/* Halflight Solar & Batteries: a page that follows the sun.
   Tokens on :root are the midday state. Dark tokens are the night state.
   site.js interpolates bg / fg / sky tokens between them as the sun moves. */

:root {
  --bg: #F4F7F9;
  --fg: #0D1A26;
  --muted: #3F5164;
  --sky-top: #CBE2F2;
  --sky-hor: #F8FBFC;
  --acc: #0B6665;
  --amb: #7A4B00;
  --amber: #F2A516;
  --amber-line: #C47F00;
  --teal: #11807F;
  --apricot: #F3B58A;
  --night: #0E1B2C;
  --hatch: #6F7E8C;
  --on-amber: #0D1A26;
  --surface: color-mix(in srgb, var(--fg) 4.5%, var(--bg));
  --surface-2: color-mix(in srgb, var(--fg) 8%, var(--bg));
  --line: color-mix(in srgb, var(--fg) 20%, transparent);
  --line-soft: color-mix(in srgb, var(--fg) 11%, transparent);
  --focus: #0B6665;
  --danger: #A12B1B;
  --f-display: "Unbounded", "Figtree", system-ui, sans-serif;
  --f-body: "Figtree", system-ui, -apple-system, "Segoe UI", sans-serif;
  --f-mono: "IBM Plex Mono", ui-monospace, "SF Mono", Menlo, monospace;
  --gutter: clamp(16px, 3.4vw, 48px);
  --nav-h: 72px;
  --r: 16px;
  --ease: cubic-bezier(.2, .7, .2, 1);
  color-scheme: light;
}

@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --bg: #0E1B2C;
    --fg: #EAF1F6;
    --muted: #A7B7C6;
    --sky-top: #060C16;
    --sky-hor: #1B2B45;
    --acc: #62D3CF;
    --amb: #F5B93E;
    --amber-line: #F2A516;
    --hatch: #8FA0B0;
    --focus: #62D3CF;
    --danger: #FF9C8A;
    color-scheme: dark;
  }
}
:root[data-theme="dark"] {
  --bg: #0E1B2C;
  --fg: #EAF1F6;
  --muted: #A7B7C6;
  --sky-top: #060C16;
  --sky-hor: #1B2B45;
  --acc: #62D3CF;
  --amb: #F5B93E;
  --amber-line: #F2A516;
  --hatch: #8FA0B0;
  --focus: #62D3CF;
  --danger: #FF9C8A;
  color-scheme: dark;
}

/* ---------- base ---------- */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-padding-top: calc(var(--nav-h) + 16px); }
html.lenis, html.lenis body { height: auto; }
.lenis.lenis-smooth { scroll-behavior: auto !important; }
.lenis.lenis-stopped { overflow: hidden; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--fg);
  font-family: var(--f-body);
  font-size: clamp(1rem, .96rem + .15vw, 1.0625rem);
  line-height: 1.6;
  font-variant-numeric: tabular-nums;
  overflow-x: clip;
  -webkit-font-smoothing: antialiased;
}
html.is-loading body { opacity: 0; }
img, svg { display: block; max-width: 100%; }
h1, h2, h3, h4, p, ul, ol, figure, dl, dd { margin: 0; }
ul, ol { padding: 0; list-style: none; }
a { color: inherit; text-underline-offset: .2em; text-decoration-thickness: 1px; }
a:hover { text-decoration-thickness: 2px; }
button, input, select, textarea { font: inherit; color: inherit; }
button { cursor: pointer; }
:focus-visible { outline: 3px solid var(--focus); outline-offset: 3px; border-radius: 6px; }
.sr-only { position: absolute !important; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0; }
.skip { position: fixed; left: 12px; top: -80px; z-index: 200; background: var(--amber); color: var(--on-amber); padding: 12px 18px; border-radius: 10px; font-weight: 700; transition: top .2s; }
.skip:focus { top: 12px; }
.num { font-variant-numeric: tabular-nums; }
.mono { font-family: var(--f-mono); }
.wrap { max-width: 1344px; margin-inline: auto; padding-inline: var(--gutter); }
.section { padding-block: clamp(72px, 10vw, 148px); position: relative; }
.eyebrow {
  font-family: var(--f-mono); font-size: .75rem; letter-spacing: .09em; text-transform: uppercase;
  color: var(--muted); font-weight: 500; margin-bottom: 16px; display: flex; align-items: center; gap: 10px;
}
.eyebrow::before { content: ""; width: 22px; height: 2px; background: var(--amber); border-radius: 2px; flex: none; }
.h2 { font-family: var(--f-body); font-weight: 800; font-size: clamp(2rem, 1.3rem + 3vw, 3.6rem); line-height: 1.02; letter-spacing: -.028em; text-wrap: balance; }
.lede { font-size: clamp(1.05rem, 1rem + .3vw, 1.25rem); line-height: 1.55; color: var(--muted); max-width: 58ch; text-wrap: pretty; }
.sec-head { display: grid; gap: 20px; margin-bottom: clamp(36px, 5vw, 64px); max-width: 880px; }

/* ---------- buttons ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 10px;
  min-height: 48px; padding: 0 26px; border-radius: 999px; border: 1.5px solid transparent;
  font-weight: 700; font-size: 1rem; text-decoration: none; line-height: 1; white-space: nowrap;
  transition: transform .18s var(--ease), box-shadow .18s var(--ease), background-color .18s, border-color .18s;
}
.btn svg { width: 18px; height: 18px; transition: transform .2s var(--ease); }
.btn:hover svg { transform: translateX(3px); }
.btn:active { transform: scale(.97); }
.btn--primary { background: var(--amber); color: var(--on-amber); box-shadow: 0 1px 0 rgba(255,255,255,.35) inset, 0 8px 22px -10px color-mix(in srgb, var(--amber) 90%, #000); }
.btn--primary:hover { transform: translateY(-2px); box-shadow: 0 1px 0 rgba(255,255,255,.35) inset, 0 14px 28px -10px color-mix(in srgb, var(--amber) 95%, #000); text-decoration: none; }
.btn--ghost { border-color: var(--line); background: transparent; color: var(--fg); }
.btn--ghost:hover { background: var(--surface); border-color: var(--fg); text-decoration: none; }
.btn--sm { min-height: 44px; padding: 0 20px; font-size: .9375rem; }
.btn[disabled] { opacity: .5; cursor: not-allowed; transform: none; }

/* ---------- nav ---------- */
.nav {
  position: fixed; inset: 0 0 auto 0; z-index: 60; height: var(--nav-h);
  display: flex; align-items: center;
  transition: background-color .3s, box-shadow .3s;
}
.nav.is-stuck { background: color-mix(in srgb, var(--bg) 82%, transparent); backdrop-filter: blur(14px) saturate(1.2); -webkit-backdrop-filter: blur(14px) saturate(1.2); box-shadow: 0 1px 0 var(--line-soft); }
.nav__in { width: 100%; max-width: 1536px; margin-inline: auto; padding-inline: var(--gutter); display: flex; align-items: center; gap: 28px; }
.logo { display: inline-flex; align-items: center; gap: 11px; text-decoration: none; font-weight: 800; letter-spacing: -.02em; font-size: 1.1875rem; min-height: 44px; }
.logo:hover { text-decoration: none; }
.logo svg { width: 34px; height: 34px; flex: none; }
.logo small { display: block; font-family: var(--f-mono); font-weight: 400; font-size: .625rem; letter-spacing: .1em; text-transform: uppercase; color: var(--muted); margin-top: 1px; }
.logo span { line-height: 1.05; }
.nav__links { display: flex; gap: 6px; margin-left: auto; align-items: center; }
.nav__links a:not(.btn) { padding: 0 14px; min-height: 44px; display: inline-flex; align-items: center; text-decoration: none; font-weight: 600; font-size: .9375rem; border-radius: 999px; transition: background-color .15s; }
.nav__links a:not(.btn):hover { background: var(--surface-2); text-decoration: none; }
.nav__phone { font-family: var(--f-mono); font-size: .875rem !important; font-weight: 500 !important; }
.iconbtn {
  width: 44px; height: 44px; border-radius: 50%; border: 1.5px solid var(--line); background: transparent;
  display: inline-grid; place-items: center; flex: none; transition: background-color .15s, transform .18s var(--ease);
}
.iconbtn:hover { background: var(--surface-2); }
.iconbtn:active { transform: scale(.94); }
.iconbtn svg { width: 20px; height: 20px; fill: none; stroke: currentColor; stroke-width: 1.5; stroke-linecap: round; stroke-linejoin: round; }
.theme-toggle .i-moon { display: none; }
.theme-toggle[aria-pressed="true"] .i-sun { display: none; }
.theme-toggle[aria-pressed="true"] .i-moon { display: block; }
.nav__menu { display: none; }
.mnav { display: none; }

@media (max-width: 1100px) {
  .nav__links .nav__hide-md { display: none; }
}
@media (max-width: 899px) {
  .nav__links { display: none; }
  .nav__menu { display: inline-grid; margin-left: auto; }
  .nav__in { gap: 10px; }
  .nav .theme-toggle { }
  .mnav { position: fixed; inset: 0; z-index: 90; background: var(--bg); padding: calc(var(--nav-h) + 12px) var(--gutter) 32px; display: none; flex-direction: column; gap: 4px; overflow-y: auto; }
  .mnav.is-open { display: flex; }
  .mnav a:not(.btn) { font-family: var(--f-body); font-weight: 800; font-size: 1.75rem; letter-spacing: -.02em; text-decoration: none; padding: 12px 0; border-bottom: 1px solid var(--line-soft); min-height: 56px; display: flex; align-items: center; }
  .mnav .btn { margin-top: 20px; min-height: 56px; }
  .mnav__close { position: absolute; top: 14px; right: var(--gutter); }
  .mnav__phone { font-family: var(--f-mono); font-size: 1rem !important; font-weight: 500 !important; border: 0 !important; }
}

/* ---------- hero: the day on your roof ---------- */
.hero { position: relative; }
.hero__stage { position: relative; overflow: hidden; background: linear-gradient(180deg, var(--sky-top) 0, var(--sky-hor) 55%, var(--bg) 55.1%); display: flex; flex-direction: column; padding: calc(var(--nav-h) + 14px) var(--gutter) 28px; isolation: isolate; }
.sky { position: absolute; inset: 0; width: 100%; height: 100%; z-index: 0; pointer-events: none; }
.sky .sk-hill { fill: color-mix(in srgb, var(--fg) 8%, var(--sky-hor)); }
.sky .sk-hill2 { fill: color-mix(in srgb, var(--fg) 5%, var(--sky-hor)); }
.sky .sk-roof { fill: color-mix(in srgb, var(--fg) 30%, var(--bg)); }
.sky .sk-ground { fill: var(--bg); }
.sky .sk-track { fill: none; stroke: var(--fg); stroke-opacity: .32; stroke-width: 1.5; stroke-dasharray: 2 7; stroke-linecap: round; }
.sky .sk-track--moon { stroke-opacity: .22; }
.sky .sk-horizon { stroke: var(--fg); stroke-opacity: .18; stroke-width: 1; }
.sky .sk-panel { fill: var(--amber); }
.sky .sk-win { fill: #FFD27A; }
.sky .sk-star { fill: #fff; }
.hero__left, .hero__right { min-width: 0; }
.readout, .hero__copy, .chartwrap { position: relative; z-index: 4; }
.sky--front { z-index: 3; }

.hero__stage { min-height: 100svh; }
.hero__grid { display: grid; grid-template-columns: minmax(0, 36fr) minmax(0, 64fr); column-gap: clamp(28px, 4vw, 64px); flex: 1; min-height: 0; }
.hero__left { display: flex; flex-direction: column; justify-content: space-between; gap: 24px; }
.hero__right { display: flex; flex-direction: column; min-height: 0; }

.readout { padding-top: 6px; }
.readout__where { font-family: var(--f-mono); font-size: .75rem; letter-spacing: .09em; text-transform: uppercase; color: var(--muted); display: flex; gap: 10px; align-items: center; }
.readout__where i { width: 7px; height: 7px; border-radius: 50%; background: var(--amber); display: inline-block; box-shadow: 0 0 0 4px color-mix(in srgb, var(--amber) 28%, transparent); }
.readout__time { display: flex; align-items: baseline; gap: 14px; margin-top: 18px; flex-wrap: wrap; }
.readout__clock { font-family: var(--f-mono); font-weight: 500; font-size: clamp(2.6rem, 2rem + 2.2vw, 4rem); letter-spacing: -.04em; line-height: 1; }
.readout__clock small { font-size: .42em; letter-spacing: 0; margin-left: 3px; color: var(--muted); }
.readout__phase { font-family: var(--f-mono); font-size: .8125rem; letter-spacing: .08em; text-transform: uppercase; color: var(--acc); font-weight: 500; }
.readout__tiles { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 0; margin-top: 22px; border-top: 1px solid var(--line); }
.tile { padding: 14px 12px 4px 0; position: relative; }
.tile + .tile { padding-left: 12px; border-left: 1px solid var(--line-soft); }
.tile__k { font-family: var(--f-mono); font-size: .6875rem; text-transform: uppercase; letter-spacing: .07em; color: var(--muted); display: flex; align-items: center; gap: 6px; }
.tile__k::before { content: ""; width: 9px; height: 9px; border-radius: 2px; background: var(--sw, var(--fg)); flex: none; }
.tile__v { font-family: var(--f-display); font-weight: 600; font-size: clamp(1.1rem, .9rem + .5vw, 1.5rem); letter-spacing: -.03em; margin-top: 8px; line-height: 1; white-space: nowrap; }
.tile__v small { font-family: var(--f-mono); font-weight: 400; font-size: .5em; letter-spacing: 0; color: var(--muted); margin-left: 3px; }
.tile--solar { --sw: var(--amber); }
.tile--house { --sw: var(--fg); }
.tile--batt { --sw: var(--teal); }
.tile--grid { --sw: var(--hatch); }
.readout__say { margin-top: 18px; font-size: 1rem; line-height: 1.5; color: var(--fg); max-width: 40ch; min-height: 4.6em; text-wrap: pretty; }

.hero__copy { padding-bottom: 4px; }
.hero h1 {
  font-family: var(--f-display); font-weight: 600; font-size: clamp(1.6rem, .7rem + 1.5vw, 2.5rem);
  line-height: 1.12; letter-spacing: -.04em; text-wrap: balance;
}
.hero h1 .ln { display: block; overflow: hidden; padding-bottom: .08em; margin-bottom: -.08em; }
.hero h1 .ln > span { display: block; }
.hero h1 em { font-style: normal; background: linear-gradient(transparent 62%, color-mix(in srgb, var(--amber) 70%, transparent) 62%, color-mix(in srgb, var(--amber) 70%, transparent) 92%, transparent 92%); }
.hero__copy p { margin-top: 16px; color: var(--muted); max-width: 46ch; font-size: 1rem; line-height: 1.55; }
.hero__ctas { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 20px; }
.hero__ctas .btn { padding: 0 22px; }

.arcspace { position: relative; z-index: 2; overflow: hidden; flex: 1 1 0; min-height: 190px; touch-action: pan-y; cursor: grab; }
.arcspace.is-drag { cursor: grabbing; }
.presets { position: absolute; top: 4px; right: 0; display: flex; gap: 6px; flex-wrap: wrap; justify-content: flex-end; z-index: 3; }
.chip {
  min-height: 44px; padding: 0 16px; border-radius: 999px; border: 1.5px solid var(--line);
  background: color-mix(in srgb, var(--bg) 50%, transparent); font-weight: 600; font-size: .875rem; display: inline-flex; align-items: center; gap: 8px;
  backdrop-filter: blur(6px); -webkit-backdrop-filter: blur(6px);
  transition: background-color .15s, border-color .15s, transform .15s var(--ease);
}
.chip:hover { background: var(--surface-2); border-color: var(--fg); }
.chip:active { transform: scale(.96); }
.chip[aria-pressed="true"] { background: var(--fg); color: var(--bg); border-color: var(--fg); }
.sun {
  position: absolute; left: 0; top: 0; width: 56px; height: 56px; margin: -28px 0 0 -28px; border-radius: 50%;
  z-index: 4; touch-action: none; cursor: grab; will-change: transform;
}
.sun__disc { position: absolute; inset: 0; border-radius: 50%; background: radial-gradient(circle at 38% 34%, #FFE6A6 0 18%, #F9C44B 48%, #F2A516 100%); box-shadow: 0 0 0 1px rgba(255,255,255,.4) inset, 0 0 40px 10px rgba(242,165,22,.45); transition: opacity .3s; }
.sun__moon { position: absolute; inset: 8px; border-radius: 50%; background: #E9EEF5; box-shadow: 0 0 30px 6px rgba(190,210,235,.35); opacity: 0; overflow: hidden; transition: opacity .3s; }
.sun__moon::after { content: ""; position: absolute; width: 100%; height: 100%; border-radius: 50%; background: var(--bg); left: 26%; top: -8%; transform: scale(.92); }
.sun.is-moon .sun__disc { opacity: 0; }
.sun.is-moon .sun__moon { opacity: 1; }
.sun:focus-visible { outline: 3px solid var(--focus); outline-offset: 6px; border-radius: 50%; }
.sun__hint {
  position: absolute; left: 50%; top: 100%; transform: translate(-50%, 6px); white-space: nowrap; font-family: var(--f-mono); font-size: .75rem; letter-spacing: .06em;
  text-transform: uppercase; color: var(--fg); background: color-mix(in srgb, var(--bg) 75%, transparent); padding: 4px 10px; border-radius: 999px; pointer-events: none; transition: opacity .4s;
}
.sun.is-touched .sun__hint { opacity: 0; }

.chartwrap { height: clamp(240px, 36svh, 370px); flex: none; display: flex; flex-direction: column; }
.chartbar { display: flex; justify-content: space-between; align-items: center; gap: 10px 20px; flex-wrap: wrap; padding-top: 8px; }
.legend { display: flex; flex-wrap: wrap; gap: 4px 18px; font-family: var(--f-mono); font-size: .75rem; color: var(--muted); }
.legend li { display: inline-flex; align-items: center; gap: 7px; }
.sw { width: 14px; height: 10px; border-radius: 2px; flex: none; display: inline-block; }
.sw--solar { background: var(--amber); }
.sw--batt { background: var(--teal); }
.sw--grid { background: repeating-linear-gradient(135deg, var(--hatch) 0 1.5px, transparent 1.5px 4px); border: 1px solid var(--hatch); }
.sw--use { height: 0; border-top: 2.5px solid var(--fg); border-radius: 0; }
.seg { display: inline-flex; padding: 3px; border-radius: 999px; border: 1.5px solid var(--line); background: color-mix(in srgb, var(--bg) 55%, transparent); }
.seg label { position: relative; }
.seg input { position: absolute; opacity: 0; inset: 0; width: 100%; height: 100%; margin: 0; cursor: pointer; }
.seg span { display: inline-flex; align-items: center; justify-content: center; min-height: 40px; padding: 0 16px; border-radius: 999px; font-weight: 700; font-size: .875rem; transition: background-color .2s, color .2s; white-space: nowrap; }
.seg input:checked + span { background: var(--fg); color: var(--bg); }
.seg input:focus-visible + span { outline: 3px solid var(--focus); outline-offset: 2px; }
.chart { flex: 1; min-height: 0; width: 100%; touch-action: pan-y; cursor: ew-resize; overflow: visible; }
.chart text { font-family: var(--f-mono); font-size: 11px; fill: var(--muted); }

.scrollcue { position: absolute; left: var(--gutter); bottom: 12px; display: none; }

/* pinned desktop hero: the stage sticks while scroll moves the sun */
@media (min-width: 1000px) and (min-height: 700px) {
  html.js .hero { height: 188svh; }
  html.js .hero__stage { position: sticky; top: 0; height: 100svh; min-height: 700px; }
}
@media (min-width: 1000px) and (max-height: 820px) {
  .readout__say { display: none; }
  .hero__copy p { font-size: .9375rem; margin-top: 12px; }
  .hero__ctas { margin-top: 16px; }
}
@media (max-width: 999px) {
  .hero__grid { display: flex; flex-direction: column; gap: 0; }
  .hero__left, .hero__right { display: contents; }
  .hero__copy { order: 1; padding-top: 14px; }
  .hero h1 { font-size: clamp(1.65rem, 1.1rem + 3.2vw, 2.6rem); }
  .arcspace { order: 2; flex: none; height: clamp(270px, 56vw, 400px); margin-top: 8px; }
  .chartwrap { order: 3; height: 300px; }
  .readout { order: 4; margin-top: 20px; }
  .hero__stage { padding-bottom: 36px; }
  .presets { top: auto; bottom: 44px; right: auto; left: 0; }
  .sun__hint { top: auto; bottom: 100%; transform: translate(-50%, -2px); }
  .readout__say { min-height: 0; }
}
@media (max-width: 560px) {
  .hero__ctas .btn { flex: 1 1 100%; }
  .presets .chip { padding: 0 12px; }
  .readout__tiles { grid-template-columns: repeat(2, 1fr); }
  .tile:nth-child(3) { padding-left: 0; border-left: 0; }
  .tile:nth-child(n+3) { border-top: 1px solid var(--line-soft); margin-top: 12px; }
  .chartwrap { height: 290px; }
  .legend { font-size: .6875rem; gap: 2px 12px; }
}

/* ---------- rebate clock ---------- */
.clock { background: var(--surface); border-block: 1px solid var(--line-soft); }
.clock__top { display: grid; grid-template-columns: minmax(0, 1.25fr) minmax(0, 1fr); gap: clamp(28px, 6vw, 96px); align-items: end; margin-bottom: clamp(44px, 6vw, 80px); }
.clock__days { display: flex; align-items: baseline; gap: 16px; flex-wrap: wrap; }
.clock__n { font-family: var(--f-body); font-weight: 800; font-size: clamp(4rem, 2rem + 9vw, 9rem); line-height: .85; letter-spacing: -.06em; }
.clock__u { font-family: var(--f-mono); font-size: .875rem; letter-spacing: .06em; text-transform: uppercase; color: var(--muted); max-width: 22ch; line-height: 1.4; }
.tiers { display: grid; gap: 10px; margin-top: 8px; }
.tier { display: grid; grid-template-columns: 5.5rem 1fr 3.2rem; align-items: center; gap: 14px; font-family: var(--f-mono); font-size: .8125rem; }
.tier__bar { height: 14px; border-radius: 3px; background: var(--line-soft); overflow: hidden; }
.tier__bar i { display: block; height: 100%; background: var(--teal); transform-origin: left; }
.tier b { font-weight: 500; text-align: right; }
.track { position: relative; padding-top: 76px; padding-bottom: 8px; }
.track__line { position: relative; height: 6px; border-radius: 4px; background: var(--line); }
.track__fill { position: absolute; left: 0; top: 0; bottom: 0; background: var(--amber); border-radius: 4px; }
.track__today { position: absolute; top: -66px; transform: translateX(-50%); display: flex; flex-direction: column; align-items: center; gap: 4px; font-family: var(--f-mono); font-size: .75rem; font-weight: 500; text-transform: uppercase; letter-spacing: .08em; }
.track__today::after { content: ""; width: 3px; height: 54px; background: var(--fg); border-radius: 2px; }
.track__today b { background: var(--fg); color: var(--bg); padding: 3px 9px; border-radius: 999px; font-weight: 500; }
.stops { position: relative; height: 0; }
.stop { position: absolute; top: -14px; width: min(260px, 26vw); }
.stop::before { content: ""; position: absolute; top: 0; width: 20px; height: 20px; border-radius: 50%; background: var(--bg); border: 3px solid var(--fg); }
.stop.is-past::before { background: var(--amber); border-color: var(--amber-line); }
.stop--first { left: 0; }
.stop--first::before { left: 0; }
.stop--mid { transform: translateX(-10px); }
.stop--mid::before { left: 0; }
.stop--last { right: 0; text-align: right; width: min(190px, 20vw); }
.stop--last::before { right: 0; }
.stop__d { display: block; font-family: var(--f-mono); font-size: .8125rem; font-weight: 500; letter-spacing: .04em; margin-top: 34px; }
.stop__f { display: block; font-weight: 800; font-size: 1.25rem; letter-spacing: -.02em; margin-top: 4px; line-height: 1.15; }
.stop__t { display: block; color: var(--muted); font-size: .9375rem; line-height: 1.45; margin-top: 6px; }
.stop__v { display: inline-block; font-family: var(--f-display); font-weight: 600; letter-spacing: -.03em; font-size: 1.125rem; margin-top: 10px; }
.stop__v small { font-family: var(--f-mono); font-weight: 400; font-size: .6875rem; letter-spacing: 0; color: var(--muted); display: block; margin-top: 3px; }
.clock__foot { margin-top: clamp(150px, 16vw, 210px); font-family: var(--f-mono); font-size: .75rem; color: var(--muted); max-width: 90ch; line-height: 1.6; }

@media (max-width: 899px) {
  .clock__top { grid-template-columns: 1fr; gap: 28px; align-items: start; }
  .track { padding-top: 0; padding-left: 28px; }
  .track__line { position: absolute; left: 8px; top: 8px; bottom: 8px; width: 6px; height: auto; }
  .track__fill { right: 0; bottom: auto; height: var(--fill-h, 40%); }
  .track__today { position: absolute; left: -1px; transform: none; top: var(--today-y, 50%); flex-direction: row; }
  .track__today::after { display: none; }
  .stops { height: auto; display: grid; gap: 30px; }
  .stop, .stop--first, .stop--mid, .stop--last { position: relative; top: 0; left: 0 !important; right: auto; transform: none; width: auto; text-align: left; padding-left: 4px; }
  .stop::before, .stop--first::before, .stop--mid::before, .stop--last::before { left: -28px; right: auto; top: 2px; }
  .stop__d { margin-top: 0; }
  .clock__foot { margin-top: 36px; }
  .track__today { display: none; }
}

/* ---------- estimator ---------- */
.est { background: var(--bg); }
.est__grid { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); gap: clamp(20px, 3vw, 44px); align-items: start; }
.panel { background: var(--surface); border: 1px solid var(--line-soft); border-radius: 22px; padding: clamp(20px, 3vw, 36px); }
.panel h3 { font-weight: 800; letter-spacing: -.02em; font-size: 1.25rem; }
.field { display: grid; gap: 8px; margin-top: 26px; border: 0; padding: 0; min-width: 0; }
.field > label, .field > legend { font-weight: 700; font-size: .9375rem; padding: 0; display: flex; justify-content: space-between; align-items: baseline; gap: 12px; }
.field .hint { font-size: .8125rem; color: var(--muted); font-weight: 400; font-family: var(--f-mono); }
.input {
  width: 100%; min-height: 52px; border: 1.5px solid var(--line); border-radius: 12px; background: var(--bg); padding: 0 16px; font-size: 1.0625rem; font-variant-numeric: tabular-nums;
  transition: border-color .15s, box-shadow .15s;
}
textarea.input { padding: 14px 16px; min-height: 108px; line-height: 1.5; resize: vertical; }
select.input { appearance: none; background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='14' height='9' viewBox='0 0 14 9' fill='none' stroke='%23808c98' stroke-width='1.8' stroke-linecap='round'%3E%3Cpath d='M1 1.5l6 6 6-6'/%3E%3C/svg%3E"); background-repeat: no-repeat; background-position: right 16px center; padding-right: 42px; }
.input:hover { border-color: var(--muted); }
.input:focus-visible { outline: 3px solid var(--focus); outline-offset: 2px; border-color: var(--fg); }
.input[aria-invalid="true"] { border-color: var(--danger); box-shadow: 0 0 0 3px color-mix(in srgb, var(--danger) 18%, transparent); }
.inwrap { position: relative; }
.inwrap__pre { position: absolute; left: 16px; top: 50%; transform: translateY(-50%); font-family: var(--f-mono); color: var(--muted); pointer-events: none; }
.inwrap .input { padding-left: 34px; }
.inwrap__suf { position: absolute; right: 16px; top: 50%; transform: translateY(-50%); font-family: var(--f-mono); font-size: .8125rem; color: var(--muted); pointer-events: none; }
.err { color: var(--danger); font-size: .875rem; font-weight: 600; min-height: 0; display: flex; gap: 6px; align-items: flex-start; }
.err:empty { display: none; }
.range { width: 100%; height: 44px; appearance: none; background: transparent; margin: 0; cursor: pointer; }
.range::-webkit-slider-runnable-track { height: 8px; border-radius: 6px; background: linear-gradient(90deg, var(--teal) var(--p, 50%), var(--line) var(--p, 50%)); }
.range::-moz-range-track { height: 8px; border-radius: 6px; background: var(--line); }
.range::-moz-range-progress { height: 8px; border-radius: 6px; background: var(--teal); }
.range::-webkit-slider-thumb { appearance: none; width: 28px; height: 28px; border-radius: 50%; background: var(--amber); border: 3px solid var(--bg); box-shadow: 0 0 0 1.5px var(--fg), 0 4px 10px rgba(0,0,0,.25); margin-top: -10px; transition: transform .15s var(--ease); }
.range::-moz-range-thumb { width: 24px; height: 24px; border-radius: 50%; background: var(--amber); border: 3px solid var(--bg); box-shadow: 0 0 0 1.5px var(--fg); }
.range:active::-webkit-slider-thumb { transform: scale(1.12); }
.range:focus-visible { outline: 3px solid var(--focus); outline-offset: 2px; border-radius: 8px; }
.bigval { font-family: var(--f-mono); font-weight: 500; font-size: 1.5rem; letter-spacing: -.03em; line-height: 1; }
.bigval small { font-size: .55em; color: var(--muted); margin-left: 4px; }
.opts { display: grid; grid-auto-flow: column; grid-auto-columns: 1fr; gap: 8px; }
.opt { position: relative; }
.opt input { position: absolute; opacity: 0; inset: 0; width: 100%; height: 100%; margin: 0; cursor: pointer; }
.opt span { display: flex; align-items: center; justify-content: center; text-align: center; min-height: 52px; padding: 6px 10px; border: 1.5px solid var(--line); border-radius: 12px; font-weight: 600; font-size: .9375rem; line-height: 1.2; background: var(--bg); transition: background-color .15s, border-color .15s, color .15s; }
.opt input:checked + span { background: var(--fg); color: var(--bg); border-color: var(--fg); }
.opt input:focus-visible + span { outline: 3px solid var(--focus); outline-offset: 2px; }
.opt:hover input:not(:checked) + span { border-color: var(--fg); }
.assume { margin-top: 28px; border-top: 1px solid var(--line-soft); padding-top: 18px; }
.assume summary { cursor: pointer; font-family: var(--f-mono); font-size: .8125rem; letter-spacing: .04em; min-height: 44px; display: flex; align-items: center; gap: 10px; list-style: none; }
.assume summary::-webkit-details-marker { display: none; }
.assume summary::before { content: "+"; display: inline-grid; place-items: center; width: 22px; height: 22px; border: 1.5px solid var(--line); border-radius: 50%; font-size: 14px; line-height: 1; }
.assume[open] summary::before { content: "–"; }
.assume dl { display: grid; grid-template-columns: 1fr auto; gap: 8px 16px; font-family: var(--f-mono); font-size: .75rem; color: var(--muted); margin-top: 8px; line-height: 1.45; }
.assume dd { color: var(--fg); text-align: right; }
.assume .input { min-height: 40px; width: 90px; font-family: var(--f-mono); padding-left: 24px; font-size: .875rem; }

.res { display: grid; gap: clamp(16px, 2vw, 24px); position: sticky; top: calc(var(--nav-h) + 16px); }
.res__hero { display: grid; grid-template-columns: 1fr 1fr; gap: 0; border-radius: 22px; background: var(--fg); color: var(--bg); overflow: hidden; position: relative; }
.res__cell { padding: clamp(18px, 2.4vw, 30px); min-width: 0; }
.res__cell + .res__cell { border-left: 1px solid color-mix(in srgb, var(--bg) 22%, transparent); }
.res__cell--wide { grid-column: 1 / -1; border-top: 1px solid color-mix(in srgb, var(--bg) 22%, transparent); border-left: 0 !important; }
.res__k { font-family: var(--f-mono); font-size: .75rem; letter-spacing: .07em; text-transform: uppercase; opacity: .78; display: block; }
.res__v { font-family: var(--f-display); font-weight: 600; font-size: clamp(1.9rem, 1.1rem + 2.2vw, 3.2rem); letter-spacing: -.05em; line-height: 1; margin-top: 12px; display: block; white-space: nowrap; }
.res__v small { font-size: .38em; letter-spacing: -.01em; margin-left: 4px; font-weight: 500; opacity: .8; }
.res__s { font-family: var(--f-mono); font-size: .75rem; opacity: .78; margin-top: 10px; display: block; line-height: 1.45; }
.res__cell--accent { background: var(--amber); color: var(--on-amber); }
.res__cell--accent .res__k, .res__cell--accent .res__s { opacity: .85; }
.res__row { display: grid; grid-template-columns: 1fr 1fr; gap: 0; }
.res__cell--wide { display: grid; grid-template-columns: 1fr 1fr; gap: 0; padding: 0; }
.res__cell--wide .res__cell { padding: clamp(18px, 2.4vw, 30px); }
.drop { display: flex; gap: 14px; align-items: flex-start; padding: 16px 20px; border-radius: 16px; border: 1.5px solid var(--amber-line); background: color-mix(in srgb, var(--amber) 14%, var(--bg)); font-size: .9375rem; line-height: 1.5; }
.drop svg { width: 24px; height: 24px; flex: none; margin-top: 1px; fill: none; stroke: currentColor; stroke-width: 1.5; stroke-linecap: round; stroke-linejoin: round; }
.drop strong { font-weight: 800; }
.when { margin-top: 0; }
.mini2 { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.mini { background: var(--surface); border: 1px solid var(--line-soft); border-radius: 18px; padding: 14px 16px 10px; min-width: 0; }
.mini__h { display: flex; justify-content: space-between; align-items: baseline; gap: 10px; font-weight: 700; font-size: .9375rem; }
.mini__h span { font-family: var(--f-mono); font-weight: 400; font-size: .6875rem; color: var(--muted); }
.mini svg.chart { height: 148px; cursor: default; touch-action: auto; margin-top: 6px; }
.mini__f { font-family: var(--f-mono); font-size: .75rem; color: var(--muted); margin-top: 4px; line-height: 1.45; }
.mini__f b { color: var(--fg); font-weight: 500; }
.res__foot { font-family: var(--f-mono); font-size: .6875rem; color: var(--muted); line-height: 1.6; }
.res__cta { display: flex; flex-wrap: wrap; gap: 12px; align-items: center; }
.nosolar { display: none; padding: 16px 20px; border-radius: 16px; border: 1.5px dashed var(--line); font-size: .9375rem; }
.nosolar.is-on { display: block; }

@media (max-width: 999px) {
  .est__grid { grid-template-columns: minmax(0, 1fr); }
  .res { position: static; }
}
@media (max-width: 560px) {
  .mini2 { grid-template-columns: 1fr; }
  .opts { grid-auto-flow: row; grid-auto-columns: auto; }
  .res__v { font-size: clamp(1.55rem, 7.4vw, 2rem); }
  .res__cell { padding: 16px 14px; }
}

/* ---------- install day ---------- */
.install { background: var(--surface); border-block: 1px solid var(--line-soft); }
.steps { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 0; position: relative; counter-reset: step; }
.steps::before { content: ""; position: absolute; left: 0; right: 0; top: 28px; height: 2px; background: repeating-linear-gradient(90deg, var(--line) 0 6px, transparent 6px 12px); }
.step { position: relative; padding: 0 22px 0 0; }
.step__ico { width: 56px; height: 56px; border-radius: 50%; background: var(--bg); border: 1.5px solid var(--fg); display: grid; place-items: center; position: relative; z-index: 1; }
.step--main .step__ico { background: var(--amber); border-color: var(--amber-line); color: var(--on-amber); }
.step__ico svg { width: 26px; height: 26px; fill: none; stroke: currentColor; stroke-width: 1.5; stroke-linecap: round; stroke-linejoin: round; }
.step__n { font-family: var(--f-mono); font-size: .75rem; letter-spacing: .08em; text-transform: uppercase; color: var(--muted); display: block; margin-top: 22px; }
.step h3 { font-weight: 800; font-size: 1.3125rem; letter-spacing: -.02em; line-height: 1.15; margin-top: 6px; }
.step p { margin-top: 10px; color: var(--muted); font-size: .9688rem; line-height: 1.55; }
.step__time { display: inline-block; margin-top: 14px; font-family: var(--f-mono); font-size: .75rem; padding: 5px 10px; border-radius: 999px; background: var(--bg); border: 1px solid var(--line-soft); }
.dayline { margin-top: clamp(48px, 6vw, 80px); background: var(--bg); border: 1px solid var(--line-soft); border-radius: 22px; padding: clamp(20px, 3vw, 36px); }
.dayline__h { display: flex; justify-content: space-between; gap: 16px; flex-wrap: wrap; align-items: baseline; }
.dayline__h h3 { font-weight: 800; font-size: 1.375rem; letter-spacing: -.02em; }
.dayline__h p { font-family: var(--f-mono); font-size: .75rem; color: var(--muted); }
.hours { display: grid; grid-template-columns: repeat(9, 1fr); margin-top: 26px; position: relative; font-family: var(--f-mono); font-size: .6875rem; color: var(--muted); }
.hours span { border-left: 1px solid var(--line); padding: 0 0 8px 6px; }
.blocks { display: grid; grid-template-columns: repeat(9, 1fr); gap: 6px 0; margin-top: 4px; }
.blk { padding: 10px 12px; border-radius: 10px; font-size: .8125rem; line-height: 1.35; font-weight: 600; background: var(--surface-2); border: 1px solid var(--line-soft); min-width: 0; }
.blk small { display: block; font-family: var(--f-mono); font-weight: 400; font-size: .6875rem; color: var(--muted); margin-top: 3px; }
.blk--off { background: var(--fg); color: var(--bg); border-color: var(--fg); }
.blk--off small { color: color-mix(in srgb, var(--bg) 78%, var(--fg)); }
.blk--on { background: var(--amber); color: var(--on-amber); border-color: var(--amber-line); }
.blk--on small { color: color-mix(in srgb, var(--on-amber) 78%, var(--amber)); }
.dayline__note { margin-top: 18px; font-size: .9375rem; color: var(--muted); max-width: 70ch; }

@media (max-width: 999px) {
  .steps { grid-template-columns: 1fr; gap: 34px; }
  .steps::before { left: 27px; right: auto; top: 20px; bottom: 20px; width: 2px; height: auto; background: repeating-linear-gradient(180deg, var(--line) 0 6px, transparent 6px 12px); }
  .step { display: grid; grid-template-columns: 56px 1fr; column-gap: 20px; padding: 0; }
  .step__n { margin-top: 2px; }
  .step h3 { margin-top: 4px; }
  .step > div { grid-column: 2; }
  .hours, .blocks { grid-template-columns: 1fr; }
  .hours { display: none; }
  .blocks { gap: 8px; }
  .blk { grid-column: auto !important; }
}

/* ---------- what we install ---------- */
.kinds { overflow-x: auto; margin-inline: calc(var(--gutter) * -1); padding-inline: var(--gutter); }
.tbl { width: 100%; min-width: 860px; border-collapse: separate; border-spacing: 0; font-size: .9688rem; }
.tbl caption { text-align: left; font-family: var(--f-mono); font-size: .75rem; color: var(--muted); padding-bottom: 14px; letter-spacing: .04em; }
.tbl th, .tbl td { text-align: left; vertical-align: top; padding: 22px 22px 22px 0; border-top: 1px solid var(--line); line-height: 1.5; }
.tbl thead th { font-family: var(--f-mono); font-size: .6875rem; text-transform: uppercase; letter-spacing: .08em; color: var(--muted); font-weight: 500; border-top: 0; padding-bottom: 12px; }
.tbl tbody th { font-weight: 800; font-size: 1.1875rem; letter-spacing: -.02em; width: 21%; line-height: 1.2; }
.tbl tbody th small { display: block; font-family: var(--f-mono); font-size: .6875rem; font-weight: 400; letter-spacing: .02em; color: var(--muted); margin-top: 8px; line-height: 1.4; }
.pro, .con { display: block; padding-left: 26px; position: relative; }
.pro::before, .con::before { content: ""; position: absolute; left: 0; top: .42em; width: 14px; height: 14px; border-radius: 50%; }
.pro::before { background: var(--teal); }
.con::before { border: 2px solid var(--amber-line); }
.tbl .cost { font-family: var(--f-mono); font-size: .875rem; white-space: nowrap; }
.callout { margin-top: clamp(36px, 5vw, 56px); display: grid; grid-template-columns: auto 1fr; gap: 20px; align-items: start; padding: 22px 26px; border-radius: 18px; background: var(--surface); border: 1px solid var(--line-soft); max-width: 880px; }
.callout svg { width: 34px; height: 34px; fill: none; stroke: var(--acc); stroke-width: 1.5; stroke-linecap: round; stroke-linejoin: round; }
.callout strong { font-weight: 800; }

/* ---------- map ---------- */
.areas { background: var(--surface); border-block: 1px solid var(--line-soft); overflow: hidden; }
.areas__grid { display: grid; grid-template-columns: minmax(0, 7fr) minmax(0, 5fr); gap: clamp(24px, 5vw, 72px); align-items: center; }
.map { width: 100%; height: auto; border-radius: 22px; background: color-mix(in srgb, var(--teal) 9%, var(--bg)); border: 1px solid var(--line-soft); overflow: hidden; }
.map .m-land { fill: var(--bg); stroke: var(--fg); stroke-opacity: .4; stroke-width: 1.5; }
.map .m-hills path { fill: none; stroke: var(--fg); stroke-opacity: .14; stroke-width: 1; }
.map .m-sea { font-family: var(--f-mono); font-size: 12px; letter-spacing: .18em; fill: var(--acc); text-transform: uppercase; }
.map .m-lbl { font-family: var(--f-mono); font-size: 10.5px; fill: var(--fg); paint-order: stroke; stroke: var(--bg); stroke-width: 3px; stroke-linejoin: round; pointer-events: none; }
.map .m-hq text { font-family: var(--f-body); font-weight: 800; font-size: 13px; fill: var(--fg); paint-order: stroke; stroke: var(--bg); stroke-width: 4px; stroke-linejoin: round; }
.map .m-dot { fill: var(--amber); stroke: var(--amber-line); stroke-width: 1.5; transition: r .2s var(--ease), fill .2s, opacity .25s; cursor: pointer; }
.map .m-dot.is-dim { opacity: .12; }
.map .m-dot.is-on { fill: var(--teal); stroke: var(--bg); r: 9; }
.map .m-pulse { fill: none; stroke: var(--amber-line); stroke-width: 1.5; }
.map .m-dotg:focus-visible { outline: none; }
.map .m-dotg:focus-visible .m-dot { stroke: var(--fg); stroke-width: 3; r: 9; }
.map .m-compass { font-family: var(--f-mono); font-size: 10px; fill: var(--muted); }
.check { margin-top: 28px; }
.check .out { margin-top: 14px; min-height: 3.2em; font-size: 1.0625rem; line-height: 1.45; }
.check .out strong { font-weight: 800; }
.regions { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 28px; }
.sublist { margin-top: 20px; display: flex; flex-wrap: wrap; gap: 6px 8px; }
.sublist li { font-size: .875rem; padding: 4px 12px; border-radius: 999px; border: 1px solid var(--line-soft); background: var(--bg); transition: opacity .2s, background-color .2s; }
.sublist li.is-dim { opacity: .28; }
.sublist li.is-on { background: var(--fg); color: var(--bg); }
@media (max-width: 899px) {
  .areas__grid { grid-template-columns: 1fr; }
}

/* ---------- FAQ ---------- */
.faq { max-width: 920px; }
.q { border-top: 1px solid var(--line); }
.q:last-child { border-bottom: 1px solid var(--line); }
.q h3 { font-size: inherit; }
.q__b { width: 100%; text-align: left; background: none; border: 0; padding: 24px 0; display: grid; grid-template-columns: 1fr auto; gap: 20px; align-items: center; font-weight: 800; font-size: clamp(1.125rem, 1rem + .6vw, 1.5rem); letter-spacing: -.02em; line-height: 1.2; min-height: 64px; }
.q__b:hover .q__i { background: var(--surface-2); }
.q__i { width: 40px; height: 40px; border-radius: 50%; border: 1.5px solid var(--line); display: grid; place-items: center; transition: transform .3s var(--ease), background-color .15s; }
.q__i svg { width: 18px; height: 18px; fill: none; stroke: currentColor; stroke-width: 1.5; stroke-linecap: round; }
.q__b[aria-expanded="true"] .q__i { transform: rotate(45deg); background: var(--amber); border-color: var(--amber-line); color: var(--on-amber); }
.q__p { overflow: hidden; height: 0; }
.q__p > div { padding: 0 0 28px; max-width: 70ch; color: var(--muted); font-size: 1.0313rem; line-height: 1.65; }
.q__p > div p + p { margin-top: 14px; }
.q__p strong { color: var(--fg); }
html:not(.js) .q__p { height: auto; }

/* ---------- final CTA ---------- */
.final { background: var(--night); color: #EAF1F6; position: relative; overflow: hidden; padding-block: clamp(80px, 11vw, 160px); --muted: #A7B7C6; --line: rgba(234,241,246,.22); --focus: #62D3CF; }
.final .eyebrow { color: #A7B7C6; }
.final__in { position: relative; z-index: 1; display: grid; grid-template-columns: minmax(0, 7fr) minmax(0, 5fr); gap: 48px; align-items: end; }
.final h2 { font-family: var(--f-display); font-weight: 600; font-size: clamp(2rem, 1rem + 3.6vw, 4.2rem); line-height: 1.05; letter-spacing: -.045em; text-wrap: balance; }
.final p { color: #A7B7C6; margin-top: 22px; max-width: 46ch; font-size: 1.125rem; }
.final__act { display: grid; gap: 14px; justify-items: start; }
.final .btn--ghost { color: #EAF1F6; border-color: rgba(234,241,246,.4); }
.final .btn--ghost:hover { background: rgba(234,241,246,.1); border-color: #EAF1F6; }
.final__ph { font-family: var(--f-mono); font-size: 1.125rem; }
.final__ph a { text-decoration: none; border-bottom: 2px solid var(--amber); }
.final__sun { position: absolute; right: -6vw; bottom: -22vw; width: 60vw; height: 60vw; max-width: 880px; max-height: 880px; border-radius: 50%; background: radial-gradient(circle, rgba(242,165,22,.5) 0, rgba(242,165,22,.18) 38%, transparent 66%); pointer-events: none; }
@media (max-width: 899px) { .final__in { grid-template-columns: 1fr; gap: 32px; } }

/* ---------- footer ---------- */
.foot { background: var(--night); color: #EAF1F6; padding: 0 0 36px; --muted: #A7B7C6; --focus: #62D3CF; }
.foot .wrap { border-top: 1px solid rgba(234,241,246,.16); padding-top: 48px; }
.foot__grid { display: grid; grid-template-columns: 1.3fr 1fr 1fr; gap: 40px; }
.foot h2 { font-family: var(--f-mono); font-size: .75rem; letter-spacing: .09em; text-transform: uppercase; color: #A7B7C6; font-weight: 500; margin-bottom: 14px; }
.foot p, .foot li, .foot address { font-size: .9375rem; line-height: 1.6; color: #C9D5E0; font-style: normal; }
.foot a { color: #EAF1F6; }
.foot li a { display: inline-flex; min-height: 44px; align-items: center; }
.foot .logo { color: #EAF1F6; margin-bottom: 16px; }
.foot .logo small { color: #A7B7C6; }
.foot__ack { margin-top: 40px; padding-top: 28px; border-top: 1px solid rgba(234,241,246,.16); max-width: 80ch; font-size: .9375rem; color: #C9D5E0; line-height: 1.65; }
.foot__legal { margin-top: 28px; display: flex; flex-wrap: wrap; gap: 8px 28px; justify-content: space-between; align-items: center; font-family: var(--f-mono); font-size: .75rem; color: #A7B7C6; line-height: 1.6; }
.foot__legal a { color: #EAF1F6; display: inline-flex; min-height: 44px; align-items: center; }
@media (max-width: 899px) { .foot__grid { grid-template-columns: 1fr; gap: 28px; } }

/* ---------- back to top ---------- */
.totop {
  position: fixed; right: max(16px, env(safe-area-inset-right)); bottom: max(16px, env(safe-area-inset-bottom)); z-index: 70;
  width: 52px; height: 52px; border-radius: 50%; border: 1.5px solid var(--fg); background: var(--bg); color: var(--fg);
  display: grid; place-items: center; opacity: 0; visibility: hidden; transform: translateY(12px);
  transition: opacity .25s, transform .25s var(--ease), visibility .25s, background-color .15s;
}
.totop.is-on { opacity: 1; visibility: visible; transform: none; }
.totop:hover { background: var(--amber); color: var(--on-amber); border-color: var(--amber-line); }
.totop svg { width: 22px; height: 22px; fill: none; stroke: currentColor; stroke-width: 1.5; stroke-linecap: round; stroke-linejoin: round; }

/* ---------- reveals ---------- */
html.js [data-reveal] { opacity: 0; transform: translateY(26px); }
html.js [data-reveal].is-in { opacity: 1; transform: none; transition: opacity .7s var(--ease), transform .8s var(--ease); transition-delay: var(--d, 0s); }

/* ---------- inner pages ---------- */
.page-top { padding-top: calc(var(--nav-h) + clamp(32px, 6vw, 80px)); }
.crumb { font-family: var(--f-mono); font-size: .75rem; letter-spacing: .06em; text-transform: uppercase; color: var(--muted); margin-bottom: 20px; }
.crumb a { text-decoration: none; border-bottom: 1px solid var(--line); }
.page-h1 { font-family: var(--f-display); font-weight: 600; font-size: clamp(1.9rem, 1rem + 3.4vw, 3.6rem); letter-spacing: -.045em; line-height: 1.06; text-wrap: balance; max-width: 18ch; }

.form-grid { display: grid; grid-template-columns: minmax(0, 7fr) minmax(0, 4fr); gap: clamp(24px, 5vw, 72px); align-items: start; margin-top: clamp(32px, 5vw, 64px); }
.progress { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; counter-reset: p; margin-bottom: 34px; }
.progress li { border-top: 4px solid var(--line); padding-top: 10px; font-family: var(--f-mono); font-size: .75rem; letter-spacing: .05em; text-transform: uppercase; color: var(--muted); display: flex; gap: 8px; align-items: baseline; transition: border-color .3s; }
.progress li b { font-weight: 500; }
.progress li[aria-current="step"] { border-color: var(--amber); color: var(--fg); }
.progress li.is-done { border-color: var(--teal); color: var(--fg); }
.progress li.is-done b::after { content: " – done"; }
.fstep { display: none; }
.fstep.is-on { display: block; animation: stepin .45s var(--ease); }
@keyframes stepin { from { opacity: 0; transform: translateX(18px); } to { opacity: 1; transform: none; } }
.fstep h2 { font-weight: 800; letter-spacing: -.025em; font-size: clamp(1.5rem, 1.2rem + 1.2vw, 2.1rem); line-height: 1.1; }
.fstep > p { color: var(--muted); margin-top: 10px; max-width: 56ch; }
.fcols { display: grid; grid-template-columns: 1fr 1fr; gap: 0 20px; }
.fnav { display: flex; gap: 12px; flex-wrap: wrap; align-items: center; margin-top: 36px; }
.fnav .spacer { flex: 1; }
.demo-note { font-family: var(--f-mono); font-size: .75rem; color: var(--muted); margin-top: 14px; }
.check-row { display: flex; gap: 12px; align-items: flex-start; margin-top: 22px; }
.check-row input { width: 24px; height: 24px; margin: 10px 0 0; accent-color: var(--teal); flex: none; }
.check-row label { font-size: .9375rem; line-height: 1.5; padding: 8px 0; }
.errsum { margin-top: 24px; padding: 16px 20px; border: 1.5px solid var(--danger); border-radius: 14px; background: color-mix(in srgb, var(--danger) 8%, var(--bg)); font-weight: 600; display: none; }
.errsum.is-on { display: block; }
.errsum ul { margin-top: 8px; font-weight: 400; list-style: disc; padding-left: 20px; }
.errsum a { color: var(--danger); }
.aside { position: sticky; top: calc(var(--nav-h) + 20px); display: grid; gap: 16px; }
.est-card { background: var(--fg); color: var(--bg); border-radius: 22px; padding: 26px; }
.est-card h2 { font-family: var(--f-mono); font-size: .75rem; letter-spacing: .08em; text-transform: uppercase; font-weight: 500; opacity: .8; }
.est-card dl { display: grid; gap: 14px; margin-top: 18px; }
.est-card dt { font-family: var(--f-mono); font-size: .6875rem; text-transform: uppercase; letter-spacing: .07em; opacity: .75; }
.est-card dd { font-family: var(--f-display); font-weight: 600; font-size: 1.5rem; letter-spacing: -.045em; margin-top: 4px; line-height: 1.1; }
.est-card dd small { font-family: var(--f-mono); font-weight: 400; font-size: .5em; letter-spacing: 0; opacity: .75; }
.est-card p { font-size: .8125rem; opacity: .85; margin-top: 16px; line-height: 1.5; }
.est-card a { color: inherit; }
.expect { background: var(--surface); border: 1px solid var(--line-soft); border-radius: 22px; padding: 24px 26px; }
.expect h2 { font-weight: 800; font-size: 1.125rem; letter-spacing: -.01em; }
.expect li { display: grid; grid-template-columns: 22px 1fr; gap: 12px; margin-top: 14px; font-size: .9375rem; line-height: 1.5; color: var(--muted); }
.expect li svg { width: 22px; height: 22px; fill: none; stroke: var(--acc); stroke-width: 1.5; stroke-linecap: round; stroke-linejoin: round; margin-top: 2px; }
.done { display: none; }
.done.is-on { display: block; animation: stepin .5s var(--ease); }
.done__badge { width: 64px; height: 64px; border-radius: 50%; background: var(--amber); color: var(--on-amber); display: grid; place-items: center; margin-bottom: 24px; }
.done__badge svg { width: 30px; height: 30px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.sumlist { margin-top: 28px; border-top: 1px solid var(--line); }
.sumlist div { display: grid; grid-template-columns: minmax(0, 11rem) 1fr; gap: 16px; padding: 14px 0; border-bottom: 1px solid var(--line-soft); }
.sumlist dt { font-family: var(--f-mono); font-size: .75rem; text-transform: uppercase; letter-spacing: .06em; color: var(--muted); padding-top: 3px; }
.sumlist dd { font-weight: 600; }
@media (max-width: 899px) {
  .form-grid { grid-template-columns: 1fr; }
  .aside { position: static; }
  .fcols { grid-template-columns: 1fr; }
  .progress li span { display: none; }
  .progress li[aria-current="step"] span { display: inline; }
}

.prose { max-width: 72ch; margin-top: 36px; }
.prose h2 { font-weight: 800; font-size: 1.5rem; letter-spacing: -.02em; margin: 44px 0 12px; }
.prose p, .prose li { color: var(--muted); line-height: 1.7; }
.prose p + p { margin-top: 14px; }
.prose ul { list-style: disc; padding-left: 22px; display: grid; gap: 8px; }
.prose a { color: var(--fg); }
.prose strong { color: var(--fg); }

/* ---------- print ---------- */
@media print { .totop, .nav, .mnav { display: none !important; } }

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

/* narrow phones: segmented toggles shrink instead of widening the page */
@media (max-width: 520px) {
  .seg { display: flex; max-width: 100%; }
  .seg label { flex: 1 1 0; min-width: 0; }
  .seg span { white-space: normal; text-align: center; padding: 6px 10px; font-size: .8125rem; line-height: 1.25; }
}
