/* ============================================================
   COPENTRY — Premium Law Enforcement Reporting Platform
   Single authoritative stylesheet (dark, masculine, refined)
   ============================================================ */

:root {
  /* Surfaces */
  --ink: #070B14;
  --bg: #0A0F1C;
  --bg-2: #0E1626;
  --surface: #111B2E;
  --surface-2: #16223A;
  --surface-3: #1C2B47;

  /* Lines & glass */
  --line: rgba(255, 255, 255, 0.08);
  --line-strong: rgba(255, 255, 255, 0.14);
  --glass: rgba(255, 255, 255, 0.04);

  /* Gold accent (refined) */
  --gold: #C9A24B;
  --gold-2: #E2C271;
  --gold-3: #F4DE9A;
  --gold-soft: rgba(201, 162, 75, 0.14);
  --gold-line: rgba(201, 162, 75, 0.35);

  /* Light card system */
  --paper: #FFFFFF;
  --paper-2: #F6F8FC;
  --card-line: #E6EAF2;

  /* Text */
  --text: #EAF0FB;
  --text-dim: #AEBAD0;
  --text-mute: #7E8BA6;
  --text-dark: #131B29;
  --text-dark-2: #475064;

  /* Radii */
  --r-sm: 10px;
  --r: 16px;
  --r-lg: 22px;
  --r-xl: 28px;

  /* Shadows */
  --sh-sm: 0 1px 2px rgba(0,0,0,.4);
  --sh: 0 14px 40px rgba(0,0,0,.35);
  --sh-lg: 0 30px 80px rgba(0,0,0,.45);
  --sh-gold: 0 16px 44px rgba(201,162,75,.28);
  --sh-card: 0 18px 50px rgba(7,11,20,.14);

  --ease: cubic-bezier(.16,.84,.44,1);
}

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

html { scroll-behavior: smooth; }

body {
  font-family: 'Manrope', -apple-system, BlinkMacSystemFont, 'Segoe UI', 'Roboto', sans-serif;
  color: var(--text);
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  min-height: 100vh;
  background:
    radial-gradient(1100px 600px at 78% -8%, rgba(201,162,75,.10), transparent 60%),
    radial-gradient(900px 600px at 8% 4%, rgba(40,68,120,.28), transparent 55%),
    linear-gradient(180deg, var(--bg) 0%, var(--bg-2) 40%, var(--ink) 100%);
  background-attachment: fixed;
}

h1, h2, h3, h4, h5 {
  font-family: 'Space Grotesk', 'Manrope', sans-serif;
  color: #fff;
  line-height: 1.12;
  letter-spacing: -0.02em;
  font-weight: 700;
}

p { color: var(--text-dim); }

a { color: inherit; text-decoration: none; }

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

::selection { background: var(--gold); color: var(--ink); }

/* ---------- Skip link ---------- */
.skip-link {
  position: absolute; left: 12px; top: -56px; z-index: 3000;
  padding: 10px 16px; border-radius: 10px;
  background: var(--gold); color: var(--ink);
  font-weight: 800; transition: top .2s var(--ease);
}
.skip-link:focus { top: 12px; }

/* ============================================================
   NAVBAR
   ============================================================ */
.navbar {
  position: sticky; top: 0; z-index: 100;
  background: rgba(8, 12, 22, 0.72);
  backdrop-filter: saturate(140%) blur(16px);
  -webkit-backdrop-filter: saturate(140%) blur(16px);
  border-bottom: 1px solid var(--line);
  padding: 0.85rem 0;
}

.nav-content { display: flex; justify-content: space-between; align-items: center; }
.nav-left { display: flex; align-items: center; gap: 2.5rem; }
.nav-right { display: flex; align-items: center; gap: 1rem; }

/* Logo — single, clean, no doubling */
.logo {
  position: relative;
  display: inline-flex; align-items: center; gap: 0.7rem;
  color: #fff; font-family: 'Space Grotesk', sans-serif;
  font-weight: 700; font-size: 1.18rem; letter-spacing: 0.14em;
  text-transform: uppercase;
}
.logo::before, .logo::after { content: none !important; } /* kill legacy pseudo logos */
.logo-image { display: none !important; }                 /* kill legacy image logo */

.logo-mark {
  width: 34px; height: 34px; flex: 0 0 34px;
  display: grid; place-items: center;
  border-radius: 9px;
  background: linear-gradient(160deg, var(--gold-2), var(--gold));
  box-shadow: 0 6px 16px rgba(201,162,75,.35), inset 0 1px 0 rgba(255,255,255,.4);
}
.logo-mark svg { width: 20px; height: 20px; display: block; }
.logo-text { background: linear-gradient(180deg, #fff, #cfd8ea); -webkit-background-clip: text; background-clip: text; color: transparent; }
.logo-text b { color: var(--gold-2); -webkit-text-fill-color: var(--gold-2); font-weight: 700; }

.nav-links { display: flex; gap: 0.35rem; align-items: center; }
.nav-links a {
  position: relative;
  color: var(--text-dim); font-weight: 600; font-size: 0.86rem;
  padding: 9px 14px; border-radius: 10px;
  letter-spacing: 0.01em; transition: color .2s var(--ease), background .2s var(--ease);
}
.nav-links a:hover { color: #fff; background: var(--glass); }
.nav-links a.active { color: var(--gold-2); }
.nav-links a.active::after {
  content: ""; position: absolute; left: 14px; right: 14px; bottom: 3px; height: 2px;
  background: linear-gradient(90deg, var(--gold), var(--gold-2)); border-radius: 2px;
}

.new-badge {
  display: inline-block; vertical-align: middle; margin-left: 6px;
  background: linear-gradient(135deg, var(--gold), var(--gold-2));
  color: var(--ink); font-size: 0.6rem; font-weight: 900;
  padding: 3px 7px; border-radius: 999px; letter-spacing: 0.06em;
}

.mobile-menu-toggle {
  display: none; background: none; border: 1px solid var(--line-strong);
  color: #fff; font-size: 1.1rem; cursor: pointer; padding: 8px 12px; border-radius: 10px;
}

/* ============================================================
   BUTTONS
   ============================================================ */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 0.5rem;
  padding: 12px 24px; border: none; border-radius: 12px;
  font-family: 'Manrope', sans-serif; font-weight: 700; font-size: 0.92rem;
  letter-spacing: 0.01em; cursor: pointer; text-align: center;
  transition: transform .25s var(--ease), box-shadow .25s var(--ease), background .25s var(--ease), color .2s var(--ease);
}
.btn-primary {
  background: linear-gradient(135deg, var(--gold-2) 0%, var(--gold) 100%);
  color: #1a1406; box-shadow: var(--sh-gold);
}
.btn-primary:hover { transform: translateY(-2px); box-shadow: 0 22px 56px rgba(201,162,75,.40); }
.btn-secondary {
  background: var(--glass); color: #fff; border: 1px solid var(--line-strong);
  backdrop-filter: blur(6px);
}
.btn-secondary:hover { transform: translateY(-2px); border-color: var(--gold-line); color: var(--gold-2); }
.btn-outline { background: transparent; color: var(--gold-2); border: 1.5px solid var(--gold-line); }
.btn-outline:hover { background: var(--gold-soft); }
.btn-danger { background: linear-gradient(135deg, #7f1d1d, #a83232); color: #fff; }
.btn-danger:hover { transform: translateY(-2px); box-shadow: 0 14px 30px rgba(127,29,29,.4); }
.btn-large { padding: 16px 32px; font-size: 1rem; }

/* ============================================================
   PAGE / SECTION SYSTEM
   ============================================================ */
.page { display: none; animation: fadeIn .4s var(--ease); }
.page.active { display: block; }

.eyebrow {
  display: inline-flex; align-items: center; gap: 0.55rem;
  font-family: 'Space Grotesk', sans-serif; font-size: 0.74rem; font-weight: 700;
  letter-spacing: 0.22em; text-transform: uppercase; color: var(--gold-2);
  margin-bottom: 1rem;
}
.eyebrow::before { content: ""; width: 26px; height: 2px; background: linear-gradient(90deg, var(--gold), transparent); }

.section-title { font-size: clamp(1.8rem, 3.4vw, 2.6rem); color: #fff; margin-bottom: 0.75rem; }
.section-sub { color: var(--text-dim); max-width: 620px; margin: 0 auto; font-size: 1.02rem; }

/* ============================================================
   HERO
   ============================================================ */
.hero {
  position: relative; overflow: hidden;
  text-align: center; color: #fff;
  padding: 5.5rem 2rem 5rem;
  margin: 2rem 0;
  border-radius: var(--r-xl);
  background:
    radial-gradient(800px 380px at 50% -10%, rgba(201,162,75,.18), transparent 60%),
    linear-gradient(180deg, var(--surface) 0%, var(--bg-2) 100%);
  border: 1px solid var(--line);
  box-shadow: var(--sh-lg);
}
.hero::before {
  content: ""; position: absolute; inset: 0; pointer-events: none;
  background-image:
    linear-gradient(rgba(255,255,255,.035) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255,255,255,.035) 1px, transparent 1px);
  background-size: 46px 46px;
  mask-image: radial-gradient(circle at 50% 35%, #000 0%, transparent 72%);
  -webkit-mask-image: radial-gradient(circle at 50% 35%, #000 0%, transparent 72%);
}
.hero::after {
  content: ""; position: absolute; left: 0; right: 0; top: 0; height: 3px;
  background: linear-gradient(90deg, transparent, var(--gold), transparent);
  opacity: .7;
}
.hero > * { position: relative; z-index: 1; }
.hero h1 {
  font-size: clamp(2.3rem, 5.4vw, 4rem); font-weight: 700; letter-spacing: -0.03em;
  margin: 0 auto 1.4rem; max-width: 16ch;
}
.hero h1 .grad { background: linear-gradient(120deg, var(--gold-3), var(--gold)); -webkit-background-clip: text; background-clip: text; color: transparent; }
.hero p { font-size: 1.14rem; color: var(--text-dim); max-width: 640px; margin: 0 auto 2.2rem; }
.hero .btn { margin: 0 0.4rem; }

/* trust strip under hero CTAs */
.trust-row {
  display: flex; flex-wrap: wrap; justify-content: center; gap: 2.2rem;
  margin-top: 3rem; padding-top: 2rem; border-top: 1px solid var(--line);
}
.trust-row .stat { text-align: center; }
.trust-row .stat b { display: block; font-family: 'Space Grotesk', sans-serif; font-size: 1.7rem; color: var(--gold-2); }
.trust-row .stat span { font-size: 0.8rem; letter-spacing: 0.12em; text-transform: uppercase; color: var(--text-mute); }

/* ============================================================
   SURFACES / CARDS
   ============================================================ */
.card {
  background: var(--paper);
  border: 1px solid var(--card-line);
  border-radius: var(--r-lg);
  padding: 2.75rem;
  margin: 2rem 0;
  box-shadow: var(--sh-card);
  color: var(--text-dark-2);
}
.card h1, .card h2, .card h3, .card h4 { color: var(--text-dark); }
.card p { color: var(--text-dark-2); }
.card .section-title { color: var(--text-dark); }
.card .eyebrow { color: #9a7b1f; }
.card > h2:first-child, .card .card-head { text-align: center; }

/* Section wrapper helper */
.section { margin: 4.5rem 0; text-align: center; }

/* ============================================================
   FEATURES
   ============================================================ */
.features-grid {
  display: grid; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 1.5rem; margin: 3rem 0 0; text-align: left;
}
.feature-card {
  background: var(--paper);
  border: 1px solid var(--card-line); border-radius: var(--r-lg);
  padding: 2.2rem; transition: transform .35s var(--ease), border-color .3s var(--ease), box-shadow .35s var(--ease);
  position: relative; overflow: hidden; color: var(--text-dark-2);
}
.feature-card::after {
  content: ""; position: absolute; inset: 0; border-radius: inherit; pointer-events: none;
  background: radial-gradient(420px 160px at 90% -20%, rgba(201,162,75,.08), transparent 60%);
}
.feature-card:hover { transform: translateY(-6px); border-color: var(--gold-line); box-shadow: var(--sh-card); }
.feature-icon {
  width: 58px; height: 58px; border-radius: 14px; margin-bottom: 1.4rem;
  display: grid; place-items: center;
  background: linear-gradient(160deg, var(--gold-2), var(--gold));
  box-shadow: 0 10px 24px rgba(201,162,75,.30), inset 0 1px 0 rgba(255,255,255,.45);
}
.feature-icon svg { width: 28px; height: 28px; color: #1a1406; }
.feature-card h3 { color: var(--text-dark); font-size: 1.18rem; margin-bottom: 0.55rem; letter-spacing: -0.01em; }
.feature-card p { color: var(--text-dark-2); font-size: 0.96rem; line-height: 1.6; }

/* ============================================================
   BEFORE / AFTER COMPARISON
   ============================================================ */
.comparison {
  display: grid; grid-template-columns: 1fr auto 1fr; align-items: stretch;
  gap: 1.25rem; margin: 2.5rem 0 0; text-align: left;
}
.compare-card {
  border-radius: var(--r); padding: 1.6rem; border: 1px solid var(--line);
  display: flex; flex-direction: column;
}
.compare-card .tag {
  display: inline-flex; align-items: center; gap: 0.5rem; align-self: flex-start;
  font-size: 0.72rem; font-weight: 800; letter-spacing: 0.14em; text-transform: uppercase;
  padding: 5px 11px; border-radius: 999px; margin-bottom: 1rem;
}
.compare-before { background: var(--paper-2); }
.compare-before .tag { background: #e9edf4; color: var(--text-dark-2); }
.compare-after {
  background: linear-gradient(180deg, #fbf3da, #fffaf0);
  border-color: var(--gold-line);
}
.compare-after .tag { background: var(--gold); color: var(--ink); }
.compare-card .example-text {
  font-family: 'Manrope', sans-serif; color: var(--text-dark); font-size: 0.96rem; line-height: 1.7;
  background: #fff; border: 1px solid var(--card-line); border-radius: 12px; padding: 1.1rem 1.2rem;
}
.compare-after .example-text { color: #5c4a1c; background: #fffdf7; border-color: var(--gold-line); }
.compare-arrow {
  align-self: center; display: grid; place-items: center;
  width: 52px; height: 52px; border-radius: 50%;
  background: linear-gradient(160deg, var(--gold-2), var(--gold)); color: var(--ink);
  font-weight: 900; box-shadow: var(--sh-gold);
}
.compare-arrow svg { width: 24px; height: 24px; }

.draft-warning {
  margin-top: 2rem; padding: 1.1rem 1.3rem; border-radius: 12px;
  background: #fdf6e1; border: 1px solid var(--gold-line); color: #6b5618;
  font-size: 0.9rem; font-weight: 600; display: flex; gap: 0.7rem; align-items: flex-start;
}
.compare-card .tag, .draft-warning strong { color: inherit; }

/* ============================================================
   PRICING
   ============================================================ */
.pricing-grid {
  display: grid; grid-template-columns: repeat(auto-fit, minmax(255px, 1fr));
  gap: 1.5rem; margin: 3rem 0;
}
.pricing-card {
  position: relative; text-align: center; padding: 2.5rem 1.9rem;
  background: var(--paper);
  border: 1px solid var(--card-line); border-radius: var(--r-lg);
  color: var(--text-dark-2); box-shadow: var(--sh-card);
  transition: transform .35s var(--ease), border-color .3s var(--ease), box-shadow .35s var(--ease);
}
.pricing-card:hover { transform: translateY(-8px); border-color: var(--gold-line); box-shadow: var(--sh-lg); }
.pricing-card.popular {
  border-color: var(--gold);
  background: linear-gradient(180deg, #fffdf7, #ffffff);
  box-shadow: 0 24px 60px rgba(201,162,75,.22);
}
.pricing-card.popular::before {
  content: ""; position: absolute; inset: 0; border-radius: inherit; padding: 1px; pointer-events: none;
  background: linear-gradient(180deg, var(--gold), transparent 60%);
  -webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0);
  -webkit-mask-composite: xor; mask-composite: exclude;
}
.tier-icon {
  width: 48px; height: 48px; margin: 0 auto 1.1rem; border-radius: 12px;
  display: grid; place-items: center;
  background: var(--gold-soft); border: 1px solid var(--gold-line);
}
.tier-icon svg { width: 24px; height: 24px; color: var(--gold-2); }
.pricing-card h3 { color: var(--text-dark); font-size: 1.15rem; letter-spacing: 0.01em; margin-bottom: 0.4rem; }
.popular-badge {
  position: absolute; top: -13px; left: 50%; transform: translateX(-50%);
  background: linear-gradient(135deg, var(--gold-2), var(--gold)); color: var(--ink);
  padding: 6px 18px; border-radius: 999px; font-size: 0.72rem; font-weight: 900;
  letter-spacing: 0.1em; text-transform: uppercase; box-shadow: 0 8px 20px rgba(201,162,75,.35);
}
.price { font-family: 'Space Grotesk', sans-serif; font-size: 2.6rem; font-weight: 700; color: var(--text-dark); margin: 0.6rem 0; }
.price span { font-size: 0.95rem; color: #8a93a5; font-weight: 600; }
.pricing-card > p { color: #8a93a5; font-size: 0.9rem; }
.pricing-card ul { list-style: none; text-align: left; margin: 1.8rem 0; padding: 0; }
.pricing-card li { color: var(--text-dark-2); padding: 0.6rem 0 0.6rem 1.8rem; position: relative; border-bottom: 1px solid var(--card-line); font-size: 0.93rem; }
.pricing-card li:last-child { border-bottom: none; }
.pricing-card li::before {
  content: ""; position: absolute; left: 0; top: 0.95rem; width: 14px; height: 8px;
  border-left: 2px solid var(--gold-2); border-bottom: 2px solid var(--gold-2);
  transform: rotate(-45deg);
}

/* ============================================================
   AUTH / FORMS
   ============================================================ */
.auth-container { display: flex; justify-content: center; align-items: center; min-height: 78vh; padding: 2.5rem 0; }
.auth-box {
  width: 100%; max-width: 440px; padding: 2.75rem;
  background: var(--paper);
  border: 1px solid var(--card-line); border-top: 3px solid var(--gold);
  border-radius: var(--r-lg); box-shadow: var(--sh-lg); color: var(--text-dark-2);
}
.auth-box h2 { color: var(--text-dark); margin-bottom: 0.4rem; }
.auth-box > p { color: var(--text-dark-2); font-size: 0.95rem; margin-bottom: 1.5rem; }

.form-group { margin-bottom: 1.3rem; }
.form-group label {
  display: block; margin-bottom: 0.55rem; color: var(--text-dark-2);
  font-weight: 600; font-size: 0.82rem; letter-spacing: 0.04em; text-transform: uppercase;
}
.form-control {
  width: 100%; padding: 13px 16px; font-size: 1rem; color: var(--text-dark);
  background: var(--paper-2); border: 1px solid var(--card-line); border-radius: 12px;
  transition: border-color .2s var(--ease), box-shadow .2s var(--ease), background .2s var(--ease);
}
.form-control::placeholder { color: #9aa3b2; }
.form-control:focus { outline: none; border-color: var(--gold); background: #fff; box-shadow: 0 0 0 4px var(--gold-soft); }
.textarea { min-height: 160px; resize: vertical; font-family: inherit; }
.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 1.2rem; }

.checkbox-group { margin: 1.4rem 0; list-style: none; }
.checkbox-item {
  display: flex; align-items: flex-start; gap: 0.8rem; margin-bottom: 0.8rem;
  padding: 0.85rem 1rem; background: var(--paper-2); border: 1px solid var(--card-line); border-radius: 12px;
}
.checkbox-item input[type="checkbox"] { width: 20px; height: 20px; margin-top: 2px; accent-color: var(--gold); cursor: pointer; }
.checkbox-item label { color: var(--text-dark); cursor: pointer; font-weight: 500; }
.explanation-box {
  background: #fdf6e1; border: 1px solid var(--gold-line); border-radius: 10px;
  padding: 12px; font-size: 0.85rem; color: #6b5618; width: 220px; margin-left: auto;
}

/* ============================================================
   REPORTS
   ============================================================ */
.report-item {
  background: var(--paper);
  border: 1px solid var(--card-line); border-left: 3px solid var(--gold);
  border-radius: var(--r); padding: 1.6rem; margin-bottom: 1.25rem; color: var(--text-dark-2);
  transition: transform .3s var(--ease), box-shadow .3s var(--ease);
}
.report-item:hover { transform: translateY(-3px); box-shadow: var(--sh-card); }
.report-item strong { color: var(--text-dark); }
.report-meta { display: flex; justify-content: space-between; align-items: center; margin-bottom: 1rem; padding-bottom: 1rem; border-bottom: 1px solid var(--card-line); }
.status-complete, .status-draft {
  padding: 5px 13px; border-radius: 999px; font-size: 0.74rem; font-weight: 800;
  letter-spacing: 0.05em; text-transform: uppercase;
}
.status-complete { background: rgba(67,160,108,.18); color: #7fe3a6; }
.status-draft { background: var(--gold-soft); color: var(--gold-3); }

.generated-report {
  display: none; margin-top: 2rem; padding: 2.5rem;
  background: var(--paper); color: var(--text-dark); border-radius: var(--r);
  border-top: 4px solid var(--gold); font-family: Georgia, serif; line-height: 1.85;
  box-shadow: var(--sh-card);
}
.generated-report.show { display: block; }

.usage-display {
  background: #fdf6e1;
  border: 1px solid var(--gold-line); border-left: 3px solid var(--gold);
  color: #6b5618; padding: 1.25rem; border-radius: 12px; text-align: center; margin: 1.5rem 0; font-weight: 600;
}
.upgrade-prompt {
  background: linear-gradient(135deg, var(--gold-2), var(--gold)); color: var(--ink);
  padding: 1.4rem; border-radius: 12px; text-align: center; margin: 1.5rem 0; font-weight: 800;
  letter-spacing: 0.02em; box-shadow: var(--sh-gold);
}

/* ============================================================
   FOOTER
   ============================================================ */
.footer {
  background: linear-gradient(180deg, transparent, rgba(0,0,0,.4));
  border-top: 1px solid var(--line);
  color: var(--text-dim); text-align: center; padding: 3.5rem 0 2.5rem; margin-top: 5rem;
}
.footer-brand { display: inline-flex; align-items: center; gap: 0.6rem; margin-bottom: 1.4rem; }
.footer-brand .logo-mark { width: 30px; height: 30px; flex-basis: 30px; }
.footer-brand .logo-mark svg { width: 17px; height: 17px; }
.footer-brand span { font-family: 'Space Grotesk', sans-serif; font-weight: 700; letter-spacing: 0.14em; color: #fff; text-transform: uppercase; }
.footer-links { display: flex; justify-content: center; gap: 2.2rem; margin-bottom: 1.4rem; flex-wrap: wrap; }
.footer-links a { color: var(--text-dim); font-weight: 600; font-size: 0.92rem; transition: color .2s var(--ease); }
.footer-links a:hover { color: var(--gold-2); }
.footer p { color: var(--text-mute); font-size: 0.88rem; }

/* ============================================================
   LOADING / SPINNER
   ============================================================ */
.loading { display: none; text-align: center; margin: 1.5rem 0; }
.loading.show { display: block; }
.spinner { width: 42px; height: 42px; margin: 0 auto; border: 3px solid var(--line-strong); border-top-color: var(--gold); border-radius: 50%; animation: spin 1s linear infinite; }

/* ============================================================
   CHAT WIDGET
   ============================================================ */
.chat-widget { position: fixed; bottom: 22px; right: 22px; z-index: 1000; }
.chat-bubble {
  width: 60px; height: 60px; border-radius: 50%; display: grid; place-items: center;
  background: linear-gradient(160deg, var(--gold-2), var(--gold)); color: var(--ink);
  font-size: 1.5rem; cursor: pointer; box-shadow: var(--sh-gold); transition: transform .25s var(--ease);
}
.chat-bubble:hover { transform: scale(1.08); }
.chat-window {
  position: fixed; bottom: 92px; right: 22px; width: 350px; height: 450px;
  background: var(--surface); border: 1px solid var(--line); border-top: 3px solid var(--gold);
  border-radius: 16px; box-shadow: var(--sh-lg); display: none; flex-direction: column; overflow: hidden;
}
.chat-header { background: linear-gradient(135deg, var(--surface-2), var(--surface)); color: #fff; padding: 1rem 1.2rem; font-weight: 700; letter-spacing: 0.04em; }
.chat-messages { flex: 1; padding: 1rem; overflow-y: auto; }
.chat-input { display: flex; padding: 0.9rem; border-top: 1px solid var(--line); gap: 0.5rem; }
.chat-input input { flex: 1; padding: 10px 12px; border: 1px solid var(--line-strong); border-radius: 10px; background: rgba(0,0,0,.25); color: #fff; }

/* ============================================================
   LEGAL / PAYMENT / ADMIN (kept readable on dark)
   ============================================================ */
.legal-page, .payment-result-page, .admin-panel {
  background: linear-gradient(180deg, var(--surface), var(--surface-2));
  border: 1px solid var(--line); border-radius: var(--r-lg);
  padding: 2.75rem; margin: 2rem 0; color: var(--text-dim); line-height: 1.8;
}
.legal-page h1, .payment-result-page h1, .admin-panel h1 { color: #fff; margin-bottom: 1rem; }
.legal-page h2 { color: var(--gold-2); margin: 2rem 0 1rem; }
.legal-page ul { margin: 1rem 0 1rem 1.4rem; }
.payment-result-page { max-width: 640px; margin: 2.5rem auto; text-align: center; }
.payment-result-content { padding: 1rem; }
.success-message { color: #7fe3a6; font-size: 1.15rem; font-weight: 700; margin-bottom: 1.5rem; }
.cancel-message { color: var(--text-dim); font-size: 1.1rem; margin-bottom: 1.5rem; }
.benefits-box, .trial-reminder, .upgrade-options, .next-steps, .help-section, .receipt-info {
  background: var(--glass); border: 1px solid var(--line); border-radius: 14px;
  padding: 1.6rem; margin: 1.5rem 0; text-align: left;
}
.benefits-box h3, .trial-reminder h3, .upgrade-options h3, .next-steps h3, .help-section h3 { color: var(--gold-2); margin-bottom: 0.8rem; text-align: center; }
.benefits-box ul, .trial-reminder ul { list-style: none; padding: 0; }
.benefits-box li, .trial-reminder li { padding: 0.45rem 0; color: var(--text-dim); }
.action-buttons { display: flex; gap: 1rem; justify-content: center; margin-top: 1.5rem; flex-wrap: wrap; }
.admin-stats { display: grid; grid-template-columns: repeat(auto-fit, minmax(180px,1fr)); gap: 1rem; margin: 1.5rem 0; }
.stat-card { background: linear-gradient(160deg, var(--gold-2), var(--gold)); color: var(--ink); padding: 1.5rem; border-radius: 14px; text-align: center; }
.stat-card h3 { color: var(--ink); font-size: 1.9rem; margin-bottom: 0.25rem; }
.admin-table { width: 100%; border-collapse: collapse; border-radius: 12px; overflow: hidden; }
.admin-table th, .admin-table td { padding: 0.9rem; text-align: left; border-bottom: 1px solid var(--line); color: var(--text-dim); }
.admin-table th { background: rgba(0,0,0,.25); color: #fff; }

/* Misc helpers used inline in markup */
.verification-message { background: linear-gradient(135deg, var(--surface-2), var(--surface)); border: 1px solid var(--gold-line); color: var(--text); padding: 1rem; border-radius: 12px; text-align: center; }
.security-warning { background: rgba(127,29,29,.25); border: 1px solid rgba(168,50,50,.5); color: #ffb4b4; padding: 1rem; border-radius: 12px; text-align: center; font-weight: 700; margin-bottom: 1.5rem; }

/* ============================================================
   ANIMATIONS
   ============================================================ */
@keyframes fadeIn { from { opacity: 0; transform: translateY(12px); } to { opacity: 1; transform: translateY(0); } }
@keyframes spin { to { transform: rotate(360deg); } }
@keyframes slideInDown { from { opacity: 0; transform: translate3d(0,-100%,0); } to { opacity: 1; transform: translate3d(0,0,0); } }
@keyframes bounceIn { 0% { transform: scale(.3); opacity: 0; } 50% { transform: scale(1.05); } 70% { transform: scale(.9); } 100% { transform: scale(1); opacity: 1; } }

/* ============================================================
   RESPONSIVE
   ============================================================ */
@media (max-width: 880px) {
  .comparison { grid-template-columns: 1fr; }
  .compare-arrow { transform: rotate(90deg); margin: -0.3rem auto; }
}
@media (max-width: 768px) {
  .mobile-menu-toggle { display: inline-flex !important; }
  .nav-links {
    position: absolute; top: 100%; left: 0; right: 0; flex-direction: column; align-items: stretch;
    background: rgba(8,12,22,.97); backdrop-filter: blur(12px); padding: 1rem;
    border-bottom: 1px solid var(--line);
    transform: translateY(-12px); opacity: 0; visibility: hidden; transition: all .3s var(--ease);
  }
  .nav-links.active { transform: translateY(0); opacity: 1; visibility: visible; }
  .nav-links a.active::after { display: none; }
  .form-row, .pricing-grid { grid-template-columns: 1fr; }
  .hero { padding: 4rem 1.4rem; }
  .card { padding: 1.6rem; }
  .auth-box { padding: 1.8rem; margin: 1rem; }
  .chat-window { width: calc(100vw - 44px); height: 60vh; }
  .trust-row { gap: 1.4rem; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .01ms !important; animation-iteration-count: 1 !important; transition-duration: .01ms !important; scroll-behavior: auto !important; }
}
