:root {
  color-scheme: dark;
  --ink: #0b0d0c;
  --surface: #131614;
  --surface-2: #1a1e1b;
  --line: #303631;
  --paper: #f2f3ed;
  --muted: #9da49d;
  --acid: #dfff3f;
  --orange: #ff6746;
  --blue: #70a5ff;
  --radius: 4px;
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}
* { box-sizing: border-box; }
html { background: var(--ink); scroll-behavior: smooth; }
body { margin: 0; min-height: 100vh; background: var(--ink); color: var(--paper); }
button, input, select, textarea { font: inherit; }
button, a { -webkit-tap-highlight-color: transparent; }
a { color: inherit; }
.eyebrow { margin: 0 0 .8rem; color: var(--acid); font-size: .72rem; font-weight: 800; letter-spacing: .13em; text-transform: uppercase; }
.button { display: inline-flex; min-height: 42px; align-items: center; justify-content: center; border: 1px solid var(--line); border-radius: var(--radius); padding: .68rem .95rem; background: transparent; color: var(--paper); font-weight: 750; text-decoration: none; cursor: pointer; }
.button:hover { border-color: var(--paper); }
.button-primary { border-color: var(--acid); background: var(--acid); color: var(--ink); }
.button-secondary { background: var(--surface-2); }
.button-danger { border-color: var(--orange); color: var(--orange); }
.button-quiet { color: var(--muted); }
.button-large { min-height: 52px; padding-inline: 1.3rem; }
.text-button { border: 0; padding: .3rem 0; background: none; color: var(--muted); text-decoration: underline; cursor: pointer; }
.back-link { color: var(--muted); font-size: .88rem; text-decoration: none; }
.compact-brand { font-size: .88rem; font-weight: 900; letter-spacing: -.03em; text-decoration: none; }
.compact-brand em { color: var(--acid); font-style: normal; }
.flash { position: sticky; z-index: 3; top: .5rem; margin: .5rem auto 1rem; border: 1px solid; padding: .85rem 1rem; background: var(--ink); font-weight: 700; }
.flash-success { border-color: var(--acid); color: var(--acid); }
.flash-error { border-color: var(--orange); color: var(--orange); }
.empty-note, .help-text { color: var(--muted); line-height: 1.6; }

.identity-page { display: grid; min-height: 100vh; grid-template-rows: auto 1fr; }
.event-mark { position: relative; display: grid; grid-template-columns: 1fr auto; border-bottom: 1px solid var(--line); padding: 1.2rem; }
.event-kicker { grid-column: 1 / -1; margin-bottom: 1rem; color: var(--muted); font-size: .65rem; font-weight: 700; letter-spacing: .15em; text-transform: uppercase; }
.event-wordmark { font-size: clamp(2.5rem, 13vw, 5.5rem); font-weight: 950; letter-spacing: -.085em; line-height: .76; }
.event-year { align-self: end; color: var(--acid); font-size: 1.25rem; font-weight: 900; writing-mode: vertical-rl; }
.identity-panel { align-self: end; border-top: 1px solid var(--line); padding: 2rem 1.2rem 2.5rem; }
.identity-panel h1 { margin: 0 0 2rem; font-size: clamp(2.6rem, 14vw, 5rem); letter-spacing: -.06em; line-height: .94; }
.identity-panel h1 span { color: var(--acid); }
.participant-picker { display: grid; }
.participant-picker button { display: grid; grid-template-columns: 2.4rem 1fr auto; align-items: center; border: 0; border-top: 1px solid var(--line); padding: 1rem 0; background: none; color: var(--paper); text-align: left; cursor: pointer; }
.participant-picker button:last-child { border-bottom: 1px solid var(--line); }
.participant-picker button span { color: var(--muted); font-size: .72rem; font-variant-numeric: tabular-nums; }
.participant-picker button b { color: var(--acid); }
.participant-picker button:hover { color: var(--acid); }
.choice-actions { display: flex; gap: .7rem; }

.portal-page { width: min(100%, 920px); margin: auto; }
.portal-header { display: flex; align-items: center; justify-content: space-between; border-bottom: 1px solid var(--line); padding: 1rem 1.2rem; }
.portal-header .text-button { font-size: .72rem; }
.portal-hero { padding: 4rem 1.2rem 1.5rem; }
.portal-hero h1 { margin: 0 0 3.5rem; font-size: clamp(3.2rem, 16vw, 7rem); letter-spacing: -.07em; line-height: .86; }
.current-discipline { border-left: 5px solid var(--acid); padding: .3rem 0 .3rem 1rem; }
.current-discipline span, .current-discipline small { display: block; color: var(--muted); font-size: .7rem; letter-spacing: .08em; text-transform: uppercase; }
.current-discipline strong { display: block; margin: .25rem 0; font-size: clamp(1.5rem, 7vw, 2.7rem); letter-spacing: -.04em; }
.schedule { padding: 3.5rem 1.2rem; }
.section-heading { display: flex; align-items: end; justify-content: space-between; gap: 1rem; margin-bottom: 1.3rem; }
.section-heading .eyebrow { margin: 0; }
.section-heading h1, .section-heading h2 { margin: 0; font-size: clamp(2rem, 8vw, 3.5rem); letter-spacing: -.055em; }
.section-heading sup { color: var(--acid); font-size: .7rem; }
.discipline-list { margin: 0; padding: 0; list-style: none; }
.discipline-list li { display: grid; grid-template-columns: 2.5rem 1fr auto; gap: .5rem; align-items: center; min-height: 76px; border-top: 1px solid var(--line); }
.discipline-list li:last-child { border-bottom: 1px solid var(--line); }
.discipline-number { color: var(--muted); font-size: .72rem; }
.discipline-list strong, .discipline-list small { display: block; }
.discipline-list strong { font-size: 1rem; }
.discipline-list small { margin-top: .25rem; color: var(--muted); font-size: .68rem; text-transform: uppercase; }
.discipline-list a { color: var(--muted); font-size: .72rem; text-decoration: none; }
.discipline-list a span { color: var(--acid); }
.discipline-list li[data-status="in_progress"] { border-left: 4px solid var(--acid); padding-left: .8rem; }
.discipline-list li[data-status="in_progress"] .discipline-status { color: var(--acid); }
.discipline-list li[data-status="completed"] { opacity: .58; }

.placeholder-page { display: flex; min-height: 100vh; flex-direction: column; padding: 1.2rem; }
.placeholder-page section { margin: auto 0; }
.placeholder-page h1 { max-width: 900px; margin: 0; font-size: clamp(3.5rem, 15vw, 9rem); letter-spacing: -.075em; line-height: .84; }
.placeholder-page section > p:not(.eyebrow) { max-width: 40rem; color: var(--muted); font-size: 1.1rem; line-height: 1.6; }
.live-pill { display: inline-block; border: 1px solid var(--acid); padding: .45rem .7rem; color: var(--acid); font-size: .72rem; font-weight: 800; text-transform: uppercase; }

.screen-shell { overflow: hidden; }
.screen-app { display: grid; width: 100vw; min-height: 100vh; grid-template-rows: auto 1fr auto; padding: 3vh 4vw; }
.screen-header, .screen-footer { display: flex; justify-content: space-between; color: var(--muted); font-size: clamp(.65rem, 1vw, 1rem); font-weight: 850; letter-spacing: .14em; }
.screen-header b { color: var(--acid); }
.screen-content { display: flex; min-height: 0; flex-direction: column; align-items: center; justify-content: center; text-align: center; }
.screen-kicker { margin: 0 0 2vh; color: var(--acid); font-size: clamp(.85rem, 1.4vw, 1.5rem); font-weight: 800; letter-spacing: .14em; text-transform: uppercase; }
.screen-title { max-width: 90vw; margin: 0; font-size: clamp(4rem, 10vw, 11rem); letter-spacing: -.075em; line-height: .86; }
.screen-subtitle { margin: 3vh 0 0; color: var(--muted); font-size: clamp(1.4rem, 2.6vw, 3rem); }
.ceremony-title { font-size: clamp(3rem, 7vw, 8rem); }
.ceremony-results { display: grid; width: min(90vw, 1250px); max-height: 55vh; grid-template-columns: repeat(2, 1fr); gap: 0 3vw; margin: 3vh 0 0; padding: 0; list-style: none; overflow: hidden; }
.ceremony-results li { display: grid; grid-template-columns: 4vw 1fr auto; align-items: center; border-top: 1px solid var(--line); padding: 1.2vh 0; text-align: left; }
.result-rank { color: var(--acid); font-size: clamp(1.2rem, 2vw, 2.5rem); font-weight: 900; }
.result-name { font-size: clamp(1.1rem, 2vw, 2.3rem); }
.result-value { color: var(--muted); font-size: clamp(.8rem, 1.25vw, 1.4rem); }
.standings-reveal { display: flex; max-width: 900px; flex-direction: column; }
.winner-rank { color: var(--acid); font-size: clamp(5rem, 12vw, 13rem); font-weight: 950; line-height: .8; }
.winner-name { margin: 1vh 0; font-size: clamp(5rem, 13vw, 14rem); letter-spacing: -.08em; line-height: .8; }
.winner-score { color: var(--muted); font-size: clamp(1.5rem, 2.4vw, 3rem); }

.admin-shell { background: #0e100f; }
.admin-header { position: sticky; z-index: 4; top: 0; display: flex; align-items: center; justify-content: space-between; border-bottom: 1px solid var(--line); padding: .8rem 1rem; background: rgba(11, 13, 12, .96); }
.admin-header div small { display: block; margin-top: .18rem; color: var(--muted); font-size: .65rem; }
.admin-header nav { display: flex; align-items: center; gap: 1rem; }
.admin-header nav a, .admin-header > a { color: var(--muted); font-size: .75rem; text-decoration: none; }
.admin-page { width: min(100%, 1100px); margin: auto; padding: 1rem; }
.admin-section { margin: 1rem 0; border: 1px solid var(--line); padding: 1rem; background: var(--surface); }
.admin-section > h1 { margin: 0; font-size: clamp(2.3rem, 8vw, 4.5rem); letter-spacing: -.06em; }
.status-banner { display: grid; grid-template-columns: 1fr; border-left: 5px solid var(--muted); padding: 1rem; background: var(--ink); }
.status-banner span, .status-banner small { color: var(--muted); font-size: .72rem; text-transform: uppercase; }
.status-banner strong { margin: .25rem 0; font-size: 1.8rem; }
.status-in_progress { border-color: var(--acid); }
.status-finished { border-color: var(--blue); }
.action-row { display: flex; flex-wrap: wrap; gap: .5rem; margin-top: 1rem; }
.action-row.compact { margin-top: auto; }
.admin-disciplines { display: grid; gap: .7rem; }
.admin-discipline { display: flex; min-height: 175px; flex-direction: column; border-top: 3px solid var(--line); padding: 1rem; background: var(--ink); }
.admin-discipline.is-in_progress { border-color: var(--acid); }
.admin-discipline.is-completed { opacity: .78; }
.discipline-topline { display: flex; justify-content: space-between; color: var(--muted); font-size: .7rem; text-transform: uppercase; }
.admin-discipline h3 { margin: .8rem 0 1.5rem; font-size: 1.35rem; line-height: 1.05; }
.tiebreak-form { display: grid; gap: .6rem; margin-top: 1rem; border-top: 1px solid var(--line); padding-top: 1rem; }
.tiebreak-form label, .add-participant label, .login-card label { display: grid; gap: .4rem; color: var(--muted); font-size: .7rem; font-weight: 750; text-transform: uppercase; }
input, select, textarea { width: 100%; min-height: 44px; border: 1px solid var(--line); border-radius: 2px; padding: .65rem .75rem; outline: 0; background: var(--ink); color: var(--paper); }
input:focus, select:focus, textarea:focus { border-color: var(--acid); }
textarea { resize: vertical; line-height: 1.5; }
.add-participant { display: grid; gap: .7rem; border-bottom: 1px solid var(--line); padding-bottom: 1rem; }
.participant-admin-list form { display: grid; grid-template-columns: 2rem 1fr; gap: .6rem; align-items: center; border-bottom: 1px solid var(--line); padding: .8rem 0; }
.participant-admin-list form > span { color: var(--muted); font-size: .7rem; }
.toggle { display: flex; align-items: center; gap: .5rem; color: var(--muted); font-size: .7rem; }
.toggle input { position: absolute; opacity: 0; pointer-events: none; }
.toggle i { position: relative; width: 34px; height: 20px; border: 1px solid var(--line); border-radius: 20px; }
.toggle i::after { position: absolute; top: 3px; left: 3px; width: 12px; height: 12px; border-radius: 50%; background: var(--muted); content: ""; transition: transform .15s; }
.toggle input:checked + i { border-color: var(--acid); }
.toggle input:checked + i::after { background: var(--acid); transform: translateX(14px); }
.table-wrap { overflow-x: auto; }
table { width: 100%; border-collapse: collapse; font-size: .85rem; }
th, td { border-bottom: 1px solid var(--line); padding: .75rem .55rem; text-align: left; white-space: nowrap; }
th { color: var(--muted); font-size: .65rem; text-transform: uppercase; }
.warning-tag { color: var(--orange); font-size: .7rem; font-weight: 800; }
.ceremony-control > p { color: var(--muted); }
.result-editor { margin-top: 1.5rem; }
.result-editor label { display: grid; grid-template-columns: 1fr minmax(110px, 30%); gap: 1rem; align-items: center; border-bottom: 1px solid var(--line); padding: .8rem 0; }
.result-editor label span b, .result-editor label span small { display: block; }
.result-editor label span small { margin-top: .25rem; color: var(--muted); font-size: .7rem; }
.result-row { display: grid; grid-template-columns: 1fr minmax(180px, 40%); gap: 1rem; align-items: center; border-bottom: 1px solid var(--line); padding: .8rem 0; }
.result-row span b, .result-row span small { display: block; }
.result-row span small { margin-top: .25rem; color: var(--muted); font-size: .7rem; }
.result-row output { color: var(--ink); text-align: right; }
.sticky-actions { position: sticky; bottom: 0; display: flex; justify-content: flex-end; gap: .5rem; border-top: 1px solid var(--line); padding: .8rem 0; background: var(--surface); }
.login-page { display: grid; min-height: 100vh; place-items: center; padding: 1rem; }
.login-card { width: min(100%, 420px); border: 1px solid var(--line); padding: 1.2rem; background: var(--surface); }
.login-card h1 { margin: 0 0 2rem; font-size: 2.4rem; letter-spacing: -.05em; }
.login-card .button { width: 100%; margin: 1rem 0; }

.word-config-section > h1 { margin: 0; font-size: clamp(3.5rem, 12vw, 7rem); letter-spacing: -.075em; line-height: .85; }
.word-config-form { display: grid; gap: 1rem; margin-top: 2rem; }
.word-config-form label { display: grid; gap: .45rem; color: var(--muted); font-size: .72rem; font-weight: 750; text-transform: uppercase; }
.word-config-form label:first-of-type { max-width: 220px; }
.word-config-form label small { font-weight: 500; text-transform: none; }
.word-config-form label small b { color: var(--acid); }
.config-lock-note { border-left: 4px solid var(--orange); padding: .8rem 1rem; background: var(--ink); color: var(--orange); font-weight: 750; }

.five-letters-shell { min-height: 100vh; }
.five-letters-page { width: min(100%, 760px); margin: auto; padding-bottom: 3rem; }
.game-header { display: grid; grid-template-columns: 1fr auto 1fr; align-items: center; border-bottom: 1px solid var(--line); padding: 1rem 1.2rem; }
.game-header > span { color: var(--muted); font-size: .72rem; text-align: right; }
.five-letters-game { padding: 2.5rem 1rem 1rem; }
.game-title-row { display: flex; align-items: end; justify-content: space-between; gap: 1rem; }
.game-title-row h1 { margin: 0; font-size: clamp(3.7rem, 16vw, 7rem); letter-spacing: -.08em; line-height: .78; }
.word-progress { color: var(--acid); font-size: 1.2rem; font-weight: 900; font-variant-numeric: tabular-nums; }
.game-status { min-height: 1.5rem; margin: 2rem 0 1rem; color: var(--muted); font-size: .85rem; }
.game-status.is-error { color: var(--orange); }
.round-history { display: flex; gap: .4rem; margin-bottom: 1rem; overflow-x: auto; scrollbar-width: thin; }
.round-chip { flex: 0 0 auto; border: 1px solid var(--line); padding: .45rem .6rem; color: var(--muted); font-size: .68rem; font-weight: 750; text-transform: uppercase; }
.round-chip.is-solved { border-color: var(--acid); color: var(--acid); }
.round-chip.is-missed { border-color: var(--orange); color: var(--orange); }
.letter-board { display: grid; gap: .35rem; width: min(100%, 350px); margin: 1.3rem auto; }
.letter-row { display: grid; grid-template-columns: repeat(5, 1fr); gap: .35rem; }
.letter-tile { display: grid; aspect-ratio: 1; place-items: center; border: 2px solid var(--line); background: var(--surface); font-size: clamp(1.35rem, 7vw, 2.2rem); font-weight: 900; text-transform: uppercase; }
.letter-tile:not(:empty) { border-color: #616a62; }
.letter-tile.is-correct { border-color: #78950d; background: #78950d; color: #fff; }
.letter-tile.is-present { border-color: #b68a12; background: #b68a12; color: #fff; }
.letter-tile.is-absent { border-color: #3c423d; background: #3c423d; color: #fff; }
.guess-form { width: min(100%, 520px); margin: 1rem auto; }
.guess-form > label, .guess-form > small { display: block; color: var(--muted); font-size: .68rem; }
.guess-form > label { margin-bottom: .4rem; font-weight: 750; text-transform: uppercase; }
.guess-form > div { display: grid; grid-template-columns: 1fr auto; gap: .5rem; }
.guess-form input { font-size: 1.15rem; font-weight: 850; letter-spacing: .2em; text-transform: uppercase; }
.guess-form > small { margin-top: .35rem; }
.letter-keyboard { display: grid; gap: .35rem; width: min(100%, 660px); margin: 1.5rem auto 0; }
.letter-keyboard > div { display: flex; justify-content: center; gap: .2rem; }
.letter-keyboard button { min-width: 0; height: 42px; flex: 1; border: 0; border-radius: 3px; padding: 0 .15rem; background: #454b46; color: var(--paper); font-size: clamp(.57rem, 2.5vw, .78rem); font-weight: 850; cursor: pointer; }
.letter-keyboard button.wide-key { flex: 1.55; font-size: .57rem; }
.letter-keyboard button.is-correct { background: #78950d; }
.letter-keyboard button.is-present { background: #b68a12; }
.letter-keyboard button.is-absent { background: #252925; color: #777e78; }
.letter-keyboard button:disabled { cursor: default; }
.game-summary { margin: 3rem auto; border-top: 5px solid var(--acid); padding: 1.2rem; background: var(--surface); text-align: center; }
.game-summary p, .game-summary span { display: block; margin: 0; color: var(--muted); }
.game-summary strong { display: block; margin: .5rem 0; font-size: clamp(4rem, 18vw, 7rem); letter-spacing: -.08em; line-height: .85; }

.archive-shell { background: var(--paper); color: var(--ink); --line: #c8cbc3; --muted: #60665f; }
.archive-page { width: min(100%, 1000px); margin: auto; padding: 1rem; }
.archive-hero { min-height: 82vh; display: flex; flex-direction: column; justify-content: center; border-bottom: 1px solid var(--line); }
.archive-hero h1 { margin: 0; font-size: clamp(4.5rem, 18vw, 11rem); letter-spacing: -.09em; line-height: .7; }
.archive-hero span { margin-top: 2rem; color: var(--muted); font-weight: 750; }
.podium-section, .archive-disciplines { padding: 5rem 0; }
.final-standings { margin: 0; padding: 0; list-style: none; }
.final-standings li { display: grid; grid-template-columns: 3rem 1fr auto; align-items: center; border-top: 1px solid var(--line); padding: 1rem 0; }
.final-standings li > span { font-size: 1.8rem; font-weight: 950; }
.final-standings li > a { font-size: 1.15rem; font-weight: 800; text-decoration: none; }
.final-standings li > b small { color: var(--muted); }
.final-standings .place-1 { border-top: 5px solid var(--ink); padding: 2rem 0; }
.final-standings .place-1 > span { color: #a1b600; font-size: 3rem; }
.final-standings .place-1 > a { font-size: 2rem; }
.archive-disciplines details { border-top: 1px solid var(--line); }
.archive-disciplines details:last-child { border-bottom: 1px solid var(--line); }
.archive-disciplines summary { display: grid; grid-template-columns: 3rem 1fr auto; align-items: center; padding: 1.2rem 0; cursor: pointer; list-style: none; }
.archive-disciplines summary::-webkit-details-marker { display: none; }
.archive-disciplines summary > span { color: var(--muted); font-size: .7rem; }
.archive-disciplines summary > b { font-size: 1.5rem; }
.archive-disciplines details[open] summary > b { transform: rotate(45deg); }
.archive-shell table a { font-weight: 700; text-decoration: none; }
.participant-result-page { width: min(100%, 760px); margin: auto; padding: 1.2rem; }
.participant-result-page header { padding: 7rem 0 3rem; }
.participant-result-page h1 { margin: 0; font-size: clamp(3.7rem, 15vw, 7.5rem); letter-spacing: -.08em; line-height: .85; }
.participant-total { display: flex; align-items: center; gap: 1rem; margin-top: 2.5rem; }
.participant-total > span { font-size: 5rem; font-weight: 950; line-height: .8; }
.participant-total p, .participant-total small { margin: 0; display: block; color: var(--muted); }
.participant-results { margin: 0 0 5rem; padding: 0; list-style: none; }
.participant-results li { display: grid; grid-template-columns: 2.5rem 1fr auto; align-items: center; border-top: 1px solid var(--line); padding: 1rem 0; }
.participant-results li > span, .participant-results small { color: var(--muted); font-size: .7rem; }
.participant-results li div b, .participant-results li div small, .participant-results li > strong small { display: block; }
.participant-results li > strong { text-align: right; }

.platform-shell { min-height: 100vh; background: radial-gradient(circle at 82% 8%, rgba(223, 255, 63, .09), transparent 30rem), var(--ink); }
.platform-nav { position: relative; z-index: 4; display: flex; min-height: 72px; align-items: center; justify-content: space-between; gap: 1rem; border-bottom: 1px solid var(--line); padding: .85rem 1.2rem; }
.platform-nav nav { display: flex; align-items: center; gap: 1rem; }
.platform-nav nav > a { color: var(--muted); font-size: .8rem; text-decoration: none; }
.platform-nav nav > .button { color: var(--ink); }
.platform-nav form { margin: 0; }
.platform-logo { font-size: .95rem; font-weight: 950; letter-spacing: -.045em; text-decoration: none; }
.platform-logo em { color: var(--acid); font-style: normal; }
.platform-page, .dashboard-page, .create-page { width: min(100%, 1180px); margin: auto; padding-inline: 1.2rem; }
.platform-hero { min-height: min(760px, calc(100vh - 72px)); display: flex; flex-direction: column; justify-content: center; border-bottom: 1px solid var(--line); padding: 5rem 0; }
.platform-hero h1 { max-width: 1100px; margin: 0; font-size: clamp(3.6rem, 10vw, 8.8rem); font-weight: 950; letter-spacing: -.085em; line-height: .78; }
.platform-hero h1 span { color: var(--acid); }
.platform-lead { max-width: 620px; margin: 2.5rem 0 0; color: var(--muted); font-size: clamp(1rem, 2vw, 1.35rem); line-height: 1.55; }
.platform-actions { display: flex; flex-wrap: wrap; gap: .7rem; margin-top: 2rem; }
.platform-feature-strip { display: grid; border-bottom: 1px solid var(--line); }
.platform-feature-strip article { min-height: 190px; border-bottom: 1px solid var(--line); padding: 1.4rem 0; }
.platform-feature-strip article:last-child { border-bottom: 0; }
.platform-feature-strip span { color: var(--acid); font-size: .7rem; font-weight: 850; }
.platform-feature-strip b { display: block; margin: 2.5rem 0 .5rem; font-size: 1.15rem; }
.platform-feature-strip p { margin: 0; color: var(--muted); line-height: 1.5; }
.platform-tournaments { padding: 6rem 0; }
.tournament-grid { display: grid; gap: .8rem; }
.tournament-card { min-height: 280px; display: flex; flex-direction: column; border: 1px solid var(--line); padding: 1.2rem; background: var(--surface); text-decoration: none; }
.tournament-card:hover { border-color: var(--acid); }
.tournament-card h3 { margin: 2.8rem 0 .6rem; font-size: 2rem; letter-spacing: -.05em; }
.tournament-card p { margin: 0; color: var(--muted); line-height: 1.5; }
.tournament-card > b { margin-top: auto; color: var(--acid); }
.tournament-card-status { width: fit-content; border: 1px solid var(--line); padding: .35rem .5rem; color: var(--muted); font-size: .65rem; font-weight: 800; text-transform: uppercase; }
.tournament-card-status.status-in_progress { border-color: var(--acid); color: var(--acid); }
.tournament-card-status.status-finished { border-color: var(--blue); color: var(--blue); }

.auth-layout { position: relative; display: grid; width: min(100%, 1180px); min-height: 100vh; margin: auto; padding: 1.2rem; }
.auth-layout > .platform-logo { position: absolute; top: 1.2rem; left: 1.2rem; }
.auth-intro { align-self: end; padding: 7rem 0 3rem; }
.auth-intro h1 { margin: 0; font-size: clamp(4rem, 14vw, 8rem); letter-spacing: -.085em; line-height: .78; }
.auth-intro > p:last-child { max-width: 430px; color: var(--muted); line-height: 1.55; }
.auth-card { align-self: center; display: grid; gap: 1rem; border: 1px solid var(--line); padding: 1.2rem; background: var(--surface); }
.auth-card h2 { margin: 0 0 1rem; font-size: 2.7rem; letter-spacing: -.06em; }
.auth-card label, .create-form label { display: grid; gap: .45rem; color: var(--muted); font-size: .7rem; font-weight: 750; text-transform: uppercase; }
.auth-card label small, .create-form label small { font-weight: 500; text-transform: none; }
.auth-card > p:last-child { margin: 0; color: var(--muted); font-size: .8rem; }
.auth-card > p:last-child a { color: var(--paper); }
.code-input { font-size: 2rem; font-weight: 900; letter-spacing: .22em; text-align: center; font-variant-numeric: tabular-nums; }

.dashboard-page { padding-top: 4rem; padding-bottom: 6rem; }
.dashboard-heading { display: flex; flex-wrap: wrap; align-items: end; justify-content: space-between; gap: 1.5rem; border-bottom: 1px solid var(--line); padding-bottom: 2rem; }
.dashboard-heading h1 { margin: 0; font-size: clamp(3.6rem, 10vw, 7rem); letter-spacing: -.08em; line-height: .8; }
.dashboard-list { display: grid; gap: .8rem; padding-top: 1rem; }
.dashboard-tournament { display: grid; gap: 2rem; border: 1px solid var(--line); padding: 1.2rem; background: var(--surface); }
.dashboard-tournament h2 { margin: 1.6rem 0 .4rem; font-size: clamp(1.8rem, 5vw, 3rem); letter-spacing: -.055em; }
.dashboard-tournament p { margin: 0; color: var(--muted); }
.dashboard-tournament-actions { display: flex; flex-wrap: wrap; align-items: end; gap: .6rem; }
.dashboard-empty { border: 1px dashed var(--line); padding: 4rem 1.2rem; text-align: center; }
.dashboard-empty > span { color: var(--acid); font-size: 4rem; font-weight: 950; }
.dashboard-empty h2 { margin: .5rem 0; font-size: 2rem; }
.dashboard-empty p { margin: 0 auto 1.5rem; color: var(--muted); }

.create-page { padding-top: 4rem; padding-bottom: 7rem; }
.create-heading { border-bottom: 1px solid var(--line); padding-bottom: 3rem; }
.create-heading h1 { margin: 0; font-size: clamp(4rem, 11vw, 8rem); letter-spacing: -.085em; line-height: .78; }
.create-form { display: grid; }
.create-form > .flash { width: 100%; }
.create-section { display: grid; grid-template-columns: 2.5rem 1fr; gap: 1rem; border-bottom: 1px solid var(--line); padding: 3rem 0; }
.create-step { color: var(--acid); font-size: .75rem; font-weight: 900; }
.create-section h2 { margin: 0 0 2rem; font-size: clamp(2rem, 6vw, 3.4rem); letter-spacing: -.06em; }
.create-section label { margin-top: 1rem; }
.check-row { grid-template-columns: auto 1fr !important; align-items: start; border: 1px solid var(--line); padding: 1rem; cursor: pointer; }
.check-row input, .discipline-picker input { width: 20px; min-height: 20px; margin: 0; accent-color: var(--acid); }
.check-row span b, .check-row span small { display: block; }
.check-row span b { color: var(--paper); }
.check-row span small { margin-top: .3rem; }
.discipline-picker { display: grid; gap: .55rem; }
.discipline-picker label { position: relative; display: block; margin: 0; cursor: pointer; }
.discipline-picker input { position: absolute; top: 1rem; right: 1rem; z-index: 1; }
.discipline-picker label > span { display: grid; grid-template-columns: 2.5rem 1fr; border: 1px solid var(--line); padding: 1rem 3.2rem 1rem 1rem; background: var(--surface); }
.discipline-picker label > span i { grid-row: 1 / 3; color: var(--muted); font-style: normal; }
.discipline-picker label > span b { color: var(--paper); font-size: 1rem; text-transform: none; }
.discipline-picker label > span small { margin-top: .25rem; color: var(--muted); }
.discipline-picker input:checked + span { border-color: var(--acid); box-shadow: inset 4px 0 var(--acid); }
.discipline-picker input:focus-visible + span { outline: 2px solid var(--blue); outline-offset: 2px; }
.create-submit { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 1rem; padding-top: 2rem; }
.create-submit p { margin: 0; color: var(--muted); }

@media (min-width: 700px) {
  .identity-page { grid-template-columns: 1fr 1fr; grid-template-rows: 1fr; }
  .event-mark { grid-template-rows: auto 1fr; border-right: 1px solid var(--line); border-bottom: 0; padding: 2rem; }
  .event-wordmark { align-self: end; font-size: min(7vw, 7rem); }
  .identity-panel { align-self: stretch; display: flex; flex-direction: column; justify-content: center; border-top: 0; padding: 4rem; }
  .identity-panel h1 { font-size: min(7vw, 6rem); }
  .portal-header { padding: 1.2rem 2rem; }
  .portal-hero, .schedule { padding-inline: 2rem; }
  .discipline-list strong { font-size: 1.15rem; }
  .admin-disciplines { grid-template-columns: repeat(2, 1fr); }
  .admin-section { padding: 1.5rem; }
  .status-banner { grid-template-columns: 8rem 1fr auto; align-items: center; }
  .participant-admin-list form { grid-template-columns: 2rem 1fr 140px auto; }
  .add-participant { grid-template-columns: 1fr auto; align-items: end; }
  .tiebreak-form { grid-template-columns: 1fr auto; align-items: end; }
  .five-letters-game { padding: 4rem 2rem 2rem; }
  .letter-keyboard button { height: 48px; }
  .platform-nav { padding-inline: 2rem; }
  .platform-feature-strip { grid-template-columns: repeat(3, 1fr); }
  .platform-feature-strip article { border-right: 1px solid var(--line); border-bottom: 0; padding: 1.5rem; }
  .platform-feature-strip article:last-child { border-right: 0; }
  .tournament-grid { grid-template-columns: repeat(2, 1fr); }
  .auth-layout { grid-template-columns: 1fr minmax(360px, 450px); gap: 4rem; padding: 2rem; }
  .auth-layout > .platform-logo { top: 2rem; left: 2rem; }
  .auth-intro { align-self: center; padding: 6rem 0 0; }
  .auth-card { padding: 2rem; }
  .dashboard-tournament { grid-template-columns: 1fr auto; align-items: end; padding: 1.5rem; }
  .create-section { grid-template-columns: 5rem minmax(0, 760px); gap: 2rem; padding: 4rem 0; }
  .discipline-picker { grid-template-columns: repeat(2, 1fr); }
}
@media (min-width: 1000px) {
  .admin-disciplines { grid-template-columns: repeat(3, 1fr); }
  .archive-page { padding-inline: 2rem; }
  .tournament-grid { grid-template-columns: repeat(3, 1fr); }
}
@media (prefers-reduced-motion: reduce) { * { scroll-behavior: auto !important; transition: none !important; } }
