:root {
  --bg: #0d0f16;
  --surface: #161923;
  --surface-2: #1e2230;
  --surface-3: #262b3d;
  --border: rgba(255, 255, 255, 0.08);
  --border-soft: rgba(255, 255, 255, 0.05);
  --text: #eef0f6;
  --text-dim: #9aa1b5;
  --text-faint: #6b7286;
  --accent: #5865f2;
  --accent-hover: #6f7bf5;
  --accent-soft: rgba(88, 101, 242, 0.15);
  --success: #57f287;
  --danger: #ed4245;
  --danger-soft: rgba(237, 66, 69, 0.15);
  --warning: #f5a623;
  --radius-lg: 22px;
  --radius-md: 16px;
  --radius-sm: 11px;
  --shadow: 0 8px 30px rgba(0, 0, 0, 0.35);
}

* { box-sizing: border-box; }

body {
  margin: 0;
  font-family: "Inter", -apple-system, BlinkMacSystemFont, sans-serif;
  background: radial-gradient(circle at 15% 0%, #171b2b 0%, var(--bg) 45%);
  color: var(--text);
  min-height: 100vh;
}

#app { min-height: 100vh; display: flex; flex-direction: column; }

.loading-screen, .center-screen {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
}

.spinner {
  width: 36px; height: 36px;
  border-radius: 50%;
  border: 3px solid var(--border);
  border-top-color: var(--accent);
  animation: spin 0.8s linear infinite;
}
@keyframes spin { to { transform: rotate(360deg); } }

/* ---------------- Login screen ---------------- */
.login-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow);
  padding: 48px 44px;
  text-align: center;
  max-width: 380px;
}
.login-card .logo {
  width: 56px; height: 56px;
  border-radius: 18px;
  background: linear-gradient(135deg, var(--accent), #8b5cf6);
  display: flex; align-items: center; justify-content: center;
  font-size: 26px;
  margin: 0 auto 20px;
}
.login-card h1 { font-size: 22px; margin: 0 0 8px; font-weight: 700; }
.login-card p { color: var(--text-dim); font-size: 14px; margin: 0 0 28px; line-height: 1.5; }

/* ---------------- Buttons ---------------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  border: none; border-radius: var(--radius-sm);
  padding: 11px 20px;
  font-family: inherit; font-size: 14px; font-weight: 600;
  cursor: pointer; transition: all 0.15s ease;
  text-decoration: none;
}
.btn-primary { background: var(--accent); color: white; }
.btn-primary:hover { background: var(--accent-hover); transform: translateY(-1px); }
.btn-secondary { background: var(--surface-3); color: var(--text); }
.btn-secondary:hover { background: #303650; }
.btn-danger { background: var(--danger-soft); color: #ff8183; }
.btn-danger:hover { background: rgba(237, 66, 69, 0.28); }
.btn-ghost { background: transparent; color: var(--text-dim); }
.btn-ghost:hover { background: var(--surface-2); color: var(--text); }
.btn-block { width: 100%; }
.btn:disabled { opacity: 0.5; cursor: not-allowed; transform: none; }
.btn-sm { padding: 7px 14px; font-size: 13px; }

/* ---------------- Topbar ---------------- */
.topbar {
  display: flex; align-items: center; justify-content: space-between;
  padding: 16px 28px;
  border-bottom: 1px solid var(--border-soft);
  position: sticky; top: 0;
  background: rgba(13, 15, 22, 0.85);
  backdrop-filter: blur(10px);
  z-index: 10;
}
.topbar-left { display: flex; align-items: center; gap: 14px; }
.brand { display: flex; align-items: center; gap: 10px; font-weight: 800; font-size: 16px; text-decoration: none; color: var(--text); }
.brand .logo-sm {
  width: 30px; height: 30px; border-radius: 9px;
  background: linear-gradient(135deg, var(--accent), #8b5cf6);
  display: flex; align-items: center; justify-content: center; font-size: 15px;
}
.crumb-sep { color: var(--text-faint); }
.guild-chip { display: flex; align-items: center; gap: 8px; font-weight: 600; font-size: 15px; }
.guild-chip img { width: 26px; height: 26px; border-radius: 8px; object-fit: cover; }
.topbar-right { display: flex; align-items: center; gap: 14px; }
.user-chip { display: flex; align-items: center; gap: 10px; font-size: 14px; color: var(--text-dim); }
.user-chip img { width: 28px; height: 28px; border-radius: 50%; }

/* ---------------- Layout ---------------- */
.page { max-width: 980px; margin: 0 auto; padding: 32px 24px 80px; width: 100%; flex: 1; }
.page-header { display: flex; align-items: center; justify-content: space-between; margin-bottom: 24px; flex-wrap: wrap; gap: 12px; }
.page-header h1 { font-size: 22px; margin: 0; font-weight: 800; }
.page-header p { color: var(--text-dim); font-size: 14px; margin: 4px 0 0; }

/* ---------------- Guild picker ---------------- */
.guild-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  gap: 16px;
}
.guild-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  padding: 20px;
  display: flex; flex-direction: column; align-items: center; gap: 12px;
  text-align: center; cursor: pointer;
  transition: all 0.15s ease;
  text-decoration: none; color: var(--text);
}
.guild-card:hover { border-color: var(--accent); transform: translateY(-2px); box-shadow: var(--shadow); }
.guild-card img, .guild-card .fallback-icon {
  width: 64px; height: 64px; border-radius: 18px; object-fit: cover;
}
.guild-card .fallback-icon {
  display: flex; align-items: center; justify-content: center;
  background: var(--surface-3); font-weight: 700; font-size: 22px;
}
.guild-card .name { font-weight: 600; font-size: 14px; }
.empty-state {
  text-align: center; padding: 60px 20px; color: var(--text-dim);
  background: var(--surface); border-radius: var(--radius-lg); border: 1px solid var(--border);
}

/* ---------------- Tabs ---------------- */
.tabs { display: flex; gap: 6px; border-bottom: 1px solid var(--border-soft); margin-bottom: 24px; }
.tab {
  padding: 10px 18px; font-size: 14px; font-weight: 600; color: var(--text-dim);
  cursor: pointer; border-radius: var(--radius-sm) var(--radius-sm) 0 0;
  border-bottom: 2px solid transparent; transition: all 0.15s ease;
}
.tab:hover { color: var(--text); }
.tab.active { color: var(--text); border-bottom-color: var(--accent); }

/* ---------------- Cards ---------------- */
.card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 24px;
}
.status-list { display: flex; flex-direction: column; gap: 12px; }
.status-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-left: 4px solid var(--surface-3);
  border-radius: var(--radius-md);
  padding: 16px 18px;
  display: flex; align-items: center; justify-content: space-between; gap: 16px; flex-wrap: wrap;
}
.status-card .info { display: flex; flex-direction: column; gap: 4px; min-width: 0; }
.status-card .info .name { font-weight: 700; font-size: 15px; }
.status-card .info .meta { font-size: 12.5px; color: var(--text-dim); display: flex; gap: 10px; flex-wrap: wrap; }
.status-card .actions { display: flex; gap: 8px; flex-shrink: 0; }
.status-card.online { border-left-color: var(--success); }
.status-card.offline { border-left-color: var(--danger); }
.status-card.restarting { border-left-color: var(--warning); }
.pill {
  display: inline-flex; align-items: center; gap: 5px;
  padding: 3px 9px; border-radius: 999px; font-size: 11.5px; font-weight: 700;
  background: var(--surface-3); color: var(--text-dim);
}
.pill.online { background: rgba(87, 242, 135, 0.15); color: var(--success); }
.pill.offline { background: var(--danger-soft); color: #ff8183; }
.pill.restarting { background: rgba(245, 166, 35, 0.15); color: var(--warning); }

/* ---------------- Forms ---------------- */
.field { margin-bottom: 16px; }
.field label { display: block; font-size: 13px; font-weight: 600; margin-bottom: 6px; color: var(--text-dim); }
.field .hint { font-size: 12px; color: var(--text-faint); margin-top: 5px; }
input[type="text"], input[type="url"], select, textarea {
  width: 100%; background: var(--surface-2); border: 1px solid var(--border);
  color: var(--text); border-radius: var(--radius-sm); padding: 10px 13px;
  font-family: inherit; font-size: 14px; transition: border-color 0.15s ease;
}
input:focus, select:focus, textarea:focus { outline: none; border-color: var(--accent); }
.field-row { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
@media (max-width: 560px) { .field-row { grid-template-columns: 1fr; } }

.button-rows { display: flex; flex-direction: column; gap: 10px; }
.button-row { display: grid; grid-template-columns: 1fr 1.4fr auto; gap: 8px; align-items: center; }
@media (max-width: 560px) { .button-row { grid-template-columns: 1fr; } }
.icon-btn {
  width: 34px; height: 34px; border-radius: var(--radius-sm); border: 1px solid var(--border);
  background: var(--surface-2); color: var(--text-dim); cursor: pointer; font-size: 16px;
  display: flex; align-items: center; justify-content: center; flex-shrink: 0;
}
.icon-btn:hover { background: var(--surface-3); color: var(--text); }

/* ---------------- Modal ---------------- */
.modal-backdrop {
  position: fixed; inset: 0; background: rgba(5, 6, 10, 0.65);
  display: flex; align-items: center; justify-content: center; padding: 20px;
  z-index: 100; backdrop-filter: blur(2px);
}
.modal {
  background: var(--surface); border: 1px solid var(--border);
  border-radius: var(--radius-lg); box-shadow: var(--shadow);
  padding: 28px; width: 100%; max-width: 560px;
  max-height: 88vh; overflow-y: auto;
}
.modal h2 { margin: 0 0 20px; font-size: 18px; font-weight: 800; }
.modal-actions { display: flex; justify-content: flex-end; gap: 10px; margin-top: 22px; }

/* ---------------- Profile ---------------- */
.profile-preview { display: flex; align-items: center; gap: 16px; margin-bottom: 24px; }
.profile-preview .avatar-preview {
  width: 72px; height: 72px; border-radius: 50%; object-fit: cover;
  border: 1px solid var(--border); background: var(--surface-2);
}
.profile-preview .avatar-fallback {
  width: 72px; height: 72px; border-radius: 50%; background: var(--surface-3);
  display: flex; align-items: center; justify-content: center; font-size: 24px; color: var(--text-faint);
}

/* ---------------- Toast / banner ---------------- */
.banner {
  border-radius: var(--radius-sm); padding: 12px 16px; font-size: 13.5px; margin-bottom: 18px;
  border: 1px solid var(--border);
}
.banner.error { background: var(--danger-soft); color: #ff9d9e; border-color: rgba(237,66,69,0.3); }
.banner.success { background: rgba(87, 242, 135, 0.12); color: #8ff5b0; border-color: rgba(87,242,135,0.3); }

.toast-stack { position: fixed; bottom: 20px; right: 20px; display: flex; flex-direction: column; gap: 10px; z-index: 200; }
.toast {
  background: var(--surface-3); border: 1px solid var(--border); border-radius: var(--radius-sm);
  padding: 12px 16px; font-size: 13.5px; box-shadow: var(--shadow); max-width: 320px;
  animation: toast-in 0.2s ease;
}
.toast.error { border-color: rgba(237,66,69,0.4); color: #ff9d9e; }
.toast.success { border-color: rgba(87,242,135,0.4); color: #8ff5b0; }
@keyframes toast-in { from { opacity: 0; transform: translateY(6px); } to { opacity: 1; transform: translateY(0); } }

/* logo images inside the gradient tiles */
.login-card .logo img, .brand .logo-sm img { width: 68%; height: 68%; object-fit: contain; display: block; }

/* ======================= Server picker: add / locked servers ======================= */
.guild-card.disabled { cursor: default; }
.guild-card.disabled img, .guild-card.disabled .fallback-icon, .guild-card.disabled .name { opacity: .5; filter: grayscale(1); transition: all .15s ease; }
.guild-card.disabled:hover { transform: none; box-shadow: none; border-color: var(--border); }
a.guild-card.disabled { cursor: pointer; }
a.guild-card.disabled:hover { border-color: var(--accent); }
a.guild-card.disabled:hover img, a.guild-card.disabled:hover .fallback-icon, a.guild-card.disabled:hover .name { opacity: 1; filter: none; }
.guild-card .add-label { margin-top: 2px; font-size: 12px; font-weight: 700; color: #fff; background: var(--accent); padding: 6px 13px; border-radius: 999px; }
.guild-card.locked .add-label { background: var(--surface-3); color: var(--text-dim); }

/* ======================= Status cards ======================= */
.status-card.clickable { cursor: pointer; transition: background .15s ease; }
.status-card.clickable:hover { background: var(--surface-2); }
.status-card .info .name .pill { margin-left: 10px; vertical-align: middle; }

/* ======================= Status dashboard ======================= */
.page.page-wide { max-width: 1180px; }
.page-wide > .card { margin-bottom: 18px; }
.page-header h1 .pill { font-size: 12px; margin-left: 8px; vertical-align: middle; }
.page-header code { background: var(--surface-2); padding: 2px 7px; border-radius: 6px; font-size: 12px; color: var(--text); }
.head-actions { display: flex; align-items: center; gap: 14px; }
.crumb-current { font-weight: 600; font-size: 15px; }
a.guild-chip { color: inherit; text-decoration: none; }
.muted { color: var(--text-dim); font-size: 13px; margin: 0; }
.card h2 { font-size: 15px; font-weight: 700; margin: 0; }
.card .sub { color: var(--text-faint); font-size: 12px; margin: 3px 0 0; }
.card-title { display: flex; align-items: center; gap: 12px; margin-bottom: 14px; flex-wrap: wrap; }
.count-badge { background: var(--accent-soft); color: #aab3ff; font-size: 12px; font-weight: 700; padding: 2px 9px; border-radius: 999px; }

.live { display: inline-flex; align-items: center; gap: 7px; font-size: 12px; font-weight: 700; color: var(--success); }
.live i { width: 8px; height: 8px; border-radius: 50%; background: var(--success); animation: livePulse 1.8s ease-out infinite; }
@keyframes livePulse { 0% { box-shadow: 0 0 0 0 rgba(87,242,135,.55); } 100% { box-shadow: 0 0 0 9px rgba(87,242,135,0); } }

.sd-hero { display: grid; grid-template-columns: minmax(0, 1fr) 300px; gap: 18px; margin-bottom: 18px; align-items: stretch; }
@media (max-width: 920px) { .sd-hero { grid-template-columns: 1fr; } }

.chart-card { padding: 20px 20px 14px; background: radial-gradient(120% 90% at 50% 0%, rgba(88,101,242,.10), transparent 60%), var(--surface); }
.chart-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 12px; margin-bottom: 8px; }
.seg { display: inline-flex; background: var(--surface-2); border-radius: 10px; padding: 3px; gap: 2px; }
.seg button { background: none; border: 0; color: var(--text-dim); font: inherit; font-size: 12px; font-weight: 700; padding: 5px 13px; border-radius: 8px; cursor: pointer; }
.seg button.active { background: var(--accent); color: #fff; }
.chart-wrap { position: relative; min-height: 300px; }
.chart-foot { color: var(--text-faint); font-size: 11.5px; margin-top: 6px; }
.chart-empty { height: 300px; display: flex; align-items: center; justify-content: center; text-align: center; color: var(--text-dim); font-size: 13px; padding: 0 30px; }

.glow-chart { width: 100%; height: auto; display: block; overflow: visible; }
.glow-chart .g { stroke: rgba(255,255,255,.06); stroke-width: 1; }
.glow-chart .ax { fill: var(--text-faint); font-size: 10.5px; }
.glow-chart .pt { fill: #a5b4ff; }
.glow-chart .halo { opacity: .7; animation: breathe 3.4s ease-in-out infinite; }
.glow-chart .core { fill: #fff; }
.glow-chart .ring { fill: none; stroke: #22d3ee; stroke-width: 1.5; transform-box: fill-box; transform-origin: center; animation: ring 2.2s ease-out infinite; }
.glow-chart .hover .hl { stroke: rgba(255,255,255,.22); stroke-width: 1; stroke-dasharray: 3 3; }
.glow-chart .hover .hd { fill: #fff; }
/* draw-in on first load / range change */
.glow-chart.anim .ln, .glow-chart.anim .halo { stroke-dasharray: 1; stroke-dashoffset: 1; }
.glow-chart.anim .ln { animation: draw 1.8s cubic-bezier(.4,0,.2,1) forwards; }
.glow-chart.anim .halo { animation: draw 1.8s cubic-bezier(.4,0,.2,1) forwards, breathe 3.4s ease-in-out 1.8s infinite; }
.glow-chart.anim .area { opacity: 0; animation: fadeIn 1.2s ease .8s forwards; }
.glow-chart.anim .last { opacity: 0; animation: fadeIn .5s ease 1.7s forwards; }
@keyframes draw { to { stroke-dashoffset: 0; } }
@keyframes fadeIn { to { opacity: 1; } }
@keyframes breathe { 0%, 100% { opacity: .45; } 50% { opacity: .95; } }
@keyframes ring { 0% { transform: scale(1); opacity: .9; } 100% { transform: scale(3.6); opacity: 0; } }
@media (prefers-reduced-motion: reduce) {
  .glow-chart *, .live i { animation: none !important; }
  .glow-chart.anim .ln, .glow-chart.anim .halo { stroke-dashoffset: 0; }
  .glow-chart.anim .area, .glow-chart.anim .last { opacity: 1; }
}
.chart-tip {
  position: absolute; transform: translate(-50%, -135%); pointer-events: none; white-space: nowrap;
  background: rgba(20,22,32,.95); border: 1px solid var(--border); border-radius: 10px; padding: 7px 11px;
  font-size: 12px; box-shadow: 0 6px 24px rgba(0,0,0,.45); color: var(--text-dim);
}
.chart-tip b { color: var(--text); }
.chart-tip span { display: block; color: var(--text-faint); font-size: 11px; margin-top: 2px; }

/* right-hand stats */
.stat-panel { padding: 22px; display: flex; flex-direction: column; }
.stat-hero { padding-bottom: 18px; }
.stat-label { font-size: 12px; font-weight: 600; color: var(--text-dim); letter-spacing: .02em; }
.stat-big { font-size: 46px; font-weight: 800; line-height: 1.05; margin-top: 6px; text-shadow: 0 0 24px rgba(88,101,242,.55); }
.stat-big span { font-size: 17px; font-weight: 600; color: var(--text-faint); margin-left: 6px; text-shadow: none; }
.stat-bar { height: 6px; background: var(--surface-3); border-radius: 999px; margin-top: 12px; overflow: hidden; }
.stat-bar i { display: block; height: 100%; background: linear-gradient(90deg, #5865f2, #22d3ee); border-radius: 999px; box-shadow: 0 0 12px rgba(34,211,238,.6); transition: width .6s ease; }
.stat-row { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 13px 0; border-top: 1px solid var(--border-soft); }
.stat-row .stat-sub { font-size: 11px; color: var(--text-faint); margin-top: 2px; }
.stat-val { font-size: 21px; font-weight: 800; }

/* player list */
.table-wrap { max-height: 380px; overflow: auto; border-radius: var(--radius-sm); }
.ptable { width: 100%; border-collapse: collapse; font-size: 13px; }
.ptable th { text-align: left; color: var(--text-faint); font-size: 11.5px; font-weight: 600; padding: 8px 12px; position: sticky; top: 0; background: var(--surface); }
.ptable td { padding: 9px 12px; border-top: 1px solid var(--border-soft); }
.ptable .num { color: var(--text-dim); font-variant-numeric: tabular-nums; white-space: nowrap; }

/* Discord preview */
.dc { background: #313338; border-radius: 12px; padding: 18px 18px 16px; font-family: "gg sans", "Noto Sans", "Inter", system-ui, sans-serif; color: #dbdee1; }
.dc-msg { display: flex; gap: 14px; }
.dc-avatar { width: 40px; height: 40px; border-radius: 50%; object-fit: cover; flex-shrink: 0; background: #1e1f22; }
.dc-body { min-width: 0; flex: 1; max-width: 520px; }
.dc-line { display: flex; align-items: center; gap: 6px; margin-bottom: 4px; flex-wrap: wrap; }
.dc-name { font-weight: 600; color: #f2f3f5; font-size: 15px; }
.dc-tag { background: #5865f2; color: #fff; font-size: 10px; font-weight: 700; padding: 1px 5px; border-radius: 4px; }
.dc-time { color: #949ba4; font-size: 12px; margin-left: 4px; }
.dc-card { background: #2b2d31; border: 1px solid #3f4147; border-left: 4px solid #57f287; border-radius: 8px; padding: 14px 16px; }
.dc-head { display: flex; justify-content: space-between; align-items: flex-start; gap: 14px; }
.dc-head h3 { margin: 0; font-size: 20px; font-weight: 700; color: #f2f3f5; word-break: break-word; }
.dc-thumb { width: 72px; height: 72px; border-radius: 8px; object-fit: cover; flex-shrink: 0; }
.dc-card hr { border: 0; border-top: 1px solid #3f4147; margin: 12px 0; }
.dc-text { font-size: 14px; line-height: 1.5; margin-bottom: 8px; }
.dc-text b { color: #f2f3f5; }
.dc-text pre { margin: 4px 0 0; background: #1e1f22; border: 1px solid #1a1b1e; border-radius: 6px; padding: 8px 10px; font-family: Consolas, "Courier New", monospace; font-size: 13px; color: #dbdee1; white-space: pre-wrap; word-break: break-all; }
.dc-emoji { width: 18px; height: 18px; vertical-align: -4px; }
.dc-dot { width: 12px; height: 12px; border-radius: 50%; vertical-align: -1px; }
.dc-dot.online { background: #57f287; } .dc-dot.restarting { background: #f5a623; } .dc-dot.offline { background: #ed4245; }
.dc-banner { display: block; width: 100%; max-height: 260px; object-fit: cover; border-radius: 8px; margin: 8px 0 2px; }
.dc-buttons { display: flex; flex-wrap: wrap; gap: 8px; }
.dc-btn { background: #4e5058; color: #fff; font-size: 13px; font-weight: 500; padding: 7px 14px; border-radius: 6px; }
.dc-ext { opacity: .7; font-size: 12px; }
.dc-foot { color: #949ba4; font-size: 12px; margin-top: 10px; }

/* ======================= Admin button + admin-view banner (customer dashboard) ======================= */
.btn-admin { background: linear-gradient(135deg, #f59e0b, #f43f5e); color: #fff; display: inline-flex; align-items: center; gap: 6px; }
.btn-admin:hover { filter: brightness(1.1); transform: translateY(-1px); }
.admin-banner {
  display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 9px 28px;
  background: linear-gradient(90deg, rgba(245,158,11,.16), rgba(244,63,94,.12)); border-bottom: 1px solid rgba(245,158,11,.3);
  color: #fbbf24; font-size: 13px; font-weight: 600;
}
.admin-banner a { color: #fff; text-decoration: none; white-space: nowrap; }
.admin-banner a:hover { text-decoration: underline; }

/* ======================= Admin panel (separate layout + amber/rose theme) ======================= */
.adm {
  --accent: #f59e0b; --accent-hover: #fbbf24; --accent-soft: rgba(245, 158, 11, .14);
  display: grid; grid-template-columns: 250px minmax(0, 1fr); min-height: 100vh;
  background: radial-gradient(900px 480px at 100% -8%, rgba(244,63,94,.10), transparent 60%), radial-gradient(700px 400px at 0% 110%, rgba(245,158,11,.07), transparent 60%), #0a0b0f;
}
.adm .btn-primary { color: #1a1206; }
.adm-side { position: sticky; top: 0; height: 100vh; padding: 22px 14px 16px; display: flex; flex-direction: column; gap: 22px; background: rgba(14,16,22,.92); border-right: 1px solid var(--border); }
.adm-brand { display: flex; align-items: center; gap: 11px; padding: 0 8px; text-decoration: none; color: var(--text); }
.adm-brand b { display: block; font-size: 16px; font-weight: 800; }
.adm-brand small { display: block; font-size: 10px; font-weight: 800; letter-spacing: .14em; background: linear-gradient(90deg, #f59e0b, #f43f5e); -webkit-background-clip: text; background-clip: text; color: transparent; }
.adm-navs { display: flex; flex-direction: column; gap: 4px; }
.adm-nav { display: flex; align-items: center; gap: 11px; padding: 10px 12px; border-radius: 10px; color: var(--text-dim); font-size: 14px; font-weight: 600; text-decoration: none; transition: background .15s, color .15s; }
.adm-nav:hover { background: var(--surface-2); color: var(--text); }
.adm-nav.active { background: linear-gradient(90deg, rgba(245,158,11,.20), rgba(244,63,94,.10)); color: #fbbf24; box-shadow: inset 3px 0 0 #f59e0b; }
.adm-foot { margin-top: auto; display: flex; flex-direction: column; gap: 10px; }
.adm-me { display: flex; align-items: center; gap: 9px; padding: 10px 12px; border-radius: 10px; background: var(--surface-2); font-size: 13px; font-weight: 600; }
.adm-me img { width: 26px; height: 26px; border-radius: 50%; }
.adm-me span { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.adm-me a { color: var(--text-faint); font-size: 12px; text-decoration: none; }
.adm-me a:hover { color: var(--text); }
.adm-main { padding: 34px 38px 70px; min-width: 0; max-width: 1280px; width: 100%; }
.adm-head { margin-bottom: 22px; }
.adm-head h1 { font-size: 26px; }
.adm-tools { display: flex; gap: 10px; flex-wrap: wrap; }
.adm-tools input[type="text"] { width: 300px; max-width: 100%; }
.adm-mini { margin-left: auto; width: 220px; max-width: 100%; padding: 7px 12px !important; font-size: 13px !important; }
.adm .card { margin-bottom: 18px; }

.adm-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(210px, 1fr)); gap: 14px; margin-bottom: 18px; }
.adm-tile { position: relative; overflow: hidden; background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius-md); padding: 18px 20px; }
.adm-tile::before { content: ""; position: absolute; left: 0; top: 0; bottom: 0; width: 3px; background: linear-gradient(#f59e0b, #f43f5e); opacity: .8; }
.adm-tile.hot { background: linear-gradient(135deg, rgba(245,158,11,.14), rgba(244,63,94,.08)), var(--surface); border-color: rgba(245,158,11,.35); }
.adm-tile.warn::before { background: var(--danger); }
.adm-label { font-size: 12px; font-weight: 600; color: var(--text-dim); }
.adm-num { font-size: 32px; font-weight: 800; line-height: 1.15; margin: 6px 0 4px; }
.adm-tile.hot .adm-num { text-shadow: 0 0 26px rgba(245,158,11,.55); }
.adm-sub { font-size: 12px; color: var(--text-faint); }
.adm-row { display: grid; grid-template-columns: minmax(0, 1fr) 320px; gap: 18px; margin-bottom: 0; }
.adm-row-2 { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); }
@media (max-width: 1000px) { .adm-row, .adm-row-2 { grid-template-columns: 1fr; } }
.adm-chart { background: radial-gradient(120% 90% at 50% 0%, rgba(245,158,11,.09), transparent 60%), var(--surface); }
.adm .glow-chart .ring { stroke: #f43f5e; }

.mixbar { display: flex; height: 12px; border-radius: 999px; overflow: hidden; background: var(--surface-3); margin: 6px 0 18px; }
.mixbar i { display: block; height: 100%; }
.mixlist > div { display: flex; align-items: center; gap: 10px; padding: 9px 0; border-top: 1px solid var(--border-soft); font-size: 14px; }
.mixlist b { margin-left: auto; font-size: 16px; }
.mixlist small { color: var(--text-faint); width: 38px; text-align: right; }
.dot { width: 9px; height: 9px; border-radius: 50%; display: inline-block; flex-shrink: 0; }
.dot.online { background: var(--success); } .dot.restarting { background: var(--warning); } .dot.offline { background: var(--danger); }

.adm-toprow { display: flex; align-items: center; gap: 12px; padding: 10px 6px; border-top: 1px solid var(--border-soft); color: inherit; text-decoration: none; border-radius: 8px; }
.adm-toprow:first-of-type { border-top: 0; }
.adm-toprow:hover { background: var(--surface-2); }
.adm-toprow .rank { width: 20px; color: var(--text-faint); font-weight: 800; font-size: 13px; }
.adm-toprow .nm { flex: 1; min-width: 0; font-weight: 600; font-size: 14px; }
.adm-toprow .nm small, .adm-toprow > small { display: block; color: var(--text-faint); font-size: 11.5px; font-weight: 500; }
.adm-toprow > b { font-size: 18px; color: #fbbf24; }
.adm-toprow > small { display: inline; }
.adm-ico { width: 34px; height: 34px; border-radius: 10px; object-fit: cover; flex-shrink: 0; background: var(--surface-3); }
.adm-ico.fb { display: flex; align-items: center; justify-content: center; font-weight: 800; color: var(--text-dim); }

.bot-id { display: flex; align-items: center; gap: 12px; margin-bottom: 8px; }
.bot-id img { width: 46px; height: 46px; border-radius: 12px; }
.bot-id small { display: block; color: var(--text-faint); font-size: 11.5px; }
.kv { display: flex; justify-content: space-between; padding: 9px 0; border-top: 1px solid var(--border-soft); font-size: 13.5px; color: var(--text-dim); }
.kv b { color: var(--text); }

.adm-tablecard { padding: 0 !important; overflow: hidden; }
.adm-tall { max-height: 620px; }
.adm-table { width: 100%; border-collapse: collapse; font-size: 13.5px; }
.adm-table th { text-align: left; color: var(--text-faint); font-size: 11.5px; font-weight: 700; letter-spacing: .03em; padding: 12px 16px; position: sticky; top: 0; background: var(--surface); z-index: 1; }
.adm-table td { padding: 12px 16px; border-top: 1px solid var(--border-soft); vertical-align: middle; }
.adm-table .r { text-align: right; } .adm-table td.dim { color: var(--text-dim); }
.adm-table td small { display: block; color: var(--text-faint); font-size: 11.5px; margin-top: 1px; }
.adm-table tr.click { cursor: pointer; transition: background .12s; }
.adm-table tr.click:hover { background: rgba(245,158,11,.07); }
.adm-table td.go { color: var(--text-faint); font-size: 20px; width: 30px; text-align: right; }
.adm-table tr.click:hover td.go { color: #fbbf24; }
.who { display: flex; align-items: center; gap: 12px; }
.who b { font-weight: 600; } .who small { font-size: 11.5px; }
.cnts { display: flex; align-items: center; gap: 12px; }
.cnts .tot { font-weight: 700; min-width: 18px; }
.cnt { display: inline-flex; align-items: center; gap: 5px; color: var(--text-dim); font-size: 12.5px; }
.pill.adminp { background: rgba(245,158,11,.16); color: #fbbf24; }

.ban-form { display: grid; grid-template-columns: minmax(0, 1.2fr) minmax(0, 1.6fr) auto; gap: 10px; }
@media (max-width: 800px) { .ban-form { grid-template-columns: 1fr; } }
.card-title .adm-mini { margin-left: auto; }

@media (max-width: 860px) {
  .adm { grid-template-columns: 1fr; }
  .adm-side { position: static; height: auto; flex-direction: row; flex-wrap: wrap; align-items: center; padding: 12px; gap: 10px; }
  .adm-navs { flex-direction: row; flex-wrap: wrap; }
  .adm-foot { margin-top: 0; margin-left: auto; flex-direction: row; align-items: center; }
  .adm-main { padding: 22px 16px 60px; }
}
.adm-brand .logo-sm { width: 36px; height: 36px; border-radius: 11px; flex-shrink: 0; display: flex; align-items: center; justify-content: center; background: linear-gradient(135deg, #f59e0b, #f43f5e); box-shadow: 0 0 18px rgba(244,63,94,.35); }
.adm-brand .logo-sm img { width: 68%; height: 68%; object-fit: contain; display: block; }
/* inputs inside the admin panel: keep them compact (global input rule is width:100%) */
.adm-tools select { width: 190px; }
.card-title input.adm-mini { margin-left: auto; width: 230px; max-width: 100%; }
