:root {
  --ink: #0f1c24;
  --ink-soft: #243742;
  --paper: #f3f6f4;
  --paper-2: #e7eee9;
  --line: #c9d5ce;
  --accent: #0f7a62;
  --accent-2: #146c8a;
  --warn: #b4541e;
  --danger: #a1262f;
  --ok: #1f7a3f;
  --terminal: #0b1512;
  --terminal-fg: #b7f0c8;
  --terminal-dim: #6f9a7d;
  --shadow: 0 18px 40px rgba(15, 28, 36, 0.08);
  --radius: 18px;
  --font: "Sora", sans-serif;
  --mono: "IBM Plex Mono", ui-monospace, monospace;
}

* { box-sizing: border-box; }

body {
  margin: 0;
  min-height: 100vh;
  font-family: var(--font);
  color: var(--ink);
  background:
    radial-gradient(circle at top right, rgba(20, 108, 138, 0.12), transparent 32%),
    radial-gradient(circle at 10% 20%, rgba(15, 122, 98, 0.10), transparent 28%),
    linear-gradient(180deg, #f7faf8 0%, var(--paper) 45%, #edf2ef 100%);
}

a { color: inherit; text-decoration: none; }

.arena-nav {
  position: sticky;
  top: 0;
  z-index: 20;
  backdrop-filter: blur(12px);
  background: rgba(243, 246, 244, 0.86);
  border-bottom: 1px solid rgba(201, 213, 206, 0.9);
}

.arena-nav .container-xl,
.arena-main .container-xl,
.arena-footer .container-xl {
  padding-top: 0.95rem;
  padding-bottom: 0.95rem;
}

.brand {
  display: flex;
  align-items: center;
  gap: 0.8rem;
}

.brand-mark {
  width: 2.2rem;
  height: 2.2rem;
  border-radius: 0.7rem;
  background:
    linear-gradient(135deg, var(--accent), #1aa885 55%, var(--accent-2));
  box-shadow: inset 0 0 0 2px rgba(255,255,255,0.25);
}

.brand-text {
  display: flex;
  flex-direction: column;
  line-height: 1.1;
}

.brand-text strong {
  font-size: 0.95rem;
  letter-spacing: 0.04em;
}

.brand-text small {
  color: #5b6d66;
  font-size: 0.72rem;
}

.nav-links {
  display: flex;
  gap: 0.35rem;
}

.nav-links a {
  padding: 0.45rem 0.85rem;
  border-radius: 999px;
  color: #41554d;
  font-size: 0.92rem;
  font-weight: 500;
}

.nav-links a.active,
.nav-links a:hover {
  background: #dff0e8;
  color: var(--accent);
}

.user-chip {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  flex: none;
}

.acct-btn {
  display: inline-flex; align-items: center; gap: 0.45rem; height: 2.55rem; padding: 0.15rem 0.65rem 0.15rem 0.18rem;
  border: 1px solid var(--line); border-radius: 999px; background: rgba(255, 255, 255, 0.7);
  color: var(--ink); font-size: 0.88rem; font-weight: 600; transition: border-color 0.15s ease, color 0.15s ease;
}
.acct-btn:hover, .acct-btn[aria-expanded="true"] { border-color: var(--accent); color: var(--accent); }
.acct-btn:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
.acct-btn .avatar-sm { width: 2.1rem; height: 2.1rem; }
.acct-name { max-width: 8rem; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.acct-caret { width: 0.75rem; height: 0.75rem; flex: none; transition: transform 0.15s ease; }
.acct-btn[aria-expanded="true"] .acct-caret { transform: rotate(180deg); }
.acct-menu {
  width: 17.5rem; max-width: calc(100vw - 1.5rem); padding: 0.4rem; margin-top: 0.4rem !important;
  border: 1px solid var(--line); border-radius: 14px; box-shadow: 0 18px 40px rgba(15, 28, 36, 0.16);
}
.acct-head { display: flex; align-items: center; gap: 0.75rem; padding: 0.55rem 0.6rem; border-radius: 10px; color: inherit; }
.acct-head:hover { background: color-mix(in srgb, var(--accent) 8%, transparent); }
.acct-who { display: flex; flex-direction: column; gap: 0.1rem; min-width: 0; line-height: 1.25; }
.acct-who strong { font-size: 0.92rem; overflow-wrap: anywhere; }
.acct-who small { font-size: 0.76rem; color: #5b6d66; }
.acct-who .server-tag { align-self: flex-start; margin-top: 0.25rem; }
.acct-menu .dropdown-divider { margin: 0.3rem 0.2rem; }
.acct-item { display: flex; align-items: center; gap: 0.65rem; padding: 0.5rem 0.65rem; border-radius: 9px; font-size: 0.9rem; color: #33463f; }
.acct-item .arena-icon { opacity: 0.75; }
.acct-item:hover, .acct-item:focus { background: #dff0e8; color: var(--accent); }
.acct-item.active, .acct-item:active { background: color-mix(in srgb, var(--accent) 14%, transparent); color: var(--accent); }
.acct-count { margin-left: auto; min-width: 1.3rem; padding: 0 0.4rem; border-radius: 999px; font-size: 0.7rem; line-height: 1.3rem; text-align: center; color: #fff; background: var(--danger); }
.acct-logout, .acct-logout:hover, .acct-logout:focus { color: #b42318; }
.acct-logout:hover { background: #fdecea; }
@media (max-width: 1399.98px) { .arena-nav .brand-text small { display: none; } }
@media (max-width: 1199.98px) { .acct-name { display: none; } .acct-btn { padding-right: 0.5rem; } }

.nav-mobile-only { display: none; }
.nav-toggle {
  display: none; flex-direction: column; justify-content: center; gap: 4px;
  width: 2.4rem; height: 2.4rem; padding: 0 0.6rem; border: 0; border-radius: 999px;
  background: #e8efeb; color: var(--ink-soft);
}
.nav-toggle span { display: block; height: 2px; border-radius: 2px; background: currentColor; transition: transform 0.18s ease, opacity 0.18s ease; }
.nav-open .nav-toggle span:nth-child(1) { transform: translateY(6px) rotate(45deg); }
.nav-open .nav-toggle span:nth-child(2) { opacity: 0; }
.nav-open .nav-toggle span:nth-child(3) { transform: translateY(-6px) rotate(-45deg); }

@media (max-width: 575.98px) {
  .user-chip { gap: 0.35rem; min-width: 0; }
  .acct-btn { padding: 0.15rem; }
  .acct-caret { display: none; }
}

.btn-arena,
.btn-ghost {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 0;
  border-radius: 999px;
  padding: 0.65rem 1.15rem;
  font-weight: 600;
  font-size: 0.9rem;
  transition: transform 0.15s ease, box-shadow 0.15s ease, background 0.15s ease;
}

.nav-bell {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 2.3rem;
  height: 2.3rem;
  border: 0;
  border-radius: 999px;
  background: #e8efeb;
  color: var(--ink-soft);
}
.nav-bell.has-items { color: var(--warn); animation: bell-ring 2.5s ease-in-out 1s 2; }
.nav-bell:hover, .nav-bell.is-current { color: var(--accent); background: color-mix(in srgb, var(--accent) 15%, #fff); }
.nav-bell-count {
  position: absolute;
  top: -0.3rem;
  right: -0.35rem;
  min-width: 1.2rem;
  height: 1.2rem;
  padding: 0 0.3rem;
  border-radius: 999px;
  background: var(--danger);
  color: #fff;
  font-size: 0.68rem;
  font-weight: 700;
  line-height: 1.2rem;
  text-align: center;
}
@keyframes bell-ring {
  0%, 20%, 100% { transform: rotate(0); }
  5% { transform: rotate(14deg); }
  10% { transform: rotate(-12deg); }
  15% { transform: rotate(8deg); }
}

.monitor-stats {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(170px, 1fr));
  gap: 0.85rem;
}
.presence-dot {
  display: inline-block;
  width: 0.6rem;
  height: 0.6rem;
  margin-right: 0.35rem;
  border-radius: 50%;
  background: #9aa8a2;
  vertical-align: middle;
}
.presence-dot.online { background: var(--ok); box-shadow: 0 0 0 3px rgba(31, 122, 63, 0.18); animation: presence-pulse 2s infinite; }
.presence-dot.idle { background: #d39b22; }
.presence-text.online { color: var(--ok); }
.presence-text.idle { color: #b07d10; }
.presence-text.away { color: #7d8b85; }
@keyframes presence-pulse {
  0%, 100% { box-shadow: 0 0 0 3px rgba(31, 122, 63, 0.18); }
  50% { box-shadow: 0 0 0 6px rgba(31, 122, 63, 0.05); }
}

.reminder-modal .modal-content { border-radius: 18px; border: 1px solid var(--line); }
.reminder-item {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 0.7rem 0.85rem;
  margin-bottom: 0.5rem;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: #fff;
}
.reminder-item.urgent { border-color: var(--danger); background: #fff6f6; }
.reminder-item .tag { margin-right: 0.35rem; }

.btn-arena {
  background: linear-gradient(135deg, var(--accent), #128a6d);
  color: #fff;
  box-shadow: 0 10px 24px rgba(15, 122, 98, 0.25);
}

.btn-arena:hover { transform: translateY(-1px); color: #fff; }

.btn-ghost {
  background: transparent;
  border: 1px solid var(--line);
  color: var(--ink-soft);
}

.arena-main { padding: 1.5rem 0 3rem; min-height: calc(100vh - 140px); }

.arena-footer {
  border-top: 1px solid var(--line);
  color: #62756c;
  font-size: 0.82rem;
  background: rgba(255,255,255,0.35);
}

.panel {
  background: rgba(255,255,255,0.78);
  border: 1px solid rgba(201, 213, 206, 0.95);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 1.25rem 1.35rem;
}

.hero-panel {
  display: grid;
  grid-template-columns: 1.4fr 1fr;
  gap: 1.25rem;
  align-items: stretch;
}

.kicker {
  display: inline-block;
  font-family: var(--mono);
  font-size: 0.75rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--accent-2);
  margin-bottom: 0.6rem;
}

h1, h2, h3 { letter-spacing: -0.02em; }

.stat-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 0.85rem;
}

.stat-card {
  background: linear-gradient(180deg, #ffffff, #f2f7f4);
  border: 1px solid var(--line);
  border-radius: 14px;
  padding: 1rem;
}

.stat-card span {
  display: block;
  color: #63756d;
  font-size: 0.78rem;
  margin-bottom: 0.35rem;
}

.stat-card strong {
  font-size: 1.45rem;
  font-weight: 700;
}

.level-list,
.mission-list {
  display: grid;
  gap: 0.85rem;
}

.level-card,
.mission-card {
  display: grid;
  grid-template-columns: auto 1fr auto;
  gap: 1rem;
  align-items: center;
  padding: 1rem 1.1rem;
  border-radius: 14px;
  border: 1px solid var(--line);
  background: #fff;
}

.level-card.locked { opacity: 0.55; }

.level-num {
  width: 2.6rem;
  height: 2.6rem;
  border-radius: 12px;
  display: grid;
  place-items: center;
  background: #dff0e8;
  color: var(--accent);
  font-weight: 700;
  font-family: var(--mono);
}

.level-card.locked .level-num {
  background: #eceff0;
  color: #7a8782;
}

.tag {
  display: inline-flex;
  align-items: center;
  padding: 0.2rem 0.55rem;
  border-radius: 999px;
  font-size: 0.72rem;
  font-weight: 600;
  background: #e7f3ee;
  color: var(--accent);
}

.tag.warn { background: #f8e8dc; color: var(--warn); }
.tag.ok { background: #e3f3e8; color: var(--ok); }
.tag.muted { background: #eceff0; color: #66756f; }
.tag.bad { background: #fbe4e4; color: #b42318; }

.auth-shell {
  min-height: 100vh;
  display: grid;
  place-items: center;
  padding: 2rem 1rem;
}

.auth-card {
  width: min(440px, 100%);
  background: rgba(255,255,255,0.9);
  border: 1px solid var(--line);
  border-radius: 24px;
  box-shadow: var(--shadow);
  padding: 2rem 1.6rem;
}

.auth-card h1 {
  font-size: 1.7rem;
  margin-bottom: 0.35rem;
}

.auth-card .lead {
  color: #5d6f68;
  margin-bottom: 1.4rem;
}

.form-label { font-weight: 600; font-size: 0.88rem; }

.form-control, .form-select {
  border-radius: 12px;
  border-color: var(--line);
  padding: 0.7rem 0.85rem;
  font-family: var(--font);
}

.form-control:focus, .form-select:focus {
  border-color: var(--accent);
  box-shadow: 0 0 0 0.2rem rgba(15, 122, 98, 0.15);
}

.demo-box {
  margin-top: 1rem;
  padding: 0.85rem 1rem;
  border-radius: 12px;
  background: #eef5f1;
  font-size: 0.85rem;
  color: #41554d;
}

.mission-layout {
  display: grid;
  grid-template-columns: 1.05fr 0.95fr;
  gap: 1rem;
}

.terminal {
  background: var(--terminal);
  color: var(--terminal-fg);
  border-radius: 16px;
  padding: 1rem;
  min-height: 320px;
  font-family: var(--mono);
  box-shadow: inset 0 0 0 1px rgba(183, 240, 200, 0.08);
}

.terminal-header {
  display: flex;
  justify-content: space-between;
  color: var(--terminal-dim);
  font-size: 0.75rem;
  margin-bottom: 0.75rem;
  border-bottom: 1px solid rgba(183, 240, 200, 0.12);
  padding-bottom: 0.55rem;
}

.terminal-body {
  height: 240px;
  overflow: auto;
  white-space: pre-wrap;
  font-size: 0.84rem;
  line-height: 1.45;
}

.terminal-input-row {
  display: flex;
  gap: 0.5rem;
  margin-top: 0.75rem;
}

.terminal-input-row input {
  flex: 1;
  background: #102019;
  border: 1px solid rgba(183, 240, 200, 0.18);
  color: var(--terminal-fg);
  border-radius: 10px;
  padding: 0.55rem 0.7rem;
  font-family: var(--mono);
}

.terminal-input-row button {
  background: #1c5f49;
  color: #dff8e8;
  border: 0;
  border-radius: 10px;
  padding: 0.55rem 0.9rem;
  font-family: var(--mono);
  font-weight: 600;
}

.config-table {
  width: 100%;
  font-family: var(--mono);
  font-size: 0.86rem;
}

.config-table th {
  text-align: left;
  color: #61736c;
  font-weight: 500;
  width: 38%;
  padding: 0.45rem 0;
}

.config-table td {
  padding: 0.45rem 0;
  color: var(--ink);
}

.choice-grid {
  display: grid;
  gap: 0.55rem;
}

.choice-grid label {
  display: flex;
  gap: 0.7rem;
  align-items: flex-start;
  padding: 0.8rem 0.9rem;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: #fff;
  cursor: pointer;
}

.choice-grid label:hover,
.choice-grid label:has(input:checked) {
  border-color: var(--accent);
  background: #eef8f3;
}

.fix-row {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 0.6rem;
  margin-top: 0.85rem;
}

.result-banner {
  display: none;
  margin-top: 1rem;
  padding: 0.9rem 1rem;
  border-radius: 12px;
  font-weight: 600;
}

.result-banner.show { display: block; }
.result-banner.success { background: #e3f3e8; color: var(--ok); }
.result-banner.fail { background: #f8e4e6; color: var(--danger); }

.topic-pills {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
  margin-top: 0.55rem;
}

.topic-pills span {
  background: #e8efeb;
  color: #41554d;
  border-radius: 999px;
  padding: 0.2rem 0.55rem;
  font-size: 0.72rem;
}

.host-table code {
  font-family: var(--mono);
  font-size: 0.82rem;
  color: var(--accent-2);
}

.host-table thead th {
  font-size: 0.78rem;
  color: #61736c;
  font-weight: 600;
}

.scan-card {
  background: #0b1512;
  border-radius: 12px;
  padding: 0.85rem 1rem;
  border: 1px solid rgba(183, 240, 200, 0.12);
}

.scan-pre {
  margin: 0;
  color: #b7f0c8;
  font-family: var(--mono);
  font-size: 0.78rem;
  white-space: pre-wrap;
  line-height: 1.45;
}

.req-list {
  margin: 0;
  padding-left: 1.1rem;
  color: #41554d;
  font-size: 0.9rem;
}

.req-list li { margin-bottom: 0.35rem; }

.fw-table .form-select-sm {
  font-family: var(--mono);
  font-size: 0.78rem;
}

.test-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 0.75rem;
  padding: 0.45rem 0;
  border-bottom: 1px solid var(--line);
  font-size: 0.86rem;
}

.test-row:last-child { border-bottom: 0; }

.btn-sm {
  padding: 0.3rem 0.65rem;
  font-size: 0.75rem;
}

@media (min-width: 992px) {
  .mission-layout-wide {
    grid-template-columns: 1.25fr 0.85fr;
  }
}

.packet-scroll {
  max-height: 340px;
  overflow: auto;
  border: 1px solid var(--line);
  border-radius: 12px;
}

.packet-table {
  font-family: var(--mono);
  font-size: 0.78rem;
  margin-bottom: 0;
}

.packet-table thead th {
  position: sticky;
  top: 0;
  background: #eef5f1;
  z-index: 1;
}

.packet-row {
  cursor: pointer;
}

.packet-row:hover {
  background: #f3faf6;
}

.packet-row.is-selected {
  background: #dff0e8;
}

.packet-row.is-suspicious td:first-child {
  box-shadow: inset 3px 0 0 var(--warn);
}

.packet-detail {
  background: #0b1512;
  color: #b7f0c8;
  border-radius: 12px;
  padding: 0.85rem 1rem;
  font-family: var(--mono);
  font-size: 0.8rem;
}

.packet-detail-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.55rem 1rem;
}

.packet-detail-grid .full { grid-column: 1 / -1; }

.packet-detail-grid span {
  display: block;
  color: #6f9a7d;
  font-size: 0.72rem;
}

.packet-detail-grid strong {
  font-weight: 500;
  color: #dff8e8;
}

.alert-hero {
  border-radius: 14px;
  padding: 1rem 1.1rem;
  border: 1px solid var(--line);
  background: linear-gradient(180deg, #fff7f2, #fff);
}

.alert-hero.severity-high {
  border-color: #efc2b0;
  box-shadow: inset 4px 0 0 var(--warn);
}

.catalog-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.55rem;
}

.catalog-card {
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 0.7rem 0.8rem;
  background: #fff;
  cursor: pointer;
}

.catalog-card:hover,
.catalog-card.active {
  border-color: var(--accent);
  background: #eef8f3;
}

.catalog-card strong {
  display: block;
  font-size: 0.86rem;
  margin-bottom: 0.25rem;
}

.catalog-card p {
  margin: 0;
  font-size: 0.75rem;
  color: #5d6f68;
}

@media (max-width: 700px) {
  .catalog-grid { grid-template-columns: 1fr; }
}

.soc-stats {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 0.55rem;
}

.soc-stat {
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 0.7rem 0.8rem;
  background: #fff;
}

.soc-stat span {
  display: block;
  font-size: 0.72rem;
  color: #62756c;
  margin-bottom: 0.2rem;
}

.soc-stat strong { font-size: 1.35rem; }
.soc-stat.critical { box-shadow: inset 3px 0 0 var(--danger); }
.soc-stat.high { box-shadow: inset 3px 0 0 var(--warn); }
.soc-stat.medium { box-shadow: inset 3px 0 0 #c4a035; }
.soc-stat.low { box-shadow: inset 3px 0 0 #6f9a7d; }

.alert-queue {
  display: grid;
  gap: 0.5rem;
  max-height: 420px;
  overflow: auto;
}

.queue-item {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 0.7rem;
  align-items: start;
  padding: 0.75rem 0.85rem;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: #fff;
  cursor: pointer;
}

.queue-item:has(input:checked) {
  border-color: var(--accent);
  background: #eef8f3;
}

.queue-item.severity-critical { border-left: 3px solid var(--danger); }
.queue-item.severity-high { border-left: 3px solid var(--warn); }
.queue-item.severity-medium { border-left: 3px solid #c4a035; }
.queue-item.severity-low { border-left: 3px solid #6f9a7d; }

.workflow-steps {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
}

.wf-step {
  padding: 0.3rem 0.65rem;
  border-radius: 999px;
  background: #eceff0;
  color: #66756f;
  font-size: 0.75rem;
  font-weight: 600;
}

.wf-step.done {
  background: #e3f3e8;
  color: var(--ok);
}

@media (max-width: 700px) {
  .soc-stats { grid-template-columns: 1fr 1fr; }
}

.ir-tabs {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem;
}

.ir-tab {
  border: 1px solid var(--line);
  background: #fff;
  border-radius: 999px;
  padding: 0.35rem 0.75rem;
  font-size: 0.78rem;
  font-weight: 600;
  color: #41554d;
}

.ir-tab.active {
  background: #dff0e8;
  border-color: #b7dccb;
  color: var(--accent);
}

.topo-palette {
  display: flex;
  flex-wrap: wrap;
  gap: 0.45rem;
}

.topo-chip {
  border: 1px solid var(--line);
  background: #fff;
  border-radius: 999px;
  padding: 0.4rem 0.75rem;
  font-size: 0.8rem;
  font-weight: 600;
  cursor: grab;
}

.topo-chip.placed {
  cursor: pointer;
  background: #eef8f3;
  border-color: #b7dccb;
}

.topo-zones {
  display: grid;
  gap: 0.75rem;
}

.topo-zone {
  border: 1px solid var(--line);
  border-radius: 14px;
  padding: 0.75rem;
  background: #fff;
}

.topo-zone strong {
  display: block;
  margin-bottom: 0.55rem;
  font-size: 0.9rem;
}

.topo-drop {
  min-height: 64px;
  border: 1px dashed #b7c7bf;
  border-radius: 12px;
  padding: 0.55rem;
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
  background: #f7faf8;
}

.ctf-timer {
  font-family: var(--mono);
  font-size: 1.4rem;
  font-weight: 700;
  color: var(--accent-2);
  background: #eef5f1;
  border-radius: 12px;
  padding: 0.45rem 0.8rem;
}

.ctf-timer.over {
  color: var(--danger);
  background: #f8e4e6;
}

.admin-subnav {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem;
}

.admin-subnav a {
  padding: 0.4rem 0.8rem;
  border-radius: 999px;
  background: #e8efeb;
  color: #41554d;
  font-size: 0.82rem;
  font-weight: 600;
}

.admin-subnav a.active,
.admin-subnav a:hover {
  background: #dff0e8;
  color: var(--accent);
}

/* Admin / faculty section menu: one bar of category dropdowns, tabs for the current category */
.snav { border: 1px solid rgba(0, 0, 0, 0.07); border-radius: 16px; background: rgba(255, 255, 255, 0.7); box-shadow: 0 6px 18px rgba(16, 42, 32, 0.05); }
.snav-bar { display: flex; gap: 0.3rem; padding: 0.4rem; overflow-x: auto; scrollbar-width: thin; }
.snav-btn {
  display: inline-flex; align-items: center; gap: 0.45rem; white-space: nowrap;
  padding: 0.5rem 0.85rem; border: 0; border-radius: 11px; background: transparent;
  color: #41554d; font-size: 0.88rem; font-weight: 600; transition: background 0.15s ease, color 0.15s ease;
}
.snav-btn:hover, .snav-btn[aria-expanded="true"] { background: #e8f2ed; color: var(--accent); }
.snav-btn::after { content: ""; width: 0.4rem; height: 0.4rem; margin-left: 0.1rem; border-right: 2px solid currentColor; border-bottom: 2px solid currentColor; transform: translateY(-2px) rotate(45deg); opacity: 0.55; }
.snav-group.is-current .snav-btn { background: var(--accent); color: #fff; }
.snav-btn .arena-icon { color: inherit; }
.snav-count { min-width: 1.25rem; padding: 0 0.35rem; border-radius: 999px; background: rgba(15, 118, 110, 0.12); font-size: 0.68rem; line-height: 1.25rem; text-align: center; }
.snav-group.is-current .snav-count { background: rgba(255, 255, 255, 0.25); }
.snav-menu { min-width: 17rem; padding: 0.4rem; border-radius: 14px; border: 1px solid rgba(0, 0, 0, 0.08); box-shadow: 0 14px 34px rgba(16, 42, 32, 0.14); }
.snav-menu-head { padding: 0.35rem 0.65rem 0.4rem; font-family: 'IBM Plex Mono', monospace; font-size: 0.66rem; font-weight: 600; letter-spacing: 0.08em; text-transform: uppercase; opacity: 0.6; }
.snav-menu .dropdown-item { display: flex; flex-direction: column; gap: 0.05rem; padding: 0.45rem 0.65rem; border-radius: 9px; white-space: normal; }
.snav-menu .dropdown-item strong { font-size: 0.88rem; font-weight: 600; }
.snav-menu .dropdown-item small { font-size: 0.74rem; opacity: 0.7; }
.snav-menu .dropdown-item:hover { background: #e8f2ed; color: var(--accent); }
.snav-menu .dropdown-item.active { background: color-mix(in srgb, var(--accent) 12%, transparent); color: var(--accent); }
.snav-tabs { display: flex; gap: 0.15rem; padding: 0 0.6rem; border-top: 1px solid rgba(0, 0, 0, 0.06); overflow-x: auto; overflow-y: hidden; scrollbar-width: thin; }
.snav-tabs a { position: relative; padding: 0.6rem 0.75rem; color: #5b6d66; font-size: 0.86rem; font-weight: 500; white-space: nowrap; }
.snav-tabs a:hover { color: var(--accent); }
.snav-tabs a.active { color: var(--accent); font-weight: 600; }
.snav-tabs a.active::after { content: ""; position: absolute; left: 0.6rem; right: 0.6rem; bottom: -1px; height: 3px; border-radius: 3px 3px 0 0; background: var(--accent); }
@media (max-width: 575.98px) {
  .snav-btn { padding: 0.45rem 0.65rem; font-size: 0.84rem; }
  .snav-count { display: none; }
}
.class-context a {
  display: inline-block;
  padding: 0.4rem 0.9rem;
  border-radius: 999px;
  background: #fff7e0;
  border: 1px solid #f0dfa8;
  color: #6b5414;
  font-size: 0.85rem;
}
.class-context a:hover { background: #fff0c2; }

/* Course picker scope: my class courses / all courses */
.scope-bar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem;
  margin-bottom: 0.75rem;
  padding: 0.5rem 0.75rem;
  border-radius: 12px;
  background: #eef7f2;
  border: 1px solid #cfe7da;
  font-size: 0.85rem;
}
.scope-bar.scope-all { background: #fff7e0; border-color: #f1dfa6; }

/* Server label (Admin → Settings → Server Label) */
.server-tag,
.user-meta .server-tag {
  display: inline-flex; align-items: center; gap: 0.3rem;
  margin-top: 0.2rem; padding: 0.12rem 0.5rem; border-radius: 999px;
  font-size: 0.62rem; font-weight: 700; letter-spacing: 0.06em; line-height: 1.3; white-space: nowrap;
}
.server-tag::before { content: ""; width: 0.45rem; height: 0.45rem; border-radius: 50%; background: currentColor; }
.server-tag.server-live,
.user-meta .server-tag.server-live { background: #d9f7e6; color: #0b7a43; border: 1px solid #8fdcb3; }
.server-tag.server-live::before { animation: server-pulse 1.8s ease-in-out infinite; }
.server-tag.server-local,
.user-meta .server-tag.server-local { background: #fff1d6; color: #9a5b00; border: 1px solid #f3c66b; }
@keyframes server-pulse { 50% { opacity: 0.35; } }
.server-bar { font-size: 0.82rem; padding: 0.35rem 0; border-bottom: 1px solid transparent; }
.server-bar .container-xl { display: flex; align-items: center; gap: 0.6rem; flex-wrap: wrap; }
.server-bar .server-tag { margin-top: 0; }
.server-bar.server-live { background: #eefbf3; color: #1d5c3c; border-bottom-color: #c5ecd5; }
.server-bar.server-local { background: #fff8e8; color: #6e4a07; border-bottom-color: #f6dda3; }
.server-choice { display: flex; gap: 0.6rem; align-items: flex-start; flex: 1 1 15rem; padding: 0.75rem 0.9rem; border: 1px solid #d7e4de; border-radius: 12px; cursor: pointer; }
.server-choice:has(input:checked) { border-color: var(--accent); box-shadow: 0 0 0 2px rgba(15, 118, 110, 0.15); }
.server-choice > span { display: flex; flex-direction: column; gap: 0.3rem; align-items: flex-start; }
.server-choice small { color: #5b6d66; font-size: 0.78rem; }

/* Custom menu links (Admin → Settings → Menu Links) */
.nav-links .nav-ext { font-size: 0.7em; margin-left: 0.2rem; opacity: 0.6; }
.nav-links .nav-dropdown { display: flex; }
.nav-links .dropdown-menu { border-radius: 12px; padding: 0.35rem; min-width: 12rem; }
.nav-links .dropdown-menu .dropdown-item { border-radius: 8px; padding: 0.4rem 0.7rem; font-size: 0.9rem; color: #41554d; }
.nav-links .dropdown-menu .dropdown-item:hover { background: #dff0e8; color: var(--accent); }

/* Practice Lab menu */
.nav-links .pl-menu { width: 40rem; max-width: calc(100vw - 1.5rem); max-height: calc(100vh - 4.5rem); overflow-y: auto; padding: 0.5rem; }
.nav-links .pl-menu.pl-narrow { width: 21rem; }
.pl-top, .pl-cols, .pl-tools { display: grid; grid-template-columns: 1fr 1fr; gap: 0 0.4rem; align-items: start; }
.pl-narrow .pl-tools { grid-template-columns: 1fr; }
@media (max-width: 575px) { .pl-top, .pl-cols, .pl-tools { grid-template-columns: 1fr; } }
.pl-head { padding: 0.55rem 0.5rem 0.2rem; font-family: 'IBM Plex Mono', monospace; font-size: 0.66rem; font-weight: 600; letter-spacing: 0.08em; text-transform: uppercase; opacity: 0.6; }
.pl-divider { height: 1px; margin: 0.35rem 0.25rem 0; background: rgba(15, 118, 110, 0.14); }
.nav-links .pl-menu .pl-item { display: flex; gap: 0.55rem; align-items: center; padding: 0.36rem 0.5rem; border-radius: 10px; white-space: normal; }
.pl-ico { flex: 0 0 auto; display: inline-flex; align-items: center; justify-content: center; width: 1.85rem; height: 1.85rem; border-radius: 9px; color: var(--pl-accent, var(--accent)); background: color-mix(in srgb, var(--pl-accent, #0f766e) 13%, transparent); }
.pl-text { display: flex; flex-direction: column; min-width: 0; line-height: 1.2; }
.pl-text strong { font-size: 0.87rem; font-weight: 600; }
.pl-text small { margin-top: 0.12rem; font-size: 0.72rem; opacity: 0.72; }
.pl-row { position: relative; border-radius: 10px; }
.pl-row:hover { background: rgba(15, 118, 110, 0.07); }
.nav-links .pl-menu .pl-row .pl-item:hover { background: transparent; color: inherit; }
.nav-links .pl-menu .pl-play { position: absolute; top: 50%; right: 0.45rem; width: auto; padding: 0.2rem 0.6rem; border-radius: 999px; font-size: 0.68rem; font-weight: 600; color: #fff; background: var(--pl-accent, var(--accent)); box-shadow: 0 2px 8px rgba(0, 0, 0, 0.12); transform: translateY(-50%); opacity: 0; pointer-events: none; transition: opacity 0.12s ease; }
.pl-row:hover .pl-play,
.pl-row:focus-within .pl-play { opacity: 1; pointer-events: auto; }
.nav-links .pl-menu .pl-play:hover,
.nav-links .pl-menu .pl-play:focus-visible { color: #fff; background: var(--pl-accent, var(--accent)); filter: brightness(1.1); }
.pl-row.is-current,
.nav-links .pl-menu .pl-item.is-current { background: color-mix(in srgb, var(--pl-accent, #0f766e) 11%, transparent); }
.pl-row.is-current .pl-text strong { color: var(--pl-accent); }
.menu-links-table td { min-width: 6rem; }

/* Admin → Install Guide */
.guide-steps details { border: 1px solid rgba(0, 0, 0, 0.1); border-radius: 10px; padding: 0.55rem 0.85rem; margin-bottom: 0.6rem; }
.guide-steps summary { font-weight: 600; cursor: pointer; }
.guide-steps details[open] summary { margin-bottom: 0.6rem; }
.guide-code { position: relative; margin: 0 0 0.75rem; }
.guide-code pre { margin: 0; padding: 0.8rem 1rem; padding-right: 4.5rem; background: #0f1a15; color: #d7f5e3; border-radius: 8px; font: 0.8rem/1.5 "IBM Plex Mono", ui-monospace, monospace; overflow-x: auto; white-space: pre; }
.guide-code code { color: inherit; background: none; padding: 0; }
.guide-copy { position: absolute; top: 0.45rem; right: 0.45rem; border: 1px solid #2f4a3c; background: #18291f; color: #9fe0b8; border-radius: 6px; font-size: 0.72rem; padding: 0.15rem 0.55rem; }
.guide-copy:hover { background: #22392b; }
.guide-note { background: #fff7e0; border: 1px solid #f1dfa6; border-radius: 10px; padding: 0.6rem 0.8rem; color: #5b4a17; }
.guide-check td { vertical-align: top; }

/* Class hub */
.class-hub-head {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 1rem;
  align-items: flex-start;
}
.join-code-box {
  text-align: center;
  padding: 0.6rem 1rem;
  border-radius: 14px;
  background: #f1f7f4;
  border: 1px dashed var(--accent);
}
.join-code-box small { display: block; font-size: 0.7rem; text-transform: uppercase; letter-spacing: 0.06em; color: #6c7d76; }
.join-code-box strong { font-family: var(--mono); font-size: 1.5rem; letter-spacing: 0.12em; color: var(--accent); }
.soc-stats.stats-5 { grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); }
.hub-tabs {
  display: flex;
  flex-wrap: wrap;
  gap: 0.25rem;
  border-bottom: 1px solid rgba(0, 0, 0, 0.08);
  margin-bottom: 1rem;
}
.hub-tabs a {
  padding: 0.55rem 0.95rem;
  font-weight: 600;
  font-size: 0.9rem;
  color: #55665f;
  border-bottom: 3px solid transparent;
  margin-bottom: -1px;
}
.hub-tabs a.active { color: var(--accent); border-bottom-color: var(--accent); }
.hub-tabs a .count {
  display: inline-block;
  min-width: 1.4rem;
  padding: 0 0.35rem;
  margin-left: 0.25rem;
  border-radius: 999px;
  background: #e8efeb;
  font-size: 0.72rem;
  text-align: center;
}
.hub-tabs a .count.warn { background: #ffe3b3; color: #7a4b00; }
.hub-actions {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(170px, 1fr));
  gap: 0.6rem;
}
.hub-action {
  display: flex;
  gap: 0.6rem;
  align-items: center;
  padding: 0.75rem 0.85rem;
  border-radius: 14px;
  background: #f6faf8;
  border: 1px solid rgba(0, 0, 0, 0.06);
  color: inherit;
  font-weight: 600;
  font-size: 0.88rem;
}
.hub-action small { display: block; font-weight: 400; color: #6c7d76; font-size: 0.75rem; }
.hub-action:hover { border-color: var(--accent); color: var(--accent); }
.class-card-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(min(250px, 100%), 1fr));
  gap: 0.75rem;
}
.class-card {
  display: flex;
  flex-direction: column;
  gap: 0.55rem;
  min-width: 0;
  padding: 0.75rem 0.85rem;
  border-radius: 12px;
  background: #fff;
  border: 1px solid rgba(0, 0, 0, 0.08);
  box-shadow: 0 2px 8px rgba(20, 60, 45, 0.05);
  transition: border-color 0.15s, box-shadow 0.15s;
}
.class-card:hover { border-color: var(--accent); box-shadow: 0 4px 14px rgba(15, 122, 98, 0.1); }
.class-card .class-card-main { color: inherit; display: flex; flex-direction: column; gap: 0.4rem; min-width: 0; text-decoration: none; }
.class-card-top { display: grid; grid-template-columns: auto minmax(0, 1fr) auto; gap: 0.55rem; align-items: start; }
.class-card-head { min-width: 0; }
.class-card-ico { display: grid; place-items: center; width: 2rem; height: 2rem; border-radius: 8px; background: rgba(15, 122, 98, 0.1); color: var(--accent); }
.class-card-kicker { font-family: var(--mono); font-size: 0.66rem; letter-spacing: 0.05em; text-transform: uppercase; color: var(--accent-2); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.class-card-title { margin: 0; font-size: 0.95rem; font-weight: 700; line-height: 1.25; letter-spacing: 0; overflow-wrap: anywhere; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.class-card-meta { font-size: 0.78rem; color: #5b6b65; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.class-card-side { display: flex; flex-direction: column; align-items: flex-end; gap: 0.25rem; }
.class-card-code { padding: 0 0.35rem; border: 1px dashed rgba(0, 0, 0, 0.18); border-radius: 6px; font-family: var(--mono); font-size: 0.7rem; color: var(--ink); white-space: nowrap; }
.class-card .class-card-stats { display: flex; flex-wrap: wrap; gap: 0.2rem 0.75rem; font-size: 0.76rem; color: #5b6b65; }
.class-card .class-card-stats span { white-space: nowrap; }
.class-card .class-card-stats b { color: var(--ink); }
.class-card .class-card-stats .is-warn, .class-card .class-card-stats .is-warn b { color: var(--warn); }
.class-card-actions { display: flex; flex-wrap: wrap; gap: 0.25rem; align-items: center; margin-top: auto; padding-top: 0.5rem; border-top: 1px solid rgba(0, 0, 0, 0.06); }
.class-card-actions form { margin: 0; }
.class-card-actions .btn-sm { padding: 0.22rem 0.5rem; font-size: 0.74rem; box-shadow: none; }
.class-card-actions .class-card-del { padding: 0.22rem 0.4rem; }
.class-card-actions .class-card-del .arena-icon { color: inherit; }
.class-card-actions .class-card-del:hover { border-color: var(--danger); background: rgba(220, 53, 69, 0.08); }
.class-card.is-archived { background: #f7f9f8; box-shadow: none; }
.class-card.is-archived .class-card-main { opacity: 0.75; }
.cls-tabs { margin-bottom: 0.9rem; }
.cls-notice { display: flex; flex-wrap: wrap; gap: 0.5rem 1rem; align-items: center; justify-content: space-between; padding: 0.7rem 0.95rem; border: 1px solid #f3d38a; border-radius: 12px; background: #fff8e6; color: #6b4a00; font-size: 0.9rem; }
.cls-notice.is-archived { border-color: rgba(0, 0, 0, 0.1); background: #f1f4f3; color: #46564f; }
.cls-toolbar { display: flex; flex-wrap: wrap; gap: 0.6rem 1rem; align-items: center; }
.cls-toolbar .form-select { width: auto; max-width: 100%; min-width: 12rem; }
.cls-group-head { display: flex; flex-wrap: wrap; gap: 0.5rem; align-items: center; padding-bottom: 0.45rem; margin-bottom: 0.75rem; border-bottom: 1px solid rgba(0, 0, 0, 0.08); }
.cls-group-head h2 { font-weight: 600; }
.dash-filter { display: flex; gap: 0.6rem; align-items: center; }
.dash-filter input { max-width: 18rem; }
.dash-scroll { max-height: 22rem; overflow-y: auto; padding-right: 0.25rem; }
.dash-prev summary { cursor: pointer; font-size: 0.88rem; font-weight: 600; color: #55665f; }
.leave-state { display: flex; flex-wrap: wrap; gap: 0.4rem; align-items: center; justify-content: flex-end; }
.leave-req > summary { list-style: none; cursor: pointer; }
.leave-req > summary::-webkit-details-marker { display: none; }
.leave-req[open] { flex: 1 1 100%; text-align: right; }
.leave-req-pop { text-align: left; margin-top: 0.5rem; padding: 0.75rem; border: 1px solid rgba(0, 0, 0, 0.08); border-radius: 10px; background: #f8fbf9; }
.leave-log td { font-size: 0.86rem; }
.teacher-periods { display: flex; flex-wrap: wrap; gap: 0.15rem 0.6rem; align-items: center; min-width: 15rem; }
.teacher-periods .form-check-inline, .teacher-invite .form-check-inline { margin-right: 0.4rem; }
.teacher-periods > div { flex-basis: 100%; }
.teacher-invite { display: flex; flex-wrap: wrap; gap: 0.6rem; align-items: center; }
.teacher-invite .form-select { max-width: 26rem; }
.invite-card { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: 0.6rem; padding: 0.7rem 0.9rem; border: 1px solid rgba(0, 0, 0, 0.08); border-radius: 12px; margin-bottom: 0.5rem; }
.rev-current { display: flex; flex-direction: column; align-items: flex-end; text-align: right; }
.rev-current strong { font-size: 1.6rem; line-height: 1.1; }
.rev-item { padding: 0.8rem 0; border-bottom: 1px solid rgba(0, 0, 0, 0.07); }
.rev-item:last-child { border-bottom: 0; }
.rev-item.is-current { padding-left: 0.8rem; border-left: 3px solid #1f8a5b; }
.rev-head { display: flex; flex-wrap: wrap; gap: 0.5rem; align-items: center; }
.about-version { display: flex; flex-wrap: wrap; gap: 0.6rem; align-items: center; }
.lm-types { display: grid; grid-template-columns: repeat(auto-fit, minmax(16rem, 1fr)); gap: 0.6rem; }
.lm-type { padding: 0.7rem 0.9rem; border: 1px solid rgba(0, 0, 0, 0.08); border-radius: 12px; }
.lm-type strong { display: block; margin: 0.35rem 0 0.15rem; }
.lm-type p { margin: 0; font-size: 0.88rem; color: #5b6472; }
.lm-guide { font-size: 0.9rem; }
.lm-guide summary { cursor: pointer; font-weight: 600; }
.lm-guide ol { margin: 0.5rem 0 0; padding-left: 1.2rem; }
.lm-guide li { margin-bottom: 0.25rem; }
.lm-states { display: grid; grid-template-columns: max-content 1fr; gap: 0.35rem 0.8rem; margin: 0.6rem 0 0; align-items: center; }
.lm-states dt, .lm-states dd { margin: 0; font-weight: normal; }
.lm-about { padding: 0.7rem 0.9rem; border-left: 4px solid #0f766e; border-radius: 10px; background: rgba(15, 118, 110, 0.07); font-size: 0.9rem; }
.lm-about ul { padding-left: 1.2rem; margin-top: 0.3rem; }
@media (max-width: 575px) { .lm-states { grid-template-columns: 1fr; } }
.remove-confirm { border-left: 4px solid #b42318; }
.remove-warn { padding: 0.75rem 0.9rem; border-radius: 10px; background: #fdf1ef; color: #6e1d14; font-size: 0.92rem; }
.btn-remove, .btn-remove:hover { background: #b42318; border-color: #b42318; color: #fff; }
.cls-del-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(18rem, 1fr)); gap: 0.75rem; }
.cls-del-keep { padding: 0.75rem 0.9rem; border-radius: 10px; background: #eef7f1; color: #1d4d2e; font-size: 0.92rem; }
.invite-link { max-width: 32rem; font-size: 0.88rem; }
.invite-pick { display: grid; grid-template-columns: repeat(auto-fill, minmax(16rem, 1fr)); gap: 0.35rem 0.8rem; max-height: 16rem; overflow-y: auto; padding: 0.6rem; border: 1px solid rgba(0, 0, 0, 0.08); border-radius: 10px; }
.invite-pick { overflow-x: hidden; }
.invite-pick label { display: flex; gap: 0.5rem; align-items: flex-start; cursor: pointer; min-width: 0; }
.invite-pick label > span { min-width: 0; overflow-wrap: anywhere; }
.invite-pick input { margin-top: 0.3rem; }
.class-notice { display: flex; flex-wrap: wrap; gap: 0.6rem; align-items: center; padding: 0.7rem 0.9rem; border-radius: 12px; margin-bottom: 0.5rem; border: 1px solid rgba(0, 0, 0, 0.08); }
.class-notice.is-invite { background: #eef7f1; border-color: #b9dcc6; }
.class-notice.is-removed { background: #fdf1ef; border-color: #f0c7bf; }
.gradebook th, .gradebook td { white-space: nowrap; font-size: 0.85rem; }
.gradebook td.cell-pass { color: #19734d; font-weight: 600; }
.gradebook td.cell-fail { color: #a5452c; }

.font-monospace {
  font-family: var(--mono);
  font-size: 0.82rem;
}

.arena-icon {
  display: inline-grid;
  place-items: center;
  flex-shrink: 0;
  color: var(--accent);
}
.arena-icon svg {
  width: 1em;
  height: 1em;
  display: block;
}
.icon-sm { font-size: 1rem; }
.icon-md { font-size: 1.35rem; }
.icon-lg { font-size: 1.85rem; }
.icon-xl { font-size: 2.4rem; }

.badge-chip,
.rank-chip {
  display: flex;
  align-items: center;
  gap: 0.7rem;
  padding: 0.65rem 0.85rem;
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.72);
  border: 1px solid var(--line);
  min-width: 0;
}
.badge-chip strong,
.rank-chip strong {
  display: block;
  font-size: 0.9rem;
  line-height: 1.2;
}
.badge-chip span,
.rank-chip small {
  display: block;
  font-size: 0.72rem;
  color: #5b6d66;
}
.badge-chip-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
  gap: 0.65rem;
}
.rank-inline {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
}
.icon-picker {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(72px, 1fr));
  gap: 0.45rem;
}
.icon-picker label {
  display: grid;
  place-items: center;
  gap: 0.2rem;
  padding: 0.45rem;
  border: 1px solid var(--line);
  border-radius: 12px;
  cursor: pointer;
  font-size: 0.68rem;
  text-align: center;
  background: #fff;
}
.icon-picker input { display: none; }
.icon-picker label.active,
.icon-picker label:has(input:checked) {
  border-color: var(--accent);
  box-shadow: inset 0 0 0 1px var(--accent);
  background: #f0faf6;
}

.user-avatar {
  display: inline-grid;
  place-items: center;
  border-radius: 50%;
  overflow: hidden;
  flex-shrink: 0;
  background: linear-gradient(135deg, var(--accent), var(--accent-2));
  color: #fff;
  font-weight: 700;
}
.user-avatar img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}
.avatar-sm { width: 2.2rem; height: 2.2rem; font-size: 0.72rem; }
.avatar-md { width: 3rem; height: 3rem; font-size: 0.9rem; }
.avatar-xl { width: 5.5rem; height: 5.5rem; font-size: 1.4rem; }
.user-chip-link {
  display: flex;
  align-items: center;
  gap: 0.65rem;
  min-width: 0;
}
.user-chip-link:hover strong {
  color: var(--accent);
}

.auth-card-wide {
  width: min(680px, 100%);
}

.auth-switch {
  text-align: center;
  color: #5b6d66;
  font-size: 0.9rem;
}

.auth-switch a {
  color: var(--accent);
  font-weight: 600;
}

.role-pick {
  display: grid;
  gap: 0.65rem;
}

.role-option {
  display: grid;
  gap: 0.15rem;
  padding: 0.85rem 1rem;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: #fff;
  cursor: pointer;
}

.role-option input { display: none; }

.role-option span {
  font-size: 0.82rem;
  color: #5b6d66;
}

.role-option.active {
  border-color: var(--accent);
  box-shadow: inset 0 0 0 1px var(--accent);
  background: #f0faf6;
}

.about-grid {
  display: grid;
  grid-template-columns: minmax(0, 15rem) minmax(0, 1fr);
  gap: 1.75rem;
  align-items: center;
}

.about-photo {
  position: relative;
  aspect-ratio: 4 / 5;
  border-radius: 22px;
  overflow: hidden;
  display: grid;
  place-items: center;
  background: linear-gradient(145deg, rgba(15, 122, 98, 0.92), rgba(20, 108, 138, 0.88));
  color: #fff;
  box-shadow: var(--shadow);
}
.about-photo img { width: 100%; height: 100%; object-fit: cover; display: block; }
.about-photo::after { content: ""; position: absolute; inset: 0; border-radius: inherit; box-shadow: inset 0 0 0 3px rgba(255, 255, 255, 0.35); pointer-events: none; }
.about-tags { display: flex; flex-wrap: wrap; gap: 0.4rem; }
.about-stats { display: grid; grid-template-columns: repeat(auto-fit, minmax(8rem, 1fr)); gap: 0.75rem; }
.about-stats div { padding: 0.75rem 1rem; border-radius: 14px; background: rgba(15, 122, 98, 0.07); border: 1px solid rgba(15, 122, 98, 0.15); }
.about-stats strong { display: block; font-size: 1.6rem; line-height: 1.1; color: var(--accent); }
.about-stats span { font-size: 0.82rem; color: #4a5a54; }
.about-pillars { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(220px, 100%), 1fr)); gap: 0.75rem; }
.about-pillars .panel, .about-roles .panel { margin: 0; }
.about-pillar-ico { display: inline-grid; place-items: center; width: 2.6rem; height: 2.6rem; margin-bottom: 0.6rem; border-radius: 12px; background: rgba(15, 122, 98, 0.1); }
.about-roles { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(260px, 100%), 1fr)); gap: 0.75rem; }
.about-list { margin: 0; padding-left: 1.1rem; color: #4a5a54; font-size: 0.92rem; }
.about-list li + li { margin-top: 0.3rem; }
.about-lab-group { font-family: var(--mono); font-size: 0.72rem; font-weight: 600; letter-spacing: 0.08em; text-transform: uppercase; color: #5b6b65; margin: 0 0 0.5rem; }
.about-labs { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(240px, 100%), 1fr)); gap: 0.6rem; }
.about-lab { display: flex; gap: 0.65rem; align-items: center; padding: 0.65rem 0.8rem; border-radius: 12px; border: 1px solid var(--line); border-left: 4px solid var(--lab); background: #fff; min-width: 0; }
.about-lab-ico { display: inline-grid; place-items: center; width: 2.1rem; height: 2.1rem; flex: none; border-radius: 10px; background: color-mix(in srgb, var(--lab) 14%, transparent); }
.about-lab-ico .arena-icon { color: var(--lab); }
.about-lab strong { display: block; font-size: 0.92rem; }
.about-lab small { display: block; color: #5b6b65; font-size: 0.8rem; }
.about-commit { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(230px, 100%), 1fr)); gap: 1rem; }
.about-commit strong { display: block; margin-bottom: 0.2rem; }
.about-commit span { font-size: 0.9rem; color: #4a5a54; }
.about-cta { display: flex; flex-wrap: wrap; gap: 1rem; align-items: center; justify-content: space-between; }
@media (max-width: 767.98px) {
  .about-grid { grid-template-columns: minmax(0, 1fr); }
  .about-photo { max-width: 15rem; width: 100%; margin: 0 auto; }
}

.about-initials {
  font-family: var(--mono);
  font-size: 1.8rem;
  font-weight: 600;
  letter-spacing: 0.06em;
}

.about-title {
  color: var(--accent);
  font-weight: 600;
}

.about-hero h1 {
  letter-spacing: -0.02em;
}

.arena-footer a {
  color: var(--accent);
  font-weight: 600;
}


@media (max-width: 991px) {
  .hero-panel,
  .mission-layout {
    grid-template-columns: 1fr;
  }

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

  .arena-nav > .container-xl { flex-wrap: wrap; row-gap: 0.6rem; }
  .arena-nav .brand { margin-right: auto; }
  .nav-toggle { display: inline-flex; }
  .nav-links { display: none; }
  .arena-nav.nav-open .nav-links {
    display: flex; flex-direction: column; gap: 0.15rem; order: 10; width: 100%;
    max-height: calc(100vh - 5.5rem); overflow-y: auto; padding: 0.5rem 0 0.25rem;
    border-top: 1px solid rgba(201, 213, 206, 0.9);
  }
  .arena-nav.nav-open .nav-links > a,
  .arena-nav.nav-open .nav-links .nav-dropdown > .dropdown-toggle { display: flex; align-items: center; justify-content: space-between; border-radius: 10px; padding: 0.65rem 0.85rem; font-size: 0.98rem; }
  .arena-nav.nav-open .nav-links .nav-dropdown { display: block; }
  .arena-nav.nav-open .nav-links .dropdown-menu {
    position: static !important; inset: auto !important; transform: none !important;
    width: 100%; max-width: 100%; margin: 0.15rem 0 0.4rem; box-shadow: none;
  }
  .arena-nav.nav-open .pl-row { display: flex; align-items: center; gap: 0.35rem; }
  .arena-nav.nav-open .pl-row .pl-item { flex: 1 1 auto; min-width: 0; }
  .arena-nav.nav-open .nav-links .pl-menu .pl-play { position: static; flex: 0 0 auto; transform: none; opacity: 1; pointer-events: auto; box-shadow: none; }
  .arena-nav.nav-open .nav-mobile-only { display: flex; }
  .nav-links .nav-logout { color: #b42318; }

  .level-card,
  .mission-card {
    grid-template-columns: auto 1fr;
  }

  .level-card > :last-child,
  .mission-card > :last-child {
    grid-column: 2;
  }
}

/* Search bars above lists */
.search-bar { display: flex; flex-wrap: wrap; gap: 0.5rem; align-items: center; }
.search-bar input[type=search] { flex: 1 1 260px; min-width: 0; }
.search-bar .form-select { width: auto; flex: 0 1 auto; }
.table-search { max-width: 320px; }

/* Admin dashboard analytics */
.dash-head { display: flex; flex-wrap: wrap; gap: 0.75rem; align-items: flex-end; justify-content: space-between; }
.dash-actions { display: flex; flex-wrap: wrap; gap: 0.4rem; }
.dash-kpis { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(210px, 100%), 1fr)); gap: 0.75rem; }
.dash-kpi { display: grid; grid-template-columns: auto 1fr; column-gap: 0.6rem; align-items: center; padding: 0.9rem 1rem; background: #fff; border: 1px solid var(--line); border-radius: 12px; color: var(--ink); text-decoration: none; transition: border-color 0.15s, box-shadow 0.15s; }
.dash-kpi:hover { border-color: var(--accent); box-shadow: 0 4px 14px rgba(15, 122, 98, 0.12); color: var(--ink); }
.dash-kpi-ico { grid-row: span 2; display: grid; place-items: center; width: 2.4rem; height: 2.4rem; border-radius: 10px; background: rgba(15, 122, 98, 0.1); color: var(--accent); }
.dash-kpi-label { font-size: 0.78rem; color: #5b6b65; text-transform: uppercase; letter-spacing: 0.03em; }
.dash-kpi strong { font-size: 1.6rem; line-height: 1.1; }
.dash-kpi small { grid-column: 1 / -1; margin-top: 0.35rem; font-size: 0.8rem; color: #5b6b65; }
.dash-attention { display: flex; flex-wrap: wrap; gap: 0.5rem; align-items: center; padding: 0.7rem 0.9rem; border: 1px solid #f0d3bd; background: #fdf6f0; border-radius: 12px; }
.dash-attention-title { display: inline-flex; gap: 0.35rem; align-items: center; color: var(--warn); margin-right: 0.25rem; }
.dash-flag { padding: 0.25rem 0.65rem; border-radius: 999px; font-size: 0.85rem; text-decoration: none; background: #fff; border: 1px solid var(--line); color: var(--ink); }
.dash-flag:hover { border-color: var(--accent); color: var(--ink); }
.dash-flag.tone-warn b { color: var(--warn); }
.dash-flag.tone-bad b { color: var(--danger); }
.dash-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0.75rem; }
.dash-grid > .panel { margin: 0; min-width: 0; }
.dash-wide { grid-column: 1 / -1; }
.dash-card-head { display: flex; flex-wrap: wrap; gap: 0.5rem; align-items: baseline; justify-content: space-between; margin-bottom: 0.75rem; }
.dash-legend { display: flex; flex-wrap: wrap; gap: 0.9rem; font-size: 0.82rem; color: #4a5a54; }
.dash-legend i, .dash-legend-list i { display: inline-block; width: 0.7rem; height: 0.7rem; border-radius: 3px; margin-right: 0.35rem; vertical-align: -1px; }
.dash-legend b { color: var(--ink); margin-left: 0.2rem; }
.dash-line { display: block; width: 100%; height: auto; }
.dash-grid line.dash-grid, .dash-line .dash-grid { stroke: #e3e9e5; stroke-width: 1; }
.dash-axis { font-size: 13px; fill: #6b7a74; }
.dash-hist { display: flex; align-items: flex-end; gap: 0.5rem; height: 180px; padding-top: 0.5rem; }
.dash-hist-col { flex: 1; height: 100%; display: flex; flex-direction: column; justify-content: flex-end; align-items: center; gap: 0.2rem; min-width: 0; }
.dash-hist-col span { display: block; width: 100%; max-width: 3rem; background: var(--accent); border-radius: 6px 6px 0 0; }
.dash-hist-col.is-low span { background: var(--danger); opacity: 0.8; }
.dash-hist-col b { font-size: 0.8rem; }
.dash-hist-col small { font-size: 0.72rem; color: #6b7a74; white-space: nowrap; }
.dash-bars { list-style: none; margin: 0; padding: 0; display: grid; gap: 0.6rem; }
.dash-bar-label { display: flex; justify-content: space-between; gap: 0.5rem; font-size: 0.88rem; }
.dash-bar-label span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.dash-bar-track { height: 0.5rem; background: #edf2ef; border-radius: 999px; overflow: hidden; margin-top: 0.2rem; }
.dash-bar-track span { display: block; height: 100%; background: var(--accent); border-radius: 999px; }
.dash-donut-wrap { display: flex; flex-wrap: wrap; gap: 1.25rem; align-items: center; }
.dash-donut { position: relative; width: 140px; height: 140px; border-radius: 50%; flex: none; }
.dash-donut::after { content: ''; position: absolute; inset: 26px; border-radius: 50%; background: #fff; }
.dash-donut span { position: absolute; inset: 0; display: grid; place-items: center; z-index: 1; font-weight: 700; font-size: 1.3rem; }
.dash-legend-list { list-style: none; margin: 0; padding: 0; flex: 1; min-width: 160px; display: grid; gap: 0.35rem; font-size: 0.88rem; }
.dash-legend-list li { display: flex; align-items: center; }
.dash-legend-list b { margin-left: auto; padding-left: 0.5rem; }
.dash-feed { list-style: none; margin: 0; padding: 0; }
.dash-feed li { display: flex; flex-wrap: wrap; gap: 0.5rem; justify-content: space-between; align-items: center; padding: 0.55rem 0; border-top: 1px solid #edf2ef; }
.dash-feed li:first-child { border-top: 0; }
.dash-feed-main { display: flex; flex-direction: column; min-width: 0; }
.dash-feed-main span { font-size: 0.85rem; overflow-wrap: anywhere; }
.dash-feed-meta { display: flex; gap: 0.6rem; align-items: center; }
@media (max-width: 767.98px) {
  .dash-grid { grid-template-columns: minmax(0, 1fr); }
  .dash-kpi strong { font-size: 1.35rem; }
}
@media (max-width: 575.98px) {
  .dash-kpis { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0.5rem; }
  .dash-kpi { grid-template-columns: minmax(0, 1fr); padding: 0.7rem; }
  .dash-kpi-ico { display: none; }
  .dash-kpi-label { font-size: 0.68rem; }
  .dash-kpi small { margin-top: 0.2rem; font-size: 0.72rem; }
}
/* Faculty dashboard */
.dash-kpi.is-warn { border-color: #f0d3bd; }
.dash-kpi.is-warn strong { color: var(--warn); }
.dash-kpi.is-warn .dash-kpi-ico { background: #fdf0e6; color: var(--warn); }
.fdash-empty { display: flex; gap: 1rem; align-items: flex-start; }
.fdash-link { color: inherit; text-decoration: none; flex: 1 1 12rem; }
.fdash-link:hover strong { color: var(--accent); }
.fdash-list.dash-scroll { max-height: 24rem; }
.dash-feed-meta .tag { text-decoration: none; white-space: nowrap; }
/* Branding: uploaded logo */
.brand-logo { height: 2.4rem; width: auto; max-width: 9rem; object-fit: contain; display: block; }
.auth-brand { display: inline-block; margin-bottom: 0.75rem; }
.auth-brand .brand-mark { width: 2.6rem; height: 2.6rem; display: block; }
.auth-brand .brand-logo { height: 3.2rem; max-width: 12rem; }

/* Landing page */
.landing-preview-bar { display: flex; flex-wrap: wrap; gap: 0.5rem; justify-content: space-between; align-items: center; margin-bottom: 0.75rem; padding: 0.55rem 0.9rem; border-radius: 12px; border: 1px dashed var(--accent); background: rgba(15, 122, 98, 0.06); font-size: 0.86rem; }
.landing-notice { display: flex; gap: 0.6rem; align-items: flex-start; margin-bottom: 1rem; padding: 0.75rem 1rem; border-radius: 14px; background: #fff8e6; border: 1px solid #f1d58a; color: #6b4e0a; }
.landing-notice .arena-icon { color: #b7791f; margin-top: 0.15rem; }
.landing-actions { display: flex; flex-wrap: wrap; gap: 0.6rem; }
.landing-actions .btn-lg { padding: 0.75rem 1.5rem; font-size: 1rem; }
.landing-lead { font-size: 1.1rem; line-height: 1.6; max-width: 40rem; }
.landing-logo { height: 4rem; width: auto; max-width: 14rem; margin-bottom: 1rem; }
span.landing-logo { width: 3.4rem; height: 3.4rem; display: block; border-radius: 1rem; }
.landing-logo-lg { height: 6rem; width: auto; max-width: 18rem; margin: 0 auto 1rem; }
span.landing-logo-lg { width: 5rem; height: 5rem; display: block; border-radius: 1.4rem; }
.landing-stats { margin-top: -0.25rem; }

.landing-hero { position: relative; overflow: hidden; display: grid; place-items: center; min-height: min(72vh, 620px); margin-bottom: 1.5rem; padding: 3.5rem 1.5rem; border-radius: 28px; text-align: center;
  background: radial-gradient(circle at 20% 15%, rgba(255, 255, 255, 0.18), transparent 40%), linear-gradient(135deg, var(--accent), var(--accent-2)); color: #fff; box-shadow: var(--shadow); }
.landing-hero.has-bg { background: linear-gradient(rgba(8, 18, 24, var(--landing-shade, 0.55)), rgba(8, 18, 24, var(--landing-shade, 0.55))), var(--landing-bg) center / cover no-repeat; }
.landing-hero-inner { max-width: 48rem; display: flex; flex-direction: column; align-items: center; }
.landing-hero h1 { font-size: clamp(2rem, 5vw, 3.4rem); font-weight: 700; letter-spacing: -0.02em; margin-bottom: 0.75rem; }
.landing-hero .kicker { color: rgba(255, 255, 255, 0.85); }
.landing-hero .landing-lead { color: rgba(255, 255, 255, 0.9); margin: 0 auto 1.6rem; }
.landing-hero .landing-actions { justify-content: center; }
.landing-hero .btn-arena { background: #fff; color: var(--accent); border-color: #fff; }
.landing-hero .btn-ghost { background: rgba(255, 255, 255, 0.12); color: #fff; border-color: rgba(255, 255, 255, 0.6); }

.landing-split { display: grid; grid-template-columns: minmax(0, 1.05fr) minmax(0, 1fr); gap: 2.5rem; align-items: center; min-height: min(68vh, 580px); margin-bottom: 1.5rem; }
.landing-split h1 { font-size: clamp(2rem, 4.5vw, 3.2rem); font-weight: 700; letter-spacing: -0.02em; margin-bottom: 0.75rem; }
.landing-split .landing-lead { color: #4a5a54; margin-bottom: 1.6rem; }
.landing-split-media { margin: 0; aspect-ratio: 4 / 3; border-radius: 28px; overflow: hidden; box-shadow: var(--shadow); }
.landing-split-media img { width: 100%; height: 100%; object-fit: cover; display: block; }
.landing-split-media.no-image { display: grid; place-items: center; background: radial-gradient(circle at 25% 20%, rgba(255, 255, 255, 0.2), transparent 45%), linear-gradient(135deg, var(--accent), var(--accent-2)); color: #fff; }
.landing-split-mark { display: flex; flex-direction: column; align-items: center; text-align: center; padding: 1.5rem; }
.landing-split-mark strong { font-size: 1.8rem; letter-spacing: 0.03em; }
.landing-split-mark span:not(.brand-mark) { opacity: 0.85; }

.landing-minimal { display: grid; place-items: center; min-height: min(78vh, 680px); margin-bottom: 1rem; padding: 2rem 1rem; border-radius: 28px; }
.landing-minimal.has-bg { background: linear-gradient(rgba(8, 18, 24, var(--landing-shade, 0.55)), rgba(8, 18, 24, var(--landing-shade, 0.55))), var(--landing-bg) center / cover no-repeat; box-shadow: var(--shadow); }
.landing-minimal-card { width: min(30rem, 100%); padding: 2.5rem 2rem; border-radius: 26px; text-align: center; background: rgba(255, 255, 255, 0.94); border: 1px solid var(--line); box-shadow: var(--shadow); }
.landing-minimal-card h1 { font-size: 2.2rem; font-weight: 700; margin-bottom: 0.2rem; }
.landing-tagline { color: var(--accent); font-weight: 600; margin-bottom: 0.4rem; }
.landing-minimal-card .landing-actions { justify-content: center; margin-top: 1.5rem; }

.landing-labs { display: flex; flex-wrap: wrap; gap: 0.5rem; }
.landing-lab { display: inline-flex; align-items: center; gap: 0.4rem; padding: 0.45rem 0.85rem; border-radius: 999px; border: 1px solid var(--line); background: #fff; font-size: 0.88rem; font-weight: 600; }
.landing-lab .arena-icon { color: var(--lab); }

@media (max-width: 767.98px) {
  .landing-split { grid-template-columns: minmax(0, 1fr); gap: 1.5rem; min-height: 0; }
  .landing-hero { min-height: 0; padding: 2.5rem 1.1rem; border-radius: 20px; }
  .landing-lead { font-size: 1rem; }
  .landing-actions .btn-lg { flex: 1 1 auto; text-align: center; }
}
/* Security page: summary cards, tab toolbars, pager */
.sec-cards { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(150px, 100%), 1fr)); gap: 0.5rem; }
.sec-card { display: flex; flex-direction: column; padding: 0.6rem 0.8rem; border-radius: 12px; border: 1px solid var(--line); background: rgba(255, 255, 255, 0.7); color: var(--ink); text-decoration: none; transition: border-color 0.15s; }
.sec-card:hover { border-color: var(--accent); color: var(--ink); }
.sec-card span { font-size: 0.76rem; color: #5b6b65; }
.sec-card strong { font-size: 1.35rem; line-height: 1.2; }
.sec-card small { font-size: 0.72rem; color: #7a8a84; }
.sec-card.is-zero strong { color: #9aa8a2; }
.sec-tabs { overflow-x: auto; overflow-y: hidden; flex-wrap: nowrap; scrollbar-width: thin; }
.sec-tabs a { white-space: nowrap; }
.sec-toolbar { display: flex; flex-wrap: wrap; gap: 0.75rem; align-items: center; justify-content: space-between; margin-bottom: 0.9rem; }
.sec-toolbar > p { flex: 1 1 320px; }
.sec-search { display: flex; flex-wrap: wrap; gap: 0.4rem; align-items: center; }
.sec-search input[type=search] { width: 220px; max-width: 100%; }
.sec-ban-add summary { cursor: pointer; font-weight: 600; font-size: 0.9rem; color: var(--accent); }
.admin-pager { display: flex; flex-wrap: wrap; gap: 0.5rem; align-items: center; justify-content: space-between; margin-top: 0.9rem; padding-top: 0.75rem; border-top: 1px solid #edf2ef; }
.admin-pager-info { font-size: 0.82rem; color: #5b6b65; }
.admin-pager .page-link { color: var(--accent); border-color: var(--line); }
.admin-pager .page-item.active .page-link { background: var(--accent); border-color: var(--accent); color: #fff; }
.admin-pager .page-item:first-child .page-link { border-radius: 8px 0 0 8px; }
.admin-pager .page-item:last-child .page-link { border-radius: 0 8px 8px 0; }
@media (max-width: 575.98px) {
  .sec-search input[type=search] { width: 100%; }
  .sec-search { width: 100%; }
  .sec-card small { display: none; }
  .sec-card strong { font-size: 1.15rem; }
}
/* Cheating incidents page */
.ic-filters { display: flex; flex-wrap: wrap; gap: 0.4rem; }
.ic-filters .form-select { width: auto; max-width: 220px; }
.ic-top { list-style: none; margin: 0; padding: 0; display: grid; gap: 0.55rem; }
.ic-top li { display: grid; grid-template-columns: auto 1fr; column-gap: 0.6rem; align-items: center; }
.ic-top li small { grid-column: 2; }
.ic-top li .ic-rank { grid-row: span 2; }
.ic-top a { color: var(--ink); text-decoration: none; }
.ic-top a:hover { color: var(--accent); }
.ic-rank { display: inline-grid; place-items: center; width: 1.8rem; height: 1.8rem; border-radius: 50%; background: #eceff0; color: #4b5a55; font-weight: 700; font-size: 0.82rem; }
.ic-rank.r1 { background: #fbe4e4; color: #b42318; }
.ic-rank.r2 { background: #fbe1d3; color: #a2401a; }
.ic-rank.r3 { background: #fdf0d2; color: #8a5a00; }
.ic-signals { display: flex; flex-wrap: wrap; gap: 0.25rem; max-width: 300px; }
.ic-sig { display: inline-block; padding: 0.1rem 0.45rem; border-radius: 999px; background: #f4f1ec; color: #5b4a3a; font-size: 0.74rem; text-decoration: none; white-space: nowrap; }
.ic-sig:hover { background: #f8e8dc; color: var(--warn); }
.ic-chips { display: flex; flex-wrap: wrap; gap: 0.4rem; align-items: center; flex: 1 1 260px; }
.ic-chips a.tag { text-decoration: none; }
.ic-stack { display: flex; height: 0.9rem; border-radius: 999px; overflow: hidden; background: #edf2ef; }
.ic-stack span { display: block; height: 100%; }
.ic-st-open { background: #f0a868; }
.ic-st-cleared { background: #3f9d63; }
.ic-st-warned { background: #4f86c6; }
.ic-st-confirmed { background: #c0392b; }
.dash-legend-list a { color: inherit; text-decoration: none; }
.dash-legend-list a:hover { color: var(--accent); }
.dash-bar-track span.ic-lv.risk-1 { background: #3f9d63; }
.dash-bar-track span.ic-lv.risk-2 { background: #9ab33a; }
.dash-bar-track span.ic-lv.risk-3 { background: #e0a526; }
.dash-bar-track span.ic-lv.risk-4 { background: #e2703a; }
.dash-bar-track span.ic-lv.risk-5 { background: #c0392b; }
.ic-hours { height: 150px; gap: 0.3rem; }
.ic-hours .dash-hist-col span { background: #b42318; opacity: 0.75; }
.ic-hours .dash-hist-col small { font-size: 0.66rem; }
.ic-cat { display: inline-flex; align-items: center; gap: 0.35rem; font-size: 0.8rem; white-space: nowrap; }
.ic-cat::before { content: ''; width: 0.6rem; height: 0.6rem; border-radius: 3px; background: var(--c); }
.ic-decisions { display: grid; gap: 0.4rem; }
.ic-decision { display: flex; gap: 0.6rem; align-items: flex-start; padding: 0.5rem 0.65rem; border: 1px solid var(--line); border-radius: 10px; cursor: pointer; }
.ic-decision:has(input:checked) { border-color: var(--accent); background: rgba(15, 118, 110, 0.06); }
.ic-decision input { margin-top: 0.3rem; }
.ic-decision span { display: grid; gap: 0.15rem; }
.ic-decision span .tag { justify-self: start; }
.ic-decision small { color: #5b6b65; font-size: 0.78rem; }
.ic-table td { vertical-align: top; }
.ic-table td:first-child { min-width: 160px; }
.ic-table td:nth-child(2) { min-width: 170px; }
@media (max-width: 575.98px) {
  .ic-filters { width: 100%; }
  .ic-filters .form-select { flex: 1 1 140px; max-width: none; }
  .ic-hours .dash-hist-col small { font-size: 0.58rem; }
}

/* Versus Match invitation notice, shown on every page */
.vs-toast { position: fixed; right: 1rem; bottom: 1rem; z-index: 1080; width: min(22rem, calc(100vw - 2rem)); display: flex; flex-direction: column; gap: 0.35rem; padding: 0.9rem 1rem; border: 1px solid var(--line); border-left: 4px solid var(--warn); border-radius: 14px; background: #fff; color: var(--ink); box-shadow: 0 18px 40px rgba(15, 28, 36, 0.2); animation: vs-toast-in 0.25s ease; }
.vs-toast[hidden] { display: none; }
.vs-toast-actions { display: flex; flex-wrap: wrap; gap: 0.4rem; margin-top: 0.3rem; }
.vs-toast-actions form { margin: 0; }
body.theme-dark .vs-toast { background: var(--dk-card); border-color: var(--dk-line); border-left-color: var(--warn); }
@keyframes vs-toast-in { from { transform: translateY(12px); opacity: 0; } to { transform: none; opacity: 1; } }