/**
 * GenNova — Dark theme for public pages (landing, login, contact)
 * Load after gn-landing.css + gn-auth.css. Tokens from gn-tokens body[data-theme="dark"].
 */

body[data-theme="dark"].gn-landing,
body[data-theme="dark"] .gn-landing {
  color: var(--gn-text);
  background: var(--gn-bg-page);
}

body[data-theme="dark"] .gn-landing-body {
  background: var(--gn-bg-page);
  color: var(--gn-text);
}

/* ── Navbar glass (override white rgba from gn-landing.css) ── */
body[data-theme="dark"] .gn-nav {
  background: rgba(28, 28, 30, 0.88);
  border-bottom-color: var(--gn-border);
}

body[data-theme="dark"] .gn-nav.scrolled {
  background: rgba(28, 28, 30, 0.97);
  box-shadow: 0 1px 0 var(--gn-border), 0 4px 16px rgba(0, 0, 0, 0.35);
}

body[data-theme="dark"] .gn-nav-mobile.open {
  background: var(--gn-bg-surface);
  border-top-color: var(--gn-border);
}

/* ── Hero / sections ── */
body[data-theme="dark"] .gn-hero {
  background: var(--gn-bg-page);
}

body[data-theme="dark"] .gn-hero::before {
  background: radial-gradient(
    ellipse 80% 60% at 50% -20%,
    color-mix(in srgb, var(--gn-primary) 10%, transparent) 0%,
    transparent 70%
  );
}

body[data-theme="dark"] .gn-hero::after {
  background: radial-gradient(
    circle,
    color-mix(in srgb, var(--gn-primary) 6%, transparent) 0%,
    transparent 70%
  );
}

body[data-theme="dark"] .gn-landing-body .gn-section--surface {
  background: var(--gn-bg-surface);
}

body[data-theme="dark"] .gn-landing-body .gn-section--muted {
  background: var(--gn-bg-muted);
}

/* ── CTA banner (gradient section — soften white overlays) ── */
body[data-theme="dark"] .gn-cta-banner::after {
  background: radial-gradient(circle, rgba(255, 255, 255, 0.05) 0%, transparent 65%);
}

body[data-theme="dark"] .gn-cta-label {
  color: color-mix(in srgb, var(--gn-on-primary) 75%, transparent);
  background: rgba(255, 255, 255, 0.1);
}

body[data-theme="dark"] .gn-cta-sub {
  color: color-mix(in srgb, var(--gn-on-primary) 78%, transparent);
}

body[data-theme="dark"] .gn-cta-btn-outline {
  background: rgba(255, 255, 255, 0.08);
  border-color: rgba(255, 255, 255, 0.22);
}

body[data-theme="dark"] .gn-cta-btn-outline:hover {
  background: rgba(255, 255, 255, 0.14);
  border-color: rgba(255, 255, 255, 0.35);
}

/* ── Footer ── */
body[data-theme="dark"] .gn-landing-footer {
  background: var(--gn-bg-muted);
  border-top-color: var(--gn-border);
}

body[data-theme="dark"] .gn-landing-footer__bar {
  border-top-color: var(--gn-border);
}

/* ── Auth pages ── */
body[data-theme="dark"] .gn-landing-body:has(.gn-auth-page) {
  background: var(--gn-bg-page);
}

body[data-theme="dark"] .gn-auth-page {
  background: var(--gn-bg-page);
  color: var(--gn-text);
}

body[data-theme="dark"] .gn-auth-brand {
  background: color-mix(in srgb, var(--gn-primary) 8%, var(--gn-bg-surface));
  border-color: var(--gn-border);
}

body[data-theme="dark"] .gn-auth-card {
  background: var(--gn-bg-surface);
  border-color: var(--gn-border);
  box-shadow: 0 2px 12px rgba(0, 0, 0, 0.25);
}

body[data-theme="dark"] .gn-auth-card-header,
body[data-theme="dark"] .gn-auth-card-footer {
  border-color: var(--gn-border-subtle);
}

body[data-theme="dark"] .gn-auth-card-footer {
  background: var(--gn-bg-muted);
}

body[data-theme="dark"] .gn-auth-input,
body[data-theme="dark"] .gn-auth-page .form-control,
body[data-theme="dark"] .gn-auth-page .form-select {
  background: var(--gn-bg-surface);
  border-color: var(--gn-border);
  color: var(--gn-text);
}

body[data-theme="dark"] .gn-auth-input:focus,
body[data-theme="dark"] .gn-auth-page .form-control:focus {
  border-color: var(--gn-primary);
  box-shadow: 0 0 0 3px color-mix(in srgb, var(--gn-primary) 22%, transparent);
}

/* ── Pricing / cards with light glass ── */
body[data-theme="dark"] .gn-pricing-card {
  background: var(--gn-bg-surface);
  border-color: var(--gn-border);
}

body[data-theme="dark"] .gn-pricing-card--featured {
  border-color: color-mix(in srgb, var(--gn-primary) 40%, var(--gn-border));
}

body[data-theme="dark"] .gn-support-fab {
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.4);
}

/* CTA band (about + home) — gradient slate, chữ vẫn trắng */
body[data-theme="dark"] .gn-landing-body .gn-section.gn-about-cta,
body[data-theme="dark"] .gn-cta-banner {
  --gn-cta-band-fg: #ffffff;
  --gn-cta-band-fg-muted: rgba(255, 255, 255, 0.88);
  background: linear-gradient(
    135deg,
    color-mix(in srgb, var(--gn-primary) 55%, #1c1c1e) 0%,
    color-mix(in srgb, var(--gn-primary) 75%, #2c2c2e) 50%,
    color-mix(in srgb, var(--gn-primary) 65%, #1c1c1e) 100%
  );
  color: var(--gn-cta-band-fg);
}

body[data-theme="dark"] .gn-landing-body .gn-section.gn-about-cta .gn-about-cta-title {
  color: var(--gn-cta-band-fg);
}

body[data-theme="dark"] .gn-landing-body .gn-section.gn-about-cta .gn-about-cta-sub {
  color: var(--gn-cta-band-fg-muted);
}

body[data-theme="dark"] .gn-landing-body .gn-section.gn-about-cta .gn-cta-btn-primary,
body[data-theme="dark"] .gn-landing-body .gn-section.gn-about-cta .gn-btn-primary,
body[data-theme="dark"] .gn-cta-banner .gn-cta-btn-primary {
  background: rgba(255, 255, 255, 0.95);
  color: color-mix(in srgb, var(--gn-primary) 70%, #1c1c1e);
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.28);
}

body[data-theme="dark"] .gn-landing-body .gn-section.gn-about-cta .gn-cta-btn-primary:hover,
body[data-theme="dark"] .gn-landing-body .gn-section.gn-about-cta .gn-btn-primary:hover,
body[data-theme="dark"] .gn-cta-banner .gn-cta-btn-primary:hover {
  background: #ffffff;
  color: var(--gn-primary);
}

body[data-theme="dark"] .gn-landing-body .gn-section.gn-about-cta .gn-cta-btn-outline {
  background: rgba(255, 255, 255, 0.1);
  border-color: rgba(255, 255, 255, 0.42);
  color: var(--gn-cta-band-fg);
}

body[data-theme="dark"] .gn-landing-body .gn-section.gn-about-cta .gn-cta-btn-outline:hover {
  background: rgba(255, 255, 255, 0.16);
  border-color: rgba(255, 255, 255, 0.62);
  color: #ffffff;
}
