/* Arisen. Tokens and reasons live in DESIGN.md. */
:root {
  --ink: #0e1b2e;
  --navy: #1a3a68;
  --paper: #f5f1e8;
  --paper-2: #ece6d9;
  --mist: #dde4ee;
  --sun: #f4a340;
  --sun-soft: #f8c27c;
  --cut: #ff7a6b;

  --text: var(--ink);
  --muted: #4a5466;
  --scrub: #7c8494;
  --on-dark: var(--paper);
  --on-dark-muted: #a9b6c8;
  --wire: #4d6a96;

  --font-display: "Montserrat", "Segoe UI", system-ui, sans-serif;
  --font-body: "Archivo", "Segoe UI", system-ui, sans-serif;

  --gutter: clamp(1rem, 4vw, 3rem);
  --max: 1320px;
  --radius-s: 4px;
  --radius-m: 8px;
  --ease-out: cubic-bezier(0.22, 1, 0.36, 1);
  --header-h: 72px;
}

@media (max-width: 720px) {
  :root { --header-h: 60px; }
}

*, *::before, *::after { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; scroll-padding-top: calc(var(--header-h) + 1rem); }
html.lenis, html.lenis body { height: auto; }
.lenis.lenis-smooth { scroll-behavior: auto !important; }

body {
  margin: 0;
  background: var(--paper);
  color: var(--text);
  font-family: var(--font-body);
  font-size: clamp(1rem, 0.96rem + 0.2vw, 1.0625rem);
  line-height: 1.6;
  text-rendering: optimizeLegibility;
  -webkit-font-smoothing: antialiased;
  overflow-x: clip;
}

img, svg { display: block; max-width: 100%; }
a { color: inherit; }
p { margin: 0 0 1em; }
h1, h2, h3 { font-family: var(--font-display); line-height: 1.05; margin: 0; letter-spacing: -0.02em; }
h2 { font-size: clamp(2rem, 1.3rem + 2.8vw, 3.6rem); font-weight: 800; }
h3 { font-size: clamp(1.2rem, 1.05rem + 0.6vw, 1.5rem); font-weight: 700; letter-spacing: -0.01em; }
button, input, select, textarea { font: inherit; color: inherit; }
main:focus { outline: none; }

:focus-visible { outline: 3px solid var(--sun); outline-offset: 3px; }
.on-light :focus-visible, .statement :focus-visible, .planner :focus-visible, .catalogue :focus-visible,
.notes :focus-visible, .prose-wrap :focus-visible, .contact :focus-visible, .products :focus-visible, .news-list :focus-visible {
  outline-color: var(--navy);
}

.visually-hidden {
  position: absolute !important; width: 1px; height: 1px; margin: -1px; padding: 0;
  overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0;
}
.symbol-defs { position: absolute; width: 0; height: 0; overflow: hidden; }

.skip {
  position: fixed; left: 1rem; top: -100px; z-index: 100;
  background: var(--sun); color: var(--ink); padding: 0.75rem 1rem; border-radius: var(--radius-s);
  font-weight: 600; text-decoration: none;
}
.skip:focus { top: 1rem; }

/* ---------- Buttons and links ---------- */
.btn {
  position: relative; isolation: isolate; overflow: hidden;
  display: inline-flex; align-items: center; justify-content: center; gap: 0.5rem;
  min-height: 48px; padding: 0 1.4rem;
  border: 1.5px solid transparent; border-radius: var(--radius-m);
  font-family: var(--font-display); font-weight: 700; font-size: 0.95rem; letter-spacing: 0;
  text-decoration: none; cursor: pointer;
  transition: transform 0.18s var(--ease-out), color 0.25s, border-color 0.25s;
}
/* The fill rises from the bottom edge on hover: a small sunrise, the site's one recurring gesture. */
.btn::before {
  content: ""; position: absolute; inset: 0; z-index: -1;
  transform: scaleY(0); transform-origin: 50% 100%;
  transition: transform 0.35s var(--ease-out);
}
.btn:hover::before { transform: scaleY(1); }
.btn:active { transform: translateY(1px) scale(0.98); }
.btn--sun { background: var(--sun); color: var(--ink); }
.btn--sun::before { background: var(--sun-soft); }
.btn--ghost { border-color: currentColor; color: var(--paper); }
.btn--ghost::before { background: var(--paper); }
.btn--ghost:hover { color: var(--ink); border-color: var(--paper); }
.btn--ink { background: var(--ink); color: var(--paper); }
.btn--ink::before { background: var(--navy); }
.btn--small { min-height: 44px; padding: 0 1rem; font-size: 0.875rem; white-space: nowrap; }

/* Arrow kept for text-only links, where it is the only cue that the line is clickable. */
.link-arrow {
  display: inline-flex; align-items: center; gap: 0.6rem; min-height: 44px;
  font-family: var(--font-display); font-weight: 700; text-decoration: none;
  background: linear-gradient(currentColor, currentColor) 0 calc(100% - 8px) / 100% 2px no-repeat;
  transition: background-size 0.35s var(--ease-out);
}
.link-arrow::after { content: "→"; transition: transform 0.3s var(--ease-out); }
.link-arrow:hover { background-size: 0% 2px; background-position: 100% calc(100% - 8px); }
.link-arrow:hover::after { transform: translateX(4px); }

/* ---------- Header ---------- */
.site-header {
  position: fixed; inset: 0 0 auto; z-index: 50;
  color: var(--paper);
  transition: background-color 0.35s, color 0.35s, transform 0.4s var(--ease-out), box-shadow 0.35s;
}
.site-header__inner {
  display: flex; align-items: center; gap: 1.5rem;
  max-width: var(--max); margin: 0 auto; height: var(--header-h); padding: 0 var(--gutter);
}
.site-header[data-state="solid"] {
  background: rgb(245 241 232 / 0.97); color: var(--ink);
  box-shadow: 0 1px 0 rgb(14 27 46 / 0.12);
}
.site-header[data-hidden="true"] { transform: translateY(-100%); }
.site-header[data-state="solid"] :focus-visible { outline-color: var(--navy); }

.brand { display: flex; align-items: center; gap: 0.6rem; text-decoration: none; min-height: 44px; margin-right: auto; }
.brand__mark { width: auto; height: 42px; }
.brand__mark--colour { display: none; }
.site-header[data-state="solid"] .brand__mark--colour { display: block; }
.site-header[data-state="solid"] .brand__mark--light { display: none; }
/* Set like the logo's wordmark: capitals, with SOLAR in the logo's orange. On the light header the orange
   is the deeper #A15A0A so it still reads at 4.7:1 on paper. */
.brand__name { font-family: var(--font-display); font-weight: 800; font-size: 1.05rem; line-height: 1.1; letter-spacing: 0.03em; text-transform: uppercase; white-space: nowrap; }
.brand__solar { color: var(--sun); }
.site-header[data-state="solid"] .brand__solar { color: #a15a0a; }
.site-header.is-open .brand__solar { color: var(--sun); }
/* Below this width the full name no longer fits beside the menu on one line, so it stacks. */
@media (max-width: 1240px) {
  .brand__name { font-size: 0.95rem; }
  .brand__w1, .brand__rest { display: block; }
  .brand__w1 { font-size: 1.3em; letter-spacing: 0.06em; }
  .brand__rest { font-size: 0.72em; letter-spacing: 0.05em; }
}
/* Very narrow phones (320 to 380px): a smaller lockup and tighter spacing keep the name clear of the Menu button. */
@media (max-width: 380px) {
  .site-header__inner { gap: 0.75rem; }
  .brand { gap: 0.45rem; }
  .brand__mark { height: 32px; }
  .brand__name { font-size: 0.8rem; }
  .menu-toggle { padding-left: 0.4rem; gap: 0.45rem; }
}

.site-nav ul { display: flex; gap: 0.25rem; list-style: none; margin: 0; padding: 0; }
.site-nav a {
  position: relative; display: inline-flex; align-items: center; min-height: 44px; padding: 0 0.85rem;
  font-weight: 500; text-decoration: none;
}
.site-nav a::after {
  content: ""; position: absolute; left: 0.85rem; right: 0.85rem; bottom: 8px; height: 2px;
  background: currentColor; transform: scaleX(0); transform-origin: 0 50%; transition: transform 0.3s var(--ease-out);
}
.site-nav a:hover::after, .site-nav a[aria-current="page"]::after { transform: scaleX(1); }

.menu-toggle {
  display: none; align-items: center; gap: 0.6rem; min-height: 44px; padding: 0 0.25rem 0 0.75rem;
  background: none; border: 0; cursor: pointer; font-family: var(--font-display); font-weight: 700;
}
.menu-toggle__icon { position: relative; width: 22px; height: 12px; }
.menu-toggle__icon i { position: absolute; left: 0; right: 0; height: 2px; background: currentColor; transition: transform 0.3s var(--ease-out); }
.menu-toggle__icon i:first-child { top: 0; }
.menu-toggle__icon i:last-child { top: 10px; }
.menu-toggle[aria-expanded="true"] .menu-toggle__icon i:first-child { transform: translateY(5px) rotate(45deg); }
.menu-toggle[aria-expanded="true"] .menu-toggle__icon i:last-child { transform: translateY(-5px) rotate(-45deg); }

.mobile-menu {
  position: fixed; inset: var(--header-h) 0 0; overflow-y: auto;
  background: var(--ink); color: var(--paper);
  padding: 1.5rem var(--gutter) calc(2rem + env(safe-area-inset-bottom));
  display: flex; flex-direction: column; gap: 2rem;
}
.mobile-menu[hidden] { display: none; }
.mobile-menu ul { list-style: none; margin: 0; padding: 0; }
.mobile-menu nav a {
  display: block; padding: 0.6rem 0; font-family: var(--font-display); font-weight: 800;
  font-size: clamp(2rem, 9vw, 2.75rem); text-decoration: none; line-height: 1.1;
}
.mobile-menu nav a[aria-current="page"] { color: var(--sun); }
.mobile-menu__contact { display: grid; gap: 0.75rem; justify-items: start; }
.mobile-menu__contact a:not(.btn) { min-height: 44px; display: inline-flex; align-items: center; color: var(--on-dark-muted); }
.mobile-menu :focus-visible { outline-color: var(--sun); }
.site-header.is-open { background: var(--ink); color: var(--paper); box-shadow: none; }
.site-header.is-open .brand__mark--light { display: block; }
.site-header.is-open .brand__mark--colour { display: none; }

@media (max-width: 1024px) {
  .site-nav, .site-header__cta { display: none; }
  .menu-toggle { display: inline-flex; }
}

/* ---------- Section scaffolding ---------- */
section { position: relative; }
.section-head {
  display: grid; grid-template-columns: 4.5rem minmax(0, 1fr); column-gap: 1.25rem; align-items: start;
  max-width: var(--max); margin: 0 auto clamp(2rem, 5vw, 4rem); padding: 0 var(--gutter);
}
.section-head > :not(.marker) { grid-column: 2; }
.section-head h2 { max-width: 18ch; }
.section-head p { max-width: 58ch; margin-top: 1rem; color: var(--muted); font-size: 1.1rem; }
.section-head--light p { color: var(--on-dark-muted); }

/* Sunrise marker: the arc fills as the reader moves through the section. */
.marker { grid-row: 1 / span 3; display: grid; justify-items: center; gap: 0.15rem; padding-top: 0.4rem; color: var(--navy); }
.section-head--light .marker { color: var(--sun); }
.marker svg { width: 48px; height: 26px; overflow: visible; }
.marker__track { fill: none; stroke: currentColor; stroke-opacity: 0.25; stroke-width: 2.5; }
.marker__fill { fill: none; stroke: currentColor; stroke-width: 2.5; stroke-linecap: round; stroke-dasharray: 1; stroke-dashoffset: var(--marker-off, 1); }
.marker span { font-family: var(--font-display); font-weight: 700; font-size: 0.85rem; }

@media (max-width: 720px) {
  .section-head { grid-template-columns: 1fr; }
  .section-head > :not(.marker) { grid-column: 1; }
  .marker { grid-row: auto; display: flex; align-items: flex-end; gap: 0.6rem; margin-bottom: 1rem; }
}

/* ---------- Hero ---------- */
.hero {
  position: relative; min-height: 560px; height: 100svh; overflow: hidden;
  background: linear-gradient(180deg, #0b1626 0%, #1a3a68 38%, #c9744a 52%, #0b1626 53%, #0e1b2e 100%);
  color: var(--paper);
}
.hero__scene, .hero__canvas { position: absolute; inset: 0; width: 100%; height: 100%; }
.hero__canvas { opacity: 0; transition: opacity 1.2s ease; touch-action: pan-y; }
.hero.is-live .hero__canvas { opacity: 1; }
/* Scrim keeps the headline above 4.5:1 wherever it sits over panels or bright sky. */
.hero__scrim {
  position: absolute; inset: 0; pointer-events: none;
  background:
    linear-gradient(0deg, rgb(11 22 38 / 0.92) 0%, rgb(11 22 38 / 0.72) 32%, rgb(11 22 38 / 0) 62%),
    linear-gradient(90deg, rgb(11 22 38 / 0.55) 0%, rgb(11 22 38 / 0) 55%);
}
.hero__content {
  position: absolute; left: 0; right: 0; bottom: 0;
  max-width: var(--max); margin: 0 auto; padding: 0 var(--gutter) clamp(3rem, 9vh, 6rem);
  pointer-events: none;
}
.hero__content a { pointer-events: auto; }
.hero__title { font-size: clamp(2.9rem, 1.6rem + 6.4vw, 8rem); font-weight: 800; line-height: 0.96; letter-spacing: -0.035em; margin-bottom: 1.5rem; }
.hero__title .line { display: block; overflow: hidden; padding-bottom: 0.06em; }
.hero__title .line > span { display: block; }
.hero__lede { max-width: 46ch; font-size: clamp(1.05rem, 1rem + 0.35vw, 1.25rem); color: #dfe6ef; }
.hero__actions { display: flex; flex-wrap: wrap; gap: 0.75rem; margin-top: 1.75rem; }
.hero__hint {
  position: absolute; right: var(--gutter); top: calc(var(--header-h) + 1.5rem); max-width: 22ch; margin: 0;
  font-size: 0.875rem; color: #dfe6ef; text-align: right; opacity: 0; transition: opacity 0.6s;
}
.hero.is-live .hero__hint { opacity: 0.9; }
.hero.is-steered .hero__hint { opacity: 0; }
@media (max-width: 720px) {
  .hero__hint { display: none; }
  .hero__actions .btn { flex: 1 1 100%; }
}

/* ---------- Statement ---------- */
.statement { padding: clamp(5rem, 12vw, 10rem) 0 clamp(4rem, 9vw, 8rem); }
.statement .section-head { margin-bottom: 0; }
.statement__body {
  max-width: var(--max); margin: -3.5rem auto 0; padding: 0 var(--gutter) 0 calc(var(--gutter) + 5.75rem);
}
.statement__lead { font-family: var(--font-display); font-weight: 600; font-size: clamp(1.7rem, 1rem + 2.8vw, 3.4rem); line-height: 1.12; letter-spacing: -0.02em; max-width: 22ch; }
.statement__lead em { font-style: normal; color: var(--navy); }
.statement__text { max-width: 52ch; margin: 2rem 0 0 auto; font-size: 1.15rem; color: var(--muted); }
.statement__scrub {
  max-width: 24ch; margin: clamp(3rem, 8vw, 6rem) 0 2rem;
  font-family: var(--font-display); font-weight: 800; font-size: clamp(1.9rem, 1rem + 3.6vw, 4.25rem); line-height: 1.04; letter-spacing: -0.03em;
}
.js .statement__scrub .w { color: var(--scrub); transition: color 0.2s linear; }
.js .statement__scrub .w.is-lit { color: var(--ink); }
@media (max-width: 720px) {
  .statement__body { margin-top: 0; padding-left: var(--gutter); }
  .statement__text { margin-left: 0; }
}

/* ---------- Systems ---------- */
.systems { background: var(--ink); color: var(--on-dark); padding: clamp(4.5rem, 10vw, 8rem) 0; }
.systems__app {
  max-width: var(--max); margin: 0 auto; padding: 0 var(--gutter);
  display: grid; grid-template-columns: minmax(0, 1.55fr) minmax(0, 1fr); gap: clamp(1.5rem, 4vw, 4rem);
  grid-template-areas: "controls controls" "stage readout";
}
.systems__controls { grid-area: controls; display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 1rem 2rem; }
.systems__stage { grid-area: stage; min-width: 0; }
.systems__readout { grid-area: readout; align-self: center; }

.tabs { display: flex; gap: 0.25rem; border-bottom: 1px solid rgb(245 241 232 / 0.18); }
.tabs button {
  position: relative; min-height: 48px; padding: 0 1rem; background: none; border: 0; cursor: pointer;
  font-family: var(--font-display); font-weight: 700; font-size: 1.05rem; color: var(--on-dark-muted);
  transition: color 0.25s;
}
.tabs button::after {
  content: ""; position: absolute; left: 0.5rem; right: 0.5rem; bottom: -1px; height: 3px; background: var(--sun);
  transform: scaleX(0); transition: transform 0.35s var(--ease-out);
}
.tabs button:hover { color: var(--paper); }
.tabs button[aria-selected="true"] { color: var(--paper); }
.tabs button[aria-selected="true"]::after { transform: scaleX(1); }

.toggles { display: flex; flex-wrap: wrap; gap: 0.75rem 1.25rem; align-items: center; }
.segmented { display: inline-flex; margin: 0; padding: 3px; border: 1.5px solid rgb(245 241 232 / 0.35); border-radius: var(--radius-m); }
.segmented label { position: relative; }
.segmented input { position: absolute; opacity: 0; inset: 0; margin: 0; cursor: pointer; }
.segmented span { display: inline-flex; align-items: center; min-height: 40px; padding: 0 1rem; border-radius: 5px; font-weight: 600; transition: background-color 0.25s, color 0.25s; }
.segmented input:checked + span { background: var(--paper); color: var(--ink); }
.segmented input:focus-visible + span { outline: 3px solid var(--sun); outline-offset: 2px; }

.switch { display: inline-flex; align-items: center; gap: 0.7rem; min-height: 44px; cursor: pointer; position: relative; font-weight: 600; }
.switch input { position: absolute; opacity: 0; width: 1px; height: 1px; }
.switch__track { position: relative; width: 52px; height: 30px; border-radius: 15px; border: 1.5px solid rgb(245 241 232 / 0.5); transition: background-color 0.25s, border-color 0.25s; }
.switch__thumb { position: absolute; top: 3px; left: 3px; width: 21px; height: 21px; border-radius: 50%; background: var(--paper); transition: transform 0.3s var(--ease-out); }
.switch input:checked + .switch__track { background: var(--cut); border-color: var(--cut); }
.switch input:checked + .switch__track .switch__thumb { transform: translateX(22px); background: var(--ink); }
.switch input:focus-visible + .switch__track { outline: 3px solid var(--sun); outline-offset: 3px; }

.flow-diagram { width: 100%; height: auto; overflow: visible; }
.flow-diagram text { fill: var(--on-dark-muted); font: 500 17px var(--font-body); text-anchor: middle; }
.fd-node > path, .fd-node > rect, .fd-node > circle { fill: none; stroke: #8fa6c6; stroke-width: 2.5; stroke-linejoin: round; stroke-linecap: round; transition: stroke 0.4s, opacity 0.4s; }
.fd-node { transition: opacity 0.5s; }
.fd-node.is-absent { opacity: 0.22; }
.fd-node.is-on > path, .fd-node.is-on > rect { stroke: var(--paper); }
.fd-screen { fill: rgb(244 163 64 / 0) !important; transition: fill 0.4s !important; }
.fd-node.is-on .fd-screen { fill: rgb(244 163 64 / 0.85) !important; stroke: var(--sun) !important; }
.fd-charge { fill: var(--sun) !important; stroke: none !important; transform-box: fill-box; transform-origin: 0 50%; transform: scaleX(var(--charge, 0.6)); transition: transform 1.2s var(--ease-out), opacity 0.4s !important; }
.fd-window { fill: #16253c !important; transition: fill 0.5s !important; }
.fd-home.is-lit .fd-window { fill: var(--sun) !important; stroke: var(--sun) !important; }
.fd-sun circle { fill: var(--sun); }
.fd-sun path { stroke: var(--sun); stroke-width: 4; stroke-linecap: round; }
.fd-moon path { fill: #c9d4e3; }
.fd-sun, .fd-moon { transform-box: fill-box; transform-origin: 50% 50%; transition: opacity 0.6s, transform 0.8s var(--ease-out); }
.flow-diagram[data-tod="night"] .fd-sun { opacity: 0; transform: translateY(40px) scale(0.6); }
.flow-diagram[data-tod="day"] .fd-moon { opacity: 0; transform: translateY(-30px) scale(0.6); }
.fd-ray { stroke: var(--sun); stroke-width: 3; stroke-dasharray: 3 10; stroke-linecap: round; fill: none; transition: opacity 0.4s; }
.flow-diagram[data-tod="night"] .fd-ray { opacity: 0; }
.fd-wire { fill: none; stroke: var(--wire); stroke-width: 4; stroke-linecap: round; transition: opacity 0.4s; }
.fd-flow { fill: none; stroke: var(--sun); stroke-width: 4; stroke-linecap: round; stroke-dasharray: 2 16; opacity: 0; transition: opacity 0.4s; }
[data-edge-group][data-flow="fwd"] .fd-flow, [data-edge-group][data-flow="rev"] .fd-flow { opacity: 1; animation: flow 0.9s linear infinite; }
[data-edge-group][data-flow="rev"] .fd-flow { animation-direction: reverse; }
[data-edge-group][data-flow="none"] .fd-wire { opacity: 0.15; }
@keyframes flow { to { stroke-dashoffset: -18; } }
.fd-cut path { stroke: var(--cut); stroke-width: 5; stroke-linecap: round; }
.fd-cut { opacity: 0; transform-box: fill-box; transform-origin: 50% 50%; transform: scale(0.4); transition: opacity 0.3s, transform 0.4s var(--ease-out); }
.flow-diagram[data-cut="true"] .fd-cut { opacity: 1; transform: scale(1); }

.systems__status { display: flex; align-items: center; gap: 0.6rem; font-weight: 600; min-height: 1.6em; }
/* The lamp marks a real state in the simulation: whether the house has power. */
.systems__lamp { width: 12px; height: 12px; border-radius: 50%; background: var(--sun); flex: none; transition: background-color 0.3s; }
.systems__lamp.is-off { background: transparent; box-shadow: inset 0 0 0 2px var(--cut); }
.systems__readout h3 { font-size: clamp(1.8rem, 1.3rem + 1.8vw, 2.6rem); font-weight: 800; margin: 1.25rem 0 0.75rem; }
.systems__readout > p:not(.systems__status) { color: #dfe6ef; font-size: 1.08rem; }
.systems__facts { margin: 1.5rem 0 0; display: grid; gap: 1rem; }
.systems__facts div { border-top: 1px solid rgb(245 241 232 / 0.2); padding-top: 0.75rem; }
.systems__facts dt { font-family: var(--font-display); font-weight: 700; font-size: 0.9rem; color: var(--sun); }
.systems__facts dd { margin: 0.25rem 0 0; color: #dfe6ef; }

@media (max-width: 960px) {
  .systems__app { grid-template-columns: 1fr; grid-template-areas: "controls" "stage" "readout"; }
}

/* ---------- Planner ---------- */
.planner { padding: clamp(4.5rem, 10vw, 8rem) 0; }
.planner__grid {
  max-width: var(--max); margin: 0 auto; padding: 0 var(--gutter);
  display: grid; grid-template-columns: minmax(0, 1.1fr) minmax(0, 1fr); gap: clamp(2rem, 5vw, 5rem); align-items: start;
}
.planner__label { display: flex; align-items: baseline; justify-content: space-between; gap: 1rem; font-family: var(--font-display); font-weight: 700; font-size: 1.15rem; margin-bottom: 0.75rem; padding: 0; }
.planner__label output { font-size: clamp(1.9rem, 1.2rem + 3vw, 3.5rem); font-weight: 800; line-height: 1; color: var(--navy); font-variant-numeric: tabular-nums; white-space: nowrap; }
.planner__summary { font-size: 1.1rem; margin: 1.25rem 0; }

.range { -webkit-appearance: none; appearance: none; width: 100%; height: 44px; background: none; cursor: pointer; margin: 0; }
.range::-webkit-slider-runnable-track { height: 8px; border-radius: 4px; background: linear-gradient(90deg, var(--navy) var(--pct, 43%), #c5ccd8 var(--pct, 43%)); }
.range::-moz-range-track { height: 8px; border-radius: 4px; background: #c5ccd8; }
.range::-moz-range-progress { height: 8px; border-radius: 4px; background: var(--navy); }
.range::-webkit-slider-thumb { -webkit-appearance: none; width: 30px; height: 30px; margin-top: -11px; border-radius: 50%; background: var(--sun); border: 3px solid var(--ink); transition: transform 0.2s var(--ease-out); }
.range::-moz-range-thumb { width: 26px; height: 26px; border-radius: 50%; background: var(--sun); border: 3px solid var(--ink); }
.range:active::-webkit-slider-thumb { transform: scale(1.15); }
.range:focus-visible { outline: 3px solid var(--navy); outline-offset: 4px; border-radius: 4px; }
.range__ticks { display: flex; justify-content: space-between; padding: 0 9px; font-size: 0.85rem; color: var(--muted); font-variant-numeric: tabular-nums; }

.range__ticks--scale { position: relative; display: block; height: 1.4em; padding: 0; }
.range__ticks--scale span { position: absolute; left: calc(15px + var(--at) * (100% - 30px)); transform: translateX(-50%); white-space: nowrap; }
.range__ticks--scale span:first-child { left: 0; transform: none; }
.range__ticks--scale span:last-child { left: auto; right: 0; transform: none; }

/* 24-hour strip from 18:00: each cell is an hour, filled for the hours the battery covers. */
.clock { margin-top: 1.5rem; }
.clock__label { font-size: 0.9rem; font-weight: 600; margin-bottom: 0.5rem; }
.clock__cells { display: grid; grid-template-columns: repeat(24, minmax(0, 1fr)); gap: 2px; }
.clock__cells i { position: relative; height: 34px; background: var(--paper-2); border-radius: 2px; overflow: hidden; }
.clock__cells i::after { content: ""; position: absolute; inset: 0; background: var(--navy); transform: scaleX(var(--fill, 0)); transform-origin: 0 50%; transition: transform 0.35s var(--ease-out); transition-delay: calc(var(--i) * 12ms); }
.clock__axis { display: flex; justify-content: space-between; margin-top: 0.35rem; font-size: 0.75rem; color: var(--muted); }
.clock__axis b { font-weight: 400; }
.fineprint { font-size: 0.9rem; color: var(--muted); max-width: 60ch; margin-top: 1rem; }

.chips { display: flex; flex-wrap: wrap; gap: 0.5rem; border: 0; margin: 0 0 2rem; padding: 0; }
.chips legend { width: 100%; }
.chip { position: relative; cursor: pointer; }
.chip input { position: absolute; opacity: 0; inset: 0; margin: 0; cursor: pointer; }
.chip span {
  display: inline-flex; align-items: center; gap: 0.5rem; min-height: 44px; padding: 0 0.9rem;
  border: 1.5px solid var(--navy); border-radius: var(--radius-m); font-weight: 500;
  transition: background-color 0.2s, color 0.2s, transform 0.15s var(--ease-out);
}
.chip small { font-size: 0.8rem; color: var(--muted); transition: color 0.2s; }
.chip input:checked + span { background: var(--navy); color: var(--paper); }
.chip input:checked + span small { color: #c9d4e3; }
.chip input:active + span { transform: scale(0.97); }
.chip input:focus-visible + span { outline: 3px solid var(--navy); outline-offset: 3px; }

.result { background: var(--ink); color: var(--paper); border-radius: var(--radius-m); padding: clamp(1.5rem, 3vw, 2.25rem); }
.result__load { margin: 0; color: var(--on-dark-muted); }
.result__load strong { color: var(--paper); font-variant-numeric: tabular-nums; }
.result__hours { display: flex; flex-wrap: wrap; align-items: baseline; gap: 0.25rem 0.75rem; margin: 0.25rem 0 1.25rem; }
.result__num { font-family: var(--font-display); font-weight: 800; font-size: clamp(3.5rem, 2.5rem + 4vw, 6rem); line-height: 1; letter-spacing: -0.04em; color: var(--sun); font-variant-numeric: tabular-nums; }
.result__unit { font-weight: 600; }
.result__verdict { font-size: 1.1rem; font-weight: 600; }
.result .fineprint { color: var(--on-dark-muted); margin-bottom: 0; }

@media (max-width: 960px) {
  .planner__grid { grid-template-columns: 1fr; }
}
@media (max-width: 520px) {
  .clock__cells { gap: 1px; }
  .clock__cells i { height: 28px; }
}

/* ---------- Catalogue ---------- */
.catalogue { background: var(--mist); padding: clamp(4.5rem, 10vw, 8rem) 0; }
.catalogue__list { list-style: none; margin: 0 auto; padding: 0 var(--gutter); max-width: var(--max); counter-reset: cat; }
.catalogue__list li { counter-increment: cat; border-top: 1.5px solid rgb(26 58 104 / 0.35); }
.catalogue__list li:last-child { border-bottom: 1.5px solid rgb(26 58 104 / 0.35); }
.cat-row {
  position: relative; isolation: isolate; overflow: hidden;
  display: grid; grid-template-columns: 3rem minmax(0, 1.1fr) minmax(0, 1fr) 132px; align-items: center; gap: 1.5rem;
  min-height: 132px; padding: 1rem 1rem; text-decoration: none; color: var(--ink);
  transition: color 0.35s var(--ease-out);
}
.cat-row::before {
  content: counter(cat, decimal-leading-zero); font-family: var(--font-display); font-weight: 700; font-size: 0.9rem; color: var(--navy);
  transition: color 0.35s;
}
.cat-row::after {
  content: ""; position: absolute; inset: 0; z-index: -1; background: var(--navy);
  transform: scaleY(0); transform-origin: 50% 100%; transition: transform 0.45s var(--ease-out);
}
.cat-row:hover, .cat-row:focus-visible { color: var(--paper); }
.cat-row:hover::after, .cat-row:focus-visible::after { transform: scaleY(1); }
.cat-row:hover::before, .cat-row:focus-visible::before { color: var(--sun); }
.cat-row:focus-visible { outline-offset: -3px; outline-color: var(--sun); }
.cat-row__name { font-family: var(--font-display); font-weight: 800; font-size: clamp(1.7rem, 1.1rem + 2.4vw, 3.2rem); letter-spacing: -0.03em; line-height: 1; transition: transform 0.45s var(--ease-out); }
.cat-row:hover .cat-row__name { transform: translateX(0.5rem); }
.cat-row__desc { color: var(--muted); transition: color 0.35s; }
.cat-row:hover .cat-row__desc, .cat-row:focus-visible .cat-row__desc { color: #dfe6ef; }

.ill { fill: none; stroke: currentColor; stroke-width: 2.5; stroke-linecap: round; stroke-linejoin: round; }
.ill .ill-accent { fill: var(--sun); stroke: none; }
.ill .ill-accent-stroke { stroke: var(--sun); }
.cat-row__ill { width: 132px; height: 99px; color: var(--navy); transition: color 0.35s, transform 0.5s var(--ease-out); }
.cat-row:hover .cat-row__ill, .cat-row:focus-visible .cat-row__ill { color: var(--paper); transform: rotate(-4deg) scale(1.06); }

@media (max-width: 860px) {
  .cat-row { grid-template-columns: 2.25rem minmax(0, 1fr) 76px; grid-template-areas: "n name ill" "n desc ill"; row-gap: 0.4rem; min-height: 0; padding: 1.25rem 0.5rem; }
  .cat-row::before { grid-area: n; align-self: start; padding-top: 0.35rem; }
  .cat-row__name { grid-area: name; }
  .cat-row__desc { grid-area: desc; font-size: 0.95rem; }
  .cat-row__ill { grid-area: ill; width: 76px; height: 57px; }
}

/* ---------- Lifecycle ---------- */
.lifecycle { background: var(--ink); color: var(--paper); }
.lifecycle__pin { padding: clamp(4.5rem, 10vw, 7rem) 0 clamp(3rem, 6vw, 5rem); min-height: 100svh; display: flex; flex-direction: column; }
.lifecycle .section-head { margin-bottom: clamp(1rem, 3vw, 2.5rem); width: 100%; }
.lifecycle__stage { position: relative; max-width: 980px; width: 100%; margin: 0 auto; padding: 0 var(--gutter); }
.arc { width: 100%; height: auto; overflow: visible; }
.arc__horizon { stroke: rgb(245 241 232 / 0.25); stroke-width: 1.5; }
.arc__track { fill: none; stroke: rgb(245 241 232 / 0.22); stroke-width: 2; stroke-dasharray: 2 8; }
.arc__done { fill: none; stroke: var(--sun); stroke-width: 3; stroke-dasharray: 1; stroke-dashoffset: var(--arc-off, 0); }
[data-arc-dots] circle { fill: var(--ink); stroke: rgb(245 241 232 / 0.5); stroke-width: 2.5; transition: fill 0.3s, stroke 0.3s; }
[data-arc-dots] circle.is-passed { fill: var(--sun); stroke: var(--sun); }
/* The sun is the one glowing element on the page. */
.arc__sun { fill: var(--sun); filter: drop-shadow(0 0 18px rgb(244 163 64 / 0.7)); }

.lifecycle__list { list-style: none; margin: 2rem 0 0; padding: 0; display: grid; gap: 1.75rem; }
.lifecycle__list li { display: grid; grid-template-columns: 2.5rem minmax(0, 1fr); column-gap: 0.75rem; }
.lifecycle__n { grid-row: span 2; font-family: var(--font-display); font-weight: 800; font-size: 1.25rem; color: var(--sun); }
.lifecycle__list h3 { font-size: clamp(1.35rem, 1.1rem + 1vw, 1.9rem); margin-bottom: 0.35rem; }
.lifecycle__list p { color: #dfe6ef; margin: 0; max-width: 46ch; }

/* Pinned mode (set by lifecycle.js on wide screens): one step at a time, inside the arc. */
.lifecycle.is-pinned .lifecycle__list { position: absolute; left: 50%; bottom: 9%; width: min(30rem, 56%); transform: translateX(-50%); margin: 0; display: block; text-align: center; }
.lifecycle.is-pinned .lifecycle__list li { position: absolute; left: 0; right: 0; bottom: 0; display: block; opacity: 0; transform: translateY(16px); transition: opacity 0.4s, transform 0.5s var(--ease-out); }
.lifecycle.is-pinned .lifecycle__list li.is-active { opacity: 1; transform: none; }
.lifecycle.is-pinned .lifecycle__n { display: block; margin-bottom: 0.5rem; }
.lifecycle.is-pinned .lifecycle__list p { margin: 0 auto; }

/* ---------- News cards (home carousel, news page, related) ---------- */
.notes { padding: clamp(4.5rem, 10vw, 8rem) 0; }
.notes > .link-arrow { margin-left: max(var(--gutter), calc((100% - var(--max)) / 2 + var(--gutter))); margin-top: 1.5rem; }

.post-card {
  display: flex; flex-direction: column; height: 100%; overflow: hidden;
  background: #fffdf8; border: 1px solid rgb(14 27 46 / 0.12); border-radius: var(--radius-m);
  text-decoration: none; color: var(--ink);
  transition: transform 0.45s var(--ease-out), box-shadow 0.45s var(--ease-out), border-color 0.3s;
}
/* The lift and shadow mark the one card under the pointer or keyboard; cards at rest sit flat. */
.post-card:hover, .post-card:focus-visible { transform: translateY(-6px); box-shadow: 0 18px 40px -18px rgb(14 27 46 / 0.45); border-color: rgb(14 27 46 / 0.25); }
.post-card:focus-visible { outline-color: var(--navy); }
.post-card__media { display: block; aspect-ratio: 16 / 9; overflow: hidden; background: var(--mist); }
.post-card__media img { width: 100%; height: 100%; object-fit: cover; transition: transform 0.8s var(--ease-out); }
.post-card:hover .post-card__media img, .post-card:focus-visible .post-card__media img { transform: scale(1.06); }
.post-card__body { display: flex; flex-direction: column; gap: 0.5rem; padding: 1.25rem 1.35rem 1.5rem; flex: 1; }
.post-card__date { font-size: 0.875rem; color: var(--muted); }
.post-card__title { font-family: var(--font-display); font-weight: 700; font-size: clamp(1.15rem, 1rem + 0.5vw, 1.35rem); line-height: 1.2; letter-spacing: -0.01em; margin: 0; }
.post-card__excerpt { color: var(--muted); font-size: 0.98rem; line-height: 1.55; }

.reel { max-width: var(--max); margin: 0 auto; padding: 0 var(--gutter); }
.reel__viewport { position: relative; overflow-x: auto; overscroll-behavior-x: contain; scroll-snap-type: x mandatory; scrollbar-width: none; margin: -12px -12px 0; padding: 12px 12px 0; scroll-padding-left: 12px; }
.reel__viewport::-webkit-scrollbar { display: none; }
.reel__track { display: grid; grid-auto-flow: column; grid-auto-columns: calc((100% - 3rem) / 3); gap: 1.5rem; list-style: none; margin: 0; padding: 0 0 1.5rem; }
.reel__item { scroll-snap-align: start; min-width: 0; }
@media (max-width: 1024px) { .reel__track { grid-auto-columns: calc((100% - 1.25rem) / 2); gap: 1.25rem; } }
@media (max-width: 640px) { .reel__track { grid-auto-columns: 86%; gap: 1rem; } }

.reel__controls { display: flex; align-items: center; gap: 0.6rem; margin-top: 0.5rem; }
.reel__controls[hidden] { display: none; }
.reel__btn {
  display: inline-grid; place-items: center; min-width: 46px; height: 46px; padding: 0 0.9rem;
  border: 1.5px solid var(--ink); border-radius: 23px; background: none; color: var(--ink); cursor: pointer;
  font-family: var(--font-display); font-weight: 700; font-size: 0.9rem;
  transition: background-color 0.25s, color 0.25s, transform 0.15s var(--ease-out);
}
.reel__btn[hidden] { display: none; }
.reel__btn svg { width: 20px; height: 20px; fill: none; stroke: currentColor; stroke-width: 2.2; stroke-linecap: round; stroke-linejoin: round; }
.reel__btn:hover { background: var(--ink); color: var(--paper); }
.reel__btn:active { transform: scale(0.94); }
.reel__btn:focus-visible { outline-color: var(--navy); }
.reel__count { margin-left: 0.5rem; font-family: var(--font-display); font-weight: 700; font-variant-numeric: tabular-nums; color: var(--navy); }
/* Shows the time left before the next card while autoplay runs. */
.reel__timer { position: relative; flex: 1; max-width: 220px; height: 3px; margin-left: auto; background: rgb(14 27 46 / 0.14); border-radius: 2px; overflow: hidden; }
.reel__timer i { position: absolute; inset: 0; background: var(--navy); transform: scaleX(0); transform-origin: 0 50%; }
.reel.is-running .reel__timer i { animation: reel-timer 5s linear forwards; }
@keyframes reel-timer { to { transform: scaleX(1); } }
@media (max-width: 480px) { .reel__timer { display: none; } }

/* ---------- Footer ---------- */
.site-footer { background: var(--ink); color: var(--paper); padding: clamp(4rem, 9vw, 7rem) var(--gutter) 2rem; border-top: 1px solid rgb(245 241 232 / 0.12); }
.site-footer > * { max-width: var(--max); margin-left: auto; margin-right: auto; }
.site-footer__lead { font-size: 1.15rem; color: var(--on-dark-muted); margin-bottom: 0.5rem; }
.site-footer__phone {
  display: inline-block; font-family: var(--font-display); font-weight: 800; letter-spacing: -0.035em; line-height: 1;
  font-size: clamp(1.75rem, 0.6rem + 8vw, 7rem); text-decoration: none; white-space: nowrap;
  background: linear-gradient(var(--sun), var(--sun)) 0 100% / 0% 6px no-repeat; transition: background-size 0.5s var(--ease-out), color 0.3s;
  padding-bottom: 0.1em;
}
.site-footer__phone:hover { background-size: 100% 6px; }
.site-footer__alt { margin-top: 1rem; color: var(--on-dark-muted); }
.site-footer__alt a { color: var(--paper); text-underline-offset: 3px; display: inline-block; padding: 0.6rem 0; }
.site-footer__grid { display: grid; grid-template-columns: minmax(0, 1.6fr) minmax(0, 1fr) minmax(0, 0.8fr); gap: 2.5rem; margin-top: clamp(3rem, 7vw, 5rem); padding-top: 2.5rem; border-top: 1px solid rgb(245 241 232 / 0.15); }
.site-footer__brand img { width: 220px; height: auto; margin-bottom: 1.25rem; }
.site-footer__brand p { color: var(--on-dark-muted); max-width: 40ch; }
.site-footer__label { display: block; font-family: var(--font-display); font-weight: 700; color: var(--sun); margin-bottom: 0.6rem; font-size: 0.95rem; }
.site-footer address { font-style: normal; }
.site-footer address a { text-decoration: none; display: inline-block; line-height: 1.5; padding: 0.2rem 0; }
.site-footer address a:hover { text-decoration: underline; }
.site-footer__links ul { list-style: none; margin: 0; padding: 0; }
.site-footer__links a { display: inline-flex; align-items: center; min-height: 40px; text-decoration: none; }
.site-footer__links a:hover { text-decoration: underline; text-underline-offset: 4px; }
.site-footer__legal { margin-top: 3rem; font-size: 0.875rem; color: var(--on-dark-muted); }
@media (max-width: 760px) { .site-footer__grid { grid-template-columns: 1fr 1fr; } .site-footer__brand { grid-column: 1 / -1; } }

/* ---------- Inner pages ---------- */
.page-hero { background: var(--ink); color: var(--paper); padding: calc(var(--header-h) + clamp(3rem, 9vw, 7rem)) 0 clamp(3rem, 7vw, 5.5rem); overflow: hidden; }
.page-hero__inner { position: relative; max-width: var(--max); margin: 0 auto; padding: 0 var(--gutter); }
.page-hero h1 { font-size: clamp(2.6rem, 1.4rem + 5vw, 6rem); font-weight: 800; letter-spacing: -0.035em; max-width: 14ch; }
.page-hero__lede { max-width: 54ch; margin-top: 1.5rem; font-size: clamp(1.05rem, 1rem + 0.4vw, 1.3rem); color: #dfe6ef; }
.page-hero__meta { color: var(--on-dark-muted); margin-bottom: 1rem; }
.page-hero__arc { position: absolute; right: var(--gutter); bottom: -5.5rem; width: min(36vw, 420px); height: auto; pointer-events: none; }
.page-hero__arc path { fill: none; stroke: var(--sun); stroke-width: 2.5; }
.page-hero__arc path + path { stroke: rgb(245 241 232 / 0.25); stroke-width: 1.5; }
.page-hero__arc circle { fill: var(--sun); }
/* About sunrise: the horizon sits inside the band and runs full width, so the sun visibly clears it. */
.page-hero__arc--sunrise { bottom: 1.5rem; width: min(40vw, 480px); overflow: visible; }
.page-hero__arc--sunrise .sunrise__glow { opacity: 0.55; }
@media (max-width: 1024px) {
  /* Narrower screens: the sunrise sits below the text instead of behind it. */
  .page-hero__arc.page-hero__arc--sunrise { position: relative; right: auto; bottom: auto; display: block; width: min(100%, 420px); margin: 2.5rem 0 -1.5rem auto; opacity: 1; }
}
.page-hero h1, .page-hero__lede, .page-hero__meta { position: relative; z-index: 1; }
@media (max-width: 1024px) { .page-hero__arc { opacity: 0.35; } }
@media (max-width: 720px) { .page-hero__arc { width: 70vw; right: -10vw; } }

.split { max-width: var(--max); margin: 0 auto; padding: clamp(4rem, 9vw, 7rem) var(--gutter); display: grid; grid-template-columns: minmax(0, 0.9fr) minmax(0, 1.3fr); gap: clamp(2rem, 6vw, 6rem); }
.split h2 { font-size: clamp(1.9rem, 1.3rem + 2.2vw, 3rem); }
.split__body { font-size: 1.1rem; }
.split__body p { max-width: 60ch; }
.split--rev { grid-template-columns: minmax(0, 1.3fr) minmax(0, 0.9fr); }
@media (max-width: 860px) { .split, .split--rev { grid-template-columns: 1fr; } }

.band { background: var(--ink); color: var(--paper); }
.band--mist { background: var(--mist); }

.sources { max-width: var(--max); margin: 0 auto; padding: clamp(4rem, 9vw, 7rem) var(--gutter); }
.sources h2 { max-width: 20ch; }
.sources__lede { color: #dfe6ef; max-width: 60ch; margin-top: 1rem; font-size: 1.1rem; }
.split--tight { padding-bottom: 2rem; }
.sources__grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 0; margin-top: 3rem; border-top: 1.5px solid rgb(245 241 232 / 0.25); }
.sources__grid--two { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.source { padding: 2rem clamp(1rem, 2.5vw, 2rem) 0 0; }
.source + .source { border-left: 1.5px solid rgb(245 241 232 / 0.25); padding-left: clamp(1rem, 2.5vw, 2rem); }
.source h3 { font-size: clamp(1.6rem, 1.2rem + 1.4vw, 2.4rem); font-weight: 800; color: var(--sun); margin-bottom: 1rem; }
.source p { color: #dfe6ef; }
.source a { color: var(--paper); }
@media (max-width: 860px) {
  .sources__grid { grid-template-columns: 1fr; }
  .source + .source { border-left: 0; border-top: 1.5px solid rgb(245 241 232 / 0.25); padding-left: 0; }
  .source { padding-bottom: 2rem; }
}


.service-list { list-style: none; margin: 0 auto; padding: 0 var(--gutter) clamp(4rem, 9vw, 7rem); max-width: var(--max); display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); column-gap: clamp(2rem, 5vw, 5rem); }
.service-list li { display: grid; grid-template-columns: 2.5rem minmax(0, 1fr); padding: 1.5rem 0; border-top: 1.5px solid rgb(14 27 46 / 0.25); }
.service-list span { font-family: var(--font-display); font-weight: 800; color: var(--navy); }
.service-list h3 { margin-bottom: 0.4rem; }
.service-list p { margin: 0; color: var(--muted); grid-column: 2; }
@media (max-width: 760px) { .service-list { grid-template-columns: 1fr; } }

/* Products page */
.products { max-width: var(--max); margin: 0 auto; padding: clamp(3rem, 7vw, 6rem) var(--gutter); }
.notice { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 1rem 2rem; align-items: center; background: var(--mist); border-radius: var(--radius-m); padding: 1.5rem clamp(1.25rem, 3vw, 2rem); margin-bottom: clamp(3rem, 7vw, 5rem); }
.notice p { margin: 0; font-size: 1.05rem; max-width: 62ch; }
@media (max-width: 720px) { .notice { grid-template-columns: 1fr; } }
.product { display: grid; grid-template-columns: minmax(0, 0.8fr) minmax(0, 1.2fr); gap: clamp(1.5rem, 5vw, 5rem); align-items: center; padding: clamp(2.5rem, 6vw, 4.5rem) 0; border-top: 1.5px solid rgb(14 27 46 / 0.2); scroll-margin-top: calc(var(--header-h) + 1rem); }
.product:nth-child(even) { grid-template-columns: minmax(0, 1.2fr) minmax(0, 0.8fr); }
.product:nth-child(even) .product__art { order: 2; }
.product__art { background: var(--mist); border-radius: var(--radius-m); aspect-ratio: 4 / 3; display: grid; place-items: center; color: var(--navy); }
.product__art .ill { width: 62%; height: auto; aspect-ratio: 4 / 3; }
.product h2 { font-size: clamp(2rem, 1.4rem + 2.4vw, 3.4rem); margin-bottom: 1rem; }
.product__body p { max-width: 56ch; font-size: 1.08rem; }
.product__ask { margin: 1.25rem 0 1.75rem; padding: 0; list-style: none; }
.product__ask li { padding: 0.5rem 0 0.5rem 1.6rem; position: relative; color: var(--muted); }
.product__ask li::before { content: ""; position: absolute; left: 0; top: 1.05rem; width: 0.8rem; height: 2px; background: var(--navy); }
@media (max-width: 760px) {
  .product, .product:nth-child(even) { grid-template-columns: 1fr; }
  .product:nth-child(even) .product__art { order: 0; }
  .product__art { aspect-ratio: 16 / 9; }
  .product__art .ill { width: 40%; }
}

/* News */
.news-list { max-width: var(--max); margin: 0 auto; padding: clamp(3rem, 7vw, 6rem) var(--gutter); }
.news-grid { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 2rem 1.75rem; }
.news-grid__lead { grid-column: span 2; grid-row: span 2; }
.news-grid__lead .post-card__title { font-size: clamp(1.6rem, 1.2rem + 1.4vw, 2.4rem); font-weight: 800; letter-spacing: -0.02em; }
.news-grid__lead .post-card__excerpt { font-size: 1.08rem; }
.news-grid__lead .post-card__media { aspect-ratio: 16 / 9; flex: 1 1 auto; }
@media (max-width: 1024px) { .news-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } .news-grid__lead { grid-row: auto; } }
@media (max-width: 640px) { .news-grid { grid-template-columns: 1fr; } .news-grid__lead { grid-column: auto; } }

.related { max-width: var(--max); margin: 0 auto; padding: 0 var(--gutter) clamp(4rem, 8vw, 6rem); }
.related h2 { font-size: clamp(1.8rem, 1.3rem + 1.8vw, 2.6rem); margin-bottom: 1.5rem; padding-top: 2.5rem; border-top: 1.5px solid rgb(14 27 46 / 0.2); }
.related__list { list-style: none; margin: 0 0 1.5rem; padding: 0; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 1.75rem; }
@media (max-width: 720px) { .related__list { grid-template-columns: 1fr; } }

/* Article pages: photo hero. The scrim keeps the title and breadcrumb readable over any part of the image. */
.article-hero { position: relative; isolation: isolate; display: flex; align-items: flex-end; min-height: min(80svh, 780px); padding-top: calc(var(--header-h) + 3rem); }
.article-hero__img { position: absolute; left: 0; top: -6%; width: 100%; height: 112%; object-fit: cover; z-index: -2; }
.article-hero::after {
  content: ""; position: absolute; inset: 0; z-index: -1;
  background: linear-gradient(0deg, rgb(11 22 38 / 0.94) 0%, rgb(11 22 38 / 0.82) 32%, rgb(11 22 38 / 0.35) 65%, rgb(11 22 38 / 0.55) 100%);
}
.article-hero .page-hero__inner { width: 100%; }
.article-hero h1 { max-width: 20ch; font-size: clamp(2.3rem, 1.3rem + 4vw, 5rem); }
.article-hero .breadcrumb ol, .article-hero .breadcrumb [aria-current], .article-hero .page-hero__meta { color: #dfe6ef; }
.article-hero .breadcrumb li:not(:last-child)::after { color: #dfe6ef; }

.reading-bar { position: fixed; left: 0; top: 0; z-index: 60; height: 3px; width: 100%; background: var(--sun); transform-origin: 0 50%; transform: scaleX(var(--read, 0)); pointer-events: none; }
.prose-wrap { max-width: var(--max); margin: 0 auto; padding: clamp(3rem, 7vw, 5rem) var(--gutter) clamp(4rem, 8vw, 6rem); display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 68ch) minmax(0, 1fr); }
.prose { grid-column: 2; font-size: 1.125rem; line-height: 1.7; }
.prose h2 { font-size: clamp(1.5rem, 1.2rem + 1vw, 2rem); margin: 2.5rem 0 0.75rem; }
.prose ul { padding-left: 1.2rem; }
.prose li { margin-bottom: 0.6rem; }
.prose dl { margin: 1.5rem 0; }
.prose dt { font-family: var(--font-display); font-weight: 800; margin-top: 1rem; }
.prose dd { margin: 0.25rem 0 0; }
.prose__source { font-size: 0.95rem; color: var(--muted); border-top: 1px solid rgb(14 27 46 / 0.2); padding-top: 1rem; margin-top: 2.5rem; }
.prose__cta { margin-top: 3rem; padding: 2rem; background: var(--mist); border-radius: var(--radius-m); }
.prose__cta h2 { margin-top: 0; }
@media (max-width: 860px) { .prose-wrap { grid-template-columns: 1fr; } .prose { grid-column: 1; } }

/* Contact */
.contact { max-width: var(--max); margin: 0 auto; padding: clamp(3rem, 7vw, 6rem) var(--gutter); display: grid; grid-template-columns: minmax(0, 1.25fr) minmax(0, 0.75fr); gap: clamp(2.5rem, 6vw, 6rem); align-items: start; }
.form { display: grid; gap: 1.25rem; }
.form__row { display: grid; grid-template-columns: 1fr 1fr; gap: 1.25rem; }
.field { display: grid; gap: 0.4rem; }
.field label { font-weight: 600; }
.field label small { font-weight: 400; color: var(--muted); }
.field input, .field select, .field textarea {
  width: 100%; min-height: 50px; padding: 0.7rem 0.9rem; background: #fffdf8;
  border: 1.5px solid #6b7486; border-radius: var(--radius-s); transition: border-color 0.2s, box-shadow 0.2s;
}
.field textarea { min-height: 160px; resize: vertical; }
.field input:hover, .field select:hover, .field textarea:hover { border-color: var(--navy); }
.field input:focus-visible, .field select:focus-visible, .field textarea:focus-visible { outline: none; border-color: var(--navy); box-shadow: 0 0 0 3px var(--navy); }
.field[data-invalid="true"] input, .field[data-invalid="true"] textarea, .field[data-invalid="true"] select { border-color: #b3261e; }
.field__error { color: #b3261e; font-size: 0.92rem; font-weight: 500; min-height: 0; }
.field__error:empty { display: none; }
.form__status { padding: 1rem 1.25rem; border-radius: var(--radius-s); font-weight: 500; }
.form__status[hidden] { display: none; }
.form__status--ok { background: var(--mist); border: 1.5px solid var(--navy); }
.form__status--err { background: #fbe9e7; border: 1.5px solid #b3261e; }
.form__note { font-size: 0.92rem; color: var(--muted); margin: 0; }
.contact__details { display: grid; gap: 0; }
.contact__item { padding: 1.25rem 0; border-top: 1.5px solid rgb(14 27 46 / 0.2); }
.contact__item:last-child { border-bottom: 1.5px solid rgb(14 27 46 / 0.2); }
.contact__item span { display: block; font-size: 0.9rem; color: var(--muted); }
.contact__item a { font-family: var(--font-display); font-weight: 700; font-size: clamp(1.25rem, 1rem + 0.8vw, 1.6rem); text-decoration: none; display: inline-block; padding: 0.2rem 0; }
.contact__item a:hover { text-decoration: underline; text-underline-offset: 4px; }
@media (max-width: 860px) { .contact { grid-template-columns: 1fr; } }
@media (max-width: 560px) { .form__row { grid-template-columns: 1fr; } }

/* Breadcrumb (inner pages) */
.breadcrumb { position: relative; z-index: 1; margin-bottom: 1.25rem; font-size: 0.95rem; }
.breadcrumb ol { display: flex; flex-wrap: wrap; align-items: center; list-style: none; margin: 0; padding: 0; color: var(--on-dark-muted); }
.breadcrumb li:not(:last-child)::after { content: "/"; margin: 0 0.6rem; color: var(--on-dark-muted); }
.breadcrumb a { display: inline-flex; align-items: center; min-height: 44px; color: var(--paper); text-underline-offset: 3px; }
.breadcrumb [aria-current] { color: var(--on-dark-muted); }

.contact__hint { margin: 0 0 1.25rem; color: var(--muted); }
.prose a, .product__body p a, .split__body a, .contact__hint a { color: var(--navy); text-underline-offset: 3px; font-weight: 500; }
.prose .btn { color: var(--paper); font-weight: 700; }

/* 404: the sun sets as you scroll, then the house lights come back on. */
.lost { position: relative; background: var(--ink); color: var(--paper); min-height: 100svh; }
.js .lost:not(.is-static) { height: 240svh; }
/* Copy on top, scene in the space left below it, so the two can never overlap at any size. */
.lost__stage { position: sticky; top: 0; height: 100svh; min-height: 560px; overflow: hidden; display: flex; flex-direction: column; }
.lost__stage::before {
  content: ""; position: absolute; inset: 0;
  background: linear-gradient(180deg, #1a3a68 0%, #3b3f63 45%, #c9744a 80%, #f4a340 100%);
  opacity: calc(1 - var(--dusk, 0)); transition: opacity 0.2s linear;
}
.lost__scene { position: relative; order: 2; flex: 1 1 auto; min-height: 140px; width: 100%; height: auto; overflow: visible; margin-top: 1rem; }
.lost__sun { fill: var(--sun); }
.lost__horizon { stroke: rgb(245 241 232 / 0.4); stroke-width: 2; }
.lost__house > path { fill: #08111e; stroke: rgb(245 241 232 / 0.35); stroke-width: 2; }
.lost__win { fill: #16253c; transition: fill 0.35s; }
.lost__win.is-on { fill: var(--sun); }
.lost__copy { position: relative; order: 1; flex: none; width: 100%; max-width: var(--max); margin: 0 auto; padding: calc(var(--header-h) + clamp(2rem, 8vh, 5rem)) var(--gutter) 0; }
.lost__code { font-family: var(--font-display); font-weight: 800; font-size: 1.1rem; color: var(--sun); margin-bottom: 0.75rem; }
.lost h1 { font-size: clamp(2.6rem, 1.4rem + 5vw, 6rem); font-weight: 800; letter-spacing: -0.035em; max-width: 12ch; }
.lost__lede { max-width: 44ch; margin-top: 1.25rem; font-size: clamp(1.05rem, 1rem + 0.4vw, 1.3rem); color: #dfe6ef; }
.lost__status { margin-top: 1rem; font-family: var(--font-display); font-weight: 700; color: var(--sun); opacity: 0; transform: translateY(8px); transition: opacity 0.4s, transform 0.4s var(--ease-out); }
.lost__status.is-on { opacity: 1; transform: none; }
@media (max-width: 720px) { .lost__scene { opacity: 0.85; } }

.ways { max-width: var(--max); margin: 0 auto; padding: clamp(4rem, 9vw, 6rem) var(--gutter); }
.ways h2 { margin-bottom: 2rem; }
.ways__list { list-style: none; margin: 0; padding: 0; }
.ways__list li { border-top: 1.5px solid rgb(14 27 46 / 0.25); }
.ways__list li:last-child { border-bottom: 1.5px solid rgb(14 27 46 / 0.25); }
.ways__list a { display: grid; grid-template-columns: minmax(0, 14rem) minmax(0, 1fr); align-items: baseline; gap: 0.5rem 2rem; padding: 1.25rem 0.5rem; text-decoration: none; transition: background-color 0.25s; }
.ways__list a:hover { background: var(--mist); }
.ways__list a > span { transition: transform 0.3s var(--ease-out); }
.ways__list a:hover > span { transform: translateX(0.5rem); }
.ways__name { font-family: var(--font-display); font-weight: 800; font-size: clamp(1.5rem, 1.2rem + 1.2vw, 2.2rem); letter-spacing: -0.02em; }
.ways__desc { color: var(--muted); }
.ways :focus-visible { outline-color: var(--navy); }
@media (max-width: 640px) { .ways__list a { grid-template-columns: 1fr; } }

/* ---------- Home: solution themes ---------- */
.themes { padding: clamp(4.5rem, 10vw, 8rem) 0; }
.themes__row { list-style: none; max-width: var(--max); margin: 0 auto; padding: 0 var(--gutter); display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 1rem; }
.theme { position: relative; isolation: isolate; overflow: hidden; display: flex; align-items: flex-end; min-height: 480px; border-radius: var(--radius-m); background: var(--ink); color: var(--paper); }
.theme__img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; z-index: -2; transition: transform 0.9s var(--ease-out); }
/* Scrim: the lower half carries the text, so it is dark enough for 4.5:1 over any photo. */
.theme::after { content: ""; position: absolute; inset: 0; z-index: -1; background: linear-gradient(0deg, rgb(11 22 38 / 0.95) 0%, rgb(11 22 38 / 0.85) 38%, rgb(11 22 38 / 0.2) 72%, rgb(11 22 38 / 0.1) 100%); }
.theme__body { width: 100%; padding: 1.5rem 1.4rem 1.25rem; }
.theme__n { display: block; margin-bottom: 0.5rem; font-family: var(--font-display); font-weight: 700; font-size: 0.9rem; color: var(--sun); }
.theme__title { font-size: clamp(1.3rem, 1rem + 0.8vw, 1.6rem); font-weight: 800; line-height: 1.15; margin-bottom: 0.35rem; }
.theme__meta { margin: 0 0 0.5rem; font-size: 0.9rem; color: var(--on-dark-muted); }
.theme__reveal { display: grid; grid-template-rows: 1fr; }
.theme__links { list-style: none; margin: 0; padding: 0; min-height: 0; overflow: hidden; }
.theme__links a { display: flex; align-items: center; justify-content: space-between; gap: 0.5rem; min-height: 44px; border-top: 1px solid rgb(245 241 232 / 0.2); color: #dfe6ef; text-decoration: none; font-weight: 500; transition: color 0.2s; }
/* The arrow appears on the link under the pointer only: it marks which line will open. */
.theme__links a::after { content: "→"; opacity: 0; transform: translateX(-6px); transition: opacity 0.2s, transform 0.25s var(--ease-out); }
.theme__links a:hover, .theme__links a:focus-visible { color: var(--paper); }
.theme__links a:hover::after, .theme__links a:focus-visible::after { opacity: 1; transform: none; }
.theme :focus-visible { outline-color: var(--sun); outline-offset: 2px; }
.themes__foot { max-width: var(--max); margin: 2rem auto 0; padding: 0 var(--gutter); }

/* Wide screens with a pointer: the list rises in on hover or keyboard focus; touch screens always show it. */
@media (hover: hover) and (min-width: 1025px) {
  .theme__reveal { grid-template-rows: 0fr; transition: grid-template-rows 0.45s var(--ease-out); }
  .theme__links { opacity: 0; transition: opacity 0.3s; }
  .theme:hover .theme__reveal, .theme:focus-within .theme__reveal { grid-template-rows: 1fr; }
  .theme:hover .theme__links, .theme:focus-within .theme__links { opacity: 1; }
  .theme:hover .theme__img, .theme:focus-within .theme__img { transform: scale(1.06); }
}
@media (max-width: 1024px) { .themes__row { grid-template-columns: repeat(2, minmax(0, 1fr)); } .theme { min-height: 420px; } }
@media (max-width: 640px) { .themes__row { grid-template-columns: 1fr; } .theme { min-height: 380px; } }

/* ---------- Solutions page ---------- */
.estate { background: var(--ink); color: var(--paper); padding: clamp(4rem, 9vw, 7rem) 0; }
.estate .section-head { margin-bottom: 2rem; }
.estate__stage { max-width: var(--max); margin: 0 auto; padding: 0 var(--gutter); }
.estate__map { width: 100%; height: auto; overflow: visible; display: block; }
.em-scenery .em-hill { fill: #13243c; stroke: none; }
.em-scenery .em-ground { stroke: rgb(245 241 232 / 0.35); stroke-width: 2; fill: none; }
.em-sun { fill: var(--sun); }
.em-house > *, .em-workshop > * { fill: none; stroke: #6f87ab; stroke-width: 2.5; stroke-linejoin: round; stroke-linecap: round; }
.em-item > * { fill: none; stroke: #b9c6d8; stroke-width: 2.5; stroke-linejoin: round; stroke-linecap: round; transition: stroke 0.25s, opacity 0.25s; }
/* With one spot picked, everything else steps back so the chosen equipment reads at a glance. */
.estate__map.has-active .em-item:not(.is-active) > * { opacity: 0.35; }
.em-item.is-active > * { stroke: var(--sun); stroke-width: 3.5; }
.em-pin { cursor: pointer; }
.em-pin__hit { fill: transparent; }
.em-pin__dot { fill: var(--ink); stroke: var(--sun); stroke-width: 3; transition: fill 0.2s, stroke 0.2s; }
.em-pin text { fill: var(--paper); font: 700 17px var(--font-display); text-anchor: middle; pointer-events: none; transition: fill 0.2s; }
.em-pin:hover .em-pin__dot, .em-pin.is-active .em-pin__dot { fill: var(--sun); }
.em-pin:hover text, .em-pin.is-active text { fill: var(--ink); }
.em-pin:focus { outline: none; }
.em-pin:focus-visible .em-pin__dot { stroke: var(--paper); stroke-width: 5; }

.estate__panel { display: grid; grid-template-columns: minmax(0, 14rem) minmax(0, 1fr) auto; align-items: center; gap: 0.5rem 2rem; margin-top: 1.5rem; padding: 1.25rem 1.5rem; border: 1.5px solid rgb(245 241 232 / 0.2); border-radius: var(--radius-m); min-height: 96px; }
.estate__group { margin: 0; font-size: 0.9rem; color: var(--sun); font-weight: 600; }
.estate__name { margin: 0; font-family: var(--font-display); font-weight: 800; font-size: clamp(1.3rem, 1rem + 1vw, 1.8rem); line-height: 1.15; }
.estate__summary { margin: 0; grid-column: 2; color: #dfe6ef; }
.estate__link { grid-column: 3; grid-row: 1 / span 2; color: var(--paper); }
.estate__link[hidden] { display: none; }
.estate :focus-visible { outline-color: var(--sun); }
.estate__hint { display: none; margin: 0 var(--gutter) 0.5rem; font-size: 0.85rem; color: var(--on-dark-muted); }
@media (max-width: 860px) {
  /* Phones: the map keeps a readable size and scrolls sideways, so the numbers stay tappable. */
  .estate__stage { padding: 0; }
  .estate__scroll { overflow-x: auto; overscroll-behavior-x: contain; padding: 0 var(--gutter) 0.5rem; }
  .estate__map { min-width: 900px; }
  .estate__panel { margin: 1rem var(--gutter) 0; grid-template-columns: 1fr; }
  .estate__summary, .estate__link { grid-column: 1; grid-row: auto; }
  .estate__hint { display: block; }
}

.sol-all { padding: clamp(4rem, 9vw, 7rem) 0; }
.sol-all .section-head { margin-bottom: 1.5rem; }
.sol-all__body { max-width: var(--max); margin: 0 auto; padding: 0 var(--gutter); }
.sol-filter { display: flex; flex-wrap: wrap; gap: 0.5rem; margin-bottom: 1rem; }
.sol-filter[hidden] { display: none; }
.sol-filter__chip {
  min-height: 44px; padding: 0 1rem; border: 1.5px solid var(--navy); border-radius: var(--radius-m);
  background: none; color: var(--ink); font-weight: 600; cursor: pointer; transition: background-color 0.2s, color 0.2s, transform 0.15s var(--ease-out);
}
.sol-filter__chip:hover { background: var(--mist); }
.sol-filter__chip[aria-pressed="true"] { background: var(--navy); color: var(--paper); }
.sol-filter__chip:active { transform: scale(0.97); }
.sol-filter__chip:focus-visible { outline-color: var(--navy); }
.sol-count { color: var(--muted); font-size: 0.95rem; margin-bottom: 1.5rem; }
.sol-grid { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 1.75rem; }
.sol-grid__item[hidden] { display: none; }
.sol-card .post-card__date { color: var(--navy); font-weight: 600; }
@media (max-width: 1024px) { .sol-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 640px) { .sol-grid { grid-template-columns: 1fr; } }

.sol-cta { background: var(--navy); color: var(--paper); padding: clamp(3.5rem, 8vw, 6rem) 0; }
.sol-cta__inner { max-width: var(--max); margin: 0 auto; padding: 0 var(--gutter); }
.sol-cta h2 { max-width: 16ch; }
.sol-cta p { max-width: 54ch; margin: 1rem 0 1.75rem; font-size: 1.1rem; color: #dfe6ef; }
.sol-cta__actions { display: flex; flex-wrap: wrap; gap: 0.75rem; }
.sol-cta :focus-visible { outline-color: var(--sun); }

/* ---------- Solution pages ---------- */
.solution-hero .page-hero__lede { color: #dfe6ef; max-width: 46ch; }
.solution { max-width: var(--max); margin: 0 auto; padding: clamp(3rem, 7vw, 5rem) var(--gutter) clamp(3rem, 7vw, 5rem); display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 2fr); gap: clamp(2rem, 5vw, 5rem); align-items: start; }
.solution__aside { position: sticky; top: calc(var(--header-h) + 1.5rem); }
.solution__card { background: var(--ink); color: var(--paper); border-radius: var(--radius-m); padding: 1.75rem; }
.solution__card h2 { font-size: 1.35rem; margin-bottom: 1rem; }
.solution__card .btn { width: 100%; margin-top: 1.5rem; }
.solution__card :focus-visible { outline-color: var(--sun); }
.solution__call { margin: 1rem 0 0; color: var(--on-dark-muted); font-size: 0.95rem; }
.solution__call a { color: var(--paper); }
.ticks { list-style: none; margin: 0; padding: 0; display: grid; gap: 0.6rem; }
.ticks li { position: relative; padding-left: 1.75rem; color: #dfe6ef; }
/* A drawn tick: a rotated corner in the accent colour, so each line reads as included. */
.ticks li::before { content: ""; position: absolute; left: 0.2rem; top: 0.35em; width: 0.45rem; height: 0.8rem; border: solid var(--sun); border-width: 0 2.5px 2.5px 0; transform: rotate(45deg); }
.solution__main > :first-child { margin-top: 0; font-size: 1.25rem; line-height: 1.6; }
.solution__main ul { padding-left: 1.2rem; }

.callout { margin: 2.5rem 0; padding: 1.5rem 1.75rem; background: var(--mist); border: 1.5px solid rgb(26 58 104 / 0.35); border-radius: var(--radius-m); }
.callout h2 { margin-top: 0 !important; font-size: 1.25rem !important; }
.callout p:last-child { margin-bottom: 0; }
.callout--warn { background: #fbf0e1; border-color: #a15a0a; }
.callout--warn h2 { color: #8a4b05; }

.related--solutions { padding-top: 0; }
.related__list--three { grid-template-columns: repeat(3, minmax(0, 1fr)); }
@media (max-width: 1024px) { .related__list--three { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 640px) { .related__list--three { grid-template-columns: 1fr; } }
.sol-pager { display: grid; grid-template-columns: 1fr auto 1fr; align-items: center; gap: 1rem; margin-top: 2.5rem; padding-top: 1.5rem; border-top: 1.5px solid rgb(14 27 46 / 0.2); }
.sol-pager__link { display: grid; gap: 0.15rem; min-height: 44px; text-decoration: none; font-family: var(--font-display); font-weight: 700; font-size: 1.1rem; }
.sol-pager__link span { font-family: var(--font-body); font-weight: 500; font-size: 0.85rem; color: var(--muted); }
.sol-pager__link:hover { color: var(--navy); }
.sol-pager__link--next { text-align: right; }
.sol-pager__all { display: inline-flex; align-items: center; min-height: 44px; padding: 0 1rem; border: 1.5px solid var(--ink); border-radius: var(--radius-m); text-decoration: none; font-weight: 600; }
.sol-pager__all:hover { background: var(--ink); color: var(--paper); }
.related--solutions :focus-visible { outline-color: var(--navy); }

@media (max-width: 860px) {
  .solution { grid-template-columns: 1fr; }
  .solution__aside { position: static; order: 2; }
  .sol-pager { grid-template-columns: 1fr 1fr; }
  .sol-pager__all { grid-column: 1 / -1; grid-row: 2; justify-self: start; }
}

/* ---------- Reveal (set up by main.js, so content stays visible without JS) ---------- */
.js [data-reveal] { opacity: 0; transform: translateY(24px); }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: 0.01ms !important; animation-iteration-count: 1 !important; transition-duration: 0.01ms !important; transition-delay: 0s !important; }
  .js [data-reveal] { opacity: 1; transform: none; }
  [data-edge-group][data-flow="fwd"] .fd-flow, [data-edge-group][data-flow="rev"] .fd-flow { stroke-dasharray: none; stroke-width: 3; }
}
