:root {
  color-scheme: light;
  --white: #fff;
  --surface: #f7f7f8;
  --ink: #111;
  --muted: #666;
  --rule: #d6d6d8;
  --blue: #002fa7;
  --green: #008f4c;
  --rail: 16.75rem;
  --header: 4.5rem;
  --preview-banner: 2.5rem;
  --unread-notice: 2.75rem;
  font-family: "Helvetica Neue", Helvetica, Arial, sans-serif;
  color: var(--ink);
  background: var(--white);
}

:root[data-theme="dark"] {
  color-scheme: dark;
  --white: #0b0d12;
  --surface: #151821;
  --ink: #f7f7f8;
  --muted: #a9acb5;
  --rule: #343844;
  --blue: #82a7ff;
  --green: #5ee09b;
}

* { box-sizing: border-box; }
html { min-width: 20rem; }
body { margin: 0; min-height: 100vh; background: var(--white); font-size: 1rem; line-height: 1.5; }
body:not(.has-banner) { --preview-banner: 0px; }
body:not(.has-unread-notice) { --unread-notice: 0px; }
button, input, select { font: inherit; }
a { color: inherit; }
button { color: inherit; }

.skip-link { position: fixed; left: 1rem; top: -5rem; z-index: 100; background: var(--blue); color: var(--white); padding: .75rem 1rem; }
.skip-link:focus { top: 1rem; }
:focus-visible { outline: 3px solid var(--blue); outline-offset: 3px; }
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; border: 0; }
.icon { display: block; width: 1.75rem; height: 1.75rem; flex: 0 0 auto; }

.preview-banner {
  position: fixed; inset: 0 0 auto 0; z-index: 60; min-height: 2.5rem; display: flex; align-items: center;
  justify-content: center; gap: .75rem; padding: .55rem 1.25rem; background: var(--banner-background, var(--blue)); color: var(--banner-foreground, var(--white)); text-align: center;
}
.preview-banner strong { text-transform: uppercase; letter-spacing: .08em; }
.preview-banner span { font-size: .875rem; }
.preview-banner[hidden] { display: none; }
.admin-config-status { max-width: 100%; overflow: auto; padding: 1rem; border: 1px solid var(--rule); background: var(--surface); font-size: .82rem; line-height: 1.5; }
.unread-notice { position: fixed; inset: var(--preview-banner) 0 auto 0; z-index: 55; min-height: 2.75rem; display: flex; align-items: center; justify-content: center; gap: 1rem; padding: .55rem 1.25rem; background: var(--ink); color: var(--white); font-size: .875rem; text-align: center; }
.unread-notice[hidden] { display: none; }
.unread-notice a { font-weight: 700; text-underline-offset: .2em; }
.unread-notice a:hover { text-decoration-thickness: 2px; }

.masthead {
  position: fixed; inset: calc(var(--preview-banner) + var(--unread-notice)) 0 auto 0; z-index: 30; height: var(--header); display: flex; align-items: center;
  gap: 1.25rem; padding: 0 1.5rem; background: var(--white); border-bottom: 1px solid var(--rule);
}
.brand { display: inline-flex; align-items: center; gap: .65rem; font-size: 1.3rem; font-weight: 700; letter-spacing: -.045em; text-decoration: none; white-space: nowrap; }
.brand::before { display: block; width: .35rem; height: 1.6rem; background: var(--ink); content: ""; }
.version { color: var(--muted); font-size: .72rem; font-variant-numeric: tabular-nums; }
.back-button, .menu-button, .icon-button { border: 0; background: transparent; cursor: pointer; }
.back-button { padding: .45rem; }
.back-button svg, .disclosure svg { width: 1.5rem; height: 1.5rem; fill: none; stroke: currentColor; stroke-width: 2; }
.breadcrumbs { display: flex; align-items: center; gap: .65rem; min-width: 0; color: var(--muted); font-size: .85rem; }
.breadcrumbs span[aria-current="page"] { overflow: hidden; color: var(--ink); font-weight: 600; text-overflow: ellipsis; white-space: nowrap; }
.breadcrumbs a { text-decoration: none; }
.breadcrumbs a:hover { color: var(--blue); text-decoration: underline; text-underline-offset: .2em; }
.session-preview { margin-left: auto; display: flex; align-items: center; gap: .75rem; font-variant-numeric: tabular-nums; }
.session-email { max-width: 14rem; overflow: hidden; color: var(--muted); font-size: .82rem; text-overflow: ellipsis; white-space: nowrap; }
.exercise-badge, .utc-clock { padding: .45rem .65rem; border: 1px solid var(--rule); color: var(--ink); font-size: .82rem; }
.exercise-badge { max-width: 14rem; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.team-view-form { display: flex; align-items: center; gap: .4rem; white-space: nowrap; }
.team-view-label { color: var(--muted); font-size: .82rem; }
.team-view-menu { position: relative; min-width: 6.7rem; }
.team-view-menu summary { display: flex; align-items: center; justify-content: space-between; gap: .75rem; min-height: 2.55rem; max-width: 9rem; padding: .4rem .7rem; border: 1px solid var(--blue); color: var(--blue); cursor: pointer; list-style: none; }
.team-view-menu summary::-webkit-details-marker { display: none; }
.team-view-menu summary::after { width: .45rem; height: .45rem; flex: 0 0 auto; border-right: 2px solid currentColor; border-bottom: 2px solid currentColor; content: ""; transform: translateY(-.15rem) rotate(45deg); }
.team-view-menu[open] summary { background: var(--surface); }
.team-view-menu[open] summary::after { transform: translateY(.1rem) rotate(225deg); }
.team-view-menu summary span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.team-view-options { position: absolute; z-index: 70; top: calc(100% + .35rem); right: 0; min-width: 100%; max-height: min(18rem, 60vh); overflow-y: auto; padding: .25rem; border: 1px solid var(--blue); background: var(--white); box-shadow: 0 5px 14px rgb(0 0 0 / 14%); }
.team-view-options button { display: flex; width: 100%; align-items: center; justify-content: space-between; gap: 1rem; min-height: 2.5rem; padding: .45rem .6rem; border: 0; background: var(--white); color: var(--ink); text-align: left; cursor: pointer; }
.team-view-options button:hover, .team-view-options button:focus-visible { background: var(--surface); color: var(--blue); }
.team-view-options button[aria-current="true"] { background: var(--surface); color: var(--blue); font-weight: 700; }
.team-view-options button[aria-current="true"]::after { width: .4rem; height: .4rem; flex: 0 0 auto; background: var(--blue); content: ""; }
.utc-clock { min-width: 6.8rem; text-align: center; }
.menu-button { display: none; width: 2.5rem; padding: .5rem; }
.menu-button span { display: block; height: 2px; margin: 5px 0; background: var(--ink); }

.side-rail {
  position: fixed; z-index: 20; left: 0; top: calc(var(--preview-banner) + var(--unread-notice) + var(--header)); bottom: 0; width: var(--rail); display: flex; flex-direction: column;
  background: var(--surface); border-right: 1px solid var(--rule); padding: 1.4rem .8rem 1rem;
}
.primary-nav { min-height: 0; display: flex; flex: 1 1 auto; flex-direction: column; gap: .1rem; overflow-y: auto; scrollbar-gutter: stable; }
.nav-entry { position: relative; display: grid; grid-template-columns: 1fr 2.5rem; }
.nav-link { min-height: 2.75rem; display: flex; align-items: center; gap: .8rem; padding: .5rem .7rem; text-decoration: none; font-size: .9rem; font-weight: 500; border-left: 3px solid transparent; }
.nav-link .icon { width: 1.25rem; height: 1.25rem; }
.nav-link:hover { color: var(--blue); background: var(--white); }
.nav-link.active { color: var(--blue); border-left-color: var(--blue); background: var(--white); font-weight: 700; }
.disclosure { grid-column: 2; grid-row: 1; border: 0; background: transparent; cursor: pointer; transition: transform 160ms ease; }
.disclosure[aria-expanded="true"] { transform: rotate(180deg); }
.disclosure.disabled { display: grid; place-items: center; color: var(--muted); cursor: help; }
.submenu { grid-column: 1 / -1; margin: 0 0 .35rem; }
.submenu a { min-height: 2.55rem; display: flex; align-items: center; justify-content: space-between; gap: .5rem; padding: .45rem .55rem .45rem 2.75rem; color: var(--muted); text-decoration: none; font-size: .82rem; font-weight: 500; }
.submenu a:hover { background: var(--white); color: var(--blue); }
.submenu a[aria-current="page"] { color: var(--blue); background: var(--white); font-weight: 700; }
.submenu .icon { width: 1.2rem; height: 1.2rem; }
.rail-footer { position: relative; z-index: 1; flex: 0 0 auto; margin-top: auto; display: grid; gap: .1rem; border-top: 1px solid var(--rule); padding-top: .75rem; }
.rail-footer .submenu a { min-height: 3.2rem; font-size: .95rem; }
.admin-rail-entry .submenu { position: absolute; right: 0; bottom: 100%; left: 0; max-height: min(19rem, 55vh); margin: 0; overflow-y: auto; border: 1px solid var(--rule); background: var(--white); }
.theme-selector { display: grid; grid-template-columns: 1.75rem 1fr auto; gap: 1.8rem; }
.theme-selector:hover { color: var(--blue); }
.theme-switch { position: relative; display: inline-flex; flex: 0 0 auto; }
.theme-switch input { position: absolute; width: 1px; height: 1px; margin: -1px; overflow: hidden; opacity: 0; }
.theme-switch-track { width: 2.6rem; height: 1.45rem; display: flex; align-items: center; padding: .2rem; border: 1px solid var(--rule); border-radius: 999px; background: var(--surface); transition: border-color 160ms ease, background 160ms ease; }
.theme-switch-track span { width: .95rem; height: .95rem; display: block; border-radius: 50%; background: var(--muted); transition: background 160ms ease, transform 160ms ease; }
.theme-selector:hover .theme-switch-track { border-color: var(--blue); }
.theme-switch input:checked + .theme-switch-track { border-color: var(--blue); background: var(--blue); }
.theme-switch input:checked + .theme-switch-track span { background: var(--white); transform: translateX(1.1rem); }
.theme-switch input:focus-visible + .theme-switch-track { outline: 3px solid var(--blue); outline-offset: 3px; }
.logout-form { width: 100%; margin: 0; }
.rail-action { width: 100%; appearance: none; border-top: 0; border-right: 0; border-bottom: 0; background: transparent; color: var(--ink); cursor: pointer; font: inherit; text-align: left; }
.rail-action:hover { color: var(--blue); }
.drawer-scrim { display: none; }

.content { margin-left: var(--rail); padding-top: calc(var(--preview-banner) + var(--unread-notice) + var(--header)); min-height: 100vh; }
h1 { margin: 0; font-size: clamp(2.8rem, 6vw, 5.25rem); font-weight: 500; letter-spacing: -.055em; line-height: 1; }
.empty-state { margin: 0 5vw; padding: 4rem 0; max-width: 42rem; }
.page-placeholder { margin-right: auto; margin-left: auto; text-align: center; }
.empty-state-image { display: block; width: min(100%, 30rem); height: auto; margin: 2rem auto; border: 1px solid var(--rule); }
.empty-state h2, .empty-state h3 { margin: 0 0 1rem; font-size: 1.4rem; font-weight: 500; }
.empty-state p { color: var(--muted); line-height: 1.6; margin: 0; }
.home-hero { min-height: 25rem; display: grid; grid-template-columns: minmax(0, 1.7fr) minmax(15rem, .65fr); border-bottom: 1px solid var(--rule); }
.home-welcome { display: flex; flex-direction: column; justify-content: flex-end; padding: clamp(2rem, 5vw, 4.25rem); border-top: 4px solid var(--ink); }
.home-eyebrow { margin: 0 0 1.25rem; color: var(--ink); font-size: .72rem; font-weight: 700; letter-spacing: .1em; text-transform: uppercase; }
.home-welcome h1 { max-width: 13ch; }
.home-summary { max-width: 32rem; margin: 1.4rem 0 0; color: var(--muted); font-size: 1rem; line-height: 1.6; }
.current-phase { display: flex; flex-direction: column; justify-content: space-between; min-height: 25rem; padding: 1.5rem; background: var(--ink); color: var(--white); }
.current-phase span { font-size: .78rem; font-weight: 700; letter-spacing: .12em; text-transform: uppercase; }
.current-phase strong { align-self: flex-end; font-size: clamp(7rem, 15vw, 12rem); font-weight: 500; letter-spacing: -.09em; line-height: .8; }
.phase-schedule { padding: clamp(2rem, 5vw, 4rem); }
.phase-schedule > header { display: flex; align-items: baseline; justify-content: space-between; gap: 2rem; margin-bottom: 2rem; }
.phase-schedule h2 { margin: 0; font-size: 1.5rem; font-weight: 500; }
.phase-schedule > header p { margin: 0; color: var(--muted); font-size: .85rem; }
.phase-list { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); margin: 0; padding: 0; border-top: 1px solid var(--rule); border-left: 1px solid var(--rule); list-style: none; }
.phase-card { position: relative; min-height: 11rem; display: flex; flex-direction: column; justify-content: space-between; padding: 1.25rem; border-right: 1px solid var(--rule); border-bottom: 1px solid var(--rule); }
.phase-card.is-current { color: var(--ink); background: var(--surface); box-shadow: inset 0 4px 0 var(--ink); }
.phase-number { color: var(--muted); font-size: .8rem; font-variant-numeric: tabular-nums; }
.phase-card h3 { margin: 0 0 .4rem; font-size: 1.25rem; font-weight: 500; }
.phase-card p { margin: 0; color: var(--muted); font-size: .9rem; font-variant-numeric: tabular-nums; }
.phase-status { position: absolute; top: 1.15rem; right: 1.15rem; padding: .25rem .45rem; background: var(--ink); color: var(--white); font-size: .7rem; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; }

.page-toolbar { min-height: 7rem; display: flex; align-items: center; gap: 1.5rem; padding: 1.5rem clamp(1.25rem, 3vw, 3rem); border-bottom: 1px solid var(--rule); border-top: 4px solid var(--ink); background: var(--surface); }
.page-toolbar h1 { font-size: clamp(1.8rem, 3vw, 2.55rem); font-weight: 600; letter-spacing: -.045em; line-height: 1.1; }
.scoring-toolbar { justify-content: space-between; }
.scoring-actions { display: flex; align-items: center; gap: .75rem; }
.scoring-actions .icon-button { color: var(--ink); }
.scoring-categories-link { color: var(--ink); font-size: .85rem; font-weight: 700; text-decoration: none; }
.scoring-categories-link:hover, .scoring-categories-link:focus-visible, .scoring-actions .icon-button:hover { color: var(--blue); }
.scoring-results { padding-top: 3rem; }
.scoring-table-region { width: 100%; overflow-x: auto; outline: 0; }
.scoring-table-region:focus-visible { box-shadow: inset 0 0 0 3px var(--blue); }
.scoring-table { width: 100%; min-width: 106rem; color: var(--ink); }
.scoring-table col.score-rank-column { width: 4rem; }
.scoring-table col.score-team-column { width: 9rem; }
.scoring-table col.score-technical-column { width: 9rem; }
.scoring-table col.score-awareness-column { width: 8rem; }
.scoring-table col.score-forensics-column { width: 8rem; }
.scoring-table col.score-non-technical-column { width: 8rem; }
.scoring-table col.score-total-column { width: 8rem; }
.scoring-table th { height: 3.15rem; font-weight: 700; white-space: nowrap; }
.scoring-table .scoring-groups th { border-top: 0; border-bottom-color: var(--ink); color: var(--ink); font-size: .78rem; text-align: center; }
.scoring-table .scoring-groups th + th { border-left: 1px solid var(--ink); }
.scoring-table .scoring-columns th { text-align: left; }
.scoring-table .scoring-columns th:nth-child(3),
.scoring-table .scoring-columns th:nth-child(8),
.scoring-table .scoring-columns th:nth-child(11),
.scoring-table .scoring-columns th:nth-child(12),
.scoring-table .scoring-columns th:nth-child(18) { border-left: 1px solid var(--ink); }
.scoring-table tbody td { font-variant-numeric: tabular-nums; }
.scoring-table tbody th { font-weight: 700; }
.scoring-table tbody td:last-child { border-left: 1px solid var(--ink); font-weight: 700; }
.scoring-average-row th, .scoring-average-row td { border-top: 2px solid var(--ink); background: var(--surface); font-weight: 700; }
.page-toolbar-with-tools { display: grid; grid-template-columns: minmax(10rem, auto) minmax(15rem, 1fr) auto; }
.search-form { display: flex; align-items: center; max-width: 32rem; border-bottom: 1px solid transparent; }
.search-form:focus-within { border-color: var(--blue); }
.search-form input { width: 100%; border: 0; padding: .75rem; background: transparent; font-size: 1.15rem; outline: 0; }
.icon-button { display: grid; place-items: center; padding: .65rem; }
.icon-button:hover { color: var(--blue); background: var(--surface); }
.toolbar-actions { display: flex; align-items: center; gap: 1rem; }
.outline-button { min-height: 2.75rem; padding: .55rem .9rem; border: 1px solid var(--blue); background: var(--white); color: var(--blue); font-weight: 700; cursor: pointer; }
.outline-button:hover, .outline-button[aria-expanded="true"] { background: var(--blue); color: var(--white); }
.text-action { display: flex; align-items: center; gap: .35rem; border: 0; background: transparent; font-weight: 700; cursor: pointer; white-space: nowrap; }
.text-action .icon { width: 1rem; height: 1rem; }
.filter-panel { padding: 1.5rem 2rem; border-bottom: 1px solid var(--rule); background: var(--surface); }
.filter-panel h2 { margin: 0 0 .5rem; font-size: 1rem; }
.filter-panel p { margin: 0; color: var(--muted); }
.filter-fields { display: flex; flex-wrap: wrap; gap: 1.5rem; }
.filter-fields label { display: grid; gap: .45rem; min-width: 13rem; font-size: .85rem; font-weight: 600; }
.filter-fields select { min-height: 2.75rem; padding: .5rem 2rem .5rem .65rem; border: 1px solid var(--ink); border-radius: 0; background: var(--white); }
.filter-fields input { min-height: 2.75rem; padding: .5rem .65rem; border: 1px solid var(--ink); border-radius: 0; background: var(--white); }
.results { padding: 3rem 2rem; }
.results-heading { display: flex; align-items: baseline; justify-content: space-between; padding-bottom: 1rem; border-bottom: 1px solid var(--ink); }
.results-heading h2 { margin: 0; font-size: 1.5rem; font-weight: 400; }
.results-heading p { margin: 0; color: var(--muted); font-size: .85rem; }
.results-heading span { color: var(--muted); font-variant-numeric: tabular-nums; }
.empty-state.compact { margin: 0; padding: 5rem 0; }
.availability-table-wrap { overflow-x: auto; border-bottom: 1px solid var(--ink); }
.availability-table { width: 100%; min-width: 60rem; border-collapse: collapse; font-size: .92rem; }
.availability-table th, .availability-table td { padding: .85rem 1rem; border-bottom: 1px solid var(--rule); text-align: left; vertical-align: middle; }
.availability-table th:last-child, .availability-table td:last-child { border-right: 0; }
.availability-table thead th { background: var(--surface); color: var(--muted); font-size: .72rem; letter-spacing: .055em; text-transform: uppercase; white-space: nowrap; }
.availability-table tbody th { font-weight: 400; }
.availability-table tbody tr:hover { background: var(--surface); }
.availability-table .numeric, .availability-table time { font-variant-numeric: tabular-nums; white-space: nowrap; }
.spot-reports { padding: 3rem 0; }
.spot-reports-heading { margin: 0 2rem; }
.spot-reports-table { min-width: 72rem; font-size: 1.05rem; }
.inbox-toolbar { grid-template-columns: minmax(10rem, auto) minmax(15rem, 1fr) auto; }
.inbox-toolbar :focus-visible, .inbox-layout :focus-visible { outline-color: var(--ink); }
.inbox-toolbar .search-form:focus-within { border-color: var(--ink); }
.inbox-toolbar .icon-button:hover { color: var(--ink); }
.inbox-title { display: flex; align-items: baseline; gap: 1rem; }
.inbox-title > span { color: var(--ink); font-size: .78rem; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; white-space: nowrap; }
.inbox-filters { display: flex; align-items: center; border: 1px solid var(--rule); }
.inbox-filter { min-height: 2.65rem; padding: .55rem .9rem; border: 0; background: var(--white); cursor: pointer; }
.inbox-filter + .inbox-filter { border-left: 1px solid var(--rule); }
.inbox-filter:hover, .inbox-filter.active { background: var(--ink); color: var(--white); }
.inbox-data-note { margin: 0; padding: .8rem 2rem; border-bottom: 1px solid var(--rule); color: var(--muted); font-size: .78rem; }
.inbox-layout { display: grid; grid-template-columns: minmax(19rem, 36%) minmax(25rem, 1fr); min-height: calc(100vh - var(--preview-banner) - var(--unread-notice) - var(--header) - 8.3rem); }
.inbox-layout.is-empty { grid-template-columns: 1fr; }
.inbox-layout.is-empty .inbox-list, .inbox-layout.is-empty .inbox-reading-pane { display: none; }
.inbox-list { border-right: 1px solid var(--ink); }
.inbox-message { position: relative; display: grid; width: 100%; gap: .45rem; padding: 1.35rem 1.5rem 1.35rem 1.8rem; border: 0; border-bottom: 1px solid var(--rule); background: var(--white); text-align: left; cursor: pointer; }
.inbox-message[hidden] { display: none; }
.inbox-message:hover { background: var(--surface); }
.inbox-message.selected { background: var(--surface); box-shadow: inset 4px 0 0 var(--ink); }
.inbox-message-marker { position: absolute; top: 1.7rem; left: .75rem; width: .4rem; height: .4rem; border: 1px solid var(--muted); border-radius: 50%; }
.inbox-message.unread .inbox-message-marker { border-color: var(--ink); background: var(--ink); }
.inbox-message-meta { display: flex; justify-content: space-between; gap: 1rem; color: var(--muted); font-size: .78rem; }
.inbox-message-meta strong { color: var(--ink); font-size: .88rem; }
.inbox-message.unread .inbox-message-subject { font-weight: 700; }
.inbox-message-preview { overflow: hidden; color: var(--muted); font-size: .88rem; line-height: 1.45; text-overflow: ellipsis; white-space: nowrap; }
.inbox-reading-pane { min-width: 0; }
.inbox-message-detail { max-width: 54rem; padding: clamp(2rem, 5vw, 5rem); }
.inbox-message-detail > header { padding-bottom: 2rem; border-bottom: 1px solid var(--ink); }
.inbox-message-detail > header > p { margin: 0 0 .75rem; color: var(--ink); font-weight: 700; }
.inbox-mark-read { border-color: var(--ink); color: var(--ink); }
.inbox-mark-read:hover { background: var(--ink); color: var(--white); }
.inbox-message-detail h2 { max-width: 18ch; margin: 0 0 2rem; font-size: clamp(2.2rem, 5vw, 4.8rem); font-weight: 400; letter-spacing: -.05em; line-height: .95; }
.inbox-message-detail header div { display: flex; flex-wrap: wrap; justify-content: space-between; gap: .75rem; color: var(--muted); font-size: .82rem; font-variant-numeric: tabular-nums; }
.inbox-message-body { max-width: 42rem; padding: 2rem 0 1rem; font-size: 1.05rem; line-height: 1.7; }
.inbox-message-body p { margin: 0 0 1.25rem; }
.inbox-empty { grid-column: 1 / -1; align-self: center; width: min(100%, 42rem); margin: 0 auto; padding: clamp(2rem, 7vw, 5rem) 1.5rem; text-align: center; }
.inbox-empty[hidden] { display: none; }
.inbox-empty h2 { margin: 0 0 1rem; font-size: clamp(2rem, 4vw, 3.25rem); letter-spacing: -.04em; line-height: 1.1; }
.inbox-empty p { margin: 0 auto; max-width: 34rem; color: var(--muted); line-height: 1.5; }
.inbox-empty button { margin-top: 1.5rem; }
.spot-reports-table th, .spot-reports-table td { height: 4.75rem; padding-right: 1.25rem; padding-left: 1.25rem; }
.spot-reports-table thead th { height: 2.75rem; padding-top: .6rem; padding-bottom: .6rem; background: var(--white); font-size: .8rem; letter-spacing: 0; text-transform: none; }
.spot-reports-table th:first-child { width: 18%; }
.spot-reports-table th:nth-child(2) { width: 33%; }
.spot-reports-table tbody th { font-weight: 700; }
.availability-row { cursor: pointer; }
.availability-row:focus-visible { outline: 3px solid var(--blue); outline-offset: -3px; }
.availability-row[aria-expanded="true"] { background: var(--surface); }
.availability-detail > td { padding: 0 !important; border-bottom-color: var(--ink); background: var(--surface); }
.availability-detail table { width: 100%; border-collapse: collapse; }
.availability-detail table th, .availability-detail table td { padding: .65rem .8rem; }
.availability-detail table thead th { background: var(--ink); color: var(--white); }
.availability-detail table th:first-child { width: 42%; }
.availability-detail .interface-status, .availability-detail .interface-team { color: var(--white); font-variant-numeric: tabular-nums; }
.availability-detail [data-interface-status="OK"] { background: #4caf50; }
.availability-detail [data-interface-status="CRITICAL"] { background: #c62828; }
.availability-detail .interface-result { white-space: nowrap; }
.collaboration-toolbar { grid-template-columns: auto minmax(14rem, 1fr) auto auto; }
.collaboration-toolbar .search-form { max-width: 28rem; }
.collaboration-summary { display: flex; align-items: center; gap: 2rem; }
.send-points-button { min-height: 3rem; padding: .65rem 1rem; border: 1px solid var(--rule); background: var(--white); box-shadow: 0 2px 6px rgb(0 0 0 / 16%); font-weight: 600; letter-spacing: .11em; text-transform: uppercase; cursor: pointer; white-space: nowrap; }
.send-points-button span { font-variant-numeric: tabular-nums; }
.send-points-button:hover { border-color: var(--blue); color: var(--blue); }
.showing-count { font-size: .82rem; font-weight: 600; letter-spacing: .1em; text-transform: uppercase; white-space: nowrap; }
.collaboration-results { padding-top: 0; }
.collaboration-data-note { margin: 0; padding: .8rem 0; color: var(--muted); font-size: .78rem; }
.collaboration-table { min-width: 64rem; }
.collaboration-table th:nth-child(1), .collaboration-table th:nth-child(2) { width: 14%; }
.collaboration-table th:nth-child(3) { width: 11%; }
.collaboration-table th:nth-child(4) { width: 11%; }
.collaboration-table th:nth-child(6) { width: 16%; }
.collaboration-table thead th { background: var(--white); text-transform: none; letter-spacing: 0; font-size: .78rem; }
.collaboration-row { cursor: pointer; }
.collaboration-row:focus-visible { outline: 3px solid var(--blue); outline-offset: -3px; }
.collaboration-row[aria-expanded="true"] { background: var(--surface); }
.collaboration-reason { max-width: 22rem; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.collaboration-detail td { padding: 0 !important; background: var(--surface); border-bottom-color: var(--ink); }
.collaboration-detail dl { display: grid; grid-template-columns: repeat(4, minmax(7rem, 1fr)); margin: 0; padding: 1.5rem 2rem; gap: 1.25rem 2rem; }
.collaboration-detail dl > div { display: grid; gap: .35rem; }
.collaboration-detail .detail-reason { grid-column: 1 / -2; }
.collaboration-detail dt { color: var(--muted); font-size: .7rem; font-weight: 600; letter-spacing: .06em; text-transform: uppercase; }
.collaboration-detail dd { margin: 0; line-height: 1.45; }
.credentials-table { min-width: 52rem; }
.credentials-table th:first-child { width: 25%; }
.credential-row { cursor: pointer; }
.credential-row:focus-visible { outline: 3px solid var(--blue); outline-offset: -3px; }
.credential-row[aria-expanded="true"] { background: var(--surface); }
.credential-detail > td { padding: 0 !important; border-bottom-color: var(--ink); background: var(--surface); }
.credential-detail-grid { display: grid; grid-template-columns: 1fr; }
.credential-detail-grid > section { padding: 1.5rem 2rem; }
.credential-detail-grid > section + section { border-top: 1px solid var(--ink); }
.credential-detail h2 { margin: 0 0 1rem; font-size: .75rem; letter-spacing: .06em; text-transform: uppercase; }
.credential-detail p { max-width: 34rem; margin: .8rem 0 0; color: var(--muted); font-size: .82rem; line-height: 1.45; }
.original-password { display: flex; align-items: center; justify-content: space-between; gap: 1rem; padding-bottom: .65rem; border-bottom: 1px solid var(--ink); }
.original-password code { overflow-wrap: anywhere; font: inherit; letter-spacing: .025em; }
.credential-service-list { display: grid; gap: 1rem; margin: 0; padding: 0; list-style: none; }
.credential-service-list li { display: grid; grid-template-columns: minmax(10rem, 1fr) minmax(14rem, 1.5fr); gap: 1rem; }
.credential-service-list strong { overflow-wrap: anywhere; font-size: .85rem; }
.credential-service-list a { color: var(--blue); text-underline-offset: .2em; }
.credential-service-list span { color: var(--muted); font-size: .82rem; line-height: 1.45; }
.systems-table { min-width: 76rem; }
.systems-table th:first-child { width: 22%; }
.systems-table .system-id { font-weight: 600; }

.ust-toolbar { grid-template-columns: minmax(18rem, auto) minmax(15rem, 1fr) auto; }
.ust-toolbar .outline-button { border-color: var(--ink); color: var(--ink); }
.ust-overview { display: grid; grid-template-columns: repeat(4, 1fr); border-bottom: 1px solid var(--rule); }
.ust-overview > div { min-width: 0; padding: 1.5rem 2rem; border-right: 1px solid var(--rule); }
.ust-overview > div:last-child { border-right: 0; }
.ust-overview span, .ust-overview small { display: block; }
.ust-overview span { color: var(--muted); font-size: .78rem; letter-spacing: .06em; text-transform: uppercase; }
.ust-overview strong { display: block; margin: .35rem 0; color: var(--ink); font-size: 2.4rem; font-weight: 400; line-height: 1; font-variant-numeric: tabular-nums; }
.ust-overview small { overflow: hidden; color: var(--muted); text-overflow: ellipsis; white-space: nowrap; }
.ust-results { padding-top: 1.5rem; }
.ust-ticket-list { border-top: 1px solid var(--ink); }
.ust-ticket { position: relative; border-bottom: 1px solid var(--rule); }
.ust-ticket-summary { width: 100%; display: grid; grid-template-columns: .4rem 6rem minmax(17rem, 1fr) 5.5rem 7rem 3.5rem 3rem; align-items: center; gap: 1rem; min-height: 5.25rem; padding: 0 1rem 0 0; border: 0; background: var(--white); color: var(--ink); text-align: left; cursor: pointer; }
.ust-ticket-summary:hover { background: var(--surface); }
.ust-signal { align-self: stretch; background: var(--rule); }
.ust-signal[data-priority="Critical"] { background: var(--ink); }
.ust-signal[data-priority="High"] { background: var(--ink); }
.ust-ticket-id, .ust-ticket-summary time { font-variant-numeric: tabular-nums; }
.ust-ticket-id { color: var(--ink); font-weight: 600; }
.ust-ticket-main { min-width: 0; }
.ust-ticket-main strong, .ust-ticket-main small { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.ust-ticket-main strong { margin-bottom: .35rem; font-size: 1rem; }
.ust-ticket-main small, .ust-ticket-summary time, .ust-expand { color: var(--muted); font-size: .82rem; }
.ust-priority, .ust-state { font-size: .78rem; letter-spacing: .04em; text-transform: uppercase; }
.ust-state { color: var(--ink); font-weight: 600; }
.ust-state[data-ticket-status="Resolved"] { color: var(--muted); }
.ust-expand { text-decoration: underline; }
.ust-ticket-detail { padding: 1.75rem 2rem 2rem 7.4rem; background: var(--surface); border-top: 1px solid var(--rule); }
.ust-ticket-detail h2 { margin: 0 0 .55rem; font-size: .78rem; letter-spacing: .06em; text-transform: uppercase; }
.ust-ticket-detail p { max-width: 62rem; margin: 0; line-height: 1.55; }
.ust-ticket-detail dl { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 1rem; margin: 1.5rem 0; padding: 1.25rem 0; border-top: 1px solid var(--rule); border-bottom: 1px solid var(--rule); }
.ust-ticket-detail dt { margin-bottom: .35rem; color: var(--muted); font-size: .78rem; }
.ust-ticket-detail dd { margin: 0; overflow-wrap: anywhere; }
.ust-thread { margin-top: 1.5rem; }
.ust-thread ol { margin: 0; padding: 0; border-top: 1px solid var(--rule); list-style: none; }
.ust-thread li { padding: 1rem 0; border-bottom: 1px solid var(--rule); }
.ust-thread li > div { display: flex; justify-content: space-between; gap: 1rem; margin-bottom: .45rem; }
.ust-thread time { color: var(--muted); font-size: .78rem; font-variant-numeric: tabular-nums; }
.ust-no-replies { color: var(--muted); }
.ust-ticket-actions { display: grid; grid-template-columns: minmax(18rem, 1fr) auto; align-items: end; gap: 1.5rem; margin-top: 1.5rem; padding-top: 1.25rem; border-top: 1px solid var(--ink); }
.ust-reply-form label { display: block; margin-bottom: .55rem; font-weight: 600; }
.ust-reply-form textarea { display: block; width: 100%; min-height: 3.75rem; margin-bottom: .75rem; padding: .6rem .75rem; border: 1px solid var(--ink); border-radius: 0; background: var(--white); color: var(--ink); font: inherit; resize: vertical; }
.ust-reply-form textarea:focus { outline: 3px solid var(--ink); outline-offset: 2px; }
.ust-action-button { border-color: var(--ink); background: var(--ink); color: var(--white); }
.ust-action-button:hover { background: var(--white); color: var(--ink); }
.ust-status-form .ust-action-button { min-width: 9rem; background: transparent; color: var(--ink); }
.ust-status-form .ust-action-button:hover { background: var(--ink); color: var(--white); }
.zone-list { display: flex; flex-wrap: wrap; gap: .35rem; }
.zone-list span { display: inline-flex; align-items: center; min-height: 1.65rem; padding: .15rem .5rem; border: 1px solid var(--ink); font-size: .76rem; font-weight: 700; white-space: nowrap; }
.network-cell { min-width: 20rem; padding-top: .6rem !important; padding-bottom: .6rem !important; }
.network-record { display: grid; grid-template-columns: 6.75rem 1fr; gap: .2rem .75rem; padding: .4rem 0; }
.network-record + .network-record { border-top: 1px solid var(--rule); }
.network-record strong { grid-row: 1 / span 2; align-self: start; font-size: .82rem; }
.network-record > span { display: flex; align-items: baseline; gap: .55rem; min-width: 0; }
.network-record code { font: inherit; font-variant-numeric: tabular-nums; white-space: nowrap; }
.address-label { flex: 0 0 2rem; color: var(--muted); font-size: .68rem; font-weight: 700; letter-spacing: .04em; text-transform: uppercase; }
.team-id { font-size: 1.1rem; font-weight: 700; }
.credential-cell-content { align-items: center; gap: .65rem; }
.username-cell-content { display: flex; min-width: 12rem; }
.password-cell-content { display: grid; grid-template-columns: auto minmax(8rem, 1fr) auto; min-width: 15rem; }
.password-cell-content > span { letter-spacing: .025em; }
.credential-copy-button, .credential-edit-button { display: grid; flex: 0 0 auto; place-items: center; width: 2rem; height: 2rem; border: 0; background: var(--white); color: var(--ink); cursor: pointer; }
.credential-copy-button .icon, .credential-edit-button .icon { width: 1rem; height: 1rem; }
.credential-copy-button:hover, .credential-copy-button:focus-visible, .credential-edit-button:hover, .credential-edit-button:focus-visible { background: var(--ink); color: var(--white); }
.credential-service a { color: var(--blue); text-underline-offset: .2em; }
.credential-dialog { width: min(32rem, calc(100% - 2rem)); border: 1px solid var(--ink); padding: 0; background: var(--white); color: var(--ink); }
.credential-dialog::backdrop { background: rgb(0 0 0 / 35%); }
.credential-dialog form { padding: 2rem; }
.credential-dialog header { margin: -2rem -2rem 2rem; padding: 1.5rem 2rem; border-bottom: 1px solid var(--ink); }
.credential-dialog header p { margin: 0 0 .4rem; color: var(--blue); font-size: .78rem; letter-spacing: .06em; text-transform: uppercase; }
.credential-dialog h2 { margin: 0; overflow-wrap: anywhere; font-size: 1.5rem; font-weight: 400; }
.credential-dialog label { display: block; margin-bottom: .5rem; font-weight: 600; }
.credential-dialog input { width: 100%; min-height: 3rem; border: 0; border-bottom: 1px solid var(--ink); padding: .65rem 0; background: transparent; color: var(--ink); font: inherit; outline: 0; }
.credential-dialog input:focus { border-bottom: 3px solid var(--blue); }
.send-points-dialog select, .send-points-dialog textarea { width: 100%; min-height: 3rem; padding: .65rem 0; border: 0; border-bottom: 1px solid var(--ink); border-radius: 0; background: var(--white); color: var(--ink); font: inherit; outline: 0; }
.send-points-dialog textarea { resize: vertical; }
.send-points-dialog select:focus, .send-points-dialog textarea:focus { border-bottom: 3px solid var(--blue); }
.primary-button:disabled { opacity: .45; cursor: not-allowed; }
.dialog-actions { display: flex; justify-content: flex-end; gap: .75rem; margin-top: 2rem; }

@media (max-width: 760px) {
  .credential-service-list li { grid-template-columns: 1fr; gap: .3rem; }
}

.auth-page { min-height: 100vh; padding-top: var(--preview-banner); background: var(--surface); }
.auth-masthead { min-height: 4.5rem; display: flex; align-items: center; justify-content: space-between; padding: 0 clamp(1.25rem, 3vw, 3rem); border-bottom: 1px solid var(--rule); background: var(--white); }
.auth-masthead > span { color: var(--muted); }
.auth-layout { min-height: calc(100vh - 4.5rem - var(--preview-banner)); display: grid; grid-template-columns: minmax(22rem, 3fr) minmax(20rem, 2fr); }
.auth-form-panel { padding: clamp(2rem, 6vw, 6rem); background: var(--white); }
.auth-form-panel h1 { max-width: 8ch; margin-bottom: 2.25rem; }
.login-layout { display: grid; grid-template-columns: minmax(22rem, 3fr) minmax(16rem, 2fr); }
.login-layout .auth-form-panel { width: 100%; padding-top: clamp(3rem, 10vh, 7rem); }
.login-layout .auth-form-panel h1 { font-size: clamp(2.7rem, 5vw, 4.5rem); }
.login-layout::after { display: block; background: var(--ink); content: ""; }
.auth-folio { margin: 0 0 1rem; color: var(--blue); font-size: 1.2rem; font-variant-numeric: tabular-nums; }
.auth-form { max-width: 34rem; }
.field { margin-bottom: 1.35rem; }
.field label { display: block; margin-bottom: .45rem; font-size: .85rem; font-weight: 700; }
.field input, .field select, .field textarea { width: 100%; min-height: 3rem; padding: .65rem .85rem; border: 1px solid var(--rule); border-radius: 0; background: var(--white); color: var(--ink); outline: 0; }
.field textarea { line-height: 1.5; resize: vertical; }
.field input:focus, .field select:focus, .field textarea:focus { border-color: var(--blue); box-shadow: inset 3px 0 0 var(--blue); }
.field [aria-invalid="true"] { border-color: var(--blue); }
.field-error, .form-error { color: var(--blue); }
.field-error { margin: .5rem 0 0; font-size: .9rem; }
.form-error { max-width: 34rem; padding: 1rem; border: 1px solid currentColor; }
.primary-button { min-height: 3rem; padding: .65rem 1.2rem; border: 1px solid var(--blue); background: var(--blue); color: var(--white); font-weight: 700; cursor: pointer; }
.primary-button:hover { background: var(--white); color: var(--blue); }
.oauth-signin { max-width: 34rem; padding-top: 1.5rem; border-top: 1px solid var(--ink); }
.oauth-signin p { margin: 0 0 2rem; color: var(--muted); line-height: 1.5; }
.oauth-button { display: inline-flex; align-items: center; justify-content: center; text-decoration: none; }
.auth-switch { margin: 2rem 0 0; }
.auth-switch a { color: var(--blue); }
.team-preview { display: flex; flex-direction: column; justify-content: space-between; min-width: 0; padding: clamp(2rem, 5vw, 5rem); background: var(--blue); color: var(--white); }
.team-preview > span { border-top: 1px solid rgb(255 255 255 / 55%); padding-top: 1rem; }
.team-preview strong { overflow-wrap: anywhere; font-size: clamp(3rem, 7vw, 7rem); font-weight: 400; letter-spacing: -.06em; line-height: .9; }
.team-preview p { max-width: 24rem; margin: 0; line-height: 1.5; }
.configuration-message { max-width: 34rem; padding: 1.5rem 0; border-top: 1px solid var(--ink); border-bottom: 1px solid var(--ink); }
.configuration-message h2 { margin: 0 0 .75rem; font-size: 1.3rem; }
.configuration-message p { margin: 0; color: var(--muted); line-height: 1.5; }
.admin-signin-note { max-width: 34rem; margin: 1rem 0 0; color: var(--muted); font-size: .85rem; line-height: 1.5; }
.oauth-signin + .auth-form { margin-top: 2rem; padding-top: 2rem; border-top: 1px solid var(--rule); }
.admin-toolbar { justify-content: space-between; flex-wrap: wrap; }
.admin-saved { margin: 0; color: var(--green); font-weight: 600; }
.admin-page-form { max-width: 90rem; margin: 0 auto; padding: clamp(1.5rem, 3vw, 3rem); }
.admin-page-intro { display: flex; align-items: center; justify-content: space-between; gap: 2rem; margin-bottom: 2rem; }
.admin-page-intro p { max-width: 44rem; margin: 0; color: var(--muted); line-height: 1.55; }
.admin-table-wrap { overflow-x: auto; border-top: 1px solid var(--ink); }
.admin-table { width: 100%; min-width: 44rem; border-collapse: collapse; }
.admin-table th, .admin-table td { height: 3.8rem; padding: .75rem 1rem; border-bottom: 1px solid var(--rule); text-align: left; }
.admin-table th:last-child, .admin-table td:last-child { border-right: 0; }
.admin-table thead th { height: 2.8rem; background: var(--surface); color: var(--muted); font-size: .75rem; letter-spacing: .06em; text-transform: uppercase; }
.admin-table tbody th { font-weight: 600; }
.admin-table code { font-family: inherit; color: var(--muted); }
.admin-switch { display: inline-flex; align-items: center; gap: .65rem; cursor: pointer; }
.admin-switch input { width: 1.15rem; height: 1.15rem; accent-color: var(--blue); }
.admin-switch span { font-size: .85rem; }

@media (max-width: 900px) {
  :root { --header: 4.25rem; }
  .menu-button { display: block; }
  .masthead { gap: .8rem; padding: 0 1rem; }
  .brand { font-size: 1.4rem; }
  .version, .back-button, .breadcrumbs, .session-email, .exercise-badge { display: none; }
  .team-view-label { display: none; }
  .team-view-menu { min-width: 6.5rem; }
  .team-view-menu summary { max-width: 6.5rem; }
  .team-view-form + .utc-clock { display: none; }
  .utc-clock { padding: .45rem .55rem; min-width: 6rem; font-size: .85rem; }
  .side-rail { top: calc(var(--preview-banner) + var(--unread-notice)); width: min(22rem, 88vw); z-index: 50; transform: translateX(-102%); transition: transform 180ms ease; box-shadow: 5px 0 15px rgb(0 0 0 / 12%); padding-top: 5rem; }
  body.drawer-open .side-rail { transform: translateX(0); }
  .drawer-scrim { position: fixed; inset: 0; z-index: 40; background: rgb(0 0 0 / 35%); }
  body.drawer-open .drawer-scrim { display: block; }
  body.drawer-open { overflow: hidden; }
  .content { margin-left: 0; }
  .home-hero { grid-template-columns: minmax(0, 1.4fr) minmax(12rem, .6fr); }
  .phase-list { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .empty-state { margin: 0 1.25rem; }
  .page-placeholder { margin-right: auto; margin-left: auto; padding-right: 1.25rem; padding-left: 1.25rem; }
  .page-toolbar { padding: 1rem 1.25rem; }
  .scoring-toolbar { flex-wrap: wrap; }
  .page-toolbar-with-tools { grid-template-columns: 1fr auto; gap: 1rem; }
  .ust-toolbar { grid-template-columns: 1fr auto; }
  .ust-overview > div { padding: 1.25rem; }
  .ust-ticket-summary { grid-template-columns: .35rem 5.5rem minmax(14rem, 1fr) 6.5rem 3rem; }
  .ust-priority, .ust-ticket-summary time { display: none; }
  .ust-ticket-detail { padding-left: 2rem; }
  .collaboration-toolbar { grid-template-columns: 1fr auto; }
  .collaboration-summary { grid-column: 1 / -1; grid-row: 2; justify-content: space-between; }
  .collaboration-toolbar .search-form { grid-row: 3; max-width: none; }
  .collaboration-toolbar .toolbar-actions { grid-row: 1; }
  .page-toolbar-with-tools h1 { grid-column: 1; }
  .search-form { grid-column: 1 / -1; grid-row: 2; max-width: none; border-bottom-color: var(--rule); }
  .toolbar-actions { grid-column: 2; grid-row: 1; }
  .text-action { font-size: 0; }
  .text-action .icon { width: 1.5rem; height: 1.5rem; }
  .filter-panel, .results { padding-left: 1.25rem; padding-right: 1.25rem; }
  .inbox-toolbar { grid-template-columns: 1fr auto; }
  .inbox-toolbar .inbox-filters { grid-column: 2; grid-row: 1; }
  .inbox-layout { grid-template-columns: minmax(17rem, 42%) minmax(20rem, 1fr); }
  .auth-layout { grid-template-columns: 1fr; }
  .admin-page-form { padding: 1.25rem; }
  .team-preview { min-height: 18rem; }
}

@media (max-width: 520px) {
  :root { --preview-banner: 3.75rem; }
  .preview-banner { min-height: 3.75rem; align-items: flex-start; gap: .25rem; flex-direction: column; text-align: left; }
  .unread-notice { justify-content: space-between; }
  .home-hero { display: block; min-height: 0; }
  .home-welcome { min-height: 22rem; padding: 2.5rem 1.25rem; }
  .current-phase { min-height: 13rem; padding: 1.25rem; }
  .current-phase strong { font-size: 8rem; }
  .phase-schedule { padding: 2.5rem 1.25rem; }
  .phase-schedule > header { display: block; }
  .phase-schedule > header p { margin-top: .5rem; }
  .phase-list { grid-template-columns: 1fr; }
  .phase-card { min-height: 9rem; }
  .page-toolbar-with-tools { grid-template-columns: 1fr; }
  .ust-overview { grid-template-columns: 1fr 1fr; }
  .ust-overview > div:nth-child(2) { border-right: 0; }
  .ust-overview > div:nth-child(-n+2) { border-bottom: 1px solid var(--rule); }
  .ust-ticket-summary { grid-template-columns: .3rem 1fr auto; gap: .75rem; padding-right: .75rem; }
  .ust-ticket-id { grid-column: 2; margin-top: .8rem; }
  .ust-ticket-main { grid-column: 2; margin-bottom: .8rem; }
  .ust-state { grid-column: 3; grid-row: 1; }
  .ust-expand { grid-column: 3; grid-row: 2; }
  .ust-ticket-detail { padding: 1.5rem 1.25rem; }
  .ust-ticket-detail dl { grid-template-columns: 1fr 1fr; }
  .ust-ticket-actions { grid-template-columns: 1fr; gap: 1rem; }
  .ust-status-form .ust-action-button { width: 100%; }
  .scoring-toolbar { align-items: flex-start; }
  .scoring-actions { width: 100%; justify-content: space-between; }
  .page-toolbar-with-tools h1, .toolbar-actions, .search-form { grid-column: 1; }
  .toolbar-actions { grid-row: 2; justify-content: space-between; }
  .search-form { grid-row: 3; }
  .collaboration-summary { grid-row: 2; flex-wrap: wrap; gap: .75rem; }
  .collaboration-toolbar .toolbar-actions { grid-row: 3; }
  .collaboration-toolbar .search-form { grid-row: 4; }
  .collaboration-detail dl { grid-template-columns: 1fr 1fr; padding: 1.25rem; }
  .collaboration-detail .detail-reason { grid-column: 1 / -1; }
  .inbox-toolbar .inbox-filters { grid-column: 1; grid-row: 2; justify-self: start; }
  .inbox-toolbar .search-form { grid-row: 3; }
  .inbox-layout { display: block; min-height: 0; }
  .inbox-layout.is-empty { min-height: 18rem; }
  .inbox-list { border-right: 0; }
  .inbox-reading-pane { border-top: 1px solid var(--ink); }
  .inbox-message-detail { padding: 2rem 1.25rem 3rem; }
  .inbox-message-detail h2 { font-size: 2.5rem; }
  .auth-masthead { min-height: 4.25rem; padding: 0 1.25rem; }
  .auth-masthead > span { display: none; }
  .auth-layout { min-height: calc(100vh - 4.25rem - var(--preview-banner)); }
  .auth-form-panel, .team-preview { padding: 2rem 1.25rem; }
  .login-layout .auth-form-panel { padding-top: 3rem; }
  .admin-page-intro { align-items: stretch; flex-direction: column; }
  .auth-form-panel h1 { margin-bottom: 2rem; }
  .team-preview strong { font-size: 3.2rem; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { scroll-behavior: auto !important; transition-duration: .01ms !important; animation-duration: .01ms !important; }
}
/* Live availability scoring shares the existing table and administration shell. */
.scoring-control-panel { padding: 24px; background: var(--white); color: var(--ink); border: 1px solid var(--rule); }
.scoring-control-panel p { max-width: 75ch; line-height: 1.6; }
.scoring-penalties { max-width: 480px; margin-top: 24px; }
.scoring-penalties caption { text-align: left; padding-bottom: 12px; }
.live-scoring-table { width: 100%; font-variant-numeric: tabular-nums; }
.live-scoring-table td, .live-scoring-table th { white-space: nowrap; }
.scoring-results { margin-bottom: 24px; }
.scoring-results h2 { margin: 0; font-size: 16px; }
.scoring-empty, .scoring-live-state { padding: 12px 0; }
.scoring-empty { padding-left: 16px; }
.scoring-status { display: inline-block; padding: 3px 8px; border: 1px solid currentColor; }
.scoring-status-healthy { color: #216c3b; }
.scoring-status-failed { color: #a62121; }
.scoring-status-stale { color: #875900; }
.scoring-page { padding: 2rem; }
.scoring-page .scoring-live-state { margin: 0 0 2rem; padding: 1rem 1.25rem; border: 1px solid var(--rule); border-left: 3px solid var(--blue); background: var(--surface); line-height: 1.5; }
.scoring-page .scoring-results { margin: 0 0 2.5rem; padding: 0; }
.scoring-page .results-heading { align-items: center; min-height: 3.5rem; padding: 0 0 .75rem; }
.scoring-page .results-heading h2 { font-size: 1.25rem; font-weight: 600; }
.scoring-page .availability-table-wrap { border-right: 1px solid var(--rule); border-left: 1px solid var(--rule); }
.scoring-page .scoring-empty { margin: 0; padding: 2rem 1.25rem; border: 1px solid var(--rule); border-top: 0; background: var(--surface); color: var(--muted); line-height: 1.5; }
@media (max-width: 600px) {
  .scoring-control-panel { padding: 16px; }
  .scoring-toolbar { flex-wrap: wrap; gap: 12px; }
  .scoring-page { padding: 1.25rem; }
  .scoring-page .scoring-live-state { margin-bottom: 1.5rem; }
}

.availability-toggle { padding: 0; border: 0; background: transparent; color: inherit; font: inherit; text-align: left; text-decoration: underline; cursor: pointer; }
.availability-toggle:focus-visible { outline: 2px solid var(--blue); outline-offset: 3px; }
.availability-metrics-note { color: var(--muted); font-size: .85rem; line-height: 1.5; }
.availability-page .availability-empty { max-width: none; margin: 0; padding: 2rem 1.25rem; border: 1px solid var(--rule); border-top: 0; background: var(--surface); }
.availability-page .availability-empty h3 { margin-bottom: .5rem; font-size: 1.15rem; font-weight: 600; }
.availability-page .availability-metrics-note { margin: 0; padding: 1rem 1.25rem; border: 1px solid var(--rule); border-left: 3px solid var(--blue); background: var(--surface); }
.availability-detail [data-interface-status="STALE"], .availability-detail [data-interface-status="PENDING"], .availability-detail [data-interface-status="PAUSED"] { background: var(--surface); color: var(--ink); }

.account-list { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 25rem), 1fr)); gap: 1rem; max-width: 90rem; margin: 0 auto; padding: 0 clamp(1.25rem, 3vw, 3rem) 3rem; }
.account-card { min-width: 0; padding: 1.5rem; border: 1px solid var(--rule); border-top: 3px solid var(--ink); background: var(--white); }
.account-card h2 { margin: 0; font-size: 1.2rem; overflow-wrap: anywhere; }
.account-card > p { color: var(--muted); font-size: .85rem; }
.account-controls { display: flex; flex-wrap: wrap; gap: 1rem; align-items: end; }
.account-controls .field { flex: 1 1 12rem; }
.account-controls select { width: 100%; }

.account-intro { max-width: 90rem; margin: 0 auto; padding: 1.5rem clamp(1.25rem, 3vw, 3rem) 0; color: var(--muted); }
.account-create-panel { max-width: calc(90rem - 2 * clamp(1.25rem, 3vw, 3rem)); margin: 1.5rem auto 2rem; padding: clamp(1.5rem, 3vw, 2.5rem); border: 1px solid var(--rule); background: var(--surface); }
.account-create-panel h2 { margin-top: 0; }
.account-create-panel > p { color: var(--muted); line-height: 1.5; }
.account-create-form { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 1rem 1.5rem; }
.account-create-form .field { margin: 0; }
.account-create-form .primary-button { justify-self: start; align-self: end; }
.admin-team-panel { max-width: 90rem; margin: 0 auto; padding: clamp(1.5rem, 3vw, 3rem); }
.admin-team-panel > p { color: var(--muted); line-height: 1.5; }
.admin-team-panel form { max-width: 28rem; margin: 2rem 0; }
.admin-team-panel h2 { margin-top: 3rem; font-size: 1.2rem; }
.admin-team-list { list-style: none; margin: 0; padding: 0; border-top: 1px solid var(--rule); }
.admin-team-list li { display: flex; justify-content: space-between; gap: 1rem; padding: 1rem 0; border-bottom: 1px solid var(--rule); }
.admin-team-list span { color: var(--muted); }
.admin-phase-panel { max-width: 90rem; margin: 0 auto; padding: clamp(1.5rem, 3vw, 3rem); }
.admin-phase-panel > p { color: var(--muted); line-height: 1.5; }
.admin-phase-create, .admin-phase-existing { padding: 1rem 0 2rem; }
.admin-phase-form { display: grid; grid-template-columns: 8rem minmax(12rem, 1fr) minmax(13rem, 1fr); gap: 1rem; align-items: end; }
.admin-phase-form .field { margin: 0; }
.admin-phase-form .primary-button { grid-column: 1 / -1; justify-self: start; }
.admin-phase-card { padding: 1.5rem; border: 1px solid var(--rule); border-top: 3px solid var(--ink); margin-bottom: 1rem; }
.admin-phase-heading { display: flex; align-items: baseline; justify-content: space-between; }
.admin-phase-heading h3 { margin-top: 0; }
.admin-phase-heading span { color: var(--green); font-weight: 600; }
.admin-phase-card .admin-phase-form { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.admin-phase-form .phase-message-field { grid-column: 1 / -1; }
.admin-phase-form textarea { width: 100%; padding: .75rem; border: 1px solid var(--ink); background: var(--white); color: var(--ink); font: inherit; resize: vertical; }
.admin-phase-actions { display: flex; flex-wrap: wrap; gap: .75rem; margin-top: 1rem; }
.admin-phase-actions button { padding: .55rem .75rem; border: 1px solid var(--blue); background: var(--white); color: var(--blue); cursor: pointer; }
.admin-phase-actions button:hover { background: var(--blue); color: var(--white); }
.admin-banner-panel { max-width: 90rem; margin: 0 auto; padding: clamp(1.5rem, 3vw, 3rem); }
.admin-banner-panel > p { color: var(--muted); line-height: 1.5; }
.admin-banner-form { display: grid; gap: 1.5rem; margin-top: 2rem; }
.admin-banner-form .field { margin: 0; }
.admin-banner-form textarea { width: 100%; padding: .75rem; border: 1px solid var(--ink); background: var(--white); color: var(--ink); font: inherit; resize: vertical; }
.admin-banner-form .primary-button { justify-self: start; }
.admin-banner-sample { display: flex; align-items: center; gap: .75rem; margin-top: 2rem; padding: .75rem 1rem; background: var(--banner-background, var(--blue)); color: var(--banner-foreground, var(--white)); }
.admin-banner-sample strong { text-transform: uppercase; letter-spacing: .08em; }
.admin-banner-sample span { overflow-wrap: anywhere; }
@media (max-width: 600px) {
  .account-intro { padding: 0 1.25rem; }
  .account-create-panel { margin: 1.25rem; }
  .account-create-form { grid-template-columns: 1fr; }
  .admin-team-panel { padding: 1.25rem; }
  .admin-phase-panel { padding: 1.25rem; }
  .admin-phase-form, .admin-phase-card .admin-phase-form { grid-template-columns: 1fr; }
  .admin-banner-panel { padding: 1.25rem; }
  .admin-banner-sample { align-items: flex-start; flex-direction: column; }
}

.admin-disabled-message textarea { width: 100%; display: block; margin-top: .5rem; padding: .6rem .75rem; border: 1px solid var(--ink); border-radius: 0; background: var(--white); color: var(--ink); font: inherit; resize: vertical; }
.admin-disabled-message textarea:focus { outline: 3px solid var(--ink); outline-offset: 2px; }
.disabled-page-message { white-space: pre-wrap; overflow-wrap: anywhere; }

.admin-disabled-message { margin-bottom: 1.5rem; }
.admin-inbox-panel { max-width: 90rem; margin: 0 auto; padding: clamp(1.5rem, 3vw, 3rem); }
.admin-inbox-panel h2 { margin: 0 0 .6rem; font-size: 1.7rem; }
.admin-inbox-panel > p { color: var(--muted); line-height: 1.5; }
.admin-inbox-form { display: grid; gap: 1.75rem; margin-top: 2rem; }
.admin-inbox-form fieldset { min-width: 0; margin: 0; padding: 1.25rem 0 0; border: 0; border-top: 1px solid var(--ink); }
.admin-inbox-form legend { padding: 0 .6rem 0 0; font-weight: 600; }
.admin-inbox-audience { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: .75rem; }
.admin-inbox-recipients p { margin: 1.5rem 0 .65rem; color: var(--muted); font-size: .85rem; }
.admin-inbox-teams { display: grid; grid-template-columns: repeat(auto-fit, minmax(8rem, 1fr)); gap: .75rem; }
.admin-inbox-choice { display: flex; align-items: center; gap: .7rem; min-height: 3.25rem; padding: .7rem .85rem; border: 1px solid var(--rule); background: var(--white); cursor: pointer; }
.admin-inbox-choice:has(input:checked) { border-color: var(--blue); background: var(--surface); }
.admin-inbox-choice input { width: 1.15rem; height: 1.15rem; margin: 0; flex: 0 0 auto; accent-color: var(--blue); cursor: pointer; }
.admin-inbox-choice span { font-weight: 500; }
.admin-inbox-form .field { margin: 0; }
.admin-inbox-form .field input { color: var(--ink); }
.admin-inbox-form .field textarea { display: block; width: 100%; padding: .75rem; border: 1px solid var(--ink); border-radius: 0; background: var(--white); color: var(--ink); font: inherit; resize: vertical; }
.admin-inbox-form .field textarea:focus { outline: 3px solid var(--blue); outline-offset: 2px; }
.admin-inbox-form .primary-button { justify-self: start; }
@media (max-width: 520px) {
  .admin-inbox-audience { grid-template-columns: 1fr; }
}

.disabled-page-notice { display: flex; align-items: flex-start; gap: 1.25rem; max-width: 44rem; margin: clamp(1.5rem, 4vw, 3rem) clamp(1.25rem, 4vw, 3rem); padding: clamp(1.25rem, 3vw, 2rem); border: 1px solid var(--rule); border-left: 3px solid var(--blue); background: var(--surface); color: var(--ink); }
.disabled-page-icon { display: grid; place-items: center; flex: 0 0 2.75rem; height: 2.75rem; border: 1px solid var(--rule); background: var(--white); color: var(--blue); }
.disabled-page-icon svg { width: 1.5rem; height: 1.5rem; }
.disabled-page-copy { min-width: 0; }
.disabled-page-copy h2 { margin: 0 0 .6rem; font-size: 1.15rem; font-weight: 600; line-height: 1.4; }
.disabled-page-copy p { margin: 0; color: var(--muted); line-height: 1.65; }
@media (max-width: 480px) {
  .disabled-page-notice { flex-direction: column; gap: 1rem; }
  .disabled-page-icon { flex-basis: auto; width: 2.75rem; }
}

.score-chart-content { padding: 0 0 2rem; }
.score-chart-intro { margin: 1.25rem 0 1.5rem; color: var(--muted); }
.score-chart-summary { display: grid; grid-template-columns: repeat(2, minmax(0, 16rem)); gap: 1rem; margin-bottom: 1.5rem; }
.score-chart-stat { display: grid; gap: .4rem; min-height: 9rem; padding: 1rem 1.25rem; border: 1px solid var(--rule); border-top: 3px solid; background: var(--surface); font-variant-numeric: tabular-nums; }
.score-chart-stat-team { border-top-color: var(--blue); }
.score-chart-stat-average { border-top-color: var(--green); }
.score-chart-stat span { font-size: .85rem; font-weight: 700; }
.score-chart-stat strong { font-size: 2.5rem; line-height: 1; }
.score-chart-stat small { color: var(--muted); }
.score-chart-panel, .score-chart-empty { border: 1px solid var(--rule); }
.score-chart-heading { display: flex; align-items: center; justify-content: flex-end; gap: 1rem; padding: 1.25rem 1.5rem; border-bottom: 1px solid var(--rule); }
.score-chart-empty h2 { margin: 0; font-size: 1.15rem; }
.score-chart-legend { display: flex; flex-wrap: wrap; gap: 1rem; font-size: .85rem; }
.score-chart-key { display: inline-flex; align-items: center; gap: .5rem; }
.score-chart-key::before { width: 1.5rem; height: 3px; background: currentColor; content: ""; }
.score-chart-key-team { color: var(--blue); }
.score-chart-key-average { color: var(--green); }
.score-chart-note { margin: 1rem 1.5rem 0; color: var(--muted); }
.score-chart-scroll { overflow-x: auto; }
.score-chart { display: block; width: 100%; min-width: 44rem; height: auto; color: var(--muted); font-family: inherit; }
.score-chart-grid { stroke: var(--rule); stroke-width: 1; }
.score-chart-axis { fill: var(--muted); font-size: 13px; font-variant-numeric: tabular-nums; }
.score-chart-series { fill: none; stroke-width: 3; stroke-linecap: round; stroke-linejoin: round; }
.score-chart-series-team { stroke: var(--blue); }
.score-chart-series-average { stroke: var(--green); }
.score-chart-dot-team { fill: var(--blue); }
.score-chart-dot-average { fill: var(--green); }
.score-chart-empty { padding: 2rem 1.25rem; border-top: 0; background: var(--surface); }
.score-chart-empty p { margin-bottom: 0; color: var(--muted); }
@media (max-width: 700px) {
  .score-chart-summary { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .score-chart-heading { align-items: flex-start; flex-direction: column; }
}
/* Shared administration rhythm: one grid, compact controls, and clear section rules. */
.content :is(.admin-banner-panel, .admin-team-panel, .admin-phase-panel, .admin-inbox-panel, .account-create-panel, .scoring-control-panel) > h2 {
  margin: 2.75rem 0 1rem;
  padding-top: 1.25rem;
  border-top: 1px solid var(--ink);
  font-size: 1.4rem;
  font-weight: 600;
  letter-spacing: -.025em;
}
.content :is(.admin-banner-panel, .admin-team-panel, .admin-phase-panel, .admin-inbox-panel, .account-create-panel, .scoring-control-panel) > h2:first-child { margin-top: 0; padding-top: 0; border-top: 0; }
.content :is(.admin-banner-panel, .admin-team-panel, .admin-phase-panel, .admin-inbox-panel, .account-create-panel, .scoring-control-panel) > p { max-width: 70ch; }
.content :is(.admin-banner-panel, .admin-team-panel, .admin-phase-panel, .admin-inbox-panel, .account-create-panel, .account-card, .scoring-control-panel) form button:not(.primary-button) {
  min-height: 2.75rem;
  margin: .4rem .5rem .4rem 0;
  padding: .55rem .9rem;
  border: 1px solid var(--rule);
  background: var(--white);
  color: var(--ink);
  font-weight: 600;
  cursor: pointer;
}
.content :is(.admin-banner-panel, .admin-team-panel, .admin-phase-panel, .admin-inbox-panel, .account-create-panel, .account-card, .scoring-control-panel) form button:not(.primary-button):hover { border-color: var(--blue); color: var(--blue); }
.content :is(.admin-banner-panel, .admin-team-panel, .admin-phase-panel, .admin-inbox-panel, .account-create-panel, .scoring-control-panel) .field { max-width: 58rem; }
.content :is(.admin-banner-panel, .admin-team-panel, .admin-phase-panel, .admin-inbox-panel, .admin-page-form, .account-create-panel, .scoring-control-panel) textarea {
  width: 100%;
  padding: .75rem .85rem;
  border: 1px solid var(--rule);
  background: var(--white);
  color: var(--ink);
  line-height: 1.5;
  resize: vertical;
}
.content :is(.admin-banner-panel, .admin-team-panel, .admin-phase-panel, .admin-inbox-panel, .admin-page-form, .account-create-panel, .scoring-control-panel) textarea:focus { border-color: var(--blue); box-shadow: inset 3px 0 0 var(--blue); outline: 0; }
.content textarea[name="record"], .content textarea[name="document"] { font-family: ui-monospace, SFMono-Regular, Consolas, monospace; font-size: .85rem; line-height: 1.55; tab-size: 2; }
.content form + form { margin-top: .6rem; }
.admin-config-status { max-width: 58rem; border-color: var(--rule); background: var(--surface); }
.content > form[action="/admin/config/transfer"] { display: inline-block; margin: .25rem 0 0 clamp(1.25rem, 3vw, 3rem); }
.content > form[action="/admin/config/transfer"] button { min-height: 2.75rem; padding: .55rem .9rem; border: 1px solid var(--rule); background: var(--white); color: var(--ink); font-weight: 600; cursor: pointer; }
.content > form[action="/admin/config/transfer"] button:hover { border-color: var(--blue); color: var(--blue); }
.scoring-control-panel { max-width: 90rem; margin: 0 auto; padding: clamp(1.5rem, 3vw, 3rem); border: 0; border-bottom: 1px solid var(--rule); }
.scoring-penalties { margin-top: 2rem; }
.scoring-penalties caption { font-size: .85rem; font-weight: 700; }
.resource-editor .resource-source-form { display: flex; flex-wrap: wrap; align-items: end; gap: 1rem; }
.resource-editor .resource-source-form .field { flex: 1 1 18rem; max-width: 26rem; margin: 0; }
.resource-editor .resource-list { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 20rem), 1fr)); gap: .75rem; margin: 1rem 0 2rem; }
.resource-editor .resource-list a { display: grid; align-content: start; gap: .3rem; min-width: 0; padding: 1rem 1.15rem; border: 1px solid var(--rule); border-left: 3px solid var(--ink); color: inherit; text-decoration: none; }
.resource-editor .resource-list a:hover { background: var(--surface); border-color: var(--blue); }
.resource-editor .resource-list a strong { overflow-wrap: anywhere; font-size: 1rem; }
.resource-editor .resource-list a span { overflow-wrap: anywhere; color: var(--muted); font-size: .8rem; }
.dataset-editor .dataset-domains { display: flex; flex-wrap: wrap; gap: .25rem; margin: 1.75rem 0 2rem; border-bottom: 1px solid var(--rule); }
.dataset-editor .dataset-domains a { padding: .65rem .85rem; border-bottom: 3px solid transparent; color: var(--muted); font-size: .85rem; text-decoration: none; }
.dataset-editor .dataset-domains a:hover { color: var(--blue); }
.dataset-editor .dataset-domains a[aria-current="page"] { border-bottom-color: var(--ink); color: var(--ink); font-weight: 700; }
.dataset-editor .dataset-record { max-width: 66rem; padding: 1.5rem 0; border-top: 1px solid var(--rule); }
.dataset-editor .dataset-record h3 { margin: 0; overflow-wrap: anywhere; font-size: 1.15rem; }
.dataset-editor .dataset-record > p { color: var(--muted); font-size: .85rem; }
.admin-team-list { max-width: 66rem; }
.admin-team-list li { flex-wrap: wrap; align-items: center; }
.admin-team-list li strong { min-width: 8rem; }
.admin-team-list li form { margin: 0; }
.admin-banner-panel:has(> form[action="/admin/variables"]) > form,
.admin-banner-panel:has(> form[action="/admin/variables"]) > form ~ form { max-width: 58rem; padding-bottom: 1.5rem; border-bottom: 1px solid var(--rule); }
.admin-banner-panel:has(> form[action="/admin/variables"]) > h3 { margin: 2rem 0 1rem; font-size: 1.1rem; }
@media (max-width: 900px) {
  .login-layout { grid-template-columns: 1fr; }
  .login-layout::after { display: none; }
  .login-layout .auth-form-panel { max-width: 44rem; margin: 0 auto; }
}
@media (max-width: 600px) {
  .account-create-panel { margin-right: 1.25rem; margin-left: 1.25rem; }
  .account-list { grid-template-columns: 1fr; }
  .resource-editor .resource-source-form { display: block; }
}
