:root {
  --primary: 250 100% 65%; /* Vibrant Purple/Blue */
  --secondary: 190 100% 50%; /* Cyan */
  --bg-dark: 230 25% 8%;
  --bg-card: 230 20% 12%;
  --bg-card-hover: 230 20% 16%;
  --text-main: 0 0% 100%;
  --text-muted: 230 15% 65%;
  --border: 230 15% 20%;
  --glow: 250 100% 65%;
}

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

body {
  font-family: 'Inter', system-ui, -apple-system, sans-serif;
  background-color: hsl(var(--bg-dark));
  color: hsl(var(--text-main));
  line-height: 1.5;
  min-height: 100vh;
  overflow-x: hidden;
}

/* Background gradient orbs */
.bg-orbs {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  overflow: hidden;
  z-index: -1;
  pointer-events: none;
}

.orb-1 {
  position: absolute;
  top: -20%;
  left: -10%;
  width: 50vw;
  height: 50vw;
  background: radial-gradient(circle, hsla(var(--primary), 0.15) 0%, transparent 70%);
  border-radius: 50%;
  filter: blur(80px);
}

.orb-2 {
  position: absolute;
  bottom: -20%;
  right: -10%;
  width: 60vw;
  height: 60vw;
  background: radial-gradient(circle, hsla(var(--secondary), 0.1) 0%, transparent 70%);
  border-radius: 50%;
  filter: blur(100px);
}

/* Layout */
.app-container {
  display: flex;
  flex-direction: column;
  min-height: 100vh;
}

header {
  padding: 2rem;
  text-align: center;
  border-bottom: 1px solid hsla(var(--border), 1);
  background: hsla(var(--bg-dark), 0.8);
  backdrop-filter: blur(12px);
  position: sticky;
  top: 0;
  z-index: 10;
}

.brand {
  font-size: 2.5rem;
  font-weight: 800;
  letter-spacing: -1px;
  background: linear-gradient(135deg, hsl(var(--primary)), hsl(var(--secondary)));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  display: inline-block;
  margin-bottom: 1rem;
}

.subtitle {
  color: hsl(var(--text-muted));
  font-size: 1.1rem;
  max-width: 600px;
  margin: 0 auto;
}

.main-content {
  display: flex;
  flex: 1;
  padding: 2rem;
  gap: 2rem;
  max-width: 1400px;
  margin: 0 auto;
  width: 100%;
}

/* Sidebar */
.sidebar {
  width: 280px;
  flex-shrink: 0;
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
}

.filter-section {
  background: hsla(var(--bg-card), 0.5);
  border: 1px solid hsla(var(--border), 1);
  border-radius: 16px;
  padding: 1.5rem;
  backdrop-filter: blur(12px);
}

.filter-title {
  font-size: 1.1rem;
  font-weight: 600;
  margin-bottom: 1rem;
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.search-input {
  width: 100%;
  padding: 0.8rem 1rem;
  background: hsla(var(--bg-dark), 0.8);
  border: 1px solid hsla(var(--border), 1);
  border-radius: 8px;
  color: hsl(var(--text-main));
  font-size: 1rem;
  transition: all 0.3s ease;
  outline: none;
}

.search-input:focus {
  border-color: hsl(var(--primary));
  box-shadow: 0 0 0 2px hsla(var(--primary), 0.2);
}

.category-list {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.category-btn {
  background: transparent;
  border: none;
  color: hsl(var(--text-muted));
  text-align: left;
  padding: 0.6rem 1rem;
  border-radius: 8px;
  cursor: pointer;
  font-size: 0.95rem;
  transition: all 0.2s ease;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.category-btn:hover {
  background: hsla(var(--bg-card-hover), 1);
  color: hsl(var(--text-main));
}

.category-btn.active {
  background: hsla(var(--primary), 0.15);
  color: hsl(var(--primary));
  font-weight: 500;
}

.category-count {
  background: hsla(var(--bg-dark), 0.8);
  padding: 0.2rem 0.5rem;
  border-radius: 12px;
  font-size: 0.8rem;
}

/* Grid */
.grid-container {
  flex: 1;
}

.stats-bar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 1.5rem;
  color: hsl(var(--text-muted));
}

.sites-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 1.5rem;
}

/* Website Card */
.site-card {
  background: hsla(var(--bg-card), 0.6);
  border: 1px solid hsla(var(--border), 1);
  border-radius: 16px;
  padding: 1.5rem;
  display: flex;
  flex-direction: column;
  gap: 1rem;
  transition: all 0.3s cubic-bezier(0.25, 0.8, 0.25, 1);
  position: relative;
  overflow: hidden;
  backdrop-filter: blur(12px);
}

.site-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 4px;
  background: linear-gradient(90deg, hsl(var(--primary)), hsl(var(--secondary)));
  opacity: 0;
  transition: opacity 0.3s ease;
}

.site-card:hover {
  transform: translateY(-4px);
  border-color: hsla(var(--primary), 0.4);
  box-shadow: 0 12px 24px hsla(0, 0%, 0%, 0.4), 0 0 16px hsla(var(--primary), 0.1);
  background: hsla(var(--bg-card-hover), 0.8);
}

.site-card:hover::before {
  opacity: 1;
}

.card-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
}

.card-category {
  font-size: 0.8rem;
  text-transform: uppercase;
  letter-spacing: 1px;
  font-weight: 600;
  color: hsl(var(--secondary));
}

.card-cpc {
  background: hsla(var(--primary), 0.1);
  color: hsl(var(--primary));
  padding: 0.3rem 0.6rem;
  border-radius: 6px;
  font-size: 0.8rem;
  font-weight: 600;
  white-space: nowrap;
}

.card-title {
  font-size: 1.25rem;
  font-weight: 600;
  line-height: 1.4;
  flex: 1;
}

.card-research {
  font-size: 0.9rem;
  color: hsla(var(--text-main), 0.85);
  line-height: 1.5;
  background: hsla(var(--bg-dark), 0.4);
  padding: 1rem;
  border-radius: 8px;
  border-left: 3px solid hsl(var(--secondary));
  margin-bottom: 0.5rem;
}

.card-url {
  color: hsl(var(--text-muted));
  font-size: 0.9rem;
  display: flex;
  align-items: center;
  gap: 0.4rem;
}

.card-footer {
  margin-top: auto;
  padding-top: 1rem;
  border-top: 1px solid hsla(var(--border), 0.5);
}

.visit-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  width: 100%;
  padding: 0.8rem;
  background: hsla(var(--bg-dark), 0.8);
  border: 1px solid hsla(var(--border), 1);
  border-radius: 8px;
  color: hsl(var(--text-main));
  text-decoration: none;
  font-weight: 500;
  transition: all 0.2s ease;
}

.site-card:hover .visit-btn {
  background: hsl(var(--primary));
  border-color: hsl(var(--primary));
  color: white;
}

.visit-btn:active {
  transform: scale(0.98);
}

/* Responsive */
@media (max-width: 900px) {
  .main-content {
    flex-direction: column;
    padding: 1rem;
    gap: 1rem;
  }
  .sidebar {
    width: 100%;
  }
}

@media (max-width: 600px) {
  header {
    padding: 1.5rem 1rem;
  }
  
  .brand {
    font-size: 2rem;
  }
  
  .subtitle {
    font-size: 1rem;
  }
  
  .site-card {
    padding: 1.25rem;
  }
  
  .card-title {
    font-size: 1.15rem;
  }
  
  .app-footer {
    padding: 2rem 1rem 1.5rem;
  }
  
  .footer-content {
    gap: 2rem;
  }
}

/* Animations */
@keyframes fadeIn {
  from { opacity: 0; transform: translateY(10px); }
  to { opacity: 1; transform: translateY(0); }
/* AdSense Placeholders */
.ad-placeholder {
  background: hsla(var(--bg-dark), 0.5);
  border: 1px dashed hsla(var(--text-muted), 0.5);
  text-align: center;
  margin-bottom: 2rem;
  border-radius: 8px;
  overflow: hidden;
  display: flex;
  flex-direction: column;
}

.ad-placeholder small {
  display: block;
  font-size: 0.7rem;
  color: hsla(var(--text-muted), 0.6);
  text-transform: uppercase;
  padding: 0.2rem;
  background: hsla(var(--bg-dark), 0.8);
}

.ad-content {
  padding: 2rem;
  color: hsla(var(--text-muted), 0.5);
  font-weight: 600;
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 90px;
}

.sidebar-ad .ad-content {
  min-height: 250px;
}

/* Cookie Banner */
.cookie-banner {
  position: fixed;
  bottom: 0;
  left: 0;
  width: 100%;
  background: hsla(var(--bg-card), 0.95);
  backdrop-filter: blur(16px);
  border-top: 1px solid hsla(var(--primary), 0.5);
  padding: 1.5rem 2rem;
  display: flex;
  justify-content: space-between;
  align-items: center;
  z-index: 9999;
  box-shadow: 0 -10px 30px hsla(0,0%,0%,0.5);
}

.cookie-banner p {
  color: hsl(var(--text-main));
  font-size: 0.95rem;
  max-width: 800px;
}

.cookie-banner a {
  color: hsl(var(--primary));
  text-decoration: underline;
}

.cookie-banner .visit-btn {
  width: auto;
  padding: 0.6rem 2rem;
}

@media (max-width: 768px) {
  .cookie-banner {
    flex-direction: column;
    gap: 1rem;
    text-align: center;
  }
}

/* Pagination Controls */
.pagination-controls {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 1.5rem;
  margin-top: 3rem;
  padding: 1rem;
}

.page-btn {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  background: hsla(var(--primary), 0.1);
  color: hsl(var(--primary));
  border: 1px solid hsla(var(--primary), 0.3);
  padding: 0.6rem 1.2rem;
  border-radius: 8px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s ease;
}

.page-btn:hover:not(:disabled) {
  background: hsl(var(--primary));
  color: #0f172a;
}

.page-btn:disabled {
  opacity: 0.4;
  cursor: not-allowed;
  background: transparent;
  border-color: hsla(var(--border), 1);
  color: hsla(var(--text-muted), 1);
}

.page-info {
  color: hsla(var(--text-main), 0.9);
  font-weight: 500;
  font-size: 0.95rem;
}

.animate-fade-in {
  animation: fadeIn 0.4s ease forwards;
}

/* Category Description Block */
.category-description-block {
  background: hsla(var(--bg-card), 0.7);
  border: 1px solid hsla(var(--primary), 0.3);
  border-left: 4px solid hsl(var(--primary));
  padding: 1.5rem;
  border-radius: 12px;
  margin-bottom: 2rem;
  backdrop-filter: blur(12px);
  color: hsl(var(--text-muted));
  line-height: 1.6;
}

.category-description-block h3 {
  color: hsl(var(--text-main));
  margin-bottom: 0.5rem;
  font-size: 1.2rem;
}

/* Footer */
.app-footer {
  margin-top: 4rem;
  background: hsla(var(--bg-card), 0.8);
  border-top: 1px solid hsla(var(--border), 1);
  padding: 3rem 2rem 1.5rem;
  backdrop-filter: blur(12px);
}

.footer-content {
  max-width: 1400px;
  margin: 0 auto;
  display: flex;
  flex-wrap: wrap;
  gap: 3rem;
  justify-content: space-between;
}

.footer-about {
  flex: 2;
  min-width: 300px;
}

.footer-about h3 {
  color: hsl(var(--text-main));
  margin-bottom: 1rem;
}

.footer-about p {
  color: hsl(var(--text-muted));
  font-size: 0.95rem;
  line-height: 1.6;
}

.footer-links {
  flex: 1;
  min-width: 200px;
}

.footer-links h3 {
  color: hsl(var(--text-main));
  margin-bottom: 1rem;
}

.footer-links ul {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.footer-links a {
  color: hsl(var(--text-muted));
  text-decoration: none;
  transition: color 0.2s;
  font-size: 0.95rem;
}

.footer-links a:hover {
  color: hsl(var(--primary));
}

.footer-bottom {
  text-align: center;
  margin-top: 3rem;
  padding-top: 1.5rem;
  border-top: 1px solid hsla(var(--border), 0.5);
  color: hsla(var(--text-muted), 0.8);
  font-size: 0.85rem;
}
