/* Traditional Thanksgiving Games: game CSS. Tokens from /design/garden.css. The canvas draws every scene; the DOM holds
   the HUD, the dialog box, the game picker, the haggle, the rope buttons, the toss button and the cards. Every panel
   sits at the bottom of the stage (one thumb), the scene fits into what is left above it. App bar and card patterns
   follow our Hopping Tune sprout. */
/* Grandma's red handwriting on the back of the photo and Grandpa's gravy slip (round 3): Dancing Script 700, latin
   subset from @fontsource/dancing-script 5.3.0, SIL OFL 1.1 (fonts/LICENSE-dancing-script-OFL.txt). Drawn on the canvas;
   ui.js loads it at boot so the first photo already has it. */
@font-face { font-family: 'Dancing Script'; font-style: normal; font-weight: 700; font-display: swap; src: url(fonts/dancing-script-latin-700-normal.woff2) format('woff2'); }
html, body { height: 100%; }
body { display: flex; flex-direction: column; height: 100svh; overflow: hidden; overscroll-behavior: none; background: var(--gg-cream); }
@supports (height: 100dvh) { body { height: 100dvh; } }
.tg-appbar { position: relative; z-index: 5; flex: none; }
.tg-appbar .gg-wordmark { display: inline-flex; align-items: center; min-height: 44px; min-width: 44px; }
.tg-appbar .gg-btn--icon { min-width: 44px; min-height: 44px; }
.tg-namechip { min-height: 30px; }
.tg-ggchip:empty { display: none; }
@media (max-width: 600px) { .tg-namechip, .tg-ggchip { display: none; } }
/* live: the trophy joins How to play, Sound and Pause, so a phone keeps the leaf and drops the word (the leaf still goes home) */
@media (max-width: 440px) { .tg-appbar .gg-wordmark span { display: none; } }
@media (max-width: 370px) { .tg-appbar .gg-wordmark span { display: none; } }
@media (orientation: landscape) and (max-height: 500px) {
  .tg-appbar .gg-appbar__in { min-height: 50px; padding-block: 3px; }
  .tg-appbar .gg-wordmark { font-size: 19px; }
  .tg-appbar .gg-wordmark svg { width: 30px; height: 30px; }
}

.tg-main { position: relative; flex: 1 1 auto; min-height: 0; width: 100%; }
.tg-stage {
  position: absolute; inset: 0; overflow: hidden; background: #F6E3C0;
  touch-action: none; user-select: none; -webkit-user-select: none; -webkit-touch-callout: none; -webkit-tap-highlight-color: transparent;
}
.tg-stage *, .tg-appbar, .tg-appbar * { -webkit-user-select: none; user-select: none; -webkit-touch-callout: none; -webkit-user-drag: none; }
.tg-canvas { position: absolute; inset: 0; width: 100%; height: 100%; display: block; touch-action: none; }

/* ---------- HUD ---------- */
.tg-hud { position: absolute; z-index: 3; top: 8px; left: 8px; right: 8px; display: flex; gap: 6px; justify-content: space-between; align-items: center; pointer-events: none; }
.tg-hud[hidden], .tg-hud .gg-pill[hidden] { display: none; }
.tg-hud .gg-pill { min-height: 32px; box-shadow: var(--gg-shadow-sm); white-space: nowrap; }
.tg-hudname { background: var(--gg-butter); font-family: var(--gg-font-display); font-weight: 800; overflow: hidden; text-overflow: ellipsis; min-width: 0; flex: 0 1 auto; }
.tg-hudinfo { background: var(--gg-paper); flex: none; }
.tg-hudscore { background: var(--gg-lime-100); font-weight: 800; flex: none; }

/* the Rule of the Year chip, under the HUD during the last game */
.tg-rulechip { position: absolute; z-index: 3; top: 48px; left: 8px; max-width: calc(100% - 16px); margin: 0; padding: 3px 10px; border: 2px solid var(--gg-ink); border-radius: 999px; background: var(--gg-butter-100); font: 800 13px/1.3 var(--gg-font-body); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; pointer-events: none; box-shadow: var(--gg-shadow-sm); }
.tg-rulechip[hidden] { display: none; }

/* the choice gate (src/gate.js): fresh choices fade in over the beat in which they cannot be picked */
.tg-panel.is-arming .tg-game, .tg-panel.is-arming .tg-opt, .tg-panel.is-arming .tg-btns, .tg-wall.is-arming .tg-wallpic { animation: tg-arm 300ms ease-out both; }
@keyframes tg-arm { from { opacity: .45; } to { opacity: 1; } }
/* the haggle beats (round 3): the options keep their place but hide while Mom speaks and Grandma answers, and the
   cue sits where they were: "Tap to continue" when a beat waits for the player, a quiet line while Grandma thinks.
   They come back (armed through the gate) when it is time to choose. The panel's height is locked in ui.js
   (lockHaggle), so nothing above it ever moves. */
.tg-haggle { display: flex; flex-direction: column; }
.tg-haggle .tg-hagline { flex: none; }
/* what Mom tried sits under Grandma's line; the score and the options stay pinned to the bottom of the locked panel */
.tg-haggle .tg-hagtotal { margin-top: auto; }
.tg-hagfoot { position: relative; }
.tg-haggle.is-wait .tg-hagopts { visibility: hidden; }
.tg-haggle.is-wait { cursor: pointer; }
/* while the beats play, the options' place holds what Mom tried and the cue */
.tg-hagbeat { position: absolute; inset: 0; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 8px; text-align: center; }
.tg-hagbeat[hidden] { display: none; }
.tg-hagnext { width: fit-content; max-width: 100%; min-height: 48px; padding-inline: 18px; background: var(--gg-butter); }
.tg-hagnext::after { content: ''; width: 10px; height: 10px; margin-left: 10px; border-right: 3px solid currentColor; border-bottom: 3px solid currentColor; transform: translateY(-2px) rotate(45deg); animation: tg-nudge 1s ease-in-out infinite; }
.tg-hagnext.is-quiet { background: transparent; border-color: transparent; box-shadow: none; font-weight: 700; color: var(--gg-ink-2); font-style: italic; pointer-events: none; }
.tg-hagnext.is-quiet::after { display: none; }
.tg-delta.is-pulse { animation: tg-pulse .45s ease-in-out infinite alternate; }
@keyframes tg-pulse { to { transform: scale(1.15); } }

/* ---------- the dialog box ---------- */
.tg-talk {
  position: absolute; z-index: 4; left: 10px; right: 10px; bottom: calc(10px + env(safe-area-inset-bottom, 0px));
  max-width: 640px; margin: 0 auto; padding: 10px 14px 14px; background: var(--gg-paper); border: var(--gg-border);
  border-radius: var(--gg-r-md); box-shadow: var(--gg-shadow); cursor: pointer; min-height: 112px;
}
.tg-talk[hidden] { display: none; }
.tg-talk__head { display: flex; align-items: center; justify-content: space-between; gap: 8px; min-height: 30px; }
.tg-talk__who { display: inline-block; padding: 3px 10px; border: 2px solid var(--gg-ink); border-radius: 999px; background: var(--who, var(--gg-butter)); font: 800 15px/1.2 var(--gg-font-display); }
.tg-talk__who:empty { visibility: hidden; }
.tg-talk__who:empty::before { content: '\200b'; } /* the narrator's empty tag keeps a tag's height, so the head never shifts */
.tg-talk__text { margin: 6px 2px 0; font: 700 var(--gg-text-md)/1.4 var(--gg-font-body); color: var(--gg-ink); min-height: 2.8em; }
/* the rest of a line still to be typed takes its space already, so the words never reflow while they type (round 3) */
.tg-talk__text .tg-ghost { visibility: hidden; }
.tg-talk__text.is-narr { font-style: italic; font-weight: 600; color: var(--gg-ink-2); }
.tg-talk__how { margin: 6px 2px 0; padding: 6px 10px; border-radius: 10px; background: var(--gg-lime-100); border: 2px dashed rgba(17,17,17,.35); font: 800 var(--gg-text-sm)/1.35 var(--gg-font-body); }
.tg-talk__how[hidden] { display: none; }
.tg-talk__more { position: absolute; right: 12px; bottom: 6px; width: 20px; height: 20px; opacity: .7; animation: tg-nudge 1s ease-in-out infinite; }
.tg-talk.is-typing .tg-talk__more { visibility: hidden; }
.tg-skip { min-height: 44px; min-width: 64px; }
@keyframes tg-nudge { 50% { transform: translateY(3px); } }

/* ---------- bottom panels ---------- */
.tg-panel {
  position: absolute; z-index: 4; left: 10px; right: 10px; bottom: calc(10px + env(safe-area-inset-bottom, 0px));
  max-width: 640px; margin: 0 auto; padding: 12px; background: var(--gg-paper); border: var(--gg-border);
  border-radius: var(--gg-r-md); box-shadow: var(--gg-shadow);
}
.tg-panel[hidden] { display: none; }
.tg-panel__head { display: flex; align-items: baseline; justify-content: space-between; gap: 8px; flex-wrap: wrap; margin-bottom: 8px; }
.tg-h2 { margin: 0; font: 800 var(--gg-text-lg)/1.15 var(--gg-font-display); }
.tg-sub { margin: 0; font: 700 var(--gg-text-sm)/1.3 var(--gg-font-body); color: var(--gg-ink-2); }
.tg-picklist { display: grid; gap: 8px; }
.tg-game {
  display: grid; grid-template-columns: 44px 1fr auto; align-items: center; gap: 10px; width: 100%; min-height: 60px; padding: 8px 12px;
  text-align: left; background: var(--gg-cream); border: var(--gg-border); border-radius: 14px; box-shadow: var(--gg-shadow-sm);
  font: inherit; color: var(--gg-ink); cursor: pointer;
}
.tg-game:hover:not(:disabled) { background: var(--gg-butter-100); }
.tg-game:active:not(:disabled) { transform: translate(2px, 2px); box-shadow: none; }
.tg-game b { display: block; font: 800 var(--gg-text-md)/1.15 var(--gg-font-display); }
.tg-game small { display: block; font: 600 13px/1.3 var(--gg-font-body); color: var(--gg-ink-2); margin-top: 2px; }
.tg-game i { font-style: normal; font: 800 var(--gg-text-md)/1 var(--gg-font-display); padding: 6px 10px; border-radius: 999px; border: 2px solid var(--gg-ink); background: var(--gg-lime-100); }
.tg-game:disabled { opacity: .62; cursor: default; background: var(--gg-sand); }
.tg-game svg { width: 44px; height: 44px; display: block; }

.tg-hagline { display: flex; flex-direction: column; align-items: flex-start; gap: 4px; }
.tg-hagmom { margin: 0 6px; font: 600 var(--gg-text-sm)/1.35 var(--gg-font-body); font-style: italic; color: var(--gg-ink-2); }
.tg-hagmom[hidden] { display: none; }
.tg-hagline p { margin: 0 2px; font: 700 var(--gg-text-md)/1.35 var(--gg-font-body); min-height: 2.7em; }
.tg-hagline p.is-narr { font-style: italic; font-weight: 600; color: var(--gg-ink-2); } /* round 4: what Mom does, told like the narrator */
.tg-hagtotal { margin: 6px 2px 8px; }
.tg-hagtotal b { color: var(--gg-ink); }
.tg-hagopts { display: grid; gap: 8px; }
.tg-opt { min-height: 48px; width: 100%; padding: 8px 12px; text-align: left; justify-content: flex-start; font: 800 var(--gg-text-sm)/1.2 var(--gg-font-body); }
.tg-opt--stop { background: var(--gg-sand); }
.tg-delta { display: inline-block; margin-left: 6px; padding: 1px 8px; border-radius: 999px; border: 2px solid var(--gg-ink); font: 800 14px/1.3 var(--gg-font-display); }
.tg-delta.is-up { background: var(--gg-lime); }
.tg-delta.is-down { background: var(--gg-pink-100); }

/* ---------- play controls ---------- */
.tg-ropes { position: absolute; z-index: 4; left: 10px; right: 10px; bottom: calc(10px + env(safe-area-inset-bottom, 0px)); display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; max-width: 520px; margin: 0 auto; }
.tg-ropes[hidden] { display: none; }
.tg-rope {
  position: relative; min-height: 84px; border: var(--gg-border); border-radius: 18px; background: var(--rope); box-shadow: var(--gg-shadow);
  font: 800 28px/1 var(--gg-font-display); color: var(--gg-ink); cursor: pointer; touch-action: none; transition: transform 60ms;
}
.tg-rope span { display: inline-grid; place-items: center; width: 44px; height: 44px; border-radius: 50%; background: var(--gg-paper); border: 2px solid var(--gg-ink); }
.tg-rope[data-lane="0"] { --rope: #FF8FB8; }
.tg-rope[data-lane="1"] { --rope: var(--gg-butter); }
.tg-rope[data-lane="2"] { --rope: #8DCBF8; }
.tg-rope.is-down { transform: translate(3px, 3px); box-shadow: none; }
.tg-ropes.is-them .tg-rope { filter: grayscale(.85); opacity: .55; }
.tg-rope.is-lit { outline: 4px solid var(--gg-ink); outline-offset: 3px; animation: tg-glow .5s ease-in-out infinite alternate; }
@keyframes tg-glow { to { box-shadow: 6px 6px 0 var(--gg-ink); } }
.tg-toss {
  position: absolute; z-index: 4; left: 0; right: 0; margin: 0 auto; width: fit-content; bottom: calc(14px + env(safe-area-inset-bottom, 0px));
  min-width: 200px; min-height: 64px; font-size: var(--gg-text-lg); touch-action: none;
}
.tg-toss.is-down { background: var(--gg-butter); }
.tg-toss[hidden] { display: none; }
.tg-hint { position: absolute; z-index: 3; left: 0; right: 0; width: fit-content; margin: 0 auto; bottom: calc(92px + env(safe-area-inset-bottom, 0px)); padding: 6px 12px; border-radius: 999px; background: rgba(255,254,246,.92); border: 2px solid var(--gg-ink); font: 800 14px/1.25 var(--gg-font-body); white-space: nowrap; pointer-events: none; }
.tg-hint[hidden] { display: none; }

/* ---------- the end ---------- */
.tg-end { text-align: center; }
.tg-end .gg-eyebrow { margin: 0; }
.tg-endline { margin: 6px 0 8px; font: 600 var(--gg-text-sm)/1.4 var(--gg-font-body); color: var(--gg-ink-2); }
.tg-endrows { display: flex; flex-wrap: wrap; gap: 6px; justify-content: center; margin-bottom: 10px; }
.tg-endrows span { padding: 3px 10px; border-radius: 999px; border: 2px solid var(--gg-ink); background: var(--gg-cream); font: 800 14px/1.4 var(--gg-font-body); }
.tg-endrows span.is-total { background: var(--gg-butter); }
/* the garden board moment (platform/gg.js resultMoment): one or two short lines above the buttons */
/* The board line (platform/gg.js resultMoment) in the end card. ONE fixed height from the moment the photo shows to
   after the reply lands, so Grandma's photo never moves (round 3: nothing on this page jumps). Two rows: the points (or
   "Put your name on the leaderboard?") with its button beside it, then one line: the badges earned, else the rank.
   The sign-in nudge, the weekly flower line and the star rating would grow the card, so they stay off here. Short
   phones and landscape: the first row only. */
.tg-end .tg-moment { display: grid; grid-template-columns: minmax(0, 1fr) auto; grid-template-rows: 44px 20px;
  align-items: center; justify-items: start; gap: 4px 10px; height: 88px; margin: 0 0 10px; padding: 8px 12px; overflow: hidden; text-align: left; }
.tg-end .tg-moment[hidden] { display: none; }
.tg-moment .ggp-moment__row { display: contents; }
.tg-moment > p:first-child { grid-area: 1 / 1; margin: 0; min-width: 0; max-width: 100%; }
.tg-moment .ggp-moment__pts { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; font-size: var(--gg-text-sm); }
.tg-moment .ggp-moment__row .gg-btn { grid-area: 1 / 2; margin: 0; }
.tg-moment .ggp-moment__pts b { font-size: 26px; }
.tg-moment .ggb-moment, .tg-moment .ggp-moment__rank { grid-area: 2 / 1 / 3 / 3; margin: 0; max-width: 100%; display: flex; align-items: center; gap: 6px;
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis; font-size: 13px; line-height: 20px; }
.tg-moment .ggb-moment > span { overflow: hidden; text-overflow: ellipsis; }
.tg-moment .ggb-moment svg { flex: none; width: 18px; height: 18px; }
.tg-moment .ggb-moment ~ .ggp-moment__row .ggp-moment__rank, .tg-moment .ggp-moment__rank:empty,
.tg-moment .ggb-moment--week, .tg-moment .ggp-moment__safe, .tg-moment .ggp-rate { display: none; }
/* Grandma's photo keeps the room: with the board line up, the end card drops its description line (the photo says it) */
.tg-end:has(.tg-moment:not([hidden])) .tg-endline { display: none; }
@media (max-height: 700px), (orientation: landscape) and (max-height: 500px) {
  .tg-end .tg-moment { grid-template-rows: 44px; height: 56px; margin-bottom: 8px; padding: 6px 10px; }
  .tg-moment .ggb-moment, .tg-moment .ggp-moment__rank { display: none; }
}
/* narrow phones: the points stay on one line beside the button */
@media (max-width: 380px) {
  .tg-moment .ggp-moment__pts b { font-size: 22px; }
  /* the board button keeps its trophy (its label stays for screen readers), so the points keep their words */
  .tg-moment .ggp-moment__btn[data-act="board"] { font-size: 0; gap: 0; min-width: 52px; padding-left: 12px; padding-right: 12px; }
  /* no garden name yet: the button says it all ("Add my name"), centred */
  .tg-moment[data-state="anon"] > p:first-child { display: none; }
  .tg-moment[data-state="anon"] .gg-btn { grid-column: 1 / -1; justify-self: center; }
}
/* the smallest phones (iPhone SE): the result title on one line gives Grandma's photo back the room the board line takes */
@media (max-height: 600px) and (orientation: portrait) {
  .tg-end:has(.tg-moment:not([hidden])) .tg-h2 { font-size: var(--gg-text-md); margin-bottom: 6px; }
}
.tg-btns { display: flex; gap: 10px; justify-content: center; flex-wrap: wrap; }
.tg-btns .gg-btn { min-height: 48px; }

/* ---------- the family photo wall (round 3) ---------- */
.tg-wall { position: absolute; z-index: 6; inset: 0; display: flex; flex-direction: column; padding: 10px 10px calc(10px + env(safe-area-inset-bottom, 0px));
  background: repeating-linear-gradient(90deg, #F6E3C0 0 22px, #EFD3A6 22px 34px); }
.tg-wall[hidden] { display: none; }
.tg-wall__head { display: flex; align-items: center; justify-content: space-between; gap: 8px; max-width: 900px; width: 100%; margin: 0 auto; padding: 8px 12px; background: var(--gg-paper); border: var(--gg-border); border-radius: var(--gg-r-md); box-shadow: var(--gg-shadow-sm); }
.tg-wall__close { min-height: 44px; min-width: 64px; }
.tg-wall__note { max-width: 900px; width: 100%; margin: 8px auto 4px; padding: 0 4px; }
.tg-wall__note.is-news { color: var(--gg-ink); font-weight: 800; }
.tg-wall__grid { flex: 1 1 auto; min-height: 0; overflow-y: auto; overscroll-behavior: contain; touch-action: pan-y; max-width: 900px; width: 100%; margin: 0 auto;
  display: grid; grid-template-columns: repeat(auto-fill, minmax(128px, 1fr)); grid-auto-rows: max-content; gap: 22px 14px; align-content: start; padding: 14px 6px 10px; }
.tg-wallpic { position: relative; height: max-content; display: flex; flex-direction: column; align-items: center; gap: 4px; min-height: 44px; padding: 0; border: 0; background: none; cursor: pointer; transform: rotate(var(--tilt, 0deg)); color: var(--gg-ink); font: inherit; }
.tg-wallpic::before { content: ''; position: absolute; z-index: 1; top: -6px; left: 50%; width: 46px; height: 14px; margin-left: -23px; background: rgba(255,243,196,.85); border: 1px solid rgba(17,17,17,.2); transform: rotate(-3deg); }
.tg-wallpic canvas { display: block; flex: none; width: 100%; height: auto; aspect-ratio: 236 / 188; }
.tg-wallpic span { font: 800 13px/1.2 var(--gg-font-body); background: rgba(255,254,246,.9); padding: 2px 8px; border-radius: 999px; }
.tg-wallpic:active { transform: rotate(var(--tilt, 0deg)) translate(2px, 2px); }
.tg-wallpic:focus-visible { outline: 3px solid var(--gg-ink); outline-offset: 4px; }
.tg-wallview { text-align: center; display: flex; flex-direction: column; justify-content: flex-end; }
.tg-wallview .gg-eyebrow { margin: 0; }
.tg-wallview .tg-h2 { margin: 2px 0 8px; }
.tg-wallview .tg-btns .gg-btn { min-height: 48px; }
.tg-wv-ask .tg-sub { margin: 0 0 8px; color: var(--gg-ink); }
.tg-wv-ask[hidden], #wv-main[hidden] { display: none; }
.tg-btn-fire { background: var(--gg-tangerine); }
/* round 4: share a photo; the toast says what happened when there is no share sheet ("Link copied") */
.tg-btn-share { background: var(--gg-lavender-100); }
.tg-toast { position: absolute; left: 50%; top: 12px; z-index: 20; transform: translateX(-50%); max-width: calc(100% - 24px); margin: 0;
  padding: 8px 16px; border: 2.5px solid var(--gg-ink); border-radius: 999px; background: var(--gg-lime); box-shadow: 3px 3px 0 var(--gg-ink);
  font: 800 var(--gg-text-sm)/1.3 var(--gg-font-body); text-align: center; overflow-wrap: anywhere; pointer-events: none; animation: tg-toast 220ms ease-out both; }
.tg-toast.is-plain { background: var(--gg-paper); pointer-events: auto; user-select: text; -webkit-user-select: text; }
.tg-toast[hidden] { display: none; }
@keyframes tg-toast { from { opacity: 0; transform: translate(-50%, -6px); } to { opacity: 1; transform: translate(-50%, 0); } }

/* ---------- cards ---------- */
.tg-card { max-width: 460px; text-align: center; }
.tg-title { margin: 4px 0 8px; font: 800 var(--gg-text-2xl)/1.05 var(--gg-font-display); }
.tg-lede { margin: 0 0 14px; font: 600 var(--gg-text-md)/1.45 var(--gg-font-body); }
.tg-howlist { text-align: left; margin: 10px 0 14px; padding-left: 18px; display: grid; gap: 8px; font: 600 var(--gg-text-sm)/1.45 var(--gg-font-body); }
body:not(.is-touch) .tg-touch, body.is-touch .tg-keys { display: none; }

/* ---------- small and landscape phones ---------- */
/* phones up to 700 px tall (iPhone 13 and smaller): the end card keeps to its title and buttons so Grandma's photo
   gets the room; the scores are on the back of the photo, and the wordmark still goes home (round 3) */
@media (max-height: 700px) {
  .tg-end .gg-eyebrow, .tg-end .tg-endline, .tg-end .tg-endrows, .tg-end a.gg-btn { display: none; }
}
@media (max-height: 640px) {
  .tg-talk { min-height: 96px; padding: 8px 12px 10px; }
  .tg-talk__text { font-size: var(--gg-text-sm); min-height: 2.6em; }
  .tg-game { min-height: 52px; padding: 6px 10px; }
  .tg-game small { display: none; }
  .tg-rope { min-height: 66px; }
  .tg-hagline p { font-size: var(--gg-text-sm); }
  .tg-hagmom { display: none; }
  /* short phones: the scores are on the back of Grandma's photo, so the end card keeps to the title and buttons */
  .tg-end .tg-endline, .tg-end .tg-endrows { display: none; }
  .tg-end .tg-h2 { margin-bottom: 8px; }
  .tg-wallview .gg-eyebrow { display: none; }
  /* short phones: the photo gets the room (the wordmark still goes home; the eyebrow is on the photo's back) */
  .tg-end .gg-eyebrow, .tg-end a.gg-btn { display: none; }
  .tg-hagopts { gap: 6px; }
  .tg-opt { min-height: 44px; padding: 6px 10px; }
  .tg-panel { padding: 10px; }
}
@media (orientation: landscape) and (max-height: 500px) {
  .tg-talk, .tg-panel { left: 8px; right: 8px; bottom: calc(6px + env(safe-area-inset-bottom, 0px)); padding: 6px 10px 8px; }
  .tg-talk { min-height: 84px; }
  .tg-talk__head { min-height: 26px; }
  .tg-talk__text { margin-top: 3px; min-height: 2.5em; }
  .tg-panel { max-width: 800px; }
  .tg-picklist { grid-template-columns: repeat(3, 1fr); }
  .tg-game { grid-template-columns: 36px 1fr; gap: 6px; min-height: 64px; }
  .tg-game i { grid-column: 1 / -1; justify-self: start; font-size: 14px; padding: 3px 8px; }
  .tg-game svg { width: 36px; height: 36px; }
  .tg-panel__head { margin-bottom: 4px; }
  .tg-hagopts { grid-template-columns: 1fr 1fr; gap: 6px; }
  .tg-hagline { flex-direction: row; align-items: baseline; gap: 8px; }
  .tg-hagline p { min-height: 0; }
  .tg-hagtotal { margin: 2px 2px 4px; }
  .tg-hagmom { display: none; }
  .tg-opt { min-height: 44px; padding: 4px 10px; }
  .tg-ropes { max-width: 600px; }
  .tg-rope { min-height: 58px; }
  .tg-toss { min-height: 54px; }
  .tg-hint { bottom: calc(70px + env(safe-area-inset-bottom, 0px)); }
  .tg-rulechip { top: 46px; }
  /* the end card docks on the right so Grandma's photo gets the left half */
  .tg-end { left: auto; right: 8px; top: 8px; width: min(48%, 400px); margin: 0; padding: 8px 10px; display: flex; flex-direction: column; justify-content: center; }
  .tg-endline { margin: 2px 0 4px; }
  .tg-endrows { margin-bottom: 4px; }
  .tg-wall { padding: 6px 8px; }
  .tg-wall__head { padding: 4px 10px; }
  .tg-wall__note { margin: 4px auto 0; }
  .tg-wall__grid { grid-template-columns: repeat(auto-fill, minmax(140px, 1fr)); padding-top: 12px; }
  /* the photo view docks on the right so the mantel and the fire get the left */
  .tg-wallview { left: auto; right: 8px; top: 8px; width: min(44%, 360px); margin: 0; padding: 8px 10px; justify-content: center; }
  .tg-wallview .tg-btns { flex-direction: column; align-items: stretch; gap: 6px; }
  .tg-wallview .tg-btns .gg-btn { min-height: 44px; }
}
@media (prefers-reduced-motion: reduce) {
  .tg-talk__more, .tg-rope.is-lit, .tg-delta.is-pulse, .tg-hagnext::after, .tg-toast { animation: none; }
  .tg-panel.is-arming .tg-game, .tg-panel.is-arming .tg-opt, .tg-panel.is-arming .tg-btns, .tg-wall.is-arming .tg-wallpic { animation: none; }
}
