@import url('https://fonts.googleapis.com/css2?family=Space+Grotesk:wght@300;400;500;600;700&family=IBM+Plex+Sans:wght@300;400;500;600;700&family=JetBrains+Mono:wght@400;500;600&family=DM+Serif+Display:ital@0;1&display=swap');

/* ╔══════════════════════════════════════════════════════════════╗
   ║  Friskr™ — Survey Intelligence Cloud                           ║
   ╠══════════════════════════════════════════════════════════════╣
   ║  File    : main.css                                            ║
   ║  Version : v2.1.0                                              ║
   ║  Build   : 20260325                                            ║
   ║  Date    : 2026-03-25                                          ║
   ║  Desc    : Friskr design system — industrial dark/light theme  ║
   ╚══════════════════════════════════════════════════════════════╝ */

/* ================================================================
   FRISKR — SURVEY INTELLIGENCE CLOUD DESIGN SYSTEM
   Dark: Obsidian Gold · Light: Brushed Steel
   ================================================================ */

/* ── Dark Mode (default) — dark_style: Golden bronze + warm slate ── */
:root {
  /* ═══ FDS-3 · Friskr Design System v3 — DARK_STYLE ═══════════════════
     Golden bronze (#D4A574) brand + Warm Slate system.
     This is the "dark_style" variant optimized for dark backgrounds.
     Lighter golden bronze provides better contrast on dark surfaces.
     Token names preserved so existing components keep working.
     The "blue-N" ramp is a legacy name; values are now golden bronze.
     The "silver-N" ramp is also legacy; values are now warm slate.
     ════════════════════════════════════════════════════════════════ */

  /* Surfaces — warm void */
  --bg-void:     #1B1A22;
  --bg-base:     #252430;
  --bg-surface:  #2E2C3D;
  --bg-elevated: #393650;
  --bg-overlay:  #45415F;
  --bg-hover:    #4F4A6A;

  /* Borders — golden bronze tint (dark_style) */
  --border-subtle:  rgba(212,165,116,0.08);
  --border-default: rgba(212,165,116,0.20);
  --border-strong:  rgba(212,165,116,0.34);
  --border-accent:  rgba(212,165,116,0.52);

  /* Golden bronze accent ramp (legacy name kept: --blue-N) — dark_style */
  --blue-900: #2A1A0A;
  --blue-800: #4A2E14;
  --blue-700: #6B4520;
  --blue-600: #8E5C2C;
  --blue-500: #A87A44;
  --blue-400: #C4935C;
  --blue-300: #D4A574;
  --blue-200: #E2BB94;
  --blue-100: #EBD0B4;

  /* Warm slate ramp (legacy name kept: --silver-N) */
  --silver-900: #18161A;
  --silver-800: #2A2620;
  --silver-700: #3D3830;
  --silver-600: #514A40;
  --silver-500: #6B5D54;
  --silver-400: #88796E;
  --silver-300: #A89890;
  --silver-200: #C2B5AC;
  --silver-100: #E2D8D0;

  /* Text — dark_style */
  --text-primary:   #EFEAF2;
  --text-heading:   #F6F2FA;
  --text-secondary: #B5ABC8;
  --text-muted:     #7B7596;
  --text-accent:    #D4A574;

  /* Status — dark_style */
  --status-active:   #34B065;
  --status-pending:  #D4A574;
  --status-complete: #34B065;
  --status-paused:   #F97316;
  --status-review:   #D4A574;

  /* Accent alpha variants — golden bronze with transparency (dark_style) */
  --accent-alpha-03: rgba(212,165,116,0.03);
  --accent-alpha-04: rgba(212,165,116,0.04);
  --accent-alpha-05: rgba(212,165,116,0.05);
  --accent-alpha-06: rgba(212,165,116,0.06);
  --accent-alpha-07: rgba(212,165,116,0.07);
  --accent-alpha-08: rgba(212,165,116,0.08);
  --accent-alpha-09: rgba(212,165,116,0.09);
  --accent-alpha-10: rgba(212,165,116,0.10);
  --accent-alpha-12: rgba(212,165,116,0.12);
  --accent-alpha-13: rgba(212,165,116,0.13);
  --accent-alpha-14: rgba(212,165,116,0.14);
  --accent-alpha-15: rgba(212,165,116,0.15);
  --accent-alpha-18: rgba(212,165,116,0.18);
  --accent-alpha-20: rgba(212,165,116,0.20);
  --accent-alpha-25: rgba(212,165,116,0.25);
  --accent-alpha-30: rgba(212,165,116,0.30);
  --accent-alpha-32: rgba(212,165,116,0.32);
  --accent-alpha-35: rgba(212,165,116,0.35);
  --accent-alpha-38: rgba(212,165,116,0.38);
  --accent-alpha-40: rgba(212,165,116,0.40);
  --accent-alpha-60: rgba(212,165,116,0.60);
  --accent-alpha-70: rgba(212,165,116,0.70);
  --accent-alpha-90: rgba(212,165,116,0.90);

  /* Radii */
  --radius-sm: 4px;
  --radius-md: 6px;
  --radius-lg: 10px;
  --radius-xl: 14px;

  /* Shadows — dark_style */
  --shadow-sm:   0 1px 3px rgba(0,0,0,0.50);
  --shadow-md:   0 4px 16px rgba(0,0,0,0.55);
  --shadow-lg:   0 8px 32px rgba(0,0,0,0.62);
  --shadow-glow: 0 0 24px rgba(212,165,116,0.16);

  /* Typography */
  --font-display: 'Space Grotesk', system-ui, sans-serif;
  --font-body:    'IBM Plex Sans', system-ui, -apple-system, sans-serif;
  --font-mono:    'JetBrains Mono', 'Courier New', monospace;
  --font-serif:   'DM Serif Display', 'IBM Plex Serif', Georgia, serif;

  /* Layout */
  --sidebar-w: 240px;
  --nav-h: 60px;

  /* ─── Short-name aliases ──────────────────────────────────────────
     The team's templates use shorthand names (--void, --tp, --ta, ...).
     Defined here once, globally, so every template can rely on them
     without redefining locally. These re-export the long-name tokens
     above; they don't introduce new colours.
     ──────────────────────────────────────────────────────────────── */
  --void:  var(--bg-void);
  --base:  var(--bg-base);
  --surf:  var(--bg-surface);
  --elev:  var(--bg-elevated);
  --bd:    var(--border-default);
  --bds:   var(--border-subtle);
  --bda:   var(--border-accent);
  --tp:    var(--text-primary);
  --ts:    var(--text-secondary);
  --tm:    var(--text-muted);
  --ta:    var(--text-accent);
  --th:    var(--text-heading);
  --grn:   var(--status-active);
  --crt:   var(--status-paused);
  --red:   var(--status-paused);
  --fm:    var(--font-mono);
  --fs:    var(--font-body);
  --fd:    var(--font-serif);
  --fb:    'iBrand', 'IBM Plex Sans', sans-serif;

  /* Status fills/borders — used by badges, alerts, status pills.
     Cross-template tokens promoted from individual page :root blocks. */
  --grnf:  rgba(52,176,101,0.13);
  --grnb:  rgba(52,176,101,0.32);
  --redf:  rgba(249,115,22,0.12);
  --redb:  rgba(249,115,22,0.32);
  --crtf:  rgba(220,38,38,0.14);
  --crtb:  rgba(220,38,38,0.32);
  --limf:  rgba(134,204,24,0.13);
  --limb:  rgba(134,204,24,0.32);

  /* Brand fill — legacy name kept (was --ambf for "amber fill"); golden bronze rgba (dark_style) */
  --ambf:  rgba(212,165,116,0.11);

  /* Composite shadow — short alias for the medium shadow */
  --shadow: var(--shadow-md);

  /* Lime status — used for "verified" badges in marketing/demo surfaces.
     Distinct from --grn (status-active); leans more yellow. */
  --lim:   #84CC16;

  /* Typography scale — used by marketing/legal/demo templates.
     Sizes don't vary per theme, so defined once globally. */
  --t-hero:  clamp(2rem, 5vw, 3.5rem);
  --t-h2:    clamp(1.5rem, 3vw, 2rem);
  --t-h3:    clamp(1.125rem, 1.5vw, 1.375rem);
  --t-stat:  clamp(1.75rem, 3.5vw, 2.75rem);
  --t-body:  1.0625rem;
  --t-small: 0.9375rem;
  --t-meta:  0.875rem;
  --t-nav:   0.8125rem;
  --t-data:  0.75rem;
  --t-label: 0.6875rem;
}

/* ── Light Mode — light_style: Deep bronze for readability ── */
[data-theme="light"] {
  /* FDS-3 light_style · reduced-luminance system
     Deep bronze (#8E4818) for WCAG AA contrast compliance on light backgrounds.
     Page #EFEEEB and cards #FAFAF7 — both off-white for eye comfort
     during long viewing sessions. ~9-unit tonal gap keeps cards
     visibly distinct from the page without pure-white retinal load. */
  --bg-void:    #EFEEEB;
  --bg-base:    #F4F3F0;
  --bg-surface: #FAFAF7;
  --bg-elevated:#FAFAF7;
  --bg-overlay: #E4E2DD;
  --bg-hover:   #E0DED8;

  --border-subtle:  rgba(15,23,42,0.05);
  --border-default: rgba(15,23,42,0.08);
  --border-strong:  rgba(15,23,42,0.18);
  --border-accent:  rgba(142,72,24,0.40);

  /* Deep bronze accent ramp (legacy --blue-N) — light_style for contrast */
  --blue-900: #2A1306;
  --blue-800: #3F1D0A;
  --blue-700: #5A2810;
  --blue-600: #7A3A12;
  --blue-500: #8E4818;
  --blue-400: #A85C1E;
  --blue-300: #B36230;
  --blue-200: #C77F4A;
  --blue-100: #DEA479;

  /* Warm slate ramp (legacy --silver-N) — deeper for white background */
  --silver-900: #14110E;
  --silver-800: #211C18;
  --silver-700: #312A24;
  --silver-600: #4A3F38;
  --silver-500: #5C5048;
  --silver-400: #786A60;
  --silver-300: #968880;
  --silver-200: #BCB0A8;
  --silver-100: #DCD4CC;

  --text-primary:   #1F2937;
  --text-secondary: #4B5563;
  --text-muted:     #9CA3AF;
  --text-accent:    #8E4818;
  --text-heading:   #0B1018;

  --shadow-sm:   0 1px 2px rgba(11,16,24,0.04);
  --shadow-md:   0 4px 16px rgba(11,16,24,0.06);
  --shadow-lg:   0 8px 24px rgba(11,16,24,0.08);
  --shadow-glow: 0 0 24px rgba(142,72,24,0.14);
  --status-complete: #0F7A40;

  /* Status fills/borders · light — alphas slightly lower for white background */
  --grnf:  rgba(15,122,64,0.07);
  --grnb:  rgba(15,122,64,0.22);
  --redf:  rgba(184,52,16,0.07);
  --redb:  rgba(184,52,16,0.24);
  --crtf:  rgba(153,27,27,0.07);
  --crtb:  rgba(153,27,27,0.26);
  --limf:  rgba(77,124,15,0.07);
  --limb:  rgba(77,124,15,0.22);
  --ambf:  rgba(142,72,24,0.07);

  /* Lime status · light — deeper for white background */
  --lim:   #4D7C0F;
}

/* ── Reset ── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { font-size: 15px; scroll-behavior: smooth; }

/* ── Font inheritance — override browser UA stylesheet defaults ──
   Browsers don't inherit font into button/input/select/textarea by default.
   This ensures every element uses the Theme K font stack consistently. */
button,
input,
select,
textarea,
optgroup {
  font-family: var(--font-body);
  font-size: inherit;
}
/* Mono elements keep JetBrains Mono */
input[type="text"].mono,
input[type="password"].mono,
.mono,
code,
kbd,
pre,
samp {
  font-family: var(--font-mono);
}

body {
  font-family: var(--font-body);
  background: var(--bg-void);
  color: var(--text-primary);
  line-height: 1.6;
  min-height: 100vh;
  overflow-x: hidden;
  transition: background 0.3s ease, color 0.3s ease;
}

::-webkit-scrollbar { width: 5px; height: 5px; }
::-webkit-scrollbar-track { background: var(--bg-base); }
::-webkit-scrollbar-thumb { background: var(--silver-700); border-radius: 2px; }
::-webkit-scrollbar-thumb:hover { background: var(--silver-600); }

/* ── Typography ── */
h1, h2, h3, h4, h5 {
  font-family: var(--font-display);
  font-weight: 700;
  color: var(--text-heading);
  letter-spacing: 0.02em;
  line-height: 1.2;
}
h1 { font-size: 2.2rem; }
h2 { font-size: 1.7rem; }
h3 { font-size: 1.3rem; }
h4 { font-size: 1.05rem; }
.mono       { font-family: var(--font-mono); }
.mono-xs    { font-family: var(--font-mono); font-size: 0.62rem; }
.mono-sm    { font-family: var(--font-mono); font-size: 0.72rem; }
.mono-md    { font-family: var(--font-mono); font-size: 0.82rem;
  line-height: 1.6; }

/* ================================================================
   AUTH LAYOUT
   ================================================================ */

/* ================================================================
   AUTH LAYOUT v3 — Clean Split Design
   ================================================================ */

.auth-wrapper {
  height: 100vh;
  max-height: 100vh;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  background: var(--bg-void);
}

/* ── Full-width nav above the split ── */
.auth-full-nav {
  position: relative;
  z-index: 10;
  flex-shrink: 0;
  min-height: 56px;
}

/* ── Split container: hero left, form right ── */
.auth-split {
  display: block;
  position: relative;
  flex: 1;
  min-height: 0;
  overflow: hidden;
}

/* ── Login page footer — consistent with home page ── */
.auth-login-footer {
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0.75rem 3rem;
  background: var(--bg-base);
  border-top: 1px solid var(--border-subtle);
  font-family: var(--font-body);
  font-size: 0.75rem;
  color: var(--text-muted);
}


/* ════════════════════════════════════════
   LEFT — Hero Panel
   ════════════════════════════════════════ */
.auth-hero {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: 2.5rem 3rem;
  background: var(--bg-base);
  border-right: none;
  overflow: hidden;
}

/* Decorative radial orbs */
.auth-hero-orb {
  position: absolute;
  border-radius: 50%;
  pointer-events: none;
}
.auth-hero-orb--1 {
  width: 520px;
  height: 520px;
  top: -160px;
  right: -160px;
  background: radial-gradient(circle, var(--accent-alpha-07) 0%, transparent 70%);
}
.auth-hero-orb--2 {
  width: 380px;
  height: 380px;
  bottom: -100px;
  left: -80px;
  background: radial-gradient(circle, rgba(167,139,250,0.05) 0%, transparent 70%);
}

/* Subtle dot grid */
.auth-hero-grid {
  position: absolute;
  inset: 0;
  background-image: radial-gradient(circle, var(--border-subtle) 1px, transparent 1px);
  background-size: 28px 28px;
  pointer-events: none;
  opacity: 0.6;
}

/* Unified page header — logo + eyebrow + theme toggle */
.auth-page-header {
  display: flex;
  align-items: center;
  gap: 1rem;
  position: relative;
  z-index: 1;
  flex-shrink: 0;
}

.auth-hero-logo {
  display: flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
  flex-shrink: 0;
}
.auth-hero-logo-name {
  font-family: var(--font-display);
  font-size: 1.15rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  color: var(--text-heading);
}
.auth-hero-logo-name sup {
  font-size: 0.5em;
  font-weight: 700;
  vertical-align: super;
  letter-spacing: 0;
}

/* Eyebrow sits inline in header — separator style */
.auth-page-header .auth-hero-eyebrow {
  margin-bottom: 0;
  padding-left: 1rem;
  border-left: 1px solid var(--border-default);
  font-size: 0.68rem;
  letter-spacing: 0.18em;
}

/* Theme btn pushed to far right in header */
.auth-page-header .auth-theme-btn {
  position: static;
  margin-left: auto;
}

/* Main hero content */
.auth-hero-content {
  position: relative;
  z-index: 1;
  display: flex;
  flex-direction: column;
  justify-content: flex-start;
  max-width: 480px;
  padding-top: 0.75rem;
}

.auth-hero-eyebrow {
  font-family: var(--font-display);
  font-size: 0.68rem;
  font-weight: 600;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--text-accent);
  margin-bottom: 0.5rem;
}

.auth-hero-heading {
  font-family: var(--font-display);
  font-size: 2.4rem;
  font-weight: 800;
  line-height: 1.05;
  letter-spacing: -0.01em;
  color: var(--text-heading);
  margin-bottom: 0.5rem;
}

.auth-hero-sub {
  font-size: 0.85rem;
  color: var(--text-secondary);
  line-height: 1.5;
  margin-bottom: 0.75rem;
}

/* Feature pills */
.auth-hero-pills {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-bottom: 0.85rem;
}

.auth-hero-pill {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 0.4rem 0.85rem;
  background: var(--bg-elevated);
  border: 1px solid var(--border-default);
  border-radius: 100px;
  font-size: 0.8rem;
  font-weight: 500;
  color: var(--text-secondary);
  transition: border-color 0.18s, color 0.18s;
}
.auth-hero-pill:hover {
  border-color: var(--border-accent);
  color: var(--text-accent);
}
.auth-hero-pill svg { flex-shrink: 0; opacity: 0.7; }

/* Stats row */
.auth-hero-stats {
  display: flex;
  align-items: center;
  gap: 0;
  padding: 1.25rem 1.5rem;
  background: var(--bg-elevated);
  border: 1px solid var(--border-default);
  border-radius: var(--radius-lg);
  width: fit-content;
}

.auth-hero-stat {
  display: flex;
  flex-direction: column;
  gap: 0.2rem;
  padding: 0 1.5rem;
}
.auth-hero-stat:first-child { padding-left: 0; }
.auth-hero-stat:last-child  { padding-right: 0; }

.auth-hero-stat-value {
  font-family: var(--font-body);
  font-size: 1.5rem;
  font-weight: 800;
  letter-spacing: -0.03em;
  color: var(--text-heading);
  line-height: 1;
}

.auth-hero-stat-label {
  font-size: 0.72rem;
  color: var(--text-muted);
  white-space: nowrap;
}

.auth-hero-stat-divider {
  width: 1px;
  height: 36px;
  background: var(--border-default);
  flex-shrink: 0;
}

/* Trust strip — sits in auth-form-side above footer */
.auth-trust-strip {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.4rem;
  flex-wrap: wrap;
  font-size: 0.7rem;
  color: var(--text-muted);
  margin-top: 1.5rem;
}
.auth-trust-strip-icon {
  width: 10px;
  height: 10px;
  flex-shrink: 0;
  opacity: 0.5;
}
.auth-trust-strip-dot {
  color: var(--border-strong);
  opacity: 0.5;
}

/* ════════════════════════════════════════
   RIGHT — Form Panel
   ════════════════════════════════════════ */
.auth-form-side {
  position: absolute;
  top: 0; right: 0; bottom: 0;
  width: 480px;
  height: 100%;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: stretch;
  padding: 2.5rem 3rem;
  background: var(--bg-surface);
  border-left: 1px solid var(--border-default);
  box-shadow: -12px 0 60px rgba(0,0,0,0.06);
  overflow-y: auto;
}

/* Theme toggle — lives in auth-page-header */
.auth-theme-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 30px;
  height: 30px;
  border-radius: var(--radius-md);
  border: 1px solid var(--border-default);
  background: transparent;
  color: var(--text-secondary);
  cursor: pointer;
  transition: all 0.18s;
  flex-shrink: 0;
}
.auth-theme-btn:hover {
  background: var(--bg-hover);
  color: var(--text-primary);
  border-color: var(--border-strong);
}

/* Form card */
.auth-form-card {
  width: 100%;
  max-width: 100%;
  display: flex;
  flex-direction: column;
  gap: 0;
}

.auth-form-card-header {
  margin-bottom: 2rem;
}

.auth-form-title {
  font-family: var(--font-display);
  font-size: 1.9rem;
  font-weight: 700;
  letter-spacing: 0.01em;
  color: var(--text-heading);
  margin-bottom: 0.35rem;
  line-height: 1.1;
}

.auth-form-subtitle {
  font-size: 0.88rem;
  color: var(--text-muted);
  line-height: 1.5;
}

/* Fields */
.auth-field {
  margin-bottom: 1.1rem;
}

.auth-field-label {
  display: block;
  font-size: 0.78rem;
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--text-secondary);
  margin-bottom: 0.45rem;
}

.auth-field-input {
  width: 100%;
  padding: 0.7rem 0.9rem;
  background: var(--bg-surface);
  border: 1px solid var(--border-default);
  border-radius: var(--radius-md);
  font-family: var(--font-body);
  font-size: 0.9rem;
  color: var(--text-primary);
  transition: border-color 0.18s, box-shadow 0.18s;
  outline: none;
}
.auth-field-input::placeholder { color: var(--text-muted); }
.auth-field-input:focus {
  border-color: var(--border-accent);
  box-shadow: 0 0 0 3px var(--accent-alpha-08);
}
[data-theme="light"] .auth-field-input:focus {
  box-shadow: 0 0 0 3px rgba(90,98,112,0.08);
}

.auth-field-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 0.45rem;
}

.auth-field-link {
  font-size: 0.78rem;
  color: var(--text-accent);
  text-decoration: none;
  font-weight: 500;
  transition: opacity 0.15s;
}
.auth-field-link:hover { opacity: 0.75; }

.auth-field-input-wrap {
  position: relative;
}

.auth-field-eye {
  position: absolute;
  right: 0.75rem;
  top: 50%;
  transform: translateY(-50%);
  background: none;
  border: none;
  cursor: pointer;
  color: var(--text-muted);
  display: flex;
  align-items: center;
  padding: 0;
  transition: color 0.15s;
}
.auth-field-eye:hover { color: var(--text-secondary); }

/* Remember me */
.auth-remember {
  margin-bottom: 1.5rem;
}
.auth-remember-label {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  cursor: pointer;
  font-size: 0.85rem;
  color: var(--text-secondary);
}
.auth-remember-check { cursor: pointer; accent-color: var(--text-accent); }

/* Submit button */
.auth-submit-btn {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 0.78rem 1.5rem;
  background: var(--text-accent);
  color: var(--bg-void);
  border: none;
  border-radius: var(--radius-md);
  font-family: var(--font-display);
  font-size: 0.95rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  cursor: pointer;
  transition: opacity 0.18s, transform 0.12s;
  margin-bottom: 1.25rem;
}
.auth-submit-btn:hover { opacity: 0.88; transform: translateY(-1px); }
.auth-submit-btn:active { transform: translateY(0); }

[data-theme="light"] .auth-submit-btn {
  background: var(--text-heading);
  color: #ffffff;
}

/* Register line */
.auth-register-line {
  text-align: center;
  font-size: 0.83rem;
  color: var(--text-muted);
}
.auth-register-link {
  color: var(--text-accent);
  text-decoration: none;
  font-weight: 600;
  transition: opacity 0.15s;
}
.auth-register-link:hover { opacity: 0.75; }

/* Success banner (new account created) */
.auth-success-banner {
  background: rgba(34,197,94,0.06);
  border: 1px solid rgba(34,197,94,0.2);
  border-radius: var(--radius-md);
  padding: 1rem 1.1rem;
  margin-bottom: 1.25rem;
  font-size: 0.83rem;
  color: var(--text-secondary);
}
.auth-success-banner-top {
  display: flex;
  align-items: center;
  gap: 6px;
  font-family: var(--font-display);
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: #22C55E;
  margin-bottom: 0.5rem;
}
.auth-id-copy {
  display: flex;
  align-items: center;
  gap: 8px;
  background: var(--bg-void);
  border: 1px solid var(--border-default);
  border-radius: var(--radius-sm);
  padding: 0.45rem 0.75rem;
  margin-top: 0.5rem;
}
.auth-id-value {
  font-family: var(--font-mono);
  font-size: 0.85rem;
  color: var(--text-accent);
  flex: 1;
  font-weight: 600;
}
.auth-id-copy-btn {
  font-size: 0.72rem;
  font-family: var(--font-display);
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--text-accent);
  background: none;
  border: 1px solid var(--border-default);
  border-radius: var(--radius-sm);
  padding: 2px 8px;
  cursor: pointer;
  transition: background 0.15s;
}
.auth-id-copy-btn:hover { background: var(--bg-hover); }

/* Footer — legal links only, pinned bottom */
.auth-form-side-footer {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.25rem;
  padding: 0.6rem 1.5rem 0.85rem;
  border-top: 1px solid var(--border-subtle);
  background: var(--bg-void);
}

.auth-form-side-footer > div,
.auth-form-side-footer > span {
  display: flex;
  align-items: center;
  gap: 0.45rem;
  font-size: 0.7rem;
  color: var(--text-muted);
}

.auth-form-side-footer a {
  font-size: 0.7rem;
  color: var(--text-muted);
  text-decoration: none;
  transition: color 0.15s;
}
.auth-form-side-footer a:hover { color: var(--text-secondary); }

/* ════════════════════════════════════════
   THEME K — Auth page overrides
   Aligns login page to home page design language
   ════════════════════════════════════════ */

/* ── Hero background — full-page fill with warm tint ── */
[data-theme="light"] .auth-hero {
  background: linear-gradient(160deg, #FAFBFC 60%, var(--accent-alpha-03) 100%);
}
[data-theme="dark"] .auth-hero {
  background: linear-gradient(160deg, #0D0E12 60%, var(--accent-alpha-04) 100%);
}

/* ── Form side — absolute panel on right (see base rule) ── */

/* ── Grid: 64px line grid matching K-hero ── */
.auth-hero-grid {
  background-image:
    linear-gradient(rgba(70,85,105,0.07) 1px, transparent 1px),
    linear-gradient(90deg, rgba(70,85,105,0.07) 1px, transparent 1px);
  background-size: 64px 64px;
  opacity: 1;
}
[data-theme="dark"] .auth-hero-grid {
  background-image:
    linear-gradient(rgba(180,160,120,0.06) 1px, transparent 1px),
    linear-gradient(90deg, rgba(180,160,120,0.06) 1px, transparent 1px);
}

/* ── Orbs — match K-h-o1 / K-h-o2 ── */
.auth-hero-orb--1 {
  width: 480px; height: 480px;
  top: -140px; right: -120px;
  background: radial-gradient(circle, var(--accent-alpha-09) 0%, transparent 68%);
}
.auth-hero-orb--2 {
  width: 360px; height: 360px;
  bottom: -80px; left: -60px;
  background: radial-gradient(circle, rgba(90,104,128,0.07) 0%, transparent 68%);
}

/* ── Nav bar — matches K-nav style ── */
.auth-page-header {
  padding-bottom: 0.75rem;
  border-bottom: 1px solid var(--border-subtle);
  margin-bottom: 0;
}

/* ── Brand logo — matches K-nav brand ── */
.auth-hero-logo-name {
  font-family: var(--font-display);
  font-size: 1.25rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  color: var(--text-heading);
}

/* ── Eyebrow — matches K-h-pill label / K-Se ── */
.auth-hero-eyebrow {
  font-family: var(--font-body);
  font-size: 0.67rem;
  font-weight: 600;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--text-accent);
}

/* ── Hero heading — proportional K-h1
      Home K-h1 = 4.8rem / left panel ~900px wide
      Login left panel ~420px → 3.2rem scaled proportionally ── */
.auth-hero-heading {
  font-family: var(--font-display);
  font-size: 3.2rem;
  font-weight: 700;
  line-height: 0.96;
  letter-spacing: -0.035em;
  color: var(--text-heading);
  margin-bottom: 0.65rem;
}

/* ── Sub — matches K-h-sub exactly ── */
.auth-hero-sub {
  font-family: var(--font-body);
  font-size: 0.9rem;
  font-weight: 300;
  line-height: 1.6;
  color: var(--text-secondary);
  margin-bottom: 0.85rem;
}

/* ── Pills — match K-h-pill ── */
.auth-hero-pill {
  font-family: var(--font-body);
  font-size: 0.72rem;
  font-weight: 500;
  letter-spacing: 0.05em;
  padding: 0.32rem 0.82rem;
  border-radius: 100px;
  background: var(--accent-alpha-04);
  border: 1px solid var(--border-default);
  color: var(--text-secondary);
  transition: border-color 0.18s, color 0.18s;
}
.auth-hero-pill:hover {
  border-color: var(--text-accent);
  color: var(--text-accent);
}

/* ── Form title — matches K-h2 serif italic ── */
.auth-form-title {
  font-family: var(--font-display);
  font-size: 2.1rem;
  font-weight: 700;
  letter-spacing: -0.02em;
  line-height: 1.05;
  color: var(--text-heading);
  margin-bottom: 0.3rem;
}

/* ── Form subtitle — matches K-Ss ── */
.auth-form-subtitle {
  font-family: var(--font-body);
  font-size: 0.85rem;
  font-weight: 300;
  color: var(--text-muted);
  line-height: 1.6;
}

/* ── Field labels — match K-label uppercase caps ── */
.auth-field-label {
  font-family: var(--font-body);
  font-size: 0.7rem;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--text-secondary);
  margin-bottom: 0.42rem;
}

/* ── Field inputs — match K-C card inputs ── */
.auth-field-input {
  font-family: var(--font-body);
  font-size: 0.88rem;
  border-radius: 6px;
  padding: 0.68rem 0.9rem;
  background: var(--bg-base);
  border: 1px solid var(--border-default);
  color: var(--text-primary);
  transition: border-color 0.18s, box-shadow 0.18s;
}
.auth-field-input:focus {
  border-color: var(--text-accent);
  box-shadow: 0 0 0 3px var(--accent-alpha-08);
}
[data-theme="light"] .auth-field-input {
  background: var(--bg-void);
}
[data-theme="light"] .auth-field-input:focus {
  border-color: var(--text-accent);
  box-shadow: 0 0 0 3px rgba(90,104,128,0.08);
}

/* ── Submit button — match K-btn-p exactly ── */
.auth-submit-btn {
  font-family: var(--font-display);
  font-size: 0.9rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  border-radius: 6px;
  padding: 0.8rem 1.5rem;
}
[data-theme="light"] .auth-submit-btn {
  background: var(--text-heading);
  color: #ffffff;
}

/* ── Remember / register text — IBM Plex Sans ── */
.auth-remember-label,
.auth-register-line {
  font-family: var(--font-body);
  font-size: 0.83rem;
  font-weight: 400;
}

/* ── Trust strip — matches K-tc trust chips ── */
.auth-trust-strip {
  font-family: var(--font-body);
  font-size: 0.7rem;
  letter-spacing: 0.06em;
  color: var(--text-muted);
}

/* ── Footer — matches home footer muted style ── */
.auth-form-side-footer {
  font-family: var(--font-body);
}


/* ════════════════════════════════════════
   THEME K — Forgot Password page
   ════════════════════════════════════════ */
.fp-page {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  background: var(--bg-base);
  position: relative;
  overflow: hidden;
  padding: 2rem;
}
/* Grid matching K-hero / auth-hero-grid */
.fp-grid {
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(rgba(70,85,105,0.07) 1px, transparent 1px),
    linear-gradient(90deg, rgba(70,85,105,0.07) 1px, transparent 1px);
  background-size: 64px 64px;
  pointer-events: none;
}
[data-theme="dark"] .fp-grid {
  background-image:
    linear-gradient(rgba(180,160,120,0.06) 1px, transparent 1px),
    linear-gradient(90deg, rgba(180,160,120,0.06) 1px, transparent 1px);
}
/* Orbs matching auth-hero */
.fp-orb { position: absolute; border-radius: 50%; pointer-events: none; }
.fp-orb--1 {
  width: 520px; height: 520px;
  top: -180px; right: -180px;
  background: radial-gradient(circle, var(--accent-alpha-08) 0%, transparent 68%);
}
.fp-orb--2 {
  width: 380px; height: 380px;
  bottom: -120px; left: -100px;
  background: radial-gradient(circle, rgba(90,104,128,0.06) 0%, transparent 68%);
}
/* Nav bar */
.fp-nav {
  position: absolute;
  top: 0; left: 0; right: 0;
  display: flex;
  align-items: center;
  gap: 1rem;
  padding: 1rem 2rem;
  border-bottom: 1px solid var(--border-subtle);
  background: var(--bg-base);
  z-index: 1;
}
.fp-brand {
  display: flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
}
.fp-brand-name {
  font-family: var(--font-display);
  font-size: 1.25rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  color: var(--text-heading);
}
.fp-nav-sep {
  font-family: var(--font-body);
  font-size: 0.67rem;
  font-weight: 600;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--text-accent);
  padding-left: 1rem;
  border-left: 1px solid var(--border-default);
}
/* Card */
.fp-card {
  position: relative;
  z-index: 1;
  width: 100%;
  max-width: 400px;
  background: var(--bg-surface);
  border: 1px solid var(--border-default);
  border-radius: 12px;
  padding: 2.5rem 2rem 2rem;
  box-shadow: 0 4px 32px rgba(0,0,0,0.08);
  margin-top: 5rem;
}
[data-theme="dark"] .fp-card {
  box-shadow: 0 8px 48px rgba(0,0,0,0.35);
}
.fp-card-icon {
  width: 44px; height: 44px;
  border-radius: 50%;
  background: var(--bg-base);
  border: 1px solid var(--border-default);
  display: grid;
  place-items: center;
  color: var(--text-accent);
  margin-bottom: 1.25rem;
}
.fp-heading {
  font-family: var(--font-display);
  font-size: 2.1rem;
  font-weight: 700;
  letter-spacing: -0.02em;
  line-height: 1.05;
  color: var(--text-heading);
  margin-bottom: 0.4rem;
}
.fp-sub {
  font-family: var(--font-body);
  font-size: 0.88rem;
  font-weight: 300;
  color: var(--text-muted);
  line-height: 1.65;
  margin-bottom: 1.75rem;
}
.fp-back {
  text-align: center;
  margin-top: 1.5rem;
}
.fp-back-link {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  font-family: var(--font-body);
  font-size: 0.83rem;
  color: var(--text-accent);
  text-decoration: none;
  transition: opacity 0.15s;
}
.fp-back-link:hover { opacity: 0.75; }
.fp-footer {
  position: relative;
  z-index: 1;
  display: flex;
  align-items: center;
  gap: 0.5rem;
  margin-top: 2rem;
  font-family: var(--font-body);
  font-size: 0.72rem;
  color: var(--text-muted);
}
.fp-footer a { color: var(--text-muted); text-decoration: none; transition: color 0.15s; }
.fp-footer a:hover { color: var(--text-accent); }
.fp-success-icon {
  width: 52px; height: 52px;
  border-radius: 12px;
  background: var(--accent-alpha-08);
  border: 1px solid var(--accent-alpha-20);
  display: grid;
  place-items: center;
  margin: 0 auto 1rem;
}
.fp-success-label {
  font-family: var(--font-display);
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--text-accent);
  margin-bottom: 0.5rem;
}

/* ── Wizard config credit pills ── */
.wiz-cfg-cr-pill {
  font-size: 0.68rem;
  font-weight: 600;
  padding: 2px 8px;
  border-radius: 999px;
  background: var(--bg-surface);
  color: var(--text-muted);
  border: 1px solid var(--border-default);
  transition: background 0.2s, color 0.2s, border-color 0.2s;
}

/* ── Login stat row ── */
.auth-stat-row {
  display: flex;
  align-items: center;
  gap: 2rem;
  margin-top: 1.25rem;
  padding-top: 1.25rem;
  border-top: 1px solid var(--border-subtle);
}
.auth-stat-item {
  display: flex;
  flex-direction: column;
  gap: 4px;
}
.auth-stat-value {
  font-family: var(--font-body);
  font-size: 1.75rem;
  font-weight: 800;
  letter-spacing: -0.03em;
  color: var(--text-heading);
  line-height: 1;
}
.auth-stat-value--accent { color: var(--text-accent); }
.auth-stat-label {
  font-family: var(--font-body);
  font-size: 0.65rem;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--text-muted);
}
.auth-stat-divider {
  width: 1px;
  height: 36px;
  background: var(--border-default);
  flex-shrink: 0;
}

/* ── Login sparkline ── */
.auth-spark-wrap {
  margin-top: 1.5rem;
  padding-top: 1.25rem;
  border-top: 1px solid var(--border-subtle);
}
.auth-spark-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 0.45rem;
}
.auth-spark-title {
  font-family: var(--font-body);
  font-size: 0.6rem;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--text-muted);
}
.auth-spark-badge {
  font-family: var(--font-mono);
  font-size: 0.65rem;
  font-weight: 600;
  color: var(--text-accent);
  background: var(--bg-elevated);
  border: 1px solid var(--border-default);
  border-radius: 4px;
  padding: 2px 8px;
}
.auth-spark-canvas-wrap {
  position: relative;
  height: 56px;
  width: 100%;
}
.auth-spark-canvas-wrap canvas {
  display: block;
  width: 100% !important;
}
.auth-spark-legend {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  margin-top: 0.45rem;
}
.auth-spark-legend span {
  font-family: var(--font-body);
  font-size: 0.65rem;
  color: var(--text-muted);
}
.auth-spark-dot {
  display: inline-block;
  width: 7px !important;
  height: 7px !important;
  border-radius: 50%;
  flex-shrink: 0;
}


/* ════════════════════════════════════════
   TREND CHART inside auth-hero
   ════════════════════════════════════════ */
.auth-trend-section {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 0.75rem;
  align-items: stretch;
  width: 100%;
  flex: 1;
  min-height: 0;
  overflow: hidden;
}

.auth-trend-chart-wrap {
  background: var(--bg-elevated);
  border: 1px solid var(--border-default);
  border-radius: var(--radius-lg);
  padding: 1.1rem 1.25rem;
  display: flex;
  flex-direction: column;
  min-width: 0;
  min-height: 0;
}

.auth-trend-chart-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 0.75rem;
  flex-shrink: 0;
}

.auth-trend-chart-title {
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--text-muted);
}

.auth-trend-badge {
  font-family: var(--font-mono);
  font-size: 0.7rem;
  font-weight: 600;
  color: var(--text-accent);
  background: var(--bg-overlay);
  border: 1px solid var(--border-default);
  border-radius: 4px;
  padding: 2px 8px;
}

.auth-trend-canvas-wrap {
  position: relative;
  flex: 1;
  min-height: 0;
  width: 100%;
}

.auth-trend-canvas-wrap canvas {
  display: block;
  width: 100% !important;
}

.auth-trend-legend {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  margin-top: 0.65rem;
  flex-shrink: 0;
  flex-wrap: wrap;
}

.auth-trend-legend span {
  font-size: 0.68rem;
  color: var(--text-muted);
}

.auth-trend-dot {
  display: inline-block;
  width: 7px !important;
  height: 7px !important;
  border-radius: 50%;
  flex-shrink: 0;
}

.auth-trend-stats {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  width: 105px;
  flex-shrink: 0;
  min-height: 0;
  overflow: hidden;
}

.auth-trend-stat-card {
  flex: 1;
  min-height: 0;
  background: var(--bg-elevated);
  border: 1px solid var(--border-default);
  border-radius: var(--radius-lg);
  padding: 0.5rem 0.65rem;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 0.18rem;
  text-align: center;
  transition: border-color 0.18s;
  overflow: hidden;
}

.auth-trend-stat-card:hover { border-color: var(--border-accent); }

.auth-trend-stat-icon {
  width: 28px;
  height: 28px;
  border-radius: var(--radius-md);
  display: grid;
  place-items: center;
  flex-shrink: 0;
  margin-bottom: 0.15rem;
}

.auth-trend-stat-value {
  font-family: var(--font-body);
  font-size: 1.1rem;
  font-weight: 800;
  letter-spacing: -0.03em;
  color: var(--text-heading);
  line-height: 1;
}

.auth-trend-stat-label {
  font-size: 0.65rem;
  font-weight: 600;
  letter-spacing: 0.07em;
  text-transform: uppercase;
  color: var(--text-muted);
  line-height: 1.3;
}

.auth-trend-stat-delta {
  font-size: 0.65rem;
  color: var(--text-accent);
  margin-top: 0.1rem;
}

/* ── Tablet: 769–1100px — narrow left panel, form still on right ── */
@media (max-width: 1100px) and (min-width: 769px) {
  .auth-split {
    grid-template-columns: 1fr 360px;
  }
  .auth-hero {
    padding: 1.5rem 1.75rem 1rem 1.75rem;
  }
  .auth-hero-heading {
    font-size: 2rem;
  }
  .auth-hero-sub {
    font-size: 0.82rem;
  }
  .auth-trend-stats {
    width: 88px;
  }
  .auth-trend-stat-value {
    font-size: 0.9rem;
  }
  .auth-form-side {
    padding: 125px 1.75rem 5rem 1.75rem;
  }
}

/* ── Mobile: ≤768px — stack vertically: form first, hero below ── */
@media (max-width: 768px) {
  .auth-split {
    display: flex;
    flex-direction: column;
    height: auto;
    overflow: visible;
  }

  /* Hero panel comes first on mobile */
  .auth-hero {
    order: 1;
    display: flex;
    height: auto;
    min-height: 0;
    padding: 2rem 1.5rem 1.5rem 1.5rem;
    border-right: none;
    border-bottom: 1px solid var(--border-default);
  }

  /* Hero logo stays visible on mobile */
  .auth-hero-logo {
    display: flex;
  }

  /* Form panel comes below hero */
  .auth-form-side {
    order: 2;
    height: auto;
    min-height: auto;
    padding: 3rem 1.5rem 5rem 1.5rem !important;
    justify-content: flex-start;
  }

  .auth-trend-section {
    flex: none;
    height: 260px;
  }

  .auth-trend-stats {
    width: 80px;
  }

  .auth-trend-stat-value {
    font-size: 0.88rem;
  }

  .auth-trend-stat-label {
    font-size: 0.65rem;
  }

  .auth-form-card {
    max-width: 100%;
  }

  .auth-form-side-footer {
    padding: 0.65rem 1rem 0.85rem;
  }

  .auth-trust-strip {
    font-size: 0.65rem;
    gap: 0.3rem;
  }

  .auth-hero-orb--1 {
    width: 300px;
    height: 300px;
    top: -80px;
    right: -80px;
  }
  .auth-hero-orb--2 {
    width: 220px;
    height: 220px;
  }
}


/* ================================================================
   HOME PAGE — PRODUCTS SECTION
   ================================================================ */
.home-products-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.25rem;
  margin-top: 3rem;
}

.home-product-card {
  display: flex;
  flex-direction: column;
  gap: 1rem;
  padding: 1.75rem;
  background: var(--bg-elevated);
  border: 1px solid var(--border-default);
  border-radius: var(--radius-lg);
  transition: border-color 0.18s, box-shadow 0.18s, transform 0.18s;
}

.home-product-card:hover {
  border-color: var(--border-accent);
  box-shadow: var(--shadow-md);
  transform: translateY(-2px);
}

.home-product-icon {
  width: 48px;
  height: 48px;
  border-radius: var(--radius-md);
  display: grid;
  place-items: center;
  flex-shrink: 0;
}

.home-product-name {
  font-family: var(--font-display);
  font-size: 1.1rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  color: var(--text-heading);
  margin-bottom: 0.15rem;
}

.home-product-desc {
  font-size: 0.78rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--text-accent);
  margin-bottom: 0.5rem;
}

.home-product-body p {
  font-size: 0.88rem;
  color: var(--text-secondary);
  line-height: 1.65;
}

/* ================================================================
   HOME PAGE — USE CASES SECTION
   ================================================================ */
.home-usecases-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 1.5rem;
  margin-top: 3rem;
}

.home-usecase-card {
  display: flex;
  gap: 1.5rem;
  padding: 2rem;
  background: var(--bg-elevated);
  border: 1px solid var(--border-default);
  border-radius: var(--radius-lg);
  transition: border-color 0.18s, box-shadow 0.18s;
}

.home-usecase-card:hover {
  border-color: var(--border-accent);
  box-shadow: var(--shadow-sm);
}

.home-usecase-num {
  font-family: var(--font-display);
  font-size: 2rem;
  font-weight: 800;
  color: var(--border-strong);
  line-height: 1;
  flex-shrink: 0;
  width: 48px;
}

.home-usecase-body h4 {
  font-size: 1.05rem;
  font-weight: 700;
  color: var(--text-heading);
  margin-bottom: 0.6rem;
}

.home-usecase-body p {
  font-size: 0.88rem;
  color: var(--text-secondary);
  line-height: 1.65;
  margin-bottom: 1rem;
}

.home-usecase-list {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
}

.home-usecase-list li {
  font-size: 0.82rem;
  color: var(--text-secondary);
  padding-left: 1rem;
  position: relative;
}

.home-usecase-list li::before {
  content: '→';
  position: absolute;
  left: 0;
  color: var(--text-accent);
  font-size: 0.75rem;
}

.home-usecase-cta {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 1rem;
  margin-top: 3.5rem;
  padding-top: 3rem;
  border-top: 1px solid var(--border-default);
  flex-wrap: wrap;
}

.home-usecase-cta p {
  font-family: var(--font-display);
  font-size: 1.1rem;
  font-weight: 600;
  color: var(--text-heading);
  margin-right: 0.5rem;
}

/* ================================================================
   HOME PAGE — AWARDS SECTION (hidden by default)
   ================================================================ */
.home-awards-grid {
  display: flex;
  gap: 1.5rem;
  justify-content: center;
  flex-wrap: wrap;
  margin-top: 3rem;
}

.home-award-card {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  gap: 0.75rem;
  padding: 2rem 2.5rem;
  background: var(--bg-elevated);
  border: 1px solid var(--border-default);
  border-radius: var(--radius-lg);
  min-width: 200px;
}

.home-award-icon {
  width: 56px;
  height: 56px;
  background: rgba(245,158,11,0.08);
  border-radius: 50%;
  display: grid;
  place-items: center;
}

.home-award-name {
  font-family: var(--font-display);
  font-size: 0.95rem;
  font-weight: 700;
  color: var(--text-heading);
  line-height: 1.3;
}

.home-award-org {
  font-size: 0.78rem;
  color: var(--text-muted);
}

/* ================================================================
   HOME PAGE — INDUSTRY AFFILIATIONS SECTION
   ================================================================ */
.home-affiliations-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.25rem;
  margin-top: 3rem;
}

.home-affiliation-card {
  display: flex;
  flex-direction: column;
  gap: 1rem;
  padding: 1.75rem;
  background: var(--bg-elevated);
  border: 1px solid var(--border-default);
  border-radius: var(--radius-lg);
  transition: border-color 0.18s;
}

.home-affiliation-card:hover {
  border-color: var(--border-accent);
}

.home-affiliation-logo {
  font-family: var(--font-display);
  font-size: 1.5rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  color: var(--text-accent);
  opacity: 0.7;
}

.home-affiliation-name {
  font-family: var(--font-display);
  font-size: 0.95rem;
  font-weight: 700;
  color: var(--text-heading);
  margin-bottom: 0.4rem;
}

.home-affiliation-body p {
  font-size: 0.85rem;
  color: var(--text-secondary);
  line-height: 1.65;
}

/* ── Responsive ── */
@media (max-width: 1024px) {
  .home-products-grid { grid-template-columns: repeat(2, 1fr); }
  .home-affiliations-grid { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 768px) {
  .home-products-grid { grid-template-columns: 1fr; }
  .home-usecases-grid { grid-template-columns: 1fr; }
  .home-affiliations-grid { grid-template-columns: 1fr; }
  .home-usecase-card { flex-direction: column; gap: 0.75rem; }
  .home-usecase-num { width: auto; font-size: 1.5rem; }
}
/* ================================================================
   APP SHELL LAYOUT
   ================================================================ */

.app-layout {
  display: flex;
  min-height: 100vh;
}

/* ── Sidebar ── */
.sidebar {
  width: var(--sidebar-w);
  background: var(--bg-base);
  border-right: 1px solid var(--border-default);
  display: flex;
  flex-direction: column;
  position: fixed;
  left: 0;
  top: 0;
  bottom: 0;
  z-index: 100;
}

/* DEPRECATED: .sidebar-header replaced by .reg-card-brand (single source). Original definition #1 */
/* .sidebar-header { */
/*   height: var(--nav-h); */
/*   display: flex; */
/*   align-items: center; */
/*   padding: 0 1.2rem; */
/*   border-bottom: 1px solid var(--border-default); */
/*   gap: 10px; */
/*   flex-shrink: 0; */
/* } */

/* Sidebar-specific layout for the brand (brand look from .reg-card-brand) */
.sidebar > .reg-card-brand {
  height: var(--nav-h);
  padding: 0 1.2rem;
  border-bottom: 1px solid var(--border-default);
  gap: 10px;
  flex-shrink: 0;
}

/* Sidebar brand row — wraps the brand_block macro + mobile-close button.
   Without this rule, the wrapper has no layout and child elements stack
   top-aligned, making the logo sit high relative to the wordmark. */
.sidebar-brand-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  height: 44px;
  padding: 0 1.2rem;
  border-bottom: 1px solid var(--border-default);
  flex-shrink: 0;
}
/* When followed by a tagline row, drop our border so the tagline row owns it.
   :has() support: Chrome 105+, Safari 15.4+, Firefox 121+. If older browser
   support is needed, replace with an explicit modifier class on .sidebar-brand-row. */
.sidebar-brand-row:has(+ .sidebar-tagline-row) {
  border-bottom: none;
}
.sidebar-brand-row .brand-block {
  flex: 1;
  min-width: 0;
}

.sidebar-logo-icon {
  width: 32px;
  height: 32px;
  background: linear-gradient(135deg, var(--text-accent) 0%, var(--text-accent) 100%);
  border-radius: var(--radius-md);
  display: grid;
  place-items: center;
  flex-shrink: 0;
  box-shadow: 0 2px 8px var(--accent-alpha-30);
}

.sidebar-logo-icon svg { color: #ffffff; }

.sidebar-logo-text {
  font-family: var(--font-display);
  font-size: 1.15rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  color: var(--text-heading);
}

/* Hide mobile-only sidebar close button on desktop by default.
   The @media (max-width: 900px) rule below overrides this to show it on mobile. */
.sidebar-mobile-close {
  display: none;
}

.sidebar-nav {
  flex: 1;
  padding: 1rem 0;
  overflow-y: auto;
}

.nav-section {
  padding: 0.5rem 1rem 0.25rem;
  font-family: var(--font-body);
  font-size: 0.65rem;
  font-weight: 600;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--text-accent);
  opacity: 0.7;
  margin-top: 0.5rem;
}

.nav-link {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 0.65rem 1.2rem;
  color: var(--text-secondary);
  text-decoration: none;
  font-family: var(--font-body);
  font-size: 0.88rem;
  font-weight: 500;
  letter-spacing: 0.02em;
  border-left: 3px solid transparent;
  transition: all 0.18s ease;
}

.nav-link:hover {
  color: var(--text-primary);
  background: var(--bg-hover);
  border-left-color: var(--border-accent);
}

.nav-link.active {
  color: var(--text-accent);
  background: var(--accent-alpha-07);
  border-left-color: var(--text-accent);
}

.nav-link svg { flex-shrink: 0; width: 16px; height: 16px; }

.sidebar-footer {
  padding: 1rem;
  border-top: 1px solid var(--border-default);
}

.user-card {
  display: flex;
  flex-direction: column;
  gap: 0;
  padding: 0 0 0.6rem;
  border-radius: var(--radius-md);
  cursor: pointer;
  transition: background 0.18s;
  overflow: hidden;
}

.user-card:hover { background: var(--bg-hover); }

.user-card-top {
  display: flex;
  flex-direction: row;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding: 0.55rem 0.6rem 0;
}

.user-avatar {
  width: 32px;
  height: 32px;
  background: linear-gradient(135deg, var(--blue-600), var(--blue-400));
  border-radius: var(--radius-sm);
  display: grid;
  place-items: center;
  font-size: 0.75rem;
  font-weight: 700;
  color: white;
  font-family: var(--font-display);
  flex-shrink: 0;
}

.user-info { min-width: 0; text-align: left; }
.user-name {
  font-size: 0.83rem;
  font-weight: 600;
  line-height: 1.6;
  color: var(--text-primary);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  line-height: 1.3;
}
.user-id {
  font-family: var(--font-mono);
  font-size: 0.62rem;
  color: var(--text-muted);
  letter-spacing: 0.04em;
  margin-top: 0.15rem;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

/* ── Account type bar — full width at top ── */
.user-card-type {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  padding: 0.4rem 0.6rem;
  border-bottom: 1px solid var(--border-subtle);
}
.user-card-type--super     { background: rgba(245,158,11,0.1);  color: #F59E0B; }
.user-card-type--primary   { background: var(--accent-alpha-07); color: var(--text-accent); }
.user-card-type--secondary { background: rgba(34,197,94,0.07);  color: #22C55E; }
.user-card-type--tertiary  { background: rgba(168,85,247,0.07); color: #A855F7; }

.user-card-pill-row {
  display: flex;
  align-items: center;
  gap: 0.35rem;
  flex-wrap: wrap;
}
.user-card-pill {
  display: inline-flex;
  align-items: center;
  gap: 3px;
  font-size: 0.65rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  padding: 0.15rem 0.5rem;
  border-radius: 999px;
  border: 1px solid transparent;
  white-space: nowrap;
  max-width: 100%;
  overflow: hidden;
  text-overflow: ellipsis;
}
.user-card-pill--super    { background: rgba(245,158,11,0.1);  border-color: rgba(245,158,11,0.25); color: #F59E0B; }
.user-card-pill--primary  { background: var(--accent-alpha-08); border-color: var(--accent-alpha-20);  color: var(--text-accent); }
.user-card-pill--secondary{ background: rgba(34,197,94,0.08);  border-color: rgba(34,197,94,0.2);   color: #22C55E; }
.user-card-pill--tertiary { background: rgba(168,85,247,0.08); border-color: rgba(168,85,247,0.2);  color: #A855F7; }

/* ── Main Content ── */
.main-content {
  margin-left: var(--sidebar-w);
  flex: 1;
  display: flex;
  flex-direction: column;
  min-height: 100vh;
  min-width: 0;
  width: calc(100vw - var(--sidebar-w));
  max-width: calc(100vw - var(--sidebar-w));
  overflow-x: hidden;
}

.topbar {
  height: var(--nav-h);
  background: var(--bg-base);
  border-bottom: 1px solid var(--border-default);
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 1.5rem;
  position: sticky;
  top: 0;
  z-index: 90;
  overflow: visible;
}

.topbar-left {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.page-title {
  font-family: var(--font-serif);
  font-size: 1.2rem;
  font-weight: 400;
  font-style: italic;
  letter-spacing: 0;
  color: var(--text-heading);
}

/* ── Account type pill ── */
.topbar-account-pill {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  font-size: 0.62rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  padding: 0.2rem 0.55rem;
  border-radius: 999px;
  border: 1px solid transparent;
  white-space: nowrap;
  flex-shrink: 0;
}
.topbar-account-pill--super {
  background: rgba(245,158,11,0.1);
  border-color: rgba(245,158,11,0.25);
  color: #F59E0B;
}
.topbar-account-pill--primary {
  background: var(--accent-alpha-08);
  border-color: var(--accent-alpha-20);
  color: var(--text-accent);
}
.topbar-account-pill--secondary {
  background: rgba(34,197,94,0.08);
  border-color: rgba(34,197,94,0.2);
  color: #22C55E;
}
.topbar-account-pill--tertiary {
  background: rgba(168,85,247,0.08);
  border-color: rgba(168,85,247,0.2);
  color: #A855F7;
}
@media (max-width: 640px) {
  .topbar-account-pill { display: none; }
}

.topbar-right {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.topbar-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 34px;
  height: 34px;
  border-radius: var(--radius-md);
  border: 1px solid var(--border-default);
  background: transparent;
  color: var(--text-secondary);
  cursor: pointer;
  transition: all 0.18s;
}

.topbar-btn:hover {
  background: var(--bg-hover);
  color: var(--text-primary);
  border-color: var(--border-strong);
}


/* ================================================================
   PAGE NAV BAR (below topbar — dashboard sub-tabs)
   ================================================================ */
.page-nav {
  display: flex;
  border-bottom: 1px solid var(--border-default);
  margin: 0.5rem -1.5rem 1.5rem -1.5rem;
  padding: 0 1.5rem;
}

.page-nav-btn {
  padding: 0.7rem 1.2rem;
  font-family: var(--font-display);
  font-size: 0.82rem;
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--text-muted);
  background: transparent;
  border: none;
  border-bottom: 2px solid transparent;
  cursor: pointer;
  transition: all 0.18s;
  margin-bottom: -1px;
  white-space: nowrap;
}
.page-nav-btn:hover { color: var(--text-primary); }
.page-nav-btn.active { color: var(--text-accent); border-bottom-color: var(--text-accent); }

.page-nav-panel { display: none; }
.page-nav-panel.active { display: block; }

.page-body {
  flex: 1;
  padding: 1.5rem;
  background: var(--bg-void);
  min-width: 0;
  overflow-x: hidden;
  box-sizing: border-box;
  width: 100%;
}


/* ================================================================
   GRID
   ================================================================ */
.grid { display: grid; gap: 1rem; }
.grid-2 { grid-template-columns: repeat(2, 1fr); }
.grid-3 { grid-template-columns: repeat(3, 1fr); }
.grid-4, .Status_Projects, .Status_Screeners, .Status_Panel, .Status_Communities { grid-template-columns: repeat(4, 1fr); }
.col-span-2 { grid-column: span 2; }
.Status_Projects, .Status_Screeners, .Status_Panel, .Status_Communities { display: grid; gap: 1rem; }

/* ================================================================
   CARDS
   ================================================================ */
.card {
  background: var(--bg-surface);
  border: 1px solid var(--border-default);
  border-radius: var(--radius-lg);
  padding: 1.25rem;
  transition: border-color 0.18s, box-shadow 0.18s;
}

.card:hover {
  border-color: var(--border-strong);
  box-shadow: var(--shadow-sm);
}

/* Card layout variants */
.card--flush   { padding: 0; }                          /* table/image inside card */
.card--compact { padding: 0.75rem 1rem; }               /* stat cards, sidebar panels */
.card--loose   { padding: 1.75rem 2rem; }               /* modal bodies, feature cards */
.card--raised  { box-shadow: var(--shadow-md); border-color: var(--border-strong); }

.card-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1rem 1.25rem;
  border-bottom: 1px solid var(--border-subtle);
}

.card-title {
  font-family: var(--font-display);
  font-size: 0.78rem;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--text-muted);
}

/* ── Metric Cards ── */
.metric-card {
  background: var(--bg-surface);
  border: 1px solid var(--border-default);
  border-radius: var(--radius-lg);
  padding: 1.2rem;
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  position: relative;
  overflow: hidden;
  transition: all 0.2s ease;
}

.metric-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 2px;
  background: var(--metric-accent, var(--text-accent));
  opacity: 0.7;
}

.metric-card:hover {
  border-color: var(--border-accent);
  box-shadow: var(--shadow-glow);
  transform: translateY(-1px);
}

.metric-icon {
  width: 36px;
  height: 36px;
  border-radius: var(--radius-md);
  background: var(--metric-bg, var(--accent-alpha-08));
  display: grid;
  place-items: center;
  color: var(--metric-accent, var(--text-accent));
}

.metric-value {
  font-family: var(--font-body);
  font-size: 2rem;
  font-weight: 800;
  letter-spacing: -0.03em;
  color: var(--text-heading);
  line-height: 1;
}

.metric-label {
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--text-muted);
}

.metric-delta {
  font-size: 0.75rem;
  color: var(--status-active);
  display: flex;
  align-items: center;
  gap: 4px;
}

/* ================================================================
   FORMS
   ================================================================ */
.form-group {
  display: flex;
  flex-direction: column;
  gap: 6px;
  margin-bottom: 1rem;
}

.form-label {
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--text-muted);
}

.form-input,
.form-select,
.form-textarea {
  background: var(--bg-elevated);
  border: 1px solid var(--border-default);
  border-radius: var(--radius-md);
  color: var(--text-primary);
  font-family: var(--font-body);
  font-size: 0.9rem;
  padding: 0.65rem 0.9rem;
  transition: border-color 0.18s, box-shadow 0.18s;
  width: 100%;
  outline: none;
  -webkit-appearance: none;
  appearance: none;
}

.form-input:focus,
.form-select:focus,
.form-textarea:focus {
  border-color: var(--text-accent);
  box-shadow: 0 0 0 3px var(--accent-alpha-10);
}

.form-input::placeholder { color: var(--text-muted); opacity: 1; }
.form-select { cursor: pointer; }
.form-textarea { resize: vertical; min-height: 80px; }

/* Form input context variants */
.form-input--sm    { font-size: 0.8rem;  height: 32px; padding: 0.35rem 0.75rem; }
.form-input--xs    { font-size: 0.75rem; height: 28px; padding: 0.28rem 0.6rem;  }
.form-input--mono  { font-family: var(--font-mono); font-size: 0.82rem; }        /* URL, API key, ID fields */
.form-input--wide  { width: 100%; }

.form-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1rem;
}

/* ================================================================
   BUTTONS
   ================================================================ */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  padding: 0.6rem 1.2rem;
  border-radius: var(--radius-md);
  font-family: var(--font-body);
  font-size: 0.85rem;
  font-weight: 700;
  cursor: pointer;
  border: 1px solid transparent;
  transition: all 0.18s ease;
  text-decoration: none;
  white-space: nowrap;
  letter-spacing: 0.03em;
  line-height: 1;
}

.btn svg,
.btn i[data-lucide] { width: 15px; height: 15px; flex-shrink: 0; }

.btn-primary {
  background: var(--text-accent);
  color: var(--bg-void);
  border-color: var(--text-accent);
}
.btn-primary:hover {
  background: var(--text-accent);
  opacity: 0.88;
  border-color: var(--text-accent00);
  box-shadow: 0 0 16px var(--accent-alpha-30);
}

.btn-secondary {
  background: transparent;
  color: var(--text-primary);
  border-color: var(--border-strong);
}
.btn-secondary:hover { background: var(--bg-hover); }

.btn-ghost {
  background: transparent;
  color: var(--text-secondary);
  border-color: transparent;
}
.btn-ghost:hover { background: var(--bg-hover); color: var(--text-primary); }

.btn-danger {
  background: transparent;
  color: var(--status-paused);
  border-color: rgba(239,68,68,0.3);
}
.btn-danger:hover { background: rgba(239,68,68,0.1); }

.btn-sm  { padding: 0.38rem 0.75rem; font-size: 0.78rem; gap: 5px; }
.btn-xs  { padding: 0.2rem  0.5rem;  font-size: 0.72rem; gap: 0.3rem; }
.btn-lg  { padding: 0.8rem  1.8rem;  font-size: 0.95rem; }
.btn-full { width: 100%; }
.btn:disabled { opacity: 0.5; cursor: not-allowed; }

/* ================================================================
   BADGES
   ================================================================ */
.badge {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 0.22rem 0.65rem;
  border-radius: 2px;
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  font-family: var(--font-display);
  border: 1px solid transparent;
}

/* Project lifecycle statuses */
.badge-draft     { background:rgba(148,163,184,0.1); color:#94A3B8;            border-color:rgba(148,163,184,0.2); }
.badge-approved  { background:var(--accent-alpha-10);  color:var(--text-accent); border-color:var(--accent-alpha-20); }
.badge-active    { background:rgba(34,197,94,0.12);  color:var(--status-active); border-color:rgba(34,197,94,0.25); }
.badge-on_hold   { background:rgba(245,158,11,0.12); color:var(--status-pending); border-color:rgba(245,158,11,0.25); }
.badge-completed { background:rgba(34,197,94,0.08);  color:#16A34A;            border-color:rgba(34,197,94,0.15); }
.badge-closed    { background:rgba(100,116,139,0.1); color:#64748B;            border-color:rgba(100,116,139,0.2); }
.badge-cancelled { background:rgba(239,68,68,0.1);   color:var(--status-paused); border-color:rgba(239,68,68,0.2); }
.badge-invoiced  { background:rgba(168,85,247,0.1);  color:#A855F7;            border-color:rgba(168,85,247,0.2); }
.badge-archived  { background:rgba(30,41,59,0.06);   color:var(--text-muted);  border-color:var(--border-default); }
/* Legacy/compat aliases */
.badge-pending  { background: rgba(245,158,11,0.12); color: var(--status-pending);  border-color: rgba(245,158,11,0.25); }
.badge-complete { background: var(--accent-alpha-10); color: var(--status-complete); border-color: var(--accent-alpha-18); }
.badge-paused   { background: rgba(239,68,68,0.12);  color: var(--status-paused);   border-color: rgba(239,68,68,0.25); }
.badge-review   { background: rgba(168,85,247,0.12); color: var(--status-review);   border-color: rgba(168,85,247,0.25); }
.badge-verified { background: var(--accent-alpha-10); color: var(--text-accent);        border-color: var(--accent-alpha-25); }
.badge-linked   { background: rgba(192,132,252,0.08); color: #C084FC;             border-color: rgba(192,132,252,0.22); } /* linked user/account */
.badge-sm       { font-size: 0.62rem; padding: 0.15rem 0.5rem; letter-spacing: 0.08em; } /* compact badge in dense tables */

/* ================================================================
   TABLES
   ================================================================ */
.table-wrap { overflow-x: auto; border-radius: var(--radius-lg); }

table { width: 100%; border-collapse: collapse; font-size: 0.85rem; }

thead tr {
  background: var(--bg-elevated);
  border-bottom: 1px solid var(--border-default);
}

th {
  padding: 0.75rem 1rem;
  text-align: left;
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--text-muted);
  white-space: nowrap;
}

tbody tr {
  border-bottom: 1px solid var(--border-subtle);
  transition: background 0.15s;
}

tbody tr:hover { background: var(--bg-elevated); }
tbody tr:last-child { border-bottom: none; }

td {
  padding: 0.8rem 1rem;
  color: var(--text-primary);
  vertical-align: middle;
}

.td-mono  { font-family: var(--font-mono); font-size: 0.75rem; color: var(--text-secondary); }
.td-muted { color: var(--text-muted); font-size: 0.72rem; margin-top: 2px; }

/* ================================================================
   PROGRESS BARS
   ================================================================ */
.progress-wrap {
  display: flex;
  align-items: center;
  gap: 8px;
}

.progress-track {
  flex: 1;
  height: 4px;
  background: var(--bg-overlay);
  border-radius: 2px;
  overflow: hidden;
}
.progress-track--thin  { height: 3px; }
.progress-track--thick { height: 6px; }

.progress-fill {
  height: 100%;
  background: linear-gradient(90deg, var(--blue-400), var(--blue-200));
  border-radius: 2px;
  transition: width 0.6s cubic-bezier(0.4,0,0.2,1);
}

.progress-fill.green { background: linear-gradient(90deg, #16A34A, #22C55E); }
.progress-fill.amber { background: linear-gradient(90deg, #B45309, #F59E0B); }
.progress-fill.red   { background: linear-gradient(90deg, #B91C1C, #EF4444); }

.progress-pct {
  font-family: var(--font-mono);
  font-size: 0.72rem;
  color: var(--text-muted);
  width: 34px;
  text-align: right;
  flex-shrink: 0;
}

/* ================================================================
   TABS
   ================================================================ */
.tabs {
  display: flex;
  border-bottom: 1px solid var(--border-default);
  margin-bottom: 0;
}

.tab-btn {
  padding: 0.7rem 1.2rem;
  font-family: var(--font-display);
  font-size: 0.82rem;
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--text-muted);
  background: transparent;
  border: none;
  border-bottom: 2px solid transparent;
  cursor: pointer;
  transition: all 0.18s;
  margin-bottom: -1px;
}

.tab-btn:hover { color: var(--text-primary); }
.tab-btn.active { color: var(--text-accent); border-bottom-color: var(--text-accent); }

.tab-panel {
  display: none;
}
.tab-panel.active {
  display: block;
  padding-top: 1.5rem;
}
.tab-panel.active > * + * { margin-top: 1rem; }

/* ================================================================
   FLASH / TOAST
   ================================================================ */
.flash-messages {
  position: fixed;
  top: 1rem;
  right: 1rem;
  z-index: 9999;
  display: flex;
  flex-direction: column;
  gap: 8px;
  max-width: 380px;
}

.flash {
  padding: 0.85rem 1.1rem;
  border-radius: var(--radius-md);
  font-size: 0.85rem;
  display: flex;
  align-items: flex-start;
  gap: 10px;
  box-shadow: var(--shadow-md);
  animation: slideInRight 0.3s ease;
  border-left: 3px solid;
}

.flash-success { background: var(--bg-elevated); border-color: var(--status-active);  color: var(--text-primary); }
.flash-error   { background: var(--bg-elevated); border-color: var(--status-paused);  color: var(--text-primary); }
.flash-info    { background: var(--bg-elevated); border-color: var(--text-accent);        color: var(--text-primary); }

.flash-close {
  margin-left: auto;
  cursor: pointer;
  opacity: 0.5;
  background: none;
  border: none;
  color: inherit;
  font-size: 1rem;
  line-height: 1;
}

#toast-container {
  position: fixed;
  bottom: 1.5rem;
  right: 1.5rem;
  z-index: 9999;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.toast {
  background: var(--bg-elevated);
  border: 1px solid var(--border-strong);
  border-radius: var(--radius-md);
  padding: 0.75rem 1rem;
  font-size: 0.83rem;
  color: var(--text-primary);
  box-shadow: var(--shadow-lg);
  animation: slideInRight 0.3s ease;
  min-width: 250px;
  display: flex;
  align-items: center;
  gap: 8px;
}

.toast.success { border-left: 3px solid var(--status-active); }
.toast.error   { border-left: 3px solid var(--status-paused); }
.toast.info    { border-left: 3px solid var(--text-accent); }

@keyframes slideInRight {
  from { transform: translateX(120%); opacity: 0; }
  to   { transform: translateX(0);    opacity: 1; }
}

@keyframes fadeIn {
  from { opacity: 0; transform: translateY(8px); }
  to   { opacity: 1; transform: translateY(0); }
}

/* ================================================================
   STAR RATINGS
   ================================================================ */
.stars { display: flex; gap: 2px; }
.star { color: var(--status-pending); font-size: 0.75rem; }
.star.empty { color: var(--border-strong); }

/* ================================================================
   WIZARD
   ================================================================ */
.wizard-steps {
  display: flex;
  align-items: flex-start;
  margin-bottom: 2rem;
}

.wizard-step {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
  position: relative;
}

.wizard-step:not(:last-child)::after {
  content: '';
  position: absolute;
  top: 16px;
  left: 50%;
  width: 100%;
  height: 1px;
  background: var(--border-default);
  z-index: 0;
}

.wizard-step.done::after,
.wizard-step.active::after { background: var(--text-accent); }

.step-circle {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: var(--bg-elevated);
  border: 2px solid var(--border-default);
  display: grid;
  place-items: center;
  font-family: var(--font-display);
  font-size: 0.82rem;
  font-weight: 700;
  color: var(--text-muted);
  position: relative;
  z-index: 1;
  transition: all 0.25s;
}

.wizard-step.active .step-circle {
  border-color: var(--text-accent);
  background: var(--accent-alpha-10);
  color: var(--text-accent);
}

.wizard-step.done .step-circle {
  border-color: var(--status-active);
  background: rgba(34,197,94,0.12);
  color: var(--status-active);
}

.step-label {
  font-size: 0.65rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--text-muted);
}

.wizard-step.active .step-label { color: var(--text-accent); }

.wizard-panel { display: none; }
.wizard-panel.active { display: block; animation: fadeIn 0.25s ease; }

/* ================================================================
   ACTIVITY FEED
   ================================================================ */
.activity-item {
  display: flex;
  gap: 10px;
  padding: 0.7rem 0.75rem;
  border-bottom: 1px solid var(--border-subtle);
  align-items: flex-start;
}

.activity-item:last-child { border-bottom: none; }

.activity-icon {
  width: 30px;
  height: 30px;
  border-radius: var(--radius-md);
  background: var(--accent-alpha-07);
  display: grid;
  place-items: center;
  color: var(--text-accent);
  flex-shrink: 0;
}

.activity-icon svg { width: 13px; height: 13px; }
.activity-text { font-size: 0.83rem; font-weight: 300; color: var(--text-secondary); line-height: 1.6; }
.activity-time { font-family: var(--font-mono); font-size: 0.68rem; color: var(--text-muted); margin-top: 2px; }

/* ================================================================
   COLLAPSIBLE
   ================================================================ */
.collapsible-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  cursor: pointer;
  user-select: none;
  padding: 1rem 1.25rem;
  background: var(--bg-surface);
  border: 1px solid var(--border-default);
  border-radius: var(--radius-lg);
  transition: background 0.18s;
}

.collapsible-header:hover { background: var(--bg-elevated); }

.collapsible-header.open {
  border-radius: var(--radius-lg) var(--radius-lg) 0 0;
  border-bottom-color: var(--border-subtle);
}

.collapsible-chevron { transition: transform 0.25s ease; color: var(--text-muted); }
.collapsible-header.open .collapsible-chevron { transform: rotate(180deg); }

.collapsible-body {
  background: var(--bg-surface);
  border: 1px solid var(--border-default);
  border-top: none;
  border-radius: 0 0 var(--radius-lg) var(--radius-lg);
  padding: 1.25rem;
  display: none;
}

.collapsible-body.open { display: block; animation: fadeIn 0.2s ease; }

/* ================================================================
   PROJECT CARDS
   ================================================================ */
.project-card {
  background: var(--bg-surface);
  border: 1px solid var(--border-default);
  border-radius: var(--radius-lg);
  padding: 1.2rem;
  display: flex;
  flex-direction: column;
  gap: 0.85rem;
  transition: all 0.25s ease;
}

.project-card:hover {
  border-color: var(--border-accent);
  box-shadow: var(--shadow-md);
  transform: translateY(-1px);
}

/* ══ Project card — risk modules block ══════════════════════════ */
.pc-risk-block {
  border: 1px solid var(--border-default);
  border-radius: var(--radius-md);
  overflow: hidden;
  margin-bottom: 0.55rem;
  background: var(--bg-surface);
}

/* Header */
.pc-risk-hdr {
  display: flex; align-items: center; justify-content: space-between;
  padding: 0.42rem 0.65rem;
  background: var(--bg-elevated);
  border-bottom: 1px solid var(--border-default);
}
.pc-risk-hdr-l {
  display: flex; align-items: center; gap: 4px;
  font-size: 0.6rem; font-weight: 600; letter-spacing: 0.09em;
  text-transform: uppercase; color: var(--text-muted);
}
.pc-risk-hdr-r {
  font-size: 0.62rem; color: var(--text-secondary);
}
.pc-risk-active-badge {
  font-size: 0.62rem; font-weight: 700; letter-spacing: 0.06em;
  text-transform: uppercase; color: #22C55E;
  background: rgba(34,197,94,0.1); border: 1px solid rgba(34,197,94,0.25);
  padding: 0px 5px; border-radius: 999px;
}
.pc-risk-inactive-badge {
  font-size: 0.62rem; font-weight: 600; letter-spacing: 0.06em;
  text-transform: uppercase; color: var(--text-muted);
  background: var(--bg-overlay); border: 1px solid var(--border-default);
  padding: 0px 5px; border-radius: 999px;
}

/* 6-module grid */
.pc-risk-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1px;
  background: var(--border-default);
  border-bottom: 1px solid var(--border-default);
}

/* Individual module cell */
.pc-mod {
  display: flex; align-items: center; gap: 0.38rem;
  padding: 0.32rem 0.5rem;
  background: var(--bg-surface);
  transition: background 0.15s;
}
.pc-mod--on {
  background: var(--bg-elevated);
}
.pc-mod--off {
  opacity: 0.38;
}
.pc-mod-dot {
  width: 5px; height: 5px; border-radius: 50%; flex-shrink: 0;
  opacity: 0.7;
}
.pc-mod--on .pc-mod-dot { opacity: 1; }
.pc-mod-body {
  display: flex; flex-direction: column; min-width: 0;
}
.pc-mod-name {
  font-size: 0.62rem; font-weight: 600; letter-spacing: 0.02em;
  color: var(--text-secondary); white-space: nowrap;
  overflow: hidden; text-overflow: ellipsis; line-height: 1.2;
}
.pc-mod--on .pc-mod-name { color: var(--text-heading); }
.pc-mod-val {
  font-size: 0.62rem; font-weight: 700;
  color: var(--text-muted); line-height: 1.2;
}
.pc-mod--on .pc-mod-val { color: var(--text-primary); }

/* FaceID row */
.pc-faceid {
  display: flex; align-items: center; gap: 0.4rem;
  padding: 0.3rem 0.5rem;
  border-bottom: 1px solid var(--border-default);
  background: var(--bg-surface);
  color: var(--text-muted);
}
.pc-faceid--on {
  background: rgba(168,85,247,0.05);
  color: #A855F7;
}
.pc-faceid--off {
  opacity: 0.38;
}
.pc-faceid svg { flex-shrink: 0; }
.pc-faceid-name {
  font-size: 0.6rem; font-weight: 700; letter-spacing: 0.04em;
  color: inherit;
}
.pc-faceid--on .pc-faceid-name { color: #A855F7; }
.pc-faceid-tag {
  font-size: 0.60rem; color: var(--text-muted);
  font-weight: 400; letter-spacing: 0.04em;
}
.pc-faceid-status {
  margin-left: auto;
  font-size: 0.62rem; font-weight: 700; letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--text-muted);
}
.pc-faceid-status--on {
  color: #A855F7;
  background: rgba(168,85,247,0.1);
  border: 1px solid rgba(168,85,247,0.25);
  padding: 0px 5px; border-radius: 999px;
}
.pc-faceid-status--off {
  color: var(--text-muted);
}
.pc-faceid-beta {
  font-size: 0.62rem; font-weight: 700; letter-spacing: 0.06em;
  text-transform: uppercase; color: #A855F7;
  background: rgba(168,85,247,0.1); border: 1px solid rgba(168,85,247,0.2);
  padding: 0px 4px; border-radius: 999px;
}

/* Progress bar at the bottom of the block */
.pc-risk-bar {
  height: 3px;
  background: var(--bg-elevated);
  overflow: hidden;
}
/* ══════════════════════════════════════════════════════════════ */


.project-name { font-weight: 700; font-size: 0.95rem; color: var(--text-heading); }
.project-desc { font-size: 0.8rem; font-weight: 300; color: var(--text-muted); line-height: 1.6; }

.project-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
}

.project-meta-item {
  display: flex;
  align-items: center;
  gap: 5px;
  font-size: 0.75rem;
  color: var(--text-secondary);
}

.project-meta-item svg { width: 12px; height: 12px; color: var(--text-muted); }

.project-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-top: 0.5rem;
  border-top: 1px solid var(--border-subtle);
  font-size: 0.75rem;
  color: var(--text-muted);
}

/* ================================================================
   MISC COMPONENTS
   ================================================================ */
.switch-banner {
  background: var(--accent-alpha-07);
  border: 1px solid var(--border-accent);
  border-radius: var(--radius-md);
  padding: 0.6rem 1rem;
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 0.82rem;
  color: var(--text-secondary);
  margin-bottom: 1rem;
}

.plan-card {
  background: var(--bg-elevated);
  border: 2px solid var(--border-default);
  border-radius: var(--radius-lg);
  padding: 1.5rem;
  text-align: center;
  cursor: pointer;
  transition: all 0.2s;
  display: block;
}

.plan-card:hover { border-color: var(--text-accent); }
.plan-card.selected { border-color: var(--text-accent); background: var(--accent-alpha-05); }

.plan-price { font-family: var(--font-display); font-size: 2.2rem; font-weight: 800; color: var(--text-heading); line-height: 1; margin: 0.25rem 0; }
.plan-price span { font-size: 0.9rem; color: var(--text-muted); font-weight: 400; }
.plan-name { font-family: var(--font-display); font-size: 0.78rem; letter-spacing: 0.15em; text-transform: uppercase; color: var(--text-muted); }

.client-switch-select {
  background: var(--bg-elevated);
  border: 1px solid var(--border-default);
  border-radius: var(--radius-md);
  color: var(--text-primary);
  font-family: var(--font-body);
  font-size: 0.8rem;
  padding: 0.4rem 0.8rem;
  cursor: pointer;
  outline: none;
  -webkit-appearance: none;
  appearance: none;
}

.divider {
  height: 1px;
  background: var(--border-default);
  margin: 1.25rem 0;
}

.empty-state {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 3rem;
  text-align: center;
  color: var(--text-muted);
  gap: 0.75rem;
}

.empty-state svg { opacity: 0.3; }
.empty-state p { font-size: 0.85rem; }

/* ================================================================
   UTILITY CLASSES
   ================================================================ */
.flex           { display: flex; }
.flex-col       { flex-direction: column; }
.items-center   { align-items: center; }
.justify-between{ justify-content: space-between; }
.gap-1          { gap: 0.5rem; }
.gap-2          { gap: 1rem; }
.gap-3          { gap: 1.5rem; }
.mt-1           { margin-top: 0.5rem; }
.mt-2           { margin-top: 1rem; }
.mt-3           { margin-top: 1.5rem; }
.mb-1           { margin-bottom: 0.5rem; }
.mb-2           { margin-bottom: 1rem; }
.text-sm        { font-size: 0.82rem; }
.text-xs        { font-size: 0.72rem; }
.text-muted     { color: var(--text-muted); }
.text-accent    { color: var(--text-accent); }
.text-right     { text-align: right; }
.font-mono      { font-family: var(--font-mono); }
.truncate       { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.w-full         { width: 100%; }

/* ================================================================
   RESPONSIVE
   ================================================================ */
/* ── Responsive: Tablet (≤ 1024px) ── */
@media (max-width: 1024px) {
  /* Auth */
  .auth-middle          { grid-template-columns: 1fr; grid-template-rows: auto auto; }
  .auth-brand           { display: flex; border-right: none; border-bottom: 1px solid var(--border-default); padding: 2.5rem 2rem; order: 1; }
  .auth-brand h2        { font-size: 2rem; }
  .auth-panel           { padding: 2.5rem; order: 2; }
  .auth-panel .center   { align-items: center; }
  .auth-header          { padding: 0.5rem 1.5rem; }
  .auth-footer          { flex-direction: column; gap: 0.3rem; padding: 0.75rem 1rem; }
  .auth-footer-left,
  .auth-footer-right,
  .copyright            { text-align: center; font-size: 0.75rem; }

  /* App sidebar: narrower */
  :root                 { --sidebar-w: 200px; }

  /* Dashboard: stack projects + activity vertically */
  .dashboard-cols       { grid-template-columns: 1fr !important; }

  /* Account: collapse side-by-side grids */
  .account-grid         { grid-template-columns: 1fr !important; }

  /* App grids */
  .grid-4, .Status_Projects, .Status_Screeners, .Status_Panel, .Status_Communities               { grid-template-columns: repeat(2, 1fr); }
  .grid-3               { grid-template-columns: repeat(2, 1fr); }
}

/* ── Responsive: Mobile (≤ 640px) ── */
@media (max-width: 640px) {
  /* Auth */
  .auth-header          { padding: 0.45rem 1rem; }
  .brand-icon           { width: 22px; height: 22px; }
  .brand-name           { font-size: 1rem; }
  .brand-tagline        { display: none; }
  .auth-brand           { padding: 1.5rem 1.25rem; order: 1; }
  .auth-brand h2        { font-size: 1.5rem; margin-bottom: 0.6rem; }
  .auth-brand > p       { display: none; }
  .auth-panel           { padding: 1.75rem; order: 2; }
  .auth-panel .center   { align-items: center; }
  .auth-form-header     { margin-bottom: 1.5rem; }
  .auth-form-header h3  { font-size: 1.3rem; }

  /* Trend section: stack chart on top, stat cards below */
  .trend-section        { grid-template-columns: 1fr; grid-template-rows: auto auto; }
  .trend-stat-cards     { flex-direction: row; width: 100%; justify-content: stretch; }
  .trend-stat-card      { flex: 1; }

  /* Fix chart height on mobile so it doesn't collapse */
  .trend-chart-canvas-wrap { min-height: 180px; }

  /* Trust strip: stop overlapping login-form-box on mobile */
  .auth-trust-strip     { flex-wrap: wrap; gap: 0.4rem; padding: 0.5rem 0; margin-top: 1rem; }
  .auth-trust-item      { padding: 0 0.5rem; white-space: normal; }

  /* Login form box: natural height on mobile, don't stretch */
  .login-form-box       { flex: none; width: 95%; }
  .login-form-box > form { flex: none; }
  .login-form-box > form > button[type="submit"] { margin-top: 1rem; }

  /* App panel: natural flow on mobile */
  .auth-panel           { height: auto; overflow-y: visible; }
  .auth-panel .center:last-of-type { flex: none; margin-top: 1.5rem; }
  .auth-footer          { padding: 0.6rem 1rem; gap: 0.2rem; }
  .auth-footer-left,
  .auth-footer-right,
  .copyright            { font-size: 0.75rem; }
}

/* ── App shell: collapse sidebar on tablets + phones ── */
@media (max-width: 900px) {
  /* Sidebar slides in from left */
  .sidebar              { transform: translateX(-100%); transition: transform 0.28s cubic-bezier(0.4,0,0.2,1); }
  .sidebar.open         { transform: translateX(0); box-shadow: 4px 0 24px rgba(0,0,0,0.35); }
  .main-content         { margin-left: 0; width: 100vw; max-width: 100vw; }
  .topbar               { grid-template-columns: auto 1fr auto; gap: 0.5rem; }
  .topbar-search-wrap   { display: none; }
  .page-title           { font-size: 0.95rem; }

  /* Show hamburger */
  .mobile-menu-btn      { display: flex !important; }

  /* Sidebar close button visible */
  .sidebar-mobile-close { display: flex !important; }
}

/* ── Narrow phones only ── */
@media (max-width: 640px) {
  .grid-4, .Status_Projects, .Status_Screeners, .Status_Panel, .Status_Communities, .grid-3, .grid-2 { grid-template-columns: 1fr; }
  .form-row             { grid-template-columns: 1fr; }

  /* Dashboard */
  .dashboard-cols       { grid-template-columns: 1fr !important; }
  .metric-value         { font-size: 1.5rem; }

  /* Wizard modal: full screen */
  .wizard-modal-inner   { width: 95vw !important; max-height: 90vh; overflow-y: auto; margin: 1rem; }

  /* Account page */
  .account-grid         { grid-template-columns: 1fr !important; }
  .account-invite-row   { grid-template-columns: 1fr !important; }

  /* Tables: horizontal scroll */
  .table-wrap           { overflow-x: auto; -webkit-overflow-scrolling: touch; }
  table                 { min-width: 540px; }

  /* Cards: reduce padding */
  .card                 { padding: 1rem; }
  .page-body            { padding: 1rem; }

  /* Profile picture card */
  .picture-meta         { flex-wrap: wrap; }

  /* Projects grid */
  .grid-3               { grid-template-columns: 1fr; }
}



/* ================================================================
   TOPBAR USER IDENTITY CHIP
   ================================================================ */

.topbar-user-chip {
  display: flex;
  align-items: center;
  gap: 10px;
  /* info left, avatar right — padding tighter on left, more on right */
  padding: 5px 5px 5px 10px;
  border-radius: var(--radius-lg);
  border: 1px solid var(--border-default);
  background: var(--bg-elevated);
  text-decoration: none;
  cursor: pointer;
  transition: all 0.18s ease;
  max-width: 260px;
}

.topbar-user-chip:hover {
  border-color: var(--border-accent);
  background: var(--bg-hover);
  box-shadow: var(--shadow-sm);
}

/* Name + role text block — LEFT side */
.topbar-user-info {
  display: flex;
  flex-direction: column;
  gap: 1px;
  min-width: 0;
  text-align: right;
}

.topbar-user-name {
  font-size: 0.82rem;
  font-weight: 600;
  color: var(--text-primary);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  line-height: 1.2;
}

.topbar-user-role {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 4px;
  font-size: 0.68rem;
  color: var(--text-muted);
  white-space: nowrap;
  font-weight: 500;
}

.topbar-role-icon {
  width: 11px !important;
  height: 11px !important;
  flex-shrink: 0;
  color: var(--text-muted);
}

/* Avatar — RIGHT side */
.topbar-avatar {
  width: 30px;
  height: 30px;
  border-radius: var(--radius-md);
  background: linear-gradient(135deg, #8A6B30, var(--text-accent));
  display: grid;
  place-items: center;
  font-family: var(--font-display);
  font-size: 0.72rem;
  font-weight: 800;
  color: #fff;
  letter-spacing: 0.03em;
  flex-shrink: 0;
}

/* Login-type badge — shown next to client switcher, NOT inside chip */
.topbar-id-badge {
  display: inline-flex;
  align-items: center;
  padding: 3px 8px;
  border-radius: 2px;
  font-family: var(--font-display);
  font-size: 0.6rem;
  font-weight: 800;
  letter-spacing: 0.14em;
  flex-shrink: 0;
  border: 1px solid transparent;
  white-space: nowrap;
}

.topbar-id-badge--primary {
  background: var(--accent-alpha-10);
  color: var(--text-accent);
  border-color: rgba(201,163,110,0.25);
}

.topbar-id-badge--secondary {
  background: rgba(192,132,252,0.12);
  color: #C084FC;
  border-color: rgba(192,132,252,0.3);
}

.topbar-id-badge--tertiary {
  background: rgba(245,158,11,0.12);
  color: #FBBF24;
  border-color: rgba(245,158,11,0.3);
}

/* Client switch group: select + badge side-by-side */
.client-switch-group {
  display: flex;
  align-items: center;
  gap: 8px;
}

/* Thin vertical divider */
.topbar-divider {
  width: 1px;
  height: 22px;
  background: var(--border-default);
  flex-shrink: 0;
}

/* ================================================================
   SUPER ADMIN BADGE
   ================================================================ */

.topbar-id-badge--super {
  background: linear-gradient(135deg, rgba(245,158,11,0.22), rgba(251,191,36,0.12));
  color: #FBBF24;
  border-color: rgba(245,158,11,0.55);
  box-shadow: 0 0 10px rgba(245,158,11,0.22), inset 0 0 6px rgba(245,158,11,0.06);
  letter-spacing: 0.18em;
}

.topbar-avatar--super {
  background: linear-gradient(135deg, #B45309, #F59E0B) !important;
  box-shadow: 0 0 12px rgba(245,158,11,0.35);
}

/* ================================================================
   TOPBAR GLOBAL SEARCH
   ================================================================ */

/* Make topbar a 3-col layout: left | search | right */
.topbar {
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: center;
  gap: 1rem;
}

.topbar-left  { min-width: 0; }
.topbar-right { display: flex; align-items: center; gap: 0.75rem; justify-content: flex-end; flex-shrink: 0; }

.topbar-search-wrap {
  position: relative;
  width: 100%;
  max-width: 440px;
  margin: 0 auto;
}

.topbar-search-box {
  display: flex;
  align-items: center;
  gap: 8px;
  background: var(--bg-elevated);
  border: 1px solid var(--border-default);
  border-radius: var(--radius-md);
  padding: 0 0.75rem;
  height: 36px;
  transition: border-color 0.18s, box-shadow 0.18s;
}

.topbar-search-box:focus-within {
  border-color: var(--text-accent);
  box-shadow: 0 0 0 3px var(--accent-alpha-08);
  background: var(--bg-surface);
}

.search-icon {
  width: 14px;
  height: 14px;
  color: var(--text-muted);
  flex-shrink: 0;
}

.topbar-search-input {
  flex: 1;
  background: transparent;
  border: none;
  outline: none;
  font-family: var(--font-body);
  font-size: 0.85rem;
  color: var(--text-primary);
  min-width: 0;
}

.topbar-search-input::placeholder {
  color: var(--text-muted);
  font-size: 0.82rem;
}

.search-kbd {
  font-family: var(--font-mono);
  font-size: 0.62rem;
  color: var(--text-muted);
  background: var(--bg-overlay);
  border: 1px solid var(--border-default);
  border-radius: 3px;
  padding: 1px 5px;
  flex-shrink: 0;
  white-space: nowrap;
  user-select: none;
}

/* ── Search Dropdown ── */
.search-dropdown {
  position: absolute;
  top: calc(100% + 6px);
  left: 0;
  right: 0;
  background: var(--bg-surface);
  border: 1px solid var(--border-strong);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-lg);
  z-index: 500;
  overflow: hidden;
  max-height: 420px;
  overflow-y: auto;
  display: none;
}

.search-dropdown.open {
  display: block;
  animation: fadeIn 0.15s ease;
}

.search-empty,
.search-no-results {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 1.5rem;
  color: var(--text-muted);
  font-size: 0.82rem;
}

.search-loading {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 0.85rem 1rem;
  color: var(--text-muted);
  font-size: 0.82rem;
}

.search-group-label {
  padding: 0.5rem 1rem 0.25rem;
  font-size: 0.62rem;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--text-muted);
  background: var(--bg-elevated);
  border-bottom: 1px solid var(--border-subtle);
  position: sticky;
  top: 0;
  z-index: 1;
}

.search-result-item {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 0.65rem 1rem;
  text-decoration: none;
  border-bottom: 1px solid var(--border-subtle);
  transition: background 0.12s;
  cursor: pointer;
}

.search-result-item:last-child { border-bottom: none; }

.search-result-item:hover {
  background: var(--bg-hover);
}

.search-result-icon {
  width: 28px;
  height: 28px;
  border-radius: var(--radius-sm);
  display: grid;
  place-items: center;
  flex-shrink: 0;
}

.search-result-text {
  display: flex;
  flex-direction: column;
  gap: 2px;
  min-width: 0;
  flex: 1;
}

.search-result-label {
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--text-primary);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.search-result-sub {
  font-family: var(--font-mono);
  font-size: 0.68rem;
  color: var(--text-muted);
}

.search-result-badge {
  flex-shrink: 0;
  font-size: 0.6rem;
}

/* Spinner */
@keyframes spin {
  from { transform: rotate(0deg); }
  to   { transform: rotate(360deg); }
}
.spin { animation: spin 0.8s linear infinite; display: inline-block; }

/* ── Auth Trust Strip ── */
.auth-trust-strip {
  display: flex;
  align-items: center;
  justify-content: center;
  margin-top: 1rem;
  padding: 0.7rem 0.5rem;
}
.auth-trust-item {
  display: flex;
  align-items: center;
  gap: 5px;
  font-size: 0.68rem;
  font-weight: 600;
  letter-spacing: 0.06em;
  color: var(--text-muted);
  padding: 0 0.85rem;
  white-space: nowrap;
}
.auth-trust-icon { width: 12px !important; height: 12px !important; flex-shrink: 0; color: var(--text-accent); }
.auth-trust-sep  { width: 1px; height: 14px; background: var(--border-default); flex-shrink: 0; }

/* ================================================================
   PROFILE PICTURE CARD
   ================================================================ */

.profile-picture-card {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1rem;
  padding: 1.75rem 1.25rem;
  background: var(--bg-surface);
  border: 1px solid var(--border-default);
  border-radius: var(--radius-lg);
  margin-bottom: 1.25rem;
  position: relative;
  overflow: hidden;
}

.profile-picture-card::before {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 80px;
  background: linear-gradient(135deg, var(--blue-800), var(--blue-600));
  opacity: 0.35;
  z-index: 0;
}

/* ── Avatar circle ── */
.picture {
  position: relative;
  z-index: 1;
}

.picture-avatar {
  width: 88px;
  height: 88px;
  border-radius: 50%;
  background: linear-gradient(135deg, #8A6B30, var(--text-accent));
  display: grid;
  place-items: center;
  overflow: hidden;
  border: 3px solid var(--bg-surface);
  box-shadow: 0 4px 16px rgba(0,0,0,0.3);
  cursor: pointer;
  transition: box-shadow 0.2s;
  position: relative;
}

.picture-avatar:hover {
  box-shadow: 0 4px 20px var(--accent-alpha-38);
}

.picture-avatar:hover /* Two-icon overlay — edit + remove, appears on hover */
.picture-edit-overlay {
  position: absolute;
  inset: 0;
  border-radius: 50%;
  background: rgba(0,0,0,0.5);
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  opacity: 0;
  transition: opacity 0.2s ease;
  z-index: 2;
}

.picture-overlay-btn {
  background: rgba(255,255,255,0.12);
  border: 1px solid rgba(255,255,255,0.25);
  border-radius: 50%;
  width: 36px;
  height: 36px;
  display: grid;
  place-items: center;
  cursor: pointer;
  transition: background 0.15s, transform 0.15s;
  flex-shrink: 0;
}

.picture-overlay-btn:hover {
  background: rgba(255,255,255,0.28);
  transform: scale(1.1);
}

.picture-overlay-btn--danger:hover {
  background: rgba(239,68,68,0.55);
  border-color: rgba(239,68,68,0.6);
}

#picture-initials {
  font-family: var(--font-display);
  font-size: 1.8rem;
  font-weight: 800;
  color: #fff;
  letter-spacing: 0.04em;
  user-select: none;
  position: relative;
  z-index: 1;
}



/* ── Identity below photo ── */
.picture-identity {
  text-align: center;
  z-index: 1;
}

.picture-name {
  font-family: var(--font-display);
  font-size: 1.2rem;
  font-weight: 700;
  color: var(--text-heading);
  letter-spacing: 0.02em;
  margin-bottom: 0.35rem;
}

/* company + email on the same row */
.picture-meta {
  display: flex;
  flex-direction: row;
  align-items: center;
  justify-content: center;
  flex-wrap: wrap;
  gap: 0.4rem;
}

.picture-meta-sep {
  color: var(--border-strong);
  font-size: 0.75rem;
  line-height: 1;
}

.picture-company,
.picture-role,
.picture-email {
  font-size: 0.8rem;
  color: var(--text-muted);
  display: flex;
  align-items: center;
  gap: 4px;
  white-space: nowrap;
}

.picture-company {
  font-weight: 500;
  color: var(--text-secondary);
}

.picture-role {
  font-weight: 600;
  color: var(--text-accent);
}

/* ================================================================
   MOBILE MENU BUTTON + SIDEBAR OVERLAY
   ================================================================ */

.mobile-menu-btn {
  display: none;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  border-radius: var(--radius-md);
  border: 1px solid var(--border-default);
  background: var(--bg-surface);
  color: var(--text-secondary);
  cursor: pointer;
  flex-shrink: 0;
  transition: background 0.15s, color 0.15s;
}
@media (max-width: 900px) {
  .mobile-menu-btn { display: flex; }
}
.mobile-menu-btn:hover {
  background: var(--bg-hover);
  color: var(--text-primary);
}

.sidebar-overlay {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.5);
  z-index: 99;
  backdrop-filter: blur(2px);
}

/* Responsive: wizard modals */
@media (max-width: 640px) {
  #wizard-overlay > div { width: 95vw !important; max-width: none !important; }
}

/* Responsive: dashboard activity + project columns */
@media (max-width: 768px) {
  .grid-4, .Status_Projects, .Status_Screeners, .Status_Panel, .Status_Communities { grid-template-columns: repeat(2, 1fr); }
}

/* ================================================================
   LOGIN PAGE — FORM ENHANCEMENTS
   ================================================================ */

/* Inline flash messages inside the form box */
.login-flash {
  display: flex;
  align-items: flex-start;
  gap: 8px;
  padding: 0.65rem 0.85rem;
  border-radius: var(--radius-md);
  font-size: 0.83rem;
  margin-bottom: 1rem;
  border-left: 3px solid;
  line-height: 1.5;
}
.login-flash--error   { background: rgba(239,68,68,0.08);  border-color: #EF4444; color: #FCA5A5; }
.login-flash--success { background: rgba(34,197,94,0.08);  border-color: #22C55E; color: #86EFAC; }
.login-flash--info,
.login-flash--message { background: var(--accent-alpha-07); border-color: var(--text-accent); color: var(--text-accent); }

/* Remember me + forgot password row */
.login-form-meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-top: 0.5rem;
  margin-bottom: 1.5rem;
}

.login-remember {
  display: flex;
  align-items: center;
  gap: 7px;
  font-size: 0.82rem;
  color: var(--text-secondary);
  cursor: pointer;
  user-select: none;
}

.login-remember input[type="checkbox"] {
  width: 14px;
  height: 14px;
  accent-color: var(--text-accent);
  cursor: pointer;
  flex-shrink: 0;
}

.login-forgot {
  font-size: 0.8rem;
  color: var(--text-accent);
  text-decoration: none;
  transition: color 0.15s;
}
.login-forgot:hover { color: var(--text-accent); text-decoration: underline; }

/* Spinner animation for loading state */

/* ================================================================
   SCREENER FRAUD FILTER TOGGLES
   ================================================================ */
.screener-toggle { cursor: pointer; }
.screener-toggle-pill {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 0.3rem 0.75rem;
  border-radius: 20px;
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.04em;
  border: 1px solid var(--border-default);
  background: var(--bg-overlay);
  color: var(--text-muted);
  cursor: pointer;
  transition: background 0.15s, border-color 0.15s, color 0.15s;
  user-select: none;
}

/* ================================================================
   HOME / LANDING PAGE
   ================================================================ */

/* ================================================================
   HOME PAGE — Theme K: Platinum Light / Obsidian Amber Dark
   ================================================================ */

/* ── Wrapper ── */
.K-wrap { min-height:100vh; display:flex; flex-direction:column; background:var(--bg-void); }

/* ── Nav ── */
.K-nav {
  position:sticky; top:0; z-index:100;
  height:56px; display:flex; align-items:center; justify-content:space-between;
  padding:0 3rem;
  background:var(--bg-base);
  border-bottom:1px solid var(--border-default);
}
/* DEPRECATED: .K-nav-l replaced by .reg-card-brand (single source). */
/* .K-nav-l  { display:flex; align-items:center; gap:.85rem; } */
.K-nb     { display:flex; align-items:center; gap:9px; text-decoration:none; }
.K-ni {
  width:30px; height:30px; border-radius:6px;
  background:var(--text-accent);
  display:grid; place-items:center;
  box-shadow:0 0 14px var(--shadow-glow);
}
.K-ni svg { width:15px; height:15px; color:var(--bg-void); }
.K-nm {
  font-family:var(--font-display); font-size:1rem;
  font-weight:600; font-style:italic;
  color:var(--text-heading); letter-spacing:-.01em;
}
.K-nm sup { font-size:.48em; vertical-align:super; font-style:normal; }
.K-nsep { width:1px; height:16px; background:var(--border-default); }
.K-nt { font-size:.62rem; font-weight:600; letter-spacing:.14em; text-transform:uppercase; color:var(--text-muted); }
.K-nl-wrap { display:flex; gap:.15rem; }
.K-nl { font-size:.8rem; font-weight:500; color:var(--text-secondary); text-decoration:none; padding:.35rem .72rem; border-radius:5px; transition:all .15s; }
.K-nl:hover { color:var(--text-heading); background:var(--bg-elevated); }
.K-nav-r { display:flex; align-items:center; gap:.55rem; }
.K-nsi { font-size:.78rem; font-weight:500; color:var(--text-secondary); text-decoration:none; padding:.38rem .85rem; border:1px solid var(--border-default); border-radius:5px; transition:all .15s; }
.K-nsi:hover { border-color:var(--border-strong); color:var(--text-heading); }
.K-nct { font-size:.78rem; font-weight:700; color:var(--bg-void); background:var(--text-accent); text-decoration:none; padding:.4rem 1.1rem; border-radius:5px; transition:all .18s; }
.K-nct:hover { opacity:.88; transform:translateY(-1px); }
.K-ntb { width:28px; height:28px; border-radius:5px; border:1px solid var(--border-default); background:transparent; color:var(--text-secondary); cursor:pointer; display:grid; place-items:center; transition:all .15s; }
.K-ntb:hover { border-color:var(--border-strong); color:var(--text-heading); }

/* ── Hero ── */
.K-hero {
  position:relative; min-height:calc(100vh - 56px);
  display:flex; align-items:center; padding:0 3rem; overflow:hidden;
  background:var(--bg-void);
}
.K-h-grid {
  position:absolute; inset:0;
  background-image:linear-gradient(var(--border-subtle) 1px,transparent 1px),
    linear-gradient(90deg,var(--border-subtle) 1px,transparent 1px);
  background-size:64px 64px; pointer-events:none;
}
.K-h-o1 { position:absolute; top:-18%; left:-8%; width:58vw; height:58vh; border-radius:50%; background:radial-gradient(ellipse,var(--shadow-glow) 0%,transparent 65%); filter:blur(55px); pointer-events:none; }
.K-h-o2 { position:absolute; bottom:-15%; right:-5%; width:42vw; height:42vh; border-radius:50%; background:radial-gradient(ellipse,var(--accent-alpha-04) 0%,transparent 65%); filter:blur(65px); pointer-events:none; }
.K-h-inner { position:relative; z-index:1; display:grid; grid-template-columns:1fr 440px; gap:5rem; align-items:center; max-width:1400px; width:100%; }
.K-h-pill { display:inline-flex; align-items:center; gap:.5rem; font-size:.65rem; font-weight:700; letter-spacing:.18em; text-transform:uppercase; color:var(--text-accent); margin-bottom:1.75rem; padding:.3rem .82rem; border:1px solid var(--border-default); border-radius:100px; background:var(--accent-alpha-06); }
.K-h-dot { width:5px; height:5px; border-radius:50%; background:var(--status-active); box-shadow:0 0 6px rgba(56,160,96,.5); animation:K-pulse 2s infinite; }
@keyframes K-pulse { 0%,100%{opacity:1}50%{opacity:.4} }
.K-h1 { font-family:var(--font-display); font-size:4.8rem; font-weight:700; font-style:italic; line-height:.93; letter-spacing:-.04em; color:var(--text-heading); margin-bottom:1.5rem; }
.K-ac { color:var(--text-accent); display:block; font-style:normal; }
.K-h-sub { font-size:1rem; font-weight:300; color:var(--text-secondary); line-height:1.78; max-width:500px; margin-bottom:2.5rem; }
.K-h-btns { display:flex; gap:.8rem; align-items:center; margin-bottom:2.25rem; flex-wrap:wrap; }
.K-btn-p { font-family:var(--font-display); font-size:.86rem; font-weight:700; font-style:italic; color:var(--bg-void); background:var(--text-accent); text-decoration:none; padding:.8rem 1.9rem; border-radius:6px; transition:all .18s; display:inline-flex; align-items:center; gap:.45rem; box-shadow:var(--shadow-glow); }
.K-btn-p:hover { opacity:.88; transform:translateY(-2px); }
.K-btn-g { font-size:.86rem; font-weight:500; color:var(--text-secondary); text-decoration:none; padding:.8rem 1.65rem; border:1px solid var(--border-default); border-radius:6px; transition:all .18s; display:inline-flex; align-items:center; gap:.45rem; }
.K-btn-g:hover { border-color:var(--border-strong); color:var(--text-heading); }
.K-h-diff {
  display: inline-flex;
  align-items: center;
  gap: .5rem;
  font-size: .78rem;
  font-weight: 500;
  color: var(--text-secondary);
  margin-bottom: 1.75rem;
  padding: .32rem .85rem .32rem .55rem;
  border: 1px solid var(--border-default);
  border-radius: 100px;
  background: var(--bg-surface);
}
.K-h-diff-icon {
  width: 18px; height: 18px;
  border-radius: 50%;
  background: var(--text-accent);
  display: grid; place-items: center;
  flex-shrink: 0;
}
.K-h-diff-icon svg { color: var(--bg-void); }

.K-tc { display:inline-flex; align-items:center; gap:.3rem; font-size:.7rem; font-weight:500; color:var(--text-muted); padding:.26rem .65rem; border:1px solid var(--border-subtle); border-radius:100px; }
.K-tck { color:var(--status-active); }

/* ── Terminal ── */
.K-terminal { background:var(--bg-void); border:1px solid var(--border-default); border-radius:6px; overflow:hidden; box-shadow:var(--shadow-lg); position:relative; font-family:var(--font-mono); }
.K-terminal::before { content:''; position:absolute; top:0; left:0; right:0; height:2px; background:linear-gradient(90deg,var(--blue-600),var(--text-accent),var(--blue-200),var(--text-accent)); background-size:200% 100%; animation:K-slide 3s linear infinite; }
@keyframes K-slide { to{background-position:-200% 0} }
.K-tb { display:flex; align-items:center; gap:.6rem; padding:.6rem 1rem; background:var(--bg-base); border-bottom:1px solid var(--border-subtle); }
.K-td { display:flex; gap:5px; }
.K-tdot { width:9px; height:9px; border-radius:50%; }
.K-tt { font-family:var(--font-mono); font-size:.6rem; letter-spacing:.1em; color:var(--text-muted); margin-left:auto; }
.K-tbody { padding:1.1rem 1.25rem; display:flex; flex-direction:column; gap:.15rem; background:var(--bg-void); }
.K-tcmd { display:flex; gap:.5rem; margin-bottom:.35rem; }
.K-tp { color:var(--text-accent); font-size:.78rem; }
.K-tct { font-size:.78rem; color:var(--text-heading); font-weight:700; }
.K-tf { color:var(--text-accent); }
.K-tco { font-size:.7rem; color:var(--text-muted); margin-top:.28rem; }
.K-tck2 { font-size:.7rem; color:var(--text-secondary); }
.K-tick { color:var(--status-active); margin-right:.2rem; }
.K-ten { font-size:.7rem; color:var(--text-secondary); }
.K-tcl { color:var(--status-active); font-weight:700; }
.K-tbl { color:var(--status-paused); font-weight:700; }
.K-tsum { font-size:.74rem; font-weight:700; color:var(--text-accent); margin-top:.5rem; margin-bottom:.65rem; }
.K-tcards { display:grid; grid-template-columns:1fr 1fr; gap:.4rem; }
.K-tcard { background:var(--bg-surface); border:1px solid var(--border-default); border-radius:5px; padding:.72rem .8rem; }
.K-tcv { font-family:var(--font-mono); font-size:1.18rem; font-weight:700; color:var(--text-accent); line-height:1; margin-bottom:.22rem; }
.K-tcl2 { font-size:.62rem; font-weight:600; letter-spacing:.1em; text-transform:uppercase; color:var(--text-muted); margin-bottom:.28rem; }
.K-tcd { font-size:.6rem; color:var(--status-active); font-style:italic; }

/* ── Shared section layout ── */
.K-S { padding:5.5rem 3rem; border-top:1px solid var(--border-subtle); background:var(--bg-void); }
.K-alt { background:var(--bg-base); }
.K-Si { max-width:1400px; margin:0 auto; }
.K-Sh { margin-bottom:3rem; }
.K-Se { display:inline-flex; align-items:center; gap:.35rem; font-size:.62rem; font-weight:700; letter-spacing:.2em; text-transform:uppercase; color:var(--text-accent); margin-bottom:.85rem; padding:.22rem .65rem; border:1px solid var(--border-default); border-radius:100px; background:var(--accent-alpha-06); }
.K-h2 { font-family:var(--font-display); font-size:2.4rem; font-weight:600; font-style:italic; letter-spacing:-.025em; color:var(--text-heading); line-height:1.05; margin-bottom:.75rem; }
.K-Ss { font-size:.9rem; color:var(--text-secondary); line-height:1.75; max-width:540px; font-weight:300; }

/* ── Universal card ── */
.K-G3 { display:grid; grid-template-columns:repeat(3,1fr); gap:1.15rem; margin-top:2.25rem; }
.K-G2 { display:grid; grid-template-columns:repeat(2,1fr); gap:1.15rem; margin-top:2.25rem; }
.K-G4 { display:grid; grid-template-columns:repeat(4,1fr); gap:1.15rem; margin-top:2.25rem; }
.K-C {
  background:var(--bg-surface); border:1px solid var(--border-default);
  border-radius:6px; padding:1.65rem;
  position:relative; overflow:hidden;
  transition:border-color .22s, box-shadow .22s, transform .22s;
}
.K-C::after { content:''; position:absolute; top:0; left:0; right:0; height:2px; background:var(--text-accent); transform:scaleX(0); transform-origin:left; transition:transform .28s ease; }
.K-C:hover { border-color:var(--border-strong); box-shadow:var(--shadow-md); transform:translateY(-3px); }
.K-C:hover::after { transform:scaleX(1); }
.K-C:hover .K-ci { transform:scale(1.08); }
.K-Cn { font-family:var(--font-mono); font-size:.62rem; font-weight:500; letter-spacing:.12em; color:var(--text-muted); margin-bottom:.9rem; }
.K-ci { width:38px; height:38px; border-radius:6px; display:grid; place-items:center; background:var(--accent-alpha-08); color:var(--text-accent); margin-bottom:.9rem; transition:transform .22s; flex-shrink:0; }
.K-ct { display:inline-block; font-size:.62rem; font-weight:700; letter-spacing:.12em; text-transform:uppercase; color:var(--text-accent); padding:.16rem .5rem; border:1px solid var(--border-default); border-radius:100px; margin-bottom:.8rem; }
.K-Ch { display:flex; align-items:flex-start; justify-content:space-between; margin-bottom:.8rem; }
.K-C h4 { font-family:var(--font-display); font-size:.96rem; font-weight:700; color:var(--text-heading); margin-bottom:.48rem; line-height:1.2; }
.K-C p { font-size:.82rem; color:var(--text-secondary); line-height:1.68; font-weight:300; }

/* Step connector */
.K-step { position:relative; }
.K-SC-n { font-family:var(--font-display); font-size:2.6rem; font-weight:900; font-style:italic; color:var(--border-default); line-height:1; margin-bottom:.8rem; letter-spacing:-.04em; }
.K-SC-line { position:absolute; top:2.5rem; left:calc(1.65rem + 2.6rem * .88); right:-1.15rem; height:1px; background:var(--border-default); }
.K-G4 .K-C:last-child .K-SC-line { display:none; }

/* Advantage cards */
.K-AC { background:var(--bg-surface); border:1px solid var(--border-default); border-radius:6px; padding:1.65rem; display:flex; gap:1.15rem; position:relative; overflow:hidden; transition:border-color .22s, transform .22s; }
.K-AC::before { content:''; position:absolute; left:0; top:0; bottom:0; width:3px; background:var(--text-accent); transform:scaleY(0); transform-origin:top; transition:transform .28s ease; }
.K-AC:hover { border-color:var(--border-strong); transform:translateY(-2px); }
.K-AC:hover::before { transform:scaleY(1); }
.K-AC-n { font-family:var(--font-display); font-size:2.4rem; font-weight:900; font-style:italic; color:var(--border-default); line-height:1; flex-shrink:0; width:48px; letter-spacing:-.04em; transition:color .22s; }
.K-AC:hover .K-AC-n { color:var(--border-strong); }
.K-AC-b h4 { font-family:var(--font-display); font-size:.93rem; font-weight:700; color:var(--text-heading); margin-bottom:.45rem; }
.K-AC-b p { font-size:.8rem; color:var(--text-secondary); line-height:1.7; margin-bottom:.8rem; font-weight:300; }
.K-vs { display:flex; flex-direction:column; gap:.28rem; padding-top:.7rem; border-top:1px solid var(--border-subtle); }
.K-vs-t { display:inline-flex; align-items:center; font-family:var(--font-mono); font-size:.63rem; width:fit-content; padding:.18rem .58rem; border-radius:4px; }
.K-vs-x { background:rgba(192,64,64,.06); border:1px solid rgba(192,64,64,.14); color:var(--text-muted); }
.K-vs-x::before { content:'✗ '; color:var(--status-paused); }
.K-vs-c { background:rgba(56,160,96,.06); border:1px solid rgba(56,160,96,.14); color:var(--text-secondary); }
.K-vs-c::before { content:'✓ '; color:var(--status-active); }

/* Affiliation cards */
.K-AFC { background:var(--bg-surface); border:1px solid var(--border-default); border-radius:6px; padding:1.65rem; transition:border-color .22s; }
.K-AFC:hover { border-color:var(--border-strong); }
.K-AFL { font-family:var(--font-display); font-size:1.35rem; font-weight:900; font-style:italic; color:var(--border-strong); letter-spacing:.04em; margin-bottom:.55rem; }
.K-AFN { font-size:.83rem; font-weight:600; color:var(--text-heading); margin-bottom:.38rem; }
.K-AFD { font-size:.78rem; color:var(--text-secondary); line-height:1.65; font-weight:300; }

/* CTA band */
.K-CTA { padding:4.5rem 3rem; background:var(--bg-base); border-top:1px solid var(--border-default); display:flex; align-items:center; justify-content:space-between; gap:3rem; position:relative; overflow:hidden; }
.K-CTA::before { content:''; position:absolute; top:0; left:0; right:0; height:2px; background:linear-gradient(90deg,transparent,var(--text-accent) 40%,transparent); }
.K-cta-h { font-family:var(--font-display); font-size:2.1rem; font-weight:600; font-style:italic; letter-spacing:-.025em; color:var(--text-heading); line-height:1.05; margin-bottom:.45rem; }
.K-cta-p { font-size:.86rem; color:var(--text-secondary); font-weight:300; }
.K-CTA-a { display:flex; gap:.8rem; flex-shrink:0; }

/* ── Section watermarks — shared (hero, products, how-it-works, footer) ── */
.K-S--wm     { position: relative; overflow: hidden; }
.K-S--products { position: relative; overflow: hidden; }

/* Watermark container — anchored bottom-left, behind all content */
.K-wm {
  position: absolute;
  bottom: -0.15em;
  left: -0.05em;
  transform: none;
  pointer-events: none;
  z-index: 0;
  user-select: none;
  white-space: nowrap;
}

/* Friskr™ text watermark */
.K-wm-text {
  font-family: var(--font-display);
  font-size: 18rem;
  font-weight: 800;
  font-style: italic;
  letter-spacing: -0.04em;
  color: var(--text-accent);
  opacity: 0.032;
  display: block;
  line-height: 1;
}

/* Site-map footer variant — slightly smaller, nudged tighter to edge */
.K-wm--sitemap {
  bottom: -0.1em;
  left: -0.04em;
}
.K-wm--sitemap .K-wm-text {
  font-size: 14rem;
  opacity: 0.045;
}

/* Products section watermark container — bottom-left aligned */
.K-products-wm {
  position: absolute;
  bottom: -0.15em;
  left: -0.05em;
  transform: none;
  pointer-events: none;
  z-index: 0;
  user-select: none;
  white-space: nowrap;
}

/* All direct children of these sections sit above watermark */
.K-S--products > .K-Si { position: relative; z-index: 1; }
.K-S--wm > .K-Si        { position: relative; z-index: 1; }
.K-S--wm > .K-h-inner   { position: relative; z-index: 1; }
.site-map--wm > .site-map-inner { position: relative; z-index: 1; }

/* ── Quick Setup wizard process steps ── */
.K-wiz-steps{display:grid;grid-template-columns:repeat(5,1fr);gap:0;margin-top:2.5rem;position:relative;}
.K-wiz-step{padding:0 1.25rem 0 0;position:relative;}
.K-wiz-step-head{display:flex;align-items:center;margin-bottom:1.1rem;}
.K-wiz-n{font-family:var(--font-display);font-size:2.4rem;font-weight:900;font-style:italic;color:var(--text-accent);opacity:.55;line-height:1;letter-spacing:-.04em;flex-shrink:0;}
.K-wiz-conn{flex:1;height:1px;background:linear-gradient(to right,var(--border-strong),var(--border-default));margin-left:.6rem;}
.K-wiz-icon{width:38px;height:38px;border-radius:var(--radius-md);display:grid;place-items:center;margin-bottom:1rem;border:1px solid var(--border-default);background:var(--bg-elevated);transition:border-color .2s,color .2s;}
.K-wiz-step:hover .K-wiz-icon{border-color:var(--border-accent);color:var(--text-accent);}
.K-wiz-icon--setup {color:#60B4F8;border-color:rgba(96,180,248,0.25);background:rgba(96,180,248,0.06);}
.K-wiz-icon--config{color:#A78BFA;border-color:rgba(167,139,250,0.25);background:rgba(167,139,250,0.06);}
.K-wiz-icon--screen{color:#4DD9A0;border-color:rgba(77,217,160,0.25);background:rgba(77,217,160,0.06);}
.K-wiz-icon--vendor{color:#F9A84A;border-color:rgba(249,168,74,0.25);background:rgba(249,168,74,0.06);}
.K-wiz-icon--launch{color:var(--text-accent);border-color:var(--border-accent);background:var(--accent-alpha-08);}
.K-wiz-pill{display:inline-flex;align-items:center;font-size:.6rem;font-weight:700;letter-spacing:.12em;text-transform:uppercase;color:var(--text-accent);padding:.18rem .6rem;border:1px solid var(--border-accent);border-radius:100px;background:var(--accent-alpha-07);margin-bottom:.65rem;}
.K-wiz-step h4{font-size:.88rem;font-weight:700;color:var(--text-heading);margin-bottom:.45rem;line-height:1.25;}
.K-wiz-step p{font-size:.78rem;color:var(--text-secondary);line-height:1.65;font-weight:300;margin-bottom:.75rem;}
.K-wiz-tags{display:flex;flex-wrap:wrap;gap:.3rem;}
.K-wiz-tags span{font-size:.62rem;font-weight:600;letter-spacing:.07em;text-transform:uppercase;padding:.18rem .5rem;border:1px solid var(--border-default);border-radius:100px;color:var(--text-muted);background:var(--bg-overlay);}
@media(max-width:1100px){
  .K-wiz-steps{grid-template-columns:repeat(3,1fr);gap:1.5rem;}
  .K-wiz-conn{display:none;}
}
@media(max-width:768px){
  .K-wiz-steps{grid-template-columns:1fr;gap:1.25rem;}
}

@media(max-width:1100px) {
  .K-h-inner, .K-G4 { grid-template-columns:1fr; }
  .K-G3 { grid-template-columns:repeat(2,1fr); }
}
@media(max-width:768px) {
  .K-G2, .K-G3 { grid-template-columns:1fr; }
  .K-nl-wrap { display:none; }
  .K-CTA { flex-direction:column; align-items:flex-start; }
  .K-h-inner { grid-template-columns:1fr; }
  .K-S { padding:4rem 1.25rem; }
  .K-hero { padding:3rem 1.25rem 2.5rem; min-height:auto; }
  .K-nav { padding:0 1.25rem; }
}

/* ── Arrows canvas ── */
.K-arrow-canvas {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
  z-index: 1;
}

.K-h-pill  { animation:K-fadeUp .5s ease both; }
.K-h1      { animation:K-fadeUp .5s .08s ease both; }
.K-h-sub   { animation:K-fadeUp .5s .16s ease both; }
.K-h-btns  { animation:K-fadeUp .5s .22s ease both; }
.K-h-trust { animation:K-fadeUp .5s .28s ease both; }
.K-terminal{ animation:K-fadeUp .5s .1s ease both; }


/* ── Wrapper ── */
.hw {
  min-height: 100vh;
  background: var(--bg-void);
  display: flex;
  flex-direction: column;
}

/* ── Nav ── */
.hn {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 2.5rem;
  height: 60px;
  background: var(--bg-base);
  border-bottom: 1px solid var(--border-default);
  position: sticky;
  top: 0;
  z-index: 100;
  gap: 2rem;
}

.hn-brand {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-shrink: 0;
}

.hn-brand-text { display: flex; flex-direction: column; gap: 1px; }

.hn-brand-name {
  font-family: var(--font-display);
  font-size: 1.15rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  color: var(--text-heading);
  line-height: 1;
}
.hn-brand-name sup { font-size: 0.5em; vertical-align: super; font-weight: 700; letter-spacing: 0; }

.hn-brand-tag {
  font-size: 0.6rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--text-muted);
}

.hn-links {
  display: flex;
  align-items: center;
  gap: 0.25rem;
  flex: 1;
  justify-content: center;
}

.hn-link {
  font-size: 0.85rem;
  font-weight: 500;
  color: var(--text-secondary);
  text-decoration: none;
  padding: 0.4rem 0.8rem;
  border-radius: var(--radius-md);
  transition: color 0.15s, background 0.15s;
}
.hn-link:hover {
  color: var(--text-primary);
  background: var(--bg-hover);
}

.hn-actions {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  flex-shrink: 0;
}

.hn-signin {
  font-size: 0.85rem;
  font-weight: 500;
  color: var(--text-secondary);
  text-decoration: none;
  padding: 0.4rem 0.85rem;
  border-radius: var(--radius-md);
  border: 1px solid var(--border-default);
  transition: all 0.15s;
}
.hn-signin:hover {
  color: var(--text-primary);
  border-color: var(--border-strong);
  background: var(--bg-hover);
}

.hn-cta {
  font-family: var(--font-display);
  font-size: 0.82rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--bg-void);
  background: var(--text-accent);
  text-decoration: none;
  padding: 0.45rem 1.1rem;
  border-radius: var(--radius-md);
  transition: opacity 0.15s, transform 0.12s;
}
.hn-cta:hover { opacity: 0.88; transform: translateY(-1px); }
[data-theme="light"] .hn-cta { color: #fff; background: var(--text-heading); }

/* ── Hero ── */
.hh {
  position: relative;
  min-height: calc(100vh - 60px);
  display: flex;
  align-items: center;
  padding: 5rem 2.5rem 4rem;
  overflow: hidden;
}

/* Dot grid */
.hh-grid {
  position: absolute;
  inset: 0;
  background-image: radial-gradient(circle, var(--border-subtle) 1px, transparent 1px);
  background-size: 32px 32px;
  pointer-events: none;
}

/* Radial orbs */
.hh-orb {
  position: absolute;
  border-radius: 50%;
  pointer-events: none;
  filter: blur(80px);
}
.hh-orb--1 {
  width: 600px; height: 600px;
  top: -200px; left: -100px;
  background: radial-gradient(circle, rgba(99,102,241,0.42) 0%, transparent 70%);
}
.hh-orb--2 {
  width: 500px; height: 500px;
  bottom: -150px; right: -50px;
  background: radial-gradient(circle, var(--accent-alpha-32) 0%, transparent 70%);
}
.hh-orb--3 {
  width: 350px; height: 350px;
  top: 50%; right: 30%;
  background: radial-gradient(circle, rgba(239,68,68,0.25) 0%, transparent 70%);
}

.hh-inner {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: 1fr 420px;
  gap: 5rem;
  align-items: center;
  max-width: 1280px;
  margin: 0 auto;
  width: 100%;
}

.hh-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--text-accent);
  background: var(--accent-alpha-06);
  border: 1px solid var(--accent-alpha-18);
  padding: 0.35rem 0.9rem;
  border-radius: 100px;
  margin-bottom: 1.75rem;
}
[data-theme="light"] .hh-badge {
  color: var(--text-heading);
  background: rgba(90,98,112,0.06);
  border-color: rgba(90,98,112,0.18);
}

.hh-badge-dot {
  width: 6px; height: 6px;
  background: var(--text-accent);
  border-radius: 50%;
  animation: hh-pulse 2s ease-in-out infinite;
}
[data-theme="light"] .hh-badge-dot { background: var(--text-heading); }

@keyframes hh-pulse {
  0%, 100% { opacity: 1; transform: scale(1); }
  50%       { opacity: 0.5; transform: scale(0.75); }
}

.hh-title {
  font-family: var(--font-display);
  font-size: 4rem;
  font-weight: 800;
  line-height: 1.0;
  letter-spacing: -0.02em;
  color: var(--text-heading);
  margin-bottom: 1.5rem;
}

.hh-title-accent {
  color: var(--text-accent);
}
[data-theme="light"] .hh-title-accent {
  background: linear-gradient(135deg, #2C3440 0%, #5A6270 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.hh-sub {
  font-weight: 300;
  font-size: 1.05rem;
  color: var(--text-secondary);
  line-height: 1.7;
  max-width: 520px;
  margin-bottom: 2.5rem;
}

.hh-actions {
  display: flex;
  align-items: center;
  gap: 1rem;
  margin-bottom: 2rem;
  flex-wrap: wrap;
}

.hh-btn-primary {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.75rem 1.75rem;
  background: var(--text-accent);
  color: var(--bg-void);
  font-family: var(--font-display);
  font-size: 0.88rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  text-decoration: none;
  border-radius: var(--radius-md);
  transition: opacity 0.18s, transform 0.12s;
  border: none;
  cursor: pointer;
}
.hh-btn-primary:hover { opacity: 0.88; transform: translateY(-2px); }
[data-theme="light"] .hh-btn-primary { background: var(--text-heading); color: #fff; }

.hh-btn-ghost {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.75rem 1.5rem;
  background: transparent;
  color: var(--text-secondary);
  font-size: 0.9rem;
  font-weight: 500;
  text-decoration: none;
  border-radius: var(--radius-md);
  border: 1px solid var(--border-default);
  transition: all 0.18s;
}
.hh-btn-ghost:hover {
  color: var(--text-primary);
  border-color: var(--border-strong);
  background: var(--bg-hover);
}

.hh-trust {
  display: flex;
  align-items: center;
  gap: 0.65rem;
  flex-wrap: wrap;
}
.hh-trust span {
  display: inline-flex;
  align-items: center;
  gap: 0.3rem;
  font-size: 0.75rem;
  color: var(--text-muted);
}
.hh-trust-sep {
  width: 3px; height: 3px;
  background: var(--border-strong);
  border-radius: 50%;
  flex-shrink: 0;
}

/* Hero stats panel */
/* ── Terminal panel (hero right) ── */
.terminal {
  background: var(--bg-void);
  border: 1px solid var(--border-default);
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: var(--shadow-lg);
  font-family: var(--font-mono);
}

.term-bar {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 0.65rem 1rem;
  background: var(--bg-base);
  border-bottom: 1px solid var(--border-subtle);
}
.term-dots { display: flex; gap: 6px; }
.term-dot { width: 10px; height: 10px; border-radius: 50%; }
.term-title {
  font-family: var(--font-mono);
  font-size: 0.68rem;
  letter-spacing: 0.06em;
  color: var(--text-muted);
  margin-left: auto;
}

.term-body {
  padding: 1.1rem 1.25rem 1.25rem;
  display: flex;
  flex-direction: column;
  gap: 0.18rem;
  background: var(--bg-void);
}

/* Command line */
.term-cmd {
  display: flex;
  align-items: baseline;
  gap: 0.5rem;
  margin-bottom: 0.35rem;
}
.term-prompt {
  color: var(--text-accent);
  font-size: 0.82rem;
  flex-shrink: 0;
}
.term-cmd-text {
  font-size: 0.82rem;
  color: var(--text-primary);
  font-weight: 700;
}
.term-flag { color: var(--text-accent); }

/* Comment lines */
.term-comment {
  font-size: 0.73rem;
  color: var(--text-muted);
  margin-top: 0.35rem;
  margin-bottom: 0.1rem;
}

/* Check lines */
.term-check {
  font-size: 0.75rem;
  color: var(--text-secondary);
}
.term-tick {
  color: var(--status-active);
  margin-right: 0.25rem;
}

/* Entry stream lines */
.term-entry {
  font-size: 0.75rem;
  color: var(--text-secondary);
}
.term-clean  { color: var(--status-active); font-weight: 700; }
.term-blocked { color: var(--status-paused); font-weight: 700; }

/* Summary line */
.term-summary {
  font-size: 0.78rem;
  font-weight: 700;
  color: var(--text-accent);
  margin-top: 0.5rem;
  margin-bottom: 0.75rem;
}

/* 2×2 stat cards */
.term-cards {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.5rem;
  margin-top: 0.25rem;
}
.term-card {
  background: var(--bg-surface);
  border: 1px solid var(--border-default);
  border-radius: 6px;
  padding: 0.85rem 1rem;
}
.term-card-val {
  font-family: var(--font-mono);
  font-size: 1.35rem;
  font-weight: 700;
  color: var(--text-accent);
  line-height: 1;
  margin-bottom: 0.3rem;
  letter-spacing: -0.01em;
}
.term-card-label {
  font-size: 0.6rem;
  font-weight: 600;
  letter-spacing: 0.1em;
  color: var(--text-muted);
  margin-bottom: 0.4rem;
}
.term-card-delta {
  font-size: 0.65rem;
  color: var(--status-active);
  font-style: italic;
}

/* ── Generic section layout ── */
.hs {
  padding: 6rem 2.5rem;
  background: var(--bg-void);
}
.hs--alt {
  background: var(--bg-base);
}
.hs-inner {
  max-width: 1280px;
  margin: 0 auto;
}
.hs-eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  font-family: var(--font-display);
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--text-accent);
  margin-bottom: 1rem;
  padding: 0.25rem 0.75rem;
  border: 1px solid var(--accent-alpha-20);
  border-radius: 100px;
  background: var(--accent-alpha-04);
}
[data-theme="light"] .hs-eyebrow {
  color: var(--text-secondary);
  border-color: var(--border-default);
  background: var(--bg-elevated);
}
.hs-title {
  font-family: var(--font-display);
  font-size: 2.6rem;
  font-weight: 800;
  letter-spacing: -0.01em;
  color: var(--text-heading);
  line-height: 1.1;
  margin-bottom: 1rem;
  max-width: 640px;
}
.hs-sub {
  font-weight: 300;
  font-size: 1rem;
  color: var(--text-secondary);
  line-height: 1.7;
  max-width: 560px;
  margin-bottom: 0;
}

/* ── Products grid ── */
.hp-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.25rem;
  margin-top: 3.5rem;
}

.hp-card {
  background: var(--bg-surface);
  border: 1px solid var(--border-default);
  border-radius: var(--radius-lg);
  padding: 2rem;
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  position: relative;
  overflow: hidden;
  transition: border-color 0.25s ease,
              box-shadow 0.25s ease,
              transform 0.25s ease,
              background 0.25s ease;
}

/* Animated accent line that slides in on hover */
.hp-card::before {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 2px;
  background: linear-gradient(90deg, var(--c, var(--text-accent)), transparent);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 0.3s ease;
}

.hp-card:hover {
  background: var(--bg-elevated);
  border-color: var(--border-strong);
  box-shadow: 0 8px 32px rgba(0,0,0,0.35);
  transform: translateY(-4px);
}
.hp-card:hover::before { transform: scaleX(1); }
.hp-card:hover .hp-icon { opacity: 1; transform: scale(1.08); }

.hp-card-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  margin-bottom: 0.75rem;
}

.hp-icon {
  width: 44px;
  height: 44px;
  border-radius: var(--radius-md);
  display: grid;
  place-items: center;
  background: color-mix(in srgb, var(--c) 12%, transparent);
  color: var(--c);
  opacity: 0.85;
  flex-shrink: 0;
  transition: opacity 0.25s ease, transform 0.25s ease;
}

.hp-tag {
  font-size: 0.66rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--c, var(--text-muted));
  padding: 0.2rem 0.55rem;
  border: 1px solid color-mix(in srgb, var(--c, var(--border-default)) 30%, transparent);
  border-radius: 100px;
}

.hp-name {
  font-family: var(--font-display);
  font-size: 1.15rem;
  font-weight: 700;
  letter-spacing: 0.03em;
  color: var(--text-heading);
}

.hp-desc-label {
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--text-accent);
  margin-bottom: 0.35rem;
}
[data-theme="light"] .hp-desc-label { color: var(--text-secondary); }

.hp-desc {
  font-weight: 300;
  font-size: 0.86rem;
  color: var(--text-secondary);
  line-height: 1.65;
}

/* ── Friskr™ Advantage ── */
.fadv-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 1.25rem;
  margin-top: 3.5rem;
}

/* Wide cards span full width — first two cards */
.fadv-card--wide {
  grid-column: span 1;
}

.fadv-card {
  background: var(--bg-surface);
  border: 1px solid var(--border-default);
  border-radius: var(--radius-lg);
  padding: 2rem;
  display: flex;
  gap: 1.25rem;
  position: relative;
  overflow: hidden;
  transition: border-color 0.25s ease, box-shadow 0.25s ease, transform 0.25s ease;
}

.fadv-card::before {
  content: '';
  position: absolute;
  top: 0; left: 0; bottom: 0;
  width: 3px;
  background: var(--text-accent);
  transform: scaleY(0);
  transform-origin: top;
  transition: transform 0.3s ease;
}

.fadv-card:hover {
  border-color: var(--border-strong);
  box-shadow: var(--shadow-md);
  transform: translateY(-2px);
}
.fadv-card:hover::before { transform: scaleY(1); }

.fadv-card-num {
  font-family: var(--font-display);
  font-size: 3rem;
  font-weight: 800;
  line-height: 1;
  color: var(--border-default);
  flex-shrink: 0;
  width: 52px;
  transition: color 0.25s ease;
}
.fadv-card:hover .fadv-card-num { color: var(--border-accent); }

.fadv-card-body {
  display: flex;
  flex-direction: column;
  gap: 0.65rem;
  min-width: 0;
}

.fadv-icon {
  width: 42px;
  height: 42px;
  border-radius: var(--radius-md);
  background: var(--accent-alpha-08);
  color: var(--text-accent);
  display: grid;
  place-items: center;
  flex-shrink: 0;
  transition: background 0.25s ease, transform 0.25s ease;
}
[data-theme="light"] .fadv-icon {
  background: rgba(90,98,112,0.08);
  color: var(--text-secondary);
}
.fadv-card:hover .fadv-icon {
  background: var(--accent-alpha-14);
  transform: scale(1.08);
}

.fadv-card-body h4 {
  font-family: var(--font-display);
  font-size: 1.05rem;
  font-weight: 700;
  color: var(--text-heading);
}

.fadv-card-body p {
  font-size: 0.86rem;
  color: var(--text-secondary);
  line-height: 1.7;
}

/* Competitor vs Friskr comparison pill row */
.fadv-vs {
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
  margin-top: 0.25rem;
  padding-top: 0.85rem;
  border-top: 1px solid var(--border-subtle);
}

.fadv-vs-them,
.fadv-vs-us {
  font-family: var(--font-mono);
  font-size: 0.68rem;
  font-weight: 500;
  letter-spacing: 0.04em;
  padding: 0.25rem 0.65rem;
  border-radius: var(--radius-sm);
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  width: fit-content;
}

.fadv-vs-them {
  background: rgba(239,68,68,0.06);
  color: var(--text-muted);
  border: 1px solid rgba(239,68,68,0.1);
}
.fadv-vs-them::before {
  content: '✗';
  color: #EF4444;
  font-size: 0.7rem;
}

.fadv-vs-us {
  background: rgba(34,197,94,0.06);
  color: var(--text-secondary);
  border: 1px solid rgba(34,197,94,0.12);
}
.fadv-vs-us::before {
  content: '✓';
  color: #22C55E;
  font-size: 0.7rem;
}

/* ── Features grid ── */
.hf-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.25rem;
  margin-top: 3.5rem;
}

.hf-card {
  padding: 2rem;
  background: var(--bg-surface);
  border: 1px solid var(--border-default);
  border-radius: var(--radius-lg);
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  transition: border-color 0.18s, transform 0.18s, box-shadow 0.18s;
}
.hf-card:hover {
  border-color: var(--border-accent);
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
}

.hf-icon {
  width: 46px; height: 46px;
  border-radius: var(--radius-md);
  display: grid;
  place-items: center;
}

.hf-card h4 {
  font-family: var(--font-display);
  font-size: 1rem;
  font-weight: 700;
  color: var(--text-heading);
  margin-top: 0.25rem;
}

.hf-card p {
  font-size: 0.86rem;
  color: var(--text-secondary);
  line-height: 1.65;
}

/* ── Use cases ── */
.huc-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 1.5rem;
  margin-top: 3.5rem;
}

.huc-card {
  display: flex;
  gap: 1.5rem;
  padding: 2rem;
  background: var(--bg-surface);
  border: 1px solid var(--border-default);
  border-radius: var(--radius-lg);
  transition: border-color 0.18s, box-shadow 0.18s;
}
.huc-card:hover {
  border-color: var(--border-accent);
  box-shadow: var(--shadow-sm);
}

.huc-num {
  font-family: var(--font-display);
  font-size: 2.2rem;
  font-weight: 800;
  color: var(--border-strong);
  line-height: 1;
  flex-shrink: 0;
  width: 52px;
}

.huc-card h4 {
  font-family: var(--font-display);
  font-size: 1.05rem;
  font-weight: 700;
  color: var(--text-heading);
  margin-bottom: 0.6rem;
}

.huc-card p {
  font-size: 0.86rem;
  color: var(--text-secondary);
  line-height: 1.65;
  margin-bottom: 1rem;
}

.huc-list {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 0.3rem;
}
.huc-list li {
  font-size: 0.8rem;
  color: var(--text-secondary);
  padding-left: 1rem;
  position: relative;
}
.huc-list li::before {
  content: '→';
  position: absolute;
  left: 0;
  color: var(--text-accent);
  font-size: 0.72rem;
}

.huc-cta {
  margin-top: 4rem;
  padding: 3rem;
  background: var(--bg-surface);
  border: 1px solid var(--border-default);
  border-radius: var(--radius-xl);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 2rem;
  position: relative;
  overflow: hidden;
}
.huc-cta::before {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 2px;
  background: linear-gradient(90deg, var(--text-accent), #6366F1);
}
.huc-cta-copy h3 {
  font-family: var(--font-display);
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--text-heading);
  margin-bottom: 0.4rem;
}
.huc-cta-copy p {
  font-size: 0.88rem;
  color: var(--text-secondary);
}
.huc-cta-actions {
  display: flex;
  align-items: center;
  gap: 0.85rem;
  flex-shrink: 0;
}

/* ── How it works ── */
.hsteps {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 0;
  margin-top: 3.5rem;
  position: relative;
}

.hstep {
  padding: 0 2rem 0 0;
  position: relative;
}
.hstep:last-child { padding-right: 0; }

.hstep-num {
  font-family: var(--font-display);
  font-size: 3rem;
  font-weight: 800;
  color: var(--border-default);
  line-height: 1;
  margin-bottom: 1rem;
  position: relative;
  z-index: 1;
}

.hstep-line {
  position: absolute;
  top: 1.5rem;
  left: 3.5rem;
  right: 0;
  height: 1px;
  background: var(--border-default);
}
.hstep:last-child .hstep-line { display: none; }

.hstep h4 {
  font-family: var(--font-display);
  font-size: 1rem;
  font-weight: 700;
  color: var(--text-heading);
  margin-bottom: 0.5rem;
  margin-top: 0.75rem;
}
.hstep p {
  font-size: 0.85rem;
  color: var(--text-secondary);
  line-height: 1.65;
}

/* ── Awards ── */
.hawards {
  display: flex;
  gap: 1.5rem;
  justify-content: center;
  flex-wrap: wrap;
  margin-top: 3rem;
}
.haward-card {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  gap: 0.65rem;
  padding: 2rem 2.5rem;
  background: var(--bg-surface);
  border: 1px solid var(--border-default);
  border-radius: var(--radius-lg);
  min-width: 200px;
}
.haward-name {
  font-family: var(--font-display);
  font-size: 0.95rem;
  font-weight: 700;
  color: var(--text-heading);
}
.haward-org {
  font-size: 0.78rem;
  color: var(--text-muted);
}

/* ── Affiliations ── */
.haff-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1px;
  margin-top: 3.5rem;
  border: 1px solid var(--border-default);
  border-radius: var(--radius-xl);
  overflow: hidden;
  background: var(--border-default);
}
.haff-card {
  background: var(--bg-surface);
  padding: 2rem;
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  transition: background 0.18s;
}
.haff-card:hover { background: var(--bg-elevated); }
.haff-logo {
  font-family: var(--font-display);
  font-size: 1.6rem;
  font-weight: 800;
  letter-spacing: 0.06em;
  color: var(--text-accent);
  opacity: 0.65;
  margin-bottom: 0.25rem;
}
[data-theme="light"] .haff-logo { opacity: 0.45; }
.haff-name {
  font-family: var(--font-display);
  font-size: 0.92rem;
  font-weight: 700;
  color: var(--text-heading);
}
.haff-card p {
  font-size: 0.83rem;
  color: var(--text-secondary);
  line-height: 1.65;
}

/* ── Newsletter ── */
.hnl {
  background: var(--bg-base);
  border-top: 1px solid var(--border-subtle);
  border-bottom: 1px solid var(--border-subtle);
  padding: 2.25rem 3rem;
}
.hnl-inner {
  max-width: 1400px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 2rem;
}
.hnl-copy {
  display: flex;
  align-items: center;
  gap: 1rem;
}
.hnl-title {
  font-family: var(--font-display);
  font-size: 0.95rem;
  font-weight: 600;
  color: var(--text-heading);
  margin-bottom: 0.15rem;
}
.hnl-sub {
  font-size: 0.8rem;
  color: var(--text-muted);
  font-weight: 300;
}
.hnl-form {
  display: flex;
  gap: 0.5rem;
  flex-shrink: 0;
}
.hnl-input {
  padding: 0.55rem 1rem;
  background: var(--bg-surface);
  border: 1px solid var(--border-default);
  border-radius: 6px;
  font-family: var(--font-body);
  font-size: 0.85rem;
  color: var(--text-primary);
  width: 220px;
  outline: none;
  transition: border-color 0.15s;
}
.hnl-input:focus { border-color: var(--border-accent); }
.hnl-input::placeholder { color: var(--text-muted); }
.hnl-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  padding: 0.55rem 1.1rem;
  background: var(--text-accent);
  color: var(--bg-void);
  font-family: var(--font-display);
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  border: none;
  border-radius: 6px;
  cursor: pointer;
  transition: opacity 0.15s;
}
.hnl-btn:hover { opacity: 0.88; }
[data-theme="light"] .hnl-btn { background: var(--text-heading); color: #fff; }

/* ── Responsive ── */
@media (max-width: 1100px) {
  .hh-inner { grid-template-columns: 1fr; }
  .terminal { max-width: 480px; }
  .hh-title { font-size: 3rem; }
  .hp-grid { grid-template-columns: repeat(2, 1fr); }
  .hf-grid { grid-template-columns: repeat(2, 1fr); }
  .haff-grid { grid-template-columns: repeat(2, 1fr); }
  .fadv-grid { grid-template-columns: 1fr; }
  .hsteps { grid-template-columns: repeat(2, 1fr); gap: 2rem; }
  .hstep-line { display: none; }
}

@media (max-width: 768px) {
  .hn { padding: 0 1.25rem; }
  .hn-links { display: none; }
  .hh { padding: 3rem 1.25rem 2.5rem; min-height: auto; }
  .hh-title { font-size: 2.4rem; }
  .hs { padding: 4rem 1.25rem; }
  .hp-grid, .hf-grid, .huc-grid, .haff-grid { grid-template-columns: 1fr; }
  .fadv-grid { grid-template-columns: 1fr; }
  .fadv-card { flex-direction: column; gap: 0.75rem; }
  .fadv-card-num { width: auto; font-size: 2rem; }
  .hsteps { grid-template-columns: 1fr; }
  .huc-cta { flex-direction: column; align-items: flex-start; }
  .hnl-inner { flex-direction: column; align-items: flex-start; gap: 1rem; }
  .hnl-form { width: 100%; }
  .hnl-input { flex: 1; width: auto; }
  .terminal { display: none; }
}

/* ─── home-auth-footer — see footer block below ─── */


/* ================================================================
   HOME PAGE — PRODUCTS SECTION
   ================================================================ */
.home-products-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.25rem;
  margin-top: 3rem;
}

.home-product-card {
  display: flex;
  flex-direction: column;
  gap: 1rem;
  padding: 1.75rem;
  background: var(--bg-elevated);
  border: 1px solid var(--border-default);
  border-radius: var(--radius-lg);
  transition: border-color 0.18s, box-shadow 0.18s, transform 0.18s;
}

.home-product-card:hover {
  border-color: var(--border-accent);
  box-shadow: var(--shadow-md);
  transform: translateY(-2px);
}

.home-product-icon {
  width: 48px;
  height: 48px;
  border-radius: var(--radius-md);
  display: grid;
  place-items: center;
  flex-shrink: 0;
}

.home-product-name {
  font-family: var(--font-display);
  font-size: 1.1rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  color: var(--text-heading);
  margin-bottom: 0.15rem;
}

.home-product-desc {
  font-size: 0.78rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--text-accent);
  margin-bottom: 0.5rem;
}

.home-product-body p {
  font-size: 0.88rem;
  color: var(--text-secondary);
  line-height: 1.65;
}

/* ================================================================
   HOME PAGE — USE CASES SECTION
   ================================================================ */
.home-usecases-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 1.5rem;
  margin-top: 3rem;
}

.home-usecase-card {
  display: flex;
  gap: 1.5rem;
  padding: 2rem;
  background: var(--bg-elevated);
  border: 1px solid var(--border-default);
  border-radius: var(--radius-lg);
  transition: border-color 0.18s, box-shadow 0.18s;
}

.home-usecase-card:hover {
  border-color: var(--border-accent);
  box-shadow: var(--shadow-sm);
}

.home-usecase-num {
  font-family: var(--font-display);
  font-size: 2rem;
  font-weight: 800;
  color: var(--border-strong);
  line-height: 1;
  flex-shrink: 0;
  width: 48px;
}

.home-usecase-body h4 {
  font-size: 1.05rem;
  font-weight: 700;
  color: var(--text-heading);
  margin-bottom: 0.6rem;
}

.home-usecase-body p {
  font-size: 0.88rem;
  color: var(--text-secondary);
  line-height: 1.65;
  margin-bottom: 1rem;
}

.home-usecase-list {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
}

.home-usecase-list li {
  font-size: 0.82rem;
  color: var(--text-secondary);
  padding-left: 1rem;
  position: relative;
}

.home-usecase-list li::before {
  content: '→';
  position: absolute;
  left: 0;
  color: var(--text-accent);
  font-size: 0.75rem;
}

.home-usecase-cta {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 1rem;
  margin-top: 3.5rem;
  padding-top: 3rem;
  border-top: 1px solid var(--border-default);
  flex-wrap: wrap;
}

.home-usecase-cta p {
  font-family: var(--font-display);
  font-size: 1.1rem;
  font-weight: 600;
  color: var(--text-heading);
  margin-right: 0.5rem;
}

/* ================================================================
   HOME PAGE — AWARDS SECTION (hidden by default)
   ================================================================ */
.home-awards-grid {
  display: flex;
  gap: 1.5rem;
  justify-content: center;
  flex-wrap: wrap;
  margin-top: 3rem;
}

.home-award-card {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  gap: 0.75rem;
  padding: 2rem 2.5rem;
  background: var(--bg-elevated);
  border: 1px solid var(--border-default);
  border-radius: var(--radius-lg);
  min-width: 200px;
}

.home-award-icon {
  width: 56px;
  height: 56px;
  background: rgba(245,158,11,0.08);
  border-radius: 50%;
  display: grid;
  place-items: center;
}

.home-award-name {
  font-family: var(--font-display);
  font-size: 0.95rem;
  font-weight: 700;
  color: var(--text-heading);
  line-height: 1.3;
}

.home-award-org {
  font-size: 0.78rem;
  color: var(--text-muted);
}

/* ================================================================
   HOME PAGE — INDUSTRY AFFILIATIONS SECTION
   ================================================================ */
.home-affiliations-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.25rem;
  margin-top: 3rem;
}

.home-affiliation-card {
  display: flex;
  flex-direction: column;
  gap: 1rem;
  padding: 1.75rem;
  background: var(--bg-elevated);
  border: 1px solid var(--border-default);
  border-radius: var(--radius-lg);
  transition: border-color 0.18s;
}

.home-affiliation-card:hover {
  border-color: var(--border-accent);
}

.home-affiliation-logo {
  font-family: var(--font-display);
  font-size: 1.5rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  color: var(--text-accent);
  opacity: 0.7;
}

.home-affiliation-name {
  font-family: var(--font-display);
  font-size: 0.95rem;
  font-weight: 700;
  color: var(--text-heading);
  margin-bottom: 0.4rem;
}

.home-affiliation-body p {
  font-size: 0.85rem;
  color: var(--text-secondary);
  line-height: 1.65;
}

/* ── Responsive ── */
@media (max-width: 1024px) {
  .home-products-grid { grid-template-columns: repeat(2, 1fr); }
  .home-affiliations-grid { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 768px) {
  .home-products-grid { grid-template-columns: 1fr; }
  .home-usecases-grid { grid-template-columns: 1fr; }
  .home-affiliations-grid { grid-template-columns: 1fr; }
  .home-usecase-card { flex-direction: column; gap: 0.75rem; }
  .home-usecase-num { width: auto; font-size: 1.5rem; }
}
/* ================================================================
   APP SHELL LAYOUT
   ================================================================ */

.app-layout {
  display: flex;
  min-height: 100vh;
}

/* ── Sidebar ── */
.sidebar {
  width: var(--sidebar-w);
  background: var(--bg-base);
  border-right: 1px solid var(--border-default);
  display: flex;
  flex-direction: column;
  position: fixed;
  left: 0;
  top: 0;
  bottom: 0;
  z-index: 100;
}

/* DEPRECATED: .sidebar-header replaced by .reg-card-brand (single source). Duplicate definition #2 */
/* .sidebar-header { */
/*   height: var(--nav-h); */
/*   display: flex; */
/*   align-items: center; */
/*   padding: 0 1.2rem; */
/*   border-bottom: 1px solid var(--border-default); */
/*   gap: 10px; */
/*   flex-shrink: 0; */
/* } */

.sidebar-logo-icon {
  width: 32px;
  height: 32px;
  background: linear-gradient(135deg, var(--text-accent) 0%, var(--text-accent) 100%);
  border-radius: var(--radius-md);
  display: grid;
  place-items: center;
  flex-shrink: 0;
  box-shadow: 0 2px 8px var(--accent-alpha-30);
}

.sidebar-logo-icon svg { color: #ffffff; }

.sidebar-logo-text {
  font-family: var(--font-display);
  font-size: 1.15rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  color: var(--text-heading);
}

.sidebar-nav {
  flex: 1;
  padding: 1rem 0;
  overflow-y: auto;
}

.nav-section {
  padding: 0.5rem 1rem 0.25rem;
  font-family: var(--font-body);
  font-size: 0.65rem;
  font-weight: 600;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--text-accent);
  opacity: 0.7;
  margin-top: 0.5rem;
}

.nav-link {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 0.65rem 1.2rem;
  color: var(--text-secondary);
  text-decoration: none;
  font-family: var(--font-body);
  font-size: 0.88rem;
  font-weight: 500;
  letter-spacing: 0.02em;
  border-left: 3px solid transparent;
  transition: all 0.18s ease;
}

.nav-link:hover {
  color: var(--text-primary);
  background: var(--bg-hover);
  border-left-color: var(--border-accent);
}

.nav-link.active {
  color: var(--text-accent);
  background: var(--accent-alpha-07);
  border-left-color: var(--text-accent);
}

.nav-link svg { flex-shrink: 0; width: 16px; height: 16px; }

.sidebar-footer {
  padding: 1rem;
  border-top: 1px solid var(--border-default);
}

.user-card {
  display: flex;
  flex-direction: column;
  gap: 0;
  padding: 0 0 0.6rem;
  border-radius: var(--radius-md);
  cursor: pointer;
  transition: background 0.18s;
  overflow: hidden;
}

.user-card:hover { background: var(--bg-hover); }

.user-card-top {
  display: flex;
  flex-direction: row;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding: 0.55rem 0.6rem 0;
}

.user-avatar {
  width: 32px;
  height: 32px;
  background: linear-gradient(135deg, var(--blue-600), var(--blue-400));
  border-radius: var(--radius-sm);
  display: grid;
  place-items: center;
  font-size: 0.75rem;
  font-weight: 700;
  color: white;
  font-family: var(--font-display);
  flex-shrink: 0;
}

.user-info { min-width: 0; text-align: left; }
.user-name {
  font-size: 0.83rem;
  font-weight: 600;
  color: var(--text-primary);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  line-height: 1.3;
}
.user-id {
  font-family: var(--font-mono);
  font-size: 0.62rem;
  color: var(--text-muted);
  letter-spacing: 0.04em;
  margin-top: 0.15rem;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

/* ── Account type bar — full width at top ── */
.user-card-type {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  padding: 0.4rem 0.6rem;
  border-bottom: 1px solid var(--border-subtle);
}
.user-card-type--super     { background: rgba(245,158,11,0.1);  color: #F59E0B; }
.user-card-type--primary   { background: var(--accent-alpha-07); color: var(--text-accent); }
.user-card-type--secondary { background: rgba(34,197,94,0.07);  color: #22C55E; }
.user-card-type--tertiary  { background: rgba(168,85,247,0.07); color: #A855F7; }

.user-card-pill-row {
  display: flex;
  align-items: center;
  gap: 0.35rem;
  flex-wrap: wrap;
}
.user-card-pill {
  display: inline-flex;
  align-items: center;
  gap: 3px;
  font-size: 0.65rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  padding: 0.15rem 0.5rem;
  border-radius: 999px;
  border: 1px solid transparent;
  white-space: nowrap;
  max-width: 100%;
  overflow: hidden;
  text-overflow: ellipsis;
}
.user-card-pill--super    { background: rgba(245,158,11,0.1);  border-color: rgba(245,158,11,0.25); color: #F59E0B; }
.user-card-pill--primary  { background: var(--accent-alpha-08); border-color: var(--accent-alpha-20);  color: var(--text-accent); }
.user-card-pill--secondary{ background: rgba(34,197,94,0.08);  border-color: rgba(34,197,94,0.2);   color: #22C55E; }
.user-card-pill--tertiary { background: rgba(168,85,247,0.08); border-color: rgba(168,85,247,0.2);  color: #A855F7; }

/* ── Main Content ── */
.main-content {
  margin-left: var(--sidebar-w);
  flex: 1;
  display: flex;
  flex-direction: column;
  min-height: 100vh;
  min-width: 0;
  width: calc(100vw - var(--sidebar-w));
  max-width: calc(100vw - var(--sidebar-w));
  overflow-x: hidden;
}

.topbar {
  height: var(--nav-h);
  background: var(--bg-base);
  border-bottom: 1px solid var(--border-default);
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 1.5rem;
  position: sticky;
  top: 0;
  z-index: 90;
  overflow: visible;
}

.topbar-left {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.page-title {
  font-family: var(--font-serif);
  font-size: 1.2rem;
  font-weight: 400;
  font-style: italic;
  letter-spacing: 0;
  color: var(--text-heading);
}

/* ── Account type pill ── */
.topbar-account-pill {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  font-size: 0.62rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  padding: 0.2rem 0.55rem;
  border-radius: 999px;
  border: 1px solid transparent;
  white-space: nowrap;
  flex-shrink: 0;
}
.topbar-account-pill--super {
  background: rgba(245,158,11,0.1);
  border-color: rgba(245,158,11,0.25);
  color: #F59E0B;
}
.topbar-account-pill--primary {
  background: var(--accent-alpha-08);
  border-color: var(--accent-alpha-20);
  color: var(--text-accent);
}
.topbar-account-pill--secondary {
  background: rgba(34,197,94,0.08);
  border-color: rgba(34,197,94,0.2);
  color: #22C55E;
}
.topbar-account-pill--tertiary {
  background: rgba(168,85,247,0.08);
  border-color: rgba(168,85,247,0.2);
  color: #A855F7;
}
@media (max-width: 640px) {
  .topbar-account-pill { display: none; }
}

.topbar-right {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.topbar-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 34px;
  height: 34px;
  border-radius: var(--radius-md);
  border: 1px solid var(--border-default);
  background: transparent;
  color: var(--text-secondary);
  cursor: pointer;
  transition: all 0.18s;
}

.topbar-btn:hover {
  background: var(--bg-hover);
  color: var(--text-primary);
  border-color: var(--border-strong);
}


/* ================================================================
   PAGE NAV BAR (below topbar — dashboard sub-tabs)
   ================================================================ */
.page-nav {
  display: flex;
  border-bottom: 1px solid var(--border-default);
  margin: 0.5rem -1.5rem 1.5rem -1.5rem;
  padding: 0 1.5rem;
}

.page-nav-btn {
  padding: 0.7rem 1.2rem;
  font-family: var(--font-display);
  font-size: 0.82rem;
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--text-muted);
  background: transparent;
  border: none;
  border-bottom: 2px solid transparent;
  cursor: pointer;
  transition: all 0.18s;
  margin-bottom: -1px;
  white-space: nowrap;
}
.page-nav-btn:hover { color: var(--text-primary); }
.page-nav-btn.active { color: var(--text-accent); border-bottom-color: var(--text-accent); }

.page-nav-panel { display: none; }
.page-nav-panel.active { display: block; }

.page-body {
  flex: 1;
  padding: 1.5rem;
  background: var(--bg-void);
  min-width: 0;
  overflow-x: hidden;
  box-sizing: border-box;
  width: 100%;
}


/* ================================================================
   GRID
   ================================================================ */
.grid { display: grid; gap: 1rem; }
.grid-2 { grid-template-columns: repeat(2, 1fr); }
.grid-3 { grid-template-columns: repeat(3, 1fr); }
.grid-4, .Status_Projects, .Status_Screeners, .Status_Panel, .Status_Communities { grid-template-columns: repeat(4, 1fr); }
.col-span-2 { grid-column: span 2; }
.Status_Projects, .Status_Screeners, .Status_Panel, .Status_Communities { display: grid; gap: 1rem; }

/* ================================================================
   CARDS
   ================================================================ */
.card {
  background: var(--bg-surface);
  border: 1px solid var(--border-default);
  border-radius: var(--radius-lg);
  padding: 1.25rem;
  transition: border-color 0.18s, box-shadow 0.18s;
}

.card:hover {
  border-color: var(--border-strong);
  box-shadow: var(--shadow-sm);
}

/* Card layout variants */
.card--flush   { padding: 0; }                          /* table/image inside card */
.card--compact { padding: 0.75rem 1rem; }               /* stat cards, sidebar panels */
.card--loose   { padding: 1.75rem 2rem; }               /* modal bodies, feature cards */
.card--raised  { box-shadow: var(--shadow-md); border-color: var(--border-strong); }

.card-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1rem 1.25rem;
  border-bottom: 1px solid var(--border-subtle);
}

.card-title {
  font-family: var(--font-display);
  font-size: 0.78rem;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--text-muted);
}

/* ── Metric Cards ── */
.metric-card {
  background: var(--bg-surface);
  border: 1px solid var(--border-default);
  border-radius: var(--radius-lg);
  padding: 1.2rem;
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  position: relative;
  overflow: hidden;
  transition: all 0.2s ease;
}

.metric-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 2px;
  background: var(--metric-accent, var(--text-accent));
  opacity: 0.7;
}

.metric-card:hover {
  border-color: var(--border-accent);
  box-shadow: var(--shadow-glow);
  transform: translateY(-1px);
}

.metric-icon {
  width: 36px;
  height: 36px;
  border-radius: var(--radius-md);
  background: var(--metric-bg, var(--accent-alpha-08));
  display: grid;
  place-items: center;
  color: var(--metric-accent, var(--text-accent));
}

.metric-value {
  font-family: var(--font-body);
  font-size: 2rem;
  font-weight: 800;
  letter-spacing: -0.03em;
  color: var(--text-heading);
  line-height: 1;
}

.metric-label {
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--text-muted);
}

.metric-delta {
  font-size: 0.75rem;
  color: var(--status-active);
  display: flex;
  align-items: center;
  gap: 4px;
}

/* ================================================================
   FORMS
   ================================================================ */
.form-group {
  display: flex;
  flex-direction: column;
  gap: 6px;
  margin-bottom: 1rem;
}

.form-label {
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--text-muted);
}

.form-input,
.form-select,
.form-textarea {
  background: var(--bg-elevated);
  border: 1px solid var(--border-default);
  border-radius: var(--radius-md);
  color: var(--text-primary);
  font-family: var(--font-body);
  font-size: 0.9rem;
  padding: 0.65rem 0.9rem;
  transition: border-color 0.18s, box-shadow 0.18s;
  width: 100%;
  outline: none;
  -webkit-appearance: none;
  appearance: none;
}

.form-input:focus,
.form-select:focus,
.form-textarea:focus {
  border-color: var(--text-accent);
  box-shadow: 0 0 0 3px var(--accent-alpha-10);
}

.form-input::placeholder { color: var(--text-muted); opacity: 1; }
.form-select { cursor: pointer; }
.form-textarea { resize: vertical; min-height: 80px; }

/* Form input context variants */
.form-input--sm    { font-size: 0.8rem;  height: 32px; padding: 0.35rem 0.75rem; }
.form-input--xs    { font-size: 0.75rem; height: 28px; padding: 0.28rem 0.6rem;  }
.form-input--mono  { font-family: var(--font-mono); font-size: 0.82rem; }        /* URL, API key, ID fields */
.form-input--wide  { width: 100%; }

.form-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1rem;
}

/* ================================================================
   BUTTONS
   ================================================================ */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  padding: 0.6rem 1.2rem;
  border-radius: var(--radius-md);
  font-family: var(--font-body);
  font-size: 0.85rem;
  font-weight: 700;
  cursor: pointer;
  border: 1px solid transparent;
  transition: all 0.18s ease;
  text-decoration: none;
  white-space: nowrap;
  letter-spacing: 0.03em;
  line-height: 1;
}

.btn svg,
.btn i[data-lucide] { width: 15px; height: 15px; flex-shrink: 0; }

.btn-primary {
  background: var(--text-accent);
  color: var(--bg-void);
  border-color: var(--text-accent);
}
.btn-primary:hover {
  background: var(--text-accent);
  opacity: 0.88;
  border-color: var(--text-accent00);
  box-shadow: 0 0 16px var(--accent-alpha-30);
}

.btn-secondary {
  background: transparent;
  color: var(--text-primary);
  border-color: var(--border-strong);
}
.btn-secondary:hover { background: var(--bg-hover); }

.btn-ghost {
  background: transparent;
  color: var(--text-secondary);
  border-color: transparent;
}
.btn-ghost:hover { background: var(--bg-hover); color: var(--text-primary); }

.btn-danger {
  background: transparent;
  color: var(--status-paused);
  border-color: rgba(239,68,68,0.3);
}
.btn-danger:hover { background: rgba(239,68,68,0.1); }

.btn-sm  { padding: 0.38rem 0.75rem; font-size: 0.78rem; gap: 5px; }
.btn-xs  { padding: 0.2rem  0.5rem;  font-size: 0.72rem; gap: 0.3rem; }
.btn-lg  { padding: 0.8rem  1.8rem;  font-size: 0.95rem; }
.btn-full { width: 100%; }
.btn:disabled { opacity: 0.5; cursor: not-allowed; }

/* ================================================================
   BADGES
   ================================================================ */
.badge {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 0.22rem 0.65rem;
  border-radius: 2px;
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  font-family: var(--font-display);
  border: 1px solid transparent;
}

/* Project lifecycle statuses */
.badge-draft     { background:rgba(148,163,184,0.1); color:#94A3B8;            border-color:rgba(148,163,184,0.2); }
.badge-approved  { background:var(--accent-alpha-10);  color:var(--text-accent); border-color:var(--accent-alpha-20); }
.badge-active    { background:rgba(34,197,94,0.12);  color:var(--status-active); border-color:rgba(34,197,94,0.25); }
.badge-on_hold   { background:rgba(245,158,11,0.12); color:var(--status-pending); border-color:rgba(245,158,11,0.25); }
.badge-completed { background:rgba(34,197,94,0.08);  color:#16A34A;            border-color:rgba(34,197,94,0.15); }
.badge-closed    { background:rgba(100,116,139,0.1); color:#64748B;            border-color:rgba(100,116,139,0.2); }
.badge-cancelled { background:rgba(239,68,68,0.1);   color:var(--status-paused); border-color:rgba(239,68,68,0.2); }
.badge-invoiced  { background:rgba(168,85,247,0.1);  color:#A855F7;            border-color:rgba(168,85,247,0.2); }
.badge-archived  { background:rgba(30,41,59,0.06);   color:var(--text-muted);  border-color:var(--border-default); }
/* Legacy/compat aliases */
.badge-pending  { background: rgba(245,158,11,0.12); color: var(--status-pending);  border-color: rgba(245,158,11,0.25); }
.badge-complete { background: var(--accent-alpha-10); color: var(--status-complete); border-color: var(--accent-alpha-18); }
.badge-paused   { background: rgba(239,68,68,0.12);  color: var(--status-paused);   border-color: rgba(239,68,68,0.25); }
.badge-review   { background: rgba(168,85,247,0.12); color: var(--status-review);   border-color: rgba(168,85,247,0.25); }
.badge-verified { background: var(--accent-alpha-10); color: var(--text-accent);        border-color: var(--accent-alpha-25); }
.badge-linked   { background: rgba(192,132,252,0.08); color: #C084FC;             border-color: rgba(192,132,252,0.22); } /* linked user/account */
.badge-sm       { font-size: 0.62rem; padding: 0.15rem 0.5rem; letter-spacing: 0.08em; } /* compact badge in dense tables */

/* ================================================================
   TABLES
   ================================================================ */
.table-wrap { overflow-x: auto; border-radius: var(--radius-lg); }

table { width: 100%; border-collapse: collapse; font-size: 0.85rem; }

thead tr {
  background: var(--bg-elevated);
  border-bottom: 1px solid var(--border-default);
}

th {
  padding: 0.75rem 1rem;
  text-align: left;
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--text-muted);
  white-space: nowrap;
}

tbody tr {
  border-bottom: 1px solid var(--border-subtle);
  transition: background 0.15s;
}

tbody tr:hover { background: var(--bg-elevated); }
tbody tr:last-child { border-bottom: none; }

td {
  padding: 0.8rem 1rem;
  color: var(--text-primary);
  vertical-align: middle;
}

.td-mono  { font-family: var(--font-mono); font-size: 0.75rem; color: var(--text-secondary); }
.td-muted { color: var(--text-muted); font-size: 0.72rem; margin-top: 2px; }

/* ================================================================
   PROGRESS BARS
   ================================================================ */
.progress-wrap {
  display: flex;
  align-items: center;
  gap: 8px;
}

.progress-track {
  flex: 1;
  height: 4px;
  background: var(--bg-overlay);
  border-radius: 2px;
  overflow: hidden;
}
.progress-track--thin  { height: 3px; }
.progress-track--thick { height: 6px; }

.progress-fill {
  height: 100%;
  background: linear-gradient(90deg, var(--blue-400), var(--blue-200));
  border-radius: 2px;
  transition: width 0.6s cubic-bezier(0.4,0,0.2,1);
}

.progress-fill.green { background: linear-gradient(90deg, #16A34A, #22C55E); }
.progress-fill.amber { background: linear-gradient(90deg, #B45309, #F59E0B); }
.progress-fill.red   { background: linear-gradient(90deg, #B91C1C, #EF4444); }

.progress-pct {
  font-family: var(--font-mono);
  font-size: 0.72rem;
  color: var(--text-muted);
  width: 34px;
  text-align: right;
  flex-shrink: 0;
}

/* ================================================================
   TABS
   ================================================================ */
.tabs {
  display: flex;
  border-bottom: 1px solid var(--border-default);
  margin-bottom: 0;
}

.tab-btn {
  padding: 0.7rem 1.2rem;
  font-family: var(--font-display);
  font-size: 0.82rem;
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--text-muted);
  background: transparent;
  border: none;
  border-bottom: 2px solid transparent;
  cursor: pointer;
  transition: all 0.18s;
  margin-bottom: -1px;
}

.tab-btn:hover { color: var(--text-primary); }
.tab-btn.active { color: var(--text-accent); border-bottom-color: var(--text-accent); }

.tab-panel {
  display: none;
}
.tab-panel.active {
  display: block;
  padding-top: 1.5rem;
}
.tab-panel.active > * + * { margin-top: 1rem; }

/* ================================================================
   FLASH / TOAST
   ================================================================ */
.flash-messages {
  position: fixed;
  top: 1rem;
  right: 1rem;
  z-index: 9999;
  display: flex;
  flex-direction: column;
  gap: 8px;
  max-width: 380px;
}

.flash {
  padding: 0.85rem 1.1rem;
  border-radius: var(--radius-md);
  font-size: 0.85rem;
  display: flex;
  align-items: flex-start;
  gap: 10px;
  box-shadow: var(--shadow-md);
  animation: slideInRight 0.3s ease;
  border-left: 3px solid;
}

.flash-success { background: var(--bg-elevated); border-color: var(--status-active);  color: var(--text-primary); }
.flash-error   { background: var(--bg-elevated); border-color: var(--status-paused);  color: var(--text-primary); }
.flash-info    { background: var(--bg-elevated); border-color: var(--text-accent);        color: var(--text-primary); }

.flash-close {
  margin-left: auto;
  cursor: pointer;
  opacity: 0.5;
  background: none;
  border: none;
  color: inherit;
  font-size: 1rem;
  line-height: 1;
}

#toast-container {
  position: fixed;
  bottom: 1.5rem;
  right: 1.5rem;
  z-index: 9999;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.toast {
  background: var(--bg-elevated);
  border: 1px solid var(--border-strong);
  border-radius: var(--radius-md);
  padding: 0.75rem 1rem;
  font-size: 0.83rem;
  color: var(--text-primary);
  box-shadow: var(--shadow-lg);
  animation: slideInRight 0.3s ease;
  min-width: 250px;
  display: flex;
  align-items: center;
  gap: 8px;
}

.toast.success { border-left: 3px solid var(--status-active); }
.toast.error   { border-left: 3px solid var(--status-paused); }
.toast.info    { border-left: 3px solid var(--text-accent); }

@keyframes slideInRight {
  from { transform: translateX(120%); opacity: 0; }
  to   { transform: translateX(0);    opacity: 1; }
}

@keyframes fadeIn {
  from { opacity: 0; transform: translateY(8px); }
  to   { opacity: 1; transform: translateY(0); }
}

/* ================================================================
   STAR RATINGS
   ================================================================ */
.stars { display: flex; gap: 2px; }
.star { color: var(--status-pending); font-size: 0.75rem; }
.star.empty { color: var(--border-strong); }

/* ================================================================
   WIZARD
   ================================================================ */
.wizard-steps {
  display: flex;
  align-items: flex-start;
  margin-bottom: 2rem;
}

.wizard-step {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
  position: relative;
}

.wizard-step:not(:last-child)::after {
  content: '';
  position: absolute;
  top: 16px;
  left: 50%;
  width: 100%;
  height: 1px;
  background: var(--border-default);
  z-index: 0;
}

.wizard-step.done::after,
.wizard-step.active::after { background: var(--text-accent); }

.step-circle {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: var(--bg-elevated);
  border: 2px solid var(--border-default);
  display: grid;
  place-items: center;
  font-family: var(--font-display);
  font-size: 0.82rem;
  font-weight: 700;
  color: var(--text-muted);
  position: relative;
  z-index: 1;
  transition: all 0.25s;
}

.wizard-step.active .step-circle {
  border-color: var(--text-accent);
  background: var(--accent-alpha-10);
  color: var(--text-accent);
}

.wizard-step.done .step-circle {
  border-color: var(--status-active);
  background: rgba(34,197,94,0.12);
  color: var(--status-active);
}

.step-label {
  font-size: 0.65rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--text-muted);
}

.wizard-step.active .step-label { color: var(--text-accent); }

.wizard-panel { display: none; }
.wizard-panel.active { display: block; animation: fadeIn 0.25s ease; }

/* ================================================================
   ACTIVITY FEED
   ================================================================ */
.activity-item {
  display: flex;
  gap: 10px;
  padding: 0.7rem 0.75rem;
  border-bottom: 1px solid var(--border-subtle);
  align-items: flex-start;
}

.activity-item:last-child { border-bottom: none; }

.activity-icon {
  width: 30px;
  height: 30px;
  border-radius: var(--radius-md);
  background: var(--accent-alpha-07);
  display: grid;
  place-items: center;
  color: var(--text-accent);
  flex-shrink: 0;
}

.activity-icon svg { width: 13px; height: 13px; }
.activity-text { font-size: 0.83rem; font-weight: 300; color: var(--text-secondary); line-height: 1.6; }
.activity-time { font-family: var(--font-mono); font-size: 0.68rem; color: var(--text-muted); margin-top: 2px; }

/* ================================================================
   COLLAPSIBLE
   ================================================================ */
.collapsible-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  cursor: pointer;
  user-select: none;
  padding: 1rem 1.25rem;
  background: var(--bg-surface);
  border: 1px solid var(--border-default);
  border-radius: var(--radius-lg);
  transition: background 0.18s;
}

.collapsible-header:hover { background: var(--bg-elevated); }

.collapsible-header.open {
  border-radius: var(--radius-lg) var(--radius-lg) 0 0;
  border-bottom-color: var(--border-subtle);
}

.collapsible-chevron { transition: transform 0.25s ease; color: var(--text-muted); }
.collapsible-header.open .collapsible-chevron { transform: rotate(180deg); }

.collapsible-body {
  background: var(--bg-surface);
  border: 1px solid var(--border-default);
  border-top: none;
  border-radius: 0 0 var(--radius-lg) var(--radius-lg);
  padding: 1.25rem;
  display: none;
}

.collapsible-body.open { display: block; animation: fadeIn 0.2s ease; }

/* ================================================================
   PROJECT CARDS
   ================================================================ */
.project-card {
  background: var(--bg-surface);
  border: 1px solid var(--border-default);
  border-radius: var(--radius-lg);
  padding: 1.2rem;
  display: flex;
  flex-direction: column;
  gap: 0.85rem;
  transition: all 0.25s ease;
}

.project-card:hover {
  border-color: var(--border-accent);
  box-shadow: var(--shadow-md);
  transform: translateY(-1px);
}

.project-name { font-weight: 700; font-size: 0.95rem; color: var(--text-heading); }
.project-desc { font-size: 0.8rem; font-weight: 300; color: var(--text-muted); line-height: 1.6; }

.project-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
}

.project-meta-item {
  display: flex;
  align-items: center;
  gap: 5px;
  font-size: 0.75rem;
  color: var(--text-secondary);
}

.project-meta-item svg { width: 12px; height: 12px; color: var(--text-muted); }

.project-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-top: 0.5rem;
  border-top: 1px solid var(--border-subtle);
  font-size: 0.75rem;
  color: var(--text-muted);
}

/* ================================================================
   MISC COMPONENTS
   ================================================================ */
.switch-banner {
  background: var(--accent-alpha-07);
  border: 1px solid var(--border-accent);
  border-radius: var(--radius-md);
  padding: 0.6rem 1rem;
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 0.82rem;
  color: var(--text-secondary);
  margin-bottom: 1rem;
}

.plan-card {
  background: var(--bg-elevated);
  border: 2px solid var(--border-default);
  border-radius: var(--radius-lg);
  padding: 1.5rem;
  text-align: center;
  cursor: pointer;
  transition: all 0.2s;
  display: block;
}

.plan-card:hover { border-color: var(--text-accent); }
.plan-card.selected { border-color: var(--text-accent); background: var(--accent-alpha-05); }

.plan-price { font-family: var(--font-display); font-size: 2.2rem; font-weight: 800; color: var(--text-heading); line-height: 1; margin: 0.25rem 0; }
.plan-price span { font-size: 0.9rem; color: var(--text-muted); font-weight: 400; }
.plan-name { font-family: var(--font-display); font-size: 0.78rem; letter-spacing: 0.15em; text-transform: uppercase; color: var(--text-muted); }

.client-switch-select {
  background: var(--bg-elevated);
  border: 1px solid var(--border-default);
  border-radius: var(--radius-md);
  color: var(--text-primary);
  font-family: var(--font-body);
  font-size: 0.8rem;
  padding: 0.4rem 0.8rem;
  cursor: pointer;
  outline: none;
  -webkit-appearance: none;
  appearance: none;
}

.divider {
  height: 1px;
  background: var(--border-default);
  margin: 1.25rem 0;
}

.empty-state {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 3rem;
  text-align: center;
  color: var(--text-muted);
  gap: 0.75rem;
}

.empty-state svg { opacity: 0.3; }
.empty-state p { font-size: 0.85rem; }

/* ================================================================
   UTILITY CLASSES
   ================================================================ */
.flex           { display: flex; }
.flex-col       { flex-direction: column; }
.items-center   { align-items: center; }
.justify-between{ justify-content: space-between; }
.gap-1          { gap: 0.5rem; }
.gap-2          { gap: 1rem; }
.gap-3          { gap: 1.5rem; }
.mt-1           { margin-top: 0.5rem; }
.mt-2           { margin-top: 1rem; }
.mt-3           { margin-top: 1.5rem; }
.mb-1           { margin-bottom: 0.5rem; }
.mb-2           { margin-bottom: 1rem; }
.text-sm        { font-size: 0.82rem; }
.text-xs        { font-size: 0.72rem; }
.text-muted     { color: var(--text-muted); }
.text-accent    { color: var(--text-accent); }
.text-right     { text-align: right; }
.font-mono      { font-family: var(--font-mono); }
.truncate       { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.w-full         { width: 100%; }

/* ================================================================
   RESPONSIVE
   ================================================================ */
/* ── Responsive: Tablet (≤ 1024px) ── */
@media (max-width: 1024px) {
  /* Auth */
  .auth-middle          { grid-template-columns: 1fr; grid-template-rows: auto auto; }
  .auth-brand           { display: flex; border-right: none; border-bottom: 1px solid var(--border-default); padding: 2.5rem 2rem; order: 1; }
  .auth-brand h2        { font-size: 2rem; }
  .auth-panel           { padding: 2.5rem; order: 2; }
  .auth-panel .center   { align-items: center; }
  .auth-header          { padding: 0.5rem 1.5rem; }
  .auth-footer          { flex-direction: column; gap: 0.3rem; padding: 0.75rem 1rem; }
  .auth-footer-left,
  .auth-footer-right,
  .copyright            { text-align: center; font-size: 0.75rem; }

  /* App sidebar: narrower */
  :root                 { --sidebar-w: 200px; }

  /* Dashboard: stack projects + activity vertically */
  .dashboard-cols       { grid-template-columns: 1fr !important; }

  /* Account: collapse side-by-side grids */
  .account-grid         { grid-template-columns: 1fr !important; }

  /* App grids */
  .grid-4, .Status_Projects, .Status_Screeners, .Status_Panel, .Status_Communities               { grid-template-columns: repeat(2, 1fr); }
  .grid-3               { grid-template-columns: repeat(2, 1fr); }
}

/* ── Responsive: Mobile (≤ 640px) ── */
@media (max-width: 640px) {
  /* Auth */
  .auth-header          { padding: 0.45rem 1rem; }
  .brand-icon           { width: 22px; height: 22px; }
  .brand-name           { font-size: 1rem; }
  .brand-tagline        { display: none; }
  .auth-brand           { padding: 1.5rem 1.25rem; order: 1; }
  .auth-brand h2        { font-size: 1.5rem; margin-bottom: 0.6rem; }
  .auth-brand > p       { display: none; }
  .auth-panel           { padding: 1.75rem; order: 2; }
  .auth-panel .center   { align-items: center; }
  .auth-form-header     { margin-bottom: 1.5rem; }
  .auth-form-header h3  { font-size: 1.3rem; }

  /* Trend section: stack chart on top, stat cards below */
  .trend-section        { grid-template-columns: 1fr; grid-template-rows: auto auto; }
  .trend-stat-cards     { flex-direction: row; width: 100%; justify-content: stretch; }
  .trend-stat-card      { flex: 1; }

  /* Fix chart height on mobile so it doesn't collapse */
  .trend-chart-canvas-wrap { min-height: 180px; }

  /* Trust strip: stop overlapping login-form-box on mobile */
  .auth-trust-strip     { flex-wrap: wrap; gap: 0.4rem; padding: 0.5rem 0; margin-top: 1rem; }
  .auth-trust-item      { padding: 0 0.5rem; white-space: normal; }

  /* Login form box: natural height on mobile, don't stretch */
  .login-form-box       { flex: none; width: 95%; }
  .login-form-box > form { flex: none; }
  .login-form-box > form > button[type="submit"] { margin-top: 1rem; }

  /* App panel: natural flow on mobile */
  .auth-panel           { height: auto; overflow-y: visible; }
  .auth-panel .center:last-of-type { flex: none; margin-top: 1.5rem; }
  .auth-footer          { padding: 0.6rem 1rem; gap: 0.2rem; }
  .auth-footer-left,
  .auth-footer-right,
  .copyright            { font-size: 0.75rem; }
}

/* ── App shell: collapse sidebar on tablets + phones ── */
@media (max-width: 900px) {
  /* Sidebar slides in from left */
  .sidebar              { transform: translateX(-100%); transition: transform 0.28s cubic-bezier(0.4,0,0.2,1); }
  .sidebar.open         { transform: translateX(0); box-shadow: 4px 0 24px rgba(0,0,0,0.35); }
  .main-content         { margin-left: 0; width: 100vw; max-width: 100vw; }
  .topbar               { grid-template-columns: auto 1fr auto; gap: 0.5rem; }
  .topbar-search-wrap   { display: none; }
  .page-title           { font-size: 0.95rem; }

  /* Show hamburger */
  .mobile-menu-btn      { display: flex !important; }

  /* Sidebar close button visible */
  .sidebar-mobile-close { display: flex !important; }
}

/* ── Narrow phones only ── */
@media (max-width: 640px) {
  .grid-4, .Status_Projects, .Status_Screeners, .Status_Panel, .Status_Communities, .grid-3, .grid-2 { grid-template-columns: 1fr; }
  .form-row             { grid-template-columns: 1fr; }

  /* Dashboard */
  .dashboard-cols       { grid-template-columns: 1fr !important; }
  .metric-value         { font-size: 1.5rem; }

  /* Wizard modal: full screen */
  .wizard-modal-inner   { width: 95vw !important; max-height: 90vh; overflow-y: auto; margin: 1rem; }

  /* Account page */
  .account-grid         { grid-template-columns: 1fr !important; }
  .account-invite-row   { grid-template-columns: 1fr !important; }

  /* Tables: horizontal scroll */
  .table-wrap           { overflow-x: auto; -webkit-overflow-scrolling: touch; }
  table                 { min-width: 540px; }

  /* Cards: reduce padding */
  .card                 { padding: 1rem; }
  .page-body            { padding: 1rem; }

  /* Profile picture card */
  .picture-meta         { flex-wrap: wrap; }

  /* Projects grid */
  .grid-3               { grid-template-columns: 1fr; }
}



/* ================================================================
   TOPBAR USER IDENTITY CHIP
   ================================================================ */

.topbar-user-chip {
  display: flex;
  align-items: center;
  gap: 10px;
  /* info left, avatar right — padding tighter on left, more on right */
  padding: 5px 5px 5px 10px;
  border-radius: var(--radius-lg);
  border: 1px solid var(--border-default);
  background: var(--bg-elevated);
  text-decoration: none;
  cursor: pointer;
  transition: all 0.18s ease;
  max-width: 260px;
}

.topbar-user-chip:hover {
  border-color: var(--border-accent);
  background: var(--bg-hover);
  box-shadow: var(--shadow-sm);
}

/* Name + role text block — LEFT side */
.topbar-user-info {
  display: flex;
  flex-direction: column;
  gap: 1px;
  min-width: 0;
  text-align: right;
}

.topbar-user-name {
  font-size: 0.82rem;
  font-weight: 600;
  color: var(--text-primary);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  line-height: 1.2;
}

.topbar-user-role {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 4px;
  font-size: 0.68rem;
  color: var(--text-muted);
  white-space: nowrap;
  font-weight: 500;
}

.topbar-role-icon {
  width: 11px !important;
  height: 11px !important;
  flex-shrink: 0;
  color: var(--text-muted);
}

/* Avatar — RIGHT side */
.topbar-avatar {
  width: 30px;
  height: 30px;
  border-radius: var(--radius-md);
  background: linear-gradient(135deg, #8A6B30, var(--text-accent));
  display: grid;
  place-items: center;
  font-family: var(--font-display);
  font-size: 0.72rem;
  font-weight: 800;
  color: #fff;
  letter-spacing: 0.03em;
  flex-shrink: 0;
}

/* Login-type badge — shown next to client switcher, NOT inside chip */
.topbar-id-badge {
  display: inline-flex;
  align-items: center;
  padding: 3px 8px;
  border-radius: 2px;
  font-family: var(--font-display);
  font-size: 0.6rem;
  font-weight: 800;
  letter-spacing: 0.14em;
  flex-shrink: 0;
  border: 1px solid transparent;
  white-space: nowrap;
}

.topbar-id-badge--primary {
  background: var(--accent-alpha-10);
  color: var(--text-accent);
  border-color: rgba(201,163,110,0.25);
}

.topbar-id-badge--secondary {
  background: rgba(192,132,252,0.12);
  color: #C084FC;
  border-color: rgba(192,132,252,0.3);
}

.topbar-id-badge--tertiary {
  background: rgba(245,158,11,0.12);
  color: #FBBF24;
  border-color: rgba(245,158,11,0.3);
}

/* Client switch group: select + badge side-by-side */
.client-switch-group {
  display: flex;
  align-items: center;
  gap: 8px;
}

/* Thin vertical divider */
.topbar-divider {
  width: 1px;
  height: 22px;
  background: var(--border-default);
  flex-shrink: 0;
}

/* ================================================================
   SUPER ADMIN BADGE
   ================================================================ */

.topbar-id-badge--super {
  background: linear-gradient(135deg, rgba(245,158,11,0.22), rgba(251,191,36,0.12));
  color: #FBBF24;
  border-color: rgba(245,158,11,0.55);
  box-shadow: 0 0 10px rgba(245,158,11,0.22), inset 0 0 6px rgba(245,158,11,0.06);
  letter-spacing: 0.18em;
}

.topbar-avatar--super {
  background: linear-gradient(135deg, #B45309, #F59E0B) !important;
  box-shadow: 0 0 12px rgba(245,158,11,0.35);
}

/* ================================================================
   TOPBAR GLOBAL SEARCH
   ================================================================ */

/* Make topbar a 3-col layout: left | search | right */
.topbar {
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: center;
  gap: 1rem;
}

.topbar-left  { min-width: 0; }
.topbar-right { display: flex; align-items: center; gap: 0.75rem; justify-content: flex-end; flex-shrink: 0; }

.topbar-search-wrap {
  position: relative;
  width: 100%;
  max-width: 440px;
  margin: 0 auto;
}

.topbar-search-box {
  display: flex;
  align-items: center;
  gap: 8px;
  background: var(--bg-elevated);
  border: 1px solid var(--border-default);
  border-radius: var(--radius-md);
  padding: 0 0.75rem;
  height: 36px;
  transition: border-color 0.18s, box-shadow 0.18s;
}

.topbar-search-box:focus-within {
  border-color: var(--text-accent);
  box-shadow: 0 0 0 3px var(--accent-alpha-08);
  background: var(--bg-surface);
}

.search-icon {
  width: 14px;
  height: 14px;
  color: var(--text-muted);
  flex-shrink: 0;
}

.topbar-search-input {
  flex: 1;
  background: transparent;
  border: none;
  outline: none;
  font-family: var(--font-body);
  font-size: 0.85rem;
  color: var(--text-primary);
  min-width: 0;
}

.topbar-search-input::placeholder {
  color: var(--text-muted);
  font-size: 0.82rem;
}

.search-kbd {
  font-family: var(--font-mono);
  font-size: 0.62rem;
  color: var(--text-muted);
  background: var(--bg-overlay);
  border: 1px solid var(--border-default);
  border-radius: 3px;
  padding: 1px 5px;
  flex-shrink: 0;
  white-space: nowrap;
  user-select: none;
}

/* ── Search Dropdown ── */
.search-dropdown {
  position: absolute;
  top: calc(100% + 6px);
  left: 0;
  right: 0;
  background: var(--bg-surface);
  border: 1px solid var(--border-strong);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-lg);
  z-index: 500;
  overflow: hidden;
  max-height: 420px;
  overflow-y: auto;
  display: none;
}

.search-dropdown.open {
  display: block;
  animation: fadeIn 0.15s ease;
}

.search-empty,
.search-no-results {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 1.5rem;
  color: var(--text-muted);
  font-size: 0.82rem;
}

.search-loading {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 0.85rem 1rem;
  color: var(--text-muted);
  font-size: 0.82rem;
}

.search-group-label {
  padding: 0.5rem 1rem 0.25rem;
  font-size: 0.62rem;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--text-muted);
  background: var(--bg-elevated);
  border-bottom: 1px solid var(--border-subtle);
  position: sticky;
  top: 0;
  z-index: 1;
}

.search-result-item {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 0.65rem 1rem;
  text-decoration: none;
  border-bottom: 1px solid var(--border-subtle);
  transition: background 0.12s;
  cursor: pointer;
}

.search-result-item:last-child { border-bottom: none; }

.search-result-item:hover {
  background: var(--bg-hover);
}

.search-result-icon {
  width: 28px;
  height: 28px;
  border-radius: var(--radius-sm);
  display: grid;
  place-items: center;
  flex-shrink: 0;
}

.search-result-text {
  display: flex;
  flex-direction: column;
  gap: 2px;
  min-width: 0;
  flex: 1;
}

.search-result-label {
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--text-primary);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.search-result-sub {
  font-family: var(--font-mono);
  font-size: 0.68rem;
  color: var(--text-muted);
}

.search-result-badge {
  flex-shrink: 0;
  font-size: 0.6rem;
}

/* Spinner */
@keyframes spin {
  from { transform: rotate(0deg); }
  to   { transform: rotate(360deg); }
}
.spin { animation: spin 0.8s linear infinite; display: inline-block; }

/* ── Auth Trust Strip ── */
.auth-trust-strip {
  display: flex;
  align-items: center;
  justify-content: center;
  margin-top: 1rem;
  padding: 0.7rem 0.5rem;
}
.auth-trust-item {
  display: flex;
  align-items: center;
  gap: 5px;
  font-size: 0.68rem;
  font-weight: 600;
  letter-spacing: 0.06em;
  color: var(--text-muted);
  padding: 0 0.85rem;
  white-space: nowrap;
}
.auth-trust-icon { width: 12px !important; height: 12px !important; flex-shrink: 0; color: var(--text-accent); }
.auth-trust-sep  { width: 1px; height: 14px; background: var(--border-default); flex-shrink: 0; }

/* ================================================================
   PROFILE PICTURE CARD
   ================================================================ */

.profile-picture-card {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1rem;
  padding: 1.75rem 1.25rem;
  background: var(--bg-surface);
  border: 1px solid var(--border-default);
  border-radius: var(--radius-lg);
  margin-bottom: 1.25rem;
  position: relative;
  overflow: hidden;
}

.profile-picture-card::before {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 80px;
  background: linear-gradient(135deg, var(--blue-800), var(--blue-600));
  opacity: 0.35;
  z-index: 0;
}

/* ── Avatar circle ── */
.picture {
  position: relative;
  z-index: 1;
}

.picture-avatar {
  width: 88px;
  height: 88px;
  border-radius: 50%;
  background: linear-gradient(135deg, #8A6B30, var(--text-accent));
  display: grid;
  place-items: center;
  overflow: hidden;
  border: 3px solid var(--bg-surface);
  box-shadow: 0 4px 16px rgba(0,0,0,0.3);
  cursor: pointer;
  transition: box-shadow 0.2s;
  position: relative;
}

.picture-avatar:hover {
  box-shadow: 0 4px 20px var(--accent-alpha-38);
}

.picture-avatar:hover /* Two-icon overlay — edit + remove, appears on hover */
.picture-edit-overlay {
  position: absolute;
  inset: 0;
  border-radius: 50%;
  background: rgba(0,0,0,0.5);
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  opacity: 0;
  transition: opacity 0.2s ease;
  z-index: 2;
}

.picture-overlay-btn {
  background: rgba(255,255,255,0.12);
  border: 1px solid rgba(255,255,255,0.25);
  border-radius: 50%;
  width: 36px;
  height: 36px;
  display: grid;
  place-items: center;
  cursor: pointer;
  transition: background 0.15s, transform 0.15s;
  flex-shrink: 0;
}

.picture-overlay-btn:hover {
  background: rgba(255,255,255,0.28);
  transform: scale(1.1);
}

.picture-overlay-btn--danger:hover {
  background: rgba(239,68,68,0.55);
  border-color: rgba(239,68,68,0.6);
}

#picture-initials {
  font-family: var(--font-display);
  font-size: 1.8rem;
  font-weight: 800;
  color: #fff;
  letter-spacing: 0.04em;
  user-select: none;
  position: relative;
  z-index: 1;
}



/* ── Identity below photo ── */
.picture-identity {
  text-align: center;
  z-index: 1;
}

.picture-name {
  font-family: var(--font-display);
  font-size: 1.2rem;
  font-weight: 700;
  color: var(--text-heading);
  letter-spacing: 0.02em;
  margin-bottom: 0.35rem;
}

/* company + email on the same row */
.picture-meta {
  display: flex;
  flex-direction: row;
  align-items: center;
  justify-content: center;
  flex-wrap: wrap;
  gap: 0.4rem;
}

.picture-meta-sep {
  color: var(--border-strong);
  font-size: 0.75rem;
  line-height: 1;
}

.picture-company,
.picture-role,
.picture-email {
  font-size: 0.8rem;
  color: var(--text-muted);
  display: flex;
  align-items: center;
  gap: 4px;
  white-space: nowrap;
}

.picture-company {
  font-weight: 500;
  color: var(--text-secondary);
}

.picture-role {
  font-weight: 600;
  color: var(--text-accent);
}

/* ================================================================
   MOBILE MENU BUTTON + SIDEBAR OVERLAY
   ================================================================ */

.mobile-menu-btn {
  display: none;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  border-radius: var(--radius-md);
  border: 1px solid var(--border-default);
  background: var(--bg-surface);
  color: var(--text-secondary);
  cursor: pointer;
  flex-shrink: 0;
  transition: background 0.15s, color 0.15s;
}
@media (max-width: 900px) {
  .mobile-menu-btn { display: flex; }
}
.mobile-menu-btn:hover {
  background: var(--bg-hover);
  color: var(--text-primary);
}

.sidebar-overlay {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.5);
  z-index: 99;
  backdrop-filter: blur(2px);
}

/* Responsive: wizard modals */
@media (max-width: 640px) {
  #wizard-overlay > div { width: 95vw !important; max-width: none !important; }
}

/* Responsive: dashboard activity + project columns */
@media (max-width: 768px) {
  .grid-4, .Status_Projects, .Status_Screeners, .Status_Panel, .Status_Communities { grid-template-columns: repeat(2, 1fr); }
}

/* ================================================================
   LOGIN PAGE — FORM ENHANCEMENTS
   ================================================================ */

/* Inline flash messages inside the form box */
.login-flash {
  display: flex;
  align-items: flex-start;
  gap: 8px;
  padding: 0.65rem 0.85rem;
  border-radius: var(--radius-md);
  font-size: 0.83rem;
  margin-bottom: 1rem;
  border-left: 3px solid;
  line-height: 1.5;
}
.login-flash--error   { background: rgba(239,68,68,0.08);  border-color: #EF4444; color: #FCA5A5; }
.login-flash--success { background: rgba(34,197,94,0.08);  border-color: #22C55E; color: #86EFAC; }
.login-flash--info,
.login-flash--message { background: var(--accent-alpha-07); border-color: var(--text-accent); color: var(--text-accent); }

/* Remember me + forgot password row */
.login-form-meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-top: 0.5rem;
  margin-bottom: 1.5rem;
}

.login-remember {
  display: flex;
  align-items: center;
  gap: 7px;
  font-size: 0.82rem;
  color: var(--text-secondary);
  cursor: pointer;
  user-select: none;
}

.login-remember input[type="checkbox"] {
  width: 14px;
  height: 14px;
  accent-color: var(--text-accent);
  cursor: pointer;
  flex-shrink: 0;
}

.login-forgot {
  font-size: 0.8rem;
  color: var(--text-accent);
  text-decoration: none;
  transition: color 0.15s;
}
.login-forgot:hover { color: var(--text-accent); text-decoration: underline; }

/* Spinner animation for loading state */

/* ================================================================
   SCREENER FRAUD FILTER TOGGLES
   ================================================================ */
.screener-toggle { cursor: pointer; }
.screener-toggle-pill {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 0.3rem 0.75rem;
  border-radius: 20px;
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.04em;
  border: 1px solid var(--border-default);
  background: var(--bg-overlay);
  color: var(--text-muted);
  cursor: pointer;
  transition: background 0.15s, border-color 0.15s, color 0.15s;
  user-select: none;
}

/* ================================================================
   HOME / LANDING PAGE
   ================================================================ */

.home-wrapper {
  min-height: 100vh;
  background: var(--bg-void);
  display: flex;
  flex-direction: column;
}

/* ── Nav ── */
.home-nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0.85rem 3rem;
  background: var(--bg-base);
  border-bottom: 1px solid var(--border-default);
  position: sticky;
  top: 0;
  z-index: 100;
}

.home-nav-brand {
  display: flex;
  align-items: center;
  gap: 10px;
}

.home-nav-logo {
  font-family:'iBrand', var(--font-display, sans-serif);
  font-size: 1.3rem;
  font-weight: 400;
  letter-spacing: 0.1em;
  color: var(--text-heading);
}

.home-nav-links {
  display: flex;
  align-items: center;
  gap: 1.5rem;
}

.home-nav-link {
  font-size: 0.88rem;
  font-weight: 500;
  color: var(--text-secondary);
  text-decoration: none;
  transition: color 0.15s;
}
.home-nav-link:hover { color: var(--text-primary); }

/* ── Hero ── */
.home-hero {
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 5rem 2rem 0;
  text-align: center;
  background: var(--bg-base);
  border-bottom: 1px solid var(--border-default);
  position: relative;
  overflow: hidden;
}

.home-hero::before {
  content: '';
  position: absolute;
  top: -150px;
  left: 50%;
  transform: translateX(-50%);
  width: 800px;
  height: 600px;
  background: radial-gradient(circle, var(--accent-alpha-07) 0%, transparent 65%);
  pointer-events: none;
}

.home-hero-inner {
  max-width: 760px;
  position: relative;
  z-index: 1;
}

.home-hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 0.35rem 0.9rem;
  background: var(--accent-alpha-08);
  border: 1px solid var(--accent-alpha-18);
  border-radius: 20px;
  font-size: 0.75rem;
  font-weight: 600;
  color: var(--text-accent);
  letter-spacing: 0.04em;
  margin-bottom: 1.5rem;
}

.home-hero-heading {
  font-size: 3.4rem;
  line-height: 1.08;
  letter-spacing: -0.01em;
  color: var(--text-heading);
  margin-bottom: 1.25rem;
}

.home-hero-accent {
  background: linear-gradient(135deg, var(--text-accent), var(--accent-alpha-60));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.home-hero-sub {
  font-weight: 300;
  font-size: 1.08rem;
  color: var(--text-secondary);
  line-height: 1.7;
  max-width: 580px;
  margin: 0 auto 2rem;
}

.home-hero-actions {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.75rem;
  margin-bottom: 1.5rem;
  flex-wrap: wrap;
}

.home-hero-trust {
  display: flex;
  align-items: center;
  justify-content: center;
  flex-wrap: wrap;
  gap: 0.5rem;
  font-size: 0.78rem;
  color: var(--text-muted);
  margin-bottom: 3rem;
}
.home-trust-sep { color: var(--border-strong); }

/* Stats strip */
.home-stats-strip {
  display: flex;
  align-items: stretch;
  width: 100%;
  max-width: 720px;
  background: var(--bg-elevated);
  border: 1px solid var(--border-default);
  border-bottom: none;
  border-radius: var(--radius-lg) var(--radius-lg) 0 0;
  overflow: hidden;
}

.home-stat {
  flex: 1;
  padding: 1.25rem 1rem;
  text-align: center;
}

.home-stat-value {
  font-family: var(--font-display);
  font-size: 1.8rem;
  font-weight: 800;
  color: var(--text-heading);
  letter-spacing: -0.02em;
  line-height: 1;
}

.home-stat-label {
  font-size: 0.68rem;
  font-weight: 600;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--text-muted);
  margin-top: 0.3rem;
}

.home-stat-divider {
  width: 1px;
  background: var(--border-default);
  flex-shrink: 0;
}

/* ── Sections ── */
.home-section {
  padding: 5rem 2rem;
}

.home-section--alt {
  background: var(--bg-base);
  border-top: 1px solid var(--border-default);
  border-bottom: 1px solid var(--border-default);
}

.home-section-inner {
  max-width: 1080px;
  margin: 0 auto;
}

.home-section-label {
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--text-accent);
  margin-bottom: 0.75rem;
}

.home-section-heading {
  font-size: 2.2rem;
  color: var(--text-heading);
  margin-bottom: 0.75rem;
}

.home-section-sub {
  font-weight: 300;
  font-size: 1rem;
  color: var(--text-secondary);
  line-height: 1.7;
  max-width: 560px;
  margin-bottom: 3rem;
}

/* ── Feature Cards ── */
.home-features-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1rem;
}

.home-feature-card {
  background: var(--bg-surface);
  border: 1px solid var(--border-default);
  border-radius: var(--radius-lg);
  padding: 1.5rem;
  transition: border-color 0.18s, box-shadow 0.18s;
}

.home-feature-card:hover {
  border-color: var(--border-accent);
  box-shadow: var(--shadow-sm);
}

.home-feature-icon {
  width: 40px;
  height: 40px;
  border-radius: var(--radius-md);
  background: var(--accent-alpha-08);
  display: grid;
  place-items: center;
  color: var(--text-accent);
  margin-bottom: 0.85rem;
}

.home-feature-title {
  font-family: var(--font-display);
  font-size: 0.95rem;
  font-weight: 700;
  color: var(--text-heading);
  letter-spacing: 0.02em;
  margin-bottom: 0.4rem;
}

.home-feature-desc {
  font-size: 0.82rem;
  color: var(--text-muted);
  font-weight: 300;
  line-height: 1.6;
}

/* ── How It Works ── */
.home-steps {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1.5rem;
  position: relative;
}

.home-steps::before {
  content: '';
  position: absolute;
  top: 28px;
  left: 12%;
  right: 12%;
  height: 1px;
  background: linear-gradient(90deg, var(--border-default), var(--text-accent), var(--border-default));
  z-index: 0;
}

.home-step {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  position: relative;
  z-index: 1;
}

.home-step-num {
  font-family: var(--font-mono);
  font-size: 0.65rem;
  font-weight: 600;
  color: var(--text-accent);
  letter-spacing: 0.1em;
  margin-bottom: 0.5rem;
}

.home-step-icon {
  width: 56px;
  height: 56px;
  border-radius: 50%;
  background: var(--bg-elevated);
  border: 2px solid var(--border-accent);
  display: grid;
  place-items: center;
  color: var(--text-accent);
  margin-bottom: 1rem;
  box-shadow: 0 0 16px var(--accent-alpha-12);
}

.home-step-title {
  font-family: var(--font-display);
  font-size: 0.95rem;
  font-weight: 700;
  color: var(--text-heading);
  margin-bottom: 0.4rem;
}

.home-step-desc {
  font-weight: 300;
  font-size: 0.8rem;
  color: var(--text-muted);
  line-height: 1.6;
}

/* ── Pricing ── */
.home-pricing-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.25rem;
  align-items: start;
}

.home-pricing-card {
  background: var(--bg-surface);
  border: 1px solid var(--border-default);
  border-radius: var(--radius-xl);
  padding: 2rem 1.75rem;
  display: flex;
  flex-direction: column;
  gap: 0;
  position: relative;
}

.home-pricing-card--highlight {
  border-color: var(--text-accent);
  background: linear-gradient(160deg, var(--bg-elevated), var(--bg-surface));
  box-shadow: 0 0 40px var(--accent-alpha-10);
}

.home-pricing-badge {
  position: absolute;
  top: -12px;
  left: 50%;
  transform: translateX(-50%);
  background: var(--text-accent);
  color: var(--bg-void);
  font-size: 0.65rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  padding: 0.25rem 0.85rem;
  border-radius: 10px;
  white-space: nowrap;
}

.home-pricing-name {
  font-family: var(--font-display);
  font-size: 0.8rem;
  font-weight: 700;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--text-muted);
  margin-bottom: 0.5rem;
}

.home-pricing-price {
  font-family: var(--font-display);
  font-size: 2.8rem;
  font-weight: 800;
  color: var(--text-heading);
  line-height: 1;
  margin-bottom: 1.5rem;
}
.home-pricing-price span {
  font-size: 0.9rem;
  font-weight: 400;
  color: var(--text-muted);
}

.home-pricing-features {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 0.6rem;
  margin-bottom: 1.75rem;
  flex: 1;
}

.home-pricing-features li {
  display: flex;
  align-items: flex-start;
  gap: 8px;
  font-size: 0.84rem;
  color: var(--text-secondary);
  line-height: 1.4;
}

/* ── CTA ── */
.home-cta {
  background: linear-gradient(135deg, var(--bg-elevated), var(--bg-surface));
  border-top: 1px solid var(--border-default);
  padding: 5rem 2rem;
  text-align: center;
}

.home-cta-inner { max-width: 600px; margin: 0 auto; }

.home-cta-heading {
  font-size: 2.4rem;
  color: var(--text-heading);
  margin-bottom: 0.75rem;
}

.home-cta-sub {
  font-weight: 300;
  font-size: 1rem;
  color: var(--text-secondary);
  line-height: 1.7;
  margin-bottom: 2rem;
}

/* ── Footer ── */
.home-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 1rem;
  padding: 1.25rem 3rem;
  background: var(--bg-base);
  border-top: 1px solid var(--border-default);
}

.home-footer-brand { display: flex; align-items: center; gap: 8px; }

.home-footer-copy { font-size: 0.78rem; color: var(--text-muted); }

.home-footer-links { display: flex; gap: 1.25rem; }
.home-footer-link { font-size: 0.82rem; color: var(--text-muted); text-decoration: none; transition: color 0.15s; }
.home-footer-link:hover { color: var(--text-primary); }

/* ── Responsive ── */
@media (max-width: 1024px) {
  .home-features-grid { grid-template-columns: repeat(2, 1fr); }
  .home-pricing-grid  { grid-template-columns: 1fr; max-width: 420px; margin: 0 auto; }
  .home-steps         { grid-template-columns: repeat(2, 1fr); }
  .home-steps::before { display: none; }
  .home-nav           { padding: 0.85rem 1.5rem; }
  .home-hero          { padding: 3rem 1.5rem 0; }
}

@media (max-width: 640px) {
  .home-nav-links     { display: none; flex-direction: column; position: absolute; top: 57px; left: 0; right: 0; background: var(--bg-base); border-bottom: 1px solid var(--border-default); padding: 1rem 1.5rem; gap: 1rem; z-index: 200; }
  .home-nav-links--open { display: flex; }
  .home-nav           { padding: 0.75rem 1rem; position: relative; }
  .home-hero-heading  { font-size: 2.2rem; }
  .home-features-grid { grid-template-columns: 1fr; }
  .home-steps         { grid-template-columns: 1fr; }
  .home-stats-strip   { flex-wrap: wrap; border-radius: 0; }
  .home-stat          { min-width: 50%; }
  .home-stat-divider  { display: none; }
  .home-footer        { flex-direction: column; align-items: center; text-align: center; padding: 1.25rem 1rem; }
  .home-section       { padding: 3rem 1rem; }
  .home-cta           { padding: 3rem 1rem; }
}

/* ================================================================
   HOME / LANDING PAGE
   ================================================================ */

.home-wrapper {
  min-height: 100vh;
  background: var(--bg-void);
  display: flex;
  flex-direction: column;
}

/* ── Navbar ── */
.home-nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0.85rem 3rem;
  background: var(--bg-base);
  border-bottom: 1px solid var(--border-default);
  position: sticky;
  top: 0;
  z-index: 100;
}

.home-nav-brand {
  display: flex;
  align-items: center;
  gap: 10px;
}

.home-nav-links {
  display: flex;
  align-items: center;
  gap: 1.5rem;
}

.home-nav-link {
  font-size: 0.88rem;
  font-weight: 500;
  color: var(--text-secondary);
  text-decoration: none;
  transition: color 0.15s;
}

.home-nav-link:hover { color: var(--text-primary); }

/* ── Hero ── */
.home-hero {
  display: grid;
  grid-template-columns: 1fr 380px;
  gap: 3rem;
  align-items: center;
  padding: 5rem 3rem 4rem;
  background: var(--bg-base);
  border-bottom: 1px solid var(--border-default);
  position: relative;
  overflow: hidden;
}

.home-hero::before {
  content: '';
  position: absolute;
  top: -120px; right: -120px;
  width: 600px; height: 600px;
  background: radial-gradient(circle, var(--accent-alpha-06) 0%, transparent 65%);
  pointer-events: none;
}

.home-hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: var(--accent-alpha-08);
  border: 1px solid var(--accent-alpha-18);
  color: var(--text-accent);
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  padding: 0.35rem 0.85rem;
  border-radius: 20px;
  margin-bottom: 1.5rem;
}

.home-hero-title {
  font-size: 3.2rem;
  line-height: 1.08;
  margin-bottom: 1.25rem;
  max-width: 580px;
  letter-spacing: -0.01em;
}

.home-hero-accent {
  color: var(--text-accent);
}

.home-hero-sub {
  font-size: 1rem;
  color: var(--text-secondary);
  line-height: 1.7;
  max-width: 520px;
  margin-bottom: 2rem;
}

.home-hero-cta {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  margin-bottom: 2rem;
}

.home-hero-trust {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 1.25rem;
}

.home-hero-trust span {
  display: flex;
  align-items: center;
  gap: 5px;
  font-size: 0.78rem;
  font-weight: 500;
  color: var(--text-muted);
}

/* Hero stat cards */
.home-hero-stats {
  display: flex;
  flex-direction: column;
  gap: 0.85rem;
  z-index: 1;
}

.home-stat-card {
  background: var(--bg-elevated);
  border: 1px solid var(--border-default);
  border-radius: var(--radius-lg);
  padding: 1.1rem 1.25rem;
  display: flex;
  align-items: center;
  gap: 1rem;
  transition: border-color 0.18s, box-shadow 0.18s;
}

.home-stat-card:hover {
  border-color: var(--border-accent);
  box-shadow: var(--shadow-sm);
}

.home-stat-value {
  font-family: var(--font-display);
  font-size: 1.7rem;
  font-weight: 800;
  color: var(--text-heading);
  letter-spacing: -0.02em;
  line-height: 1;
  flex: 1;
}

.home-stat-label {
  font-size: 0.72rem;
  color: var(--text-muted);
  line-height: 1.4;
  flex: 2;
}

.home-stat-icon { flex-shrink: 0; opacity: 0.7; }

/* ── Sections ── */
.home-section {
  padding: 6rem 3rem;
}

.home-section--alt {
  background: var(--bg-surface);
  border-top: 1px solid var(--border-default);
  border-bottom: 1px solid var(--border-default);
  position: relative;
  overflow: hidden;
}

/* Subtle diagonal texture on alt sections */
.home-section--alt::before {
  content: '';
  position: absolute;
  inset: 0;
  background:
    repeating-linear-gradient(
      -45deg,
      transparent,
      transparent 40px,
      rgba(71,142,255,0.015) 40px,
      rgba(71,142,255,0.015) 41px
    );
  pointer-events: none;
}

.home-section-inner {
  max-width: 1100px;
  margin: 0 auto;
  position: relative;
}

.home-section-label {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--text-accent);
  background: rgba(201,163,110,0.07);
  border: 1px solid var(--accent-alpha-15);
  border-radius: 999px;
  padding: 0.25rem 0.75rem;
  margin-bottom: 1.25rem;
}

.home-section-title {
  font-size: 2.4rem;
  font-weight: 800;
  line-height: 1.12;
  letter-spacing: -0.02em;
  margin-bottom: 1rem;
  max-width: 620px;
}

.home-section-sub {
  font-size: 1rem;
  color: var(--text-secondary);
  line-height: 1.7;
  max-width: 540px;
  margin-bottom: 3.5rem;
}

/* ── Features grid — left-accent style ── */
.home-features-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1rem;
}

.home-feature-card {
  background: var(--bg-elevated);
  border: 1px solid var(--border-default);
  border-left: 3px solid transparent;
  border-radius: var(--radius-lg);
  padding: 1.5rem 1.5rem 1.5rem 1.25rem;
  transition: border-color 0.2s, box-shadow 0.2s, transform 0.2s;
}

.home-feature-card:nth-child(1) { border-left-color: #C9A96E; }
.home-feature-card:nth-child(2) { border-left-color: #22C55E; }
.home-feature-card:nth-child(3) { border-left-color: #F59E0B; }
.home-feature-card:nth-child(4) { border-left-color: #A855F7; }
.home-feature-card:nth-child(5) { border-left-color: #EF4444; }
.home-feature-card:nth-child(6) { border-left-color: #C9A96E; }

.home-feature-card:hover {
  border-color: var(--border-accent);
  border-left-width: 3px;
  box-shadow: var(--shadow-md);
  transform: translateY(-2px);
}

.home-feature-icon {
  width: 38px;
  height: 38px;
  border-radius: var(--radius-md);
  display: grid;
  place-items: center;
  margin-bottom: 0.85rem;
}

.home-feature-card h4 {
  font-size: 0.95rem;
  font-weight: 700;
  margin-bottom: 0.45rem;
  color: var(--text-heading);
}

.home-feature-card p {
  font-size: 0.83rem;
  color: var(--text-secondary);
  line-height: 1.65;
  margin: 0;
}

/* ── How it works — vertical timeline ── */
.home-steps {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0;
  margin-top: 0;
  position: relative;
}

.home-steps::before {
  content: '';
  position: absolute;
  left: 50%;
  top: 0;
  bottom: 0;
  width: 1px;
  background: var(--border-default);
  transform: translateX(-50%);
}

.home-step {
  display: grid;
  grid-template-columns: 48px 1fr;
  gap: 1.25rem;
  padding: 2rem;
  position: relative;
}

/* Even steps on right, odd on left */
.home-step:nth-child(odd) {
  padding-right: 3rem;
}
.home-step:nth-child(even) {
  padding-left: 3rem;
}

/* Connector dot on the centre line */
.home-step::after {
  content: '';
  position: absolute;
  top: 2.25rem;
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: var(--text-accent);
  border: 2px solid var(--bg-surface);
  box-shadow: 0 0 0 3px var(--accent-alpha-15);
}
.home-step:nth-child(odd)::after  { right: -5px; }
.home-step:nth-child(even)::after { left: -5px; }

.home-step-num {
  width: 48px;
  height: 48px;
  border-radius: var(--radius-md);
  background: var(--accent-alpha-07);
  border: 1px solid var(--accent-alpha-15);
  display: grid;
  place-items: center;
  font-family: var(--font-mono);
  font-size: 0.78rem;
  font-weight: 700;
  color: var(--text-accent);
  letter-spacing: 0.04em;
  flex-shrink: 0;
}

.home-step-arrow { display: none; }

.home-step-body h4 {
  font-size: 1rem;
  font-weight: 700;
  margin-bottom: 0.4rem;
  color: var(--text-heading);
}

.home-step-body p {
  font-size: 0.83rem;
  color: var(--text-secondary);
  line-height: 1.65;
  margin: 0;
}

/* ── Pricing ── */
.home-pricing-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.25rem;
  margin-top: 2.5rem;
}

.home-price-card {
  background: var(--bg-surface);
  border: 1px solid var(--border-default);
  border-radius: var(--radius-xl);
  padding: 2rem;
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  position: relative;
}

.home-price-card--featured {
  border-color: var(--text-accent);
  background: var(--bg-elevated);
  box-shadow: 0 0 40px var(--accent-alpha-10);
}

.home-price-badge {
  position: absolute;
  top: -12px;
  left: 50%;
  transform: translateX(-50%);
  background: var(--text-accent);
  color: var(--bg-void);
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  padding: 0.25rem 0.9rem;
  border-radius: 20px;
  white-space: nowrap;
}

.home-price-name {
  font-family: var(--font-display);
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--text-muted);
}

.home-price-amount {
  font-family: var(--font-display);
  font-size: 2.8rem;
  font-weight: 800;
  color: var(--text-heading);
  line-height: 1;
  letter-spacing: -0.03em;
  margin: 0.25rem 0;
}

.home-price-amount span {
  font-size: 1rem;
  font-weight: 400;
  color: var(--text-muted);
}

.home-price-desc {
  font-weight: 300;
  font-size: 0.82rem;
  color: var(--text-secondary);
  line-height: 1.6;
  margin-bottom: 1rem;
}

.home-price-features {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 0.6rem;
  margin-bottom: 1.5rem;
  flex: 1;
}

.home-price-features li {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 0.82rem;
  color: var(--text-secondary);
}

/* ── Footer ── */
.home-footer {
  padding: 2.5rem 3rem;
  background: var(--bg-base);
  border-top: 1px solid var(--border-default);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.25rem;
  text-align: center;
  margin-top: auto;
}

.home-footer-brand {
  display: flex;
  align-items: center;
  gap: 8px;
}

.home-footer-links {
  display: flex;
  gap: 1.5rem;
  margin-top: 0.75rem;
}

.home-footer-links a {
  font-size: 0.82rem;
  color: var(--text-muted);
  text-decoration: none;
  transition: color 0.15s;
}

.home-footer-links a:hover { color: var(--text-accent); }

/* ── Responsive ── */
@media (max-width: 1024px) {
  .home-hero            { grid-template-columns: 1fr; gap: 2rem; padding: 3.5rem 2rem; }
  .home-hero-stats      { flex-direction: row; flex-wrap: wrap; }
  .home-stat-card       { flex: 1; min-width: 160px; }
  .home-features-grid   { grid-template-columns: repeat(2, 1fr); }
  .home-pricing-grid    { grid-template-columns: repeat(2, 1fr); }
  .home-nav             { padding: 0.75rem 1.5rem; }
  .home-section         { padding: 3.5rem 2rem; }
}

@media (max-width: 640px) {
  .home-nav-links .home-nav-link { display: none; }
  .home-hero-title      { font-size: 2.2rem; }
  .home-features-grid   { grid-template-columns: 1fr; }
  .home-pricing-grid    { grid-template-columns: 1fr; }
  .home-steps           { flex-direction: column; gap: 1.5rem; }
  .home-step-arrow      { display: none; }
  .home-hero-stats      { grid-template-columns: 1fr 1fr; display: grid; }
  .home-section         { padding: 2.5rem 1.25rem; }
  .home-nav             { padding: 0.75rem 1.25rem; }
  .home-footer          { padding: 2rem 1.25rem; }
  .home-price-card:nth-child(2) { order: -1; }
}

/* ================================================================
   SITE MAP
   ================================================================ */
/* ── Newsletter CTA strip (suggestion 9) ── */
.site-map-newsletter {
  background: var(--bg-elevated);
  border-top: 1px solid var(--border-default);
  border-bottom: 1px solid var(--border-default);
  padding: 1.25rem 3rem;
}

.site-map-newsletter-inner {
  max-width: 1100px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 2rem;
  flex-wrap: wrap;
}

.site-map-newsletter-copy {
  display: flex;
  align-items: center;
  gap: 0.85rem;
}

.site-map-newsletter-title {
  font-family: var(--font-display);
  font-size: 0.95rem;
  font-weight: 700;
  color: var(--text-heading);
}

.site-map-newsletter-sub {
  font-size: 0.78rem;
  color: var(--text-muted);
  margin-top: 2px;
}

.site-map-newsletter-form {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  flex-shrink: 0;
}

.site-map-newsletter-input {
  background: var(--bg-base);
  border: 1px solid var(--border-default);
  border-radius: var(--radius-md);
  color: var(--text-primary);
  font-family: var(--font-body);
  font-size: 0.85rem;
  padding: 0.55rem 0.9rem;
  outline: none;
  width: 220px;
  transition: border-color 0.18s, box-shadow 0.18s;
}

.site-map-newsletter-input:focus {
  border-color: var(--text-accent);
  box-shadow: 0 0 0 3px var(--accent-alpha-10);
}

.site-map-newsletter-input::placeholder { color: var(--text-muted); }

/* ── Site map (suggestion 1: top accent gradient) ── */
.site-map {
  background: var(--bg-void);
  border-top: 1px solid var(--border-subtle);
  padding: 5.5rem 3rem;
  position: relative;
  overflow: hidden;
}

.site-map-inner {
  max-width: 1400px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1.8fr 1.5fr 1fr 1fr;
  gap: 3rem;
}

.site-map-brand {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 0.85rem;
}

.site-map-brand-sep {
  height: 1px;
  background: var(--border-default);
  margin: 0.75rem 0 1rem;
  max-width: 300px;
}

.site-map-desc {
  font-size: 0.82rem;
  color: var(--text-secondary);
  line-height: 1.7;
  max-width: 300px;
  margin-bottom: 1rem;
  font-weight: 300;
}

.site-map-trust-badges {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
  margin-top: 0.25rem;
}

.site-map-badge {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 0.25rem 0.65rem;
  border-radius: 100px;
  font-size: 0.65rem;
  font-weight: 600;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  background: var(--accent-alpha-07);
  border: 1px solid var(--border-default);
  color: var(--text-accent);
  font-family: var(--font-mono);
}

.site-map-group-header {
  font-family: var(--font-mono);
  font-size: 0.65rem;
  font-weight: 600;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--text-muted);
  margin-bottom: 1rem;
}

.site-map-links {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 0;
}

.site-map-links li a {
  display: block;
  padding: 0.45rem 0 0.45rem 0.75rem;
  border-left: 2px solid transparent;
  font-size: 0.83rem;
  color: var(--text-secondary);
  text-decoration: none;
  transition: color 0.15s, border-color 0.15s;
  font-weight: 300;
}

.site-map-links li a:hover {
  color: var(--text-accent);
  border-left-color: var(--text-accent);
}

.site-map-link-name {
  display: block;
  font-size: 0.83rem;
  color: var(--text-secondary);
  font-weight: 500;
  transition: color 0.15s;
}

.site-map-link-desc {
  display: block;
  font-size: 0.72rem;
  color: var(--text-muted);
  margin-top: 1px;
  transition: color 0.15s;
  font-weight: 300;
}

.site-map-links li a:hover .site-map-link-name { color: var(--text-accent); }
.site-map-links li a:hover .site-map-link-desc { color: var(--text-secondary); }

.site-map-social {
  display: flex;
  flex-wrap: wrap;
  gap: 0.6rem;
  margin-top: 0.25rem;
}

.site-map-social-btn {
  width: 34px;
  height: 34px;
  border-radius: 6px;
  border: 1px solid var(--border-default);
  background: var(--bg-surface);
  color: var(--text-secondary);
  display: grid;
  place-items: center;
  text-decoration: none;
  transition: color 0.18s, border-color 0.18s, background 0.18s;
}

.site-map-social-btn--linkedin:hover  { color: #0A66C2; border-color: rgba(10,102,194,0.4);  background: rgba(10,102,194,0.08); }
.site-map-social-btn--twitter:hover   { color: #E7E9EA; border-color: rgba(231,233,234,0.3); background: rgba(231,233,234,0.06); }
.site-map-social-btn--github:hover    { color: #6e5494; border-color: rgba(110,84,148,0.4);  background: rgba(110,84,148,0.08); }
.site-map-social-btn--youtube:hover   { color: #FF0000; border-color: rgba(255,0,0,0.35);    background: rgba(255,0,0,0.06); }

/* ── Footer ── */
.home-auth-footer {
  max-width: none;
  padding: 1.25rem 3rem;
  background: var(--bg-base);
  border-top: 1px solid var(--border-subtle);
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-family: var(--font-body);
  font-size: 0.75rem;
  color: var(--text-muted);
}

.auth-footer-left {
  display: flex;
  align-items: center;
  gap: 0.85rem;
  flex-wrap: wrap;
}

.auth-footer-left a {
  color: var(--text-muted);
  text-decoration: none;
  font-size: 0.75rem;
  font-weight: 400;
  transition: color 0.15s;
}
.auth-footer-left a:hover { color: var(--text-accent); }

.auth-footer-sep {
  color: var(--border-strong);
  font-size: 0.7rem;
}

.auth-footer-right-group { flex-shrink: 0; margin-left: auto; }

.copyright {
  font-size: 0.75rem;
  color: var(--text-muted);
  font-weight: 300;
}



/* ── Responsive ── */
@media (max-width: 1024px) {
  .site-map-newsletter       { padding: 1.25rem 2rem; }
  .site-map-newsletter-inner { flex-direction: column; align-items: flex-start; gap: 1rem; }
  .site-map-newsletter-form  { width: 100%; }
  .site-map-newsletter-input { flex: 1; width: auto; }
  .site-map-inner { grid-template-columns: 1fr 1fr; gap: 2rem; }
  .site-map-col--brand { grid-column: 1 / -1; }
  .home-auth-footer { padding: 0.9rem 2rem; }
}

@media (max-width: 640px) {
  .site-map { padding: 2.5rem 1.25rem; }
  .site-map-newsletter { padding: 1.25rem; }
  .site-map-inner { grid-template-columns: 1fr 1fr; gap: 1.5rem; }
  .site-map-col--brand { grid-column: 1 / -1; }
  /* suggestion 7: Company+Social col spans full width at mobile */
  .site-map-col:last-child { grid-column: 1 / -1; }
  .home-auth-footer { flex-direction: column; gap: 0.6rem; text-align: center; padding: 1rem 1.25rem; }
  .auth-footer-policy-links { margin-left: 0; flex-wrap: wrap; justify-content: center; gap: 0.75rem; }
}

/* ================================================================
   ACCOUNTS — EMPTY STATE
   ================================================================ */
.accounts-empty {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 5rem 2rem;
  max-width: 520px;
  margin: 0 auto;
  gap: 1rem;
}

.accounts-empty-icon {
  width: 80px;
  height: 80px;
  border-radius: var(--radius-xl);
  background: var(--accent-alpha-07);
  border: 1px solid var(--border-accent);
  display: grid;
  place-items: center;
  color: var(--text-accent);
  margin-bottom: 0.5rem;
}

.accounts-empty-title {
  font-size: 1.4rem;
  color: var(--text-heading);
  margin: 0;
}

.accounts-empty-sub {
  font-size: 0.88rem;
  font-weight: 300;
  color: var(--text-secondary);
  line-height: 1.6;
  max-width: 420px;
}

.accounts-empty-actions {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  margin-top: 0.5rem;
  flex-wrap: wrap;
  justify-content: center;
}

.accounts-empty-hint {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 0.78rem;
  color: var(--text-muted);
  background: var(--bg-elevated);
  border: 1px solid var(--border-default);
  border-radius: var(--radius-md);
  padding: 0.5rem 0.9rem;
  margin-top: 0.25rem;
}

/* ================================================================
   REGISTRATION — MODAL-STYLE CARD
   ================================================================ */
.reg-page {
  min-height: 100vh;
  background: var(--bg-void);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1.5rem;
  position: relative;
}

.reg-backdrop {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.65);
  backdrop-filter: blur(3px);
  z-index: 0;
}

/* ════════════════════════════════════════
   Brand-block styling lives in components.css (FDS-3).
   The legacy Theme K override block previously here was deleted
   because its unscoped .brand-name / .brand-tagline selectors were
   overriding components.css globally with wrong colours and fonts.
   ════════════════════════════════════════ */
.reg-card-title {
  font-family: var(--font-display);
}
.reg-card-body .form-input,
.reg-card-body .form-select {
  font-family: var(--font-body);
  background: var(--bg-base);
  border-color: var(--border-default);
}
.reg-card-body .form-input:focus,
.reg-card-body .form-select:focus {
  border-color: var(--text-accent);
  box-shadow: 0 0 0 3px var(--accent-alpha-08);
}
[data-theme="light"] .reg-card-body .form-input,
[data-theme="light"] .reg-card-body .form-select { background: var(--bg-void); }
.reg-card .btn-primary {
  font-family: var(--font-display);
  font-weight: 700;
  letter-spacing: 0.08em;
}

.reg-card {
  position: relative;
  z-index: 1;
  background: var(--bg-surface);
  border: 1px solid var(--border-default);
  border-radius: var(--radius-xl);
  box-shadow: var(--shadow-lg);
  width: 100%;
  max-width: 560px;
  max-height: 92vh;
  display: flex;
  flex-direction: column;
  overflow: hidden;
}

/* Card header */
.reg-card-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1rem 1.4rem;
  border-bottom: 1px solid var(--border-default);
  background: var(--bg-elevated);
  gap: 0.75rem;
  flex-shrink: 0;
  position: relative;
}

.reg-card-brand {
  display: flex;
  align-items: center;
  gap: 8px;
}

.reg-card-title {
  font-family: var(--font-display);
  font-size: 0.82rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--text-muted);
  position: absolute;
  left: 50%;
  transform: translateX(-50%);
  white-space: nowrap;
}

.reg-close {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 28px;
  height: 28px;
  border-radius: var(--radius-md);
  border: 1px solid var(--border-default);
  background: transparent;
  color: var(--text-muted);
  text-decoration: none;
  transition: all 0.15s;
  flex-shrink: 0;
}
.reg-close:hover {
  background: var(--bg-hover);
  color: var(--text-primary);
  border-color: var(--border-strong);
}

/* Scrollable body */
.reg-card-body {
  padding: 1.4rem;
  overflow-y: auto;
  flex: 1;
}

/* Override form spacing inside card */
.reg-card-body .form-group { margin-bottom: 0.75rem; }
.reg-card-body .form-row   { gap: 0.6rem; }
.reg-card-body .form-input,
.reg-card-body .form-select { font-size: 0.85rem; padding: 0.55rem 0.85rem; }

/* Plan row */
.reg-plan-row {
  display: flex;
  gap: 0.5rem;
}

.reg-plan-card {
  flex: 1;
  background: var(--bg-elevated);
  border: 1px solid var(--border-default);
  border-radius: var(--radius-md);
  padding: 0.6rem 0.5rem;
  text-align: center;
  cursor: pointer;
  transition: border-color 0.15s, background 0.15s;
  display: block;
}

.reg-plan-card:hover { border-color: var(--border-strong); }

.reg-plan-card--selected {
  border-color: var(--text-accent);
  background: var(--accent-alpha-05);
}

.reg-plan-name {
  font-family: var(--font-display);
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--text-muted);
  margin-bottom: 0.2rem;
}

.reg-plan-price {
  font-family: var(--font-display);
  font-size: 1.15rem;
  font-weight: 800;
  color: var(--text-heading);
  line-height: 1;
}

.reg-plan-price span {
  font-size: 0.65rem;
  font-weight: 400;
  color: var(--text-muted);
}

/* Responsive */
@media (max-width: 640px) {
  .reg-card { max-width: 100%; border-radius: var(--radius-lg); max-height: 100vh; }
  .reg-page  { padding: 0; align-items: flex-end; }
  .reg-backdrop { display: none; }
}

/* ================================================================
   INACTIVE ACCOUNT MODAL
   ================================================================ */
.inactive-modal-overlay,
.client-edit-modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.72);
  backdrop-filter: blur(4px);
  z-index: 9999;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1.5rem;
}

.inactive-modal,
.client-edit-modal {
  background: var(--bg-surface);
  border: 1px solid var(--border-default);
  border-radius: var(--radius-xl);
  box-shadow: var(--shadow-lg);
  width: 100%;
  max-width: 420px;
  padding: 2rem;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1rem;
  text-align: center;
}

.inactive-modal-icon {
  width: 60px;
  height: 60px;
  border-radius: var(--radius-lg);
  background: rgba(239,68,68,0.1);
  border: 1px solid rgba(239,68,68,0.25);
  display: grid;
  place-items: center;
  color: var(--status-paused);
}

.inactive-modal-title,
.client-edit-modal-title {
  font-size: 1.2rem;
  color: var(--text-heading);
  margin: 0;
}

.inactive-modal-body {
  font-size: 0.85rem;
  font-weight: 300;
  color: var(--text-secondary);
  line-height: 1.7;
  margin: 0;
}

.inactive-modal-link {
  color: var(--text-accent);
  text-decoration: none;
}
.inactive-modal-link:hover { text-decoration: underline; }

.inactive-modal-id {
  font-family: var(--font-mono);
  font-size: 0.82rem;
  color: var(--text-accent);
  background: rgba(201,163,110,0.08);
  padding: 1px 6px;
  border-radius: var(--radius-sm);
}

/* ================================================================
   ACCOUNT STATUS BADGES
   ================================================================ */
/* Shared width so all status badges are uniform */
.badge-status-enquiry,
.badge-status-followup,
.badge-status-onhold,
.badge-status-onboarding,
.badge-status-active,
.badge-status-suspended,
.badge-status-blacklisted {
  min-width: 96px;
  justify-content: center;
  text-align: center;
}

.badge-status-enquiry    { background: rgba(168,85,247,0.12); color: #C084FC; border: 1px solid rgba(168,85,247,0.28); }
.badge-status-followup   { background: rgba(249,115,22,0.12); color: #FB923C; border: 1px solid rgba(249,115,22,0.28); }
.badge-status-onhold     { background: rgba(236,72,153,0.12); color: #F472B6; border: 1px solid rgba(236,72,153,0.28); }
.badge-status-onboarding { background: rgba(234,179,8,0.12);  color: #FACC15; border: 1px solid rgba(234,179,8,0.28);  }
.badge-status-active     { background: rgba(34,197,94,0.12);  color: #4ADE80; border: 1px solid rgba(34,197,94,0.28);  }
.badge-status-suspended  { background: rgba(239,68,68,0.12);  color: #F87171; border: 1px solid rgba(239,68,68,0.28);  }
.badge-status-blacklisted{ background: rgba(148,163,184,0.12);color: #94A3B8; border: 1px solid rgba(148,163,184,0.28);}

/* ================================================================
   LOGIN PAGE — DESIGN IMPROVEMENTS
   ================================================================ */

/* Header accent line */
.auth-header {
  border-bottom-color: transparent;
  box-shadow: 0 1px 0 var(--border-default), 0 2px 0 var(--accent-alpha-07);
}

/* Left panel eyebrow tag */
.auth-brand-eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-family: var(--font-display);
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--text-accent);
  background: rgba(201,163,110,0.07);
  border: 1px solid var(--accent-alpha-15);
  border-radius: var(--radius-xl);
  padding: 0.3rem 0.75rem;
  margin-bottom: 1.25rem;
}

/* Accent span in h2 */
.auth-brand-accent {
  background: linear-gradient(135deg, var(--text-accent) 0%, var(--accent-alpha-60) 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

/* Sub-headline under h2 */
.auth-brand-sub {
  font-size: 0.88rem !important;
  color: var(--text-muted) !important;
  line-height: 1.6 !important;
  margin-top: 0.25rem !important;
  margin-bottom: 0 !important;
}

/* Form header icon */
.auth-form-header-icon {
  width: 44px;
  height: 44px;
  border-radius: var(--radius-lg);
  background: var(--accent-alpha-08);
  border: 1px solid var(--accent-alpha-15);
  display: grid;
  place-items: center;
  margin: 0 auto 1rem;
}

/* Form box subtle glass border */
.login-form-box {
  border: 1px solid var(--border-default);
  border-radius: var(--radius-xl);
  padding: 2rem;
  background: var(--bg-surface);
  box-shadow: 0 4px 24px rgba(0,0,0,0.12), 0 1px 4px rgba(0,0,0,0.08);
  display: flex;
  flex-direction: column;
  justify-content: center;
  width: 100%;
  max-width: 480px;
  box-sizing: border-box;
}

/* Auth divider — "New to Friskr?" */
.auth-divider {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  margin: 1.25rem 0 0.85rem;
  color: var(--text-muted);
  font-size: 0.75rem;
}
.auth-divider::before,
.auth-divider::after {
  content: '';
  flex: 1;
  height: 1px;
  background: var(--border-default);
}
.auth-divider span { white-space: nowrap; }

/* Stat card delta indicator */
.trend-stat-delta {
  font-size: 0.68rem;
  color: #22C55E;
  display: flex;
  align-items: center;
  gap: 2px;
  margin-top: 2px;
}

/* Trust strip pill style */
.auth-trust-strip {
  background: var(--bg-elevated);
  border: 1px solid var(--border-default);
  border-radius: var(--radius-lg);
  padding: 0.5rem 0.75rem;
  margin-top: 1.25rem;
  flex-shrink: 0;
}

/* Smooth input focus ring */
.login-form-box .form-input:focus {
  border-color: var(--text-accent);
  box-shadow: 0 0 0 3px var(--accent-alpha-10);
  outline: none;
}



/* ================================================================
   REGISTRATION SUCCESS MODAL
   ================================================================ */
.reg-success-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.72);
  backdrop-filter: blur(4px);
  z-index: 9999;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1.5rem;
}

.reg-success-modal {
  position: relative;
  background: var(--bg-surface);
  border: 1px solid var(--border-default);
  border-radius: var(--radius-xl);
  box-shadow: var(--shadow-lg);
  width: 100%;
  max-width: 460px;
  padding: 2rem;
}

.reg-success-close {
  position: absolute;
  top: 1rem;
  right: 1rem;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 28px;
  height: 28px;
  border-radius: var(--radius-md);
  border: 1px solid var(--border-default);
  background: transparent;
  color: var(--text-muted);
  cursor: pointer;
  transition: all 0.15s;
}

.reg-success-close:hover {
  background: var(--bg-hover);
  color: var(--text-primary);
  border-color: var(--border-strong);
}

/* ================================================================
   TOPBAR USER DROPDOWN MENU
   ================================================================ */
.topbar-user-chip {
  position: relative;
  user-select: none;
}

.topbar-user-menu {
  display: none;
  position: fixed;
  top: var(--nav-h);
  right: 1.5rem;
  background: var(--bg-surface);
  border: 1px solid var(--border-default);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-lg);
  min-width: 200px;
  z-index: 9500;
  padding: 0.35rem 0;
  overflow: visible;
}

.topbar-user-menu.open { display: block; }

.topbar-menu-item {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  padding: 0.55rem 1rem;
  font-size: 0.84rem;
  font-weight: 500;
  letter-spacing: 0.01em;
  color: var(--text-secondary);
  text-decoration: none;
  cursor: pointer;
  transition: background 0.12s, color 0.12s;
  position: relative;
  white-space: nowrap;
}

.topbar-menu-item:hover {
  background: var(--bg-hover);
  color: var(--text-primary);
}

.topbar-menu-item--danger { color: var(--status-paused); }
.topbar-menu-item--danger:hover { background: rgba(239,68,68,0.08); color: #F87171; }
.topbar-menu-item--active { background: var(--accent-alpha-08); color: var(--text-accent); }

.topbar-menu-divider {
  height: 1px;
  background: var(--border-default);
  margin: 0.3rem 0;
}

/* Switch Access sub-menu */
.topbar-menu-item--has-sub { cursor: pointer; }

.topbar-sub-menu {
  display: none;
  position: fixed;
  background: var(--bg-surface);
  border: 1px solid var(--border-default);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-lg);
  min-width: 220px;
  max-width: 280px;
  max-height: calc(100vh - var(--nav-h) - 1rem);
  overflow-y: auto;
  padding: 0.35rem 0;
  z-index: 9999;
}

.topbar-sub-menu.open { display: block; }

/* ================================================================
   LEGAL PAGES
   ================================================================ */
.legal-wrapper {
  display: grid;
  grid-template-columns: 220px 1fr;
  gap: 3rem;
  max-width: 1100px;
  margin: 0 auto;
  padding: 3rem 2rem 5rem;
  min-height: calc(100vh - 130px);
}

/* Sidebar */
.legal-sidebar {
  position: sticky;
  top: 2rem;
  align-self: start;
}
.legal-sidebar-title {
  font-size: 0.65rem;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--text-muted);
  margin-bottom: 0.75rem;
  padding-bottom: 0.5rem;
  border-bottom: 1px solid var(--border-default);
}
.legal-sidebar-nav {
  display: flex;
  flex-direction: column;
  gap: 0.15rem;
  margin-bottom: 2rem;
}
.legal-sidebar-link {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.45rem 0.65rem;
  font-family: var(--font-body);
  font-size: 0.82rem;
  color: var(--text-secondary);
  border-radius: var(--radius-md);
  text-decoration: none;
  transition: background 0.15s, color 0.15s;
  border-left: 2px solid transparent;
}
.legal-sidebar-link:hover {
  background: var(--bg-hover);
  color: var(--text-primary);
}
.legal-sidebar-link.active {
  background: var(--accent-alpha-08);
  color: var(--text-accent);
  border-left-color: var(--text-accent);
  font-weight: 600;
}
.legal-sidebar-contact {
  padding: 0.75rem;
  background: var(--bg-elevated);
  border: 1px solid var(--border-default);
  border-radius: var(--radius-md);
}

/* Content area */
.legal-content {
  min-width: 0;
  max-width: 740px;
}

/* Header */
.legal-header {
  margin-bottom: 2.5rem;
  padding-bottom: 2rem;
  border-bottom: 1px solid var(--border-default);
}
.legal-label {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  font-size: 0.67rem;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--text-accent);
  background: var(--accent-alpha-07);
  border: 1px solid var(--accent-alpha-18);
  border-radius: 999px;
  padding: 0.2rem 0.65rem;
  margin-bottom: 0.85rem;
}
.legal-title {
  font-family: var(--font-display);
  font-size: 2rem;
  font-weight: 700;
  letter-spacing: -0.02em;
  color: var(--text-heading);
  margin-bottom: 0.5rem;
  line-height: 1.15;
}
.legal-meta {
  font-size: 0.8rem;
  color: var(--text-muted);
  font-family: var(--font-mono);
  margin-bottom: 1.25rem;
}
.legal-intro {
  font-size: 0.95rem;
  color: var(--text-secondary);
  line-height: 1.75;
}

/* Table of contents */
.legal-toc {
  background: var(--bg-elevated);
  border: 1px solid var(--border-default);
  border-radius: var(--radius-lg);
  padding: 1.25rem 1.5rem;
  margin-bottom: 2.5rem;
}
.legal-toc-title {
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--text-muted);
  margin-bottom: 0.75rem;
}
.legal-toc-list {
  list-style: decimal;
  padding-left: 1.25rem;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.3rem 2rem;
}
.legal-toc-list li { font-size: 0.83rem; }
.legal-toc-list a {
  color: var(--text-secondary);
  text-decoration: none;
  transition: color 0.15s;
}
.legal-toc-list a:hover { color: var(--text-accent); }

/* Sections */
.legal-section {
  margin-bottom: 2.75rem;
  padding-bottom: 2.75rem;
  border-bottom: 1px solid var(--border-subtle);
}
.legal-section:last-child { border-bottom: none; }
.legal-section h2 {
  font-size: 1.25rem;
  font-weight: 700;
  color: var(--text-heading);
  margin-bottom: 0.85rem;
  padding-bottom: 0.6rem;
  border-bottom: 1px solid var(--border-default);
  letter-spacing: -0.01em;
}
.legal-section h3 {
  font-size: 0.95rem;
  font-weight: 700;
  color: var(--text-primary);
  margin: 1.25rem 0 0.5rem;
}
.legal-section p {
  font-size: 0.88rem;
  color: var(--text-secondary);
  line-height: 1.8;
  margin-bottom: 0.85rem;
}
.legal-section p:last-child { margin-bottom: 0; }
.legal-section ul, .legal-section ol {
  padding-left: 1.4rem;
  margin-bottom: 0.85rem;
}
.legal-section li {
  font-size: 0.88rem;
  color: var(--text-secondary);
  line-height: 1.75;
  margin-bottom: 0.35rem;
}
.legal-section a {
  color: var(--text-accent);
  text-decoration: none;
}
.legal-section a:hover { text-decoration: underline; }
.legal-section code {
  font-family: var(--font-mono);
  font-size: 0.8rem;
  background: var(--bg-elevated);
  border: 1px solid var(--border-default);
  padding: 0.1em 0.4em;
  border-radius: 3px;
  color: var(--blue-200);
}

/* Contact block */
.legal-contact-block {
  background: var(--bg-elevated);
  border: 1px solid var(--border-default);
  border-left: 3px solid var(--text-accent);
  border-radius: var(--radius-md);
  padding: 1rem 1.25rem;
  margin: 1rem 0;
}
.legal-contact-block p {
  margin: 0;
  line-height: 1.75;
}

/* Tables */
.legal-table-wrap {
  overflow-x: auto;
  margin: 1rem 0;
  border-radius: var(--radius-md);
  border: 1px solid var(--border-default);
}
.legal-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.82rem;
}
.legal-table th {
  background: var(--bg-elevated);
  padding: 0.6rem 0.85rem;
  text-align: left;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--text-muted);
  border-bottom: 1px solid var(--border-default);
}
.legal-table td {
  padding: 0.65rem 0.85rem;
  color: var(--text-secondary);
  border-bottom: 1px solid var(--border-subtle);
  line-height: 1.6;
  vertical-align: top;
}
.legal-table tr:last-child td { border-bottom: none; }

/* Mobile */
@media (max-width: 768px) {
  .legal-wrapper { grid-template-columns: 1fr; gap: 1.5rem; padding: 1.5rem 1rem; }
  .legal-sidebar { position: static; }
  .legal-toc-list { grid-template-columns: 1fr; }
  .legal-title { font-size: 1.5rem; }
}

/* ================================================================
   ACCOUNT REGISTRY — RESPONSIVE
   ================================================================ */

/* Both hidden by default — JS applies correct view on load */
.accreg-table-wrap { display: none; }
.accreg-cards      { display: none; }

/* ── View toggle button group ── */
.accreg-view-toggle {
  display: flex;
  align-items: center;
  background: var(--bg-elevated);
  border: 1px solid var(--border-default);
  border-radius: var(--radius-md);
  padding: 2px;
  gap: 2px;
}
.accreg-view-btn {
  display: grid;
  place-items: center;
  width: 28px;
  height: 26px;
  border-radius: calc(var(--radius-md) - 2px);
  border: none;
  background: transparent;
  color: var(--text-muted);
  cursor: pointer;
  transition: background 0.15s, color 0.15s;
}
.accreg-view-btn:hover { background: var(--bg-hover); color: var(--text-primary); }
.accreg-view-btn--active { background: var(--bg-surface); color: var(--text-accent); box-shadow: var(--shadow-sm); }

/* ── Account card grid wrapper ── */
.accreg-cards {
  display: none;
  padding: 1.25rem;
  gap: 1rem;
  flex-direction: column;
}

.accreg-card {
  background: var(--bg-elevated);
  border: 1px solid var(--border-default);
  border-radius: var(--radius-lg);
  border-left: 3px solid var(--text-accent);
  padding: 1.1rem 1.25rem;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  transition: border-color 0.18s, box-shadow 0.18s;
}
.accreg-card:hover {
  border-color: var(--border-accent);
  box-shadow: var(--shadow-md);
}

/* Accent colour by status via data attribute */
.accreg-card[data-status="Active"]      { border-left-color: #22C55E; }
.accreg-card[data-status="Enquiry"]     { border-left-color: var(--text-accent); }
.accreg-card[data-status="Follow up"]   { border-left-color: #F59E0B; }
.accreg-card[data-status="On hold"]     { border-left-color: #94A3B8; }
.accreg-card[data-status="Onboarding"] { border-left-color: #A855F7; }
.accreg-card[data-status="Suspended"]  { border-left-color: #EF4444; }
.accreg-card[data-status="Black-listed"]{ border-left-color: #7F1D1D; }

.accreg-card-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.6rem;
}
.accreg-card-name {
  font-size: 1rem;
  font-weight: 700;
  color: var(--text-heading);
  line-height: 1.2;
  flex: 1;
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.accreg-card-header-right {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  flex-shrink: 0;
}

/* ID chips row */
.accreg-card-ids {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
  padding-bottom: 0.65rem;
  border-bottom: 1px solid var(--border-subtle);
}
.accreg-id-chip {
  font-family: var(--font-mono);
  font-size: 0.65rem;
  font-weight: 600;
  padding: 0.15rem 0.55rem;
  border-radius: 999px;
  border: 1px solid transparent;
  letter-spacing: 0.04em;
}
.accreg-id-chip--enq { background: var(--accent-alpha-08);  border-color: var(--accent-alpha-20);  color: var(--text-accent); }
.accreg-id-chip--pri { background: rgba(148,163,184,0.07); border-color: rgba(148,163,184,0.18); color: var(--text-secondary); }
.accreg-id-chip--adm { background: rgba(192,132,252,0.08); border-color: rgba(192,132,252,0.22); color: #C084FC; }

/* 2-col field grid */
.accreg-card-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.75rem 1.25rem;
}
.accreg-field--wide { grid-column: 1 / -1; }

.accreg-field-label {
  font-size: 0.62rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--text-muted);
  margin-bottom: 0.2rem;
}
.accreg-field-value {
  font-size: 0.85rem;
  color: var(--text-primary);
  line-height: 1.3;
}
.accreg-field-value.mono { font-family: var(--font-mono); font-size: 0.75rem; color: var(--blue-200); }
.accreg-field-sub {
  font-size: 0.75rem;
  color: var(--text-muted);
  margin-top: 0.15rem;
}

/* ── Vendor Edit Modal ── */
.vendor-edit-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.72);
  backdrop-filter: blur(4px);
  z-index: 9999;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1.5rem;
}
.vendor-edit-modal {
  background: var(--bg-surface);
  border: 1px solid var(--border-default);
  border-radius: var(--radius-xl);
  box-shadow: var(--shadow-lg);
  width: 100%;
  max-width: 520px;
  display: flex;
  flex-direction: column;
  gap: 0;
  text-align: left;
  max-height: 90vh;
  overflow-y: auto;
}
.vendor-edit-modal-title {
  font-size: 1rem;
  font-weight: 700;
  color: var(--text-heading);
  margin: 0;
}


/* ================================================================
   SIDEBAR COLLAPSE MODE
   Triggered by [data-sidebar="collapsed"] on <html>
   ================================================================ */
[data-sidebar="collapsed"] {
  --sidebar-w: 64px;
}

[data-sidebar="collapsed"] .sidebar {
  overflow: visible;
}

[data-sidebar="collapsed"] .sidebar-logo-text,
[data-sidebar="collapsed"] .sidebar-logo-text + *,
[data-sidebar="collapsed"] .user-info,
[data-sidebar="collapsed"] .user-card-type,
[data-sidebar="collapsed"] .nav-section {
  display: none !important;
}

[data-sidebar="collapsed"] .nav-link {
  justify-content: center;
  padding: 0.65rem;
  gap: 0;
}

[data-sidebar="collapsed"] .nav-link span,
[data-sidebar="collapsed"] .nav-link > *:not(i):not(svg) {
  display: none !important;
}

[data-sidebar="collapsed"] .nav-link i,
[data-sidebar="collapsed"] .nav-link svg {
  width: 18px !important;
  height: 18px !important;
  margin: 0 !important;
}

/* Tooltip on hover for collapsed nav links */
[data-sidebar="collapsed"] .nav-link {
  position: relative;
}

[data-sidebar="collapsed"] .nav-link::after {
  content: attr(data-label);
  position: absolute;
  left: calc(100% + 12px);
  top: 50%;
  transform: translateY(-50%);
  background: var(--bg-surface);
  border: 1px solid var(--border-default);
  border-radius: var(--radius-md);
  padding: 0.3rem 0.65rem;
  font-size: 0.78rem;
  color: var(--text-primary);
  white-space: nowrap;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.15s;
  box-shadow: var(--shadow-md);
  z-index: 200;
}

[data-sidebar="collapsed"] .nav-link:hover::after {
  opacity: 1;
}

[data-sidebar="collapsed"] .sidebar > .reg-card-brand {
  padding: 0;
  justify-content: center;
}

[data-sidebar="collapsed"] .sidebar-logo-icon {
  margin: 0;
}

[data-sidebar="collapsed"] .sidebar-footer {
  padding: 0.5rem 0;
  display: flex;
  justify-content: center;
}

[data-sidebar="collapsed"] .user-card {
  padding: 0.4rem;
  justify-content: center;
}

[data-sidebar="collapsed"] .user-card-top {
  justify-content: center;
}

[data-sidebar="collapsed"] .user-avatar {
  margin: 0;
}

[data-sidebar="collapsed"] .sidebar-mobile-close {
  display: none !important;
}

/* Smooth width transition for collapse (desktop only — mobile uses transform) */
@media (min-width: 901px) {
  .sidebar {
    transition: width 0.22s ease, transform 0.22s ease;
  }
  .main-content {
    transition: margin-left 0.22s ease, width 0.22s ease, max-width 0.22s ease;
  }
}

/* On mobile, sidebar collapse is disabled — never apply collapsed state */
@media (max-width: 900px) {
  [data-sidebar="collapsed"] {
    --sidebar-w: 240px;
  }
  [data-sidebar="collapsed"] .sidebar {
    overflow: hidden;
  }
  [data-sidebar="collapsed"] .sidebar-logo-text,
  [data-sidebar="collapsed"] .sidebar-logo-text + *,
  [data-sidebar="collapsed"] .user-info,
  [data-sidebar="collapsed"] .user-card-type,
  [data-sidebar="collapsed"] .nav-section,
  [data-sidebar="collapsed"] .nav-link span,
  [data-sidebar="collapsed"] .nav-link > *:not(i):not(svg) {
    display: revert !important;
  }
  [data-sidebar="collapsed"] .nav-link {
    justify-content: flex-start;
    padding: 0.6rem 1.2rem;
    gap: 0.6rem;
  }
  [data-sidebar="collapsed"] .nav-link i,
  [data-sidebar="collapsed"] .nav-link svg {
    width: 16px !important;
    height: 16px !important;
  }
  /* Hide the collapse button on mobile — irrelevant there */
  #sidebar-collapse-btn {
    display: none !important;
  }
}

/* ── Dashboard mobile responsive (#12) ─────────────────────── */
@media (max-width: 900px) {
  .dashboard-cols {
    grid-template-columns: 1fr !important;
  }
}
@media (max-width: 600px) {
  .grid.grid-4 {
    grid-template-columns: 1fr 1fr !important;
  }
  .metric-card.col-span-2 {
    grid-column: span 2 !important;
  }
  .metric-value {
    font-size: 1.6rem !important;
  }
  .metric-delta {
    flex-wrap: wrap;
    gap: 0.2rem;
  }
}
@media (max-width: 400px) {
  .grid.grid-4 {
    grid-template-columns: 1fr !important;
  }
  .metric-card.col-span-2 {
    grid-column: span 1 !important;
  }
}

/* ── Wizard calendar picker ─────────────────────────────── */
.wiz-cal-trigger:hover {
  border-color: var(--border-accent) !important;
  background: var(--bg-hover);
}
.wiz-cal-trigger:focus-within {
  border-color: var(--text-accent) !important;
  box-shadow: 0 0 0 2px rgba(99,102,241,0.18);
}
.wiz-cal-wrap {
  position: relative;
}
#wiz-cal-popup {
  position: absolute;
  animation: wiz-cal-in 0.12s ease;
}
@keyframes wiz-cal-in {
  from { opacity: 0; transform: translateY(-6px); }
  to   { opacity: 1; transform: translateY(0); }
}

.wiz-cal-day:hover {
  background: var(--bg-hover) !important;
}


/* ══════════════════════════════════════════════════════════
   SCREENER QUESTION BUILDER — shared across screeners page
   and Quick Setup wizard Screen step
   ══════════════════════════════════════════════════════════ */
.sb-tab-pill{display:inline-flex;align-items:center;gap:5px;padding:0.3rem 0.75rem;border-radius:calc(var(--radius-md) - 2px);border:none;background:transparent;color:var(--text-muted);font-size:0.78rem;font-weight:500;cursor:pointer;transition:background .15s,color .15s;white-space:nowrap}
.sb-tab-pill:hover{background:var(--bg-hover);color:var(--text-secondary)}
.sb-tab-pill.active{background:var(--bg-surface);color:var(--text-heading);box-shadow:0 1px 3px rgba(0,0,0,.3)}
.qlist{display:flex;flex-direction:column;gap:0.6rem;min-height:20px}
.qcard{border:1px solid var(--border-default);border-radius:var(--radius-md);background:var(--bg-overlay);transition:box-shadow .15s,border-color .15s,opacity .15s,transform .15s;user-select:none}
.qcard:hover{border-color:var(--border-strong)}
.qcard.dragging{opacity:.4;transform:scale(.98)}
.qcard.drag-over{border-color:var(--text-accent);box-shadow:0 0 0 2px var(--accent-alpha-20)}
.qcard-header{display:flex;align-items:center;gap:0.55rem;padding:0.7rem 0.9rem 0.5rem;cursor:default}
.qcard-drag-handle{cursor:grab;color:var(--text-muted);display:flex;align-items:center;padding:0.35rem 0.25rem;border-radius:3px;transition:color .12s,background .12s;flex-shrink:0;touch-action:none;user-select:none;-webkit-user-select:none}
.qcard-drag-handle:hover{color:var(--text-secondary);background:var(--bg-hover)}
.qcard-drag-handle:active{cursor:grabbing}
.qcard-num{font-size:0.7rem;font-weight:700;color:var(--text-muted);background:var(--bg-surface);border:1px solid var(--border-default);border-radius:4px;padding:0.1rem 0.4rem;flex-shrink:0;min-width:26px;text-align:center}
.qtype-select{font-size:0.78rem;padding:0.25rem 0.5rem;height:28px;border-radius:5px;border:1px solid var(--border-default);background:var(--bg-surface);color:var(--text-secondary);cursor:pointer;outline:none;transition:border-color .15s}
.qtype-select:focus{border-color:var(--text-accent)}
.qualifying-toggle{display:flex;align-items:center;gap:5px;font-size:0.75rem;color:var(--text-muted);cursor:pointer;margin-left:auto}
.qualifying-toggle input[type=checkbox]{width:14px;height:14px;accent-color:var(--text-accent);cursor:pointer}
.qualifying-toggle.active{color:#22C55E}
.qcard-body{padding:0 0.9rem 0.9rem;display:flex;flex-direction:column;gap:0.5rem}
.qcard-delete-btn{display:flex;align-items:center;justify-content:center;width:26px;height:26px;border-radius:5px;border:1px solid transparent;background:transparent;color:var(--text-muted);cursor:pointer;transition:all .12s;flex-shrink:0}
.qcard-delete-btn:hover{background:rgba(239,68,68,.1);border-color:rgba(239,68,68,.2);color:#F87171}
.opt-row{display:flex;align-items:center;gap:0.4rem}
.opt-bullet{width:16px;height:16px;border-radius:50%;border:2px solid var(--border-strong);flex-shrink:0;background:transparent}
.opt-bullet.multi{border-radius:3px}
.opt-del-btn{display:flex;align-items:center;justify-content:center;width:22px;height:22px;border-radius:4px;border:none;background:transparent;color:var(--text-muted);cursor:pointer;transition:all .12s;flex-shrink:0}
.opt-del-btn:hover{background:rgba(239,68,68,.08);color:#F87171}
.add-opt-btn{display:inline-flex;align-items:center;gap:0.3rem;font-size:0.76rem;color:var(--text-accent);background:transparent;border:1px dashed var(--accent-alpha-25);border-radius:5px;padding:0.3rem 0.6rem;cursor:pointer;transition:all .12s;align-self:flex-start}
.add-opt-btn:hover{background:var(--accent-alpha-06);border-color:var(--text-accent)}
.pv-card{background:var(--bg-surface);border:1px solid var(--border-default);border-radius:var(--radius-lg);box-shadow:var(--shadow-lg);padding:1.5rem;width:100%;box-sizing:border-box}
.pv-progress-bar{height:3px;background:var(--border-default);border-radius:2px;margin-bottom:0.75rem;overflow:hidden}
.pv-progress-fill{height:100%;background:var(--text-accent);border-radius:2px;transition:width .4s}
.pv-question-num{font-size:0.7rem;color:var(--text-accent);font-weight:600;letter-spacing:0.08em;text-transform:uppercase;margin-bottom:0.4rem}
.pv-question-text{font-size:1rem;font-weight:600;color:var(--text-heading);line-height:1.45;margin-bottom:1rem}
.pv-option{display:flex;align-items:center;gap:0.6rem;padding:0.55rem 0.75rem;border-radius:var(--radius-md);border:1px solid var(--border-default);margin-bottom:0.45rem;cursor:pointer;transition:all .15s;font-size:0.88rem;color:var(--text-secondary)}
.pv-option:hover{background:var(--bg-hover);border-color:var(--border-strong);color:var(--text-primary)}
.pv-option.selected{background:var(--accent-alpha-08);border-color:var(--text-accent);color:var(--text-heading)}
.pv-option-bullet{width:16px;height:16px;border-radius:50%;border:2px solid var(--border-strong);flex-shrink:0;transition:all .15s}
.pv-option-bullet.multi{border-radius:4px}
.pv-option.selected .pv-option-bullet{background:var(--text-accent);border-color:var(--text-accent)}
.pv-text-input{width:100%;box-sizing:border-box;padding:0.6rem 0.75rem;font-size:0.88rem;color:var(--text-primary);background:var(--bg-overlay);border:1px solid var(--border-default);border-radius:var(--radius-md);outline:none;transition:border-color .15s}
.pv-text-input:focus{border-color:var(--text-accent)}
.pv-nav{display:flex;justify-content:space-between;align-items:center;margin-top:1.25rem;padding-top:0.75rem;border-top:1px solid var(--border-subtle)}
.pv-btn{padding:0.55rem 1.25rem;border-radius:var(--radius-md);border:none;font-size:0.85rem;font-weight:600;cursor:pointer;transition:all .15s}
.pv-btn-primary{background:var(--text-accent);color:#0F0E0C}
.pv-btn-secondary{background:transparent;border:1px solid var(--border-default);color:var(--text-secondary)}
.pv-btn-primary:hover{opacity:.88}
.pv-btn-secondary:hover{background:var(--bg-hover)}
.pv-empty{text-align:center;padding:2.5rem 1rem;color:var(--text-muted);font-size:0.85rem}
.pv-end-screen{text-align:center;padding:1.5rem 0}
.pv-end-icon{font-size:2.5rem;margin-bottom:0.75rem}
.pv-end-title{font-size:1.05rem;font-weight:700;color:var(--text-heading);margin-bottom:0.5rem}
.pv-end-body{font-size:0.85rem;color:var(--text-secondary)}
.pv-device-btn{display:flex;align-items:center;justify-content:center;width:26px;height:26px;border-radius:5px;border:1px solid var(--border-default);background:transparent;color:var(--text-muted);cursor:pointer;transition:all .12s}
.pv-device-btn:hover,.pv-device-btn.active{background:var(--bg-surface);color:var(--text-primary);border-color:var(--border-strong)}
.pv-nav-btn{width:26px;height:26px;border-radius:5px;border:1px solid var(--border-default);background:transparent;color:var(--text-secondary);cursor:pointer;font-size:0.9rem;transition:all .12s;display:flex;align-items:center;justify-content:center}
.pv-nav-btn:hover:not([disabled]){background:var(--bg-hover);color:var(--text-primary)}
.pv-nav-btn[disabled]{opacity:.3;cursor:default}
.pv-step-dot{width:6px;height:6px;border-radius:50%;background:var(--border-strong);transition:background .2s,width .2s;cursor:pointer}
.pv-step-dot.active{background:var(--text-accent);width:18px;border-radius:3px}
.qlist-drop-placeholder{min-height:48px;border:2px dashed var(--accent-alpha-40);border-radius:var(--radius-md);background:var(--accent-alpha-06);pointer-events:none;transition:height .1s}
/* Survey features panel */
.sfp-type-btn{display:flex;flex-direction:column;align-items:center;gap:0.3rem;padding:0.6rem 0.35rem;border:1px solid var(--border-default);border-radius:var(--radius-md);background:var(--bg-overlay);cursor:pointer;transition:all .15s;text-align:center}
.sfp-type-btn:hover{background:var(--bg-hover);border-color:var(--border-strong)}
.sfp-type-icon{width:32px;height:32px;border-radius:var(--radius-md);display:flex;align-items:center;justify-content:center;flex-shrink:0}
.sfp-type-label{font-size:0.72rem;font-weight:700;color:var(--text-primary)}
.sfp-type-desc{font-size:0.64rem;color:var(--text-muted);line-height:1.2}
.sfp-stat-row{display:flex;align-items:center;justify-content:space-between;font-size:0.78rem}
.sfp-stat-label{color:var(--text-muted)}
.sfp-stat-val{font-weight:700;color:var(--text-heading);font-family:var(--font-mono);font-size:0.8rem}
/* Selected question highlight */
.qcard--selected{border-color:var(--text-accent)!important;box-shadow:0 0 0 2px var(--accent-alpha-15)}
.skip-rule-row{background:var(--bg-overlay);border:1px solid var(--border-default);border-radius:var(--radius-md);padding:0.6rem 0.7rem;transition:border-color .15s}
.skip-rule-row:hover{border-color:var(--border-strong)}
.qcard-skip-badge{display:inline-flex;align-items:center;font-size:0.65rem;font-weight:700;color:var(--text-accent);background:var(--accent-alpha-10);border:1px solid var(--accent-alpha-20);border-radius:999px;padding:1px 7px;margin-left:auto;letter-spacing:0.03em;flex-shrink:0}
/* Responsive: collapse features panel below 900px */
@media(max-width:900px){
  /* Screener builder mobile layout */
  #sbp-questions > div{grid-template-columns:1fr!important}
  #survey-features-panel{position:static!important}
  /* Questions tab: collapse features panel into accordion on mobile */
  #survey-features-panel .card{margin-bottom:0.5rem}
  /* Larger touch targets for question cards */
  .qcard-drag-handle{padding:0.6rem 0.4rem!important}
  .qcard-delete-btn{width:36px!important;height:36px!important}
  .qtype-select{height:36px!important;font-size:0.85rem!important}
  /* Skip logic rows stack vertically */
  .skip-rule-row{font-size:0.8rem}
  /* Type buttons bigger on mobile */
  .sfp-type-btn{padding:0.75rem 0.4rem!important}
  .sfp-type-icon{width:36px!important;height:36px!important}
  /* Controls tab: single column */
  #friskr-modules > div{grid-template-columns:1fr!important}
  /* Drawer tabs scrollable */
  .sb-tab-pill{padding:0.35rem 0.6rem!important;font-size:0.75rem!important}
}
@media(max-width:600px){
  /* Very small screens: builder toolbar wraps */
  #sb-body{gap:0.75rem!important}
  .qcard-header{flex-wrap:wrap;gap:0.35rem}
  .qualifying-toggle{width:100%;margin-left:0!important}
}
/* ── Controls tab ── */
.ctrl-row{display:flex;align-items:flex-start;justify-content:space-between;gap:1.5rem;padding:0.85rem 0}
.ctrl-row-left{flex:1;min-width:0}
.ctrl-label{font-size:0.88rem;font-weight:600;color:var(--text-heading);display:flex;align-items:center;gap:0.5rem;margin-bottom:0.2rem}
.ctrl-desc{font-size:0.78rem;font-weight:300;color:var(--text-muted);line-height:1.6}
.ctrl-divider{height:1px;background:var(--border-subtle);margin:0.1rem 0}
.ctrl-status-text{font-size:0.75rem;font-weight:700;letter-spacing:0.04em;min-width:52px;text-align:right;transition:color .2s}
.ctrl-status-text--on{color:#22C55E}
.ctrl-status-text--off{color:#EF4444}
.ctrl-badge{display:inline-flex;align-items:center;padding:1px 7px;border-radius:999px;font-size:0.65rem;font-weight:700;letter-spacing:0.05em;background:var(--accent-alpha-12);color:var(--text-accent);border:1px solid var(--accent-alpha-20)}
.ctrl-badge--purple{background:rgba(168,85,247,0.1);color:#A855F7;border-color:rgba(168,85,247,0.25)}
/* Toggle switch */
.ctrl-toggle{position:relative;display:inline-flex;align-items:center;cursor:pointer;flex-shrink:0}
.ctrl-toggle input{position:absolute;opacity:0;width:0;height:0}
.ctrl-toggle-track{display:inline-block;width:40px;height:22px;background:var(--border-strong);border-radius:11px;transition:background .2s;position:relative;flex-shrink:0}
.ctrl-toggle input:checked ~ .ctrl-toggle-track{background:var(--text-accent)}
/* Status toggles: green on, red off */
.ctrl-toggle--status .ctrl-toggle-track{background:#EF4444}
.ctrl-toggle--status input:checked ~ .ctrl-toggle-track{background:#22C55E}
.ctrl-toggle-thumb{position:absolute;top:3px;left:3px;width:16px;height:16px;background:#fff;border-radius:50%;transition:left .2s;box-shadow:0 1px 3px rgba(0,0,0,.35)}
.ctrl-toggle input:checked ~ .ctrl-toggle-track .ctrl-toggle-thumb{left:21px}
.ctrl-toggle--sm .ctrl-toggle-track{width:32px;height:18px;border-radius:9px}
.ctrl-toggle--sm .ctrl-toggle-thumb{width:12px;height:12px;top:3px;left:3px}
.ctrl-toggle--sm input:checked ~ .ctrl-toggle-track .ctrl-toggle-thumb{left:17px}
/* Friskr modules grid */
.ctrl-module{background:var(--bg-raised,var(--bg-overlay));border:1px solid var(--border-default);border-radius:var(--radius-md);padding:0.85rem 1rem;transition:border-color .15s}
.ctrl-module:hover{border-color:var(--border-strong)}
.ctrl-module-name{font-size:0.83rem;font-weight:700;color:var(--text-heading);margin-bottom:0.3rem}
.ctrl-module-name sup{font-size:0.55em;vertical-align:super;font-weight:600;opacity:0.7}
.ctrl-module-desc{font-size:0.75rem;font-weight:300;color:var(--text-muted);line-height:1.6}


/* ── Wizard Expanding Cards ──────────────────────────────────── */
.wiz-exp-card{border:1px solid var(--border-default);border-radius:10px;overflow:hidden;transition:border-color 0.2s}
.wiz-exp-card.open{border-color:var(--accent-alpha-35);box-shadow:0 0 0 1px var(--accent-alpha-08)}
.wiz-exp-header{display:flex;align-items:center;gap:0.7rem;padding:0.8rem 1rem;cursor:pointer;user-select:none;background:var(--bg-overlay);transition:background 0.15s}
.wiz-exp-header:hover{background:var(--bg-surface)}
/* Toggle-only headers (Risk Detection, Face Detection) — no pointer/hover */
.wiz-exp-header[style*="cursor:default"]{cursor:default!important}
.wiz-exp-header[style*="cursor:default"]:hover{background:var(--bg-overlay)!important}
.wiz-exp-card.open .wiz-exp-header{border-bottom:1px solid var(--border-default)}
.wiz-exp-icon{width:30px;height:30px;border-radius:7px;display:flex;align-items:center;justify-content:center;flex-shrink:0}
.wiz-exp-title{font-size:0.86rem;font-weight:700;color:var(--text-heading);display:flex;align-items:center;gap:0.4rem}
.wiz-exp-sub{font-size:0.7rem;color:var(--text-muted);margin-top:1px}
.wiz-exp-chevron{width:16px;height:16px;color:var(--text-muted);flex-shrink:0;transition:transform 0.2s,color 0.2s}
.wiz-exp-card.open .wiz-exp-chevron{transform:rotate(180deg);color:var(--text-accent)}
.wiz-exp-body{padding:1rem;background:var(--bg-surface);animation:wizExpSlide 0.15s ease}
@keyframes wizExpSlide{from{opacity:0;transform:translateY(-4px)}to{opacity:1;transform:translateY(0)}}
.wiz-sum-chip{font-size:0.67rem;font-weight:600;padding:2px 8px;border-radius:999px;background:var(--bg-overlay);border:1px solid var(--border-default);color:var(--text-muted)}
.wiz-sum-accent{background:var(--accent-alpha-10);border-color:var(--accent-alpha-25);color:var(--text-accent)}
.wiz-sum-green{background:rgba(34,197,94,0.08);border-color:rgba(34,197,94,0.2);color:#22C55E}
.wiz-sum-purple{background:rgba(168,85,247,0.1);border-color:rgba(168,85,247,0.25);color:#A855F7}
.wiz-cfg-cr-pill{font-size:0.68rem;font-weight:600;padding:3px 9px;border-radius:999px;background:var(--bg-overlay);border:1px solid var(--border-default);color:var(--text-muted);transition:all 0.15s}
.wiz-cfg-cr-pill.active{background:var(--accent-alpha-10);border-color:var(--accent-alpha-25);color:var(--text-accent)}

/* ── Risk Module Cards (2-col grid inside Risk Detection body) ── */
#wiz-fd-modules2{display:grid;grid-template-columns:1fr 1fr;gap:0.5rem}
#wiz-fd-modules2 > div:hover{border-color:rgba(239,68,68,0.45)!important}

/* ── Wizard Credits Grid Cells ── */
.wiz-cr-cell{display:flex;flex-direction:column;align-items:center;padding:0.4rem 0.3rem;background:var(--bg-surface);border:1px solid var(--border-default);border-radius:7px;transition:all 0.15s;text-align:center}
.wiz-cr-cell.active{background:var(--accent-alpha-08);border-color:var(--accent-alpha-30)}
.wiz-cr-name{font-size:0.62rem;font-weight:600;color:var(--text-muted);text-transform:uppercase;letter-spacing:0.04em;margin-bottom:2px;line-height:1.2;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;max-width:100%}
.wiz-cr-val{font-size:1rem;font-weight:800;color:var(--text-muted);font-family:var(--font-mono);line-height:1}
.wiz-cr-cell.active .wiz-cr-name{color:var(--text-accent)}
.wiz-cr-cell.active .wiz-cr-val{color:var(--text-accent)}



/* ══════════════════════════════════════════════════════════════
   ARC (O) — Project Card Design (Session 18 rev)
   Left panel: 148px SVG arc score widget + 2-col module legend.
   Right panel: badge row, project name, meta line, 2×4 stat grid,
   progress bar, footer. Status colour via CSS var --sc.
   ══════════════════════════════════════════════════════════════ */

/* ── Card shell ── */
.project-card {
  background: var(--bg-surface);
  border: 1px solid var(--border-default);
  border-radius: var(--radius-lg);
  overflow: hidden;
  transition: box-shadow 0.2s, transform 0.18s, border-color 0.2s;
}
.project-card:hover {
  box-shadow: 0 8px 32px rgba(0,0,0,0.22);
  transform: translateY(-2px);
  border-color: var(--border-strong);
}

/* ── Left panel — exact Arc (O) spec ── */
.co-left {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: .85rem .65rem;
  background: var(--bg-elevated);
  border-right: 2px solid var(--sc, #22C55E);
  gap: .5rem;
}

/* ── Arc widget ── */
.co-arc-wrap {
  position: relative;
  width: 108px;
  height: 108px;
  flex-shrink: 0;
}
.co-arc-wrap svg { width: 108px; height: 108px; display: block; }
.co-arc-inner {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: .05rem;
  pointer-events: none;
}
.co-arc-eyebrow {
  font-size: .62rem;
  font-weight: 700;
  letter-spacing: .14em;
  text-transform: uppercase;
  color: var(--text-muted);
}
.co-arc-num {
  font-family: var(--font-mono);
  font-size: 1.65rem;
  font-weight: 700;
  line-height: 1;
  letter-spacing: -.04em;
}
.co-arc-grade {
  font-size: .65rem;
  font-weight: 700;
  letter-spacing: .1em;
  text-transform: uppercase;
}

/* ── Module dot legend (2 col grid below arc) ── */
.co-legend {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: .2rem .35rem;
  width: 100%;
}
.co-leg-item {
  display: flex;
  align-items: center;
  gap: .25rem;
}
.co-leg-dot {
  width: 5px;
  height: 5px;
  border-radius: 50%;
  flex-shrink: 0;
}
.co-leg-name {
  font-size: .62rem;
  color: var(--text-secondary);
  font-weight: 500;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  flex: 1;
}
.co-leg-item--on .co-leg-name { color: var(--text-primary); }
.co-leg-item--off { opacity: .28; }
.co-leg-val {
  font-family: var(--font-mono);
  font-size: .60rem;
  color: var(--text-muted);
  margin-left: auto;
  flex-shrink: 0;
}
.co-leg-item--on .co-leg-val { color: var(--text-secondary); }

/* ── Right panel ── */
.co-right {
  padding: .85rem 1rem;
  display: flex;
  flex-direction: column;
  min-width: 0;
}

/* Badge row — exact Arc (O) spec */
.co-toprow {
  display: flex;
  align-items: center;
  gap: .28rem;
  flex-wrap: wrap;
  margin-bottom: .35rem;
}
.co-toprow-r {
  margin-left: auto;
  display: flex;
  gap: .18rem;
  flex-shrink: 0;
}

/* badge2 — Arc status pills (replaces .badge in this card) */
.badge2 {
  font-size: .62rem;
  font-weight: 700;
  letter-spacing: .07em;
  text-transform: uppercase;
  padding: 2px 6px;
  border-radius: 999px;
  border: 1px solid;
  display: inline-flex;
  align-items: center;
  gap: 3px;
  white-space: nowrap;
}
.b2-act { color: #22C55E; border-color: rgba(34,197,94,.3); background: rgba(34,197,94,.08); }
.b2-hld { color: #F9A84A; border-color: rgba(249,168,74,.3); background: rgba(249,168,74,.08); }
.b2-cmp { color: #60B4F8; border-color: rgba(96,180,248,.3); background: rgba(96,180,248,.08); }
.b2-cxl { color: #EF4444; border-color: rgba(239,68,68,.3);  background: rgba(239,68,68,.08); }
.b2-inv { color: #A78BFA; border-color: rgba(167,139,250,.3);background: rgba(167,139,250,.08); }
.b2-arc { color: var(--text-muted); border-color: var(--border-default); background: var(--bg-overlay); }
.b2-met { color: var(--text-accent); border-color: var(--border-default); background: var(--bg-overlay); }

/* ibtn — Arc icon buttons: 24×24, border, hover accent */
.ibtn {
  width: 24px;
  height: 24px;
  border-radius: var(--radius-sm, 5px);
  border: 1px solid var(--border-default);
  background: transparent;
  display: grid;
  place-items: center;
  cursor: pointer;
  color: var(--text-muted);
  transition: border-color .15s, color .15s, background .15s;
  flex-shrink: 0;
  text-decoration: none;
}
.ibtn:hover { border-color: var(--border-accent); color: var(--text-accent); background: var(--bg-hover); }
.ibtn.del:hover { border-color: rgba(239,68,68,.4); color: #EF4444; background: rgba(239,68,68,.06); }
.ibtn svg { width: 11px; height: 11px; }

/* live-dot — used inside badge2 */
.live-dot {
  display: inline-block;
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: #22C55E;
  flex-shrink: 0;
  animation: livepulse 1.8s ease-in-out infinite;
}
@keyframes livepulse {
  0%, 100% { opacity: 1; }
  50%       { opacity: .35; }
}

/* Project name */
.co-name {
  font-family: var(--font-display);
  font-size: .96rem;
  font-weight: 700;
  color: var(--text-heading);
  letter-spacing: -.015em;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  margin-bottom: .16rem;
}

/* Meta line: client · ID · dates */
.co-meta {
  font-size: .62rem;
  color: var(--text-secondary);
  display: flex;
  align-items: center;
  gap: .26rem;
  flex-wrap: wrap;
  margin-bottom: .55rem;
}
.co-meta .sep { color: var(--border-strong); font-size: .5rem; }
.co-meta .mono { font-size: .57rem; color: var(--text-muted); }

/* 2-col stats grid — exact Arc (O) spec: 1fr 1fr */
.co-stats {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: .32rem .6rem;
  margin-bottom: .58rem;
}
.co-stat-val {
  font-family: var(--font-mono);
  font-size: .8rem;
  font-weight: 700;
  color: var(--text-heading);
  line-height: 1;
}
.co-stat-lbl {
  font-size: .62rem;
  font-weight: 600;
  letter-spacing: .07em;
  text-transform: uppercase;
  color: var(--text-muted);
  margin-top: .04rem;
}

/* Progress row */
.co-prog-row {
  display: flex;
  align-items: center;
  gap: .38rem;
  margin-bottom: .3rem;
}
.co-prog-lbl { font-size: .6rem; color: var(--text-secondary); }
.co-prog-val { font-family: var(--font-mono); font-size: .6rem; margin-left: auto; }

/* Progress track */
.co-prog-track {
  height: 4px;
  border-radius: 2px;
  background: var(--border-default);
  overflow: hidden;
  margin-bottom: .45rem;
}
.co-prog-fill {
  height: 100%;
  border-radius: 2px;
  transition: width .6s ease;
}

/* Footer */
.co-footer {
  display: flex;
  align-items: center;
  gap: .26rem;
  flex-wrap: wrap;
  font-size: .6rem;
  color: var(--text-muted);
  padding-top: .4rem;
  border-top: 1px solid var(--border-subtle);
  margin-top: auto;
}
.co-footer strong { color: var(--text-secondary); font-weight: 600; }
.co-footer .sep { opacity: .3; }

/* Live dot pulse */
@keyframes pulse-green {
  0%, 100% { opacity: 1; }
  50%       { opacity: .45; }
}
.co-live-dot {
  display: inline-block;
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: #22C55E;
  margin-right: 3px;
  animation: pulse-green 1.8s ease-in-out infinite;
  vertical-align: middle;
}

/* Days-remaining chip */
.co-days-chip {
  font-size: .62rem;
  padding: 1px 5px;
  border-radius: 999px;
  background: rgba(34,197,94,.1);
  color: #22C55E;
  border: 1px solid rgba(34,197,94,.2);
}
.co-days-chip--warn { background: rgba(245,158,11,.1); color: #F59E0B; border-color: rgba(245,158,11,.2); }
.co-days-chip--over { background: rgba(239,68,68,.1);  color: #EF4444; border-color: rgba(239,68,68,.2); }

/* Warning line in footer when modules are sparse */
.co-warn { color: #F59E0B; }

/* Responsive */
@media (max-width: 520px) {
  .project-card { grid-template-columns: 1fr !important; }
  .co-left { flex-direction: row; padding: .75rem 1rem; border-right: none; border-bottom: 1px solid var(--border-default); }
  .co-arc-wrap { width: 72px; height: 72px; }
  .co-arc-wrap svg { width: 72px; height: 72px; }
  .co-arc-num { font-size: 1.2rem; }
}





/* Combined grid */
.combined{background:var(--surface-2);border:1px solid var(--border);border-radius:12px;overflow:hidden;margin-bottom:2rem;}
.combined-title{padding:1rem 1.5rem;border-bottom:1px solid var(--border);font-family:var(--font-display);font-size:1rem;font-weight: 400;color:var(--text-heading);}
.combined-grid{display:grid;grid-template-columns:repeat(auto-fit,minmax(200px,1fr));}
.combined-cell{padding:1rem 1.5rem;border-right:1px solid var(--border);}
.combined-cell:last-child{border-right:none;}
.combined-cell-tag{font-family:var(--font-mono);font-size:.65rem;letter-spacing:.1em;text-transform:uppercase;color:var(--text-muted);margin-bottom:.35rem;}
.combined-cell-clusters{font-size:.85rem;line-height:1.6;color:var(--text-secondary);}
.combined-body{padding:1.25rem 1.5rem;border-top:1px solid var(--border);font-size:.9rem;line-height:1.7;color:var(--text-secondary);}

/* FaceGraph strip */
.face-strip{display:flex;align-items:center;justify-content:space-between;padding:1.25rem 1.5rem;background:var(--accent-alpha-06);border:1px solid var(--accent-alpha-18);border-radius:12px;gap:1.5rem;margin-bottom:3rem;flex-wrap:wrap;}
.face-strip-txt{font-size:.9rem;line-height:1.65;color:var(--text-secondary);flex:1;}
.face-strip-badge{font-family:var(--font-mono);font-size:.75rem;font-weight:700;letter-spacing:.08em;text-transform:uppercase;padding:.35rem .85rem;border-radius:4px;background:var(--accent-alpha-12);border:1px solid var(--accent-alpha-20);color:var(--amber);white-space:nowrap;}

@media(max-width:768px){
  .clusters{grid-template-columns:1fr;}
  .legend{gap:1rem;}
}


/* ════════════════════════════════════════════════════════════════════════
   CLUSTERS PAGE — /products/clusters
   ════════════════════════════════════════════════════════════════════════ */
.pg-tog-wrap{padding:1rem 0 0;display:flex;justify-content:flex-end;}
.pg-tog{
  font-family:var(--font-mono);font-size:.75rem;padding:.3rem .75rem;
  border-radius:var(--radius-sm);border:1px solid var(--border-default);
  background:transparent;cursor:pointer;color:var(--text-secondary);
}

.mast{padding:clamp(4rem,8vw,6rem) 0 clamp(2rem,4vw,3rem);max-width:680px;}
.mast-logo{
  font-family:var(--font-display);font-size:.875rem;font-weight:700;
  letter-spacing:.06em;color:var(--text-accent);margin-bottom:1rem;
}
.mast-h{
  font-family:var(--font-serif);font-size:clamp(1.75rem,4vw,2.75rem);
  font-weight:400;font-style:italic;line-height:1.15;letter-spacing:0;
  color:var(--text-heading);margin-bottom:.75rem;
}
.mast-h strong{font-weight:700;}
.mast-sub{font-size:1rem;font-weight:300;line-height:1.7;color:var(--text-secondary);}

.legend{
  display:flex;align-items:center;gap:1.5rem;padding:.75rem 0;
  border-top:1px solid var(--border-subtle);
  border-bottom:1px solid var(--border-subtle);
  margin-bottom:2.5rem;flex-wrap:wrap;
}
.legend-lbl{
  font-family:var(--font-mono);font-size:.7rem;letter-spacing:.1em;
  text-transform:uppercase;color:var(--text-muted);
}
.legend-item{display:flex;align-items:center;gap:.4rem;font-size:.82rem;color:var(--text-secondary);}
.legend-dot{width:8px;height:8px;border-radius:50%;flex-shrink:0;}

.clusters{
  display:grid;grid-template-columns:repeat(2,1fr);
  gap:1px;background:var(--border-subtle);
  border:1px solid var(--border-default);border-radius:var(--radius-lg);
  overflow:hidden;margin-bottom:2rem;
}
.cl{
  background:var(--bg-surface);
  padding:clamp(1.25rem,2.5vw,1.75rem);
  display:flex;flex-direction:column;gap:1rem;
}
.cl-top{display:flex;justify-content:space-between;align-items:flex-start;gap:1rem;}
.cl-name-wrap{display:flex;flex-direction:column;gap:.2rem;}
.cl-eyebrow{
  font-family:var(--font-mono);font-size:.65rem;letter-spacing:.12em;
  text-transform:uppercase;color:var(--text-muted);
}
.cl-name{
  font-family:var(--font-serif);font-size:1.15rem;font-weight:400;
  font-style:italic;letter-spacing:0;color:var(--text-heading);
}
.cl-weight{text-align:right;}
.cl-weight-num{font-family:var(--font-mono);font-size:1.25rem;font-weight:500;line-height:1;}
.cl-weight-lbl{
  font-family:var(--font-mono);font-size:.6rem;letter-spacing:.08em;
  text-transform:uppercase;color:var(--text-muted);margin-top:.15rem;
}
.cl-desc{font-size:.9rem;font-weight:300;line-height:1.7;color:var(--text-secondary);flex:1;}
.cl-signals{display:flex;flex-direction:column;gap:.35rem;}
.cl-signal{display:flex;align-items:baseline;gap:.5rem;font-size:.82rem;color:var(--text-secondary);}
.cl-signal-dot{
  width:5px;height:5px;border-radius:50%;
  background:var(--text-accent);flex-shrink:0;margin-top:.25em;
}
.cl-catches{
  padding:.65rem .85rem;
  background:var(--bg-elevated);border-radius:var(--radius-sm);
}
.cl-catches-lbl{
  font-family:var(--font-mono);font-size:.6rem;letter-spacing:.1em;
  text-transform:uppercase;color:var(--text-muted);margin-bottom:.25rem;
}
.cl-catches-txt{font-size:.82rem;line-height:1.55;color:var(--text-secondary);}
.cl-weight-bar{
  height:3px;background:var(--border-subtle);
  border-radius:2px;overflow:hidden;margin-top:auto;
}
.cl-weight-fill{height:100%;background:var(--text-accent);border-radius:2px;}

/* Combined grid */
.combined{
  background:var(--bg-surface);border:1px solid var(--border-default);
  border-radius:var(--radius-lg);overflow:hidden;margin-bottom:2rem;
}
.combined-title{
  padding:1rem 1.5rem;border-bottom:1px solid var(--border-subtle);
  font-family:var(--font-display);font-size:1rem;font-weight:600;
  color:var(--text-heading);
}
.combined-grid{display:grid;grid-template-columns:repeat(auto-fit,minmax(200px,1fr));}
.combined-cell{padding:1rem 1.5rem;border-right:1px solid var(--border-subtle);}
.combined-cell:last-child{border-right:none;}
.combined-cell-tag{
  font-family:var(--font-mono);font-size:.65rem;letter-spacing:.1em;
  text-transform:uppercase;color:var(--text-muted);margin-bottom:.35rem;
}
.combined-cell-clusters{font-size:.85rem;line-height:1.6;color:var(--text-secondary);}
.combined-body{
  padding:1.25rem 1.5rem;border-top:1px solid var(--border-subtle);
  font-size:.9rem;line-height:1.7;color:var(--text-secondary);
}

/* FaceGraph strip */
.face-strip{
  display:flex;align-items:center;justify-content:space-between;
  padding:1.25rem 1.5rem;
  background:var(--bg-elevated);
  border:1px solid var(--border-accent);
  border-radius:var(--radius-lg);
  gap:1.5rem;margin-bottom:3rem;flex-wrap:wrap;
}
.face-strip-txt{font-size:.9rem;line-height:1.65;color:var(--text-secondary);flex:1;}
.face-strip-badge{
  font-family:var(--font-mono);font-size:.75rem;font-weight:700;
  letter-spacing:.08em;text-transform:uppercase;
  padding:.35rem .85rem;border-radius:var(--radius-sm);
  background:var(--bg-elevated);border:1px solid var(--border-accent);
  color:var(--text-accent);white-space:nowrap;
}

@media(max-width:768px){
  .clusters{grid-template-columns:1fr;}
  .legend{gap:1rem;}
}
/* ── Theme toggle buttons — borderless, transparent, subtle hover ── */
/* Applied to every sun/moon toggle via the shared .theme-toggle-btn class.
   Overrides any inherited button border/background from shared classes
   (topbar-btn, nav-tog, K-ntb, btn-secondary, etc.). */
.theme-toggle-btn {
  background: transparent !important;
  border: none !important;
  box-shadow: none !important;
  color: var(--text-muted);
  cursor: pointer;
  transition: background 0.15s ease, color 0.15s ease;
}
.theme-toggle-btn:hover {
  background: var(--bg-hover) !important;
  color: var(--text-primary);
}
