
:root {
  --primary: #6366f1;
  --primary-dark: #4f46e5;
  --accent: #f43f5e;
  --bg: #0a0a0f;
  --surface: #16161e;
  --surface-light: #22222e;
  --text-primary: #f8fafc;
  --text-secondary: #94a3b8;
  --text-muted: #64748b;
  --border: rgba(255, 255, 255, 0.1);
  --radius-lg: 16px;
  --radius-md: 12px;
  --container-width: 1200px;
  --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

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

body {
  background-color: var(--bg);
  color: var(--text-primary);
  font-family: 'Inter', sans-serif;
  line-height: 1.6;
  overflow-x: hidden;
}

h1, h2, h3, .logo-text {
  font-family: 'Plus Jakarta Sans', sans-serif;
  font-weight: 700;
}

.container {
  max-width: var(--container-width);
  margin: 0 auto;
  padding: 0 24px;
}

/* Navbar */
.navbar {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 1000;
  background: rgba(10, 10, 15, 0.8);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border);
  height: 80px;
  display: flex;
  align-items: center;
}

.nav-content {
  display: flex;
  justify-content: space-between;
  align-items: center;
  width: 100%;
}

.logo {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 1.5rem;
  text-decoration: none;
  color: var(--text-primary);
}

.logo-icon {
  background: var(--primary);
  color: white;
  width: 32px;
  height: 32px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 8px;
  font-size: 0.8rem;
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 32px;
}

.nav-links a {
  text-decoration: none;
  color: var(--text-secondary);
  font-weight: 500;
  transition: var(--transition);
}

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

.btn-primary {
  background: var(--primary);
  color: white !important;
  padding: 10px 24px;
  border-radius: 100px;
  font-weight: 600;
}

.btn-primary:hover {
  background: var(--primary-dark);
  transform: translateY(-2px);
}

.mobile-toggle {
  display: none;
  background: none;
  border: none;
  color: white;
  font-size: 1.5rem;
  cursor: pointer;
}

/* Hero Section */
.hero {
  padding: 180px 0 100px;
  position: relative;
  text-align: center;
}

.hero-content {
  max-width: 800px;
  margin: 0 auto;
  position: relative;
  z-index: 2;
}

.badge {
  display: inline-block;
  padding: 6px 16px;
  background: rgba(99, 102, 241, 0.1);
  border: 1px solid rgba(99, 102, 241, 0.2);
  color: var(--primary);
  border-radius: 100px;
  font-size: 0.875rem;
  font-weight: 600;
  margin-bottom: 24px;
}

.hero h1 {
  font-size: clamp(2.5rem, 8vw, 4.5rem);
  line-height: 1.1;
  margin-bottom: 24px;
  letter-spacing: -0.02em;
}

.text-gradient {
  background: linear-gradient(135deg, var(--primary), #a855f7);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

.hero p {
  font-size: 1.25rem;
  color: var(--text-secondary);
  margin-bottom: 48px;
  max-width: 600px;
  margin-left: auto;
  margin-right: auto;
}

.search-box-wrapper {
  max-width: 600px;
  margin: 0 auto;
}

.search-box {
  display: flex;
  background: var(--surface);
  border: 1px solid var(--border);
  padding: 8px;
  border-radius: 100px;
  box-shadow: 0 20px 40px rgba(0,0,0,0.4);
  transition: var(--transition);
}

.search-box:focus-within {
  border-color: var(--primary);
  box-shadow: 0 0 0 4px rgba(99, 102, 241, 0.2);
}

.search-box input {
  flex: 1;
  background: none;
  border: none;
  padding: 0 24px;
  color: white;
  font-size: 1rem;
  outline: none;
}

.btn-search {
  background: var(--primary);
  color: white;
  border: none;
  padding: 12px 32px;
  border-radius: 100px;
  font-weight: 600;
  cursor: pointer;
  transition: var(--transition);
}

.btn-search:hover {
  background: var(--primary-dark);
}

.hero-bg-glow {
  position: absolute;
  top: 0;
  left: 50%;
  transform: translateX(-50%);
  width: 100%;
  height: 100%;
  background: radial-gradient(circle at 50% 30%, rgba(99, 102, 241, 0.15), transparent 70%);
  pointer-events: none;
}

/* Sections */
.results-section, .favorites-section, .stats-section, .faq-section {
  padding: 100px 0;
}

.section-header {
  margin-bottom: 48px;
  text-align: center;
}

.section-header h2 {
  font-size: 2.5rem;
  margin-bottom: 16px;
}

.section-header p {
  color: var(--text-secondary);
  font-size: 1.1rem;
}

/* Video Grid */
.video-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  gap: 32px;
}

.video-card {
  background: var(--surface);
  border-radius: var(--radius-lg);
  overflow: hidden;
  border: 1px solid var(--border);
  transition: var(--transition);
  position: relative;
}

.video-card:hover {
  transform: translateY(-8px);
  border-color: var(--primary);
  box-shadow: 0 12px 24px rgba(0,0,0,0.3);
}

.thumbnail-wrapper {
  position: relative;
  aspect-ratio: 16/9;
  overflow: hidden;
}

.thumbnail-wrapper img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: var(--transition);
}

.video-card:hover .thumbnail-wrapper img {
  scale: 1.05;
}

.play-overlay {
  position: absolute;
  inset: 0;
  background: rgba(0,0,0,0.4);
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  transition: var(--transition);
}

.video-card:hover .play-overlay {
  opacity: 1;
}

.play-btn {
  width: 60px;
  height: 60px;
  background: var(--primary);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: white;
  font-size: 1.5rem;
  border: none;
  cursor: pointer;
}

.video-info {
  padding: 20px;
}

.video-title {
  font-size: 1.1rem;
  font-weight: 600;
  margin-bottom: 8px;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.video-channel {
  color: var(--text-secondary);
  font-size: 0.9rem;
  margin-bottom: 16px;
}

.card-actions {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.btn-fav {
  background: none;
  border: 1px solid var(--border);
  color: var(--text-secondary);
  padding: 8px 12px;
  border-radius: 8px;
  cursor: pointer;
  transition: var(--transition);
  display: flex;
  align-items: center;
  gap: 6px;
}

.btn-fav:hover, .btn-fav.active {
  background: rgba(244, 63, 94, 0.1);
  border-color: var(--accent);
  color: var(--accent);
}

/* Stats */
.stats-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 32px;
  text-align: center;
}

.stat-card {
  padding: 40px;
  background: var(--surface);
  border-radius: var(--radius-lg);
  border: 1px solid var(--border);
}

.stat-number {
  font-size: 3rem;
  color: var(--primary);
  margin-bottom: 8px;
}

/* FAQ */
.faq-accordion {
  max-width: 800px;
  margin: 0 auto;
}

.faq-item {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  margin-bottom: 16px;
  overflow: hidden;
}

.faq-question {
  width: 100%;
  padding: 20px 24px;
  background: none;
  border: none;
  color: white;
  text-align: left;
  font-size: 1.1rem;
  font-weight: 600;
  cursor: pointer;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.faq-answer {
  padding: 0 24px 20px;
  color: var(--text-secondary);
  display: none;
}

.faq-item.active .faq-answer {
  display: block;
}

/* Modal */
.modal {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.9);
  z-index: 2000;
  display: none;
  align-items: center;
  justify-content: center;
  padding: 24px;
}

.modal.active {
  display: flex;
}

.modal-content {
  width: 100%;
  max-width: 1000px;
  background: var(--surface);
  border-radius: var(--radius-lg);
  overflow: hidden;
  position: relative;
}

.close-modal {
  position: absolute;
  top: 20px;
  right: 20px;
  background: rgba(0,0,0,0.5);
  border: none;
  color: white;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  font-size: 1.5rem;
  cursor: pointer;
  z-index: 10;
}

.video-container {
  position: relative;
  padding-bottom: 56.25%;
  height: 0;
}

.video-container iframe {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
}

.modal-info {
  padding: 32px;
}

/* Footer */
.footer {
  padding: 80px 0 40px;
  border-top: 1px solid var(--border);
  background: #050508;
}

.footer-grid {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr;
  gap: 64px;
  margin-bottom: 64px;
}

.footer-brand p {
  margin-top: 20px;
  color: var(--text-secondary);
}

.footer-links h4 {
  margin-bottom: 24px;
}

.footer-links a {
  display: block;
  color: var(--text-secondary);
  text-decoration: none;
  margin-bottom: 12px;
  transition: var(--transition);
}

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

.footer-bottom {
  text-align: center;
  padding-top: 40px;
  border-top: 1px solid var(--border);
  color: var(--text-muted);
  font-size: 0.9rem;
}

/* Responsive */
@media (max-width: 768px) {
  .nav-links { display: none; }
  .mobile-toggle { display: block; }
  .footer-grid { grid-template-columns: 1fr; gap: 40px; }
  .stats-grid { grid-template-columns: 1fr; }
  .hero h1 { font-size: 3rem; }
}

.empty-state {
  grid-column: 1 / -1;
  text-align: center;
  padding: 60px;
  color: var(--text-muted);
  border: 2px dashed var(--border);
  border-radius: var(--radius-lg);
}
