/* CHAOS-0001 | Logistic Map
   CatLab visual language: an interactive science exhibit — calm, readable,
   graphs first. No neon, no build step; plain CSS only. */

/* Theme (Prototype v5): <html data-theme="dark|light">, dark by default, switched by
   site/theme.js (not saved). Site header/footer colours live in site/site-chrome.css
   (--site-*); the tokens below are the EXHIBIT area. Light values = Prototype v5 light
   (MELUVIRA web tokens v1) for UI; science colours keep their meaning in both themes
   (same hue, lightened for dark — never inverted, never turned teal). */
:root {
  --font-sans: -apple-system, BlinkMacSystemFont, "Hiragino Sans", "Hiragino Kaku Gothic ProN",
    "Noto Sans JP", "Segoe UI", Roboto, sans-serif;   /* = Prototype v5 */
  --font-mono: "SFMono-Regular", Menlo, Consolas, monospace;
  --touch: 44px;
  --radius: 14px;              /* = Prototype v5 cards */
  --catlab-teal: #1B6B6F;      /* official CatLab / MELUVIRA teal */
}
:root[data-theme="light"] {
  --color-bg: #fafaf9;         /* exhibit area (= Prototype v5 light --ui-bg) */
  --color-surface: #ffffff;
  --color-surface-muted: #eef2f2;
  --color-ink: #1d2b2c;
  --color-ink-soft: #4f5f60;
  --color-border: #e1e2e2;
  --color-border-strong: #7d8b8b;
  /* science (unchanged meaning and values) */
  --color-grid: #ebe6db;
  --color-axis: #b9b2a4;
  --color-accent: #8a4b16;     /* warning text / fixed-point marker (brown) */
  --color-accent-soft: #f3e7d9;
  --color-a: #1f5fa8;          /* trajectory A / main series / current step */
  --color-a-tint: #eef3fa;
  --color-b: #b5482c;          /* trajectory B */
  --color-sep: #6a4c9c;        /* separation, λ */
  --color-bif: #1f2328;
  --color-pos: rgba(181, 72, 44, 0.12);
  --color-marker: #b0006a;
  --color-selection: rgba(31, 95, 168, 0.15);
  /* CatLab interaction accent */
  --ui-accent: var(--catlab-teal);      /* white on it 6.21:1; on --color-bg 5.95:1 */
  --ui-accent-hover: #175c60;
  --ui-accent-active: #144f52;
  --ui-accent-strong: #144f52;          /* selected border, label text */
  --ui-accent-soft: #e3eff0;            /* selected / badge tint */
  --ui-accent-faint: #f0f6f6;           /* hover / callout tint */
  --ui-on-accent: #ffffff;
  --ui-link: var(--catlab-teal);
  --color-focus: #6f70a3;               /* = Prototype v5 --ui-focus (4.45:1 on bg) */
  --disabled-opacity: 0.5;
  color-scheme: light;
}
:root, :root[data-theme="dark"] {
  --color-bg: #0e1516;         /* exhibit area (= Prototype v5 dark --ui-bg); header/footer #121a1b */
  --color-surface: #152021;
  --color-surface-muted: #1b2a2b;
  --color-ink: #eaf0ef;
  --color-ink-soft: #a3b3b2;
  --color-border: #2b3a3b;
  --color-border-strong: #6a7c7d;
  /* science: same hues, lightened for a dark plot (≥ 4.9:1 on the card surface) */
  --color-grid: #2e3e3f;
  --color-axis: #7d8f90;
  --color-accent: #e0a56a;     /* warning brown, lightened (7.7:1) */
  --color-accent-soft: #33261a;
  --color-a: #6aa6e8;          /* A blue (6.5:1) */
  --color-a-tint: #1a2a3d;
  --color-b: #f08a6c;          /* B orange-red (6.8:1) */
  --color-sep: #b49be0;        /* separation purple (6.9:1) */
  --color-bif: #eaf0ef;
  --color-pos: rgba(240, 138, 108, 0.16);
  --color-marker: #ff6fbf;
  --color-selection: rgba(106, 166, 232, 0.22);
  /* CatLab interaction accent: official dark teal (#1B6B6F is only 2.7:1 as text here) */
  --ui-accent: #6cc0c3;                 /* dark text on it 8.6:1; on surface 7.9:1 */
  --ui-accent-hover: #84cdd0;
  --ui-accent-active: #84cdd0;
  --ui-accent-strong: #84cdd0;
  --ui-accent-soft: #1d3537;
  --ui-accent-faint: #172728;
  --ui-on-accent: #0f1718;
  --ui-link: #6cc0c3;
  --color-focus: #b7b8de;               /* = Prototype v5 dark --ui-focus */
  --disabled-opacity: 0.6;              /* keeps disabled text ≥ 4.5:1 on the dark card */
  color-scheme: dark;
}

* { box-sizing: border-box; }

html, body {
  margin: 0;
  padding: 0;
  background: var(--color-bg);
  color: var(--color-ink);
  font-family: var(--font-sans);
  font-size: 16px;
  line-height: 1.65;
  overflow-x: hidden;
}

[hidden] { display: none !important; }

.sr-only {
  position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; border: 0;
}

/* .skip-link, :focus-visible base: site/site-chrome.css (official, Prototype v5) */

a { color: var(--ui-link); overflow-wrap: anywhere; text-underline-offset: 0.2em; }

:focus-visible {
  outline: 3px solid var(--color-focus);
  outline-offset: 2px;
  border-radius: 4px;
}

/* ---------- mode visibility ---------- */
body[data-mode="beginner"] .only-sr,
body[data-mode="beginner"] .only-research,
body[data-mode="standard"] .only-research,
body:not([data-mode="beginner"]) .only-beginner { display: none !important; }
/* Beginner = visual-first view: hide the formal blocks, reorder optional ones */
body[data-mode="beginner"] .hide-beginner { display: none !important; }
body[data-mode="beginner"] #sec-cobweb { order: 20; }
body[data-mode="beginner"] #sec-more { order: 25; }
body[data-mode="beginner"] #sec-sources { order: 30; }
body[data-mode="beginner"] .chart-tall { height: 400px; }
.status-plain { margin-top: 0.5rem; background: var(--ui-accent-faint); border-left: 4px solid var(--ui-accent); padding: 0.45rem 0.7rem; border-radius: 0 8px 8px 0; }
.status-plain p { margin: 0.1rem 0 0; font-weight: 600; font-size: 1rem; min-height: 4.95em; } /* 3 lines reserved (longest guide result): the text change at the end of a run must not move Start */
.secondary { font-size: 0.85rem; color: var(--color-ink-soft); font-weight: normal; }
#rule-disclosure { margin-top: 0.5rem; }
#x0-advanced > summary { font-weight: 600; font-size: 0.95rem; }
#x0-advanced { margin-bottom: 0.6rem; }

/* Beginner guide buttons: 2 × 2 on small screens, one row when there is room.
   Selected = aria-pressed; shown by a check mark, thick border and bold text,
   not by colour alone. */
.guide-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0.5rem; margin: 0.4rem 0 0.5rem; }
@media (min-width: 700px) { .guide-grid { grid-template-columns: repeat(4, minmax(0, 1fr)); } }
@media (min-width: 1200px) { body[data-mode="beginner"] #sec-intro, #sec-guide { grid-column: 1 / -1; } }
/* Beginner, wide screens: ui.js puts the controls inside <main> right after
   the guide card (.layout.b-merged). The intro spans the full width; then the
   controls (left) start on the same row as the guide; below the guide come
   "How the value moves" (first observation, beside Start) and then "Watch it
   one step at a time" (2026-11-26: numbers first, then step details). */
@media (min-width: 960px) {
  .layout.b-merged { grid-template-columns: minmax(0, 1fr); }
  .layout.b-merged .content { grid-template-columns: 300px minmax(0, 1fr); }
  .layout.b-merged .content > .card, .layout.b-merged .content > .aux-controls,
  .layout.b-merged #sec-ts, .layout.b-merged #sec-steps, .layout.b-merged #sec-bif, .layout.b-merged #sec-sources { grid-column: 2 / -1; }
  .layout.b-merged #sec-intro { grid-column: 1 / -1; grid-row: 1; }
  .layout.b-merged #sec-guide { grid-column: 2 / -1; grid-row: 2; }
  .layout.b-merged .content > .controls { grid-column: 1; grid-row: 2 / span 3; }
}
@media (min-width: 1200px) {
  .layout.b-merged .content { grid-template-columns: 300px minmax(0, 1fr) minmax(0, 1fr); }
  .layout.b-merged #sec-cobweb { grid-column: 2; }
  .layout.b-merged #sec-more { grid-column: 3; }
}
.btn.guide-btn { white-space: normal; line-height: 1.35; text-align: center; }
.btn.guide-btn[aria-pressed="true"] { background: var(--ui-accent-soft); border: 3px solid var(--ui-accent-strong); }
.btn.guide-btn[aria-pressed="true"]::before { content: "✓ "; content: "✓ " / ""; }
.guide-state { margin: 0; font-weight: 600; font-size: 0.95rem; }
/* Beginner "Key point" under the step list (below / beside the controls, so it
   never pushes the Start/Pause button), shown once a guide example has run a while. */
.takeaway { margin: 0.45rem 0 0.2rem !important; padding: 0.4rem 0.65rem; background: var(--ui-accent-faint);
  border-left: 4px solid var(--ui-accent); border-radius: 0 8px 8px 0; font-size: 0.95rem; }
.takeaway-label { display: inline-block; margin-right: 0.5em; font-size: 0.8rem; font-weight: 700; color: var(--ui-accent-strong); }

/* "More settings" heading: always in Beginner; in other modes only when the
   block is moved out of the panel into <main> (narrow screens). */
body:not([data-mode="beginner"]) .controls .aux-heading { display: none; }

/* Narrow screens: ui.js moves the secondary settings (every mode) and, in
   Beginner, the controls panel
   into <main> (DOM order = visual = Tab order). */
.content > .aux-controls {
  background: var(--color-surface); border: 1px solid var(--color-border);
  border-radius: var(--radius); padding: 1rem 1.1rem 1.1rem;
}

/* ---------- header ---------- */
.exhibit-header {
  /* Part of the exhibit area (no own band): the site header above is the "building",
     this is the room's title. */
  background: transparent;
}
.header-inner {
  max-width: 72rem; margin: 0 auto; padding: 1.25rem 1rem;
  display: grid; gap: 1rem;
}
/* Long words (EN title at 320 px + text 200 %) wrap instead of being cut. */
.header-inner > * { min-width: 0; overflow-wrap: break-word; }
/* Same for the panels and cards: a long word or value never widens the column. */
.layout > *, .content > * { min-width: 0; }
.card, .controls { overflow-wrap: break-word; }
.exhibit-id {
  margin: 0; font-family: var(--font-mono); font-size: 0.8rem;
  letter-spacing: 0.04em; color: var(--ui-accent);
}
h1 { margin: 0.1rem 0 0.4rem; font-size: clamp(1.4rem, 1rem + 2vw, 2.1rem); line-height: 1.25; }
.lead { margin: 0; color: var(--color-ink-soft); max-width: 60rem; }
.header-controls { display: flex; flex-wrap: wrap; gap: 0.75rem 1.25rem; align-items: flex-end; }
.mode-desc { flex-basis: 100%; margin: 0; font-size: 0.9rem; color: var(--color-ink-soft); }

@media (min-width: 960px) {
  .mode-desc { flex-basis: auto; max-width: 32rem; align-self: center; }
}

/* ---------- segmented buttons ---------- */
.segmented { border: 0; padding: 0; margin: 0; display: flex; flex-wrap: wrap; gap: 0; }
.segmented legend { font-size: 0.8rem; color: var(--color-ink-soft); padding: 0; margin-bottom: 0.2rem; width: 100%; }
.seg-btn {
  min-height: var(--touch); padding: 0.4rem 0.9rem; font: inherit; font-size: 0.95rem;
  background: var(--color-surface); color: var(--color-ink);
  border: 1px solid var(--color-border); cursor: pointer;
}
.seg-btn + .seg-btn { margin-left: -1px; }
.seg-btn:first-of-type { border-radius: 8px 0 0 8px; }
.seg-btn:last-of-type { border-radius: 0 8px 8px 0; }
.seg-btn[aria-pressed="true"] {
  background: var(--ui-accent); color: var(--ui-on-accent); border-color: var(--ui-accent);
  font-weight: 600;
}
.seg-btn[aria-pressed="true"]::before { content: "✓ "; }
.segmented.small .seg-btn { font-size: 0.85rem; padding: 0.3rem 0.7rem; }

/* ---------- layout ---------- */
.layout {
  max-width: 72rem; margin: 0 auto; padding: 1rem;
  display: grid; gap: 1rem;
}
@media (min-width: 960px) {
  .layout { grid-template-columns: 300px minmax(0, 1fr); align-items: start; }
  .controls { position: sticky; top: 0.75rem; max-height: calc(100vh - 1.5rem); overflow-y: auto; }
}
.content { display: grid; gap: 1rem; min-width: 0; align-items: start; }
.content:focus { outline: none; }
@media (min-width: 1200px) {
  .content { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); }
  .card-wide, #sec-ts, #sec-steps, #sec-rule { grid-column: 1 / -1; }  /* numbers first, full width, in every mode */
}

/* ---------- controls panel ---------- */
.controls {
  background: var(--color-surface); border: 1px solid var(--color-border);
  border-radius: var(--radius); padding: 1rem;
}
.panel-title { margin: 0 0 0.5rem; font-size: 1.05rem; }
.control { padding: 0.75rem 0; border-top: 1px solid var(--color-grid); }
.control:first-of-type { border-top: 0; }
.control-label { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: baseline; gap: 0.5rem; font-weight: 600; font-size: 0.95rem; margin: 0 0 0.35rem; }
.value-badge {
  font-family: var(--font-mono); font-weight: 600; background: var(--ui-accent-soft);
  padding: 0.05rem 0.45rem; border-radius: 6px; font-size: 0.9rem;
}
.help { font-size: 0.85rem; color: var(--color-ink-soft); margin: 0.3rem 0; }
.mono { font-family: var(--font-mono); }

input[type="range"] { width: 100%; min-height: var(--touch); accent-color: var(--ui-accent); margin: 0; }
input[type="number"] {
  width: 100%; min-height: var(--touch); font: inherit; font-family: var(--font-mono);
  padding: 0.3rem 0.5rem; border: 1px solid var(--color-border); border-radius: 6px;
  background: var(--color-surface); color: var(--color-ink);
}
.r-zones { display: flex; justify-content: space-between; font-size: 0.75rem; color: var(--color-ink-soft); font-family: var(--font-mono); }
.number-row { margin-top: 0.35rem; }

.check { display: flex; align-items: center; gap: 0.5rem; min-height: var(--touch); font-size: 0.95rem; }
.check input { width: 1.2rem; height: 1.2rem; }

.btn {
  min-height: var(--touch); padding: 0.45rem 0.85rem; font: inherit; font-size: 0.92rem;
  background: var(--color-surface); color: var(--color-ink);
  border: 1px solid var(--color-axis); border-radius: 8px; cursor: pointer;
}
.btn:hover:not(:disabled) { background: var(--ui-accent-faint); }
.btn:disabled { opacity: var(--disabled-opacity); cursor: not-allowed; }
.btn.primary { background: var(--ui-accent); border-color: var(--ui-accent); color: var(--ui-on-accent); font-weight: 600; }
.btn.primary:hover:not(:disabled) { background: var(--ui-accent-hover); }
.btn.primary:active:not(:disabled) { background: var(--ui-accent-strong); }
.btn.link { border: 0; background: none; color: var(--ui-link); text-decoration: underline; padding-left: 0; }
.btn[aria-pressed="true"] { border-width: 2px; border-color: var(--color-ink); font-weight: 600; }
.btn.primary[aria-pressed="true"] { border-color: var(--ui-accent-strong); }

.play-row { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0.4rem; margin-bottom: 0.6rem; }
.preset-grid { display: grid; grid-template-columns: 1fr; gap: 0.35rem; }
.btn.preset { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 0.5rem; text-align: left; }
.preset-r { font-family: var(--font-mono); font-size: 0.8rem; color: var(--color-ink-soft); white-space: nowrap; }
.btn-row { display: flex; flex-wrap: wrap; gap: 0.4rem; margin: 0.5rem 0; }

.notice { min-height: 1.2em; margin: 0.5rem 0 0; font-size: 0.88rem; color: var(--color-accent); }
.notice-inline { background: var(--color-accent-soft); padding: 0.5rem 0.75rem; border-radius: 6px; font-size: 0.9rem; }

/* ---------- cards ---------- */
.card {
  background: var(--color-surface); border: 1px solid var(--color-border);
  border-radius: var(--radius); padding: 1.25rem; min-width: 0;  /* = Prototype v5 card (20px) */
}
.card h2 { margin: 0 0 0.4rem; font-size: 1.2rem; line-height: 1.35; }
.card p { margin: 0.4rem 0; }
h3.sub, .callout h3 { font-size: 1rem; margin: 1rem 0 0.35rem; }
.callout h3 { margin-top: 0; }

.formula {
  font-family: "Times New Roman", "Hiragino Mincho ProN", serif; font-size: clamp(1.3rem, 1rem + 1.5vw, 1.9rem);
  text-align: center; margin: 0.6rem 0 !important; padding: 0.6rem; background: var(--color-bg);
  border-radius: 8px; overflow-x: auto;
}
.parts { margin: 0.3rem 0; padding-left: 1.2rem; color: var(--color-ink-soft); }
.callout {
  border-left: 4px solid var(--ui-accent); background: var(--ui-accent-faint);
  padding: 0.6rem 0.8rem; border-radius: 0 8px 8px 0; margin: 0.75rem 0 0;
}
.callout-strong { border-left-color: var(--ui-accent-strong); background: var(--ui-accent-soft); }

details > summary { cursor: pointer; min-height: var(--touch); display: flex; flex-wrap: wrap; align-items: center; gap: 0.4rem; list-style: none; }
details > summary::-webkit-details-marker { display: none; }
details > summary::before { content: "▶"; font-size: 0.8rem; color: var(--ui-accent); transition: transform 0.15s; }
details[open] > summary::before { transform: rotate(90deg); }
details > summary h2 { margin: 0; display: inline; }

/* ---------- steps ---------- */
.step-counter { font-family: var(--font-mono); font-weight: 600; }
.step-list { list-style: none; margin: 0.4rem 0; padding: 0; display: flex; flex-wrap: wrap; gap: 0.35rem; align-items: stretch; }
.step-list li {
  display: flex; flex-direction: column; gap: 0.1rem; padding: 0.4rem 0.6rem;
  border: 1px solid var(--color-grid); border-radius: 8px; background: var(--color-bg);
  font-family: var(--font-mono); font-size: 0.85rem; min-width: 7.5rem;
}
.step-list li.current { border: 2px solid var(--color-a); background: var(--color-a-tint); }
.step-list .arrow { color: var(--color-ink-soft); font-size: 0.75rem; overflow-wrap: anywhere; }
.step-label { color: var(--color-ink-soft); font-size: 0.78rem; }
.step-value { font-weight: 600; }

/* ---------- charts ---------- */
.chart { display: block; width: 100%; height: 240px; background: var(--color-surface); touch-action: manipulation; }
.chart-small { height: 150px; }
.chart-square { height: auto; aspect-ratio: 1 / 1; max-height: 420px; }
.chart-tall { height: 340px; }
.bif-stack { position: relative; }
.bif-stack .overlay { position: absolute; inset: 0; background: transparent; cursor: crosshair; touch-action: pan-y; }
.summary { font-size: 0.92rem; background: var(--color-bg); padding: 0.45rem 0.7rem; border-radius: 6px; }

.legend { list-style: none; padding: 0; margin: 0.3rem 0; display: flex; flex-wrap: wrap; gap: 0.3rem 1rem; font-size: 0.88rem; }
.legend li { display: flex; align-items: center; gap: 0.4rem; }
.swatch { display: inline-block; width: 28px; height: 0; border-top: 3px solid; }
.swatch-a { border-color: var(--color-a); }
.swatch-b { border-color: var(--color-b); border-top-style: dashed; }
.swatch-curve { border-color: var(--color-ink); }
.swatch-diag { border-color: var(--color-ink-soft); border-top-style: dashed; border-top-width: 2px; }

.zoom-box { border-top: 1px solid var(--color-grid); margin-top: 0.5rem; }
.range-row { display: flex; flex-wrap: wrap; gap: 0.5rem; align-items: flex-end; }
.range-row label { display: grid; font-size: 0.85rem; flex: 1 1 7rem; }

/* Learning block, separated from the zoom (operation) block above. */
.story-box { border-top: 1px solid var(--color-border); margin-top: 1rem; padding-top: 0.25rem; }
.story-lead { margin: 0 0 0.35rem; }
.story { padding-left: 1.4rem; margin: 0.3rem 0; }
.story li { margin: 0.2rem 0; }

.ly-readout { display: flex; flex-wrap: wrap; gap: 0.3rem 0.8rem; align-items: baseline; background: var(--color-bg); padding: 0.6rem 0.8rem; border-radius: 8px; }
.ly-label { font-size: 0.85rem; color: var(--color-ink-soft); }
#ly-value { font-family: var(--font-mono); font-size: 1.15rem; }

.strip-grid { display: grid; grid-template-columns: 1fr; gap: 0.6rem; }
@media (min-width: 560px) { .strip-grid { grid-template-columns: 1fr 1fr; } }
.strip-grid figure { margin: 0; }
.strip-grid figcaption { font-size: 0.85rem; color: var(--color-ink-soft); }
.strip { height: 90px; }

/* ---------- research ---------- */
.obs-grid { display: grid; grid-template-columns: minmax(0, auto) minmax(0, 1fr); gap: 0.25rem 1rem; margin: 0.3rem 0; font-size: 0.9rem; }
.obs-grid dt { color: var(--color-ink-soft); }
.obs-grid dd { margin: 0; overflow-wrap: anywhere; }
.settings-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 14rem), 1fr)); gap: 0.5rem 0.8rem; margin: 0.4rem 0 0.6rem; }
.settings-grid label { display: grid; gap: 0.2rem; font-size: 0.85rem; }
.plain-list { padding-left: 1.2rem; margin: 0.3rem 0; }
.plain-list li { margin: 0.2rem 0; }
.table-wrap { overflow-x: auto; }
.data-table { border-collapse: collapse; font-size: 0.88rem; min-width: 18rem; }
.data-table th, .data-table td { border: 1px solid var(--color-grid); padding: 0.3rem 0.6rem; text-align: right; font-family: var(--font-mono); }
.data-table th { background: var(--color-bg); font-family: var(--font-sans); text-align: center; }
.export-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 12rem), 1fr)); gap: 0.4rem; }

/* Play button inside an observation card: the same simulation as the main
   Start, shown as a secondary (outline) button so the panel's Start stays
   the one primary action. */
.card-play { margin: 0.35rem 0 0.5rem; }
.card-play-btn { min-width: min(9.5rem, 100%); max-width: 100%; }
.source-list { padding-left: 1.2rem; margin: 0.3rem 0; }
.source-list li { margin: 0.5rem 0; }
.source-list .help { margin: 0.1rem 0; }
/* DOI / URL lines have no spaces: let them wrap anywhere so they never run
   past the card at 320px or with large text (site audit 2026-11-26). */
.source-list .mono { overflow-wrap: anywhere; }

.exhibit-footer {
  max-width: 72rem; margin: 0 auto; padding: 1rem 1rem 2.5rem;
  font-size: 0.85rem; color: var(--color-ink-soft);
}
.exhibit-footer p { margin: 0.2rem 0; }
.exhibit-footer .footer-heading { margin: 0 0 0.3rem; font-size: 1rem; line-height: 1.4; color: var(--color-ink); }

/* ---------- reduced motion ---------- */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { transition: none !important; animation: none !important; scroll-behavior: auto !important; }
}

/* ---------- narrow screens ---------- */
@media (max-width: 400px) {
  .card { padding: 0.8rem; }
  .layout { padding: 0.5rem; }
  .chart { height: 210px; }
  .chart-tall { height: 280px; }
  body[data-mode="beginner"] .chart-tall { height: 360px; }
  .seg-btn { padding: 0.35rem 0.6rem; }
}

/* Same content edges as the official .container (72rem, 1rem → 2.5rem gutters at 48rem),
   (kept last so it wins over the base padding) so the site header, breadcrumb and exhibit line up. */
@media (min-width: 48rem) {
  .header-inner, .layout, .exhibit-footer { padding-left: 2.5rem; padding-right: 2.5rem; }
}
