/* 84-0 · 1v1 Head-to-Head UI — self-contained; injected by h2h.js */
/* title-screen entry button (lives on each game's menu) */
.h2h-entry { display: block; width: 100%; max-width: 460px; text-align: center; cursor: pointer; border: none; border-radius: 14px;
  padding: 15px 13px; margin: 12px auto; background: linear-gradient(135deg, #2a4bb5, #16224f); color: #fff;
  font-family: "Oswald", sans-serif; box-shadow: 0 12px 30px rgba(42,75,181,.4); transition: transform 0.12s, box-shadow 0.12s, filter 0.12s; }
/* full-width inside the menu grid (hockey); standalone above the grid elsewhere (nba/nfl/mlb) */
.mode-grid .h2h-entry { grid-column: 1 / -1; max-width: none; margin: 0; }
.h2h-entry .h2h-entry-main { font-weight: 700; font-size: 18px; display: flex; align-items: center; justify-content: center; gap: 9px; letter-spacing: .3px; }
.h2h-entry .h2h-entry-sub { font-size: 12.5px; opacity: .85; display: block; margin-top: 2px; font-family: "Inter", sans-serif; }
.h2h-entry:hover { transform: translateY(-2px); box-shadow: 0 16px 38px rgba(42,75,181,.5); filter: brightness(1.05); }
.h2h-entry:active { transform: translateY(0); }
/* green "LIVE" badge on the 1v1 entry button (matches the homepage banner) */
.h2h-entry-live { display: inline-flex; align-items: center; gap: 5px; flex: none; font-family: "Oswald", sans-serif;
  font-weight: 600; font-size: 11px; letter-spacing: 1px; color: #5fe39a; background: rgba(46,210,120,.18); border: 1px solid rgba(46,210,120,.5);
  padding: 2px 8px; border-radius: 999px; }
.h2h-entry-live .dot { width: 6px; height: 6px; border-radius: 50%; background: #3fd07a; animation: h2hlivepulse 1.6s ease-in-out infinite; }
@keyframes h2hlivepulse { 0%, 100% { opacity: 1; } 50% { opacity: .3; } }
/* 1v1 rule, shown directly under the 1v1 button */
.h2h-entry-rule { max-width: 460px; margin: -4px auto 14px; padding: 11px 14px; font-size: 12.5px; line-height: 1.55;
  text-align: left; color: var(--text-dim, #b9cbdd); background: var(--surface, rgba(255,255,255,.05));
  border: 1px solid var(--line, rgba(255,255,255,.1)); border-radius: 10px; }
.h2h-entry-rule strong { color: var(--gold, #e0a93a); }
.mode-grid .h2h-entry-rule { grid-column: 1 / -1; max-width: none; }

/* Dedicated 1v1 route pages (/h2h/*): land on a clean 1v1-only screen — hide the season
   modes (Free Play / Hard Mode), the Daily Gauntlet, the long 1v1 rule (the page desc
   covers it), the general rules, and the season-leaderboard link. */
body.h2h-only #screen-title .gauntlet-btn,
body.h2h-only #screen-title .mode-card,
body.h2h-only #screen-title .h2h-entry-rule,
body.h2h-only #screen-title .rules,
body.h2h-only #screen-title .text-link-btn { display: none !important; }
body.h2h-only #screen-title .title-card > img { width: 134px; height: 134px; border-radius: 20px; }
body.h2h-only #screen-title .tagline { max-width: 540px; }

/* ---- 1v1 landing extras: 300×250 ad · OG-game cross-promo · embedded Elo ladder ---- */
.h2h-adslot { display: flex; flex-direction: column; align-items: center; gap: 6px; margin: 24px auto 0; }
.h2h-adslot-label { font-family: "Oswald", sans-serif; font-size: 10px; letter-spacing: 1.5px; text-transform: uppercase; color: var(--text-faint, #7f93a6); }
.h2h-mrec { width: 300px; height: 250px; max-width: 100%; background: var(--surface, rgba(255,255,255,.05)); border: 1px dashed var(--line, rgba(255,255,255,.14)); border-radius: 10px; }
.h2h-og-card { display: flex; align-items: center; gap: 14px; max-width: 540px; margin: 24px auto 0; padding: 14px 16px; text-decoration: none;
  color: inherit; background: var(--surface, rgba(255,255,255,.05)); border: 1px solid var(--line, rgba(255,255,255,.12));
  border-left: 4px solid var(--gold, #e0a93a); border-radius: 12px; transition: transform .12s, border-color .12s; text-align: left; }
.h2h-og-card:hover { transform: translateY(-2px); border-left-color: #ffd166; }
.h2h-og-logo { width: 52px; height: 52px; border-radius: 10px; object-fit: cover; flex: none; }
.h2h-og-text { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.h2h-og-kicker { font-family: "Oswald", sans-serif; font-size: 10.5px; letter-spacing: 1.2px; color: var(--gold, #e0a93a); }
.h2h-og-title { font-family: "Oswald", sans-serif; font-weight: 700; font-size: 16px; line-height: 1.15; }
.h2h-og-sub { font-size: 12px; color: var(--text-dim, #b9cbdd); }
.h2h-board-embed { max-width: 720px; margin: 28px auto 0; }
.h2h-board-embed .h2hb { padding-top: 0; }

#h2hRoot { position: fixed; inset: 0; z-index: 9000; display: none; background: var(--bg-3, #0a121c); color: var(--text, #eef4fb);
  --h2h-gold: #e0a93a; font-family: "Inter", system-ui, sans-serif; overflow-y: auto; -webkit-overflow-scrolling: touch;
  overscroll-behavior: none; }   /* the overlay scrolls itself — don't chain/bounce out to the page behind it */
:root[data-theme="light"] #h2hRoot { --h2h-gold: #b07d1a; }   /* darker gold so it reads on a light bg */
#h2hRoot.h2h-open { display: block; }
/* Lock the page BEHIND the 1v1 overlay so it can't scroll or rubber-band on mobile while you
   play (it kept "moving like the app"). body.h2h-active is toggled open/close by h2h.js. */
body.h2h-active { position: fixed; inset: 0; width: 100%; overflow: hidden; }
.h2h-wrap { max-width: 880px; margin: 0 auto; padding: 14px 16px 40px; }
/* mobile: don't cover the 72px top sticky ad, and clear the fixed bottom anchor ad + home bar */
@media (max-width: 767px) {
  #h2hRoot { top: 72px; }
  .h2h-wrap { padding-top: 12px; padding-bottom: calc(100px + env(safe-area-inset-bottom, 0px)); }
}
.h2h-top { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-bottom: 12px; }
.h2h-top .h2h-title { font-family: "Oswald", sans-serif; font-weight: 700; letter-spacing: .5px; font-size: 18px; }
.h2h-oppelo { color: var(--text-dim, #b9cbdd); font-weight: 500; font-size: .72em; letter-spacing: .3px; }
.h2h-x { background: none; border: none; color: var(--text-dim, #b9cbdd); font-size: 26px; line-height: 1; cursor: pointer; padding: 2px 6px; }
.h2h-x:hover { color: var(--text, #eef4fb); }
.h2h-top-r { display: flex; align-items: center; gap: 10px; }
.h2h-signin-btn { background: linear-gradient(135deg, #2a4bb5, #16224f); color: #fff; border: none; border-radius: 999px;
  padding: 6px 15px; font: inherit; font-size: 12.5px; font-weight: 700; cursor: pointer; }
.h2h-signin-btn:hover { filter: brightness(1.1); }
.h2h-guest { color: var(--text-dim, #b9cbdd); font-size: 13px; margin-top: 10px; }
.h2h-cool { color: var(--h2h-gold, #e0a93a); font-size: 13px; margin: 10px auto 0; max-width: 300px; }
.h2h-tiebreak { color: var(--h2h-gold, #e0a93a); font-size: 12.5px; font-weight: 600; margin: -4px auto 10px; max-width: 340px; }
.h2h-link { background: none; border: none; color: var(--h2h-gold); font: inherit; font-weight: 700; cursor: pointer; text-decoration: underline; padding: 0; }
/* the page's sign-in modal must sit ABOVE the 1v1 overlay (z 9000) while it's open */
body.h2h-active .modal-overlay { z-index: 10000; }

/* ---- matchmaking ---- */
.h2h-mm { text-align: center; padding: 48px 16px; }
.h2h-mm .h2h-spinner { width: 54px; height: 54px; margin: 0 auto 22px; border-radius: 50%;
  border: 4px solid rgba(224,169,58,.25); border-top-color: var(--h2h-gold); animation: h2hspin 1s linear infinite; }
@keyframes h2hspin { to { transform: rotate(360deg); } }
.h2h-mm h2 { font-family: "Oswald", sans-serif; font-size: 24px; margin: 0 0 6px; }
.h2h-mm p { color: var(--text-dim, #b9cbdd); margin: 0 0 4px; }
.h2h-mm .h2h-found { font-family: "Oswald", sans-serif; font-size: 22px; color: var(--h2h-gold); }
.h2h-vs-avatars { display: flex; align-items: center; justify-content: center; gap: 18px; margin: 18px 0; }
.h2h-av { width: 56px; height: 56px; border-radius: 50%; display: grid; place-items: center; font-size: 26px;
  background: var(--surface, #122130); border: 1px solid var(--line, rgba(255,255,255,.12)); }
.h2h-vs-x { font-family: "Oswald", sans-serif; font-weight: 700; color: var(--text-dim, #b9cbdd); }

/* ---- draft board ---- */
.h2h-sub { color: var(--text-dim, #b9cbdd); font-size: 13px; }
.h2h-cols { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin: 12px 0; }
.h2h-col { background: var(--surface, #122130); border: 1px solid var(--line, rgba(255,255,255,.12)); border-radius: 12px; padding: 8px; }
.h2h-col.h2h-active { border-color: var(--h2h-gold); box-shadow: 0 0 0 1px rgba(224,169,58,.4); }
.h2h-col-name { font-family: "Oswald", sans-serif; font-weight: 600; font-size: 14px; padding: 2px 4px 8px; display: flex; justify-content: space-between; align-items: center; }
.h2h-col-name .h2h-you { color: var(--h2h-gold); }
.h2h-slot { display: flex; align-items: center; gap: 7px; padding: 5px 6px; border-radius: 8px; font-size: 12.5px; min-height: 30px; }
.h2h-slot + .h2h-slot { border-top: 1px solid rgba(255,255,255,.05); }
.h2h-slot .h2h-pos { width: 30px; flex: none; color: var(--text-dim, #b9cbdd); font-weight: 700; font-size: 11px; }
.h2h-slot .h2h-pmain { flex: 1; min-width: 0; display: flex; flex-direction: column; line-height: 1.25; }
.h2h-slot .h2h-pname { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.h2h-slot .h2h-pstat { color: var(--text-faint, #7f93a6); font-size: 10px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.h2h-slot .h2h-pmeta { color: var(--text-faint, #7f93a6); font-size: 10.5px; flex: none; }
.h2h-slot.h2h-empty .h2h-pname { color: var(--text-faint, #7f93a6); }
.h2h-slot.h2h-just { animation: h2hpop .4s ease; }
@keyframes h2hpop { from { background: rgba(224,169,58,.22); } to { background: transparent; } }

/* ---- draw / picking ---- */
.h2h-draw { background: var(--bg-2, #0b1622); border: 1px solid var(--line, rgba(255,255,255,.12)); border-radius: 14px; padding: 12px; margin-top: 8px; }
.h2h-timer { height: 5px; border-radius: 3px; background: rgba(255,255,255,.08); overflow: hidden; margin: 0 0 12px; }
.h2h-timer-fill { height: 100%; width: 100%; background: #57c98a; border-radius: 3px; transition: width .12s linear, background .3s; }
.h2h-timer-fill.low { background: #d86b6b; }
.h2h-combo { text-align: center; margin-bottom: 10px; }
.h2h-combo .h2h-era { color: var(--text-dim, #b9cbdd); font-size: 12px; text-transform: uppercase; letter-spacing: 1px; }
.h2h-combo .h2h-team { font-family: "Oswald", sans-serif; font-weight: 700; font-size: 22px; }
.h2h-prompt { text-align: center; color: var(--text-dim, #b9cbdd); font-size: 13px; margin-bottom: 10px; min-height: 16px; }
.h2h-prompt strong { color: var(--h2h-gold); }
.h2h-opts { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 8px; }
.h2h-opt { text-align: left; background: var(--surface, #122130); border: 1px solid var(--line, rgba(255,255,255,.12)); border-radius: 10px;
  padding: 9px 11px; cursor: pointer; color: inherit; font: inherit; transition: transform .08s, border-color .12s; }
.h2h-opt:hover { border-color: var(--h2h-gold); transform: translateY(-1px); }
.h2h-opt .h2h-on { font-weight: 600; font-size: 13.5px; }
.h2h-opt .h2h-os { color: var(--text-faint, #7f93a6); font-size: 11px; margin-top: 2px; }
.h2h-opt .h2h-otag { float: right; color: var(--text-dim, #b9cbdd); font-size: 11px; font-weight: 700; }
.h2h-skips { display: flex; gap: 8px; justify-content: center; margin-top: 12px; }
.h2h-skip { background: none; border: 1px solid var(--line, rgba(255,255,255,.18)); color: var(--text-dim, #b9cbdd);
  border-radius: 999px; padding: 7px 14px; font: inherit; font-size: 12.5px; cursor: pointer; }
.h2h-skip:hover:not(:disabled) { border-color: var(--h2h-gold); color: var(--text, #eef4fb); }
.h2h-skip:disabled { opacity: .35; cursor: default; }
.h2h-skip-note { margin-top: 8px; text-align: center; font-size: 11.5px; line-height: 1.35; color: var(--text-faint, #8aa3bd); }
.h2h-thinking { text-align: center; color: var(--text-dim, #b9cbdd); padding: 14px; font-size: 14px; }
.h2h-thinking .h2h-dots::after { content: ""; animation: h2hdots 1.2s steps(4, end) infinite; }
@keyframes h2hdots { 0%{content:"";} 25%{content:".";} 50%{content:"..";} 75%{content:"...";} }

/* ---- spin-the-wheel reveal (two reels: decade | team) ---- */
.h2h-spin { text-align: center; padding: 8px 0 4px; }
.h2h-spin-duo { display: flex; gap: 10px; justify-content: center; align-items: stretch; max-width: 540px; margin: 6px auto 16px; }
.h2h-spin-w-decade { flex: 0 0 30%; }
.h2h-spin-w-team { flex: 1 1 auto; min-width: 0; }
.h2h-spin-window { position: relative; height: 112px; overflow: hidden;
  background: var(--bg-3, #0a121c); border: 3px solid var(--h2h-gold); border-radius: 16px;
  box-shadow: 0 0 34px rgba(224,169,58,.22), 0 10px 28px rgba(0,0,0,.32); }
.h2h-reel { will-change: transform; height: 100%; }   /* so the resting placeholder cell fills + centers in the window */
.h2h-reel-cell { display: grid; place-items: center; }
.h2h-spin-val { font-family: "Oswald", sans-serif; font-weight: 700; padding: 0 6px; }
.h2h-spin-val.era { font-size: clamp(18px, 5vw, 24px); letter-spacing: 1px; color: var(--text-dim, #b9cbdd); text-transform: uppercase; }
.h2h-spin-val.team { font-size: clamp(17px, 4.4vw, 26px); line-height: 1.12; }
/* top/bottom fade so values appear to scroll in and out of each window (slot-reel look) */
.h2h-spin-window::before, .h2h-spin-window::after { content: ""; position: absolute; left: 0; right: 0; height: 30px; z-index: 2; pointer-events: none; }
.h2h-spin-window::before { top: 0; background: linear-gradient(var(--bg-3, #0a121c), transparent); }
.h2h-spin-window::after { bottom: 0; background: linear-gradient(transparent, var(--bg-3, #0a121c)); }
.h2h-spin-window.h2h-spin-land { animation: h2hland .55s ease; }
@keyframes h2hland { 0% { box-shadow: 0 0 60px rgba(224,169,58,.8), 0 10px 28px rgba(0,0,0,.32); } 100% { box-shadow: 0 0 34px rgba(224,169,58,.22), 0 10px 28px rgba(0,0,0,.32); } }
.h2h-spin-btn { font-size: 18px !important; padding: 13px 40px !important; letter-spacing: .5px; }
.h2h-spin-auto { height: 4px; border-radius: 3px; background: rgba(127,147,166,.28); overflow: hidden; max-width: 240px; margin: 14px auto 6px; }
.h2h-spin-auto-fill { height: 100%; width: 100%; background: var(--h2h-gold); transition: width .08s linear; }
.h2h-spin-hint { color: var(--text-dim, #b9cbdd); font-size: 13.5px; margin-top: 10px; }

/* ---- result ---- */
.h2h-result { text-align: center; padding: 8px 0; }
.h2h-banner { font-family: "Oswald", sans-serif; font-weight: 700; font-size: clamp(34px, 9vw, 56px); margin: 6px 0; }
.h2h-banner.win { color: #57c98a; } .h2h-banner.loss { color: #d86b6b; } .h2h-banner.draw { color: var(--h2h-gold); }
.h2h-scoreline { font-family: "Oswald", sans-serif; font-size: 20px; color: var(--text-dim, #b9cbdd); margin-bottom: 4px; }
.h2h-reward { color: var(--h2h-gold); font-size: 14px; margin: 6px 0 16px; min-height: 18px; }
.h2h-reward .h2h-elo { font-family: "Oswald", sans-serif; font-weight: 700; font-size: 16px; }
.h2h-reward .h2h-elo.up { color: #57c98a; } .h2h-reward .h2h-elo.down { color: #d86b6b; } .h2h-reward .h2h-elo.even { color: var(--text-dim, #b9cbdd); }
.h2h-reward .h2h-elo-track { color: var(--text-faint, #7f93a6); font-size: 12px; }
.h2h-reward .h2h-pts { color: var(--h2h-gold); font-weight: 600; }
.h2h-reward .h2h-dot { margin: 0 8px; color: var(--text-faint, #7f93a6); }
.h2h-actions { display: flex; gap: 10px; justify-content: center; flex-wrap: wrap; margin-top: 14px; }
.h2h-btn { font-family: "Oswald", sans-serif; font-weight: 700; font-size: 15px; padding: 11px 22px; border-radius: 12px; cursor: pointer; border: 1px solid var(--line, rgba(255,255,255,.18)); background: none; color: var(--text, #eef4fb); }
.h2h-btn.h2h-primary { background: linear-gradient(135deg, #f0c04e, #cf962f); color: #241a05; border: none; }
.h2h-btn.h2h-share { background: rgba(47, 147, 255, 0.14); border-color: rgba(47, 147, 255, 0.55); color: var(--text, #eef4fb); }
.h2h-btn.h2h-share:hover { background: rgba(47, 147, 255, 0.22); }
.h2h-btn:hover { filter: brightness(1.06); }
.h2h-btn:disabled { opacity: .7; cursor: default; filter: none; }
@media (max-width: 520px) { .h2h-slot .h2h-pmeta { display: none; } .h2h-col { padding: 6px; } }
