:root {
  --navy-950: #020919;
  --navy-900: #061431;
  --navy-850: #081a3a;
  --navy-800: #0a2249;
  --blue: #2774ff;
  --blue-soft: #6ea0ff;
  --lime: #d8ff3e;
  --lime-deep: #b9e71e;
  --paper: #f7f9fd;
  --ink: #102042;
  --muted: #66728d;
  --line: #dfe5f0;
  --white: #ffffff;
  --surface: #ffffff;
  --danger: #d44949;
  --shadow: 0 18px 55px rgba(1, 11, 34, 0.12);
  --radius: 16px;
}

html[data-theme="dark"] {
  --paper: #050d1b;
  --ink: #edf3ff;
  --muted: #a6b5ce;
  --line: #273a59;
  --surface: #0c1b33;
  --shadow: 0 18px 55px rgba(0, 0, 0, .3);
  color-scheme: dark;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  min-width: 320px;
  color: var(--ink);
  background:
    radial-gradient(circle at 82% -10%, rgba(39, 116, 255, 0.11), transparent 28rem),
    var(--paper);
  font-family: Inter, ui-sans-serif, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  font-size: 16px;
  line-height: 1.5;
  transition: color .2s ease, background-color .2s ease;
}

button, a { -webkit-tap-highlight-color: transparent; }
button { font: inherit; }
a { color: inherit; }

.hidden { display: none !important; }

.skip-link {
  position: fixed;
  left: 1rem;
  top: -5rem;
  z-index: 1000;
  padding: .75rem 1rem;
  border-radius: 8px;
  color: var(--white);
  background: var(--navy-950);
}

.skip-link:focus { top: 1rem; }

.app-header {
  position: sticky;
  top: 0;
  z-index: 50;
  color: var(--white);
  background: rgba(2, 9, 25, 0.96);
  border-bottom: 1px solid rgba(255,255,255,.1);
  backdrop-filter: blur(18px);
}

.header-shell {
  width: min(1560px, calc(100% - 40px));
  min-height: 68px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1.5rem;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: .7rem;
  color: var(--white);
  text-decoration: none;
}

.brand-mark {
  display: grid;
  width: 38px;
  height: 38px;
  place-items: center;
  border: 1px solid rgba(216,255,62,.6);
  border-radius: 50%;
  color: var(--lime);
  font-size: .76rem;
  font-weight: 900;
  letter-spacing: .05em;
}

.brand-copy { display: grid; line-height: 1.1; }
.brand-copy strong { font-size: .98rem; letter-spacing: .02em; }
.brand-copy small { margin-top: .2rem; color: #9aaccd; font-size: .72rem; }

.header-actions { display: flex; align-items: center; gap: 1rem; }
.back-link { color: #b9c7e1; font-size: .88rem; text-decoration: none; }
.back-link:hover, .back-link:focus-visible { color: var(--white); }

.google-button, .account-button, .theme-toggle {
  min-height: 42px;
  border: 1px solid rgba(255,255,255,.16);
  border-radius: 999px;
  cursor: pointer;
}

.theme-toggle {
  display: inline-flex;
  align-items: center;
  gap: .45rem;
  padding: .48rem .72rem;
  color: #dbe6f9;
  background: rgba(255,255,255,.06);
  font-size: .75rem;
  font-weight: 800;
}

.theme-icon {
  width: 16px;
  height: 16px;
  border: 2px solid currentColor;
  border-radius: 50%;
  box-shadow: inset -5px -3px 0 -2px var(--navy-950);
}

html[data-theme="dark"] .theme-icon { background: var(--lime); border-color: var(--lime); box-shadow: 0 0 0 3px rgba(216,255,62,.12); }
.theme-toggle:hover, .theme-toggle:focus-visible { color: var(--white); background: rgba(255,255,255,.12); }

.google-button {
  display: inline-flex;
  align-items: center;
  gap: .55rem;
  padding: .55rem .9rem;
  color: #102042;
  background: var(--white);
  font-size: .86rem;
  font-weight: 750;
}

.google-button svg { width: 19px; height: 19px; }
.google-button:hover { background: #eef3ff; }

.account { position: relative; }
.account-button {
  display: flex;
  align-items: center;
  gap: .55rem;
  padding: .24rem .75rem .24rem .28rem;
  color: var(--white);
  background: rgba(255,255,255,.07);
}

.account-button img { border-radius: 50%; background: var(--navy-800); object-fit: cover; }
.account-button span:nth-child(2) { max-width: 130px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

.account-menu {
  position: absolute;
  top: calc(100% + .65rem);
  right: 0;
  width: 270px;
  padding: 1rem;
  border: 1px solid #dce3ef;
  border-radius: 14px;
  color: var(--ink);
  background: var(--surface);
  box-shadow: var(--shadow);
}

.account-menu p { margin: 0; overflow-wrap: anywhere; }
.account-menu #accountEmail { font-weight: 750; }
.account-menu .account-note { margin: .35rem 0 1rem; color: var(--muted); font-size: .78rem; }
.account-menu button {
  width: 100%;
  padding: .65rem;
  border: 1px solid var(--line);
  border-radius: 9px;
  color: var(--ink);
  background: var(--paper);
  cursor: pointer;
}

main { min-height: calc(100vh - 130px); }

.control-deck {
  position: relative;
  overflow: hidden;
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 2rem;
  padding: 48px max(32px, calc((100vw - 1500px) / 2)) 40px;
  color: var(--white);
  background:
    linear-gradient(90deg, transparent 0 76%, rgba(216,255,62,.09) 76% 76.2%, transparent 76.2%),
    repeating-linear-gradient(90deg, transparent 0 92px, rgba(255,255,255,.025) 92px 93px),
    linear-gradient(112deg, var(--navy-900), #0b2756 62%, #102f61);
}

.control-deck::after {
  content: "";
  position: absolute;
  right: -12rem;
  top: -14rem;
  width: 32rem;
  height: 32rem;
  border: 1px solid rgba(216,255,62,.26);
  border-radius: 50%;
  box-shadow: 0 0 0 80px rgba(216,255,62,.028), 0 0 0 160px rgba(216,255,62,.02);
  pointer-events: none;
}

.deck-copy, .deck-actions { position: relative; z-index: 1; }
.deck-copy { max-width: 880px; }

.eyebrow-row {
  display: flex;
  align-items: center;
  gap: .55rem;
  margin-bottom: .85rem;
  color: #b9c9e7;
  font-size: .74rem;
  font-weight: 800;
  letter-spacing: .09em;
  text-transform: uppercase;
}

.live-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--lime);
  box-shadow: 0 0 0 5px rgba(216,255,62,.12);
}

.control-deck h1 {
  margin: 0;
  font-family: Georgia, "Times New Roman", serif;
  font-size: clamp(2.4rem, 5vw, 5rem);
  font-weight: 500;
  letter-spacing: -.052em;
  line-height: .94;
}

.control-deck h1 span { color: var(--lime); }
.control-deck p { max-width: 660px; margin: 1rem 0 0; color: #cad6ec; font-size: 1.03rem; }

.deck-actions { display: flex; flex-wrap: wrap; justify-content: flex-end; gap: .7rem; min-width: 320px; }
.primary-action, .quiet-action {
  min-height: 48px;
  border-radius: 10px;
  cursor: pointer;
  font-size: .88rem;
  font-weight: 850;
}

.primary-action {
  display: inline-flex;
  align-items: center;
  justify-content: space-between;
  gap: 1.4rem;
  min-width: 220px;
  padding: .8rem 1rem;
  border: 1px solid var(--lime);
  color: #101b31;
  background: var(--lime);
}

.primary-action:hover { background: #e5ff79; }
.quiet-action { padding: .8rem 1rem; border: 1px solid rgba(255,255,255,.2); color: var(--white); background: rgba(255,255,255,.04); }
.quiet-action:hover { background: rgba(255,255,255,.1); }

.status-strip {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  width: min(1500px, calc(100% - 40px));
  margin: 0 auto;
  border: solid var(--line);
  border-width: 0 1px 1px;
  border-radius: 0 0 var(--radius) var(--radius);
  background: var(--surface);
  box-shadow: 0 10px 30px rgba(7,24,55,.055);
}

.status-strip div { display: flex; align-items: baseline; gap: .65rem; padding: 1rem 1.35rem; border-right: 1px solid var(--line); }
.status-strip div:last-child { border-right: 0; }
.status-strip strong { color: var(--navy-800); font-family: Georgia, serif; font-size: 1.65rem; font-weight: 500; }
.status-strip span { color: var(--muted); font-size: .77rem; font-weight: 720; }

.workspace {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 315px;
  gap: 1.25rem;
  width: min(1500px, calc(100% - 40px));
  margin: 28px auto 48px;
}

.workspace-main {
  min-width: 0;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface);
  box-shadow: var(--shadow);
}

.view-bar {
  min-height: 62px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 0 1.2rem;
  border-bottom: 1px solid var(--line);
}

.view-tabs { align-self: stretch; display: flex; align-items: stretch; gap: .25rem; }
.view-tab {
  position: relative;
  padding: 0 1rem;
  border: 0;
  color: var(--muted);
  background: transparent;
  cursor: pointer;
  font-size: .85rem;
  font-weight: 800;
}

.view-tab.active { color: var(--ink); }
.view-tab.active::after { content: ""; position: absolute; left: 1rem; right: 1rem; bottom: 0; height: 3px; border-radius: 3px 3px 0 0; background: var(--blue); }
.view-bar p { margin: 0; color: var(--muted); font-size: .76rem; }

.bracket-scroll {
  overflow-x: auto;
  overscroll-behavior-inline: contain;
  padding: 1.15rem 1.15rem 1.6rem;
  background:
    linear-gradient(rgba(246,249,254,.91), rgba(246,249,254,.91)),
    repeating-linear-gradient(90deg, #0d2a55 0 1px, transparent 1px 76px),
    repeating-linear-gradient(0deg, #0d2a55 0 1px, transparent 1px 76px);
  scrollbar-color: #afbad0 transparent;
}

.open-round {
  width: 100%;
  min-width: 980px;
  margin-bottom: 1.6rem;
  padding-bottom: 1.45rem;
  border-bottom: 1px solid #d6dfed;
}

.open-round-heading,
.tree-round-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 1rem;
}

.open-round-heading {
  margin-bottom: .8rem;
  padding: .15rem .1rem .65rem;
  border-bottom: 2px solid var(--navy-800);
}

.open-round-heading h2,
.tree-round-header h2 { margin: 0; font-size: .78rem; letter-spacing: .075em; text-transform: uppercase; }
.open-round-heading span,
.tree-round-header span { color: var(--muted); font-size: .66rem; font-weight: 750; text-align: right; }

.open-match-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(232px, 1fr));
  gap: .72rem;
}

.bracket-tree {
  position: relative;
  min-width: max-content;
}

.tree-round-headers {
  position: sticky;
  top: 0;
  z-index: 8;
  display: grid;
  gap: var(--tree-gap);
  width: var(--tree-width);
  padding-bottom: .75rem;
  background: rgba(246,249,254,.96);
}

.tree-round-header {
  min-height: 44px;
  padding: .25rem .1rem .55rem;
  border-bottom: 2px solid var(--navy-800);
}

.tree-stage {
  position: relative;
  width: var(--tree-width);
  height: var(--tree-height);
}

.bracket-connectors {
  position: absolute;
  inset: 0;
  z-index: 0;
  overflow: visible;
  pointer-events: none;
}

.bracket-connectors path {
  fill: none;
  stroke: #aab7ca;
  stroke-width: 1.5;
  vector-effect: non-scaling-stroke;
}

.match-card {
  position: relative;
  z-index: 1;
  overflow: hidden;
  border: 1px solid #d7dfec;
  border-radius: 12px;
  background: var(--surface);
  box-shadow: 0 5px 16px rgba(11,34,73,.055);
}

.tree-stage > .match-card {
  position: absolute;
  width: var(--card-width);
  height: var(--card-height);
}

.match-card::before { content: ""; position: absolute; inset: 0 auto 0 0; width: 3px; background: #bfc9da; }
.match-card.complete::before { background: var(--lime-deep); }
.match-meta { display: flex; justify-content: space-between; gap: .55rem; padding: .65rem .72rem .55rem .85rem; border-bottom: 1px solid #edf1f7; }
.match-meta span:first-child { color: var(--navy-800); font-size: .67rem; font-weight: 850; }
.match-meta span:last-child { color: var(--muted); font-size: .65rem; font-weight: 680; text-align: right; }

.player-row {
  display: grid;
  grid-template-columns: 38px minmax(0, 1fr);
  align-items: center;
  min-height: 46px;
  border-bottom: 1px solid #edf1f7;
}

.profile-trigger {
  position: relative;
  width: 30px;
  height: 30px;
  margin-left: .55rem;
  overflow: hidden;
  display: grid;
  place-items: center;
  border: 1px solid #d6dfec;
  border-radius: 50%;
  color: #4f5f79;
  background: #eaf0f8;
  cursor: pointer;
  font-size: .63rem;
  font-weight: 900;
}

.profile-trigger:hover,
.profile-trigger:focus-visible { border-color: var(--blue); outline: 2px solid rgba(39,116,255,.18); }
.profile-trigger img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; opacity: 0; }
.profile-trigger img.loaded { opacity: 1; }
.profile-trigger:disabled { cursor: default; opacity: .6; }

.player-pick {
  width: 100%;
  min-width: 0;
  min-height: 45px;
  display: grid;
  grid-template-columns: minmax(0, 1fr) 32px auto auto;
  align-items: center;
  gap: .5rem;
  padding: .45rem .62rem .45rem .35rem;
  border: 0;
  color: var(--ink);
  background: transparent;
  text-align: left;
  cursor: pointer;
}

.player-pick:hover:not(:disabled) { background: #f0f5ff; }
.player-pick:focus-visible { position: relative; z-index: 2; outline: 3px solid rgba(39,116,255,.35); outline-offset: -3px; }
.player-pick.selected { color: #07152f; background: linear-gradient(90deg, rgba(216,255,62,.48), rgba(216,255,62,.15)); }
.player-pick:disabled { color: #8893a9; cursor: not-allowed; }

.country-badge {
  display: grid;
  min-height: 23px;
  place-items: center;
  border-radius: 5px;
  color: #52617e;
  background: #eef2f8;
  font-size: .58rem;
  font-weight: 900;
  letter-spacing: .035em;
}

.player-name { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: .75rem; font-weight: 780; }
.seed { color: #6d7890; font-size: .66rem; font-weight: 850; }
.pick-check { display: none; color: #385300; font-size: .88rem; }
.player-pick.selected .seed { display: none; }
.player-pick.selected .pick-check { display: inline; }

.match-model {
  display: flex;
  justify-content: space-between;
  gap: .6rem;
  padding: .45rem .7rem .5rem .85rem;
  color: #77839b;
  background: #fbfcfe;
  font-size: .63rem;
}

.match-model a { color: var(--blue); font-weight: 850; text-decoration: none; }
.moneyline { min-width: 38px; color: #31520d; font-size: .66rem; font-weight: 900; text-align: right; }
.moneyline.model-line { color: var(--muted); }
.odds-source-note { margin: .65rem 0 0; color: var(--muted); font-size: .68rem; }
.odds-source-note a { color: var(--blue); font-weight: 850; text-decoration: none; }

.match-model strong { color: #324364; }
.scroll-hint { margin: 0; padding: .75rem 1.15rem; border-top: 1px solid var(--line); color: var(--muted); font-size: .72rem; text-align: right; }

.forecast-rail { display: grid; align-content: start; gap: 1rem; }
.champion-card, .rail-card, .source-card { border: 1px solid var(--line); border-radius: var(--radius); background: var(--surface); box-shadow: 0 10px 30px rgba(7,24,55,.055); }
.champion-card { position: relative; overflow: hidden; padding: 1.3rem; color: var(--white); background: linear-gradient(145deg, var(--navy-900), #0d2f66); border-color: transparent; }
.champion-card::after { content: ""; position: absolute; right: -58px; top: -60px; width: 155px; height: 155px; border: 1px solid rgba(216,255,62,.22); border-radius: 50%; box-shadow: 0 0 0 32px rgba(216,255,62,.035); }
.section-kicker { margin: 0 0 .35rem; color: var(--blue); font-size: .68rem; font-weight: 900; letter-spacing: .1em; text-transform: uppercase; }
.champion-card .section-kicker { color: var(--lime); }
.trophy { margin: .7rem 0 .4rem; color: var(--lime); font-size: 2.2rem; transform: rotate(-35deg); }
.champion-card h2 { position: relative; z-index: 1; margin: 0; font-family: Georgia, serif; font-size: 1.75rem; font-weight: 500; line-height: 1.04; }
.champion-card > p:not(.section-kicker):not(.completion-copy) { position: relative; z-index: 1; margin: .5rem 0 1rem; color: #b9c8e5; font-size: .78rem; }
.completion-track { height: 5px; overflow: hidden; border-radius: 99px; background: rgba(255,255,255,.14); }
.completion-track span { display: block; width: 0; height: 100%; border-radius: inherit; background: var(--lime); transition: width .25s ease; }
.completion-copy { margin: .45rem 0 0; color: #aebdda; font-size: .68rem; }

.rail-card { padding: 1.15rem; }
.rail-card-heading { display: flex; align-items: flex-start; justify-content: space-between; gap: 1rem; }
.rail-card-heading h2 { margin: 0; font-family: Georgia, serif; font-size: 1.45rem; font-weight: 500; }
.rail-card-heading button { padding: .2rem 0; border: 0; color: var(--blue); background: transparent; cursor: pointer; font-size: .72rem; font-weight: 850; }
.odds-list { display: grid; gap: .15rem; margin: .8rem 0 0; padding: 0; list-style: none; counter-reset: contender; }
.odds-list li { counter-increment: contender; display: grid; grid-template-columns: 24px minmax(0, 1fr) auto; align-items: center; gap: .5rem; padding: .55rem .25rem; border-bottom: 1px solid #edf1f6; }
.odds-list li:last-child { border-bottom: 0; }
.odds-list li::before { content: counter(contender, decimal-leading-zero); color: #9aa4b7; font-size: .64rem; font-weight: 800; }
.odds-player { min-width: 0; }
.profile-link { padding: 0; border: 0; color: inherit; background: transparent; text-align: left; cursor: pointer; }
.profile-link:hover strong, .profile-link:focus-visible strong { color: var(--blue); text-decoration: underline; text-underline-offset: 3px; }
.odds-player strong { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: .77rem; }
.odds-player span { color: var(--muted); font-size: .64rem; }
.odds-value { color: var(--navy-800); font-family: Georgia, serif; font-size: 1rem; }

.source-card { padding: 1rem 1.1rem; }
.source-card p { margin: 0 0 .55rem; color: var(--muted); font-size: .72rem; }
.source-card p strong { color: var(--ink); }
.source-links { display: flex; flex-wrap: wrap; gap: .75rem; }
.source-links a { color: var(--blue); font-size: .7rem; font-weight: 850; text-decoration: none; }
.source-card .profile-source { margin: .8rem 0 0; padding-top: .7rem; border-top: 1px solid var(--line); font-size: .65rem; }

.odds-view { padding: 1.5rem; }
.odds-heading { display: flex; justify-content: space-between; gap: 2rem; margin-bottom: 1.4rem; }
.odds-heading h2 { margin: 0; font-family: Georgia, serif; font-size: clamp(1.8rem, 3vw, 2.6rem); font-weight: 500; }
.odds-heading > p { max-width: 390px; margin: 1rem 0 0; color: var(--muted); font-size: .82rem; }
.odds-table-wrap { overflow-x: auto; border: 1px solid var(--line); border-radius: 12px; }
table { width: 100%; border-collapse: collapse; min-width: 620px; }
th, td { padding: .8rem .9rem; border-bottom: 1px solid var(--line); text-align: left; }
th { color: #6d7891; background: #f3f6fb; font-size: .68rem; letter-spacing: .055em; text-transform: uppercase; }
td { font-size: .79rem; }
tbody tr:last-child td { border-bottom: 0; }
.table-player { display: flex; align-items: center; gap: .65rem; font-weight: 780; }
.table-player .country-badge { width: 34px; flex: 0 0 auto; }
.odds-bar { width: 130px; height: 6px; overflow: hidden; display: inline-block; vertical-align: middle; margin-left: .7rem; border-radius: 99px; background: #e8edf5; }
.odds-bar span { display: block; height: 100%; border-radius: inherit; background: var(--blue); }

.news-view { padding: 1.5rem; }
.news-heading { display: flex; justify-content: space-between; gap: 2rem; margin-bottom: 1.4rem; }
.news-heading h2 { margin: 0; font-family: Georgia, serif; font-size: clamp(1.8rem, 3vw, 2.6rem); font-weight: 500; }
.news-heading > p { max-width: 390px; margin: 1rem 0 0; color: var(--muted); font-size: .82rem; }
.news-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 1rem; }
.news-card { position: relative; overflow: hidden; display: grid; grid-template-columns: 135px minmax(0, 1fr); min-height: 190px; border: 1px solid var(--line); border-radius: 14px; color: var(--ink); background: var(--surface); text-decoration: none; transition: transform .18s ease, border-color .18s ease; }
.news-card:hover, .news-card:focus-visible { transform: translateY(-2px); border-color: var(--blue); outline: none; }
.news-visual { position: relative; display: grid; place-items: center; overflow: hidden; color: var(--lime); background: linear-gradient(150deg, #071a39, #205ba3); font-family: Georgia, serif; font-size: 2rem; }
.news-visual img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; object-position: top center; opacity: 0; }
.news-visual img.loaded { opacity: 1; }
.news-visual::after { content: ""; position: absolute; inset: auto 0 0; height: 45%; background: linear-gradient(transparent, rgba(2,9,25,.72)); }
.news-score { position: absolute; z-index: 1; left: .7rem; right: .7rem; bottom: .65rem; color: #fff; font-family: Inter, sans-serif; font-size: .65rem; font-weight: 850; line-height: 1.35; }
.news-copy { display: flex; flex-direction: column; padding: 1rem; }
.news-tag { margin: 0 0 .4rem; color: var(--blue); font-size: .62rem; font-weight: 900; letter-spacing: .08em; text-transform: uppercase; }
.news-card h3 { margin: 0; font-family: Georgia, serif; font-size: 1.15rem; font-weight: 600; line-height: 1.15; }
.news-dek { margin: .55rem 0 .8rem; color: var(--muted); font-size: .73rem; line-height: 1.45; }
.news-source { margin-top: auto; color: var(--muted); font-size: .64rem; font-weight: 800; }

.toast {
  position: fixed;
  left: 50%;
  bottom: 24px;
  z-index: 100;
  max-width: min(420px, calc(100% - 32px));
  padding: .75rem 1rem;
  border-radius: 10px;
  color: var(--white);
  background: var(--navy-950);
  box-shadow: var(--shadow);
  font-size: .8rem;
  font-weight: 720;
  opacity: 0;
  pointer-events: none;
  transform: translate(-50%, 18px);
  transition: .2s ease;
}

.toast.show { opacity: 1; transform: translate(-50%, 0); }

.player-dialog {
  width: min(650px, calc(100% - 28px));
  max-height: min(760px, calc(100vh - 40px));
  overflow-y: auto;
  padding: 0;
  border: 0;
  border-radius: 20px;
  color: var(--ink);
  background: var(--surface);
  box-shadow: 0 28px 90px rgba(1, 9, 28, .34);
}

.player-dialog::backdrop { background: rgba(2, 9, 25, .7); backdrop-filter: blur(5px); }
.dialog-close {
  position: absolute;
  top: .8rem;
  right: .8rem;
  z-index: 2;
  width: 36px;
  height: 36px;
  border: 1px solid rgba(255,255,255,.25);
  border-radius: 50%;
  color: var(--white);
  background: rgba(2,9,25,.48);
  cursor: pointer;
  font-size: 1.35rem;
  line-height: 1;
}

.profile-hero {
  display: grid;
  grid-template-columns: 150px minmax(0, 1fr);
  align-items: end;
  gap: 1.3rem;
  min-height: 210px;
  padding: 2rem;
  color: var(--white);
  background: linear-gradient(140deg, #061431, #17467f);
}

.profile-photo {
  width: 150px;
  aspect-ratio: 4 / 5;
  display: grid;
  place-items: center;
  overflow: hidden;
  border: 1px solid rgba(255,255,255,.22);
  border-radius: 14px;
  color: var(--lime);
  background: rgba(255,255,255,.08);
  font-family: Georgia, serif;
  font-size: 2.2rem;
}

.profile-photo img { width: 100%; height: 100%; object-fit: cover; object-position: top center; }
.profile-hero .section-kicker { color: var(--lime); }
.profile-hero h2 { margin: 0; font-family: Georgia, serif; font-size: clamp(2rem, 5vw, 3rem); font-weight: 500; line-height: 1; }
.profile-hero #profileDescription { margin: .65rem 0 0; color: #c4d1e7; font-size: .82rem; text-transform: capitalize; }
.profile-stats { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1px; background: var(--line); border-bottom: 1px solid var(--line); }
.profile-stat { min-height: 88px; padding: 1rem; background: var(--surface); }
.profile-stat span { display: block; margin-bottom: .3rem; color: var(--muted); font-size: .62rem; font-weight: 850; letter-spacing: .07em; text-transform: uppercase; }
.profile-stat strong { display: block; color: var(--navy-800); font-size: .82rem; line-height: 1.35; }
.profile-bio { margin: 0; padding: 1.3rem 2rem .7rem; color: #46536c; font-size: .86rem; line-height: 1.65; }
.profile-actions { display: flex; flex-wrap: wrap; gap: .8rem 1.2rem; padding: .6rem 2rem 1rem; }
.profile-actions a { color: var(--blue); font-size: .75rem; font-weight: 850; text-decoration: none; }
.profile-credit { margin: 0; padding: .9rem 2rem 1.2rem; color: #7b8598; background: #f5f7fb; font-size: .64rem; }

footer { padding: 0 24px 42px; color: #7b8599; font-size: .7rem; text-align: center; }
footer p { margin: 0 auto; max-width: 760px; }

html[data-theme="dark"] .bracket-scroll {
  background:
    linear-gradient(rgba(7,18,36,.94), rgba(7,18,36,.94)),
    repeating-linear-gradient(90deg, #34527b 0 1px, transparent 1px 76px),
    repeating-linear-gradient(0deg, #34527b 0 1px, transparent 1px 76px);
}
html[data-theme="dark"] .tree-round-headers { background: rgba(7,18,36,.97); }
html[data-theme="dark"] .match-meta,
html[data-theme="dark"] .player-row { border-color: #203451; }
html[data-theme="dark"] .match-model { color: #98a8c1; background: #09172b; }
html[data-theme="dark"] .match-model strong { color: #d3def0; }
html[data-theme="dark"] .country-badge,
html[data-theme="dark"] .profile-trigger { color: #b7c7de; background: #182b48; }
html[data-theme="dark"] .player-pick:hover:not(:disabled) { background: #12284a; }
html[data-theme="dark"] .player-pick.selected { color: #f0f6ff; background: linear-gradient(90deg, rgba(127,166,23,.48), rgba(127,166,23,.13)); }
html[data-theme="dark"] .player-pick.selected .pick-check,
html[data-theme="dark"] .moneyline { color: var(--lime); }
html[data-theme="dark"] th { color: #aebbd0; background: #10223e; }
html[data-theme="dark"] .odds-bar { background: #223755; }
html[data-theme="dark"] .profile-credit { color: #9cabc2; background: #09172b; }
html[data-theme="dark"] .account-menu button { color: var(--ink); background: #12233e; }
html[data-theme="dark"] .status-strip strong,
html[data-theme="dark"] .profile-stat strong,
html[data-theme="dark"] .match-meta span:first-child,
html[data-theme="dark"] .odds-value { color: #edf3ff; }
html[data-theme="dark"] .profile-bio { color: #bdc9dc; }
html[data-theme="dark"] .account-menu { border-color: var(--line); }

@media (max-width: 1100px) {
  .workspace { grid-template-columns: 1fr; }
  .forecast-rail { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .source-card { grid-column: 1 / -1; }
}

@media (max-width: 800px) {
  .header-shell { width: min(100% - 24px, 1560px); }
  .back-link, .google-button span { display: none; }
  .google-button { width: 42px; justify-content: center; padding: .5rem; }
  .account-button #accountName { display: none; }
  .control-deck { align-items: flex-start; flex-direction: column; padding: 38px 20px 32px; }
  .deck-actions { justify-content: flex-start; min-width: 0; width: 100%; }
  .status-strip { grid-template-columns: repeat(2, 1fr); width: calc(100% - 24px); }
  .status-strip div:nth-child(2) { border-right: 0; }
  .status-strip div:nth-child(-n+2) { border-bottom: 1px solid var(--line); }
  .workspace { width: calc(100% - 24px); margin-top: 18px; }
  .view-bar { align-items: flex-start; flex-direction: column; padding: .8rem 1rem 0; }
  .view-tabs { min-height: 44px; }
  .view-bar p { padding-bottom: .75rem; }
  .forecast-rail { grid-template-columns: 1fr; }
  .source-card { grid-column: auto; }
  .odds-heading { flex-direction: column; gap: .25rem; }
  .news-heading { flex-direction: column; gap: .25rem; }
  .news-grid { grid-template-columns: 1fr; }
}

@media (max-width: 520px) {
  .brand-copy small { display: none; }
  .theme-toggle #themeLabel { display: none; }
  .theme-toggle { width: 42px; justify-content: center; padding: .5rem; }
  .control-deck h1 { font-size: 2.55rem; }
  .control-deck p { font-size: .92rem; }
  .deck-actions { display: grid; }
  .primary-action { min-width: 0; }
  .status-strip div { align-items: flex-start; flex-direction: column; gap: .05rem; padding: .8rem 1rem; }
  .status-strip strong { font-size: 1.35rem; }
  .bracket-scroll { padding: .85rem; }
  .odds-view { padding: 1rem; }
  .news-view { padding: 1rem; }
  .news-card { grid-template-columns: 105px minmax(0, 1fr); }
  .profile-hero { grid-template-columns: 95px minmax(0, 1fr); gap: 1rem; min-height: 170px; padding: 1.5rem; }
  .profile-photo { width: 95px; }
  .profile-stats { grid-template-columns: repeat(2, 1fr); }
  .profile-bio, .profile-actions { padding-left: 1.4rem; padding-right: 1.4rem; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { scroll-behavior: auto !important; transition: none !important; animation: none !important; }
}
