/* ==========================================================================
   Design notes
   Palette : navy for structure, light neutrals for reading, one yellow for action and focus.
   Type    : Heros Cn Bold (condensed grotesque, like labels on switchgear) for display,
             Carlito for text. Both are self-hosted; no third-party fonts.
   Rules   : square-cornered buttons, no gradients, no scroll animation, no emoji, no decorative icons.
   Contrast: every text/background pair below is checked at 4.5:1 or better (see docs/CHECKLIST.md).
   ========================================================================== */

@font-face { font-family: "HerosCn"; src: url("/assets/fonts/heros-cn-bold.woff") format("woff"); font-weight: 700; font-style: normal; font-display: swap; }
@font-face { font-family: "Carlito"; src: url("/assets/fonts/carlito-regular.woff") format("woff"); font-weight: 400; font-style: normal; font-display: swap; }
@font-face { font-family: "Carlito"; src: url("/assets/fonts/carlito-bold.woff") format("woff"); font-weight: 700; font-style: normal; font-display: swap; }

:root {
  --navy: #0B2545;
  --navy-2: #12335C;
  --navy-3: #1B4574;
  --ink: #0E1B2C;
  --slate: #46566B;
  --edge: #6B7C93;
  --line: #C9D1DA;
  --line-soft: #DCE2E9;
  --mist: #EEF1F4;
  --paper: #FFFFFF;
  --signal: #FFC61A;
  --signal-press: #E6B000;
  --err: #B3261E;
  --ok: #146C43;
  --warn-bg: #FFF2C2;
  --on-navy: #FFFFFF;
  --on-navy-mute: #B4C2D4;
  --line-navy: rgba(255, 255, 255, 0.2);

  --font-display: "HerosCn", "Avenir Next Condensed", "Roboto Condensed", "Arial Narrow", "Helvetica Neue", Arial, sans-serif;
  --font-text: "Carlito", Calibri, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;

  --radius: 2px;
  --max: 1240px;
  --gutter: clamp(16px, 4.5vw, 44px);
  --hdr-h: 68px;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; text-size-adjust: 100%; scroll-padding-top: calc(var(--hdr-h) + 16px); }
body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--font-text);
  font-size: 1.1875rem;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
  font-variant-numeric: lining-nums tabular-nums;
}
img, svg { max-width: 100%; display: block; }
h1, h2, h3, h4 { margin: 0; font-family: var(--font-display); font-weight: 700; line-height: 1.02; letter-spacing: -0.005em; color: inherit; }
p { margin: 0 0 1em; }
ul, ol { margin: 0; padding: 0; list-style: none; }
a { color: inherit; text-decoration-thickness: 0.08em; text-underline-offset: 0.16em; }
button, input, select, textarea { font: inherit; color: inherit; }
button { cursor: pointer; }
[hidden] { display: none !important; }
address { font-style: normal; }
table { border-collapse: collapse; width: 100%; }

.wrap { width: 100%; max-width: var(--max); margin-inline: auto; padding-inline: var(--gutter); }
.vh { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.skip { position: absolute; left: 12px; top: -80px; z-index: 200; background: var(--signal); color: var(--ink); padding: 12px 18px; font-weight: 700; }
.skip:focus { top: 12px; }
.noscript { margin: 0; padding: 14px var(--gutter); background: var(--warn-bg); color: var(--ink); }

/* Focus: navy ring on light surfaces, yellow ring on navy surfaces. Never removed. */
:focus-visible { outline: 3px solid var(--navy); outline-offset: 3px; }
.on-navy :focus-visible, .hdr :focus-visible, .ftr :focus-visible, .mbar :focus-visible, .section--navy :focus-visible { outline-color: var(--signal); }
main:focus { outline: none; }

/* ---------- Type scale ---------- */
.h-xl { font-size: clamp(2.6rem, 6vw, 4.6rem); line-height: 0.96; }
.h-l { font-size: clamp(2.1rem, 4.2vw, 3.2rem); line-height: 1; }
.h-m { font-size: clamp(1.55rem, 2.6vw, 2rem); line-height: 1.05; }
.h-s { font-size: 1.35rem; line-height: 1.1; }
.lede { font-size: clamp(1.25rem, 2vw, 1.5rem); line-height: 1.4; max-width: 34ch; }
.measure { max-width: 66ch; }
.muted { color: var(--slate); }
.on-navy .muted, .section--navy .muted { color: var(--on-navy-mute); }
.tnum { font-variant-numeric: tabular-nums lining-nums; }
.todo { background: var(--signal); color: var(--ink); padding: 0 4px; font-weight: 700; font-family: var(--font-text); }
.draft-note { border: 2px solid var(--ink); background: var(--warn-bg); padding: 12px 16px; margin: 0 0 32px; max-width: 66ch; }

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 10px;
  min-height: 52px; padding: 0 26px;
  background: var(--signal); color: var(--ink);
  border: 2px solid var(--signal); border-radius: var(--radius);
  font-weight: 700; font-size: 1.0625rem; line-height: 1; text-decoration: none; text-align: center;
}
.btn:hover { background: var(--signal-press); border-color: var(--signal-press); }
.btn--dark { background: var(--navy); border-color: var(--navy); color: var(--on-navy); }
.btn--dark:hover { background: var(--navy-3); border-color: var(--navy-3); }
.btn--ghost { background: transparent; border-color: currentColor; color: inherit; }
.btn--ghost:hover { background: rgba(127, 140, 160, 0.16); border-color: currentColor; }
.btn--sm { min-height: 42px; padding: 0 16px; font-size: 1rem; }
.btn--block { width: 100%; }
.btn[disabled], .btn[aria-disabled="true"] { opacity: 0.5; cursor: not-allowed; }
.btn .ic { width: 20px; height: 20px; }
.linklike { background: none; border: 0; padding: 0; text-decoration: underline; text-underline-offset: 0.16em; text-align: left; }
.actions { display: flex; flex-wrap: wrap; gap: 12px; }
.ic { width: 1.25em; height: 1.25em; flex: none; }

/* ---------- Header ---------- */
.hdr { position: sticky; top: 0; z-index: 50; background: var(--navy); color: var(--on-navy); border-bottom: 1px solid var(--line-navy); }
.hdr__in { display: flex; align-items: center; gap: 24px; min-height: var(--hdr-h); }
.brand { display: inline-flex; align-items: center; gap: 10px; text-decoration: none; color: var(--on-navy); }
.brand__mark { width: 32px; height: 32px; }
.brand__name { font-family: var(--font-display); font-weight: 700; font-size: 1.7rem; letter-spacing: 0.005em; line-height: 1; }
.nav { display: none; gap: 4px; margin-left: 12px; }
.nav a { text-decoration: none; padding: 8px 12px; border-bottom: 3px solid transparent; font-weight: 700; font-size: 1.05rem; }
.nav a:hover { border-bottom-color: var(--on-navy-mute); }
.nav a[aria-current="page"] { border-bottom-color: var(--signal); }
.hdr__actions { margin-left: auto; display: flex; align-items: center; gap: 4px; }
.hdr__link { position: relative; display: inline-flex; align-items: center; gap: 8px; min-height: 44px; padding: 0 10px; text-decoration: none; font-weight: 700; }
.hdr__link:hover { background: var(--navy-2); }
.hdr__label { display: none; }
.badge { position: absolute; top: 2px; right: 0; min-width: 20px; height: 20px; padding: 0 5px; background: var(--signal); color: var(--ink); font-size: 0.8rem; font-weight: 700; line-height: 20px; text-align: center; border-radius: var(--radius); }
.menu { position: relative; }
.menu > summary { display: flex; align-items: center; justify-content: center; width: 44px; height: 44px; list-style: none; cursor: pointer; }
.menu > summary::-webkit-details-marker { display: none; }
.menu[open] > summary { background: var(--navy-2); }
.menu__panel { position: fixed; left: 0; right: 0; top: var(--hdr-h); background: var(--navy); border-top: 1px solid var(--line-navy); border-bottom: 3px solid var(--signal); padding: 8px var(--gutter) 20px; max-height: calc(100vh - var(--hdr-h)); overflow: auto; }
.menu__panel a { display: block; padding: 14px 0; border-bottom: 1px solid var(--line-navy); text-decoration: none; font-family: var(--font-display); font-size: 1.75rem; }
@media (min-width: 980px) {
  .nav { display: flex; }
  .menu { display: none; }
  .hdr__label { display: inline; }
  .badge { position: static; }
}

/* ---------- Network + status banners ---------- */
.net { position: sticky; top: var(--hdr-h); z-index: 40; background: var(--warn-bg); color: var(--ink); border-bottom: 3px solid var(--signal); }
.net__in { display: flex; flex-wrap: wrap; align-items: center; gap: 10px 16px; padding-block: 10px; }
.net__in p { margin: 0; flex: 1 1 260px; }
.net .ic { width: 22px; height: 22px; }

/* ---------- Sections ---------- */
.section { padding-block: clamp(56px, 9vw, 120px); }
.section--mist { background: var(--mist); }
.section--navy { background: var(--navy); color: var(--on-navy); }
.section--tight { padding-block: clamp(36px, 5vw, 64px); }
.rule { border: 0; border-top: 1px solid var(--line); margin: 0; }
.section--navy .rule { border-top-color: var(--line-navy); }

/* Datasheet layout: the heading sits in a narrow rail, the content to its right. */
.spec { display: grid; gap: 28px; }
.spec__rail h2 { font-size: clamp(2rem, 3.6vw, 2.8rem); line-height: 0.98; }
.spec__rail p { margin: 14px 0 0; max-width: 30ch; color: var(--slate); }
.section--navy .spec__rail p { color: var(--on-navy-mute); }
@media (min-width: 960px) {
  .spec { grid-template-columns: minmax(0, 3fr) minmax(0, 9fr); gap: 56px; }
  .spec__rail { position: sticky; top: calc(var(--hdr-h) + 28px); align-self: start; }
}

/* ---------- Hero ---------- */
.hero { background: var(--navy); color: var(--on-navy); padding-top: clamp(36px, 6vw, 80px); }
.hero__grid { display: grid; gap: 36px; align-items: end; }
.hero__title { font-size: clamp(3.4rem, 14.5vw, 8.1rem); line-height: 0.86; letter-spacing: -0.012em; }
.hero__title a, .hero__title span { display: block; width: fit-content; }
.hero__title a { text-decoration: underline; text-decoration-color: var(--signal); text-decoration-thickness: 0.035em; text-underline-offset: 0.09em; }
.hero__title a:hover { text-decoration-thickness: 0.09em; }
.hero__copy .lede { margin: 28px 0 28px; }
.hero__media .ph, .hero__media .media { width: 100%; }
.hero__notes { display: grid; gap: 0; margin-top: clamp(40px, 6vw, 72px); border-top: 1px solid var(--line-navy); }
.hero__notes li { padding: 20px 0; border-bottom: 1px solid var(--line-navy); color: var(--on-navy-mute); max-width: 44ch; }
.hero__notes strong { display: block; color: var(--on-navy); font-size: 1.2rem; margin-bottom: 2px; }
@media (min-width: 900px) {
  .hero__grid { grid-template-columns: minmax(0, 7.4fr) minmax(0, 4.6fr); gap: 56px; }
  .hero__notes { grid-template-columns: repeat(3, 1fr); gap: 32px; border-bottom: 0; }
  .hero__notes li { border-bottom: 0; padding: 22px 0 28px; }
}

/* Page heads for inner pages */
.pagehead { background: var(--navy); color: var(--on-navy); padding: clamp(28px, 4vw, 48px) 0 clamp(36px, 6vw, 72px); }
.pagehead h1 { font-size: clamp(2.8rem, 8vw, 5.6rem); line-height: 0.92; margin-top: 18px; }
.pagehead .lede { margin: 20px 0 0; color: var(--on-navy); }
.pagehead--light { background: var(--mist); color: var(--ink); }
.pagehead--light .lede { color: var(--ink); }
.crumbs ol { display: flex; flex-wrap: wrap; gap: 4px 10px; font-size: 1rem; color: var(--on-navy-mute); }
.pagehead--light .crumbs ol { color: var(--slate); }
.crumbs li + li::before { content: "/"; margin-right: 10px; opacity: 0.7; }
.crumbs a { text-decoration: none; }
.crumbs a:hover { text-decoration: underline; }
.crumbs [aria-current] { color: var(--on-navy); }
.pagehead--light .crumbs [aria-current] { color: var(--ink); }

/* ---------- Placeholders for photos ---------- */
.ph, .media { position: relative; margin: 0; overflow: hidden; }
.ph { background-color: var(--navy-2); color: var(--on-navy); border: 1px solid var(--line-navy);
  background-image:
    linear-gradient(var(--line-navy) 1px, transparent 1px),
    linear-gradient(90deg, var(--line-navy) 1px, transparent 1px);
  background-size: 32px 32px; }
.ph::before, .ph::after { content: ""; position: absolute; width: 22px; height: 22px; border: 2px solid var(--signal); }
.ph::before { top: 10px; left: 10px; border-right: 0; border-bottom: 0; }
.ph::after { right: 10px; bottom: 10px; border-left: 0; border-top: 0; }
.ph__cap { position: absolute; left: 0; right: 0; bottom: 0; padding: 14px 16px 16px 44px; font-size: 0.95rem; line-height: 1.3; background: var(--navy); border-top: 1px solid var(--line-navy); }
.ph__tag { display: block; font-weight: 700; color: var(--signal); margin-bottom: 2px; }
.media img { width: 100%; height: 100%; object-fit: cover; }
.media figcaption { padding: 8px 0; font-size: 0.95rem; color: var(--slate); }
.r-1-1 { aspect-ratio: 1 / 1; } .r-4-3 { aspect-ratio: 4 / 3; } .r-3-2 { aspect-ratio: 3 / 2; }
.r-16-10 { aspect-ratio: 16 / 10; } .r-4-5 { aspect-ratio: 4 / 5; } .r-21-9 { aspect-ratio: 21 / 9; } .r-16-9 { aspect-ratio: 16 / 9; }
.ph--thumb { width: 72px; height: 72px; aspect-ratio: auto; background-size: 12px 12px; }
.ph--thumb::before, .ph--thumb::after { width: 10px; height: 10px; border-width: 2px; }
.ph--thumb::before { top: 5px; left: 5px; } .ph--thumb::after { right: 5px; bottom: 5px; }

/* ---------- Load sheet ---------- */
.sheet { background: var(--paper); border: 2px solid var(--navy); }
.sheet table { font-size: 1.05rem; }
.sheet caption { text-align: left; padding: 16px 18px; border-bottom: 2px solid var(--navy); font-family: var(--font-display); font-size: 1.5rem; background: var(--paper); }
.sheet th { text-align: left; font-weight: 700; padding: 10px 14px; background: var(--mist); border-bottom: 2px solid var(--navy); font-size: 0.98rem; }
.sheet td { padding: 8px 14px; border-bottom: 1px solid var(--line); vertical-align: middle; }
.sheet td.num, .sheet th.num { text-align: right; }
.sheet tr.is-off td { color: var(--slate); }
.sheet .cell-input { width: 92px; min-height: 42px; padding: 0 10px; text-align: right; background: var(--paper); border: 2px solid var(--edge); border-radius: var(--radius); }
.sheet .cell-input--name { width: 100%; text-align: left; }
.sheet .cell-input:focus-visible { border-color: var(--navy); }
.sheet__hint { display: block; font-size: 0.92rem; color: var(--slate); }
.sheet__totals { display: grid; gap: 0; border-top: 2px solid var(--navy); background: var(--navy); color: var(--on-navy); }
.sheet__total { padding: 18px 18px 20px; border-bottom: 1px solid var(--line-navy); }
.sheet__total b { display: block; font-family: var(--font-display); font-size: clamp(2.4rem, 5vw, 3.4rem); line-height: 1; margin-top: 4px; }
.sheet__total span { color: var(--on-navy-mute); }
.sheet__foot { padding: 18px; display: grid; gap: 14px; background: var(--navy); color: var(--on-navy); border-top: 1px solid var(--line-navy); }
.sheet__foot p { margin: 0; color: var(--on-navy-mute); max-width: 60ch; }
.sheet__foot .actions { align-items: center; }
@media (min-width: 720px) { .sheet__totals { grid-template-columns: 1fr 1fr; } .sheet__total + .sheet__total { border-left: 1px solid var(--line-navy); } .sheet__total { border-bottom: 0; } }
@media (max-width: 719px) {
  .sheet table, .sheet tbody, .sheet tr, .sheet td { display: block; width: 100%; }
  .sheet thead { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }
  .sheet tr { padding: 12px 14px; border-bottom: 1px solid var(--line); display: grid; grid-template-columns: 1fr 1fr 1fr; gap: 8px 12px; }
  .sheet td { padding: 0; border: 0; }
  .sheet td:first-child { grid-column: 1 / -1; font-weight: 700; }
  .sheet td.num { text-align: left; }
  .sheet td[data-label]::before { content: attr(data-label); display: block; font-size: 0.85rem; color: var(--slate); }
  .sheet .cell-input { width: 100%; text-align: left; }
  .sheet td.energy { grid-column: 1 / -1; }
}

/* ---------- Category index ---------- */
.index { border-top: 2px solid var(--navy); }
.index__row { display: grid; gap: 6px 24px; padding: 26px 0 28px; border-bottom: 1px solid var(--line); text-decoration: none; }
.index__row:hover { background: var(--navy); color: var(--on-navy); padding-inline: 18px; margin-inline: -18px; }
.index__row:hover .muted, .index__row:hover .index__meta { color: var(--on-navy-mute); }
.index__name { font-family: var(--font-display); font-size: clamp(2.2rem, 5vw, 3.6rem); line-height: 0.95; }
.index__what { max-width: 46ch; }
.index__meta { color: var(--slate); }
.index__meta b { display: block; color: inherit; font-size: 1.35rem; }
.index__row:hover .index__meta b { color: var(--on-navy); }
@media (min-width: 860px) {
  .index__row { grid-template-columns: minmax(0, 4fr) minmax(0, 5fr) minmax(0, 2.4fr); align-items: baseline; }
  .index__meta { text-align: right; }
}

/* ---------- Order steps (a real sequence, so numbered) ---------- */
.steps { counter-reset: step; display: grid; gap: 0; position: relative; }
.steps li { counter-increment: step; position: relative; padding: 0 0 30px 56px; }
.steps li::before { content: counter(step); position: absolute; left: 0; top: -2px; width: 36px; height: 36px; background: var(--signal); color: var(--ink); font-family: var(--font-display); font-size: 1.35rem; line-height: 36px; text-align: center; }
.steps li::after { content: ""; position: absolute; left: 17px; top: 38px; bottom: 2px; width: 2px; background: var(--line-navy); }
.steps li:last-child { padding-bottom: 0; } .steps li:last-child::after { display: none; }
.steps h3 { font-size: 1.6rem; margin-bottom: 6px; }
.steps p { margin: 0; color: var(--on-navy-mute); max-width: 44ch; }
.section--mist .steps p, .section:not(.section--navy) .steps p { color: var(--slate); }
.section:not(.section--navy) .steps li::after { background: var(--line); }
@media (min-width: 900px) {
  .steps { grid-template-columns: repeat(5, 1fr); gap: 24px; }
  .steps li { padding: 56px 0 0 0; }
  .steps li::before { top: 0; }
  .steps li::after { left: 36px; top: 17px; bottom: auto; right: -24px; width: auto; height: 2px; }
}

/* A numbered list inside a narrow sidebar card stays vertical at every screen width
   (the wide-screen rule above lays steps out in a row, which crushes them inside a card). */
@media (min-width: 900px) {
  .summary .steps { grid-template-columns: 1fr; gap: 0; padding: 18px; }
  .summary .steps li { padding: 0 0 24px 56px; }
  .summary .steps li:last-child { padding-bottom: 0; }
  .summary .steps li::before { top: -2px; }
  .summary .steps li::after { left: 17px; top: 38px; bottom: 2px; right: auto; width: 2px; height: auto; }
}
.summary .steps { padding: 18px; }
.summary .steps p, .summary .steps li { max-width: none; }

/* ---------- Definition grid ---------- */
.defs { display: grid; gap: 0; border-top: 2px solid var(--navy); }
.defs > div { padding: 20px 0 22px; border-bottom: 1px solid var(--line); }
.defs dt { font-family: var(--font-display); font-size: 1.6rem; margin-bottom: 4px; }
.defs dd { margin: 0; max-width: 52ch; color: var(--slate); }
@media (min-width: 860px) { .defs { grid-template-columns: 1fr 1fr; column-gap: 48px; } }

/* ---------- FAQ ---------- */
.faq { border-top: 2px solid var(--navy); }
.faq__item { border-bottom: 1px solid var(--line); }
.faq__item summary { display: flex; align-items: center; justify-content: space-between; gap: 20px; padding: 20px 0; font-weight: 700; font-size: 1.25rem; cursor: pointer; list-style: none; }
.faq__item summary::-webkit-details-marker { display: none; }
.faq__item summary::after { content: ""; width: 20px; height: 20px; flex: none; background: currentColor; -webkit-mask: url("/assets/img/icons.svg#plus") center / contain no-repeat; mask: url("/assets/img/icons.svg#plus") center / contain no-repeat; }
.faq__item[open] summary::after { -webkit-mask-image: url("/assets/img/icons.svg#minus"); mask-image: url("/assets/img/icons.svg#minus"); }
.faq__a { padding: 0 0 22px; max-width: 62ch; color: var(--slate); }
.faq__a p { margin: 0; }

/* ---------- Product list ---------- */
.price { font-family: var(--font-display); font-size: 1.9rem; line-height: 1; white-space: nowrap; }
.rating { display: inline-flex; gap: 3px; align-items: center; vertical-align: middle; }
.rating__b { width: 11px; height: 11px; background: var(--line-soft); flex: none; }
.rating__b--on { background: var(--signal-press); }
.on-navy .rating__b, .section--navy .rating__b { background: var(--line-navy); }
.on-navy .rating__b--on, .section--navy .rating__b--on { background: var(--signal); }
.rating-line { display: inline-flex; align-items: center; gap: 8px; }
@media (min-width: 860px) {
}
.skeleton { height: 76px; border-bottom: 1px solid var(--line); background: var(--mist); animation: kb-pulse 1.4s ease-in-out infinite; }
@keyframes kb-pulse { 0%, 100% { opacity: 1; } 50% { opacity: 0.4; } }
@media (prefers-reduced-motion: reduce) { .skeleton { animation: none; } }
.skeleton--sm { height: 58px; }
.skeleton--bar { height: 1em; border-bottom: 0; border-radius: 2px; margin: 8px 0; }
.skeleton--btn { height: 44px; max-width: 220px; border-bottom: 0; margin-top: 14px; }
.skeleton--w40 { max-width: 40%; }
.skeleton--w60 { max-width: 60%; }
.skeleton--w90 { max-width: 90%; }
.problem { border: 2px solid var(--ink); background: var(--warn-bg); padding: 18px 20px; display: grid; gap: 12px; max-width: 62ch; }
.problem p { margin: 0; }
.empty { border: 2px dashed var(--edge); padding: 28px; max-width: 62ch; }
.empty h2 { font-size: 1.8rem; margin-bottom: 8px; }
.empty p:last-child { margin-bottom: 0; }

/* ---------- Technicians ---------- */
.tech-list { border-top: 2px solid var(--navy); }
.tech-row { display: grid; gap: 6px 20px; padding: 22px 0; border-bottom: 1px solid var(--line); text-decoration: none; }
.tech-row:hover { background: var(--navy); color: var(--on-navy); padding-inline: 18px; margin-inline: -18px; }
.tech-row:hover .muted, .tech-row:hover .tech-row__meta { color: var(--on-navy-mute); }
.tech-row__name { font-family: var(--font-display); font-size: 1.7rem; line-height: 1; }
.tech-row__meta { color: var(--slate); font-size: 1rem; }
.tech-avail { display: inline-flex; align-items: center; gap: 7px; font-weight: 700; font-size: 0.95rem; }
.tech-avail::before { content: ""; width: 9px; height: 9px; background: currentColor; }
.tech-avail--available { color: var(--ok); }
.tech-avail--on_job { color: #8A5A00; }
.tech-avail--inactive { color: var(--slate); }
@media (min-width: 800px) { .tech-row { grid-template-columns: 1fr auto auto; align-items: center; } }

.tech-head { display: grid; gap: 18px; }
.tech-head h1 { font-size: clamp(2.2rem, 5vw, 3.4rem); line-height: 1; }
@media (min-width: 700px) { .tech-head { grid-template-columns: 1fr auto; align-items: end; } }

.reviews { border-top: 2px solid var(--navy); display: grid; gap: 0; }
.review { padding: 20px 0; border-bottom: 1px solid var(--line); display: grid; gap: 6px; }
.review__meta { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; }
.review__date { color: var(--slate); font-size: 0.95rem; }
.review p { margin: 0; max-width: 62ch; }
.review__reply { color: var(--slate); border-left: 3px solid var(--line); padding-left: 12px; }

/* Technician profile (step 3.1b): avatar, name, three number tiles, groups of small labels, star breakdown. */
.pf { display: grid; gap: 22px; max-width: 640px; margin: 8px 0 24px; }
.pf-top { display: grid; justify-items: center; gap: 6px; text-align: center; }
.pf-avatar { width: 96px; height: 96px; border-radius: 50%; border: 3px solid var(--navy); background: var(--mist); color: var(--navy); display: grid; place-items: center; font-family: var(--font-display); font-size: 2.2rem; line-height: 1; overflow: hidden; }
.pf-avatar img { width: 100%; height: 100%; object-fit: cover; display: block; }
.pf-name { margin: 6px 0 0; font-size: clamp(1.8rem, 5vw, 2.4rem); line-height: 1.05; }
.pf-sub { margin: 0; color: var(--slate); }
.pf-tiles { display: grid; grid-template-columns: repeat(3, 1fr); border: 1px solid var(--line); background: var(--paper); }
.pf-tile { padding: 16px 8px; display: grid; justify-items: center; align-content: start; gap: 6px; text-align: center; }
.pf-tile + .pf-tile { border-left: 1px solid var(--line); }
.pf-tile__n { font-family: var(--font-display); font-size: 2rem; line-height: 1; color: var(--navy); }
.pf-tile__l { color: var(--slate); font-size: 0.95rem; }
.pf-groups { display: grid; gap: 16px; padding: 18px; border: 1px solid var(--line); background: var(--paper); }
.pf-group__t { margin: 0 0 8px; font-weight: 700; color: var(--slate); font-size: 0.85rem; letter-spacing: 0.06em; text-transform: uppercase; }
.pf-chips { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: 8px; }
.pf-chips li { border: 1px solid var(--line); background: var(--mist); padding: 6px 12px; font-weight: 700; }
.pf-bd { padding: 18px; border: 1px solid var(--line); background: var(--paper); }
.pf-bd__list { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; }
.pf-bd__row { display: grid; grid-template-columns: 1.5rem 1fr 2.5rem; gap: 10px; align-items: center; }
.pf-bd__c { text-align: right; color: var(--slate); }
.pf-bar { height: 10px; background: var(--line-soft); display: block; }
.pf-bar__fill { display: block; height: 100%; background: var(--signal-press); }
.pf-replyform { margin-top: 10px; }
.review__meta .tnum { font-weight: 700; }

/* The customer's review form (step 3.1b). */
.rv-rating { border: 0; padding: 0; margin: 0; }
.rv-rating legend { font-weight: 700; padding: 0; margin-bottom: 8px; }
.rv-choices { display: flex; flex-wrap: wrap; gap: 8px; }
.rv-choice { display: inline-flex; align-items: center; gap: 8px; min-height: 44px; padding: 8px 14px; border: 1px solid var(--line); background: var(--paper); cursor: pointer; }
.rv-choice:has(input:checked) { border-color: var(--navy); background: var(--mist); }
.rv-choice input { margin: 0; }
.rv-choice__w { color: var(--slate); }
@media (max-width: 420px) { .rv-choice__w { display: none; } }

.stars-input { display: inline-flex; gap: 6px; }
.stars-input button { width: 44px; height: 44px; border: 2px solid var(--edge); background: var(--paper); display: flex; align-items: center; justify-content: center; }
.stars-input button[aria-pressed="true"], .stars-input button.is-on { background: var(--navy); border-color: var(--navy); color: var(--on-navy); }
.stars-input i { width: 14px; height: 14px; background: currentColor; display: block; }

/* Product page */
@media (min-width: 900px) { .pdp { grid-template-columns: minmax(0, 6fr) minmax(0, 5fr); gap: 56px; } }

/* ---------- Cart and checkout ---------- */
.summary { border: 2px solid var(--navy); background: var(--paper); }
.summary h2 { font-size: 1.6rem; padding: 16px 18px; border-bottom: 2px solid var(--navy); background: var(--mist); }
.two-col { display: grid; gap: 40px; }
@media (min-width: 960px) { .two-col { grid-template-columns: minmax(0, 7.5fr) minmax(0, 4.5fr); gap: 64px; align-items: start; } .sticky { position: sticky; top: calc(var(--hdr-h) + 24px); } }
.note { font-size: 1rem; color: var(--slate); }
.note--box { border-left: 4px solid var(--signal); padding: 4px 0 4px 14px; }
.ir-row { border: 1px solid var(--line); padding: 14px; display: grid; gap: 12px; }

/* ---------- Picture picker (technician portal) ---------- */
.pk { padding: 14px; border: 1px solid var(--line); }
.pk__btn { width: 100%; min-height: 56px; font-size: 1.15rem; }
.pk__grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(112px, 1fr)); gap: 10px; }
.pk__grid:empty { display: none; }
.pk__tile { display: grid; gap: 6px; border: 1px solid var(--line); padding: 6px; background: var(--paper); }
.pk__img { width: 100%; aspect-ratio: 1; object-fit: cover; display: block; background: var(--mist); }
.pk__img--blank { display: grid; place-items: center; color: var(--slate); font-size: 0.9rem; }
.pk__state { font-size: 0.9rem; color: var(--slate); }
.pk__tile--done .pk__state { color: var(--ok); font-weight: 700; }
.pk__tile--error { border-color: var(--err); }
.pk__tile--error .pk__state { color: var(--err); font-weight: 700; }
.pk__remove { min-height: 38px; padding: 0 10px; }

/* ---------- Forms ---------- */
.form { display: grid; gap: 28px; max-width: 640px; }
.form fieldset { border: 0; padding: 0; margin: 0; display: grid; gap: 18px; }
.form legend { padding: 0; margin-bottom: 14px; font-family: var(--font-display); font-size: 1.7rem; line-height: 1; }
.field { display: grid; gap: 6px; }
.field > label, .label { font-weight: 700; }
.field .opt { font-weight: 400; color: var(--slate); }
.field input:not([type="checkbox"]), .field select, .field textarea {
  width: 100%; min-height: 52px; padding: 10px 14px; background: var(--paper);
  border: 2px solid var(--edge); border-radius: var(--radius);
}
.field textarea { min-height: 112px; resize: vertical; line-height: 1.4; }
.field input:focus-visible, .field select:focus-visible, .field textarea:focus-visible { border-color: var(--navy); outline-offset: 0; }
.field [aria-invalid="true"] { border-color: var(--err); }
.field__hint { font-size: 1rem; color: var(--slate); }
.field__err { display: flex; gap: 8px; color: var(--err); font-weight: 700; font-size: 1rem; }
.field__err .ic { width: 20px; height: 20px; margin-top: 2px; }
.check { display: grid; grid-template-columns: 26px 1fr; gap: 12px; align-items: start; }
.check input { width: 26px; height: 26px; margin: 1px 0 0; accent-color: var(--navy); }
.pw { position: relative; }
.pw input { padding-right: 56px !important; }
.pw button { position: absolute; right: 2px; top: 2px; bottom: 2px; width: 50px; border: 0; background: transparent; display: flex; align-items: center; justify-content: center; }
.pw button:hover { background: var(--mist); }
.honey { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
.errors { border: 2px solid var(--err); background: var(--paper); padding: 16px 18px; }
.errors h2 { font-size: 1.4rem; color: var(--err); margin-bottom: 6px; }
.errors ul { list-style: disc; padding-left: 1.2em; }
.errors a { font-weight: 700; }
.success { border: 2px solid var(--ok); padding: 16px 18px; background: var(--paper); }
.auth { display: grid; gap: 40px; }
@media (min-width: 900px) { .auth { grid-template-columns: minmax(0, 5fr) minmax(0, 6fr); gap: 72px; align-items: start; } }
.strength { height: 6px; background: var(--line-soft); display: grid; grid-template-columns: repeat(4, 1fr); gap: 3px; }
.strength i { background: var(--line); } .strength[data-level="1"] i:nth-child(-n+1), .strength[data-level="2"] i:nth-child(-n+2), .strength[data-level="3"] i:nth-child(-n+3), .strength[data-level="4"] i:nth-child(-n+4) { background: var(--navy); }

/* ---------- Account and orders ---------- */
.tabs { display: flex; flex-wrap: wrap; gap: 0; border-bottom: 2px solid var(--navy); margin-bottom: 32px; }
.tabs a { padding: 12px 18px; text-decoration: none; font-weight: 700; border: 2px solid transparent; border-bottom: 0; margin-bottom: -2px; }
.tabs a[aria-current="page"] { background: var(--navy); color: var(--on-navy); }
.orders { border-top: 2px solid var(--navy); }
.orders__row { display: grid; gap: 4px 20px; padding: 18px 0; border-bottom: 1px solid var(--line); text-decoration: none; }
.orders__row:hover { background: var(--mist); }
.orders__ref { font-family: var(--font-display); font-size: 1.5rem; }
@media (min-width: 760px) { .orders__row { grid-template-columns: 1.3fr 1fr 1fr 1fr; align-items: center; } .orders__row .end { text-align: right; } }
.status { display: inline-block; padding: 3px 10px; border: 2px solid currentColor; font-weight: 700; font-size: 0.95rem; }
.status--ok { color: var(--ok); } .status--wait { color: #8A5A00; } .status--bad { color: var(--err); } .status--info { color: var(--navy); }
.timeline { counter-reset: t; border-left: 2px solid var(--line); margin-left: 8px; }
.timeline li { position: relative; padding: 0 0 22px 28px; }
.timeline li::before { content: ""; position: absolute; left: -9px; top: 4px; width: 16px; height: 16px; background: var(--paper); border: 2px solid var(--edge); }
.timeline li.done::before { background: var(--navy); border-color: var(--navy); }
.timeline li.now::before { background: var(--signal); border-color: var(--navy); }
.timeline li.bad::before { background: var(--err); border-color: var(--err); }
.timeline b { display: block; }
.dl { display: grid; gap: 0; border-top: 2px solid var(--navy); margin: 0; }
.dl > div { display: grid; grid-template-columns: 10rem 1fr; gap: 12px; padding: 12px 0; border-bottom: 1px solid var(--line); }
.dl dt { color: var(--slate); } .dl dd { margin: 0; overflow-wrap: anywhere; }

/* ---------- Prose (legal and long text) ---------- */
.prose { max-width: 68ch; }
.prose h2 { font-size: 2rem; margin: 2.2em 0 0.5em; }
.prose h3 { font-size: 1.45rem; margin: 1.6em 0 0.4em; }
.prose ul { list-style: disc; padding-left: 1.3em; margin: 0 0 1em; } .prose ol { list-style: decimal; padding-left: 1.4em; margin: 0 0 1em; }
.prose li { margin-bottom: 0.4em; }
.prose table { margin: 0 0 1.4em; font-size: 1.02rem; }
.prose th, .prose td { text-align: left; padding: 10px 12px; border: 1px solid var(--line); vertical-align: top; }
.prose th { background: var(--mist); }
.scroll-x { overflow-x: auto; }

/* ---------- CTA block ---------- */
.cta { display: grid; gap: 28px; }
.cta h2 { font-size: clamp(2.2rem, 5vw, 3.8rem); line-height: 0.96; max-width: 16ch; }
.cta__contact { display: grid; gap: 10px; align-content: start; }
.cta__contact a, .cta__contact span { display: flex; align-items: center; gap: 10px; }
@media (min-width: 900px) { .cta { grid-template-columns: minmax(0, 7fr) minmax(0, 5fr); gap: 64px; align-items: end; } }

/* ---------- Footer ---------- */
.ftr { background: var(--navy); color: var(--on-navy); padding-top: clamp(44px, 6vw, 80px); }
.ftr a { text-decoration-color: var(--on-navy-mute); }
.ftr__grid { display: grid; gap: 36px; padding-bottom: 44px; }
.ftr__blurb { color: var(--on-navy-mute); max-width: 34ch; margin: 14px 0; }
.ftr__addr { display: grid; gap: 4px; color: var(--on-navy-mute); font-size: 1.02rem; }
.ftr__line { display: block; }
.ftr__h { font-size: 1.25rem; margin-bottom: 10px; color: var(--on-navy); }
.ftr__col li { margin: 0 0 6px; }
.ftr__col a, .ftr__col .linklike { color: var(--on-navy-mute); }
.ftr__col a:hover, .ftr__col .linklike:hover { color: var(--on-navy); }
.ftr__base { display: grid; gap: 4px; padding-block: 22px; border-top: 1px solid var(--line-navy); color: var(--on-navy-mute); font-size: 0.98rem; }
.ftr__base p { margin: 0; }
@media (min-width: 900px) { .ftr__grid { grid-template-columns: 1.6fr 1fr 1fr 1fr; gap: 56px; } .ftr__base { grid-template-columns: 1fr auto; } }

/* ---------- Mobile action bar ---------- */
.mbar { display: none; }
@media (max-width: 799px) {
  .mbar { position: fixed; z-index: 45; left: 0; right: 0; bottom: 0; display: flex; background: var(--navy); border-top: 3px solid var(--signal); padding-bottom: env(safe-area-inset-bottom, 0); }
  .mbar__btn { flex: 1; display: flex; align-items: center; justify-content: center; gap: 8px; min-height: 56px; background: transparent; color: var(--on-navy); border: 0; border-right: 1px solid var(--line-navy); font-weight: 700; font-size: 1.05rem; text-decoration: none; }
  .mbar__btn:last-child { border-right: 0; }
  .mbar__btn--primary { background: var(--signal); color: var(--ink); }
  .mbar .ic { width: 20px; height: 20px; }
  body { padding-bottom: calc(60px + env(safe-area-inset-bottom, 0)); }
  body[data-page="checkout"] .mbar, body[data-page="quote"] .mbar { display: none; }
  body[data-page="checkout"], body[data-page="quote"] { padding-bottom: 0; }
}

/* ---------- Chat ---------- */
.chat__launch { position: fixed; right: 20px; bottom: 20px; z-index: 46; display: none; align-items: center; gap: 10px; min-height: 54px; padding: 0 20px; background: var(--navy); color: var(--on-navy); border: 2px solid var(--signal); border-radius: var(--radius); font-weight: 700; }
.chat__launch:hover { background: var(--navy-3); }
@media (min-width: 800px) { .chat__launch { display: inline-flex; } }
.chatbox { display: flex; flex-direction: column; background: var(--paper); border: 2px solid var(--navy); color: var(--ink); min-height: 0; }
.chatbox--float { position: fixed; z-index: 90; right: 20px; bottom: 20px; width: 400px; height: min(640px, calc(100vh - 40px)); box-shadow: 0 0 0 1px var(--paper); }
@media (max-width: 799px) { .chatbox--float { inset: 0; width: auto; height: auto; border: 0; } }
.chatbox__head { display: flex; align-items: center; justify-content: space-between; gap: 8px; padding: 12px 14px; background: var(--navy); color: var(--on-navy); }
.chatbox__title { font-family: var(--font-display); font-size: 1.4rem; line-height: 1; }
.chatbox__btn { display: inline-flex; align-items: center; justify-content: center; gap: 6px; min-width: 44px; min-height: 44px; padding: 0 10px; border: 0; background: transparent; color: inherit; font-weight: 700; }
.chatbox__btn:hover { background: var(--navy-2); }
.chatbox__notice { margin: 0; padding: 10px 14px; font-size: 0.95rem; background: var(--mist); border-bottom: 1px solid var(--line); color: var(--ink); }
.chatbox__log { flex: 1; overflow-y: auto; padding: 14px; display: grid; gap: 12px; align-content: start; background: var(--paper); }
.msg { max-width: 88%; padding: 10px 14px; white-space: pre-wrap; overflow-wrap: anywhere; line-height: 1.4; border-radius: var(--radius); }
.msg--bot { background: var(--mist); justify-self: start; }
.msg--me { background: var(--navy); color: var(--on-navy); justify-self: end; }
.msg--err { background: var(--paper); border: 2px solid var(--err); justify-self: start; }
.msg--err button { margin-top: 8px; }
.msg__who { display: block; font-size: 0.85rem; font-weight: 700; margin-bottom: 2px; color: var(--slate); }
.msg--me .msg__who { color: var(--on-navy-mute); }
.chatbox__form { display: flex; gap: 8px; padding: 12px; border-top: 2px solid var(--navy); background: var(--paper); }
.chatbox__form textarea { flex: 1; min-height: 48px; max-height: 120px; padding: 10px 12px; border: 2px solid var(--edge); border-radius: var(--radius); resize: none; line-height: 1.3; }
.chatbox__form textarea:focus-visible { border-color: var(--navy); outline-offset: 0; }
.chatbox__send { min-width: 52px; }

/* ---------- Consent dialog ---------- */
.consent { position: fixed; z-index: 100; left: 16px; bottom: 16px; width: min(460px, calc(100vw - 32px)); background: var(--paper); border: 2px solid var(--navy); padding: 18px; display: grid; gap: 12px; }
.consent h2 { font-size: 1.5rem; }
.consent p { margin: 0; font-size: 1.02rem; }
.consent .actions .btn { flex: 1 1 auto; }
@media (max-width: 799px) { .consent { bottom: 72px; } }

/* ---------- Misc ---------- */
.stack > * + * { margin-top: 1.2rem; }
.split { display: grid; gap: 24px; }
@media (min-width: 860px) { .split { grid-template-columns: 1fr 1fr; gap: 56px; } }
.kv { display: grid; gap: 4px; }
.tag { display: inline-block; padding: 2px 8px; background: var(--signal); color: var(--ink); font-weight: 700; font-size: 0.95rem; }

@media (prefers-reduced-motion: no-preference) {
  .btn, .index__row, .hdr__link { transition: background-color 0.12s ease, color 0.12s ease; }
}
@media (forced-colors: active) { .btn, .chat__launch { border: 2px solid ButtonText; } }
@media print {
  .hdr, .ftr, .mbar, .chat, .net, .consent, .skip { display: none !important; }
  body { padding: 0; font-size: 12pt; }
  a { text-decoration: none; }
}

.btnrow { display: flex; flex-wrap: wrap; gap: 10px; }

.agreement-text { white-space: pre-wrap; max-height: 24rem; overflow: auto; border: 2px solid var(--navy); padding: 14px; background: #fff; font-size: 0.95rem; line-height: 1.5; }

/* location help (technician application, customer request) */
.lochelp { border: 2px solid var(--navy); background: var(--paper); margin: 8px 0 12px; }
.lochelp > summary { padding: 12px 14px; font-weight: 700; cursor: pointer; min-height: 44px; display: flex; align-items: center; }
.lochelp[open] > summary { border-bottom: 2px solid var(--navy); }
.lochelp__body { padding: 12px 14px 14px; display: grid; gap: 10px; }
.lochelp__body ol { padding-left: 26px; display: grid; gap: 6px; list-style: decimal; }
.lochelp__body li { padding-left: 4px; }
.lochelp code { background: #fff; border: 1px solid var(--line-navy); padding: 1px 6px; font-size: .95em; white-space: nowrap; }

/* Inspection report shown to the customer (My requests). Pictures are signed private links. */
.report-photos { display: grid; grid-template-columns: repeat(auto-fill, minmax(112px, 1fr)); gap: 8px; margin: 8px 0; }
.report-photos a { display: block; border: 1px solid var(--line); background: var(--line-soft); }
.report-photos img { display: block; width: 100%; aspect-ratio: 1 / 1; object-fit: cover; }
.report-photos a:focus-visible { outline: 3px solid var(--signal); outline-offset: 2px; }
.report-materials { margin: 4px 0 8px; padding-left: 20px; }

/* ---------- Supplier price reply (/supplier/) ---------- */
.sp-head { max-width: 640px; margin-bottom: 20px; }
.sp-item { border: 1px solid var(--line); padding: 14px; display: grid; gap: 14px; }
.sp-item legend { font-weight: 700; padding: 0 6px; font-family: var(--font-text); font-size: 1.1rem; line-height: 1.3; margin: 0; }
.sp-choice { display: grid; gap: 10px; }
@media (min-width: 560px) { .sp-choice { grid-template-columns: 1fr 1fr; } }
.sp-total { font-weight: 700; }
/* material delivery (step 2.4d) */
.delivery-code-box { margin: 10px 0; padding: 14px; border: 2px solid var(--ink, currentColor); background: var(--paper, transparent); }
.delivery-code { font-family: ui-monospace, "SFMono-Regular", Menlo, Consolas, monospace; font-size: 2rem; font-weight: 700; letter-spacing: .35em; margin: 4px 0 8px; user-select: all; }
.dl-item--bad { border-color: #b00020; box-shadow: 0 0 0 2px #b00020; }
.dl-fault { margin-top: 10px; }
.dl-fault summary { cursor: pointer; font-weight: 700; padding: 8px 0; }
.dl-fault-row { display: grid; gap: 6px; margin-bottom: 10px; }

/* The customer quote (step 2.2c) */
.quote-table { margin: 8px 0; font-size: 1.02rem; }
.quote-table th, .quote-table td { padding: 7px 0; border-bottom: 1px solid var(--line); text-align: left; vertical-align: top; }
.quote-table th { font-weight: 400; padding-right: 12px; }
.quote-table td { text-align: right; white-space: nowrap; }
.quote-table .quote-total th, .quote-table .quote-total td { font-weight: 700; border-bottom: 0; border-top: 2px solid var(--ink); }
.quote-choice { border: 0; margin: 12px 0; padding: 0; min-width: 0; }
.quote-choice legend { font-weight: 700; padding: 0; margin-bottom: 4px; }
.quote-choice label { display: flex; gap: 10px; align-items: flex-start; padding: 8px 0; cursor: pointer; }
.quote-choice input[type="radio"] { margin-top: 5px; flex: none; }
.quote-actions { margin-top: 8px; }
.ws-day { max-width: 22rem; }
.ws-where { list-style: none; padding: 0; margin: 0 0 8px; display: grid; gap: 4px; }
.workstart .status { white-space: normal; }

/* step 3.1c: complaint about a review, picture box, one block for each person of a job */
.pf-complaint { margin-top: 10px; }
.pf-complaint summary { cursor: pointer; min-height: 44px; display: inline-flex; align-items: center; color: var(--slate); text-decoration: underline; }
.pf-picture { margin: 18px 0; display: grid; gap: 10px; }

/* ==========================================================================
   S1 DESIGN FOUNDATION (18 Oct 2026)
   Same colours, same fonts, same square corners. This block adds depth, one spacing scale and the
   shared parts every later screen uses: cards, status chips, three button roles, notices, empty
   states, loading blocks, a step tracker, a card grid, tables that turn into cards on phones, a
   sticky action bar on phones. Preview page: /styleguide/ (not linked, not indexed).
   Rule kept: no gradients, no scroll animation.
   ========================================================================== */
:root {
  --shadow-1: 0 1px 2px rgba(11, 37, 69, 0.08), 0 2px 8px rgba(11, 37, 69, 0.06);
  --shadow-2: 0 2px 4px rgba(11, 37, 69, 0.10), 0 10px 28px rgba(11, 37, 69, 0.12);
  --tint-ok: #E6F2EB;
  --tint-wait: #FFF4CC;
  --tint-bad: #FBE8E6;
  --tint-info: #E7EEF7;
  --sp-1: 4px; --sp-2: 8px; --sp-3: 12px; --sp-4: 16px; --sp-5: 24px; --sp-6: 32px; --sp-7: 48px; --sp-8: 72px;
  --measure: 68ch;
  --narrow: 760px;
}

/* page widths and grids */
.wrap--narrow { max-width: calc(var(--narrow) + 2 * var(--gutter)); }
.measure { max-width: var(--measure); }
.grid-2 { display: grid; gap: var(--sp-6); }
.grid-aside { display: grid; gap: var(--sp-6); }
@media (min-width: 960px) {
  .grid-2 { grid-template-columns: 1fr 1fr; align-items: start; }
  .grid-aside { grid-template-columns: minmax(280px, 360px) 1fr; align-items: start; }
  .grid-aside > .sticky { position: sticky; top: calc(var(--hdr-h) + 16px); }
}
.cluster { display: flex; flex-wrap: wrap; align-items: center; gap: var(--sp-3) var(--sp-4); }

/* cards */
.card { background: var(--paper); border: 1px solid var(--line); border-top: 4px solid var(--navy); box-shadow: var(--shadow-1); padding: var(--sp-5) clamp(16px, 3vw, 28px); }
.card--flat { box-shadow: none; border-top-width: 1px; }
.card--signal { border-top-color: var(--signal); }
.card--lift { transition: box-shadow 0.15s ease, transform 0.15s ease; }
.card--lift:hover { box-shadow: var(--shadow-2); transform: translateY(-2px); }
.card > :first-child { margin-top: 0; }
.card > :last-child { margin-bottom: 0; }
.cards { display: grid; gap: var(--sp-5); grid-template-columns: repeat(auto-fill, minmax(min(100%, 280px), 1fr)); }

/* My requests: each request is one card, with air between cards */
.reqhead { margin-bottom: var(--sp-5); }
.reqcard { background: var(--paper); border: 1px solid var(--line); border-top: 4px solid var(--navy); box-shadow: var(--shadow-1); padding: var(--sp-5) clamp(16px, 3vw, 28px) var(--sp-6); margin-bottom: var(--sp-6); }
.reqcard > .rule { display: none; }
.reqmeta { display: flex; flex-wrap: wrap; align-items: center; gap: var(--sp-2) var(--sp-4); margin: 0; }

/* status chips: the colour carries the meaning (green done, yellow waiting, red stopped, blue your move) */
.status { border-width: 1px; padding: 4px 12px; font-size: 0.9rem; letter-spacing: 0.01em; background: var(--tint-info); }
.status--ok { background: var(--tint-ok); }
.status--wait { background: var(--tint-wait); }
.status--bad { background: var(--tint-bad); }
.status--info { background: var(--tint-info); }
.status--muted { color: var(--slate); background: var(--mist); }
.note--box { background: var(--mist); padding: var(--sp-4); border-left: 4px solid var(--signal); }
.note--box > :first-child { margin-top: 0; }
.note--box > :last-child { margin-bottom: 0; }

/* buttons: ONE main (navy), ONE second (outline), ONE danger (red outline), quiet (a link). Yellow stays the site call to action. */
.btn--second { background: var(--paper); border-color: var(--navy); color: var(--navy); }
.btn--second:hover { background: var(--mist); border-color: var(--navy); }
.btn--danger { background: transparent; border-color: var(--err); color: var(--err); }
.btn--danger:hover { background: var(--err); border-color: var(--err); color: #fff; }
.btn--quiet { background: transparent; border-color: transparent; color: var(--navy); text-decoration: underline; text-underline-offset: 3px; }
.btn--quiet:hover { background: var(--mist); border-color: transparent; }
.btn:focus-visible, .chat__launch:focus-visible { outline: 3px solid var(--navy); outline-offset: 3px; }
.btnrow { align-items: center; }

/* inline messages */
.notice { display: flex; gap: var(--sp-3); align-items: flex-start; padding: var(--sp-4); border: 1px solid var(--line); border-left-width: 4px; background: var(--paper); }
.notice p { margin: 0; }
.notice--ok { border-left-color: var(--ok); background: var(--tint-ok); }
.notice--wait { border-left-color: var(--signal-press); background: var(--tint-wait); }
.notice--bad { border-left-color: var(--err); background: var(--tint-bad); }
.notice--info { border-left-color: var(--navy); background: var(--tint-info); }

/* empty state (loading blocks `.skeleton` already exist above and are reused) */
.empty { max-width: none; display: grid; justify-items: start; gap: var(--sp-3); padding: var(--sp-6) var(--sp-5); background: var(--paper); border: 2px dashed var(--line); color: var(--slate); }
.empty h2, .empty h3 { margin: 0; color: var(--ink); }
.empty p { margin: 0; max-width: 52ch; }
.empty--center { justify-items: center; text-align: center; }
@media (prefers-reduced-motion: reduce) { .card--lift { transition: none; } .card--lift:hover { transform: none; } }

/* step tracker: where the job is in the journey */
.track { list-style: none; margin: 0; padding: 0; display: grid; grid-auto-flow: column; grid-auto-columns: minmax(84px, 1fr); overflow-x: auto; counter-reset: tr; }
.track li { position: relative; padding: 32px 6px 4px; text-align: center; font-size: 0.85rem; color: var(--slate); counter-increment: tr; }
.track li::before { content: counter(tr); position: absolute; top: 0; left: 50%; transform: translateX(-50%); width: 24px; height: 24px; display: grid; place-items: center; background: var(--paper); border: 2px solid var(--edge); font-weight: 700; font-size: 0.8rem; z-index: 1; }
.track li::after { content: ""; position: absolute; top: 11px; left: calc(-50% + 12px); right: calc(50% + 12px); height: 2px; background: var(--line); }
.track li:first-child::after { display: none; }
.track li.done { color: var(--ink); }
.track li.done::before { background: var(--navy); border-color: var(--navy); color: #fff; content: "\2713"; }
.track li.done::after, .track li.now::after { background: var(--navy); }
.track li.now { color: var(--ink); font-weight: 700; }
.track li.now::before { background: var(--signal); border-color: var(--navy); color: var(--ink); }

/* tables that turn into cards on a phone (td needs data-label) */
.tbl { width: 100%; border-collapse: collapse; background: var(--paper); border: 1px solid var(--line); }
.tbl th { text-align: left; font-size: 0.85rem; letter-spacing: 0.06em; text-transform: uppercase; color: var(--slate); background: var(--mist); }
.tbl th, .tbl td { padding: 12px 14px; border-bottom: 1px solid var(--line-soft); vertical-align: top; }
@media (max-width: 719px) {
  .tbl, .tbl tbody, .tbl tr, .tbl td { display: block; width: 100%; }
  .tbl thead { position: absolute; left: -9999px; }
  .tbl tr { border: 1px solid var(--line); border-top: 4px solid var(--navy); margin-bottom: var(--sp-4); background: var(--paper); box-shadow: var(--shadow-1); }
  .tbl td { border: 0; border-bottom: 1px solid var(--line-soft); display: grid; grid-template-columns: 38% 1fr; gap: 10px; }
  .tbl td::before { content: attr(data-label); font-weight: 700; color: var(--slate); }
}

/* numbers */
.stat { display: grid; gap: 2px; }
.stat__n { font-family: var(--font-display); font-size: 2.2rem; line-height: 1; color: var(--navy); }
.stat__l { color: var(--slate); }

/* sticky action bar on phones: the one main action stays under the thumb */
.actionbar { display: none; }
@media (max-width: 799px) {
  .actionbar { display: flex; gap: var(--sp-3); position: sticky; bottom: calc(59px + env(safe-area-inset-bottom, 0px)); z-index: 40; padding: var(--sp-3) var(--gutter); background: var(--paper); border-top: 1px solid var(--line); box-shadow: 0 -4px 16px rgba(11, 37, 69, 0.10); }
  .actionbar .btn { flex: 1; }
}

/* the public technician page: a centred column, not a half-empty wide screen (S5 makes it two columns) */
#tech-profile .pf-tiles, #tech-profile .pf-groups, #tech-profile .pf-bd { box-shadow: var(--shadow-1); }
/* keep the floating Chat button off the bottom of the content on wide screens */
@media (min-width: 800px) { main { padding-bottom: 76px; } }

/* style guide page only */
.sg-swatch { display: inline-block; width: 64px; height: 64px; border: 1px solid var(--line); }
.sg-navy { background: #0B2545; } .sg-signal { background: #FFC61A; } .sg-mist { background: #EEF1F4; } .sg-ok { background: #146C43; } .sg-err { background: #B3261E; }
.sk-a { height: 20px; width: 40%; margin-bottom: 10px; } .sk-b { height: 14px; width: 90%; margin-bottom: 8px; } .sk-c { height: 14px; width: 75%; }
.card .skeleton { background: var(--line-soft); border-bottom: 0; }

/* ---------- public technician page (S5 start): profile card beside the details ---------- */
.tech-head { gap: var(--sp-4); }
.tech-head .lede { font-size: 1.3rem; margin: 0 0 var(--sp-3); }
.tech-avail { padding: 4px 12px; border: 1px solid currentColor; background: var(--paper); }
.tech-avail--available { background: var(--tint-ok); }
.tech-avail--on_job { background: var(--tint-wait); }
.tech-avail--inactive { background: var(--mist); }
.tech-page { background: var(--mist); }
.tech-page .grid-aside { gap: var(--sp-6); }
@media (min-width: 960px) { .tech-page .grid-aside { grid-template-columns: minmax(300px, 380px) minmax(0, 1fr); gap: 40px; } }
.tech-side { display: grid; gap: var(--sp-5); align-content: start; }
@media (min-width: 960px) and (min-height: 860px) { .tech-side { position: sticky; top: calc(var(--hdr-h) + 16px); } }
.tech-main { display: grid; gap: var(--sp-5); align-content: start; min-width: 0; }
.tech-block { background: var(--paper); border: 1px solid var(--line); border-top: 4px solid var(--navy); box-shadow: var(--shadow-1); padding: var(--sp-5) clamp(16px, 3vw, 28px); }
.tech-block.card--flat { box-shadow: none; border-top-width: 1px; }
.tech-block h2 { font-size: clamp(1.7rem, 3vw, 2.1rem); margin-bottom: var(--sp-3); }
.tech-block > .muted { margin-top: calc(-1 * var(--sp-2)); }
#tech-reviews .empty { border-style: dashed; }
.tech-cta h2 { font-size: 1.7rem; margin-bottom: var(--sp-3); }
.tech-cta p { color: var(--slate); }
/* the profile card: one card, avatar on a navy band, labels as plain rows */
.tech-side .pf { background: var(--paper); border: 1px solid var(--line); box-shadow: var(--shadow-1); display: grid; gap: 0; }
.tech-side .pf-top { background: var(--navy); padding: var(--sp-6) var(--sp-5) var(--sp-5); }
.tech-side .pf-avatar { width: 120px; height: 120px; border-color: var(--signal); background: var(--navy-3); color: var(--on-navy); font-size: 2.6rem; }
.tech-side .pf-tiles, .tech-side .pf-groups, .tech-side .pf-bd { border: 0; border-top: 1px solid var(--line); box-shadow: none; }
.tech-side .pf-groups { gap: 0; padding: 0; }
.tech-side .pf-group { display: grid; grid-template-columns: 9rem 1fr; gap: var(--sp-3); align-items: center; padding: var(--sp-3) var(--sp-5); border-bottom: 1px solid var(--line-soft); }
.tech-side .pf-group:last-child { border-bottom: 0; }
.tech-side .pf-group__t { margin: 0; }
.tech-side .pf-chips li { border: 0; background: transparent; padding: 0; font-weight: 700; }
.tech-side .pf-bd { padding: var(--sp-5); }
/* the five steps, always vertical */
.tech-steps { counter-reset: ts; display: grid; gap: 0; }
.tech-steps li { counter-increment: ts; position: relative; padding: 0 0 var(--sp-5) 56px; }
.tech-steps li::before { content: counter(ts); position: absolute; left: 0; top: -2px; width: 36px; height: 36px; background: var(--signal); color: var(--ink); font-family: var(--font-display); font-size: 1.35rem; line-height: 36px; text-align: center; }
.tech-steps li::after { content: ""; position: absolute; left: 17px; top: 38px; bottom: 4px; width: 2px; background: var(--line); }
.tech-steps li:last-child { padding-bottom: 0; }
.tech-steps li:last-child::after { display: none; }
.tech-steps h3 { font-size: 1.35rem; margin-bottom: 4px; }
.tech-steps p { margin: 0; color: var(--slate); max-width: 56ch; }
.tech-checks { display: grid; gap: var(--sp-3); }
.tech-checks li { position: relative; padding-left: 28px; }
.tech-checks li::before { content: "\2713"; position: absolute; left: 0; top: 0; color: var(--ok); font-weight: 700; }
.pagehead--compact { padding-bottom: var(--sp-5); }
.pagehead--compact .tech-head { margin-top: var(--sp-3); }
.tech-page.section--tight { padding-top: var(--sp-5); }

/* S2 REMOVE THE SHOP: header call to action (wide screens; phones use the bottom bar), bottom-bar link */
.hdr__cta { display: none; margin-right: 8px; }
@media (min-width: 980px) { .hdr__cta { display: inline-flex; } }
.mbar a.mbar__btn { text-decoration: none; }
/* Six-step list (home, how it works): three by two on wide screens, so no step sits alone */
@media (min-width: 860px) {
  .steps--six { grid-template-columns: repeat(3, 1fr); gap: 40px 28px; }
  .steps--six li:nth-child(3n)::after { display: none; }
}

/* ACCOUNT TABS (Profile, Security, Privacy): one card per setting, air between cards, buttons that keep their own width */
.acct-cards { display: grid; gap: var(--sp-5); max-width: 760px; }
.acct-card { display: grid; gap: var(--sp-4); align-content: start; }
.acct-card > * { margin: 0; }
.acct-card__head { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: var(--sp-2) var(--sp-4); }
.acct-card__head .h-s { margin: 0; }
.acct-card .form { gap: var(--sp-4); max-width: none; }
.acct-card__actions { display: flex; flex-wrap: wrap; gap: var(--sp-3); }
.acct-card__actions .btn { justify-self: start; }
.acct-card--warn { border-top-color: var(--err); }
.acct-qr { background: #fff; border: 1px solid var(--line); padding: var(--sp-2); max-width: 100%; height: auto; }
.acct-secret { overflow-wrap: anywhere; background: var(--mist); padding: var(--sp-3); margin: 0; }
.acct-card .success, .acct-card .errors { margin: 0; }
@media (max-width: 560px) {
  .acct-card__actions .btn, .acct-card .actions .btn { width: 100%; }
}
/* the four account tabs fit on one line on a phone */
@media (max-width: 480px) { .tabs a { padding: 12px 11px; font-size: 1rem; } }

/* TRADES SLICE (18 Oct 2026): technician application as cards, trade tiles, proof per trade, inspection report as numbered cards */
.apply-form { display: grid; gap: var(--sp-6); max-width: 860px; }
.apply-form > * { margin: 0; }
.apply-form fieldset { border: 1px solid var(--line); border-top: 4px solid var(--navy); background: var(--paper); box-shadow: var(--shadow-1); padding: var(--sp-5) clamp(16px, 3vw, 28px) var(--sp-6); min-width: 0; display: grid; gap: var(--sp-4); align-content: start; }
.apply-form legend { float: left; width: 100%; margin: 0 0 var(--sp-2); padding: 0; display: flex; align-items: center; gap: var(--sp-3); }
.apply-n { display: inline-grid; place-items: center; width: 34px; height: 34px; flex: none; background: var(--signal); color: var(--ink); font-family: var(--font-display); font-size: 1.3rem; line-height: 1; }
.trades { display: grid; gap: var(--sp-3); grid-template-columns: repeat(auto-fill, minmax(min(100%, 230px), 1fr)); }
.trade { position: relative; display: grid; gap: 4px; align-content: start; padding: var(--sp-4) var(--sp-4) var(--sp-4) 52px; border: 2px solid var(--line); background: var(--paper); cursor: pointer; min-height: 44px; }
.trade:hover { border-color: var(--navy-3); }
.trade input { position: absolute; left: 14px; top: 16px; width: 26px; height: 26px; margin: 0; accent-color: var(--navy); }
.trade__t { font-weight: 700; }
.trade__d { font-size: 0.95rem; color: var(--slate); }
.trade--on { border-color: var(--navy); background: var(--tint-info); box-shadow: inset 4px 0 0 var(--signal); }
.trade:has(input:disabled) { opacity: 0.55; cursor: not-allowed; }
.proof { display: grid; gap: var(--sp-3); }
.proof__head { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: var(--sp-2) var(--sp-4); }
.proof__head .h-s { margin: 0; }
.proof__files { list-style: none; margin: 0; padding: 0; display: grid; gap: var(--sp-2); }
.proof__files li { display: flex; align-items: center; justify-content: space-between; gap: var(--sp-3); padding: var(--sp-2) var(--sp-3); background: var(--mist); }
.proof--stray { border-top-color: var(--err); }
.apply-ready__list { list-style: none; margin: 0; padding: 0; display: grid; gap: var(--sp-2); }
.apply-ready__list li { display: flex; align-items: baseline; gap: var(--sp-3); }
.apply-ready__mark { display: inline-grid; place-items: center; width: 24px; height: 24px; flex: none; border: 2px solid var(--edge); font-weight: 700; font-size: 0.9rem; }
.apply-ready__list .is-ok .apply-ready__mark { background: var(--ok); border-color: var(--ok); color: #fff; }
.apply-ready__note { color: var(--slate); font-size: 0.95rem; margin-top: var(--sp-2); }
.apply-form .btnrow .btn { min-height: 48px; }
@media (max-width: 560px) { .apply-form .btnrow .btn { width: 100%; } }

.ir { gap: var(--sp-5); }
.ir-sec { display: grid; gap: var(--sp-4); }
.ir-sec > * { margin: 0; }
.ir-sec__h { display: flex; flex-wrap: wrap; align-items: center; gap: var(--sp-3); margin: 0; font-family: var(--font-display); font-size: 1.5rem; line-height: 1.1; font-weight: 400; }
.ir-sec__h .opt { font-family: var(--font-text); font-size: 1rem; color: var(--slate); }
.ir-sec .ir-row { background: var(--mist); border: 1px solid var(--line); padding: var(--sp-4); }
.ir-row__head { margin: 0; }
@media (min-width: 640px) {
  .ir-row--mat { grid-template-columns: minmax(0, 2fr) minmax(0, 1fr) auto; align-items: end; }
  .ir-row--mat > .field[hidden] { display: none; }
}
/* the Submit button of the technician actions: a normal button on a wide screen, a sticky bar above the phone's bottom bar */
.submitbar { display: flex; }
@media (max-width: 799px) {
  .submitbar { gap: var(--sp-3); position: sticky; bottom: calc(59px + env(safe-area-inset-bottom, 0px)); z-index: 40; padding: var(--sp-3) var(--gutter); margin-inline: calc(var(--gutter) * -1); background: var(--paper); border-top: 1px solid var(--line); box-shadow: 0 -4px 16px rgba(11, 37, 69, 0.10); }
  .submitbar .btn { flex: 1; }
}
.apply-form .status { justify-self: start; }
#tech-action-form { max-width: 760px; }
.ir-sec > .btn { justify-self: start; }
@media (min-width: 640px) {
  .ir-row .field:has(.ir-hours), .ir-row .field:has(.ir-amount) { max-width: 320px; }
}

/* FORMS REDESIGN (19 Oct 2026): application and request forms. Two columns for short fields, numbered cards, trade tiles for a single choice */
.apply-form fieldset { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.apply-form fieldset > * { grid-column: 1 / -1; }
.apply-form fieldset > .field--half { grid-column: auto; }
.apply-form fieldset[hidden] { display: none; }
@media (max-width: 639px) { .apply-form fieldset > .field--half { grid-column: 1 / -1; } }
.apply-form--fluid { max-width: none; }
.apply-form--count { counter-reset: rqstep; }
.apply-form--count legend { counter-increment: rqstep; }
.apply-form--count legend::before { content: counter(rqstep); display: inline-grid; place-items: center; width: 34px; height: 34px; flex: none; background: var(--signal); color: var(--ink); font-family: var(--font-display); font-size: 1.3rem; line-height: 1; }
.field > .label { display: block; font-weight: 700; }
.trade input[type="radio"] { border-radius: 50%; }
.apply-steps { display: flex; flex-wrap: wrap; gap: var(--sp-2); }
.apply-steps a { display: inline-flex; align-items: center; gap: 8px; min-height: 44px; padding: 6px 14px 6px 6px; border: 1px solid var(--line); background: var(--paper); color: var(--ink); font-weight: 700; font-size: 0.95rem; text-decoration: none; }
.apply-steps a:hover { border-color: var(--navy); }
.apply-steps .apply-n { width: 30px; height: 30px; font-size: 1.1rem; }
.apply-form fieldset { scroll-margin-top: 90px; }
.trade input[type="radio"] { position: absolute; left: 14px; top: 16px; width: 26px; height: 26px; min-height: 0; padding: 0; margin: 0; border: 2px solid var(--navy); background: var(--paper); accent-color: var(--navy); }
.apply-form .notice { display: block; }
.apply-form .notice p + p { margin-top: var(--sp-2); }

/* ---- technician application: kinds of job and tools photos (19 Oct 2026) ---- */
.specs { display: grid; gap: var(--sp-2); }
.specs__grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: var(--sp-2); }
.kindtick { display: grid; grid-template-columns: 26px 1fr; gap: 12px; align-items: start; padding: var(--sp-2) var(--sp-3); border: 1px solid var(--line); background: var(--paper); min-height: 44px; cursor: pointer; }
.kindtick input { width: 26px; height: 26px; margin: 1px 0 0; accent-color: var(--navy); }
.kindtick small { display: block; color: var(--slate); font-size: 0.875rem; }
.kindtick--on { border-color: var(--navy); background: var(--tint-info); }
.proof__sub { display: grid; gap: var(--sp-2); padding: var(--sp-3); border-left: 4px solid var(--signal); background: var(--mist); }
.proof__sub .proof__files li { background: var(--paper); }
.proof__sub-h { margin: 0; font-weight: 700; }
