:root {
  color-scheme: light;
  --bg: #eef3f8;
  --bg-top: #f8fafc;
  --bg-bottom: #e2ebf3;
  --panel: rgba(255, 255, 255, 0.74);
  --panel-strong: rgba(255, 255, 255, 0.92);
  --panel-soft: rgba(248, 251, 254, 0.82);
  --panel-muted: rgba(241, 246, 250, 0.86);
  --panel-dark: #0f1822;
  --panel-dark-soft: #152232;
  --line: rgba(204, 216, 229, 0.92);
  --line-strong: rgba(181, 197, 213, 0.96);
  --text: #16222e;
  --text-soft: #617181;
  --text-faint: #8c9aaa;
  --accent: #2768e3;
  --accent-strong: #194ca2;
  --accent-soft: rgba(39, 104, 227, 0.12);
  --success: #1f8a5a;
  --success-soft: rgba(31, 138, 90, 0.12);
  --warning: #bf7a12;
  --warning-soft: rgba(191, 122, 18, 0.13);
  --danger: #c14249;
  --danger-soft: rgba(193, 66, 73, 0.13);
  --nav-text: rgba(245, 248, 252, 0.96);
  --nav-muted: rgba(200, 214, 229, 0.72);
  --focus-ring: 0 0 0 4px rgba(39, 104, 227, 0.15);
  --radius-xs: 8px;
  --radius-sm: 10px;
  --radius-md: 12px;
  --radius-lg: 16px;
  --shadow-soft: 0 18px 48px rgba(17, 27, 39, 0.08);
  --shadow-panel: 0 12px 28px rgba(17, 27, 39, 0.07);
  --shadow-strong: 0 26px 60px rgba(12, 20, 31, 0.18);
  --spring: cubic-bezier(0.2, 0.8, 0.2, 1);
  --font-title: 1rem;
  --font-copy: 0.82rem;
  font-family: "Segoe UI", "Helvetica Neue", Arial, sans-serif;
}

* {
  box-sizing: border-box;
}

html,
body {
  min-height: 100%;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  color: var(--text);
  background:
    linear-gradient(135deg, rgba(39, 104, 227, 0.06), transparent 34%),
    linear-gradient(180deg, var(--bg-top) 0%, var(--bg) 58%, var(--bg-bottom) 100%);
}

body.drawer-open,
body.sidebar-open {
  overflow: hidden;
}

body.sidebar-collapsed .sidebar {
  width: 6rem;
  padding-inline: 12px;
}

body.sidebar-collapsed .sidebar .brand-copy,
body.sidebar-collapsed .sidebar .page-copy,
body.sidebar-collapsed .sidebar .sidebar-locale span,
body.sidebar-collapsed .sidebar .secondary-button {
  display: none;
}

body.sidebar-collapsed .sidebar .page-button {
  justify-items: center;
}

body.sidebar-collapsed .sidebar .sidebar-brand {
  grid-template-columns: 1fr;
  justify-items: center;
  gap: 10px;
  padding: 12px;
}

body.sidebar-collapsed .sidebar .sidebar-brand .sidebar-collapse-button {
  justify-self: center;
}

body.sidebar-collapsed .sidebar .page-button {
  grid-template-columns: 1fr;
}

button,
input,
textarea,
select {
  font: inherit;
  transition:
    border-color 180ms var(--spring),
    background-color 180ms var(--spring),
    box-shadow 180ms var(--spring),
    transform 180ms var(--spring),
    opacity 180ms var(--spring);
}

button {
  cursor: pointer;
}

button:disabled,
input:disabled,
textarea:disabled,
select:disabled {
  cursor: not-allowed;
  opacity: 0.62;
}

:focus-visible {
  outline: none;
  box-shadow: var(--focus-ring);
}

.hidden {
  display: none !important;
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.skip-link {
  position: fixed;
  top: 12px;
  left: 12px;
  z-index: 100;
  padding: 10px 14px;
  border-radius: var(--radius-sm);
  color: #fff;
  background: var(--accent-strong);
  transform: translateY(-180%);
}

.skip-link:focus-visible {
  transform: translateY(0);
}

.shell {
  min-height: 100vh;
}

.console-shell {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
}

.login-shell {
  display: grid;
  place-items: center;
  padding: 24px 16px;
}

.sidebar-backdrop,
.drawer-backdrop {
  position: fixed;
  inset: 0;
  background: rgba(15, 24, 34, 0.42);
  backdrop-filter: blur(10px);
}

.sidebar-backdrop {
  z-index: 24;
}

.drawer-backdrop {
  z-index: 40;
  display: flex;
  justify-content: flex-end;
}

.sidebar,
.workspace,
.sidebar-stack,
.sidebar-footer,
.sidebar-group,
.page-list,
.fields,
.overview-stack,
.context-list,
.dashboard-grid,
.management-list-stack,
.audit-log,
.drawer-content,
.field-grid,
.trace-columns,
.summary-grid,
.record-grid,
.traffic-layout,
.mini-stat-list,
.status-tile-grid,
.ranked-list,
.traffic-chart,
.traffic-table {
  display: grid;
}

.sidebar {
  position: sticky;
  top: 0;
  z-index: 30;
  width: 20rem;
  height: 100vh;
  height: 100dvh;
  max-height: 100dvh;
  grid-template-rows: minmax(0, 1fr) auto;
  gap: 16px;
  padding: 16px;
  overflow: hidden;
  color: var(--nav-text);
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.05), transparent 26%),
    linear-gradient(180deg, var(--panel-dark) 0%, var(--panel-dark-soft) 100%);
  box-shadow:
    inset -1px 0 0 rgba(255, 255, 255, 0.08),
    20px 0 40px rgba(12, 20, 31, 0.12);
  transition:
    width 220ms var(--spring),
    padding 220ms var(--spring);
}

.sidebar-stack {
  min-height: 0;
  gap: 18px;
  align-content: start;
  overflow-y: auto;
  padding-right: 4px;
  scrollbar-gutter: stable;
  overscroll-behavior: contain;
}

.sidebar-brand {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  gap: 14px;
  align-items: start;
  padding: 16px;
  border-radius: var(--radius-lg);
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.08), rgba(255, 255, 255, 0.03));
  border: 1px solid rgba(255, 255, 255, 0.08);
}

.sidebar-brand .sidebar-collapse-button {
  align-self: start;
  justify-self: end;
}

.brand-mark,
.operator-avatar {
  width: 46px;
  height: 46px;
  display: grid;
  place-items: center;
  border-radius: var(--radius-sm);
  color: #fff;
  font-size: 0.82rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  background: linear-gradient(135deg, var(--accent) 0%, #5da0ff 100%);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.32);
}

.sidebar-group {
  gap: 10px;
}

.sidebar-stack h1,
.login-card h1,
.section-head h3,
.drawer-header h3,
.context-card h3,
.hero-card h2,
.page-header h2,
.record-title,
.trace-section h4 {
  margin: 0;
  font-size: var(--font-title);
  font-weight: 700;
  line-height: 1.35;
  letter-spacing: 0;
}

.eyebrow,
.kicker,
.section-kicker,
.hero-action-label,
.sidebar-status-label {
  margin: 0;
  text-transform: none;
  letter-spacing: 0;
  font-size: var(--font-copy);
  font-weight: 400;
}

.eyebrow,
.kicker,
.sidebar-status-label {
  color: rgba(209, 221, 234, 0.58);
}

.section-kicker,
.hero-action-label {
  color: var(--text-faint);
}

.sidebar-copy,
.hero-copy,
.hero-action-copy,
.context-list dt,
.context-list dd,
.section-head p,
.record-copy,
.record-meta,
.history-summary,
.audit-entry span,
.audit-entry p,
.summary-card p,
.trace-item p,
.drawer-header p,
.feedback,
.search-shell input::placeholder,
.traffic-row small {
  color: var(--text-soft);
  font-size: var(--font-copy);
  font-weight: 400;
}

.page-list,
.sidebar-footer,
.context-list,
.mini-stat-list,
.status-tile-grid,
.ranked-list,
.management-list-stack,
.audit-log,
.drawer-content {
  gap: 12px;
}

.page-button,
.primary-button,
.secondary-button,
.icon-button,
.list-action {
  border: 1px solid transparent;
  border-radius: var(--radius-sm);
}

.page-button {
  width: 100%;
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  gap: 12px;
  align-items: center;
  padding: 14px;
  color: var(--nav-text);
  text-align: left;
  background: transparent;
}

.page-button:hover,
.page-button[aria-current="true"] {
  transform: translateY(-1px);
  background: rgba(255, 255, 255, 0.08);
}

.page-button[aria-current="true"] {
  border-color: rgba(255, 255, 255, 0.14);
}

.page-icon {
  position: relative;
  width: 38px;
  height: 38px;
  display: grid;
  place-items: center;
  border-radius: var(--radius-xs);
  background: rgba(255, 255, 255, 0.08);
  color: var(--nav-text);
  overflow: hidden;
}

.page-icon::before,
.page-icon::after,
.menu-icon::before,
.menu-icon::after,
.close-icon::before,
.close-icon::after,
.search-icon::after {
  content: "";
  position: absolute;
}

.page-icon-overview::before {
  inset: 10px;
  background:
    linear-gradient(currentColor 0 0) 0 0 / 7px 7px,
    linear-gradient(currentColor 0 0) 100% 0 / 7px 7px,
    linear-gradient(currentColor 0 0) 0 100% / 7px 7px,
    linear-gradient(currentColor 0 0) 100% 100% / 7px 7px;
  background-repeat: no-repeat;
  opacity: 0.9;
}

.page-icon-quarantine::before {
  width: 15px;
  height: 18px;
  border: 2px solid currentColor;
  border-top-width: 4px;
  transform: translateY(1px);
}

.page-icon-history::before {
  width: 18px;
  height: 18px;
  border: 2px solid currentColor;
  border-radius: 50%;
}

.page-icon-history::after {
  width: 8px;
  height: 2px;
  background: currentColor;
  transform: translate(3px, -1px) rotate(35deg);
  transform-origin: left center;
}

.page-icon-address::before {
  width: 18px;
  height: 12px;
  border: 2px solid currentColor;
}

.page-icon-address::after {
  width: 12px;
  height: 2px;
  background: currentColor;
  transform: translateY(-1px) rotate(28deg);
}

.page-icon-attachment::before {
  width: 16px;
  height: 20px;
  border: 2px solid currentColor;
}

.page-icon-attachment::after {
  width: 8px;
  height: 8px;
  border-top: 2px solid currentColor;
  border-right: 2px solid currentColor;
  transform: translate(4px, -6px);
}

.page-icon-verification::before {
  width: 17px;
  height: 17px;
  border: 2px solid currentColor;
  transform: rotate(45deg);
}

.page-icon-verification::after {
  width: 10px;
  height: 5px;
  border-left: 2px solid currentColor;
  border-bottom: 2px solid currentColor;
  transform: translateY(-1px) rotate(-45deg);
}

.page-icon-dkim::before {
  width: 18px;
  height: 14px;
  border: 2px solid currentColor;
  transform: translateY(3px);
}

.page-icon-dkim::after {
  width: 10px;
  height: 8px;
  border: 2px solid currentColor;
  border-bottom: 0;
  transform: translateY(-8px);
}

.page-icon-digest::before {
  width: 18px;
  height: 18px;
  border: 2px solid currentColor;
}

.page-icon-digest::after {
  width: 12px;
  height: 2px;
  background: currentColor;
  box-shadow: 0 5px 0 currentColor;
  transform: translateY(-3px);
}

.page-icon-platform::before {
  width: 20px;
  height: 12px;
  border-top: 2px solid currentColor;
  border-bottom: 2px solid currentColor;
}

.page-icon-platform::after {
  width: 2px;
  height: 20px;
  background: currentColor;
  box-shadow: -7px 0 0 currentColor, 7px 0 0 currentColor;
}

.page-icon-audit::before {
  width: 16px;
  height: 20px;
  border: 2px solid currentColor;
}

.page-icon-audit::after {
  width: 9px;
  height: 2px;
  background: currentColor;
  box-shadow: 0 5px 0 currentColor, 0 10px 0 currentColor;
  transform: translateY(-5px);
}

.page-label {
  display: block;
  font-size: var(--font-title);
  font-weight: 700;
  line-height: 1.35;
}

.sidebar-footer {
  min-height: 0;
  align-content: end;
}

.context-list dd,
.hero-action-card strong,
.kpi-card strong {
  display: block;
}

.sidebar-locale span {
  color: var(--nav-muted);
}

.sidebar-locale select {
  color: var(--nav-text);
  border-color: rgba(255, 255, 255, 0.14);
  background: rgba(255, 255, 255, 0.08);
  box-shadow: none;
}

.sidebar-locale select option {
  color: var(--text);
}

.workspace {
  min-width: 0;
  gap: 18px;
  align-content: start;
  padding: 18px;
}

.panel,
.drawer,
.record-row,
.summary-card,
.trace-section,
.audit-entry,
.empty-state,
.loading-row,
.status-banner,
.traffic-row,
.mini-stat,
.status-tile,
.ranked-row {
  min-width: 0;
  border: 1px solid var(--line);
  border-radius: var(--radius-md);
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.72), rgba(255, 255, 255, 0.64)),
    var(--panel);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.75),
    var(--shadow-panel);
  backdrop-filter: blur(18px);
}

.panel,
.drawer {
  padding: 20px;
}

.topbar {
  position: sticky;
  top: 0;
  z-index: 20;
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 14px;
}

.topbar-primary,
.topbar-actions,
.hero-badges,
.inline-actions,
.toolbar-actions,
.toolbar-chips,
.record-tags,
.record-actions,
.empty-state-actions,
.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  align-items: center;
}

.topbar-actions {
  justify-content: flex-end;
}

.topbar-primary {
  min-width: 0;
}

.mobile-nav-button {
  display: none;
}

.search-shell {
  min-width: 0;
  flex: 1 1 auto;
  width: 100%;
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  gap: 10px;
  align-items: center;
  padding: 0 14px;
  min-height: 52px;
  border-radius: var(--radius-md);
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.88);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.86),
    var(--shadow-panel);
}

.search-shell:focus-within {
  border-color: rgba(39, 104, 227, 0.4);
  box-shadow:
    0 0 0 4px rgba(39, 104, 227, 0.1),
    inset 0 1px 0 rgba(255, 255, 255, 0.9),
    var(--shadow-panel);
}

.search-shell input {
  min-width: 0;
  padding: 0;
  border: 0;
  background: transparent;
  box-shadow: none;
}

.search-icon,
.search-shortcut {
  color: var(--text-faint);
  font-weight: 700;
}

.search-icon {
  position: relative;
  width: 17px;
  height: 17px;
  border: 2px solid currentColor;
  border-radius: 50%;
}

.search-icon::after {
  width: 8px;
  height: 2px;
  right: -6px;
  bottom: -3px;
  background: currentColor;
  transform: rotate(45deg);
  transform-origin: left center;
}

.search-shortcut {
  padding: 4px 8px;
  border-radius: var(--radius-xs);
  background: var(--panel-muted);
  border: 1px solid var(--line);
  font-size: 0.82rem;
}

.operator-chip {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  gap: 12px;
  align-items: center;
  padding: 8px 10px;
  border-radius: var(--radius-md);
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.84);
}

.operator-copy strong,
.context-list dd,
.hero-action-card strong,
.kpi-card strong,
.ranked-row strong,
.traffic-row strong {
  min-width: 0;
  font-size: var(--font-title);
  font-weight: 700;
  line-height: 1.35;
  letter-spacing: 0;
  color: var(--text);
  overflow-wrap: anywhere;
}

.mini-stat strong {
  min-width: 0;
  font-size: var(--font-copy);
  font-weight: 700;
  line-height: 1.4;
  letter-spacing: 0;
  color: var(--text);
  overflow-wrap: anywhere;
  text-align: right;
}

.operator-copy span {
  display: block;
  font-size: var(--font-copy);
  font-weight: 400;
  color: var(--text-soft);
}

.overview-stack {
  gap: 16px;
}

.page-view {
  display: none;
}

.page-view.page-view-active,
.page-header {
  display: grid;
}

.section-stack {
  gap: 16px;
}

.page-header {
  gap: 8px;
}

.page-header h2 {
  margin: 0;
}

.page-header p {
  margin: 0;
  font-size: var(--font-copy);
  font-weight: 400;
  color: var(--text-soft);
  line-height: 1.55;
}

.overview-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.55fr) minmax(18rem, 0.95fr);
  gap: 16px;
}

.hero-card {
  display: grid;
  grid-template-columns: minmax(0, 1.2fr) minmax(15rem, 0.8fr);
  gap: 16px;
  overflow: hidden;
  position: relative;
  min-height: 282px;
  background:
    linear-gradient(135deg, rgba(255, 255, 255, 0.9), rgba(245, 249, 253, 0.7)),
    linear-gradient(135deg, rgba(39, 104, 227, 0.09), rgba(31, 138, 90, 0.06));
}

.hero-card::before {
  content: "";
  position: absolute;
  inset: 0;
  background:
    linear-gradient(90deg, rgba(39, 104, 227, 0.08), transparent 38%),
    linear-gradient(180deg, rgba(255, 255, 255, 0.2), transparent 44%);
  pointer-events: none;
}

.hero-card::after {
  content: "";
  position: absolute;
  inset: auto 24px 22px auto;
  width: 42%;
  height: 1px;
  background: linear-gradient(90deg, transparent, rgba(39, 104, 227, 0.34), transparent);
  pointer-events: none;
}

.hero-copy-block,
.context-card,
.dashboard-module,
.kpi-card {
  position: relative;
  z-index: 1;
}

.hero-copy-block {
  display: grid;
  gap: 14px;
  align-content: start;
}

.hero-card h2 {
  font-size: var(--font-title);
  letter-spacing: 0;
}

.hero-copy {
  margin: 0;
  max-width: 50rem;
  line-height: 1.6;
}

.hero-actions {
  align-content: stretch;
}

.hero-action-card {
  flex: 1 1 100%;
  min-height: 124px;
  display: grid;
  gap: 8px;
  padding: 18px;
  border-radius: var(--radius-md);
  border: 1px solid rgba(204, 216, 229, 0.86);
  background: rgba(255, 255, 255, 0.62);
}

.hero-action-card strong {
  font-size: var(--font-title);
}

.context-card {
  display: grid;
  gap: 14px;
}

.compact-head {
  margin-bottom: 2px;
}

.context-list {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.context-list div {
  min-width: 0;
  padding: 14px;
  border-radius: var(--radius-sm);
  background: rgba(248, 251, 254, 0.76);
  border: 1px solid rgba(204, 216, 229, 0.76);
}

.context-list dt {
  min-width: 0;
  font-size: var(--font-copy);
  font-weight: 400;
  text-transform: none;
  letter-spacing: 0;
  overflow-wrap: anywhere;
}

.context-list dd {
  min-width: 0;
  margin: 8px 0 0;
  font-weight: 700;
  overflow-wrap: anywhere;
}

.badge,
.pill,
.status-chip {
  min-width: 0;
  max-width: 100%;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  border-radius: var(--radius-xs);
  padding: 7px 11px;
  font-size: 0.8rem;
  font-weight: 700;
  overflow-wrap: anywhere;
  white-space: normal;
}

.badge,
.pill {
  background: var(--accent-soft);
  color: var(--accent);
}

.badge.ok,
.status-chip.ok {
  background: var(--success-soft);
  color: var(--success);
}

.badge.warn,
.status-chip.warn {
  background: var(--warning-soft);
  color: var(--warning);
}

.badge.danger,
.status-chip.danger {
  background: var(--danger-soft);
  color: var(--danger);
}

.badge.muted,
.status-chip.muted {
  background: rgba(97, 113, 129, 0.12);
  color: var(--text-soft);
}

.primary-button,
.secondary-button,
.icon-button,
.list-action {
  background: var(--panel-strong);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.86),
    var(--shadow-panel);
}

.primary-button,
.secondary-button {
  padding: 12px 16px;
}

.primary-button {
  color: #fff;
  background: linear-gradient(135deg, var(--accent) 0%, var(--accent-strong) 100%);
  box-shadow: 0 14px 28px rgba(39, 104, 227, 0.24);
}

.secondary-button,
.list-action,
.icon-button {
  color: var(--accent-strong);
  border-color: var(--line);
}

.compact-button {
  padding: 10px 14px;
}

.icon-button {
  position: relative;
  width: 42px;
  height: 42px;
  display: grid;
  place-items: center;
}

.menu-icon,
.close-icon {
  position: relative;
  width: 18px;
  height: 18px;
  display: block;
  color: currentColor;
}

.menu-icon::before,
.menu-icon::after {
  left: 2px;
  width: 14px;
  height: 2px;
  border-radius: 2px;
  background: currentColor;
  box-shadow: 0 6px 0 currentColor;
}

.menu-icon::before {
  top: 3px;
}

.menu-icon::after {
  top: 15px;
  box-shadow: none;
}

.close-icon::before,
.close-icon::after {
  top: 8px;
  left: 2px;
  width: 14px;
  height: 2px;
  border-radius: 2px;
  background: currentColor;
}

.close-icon::before {
  transform: rotate(45deg);
}

.close-icon::after {
  transform: rotate(-45deg);
}

.primary-button:hover,
.secondary-button:hover,
.icon-button:hover,
.list-action:hover {
  transform: translateY(-1px);
}

.kpi-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 14px;
}

.kpi-card {
  overflow: hidden;
  position: relative;
  display: grid;
  gap: 8px;
  min-height: 146px;
  padding-top: 18px;
}

.kpi-card::before {
  content: "";
  position: absolute;
  inset: 0 auto 0 0;
  width: 4px;
  border-radius: 4px;
  background: var(--line-strong);
}

.kpi-card strong {
  font-size: var(--font-title);
  letter-spacing: 0;
}

.kpi-card p {
  margin: 0;
  font-size: var(--font-copy);
  font-weight: 400;
  line-height: 1.5;
}

.accent-ok::before {
  background: var(--success);
}

.accent-primary::before {
  background: var(--accent);
}

.accent-warn::before {
  background: var(--warning);
}

.accent-danger::before {
  background: var(--danger);
}

.accent-neutral::before {
  background: var(--line-strong);
}

.dashboard-grid {
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 14px;
}

.dashboard-core-grid {
  grid-template-columns: repeat(4, minmax(13rem, 1fr));
  align-items: stretch;
}

.dashboard-module {
  gap: 14px;
}

.dashboard-core-card {
  display: grid;
  grid-template-rows: auto minmax(0, 1fr);
  align-content: start;
  gap: 16px;
  min-height: 100%;
  border-color: rgba(181, 197, 213, 0.98);
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.86), rgba(248, 251, 254, 0.76)),
    var(--panel-strong);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.9),
    0 14px 30px rgba(17, 27, 39, 0.07);
}

.dashboard-core-card .mini-stat-list.two-columns {
  grid-template-columns: 1fr;
}

.traffic-module {
  grid-column: span 2;
}

.dashboard-core-grid > .traffic-module {
  grid-column: 1 / -1;
}

.mini-stat-list.two-columns {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.mini-stat,
.status-tile,
.ranked-row,
.traffic-row {
  padding: 14px;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.68), rgba(248, 251, 254, 0.7)),
    var(--panel-soft);
}

.mini-stat {
  display: grid;
  grid-template-columns: minmax(7rem, 0.9fr) minmax(0, 1.1fr);
  gap: 12px;
  align-items: start;
}

.mini-stat > div {
  min-width: 0;
}

.mini-stat span,
.status-tile p,
.ranked-row p,
.traffic-row small {
  min-width: 0;
  display: block;
  font-size: var(--font-copy);
  font-weight: 400;
  line-height: 1.4;
  overflow-wrap: anywhere;
}

.status-tile-grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.status-tile {
  display: grid;
  gap: 8px;
  min-width: 0;
}

.ranked-row {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) minmax(0, auto);
  gap: 12px;
  align-items: start;
}

.ranked-index {
  width: 32px;
  height: 32px;
  display: grid;
  place-items: center;
  border-radius: var(--radius-xs);
  background: var(--panel-muted);
  font-size: 0.8rem;
  font-weight: 800;
  color: var(--text-soft);
}

.ranked-row strong,
.traffic-row strong {
  margin-bottom: 4px;
}

.traffic-layout {
  grid-template-columns: minmax(0, 1.2fr) minmax(18rem, 0.9fr);
  gap: 14px;
}

.traffic-chart {
  grid-template-columns: repeat(7, minmax(0, 1fr));
  gap: 12px;
  align-items: end;
  min-height: 260px;
  padding: 12px;
  border-radius: var(--radius-md);
  background:
    linear-gradient(180deg, rgba(39, 104, 227, 0.05), transparent 28%),
    rgba(248, 251, 254, 0.72);
  border: 1px solid rgba(204, 216, 229, 0.76);
}

.traffic-bar {
  display: grid;
  gap: 8px;
  align-items: end;
}

.traffic-bar-stack {
  height: 180px;
  display: flex;
  align-items: end;
  justify-content: center;
  gap: 6px;
}

.traffic-bar-segment {
  width: 14px;
  min-height: 8px;
  border-radius: 8px 8px 4px 4px;
}

.traffic-bar-segment.total {
  background: linear-gradient(180deg, rgba(39, 104, 227, 0.92), rgba(39, 104, 227, 0.52));
}

.traffic-bar-segment.quarantine {
  background: linear-gradient(180deg, rgba(191, 122, 18, 0.92), rgba(191, 122, 18, 0.48));
}

.traffic-bar-segment.security {
  background: linear-gradient(180deg, rgba(193, 66, 73, 0.92), rgba(193, 66, 73, 0.48));
}

.traffic-bar-label,
.traffic-bar-total {
  text-align: center;
}

.traffic-bar-label {
  font-size: var(--font-copy);
  font-weight: 400;
  color: var(--text-soft);
}

.traffic-bar-total {
  font-size: var(--font-title);
  font-weight: 700;
  color: var(--text);
}

.traffic-table {
  gap: 10px;
}

.data-table-wrap {
  overflow-x: auto;
}

.data-table {
  width: 100%;
  min-width: 58rem;
  border-collapse: collapse;
  font-size: var(--font-copy);
}

.data-table th,
.data-table td {
  padding: 10px 12px;
  border-bottom: 1px solid var(--line);
  text-align: right;
  min-width: 0;
  overflow-wrap: anywhere;
  white-space: normal;
}

.data-table th:first-child,
.data-table td:first-child {
  text-align: left;
}

.data-table thead th {
  color: var(--text-faint);
  font-size: var(--font-copy);
  font-weight: 400;
  text-transform: none;
  letter-spacing: 0;
}

.data-table tbody th {
  color: var(--text);
  font-weight: 700;
}

.data-table tbody td {
  font-weight: 700;
}

.traffic-row {
  display: grid;
  gap: 4px;
}

.feedback {
  padding: 12px 14px;
  border-radius: var(--radius-sm);
  border: 1px solid rgba(31, 138, 90, 0.2);
  background: rgba(31, 138, 90, 0.08);
}

.feedback.error {
  border-color: rgba(193, 66, 73, 0.2);
  color: var(--danger);
  background: rgba(193, 66, 73, 0.08);
}

.feedback.warning {
  border-color: rgba(191, 122, 18, 0.22);
  color: var(--warning);
  background: rgba(191, 122, 18, 0.08);
}

.section-panel {
  gap: 16px;
  scroll-margin-top: 24px;
}

.section-panel > .management-list-stack {
  overflow: hidden;
  gap: 0;
  border: 1px solid rgba(204, 216, 229, 0.88);
  border-radius: var(--radius-md);
  background: rgba(255, 255, 255, 0.58);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.78),
    0 8px 22px rgba(17, 27, 39, 0.045);
}

.section-panel > .management-list-stack + .management-list-stack {
  margin-top: 10px;
}

.setup-tabs {
  display: grid;
  gap: 14px;
  padding: 14px;
}

.tab-strip {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  padding: 6px;
  border: 1px solid rgba(204, 216, 229, 0.88);
  border-radius: var(--radius-md);
  background: rgba(248, 251, 254, 0.72);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.78);
}

.tab-strip-secondary {
  padding: 0;
  border: 0;
  background: transparent;
  box-shadow: none;
}

.tab-button {
  min-height: 36px;
  padding: 8px 12px;
  border: 1px solid transparent;
  border-radius: var(--radius-xs);
  color: var(--text-soft);
  background: transparent;
  font-size: var(--font-copy);
  font-weight: 700;
}

.tab-button:hover,
.tab-button:focus-visible {
  color: var(--text);
  border-color: rgba(204, 216, 229, 0.88);
  background: rgba(255, 255, 255, 0.72);
}

.tab-button-active {
  color: var(--text);
  border-color: rgba(39, 104, 227, 0.24);
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.9), rgba(248, 251, 254, 0.84)),
    var(--panel-strong);
  box-shadow: 0 8px 18px rgba(17, 27, 39, 0.06);
}

.setup-tab-panel {
  display: grid;
  gap: 12px;
}

.setup-panel {
  border: 1px solid rgba(204, 216, 229, 0.88);
  border-radius: var(--radius-md);
  background: rgba(255, 255, 255, 0.58);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.78),
    0 8px 22px rgba(17, 27, 39, 0.045);
}

.compact-empty-state {
  margin-top: 12px;
  border: 1px dashed rgba(181, 197, 213, 0.92);
  background: rgba(248, 251, 254, 0.7);
}

.section-head,
.drawer-header,
.record-head {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 12px;
}

.search-toolbar {
  display: grid;
  grid-template-columns: minmax(240px, 1fr) 180px 180px auto;
  gap: 12px;
}

.history-toolbar {
  grid-template-columns: minmax(220px, 1fr) 150px 150px 180px 180px auto;
}

label,
.locale-picker {
  display: grid;
  gap: 8px;
}

input,
textarea,
select {
  width: 100%;
  padding: 12px 14px;
  color: var(--text);
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  background: rgba(255, 255, 255, 0.96);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.86);
}

textarea {
  resize: vertical;
}

input:focus,
textarea:focus,
select:focus {
  border-color: rgba(39, 104, 227, 0.42);
  box-shadow:
    0 0 0 4px rgba(39, 104, 227, 0.1),
    inset 0 1px 0 rgba(255, 255, 255, 0.9);
}

.field-error input,
.field-error textarea,
.field-error select,
input.invalid,
textarea.invalid,
select.invalid {
  border-color: rgba(193, 66, 73, 0.64);
}

.form-error-list {
  padding: 12px 14px;
  border: 1px solid rgba(193, 66, 73, 0.2);
  border-radius: var(--radius-sm);
  color: var(--danger);
  background: rgba(193, 66, 73, 0.08);
}

.form-error-list p,
.form-error-list ul {
  margin: 0;
}

.form-error-list ul {
  padding-left: 18px;
}

.locale-row {
  display: flex;
  justify-content: flex-end;
  margin-bottom: 16px;
}

.login-card {
  width: min(480px, calc(100vw - 32px));
}

.fields {
  gap: 14px;
}

.record-row,
.empty-state,
.loading-row,
.status-banner,
.audit-entry,
.trace-section {
  padding: 16px;
}

.record-row,
.empty-state,
.loading-row {
  gap: 10px;
}

.management-list-stack > .record-row,
.management-list-stack > .empty-state,
.management-list-stack > .loading-row,
.management-list-stack > .summary-card {
  border-width: 0 0 1px;
  border-radius: 0;
  box-shadow: none;
  background: rgba(255, 255, 255, 0.55);
}

.management-list-stack > .record-row:last-child,
.management-list-stack > .empty-state:last-child,
.management-list-stack > .loading-row:last-child,
.management-list-stack > .summary-card:last-child {
  border-bottom-width: 0;
}

.management-list-stack > .record-row:hover {
  background: rgba(248, 251, 254, 0.84);
}

#quarantine-list,
#history-list,
#mail-log,
#audit-log,
#message-log,
#email-alert-log {
  overflow-x: auto;
}

.quarantine-bulk-actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 10px;
  padding: 10px 16px 12px;
  border-bottom: 1px solid rgba(204, 216, 229, 0.88);
}

.history-table-header,
.history-message-row,
.log-table-header,
.log-message-row,
.quarantine-table-header,
.quarantine-message-row {
  display: grid;
  gap: 12px;
  align-items: center;
  min-width: max-content;
}

.history-table-header,
.history-message-row {
  grid-template-columns: var(--history-grid-columns, 172px 176px 144px 132px 220px 220px 112px);
}

.log-table-header,
.log-message-row {
  grid-template-columns: var(--log-grid-columns, 172px 180px 220px 360px);
}

.quarantine-table-header,
.quarantine-message-row {
  grid-template-columns: var(--quarantine-grid-columns, 112px 220px 220px 280px 172px 112px);
}

.history-table-header,
.log-table-header,
.quarantine-table-header {
  padding: 10px 16px;
  border-bottom: 1px solid rgba(204, 216, 229, 0.88);
  color: var(--text-faint);
  font-size: var(--font-copy);
  font-weight: 700;
  background: rgba(248, 251, 254, 0.74);
}

.history-message-row,
.log-message-row,
.quarantine-message-row {
  width: 100%;
  padding: 12px 16px;
  border: 0;
  border-bottom: 1px solid rgba(204, 216, 229, 0.88);
  color: var(--text);
  background: rgba(255, 255, 255, 0.55);
  text-align: left;
}

.quarantine-message-row {
  cursor: pointer;
  text-align: left;
}

.history-message-row:last-child,
.log-message-row:last-child,
.quarantine-message-row:last-child {
  border-bottom: 0;
}

.history-message-row:hover,
.history-message-row:focus-visible,
.log-message-row:hover,
.quarantine-message-row:hover,
.quarantine-message-row:focus-visible,
.quarantine-message-row.selected {
  background: rgba(248, 251, 254, 0.9);
}

.history-table-header span,
.history-message-row span,
.log-table-header span,
.log-message-row span,
.quarantine-table-header span,
.quarantine-message-row span {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.history-column-heading,
.log-column-heading,
.quarantine-column-heading {
  position: relative;
  display: flex;
  align-items: center;
  min-width: 0;
  overflow: visible;
}

.history-column-heading button,
.log-column-heading button,
.quarantine-column-heading button {
  width: 100%;
  min-width: 0;
  overflow: hidden;
  color: inherit;
  font: inherit;
  font-weight: 700;
  text-align: left;
  text-overflow: ellipsis;
  white-space: nowrap;
  background: transparent;
}

.history-column-heading button:hover,
.history-column-heading button:focus-visible,
.log-column-heading button:hover,
.log-column-heading button:focus-visible,
.quarantine-column-heading button:hover,
.quarantine-column-heading button:focus-visible {
  color: var(--text);
}

.quarantine-select-checkbox {
  width: 16px;
  height: 16px;
  accent-color: var(--accent);
  flex: 0 0 auto;
}

.history-column-resizer,
.log-column-resizer {
  position: absolute;
  top: -10px;
  right: -8px;
  bottom: -10px;
  width: 12px;
  overflow: visible;
  cursor: col-resize;
}

.history-column-resizer::after,
.log-column-resizer::after {
  content: "";
  position: absolute;
  top: 8px;
  right: 5px;
  bottom: 8px;
  width: 1px;
  background: rgba(181, 197, 213, 0.8);
}

.record-title {
  margin: 0;
  overflow-wrap: anywhere;
}

.record-grid {
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
}

.summary-card {
  min-width: 0;
  padding: 12px 14px;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.72), rgba(248, 251, 254, 0.72)),
    var(--panel-muted);
}

.dashboard-detail-list {
  min-width: 0;
}

.dashboard-detail-table-card {
  min-width: 0;
  overflow: hidden;
  border: 1px solid rgba(216, 226, 236, 0.92);
  border-radius: var(--radius-md);
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.78), rgba(248, 251, 254, 0.72)),
    var(--panel-muted);
}

.dashboard-detail-table {
  width: 100%;
  border-collapse: collapse;
  font-size: var(--font-copy);
}

.dashboard-detail-table th,
.dashboard-detail-table td {
  min-width: 0;
  padding: 10px 12px;
  border-bottom: 1px solid rgba(216, 226, 236, 0.82);
  text-align: left;
  vertical-align: top;
}

.dashboard-detail-table tr:last-child th,
.dashboard-detail-table tr:last-child td {
  border-bottom: 0;
}

.dashboard-detail-table th {
  width: 42%;
  color: var(--text-soft);
  font-weight: 400;
  overflow-wrap: anywhere;
}

.dashboard-detail-table td {
  color: var(--text);
}

.dashboard-detail-table strong,
.dashboard-detail-table small {
  display: block;
  font-size: var(--font-copy);
  line-height: 1.35;
  overflow-wrap: anywhere;
  word-break: normal;
}

.dashboard-detail-table strong {
  font-weight: 700;
}

.dashboard-detail-table small {
  margin-top: 2px;
  color: var(--text-soft);
  font-weight: 400;
}

.system-report-table th {
  width: 32%;
}

.system-report-table td {
  vertical-align: middle;
}

.system-report-table-actions {
  table-layout: fixed;
}

.system-report-table-actions th {
  width: 32%;
}

.system-report-table-actions td:last-child {
  width: 10rem;
}

.system-report-action-cell {
  text-align: right;
  white-space: nowrap;
}

.system-report-action-cell .secondary-button {
  width: auto;
}

.resource-meter {
  display: grid;
  grid-template-columns: minmax(8rem, 1fr) auto;
  align-items: center;
  gap: 12px;
  min-width: 0;
}

.resource-meter-track {
  position: relative;
  display: block;
  height: 12px;
  overflow: hidden;
  border: 1px solid rgba(181, 197, 213, 0.72);
  border-radius: 999px;
  background: rgba(226, 233, 241, 0.92);
}

.resource-meter-fill {
  display: block;
  height: 100%;
  border-radius: inherit;
  background: linear-gradient(90deg, var(--success) 0%, var(--accent) 100%);
}

.resource-meter-meta {
  display: flex;
  align-items: baseline;
  justify-content: flex-end;
  gap: 8px;
  min-width: 8.5rem;
  color: var(--text-soft);
}

.system-reporting-page {
  display: grid;
  gap: 18px;
  min-width: 0;
}

.system-report-section {
  display: grid;
  gap: 10px;
  min-width: 0;
}

.system-report-section-head h4 {
  margin: 0;
  color: var(--text);
  font-size: var(--font-title);
  line-height: 1.25;
}

.system-report-row,
.system-tool-row {
  align-items: center;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 12px;
}

.system-tool-row label {
  display: grid;
  grid-template-columns: minmax(96px, 0.18fr) minmax(180px, 1fr);
  align-items: center;
  gap: 10px;
  min-width: 0;
  color: var(--text-soft);
  font-size: var(--font-copy);
}

.system-tool-row input,
.system-report-table input,
.system-file-input {
  width: 100%;
  min-width: 0;
}

.diagnostic-output {
  max-height: 56vh;
  overflow: auto;
  white-space: pre-wrap;
  word-break: break-word;
}

.diagnostic-output-pending {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  color: var(--text-soft);
  white-space: normal;
}

.mail-queue-output {
  display: grid;
  gap: 12px;
}

.mail-queue-reachability {
  display: flex;
  justify-content: flex-start;
}

.mail-queue-metric-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
}

.mail-queue-metric {
  min-width: 0;
  padding: 12px;
  border: 1px solid rgba(216, 226, 236, 0.88);
  border-radius: var(--radius-sm);
  background: rgba(248, 251, 254, 0.78);
}

.mail-queue-metric span,
.mail-queue-metric strong {
  display: block;
  overflow-wrap: anywhere;
}

.mail-queue-metric span {
  color: var(--text-soft);
  font-size: var(--font-copy);
}

.mail-queue-metric strong {
  margin-top: 6px;
  color: var(--text);
  font-size: 1.25rem;
  line-height: 1.1;
}

.health-check-output {
  display: grid;
  gap: 14px;
}

.health-check-summary-grid {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 10px;
}

.health-check-summary-card {
  min-width: 0;
  padding: 12px;
  border: 1px solid rgba(216, 226, 236, 0.88);
  border-radius: var(--radius-sm);
  background: rgba(248, 251, 254, 0.78);
}

.health-check-summary-label,
.health-check-summary-card strong {
  display: block;
  overflow-wrap: anywhere;
}

.health-check-summary-label {
  color: var(--text-soft);
  font-size: var(--font-copy);
}

.health-check-summary-card strong,
.health-check-summary-card .status-chip {
  margin-top: 6px;
}

.health-check-summary-card strong {
  color: var(--text);
  font-size: 1.08rem;
  line-height: 1.2;
}

.health-check-list {
  display: grid;
  gap: 8px;
}

.health-check-row {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  gap: 12px;
  align-items: start;
  min-width: 0;
  padding: 12px;
  border: 1px solid rgba(216, 226, 236, 0.88);
  border-radius: var(--radius-sm);
  background: rgba(255, 255, 255, 0.74);
}

.health-check-marker {
  width: 12px;
  height: 12px;
  margin-top: 5px;
  border-radius: 999px;
  background: var(--line-strong);
  box-shadow: 0 0 0 4px rgba(112, 128, 146, 0.12);
}

.health-check-marker.ok,
.health-check-marker.ready {
  background: var(--success);
  box-shadow: 0 0 0 4px rgba(30, 146, 92, 0.14);
}

.health-check-marker.warn,
.health-check-marker.degraded {
  background: var(--warning);
  box-shadow: 0 0 0 4px rgba(194, 126, 0, 0.16);
}

.health-check-marker.failed,
.health-check-marker.danger {
  background: var(--danger);
  box-shadow: 0 0 0 4px rgba(196, 59, 59, 0.14);
}

.health-check-row-body {
  min-width: 0;
}

.health-check-row-body strong,
.health-check-row-body p {
  overflow-wrap: anywhere;
}

.health-check-row-body p {
  margin: 4px 0 0;
  color: var(--text-soft);
  font-size: var(--font-copy);
  line-height: 1.45;
}

.health-check-row-actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 6px;
}

.health-check-impact {
  display: inline-flex;
  align-items: center;
  min-height: 26px;
  padding: 4px 9px;
  border-radius: 999px;
  border: 1px solid rgba(216, 226, 236, 0.88);
  color: var(--text-soft);
  background: rgba(248, 251, 254, 0.78);
  font-size: var(--font-caption);
  font-weight: 700;
  line-height: 1.2;
}

.health-check-impact.critical {
  color: var(--danger);
  border-color: rgba(196, 59, 59, 0.25);
  background: rgba(196, 59, 59, 0.08);
}

.diagnostic-hourglass {
  position: relative;
  width: 18px;
  height: 22px;
  flex: 0 0 auto;
  border-top: 3px solid var(--warning);
  border-bottom: 3px solid var(--warning);
  animation: diagnostic-hourglass-turn 1.15s linear infinite;
}

.diagnostic-hourglass::before,
.diagnostic-hourglass::after {
  content: "";
  position: absolute;
  left: 4px;
  right: 4px;
  border-left: 5px solid transparent;
  border-right: 5px solid transparent;
}

.diagnostic-hourglass::before {
  top: 3px;
  border-top: 7px solid var(--warning);
}

.diagnostic-hourglass::after {
  bottom: 3px;
  border-bottom: 7px solid rgba(191, 122, 18, 0.42);
}

@keyframes diagnostic-hourglass-turn {
  0%,
  45% {
    transform: rotate(0deg);
  }

  55%,
  100% {
    transform: rotate(180deg);
  }
}

.network-interface-panel {
  display: grid;
  gap: 10px;
  margin-top: 12px;
  min-width: 0;
}

.network-interface-panel h5 {
  margin: 0;
  color: var(--text);
  font-size: var(--font-title);
  font-weight: 700;
  line-height: 1.35;
  overflow-wrap: anywhere;
}

.network-interface-table-wrap {
  border: 1px solid rgba(216, 226, 236, 0.9);
  border-radius: var(--radius-sm);
  background: rgba(255, 255, 255, 0.64);
}

.network-interface-table {
  min-width: 38rem;
}

.network-interface-table th,
.network-interface-table td {
  text-align: left;
}

.system-value-list {
  display: grid;
  gap: 8px;
  margin-top: 10px;
}

.system-value-list code {
  display: block;
  min-width: 0;
  padding: 8px 10px;
  border: 1px solid rgba(204, 216, 229, 0.78);
  border-radius: var(--radius-sm);
  background: rgba(248, 251, 254, 0.82);
  color: var(--text);
  overflow-wrap: anywhere;
}

.danger-action {
  border-color: rgba(218, 82, 82, 0.42);
  color: #9f1f1f;
}

.accepted-domain-table {
  min-width: 72rem;
}

.accepted-domain-table th,
.accepted-domain-table td {
  text-align: left;
  vertical-align: middle;
}

.table-action-icons,
.list-footer-actions {
  display: flex;
  align-items: center;
  gap: 8px;
}

.table-action-icons {
  justify-content: flex-end;
  flex-wrap: nowrap;
}

.list-footer-actions {
  justify-content: flex-end;
  padding-top: 12px;
}

.table-icon-button {
  width: 34px;
  height: 34px;
  box-shadow: none;
}

.danger-icon-button {
  color: var(--danger);
}

.action-icon {
  position: relative;
  width: 16px;
  height: 16px;
  display: block;
  color: currentColor;
}

.action-icon-edit::before {
  content: "";
  position: absolute;
  width: 12px;
  height: 5px;
  border: 2px solid currentColor;
  border-left-width: 6px;
  transform: translate(1px, 5px) rotate(-35deg);
}

.action-icon-test::before,
.action-icon-test::after {
  content: "";
  position: absolute;
}

.action-icon-test::before {
  inset: 1px;
  border: 2px solid currentColor;
  border-radius: 50%;
}

.action-icon-test::after {
  width: 7px;
  height: 4px;
  left: 4px;
  top: 5px;
  border-left: 2px solid currentColor;
  border-bottom: 2px solid currentColor;
  transform: rotate(-45deg);
}

.action-icon-view::before,
.action-icon-view::after,
.action-icon-download::before,
.action-icon-download::after {
  content: "";
  position: absolute;
}

.action-icon-view::before {
  inset: 1px;
  border: 2px solid currentColor;
  border-radius: 50%;
}

.action-icon-view::after {
  width: 7px;
  height: 2px;
  right: -1px;
  bottom: 1px;
  border-radius: 2px;
  background: currentColor;
  transform: rotate(45deg);
}

.action-icon-download::before {
  left: 7px;
  top: 1px;
  width: 2px;
  height: 10px;
  border-radius: 2px;
  background: currentColor;
}

.action-icon-download::after {
  left: 3px;
  top: 8px;
  width: 8px;
  height: 8px;
  border-right: 2px solid currentColor;
  border-bottom: 2px solid currentColor;
  transform: rotate(45deg);
}

.action-icon-delete::before,
.action-icon-delete::after {
  content: "";
  position: absolute;
  left: 3px;
  right: 3px;
  border: 2px solid currentColor;
}

.action-icon-delete::before {
  top: 1px;
  height: 2px;
  border-bottom: 0;
}

.action-icon-delete::after {
  top: 5px;
  bottom: 1px;
  border-top-width: 3px;
}

.host-log-row .table-action-icons {
  justify-content: flex-start;
}

.host-log-preview pre {
  max-height: 62vh;
  overflow: auto;
}

.muted-inline {
  color: var(--text-faint);
  font-size: var(--font-caption);
}

.record-actions {
  justify-content: flex-start;
}

.list-action {
  padding: 9px 12px;
}

.summary-grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}

.summary-card strong,
.trace-section h4,
.empty-state strong {
  display: block;
  margin-bottom: 8px;
  font-size: var(--font-title);
  font-weight: 700;
  line-height: 1.35;
  max-width: 100%;
  overflow-wrap: anywhere;
}

.summary-card p,
.record-copy,
.record-meta,
.audit-entry strong,
.audit-entry span,
.audit-entry p,
.trace-item strong,
.trace-item p,
.record-tags {
  min-width: 0;
  max-width: 100%;
  overflow-wrap: anywhere;
}

.record-head > *,
.summary-grid > *,
.trace-columns > *,
.record-grid > * {
  min-width: 0;
}

.trace-columns {
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}

.trace-list {
  display: grid;
  gap: 10px;
}

.trace-item {
  padding: 12px 14px;
  border-radius: var(--radius-sm);
  background: var(--panel-soft);
  border: 1px solid rgba(204, 216, 229, 0.72);
}

.quarantine-dialog,
.quarantine-dialog-panel,
.quarantine-message-view {
  display: grid;
  gap: 14px;
}

.quarantine-dialog-tabs {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  border-bottom: 1px solid rgba(204, 216, 229, 0.88);
  padding-bottom: 10px;
}

.quarantine-detail-list,
.message-header-list {
  display: grid;
  gap: 8px;
  margin: 0;
}

.quarantine-detail-list div,
.message-header-list div {
  display: grid;
  grid-template-columns: minmax(180px, 240px) minmax(0, 1fr);
  gap: 12px;
  align-items: start;
}

.quarantine-detail-list dt,
.message-header-list dt {
  color: var(--text-soft);
  font-weight: 700;
}

.quarantine-detail-list dd,
.message-header-list dd {
  margin: 0;
  min-width: 0;
  overflow-wrap: anywhere;
}

.message-headers-toggle summary {
  cursor: pointer;
  color: var(--accent);
  font-weight: 700;
}

.message-raw-content,
.message-headers-toggle pre {
  margin: 0;
  padding: 12px;
  border-radius: var(--radius-sm);
  border: 1px solid rgba(204, 216, 229, 0.72);
  background: var(--panel-soft);
  white-space: pre-wrap;
  word-break: break-word;
  color: var(--text);
}

.message-attachment-list {
  display: grid;
  gap: 6px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.message-attachment-list li {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  padding: 8px 10px;
  border-radius: var(--radius-sm);
  border: 1px solid rgba(204, 216, 229, 0.72);
  background: var(--panel-soft);
}

.trace-section pre,
.digest-content {
  margin: 0;
  white-space: pre-wrap;
  word-break: break-word;
  color: var(--text);
}

.loading-row {
  background:
    linear-gradient(90deg, rgba(255, 255, 255, 0.78), rgba(245, 249, 252, 0.95), rgba(255, 255, 255, 0.78)),
    var(--panel);
}

.loading-line {
  height: 12px;
  border-radius: var(--radius-xs);
  background: linear-gradient(90deg, rgba(204, 216, 229, 0.72), rgba(226, 233, 241, 0.96), rgba(204, 216, 229, 0.72));
  background-size: 200% 100%;
  animation: pulse 1.2s linear infinite;
}

.loading-line.short {
  width: 34%;
}

.loading-line.medium {
  width: 56%;
}

.loading-line.long {
  width: 82%;
}

@keyframes pulse {
  from {
    background-position: 0 0;
  }

  to {
    background-position: -200% 0;
  }
}

.drawer {
  width: min(620px, calc(100vw - 32px));
  height: calc(100vh - 32px);
  margin: 16px 16px 16px 0;
  overflow: auto;
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-strong);
  animation: drawer-in 180ms var(--spring);
}

.drawer.drawer-wide {
  width: min(920px, calc(100vw - 32px));
}

@keyframes drawer-in {
  from {
    transform: translateX(28px);
    opacity: 0.7;
  }

  to {
    transform: translateX(0);
    opacity: 1;
  }
}

.drawer-content {
  gap: 18px;
}

.field-grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
}

.field-span-full {
  grid-column: span 2;
}

.toggle-field {
  display: grid;
  grid-template-columns: 1fr auto;
  align-items: center;
  padding: 13px 14px;
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  background: rgba(255, 255, 255, 0.82);
}

.toggle-field input {
  width: 20px;
  height: 20px;
}

.split-list {
  margin-top: 4px;
}

@media (max-width: 1400px) {
  .kpi-grid,
  .dashboard-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .traffic-module {
    grid-column: span 2;
  }
}

@media (max-width: 1200px) {
  .overview-grid,
  .hero-card,
  .traffic-layout,
  .topbar {
    grid-template-columns: 1fr;
  }

  .search-toolbar,
  .history-toolbar,
  .record-grid,
  .summary-grid,
  .trace-columns,
  .field-grid,
  .mini-stat-list.two-columns,
  .status-tile-grid,
  .context-list {
    grid-template-columns: 1fr;
  }

  .field-span-full {
    grid-column: span 1;
  }
}

@media (max-width: 1024px) {
  .console-shell {
    grid-template-columns: 1fr;
  }

  .sidebar {
    position: fixed;
    left: 0;
    top: 0;
    width: min(22rem, calc(100vw - 24px));
    transform: translateX(-104%);
    transition: transform 200ms var(--spring);
  }

  body.sidebar-open .sidebar {
    transform: translateX(0);
  }

  body.sidebar-collapsed .sidebar {
    width: min(22rem, calc(100vw - 24px));
    padding-inline: 16px;
  }

  body.sidebar-collapsed .sidebar .brand-copy,
  body.sidebar-collapsed .sidebar .page-copy,
  body.sidebar-collapsed .sidebar .sidebar-locale span,
  body.sidebar-collapsed .sidebar .secondary-button {
    display: initial;
  }

  body.sidebar-collapsed .sidebar .page-button {
    justify-items: initial;
  }

  body.sidebar-collapsed .sidebar .sidebar-brand {
    grid-template-columns: auto minmax(0, 1fr);
    justify-items: initial;
    gap: 14px;
    padding: 16px;
  }

  body.sidebar-collapsed .sidebar .page-button {
    grid-template-columns: auto minmax(0, 1fr);
  }

  .workspace {
    padding: 16px;
  }

  .mobile-nav-button {
    display: inline-flex;
  }

  .sidebar-collapse-button {
    display: none;
  }
}

@media (max-width: 720px) {
  .workspace {
    padding: 14px;
  }

  .topbar-actions,
  .hero-badges,
  .hero-actions,
  .record-actions,
  .inline-actions,
  .empty-state-actions {
    width: 100%;
  }

  .topbar-actions > *,
  .hero-actions > *,
  .record-actions > *,
  .inline-actions > * {
    flex: 1 1 100%;
  }

  .section-head,
  .drawer-header,
  .record-head {
    flex-direction: column;
    align-items: stretch;
  }

  .kpi-grid,
  .dashboard-grid,
  .mail-queue-metric-grid,
  .health-check-summary-grid,
  .traffic-layout {
    grid-template-columns: 1fr;
  }

  .health-check-row {
    grid-template-columns: auto minmax(0, 1fr);
  }

  .health-check-row-actions {
    grid-column: 2;
    justify-content: flex-start;
  }

  .traffic-module {
    grid-column: auto;
  }

  .drawer {
    width: 100%;
    height: calc(100vh - 18px);
    margin: 18px 0 0;
    border-radius: var(--radius-lg) var(--radius-lg) 0 0;
  }

  .quarantine-detail-list div,
  .message-header-list div {
    grid-template-columns: 1fr;
    gap: 4px;
  }
}
