/* Reset and Base Styles */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

:root {
  --primary: #6366f1;
  --primary-dark: #4f46e5;
  --primary-light: #818cf8;
  --secondary: #10b981;
  --dark: #0f172a;
  --dark-light: #1e293b;
  --gray: #64748b;
  --gray-light: #cbd5e1;
  --light: #f1f5f9;
  --white: #ffffff;
  --gradient: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  --gradient-2: linear-gradient(135deg, #f093fb 0%, #f5576c 100%);
  --shadow: 0 10px 40px rgba(0, 0, 0, 0.1);
  --shadow-lg: 0 20px 60px rgba(0, 0, 0, 0.15);
}

body {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "Roboto", "Oxygen",
    "Ubuntu", "Cantarell", sans-serif;
  line-height: 1.6;
  color: var(--dark);
  background: var(--white);
  overflow-x: hidden;
}

.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 24px;
}

/* Navigation */
.navbar {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  background: rgba(255, 255, 255, 0.95);
  backdrop-filter: blur(10px);
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);
  z-index: 1000;
  padding: 16px 0;
}

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

/* Ensure clear separation between links and action button */
.nav-links {
  flex: 1;
}
.nav-actions {
  margin-left: 24px;
}

.brand {
  display: flex;
  align-items: center;
  gap: 12px;
}

/* Allow brand text to shrink gracefully */
.brand {
  flex: 1;
  min-width: 0;
}
.brand-name {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.nav-logo {
  width: 48px;
  height: 48px;
}

.brand-name {
  font-size: 1.25rem;
  font-weight: 700;
  color: var(--dark);
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 32px;
  padding-right: 16px; /* breathing room near action button */
}

/* Collapsible nav group */
.nav-group {
  position: relative;
}

.nav-toggle {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: transparent;
  border: 1px solid var(--gray-light);
  color: var(--gray);
  padding: 8px 12px;
  border-radius: 8px;
  cursor: pointer;
  font-weight: 600;
}

.nav-toggle:hover {
  color: var(--primary);
  border-color: var(--primary-light);
}

.nav-dropdown {
  position: absolute;
  top: 110%;
  left: 0;
  min-width: 220px;
  background: var(--white);
  border: 1px solid var(--gray-light);
  box-shadow: var(--shadow);
  border-radius: 10px;
  padding: 8px;
  display: none;
  z-index: 1001;
}

.nav-dropdown a {
  display: block;
  padding: 10px 12px;
  border-radius: 6px;
  color: var(--gray);
  text-decoration: none;
  font-weight: 500;
}

.nav-dropdown a:hover {
  background: var(--light);
  color: var(--primary);
}

/* Open state */
.nav-group[aria-expanded="true"] .nav-dropdown {
  display: block;
}

.nav-links a {
  color: var(--gray);
  text-decoration: none;
  font-weight: 500;
  font-size: 0.95rem;
  transition: color 0.3s ease;
}

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

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 10px 24px;
  border-radius: 8px;
  font-weight: 600;
  text-decoration: none;
  cursor: pointer;
  transition: all 0.3s ease;
  border: none;
  font-size: 0.95rem;
}

.btn-primary {
  background: var(--primary);
  color: var(--white);
}

.btn-primary:hover {
  background: var(--primary-dark);
  transform: translateY(-2px);
  box-shadow: 0 8px 20px rgba(99, 102, 241, 0.3);
}

.btn-secondary {
  background: transparent;
  color: var(--primary);
  border: 2px solid var(--primary);
}

.btn-secondary:hover {
  background: var(--primary);
  color: var(--white);
}

.btn-large {
  padding: 14px 32px;
  font-size: 1.05rem;
}

/* Hero Section */
.hero {
  padding: 140px 0 80px;
  background: linear-gradient(135deg, #f8fafc 0%, #e0e7ff 100%);
  position: relative;
  overflow: hidden;
}

.hero::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: radial-gradient(
    circle at 20% 50%,
    rgba(99, 102, 241, 0.1) 0%,
    transparent 50%
  );
  pointer-events: none;
}

.hero-content {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 60px;
  align-items: center;
  position: relative;
  z-index: 1;
}

.hero-title {
  font-size: 3.5rem;
  font-weight: 800;
  line-height: 1.2;
  margin-bottom: 24px;
  color: var(--dark);
}

.highlight {
  background: var(--gradient);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.hero-subtitle {
  font-size: 1.25rem;
  color: var(--gray);
  margin-bottom: 32px;
  line-height: 1.8;
}

.hero-cta {
  display: flex;
  gap: 16px;
  margin-bottom: 32px;
}

.hero-badges {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
}

.badge {
  display: inline-flex;
  align-items: center;
  padding: 8px 16px;
  background: var(--white);
  border-radius: 50px;
  font-size: 0.9rem;
  color: var(--gray);
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
}

/* Hero Visual */
.mockup-container {
  position: relative;
  animation: float 6s ease-in-out infinite;
}

@keyframes float {
  0%,
  100% {
    transform: translateY(0px);
  }
  50% {
    transform: translateY(-20px);
  }
}

.mockup-browser {
  background: var(--white);
  border-radius: 12px;
  box-shadow: var(--shadow-lg);
  overflow: hidden;
}

.browser-header {
  background: var(--dark-light);
  padding: 12px;
  display: flex;
  align-items: center;
  gap: 12px;
}

.browser-dots {
  display: flex;
  gap: 6px;
}

.browser-dots span {
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background: var(--gray);
}

.browser-dots span:nth-child(1) {
  background: #ff5f56;
}
.browser-dots span:nth-child(2) {
  background: #ffbd2e;
}
.browser-dots span:nth-child(3) {
  background: #27c93f;
}

.browser-url {
  flex: 1;
  background: var(--dark);
  padding: 6px 12px;
  border-radius: 6px;
  color: var(--gray-light);
  font-size: 0.85rem;
}

.browser-content {
  padding: 24px;
}

.demo-video-player {
  width: 100%;
  height: 200px;
  background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  border-radius: 8px;
  margin-bottom: 16px;
}

.demo-summary {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.demo-line {
  height: 12px;
  background: var(--light);
  border-radius: 4px;
  animation: pulse 2s ease-in-out infinite;
}

.demo-line.short {
  width: 60%;
}
.demo-line.medium {
  width: 80%;
}

@keyframes pulse {
  0%,
  100% {
    opacity: 1;
  }
  50% {
    opacity: 0.5;
  }
}

/* Floating Cards */
.floating-card {
  position: absolute;
  background: var(--white);
  padding: 12px 20px;
  border-radius: 12px;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.12);
  display: flex;
  align-items: center;
  gap: 8px;
  font-weight: 600;
  font-size: 0.9rem;
  animation: fadeInUp 0.6s ease-out forwards;
  opacity: 0;
}

.floating-card .emoji {
  font-size: 1.2rem;
}

.card-1 {
  top: 10%;
  right: -10%;
  animation-delay: 0.5s;
}

.card-2 {
  bottom: 30%;
  right: -8%;
  animation-delay: 1s;
}

.card-3 {
  bottom: 10%;
  left: -5%;
  animation-delay: 1.5s;
}

.card-4 {
  top: 30%;
  left: -8%;
  animation-delay: 2s;
}

@keyframes fadeInUp {
  to {
    opacity: 1;
    transform: translateY(-10px);
  }
}

/* Section Headers */
.section-header {
  text-align: center;
  margin-bottom: 60px;
}

.section-header h2 {
  font-size: 2.5rem;
  font-weight: 800;
  margin-bottom: 16px;
  color: var(--dark);
}

.section-header p {
  font-size: 1.15rem;
  color: var(--gray);
}

/* YouTube Limitations Section */
.youtube-limitations {
  padding: 100px 0;
  background: linear-gradient(135deg, #f8fafc 0%, #f1f5f9 100%);
}

.limitations-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 32px;
  margin-top: 60px;
}

.limitation-card {
  background: var(--white);
  padding: 32px;
  border-radius: 16px;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
  transition: all 0.3s ease;
  border: 2px solid transparent;
  position: relative;
  overflow: hidden;
}

.limitation-card::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 4px;
  background: linear-gradient(90deg, #ef4444 0%, #f97316 100%);
}

.limitation-card:hover {
  transform: translateY(-8px);
  box-shadow: 0 12px 40px rgba(0, 0, 0, 0.15);
  border-color: var(--primary-light);
}

.limitation-icon {
  font-size: 3rem;
  margin-bottom: 20px;
  opacity: 0.8;
}

.limitation-card h3 {
  font-size: 1.35rem;
  font-weight: 700;
  margin-bottom: 12px;
  color: var(--dark);
}

.limitation-card > p {
  color: var(--gray);
  margin-bottom: 20px;
  line-height: 1.7;
  font-size: 0.95rem;
}

.solution {
  margin-top: 16px;
  padding-top: 14px;
  border-top: 2px solid var(--light);
  display: flex;
  align-items: flex-start;
  gap: 14px;
  flex-wrap: wrap;
}

.solution-badge {
  display: inline-block;
  padding: 6px 14px;
  background: linear-gradient(135deg, var(--secondary) 0%, #059669 100%);
  color: var(--white);
  border-radius: 20px;
  font-size: 0.85rem;
  font-weight: 700;
  margin-bottom: 0;
  letter-spacing: 0.3px;
  flex-shrink: 0;
}

.solution p {
  color: var(--dark);
  font-weight: 500;
  line-height: 1.5;
  font-size: 0.95rem;
  margin: 0;
  flex: 1;
}

/* Features Section */
.features {
  padding: 100px 0;
  background: var(--white);
}

.features-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 24px;
}

.feature-card {
  background: var(--white);
  padding: 32px;
  border-radius: 16px;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
  transition: all 0.3s ease;
  opacity: 0;
  transform: translateY(20px);
}

.feature-card.animate-in {
  opacity: 1;
  transform: translateY(0);
}

.feature-card:hover {
  transform: translateY(-8px);
  box-shadow: 0 12px 40px rgba(0, 0, 0, 0.12);
}

.feature-icon {
  font-size: 2rem;
  margin: 0;
}

.feature-head {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 12px;
}

.feature-card h3 {
  font-size: 1.5rem;
  font-weight: 700;
  margin-bottom: 0;
  color: var(--dark);
}

.feature-card p {
  color: var(--gray);
  margin-bottom: 16px;
  line-height: 1.7;
}

.feature-list {
  list-style: none;
  padding: 0;
}

.feature-list li {
  padding: 6px 0;
  color: var(--gray);
  display: flex;
  align-items: center;
  gap: 8px;
}

.feature-list li::before {
  content: "✓";
  color: var(--secondary);
  font-weight: bold;
}

/* How It Works */
.how-it-works {
  padding: 100px 0;
  background: var(--light);
}

.steps {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 40px;
  flex-wrap: wrap;
}

.step {
  flex: 1;
  min-width: 250px;
  max-width: 300px;
  text-align: center;
  position: relative;
  opacity: 0;
  transform: translateY(20px);
}

.step.animate-in {
  opacity: 1;
  transform: translateY(0);
}

.step-number {
  position: absolute;
  top: -10px;
  right: -10px;
  width: 40px;
  height: 40px;
  background: var(--primary);
  color: var(--white);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 1.2rem;
}

.step-icon {
  font-size: 4rem;
  margin-bottom: 20px;
}

.step h3 {
  font-size: 1.3rem;
  font-weight: 700;
  margin-bottom: 12px;
  color: var(--dark);
}

.step p {
  color: var(--gray);
  line-height: 1.6;
}

.step-arrow {
  font-size: 2rem;
  color: var(--primary);
  font-weight: bold;
}

/* Use Cases */
.use-cases {
  padding: 100px 0;
  background: var(--white);
}

.use-cases-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 32px;
}

.use-case {
  text-align: center;
  padding: 32px;
  background: var(--light);
  border-radius: 16px;
  transition: all 0.3s ease;
  opacity: 0;
  transform: translateY(20px);
}

.use-case.animate-in {
  opacity: 1;
  transform: translateY(0);
}

.use-case:hover {
  background: var(--white);
  box-shadow: var(--shadow);
  transform: translateY(-5px);
}

/* Selected/highlight state when navigated from header/footer */
.use-case.selected {
  background: var(--white);
  box-shadow: 0 12px 40px rgba(99, 102, 241, 0.25);
  border: 2px solid var(--primary-light);
  transform: translateY(-6px);
}

.use-case-icon {
  font-size: 3.5rem;
  margin-bottom: 20px;
}

.use-case h3 {
  font-size: 1.4rem;
  font-weight: 700;
  margin-bottom: 12px;
  color: var(--dark);
}

.use-case p {
  color: var(--gray);
  line-height: 1.7;
}

/* Comparison */
.comparison {
  padding: 100px 0;
  background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  color: var(--white);
}

.comparison .section-header h2,
.comparison .section-header p {
  color: var(--white);
}

.comparison-table {
  background: var(--white);
  border-radius: 16px;
  overflow: hidden;
  box-shadow: var(--shadow-lg);
}

.comparison-header,
.comparison-row {
  display: grid;
  grid-template-columns: 1fr 1fr 1fr;
}

.comparison-header {
  background: var(--dark);
  color: var(--white);
  font-weight: 700;
}

.comparison-row:nth-child(even) {
  background: var(--light);
}

.comparison-cell {
  padding: 20px;
  text-align: center;
  border-right: 1px solid var(--gray-light);
}

.comparison-cell:last-child {
  border-right: none;
}

.comparison-cell.label {
  font-weight: 600;
  text-align: left;
  color: var(--dark);
}

.comparison-cell.old {
  color: var(--gray);
}

.comparison-cell.new {
  color: var(--primary);
  font-weight: 600;
}

/* Demo Section */
.demo-section {
  padding: 100px 0;
  background: var(--light);
}

.demo-container {
  max-width: 800px;
  margin: 0 auto;
}

.demo-placeholder {
  background: var(--dark);
  border-radius: 16px;
  padding: 100px 40px;
  text-align: center;
  position: relative;
  overflow: hidden;
}

.demo-placeholder::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: linear-gradient(
    135deg,
    rgba(99, 102, 241, 0.1) 0%,
    rgba(139, 92, 246, 0.1) 100%
  );
}

.demo-play-button {
  margin: 0 auto 24px;
  width: 80px;
  height: 80px;
  background: var(--primary);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.3s ease;
  position: relative;
}

.demo-play-button:hover {
  transform: scale(1.1);
  background: var(--primary-light);
}

.demo-text {
  color: var(--white);
  font-size: 1.2rem;
  position: relative;
}

/* CTA Section */
.cta-section {
  padding: 100px 0;
  background: var(--white);
  text-align: center;
}

.cta-content h2 {
  font-size: 2.5rem;
  font-weight: 800;
  margin-bottom: 20px;
  color: var(--dark);
}

.cta-content p {
  font-size: 1.15rem;
  color: var(--gray);
  margin-bottom: 32px;
}

.cta-buttons {
  margin-bottom: 24px;
}

.cta-note {
  font-size: 0.9rem;
  color: var(--gray);
}

/* Footer */
.footer {
  background: var(--dark);
  color: var(--gray-light);
  padding: 30px 0 20px;
  display: block;
  visibility: visible;
  opacity: 1;
}

.footer-content {
  display: flex;
  align-items: center;
  gap: 24px;
  justify-content: center;
  margin-bottom: 0;
  flex-wrap: wrap;
}

.footer-brand {
  display: flex;
  flex-direction: row;
  align-items: center;
  gap: 14px;
}

.footer-logo {
  width: 40px;
  height: 40px;
  flex-shrink: 0;
}

.footer-brand p {
  color: var(--gray-light);
  line-height: 1.6;
  margin: 0;
  font-size: 0.95rem;
}

.footer-bottom {
  border-top: none;
  padding-top: 0;
  text-align: center;
}

.footer-bottom p {
  margin: 0;
  color: var(--gray-light);
  font-size: 0.9rem;
}

@media (max-width: 968px) {
  .footer {
    padding: 25px 0 18px;
  }
  .footer-content {
    gap: 20px;
    padding: 0 20px;
  }
  .footer-logo {
    width: 36px;
    height: 36px;
  }
  .footer-brand p {
    font-size: 0.9rem;
  }
}

/* Responsive Design */
@media (max-width: 968px) {
  /* Navbar: reduce density on tablets */
  .nav-logo {
    width: 40px;
    height: 40px;
  }
  .brand-name {
    font-size: 1.05rem;
  }
  .nav-links {
    gap: 18px;
    padding-right: 12px;
  }
  .nav-actions {
    margin-left: 16px;
  }
  .nav-dropdown {
    min-width: 200px;
  }

  .hero-content {
    grid-template-columns: 1fr;
    gap: 40px;
  }

  .hero-title {
    font-size: 2.5rem;
  }

  .hero-visual {
    order: -1;
  }

  .section-header h2 {
    font-size: 2rem;
  }

  .comparison-header,
  .comparison-row {
    grid-template-columns: 1fr;
  }

  .comparison-cell {
    border-right: none;
    border-bottom: 1px solid var(--gray-light);
  }

  .comparison-cell.label {
    text-align: center;
    font-weight: 700;
    background: var(--dark-light);
    color: var(--white);
  }

  .step-arrow {
    display: none;
  }

  .footer-content {
    grid-template-columns: 1fr;
    gap: 30px;
  }
}

@media (max-width: 640px) {
  /* Navbar: prevent overflow on mobile */
  .navbar {
    padding: 12px 0;
  }
  .nav-content {
    gap: 12px;
  }
  .brand-name {
    display: inline;
    font-size: 0.95rem;
  }
  .nav-logo {
    width: 36px;
    height: 36px;
  }
  /* Hide all menu items on mobile, keep only logo, name, and button */
  .nav-links {
    display: none;
  }
  .nav-actions {
    margin-left: auto;
  }
  .nav-actions .btn {
    padding: 8px 14px;
    font-size: 0.9rem;
  }

  .hero {
    padding: 100px 0 60px;
  }

  .hero-title {
    font-size: 2rem;
  }

  .hero-subtitle {
    font-size: 1.1rem;
  }

  .hero-cta {
    flex-direction: column;
  }

  .btn-large {
    width: 100%;
    justify-content: center;
  }

  .section-header h2 {
    font-size: 1.75rem;
  }

  .features-grid,
  .use-cases-grid,
  .limitations-grid {
    grid-template-columns: 1fr;
  }

  /* Footer mobile improvements */
  .footer {
    padding: 20px 0 16px;
  }
  .footer-content {
    flex-direction: column;
    gap: 12px;
    padding: 0 16px;
  }
  .footer-brand {
    flex-direction: column;
    text-align: center;
  }
  .footer-logo {
    width: 32px;
    height: 32px;
  }
  .footer-brand p {
    font-size: 0.85rem;
    line-height: 1.4;
  }
  .footer-bottom p {
    font-size: 0.8rem;
    padding: 0 16px;
  }
}
