/* Shade Plans. Off-white paper, warm black ink, serif titles in capitals,
 * small monospace capitals in pill controls. The wood carries the colour.
 * Style source: 06-Systems/design-inspiration/apartment-birds-style.md
 * The earlier look (ivory paper, green ink, Georgia) is in studio-ivory.css. */
:root {
  --paper: #fcfcfb;
  --paper-2: #f3f2ee;
  --paper-3: #e8e6df;
  --panel: #fcfcfb;
  --ink: #1a1612;
  --ink-2: #4a3f31;
  --muted: #908576;
  --line: rgba(26, 22, 18, 0.14);
  --accent: #4a3f31;
  --soft: #f3f2ee;
  --focus: #1a1612;
  --warn: #1a1612;
  --warn-soft: #e8e6df;
  --stop: #9b3f37;
  --stop-soft: #f4e6e3;
  --radius: 2px;
  /* depth without drop shadows: a light inner edge and a dark outer ring */
  --edge: inset 0 0 0 1px rgba(255, 255, 255, 0.55), 0 0 0 1px rgba(26, 22, 18, 0.04);
  --edge-lg: inset 0 0 0 1px rgba(255, 255, 255, 0.6), 0 0 0 1px rgba(26, 22, 18, 0.06), 0 8px 28px rgba(26, 22, 18, 0.06);
  --raised: inset 0 0 0 1px rgba(255, 255, 255, 0.8), 0 0 0 1px rgba(26, 22, 18, 0.05), 0 1px 2px rgba(26, 22, 18, 0.07);
  --recess: inset 0 1px 2px rgba(26, 22, 18, 0.06), inset 0 0 0 1px rgba(26, 22, 18, 0.04);
  --serif: ui-serif, "Iowan Old Style", "Bookman Old Style", Georgia, serif;
  --mono: ui-monospace, "SF Mono", Menlo, monospace;
  --sans: -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  /* the small label of every control: monospace capitals with wide spacing */
  --label: 10px/1 var(--mono);
  --track: .18em;
  font-family: var(--serif);
  color: var(--ink);
  background: var(--paper);
  font-synthesis: none;
}
* { box-sizing: border-box; }
body { margin: 0; }
button, input, select { font: inherit; color: inherit; }
button, a, input, select { -webkit-tap-highlight-color: transparent; }
button { cursor: pointer; }
button:disabled { opacity: .45; cursor: default; }
button:focus-visible, a:focus-visible, select:focus-visible, input:focus-visible,
canvas:focus-visible, summary:focus-visible { outline: 2px solid var(--focus); outline-offset: 3px; }
[hidden] { display: none !important; }
.sr-only { position: absolute; width: 1px; height: 1px; margin: -1px; overflow: hidden; clip-path: inset(50%); }

/* ---------- masthead ---------- */
.masthead {
  height: 64px; padding: 0 24px; display: flex; align-items: center; gap: 28px;
  background: var(--panel); border-bottom: 1px solid var(--line);
}
/* brand: a ring of staves from above, and the name in serif capitals */
.brand { display: flex; align-items: center; gap: 12px; text-decoration: none; color: var(--ink); white-space: nowrap; }
.brand-mark { width: 34px; height: 34px; display: block; }
.brand-mark .ring { fill: var(--ink); }
.brand-mark .hole { fill: var(--panel); }
.brand-mark .joints { stroke: var(--panel); stroke-width: .9; }
.brand-mark .bulb { fill: #e3a54a; }
.brand-name { font: 700 22px/1 var(--serif); letter-spacing: .16em; text-transform: uppercase; }
.brand-name em { font-style: italic; font-weight: 400; letter-spacing: .08em; text-transform: none; font-size: 24px; margin-left: .1em; }
.masthead-actions { margin-left: auto; display: flex; align-items: center; gap: 14px; flex-shrink: 0; }
.save-status { font: var(--label); letter-spacing: .12em; text-transform: uppercase; color: var(--muted); }
.save-status button { border: 0; background: none; padding: 0; color: var(--ink-2); text-decoration: underline; font: inherit; letter-spacing: inherit; text-transform: inherit; }
.quiet { border: 0; background: none; font: var(--label); letter-spacing: var(--track); text-transform: uppercase; color: var(--muted); height: 30px; padding: 0 4px; }
.check-chip {
  min-height: 32px; padding: 0 16px 0 14px; border-radius: 999px; font: var(--label); letter-spacing: .14em; text-transform: uppercase;
  border: 0; background: var(--paper-2); box-shadow: var(--recess); color: var(--ink-2); white-space: nowrap;
}
.check-chip::before { content: "✓"; margin-right: 8px; }
.check-chip[data-level=warn] { background: var(--warn-soft); color: var(--warn); }
.check-chip[data-level=warn]::before { content: "!"; font-weight: 700; }
.check-chip[data-level=stop] { background: var(--stop-soft); color: var(--stop); }
.check-chip[data-level=stop]::before { content: "✕"; }

/* ---------- workspace ---------- */
.workspace { display: grid; grid-template-columns: minmax(0, 1fr) 372px; height: calc(100dvh - 64px); min-height: 560px; }
.preview { min-width: 0; min-height: 0; display: grid; grid-template-rows: minmax(0, 1fr); }

.stage { position: relative; min-width: 0; min-height: 0; overflow: hidden; transition: background-color .35s; }
.stage.lit { background: #1a1612; }
#view { width: 100%; height: 100%; display: block; touch-action: none; cursor: grab; }
#view:active { cursor: grabbing; }

/* a recessed track, with a raised pill for the selected choice */
.stage-controls { position: absolute; top: 16px; left: 16px; display: flex; gap: 8px; align-items: center; }
/* both controls are 30 px high */
.view-switch {
  display: flex; padding: 3px; height: 30px;
  background: var(--paper-2); box-shadow: var(--recess); border-radius: 999px; white-space: nowrap;
}
.view-switch button { height: 24px; padding: 0 12px; border: 0; background: none; color: var(--muted); border-radius: 999px; font: var(--label); letter-spacing: var(--track); text-transform: uppercase; }
.view-switch button[aria-pressed=true] { background: var(--paper); box-shadow: var(--raised); color: var(--ink); }

/* every stage pill is 30 px high, 16 px in from the corner (2026-11-30 polish) */
.view-actions { position: absolute; bottom: 16px; right: 16px; display: flex; gap: 8px; align-items: center; }
.view-actions > button, .zoom {
  min-height: 30px; background: var(--paper); border: 0; box-shadow: var(--raised); border-radius: 999px;
  font: var(--label); letter-spacing: var(--track); text-transform: uppercase; color: var(--muted);
}
.view-actions > button { padding: 0 16px; }
/* lower left: feedback, the same pill as the view buttons */
.stage-corner { position: absolute; bottom: 16px; left: 16px; }
.feedback-open {
  min-height: 30px; padding: 0 16px; background: var(--paper); border: 0; box-shadow: var(--raised); border-radius: 999px;
  font: var(--label); letter-spacing: var(--track); text-transform: uppercase; color: var(--muted);
}
.feedback-open[aria-expanded=true] { background: var(--ink-2); color: var(--paper); box-shadow: none; }
.view-actions > button[aria-pressed=true] { background: var(--ink-2); color: var(--paper); box-shadow: none; }
.zoom { display: flex; align-items: center; padding: 0 3px; }
.zoom button { width: 24px; height: 24px; border: 0; border-radius: 50%; background: none; font: 16px/1 var(--mono); color: var(--ink); }
.zoom output { min-width: 46px; text-align: center; font-variant-numeric: tabular-nums; }

/* lamp switch */
.lamp-switch {
  height: 30px; padding: 0 12px 0 4px; display: flex; align-items: center; gap: 8px;
  background: var(--paper); border: 0; box-shadow: var(--raised); border-radius: 999px;
  font: var(--label); letter-spacing: var(--track); text-transform: uppercase; color: var(--muted); white-space: nowrap;
}
.lamp-knob { width: 34px; height: 22px; border-radius: 11px; background: var(--paper-2); box-shadow: var(--recess); position: relative; transition: background-color .2s; }
.lamp-knob::after {
  content: ""; position: absolute; top: 3px; left: 3px; width: 16px; height: 16px; border-radius: 50%;
  background: var(--paper); box-shadow: var(--raised); transition: transform .2s, background-color .2s;
}
.lamp-switch[aria-checked=true] { color: var(--ink); }
.lamp-switch[aria-checked=true] .lamp-knob { background: var(--ink-2); }
.lamp-switch[aria-checked=true] .lamp-knob::after { transform: translateX(12px); background: var(--paper); }

/* drag handles on the shade */
.handles { position: absolute; inset: 0; pointer-events: none; }
.handle {
  position: absolute; left: 0; top: 0; width: 36px; height: 36px; margin: -18px 0 0 -18px; padding: 0;
  border: 0; background: none; pointer-events: auto; touch-action: none; cursor: ew-resize;
}
.handle[data-key=height] { cursor: ns-resize; }
.handle .dot {
  position: absolute; left: 11px; top: 11px; width: 14px; height: 14px; border-radius: 50%;
  background: var(--ink); border: 2.5px solid var(--paper); box-shadow: 0 0 0 1px rgba(26, 22, 18, 0.22);
  transition: transform .12s;
}
.handle:hover .dot, .handle.active .dot, .handle:focus-visible .dot { transform: scale(1.3); }
.handle:focus-visible { outline: none; }
.handle:focus-visible .dot { outline: 2px solid var(--focus); outline-offset: 2px; }
.handle .tag {
  position: absolute; top: 8px; left: 34px; padding: 5px 10px; border-radius: 999px; white-space: nowrap;
  font: var(--label); letter-spacing: .1em; text-transform: uppercase; font-variant-numeric: tabular-nums;
  background: var(--paper); color: var(--ink); box-shadow: var(--raised);
}
.handle[data-side=left] .tag { left: auto; right: 34px; }
.handle.active .tag { background: var(--ink); color: var(--paper); box-shadow: none; }

/* ---------- editor ---------- */
.editor { min-width: 0; background: var(--panel); border-left: 1px solid var(--line); display: flex; flex-direction: column; overflow: hidden; }
.editor-scroll { overflow-y: auto; padding: 14px 24px 34px; scrollbar-gutter: stable; min-height: 0; }

/* steps: a numbered dot for each step, on one vertical line */
.steps { list-style: none; margin: 0; padding: 0; }
.step { position: relative; padding-left: 38px; }
/* no line between the step numbers (Dan, 2026-11-28) */
.step-head {
  display: flex; align-items: baseline; gap: 12px; width: 100%; min-height: 50px; padding: 16px 0 12px; border: 0; background: none;
  font: var(--label); letter-spacing: var(--track); text-transform: uppercase; color: var(--ink); text-align: left;
}
/* no hover filter: a filter makes the heading the frame of the dot and moves it */
.step-head:hover { filter: none !important; color: var(--ink-2); }
.step-head .dot {
  /* top: the digit on the baseline of the step name (Dan, 2026-11-28) */
  position: absolute; left: 0; top: 9.5px; width: 23px; height: 23px; border-radius: 50%; display: grid; place-items: center;
  font: 10px/1 var(--mono); letter-spacing: 0; background: var(--paper); box-shadow: 0 0 0 1px var(--line); color: var(--muted);
}
.step-name { font-weight: 700; }
.step-sum { margin-left: auto; color: var(--muted); letter-spacing: .08em; text-align: right; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; min-width: 0; }
.step[data-state=open] .dot, .step[data-state=done] .dot { background: var(--ink); color: var(--paper); box-shadow: none; }
.step[data-state=open] .step-sum { display: none; }
.step[data-state=locked] .step-head { color: var(--muted); cursor: default; }
.step[data-state=locked] .step-name { font-weight: 400; }
.step-body { padding: 6px 0 8px; }

/* one title for each step: a serif in bold capitals, with an italic line under it */
h2 { font: 700 23px/1.12 var(--serif); letter-spacing: .06em; text-transform: uppercase; margin: 0 0 10px; }
h3 { font: 700 17px/1.2 var(--serif); letter-spacing: .06em; text-transform: uppercase; margin: 0 0 10px; }
.pdf-block p { font-size: 14px; color: var(--ink-2); line-height: 1.55; margin: 0; }

fieldset { border: 0; padding: 0; margin: 0 0 28px; min-width: 0; }
legend { font: 700 10px/1.2 var(--mono); letter-spacing: var(--track); text-transform: uppercase; width: 100%; margin-bottom: 13px; padding: 0; }
legend span { float: right; font-weight: 400; letter-spacing: .06em; text-transform: none; color: var(--muted); }
.field-help { font-size: 13px; color: var(--ink-2); line-height: 1.5; margin: 9px 0 0; }
/* a control stopped at a limit, or an option is off: the cause */
.limit-note { color: var(--ink); font-weight: 600; border-left: 2px solid var(--accent); padding-left: 10px; }
.chips button:disabled, select option:disabled { opacity: .38; cursor: not-allowed; }
.check { display: flex; align-items: center; gap: 9px; font-size: 15px; margin: 2px 0 10px; cursor: pointer; }
.check input { width: 16px; height: 16px; accent-color: var(--accent); margin: 0; }
#tierControls { margin-top: 12px; }
#tierControls .field { margin: 14px 0 12px; }
#decorTiers { margin-bottom: 18px; }
.tier-tabs[data-stack-only] { margin-bottom: 12px; }
#plateMat { margin-top: 4px; }

.field { margin: 14px 0; }
.field-head { display: flex; justify-content: space-between; gap: 8px; align-items: center; min-height: 32px; }
.field-head label, .field-head > span:first-child { font-size: 15px; }
/* a long reading goes on its own line, under its label */
.field-head.stacked { flex-direction: column; align-items: flex-start; gap: 6px; padding: 4px 0; }
.field-head output { font: 11px/1 var(--mono); letter-spacing: .04em; font-variant-numeric: tabular-nums; white-space: nowrap; }
.field input[type=range] { width: 100%; height: 28px; display: block; accent-color: var(--accent); cursor: pointer; margin: 2px 0 0; }

.num { display: flex; align-items: center; border: 0; border-radius: var(--radius); background: var(--paper-2); box-shadow: var(--recess); padding-right: 9px; }
.num:focus-within { box-shadow: var(--recess), 0 0 0 1px var(--ink-2); }
.num input {
  width: 68px; height: 30px; border: 0; background: none; padding: 0 5px 0 9px; text-align: right;
  font: 12px/1 var(--mono); font-variant-numeric: tabular-nums; outline: none; -moz-appearance: textfield;
}
.num input::-webkit-outer-spin-button, .num input::-webkit-inner-spin-button { -webkit-appearance: none; margin: 0; }
.num i { font: normal 10px/1 var(--mono); letter-spacing: .08em; text-transform: uppercase; color: var(--muted); }

.stepper { display: flex; align-items: center; gap: 4px; }
.stepper button { width: 32px; height: 32px; border: 0; border-radius: 50%; background: var(--paper); box-shadow: var(--raised); font: 16px/1 var(--mono); color: var(--ink); }
.stepper output { min-width: 40px; text-align: center; font: 15px/1 var(--mono) !important; letter-spacing: 0 !important; }

.select-label { font: 700 10px/1.2 var(--mono); letter-spacing: var(--track); text-transform: uppercase; display: block; margin: 18px 0 9px; }
select { width: 100%; min-height: 40px; background: var(--paper-2); border: 0; box-shadow: var(--recess); border-radius: var(--radius); padding: 0 12px; font-size: 15px; }
.segmented { display: flex; padding: 4px; background: var(--paper-2); box-shadow: var(--recess); border-radius: 999px; border: 0; }
.segmented button { flex: 1; min-height: 32px; border: 0; background: transparent; color: var(--muted); border-radius: 999px; font: var(--label); letter-spacing: .14em; text-transform: uppercase; }
.segmented button:disabled { opacity: .38; cursor: not-allowed; }
.check:has(input:disabled) { opacity: .5; cursor: not-allowed; }
.segmented button[aria-pressed=true] { background: var(--paper); box-shadow: var(--raised); color: var(--ink); }

.swatches { display: grid; grid-template-columns: repeat(4, 1fr); gap: 8px; }
.swatches button {
  border: 0; border-radius: var(--radius); background: var(--paper); box-shadow: var(--raised); padding: 5px 4px 7px;
  font: italic 13px/1.2 var(--serif); color: var(--ink-2); display: grid; gap: 6px; justify-items: center;
}
.swatches button i { width: 100%; height: 34px; border-radius: 1px; display: block; }
.swatches button[aria-checked=true] { color: var(--ink); box-shadow: 0 0 0 1.5px var(--ink); }
.chips { display: flex; gap: 6px; margin: 6px 0 4px; }
.chips button {
  flex: 1; min-height: 32px; border: 0; border-radius: 999px; background: var(--paper); box-shadow: var(--raised);
  font: 11px/1 var(--mono); letter-spacing: .04em; color: var(--muted); font-variant-numeric: tabular-nums;
}
.chips button[aria-pressed=true] { background: var(--ink-2); color: var(--paper); box-shadow: none; }

.next-section {
  display: flex; justify-content: space-between; align-items: center; width: 100%; min-height: 44px;
  background: var(--ink); border: 0; border-radius: 999px; color: var(--paper);
  font: var(--label); letter-spacing: var(--track); text-transform: uppercase; padding: 0 20px; margin: 4px 0 18px;
}
.next-section span { font: var(--label); letter-spacing: 0; }

/* ---------- build ---------- */
.checks { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; }
.checks li { display: grid; grid-template-columns: 22px 1fr; gap: 10px; padding: 12px 13px; border-radius: var(--radius); background: var(--paper-2); }
.checks li::before {
  content: "✓"; width: 20px; height: 20px; border-radius: 50%; display: grid; place-items: center;
  font: 700 10px/1 var(--mono); background: var(--paper); box-shadow: var(--raised); color: var(--ink-2); margin-top: 1px;
}
.checks li[data-level=warn] { background: var(--warn-soft); }
.checks li[data-level=warn]::before { content: "!"; background: var(--ink); color: var(--paper); box-shadow: none; }
.checks li[data-level=info]::before { content: "i"; font: italic 12px/1 var(--serif); }
.checks li[data-level=stop] { background: var(--stop-soft); }
.checks li[data-level=stop]::before { content: "✕"; background: var(--stop); color: #fff; box-shadow: none; }
.checks strong { display: block; font-size: 15px; font-weight: 600; }
.checks p { margin: 3px 0 0; font-size: 13.5px; line-height: 1.45; color: var(--ink-2); }

.cut-summary { margin: 0; display: grid; grid-template-columns: 96px 1fr; font-size: 14px; }
.cut-summary dt, .cut-summary dd { margin: 0; padding: 9px 0; border-bottom: 1px solid var(--line); line-height: 1.45; }
.cut-summary dt { font: 10px/2 var(--mono); letter-spacing: .12em; text-transform: uppercase; color: var(--muted); }
.cut-summary dd { font-variant-numeric: tabular-nums; }
.cut-summary dd small { display: block; font-size: 12.5px; color: var(--ink-2); margin-top: 2px; }

.pdf-block { padding: 22px; background: var(--paper-2); box-shadow: var(--recess); border-radius: var(--radius); margin: 0 0 22px; }
.pdf-block a { font: var(--label); letter-spacing: .12em; text-transform: uppercase; line-height: 1.8; color: var(--ink-2); }
.pdf-block #planPreview { margin-top: 14px; }
.pdf-block .plan-offer { margin-bottom: 14px; }
.pdf-block .plan-offer:empty { display: none; }
.pdf-block #planText { margin-bottom: 6px; }
.pdf-blocked { margin-top: 12px !important; color: var(--stop) !important; }
/* the subhead and the support line use the label and the help text of the steps (Dan, 2026-11-28: fewer type styles) */
.pdf-block p.select-label { font: 700 10px/1.2 var(--mono); color: var(--ink); margin: 0 0 9px; }
.pdf-block p.field-help { font-size: 13px; line-height: 1.5; color: var(--ink-2); margin: 0 0 16px; }

/* ---------- intro (Dan, 2026-11-28): one text style, the body text of the steps ---------- */
.intro { padding: 18px 0 8px; }
.intro > p { font-size: 15px; line-height: 1.5; color: var(--ink); margin: 0 0 16px; }
.intro > .intro-or { margin-bottom: 0; }
.intro:not([hidden]) + .steps { margin-top: 8px; }
.intro .pdf-block { margin: 0 0 22px; }
.intro .pdf-block .primary { margin-top: 0; }
.intro .pdf-block p.intro-status { margin: 10px 0 0; }
/* step 1, the home: no handles and no height line on the shade */
body[data-intro] .handles { display: none; }
.primary {
  background: var(--ink); color: var(--paper); border: 0; border-radius: 999px; padding: 0 22px; min-height: 46px;
  width: 100%; font: var(--label); letter-spacing: var(--track); text-transform: uppercase;
  display: flex; justify-content: space-between; align-items: center; margin-top: 18px;
}

/* one line of credit for the wood pictures: the copyright needs it */
.credit { font-size: 11.5px; line-height: 1.5; color: var(--muted); margin: 0 0 12px; }

/* CNC sheet size */
.sheet-row { display: flex; align-items: center; gap: 10px; font: 12px/1 var(--mono); color: var(--muted); }
.sheet-row .num input { width: 64px; }

/* saved designs */
.masthead { position: relative; }
/* Save is a raised paper pill: black is for Download and Next only (2026-11-30 polish) */
.pill.save-open { height: 30px; background: var(--paper); color: var(--ink); box-shadow: var(--raised); }
.pill.save-open[aria-expanded=true] { background: var(--ink-2); color: var(--paper); box-shadow: none; }
.library {
  position: absolute; top: 58px; right: 16px; z-index: 20; width: 340px; max-height: min(520px, calc(100dvh - 80px)); overflow-y: auto;
  background: var(--panel); box-shadow: var(--edge-lg); border-radius: var(--radius); padding: 4px 18px 16px;
}
.library .select-label { margin: 14px 0 8px; }
.save-row { display: flex; gap: 8px; }
.save-row input { flex: 1; min-width: 0; height: 34px; border: 0; border-radius: var(--radius); background: var(--paper-2); box-shadow: var(--recess); padding: 0 10px; font-size: 14px; }
.pill {
  height: 34px; padding: 0 16px; border: 0; border-radius: 999px; background: var(--ink); color: var(--paper);
  font: var(--label); letter-spacing: var(--track); text-transform: uppercase;
}
/* feedback: the panel opens upward from the lower-left corner of the preview */
.library.feedback { top: auto; right: auto; left: 16px; bottom: 54px; max-height: calc(100% - 70px); }
.feedback-form textarea, .feedback-form input[type=email] {
  display: block; width: 100%; box-sizing: border-box; border: 0; border-radius: var(--radius); background: var(--paper-2);
  box-shadow: var(--recess); padding: 8px 10px; font-family: inherit; font-size: 14px; line-height: 1.45; color: var(--ink); resize: vertical;
}
.feedback-form input[type=email] { height: 34px; }
.feedback-form .check-line { display: flex; align-items: center; gap: 8px; margin: 14px 0 4px; font-size: 14px; color: var(--ink-2); }
.feedback-form .trap { position: absolute; left: -10000px; width: 1px; height: 1px; overflow: hidden; }
.feedback-row { align-items: center; justify-content: space-between; margin-top: 12px; }
.feedback-intro { margin: 0 0 14px; font-size: 14px; line-height: 1.45; color: var(--ink-2); max-width: 34em; }
.feedback-status { margin: 0; font-size: 13px; line-height: 1.4; color: var(--ink-2); }
.feedback-status[data-level=stop] { color: var(--stop); }
.designs { list-style: none; margin: 0; padding: 0; }
.designs li { display: grid; grid-template-columns: 1fr auto; gap: 4px 8px; align-items: center; padding: 9px 0; border-bottom: 1px solid var(--line); }
.designs .name { font-size: 15px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.designs input { height: 30px; border: 0; border-radius: var(--radius); background: var(--paper-2); box-shadow: var(--recess); padding: 0 8px; font-size: 14px; min-width: 0; }
.designs time { grid-column: 1; font: 10px/1.2 var(--mono); letter-spacing: .08em; text-transform: uppercase; color: var(--muted); }
.designs .acts { grid-column: 2; grid-row: 1 / span 2; display: flex; gap: 2px; }
.designs .acts button { border: 0; background: none; width: 30px; height: 30px; padding: 0; border-radius: 50%; color: var(--ink-2); display: grid; place-items: center; }
.designs .acts button svg { width: 16px; height: 16px; }
.designs .acts button:hover { background: var(--paper-2); }
.designs .acts button.danger { color: var(--paper); background: var(--stop); }
#flat { width: 100%; height: 230px; display: block; }
#facts h4 { font: 700 10px/1.2 var(--mono); letter-spacing: var(--track); text-transform: uppercase; margin: 18px 0 8px; }
#facts table { width: 100%; border-collapse: collapse; font: 10.5px/1.4 var(--mono); table-layout: fixed; font-variant-numeric: tabular-nums; }
#facts td, #facts th { padding: 7px 2px; text-align: left; border-bottom: 1px solid var(--line); overflow-wrap: anywhere; }
#facts td:last-child { text-align: right; }
#facts .types { font-size: 9.5px; }
#facts .types td, #facts .types th { text-align: right; }
#facts .types td:first-child, #facts .types th:first-child { text-align: left; }
#facts .note { font: 13px/1.5 var(--serif); color: var(--ink-2); }

@media (hover: hover) {
  button:hover { filter: brightness(.96); }
  a:hover { text-decoration: underline; }
}
@media (max-width: 1100px) {
  .workspace { grid-template-columns: minmax(0, 1fr) 350px; }
  .editor-scroll { padding: 24px 22px; }
  .save-status { display: none; }
}
@media (max-width: 760px) {
  .masthead { height: 54px; padding: 0 16px; gap: 12px; }
  .quiet, .brand-name em { display: none; }
  .brand-name { font-size: 17px; }
  .workspace { display: flex; flex-direction: column; height: auto; min-height: 0; }
  .preview { height: 430px; position: sticky; top: 0; z-index: 2; background: var(--paper); border-bottom: 1px solid var(--line); }
  .stage-controls { top: 10px; left: 10px; }
  .library { right: 8px; left: 8px; width: auto; }
  /* the view buttons fill the bottom edge of a phone: feedback sits one row above them */
  .stage-corner { left: 10px; bottom: 54px; }
  .feedback-open { min-height: 34px; }
  .library.feedback { left: 8px; right: 8px; bottom: 98px; max-height: calc(100% - 108px); }
  .view-actions { right: 10px; bottom: 10px; }
  .view-actions > button, .zoom { min-height: 34px; }
  .editor { border-left: 0; overflow: visible; }
  .editor-scroll { overflow: visible; padding: 22px 20px 32px; }
  /* a step that opens scrolls to its top, below the sticky preview (Dan, 2026-11-30) */
  .step { scroll-margin-top: 430px; }
}
@media (prefers-reduced-motion: reduce) {
  * { scroll-behavior: auto !important; transition: none !important; }
}
