/* BeGuile page (internal name Proteus; styles copied from Tap Out's tapout.css, Nov 2026, power-ups and solo taken out). Colors and fonts only through the site's variables (tokens.css, fonts.css).
   Lobby on a paper band; a match on its own iron band, full screen on phones, in the "Fuse" look (see tapout.js). */

.pr-main { padding: clamp(32px, 6vw, 64px) 0 clamp(48px, 8vw, 88px); }
.pr-main .wrap { max-width: 34rem; }
/* .btn sets its own display, which would beat the hidden attribute (the host-only Start button) */
.pr-main [hidden] { display: none; }

.pr-view { display: none; gap: .9rem; }
body[data-view="start"] [data-for="start"],
body[data-view="join"] [data-for="join"],
body[data-view="lobby"] [data-for="lobby"],
body[data-view="error"] [data-for="error"] { display: grid; }
.pr-view .btn { justify-self: start; }

.pr-h { font-size: clamp(1.8rem, 6vw, 2.5rem); color: var(--title); }
.pr-code { font-family: var(--font-accent); letter-spacing: .12em; color: var(--accent-ink); }
.pr-note { color: var(--soft); }
.pr-note:empty { display: none; }

.pr-label { font: 400 .78rem/1 var(--font-accent); text-transform: uppercase; letter-spacing: .1em; color: var(--soft); padding: 0; }
.pr-input {
  width: 100%; min-height: 54px; padding: .6em .8em;
  font: 700 1.25rem/1.2 var(--font-body); color: var(--title);
  background: var(--card); border: 2px solid var(--rule); border-radius: 3px;
}
.pr-input:focus { outline: none; border-color: var(--accent-ink); }

.pr-faces { border: 0; margin: .4rem 0 0; padding: 0; display: grid; gap: .8rem; }
.pr-face-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(48px, 1fr)); gap: 6px; }
.pr-face {
  aspect-ratio: 1; font-size: 1.6rem; line-height: 1; cursor: pointer;
  background: var(--card); border: 2px solid var(--rule); border-radius: 3px;
}
.pr-face[aria-pressed="true"] { border-color: var(--accent-ink); background: var(--ember); }
.pr-face:focus-visible { outline: 2px solid var(--focus); outline-offset: 2px; }

.pr-error { color: var(--danger); font-weight: 700; }

/* theme box: a labelled text field with a Go button on top, then one-tap chips */
.pr-pick { display: flex; gap: 8px; margin-top: -8px; }
.pr-pick-label { color: var(--title); font-size: .85rem; }
.pr-pick-label + .pr-chips { margin-top: -8px; }
.pr-pick .pr-input { flex: 1; min-width: 0; }
.pr-pick .btn { flex: none; }
.pr-chips { display: flex; flex-wrap: wrap; gap: 6px; }
.pr-chip {
  min-height: 40px; padding: .4rem .8rem; cursor: pointer;
  font: 700 .95rem/1.1 var(--font-body); color: var(--ink);
  background: var(--card); border: 2px solid var(--rule); border-radius: 999px;
}
.pr-chip:hover { border-color: var(--accent-ink); color: var(--accent-ink); }
.pr-chip:disabled { opacity: .5; cursor: default; }
.pr-chip--big { min-height: 52px; padding: .6rem 1.1rem; font-size: 1.1rem; }

/* speed: a three-way switch (host only) */
.pr-speed { display: grid; gap: .5rem; margin-top: .4rem; }
.pr-seg { display: grid; grid-template-columns: repeat(3, 1fr); border: 2px solid var(--ink); border-radius: 3px; overflow: hidden; }
.pr-seg__btn {
  min-height: 48px; font: 700 1rem/1 var(--font-body); text-transform: uppercase; letter-spacing: .04em; cursor: pointer;
  color: var(--ink); background: transparent; border: 0;
}
.pr-seg__btn + .pr-seg__btn { border-left: 2px solid var(--ink); }
.pr-seg--4 { grid-template-columns: repeat(4, 1fr); }
.pr-seg--4 .pr-seg__btn { font-size: .82rem; letter-spacing: 0; padding: 0 .2rem; }
.pr-seg__btn[aria-pressed="true"] { background: var(--ember); color: var(--on-ember); }
.pr-seg__btn:focus-visible { outline: 2px solid var(--focus); outline-offset: -5px; }

.pr-lobby-head { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: .8rem; }

.pr-players { list-style: none; margin: 0; padding: 0; display: grid; gap: 6px; }
.pr-player {
  display: flex; align-items: center; gap: .8rem; min-height: 56px; padding: .4rem .9rem;
  background: var(--card); border: 2px solid var(--rule); border-radius: 3px;
}
.pr-player__face { font-size: 1.7rem; line-height: 1; }
.pr-player__name { flex: 1; min-width: 0; font-weight: 700; color: var(--title); overflow-wrap: anywhere; }
.pr-player__tag { font: 400 .72rem/1 var(--font-accent); text-transform: uppercase; letter-spacing: .08em; color: var(--soft); }
.pr-player--me { border-color: var(--accent-ink); }
.pr-player--off { opacity: .5; }
.pr-player--empty { border-style: dashed; color: var(--soft); justify-content: center; font-size: .95rem; }

.pr-conn {
  position: fixed; left: 50%; bottom: 16px; z-index: 60; translate: -50% 0; margin: 0; padding: .5rem 1rem;
  font: 400 .85rem/1.2 var(--font-accent); color: var(--head-ink); background: var(--head-bg);
  border: 2px solid var(--ember); border-radius: 3px;
}
.pr-conn[hidden] { display: none; }

/* ---------- the match ---------- */
.pr-play { display: none; }
.pr[data-view="game"] .pr-play { display: block; }
.pr[data-view="game"] .hero,
.pr[data-view="game"] .pr-main { display: none; }
.pr-play__inner { max-width: 34rem; margin: 0 auto; padding: 14px var(--gutter) 28px; display: grid; gap: 14px; min-height: 70vh; align-content: start; }
/* Phones: the match fills the screen, no site header or footer */
@media (max-width: 899px) {
  .pr[data-view="game"] { padding-top: 0; }
  .pr[data-view="game"] .site-header,
  .pr[data-view="game"] .site-footer { display: none; }
  .pr[data-view="game"] .pr-play { min-height: 100dvh; }
  .pr-play__inner { min-height: 100dvh; padding-top: max(12px, env(safe-area-inset-top)); padding-bottom: max(20px, env(safe-area-inset-bottom)); }
}

.pr-top {
  display: flex; justify-content: space-between; align-items: center; gap: 1rem;
  font: 400 .74rem/1.3 var(--font-accent); text-transform: uppercase; letter-spacing: .08em; color: var(--soft);
}
.pr-top__me { font: 700 1rem/1 var(--font-body); color: var(--title); font-variant-numeric: tabular-nums; letter-spacing: 0; }
.pr-top__me.is-down { color: var(--danger); }
.pr-stage { display: grid; gap: 14px; align-content: start; }
.pr-stage .btn { justify-self: start; }
.pr-big { font-size: clamp(2.2rem, 9vw, 3.2rem); color: var(--title); }
.pr-theme { font: 700 1.3rem/1.2 var(--font-body); color: var(--accent-ink); }
.pr-soft { color: var(--soft); font-family: var(--font-accent); font-size: .85rem; }
.pr-count { font: 700 clamp(4rem, 24vw, 7rem)/1 var(--font-heading); color: var(--title); text-align: center; min-height: 1em; }
.pr-question { font: 700 clamp(1.4rem, 6vw, 1.8rem)/1.25 var(--font-body); color: var(--title); }
.pr-question--small { font-size: 1.1rem; color: var(--soft); }

.pr-board { list-style: none; margin: 0; padding: 0; display: grid; gap: 4px; counter-reset: rank; }
.pr-row {
  counter-increment: rank; display: flex; align-items: center; gap: .7rem; min-height: 48px; padding: .3rem .8rem;
  background: var(--card); border: 2px solid var(--rule); border-radius: 3px;
}
.pr-row::before { content: counter(rank); width: 1.2em; font-family: var(--font-accent); color: var(--soft); }
.pr-board--swings .pr-row { min-height: 40px; }
.pr-board--swings .pr-row::before { content: none; }
.pr-row__face { font-size: 1.4rem; line-height: 1; }
.pr-row__name { flex: 1; min-width: 0; font-weight: 700; color: var(--title); overflow-wrap: anywhere; }
.pr-row__score { font-weight: 700; font-variant-numeric: tabular-nums; color: var(--title); }
.pr-row__score.is-up { color: var(--accent-ink, var(--iron-accent)); }
.pr-row__score.is-down { color: var(--danger); }
.pr-row--me { border-color: var(--accent-ink); }
.pr-row--off { opacity: .5; }

/* the end: the winner's face, then confetti */
.pr-winner { font-size: 4rem; line-height: 1; animation: pr-slam .5s cubic-bezier(.2, 1.6, .4, 1) both; }
.pr-confetti { position: fixed; inset: 0; z-index: 50; pointer-events: none; overflow: hidden; }
.pr-confetti i {
  position: absolute; top: -20px; width: 9px; height: 14px; border-radius: 2px;
  animation: pr-fall linear both;
}
.pr-confetti .c0 { background: var(--ember); }
.pr-confetti .c1 { background: var(--accent-300); }
.pr-confetti .c2 { background: var(--color-bg); }
.pr-confetti .c3 { background: var(--danger-300); }
@keyframes pr-fall { to { transform: translate(var(--drift), 105vh) rotate(var(--spin)); } }

/* between rounds: the pick countdown and the recap lines */
.pr-count--small { font-size: clamp(2.4rem, 12vw, 3.4rem); text-align: left; }
/* Notes on the round intro that are sometimes empty: no gap for them */
.pr-gnote:empty, .pr-wait:empty { display: none; }
.pr-writing { animation: pr-blink 1.2s ease-in-out infinite; }
@keyframes pr-blink { 50% { opacity: .45; } }

/* ---------- before Round 1 (Oct 22, picked from mockups) ---------- */
/* spin: a spotlight hops between everyone's cards and lands on who picks the theme */
.pr-spot { display: grid; grid-template-columns: repeat(2, 1fr); gap: 10px; }
.pr-spot__card {
  display: flex; align-items: center; gap: 10px; min-width: 0; min-height: 64px; padding: .6rem .8rem;
  font: 700 1.15rem/1.1 var(--font-body); color: var(--title); background: var(--card); border: 3px solid var(--rule); border-radius: 3px;
  opacity: .55; transition: opacity .08s, transform .08s;
}
.pr-spot__face { font-size: 1.8rem; }
.pr-spot__name { min-width: 0; overflow-wrap: anywhere; }
.pr-spot__card.is-lit { opacity: 1; border-color: var(--ember); transform: scale(1.04); }
.pr-spot__card.is-won { opacity: 1; background: var(--ember); border-color: var(--ember); color: var(--on-ember); animation: pr-slam .35s cubic-bezier(.2, 1.6, .4, 1) both; }
.pr-who { min-height: 1.3em; font: 700 clamp(1.6rem, 7vw, 2.2rem)/1.2 var(--font-body); color: var(--accent-ink); text-align: center; }
.pr-who.is-in { animation: pr-slam .35s cubic-bezier(.2, 1.6, .4, 1) both; }
/* typed lists: How to play and the round facts type in a line at a time and stay (the round facts used to take
   turns, fading, until Oct 22); How to play's Win! slams in big */
.pr-typed { list-style: none; margin: 0; padding: 0; display: grid; gap: .55rem; font: 400 clamp(1.1rem, 4.6vw, 1.35rem)/1.35 var(--font-accent); color: var(--title); }
.pr-typed li { animation: pr-type .5s steps(14) both; }
.pr-typed li::before { content: "// "; color: var(--accent-ink); }
.pr-typed li.is-win { margin-top: .4rem; font: 900 clamp(2.4rem, 12vw, 3.4rem)/1 var(--font-body); color: var(--accent-ink, var(--iron-accent)); animation: pr-slam .4s cubic-bezier(.2, 1.6, .4, 1) both; }
.pr-typed li.is-win::before { content: none; }
@keyframes pr-type { from { clip-path: inset(0 100% 0 0); } to { clip-path: inset(0); } }
@media (prefers-reduced-motion: reduce) { .pr-typed li, .pr-spot__card.is-won, .pr-who.is-in { animation: none; } }

/* Leave game: a quiet link under the lobby */
.pr-leave { justify-self: start; font: 400 .85rem/1.2 var(--font-accent); color: var(--soft); min-height: 44px; }
/* the match's ⋮ menu: a dim icon by your score, opening a sheet from the bottom. The sheet takes the iron band's
   colors for the theme (Oct 23: it was always charcoal, so in light mode its dark text was invisible). */
.pr-top__right { display: inline-flex; align-items: center; gap: 4px; }
.pr-menu-btn {
  width: 44px; height: 44px; margin: -12px -12px -12px 0; font: 700 1.3rem/1 var(--font-body); color: var(--soft);
  background: none; border: 0; border-radius: 50%; cursor: pointer; opacity: .7;
}
.pr-menu-btn:hover, .pr-menu-btn[aria-expanded="true"] { opacity: 1; color: var(--title); }
.pr-menu-btn:focus-visible { outline: 2px solid var(--focus); outline-offset: -4px; }
.pr-sheet { position: fixed; inset: 0; z-index: 50; display: flex; align-items: flex-end; justify-content: center; background: color-mix(in oklab, var(--char-950) 60%, transparent); }
.pr-sheet[hidden], .pr-sheet [hidden] { display: none; }   /* .btn sets its own display, which would beat hidden (Leave in the lobby) */
.pr-sheet__panel {
  --ink: var(--iron-ink); --soft: var(--iron-soft); --rule: var(--iron-rule); --title: var(--iron-title);
  --card: var(--iron-card); --accent-ink: var(--iron-accent); color: var(--ink);
  max-height: 92dvh; overflow-y: auto;
  width: min(100%, 34rem); display: grid; gap: 10px; padding: 18px var(--gutter, 16px) max(18px, env(safe-area-inset-bottom));
  background: var(--iron-bg); border-top: 3px solid var(--ember); border-radius: 10px 10px 0 0; animation: pr-rise .2s ease-out both;
}
.pr-sheet__panel .btn { width: 100%; justify-content: center; }
.pr-sheet__leave { background: var(--danger); border-color: var(--danger); }

/* How to play and the power-ups, in the ⋮ sheet (and from the lobby's How to play link): rows that open in place */
.pr-fold { background: var(--card); border: 2px solid var(--rule); border-radius: 4px; }
.pr-fold summary {
  list-style: none; display: flex; justify-content: space-between; align-items: center; min-height: 54px; padding: 0 1rem;
  font: 700 1.1rem/1 var(--font-body); color: var(--title); cursor: pointer;
}
.pr-fold summary::-webkit-details-marker { display: none; }
.pr-fold summary::after { content: "+"; font-size: 1.5rem; color: var(--soft); }
.pr-fold[open] summary::after { content: "−"; }
.pr-fold summary:focus-visible { outline: 2px solid var(--focus); outline-offset: 2px; }
.pr-fold .pr-help { padding: 0 1rem 1rem; max-height: 44dvh; }
.pr-help { display: grid; gap: .55rem; max-height: 52dvh; overflow-y: auto; padding: 2px 2px 6px; font-size: .98rem; line-height: 1.4; }
.pr-help b { color: var(--title); }
.pr-help__group { margin-top: .4rem; font: 400 .75rem/1 var(--font-accent); text-transform: uppercase; letter-spacing: .1em; color: var(--accent-ink); }
.pr-lobbylinks { display: flex; gap: 1.4rem; flex-wrap: wrap; }


/* ---------- Proteus (Nov 2026) ---------- */
.pr-tiles, .pr-tile { display: none; }
/* the turn row: everyone's face in turn order; the dice holder carries a die, the speaker grows, a check once spoken */
.pr-turns { display: flex; flex-wrap: wrap; gap: 6px; justify-content: center; }
.pr-turn { position: relative; display: grid; place-items: center; width: 40px; height: 40px; font-size: 1.4rem; line-height: 1;
  background: var(--card); border: 2px solid var(--rule); border-radius: 50%; transition: transform .15s; }
.pr-turn.is-me { border-color: var(--accent-ink); }
.pr-turn.is-off { opacity: .45; }
.pr-turn.is-now { transform: scale(1.3); border-color: var(--ember); animation: pr-pulse 1s ease-in-out infinite; z-index: 1; }
.pr-turn.is-done::after, .pr-turn.is-lock::after, .pr-turn.is-dice::before {
  position: absolute; display: grid; place-items: center; width: 18px; height: 18px; font: 700 .7rem/1 var(--font-body);
  border-radius: 50%; }
.pr-turn.is-done::after { content: "✓"; right: -5px; bottom: -5px; color: var(--on-ember); background: var(--ember); }
.pr-turn.is-lock::after { content: ""; right: -4px; bottom: -4px; width: 12px; height: 12px; background: var(--ember); border: 2px solid var(--card); border-radius: 3px; }   /* locked in (no emoji in the UI: Mark) */
.pr-turn.is-dice::before { content: "⚄"; left: -6px; top: -6px; font-size: .95rem; color: var(--title); background: var(--card); }
@keyframes pr-pulse { 50% { box-shadow: 0 0 0 6px color-mix(in oklab, var(--ember) 35%, transparent); } }

/* the board: the theme, big and centred, over a 4 x 4 grid of words */
.pr-btheme { font: 700 clamp(1.5rem, 7vw, 2.2rem)/1.15 var(--font-body); color: var(--title); text-align: center; }
.pr-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 5px; }
.pr-cell {
  position: relative; display: flex; align-items: center; justify-content: center; min-height: 58px; padding: .35rem .2rem;
  text-align: center; font: 700 clamp(.72rem, 3.3vw, .95rem)/1.15 var(--font-body); color: var(--title); overflow-wrap: anywhere; hyphens: auto;
  background: var(--card); border: 2px solid var(--rule); border-radius: 3px; transition: background-color .08s, border-color .08s, opacity .2s;
  user-select: none; -webkit-user-select: none;
}
button.pr-cell { cursor: pointer; }
button.pr-cell:focus-visible { outline: 3px solid var(--focus); outline-offset: 2px; }
/* the dice sweep: a row and a column light up and move, then stop */
.pr-grid.is-rolling .pr-cell.is-row, .pr-grid.is-rolling .pr-cell.is-col { background: color-mix(in oklab, var(--ember) 30%, var(--card)); border-color: var(--ember); }
.pr-grid.is-rolling .pr-cell.is-row.is-col { background: var(--ember); color: var(--on-ember); }
.pr-grid.is-rolled .pr-cell { animation: pr-flash .5s ease-out; }
@keyframes pr-flash { 30% { background: color-mix(in oklab, var(--ember) 40%, var(--card)); } }
/* your secret word, only while you hold the card */
.pr-grid.is-peek .pr-cell:not(.is-hit) { opacity: .3; }
.pr-cell.is-hit { background: var(--ember); border-color: var(--ember); color: var(--on-ember); }
/* the Proteus's guess, and the answer at the end */
.pr-cell.is-pick { border-color: var(--accent-ink); border-width: 3px; background: color-mix(in oklab, var(--accent-ink) 22%, var(--card)); }
.pr-cell.is-answer { background: var(--ember); border-color: var(--ember); color: var(--on-ember); }
.pr-cell.is-wrong { border-color: var(--danger); color: var(--danger); text-decoration: line-through; }

.pr-rollbtn { justify-self: stretch !important; min-height: 64px; font-size: 1.4rem; }

/* your card: a slim bar, press and hold to see it (a big face-down card until Nov 4 2026) */
.pr-hold {
  display: flex; align-items: center; gap: .7rem; min-height: 50px; padding: .35rem .8rem; cursor: pointer;
  font: 400 .9rem/1.2 var(--font-accent); color: var(--soft);
  background: var(--card); border: 2px dashed var(--rule); border-radius: 6px;
  user-select: none; -webkit-user-select: none; -webkit-touch-callout: none; touch-action: none;
}
.pr-hold__icon { width: 34px; height: 30px; object-fit: contain; opacity: .5; }
.pr-hold__word { font: 900 1.25rem/1.1 var(--font-body); color: var(--accent-ink); }
.pr-hold.is-open { border-style: solid; border-color: var(--ember); }
.pr-hold.is-open .pr-hold__icon { opacity: 1; }
.pr-hold:focus-visible { outline: 3px solid var(--focus); outline-offset: 2px; }
.pr-hold--compact { flex: none; min-height: 46px; padding: .2rem .7rem; font-size: .8rem; }
.pr-hold--compact .pr-hold__icon { display: none; }
.pr-hold--compact .pr-hold__word { font-size: 1rem; }

/* speaking */
.pr-speaker { display: flex; align-items: center; justify-content: center; gap: .6rem; font: 700 clamp(1.3rem, 6vw, 1.7rem)/1.2 var(--font-body); color: var(--title); text-align: center; }
.pr-speaker__face { font-size: 2.4rem; }
.pr-done { justify-self: stretch !important; min-height: 60px; font-size: 1.25rem; }

/* the vote panel: one row per player in clue order (face, name with their voters' faces under it, the clue, a
   count); the row is the vote button. Was a 2-column grid of cards next to a separate clue list until Nov 3 2026. */
.pr-votepanel { display: grid; gap: 8px; }
.pr-votes { display: grid; gap: 5px; }
.pr-vote {
  display: grid; grid-template-columns: auto minmax(0, 5.5rem) minmax(0, 1fr) 1.6rem; align-items: center; gap: .55rem;
  min-height: 56px; padding: .35rem .7rem; text-align: left; color: var(--title); background: var(--card);
  border: 2px solid var(--rule); border-radius: 3px; cursor: pointer; font: 700 .95rem/1.1 var(--font-body);
}
.pr-vote:not(:disabled):hover { border-color: var(--soft); }
.pr-vote:focus-visible { outline: 3px solid var(--focus); outline-offset: 2px; }
.pr-vote:disabled { cursor: default; }
.pr-vote.is-self { border-color: var(--accent-ink); }
.pr-vote.is-out { opacity: .3; }
.pr-vote.is-mine { border-color: var(--ember); box-shadow: inset 0 0 0 1px var(--ember); }
.pr-vote.is-mine.is-locked { background: var(--ember); color: var(--on-ember); }
.pr-vote.is-mine.is-locked .pr-vote__clue, .pr-vote.is-mine.is-locked .pr-vote__name { color: inherit; }
.pr-vote__face { font-size: 1.5rem; line-height: 1; }
.pr-vote__who { display: grid; gap: 3px; min-width: 0; }
.pr-vote__name { font: 400 .8rem/1.2 var(--font-accent); color: var(--soft); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.pr-vote__by { min-height: 1rem; font-size: .9rem; line-height: 1; letter-spacing: 1px; overflow-wrap: anywhere; }
.pr-vote__by:empty { display: none; }
.pr-vote__clue { font: 700 1.05rem/1.25 var(--font-body); color: var(--title); overflow-wrap: anywhere; }
.pr-vote__clue.is-soft { font: italic 400 .9rem/1.2 var(--font-body); color: var(--soft); }
.pr-vote__n { justify-self: end; font: 900 1.4rem/1 var(--font-body); font-variant-numeric: tabular-nums; }
.pr-voterow { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; }
.pr-lockbtn { flex: 1; }
.pr-lockbtn:disabled { opacity: .5; }

/* the reveal and the score */
.pr-verdict { font: 900 clamp(1.8rem, 9vw, 2.6rem)/1.1 var(--font-body); text-align: center; color: var(--accent-ink); animation: pr-slam .4s cubic-bezier(.2, 1.6, .4, 1) both; }
.pr-verdict.is-down { color: var(--danger); }
.pr-reveal { display: grid; justify-items: center; gap: .4rem; }
.pr-reveal__face { font-size: 4rem; line-height: 1; animation: pr-slam .45s cubic-bezier(.2, 1.6, .4, 1) both; }
.pr-reveal__icon { width: 150px; height: 132px; object-fit: contain; animation: pr-slam .45s .1s cubic-bezier(.2, 1.6, .4, 1) both; }
@keyframes pr-slam { from { transform: scale(2); opacity: 0; } }
.pr-row__score.is-up { color: var(--accent-ink, var(--iron-accent)); }
.pr-row__pts { font: 700 .9rem/1 var(--font-body); color: var(--accent-ink); min-width: 2.2ch; text-align: right; }
.pr-row__pts:empty { display: none; }
.pr-ring { font: 700 clamp(2.4rem, 12vw, 3.4rem)/1 var(--font-heading); color: var(--title); text-align: center; }
.pr-confirm { justify-self: stretch !important; }
.pr-big + .pr-soft { margin-top: -6px; }
.pr-who-icon { width: 28px; height: 25px; vertical-align: -6px; object-fit: contain; }
@media (prefers-reduced-motion: reduce) {
  .pr-turn.is-now, .pr-vote.is-now, .pr-verdict, .pr-reveal__face, .pr-reveal__icon, .pr-grid.is-rolled .pr-cell { animation: none; }
}
/* the zoom-in animations start at 2x: keep them from widening the page on phones */
.pr-play { overflow-x: clip; }

/* ---------- typed clues and the voting chat (Nov 2026: so the game also works with players apart) ---------- */
.pr-clueform { display: grid; gap: 8px; }
.pr-clueform .pr-pick { margin-top: 0; }
.pr-said { justify-self: start; min-height: 44px; font: 400 .9rem/1.2 var(--font-accent); color: var(--soft); text-decoration: underline; }
.pr-said:disabled { opacity: .5; }
/* the clues so far: face, name, the clue */
.pr-clues { list-style: none; margin: 0; padding: 0; display: grid; gap: 4px; }
.pr-clues[hidden] { display: none; }
.pr-clue {
  display: grid; grid-template-columns: auto minmax(0, 6.5rem) 1fr; align-items: center; gap: .6rem; min-height: 44px; padding: .3rem .7rem;
  background: var(--card); border: 2px solid var(--rule); border-radius: 3px;
}
.pr-clue.is-me { border-color: var(--accent-ink); }
.pr-clue__face { font-size: 1.3rem; line-height: 1; }
.pr-clue__name { font: 400 .8rem/1.2 var(--font-accent); color: var(--soft); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.pr-clue__text { font: 700 1.05rem/1.25 var(--font-body); color: var(--title); overflow-wrap: anywhere; }
.pr-clue__text.is-soft { font: italic 400 .9rem/1.2 var(--font-body); color: var(--soft); }
/* the chat: a short scrolling list over a Send box */
.pr-chat { display: grid; gap: 6px; }
.pr-chat .pr-pick { margin-top: 0; }
.pr-chat__lines {
  list-style: none; margin: 0; padding: .5rem .7rem; display: grid; gap: 5px; align-content: start;
  max-height: 11.5rem; overflow-y: auto; overscroll-behavior: contain;
  background: var(--card); border: 2px solid var(--rule); border-radius: 3px;
}
.pr-chat__line { font-size: .98rem; line-height: 1.3; overflow-wrap: anywhere; }
.pr-chat__line.is-empty { color: var(--soft); font-style: italic; }
.pr-chat__who { margin-right: .45em; font: 700 .85rem/1 var(--font-body); color: var(--soft); }
.pr-chat__line.is-me .pr-chat__who { color: var(--accent-ink); }
.pr-chat__text { color: var(--title); }
.pr-chat__input { min-height: 46px; font-size: 1.05rem; }
.pr-pick .pr-error, .pr-clueform .pr-error[hidden], .pr-chat .pr-error[hidden] { display: none; }

/* ---------- the round's layout follows the round (Nov 4 2026, mockup "E"; same on every phone) ---------- */
/* whose turn (or what's happening) and the clock, on one line */
.pr-clock { display: flex; align-items: center; justify-content: space-between; gap: .8rem; }
.pr-clock__what { min-width: 0; font: 700 clamp(1.1rem, 5vw, 1.3rem)/1.2 var(--font-body); color: var(--title); overflow-wrap: anywhere; }
.pr-clock__what small { display: block; margin-top: 2px; font: 400 .78rem/1.2 var(--font-accent); color: var(--soft); }
.pr-count--clock { flex: none; font-size: clamp(1.6rem, 8vw, 2rem); min-height: 0; text-align: right; }
/* board sizes: big while you study it, tiny once the clues matter more */
.pr-boardwrap--big .pr-cell { min-height: 60px; }
.pr-boardwrap--tiny { gap: 6px !important; }
.pr-boardwrap--tiny .pr-btheme { font-size: 1rem; text-align: left; }
.pr-boardwrap--tiny .pr-grid { gap: 3px; }
.pr-boardwrap--tiny .pr-cell { min-height: 34px; padding: .1rem; font-size: clamp(.64rem, 2.9vw, .78rem); border-width: 1px; }
.pr-boardwrap[hidden] { display: none !important; }
/* slim clue rows (before your clue, and while voting) */
.pr-votepanel--mini .pr-votes { gap: 3px; }
.pr-votepanel--mini .pr-vote { min-height: 40px; padding: .15rem .6rem; }
.pr-votepanel--mini .pr-vote__face { font-size: 1.15rem; }
.pr-votepanel--mini .pr-vote__clue { font-size: .98rem; }
.pr-voterow[hidden] { display: none; }
/* the clue rows carry what the faces row used to: who's speaking, who's locked in */
.pr-vote.is-now { border-color: var(--ember); animation: pr-pulse 1.2s ease-in-out infinite; }
.pr-vote__face { position: relative; }
.pr-vote__face.is-lock::after { content: ""; position: absolute; right: -4px; bottom: -3px; width: 11px; height: 11px; background: var(--ember); border: 2px solid var(--card); border-radius: 3px; }
/* voting: the board folded to one line, with a short card button */
.pr-foldline { display: flex; gap: 6px; }
.pr-foldbtn {
  flex: 1; min-width: 0; min-height: 46px; display: flex; align-items: center; justify-content: space-between; gap: .5rem; padding: 0 .8rem;
  font: 700 .95rem/1.1 var(--font-body); color: var(--title); text-align: left; cursor: pointer;
  background: var(--card); border: 2px solid var(--rule); border-radius: 6px;
}
.pr-foldbtn small { flex: none; font: 400 .75rem/1 var(--font-accent); color: var(--soft); }
.pr-foldline + .pr-boardwrap .pr-btheme { display: none; }   /* the fold button already names the theme */
.pr-foldbtn:focus-visible { outline: 3px solid var(--focus); outline-offset: 2px; }
.pr-chat__lines { max-height: 15rem; min-height: 6rem; }
/* results: what happened and your points first */
.pr-result { display: grid; justify-items: center; gap: .3rem; text-align: center; }
.pr-result__face { font-size: 2.6rem; line-height: 1; animation: pr-slam .45s cubic-bezier(.2, 1.6, .4, 1) both; }
.pr-result .pr-verdict { font-size: clamp(1.4rem, 7vw, 1.9rem); }
.pr-result__pts { font: 900 clamp(3rem, 16vw, 4.4rem)/1 var(--font-body); color: var(--title); animation: pr-slam .4s .15s cubic-bezier(.2, 1.6, .4, 1) both; }
.pr-result__pts.is-zero { color: var(--soft); }
/* the pause screen */
.pr-count-note { margin-top: -10px; text-align: center; }
.pr-row--slot { border-style: dashed; color: var(--soft); justify-content: center; }
.pr-row--slot::before { content: none; }
@media (prefers-reduced-motion: reduce) { .pr-result__face, .pr-result__pts { animation: none; } }
.pr-row__held { display: block; font: 400 .72rem/1.2 var(--font-accent); color: var(--soft); }   /* "left the game", under the name */

/* ---------- Mark's art (Nov 4 2026): the wolf mascot (design-assets/proteus/) ---------- */
/* the wolf beside the start, join and lobby screens, and small in the corner of the game */
.pr-main .wrap { position: relative; }
.pr-mascot { position: absolute; top: -18px; right: 0; width: clamp(96px, 26vw, 150px); height: auto; pointer-events: none; }
/* the first heading of each screen leaves room for him on the right */
.pr-view > .pr-h:first-child, .pr-lobby-head { min-height: clamp(70px, 20vw, 110px); padding-right: clamp(100px, 28vw, 160px); align-content: start; }
.pr-lobby-head { align-items: flex-start; }
.pr-top__left { display: inline-flex; align-items: center; gap: 8px; }
.pr-corner { width: 28px; height: 28px; margin: -6px 0; }

/* start screen: the name as a dictionary entry (Nov 4 2026). Red only as the line above the closing tag, never as text on dark. */
.pr-dict { display: grid; gap: .8rem; margin: .2rem 0 .6rem; }
.pr-dict__defs { margin: 0; display: grid; gap: .25rem; }
.pr-dict__defs dt { margin-top: .5rem; }
.pr-dict__defs dt:first-child { margin-top: 0; }
.pr-dict__defs dd { margin: 0; color: var(--soft); }
.pr-dict__word { font: var(--font-heading-weight) 1.35rem/1.2 var(--font-heading); color: var(--title); letter-spacing: .03em; }
.pr-dict__pos { font-size: .9rem; color: var(--soft); }
.pr-dict__tag {
  justify-self: start; margin: 0; padding-top: .7rem; border-top: 2px solid var(--ember);
  font: 400 .82rem/1.4 var(--font-accent); text-transform: uppercase; letter-spacing: .12em; color: var(--title);
}
.pr-dict .pr-note .pr-dict__word { line-height: 1; }   /* the name inside the paragraph, without stretching its line */

/* Nov 7 2026: the dictionary entry while waiting for the theme and board; the clues under the board while the
   caught Beguiler guesses (read-only) */
.pr-dict--wait { margin: 1rem 0; padding: .9rem 1rem; border: 1px solid var(--soft); border-radius: 8px; text-align: left; }
.pr-votepanel--read .pr-vote { pointer-events: none; }
.pr-clues-label { margin-top: 1rem; }
