/*
 * Trinity Solutions v3
 * Art direction: Premium editorial security SaaS
 * Palette: Warm parchment + deep ink navy + antique gold — distinguished, trustworthy, never cold
 * Typography: DM Serif Display (editorial gravitas) + DM Sans (refined legibility)
 * Aesthetic: High-end financial/legal services — confident minimalism with warmth
 */

/* ============================================================
   DESIGN TOKENS — full set (critical path tokens in <style>)
   ============================================================ */
:root,
[data-theme="light"] {
  /* Brand */
  --c-bg:          #F5F3EF;
  --c-bg-alt:      #EDEAE3;
  --c-surface:     #FFFFFF;
  --c-surface-2:   #F9F7F4;
  --c-text:        #0E0C0A;
  --c-text-muted:  #5A5248;
  --c-text-faint:  #9A9188;
  --c-text-inv:    #F5F3EF;
  --c-gold:        #C4A882;
  --c-gold-d:      #A88B65;
  --c-gold-bg:     rgba(196,168,130,0.1);
  --c-gold-border: rgba(196,168,130,0.3);
  --c-navy:        #0E1829;
  --c-navy-mid:    #1A2E4A;
  --c-border:      #E2DDD6;
  --c-divider:     #EAE6E0;
  --c-success:     #2E7D52;
  --c-error:       #B91C1C;
  --c-warn:        #C07A1E;

  /* Shadows */
  --shadow-xs: 0 1px 2px rgba(14,12,10,0.05);
  --shadow-sm: 0 2px 8px rgba(14,12,10,0.07);
  --shadow-md: 0 6px 24px rgba(14,12,10,0.09);
  --shadow-lg: 0 16px 48px rgba(14,12,10,0.12);
  --shadow-xl: 0 24px 64px rgba(14,12,10,0.16);

  /* Type scale */
  --text-xs:   clamp(0.75rem,  0.7rem  + 0.2vw,  0.8125rem);
  --text-sm:   clamp(0.875rem, 0.82rem + 0.27vw,  1rem);
  --text-base: clamp(1rem,     0.95rem + 0.25vw,  1.125rem);
  --text-lg:   clamp(1.125rem, 1rem    + 0.6vw,   1.375rem);
  --text-xl:   clamp(1.5rem,   1.2rem  + 1.2vw,   2.125rem);
  --text-2xl:  clamp(2rem,     1.3rem  + 2.2vw,   3.25rem);
  --text-hero: clamp(2.5rem,   1.4rem  + 3.2vw,   4.25rem);

  /* Spacing */
  --sp-1: .25rem; --sp-2: .5rem; --sp-3: .75rem; --sp-4: 1rem;
  --sp-5: 1.25rem; --sp-6: 1.5rem; --sp-8: 2rem; --sp-10: 2.5rem;
  --sp-12: 3rem; --sp-16: 4rem; --sp-20: 5rem; --sp-24: 6rem;

  /* Radii */
  --r-sm: .25rem; --r-md: .5rem; --r-lg: .75rem;
  --r-xl: 1rem; --r-2xl: 1.5rem; --r-full: 9999px;

  /* Fonts */
  --font-serif: 'DM Serif Display', Georgia, 'Times New Roman', serif;
  --font-body:  'DM Sans', system-ui, sans-serif;

  /* Transition */
  --ease: cubic-bezier(0.16, 1, 0.3, 1);
  --t-fast:  120ms var(--ease);
  --t-base:  200ms var(--ease);
  --t-slow:  400ms var(--ease);

  /* Layout */
  --max-w: 1140px;
  --nav-h: 68px;
}

[data-theme="dark"] {
  --c-bg:          #0A0F1E;
  --c-bg-alt:      #0E1422;
  --c-surface:     #111827;
  --c-surface-2:   #0D1320;
  --c-text:        #EAE6DE;
  --c-text-muted:  #8A8178;
  --c-text-faint:  #4A453D;
  --c-text-inv:    #0A0F1E;
  --c-gold:        #D4B896;
  --c-gold-d:      #C4A882;
  --c-gold-bg:     rgba(212,184,150,0.08);
  --c-gold-border: rgba(212,184,150,0.2);
  --c-navy:        #EAE6DE;
  --c-navy-mid:    #C4B9A8;
  --c-border:      #1E2A3D;
  --c-divider:     #172030;
  --shadow-xs: 0 1px 2px rgba(0,0,0,0.2);
  --shadow-sm: 0 2px 8px rgba(0,0,0,0.3);
  --shadow-md: 0 6px 24px rgba(0,0,0,0.4);
  --shadow-lg: 0 16px 48px rgba(0,0,0,0.5);
  --shadow-xl: 0 24px 64px rgba(0,0,0,0.6);
}

@media (prefers-color-scheme: dark) {
  :root:not([data-theme]) {
    --c-bg:#0A0F1E;--c-bg-alt:#0E1422;--c-surface:#111827;--c-surface-2:#0D1320;
    --c-text:#EAE6DE;--c-text-muted:#8A8178;--c-text-faint:#4A453D;--c-text-inv:#0A0F1E;
    --c-gold:#D4B896;--c-gold-d:#C4A882;--c-gold-bg:rgba(212,184,150,0.08);--c-gold-border:rgba(212,184,150,0.2);
    --c-navy:#EAE6DE;--c-navy-mid:#C4B9A8;--c-border:#1E2A3D;--c-divider:#172030;
    --shadow-xs:0 1px 2px rgba(0,0,0,0.2);--shadow-sm:0 2px 8px rgba(0,0,0,0.3);
    --shadow-md:0 6px 24px rgba(0,0,0,0.4);--shadow-lg:0 16px 48px rgba(0,0,0,0.5);--shadow-xl:0 24px 64px rgba(0,0,0,0.6);
  }
}

/* ============================================================
   RESET
   ============================================================ */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

html {
  scroll-behavior: smooth;
  scroll-padding-top: var(--nav-h);
  text-rendering: optimizeLegibility;
  -webkit-text-size-adjust: none;
  text-size-adjust: none;
}

img, svg { display: block; max-width: 100%; }
ul, ol { list-style: none; }
input, button, textarea, select { font: inherit; color: inherit; }
button { cursor: pointer; background: none; border: none; }
address { font-style: normal; }

h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-serif);
  font-weight: 400;
  line-height: 1.15;
  text-wrap: balance;
  color: var(--c-text);
}

p, li { text-wrap: pretty; }
a { color: var(--c-gold); text-decoration: none; }
a:hover { color: var(--c-gold-d); }

::selection {
  background: var(--c-gold-bg);
  color: var(--c-text);
}

:focus-visible {
  outline: 2px solid var(--c-gold);
  outline-offset: 3px;
  border-radius: var(--r-sm);
}

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

/* ============================================================
   UTILITIES
   ============================================================ */
.container {
  max-width: var(--max-w);
  margin-inline: auto;
  padding-inline: clamp(var(--sp-4), 5vw, var(--sp-12));
}

.sr-only {
  position: absolute; width: 1px; height: 1px; padding: 0;
  margin: -1px; overflow: hidden; clip: rect(0,0,0,0);
  white-space: nowrap; border: 0;
}

.skip-link {
  position: absolute; top: -999px; left: var(--sp-4); z-index: 9999;
  background: var(--c-navy); color: var(--c-bg);
  padding: var(--sp-3) var(--sp-6); border-radius: var(--r-md);
  font-weight: 600; font-size: var(--text-sm);
}
.skip-link:focus { top: var(--sp-4); }

/* ============================================================
   SCROLL ANIMATIONS
   ============================================================ */
.fade-up {
  opacity: 0;
  transform: translateY(24px);
  transition: opacity 0.6s var(--ease), transform 0.6s var(--ease);
}
.fade-up.is-visible { opacity: 1; transform: translateY(0); }
.fade-up:nth-child(2) { transition-delay: 80ms; }
.fade-up:nth-child(3) { transition-delay: 160ms; }
.fade-up:nth-child(4) { transition-delay: 240ms; }
.fade-up:nth-child(5) { transition-delay: 320ms; }
.fade-up:nth-child(6) { transition-delay: 400ms; }

/* ============================================================
   SECTION LABELS & HEADINGS
   ============================================================ */
.section-kicker {
  font-family: var(--font-body);
  font-size: var(--text-xs);
  font-weight: 600;
  letter-spacing: .12em;
  text-transform: uppercase;
  color: var(--c-gold-d);
  margin-bottom: var(--sp-3);
}

.section-heading {
  font-size: var(--text-2xl);
  font-weight: 400;
  letter-spacing: -.01em;
  color: var(--c-text);
  margin-bottom: var(--sp-4);
}

.section-sub {
  font-family: var(--font-body);
  font-size: var(--text-base);
  color: var(--c-text-muted);
  max-width: 58ch;
  margin-bottom: var(--sp-12);
  line-height: 1.75;
}

/* ============================================================
   BUTTONS
   ============================================================ */
.btn {
  display: inline-flex;
  align-items: center;
  gap: var(--sp-2);
  padding: .625rem 1.375rem;
  border-radius: var(--r-md);
  font-family: var(--font-body);
  font-size: var(--text-sm);
  font-weight: 500;
  line-height: 1.4;
  cursor: pointer;
  text-decoration: none;
  border: 1.5px solid transparent;
  transition: background var(--t-base), color var(--t-base),
              border-color var(--t-base), box-shadow var(--t-base),
              transform var(--t-fast);
  white-space: nowrap;
  min-height: 44px;
}
.btn:active { transform: translateY(1px); }

.btn-lg { padding: .75rem 1.75rem; font-size: var(--text-base); }

.btn-primary {
  background: var(--c-navy);
  color: var(--c-bg);
  border-color: var(--c-navy);
}
[data-theme="dark"] .btn-primary {
  background: var(--c-gold);
  color: #0A0F1E;
  border-color: var(--c-gold);
}
.btn-primary:hover {
  background: var(--c-navy-mid);
  border-color: var(--c-navy-mid);
  color: var(--c-bg);
  box-shadow: var(--shadow-md);
}
[data-theme="dark"] .btn-primary:hover {
  background: var(--c-gold-d);
  border-color: var(--c-gold-d);
  color: #0A0F1E;
}

.btn-outline {
  background: transparent;
  color: var(--c-text);
  border-color: var(--c-border);
}
.btn-outline:hover {
  background: var(--c-surface-2);
  border-color: var(--c-gold);
  color: var(--c-text);
}
.btn-outline svg { color: var(--c-text-muted); }

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

/* ============================================================
   NAV
   ============================================================ */
.nav-header {
  position: sticky; top: 0; z-index: 100;
  height: var(--nav-h);
  border-bottom: 1px solid var(--c-border);
  background: color-mix(in oklch, var(--c-bg) 85%, transparent);
  backdrop-filter: blur(20px) saturate(1.3);
  -webkit-backdrop-filter: blur(20px) saturate(1.3);
  transition: background var(--t-slow), box-shadow var(--t-slow);
}
.nav-header.scrolled {
  box-shadow: 0 1px 16px rgba(14,12,10,0.08);
}

.nav-link {
  font-family: var(--font-body);
  font-size: var(--text-sm);
  font-weight: 500;
  color: var(--c-text-muted);
  text-decoration: none;
  padding: var(--sp-2) var(--sp-3);
  border-radius: var(--r-md);
  transition: color var(--t-fast), background var(--t-fast);
}
.nav-link:hover { color: var(--c-text); background: var(--c-gold-bg); }
.nav-link--hidden-sm { display: none; }
@media (min-width: 700px) { .nav-link--hidden-sm { display: inline-flex; } }

.nav-name { font-family: var(--font-serif); font-size: 1.05rem; color: var(--c-text); }

.nav-actions { display: flex; align-items: center; gap: var(--sp-3); }

.theme-toggle {
  display: flex; align-items: center; justify-content: center;
  width: 36px; height: 36px; border-radius: var(--r-md);
  color: var(--c-text-muted);
  transition: color var(--t-fast), background var(--t-fast);
}
.theme-toggle:hover { color: var(--c-text); background: var(--c-gold-bg); }

/* ============================================================
   HERO
   ============================================================ */
.hero {
  padding-block: clamp(var(--sp-16), 12vw, var(--sp-24)) clamp(var(--sp-12), 8vw, var(--sp-20));
  background: var(--c-bg);
  position: relative;
  overflow: hidden;
}

/* Subtle warm grid texture */
.hero::before {
  content: '';
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(var(--c-border) 1px, transparent 1px),
    linear-gradient(90deg, var(--c-border) 1px, transparent 1px);
  background-size: 48px 48px;
  opacity: 0.35;
  pointer-events: none;
}

/* Warm radial glow */
.hero::after {
  content: '';
  position: absolute;
  top: -20%;
  right: -10%;
  width: 60%;
  height: 80%;
  background: radial-gradient(ellipse at center, var(--c-gold-bg) 0%, transparent 70%);
  pointer-events: none;
}

.hero-layout {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: clamp(var(--sp-10), 6vw, var(--sp-16));
  align-items: center;
  position: relative;
  z-index: 1;
}

@media (max-width: 820px) {
  .hero-layout { grid-template-columns: 1fr; }
  .hero-visual { order: -1; }
}

.hero-eyebrow {
  display: inline-flex;
  align-items: center;
  gap: var(--sp-2);
  font-family: var(--font-body);
  font-size: var(--text-xs);
  font-weight: 600;
  letter-spacing: .1em;
  text-transform: uppercase;
  color: var(--c-gold-d);
  padding: var(--sp-2) var(--sp-3);
  background: var(--c-gold-bg);
  border: 1px solid var(--c-gold-border);
  border-radius: var(--r-full);
  margin-bottom: var(--sp-6);
}

.eyebrow-dot {
  width: 6px; height: 6px;
  border-radius: var(--r-full);
  background: var(--c-gold);
  flex-shrink: 0;
  animation: pulse-dot 2s ease-in-out infinite;
}

@keyframes pulse-dot {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.4; }
}

.hero-heading {
  font-size: var(--text-hero);
  font-weight: 400;
  letter-spacing: -.02em;
  line-height: 1.1;
  color: var(--c-text);
  margin-bottom: var(--sp-6);
}
.hero-heading em {
  font-style: italic;
  color: var(--c-gold-d);
}

.hero-sub {
  font-family: var(--font-body);
  font-size: var(--text-lg);
  color: var(--c-text-muted);
  line-height: 1.7;
  max-width: 46ch;
  margin-bottom: var(--sp-8);
  font-weight: 300;
}
.hero-sub strong { color: var(--c-text); font-weight: 500; }

.hero-btns { display: flex; gap: var(--sp-3); flex-wrap: wrap; margin-bottom: var(--sp-8); }

.trust-row {
  display: flex; flex-wrap: wrap; gap: var(--sp-4) var(--sp-6);
}
.trust-item {
  display: flex; align-items: center; gap: var(--sp-2);
  font-family: var(--font-body);
  font-size: var(--text-xs); font-weight: 500;
  color: var(--c-text-muted);
}
.trust-item svg { color: var(--c-gold); flex-shrink: 0; }

/* ============================================================
   DASHBOARD CHROME
   ============================================================ */
.hero-visual {
  border-radius: var(--r-xl);
  overflow: hidden;
  border: 1px solid var(--c-border);
  box-shadow: var(--shadow-xl);
  transition: transform var(--t-slow), box-shadow var(--t-slow);
}
.hero-visual:hover {
  transform: translateY(-5px) rotate(-.3deg);
  box-shadow: 0 32px 80px rgba(14,12,10,0.18);
}

.dashboard-chrome {
  background: var(--c-surface);
  font-family: var(--font-body);
}

.chrome-bar {
  display: flex;
  align-items: center;
  gap: var(--sp-2);
  padding: 10px 14px;
  background: #1A2034;
  border-bottom: 1px solid rgba(255,255,255,0.06);
}
.chrome-dot { width: 10px; height: 10px; border-radius: 50%; flex-shrink: 0; }
.chrome-title {
  margin-left: var(--sp-3);
  font-size: .7rem;
  color: rgba(255,255,255,0.45);
  letter-spacing: .02em;
}

.dashboard-body { display: flex; min-height: 0; }

.dash-sidebar {
  width: 130px;
  flex-shrink: 0;
  background: #111827;
  padding: var(--sp-4) var(--sp-3);
  display: flex;
  flex-direction: column;
  gap: 2px;
  border-right: 1px solid rgba(255,255,255,0.06);
}

.sidebar-item {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 7px 10px;
  border-radius: 6px;
  font-size: .72rem;
  font-weight: 500;
  color: rgba(255,255,255,0.45);
  cursor: default;
  transition: background .15s;
}
.sidebar-item--active {
  background: rgba(196,168,130,0.15);
  color: #C4A882;
}

.dash-main {
  flex: 1;
  padding: var(--sp-4);
  background: #F8F7F4;
  display: flex;
  flex-direction: column;
  gap: var(--sp-3);
}
[data-theme="dark"] .dash-main { background: #0D1421; }

.dash-header-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.dash-title { font-size: .8rem; font-weight: 600; color: #0E0C0A; }
[data-theme="dark"] .dash-title { color: #DDD8D0; }

.dash-run-btn {
  font-size: .65rem;
  font-weight: 600;
  padding: 5px 10px;
  background: #0E1829;
  color: #C4A882;
  border: none;
  border-radius: 5px;
  cursor: default;
  pointer-events: none;
}

.kpi-row { display: grid; grid-template-columns: repeat(3, 1fr); gap: var(--sp-2); }

.kpi-card {
  background: white;
  border: 1px solid #E2DDD6;
  border-radius: 8px;
  padding: 10px 12px;
}
[data-theme="dark"] .kpi-card { background: #141D2B; border-color: #1E2A3D; }

.kpi-label { font-size: .6rem; color: #9A9188; margin-bottom: 3px; }
.kpi-value { font-size: 1.6rem; font-family: var(--font-serif); font-weight: 400; color: #0E1829; line-height: 1; }
[data-theme="dark"] .kpi-value { color: #DDD8D0; }
.kpi-value--primary { color: #0E1829; }
.kpi-value--warn { color: #C07A1E; }
.kpi-unit { font-size: .9rem; }
.kpi-delta { font-size: .6rem; color: #2E7D52; margin-top: 3px; }
.kpi-sub { font-size: .6rem; color: #9A9188; margin-top: 3px; }

.framework-list {
  background: white;
  border: 1px solid #E2DDD6;
  border-radius: 8px;
  padding: 10px 12px;
  flex: 1;
}
[data-theme="dark"] .framework-list { background: #141D2B; border-color: #1E2A3D; }

.fw-label { font-size: .65rem; font-weight: 600; color: #5A5248; margin-bottom: 8px; }
[data-theme="dark"] .fw-label { color: #9A9188; }

.fw-row { display: flex; align-items: center; gap: 8px; margin-bottom: 7px; }
.fw-name { font-size: .6rem; color: #9A9188; width: 85px; flex-shrink: 0; white-space: nowrap; }
.fw-bar-track { flex: 1; height: 6px; background: #EAE6E0; border-radius: 999px; overflow: hidden; }
[data-theme="dark"] .fw-bar-track { background: #1E2A3D; }
.fw-bar { height: 100%; border-radius: 999px; transition: width .6s var(--ease); }
.fw-pct { font-size: .6rem; font-weight: 600; width: 30px; text-align: right; color: #5A5248; }

.dash-status-bar {
  display: flex;
  align-items: center;
  gap: var(--sp-2);
  background: #0E1829;
  border-radius: 6px;
  padding: 8px 12px;
  font-size: .62rem;
  color: rgba(255,255,255,0.45);
  flex-wrap: wrap;
}
.status-sep { color: rgba(255,255,255,0.2); }
.status-badge { color: #C4A882; font-weight: 600; }

/* ============================================================
   PROBLEM STRIP
   ============================================================ */
.problem-strip {
  background: var(--c-bg-alt);
  padding-block: clamp(var(--sp-12), 6vw, var(--sp-20));
  border-top: 1px solid var(--c-border);
  border-bottom: 1px solid var(--c-border);
}

.problem-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: var(--sp-6); }
@media (max-width: 820px) { .problem-grid { grid-template-columns: 1fr; } }

.problem-card {
  padding: var(--sp-8);
  background: var(--c-surface);
  border: 1px solid var(--c-border);
  border-radius: var(--r-xl);
  transition: box-shadow var(--t-base), transform var(--t-base), border-color var(--t-base);
  position: relative;
  overflow: hidden;
}
.problem-card::before {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 2px;
  background: linear-gradient(90deg, var(--c-gold) 0%, transparent 100%);
  opacity: 0;
  transition: opacity var(--t-base);
}
.problem-card:hover { box-shadow: var(--shadow-md); transform: translateY(-3px); border-color: var(--c-gold-border); }
.problem-card:hover::before { opacity: 1; }

.problem-icon { color: var(--c-gold); margin-bottom: var(--sp-5); }

.problem-card h3 {
  font-size: var(--text-base);
  font-family: var(--font-body);
  font-weight: 600;
  margin-bottom: var(--sp-3);
  color: var(--c-text);
}
.problem-card p {
  font-family: var(--font-body);
  font-size: var(--text-sm);
  color: var(--c-text-muted);
  line-height: 1.7;
}

/* ============================================================
   PRODUCT SECTION
   ============================================================ */
.product-section {
  padding-block: clamp(var(--sp-16), 8vw, var(--sp-24));
  background: var(--c-bg);
}

.features-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: var(--sp-6);
}
@media (max-width: 820px) { .features-grid { grid-template-columns: 1fr; } }

.feature-card {
  padding: var(--sp-8);
  background: var(--c-surface);
  border: 1px solid var(--c-border);
  border-radius: var(--r-xl);
  position: relative;
  transition: box-shadow var(--t-base), transform var(--t-base);
}
.feature-card:hover { box-shadow: var(--shadow-md); transform: translateY(-4px); }

.feature-num {
  font-family: var(--font-serif);
  font-size: 3rem;
  font-weight: 400;
  color: var(--c-gold-border);
  line-height: 1;
  margin-bottom: var(--sp-4);
  letter-spacing: -.02em;
}

.feature-icon { color: var(--c-gold); margin-bottom: var(--sp-4); }

.feature-card h3 {
  font-family: var(--font-body);
  font-size: var(--text-base);
  font-weight: 600;
  margin-bottom: var(--sp-3);
  color: var(--c-text);
}
.feature-card p {
  font-family: var(--font-body);
  font-size: var(--text-sm);
  color: var(--c-text-muted);
  line-height: 1.75;
}

/* ============================================================
   STATS
   ============================================================ */
.stats-section {
  padding-block: clamp(var(--sp-16), 8vw, var(--sp-20));
  background: var(--c-navy);
  position: relative;
  overflow: hidden;
}

[data-theme="dark"] .stats-section {
  background: #0D1120;
  border-top: 1px solid var(--c-border);
  border-bottom: 1px solid var(--c-border);
}

.stats-section::before {
  content: '';
  position: absolute;
  top: 50%; left: 50%;
  transform: translate(-50%, -50%);
  width: 600px; height: 400px;
  background: radial-gradient(ellipse, rgba(196,168,130,0.12) 0%, transparent 70%);
  pointer-events: none;
}

.stats-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: var(--sp-8);
  position: relative;
}
@media (max-width: 820px) { .stats-grid { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 480px) { .stats-grid { grid-template-columns: 1fr; } }

.stat-card { text-align: center; }

.stat-value {
  font-family: var(--font-serif);
  font-size: clamp(2.2rem, 1.2rem + 2.5vw, 3.5rem);
  font-weight: 400;
  color: #FFFFFF;
  line-height: 1;
  letter-spacing: -.02em;
  margin-bottom: var(--sp-3);
}
[data-theme="dark"] .stat-value { color: var(--c-gold); }

.stat-plus { color: var(--c-gold); font-size: .7em; }
[data-theme="dark"] .stat-plus { color: var(--c-gold-d); }

.stat-label {
  font-family: var(--font-body);
  font-size: var(--text-sm);
  color: rgba(255,255,255,0.5);
  line-height: 1.5;
}
[data-theme="dark"] .stat-label { color: var(--c-text-muted); }

/* ============================================================
   DIFFERENTIATORS
   ============================================================ */
.diff-section {
  padding-block: clamp(var(--sp-16), 8vw, var(--sp-24));
  background: var(--c-bg-alt);
  border-top: 1px solid var(--c-border);
}

.diff-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: var(--sp-4);
}
@media (max-width: 900px) { .diff-grid { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 560px) { .diff-grid { grid-template-columns: 1fr; } }

.diff-card {
  padding: var(--sp-6);
  background: var(--c-surface);
  border: 1px solid var(--c-border);
  border-radius: var(--r-lg);
  transition: box-shadow var(--t-base), transform var(--t-base), border-color var(--t-base);
}
.diff-card:hover {
  box-shadow: var(--shadow-sm);
  transform: translateY(-2px);
  border-color: var(--c-gold-border);
}

.diff-icon {
  color: var(--c-gold);
  margin-bottom: var(--sp-4);
  padding: var(--sp-2);
  background: var(--c-gold-bg);
  border-radius: var(--r-md);
  display: inline-flex;
}

.diff-card h3 {
  font-family: var(--font-body);
  font-size: var(--text-sm);
  font-weight: 600;
  margin-bottom: var(--sp-2);
  color: var(--c-text);
}
.diff-card p {
  font-family: var(--font-body);
  font-size: var(--text-sm);
  color: var(--c-text-muted);
  line-height: 1.65;
}

/* ============================================================
   FRAMEWORKS
   ============================================================ */
.frameworks-section {
  padding-block: clamp(var(--sp-16), 8vw, var(--sp-24));
  background: var(--c-bg);
}

.frameworks-wrap {
  display: flex;
  flex-wrap: wrap;
  gap: var(--sp-3);
}

.fw-badge {
  display: inline-flex;
  align-items: center;
  padding: var(--sp-2) var(--sp-4);
  background: var(--c-surface);
  border: 1px solid var(--c-border);
  border-radius: var(--r-full);
  font-family: var(--font-body);
  font-size: var(--text-sm);
  font-weight: 500;
  color: var(--c-text-muted);
  white-space: nowrap;
  transition: background var(--t-fast), border-color var(--t-fast), color var(--t-fast);
}
.fw-badge:hover {
  background: var(--c-gold-bg);
  border-color: var(--c-gold);
  color: var(--c-text);
}
.fw-badge--accent {
  background: var(--c-gold-bg);
  border-color: var(--c-gold-border);
  color: var(--c-gold-d);
}

/* ============================================================
   HOW IT WORKS
   ============================================================ */
.how-section {
  padding-block: clamp(var(--sp-16), 8vw, var(--sp-24));
  background: var(--c-bg-alt);
  border-top: 1px solid var(--c-border);
}

.how-layout {
  display: grid;
  grid-template-columns: 1fr 1.5fr;
  gap: clamp(var(--sp-10), 6vw, var(--sp-20));
  align-items: start;
}
@media (max-width: 820px) { .how-layout { grid-template-columns: 1fr; } }

.how-intro .section-sub { margin-bottom: 0; }

.timeline { display: flex; flex-direction: column; }

.timeline-item {
  display: grid;
  grid-template-columns: 52px 1fr;
  gap: var(--sp-5);
  padding-bottom: var(--sp-8);
  position: relative;
}
.timeline-item:not(:last-child)::after {
  content: '';
  position: absolute;
  left: 25px; top: 50px; bottom: 0;
  width: 1px;
  background: linear-gradient(to bottom, var(--c-gold-border), transparent);
}

.tl-num {
  width: 52px; height: 52px;
  border-radius: var(--r-full);
  background: var(--c-surface);
  border: 1px solid var(--c-gold-border);
  display: flex; align-items: center; justify-content: center;
  font-family: var(--font-serif);
  font-size: var(--text-sm);
  color: var(--c-gold-d);
  flex-shrink: 0;
  z-index: 1;
  position: relative;
}

.tl-body { padding-top: var(--sp-3); }

.tl-body h3 {
  font-family: var(--font-body);
  font-size: var(--text-base);
  font-weight: 600;
  color: var(--c-text);
  margin-bottom: var(--sp-2);
}
.tl-body p {
  font-family: var(--font-body);
  font-size: var(--text-sm);
  color: var(--c-text-muted);
  line-height: 1.7;
}

/* ============================================================
   FAQ
   ============================================================ */
.faq-section {
  padding-block: clamp(var(--sp-16), 8vw, var(--sp-24));
  background: var(--c-bg);
  border-top: 1px solid var(--c-border);
}

.faq-layout { max-width: 720px; }

.faq-list { display: flex; flex-direction: column; gap: 0; }

.faq-item {
  border-bottom: 1px solid var(--c-divider);
  padding-block: var(--sp-6);
}
.faq-item:first-child { border-top: 1px solid var(--c-divider); }

.faq-q {
  font-family: var(--font-body);
  font-size: var(--text-base);
  font-weight: 600;
  color: var(--c-text);
  margin-bottom: var(--sp-3);
}

.faq-a {
  font-family: var(--font-body);
  font-size: var(--text-sm);
  color: var(--c-text-muted);
  line-height: 1.75;
}

/* ============================================================
   CONTACT
   ============================================================ */
.contact-section {
  padding-block: clamp(var(--sp-16), 8vw, var(--sp-24));
  background: var(--c-bg-alt);
  border-top: 1px solid var(--c-border);
}

.contact-layout {
  display: grid;
  grid-template-columns: 1fr 1.5fr;
  gap: clamp(var(--sp-10), 6vw, var(--sp-20));
  align-items: start;
}
@media (max-width: 820px) { .contact-layout { grid-template-columns: 1fr; } }

.contact-intro .section-sub { margin-bottom: var(--sp-8); }

.contact-email-block { margin-bottom: var(--sp-8); }

.contact-email-label {
  display: block;
  font-family: var(--font-body);
  font-size: var(--text-xs);
  font-weight: 600;
  letter-spacing: .08em;
  text-transform: uppercase;
  color: var(--c-text-muted);
  margin-bottom: var(--sp-2);
}

.contact-email-link {
  font-family: var(--font-body);
  font-size: var(--text-base);
  font-weight: 500;
  color: var(--c-gold-d);
  text-decoration: underline;
  text-underline-offset: 4px;
}
.contact-email-link:hover { color: var(--c-gold); }

.contact-address {
  font-family: var(--font-body);
  font-size: var(--text-sm);
  color: var(--c-text-muted);
  line-height: 1.8;
  padding-top: var(--sp-6);
  border-top: 1px solid var(--c-divider);
}
.contact-address strong { color: var(--c-text); display: block; margin-bottom: var(--sp-1); font-weight: 600; }
.company-num {
  display: inline-block;
  margin-top: var(--sp-2);
  font-size: var(--text-xs);
  color: var(--c-text-faint);
}

/* ============================================================
   CONTACT FORM
   ============================================================ */
.contact-form {
  background: var(--c-surface);
  border: 1px solid var(--c-border);
  border-radius: var(--r-2xl);
  padding: clamp(var(--sp-6), 4vw, var(--sp-10));
  box-shadow: var(--shadow-sm);
}

.form-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--sp-4);
}
@media (max-width: 560px) { .form-row { grid-template-columns: 1fr; } }

.form-group {
  display: flex;
  flex-direction: column;
  gap: var(--sp-2);
  margin-bottom: var(--sp-4);
}

label {
  font-family: var(--font-body);
  font-size: var(--text-sm);
  font-weight: 500;
  color: var(--c-text);
}
.req { color: var(--c-error); }

input, select, textarea {
  width: 100%;
  padding: .625rem .875rem;
  border: 1.5px solid var(--c-border);
  border-radius: var(--r-md);
  background: var(--c-bg);
  color: var(--c-text);
  font-family: var(--font-body);
  font-size: var(--text-sm);
  min-height: 44px;
  transition: border-color var(--t-fast), box-shadow var(--t-fast);
}
input::placeholder, textarea::placeholder { color: var(--c-text-faint); }

input:focus, select:focus, textarea:focus {
  outline: none;
  border-color: var(--c-gold);
  box-shadow: 0 0 0 3px var(--c-gold-bg);
}

input.is-invalid, textarea.is-invalid { border-color: var(--c-error); }

textarea { resize: vertical; min-height: 110px; }

.field-error {
  font-family: var(--font-body);
  font-size: var(--text-xs);
  color: var(--c-error);
  min-height: 1.2em;
}

.form-privacy {
  font-family: var(--font-body);
  font-size: var(--text-xs);
  color: var(--c-text-muted);
  margin-block: var(--sp-4);
  line-height: 1.6;
}
.form-privacy a { color: var(--c-gold-d); text-decoration: underline; text-underline-offset: 2px; }

.form-success {
  display: flex;
  align-items: center;
  gap: var(--sp-3);
  margin-top: var(--sp-4);
  padding: var(--sp-4);
  background: rgba(46,125,82,0.08);
  border: 1px solid rgba(46,125,82,0.25);
  border-radius: var(--r-md);
  color: var(--c-success);
  font-family: var(--font-body);
  font-size: var(--text-sm);
  font-weight: 500;
}

/* ============================================================
   FOOTER
   ============================================================ */
.site-footer {
  background: var(--c-navy);
  color: rgba(255,255,255,0.6);
  padding-top: clamp(var(--sp-12), 6vw, var(--sp-20));
}
[data-theme="dark"] .site-footer {
  background: var(--c-surface);
  border-top: 1px solid var(--c-border);
}

.footer-inner {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: var(--sp-12);
  padding-bottom: var(--sp-12);
  border-bottom: 1px solid rgba(255,255,255,0.1);
  align-items: start;
}
@media (max-width: 640px) { .footer-inner { grid-template-columns: 1fr; gap: var(--sp-8); } }
[data-theme="dark"] .footer-inner { border-bottom-color: var(--c-border); }

.footer-nav-name { color: rgba(255,255,255,0.85); }
[data-theme="dark"] .footer-nav-name { color: var(--c-text); }

.footer-tagline {
  font-family: var(--font-serif);
  font-style: italic;
  font-size: var(--text-sm);
  color: rgba(255,255,255,0.4);
  margin-top: var(--sp-3);
  margin-bottom: var(--sp-5);
}
[data-theme="dark"] .footer-tagline { color: var(--c-text-muted); }

.footer-address {
  font-family: var(--font-body);
  font-size: var(--text-xs);
  color: rgba(255,255,255,0.35);
  line-height: 1.8;
}
[data-theme="dark"] .footer-address { color: var(--c-text-faint); }

.footer-nav {
  display: flex;
  flex-direction: column;
  gap: var(--sp-3);
}
.footer-nav a {
  font-family: var(--font-body);
  font-size: var(--text-sm);
  color: rgba(255,255,255,0.55);
  text-decoration: none;
  transition: color var(--t-fast);
}
.footer-nav a:hover { color: rgba(255,255,255,0.9); }
[data-theme="dark"] .footer-nav a { color: var(--c-text-muted); }
[data-theme="dark"] .footer-nav a:hover { color: var(--c-text); }

.footer-bottom { padding-block: var(--sp-5); }
.footer-bottom-inner {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: var(--sp-3);
  font-family: var(--font-body);
  font-size: var(--text-xs);
  color: rgba(255,255,255,0.3);
}
[data-theme="dark"] .footer-bottom-inner { color: var(--c-text-faint); }

.footer-domain {
  color: rgba(255,255,255,0.3);
  text-decoration: none;
  transition: color var(--t-fast);
}
.footer-domain:hover { color: rgba(255,255,255,0.65); }

/* ============================================================
   LEGAL PAGES
   ============================================================ */
.legal-page { min-height: 100vh; }
.legal-hero {
  background: var(--c-bg-alt);
  border-bottom: 1px solid var(--c-border);
  padding-block: clamp(var(--sp-12), 6vw, var(--sp-20));
}
.legal-hero h1 { font-size: var(--text-xl); margin-bottom: var(--sp-3); }
.legal-meta {
  font-family: var(--font-body);
  font-size: var(--text-sm);
  color: var(--c-text-muted);
}
.legal-body { padding-block: clamp(var(--sp-12), 6vw, var(--sp-20)); }
.legal-content { max-width: 72ch; }
.legal-content h2 {
  font-size: var(--text-lg); font-weight: 400;
  margin-top: var(--sp-10); margin-bottom: var(--sp-4);
}
.legal-content h3 {
  font-family: var(--font-body); font-size: var(--text-base); font-weight: 600;
  margin-top: var(--sp-6); margin-bottom: var(--sp-3);
}
.legal-content p {
  font-family: var(--font-body); font-size: var(--text-base);
  color: var(--c-text-muted); line-height: 1.8; margin-bottom: var(--sp-4);
}
.legal-content ul { list-style: disc; padding-left: var(--sp-6); margin-bottom: var(--sp-4); }
.legal-content li {
  font-family: var(--font-body); font-size: var(--text-base);
  color: var(--c-text-muted); line-height: 1.7; margin-bottom: var(--sp-2);
}
.legal-content a { color: var(--c-gold-d); text-decoration: underline; text-underline-offset: 3px; }
.legal-nav-back {
  display: inline-flex; align-items: center; gap: var(--sp-2);
  font-family: var(--font-body); font-size: var(--text-sm); font-weight: 500;
  color: var(--c-gold-d); margin-bottom: var(--sp-8); text-decoration: none;
}
.legal-nav-back:hover { color: var(--c-gold); }

/* ============================================================
   HAMBURGER BUTTON — Fix #9
   ============================================================ */
.hamburger {
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 5px;
  width: 36px; height: 36px;
  padding: 8px;
  border-radius: var(--r-md);
  color: var(--c-text-muted);
  transition: background var(--t-fast);
  cursor: pointer;
}
@media (min-width: 700px) { .hamburger { display: none; } }
.hamburger:hover { background: var(--c-gold-bg); }
.hamburger-bar {
  display: block;
  width: 18px; height: 1.5px;
  background: currentColor;
  border-radius: 2px;
  transition: transform 0.25s var(--ease), opacity 0.2s;
  transform-origin: center;
}
.hamburger.is-open .hamburger-bar:nth-child(1) { transform: translateY(6.5px) rotate(45deg); }
.hamburger.is-open .hamburger-bar:nth-child(2) { opacity: 0; transform: scaleX(0); }
.hamburger.is-open .hamburger-bar:nth-child(3) { transform: translateY(-6.5px) rotate(-45deg); }

/* Hide CTA on mobile — hamburger takes over */
@media (max-width: 699px) { .nav-cta--hidden-sm { display: none !important; } }

/* ============================================================
   MOBILE NAV DRAWER — Fix #9
   ============================================================ */
.mobile-nav {
  position: fixed;
  top: 0; right: 0;
  width: min(320px, 85vw);
  height: 100dvh;
  background: var(--c-surface);
  border-left: 1px solid var(--c-border);
  z-index: 200;
  transform: translateX(100%);
  transition: transform 0.3s var(--ease);
  overflow-y: auto;
  padding: calc(var(--nav-h) + var(--sp-6)) var(--sp-6) var(--sp-8);
}
.mobile-nav.is-open { transform: translateX(0); }
@media (min-width: 700px) { .mobile-nav, .mobile-nav-overlay { display: none !important; } }

.mobile-nav-overlay {
  position: fixed;
  inset: 0;
  background: rgba(14,24,41,0.55);
  z-index: 199;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.3s var(--ease);
  backdrop-filter: blur(2px);
  -webkit-backdrop-filter: blur(2px);
}
.mobile-nav-overlay.is-visible { opacity: 1; pointer-events: auto; }

.mobile-nav-links { display: flex; flex-direction: column; gap: 0; }

.mobile-nav-link {
  display: block;
  font-family: var(--font-body);
  font-size: var(--text-lg);
  font-weight: 500;
  color: var(--c-text-muted);
  text-decoration: none;
  padding: var(--sp-4) 0;
  border-bottom: 1px solid var(--c-divider);
  transition: color var(--t-fast), padding-left var(--t-fast);
}
.mobile-nav-link:hover { color: var(--c-text); padding-left: var(--sp-2); }
.mobile-nav-link--cta {
  margin-top: var(--sp-6);
  color: var(--c-gold-d);
  border-bottom: none;
  font-weight: 600;
}

/* ============================================================
   BACK TO TOP — Fix #18
   ============================================================ */
.back-to-top {
  position: fixed;
  bottom: var(--sp-6);
  right: var(--sp-6);
  z-index: 90;
  width: 44px; height: 44px;
  border-radius: var(--r-full);
  background: var(--c-navy);
  color: var(--c-gold);
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: var(--shadow-md);
  cursor: pointer;
  transition: background var(--t-fast), transform var(--t-fast), box-shadow var(--t-fast);
  border: 1px solid rgba(196,168,130,0.3);
}
[data-theme="dark"] .back-to-top {
  background: var(--c-surface);
  border-color: var(--c-border);
}
.back-to-top:hover {
  background: var(--c-gold);
  color: var(--c-navy);
  transform: translateY(-2px);
  box-shadow: var(--shadow-lg);
}
@media (prefers-reduced-motion: reduce) { .back-to-top { transition: none; } }

/* ============================================================
   LINKEDIN FOOTER NAV LINK
   ============================================================ */
.footer-nav-linkedin {
  display: inline-flex;
  align-items: center;
  gap: var(--sp-2);
}
