/* Hot Potato Pad: a night kitchen yard. Iron and soot plates with a 1px tallow bevel and a hard 3px drop,
   enamel tags for buttons, ember only for the potato and its heat, butter only for the jackpot.
   Type: Bricolage Grotesque (condensed 75, opsz 96 for display, sentence case) and Red Hat Mono for numbers.
   Scale 1.25: 11 / 12.5 / 14 / 17.5 / 22 / 27 / 34 / 42. Spacing 4 / 8 / 12 / 16 / 24 / 32 / 48. */
:root {
  --iron: #1a1613; --iron-2: #14110f; --soot: #2b2521; --soot-2: #231e1b; --soot-3: #332c27;
  --tallow: #efe2c6; --tallow-2: rgba(239, 226, 198, .72); --tallow-3: rgba(239, 226, 198, .5); --ash: #8f8375;
  --ember: #df5f27; --ember-2: #b8491a; --butter: #efc54c;
  --rule: rgba(239, 226, 198, .12); --rule-2: rgba(239, 226, 198, .2); --drop: 0 3px 0 #000;
  --bevel: inset 0 1px 0 rgba(239, 226, 198, .08), inset 0 -1px 0 rgba(0, 0, 0, .45);
  --r: 12px; --r-s: 10px; --r-xs: 6px;
  --f-d: "Bricolage Grotesque", "Arial Narrow", sans-serif; --f-m: "Red Hat Mono", ui-monospace, monospace;
  --ease: cubic-bezier(.2, .7, .2, 1); --t: 180ms;
  --gut: 16px;
}
* { box-sizing: border-box; }
[hidden] { display: none !important; }
html, body { margin: 0; height: 100%; }
body {
  background: var(--iron); color: var(--tallow); overflow: hidden;
  font: 400 14px/1.45 var(--f-d); font-variation-settings: "wdth" 100, "opsz" 14;
  -webkit-font-smoothing: antialiased; text-rendering: optimizeLegibility;
}
button, input { font: inherit; color: inherit; }
button { cursor: pointer; }
a { color: inherit; }
img { display: block; }
.sr, .skip:not(:focus) { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.skip:focus { position: fixed; z-index: 50; left: 12px; top: 12px; background: var(--tallow); color: var(--iron); padding: 8px 12px; border-radius: 8px; }
:focus-visible { outline: 2px solid var(--butter); outline-offset: 2px; }
.k, .dlg-k { font: 500 11px/1 var(--f-m); letter-spacing: .12em; text-transform: uppercase; color: var(--ash); }
b { font-weight: 600; }

/* ---------------------------------------------------------------- the yard */
.yard { position: fixed; inset: 0; z-index: 0; cursor: grab; }
.yard > .bar, .yard > main { cursor: auto; }
.yard-gl { position: absolute; inset: 0; width: 100%; height: 100%; display: block; cursor: grab; touch-action: none; opacity: 0; transition: opacity 1.2s var(--ease); }
.yard-gl:active { cursor: grabbing; }
.gl-ready .yard-gl { opacity: 1; }
.yard-poster {
  position: absolute; inset: 0; background: url(/assets/scene/og-plate.jpg) 70% 60% / cover no-repeat;
  filter: brightness(.55) saturate(.9); transition: opacity 1.2s var(--ease);
}
.gl-ready .yard-poster { opacity: 0; }
.yard-shade {
  position: absolute; inset: 0; pointer-events: none;
  background:
    radial-gradient(120% 85% at 50% 58%, transparent 45%, rgba(10, 8, 7, .55) 80%, rgba(10, 8, 7, .85) 100%),
    linear-gradient(180deg, rgba(10, 8, 7, .7), transparent 18%, transparent 78%, rgba(10, 8, 7, .75));
}
.yard-shade::after { /* grain */
  content: ""; position: absolute; inset: 0; opacity: .07; mix-blend-mode: overlay;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='160' height='160'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.9' numOctaves='3' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
}
.yard-plates, .yard-anchors { position: absolute; inset: 0; pointer-events: none; }
.yard-plates > *, .yard-anchors > * { position: absolute; left: 0; top: 0; will-change: transform; }
.plate {
  font: 500 11px/1 var(--f-m); white-space: nowrap; display: flex; gap: 6px; align-items: baseline;
  padding: 5px 7px 4px; border-radius: 6px; background: rgba(20, 17, 15, .86); border: 1px solid var(--rule); color: var(--tallow-2);
  box-shadow: 0 2px 0 rgba(0, 0, 0, .7);
}
.plate b { color: var(--tallow); font-weight: 600; }
.plate span { color: var(--ash); }
.plate.is-holder { background: var(--ember); border-color: #f08a55; color: #1a0e08; }
.plate.is-holder b, .plate.is-holder span { color: #1a0e08; }
.plate.is-cold { background: var(--soot-3); border-color: var(--rule-2); }
.plate.is-cold b, .plate.is-cold span { color: var(--tallow-2); }
.plate.is-me { outline: 1px solid var(--butter); outline-offset: 1px; }
.brass {
  pointer-events: auto; display: flex; align-items: center; gap: 8px; padding: 6px 8px 6px 10px; border-radius: 6px;
  background: linear-gradient(180deg, #a07c3c, #7a5c29); color: #22170a; border: 1px solid #c49a50;
  box-shadow: inset 0 1px 0 rgba(255, 236, 190, .45), 0 2px 0 #000; margin-top: 18px;
}
.brass-k { font: 600 10px/1 var(--f-m); letter-spacing: .12em; text-transform: uppercase; }
.brass-ca { border: 0; background: rgba(34, 23, 10, .18); border-radius: 4px; padding: 5px 7px; min-height: 32px; font: 600 12px/1 var(--f-m); cursor: pointer; }
.brass-ca:hover { background: rgba(34, 23, 10, .3); }
.jackpot {
  display: grid; justify-items: center; gap: 4px; padding: 8px 12px 9px; border-radius: 10px; text-align: center;
  background: rgba(20, 17, 15, .9); border: 1px solid rgba(239, 197, 76, .45); box-shadow: 0 3px 0 #000; margin-top: -8px;
}
.jackpot-k { font: 500 10px/1 var(--f-m); letter-spacing: .14em; text-transform: uppercase; color: rgba(239, 197, 76, .8); }
.jackpot-v { font: 500 13px/1 var(--f-m); color: var(--butter); font-variant-numeric: tabular-nums; white-space: nowrap; }
.jackpot-v b { font: 800 22px/1 var(--f-d); font-variation-settings: "wdth" 75, "opsz" 96; letter-spacing: -.01em; }
.jackpot-v i { font-style: normal; color: rgba(239, 197, 76, .7); margin-left: 4px; }
.jackpot.hot { border-color: var(--butter); }

/* ---------------------------------------------------------------- bar */
.bar {
  position: fixed; z-index: 5; top: 0; left: 0; right: 0; height: 64px; padding: 0 20px;
  display: grid; grid-template-columns: auto 1fr auto auto; align-items: center; gap: 24px;
}
.brand { display: flex; align-items: center; gap: 10px; text-decoration: none; min-height: 40px; }
.brand-mark { width: 30px; height: 30px; border-radius: 7px; }
.brand-name { margin: 0; font: 800 24px/1 var(--f-d); font-variation-settings: "wdth" 75, "opsz" 96; letter-spacing: -.01em; }
.brand-line { margin: 0; font-size: 14px; color: var(--tallow-3); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.bar-nav { display: flex; gap: 4px; }
.bar-nav a { text-decoration: none; font: 500 13px/1 var(--f-d); padding: 10px 12px; border-radius: 8px; color: var(--tallow-2); transition: color var(--t), background var(--t); }
.bar-nav a:hover { color: var(--tallow); background: rgba(239, 226, 198, .06); }
.bar-log span { font: 500 11px/1 var(--f-m); color: var(--ash); margin-left: 2px; }
.bar-acts { display: flex; gap: 8px; align-items: center; }

/* ---------------------------------------------------------------- buttons: enamel tags */
.tag {
  --bg: var(--tallow); --fg: var(--iron);
  position: relative; display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 42px; padding: 0 18px;
  border: 0; border-radius: var(--r-s); background: var(--bg); color: var(--fg);
  font: 700 14px/1 var(--f-d); font-variation-settings: "wdth" 88, "opsz" 24; letter-spacing: .005em; white-space: nowrap;
  box-shadow: 0 3px 0 #000, inset 0 1px 0 rgba(255, 255, 255, .45), inset 0 -2px 0 rgba(0, 0, 0, .14);
  transition: transform 90ms steps(2), box-shadow 90ms steps(2), background var(--t);
}
.tag:hover { background: #f7ecd4; }
.tag:active { transform: translateY(3px); box-shadow: 0 0 0 #000, inset 0 1px 0 rgba(255, 255, 255, .3), inset 0 -1px 0 rgba(0, 0, 0, .14); }
.tag:disabled { opacity: .45; cursor: not-allowed; transform: none; }
.tag[aria-busy="true"] { cursor: progress; }
.tag[aria-busy="true"]::after { content: ""; position: absolute; left: 12px; right: 12px; bottom: 6px; height: 2px; background: currentColor; opacity: .5; transform-origin: left; animation: fuse 1.2s linear infinite; }
@keyframes fuse { from { transform: scaleX(0); } to { transform: scaleX(1); opacity: 0; } }
.tag svg { width: 18px; height: 18px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.tag-dark { --bg: var(--soot-3); --fg: var(--tallow); box-shadow: 0 3px 0 #000, inset 0 1px 0 rgba(239, 226, 198, .1), inset 0 0 0 1px var(--rule); }
.tag-dark:hover { background: #3c342e; }
.tag-dark.is-on { --fg: var(--tallow); font-family: var(--f-m); font-weight: 500; font-size: 13px; }
.tag-hot svg { fill: var(--ember); stroke: var(--iron); }
.tag-hot.is-mine { --bg: var(--ember); --fg: #1a0e08; }
.tag-hot.is-mine svg { fill: #1a0e08; }
.icon-btn {
  display: inline-grid; place-items: center; width: 40px; height: 40px; border-radius: 9px; border: 1px solid var(--rule); background: rgba(35, 30, 27, .8); color: var(--tallow-2);
  transition: color var(--t), background var(--t), border-color var(--t);
}
.icon-btn:hover { color: var(--tallow); background: var(--soot-3); border-color: var(--rule-2); }
.icon-btn svg { width: 18px; height: 18px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
[data-sound] .snd-on { display: none; }
[data-sound].is-on .snd-on { display: inline; }
[data-sound].is-on .snd-off { display: none; }
[data-sound].is-on { color: var(--tallow); }

/* ---------------------------------------------------------------- plates (panels) */
.coin, .log, .dock, .dlg-in {
  background: linear-gradient(180deg, rgba(43, 37, 33, .96), rgba(33, 28, 25, .96));
  border: 1px solid var(--rule); border-radius: var(--r); box-shadow: var(--bevel), var(--drop);
}

/* ---------------------------------------------------------------- the coin card */
.coin { position: fixed; z-index: 4; left: 20px; top: 76px; width: 336px; padding: 16px; }
.coin-skel { display: grid; gap: 10px; }
.coin-skel i { display: block; height: 16px; border-radius: 6px; background: linear-gradient(90deg, var(--soot-3) 0 40%, #3d352f 50%, var(--soot-3) 60% 100%) 0 0 / 300% 100%; animation: sk 1.6s linear infinite; }
.coin-skel i:first-child { height: 56px; width: 56px; border-radius: 50%; }
.coin-skel i:last-child { width: 60%; }
@keyframes sk { to { background-position: -150% 0; } }
.cc-top { display: grid; grid-template-columns: 72px 1fr auto; gap: 12px; align-items: center; }
.cc-pic { position: relative; width: 72px; height: 72px; display: grid; place-items: center; }
.cc-pic img, .cc-pic .pic-none { width: 56px; height: 56px; border-radius: 50%; object-fit: cover; background: var(--soot-3); }
.cc-pic-empty img { width: 40px; height: 40px; border-radius: 9px; }
.cc-ring { position: absolute; inset: 0; transform: rotate(-90deg); }
.cc-ring circle { fill: none; stroke-width: 3; }
.ring-bg { stroke: rgba(239, 226, 198, .1); }
.ring-fg { stroke: var(--ember); stroke-linecap: round; transition: stroke-dashoffset 1s linear; }
.cc-id { min-width: 0; }
.cc-state { margin: 0 0 4px; font: 500 10.5px/1 var(--f-m); letter-spacing: .12em; text-transform: uppercase; color: var(--ash); display: flex; align-items: center; gap: 6px; }
.cc-state::before { content: ""; width: 6px; height: 6px; border-radius: 2px; background: var(--ash); }
.s-live::before { background: var(--ember); }
.s-stretch::before { background: var(--butter); }
.s-fresh::before { background: var(--tallow); }
.s-served::before { background: transparent; box-shadow: inset 0 0 0 1px var(--ash); }
.cc-name { margin: 0; font: 800 27px/1 var(--f-d); font-variation-settings: "wdth" 75, "opsz" 96; letter-spacing: -.01em; overflow-wrap: anywhere; }
.cc-sym { margin: 4px 0 0; font: 500 12.5px/1 var(--f-m); color: var(--tallow-3); }
.cc-share { align-self: start; }
.cc-holdrow { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; margin: 14px 0 0; padding: 10px 0 0; border-top: 1px solid var(--rule); font-size: 13px; color: var(--tallow-2); }
.cc-hold b { font: 500 12.5px var(--f-m); color: var(--tallow); }
.cc-time { font: 500 17px/1 var(--f-m); color: var(--ember); font-variant-numeric: tabular-nums; }
.cc-cold { color: var(--ash); font-size: 12.5px; letter-spacing: .1em; text-transform: uppercase; }
.cc-pr { margin: 14px 0 0; }
.cc-k { margin: 0; font: 500 11px/1 var(--f-m); letter-spacing: .12em; text-transform: uppercase; color: var(--ash); }
.cc-price { margin: 6px 0 0; display: flex; align-items: baseline; gap: 8px; }
.cc-price b { font: 800 42px/.95 var(--f-d); font-variation-settings: "wdth" 75, "opsz" 96; letter-spacing: -.02em; font-variant-numeric: tabular-nums; }
.cc-price span { font: 500 14px var(--f-m); color: var(--tallow-3); }
.cc-price .dg { display: inline-block; font-style: normal; }
.cc-price .dg.roll { animation: dg .5s var(--ease) both; }
@keyframes dg { from { transform: translateY(-.45em); opacity: 0; } to { transform: none; opacity: 1; } }
.cc-price-s { font: 700 22px/1.1 var(--f-d); font-variation-settings: "wdth" 80, "opsz" 48; }
.cc-curve { margin: 14px 0 0; }
.bar-wrap, .cc-curve .bar { position: relative; height: 8px; border-radius: 3px; background: repeating-linear-gradient(90deg, rgba(239, 226, 198, .09) 0 6px, transparent 6px 8px); }
.cc-curve .bar i { position: absolute; left: 0; top: 0; bottom: 0; border-radius: 3px; background: repeating-linear-gradient(90deg, var(--ember) 0 6px, transparent 6px 8px); transition: width .8s var(--ease); }
.cc-curve .bar em { position: absolute; top: -4px; bottom: -4px; width: 2px; margin-left: -1px; background: var(--butter); border-radius: 1px; }
.cc-curve p { display: flex; justify-content: space-between; margin: 8px 0 0; font: 500 11px/1 var(--f-m); color: var(--ash); letter-spacing: .04em; }
.cc-foot { display: flex; align-items: center; gap: 6px; margin: 14px -4px -4px; padding-top: 12px; border-top: 1px solid var(--rule); }
.cc-foot .icon-btn { width: 34px; height: 34px; }
.cc-n { font: 500 12px/1 var(--f-m); color: var(--ash); padding: 0 4px; font-variant-numeric: tabular-nums; }
.cc-more { margin-left: auto; border: 0; background: none; font: 600 13px/1 var(--f-d); color: var(--tallow-2); padding: 10px 8px; border-radius: 8px; }
.cc-more + .cc-more { margin-left: 0; }
.cc-more:hover { color: var(--tallow); background: rgba(239, 226, 198, .06); }
.cc-lede { margin: 12px 0 0; color: var(--tallow-2); font-size: 14px; max-width: 32ch; }
.cc-facts { margin: 14px 0 0; display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; }
.cc-facts div { padding: 10px; border-radius: 8px; background: rgba(20, 17, 15, .5); border: 1px solid var(--rule); }
.cc-facts dt { font: 500 10px/1.2 var(--f-m); letter-spacing: .1em; text-transform: uppercase; color: var(--ash); }
.cc-facts dd { margin: 6px 0 0; font: 700 15px/1.1 var(--f-d); font-variation-settings: "wdth" 85, "opsz" 24; }
.cc-foot .tag { width: 100%; }

/* ---------------------------------------------------------------- the pass log */
.log { position: fixed; z-index: 4; right: 20px; top: 76px; max-height: calc(100vh - 180px); width: 330px; display: flex; flex-direction: column; overflow: hidden; }
.log-h { display: flex; align-items: baseline; gap: 10px; padding: 14px 16px 12px; border-bottom: 1px solid var(--rule); }
.log-h h2 { margin: 0; font: 800 22px/1 var(--f-d); font-variation-settings: "wdth" 75, "opsz" 96; }
.log-n { font: 500 11px/1 var(--f-m); color: var(--ash); letter-spacing: .08em; text-transform: uppercase; }
.log-x { display: none; margin-left: auto; }
.log-list { list-style: none; margin: 0; padding: 4px 0; overflow-y: auto; flex: 1; perspective: 900px; scrollbar-width: thin; scrollbar-color: var(--soot-3) transparent; }
.lr { position: relative; padding: 11px 16px 11px 30px; border-bottom: 1px solid rgba(239, 226, 198, .06); transform-origin: 50% 0; }
.lr::before { content: ""; position: absolute; left: 15px; top: 16px; width: 7px; height: 7px; border-radius: 2px; background: var(--ash); }
.r-take::before { background: var(--ember); border-radius: 50% 60% 45% 55%; width: 9px; left: 14px; }
.r-ref::before { background: transparent; box-shadow: inset 0 0 0 1.5px var(--ember); }
.r-str::before, .r-jp::before { background: var(--butter); }
.r-srv::before { background: transparent; box-shadow: inset 0 0 0 1.5px var(--butter); }
.r-launch::before { background: var(--tallow); }
.lr-main { margin: 0; display: flex; gap: 8px; justify-content: space-between; font-size: 14px; color: var(--tallow-2); padding-right: 44px; }
.lr-main b { font: 500 12.5px var(--f-m); color: var(--tallow); }
.lr-main { align-items: center; }
.av { flex: none; width: 22px; height: 33px; margin: -10px 0 -8px -2px; background: url(/assets/scene/crowd.webp) no-repeat; background-size: 132px 66px; background-position: calc(var(--k) * -22px) 0; }
.lr-who { display: flex; align-items: center; gap: 6px; min-width: 0; }
.lr:has(.av)::before { display: none; }
.lr:has(.av) { padding-left: 18px; }
.lr:has(.av) .lr-sub { padding-left: 24px; }
.lr-amt { font: 500 13px var(--f-m); color: var(--tallow); font-variant-numeric: tabular-nums; }
.r-jp .lr-amt, .r-srv .lr-amt { color: var(--butter); }
.lr-sub { margin: 3px 0 0; font-size: 12.5px; color: var(--ash); line-height: 1.35; }
.lr-t { position: absolute; right: 10px; top: 4px; font: 500 11px/1 var(--f-m); color: var(--ash); text-decoration: none; padding: 11px 6px; }
.lr-t:hover { color: var(--tallow); text-decoration: underline; }
.lr-in { animation: roll .7s var(--ease) both; }
@keyframes roll { from { opacity: 0; transform: rotateX(40deg) translateY(-6px); } to { opacity: 1; transform: none; } }
.log-empty { display: grid; justify-items: start; gap: 12px; padding: 22px 18px; color: var(--tallow-2); }
.log-empty svg { width: 44px; height: 44px; fill: none; stroke: var(--ash); stroke-width: 1.6; stroke-linecap: round; stroke-linejoin: round; }
.log-empty p { margin: 0; font-size: 14px; max-width: 30ch; }

/* ---------------------------------------------------------------- the dock */
.dock {
  position: fixed; z-index: 4; left: 50%; bottom: 20px; transform: translateX(-50%);
  display: flex; align-items: center; gap: 8px; padding: 10px;
}
.dock-take { min-width: 200px; min-height: 48px; font-size: 16px; }
.dock-sep { width: 1px; align-self: stretch; margin: 4px 6px; background: var(--rule); }
.dock-key {
  position: relative; display: inline-flex; flex-direction: column; align-items: center; gap: 4px; min-width: 62px; padding: 7px 8px 6px; border: 0; border-radius: 9px; background: none; color: var(--tallow-2);
  font: 600 11.5px/1 var(--f-d); transition: color var(--t), background var(--t);
}
.dock-key:hover { color: var(--tallow); background: rgba(239, 226, 198, .07); }
.dock-key svg { width: 20px; height: 20px; fill: none; stroke: currentColor; stroke-width: 1.7; stroke-linecap: round; stroke-linejoin: round; }
.dock-dot { position: absolute; top: 2px; right: 10px; min-width: 16px; height: 16px; padding: 0 4px; border-radius: 8px; background: var(--butter); color: var(--iron); font: 700 10px/16px var(--f-m); }
.dock-logkey { display: none; }
.demo-tag {
  position: fixed; z-index: 4; left: 50%; bottom: 96px; transform: translateX(-50%); margin: 0;
  font: 500 11px/1 var(--f-m); letter-spacing: .14em; text-transform: uppercase; color: var(--tallow-2);
  padding: 7px 10px; border-radius: 6px; border: 1px dashed var(--rule-2); background: rgba(20, 17, 15, .7); white-space: nowrap;
}

/* ---------------------------------------------------------------- dialogs */
.dlg { padding: 0; border: 0; background: none; color: var(--tallow); max-width: min(480px, calc(100vw - 24px)); width: 100%; overflow: visible; }
.dlg-wide { max-width: min(860px, calc(100vw - 24px)); }
.dlg::backdrop { background: rgba(10, 8, 7, .72); }
.dlg[open] .dlg-in { animation: pop .28s var(--ease); }
@keyframes pop { from { opacity: 0; transform: translateY(10px); } to { opacity: 1; transform: none; } }
.dlg-in { position: relative; margin: 0; padding: 24px; max-height: calc(100dvh - 32px); overflow-y: auto; }
.dlg-in::before { content: ""; position: absolute; left: 24px; right: 24px; top: 0; height: 2px; background: var(--ember); border-radius: 0 0 2px 2px; }
.dlg-x { position: absolute; right: 14px; top: 14px; }
.dlg-k { margin: 0 44px 8px 0; }
.dlg-h { margin: 0; font: 800 34px/1 var(--f-d); font-variation-settings: "wdth" 75, "opsz" 96; letter-spacing: -.015em; }
.dlg-lede { margin: 12px 0 0; color: var(--tallow-2); max-width: 48ch; }
.dlg-lede b { color: var(--tallow); }
.dlg-err { margin: 14px 0 0; padding: 10px 12px; border-radius: 8px; background: rgba(223, 95, 39, .12); border: 1px solid rgba(223, 95, 39, .4); color: #f3b08e; font-size: 13.5px; }
.dlg-acts { display: flex; justify-content: flex-end; gap: 8px; margin-top: 20px; }
.dlg-acts .tag { min-width: 60%; }
.seg { border: 0; padding: 0; margin: 20px 0 0; min-width: 0; }
.seg legend { padding: 0; margin-bottom: 8px; display: flex; gap: 6px; align-items: center; }
.seg-row { position: relative; display: grid; grid-auto-flow: column; grid-auto-columns: 1fr; gap: 4px; padding: 4px; border-radius: 10px; background: rgba(20, 17, 15, .6); border: 1px solid var(--rule); }
.seg-b { position: relative; z-index: 1; display: grid; gap: 3px; justify-items: center; min-height: 44px; padding: 7px 6px; border: 0; border-radius: 7px; background: none; color: var(--tallow-2); transition: color var(--t); }
.seg-b b { font: 500 14px/1 var(--f-m); font-variant-numeric: tabular-nums; }
.seg-b span { font: 500 10px/1 var(--f-m); color: var(--ash); letter-spacing: .06em; text-transform: uppercase; }
.seg-b:hover { color: var(--tallow); }
.seg-b[aria-checked="true"] { color: var(--iron); }
.seg-b[aria-checked="true"] span { color: rgba(26, 22, 19, .6); }
.seg-thumb { position: absolute; z-index: 0; left: 0; top: 4px; border-radius: 7px; background: var(--tallow); box-shadow: 0 2px 0 #000, inset 0 1px 0 rgba(255, 255, 255, .5); transition: transform .26s var(--ease), width .26s var(--ease); }
.sum { margin: 18px 0 0; display: grid; gap: 0; border-top: 1px solid var(--rule); }
.sum div { display: grid; grid-template-columns: 120px 1fr; gap: 12px; padding: 10px 0; border-bottom: 1px solid var(--rule); }
.sum dt { font: 500 11px/1.5 var(--f-m); letter-spacing: .1em; text-transform: uppercase; color: var(--ash); }
.sum dd { margin: 0; font: 500 14px/1.4 var(--f-m); font-variant-numeric: tabular-nums; }
.sum small { display: block; font: 400 12.5px/1.35 var(--f-d); color: var(--ash); margin-top: 2px; }
.hint { display: inline-grid; place-items: center; width: 16px; height: 16px; border-radius: 50%; border: 1px solid var(--rule-2); font: 600 10px/1 var(--f-m); color: var(--ash); cursor: help; position: relative; text-transform: none; letter-spacing: 0; }
.hint:hover::after, .hint:focus::after {
  content: attr(data-tip); position: absolute; z-index: 3; left: 50%; bottom: calc(100% + 8px); transform: translateX(-50%); width: 240px; padding: 10px 12px; border-radius: 8px;
  background: var(--iron); border: 1px solid var(--rule-2); box-shadow: var(--drop); font: 400 12.5px/1.4 var(--f-d); color: var(--tallow-2); text-align: left;
}
/* launch */
.launch { display: grid; grid-template-columns: 1fr 260px; gap: 28px; }
.field-row { display: grid; grid-template-columns: 1fr 130px; gap: 10px; margin-top: 20px; }
.field { display: grid; gap: 8px; min-width: 0; }
.field input { width: 100%; min-width: 0; }
.field input:not([type=file]) {
  min-height: 44px; padding: 0 12px; border-radius: 9px; border: 1px solid var(--rule-2); background: rgba(20, 17, 15, .7); color: var(--tallow);
  font: 500 15px var(--f-d); transition: border-color var(--t);
}
.field input:focus { outline: none; border-color: var(--tallow-2); }
.field input::placeholder { color: rgba(239, 226, 198, .28); }
.file { margin-top: 14px; position: relative; }
.file input { position: absolute; inset: 22px 0 0; opacity: 0; cursor: pointer; }
.file-lab { display: flex; align-items: center; min-height: 44px; padding: 0 12px; border-radius: 9px; border: 1px dashed var(--rule-2); color: var(--ash); font-size: 13.5px; }
.file:hover .file-lab { border-color: var(--tallow-3); color: var(--tallow-2); }
.launch-prev { align-self: start; padding: 18px; border-radius: 10px; background: rgba(20, 17, 15, .55); border: 1px solid var(--rule); display: grid; gap: 14px; margin-top: 30px; }
.prev-card { display: grid; justify-items: center; gap: 6px; text-align: center; padding: 8px 0; }
.prev-pic { width: 88px; height: 88px; border-radius: 50%; background: var(--soot-3); box-shadow: 0 0 0 3px var(--iron), 0 0 0 5px var(--ember); overflow: hidden; margin-bottom: 8px; }
.prev-pic img { width: 100%; height: 100%; object-fit: cover; }
.prev-name { font: 800 24px/1 var(--f-d); font-variation-settings: "wdth" 75, "opsz" 96; overflow-wrap: anywhere; }
.prev-sym { font: 500 12.5px var(--f-m); color: var(--tallow-3); }
.prev-price { margin-top: 8px; font-size: 13px; color: var(--ash); }
.prev-price b { font: 500 13px var(--f-m); color: var(--tallow); }
.prev-note { margin: 0; font-size: 12.5px; color: var(--ash); }
/* coins */
.coins { margin-top: 20px; display: grid; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); gap: 10px; }
.ck {
  display: grid; grid-template-columns: 64px 1fr; grid-template-rows: auto auto auto; column-gap: 12px; row-gap: 6px; align-items: center; text-align: left;
  padding: 12px; border-radius: 10px; border: 1px solid var(--rule); background: rgba(20, 17, 15, .45); box-shadow: 0 2px 0 #000; transition: border-color var(--t), background var(--t);
}
.ck:hover { border-color: var(--rule-2); background: rgba(20, 17, 15, .7); }
.ck.is-sel { border-color: var(--tallow-3); }
.ck-pic { grid-row: 1 / 4; }
.ck-pic img, .ck-pic .pic-none { width: 64px; height: 64px; border-radius: 10px; object-fit: cover; background: var(--soot-3); }
.ck-id b { display: block; font: 800 19px/1 var(--f-d); font-variation-settings: "wdth" 75, "opsz" 96; }
.ck-id i { font: 500 11.5px var(--f-m); font-style: normal; color: var(--tallow-3); }
.ck-st { font: 500 10px/1 var(--f-m); letter-spacing: .1em; text-transform: uppercase; color: var(--ash); display: flex; gap: 6px; align-items: center; }
.ck-st::before { content: ""; width: 6px; height: 6px; border-radius: 2px; background: var(--ash); }
.ck-n { display: flex; justify-content: space-between; gap: 8px; font: 500 11.5px var(--f-m); color: var(--tallow-2); }
.ck-jp { color: rgba(239, 197, 76, .85); }
.coins-empty { display: grid; justify-items: start; gap: 12px; padding: 12px 0; color: var(--tallow-2); }
.coins-empty p { margin: 0; max-width: 44ch; }
/* mine */
.mine-top { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-top: 16px; }
.mine-total { margin: 0; color: var(--tallow-2); }
.mine-total b { font: 500 15px var(--f-m); color: var(--tallow); }
.mine { margin-top: 16px; display: grid; gap: 8px; }
.mr { display: grid; grid-template-columns: 44px minmax(0, 1fr) minmax(0, 1.3fr) auto; gap: 14px; align-items: center; padding: 12px; border-radius: 10px; border: 1px solid var(--rule); background: rgba(20, 17, 15, .45); }
.mr-pic img, .mr-pic .pic-none { width: 44px; height: 44px; border-radius: 8px; object-fit: cover; background: var(--soot-3); }
.mr-id b { display: block; font: 800 18px/1.05 var(--f-d); font-variation-settings: "wdth" 75, "opsz" 96; }
.mr-id i { font-style: normal; font-size: 12.5px; color: var(--ash); }
.mr-owed { list-style: none; margin: 0; padding: 0; display: grid; gap: 4px; }
.mr-owed li { display: flex; gap: 8px; align-items: baseline; font-size: 12.5px; color: var(--ash); flex-wrap: wrap; }
.mr-owed li span { min-width: 84px; }
.mr-owed b { font: 500 13px var(--f-m); color: var(--tallow); }
.mr-acts { display: flex; gap: 6px; flex-wrap: wrap; justify-content: flex-end; }
.mr-owed em { font-style: normal; font: 500 11px var(--f-m); color: var(--ash); }

/* ---------------------------------------------------------------- toasts + tx status */
.toasts { position: fixed; z-index: 60; right: 20px; bottom: 20px; display: grid; gap: 8px; width: min(360px, calc(100vw - 32px)); }
.toast { padding: 12px 14px 12px 16px; border-radius: 10px; background: var(--soot); border: 1px solid var(--rule-2); box-shadow: var(--drop); color: var(--tallow); font-size: 14px; animation: toast .3s var(--ease); border-left: 3px solid var(--ash); }
.toast.ok { border-left-color: var(--ember); }
.toast.err { border-left-color: #e0503a; color: #f5c9b6; }
@keyframes toast { from { opacity: 0; transform: translateY(8px); } }
.txstatus { position: fixed; z-index: 61; left: 50%; top: 76px; transform: translate(-50%, -8px); margin: 0; padding: 8px 12px; border-radius: 8px; background: var(--iron); border: 1px solid var(--rule-2); box-shadow: var(--drop); font: 500 12px/1 var(--f-m); color: var(--tallow-2); opacity: 0; pointer-events: none; transition: opacity var(--t), transform var(--t); }
.txstatus.on { opacity: 1; transform: translate(-50%, 0); }
.txstatus::before { content: ""; display: inline-block; width: 6px; height: 6px; margin-right: 8px; border-radius: 2px; background: var(--ember); vertical-align: 1px; }

/* wallet picker (kit/wallet.js) */
.wpick .dlg-x { position: absolute; right: 14px; top: 14px; width: 40px; height: 40px; border-radius: 9px; border: 1px solid var(--rule); background: none; color: var(--tallow-2); font-size: 22px; }
.wpick { padding: 24px; border-radius: var(--r); border: 1px solid var(--rule); background: var(--soot); color: var(--tallow); box-shadow: var(--bevel), var(--drop); width: min(400px, calc(100vw - 24px)); }
.wpick h2 { margin: 0 0 16px; font: 800 30px/1 var(--f-d); font-variation-settings: "wdth" 75, "opsz" 96; }
.wp-list { display: grid; gap: 6px; }
.wp-item { display: flex; align-items: center; gap: 12px; min-height: 48px; padding: 8px 12px; border-radius: 9px; border: 1px solid var(--rule); background: rgba(20, 17, 15, .5); text-align: left; font-weight: 600; }
.wp-item:hover { border-color: var(--rule-2); background: rgba(20, 17, 15, .8); }
.wp-item img { border-radius: 6px; }
.wp-dot { width: 32px; height: 32px; border-radius: 8px; background: var(--ember); }
.wp-get { display: flex; flex-wrap: wrap; gap: 6px 14px; margin-top: 14px; font-size: 13px; }
.wp-get a { color: var(--tallow-2); }
.wp-cur, .wp-none, .wp-err { color: var(--tallow-2); font-size: 13.5px; }
.wp-err { color: #f3b08e; }
.wp-off { margin-top: 12px; }
.btn.ghost { border: 1px solid var(--rule); background: none; border-radius: 9px; padding: 10px 14px; }
.wpick::backdrop { background: rgba(10, 8, 7, .72); }

/* ---------------------------------------------------------------- narrower screens */
@media (max-width: 1180px) {
  .brand-line { display: none; }
  .bar { grid-template-columns: auto 1fr auto; }
  .bar-nav { justify-self: end; }
  .log { width: 300px; }
  .coin { width: 316px; }
}
@media (max-width: 860px) {
  :root { --gut: 12px; }
  .bar { height: 56px; padding: 0 var(--gut); gap: 10px; grid-template-columns: auto 1fr auto; }
  .brand-name { font-size: 21px; }
  .brand-mark { width: 26px; height: 26px; }
  .bar-nav { gap: 0; }
  .bar-nav a { padding: 10px 7px; font-size: 12.5px; }
  .bar-nav .bar-log span { display: none; }
  [data-sound] { display: none; }
  .tag-dark.is-on { font-size: 12px; }
  [data-connect] { min-height: 38px; padding: 0 12px; font-size: 13px; }
  .coin { left: var(--gut); right: var(--gut); top: 64px; width: auto; padding: 12px; }
  .cc-top { grid-template-columns: 60px 1fr auto; gap: 10px; }
  .cc-pic { width: 60px; height: 60px; }
  .cc-pic img, .cc-pic .pic-none { width: 46px; height: 46px; }
  .cc-name { font-size: 23px; }
  .cc-holdrow { margin-top: 10px; padding-top: 8px; }
  .cc-pr { margin-top: 8px; display: flex; align-items: baseline; justify-content: space-between; gap: 10px; }
  .cc-price { margin: 0; }
  .cc-price b { font-size: 30px; }
  .cc-curve { margin-top: 10px; }
  .cc-foot { margin-top: 10px; padding-top: 8px; }
  .cc-facts dd { font-size: 13.5px; }
  .log { left: 0; right: 0; top: auto; bottom: 0; width: auto; height: 72dvh; max-height: none; border-radius: 14px 14px 0 0; transform: translateY(105%); transition: transform .32s var(--ease); z-index: 8; }
  .log-open .log { transform: none; }
  .log-x { display: inline-grid; }
  .dock { left: var(--gut); right: var(--gut); bottom: calc(var(--gut) + env(safe-area-inset-bottom)); transform: none; padding: 8px; gap: 4px; }
  .dock-take { min-width: 0; flex: 1; font-size: 15px; padding: 0 12px; }
  .dock [data-refresh] { padding: 0 10px; }
  .dock-sep { display: none; }
  .dock-key { min-width: 50px; padding: 6px 4px; font-size: 10.5px; }
  .dock-logkey { display: inline-flex; }
  .demo-tag { bottom: 88px; }
  .launch { grid-template-columns: 1fr; }
  .launch-prev { display: none; }
  .dlg-in { padding: 20px 16px; }
  .dlg-h { font-size: 29px; }
  .sum div { grid-template-columns: 96px 1fr; }
  .mr { grid-template-columns: 44px 1fr; }
  .mr-owed, .mr > .tag, .mr-acts { grid-column: 1 / -1; }
  .mr-acts { justify-content: stretch; }
  .mr-acts .tag { flex: 1; }
  .jackpot-v b { font-size: 18px; }
  .toasts { right: 12px; left: 12px; bottom: 90px; width: auto; }
}
@media (max-width: 420px) {
  .bar-nav a[href="/stats"] { display: none; }
  .cc-foot .cc-more[data-stoke] { display: none; }
}
@media (max-width: 860px) and (max-height: 500px) {
  .coin { width: 300px; right: auto; }
  .cc-curve, .cc-holdrow { display: none; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .01ms !important; transition-duration: .01ms !important; }
}

/* how it works: the explainer video */
.dlg-how .dlg-in { padding-bottom: 20px; }
.how-video { display: block; width: 100%; height: auto; aspect-ratio: 16 / 9; margin-top: 18px; border-radius: var(--r-s); background: var(--iron-2); border: 1px solid var(--rule); box-shadow: var(--drop); }
.dlg-how .dlg-lede a { color: var(--tallow); }
/* no WebGL: the brass plate has no 3D anchor, so it sits in the bottom-left corner instead of over the brand */
body:not(.gl) .yard-anchors > .brass { position: fixed; left: 20px; top: auto; bottom: 24px; transform: none !important; margin: 0; z-index: 3; }
@media (max-width: 860px) { body:not(.gl) .yard-anchors > .brass { left: var(--gut); bottom: calc(var(--gut) + 84px + env(safe-area-inset-bottom)); } }
body:not(.gl) .yard-anchors > .jackpot { position: fixed; left: 20px; top: auto; bottom: 76px; transform: none !important; margin: 0; z-index: 3; }
@media (max-width: 860px) { body:not(.gl) .yard-anchors > .jackpot { left: var(--gut); bottom: calc(var(--gut) + 136px + env(safe-area-inset-bottom)); } }
.nav-how { white-space: nowrap; }
.nav-how .how-s { display: none; }
@media (max-width: 860px) { .nav-how .how-l { display: none; } .nav-how .how-s { display: inline; } }
.nav-how .how-sr { display: none; }
@media (max-width: 860px) { .nav-how .how-sr { display: inline; } .nav-how .how-s svg { display: block; } }
@media (max-width: 340px) { .bar { gap: 8px; } .bar-nav a.nav-how { padding-left: 4px; padding-right: 4px; min-width: 32px; min-height: 36px; display: inline-grid; place-items: center; } }
