/* Police Academy visual system: LAPD-inspired navy, service blue and brass. */
:root {
  font-family: 'Source Sans 3', sans-serif;
  color-scheme: light;
  --bg: #edf1f5;
  --surface: #ffffff;
  --surface-soft: #e4eaf0;
  --text: #17283c;
  --muted: #657588;
  --line: #cbd5df;
  --green: #17395d;
  --green-hover: #0b2948;
  --lime: #c8a854;
  --red: #b64046;
  --shadow: 0 18px 42px rgba(17, 39, 63, .15);
  --lapd-navy: #102b49;
  --lapd-blue: #276093;
  --lapd-gold: #d0b05f;
  --lapd-red: #b5484d;
  letter-spacing: 0;
}

:root[data-theme="dark"] {
  color-scheme: dark;
  --bg: #111c29;
  --surface: #1a2a3c;
  --surface-soft: #24384d;
  --text: #f1f3f5;
  --muted: #aebac7;
  --line: #394d62;
  --green: #d2b461;
  --green-hover: #e2c978;
  --lime: #54451e;
  --red: #e47778;
  --shadow: 0 18px 42px rgba(0, 0, 0, .28);
  --lapd-navy: #0b1724;
  --lapd-blue: #4d83b0;
  --lapd-gold: #d2b461;
  --lapd-red: #df7377;
}

* {
  letter-spacing: 0 !important;
}

body {
  background-color: var(--bg);
  background-image: repeating-linear-gradient(0deg, transparent 0 47px, rgba(23, 57, 93, .025) 48px), repeating-linear-gradient(90deg, transparent 0 47px, rgba(23, 57, 93, .02) 48px);
  color: var(--text);
  font-size: 15px;
}

:root[data-theme="dark"] body {
  background-image: repeating-linear-gradient(0deg, transparent 0 47px, rgba(219, 230, 242, .018) 48px), repeating-linear-gradient(90deg, transparent 0 47px, rgba(219, 230, 242, .014) 48px);
}

.topbar {
  position: relative;
  z-index: 2;
  min-height: 82px;
  height: auto;
  gap: clamp(24px, 4vw, 64px);
  padding: 10px max(30px, calc((100vw - 1320px) / 2));
  background: var(--lapd-navy);
  border: 0;
  border-bottom: 3px solid var(--lapd-gold);
  color: #f6f5f0;
}

.topbar::before {
  position: absolute;
  right: 0;
  bottom: -3px;
  width: 54px;
  height: 3px;
  content: '';
  /* background: var(--lapd-red); */
}

.brand {
  flex: none;
  gap: 12px;
  color: #fff;
}

.brand-mark {
  position: relative;
  display: flex;
  width: 52px;
  height: 42px;
  align-items: center;
  justify-content: center;
  gap: 2px;
  background: transparent;
  color: var(--lapd-navy);
  clip-path: none;
  border-radius: 0;
  line-height: 1;
}

.book-page {
  display: block;
  width: 20px;
  height: 27px;
  border: 2px solid var(--lapd-gold);
  background: #f5f2e8;
}

.book-page-left {
  border-radius: 3px 1px 2px 5px;
  transform: skewY(7deg);
}

.book-page-right {
  border-radius: 1px 3px 5px 2px;
  transform: skewY(-7deg);
}

.brand-name {
  display: flex;
  flex-direction: column;
  gap: 1px;
  line-height: 1.02;
}

.brand-name small {
  color: #d3dae2;
  font: 600 9px 'Source Sans 3', sans-serif;
}

.brand-name strong {
  color: #fff;
  font: 700 20px 'Barlow Condensed', sans-serif;
}

.brand-name em {
  color: var(--lapd-gold);
  font: 700 10px 'Source Sans 3', sans-serif;
  font-style: normal;
}

.nav-links {
  justify-content: center;
  gap: 6px;
  align-self: stretch;
  height: auto;
}

.nav-links a {
  position: relative;
  display: flex;
  align-self: stretch;
  height: auto;
  min-height: 62px;
  align-items: center;
  gap: 8px;
  padding: 0 12px;
  border: 0;
  color: #d2dbe4;
  font-size: 14px;
  font-weight: 600;
}

.nav-links a::after {
  position: absolute;
  right: 12px;
  bottom: 0;
  left: 12px;
  height: 2px;
  content: '';
  background: transparent;
}

.nav-links a:hover {
  color: #fff;
  border-color: transparent;
}

.nav-links a.active {
  color: var(--lapd-gold);
}

.nav-links a.active::after {
  display: none;
}

.nav-index {
  color: var(--lapd-gold);
  font: 700 11px 'Barlow Condensed', sans-serif;
}

.nav-actions {
  flex: none;
  gap: 14px;
}

.nav-actions .icon-button {
  width: 36px;
  height: 36px;
  border: 1px solid rgba(255, 255, 255, .27);
  border-radius: 50%;
  background: rgba(255, 255, 255, .04);
  color: #fff;
}

.nav-actions .icon-button:hover {
  background: rgba(255, 255, 255, .12);
}

.nav-actions .text-button {
  color: #f3d98d;
}

.nav-actions .text-button:hover {
  color: #fff;
}

.nav-actions .user-label {
  display: grid;
  gap: 0;
  color: #fff;
  line-height: 1.1;
}

.nav-actions .user-label small {
  color: #aab8c6;
  font: 600 9px 'Source Sans 3', sans-serif;
}

.nav-actions .user-label strong {
  font-size: 13px;
  font-weight: 600;
}

.network-status {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding-right: 12px;
  border-right: 1px solid rgba(255, 255, 255, .2);
  color: #d5dfd9;
  font-size: 10px;
  font-weight: 700;
}

.network-status i,
.footer-classification i,
.register-dot,
.pool-label i {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: #69b982;
  box-shadow: 0 0 0 3px rgba(105, 185, 130, .13);
}

.academy-ribbon {
  display: flex;
  min-height: 38px;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 0 max(30px, calc((100vw - 1320px) / 2));
  background: #e0e6ec;
  border-bottom: 1px solid #cbd5df;
  color: #344d68;
  font-size: 10px;
  font-weight: 700;
}

:root[data-theme="dark"] .academy-ribbon {
  background: #172638;
  border-color: var(--line);
  color: #c5d0dc;
}

.academy-ribbon>div {
  display: flex;
  align-items: center;
  gap: 9px;
}

.ribbon-star {
  color: #aa8734;
}

.ribbon-divider {
  color: var(--lapd-red);
}

.page-shell {
  max-width: 1320px;
  min-height: calc(100vh - 204px);
  padding: 52px 34px 76px;
}

.page-heading {
  position: relative;
  align-items: center;
  margin-bottom: 28px;
  padding-bottom: 24px;
  border-bottom: 1px solid var(--line);
}

.page-heading::after {
  position: absolute;
  bottom: -1px;
  left: 0;
  width: 88px;
  height: 3px;
  content: '';
  background: var(--lapd-gold);
}

.page-heading h1,
.auth-aside h1,
.exam-access h1,
.completion h1 {
  color: var(--text);
  font-family: 'Barlow Condensed', sans-serif;
  font-size: 50px;
  font-weight: 700;
  line-height: .98;
  text-transform: uppercase;
}

.section-kicker,
.eyebrow,
.small-caps {
  display: flex;
  align-items: center;
  gap: 8px;
  color: #725d2b;
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
}

:root[data-theme="dark"] .section-kicker,
:root[data-theme="dark"] .small-caps {
  color: #e0c771;
}

.heading-star {
  color: #ab8734;
}

.muted {
  color: var(--muted);
}

.button {
  min-height: 42px;
  border-radius: 4px;
  font-weight: 700;
}

.button.primary {
  position: relative;
  border-color: var(--lapd-gold);
  background: var(--lapd-gold);
  color: #152b43;
}

.button.primary:hover {
  border-color: #dfc676;
  background: #dfc676;
}

.button.quiet {
  border-radius: 4px;
}

.icon-link {
  border-radius: 4px;
}

.stat-strip {
  margin-bottom: 30px;
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
  background: color-mix(in srgb, var(--surface) 78%, transparent);
}

.stat-strip>div {
  position: relative;
  min-height: 86px;
  padding: 16px 24px;
}

.stat-strip>div::before {
  position: absolute;
  top: 18px;
  bottom: 18px;
  left: 0;
  width: 2px;
  content: '';
  background: var(--lapd-gold);
}

.stat-strip>div:first-child {
  padding-left: 24px;
}

.stat-strip strong {
  color: var(--lapd-navy);
  font: 700 34px 'Barlow Condensed', sans-serif;
}

:root[data-theme="dark"] .stat-strip strong {
  color: #f0d989;
}

.stat-strip span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 600;
}

.register-heading {
  display: flex;
  min-height: 42px;
  align-items: center;
  justify-content: space-between;
  gap: 15px;
  margin-top: 2px;
  padding: 0 14px;
  background: var(--lapd-navy);
  color: #f2f4f5;
  font-size: 10px;
  font-weight: 700;
}

.register-heading>div {
  display: flex;
  align-items: center;
  gap: 9px;
}

.register-heading .register-dot {
  background: var(--lapd-gold);
  box-shadow: 0 0 0 3px rgba(208, 176, 95, .16);
}

.register-heading>span {
  color: #c0cad5;
}

.register-heading b {
  padding: 0 6px;
  color: var(--lapd-gold);
}

.table-wrap {
  border-top: 0;
  border-bottom: 1px solid var(--line);
  background: var(--surface);
}

table {
  min-width: 740px;
}

th {
  padding: 13px 15px;
  background: #dfe6ed;
  color: #334a61;
  font-size: 10px;
}

:root[data-theme="dark"] th {
  background: #23364a;
  color: #d2dce5;
}

td {
  min-height: 62px;
  padding: 16px 15px;
}

tbody tr {
  border-left: 2px solid transparent;
}

tbody tr:hover {
  border-left-color: var(--lapd-blue);
  background: color-mix(in srgb, var(--surface-soft) 58%, var(--surface));
}

.question-title {
  color: var(--text);
  font-weight: 600;
}

.type-label {
  border: 1px solid #d3dce6;
  border-radius: 3px;
  background: #edf2f6;
  color: #315777;
  font-size: 11px;
  font-weight: 600;
}

:root[data-theme="dark"] .type-label {
  border-color: #42566c;
  background: #23384e;
  color: #c2d8eb;
}

.status-pill {
  border-radius: 3px;
}

.status-pill.pinned {
  background: #f1e8ce;
  color: #71591e;
}

:root[data-theme="dark"] .status-pill.pinned {
  background: #4e421f;
  color: #f0d989;
}

.pool-label {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: var(--muted);
  font-size: 12px;
}

.pool-label i {
  width: 6px;
  height: 6px;
  background: var(--lapd-blue);
  box-shadow: none;
}

.points-unit {
  font-size: 9px;
  font-weight: 700;
}

.row-actions {
  min-width: 82px;
}

td.row-actions {
  display: table-cell;
  text-align: right;
  white-space: nowrap;
}

.row-actions>a,
.row-actions>form {
  display: inline-flex;
  vertical-align: middle;
}

.row-actions>form {
  margin-left: 7px;
}

.row-actions .icon-link {
  width: 32px;
  height: 32px;
}

.empty-state {
  padding: 56px 24px;
}

.form-sheet {
  border-radius: 5px;
  box-shadow: 0 8px 24px rgba(17, 39, 63, .06);
}

.auth-aside:before {
  background: var(--lapd-navy);
}

.auth-aside .eyebrow {
  color: var(--lapd-gold);
}

.auth-aside h1 {
  color: #f6f4ed;
}

.auth-aside h1 em {
  color: #e3c66f;
}

.auth-panel {
  background: var(--surface);
  border-left: 3px solid var(--lapd-gold);
}

.exam-header {
  border-top-color: var(--lapd-gold);
}

.exam-question {
  border-left: 3px solid transparent;
}

.exam-question:focus-within {
  border-left-color: var(--lapd-blue);
}

.question-number {
  border-radius: 3px;
  background: #e6edf3;
  color: var(--lapd-navy);
  font-family: 'Barlow Condensed', sans-serif;
  font-size: 14px;
  font-weight: 700;
}

:root[data-theme="dark"] .question-number {
  background: #29415a;
  color: #e6cf84;
}

.exam-progress {
  border-top-color: var(--line);
}

.answer-option:hover {
  border-radius: 3px;
  background: color-mix(in srgb, var(--lapd-blue) 8%, var(--surface));
}

.result-scoreboard {
  border-left-color: var(--lapd-gold);
  border-radius: 4px;
}

.answer-review {
  border-radius: 4px;
}

.choice-review {
  display: grid;
  gap: 7px;
  margin-top: 13px;
}

.choice-review-option {
  display: grid;
  grid-template-columns: 24px minmax(0, 1fr) auto;
  align-items: center;
  gap: 10px;
  min-height: 48px;
  padding: 9px 12px;
  border: 1px solid var(--line);
  border-left: 3px solid transparent;
  border-radius: 4px;
  background: var(--surface);
}

.choice-review-mark {
  display: grid;
  width: 20px;
  height: 20px;
  place-items: center;
  border: 1px solid #9aa8b6;
  border-radius: 50%;
  color: transparent;
  font-size: 13px;
  font-weight: 800;
}

.choice-review-option.is-correct {
  border-left-color: #39875a;
  background: color-mix(in srgb, #39875a 7%, var(--surface));
}

.choice-review-option.is-correct .choice-review-mark {
  border-color: #39875a;
  background: #39875a;
  color: #fff;
}

.choice-review-option.is-incorrect {
  border-left-color: var(--lapd-red);
  background: color-mix(in srgb, var(--lapd-red) 8%, var(--surface));
}

.choice-review-option.is-incorrect .choice-review-mark {
  border-color: var(--lapd-red);
  background: var(--lapd-red);
  color: #fff;
}

.choice-review-option.is-missed {
  border-left-color: var(--lapd-gold);
}

.choice-review-text {
  color: var(--text);
  font-size: 14px;
  line-height: 1.35;
}

.choice-review-status {
  color: var(--muted);
  font-size: 11px;
  font-weight: 700;
  text-align: right;
}

.choice-review-option.is-correct .choice-review-status {
  color: #287044;
}

.choice-review-option.is-incorrect .choice-review-status {
  color: var(--lapd-red);
}

.choice-review-option.is-missed .choice-review-status {
  color: #8b6d24;
}

:root[data-theme="dark"] .choice-review-option.is-correct .choice-review-status {
  color: #8bd2a0;
}

:root[data-theme="dark"] .choice-review-option.is-missed .choice-review-status {
  color: #e6ce7e;
}

.choice-review-legend {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
  margin-top: 12px;
}

.choice-review-legend span {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: var(--muted);
  font-size: 10px;
}

.choice-review-legend i {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #39875a;
}

.choice-review-legend .legend-incorrect {
  background: var(--lapd-red);
}

.choice-review-legend .legend-missed {
  background: var(--lapd-gold);
}

.academy-footer {
  display: flex;
  min-height: 76px;
  align-items: center;
  gap: 12px;
  padding: 12px max(30px, calc((100vw - 1320px) / 2));
  background: var(--lapd-navy);
  color: #f0f2f2;
}

.footer-insignia {
  display: flex;
  width: 42px;
  height: 36px;
  align-items: center;
  justify-content: center;
  gap: 1px;
  background: transparent;
}

.footer-insignia .book-page {
  width: 16px;
  height: 23px;
  border-width: 1.5px;
}

.academy-footer>span:nth-child(2) {
  display: grid;
  gap: 2px;
}

.academy-footer strong {
  font: 700 11px 'Source Sans 3', sans-serif;
}

.academy-footer small {
  color: #bac6d1;
  font-size: 9px;
}

.footer-classification {
  display: flex;
  align-items: center;
  gap: 9px;
  margin-left: auto;
  color: #bac6d1;
  font-size: 9px;
  font-weight: 700;
}

.footer-classification i {
  width: 6px;
  height: 6px;
}

.you-label,
.admin-role {
  display: inline-flex;
  align-items: center;
  margin-left: 8px;
  padding: 4px 7px;
  border: 1px solid var(--lapd-gold);
  border-radius: 3px;
  background: #f2e9cf;
  color: #5c4918;
  font-size: 9px;
  font-weight: 700;
}

.you-label {
  padding: 2px 5px;
  background: transparent;
  color: var(--lapd-blue);
}

:root[data-theme="dark"] .you-label,
:root[data-theme="dark"] .admin-role {
  background: #40391f;
  color: #edd781;
}

.administrator-set {
  margin: 0 0 20px;
  padding: 17px 19px;
  border: 1px solid #c8ae69;
  border-left: 4px solid var(--lapd-gold);
  border-radius: 5px;
  background: color-mix(in srgb, var(--lapd-gold) 10%, var(--surface));
}

.admin-toggle,
.active-toggle {
  display: flex;
  align-items: flex-start;
  gap: 11px;
}

.admin-toggle input,
.active-toggle input {
  width: 18px;
  height: 18px;
  margin: 2px 0 0;
  accent-color: var(--lapd-navy);
}

.admin-toggle span,
.active-toggle span {
  display: grid;
  gap: 4px;
}

.admin-toggle strong,
.active-toggle strong {
  color: var(--text);
  font-size: 14px;
}

.admin-toggle small,
.active-toggle small {
  color: var(--muted);
  font-size: 12px;
  line-height: 1.4;
}

.active-toggle {
  margin: 0 0 20px;
}

.log-filter {
  display: flex;
  align-items: center;
  gap: 12px;
  margin: 0 0 16px;
}

.log-filter label {
  color: var(--muted);
  font-size: 12px;
  font-weight: 700;
}

.log-filter select {
  min-height: 38px;
  min-width: 190px;
  padding: 6px 10px;
  border: 1px solid var(--line);
  border-radius: 4px;
  background: var(--surface);
  color: var(--text);
}

.log-filter>span {
  margin-left: auto;
  color: var(--muted);
  font-size: 11px;
}

.pool-toolbar {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 16px;
  margin: -10px 0 22px;
}

.pool-selector {
  display: grid;
  min-width: min(100%, 360px);
  gap: 6px;
}

.pool-selector label {
  color: var(--muted);
  font-size: 10px;
  font-weight: 700;
}

.pool-selector select {
  min-height: 42px;
  padding: 8px 11px;
  border: 1px solid var(--line);
  border-left: 3px solid var(--lapd-gold);
  border-radius: 4px;
  background: var(--surface);
  color: var(--text);
  font-weight: 600;
}

.pool-admin-layout {
  display: grid;
  grid-template-columns: minmax(0, 1.45fr) minmax(280px, .75fr);
  align-items: start;
  gap: 34px;
}

.pool-admin-list {
  min-width: 0;
}

.pool-create-sheet h2 {
  margin: 10px 0 20px;
  font: 700 22px 'Barlow Condensed', sans-serif;
  text-transform: uppercase;
}

.pool-admin-table {
  min-width: 560px;
}

.pool-admin-table td:first-child {
  min-width: 180px;
}

.pool-admin-table .row-actions {
  min-width: 116px;
}

.permissions-manager,
.permissions-section {
  margin-bottom: 34px;
}

.personnel-tabs {
  display: flex;
  gap: 24px;
  margin: 0 0 28px;
  border-bottom: 1px solid var(--line);
  overflow-x: auto;
}

.personnel-tabs a {
  flex: none;
  padding: 0 2px 11px;
  border-bottom: 3px solid transparent;
  color: var(--muted);
  font-weight: 600;
  text-decoration: none;
}

.personnel-tabs a:hover,
.personnel-tabs a.active {
  border-bottom-color: var(--lapd-gold);
  color: var(--text);
}

.permissions-section-heading {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 18px;
  margin: 0 0 14px;
  padding-bottom: 13px;
  border-bottom: 1px solid var(--line);
}
.permissions-section-heading h2 {
  margin: 4px 0 0;
  color: var(--text);
  font: 700 27px 'Barlow Condensed', sans-serif;
  text-transform: uppercase;
}
.permission-group-list {
  display: grid;
  border-top: 1px solid var(--line);
}
.permission-group-row {
  display: grid;
  grid-template-columns: 42px minmax(0, 1fr) auto;
  align-items: center;
  gap: 13px;
  min-height: 78px;
  padding: 12px 15px;
  border-bottom: 1px solid var(--line);
  background: var(--surface);
}
.permission-group-row.is-admin-group {
  border-left: 3px solid var(--lapd-gold);
  background: color-mix(in srgb, var(--lapd-gold) 6%, var(--surface));
}
.permission-group-icon {
  display: grid;
  width: 34px;
  height: 34px;
  place-items: center;
  border: 1px solid var(--line);
  border-radius: 50%;
  color: var(--lapd-blue);
  font: 700 15px 'Barlow Condensed', sans-serif;
}
.permission-group-row.is-admin-group .permission-group-icon {
  border-color: var(--lapd-gold);
  color: #8b6d24;
}
.button.danger {
  border-color: var(--lapd-red);
  background: var(--lapd-red);
  color: #fff;
}
.button.danger:hover {
  filter: brightness(.92);
}
.permission-group-copy h3 {
  display: flex;
  align-items: center;
  gap: 8px;
  margin: 0;
  color: var(--text);
  font-size: 14px;
}
.permission-group-copy p {
  margin: 4px 0 0;
  color: var(--muted);
  font-size: 11px;
}
.permission-preview {
  display: flex;
  flex-wrap: wrap;
  gap: 4px 12px;
  margin: 8px 0 0;
  padding: 0;
  color: var(--muted);
  font-size: 11px;
  list-style: none;
}
.permission-preview li::before {
  margin-right: 5px;
  color: var(--lapd-blue);
  content: '·';
}
.permission-preview-empty {
  color: var(--lapd-red) !important;
}
.permission-group-actions {
  display: flex;
  align-items: center;
  gap: 8px;
}
.permission-group-actions form { margin: 0; }
.permission-editor-form { max-width: 920px; }
.permission-editor-kicker { margin: 28px 0 6px; }
.permission-editor-form > .muted { margin: 0 0 18px; font-size: 12px; }
.permission-set { min-width: 0; }
.permission-set legend {
  color: var(--lapd-navy);
  font: 700 16px 'Barlow Condensed', sans-serif;
  text-transform: uppercase;
}
:root[data-theme="dark"] .permission-set legend { color: #e6cf84; }
.permission-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 9px 16px;
}
.permission-choice {
  display: flex;
  align-items: flex-start;
  gap: 9px;
  min-width: 0;
  padding: 8px;
  border-radius: 4px;
  color: var(--text);
  font-size: 12px;
  line-height: 1.35;
}
.permission-choice:hover { background: var(--surface-soft); }
.permission-choice input {
  flex: none;
  width: 16px;
  height: 16px;
  margin: 1px 0 0;
  accent-color: var(--lapd-blue);
}
.permission-choice span { display: grid; gap: 4px; }
.permission-choice strong {
  font-size: 12px;
  font-weight: 600;
}
.permission-help {
  color: var(--muted);
  font-size: 11px;
  font-weight: 400;
  line-height: 1.4;
}
.role-lock-note {
  margin: 18px 0;
  padding: 13px 15px;
  border-left: 3px solid var(--lapd-gold);
  background: var(--surface-soft);
  font-size: 12px;
}

.audit-table {
  min-width: 980px;
}

.audit-category {
  display: inline-flex;
  padding: 4px 7px;
  border-radius: 3px;
  background: var(--surface-soft);
  color: var(--lapd-blue);
  font-size: 11px;
  font-weight: 700;
}

.audit-details {
  margin-top: 6px;
  color: var(--muted);
  font-size: 11px;
}

.audit-details summary {
  cursor: pointer;
  color: var(--lapd-blue);
  font-weight: 600;
}

.audit-details pre {
  max-width: 360px;
  overflow: auto;
  white-space: pre-wrap;
}

.audit-source {
  font-size: 12px;
  font-variant-numeric: tabular-nums;
}

.log-pagination {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 16px;
  padding: 18px 0;
  color: var(--muted);
  font-size: 12px;
}

.row-actions form {
  margin: 0;
}

.row-actions .danger-link {
  color: var(--lapd-red);
}

.messages {
  max-width: 100%;
}

@media (max-width: 950px) {
  .topbar {
    gap: 20px;
    padding-right: 20px;
    padding-left: 20px;
  }

  .nav-links {
    gap: 0;
  }

  .nav-links a {
    gap: 5px;
    padding-right: 8px;
    padding-left: 8px;
    font-size: 13px;
  }

  .nav-links a::after {
    right: 8px;
    left: 8px;
  }

  .network-status {
    display: none;
  }

  .academy-ribbon,
  .academy-footer {
    padding-right: 20px;
    padding-left: 20px;
  }
}

@media (max-width: 700px) {
  .topbar {
    min-height: 72px;
    flex-wrap: wrap;
    padding-top: 9px;
    padding-bottom: 9px;
  }

  .brand-mark {
    width: 43px;
    height: 38px;
  }

  .brand-name small {
    font-size: 8px;
  }

  .brand-name strong {
    font-size: 18px;
  }

  .nav-actions {
    margin-left: auto;
  }

  .nav-actions .user-label {
    display: none;
  }

  .nav-links {
    order: 3;
    flex: 1 0 100%;
    min-height: 34px;
    justify-content: space-between;
    gap: 2px;
  }

  .nav-links a {
    flex: none;
    min-height: 34px;
    padding: 0 5px;
    font-size: 12px;
  }

  .nav-index {
    display: none;
  }

  .academy-ribbon {
    min-height: 34px;
    font-size: 9px;
  }

  .academy-ribbon>div {
    gap: 6px;
  }

  .page-shell {
    min-height: calc(100vh - 220px);
    padding: 34px 18px 54px;
  }

  .page-heading {
    align-items: flex-start;
  }

  .page-heading h1,
  .auth-aside h1,
  .exam-access h1,
  .completion h1 {
    font-size: 43px;
  }

  .stat-strip>div {
    min-height: 76px;
    padding: 12px 13px;
  }

  .stat-strip>div:first-child {
    padding-left: 14px;
  }

  .stat-strip strong {
    font-size: 28px;
  }

  .stat-strip span {
    font-size: 10px;
  }

  .register-heading {
    min-height: 38px;
    padding: 0 9px;
    font-size: 9px;
  }

  .table-wrap:has(.question-register-table) {
    overflow: visible;
    border: 0;
    background: transparent;
  }

  .question-register-table,
  .question-register-table tbody {
    display: block;
    width: 100%;
    min-width: 0;
  }

  .question-register-table thead {
    display: none;
  }

  .question-register-table tbody tr {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 5px 12px;
    margin-bottom: 9px;
    padding: 11px 14px;
    border: 1px solid var(--line);
    border-left: 3px solid var(--lapd-blue);
    background: var(--surface);
  }

  .question-register-table td {
    display: flex;
    min-height: 0;
    align-items: center;
    gap: 7px;
    padding: 3px 0;
    border: 0;
  }

  .question-register-table td:first-child {
    grid-column: 1 / -1;
    padding-bottom: 8px;
    border-bottom: 1px solid var(--line);
  }

  .question-register-table td:nth-child(2)::before {
    content: 'FORMAT';
    color: var(--muted);
    font-size: 9px;
    font-weight: 700;
  }

  .question-register-table td:nth-child(3) {
    justify-content: flex-end;
  }

  .question-register-table td:nth-child(3)::before {
    content: 'WERTUNG';
    color: var(--muted);
    font-size: 9px;
    font-weight: 700;
  }

  .question-register-table td:nth-child(4) {
    grid-column: 1;
  }

  .question-register-table td:nth-child(4)::before {
    content: 'STATUS';
    color: var(--muted);
    font-size: 9px;
    font-weight: 700;
  }

  .question-register-table td:nth-child(5) {
    grid-column: 2;
    grid-row: 3;
  }

  .question-register-table td.row-actions {
    display: flex;
  }

  .table-wrap:has(.test-results-table),
  .table-wrap:has(.academy-staff-table) {
    overflow: visible;
    border: 0;
    background: transparent;
  }

  .test-results-table,
  .test-results-table tbody,
  .academy-staff-table,
  .academy-staff-table tbody {
    display: block;
    width: 100%;
    min-width: 0;
  }

  .test-results-table thead,
  .academy-staff-table thead {
    display: none;
  }

  .test-results-table tbody tr,
  .academy-staff-table tbody tr {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 7px 12px;
    margin-bottom: 9px;
    padding: 12px 14px;
    border: 1px solid var(--line);
    border-left: 3px solid var(--lapd-gold);
    background: var(--surface);
  }

  .test-results-table td,
  .academy-staff-table td {
    display: flex;
    min-width: 0;
    align-items: center;
    gap: 7px;
    padding: 3px 0;
    border: 0;
    overflow-wrap: anywhere;
  }

  .test-results-table td:first-child,
  .academy-staff-table td:first-child {
    grid-column: 1 / -1;
    padding-bottom: 8px;
    border-bottom: 1px solid var(--line);
  }

  .test-results-table td:nth-child(2) {
    grid-column: 1 / -1;
  }

  .test-results-table td:nth-child(2)::before {
    content: 'PRÜFUNGSTYP';
    color: var(--muted);
    font-size: 9px;
    font-weight: 700;
  }

  .test-results-table td:nth-child(3)::before {
    content: 'PRÜFLING';
    color: var(--muted);
    font-size: 9px;
    font-weight: 700;
  }

  .test-results-table td:nth-child(4) {
    grid-column: 1 / -1;
  }

  .test-results-table td:nth-child(4)::before {
    content: 'ABGABE';
    color: var(--muted);
    font-size: 9px;
    font-weight: 700;
  }

  .test-results-table td:nth-child(5) {
    justify-content: flex-end;
  }

  .test-results-table td:nth-child(5)::before {
    content: 'PUNKTE';
    color: var(--muted);
    font-size: 9px;
    font-weight: 700;
  }

  .test-results-table td:nth-child(6) {
    grid-column: 1;
  }

  .test-results-table td:nth-child(6)::before {
    content: 'STATUS';
    color: var(--muted);
    font-size: 9px;
    font-weight: 700;
  }

  .test-results-table td:nth-child(7) {
    grid-column: 2;
    grid-row: 7;
  }

  .pool-toolbar {
    align-items: stretch;
    flex-direction: column;
  }

  .pool-toolbar>.button {
    align-self: flex-start;
  }

  .pool-admin-layout {
    grid-template-columns: 1fr;
    gap: 22px;
  }

  .pool-admin-list .table-wrap {
    overflow-x: auto;
  }

  .pool-admin-table {
    min-width: 560px;
  }

  .permission-grid {
    grid-template-columns: 1fr;
  }

  .permission-group-row {
    grid-template-columns: 36px minmax(0, 1fr);
  }

  .permission-group-actions {
    grid-column: 2;
  }

  .academy-staff-table td:nth-child(2) {
    grid-column: 1 / -1;
  }

  .academy-staff-table td:nth-child(2)::before {
    content: 'BENUTZERNAME';
    color: var(--muted);
    font-size: 9px;
    font-weight: 700;
  }

  .academy-staff-table td:nth-child(3) {
    grid-column: 1 / -1;
    flex-wrap: wrap;
  }

  .academy-staff-table td:nth-child(3)::before {
    content: 'RECHTEGRUPPEN';
    flex-basis: 100%;
    color: var(--muted);
    font-size: 9px;
    font-weight: 700;
  }

  .academy-staff-table td:nth-child(4) {
    grid-column: 1;
  }

  .academy-staff-table td:nth-child(4)::before {
    content: 'STATUS';
    color: var(--muted);
    font-size: 9px;
    font-weight: 700;
  }

  .academy-staff-table td:nth-child(5) {
    grid-column: 2;
    grid-row: 5;
  }

  .audit-table {
    min-width: 980px;
  }

  .log-filter {
    flex-wrap: wrap;
  }

  .log-filter>span {
    flex-basis: 100%;
    margin-left: 0;
  }

  .academy-footer {
    min-height: 66px;
    padding-right: 18px;
    padding-left: 18px;
  }

  .footer-classification {
    font-size: 8px;
  }
}

@media (max-width: 560px) {
  .choice-review-option {
    grid-template-columns: 22px minmax(0, 1fr);
    gap: 8px;
  }

  .choice-review-status {
    grid-column: 2;
    text-align: left;
  }

  .choice-review-legend {
    gap: 9px;
  }
}

@media (max-width: 480px) {
  .topbar {
    padding-right: 14px;
    padding-left: 14px;
  }

  .brand {
    gap: 8px;
  }

  .brand-mark {
    width: 38px;
    height: 35px;
  }

  .brand-name small {
    font-size: 7px;
  }

  .brand-name strong {
    font-size: 16px;
  }

  .brand-name em {
    font-size: 9px;
  }

  .nav-actions {
    gap: 8px;
  }

  .nav-actions .text-button {
    font-size: 11px;
  }

  .academy-ribbon {
    padding-right: 14px;
    padding-left: 14px;
  }

  .page-shell {
    padding-right: 14px;
    padding-left: 14px;
  }

  .page-heading h1,
  .auth-aside h1,
  .exam-access h1,
  .completion h1 {
    font-size: 38px;
  }

  .stat-strip>div {
    align-items: flex-start;
  }

  .stat-strip span {
    max-width: 82px;
    line-height: 1.2;
  }

  .register-heading>span {
    max-width: 120px;
    text-align: right;
  }

  .academy-footer {
    gap: 8px;
    padding-right: 14px;
    padding-left: 14px;
  }

  .footer-insignia {
    width: 35px;
    height: 31px;
  }

  .academy-footer strong {
    font-size: 9px;
  }

  .academy-footer small {
    font-size: 7px;
  }

  .footer-classification {
    max-width: 90px;
    line-height: 1.2;
  }
}