:root {
  --bg: #06101d;
  --bg-2: #0a192c;
  --surface: rgba(12, 29, 49, .78);
  --surface-2: rgba(24, 52, 78, .62);
  --border: rgba(125, 211, 252, .20);
  --purple-border: #1d3c5d;
  --text: #eef7ff;
  --muted: #8fa8bd;
  --accent: #38d5ff;
  --accent-2: #60a5fa;
  --pink: #22d3ee;
  --coral: #7dd3fc;
  --danger: #fb7185;
  --ok: #34d399;
  --warn: #fbbf24;
  --shadow: rgba(0, 0, 0, .32) 0 22px 70px;
  --inner: inset 0 1px 0 rgba(255,255,255,.06);
}

* { box-sizing: border-box; }
html {
  width: 100%;
  max-width: 100%;
  overflow-x: hidden;
  color-scheme: dark;
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
}
body {
  margin: 0;
  width: 100%;
  max-width: 100%;
  min-height: 100vh;
  font-family: 'Rubik', system-ui, -apple-system, 'Segoe UI', sans-serif;
  color: var(--text);
  background:
    radial-gradient(circle at 14% 4%, rgba(56, 213, 255, .23), transparent 30rem),
    radial-gradient(circle at 88% 0%, rgba(96, 165, 250, .18), transparent 28rem),
    radial-gradient(circle at 54% 100%, rgba(20, 184, 166, .10), transparent 34rem),
    linear-gradient(135deg, var(--bg-2), var(--bg));
  overflow-x: hidden;
}
@supports (overflow: clip) {
  html, body { overflow-x: clip; }
}

body::before {
  content: '';
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 0;
  background-image:
    linear-gradient(rgba(125,211,252,.035) 1px, transparent 1px),
    linear-gradient(90deg, rgba(125,211,252,.035) 1px, transparent 1px);
  background-size: 44px 44px;
  mask-image: linear-gradient(to bottom, rgba(0,0,0,.75), transparent 72%);
}

.orb { position: fixed; pointer-events: none; border-radius: 999px; filter: blur(12px); opacity: .62; z-index: 0; }
.orb-a { width: 15rem; height: 15rem; left: -8rem; top: 18rem; background: rgba(34, 211, 238, .12); }
.orb-b { width: 18rem; height: 18rem; right: -10rem; top: 7rem; background: rgba(96, 165, 250, .12); }

.topbar, .shell { position: relative; z-index: 1; width: min(1280px, calc(100% - 40px)); max-width: calc(100vw - 40px); min-width: 0; margin: 0 auto; }
.topbar {
  display: flex;
  justify-content: space-between;
  gap: 18px;
  align-items: flex-end;
  margin-top: 14px;
  margin-bottom: 14px;
  padding: 20px 22px;
  border: 1px solid rgba(125, 211, 252, .18);
  border-radius: 24px;
  background:
    linear-gradient(135deg, rgba(13, 36, 61, .86), rgba(7, 17, 31, .66)),
    radial-gradient(circle at 72% 0%, rgba(56, 213, 255, .16), transparent 26rem);
  box-shadow: var(--shadow), var(--inner);
  backdrop-filter: blur(20px) saturate(170%);
  overflow: hidden;
}
.topbar::after { content: ''; position: absolute; width: 20rem; height: 20rem; right: 0; top: -12rem; border-radius: 999px; background: rgba(56,213,255,.09); filter: blur(2px); }
.topbar > * { position: relative; z-index: 1; }
.eyebrow { color: var(--accent); font-size: 10px; font-weight: 700; letter-spacing: .15em; text-transform: uppercase; }
h1, h2, p { margin: 0; }
h1 { margin-top: 7px; font-size: 58px; line-height: .96; letter-spacing: 0; max-width: 660px; }
h2 { margin-top: 4px; font-size: 23px; letter-spacing: 0; }
p { color: var(--muted); margin-top: 10px; line-height: 1.55; max-width: 620px; font-size: 14px; }
.hero-meta { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 16px; }
.hero-meta span { border: 1px solid rgba(125,211,252,.17); background: rgba(3, 12, 24, .42); color: #bfefff; border-radius: 999px; padding: 7px 10px; font: 700 10px/1 'JetBrains Mono', monospace; letter-spacing: .08em; }

.primary-btn {
  border: 1px solid rgba(125, 211, 252, .32);
  color: #effaff;
  background: linear-gradient(135deg, #0f8db3, #1d4ed8);
  padding: 11px 15px;
  border-radius: 13px;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: .08em;
  text-transform: uppercase;
  box-shadow: rgba(14, 165, 233, .16) 0 1px 3px inset, rgba(0,0,0,.24) 0 10px 26px;
  cursor: pointer;
}
.primary-btn:active { transform: translateY(1px); }
.top-actions { display: flex; gap: 10px; align-items: center; }
.ghost-btn {
  border: 1px solid rgba(125, 211, 252, .22);
  color: var(--muted);
  background: rgba(8, 22, 38, .62);
  padding: 11px 14px;
  border-radius: 13px;
  font-size: 12px;
  font-weight: 700;
  cursor: pointer;
}

.shell { padding-bottom: 36px; }
.setup-hint, .summary-card, .server-card, .panel-card {
  border: 1px solid var(--border);
  background:
    linear-gradient(180deg, rgba(23, 50, 78, .78), rgba(7, 20, 35, .66)),
    radial-gradient(circle at top right, rgba(56,213,255,.06), transparent 16rem);
  backdrop-filter: blur(18px) saturate(170%);
  box-shadow: var(--shadow), var(--inner);
}
.setup-hint { display: flex; gap: 10px; flex-wrap: wrap; padding: 14px; border-radius: 17px; margin-bottom: 16px; color: var(--muted); font-size: 13px; }
.setup-hint strong { color: var(--accent); }
code { font-family: 'JetBrains Mono', monospace; color: var(--coral); }
.hidden { display: none !important; }

.summary-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 10px; min-width: 0; max-width: 100%; margin-bottom: 16px; }
.summary-card { padding: 13px; border-radius: 15px; min-height: 88px; position: relative; overflow: hidden; }
.summary-card::after { content: ''; position: absolute; inset: auto 12px 12px auto; width: 42px; height: 42px; border-radius: 14px; background: linear-gradient(135deg, rgba(56,213,255,.12), rgba(96,165,250,.04)); border: 1px solid rgba(125,211,252,.10); transform: rotate(10deg); }
.summary-card span, .metric-label { display: block; color: var(--muted); font-size: 10px; letter-spacing: .11em; text-transform: uppercase; font-weight: 700; }
.summary-card strong { display: block; margin-top: 8px; font-size: 31px; letter-spacing: 0; }
.summary-card small { color: var(--muted); font-size: 11px; }
.summary-card.hot { border-color: rgba(56,213,255,.40); background: linear-gradient(160deg, rgba(14, 165, 233, .22), rgba(12, 31, 51, .66)); }

.section-title { display: flex; justify-content: space-between; align-items: flex-end; margin: 20px 0 10px; gap: 12px; }
.section-title.compact { margin-top: 0; }
.section-title small { color: var(--muted); font-size: 11px; white-space: nowrap; }
.section-actions { display: flex; align-items: center; gap: 10px; }
.ghost-link {
  display: inline-flex;
  align-items: center;
  min-height: 30px;
  border: 1px solid rgba(125, 211, 252, .18);
  border-radius: 10px;
  padding: 0 9px;
  color: var(--muted);
  background: rgba(8, 22, 38, .48);
  font-size: 11px;
  font-weight: 700;
  text-decoration: none;
}
.ghost-link:hover { color: #effaff; border-color: rgba(125, 211, 252, .32); }
.server-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 9px; min-width: 0; max-width: 100%; }
.server-card { border-radius: 16px; padding: 11px; position: relative; overflow: hidden; transition: transform .18s ease, border-color .18s ease, background .18s ease; }
.server-card:hover { transform: translateY(-2px); border-color: rgba(56,213,255,.36); }
.server-card::after { content: ''; position: absolute; inset: auto -32% -42% 34%; height: 8rem; background: rgba(56,213,255,.08); transform: rotate(-14deg); }
.server-head { position: relative; z-index: 1; display: flex; justify-content: space-between; gap: 8px; }
.server-name { font-size: 15px; font-weight: 700; letter-spacing: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.badge { display: inline-flex; align-items: center; gap: 6px; padding: 5px 8px; border-radius: 999px; font-size: 10px; font-weight: 700; background: rgba(148, 163, 184, .13); color: var(--muted); white-space: nowrap; }
.badge::before { content: ''; width: 7px; height: 7px; border-radius: 999px; background: currentColor; }
.badge.ok { color: var(--ok); }
.badge.bad { color: var(--danger); }
.server-note { color: var(--muted); font-size: 11px; margin-top: 3px; min-height: 15px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.metrics { position: relative; z-index: 1; display: grid; grid-template-columns: repeat(3, 1fr); gap: 5px; margin-top: 8px; }
.metric { background: rgba(5, 16, 28, .54); border: 1px solid rgba(125,211,252,.12); border-radius: 9px; padding: 6px; box-shadow: inset 0 1px 0 rgba(255,255,255,.035); }
.metric-value { display: block; margin-top: 3px; font-size: 14px; font-weight: 700; }
.progress { height: 4px; margin-top: 7px; border-radius: 999px; overflow: hidden; background: rgba(148,163,184,.16); }
.progress i { display: block; height: 100%; border-radius: inherit; background: linear-gradient(90deg, var(--accent), var(--accent-2)); width: 0%; }
.server-footer { position: relative; z-index: 1; display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 5px; margin-top: 7px; }
.kv { min-width: 0; padding: 6px; border-radius: 9px; background: rgba(148, 163, 184, .08); color: var(--muted); font-size: 10px; }
.kv strong { display: block; color: var(--text); margin-top: 3px; font-family: 'JetBrains Mono', monospace; font-size: 10px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.error { color: var(--danger); margin-top: 12px; line-height: 1.45; font-size: 12px; }

.dashboard-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(300px, 340px);
  grid-template-areas:
    "main online"
    "main side";
  gap: 14px;
  width: 100%;
  min-width: 0;
  max-width: 100%;
  margin-top: 14px;
  align-items: start;
}
.dashboard-main { grid-area: main; }
.online-panel { grid-area: online; }
.dashboard-side { grid-area: side; }
.dashboard-main, .dashboard-side { display: grid; gap: 14px; align-content: start; min-width: 0; max-width: 100%; }
.panel-card { width: 100%; max-width: 100%; border-radius: 19px; padding: 14px; align-self: start; min-width: 0; }
.panel-card .section-title h2 { color: #f6fbff; }
.client-row, .alert-row { display: grid; grid-template-columns: 1fr auto; gap: 10px; align-items: center; padding: 10px 0; border-top: 1px solid rgba(125,211,252,.10); }
.client-row { width: 100%; color: inherit; font: inherit; text-align: left; border-right: 0; border-bottom: 0; border-left: 0; background: transparent; cursor: pointer; }
.client-row:hover { background: rgba(56, 213, 255, .045); }
.client-row:focus-visible { outline: 2px solid rgba(56, 213, 255, .58); outline-offset: 3px; border-radius: 10px; }
.client-row:first-child, .alert-row:first-child { border-top: 0; }
.client-row.disabled { opacity: .62; }
.panel-note { margin: -4px 0 10px; font-size: 12px; line-height: 1.55; }
.logs-list { max-height: 420px; overflow: auto; padding-right: 4px; }
.access-panel .logs-list { max-height: 360px; }
.compact-logs { max-height: 340px; }
.online-users-list { display: grid; gap: 8px; max-height: 320px; overflow: auto; padding-right: 4px; }
.online-user-row {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  gap: 9px;
  align-items: center;
  width: 100%;
  min-width: 0;
  padding: 9px;
  border: 1px solid rgba(52, 211, 153, .16);
  border-radius: 12px;
  background: linear-gradient(135deg, rgba(52, 211, 153, .10), rgba(56,213,255,.04));
}
.online-dot { width: 8px; height: 8px; border-radius: 999px; background: var(--muted); box-shadow: 0 0 0 4px rgba(148, 163, 184, .08); }
.online-dot.ok { background: var(--ok); box-shadow: 0 0 0 4px rgba(52, 211, 153, .10); }
.online-dot.bad { background: var(--danger); box-shadow: 0 0 0 4px rgba(251, 113, 133, .10); }
.online-user-row strong { display: block; color: #eafff7; font-size: 13px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.online-user-row span { display: block; color: var(--muted); font-size: 11px; margin-top: 3px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.online-user-row em { font-style: normal; color: var(--accent); font-family: 'JetBrains Mono', monospace; font-size: 11px; white-space: nowrap; }
.domain-monitor-list { max-height: 460px; overflow: auto; padding-right: 4px; }
.log-row { padding: 10px 0; border-top: 1px solid rgba(125,211,252,.10); }
.log-row:first-child { border-top: 0; }
.log-row div { display: flex; justify-content: space-between; gap: 9px; align-items: baseline; }
.log-row strong { color: var(--accent); }
.log-row.error strong { color: var(--danger); }
.log-row.warn strong { color: var(--warn); }
.log-row span { color: var(--muted); font-size: 11px; white-space: nowrap; }
.log-row code { display: block; margin-top: 5px; color: #cde8f6; white-space: normal; overflow-wrap: anywhere; line-height: 1.5; font-size: 11px; }
.log-row.access strong { color: var(--ok); }
.client-main strong { display: block; font-size: 13px; }
.client-main span, .alert-row span { display: block; color: var(--muted); margin-top: 3px; font-size: 12px; }
.client-traffic { text-align: right; font-family: 'JetBrains Mono', monospace; color: var(--accent); font-size: 12px; }
.alert-row.good strong { color: var(--ok); }
.alert-row.warn strong { color: var(--warn); }
.alert-row.bad strong { color: var(--danger); }
.empty { color: var(--muted); padding: 16px 0; line-height: 1.55; font-size: 13px; }
.empty.small { font-size: 11px; padding: 10px 0 0; }
.history-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 8px; }
.trend-card { background: rgba(5, 16, 28, .48); border: 1px solid rgba(125,211,252,.10); border-radius: 13px; padding: 9px; min-width: 0; }
.trend-card div { display: flex; justify-content: space-between; gap: 8px; align-items: baseline; }
.trend-card span { color: var(--muted); font-size: 10px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; }
.trend-card strong { font-family: 'JetBrains Mono', monospace; font-size: 14px; color: var(--text); }
.trend-card svg { display: block; width: 100%; height: 58px; margin-top: 8px; }
.trend-card polyline { fill: none; stroke: var(--accent); stroke-width: 4; stroke-linecap: round; stroke-linejoin: round; filter: drop-shadow(0 0 6px rgba(56,213,255,.28)); }
.status-row { display: flex; justify-content: space-between; gap: 10px; padding: 9px 0; border-top: 1px solid rgba(125,211,252,.10); color: var(--muted); font-size: 12px; }
.status-row:first-child { border-top: 0; }
.status-row strong { color: var(--text); font-family: 'JetBrains Mono', monospace; }
.access-tabs { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 6px; margin: 2px 0 10px; padding: 4px; border: 1px solid rgba(125,211,252,.10); border-radius: 13px; background: rgba(5,16,28,.36); }
.access-tab { min-width: 0; border: 0; border-radius: 9px; background: transparent; color: var(--muted); padding: 8px 6px; font-size: 11px; font-weight: 700; cursor: pointer; }
.access-tab.active { color: #effaff; background: linear-gradient(135deg, rgba(14,165,233,.32), rgba(29,78,216,.25)); box-shadow: inset 0 1px 0 rgba(255,255,255,.08); }
.inline-section-title { margin: 10px 0 4px; color: var(--muted); font-size: 10px; font-weight: 700; letter-spacing: .12em; text-transform: uppercase; }
.access-user-bar { display: flex; justify-content: space-between; align-items: center; gap: 10px; margin: -2px 0 10px; }
.access-user-bar .inline-section-title { flex: 0 0 auto; margin: 0; }
.access-user-filters { display: flex; justify-content: flex-end; gap: 6px; min-width: 0; overflow-x: auto; overscroll-behavior-x: contain; scrollbar-width: none; }
.access-user-filters::-webkit-scrollbar { display: none; }
.access-user-filter { flex: 0 0 auto; border: 1px solid rgba(125,211,252,.12); border-radius: 999px; background: rgba(5,16,28,.44); color: var(--muted); padding: 7px 9px; font-size: 10px; font-weight: 700; cursor: pointer; white-space: nowrap; }
.access-user-filter.active { color: #eafff7; border-color: rgba(52,211,153,.30); background: rgba(52,211,153,.13); }
.domain-rank { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; margin-bottom: 10px; }
.access-rank { min-height: 120px; }
.domain-pill { display: grid; grid-template-columns: auto minmax(0, 1fr); gap: 8px; align-items: center; border: 1px solid rgba(52, 211, 153, .18); background: linear-gradient(135deg, rgba(52, 211, 153, .10), rgba(56,213,255,.045)); border-radius: 12px; padding: 8px; min-width: 0; }
.rank-index { display: grid; place-items: center; width: 24px; height: 24px; border-radius: 8px; background: rgba(52,211,153,.12); color: var(--ok); font-family: 'JetBrains Mono', monospace; font-size: 11px; font-weight: 700; }
.domain-pill strong { display: block; color: var(--ok); font-size: 12px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.domain-pill span { display: block; color: var(--muted); font-size: 10px; margin-top: 3px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.domain-row { display: flex; justify-content: space-between; align-items: center; gap: 12px; padding: 10px 0; border-top: 1px solid rgba(125,211,252,.10); }
.domain-row:first-child { border-top: 0; }
.domain-row strong { display: block; font-size: 13px; }
.domain-row span { display: block; color: var(--muted); font-size: 11px; margin-top: 3px; }
.domain-row em { font-style: normal; font-family: 'JetBrains Mono', monospace; font-size: 11px; color: var(--muted); text-align: right; }
.domain-row.good strong { color: var(--ok); }
.domain-row.warn strong { color: var(--warn); }
.domain-row.bad strong { color: var(--danger); }
.login-body { display: grid; place-items: center; padding: 18px; }
.login-shell { width: min(420px, 100%); position: relative; z-index: 1; }
.login-card { border: 1px solid var(--border); background: linear-gradient(180deg, rgba(22, 47, 72, .84), rgba(9, 23, 39, .72)); backdrop-filter: blur(18px) saturate(170%); box-shadow: var(--shadow); border-radius: 26px; padding: 24px; }
.login-card h1 { font-size: 34px; margin-top: 8px; }
.login-form { margin-top: 18px; display: grid; gap: 13px; }
.login-form label { color: var(--muted); font-size: 12px; font-weight: 700; letter-spacing: .08em; }
.login-form input { width: 100%; margin-top: 7px; border: 1px solid rgba(125,211,252,.18); border-radius: 13px; background: rgba(5,16,28,.62); color: var(--text); padding: 12px; outline: none; }
.login-form input:focus { border-color: rgba(56,213,255,.58); box-shadow: 0 0 0 3px rgba(56,213,255,.10); }
.login-msg { min-height: 18px; color: var(--danger); font-size: 12px; }

@media (max-width: 1180px) {
  .topbar, .shell { width: min(100% - 32px, 1180px); max-width: calc(100vw - 32px); }
  .dashboard-layout { grid-template-columns: minmax(0, 1fr) minmax(280px, 320px); }
  .history-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

@media (max-width: 920px) {
  .topbar { align-items: stretch; flex-direction: column; padding-top: 22px; gap: 14px; }
  .primary-btn, .top-actions { width: 100%; }
  .top-actions { display: grid; grid-template-columns: 1fr auto; }
  .summary-grid { grid-template-columns: repeat(4, minmax(0, 1fr)); }
  .server-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; }
  .server-card { padding: 10px; }
  .server-footer { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .dashboard-layout {
    grid-template-columns: minmax(0, 1fr);
    grid-template-areas:
      "online"
      "main"
      "side";
  }
  .dashboard-side { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .dashboard-side .panel-card { height: auto; }
  .history-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

@media (max-width: 760px) {
  .summary-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .server-grid {
    display: flex;
    grid-template-columns: none;
    gap: 10px;
    max-width: 100%;
    overflow-x: auto;
    overflow-y: hidden;
    overscroll-behavior-x: contain;
    -webkit-overflow-scrolling: touch;
    contain: paint;
    scroll-snap-type: x mandatory;
    scrollbar-width: none;
    padding-bottom: 4px;
  }
  .server-grid::-webkit-scrollbar { display: none; }
  .server-card { flex: 0 0 min(340px, calc(100vw - 42px)); scroll-snap-align: start; }
  .server-card:hover { transform: none; }
  .dashboard-side { grid-template-columns: 1fr; }
}

@media (max-width: 560px) {
  .topbar, .shell { width: calc(100% - 20px); max-width: calc(100vw - 20px); }
  .shell { overflow-x: clip; }
  .topbar {
    margin-top: 10px;
    margin-bottom: 14px;
    padding: 18px;
    border-radius: 22px;
    gap: 14px;
    box-shadow: rgba(0,0,0,.26) 0 16px 42px, var(--inner);
  }
  .orb { display: none; }
  .topbar::after { width: 12rem; height: 12rem; right: 0; top: -7rem; opacity: .72; }
  h1 { font-size: 38px; letter-spacing: 0; }
  h2 { font-size: 18px; }
  p { font-size: 12px; margin-top: 8px; line-height: 1.45; }
  .eyebrow { font-size: 9px; }
  .hero-meta { gap: 6px; margin-top: 12px; }
  .hero-meta span { padding: 6px 8px; font-size: 9px; }
  .top-actions { grid-template-columns: minmax(0, 1fr) 72px; gap: 8px; }
  .primary-btn, .ghost-btn { min-height: 42px; border-radius: 14px; }
  .primary-btn { padding: 10px 12px; }
  .ghost-btn { padding: 10px 12px; color: #a8bdcf; background: rgba(255,255,255,.045); }

  .summary-grid {
    grid-template-columns: repeat(4, minmax(84px, 1fr));
    max-width: 100%;
    overflow-x: auto;
    overflow-y: hidden;
    gap: 7px;
    margin-bottom: 14px;
    padding-bottom: 4px;
    overscroll-behavior-x: contain;
    -webkit-overflow-scrolling: touch;
    contain: paint;
    scroll-snap-type: x proximity;
    scrollbar-width: none;
  }
  .summary-grid::-webkit-scrollbar { display: none; }
  .summary-card { min-width: 84px; min-height: 66px; padding: 9px; border-radius: 14px; scroll-snap-align: start; }
  .summary-card::after { display: none; }
  .summary-card span { font-size: 9px; letter-spacing: .06em; white-space: nowrap; }
  .summary-card strong { font-size: 18px; margin-top: 5px; white-space: nowrap; }
  .summary-card small { display: block; font-size: 9px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }

  .section-title { margin: 16px 0 9px; }
  .section-title.compact { align-items: flex-start; }
  .section-actions { flex-wrap: wrap; justify-content: flex-end; gap: 7px; }
  .server-grid {
    display: flex;
    grid-template-columns: none;
    gap: 10px;
    max-width: 100%;
    overflow-x: auto;
    overflow-y: hidden;
    overscroll-behavior-x: contain;
    -webkit-overflow-scrolling: touch;
    contain: paint;
    scroll-snap-type: x mandatory;
    scrollbar-width: none;
    padding: 0 0 4px;
    margin-right: 0;
  }
  .server-card { width: auto; min-width: 0; flex: 0 0 min(340px, calc(100vw - 42px)); border-radius: 20px; padding: 13px; scroll-snap-align: start; }
  .server-card:hover { transform: none; }
  .server-name { font-size: 16px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
  .server-note { font-size: 11px; min-height: 14px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
  .badge { padding: 6px 8px; font-size: 10px; }
  .metrics { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 7px; margin-top: 10px; }
  .metric { min-width: 0; padding: 8px; border-radius: 12px; background: rgba(255,255,255,.045); border-color: rgba(255,255,255,.07); box-shadow: none; }
  .metric-value { font-size: 15px; }
  .server-footer { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 7px; margin-top: 8px; }
  .kv { min-width: 0; padding: 8px; border-radius: 12px; background: rgba(255,255,255,.04); border: 1px solid rgba(255,255,255,.055); font-size: 10px; }
  .kv strong { font-size: 10px; overflow-wrap: anywhere; }
  .dashboard-layout {
    display: grid;
    grid-template-columns: minmax(0, 1fr);
    grid-template-areas:
      "online"
      "main"
      "side";
    gap: 10px;
    align-items: stretch;
  }
  .dashboard-main, .dashboard-side { display: grid; width: 100%; gap: 10px; }
  .dashboard-side { grid-template-columns: 1fr; }
  .panel-card { border-radius: 20px; padding: 13px; }
  .client-row, .alert-row { padding: 8px 0; }
  .client-main strong { font-size: 12px; }
  .client-main span, .alert-row span { font-size: 11px; }
  .client-traffic { font-size: 11px; }
  .log-row div { display: block; }
  .log-row span { display: block; margin-top: 4px; white-space: normal; }
  .log-row code { font-size: 10px; }
  .history-grid { grid-template-columns: 1fr 1fr; gap: 7px; }
  .trend-card { padding: 8px; border-radius: 12px; }
  .trend-card svg { height: 54px; }
  .access-tabs { gap: 4px; padding: 3px; border-radius: 12px; }
  .access-tab { padding: 7px 4px; font-size: 10px; }
  .access-user-bar { display: block; margin-bottom: 9px; }
  .access-user-filters { justify-content: flex-start; margin-top: 7px; }
  .access-user-filter { padding: 7px 8px; }
  .domain-rank { grid-template-columns: 1fr; gap: 6px; }
  .logs-list, .access-panel .logs-list, .compact-logs, .online-users-list, .domain-monitor-list { max-height: none; overflow: visible; padding-right: 0; }
}
