:root {
  color-scheme: dark;
  --bg: #100d0c;
  --panel: #1a1513;
  --panel-bright: #211916;
  --line: #392b24;
  --line-bright: #624732;
  --gold: #e7b875;
  --gold-light: #f4d49e;
  --red: #e25650;
  --ink: #f5ede4;
  --muted: #bfb0a4;
  --body: "Segoe UI", Arial, sans-serif;
  --display: "Bahnschrift", "Arial Black", "Segoe UI", sans-serif;
  color: var(--ink);
  background: var(--bg);
  font-family: var(--body);
  scroll-behavior: smooth;
}

*, *::before, *::after { box-sizing: border-box; }
body { margin: 0; min-width: 280px; }
img { display: block; max-width: 100%; }
button, input, select, textarea { font: inherit; }
button, select { cursor: pointer; }
button:disabled { cursor: default; }
a { color: inherit; text-decoration: none; }
button, a, input, select { -webkit-tap-highlight-color: transparent; }
[hidden] { display: none !important; }
:focus-visible { outline: 2px solid var(--gold-light); outline-offset: 3px; }
::selection { color: #211610; background: var(--gold); }
.wrap { width: min(100% - 64px, 1220px); margin-inline: auto; }
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
.skip-link { position: fixed; z-index: 10; top: 12px; left: 12px; padding: 10px 14px; background: var(--panel); transform: translateY(-150%); }
.skip-link:focus { transform: none; }
body:not(.admin-active) .admin-only { display: none; }

.site-header { position: sticky; top: 0; z-index: 5; background: #100d0cf7; border-bottom: 1px solid var(--line); }
.header-inner { min-height: 69px; display: grid; grid-template-columns: 1fr auto 1fr; align-items: center; gap: 14px; }
.wordmark { width: fit-content; display: inline-flex; gap: 9px; align-items: center; font: 750 1rem/1.05 var(--display); letter-spacing: .075em; white-space: nowrap; text-transform: uppercase; }
.brand-emblem { display: block; flex: none; height: auto; object-fit: contain; }
.wordmark .brand-emblem { filter: brightness(1.5) saturate(.82); }
.wordmark strong { color: var(--gold); }
nav { display: flex; align-self: stretch; gap: clamp(19px, 3.2vw, 44px); }
nav a { display: inline-grid; align-items: center; color: var(--muted); font-size: .92rem; font-weight: 650; transition: color 150ms; white-space: nowrap; }
nav a:hover { color: var(--gold-light); }
.admin-toggle { justify-self: end; }

.button { display: inline-flex; gap: 9px; align-items: center; justify-content: center; min-height: 42px; padding: 9px 15px; border: 1px solid transparent; border-radius: 4px; color: var(--ink); font-size: .9rem; font-weight: 700; line-height: 1.2; text-align: center; transition: background-color 160ms, border-color 160ms, box-shadow 160ms, transform 160ms; }
.button-gold { background: var(--gold); color: #23160d; border-color: var(--gold); }
.button-gold:hover { background: #f8d59b; border-color: #f8d59b; box-shadow: 0 0 26px #e7b87528; transform: translateY(-1px); }
.button-secondary, .button-small { background: #1a1411; color: var(--gold-light); border-color: var(--line-bright); }
.button-secondary:hover, .button-small:hover, .button-secondary[aria-pressed="true"] { background: #342519; border-color: #9d7146; }
.button-danger { background: #2a1717; color: #ffb4ab; border-color: #7f4941; }
.button-danger:hover { background: #43201d; }
.button-small { min-height: 35px; padding: 6px 10px; font-size: .82rem; }
.lock-icon { position: relative; width: 12px; height: 10px; margin-top: 4px; border: 1px solid currentColor; border-radius: 2px; }
.lock-icon::before { position: absolute; content: ""; inset: -6px 2px auto; height: 6px; border: 1px solid currentColor; border-radius: 5px 5px 0 0; }
.admin-active .lock-icon::before { inset-inline-start: 4px; transform: rotate(25deg); transform-origin: bottom right; }

.hero { position: relative; isolation: isolate; overflow: hidden; background: radial-gradient(ellipse at 76% 45%, #672522 0%, #341416 42%, #211113 68%, #140e0e 100%); }
.hero::before { content: ""; position: absolute; z-index: -1; inset: 0; background: linear-gradient(90deg, #111011b3, transparent 74%), linear-gradient(0deg, #130c0ccf, transparent 60%), repeating-linear-gradient(130deg, transparent 0 122px, #af38292d 123px 170px, transparent 171px 244px, #1a090b81 245px 300px, transparent 301px 370px); }
.hero-contours { position: absolute; z-index: -1; width: 100%; height: 100%; inset: 0; object-fit: cover; opacity: .7; pointer-events: none; }
.hero-inner { min-height: 360px; display: grid; grid-template-columns: 1.4fr 1fr; align-items: center; gap: 30px; padding-block: 32px; }
.hero-eyebrow { display: flex; align-items: center; gap: 10px; margin: 0 0 17px; color: var(--gold-light); font-size: .81rem; letter-spacing: .19em; font-weight: 750; }
.hero-eyebrow i { display: block; width: 23px; height: 2px; background: var(--red); }
.hero h1 { margin: 0; font: 900 clamp(3.8rem, 8.2vw, 7.4rem)/.9 var(--display); letter-spacing: -.055em; text-transform: uppercase; text-shadow: 0 10px 30px #110905ab; }
.hero h1 span { color: var(--gold); display: block; margin-top: .14em; font-size: clamp(2rem, 4.5vw, 4.6rem); }
.hero-summary { margin: 17px 0 22px; font-size: 1.05rem; color: var(--ink); font-weight: 650; }
.hero .button { padding-inline: 20px; }
.hero-art { height: 100%; min-height: 265px; position: relative; display: grid; place-items: center; }
.hero-art .brand-emblem { width: min(58%, 235px); transform: rotate(-6deg); filter: brightness(1.51) saturate(.78) drop-shadow(0 15px 19px #100608aa) drop-shadow(0 0 35px #eaae5d42); }
.crest-outline { position: absolute; inset: 8% 9%; background: linear-gradient(128deg, transparent 32%, #ffcc7c25 32.2% 32.45%, transparent 32.7% 66%, #ffcc7c2b 66.1% 66.4%, transparent 66.5%), linear-gradient(140deg, #e6a47472, transparent 13%, transparent 87%, #e6a47472); border: 1px solid #b6895a37; clip-path: polygon(0 0, 100% 0, 100% 81%, 90% 100%, 0 100%); }

.sponsors { padding-top: 21px; scroll-margin-top: 90px; }
.sponsors h2 { margin: 0 0 8px; color: var(--gold-light); font: 750 1rem/1.2 var(--display); letter-spacing: .07em; text-transform: uppercase; }
.sponsor-viewport { overflow-x: auto; }
.sponsor-track { display: flex; width: max-content; padding-block: 6px; background: var(--bg); isolation: isolate; }
.sponsor-list { display: flex; flex: none; gap: 10px; margin: 0; padding: 0 10px 0 0; list-style: none; }
.sponsor-list li { display: grid; place-items: center; width: clamp(156px, 25vw, 305px); padding-inline: 6px; }
.sponsor-mark { position: relative; width: min(100%, 150px); height: 64px; display: grid; place-items: center; overflow: hidden; }
.sponsor-mark img { width: auto; height: auto; }
.sponsor-target img { width: 111px; }
.sponsor-bada img { width: 100%; transform: translateY(-53%); filter: invert(1) hue-rotate(180deg) saturate(1.55) contrast(1.38); }
.sponsor-tg img { width: 78px; transform: translateY(-50%); filter: grayscale(1) contrast(3.5); }
.sponsor-zeta img { width: 82px; transform: translateY(-50%); filter: brightness(.9) contrast(1.35); }
.sponsor-altargana { width: min(100%, 166px); }
.sponsor-altargana img { width: 100%; filter: brightness(2.65) saturate(.8); }
.sponsor-bada, .sponsor-tg, .sponsor-zeta { mix-blend-mode: screen; }
.sponsor-bada img, .sponsor-tg img, .sponsor-zeta img { position: absolute; top: 50%; }
.sponsor-viewport.is-animated { overflow: hidden; }
.sponsor-viewport.is-animated .sponsor-track { animation: sponsor-scroll 30s linear infinite; }
@keyframes sponsor-scroll { to { transform: translateX(-50%); } }

.main-content { padding-block: 34px 62px; }
.main-content section { scroll-margin-top: 86px; }
.main-content section + section { margin-top: 38px; }
.section-heading { display: flex; gap: 9px 15px; align-items: end; justify-content: space-between; flex-wrap: wrap; margin-bottom: 15px; }
.section-heading h2 { margin: 0; font: 800 clamp(1.5rem, 3.4vw, 2.1rem)/1.08 var(--display); letter-spacing: .018em; text-transform: uppercase; }
.section-heading p { margin: 0; color: var(--muted); font-size: .91rem; }
.section-controls { display: flex; gap: 8px 14px; align-items: center; flex-wrap: wrap; }
.section-heading .stage-label { color: var(--gold); font: 700 .79rem/1.2 var(--display); text-transform: uppercase; letter-spacing: .08em; margin-bottom: 6px; }
.qualification { display: inline-flex; align-items: center; gap: 8px; }
.qualification i { width: 8px; height: 8px; border: 1px solid var(--gold); transform: rotate(45deg); }
.group-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; }
.group-card { min-width: 0; overflow: hidden; background: var(--panel); border: 1px solid var(--line); border-radius: 5px; }
.group-head { min-height: 61px; display: flex; align-items: center; justify-content: space-between; gap: 8px; padding: 10px 15px; background: linear-gradient(112deg, #35201a, var(--panel-bright) 72%); border-bottom: 1px solid var(--line); }
.group-head h3 { display: flex; align-items: center; gap: 9px; margin: 0; font: 750 1.08rem/1 var(--display); }
.group-head h3 b { display: grid; place-items: center; width: 32px; height: 32px; color: var(--gold-light); background: #5a3627; clip-path: polygon(0 0, 100% 0, 100% 75%, 75% 100%, 0 100%); }
.group-head > span, .group-foot > span { color: var(--muted); font-size: .86rem; }
.standings { width: 100%; border-collapse: collapse; table-layout: fixed; }
.standings col.place { width: 40px; }
.standings col.metric { width: 45px; }
.standings thead th { height: 32px; font-size: .8rem; color: var(--muted); }
.standings thead th:nth-child(2) { text-align: left; }
.standings abbr { text-decoration: none; }
.standings tbody tr { border-top: 1px solid #3b2d25; }
.standings tbody tr.qualification-slot { background: #e7b87514; box-shadow: inset 2px 0 var(--gold); }
.standings tbody td { text-align: center; color: var(--muted); font-size: .87rem; font-variant-numeric: tabular-nums; }
.standings tbody tr.qualification-slot td:first-child { color: var(--gold-light); font-weight: 750; }
.standings tbody th { min-width: 0; height: 43px; padding: 4px 2px 4px 0; }
.group-team { display: flex; align-items: center; gap: 7px; min-width: 0; }
.group-team .team-roster-trigger { font-size: .89rem; text-align: left; }
.group-team .team-badge { width: 29px; height: 29px; font-size: .72rem; }
.group-team .edit-team { margin-left: auto; }
.group-foot { border-top: 1px solid var(--line); display: flex; align-items: center; justify-content: space-between; gap: 6px; padding: 5px 12px; min-height: 42px; }
.group-schedule { border-top: 1px solid var(--line); padding: 12px; }
.group-schedule h4 { margin: 0 0 10px; font: 750 1rem/1.2 var(--display); }
.schedule-round + .schedule-round { margin-top: 10px; }
.schedule-round h5 { margin: 0 0 5px; color: var(--gold-light); font-size: .78rem; font-weight: 750; letter-spacing: .045em; text-transform: uppercase; }
.schedule-round ul { display: grid; gap: 5px; margin: 0; padding: 0; list-style: none; }
.schedule-match { position: relative; display: grid; grid-template-columns: minmax(0, 1fr) auto; align-items: center; gap: 7px 11px; width: 100%; min-height: 42px; padding: 6px 8px; border: 1px solid #48382d; border-radius: 4px; color: var(--ink); background: #211916; text-align: left; transition: background-color 160ms, border-color 160ms; }
.schedule-match:hover { background: #33241b; border-color: #b98a54; }
.schedule-sides { display: grid; grid-template-columns: minmax(0, 1fr) auto minmax(0, 1fr); align-items: center; gap: 5px; font-size: .85rem; font-weight: 650; }
.schedule-sides .team-roster-trigger:last-child { justify-self: end; text-align: right; }
.schedule-sides strong { color: var(--gold-light); padding: 1px 3px; white-space: nowrap; font-size: .8rem; font-variant-numeric: tabular-nums; }
.schedule-meta { display: grid; justify-items: end; align-items: center; gap: 3px; }
.schedule-meta .status { padding: 3px 4px; font-size: .65rem; }
.schedule-meta time { color: var(--muted); font-size: .72rem; white-space: nowrap; }
.team-badge { display: grid; flex: none; place-items: center; width: 40px; height: 40px; background: #3f2d21; color: #f4cc95; border: 1px solid #765138; border-radius: 4px; font: 750 .82rem/1 var(--display); }
.team-badge img { width: 100%; height: 100%; aspect-ratio: 1; object-fit: contain; padding: 3px; border-radius: inherit; }
.team-badge.tone-2, .team-badge.tone-6 { background: #432423; border-color: #7f4741; color: #ffd0c6; }
.team-badge.tone-3, .team-badge.tone-7 { background: #323139; border-color: #666373; color: #e2ddeb; }
.team-badge.tone-4, .team-badge.tone-8 { background: #303327; border-color: #626548; color: #e3e6bb; }
.team-badge.pending { border-style: dashed; background: #231b16; color: var(--muted); }
.edit-team { min-width: 34px; min-height: 36px; padding: 4px 5px; color: var(--gold-light); background: transparent; border: 0; font-size: .77rem; font-weight: 700; }
.edit-team:hover { text-decoration: underline; text-underline-offset: 4px; }
.team-roster-trigger { position: relative; z-index: 1; display: block; min-width: 0; max-width: 100%; width: fit-content; padding: 0; border: 0; border-radius: 2px; color: inherit; background: none; text-align: inherit; font: inherit; font-weight: 700; overflow-wrap: anywhere; }
.team-roster-trigger:hover, .team-roster-trigger[aria-expanded="true"] { color: var(--gold-light); text-decoration: underline; text-underline-offset: 3px; }
.match-hit-area { position: absolute; inset: 0; width: 100%; height: 100%; padding: 0; border: 0; border-radius: inherit; background: transparent; }
.match-hit-area:focus-visible { outline-offset: -3px; }
.roster-popover { position: fixed; inset: auto; margin: 0; width: min(274px, calc(100vw - 20px)); max-height: calc(100dvh - 20px); overflow-y: auto; padding: 10px 11px; border: 1px solid #90683f; border-radius: 5px; color: var(--ink); background: #241913; box-shadow: 0 12px 34px #080504ce; }
.roster-popover h2 { margin: 0; padding-bottom: 7px; border-bottom: 1px solid #553c29; color: var(--gold-light); font-size: .96rem; overflow-wrap: anywhere; }
.roster-list { margin: 0; padding: 0; list-style: none; }
.roster-list li { display: grid; gap: 2px; padding-block: 6px; overflow-wrap: anywhere; }
.roster-list li + li { border-top: 1px solid #463124; }
.roster-list strong { color: var(--ink); font-size: .86rem; }
.roster-list span, .roster-empty { color: var(--muted); font-size: .81rem; }
.roster-empty { margin: 8px 0 1px; }

.bracket-jumps { display: none; }
.bracket-scroll { overflow: auto; border: 1px solid var(--line); border-radius: 6px; background: radial-gradient(ellipse at 90% 52%, #281b14, transparent 67%), #161211; scrollbar-color: #765640 #211815; }
.bracket-board { --row-gap: 12px; --column-gap: clamp(22px, 3.2vw, 45px); min-width: 620px; padding: 17px; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)) minmax(0, .68fr); gap: 10px var(--column-gap); position: relative; isolation: isolate; }
.bracket-lines { position: absolute; z-index: -1; inset: 0; width: 100%; height: 100%; pointer-events: none; }
.bracket-column { min-width: 0; display: grid; grid-template-rows: 27px repeat(2, 130px); gap: var(--row-gap); }
.bracket-column h3 { margin: 0; display: flex; align-items: center; justify-content: space-between; gap: 6px; font-size: .85rem; color: var(--muted); font-weight: 700; }
.bracket-column h3 span { color: var(--gold-light); font: 720 .77rem/1 var(--display); }
.bracket-cell { min-width: 0; align-self: center; position: relative; }
.finals .bracket-cell, .champions .bracket-cell { grid-row: span 2; }
.match-card { position: relative; display: block; width: 100%; padding: 0; color: var(--ink); text-align: left; background: var(--panel-bright); border: 1px solid #5b4433; border-radius: 4px; overflow: hidden; transition: border-color 160ms, box-shadow 160ms, background-color 160ms; }
.match-card:hover { border-color: var(--gold); box-shadow: 0 0 20px #e7b87517; background: #2b201a; }
.match-card[data-status="Live"] { border-color: #9f5540; }
.match-meta { display: flex; align-items: center; justify-content: space-between; gap: 6px; min-height: 29px; border-bottom: 1px solid #4c382a; padding: 4px 8px; color: var(--gold-light); font-size: .73rem; font-weight: 700; text-transform: uppercase; letter-spacing: .04em; }
.status { display: inline-flex; align-items: center; white-space: nowrap; border-radius: 3px; padding: 3px 6px; font-size: .73rem; font-weight: 750; letter-spacing: .035em; text-transform: uppercase; color: #d1bfb0; background: #352a25; }
.status.live { color: #ffd0c5; background: #66302b; }
.status.finished { color: #f3d3a1; background: #47341f; }
.match-row { min-height: 29px; display: grid; grid-template-columns: 21px minmax(0, 1fr) auto; gap: 6px; align-items: center; padding: 3px 8px; }
.match-row + .match-row { border-top: 1px solid #3d2e27; }
.match-row.seed-winner { background: #e7b87512; color: var(--gold-light); }
.row-seed { font-size: .72rem; color: var(--muted); }
.row-name { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: .83rem; font-weight: 690; }
.row-name .team-roster-trigger { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; outline-offset: -2px; }
.row-wins { font: 750 .9rem/1 var(--display); font-variant-numeric: tabular-nums; }
.match-maps { display: flex; flex-wrap: wrap; gap: 3px 5px; padding: 4px 7px 5px; border-top: 1px solid #3d2e27; min-height: 22px; }
.match-maps span { background: #342720; border-radius: 2px; color: #e4cbb0; padding: 2px 4px; font-size: .66rem; line-height: 1.2; white-space: nowrap; }
.match-maps span.is-live { background: #522c25; color: #ffbcaa; }
.match-maps .pending-maps { padding-inline: 1px; background: none; color: var(--muted); }

.champion-card { min-height: 134px; padding: 13px 7px; display: grid; align-content: center; justify-items: center; gap: 8px; border-radius: 5px; border: 1px solid #745435; background: linear-gradient(160deg, #302018, #211815); text-align: center; }
.champion-card .team-roster-trigger { color: var(--gold-light); }
.champion-card > span { color: var(--muted); font-size: .82rem; }
.champion-card.is-crowned { border-color: var(--gold); box-shadow: 0 0 26px #edb97435, inset 0 0 30px #b47a262c; background: radial-gradient(ellipse at 50% 22%, #503425, #201612 79%); }
.trophy { width: 56px; height: 52px; position: relative; color: #a4815a; }
.trophy::before, .trophy::after { position: absolute; top: 6px; width: 20px; height: 20px; content: ""; border: 2px solid; border-radius: 4px 4px 55% 55%; }
.trophy::before { left: 1px; }
.trophy::after { right: 1px; }
.trophy-cup { width: 29px; height: 29px; position: absolute; top: 2px; left: 14px; z-index: 1; border: 1px solid currentColor; border-radius: 3px 3px 51% 51%; background: #38291f; }
.trophy-stem { width: 6px; height: 16px; background: currentColor; position: absolute; bottom: 9px; left: 25px; }
.trophy-base { width: 26px; height: 6px; background: currentColor; position: absolute; bottom: 5px; left: 15px; border-radius: 3px 3px 1px 1px; }
.is-crowned .trophy { color: var(--gold); filter: drop-shadow(0 2px 8px #f2a55a70); animation: trophy-lift 740ms cubic-bezier(.2,.8,.28,1.35) both; }
.is-crowned .trophy-cup { background: linear-gradient(120deg, #fff2bd, #e6b461 52%, #9c6130); }
@keyframes trophy-lift { from { transform: translateY(11px) scale(.62); opacity: .4; } to { transform: none; opacity: 1; } }

.match-picker { width: min(100%, 415px); }
select, .form-control { border: 1px solid var(--line-bright); background-color: #140f0e; color: var(--ink); border-radius: 4px; min-height: 42px; padding: 8px 10px; }
select { appearance: none; padding-right: 28px; background-image: linear-gradient(45deg, transparent 49%, var(--gold) 50%), linear-gradient(135deg, var(--gold) 50%, transparent 51%); background-position: calc(100% - 14px) center, calc(100% - 9px) center; background-size: 5px 5px; background-repeat: no-repeat; }
.match-picker select { width: 100%; }
.scorecard { background: var(--panel); border: 1px solid var(--line); border-radius: 6px; overflow: hidden; }
.score-top { min-height: 61px; display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap; gap: 7px 14px; padding: 10px 15px; background: #271b15; border-bottom: 1px solid var(--line); }
.score-top h3 { margin: 0; font-size: 1.05rem; }
.score-top .score-meta { display: flex; align-items: center; gap: 9px; color: var(--gold-light); font-size: .86rem; }
.score-body { padding: 15px; }
.score-duel { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
.score-team { min-width: 0; display: grid; grid-template-columns: auto 1fr auto; gap: 11px; align-items: center; padding: 11px; border: 1px solid var(--line); border-radius: 4px; background: #160f0e; }
.score-team.is-winner { border-color: #92683f; background: #342319; }
.score-team-name { min-width: 0; overflow-wrap: anywhere; font-weight: 750; }
.score-team > strong { color: var(--gold-light); font: 800 1.85rem/1 var(--display); font-variant-numeric: tabular-nums; }
.score-maps { list-style: none; padding: 0; margin: 13px 0 0; display: grid; grid-template-columns: repeat(auto-fit, minmax(128px, 1fr)); gap: 7px; }
.score-maps li { display: flex; justify-content: space-between; align-items: center; gap: 5px; min-height: 39px; padding: 6px 8px; border: 1px solid var(--line); border-radius: 3px; font-size: .85rem; }
.score-maps li span { color: var(--muted); }
.score-maps li strong { white-space: nowrap; font-size: .82rem; font-variant-numeric: tabular-nums; }
.score-maps li.is-live { border-color: #895041; }
.score-bottom { margin-top: 13px; display: flex; justify-content: space-between; gap: 9px 12px; flex-wrap: wrap; align-items: center; }
.score-bottom p { margin: 0; color: var(--muted); font-size: .86rem; }
.site-footer { border-top: 1px solid var(--line); background: #15110f; }
.footer-inner { display: flex; min-height: 76px; justify-content: space-between; align-items: center; gap: 10px 16px; flex-wrap: wrap; padding-block: 12px; }
.hosted-access { min-height: 100dvh; display: grid; place-items: center; padding: 18px; background: radial-gradient(ellipse at top, #371e1a, var(--bg) 63%); }
.hosted-access-card { width: min(100%, 490px); padding: clamp(18px, 6vw, 34px); border: 1px solid var(--line-bright); border-radius: 5px; background: var(--panel); }
.hosted-access-card .brand-emblem { width: 53px; filter: brightness(1.5) saturate(.82); }
.hosted-access-card h1 { margin: 12px 0 7px; font-size: clamp(1.4rem, 5vw, 1.9rem); }
.hosted-access-card p { margin: 0 0 16px; color: var(--muted); }
.hosted-access-card > div { display: flex; flex-wrap: wrap; gap: 7px; }

dialog { color: var(--ink); background: #211815; border: 1px solid #98714b; border-radius: 7px; padding: 0; width: min(100% - 25px, 620px); max-height: 90dvh; overflow: auto; box-shadow: 0 18px 84px #080303cb; }
dialog::backdrop { background: #080505d1; }
#dialog-form { padding: clamp(13px, 3.5vw, 23px); }
.dialog-head { display: flex; justify-content: space-between; align-items: start; gap: 13px; margin-bottom: 12px; }
.dialog-head h2 { margin: 0; font: 780 clamp(1.3rem, 4.6vw, 1.75rem)/1.12 var(--display); }
.dialog-head p { color: var(--gold-light); font-size: .78rem; margin: 0 0 5px; font-weight: 750; letter-spacing: .07em; text-transform: uppercase; }
.dialog-head p:empty { display: none; }
.close-dialog { min-width: 35px; min-height: 35px; display: grid; place-items: center; padding: 0; background: transparent; color: var(--gold-light); border: 1px solid var(--line-bright); border-radius: 4px; font-size: 1.4rem; line-height: 1; }
.close-dialog:hover { background: #402a20; }
.dialog-copy { margin: 0 0 12px; color: var(--muted); font-size: .91rem; line-height: 1.5; }
.dialog-fields { display: grid; gap: 10px; }
.roster-editor { display: grid; min-width: 0; gap: 6px; margin: 0; padding: 7px 9px 9px; border: 1px solid var(--line); border-radius: 4px; }
.roster-editor legend { padding-inline: 4px; color: var(--gold-light); font-weight: 750; font-size: .89rem; }
.roster-edit-row { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 7px; }
.roster-edit-row .form-control { min-width: 0; width: 100%; min-height: 36px; padding: 6px 8px; }
.roster-field-head { color: var(--muted); font-size: .81rem; }
.field { min-width: 0; display: grid; gap: 5px; font-size: .88rem; color: var(--muted); }
.field input, .field select, .field textarea { width: 100%; min-width: 0; }
.field input[type="file"] { padding: 7px; }
.field textarea { min-height: 76px; resize: vertical; }
.field .check { width: auto; min-height: 0; justify-self: start; vertical-align: middle; }
.field-error { color: #ffb3a9; font-size: .84rem; line-height: 1.4; margin: 5px 0 0; }
[aria-invalid="true"] { border-color: #f18e81 !important; }
.dialog-actions { display: flex; justify-content: end; align-items: center; gap: 8px; margin-top: 17px; }
.series-summary { display: flex; justify-content: space-between; align-items: center; gap: 8px; background: #160f0e; border: 1px solid var(--line); border-radius: 4px; padding: 8px 10px; margin-bottom: 11px; }
.series-summary > strong { color: var(--gold-light); }
.map-field { display: grid; grid-template-columns: minmax(0, 1.25fr) minmax(64px, .8fr) minmax(64px, .8fr); align-items: end; gap: 5px 8px; margin: 0; padding: 8px; border: 1px solid var(--line); border-radius: 4px; }
.map-field legend { color: var(--gold-light); padding-inline: 4px; font-size: .87rem; font-weight: 750; }
.map-field .field span { overflow-wrap: anywhere; }
.map-field .field-error, .map-field .map-inline { grid-column: 1 / -1; }
.map-inline { min-height: 0; color: var(--muted); font-size: .78rem; }
.map-inline:empty { display: none; }
.veto-log { margin-top: 11px; }
.veto-log summary { font-size: .9rem; font-weight: 700; color: var(--gold-light); cursor: pointer; margin-bottom: 6px; }
.veto-log p { white-space: pre-wrap; overflow-wrap: anywhere; color: var(--muted); font-size: .9rem; }
.veto-log ol { padding-left: 23px; color: var(--muted); font-size: .86rem; line-height: 1.5; }
.match-tabs { display: flex; gap: 7px; margin-bottom: 11px; padding-bottom: 10px; border-bottom: 1px solid var(--line); }
.match-tabs [aria-pressed="true"] { color: #25180f; background: var(--gold); border-color: var(--gold); }
.match-time { margin: 0 0 11px; color: var(--muted); font-size: .84rem; }
.schedule-editor { display: flex; flex-wrap: wrap; gap: 7px; align-items: end; padding: 8px 10px; border-radius: 4px; border: 1px solid var(--line); margin-bottom: 12px; }
.schedule-editor .field { flex: 1 1 205px; }
.veto-head { display: flex; justify-content: space-between; align-items: end; gap: 8px; flex-wrap: wrap; margin-bottom: 9px; }
.veto-head .dialog-copy { color: var(--gold-light); font-weight: 650; margin: 0; overflow-wrap: anywhere; }
.veto-first { min-width: min(100%, 150px); max-width: 100%; }
.veto-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(105px, 1fr)); gap: 6px; }
.veto-map { display: grid; align-content: center; text-align: left; gap: 4px; min-height: 59px; padding: 7px; border: 1px solid var(--line-bright); border-radius: 4px; background: #251b16; color: var(--ink); overflow-wrap: anywhere; }
.veto-map strong { font-size: .91rem; }
.veto-map span { color: var(--muted); font-size: .75rem; }
.veto-choice:hover { border-color: var(--gold); background: #3b281d; }
.veto-map.ban { background: #311c18; border-color: #674039; }
.veto-map.ban strong { text-decoration: line-through; color: #f2b4a9; }
.veto-map.pick, .veto-map.decider { border-color: #8f6842; background: #3a281b; color: var(--gold-light); }
.veto-tools { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 9px; }
#toast { position: fixed; z-index: 9; right: max(14px, calc((100vw - 1220px) / 2)); bottom: 15px; width: min(max-content, calc(100vw - 28px)); max-width: calc(100vw - 28px); padding: 10px 14px; border: 1px solid var(--line-bright); border-radius: 4px; background: #2a1c17; color: var(--gold-light); box-shadow: 0 9px 26px #080503a0; font-size: .92rem; }
#toast:empty { display: none; }

@media (max-width: 950px) {
  .wrap { width: calc(100% - 42px); }
  .hero-inner { min-height: 325px; }
}
@media (max-width: 700px) {
  .bracket-jumps { display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: 8px; }
  .wrap { width: calc(100% - 30px); }
  .header-inner { grid-template-columns: 1fr auto; gap: 1px 8px; padding-top: 7px; }
  .wordmark .brand-emblem { width: 29px; }
  .wordmark { font-size: .9rem; }
  .header-inner nav { grid-column: 1 / -1; grid-row: 2; min-height: 38px; justify-content: space-between; gap: 8px; }
  .header-inner nav a { font-size: .83rem; }
  .admin-toggle { min-height: 35px; padding: 6px 8px; font-size: .84rem; }
  .hero-inner { min-height: 280px; grid-template-columns: 1.15fr 1fr; gap: 5px; padding-block: 22px; }
  .hero h1 { font-size: clamp(2.2rem, 9.1vw, 4.3rem); }
  .hero h1 span { font-size: clamp(1.15rem, 5.4vw, 2.45rem); }
  .hero-art { min-height: 169px; }
  .hero-art .brand-emblem { width: min(76%, 194px); }
  .crest-outline { inset: 10% 3%; }
  .hero-eyebrow { font-size: .7rem; letter-spacing: .12em; margin-bottom: 12px; gap: 5px; }
  .hero-eyebrow i { width: 12px; }
  .hero-summary { font-size: .9rem; margin: 12px 0 15px; }
  .hero .button { min-height: 37px; padding-inline: 10px; }
  .sponsors { padding-top: 15px; }
  .main-content { padding-block: 25px 39px; }
  .main-content section { scroll-margin-top: 102px; }
  .main-content section + section { margin-top: 31px; }
  .group-grid { grid-template-columns: 1fr; gap: 12px; }
  .standings col.place { width: 32px; }
  .standings col.metric { width: 38px; }
  .edit-team { min-width: 27px; padding-inline: 1px; }
  .score-body { padding: 9px; }
  .score-team { gap: 6px; padding: 6px; }
  .score-team .team-badge { width: 29px; height: 29px; font-size: .73rem; }
  .score-team-name { font-size: .84rem; }
  .score-team > strong { font-size: 1.38rem; }
}
@media (max-width: 370px) {
  .bracket-jumps .button { font-size: .73rem; padding-inline: 6px; }
  .edit-team { min-width: auto; }
  .group-team .team-badge { width: 24px; height: 24px; font-size: .67rem; }
  .group-team { gap: 5px; }
  .schedule-match { grid-template-columns: minmax(0, 1fr); }
  .schedule-meta { display: flex; justify-content: space-between; }
  .map-field { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .map-field .field:first-of-type { grid-column: 1 / -1; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { scroll-behavior: auto !important; animation-duration: .001ms !important; transition-duration: .001ms !important; }
  .sponsor-viewport.is-animated { overflow-x: auto; }
  .sponsor-viewport.is-animated .sponsor-track { animation: none; }
  .sponsor-track [aria-hidden="true"] { display: none; }
}
