:root {
  color-scheme: light;
  --ink: #183a2c;
  --muted: #829084;
  --line: #e9ede5;
  --lime: #d9f36a;
  --green: #1f533c;
  font-family: Arial, Helvetica, sans-serif;
}

* { box-sizing: border-box; }
body { margin: 0; background: #f7f8f2; color: var(--ink); }
button, input, textarea, select { font: inherit; }
button, a { -webkit-tap-highlight-color: transparent; }
button { cursor: pointer; }
button:disabled { cursor: not-allowed; opacity: .58; }
a { color: inherit; text-decoration: none; }
h1, h2, h3, h4, p { margin-top: 0; }
.loading-screen, .loading-panel { display: grid; min-height: 45vh; place-items: center; color: #718074; }
.loading-screen { min-height: 100vh; }
.login-shell { display: grid; min-height: 100vh; grid-template-columns: minmax(0, 1.07fr) minmax(420px, .93fr); background: white; }
.login-story { position: relative; overflow: hidden; min-height: 100vh; background: #173a2c; color: white; }
.login-story::before { position: absolute; inset: 0; background: radial-gradient(ellipse at 79% 59%, rgba(119,162,85,.27), transparent 35%), linear-gradient(140deg, transparent 38%, rgba(3,25,16,.3)); content: ""; }
.story-inner { position: relative; display: flex; min-height: 100vh; flex-direction: column; justify-content: space-between; padding: 38px 9%; }
.brand { display: flex; align-items: center; gap: 12px; }
.brand-mark { display: grid; width: 42px; height: 42px; place-items: center; border-radius: 14px; background: var(--green); color: var(--lime); font-size: 23px; }
.brand b, .brand small { display: block; letter-spacing: .16em; }
.brand b { font-size: 13px; }
.brand small { margin-top: 3px; color: #93a295; font-size: 10px; }
.story-copy { max-width: 540px; padding: 90px 0 34px; }
.eyebrow, .panel-kicker { color: #83927f; font-size: 10px; font-weight: 800; letter-spacing: .16em; }
.eyebrow-light { color: var(--lime); }
.story-copy h1 { max-width: 530px; margin: 27px 0 18px; font-size: clamp(42px, 5vw, 68px); font-weight: 600; letter-spacing: -.055em; line-height: 1.06; }
.story-copy h1 em { color: var(--lime); font-style: normal; }
.story-copy p { max-width: 430px; color: rgba(255,255,255,.66); font-size: 16px; line-height: 1.8; }
.story-footnote { color: rgba(255,255,255,.58); font-size: 12px; }
.score-art { position: absolute; right: 4%; bottom: 11%; display: flex; align-items: center; gap: 14px; width: 290px; border: 1px solid rgba(255,255,255,.16); border-radius: 18px; padding: 17px; background: rgba(255,255,255,.1); box-shadow: 0 25px 55px rgba(0,0,0,.2); transform: rotate(-5deg); }
.score-art > span { display: grid; width: 42px; height: 42px; place-items: center; border-radius: 13px; background: var(--lime); font-size: 18px; }
.score-art small { display: block; color: rgba(255,255,255,.55); font-size: 8px; font-weight: 700; letter-spacing: .15em; }
.score-art strong { display: block; margin-top: 5px; color: white; font-size: 25px; }
.score-art i { color: #b7ce71; font-size: 11px; font-style: normal; }
.score-art > b { margin-left: auto; color: var(--lime); font-size: 12px; }
.login-form-side { display: grid; place-items: center; padding: 48px; }
.login-form-wrap { width: min(100%, 410px); }
.login-form-wrap h2 { margin: 9px 0; font-size: 31px; letter-spacing: -.04em; }
.login-form-wrap > p { margin-bottom: 27px; color: #758178; font-size: 14px; line-height: 1.6; }
.mobile-brand { display: none; margin-bottom: 40px; }
.stack-form, .form-grid { display: grid; gap: 13px; }
.field-label { display: block; color: #48594b; font-size: 11px; font-weight: 700; }
.text-field { display: block; width: 100%; min-height: 43px; margin-top: 7px; border: 1px solid #e5e9e1; border-radius: 9px; outline: none; padding: 0 12px; background: white; color: #1e3e30; font-size: 13px; }
textarea.text-field { min-height: 82px; padding: 11px 12px; resize: vertical; }
.text-field:focus { border-color: #82a681; box-shadow: 0 0 0 3px rgba(71,125,83,.1); }
.primary-button, .secondary-button, .quiet-button, .screen-button { display: inline-flex; min-height: 40px; align-items: center; justify-content: center; gap: 8px; border: 0; border-radius: 9px; padding: 0 14px; background: var(--green); color: white; font-size: 12px; font-weight: 700; transition: background .15s, transform .15s; }
.primary-button:hover:not(:disabled) { background: #28694a; transform: translateY(-1px); }
.secondary-button { border: 1px solid #e4e9e0; background: white; color: #395543; }
.secondary-button:hover:not(:disabled) { background: #f3f6ef; }
.quiet-button { min-height: 34px; background: #f7f1ed; color: #9c6257; }
.screen-button { min-height: 34px; border: 1px solid #e3e9e0; background: white; color: #3d5a45; font-size: 10px; }
.full-width { width: 100%; margin-top: 8px; }
.switch-auth { width: 100%; margin-top: 24px; border: 0; background: none; color: #526457; font-size: 12px; }
.switch-auth:hover { color: var(--green); }
.notice { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin: 12px 0; border-radius: 9px; padding: 11px 13px; font-size: 12px; }
.notice button { border: 0; background: transparent; color: currentColor; font-size: 18px; }
.notice-error { background: #fff1ed; color: #9e4d40; }
.notice-success { background: #edf6e9; color: #406641; }
.app-shell { display: flex; min-height: 100vh; }
.sidebar { position: fixed; z-index: 4; display: flex; width: 244px; height: 100vh; flex-direction: column; border-right: 1px solid var(--line); padding: 26px 22px 15px; background: white; }
.sidebar .brand-mark { background: var(--green); }
.sidebar-label { margin: 58px 6px 13px; color: #a0aaa0; font-size: 9px; font-weight: 800; letter-spacing: .16em; }
.nav-item { display: flex; align-items: center; gap: 12px; border-radius: 9px; padding: 13px; background: #eff5eb; color: #315940; font-size: 12px; font-weight: 700; }
.sidebar-bottom { margin-top: auto; }
.help-card { margin-bottom: 18px; border: 1px solid var(--line); border-radius: 13px; padding: 13px; background: #fbfcf9; font-size: 11px; }
.help-card p { margin: 6px 0 0; color: #899488; font-size: 10px; line-height: 1.6; }
.profile-row { display: flex; align-items: center; gap: 10px; border-top: 1px solid #edf0e9; padding: 14px 2px 0; }
.profile-row > span:nth-child(2) { min-width: 0; flex: 1; }
.profile-row b, .profile-row small { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.profile-row b { font-size: 10px; }
.profile-row small { margin-top: 4px; color: #9aa49a; font-size: 9px; }
.avatar { display: grid; width: 34px; height: 34px; flex: 0 0 auto; place-items: center; border-radius: 12px; background: #dbe8d5; color: #33593e; font-size: 13px; font-weight: 800; }
.avatar-small { width: 31px; height: 31px; border-radius: 50%; font-size: 11px; }
.icon-button { display: grid; width: 30px; height: 30px; place-items: center; border: 0; border-radius: 8px; background: transparent; color: #68786b; font-size: 18px; }
.icon-button:hover { background: #f1f4ee; }
.main-area { width: calc(100% - 244px); min-height: 100vh; margin-left: 244px; }
.main-area-full { width: 100%; margin-left: 0; }
.topbar { position: sticky; z-index: 3; top: 0; display: flex; min-height: 82px; align-items: center; justify-content: space-between; border-bottom: 1px solid var(--line); padding: 0 34px; background: rgba(255,255,255,.94); backdrop-filter: blur(10px); }
.breadcrumb { color: #9aa49a; font-size: 9px; font-weight: 800; letter-spacing: .12em; }
.topbar h1 { margin: 7px 0 0; font-size: 21px; letter-spacing: -.04em; }
.topbar-right { display: flex; align-items: center; gap: 15px; }
.live-indicator { display: flex; align-items: center; gap: 7px; color: #718273; font-size: 9px; font-weight: 800; letter-spacing: .09em; }
.live-indicator i, .status-live i, .live-badge i, .screen-buzzer-status i, .screen-live-pill i { width: 6px; height: 6px; border-radius: 50%; background: #71ac5f; box-shadow: 0 0 0 3px rgba(113,172,95,.12); }
.page-content { max-width: 1440px; margin: 0 auto; padding: 30px 34px 55px; }
.lobby-grid { display: grid; grid-template-columns: minmax(0, 1.5fr) minmax(270px, .78fr); align-items: start; gap: 24px; }
.section-heading, .panel-title-row, .event-heading, .event-heading-actions, .event-card-meta, .directory-page-heading, .directory-toolbar, .directory-detail-heading, .judge-header, .judge-timer-control { display: flex; align-items: center; justify-content: space-between; gap: 14px; }
.section-heading { align-items: end; margin-bottom: 18px; }
.section-heading h2, .event-heading h2 { margin: 8px 0 5px; font-size: 27px; letter-spacing: -.045em; }
.section-heading p, .event-heading p, .directory-page-heading p { margin: 0; color: var(--muted); font-size: 11px; line-height: 1.6; }
.count-pill { border-radius: 20px; padding: 7px 10px; background: #f0f3eb; color: #72816f; font-size: 8px; font-weight: 900; letter-spacing: .1em; white-space: nowrap; }
.event-list { display: grid; gap: 10px; }
.event-card { display: flex; width: 100%; align-items: center; gap: 14px; border: 1px solid #e9ede5; border-radius: 13px; padding: 15px; background: white; color: var(--ink); text-align: left; }
.event-card:hover { border-color: #cbd9c5; box-shadow: 0 8px 22px rgba(22,57,38,.06); }
.event-symbol, .empty-icon { display: grid; width: 41px; height: 41px; flex: 0 0 auto; place-items: center; border-radius: 13px; background: #eff5e9; font-size: 18px; }
.event-card-copy { display: grid; min-width: 0; flex: 1; gap: 6px; }
.event-card-copy > strong { font-size: 13px; }
.event-card-copy > small { overflow: hidden; color: #839084; font-size: 10px; text-overflow: ellipsis; white-space: nowrap; }
.event-card-meta { justify-content: flex-start; color: #738172; font-size: 9px; }
.event-arrow { color: #92a08e; font-size: 18px; }
.status-tag { display: inline-flex; align-items: center; gap: 6px; border-radius: 20px; padding: 5px 8px; background: #f2f3ef; color: #7a8578; font-size: 8px; font-weight: 800; white-space: nowrap; }
.status-live { background: #eaf5e5; color: #4a7842; }
.status-finished { background: #f5ece8; color: #956154; }
.empty-panel, .create-card, .panel-card, .control-panel { border: 1px solid #e9ede5; border-radius: 14px; padding: 19px; background: white; }
.empty-panel { display: grid; justify-items: start; gap: 11px; padding: 26px; }
.empty-panel strong { font-size: 13px; }
.empty-panel p, .create-card p, .muted-copy { margin: 0 0 14px; color: #899488; font-size: 10px; line-height: 1.7; }
.create-card h3, .panel-card h3 { margin: 8px 0 8px; font-size: 16px; letter-spacing: -.025em; }
.card-overline { color: #638057; font-size: 9px; font-weight: 900; letter-spacing: .13em; }
.optional { color: #a0aaa0; font-weight: 400; }
.selected-event { display: flex; align-items: center; justify-content: space-between; margin: 10px 0; border-radius: 8px; padding: 10px; background: #f2f6ec; font-size: 11px; }
.selected-event button { border: 0; background: none; color: #557550; font-size: 10px; }
.back-link { display: inline-flex; align-items: center; gap: 7px; margin: 0 0 17px; border: 0; background: transparent; color: #718173; font-size: 11px; }
.event-heading { align-items: flex-start; margin: 4px 0 19px; }
.event-heading h2 { font-size: 29px; }
.event-heading-actions { align-items: flex-start; }
.join-code { margin-top: 9px !important; color: #738172 !important; font-size: 10px !important; }
.join-code b { color: #315940; letter-spacing: .12em; }
.event-section-tabs, .directory-tabs { display: flex; gap: 7px; margin: 17px 0; border-bottom: 1px solid var(--line); }
.event-section-tab, .directory-tabs button { display: inline-flex; align-items: center; gap: 7px; border: 0; border-bottom: 2px solid transparent; padding: 11px 12px; background: transparent; color: #718173; font-size: 10px; font-weight: 700; }
.event-section-tab.active, .directory-tabs button.active { border-bottom-color: #60915c; color: #315940; }
.workspace-grid { display: grid; grid-template-columns: minmax(0, 1.2fr) minmax(300px, .8fr); align-items: start; gap: 18px; }
.workspace-column { display: grid; gap: 17px; }
.panel-title-row { align-items: flex-start; margin-bottom: 13px; }
.panel-title-row h3, .panel-title-row h2 { margin: 5px 0 0; font-size: 17px; }
.button-row, .judge-controls { display: flex; flex-wrap: wrap; gap: 8px; }
.active-question { border: 1px solid #edf0e9; border-radius: 11px; padding: 15px; background: #fbfcf9; }
.active-question-top { display: flex; align-items: center; justify-content: space-between; color: #72816f; font-size: 10px; }
.live-badge { display: inline-flex; align-items: center; gap: 7px; color: #7e897c; font-size: 8px; font-weight: 900; letter-spacing: .08em; }
.live-badge-open { color: #4d8142; }
.active-question-text, .participant-question { min-height: 55px; padding: 18px 0; color: #475b49; font-size: 14px; line-height: 1.7; }
.answer-reveal { display: grid; gap: 5px; margin: 10px 0; border-radius: 9px; padding: 10px; background: #eef5e8; color: #416844; font-size: 11px; }
.answer-reveal small { font-size: 8px; font-weight: 900; letter-spacing: .12em; }
.winner-callout { display: flex; align-items: center; gap: 8px; margin: 10px 0; border-radius: 9px; padding: 10px; background: #fff9e6; color: #81652f; font-size: 11px; }
.round-list, .team-cards, .score-list, .tournament-round-list, .directory-people-list { display: grid; gap: 8px; }
.round-item, .score-row, .member-row, .directory-member-row, .directory-person-row, .match-teams > div, .judge-match-teams > div { display: flex; align-items: center; justify-content: space-between; gap: 12px; border-bottom: 1px solid #edf0e9; padding: 9px 2px; font-size: 11px; }
.round-item span, .member-row small, .score-row small, .directory-member-row small, .directory-person-row small { color: #869187; font-size: 9px; }
.compact-form { margin-top: 15px; border-top: 1px solid #edf0e9; padding-top: 14px; }
.compact-form h4 { margin: 0; font-size: 12px; }
.two-fields { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.score-row { justify-content: flex-start; min-height: 50px; }
.score-row .rank { display: grid; width: 27px; height: 27px; place-items: center; border-radius: 8px; background: #f1f5eb; color: #5d7954; font-size: 9px; font-weight: 900; }
.score-row > div { display: grid; flex: 1; gap: 4px; }
.score-row > strong { color: #52714c; }
.team-card { border: 1px solid #edf0e9; border-radius: 10px; padding: 12px; }
.team-card > div:first-child { display: grid; gap: 5px; }
.team-card > div:first-child small, .team-card > small { color: #879286; font-size: 9px; }
.member-row { padding: 7px 0; }
.member-row span { flex: 1; }
.tournament-round { margin-top: 12px; border: 1px solid #edf0e9; border-radius: 10px; padding: 12px; }
.tournament-round-heading, .match-heading { display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.tournament-round-heading > div { display: grid; gap: 5px; }
.tournament-round-heading small { color: #899488; font-size: 9px; line-height: 1.5; }
.tournament-status { border-radius: 20px; padding: 5px 8px; background: #f1f3ed; color: #738172; font-size: 8px; }
.match-card { display: grid; gap: 8px; margin-top: 11px; border-top: 1px solid #edf0e9; padding-top: 10px; }
.match-heading { color: #49624d; font-size: 10px; }
.match-teams { display: grid; }
.match-teams > div { font-size: 10px; }
.match-teams b { margin-left: auto; color: #607658; }
.choice-list { display: grid; gap: 8px; border-radius: 9px; padding: 11px; background: #f8faf5; font-size: 10px; }
.choice-list label { display: flex; align-items: center; gap: 8px; }
.next-match { margin-top: 13px; }
.next-match p { color: #69786a; font-size: 11px; }
.participant-event { display: grid; max-width: 1180px; gap: 16px; }
.participant-hero { display: flex; align-items: center; justify-content: space-between; border-radius: 15px; padding: 20px; background: #1f533c; color: white; }
.participant-hero h3 { margin: 8px 0; font-size: 19px; }
.participant-hero p { display: flex; align-items: center; gap: 8px; margin: 0; color: #c0d0bb; font-size: 10px; }
.participant-score { font-size: 28px; font-weight: 800; }
.participant-score small { font-size: 10px; }
.buzzer-button { width: 100%; min-height: 70px; border: 0; border-radius: 12px; background: #d9f36a; color: #1e462f; font-size: 20px; font-weight: 900; letter-spacing: .08em; }
.buzzer-button:disabled { background: #e7ebdf; color: #9ba397; }
.mini-empty { display: flex; min-height: 100px; align-items: center; justify-content: center; gap: 9px; color: #899488; font-size: 11px; text-align: center; }
.directory-page { min-height: 350px; }
.directory-page-heading { align-items: flex-start; }
.directory-page-heading h3 { margin: 6px 0; }
.directory-toolbar { margin: 15px 0; }
.directory-toolbar .directory-tabs { margin: 0; }
.directory-toolbar > .text-field { width: min(320px, 48%); }
.directory-tabs button { border-bottom: 0; }
.directory-team-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(185px, 1fr)); gap: 10px; }
.directory-team-card, .directory-person-row { display: flex; align-items: center; gap: 9px; border: 1px solid #e9ede5; border-radius: 10px; padding: 13px; background: white; color: var(--ink); text-align: left; }
.directory-team-card { display: grid; }
.directory-team-card small { color: #899488; font-size: 9px; }
.directory-team-card strong { color: #52714c; font-size: 11px; }
.directory-person-row { width: 100%; }
.directory-person-row > span:nth-child(2) { display: grid; flex: 1; gap: 5px; }
.directory-detail-heading { justify-content: flex-start; margin: 18px 0; }
.directory-avatar { display: grid; width: 48px; height: 48px; place-items: center; border-radius: 14px; background: #eff5e9; font-size: 20px; }
.directory-detail-heading h3 { margin: 5px 0; }
.directory-detail-heading p { margin: 0; color: #899488; font-size: 10px; }
.directory-stats { display: grid; grid-template-columns: repeat(4, 1fr); gap: 8px; margin: 17px 0; }
.directory-stats > div { display: grid; gap: 8px; border: 1px solid #edf0e9; border-radius: 9px; padding: 11px; }
.directory-stats span { color: #899488; font-size: 8px; font-weight: 800; }
.directory-stats b { font-size: 12px; }
.directory-member-row > div { display: grid; flex: 1; gap: 5px; }
.question-bank-page { max-width: 1440px; margin: auto; padding: 24px 34px 50px; }
.question-bank-heading { display: flex; align-items: center; justify-content: space-between; gap: 15px; margin: 10px 0 20px; }
.question-bank-heading h1 { margin: 8px 0; font-size: 27px; }
.question-bank-heading p { max-width: 690px; color: #899488; font-size: 11px; line-height: 1.6; }
.question-bank-total { display: grid; justify-items: center; gap: 5px; border: 1px solid var(--line); border-radius: 12px; padding: 13px 20px; }
.question-bank-total b { font-size: 23px; }
.question-bank-total span { color: #899488; font-size: 9px; }
.question-bank-layout { display: grid; grid-template-columns: minmax(0, 1.55fr) minmax(260px, .75fr); align-items: start; gap: 16px; }
.question-bank-toolbar { display: grid; grid-template-columns: minmax(180px, 1.5fr) minmax(135px, 1fr) minmax(130px, .9fr) auto; align-items: end; gap: 8px; margin-bottom: 14px; }
.question-bank-items { display: grid; grid-template-columns: repeat(auto-fill, minmax(235px, 1fr)); gap: 9px; }
.question-bank-item { border: 1px solid #edf0e9; border-radius: 10px; padding: 12px; }
.question-bank-item-top { display: flex; align-items: center; gap: 7px; }
.question-bank-number { color: #9aa493; font-size: 9px; font-weight: 800; }
.question-bank-category { border-radius: 20px; padding: 4px 8px; background: #f1f5eb; color: #668056; font-size: 8px; font-weight: 700; }
.question-bank-status { margin-left: auto; border-radius: 20px; padding: 4px 8px; background: #f3f4f1; color: #879084; font-size: 8px; }
.question-bank-item h4 { margin: 9px 0 5px; color: #465847; font-size: 12px; line-height: 1.55; }
.question-bank-answer { color: #82907f; font-size: 10px; line-height: 1.5; }
.question-bank-item-footer { display: flex; align-items: center; justify-content: space-between; gap: 8px; border-top: 1px solid #f0f2ed; padding-top: 8px; color: #9aa396; font-size: 8px; }
.question-bank-pagination, .question-bank-pagination > div { display: flex; align-items: center; justify-content: space-between; gap: 8px; }
.question-bank-pagination { margin-top: 14px; color: #8d988b; font-size: 9px; }
.question-bank-pagination .secondary-button { min-height: 31px; padding: 0 8px; font-size: 9px; }
.question-bank-note { margin: 12px 0 0; color: #899583; font-size: 9px; line-height: 1.6; }
.question-bank-page .compact-form { display: grid; gap: 12px; }
.live-screen { min-height: 100vh; padding: 0 4vw; background: #152f26; color: #ecf1e4; }
.live-header { display: flex; min-height: 82px; align-items: center; justify-content: space-between; gap: 16px; border-bottom: 1px solid rgba(255,255,255,.1); }
.live-brand { display: flex; align-items: center; gap: 10px; }
.live-brand b, .live-brand small { display: block; }
.live-brand b { font-size: 11px; letter-spacing: .12em; }
.live-brand small { margin-top: 4px; color: #91a28e; font-size: 8px; letter-spacing: .16em; }
.live-event-title { display: grid; gap: 5px; text-align: center; }
.live-event-title span { color: #91a28e; font-size: 8px; font-weight: 800; letter-spacing: .14em; }
.live-event-title b { font-size: 13px; }
.live-header-right { display: flex; align-items: center; gap: 14px; }
.live-audio-toggle { border: 1px solid rgba(217,243,106,.3); border-radius: 8px; padding: 9px; background: rgba(217,243,106,.08); color: var(--lime); font-size: 8px; font-weight: 800; }
.live-audio-enabled { background: rgba(217,243,106,.2); }
.live-clock { color: #d6e0d1; font-size: 15px; font-variant-numeric: tabular-nums; }
.screen-live-pill { display: flex; align-items: center; gap: 7px; border-radius: 20px; padding: 7px 10px; background: rgba(113,172,95,.1); color: #a9ce9e; font-size: 8px; font-weight: 900; }
.live-layout { display: grid; grid-template-columns: minmax(0, 1.7fr) minmax(260px, .7fr); gap: 18px; padding: 22px 0; }
.live-main { display: flex; flex-direction: column; }
.live-round-line { display: flex; align-items: center; gap: 10px; color: #c7d7bd; font-size: 9px; font-weight: 900; letter-spacing: .13em; }
.live-round-rule { height: 1px; flex: 1; background: rgba(255,255,255,.12); }
.screen-buzzer-status { display: flex; align-items: center; gap: 7px; color: #96a596; }
.screen-buzzer-open { color: var(--lime); }
.live-question-card { display: flex; min-height: 320px; flex: 1; flex-direction: column; justify-content: center; margin-top: 14px; border: 1px solid rgba(238,242,219,.13); border-radius: 19px; padding: clamp(24px, 4vw, 50px); background: radial-gradient(ellipse at 88% 7%, rgba(155,191,90,.16), transparent 37%), linear-gradient(145deg, #204736, #18372d 75%); }
.live-question-label { display: flex; align-items: center; justify-content: space-between; color: var(--lime); font-size: 9px; font-weight: 900; letter-spacing: .2em; }
.live-countdown { display: flex; align-items: center; gap: 9px; border: 1px solid rgba(217,243,106,.32); border-radius: 10px; padding: 9px 13px; background: rgba(217,243,106,.1); color: var(--lime); }
.live-countdown small { font-size: 8px; }
.live-countdown b { font-size: 23px; font-variant-numeric: tabular-nums; }
.live-countdown-low { color: #ff9a83; }
.live-question-text { max-width: 940px; margin: 24px 0; color: #fbfbf1; font-size: clamp(26px, 4vw, 51px); font-weight: 600; letter-spacing: -.045em; line-height: 1.2; }
.live-question-footer { display: flex; gap: 25px; border-top: 1px solid rgba(255,255,255,.1); padding-top: 15px; color: #8ca693; font-size: 8px; font-weight: 800; letter-spacing: .12em; }
.live-buzzer-winner, .live-buzzer-ready { display: flex; min-height: 82px; align-items: center; gap: 15px; margin-top: 13px; border: 1px solid rgba(217,243,106,.21); border-radius: 14px; padding: 14px 17px; background: rgba(217,243,106,.07); }
.live-buzzer-winner > span, .live-buzzer-ready > span { display: grid; width: 40px; height: 40px; place-items: center; border-radius: 12px; background: var(--lime); color: #173a2c; font-size: 18px; }
.live-buzzer-winner > div { display: grid; flex: 1; gap: 5px; }
.live-buzzer-winner small { color: #a8bd98; font-size: 9px; font-weight: 800; letter-spacing: .1em; }
.live-buzzer-winner b { color: #f5f6e8; font-size: 23px; }
.live-buzzer-winner strong { color: var(--lime); font-size: 9px; }
.live-buzzer-ready { border-color: rgba(255,255,255,.1); background: rgba(255,255,255,.035); }
.live-buzzer-ready > span { background: rgba(217,243,106,.11); color: var(--lime); }
.live-buzzer-ready div { display: grid; gap: 5px; }
.live-buzzer-ready b { color: #dae8ce; font-size: 10px; }
.live-buzzer-ready small { color: #829987; font-size: 9px; }
.live-bottom-stats { display: flex; flex-wrap: wrap; gap: 20px; padding: 15px 2px 0; color: #8ba18e; font-size: 8px; font-weight: 800; letter-spacing: .08em; }
.live-score-panel { border: 1px solid rgba(255,255,255,.1); border-radius: 16px; padding: 18px; background: rgba(255,255,255,.045); }
.live-score-heading span { color: #a6bc91; font-size: 8px; font-weight: 900; letter-spacing: .16em; }
.live-score-heading h2 { margin: 6px 0 0; color: #f1f3e8; font-size: 18px; }
.live-score-list { display: grid; margin-top: 12px; }
.live-score-row { display: grid; min-height: 56px; grid-template-columns: 31px minmax(0, 1fr) auto; align-items: center; gap: 10px; border-bottom: 1px solid rgba(255,255,255,.075); padding: 7px 4px; }
.live-score-row-leader { border-radius: 10px; background: rgba(217,243,106,.09); padding-right: 9px; padding-left: 9px; }
.live-score-rank { display: grid; width: 28px; height: 28px; place-items: center; border: 1px solid rgba(255,255,255,.09); border-radius: 9px; color: #a0b29d; font-size: 9px; font-weight: 900; }
.live-score-row-leader .live-score-rank { background: var(--lime); color: #24432e; }
.live-score-team { display: grid; gap: 4px; overflow: hidden; }
.live-score-team b { overflow: hidden; color: #e6ecdf; font-size: 10px; text-overflow: ellipsis; white-space: nowrap; }
.live-score-team small { color: #8ea48f; font-size: 8px; }
.live-score-row > strong { color: var(--lime); font-size: 13px; white-space: nowrap; }
.live-score-row > strong small { color: #91a28d; font-size: 7px; }
.score-panel-footer { padding-top: 13px; color: #809780; font-size: 7px; font-weight: 900; letter-spacing: .1em; }
.live-no-scores { display: grid; min-height: 190px; place-items: center; color: #9aa998; font-size: 10px; }
.live-footer { display: flex; min-height: 45px; align-items: center; justify-content: space-between; gap: 10px; border-top: 1px solid rgba(255,255,255,.08); color: #738a79; font-size: 7px; font-weight: 800; letter-spacing: .09em; }
.live-error { padding: 8px; background: #55342d; color: #ffe4d8; font-size: 10px; text-align: center; }
.live-tournament-match { display: grid; gap: 7px; margin-top: 12px; border-radius: 10px; padding: 13px; background: rgba(217,243,106,.07); color: #c7d7bd; font-size: 10px; }
.live-tournament-match > span { display: flex; justify-content: space-between; }
.judge-screen { min-height: 100vh; padding: 25px max(4vw, 18px); background: #f7f8f2; }
.judge-header { margin-bottom: 18px; }
.judge-header h1 { margin: 5px 0 0; font-size: 20px; }
.judge-back { color: #65796a; font-size: 10px; }
.judge-grid { display: grid; grid-template-columns: minmax(0, 1.2fr) minmax(300px, .8fr); align-items: start; gap: 15px; }
.judge-card { display: grid; gap: 13px; }
.judge-card h2 { font-size: 17px; }
.judge-question { min-height: 85px; border-radius: 11px; padding: 18px; background: #f4f7ef; color: #3e5742; font-size: 17px; line-height: 1.6; }
.judge-question-meta { color: #899488; font-size: 9px; }
.judge-timer-control { justify-content: flex-start; flex-wrap: wrap; }
.judge-timer-control .field-label { width: min(270px, 100%); }
.judge-countdown { color: #5a734d; font-size: 20px; font-variant-numeric: tabular-nums; }
.judge-match-teams { display: grid; }
.judge-match-teams > div { padding: 12px 3px; }
.judge-match-teams > div > span { display: grid; gap: 4px; }
.judge-match-teams small { color: #859084; font-size: 9px; }
.judge-next-match, .judge-empty { color: #778476; font-size: 11px; }
.judge-next-match p { line-height: 1.6; }
.live-buzzer-ready + * { margin-top: 0; }

@media (max-width: 1000px) {
  .sidebar { width: 200px; }
  .main-area { width: calc(100% - 200px); margin-left: 200px; }
  .workspace-grid, .question-bank-layout { grid-template-columns: 1fr; }
  .live-layout { grid-template-columns: minmax(0, 1fr) 260px; }
}
@media (max-width: 760px) {
  .login-shell { grid-template-columns: 1fr; }
  .login-story { display: none; }
  .mobile-brand { display: flex; }
  .login-form-side { min-height: 100vh; padding: 28px; }
  .sidebar { display: none; }
  .main-area, .main-area-full { width: 100%; margin: 0; }
  .topbar { min-height: 70px; padding: 0 18px; }
  .page-content { padding: 21px 16px 40px; }
  .lobby-grid, .workspace-grid, .judge-grid, .live-layout { grid-template-columns: 1fr; }
  .lobby-grid { gap: 18px; }
  .event-heading, .section-heading, .directory-page-heading { align-items: flex-start; flex-direction: column; }
  .event-section-tabs { overflow-x: auto; }
  .event-section-tab { white-space: nowrap; }
  .live-screen { padding: 0 16px; }
  .live-header { flex-wrap: wrap; padding: 12px 0; }
  .live-event-title { order: 3; width: 100%; text-align: left; }
  .live-header-right { gap: 8px; }
  .live-audio-toggle { max-width: 44px; overflow: hidden; white-space: nowrap; }
  .live-question-card { min-height: 270px; }
  .live-footer { flex-wrap: wrap; justify-content: center; padding: 10px 0; }
}
@media (max-width: 520px) {
  .section-heading h2, .event-heading h2 { font-size: 23px; }
  .event-card { padding: 11px; }
  .event-card-copy > small { white-space: normal; }
  .event-card-meta { flex-wrap: wrap; }
  .two-fields, .directory-stats { grid-template-columns: 1fr 1fr; }
  .question-bank-page { padding: 18px 12px 35px; }
  .question-bank-heading { align-items: flex-start; }
  .question-bank-toolbar { grid-template-columns: 1fr 1fr; }
  .question-bank-toolbar .text-field:first-child { grid-column: 1 / -1; }
  .question-bank-pagination, .question-bank-pagination > div { flex-wrap: wrap; justify-content: center; }
  .directory-toolbar { align-items: flex-start; flex-direction: column; }
  .directory-toolbar > .text-field { width: 100%; }
  .live-question-footer { flex-direction: column; gap: 8px; }
  .live-buzzer-winner { flex-wrap: wrap; }
  .live-buzzer-winner strong { width: 100%; }
  .judge-header { align-items: flex-start; flex-wrap: wrap; }
}
