/* ═══════════════════════════════════════════════════════════════════
   Blessed Control Panel — style.css
   ═══════════════════════════════════════════════════════════════════ */

/* ─── Tokens ─────────────────────────────────────────────────────── */
:root {
  --bg:           #f4f6fb;
  --surface-0:    #ffffff;
  --surface-1:    #f0f2f8;
  --surface-2:    #e6e9f2;
  --surface-3:    #d8dce9;

  --border:       rgba(0,0,0,0.07);
  --border-med:   rgba(0,0,0,0.13);
  --border-strong:rgba(0,0,0,0.22);

  --text:         #0f1724;
  --text-2:       #334155;
  --muted:        #64748b;
  --muted-2:      #94a3b8;

  --accent:       #2563eb;
  --accent-2:     #1d4ed8;
  --accent-bg:    rgba(37,99,235,0.08);
  --accent-fg:    #ffffff;

  --danger:       #dc2626;
  --danger-2:     #b91c1c;
  --danger-bg:    rgba(220,38,38,0.08);

  --ok:           #16a34a;
  --ok-bg:        rgba(22,163,74,0.09);
  --warn:         #d97706;
  --warn-bg:      rgba(217,119,6,0.09);

  --sb-w:         240px;
  --sb-bg:        #0e1420;
  --sb-border:    rgba(255,255,255,0.06);
  --sb-text:      rgba(255,255,255,0.50);
  --sb-text-hi:   #ffffff;
  --sb-hover:     rgba(255,255,255,0.05);
  --sb-active-bg: rgba(255,255,255,0.10);
  --sb-active-accent: #3b82f6;

  --radius-sm:    6px;
  --radius:       8px;
  --radius-lg:    12px;
  --radius-xl:    16px;

  --shadow-sm: 0 1px 2px rgba(0,0,0,0.06);
  --shadow:    0 2px 8px rgba(0,0,0,0.08), 0 1px 2px rgba(0,0,0,0.04);
  --shadow-lg: 0 8px 24px rgba(0,0,0,0.10), 0 2px 6px rgba(0,0,0,0.05);

  --font:      "Inter", system-ui, sans-serif;
  --font-mono: "JetBrains Mono", "Fira Mono", monospace;
}

:root[data-theme="dark"] {
  --bg:           #0a0d14;
  --surface-0:    #111827;
  --surface-1:    #1a2234;
  --surface-2:    #1e2840;
  --surface-3:    #243050;

  --border:       rgba(255,255,255,0.06);
  --border-med:   rgba(255,255,255,0.11);
  --border-strong:rgba(255,255,255,0.20);

  --text:         #e8edf5;
  --text-2:       #b0bdd0;
  --muted:        #718096;
  --muted-2:      #4a5568;

  --accent:       #60a5fa;
  --accent-2:     #93c5fd;
  --accent-bg:    rgba(96,165,250,0.12);

  --danger:       #f87171;
  --danger-2:     #fca5a5;
  --danger-bg:    rgba(248,113,113,0.12);

  --ok:           #4ade80;
  --ok-bg:        rgba(74,222,128,0.10);
  --warn:         #fbbf24;
  --warn-bg:      rgba(251,191,36,0.10);

  --sb-bg:        #080c14;
  --sb-border:    rgba(255,255,255,0.05);
}

/* ─── Reset ──────────────────────────────────────────────────────── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
[hidden] { display: none !important; }
html { font-size: 14px; -webkit-text-size-adjust: 100%; }
body {
  font-family: var(--font);
  font-size: 14px;
  line-height: 1.6;
  color: var(--text);
  background: var(--bg);
  min-height: 100vh;
}
a { color: var(--accent); text-decoration: none; }
a:hover { text-decoration: underline; }
img { display: block; max-width: 100%; }
button { cursor: pointer; font-family: inherit; }
ul { list-style: none; }
code, kbd, pre, samp {
  font-family: var(--font-mono);
  font-size: 0.85em;
  background: var(--surface-2);
  padding: 1px 5px;
  border-radius: 4px;
}

/* ─── App shell ──────────────────────────────────────────────────── */
.app {
  display: grid;
  grid-template-columns: var(--sb-w) minmax(0,1fr);
  min-height: 100vh;
}

/* ─── Sidebar ────────────────────────────────────────────────────── */
.sidebar {
  position: sticky;
  top: 0;
  height: 100vh;
  display: flex;
  flex-direction: column;
  background: var(--sb-bg);
  border-right: 1px solid var(--sb-border);
  overflow: hidden;
  z-index: 100;
}

/* Head */
.sb-head {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 18px 14px 14px;
  border-bottom: 1px solid var(--sb-border);
  flex-shrink: 0;
}
.sb-logo {
  width: 34px; height: 34px;
  border-radius: var(--radius);
  overflow: hidden;
  flex-shrink: 0;
  background: rgba(255,255,255,0.04);
  display: flex; align-items: center; justify-content: center;
}
.sb-logo img { width: 100%; height: 100%; object-fit: cover; }
.sb-name {
  font-size: 13px;
  font-weight: 700;
  color: #fff;
  line-height: 1.2;
}
.sb-sub {
  font-size: 10px;
  font-weight: 500;
  color: var(--sb-text);
  text-transform: uppercase;
  letter-spacing: 0.06em;
  margin-top: 1px;
}

/* Nav */
.sb-nav {
  flex: 1;
  overflow-y: auto;
  overflow-x: hidden;
  padding: 8px 6px;
  display: flex;
  flex-direction: column;
  gap: 1px;
  scrollbar-width: thin;
  scrollbar-color: var(--sb-border) transparent;
}
.sb-nav::-webkit-scrollbar { width: 4px; }
.sb-nav::-webkit-scrollbar-thumb { background: var(--sb-border); border-radius: 2px; }

.sb-link {
  display: flex;
  align-items: center;
  gap: 9px;
  padding: 7px 10px;
  border-radius: var(--radius);
  color: var(--sb-text);
  font-size: 13px;
  font-weight: 500;
  text-decoration: none;
  transition: background 0.12s, color 0.12s;
  position: relative;
  border-left: 2px solid transparent;
  margin-left: 0;
}
.sb-link:hover {
  background: var(--sb-hover);
  color: rgba(255,255,255,0.85);
  text-decoration: none;
}
.sb-link.is-active {
  background: var(--sb-active-bg);
  color: var(--sb-text-hi);
  border-left-color: var(--sb-active-accent);
  font-weight: 600;
}
.sb-icon {
  width: 16px; height: 16px;
  flex-shrink: 0;
  opacity: 0.7;
  transition: opacity 0.12s;
}
.sb-link:hover .sb-icon,
.sb-link.is-active .sb-icon { opacity: 1; }
.sb-link-text { min-width: 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }

/* Footer */
.sb-foot {
  flex-shrink: 0;
  border-top: 1px solid var(--sb-border);
  padding: 10px 8px 12px;
  display: flex;
  flex-direction: column;
  gap: 6px;
}
.sb-user {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 4px 6px;
}
.sb-ava {
  width: 30px; height: 30px;
  border-radius: 50%;
  background: var(--sb-active-accent);
  color: #fff;
  font-size: 12px;
  font-weight: 700;
  display: flex; align-items: center; justify-content: center;
  flex-shrink: 0;
  text-transform: uppercase;
}
.sb-user-meta { min-width: 0; flex: 1; }
.sb-uname {
  display: block;
  font-size: 12px;
  font-weight: 600;
  color: #fff;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  line-height: 1.3;
}
.sb-uguild {
  display: block;
  font-size: 11px;
  color: var(--sb-text);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.sb-btns {
  display: flex;
  align-items: center;
  gap: 3px;
  padding: 0 4px;
}
.sb-btn {
  width: 32px; height: 32px;
  border-radius: var(--radius);
  background: transparent;
  border: 1px solid transparent;
  color: var(--sb-text);
  display: inline-flex;
  align-items: center; justify-content: center;
  transition: background 0.12s, color 0.12s, border-color 0.12s;
  flex-shrink: 0;
  text-decoration: none;
  padding: 0;
  font-size: 0;
  cursor: pointer;
  font-family: inherit;
}
.sb-btn svg { width: 14px; height: 14px; }
.sb-btn:hover {
  background: var(--sb-hover);
  color: #fff;
  border-color: var(--sb-border);
  text-decoration: none;
}
.sb-btn--danger:hover {
  background: var(--danger-bg);
  color: var(--danger);
  border-color: transparent;
}

/* ─── App body + main ────────────────────────────────────────────── */
.app-body {
  display: flex;
  flex-direction: column;
  min-width: 0;
  min-height: 100vh;
}
.app-main {
  flex: 1;
  padding: 28px 28px 40px;
  display: flex;
  flex-direction: column;
  gap: 20px;
  max-width: 1200px;
}

/* ─── Guest layout ───────────────────────────────────────────────── */
.guest-wrap {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  background: var(--bg);
}
.guest-bar {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 14px 24px;
  background: var(--surface-0);
  border-bottom: 1px solid var(--border);
  flex-shrink: 0;
}
.guest-main {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 40px 24px;
}
.guest-main > * { width: 100%; max-width: 420px; }
.guest-main--wide > * { max-width: 680px; }

/* ─── Icon toggle ────────────────────────────────────────────────── */
.icon-sun, .icon-moon { display: block; }

/* ─── Outer form containers ──────────────────────────────────────── */
.app-main > form { display: contents; }
.main > form    { display: contents; }

/* ─── Responsive collapse ────────────────────────────────────────── */
@media (max-width: 860px) {
  :root { --sb-w: 60px; }
  .sb-name, .sb-sub, .sb-link-text,
  .sb-user-meta                { display: none; }
  .sb-head                     { justify-content: center; padding: 14px 8px; gap: 0; }
  .sb-nav                      { padding: 8px 4px; align-items: stretch; }
  .sb-link                     { justify-content: center; padding: 8px; border-left-width: 0; border-bottom: 2px solid transparent; }
  .sb-link.is-active           { border-bottom-color: var(--sb-active-accent); }
  .sb-foot                     { padding: 8px 4px; align-items: center; }
  .sb-user                     { justify-content: center; padding: 4px; }
  .sb-btns                     { flex-direction: column; gap: 2px; }
  .sb-icon                     { width: 18px; height: 18px; }
  .app-main                    { padding: 16px; gap: 14px; }
}


/* Page header */
.page-head, .pg-hd { padding-bottom: 4px; }
.page-head h1, .pg-hd h1 { font-size: 22px; font-weight: 700; letter-spacing: -0.4px; color: var(--text); line-height: 1.25; }
.page-head p, .pg-hd p { font-size: 13px; color: var(--muted); margin-top: 5px; line-height: 1.6; }

/* Alert */
.alert { padding: 11px 14px; border-radius: var(--radius); font-size: 13px; font-weight: 500; border: 1px solid; line-height: 1.5; }
.alert.ok    { background: var(--ok-bg);     border-color: rgba(22,163,74,.25);  color: var(--ok); }
.alert.error { background: var(--danger-bg); border-color: rgba(220,38,38,.25); color: var(--danger); }

/* Callout */
.callout, .help-box { background: var(--accent-bg); border: 1px solid rgba(37,99,235,.14); border-left: 3px solid var(--accent); border-radius: var(--radius); padding: 12px 14px; font-size: 13px; }
:root[data-theme="dark"] .callout, :root[data-theme="dark"] .help-box { border-color: rgba(96,165,250,.12); border-left-color: var(--accent); }
.callout > b, .help-box .title { display: block; font-size: 10.5px; font-weight: 700; text-transform: uppercase; letter-spacing: .08em; color: var(--accent); margin-bottom: 7px; }
.callout ul, .help-box .list { display: flex; flex-direction: column; gap: 4px; padding-left: 16px; list-style: disc; color: var(--text-2); }
.callout ul li, .help-box .list li { font-size: 13px; line-height: 1.5; }

/* Tabs */
.tabs { display: flex; flex-direction: column; gap: 6px; }
.tabs-nav { display: flex; gap: 3px; flex-wrap: wrap; padding: 4px; background: var(--surface-1); border: 1px solid var(--border); border-radius: var(--radius-lg); width: fit-content; max-width: 100%; }
.tab-btn { padding: 6px 14px; border-radius: var(--radius); border: none; background: transparent; color: var(--muted); font-size: 13px; font-weight: 500; cursor: pointer; transition: background .12s, color .12s; white-space: nowrap; font-family: inherit; }
.tab-btn:hover { background: var(--surface-0); color: var(--text); }
.tab-btn.is-active { background: var(--surface-0); color: var(--accent); font-weight: 600; box-shadow: var(--shadow-sm); }
.tab-intro { font-size: 12px; color: var(--muted); padding: 2px 2px; min-height: 18px; }

/* Card */
.card { background: var(--surface-0); border: 1px solid var(--border); border-radius: var(--radius-lg); overflow: hidden; }
.card-head, .card-hd { padding: 14px 18px; border-bottom: 1px solid var(--border); display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.card-head h2, .card-hd h2 { font-size: 14px; font-weight: 600; color: var(--text); flex: 1; min-width: 0; }
.card-desc { padding: 10px 18px 0; font-size: 13px; color: var(--muted); line-height: 1.5; }
.card-body, .card-bd { padding: 16px 18px; display: flex; flex-direction: column; gap: 14px; }
.card > form { display: contents; }
.app-main > form { display: contents; }

/* Field groups */
.field { display: flex; flex-direction: column; gap: 5px; }
.field > label { font-size: 12px; font-weight: 600; color: var(--text-2); }
.fhint, .hint { font-size: 12px; color: var(--muted); line-height: 1.4; }

/* Form elements */
input:not([type="checkbox"]):not([type="radio"]):not([type="submit"]):not([type="button"]):not([type="file"]),
select, textarea {
  width: 100%; padding: 8px 10px; font-size: 13px; font-family: inherit; color: var(--text);
  background: var(--surface-1); border: 1px solid var(--border-med); border-radius: var(--radius);
  outline: none; transition: border-color .12s, box-shadow .12s; line-height: 1.4; -webkit-appearance: none;
}
input:not([type="checkbox"]):not([type="radio"]):not([type="submit"]):not([type="button"]):not([type="file"]):focus,
select:focus, textarea:focus { border-color: var(--accent); box-shadow: 0 0 0 3px var(--accent-bg); }
textarea { resize: vertical; min-height: 80px; }
select { cursor: pointer; }
label.check { display: inline-flex; align-items: center; gap: 8px; font-size: 13px; font-weight: 500; color: var(--text); cursor: pointer; }
label.check.small { font-size: 12.5px; }
label.check input[type="checkbox"], label.check input[type="radio"] { width: 15px; height: 15px; flex-shrink: 0; accent-color: var(--accent); cursor: pointer; }

/* Card direct-child elements (legacy pattern) */
.card > label:not([class]) { display: block; font-size: 12px; font-weight: 600; color: var(--text-2); padding: 14px 18px 0; }
.card > label.check { display: flex; padding: 10px 18px 0; }
.card > input, .card > select, .card > textarea { margin: 4px 18px 0; width: calc(100% - 36px); }
.card > .hint { padding: 4px 18px 0; }
.card > .divider { margin: 10px 18px; width: calc(100% - 36px); }
.card > .section-title { padding: 14px 18px 0; }
.card > .chip-list { padding: 4px 18px 0; }
.card > .inline-actions { padding: 8px 18px 0; }
.card > .grid { padding: 0 18px; }
.card > .toggle { padding: 10px 18px 0; }
.card > .kv { padding: 0 18px; }
.card > .note { padding: 8px 18px; }
.card > p.note { padding: 8px 18px; }
.card > .command-grid { padding: 4px 18px 0; }
.card > form > label:not([class]) { display: block; font-size: 12px; font-weight: 600; color: var(--text-2); padding: 14px 18px 0; }
.card > form > label.check { display: flex; padding: 10px 18px 0; }
.card > form > input, .card > form > select, .card > form > textarea { margin: 4px 18px 0; width: calc(100% - 36px); }
.card > form > .hint { padding: 4px 18px 0; }
.card > form > .divider { margin: 10px 18px; width: calc(100% - 36px); }
.card > form > .section-title { padding: 14px 18px 0; }
.card > form > .chip-list { padding: 4px 18px 0; }
.card > form > .inline-actions { padding: 8px 18px 0; }
.card > form > button.btn { margin: 12px 18px 16px; width: calc(100% - 36px); }

/* Buttons */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 6px; padding: 8px 16px; font-size: 13px; font-weight: 600; border-radius: var(--radius); border: 1px solid var(--border-med); cursor: pointer; background: var(--surface-1); color: var(--text); font-family: inherit; text-decoration: none; transition: background .12s, border-color .12s; white-space: nowrap; line-height: 1; }
.btn:hover { background: var(--surface-2); text-decoration: none; }
.btn.primary { background: var(--accent); border-color: var(--accent); color: #fff; }
.btn.primary:hover { background: var(--accent-2); border-color: var(--accent-2); }
.btn.ghost { background: transparent; color: var(--text); }
.btn.ghost:hover { background: var(--surface-1); }
.btn.danger { background: var(--danger-bg); border-color: rgba(220,38,38,.2); color: var(--danger); }
.btn.danger:hover { background: var(--danger); border-color: var(--danger); color: #fff; }
.btn.small, .btn.sm { padding: 5px 10px; font-size: 12px; }

/* Save row */
.pg-save, .row.space { display: flex; align-items: center; justify-content: flex-end; gap: 10px; padding: 12px 18px; background: var(--surface-0); border: 1px solid var(--border); border-radius: var(--radius-lg); }
.pg-save .note, .row.space .note { flex: 1; font-size: 12px; color: var(--muted); }

/* Table */
.table { display: grid; border: 1px solid var(--border); border-radius: var(--radius); overflow: hidden; font-size: 13px; }
.table .row { display: contents; }
.table .row > div { padding: 9px 12px; border-bottom: 1px solid var(--border); border-right: 1px solid var(--border); display: flex; align-items: center; gap: 6px; flex-wrap: wrap; min-width: 0; }
.table .row > div:last-child { border-right: none; }
.table .row:last-child > div { border-bottom: none; }
.table .row.header > div { background: var(--surface-1); font-weight: 600; font-size: 11.5px; text-transform: uppercase; letter-spacing: .05em; color: var(--muted); }
.table .row:not(.header):hover > div { background: var(--surface-1); transition: background .1s; }
.table .row.is-busy > div { background: rgba(217,119,6,.07); }
.table .row > div > form { display: contents; }

/* KV */
.kv { display: grid; grid-template-columns: auto 1fr; }
.kv > div { padding: 7px 0; border-bottom: 1px solid var(--border); font-size: 13px; line-height: 1.4; }
.kv > div:nth-child(odd) { color: var(--muted); padding-right: 20px; font-weight: 500; }
.kv > div:nth-child(even) { color: var(--text); font-weight: 600; }
.kv > div:nth-last-child(-n+2) { border-bottom: none; }

/* Badge / Pill */
.badge { display: inline-flex; align-items: center; padding: 2px 8px; border-radius: 999px; font-size: 11px; font-weight: 600; border: 1px solid var(--border-med); background: var(--surface-1); color: var(--text-2); }
.pill { display: inline-flex; align-items: center; padding: 2px 8px; border-radius: 999px; font-size: 11px; font-weight: 600; background: var(--accent-bg); color: var(--accent); border: 1px solid rgba(37,99,235,.15); }
:root[data-theme="dark"] .pill { border-color: rgba(96,165,250,.18); }

/* Chip */
.chip-list { display: flex; flex-wrap: wrap; gap: 6px; }
.chip { display: inline-flex; align-items: center; gap: 4px; padding: 3px 8px 3px 10px; border-radius: 999px; background: var(--surface-2); border: 1px solid var(--border-med); font-size: 12px; font-weight: 500; color: var(--text); }
.chip-remove { background: none; border: none; color: var(--muted); cursor: pointer; padding: 0 2px; font-size: 14px; line-height: 1; display: flex; align-items: center; }
.chip-remove:hover { color: var(--danger); }

/* Stack */
.stack { display: flex; flex-direction: column; gap: 6px; }

/* Inline actions */
.inline-actions { display: flex; align-items: center; flex-wrap: wrap; gap: 6px; }

/* Grid */
.grid { display: grid; gap: 16px; }
.grid.two { grid-template-columns: 1fr 1fr; }
.grid.three { grid-template-columns: 1fr 1fr 1fr; }
@media (max-width: 720px) { .grid.two, .grid.three { grid-template-columns: 1fr; } }

/* Divider */
.divider { height: 1px; background: var(--border); }

/* Section title */
.section-title { font-size: 11px; font-weight: 700; text-transform: uppercase; letter-spacing: .07em; color: var(--muted); }

/* Text utilities */
.note { font-size: 12px; color: var(--muted); line-height: 1.5; }
.mono { font-family: var(--font-mono); font-size: 0.9em; }

/* Command grid */
.command-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(130px, 1fr)); gap: 4px; }
.command-item { padding: 6px 8px; border-radius: var(--radius-sm); background: var(--surface-1); border: 1px solid var(--border); transition: background .1s; }
.command-item:hover { background: var(--surface-2); }

/* Toggle group */
.toggle { display: flex; flex-direction: column; gap: 8px; }
.toggle label { display: flex; align-items: center; gap: 8px; font-size: 13px; font-weight: 500; color: var(--text); cursor: pointer; }

/* Log viewer */
.log { font-family: var(--font-mono); font-size: 12px; line-height: 1.7; color: var(--text-2); background: var(--surface-1); border: 1px solid var(--border); border-radius: var(--radius); padding: 14px 16px; overflow: auto; max-height: 64vh; white-space: pre-wrap; word-break: break-all; }

/* Login card */
.login-card { background: var(--surface-0); border: 1px solid var(--border); border-radius: var(--radius-xl); padding: 32px; box-shadow: var(--shadow-lg); display: flex; flex-direction: column; gap: 18px; }
.login-card h1 { font-size: 20px; font-weight: 700; color: var(--text); }
.login-card p  { font-size: 13px; color: var(--muted); margin-top: -10px; }

/* Server picker */
.server-picker-page { min-height: 100vh; background: var(--bg); display: flex; flex-direction: column; }
.server-picker-top { display: flex; align-items: center; gap: 12px; padding: 14px 28px; background: var(--surface-0); border-bottom: 1px solid var(--border); flex-shrink: 0; }
.brand { display: flex; align-items: center; gap: 12px; flex: 1; }
.brand .logo { width: 36px; height: 36px; border-radius: var(--radius); overflow: hidden; }
.brand .logo img { width: 100%; height: 100%; object-fit: cover; }
.brand .title { font-weight: 700; font-size: 14px; color: var(--text); }
.brand .subtitle { font-size: 12px; color: var(--muted); margin-top: 1px; }
.server-picker { max-width: 540px; width: 100%; margin: 40px auto; padding: 0 24px 60px; }
.server-picker-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 12px; margin-bottom: 20px; }
.server-picker-head h1 { font-size: 18px; font-weight: 700; color: var(--text); }
.server-picker-head p  { font-size: 13px; color: var(--muted); margin-top: 3px; }
.server-picker-title { flex: 1; }
.server-picker-user { font-size: 13px; font-weight: 600; color: var(--text-2); padding: 4px 10px; background: var(--surface-1); border: 1px solid var(--border); border-radius: 999px; white-space: nowrap; }
.server-picker-list { display: flex; flex-direction: column; gap: 8px; }
.server-row { display: flex; align-items: center; gap: 12px; padding: 12px 14px; border-radius: var(--radius-lg); background: var(--surface-0); border: 1px solid var(--border); cursor: pointer; font-family: inherit; font-size: 14px; font-weight: 600; color: var(--text); text-align: left; width: 100%; transition: border-color .12s, box-shadow .12s, background .12s; }
.server-row:hover { border-color: var(--accent); box-shadow: 0 0 0 2px var(--accent-bg); background: var(--accent-bg); }
.server-row.is-current { border-color: var(--accent); background: var(--accent-bg); }
.server-row-icon { width: 40px; height: 40px; border-radius: 50%; overflow: hidden; background: var(--surface-2); display: flex; align-items: center; justify-content: center; flex-shrink: 0; font-size: 16px; font-weight: 800; color: var(--accent); }
.server-row-icon img { width: 100%; height: 100%; object-fit: cover; }
.server-row-name { flex: 1; }
.server-row-state { font-size: 11px; font-weight: 600; color: var(--accent); background: var(--accent-bg); padding: 2px 8px; border-radius: 999px; border: 1px solid rgba(37,99,235,.15); }
.server-row-arrow { color: var(--muted); font-size: 18px; }
.server-picker-foot { margin-top: 20px; display: flex; gap: 8px; }
.server-picker-brand { gap: 10px; }

/* Messages editor */
.mini-form { display: flex; flex-direction: column; gap: 8px; }
.card > .grid.two { padding: 16px 18px; }
.msg-list, .recent-msg { display: flex; flex-direction: column; gap: 6px; max-height: 280px; overflow-y: auto; scrollbar-width: thin; }
.msg-item, .recent-msg-item { padding: 9px 12px; border-radius: var(--radius); background: var(--surface-1); border: 1px solid var(--border); cursor: pointer; transition: border-color .1s, background .1s; font-size: 13px; }
.msg-item:hover, .msg-item.is-selected, .recent-msg-item:hover, .recent-msg-item.is-selected { border-color: var(--accent); background: var(--accent-bg); }
.msg-item-meta, .recent-msg-meta { font-size: 11px; color: var(--muted); margin-bottom: 2px; }
.msg-item-text, .recent-msg-text { color: var(--text); white-space: pre-wrap; overflow: hidden; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; }

/* Embed builder */
.embed-preview { border-left: 4px solid var(--accent); background: var(--surface-1); border-radius: 0 var(--radius) var(--radius) 0; padding: 12px 14px; display: flex; flex-direction: column; gap: 6px; min-height: 60px; }
.embed-preview-title { font-weight: 700; font-size: 14px; color: var(--text); }
.embed-preview-desc  { font-size: 13px; color: var(--text-2); white-space: pre-wrap; }
.embed-preview-field { background: var(--surface-2); border-radius: var(--radius-sm); padding: 8px 10px; font-size: 12px; }
.embed-preview-footer { font-size: 11px; color: var(--muted); margin-top: 4px; }
.embed-preview-img { max-width: 100%; border-radius: var(--radius); margin-top: 6px; }
.embed-preview-thumb { width: 72px; height: 72px; object-fit: cover; border-radius: var(--radius-sm); float: right; margin: 0 0 4px 12px; }
.embed-field-row { background: var(--surface-1); border: 1px solid var(--border); border-radius: var(--radius); padding: 10px; display: flex; flex-direction: column; gap: 6px; margin-bottom: 6px; }
.embed-thumbnail { width: 72px; height: 72px; object-fit: cover; border-radius: var(--radius-sm); flex-shrink: 0; }
.embed-image { max-width: 100%; border-radius: var(--radius); margin-top: 4px; }

/* ─── Media (картинки) ───────────────────────────────────────────── */
.media-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: 16px; }
.media-card { display: flex; flex-direction: column; }
.media-card .hint { padding: 8px 18px 0; }
.media-preview { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; padding: 12px 18px; }
.media-frame { display: flex; flex-direction: column; gap: 6px; }
.media-label { font-size: 11px; font-weight: 600; text-transform: uppercase; letter-spacing: .06em; color: var(--muted); }
.media-frame img { width: 100%; aspect-ratio: 16/9; object-fit: cover; border-radius: var(--radius); border: 1px solid var(--border); background: var(--surface-2); display: block; }
.media-frame img:not(.show):not([src]) { display: none; }
.media-placeholder { width: 100%; aspect-ratio: 16/9; border-radius: var(--radius); border: 2px dashed var(--border-med); background: var(--surface-1); display: flex; align-items: center; justify-content: center; font-size: 12px; color: var(--muted); }
.media-placeholder.hide { display: none; }
.media-next-img { width: 100%; aspect-ratio: 16/9; object-fit: cover; border-radius: var(--radius); border: 1px solid var(--border); display: none; }
.media-next-img.show { display: block; }
.media-card form { display: flex; flex-direction: column; gap: 8px; padding: 0 18px 16px; }
.media-file { padding: 6px 0; border: none; background: none; font-size: 12px; color: var(--muted); cursor: pointer; width: 100%; }
.media-actions { display: flex; justify-content: flex-end; }

.bracket {
  display: grid;
  gap: 12px;
  padding: 8px;
  border-radius: 12px;
  border: 1px solid var(--border);
  background: var(--surface-2);
  width: 100%;
  overflow: visible;
}

.bracket.bracket-full {
  padding: 0;
  border: none;
  background: transparent;
  gap: 20px;
  --bracket-card: rgba(22, 28, 36, 0.98);
  --bracket-row: rgba(28, 35, 46, 0.98);
  --bracket-score: rgba(18, 23, 30, 0.98);
  --bracket-border: rgba(255, 255, 255, 0.14);
  --bracket-line: rgba(255, 255, 255, 0.22);
  --bracket-title: rgba(24, 30, 40, 0.95);
  --bracket-muted: rgba(203, 213, 225, 0.72);
}

:root:not([data-theme="dark"]) .bracket.bracket-full {
  --bracket-card: #ffffff;
  --bracket-row: #ffffff;
  --bracket-score: #f1f5f9;
  --bracket-border: rgba(15, 23, 42, 0.18);
  --bracket-line: rgba(15, 23, 42, 0.28);
  --bracket-title: #e2e8f0;
  --bracket-muted: #1f2937;
}

:root:not([data-theme="dark"]) .bracket-full .match-name {
  color: #0f172a;
}

:root:not([data-theme="dark"]) .bracket-full .match-score {
  background: var(--bracket-score);
  color: #334155;
}

:root:not([data-theme="dark"]) .bracket-full .match-row.winner {
  background: rgba(14, 116, 144, 0.12);
  border-color: rgba(14, 116, 144, 0.4);
}

:root:not([data-theme="dark"]) .bracket-full .match-row.winner .match-score {
  background: #0f766e;
  color: #ffffff;
}

.bracket-full .bracket-rounds {
  grid-auto-columns: 190px;
  gap: var(--round-col-gap);
  padding: 0;
  border: none;
  background: transparent;
  --max-matches: 1;
  --round-head: 28px;
  --round-col-gap: 28px;
  --base-gap: 8px;
  --match-meta: 0px;
  --match-row: 26px;
  --match-gap: 6px;
  --match-block: calc(var(--match-meta) + (var(--match-row) * 2) + (var(--match-gap) * 2));
  --base-step: calc(var(--match-block) + var(--base-gap));
  --round-height: calc((var(--max-matches) * var(--base-step)) - var(--base-gap));
}

.bracket-full .bracket-round {
  padding: 0;
  border: none;
  background: transparent;
  gap: 8px;
  width: 190px;
  display: grid;
  grid-template-rows: auto 1fr;
  --pow: 1;
  --step: calc(var(--base-step) * var(--pow));
  --offset: calc((var(--step) - var(--match-block)) / 2);
}

.bracket-tools {
  display: none;
}

.bracket-section {
  display: grid;
  gap: 12px;
}

.bracket-panel {
  padding: 0;
  border-radius: 12px;
  border: none;
  background: transparent;
}

.bracket-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

.bracket-rounds {
  display: grid;
  grid-auto-flow: column;
  grid-auto-columns: minmax(200px, 220px);
  gap: 12px;
  overflow: visible;
  padding: 8px;
  border-radius: 10px;
  border: 1px solid var(--border);
  background: var(--surface-3);
  justify-content: start;
}

.bracket-round {
  display: grid;
  gap: 8px;
  min-width: 200px;
  padding: 8px;
  border-radius: 10px;
  border: 1px solid var(--border);
  background: var(--surface-1);
}

.round-title {
  font-size: 10px;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--muted);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 4px 6px;
  border-radius: 6px;
  border: 1px solid var(--border);
  background: var(--surface-2);
}

.bracket-full .round-title {
  font-size: 11px;
  padding: 6px 8px;
  border-radius: 8px;
  background: var(--bracket-title);
  height: var(--round-head);
  align-items: center;
  color: var(--bracket-muted);
  border-color: var(--bracket-border);
}

.bracket-full .round-body {
  position: relative;
  height: var(--round-height);
}

.match-card {
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 6px;
  background: var(--surface-2);
  display: grid;
  gap: 4px;
  position: relative;
}

.bracket-round:not(:last-child) .match-card::after {
  content: "";
  position: absolute;
  top: 50%;
  right: -8px;
  width: 8px;
  height: 1px;
  background: var(--border);
}

.bracket-full .round-body .match-card {
  position: absolute;
  left: 0;
  right: 0;
  top: calc(var(--offset) + (var(--idx) * var(--step)));
  border: none;
  padding: 0;
  background: transparent;
  gap: var(--match-gap);
  height: var(--match-block);
  align-content: start;
  box-shadow: none;
}

.bracket-full .round-body .match-card::after {
  content: "";
  position: absolute;
  top: 50%;
  right: calc(-1 * var(--round-col-gap));
  width: var(--round-col-gap);
  height: 1px;
  background: var(--bracket-line);
}

.bracket-full .round-body .match-card.pair-start::before {
  content: "";
  position: absolute;
  top: 50%;
  right: calc(-1 * var(--round-col-gap));
  width: 1px;
  height: var(--step);
  background: var(--bracket-line);
}

.bracket-full .bracket-round:last-child .match-card::after,
.bracket-full .bracket-round:last-child .match-card.pair-start::before {
  display: none;
}

.match-meta {
  font-size: 9px;
  color: var(--muted);
  text-transform: uppercase;
  letter-spacing: 0.06em;
  margin-bottom: 0;
}

.bracket-full .match-meta {
  display: none;
  height: 0;
  line-height: 0;
}

.match-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 28px;
  align-items: center;
  gap: 0;
  padding: 0;
  border-radius: 6px;
  background: var(--surface-3);
  color: inherit;
  text-align: left;
  overflow: hidden;
  border: 1px solid transparent;
  appearance: none;
  font: inherit;
}

.bracket-full .match-row {
  grid-template-columns: minmax(0, 1fr) 26px;
  border: 1px solid var(--bracket-border);
  background: var(--bracket-row);
  border-radius: 6px;
  min-height: var(--match-row);
  height: var(--match-row);
}

.match-row.pick {
  width: 100%;
  cursor: pointer;
  transition: border-color 0.2s ease, background 0.2s ease, box-shadow 0.2s ease;
}

.match-name {
  padding: 4px 6px;
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-size: 11px;
}

.bracket-full .match-name {
  padding: 4px 8px;
  font-size: 11px;
  color: #eef2f7;
}

.match-score {
  width: 28px;
  min-width: 28px;
  height: 100%;
  display: grid;
  place-items: center;
  font-size: 10px;
  font-family: "IBM Plex Mono", ui-monospace, SFMono-Regular, Menlo, Consolas, "Liberation Mono", monospace;
  background: var(--surface-1);
  border-left: 1px solid var(--border);
  color: var(--muted);
}

.bracket-full .match-score {
  width: 26px;
  min-width: 26px;
  font-size: 10px;
  background: var(--bracket-score);
  border-left-color: var(--bracket-border);
  color: var(--bracket-muted);
  height: 100%;
}

.match-row.pick:hover {
  border-color: var(--border);
  background: var(--surface-2);
  box-shadow: 0 0 0 1px var(--border) inset;
}

.match-row.pick:focus-visible {
  outline: 2px solid rgba(29, 78, 216, 0.4);
  outline-offset: 2px;
}

.match-row.winner {
  background: rgba(15, 118, 110, 0.12);
  border: 1px solid rgba(15, 118, 110, 0.28);
}

.bracket-full .match-row.winner {
  background: rgba(34, 197, 187, 0.16);
  border: 1px solid rgba(34, 197, 187, 0.4);
}

.match-row.winner .match-name {
  font-weight: 600;
}

.match-row.winner .match-score {
  background: var(--accent-2);
  border-left-color: rgba(0, 0, 0, 0.12);
  color: #ffffff;
  font-weight: 600;
}

.match-row.pick:disabled {
  cursor: not-allowed;
  opacity: 0.6;
}

.media-grid {
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
}

.media-card {
  display: grid;
  gap: 12px;
}

.media-preview {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
  gap: 10px;
}

.media-frame {
  display: grid;
  gap: 8px;
  padding: 10px;
  border-radius: 12px;
  border: 1px dashed var(--border);
  background: var(--surface-2);
  overflow: hidden;
}

.media-frame img {
  width: 100%;
  height: 160px;
  max-height: 160px;
  object-fit: contain;
  display: block;
  border-radius: 8px;
  border: 1px solid var(--border);
  background: var(--surface-3);
}

.media-label {
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--muted);
}

.media-placeholder {
  font-size: 12px;
  color: var(--muted);
  text-align: center;
  height: 160px;
  display: grid;
  place-items: center;
}

.media-placeholder.hide {
  display: none;
}

.media-next-img {
  display: none;
}

.media-next-img.show {
  display: block;
}

.media-actions {
  display: flex;
  justify-content: flex-end;
  margin-top: 10px;
}

.winners-admin-grid {
  display: grid;
  gap: 12px;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  margin-top: 12px;
}

.winners-admin-card {
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 12px;
  background: var(--surface-2);
  display: grid;
  gap: 6px;
}

.winners-archive-admin {
  margin-top: 14px;
  display: grid;
  gap: 10px;
}

.winners-archive-grid {
  display: grid;
  gap: 12px;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
}

.winners-archive-card {
  border: 1px dashed var(--border);
  border-radius: 12px;
  padding: 12px;
  background: var(--surface-2);
  display: grid;
  gap: 6px;
}

body.winners-page {
  margin: 0;
  background: #0b0d10;
  color: #f2f5f7;
  font-family: "Manrope", "IBM Plex Sans", sans-serif;
  min-height: 100vh;
  --w5-bg-0: #0b0d10;
  --w5-bg-1: #10141b;
  --w5-bg-2: #171c27;
  --w5-panel: rgba(16, 20, 27, 0.92);
  --w5-line: rgba(255, 255, 255, 0.08);
  --w5-text: #f2f5f7;
  --w5-muted: #9aa7b2;
  --w5-accent: #7df9c2;
  --w5-accent-soft: #bfffe1;
  --w5-ember: #ffb25e;
  --w5-ember-soft: #ffd7a6;
  --w5-silver: #cfd6df;
  --w5-bronze: #c7834e;
  --w5-shadow: 0 30px 80px rgba(0, 0, 0, 0.55);
  --w5-noise: rgba(255, 255, 255, 0.035);
  --w4-bg-0: #0b0d10;
  --w4-bg-1: #10141b;
  --w4-bg-2: #171c27;
  --w4-panel: rgba(16, 20, 27, 0.92);
  --w4-border: rgba(255, 255, 255, 0.08);
  --w4-text: #f2f5f7;
  --w4-muted: #9aa7b2;
  --w4-ember: #ffb25e;
  --w4-ember-soft: #ffd7a6;
  --w4-ice: #cfd6df;
  --w4-ice-soft: #eef1f5;
  --w4-bronze: #c7834e;
  --w4-bronze-soft: #e5b08b;
  --w4-emerald: #7df9c2;
  --w4-shadow: 0 30px 80px rgba(0, 0, 0, 0.55);
  --w4-noise: rgba(255, 255, 255, 0.035);
}

body.winners-page::after {
  content: "";
  position: fixed;
  inset: 0;
  background-image:
    radial-gradient(var(--w5-noise) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.02) 1px, transparent 1px);
  background-size: 3px 3px, 160px 160px;
  opacity: 0.2;
  pointer-events: none;
  z-index: 0;
}

.winners-backdrop {
  position: relative;
  min-height: 100vh;
  overflow: hidden;
  background: #07080a;
}

.winners-backdrop::before {
  content: "";
  position: absolute;
  inset: -12%;
  background-image: var(--w-bg-image, none);
  background-size: cover;
  background-position: center;
  opacity: 0.32;
  filter: saturate(0.9) contrast(1.08);
  mix-blend-mode: screen;
}

.winners-backdrop::after {
  content: "";
  position: absolute;
  inset: 0;
  background:
    radial-gradient(circle at 20% 18%, rgba(246, 213, 143, 0.22), transparent 55%),
    radial-gradient(circle at 82% 16%, rgba(192, 122, 67, 0.28), transparent 55%),
    radial-gradient(circle at 70% 82%, rgba(231, 236, 242, 0.22), transparent 60%),
    linear-gradient(180deg, rgba(4, 5, 6, 0.7), rgba(6, 7, 10, 0.96));
}

.winners-shell {
  position: relative;
  z-index: 1;
  min-height: 100vh;
  width: min(1200px, 100%);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  gap: 24px;
  padding: 44px 20px 64px;
  margin: 0 auto;
}

.winners-header {
  display: flex;
  align-items: center;
  gap: 18px;
  text-transform: uppercase;
  padding: 8px 16px;
  border-radius: 999px;
  border: 1px solid rgba(246, 213, 143, 0.3);
  background: rgba(10, 11, 14, 0.6);
  box-shadow: 0 18px 40px rgba(0, 0, 0, 0.45);
}

.winners-logo {
  width: 78px;
  height: 78px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  background: radial-gradient(circle at 30% 20%, rgba(247, 227, 183, 0.95), rgba(217, 130, 43, 0.55));
  border: 1px solid rgba(246, 213, 143, 0.7);
  box-shadow: 0 18px 40px rgba(0, 0, 0, 0.5);
}

.winners-logo img {
  width: 70%;
  height: 70%;
  object-fit: contain;
  display: block;
  filter: drop-shadow(0 6px 12px rgba(0, 0, 0, 0.45));
}

.winners-meta {
  display: grid;
  gap: 4px;
  text-align: left;
}

.winners-event {
  font-family: "Cinzel", "Sora", sans-serif;
  font-size: 12px;
  letter-spacing: 0.26em;
  color: var(--w-gold-1);
}

.winners-subtitle {
  font-size: 12px;
  letter-spacing: 0.14em;
  color: rgba(255, 255, 255, 0.7);
}

.winners-hero {
  width: min(880px, 100%);
  display: grid;
  gap: 12px;
  padding: 34px 32px 36px;
  border-radius: 26px;
  border: 1px solid rgba(246, 213, 143, 0.42);
  background: linear-gradient(130deg, rgba(78, 64, 40, 0.75), rgba(28, 32, 42, 0.75));
  box-shadow: 0 32px 70px rgba(0, 0, 0, 0.6);
  position: relative;
  overflow: hidden;
  animation: winners-pop 0.6s ease both;
}

.winners-hero::before {
  content: "";
  position: absolute;
  inset: 0;
  background:
    radial-gradient(circle at 18% 18%, rgba(246, 213, 143, 0.24), transparent 60%),
    radial-gradient(circle at 82% 75%, rgba(231, 236, 242, 0.22), transparent 55%);
  opacity: 0.8;
  pointer-events: none;
}

.winners-hero::after {
  content: "";
  position: absolute;
  inset: 14px;
  border-radius: 20px;
  border: 1px solid rgba(255, 255, 255, 0.06);
  pointer-events: none;
}

.winners-label {
  font-family: "Cinzel", "Sora", sans-serif;
  font-size: 11px;
  letter-spacing: 0.34em;
  text-transform: uppercase;
  color: var(--w-gold-1);
}

.winners-name {
  font-size: clamp(36px, 6vw, 74px);
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  background: linear-gradient(90deg, var(--w-gold-3), var(--w-gold-2), var(--w-gold-3));
  -webkit-background-clip: text;
  color: transparent;
  text-shadow: 0 14px 30px rgba(0, 0, 0, 0.45);
  word-break: break-word;
}

.winners-handles {
  font-size: 14px;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.7);
  word-break: break-word;
}

.winners-note {
  font-size: 12px;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.55);
}

.winners-prize {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding: 12px 26px;
  border-radius: 999px;
  background: linear-gradient(135deg, var(--w-gold-1), var(--w-gold-2));
  color: #2a1506;
  font-weight: 700;
  letter-spacing: 0.14em;
  box-shadow: 0 18px 36px rgba(0, 0, 0, 0.45);
}

.prize-amount {
  font-size: 20px;
}

.prize-label {
  font-size: 12px;
  letter-spacing: 0.26em;
  text-transform: uppercase;
}

.winners-podium {
  width: min(780px, 100%);
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 16px;
}

.winners-podium .podium-card:first-child {
  transform: translateY(4px);
}

.podium-card {
  --accent: rgba(246, 213, 143, 0.7);
  display: grid;
  gap: 8px;
  padding: 16px 16px 18px;
  border-radius: 16px;
  border: 1px solid rgba(255, 255, 255, 0.1);
  background: linear-gradient(160deg, rgba(11, 12, 16, 0.88), rgba(16, 18, 24, 0.88));
  min-height: 140px;
  animation: winners-rise 0.6s ease both;
  position: relative;
  overflow: hidden;
}

.podium-card::before {
  content: "";
  position: absolute;
  inset: 0;
  background: radial-gradient(circle at 15% 20%, rgba(255, 255, 255, 0.08), transparent 55%);
  opacity: 0.7;
  pointer-events: none;
}

.podium-card::after {
  content: "";
  position: absolute;
  top: 0;
  left: 16px;
  right: 16px;
  height: 4px;
  border-radius: 999px;
  background: linear-gradient(90deg, transparent, var(--accent), transparent);
  opacity: 0.9;
}

.podium-card:nth-child(2) {
  animation-delay: 0.1s;
}

.podium-card:nth-child(3) {
  animation-delay: 0.18s;
}

.podium-card.second {
  --accent: rgba(201, 209, 219, 0.7);
  border-color: rgba(201, 209, 219, 0.4);
}

.podium-card.second .place-badge {
  background: rgba(201, 209, 219, 0.2);
  border-color: rgba(201, 209, 219, 0.55);
  color: var(--w-silver-1);
}

.podium-card.third {
  --accent: rgba(192, 122, 67, 0.7);
  border-color: rgba(192, 122, 67, 0.35);
}

.podium-card.third .place-badge {
  background: rgba(192, 122, 67, 0.2);
  border-color: rgba(192, 122, 67, 0.5);
  color: #f2c49b;
}

.place-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 6px 12px;
  border-radius: 999px;
  border: 1px solid rgba(246, 213, 143, 0.45);
  background: rgba(246, 213, 143, 0.12);
  color: #f7e3b7;
  font-size: 11px;
  letter-spacing: 0.3em;
  text-transform: uppercase;
}

.podium-name {
  font-size: 20px;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  word-break: break-word;
}

.podium-handles {
  font-size: 12px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.66);
  word-break: break-word;
}

.podium-note {
  font-size: 11px;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.5);
}

.winners-archive {
  width: min(1000px, 100%);
  display: grid;
  gap: 16px;
  margin-top: 8px;
}

.winners-archive-title {
  font-family: "Cinzel", "Sora", sans-serif;
  font-size: 14px;
  letter-spacing: 0.26em;
  text-transform: uppercase;
  color: rgba(246, 213, 143, 0.88);
}

.archive-grid {
  display: grid;
  gap: 16px;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
}

.archive-card {
  border-radius: 18px;
  border: 1px solid rgba(255, 255, 255, 0.1);
  background: linear-gradient(160deg, rgba(10, 11, 14, 0.82), rgba(18, 20, 28, 0.78));
  padding: 16px;
  display: grid;
  gap: 8px;
  position: relative;
}

.archive-card::before {
  content: "";
  position: absolute;
  inset: 12px;
  border-radius: 12px;
  border: 1px solid rgba(255, 255, 255, 0.05);
  pointer-events: none;
}

.archive-event {
  font-size: 15px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.86);
  word-break: break-word;
}

.archive-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  font-size: 11px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.55);
}

.archive-meta span {
  padding: 4px 8px;
  border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  background: rgba(255, 255, 255, 0.04);
}

.archive-podium {
  display: grid;
  gap: 6px;
  font-size: 12px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.7);
}

.archive-line {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

.archive-place {
  color: var(--w-gold-1);
}

.winners-footer {
  font-size: 12px;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.55);
}

.winners-empty {
  padding: 24px 26px;
  border-radius: 18px;
  border: 1px solid rgba(255, 255, 255, 0.12);
  background: rgba(15, 15, 18, 0.7);
  display: grid;
  gap: 8px;
}

.winners-empty-title {
  font-size: 18px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.winners-empty-note {
  font-size: 12px;
  letter-spacing: 0.12em;
  color: rgba(255, 255, 255, 0.6);
}

/* Winners v3 */
.w3-stage {
  position: relative;
  min-height: 100vh;
  overflow: hidden;
  background: var(--w3-bg-0);
}

.w3-stage::before {
  content: "";
  position: absolute;
  inset: -14%;
  background-image: var(--w3-bg-image, none);
  background-size: cover;
  background-position: center;
  opacity: 0.18;
  filter: saturate(0.9) contrast(1.1);
}

.w3-stage::after {
  content: "";
  position: absolute;
  inset: 0;
  background:
    radial-gradient(circle at 18% 18%, rgba(247, 185, 85, 0.14), transparent 55%),
    radial-gradient(circle at 82% 16%, rgba(199, 134, 84, 0.16), transparent 55%),
    radial-gradient(circle at 70% 82%, rgba(207, 214, 225, 0.12), transparent 60%),
    linear-gradient(180deg, rgba(8, 10, 14, 0.76), rgba(6, 7, 10, 0.96));
}

.w3-shell {
  position: relative;
  z-index: 1;
  width: min(1200px, 100%);
  margin: 0 auto;
  min-height: 100vh;
  padding: 64px 24px 90px;
  display: grid;
  gap: 30px;
  align-content: start;
}

.w3-empty {
  padding: 28px 30px;
  border-radius: 18px;
  border: 1px solid rgba(255, 255, 255, 0.12);
  background: rgba(10, 12, 16, 0.7);
  display: grid;
  gap: 8px;
}

.w3-empty-title {
  font-family: "Bebas Neue", "Space Grotesk", sans-serif;
  font-size: 26px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

.w3-empty-note {
  font-size: 12px;
  letter-spacing: 0.12em;
  color: rgba(255, 255, 255, 0.6);
}

.w3-header {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
}

.w3-brand {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 10px 14px;
  border-radius: 14px;
  border: 1px solid rgba(255, 255, 255, 0.12);
  background: rgba(12, 14, 18, 0.7);
  box-shadow: 0 18px 38px rgba(0, 0, 0, 0.4);
}

.w3-logo {
  width: 52px;
  height: 52px;
  border-radius: 14px;
  display: grid;
  place-items: center;
  background: linear-gradient(145deg, #1c2130, #0d1016);
  border: 1px solid rgba(255, 255, 255, 0.12);
}

.w3-logo img {
  width: 70%;
  height: 70%;
  object-fit: contain;
  display: block;
  filter: brightness(0.85) saturate(0.8);
  opacity: 0.85;
}

.w3-brand-text {
  display: grid;
  gap: 4px;
}

.w3-event {
  font-family: "Cinzel", "Space Grotesk", sans-serif;
  font-size: 12px;
  letter-spacing: 0.26em;
  text-transform: uppercase;
  color: var(--w3-gold-soft);
}

.w3-subtitle {
  font-size: 12px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.64);
}

.w3-header-right {
  display: grid;
  gap: 8px;
  text-align: right;
}

.w3-headline {
  font-size: 11px;
  letter-spacing: 0.34em;
  text-transform: uppercase;
  color: var(--w3-gold);
}

.w3-prize {
  display: inline-flex;
  align-items: baseline;
  gap: 8px;
  padding: 8px 12px;
  border-radius: 999px;
  border: 1px solid rgba(247, 185, 85, 0.35);
  background: rgba(16, 18, 24, 0.7);
}

.w3-prize-label {
  font-size: 10px;
  letter-spacing: 0.28em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.6);
}

.w3-prize-value {
  font-family: "Bebas Neue", "Space Grotesk", sans-serif;
  font-size: 22px;
  letter-spacing: 0.12em;
  color: var(--w3-gold-soft);
}

.w3-prize-suffix {
  font-size: 12px;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.6);
}

.w3-main {
  display: grid;
  gap: 18px;
}

.w3-champion {
  position: relative;
  padding: 30px 34px 34px;
  border-radius: 20px;
  border: 1px solid rgba(255, 255, 255, 0.12);
  background: linear-gradient(140deg, rgba(18, 20, 28, 0.95), rgba(10, 12, 16, 0.95));
  box-shadow: 0 26px 60px rgba(0, 0, 0, 0.5);
  overflow: hidden;
}

.w3-champion::before {
  content: "";
  position: absolute;
  inset: 0;
  background:
    radial-gradient(circle at 12% 20%, rgba(247, 185, 85, 0.12), transparent 60%),
    radial-gradient(circle at 80% 80%, rgba(207, 214, 225, 0.08), transparent 60%);
  opacity: 0.8;
  pointer-events: none;
}

.w3-champ-ribbon {
  font-size: 11px;
  letter-spacing: 0.34em;
  text-transform: uppercase;
  color: var(--w3-gold);
}

.w3-champ-name {
  font-family: "Bebas Neue", "Space Grotesk", sans-serif;
  font-size: clamp(42px, 7vw, 92px);
  letter-spacing: 0.16em;
  text-transform: uppercase;
  background: linear-gradient(90deg, var(--w3-gold-soft), var(--w3-gold), var(--w3-gold-soft));
  -webkit-background-clip: text;
  color: transparent;
  text-shadow: 0 18px 32px rgba(0, 0, 0, 0.5);
  word-break: break-word;
}

.w3-champ-handles {
  font-size: 12px;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.7);
}

.w3-champ-note {
  font-size: 11px;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.5);
}

.w3-champ-rank {
  position: absolute;
  right: 26px;
  top: 18px;
  font-family: "Bebas Neue", "Space Grotesk", sans-serif;
  font-size: 64px;
  color: rgba(255, 255, 255, 0.08);
  letter-spacing: 0.1em;
}

.w3-placements {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 16px;
}

.w3-place-card {
  --accent: var(--w3-silver);
  border-radius: 18px;
  border: 1px solid rgba(255, 255, 255, 0.1);
  background: rgba(12, 14, 18, 0.9);
  padding: 18px 18px 20px;
  display: grid;
  gap: 8px;
  position: relative;
  overflow: hidden;
}

.w3-place-card::after {
  content: "";
  position: absolute;
  top: 0;
  left: 16px;
  right: 16px;
  height: 4px;
  border-radius: 999px;
  background: linear-gradient(90deg, transparent, var(--accent), transparent);
}

.w3-place-card.silver {
  --accent: var(--w3-silver);
  border-color: rgba(207, 214, 225, 0.45);
}

.w3-place-card.bronze {
  --accent: var(--w3-bronze);
  border-color: rgba(199, 134, 84, 0.45);
}

.w3-place-label {
  font-size: 11px;
  letter-spacing: 0.26em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.75);
}

.w3-place-name {
  font-family: "Bebas Neue", "Space Grotesk", sans-serif;
  font-size: 26px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  word-break: break-word;
}

.w3-place-handles {
  font-size: 11px;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.65);
}

.w3-place-note {
  font-size: 10px;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.45);
}

.w3-archive {
  display: grid;
  gap: 14px;
}

.w3-archive-title {
  font-family: "Bebas Neue", "Space Grotesk", sans-serif;
  font-size: 20px;
  letter-spacing: 0.3em;
  text-transform: uppercase;
  color: var(--w3-gold);
}

.w3-archive-grid {
  display: grid;
  gap: 16px;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
}

.w3-archive-card {
  border-radius: 18px;
  border: 1px solid rgba(255, 255, 255, 0.1);
  background: rgba(12, 14, 18, 0.9);
  padding: 16px;
  display: grid;
  gap: 10px;
}

.w3-archive-event {
  font-size: 14px;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.88);
  word-break: break-word;
}

.w3-archive-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.w3-archive-meta span {
  padding: 4px 8px;
  border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  background: rgba(255, 255, 255, 0.04);
  font-size: 11px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.6);
}

.w3-archive-places {
  display: grid;
  gap: 6px;
  font-size: 12px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.75);
}

.w3-archive-places div {
  display: flex;
  align-items: center;
  gap: 10px;
}

.w3-archive-places strong {
  color: var(--w3-gold);
  font-weight: 600;
}

.w3-footer {
  font-size: 11px;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.55);
  text-align: center;
}

@media (max-width: 720px) {
  .w3-shell {
    padding: 48px 16px 64px;
  }

  .w3-header {
    flex-direction: column;
    align-items: flex-start;
  }

  .w3-header-right {
    text-align: left;
  }
}

/* Winners v5 */
.w5-stage {
  position: relative;
  min-height: 100vh;
  overflow: hidden;
  background: var(--w5-bg-0);
  padding: clamp(28px, 4vw, 60px) 0 82px;
}

.w5-stage::before {
  content: "";
  position: absolute;
  inset: -12%;
  background-image: var(--w5-bg-image, none);
  background-size: cover;
  background-position: center;
  filter: grayscale(1) brightness(0.4) contrast(1.15);
  opacity: 0.12;
}

.w5-stage::after {
  content: "";
  position: absolute;
  inset: 0;
  background:
    radial-gradient(circle at 16% 12%, rgba(125, 249, 194, 0.2), transparent 48%),
    radial-gradient(circle at 86% 18%, rgba(255, 178, 94, 0.16), transparent 52%),
    radial-gradient(circle at 24% 78%, rgba(207, 214, 223, 0.12), transparent 55%),
    linear-gradient(180deg, rgba(9, 11, 15, 0.8), rgba(9, 11, 15, 0.98));
  pointer-events: none;
}

.w5-shell {
  position: relative;
  z-index: 1;
  width: min(1120px, 100%);
  margin: 0 auto;
  padding: 0 20px;
  display: grid;
  gap: clamp(22px, 4vw, 34px);
}

.w5-empty {
  min-height: 70vh;
  display: grid;
  place-items: center;
  text-align: center;
  gap: 10px;
  color: var(--w5-muted);
}

.w5-empty-title {
  font-size: clamp(20px, 3vw, 28px);
  font-family: "Unbounded", "Manrope", sans-serif;
  letter-spacing: 0.18em;
  text-transform: uppercase;
}

.w5-empty-note {
  font-size: 14px;
  max-width: 380px;
}

.w5-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  flex-wrap: wrap;
}

.w5-brand {
  display: flex;
  align-items: center;
  gap: 16px;
}

.w5-logo {
  width: 58px;
  height: 58px;
  border-radius: 16px;
  background: linear-gradient(135deg, rgba(125, 249, 194, 0.18), rgba(255, 255, 255, 0.03));
  border: 1px solid var(--w5-line);
  display: grid;
  place-items: center;
  box-shadow: 0 16px 34px rgba(0, 0, 0, 0.35);
}

.w5-logo img {
  width: 70%;
  height: auto;
  filter: brightness(0.75) saturate(0.8);
  opacity: 0.88;
}

.w5-brand-text {
  display: grid;
  gap: 4px;
}

.w5-event {
  font-size: 12px;
  letter-spacing: 0.32em;
  text-transform: uppercase;
  color: var(--w5-muted);
}

.w5-subtitle {
  font-size: 14px;
  color: var(--w5-text);
}

.w5-prize {
  min-width: 180px;
  padding: 12px 16px;
  border-radius: 16px;
  border: 1px solid var(--w5-line);
  background: linear-gradient(135deg, rgba(255, 255, 255, 0.06), rgba(255, 255, 255, 0.02));
  display: grid;
  gap: 4px;
  text-align: right;
  box-shadow: 0 18px 40px rgba(0, 0, 0, 0.35);
}

.w5-prize-label {
  font-size: 11px;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--w5-muted);
}

.w5-prize-value {
  font-size: 22px;
  font-weight: 600;
  letter-spacing: 0.06em;
  color: var(--w5-text);
}

.w5-prize-unit {
  font-size: 12px;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--w5-ember);
}

.w5-hero {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1.2fr);
  gap: 24px;
  align-items: stretch;
}

.w5-hero-text {
  display: grid;
  gap: 12px;
  align-content: center;
}

.w5-title {
  font-family: "Unbounded", "Manrope", sans-serif;
  font-size: clamp(30px, 6vw, 58px);
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--w5-text);
}

.w5-hero-subtitle {
  font-size: 13px;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--w5-muted);
}

.w5-hero-card {
  position: relative;
  overflow: hidden;
  border-radius: 26px;
  padding: clamp(22px, 4vw, 36px);
  background: var(--w5-panel);
  border: 1px solid rgba(255, 255, 255, 0.12);
  box-shadow: var(--w5-shadow);
  clip-path: polygon(0 0, 100% 0, 100% 92%, 94% 100%, 0 100%);
}

.w5-hero-card::before {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(140deg, rgba(125, 249, 194, 0.16), transparent 50%);
  pointer-events: none;
}

.w5-hero-card::after {
  content: "01";
  position: absolute;
  top: -18px;
  right: 18px;
  font-family: "Unbounded", "Manrope", sans-serif;
  font-size: 96px;
  color: rgba(255, 255, 255, 0.08);
  pointer-events: none;
}

.w5-hero-badge {
  position: relative;
  z-index: 1;
  font-size: 12px;
  letter-spacing: 0.3em;
  text-transform: uppercase;
  color: var(--w5-accent);
}

.w5-hero-name {
  position: relative;
  z-index: 1;
  margin-top: 10px;
  font-family: "Unbounded", "Manrope", sans-serif;
  font-size: clamp(34px, 7vw, 70px);
  letter-spacing: 0.08em;
  text-transform: uppercase;
  background: linear-gradient(90deg, var(--w5-silver), var(--w5-accent), var(--w5-ember-soft));
  -webkit-background-clip: text;
  color: transparent;
}

.w5-hero-handles {
  position: relative;
  z-index: 1;
  margin-top: 6px;
  font-size: 13px;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--w5-text);
  opacity: 0.8;
}

.w5-hero-note {
  position: relative;
  z-index: 1;
  margin-top: 12px;
  font-size: 11px;
  letter-spacing: 0.24em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.55);
}

.w5-podium {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(230px, 1fr));
  gap: 16px;
}

.w5-podium-card {
  --accent: var(--w5-silver);
  position: relative;
  border-radius: 18px;
  padding: 18px 20px;
  background: rgba(12, 15, 21, 0.86);
  border: 1px solid rgba(255, 255, 255, 0.08);
  box-shadow: 0 18px 36px rgba(0, 0, 0, 0.35);
}

.w5-podium-card::before {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(120deg, rgba(255, 255, 255, 0.06), transparent 60%);
  pointer-events: none;
}

.w5-podium-card::after {
  content: "";
  position: absolute;
  left: 0;
  top: 0;
  height: 4px;
  width: 100%;
  background: var(--accent);
}

.w5-podium-card.silver { --accent: var(--w5-silver); }
.w5-podium-card.bronze { --accent: var(--w5-bronze); }

.w5-podium-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}

.w5-podium-badge {
  font-size: 11px;
  letter-spacing: 0.26em;
  text-transform: uppercase;
  color: var(--accent);
}

.w5-podium-rank {
  font-size: 26px;
  font-weight: 600;
  color: rgba(255, 255, 255, 0.15);
}

.w5-podium-name {
  margin-top: 8px;
  font-size: 22px;
  font-weight: 600;
  color: var(--w5-text);
}

.w5-podium-handles {
  margin-top: 4px;
  font-size: 12px;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--w5-muted);
}

.w5-podium-note {
  margin-top: 10px;
  font-size: 11px;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.55);
}

.w5-archive {
  display: grid;
  gap: 16px;
}

.w5-archive-title {
  font-family: "Unbounded", "Manrope", sans-serif;
  font-size: 16px;
  letter-spacing: 0.26em;
  text-transform: uppercase;
  color: var(--w5-muted);
}

.w5-archive-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(230px, 1fr));
  gap: 14px;
}

.w5-archive-card {
  border-radius: 16px;
  border: 1px solid rgba(255, 255, 255, 0.06);
  background: rgba(12, 15, 21, 0.74);
  padding: 16px;
  display: grid;
  gap: 10px;
}

.w5-archive-header {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  flex-wrap: wrap;
}

.w5-archive-event {
  font-size: 13px;
  font-weight: 600;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--w5-text);
}

.w5-archive-date {
  font-size: 11px;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--w5-muted);
}

.w5-archive-prize {
  font-size: 12px;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--w5-ember);
}

.w5-archive-places {
  display: grid;
  gap: 8px;
  font-size: 12px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--w5-text);
}

.w5-archive-places div {
  display: flex;
  align-items: center;
  gap: 10px;
}

.w5-archive-rank {
  width: 22px;
  height: 22px;
  border-radius: 8px;
  display: grid;
  place-items: center;
  background: rgba(255, 255, 255, 0.08);
  color: var(--w5-accent);
  font-size: 11px;
}

.w5-footer {
  text-align: center;
  font-size: 11px;
  letter-spacing: 0.24em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.5);
}

.w5-animate {
  animation: w5-rise 0.8s ease both;
}

.w5-delay-1 { animation-delay: 0.1s; }
.w5-delay-2 { animation-delay: 0.2s; }
.w5-delay-3 { animation-delay: 0.3s; }
.w5-delay-4 { animation-delay: 0.4s; }

@keyframes w5-rise {
  from {
    opacity: 0;
    transform: translateY(16px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@media (max-width: 960px) {
  .w5-hero {
    grid-template-columns: 1fr;
  }

  .w5-prize {
    text-align: left;
  }
}

@media (max-width: 720px) {
  .w5-shell {
    padding: 0 16px;
  }

  .w5-top {
    flex-direction: column;
    align-items: flex-start;
  }

  .w5-title {
    letter-spacing: 0.08em;
  }
}

/* Winners v4 */
.w4-stage {
  position: relative;
  min-height: 100vh;
  overflow: hidden;
  background: var(--w4-bg-0);
  padding: clamp(32px, 4vw, 64px) 0 84px;
}

.w4-stage::before {
  content: "";
  position: absolute;
  inset: -10%;
  background-image: var(--w4-bg-image, none);
  background-size: cover;
  background-position: center;
  filter: grayscale(1) brightness(0.5) contrast(1.1);
  opacity: 0.18;
}

.w4-stage::after {
  content: "";
  position: absolute;
  inset: 0;
  background:
    radial-gradient(circle at 12% 12%, rgba(255, 178, 94, 0.16), transparent 46%),
    radial-gradient(circle at 85% 18%, rgba(77, 214, 194, 0.14), transparent 52%),
    radial-gradient(circle at 22% 78%, rgba(207, 214, 223, 0.12), transparent 50%),
    linear-gradient(180deg, rgba(8, 10, 14, 0.6), rgba(8, 10, 14, 0.95));
  pointer-events: none;
}

.w4-shell {
  position: relative;
  z-index: 1;
  width: min(1100px, 100%);
  margin: 0 auto;
  padding: 0 20px;
  display: grid;
  gap: clamp(24px, 4vw, 36px);
}

.w4-empty {
  min-height: 70vh;
  display: grid;
  place-items: center;
  text-align: center;
  gap: 8px;
  color: var(--w4-muted);
}

.w4-empty-title {
  font-size: clamp(20px, 3vw, 28px);
  font-family: "Cinzel", "Space Grotesk", serif;
  letter-spacing: 0.16em;
  text-transform: uppercase;
}

.w4-empty-note {
  font-size: 14px;
  max-width: 360px;
}

.w4-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 28px;
  flex-wrap: wrap;
}

.w4-brand {
  display: flex;
  align-items: center;
  gap: 16px;
}

.w4-mark {
  width: 56px;
  height: 56px;
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid var(--w4-border);
  display: grid;
  place-items: center;
  box-shadow: 0 12px 30px rgba(0, 0, 0, 0.35);
}

.w4-mark img {
  width: 68%;
  height: auto;
  filter: brightness(0.8) saturate(0.75);
  opacity: 0.85;
}

.w4-brand-text {
  display: grid;
  gap: 4px;
}

.w4-event {
  font-size: 12px;
  letter-spacing: 0.34em;
  text-transform: uppercase;
  color: var(--w4-muted);
}

.w4-subtitle {
  font-size: 14px;
  color: var(--w4-ice);
}

.w4-title-block {
  display: grid;
  gap: 10px;
  text-align: right;
}

.w4-title {
  font-family: "Cinzel", "Bebas Neue", serif;
  font-size: clamp(28px, 5vw, 46px);
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--w4-ember-soft);
}

.w4-prize {
  display: inline-flex;
  align-items: baseline;
  gap: 10px;
  padding: 10px 18px;
  border-radius: 999px;
  border: 1px solid var(--w4-border);
  background: rgba(255, 255, 255, 0.04);
  color: var(--w4-muted);
  font-size: 13px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  justify-content: flex-end;
}

.w4-prize-label {
  font-size: 11px;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--w4-muted);
}

.w4-prize-value {
  font-size: 20px;
  font-weight: 600;
  letter-spacing: 0.06em;
  color: var(--w4-text);
}

.w4-prize-unit {
  color: var(--w4-ember);
  font-weight: 600;
}

.w4-hero {
  display: grid;
}

.w4-hero-card {
  position: relative;
  overflow: hidden;
  border-radius: 28px;
  padding: clamp(28px, 5vw, 48px);
  background: linear-gradient(135deg, rgba(255, 178, 94, 0.12), rgba(15, 18, 27, 0.95));
  border: 1px solid rgba(255, 255, 255, 0.12);
  box-shadow: var(--w4-shadow);
}

.w4-hero-card::before {
  content: "";
  position: absolute;
  inset: 0;
  background: radial-gradient(circle at 20% 20%, rgba(255, 178, 94, 0.28), transparent 48%);
  opacity: 0.8;
  pointer-events: none;
}

.w4-hero-card::after {
  content: "";
  position: absolute;
  top: -70px;
  right: -40px;
  width: 220px;
  height: 220px;
  border-radius: 50%;
  border: 1px solid rgba(255, 255, 255, 0.08);
  background: radial-gradient(circle at center, rgba(255, 178, 94, 0.2), transparent 60%);
  pointer-events: none;
}

.w4-hero-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  position: relative;
  z-index: 1;
}

.w4-hero-badge {
  font-size: 12px;
  letter-spacing: 0.32em;
  text-transform: uppercase;
  color: var(--w4-ember);
}

.w4-hero-rank {
  font-size: 56px;
  font-weight: 600;
  color: rgba(255, 255, 255, 0.12);
}

.w4-hero-name {
  position: relative;
  z-index: 1;
  margin-top: 6px;
  font-family: "Bebas Neue", "Oswald", sans-serif;
  font-size: clamp(42px, 9vw, 92px);
  letter-spacing: 0.08em;
  text-transform: uppercase;
  background: linear-gradient(90deg, #ffe1b8, #ffb25e, #ffd6a1);
  -webkit-background-clip: text;
  color: transparent;
}

.w4-hero-handles {
  position: relative;
  z-index: 1;
  margin-top: 6px;
  font-size: 14px;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--w4-ice);
}

.w4-hero-note {
  position: relative;
  z-index: 1;
  margin-top: 14px;
  font-size: 12px;
  letter-spacing: 0.24em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.55);
}

.w4-podium {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 18px;
}

.w4-podium-card {
  --accent: var(--w4-ice);
  position: relative;
  overflow: hidden;
  border-radius: 20px;
  padding: 20px 22px;
  background: rgba(12, 14, 20, 0.82);
  border: 1px solid rgba(255, 255, 255, 0.08);
  box-shadow: 0 18px 36px rgba(0, 0, 0, 0.35);
}

.w4-podium-card::before {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(145deg, rgba(255, 255, 255, 0.05), transparent 70%);
  pointer-events: none;
}

.w4-podium-card.silver {
  --accent: var(--w4-ice);
}

.w4-podium-card.bronze {
  --accent: var(--w4-bronze);
}

.w4-podium-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}

.w4-podium-badge {
  font-size: 11px;
  letter-spacing: 0.24em;
  text-transform: uppercase;
  color: var(--accent);
}

.w4-podium-rank {
  font-size: 30px;
  font-weight: 600;
  color: rgba(255, 255, 255, 0.16);
}

.w4-podium-name {
  margin-top: 8px;
  font-size: 24px;
  font-weight: 600;
  color: var(--w4-text);
}

.w4-podium-handles {
  margin-top: 4px;
  font-size: 13px;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--w4-muted);
}

.w4-podium-note {
  margin-top: 10px;
  font-size: 11px;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.55);
}

.w4-archive {
  display: grid;
  gap: 16px;
}

.w4-archive-title {
  font-family: "Cinzel", "Space Grotesk", serif;
  font-size: 18px;
  letter-spacing: 0.28em;
  text-transform: uppercase;
  color: var(--w4-muted);
}

.w4-archive-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(230px, 1fr));
  gap: 14px;
}

.w4-archive-card {
  border-radius: 18px;
  border: 1px solid rgba(255, 255, 255, 0.06);
  background: rgba(12, 14, 20, 0.7);
  padding: 16px;
  display: grid;
  gap: 10px;
}

.w4-archive-header {
  display: flex;
  justify-content: space-between;
  gap: 8px;
  flex-wrap: wrap;
}

.w4-archive-event {
  font-size: 14px;
  font-weight: 600;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--w4-text);
}

.w4-archive-date {
  font-size: 12px;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--w4-muted);
}

.w4-archive-prize {
  font-size: 13px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--w4-ember);
}

.w4-archive-places {
  display: grid;
  gap: 8px;
  font-size: 13px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--w4-text);
}

.w4-archive-places div {
  display: flex;
  align-items: center;
  gap: 10px;
}

.w4-archive-rank {
  width: 22px;
  height: 22px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  background: rgba(255, 255, 255, 0.08);
  color: var(--w4-ember-soft);
  font-size: 11px;
}

.w4-footer {
  text-align: center;
  font-size: 11px;
  letter-spacing: 0.24em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.55);
}

.w4-animate {
  animation: w4-rise 0.8s ease both;
}

.w4-delay-1 { animation-delay: 0.12s; }
.w4-delay-2 { animation-delay: 0.2s; }
.w4-delay-3 { animation-delay: 0.28s; }
.w4-delay-4 { animation-delay: 0.36s; }

@keyframes w4-rise {
  from {
    opacity: 0;
    transform: translateY(18px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@media (max-width: 960px) {
  .w4-title-block {
    text-align: left;
  }

  .w4-prize {
    justify-content: flex-start;
  }
}

@media (max-width: 720px) {
  .w4-shell {
    padding: 0 16px;
  }

  .w4-top {
    flex-direction: column;
    align-items: flex-start;
  }

  .w4-title {
    letter-spacing: 0.12em;
  }

  .w4-hero-rank {
    font-size: 44px;
  }

  .w4-hero-name {
    letter-spacing: 0.05em;
  }
}

/* Winners v2 */
.w2-stage {
  position: relative;
  min-height: 100vh;
  overflow: hidden;
  background: var(--w-bg-0);
}

.w2-stage::before {
  content: "";
  position: absolute;
  inset: -12%;
  background-image: var(--w-bg-image, none);
  background-size: cover;
  background-position: center;
  opacity: 0.22;
  filter: saturate(0.9) contrast(1.1);
}

.w2-stage::after {
  content: "";
  position: absolute;
  inset: 0;
  background:
    radial-gradient(circle at 18% 16%, rgba(255, 159, 67, 0.18), transparent 55%),
    radial-gradient(circle at 82% 20%, rgba(191, 122, 74, 0.18), transparent 55%),
    radial-gradient(circle at 70% 82%, rgba(201, 207, 216, 0.16), transparent 60%),
    linear-gradient(180deg, rgba(8, 9, 12, 0.76), rgba(6, 7, 10, 0.96));
}

.w2-layout {
  position: relative;
  z-index: 1;
  width: min(1200px, 100%);
  margin: 0 auto;
  min-height: 100vh;
  padding: 64px 24px 84px;
  display: grid;
  gap: 28px;
  align-content: start;
}

.w2-empty {
  padding: 28px 30px;
  border-radius: 18px;
  border: 1px solid rgba(255, 255, 255, 0.12);
  background: rgba(10, 11, 14, 0.7);
  display: grid;
  gap: 8px;
}

.w2-empty-title {
  font-family: "Bebas Neue", "Oswald", sans-serif;
  font-size: 24px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.w2-empty-note {
  font-size: 12px;
  letter-spacing: 0.12em;
  color: rgba(255, 255, 255, 0.6);
}

.w2-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  flex-wrap: wrap;
}

.w2-mark {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 10px 14px;
  border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, 0.12);
  background: rgba(10, 12, 16, 0.72);
  box-shadow: 0 16px 36px rgba(0, 0, 0, 0.4);
}

.w2-logo {
  width: 52px;
  height: 52px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  background: radial-gradient(circle at 30% 20%, rgba(44, 48, 58, 0.95), rgba(14, 16, 20, 0.9));
  border: 1px solid rgba(255, 255, 255, 0.14);
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.04), 0 10px 24px rgba(0, 0, 0, 0.45);
  position: relative;
}

.w2-logo img {
  width: 70%;
  height: 70%;
  object-fit: contain;
  display: block;
  filter: brightness(0.85) saturate(0.8) contrast(1.05);
  opacity: 0.85;
}

.w2-logo::after {
  content: "";
  position: absolute;
  inset: 6px;
  border-radius: 50%;
  border: 1px solid rgba(255, 255, 255, 0.08);
  pointer-events: none;
}

.w2-mark-text {
  display: grid;
  gap: 4px;
}

.w2-event {
  font-family: "Cinzel", "Sora", sans-serif;
  font-size: 12px;
  letter-spacing: 0.24em;
  text-transform: uppercase;
  color: var(--w-gold-1);
}

.w2-subtitle {
  font-size: 12px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.68);
}

.w2-prize-chip {
  padding: 10px 16px 12px;
  border-radius: 14px;
  border: 1px solid rgba(255, 159, 67, 0.35);
  background: linear-gradient(145deg, rgba(20, 16, 12, 0.85), rgba(12, 14, 18, 0.82));
  display: grid;
  gap: 4px;
  text-align: right;
}

.w2-prize-label {
  font-size: 10px;
  letter-spacing: 0.24em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.6);
}

.w2-prize-value {
  font-family: "Bebas Neue", "Oswald", sans-serif;
  font-size: 22px;
  letter-spacing: 0.12em;
  color: var(--w-gold-3);
}

.w2-prize-value span {
  font-size: 12px;
  letter-spacing: 0.26em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.65);
}

.w2-champion {
  display: grid;
  grid-template-columns: 90px minmax(0, 1fr);
  gap: 18px;
  align-items: stretch;
}

.w2-rank {
  border-radius: 18px;
  border: 1px solid rgba(255, 159, 67, 0.42);
  background: linear-gradient(160deg, rgba(255, 159, 67, 0.18), rgba(10, 12, 16, 0.9));
  display: grid;
  place-items: center;
  font-family: "Bebas Neue", "Oswald", sans-serif;
  font-size: 64px;
  color: var(--w-gold-3);
}

.w2-card {
  border-radius: 22px;
  padding: 26px 28px 28px;
  border: 1px solid rgba(255, 255, 255, 0.12);
  background: linear-gradient(135deg, rgba(18, 20, 26, 0.94), rgba(10, 12, 16, 0.95));
  display: grid;
  gap: 10px;
  position: relative;
  overflow: hidden;
}

.w2-card::after {
  content: "";
  position: absolute;
  inset: 14px;
  border-radius: 16px;
  border: 1px solid rgba(255, 255, 255, 0.05);
  pointer-events: none;
}

.w2-headline {
  font-size: 11px;
  letter-spacing: 0.34em;
  text-transform: uppercase;
  color: var(--w-gold-1);
}

.w2-name {
  font-family: "Bebas Neue", "Oswald", sans-serif;
  font-size: clamp(40px, 7vw, 84px);
  letter-spacing: 0.14em;
  text-transform: uppercase;
  background: linear-gradient(90deg, var(--w-gold-3), var(--w-gold-2), var(--w-gold-3));
  -webkit-background-clip: text;
  color: transparent;
  text-shadow: 0 14px 28px rgba(0, 0, 0, 0.45);
  word-break: break-word;
}

.w2-handles {
  font-size: 12px;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.7);
  word-break: break-word;
}

.w2-note {
  font-size: 11px;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.5);
}

.w2-podium {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 16px;
}

.w2-place {
  --accent: var(--w-silver-2);
  border-radius: 18px;
  border: 1px solid rgba(255, 255, 255, 0.1);
  background: linear-gradient(160deg, rgba(14, 16, 22, 0.94), rgba(10, 12, 16, 0.94));
  padding: 18px 18px 20px;
  display: grid;
  gap: 8px;
  position: relative;
  overflow: hidden;
}

.w2-place::after {
  content: "";
  position: absolute;
  top: 0;
  left: 16px;
  right: 16px;
  height: 4px;
  border-radius: 999px;
  background: linear-gradient(90deg, transparent, var(--accent), transparent);
}

.w2-place.silver {
  --accent: var(--w-silver-2);
  border-color: rgba(195, 204, 215, 0.5);
  background: linear-gradient(160deg, rgba(16, 18, 24, 0.96), rgba(10, 12, 16, 0.94));
}

.w2-place.bronze {
  --accent: var(--w-bronze-2);
  border-color: rgba(191, 122, 74, 0.5);
  background: linear-gradient(160deg, rgba(22, 16, 12, 0.94), rgba(10, 10, 12, 0.94));
}

.w2-place-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 6px 10px;
  border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, 0.14);
  background: rgba(255, 255, 255, 0.06);
  font-size: 11px;
  letter-spacing: 0.24em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.8);
  width: fit-content;
}

.w2-place-name {
  font-family: "Bebas Neue", "Oswald", sans-serif;
  font-size: 26px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  word-break: break-word;
}

.w2-place-handles {
  font-size: 11px;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.65);
  word-break: break-word;
}

.w2-place-note {
  font-size: 10px;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.45);
}

.w2-archive {
  display: grid;
  gap: 14px;
}

.w2-archive-title {
  font-family: "Bebas Neue", "Oswald", sans-serif;
  font-size: 20px;
  letter-spacing: 0.28em;
  text-transform: uppercase;
  color: var(--w-gold-1);
}

.w2-archive-grid {
  display: grid;
  gap: 16px;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
}

.w2-archive-card {
  border-radius: 18px;
  border: 1px solid rgba(255, 255, 255, 0.1);
  background: linear-gradient(160deg, rgba(12, 14, 18, 0.94), rgba(18, 20, 28, 0.86));
  padding: 16px;
  display: grid;
  gap: 10px;
  position: relative;
}

.w2-archive-event {
  font-size: 14px;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.88);
  word-break: break-word;
}

.w2-archive-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.w2-archive-meta span {
  padding: 4px 8px;
  border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  background: rgba(255, 255, 255, 0.04);
  font-size: 11px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.6);
}

.w2-archive-places {
  display: grid;
  gap: 6px;
  font-size: 12px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.75);
}

.w2-archive-places div {
  display: flex;
  align-items: center;
  gap: 10px;
}

.w2-archive-places strong {
  color: var(--w-gold-1);
  font-weight: 600;
}

.w2-footer {
  font-size: 11px;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.55);
  text-align: center;
}

.w2-animate {
  animation: w2-fade-up 0.6s ease both;
}

@keyframes w2-fade-up {
  from {
    opacity: 0;
    transform: translateY(14px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes winners-pop {
  from {
    opacity: 0;
    transform: translateY(12px) scale(0.98);
  }
  to {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

@keyframes winners-rise {
  from {
    opacity: 0;
    transform: translateY(12px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@media (max-width: 1100px) {
  .shell {
    grid-template-columns: 1fr;
    gap: 12px;
  }

  .sidebar {
    position: relative;
    height: auto;
  }

  .nav {
    flex-direction: row;
    flex-wrap: wrap;
    gap: 4px;
  }

  .nav a {
    flex: 0 1 auto;
    min-width: 120px;
    text-align: center;
  }

  .field-row {
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  }

  .embed-builder {
    grid-template-columns: 1fr;
  }

  .embed-preview {
    position: relative;
    top: 0;
  }
}

@media (max-width: 720px) {
  .top {
    flex-direction: column;
    align-items: flex-start;
    gap: 12px;
  }

  .page-head {
    flex-direction: column;
    align-items: flex-start;
  }

  .nav {
    flex-direction: column;
  }

  .field-row {
    grid-template-columns: 1fr;
  }

  .table {
    font-size: 12px;
  }

  .winners-shell {
    padding: 32px 16px 48px;
  }

  .winners-header {
    flex-direction: column;
    text-align: center;
  }

  .winners-meta {
    text-align: center;
  }

  .winners-hero {
    padding: 22px 18px 24px;
  }

  .w2-layout {
    padding: 48px 16px 60px;
  }

  .w2-top {
    flex-direction: column;
    align-items: flex-start;
  }

  .w2-mark {
    width: 100%;
    justify-content: center;
    text-align: center;
  }

  .w2-prize-chip {
    width: 100%;
    text-align: left;
  }

  .w2-champion {
    grid-template-columns: 1fr;
  }

  .w2-rank {
    height: 72px;
    font-size: 48px;
  }

  .server-picker-page {
    gap: 8px;
  }

  .server-picker-top {
    padding: 4px 0;
    flex-direction: column;
    align-items: flex-start;
  }

  .server-picker {
    margin-top: 0;
    padding: 16px 14px;
    border-radius: 14px;
  }

  .server-picker-head {
    flex-direction: column;
    align-items: flex-start;
  }

  .server-picker-user {
    max-width: 100%;
  }

  .server-row {
    grid-template-columns: 40px minmax(0, 1fr) 16px;
    gap: 10px;
    padding: 9px 11px;
  }

  .server-row-name {
    font-size: 14px;
  }

  .server-row-state {
    display: none;
  }
}

@media (prefers-reduced-motion: reduce) {
  .main,
  .stagger > .card {
    animation: none;
  }

  .card,
  .btn {
    transition: none;
  }

  .winners-hero,
  .podium-card {
    animation: none;
  }

  .w2-animate {
    animation: none;
  }

  .server-row {
    animation: none;
  }
}

@media (prefers-reduced-motion: reduce) {
  .w4-animate {
    animation: none;
  }
}

@media (prefers-reduced-motion: reduce) {
  .w5-animate {
    animation: none;
  }
}
