@font-face { font-family: 'Sansita Swashed'; src: url(fonts/sansita-swashed-latin-800-normal.woff2) format('woff2'); font-weight: 800; font-display: swap; }
@font-face { font-family: 'Bricolage Grotesque'; src: url(fonts/bricolage-grotesque-latin-500-normal.woff2) format('woff2'); font-weight: 500; font-display: swap; }
@font-face { font-family: 'Bricolage Grotesque'; src: url(fonts/bricolage-grotesque-latin-800-normal.woff2) format('woff2'); font-weight: 800; font-display: swap; }

:root {
  --ink: #2b1b2e; --grout: #cfd19c; --avocado: #a4ab5b; --avocado-deep: #6d7433;
  --salmon: #ee8d76; --mustard: #e7b64a; --cream: #f6efdf; --teal: #58c1c9; --lilac: #b89be6; --foam: #fbf3ff;
  --display: 'Sansita Swashed', 'Trebuchet MS', 'Noto Sans', system-ui, sans-serif;
  --body: 'Bricolage Grotesque', 'Noto Sans', system-ui, -apple-system, 'Segoe UI', sans-serif;
  --sat: env(safe-area-inset-top, 0px); --sab: env(safe-area-inset-bottom, 0px); --sal: env(safe-area-inset-left, 0px); --sar: env(safe-area-inset-right, 0px);
}
* { box-sizing: border-box; -webkit-tap-highlight-color: transparent; }
html, body { margin: 0; height: 100%; overflow: hidden; background: var(--avocado); color: var(--ink); font: 500 16px/1.35 var(--body); -webkit-user-select: none; user-select: none; overscroll-behavior: none; }
button { font: inherit; color: inherit; cursor: pointer; touch-action: manipulation; }
[hidden] { display: none !important; }
canvas#game { position: fixed; inset: 0; width: 100%; height: 100%; display: block; touch-action: none; outline: none; }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); }
:focus-visible { outline: 3px solid var(--foam); outline-offset: 2px; box-shadow: 0 0 0 6px var(--ink); }

/* ---- ceramic: every button is a tile set into grout ---- */
.tile {
  position: relative; display: flex; flex-direction: column; justify-content: flex-end; gap: 2px; text-align: left;
  min-height: 84px; padding: 12px 14px; border: 3px solid var(--ink); border-radius: 7px; background: var(--cream);
  box-shadow: inset 0 5px 0 rgba(255,255,255,.45), inset 0 -6px 0 rgba(43,27,46,.13);
}
.tile::before { content: ''; position: absolute; top: 11px; left: 11px; width: 19px; height: 5px; border-radius: 3px; background: rgba(255,255,255,.65); }
.tile:active { transform: translateY(2px); box-shadow: inset 0 2px 0 rgba(255,255,255,.3), inset 0 -2px 0 rgba(43,27,46,.13); }
.tile .t { font: 800 clamp(20px, 5.4vmin, 27px)/1.04 var(--display); margin-top: 12px; }
.tile .s { font-size: clamp(13px, 3.4vmin, 15px); line-height: 1.2; }
.tile.big .t { font-size: clamp(27px, 8vmin, 38px); }
.t-salmon { background: var(--salmon); } .t-mustard { background: var(--mustard); } .t-cream { background: var(--cream); } .t-teal { background: var(--teal); }
.tile.wide { grid-column: 1 / -1; }

.icon { width: 44px; height: 44px; display: grid; place-items: center; padding: 8px; border: 3px solid var(--ink); border-radius: 7px; background: var(--cream); box-shadow: inset 0 3px 0 rgba(255,255,255,.5), inset 0 -3px 0 rgba(43,27,46,.13); }
.icon svg { width: 100%; height: 100%; fill: currentColor; }
#btnMute { position: fixed; top: calc(6px + var(--sat)); right: calc(6px + var(--sar)); z-index: 9; }
#btnMute .off { display: none; } #btnMute.muted .off { display: block; } #btnMute.muted .on { display: none; }

/* ---- menu ---- */
#menu { position: fixed; inset: 0; z-index: 5; display: grid; grid-template-rows: auto minmax(120px, 1fr) auto; padding: calc(10px + var(--sat)) calc(14px + var(--sar)) calc(10px + var(--sab)) calc(14px + var(--sal)); overflow-y: auto; }
.m-head { padding-right: 52px; }
#logo { margin: 0; font: 800 clamp(46px, 15vmin, 88px)/.9 var(--display); color: var(--foam); paint-order: stroke fill; -webkit-text-stroke: 7px var(--ink); letter-spacing: -.5px; transform: rotate(-2.5deg); transform-origin: left bottom; }
#tagline { margin: 10px 0 0; font-weight: 800; font-size: clamp(15px, 4.2vmin, 19px); line-height: 1.2; max-width: 30ch; }
.m-tiles { display: grid; grid-template-columns: 1fr 1fr; gap: 6px; padding: 6px; background: var(--grout); border: 3px solid var(--ink); border-radius: 9px; max-width: 560px; width: 100%; justify-self: center; }
#menuLinks { grid-column: 1 / -1; margin: 2px 0 0; display: flex; flex-wrap: wrap; gap: 2px 14px; justify-content: center; }
.link { background: none; border: 0; padding: 8px 4px; min-height: 40px; font-weight: 800; text-decoration: underline; text-underline-offset: 3px; }
#stats, #byline { grid-column: 1 / -1; margin: 0; text-align: center; font-size: 13px; line-height: 1.25; }
#stats { font-weight: 800; } #stats:empty { display: none; }
@media (orientation: landscape) {
  #menu { grid-template-columns: minmax(0, 1fr) minmax(320px, 46%); grid-template-rows: auto 1fr; column-gap: 16px; }
  .m-head { grid-column: 1; grid-row: 1; padding-right: 0; }
  #sceneSpot { grid-column: 1; grid-row: 2; }
  .m-tiles { grid-column: 2; grid-row: 1 / span 2; align-self: center; margin-top: 48px; }
  #logo { font-size: clamp(40px, 15vh, 92px); }
}
@media (orientation: landscape) and (max-height: 420px) {
  .tile { min-height: 58px; padding: 6px 10px; } .tile .t { margin-top: 3px; font-size: 19px; } .tile.big .t { font-size: 25px; } .tile .s { font-size: 12px; }
  .tile::before { top: 6px; left: 8px; }
  #byline { display: none; } #stats { font-size: 12px; } .link { min-height: 30px; padding: 3px 4px; font-size: 14px; }
  .m-tiles { margin-top: 40px; gap: 4px; padding: 4px; }
  #logo { font-size: 44px; -webkit-text-stroke-width: 5px; } #tagline { font-size: 14px; margin-top: 6px; }
}

/* ---- panels: a big tile on the wall ---- */
#panel { position: fixed; inset: 0; z-index: 20; display: grid; place-items: center; padding: calc(8px + var(--sat)) calc(10px + var(--sar)) calc(8px + var(--sab)) calc(10px + var(--sal)); background: rgba(109,116,51,.72); overflow-y: auto; }
.card { width: 100%; max-width: 560px; max-height: 100%; overflow-y: auto; padding: 16px; border: 4px solid var(--ink); border-radius: 10px; background: var(--cream); box-shadow: inset 0 6px 0 rgba(255,255,255,.7); -webkit-overflow-scrolling: touch; }
#pTitle { margin: 0 0 8px; font: 800 clamp(25px, 7vmin, 36px)/1.05 var(--display); }
#pBody p { margin: 6px 0; max-width: 62ch; }
#pBody .big { font: 800 clamp(30px, 10vmin, 46px)/1 var(--display); margin: 6px 0; }
#pBody .quiet { font-size: 14px; }
#pBody h3 { margin: 12px 0 6px; font: 800 19px/1.1 var(--display); }
#pBtns { display: grid; grid-template-columns: 1fr 1fr; gap: 6px; margin-top: 12px; }
#pBtns .tile { min-height: 58px; justify-content: center; }
#pBtns .tile::before { top: 6px; left: 8px; }
#pBtns .tile .t { margin: 0; font-size: 19px; }
#pBtns .tile.wide { grid-column: 1 / -1; }
#pBtns .tile.go .t { font-size: 25px; }
#pToast { margin: 8px 0 0; font-weight: 800; min-height: 1.2em; }
#pToast:empty { display: none; }
textarea.sharebox { width: 100%; height: 88px; margin-top: 8px; border: 2px solid var(--ink); border-radius: 6px; padding: 8px; font: 500 14px var(--body); background: #fff; color: var(--ink); -webkit-user-select: text; user-select: text; resize: none; }

.seg { display: grid; grid-auto-flow: column; grid-auto-columns: 1fr; gap: 4px; padding: 4px; background: var(--grout); border: 2px solid var(--ink); border-radius: 8px; margin: 2px 0 8px; }
.seg button { min-height: 46px; border: 2px solid var(--ink); border-radius: 5px; background: var(--cream); font: 800 21px var(--display); }
.seg button[aria-pressed=true] { background: var(--ink); color: var(--foam); }
.gangs { display: grid; grid-template-columns: repeat(auto-fit, minmax(118px, 1fr)); gap: 6px; }
.gang { display: flex; align-items: center; gap: 6px; min-height: 60px; padding: 4px 8px 4px 4px; background: #fff; border: 2px solid var(--ink); border-radius: 7px; text-align: left; font-weight: 800; font-size: 14px; line-height: 1.1; }
.gang canvas { width: 50px; height: 50px; flex: none; }
.lad { display: grid; gap: 6px; }
.lad button { display: grid; grid-template-columns: 54px 1fr; gap: 2px 8px; align-items: center; text-align: left; padding: 6px 10px 6px 6px; min-height: 62px; background: #fff; border: 2px solid var(--ink); border-radius: 7px; }
.lad button:disabled { opacity: .55; cursor: default; }
.lad canvas { grid-row: 1 / span 2; width: 54px; height: 54px; }
.lad b { font: 800 18px/1.05 var(--display); } .lad small { font-size: 13px; line-height: 1.15; }
.lookrow { display: grid; grid-template-columns: repeat(auto-fill, minmax(130px, 1fr)); gap: 6px; }
.look { display: grid; justify-items: start; gap: 2px; padding: 6px; background: #fff; border: 2px solid var(--ink); border-radius: 7px; text-align: left; font-size: 13px; line-height: 1.15; min-height: 92px; }
.look canvas { width: 48px; height: 48px; }
.look b { font-size: 14px; } .look[aria-pressed=true] { background: var(--mustard); }
.look:disabled { color: #554a55; background: #ece6d6; cursor: default; }
.how li { margin: 6px 0; } .how { padding-left: 20px; margin: 4px 0; }
.howitems { display: grid; grid-template-columns: 1fr; gap: 6px; margin-top: 6px; }
.hi { display: grid; grid-template-columns: 40px 1fr; gap: 8px; align-items: center; font-size: 14px; line-height: 1.2; }
.hi canvas { width: 40px; height: 40px; }
.scoreb { width: 100%; border-collapse: collapse; margin-top: 8px; font-size: 14px; }
.scoreb td, .scoreb th { padding: 4px 4px; border-bottom: 2px solid var(--grout); text-align: right; }
.scoreb td:first-child, .scoreb th:first-child { text-align: left; font-weight: 800; } .scoreb th { font-weight: 500; font-size: 12px; line-height: 1.1; vertical-align: bottom; }
.scoreb i { display: inline-block; width: 12px; height: 12px; border: 2px solid var(--ink); border-radius: 50%; margin-right: 6px; vertical-align: -1px; }
.row { font-size: 20px; letter-spacing: 1px; word-break: break-all; }

/* ---- in-match HUD ---- */
#hud { position: fixed; z-index: 6; top: 0; left: 0; right: 0; padding: calc(6px + var(--sat)) calc(56px + var(--sar)) 4px calc(6px + var(--sal)); display: grid; gap: 4px 6px; grid-template-columns: auto minmax(0, 1fr) auto; grid-template-areas: 'pause chips timer' 'wind who mini'; align-items: center; pointer-events: none; }
#hud > * { pointer-events: auto; }
#btnPause { grid-area: pause; }
#chips { grid-area: chips; display: flex; flex-wrap: wrap; gap: 4px; pointer-events: none; min-width: 0; }
.chip { display: flex; align-items: center; gap: 3px; height: 26px; padding: 0 6px; border: 2px solid var(--ink); border-radius: 13px; background: var(--cream); }
.chip.on { background: var(--ink); }
.chip i { width: 12px; height: 12px; border-radius: 50%; border: 2px solid var(--ink); }
.chip.on i { border-color: var(--foam); }
.chip i.wet { background: transparent !important; opacity: .4; }
#who { grid-area: who; justify-self: start; max-width: 100%; min-width: 0; padding: 2px 7px; background: var(--cream); border: 2px solid var(--ink); border-radius: 6px; font-weight: 800; font-size: 14px; line-height: 1.1; color: var(--ink); overflow: hidden; pointer-events: none; }
#windBox { grid-area: wind; display: flex; align-items: center; justify-content: center; gap: 2px; height: 28px; padding: 0 4px; border: 2px solid var(--ink); border-radius: 6px; background: var(--cream); font-weight: 800; font-size: 17px; line-height: 1; letter-spacing: -1px; pointer-events: none; }
#windBox svg { width: 24px; height: 16px; flex: none; color: var(--ink); }
#windL, #windR { display: flex; gap: 1px; width: 34px; }
#windL { justify-content: flex-end; }
#windL i, #windR i { width: 6px; height: 13px; background: #c33a24; }
#windL i { clip-path: polygon(100% 0, 0 50%, 100% 100%); }
#windR i { clip-path: polygon(0 0, 100% 50%, 0 100%); }
#timer { grid-area: timer; justify-self: end; width: 44px; height: 44px; display: grid; place-items: center; border: 3px solid var(--ink); border-radius: 50%; background: var(--mustard); font: 800 21px var(--display); pointer-events: none; }
#timer.low { background: var(--salmon); }
#btnMini { grid-area: mini; padding: 0; border: 2px solid var(--ink); border-radius: 5px; background: none; line-height: 0; width: 112px; height: 60px; overflow: hidden; }
#mini { width: 100%; height: 100%; display: block; }
@media (orientation: landscape) {
  #hud { grid-template-columns: auto auto minmax(0, 1fr) auto auto auto; grid-template-areas: 'pause chips who wind timer mini'; padding-right: calc(56px + var(--sar)); }
  #chips { flex-wrap: nowrap; }
  #btnMini { width: 84px; height: 44px; }
}
#caption { position: fixed; z-index: 6; left: 50%; transform: translateX(-50%) rotate(-.7deg); top: calc(112px + var(--sat)); width: max-content; max-width: min(92vw, 560px); padding: 5px 11px; border: 3px solid var(--ink); border-radius: 7px; background: var(--foam); font-weight: 800; font-size: 15px; line-height: 1.2; text-align: center; pointer-events: none; }
#banner { position: fixed; z-index: 6; left: 50%; top: 42%; transform: translate(-50%, -50%) rotate(-1.5deg); width: max-content; max-width: 92vw; padding: 7px 18px 9px; border: 4px solid var(--ink); border-radius: 9px; font: 800 clamp(24px, 7.5vmin, 42px)/1.05 var(--display); color: #fff; text-align: center; pointer-events: none; paint-order: stroke fill; -webkit-text-stroke: 4px var(--ink); }
#hint { position: fixed; z-index: 6; left: 50%; transform: translateX(-50%); bottom: 150px; top: auto; width: max-content; max-width: 86vw; padding: 7px 11px; border: 3px solid var(--ink); border-radius: 7px; background: var(--mustard); font-weight: 800; font-size: 15px; line-height: 1.2; text-align: center; pointer-events: none; }
@media (orientation: landscape) { #caption { top: calc(56px + var(--sat)); } #hint { top: 62px; bottom: auto; } }

/* ---- tray ---- */
#tray { position: fixed; z-index: 6; left: 0; right: 0; bottom: 0; padding: 6px calc(6px + var(--sar)) calc(6px + var(--sab)) calc(6px + var(--sal)); display: grid; grid-template-columns: minmax(0, 1fr) auto; grid-template-areas: 'fine fine' 'move act'; gap: 6px; background: var(--grout); border-top: 3px solid var(--ink); }
#tray.off .key, #tray.off .nudge { opacity: .42; pointer-events: none; }
.key { position: relative; display: grid; place-items: center; min-width: 54px; height: 56px; padding: 0 6px; border: 3px solid var(--ink); border-radius: 7px; background: var(--cream); font-weight: 800; font-size: 15px; line-height: 1; touch-action: none; box-shadow: inset 0 4px 0 rgba(255,255,255,.5), inset 0 -4px 0 rgba(43,27,46,.13); }
.key svg { width: 24px; height: 24px; }
.key:active, .key.down { transform: translateY(2px); background: var(--mustard); }
.t-move { grid-area: move; display: flex; gap: 5px; position: relative; padding-bottom: 7px; }
.t-move .key { flex: 1 1 0; min-width: 0; }
#stam { position: absolute; left: 0; right: 0; bottom: 0; height: 5px; border: 1px solid var(--ink); border-radius: 3px; background: rgba(255,255,255,.5); overflow: hidden; }
#stam i { display: block; height: 100%; width: 100%; background: var(--avocado-deep); transform-origin: left; }
.t-act { grid-area: act; display: flex; gap: 5px; }
.swat { min-width: 96px; background: var(--salmon); font: 800 24px var(--display); }
#btnItem { width: 66px; grid-template-rows: 1fr auto; padding: 2px; gap: 0; }
#itemIcon { width: 34px; height: 34px; }
#itemN { font-size: 12px; }
.t-fine { grid-area: fine; display: grid; grid-template-columns: 1fr 1fr; gap: 6px; }
.fine { display: grid; grid-template-columns: 44px minmax(0, 1fr) 44px; gap: 3px; align-items: center; }
.nudge { height: 44px; border: 2px solid var(--ink); border-radius: 6px; background: var(--cream); padding: 8px; display: grid; place-items: center; touch-action: none; }
.nudge svg { width: 22px; height: 22px; }
.nudge:active { background: var(--mustard); }
.val { text-align: center; line-height: 1; min-width: 0; }
.val small { display: block; font-size: 11px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.val b { font: 800 20px var(--display); }
@media (orientation: landscape) {
  /* Thumbs at the corners and the fine controls low in the middle; the tub stays visible behind them. */
  #tray { background: none; border: 0; pointer-events: none; grid-template-columns: auto minmax(0, 1fr) auto; grid-template-areas: 'move fine act'; align-items: end; }
  #tray > * { pointer-events: auto; }
  .t-move { width: 196px; }
  .t-fine { justify-self: center; width: min(100%, 340px); padding: 3px; background: rgba(207,209,156,.92); border: 2px solid var(--ink); border-radius: 8px; }
  .fine { grid-template-columns: 38px minmax(0, 1fr) 38px; }
  .nudge { height: 40px; padding: 6px; }
  .val b { font-size: 17px; }
  .key { height: 52px; }
}
@media (orientation: landscape) and (max-width: 640px) {
  .t-move { width: 150px; } .key { min-width: 44px; } .swat { min-width: 70px; font-size: 19px; } #btnItem { width: 52px; }
  .fine { grid-template-columns: 30px minmax(0, 1fr) 30px; } .nudge { height: 34px; padding: 4px; } .val small { display: none; } .val b { font-size: 14px; }
}

#itemsPop { position: fixed; z-index: 8; left: 50%; bottom: calc(8px + var(--sab)); transform: translateX(-50%); width: min(96vw, 640px); max-height: calc(100% - 66px); overflow-y: auto; padding: 8px; background: var(--grout); border: 3px solid var(--ink); border-radius: 10px; }
#itemsPop h2 { margin: 0 0 6px 4px; font: 800 20px var(--display); }
#itemsList { display: grid; grid-template-columns: repeat(auto-fill, minmax(258px, 1fr)); gap: 5px; }
.ib { display: grid; grid-template-columns: 44px 1fr auto; column-gap: 8px; align-items: center; text-align: left; min-height: 62px; padding: 4px 8px 4px 4px; background: var(--cream); border: 2px solid var(--ink); border-radius: 7px; }
.ib canvas { width: 44px; height: 44px; grid-row: 1 / span 2; }
.ib b { font: 800 16px/1 var(--display); } .ib em { font-style: normal; font-weight: 800; font-size: 12px; white-space: nowrap; }
.ib small { grid-column: 2 / -1; font-size: 12px; line-height: 1.15; }
.ib[aria-pressed=true] { background: var(--mustard); }
.ib:disabled { opacity: .45; }
@media (max-height: 460px) { .ib small { display: none; } .ib { min-height: 48px; } .ib canvas { grid-row: auto; width: 34px; height: 34px; } #itemsList { grid-template-columns: repeat(auto-fill, minmax(170px, 1fr)); } .ib { grid-template-columns: 34px 1fr auto; } }

@media (prefers-reduced-motion: no-preference) {
  #banner { animation: slap .28s cubic-bezier(.2, 1.6, .4, 1); }
  @keyframes slap { from { transform: translate(-50%, -50%) rotate(-7deg) scale(1.6); } }
}

.twosegs { display: grid; grid-template-columns: 1fr; }
@media (orientation: landscape) { .twosegs { grid-template-columns: 1fr 1fr; gap: 10px; } }
@media (orientation: landscape) and (max-height: 460px) {
  .card { padding: 8px 12px; max-width: 680px; }
  #pTitle { font-size: 23px; margin-bottom: 2px; }
  #pBody p { margin: 2px 0; font-size: 14px; }
  #pBody .big { font-size: 28px; }
  .seg { margin-bottom: 4px; } .seg button { min-height: 36px; font-size: 18px; }
  .gang { min-height: 44px; } .gang canvas { width: 38px; height: 38px; }
  #pBtns { grid-template-columns: repeat(3, 1fr); margin-top: 6px; }
  #pBtns .tile { min-height: 42px; padding: 4px 10px; } #pBtns .tile::before { display: none; }
  #pBtns .tile .t { font-size: 16px; } #pBtns .tile.go .t { font-size: 19px; }
  .scoreb { margin-top: 2px; font-size: 13px; } .scoreb td, .scoreb th { padding: 1px 4px; }
  .lad { grid-template-columns: 1fr 1fr; }
}

/* ---- online ---- */
#onbar { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 1px 6px; align-items: center; padding: 3px 6px; background: var(--cream); border: 2px solid var(--ink); border-radius: 6px; line-height: 1.12; }
#hud.withbar { grid-template-areas: 'pause chips timer' 'wind who mini' 'bar bar bar'; }
#onbar { grid-area: bar; }
#onMsg { margin: 0; font-weight: 800; font-size: 14px; grid-column: 1; grid-row: 1; }
#onNames { margin: 0; font-size: 12px; grid-column: 1 / -1; grid-row: 2; }
#onDot { display: inline-block; width: 11px; height: 11px; margin-right: 4px; border: 2px solid var(--ink); border-radius: 50%; vertical-align: -1px; }
#onBtns { grid-column: 2; grid-row: 1; display: flex; gap: 3px; }
#onbar[data-state=reconnecting] { background: var(--salmon); }
#onbar[data-state=opponent_away] { background: var(--mustard); }
.pill { min-width: 40px; min-height: 36px; padding: 2px 7px; border: 2px solid var(--ink); border-radius: 6px; background: #fff; font-weight: 800; font-size: 13px; line-height: 1; }
.pill.ico { width: 36px; min-width: 36px; padding: 5px; display: grid; place-items: center; }
.pill.ico svg { width: 100%; height: 100%; }
.pill[aria-pressed=true] { background: var(--ink); color: var(--foam); }
.pill:active { background: var(--mustard); }
body.onl #caption { top: calc(var(--hudb, 170px) + 6px); }
#emotes { position: fixed; z-index: 8; left: 50%; transform: translateX(-50%); top: calc(var(--hudb, 170px) + 4px); width: min(94vw, 460px); display: grid; grid-template-columns: repeat(4, 1fr); gap: 4px; padding: 5px; background: var(--grout); border: 3px solid var(--ink); border-radius: 9px; }
#emotes button { min-height: 44px; padding: 2px; border: 2px solid var(--ink); border-radius: 6px; background: var(--cream); font-weight: 800; font-size: 13px; line-height: 1.05; }
@media (orientation: landscape) {
  #hud.withbar { grid-template-areas: 'pause chips who wind timer mini' 'bar bar bar bar bar bar'; }
  #onbar { padding: 1px 5px; }
  #onMsg { font-size: 13px; } #onNames { font-size: 11px; }
  .pill { min-height: 30px; } .pill.ico { width: 30px; min-width: 30px; padding: 3px; }
  body.onl #hint { top: calc(var(--hudb, 96px) + 6px); }
  #onNames { grid-column: 1; grid-row: 2; } #onBtns { grid-row: 1 / span 2; }
}
.codebox { font: 800 clamp(38px, 12vmin, 56px)/1.05 var(--display); letter-spacing: 3px; text-align: center; padding: 8px 4px; margin: 8px 0; background: #fff; border: 3px solid var(--ink); border-radius: 8px; -webkit-user-select: text; user-select: text; }
.spin { display: block; width: 34px; height: 34px; margin: 8px auto; border: 5px solid var(--grout); border-top-color: var(--ink); border-radius: 50%; }
@media (prefers-reduced-motion: no-preference) { .spin { animation: turn 1s linear infinite; } @keyframes turn { to { transform: rotate(360deg); } } }
.joinrow { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 6px; margin-top: 6px; }
.joinrow input { min-width: 0; min-height: 46px; padding: 4px 10px; border: 3px solid var(--ink); border-radius: 7px; background: #fff; color: var(--ink); font: 800 22px var(--body); letter-spacing: 2px; text-transform: uppercase; -webkit-user-select: text; user-select: text; }
.joinrow input::placeholder { letter-spacing: 0; font-size: 15px; font-weight: 500; text-transform: none; color: #5d505f; }
.joinrow button { min-height: 46px; padding: 2px 14px; border: 3px solid var(--ink); border-radius: 7px; background: var(--mustard); font: 800 18px var(--display); }
#pBody .onend { font: 800 clamp(21px, 6vmin, 28px)/1.12 var(--display); }
#pBody .onmsg { font-weight: 800; }
#pBody .link { display: inline-block; }
#pBtns .tile .s { font-size: 13px; }
