/* ─────────────────────────────────────────────────────────────
   Farber Fleet — landing page
   Palette: ink #0A0E14 · slate #101623 · copper #E8833A · teal #3FD0C9
   Type: Space Grotesk (display) · Inter (body), self-hosted
   ───────────────────────────────────────────────────────────── */

@font-face {
  font-family: 'Space Grotesk';
  font-style: normal;
  font-weight: 300 700;
  font-display: swap;
  src: url('../fonts/space-grotesk-latin.woff2') format('woff2');
}
@font-face {
  font-family: 'Inter';
  font-style: normal;
  font-weight: 100 900;
  font-display: swap;
  src: url('../fonts/inter-latin.woff2') format('woff2');
}

:root {
  --ink: #0A0E14;
  --ink-2: #0E141F;
  --slate: #101623;
  --line: rgba(148, 163, 184, .14);
  --text: #EDF1F7;
  --muted: #8A94A6;
  --copper: #E8833A;
  --copper-hi: #F5A05C;
  --teal: #3FD0C9;
  --ok: #4ADE80;
  --warn: #FBBF24;
  --radius: 14px;
  --display: 'Space Grotesk', system-ui, sans-serif;
  --body: 'Inter', system-ui, -apple-system, sans-serif;
}

* { margin: 0; padding: 0; box-sizing: border-box; }
html { scroll-behavior: smooth; overflow-x: clip; }
body {
  font-family: var(--body);
  background: var(--ink);
  color: var(--text);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  overflow-x: clip;   /* clip, not hidden: kills sideways scroll without trapping wheel events */
}

/* ── backgrounds ─────────────────────────────── */
.bg-mesh, .bg-grid { position: fixed; inset: 0; pointer-events: none; z-index: 0; }
.bg-mesh {
  background:
    radial-gradient(60rem 40rem at 85% -10%, rgba(232, 131, 58, .13), transparent 60%),
    radial-gradient(50rem 36rem at -10% 25%, rgba(63, 208, 201, .08), transparent 55%),
    radial-gradient(46rem 40rem at 55% 110%, rgba(232, 131, 58, .07), transparent 60%);
}
.bg-grid {
  background-image:
    linear-gradient(rgba(148,163,184,.045) 1px, transparent 1px),
    linear-gradient(90deg, rgba(148,163,184,.045) 1px, transparent 1px);
  background-size: 44px 44px;
  mask-image: radial-gradient(70rem 50rem at 50% 0%, #000 30%, transparent 75%);
  -webkit-mask-image: radial-gradient(70rem 50rem at 50% 0%, #000 30%, transparent 75%);
}

.container { position: relative; z-index: 1; max-width: 1140px; margin: 0 auto; padding: 0 24px; }
.container.narrow { max-width: 780px; text-align: center; }

/* ── nav ─────────────────────────────────────── */
.nav {
  position: sticky; top: 0; z-index: 50;
  backdrop-filter: blur(14px);
  background: rgba(10, 14, 20, .72);
  border-bottom: 1px solid var(--line);
}
.nav-inner { display: flex; align-items: center; gap: 32px; height: 68px; }
.brand { display: flex; align-items: center; gap: 11px; text-decoration: none; color: var(--text); }
.brand-mark {
  width: 34px; height: 34px; border-radius: 9px;
  display: grid; place-items: center;
  font-family: var(--display); font-weight: 700; font-size: 19px;
  color: var(--ink);
  background: linear-gradient(135deg, var(--copper-hi), var(--copper));
}
.brand-name { font-family: var(--display); font-weight: 600; font-size: 19px; letter-spacing: .01em; }
.brand-name em { font-style: normal; color: var(--copper); }
.nav-links { display: flex; gap: 26px; margin-left: auto; }
.nav-links a { color: var(--muted); text-decoration: none; font-size: 14.5px; font-weight: 500; transition: color .18s; }
.nav-links a:hover { color: var(--text); }

/* ── buttons ─────────────────────────────────── */
.btn {
  display: inline-block; text-decoration: none; font-weight: 600;
  font-size: 15px; padding: 12px 24px; border-radius: 10px;
  transition: transform .16s, box-shadow .16s, background .16s, border-color .16s;
}
.btn-primary {
  color: #14100B;
  background: linear-gradient(135deg, var(--copper-hi), var(--copper));
  box-shadow: 0 8px 28px rgba(232, 131, 58, .28);
}
.btn-primary:hover { transform: translateY(-2px); box-shadow: 0 12px 34px rgba(232, 131, 58, .4); }
.btn-ghost { color: var(--text); border: 1px solid var(--line); background: rgba(148,163,184,.05); }
.btn-ghost:hover { border-color: rgba(232,131,58,.5); }
.btn-lg { padding: 16px 34px; font-size: 16.5px; border-radius: 12px; }

/* ── hero ────────────────────────────────────── */
.hero { padding: 88px 0 96px; }
.hero-grid { display: grid; grid-template-columns: 1.05fr .95fr; gap: 56px; align-items: center; }

.eyebrow {
  display: inline-flex; align-items: center; gap: 8px;
  font-size: 12.5px; font-weight: 600; letter-spacing: .14em; text-transform: uppercase;
  color: var(--copper);
}
.pulse-dot {
  width: 8px; height: 8px; border-radius: 50%;
  background: var(--copper);
  animation: pulse 2.2s ease-out infinite;
}
.pulse-dot.ok { background: var(--ok); }
@keyframes pulse {
  0%   { box-shadow: 0 0 0 0 rgba(232,131,58,.55); }
  70%  { box-shadow: 0 0 0 9px rgba(232,131,58,0); }
  100% { box-shadow: 0 0 0 0 rgba(232,131,58,0); }
}

h1 {
  font-family: var(--display);
  font-size: clamp(42px, 5.4vw, 64px);
  line-height: 1.06; font-weight: 700; letter-spacing: -.015em;
  margin: 18px 0 22px;
}
.grad {
  background: linear-gradient(100deg, var(--copper-hi) 10%, var(--copper) 45%, var(--teal) 105%);
  -webkit-background-clip: text; background-clip: text; color: transparent;
}
.lede { font-size: 18px; color: var(--muted); max-width: 34em; }
.hero-ctas { display: flex; gap: 14px; margin: 32px 0 42px; flex-wrap: wrap; }
.hero-stats { display: flex; gap: 42px; }
.hero-stats div { display: flex; flex-direction: column; }
.hero-stats strong { font-family: var(--display); font-size: 26px; font-weight: 700; color: var(--text); }
.hero-stats span { font-size: 13px; color: var(--muted); }

/* ── telemetry panel ─────────────────────────── */
.hero-panel { position: relative; }
.panel {
  position: relative; z-index: 2;
  background: linear-gradient(180deg, rgba(20,27,40,.92), rgba(14,20,31,.96));
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: 0 30px 80px rgba(0,0,0,.5), inset 0 1px 0 rgba(255,255,255,.05);
  overflow: hidden;
}
.panel-shadow {
  position: absolute; inset: 12% -6% -8% 6%; z-index: 1;
  background: radial-gradient(closest-side, rgba(232,131,58,.16), transparent 70%);
  filter: blur(18px);
}
.panel-head {
  display: flex; justify-content: space-between; align-items: center;
  padding: 14px 18px; border-bottom: 1px solid var(--line);
  background: rgba(148,163,184,.04);
}
.panel-title { font-family: var(--display); font-size: 12.5px; font-weight: 600; letter-spacing: .12em; color: var(--muted); }
.panel-link { display: inline-flex; align-items: center; gap: 7px; font-size: 12.5px; color: var(--ok); }
.panel-body { padding: 18px; display: flex; flex-direction: column; gap: 15px; }

.tele { display: grid; grid-template-columns: 1fr auto; gap: 3px 10px; align-items: baseline; }
.tele-label { font-size: 12.5px; color: var(--muted); letter-spacing: .03em; }
.tele-value { font-family: var(--display); font-size: 16px; font-weight: 600; font-variant-numeric: tabular-nums; }
.tele-note { grid-column: 1 / -1; font-size: 11.5px; color: var(--warn); }
.bar {
  grid-column: 1 / -1; height: 5px; border-radius: 3px;
  background: rgba(148,163,184,.12); overflow: hidden;
}
.bar i {
  display: block; height: 100%; border-radius: 3px;
  background: linear-gradient(90deg, var(--teal), #6EE7B7);
  transition: width 1.2s cubic-bezier(.2,.8,.2,1);
}
.bar.warn i { background: linear-gradient(90deg, var(--warn), var(--copper)); }
.spark { grid-column: 1 / -1; height: 28px; }
.spark svg { width: 100%; height: 100%; }
.spark polyline { stroke: var(--teal); opacity: .85; }

.tele-row { display: flex; gap: 8px; flex-wrap: wrap; }
.chip {
  font-size: 11.5px; font-weight: 600; padding: 5px 11px; border-radius: 999px;
  border: 1px solid var(--line); color: var(--muted);
}
.chip.ok { color: var(--ok); border-color: rgba(74,222,128,.25); background: rgba(74,222,128,.06); }

.panel-alert {
  display: flex; gap: 12px; align-items: flex-start;
  padding: 13px 14px; border-radius: 10px;
  background: rgba(232,131,58,.08);
  border: 1px solid rgba(232,131,58,.3);
}
.alert-ic {
  flex: none; width: 22px; height: 22px; border-radius: 6px;
  display: grid; place-items: center;
  background: var(--copper); color: #14100B;
  font-weight: 800; font-size: 14px;
}
.panel-alert strong { display: block; font-size: 13.5px; }
.panel-alert span { font-size: 12.5px; color: var(--muted); line-height: 1.45; display: block; }

/* ── sections ────────────────────────────────── */
.section { padding: 96px 0; position: relative; }
.section.dim { background: linear-gradient(180deg, transparent, rgba(16,22,35,.55) 18% 82%, transparent); }
.section h2 {
  font-family: var(--display);
  font-size: clamp(30px, 3.6vw, 42px);
  font-weight: 700; letter-spacing: -.01em; line-height: 1.15;
  margin: 14px 0 18px;
}
.section > .container > p, .problem p { color: var(--muted); }
.problem h2 { margin-top: 0; }
.problem p { font-size: 17.5px; }
.problem strong { color: var(--text); }

/* ── cards ───────────────────────────────────── */
.cards3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 22px; margin-top: 44px; }
.card {
  background: linear-gradient(180deg, rgba(20,27,40,.7), rgba(14,20,31,.85));
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 30px 28px;
  transition: transform .22s, border-color .22s, box-shadow .22s;
}
.card:hover {
  transform: translateY(-5px);
  border-color: rgba(232,131,58,.35);
  box-shadow: 0 20px 50px rgba(0,0,0,.35);
}
.card-ic {
  width: 46px; height: 46px; border-radius: 12px;
  display: grid; place-items: center; margin-bottom: 20px;
  color: var(--copper);
  background: rgba(232,131,58,.1);
  border: 1px solid rgba(232,131,58,.25);
}
.card-ic svg { width: 23px; height: 23px; }
.card h3 { font-family: var(--display); font-size: 20px; font-weight: 600; margin-bottom: 10px; }
.card p { font-size: 14.5px; color: var(--muted); }

/* ── telemetry grid ──────────────────────────── */
.tgrid { display: grid; grid-template-columns: repeat(5, 1fr); gap: 14px; margin-top: 44px; }
.tcell {
  padding: 20px 18px; border-radius: 12px;
  border: 1px solid var(--line);
  background: rgba(16,22,35,.6);
  transition: border-color .2s, background .2s;
}
.tcell:hover { border-color: rgba(63,208,201,.4); background: rgba(63,208,201,.05); }
.tcell strong { display: block; font-family: var(--display); font-size: 15px; font-weight: 600; margin-bottom: 4px; }
.tcell span { font-size: 12.5px; color: var(--muted); line-height: 1.4; display: block; }
.tgrid-note { margin-top: 32px; font-size: 15px; color: var(--muted); max-width: 46em; }

/* ── split sections ──────────────────────────── */
.split { display: grid; grid-template-columns: 1fr 1fr; gap: 64px; align-items: center; }
.split-copy .eyebrow { margin-bottom: 4px; }
.split-copy p { color: var(--muted); font-size: 16px; }
.checklist { list-style: none; margin-top: 24px; display: flex; flex-direction: column; gap: 12px; }
.checklist li { position: relative; padding-left: 30px; font-size: 15.5px; }
.checklist li::before {
  content: ''; position: absolute; left: 0; top: 4px;
  width: 18px; height: 18px; border-radius: 6px;
  background: rgba(63,208,201,.12);
  border: 1px solid rgba(63,208,201,.45);
}
.checklist li::after {
  content: ''; position: absolute; left: 5px; top: 8px;
  width: 8px; height: 5px;
  border-left: 2px solid var(--teal); border-bottom: 2px solid var(--teal);
  transform: rotate(-45deg);
}

/* chat demo */
.chat { display: flex; flex-direction: column; gap: 14px; }
.chat-q {
  align-self: flex-end;
  background: linear-gradient(135deg, var(--copper-hi), var(--copper));
  color: #14100B; font-weight: 600; font-size: 14.5px;
  padding: 13px 18px; border-radius: 16px 16px 4px 16px;
  max-width: 82%;
  box-shadow: 0 10px 30px rgba(232,131,58,.25);
}
.chat-a {
  background: linear-gradient(180deg, rgba(20,27,40,.9), rgba(14,20,31,.95));
  border: 1px solid var(--line);
  border-radius: 16px 16px 16px 4px;
  padding: 18px 20px; font-size: 14px;
  box-shadow: 0 22px 60px rgba(0,0,0,.4);
}
.chat-src {
  display: block; font-size: 11.5px; font-weight: 600; letter-spacing: .06em;
  text-transform: uppercase; color: var(--teal); margin-bottom: 10px;
}
.chat-a ol { margin: 0 0 10px 18px; display: flex; flex-direction: column; gap: 6px; color: var(--text); }
.chat-more { color: var(--copper); font-weight: 600; font-size: 13.5px; }

/* route map */
.routemap {
  background: linear-gradient(180deg, rgba(20,27,40,.85), rgba(14,20,31,.95));
  border: 1px solid var(--line); border-radius: var(--radius);
  padding: 22px; box-shadow: 0 26px 70px rgba(0,0,0,.45);
}
.routemap svg { width: 100%; height: auto; display: block; }
.map-dots circle { fill: rgba(148,163,184,.2); }
.stops circle { fill: var(--teal); }
.stops circle.depot { fill: var(--copper); }
.route { animation: dashmove 3.2s linear infinite; }
@keyframes dashmove { to { stroke-dashoffset: -26; } }
.routemap-tag {
  margin-top: 14px; text-align: center;
  font-size: 13px; font-weight: 600; color: var(--muted);
  letter-spacing: .04em;
}

/* ── plans ───────────────────────────────────── */
.plans { align-items: stretch; }
.plan { position: relative; display: flex; flex-direction: column; }
.plan-tag { font-size: 12.5px !important; text-transform: uppercase; letter-spacing: .1em; color: var(--copper) !important; font-weight: 600; margin: -4px 0 14px; }
.plan ul { list-style: none; display: flex; flex-direction: column; gap: 10px; }
.plan li { font-size: 14.5px; color: var(--muted); padding-left: 22px; position: relative; }
.plan li::before { content: '—'; position: absolute; left: 0; color: var(--copper); }
.plan.featured {
  border-color: rgba(232,131,58,.5);
  background: linear-gradient(180deg, rgba(232,131,58,.09), rgba(14,20,31,.9) 45%);
  box-shadow: 0 24px 60px rgba(0,0,0,.4);
}
.plan-flag {
  position: absolute; top: -13px; left: 50%; transform: translateX(-50%);
  font-size: 11.5px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase;
  background: linear-gradient(135deg, var(--copper-hi), var(--copper));
  color: #14100B; padding: 5px 14px; border-radius: 999px;
}

/* ── CTA & footer ────────────────────────────── */
.cta { padding: 120px 0; }
.cta h2 { margin-bottom: 16px; }
.cta p { font-size: 17px; margin-bottom: 34px; }
.cta-sub { margin-top: 18px !important; font-size: 14px !important; color: var(--muted); }

/* ── contact form ────────────────────────────── */
.cform {
  max-width: 760px; margin: 0 auto;
  background: linear-gradient(180deg, rgba(20,27,40,.75), rgba(14,20,31,.9));
  border: 1px solid var(--line); border-radius: var(--radius);
  padding: 34px; box-shadow: 0 26px 70px rgba(0,0,0,.4);
}
.cform-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; }
.cform label { display: flex; flex-direction: column; gap: 7px; font-size: 13.5px; font-weight: 600; color: var(--text); }
.cform .opt { color: var(--muted); font-weight: 400; }
.cform input, .cform textarea {
  font: 15px/1.5 var(--body); color: var(--text);
  background: rgba(10,14,20,.6);
  border: 1px solid var(--line); border-radius: 10px;
  padding: 12px 14px; outline: none;
  transition: border-color .18s, box-shadow .18s;
}
.cform input:focus, .cform textarea:focus {
  border-color: rgba(232,131,58,.6);
  box-shadow: 0 0 0 3px rgba(232,131,58,.15);
}
.cform textarea { resize: vertical; }
.cform-msg { margin-top: 18px; }
.cform .hp { position: absolute; left: -9999px; width: 1px; height: 1px; opacity: 0; }
.cform-actions { display: flex; align-items: center; gap: 18px; margin-top: 24px; flex-wrap: wrap; }
.cform-actions button { border: 0; cursor: pointer; font-family: var(--body); }
.cform-actions button[disabled] { opacity: .6; cursor: wait; transform: none; }
#cform-status { font-size: 14px; color: var(--warn); }
.cform-done {
  max-width: 760px; margin: 0 auto; text-align: center;
  background: rgba(74,222,128,.06);
  border: 1px solid rgba(74,222,128,.35); border-radius: var(--radius);
  padding: 48px 34px;
}
.cform-done h3 { font-family: var(--display); font-size: 24px; color: var(--ok); margin-bottom: 10px; }
.cform-done p { color: var(--muted); margin: 0 !important; }
@media (max-width: 980px) {
  .cform-grid { grid-template-columns: 1fr; }
  .cform { padding: 24px; }
}
.footer { border-top: 1px solid var(--line); padding: 30px 0; }
.footer-inner { display: flex; justify-content: space-between; flex-wrap: wrap; gap: 10px; font-size: 13px; color: var(--muted); }
.footer strong { color: var(--text); }

/* ── knowledgebase ───────────────────────────── */
.kb-hero { padding: 72px 0 40px; text-align: center; }
.kb-hero .eyebrow { justify-content: center; }
.ffu-mark {
  display: inline-grid; place-items: center;
  width: 26px; height: 26px; border-radius: 7px;
  font-family: var(--display); font-weight: 700; font-size: 11px; letter-spacing: 0;
  color: var(--ink);
  background: linear-gradient(135deg, var(--copper-hi), var(--copper));
}
.kb-hero-sm { text-align: left; padding: 56px 0 8px; }
.kb-h1 {
  font-family: var(--display);
  font-size: clamp(34px, 4.4vw, 52px);
  line-height: 1.08; font-weight: 700; letter-spacing: -.015em;
  margin: 14px 0 18px;
}
.kb-hero .lede, .kb-hero-sm .lede { margin: 0 auto; }
.kb-hero-sm .lede { margin-left: 0; }
.kb-search { display: flex; gap: 10px; max-width: 620px; margin: 30px auto 0; }
.kb-search input {
  flex: 1; font: 15.5px var(--body); color: var(--text);
  background: rgba(16,22,35,.8);
  border: 1px solid var(--line); border-radius: 12px;
  padding: 14px 18px; outline: none;
  transition: border-color .18s, box-shadow .18s;
}
.kb-search input:focus { border-color: rgba(232,131,58,.6); box-shadow: 0 0 0 3px rgba(232,131,58,.15); }
.kb-search button { border: 0; cursor: pointer; font-family: var(--body); }

.kb-crumb { font-size: 13.5px; color: var(--muted); margin-bottom: 4px; }
.kb-crumb a { color: var(--copper); text-decoration: none; }
.kb-crumb span { margin: 0 6px; opacity: .6; }

.kb-cats { display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px; }
.kb-cat {
  display: flex; flex-direction: column; gap: 6px;
  padding: 26px 24px; border-radius: var(--radius);
  background: linear-gradient(180deg, rgba(20,27,40,.7), rgba(14,20,31,.85));
  border: 1px solid var(--line);
  text-decoration: none; color: var(--text);
  transition: transform .2s, border-color .2s;
}
.kb-cat:hover { transform: translateY(-4px); border-color: rgba(232,131,58,.4); }
.kb-cat strong { font-family: var(--display); font-size: 18px; }
.kb-cat span { font-size: 13.5px; color: var(--muted); }
.kb-cat em { font-style: normal; font-size: 12px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: var(--copper); margin-top: 8px; }

.kb-list { display: flex; flex-direction: column; gap: 12px; max-width: 860px; }
.kb-row {
  display: flex; flex-direction: column; gap: 4px;
  padding: 20px 22px; border-radius: 12px;
  background: rgba(16,22,35,.6); border: 1px solid var(--line);
  text-decoration: none; color: var(--text);
  transition: border-color .18s, background .18s;
}
.kb-row:hover { border-color: rgba(63,208,201,.45); background: rgba(63,208,201,.05); }
.kb-row-cat { font-size: 11.5px; font-weight: 700; letter-spacing: .09em; text-transform: uppercase; color: var(--teal); }
.kb-row strong { font-family: var(--display); font-size: 17px; }
.kb-row-sum { font-size: 14px; color: var(--muted); }
.kb-results h2 { margin-bottom: 20px; }
.kb-empty { color: var(--muted); }
.kb-empty a { color: var(--copper); }

.kb-article { padding: 40px 0 90px; }
.kb-article-grid { display: grid; grid-template-columns: minmax(0, 1fr) 260px; gap: 56px; align-items: start; }
.kb-main .kb-h1 { font-size: clamp(28px, 3.4vw, 40px); }
.kb-main h2 {
  font-family: var(--display); font-size: 24px; font-weight: 700;
  margin: 44px 0 16px; padding-top: 8px;
  letter-spacing: -.01em;
}
.kb-body h2 { margin: 36px 0 14px; }
.kb-body h3 { font-family: var(--display); font-size: 18px; margin: 26px 0 10px; }
.kb-body p, .kb-body li { color: #C4CBD8; font-size: 15.5px; }
.kb-body p { margin: 0 0 14px; }
.kb-body ul, .kb-body ol { margin: 0 0 16px 22px; display: flex; flex-direction: column; gap: 6px; }
.kb-body table { border-collapse: collapse; margin: 0 0 18px; width: 100%; font-size: 14px; }
.kb-body th, .kb-body td { border: 1px solid var(--line); padding: 8px 12px; text-align: left; }
.kb-body th { background: rgba(148,163,184,.06); font-family: var(--display); }

.kb-tablewrap { overflow-x: auto; border-radius: 12px; border: 1px solid var(--line); }
.kb-table { width: 100%; border-collapse: collapse; font-size: 14px; }
.kb-table th, .kb-table td { padding: 12px 14px; text-align: left; border-bottom: 1px solid var(--line); vertical-align: top; }
.kb-table th { font-family: var(--display); font-size: 12.5px; letter-spacing: .08em; text-transform: uppercase; color: var(--muted); background: rgba(148,163,184,.05); }
.kb-table tr:last-child td { border-bottom: 0; }
.kb-table td { color: #C4CBD8; }
.kb-nowrap { white-space: nowrap; }

.kb-trouble { display: flex; flex-direction: column; gap: 10px; }
.kb-symptom {
  border: 1px solid var(--line); border-radius: 12px;
  background: rgba(16,22,35,.6);
  overflow: hidden;
}
.kb-symptom summary {
  cursor: pointer; padding: 15px 18px;
  font-family: var(--display); font-weight: 600; font-size: 15px;
  list-style: none; position: relative;
}
.kb-symptom summary::after { content: '+'; position: absolute; right: 18px; color: var(--copper); font-size: 18px; }
.kb-symptom[open] summary::after { content: '–'; }
.kb-symptom ol { margin: 0 18px 16px 38px; display: flex; flex-direction: column; gap: 8px; font-size: 14.5px; color: #C4CBD8; }

.kb-source { margin-top: 34px; font-size: 12.5px; color: var(--muted); border-top: 1px solid var(--line); padding-top: 16px; }
.kb-cta {
  margin-top: 28px; padding: 22px 24px; border-radius: var(--radius);
  border: 1px solid rgba(232,131,58,.35);
  background: rgba(232,131,58,.07);
  display: flex; flex-wrap: wrap; align-items: center; gap: 8px 16px;
}
.kb-cta strong { font-family: var(--display); }
.kb-cta span { color: var(--muted); font-size: 14px; flex: 1; min-width: 200px; }

.kb-side { position: sticky; top: 92px; }
.kb-side h3 { font-family: var(--display); font-size: 13px; letter-spacing: .1em; text-transform: uppercase; color: var(--muted); margin: 22px 0 10px; }
.kb-side h3:first-child { margin-top: 0; }
.kb-side ul { list-style: none; display: flex; flex-direction: column; gap: 8px; }
.kb-side a { color: var(--text); text-decoration: none; font-size: 14px; }
.kb-side a:hover { color: var(--copper); }

@media (max-width: 980px) {
  .kb-cats { grid-template-columns: 1fr; }
  .kb-article-grid { grid-template-columns: 1fr; gap: 24px; }
  .kb-side { position: static; order: -1; display: none; }
  .kb-search { flex-direction: column; }
}

/* ── employee portal ─────────────────────────── */
.login-wrap { min-height: 100vh; display: grid; place-items: center; padding: 24px; }
.login-card {
  width: min(440px, 100%);
  background: linear-gradient(180deg, rgba(20,27,40,.85), rgba(14,20,31,.95));
  border: 1px solid var(--line); border-radius: var(--radius);
  padding: 40px 36px; box-shadow: 0 30px 80px rgba(0,0,0,.5);
  display: flex; flex-direction: column; gap: 16px;
}
.login-card h1 { font-family: var(--display); font-size: 26px; margin-top: 6px; }
.login-sub { color: var(--muted); font-size: 14.5px; }
.login-ok { color: var(--ok); font-size: 14.5px; }
.login-err { color: #F87171; font-size: 14.5px; }
.login-card form { display: flex; flex-direction: column; gap: 12px; }
.login-card input {
  font: 15px var(--body); color: var(--text);
  background: rgba(10,14,20,.6); border: 1px solid var(--line);
  border-radius: 10px; padding: 13px 15px; outline: none;
}
.login-card input:focus { border-color: rgba(232,131,58,.6); }
.login-card .btn { border: 0; cursor: pointer; }

.app-body { background: var(--ink); }
.app-shell { display: grid; grid-template-columns: 232px 1fr; min-height: 100vh; }
.app-side {
  position: sticky; top: 0; height: 100vh;
  display: flex; flex-direction: column;
  background: rgba(14,20,31,.9);
  border-right: 1px solid var(--line);
  padding: 18px 14px;
  z-index: 5;
}
.app-brand { margin: 4px 8px 18px; }
.app-nav { display: flex; flex-direction: column; gap: 2px; flex: 1; overflow-y: auto; }
.app-nav a {
  color: var(--muted); text-decoration: none;
  font-size: 14px; font-weight: 500;
  padding: 8px 12px; border-radius: 8px;
  transition: background .15s, color .15s;
}
.app-nav a:hover { color: var(--text); background: rgba(148,163,184,.07); }
.app-nav a.active { color: var(--copper-hi); background: rgba(232,131,58,.1); }
.app-nav-h {
  font-size: 10.5px; font-weight: 700; letter-spacing: .12em; text-transform: uppercase;
  color: rgba(138,148,166,.6); margin: 14px 12px 4px;
}
.app-side-foot { border-top: 1px solid var(--line); padding-top: 12px; display: flex; align-items: center; justify-content: space-between; gap: 8px; }
.app-user { font-size: 13px; color: var(--text); font-weight: 600; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.app-logout { background: none; border: 0; color: var(--muted); font: 12.5px var(--body); cursor: pointer; }
.app-logout:hover { color: var(--copper); }
.app-main { padding: 30px 36px 60px; min-width: 0; }

.pg-head { display: flex; align-items: flex-start; gap: 18px; margin-bottom: 24px; flex-wrap: wrap; }
.pg-head h1 { font-family: var(--display); font-size: 27px; font-weight: 700; letter-spacing: -.01em; }
.pg-head > div:first-child { flex: 1; min-width: 240px; }
.pg-sub { color: var(--muted); font-size: 13.5px; }
.pg-sub a { color: var(--copper); text-decoration: none; }
.pg-tools { display: flex; gap: 10px; align-items: center; }
.pg-h2 { font-family: var(--display); font-size: 19px; margin: 30px 0 12px; }

.pg-tools input, .pg-tools select, .inline-form input, .inline-form select, .inline-form textarea,
.stage-form select, .stage-form input, .inline-mini select {
  font: 13.5px var(--body); color: var(--text);
  background: rgba(10,14,20,.6); border: 1px solid var(--line);
  border-radius: 8px; padding: 9px 12px; outline: none;
}
.pg-tools input:focus, .inline-form input:focus, .inline-form textarea:focus { border-color: rgba(232,131,58,.55); }
.inline-form {
  display: flex; gap: 10px; flex-wrap: wrap; align-items: center;
  padding: 14px; border: 1px solid var(--line); border-radius: 12px;
  background: rgba(16,22,35,.5); margin-bottom: 16px;
}
.inline-form .btn { border: 0; cursor: pointer; padding: 9px 18px; font-size: 13.5px; }
.inline-mini { display: inline; }
.stage-form { display: flex; gap: 8px; flex-wrap: wrap; }
.stage-form .btn { border: 0; cursor: pointer; padding: 9px 16px; font-size: 13.5px; }

.stat-row { display: grid; grid-template-columns: repeat(4, 1fr); gap: 14px; margin-bottom: 26px; }
.stat {
  padding: 16px 18px; border-radius: 12px;
  border: 1px solid var(--line); background: rgba(16,22,35,.6);
}
.stat strong { display: block; font-family: var(--display); font-size: 24px; font-weight: 700; }
.stat span { font-size: 12px; color: var(--muted); }
.stat.warn { border-color: rgba(251,191,36,.45); background: rgba(251,191,36,.06); }

.grid2 { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; align-items: start; }
.panel2 {
  border: 1px solid var(--line); border-radius: var(--radius);
  background: rgba(16,22,35,.5); padding: 22px;
}
.panel2 h2 { font-family: var(--display); font-size: 16.5px; margin-bottom: 12px; }
.panel-note { font-size: 13px; color: var(--muted); margin-top: 10px; }
.panel-note a { color: var(--copper); }

.tbl { width: 100%; border-collapse: collapse; font-size: 13.5px; }
.tbl th {
  text-align: left; font-family: var(--display); font-size: 11px;
  letter-spacing: .09em; text-transform: uppercase; color: var(--muted);
  padding: 9px 12px; border-bottom: 1px solid var(--line);
}
.tbl td { padding: 10px 12px; border-bottom: 1px solid rgba(148,163,184,.08); vertical-align: top; }
.tbl tr:last-child td { border-bottom: 0; }
.tbl a { color: var(--copper-hi); text-decoration: none; }
.tbl a:hover { text-decoration: underline; }
.tbl-empty { color: var(--muted); font-style: italic; }
.tbl.kv td:first-child { color: var(--muted); width: 40%; }
.mono { font-family: ui-monospace, 'Cascadia Mono', monospace; font-size: 12.5px; }

.badge {
  display: inline-block; font-size: 11px; font-weight: 700;
  letter-spacing: .05em; text-transform: uppercase;
  padding: 3px 10px; border-radius: 999px;
  border: 1px solid var(--line); color: var(--muted);
}
.badge.ok { color: var(--ok); border-color: rgba(74,222,128,.35); background: rgba(74,222,128,.07); }
.badge.bad { color: #F87171; border-color: rgba(248,113,113,.35); background: rgba(248,113,113,.07); }
.badge.stage.s0 { color: var(--teal); border-color: rgba(63,208,201,.35); }
.badge.stage.s1, .badge.stage.s2 { color: var(--copper-hi); border-color: rgba(232,131,58,.4); }
.badge.stage.s3, .badge.stage.s4 { color: var(--warn); border-color: rgba(251,191,36,.4); }
.badge.stage.s5 { color: var(--ok); border-color: rgba(74,222,128,.4); }
.badge.stage.s6 { color: #F87171; border-color: rgba(248,113,113,.4); }

.mini-btn {
  font: 600 11.5px var(--body); padding: 5px 12px; border-radius: 7px;
  background: rgba(148,163,184,.08); color: var(--text);
  border: 1px solid var(--line); cursor: pointer; margin-right: 4px;
}
.mini-btn.ok { color: var(--ok); border-color: rgba(74,222,128,.35); }
.mini-btn.bad { color: #F87171; border-color: rgba(248,113,113,.35); }
.mini-btn:hover { background: rgba(148,163,184,.15); }

.kanban { display: grid; grid-template-columns: repeat(5, 1fr); gap: 12px; align-items: start; }
.kan-col { border: 1px solid var(--line); border-radius: 12px; background: rgba(16,22,35,.45); padding: 10px; min-height: 120px; }
.kan-head { display: flex; justify-content: space-between; align-items: baseline; padding: 4px 6px 10px; }
.kan-head strong { font-family: var(--display); font-size: 13.5px; }
.kan-head span { font-size: 11.5px; color: var(--muted); }
.kan-card {
  display: flex; flex-direction: column; gap: 3px;
  background: rgba(20,27,40,.85); border: 1px solid var(--line);
  border-radius: 10px; padding: 11px 12px; margin-bottom: 8px;
  text-decoration: none; color: var(--text);
  transition: border-color .15s, transform .15s;
}
.kan-card:hover { border-color: rgba(232,131,58,.45); transform: translateY(-2px); }
.kan-card strong { font-size: 13.5px; line-height: 1.35; }
.kan-co { font-size: 11.5px; color: var(--teal); }
.kan-meta { font-size: 11.5px; color: var(--muted); }
.kan-empty { text-align: center; color: rgba(138,148,166,.4); padding: 16px 0; }

/* dashboard v2 */
.kpi-row { display: grid; grid-template-columns: 2fr 1fr 1fr 1fr; gap: 14px; margin-bottom: 22px; }
.kpi {
  display: flex; flex-direction: column; gap: 3px;
  padding: 18px 20px; border-radius: var(--radius);
  border: 1px solid var(--line);
  background: linear-gradient(180deg, rgba(20,27,40,.7), rgba(14,20,31,.85));
}
.kpi-label { font-size: 11px; font-weight: 700; letter-spacing: .1em; text-transform: uppercase; color: var(--muted); }
.kpi strong { font-family: var(--display); font-size: 30px; font-weight: 700; letter-spacing: -.01em; font-variant-numeric: tabular-nums; }
.kpi-sub { font-size: 12.5px; color: var(--muted); }
.kpi-foot { font-size: 11px; color: rgba(138,148,166,.7); margin-top: 2px; }
.kpi.warn { border-color: rgba(251,191,36,.4); }
.hero-kpi { grid-row: span 1; }
.kpi-spark { width: 100%; height: 52px; margin-top: 8px; }
.dash-split { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; }
.donut-wrap { display: flex; gap: 16px; align-items: center; }
.donut-wrap path { transition: stroke-width .15s; }
.donut-wrap path:hover { stroke-width: 22; }
.donut-legend { list-style: none; display: flex; flex-direction: column; gap: 7px; font-size: 12.5px; }
.donut-legend i { display: inline-block; width: 10px; height: 10px; border-radius: 3px; margin-right: 7px; }
.donut-legend em { font-style: normal; color: var(--muted); margin-left: 6px; font-variant-numeric: tabular-nums; }
.rep-bars { display: flex; flex-direction: column; gap: 8px; }
.rep-row { display: grid; grid-template-columns: 64px 1fr auto; gap: 10px; align-items: center; }
.rep-name { font-size: 12.5px; color: var(--muted); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.rep-bar { height: 14px; background: rgba(148,163,184,.08); border-radius: 4px; overflow: hidden; }
.rep-bar i { display: block; height: 100%; background: #149E90; border-radius: 4px; }
.rep-n { font-size: 12px; font-variant-numeric: tabular-nums; }
.funnel-row:hover .funnel-bar i { filter: brightness(1.18); }
@media (max-width: 1100px) { .kpi-row { grid-template-columns: 1fr 1fr; } .dash-split { grid-template-columns: 1fr; } }

/* vehicle telemetry grid */
.tele-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 12px; }
.tele-cell {
  display: flex; flex-direction: column; gap: 2px;
  padding: 12px 14px; border-radius: 10px;
  border: 1px solid var(--line); background: rgba(10,14,20,.5);
}
.tele-cell .tele-label { font-size: 11px; color: var(--muted); letter-spacing: .04em; }
.tele-cell .tele-value { font-family: var(--display); font-size: 17px; font-weight: 600; font-variant-numeric: tabular-nums; }
.tele-cell em { font-style: normal; font-size: 10.5px; color: rgba(138,148,166,.7); }
.tele-spark { width: 100%; height: 24px; margin: 3px 0 1px; }
.tele-spark polyline { stroke: #149E90; opacity: .9; }

.funnel { display: flex; flex-direction: column; gap: 8px; }
.funnel-row { display: grid; grid-template-columns: 120px 1fr auto; gap: 12px; align-items: center; text-decoration: none; }
.funnel-label { font-size: 12.5px; color: var(--muted); }
.funnel-bar { height: 18px; background: rgba(148,163,184,.08); border-radius: 5px; overflow: hidden; }
.funnel-bar i { display: block; height: 100%; background: linear-gradient(90deg, var(--copper), var(--copper-hi)); border-radius: 5px; }
.funnel-n { font-size: 12px; color: var(--text); font-variant-numeric: tabular-nums; }

.feed { display: flex; flex-direction: column; gap: 10px; }
.feed-item { display: flex; gap: 10px; align-items: flex-start; }
.feed-kind {
  flex: none; font-size: 10px; font-weight: 700; text-transform: uppercase; letter-spacing: .06em;
  padding: 3px 8px; border-radius: 6px; margin-top: 2px;
  background: rgba(148,163,184,.1); color: var(--muted);
}
.feed-kind.k1 { color: var(--teal); } .feed-kind.k2 { color: var(--copper-hi); }
.feed-kind.k3 { color: var(--warn); } .feed-kind.k4 { color: var(--ok); }
.feed-item div { display: flex; flex-direction: column; font-size: 13px; }
.feed-item a { color: var(--copper-hi); text-decoration: none; font-weight: 600; }
.feed-item span { color: #C4CBD8; }
.feed-item em { font-style: normal; font-size: 11.5px; color: var(--muted); }

@media (max-width: 1100px) {
  .stat-row { grid-template-columns: repeat(2, 1fr); }
  .kanban { grid-template-columns: 1fr 1fr; }
  .grid2 { grid-template-columns: 1fr; }
}
@media (max-width: 760px) {
  .app-shell { grid-template-columns: 1fr; }
  .app-side { position: static; height: auto; flex-direction: row; align-items: center; overflow-x: auto; }
  .app-nav { flex-direction: row; }
  .app-nav-h { display: none; }
  .app-main { padding: 20px 16px 50px; }
  .kanban { grid-template-columns: 1fr; }
}

/* ── reveal animation ────────────────────────── */
.reveal { opacity: 0; transform: translateY(22px); transition: opacity .7s ease, transform .7s cubic-bezier(.2,.8,.2,1); }
.reveal.in { opacity: 1; transform: none; }

@media (prefers-reduced-motion: reduce) {
  .reveal { opacity: 1; transform: none; transition: none; }
  .route { animation: none; }
  .pulse-dot { animation: none; }
  html { scroll-behavior: auto; }
}

/* ── responsive ──────────────────────────────── */
@media (max-width: 980px) {
  .hero-grid, .split { grid-template-columns: 1fr; gap: 44px; }
  .split.rev .split-demo { order: 2; }
  .cards3 { grid-template-columns: 1fr; }
  .tgrid { grid-template-columns: repeat(2, 1fr); }
  .nav-links { display: none; }
  .hero { padding: 56px 0 72px; }
  .section { padding: 68px 0; }
  .hero-stats { gap: 26px; }
}
