/* ============================================================================
   Lead Recovery Desk, design system
   Sharp, premium dark UI. Near black charcoal base, warm gold/ember accent.
   Editorial display type (Fraunces) over a confident grotesque body (Archivo).
   All visible copy avoids dashes per the build contract. Hyphens here are code.
   ========================================================================== */

@import url("https://fonts.googleapis.com/css2?family=Fraunces:opsz,wght@9..144,400;9..144,500;9..144,600;9..144,700&family=Archivo:wght@400;500;600;700&family=JetBrains+Mono:wght@400;500&display=swap");

/* ---------------------------------------------------------------- tokens -- */
:root {
  /* surfaces: layered near black with a faint warm cast */
  --bg:           #0b0a08;
  --bg-deep:      #070605;
  --surface:      #141210;
  --surface-2:    #1b1815;
  --surface-3:    #232019;
  --raised:       #1e1b16;

  /* lines */
  --line:         #2b2720;
  --line-strong:  #3a352b;
  --line-gold:    rgba(245, 177, 60, 0.28);

  /* ink */
  --ink:          #f4efe6;
  --ink-soft:     #c8c0b1;
  --ink-mute:     #8c8475;
  --ink-faint:    #877f72;

  /* accent: warm gold / ember */
  --gold:         #f5b13c;
  --gold-bright:  #ffc457;
  --gold-deep:    #c98a23;
  --ember:        #e8632a;
  --gold-glow:    rgba(245, 177, 60, 0.16);
  --gold-wash:    rgba(245, 177, 60, 0.08);

  /* segment + status palette (warm to cold spectrum) */
  --seg-warm:     #ff8a3d;   /* hottest leads */
  --seg-warm-bg:  rgba(255, 138, 61, 0.14);
  --seg-luke:     #f5b13c;   /* lukewarm */
  --seg-luke-bg:  rgba(245, 177, 60, 0.13);
  --seg-cold:     #6ea2c9;   /* cold, gone quiet */
  --seg-cold-bg:  rgba(110, 162, 201, 0.14);
  --seg-supp:     #8c8475;   /* suppressed, do not contact */
  --seg-supp-bg:  rgba(140, 132, 117, 0.12);

  /* semantic */
  --ok:           #5fbf8f;
  --ok-bg:        rgba(95, 191, 143, 0.13);
  --warn:         #e8a13c;
  --warn-bg:      rgba(232, 161, 60, 0.13);
  --danger:       #e2674f;
  --danger-bg:    rgba(226, 103, 79, 0.13);
  --info:         #6ea2c9;
  --info-bg:      rgba(110, 162, 201, 0.13);

  /* type */
  --font-display: "Fraunces", Georgia, serif;
  --font-body:    "Archivo", system-ui, sans-serif;
  --font-mono:    "JetBrains Mono", ui-monospace, monospace;

  /* shape + motion */
  --r-sm: 8px;
  --r:    12px;
  --r-lg: 18px;
  --r-pill: 999px;
  --shadow:    0 1px 0 rgba(255,255,255,0.02) inset, 0 18px 40px rgba(0,0,0,0.45);
  --shadow-lg: 0 1px 0 rgba(255,255,255,0.03) inset, 0 30px 70px rgba(0,0,0,0.6);
  --ring: 0 0 0 3px rgba(245, 177, 60, 0.35);
  --ease: cubic-bezier(0.22, 0.61, 0.36, 1);

  --nav-h: 66px;
  --maxw: 1140px;
}

/* --------------------------------------------------------- skip link -- */
/* Hidden until focused via keyboard; jumps to the main content landmark. */
.skip-link {
  position: absolute;
  top: 0;
  left: 0;
  z-index: 9999;
  padding: 10px 18px;
  background: var(--gold);
  color: #1a1304;
  font-family: var(--font-body);
  font-size: 0.95rem;
  font-weight: 700;
  border-radius: 0 0 var(--r-sm) 0;
  transform: translateY(-100%);
  transition: transform 0.15s var(--ease);
  text-decoration: none;
  white-space: nowrap;
}
.skip-link:focus { transform: translateY(0); outline: 3px solid #1a1304; outline-offset: 2px; }

/* ---------------------------------------------------------------- reset -- */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body {
  margin: 0;
  min-height: 100vh;
  font-family: var(--font-body);
  font-size: 16px;
  line-height: 1.55;
  color: var(--ink);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  overflow-x: hidden;
}

/* atmosphere: a faint warm radial glow up top plus a fine grain overlay.
   Both are decorative, sit behind everything, and never block input. */
body::before {
  content: "";
  position: fixed;
  inset: 0;
  z-index: -2;
  background:
    radial-gradient(1100px 520px at 78% -8%, var(--gold-glow), transparent 60%),
    radial-gradient(900px 600px at 8% 4%, rgba(232, 99, 42, 0.06), transparent 55%),
    var(--bg);
}
body::after {
  content: "";
  position: fixed;
  inset: 0;
  z-index: -1;
  pointer-events: none;
  opacity: 0.5;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='180' height='180'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.85' numOctaves='2' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)' opacity='0.035'/%3E%3C/svg%3E");
}

img, svg { display: block; max-width: 100%; }
a { color: inherit; text-decoration: none; }
a:focus-visible { outline: 2px solid var(--gold); outline-offset: 2px; border-radius: 2px; }
/* Inline links inside running text carry an underline so they are not
   distinguished by color alone (WCAG 1.4.1). Buttons and chrome links opt out. */
.callout a:not(.btn):not(.btn-link), .lede a:not(.btn):not(.btn-link),
.muted a:not(.btn):not(.btn-link), .hint a:not(.btn):not(.btn-link),
main p a:not(.btn):not(.btn-link), main li a:not(.btn):not(.btn-link),
main dd a:not(.btn):not(.btn-link) { text-decoration: underline; text-underline-offset: 2px; }
/* Screen reader only utility. */
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0,0,0,0); white-space: nowrap; border: 0; }
button { font-family: inherit; }
/* Ensure focus outlines are never suppressed by custom cursor or other overrides */
:focus-visible { outline-color: var(--gold); }

::selection { background: var(--gold); color: #1a1304; }

/* scrollbars */
* { scrollbar-width: thin; scrollbar-color: var(--line-strong) transparent; }
*::-webkit-scrollbar { width: 10px; height: 10px; }
*::-webkit-scrollbar-thumb { background: var(--line-strong); border-radius: 999px; border: 2px solid var(--bg); }

/* ---------------------------------------------------------- typography -- */
h1, h2, h3, h4 { font-family: var(--font-display); font-weight: 600; line-height: 1.08; letter-spacing: -0.01em; margin: 0; color: var(--ink); }
h1 { font-size: clamp(2rem, 4.4vw, 3.1rem); font-weight: 600; }
h2 { font-size: clamp(1.5rem, 2.6vw, 2.05rem); }
h3 { font-size: 1.28rem; }
h4 { font-size: 1.05rem; font-family: var(--font-body); font-weight: 600; letter-spacing: 0; }
p  { margin: 0 0 1rem; color: var(--ink-soft); }

.eyebrow {
  font-family: var(--font-mono);
  font-size: 0.72rem;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--gold);
  font-weight: 500;
  margin: 0 0 0.75rem;
}
.lede { font-size: 1.12rem; color: var(--ink-soft); max-width: 56ch; }
.muted { color: var(--ink-mute); }
.faint { color: var(--ink-faint); }
.mono { font-family: var(--font-mono); }
.serif { font-family: var(--font-display); }
.nowrap { white-space: nowrap; }
.center { text-align: center; }
small { font-size: 0.82rem; }

/* ------------------------------------------------------------- layout -- */
.shell { display: flex; flex-direction: column; min-height: 100vh; }
.page { width: 100%; max-width: var(--maxw); margin: 0 auto; padding: 40px 24px 96px; flex: 1; }
.page-narrow { max-width: 760px; }
.page-wide { max-width: 1320px; }

.page-head { margin-bottom: 32px; }
.page-head h1 { margin-bottom: 6px; }

.section { margin-top: 44px; }
.section-head { display: flex; align-items: baseline; justify-content: space-between; gap: 16px; margin-bottom: 18px; flex-wrap: wrap; }
.section-head h2 { font-size: 1.4rem; }

.stack   { display: flex; flex-direction: column; gap: 16px; }
.stack-sm{ display: flex; flex-direction: column; gap: 8px; }
.row     { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; }
.row-between { display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap; }
.spacer  { flex: 1; }

.grid { display: grid; gap: 20px; }
.grid-2 { grid-template-columns: repeat(2, 1fr); }
.grid-3 { grid-template-columns: repeat(3, 1fr); }
.grid-4 { grid-template-columns: repeat(4, 1fr); }
.grid-auto { grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); }
@media (max-width: 860px) {
  .grid-2, .grid-3, .grid-4 { grid-template-columns: 1fr; }
  .grid-auto { grid-template-columns: 1fr; }
}

/* ---------------------------------------------------------------- nav -- */
.nav {
  position: sticky; top: 0; z-index: 50;
  height: var(--nav-h);
  display: flex; align-items: center; gap: 22px;
  padding: 0 24px;
  background: color-mix(in srgb, var(--bg-deep) 82%, transparent);
  backdrop-filter: blur(14px) saturate(1.2);
  -webkit-backdrop-filter: blur(14px) saturate(1.2);
  border-bottom: 1px solid var(--line);
}
.nav-inner { width: 100%; max-width: var(--maxw); margin: 0 auto; display: flex; align-items: center; gap: 22px; }
.brand { display: inline-flex; align-items: center; gap: 11px; font-family: var(--font-display); font-weight: 600; font-size: 1.12rem; letter-spacing: -0.01em; color: var(--ink); border-radius: var(--r-sm); }
.brand:focus-visible { outline: none; box-shadow: var(--ring); }
.brand-mark {
  width: 30px; height: 30px; flex: none;
  display: grid; place-items: center;
  border-radius: 9px;
  background: linear-gradient(150deg, var(--gold-bright), var(--gold-deep));
  color: #1a1304;
  font-family: var(--font-display); font-weight: 700; font-size: 1rem;
  box-shadow: 0 4px 14px rgba(245, 177, 60, 0.32), 0 0 0 1px rgba(255,255,255,0.12) inset;
}
.brand-mark svg { width: 17px; height: 17px; }
.brand small { display: block; font-family: var(--font-mono); font-size: 0.6rem; letter-spacing: 0.18em; color: var(--ink-mute); text-transform: uppercase; line-height: 1; margin-top: 2px; }

.nav-links { display: flex; align-items: center; gap: 4px; margin-left: 14px; }
.nav-link {
  position: relative;
  padding: 8px 12px;
  border-radius: var(--r-sm);
  color: var(--ink-mute);
  font-size: 0.92rem; font-weight: 500;
  transition: color 0.18s var(--ease), background 0.18s var(--ease);
}
.nav-link:hover { color: var(--ink); background: var(--surface-2); }
.nav-link:focus-visible { outline: none; box-shadow: var(--ring); color: var(--ink); background: var(--surface-2); }
.nav-link.is-active { color: var(--gold); }
.nav-link.is-active::after {
  content: ""; position: absolute; left: 12px; right: 12px; bottom: -1px; height: 2px;
  background: var(--gold); border-radius: 2px;
}
.nav-right { margin-left: auto; display: flex; align-items: center; gap: 12px; }
.nav-acct { display: none; font-size: 0.84rem; color: var(--ink-mute); }
@media (min-width: 720px) { .nav-acct { display: inline; } }

/* mobile nav toggle */
.nav-toggle { display: none; }
@media (max-width: 720px) {
  .nav-links {
    position: absolute; top: var(--nav-h); left: 0; right: 0;
    flex-direction: column; align-items: stretch; gap: 2px;
    margin: 0; padding: 10px;
    background: var(--bg-deep); border-bottom: 1px solid var(--line);
    transform: translateY(-8px); opacity: 0; pointer-events: none;
    transition: opacity 0.18s var(--ease), transform 0.18s var(--ease);
  }
  .nav.is-open .nav-links { transform: translateY(0); opacity: 1; pointer-events: auto; }
  .nav-link.is-active::after { display: none; }
  .nav-link.is-active { background: var(--surface-2); }
  .nav-toggle {
    display: grid; place-items: center; margin-left: auto;
    /* 44px minimum tap target for mobile accessibility */
    width: 44px; height: 44px; border-radius: var(--r-sm);
    background: var(--surface-2); border: 1px solid var(--line); color: var(--ink); cursor: pointer;
  }
  .nav-toggle:focus-visible { outline: none; box-shadow: var(--ring); }
}

/* ------------------------------------------------------------- buttons -- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 9px;
  padding: 11px 20px;
  border: 1px solid transparent;
  border-radius: var(--r-sm);
  font-family: var(--font-body); font-size: 0.95rem; font-weight: 600;
  line-height: 1; letter-spacing: 0.005em;
  cursor: pointer; user-select: none; white-space: nowrap;
  transition: transform 0.12s var(--ease), background 0.18s var(--ease), border-color 0.18s var(--ease), box-shadow 0.18s var(--ease), color 0.18s var(--ease);
}
.btn:active { transform: translateY(1px); }
.btn:focus-visible { outline: none; box-shadow: var(--ring); }
.btn svg { width: 17px; height: 17px; }

.btn-primary {
  background: linear-gradient(150deg, var(--gold-bright), var(--gold-deep));
  color: #1a1304;
  box-shadow: 0 8px 22px rgba(245, 177, 60, 0.26), 0 0 0 1px rgba(255,255,255,0.14) inset;
}
.btn-primary:hover { box-shadow: 0 12px 30px rgba(245, 177, 60, 0.4), 0 0 0 1px rgba(255,255,255,0.2) inset; transform: translateY(-1px); }

.btn-ghost { background: var(--surface-2); color: var(--ink); border-color: var(--line); }
.btn-ghost:hover { background: var(--surface-3); border-color: var(--line-strong); }

.btn-outline { background: transparent; color: var(--ink); border-color: var(--line-strong); }
.btn-outline:hover { border-color: var(--gold); color: var(--gold); }

.btn-gold-quiet { background: var(--gold-wash); color: var(--gold-bright); border-color: var(--line-gold); }
.btn-gold-quiet:hover { background: var(--gold-glow); border-color: var(--gold); }

.btn-danger { background: var(--danger-bg); color: var(--danger); border-color: rgba(226,103,79,0.3); }
.btn-danger:hover { background: rgba(226,103,79,0.22); }

.btn-sm { padding: 8px 14px; font-size: 0.86rem; }
.btn-lg { padding: 14px 26px; font-size: 1.02rem; }
.btn-block { width: 100%; }
.btn[disabled], .btn.is-disabled { opacity: 0.5; cursor: not-allowed; pointer-events: none; }
.btn.is-loading { color: transparent; position: relative; pointer-events: none; }
.btn.is-loading::after {
  content: ""; position: absolute; width: 16px; height: 16px;
  border: 2px solid currentColor; border-top-color: transparent; border-radius: 50%;
  color: #1a1304; animation: spin 0.6s linear infinite;
}
.btn-ghost.is-loading::after, .btn-outline.is-loading::after { color: var(--ink); }

.btn-link { background: none; border: none; padding: 0; color: var(--gold); font-weight: 600; cursor: pointer; }
.btn-link:hover { color: var(--gold-bright); text-decoration: underline; text-underline-offset: 3px; }
.btn-link:focus-visible { outline: 2px solid var(--gold); outline-offset: 2px; border-radius: 2px; }

@keyframes spin { to { transform: rotate(360deg); } }

/* --------------------------------------------------------------- cards -- */
.card {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--r);
  padding: 24px;
  box-shadow: var(--shadow);
}
.card-pad-lg { padding: 32px; }
.card-tight { padding: 18px; }
.card-flush { padding: 0; overflow: hidden; }
.card-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 14px; margin-bottom: 16px; }
.card-head h3, .card-head h4 { margin: 0; }
.card-foot { margin-top: 18px; padding-top: 16px; border-top: 1px solid var(--line); display: flex; align-items: center; gap: 12px; }

/* interactive / step cards used on the home desk */
.card-link { display: block; color: inherit; transition: transform 0.16s var(--ease), border-color 0.18s var(--ease), box-shadow 0.18s var(--ease); }
.card-link:hover { transform: translateY(-3px); border-color: var(--line-gold); box-shadow: var(--shadow-lg); }
.card-link:focus-visible { outline: none; border-color: var(--gold); box-shadow: var(--ring); }

.card-gold { border-color: var(--line-gold); background: linear-gradient(165deg, var(--surface), var(--gold-wash)); }
.card-accent-top { position: relative; overflow: hidden; }
.card-accent-top::before { content: ""; position: absolute; top: 0; left: 0; right: 0; height: 3px; background: linear-gradient(90deg, var(--ember), var(--gold)); }

/* locked state (needs purchase) */
.card.is-locked { opacity: 0.96; }
.card.is-locked .card-icon { filter: grayscale(0.5); opacity: 0.7; }

.card-icon {
  width: 46px; height: 46px; flex: none;
  display: grid; place-items: center;
  border-radius: var(--r-sm);
  background: var(--gold-wash); color: var(--gold);
  border: 1px solid var(--line-gold);
}
.card-icon svg { width: 22px; height: 22px; }
.card-icon.is-muted { background: var(--surface-3); color: var(--ink-mute); border-color: var(--line); }

/* ---------------------------------------------------- step / desk card -- */
.step {
  position: relative;
  display: flex; flex-direction: column; gap: 14px;
  height: 100%;
}
.step-top { display: flex; align-items: flex-start; gap: 14px; }
.step-no { font-family: var(--font-mono); font-size: 0.74rem; color: var(--ink-faint); letter-spacing: 0.1em; }
.step h3 { font-family: var(--font-body); font-size: 1.12rem; font-weight: 600; letter-spacing: 0; }
.step p { margin: 0; font-size: 0.92rem; color: var(--ink-mute); }
.step-foot { margin-top: auto; padding-top: 6px; }

/* ------------------------------------------------------------- badges -- */
.badge {
  display: inline-flex; align-items: center; gap: 6px;
  padding: 3px 10px;
  border-radius: var(--r-pill);
  font-family: var(--font-body); font-size: 0.74rem; font-weight: 600;
  letter-spacing: 0.02em; line-height: 1.4;
  border: 1px solid transparent; white-space: nowrap;
  text-transform: capitalize;
}
.badge::before { content: ""; width: 6px; height: 6px; border-radius: 50%; background: currentColor; flex: none; }
.badge-plain::before { display: none; }

/* segments */
.badge-warm       { color: var(--seg-warm); background: var(--seg-warm-bg); border-color: color-mix(in srgb, var(--seg-warm) 28%, transparent); }
.badge-lukewarm   { color: var(--seg-luke); background: var(--seg-luke-bg); border-color: color-mix(in srgb, var(--seg-luke) 28%, transparent); }
.badge-cold       { color: var(--seg-cold); background: var(--seg-cold-bg); border-color: color-mix(in srgb, var(--seg-cold) 28%, transparent); }
.badge-suppressed { color: var(--seg-supp); background: var(--seg-supp-bg); border-color: color-mix(in srgb, var(--seg-supp) 28%, transparent); }

/* statuses (lead lifecycle + generic) */
.badge-new       { color: var(--info); background: var(--info-bg); border-color: color-mix(in srgb, var(--info) 26%, transparent); }
.badge-queued    { color: var(--gold); background: var(--gold-wash); border-color: var(--line-gold); }
.badge-contacted { color: var(--gold-bright); background: var(--gold-glow); border-color: var(--line-gold); }
.badge-replied   { color: var(--seg-warm); background: var(--seg-warm-bg); border-color: color-mix(in srgb, var(--seg-warm) 28%, transparent); }
.badge-booked    { color: var(--ok); background: var(--ok-bg); border-color: color-mix(in srgb, var(--ok) 28%, transparent); }
.badge-won       { color: var(--ok); background: var(--ok-bg); border-color: color-mix(in srgb, var(--ok) 40%, transparent); }
.badge-closed    { color: var(--ink-mute); background: var(--surface-3); border-color: var(--line); }

/* generic semantic + states */
.badge-ok      { color: var(--ok); background: var(--ok-bg); border-color: color-mix(in srgb, var(--ok) 28%, transparent); }
.badge-warn    { color: var(--warn); background: var(--warn-bg); border-color: color-mix(in srgb, var(--warn) 28%, transparent); }
.badge-danger  { color: var(--danger); background: var(--danger-bg); border-color: color-mix(in srgb, var(--danger) 28%, transparent); }
.badge-info    { color: var(--info); background: var(--info-bg); border-color: color-mix(in srgb, var(--info) 26%, transparent); }
.badge-neutral { color: var(--ink-soft); background: var(--surface-3); border-color: var(--line); }
.badge-locked  { color: var(--ink-soft); background: var(--surface-3); border-color: var(--line); }
.badge-locked::before { display: none; }
.badge-unlocked{ color: var(--ok); background: var(--ok-bg); border-color: color-mix(in srgb, var(--ok) 28%, transparent); }

/* dryrun / live pill for the send engine */
.badge-dryrun { color: var(--info); background: var(--info-bg); border-color: color-mix(in srgb, var(--info) 26%, transparent); }
.badge-live   { color: var(--ember); background: rgba(232,99,42,0.14); border-color: color-mix(in srgb, var(--ember) 30%, transparent); }

/* small uppercase status pip used in tables */
.pip { display: inline-block; width: 8px; height: 8px; border-radius: 50%; background: var(--ink-mute); }
.pip-warm { background: var(--seg-warm); } .pip-lukewarm { background: var(--seg-luke); }
.pip-cold { background: var(--seg-cold); } .pip-suppressed { background: var(--seg-supp); }

/* --------------------------------------------------------- stat cards -- */
.stat {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--r);
  padding: 20px 22px;
  position: relative; overflow: hidden;
}
.stat-label { font-family: var(--font-mono); font-size: 0.7rem; letter-spacing: 0.16em; text-transform: uppercase; color: var(--ink-mute); margin-bottom: 10px; }
.stat-value { font-family: var(--font-display); font-size: 2.1rem; font-weight: 600; line-height: 1; color: var(--ink); letter-spacing: -0.02em; }
.stat-value.is-gold { color: var(--gold); }
.stat-sub { margin-top: 8px; font-size: 0.82rem; color: var(--ink-mute); }
.stat-delta { font-size: 0.8rem; font-weight: 600; }
.stat-delta.up { color: var(--ok); } .stat-delta.down { color: var(--danger); }
.stat-accent::after { content: ""; position: absolute; left: 0; top: 0; bottom: 0; width: 3px; background: var(--gold); }

/* --------------------------------------------------------------- forms -- */
.field { display: flex; flex-direction: column; gap: 7px; margin-bottom: 18px; }
.label { font-size: 0.86rem; font-weight: 600; color: var(--ink-soft); }
.label .req { color: var(--gold); }
.hint { font-size: 0.8rem; color: var(--ink-mute); }
.field-error { font-size: 0.82rem; color: var(--danger); min-height: 1em; }

.input, .select, .textarea {
  width: 100%;
  padding: 12px 14px;
  background: var(--bg-deep);
  border: 1px solid var(--line-strong);
  border-radius: var(--r-sm);
  color: var(--ink);
  font-family: var(--font-body); font-size: 0.96rem;
  transition: border-color 0.18s var(--ease), box-shadow 0.18s var(--ease), background 0.18s var(--ease);
}
.input::placeholder, .textarea::placeholder { color: var(--ink-faint); }
.input:hover, .select:hover, .textarea:hover { border-color: var(--ink-faint); }
.input:focus, .select:focus, .textarea:focus { outline: none; border-color: var(--gold); box-shadow: var(--ring); background: var(--bg); }
.input.has-error, .select.has-error, .textarea.has-error { border-color: var(--danger); }
.textarea { resize: vertical; min-height: 110px; line-height: 1.55; }
.select { appearance: none; background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' fill='none' stroke='%238c8475' stroke-width='1.6'%3E%3Cpath d='M1 1l5 5 5-5'/%3E%3C/svg%3E"); background-repeat: no-repeat; background-position: right 14px center; padding-right: 36px; }
.input-mono { font-family: var(--font-mono); letter-spacing: 0.01em; }

/* input adornment group (e.g. a leading icon or trailing button) */
.input-group { display: flex; }
.input-group .input { border-radius: var(--r-sm) 0 0 var(--r-sm); }
.input-group .btn { border-radius: 0 var(--r-sm) var(--r-sm) 0; }

/* checkbox / toggle */
.check { display: flex; align-items: flex-start; gap: 10px; cursor: pointer; font-size: 0.92rem; color: var(--ink-soft); }
.check input { width: 18px; height: 18px; margin-top: 2px; accent-color: var(--gold); flex: none; }

.toggle { position: relative; display: inline-flex; align-items: center; gap: 10px; cursor: pointer; }
.toggle input { position: absolute; opacity: 0; }
.toggle-track { width: 42px; height: 24px; border-radius: 999px; background: var(--surface-3); border: 1px solid var(--line-strong); transition: background 0.18s var(--ease), border-color 0.18s var(--ease); flex: none; }
.toggle-track::after { content: ""; position: absolute; top: 3px; left: 3px; width: 18px; height: 18px; border-radius: 50%; background: var(--ink-mute); transition: transform 0.18s var(--ease), background 0.18s var(--ease); }
.toggle input:checked + .toggle-track { background: var(--gold-wash); border-color: var(--line-gold); }
.toggle input:checked + .toggle-track::after { transform: translateX(18px); background: var(--gold); }
.toggle input:focus-visible + .toggle-track { box-shadow: var(--ring); }

/* segmented control / filter pills */
.segmented { display: inline-flex; padding: 3px; gap: 2px; background: var(--bg-deep); border: 1px solid var(--line); border-radius: var(--r-sm); }
.segmented button { padding: 7px 14px; border: none; background: none; color: var(--ink-mute); font-size: 0.86rem; font-weight: 600; border-radius: 6px; cursor: pointer; transition: background 0.16s var(--ease), color 0.16s var(--ease); }
.segmented button:hover { color: var(--ink); }
.segmented button.is-active { background: var(--surface-3); color: var(--gold); }
.segmented button:focus-visible { outline: none; box-shadow: var(--ring); }

/* --------------------------------------------------------------- table -- */
.table-wrap { width: 100%; overflow-x: auto; border: 1px solid var(--line); border-radius: var(--r); background: var(--surface); }
table.table { width: 100%; border-collapse: collapse; font-size: 0.92rem; min-width: 560px; }
.table thead th {
  text-align: left; padding: 13px 16px;
  font-family: var(--font-mono); font-size: 0.68rem; letter-spacing: 0.12em; text-transform: uppercase;
  color: var(--ink-mute); font-weight: 500;
  background: var(--bg-deep); border-bottom: 1px solid var(--line);
  position: sticky; top: 0;
}
/* sortable column headers are interactive; give them a visible focus ring */
.table thead th[data-sort] { cursor: pointer; }
.table thead th[data-sort]:focus-visible { outline: 2px solid var(--gold); outline-offset: -2px; }
.table tbody td { padding: 13px 16px; border-bottom: 1px solid var(--line); color: var(--ink-soft); vertical-align: middle; }
.table tbody tr { transition: background 0.14s var(--ease); }
.table tbody tr:hover { background: var(--surface-2); }
.table tbody tr:last-child td { border-bottom: none; }
.table td.num, .table th.num { text-align: right; font-variant-numeric: tabular-nums; font-family: var(--font-mono); }
.table .cell-strong { color: var(--ink); font-weight: 600; }
.table .cell-sub { color: var(--ink-mute); font-size: 0.82rem; }
.table-clickable tbody tr { cursor: pointer; }

/* ------------------------------------------------------------- divider -- */
.hr { height: 1px; background: var(--line); border: none; margin: 24px 0; }
.hr-faded { height: 1px; border: none; margin: 24px 0; background: linear-gradient(90deg, transparent, var(--line-strong), transparent); }
.dot-sep { color: var(--ink-faint); padding: 0 8px; }

/* --------------------------------------------------------------- modal -- */
.modal-backdrop {
  position: fixed; inset: 0; z-index: 100;
  display: flex; align-items: center; justify-content: center; padding: 20px;
  background: rgba(5,4,3,0.66); backdrop-filter: blur(4px);
  opacity: 0; pointer-events: none; transition: opacity 0.2s var(--ease);
}
.modal-backdrop.is-open { opacity: 1; pointer-events: auto; }
.modal {
  width: 100%; max-width: 500px;
  background: var(--surface); border: 1px solid var(--line-strong);
  border-radius: var(--r-lg); box-shadow: var(--shadow-lg);
  transform: translateY(10px) scale(0.98); transition: transform 0.22s var(--ease);
  max-height: 90vh; overflow-y: auto;
}
.modal-backdrop.is-open .modal { transform: translateY(0) scale(1); }
.modal-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 14px; padding: 22px 24px 0; }
.modal-head h3 { margin: 0; }
.modal-body { padding: 16px 24px; }
.modal-foot { padding: 16px 24px 22px; display: flex; gap: 10px; justify-content: flex-end; flex-wrap: wrap; }
.modal-close { width: 44px; height: 44px; border-radius: var(--r-sm); border: 1px solid var(--line); background: var(--surface-2); color: var(--ink-mute); cursor: pointer; display: grid; place-items: center; flex: none; }
.modal-close:hover { color: var(--ink); border-color: var(--line-strong); }
.modal-close:focus-visible { outline: none; box-shadow: var(--ring); }

/* --------------------------------------------------------------- toast -- */
.toast-host { position: fixed; top: 18px; right: 18px; z-index: 200; display: flex; flex-direction: column; gap: 10px; max-width: min(380px, calc(100vw - 36px)); }
.toast {
  display: flex; align-items: flex-start; gap: 11px;
  padding: 13px 15px;
  background: var(--surface-2); border: 1px solid var(--line-strong);
  border-left: 3px solid var(--gold);
  border-radius: var(--r-sm); box-shadow: var(--shadow);
  font-size: 0.9rem; color: var(--ink);
  transform: translateX(120%); opacity: 0;
  transition: transform 0.32s var(--ease), opacity 0.32s var(--ease);
}
.toast.is-in { transform: translateX(0); opacity: 1; }
.toast.is-out { transform: translateX(120%); opacity: 0; }
.toast-icon { flex: none; margin-top: 1px; }
.toast-ok      { border-left-color: var(--ok); }   .toast-ok .toast-icon { color: var(--ok); }
.toast-error   { border-left-color: var(--danger); } .toast-error .toast-icon { color: var(--danger); }
.toast-warn    { border-left-color: var(--warn); }  .toast-warn .toast-icon { color: var(--warn); }
.toast-info    { border-left-color: var(--info); }  .toast-info .toast-icon { color: var(--info); }

/* --------------------------------------------------------- empty state -- */
.empty {
  display: flex; flex-direction: column; align-items: center; text-align: center;
  padding: 56px 28px; gap: 6px;
  border: 1px dashed var(--line-strong); border-radius: var(--r);
  background: var(--surface);
}
.empty-icon { width: 56px; height: 56px; display: grid; place-items: center; border-radius: 14px; background: var(--gold-wash); color: var(--gold); border: 1px solid var(--line-gold); margin-bottom: 10px; }
.empty-icon svg { width: 26px; height: 26px; }
.empty h3 { font-family: var(--font-body); font-weight: 600; font-size: 1.1rem; }
.empty p { color: var(--ink-mute); max-width: 42ch; margin: 4px 0 14px; }

/* -------------------------------------------------------- skeleton load -- */
.skel { background: linear-gradient(90deg, var(--surface-2) 25%, var(--surface-3) 37%, var(--surface-2) 63%); background-size: 400% 100%; border-radius: 6px; animation: shimmer 1.3s ease infinite; }
.skel-line { height: 13px; margin: 8px 0; }
.skel-line.short { width: 50%; }
@keyframes shimmer { 0% { background-position: 100% 0; } 100% { background-position: -100% 0; } }

/* ----------------------------------------------------------- progress -- */
.steps-rail { display: flex; align-items: center; gap: 0; margin: 8px 0 24px; }
.steps-rail .node { display: flex; align-items: center; gap: 10px; }
.steps-rail .dot { width: 26px; height: 26px; border-radius: 50%; display: grid; place-items: center; font-family: var(--font-mono); font-size: 0.74rem; background: var(--surface-3); border: 1px solid var(--line-strong); color: var(--ink-mute); flex: none; }
.steps-rail .node.done .dot { background: var(--gold); border-color: var(--gold); color: #1a1304; }
.steps-rail .node.active .dot { border-color: var(--gold); color: var(--gold); box-shadow: var(--ring); }
.steps-rail .node .lbl { font-size: 0.84rem; color: var(--ink-mute); }
.steps-rail .node.active .lbl, .steps-rail .node.done .lbl { color: var(--ink); }
.steps-rail .bar { flex: 1; height: 1px; background: var(--line-strong); margin: 0 12px; }
.steps-rail .node.done + .bar { background: var(--gold); }

.progress { height: 7px; border-radius: 999px; background: var(--surface-3); overflow: hidden; }
.progress > span { display: block; height: 100%; border-radius: 999px; background: linear-gradient(90deg, var(--ember), var(--gold)); transition: width 0.4s var(--ease); }

/* --------------------------------------------------------------- auth -- */
.auth {
  min-height: 100vh;
  display: grid; grid-template-columns: 1.05fr 1fr;
}
.auth-aside {
  position: relative; overflow: hidden;
  padding: 56px 56px;
  display: flex; flex-direction: column; justify-content: space-between;
  background:
    radial-gradient(700px 420px at 70% 10%, var(--gold-glow), transparent 62%),
    linear-gradient(165deg, var(--bg-deep), var(--surface));
  border-right: 1px solid var(--line);
}
.auth-aside .brand { font-size: 1.18rem; }
.auth-pitch { max-width: 30ch; }
.auth-pitch h2 { font-size: clamp(1.7rem, 2.6vw, 2.5rem); margin-bottom: 14px; }
.auth-pitch p { color: var(--ink-mute); }
.auth-points { list-style: none; padding: 0; margin: 22px 0 0; display: grid; gap: 13px; }
.auth-points li { display: flex; align-items: flex-start; gap: 11px; color: var(--ink-soft); font-size: 0.95rem; }
.auth-points .tick { width: 22px; height: 22px; border-radius: 6px; background: var(--gold-wash); color: var(--gold); display: grid; place-items: center; flex: none; border: 1px solid var(--line-gold); }
.auth-points .tick svg { width: 13px; height: 13px; }

.auth-main { display: flex; align-items: center; justify-content: center; padding: 40px 24px; }
.auth-card { width: 100%; max-width: 400px; }
.auth-card h1 { font-size: 1.9rem; margin-bottom: 6px; }
.auth-foot { margin-top: 22px; text-align: center; font-size: 0.92rem; color: var(--ink-mute); }

@media (max-width: 860px) {
  .auth { grid-template-columns: 1fr; }
  .auth-aside { display: none; }
}

/* ---------------------------------------------------------- callouts -- */
.callout { display: flex; gap: 12px; padding: 15px 17px; border-radius: var(--r-sm); border: 1px solid var(--line); background: var(--surface-2); font-size: 0.9rem; color: var(--ink-soft); }
.callout .callout-icon { flex: none; margin-top: 1px; }
.callout-gold  { border-color: var(--line-gold); background: var(--gold-wash); }
.callout-gold .callout-icon { color: var(--gold); }
.callout-info  { border-color: color-mix(in srgb, var(--info) 26%, transparent); background: var(--info-bg); }
.callout-info .callout-icon { color: var(--info); }
.callout-warn  { border-color: color-mix(in srgb, var(--warn) 26%, transparent); background: var(--warn-bg); }
.callout-warn .callout-icon { color: var(--warn); }
.callout-ok    { border-color: color-mix(in srgb, var(--ok) 26%, transparent); background: var(--ok-bg); }
.callout-ok .callout-icon { color: var(--ok); }
.mini-list { margin: 8px 0 0; padding-left: 18px; color: var(--ink-soft); }
.mini-list li { margin: 3px 0; }

/* ---------------------------------------------------- price / buy bits -- */
.price { display: flex; align-items: baseline; gap: 6px; }
.price .amount { font-family: var(--font-display); font-size: 2.4rem; font-weight: 600; color: var(--ink); letter-spacing: -0.02em; }
.price .unit { font-size: 0.86rem; color: var(--ink-mute); }
.feature-list { list-style: none; padding: 0; margin: 16px 0 0; display: grid; gap: 11px; }
.feature-list li { display: flex; align-items: flex-start; gap: 10px; font-size: 0.92rem; color: var(--ink-soft); }
.feature-list .tick { color: var(--gold); flex: none; margin-top: 2px; }

/* ----------------------------------------------------------- utilities -- */
.tag-key { font-family: var(--font-mono); font-size: 0.78rem; color: var(--ink-mute); }
.kv { display: grid; grid-template-columns: auto 1fr; gap: 6px 16px; font-size: 0.92rem; }
.kv dt { color: var(--ink-mute); } .kv dd { margin: 0; color: var(--ink); text-align: right; }

.mt-0 { margin-top: 0; } .mt-1 { margin-top: 8px; } .mt-2 { margin-top: 16px; } .mt-3 { margin-top: 24px; } .mt-4 { margin-top: 32px; }
.mb-0 { margin-bottom: 0; } .mb-1 { margin-bottom: 8px; } .mb-2 { margin-bottom: 16px; } .mb-3 { margin-bottom: 24px; }
.hide { display: none !important; }
.text-gold { color: var(--gold); }
.text-ink { color: var(--ink); }
.full { width: 100%; }

/* ------------------------------------------------------- page reveal -- */
.reveal { opacity: 0; transform: translateY(12px); animation: rise 0.6s var(--ease) forwards; }
.reveal.d1 { animation-delay: 0.05s; } .reveal.d2 { animation-delay: 0.12s; }
.reveal.d3 { animation-delay: 0.19s; } .reveal.d4 { animation-delay: 0.26s; }
.reveal.d5 { animation-delay: 0.33s; } .reveal.d6 { animation-delay: 0.40s; }
@keyframes rise { to { opacity: 1; transform: translateY(0); } }

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

/* ------------------------------------------------------------ footer -- */
.foot { border-top: 1px solid var(--line); padding: 28px 24px; color: var(--ink-faint); font-size: 0.84rem; }
.foot-inner { max-width: var(--maxw); margin: 0 auto; display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 12px; }
.foot a { color: var(--ink-mute); } .foot a:hover { color: var(--gold); }
.foot a:focus-visible { outline: 2px solid var(--gold); outline-offset: 2px; border-radius: 2px; }

/* auth-page footer: keep the full-height login layout but pin a slim legal/help
   bar in view so the page does not look like a demo with no footer at all.
   Scoped with :has() so ONLY the login page (which mounts .auth-foot-bar) is
   affected; signup and other auth pages are untouched.                       */
body:has(> .auth-foot-bar) { display: flex; flex-direction: column; min-height: 100vh; }
body:has(> .auth-foot-bar) .auth { flex: 1 1 auto; min-height: 0; }
.auth-foot-bar { flex: none; }

/* ------------------------------------------------------ card-lite row --
   Used for list rows inside a card, e.g. account purchases or sender rows.
   Subtle vertical padding and a faint bottom divider; the last row has no
   border so the card edge acts as the terminator.                           */
.card-lite {
  padding: 11px 0;
  border-bottom: 1px solid var(--line);
  display: flex; align-items: center; gap: 12px;
}
.card-lite:last-child { border-bottom: none; }

/* --------------------------------------------------- file-drop control --
   Full-width clickable drop zone for file uploads. Wraps a hidden native
   file input. Shows an upload icon and a filename slot (.file-drop-name).
   Matches .input styling with a gold hover and focus-within ring.
   Markup: <label class="file-drop"><input type="file" ...><span
     class="file-drop-name">Choose a file</span></label>                    */
.file-drop {
  display: flex; align-items: center; gap: 12px;
  width: 100%; cursor: pointer;
  padding: 12px 14px;
  background: var(--bg-deep);
  border: 1px solid var(--line-strong);
  border-radius: var(--r-sm);
  color: var(--ink-mute);
  font-family: var(--font-body); font-size: 0.96rem;
  transition: border-color 0.18s var(--ease), box-shadow 0.18s var(--ease), background 0.18s var(--ease);
}
.file-drop input[type="file"] {
  position: absolute; width: 1px; height: 1px;
  opacity: 0; pointer-events: none; overflow: hidden;
  clip: rect(0 0 0 0); white-space: nowrap;
}
.file-drop:hover { border-color: var(--ink-faint); background: var(--bg); }
.file-drop:focus-within { outline: none; border-color: var(--gold); box-shadow: var(--ring); background: var(--bg); }
.file-drop .file-drop-icon { flex: none; color: var(--gold); opacity: 0.8; }
.file-drop-name { flex: 1; color: var(--ink-faint); min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.file-drop-name.has-file { color: var(--ink); }

/* ------------------------------------------ table scroll affordance --
   A right-edge gradient fade on .table-wrap lets mobile users know the
   table continues horizontally. Positioned relative so ::after can live
   at the right edge.
   Also: when a .table-wrap sits directly inside .card-flush the card
   already provides the border and radius, so we remove the duplicate
   inner border and radius on the wrap itself.                           */
.table-wrap {
  position: relative;
}
.table-wrap::after {
  content: "";
  position: absolute; top: 0; right: 0; bottom: 0; width: 48px;
  pointer-events: none;
  background: linear-gradient(to right, transparent, var(--surface) 90%);
  border-radius: 0 var(--r) var(--r) 0;
}
/* hide the fade when the table is not overflowing (JS can remove the class,
   or pages can add .no-fade for tables that never overflow) */
.table-wrap.no-fade::after { display: none; }

/* remove duplicate border when nested inside a flush card */
.card-flush > .table-wrap {
  border: none;
  border-radius: 0;
}
.card-flush > .table-wrap::after {
  border-radius: 0;
}

/* -------------------------------------------- mobile nav sign out ----
   On mobile the sign out button in .nav-right is hidden; it re-appears
   inside the open .nav.is-open drawer (appended after the nav links by
   renderNav). On desktop it stays in .nav-right as before.             */
@media (max-width: 720px) {
  /* hide the top-bar sign out on mobile so it does not crowd the toggle */
  .nav-right #nav-logout { display: none; }

  /* sign out entry inside the open drawer */
  .nav-links .nav-signout-mobile {
    margin-top: 6px; padding: 6px 0 4px;
    border-top: 1px solid var(--line);
  }
  .nav-links .nav-signout-mobile button {
    display: flex; align-items: center; gap: 10px;
    width: 100%; padding: 10px 12px;
    background: none; border: none; border-radius: var(--r-sm);
    color: var(--ink-mute); font-family: var(--font-body);
    font-size: 0.92rem; font-weight: 500; cursor: pointer;
    transition: color 0.16s var(--ease), background 0.16s var(--ease);
  }
  .nav-links .nav-signout-mobile button:hover { color: var(--ink); background: var(--surface-2); }
}

/* responsive paddings */
@media (max-width: 560px) {
  .page { padding: 28px 16px 72px; }
  .card { padding: 20px; }
  .nav { padding: 0 16px; }
  .stat-value { font-size: 1.8rem; }
}

/* Wave one additions */
:root {
  --surface-veil: rgba(20, 18, 16, 0.78);
  --surface-glass: rgba(27, 24, 21, 0.58);
  --line-soft: rgba(255, 255, 255, 0.07);
  --highlight: rgba(255, 255, 255, 0.09);
  --shadow-premium: 0 1px 0 rgba(255,255,255,0.05) inset, 0 28px 80px rgba(0,0,0,0.54), 0 0 0 1px rgba(245,177,60,0.06);
  --shadow-float: 0 18px 50px rgba(0,0,0,0.42), 0 1px 0 rgba(255,255,255,0.04) inset;
}

.section-lg {
  margin-top: 76px;
  padding-top: 10px;
}

.divider-glow {
  height: 1px;
  margin: 38px 0;
  border: 0;
  background:
    linear-gradient(90deg, transparent, rgba(245,177,60,0.5), transparent),
    linear-gradient(90deg, transparent, var(--line-strong), transparent);
  box-shadow: 0 0 28px rgba(245,177,60,0.18);
}

.card-elevated {
  position: relative;
  overflow: hidden;
  padding: 26px;
  border: 1px solid color-mix(in srgb, var(--line-strong) 82%, var(--gold) 18%);
  border-radius: var(--r);
  background:
    linear-gradient(180deg, rgba(255,255,255,0.045), transparent 38%),
    radial-gradient(600px 220px at 18% 0%, rgba(245,177,60,0.12), transparent 58%),
    linear-gradient(145deg, var(--surface-2), var(--surface));
  box-shadow: var(--shadow-premium);
}
.card-elevated::before {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  border-radius: inherit;
  background: linear-gradient(135deg, var(--highlight), transparent 34%);
  opacity: 0.7;
}
.card-elevated > * { position: relative; }

.card-glass {
  position: relative;
  overflow: hidden;
  padding: 24px;
  border: 1px solid var(--line-soft);
  border-radius: var(--r);
  background:
    linear-gradient(145deg, rgba(255,255,255,0.06), transparent 42%),
    var(--surface-glass);
  box-shadow: var(--shadow-float);
  backdrop-filter: blur(18px) saturate(1.18);
  -webkit-backdrop-filter: blur(18px) saturate(1.18);
}
.card-glass::after {
  content: "";
  position: absolute;
  inset: 1px;
  pointer-events: none;
  border-radius: calc(var(--r) - 1px);
  border: 1px solid rgba(255,255,255,0.035);
}

.hero {
  position: relative;
  width: 100vw;
  margin-left: calc(50% - 50vw);
  margin-right: calc(50% - 50vw);
  overflow: hidden;
  border-block: 1px solid rgba(245,177,60,0.12);
  background:
    radial-gradient(900px 420px at 78% 18%, rgba(245,177,60,0.2), transparent 62%),
    radial-gradient(740px 480px at 20% 8%, rgba(232,99,42,0.12), transparent 60%),
    linear-gradient(180deg, rgba(255,255,255,0.035), transparent 42%),
    linear-gradient(145deg, var(--bg-deep), var(--surface));
}
.hero::before {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  opacity: 0.36;
  background-image:
    linear-gradient(rgba(255,255,255,0.035) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255,255,255,0.035) 1px, transparent 1px);
  background-size: 44px 44px;
  mask-image: linear-gradient(90deg, transparent, #000 18%, #000 82%, transparent);
}
.hero-inner {
  position: relative;
  width: min(var(--maxw), calc(100% - 48px));
  margin: 0 auto;
  min-height: 580px;
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(320px, 0.86fr);
  align-items: center;
  gap: 56px;
  padding: 78px 0;
}
.hero-eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  margin: 0 0 16px;
  color: var(--gold);
  font-family: var(--font-mono);
  font-size: 0.72rem;
  font-weight: 500;
  letter-spacing: 0.18em;
  text-transform: uppercase;
}
.hero-eyebrow::before {
  content: "";
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--gold);
  box-shadow: 0 0 18px rgba(245,177,60,0.6);
}
.hero-title {
  max-width: 12ch;
  color: var(--ink);
  font-family: var(--font-display);
  font-size: 4.35rem;
  font-weight: 600;
  line-height: 0.98;
  letter-spacing: 0;
}
.hero-lede {
  max-width: 58ch;
  margin: 22px 0 0;
  color: var(--ink-soft);
  font-size: 1.16rem;
  line-height: 1.7;
}
.hero-actions {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 30px;
}
.hero-visual {
  position: relative;
  min-height: 390px;
  display: grid;
  place-items: center;
  border: 1px solid rgba(245,177,60,0.16);
  border-radius: var(--r-lg);
  background:
    linear-gradient(180deg, rgba(255,255,255,0.07), transparent 38%),
    radial-gradient(420px 220px at 50% 0%, rgba(245,177,60,0.16), transparent 64%),
    rgba(7,6,5,0.48);
  box-shadow: var(--shadow-lg);
}
.hero-visual::before {
  content: "";
  position: absolute;
  inset: 16px;
  pointer-events: none;
  border: 1px solid rgba(255,255,255,0.06);
  border-radius: calc(var(--r-lg) - 5px);
}
.hero-visual::after {
  content: "";
  position: absolute;
  inset: auto 18% 8% 18%;
  height: 34px;
  pointer-events: none;
  background: radial-gradient(ellipse at center, rgba(245,177,60,0.28), transparent 70%);
  filter: blur(8px);
}
.hero-visual svg {
  position: relative;
  z-index: 1;
  width: min(100%, 440px);
  height: auto;
  color: var(--gold);
}

.feature-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 18px;
}
.feature {
  position: relative;
  min-height: 190px;
  padding: 24px;
  border: 1px solid var(--line);
  border-radius: var(--r);
  background:
    linear-gradient(180deg, rgba(255,255,255,0.045), transparent 46%),
    var(--surface);
  box-shadow: var(--shadow);
}
.feature::before {
  content: "";
  position: absolute;
  inset: 0 auto 0 0;
  width: 3px;
  background: linear-gradient(180deg, var(--gold), transparent);
  opacity: 0.78;
  border-radius: var(--r) 0 0 var(--r);
}
.feature h3,
.feature h4 { margin-bottom: 9px; }
.feature p { margin-bottom: 0; color: var(--ink-mute); }

.rail {
  display: grid;
  gap: 0;
  counter-reset: rail;
}
.rail-step {
  position: relative;
  min-height: 96px;
  padding: 0 0 28px 58px;
  counter-increment: rail;
}
.rail-step::before {
  content: counter(rail);
  position: absolute;
  left: 0;
  top: 0;
  width: 34px;
  height: 34px;
  display: grid;
  place-items: center;
  border: 1px solid var(--line-gold);
  border-radius: 50%;
  background: linear-gradient(150deg, var(--gold-bright), var(--gold-deep));
  color: #1a1304;
  font-family: var(--font-mono);
  font-size: 0.78rem;
  font-weight: 700;
  box-shadow: 0 0 0 5px rgba(245,177,60,0.08);
}
.rail-step::after {
  content: "";
  position: absolute;
  left: 16px;
  top: 42px;
  bottom: 8px;
  width: 1px;
  background: linear-gradient(180deg, rgba(245,177,60,0.5), transparent);
}
.rail-step:last-child { padding-bottom: 0; }
.rail-step:last-child::after { display: none; }
.rail-step h3,
.rail-step h4 { margin-bottom: 7px; }
.rail-step p { margin-bottom: 0; color: var(--ink-mute); }

.trust-strip {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 1px;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: var(--r);
  background: var(--line);
  box-shadow: var(--shadow);
}
.trust-strip > * {
  min-height: 92px;
  padding: 22px 24px;
  background:
    linear-gradient(180deg, rgba(255,255,255,0.04), transparent),
    var(--surface);
}
.trust-strip strong {
  display: block;
  margin-bottom: 4px;
  color: var(--ink);
  font-weight: 700;
}
.trust-strip span,
.trust-strip p {
  margin: 0;
  color: var(--ink-mute);
  font-size: 0.9rem;
}

.price-card {
  position: relative;
  overflow: hidden;
  padding: 30px;
  border: 1px solid color-mix(in srgb, var(--line-strong) 76%, var(--gold) 24%);
  border-radius: var(--r);
  background:
    radial-gradient(520px 220px at 50% 0%, rgba(245,177,60,0.16), transparent 64%),
    linear-gradient(180deg, rgba(255,255,255,0.05), transparent 44%),
    var(--surface);
  box-shadow: var(--shadow-premium);
}
.price-card.is-featured {
  border-color: rgba(245,177,60,0.55);
  box-shadow: 0 1px 0 rgba(255,255,255,0.06) inset, 0 34px 90px rgba(0,0,0,0.62), 0 0 42px rgba(245,177,60,0.11);
}
.price-amount {
  display: flex;
  align-items: baseline;
  gap: 8px;
  margin: 18px 0 4px;
  font-family: var(--font-display);
  font-size: 3.2rem;
  font-weight: 600;
  line-height: 1;
  letter-spacing: 0;
  color: var(--ink);
}
.price-amount small {
  color: var(--ink-mute);
  font-family: var(--font-body);
  font-size: 0.95rem;
  font-weight: 500;
}
.price-feature-list {
  display: grid;
  gap: 12px;
  margin: 22px 0 0;
  padding: 0;
  list-style: none;
}
.price-feature-list li {
  position: relative;
  padding-left: 26px;
  color: var(--ink-soft);
  font-size: 0.94rem;
}
.price-feature-list li::before {
  content: "";
  position: absolute;
  left: 2px;
  top: 0.38em;
  width: 7px;
  height: 12px;
  border: solid var(--gold);
  border-width: 0 2px 2px 0;
  transform: rotate(45deg);
}

.dot-grid {
  position: relative;
}
.dot-grid::before {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  opacity: 0.28;
  background-image: radial-gradient(rgba(245,177,60,0.34) 1px, transparent 1.5px);
  background-size: 18px 18px;
  mask-image: radial-gradient(circle at 50% 35%, #000, transparent 70%);
}
.data-viz {
  position: relative;
  min-height: 220px;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: var(--r);
  background:
    linear-gradient(180deg, rgba(255,255,255,0.045), transparent),
    repeating-linear-gradient(90deg, rgba(255,255,255,0.035) 0 1px, transparent 1px 44px),
    repeating-linear-gradient(0deg, rgba(255,255,255,0.03) 0 1px, transparent 1px 44px),
    var(--surface);
}
.data-viz::after {
  content: "";
  position: absolute;
  left: 24px;
  right: 24px;
  bottom: 24px;
  height: 130px;
  pointer-events: none;
  background:
    linear-gradient(135deg, transparent 6%, rgba(245,177,60,0.45) 6% 8%, transparent 8% 30%, rgba(95,191,143,0.45) 30% 32%, transparent 32% 54%, rgba(110,162,201,0.48) 54% 56%, transparent 56%),
    linear-gradient(180deg, rgba(245,177,60,0.12), transparent);
  clip-path: polygon(0 82%, 16% 64%, 31% 70%, 47% 38%, 63% 48%, 81% 20%, 100% 30%, 100% 100%, 0 100%);
}
.metric-gauge {
  --gauge-value: 72%;
  width: 156px;
  aspect-ratio: 1;
  display: grid;
  place-items: center;
  border-radius: 50%;
  background:
    radial-gradient(circle at center, var(--surface) 0 56%, transparent 57%),
    conic-gradient(var(--gold) 0 var(--gauge-value), var(--surface-3) var(--gauge-value) 100%);
  box-shadow: inset 0 0 0 1px var(--line), 0 18px 46px rgba(0,0,0,0.35);
  color: var(--ink);
  font-family: var(--font-display);
  font-size: 2rem;
  font-weight: 600;
}

@media (max-width: 920px) {
  .hero-inner {
    min-height: auto;
    grid-template-columns: 1fr;
    gap: 32px;
    padding: 66px 0;
  }
  .hero-title { max-width: 14ch; font-size: 3.1rem; }
  .hero-visual { min-height: 320px; }
  .feature-grid,
  .trust-strip { grid-template-columns: 1fr; }
}

@media (max-width: 560px) {
  .section-lg { margin-top: 56px; }
  .hero-inner {
    width: min(var(--maxw), calc(100% - 32px));
    padding: 52px 0;
  }
  .hero-title { font-size: 2.45rem; }
  .hero-lede { font-size: 1.02rem; }
  .hero-actions { align-items: stretch; flex-direction: column; }
  .hero-actions .btn { width: 100%; }
  .hero-visual {
    min-height: 260px;
    border-radius: var(--r);
  }
  .card-elevated,
  .card-glass,
  .feature,
  .price-card { padding: 20px; }
  .rail-step { padding-left: 48px; }
  .price-amount { font-size: 2.55rem; }
}
