/* Shamondemic - one cartridge, four greens, one pixel. No fifth colour, no radius, no blur, no gradient. */
@font-face { font-family: "PS2P"; src: url(/assets/fonts/ps2p.woff2) format("woff2"); font-display: swap; }
@font-face { font-family: "Silk"; src: url(/assets/fonts/silk.woff2) format("woff2"); font-display: swap; }
@font-face { font-family: "Azeret"; src: url(/assets/fonts/azeret.woff2) format("woff2"); font-weight: 100 900; font-display: swap; }

:root {
  --k: #0f380f; --d: #306230; --l: #8bac0f; --w: #9bbc0f;
  --px: 4px; --gut: 32px; --max: 1280px;
  --pix: "PS2P", ui-monospace, monospace; --num: "Azeret", ui-monospace, monospace; --sk: "Silk", "PS2P", ui-monospace, monospace;
    --i-up: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 8 8' shape-rendering='crispEdges'%3E%3Crect x='3' y='0' width='1' height='1'/%3E%3Crect x='2' y='1' width='1' height='1'/%3E%3Crect x='3' y='1' width='1' height='1'/%3E%3Crect x='4' y='1' width='1' height='1'/%3E%3Crect x='1' y='2' width='1' height='1'/%3E%3Crect x='2' y='2' width='1' height='1'/%3E%3Crect x='3' y='2' width='1' height='1'/%3E%3Crect x='4' y='2' width='1' height='1'/%3E%3Crect x='5' y='2' width='1' height='1'/%3E%3Crect x='0' y='3' width='1' height='1'/%3E%3Crect x='1' y='3' width='1' height='1'/%3E%3Crect x='2' y='3' width='1' height='1'/%3E%3Crect x='3' y='3' width='1' height='1'/%3E%3Crect x='4' y='3' width='1' height='1'/%3E%3Crect x='5' y='3' width='1' height='1'/%3E%3Crect x='6' y='3' width='1' height='1'/%3E%3Crect x='3' y='4' width='1' height='1'/%3E%3Crect x='3' y='5' width='1' height='1'/%3E%3Crect x='3' y='6' width='1' height='1'/%3E%3C/svg%3E");
  --i-down: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 8 8' shape-rendering='crispEdges'%3E%3Crect x='3' y='0' width='1' height='1'/%3E%3Crect x='3' y='1' width='1' height='1'/%3E%3Crect x='3' y='2' width='1' height='1'/%3E%3Crect x='0' y='3' width='1' height='1'/%3E%3Crect x='1' y='3' width='1' height='1'/%3E%3Crect x='2' y='3' width='1' height='1'/%3E%3Crect x='3' y='3' width='1' height='1'/%3E%3Crect x='4' y='3' width='1' height='1'/%3E%3Crect x='5' y='3' width='1' height='1'/%3E%3Crect x='6' y='3' width='1' height='1'/%3E%3Crect x='1' y='4' width='1' height='1'/%3E%3Crect x='2' y='4' width='1' height='1'/%3E%3Crect x='3' y='4' width='1' height='1'/%3E%3Crect x='4' y='4' width='1' height='1'/%3E%3Crect x='5' y='4' width='1' height='1'/%3E%3Crect x='2' y='5' width='1' height='1'/%3E%3Crect x='3' y='5' width='1' height='1'/%3E%3Crect x='4' y='5' width='1' height='1'/%3E%3Crect x='3' y='6' width='1' height='1'/%3E%3C/svg%3E");
  --i-left: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 8 8' shape-rendering='crispEdges'%3E%3Crect x='3' y='0' width='1' height='1'/%3E%3Crect x='2' y='1' width='1' height='1'/%3E%3Crect x='3' y='1' width='1' height='1'/%3E%3Crect x='1' y='2' width='1' height='1'/%3E%3Crect x='2' y='2' width='1' height='1'/%3E%3Crect x='3' y='2' width='1' height='1'/%3E%3Crect x='0' y='3' width='1' height='1'/%3E%3Crect x='1' y='3' width='1' height='1'/%3E%3Crect x='2' y='3' width='1' height='1'/%3E%3Crect x='3' y='3' width='1' height='1'/%3E%3Crect x='4' y='3' width='1' height='1'/%3E%3Crect x='5' y='3' width='1' height='1'/%3E%3Crect x='6' y='3' width='1' height='1'/%3E%3Crect x='1' y='4' width='1' height='1'/%3E%3Crect x='2' y='4' width='1' height='1'/%3E%3Crect x='3' y='4' width='1' height='1'/%3E%3Crect x='2' y='5' width='1' height='1'/%3E%3Crect x='3' y='5' width='1' height='1'/%3E%3Crect x='3' y='6' width='1' height='1'/%3E%3C/svg%3E");
  --i-right: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 8 8' shape-rendering='crispEdges'%3E%3Crect x='3' y='0' width='1' height='1'/%3E%3Crect x='3' y='1' width='1' height='1'/%3E%3Crect x='4' y='1' width='1' height='1'/%3E%3Crect x='3' y='2' width='1' height='1'/%3E%3Crect x='4' y='2' width='1' height='1'/%3E%3Crect x='5' y='2' width='1' height='1'/%3E%3Crect x='0' y='3' width='1' height='1'/%3E%3Crect x='1' y='3' width='1' height='1'/%3E%3Crect x='2' y='3' width='1' height='1'/%3E%3Crect x='3' y='3' width='1' height='1'/%3E%3Crect x='4' y='3' width='1' height='1'/%3E%3Crect x='5' y='3' width='1' height='1'/%3E%3Crect x='6' y='3' width='1' height='1'/%3E%3Crect x='3' y='4' width='1' height='1'/%3E%3Crect x='4' y='4' width='1' height='1'/%3E%3Crect x='5' y='4' width='1' height='1'/%3E%3Crect x='3' y='5' width='1' height='1'/%3E%3Crect x='4' y='5' width='1' height='1'/%3E%3Crect x='3' y='6' width='1' height='1'/%3E%3C/svg%3E");
  --i-close: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 8 8' shape-rendering='crispEdges'%3E%3Crect x='0' y='0' width='1' height='1'/%3E%3Crect x='1' y='0' width='1' height='1'/%3E%3Crect x='6' y='0' width='1' height='1'/%3E%3Crect x='7' y='0' width='1' height='1'/%3E%3Crect x='0' y='1' width='1' height='1'/%3E%3Crect x='1' y='1' width='1' height='1'/%3E%3Crect x='2' y='1' width='1' height='1'/%3E%3Crect x='5' y='1' width='1' height='1'/%3E%3Crect x='6' y='1' width='1' height='1'/%3E%3Crect x='7' y='1' width='1' height='1'/%3E%3Crect x='1' y='2' width='1' height='1'/%3E%3Crect x='2' y='2' width='1' height='1'/%3E%3Crect x='3' y='2' width='1' height='1'/%3E%3Crect x='4' y='2' width='1' height='1'/%3E%3Crect x='5' y='2' width='1' height='1'/%3E%3Crect x='6' y='2' width='1' height='1'/%3E%3Crect x='2' y='3' width='1' height='1'/%3E%3Crect x='3' y='3' width='1' height='1'/%3E%3Crect x='4' y='3' width='1' height='1'/%3E%3Crect x='5' y='3' width='1' height='1'/%3E%3Crect x='2' y='4' width='1' height='1'/%3E%3Crect x='3' y='4' width='1' height='1'/%3E%3Crect x='4' y='4' width='1' height='1'/%3E%3Crect x='5' y='4' width='1' height='1'/%3E%3Crect x='1' y='5' width='1' height='1'/%3E%3Crect x='2' y='5' width='1' height='1'/%3E%3Crect x='3' y='5' width='1' height='1'/%3E%3Crect x='4' y='5' width='1' height='1'/%3E%3Crect x='5' y='5' width='1' height='1'/%3E%3Crect x='6' y='5' width='1' height='1'/%3E%3Crect x='0' y='6' width='1' height='1'/%3E%3Crect x='1' y='6' width='1' height='1'/%3E%3Crect x='2' y='6' width='1' height='1'/%3E%3Crect x='5' y='6' width='1' height='1'/%3E%3Crect x='6' y='6' width='1' height='1'/%3E%3Crect x='7' y='6' width='1' height='1'/%3E%3Crect x='0' y='7' width='1' height='1'/%3E%3Crect x='1' y='7' width='1' height='1'/%3E%3Crect x='6' y='7' width='1' height='1'/%3E%3Crect x='7' y='7' width='1' height='1'/%3E%3C/svg%3E");
  --i-ext: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 8 8' shape-rendering='crispEdges'%3E%3Crect x='3' y='0' width='1' height='1'/%3E%3Crect x='4' y='0' width='1' height='1'/%3E%3Crect x='5' y='0' width='1' height='1'/%3E%3Crect x='6' y='0' width='1' height='1'/%3E%3Crect x='7' y='0' width='1' height='1'/%3E%3Crect x='4' y='1' width='1' height='1'/%3E%3Crect x='5' y='1' width='1' height='1'/%3E%3Crect x='6' y='1' width='1' height='1'/%3E%3Crect x='7' y='1' width='1' height='1'/%3E%3Crect x='3' y='2' width='1' height='1'/%3E%3Crect x='4' y='2' width='1' height='1'/%3E%3Crect x='5' y='2' width='1' height='1'/%3E%3Crect x='6' y='2' width='1' height='1'/%3E%3Crect x='7' y='2' width='1' height='1'/%3E%3Crect x='2' y='3' width='1' height='1'/%3E%3Crect x='3' y='3' width='1' height='1'/%3E%3Crect x='4' y='3' width='1' height='1'/%3E%3Crect x='6' y='3' width='1' height='1'/%3E%3Crect x='7' y='3' width='1' height='1'/%3E%3Crect x='1' y='4' width='1' height='1'/%3E%3Crect x='2' y='4' width='1' height='1'/%3E%3Crect x='3' y='4' width='1' height='1'/%3E%3Crect x='7' y='4' width='1' height='1'/%3E%3Crect x='0' y='5' width='1' height='1'/%3E%3Crect x='1' y='5' width='1' height='1'/%3E%3Crect x='2' y='5' width='1' height='1'/%3E%3Crect x='0' y='6' width='1' height='1'/%3E%3Crect x='1' y='6' width='1' height='1'/%3E%3C/svg%3E");
  --i-copy: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 8 8' shape-rendering='crispEdges'%3E%3Crect x='0' y='0' width='1' height='1'/%3E%3Crect x='1' y='0' width='1' height='1'/%3E%3Crect x='2' y='0' width='1' height='1'/%3E%3Crect x='3' y='0' width='1' height='1'/%3E%3Crect x='4' y='0' width='1' height='1'/%3E%3Crect x='0' y='1' width='1' height='1'/%3E%3Crect x='4' y='1' width='1' height='1'/%3E%3Crect x='0' y='2' width='1' height='1'/%3E%3Crect x='2' y='2' width='1' height='1'/%3E%3Crect x='3' y='2' width='1' height='1'/%3E%3Crect x='4' y='2' width='1' height='1'/%3E%3Crect x='5' y='2' width='1' height='1'/%3E%3Crect x='6' y='2' width='1' height='1'/%3E%3Crect x='0' y='3' width='1' height='1'/%3E%3Crect x='2' y='3' width='1' height='1'/%3E%3Crect x='6' y='3' width='1' height='1'/%3E%3Crect x='0' y='4' width='1' height='1'/%3E%3Crect x='1' y='4' width='1' height='1'/%3E%3Crect x='2' y='4' width='1' height='1'/%3E%3Crect x='6' y='4' width='1' height='1'/%3E%3Crect x='2' y='5' width='1' height='1'/%3E%3Crect x='6' y='5' width='1' height='1'/%3E%3Crect x='2' y='6' width='1' height='1'/%3E%3Crect x='3' y='6' width='1' height='1'/%3E%3Crect x='4' y='6' width='1' height='1'/%3E%3Crect x='5' y='6' width='1' height='1'/%3E%3Crect x='6' y='6' width='1' height='1'/%3E%3C/svg%3E");
  --i-tri: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 8 8' shape-rendering='crispEdges'%3E%3Crect x='0' y='0' width='1' height='1'/%3E%3Crect x='0' y='1' width='1' height='1'/%3E%3Crect x='1' y='1' width='1' height='1'/%3E%3Crect x='0' y='2' width='1' height='1'/%3E%3Crect x='1' y='2' width='1' height='1'/%3E%3Crect x='2' y='2' width='1' height='1'/%3E%3Crect x='0' y='3' width='1' height='1'/%3E%3Crect x='1' y='3' width='1' height='1'/%3E%3Crect x='2' y='3' width='1' height='1'/%3E%3Crect x='3' y='3' width='1' height='1'/%3E%3Crect x='0' y='4' width='1' height='1'/%3E%3Crect x='1' y='4' width='1' height='1'/%3E%3Crect x='2' y='4' width='1' height='1'/%3E%3Crect x='0' y='5' width='1' height='1'/%3E%3Crect x='1' y='5' width='1' height='1'/%3E%3Crect x='0' y='6' width='1' height='1'/%3E%3C/svg%3E");
  --dots: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 10 10' shape-rendering='crispEdges'%3E%3Crect x='2' y='2' width='1' height='1' fill='%230f380f'/%3E%3Crect x='7' y='7' width='1' height='1' fill='%230f380f'/%3E%3C/svg%3E");
}
@media (max-width: 900px) { :root { --px: 3px; --gut: 20px; } }
@media (max-width: 420px) { :root { --px: 2px; --gut: 16px; } }

*, *::before, *::after { box-sizing: border-box; }
html { background: var(--d); scroll-behavior: auto; -webkit-text-size-adjust: 100%; }
body {
  margin: 0; min-height: 100vh; display: flex; flex-direction: column; color: var(--w); background: var(--d) url(/assets/art/ui/g-meadow.png) 0 0 / calc(var(--px) * 96) calc(var(--px) * 96);
  font: 16px/1.5 var(--pix); -webkit-font-smoothing: none; -moz-osx-font-smoothing: unset; font-smooth: never;
  overflow-x: hidden;
}
img, canvas { image-rendering: pixelated; image-rendering: crisp-edges; }
canvas { image-rendering: pixelated; }
a { color: inherit; }
button, input, textarea, select { font: inherit; color: inherit; }
:focus-visible { outline: var(--px) solid var(--k); outline-offset: var(--px); }
.hdr :focus-visible, .foot :focus-visible, .dmg :focus-visible { outline-color: var(--w); }
.skip:not(:focus) { position: absolute !important; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }
.skip:focus { position: fixed; left: 8px; top: 8px; z-index: 99; background: var(--w); color: var(--k); padding: 8px 16px; }
.num, .ca, output { font-family: var(--num); font-variant-numeric: tabular-nums; font-weight: 600; letter-spacing: 0; }
h1, h2, h3 { margin: 0; font-weight: 400; }
p { margin: 0; }
[hidden] { display: none !important; }
.px8 { width: calc(var(--px) * 8); height: calc(var(--px) * 8); }

/* ---------------------------------------------------------------- header plate */
.hdr {
  position: sticky; top: 0; z-index: 40; display: flex; align-items: center; gap: 24px;
  height: calc(var(--px) * 18); padding: 0 var(--gut); background: var(--k); color: var(--w);
  border-bottom: var(--px) solid var(--l);
}
.brand { display: flex; align-items: center; gap: 12px; text-decoration: none; white-space: nowrap; min-height: 40px; min-width: 40px; }
.brand span { font-size: 16px; }
.nav { display: flex; gap: 4px; margin: 0 auto; }
.nav a { position: relative; padding: 8px 12px 8px 26px; text-decoration: none; color: var(--l); }
.nav a::before, .mi::before {
  content: ""; position: absolute; left: 6px; top: 50%; width: 8px; height: 12px; margin-top: -6px; background: currentColor;
  clip-path: polygon(0 0, 25% 0, 25% 17%, 50% 17%, 50% 33%, 75% 33%, 75% 50%, 100% 50%, 100% 50%, 75% 50%, 75% 67%, 50% 67%, 50% 83%, 25% 83%, 25% 100%, 0 100%);
  visibility: hidden;
}
.nav a:hover, .nav a[aria-current] { color: var(--w); }
.nav a:hover::before, .nav a[aria-current]::before { visibility: visible; }
.hdr-act { display: flex; align-items: center; gap: 12px; }

/* round A/B buttons: a pixel disc (stepped clip), letter, 1-px highlight arc; pressed = 1 px down */
.disc {
  display: inline-grid; place-items: center; flex: none; width: max(36px, calc(var(--px) * 10)); height: max(36px, calc(var(--px) * 10));
  background: var(--k); color: var(--w); font: 16px/1 var(--pix);
  clip-path: polygon(30% 0, 70% 0, 70% 10%, 90% 10%, 90% 30%, 100% 30%, 100% 70%, 90% 70%, 90% 90%, 70% 90%, 70% 100%, 30% 100%, 30% 90%, 10% 90%, 10% 70%, 0 70%, 0 30%, 10% 30%, 10% 10%, 30% 10%);
  box-shadow: inset var(--px) var(--px) 0 0 var(--d);
}
.hdr .disc, .foot .disc { background: var(--w); color: var(--k); box-shadow: inset var(--px) var(--px) 0 0 var(--l); }
.xbtn, .wbtn, .abtn, .bbtn {
  display: inline-flex; align-items: center; gap: 12px; padding: 0; border: 0; background: none; text-decoration: none; min-height: 40px;
}
.wbtn .bl { color: var(--w); font-size: 16px; white-space: nowrap; }
.wbtn.on .bl { font-family: var(--num); font-weight: 600; }
.xbtn:active .disc, .wbtn:active .disc, .abtn:active .disc, .bbtn:active .disc { transform: translateY(var(--px)); box-shadow: none; }
.abtn .bl, .bbtn .bl { color: var(--k); font-size: 16px; }
.abtn:hover .bl, .bbtn:hover .bl { text-decoration: underline; text-underline-offset: 6px; text-decoration-thickness: var(--px); }
.abtn:disabled, .bbtn:disabled { opacity: 1; }
.abtn:disabled .disc, .bbtn:disabled .disc { background: var(--l); box-shadow: none; }
.abtn:disabled .bl, .bbtn:disabled .bl { color: var(--l); text-decoration: none; }
.abtn.big .disc { width: calc(var(--px) * 14); height: calc(var(--px) * 14); font-size: 24px; }
.abtn.big .bl { font-size: 24px; }
.bbtn .disc { background: var(--d); }
.busy .disc { animation: blink .5s steps(1) infinite; }

/* ---------------------------------------------------------------- dialog box + menus */
.box {
  position: relative; background: var(--w); color: var(--k); border: var(--px) solid var(--k);
  box-shadow: inset 0 0 0 var(--px) var(--w), inset 0 0 0 calc(var(--px) * 2) var(--k);
  padding: calc(var(--px) * 6) calc(var(--px) * 6);
}
.box h3 { font-size: 16px; margin-bottom: 16px; }
.more::after {
  content: ""; position: absolute; right: calc(var(--px) * 5); bottom: calc(var(--px) * 4); width: 12px; height: 8px; background: var(--k);
  clip-path: polygon(0 0, 100% 0, 100% 25%, 83% 25%, 83% 50%, 67% 50%, 67% 75%, 50% 75%, 50% 100%, 50% 100%, 33% 75%, 33% 75%, 33% 50%, 17% 50%, 17% 25%, 0 25%);
  animation: blink 1s steps(1) infinite;
}
@keyframes blink { 50% { visibility: hidden; } }
.say { font-size: 16px; line-height: 2; min-height: 2em; }
.menu { display: flex; flex-direction: column; gap: 8px; }
.mi { position: relative; display: block; padding: 6px 0 6px 28px; text-decoration: none; color: var(--k); font-size: 16px; background: none; border: 0; text-align: left; width: max-content; max-width: 100%; }
.mi::before { left: 4px; }
.mi:hover::before, .mi:focus-visible::before, .mi.cur::before, .menu:not(:hover):not(:focus-within) .mi:first-child::before { visibility: visible; animation: blink 1s steps(1) infinite; }
.mi.small { font: 16px/1.25 var(--sk); padding: 14px 0 14px 22px; margin-top: 8px; }
.mi.small::before { width: 6px; height: 8px; margin-top: -4px; }
.fine { font: 16px/1.5 var(--sk); color: var(--d); }
.inv { background: var(--k) !important; color: var(--w) !important; }

/* CA rows: full address, copy on click */
.carow { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 12px; }
.cal { font: 16px/1.25 var(--sk); }
.ca { border: 0; background: none; padding: 9px 6px; margin: -9px -6px; min-width: 0; max-width: calc(100% + 12px); flex: 0 1 auto; overflow-wrap: anywhere; word-break: break-all; font-size: 15px; word-break: break-all; text-align: left; color: var(--k); }
.ca:hover { background: var(--k); color: var(--w); }
.calinks { display: flex; gap: 12px; font: 16px/1.25 var(--sk); }
.calinks a { text-decoration: none; padding: 13px 0 7px; border-bottom: calc(var(--px) / 2) solid currentColor; }
.calinks a:hover { background: var(--k); color: var(--w); }
.soon { font: 16px/1.25 var(--sk); }
.tk { font-family: var(--num); font-weight: 700; font-size: 15px; }

/* ---------------------------------------------------------------- the DMG plate + LCD */
.dmg { background: var(--k); padding: calc(var(--px) * 5) calc(var(--px) * 5) 0; border: var(--px) solid var(--k); box-shadow: inset 0 0 0 var(--px) var(--d); }
.lcd { position: relative; overflow: hidden; background: var(--w); border: var(--px) solid var(--d); margin: 0; }
.scv { position: absolute; left: 0; top: 0; display: block; }
.plate { display: flex; align-items: center; gap: 12px; min-height: calc(var(--px) * 9); color: var(--l); font: 16px/1.25 var(--sk); padding: 8px 0; flex-wrap: wrap; }
.led { width: calc(var(--px) * 2); height: calc(var(--px) * 2); background: var(--w); flex: none; }
.plate .hud { margin-left: auto; font: 600 15px/1 var(--num); color: var(--w); display: flex; gap: 16px; flex-wrap: wrap; }
.plate .hud b { font: 16px/1 var(--sk); color: var(--l); margin-right: 6px; font-weight: 400; }

main { display: block; flex: 1 0 auto; width: 100%; }
.home main, .page { max-width: calc(var(--max) + var(--gut) * 2); margin: 0 auto; padding: 0 var(--gut); }
.page { padding-top: 48px; padding-bottom: 96px; min-height: 70vh; }

/* hero: title screen */
.hero { padding-top: 24px; }
.herolcd { height: calc(var(--px) * 136); }
.title { position: absolute; left: 50%; top: calc(var(--px) * 6); transform: translateX(-50%); display: flex; flex-direction: column; align-items: center; gap: calc(var(--px) * 4); z-index: 2; }
.markw { position: relative; width: calc(var(--px) * 40); height: calc(var(--px) * 40); }
.mark { position: absolute; inset: 0; width: 100%; height: 100%; }
.mark.b { visibility: hidden; animation: flapb .32s steps(1) infinite; }
.mark.a { animation: flapa .32s steps(1) infinite; }
@keyframes flapa { 50% { visibility: hidden; } }
@keyframes flapb { 50% { visibility: visible; } }
.wordmark { display: block; width: calc(var(--px) * 122); height: calc(var(--px) * 16); }
.hero h1 { line-height: 0; }
.hero-ui { display: grid; grid-template-columns: minmax(280px, 380px) 1fr; gap: 16px; margin-top: 16px; }
.hero-ui .menu { justify-content: center; }
.dialog { display: flex; flex-direction: column; gap: 16px; justify-content: center; }
.padca { display: flex; flex-direction: column; gap: 8px; min-height: 32px; }
@media (max-width: 560px) { .hero .padca { min-height: 96px; } }

/* sections: each one a screen of the same cartridge */
.sec { padding-top: 120px; }
.sech { display: flex; align-items: baseline; gap: 12px 32px; flex-wrap: wrap; margin-bottom: 24px; }
.sech h1, .sech h2 { font-size: 32px; line-height: 1.25; color: var(--w); }
.sech .sub { font-size: 16px; color: var(--l); max-width: 60ch; }
.flip-ok .sec.flip { animation: flip .24s steps(8) both; }
@keyframes flip { from { transform: translateY(calc(var(--px) * 24)); } to { transform: none; } }

/* the war map */
.maplcd { display: block; min-height: calc(var(--px) * 64); }
.maplcd .mapcv { display: block; margin: 0 auto; outline: none; }
.maplcd .mapcv:focus-visible { outline: var(--px) solid var(--k); outline-offset: calc(var(--px) * -1); }
.stamp { position: absolute; left: calc(var(--px) * 3); top: calc(var(--px) * 3); background: var(--k); color: var(--w); padding: 6px 8px; font-size: 16px; z-index: 3; animation: blink 1s steps(1) infinite; }
.dpad { margin-left: auto; display: none; gap: 8px; }
.dmg.pans .dpad { display: flex; }
.dpad button { width: 40px; height: 40px; border: 0; background: var(--w); color: var(--k); padding: 0; display: grid; place-items: center; }
.dpad button:active { transform: translateY(var(--px)); }
.warhud { display: grid; grid-template-columns: minmax(300px, 0.9fr) 1.4fr; gap: 16px; margin-top: 16px; align-items: stretch; }
.strains { display: flex; flex-direction: column; }
.strains > .mi { margin-top: auto; align-self: flex-start; }
.rank { flex: 1; list-style: none; margin: 0 0 16px; padding: 0; display: flex; flex-direction: column; gap: 4px; }
.rank li { flex: 1 1 40px; max-height: 72px; min-height: 40px; display: grid; grid-template-columns: auto auto 1fr auto; align-items: center; gap: 12px; padding: 6px 8px; }
.rank li.go { cursor: pointer; }
.rank li.go:hover, .rank li.on { background: var(--k); color: var(--w); }
.rank li.go:hover .glyph, .rank li.on .glyph { outline: calc(var(--px) / 2) solid var(--w); }
.rank .pos { font: 600 15px var(--num); width: 2ch; }
.rank .sy { font-size: 16px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.rank .v { font: 600 15px var(--num); text-align: right; white-space: nowrap; }
.rank .v small { font: 16px/1.25 var(--sk); margin-left: 6px; }
.rank .empty { display: block; font: 16px/1.5 var(--sk); }
.glyph { width: calc(var(--px) * 7); height: calc(var(--px) * 7); display: block; flex: none; }
.sheet { min-height: 320px; display: grid; grid-template-columns: 1fr 1fr; gap: 20px 28px; align-content: start; }
.sheet > .shead { grid-column: 1; grid-row: 1; }
.sheet > .slots { grid-column: 2; grid-row: 1; align-self: start; }
.sheet > .sstats { grid-column: 1 / -1; grid-row: 2; justify-content: space-between; gap: 16px 24px; }
.sheet > .carow, .sheet > .sacts, .sheet > .fine, .sheet > .say { grid-column: 1 / -1; }
.shead { display: grid; grid-template-columns: auto 1fr; gap: 20px; align-items: start; }
.portrait { width: calc(var(--px) * 32); height: calc(var(--px) * 32); background: var(--d); display: block; border: var(--px) solid var(--k); box-sizing: content-box; }
.sname { font-size: 16px; line-height: 1.75; word-break: break-word; }
.ssym { font: 700 18px var(--num); }
.sstate { display: inline-block; margin-top: 8px; font: 16px/1.25 var(--sk); padding: 6px 8px; background: var(--k); color: var(--w); }
.sstate.cur { background: var(--d); }
.slots { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 8px; }
.slots li { display: grid; grid-template-columns: auto 1fr auto; gap: 12px; align-items: center; padding: 6px 0; border-top: calc(var(--px) / 2) solid var(--l); }
.slots li.free { color: var(--d); font: 16px/1.25 var(--sk); }
.slots .sl { font-size: 16px; }
.slots .sl small { display: block; font: 600 13px var(--num); margin-top: 4px; }
.slots .sv { font: 600 15px var(--num); text-align: right; }
.slots .sv small { display: block; font: 16px/1.25 var(--sk); color: var(--d); margin-top: 4px; }
.sstats { display: flex; gap: 24px; flex-wrap: wrap; }
.sstats div { display: flex; flex-direction: column; gap: 6px; }
.sstats dt { font: 16px/1.25 var(--sk); }
.sstats dd { margin: 0; font: 600 18px var(--num); }
.sacts { display: flex; flex-wrap: wrap; gap: 16px 28px; align-items: center; }
.sacts .mi { padding-top: 10px; padding-bottom: 10px; }

/* how: the explainer screen (the video slot) */
.howgrid { display: grid; grid-template-columns: 1.6fr 1fr; gap: 16px; align-items: stretch; }
.howside .more { flex: 1; display: flex; align-items: center; }
.howlcd { height: calc(var(--px) * 112); }
.howlcd:has(.vp) { height: auto; }
.vp { cursor: pointer; position: relative; background: var(--k); display: flex; flex-direction: column; }
.vp:fullscreen { justify-content: center; }
.vp:-webkit-full-screen { justify-content: center; }
.vp video { display: block; width: 100%; height: auto; aspect-ratio: 16 / 9; object-fit: contain; background: var(--k); image-rendering: pixelated; }
.vp:fullscreen video { aspect-ratio: auto; flex: 1; min-height: 0; }
.vbig { position: absolute; left: 50%; top: 50%; transform: translate(-50%, -50%); margin-top: calc(var(--px) * -5); padding: 0; border: 0; background: none; }
.vbig .disc { width: calc(var(--px) * 22); height: calc(var(--px) * 22); font-size: 28px; background: var(--w); color: var(--k); box-shadow: inset var(--px) var(--px) 0 0 var(--l); }
.vbig:active .disc { transform: translateY(var(--px)); box-shadow: none; }
.vp.playing .vbig { display: none; }
.vbar { display: flex; align-items: center; gap: 12px; padding: 8px 12px; background: var(--k); border-top: var(--px) solid var(--d); color: var(--w); }
.vb { display: inline-flex; align-items: center; justify-content: center; min-width: 40px; min-height: 40px; padding: 0; border: 0; background: none; color: var(--w); }
.vb .disc { background: var(--w); color: var(--k); box-shadow: inset var(--px) var(--px) 0 0 var(--l); font-size: 12px; }
.vb:active .disc { transform: translateY(var(--px)); box-shadow: none; }
.vtxt { font: 16px/1 var(--sk); padding: 0 6px; }
.vtxt:hover { text-decoration: underline; text-underline-offset: 6px; text-decoration-thickness: var(--px); }
.vseek { position: relative; flex: 1; min-width: 40px; height: 40px; cursor: pointer; touch-action: none; }
.vseek::before { content: ""; position: absolute; left: 0; right: 0; top: 50%; height: calc(var(--px) * 2); margin-top: calc(var(--px) * -1); background: var(--d); }
.vbuf, .vfill { position: absolute; left: 0; top: 50%; height: calc(var(--px) * 2); margin-top: calc(var(--px) * -1); width: 0; }
.vbuf { background: var(--l); opacity: .5; }
.vfill { background: var(--w); }
.vknob { position: absolute; top: 50%; left: 0; width: calc(var(--px) * 3); height: calc(var(--px) * 6); margin: calc(var(--px) * -3) 0 0 calc(var(--px) * -1.5); background: var(--w); }
.vseek:focus-visible, .vp:focus-visible { outline-color: var(--w); }
.vt { font-size: 13px; white-space: nowrap; color: var(--w); }
@media (max-width: 520px) { .vbar { gap: 4px; padding: 4px 6px; } .vt { font-size: 11px; } .vtxt { padding: 0 3px; font: 16px/1.25 var(--sk); } }
.howside { display: flex; flex-direction: column; gap: 16px; }
.steps { list-style: none; margin: 0; padding-left: calc(var(--px) * 6); }
.steps li { list-style: none; }
.steps .mi { width: 100%; }
.steps .mi .n { font: 600 15px var(--num); margin-right: 12px; }
.steps .mi.on { background: var(--k); color: var(--w); }
.steps .mi.on::before { visibility: visible; }
.menu.steps:not(:hover):not(:focus-within) .mi:first-child:not(.on)::before { visibility: hidden; animation: none; }

/* patient zero */
.zerogrid { display: grid; grid-template-columns: 1.3fr 1fr; gap: 16px; align-items: stretch; }
.zerolcd { height: calc(var(--px) * 112); }
.zbox { display: flex; flex-direction: column; gap: 24px; justify-content: space-evenly; }
.stat { display: grid; grid-template-columns: 1fr 1fr; gap: 20px 24px; margin: 0; }
.stat div { display: flex; flex-direction: column; gap: 8px; }
.stat dt { font: 16px/1.5 var(--sk); }
.stat dd { margin: 0; font-size: 24px; line-height: 1; }

/* night */
.night { padding-bottom: 96px; }
.nightlcd { height: calc(var(--px) * 88); }
.night .dmg { padding-bottom: calc(var(--px) * 5); }
.nightui { display: grid; grid-template-columns: minmax(280px, 380px) 1fr; gap: 16px; margin-top: 16px; }

/* ---------------------------------------------------------------- footer plate */
.foot { background: var(--k); color: var(--w); border-top: var(--px) solid var(--l); }
.foot-in { max-width: calc(var(--max) + var(--gut) * 2); margin: 0 auto; padding: 32px var(--gut) 40px; display: grid; grid-template-columns: auto 1fr; gap: 24px 48px; align-items: center; }
.foot-ca { grid-row: span 2; justify-self: end; max-width: 560px; }
.foot-ca .ca { color: var(--w); }
.foot-ca .ca:hover { background: var(--w); color: var(--k); }
.foot-nav { display: flex; flex-wrap: wrap; gap: 8px 20px; font: 16px/1.25 var(--sk); }
.foot-nav a { text-decoration: none; color: var(--l); padding: 14px 0; display: inline-block; }
.foot-nav a:hover { color: var(--w); }

/* ---------------------------------------------------------------- launch: the naming screen */
.launch { display: grid; grid-template-columns: 1.15fr 1fr; gap: 16px; align-items: start; }
.namebox { display: flex; flex-direction: column; gap: 24px; }
.fields { display: flex; flex-direction: column; gap: 12px; }
.fld { position: relative; display: grid; grid-template-columns: calc(var(--px) * 24) 1fr; align-items: center; gap: 12px; padding: 8px; }
.fld .fl { font: 16px/1.25 var(--sk); }
.fld.on { background: var(--k); color: var(--w); }
.fld input { width: 100%; border: 0; border-bottom: var(--px) solid currentColor; background: none; padding: 6px 0; font-size: 16px; outline: none; caret-color: transparent; text-transform: none; }
.fld .caret { position: absolute; display: none; }
.kgrid { display: grid; grid-template-columns: repeat(10, 1fr); gap: 4px; }
.kgrid button { min-height: 40px; border: 0; background: none; color: var(--k); font-size: 16px; padding: 0; }
.kgrid button:hover, .kgrid button:focus-visible { background: var(--k); color: var(--w); outline: none; }
.kgrid button.wide { grid-column: span 2; font: 16px/1.25 var(--sk); }
.kgrid .case { grid-column: span 2; font: 16px/1.25 var(--sk); }
.lside { display: flex; flex-direction: column; gap: 16px; }
.pic { display: grid; gap: 12px; }
.drop {
  position: relative; display: grid; place-items: center; height: calc(var(--px) * 64);
  background: url(/assets/art/fence-h.png) 0 0 / calc(var(--px) * 16) calc(var(--px) * 16) repeat-x, url(/assets/art/fence-h.png) 0 100% / calc(var(--px) * 16) calc(var(--px) * 16) repeat-x,
    url(/assets/art/fence-v.png) 0 0 / calc(var(--px) * 16) calc(var(--px) * 16) repeat-y, url(/assets/art/fence-v.png) 100% 0 / calc(var(--px) * 16) calc(var(--px) * 16) repeat-y,
    url(/assets/art/pasture.png) 0 0 / calc(var(--px) * 16) calc(var(--px) * 16);
  image-rendering: pixelated;
}
.drop input { position: absolute; inset: 0; opacity: 0; cursor: pointer; }
.drop.over { outline: var(--px) solid var(--k); }
.dmgpic { width: calc(var(--px) * 32); height: calc(var(--px) * 32); border: var(--px) solid var(--k); box-sizing: content-box; pointer-events: none; }
.dropt { background: var(--w); padding: 8px 10px; border: var(--px) solid var(--k); pointer-events: none; font-size: 16px; }
.extra { display: flex; flex-direction: column; gap: 14px; }
.tf { display: grid; grid-template-columns: calc(var(--px) * 24) 1fr; gap: 12px; align-items: center; }
.tf .fl { font: 16px/1.25 var(--sk); }
.tf input, .tf textarea { width: 100%; border: 0; border-bottom: var(--px) solid var(--k); background: none; padding: 6px 0; font: 600 15px var(--num); color: var(--k); outline: none; resize: none; }
.tf input:focus, .tf textarea:focus { background: var(--l); }
.stepper { display: flex; align-items: center; gap: 12px; }
.stepper button { width: 40px; height: 40px; border: 0; background: var(--k); color: var(--w); display: grid; place-items: center; padding: 0; }
.stepper button:active { transform: translateY(var(--px)); }
.stepper output { font-size: 18px; min-width: 9ch; text-align: center; }
.cost { display: flex; flex-direction: column; gap: 20px; }
.bill { display: grid; grid-template-columns: 1fr auto; gap: 10px 0; margin: 0; }
.bill dd { padding-left: 16px; }
.bill dt { font: 16px/1.5 var(--sk); }
.bill dd { margin: 0; text-align: right; font: 600 15px var(--num); }
.bill .tot { border-top: calc(var(--px) / 2) solid var(--k); padding-top: 10px; }
.done { margin-top: 16px; }
.done .sacts { margin-top: 8px; }

/* ---------------------------------------------------------------- carrier save file */
.save { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; align-items: start; }
.save .full { grid-column: 1 / -1; }
.insert { display: flex; flex-direction: column; align-items: flex-start; gap: 24px; padding-top: 40px; padding-bottom: 40px; }
.insert .say { max-width: 40ch; }
.file { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 12px 24px; align-items: center; }
.file .num { font-size: 15px; word-break: break-all; }
.carry { display: flex; flex-direction: column; gap: 16px; }
.cur-strain { display: flex; align-items: center; gap: 12px; padding: 10px; background: var(--k); color: var(--w); }
.cur-strain .glyph { outline: calc(var(--px) / 2) solid var(--w); }
.hold { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 4px; }
.hold li button { width: 100%; display: grid; grid-template-columns: auto auto 1fr auto; gap: 12px; align-items: center; border: 0; background: none; color: var(--k); padding: 8px 8px 8px 28px; position: relative; text-align: left; min-height: 40px; }
.hold li button::before { content: ""; position: absolute; left: 6px; top: 50%; width: 8px; height: 12px; margin-top: -6px; background: currentColor; clip-path: polygon(0 0, 25% 0, 25% 17%, 50% 17%, 50% 33%, 75% 33%, 75% 50%, 100% 50%, 100% 50%, 75% 50%, 75% 67%, 50% 67%, 50% 83%, 25% 83%, 25% 100%, 0 100%); visibility: hidden; }
.hold li button:hover::before, .hold li button.on::before { visibility: visible; }
.hold li button.on { background: var(--k); color: var(--w); }
.hold li button:disabled { color: var(--l); cursor: default; }
.hold li button:disabled::before { visibility: hidden; }
.hold .amt { font: 600 14px var(--num); text-align: right; }
.list { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; }
.list li { display: grid; grid-template-columns: auto 1fr auto; gap: 12px; align-items: center; padding: 10px 0; border-top: calc(var(--px) / 2) solid var(--l); }
.list li .v { font: 600 15px var(--num); text-align: right; }
.list li .v small { display: block; font: 16px/1.25 var(--sk); color: var(--d); margin-top: 4px; }
.list .nm { font-size: 16px; }
.list .nm small { display: block; font: 16px/1.5 var(--sk); color: var(--d); }
.tot-row { display: flex; justify-content: space-between; align-items: center; gap: 16px; flex-wrap: wrap; margin-top: 16px; }
.tot-row .num { font-size: 22px; }

/* ---------------------------------------------------------------- stats + docs */
.killer { font-size: 24px; line-height: 1.6; color: var(--w); max-width: 40ch; }
.killer .num { font-size: 26px; }
.tbl { margin-top: 16px; }
.tw { overflow-x: auto; }
table { width: 100%; border-collapse: collapse; }
th { font: 16px/1.25 var(--sk); text-align: left; padding: 8px 10px; background: var(--k); color: var(--w); font-weight: 400; white-space: nowrap; }
td { padding: 10px; border-bottom: calc(var(--px) / 2) solid var(--l); vertical-align: middle; font-size: 16px; }
td.num, td .num { font-size: 15px; }
.r { text-align: right; }
td .cn { display: flex; align-items: center; gap: 10px; white-space: nowrap; }
td .ca { font-size: 13px; }
.docs .dgrid { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; align-items: start; }
.doc { display: flex; flex-direction: column; gap: 16px; }
.doc h2 { font-size: 16px; }
.doc p, .dl li { font: 500 15px/1.65 var(--num); }
.dl { margin: 0; padding-left: 20px; display: flex; flex-direction: column; gap: 12px; }
.dl b { font: 16px/1 var(--sk); margin-right: 6px; }
.kv { display: grid; grid-template-columns: 1fr auto; gap: 10px 16px; margin: 0; }
.kv dt { font: 16px/1.5 var(--sk); }
.kv dd { margin: 0; font: 600 15px var(--num); text-align: right; }
.split td { font: 16px/1.25 var(--sk); }
.split td.num { font-size: 15px; }
#split, #trust { grid-column: 1 / -1; }

/* 404 */
.lostp { display: flex; flex-direction: column; align-items: center; gap: 16px; }
.lostlcd { width: calc(var(--px) * 160); height: calc(var(--px) * 144); max-width: 100%; }
.lostart { width: 100%; height: 100%; display: block; }
.lostp .dialog { width: min(100%, calc(var(--px) * 170)); }

/* toasts = dialog boxes */
.toasts { position: fixed; left: 50%; bottom: 20px; transform: translateX(-50%); z-index: 90; display: flex; flex-direction: column; gap: 8px; width: min(560px, calc(100vw - 32px)); }
.toast { font-size: 16px; line-height: 1.75; padding-right: 48px; }
.toast a { font: 600 14px var(--num); }
.toast.err { background: var(--k); color: var(--w); border-color: var(--w); box-shadow: inset 0 0 0 var(--px) var(--k), inset 0 0 0 calc(var(--px) * 2) var(--w); animation: errb .3s steps(1) 3; }
.toast.err::after { background: var(--w); }
@keyframes errb { 50% { background: var(--w); color: var(--k); } }

/* wallet picker (kit) in the same skin */
dialog.dlg { background: var(--w); color: var(--k); border: var(--px) solid var(--k); box-shadow: inset 0 0 0 var(--px) var(--w), inset 0 0 0 calc(var(--px) * 2) var(--k); padding: 32px; width: min(480px, calc(100vw - 32px)); }
dialog.dlg::backdrop { background: var(--k) var(--dots) 0 0 / calc(var(--px) * 10) calc(var(--px) * 10); }
dialog.dlg h2 { font-size: 16px; margin-bottom: 20px; }
.dlg-x { position: absolute; right: 12px; top: 12px; width: 44px; height: 44px; border: 0; background: var(--k); color: var(--w); font-size: 20px; }
.wp-list { display: flex; flex-direction: column; gap: 4px; }
.wp-item { display: flex; align-items: center; gap: 12px; border: 0; background: none; padding: 10px 10px 10px 28px; position: relative; text-align: left; font-size: 16px; color: var(--k); min-height: 44px; }
.wp-item:hover { background: var(--k); color: var(--w); }
.wp-item img { width: 32px; height: 32px; }
.wp-dot { width: 16px; height: 16px; background: var(--d); }
.wp-get { display: flex; gap: 16px; flex-wrap: wrap; margin-top: 16px; font: 16px/1.25 var(--sk); }
.wp-get a { padding: 8px 0; }
.wp-cur { font: 16px/1.5 var(--sk); margin-bottom: 12px; }
.wp-cur .mono { font: 600 14px var(--num); }
.wp-off { margin-top: 16px; border: 0; background: var(--k); color: var(--w); padding: 10px 14px; font: 16px/1.25 var(--sk); }
.wp-err, .wp-none { font: 500 14px var(--num); margin-top: 12px; }

/* ---------------------------------------------------------------- responsive */
@media (max-width: 1100px) {
  .warhud, .howgrid, .zerogrid { grid-template-columns: 1fr; }
  .sheet { grid-template-columns: 1fr; }
  .sheet > .shead, .sheet > .slots, .sheet > .sstats { grid-column: 1; grid-row: auto; }
  .launch { grid-template-columns: 1fr; }
  .docs .dgrid { grid-template-columns: 1fr; }
}
@media (max-width: 900px) {
  .nav { position: absolute; left: 0; right: 0; top: 100%; margin: 0; background: var(--k); border-bottom: var(--px) solid var(--l); overflow-x: auto; padding: 0 var(--gut); scrollbar-width: none; }
  .nav::-webkit-scrollbar { display: none; }
  .nav a { padding: 12px 10px 12px 24px; white-space: nowrap; }
  .hdr { margin-bottom: 52px; }
  .hdr-act { margin-left: auto; }
  .hero-ui, .nightui, .save { grid-template-columns: 1fr; }
  .sec { padding-top: 88px; }
  .sech h1, .sech h2 { font-size: 24px; }
  .foot-in { grid-template-columns: 1fr; }
  .foot-ca { grid-row: auto; justify-self: start; }
}
@media (max-width: 560px) {
  .brand span { display: none; }
  .hdr .brand { order: 0; }
  .wbtn .bl { font: 16px/1.25 var(--sk); }
  .wbtn.on .bl { font-size: 13px; }
  .sech .sub, .rank .sy, .slots .sl, .list .nm, td { font: 16px/1.5 var(--sk); }
  .say { line-height: 1.75; }
  .war .dmg { margin: 0 calc(var(--gut) * -1); border-left: 0; border-right: 0; padding-left: 4px; padding-right: 4px; }
  .foot .brand span { display: inline; }
  .sech h1, .sech h2 { font-size: 16px; }
  .killer { font-size: 16px; }
  .box { padding: 16px 14px; }
  .shead { grid-template-columns: 1fr; }
  .stat dd { font-size: 20px; }
  .kgrid button { font-size: 16px; }
  .abtn.big .bl { font-size: 16px; }
  .ca { font-size: 13px; }
  .steps .mi { font: 16px/1.25 var(--sk); }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; }
  .mark.b { visibility: hidden; }
}
.fl { font: 16px/1.25 var(--sk); }

.lcol { display: flex; flex-direction: column; gap: 16px; }
.prevlcd { height: calc(var(--px) * 96); }
.insert { flex-direction: row; align-items: center; gap: 40px; }
.insert .markw { flex: none; }
.insert .ib { display: flex; flex-direction: column; align-items: flex-start; gap: 24px; }
@media (max-width: 560px) { .insert { flex-direction: column; align-items: flex-start; } }
.ca [data-cl] { word-break: break-all; overflow-wrap: anywhere; }
.steps .mi, .sacts .mi { min-height: 40px; }
.maplcd { min-height: calc(var(--px) * 176); }
@media (max-width: 900px) { .maplcd { min-height: calc(var(--px) * 208); } }
@media (max-width: 420px) { .maplcd { min-height: calc(var(--px) * 240); } }

/* ================================================================ design bar 10-23: one skin for every control
   cursors, icons, carets, scrollbars, selection, focus, loaders, toasts, dialogs and the overworld ground */
html { cursor: url(/assets/art/ui/cur-arrow-2x.png) 1 1, default; -webkit-tap-highlight-color: transparent; }
a, button, [role=button], [onclick], summary, label, .ca, [data-copy], .rank li.go, .vp, .vseek, .drop input, select, .mapcv.hot {
  cursor: url(/assets/art/ui/cur-hand-2x.png) 11 1, pointer;
}
.mapcv.grab { cursor: url(/assets/art/ui/cur-hand-2x.png) 11 1, grab; }
input:not([type=file]), textarea { cursor: url(/assets/art/ui/cur-beam-2x.png) 7 14, text; }
button:disabled, .hold li button:disabled { cursor: url(/assets/art/ui/cur-arrow-2x.png) 1 1, default; }

::selection { background: var(--k); color: var(--w); }
.hdr ::selection, .foot ::selection, .dmg ::selection { background: var(--w); color: var(--k); }

/* scrollbars: a K rail with a W thumb, square, 1 page-pixel inset (webkit/blink); Firefox gets the colours */
::-webkit-scrollbar { width: calc(var(--px) * 4); height: calc(var(--px) * 4); background: var(--k); }
::-webkit-scrollbar-track { background: var(--k); }
::-webkit-scrollbar-thumb { background: var(--w); border: var(--px) solid var(--k); box-shadow: inset calc(var(--px) * -1) calc(var(--px) * -1) 0 var(--l); }
::-webkit-scrollbar-thumb:hover { background: var(--l); }
::-webkit-scrollbar-button, ::-webkit-scrollbar-corner { display: none; background: var(--k); }
@supports not selector(::-webkit-scrollbar) { html, .tw, textarea, .nav { scrollbar-color: var(--w) var(--k); } }

/* focus: a hard 1-page-pixel ring with a gap, inverted on dark plates */
:focus-visible { outline: var(--px) solid var(--k); outline-offset: var(--px); box-shadow: 0 0 0 calc(var(--px) * 3) var(--w); }
.hdr :focus-visible, .foot :focus-visible, .dmg :focus-visible, .inv:focus-visible, .rank li.on:focus-visible { outline-color: var(--w); box-shadow: 0 0 0 calc(var(--px) * 3) var(--k); }
.mi:focus-visible, .kgrid button:focus-visible, .hold li button:focus-visible, .rank li:focus-visible, .ca:focus-visible { outline-offset: 0; box-shadow: none; }

/* pixel icons (8x8 masks, painted in currentColor) */
.ico { display: inline-block; width: calc(var(--px) * 4); height: calc(var(--px) * 4); min-width: 16px; min-height: 16px; background: currentColor; flex: none;
  -webkit-mask: var(--m) center / 100% 100% no-repeat; mask: var(--m) center / 100% 100% no-repeat; image-rendering: pixelated; }
.i-up { --m: var(--i-up); } .i-down { --m: var(--i-down); } .i-left { --m: var(--i-left); } .i-right { --m: var(--i-right); }
.i-close { --m: var(--i-close); } .i-ext { --m: var(--i-ext); } .i-copy { --m: var(--i-copy); }
.dpad button:active .ico, .stepper button:active .ico { transform: translateY(var(--px)); }
.dpad button:hover { background: var(--l); }
.stepper button:hover { background: var(--d); }
.calinks a { display: inline-flex; align-items: center; gap: 6px; }
.calinks a::after, .wp-get a::after, .foot-nav a[target]::after { content: ""; width: 12px; height: 12px; background: currentColor; -webkit-mask: var(--i-ext) center / 100% no-repeat; mask: var(--i-ext) center / 100% no-repeat; }
.foot-nav a[target] { display: inline-flex; align-items: center; gap: 8px; }
.wp-get a { display: inline-flex; align-items: center; gap: 8px; text-decoration: none; border-bottom: calc(var(--px) / 2) solid currentColor; }
.ca { position: relative; }
.ca::after { content: ""; display: inline-block; vertical-align: -2px; width: 14px; height: 14px; margin-left: 10px; background: currentColor; -webkit-mask: var(--i-copy) center / 100% no-repeat; mask: var(--i-copy) center / 100% no-repeat; }
.ca.inv::after { visibility: hidden; }

/* the menu cursor: slides to the hovered item in 2 steps (transform only) */
.nav a::before, .mi::before { transition: none; }
.mi:hover::before, .nav a:hover::before { animation: nudge .5s steps(1) infinite; }
@keyframes nudge { 50% { transform: translateX(calc(var(--px) / 2 + 1px)); } }

/* buttons: A/B discs get a hover highlight swap and a 2-frame press */
.abtn:not(:disabled):hover .disc, .bbtn:not(:disabled):hover .disc, .wbtn:hover .disc, .xbtn:hover .disc { box-shadow: inset var(--px) var(--px) 0 0 var(--l), inset calc(var(--px) * -1) calc(var(--px) * -1) 0 0 var(--k); }
.hdr .wbtn:hover .disc, .hdr .xbtn:hover .disc, .foot .xbtn:hover .disc { background: var(--l); box-shadow: inset var(--px) var(--px) 0 0 var(--w); }
.wbtn:hover .bl { text-decoration: underline; text-underline-offset: 6px; text-decoration-thickness: var(--px); }
/* loader: the busy disc becomes a 4-frame pixel wheel (rotate in 90 deg steps) */
.busy .disc { animation: none; position: relative; color: transparent; }
.busy .disc::after { content: ""; position: absolute; left: 50%; top: 50%; width: 12px; height: 12px; margin: -6px 0 0 -6px; background:
  linear-gradient(var(--w), var(--w)) 0 0 / 6px 6px no-repeat, linear-gradient(var(--l), var(--l)) 6px 6px / 6px 6px no-repeat; animation: wheel .48s steps(4) infinite; will-change: transform; }
.abtn.big.busy .disc::after { width: 16px; height: 16px; margin: -8px 0 0 -8px; background: linear-gradient(var(--w), var(--w)) 0 0 / 8px 8px no-repeat, linear-gradient(var(--l), var(--l)) 8px 8px / 8px 8px no-repeat; }
@keyframes wheel { to { transform: rotate(360deg); } }
.busy .bl::after { content: "..."; display: inline-block; width: 3ch; text-align: left; animation: dots 1.2s steps(4) infinite; clip-path: inset(0 100% 0 0); }
@keyframes dots { 0% { clip-path: inset(0 100% 0 0); } 25% { clip-path: inset(0 66% 0 0); } 50% { clip-path: inset(0 33% 0 0); } 75%, 100% { clip-path: inset(0 0 0 0); } }
.plate-t.wait::after, [data-live]:empty::after { content: "..."; display: inline-block; width: 3ch; animation: dots 1.2s steps(4) infinite; }

/* the naming screen: GB block caret, inverted active row, no browser chrome on any field */
.fld .caret { display: none; position: absolute; left: 0; top: 50%; width: 16px; height: 16px; margin-top: -8px; background: currentColor; pointer-events: none; will-change: transform; }
.fld.on .caret { display: block; animation: blink 1s steps(1) infinite; }
.fld { cursor: inherit; }
.fld input { -webkit-appearance: none; appearance: none; border-radius: 0; }
.fld input::selection { background: var(--w); color: var(--k); }
.tf input, .tf textarea { -webkit-appearance: none; appearance: none; border-radius: 0; caret-color: var(--k); caret-shape: block; }
.tf input:focus, .tf textarea:focus { background: var(--k); color: var(--w); caret-color: var(--w); border-bottom-color: var(--k); }
.tf textarea { overflow-y: auto; }
input:-webkit-autofill, input:-webkit-autofill:hover, input:-webkit-autofill:focus, textarea:-webkit-autofill {
  -webkit-text-fill-color: currentColor; -webkit-box-shadow: 0 0 0 1000px transparent inset; transition: background-color 99999s steps(1); }
input::placeholder, textarea::placeholder { color: var(--l); opacity: 1; }
.kgrid button { position: relative; }
.kgrid button:active { transform: translateY(var(--px)); }
.kgrid button.wide, .kgrid .case { background: var(--l); }
.kgrid button.wide:hover, .kgrid .case:hover { background: var(--k); }
.stepper output { background: var(--k); color: var(--w); padding: 8px 4px; }
.drop { outline: var(--px) dashed var(--k); outline-offset: calc(var(--px) * -2); }
.drop.over { outline-style: solid; animation: blink .5s steps(1) 3; }
.drop:focus-within { outline-style: solid; }
.drop:hover .dropt { background: var(--k); color: var(--w); }

/* dialogs (wallet picker) and toasts: GB boxes that open by unrolling in 4 steps */
dialog.dlg[open] { animation: unroll .2s steps(4) both; transform-origin: 50% 0; }
dialog.dlg::backdrop { background: var(--k) url(/assets/art/ui/g-night.png) 0 0 / calc(var(--px) * 96) calc(var(--px) * 96); opacity: .92; }
@keyframes unroll { from { transform: scaleY(.25); } to { transform: none; } }
.dlg-x { font-size: 0 !important; display: grid; place-items: center; }
.dlg-x::before { content: ""; width: 16px; height: 16px; background: currentColor; -webkit-mask: var(--i-close) center / 100% no-repeat; mask: var(--i-close) center / 100% no-repeat; }
.dlg-x:hover { background: var(--d); }
.dlg-x:active::before { transform: translateY(var(--px)); }
.wp-item::before { content: ""; position: absolute; left: 6px; top: 50%; width: 8px; height: 12px; margin-top: -6px; background: currentColor; clip-path: polygon(0 0, 25% 0, 25% 17%, 50% 17%, 50% 33%, 75% 33%, 75% 50%, 100% 50%, 100% 50%, 75% 50%, 75% 67%, 50% 67%, 50% 83%, 25% 83%, 25% 100%, 0 100%); visibility: hidden; }
.wp-item:hover::before, .wp-item:focus-visible::before { visibility: visible; animation: blink 1s steps(1) infinite; }
.wp-item img { filter: url(#dmg); image-rendering: pixelated; border: calc(var(--px) / 2) solid var(--k); }
.wp-item:hover img { border-color: var(--w); }
.wp-off:hover { background: var(--d); }
.toast { animation: tin .2s steps(4) both; }
.toast.err { animation: tin .2s steps(4) both, errb .3s steps(1) .2s 3; }
@keyframes tin { from { transform: translateY(calc(var(--px) * 8)); opacity: 0; } 25% { opacity: 1; } to { transform: none; opacity: 1; } }
svg.defs { position: absolute; width: 0; height: 0; overflow: hidden; }

/* ---- the ground: the page is an overworld; every screen has its own soil, a dirt road between screens,
   and the grass bends with the wind (2-frame swap of a second layer, opacity only) */
.home main { position: relative; }
.hero, .sec { position: relative; isolation: isolate; }
.hero::before, .sec::before, .sec::after {
  content: ""; position: absolute; top: 0; bottom: 0; left: 50%; width: 100vw; margin-left: -50vw; z-index: -1; pointer-events: none;
  background-size: calc(var(--px) * 96) calc(var(--px) * 96); image-rendering: pixelated;
}
.hero::before { top: -24px; background-image: url(/assets/art/ui/g-meadow-wind.png); animation: wind 1.6s steps(1) infinite; opacity: 0; will-change: opacity; background-position: calc(50% + 0px) 0; }
.sec { --road: calc(var(--px) * 16); --roady: 40px; }
.sec::before { background-image: url(/assets/art/ui/road.png), url(/assets/art/ui/g-meadow.png); background-size: calc(var(--px) * 32) var(--road), calc(var(--px) * 96) calc(var(--px) * 96); background-repeat: repeat-x, repeat; background-position: 0 var(--roady), 0 0; }
.sec::after { top: calc(var(--roady) + var(--road)); background-image: url(/assets/art/ui/g-meadow-wind.png); animation: wind 1.6s steps(1) infinite; opacity: 0; will-change: opacity; }
.war::before { background-image: url(/assets/art/ui/road.png), url(/assets/art/ui/g-pasture.png); }
.war::after { background-image: url(/assets/art/ui/g-pasture-wind.png); animation-delay: -.4s; }
.how::before { background-image: url(/assets/art/ui/road.png), url(/assets/art/ui/g-field.png); }
.how::after { background-image: url(/assets/art/ui/g-field-wind.png); animation-delay: -.8s; }
.night::before { background-image: url(/assets/art/ui/road.png), url(/assets/art/ui/g-night.png); }
.night::after { background-image: url(/assets/art/ui/g-night-wind.png); animation-delay: -1.2s; }
@keyframes wind { 0% { opacity: 0; } 50% { opacity: 1; } }
.sec { padding-top: calc(var(--roady) + var(--road) + 48px); }
.sech h1, .sech h2 { text-shadow: var(--px) var(--px) 0 var(--k); }
.sech .sub { background: var(--k); color: var(--l); padding: 8px 12px; width: fit-content; max-width: 72ch; }
.page .sech .sub { color: var(--w); }
.foot { position: relative; z-index: 1; }
@media (max-width: 900px) { .sec { --roady: 28px; } .sec { padding-top: calc(var(--roady) + var(--road) + 36px); } }
@media (prefers-reduced-motion: reduce) { .hero::before, .sec::after { animation: none; opacity: 0; } .busy .disc::after { animation: none; } }
.killer { background: var(--k); padding: 12px 16px; width: fit-content; max-width: min(100%, 44ch); }
td .ca { font-size: 12px; white-space: nowrap; word-break: normal; overflow-wrap: normal; }
td .ca [data-cl] { word-break: normal; overflow-wrap: normal; }
.ca { margin: -9px 0; padding: 9px 4px; max-width: 100%; }
