:root{--bg:#f6f6f4;--machine:#222127;--slot:#171717;--paper:#ffffff;--ink:#2b2b2b;--muted:#828282;--rule:#e5e5e1;--line:#e5e5e1;--button:#aaaaaa;--shadow:0 8px 20px #17171718;--serif:"Noto Serif SC","Songti SC",Georgia,serif;--mono:"JetBrains Mono","SFMono-Regular",Consolas,monospace}*{box-sizing:border-box}html{scroll-behavior:smooth}body{margin:0;min-height:100vh;overflow-x:hidden;background:var(--bg);color:var(--ink);font-family:var(--serif);transition:background .25s,color .25s}button,input{font:inherit}.printer-top{height:66px;position:fixed;inset:0 0 auto;z-index:60;display:flex;align-items:flex-end;justify-content:center;background:var(--machine);border-bottom:0;box-shadow:0 8px 24px #1118}.printer-top:before,.printer-top:after{content:"";position:absolute;top:66px;width:calc(50% - 17.25rem);height:14px;background:var(--machine);border-bottom:0;box-shadow:0 5px 16px #1115}.printer-top:before{left:0}.printer-top:after{right:0}.actions{display:flex;gap:12px;margin-bottom:14px;position:relative;z-index:2}.action-btn{text-decoration:none;width:36px;height:36px;padding:8px;border:1px solid #ffffff0a;border-radius:50%;display:grid;place-items:center;background:#ffffff05;color:var(--button);cursor:pointer;transition:color .18s,border-color .18s,background .18s,transform .18s}.action-btn:focus-visible{outline:2px solid #aaa;outline-offset:3px}.action-btn:hover,.action-btn[aria-pressed="true"]{color:#fff;border-color:#ffffff28;background:#ffffff12;transform:translateY(-1px)}.action-btn svg{width:18px;height:18px;fill:none;stroke:currentColor;stroke-width:1.65;stroke-linecap:round;stroke-linejoin:round}.slot-bg,.slot-overlay{position:fixed;top:66px;left:50%;transform:translateX(-50%);width:min(34.5rem,100%);height:14px;pointer-events:none}.slot-bg{z-index:40;background:var(--slot)}.slot-overlay{z-index:65;border:0;border-radius:6px 6px 0 0;background:linear-gradient(to bottom,#171a18aa 0%,#14171555 38%,transparent 100%);box-shadow:inset 0 5px 9px #0008,0 7px 14px #10141144}.slot-lip{position:absolute;left:0;bottom:0;width:100%;height:6px;background:linear-gradient(#505653,#303633);border-top:1px solid #72797055;box-shadow:0 -2px 5px #10141066}.paper{position:relative;z-index:50;width:min(32rem,100%);min-height:0;margin:66px auto 0;padding:0 48px 18px;background-color:var(--paper);color:var(--ink);box-shadow:var(--shadow);background-image:url("data:image/svg+xml,%3Csvg viewBox='0 0 180 180' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.8' numOctaves='3' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)' opacity='.018'/%3E%3C/svg%3E")}.paper-head{text-align:center;padding:44px 0 24px;border-bottom:1px dashed var(--rule)}.brand{margin:0;font:500 13px/1.4 var(--mono);letter-spacing:.24em}.subtitle{margin:7px 0 0;color:#98948a;font:9px var(--mono);letter-spacing:.14em}.year{margin:12px 0 0;color:#895b4e;font:11px var(--mono);letter-spacing:.12em}.entries{padding:4px 0 0}.entry{padding:24px 0 26px;border-bottom:1px dashed var(--line);scroll-margin-top:98px}.entry-meta{display:flex;justify-content:space-between;gap:12px;margin-bottom:13px;color:#79776e;font:10px var(--mono);letter-spacing:.04em}.entry-title{margin:17px 0 9px;font:500 13px/1.6 var(--mono);letter-spacing:.035em;color:#5f5e56}.entry-title:first-child{margin-top:0}.entry a{color:inherit;text-decoration:underline;text-underline-offset:3px}.entry p{margin:0 0 13px;color:#33332e;font-size:14px;line-height:2;letter-spacing:.008em;overflow-wrap:anywhere}.entry p:last-child{margin-bottom:0}.entry ul,.entry ol{margin:0 0 13px;padding-left:22px;color:var(--ink);font-size:14px;line-height:2}.entry li{padding-left:2px;overflow-wrap:anywhere}.dark-theme .entry ul,.dark-theme .entry ol{color:#d7d7d2}.entry[hidden]{display:none}.empty{padding:40px 0;text-align:center;color:var(--muted);font:11px/1.9 var(--mono)}.entry:last-child{padding-bottom:14px}.receipt-end{text-align:center;padding:16px 0 2px;color:#969287;font:9px/1.9 var(--mono);letter-spacing:.12em}.year-link{display:flex;align-items:center;justify-content:center;gap:9px;width:max-content;max-width:100%;margin:12px auto 0;padding:8px 13px;border:1px solid #cbc7bc;color:#66645c;text-decoration:none;font:10px var(--mono);letter-spacing:.04em;transition:.18s}.year-link:hover{background:#282823;color:#f4f3ee;border-color:#282823}.year-link svg{width:13px;height:13px;stroke:currentColor;fill:none;stroke-width:1.5}.overlay{position:fixed;inset:0;z-index:200;display:none;align-items:center;justify-content:center;padding:20px;background:#0009;backdrop-filter:blur(4px)}.overlay.open{display:flex}.dialog{position:relative;width:min(440px,100%);max-height:min(80vh,680px);overflow:auto;padding:30px;background:#f4f3ee;color:#24241f;box-shadow:0 25px 60px #0008;transform:translateY(7px);animation:modalIn .2s ease forwards}.dialog-head{display:flex;align-items:center;justify-content:space-between;margin-bottom:18px;color:#77766e;font:10px var(--mono);letter-spacing:.12em}.close{border:0;background:transparent;color:inherit;font-size:20px;cursor:pointer;line-height:1}.dialog h2{margin:0 0 13px;text-align:center;font:500 13px var(--mono);letter-spacing:.16em}.dialog p{font-size:13px;line-height:1.9;color:#5c5a52}.dialog a{color:#45443e;text-underline-offset:3px}.social{display:flex;justify-content:center;gap:18px;margin-top:18px;font:10px var(--mono)}.dialog-note{display:block;margin-top:22px;text-align:center;color:#99958b;font:9px var(--mono);letter-spacing:.13em}.search-dialog{padding:24px 26px}.search-input{width:100%;padding:13px 1px;border:0;border-bottom:1px solid #aaa69b;background:transparent;color:inherit;outline:none;font:14px var(--serif)}.search-input::placeholder{color:#98948a}.search-input::-webkit-search-cancel-button,.search-input::-webkit-search-decoration{-webkit-appearance:none;appearance:none;display:none}.search-results{max-height:none;overflow:visible;margin-top:12px}.result{display:block;padding:12px 0;border-bottom:1px dashed #d0ccc1;color:inherit;text-decoration:none}.result:hover .result-title{color:#000;text-decoration:underline;text-underline-offset:3px}.dark-theme .result:hover .result-title{color:#fff;text-decoration:underline;text-underline-offset:3px}.result-meta{display:flex;gap:10px;color:#88857b;font:9px var(--mono)}.result-title{display:block;margin-top:5px;font-size:12px}.result-excerpt{display:block;margin-top:4px;color:#77746b;font-size:11px;line-height:1.6}.search-message{padding:16px 0;color:#88857b;font:10px var(--mono)} .dark-theme{--bg:#171717;--machine:#101010;--slot:#080808;--paper:#1d1d1d;--ink:#d6d6d6;--muted:#7a7a7a;--rule:#2e2e2e;--line:#2e2e2e;--shadow:0 4px 14px #0009}.dark-theme .paper{background-image:url("data:image/svg+xml,%3Csvg viewBox='0 0 180 180' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.8' numOctaves='3' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)' opacity='.018' fill='%23fff'/%3E%3C/svg%3E")}.dark-theme .entry p{color:#d7d7d2}.dark-theme .entry-title{color:#c0bfb7}.dark-theme .entry-meta,.dark-theme .year{color:#7a7a7a}.dark-theme .year-link{border-color:#55554e;color:#c9c8c1}.dark-theme .year-link:hover{background:#eee;color:#111}.dark-theme .dialog{background:#181818;color:#e6e6e1;border:1px solid #333}.dark-theme .dialog p,.dark-theme .dialog a{color:#c9c8c1}.dark-theme .search-input{border-color:#555}.dark-theme .result{border-color:#393934}.dark-theme .result-title{color:#e6e6e1}.dark-theme .result-excerpt,.dark-theme .result-meta{color:#aaa99f}.dark-theme .search-message{color:#aaa99f}.dark-theme .overlay{background:#000b}@keyframes printOut{from{transform:translateY(-12px)}to{transform:translateY(0)}}.paper.is-printing{animation:printOut .34s cubic-bezier(.2,.75,.25,1)}@keyframes modalIn{to{transform:translateY(0)}}@media(max-width:552px){.printer-top:before,.printer-top:after{display:none}.slot-overlay{border-radius:0}}@media(max-width:560px){.paper{padding:0 25px 14px}.paper-head{padding-top:37px}.entry{padding:22px 0 23px}.entry p{font-size:13px;line-height:1.95}.dialog{padding:25px 22px}.search-dialog{padding:21px 22px}.search-input{width:88%;display:block;margin-inline:auto}}@media(prefers-reduced-motion:reduce){*,*::before,*::after{scroll-behavior:auto!important;animation:none!important;transition:none!important}}@media print{@page{margin:14mm}body, .dark-theme{background:#fff!important;color:#000!important}.printer-top,.slot-bg,.slot-overlay,.overlay{display:none!important}.paper,.dark-theme .paper{width:100%;min-height:0;margin:0;padding:0;box-shadow:none;background:#fff!important;color:#000!important;animation:none}.entry p,.entry-title,.entry-meta{color:#111!important}.entry{break-inside:avoid}.year-link{display:none!important}}





/* Palette adapted from posts.css; color overrides only. */
:root {
  color-scheme: light;
  --bg: #e8e7e3;
  --machine: #24232a;
  --slot: #15151b;
  --paper: #f3f2ee;
  --ink: #1c1b22;
  --muted: #65626f;
  --rule: rgba(28, 27, 34, .14);
  --line: rgba(28, 27, 34, .14);
  --button: #cfc9bc;
  --shadow: 0 1px 0 rgba(0,0,0,.04), 0 18px 40px -24px rgba(20,18,30,.35);
  --accent: #94440f;
}
.paper, .dark-theme .paper {
  background-color: var(--paper);
  background-image: none;
}
.subtitle { color: #65626f; }
.year { color: #94440f; }
.entry-meta { color: #65626f; }
.entry-title { color: #3a3844; }
.entry p, .entry ul, .entry ol { color: #1c1b22; }
.receipt-end { color: #65626f; }
.year-link { border-color: rgba(28,27,34,.22); color: #94440f; }
.year-link:hover { background: #94440f; color: #fff; border-color: #94440f; }
.action-btn:focus-visible { outline-color: #ffb867; }
.action-btn:hover, .action-btn[aria-pressed="true"] { color: #ffb867; border-color: rgba(255,184,103,.42); }
.slot-overlay {
  background: linear-gradient(to bottom, rgba(21,21,27,.72), rgba(21,21,27,.28) 42%, transparent 100%);
  box-shadow: inset 0 5px 9px rgba(0,0,0,.42), 0 7px 14px rgba(20,18,30,.2);
}
.slot-lip {
  background: linear-gradient(#5b5960, #34323a);
  border-top-color: rgba(243,242,238,.2);
  box-shadow: 0 -2px 5px rgba(20,18,30,.35);
}
.dialog { background: #f3f2ee; color: #1c1b22; }
.dialog-head { color: #65626f; }
.dialog p { color: #3a3844; }
.dialog a, .result-title { color: #94440f; }
.search-input { border-color: rgba(28,27,34,.28); }
.search-input::placeholder, .result-excerpt, .result-meta, .search-message { color: #65626f; }
.result { border-color: rgba(28,27,34,.14); }
.result:hover .result-title { color: #71340e; }
.dark-theme {
  color-scheme: dark;
  --bg: #08090e;
  --machine: #101116;
  --slot: #050507;
  --paper: #0e0f16;
  --ink: #ebe6da;
  --muted: #9a97a6;
  --rule: rgba(255,255,255,.12);
  --line: rgba(255,255,255,.12);
  --button: #cfc9bc;
  --shadow: 0 0 0 1px rgba(255,255,255,.04), 0 30px 60px -30px rgba(0,0,0,.9);
  --accent: #ffb867;
}
.dark-theme .paper { background-color: var(--paper); background-image: none; }
.dark-theme .subtitle, .dark-theme .entry-meta { color: #9a97a6; }
.dark-theme .year, .dark-theme .dialog a, .dark-theme .result-title { color: #ffb867; }
.dark-theme .entry-title, .dark-theme .entry ul, .dark-theme .entry ol { color: #cfc9bc; }
.dark-theme .entry p { color: #ebe6da; }
.dark-theme .receipt-end { color: #9a97a6; }
.dark-theme .year-link { border-color: rgba(255,255,255,.2); color: #ffb867; }
.dark-theme .year-link:hover { background: #ffb867; color: #0b0a08; border-color: #ffb867; }
.dark-theme .slot-overlay {
  background: linear-gradient(to bottom, rgba(5,5,7,.78), rgba(5,5,7,.32) 42%, transparent 100%);
  box-shadow: inset 0 5px 9px rgba(0,0,0,.58), 0 7px 14px rgba(0,0,0,.34);
}
.dark-theme .slot-lip {
  background: linear-gradient(#353640, #20212a);
  border-top-color: rgba(235,230,218,.16);
  box-shadow: 0 -2px 5px rgba(0,0,0,.5);
}
.dark-theme .dialog { background: #0e0f16; color: #ebe6da; border-color: rgba(255,255,255,.12); }
.dark-theme .dialog-head, .dark-theme .dialog p, .dark-theme .result-excerpt, .dark-theme .result-meta, .dark-theme .search-message { color: #cfc9bc; }
.dark-theme .search-input { border-color: rgba(255,255,255,.2); color: #ebe6da; }
.dark-theme .search-input::placeholder { color: #9a97a6; }
.dark-theme .result { border-color: rgba(255,255,255,.12); }
.dark-theme .result:hover .result-title { color: #ffd196; }
.dark-theme .overlay { background: rgba(0,0,0,.78); }

/* Long-receipt rendering: defer paint for diary entries outside the viewport. */
.entry {
  content-visibility: auto;
  contain-intrinsic-size: auto 28rem;
}

/* Public life HUD above the receipt printer. */
body.has-life-hud { --life-hud-height: 62px; }
.life-hud {
  position: fixed;
  z-index: 70;
  inset: 0 0 auto;
  height: var(--life-hud-height);
  display: flex;
  align-items: center;
  border-bottom: 1px solid var(--rule);
  background: var(--bg);
  color: var(--ink);
}
.life-hud-inner {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  align-items: center;
  width: min(900px, 100%);
  height: 100%;
  margin: 0 auto;
  padding: 0 20px;
}
.life-stat {
  min-width: 0;
  padding: 0 16px;
  border-right: 1px solid var(--line);
}
.life-stat:first-child { padding-left: 0; }
.life-stat:last-child { padding-right: 0; border-right: 0; }
.life-stat-label {
  display: block;
  overflow: hidden;
  color: var(--muted);
  font: 9px/1.3 var(--mono);
  letter-spacing: .08em;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.life-stat-value {
  display: block;
  overflow: hidden;
  margin-top: 4px;
  color: var(--ink);
  font: 600 14px/1.1 var(--mono);
  font-variant-numeric: tabular-nums;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.life-stat[data-kind="debt"] .life-stat-value { color: #94440f; }
.life-stat[data-kind="savings"] .life-stat-value,
.life-stat[data-kind="expense"] .life-stat-value { color: #94440f; }
.life-stat[data-kind="income"] .life-stat-value { color: #527b5e; }
.life-hud-status { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
body.has-life-hud .printer-top { top: var(--life-hud-height); }
body.has-life-hud .slot-bg,
body.has-life-hud .slot-overlay { top: calc(66px + var(--life-hud-height)); }
body.has-life-hud .paper { margin-top: calc(66px + var(--life-hud-height)); }
.dark-theme .life-stat[data-kind="debt"] .life-stat-value,
.dark-theme .life-stat[data-kind="savings"] .life-stat-value,
.dark-theme .life-stat[data-kind="expense"] .life-stat-value { color: #ffb867; }
.dark-theme .life-stat[data-kind="income"] .life-stat-value { color: #9dd3a9; }
@media (max-width: 600px) {
  body.has-life-hud { --life-hud-height: 88px; }
  .life-hud-inner { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0; padding: 6px 15px; }
  .life-stat { padding: 4px 10px; border-right: 1px solid var(--line); }
  .life-stat:nth-child(2n) { border-right: 0; }
  .life-stat:nth-child(-n+2) { border-bottom: 1px solid var(--line); }
  .life-stat:first-child, .life-stat:nth-child(3) { padding-left: 0; }
  .life-stat:nth-child(2), .life-stat:last-child { padding-right: 0; }
  .life-stat-value { margin-top: 2px; font-size: 13px; }
}
@media print {
  .life-hud { display: none !important; }
  body.has-life-hud .paper { margin-top: 0 !important; }
}

/* Printer control panel: four recessed monochrome displays. */
.life-hud {
  border-bottom: 1px solid rgba(255,255,255,.08);
  background: linear-gradient(180deg, #292a30 0%, #202126 100%);
  color: #e8e4da;
  box-shadow: 0 5px 14px rgba(0,0,0,.18);
}
.life-hud-inner { gap: 8px; }
.life-stat,
.life-stat:first-child,
.life-stat:last-child {
  min-height: 42px;
  padding: 5px 11px;
  border: 1px solid rgba(255,255,255,.08);
  border-radius: 4px;
  background: linear-gradient(180deg, #17181d 0%, #111216 100%);
  box-shadow: inset 0 1px 0 rgba(255,255,255,.045), inset 0 2px 5px rgba(0,0,0,.42), 0 1px 0 rgba(255,255,255,.025);
}
.life-stat-label {
  color: #99999b;
  font-size: 8px;
  letter-spacing: .1em;
}
.life-stat-value {
  margin-top: 3px;
  color: #e8e2d3;
  font-size: 14px;
  text-shadow: 0 0 8px rgba(232,226,211,.12);
}
.life-stat[data-kind="debt"] .life-stat-value { color: #e49a73; }
.life-stat[data-kind="expense"] { --display-accent: #e7b976; }
.life-stat[data-kind="expense"] .life-stat-value { color: var(--display-accent); }
.life-stat[data-kind="income"] .life-stat-value { color: #a9c5a4; }
.dark-theme .life-hud {
  border-bottom-color: rgba(255,255,255,.06);
  background: linear-gradient(180deg, #1b1c22 0%, #15161b 100%);
  box-shadow: 0 5px 14px rgba(0,0,0,.3);
}
.dark-theme .life-stat,
.dark-theme .life-stat:first-child,
.dark-theme .life-stat:last-child {
  border-color: rgba(255,255,255,.075);
  background: linear-gradient(180deg, #0e0f13 0%, #090a0d 100%);
  box-shadow: inset 0 1px 0 rgba(255,255,255,.035), inset 0 2px 6px rgba(0,0,0,.55), 0 1px 0 rgba(255,255,255,.02);
}
.dark-theme .life-stat-label { color: #85858b; }
.dark-theme .life-stat-value { color: #e5dfd1; }
.dark-theme .life-stat[data-kind="debt"] .life-stat-value { color: #e49a73; }
.dark-theme .life-stat[data-kind="savings"] .life-stat-value,
.dark-theme .life-stat[data-kind="expense"] .life-stat-value { color: #e7b976; }
.dark-theme .life-stat[data-kind="income"] .life-stat-value { color: #a9c5a4; }
@media (max-width: 600px) {
  .life-hud-inner { gap: 5px 7px; padding: 6px 12px; }
  .life-stat,
  .life-stat:first-child,
  .life-stat:last-child {
    min-height: 32px;
    padding: 4px 8px;
  }
  .life-stat:nth-child(2n),
  .life-stat:nth-child(-n+2) { border-bottom: 1px solid rgba(255,255,255,.08); }
  .life-stat-label { font-size: 7px; }
  .life-stat-value { margin-top: 2px; font-size: 12px; }
}

.life-stat[data-kind="savings"] .life-stat-value { color: #a9c5a4; }
.dark-theme .life-stat[data-kind="savings"] .life-stat-value { color: #a9c5a4; }

/* Restore the quiet retro LCD typography on the homepage displays. */
body[data-page="dashboard"] {
  --lcd-font: "Segoe UI", "Helvetica Neue", Arial, sans-serif;
}
body[data-page="dashboard"] .home-tagline,
body[data-page="dashboard"] .home-intro,
body[data-page="dashboard"] .home-about-inline,
body[data-page="dashboard"] .home-life-stats .life-stat-label,
body[data-page="dashboard"] .map-screen-heading,
body[data-page="dashboard"] .map-coordinate-label,
body[data-page="dashboard"] .detail-heading h2,
body[data-page="dashboard"] .markdown-preview h3,
body[data-page="dashboard"] .markdown-preview p,
body[data-page="dashboard"] .markdown-preview li,
body[data-page="dashboard"] .dashboard-empty,
body[data-page="dashboard"] .dashboard-loading,
body[data-page="dashboard"] .community-vote h2,
body[data-page="dashboard"] .community-vote-kicker,
body[data-page="dashboard"] .poll-guidance,
body[data-page="dashboard"] .poll-empty,
body[data-page="dashboard"] .poll-message,
body[data-page="dashboard"] .vote-option,
body[data-page="dashboard"] .vote-result-option {
  font-family: var(--lcd-font);
  font-weight: 400;
  text-shadow: 0 0 .45px currentColor, 0 0 3px rgba(207, 201, 188, .12);
}
body[data-page="dashboard"] .home-intro {
  color: #d2cfc7;
  font-size: 11px;
  line-height: 1.95;
  letter-spacing: .035em;
}
body[data-page="dashboard"] .home-tagline { font-size: 10px; letter-spacing: .13em; }
body[data-page="dashboard"] .home-about-inline { font-size: 8px; }
body[data-page="dashboard"] .home-life-stats .life-stat-label {
  font-size: 7px;
  letter-spacing: .12em;
}
body[data-page="dashboard"] .home-life-stats .life-stat-value {
  font-family: var(--lcd-font);
  font-size: 12px;
  font-weight: 400;
  letter-spacing: .045em;
  font-variant-numeric: tabular-nums;
  text-shadow: 0 0 .5px currentColor, 0 0 5px rgba(232, 226, 211, .16);
}
body[data-page="dashboard"] .map-screen-heading,
body[data-page="dashboard"] .detail-heading h2,
body[data-page="dashboard"] .community-vote h2 {
  font-size: 10px;
  font-weight: 400;
  letter-spacing: .14em;
}
body[data-page="dashboard"] .markdown-preview p,
body[data-page="dashboard"] .markdown-preview li,
body[data-page="dashboard"] .poll-guidance,
body[data-page="dashboard"] .poll-empty,
body[data-page="dashboard"] .poll-message,
body[data-page="dashboard"] .vote-option,
body[data-page="dashboard"] .vote-result-option {
  font-size: 10px;
  line-height: 1.85;
  letter-spacing: .025em;
}
body[data-page="dashboard"] .markdown-preview h3 { font-size: 9px; letter-spacing: .14em; }
body[data-page="dashboard"] .community-vote-kicker,
body[data-page="dashboard"] .map-coordinate-label { font-size: 7px; letter-spacing: .12em; }

/* Keep each desktop display on one line; compact screens remain stacked. */
@media (min-width: 761px) {
  .life-stat { display: flex; align-items: center; justify-content: space-between; gap: 8px; min-height: 30px; padding: 3px 10px; }
  .life-stat:first-child,
  .life-stat:last-child { min-height: 30px; padding: 3px 10px; }
  .life-stat-label { flex: 1 1 auto; font-size: 7px; letter-spacing: .07em; }
  .life-stat-value { flex: 0 0 auto; margin-top: 0; font-size: 13px; }
}
@media (max-width: 600px) {
  .life-stat:nth-child(3) { padding-left: 8px; }
}

/* Collapsible public stats, revealed from the centered printer-panel button. */
body.has-life-hud { --life-hud-height: 42px; }
.life-hud {
  height: var(--life-hud-height);
  flex-direction: column;
  align-items: stretch;
  overflow: hidden;
  transition: height .22s ease;
}
.life-hud-toggle {
  align-self: center;
  flex: 0 0 42px;
  height: 42px;
  padding: 0 14px;
  border: 0;
  background: transparent;
  color: #aaa9a3;
  cursor: pointer;
  font: 9px/1 var(--mono);
  letter-spacing: .13em;
}
.life-hud-toggle:hover { color: #e7b976; }
.life-hud-toggle:focus-visible { outline: 1px solid #e7b976; outline-offset: -5px; }
.life-hud-inner { display: none; height: 44px; flex: 0 0 44px; }
.life-hud.is-open .life-hud-inner { display: grid; }
.dark-theme .life-hud-toggle { color: #96969b; }
.dark-theme .life-hud-toggle:hover { color: #e7b976; }
body.has-life-hud.life-hud-open { --life-hud-height: 86px; }
@media (max-width: 600px) {
  body.has-life-hud.life-hud-open { --life-hud-height: 128px; }
  .life-hud.is-open .life-hud-inner { height: 86px; flex-basis: 86px; }
}

/* Minimal community poll on the home receipt. */
.community-vote {
  padding: 24px 0 26px;
  border-bottom: 1px dashed var(--line);
  text-align: center;
}
.community-vote-kicker,
.poll-results-title {
  margin: 0 0 10px;
  color: var(--muted);
  font: 9px/1.5 var(--mono);
  letter-spacing: .14em;
}
.community-vote h2 {
  margin: 0 0 10px;
  color: var(--ink);
  font: 500 13px/1.7 var(--mono);
  letter-spacing: .05em;
}
.poll-guidance,
.poll-empty,
.poll-message {
  margin: 0 auto 14px;
  max-width: 28rem;
  color: var(--muted);
  font-size: 12px;
  line-height: 1.8;
}
.poll-empty { margin-bottom: 0; font: 10px/1.8 var(--mono); }
.poll-options { display: grid; gap: 7px; margin: 18px 0 13px; padding: 0; border: 0; }
.vote-option {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 9px 11px;
  border: 1px solid var(--line);
  color: var(--ink);
  cursor: pointer;
  text-align: left;
  font-size: 12px;
  line-height: 1.6;
}
.vote-option:hover { border-color: var(--muted); }
.vote-option input { flex: 0 0 auto; margin: 0; accent-color: var(--ink); }
.poll-submit {
  padding: 9px 14px;
  border: 1px solid var(--line);
  background: transparent;
  color: var(--ink);
  cursor: pointer;
  font: 9px/1.4 var(--mono);
  letter-spacing: .1em;
}
.poll-submit:hover:not(:disabled) { border-color: var(--ink); }
.poll-submit:disabled { cursor: wait; opacity: .55; }
.poll-message { min-height: 1.8em; margin: 10px auto 0; font: 10px/1.8 var(--mono); }
.poll-results { margin-top: 20px; text-align: left; }
.poll-results-title { text-align: center; }
.vote-result-option { margin: 0 0 11px; color: var(--ink); font-size: 11px; }
.vote-result-caption { display: flex; justify-content: space-between; gap: 10px; margin-bottom: 4px; }
.vote-result-track { height: 3px; background: var(--line); }
.vote-result-track span { display: block; height: 100%; background: var(--ink); transition: width .25s ease; }
.dark-theme .vote-result-track span { background: #e7b976; }
@media print { .community-vote { display: none !important; } }

/* Homepage dashboard lives in the same body-level position as the year-page life HUD. */
body[data-page="dashboard"] { --life-hud-height: 0px; --display-top: #17181d; --display-bottom: #111216; --display-inset: rgba(0,0,0,.4); color: #e8e4da; }
.dark-theme body[data-page="dashboard"] { --display-top: #17181d; --display-bottom: #111216; --display-inset: rgba(0,0,0,.4); }
.home-dashboard {
  position: relative; display: block; width: 100%; margin: 0; padding: 29px 22px 26px;
  overflow: visible; background: linear-gradient(0deg,var(--machine) 0%,var(--slot) 100%); color: #e8e4da;
  box-shadow: inset 0 -1px 0 rgba(255,255,255,.06);
}
.home-header { width: min(32rem,100%); margin: 0 auto; padding: 0 0 23px; text-align: center; border-bottom: 1px solid rgba(255,255,255,.1); }
.home-header .brand { color: #e8e4da; font-size: 22px; letter-spacing: .22em; }
.home-header .subtitle { margin-top: 9px; color: #99999b; font-size: 9px; letter-spacing: .18em; }
.home-header .year { color: #e7b976; }
.home-tagline { margin: 8px 0 0; color: #e7b976; font: 300 11px/1.6 "Segoe UI","Helvetica Neue",Arial,sans-serif; letter-spacing: .12em; }
.home-intro { max-width: 33rem; margin: 17px auto 0; color: #d2cfc7; font: 300 12px/1.9 "Segoe UI","Helvetica Neue",Arial,sans-serif; letter-spacing: .01em; }
.home-about-inline { display: inline-block; margin-left: 7px; border-bottom: 1px solid rgba(231,185,118,.45); color: #e7b976; font: 300 8px/1.4 "Segoe UI","Helvetica Neue",Arial,sans-serif; letter-spacing: .1em; text-decoration: none; white-space: nowrap; transition: color .18s,border-color .18s; }
.home-about-inline:hover { color: #f2d3a4; border-color: rgba(231,185,118,.85); }
.player-support { margin-top: 16px; text-align: center; }
.player-support-label { display: block; margin-bottom: 8px; color: #99999b; font: 7px/1.4 var(--mono); letter-spacing: .14em; }
.player-support-icons { display: flex; justify-content: center; gap: 8px; }
.support-icon { display: inline-grid; width: 27px; height: 27px; padding: 0; place-items: center; border: 1px solid rgba(255,255,255,.14); border-radius: 50%; background: rgba(255,255,255,.025); color: #c9c5bd; cursor: pointer; text-decoration: none; transition: color .18s,border-color .18s,background .18s,transform .18s; }
.support-icon:hover,.support-icon:focus-visible { color: #e7b976; border-color: rgba(231,185,118,.65); background: rgba(231,185,118,.08); transform: translateY(-1px); }
.support-icon:focus-visible { outline: 2px solid #e7b976; outline-offset: 2px; }
.support-icon svg { width: 14px; height: 14px; fill: none; stroke: currentColor; stroke-width: 1.45; stroke-linecap: round; stroke-linejoin: round; }
.support-paypal span,.support-bitcoin span { font: 600 14px/1 Arial,sans-serif; }
.support-bitcoin span { font-size: 15px; }
.support-copy-status { display: block; min-height: 1.5em; margin: 6px auto 0; color: #e7b976; font: 7px/1.5 var(--mono); letter-spacing: .06em; overflow-wrap: anywhere; }
.home-life-stats { display: grid; grid-template-columns: repeat(4,minmax(0,1fr)); gap: 8px; width: min(32rem,100%); margin: 17px auto 20px; }
.home-life-stats .life-stat { display: flex; min-width: 0; min-height: 48px; flex-direction: column; align-items: flex-start; justify-content: center; gap: 4px; padding: 7px 10px; border: 1px solid rgba(255,255,255,.1); border-radius: 4px; background: linear-gradient(180deg,var(--display-top) 100%,var(--display-bottom) 100%); box-shadow: inset 0 1px 0 rgba(255,255,255,.055),inset 0 2px 5px var(--display-inset); }
.home-life-stats .life-stat-label { color: #99999b; font: 300 7px/1.4 "Segoe UI","Helvetica Neue",Arial,sans-serif; letter-spacing: .1em; }
.home-life-stats .life-stat-value { margin: 0; color: #e8e4da; font: 400 12px/1.25 "Segoe UI","Helvetica Neue",Arial,sans-serif; font-variant-numeric: tabular-nums; letter-spacing: .025em; }
.home-life-stats .life-stat[data-kind="debt"] .life-stat-value { color: #e49a73; }
.home-life-stats .life-stat[data-kind="savings"] .life-stat-value { color: #a9c5a4; }
.home-life-stats .life-stat[data-kind="income"] .life-stat-value { color: #a9c5a4; }
.home-life-stats .life-stat[data-kind="expense"] .life-stat-value { color: #e7b976; }
.home-map-screen { width: min(32rem,100%); margin: 0 auto 20px; padding: 9px; border: 1px solid rgba(255,255,255,.1); border-radius: 5px; background: linear-gradient(180deg,var(--display-top) 100%,var(--display-bottom) 100%); box-shadow: inset 0 1px 0 rgba(255,255,255,.055),inset 0 2px 6px var(--display-inset); }
.map-screen-heading { display: flex; align-items: baseline; justify-content: space-between; gap: 12px; padding: 2px 3px 8px; color: #e8e4da; font: 300 8px/1.5 "Segoe UI","Helvetica Neue",Arial,sans-serif; letter-spacing: .12em; }
.map-screen-label { color: #99999b; }
.map-screen-heading strong { color: #e7b976; font-weight: 500; }
.map-screen-viewport { position: relative; height: 112px; overflow: hidden; border: 1px solid rgba(255,255,255,.07); border-radius: 3px; background: radial-gradient(ellipse at center,rgba(169,197,164,.045),transparent 68%),var(--display-top); box-shadow: inset 0 2px 7px var(--display-inset); }
.map-drawing { display: block; width: 100%; height: 100%; }
.map-road { fill: none; stroke: rgba(197,190,167,.16); stroke-width: 1.2; vector-effect: non-scaling-stroke; }
.map-road-major { stroke: rgba(231,185,118,.28); stroke-width: 1.7; }
.map-pin-halo { fill: rgba(231,185,118,.11); }
.map-pin-pulse { fill: none; stroke: rgba(231,185,118,.7); stroke-width: 1.2; transform-box: fill-box; transform-origin: center; animation: mapPulse 2.4s ease-out infinite; }
.map-pin { fill: #f0c77e; }
@keyframes mapPulse { 0% { transform: scale(.55); opacity: .65; } 80%,100% { transform: scale(2.3); opacity: 0; } }
.map-coordinate-label { position: absolute; bottom: 8px; left: 10px; color: #8c8c88; font: 300 7px/1.4 "Segoe UI","Helvetica Neue",Arial,sans-serif; letter-spacing: .1em; }
.dashboard-detail { width: min(32rem,100%); margin: 12px auto; padding: 17px 18px 18px; border: 1px solid rgba(255,255,255,.1); border-radius: 5px; background: linear-gradient(180deg,var(--display-top) 100%,var(--display-bottom) 100%); box-shadow: inset 0 1px 0 rgba(255,255,255,.055),inset 0 3px 7px var(--display-inset),0 2px 0 rgba(255,255,255,.025); }
.detail-heading { margin: 0 0 12px; }
.detail-heading h2 { margin: 0; color: #e8e4da; font: 400 12px/1.5 "Segoe UI","Helvetica Neue",Arial,sans-serif; letter-spacing: .12em; }
.markdown-preview h3 { margin: 13px 0 7px; color: #99999b; font: 400 10px/1.5 "Segoe UI","Helvetica Neue",Arial,sans-serif; text-transform: uppercase; letter-spacing: .1em; }
.markdown-preview h3:first-child { margin-top: 0; }
.markdown-preview p, .markdown-preview li { color: #d9d5cc; font: 300 12px/1.8 "Segoe UI","Helvetica Neue",Arial,sans-serif; letter-spacing: .01em; }
.markdown-preview p { margin: 0 0 8px; }
.markdown-preview a { color: #e7b976; text-decoration: underline; text-decoration-color: rgba(231,185,118,.5); text-underline-offset: 3px; }
.markdown-preview ul { margin: 0; padding: 0; list-style: none; }
.markdown-preview li { position: relative; padding: 4px 0 4px 17px; border-bottom: 1px solid rgba(255,255,255,.1); }
.markdown-preview li:before { content: "□"; position: absolute; left: 0; color: #e7b976; }
.markdown-preview li.is-complete { color: #99999b; text-decoration: line-through; }
.markdown-preview li.is-complete:before { content: "✓"; }
.markdown-preview li.is-progress:before { content: "◩"; color: #e7b976; }
.markdown-preview li.is-primary:before { content: "■"; color: #e7b976; }
.dashboard-empty,.dashboard-loading { color: #99999b!important; font: 300 10px/1.8 "Segoe UI","Helvetica Neue",Arial,sans-serif!important; letter-spacing: .03em; }
.community-vote { width: min(32rem,100%); margin: 12px auto 0; padding: 17px 18px 18px; border: 1px solid rgba(255,255,255,.1); border-radius: 5px; background: linear-gradient(180deg,var(--display-top) 100%,var(--display-bottom) 100%); box-shadow: inset 0 1px 0 rgba(255,255,255,.055),inset 0 3px 7px var(--display-inset),0 2px 0 rgba(255,255,255,.025); color: #e8e4da; text-align: center; }
.community-vote h2 { color: #e8e4da; font-weight: 400; }
.community-vote h2,.community-vote-kicker,.poll-guidance,.poll-empty,.poll-message,.vote-option,.vote-result-option { font-family: "Segoe UI","Helvetica Neue",Arial,sans-serif; font-weight: 300; letter-spacing: .02em; }
.community-vote-kicker,.poll-guidance,.poll-empty,.poll-message { color: #99999b; }
.vote-option { color: #e8e4da; border-color: rgba(255,255,255,.12); }
.poll-submit { color: #e8e4da; border-color: rgba(255,255,255,.2); }
body[data-page="dashboard"] .printer-top { position: relative; inset: auto; top: auto; z-index: 60; display: block; width: 100%; height: 66px; }
body[data-page="dashboard"] .slot-bg,
body[data-page="dashboard"] .slot-overlay { position: relative; top: auto; left: 50%; transform: translateX(-50%); height: 14px; margin: 0; }
body[data-page="dashboard"] .slot-bg { z-index: 40; }
body[data-page="dashboard"] .slot-overlay { z-index: 65; margin-top: -14px; }
body[data-page="dashboard"] .home-receipt { margin-top: -14px; padding: 18px 24px 22px; }
.home-receipt .latest-archive { display: flex; flex-direction: column; align-items: center; gap: 4px; color: var(--ink); text-decoration: none; text-align: center; }
.home-receipt .latest-archive:hover { color: var(--accent); }
.home-receipt .tail-kicker { margin-bottom: 5px; color: var(--muted); font: 8px/1.5 var(--mono); letter-spacing: .14em; }
.home-receipt .tail-title { color: inherit; font: 9px/1.5 var(--mono); letter-spacing: .14em; }
.home-receipt .latest-archive strong { color: var(--accent); font: 500 21px/1.35 var(--mono); letter-spacing: .15em; }
body[data-page="dashboard"] .year-link { display: none!important; }
@media(max-width:600px) {
  .home-dashboard { padding: 23px 16px 21px; }
  .home-header .brand { font-size: 20px; }
  .home-intro { max-width: 28rem; font-size: 12px; }
  .home-tagline { font-size: 10px; }
  .home-life-stats { grid-template-columns: repeat(2,minmax(0,1fr)); gap: 6px; }
  .home-life-stats .life-stat { min-height: 43px; padding: 6px 8px; }
  .home-map-screen { margin-bottom: 16px; padding: 7px; }
  .map-screen-viewport { height: 96px; }
  .map-screen-heading { font-size: 7px; }
  .dashboard-detail { padding: 14px 12px 15px; }
  .community-vote { padding: 14px 12px 15px; }
}
@media print {
  body[data-page="dashboard"] { background: #fff!important; }
  .home-dashboard,.printer-top,.slot-bg,.slot-overlay { display:none!important; }
  body[data-page="dashboard"] .home-receipt { width:100%; margin:0; box-shadow:none; }
}

