:root {
  color-scheme: dark;
  --bg: #141818;
  --surface: #090c0c;
  --panel: #0b0e0e;
  --ink: #ffb757;
  --strong: #ffc56d;
  --muted: #c6ba9f;
  --line: #97622b;
  --soft-line: #493c28;
  --active: #ffae3f;
  --active-ink: #20160b;
  --hover: #292016;
  --scanline: rgba(255, 185, 79, .025);
  --glow: rgba(255, 158, 29, .12);
  --focus: #ffe0a3;
  --menu-glow: rgba(255, 170, 55, .28);
  --sans: -apple-system, BlinkMacSystemFont, 'Noto Sans CJK JP', 'Hiragino Kaku Gothic ProN', 'Yu Gothic', sans-serif;
  --mono: 'SFMono-Regular', Consolas, 'Liberation Mono', Menlo, monospace;
}
html[data-theme="light"] {
  color-scheme: light;
  --bg: #e9e4d5;
  --surface: #fff9e9;
  --panel: #fff9e9;
  --ink: #814115;
  --strong: #b74b07;
  --muted: #625341;
  --line: #b76626;
  --soft-line: #d4b38b;
  --active: #f8a342;
  --active-ink: #321b0b;
  --hover: #f4e4c8;
  --scanline: rgba(102, 60, 16, .025);
  --glow: transparent;
  --focus: #7c3300;
  --menu-glow: rgba(185, 94, 16, .2);
}
* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body { margin: 0; padding: 28px; background: var(--bg); color: var(--ink); font: 1rem/1.65 var(--sans); }
button, input { font: inherit; }
button, a { -webkit-tap-highlight-color: transparent; }
button { color: inherit; cursor: pointer; }
a { color: inherit; text-decoration: none; }
p, h1, h2, h3 { margin: 0; }
ul, ol { margin: 0; padding: 0; list-style: none; }
[hidden] { display: none !important; }
:focus-visible { outline: 2px solid var(--focus); outline-offset: 4px; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
.skip-link { position: fixed; top: -100px; left: 32px; background: var(--active); color: var(--active-ink); padding: 10px 16px; z-index: 30; }
.skip-link:focus { top: 12px; }
.terminal-shell { max-width: 1510px; margin: 0 auto; border: 1px solid var(--line); background: var(--surface); box-shadow: 0 0 0 6px var(--surface), 0 0 0 7px var(--soft-line), 0 24px 60px #0003; position: relative; }
.terminal-shell::after { content: ''; position: absolute; inset: 0; pointer-events: none; z-index: 4; background: repeating-linear-gradient(transparent 0 3px, var(--scanline) 3px 4px); }
.site-header { min-height: 64px; display: flex; align-items: center; padding: 8px 24px; gap: 22px; border-bottom: 1px solid var(--line); position: relative; z-index: 10; font-family: var(--mono); }
.brand { font-size: 1.125rem; font-weight: 600; min-width: 0; }
.header-motto { margin-left: auto; font-size: .8125rem; line-height: 1.5; letter-spacing: .025em; text-align: right; color: var(--muted); }
.mobile-break { display: none; }
.theme-toggle { border: 1px solid var(--soft-line); padding: 5px 10px; background: transparent; min-height: 44px; font-size: .875rem; }
.menu-toggle { display: flex; gap: 8px; justify-content: center; align-items: center; border: none; background: transparent; min-width: 44px; min-height: 44px; font-size: 1.6rem; line-height: 1; }
.menu-label { font-size: .875rem; }
.theme-toggle:hover, .menu-toggle:hover { background: var(--hover); }
.header-menu { position: absolute; top: calc(100% + 8px); right: 16px; width: min(340px, calc(100vw - 50px)); border: 1px solid var(--line); background: var(--surface); padding: 12px; box-shadow: 0 12px 30px #0005; }
.header-menu a { display: flex; gap: 12px; align-items: baseline; padding: 11px 12px; min-height: 46px; }
.header-menu a small { margin-left: auto; font-family: var(--sans); font-size: .8125rem; }
main { padding: 24px; min-width: 0; }
main:focus { outline: none; }
.hero { position: relative; border: 1px solid var(--soft-line); min-height: 221px; padding: 28px 28px 26px; display: grid; grid-template-columns: 1.5fr 1fr; gap: 24px; align-items: center; overflow: hidden; }
.hero-label { color: var(--muted); font: .75rem/1.4 var(--mono); letter-spacing: .12em; margin-bottom: 17px; }
.pixel-title { display: flex; flex-wrap: wrap; align-items: center; gap: 18px; color: var(--strong); filter: drop-shadow(0 0 9px var(--glow)); max-width: 750px; }
.pixel-title svg { height: clamp(30px, 3.55vw, 55px); width: auto; max-width: 100%; fill: currentColor; shape-rendering: crispEdges; }
.enter-link { display: inline-flex; align-items: center; gap: 14px; font: 1.1875rem/1.5 var(--mono); margin-top: 18px; min-height: 44px; }
.enter-link:hover { color: var(--strong); text-decoration: underline; text-underline-offset: 6px; }
.cursor-block { width: 8px; height: 17px; background: var(--ink); display: inline-block; opacity: .7; }
.hero-world { display: flex; align-items: flex-end; justify-content: space-between; gap: 12px; }
.hero-copy { font-size: .875rem; line-height: 1.65; font-weight: 600; white-space: nowrap; padding-bottom: 15px; }
.art-wrap { position: relative; min-width: 0; flex: 1; }
.themed-art { display: block; width: 100%; height: auto; }
.light-art { display: none; }
html[data-theme="light"] .dark-art { display: none; }
html[data-theme="light"] .light-art { display: block; }
html[data-theme="dark"] .themed-art { mix-blend-mode: screen; }
html[data-theme="light"] .themed-art { mix-blend-mode: multiply; }
.hero .art-wrap { max-width: 318px; }
.pixel-canvas { width: 100%; height: auto; display: block; image-rendering: crisp-edges; image-rendering: pixelated; }
.hero-pixel { box-shadow: 0 0 12px var(--glow); }
.hero-pixel::after { content: ''; position: absolute; inset: 0; pointer-events: none; background: repeating-linear-gradient(transparent 0 3px, var(--scanline) 3px 4px); }
.dashboard { margin-top: 14px; display: grid; grid-template-columns: .95fr 1.12fr 1.42fr; gap: 14px; align-items: stretch; }
.panel { border: 1px solid var(--line); padding: 13px 15px; background: var(--panel); min-width: 0; }
.panel-heading { font: .875rem/1.5 var(--mono); letter-spacing: .015em; padding-bottom: 9px; margin-bottom: 14px; border-bottom: 1px solid var(--line); display: flex; gap: 8px; align-items: baseline; font-weight: 400; }
.panel-heading::before { content: '//'; color: var(--muted); }
.menu-panel { display: flex; flex-direction: column; }
.main-menu { font-family: var(--mono); }
.menu-item { display: flex; gap: 12px; align-items: center; min-height: 54px; padding: 4px 12px; font-size: clamp(1rem, 1.5vw, 1.375rem); line-height: 1.45; }
.menu-item::before { content: '›'; font-size: 1.7em; line-height: 1; flex-shrink: 0; }
.menu-item[data-pointer-lit],
.menu-item[data-pressed],
.menu-item:focus-visible,
.header-menu a[data-pointer-lit],
.header-menu a[data-pressed],
.header-menu a:focus-visible {
  color: var(--active-ink);
  background: var(--active);
  box-shadow: 0 0 14px var(--menu-glow), inset 0 0 0 1px var(--active);
  text-shadow: none;
}
.menu-item[aria-current="page"], .header-menu a[aria-current="page"] { font-weight: 600; }
.menu-item[aria-current="page"]::before { content: '▸'; }
.header-menu a[aria-current="page"] { text-decoration: underline; text-underline-offset: 5px; }
.menu-item:focus-visible, .header-menu a:focus-visible { outline-offset: 2px; }
.menu-meta { display: flex; justify-content: space-between; gap: 10px; border-top: 1px solid var(--line); margin-top: auto; padding-top: 18px; font: .75rem/1.55 var(--mono); color: var(--muted); }
.information { display: flex; flex-direction: column; }
.welcome { font-size: clamp(1.2rem, 1.65vw, 1.65rem); line-height: 1.75; font-weight: 500; color: var(--strong); text-wrap: balance; }
.welcome-break { display: none; }
.information-copy { font-size: .9375rem; color: var(--muted); margin-top: 12px; }
.information .art-wrap { flex: none; margin: auto -1px 10px; padding-top: 12px; }
.info-signature { display: flex; align-items: flex-end; gap: 14px; justify-content: space-between; font: .75rem/1.5 var(--mono); color: var(--muted); }
.info-signature span:last-child { text-align: right; }
.right-deck { display: grid; grid-template-columns: repeat(10, minmax(0, 1fr)); grid-template-rows: auto 1fr; gap: 14px; }
.status { grid-column: 1 / span 6; }
.status dl { margin: 0 0 10px; font: .875rem/1.75 var(--mono); }
.status dt, .status dd { display: inline; margin: 0; }
.status dt::after { content: ': '; }
.status dt:not(:first-child)::before { content: ''; display: block; }
.mission-label { font: .875rem/1.5 var(--mono); margin-top: 9px; }
.mission-list { margin-top: 6px; font-size: .9375rem; }
.mission-list li::before { content: '− '; }
.sample-note { color: var(--muted); font-size: .75rem; line-height: 1.55; margin-top: 9px; }
.mascot-panel { grid-column: 7 / span 4; display: flex; flex-direction: column; align-items: center; }
.mascot-panel .panel-heading { width: 100%; margin-bottom: 20px; }
.mascot-stage { display: flex; flex-wrap: wrap; max-width: 100%; align-items: flex-end; gap: 8px; margin: auto 0; }
.cat-art { width: 68px; flex-shrink: 0; image-rendering: pixelated; }
.cat-bubble { border: 1px solid var(--line); padding: 8px; position: relative; font: .75rem/1.4 var(--mono); margin-bottom: 24px; }
.cat-bubble::after { content: ''; width: 7px; height: 7px; border-left: 1px solid var(--line); border-bottom: 1px solid var(--line); background: var(--panel); transform: skewY(-35deg); position: absolute; bottom: -5px; left: 8px; }
.mascot-caption { margin-top: 10px; font-size: .75rem; color: var(--muted); text-align: center; }
.sectors { grid-column: 1 / span 5; }
.unlocks { grid-column: 6 / span 5; }
.sector-link { display: flex; gap: 6px; align-items: baseline; padding: 4px 0; min-height: 36px; font: 1rem/1.5 var(--mono); }
.sector-link::before { content: '−'; }
.sector-link small { color: var(--muted); font: .75rem/1.4 var(--sans); margin-left: auto; }
.sector-link:hover, .unlock-link:hover { color: var(--strong); text-decoration: underline; text-underline-offset: 4px; }
.unlock-link { display: block; font-size: .9375rem; line-height: 1.5; padding: 6px 0; min-height: 40px; }
.unlock-link::before { content: '» '; font-family: var(--mono); }
.panel-caption { font: .75rem/1.4 var(--mono); border-top: 1px solid var(--line); margin-top: 12px; padding-top: 9px; color: var(--muted); }
.prototype-footnote { margin-top: 15px; color: var(--muted); font-size: .75rem; line-height: 1.6; }
.site-footer { border-top: 1px solid var(--line); display: flex; flex-wrap: wrap; gap: 18px 26px; align-items: center; padding: 16px 24px; font: .75rem/1.4 var(--mono); }
.footer-brand { font-size: .875rem; }
.footer-verbs i { font-style: normal; padding: 0 12px; color: var(--line); }
.footer-meta { margin-left: auto; color: var(--muted); text-align: right; }
.footer-meta span { display: block; }
.page-intro { border: 1px solid var(--soft-line); padding: 26px; display: flex; align-items: center; justify-content: space-between; gap: 20px; margin-bottom: 20px; }
.eyebrow { color: var(--muted); font: .75rem/1.5 var(--mono); letter-spacing: .1em; margin-bottom: 8px; }
.page-title { font: 600 clamp(2rem, 4vw, 3.5rem)/1.2 var(--mono); color: var(--strong); overflow-wrap: anywhere; }
.page-subtitle { font-size: 1.0625rem; margin-top: 12px; max-width: 55ch; }
.return-home { border: 1px solid var(--line); padding: 10px 16px; display: inline-flex; min-height: 44px; white-space: nowrap; font-size: .9375rem; }
.return-home:hover { background: var(--active); color: var(--active-ink); }
.page-layout { display: grid; grid-template-columns: minmax(235px, .75fr) minmax(0, 2.7fr); gap: 20px; align-items: start; }
.page-layout .menu-panel { position: sticky; top: 22px; }
.page-layout .menu-item { font-size: 1rem; min-height: 48px; }
.page-layout .menu-meta { margin-top: 20px; }
.page-content { min-width: 0; }
.content-note { border-left: 2px solid var(--line); padding: 10px 14px; background: var(--hover); color: var(--muted); font-size: .875rem; margin-bottom: 22px; }
.content-section { scroll-margin-top: 20px; margin-bottom: 26px; }
.content-section:target { outline: 1px solid var(--line); outline-offset: 8px; }
.section-title { font: 1.125rem/1.5 var(--mono); border-bottom: 1px solid var(--line); padding-bottom: 10px; margin-bottom: 15px; color: var(--strong); }
.section-title small { font: .875rem var(--sans); margin-left: 14px; color: var(--muted); }
.record-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px; }
.record { border: 1px solid var(--soft-line); padding: 20px; min-width: 0; display: flex; flex-direction: column; align-items: flex-start; }
.record h3 { font-size: 1.125rem; line-height: 1.6; font-weight: 500; color: var(--strong); overflow-wrap: anywhere; }
.record p { margin-top: 9px; color: var(--muted); }
.pending { border: 1px solid var(--soft-line); padding: 2px 8px; font-size: .8125rem; display: inline-block; margin-top: 18px; color: var(--muted); }
.record .external-link { margin-top: 18px; text-decoration: underline; text-underline-offset: 4px; }
.mission-record { display: grid; grid-template-columns: 44px 1fr; gap: 12px; border-top: 1px solid var(--soft-line); padding: 24px 0; }
.mission-number { font: 1.25rem var(--mono); color: var(--muted); }
.mission-record h3 { font-size: 1.25rem; font-weight: 500; }
.mission-record p { color: var(--muted); margin-top: 7px; }
.route-home-end { display: inline-flex; margin-top: 16px; }
.no-script { margin: 20px; padding: 20px; border: 1px solid var(--line); }
@media (min-width: 1500px) { .dashboard { grid-template-columns: 1fr 1.15fr 1.5fr; } }
@media (max-width: 1200px) {
  body { padding: 20px; }
  main { padding: 20px; }
  .hero { grid-template-columns: 1.25fr 1fr; padding: 24px; }
  .hero-world { gap: 10px; }
  .hero-copy { font-size: .8125rem; }
  .pixel-title { gap: 12px; }
  .dashboard { grid-template-columns: .9fr 1.05fr 1.35fr; gap: 12px; }
  .right-deck { grid-template-columns: 1fr 1fr; gap: 12px; }
  .status { grid-column: 1 / -1; }
  .mascot-panel { grid-column: 1 / -1; flex-direction: row; flex-wrap: wrap; gap: 10px; }
  .mascot-panel .panel-heading { width: 100%; margin-bottom: 0; }
  .mascot-stage { align-items: center; margin: 0; }
  .cat-art { width: 36px; }
  .cat-bubble { margin: 0; font-size: .75rem; }
  .cat-bubble br { display: none; }
  .mascot-caption { margin: 0 0 0 auto; }
  .sectors, .unlocks { grid-column: 1 / -1; }
  .panel { padding: 12px; }
  .header-motto { font-size: .75rem; }
}
@media (max-width: 950px) {
  .dashboard { grid-template-columns: .9fr 1.4fr; }
  .right-deck { grid-column: 1 / -1; grid-template-columns: 1fr 1fr; }
  .right-deck > * { grid-column: auto; }
  .mascot-panel { flex-direction: column; }
  .cat-art { width: 52px; }
  .mascot-caption { margin: 0; }
  .mascot-stage { margin: auto; }
  .sectors .sector-link, .unlocks .unlock-link { font-size: .875rem; }
  .sector-link small { display: none; }
  .hero { grid-template-columns: 1.2fr 1fr; }
  .hero-world { flex-direction: column-reverse; align-items: flex-start; gap: 5px; }
  .hero .art-wrap { width: 100%; max-width: 230px; margin-left: auto; }
  .hero-copy { padding: 0; }
  .header-motto { display: none; }
  .theme-toggle { margin-left: auto; }
  .menu-item { font-size: 1.25rem; }
  .page-layout { grid-template-columns: 220px minmax(0, 1fr); }
  .record-grid { grid-template-columns: 1fr; }
}
@media (max-width: 700px) {
  body { padding: 12px; }
  .terminal-shell { box-shadow: 0 0 0 3px var(--surface), 0 0 0 4px var(--soft-line); }
  .site-header { min-height: 66px; gap: 7px; padding: 8px 12px; }
  .brand { font-size: .9375rem; }
  .theme-toggle { font-size: .75rem; padding: 4px 8px; }
  .menu-label { display: none; }
  .menu-toggle { font-size: 1.4rem; }
  .header-menu { right: 8px; width: calc(100vw - 44px); }
  main { padding: 12px; }
  .hero { min-height: 280px; padding: 18px 10px 14px; gap: 8px; grid-template-columns: 1.2fr 1fr; align-items: start; border: none; }
  .hero-label { font-size: .75rem; letter-spacing: .04em; margin-bottom: 17px; }
  .hero-heading { grid-column: 1 / -1; position: relative; z-index: 1; pointer-events: none; }
  .hero-heading .enter-link { pointer-events: auto; }
  .pixel-title { display: flex; flex-direction: column; align-items: flex-start; gap: 9px; max-width: 250px; }
  .pixel-title svg { height: clamp(30px, 9.2vw, 52px); }
  .enter-link { font-size: 1.0625rem; margin-top: 8px; }
  .hero-world { grid-column: 1 / -1; width: 100%; margin-top: 0; flex-direction: row; align-items: flex-end; gap: 5px; }
  .hero-copy { order: 0; font-size: .875rem; line-height: 1.65; padding-top: 0; min-width: 42%; white-space: normal; }
  .hero-copy .copy-end { display: block; max-width: 150px; }
  .hero-world .art-wrap { width: 56%; max-width: 220px; align-self: flex-end; margin-left: auto; }
  .dashboard { grid-template-columns: 1fr; margin-top: 9px; gap: 12px; }
  .panel { padding: 12px; }
  .panel-heading { margin-bottom: 10px; padding-bottom: 7px; font-size: .875rem; }
  .menu-item { min-height: 48px; font-size: 1.1875rem; padding: 5px 9px; }
  .menu-meta { padding-top: 12px; margin-top: 12px; }
  .welcome { font-size: 1.375rem; }
  .welcome-break { display: initial; }
  .information-copy { font-size: 1rem; }
  .information .art-wrap { max-width: 420px; width: 100%; margin: 10px auto; }
  .info-signature { font-size: .75rem; }
  .right-deck { grid-column: auto; grid-template-columns: 1fr 1fr; gap: 12px; }
  .status { grid-column: 1 / -1; }
  .status dl { font-size: .9375rem; }
  .mission-list { font-size: 1rem; }
  .mascot-panel { grid-column: 1 / -1; flex-direction: row; align-items: center; justify-content: space-between; }
  .mascot-panel .panel-heading { width: 100%; }
  .mascot-stage { margin: 4px 0; }
  .cat-art { width: 58px; }
  .cat-bubble { font-size: .75rem; }
  .mascot-caption { font-size: .75rem; margin-left: auto; }
  .sectors { grid-column: 1; }
  .unlocks { grid-column: 2; }
  .sector-link { min-height: 42px; }
  .sectors .sector-link { font-size: .875rem; overflow-wrap: anywhere; }
  .unlocks .unlock-link { font-size: .875rem; min-height: 44px; }
  .sectors .panel-heading, .unlocks .panel-heading { font-size: .8125rem; }
  .site-footer { gap: 12px; padding: 14px 12px; }
  .footer-brand { font-size: .8125rem; }
  .footer-verbs { margin-left: auto; font-size: .75rem; }
  .footer-verbs i { padding: 0 4px; }
  .footer-meta { width: 100%; text-align: left; display: flex; justify-content: space-between; font-size: .75rem; }
  .page-intro { padding: 20px 14px; flex-direction: column; align-items: flex-start; }
  .page-title { font-size: 2rem; }
  .page-layout { display: block; }
  .page-layout .menu-panel { display: none; }
  .page-content { margin-top: 0; }
  .record { padding: 18px; }
  .section-title small { display: block; margin: 5px 0 0; }
}
@media (max-width: 360px) {
  .brand { font-size: .8125rem; }
  .hero { padding-left: 3px; padding-right: 3px; }
  .right-deck { grid-template-columns: 1fr; }
  .right-deck > * { grid-column: 1; }
  .sector-link small { display: block; }
  .footer-verbs { margin-left: 0; }
}
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }
@media print { body { padding: 0; } .terminal-shell::after, .theme-toggle, .menu-toggle { display: none; } }

/* v1.0 visitor pages — the terminal frame and pixel decorations remain from v0.2. */
.enter-hint { color: var(--muted); font: .75rem/1.4 var(--sans); }
.information-actions { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 16px; }
.action-link { display: inline-flex; align-items: center; justify-content: space-between; gap: 16px; min-height: 44px; padding: 8px 14px; border: 1px solid var(--line); font-size: .875rem; line-height: 1.6; background: transparent; overflow-wrap: anywhere; }
.action-link > span[aria-hidden] { flex: none; font-family: var(--mono); }
.action-link:hover { background: var(--hover); color: var(--strong); }
.primary-action { background: var(--active); color: var(--active-ink); border-color: var(--active); }
.primary-action:hover { background: var(--strong); color: var(--active-ink); }
.text-link { display: inline-flex; align-items: center; min-height: 44px; font-size: .875rem; text-decoration: underline; text-underline-offset: 5px; }
.text-link:hover { color: var(--strong); }
.mission-list a { display: inline-block; min-height: 36px; text-underline-offset: 4px; }
.mission-list a:hover { text-decoration: underline; }
.unlock-link time { display: block; font: .6875rem/1.5 var(--mono); color: var(--muted); margin: 2px 0 5px 14px; }
.entry-strip { display: flex; flex-wrap: wrap; align-items: center; gap: 16px; border-top: 1px solid var(--line); padding: 24px 0 4px; margin-top: 28px; }
.entry-strip p { flex: 1; min-width: 220px; color: var(--muted); font-size: .9375rem; }
.entry-strip .eyebrow { display: block; }
.breadcrumbs { margin: 0 0 16px; color: var(--muted); font-size: .8125rem; }
.breadcrumbs ol { display: flex; flex-wrap: wrap; gap: 6px 10px; }
.breadcrumbs li { display: inline-flex; gap: 10px; align-items: baseline; overflow-wrap: anywhere; min-width: 0; }
.breadcrumbs li + li::before { content: '/'; color: var(--line); }
.breadcrumbs a { padding: 6px 0; }
.breadcrumbs a:hover { color: var(--strong); text-decoration: underline; }
.detail-title { font-family: var(--sans); font-size: clamp(1.625rem, 3.3vw, 2.75rem); line-height: 1.45; }
.page-content { min-width: 0; }
.page-layout { align-items: start; }
.page-layout > .menu-panel { position: sticky; top: 24px; }
.page-layout .menu-meta { margin-top: 30px; }
.page-end { display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap; gap: 16px; padding: 24px 0 0; margin-top: 32px; border-top: 1px solid var(--soft-line); }
.page-end > span { color: var(--muted); font: .6875rem/1.5 var(--mono); }
.catalog-toolbar { border: 1px solid var(--soft-line); padding: 18px; }
.filter-tabs { display: flex; flex-wrap: wrap; gap: 8px; }
.filter-tabs a { display: inline-flex; align-items: center; justify-content: center; min-height: 44px; border: 1px solid var(--soft-line); padding: 7px 15px; font-size: .875rem; }
.filter-tabs a:hover { background: var(--hover); border-color: var(--line); }
.filter-tabs a[aria-current="true"] { background: var(--active); color: var(--active-ink); border-color: var(--active); font-weight: 600; }
.catalog-search { margin-top: 18px; }
.catalog-search label { display: block; color: var(--muted); font-size: .8125rem; margin-bottom: 6px; }
.catalog-search > div { display: flex; gap: 8px; }
.catalog-search input { width: 100%; min-width: 0; min-height: 46px; border: 1px solid var(--line); color: var(--ink); background: var(--surface); border-radius: 0; padding: 8px 12px; font-size: 1rem; }
.catalog-search input::placeholder { color: var(--muted); opacity: 1; }
.catalog-search button { padding: 8px 18px; min-height: 46px; border: 1px solid var(--line); background: var(--hover); font-size: .875rem; flex-shrink: 0; }
.catalog-search button:hover { background: var(--active); color: var(--active-ink); }
.catalog-result { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 10px; align-items: center; color: var(--muted); font-size: .8125rem; margin: 12px 0 20px; min-height: 44px; }
.catalog-result p { overflow-wrap: anywhere; }
.project-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; }
.project-card { border: 1px solid var(--line); min-width: 0; display: flex; flex-direction: column; background: var(--panel); }
.project-marker { display: flex; justify-content: space-between; align-items: center; padding: 15px 20px; min-height: 82px; border-bottom: 1px solid var(--soft-line); color: var(--muted); background: repeating-linear-gradient(90deg, transparent 0 15px, var(--scanline) 15px 16px); }
.project-marker > span { font: .6875rem/1.5 var(--mono); text-transform: uppercase; letter-spacing: .065em; }
.sector-glyph { fill: var(--ink); width: 38px; height: 38px; shape-rendering: crispEdges; opacity: .8; flex-shrink: 0; margin-left: 12px; }
.project-copy { padding: 22px; display: flex; flex-direction: column; align-items: start; flex: 1; min-width: 0; }
.file-state { color: var(--muted); font: .6875rem/1.5 var(--mono); display: inline-block; margin-bottom: 12px; }
.file-state:not(.pending-state)::before { content: ''; display: inline-block; width: 5px; height: 5px; background: var(--ink); margin-right: 8px; }
.project-copy h3 { font: 600 1.1875rem/1.6 var(--sans); color: var(--strong); overflow-wrap: anywhere; }
.project-copy h3 a:hover { text-decoration: underline; text-underline-offset: 5px; }
.project-tagline { font-size: .9375rem; margin-top: 12px; }
.project-description { font-size: .875rem; color: var(--muted); margin-top: 8px; }
.tag-list { display: flex; flex-wrap: wrap; gap: 6px; margin: 16px 0 20px; }
.tag-list li { border: 1px solid var(--soft-line); color: var(--muted); padding: 2px 7px; font-size: .6875rem; }
.card-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 12px; margin-top: auto; padding-top: 8px; }
.empty-state { grid-column: 1/-1; padding: 34px 24px; border: 1px solid var(--soft-line); }
.empty-state h2 { font-size: 1.25rem; font-weight: 500; }
.empty-state p:not(.eyebrow) { color: var(--muted); margin: 12px 0 22px; }
.detail-panel { border: 1px solid var(--line); padding: 32px; background: var(--panel); }
.detail-meta { border-bottom: 1px solid var(--soft-line); margin-bottom: 26px; }
.reading-copy { font-size: 1.0625rem; line-height: 1.95; max-width: 65ch; }
.reading-copy p + p { margin-top: 20px; }
.detail-actions { display: flex; flex-wrap: wrap; gap: 12px; align-items: center; margin-top: 28px; }
.detail-actions .pending { margin: 0; min-height: 44px; display: inline-flex; align-items: center; padding: 8px 14px; }
.related-note { border-top: 1px solid var(--soft-line); margin-top: 30px; padding-top: 22px; }
.related-note .eyebrow { margin-bottom: 0; }
.related-projects { margin-top: 36px; }
.current-lead { border: 1px solid var(--line); padding: 26px 30px; }
.current-lead h2 { font: 500 clamp(1.375rem, 2vw, 1.875rem)/1.6 var(--sans); color: var(--strong); margin: 8px 0 16px; }
.current-lead > p:last-child { color: var(--muted); max-width: 62ch; }
.quest { display: grid; grid-template-columns: 52px minmax(0, 1fr); gap: 18px; padding: 30px 12px; border-bottom: 1px solid var(--line); scroll-margin-top: 24px; }
.quest-number { font: 2rem/1.4 var(--mono); color: var(--line); }
.quest h2 { font-size: 1.375rem; font-weight: 500; color: var(--strong); }
.quest p:not(.eyebrow) { color: var(--muted); margin: 12px 0 18px; }
.about-terminal { padding: 30px; margin-top: 32px; border: 1px solid var(--soft-line); }
.about-terminal > p { color: var(--muted); }
.about-terminal .about-signature { margin: 18px 0; font: .6875rem/1.7 var(--mono); }
.log-list { margin-top: 22px; border-top: 1px solid var(--line); }
.log-row { display: grid; grid-template-columns: minmax(110px, .35fr) minmax(0, 1fr); gap: 24px; padding: 26px 14px; border-bottom: 1px solid var(--soft-line); }
.log-meta { font: .6875rem/1.7 var(--mono); color: var(--muted); display: flex; flex-direction: column; gap: 6px; }
.log-row h2 { font-size: 1.25rem; font-weight: 500; line-height: 1.6; overflow-wrap: anywhere; color: var(--strong); }
.log-row h2 a:hover { text-decoration: underline; text-underline-offset: 6px; }
.log-row p { margin-top: 9px; color: var(--muted); font-size: .9375rem; }
.log-row .text-link { margin-top: 8px; }
.record-navigation { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 12px; padding-top: 22px; }
.record-navigation .action-link { max-width: 100%; }
.link-group + .link-group { margin-top: 32px; }
.group-description { color: var(--muted); margin: -6px 0 18px; font-size: .9375rem; }
.link-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; }
.link-card { border: 1px solid var(--line); padding: 24px; display: flex; flex-direction: column; align-items: flex-start; min-width: 0; }
.link-card h3 { font-size: 1.1875rem; font-weight: 500; overflow-wrap: anywhere; }
.link-card p { color: var(--muted); margin: 10px 0 24px; }
.link-card .action-link, .link-card .pending { margin-top: auto; }
@media (max-width: 1100px) { .project-grid, .link-grid { grid-template-columns: 1fr; } .project-copy { padding: 20px; } }
@media (max-width: 700px) {
  .enter-link { flex-wrap: wrap; column-gap: 10px; }
  .enter-hint { width: 100%; margin: -4px 0 4px; }
  .entry-strip { padding-top: 18px; gap: 12px; }
  .entry-strip p { min-width: 100%; }
  .entry-strip .action-link { flex: 1; }
  .page-layout > .menu-panel { position: static; }
  .page-layout .main-menu { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 5px; }
  .page-layout .menu-item { font-size: .8125rem; min-height: 44px; gap: 5px; padding: 5px 6px; overflow-wrap: anywhere; }
  .page-layout .menu-meta { display: none; }
  .page-layout .menu-panel { margin-bottom: 22px; }
  .page-title { overflow-wrap: anywhere; }
  .page-end > span { width: 100%; }
  .catalog-toolbar { padding: 12px; }
  .filter-tabs { gap: 6px; }
  .filter-tabs a { padding: 7px 12px; }
  .catalog-search button { padding: 8px 12px; }
  .project-marker { min-height: 68px; }
  .detail-panel { padding: 22px 18px; }
  .reading-copy { font-size: 1rem; }
  .current-lead, .about-terminal { padding: 22px 18px; }
  .quest { grid-template-columns: 34px minmax(0, 1fr); gap: 10px; padding: 26px 4px; }
  .quest-number { font-size: 1.5rem; }
  .quest h2 { font-size: 1.1875rem; }
  .log-row { grid-template-columns: 1fr; gap: 10px; padding: 22px 4px; }
  .log-meta { flex-direction: row; flex-wrap: wrap; gap: 6px 14px; }
  .log-row h2 { font-size: 1.125rem; }
  .link-card { padding: 22px 18px; }
  .record-navigation { flex-direction: column; }
  .record-navigation > span:empty { display: none; }
}
@media (max-width: 360px) { .right-deck .sectors, .right-deck .unlocks { grid-column: 1/-1; } }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }
