:root {
  --bg: #fbfaf7;
  --surface: #ffffff;
  --text: #1c1b1a;
  --muted: #62605b;
  --line: #e5e2db;
  --accent: #1f6f5c;
  --accent-ink: #ffffff;
  --retro: #e0407a;
}
@media (prefers-color-scheme: dark) {
  :root {
    --bg: #131312;
    --surface: #1c1c1a;
    --text: #f1efe9;
    --muted: #a5a299;
    --line: #2d2d2a;
    --accent: #5cc4a8;
    --accent-ink: #0b1f1a;
    --retro: #ff6fa3;
  }
}
* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font: 17px/1.65 system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
}
a { color: var(--accent); }
.wrap { max-width: 880px; margin: 0 auto; padding: 0 20px; }
header.site { border-bottom: 1px solid var(--line); }
header.site .wrap { display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: 8px 24px; padding-top: 16px; padding-bottom: 16px; }
.brand { font-weight: 800; font-size: 1.35rem; letter-spacing: -0.02em; color: var(--text); text-decoration: none; }
nav a { color: var(--muted); text-decoration: none; margin-right: 18px; font-size: 0.95rem; }
nav a:last-child { margin-right: 0; }
nav a:hover, nav a[aria-current] { color: var(--text); }
h1 { font-size: clamp(2rem, 6vw, 3rem); line-height: 1.15; letter-spacing: -0.03em; margin: 0 0 16px; }
h2 { font-size: 1.4rem; margin: 40px 0 8px; letter-spacing: -0.01em; }
h3 { font-size: 1.1rem; margin: 28px 0 4px; }
.hero { padding: 64px 0 24px; }
.lede { font-size: 1.2rem; color: var(--muted); max-width: 40em; }
.cards { display: grid; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); gap: 20px; margin: 32px 0; }
.card { background: var(--surface); border: 1px solid var(--line); border-radius: 18px; padding: 24px; display: flex; flex-direction: column; gap: 8px; }
.card img { width: 72px; height: 72px; border-radius: 16px; }
.card h2 { margin: 8px 0 0; }
.card p { margin: 0; color: var(--muted); }
.card .links { margin-top: auto; padding-top: 12px; }
.btn { display: inline-block; background: var(--accent); color: var(--accent-ink); padding: 11px 20px; border-radius: 999px; text-decoration: none; font-weight: 600; margin-right: 12px; }
.badge { display: inline-block; font-size: 0.8rem; font-weight: 600; padding: 2px 10px; border-radius: 999px; border: 1px solid var(--line); color: var(--muted); }
.principles { list-style: none; padding: 0; display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 16px; }
.principles li { background: var(--surface); border: 1px solid var(--line); border-radius: 14px; padding: 16px 18px; }
.principles strong { display: block; }
.app-head { display: flex; gap: 20px; align-items: center; padding: 56px 0 8px; flex-wrap: wrap; }
.app-head img { width: 96px; height: 96px; border-radius: 22px; }
.app-head h1 { margin: 0; }
ul.ticks { padding-left: 1.2em; }
ul.ticks li { margin: 6px 0; }
.note { background: var(--surface); border: 1px solid var(--line); border-left: 4px solid var(--accent); border-radius: 10px; padding: 14px 18px; }
.retro h1, .retro .brandline { font-family: "Courier New", ui-monospace, monospace; text-transform: uppercase; letter-spacing: 0.02em; }
.retro .btn { background: var(--retro); color: #fff; }
.retro .note { border-left-color: var(--retro); }
.prose { padding: 48px 0 24px; max-width: 42em; }
.prose h1 { font-size: clamp(1.8rem, 5vw, 2.4rem); }
.updated { color: var(--muted); font-size: 0.95rem; }
.form-frame { width: 100%; height: 900px; border: 1px solid var(--line); border-radius: 14px; background: #fff; }
.crumbs { font-size: 0.92rem; color: var(--muted); padding: 20px 0 0; margin: 0; }
.crumbs a { color: var(--muted); }
.shot { margin: 20px 0; }
.shot img { display: block; width: 100%; height: auto; border-radius: 12px; border: 1px solid var(--line); background: #000; }
.shot figcaption { font-size: 0.9rem; color: var(--muted); margin-top: 6px; }
.shots { display: grid; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); gap: 16px; margin: 20px 0; }
.shots .shot { margin: 0; }
.tablewrap { overflow-x: auto; }
table { border-collapse: collapse; width: 100%; margin: 12px 0; }
th, td { text-align: left; padding: 8px 12px; border-bottom: 1px solid var(--line); vertical-align: top; }
th { color: var(--muted); font-weight: 600; font-size: 0.92rem; }
.retro .card h2 { font-family: "Courier New", ui-monospace, monospace; text-transform: uppercase; }
.retro .card.game img.thumb { width: 100%; height: auto; border-radius: 10px; border: 1px solid var(--line); background: #000; }
footer.site { border-top: 1px solid var(--line); margin-top: 64px; padding: 28px 0 40px; color: var(--muted); font-size: 0.92rem; }
footer.site a { color: var(--muted); margin-right: 16px; }
footer.site p.emails { line-height: 1.8; }
footer.site p.emails a { margin-right: 0; text-decoration: underline; }
.prose h2 { margin-top: 44px; }
.prose blockquote { margin: 20px 0; padding: 4px 18px; border-left: 4px solid var(--accent); color: var(--muted); }
.shots.phones { grid-template-columns: repeat(auto-fit, minmax(140px, 200px)); justify-content: start; }
.withshot { display: flex; gap: 24px; align-items: flex-start; }
.withshot > div { flex: 1; min-width: 0; }
.withshot > figure { flex: 0 0 200px; margin: 8px 0 0; }
.shot.narrow { max-width: 300px; }
@media (max-width: 600px) { .withshot { flex-direction: column; } .withshot > figure { flex: none; width: 200px; } }
ol.toc { columns: 2; column-gap: 32px; padding-left: 1.4em; }
ol.toc li { margin: 4px 0; break-inside: avoid; }
@media (max-width: 600px) { ol.toc { columns: 1; } }
code { background: var(--surface); border: 1px solid var(--line); border-radius: 4px; padding: 0 4px; }
.brand img { display: block; height: 34px; width: auto; }
