/* Taupunkt: technical, quiet, numbers first. One blue accent, near-square corners. */

/* IBM Plex, self-hosted (SIL OFL 1.1, see fonts/IBM-Plex-LICENSE.txt). No third-party font requests.
   Sources: npm @ibm/plex-sans 1.1.0 and @ibm/plex-mono 2.5.0, fonts/complete/woff2. */
@font-face { font-family: "IBM Plex Sans"; font-style: normal; font-weight: 400; font-display: swap; src: url("/assets/IBMPlexSans-Regular-90cc55e6.woff2") format("woff2"); }
@font-face { font-family: "IBM Plex Sans"; font-style: normal; font-weight: 500; font-display: swap; src: url("/assets/IBMPlexSans-Medium-9fb7ea15.woff2") format("woff2"); }
@font-face { font-family: "IBM Plex Sans"; font-style: normal; font-weight: 600; font-display: swap; src: url("/assets/IBMPlexSans-SemiBold-5326bafa.woff2") format("woff2"); }
@font-face { font-family: "IBM Plex Mono"; font-style: normal; font-weight: 400; font-display: swap; src: url("/assets/IBMPlexMono-Regular-537ab494.woff2") format("woff2"); }
@font-face { font-family: "IBM Plex Mono"; font-style: normal; font-weight: 500; font-display: swap; src: url("/assets/IBMPlexMono-Medium-98c318fa.woff2") format("woff2"); }
:root {
  --bg: #F3F4F6;
  --surface: #FFFFFF;
  --surface-tint: #F2F5FC;
  --border: #DCDFE5;
  --border-soft: #EBEDF1;
  --border-input: #C9CED7;
  --text: #16181D;
  --text-2: #3A3D44;
  --muted: #5B5E66;
  --faint: #8C8E95;
  --primary: #1F4FD1;
  --primary-strong: #14358F;
  --primary-soft: #E7EDFB;
  --warn-bg: #FFFAF0;
  --warn-border: #F1D9A6;
  --warn-text: #7A4F00;
  --error: #B42318;
  --sans: "IBM Plex Sans", "Helvetica Neue", Arial, system-ui, sans-serif;
  --mono: "IBM Plex Mono", ui-monospace, "SF Mono", Menlo, Consolas, monospace;
  --radius: 2px;
  --radius-card: 3px;
}

*, *::before, *::after { box-sizing: border-box; }
[hidden] { display: none !important; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; background: var(--bg); color: var(--text); font: 13px/1.45 var(--sans); }
a { color: var(--primary); }
a:hover { color: var(--primary-strong); }
h1, h2, h3 { margin: 0; line-height: 1.25; }
button, input, select { font: inherit; color: inherit; }
:focus-visible { outline: 2px solid var(--primary); outline-offset: 2px; }
.num { font-family: var(--mono); font-variant-numeric: tabular-nums; }
.muted { color: var(--muted); }
.small { font-size: 12px; }
.visually-hidden { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

/* App frame */
.topbar { display: flex; flex-wrap: wrap; align-items: center; gap: 14px; padding: 8px 20px; background: var(--surface); border-bottom: 1px solid var(--border); }
.wordmark { display: inline-flex; align-items: center; gap: 10px; font-weight: 600; font-size: 16px; color: var(--text); text-decoration: none; letter-spacing: -0.01em; }
.crumb-sep { color: #A7ADB8; }
.crumb { display: flex; flex-direction: column; }
.crumb strong { font-weight: 600; }
.spacer { flex: 1; }
.frame { display: flex; flex-wrap: wrap; min-height: calc(100vh - 50px); }
.content { flex: 999 1 560px; min-width: 0; padding: 16px 20px; display: flex; flex-direction: column; gap: 14px; }
.aside { flex: 1 1 300px; max-width: 380px; padding: 16px; background: var(--surface); border-left: 1px solid var(--border); display: flex; flex-direction: column; gap: 16px; }
.page-head { display: flex; flex-wrap: wrap; align-items: flex-end; justify-content: space-between; gap: 12px; }
.page-head h1 { font-size: 21px; font-weight: 600; letter-spacing: -0.02em; }
.page-head p { margin: 4px 0 0; color: var(--muted); }

/* Step navigation */
.steps { flex: 1 1 200px; max-width: 230px; padding: 14px 10px; background: var(--surface); border-right: 1px solid var(--border); }
.steps ol { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 2px; font-size: 13px; }
.step { display: flex; align-items: center; gap: 8px; padding: 6px 8px; border-radius: var(--radius); color: #4A4D55; text-decoration: none; }
a.step:hover { background: var(--bg); color: var(--text); }
.step[aria-current="page"] { background: var(--primary-soft); color: var(--primary-strong); font-weight: 600; }
.step .mark { width: 14px; height: 14px; flex: none; border-radius: var(--radius); border: 2px solid #C1C6CF; }
.step[aria-current="page"] .mark { border-color: var(--primary); background: var(--primary); box-shadow: inset 0 0 0 3px var(--primary-soft); }
.step.planned { color: var(--faint); }
.step.planned .mark { border-style: dashed; }
.step .tag { margin-left: auto; font-size: 11px; color: var(--faint); text-transform: uppercase; letter-spacing: .06em; }

/* Controls */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 32px; padding: 0 12px; border-radius: var(--radius); border: 1px solid var(--border-input); background: var(--surface); color: var(--text); text-decoration: none; font-weight: 500; cursor: pointer; }
.btn:hover { border-color: var(--muted); color: var(--text); }
.btn-primary { background: var(--primary); border-color: var(--primary); color: #FFFFFF; }
.btn-primary:hover { background: var(--primary-strong); border-color: var(--primary-strong); color: #FFFFFF; }
.input { min-height: 30px; padding: 0 8px; border: 1px solid var(--border-input); border-radius: var(--radius); background: var(--surface); }
.input.num { width: 84px; text-align: right; }
.input[aria-invalid="true"] { border-color: var(--error); }
.tabs { display: inline-flex; padding: 2px; background: #E5E7EB; border-radius: var(--radius); }
.tabs a { min-height: 28px; display: inline-flex; align-items: center; padding: 0 10px; border-radius: var(--radius); color: #4A4D55; text-decoration: none; }
.tabs a[aria-current="page"] { background: var(--surface); color: var(--text); font-weight: 500; }
.chip { display: inline-block; padding: 2px 8px; border-radius: var(--radius); font-size: 11px; font-weight: 500; background: var(--primary-soft); color: var(--primary-strong); }

/* Cards and tables */
.card { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius-card); }
.card > h2 { padding: 10px 14px; font-size: 13px; font-weight: 600; border-bottom: 1px solid var(--border); }
.card-foot { padding: 8px 14px; border-top: 1px solid var(--border); font-size: 12px; color: var(--muted); }
.table-wrap { overflow-x: auto; }
table.data { width: 100%; border-collapse: collapse; font-size: 13px; }
/* No uppercase: units like W/(mK) must keep their case. */
table.data th { padding: 6px 12px; text-align: left; font-size: 11px; font-weight: 500; letter-spacing: .02em; color: var(--muted); background: #F8F9FA; }
table.data td { padding: 7px 12px; border-top: 1px solid var(--border-soft); vertical-align: middle; }
table.data .n { text-align: right; font-family: var(--mono); font-variant-numeric: tabular-nums; font-size: 12px; white-space: nowrap; }
table.data th.n { font-family: var(--sans); font-size: 11px; }
table.data tfoot td { border-top: 1px solid var(--border); font-weight: 600; }
table.compact th, table.compact td { padding: 5px 4px; }

.result { display: flex; align-items: baseline; justify-content: space-between; gap: 12px; padding: 10px 14px; background: var(--surface-tint); border: 1px solid var(--primary-soft); border-radius: var(--radius-card); color: var(--primary-strong); }
.result .value { font-family: var(--mono); font-size: 21px; font-weight: 500; }
.result .unit { font-family: var(--sans); font-size: 12px; }
.note { padding: 8px 12px; background: var(--bg); border-radius: var(--radius-card); font-size: 12px; color: var(--text-2); }
.notice { padding: 10px 14px; border-left: 3px solid var(--primary); background: var(--surface); font-size: 13px; }
.errors { padding: 10px 14px; border-left: 3px solid var(--error); background: #FEF3F2; color: var(--error); font-size: 13px; }
.errors ul { margin: 0; padding-left: 18px; }

/* Flash messages float bottom right, so an in-place save is confirmed wherever the page is scrolled. */
.toasts { position: fixed; right: 16px; bottom: 16px; z-index: 60; display: flex; flex-direction: column; gap: 8px; width: min(420px, calc(100vw - 32px)); pointer-events: none; }
.toasts:empty { display: none; }
.toast { margin: 0; pointer-events: auto; border: 1px solid var(--border); box-shadow: 0 6px 20px rgba(22, 24, 29, .12); animation: toast-in .16s ease-out; }
.toasts .errors { display: flex; gap: 10px; align-items: flex-start; justify-content: space-between; }
.toast-close { flex: none; border: 0; background: none; color: inherit; cursor: pointer; padding: 2px; display: inline-flex; }
.toast.notice { border-left: 3px solid var(--primary); }
.toast.errors { border-left: 3px solid var(--error); }
@keyframes toast-in { from { opacity: 0; transform: translateY(6px); } }
@media (prefers-reduced-motion: reduce) { .toast { animation: none; } }

/* Method picker */
fieldset.methods { margin: 0; padding: 10px 14px 12px; display: flex; flex-wrap: wrap; gap: 10px; }
fieldset.methods legend { padding: 0 6px; font-size: 13px; font-weight: 600; }
.method { flex: 1 1 200px; display: flex; gap: 8px; align-items: flex-start; padding: 8px 10px; border: 1px solid var(--border-input); border-radius: var(--radius); cursor: pointer; }
.method:has(input:checked) { border: 2px solid var(--primary); padding: 7px 9px; background: var(--surface-tint); }
.method input { margin-top: 4px; accent-color: var(--primary); }
.method strong { display: block; font-weight: 500; }

/* Plan */
.plan { margin: 0; padding: 12px; display: flex; justify-content: center; }
.plan svg { width: 100%; max-width: 760px; height: auto; }
.legend { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 8px; font-size: 12px; color: var(--text-2); }
.swatch { display: inline-block; width: 12px; height: 4px; margin-right: 8px; vertical-align: middle; }

.section-cut { width: 100%; height: auto; }

@media (max-width: 760px) {
  .content { padding: 16px; }
  .steps, .aside { max-width: none; border: 0; border-bottom: 1px solid var(--border); }
  .topbar { padding: 12px 16px; }
}

/* Forms */
.form { display: flex; flex-direction: column; }
.form fieldset { margin: 0; padding: 12px 14px; border: 0; border-bottom: 1px solid var(--border); display: grid; grid-template-columns: repeat(auto-fill, minmax(190px, 1fr)); gap: 10px 12px; }
.form legend { float: left; width: 100%; grid-column: 1 / -1; padding: 0 0 2px; font-size: 13px; font-weight: 600; }
.form .errors { margin: 16px 16px 0; }
.form fieldset > .table-wrap { clear: both; } /* a scroll box would otherwise sit beside the floated legend at 0 px */
.field { display: flex; flex-direction: column; gap: 3px; min-width: 0; }
.field label, .label { font-size: 12px; color: var(--text-2); }
.field .input { width: 100%; min-height: 32px; }
.wide { grid-column: 1 / -1; }
textarea.input { padding: 8px; min-height: 80px; resize: vertical; }
select.input { padding-right: 24px; }
.form-actions { display: flex; flex-wrap: wrap; gap: 8px; padding: 12px 14px; }
.inline-form { display: flex; flex-wrap: wrap; align-items: flex-end; gap: 8px; }
.card-body.inline-form { flex-direction: row; } /* a card-body column would turn the fields' flex-basis into height */
.inline-form .field .input { min-height: 30px; }
.inline-form .field.xs { width: 84px; }
.inline-form .field.sm { width: 120px; }
.inline-form .field.md { width: 180px; }
.btn-sm { min-height: 28px; padding: 0 9px; font-size: 12px; }
.btn-link { border: 0; background: none; padding: 0; color: var(--primary); cursor: pointer; font: inherit; text-decoration: underline; }
.btn-danger { color: var(--error); }
.btn-danger:hover { border-color: var(--error); color: var(--error); }
details.add > summary { cursor: pointer; color: var(--primary); font-weight: 500; font-size: 13px; list-style: none; }
details.add > summary::-webkit-details-marker { display: none; }
details.add > summary::before { content: "+"; font-weight: 600; }
details.add[open] > summary { margin-bottom: 10px; }
details.add > summary { display: inline-flex; align-items: center; gap: 4px; min-height: 28px; padding: 0 9px; border: 1px dashed var(--border-input); border-radius: var(--radius); font-size: 12px; }
details.add > summary:hover, details.add > summary:focus-visible { border-color: var(--primary); border-style: solid; }
details.add[open] > summary { border-style: solid; background: var(--surface-tint); }

/* Edit toggles: icon summary; the editor opens below. In .edit-cell the icon sits top right of the item. */
details.edit > summary { list-style: none; }
details.edit > summary::-webkit-details-marker { display: none; }
details.edit[open] > summary.icon-btn { border-color: var(--primary); color: var(--primary); background: var(--surface-tint); }
.edit-cell { position: relative; padding-right: 34px; }
.edit-cell > details.edit > summary.icon-btn { position: absolute; top: 0; right: 0; }
.edit-cell > details.edit[open] { margin-top: 8px; padding: 10px; border: 1px solid var(--primary); border-radius: var(--radius-card); background: var(--surface-tint); }
td .edit-cell > details.edit > summary.icon-btn { top: -6px; }
.chip-editors { display: flex; flex-direction: column; align-items: flex-start; gap: 6px; }
.chip-edit > summary.opening-chip { cursor: pointer; }
.chip-edit[open] { align-self: stretch; padding: 10px; border: 1px solid var(--primary); border-radius: var(--radius-card); background: var(--surface-tint); }
.chip-edit[open] > summary.opening-chip { border-color: var(--primary); background: var(--surface); }
.form-tools { display: flex; gap: 6px; justify-content: flex-end; }
.icon-form { display: inline-flex; margin: 0; }
.row-actions { display: flex; gap: 12px; justify-content: flex-end; }
.wall-openings { margin: 6px 0 0; padding: 0; list-style: none; display: flex; flex-direction: column; gap: 6px; }
.wall-openings li { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; font-size: 12px; }
.warn { color: var(--warn-text); background: var(--warn-bg); border: 1px solid var(--warn-border); padding: 2px 6px; border-radius: var(--radius); font-size: 11px; }
table.points td { padding: 4px 6px 4px 0; border: 0; }
table.points .input { width: 100px; text-align: right; font-family: var(--mono); }
.card-body { padding: 12px 14px; display: flex; flex-direction: column; gap: 10px; }

/* Icon buttons with tooltip */
.icon-btn { position: relative; display: inline-flex; align-items: center; justify-content: center; width: 28px; height: 28px; flex: none;
  border: 1px solid var(--border); border-radius: var(--radius); background: var(--surface); color: var(--text-2); text-decoration: none; cursor: pointer; padding: 0; }
.icon-btn:hover, .icon-btn:focus-visible { border-color: var(--primary); color: var(--primary); }
.icon-btn.danger:hover, .icon-btn.danger:focus-visible { border-color: var(--error); color: var(--error); }
.icon-btn[data-tip]:hover::after, .icon-btn[data-tip]:focus-visible::after {
  content: attr(data-tip); position: absolute; bottom: calc(100% + 6px); right: 0; z-index: 5; white-space: nowrap;
  background: var(--text); color: #fff; font-size: 11px; line-height: 1.3; padding: 3px 6px; border-radius: var(--radius); pointer-events: none; }

/* Walls as compact rows */
.wall-list .wall-row { display: grid; grid-template-columns: 28px minmax(0, 1fr) 96px minmax(150px, 210px) auto; gap: 10px; padding: 8px 14px;
  border-top: 1px solid var(--border-soft); align-items: start; }
.wall-list .wall-head { background: #F8F9FA; border-top: 0; padding-top: 6px; padding-bottom: 6px; font-size: 11px; color: var(--muted); }
.wall-row .n { text-align: right; font-family: var(--mono); font-size: 12px; }
.wall-row .picks { display: flex; flex-direction: column; gap: 6px; }
.wall-row .picks .input { min-height: 28px; font-size: 12px; width: 100%; }
.wall-row .actions { display: flex; gap: 6px; justify-content: flex-end; }
.opening-chips { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 8px; }
.opening-chip { display: inline-flex; align-items: center; gap: 6px; padding: 3px 8px; border: 1px solid var(--border); border-radius: var(--radius);
  background: #F8F9FA; font-size: 11px; color: var(--text); text-decoration: none; }
.opening-chip:hover, .opening-chip:focus-visible { border-color: var(--primary); color: var(--text); }
.opening-chip .num { font-size: 11px; }
.opening-chip { white-space: nowrap; }
.wall-row .dims { line-height: 1.5; }
.opening-chip.bad { border-color: var(--warn-border); background: var(--warn-bg); }
turbo-frame.wall-editor { display: block; }
.wall-editor:not(:empty) { margin: 0 16px 12px 60px; padding: 12px; border: 1px solid var(--primary); border-radius: var(--radius-card); background: var(--surface-tint); }
.wall-editor .inline-form .field .input { background: var(--surface); }
@media (max-width: 900px) {
  .wall-list .wall-row { grid-template-columns: 28px minmax(0, 1fr) auto; }
  .wall-list .wall-row .n:not(:first-child), .wall-list .wall-head { display: none; }
  .wall-row .picks { grid-column: 2 / -1; }
  .wall-row .actions { grid-column: 3; grid-row: 1; }
  .wall-editor:not(:empty) { margin-left: 16px; }
}

/* Dense desktop type; touch devices keep 16px in fields so iOS does not zoom in on focus. */
@media (pointer: coarse) { input, select, textarea { font-size: 16px !important; } }

/* Editor rows under table rows: hidden until their details opens. */
tr.editor-row:has(> td > details:not([open])) { display: none; }
tr.editor-row > td { padding: 0 12px 10px; border-top: 0; }
tr.editor-row details[open] { padding: 10px; border: 1px solid var(--primary); border-radius: var(--radius-card); background: var(--surface-tint); }
.icon-btn-inline { width: 24px; height: 24px; margin-right: 6px; vertical-align: middle; }
.icon-btn[aria-expanded="true"] { border-color: var(--primary); color: var(--primary); background: var(--surface-tint); }
.icon-btn-inline[data-tip]:hover::after, .icon-btn-inline[data-tip]:focus-visible::after { right: auto; bottom: auto; left: calc(100% + 6px); top: 50%; transform: translateY(-50%); }

/* Envelope gap (e.g. missing roof): blocks results, so it is shown on every page that depends on it. */
.gap-banner { padding: 8px 12px; border: 1px solid var(--warn-border); border-left: 3px solid #B54708; background: var(--warn-bg); color: var(--warn-text); border-radius: var(--radius); }
.gap-banner p { margin: 0; }
.gap-banner a { margin-left: 6px; }

.copy-line { display: block; padding: 6px 8px; background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); font-size: 12px; overflow-wrap: anywhere; user-select: all; }

/* Results sidebar */
.results { display: flex; flex-direction: column; gap: 8px; padding-bottom: 14px; border-bottom: 1px solid var(--border-soft); }
.results-head { display: flex; align-items: center; justify-content: space-between; gap: 8px; }
.results-head h2 { margin: 0; font-size: 14px; font-weight: 600; }
.results-head label { display: flex; align-items: center; gap: 6px; font-size: 11px; color: var(--muted); }
.results-head select { min-height: 26px; max-width: 170px; padding: 0 4px; font-size: 12px; }
.rcard { display: flex; flex-direction: column; gap: 5px; padding: 9px 10px; border: 1px solid var(--border); border-radius: var(--radius-card); color: inherit; text-decoration: none; background: var(--surface); }
a.rcard:hover { border-color: var(--primary); color: inherit; }
.rcard-top { display: flex; justify-content: space-between; align-items: baseline; gap: 8px; }
.rcard-title { font-weight: 600; }
.rcard-title small { font-weight: 400; font-size: 11px; color: var(--muted); }
.rcard-value { display: flex; align-items: baseline; gap: 8px; flex-wrap: wrap; }
.rcard-value .big { font-family: var(--mono); font-size: 20px; font-weight: 500; }
.rcard-sub { font-size: 11px; color: var(--muted); }
.status { display: inline-flex; align-items: center; gap: 5px; font-size: 11px; white-space: nowrap; }
.status.bad { color: #9A3412; }
.status.open { color: var(--warn-text); }
.status.ok { color: #0F6E63; }
.rcard dl { margin: 0; display: grid; grid-template-columns: 1fr auto 1fr auto; gap: 2px 10px; font-size: 12px; }
.rcard dt { color: var(--muted); }
.rcard dd { margin: 0; font-family: var(--mono); text-align: right; }
.rcard.open-items { border-color: var(--warn-border); background: var(--warn-bg); }
.rcard.open-items h3 { margin: 0; font-size: 13px; font-weight: 600; color: var(--warn-text); }
.rcard.open-items a { font-size: 12px; }
.rcard.not-calculated { border-style: dashed; border-color: var(--border-input); color: var(--muted); }
.rcard.not-calculated strong { color: var(--text-2); }
.bars { display: grid; grid-template-columns: 86px 1fr 58px; gap: 4px 6px; align-items: center; font-size: 11px; }
.bars .bar { height: 8px; background: var(--border-soft); position: relative; }
.bars .bar span { position: absolute; inset: 0 auto 0 0; }
.bars .n { font-family: var(--mono); text-align: right; }

/* Public pages (product, about, contact): same quiet system, more room to read. */
.site-nav { display: flex; flex-wrap: wrap; align-items: center; gap: 4px 16px; font-size: 13px; }
.site-nav a:not(.btn) { color: var(--text-2); text-decoration: none; }
.site-nav a:not(.btn):hover, .site-nav a[aria-current="page"] { color: var(--primary); }
.site { max-width: 1040px; margin: 0 auto; padding: 0 20px 48px; display: flex; flex-direction: column; gap: 48px; font-size: 14px; line-height: 1.6; }
.site p { margin: 0; }
.site-hero { padding-top: 64px; display: flex; flex-direction: column; gap: 16px; max-width: 760px; }
.site-hero h1 { font-size: 34px; font-weight: 600; letter-spacing: -0.025em; line-height: 1.15; }
.site-hero .lead { font-size: 17px; color: var(--text-2); }
.site-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 10px 16px; padding-top: 4px; }
.site-actions .btn { min-height: 38px; padding: 0 16px; }
.eyebrow { font-family: var(--mono); font-size: 11px; font-weight: 500; letter-spacing: .08em; text-transform: uppercase; color: var(--primary); }
.site-section { display: flex; flex-direction: column; gap: 16px; }
.site-section > header { display: flex; flex-direction: column; gap: 6px; max-width: 680px; }
.site-section h2 { font-size: 21px; font-weight: 600; letter-spacing: -0.02em; }
.site-section > header p { color: var(--muted); }
.site-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: 12px; }
.site-card { padding: 16px 18px; display: flex; flex-direction: column; gap: 6px; }
.site-card h3 { font-size: 14px; font-weight: 600; display: flex; align-items: center; gap: 8px; }
.site-card p { color: var(--text-2); font-size: 13px; }
.site-card .mark { width: 12px; height: 12px; flex: none; border-radius: var(--radius); border: 2px solid var(--primary); background: var(--primary); box-shadow: inset 0 0 0 2px var(--surface); }
.site-card.planned { background: transparent; border-style: dashed; }
.site-card.planned .mark { border: 2px dashed #A7ADB8; background: none; box-shadow: none; }
.site-band { padding: 20px 22px; display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 12px 24px; background: var(--surface-tint); border: 1px solid var(--primary-soft); border-radius: var(--radius-card); }
.site-band p { color: var(--text-2); max-width: 640px; }
.site-facts { margin: 0; display: grid; grid-template-columns: max-content 1fr; gap: 6px 20px; font-size: 13px; }
.site-facts dt { color: var(--muted); }
.site-facts dd { margin: 0; }
.person { padding: 18px; display: flex; flex-direction: column; gap: 8px; }
.person h3 { font-size: 16px; font-weight: 600; }
.person .role { color: var(--primary-strong); font-weight: 500; font-size: 13px; }
.person p { color: var(--text-2); font-size: 13px; }
@media (max-width: 760px) {
  .site { padding: 0 16px 32px; gap: 36px; }
  .site-hero { padding-top: 36px; }
  .site-hero h1 { font-size: 26px; }
  .site-hero .lead { font-size: 15px; }
}

/* Public pages: articles, comparisons, questions, sitemap */
.site .h3, .site-card h2.h3 { font-size: 14px; font-weight: 600; display: flex; align-items: center; gap: 8px; }
.site-card h2.h3 a, .site-card h3 a { color: var(--text); text-decoration: none; }
.site-card h2.h3 a:hover, .site-card h3 a:hover { color: var(--primary); }
.crumbs { color: var(--muted); }
.crumbs a { color: var(--muted); text-decoration: none; }
.crumbs a:hover { color: var(--primary); }
.prose { max-width: 720px; display: flex; flex-direction: column; gap: 28px; }
.prose-section { display: flex; flex-direction: column; gap: 10px; scroll-margin-top: 16px; }
.prose-section h2 { font-size: 19px; font-weight: 600; letter-spacing: -0.015em; }
.prose-section ul, .prose-list { margin: 0; padding-left: 20px; display: flex; flex-direction: column; gap: 6px; }
.toc { padding: 12px 16px; display: flex; flex-direction: column; gap: 6px; }
.toc ol { margin: 0; padding-left: 18px; display: flex; flex-direction: column; gap: 3px; }
.faq { display: flex; flex-direction: column; gap: 8px; max-width: 760px; }
.faq details { padding: 0; }
.faq summary { padding: 12px 16px; font-weight: 500; cursor: pointer; }
.faq details p { padding: 0 16px 14px; color: var(--text-2); font-size: 13px; }
.sources ol { margin: 0; padding-left: 20px; display: flex; flex-direction: column; gap: 4px; }
.sources h2 { font-size: 15px; }
.site-table th[scope="row"] { font-size: 12px; font-weight: 500; color: var(--text-2); background: none; width: 22%; }
.site-table td, .site-table th[scope="row"] { vertical-align: top; }
.site-two { display: grid; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); gap: 12px; }
.site-two ul { margin: 0; padding-left: 18px; display: flex; flex-direction: column; gap: 4px; font-size: 13px; color: var(--text-2); }
.link-list { margin: 0; padding-left: 18px; display: flex; flex-direction: column; gap: 4px; }
.link-list.inline { padding: 0; list-style: none; flex-direction: row; flex-wrap: wrap; gap: 6px 16px; }
.glossary { margin: 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: 12px; }
.glossary dd { margin: 0; color: var(--text-2); font-size: 13px; }
.site-map { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 24px; }
.site-map h2 { font-size: 14px; font-weight: 600; margin-bottom: 6px; }
.site-map ul { margin: 0; padding-left: 16px; display: flex; flex-direction: column; gap: 3px; font-size: 13px; }
.site-footer { padding: 32px 20px 24px; border-top: 1px solid var(--border); background: var(--surface); font-size: 12px; }
.site-footer .cols { max-width: 1040px; margin: 0 auto; display: grid; grid-template-columns: repeat(auto-fill, minmax(170px, 1fr)); gap: 20px; }
.site-footer h2 { font-size: 12px; font-weight: 600; margin-bottom: 6px; }
.site-footer ul { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 4px; }
.site-footer a { color: var(--muted); text-decoration: none; }
.site-footer a:hover { color: var(--primary); }
.site-footer .legal { max-width: 1040px; margin: 20px auto 0; color: var(--faint); }
.person .avatar { width: 96px; height: 96px; border-radius: var(--radius-card); object-fit: cover; background: var(--surface-tint); }
.person .avatar.initials { display: flex; align-items: center; justify-content: center; font-family: var(--mono); font-size: 24px; font-weight: 500; color: var(--primary-strong); border: 1px solid var(--primary-soft); }

/* Documentation: chapter list on the left, screenshots that open full size. */
.doc-layout { display: grid; grid-template-columns: 200px minmax(0, 1fr); gap: 32px; align-items: start; }
.doc-layout .prose { max-width: 820px; }
.doc-toc { position: sticky; top: 16px; font-size: 13px; }
.doc-toc ol { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 2px; }
.doc-toc a { display: block; padding: 5px 10px; border-radius: var(--radius); color: var(--text-2); text-decoration: none; }
.doc-toc a:hover { color: var(--primary); }
.doc-toc a[aria-current="page"] { background: var(--primary-soft); color: var(--primary-strong); font-weight: 600; }
.shot { margin: 6px 0 0; display: flex; flex-direction: column; gap: 6px; }
.shot img { display: block; width: 100%; height: auto; border: 1px solid var(--border); border-radius: var(--radius-card); background: var(--surface); }
.shot a:hover img { border-color: var(--primary); }
.shot figcaption { font-size: 12px; color: var(--muted); }
.doc-pager { display: flex; justify-content: space-between; gap: 12px; padding-top: 12px; border-top: 1px solid var(--border-soft); }
.doc-index { list-style: none; margin: 0; padding: 0; }
.doc-thumb img { display: block; width: 100%; aspect-ratio: 16 / 10; object-fit: cover; object-position: top left; border: 1px solid var(--border-soft); border-radius: var(--radius); }
.doc-index .num { color: var(--muted); font-family: var(--mono); font-weight: 500; }
@media (max-width: 760px) {
  .doc-layout { grid-template-columns: 1fr; }
  .doc-toc { position: static; }
  .doc-toc ol { flex-direction: row; flex-wrap: wrap; }
}
