:root {
  color-scheme: light;
  font-family: "Segoe UI", Arial, sans-serif;
  color: #242726;
  background: #fcfcfc;
  --green: #007b35;
  --dark-green: #00652c;
}

* { box-sizing: border-box; }
body { margin: 0; min-height: 100vh; }
h1 { margin: 0; line-height: 1.12; letter-spacing: -0.035em; }

.login-page {
  display: grid;
  min-height: 100svh;
  place-items: center;
  padding: 24px;
  background:
    radial-gradient(ellipse at 10% 100%, #17824c, transparent 65%),
    #073d28;
}

.login-card {
  width: min(100%, 450px);
  padding: clamp(28px, 5vw, 48px);
  border: 1px solid #dce8e0;
  border-radius: 24px;
  background: #fcfefc;
  box-shadow: 0 24px 64px #052e2340;
}

.login-card h1 {
  color: #123827;
  font-size: clamp(2.25rem, 5vw, 3rem);
}

.login-form { display: grid; gap: 10px; margin-top: 26px; }
.login-form label { color: #314c3d; font-size: 0.95rem; }
.login-form input {
  min-height: 52px;
  border-color: #849b8d;
  border-radius: 12px;
  background: white;
}
.login-form button[type="submit"] {
  min-height: 52px;
  margin-top: 10px;
  border-radius: 12px;
}
.password-field { position: relative; }
.password-field:has(button:not([hidden])) input { padding-inline-end: 54px; }
.password-field input:focus {
  border-color: var(--dark-green);
  outline: 2px solid var(--dark-green);
  outline-offset: 1px;
}
.password-field button {
  position: absolute;
  inset-inline-end: 5px;
  top: 50%;
  transform: translateY(-50%);
  width: 44px;
  height: 44px;
  padding: 0;
  border-radius: 8px;
  background: #eaf4ed;
  color: var(--dark-green);
}
.password-field svg { display: block; margin: auto; }
.eye-slash { visibility: hidden; }
.password-field input[type="text"] + button .eye-slash { visibility: visible; }
.password-field button:hover { background: #dbeee1; }
.login-form button[type="submit"]:disabled {
  background: var(--dark-green);
  cursor: wait;
}
.caps-warning { margin: 0; color: #785012; font-size: 0.875rem; }

.login-form .error {
  padding: 10px 12px;
  border: 1px solid #f3d2cf;
  border-radius: 10px;
  background: #fff4f3;
}

@media (min-width: 760px) {
  .login-page {
    --rack-width: clamp(120px, 15vw, 210px);
    position: relative;
    grid-template-columns: 46% 1fr;
    padding: 40px;
    background:
      radial-gradient(circle at 35% 69%, transparent 0 13vw, #ffffff28 13.1vw 13.2vw, transparent 13.3vw 20vw, #ffffff24 20.1vw 20.2vw, transparent 20.3vw 27vw, #ffffff20 27.1vw 27.2vw, transparent 27.3vw) left / 46% 100% no-repeat,
      linear-gradient(150deg, #073d28, #16844b) left / 46% 100% no-repeat,
      #edf5ef;
  }
  .login-page::before,
  .login-page::after {
    position: absolute;
    box-sizing: border-box;
    content: "";
    pointer-events: none;
  }
  .login-page::before {
    left: 16.1%;
    top: 69%;
    width: var(--rack-width);
    height: 132px;
    border: 1px solid #ffffff80;
    border-radius: 12px;
    background:
      radial-gradient(circle, #ffffff55 55%, transparent 72%) left calc(24% + 22px) top 19px / 5px 5px no-repeat,
      radial-gradient(circle, #ffffff55 55%, transparent 72%) left calc(24% + 22px) top 63px / 5px 5px no-repeat,
      radial-gradient(circle, #ffffff55 55%, transparent 72%) left calc(24% + 22px) top 107px / 5px 5px no-repeat,
      linear-gradient(#ffffff55, #ffffff55) left 14px top 21px / 24% 1px no-repeat,
      linear-gradient(#ffffff55, #ffffff55) left 14px top 65px / 24% 1px no-repeat,
      linear-gradient(#ffffff55, #ffffff55) left 14px top 109px / 24% 1px no-repeat,
      linear-gradient(#ffffff55, #ffffff55) center top 43px / 100% 1px no-repeat,
      linear-gradient(#ffffff55, #ffffff55) center top 87px / 100% 1px no-repeat,
      #35635a;
    transform: translate(-50%, -50%);
  }
  .login-page::after {
    left: calc(16.1% + var(--rack-width) / 2 - 19px);
    top: calc(69% - 44px);
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: var(--rack-green, #85ffad);
    box-shadow: 0 44px var(--rack-red, #ff8175), 0 88px var(--rack-yellow, #ffe477);
    transform: translate(-50%, -50%);
  }
  .login-card {
    grid-column: 2;
    box-shadow: 0 24px 64px #123c251a;
  }
}

@property --rack-green {
  syntax: "<color>";
  inherits: false;
  initial-value: #85ffad;
}
@property --rack-red {
  syntax: "<color>";
  inherits: false;
  initial-value: #ff8175;
}
@property --rack-yellow {
  syntax: "<color>";
  inherits: false;
  initial-value: #ffe477;
}

@media (min-width: 760px) and (prefers-reduced-motion: no-preference) {
  .login-page::after {
    box-shadow:
      0 0 4px var(--rack-green),
      0 44px var(--rack-red), 0 44px 4px var(--rack-red),
      0 88px var(--rack-yellow), 0 88px 4px var(--rack-yellow);
    animation:
      rack-green 2.4s ease-in-out infinite,
      rack-red 3.1s ease-in-out -0.7s infinite,
      rack-yellow 3.7s ease-in-out -1.8s infinite;
  }

  @keyframes rack-green {
    0%, 35%, 100% { --rack-green: #3d8057; }
    8%, 15% { --rack-green: #85ffad; }
  }
  @keyframes rack-red {
    0%, 42%, 100% { --rack-red: #934740; }
    10%, 18% { --rack-red: #ff8175; }
  }
  @keyframes rack-yellow {
    0%, 32%, 100% { --rack-yellow: #8c7736; }
    7%, 12% { --rack-yellow: #ffe477; }
  }
}

label { font-weight: 600; }
input, button { font: inherit; }

input {
  width: 100%;
  padding: 12px 14px;
  border: 1px solid #778c7e;
  border-radius: 8px;
  color: inherit;
}

button {
  padding: 12px 20px;
  border: 1px solid transparent;
  border-radius: 8px;
  background: var(--green);
  color: white;
  font-weight: 600;
  cursor: pointer;
}
button:hover { background: var(--dark-green); }
input:focus-visible, button:focus-visible {
  outline: 3px solid var(--dark-green);
  outline-offset: 3px;
}
.error { margin: 0; color: #a02424; }

.admin-header {
  grid-area: header;
  position: sticky;
  top: 0;
  z-index: 2;
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  gap: 16px;
  padding: 12px 20px;
  background: linear-gradient(90deg, var(--dark-green), var(--green));
  color: white;
  border-bottom: 1px solid #005528;
}

.admin-header form {
  grid-column: 2;
  grid-row: 1;
  align-self: start;
  justify-self: end;
}
.admin-header button { background: #003b2070; border-color: #ffffff80; }
.admin-header button:hover { background: #003b20a0; }
.admin-header button:focus-visible { outline-color: white; }

.password-setup-logout { margin-top: 16px; }
.password-setup-logout button {
  background: #eaf4ed;
  color: var(--dark-green);
}
.password-setup-logout button:hover { background: #dbeee1; }

.admin-page {
  display: grid;
  grid-template-columns: 254px minmax(0, 1fr);
  grid-template-rows: auto 1fr;
  grid-template-areas: "sidebar header" "sidebar content";
  min-height: 100svh;
}
.admin-sidebar {
  grid-area: sidebar;
  position: sticky;
  top: 0;
  align-self: start;
  height: 100svh;
  overflow-y: auto;
  display: flex;
  flex-direction: column;
  gap: 26px;
  padding: 22px 14px 18px;
  background: linear-gradient(180deg, var(--dark-green) 0 14%, #063e2d 55%, #032f23 100%);
  color: #f4fcf6;
}
.sidebar-brand {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 0 8px;
  color: inherit;
  text-decoration: none;
}
.sidebar-brand svg { flex: none; color: #4bdc87; }
.sidebar-brand strong { display: block; font-size: 1.65rem; line-height: 1.05; }
.sidebar-brand small { color: #c4e7d2; font-size: .72rem; }
.sidebar-footer {
  display: grid;
  gap: 10px;
  margin-top: auto;
  padding: 16px 9px 0;
  border-top: 1px solid #ffffff25;
  color: #b9dfca;
}
.sidebar-footer small { justify-self: end; color: #cae9d6; }
.admin-menu a {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 11px 12px;
  border: 1px solid transparent;
  border-radius: 10px;
  color: inherit;
  font-weight: 600;
  text-decoration: none;
}
.admin-menu a svg { flex: none; }
.admin-menu a:hover { background: #ffffff1a; }
.admin-menu a + a { margin-top: 6px; }
.admin-menu a[aria-current="page"] {
  background: #0b7849;
  border-color: #42ba79;
  color: white;
}
.admin-menu a:focus-visible,
.sidebar-brand:focus-visible {
  outline: 2px solid #a3f5c2;
  outline-offset: 2px;
}
html[data-theme] {
  color: var(--text);
  background: var(--page);
  --page: light-dark(#fcfcfc, #1b1e20);
  --text: light-dark(#242726, #edf1ef);
  --surface: light-dark(#fff, #282d30);
  --surface-soft: light-dark(#f7faf8, #303638);
  --surface-hover: light-dark(#e2f1e7, #394341);
  --workspace-start: light-dark(#e9f6ed, #252d2c);
  --workspace-end: light-dark(#fcfefc, #232729);
  --border: light-dark(#d2e9da, #4d5958);
  --field-border: light-dark(#778c7e, #82938c);
  --accent: light-dark(#075432, #9de2b7);
  --muted: light-dark(#4b6257, #b9c8c1);
  --focus: light-dark(#087443, #83d9a8);
  --danger: light-dark(#a02424, #ffb6b0);
}
html[data-theme="dark"] { color-scheme: dark; }
html[data-theme="system"] { color-scheme: light dark; }

.workspace a:not(.zoom-button, .bot-card) { color: var(--accent); }
.workspace .error { color: var(--danger); }
.workspace :is(input, select, textarea) {
  color: var(--text);
  background: var(--surface);
  border-color: var(--field-border);
}
.workspace :is(input, select, textarea)::placeholder { color: var(--muted); }
.workspace :is(a, button, input, select, textarea, summary):focus-visible {
  outline: 3px solid var(--focus);
  outline-offset: 3px;
}
.appearance-form { display: grid; justify-items: start; gap: 8px; margin-top: 24px; }
.appearance-form select { font: inherit; border-radius: 8px; padding: 8px 12px; }
.user-bot-access { display: grid; gap: 8px; padding: 8px 12px 12px; }
.user-bot-access ul { display: grid; gap: 4px; list-style: none; margin: 0; padding: 0; }
.user-bot-access label { display: flex; align-items: center; gap: 10px; min-height: 28px; cursor: pointer; }
.user-bot-access input[type="checkbox"] { width: 20px; height: 20px; margin: 0; padding: 0; accent-color: var(--accent); }
.department-filter { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; margin: 0 0 12px; }
.user-create-form { margin: 0 0 16px; }
.user-create-row { display: flex; flex-wrap: wrap; align-items: end; gap: 10px 14px; }
.user-create-row > label { display: grid; gap: 4px; flex: 0 1 12rem; min-width: 0; }
.user-create-row > label:first-child { flex-basis: 15rem; }
.user-create-row input, .user-create-row select { box-sizing: border-box; min-height: 42px; }
.user-create-form .user-bot-access { margin: 12px 0 0; padding: 4px 0 0; border: 0; }
.user-create-form .user-bot-access legend { padding: 0; }
.user-create-row > button { min-height: 42px; }
.workspace .department-filter a { border: 1px solid var(--border); border-radius: 8px; background: var(--surface); padding: 5px 11px; text-decoration: none; overflow-wrap: anywhere; }
.workspace .department-filter a:hover { background: var(--surface-hover); }
.workspace .department-filter a[aria-current="page"] { color: white; background: var(--green); border-color: var(--green); }
.user-list-row { border-bottom: 1px solid var(--border); }
.user-list-row > summary { cursor: pointer; padding: 5px 0; overflow-wrap: anywhere; }

.workspace {
  grid-area: content;
  align-self: start;
  min-width: 0;
  min-height: 240px;
  margin: clamp(16px, 4vw, 48px);
  padding: clamp(20px, 5vw, 48px);
  border: 1px solid var(--border);
  border-top: 4px solid var(--green);
  border-radius: 18px;
  background: linear-gradient(140deg, var(--workspace-start), var(--workspace-end) 65%);
}
.workspace h1 {
  max-width: 24ch;
  color: var(--accent);
  font-size: clamp(1.7rem, 4vw, 2.75rem);
}
.account-details dd { margin: 4px 0 0; font-weight: 600; }

.bot-catalog {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 15rem), 1fr));
  gap: clamp(12px, 2vw, 24px);
  max-width: 64rem;
  margin: 28px 0 0;
  padding: 0;
  list-style: none;
}
.bot-card {
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: flex-start;
  gap: 8px;
  height: 100%;
  min-height: 9rem;
  padding: clamp(18px, 3vw, 30px);
  border: 1px solid var(--border);
  border-radius: 12px;
  background: var(--surface);
  color: var(--accent);
  text-decoration: none;
  overflow-wrap: anywhere;
}
.bot-card strong { font-size: 1.3rem; }
.bot-card span { color: var(--muted); }
.bot-card-link:hover { border-color: var(--focus); background: var(--surface-soft); }
.bot-card-link:focus-visible { outline: 3px solid var(--focus); outline-offset: 3px; }
.bot-card-planned { background: var(--surface-soft); }

.posthub-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  align-items: start;
  gap: clamp(16px, 3vw, 32px);
  max-width: 64rem;
  margin: 20px 0;
}
.posthub-compose, .posthub-preview {
  min-width: 0;
  border: 1px solid var(--border);
  border-radius: 12px;
  background: var(--surface);
  padding: clamp(14px, 2vw, 24px);
}
.posthub-compose { display: grid; justify-items: start; gap: 16px; }
.posthub-compose > label { width: 100%; }
.posthub-compose label:not(.posthub-time-options label) { display: grid; gap: 6px; }
.posthub-compose :is(input:not([type="radio"]), select, textarea) {
  min-width: 0;
  max-width: 100%;
  padding: 7px 9px;
  border: 1px solid var(--border);
  border-radius: 8px;
  font: inherit;
}
.posthub-compose textarea { resize: vertical; }
.posthub-compose input[type="file"]::file-selector-button {
  margin-inline-end: 8px;
  padding: 5px 9px;
  border: 1px solid var(--border);
  border-radius: 6px;
  background: var(--surface-soft);
  color: var(--accent);
  cursor: pointer;
}
.posthub-schedule { display: flex; align-items: start; flex-wrap: wrap; gap: 14px; }
.posthub-schedule fieldset { min-width: 0; padding: 0; margin: 0; border: 0; }
.posthub-schedule legend { padding: 0; }
.posthub-time-options, .posthub-time-inputs { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 6px; }
.posthub-preview h2 { margin: 0 0 14px; font-size: 1.2rem; }
.posthub-message {
  max-width: 27rem;
  overflow: hidden;
  border: 1px solid var(--border);
  border-radius: 12px;
  background: var(--surface-soft);
}
.posthub-message canvas:not([hidden]) { display: block; width: 100%; height: auto; }
.posthub-message p { margin: 0; padding: 12px 14px; white-space: pre-wrap; overflow-wrap: anywhere; }
#posthub-preview-empty { color: var(--muted); }
@media (max-width: 52rem) {
  .posthub-layout { grid-template-columns: minmax(0, 1fr); }
}

.zoom-layout {
  display: grid;
  grid-template-columns: minmax(0, 1.5fr) minmax(0, 1fr);
  gap: 16px;
  align-items: stretch;
}
.zoom-panel {
  min-width: 0;
  padding: clamp(12px, 2vw, 22px);
  border: 1px solid var(--border);
  border-radius: 10px;
  background: var(--surface);
}
.zoom-schedule { border-top: 3px solid var(--focus); }
.zoom-panel h2 { margin: 0 0 12px; font-size: 1.1rem; }
.zoom-period, .zoom-schedule-header {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
}
.zoom-schedule-header { justify-content: space-between; margin-top: 12px; }
.zoom-schedule-header a { color: var(--accent); }
.zoom-button {
  display: inline-block;
  padding: 8px 11px;
  border: 1px solid var(--border);
  border-radius: 7px;
  background: var(--surface);
  color: var(--accent);
  font-weight: 600;
  text-decoration: none;
  overflow-wrap: anywhere;
}
.zoom-button:hover { border-color: var(--focus); }
nav.zoom-period { flex-wrap: nowrap; overflow-x: auto; }
nav.zoom-period .zoom-button { flex: 1 0 auto; text-align: center; white-space: nowrap; }
.zoom-button[aria-current="page"], .zoom-primary { color: white; background: #08663a; border-color: #08663a; }
.zoom-meetings { list-style: none; padding: 0; margin: 8px 0; }
.zoom-meetings li { display: flex; flex-wrap: wrap; gap: 3px 12px; padding: 8px 0; border-top: 1px solid var(--border); }
.zoom-meetings small { display: block; }
.zoom-meeting-actions { display: flex; flex-wrap: wrap; gap: 6px; margin-inline-start: auto; }
.zoom-meeting-actions .zoom-button { padding: 4px 8px; font-size: .9rem; }
.zoom-remove { color: var(--danger); }
.zoom-remove:hover { border-color: var(--danger); }
.zoom-meeting-time { color: var(--accent); font-variant-numeric: tabular-nums; }
.zoom-day { padding-top: 8px; margin-top: 10px; border-top: 1px solid var(--border); }
.zoom-day h2, .zoom-day p { margin: 0; }
.zoom-muted, .zoom-meetings small { color: var(--muted); font-size: .9rem; }
.zoom-booking, .zoom-booking label { display: grid; gap: 8px; }
.zoom-booking { min-width: 0; margin: 0; padding: 0; border: 0; }
.zoom-booking button { justify-self: start; }
#zoom-trainers { margin-top: 14px; }
#zoom-trainers summary {
  max-width: max-content;
  min-height: 44px;
  padding: 10px 14px;
  border: 1px solid var(--border);
  border-radius: 7px;
  background: var(--surface-soft);
  color: var(--accent);
  font-weight: 600;
  cursor: pointer;
}
#zoom-trainers summary:hover, #zoom-trainers[open] summary {
  border-color: var(--focus);
  background: var(--surface-hover);
}
#zoom-trainers summary:focus-visible { outline: 2px solid var(--focus); outline-offset: 2px; }
#zoom-trainers form { margin-top: 8px; }
.zoom-booking input, .zoom-booking select, .zoom-booking textarea {
  min-width: 0;
  width: 100%;
  padding: 7px;
  border: 1px solid var(--field-border);
  border-radius: 6px;
  font: inherit;
}
.zoom-export-panel { max-width: 48rem; }
.zoom-export-panel textarea { resize: vertical; }
.zoom-times { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; }
.zoom-exports { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 16px; }
.zoom-availability { margin-top: 16px; scroll-margin-top: 5rem; }
.zoom-date-form { display: flex; align-items: end; flex-wrap: wrap; gap: 10px; }
.zoom-date-form label { display: grid; gap: 4px; }
.zoom-year { display: flex; flex-wrap: wrap; align-items: end; gap: 8px; flex-basis: 100%; }
.zoom-year input { max-width: 7rem; }
.zoom-date-form input {
  width: min(100%, 14rem);
  border: 1px solid var(--field-border);
  border-radius: 6px;
  padding: 8px;
  font: inherit;
}
@media (max-width: 50rem) {
  .zoom-layout { grid-template-columns: 1fr; }
}

.users-table {
  width: 100%;
  margin-top: 20px;
  border-spacing: 0;
  border: 1px solid var(--border);
  border-radius: 10px;
  background: var(--surface);
}
.users-table th,
.users-table td { padding: 11px clamp(8px, 2vw, 16px); text-align: left; }
.group-table th,
.group-table td { overflow-wrap: anywhere; }
.group-scroll {
  margin-top: 16px;
  border: 1px solid var(--border);
  border-radius: 10px;
}
.group-scroll[data-group-scroll] {
  max-height: 23rem;
  overflow: auto;
  scrollbar-gutter: stable;
  background: var(--surface);
}
.group-scroll:focus-visible { outline: 3px solid var(--focus); }
.group-scroll .group-table { margin: 0; border: 0; border-radius: 0; }
.group-scroll thead th { position: sticky; top: 0; background: var(--surface-soft); }
.antispam-summary {
  margin-top: 28px;
  padding-top: 4px;
  border-top: 1px solid var(--border);
}
.antispam-summary dl { display: grid; gap: 6px; }
.antispam-summary dt,
.antispam-summary dd { display: inline; margin: 0; }
.antispam-summary dt::after { content: " - "; white-space: pre; }
.group-id { display: block; margin-top: 4px; color: var(--muted); font-weight: 400; }
.antispam-text-form {
  display: grid;
  gap: 12px;
  width: max-content;
  max-width: min(100%, 56rem);
  margin-block: 24px;
}
.antispam-text-form textarea,
.antispam-text-form select {
  font: inherit;
  padding: 10px;
  border: 1px solid var(--field-border);
  border-radius: 8px;
  background: var(--surface);
}
.antispam-text-form textarea { width: 100%; resize: vertical; }
.antispam-tool-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 10px; }
.antispam-text-form p { margin: 0; }
.antispam-workbench {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 20px;
  align-items: stretch;
  margin-block: 26px;
}
@media (min-width: 68rem) {
  .antispam-workbench { grid-template-columns: minmax(0, 1.5fr) minmax(0, 1fr); }
}
.antispam-card {
  min-width: 0;
  padding: 14px 16px;
  border: 1px solid var(--border);
  border-radius: 10px;
  background: var(--surface);
  overflow-wrap: anywhere;
}
.antispam-card > h2,
.antispam-statistics-header > h2 {
  margin: 0;
  color: var(--accent);
  font-size: 1.15rem;
}
.antispam-card summary {
  color: var(--accent);
  font-weight: 600;
  cursor: pointer;
}
.antispam-notifications {
  margin-top: 16px;
  padding-top: 12px;
  border-top: 1px solid var(--border);
}
.antispam-notifications > summary { font-size: 1.15rem; }
.antispam-text-panel .antispam-text-form {
  width: 100%;
  max-width: none;
  margin: 12px 0 0;
}
.antispam-text-panel textarea { min-width: 0; }
.antispam-audit-date { color: var(--muted); }
.antispam-attention-list { list-style: none; margin: 10px 0 0; padding: 0; }
.antispam-attention-list li { padding-block: 8px; border-top: 1px solid var(--border); }
.antispam-attention-list p { margin: 4px 0 0; }
.antispam-attention-meta { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 2px 12px; }
.antispam-attention-meta span { color: var(--muted); }
.antispam-statistics-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px 16px;
}
.antispam-statistics select {
  font: inherit;
  padding: 6px;
  border: 1px solid var(--field-border);
  border-radius: 7px;
  background: var(--surface);
}
.antispam-statistics p { margin: 8px 0 0; color: var(--muted); }
.antispam-statistics dl {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
  margin: 12px 0;
  padding-block: 12px;
  border-block: 1px solid var(--border);
}
.antispam-statistics dd { margin: 3px 0 0; font-size: 1.35rem; font-weight: 600; font-variant-numeric: tabular-nums; }
@media (max-width: 40rem) {
  .antispam-statistics dl { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
.notification-card {
  margin-block: 12px;
  padding: 12px 16px;
  border: 1px solid var(--border);
  border-radius: 10px;
  background: var(--surface);
  overflow-wrap: anywhere;
}
.notification-card h3,
.notification-card p { margin: 0 0 6px; }
.users-table thead th {
  border-bottom: 1px solid var(--border);
  color: var(--accent);
}

.health-monitor {
  --health-green: #9cf1b6;
  --health-red: #ffb6aa;
  --health-line: #c5e0ce;
  min-width: 0;
  color: white;
}
.health-summary { margin: 0 0 5px; color: #e1f5e8; text-align: center; font-size: 12px; }
.health-strip-scroll {
  overflow-x: auto;
  scrollbar-width: thin;
  scrollbar-color: #b8e4c7 transparent;
}
.health-strip-scroll:focus-visible { outline: 1px solid white; outline-offset: -1px; }
.health-strip { display: flex; align-items: center; gap: 7px; width: max-content; margin-inline: auto; padding: 2px; }
.health-item {
  display: grid;
  grid-template-columns: auto auto;
  column-gap: 6px;
  align-items: center;
  padding: 5px 8px;
  border: 1px solid #ffffff63;
  border-radius: 8px;
  background: #ffffff12;
  white-space: nowrap;
}
.health-dot { width: 9px; height: 9px; border-radius: 50%; background: var(--health-line); }
.health-label { font-size: 13px; font-weight: 700; }
.health-state { grid-column: 2; color: #e1f5e8; font-size: 11px; }
.health-line { width: 16px; height: 1px; background: var(--health-line); }
.health-item[data-status="healthy"] .health-dot,
.health-item[data-status="healthy"] + .health-line { background: var(--health-green); }
.health-item[data-status="unhealthy"] .health-dot,
.health-item[data-status="unhealthy"] + .health-line { background: var(--health-red); }
.health-item[data-status="healthy"] .health-dot { animation: health-pulse 3s ease-in-out infinite; }
@keyframes health-pulse {
  50% { opacity: .7; box-shadow: 0 0 0 4px color-mix(in srgb, var(--health-green) 18%, transparent); }
}
@media (prefers-reduced-motion: reduce) {
  .health-item[data-status="healthy"] .health-dot { animation: none; }
}

@media (max-width: 1200px) {
  .admin-header { gap: 8px 12px; }
  .admin-header .health-monitor { grid-area: 2 / 1 / 3 / -1; }
}

@media (max-width: 620px) {
  .admin-page {
    grid-template-columns: minmax(0, 1fr);
    grid-template-rows: auto auto 1fr;
    grid-template-areas: "header" "sidebar" "content";
  }
  .admin-sidebar { position: static; height: auto; gap: 14px; padding: 14px; }
  .admin-menu { display: flex; flex-wrap: wrap; gap: 4px; }
  .admin-menu a { padding: 7px; gap: 4px; font-size: .85rem; }
  .admin-menu a + a { margin: 0; }
  .admin-menu a svg { width: 16px; height: 16px; }
  .sidebar-footer { grid-template-columns: 1fr auto; margin: 0; padding: 8px; }
}

.notification-meta,
.notification-original,
.notification-preview {
  overflow-wrap: anywhere;
}
.notification-preview {
  margin: 8px 0;
  padding: 4px 10px;
  border-inline-start: 2px solid currentColor;
}

.notification-heading {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  justify-content: space-between;
  gap: 8px 16px;
  margin-bottom: 10px;
}
.notification-heading a { margin-inline-start: auto; }
.notification-label {
  display: inline-block;
  padding: 3px 8px;
  border-radius: 6px;
  color: #382900;
  background: #ffdf97;
}
.notification-outcome { font-weight: 700; }
.notification-card details { margin-top: 8px; }
.notification-card summary { cursor: pointer; }

.group-connection { margin: 0 0 12px; }
.group-connection summary { cursor: pointer; font-weight: 700; }
.group-connection-form {
  display: flex;
  align-items: end;
  flex-wrap: wrap;
  gap: 12px;
  margin: 10px 0 14px;
}
.group-connection-form p { flex-basis: 100%; margin: 0; }
.group-connection-form label { display: grid; gap: 4px; }
