/* GuessRank redesign: shared styles. Page-specific files (v2-multiplayer.css, v2-forms.css, v2-text.css) build on these. */

/* ---------- Font: Inter (variable, all weights in one file), served from this site ---------- */
/* The extended file only downloads when a page has characters outside basic Latin (e.g. ş, ğ in a username). */
@font-face {
  font-family: Inter; font-style: normal; font-weight: 100 900; font-display: swap;
  src: url("../fonts/inter-latin-ext.woff2") format("woff2");
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C4, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
@font-face {
  font-family: Inter; font-style: normal; font-weight: 100 900; font-display: swap;
  src: url("../fonts/inter-latin.woff2") format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

/* ---------- Tokens ---------- */
:root {
  --v2-ground: #0a0a0c;
  --v2-card: #161618;
  --v2-raised: #1c1c1e;
  --v2-hover: #1f1f23;
  --v2-fill: #2c2c2e;
  --v2-ad: #111113;
  --v2-line: rgba(255, 255, 255, .08);
  --v2-text: #f5f5f7;
  --v2-nav: #d2d2d7;
  --v2-muted: #a1a1a6;
  --v2-faint: #86868b;
  --v2-accent: #6a5fd0;
  --v2-accent-hover: #5d53bd;
  --v2-lavender: #a99ff0;
  --v2-gold: #efbd50;
  --v2-green: #5fd08f;
  --v2-green-ring: #3cb371;
  --v2-red: #ff8a8a;
  --v2-red-ring: #ff6d6d;
  --v2-ease: cubic-bezier(.22, 1, .36, 1);
  --v2-spring: cubic-bezier(.34, 1.56, .64, 1);
  --v2-font: Inter, system-ui, -apple-system, "Segoe UI", sans-serif;
  --v2-header-h: 73px;
}

/* ---------- Base ---------- */
*, *::before, *::after { box-sizing: border-box; }
html { scrollbar-color: var(--v2-fill) var(--v2-ground); -webkit-text-size-adjust: 100%; }
body.v2 {
  margin: 0;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  background: var(--v2-ground);
  color: var(--v2-text);
  font-family: var(--v2-font);
  font-size: 16px;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
}
.v2 a { color: var(--v2-muted); text-decoration: none; }
.v2 a:hover { color: var(--v2-text); }
.v2 a, .v2 button { cursor: pointer; }
.v2 button { font-family: inherit; }
.v2 button:disabled { cursor: not-allowed; }
.v2 img { -webkit-user-drag: none; }
.v2 button { -webkit-user-select: none; user-select: none; }
/* No double-tap zoom on controls (a quick second tap on a rank or Next clip would zoom the page); pinch zoom stays. */
.v2 a, .v2 button, .v2 input, .v2 select, .v2 textarea, .v2 label, .v2 [role="button"] { touch-action: manipulation; }
.v2 ::selection { background: var(--v2-accent); color: #ffffff; }
.v2 :focus-visible { outline: 2px solid var(--v2-lavender); outline-offset: 3px; }
.v2 h1, .v2 h2, .v2 h3 { margin: 0; font-weight: 600; color: var(--v2-text); }
.v2-sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.v2-main { flex: 1 0 auto; width: 100%; }
.v2-container { width: 100%; max-width: 1360px; margin: 0 auto; padding: 0 32px; }
.v2-narrow { width: 100%; max-width: 720px; margin: 0 auto; padding: 0 32px; }

/* ---------- Buttons ---------- */
.v2-pill {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  min-height: 48px; padding: 0 28px; border: 0; border-radius: 999px;
  background: var(--v2-accent); color: #ffffff !important; font-size: 16px; font-weight: 600; text-decoration: none;
  transition: background-color 150ms var(--v2-ease), transform 120ms var(--v2-ease);
}
.v2-pill:hover { background: var(--v2-accent-hover); }
.v2-pill:active { transform: scale(.97); }
.v2-pill:disabled { opacity: .5; }
.v2-quiet {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  min-height: 44px; padding: 0 20px; border: 0; border-radius: 999px;
  background: var(--v2-raised); box-shadow: inset 0 0 0 1px var(--v2-line);
  color: var(--v2-nav) !important; font-size: 14px; font-weight: 500; text-decoration: none;
  transition: background-color 150ms var(--v2-ease), transform 120ms var(--v2-ease);
}
.v2-quiet:hover { background: var(--v2-fill); color: #ffffff !important; }
.v2-quiet:active { transform: scale(.97); }
.v2-link {
  display: inline-flex; align-items: center; gap: 4px; min-height: 44px;
  color: var(--v2-lavender) !important; font-size: 16px; font-weight: 500; text-decoration: none;
}
.v2-link:hover { color: #c4bcf6 !important; }

/* ---------- Header ---------- */
.v2-header {
  position: sticky; top: 0; z-index: 50;
  background: rgba(10, 10, 12, .72);
  -webkit-backdrop-filter: saturate(180%) blur(20px);
  backdrop-filter: saturate(180%) blur(20px);
  border-bottom: 1px solid var(--v2-line);
}
.v2-header__grid {
  max-width: 1360px; margin: 0 auto; padding: 8px 32px;
  display: grid; grid-template-columns: minmax(0, 1fr) auto minmax(0, 1fr); align-items: center; gap: 40px;
}
.v2-header__side { display: flex; align-items: center; gap: 4px; }
.v2-header__side--left { justify-content: flex-end; }
.v2-header__side--right { justify-content: flex-start; }
.v2-header__logo { display: block; line-height: 0; }
.v2-header__logo img { display: block; width: auto; height: 56px; }
.v2-header__menu, .v2-header__spacer { display: none; }
.v2-header__menu {
  width: 48px; height: 48px; border: 0; border-radius: 12px; background: transparent; color: var(--v2-text);
  align-items: center; justify-content: center; padding: 0;
}
.v2-nav {
  display: inline-flex; align-items: center; gap: 8px; min-height: 44px; padding: 0 12px;
  border: 0; border-radius: 8px; background: transparent;
  color: var(--v2-nav) !important; font-size: 14px; font-weight: 500; text-decoration: none; white-space: nowrap;
  transition: background-color 150ms var(--v2-ease), color 150ms var(--v2-ease);
}
.v2-nav:hover, .v2-nav[aria-expanded="true"] { background: rgba(255, 255, 255, .06); color: #ffffff !important; }
.v2-nav[aria-current="page"] { color: #ffffff !important; }
.v2-nav .v2-chev { transition: transform 200ms var(--v2-ease); }
.v2-nav[aria-expanded="true"] .v2-chev { transform: rotate(180deg); }

.v2-drop { position: relative; }
.v2-drop__panel {
  position: absolute; top: calc(100% + 8px); left: 0; z-index: 60;
  background: var(--v2-raised); border-radius: 24px; box-shadow: 0 20px 48px rgba(0, 0, 0, .5);
  transform-origin: top left; animation: v2-pop 180ms var(--v2-ease) both;
}
.v2-drop__panel[hidden] { display: none; }
.v2-drop__panel--right { left: auto; right: 0; transform-origin: top right; }
.v2-drop__panel--games { width: min(592px, calc(100vw - 32px)); padding: 16px; display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 16px 12px; }
.v2-drop__panel--menu { width: 220px; padding: 8px; border-radius: 16px; display: flex; flex-direction: column; gap: 4px; }
.v2-cover-link { display: flex; flex-direction: column; gap: 8px; color: var(--v2-nav) !important; font-size: 14px; font-weight: 500; line-height: 1.3; }
.v2-cover-link:hover { color: #ffffff !important; }
.v2-cover { display: block; aspect-ratio: 3 / 4; border-radius: 12px; overflow: hidden; background: var(--v2-fill); }
.v2-cover img { display: block; width: 100%; height: 100%; object-fit: cover; object-position: center 25%; transition: filter 150ms var(--v2-ease); }
.v2-cover-link:hover .v2-cover img { filter: brightness(1.12); }
.v2-cover-link[aria-current="page"] .v2-cover { box-shadow: inset 0 0 0 2px var(--v2-lavender); }
.v2-cover-link[aria-current="page"] .v2-cover img { outline: 2px solid var(--v2-lavender); outline-offset: -2px; }
.v2-menu-link {
  display: flex; align-items: center; gap: 12px; min-height: 44px; padding: 0 12px; border-radius: 8px;
  color: var(--v2-nav) !important; font-size: 14px; text-decoration: none;
}
.v2-menu-link svg { color: var(--v2-faint); flex: 0 0 auto; }
.v2-menu-link:hover { background: var(--v2-fill); color: #ffffff !important; }

.v2-sheet {
  position: absolute; left: 0; right: 0; top: 100%;
  padding: 12px 16px 16px; background: var(--v2-raised); border-radius: 0 0 24px 24px; box-shadow: 0 20px 48px rgba(0, 0, 0, .5);
  display: flex; flex-direction: column; gap: 12px; animation: v2-pop 180ms var(--v2-ease) both;
}
.v2-sheet[hidden] { display: none; }
/* Open menu: the page behind is locked, dimmed, and a tap on the dimmed part closes the menu. Long menus scroll inside. */
html.v2-menu-open { overflow: hidden; }
.v2-sheet { max-height: calc(100dvh - var(--v2-header-h)); overflow-y: auto; overscroll-behavior: contain; }
.v2-backdrop { position: fixed; inset: 0; z-index: 40; background: rgba(0, 0, 0, .55); animation: v2-fade 200ms var(--v2-ease) both; touch-action: none; }
.v2-backdrop[hidden] { display: none; }
@media (min-width: 861px) { .v2-backdrop { display: none !important; } }
.v2-sheet__label { font-size: 12px; font-weight: 500; color: var(--v2-faint); }
.v2-sheet__games { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 12px 8px; }
.v2-sheet__games .v2-cover-link { gap: 4px; font-size: 12px; }
.v2-sheet__links { display: flex; flex-direction: column; border-top: 1px solid var(--v2-line); padding-top: 8px; }
.v2-sheet__links .v2-menu-link { font-size: 16px; padding: 0 4px; }

@media (max-width: 860px) {
  :root { --v2-header-h: 61px; }
  .v2-header__grid { grid-template-columns: 48px minmax(0, 1fr) 48px; gap: 0; padding: 8px; }
  .v2-header__side { display: none; }
  .v2-header__menu, .v2-header__spacer { display: flex; }
  .v2-header__logo { justify-self: center; }
  .v2-header__logo img { height: 44px; }
}
@media (min-width: 861px) { .v2-sheet { display: none !important; } }

/* ---------- Footer ---------- */
.v2-footer { margin-top: 80px; border-top: 1px solid var(--v2-line); }
.v2-footer__inner {
  max-width: 1360px; margin: 0 auto; padding: 40px 32px 48px;
  display: flex; align-items: center; justify-content: space-between; gap: 24px; flex-wrap: wrap;
}
.v2-footer__links { display: flex; flex-wrap: wrap; gap: 4px 24px; list-style: none; margin: 0; padding: 0; }
.v2-footer__links a { display: inline-flex; align-items: center; min-height: 44px; font-size: 14px; color: var(--v2-muted); }
.v2-footer__links a:hover { color: var(--v2-text); }
.v2-footer__end { display: flex; align-items: center; gap: 24px; flex-wrap: wrap; }
.v2-footer__badge img { display: block; width: 150px; height: 58px; }
.v2-footer__copy { font-size: 12px; color: var(--v2-faint); }
@media (max-width: 640px) {
  .v2-footer__inner { flex-direction: column; align-items: center; gap: 20px; padding: 32px 16px 40px; text-align: center; }
  .v2-footer__links { justify-content: center; }
  .v2-footer__end { flex-direction: column; gap: 12px; }
}

/* ---------- Ads ---------- */
.v2-ad {
  display: flex; align-items: center; justify-content: center; text-align: center;
  background: var(--v2-ad); border-radius: 16px; color: var(--v2-faint); font-size: 12px; padding: 8px;
}
.v2-ad--leaderboard { width: 728px; max-width: 100%; height: 90px; margin: 0 auto; }
.v2-ad--side { width: 160px; height: 600px; }
.v2-ad--mobile { width: 100%; min-height: 100px; }
.v2-ad--custom { width: 100%; min-height: 250px; }
.v2-slot { margin: 48px auto 0; }
.v2-slot--tight { margin-top: 24px; }
.v2-slot:empty, .v2-slot--tight:not(:has(*)) { display: none; }
.v2-rail { flex: 0 0 160px; position: sticky; top: calc(var(--v2-header-h) + 24px); }
.v2-rail .side { width: 160px; }
.v2 .mobile-only { display: none; }
@media (max-width: 768px) { .v2 .mobile-only { display: block; } }

/* ---------- Cards and headings ---------- */
.v2-card { background: var(--v2-card); border-radius: 24px; }
.v2-eyebrowless { margin: 0; }
.v2-page-title { font-size: 36px; line-height: 1.15; letter-spacing: -0.01em; }
.v2-lead { margin: 0; font-size: 18px; line-height: 1.55; color: var(--v2-muted); }
.v2-section-title { font-size: 24px; }

/* ---------- Home ---------- */
.v2-hero { display: flex; align-items: center; gap: 56px; padding: 64px 0 56px; flex-wrap: wrap; }
.v2-hero__text { flex: 1 1 480px; min-width: 0; display: flex; flex-direction: column; gap: 24px; }
.v2-hero__title { font-size: 60px; line-height: 1.05; letter-spacing: -0.03em; }
.v2-hero__lead { margin: 0; max-width: 520px; font-size: 20px; line-height: 1.5; color: var(--v2-muted); }
/* Home preview card. data-step on .v2-preview: final (static result, also the no-JS state), idle, aim, press, reveal. */
.v2-preview {
  position: relative; flex: 0 1 440px; min-width: 0; padding: 12px; border-radius: 24px; background: var(--v2-card);
  display: flex; flex-direction: column; gap: 12px; color: inherit;
  transition: transform 150ms var(--v2-ease);
}
.v2-preview:has(.v2-preview__link:active) { transform: scale(.98); }
.v2-preview__link { position: absolute; inset: 0; z-index: 3; border-radius: 24px; }
.v2-preview__link:focus-visible { outline: 2px solid var(--v2-lavender); outline-offset: 3px; }
.v2-preview__shot { position: relative; aspect-ratio: 16 / 9; border-radius: 12px; overflow: hidden; background: #000000; }
.v2-preview__video { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; transition: filter 150ms var(--v2-ease); }
.v2-preview:hover .v2-preview__video { filter: brightness(1.08); }
.v2-preview__pause {
  position: absolute; z-index: 4; top: 20px; right: 20px; width: 32px; height: 32px; padding: 0; border: 0; border-radius: 999px;
  display: flex; align-items: center; justify-content: center; background: rgba(10, 10, 12, .6); color: var(--v2-text);
  opacity: 0; transition: opacity 150ms var(--v2-ease), background-color 150ms var(--v2-ease);
}
.v2-preview__pause[hidden] { display: none; }
.v2-preview:hover .v2-preview__pause, .v2-preview__pause:focus-visible, .v2-preview__pause[aria-pressed="true"] { opacity: 1; }
.v2-preview__pause:hover { background: rgba(10, 10, 12, .85); }
.v2-preview__play-icon, .v2-preview__pause[aria-pressed="true"] .v2-preview__pause-icon { display: none; }
.v2-preview__pause[aria-pressed="true"] .v2-preview__play-icon { display: flex; }
.v2-preview__pause-icon { display: flex; }

.v2-preview__ranks { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 8px; }
.v2-preview__ranks span {
  position: relative; overflow: hidden; display: flex; justify-content: center; padding: 8px 0; border-radius: 12px;
  background: var(--v2-hover); box-shadow: inset 0 0 0 2px transparent;
  transition: background-color 240ms var(--v2-ease), box-shadow 240ms var(--v2-ease), opacity 320ms var(--v2-ease), transform 140ms var(--v2-ease);
}
.v2-preview__ranks img { position: relative; z-index: 1; width: 36px; height: 36px; object-fit: contain; }
.v2-preview:is([data-step="final"], [data-step="reveal"]) .v2-preview__ranks span:not([data-role]) { opacity: .4; }
.v2-preview:is([data-step="final"], [data-step="reveal"]) [data-role="answer"] { background: rgba(60, 179, 113, .16); box-shadow: inset 0 0 0 2px var(--v2-green-ring); }
.v2-preview:is([data-step="final"], [data-step="reveal"]) [data-role="pick"] { background: rgba(239, 189, 80, .14); box-shadow: inset 0 0 0 2px var(--v2-gold); }
.v2-preview[data-step="reveal"] [data-role="answer"] { animation: v2-answer 520ms var(--v2-ease); }
.v2-preview[data-step="press"] [data-role="pick"] { box-shadow: inset 0 0 0 2px var(--v2-lavender); transform: scale(.95); }
.v2-preview[data-step="press"] [data-role="pick"]::before {
  content: ""; position: absolute; left: 50%; top: 50%; width: 120px; height: 120px; margin: -60px 0 0 -60px; border-radius: 50%;
  background: radial-gradient(circle, rgba(169, 159, 240, .5) 0%, rgba(169, 159, 240, .2) 35%, rgba(169, 159, 240, 0) 70%);
  animation: v2-light 700ms var(--v2-ease) both;
}

.v2-preview__caption { display: grid; padding: 4px 8px 8px; font-size: 14px; }
.v2-preview__ask, .v2-preview__result { grid-area: 1 / 1; transition: opacity 260ms var(--v2-ease), transform 260ms var(--v2-ease); }
.v2-preview__ask { align-self: center; color: var(--v2-muted); }
.v2-preview__result { display: flex; align-items: baseline; justify-content: space-between; gap: 12px; }
.v2-preview__result b { font-weight: 600; color: var(--v2-gold); white-space: nowrap; }
.v2-preview__result span { color: var(--v2-muted); }
.v2-preview:is([data-step="final"], [data-step="reveal"]) .v2-preview__ask { opacity: 0; transform: translateY(-6px); }
.v2-preview:not([data-step="final"]):not([data-step="reveal"]) .v2-preview__result { opacity: 0; transform: translateY(6px); }

/* The demo cursor: JS sets --v2-cursor-x/y to the Platinum tile; it glides there, presses, then fades. */
.v2-preview__cursor {
  position: absolute; z-index: 2; left: 0; top: 0; pointer-events: none; opacity: 0;
  transform: translate(var(--v2-cursor-from-x, 70%), var(--v2-cursor-from-y, 40%));
  filter: drop-shadow(0 2px 4px rgba(0, 0, 0, .5));
  transition: transform 900ms var(--v2-ease), opacity 200ms var(--v2-ease);
}
.v2-preview__cursor svg { display: block; transition: transform 140ms var(--v2-ease); }
.v2-preview:is([data-step="aim"], [data-step="press"], [data-step="reveal"]) .v2-preview__cursor { transform: translate(var(--v2-cursor-x, 60%), var(--v2-cursor-y, 70%)); }
.v2-preview:is([data-step="aim"], [data-step="press"]) .v2-preview__cursor { opacity: 1; }
.v2-preview[data-step="press"] .v2-preview__cursor svg { transform: scale(.85); }
/* Back to the start position only while invisible, so the cursor never slides backwards on screen. */
.v2-preview:is([data-step="idle"], [data-step="final"]) .v2-preview__cursor { transition: opacity 200ms var(--v2-ease); }
.v2-games-title { margin-bottom: 24px; font-size: 24px; }
.v2-game-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 32px 24px; }
.v2-game-card { display: flex; flex-direction: column; gap: 12px; color: var(--v2-nav) !important; font-size: 16px; font-weight: 500; animation: v2-rise 420ms var(--v2-ease) both; }
.v2-game-card:hover { color: #ffffff !important; }
.v2-game-card .v2-cover { border-radius: 16px; transition: transform 120ms var(--v2-ease); }
.v2-game-card:active .v2-cover { transform: scale(.98); }
.v2-game-card:hover .v2-cover img { filter: brightness(1.1); }
@media (max-width: 1100px) { .v2-game-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
@media (max-width: 860px) {
  .v2-container, .v2-narrow { padding: 0 16px; }
  .v2-hero { padding: 32px 0; gap: 32px; }
  .v2-hero__title { font-size: 36px; line-height: 1.1; letter-spacing: -0.02em; }
  .v2-hero__lead { font-size: 16px; }
  .v2-preview { display: none; }
  .v2-game-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 24px 16px; }
  .v2-game-card { font-size: 14px; }
}

/* ---------- Game page ---------- */
.v2-game { display: flex; gap: 32px; align-items: flex-start; justify-content: center; padding-top: 32px; }
.v2-game__main { flex: 999 1 560px; min-width: 0; max-width: 860px; }
@media (max-width: 1279px) { .v2-game .v2-rail { display: none; } }
.v2-game__top { display: flex; align-items: flex-end; justify-content: space-between; gap: 16px; margin-bottom: 16px; flex-wrap: wrap; }
.v2-switcher-btn {
  display: inline-flex; align-items: center; gap: 12px; min-height: 48px; padding: 0 20px;
  border: 0; border-radius: 12px; background: var(--v2-card); color: var(--v2-text);
  font-size: 18px; font-weight: 600; transition: background-color 150ms var(--v2-ease);
}
.v2-switcher-btn:hover, .v2-switcher-btn[aria-expanded="true"] { background: var(--v2-hover); }
.v2-switcher-btn:has(.v2-switcher-btn__thumb) { min-height: 56px; padding: 4px 16px 4px 4px; }
.v2-switcher-btn__thumb { display: block; width: 48px; height: 48px; border-radius: 8px; object-fit: cover; }
.v2-switcher-btn svg { color: var(--v2-faint); transition: transform 200ms var(--v2-ease); }
.v2-switcher-btn[aria-expanded="true"] svg { transform: rotate(180deg); }
.v2-score { display: flex; align-items: flex-end; gap: 24px; }
.v2-score__clip { display: flex; flex-direction: column; align-items: flex-end; gap: 8px; }
.v2-score__clip-label { font-size: 14px; color: var(--v2-muted); font-variant-numeric: tabular-nums; }
.v2-segs { display: flex; gap: 6px; }
.v2-seg { display: block; width: 28px; height: 6px; border-radius: 3px; background: var(--v2-fill); transition: background-color 300ms var(--v2-ease); }
.v2-seg.is-current { background: var(--v2-faint); }
.v2-seg.is-exact { background: var(--v2-green); }
.v2-seg.is-close { background: var(--v2-gold); }
.v2-seg.is-miss { background: var(--v2-red); }
.v2-seg.is-new { animation: v2-seg 420ms var(--v2-ease); }
.v2-score__value { display: flex; flex-direction: column; align-items: flex-end; gap: 2px; position: relative; }
.v2-score__label { font-size: 12px; color: var(--v2-faint); }
.v2-odo { display: inline-flex; height: 1em; overflow: hidden; font-size: 36px; font-weight: 600; line-height: 1em; letter-spacing: -0.02em; color: var(--v2-gold); font-variant-numeric: tabular-nums; }
.v2-odo__col { display: block; overflow: hidden; width: .62em; transition: width 520ms var(--v2-ease), opacity 360ms var(--v2-ease); }
.v2-odo__col.is-hidden { width: 0; opacity: 0; }
.v2-odo__reel { display: flex; flex-direction: column; transition: transform 760ms var(--v2-ease), filter 260ms linear; }
.v2-odo__reel.is-rolling { filter: blur(1.4px); }
.v2-odo__reel span { display: block; height: 1em; }
.v2-odo__max { font-size: 16px; color: var(--v2-muted); align-self: flex-end; margin-left: 4px; line-height: 28px; }
.v2-float { position: absolute; right: 100%; top: 8px; margin-right: 8px; font-size: 18px; font-weight: 600; color: var(--v2-gold); white-space: nowrap; pointer-events: none; opacity: 0; }
.v2-float.is-a { animation: v2-float-a 1000ms var(--v2-ease) both; }
.v2-float.is-b { animation: v2-float-b 1000ms var(--v2-ease) both; }
.v2-float.is-zero { color: var(--v2-faint); }

.v2-clip { position: relative; aspect-ratio: 16 / 9; }
.v2-clip__glow { position: absolute; overflow: hidden; opacity: 0; pointer-events: none; transition: opacity 480ms var(--v2-ease); }
.v2-clip.is-loading .v2-clip__glow { opacity: 1; }
.v2-clip__glow--soft { inset: -6px; border-radius: 22px; filter: blur(20px); }
.v2-clip__glow--edge { inset: -2px; border-radius: 18px; }
.v2-clip__breathe { position: absolute; inset: 0; }
.v2-clip.is-loading .v2-clip__breathe { animation: v2-breathe 1.3s ease-in-out infinite alternate; }
.v2-clip__spin {
  position: absolute; left: 50%; top: 50%; width: 1200px; height: 1200px; margin: -600px 0 0 -600px;
  /* Logo purple to logo gold through violet, pink and amber; mixed in OKLCH so no muddy in-between tones (sRGB fallback first). */
  background: conic-gradient(from 0deg, #6a5fd0, #b06ef2, #ec6fc1, #f5a049, #efbd50, #b06ef2, #6a5fd0);
  background: conic-gradient(from 0deg in oklch, #6a5fd0, #b06ef2, #ec6fc1, #f5a049, #efbd50, #b06ef2, #6a5fd0);
  animation: v2-spin 2.4s linear infinite; animation-play-state: paused;
}
.v2-clip.is-loading .v2-clip__spin { animation-play-state: running; }
.v2-clip #video, .v2-clip .v2-clip__frame {
  position: absolute; inset: 0; border-radius: 16px; overflow: hidden; background: #000000;
}
.v2-clip #video iframe { position: absolute; inset: 0; width: 100% !important; height: 100% !important; border: 0; transition: opacity 360ms var(--v2-ease); }
.v2-clip.is-loading #video iframe { opacity: .35; }
.v2-clip #video > div:not(.report) { position: absolute; inset: 0; display: flex; align-items: center; justify-content: center; color: var(--v2-muted) !important; font-size: 16px; }
/* The live script puts a report text and a sound image inside the video, under YouTube's own controls. They are hidden; .v2-tools has buttons that call the same functions. */
.v2-clip #report-video, .v2-clip #soundButton { display: none !important; }
.v2-game__controls { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.v2-tools { display: flex; align-items: center; gap: 8px; }
.v2-tool {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px; width: 44px; height: 44px; padding: 0;
  border: 0; border-radius: 999px; background: var(--v2-card); color: var(--v2-nav); font-size: 14px; font-weight: 500;
  transition: background-color 150ms var(--v2-ease), color 150ms var(--v2-ease), transform 120ms var(--v2-ease);
}
.v2-tool:hover { background: var(--v2-hover); color: #ffffff; }
.v2-tool:active { transform: scale(.95); }
.v2-tool--text { width: auto; padding: 0 16px 0 14px; }
.v2-tool--text svg { color: var(--v2-faint); }
.v2-tool.is-done { color: var(--v2-muted); cursor: default; }
.v2-tool.is-done:hover { background: var(--v2-card); }
.v2-tool.is-done:active { transform: none; }
.v2-tool__on, .v2-tool__off { display: inline-flex; }
.v2-tool__off { color: var(--v2-red); }
.v2-tool[aria-pressed="true"] .v2-tool__on, .v2-tool:not([aria-pressed="true"]) .v2-tool__off { display: none; }

.v2-question { min-height: 48px; margin: 24px 0 16px; display: flex; align-items: center; }
.v2-question__ask { flex: 1 1 auto; display: flex; align-items: baseline; justify-content: space-between; gap: 12px; flex-wrap: wrap; }
.v2-question__ask h2 { font-size: 20px; }
.v2-question__ask span { font-size: 14px; color: var(--v2-muted); }
.v2-question__ask b { font-weight: 600; color: var(--v2-gold); }
.v2-question__result { display: none; flex: 1 1 auto; align-items: center; justify-content: space-between; gap: 16px; flex-wrap: wrap; }
.v2-question.is-result .v2-question__ask, .v2-question.is-pending .v2-question__ask { display: none; }
.v2-question.is-result .v2-question__result, .v2-question.is-pending .v2-question__result { display: flex; animation: v2-rise 300ms var(--v2-ease) both; }
.v2-verdict__text { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.v2-verdict__side { display: flex; align-items: center; gap: 16px; }
/* Next clip: arrives once the tiles have mostly filled, then one light sweep crosses it. Scale is animated on its
   own property so the press effect (transform) keeps working afterwards. */
.v2-next { position: relative; overflow: hidden; isolation: isolate; animation: v2-next-in 460ms 450ms cubic-bezier(.34, 1.56, .64, 1) backwards; }
.v2-next::after {
  content: ""; position: absolute; inset: 0; z-index: -1; border-radius: inherit; pointer-events: none; transform: translateX(-120%);
  background: linear-gradient(105deg, transparent 25%, rgba(255, 255, 255, .42) 50%, transparent 75%);
  animation: v2-shine 900ms 950ms cubic-bezier(.45, 0, .25, 1) forwards;
}
.v2-next:disabled::after { display: none; }
.v2-next__key { display: none; }
/* The Enter hint only where there is a keyboard and a mouse. */
@media (hover: hover) and (pointer: fine) {
  .v2-next { padding: 0 12px 0 24px; }
  .v2-next__key { display: inline-flex; align-items: center; height: 24px; padding: 0 7px; border-radius: 7px; background: rgba(255, 255, 255, .18); color: rgba(255, 255, 255, .92); font-family: inherit; font-size: 12px; font-weight: 600; line-height: 1; }
}
@media (prefers-reduced-motion: reduce) {
  .v2-next { animation: none !important; }
  .v2-next::after { display: none; }
}
.v2-verdict__total { font-size: 12px; color: var(--v2-faint); white-space: nowrap; }
.v2-verdict__pending { display: flex; align-items: center; gap: 12px; font-size: 14px; color: var(--v2-muted); }

/* Rank tiles. The live script toggles #ranks display; the grid is kept visible so the result can be shown on the tiles. */
.v2 #ranks.v2-ranks { display: grid !important; grid-template-columns: repeat(var(--v2-rank-count, 9), minmax(0, 1fr)); gap: 8px; }
body.v2-is-final #ranks.v2-ranks, body.v2-is-final .v2-question { display: none !important; }
.v2-rank {
  position: relative; z-index: 1; overflow: hidden; display: flex; flex-direction: column; align-items: center; gap: 8px;
  min-height: 44px; padding: 16px 4px 12px; border: 0; border-radius: 16px;
  background: var(--v2-card); box-shadow: inset 0 0 0 2px transparent;
  color: var(--v2-muted); font-size: 12px; font-weight: 500; line-height: 1.3; text-align: center;
  transition: background-color 240ms var(--v2-ease), box-shadow 240ms var(--v2-ease), opacity 320ms var(--v2-ease), transform 140ms var(--v2-ease);
}
.v2-rank img { position: relative; z-index: 1; width: 56px; height: 56px; object-fit: contain; }
.v2-rank__label { position: relative; z-index: 1; max-width: 100%; overflow-wrap: break-word; hyphens: auto; }
.v2-rank:hover { background: var(--v2-hover); }
.v2-rank:active { transform: scale(.95); }
body.gr-result-locked .v2-rank { cursor: default; }
body.gr-result-locked .v2-rank:hover { background: var(--v2-card); }
body.gr-result-locked .v2-rank:active { transform: none; }
.v2-rank.is-picked { box-shadow: inset 0 0 0 2px var(--v2-lavender); }
.v2-rank.is-answer { background: rgba(60, 179, 113, .16) !important; box-shadow: inset 0 0 0 2px var(--v2-green-ring); animation: v2-answer 520ms var(--v2-ease); }
.v2-rank.is-close { background: rgba(239, 189, 80, .14) !important; box-shadow: inset 0 0 0 2px var(--v2-gold); }
.v2-rank.is-miss { background: rgba(255, 109, 109, .12) !important; box-shadow: inset 0 0 0 2px var(--v2-red-ring); animation: v2-shake 440ms cubic-bezier(.36, .07, .19, .97); }
.v2-rank.is-dim { opacity: .7; }
.v2-rank__fill { position: absolute; z-index: 0; left: 0; right: 0; bottom: 0; background: rgba(255, 255, 255, .12); transform-origin: bottom center; animation: v2-grow 620ms var(--v2-ease) both; pointer-events: none; }
.v2-rank.is-answer .v2-rank__fill { background: rgba(60, 179, 113, .3); }
.v2-rank.is-close .v2-rank__fill { background: rgba(239, 189, 80, .26); }
.v2-rank.is-miss .v2-rank__fill { background: rgba(255, 109, 109, .22); }
.v2-rank__pct { position: relative; z-index: 1; font-size: 14px; font-weight: 600; color: var(--v2-text); font-variant-numeric: tabular-nums; animation: v2-rise 300ms 200ms var(--v2-ease) both; }
.v2-rank-wrap { position: relative; min-width: 0; }
.v2-rank-wrap > .v2-rank { width: 100%; }
.v2-aura {
  position: absolute; z-index: 0; left: 50%; top: 50%; width: 280px; height: 280px; margin: -140px 0 0 -140px;
  border-radius: 50%; pointer-events: none; opacity: 0; animation: v2-aura 1200ms var(--v2-ease);
}
.v2-aura.is-exact { width: 200px; height: 200px; margin: -100px 0 0 -100px; background: radial-gradient(circle, rgba(95, 208, 143, .35) 0%, rgba(10, 10, 12, 0) 68%); }
.v2-aura.is-close { width: 150px; height: 150px; margin: -75px 0 0 -75px; background: radial-gradient(circle, rgba(239, 189, 80, .3) 0%, rgba(10, 10, 12, 0) 68%); }
@media (max-width: 860px) {
  .v2-game { padding-top: 16px; }
  .v2 #ranks.v2-ranks { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .v2-score { gap: 16px; }
  .v2-seg { width: 16px; height: 4px; }
  .v2-question { margin-top: 20px; }
  .v2-drop__panel--games { padding: 12px; gap: 12px 8px; }
  .v2-drop__panel--games .v2-cover-link { gap: 4px; font-size: 12px; }
}

/* Phones: the game switcher gets its own row (long names never cut); sound, report and the score share the row below. */
@media (max-width: 640px) {
  .v2-game__top { display: grid; grid-template-columns: auto minmax(0, 1fr); align-items: center; gap: 12px 8px; }
  .v2-game__controls { display: contents; }
  .v2-game__controls > .v2-drop { grid-column: 1 / -1; min-width: 0; }
  .v2-tools { grid-column: 1; gap: 6px; }
  .v2-switcher-btn { max-width: 100%; font-size: 16px; gap: 8px; }
  .v2-switcher-btn:has(.v2-switcher-btn__thumb) { min-height: 48px; padding: 4px 12px 4px 4px; }
  .v2-switcher-btn__thumb { width: 40px; height: 40px; }
  .v2-switcher-btn__name { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
  .v2-tool--text { width: 44px; padding: 0; }
  .v2-tool--text span { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
  .v2-tool--text svg { color: var(--v2-nav); }
  .v2-tool--text.is-done svg { color: var(--v2-green); }
  .v2-score { grid-column: 2; justify-self: end; flex-direction: column-reverse; align-items: flex-end; gap: 6px; }
  .v2-score__label, .v2-score__clip-label { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
  .v2-odo { font-size: 30px; }
  .v2-segs { gap: 4px; }
  .v2-seg { width: 12px; }
  .v2-odo__max { font-size: 14px; line-height: 22px; }
}

/* Tap light (any element with .v2-tap) */
.v2-tap { position: relative; overflow: hidden; }
.v2-tap > .v2-light, .v2-light {
  position: absolute; z-index: 0; width: 180px; height: 180px; margin: -90px 0 0 -90px; border-radius: 50%;
  pointer-events: none; opacity: 0;
  background: radial-gradient(circle, rgba(169, 159, 240, .5) 0%, rgba(169, 159, 240, .2) 35%, rgba(169, 159, 240, 0) 70%);
  animation: v2-light 700ms var(--v2-ease);
}

/* Result card */
.v2-result { margin-top: 16px; }
.v2-result:empty { display: none; }
.v2-result__card { display: flex; flex-direction: column; gap: 20px; padding: 20px 20px 20px 24px; border-radius: 24px; background: var(--v2-card); animation: v2-rise 360ms var(--v2-ease) both; }
.v2-result__head { display: flex; align-items: center; justify-content: space-between; gap: 16px; flex-wrap: wrap; }
.v2-result__title { display: block; font-size: 18px; font-weight: 600; }
.v2-result__title.is-exact { color: var(--v2-green); }
.v2-result__title.is-close { color: var(--v2-gold); }
.v2-result__title.is-miss { color: var(--v2-red); }
.v2-result__meta { font-size: 14px; color: var(--v2-muted); }
.v2-result__meta b { font-weight: 600; color: var(--v2-text); }
.v2-result__pending { display: flex; align-items: center; gap: 12px; padding: 20px 24px; border-radius: 24px; background: var(--v2-card); color: var(--v2-muted); font-size: 14px; animation: v2-rise 240ms var(--v2-ease) both; }
.v2-spinner { width: 18px; height: 18px; border-radius: 50%; border: 2px solid rgba(255, 255, 255, .2); border-top-color: var(--v2-lavender); animation: v2-spin 800ms linear infinite; }
.v2-dist { display: flex; flex-direction: column; gap: 12px; padding-top: 16px; border-top: 1px solid var(--v2-line); }
.v2-dist__head { display: flex; align-items: baseline; justify-content: space-between; gap: 12px; font-size: 14px; color: var(--v2-muted); }
.v2-dist__head span:last-child { font-size: 12px; color: var(--v2-faint); }
.v2-dist__chart { display: grid; grid-template-columns: repeat(var(--v2-rank-count, 9), minmax(0, 1fr)); gap: 8px; align-items: end; }
.v2-dist__item { display: flex; flex-direction: column; align-items: center; gap: 6px; }
.v2-dist__pct { font-size: 12px; color: var(--v2-faint); font-variant-numeric: tabular-nums; }
.v2-dist__track { position: relative; width: 100%; height: 72px; display: flex; align-items: flex-end; }
.v2-dist__bar { width: 100%; border-radius: 6px 6px 2px 2px; background: var(--v2-fill); transform-origin: bottom center; animation: v2-grow 520ms var(--v2-ease) both; }
.v2-dist__bar.is-actual { background: var(--v2-green-ring); }
.v2-dist__bar.is-guess { background: var(--v2-gold); }
.v2-dist__item img { width: 24px; height: 24px; object-fit: contain; }

/* Final score */
.v2-final { display: flex; flex-direction: column; align-items: center; gap: 20px; padding: 40px 32px; border-radius: 24px; background: var(--v2-card); text-align: center; animation: v2-rise 360ms var(--v2-ease) both; }
.v2-final h2 { font-size: 20px; color: var(--v2-muted); }
.v2-ring { position: relative; width: 168px; height: 168px; }
.v2-ring svg { display: block; }
.v2-ring__arc { transition: stroke-dashoffset 1200ms var(--v2-ease); }
.v2-ring__value { position: absolute; inset: 0; display: flex; align-items: baseline; justify-content: center; gap: 4px; padding-top: 56px; }
.v2-ring__value b { font-size: 48px; font-weight: 600; line-height: 1; letter-spacing: -0.02em; color: var(--v2-gold); font-variant-numeric: tabular-nums; }
.v2-ring__value span { font-size: 18px; color: var(--v2-muted); }
.v2-final__msg { margin: 0; max-width: 480px; font-size: 18px; line-height: 1.5; color: var(--v2-text); animation: v2-rise 420ms 1150ms var(--v2-ease) both; }
.v2-final__chips { display: flex; gap: 8px; flex-wrap: wrap; justify-content: center; }
.v2-chip { display: inline-flex; flex-direction: column; align-items: center; gap: 4px; min-width: 72px; padding: 12px 8px; border-radius: 16px; background: var(--v2-hover); animation: v2-chip 420ms var(--v2-spring) both; }
.v2-chip span:first-child { font-size: 12px; color: var(--v2-faint); }
.v2-chip span:last-child { font-size: 18px; font-weight: 600; font-variant-numeric: tabular-nums; }
.v2-chip.is-exact span:last-child { color: var(--v2-green); }
.v2-chip.is-close span:last-child { color: var(--v2-gold); }
.v2-chip.is-miss span:last-child { color: var(--v2-red); }
.v2-final__actions { display: flex; align-items: center; justify-content: center; gap: 24px; flex-wrap: wrap; margin-top: 8px; }

/* Island notice */
.v2-island {
  position: fixed; z-index: 80; left: 50%; top: calc(var(--v2-header-h) + 12px); height: 44px; width: 44px;
  border-radius: 999px; background: var(--v2-raised); box-shadow: 0 12px 32px rgba(0, 0, 0, .5), inset 0 0 0 1px var(--v2-line);
  overflow: hidden; opacity: 0; transform: translateX(-50%) scale(.6); pointer-events: none;
  transition: width 560ms cubic-bezier(.34, 1.32, .64, 1), transform 560ms cubic-bezier(.34, 1.32, .64, 1), opacity 220ms var(--v2-ease);
}
.v2-island.is-open { opacity: 1; transform: translateX(-50%) scale(1); }
.v2-island__in { display: flex; align-items: center; gap: 10px; height: 100%; padding: 0 18px 0 10px; opacity: 0; white-space: nowrap; transition: opacity 140ms var(--v2-ease); }
.v2-island.is-open .v2-island__in { opacity: 1; transition: opacity 260ms 180ms var(--v2-ease); }
.v2-island__icon { flex: 0 0 auto; width: 26px; height: 26px; border-radius: 999px; display: flex; align-items: center; justify-content: center; }
.v2-island__icon.is-ok { background: rgba(95, 208, 143, .16); color: var(--v2-green); }
.v2-island__icon.is-off { background: rgba(255, 138, 138, .16); color: var(--v2-red); }
.v2-island__icon.is-on { background: rgba(255, 255, 255, .08); color: var(--v2-text); }
.v2-island__text { font-size: 14px; font-weight: 500; color: var(--v2-text); }

/* Send button morph (forms) */
.v2-send { position: relative; overflow: hidden; width: var(--v2-send-w, 160px); transition: width 440ms var(--v2-ease), background-color 300ms var(--v2-ease), transform 120ms var(--v2-ease); }
.v2-send.is-busy, .v2-send.is-done { width: 48px; padding: 0; cursor: default; }
.v2-send.is-busy:hover { background: var(--v2-accent); }
.v2-send.is-done, .v2-send.is-done:hover { background: rgba(95, 208, 143, .16); }
.v2-send__label { white-space: nowrap; transition: opacity 160ms var(--v2-ease); }
.v2-send.is-busy .v2-send__label, .v2-send.is-done .v2-send__label { opacity: 0; }
.v2-send__spinner { position: absolute; left: 50%; top: 50%; width: 20px; height: 20px; margin: -10px 0 0 -10px; border-radius: 50%; border: 2px solid rgba(255, 255, 255, .3); border-top-color: #ffffff; opacity: 0; transition: opacity 200ms var(--v2-ease); animation: v2-spin 800ms linear infinite; animation-play-state: paused; }
.v2-send.is-busy .v2-send__spinner { opacity: 1; transition-delay: 200ms; animation-play-state: running; }
.v2-send__check { position: absolute; inset: 0; display: flex; align-items: center; justify-content: center; opacity: 0; transform: scale(.6); color: var(--v2-green); transition: opacity 200ms var(--v2-ease), transform 460ms var(--v2-spring); }
.v2-send__check path { stroke-dasharray: 24; stroke-dashoffset: 24; transition: stroke-dashoffset 380ms 160ms var(--v2-ease); }
.v2-send.is-done .v2-send__check { opacity: 1; transform: none; }
.v2-send.is-done .v2-send__check path { stroke-dashoffset: 0; }
.v2-shake { animation: v2-shake 440ms cubic-bezier(.36, .07, .19, .97); }

/* Utility animations */
.v2-rise { animation: v2-rise 360ms var(--v2-ease) both; }

/* ---------- Keyframes ---------- */
@keyframes v2-fade { from { opacity: 0; } to { opacity: 1; } }
@keyframes v2-pop { from { opacity: 0; transform: translateY(-6px); } to { opacity: 1; transform: none; } }
@keyframes v2-rise { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: none; } }
@keyframes v2-light { 0% { opacity: 1; transform: scale(.15); } 100% { opacity: 0; transform: scale(1.5); } }
@keyframes v2-answer { 0% { transform: scale(1); } 35% { transform: scale(1.06); } 65% { transform: scale(.99); } 100% { transform: scale(1); } }
@keyframes v2-shake { 0%, 100% { transform: translateX(0); } 18% { transform: translateX(-6px); } 36% { transform: translateX(5px); } 54% { transform: translateX(-4px); } 72% { transform: translateX(2px); } 88% { transform: translateX(-1px); } }
@keyframes v2-aura { 0% { opacity: 0; transform: scale(.5); } 25% { opacity: 1; } 100% { opacity: 0; transform: scale(1.3); } }
@keyframes v2-grow { from { transform: scaleY(0); } to { transform: scaleY(1); } }
@keyframes v2-seg { 0% { transform: scaleY(1); } 40% { transform: scaleY(2); } 100% { transform: scaleY(1); } }
@keyframes v2-float-a { 0% { opacity: 0; transform: translateY(6px) scale(.9); } 20% { opacity: 1; transform: translateY(0) scale(1); } 100% { opacity: 0; transform: translateY(-22px); } }
@keyframes v2-float-b { 0% { opacity: 0; transform: translateY(6px) scale(.9); } 20% { opacity: 1; transform: translateY(0) scale(1); } 100% { opacity: 0; transform: translateY(-22px); } }
@keyframes v2-spin { to { transform: rotate(360deg); } }
@keyframes v2-breathe { from { opacity: .55; } to { opacity: 1; } }
@keyframes v2-next-in { from { opacity: 0; scale: .86; } to { opacity: 1; scale: 1; } }
@keyframes v2-shine { from { transform: translateX(-120%); } to { transform: translateX(120%); } }
@keyframes v2-chip { from { opacity: 0; transform: scale(.6); } to { opacity: 1; transform: none; } }

@media (prefers-reduced-motion: reduce) {
  .v2 *, .v2 *::before, .v2 *::after { animation-duration: .001ms !important; animation-iteration-count: 1 !important; transition-duration: .001ms !important; transition-delay: 0ms !important; }
  .v2-light, .v2-aura { display: none; }
  .v2-clip__spin { animation: none !important; }
}
