:root {
  --bg: #f4f6f8;
  --surface: #ffffff;
  --surface-muted: #f8fafb;
  --surface-strong: #edf1f4;
  --ink: #17212b;
  --ink-soft: #52606d;
  --ink-faint: #7b8794;
  --line: #dbe1e6;
  --line-strong: #c7d0d9;
  --high: #c63838;
  --high-bg: #fceded;
  --medium: #a4660a;
  --medium-bg: #fff4d9;
  --online: #167553;
  --online-bg: #e8f6f0;
  --accent: #2367a5;
  --accent-dark: #194f80;
  --accent-bg: #eaf2fa;
  --shadow: 0 10px 30px rgba(20, 32, 44, 0.14);
  --radius: 6px;
  --content: 1480px;
  font-family: Inter, ui-sans-serif, -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Microsoft YaHei", sans-serif;
  color: var(--ink);
  background: var(--bg);
  font-synthesis: none;
}

* {
  box-sizing: border-box;
}

html {
  min-width: 320px;
  min-height: 100%;
  background: var(--bg);
}

body {
  min-width: 320px;
  min-height: 100vh;
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-size: 14px;
  line-height: 1.45;
}

button,
input,
select {
  font: inherit;
  letter-spacing: 0;
}

button,
select {
  cursor: pointer;
}

button:focus-visible,
input:focus-visible,
select:focus-visible,
a:focus-visible {
  outline: 3px solid rgba(35, 103, 165, 0.24);
  outline-offset: 2px;
}

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

.skip-link {
  position: fixed;
  z-index: 100;
  top: 8px;
  left: 8px;
  padding: 8px 12px;
  transform: translateY(-160%);
  border-radius: 4px;
  background: var(--ink);
  color: white;
}

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

.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;
}

[hidden] {
  display: none !important;
}

.icon-sprite {
  position: absolute;
  width: 0;
  height: 0;
  overflow: hidden;
}

.icon {
  width: 17px;
  height: 17px;
  flex: 0 0 17px;
  fill: none;
  stroke: currentColor;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.topbar {
  position: sticky;
  z-index: 20;
  top: 0;
  height: 58px;
  border-bottom: 1px solid #202b35;
  background: #17212b;
  color: #f6f8fa;
}

.topbar__inner {
  width: min(100%, var(--content));
  height: 100%;
  margin: 0 auto;
  padding: 0 24px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
}

.brand,
.topbar__actions,
.connection,
.brand__text {
  display: flex;
  align-items: center;
}

.brand {
  min-width: 0;
  gap: 10px;
}

.brand__mark {
  width: 32px;
  height: 32px;
  display: grid;
  place-items: center;
  border: 1px solid rgba(255, 255, 255, 0.17);
  border-radius: 6px;
  background: rgba(255, 255, 255, 0.08);
  color: #79b4e8;
}

.brand__mark .icon {
  width: 19px;
  height: 19px;
}

.brand__text {
  min-width: 0;
  gap: 7px;
  white-space: nowrap;
}

.brand__text strong {
  font-size: 16px;
}

.brand__text span {
  color: #b9c4cd;
  font-size: 13px;
}

.topbar__actions {
  gap: 12px;
}

.connection {
  height: 30px;
  gap: 7px;
  padding: 0 10px;
  border: 1px solid rgba(255, 255, 255, 0.13);
  border-radius: 4px;
  color: #c2cbd3;
  font-size: 12px;
  white-space: nowrap;
}

.connection__dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: #8c99a5;
}

.connection.is-connected .connection__dot {
  background: #45c18a;
  box-shadow: 0 0 0 3px rgba(69, 193, 138, 0.15);
}

.connection.is-reconnecting .connection__dot {
  background: #e6ad48;
  animation: pulse 1.2s ease-in-out infinite;
}

.connection.is-offline .connection__dot {
  background: #e15b5b;
}

.topbar .icon-button {
  color: #cbd4dc;
}

main {
  width: min(100%, var(--content));
  margin: 0 auto;
  padding: 20px 24px 40px;
}

.metric-band {
  min-height: 96px;
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface);
  overflow: hidden;
}

.metric {
  position: relative;
  min-width: 0;
  padding: 17px 18px;
  display: grid;
  grid-template-columns: 38px minmax(0, 1fr);
  grid-template-rows: 1fr auto;
  align-items: center;
  column-gap: 12px;
}

.metric + .metric {
  border-left: 1px solid var(--line);
}

.metric::before {
  content: "";
  position: absolute;
  top: 0;
  right: 0;
  left: 0;
  height: 3px;
  background: var(--line-strong);
}

.metric--high::before { background: var(--high); }
.metric--medium::before { background: #d7962d; }
.metric--users::before { background: var(--accent); }
.metric--servers::before { background: var(--online); }

.metric__icon {
  grid-row: 1 / 3;
  width: 38px;
  height: 38px;
  display: grid;
  place-items: center;
  border-radius: 6px;
  background: var(--surface-strong);
  color: var(--ink-soft);
}

.metric--high .metric__icon { color: var(--high); background: var(--high-bg); }
.metric--medium .metric__icon { color: var(--medium); background: var(--medium-bg); }
.metric--users .metric__icon { color: var(--accent); background: var(--accent-bg); }
.metric--servers .metric__icon { color: var(--online); background: var(--online-bg); }

.metric__copy {
  min-width: 0;
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 8px;
}

.metric__copy > span {
  overflow: hidden;
  color: var(--ink-soft);
  font-size: 12px;
  white-space: nowrap;
  text-overflow: ellipsis;
}

.metric__copy strong {
  font-variant-numeric: tabular-nums;
  font-size: 25px;
  line-height: 1;
}

.metric__period {
  grid-column: 2;
  color: var(--ink-faint);
  font-size: 11px;
}

.workspace {
  margin-top: 18px;
}

.tabs {
  display: flex;
  align-items: flex-end;
  gap: 4px;
  min-height: 43px;
  padding: 0 4px;
  border-bottom: 1px solid var(--line-strong);
  overflow-x: auto;
  scrollbar-width: thin;
}

.tab {
  position: relative;
  min-width: max-content;
  height: 42px;
  padding: 0 13px;
  display: inline-flex;
  align-items: center;
  gap: 7px;
  border: 0;
  background: transparent;
  color: var(--ink-soft);
  font-weight: 600;
}

.tab:hover {
  color: var(--ink);
  background: rgba(255, 255, 255, 0.55);
}

.tab::after {
  content: "";
  position: absolute;
  right: 8px;
  bottom: -1px;
  left: 8px;
  height: 3px;
  background: transparent;
}

.tab.is-active {
  color: var(--accent-dark);
}

.tab.is-active::after {
  background: var(--accent);
}

.tab__count {
  min-width: 19px;
  height: 19px;
  padding: 0 5px;
  display: inline-grid;
  place-items: center;
  border-radius: 10px;
  background: var(--high);
  color: white;
  font-size: 11px;
  font-variant-numeric: tabular-nums;
}

.view {
  padding-top: 16px;
}

.toolbar {
  min-height: 42px;
  margin-bottom: 12px;
  display: flex;
  align-items: center;
  gap: 8px;
}

.toolbar--events .search-field {
  flex: 1 1 300px;
}

.toolbar__actions {
  margin-left: auto;
  display: flex;
  align-items: center;
  gap: 6px;
}

.search-field {
  position: relative;
  min-width: 180px;
  height: 38px;
  display: flex;
  align-items: center;
}

.search-field .icon {
  position: absolute;
  left: 11px;
  color: var(--ink-faint);
  pointer-events: none;
}

.search-field input,
.field input,
.field select {
  width: 100%;
  height: 38px;
  border: 1px solid var(--line-strong);
  border-radius: 5px;
  background: var(--surface);
  color: var(--ink);
}

.search-field input {
  padding: 0 11px 0 36px;
}

.field input,
.field select {
  padding: 0 10px;
}

.search-field input:hover,
.field input:hover,
.field select:hover {
  border-color: #9caab7;
}

.search-field input:focus,
.field input:focus,
.field select:focus {
  border-color: var(--accent);
  outline: 3px solid rgba(35, 103, 165, 0.12);
}

.field--compact {
  flex: 0 1 145px;
  min-width: 116px;
}

.field--compact select {
  min-width: 0;
  padding-right: 28px;
}

.icon-button,
.button {
  height: 36px;
  border-radius: 5px;
  transition: background-color 120ms ease, border-color 120ms ease, color 120ms ease;
}

.icon-button {
  width: 36px;
  padding: 0;
  display: inline-grid;
  place-items: center;
  border: 1px solid transparent;
  background: transparent;
  color: var(--ink-soft);
}

.icon-button:hover {
  background: rgba(255, 255, 255, 0.09);
  color: white;
}

.icon-button--bordered {
  border-color: var(--line-strong);
  background: var(--surface);
}

.icon-button--bordered:hover {
  border-color: #98a6b2;
  background: var(--surface-muted);
  color: var(--ink);
}

.icon-button.is-spinning .icon,
.button.is-loading .icon {
  animation: spin 0.8s linear infinite;
}

.button {
  min-width: 36px;
  padding: 0 13px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  border: 1px solid transparent;
  font-weight: 600;
  white-space: nowrap;
}

.button--quiet {
  border-color: var(--line-strong);
  background: var(--surface);
  color: var(--ink-soft);
}

.button--quiet:hover {
  border-color: #98a6b2;
  background: var(--surface-muted);
  color: var(--ink);
}

.button--primary {
  border-color: var(--accent);
  background: var(--accent);
  color: white;
}

.button--primary:hover {
  border-color: var(--accent-dark);
  background: var(--accent-dark);
}

.button--danger {
  border-color: #e2bbbb;
  background: white;
  color: var(--high);
}

.button--danger:hover {
  border-color: var(--high);
  background: var(--high-bg);
}

.button--wide {
  width: 100%;
}

.new-events {
  width: max-content;
  max-width: 100%;
  height: 34px;
  margin: 0 auto 10px;
  padding: 0 12px;
  display: flex;
  align-items: center;
  gap: 8px;
  border: 1px solid #9bbddc;
  border-radius: 17px;
  background: var(--accent-bg);
  color: var(--accent-dark);
  font-weight: 600;
}

.new-events .icon {
  transform: rotate(90deg);
}

.table-frame {
  position: relative;
  min-height: 210px;
  overflow-x: auto;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface);
}

.data-table {
  width: 100%;
  min-width: 820px;
  border-collapse: collapse;
  table-layout: fixed;
}

.data-table--events { min-width: 1040px; }
.data-table--events th:nth-child(1) { width: 140px; }
.data-table--events th:nth-child(2) { width: 210px; }
.data-table--events th:nth-child(3) { width: 24%; }
.data-table--events th:nth-child(4) { width: 145px; }
.data-table--events th:nth-child(5) { width: 150px; }
.data-table--events th:nth-child(6) { width: 22%; }
.data-table--events th:nth-child(7) { width: 220px; }

.data-table--rules { min-width: 900px; }
.data-table--rules th:nth-child(1) { width: 86px; }
.data-table--rules th:nth-child(2) { width: 26%; }
.data-table--rules th:nth-child(3) { width: 23%; }
.data-table--rules th:nth-child(4) { width: 110px; }
.data-table--rules th:nth-child(5) { width: 120px; }
.data-table--rules th:nth-child(6) { width: 220px; }
.data-table--rules th:nth-child(7) { width: 104px; }

.data-table--platforms { min-width: 900px; }
.data-table--platforms th:nth-child(1) { width: 86px; }
.data-table--platforms th:nth-child(2) { width: 30%; }
.data-table--platforms th:nth-child(3) { width: 32%; }
.data-table--platforms th:nth-child(4) { width: 150px; }
.data-table--platforms th:nth-child(5) { width: 104px; }

.data-table th,
.data-table td {
  padding: 11px 13px;
  border-bottom: 1px solid var(--line);
  text-align: left;
  vertical-align: middle;
  overflow-wrap: anywhere;
}

.data-table thead th {
  position: sticky;
  z-index: 2;
  top: 0;
  height: 40px;
  padding-top: 8px;
  padding-bottom: 8px;
  background: var(--surface-muted);
  color: var(--ink-soft);
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
}

.data-table tbody tr:last-child td {
  border-bottom: 0;
}

.data-table tbody tr:hover {
  background: #f9fbfc;
}

.data-table .align-right {
  text-align: right;
}

.cell-main,
.cell-sub,
.cell-stack {
  min-width: 0;
}

.cell-stack {
  display: flex;
  flex-direction: column;
  gap: 3px;
}

.cell-main {
  color: var(--ink);
  font-weight: 600;
}

.cell-sub {
  color: var(--ink-faint);
  font-size: 11px;
}

.uuid-full-label {
  color: var(--accent-dark);
  font-weight: 600;
}

.uuid-value {
  overflow-wrap: anywhere;
  word-break: break-all;
  white-space: normal;
}

.mono {
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, "Liberation Mono", monospace;
  font-variant-numeric: tabular-nums;
}

.truncate {
  display: block;
  overflow: hidden;
  white-space: nowrap;
  text-overflow: ellipsis;
}

.badge {
  width: max-content;
  max-width: 100%;
  min-height: 24px;
  padding: 3px 8px;
  display: inline-flex;
  align-items: center;
  gap: 5px;
  border: 1px solid transparent;
  border-radius: 4px;
  font-size: 11px;
  font-weight: 700;
  white-space: nowrap;
}

.badge::before {
  content: "";
  width: 6px;
  height: 6px;
  flex: 0 0 6px;
  border-radius: 50%;
  background: currentColor;
}

.badge--high {
  border-color: #efcaca;
  background: var(--high-bg);
  color: var(--high);
}

.badge--medium {
  border-color: #efd9aa;
  background: var(--medium-bg);
  color: var(--medium);
}

.badge--online,
.badge--enabled {
  border-color: #b9ddcf;
  background: var(--online-bg);
  color: var(--online);
}

.badge--offline,
.badge--disabled {
  border-color: var(--line);
  background: var(--surface-strong);
  color: var(--ink-faint);
}

.event-time {
  display: block;
  margin-top: 5px;
  color: var(--ink-faint);
  font-size: 11px;
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}

.event-target {
  color: var(--ink);
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, "Liberation Mono", monospace;
  font-size: 12px;
}

.counter-pair {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  font-variant-numeric: tabular-nums;
}

.counter-pair .high { color: var(--high); }
.counter-pair .medium { color: var(--medium); }

.server-list {
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
}

.tag {
  max-width: 100%;
  padding: 2px 6px;
  border: 1px solid var(--line);
  border-radius: 3px;
  background: var(--surface-muted);
  color: var(--ink-soft);
  font-size: 11px;
  overflow-wrap: anywhere;
}

.row-actions {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 3px;
}

.row-actions .icon-button:hover {
  background: var(--surface-strong);
  color: var(--ink);
}

.row-actions .icon-button.is-danger:hover {
  background: var(--high-bg);
  color: var(--high);
}

.table-state {
  position: absolute;
  inset: 41px 0 0;
  min-height: 168px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 9px;
  background: rgba(255, 255, 255, 0.94);
  color: var(--ink-soft);
}

.table-state.is-error {
  color: var(--high);
}

.spinner {
  width: 16px;
  height: 16px;
  border: 2px solid var(--line-strong);
  border-top-color: var(--accent);
  border-radius: 50%;
  animation: spin 0.8s linear infinite;
}

.table-state.is-empty .spinner,
.table-state.is-error .spinner {
  display: none;
}

.table-footer {
  min-height: 32px;
  padding: 7px 3px 0;
  display: flex;
  justify-content: space-between;
  gap: 12px;
  color: var(--ink-faint);
  font-size: 11px;
}

.section-heading {
  min-height: 44px;
  margin-bottom: 12px;
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 16px;
}

.section-heading__actions {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 8px;
}

.section-heading h1,
.section-heading p {
  margin: 0;
}

.section-heading h1 {
  font-size: 18px;
  line-height: 1.3;
}

.section-heading p {
  margin-top: 3px;
  color: var(--ink-faint);
  font-size: 12px;
}

.section-heading code {
  color: var(--ink-soft);
}

.search-field--short {
  width: min(300px, 48vw);
}

.toggle-field {
  min-height: 38px;
  display: flex;
  align-items: center;
  gap: 9px;
  color: var(--ink-soft);
  cursor: pointer;
  user-select: none;
}

.toggle-field input {
  position: absolute;
  width: 1px;
  height: 1px;
  opacity: 0;
}

.toggle {
  position: relative;
  width: 34px;
  height: 19px;
  flex: 0 0 34px;
  border-radius: 10px;
  background: #abb5be;
  transition: background-color 140ms ease;
}

.toggle::after {
  content: "";
  position: absolute;
  top: 3px;
  left: 3px;
  width: 13px;
  height: 13px;
  border-radius: 50%;
  background: white;
  box-shadow: 0 1px 3px rgba(20, 30, 40, 0.24);
  transition: transform 140ms ease;
}

.toggle-field input:checked + .toggle {
  background: var(--online);
}

.toggle-field input:checked + .toggle::after {
  transform: translateX(15px);
}

.toggle-field input:focus-visible + .toggle {
  outline: 3px solid rgba(35, 103, 165, 0.24);
  outline-offset: 2px;
}

.dialog {
  width: min(92vw, 580px);
  max-height: min(88vh, 720px);
  padding: 0;
  border: 1px solid var(--line-strong);
  border-radius: 8px;
  background: var(--surface);
  color: var(--ink);
  box-shadow: var(--shadow);
  overflow: auto;
}

.dialog::backdrop {
  background: rgba(19, 29, 38, 0.56);
  backdrop-filter: blur(2px);
}

.dialog form {
  padding: 22px;
}

.dialog--auth {
  width: min(92vw, 420px);
}

.dialog--auth form {
  padding: 26px;
}

.dialog__head,
.dialog__titlebar {
  display: flex;
  align-items: flex-start;
  gap: 12px;
}

.dialog__head {
  margin-bottom: 22px;
}

.dialog__titlebar {
  margin-bottom: 20px;
  justify-content: space-between;
}

.dialog__mark {
  width: 38px;
  height: 38px;
  flex: 0 0 38px;
  display: grid;
  place-items: center;
  border-radius: 6px;
  background: var(--accent-bg);
  color: var(--accent);
}

.dialog h2,
.dialog p {
  margin: 0;
}

.dialog h2 {
  font-size: 18px;
}

.dialog__head p,
.dialog__titlebar p {
  margin-top: 3px;
  color: var(--ink-faint);
  font-size: 12px;
}

.field--stack {
  display: flex;
  flex-direction: column;
  gap: 6px;
  color: var(--ink-soft);
  font-size: 12px;
  font-weight: 600;
}

.field--stack small {
  color: var(--ink-faint);
  font-weight: 400;
}

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

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

.form-hint {
  margin: -2px 0 0;
  color: var(--ink-faint);
  font-size: 11px;
  line-height: 1.55;
}

.dialog__actions {
  margin-top: 20px;
  display: flex;
  justify-content: flex-end;
  gap: 8px;
}

.dialog__note {
  margin-top: 12px !important;
  color: var(--ink-faint);
  font-size: 11px;
  text-align: center;
}

.form-error {
  margin-top: 12px !important;
  padding: 8px 10px;
  border-left: 3px solid var(--high);
  background: var(--high-bg);
  color: var(--high);
  font-size: 12px;
}

.toast-region {
  position: fixed;
  z-index: 80;
  right: 20px;
  bottom: 20px;
  width: min(360px, calc(100vw - 32px));
  display: flex;
  flex-direction: column;
  gap: 8px;
  pointer-events: none;
}

.toast {
  min-height: 44px;
  padding: 10px 12px;
  display: flex;
  align-items: flex-start;
  gap: 9px;
  border: 1px solid var(--line-strong);
  border-left: 4px solid var(--accent);
  border-radius: 5px;
  background: var(--surface);
  box-shadow: 0 6px 20px rgba(20, 30, 40, 0.16);
  color: var(--ink);
  pointer-events: auto;
  animation: toast-in 180ms ease-out;
}

.toast.is-error { border-left-color: var(--high); }
.toast.is-success { border-left-color: var(--online); }

.toast__body {
  min-width: 0;
  flex: 1;
}

.toast__title {
  display: block;
  font-weight: 700;
}

.toast__message {
  display: block;
  margin-top: 2px;
  color: var(--ink-soft);
  font-size: 12px;
  overflow-wrap: anywhere;
}

@keyframes spin {
  to { transform: rotate(360deg); }
}

@keyframes pulse {
  50% { opacity: 0.4; }
}

@keyframes toast-in {
  from { transform: translateY(8px); opacity: 0; }
}

@media (max-width: 1080px) {
  .toolbar--events {
    display: grid;
    grid-template-columns: minmax(220px, 1fr) repeat(5, minmax(112px, 0.45fr));
  }

  .toolbar--events .search-field {
    grid-column: 1 / -2;
  }

  .toolbar__actions {
    grid-column: -2;
    grid-row: 1;
  }
}

@media (max-width: 840px) {
  main {
    padding-right: 16px;
    padding-left: 16px;
  }

  .topbar__inner {
    padding-right: 16px;
    padding-left: 16px;
  }

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

  .metric:nth-child(3) {
    border-left: 0;
  }

  .metric:nth-child(n + 3) {
    border-top: 1px solid var(--line);
  }

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

  .toolbar--events .search-field {
    grid-column: 1 / -1;
  }

  .toolbar__actions {
    grid-column: 1 / -1;
    grid-row: auto;
    margin-left: 0;
    justify-content: flex-end;
  }

  .field--compact {
    width: 100%;
    max-width: none;
  }
}

@media (max-width: 680px) {
  body {
    font-size: 13px;
  }

  .topbar {
    height: 54px;
  }

  .brand__text span {
    display: none;
  }

  .connection {
    max-width: 148px;
    overflow: hidden;
    text-overflow: ellipsis;
  }

  main {
    padding: 12px 10px 30px;
  }

  .topbar__inner {
    padding-right: 10px;
    padding-left: 10px;
  }

  .metric-band {
    min-height: 0;
  }

  .metric {
    min-height: 80px;
    padding: 12px;
    grid-template-columns: 32px minmax(0, 1fr);
    column-gap: 9px;
  }

  .metric__icon {
    width: 32px;
    height: 32px;
  }

  .metric__copy {
    flex-direction: column;
    align-items: flex-start;
    gap: 2px;
  }

  .metric__copy strong {
    font-size: 22px;
  }

  .metric__period {
    display: none;
  }

  .workspace {
    margin-top: 12px;
  }

  .tabs {
    margin-right: -10px;
    margin-left: -10px;
    padding: 0 8px;
  }

  .tab {
    padding: 0 10px;
  }

  .tab .icon {
    display: none;
  }

  .toolbar--events {
    gap: 7px;
  }

  .toolbar__actions .button {
    flex: 1;
  }

  .table-frame {
    min-height: 170px;
    overflow: visible;
    border: 0;
    border-radius: 0;
    background: transparent;
  }

  .data-table {
    min-width: 0;
    border-collapse: separate;
    border-spacing: 0 8px;
  }

  .data-table thead {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
  }

  .data-table tbody,
  .data-table tr,
  .data-table td {
    display: block;
    width: 100%;
  }

  .data-table tbody tr {
    border: 1px solid var(--line);
    border-radius: var(--radius);
    background: var(--surface);
    overflow: hidden;
  }

  .data-table tbody tr:hover {
    background: var(--surface);
  }

  .data-table td {
    min-height: 38px;
    padding: 8px 10px;
    display: grid;
    grid-template-columns: 96px minmax(0, 1fr);
    align-items: start;
    gap: 10px;
    border-bottom: 1px solid var(--line);
    text-align: left !important;
  }

  .data-table td::before {
    content: attr(data-label);
    color: var(--ink-faint);
    font-size: 11px;
    font-weight: 600;
  }

  .data-table td:last-child {
    border-bottom: 0;
  }

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

  .table-state {
    position: relative;
    inset: auto;
    min-height: 150px;
    border: 1px solid var(--line);
    border-radius: var(--radius);
  }

  .section-heading {
    align-items: center;
  }

  .section-heading__actions {
    flex-wrap: wrap;
  }

  .section-heading h1 {
    font-size: 16px;
  }

  .search-field--short {
    width: min(220px, 52vw);
  }

  .dialog form,
  .dialog--auth form {
    padding: 18px;
  }

  .form-grid {
    grid-template-columns: minmax(0, 1fr);
  }

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

  .toast-region {
    right: 10px;
    bottom: 10px;
    width: calc(100vw - 20px);
  }
}

@media (max-width: 440px) {
  .connection {
    width: 30px;
    padding: 0;
    justify-content: center;
    border: 0;
  }

  .connection span:last-child {
    position: absolute;
    width: 1px;
    height: 1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
  }

  .toolbar--events {
    grid-template-columns: minmax(0, 1fr);
  }

  .toolbar--events .search-field,
  .toolbar__actions {
    grid-column: auto;
  }

  .toolbar__actions {
    justify-content: stretch;
  }

  .section-heading {
    align-items: flex-start;
    flex-wrap: wrap;
  }

  .section-heading__actions {
    width: 100%;
    justify-content: flex-start;
  }

  .section-heading .search-field--short {
    width: 100%;
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    scroll-behavior: auto !important;
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}
