/* HaulGuard Portal — design system
   Palette: navy #0B1220 · corporate #163B65 · canvas #F4F7FB · white · green #24C78B · amber #F59E0B · red #EF4444 */

@font-face {
  font-family: 'Inter';
  src: url('/fonts/inter-latin-var.woff2') format('woff2-variations'), url('/fonts/inter-latin-var.woff2') format('woff2');
  font-weight: 100 900;
  font-style: normal;
  font-display: swap;
}

:root {
  --navy: #0B1220;
  --navy-2: #111A2E;
  --navy-3: #1A2540;
  --corp: #163B65;
  --corp-2: #1E4D82;
  --corp-50: #EAF1F9;
  --canvas: #F4F7FB;
  --white: #FFFFFF;
  --green: #24C78B;
  --green-50: #E6F8F1;
  --green-700: #0F8A5C;
  --amber: #F59E0B;
  --amber-50: #FEF5E6;
  --amber-700: #A16207;
  --red: #EF4444;
  --red-50: #FDECEC;
  --red-700: #B91C1C;
  --slate-50: #F8FAFC;
  --slate-100: #EEF2F7;
  --slate-200: #E3E8F0;
  --slate-300: #CBD4E1;
  --slate-400: #94A3B8;
  --slate-500: #64748B;
  --slate-600: #475569;
  --slate-700: #334155;
  --text: #0B1220;
  --muted: #5B6B82;
  --border: #E3E8F0;
  --radius: 14px;
  --radius-sm: 10px;
  --shadow-sm: 0 1px 2px rgba(11, 18, 32, 0.04), 0 1px 3px rgba(11, 18, 32, 0.04);
  --shadow: 0 1px 2px rgba(11, 18, 32, 0.04), 0 8px 24px -12px rgba(11, 18, 32, 0.12);
  --shadow-lg: 0 24px 60px -20px rgba(11, 18, 32, 0.35);
  --sidebar-w: 256px;
  --font: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
  --mono: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  --ease: cubic-bezier(.2, .7, .2, 1);
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  font-family: var(--font);
  font-size: 15px;
  line-height: 1.5;
  color: var(--text);
  background: var(--canvas);
  font-feature-settings: 'cv11', 'ss01', 'tnum';
  -webkit-font-smoothing: antialiased;
}
a { color: var(--corp); text-decoration: none; }
a:hover { color: var(--corp-2); text-decoration: underline; }
h1, h2, h3, h4 { margin: 0; line-height: 1.2; letter-spacing: -0.01em; }
p { margin: 0; }
svg { flex-shrink: 0; }
button, input, select, textarea { font: inherit; color: inherit; }
:focus-visible { outline: 3px solid rgba(22, 59, 101, 0.35); outline-offset: 2px; border-radius: 6px; }
.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; }
.hidden { display: none !important; }
.mono { font-family: var(--mono); font-size: 0.92em; }
.muted { color: var(--muted); }
.small { font-size: 13px; }
.nowrap { white-space: nowrap; }
.right { text-align: right; }

/* ------------------------------------------------------------------ Buttons */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  height: 40px; padding: 0 16px; border-radius: 10px; border: 1px solid transparent;
  font-weight: 600; font-size: 14px; letter-spacing: 0.01em; cursor: pointer; white-space: nowrap;
  transition: background .15s var(--ease), border-color .15s var(--ease), transform .1s var(--ease), box-shadow .15s var(--ease);
  text-decoration: none !important;
}
.btn:active { transform: translateY(1px); }
.btn:disabled { opacity: .55; cursor: not-allowed; }
.btn svg { width: 18px; height: 18px; }
.btn-primary { background: var(--corp); color: #fff; box-shadow: 0 1px 2px rgba(22, 59, 101, .3); }
.btn-primary:hover { background: var(--corp-2); color: #fff; }
.btn-success { background: var(--green); color: #052E1F; }
.btn-success:hover { background: #1FB57E; color: #052E1F; }
.btn-secondary { background: #fff; border-color: var(--slate-200); color: var(--navy); }
.btn-secondary:hover { border-color: var(--slate-300); background: var(--slate-50); color: var(--navy); }
.btn-ghost { background: transparent; color: var(--corp); }
.btn-ghost:hover { background: var(--corp-50); color: var(--corp); }
.btn-danger { background: #fff; border-color: #F6C3C3; color: var(--red-700); }
.btn-danger:hover { background: var(--red-50); color: var(--red-700); }
.btn-sm { height: 32px; padding: 0 12px; font-size: 13px; border-radius: 8px; }
.btn-sm svg { width: 16px; height: 16px; }
.btn-block { width: 100%; height: 46px; font-size: 15px; }
.btn-icon { width: 38px; padding: 0; }
.btn.loading { position: relative; color: transparent !important; pointer-events: none; }
.btn.loading::after {
  content: ''; position: absolute; width: 18px; height: 18px; border-radius: 50%;
  border: 2px solid rgba(255, 255, 255, .45); border-top-color: #fff; animation: spin .7s linear infinite;
}
.btn-secondary.loading::after, .btn-danger.loading::after, .btn-ghost.loading::after { border-color: var(--slate-200); border-top-color: var(--corp); }
@keyframes spin { to { transform: rotate(360deg); } }

/* ------------------------------------------------------------------ Forms */
.field { display: flex; flex-direction: column; gap: 6px; }
.field label, .label { font-size: 13px; font-weight: 600; color: var(--slate-700); }
.field .hint { font-size: 12px; color: var(--muted); }
.input, select.input, textarea.input {
  height: 42px; width: 100%; padding: 0 12px; border: 1px solid var(--slate-200); border-radius: 10px;
  background: #fff; transition: border-color .15s, box-shadow .15s; font-size: 14.5px;
}
textarea.input { height: auto; min-height: 96px; padding: 10px 12px; resize: vertical; line-height: 1.5; }
.input:hover { border-color: var(--slate-300); }
.input:focus { outline: none; border-color: var(--corp); box-shadow: 0 0 0 4px rgba(22, 59, 101, .12); }
.input.invalid { border-color: var(--red); box-shadow: 0 0 0 4px rgba(239, 68, 68, .1); }
.input-group { position: relative; }
.input-group .input { padding-right: 44px; }
.input-group .toggle-visibility {
  position: absolute; right: 4px; top: 4px; height: 34px; width: 36px; border: 0; background: transparent;
  border-radius: 8px; color: var(--slate-500); cursor: pointer; display: grid; place-items: center;
}
.input-group .toggle-visibility:hover { background: var(--slate-100); }
.input-prefix { position: relative; }
.input-prefix span { position: absolute; left: 12px; top: 50%; transform: translateY(-50%); color: var(--muted); font-weight: 600; }
.input-prefix .input { padding-left: 26px; }
.form-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; }
.form-grid .span-2 { grid-column: span 2; }
.form-section-title { grid-column: 1 / -1; font-size: 12px; font-weight: 700; text-transform: uppercase; letter-spacing: .08em; color: var(--slate-500); margin-top: 8px; padding-top: 12px; border-top: 1px solid var(--slate-100); }
.form-error { display: none; padding: 10px 12px; border-radius: 10px; background: var(--red-50); color: var(--red-700); font-size: 14px; border: 1px solid #F8CACA; }
.form-error.show { display: flex; gap: 8px; align-items: flex-start; }
.form-success { padding: 12px 14px; border-radius: 10px; background: var(--green-50); color: #065F46; font-size: 14px; border: 1px solid #BDEBD9; }
.checkbox { display: flex; align-items: flex-start; gap: 10px; font-size: 14px; cursor: pointer; }
.checkbox input { width: 18px; height: 18px; margin-top: 2px; accent-color: var(--corp); }

/* Switch */
.switch { position: relative; display: inline-flex; width: 44px; height: 26px; flex-shrink: 0; }
.switch input { opacity: 0; width: 0; height: 0; position: absolute; }
.switch .track { position: absolute; inset: 0; border-radius: 999px; background: var(--slate-300); transition: background .2s var(--ease); cursor: pointer; }
.switch .track::after { content: ''; position: absolute; top: 3px; left: 3px; width: 20px; height: 20px; border-radius: 50%; background: #fff; box-shadow: 0 1px 3px rgba(0, 0, 0, .2); transition: transform .2s var(--ease); }
.switch input:checked + .track { background: var(--green); }
.switch input:checked + .track::after { transform: translateX(18px); }
.switch input:focus-visible + .track { outline: 3px solid rgba(22, 59, 101, .35); outline-offset: 2px; }
.switch input:disabled + .track { opacity: .5; cursor: not-allowed; }

/* ------------------------------------------------------------------ Auth pages */
.auth { min-height: 100vh; display: grid; grid-template-columns: minmax(0, 1.05fr) minmax(0, 1fr); }
.auth-brand {
  position: relative; overflow: hidden; color: #fff; padding: 48px 56px; display: flex; flex-direction: column; justify-content: space-between;
  background: radial-gradient(1200px 600px at -10% -10%, #1E4D82 0%, transparent 55%), radial-gradient(900px 500px at 120% 120%, #163B65 0%, transparent 55%), var(--navy);
}
.auth-brand::after {
  content: ''; position: absolute; inset: 0; pointer-events: none; opacity: .5;
  background-image: linear-gradient(rgba(255, 255, 255, .04) 1px, transparent 1px), linear-gradient(90deg, rgba(255, 255, 255, .04) 1px, transparent 1px);
  background-size: 44px 44px; mask-image: linear-gradient(180deg, transparent, #000 30%, #000 70%, transparent);
}
.auth-brand > * { position: relative; z-index: 1; }
.auth-brand h1 { font-size: 40px; font-weight: 700; max-width: 520px; letter-spacing: -0.02em; line-height: 1.12; }
.auth-brand .lead { color: #C9D6E8; font-size: 17px; max-width: 480px; margin-top: 16px; }
.auth-points { display: grid; gap: 14px; margin-top: 36px; max-width: 460px; }
.auth-point { display: flex; gap: 14px; align-items: flex-start; color: #DCE6F3; }
.auth-point .chip { width: 36px; height: 36px; border-radius: 10px; display: grid; place-items: center; background: rgba(255, 255, 255, .07); border: 1px solid rgba(255, 255, 255, .1); color: var(--green); }
.auth-point strong { display: block; color: #fff; font-weight: 600; }
.auth-point span { font-size: 14px; color: #A9B8CE; }
.auth-foot { color: #7E8FA9; font-size: 13px; }
.auth-panel { display: flex; align-items: center; justify-content: center; padding: 40px 24px; background: var(--canvas); }
.auth-card { width: 100%; max-width: 420px; }
.auth-card h2 { font-size: 26px; font-weight: 700; }
.auth-card .sub { color: var(--muted); margin-top: 6px; margin-bottom: 28px; }
.auth-card form { display: grid; gap: 18px; }
.auth-card .row-between { display: flex; justify-content: space-between; align-items: center; font-size: 14px; }
.auth-card .secure-note { display: flex; gap: 8px; align-items: center; justify-content: center; color: var(--muted); font-size: 12.5px; margin-top: 24px; }
.logo.auth-mobile-logo { display: none; margin-bottom: 28px; }
.auth-card .callout { margin-bottom: 20px; }
.pw-meter { height: 6px; border-radius: 99px; background: var(--slate-100); overflow: hidden; }
.pw-meter span { display: block; height: 100%; width: 0; background: var(--red); transition: width .25s var(--ease), background .25s; }
.pw-rules { display: grid; gap: 4px; font-size: 12.5px; color: var(--muted); padding: 0; margin: 4px 0 0; list-style: none; }
.pw-rules li { display: flex; gap: 6px; align-items: center; }
.pw-rules li.ok { color: var(--green-700); }

/* ------------------------------------------------------------------ Logo */
.logo { display: inline-flex; align-items: center; gap: 10px; color: #fff; font-weight: 700; font-size: 17px; letter-spacing: -0.01em; text-decoration: none !important; }
.logo-mark { width: 34px; height: 34px; border-radius: 10px; display: grid; place-items: center; background: linear-gradient(135deg, var(--corp-2), var(--corp)); box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .12); }
.logo-mark svg { width: 20px; height: 20px; color: var(--green); }
.logo small { display: block; font-size: 11px; font-weight: 500; color: #8FA1BC; letter-spacing: .04em; text-transform: uppercase; }
.logo.dark { color: var(--navy); }
.logo.dark small { color: var(--muted); }

/* ------------------------------------------------------------------ App shell */
.app { display: flex; min-height: 100vh; }
.sidebar {
  position: fixed; inset: 0 auto 0 0; width: var(--sidebar-w); background: var(--navy); color: #C3CFE0;
  display: flex; flex-direction: column; z-index: 40; border-right: 1px solid rgba(255, 255, 255, .04);
  transition: transform .25s var(--ease);
}
.sidebar-head { padding: 22px 20px 18px; border-bottom: 1px solid rgba(255, 255, 255, .06); }
.nav { padding: 14px 12px; display: flex; flex-direction: column; gap: 2px; overflow-y: auto; flex: 1; }
.nav-label { font-size: 11px; text-transform: uppercase; letter-spacing: .1em; color: #5F708C; font-weight: 700; padding: 14px 12px 6px; }
.nav a {
  display: flex; align-items: center; gap: 12px; padding: 10px 12px; border-radius: 10px; color: #B4C2D6; font-weight: 500; font-size: 14.5px;
  text-decoration: none; transition: background .15s, color .15s; position: relative;
}
.nav a svg { width: 19px; height: 19px; opacity: .85; }
.nav a:hover { background: rgba(255, 255, 255, .05); color: #fff; }
.nav a.active { background: linear-gradient(90deg, rgba(36, 199, 139, .14), rgba(36, 199, 139, .02)); color: #fff; }
.nav a.active::before { content: ''; position: absolute; left: -12px; top: 8px; bottom: 8px; width: 3px; border-radius: 0 3px 3px 0; background: var(--green); }
.nav a.active svg { color: var(--green); opacity: 1; }
.nav .badge-count { margin-left: auto; background: var(--red); color: #fff; font-size: 11px; font-weight: 700; border-radius: 99px; padding: 1px 7px; }
.sidebar-foot { padding: 14px; border-top: 1px solid rgba(255, 255, 255, .06); }
.user-card { display: flex; align-items: center; gap: 10px; padding: 8px; border-radius: 12px; }
.avatar { width: 36px; height: 36px; border-radius: 50%; display: grid; place-items: center; font-weight: 700; font-size: 13px; color: #fff; background: linear-gradient(135deg, var(--corp-2), #2C6CB0); flex-shrink: 0; }
.avatar.lg { width: 56px; height: 56px; font-size: 18px; border-radius: 16px; }
.user-card .who { min-width: 0; flex: 1; }
.user-card .who strong { display: block; color: #fff; font-size: 14px; font-weight: 600; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.user-card .who span { display: block; font-size: 12px; color: #7E8FA9; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.user-card .btn-icon { color: #9FB0C8; background: transparent; border: 0; height: 36px; width: 36px; border-radius: 10px; cursor: pointer; display: grid; place-items: center; }
.user-card .btn-icon:hover { background: rgba(255, 255, 255, .07); color: #fff; }

.main { flex: 1; margin-left: var(--sidebar-w); min-width: 0; display: flex; flex-direction: column; }
.topbar {
  position: sticky; top: 0; z-index: 30; display: flex; align-items: center; gap: 12px; height: 68px; padding: 0 32px;
  background: rgba(244, 247, 251, .86); backdrop-filter: saturate(1.4) blur(10px); -webkit-backdrop-filter: saturate(1.4) blur(10px);
  border-bottom: 1px solid rgba(227, 232, 240, .7);
}
.topbar h1 { font-size: 20px; font-weight: 700; }
.topbar .crumbs { font-size: 13px; color: var(--muted); display: flex; gap: 6px; align-items: center; }
.topbar .crumbs a { color: var(--muted); }
.topbar .spacer { flex: 1; }
.menu-btn { display: none; }
.content { padding: 28px 32px 56px; max-width: 1360px; width: 100%; }
.demo-banner {
  display: flex; align-items: center; gap: 10px; padding: 9px 32px; font-size: 13px; color: #7A4B00;
  background: repeating-linear-gradient(135deg, #FEF5E6, #FEF5E6 12px, #FDF0D9 12px, #FDF0D9 24px); border-bottom: 1px solid #F7DDB0;
}
.demo-banner svg { color: var(--amber); width: 18px; height: 18px; }
.demo-banner strong { color: #5C3900; }
.scrim { position: fixed; inset: 0; background: rgba(11, 18, 32, .5); z-index: 35; opacity: 0; pointer-events: none; transition: opacity .2s; }

/* ------------------------------------------------------------------ Cards & layout */
.page-head { display: flex; align-items: flex-end; justify-content: space-between; gap: 16px; margin-bottom: 24px; flex-wrap: wrap; }
.page-head h2 { font-size: 26px; font-weight: 700; letter-spacing: -0.02em; }
.page-head p { color: var(--muted); margin-top: 4px; }
.page-head .actions { display: flex; gap: 10px; flex-wrap: wrap; }
.card { background: #fff; border: 1px solid var(--border); border-radius: var(--radius); box-shadow: var(--shadow-sm); }
.card-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 18px 22px; border-bottom: 1px solid var(--slate-100); }
.card-head h3 { font-size: 16px; font-weight: 650; }
.card-head .sub { font-size: 13px; color: var(--muted); margin-top: 2px; }
.card-body { padding: 22px; }
.card-body.flush { padding: 0; }
.grid { display: grid; gap: 20px; }
.grid-4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.grid-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.grid-2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.grid-main { grid-template-columns: minmax(0, 1.65fr) minmax(0, 1fr); }
.stack { display: grid; gap: 20px; align-content: start; grid-template-columns: minmax(0, 1fr); }
.stack > *, .grid > * { min-width: 0; }
fieldset { border: 0; padding: 0; margin: 0; min-width: 0; }
.section-gap { margin-top: 20px; }

/* KPI cards */
.kpi { padding: 20px 22px; display: flex; flex-direction: column; gap: 14px; position: relative; overflow: hidden; }
.kpi-top { display: flex; align-items: center; justify-content: space-between; }
.kpi-label { font-size: 13px; font-weight: 600; color: var(--muted); }
.kpi-icon { width: 38px; height: 38px; border-radius: 11px; display: grid; place-items: center; background: var(--corp-50); color: var(--corp); }
.kpi-icon svg { width: 20px; height: 20px; }
.kpi-icon.green { background: var(--green-50); color: var(--green-700); }
.kpi-icon.amber { background: var(--amber-50); color: var(--amber-700); }
.kpi-icon.red { background: var(--red-50); color: var(--red-700); }
.kpi-value { font-size: 30px; font-weight: 700; letter-spacing: -0.02em; line-height: 1; }
.kpi-value.sm { font-size: 22px; }
.kpi-foot { font-size: 12.5px; color: var(--muted); }
.kpi-foot .up { color: var(--green-700); font-weight: 600; }
.kpi-foot .warn { color: var(--amber-700); font-weight: 600; }
.kpi-foot .bad { color: var(--red-700); font-weight: 600; }

/* Next payment hero card */
.hero-pay {
  position: relative; overflow: hidden; color: #fff; border-radius: 18px; padding: 26px 28px;
  background: radial-gradient(600px 300px at 110% -20%, rgba(36, 199, 139, .28), transparent 60%), linear-gradient(135deg, var(--corp) 0%, var(--navy) 100%);
  box-shadow: var(--shadow);
}
.hero-pay::after { content: ''; position: absolute; right: -60px; bottom: -80px; width: 260px; height: 260px; border-radius: 50%; border: 36px solid rgba(255, 255, 255, .04); }
.hero-pay .eyebrow { font-size: 12px; font-weight: 700; letter-spacing: .14em; text-transform: uppercase; color: #9FD9C2; display: flex; align-items: center; gap: 8px; }
.hero-pay .amount { font-size: 42px; font-weight: 700; letter-spacing: -0.02em; margin: 14px 0 4px; }
.hero-pay .due { color: #C9D6E8; font-size: 15px; }
.hero-pay dl { display: grid; grid-template-columns: repeat(3, minmax(0, auto)); gap: 4px 28px; margin: 22px 0 0; justify-content: start; }
.hero-pay dt { font-size: 12px; color: #93A6C2; text-transform: uppercase; letter-spacing: .06em; font-weight: 600; }
.hero-pay dd { margin: 0; font-weight: 600; font-size: 15px; }
.hero-pay .hero-actions { margin-top: 24px; display: flex; gap: 10px; flex-wrap: wrap; position: relative; z-index: 1; }
.hero-pay .btn-light { background: #fff; color: var(--navy); }
.hero-pay .btn-light:hover { background: #EAF1F9; color: var(--navy); }
.hero-pay .countdown { position: absolute; top: 24px; right: 26px; text-align: right; z-index: 1; }
.hero-pay .countdown b { display: block; font-size: 34px; line-height: 1; }
.hero-pay .countdown span { font-size: 12px; color: #93A6C2; text-transform: uppercase; letter-spacing: .08em; }
.demo-tag { display: inline-flex; align-items: center; gap: 5px; font-size: 10.5px; font-weight: 800; letter-spacing: .1em; text-transform: uppercase; padding: 3px 8px; border-radius: 6px; background: var(--amber); color: #3B2600; }

/* ------------------------------------------------------------------ Pills / badges */
.pill { display: inline-flex; align-items: center; gap: 6px; height: 24px; padding: 0 10px; border-radius: 99px; font-size: 12px; font-weight: 650; white-space: nowrap; border: 1px solid transparent; }
.pill::before { content: ''; width: 6px; height: 6px; border-radius: 50%; background: currentColor; }
.pill.no-dot::before { display: none; }
.pill-green { background: var(--green-50); color: var(--green-700); border-color: #C3EEDD; }
.pill-amber { background: var(--amber-50); color: var(--amber-700); border-color: #F8E0B4; }
.pill-red { background: var(--red-50); color: var(--red-700); border-color: #F8CACA; }
.pill-blue { background: var(--corp-50); color: var(--corp); border-color: #CFDDEE; }
.pill-gray { background: var(--slate-100); color: var(--slate-600); border-color: var(--slate-200); }
.pill-dark { background: #E5E7EB; color: #1F2937; border-color: #D1D5DB; }

/* ------------------------------------------------------------------ Tables */
.toolbar { display: flex; gap: 12px; align-items: center; padding: 16px 22px; border-bottom: 1px solid var(--slate-100); flex-wrap: wrap; }
.search { position: relative; flex: 1; min-width: 220px; max-width: 420px; }
.search svg { position: absolute; left: 12px; top: 50%; transform: translateY(-50%); width: 18px; height: 18px; color: var(--slate-400); }
.search .input { padding-left: 38px; }
.toolbar select.input { width: auto; min-width: 170px; }
.table-wrap { overflow-x: auto; }
table.table { width: 100%; border-collapse: separate; border-spacing: 0; font-size: 14px; }
.table th {
  text-align: left; font-size: 11.5px; text-transform: uppercase; letter-spacing: .07em; color: var(--slate-500); font-weight: 700;
  padding: 12px 22px; background: var(--slate-50); border-bottom: 1px solid var(--slate-100); white-space: nowrap;
}
.table td { padding: 14px 22px; border-bottom: 1px solid var(--slate-100); vertical-align: middle; }
.table tbody tr { transition: background .12s; }
.table tbody tr:hover { background: #FAFCFE; }
.table tbody tr.clickable { cursor: pointer; }
.table tbody tr:last-child td { border-bottom: 0; }
.table .primary { font-weight: 600; color: var(--navy); }
.table a.primary, .table td.cell-main > .primary { white-space: nowrap; }
.table .secondary { font-size: 12.5px; color: var(--muted); }
.table td.amount { font-variant-numeric: tabular-nums; font-weight: 600; white-space: nowrap; }
.table tr.voided td { color: var(--slate-400); }
.table tr.voided td .amount-v { text-decoration: line-through; }
.cell-entity { display: flex; align-items: center; gap: 12px; min-width: 0; }
.cell-entity .avatar { width: 34px; height: 34px; font-size: 12px; border-radius: 10px; }
.empty { padding: 48px 24px; text-align: center; color: var(--muted); }
.empty svg { width: 40px; height: 40px; color: var(--slate-300); margin-bottom: 10px; }
.empty strong { display: block; color: var(--navy); font-size: 15px; margin-bottom: 4px; }


/* Stacked (card-style) tables for narrow columns */
table.table.stacked thead { display: none; }
table.table.stacked, table.table.stacked tbody, table.table.stacked tr, table.table.stacked td { display: block; width: 100%; }
table.table.stacked tr { padding: 12px 22px; border-bottom: 1px solid var(--slate-100); }
table.table.stacked tr:last-child { border-bottom: 0; }
table.table.stacked td { border: 0; padding: 3px 0; display: flex; justify-content: space-between; gap: 12px; text-align: right; }
table.table.stacked td::before { content: attr(data-label); font-size: 12px; font-weight: 600; color: var(--slate-500); text-align: left; flex-shrink: 0; }
table.table.stacked td.cell-main { display: block; text-align: left; padding-bottom: 6px; }
table.table.stacked td.cell-main::before, table.table.stacked td[data-label=""]::before { display: none; }

/* ------------------------------------------------------------------ Timeline */
.timeline { list-style: none; margin: 0; padding: 4px 0 0; position: relative; }
.timeline::before { content: ''; position: absolute; left: 19px; top: 8px; bottom: 8px; width: 2px; background: linear-gradient(var(--slate-200), var(--slate-100)); border-radius: 2px; }
.tl-item { position: relative; padding-left: 58px; padding-bottom: 22px; animation: rise .4s var(--ease) both; }
.tl-item:last-child { padding-bottom: 4px; }
.tl-node { position: absolute; left: 0; top: 0; width: 40px; height: 40px; border-radius: 12px; display: grid; place-items: center; background: #fff; border: 1px solid var(--slate-200); box-shadow: 0 0 0 4px #fff; color: var(--corp); }
.tl-node svg { width: 19px; height: 19px; }
.tl-node.payment { background: var(--green-50); border-color: #C3EEDD; color: var(--green-700); }
.tl-node.alert { background: var(--amber-50); border-color: #F8E0B4; color: var(--amber-700); }
.tl-node.critical { background: var(--red-50); border-color: #F8CACA; color: var(--red-700); }
.tl-node.document { background: #F2EEFD; border-color: #DED3FA; color: #6D4BD8; }
.tl-node.update { background: var(--corp-50); border-color: #CFDDEE; color: var(--corp); }
.tl-node.system { background: var(--slate-100); color: var(--slate-600); }
.tl-card { background: #fff; border: 1px solid var(--slate-200); border-radius: 12px; padding: 12px 16px; transition: border-color .15s, box-shadow .15s; }
.tl-card:hover { border-color: var(--slate-300); box-shadow: var(--shadow-sm); }
.tl-title { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.tl-title strong { font-weight: 650; font-size: 14.5px; }
.tl-desc { margin-top: 4px; color: var(--slate-600); font-size: 14px; }
.tl-meta { margin-top: 8px; display: flex; gap: 14px; flex-wrap: wrap; font-size: 12.5px; color: var(--muted); }
.tl-meta span { display: inline-flex; align-items: center; gap: 5px; }
.tl-meta svg { width: 14px; height: 14px; }
.tl-day { position: relative; padding-left: 58px; margin: 6px 0 14px; font-size: 12px; font-weight: 700; text-transform: uppercase; letter-spacing: .08em; color: var(--slate-500); }
.tl-day::before { content: ''; position: absolute; left: 14px; top: 50%; width: 12px; height: 12px; border-radius: 50%; background: var(--canvas); border: 2px solid var(--slate-300); transform: translateY(-50%); }
.tl-admin-only { font-size: 10.5px; font-weight: 800; letter-spacing: .08em; text-transform: uppercase; color: var(--slate-500); background: var(--slate-100); border-radius: 5px; padding: 2px 6px; }
@keyframes rise { from { opacity: 0; transform: translateY(6px); } to { opacity: 1; transform: none; } }

/* Compact activity list */
.activity { list-style: none; margin: 0; padding: 0; }
.activity li { display: flex; gap: 12px; padding: 12px 22px; border-bottom: 1px solid var(--slate-100); align-items: flex-start; }
.activity li:last-child { border-bottom: 0; }
.activity .tl-node { position: static; width: 34px; height: 34px; border-radius: 10px; box-shadow: none; }
.activity .tl-node svg { width: 17px; height: 17px; }
.activity .what { min-width: 0; flex: 1; }
.activity .what strong { font-weight: 600; font-size: 14px; }
.activity .what p { font-size: 13px; color: var(--muted); overflow: hidden; text-overflow: ellipsis; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; }
.activity time { font-size: 12px; color: var(--slate-400); white-space: nowrap; }

/* ------------------------------------------------------------------ Detail / facts */
.facts { display: grid; grid-template-columns: repeat(auto-fill, minmax(180px, 1fr)); gap: 18px 24px; }
.fact dt { font-size: 12px; text-transform: uppercase; letter-spacing: .06em; color: var(--slate-500); font-weight: 700; }
.fact dd { margin: 4px 0 0; font-weight: 600; font-size: 15px; word-break: break-word; }
.profile-head { display: flex; gap: 18px; align-items: center; flex-wrap: wrap; }
.profile-head h2 { font-size: 24px; font-weight: 700; display: flex; gap: 10px; align-items: center; flex-wrap: wrap; }
.profile-head .meta { display: flex; gap: 16px; flex-wrap: wrap; color: var(--muted); font-size: 14px; margin-top: 6px; }
.profile-head .meta span { display: inline-flex; gap: 6px; align-items: center; }
.profile-head .meta svg { width: 16px; height: 16px; }
.tabs { display: flex; gap: 4px; border-bottom: 1px solid var(--slate-200); margin: 24px 0 20px; overflow-x: auto; scrollbar-width: none; }
.tabs button { background: none; border: 0; padding: 12px 14px; font-weight: 600; font-size: 14px; color: var(--muted); cursor: pointer; position: relative; white-space: nowrap; border-radius: 8px 8px 0 0; }
.tabs button:hover { color: var(--navy); background: rgba(22, 59, 101, .04); }
.tabs button.active { color: var(--corp); }
.tabs button.active::after { content: ''; position: absolute; left: 10px; right: 10px; bottom: -1px; height: 2px; background: var(--corp); border-radius: 2px; }
.tabs .count { margin-left: 6px; font-size: 11px; background: var(--slate-100); color: var(--slate-600); border-radius: 99px; padding: 1px 7px; }

/* Policy mini cards (client) */
.policy-cards { display: grid; grid-template-columns: repeat(auto-fill, minmax(290px, 1fr)); gap: 16px; }
.policy-card { padding: 20px; display: flex; flex-direction: column; gap: 14px; transition: transform .15s var(--ease), box-shadow .15s; cursor: pointer; color: inherit; text-decoration: none !important; }
.policy-card:hover { transform: translateY(-2px); box-shadow: var(--shadow); color: inherit; }
.policy-card .pc-top { display: flex; justify-content: space-between; align-items: flex-start; gap: 8px; }
.policy-card .pc-num { font-weight: 700; font-size: 16px; }
.policy-card .pc-cov { color: var(--muted); font-size: 13.5px; }
.policy-card .pc-row { display: flex; justify-content: space-between; font-size: 13.5px; }
.policy-card .pc-row span:first-child { color: var(--muted); }
.policy-card .pc-row span:last-child { font-weight: 600; }
.progress { height: 6px; border-radius: 99px; background: var(--slate-100); overflow: hidden; }
.progress span { display: block; height: 100%; border-radius: 99px; background: linear-gradient(90deg, var(--corp), var(--green)); }

/* ------------------------------------------------------------------ Settings rows (Payment reminders) */
.setting-row { display: flex; align-items: center; justify-content: space-between; gap: 20px; padding: 16px 0; border-bottom: 1px solid var(--slate-100); }
.setting-row:first-child { padding-top: 0; }
.setting-row:last-child { border-bottom: 0; padding-bottom: 0; }
.setting-row .txt strong { display: block; font-weight: 600; font-size: 14.5px; }
.setting-row .txt span { font-size: 13px; color: var(--muted); }
.days-input { display: flex; align-items: center; gap: 8px; }
.days-input .input { width: 76px; text-align: center; height: 38px; }
.days-input span { font-size: 13px; color: var(--muted); }
.reminder-panel.disabled .setting-row:not(.master) { opacity: .45; pointer-events: none; }
.reminder-head { display: flex; align-items: center; gap: 12px; }
.reminder-head .kpi-icon { width: 36px; height: 36px; }
.callout { display: flex; gap: 12px; padding: 14px 16px; border-radius: 12px; background: var(--corp-50); border: 1px solid #D5E2F1; color: #1C3A5E; font-size: 13.5px; }
.callout svg { width: 20px; height: 20px; color: var(--corp); flex-shrink: 0; margin-top: 1px; }
.callout.amber { background: var(--amber-50); border-color: #F6DFB5; color: #6B4500; }
.callout.amber svg { color: var(--amber); }
.callout.red { background: var(--red-50); border-color: #F8CACA; color: #7F1D1D; }
.callout.red svg { color: var(--red); }
.callout.green { background: var(--green-50); border-color: #C3EEDD; color: #064E3B; }
.callout.green svg { color: var(--green-700); }
.preview-mail { border: 1px solid var(--slate-200); border-radius: 12px; overflow: hidden; background: #fff; }
.preview-mail .pm-head { background: var(--navy); color: #fff; padding: 12px 16px; font-weight: 600; font-size: 14px; }
.preview-mail .pm-subj { padding: 12px 16px; border-bottom: 1px solid var(--slate-100); font-size: 14px; }
.preview-mail .pm-body { padding: 16px; white-space: pre-wrap; font-size: 14px; color: var(--slate-700); }
.code-chip { font-family: var(--mono); font-size: 12px; background: var(--slate-100); border: 1px solid var(--slate-200); padding: 2px 6px; border-radius: 6px; cursor: pointer; }
.code-chip:hover { background: var(--corp-50); }

/* ------------------------------------------------------------------ Charts */
.chart { width: 100%; height: auto; display: block; }
.chart .bar { transition: opacity .15s; }
.chart .bar:hover { opacity: .8; }
.chart text { font-family: var(--font); font-size: 11px; fill: var(--slate-500); }
.chart .val { font-weight: 700; fill: var(--navy); font-size: 11px; }
.donut-wrap { display: flex; align-items: center; gap: 22px; flex-wrap: wrap; }
.donut-wrap svg { width: 150px; height: 150px; }
.legend { list-style: none; padding: 0; margin: 0; display: grid; gap: 8px; flex: 1; min-width: 160px; }
.legend li { display: flex; align-items: center; gap: 8px; font-size: 13.5px; }
.legend i { width: 10px; height: 10px; border-radius: 3px; display: inline-block; }
.legend b { margin-left: auto; font-variant-numeric: tabular-nums; }
.donut-seg { transition: stroke-width .15s; }

/* ------------------------------------------------------------------ Modal */
dialog.modal { border: 0; padding: 0; border-radius: 18px; width: min(680px, calc(100vw - 24px)); max-height: calc(100vh - 32px); box-shadow: var(--shadow-lg); color: var(--text); overflow: hidden; }
dialog.modal.sm { width: min(460px, calc(100vw - 24px)); }
dialog.modal::backdrop { background: rgba(11, 18, 32, .55); backdrop-filter: blur(2px); }
dialog.modal[open] { animation: pop .22s var(--ease); display: flex; flex-direction: column; }
@keyframes pop { from { opacity: 0; transform: translateY(10px) scale(.98); } to { opacity: 1; transform: none; } }
.modal-head { display: flex; align-items: center; justify-content: space-between; padding: 20px 24px; border-bottom: 1px solid var(--slate-100); }
.modal-head h3 { font-size: 18px; font-weight: 700; }
.modal-head p { font-size: 13px; color: var(--muted); margin-top: 2px; }
.modal-close { background: none; border: 0; width: 36px; height: 36px; border-radius: 10px; cursor: pointer; color: var(--slate-500); display: grid; place-items: center; }
.modal-close:hover { background: var(--slate-100); }
.modal-body { padding: 22px 24px; overflow-y: auto; display: grid; gap: 16px; }
.modal-foot { display: flex; justify-content: flex-end; gap: 10px; padding: 16px 24px; border-top: 1px solid var(--slate-100); background: var(--slate-50); }
.copy-box { display: flex; gap: 8px; }
.copy-box .input { font-family: var(--mono); font-size: 12.5px; }

/* ------------------------------------------------------------------ Toasts */
.toasts { position: fixed; right: 20px; bottom: 20px; display: grid; gap: 10px; z-index: 100; width: min(380px, calc(100vw - 40px)); }
.toast { display: flex; gap: 12px; align-items: flex-start; background: var(--navy); color: #fff; padding: 14px 16px; border-radius: 12px; box-shadow: var(--shadow-lg); animation: toastin .25s var(--ease); font-size: 14px; }
.toast svg { width: 20px; height: 20px; flex-shrink: 0; }
.toast.success svg { color: var(--green); }
.toast.error svg { color: #FF8A8A; }
.toast.warn svg { color: var(--amber); }
.toast.out { animation: toastout .2s var(--ease) forwards; }
@keyframes toastin { from { opacity: 0; transform: translateY(12px); } to { opacity: 1; transform: none; } }
@keyframes toastout { to { opacity: 0; transform: translateY(8px); } }

/* Skeleton loading */
.skeleton { background: linear-gradient(90deg, var(--slate-100) 25%, #F6F8FB 37%, var(--slate-100) 63%); background-size: 400% 100%; animation: shimmer 1.3s ease infinite; border-radius: 8px; }
@keyframes shimmer { 0% { background-position: 100% 50%; } 100% { background-position: 0 50%; } }
.sk-line { height: 14px; margin: 10px 0; }
.sk-block { height: 120px; }
.fade-in { animation: rise .35s var(--ease) both; }

/* ------------------------------------------------------------------ Responsive */
@media (max-width: 1200px) {
  .grid-4 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .grid-main { grid-template-columns: minmax(0, 1fr); }
}
@media (max-width: 960px) {
  .auth { grid-template-columns: 1fr; }
  .auth-brand { display: none; }
  .logo.auth-mobile-logo { display: inline-flex; }
  .sidebar { transform: translateX(-100%); box-shadow: var(--shadow-lg); }
  body.nav-open .sidebar { transform: none; }
  body.nav-open .scrim { opacity: 1; pointer-events: auto; }
  .main { margin-left: 0; }
  .menu-btn { display: inline-flex; }
  .topbar { padding: 0 16px; height: 60px; }
  .content { padding: 20px 16px 48px; }
  .demo-banner { padding: 8px 16px; }
  .grid-3, .grid-2 { grid-template-columns: minmax(0, 1fr); }
}
@media (max-width: 640px) {
  body { font-size: 14.5px; }
  .grid-4 { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
  .kpi { padding: 16px; gap: 10px; }
  .kpi-value { font-size: 24px; }
  .kpi-icon { width: 32px; height: 32px; }
  .page-head h2 { font-size: 22px; }
  .form-grid { grid-template-columns: 1fr; }
  .form-grid .span-2 { grid-column: auto; }
  .hero-pay { padding: 22px; }
  .hero-pay .amount { font-size: 34px; }
  .hero-pay .countdown { position: static; text-align: left; margin-bottom: 10px; }
  .hero-pay .countdown b { display: inline; font-size: 18px; margin-right: 6px; }
  .hero-pay dl { grid-template-columns: 1fr 1fr; }
  .card-head, .card-body, .toolbar { padding-left: 16px; padding-right: 16px; }
  .toolbar select.input { flex: 1; min-width: 0; }
  .toolbar .search { min-width: 100%; max-width: none; }
  .topbar h1 { font-size: 17px; }
  .topbar .crumbs { display: none; }
  /* Tables become stacked cards */
  table.table.responsive thead { display: none; }
  table.table.responsive, table.table.responsive tbody, table.table.responsive tr, table.table.responsive td { display: block; width: 100%; }
  table.table.responsive tr { padding: 12px 16px; border-bottom: 1px solid var(--slate-100); }
  table.table.responsive td { border: 0; padding: 4px 0; display: flex; justify-content: space-between; gap: 12px; text-align: right; }
  table.table.responsive td::before { content: attr(data-label); font-size: 12px; font-weight: 600; color: var(--slate-500); text-align: left; flex-shrink: 0; }
  table.table.responsive td.cell-main { display: block; text-align: left; padding-bottom: 8px; }
  table.table.responsive td.cell-main::before { display: none; }
  .tl-item, .tl-day { padding-left: 50px; }
  .tl-node { width: 36px; height: 36px; }
  .timeline::before { left: 17px; }
  .tl-day::before { left: 12px; }
  .modal-body { padding: 18px; }
  .modal-foot { padding: 14px 18px; }
  .modal-foot .btn { flex: 1; }
  .setting-row { flex-wrap: wrap; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .01ms !important; animation-iteration-count: 1 !important; transition-duration: .01ms !important; }
}
body > .auth-panel { min-height: 100vh; }

/* ================================================================== Mileage */
.mile-chip { display: inline-flex; align-items: center; gap: 5px; font-weight: 650; font-size: 12.5px; color: var(--corp); background: var(--corp-50); border: 1px solid #CFDDEE; border-radius: 99px; padding: 2px 9px 2px 7px; white-space: nowrap; }
.mile-chip svg { width: 14px; height: 14px; }
.card-head h3 svg { width: 18px; height: 18px; vertical-align: -3px; color: var(--corp); margin-right: 4px; }
.warn { color: var(--amber-700); font-weight: 600; }
.input-sm { height: 34px; font-size: 13.5px; padding: 0 8px; }
.btn-ghost-light { background: rgba(255, 255, 255, .08); color: #fff; border-color: rgba(255, 255, 255, .22); }
.btn-ghost-light:hover { background: rgba(255, 255, 255, .16); color: #fff; }
.avatar.unit { width: 34px; height: 34px; border-radius: 10px; background: linear-gradient(135deg, #1A2540, #0B1220); color: var(--green); }
.avatar.unit svg { width: 18px; height: 18px; }

/* Segmented radio */
.segmented { display: inline-flex; padding: 4px; gap: 4px; background: var(--slate-100); border-radius: 12px; flex-wrap: wrap; }
.segmented label { position: relative; cursor: pointer; }
.segmented input { position: absolute; opacity: 0; }
.segmented span { display: inline-flex; align-items: center; gap: 7px; padding: 8px 14px; border-radius: 9px; font-weight: 600; font-size: 14px; color: var(--slate-600); transition: background .15s, color .15s, box-shadow .15s; }
.segmented span svg { width: 17px; height: 17px; }
.segmented input:checked + span { background: #fff; color: var(--corp); box-shadow: var(--shadow-sm); }
.segmented input:focus-visible + span { outline: 3px solid rgba(22, 59, 101, .35); }

/* Admin dashboard strip */
.mile-strip { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 12px; }
.mile-stat { display: flex; align-items: center; gap: 12px; padding: 14px 16px; border-radius: 14px; background: var(--navy); color: #C3CFE0; text-decoration: none !important; border: 1px solid rgba(255, 255, 255, .04); transition: transform .15s var(--ease), box-shadow .15s; }
.mile-stat:hover { transform: translateY(-1px); box-shadow: var(--shadow); color: #fff; }
.mile-stat svg { width: 22px; height: 22px; color: #6F8BB0; }
.mile-stat b { display: block; color: #fff; font-size: 20px; line-height: 1.1; }
.mile-stat span { font-size: 12.5px; }
.mile-stat.hot svg { color: var(--green); }
.mile-stat.warn svg { color: var(--amber); }

/* Client mileage card */
.mileage-card .mileage-body { display: grid; grid-template-columns: minmax(0, 1.2fr) minmax(0, 1fr); gap: 20px; align-items: center; }
.report-cta { display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 14px 22px; background: linear-gradient(90deg, var(--green-50), #F4FBF8); border-bottom: 1px solid #CDEFE1; flex-wrap: wrap; }
.card > .report-cta:first-child, .report-cta.section-gap { border-radius: 14px; border: 1px solid #CDEFE1; }
.report-cta strong { display: block; color: #064E3B; }
.report-cta span { font-size: 13px; color: #2F6B57; }
.report-cta.late { background: linear-gradient(90deg, var(--red-50), #FEF6F6); border-color: #F8CACA; }
.report-cta.late strong { color: #7F1D1D; }
.report-cta.late span { color: #9B3636; }

/* Report hero */
.report-hero { display: flex; justify-content: space-between; align-items: flex-end; gap: 20px; padding: 24px 26px; border-radius: 18px; color: #fff;
  background: radial-gradient(500px 240px at 100% 0%, rgba(36, 199, 139, .22), transparent 60%), linear-gradient(135deg, var(--corp) 0%, var(--navy) 100%); flex-wrap: wrap; }
.report-hero .eyebrow { font-size: 12px; font-weight: 700; letter-spacing: .12em; text-transform: uppercase; color: #9FD9C2; display: flex; align-items: center; gap: 8px; }
.report-hero .eyebrow svg { width: 16px; height: 16px; }
.report-hero h2 { font-size: 30px; margin: 8px 0 6px; display: flex; gap: 10px; align-items: center; flex-wrap: wrap; letter-spacing: -0.02em; }
.report-hero p { color: #C9D6E8; font-size: 14px; }
.report-deadline { text-align: right; }
.report-deadline b { display: block; font-size: 30px; line-height: 1; }
.report-deadline span { font-size: 12px; color: #93A6C2; text-transform: uppercase; letter-spacing: .08em; }
.report-deadline.late b { color: #FFB4B4; }

/* Odometer table */
.odo-table td { vertical-align: top; }
.odo-table .input.odo { max-width: 170px; font-variant-numeric: tabular-nums; font-family: var(--mono); font-size: 14px; }
.odo-table .secondary { margin-top: 4px; }
.odo-miles { font-weight: 700; font-variant-numeric: tabular-nums; }
.odo-table tr.row-bad .odo-miles { color: var(--red-700); }
.odo-table tr.row-bad .input.odo { border-color: #F3B4B4; }

/* State allocation */
.alloc { display: flex; align-items: center; gap: 12px; margin-bottom: 14px; }
.alloc-bar { flex: 1; height: 8px; border-radius: 99px; background: var(--slate-100); overflow: hidden; }
.alloc-bar span { display: block; height: 100%; width: 0; background: var(--corp-2); border-radius: 99px; transition: width .25s var(--ease), background .2s; }
.alloc-bar span.done { background: var(--green); }
.alloc-bar span.over { background: var(--red); }
.alloc-text { font-size: 12.5px; color: var(--muted); white-space: nowrap; }
.state-rows { display: grid; gap: 8px; }
.state-row { display: grid; grid-template-columns: 110px minmax(0, 1fr) auto auto; gap: 8px; align-items: center; }

/* Statement summary */
.statement-card.sticky { position: sticky; top: 84px; }
.stmt-total { display: flex; justify-content: space-between; align-items: baseline; padding-bottom: 14px; border-bottom: 1px dashed var(--slate-200); }
.stmt-total span { color: var(--muted); font-size: 13px; font-weight: 600; }
.stmt-total b { font-size: 30px; letter-spacing: -0.02em; font-variant-numeric: tabular-nums; }
.stmt-lines { margin: 12px 0; display: grid; gap: 8px; }
.stmt-lines div { display: flex; justify-content: space-between; font-size: 14px; }
.stmt-lines dt { color: var(--muted); }
.stmt-lines dd { margin: 0; font-weight: 600; font-variant-numeric: tabular-nums; }
.stmt-amount { display: flex; justify-content: space-between; align-items: center; gap: 12px; padding: 14px 16px; border-radius: 12px; background: var(--navy); color: #fff; }
.stmt-amount span { font-size: 13px; color: #A9B8CE; }
.stmt-amount b { font-size: 22px; font-variant-numeric: tabular-nums; }
.review-actions { display: grid; gap: 8px; }
.share { height: 6px; border-radius: 99px; background: var(--slate-100); overflow: hidden; min-width: 80px; }
.share span { display: block; height: 100%; background: linear-gradient(90deg, var(--corp), var(--green)); border-radius: 99px; }

/* US tile map */
.statemap { display: grid; grid-template-columns: minmax(0, 1.5fr) minmax(0, 1fr); gap: 24px; align-items: center; }
.statemap.compact { grid-template-columns: 1fr; }
.statemap svg { width: 100%; height: auto; display: block; }
.statemap .tile rect { transition: transform .15s var(--ease), opacity .15s; transform-box: fill-box; transform-origin: center; }
.statemap .tile.has:hover rect { transform: scale(1.08); }
.statemap text { font-family: var(--font); pointer-events: none; }
.statemap-legend { display: flex; align-items: center; gap: 8px; font-size: 12px; color: var(--muted); margin-bottom: 14px; }
.statemap-legend i { flex: 1; height: 8px; border-radius: 99px; background: linear-gradient(90deg, #DCE8F5, #0F2E52); }
.statemap-top { list-style: none; padding: 0; margin: 0; display: grid; gap: 8px; }
.statemap-top li { display: grid; grid-template-columns: 30px minmax(0, 1fr) auto 38px; gap: 8px; align-items: center; font-size: 13px; }
.statemap-top b { font-weight: 700; }
.statemap-top .bar { height: 8px; background: var(--slate-100); border-radius: 99px; overflow: hidden; }
.statemap-top .bar span { display: block; height: 100%; background: var(--corp-2); border-radius: 99px; }
.statemap-top em { font-style: normal; font-variant-numeric: tabular-nums; font-weight: 600; }
.statemap-top small { color: var(--muted); text-align: right; }

/* Policy units checklist */
.unit-checks { display: grid; gap: 8px; }
.unit-check { display: flex; align-items: center; gap: 10px; padding: 8px 10px; border: 1px solid var(--slate-200); border-radius: 12px; cursor: pointer; transition: border-color .15s, background .15s; }
.unit-check:hover { border-color: var(--slate-300); }
.unit-check input { width: 18px; height: 18px; accent-color: var(--corp); }
.unit-check:has(input:checked) { border-color: #B9CCE4; background: var(--corp-50); }
.unit-check b { display: block; font-size: 14px; }
.unit-check small { color: var(--muted); font-size: 12.5px; }
.unit-check.inactive { opacity: .6; }

/* Rater settings */
.rater-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 10px 14px; padding-bottom: 14px; border-bottom: 1px solid var(--slate-100); }
.rater-grid > b { grid-column: 1 / -1; font-size: 12px; text-transform: uppercase; letter-spacing: .08em; color: var(--slate-500); }
.rater-grid label { display: grid; gap: 4px; font-size: 12.5px; color: var(--slate-600); font-weight: 600; }

@media (max-width: 1200px) {
  .mile-strip { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .statement-card.sticky { position: static; }
}
@media (max-width: 960px) {
  .statemap { grid-template-columns: 1fr; }
  .mileage-card .mileage-body { grid-template-columns: 1fr; }
  .rater-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 640px) {
  .mile-strip { grid-template-columns: 1fr 1fr; gap: 8px; }
  .mile-stat { padding: 12px; }
  .report-hero { padding: 20px; }
  .report-hero h2 { font-size: 24px; }
  .report-deadline { text-align: left; }
  .odo-table .input.odo { max-width: 150px; }
  .state-row { grid-template-columns: 90px minmax(0, 1fr) auto; }
  .state-row [data-fill] { display: none; }
  .rater-grid { grid-template-columns: 1fr; }
  .statemap-top li { grid-template-columns: 28px minmax(0, 1fr) auto; }
  .statemap-top small { display: none; }
}

/* ================================================================== Public product page */
body.site { background: #fff; }
.site .wrap { max-width: 1240px; margin: 0 auto; padding: 0 32px; }
.skip { position: absolute; left: -999px; top: 8px; z-index: 100; background: #fff; padding: 8px 12px; border-radius: 8px; }
.skip:focus { left: 8px; }
.util-bar { background: var(--navy); color: #A9B8CE; font-size: 13px; }
.util-inner { display: flex; justify-content: space-between; align-items: center; height: 38px; gap: 16px; }
.util-note { display: inline-flex; align-items: center; gap: 7px; }
.util-note svg { color: var(--green); }
.util-links { display: flex; gap: 22px; }
.util-links a { color: #DCE6F3; font-weight: 500; }
.util-links a:hover { color: #fff; }
.site-header { position: sticky; top: 0; z-index: 50; background: rgba(255, 255, 255, .94); backdrop-filter: saturate(1.4) blur(10px); -webkit-backdrop-filter: saturate(1.4) blur(10px); border-bottom: 1px solid var(--slate-200); }
.header-inner { display: flex; align-items: center; gap: 28px; height: 70px; }
.main-nav { display: flex; gap: 6px; flex: 1; }
.main-nav a { padding: 8px 12px; border-radius: 8px; font-weight: 600; font-size: 14.5px; color: var(--slate-700); text-decoration: none; }
.main-nav a:hover { background: var(--slate-100); color: var(--navy); }
.header-cta { display: flex; gap: 8px; align-items: center; }
.nav-toggle { display: none; }
.crumb-bar { background: var(--canvas); border-bottom: 1px solid var(--slate-200); }
.breadcrumb { list-style: none; display: flex; gap: 8px; margin: 0; padding: 10px 0; font-size: 13px; color: var(--muted); }
.breadcrumb li + li::before { content: '›'; margin-right: 8px; color: var(--slate-400); }
.breadcrumb a { color: var(--muted); }

.site-hero { position: relative; overflow: hidden; color: #fff; padding: 72px 0 84px;
  background: radial-gradient(900px 480px at 85% 0%, rgba(36, 199, 139, .2), transparent 60%), radial-gradient(800px 600px at 0% 100%, rgba(30, 77, 130, .7), transparent 60%), var(--navy); }
.site-hero::after { content: ''; position: absolute; inset: 0; pointer-events: none; opacity: .45;
  background-image: linear-gradient(rgba(255, 255, 255, .04) 1px, transparent 1px), linear-gradient(90deg, rgba(255, 255, 255, .04) 1px, transparent 1px);
  background-size: 48px 48px; mask-image: radial-gradient(ellipse at 60% 40%, #000 30%, transparent 75%); }
.hero-grid { position: relative; z-index: 1; display: grid; grid-template-columns: minmax(0, 1.1fr) minmax(0, 1fr); gap: 56px; align-items: center; }
.kicker, .sec-kicker { font-size: 12.5px; font-weight: 800; letter-spacing: .16em; text-transform: uppercase; color: var(--green); }
.site-hero h1 { font-size: 58px; line-height: 1.02; letter-spacing: -0.035em; margin: 14px 0 0; font-weight: 800; }
.site-hero h1 span { display: block; background: linear-gradient(90deg, #8FE3C3, #6FB2F2); -webkit-background-clip: text; background-clip: text; color: transparent; }
.hero-copy p { color: #B9C7DB; font-size: 18px; max-width: 540px; margin-top: 20px; }
.hero-ctas { display: flex; gap: 12px; margin-top: 30px; flex-wrap: wrap; }
.btn-outline-light { border-color: rgba(255, 255, 255, .28); color: #fff; background: transparent; }
.btn-outline-light:hover { background: rgba(255, 255, 255, .08); color: #fff; }
.hero-proof { list-style: none; padding: 0; margin: 36px 0 0; display: flex; gap: 34px; flex-wrap: wrap; }
.hero-proof b { display: block; font-size: 18px; color: #fff; }
.hero-proof span { font-size: 13px; color: #8FA1BC; }

.hero-visual { position: relative; padding: 20px; }
.route-card { position: relative; background: linear-gradient(160deg, rgba(255, 255, 255, .09), rgba(255, 255, 255, .03)); border: 1px solid rgba(255, 255, 255, .12); border-radius: 22px; padding: 22px 24px 24px; box-shadow: 0 40px 90px -30px rgba(0, 0, 0, .7); }
.rc-top { display: flex; justify-content: space-between; align-items: center; font-size: 13px; color: #A9B8CE; }
.route { width: 100%; height: auto; margin: 10px 0 6px; overflow: visible; }
.route text { fill: #8FA1BC; font-size: 11px; font-family: var(--font); }
.route-bg { fill: none; stroke: rgba(255, 255, 255, .12); stroke-width: 3; stroke-dasharray: 2 8; stroke-linecap: round; }
.route-line { fill: none; stroke: url(#rg); stroke-width: 3.5; stroke-linecap: round; stroke-dasharray: 520; stroke-dashoffset: 520; animation: draw 4.4s var(--ease) infinite; }
.route-a { fill: var(--green); } .route-b { fill: #5BA3E8; animation: pulse 2.2s ease-in-out infinite; transform-box: fill-box; transform-origin: center; }
@keyframes draw { 0% { stroke-dashoffset: 520; } 60%, 100% { stroke-dashoffset: 0; } }
@keyframes pulse { 0%, 100% { transform: scale(1); } 50% { transform: scale(1.35); } }
.odometer { display: flex; gap: 5px; margin-top: 8px; }
.odo-digit { width: 44px; height: 60px; border-radius: 10px; overflow: hidden; background: linear-gradient(#0B1220, #18233B 50%, #0B1220); border: 1px solid rgba(255, 255, 255, .1); box-shadow: inset 0 0 18px rgba(0, 0, 0, .6); position: relative; }
.odo-digit::after { content: ''; position: absolute; inset: 0; background: linear-gradient(rgba(255, 255, 255, .06), transparent 40%, transparent 60%, rgba(0, 0, 0, .25)); pointer-events: none; }
.odo-strip { display: flex; flex-direction: column; transition: transform 1.1s cubic-bezier(.25, 1.3, .4, 1); }
.odo-strip span { height: 60px; line-height: 60px; text-align: center; font-family: var(--mono); font-size: 34px; font-weight: 700; color: #F4F7FB; font-variant-numeric: tabular-nums; }
.odo-digit:nth-last-child(-n+1) .odo-strip span { color: var(--green); }
.rc-label { font-size: 12px; color: #8FA1BC; text-transform: uppercase; letter-spacing: .1em; margin-top: 8px; }
.rc-calc { display: flex; justify-content: space-between; align-items: center; margin-top: 16px; padding-top: 16px; border-top: 1px dashed rgba(255, 255, 255, .15); color: #C9D6E8; font-size: 15px; }
.rc-amount { font-size: 28px; color: #fff; letter-spacing: -0.02em; font-variant-numeric: tabular-nums; }
.float-chip { position: absolute; display: inline-flex; gap: 7px; align-items: center; padding: 9px 14px; border-radius: 999px; background: #fff; color: var(--navy); font-weight: 650; font-size: 13px; box-shadow: var(--shadow-lg); animation: bob 5s ease-in-out infinite; }
.float-chip svg { color: var(--green-700); }
.float-chip.c1 { top: -4px; right: 18px; }
.float-chip.c2 { bottom: -6px; left: -6px; animation-delay: -2.5s; }
.float-chip.c2 svg { color: var(--amber-700); }
@keyframes bob { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-7px); } }

.section-tabs { position: sticky; top: 70px; z-index: 40; background: #fff; border-bottom: 1px solid var(--slate-200); }
.section-tabs nav { display: flex; gap: 4px; overflow-x: auto; scrollbar-width: none; }
.section-tabs a { padding: 14px 14px; font-weight: 600; font-size: 14px; color: var(--muted); white-space: nowrap; border-bottom: 2px solid transparent; text-decoration: none; }
.section-tabs a:hover { color: var(--navy); }
.section-tabs a.active { color: var(--corp); border-bottom-color: var(--corp); }

.page-grid { display: grid; grid-template-columns: minmax(0, 1fr) 300px; gap: 48px; padding-top: 16px; padding-bottom: 72px; }
.site-section { padding: 56px 0 8px; scroll-margin-top: 130px; }
.site-section h2 { font-size: 36px; letter-spacing: -0.025em; margin: 10px 0 14px; }
.site-section .lead { font-size: 17px; color: var(--slate-600); max-width: 760px; }
.reveal { opacity: 0; transform: translateY(14px); transition: opacity .6s var(--ease), transform .6s var(--ease); }
.reveal.in { opacity: 1; transform: none; }
.overview-points { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; margin-top: 26px; }
.overview-points div { padding: 18px; border-radius: 14px; background: var(--canvas); border: 1px solid var(--slate-200); }
.overview-points b { display: block; margin-bottom: 4px; }
.overview-points span { font-size: 14px; color: var(--slate-600); }

.class-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 14px; margin-top: 22px; }
.class-card { padding: 18px; border: 1px solid var(--slate-200); border-radius: 16px; background: #fff; transition: transform .2s var(--ease), box-shadow .2s, border-color .2s; }
.class-card:hover { transform: translateY(-3px); box-shadow: var(--shadow); border-color: #CFDDEE; }
.class-card .ci { width: 46px; height: 46px; border-radius: 13px; display: grid; place-items: center; background: linear-gradient(135deg, var(--corp-50), #F2F8FD); color: var(--corp); margin-bottom: 12px; }
.class-card .ci svg { width: 26px; height: 26px; }
.class-card h3 { font-size: 15.5px; }
.class-card p { font-size: 13.5px; color: var(--slate-600); margin-top: 5px; }
.reveal.class-card.in:nth-child(2n) { transition-delay: .06s; }

.cov-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 22px; margin-top: 22px; }
.cov-col { padding: 22px; border-radius: 18px; border: 1px solid var(--slate-200); }
.cov-col h3 { font-size: 16px; margin-bottom: 12px; }
.checks { list-style: none; padding: 0; margin: 0; display: grid; gap: 12px; }
.checks li { position: relative; padding-left: 30px; }
.checks li::before { content: ''; position: absolute; left: 0; top: 2px; width: 20px; height: 20px; border-radius: 6px; background: var(--green-50) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%230F8A5C' stroke-width='3' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M20 6 9 17l-5-5'/%3E%3C/svg%3E") center/13px no-repeat; }
.checks.alt li::before { background-color: var(--corp-50); background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23163B65' stroke-width='3' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M12 5v14M5 12h14'/%3E%3C/svg%3E"); }
.checks b { display: block; font-size: 14.5px; }
.checks span { font-size: 13.5px; color: var(--slate-600); }
.footnote { font-size: 12.5px; color: var(--muted); margin-top: 14px; }

.how-steps { list-style: none; padding: 0; margin: 24px 0 0; display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 14px; counter-reset: s; position: relative; }
.how-steps::before { content: ''; position: absolute; left: 24px; right: 24px; top: 23px; height: 2px; background: linear-gradient(90deg, var(--green), var(--corp-2)); opacity: .35; }
.how-steps li { position: relative; }
.hs-n { position: relative; width: 46px; height: 46px; border-radius: 50%; display: grid; place-items: center; font-weight: 800; color: #fff; background: var(--corp); box-shadow: 0 0 0 6px #fff; margin-bottom: 14px; }
.how-steps li:last-child .hs-n { background: var(--green); color: #052E1F; }
.how-steps b { display: block; font-size: 15.5px; }
.how-steps p { font-size: 13.5px; color: var(--slate-600); margin-top: 4px; }
.example-calc { margin-top: 26px; display: flex; align-items: center; gap: 18px; padding: 18px 22px; border-radius: 16px; background: var(--canvas); border: 1px dashed #CBD9EA; flex-wrap: wrap; }
.example-calc span { display: block; font-size: 12px; color: var(--muted); text-transform: uppercase; letter-spacing: .08em; font-weight: 700; }
.example-calc b { font-size: 20px; font-variant-numeric: tabular-nums; }
.example-calc .op { font-size: 22px; color: var(--slate-400); font-weight: 700; }
.example-calc .res b { color: var(--green-700); }
.example-calc small { flex-basis: 100%; color: var(--muted); font-size: 12px; }

.rater { display: grid; grid-template-columns: minmax(0, 1.1fr) minmax(0, 1fr); gap: 22px; margin-top: 24px; padding: 22px; border-radius: 22px; background: linear-gradient(180deg, var(--canvas), #fff); border: 1px solid var(--slate-200); }
.rater-form { display: grid; gap: 18px; align-content: start; }
.rf-label { display: flex; justify-content: space-between; align-items: baseline; font-size: 13px; font-weight: 700; color: var(--slate-700); margin-bottom: 6px; }
.rf-label output { font-size: 18px; color: var(--corp); font-variant-numeric: tabular-nums; }
.rf-row { display: grid; grid-template-columns: auto minmax(0, 1fr); gap: 18px; }
.segmented.wide { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); width: 100%; }
.segmented.wide span { flex-direction: column; align-items: flex-start; gap: 0; padding: 8px 12px; height: 100%; }
.segmented.wide small { font-weight: 500; font-size: 11.5px; color: var(--muted); }
.stepper { display: inline-flex; align-items: center; border: 1px solid var(--slate-200); border-radius: 10px; background: #fff; overflow: hidden; }
.stepper button { width: 40px; height: 42px; border: 0; background: transparent; font-size: 20px; cursor: pointer; color: var(--corp); }
.stepper button:hover { background: var(--slate-100); }
.stepper .input { width: 64px; border: 0; text-align: center; border-radius: 0; font-weight: 700; padding: 0; }
input[type=range] { width: 100%; accent-color: var(--corp); height: 28px; }
.range-ends { display: flex; justify-content: space-between; font-size: 11.5px; color: var(--muted); }
.rf-toggles { display: grid; gap: 10px; }
.toggle-row { display: flex; justify-content: space-between; align-items: center; gap: 12px; padding: 12px 14px; background: #fff; border: 1px solid var(--slate-200); border-radius: 12px; cursor: pointer; }
.toggle-row b { display: block; font-size: 14px; }
.toggle-row small { font-size: 12.5px; color: var(--muted); }

.rater-result { display: flex; flex-direction: column; gap: 14px; padding: 22px; border-radius: 18px; background: var(--navy); color: #fff; box-shadow: var(--shadow-lg); align-self: start; position: sticky; top: 130px; }
.rr-head { display: flex; justify-content: space-between; align-items: center; font-size: 12.5px; text-transform: uppercase; letter-spacing: .12em; color: #8FA1BC; font-weight: 700; }
.rr-range { font-size: 34px; font-weight: 800; letter-spacing: -0.03em; font-variant-numeric: tabular-nums; line-height: 1.1; }
.rr-range span { color: #6F819D; font-weight: 500; }
.rr-sub { display: flex; gap: 18px; color: #A9B8CE; font-size: 14px; flex-wrap: wrap; }
.rr-sub b { color: #fff; }
.rr-break { display: grid; gap: 8px; padding: 14px 0; border-top: 1px solid rgba(255, 255, 255, .1); border-bottom: 1px solid rgba(255, 255, 255, .1); }
.rb { display: grid; grid-template-columns: 150px minmax(0, 1fr) auto; gap: 10px; align-items: center; font-size: 13px; color: #C9D6E8; }
.rb i { height: 8px; border-radius: 99px; background: rgba(255, 255, 255, .08); overflow: hidden; }
.rb em { display: block; height: 100%; width: 0; border-radius: 99px; background: linear-gradient(90deg, var(--green), #5BA3E8); transition: width .4s var(--ease); }
.rb b { font-variant-numeric: tabular-nums; }
.rr-min, .rr-total { font-size: 12.5px; color: #8FA1BC; }
.rr-min { color: #FCD38D; }
.rr-what-head { display: flex; justify-content: space-between; gap: 10px; font-size: 13px; flex-wrap: wrap; }
.rr-what-head span { color: #8FE3C3; }
#rrCurve { width: 100%; height: auto; margin-top: 6px; }
.cv-area { fill: rgba(91, 163, 232, .12); }
.cv-line { fill: none; stroke: #5BA3E8; stroke-width: 2.5; }
.cv-marker { stroke: rgba(255, 255, 255, .25); stroke-dasharray: 3 4; }
.cv-dot { fill: var(--green); stroke: #0B1220; stroke-width: 3; }
.cv-axis { fill: #6F819D; font-size: 10px; font-family: var(--font); }
.rr-fine { font-size: 11.5px; color: #7E8FA9; line-height: 1.45; }
.hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }

.faq { display: grid; gap: 10px; margin-top: 18px; }
.faq details { border: 1px solid var(--slate-200); border-radius: 14px; padding: 4px 18px; background: #fff; }
.faq details[open] { border-color: #CFDDEE; background: #FBFDFF; }
.faq summary { cursor: pointer; padding: 12px 0; font-weight: 650; list-style: none; display: flex; justify-content: space-between; gap: 12px; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: '+'; font-size: 20px; color: var(--corp); line-height: 1; transition: transform .2s; }
.faq details[open] summary::after { transform: rotate(45deg); }
.faq p { padding: 0 0 14px; color: var(--slate-600); font-size: 14.5px; }
.help-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; margin-top: 22px; }
.help-card { padding: 20px; border-radius: 16px; background: var(--canvas); border: 1px solid var(--slate-200); scroll-margin-top: 130px; display: grid; gap: 8px; align-content: start; justify-items: start; }
.help-card p { font-size: 14px; color: var(--slate-600); }

.page-rail { padding-top: 56px; }
.page-rail > * + * { margin-top: 16px; }
.page-rail .rail-card:first-child { position: sticky; top: 130px; }
.rail-card { padding: 20px; border-radius: 18px; border: 1px solid var(--slate-200); background: #fff; display: grid; gap: 10px; }
.rail-card h3 { font-size: 16px; }
.rail-card p { font-size: 13.5px; color: var(--slate-600); }
.rail-card.dark { background: var(--navy); border-color: var(--navy); color: #fff; }
.rail-card.dark p { color: #A9B8CE; }
.rail-link { font-size: 13px; font-weight: 600; text-align: center; }
.quick-tasks { margin: 0; padding: 0; list-style: none; counter-reset: q; display: grid; gap: 2px; }
.quick-tasks li { counter-increment: q; }
.quick-tasks a { display: flex; align-items: center; gap: 10px; padding: 8px 6px; border-radius: 8px; font-weight: 600; font-size: 14px; color: var(--navy); text-decoration: none; }
.quick-tasks a::before { content: counter(q); width: 24px; height: 24px; border-radius: 50%; display: grid; place-items: center; font-size: 12px; background: var(--corp-50); color: var(--corp); flex-shrink: 0; }
.quick-tasks a:hover { background: var(--slate-50); }

.cta-band { background: linear-gradient(120deg, var(--corp) 0%, var(--navy) 70%); color: #fff; }
.cta-inner { display: flex; justify-content: space-between; align-items: center; gap: 20px; padding-top: 40px; padding-bottom: 40px; flex-wrap: wrap; }
.cta-band h2 { font-size: 28px; letter-spacing: -0.02em; }
.cta-band p { color: #B9C7DB; margin-top: 4px; }
.site-footer { background: var(--navy); color: #A9B8CE; padding: 48px 0 28px; font-size: 14px; }
.footer-cols { display: grid; grid-template-columns: 1.5fr repeat(4, 1fr); gap: 32px; }
.footer-cols h4 { color: #fff; font-size: 13px; text-transform: uppercase; letter-spacing: .1em; margin: 0 0 10px; }
.footer-cols a:not(.logo) { display: block; color: #A9B8CE; padding: 3px 0; }
.footer-cols a:not(.logo):hover { color: #fff; }
.fc-brand p { margin-top: 10px; max-width: 280px; }
.footer-legal { border-top: 1px solid rgba(255, 255, 255, .08); margin-top: 32px; padding-top: 20px; font-size: 12.5px; color: #7E8FA9; display: grid; gap: 8px; }

@media (max-width: 1100px) {
  .page-grid { grid-template-columns: 1fr; }
  .page-rail { padding-top: 0; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; }
  .page-rail > * + * { margin-top: 0; }
  .page-rail .rail-card:first-child { position: static; }
  .class-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .rater { grid-template-columns: 1fr; }
  .rater-result { position: static; }
}
@media (max-width: 860px) {
  .site .wrap { padding: 0 16px; }
  .util-note { display: none; }
  .util-inner { justify-content: center; }
  .util-links { gap: 14px; font-size: 12.5px; }
  .main-nav { display: none; position: absolute; top: 70px; left: 0; right: 0; flex-direction: column; background: #fff; border-bottom: 1px solid var(--slate-200); padding: 10px 16px 16px; box-shadow: var(--shadow); }
  body.menu-open .main-nav { display: flex; }
  .nav-toggle { display: inline-flex; }
  .header-inner { justify-content: space-between; }
  .hide-sm { display: none; }
  .hero-grid { grid-template-columns: 1fr; gap: 36px; }
  .site-hero { padding: 44px 0 60px; }
  .site-hero h1 { font-size: 40px; }
  .hero-copy p { font-size: 16px; }
  .overview-points, .cov-grid, .help-grid { grid-template-columns: 1fr; }
  .how-steps { grid-template-columns: 1fr 1fr; }
  .how-steps::before { display: none; }
  .page-rail { grid-template-columns: 1fr; }
  .footer-cols { grid-template-columns: 1fr 1fr; }
  .site-section h2 { font-size: 28px; }
}
@media (max-width: 520px) {
  .util-links a:nth-child(3) { display: none; }
  .class-grid { grid-template-columns: 1fr 1fr; gap: 10px; }
  .class-card { padding: 14px; }
  .odo-digit { width: 38px; height: 52px; }
  .odo-strip span { height: 52px; line-height: 52px; font-size: 28px; }
  .rf-row { grid-template-columns: 1fr; }
  .segmented.wide { grid-template-columns: 1fr; }
  .rb { grid-template-columns: 110px minmax(0, 1fr) auto; }
  .rr-range { font-size: 28px; }
  .example-calc { gap: 10px; }
  .float-chip.c1 { right: 0; }
}
.site .page-grid { padding-top: 16px; padding-bottom: 80px; }
.site .cta-inner { padding-top: 44px; padding-bottom: 44px; }
.statemap.compact svg { max-width: 520px; margin: 0 auto; }
.table select.input-sm { min-width: 128px; }
.table td[data-label="Policy"] a { white-space: nowrap; }
.segmented.wide label { display: block; }
.segmented.wide span { width: 100%; }
@media (max-width: 520px) {
  .site .header-cta .btn-primary { display: none; }
  .site .site-header .logo { font-size: 15px; }
  .site .site-header .logo small { display: none; }
  .example-calc { display: grid; grid-template-columns: 1fr 1fr; }
  .example-calc .op { display: none; }
  .example-calc .res { grid-column: 1 / -1; }
}

/* ================================================================== Dev Mode branding */
.logo-mark.has-img { background: #fff; overflow: hidden; padding: 0; }
.logo-mark.has-img img { width: 100%; height: 100%; object-fit: cover; display: block; }
.logo-mark.has-text b { color: var(--green); font-size: 13px; font-weight: 800; letter-spacing: .02em; line-height: 1; }
.auth-help { text-align: center; font-size: 13.5px; color: var(--muted); margin: 18px 0 0; }
.auth-help a { font-weight: 600; }
.auth-contact { display: flex; flex-wrap: wrap; gap: 6px 18px; color: #A9B8CE; font-size: 13px; margin-bottom: 14px; }
.auth-contact a { color: #DCE6F3; }
.agent-card { display: grid; gap: 10px; background: var(--canvas); border: 1px solid var(--border); border-radius: var(--radius); padding: 18px; margin: 18px 0; }
.agent-card strong { font-size: 15px; }
.fc-contact p { color: #A9B8CE; margin: 6px 0 0; font-size: 13.5px; line-height: 1.5; }
.fc-contact .fc-hours { font-size: 12.5px; color: #8FA1BC; }
.util-phone { display: inline-flex; align-items: center; gap: 6px; color: #fff !important; font-weight: 600 !important; }
.wa-float { position: fixed; right: 20px; bottom: 20px; z-index: 60; width: 56px; height: 56px; border-radius: 50%; background: #25D366; color: #fff; display: grid; place-items: center; box-shadow: 0 10px 24px -8px rgba(11, 18, 32, .45); transition: transform .2s var(--ease); }
.wa-float:hover { transform: scale(1.06); color: #fff; }
@media print { .wa-float { display: none; } }

/* ================================================================== Payment orders */
dialog.modal.lg { width: min(760px, calc(100vw - 24px)); }
.callout.blue { background: var(--corp-50); border-color: #D5E2F1; color: #1C3A5E; }
.order-cards { display: grid; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); gap: 14px; }
.order-card { display: flex; flex-direction: column; gap: 6px; padding: 18px; border-radius: var(--radius); background: #fff; border: 1px solid var(--border); border-left: 4px solid var(--amber); color: var(--text); text-decoration: none !important; box-shadow: var(--shadow-sm); transition: transform .15s var(--ease), box-shadow .15s var(--ease); }
.order-card:hover { transform: translateY(-2px); box-shadow: var(--shadow); }
.order-card.overdue { border-left-color: var(--red); }
.order-card.reported { border-left-color: var(--corp); }
.oc-top .mono { white-space: nowrap; }
.oc-top { display: flex; justify-content: space-between; align-items: center; gap: 8px; font-size: 12.5px; color: var(--muted); }
.oc-amount { font-size: 28px; font-weight: 800; letter-spacing: -0.02em; }
.oc-due { font-size: 13.5px; color: var(--slate-700); }
.order-card.overdue .oc-due { color: var(--red-700); font-weight: 600; }
.oc-desc { font-size: 13px; color: var(--muted); }
.oc-cta { margin-top: 6px; display: inline-flex; align-items: center; gap: 6px; font-weight: 700; color: var(--corp); font-size: 13.5px; }
.oc-cta svg { width: 16px; height: 16px; }
.orders-banner { border: 1px solid #F6DFB5; background: linear-gradient(180deg, #FFFBF2, #fff); border-radius: var(--radius); padding: 18px; }
.orders-banner .ob-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 14px; flex-wrap: wrap; }
.orders-banner h3 { margin: 0; display: flex; align-items: center; gap: 8px; font-size: 17px; }
.orders-banner h3 svg { color: var(--amber); }

.order-doc { padding: 28px; max-width: 920px; }
.od-head { display: flex; justify-content: space-between; gap: 20px; align-items: flex-start; padding-bottom: 20px; border-bottom: 1px solid var(--border); flex-wrap: wrap; }
.od-brand { display: flex; gap: 12px; align-items: flex-start; }
.od-brand .logo-mark { width: 44px; height: 44px; flex-shrink: 0; }
.od-brand strong { display: block; font-size: 17px; }
.od-brand > div > span { display: block; font-size: 12.5px; color: var(--muted); }
.od-title { text-align: right; display: grid; gap: 4px; justify-items: end; }
.od-title span { font-size: 11.5px; text-transform: uppercase; letter-spacing: .12em; color: var(--muted); font-weight: 700; }
.od-title b { font-size: 20px; }
.od-amount { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; margin: 22px 0; padding: 20px 22px; border-radius: var(--radius); background: var(--navy); color: #fff; }
.od-amount span { display: block; font-size: 12px; text-transform: uppercase; letter-spacing: .1em; color: #A9B8CE; font-weight: 700; }
.od-amount b { display: block; font-size: 30px; font-weight: 800; letter-spacing: -0.02em; margin-top: 2px; }
.od-amount div + div b { font-size: 21px; margin-top: 8px; }
.od-amount em { font-style: normal; font-size: 13px; color: var(--amber); font-weight: 600; }
.od-amount.late { background: linear-gradient(135deg, #3B0D0D, var(--navy)); }
.od-amount.late em { color: #FCA5A5; }
.od-grid { display: grid; grid-template-columns: 1fr 1.35fr; gap: 28px; }
.od-grid h4 { font-size: 11.5px; text-transform: uppercase; letter-spacing: .1em; color: var(--muted); margin: 0 0 6px; }
.od-grid p { margin: 0 0 16px; font-size: 14px; line-height: 1.5; }
.od-foot { margin-top: 22px; padding-top: 16px; border-top: 1px dashed var(--border); font-size: 12.5px; color: var(--muted); }
.od-foot p { margin: 0 0 4px; }
.pay-to { border: 1px solid var(--border); border-radius: var(--radius); overflow: hidden; }
.pt-head { display: flex; gap: 10px; align-items: center; padding: 12px 14px; background: var(--canvas); border-bottom: 1px solid var(--border); }
.pt-head svg { color: var(--corp); }
.pt-head strong { display: block; font-size: 14.5px; }
.pt-head span { font-size: 12.5px; color: var(--muted); }
.pt-list { margin: 0; padding: 4px 14px; }
.pt-row { display: grid; grid-template-columns: 130px 1fr; gap: 10px; align-items: center; padding: 8px 0; border-bottom: 1px solid var(--slate-100); }
.pt-row:last-child { border-bottom: 0; }
.pt-row dt { font-size: 12.5px; color: var(--muted); }
.pt-row dd { margin: 0; display: flex; align-items: center; justify-content: space-between; gap: 8px; font-weight: 600; font-size: 14px; word-break: break-word; }
.pt-row.big dd span { font-size: 17px; color: var(--corp); }
.copy-btn { width: 30px; height: 30px; border-radius: 8px; border: 1px solid var(--border); background: #fff; color: var(--muted); display: grid; place-items: center; cursor: pointer; flex-shrink: 0; }
.copy-btn:hover { color: var(--corp); border-color: var(--corp); }
.copy-btn svg { width: 15px; height: 15px; }
.pt-note { display: flex; gap: 8px; margin: 0; padding: 10px 14px; font-size: 13px; color: var(--slate-700); background: #FFFBF2; border-top: 1px solid var(--slate-100); }
.pt-note svg { width: 16px; height: 16px; color: var(--amber); flex-shrink: 0; margin-top: 2px; }
@media (max-width: 760px) {
  .od-grid, .od-amount { grid-template-columns: 1fr; }
  .od-title { text-align: left; justify-items: start; }
  .order-doc { padding: 18px; }
  .pt-row { grid-template-columns: 1fr; gap: 2px; }
}

/* ================================================================== Dev Mode */
.dev-grid { display: grid; grid-template-columns: minmax(0, 1.4fr) minmax(0, 1fr); gap: 20px; align-items: start; }
.logo-uploader { display: flex; gap: 16px; align-items: center; flex-wrap: wrap; }
.logo-uploader .logo-mark { width: 72px; height: 72px; border-radius: 16px; }
.logo-uploader .logo-mark svg { width: 36px; height: 36px; }
.logo-uploader .logo-mark.has-text b { font-size: 22px; }
.color-field { display: flex; gap: 8px; align-items: center; }
.color-field input[type=color] { width: 44px; height: 40px; padding: 2px; border-radius: 10px; border: 1px solid var(--border); background: #fff; cursor: pointer; flex-shrink: 0; }
.brand-preview { border-radius: var(--radius); overflow: hidden; border: 1px solid var(--border); }
.bp-bar { background: var(--navy); color: #fff; padding: 14px 16px; display: flex; align-items: center; gap: 10px; }
.bp-bar .logo { font-size: 15px; }
.bp-body { padding: 16px; display: grid; gap: 10px; background: var(--canvas); }
.bp-body .bp-btns { display: flex; gap: 8px; flex-wrap: wrap; }
.bp-contact { font-size: 13px; color: var(--slate-700); display: grid; gap: 4px; }
.bp-contact span { display: flex; gap: 6px; align-items: center; }
.bp-contact svg { width: 15px; height: 15px; color: var(--corp); }
.account-list { display: grid; gap: 12px; }
.account-item { display: flex; gap: 14px; align-items: flex-start; padding: 16px; border: 1px solid var(--border); border-radius: var(--radius); background: #fff; }
.account-item.inactive { opacity: .6; }
.account-item .grow { flex: 1; min-width: 0; }
.account-item .ai-title { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; font-weight: 700; }
.account-item .ai-lines { font-size: 13px; color: var(--muted); margin-top: 4px; word-break: break-word; }
.account-item .actions { flex-shrink: 0; }
@media (max-width: 960px) { .dev-grid { grid-template-columns: 1fr; } .account-item { flex-direction: column; } }

/* ================================================================== Credentials + forced password change */
.cred-box { display: grid; gap: 10px; background: var(--navy); color: #fff; border-radius: var(--radius); padding: 18px; }
.cred-box .cred-row { display: flex; justify-content: space-between; align-items: center; gap: 10px; }
.cred-box span { display: block; margin-bottom: 2px; font-size: 12px; text-transform: uppercase; letter-spacing: .1em; color: #A9B8CE; font-weight: 700; }
.cred-box b { font-family: var(--mono); font-size: 18px; word-break: break-all; }
.cred-box .copy-btn { background: transparent; color: #DCE6F3; border-color: #2F4566; }
.pw-gen { display: flex; gap: 8px; }
.pw-gen .input { font-family: var(--mono); }
.force-pw { min-height: 100vh; display: grid; place-items: center; padding: 24px 16px; background: var(--canvas); }
.force-pw .auth-card { max-width: 460px; width: 100%; background: #fff; border-radius: 20px; padding: 32px; box-shadow: var(--shadow); }

@media print {
  .sidebar, .topbar, .demo-banner, .no-print, .toasts, .scrim, .tabs { display: none !important; }
  .main { margin-left: 0 !important; }
  .content { padding: 0 !important; max-width: none; }
  body { background: #fff; }
  .order-doc { box-shadow: none; border: 0; max-width: none; padding: 0; }
  .od-amount { -webkit-print-color-adjust: exact; print-color-adjust: exact; }
}
.account-item { flex-wrap: wrap; }
.account-item .grow { flex: 1 1 260px; }
.account-item .actions { flex-basis: 100%; padding-left: 54px; }
@media (max-width: 960px) { .account-item .actions { padding-left: 0; } }
