* { box-sizing: border-box; margin: 0; padding: 0; }
html, body { height: 100%; background: #000; color: #fff; overflow: hidden; }
body { font-family: "Inter", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif; -webkit-font-smoothing: antialiased; -webkit-tap-highlight-color: transparent; user-select: none; -webkit-user-select: none; }

/* --u scales everything with the frame; X cards can be ~280 px tall */
:root { --u: min(1vh, 0.5625vw); --red: #ff2e2e; --ice: #9fe1ff; --gold: #ffd34d; --glass: rgba(14, 16, 22, 0.55); --line: rgba(255, 255, 255, 0.12); }
@media (max-aspect-ratio: 1/1) { :root { --u: min(0.62vh, 1vw); } }
:root { --safe-top: env(safe-area-inset-top, 0px); --safe-right: env(safe-area-inset-right, 0px); --safe-bottom: env(safe-area-inset-bottom, 0px); --safe-left: env(safe-area-inset-left, 0px); }

#app { position: fixed; inset: 0; overflow: hidden; touch-action: manipulation; background: #000; }
#game { position: absolute; inset: 0; width: 100%; height: 100%; display: block; }
#game, #title { touch-action: none; }
.hidden { display: none !important; }
#render-stats { position: fixed; left: 8px; bottom: 8px; z-index: 100; pointer-events: none; padding: 8px; color: #fff; background: #000c; font: 11px/1.5 monospace; }

/* ---------- HUD ---------- */
#hud { position: absolute; inset: 0; pointer-events: none; padding: calc(var(--u) * 3.2) calc(var(--u) * 3.6); display: flex; justify-content: space-between; align-items: flex-start; }
#hud-score { font-size: calc(var(--u) * 9); font-weight: 800; letter-spacing: -0.02em; line-height: 1; font-variant-numeric: tabular-nums; text-shadow: 0 2px 18px rgba(0,0,0,0.5); }
.hud-row { display: flex; align-items: center; gap: calc(var(--u) * 1.6); margin-top: calc(var(--u) * 1.2); }
#hud-best { font-size: max(9px, calc(var(--u) * 2.4)); letter-spacing: 0.16em; color: rgba(255,255,255,0.55); font-weight: 600; }
#hud-flow { position: relative; display: flex; align-items: baseline; gap: 4px; padding: 3px 9px 4px; border-radius: 999px; background: var(--glass); border: 1px solid var(--line); overflow: hidden; transition: opacity 0.3s; }
#hud-flow-x { font-weight: 900; font-size: max(11px, calc(var(--u) * 3.2)); font-style: italic; }
#hud-flow .lbl { font-size: max(8px, calc(var(--u) * 1.9)); letter-spacing: 0.18em; color: rgba(255,255,255,0.6); font-weight: 700; }
#hud-flow-bar { position: absolute; left: 0; right: 0; bottom: 0; height: 2px; background: var(--ice); transform-origin: left; }
#hud-flow.hot { border-color: rgba(255, 211, 77, 0.6); box-shadow: 0 0 18px rgba(255, 211, 77, 0.25); }
#hud-flow.hot #hud-flow-x { color: var(--gold); }
#hud-flow.hot #hud-flow-bar { background: var(--gold); }
#hud-flow.bump { animation: bump 0.35s cubic-bezier(.2,1.6,.4,1); }
@keyframes bump { 0% { transform: scale(1); } 40% { transform: scale(1.35); } 100% { transform: scale(1); } }
#hud-star { margin-top: calc(var(--u) * 1.2); font-size: max(9px, calc(var(--u) * 2.4)); font-weight: 800; letter-spacing: 0.14em; color: var(--gold); }
.hud-r { margin-right: calc(var(--u) * 9); min-width: calc(var(--u) * 30); text-align: right; }
.air-top { display: flex; justify-content: flex-end; align-items: baseline; gap: 5px; font-size: max(8px, calc(var(--u) * 2)); letter-spacing: 0.16em; color: rgba(255,255,255,0.6); font-weight: 700; }
.air-top b { font-size: max(12px, calc(var(--u) * 3.6)); color: #fff; letter-spacing: 0; font-variant-numeric: tabular-nums; }
.air-bar { margin-top: 5px; height: 5px; border-radius: 3px; background: rgba(255,255,255,0.12); overflow: hidden; }
.air-bar i { display: block; height: 100%; background: linear-gradient(90deg, #5fc8ff, #c9f0ff); transform-origin: left; transition: transform 0.12s; box-shadow: 0 0 10px rgba(127,216,255,0.6); }
#hud-air.low .air-bar i { background: var(--red); box-shadow: 0 0 10px rgba(255,46,46,0.7); animation: blink 0.5s steps(2) infinite; }
@keyframes blink { 50% { opacity: 0.35; } }

/* ---------- callouts ---------- */
#fx { position: absolute; inset: 0; pointer-events: none; overflow: hidden; }
.pop { position: absolute; left: 0; top: 0; white-space: nowrap; font-weight: 900; font-style: italic; letter-spacing: 0.02em; font-size: max(11px, calc(var(--u) * 3.4)); text-shadow: 0 2px 10px rgba(0,0,0,0.7); will-change: transform, opacity; }

#combo { position: absolute; left: 50%; top: 17%; transform: translateX(-50%); text-align: center; pointer-events: none; opacity: 0; transition: opacity 0.15s; }
#combo.show { opacity: 1; }
#combo.kick .c-names { animation: kick 0.25s cubic-bezier(.2,1.5,.4,1); }
#combo .c-names { font-weight: 900; font-style: italic; font-size: max(12px, calc(var(--u) * 4)); letter-spacing: 0.04em; text-shadow: 0 2px 14px rgba(0,0,0,0.6); white-space: nowrap; }
#combo .c-names i { color: var(--ice); font-style: normal; margin: 0 2px; }
#combo .c-x { font-weight: 900; font-style: italic; color: var(--gold); font-size: max(16px, calc(var(--u) * 6.5)); line-height: 1; margin-top: 2px; text-shadow: 0 0 22px rgba(255,211,77,0.5); }
@keyframes kick { 0% { transform: scale(1.3); } 100% { transform: scale(1); } }

#landed { position: absolute; left: 50%; top: 30%; transform: translate(-50%, -50%); text-align: center; pointer-events: none; opacity: 0; white-space: nowrap; }
#landed.show { animation: land 1.3s cubic-bezier(.2,1.2,.3,1) forwards; }
@keyframes land { 0% { opacity: 0; transform: translate(-50%, -50%) scale(0.6); } 12% { opacity: 1; transform: translate(-50%, -50%) scale(1.08); } 22% { transform: translate(-50%, -50%) scale(1); } 80% { opacity: 1; } 100% { opacity: 0; transform: translate(-50%, -70%) scale(0.98); } }
#landed .l-q { font-size: max(9px, calc(var(--u) * 2.6)); letter-spacing: 0.36em; font-weight: 800; color: rgba(255,255,255,0.7); }
#landed.q-perfect .l-q { color: var(--gold); text-shadow: 0 0 16px rgba(255,211,77,0.7); }
#landed.q-sketchy .l-q { color: #ff8a70; }
#landed .l-word { font-size: max(22px, calc(var(--u) * 10)); font-weight: 900; font-style: italic; letter-spacing: -0.01em; line-height: 1.05; background: linear-gradient(180deg, #fff 30%, #c9d6ff); -webkit-background-clip: text; background-clip: text; color: transparent; padding: 0 0.12em; filter: drop-shadow(0 4px 18px rgba(0,0,0,0.55)); }
#landed.q-perfect .l-word { background: linear-gradient(180deg, #fff6d0 10%, #ffc63a 90%); -webkit-background-clip: text; background-clip: text; }
#landed .l-sub { font-size: max(9px, calc(var(--u) * 2.6)); font-weight: 700; letter-spacing: 0.12em; color: rgba(255,255,255,0.7); margin-top: 2px; }
#landed .l-pts { margin-top: calc(var(--u) * 1); font-size: max(13px, calc(var(--u) * 4.4)); font-weight: 800; font-variant-numeric: tabular-nums; }
#landed .l-pts span { font-size: 0.6em; color: var(--ice); letter-spacing: 0.12em; vertical-align: middle; }

#launch { position: absolute; left: 50%; top: 22%; transform: translateX(-50%); pointer-events: none; opacity: 0; font-size: max(11px, calc(var(--u) * 3.2)); letter-spacing: 0.14em; text-transform: uppercase; color: rgba(255,255,255,0.8); white-space: nowrap; }
#launch b { color: #fff; font-size: 1.5em; font-style: italic; letter-spacing: 0; }
#launch.go { animation: launch 1.8s ease forwards; }
@keyframes launch { 0% { opacity: 0; transform: translateX(-50%) translateY(8px); } 15% { opacity: 1; transform: translateX(-50%); } 75% { opacity: 1; } 100% { opacity: 0; } }

#hint { position: absolute; left: 50%; bottom: calc(var(--u) * 6); transform: translateX(-50%); display: flex; gap: calc(var(--u) * 4); pointer-events: none; opacity: 0; transition: opacity 0.4s; font-size: max(10px, calc(var(--u) * 2.8)); color: rgba(255,255,255,0.75); letter-spacing: 0.06em; white-space: nowrap; }
#hint.show { opacity: 1; animation: breathe 1.6s ease-in-out infinite; }
#hint b { color: #fff; }
@keyframes breathe { 50% { opacity: 0.55; } }

/* ---------- controls ---------- */
.icon-btn { pointer-events: auto; background: var(--glass); border: 1px solid var(--line); color: #fff; border-radius: 999px; width: max(30px, calc(var(--u) * 7.5)); height: max(30px, calc(var(--u) * 7.5)); font-size: max(13px, calc(var(--u) * 3.4)); cursor: pointer; display: grid; place-items: center; backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px); }
#mute { position: absolute; top: calc(var(--u) * 3); right: calc(var(--u) * 3); z-index: 30; }
#mute .x { display: none; }
#mute.off .wave { display: none; }
#mute.off .x { display: inline; }

.screen { position: absolute; inset: 0; z-index: 20; display: flex; align-items: center; justify-content: center; }
.shade { position: absolute; inset: 0; background: radial-gradient(ellipse at 30% 40%, rgba(6,8,14,0.55), rgba(2,3,6,0.88)); backdrop-filter: blur(8px); -webkit-backdrop-filter: blur(8px); }
.panel { position: relative; display: flex; flex-direction: column; gap: calc(var(--u) * 2); max-height: 100%; padding: calc(var(--u) * 4.5); animation: rise 0.4s cubic-bezier(.2,1,.3,1); }
@keyframes rise { from { opacity: 0; transform: translateY(14px); } to { opacity: 1; transform: none; } }

.muted { font-size: max(10px, calc(var(--u) * 2.6)); color: rgba(255,255,255,0.55); letter-spacing: 0.04em; }
.row { display: flex; gap: calc(var(--u) * 1.6); flex-wrap: wrap; }
.eyebrow { font-size: max(9px, calc(var(--u) * 2.4)); letter-spacing: 0.3em; text-transform: uppercase; color: var(--red); font-weight: 700; }

.btn { font: inherit; font-weight: 700; letter-spacing: 0.16em; font-size: max(10px, calc(var(--u) * 2.8)); color: #fff; background: rgba(255,255,255,0.06); border: 1px solid rgba(255,255,255,0.2); padding: calc(var(--u) * 2.2) calc(var(--u) * 4.4); border-radius: 999px; cursor: pointer; transition: transform 0.1s, background 0.2s, box-shadow 0.2s; white-space: nowrap; }
.btn:hover { background: rgba(255,255,255,0.12); }
.btn:active { transform: scale(0.96); }
.btn.primary { background: #fff; color: #000; border-color: #fff; }
.btn.primary:hover { box-shadow: 0 0 24px rgba(255,255,255,0.35); }
.btn.wide { flex: 1; }
.btn:disabled { opacity: 0.6; cursor: default; }
.link { background: none; border: 0; color: var(--ice); font: inherit; font-size: max(10px, calc(var(--u) * 2.6)); cursor: pointer; text-align: left; letter-spacing: 0.04em; }
.chip { font: inherit; font-size: max(10px, calc(var(--u) * 2.6)); letter-spacing: 0.14em; text-transform: uppercase; font-weight: 600; color: rgba(255,255,255,0.85); background: var(--glass); border: 1px solid var(--line); padding: calc(var(--u) * 1.6) calc(var(--u) * 3.6); border-radius: 999px; cursor: pointer; backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px); }
.chip:hover { color: #fff; border-color: rgba(255,255,255,0.3); }

/* ---------- title (no wordmark: the car is the hero) ---------- */
#title { align-items: flex-end; background: linear-gradient(180deg, transparent 55%, rgba(0,0,0,0.55)); cursor: pointer; }
.title-bottom { display: flex; flex-direction: column; align-items: center; gap: calc(var(--u) * 2.2); padding-bottom: calc(var(--u) * 6); }
.tap-cta { position: relative; display: flex; align-items: center; gap: calc(var(--u) * 2); font-size: max(12px, calc(var(--u) * 3.6)); font-weight: 600; letter-spacing: 0.32em; text-transform: uppercase; animation: breathe 2s ease-in-out infinite; }
.tap-cta .ring { width: max(10px, calc(var(--u) * 2.6)); height: max(10px, calc(var(--u) * 2.6)); border-radius: 50%; border: 2px solid #fff; position: relative; }
.tap-cta .ring::after { content: ""; position: absolute; inset: -2px; border-radius: 50%; border: 2px solid #fff; animation: ping 1.6s ease-out infinite; }
@keyframes ping { from { transform: scale(1); opacity: 0.8; } to { transform: scale(2.6); opacity: 0; } }

/* ---------- results: real demo footage full-bleed, typography on top ---------- */
#over { align-items: stretch; justify-content: flex-start; background: #000; }
.over-bg { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; filter: saturate(0.9) contrast(1.05); }
.over-shade { position: absolute; inset: 0; background:
  linear-gradient(90deg, rgba(0,0,0,0.92) 0%, rgba(0,0,0,0.78) 34%, rgba(0,0,0,0.25) 62%, rgba(0,0,0,0.1) 100%),
  linear-gradient(0deg, rgba(0,0,0,0.6), rgba(0,0,0,0) 40%); }
.over-main { position: relative; display: flex; flex-direction: column; justify-content: center; gap: calc(var(--u) * 1.6);
  width: min(100%, calc(var(--u) * 92)); padding: calc(var(--u) * 5) calc(var(--u) * 6); animation: rise 0.45s cubic-bezier(.2,1,.3,1); }
.big-score { font-size: calc(var(--u) * 17); font-weight: 800; letter-spacing: -0.035em; line-height: 0.9; font-variant-numeric: tabular-nums; margin-top: calc(var(--u) * 0.6); }
.best-line { font-size: max(10px, calc(var(--u) * 2.5)); letter-spacing: 0.08em; color: rgba(255,255,255,0.55); font-weight: 500; }
.best-line.new { color: var(--gold); font-weight: 700; }
#over-stats { display: grid; grid-template-columns: repeat(6, max-content); justify-content: space-between; gap: calc(var(--u) * 1.6) calc(var(--u) * 2); margin: calc(var(--u) * 2.6) 0 calc(var(--u) * 1.4); }
#over-stats div { display: flex; flex-direction: column; gap: 2px; opacity: 0; animation: rise 0.4s cubic-bezier(.2,1,.3,1) forwards; }
#over-stats b { font-size: max(15px, calc(var(--u) * 4.2)); font-weight: 600; letter-spacing: -0.01em; font-variant-numeric: tabular-nums; line-height: 1; }
#over-stats span { font-size: max(8px, calc(var(--u) * 1.6)); letter-spacing: 0.14em; white-space: nowrap; text-transform: uppercase; color: rgba(255,255,255,0.45); }
#score-form { display: flex; align-items: center; height: max(38px, calc(var(--u) * 8.6)); border-bottom: 1px solid rgba(255,255,255,0.28); transition: border-color 0.2s; }
#score-form:focus-within { border-color: #fff; }
#name { flex: 1; min-width: 0; height: 100%; font: inherit; font-size: max(13px, calc(var(--u) * 3)); color: #fff; background: none; border: 0; padding: 0; outline: none; user-select: text; -webkit-user-select: text; }
#name::placeholder { color: rgba(255,255,255,0.4); }
#submit { font: inherit; font-size: max(10px, calc(var(--u) * 2.3)); font-weight: 700; letter-spacing: 0.16em; text-transform: uppercase; color: #fff; background: none; border: 0; padding: 0 0 0 calc(var(--u) * 2); cursor: pointer; opacity: 0.85; }
#submit:hover { opacity: 1; }
#submit:disabled { opacity: 0.5; cursor: default; }
.cta { margin-top: calc(var(--u) * 2.4); height: max(42px, calc(var(--u) * 10)); font: inherit; font-size: max(11px, calc(var(--u) * 3)); font-weight: 800; letter-spacing: 0.22em; text-transform: uppercase; color: #000; background: #fff; border: 0; border-radius: 999px; cursor: pointer; transition: transform 0.1s, box-shadow 0.2s; }
.cta:hover { box-shadow: 0 0 34px rgba(255,255,255,0.35); }
.cta:active { transform: scale(0.98); }
.text-links { display: flex; justify-content: center; align-items: center; gap: calc(var(--u) * 2); color: rgba(255,255,255,0.35); font-size: max(10px, calc(var(--u) * 2.4)); }
.tlink { font: inherit; background: none; border: 0; color: rgba(255,255,255,0.7); letter-spacing: 0.14em; text-transform: uppercase; font-weight: 600; cursor: pointer; padding: 4px 2px; }
.tlink:hover { color: #fff; }
.over-credit { position: absolute; right: calc(var(--u) * 4); bottom: calc(var(--u) * 4); max-width: 42%; text-align: right; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; color: rgba(255,255,255,0.7); text-decoration: none; font-size: max(9px, calc(var(--u) * 2.2)); letter-spacing: 0.02em; text-shadow: 0 1px 8px rgba(0,0,0,0.6); }
.over-credit i { display: inline-block; font-style: normal; font-weight: 800; letter-spacing: 0.12em; text-transform: uppercase; font-size: 0.85em; background: var(--red); color: #fff; padding: 2px 6px; border-radius: 3px; margin-right: 8px; vertical-align: 1px; }
.over-credit:hover { color: #fff; }

/* ---------- scoreboard + reel ---------- */
.panel.list { width: 100%; max-width: calc(var(--u) * 150); height: 100%; }
.head { display: flex; align-items: center; gap: calc(var(--u) * 2.4); }
.head h2 { font-size: max(16px, calc(var(--u) * 5)); font-weight: 700; letter-spacing: 0.02em; }
#board-list { list-style: none; overflow-y: auto; flex: 1; min-height: 0; display: flex; flex-direction: column; gap: 5px; touch-action: pan-y; }
#board-list li { display: grid; grid-template-columns: 2.4em 1fr auto 5.5em; gap: 10px; align-items: center; padding: calc(var(--u) * 1.6) calc(var(--u) * 2.8); background: rgba(255,255,255,0.04); border: 1px solid rgba(255,255,255,0.06); border-radius: 12px; font-size: max(12px, calc(var(--u) * 3.2)); opacity: 0; animation: rise 0.3s ease forwards; }
#board-list li:nth-child(1) .rk { color: var(--gold); }
#board-list li:nth-child(2) .rk { color: #d6dbe4; }
#board-list li:nth-child(3) .rk { color: #e39b5a; }
#board-list li.me { background: rgba(159,225,255,0.12); border-color: var(--ice); }
#board-list li.empty { display: block; text-align: center; color: rgba(255,255,255,0.6); opacity: 1; animation: none; }
#board-list .rk { font-weight: 800; font-variant-numeric: tabular-nums; }
#board-list .nm { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-weight: 600; }
#board-list .fl { color: rgba(255,255,255,0.45); font-size: 0.82em; }
#board-list .sc { text-align: right; font-weight: 800; font-variant-numeric: tabular-nums; }
.panel.list > .btn { align-self: center; }

#reel-grid { flex: 1; min-height: 0; overflow-y: auto; display: grid; grid-template-columns: repeat(auto-fill, minmax(max(110px, calc(var(--u) * 32)), 1fr)); grid-auto-rows: max-content; align-content: start; gap: 8px; touch-action: pan-y; padding-bottom: 8px; }
.tile { position: relative; border: 0; padding: 0; background: #111; border-radius: 10px; overflow: hidden; cursor: pointer; aspect-ratio: 16 / 10; color: #fff; }
.tile img { width: 100%; height: 100%; object-fit: cover; display: block; transition: transform 0.4s; }
.tile:hover img { transform: scale(1.06); }
.tile .cap { position: absolute; left: 0; right: 0; bottom: 0; padding: 16px 8px 6px; font-size: max(10px, calc(var(--u) * 2.4)); text-align: left; background: linear-gradient(transparent, rgba(0,0,0,0.85)); }
.tile .play { position: absolute; top: 6px; left: 6px; background: var(--red); border-radius: 999px; font-size: 9px; padding: 3px 7px; }

#viewer { position: absolute; inset: 0; z-index: 40; background: rgba(0,0,0,0.95); display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 8px; padding: calc(var(--u) * 4); }
#viewer-body { flex: 1; min-height: 0; width: 100%; display: flex; align-items: center; justify-content: center; }
#viewer-body img, #viewer-body video { max-width: 100%; max-height: 100%; border-radius: 10px; }
#viewer-cap { font-size: max(11px, calc(var(--u) * 2.8)); color: rgba(255,255,255,0.8); text-align: center; }
#viewer-cap a { color: var(--ice); }
#viewer .close { position: absolute; top: calc(var(--u) * 3); left: calc(var(--u) * 3); }

@media (max-aspect-ratio: 1/1) {
  #over-stats { grid-template-columns: repeat(3, max-content); }
  .over-main { width: 100%; justify-content: flex-end; padding-bottom: calc(var(--u) * 8); }
  .over-shade { background: linear-gradient(0deg, rgba(0,0,0,0.95) 0%, rgba(0,0,0,0.8) 55%, rgba(0,0,0,0.2) 100%); }
  .over-credit { top: calc(var(--u) * 4); bottom: auto; left: calc(var(--u) * 4); right: auto; max-width: 70%; text-align: left; }
  .hud-r { margin-right: calc(var(--u) * 12); }
}

/* small X card frames (~280 px tall) */
@media (max-height: 340px) and (min-aspect-ratio: 1/1) {
  .panel { padding: 10px 14px; }
  .over-main { gap: 4px; padding: 10px 18px; width: min(100%, 360px); }
  .big-score { font-size: 42px; }
  #over-stats { grid-template-columns: repeat(6, max-content); gap: 4px 10px; margin: 6px 0 2px; }
  #over-stats b { font-size: 14px; }
  #over-stats span { font-size: 7px; }
  #score-form { height: 30px; }
  #name { font-size: 12px; }
  .cta { height: 32px; margin-top: 6px; font-size: 10px; }
  .eyebrow, .best-line, .tlink, .over-credit { font-size: 8px; }
  .over-credit { max-width: 34%; }
  #board-list li { padding: 5px 10px; font-size: 11px; }
}

/* Keep controls clear of phone cutouts and the home indicator. */
#hud { padding: max(var(--safe-top), calc(var(--u) * 3.2)) max(var(--safe-right), calc(var(--u) * 3.6)) 0 max(var(--safe-left), calc(var(--u) * 3.6)); }
#mute { top: max(var(--safe-top), calc(var(--u) * 3)); right: max(var(--safe-right), calc(var(--u) * 3)); }
.title-bottom { padding-bottom: max(calc(var(--safe-bottom) + 12px), calc(var(--u) * 6)); }
.panel { padding-top: max(var(--safe-top), calc(var(--u) * 4.5)); padding-right: max(var(--safe-right), calc(var(--u) * 4.5)); padding-bottom: max(calc(var(--safe-bottom) + 12px), calc(var(--u) * 4.5)); padding-left: max(var(--safe-left), calc(var(--u) * 4.5)); }
.over-main { padding-top: max(var(--safe-top), calc(var(--u) * 5)); padding-right: max(var(--safe-right), calc(var(--u) * 6)); padding-bottom: max(calc(var(--safe-bottom) + 12px), calc(var(--u) * 5)); padding-left: max(var(--safe-left), calc(var(--u) * 6)); }
@media (max-aspect-ratio: 1/1) { .over-main { padding-bottom: max(calc(var(--safe-bottom) + 12px), calc(var(--u) * 8)); } }
#hint { bottom: max(calc(var(--safe-bottom) + 12px), calc(var(--u) * 6)); }

html[data-render-profile="mobile"] :is(.icon-btn, .chip, .btn, .tlink) { min-width: 44px; min-height: 44px; }
html[data-render-profile="mobile"] :is(#score-form, #submit) { min-height: 44px; }
html[data-render-profile="mobile"] #name { font-size: 16px; }
html[data-render-profile="mobile"] #board-list li { grid-template-columns: 2em minmax(0, 1fr) auto; }
html[data-render-profile="mobile"] #board-list .fl { display: none; }
@media (max-width: 600px) and (max-height: 500px) {
  html[data-render-profile="mobile"] .over-main { width: 100%; justify-content: flex-start; overflow-y: auto; }
  html[data-render-profile="mobile"] .over-main > * { flex-shrink: 0; }
  html[data-render-profile="mobile"] #over-stats { grid-template-columns: repeat(3, max-content); }
}
