/* =====================================================
   ZDVAL Admin Panel
   AAA+ esports-grade dashboard
   ===================================================== */

:root {
  --adm-bg-0: #070910;
  --adm-bg-1: #0b0f18;
  --adm-bg-2: #111624;
  --adm-bg-3: #161c2c;
  --adm-border: rgba(255,255,255,0.06);
  --adm-border-hi: rgba(255,255,255,0.12);
  --adm-txt: #e6eaf3;
  --adm-txt-dim: #8a93a8;
  --adm-txt-mute: #5a6377;
  --adm-red: #ff4655;
  --adm-red-hi: #ff5b6c;
  --adm-red-lo: #c42a3a;
  --adm-cyan: #00d4ff;
  --adm-green: #1dd18a;
  --adm-gold: #ffb93b;
  --adm-violet: #8b7dff;
  --adm-radius: 12px;
  --adm-radius-lg: 16px;
  --adm-shadow-sm: 0 2px 8px rgba(0,0,0,0.25);
  --adm-shadow: 0 10px 28px rgba(0,0,0,0.45);
  --adm-grad-side: linear-gradient(180deg, #0b0f18 0%, #080b13 100%);
  --adm-grad-card: linear-gradient(180deg, #141a28 0%, #10151f 100%);
  --adm-grad-red: linear-gradient(135deg, #ff4655 0%, #c42a3a 100%);
}

* { box-sizing: border-box; }
html, body { margin: 0; padding: 0; height: 100%; }
body {
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
  background: var(--adm-bg-0);
  color: var(--adm-txt);
  font-size: 14px;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: hidden;
}
body::before {
  content: '';
  position: fixed; inset: 0;
  background:
    radial-gradient(ellipse 60% 40% at 15% 0%, rgba(255,70,85,0.08), transparent 60%),
    radial-gradient(ellipse 50% 40% at 85% 100%, rgba(139,125,255,0.06), transparent 60%);
  pointer-events: none;
  z-index: 0;
}

/* ── Boot / loading ─────────────────────────────────── */
.adm-loading {
  position: fixed; inset: 0;
  display: grid; place-items: center;
  background: var(--adm-bg-0);
  z-index: 10;
}
.adm-boot-spinner {
  width: 64px; height: 64px;
  border-radius: 18px;
  background: var(--adm-grad-red);
  display: grid; place-items: center;
  color: #fff;
  font-size: 26px;
  box-shadow: 0 12px 30px rgba(255,70,85,0.4);
  animation: admPulse 1.6s ease-in-out infinite;
}
@keyframes admPulse {
  0%, 100% { transform: scale(1); opacity: 1; }
  50% { transform: scale(0.92); opacity: 0.7; }
}

/* ── Layout root ────────────────────────────────────── */
.adm-shell {
  display: grid;
  grid-template-columns: 260px 1fr;
  min-height: 100vh;
  position: relative;
  z-index: 1;
}

/* ── Sidebar ────────────────────────────────────────── */
.adm-side {
  background: var(--adm-grad-side);
  border-right: 1px solid var(--adm-border);
  padding: 24px 16px;
  display: flex;
  flex-direction: column;
  gap: 4px;
  position: sticky;
  top: 0;
  height: 100vh;
  overflow-y: auto;
}
.adm-brand {
  display: flex; align-items: center; gap: 12px;
  padding: 8px 10px 20px;
  border-bottom: 1px solid var(--adm-border);
  margin-bottom: 16px;
}
.adm-brand-logo {
  width: 40px; height: 40px;
  border-radius: 10px;
  background: var(--adm-grad-red);
  display: grid; place-items: center;
  color: #fff;
  font-size: 18px;
  box-shadow: 0 6px 16px rgba(255,70,85,0.35);
}
.adm-brand-text { line-height: 1.1; }
.adm-brand-text b { display: block; font-weight: 800; font-size: 14px; letter-spacing: 0.3px; }
.adm-brand-text span { font-size: 10px; color: var(--adm-txt-dim); letter-spacing: 0.15em; text-transform: uppercase; }

.adm-nav-label {
  font-size: 10px;
  color: var(--adm-txt-mute);
  letter-spacing: 0.15em;
  text-transform: uppercase;
  padding: 14px 12px 6px;
  font-weight: 700;
}
.adm-nav-item {
  display: flex; align-items: center; gap: 12px;
  padding: 10px 12px;
  border-radius: 10px;
  color: var(--adm-txt-dim);
  cursor: pointer;
  transition: all 0.18s ease;
  font-size: 13px;
  font-weight: 500;
  border: 1px solid transparent;
  user-select: none;
}
.adm-nav-item:hover {
  color: var(--adm-txt);
  background: rgba(255,255,255,0.03);
}
.adm-nav-item i { width: 18px; text-align: center; font-size: 14px; }
.adm-nav-item.active {
  color: #fff;
  background: linear-gradient(135deg, rgba(255,70,85,0.16), rgba(255,70,85,0.04));
  border-color: rgba(255,70,85,0.25);
  box-shadow: inset 0 0 0 1px rgba(255,70,85,0.08);
}
.adm-nav-item.active i { color: var(--adm-red-hi); }

.adm-side-foot {
  margin-top: auto;
  padding-top: 14px;
  border-top: 1px solid var(--adm-border);
  display: flex; align-items: center; gap: 10px;
  font-size: 12px;
}
.adm-side-foot img {
  width: 34px; height: 34px; border-radius: 50%;
  object-fit: cover;
  border: 2px solid var(--adm-border-hi);
}
.adm-side-foot-info b { color: #fff; display: block; font-size: 12px; }
.adm-side-foot-info span { color: var(--adm-txt-dim); font-size: 10px; letter-spacing: 0.08em; text-transform: uppercase; }
.adm-logout {
  margin-left: auto;
  background: transparent;
  border: 1px solid var(--adm-border);
  color: var(--adm-txt-dim);
  width: 32px; height: 32px;
  border-radius: 8px;
  cursor: pointer;
  display: grid; place-items: center;
  transition: all 0.18s;
}
.adm-logout:hover { color: var(--adm-red); border-color: var(--adm-red); }

/* ── Main ───────────────────────────────────────────── */
.adm-main {
  padding: 28px 32px 64px;
  min-width: 0;
}

/* Academy iframe container (embeds /painelcoach) */
.adm-academy-frame-wrap {
  margin: -28px -32px -64px;
  height: calc(100vh - 0px);
  min-height: calc(100vh - 0px);
  background: var(--adm-bg-0, #0a0d14);
}
.adm-academy-frame {
  width: 100%;
  height: 100%;
  border: 0;
  display: block;
}
.adm-page-head {
  display: flex; align-items: flex-end; justify-content: space-between;
  gap: 20px;
  margin-bottom: 26px;
  flex-wrap: wrap;
}
.adm-page-head h1 {
  margin: 0;
  font-size: 26px;
  font-weight: 800;
  letter-spacing: -0.3px;
  color: #fff;
  display: flex; align-items: center; gap: 12px;
}
.adm-page-head h1 i {
  font-size: 20px;
  color: var(--adm-red-hi);
  background: rgba(255,70,85,0.1);
  width: 40px; height: 40px;
  border-radius: 10px;
  display: grid; place-items: center;
}
.adm-page-head p {
  margin: 4px 0 0;
  color: var(--adm-txt-dim);
  font-size: 13px;
}

/* ── Stats grid ─────────────────────────────────────── */
.adm-stats {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 14px;
  margin-bottom: 26px;
}
.adm-stat {
  background: var(--adm-grad-card);
  border: 1px solid var(--adm-border);
  border-radius: var(--adm-radius);
  padding: 18px 20px;
  position: relative;
  overflow: hidden;
  transition: transform 0.2s, border-color 0.2s;
}
.adm-stat:hover { transform: translateY(-2px); border-color: var(--adm-border-hi); }
.adm-stat-icon {
  position: absolute; top: 14px; right: 14px;
  width: 36px; height: 36px;
  border-radius: 9px;
  display: grid; place-items: center;
  font-size: 14px;
  opacity: 0.9;
}
.adm-stat-icon.red    { background: rgba(255,70,85,0.12); color: var(--adm-red-hi); }
.adm-stat-icon.cyan   { background: rgba(0,212,255,0.1);  color: var(--adm-cyan); }
.adm-stat-icon.green  { background: rgba(29,209,138,0.1); color: var(--adm-green); }
.adm-stat-icon.gold   { background: rgba(255,185,59,0.1); color: var(--adm-gold); }
.adm-stat-icon.violet { background: rgba(139,125,255,0.1); color: var(--adm-violet); }
.adm-stat-label {
  font-size: 10px;
  color: var(--adm-txt-mute);
  letter-spacing: 0.15em;
  text-transform: uppercase;
  font-weight: 700;
}
.adm-stat-value {
  font-size: 28px;
  font-weight: 800;
  color: #fff;
  margin-top: 6px;
  letter-spacing: -0.3px;
}
.adm-stat-sub { font-size: 11px; color: var(--adm-txt-dim); margin-top: 2px; }

/* ── Card / section ─────────────────────────────────── */
.adm-card {
  background: var(--adm-grad-card);
  border: 1px solid var(--adm-border);
  border-radius: var(--adm-radius);
  padding: 20px 22px;
  margin-bottom: 18px;
}
.adm-card-head {
  display: flex; align-items: center; justify-content: space-between;
  margin-bottom: 16px;
  gap: 12px;
}
.adm-card-head h3 {
  margin: 0;
  font-size: 14px;
  font-weight: 700;
  color: #fff;
  display: flex; align-items: center; gap: 10px;
}
.adm-card-head h3 i { color: var(--adm-red-hi); font-size: 13px; }
.adm-card-head-right { display: flex; gap: 10px; align-items: center; }

.adm-collapsible .adm-card-head {
  margin-bottom: 0;
}

.adm-collapsible-body {
  margin-top: 16px;
}

.adm-collapsible.is-collapsed .adm-collapsible-body {
  display: none;
}

.adm-card-collapse-btn {
  width: 30px;
  height: 30px;
  border-radius: 8px;
  border: 1px solid var(--adm-border);
  background: rgba(255,255,255,0.03);
  color: var(--adm-txt-dim);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.18s ease;
}

.adm-card-collapse-btn:hover {
  border-color: var(--adm-border-hi);
  color: var(--adm-txt);
  background: rgba(255,255,255,0.06);
}

.adm-card-collapse-btn i {
  transition: transform 0.18s ease;
}

.adm-collapsible:not(.is-collapsed) .adm-card-collapse-btn i {
  transform: rotate(180deg);
}

/* ── Controls ───────────────────────────────────────── */
.adm-input, .adm-select {
  background: #0d1220;
  border: 1px solid var(--adm-border);
  color: var(--adm-txt);
  padding: 8px 12px;
  border-radius: 8px;
  font-size: 13px;
  font-family: inherit;
  outline: none;
  transition: border-color 0.18s, background 0.18s;
  color-scheme: dark;
}
.adm-input:focus, .adm-select:focus {
  border-color: rgba(255,70,85,0.4);
  background: #101523;
}
.adm-input::placeholder { color: var(--adm-txt-mute); }

.adm-btn {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 8px 14px;
  border-radius: 8px;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.03em;
  cursor: pointer;
  border: 1px solid var(--adm-border);
  background: rgba(255,255,255,0.03);
  color: var(--adm-txt);
  transition: all 0.18s;
  font-family: inherit;
}
.adm-btn:hover { background: rgba(255,255,255,0.06); border-color: var(--adm-border-hi); }
.adm-btn-primary {
  background: var(--adm-grad-red);
  border-color: transparent;
  color: #fff;
  box-shadow: 0 6px 18px rgba(255,70,85,0.3);
}
.adm-btn-primary:hover { filter: brightness(1.08); transform: translateY(-1px); }
.adm-btn-danger {
  background: rgba(255,70,85,0.1);
  border-color: rgba(255,70,85,0.3);
  color: var(--adm-red-hi);
}
.adm-btn-danger:hover { background: rgba(255,70,85,0.18); }
.adm-btn-sm { padding: 5px 10px; font-size: 11px; }
.adm-btn-ghost { background: transparent; }

/* ── Table ──────────────────────────────────────────── */
.adm-table-wrap { overflow-x: auto; border-radius: 10px; border: 1px solid var(--adm-border); }
.adm-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 13px;
  min-width: 680px;
}
.adm-table th {
  text-align: left;
  font-size: 10px;
  color: var(--adm-txt-mute);
  letter-spacing: 0.15em;
  text-transform: uppercase;
  font-weight: 700;
  padding: 12px 16px;
  background: rgba(255,255,255,0.02);
  border-bottom: 1px solid var(--adm-border);
}
.adm-table td {
  padding: 12px 16px;
  border-bottom: 1px solid var(--adm-border);
  vertical-align: middle;
}
.adm-table tbody tr:hover { background: rgba(255,255,255,0.015); }
.adm-table tbody tr:last-child td { border-bottom: none; }

.adm-user-cell {
  display: flex; align-items: center; gap: 10px;
}
.adm-user-cell img {
  width: 32px; height: 32px;
  border-radius: 8px;
  object-fit: cover;
  border: 1px solid var(--adm-border);
}
.adm-user-cell b { color: #fff; font-weight: 600; display: block; line-height: 1.2; }
.adm-user-cell span { color: var(--adm-txt-dim); font-size: 11px; }

/* ── Role badge ─────────────────────────────────────── */
.adm-role {
  display: inline-flex; align-items: center; gap: 6px;
  padding: 4px 10px;
  border-radius: 5px;
  font-size: 10px;
  font-weight: 800;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  border: 1px solid transparent;
}
.adm-role.super_admin { background: rgba(255,70,85,0.12);  color: var(--adm-red-hi); border-color: rgba(255,70,85,0.25); }
.adm-role.moderator   { background: rgba(255,185,59,0.12); color: var(--adm-gold);   border-color: rgba(255,185,59,0.25); }
.adm-role.player      { background: rgba(0,212,255,0.1);   color: var(--adm-cyan);   border-color: rgba(0,212,255,0.2); }

.adm-status-dot {
  display: inline-block;
  width: 7px; height: 7px;
  border-radius: 50%;
  margin-right: 6px;
}
.adm-status-dot.on  { background: var(--adm-green); box-shadow: 0 0 6px var(--adm-green); }
.adm-status-dot.off { background: #555c70; }

/* ── Permissions matrix ─────────────────────────────── */
.adm-perm-group {
  margin-bottom: 22px;
}
.adm-perm-group-head {
  font-size: 11px;
  color: var(--adm-red-hi);
  letter-spacing: 0.2em;
  text-transform: uppercase;
  font-weight: 800;
  margin-bottom: 10px;
  padding-bottom: 8px;
  border-bottom: 1px solid rgba(255,70,85,0.15);
}
.adm-perm-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 13px;
}
.adm-perm-table th {
  padding: 10px 12px;
  text-align: center;
  font-size: 10px;
  color: var(--adm-txt-mute);
  letter-spacing: 0.15em;
  text-transform: uppercase;
  font-weight: 700;
  background: rgba(255,255,255,0.02);
}
.adm-perm-table th:first-child { text-align: left; }
.adm-perm-table td {
  padding: 10px 12px;
  border-bottom: 1px solid var(--adm-border);
  text-align: center;
}
.adm-perm-table td:first-child { text-align: left; }
.adm-perm-table tbody tr:last-child td { border-bottom: none; }
.adm-perm-name {
  font-weight: 500;
  color: var(--adm-txt);
  display: flex; align-items: center; gap: 8px;
}
.adm-perm-name i.danger { color: var(--adm-red); font-size: 10px; }
.adm-perm-unavailable { color: var(--adm-txt-mute); font-size: 16px; }

/* toggle */
.adm-toggle {
  position: relative;
  display: inline-block;
  width: 40px; height: 22px;
  cursor: pointer;
}
.adm-toggle input { opacity: 0; width: 0; height: 0; }
.adm-toggle-slider {
  position: absolute; inset: 0;
  background: #1a2132;
  border: 1px solid var(--adm-border);
  border-radius: 22px;
  transition: 0.22s;
}
.adm-toggle-slider::before {
  content: '';
  position: absolute;
  height: 14px; width: 14px;
  left: 3px; top: 50%;
  transform: translateY(-50%);
  background: #6a7288;
  border-radius: 50%;
  transition: 0.22s;
}
.adm-toggle input:checked + .adm-toggle-slider {
  background: rgba(255,70,85,0.2);
  border-color: rgba(255,70,85,0.5);
}
.adm-toggle input:checked + .adm-toggle-slider::before {
  transform: translate(18px, -50%);
  background: var(--adm-red-hi);
  box-shadow: 0 0 8px rgba(255,70,85,0.6);
}
.adm-toggle input:disabled + .adm-toggle-slider {
  opacity: 0.4;
  cursor: not-allowed;
}

/* ── Recent activity list ──────────────────────────── */
.adm-mini-list { display: flex; flex-direction: column; gap: 8px; }
.adm-mini-row {
  display: flex; align-items: center; gap: 12px;
  padding: 10px 12px;
  background: rgba(255,255,255,0.02);
  border: 1px solid var(--adm-border);
  border-radius: 9px;
  font-size: 12px;
}
.adm-mini-row img { width: 28px; height: 28px; border-radius: 7px; object-fit: cover; }
.adm-mini-row b { color: #fff; display: block; }
.adm-mini-row span { color: var(--adm-txt-dim); font-size: 10.5px; }
.adm-mini-row .adm-mini-time { margin-left: auto; color: var(--adm-txt-mute); font-size: 10.5px; }

/* ── Empty / pagination ─────────────────────────────── */
.adm-empty {
  padding: 40px 20px;
  text-align: center;
  color: var(--adm-txt-dim);
  font-size: 13px;
}
.adm-empty i { font-size: 28px; color: var(--adm-txt-mute); margin-bottom: 12px; display: block; }

.adm-pagin { display: flex; justify-content: space-between; align-items: center; gap: 12px; padding: 14px 0 4px; font-size: 12px; color: var(--adm-txt-dim); }
.adm-pagin-btns { display: flex; gap: 6px; }

/* ── Toast ──────────────────────────────────────────── */
.adm-toast {
  position: fixed;
  bottom: 24px; right: 24px;
  background: var(--adm-bg-2);
  border: 1px solid var(--adm-border-hi);
  color: var(--adm-txt);
  padding: 12px 18px;
  border-radius: 10px;
  font-size: 13px;
  font-weight: 500;
  box-shadow: var(--adm-shadow);
  z-index: 1000;
  opacity: 0;
  transform: translateY(12px);
  transition: all 0.25s;
  pointer-events: none;
  max-width: 320px;
}
.adm-toast.show { opacity: 1; transform: translateY(0); }
.adm-toast.success { border-color: rgba(29,209,138,0.4); }
.adm-toast.error { border-color: rgba(255,70,85,0.5); color: var(--adm-red-hi); }

/* ── Access denied ──────────────────────────────────── */
.adm-gate {
  min-height: 100vh;
  display: grid;
  place-items: center;
  padding: 32px;
}
.adm-gate-box {
  max-width: 420px;
  text-align: center;
  padding: 40px 32px;
  background: var(--adm-grad-card);
  border: 1px solid var(--adm-border);
  border-radius: var(--adm-radius-lg);
  box-shadow: var(--adm-shadow);
}
.adm-gate-box i {
  font-size: 44px;
  color: var(--adm-red-hi);
  margin-bottom: 16px;
}
.adm-gate-box h2 { margin: 0 0 6px; color: #fff; }
.adm-gate-box p { margin: 0 0 20px; color: var(--adm-txt-dim); font-size: 13px; }

/* ── Academy ────────────────────────────────────────── */
.adm-az-redirect-card {
  display: flex;
  align-items: center;
  gap: 20px;
  background: var(--adm-grad-card);
  border: 1px solid var(--adm-border);
  border-radius: var(--adm-radius-lg);
  padding: 28px 32px;
  flex-wrap: wrap;
}
.adm-az-redirect-icon {
  width: 56px; height: 56px;
  border-radius: 16px;
  background: rgba(255,70,85,0.12);
  border: 1px solid rgba(255,70,85,0.2);
  display: grid; place-items: center;
  font-size: 22px;
  color: var(--adm-red-hi);
  flex-shrink: 0;
}
.adm-az-redirect-text {
  flex: 1;
  min-width: 180px;
}
.adm-az-redirect-text h3 {
  margin: 0 0 4px;
  font-size: 1rem;
  font-weight: 800;
  color: #fff;
}
.adm-az-redirect-text p {
  margin: 0;
  font-size: 0.82rem;
  color: var(--adm-txt-dim);
  line-height: 1.5;
}
.adm-az-tabs {
  display: flex; gap: 4px; margin-bottom: 16px;
  background: var(--adm-bg-2);
  border-radius: var(--adm-radius);
  padding: 4px;
  border: 1px solid var(--adm-border);
}
.adm-az-tab {
  flex: 1;
  padding: 10px 14px;
  font-size: 12px; font-weight: 600;
  color: var(--adm-txt-dim);
  background: transparent;
  border: none; border-radius: 6px;
  cursor: pointer;
  transition: all 0.2s;
  display: flex; align-items: center; justify-content: center; gap: 6px;
}
.adm-az-tab:hover { color: #fff; background: rgba(255,255,255,0.04); }
.adm-az-tab.active { color: #fff; background: var(--adm-red-hi); }
.adm-az-list { display: flex; flex-direction: column; gap: 8px; }
.adm-az-row {
  display: flex; align-items: center; gap: 14px;
  padding: 12px 16px;
  background: var(--adm-bg-2);
  border: 1px solid var(--adm-border);
  border-radius: var(--adm-radius);
  transition: border-color 0.2s;
}
.adm-az-row:hover { border-color: rgba(255,70,85,0.25); }
.adm-az-row-cover {
  width: 52px; height: 38px;
  border-radius: 6px;
  background: linear-gradient(135deg, #1e2436, #141825);
  background-size: cover; background-position: center;
  flex-shrink: 0;
}
.adm-az-row-info { flex: 1; min-width: 0; }
.adm-az-row-title { font-weight: 700; color: #fff; font-size: 0.88rem; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.adm-az-row-sub { font-size: 0.72rem; color: var(--adm-txt-dim); margin-top: 2px; }
.adm-az-row-motive { font-size: 0.72rem; color: var(--adm-txt-dim); margin-top: 4px; font-style: italic; opacity: 0.8; }
.adm-az-row-actions { display: flex; gap: 6px; flex-shrink: 0; }
.adm-az-avatar {
  width: 40px; height: 40px;
  border-radius: 50%;
  object-fit: cover;
  flex-shrink: 0;
  border: 2px solid var(--adm-border);
}
.adm-az-status { font-size: 0.72rem; font-weight: 600; flex-shrink: 0; }
.adm-az-section { margin-top: 20px; }
.adm-az-section h3 {
  font-size: 0.88rem; font-weight: 700; color: #fff;
  margin: 0 0 12px; display: flex; align-items: center; gap: 8px;
}
.adm-btn-green {
  background: rgba(82,212,164,0.15);
  color: #52d4a4;
  border: 1px solid rgba(82,212,164,0.25);
}
.adm-btn-green:hover { background: rgba(82,212,164,0.25); }
.adm-btn-primary { background: var(--adm-grad-red); color: #fff; border: none; }
.adm-btn-primary:hover { opacity: .9; }

/* ── Academy: Diretório (coach cards) ──────────────── */
.adm-az-dir-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  gap: 16px;
  padding: 4px 0;
}
.adm-az-dir-card {
  background: var(--adm-bg-2);
  border: 1px solid var(--adm-border);
  border-radius: var(--adm-radius);
  overflow: hidden;
  transition: border-color 0.2s, transform 0.2s;
}
.adm-az-dir-card:hover {
  border-color: rgba(255,70,85,0.3);
  transform: translateY(-2px);
}
.adm-az-dir-cover {
  position: relative;
  height: 90px;
  background: linear-gradient(135deg, #1e2436, #141825);
  background-size: cover; background-position: center;
}
.adm-az-dir-avatar {
  position: absolute; bottom: -20px; left: 16px;
  width: 44px; height: 44px;
  border-radius: 50%; object-fit: cover;
  border: 3px solid var(--adm-bg-2);
}
.adm-az-dir-body {
  padding: 28px 16px 16px;
}
.adm-az-dir-body h3 {
  margin: 0; font-size: 0.88rem; font-weight: 700; color: #fff;
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.adm-az-dir-headline {
  margin: 4px 0 10px; font-size: 0.72rem;
  color: var(--adm-txt-dim);
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.adm-az-dir-stats {
  display: flex; gap: 12px; font-size: 0.72rem; color: var(--adm-txt-mute);
}
.adm-az-dir-stats span { display: flex; align-items: center; gap: 4px; }
.adm-az-dir-stats i { font-size: 11px; color: var(--adm-gold); }

/* ── Academy: Coach Panel ──────────────────────────── */
.adm-az-cpanel-head {
  display: flex; align-items: center; justify-content: space-between;
  margin-bottom: 16px;
}
.adm-az-cpanel-head h3 {
  margin: 0; font-size: 1rem; font-weight: 700; color: #fff;
  display: flex; align-items: center; gap: 8px;
}
.adm-az-clist { display: flex; flex-direction: column; gap: 8px; }
.adm-az-crow {
  display: flex; align-items: center; gap: 14px;
  padding: 12px 16px;
  background: var(--adm-bg-2);
  border: 1px solid var(--adm-border);
  border-radius: var(--adm-radius);
  transition: border-color 0.2s;
}
.adm-az-crow:hover { border-color: rgba(255,70,85,0.25); }
.adm-az-crow-cover {
  width: 64px; height: 44px;
  border-radius: 8px;
  background: linear-gradient(135deg, #1e2436, #141825);
  background-size: cover; background-position: center;
  flex-shrink: 0;
}
.adm-az-crow-main { flex: 1; min-width: 0; }
.adm-az-crow-title { font-weight: 700; color: #fff; font-size: 0.88rem; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.adm-az-crow-sub { font-size: 0.72rem; color: var(--adm-txt-dim); margin-top: 2px; }
.adm-az-crow-stat {
  text-align: center; flex-shrink: 0;
}
.adm-az-crow-stat span { display: block; font-weight: 700; color: #fff; font-size: 0.88rem; }
.adm-az-crow-stat em { font-style: normal; font-size: 0.68rem; color: var(--adm-txt-mute); }
.adm-az-crow-status { font-size: 0.72rem; font-weight: 600; flex-shrink: 0; }

/* ── Academy: Course Editor ────────────────────────── */
.adm-az-editor-topbar {
  display: flex; align-items: center; gap: 12px; margin-bottom: 16px;
}
.adm-az-editor-bc {
  flex: 1; display: flex; align-items: center; gap: 8px;
  font-size: 0.8rem; color: var(--adm-txt-dim);
}
.adm-az-editor-badge {
  font-size: 0.72rem; font-weight: 600;
  color: var(--sc);
  display: flex; align-items: center; gap: 6px;
}
.adm-az-badge-dot {
  width: 8px; height: 8px; border-radius: 50%;
  background: var(--sc);
  display: inline-block;
}
.adm-az-editor-hero {
  position: relative;
  height: 160px;
  border-radius: var(--adm-radius);
  background: linear-gradient(135deg, #1e2436, #141825);
  background-size: cover; background-position: center;
  overflow: hidden;
  margin-bottom: 16px;
}
.adm-az-editor-hero-shade {
  position: absolute; inset: 0;
  background: linear-gradient(180deg, transparent 20%, rgba(7,9,16,0.85) 100%);
}
.adm-az-editor-hero-info {
  position: absolute; bottom: 16px; left: 20px; right: 20px;
}
.adm-az-editor-hero-info h2 { margin: 0 0 4px; font-size: 1.1rem; color: #fff; }
.adm-az-editor-hero-info p { margin: 0 0 6px; font-size: 0.78rem; color: var(--adm-txt-dim); }
.adm-az-editor-hero-meta {
  display: flex; gap: 14px;
  font-size: 0.72rem; color: var(--adm-txt-mute);
}
.adm-az-editor-hero-meta span { display: flex; align-items: center; gap: 4px; }
.adm-az-editor-cols {
  display: grid; grid-template-columns: 1fr 1fr; gap: 16px;
}
.adm-az-ecard {
  background: var(--adm-bg-2);
  border: 1px solid var(--adm-border);
  border-radius: var(--adm-radius);
  padding: 20px;
}
.adm-az-ecard-head {
  display: flex; align-items: center; gap: 12px;
  margin-bottom: 16px;
}
.adm-az-ecard-icon {
  width: 36px; height: 36px;
  display: grid; place-items: center;
  background: rgba(255,70,85,0.12);
  color: var(--adm-red-hi);
  border-radius: 10px;
  font-size: 16px; flex-shrink: 0;
}
.adm-az-ecard-icon--cyan { background: rgba(0,212,255,0.12); color: var(--adm-cyan); }
.adm-az-ecard-title { font-weight: 700; font-size: 0.88rem; color: #fff; }
.adm-az-ecard-sub { font-size: 0.72rem; color: var(--adm-txt-dim); margin-top: 2px; }

/* ── Academy: Forms ────────────────────────────────── */
.adm-az-form { display: flex; flex-direction: column; gap: 14px; }
.adm-az-form-row { display: flex; flex-direction: column; gap: 4px; }
.adm-az-form-row label {
  font-size: 0.76rem; font-weight: 600;
  color: var(--adm-txt-dim);
  text-transform: uppercase; letter-spacing: 0.04em;
}
.adm-az-form-row input,
.adm-az-form-row textarea,
.adm-az-form-row select {
  background: var(--adm-bg-1);
  border: 1px solid var(--adm-border);
  border-radius: 8px;
  padding: 10px 12px;
  color: var(--adm-txt);
  font-size: 0.84rem;
  font-family: inherit;
  outline: none;
  transition: border-color 0.2s;
}
.adm-az-form-row input:focus,
.adm-az-form-row textarea:focus,
.adm-az-form-row select:focus {
  border-color: var(--adm-red-hi);
}
.adm-az-form-2col { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.adm-az-form-actions {
  display: flex; gap: 8px; margin-top: 4px;
}

/* ── Academy: Lessons list ─────────────────────────── */
.adm-az-lessons {
  list-style: none; margin: 0; padding: 0;
  display: flex; flex-direction: column; gap: 6px;
}
.adm-az-lesson {
  display: flex; align-items: center; gap: 12px;
  padding: 10px 12px;
  background: var(--adm-bg-1);
  border: 1px solid var(--adm-border);
  border-radius: 8px;
  transition: border-color 0.2s;
}
.adm-az-lesson:hover { border-color: rgba(0,212,255,0.2); }
.adm-az-lesson-num {
  font-weight: 800; font-size: 0.7rem;
  color: var(--adm-txt-mute);
  width: 22px; text-align: center; flex-shrink: 0;
}
.adm-az-lesson-thumb {
  width: 48px; height: 32px; border-radius: 6px; object-fit: cover; flex-shrink: 0;
}
.adm-az-lesson-thumb-empty {
  width: 48px; height: 32px; border-radius: 6px;
  background: rgba(255,255,255,0.04);
  display: grid; place-items: center;
  color: var(--adm-txt-mute); font-size: 12px;
  flex-shrink: 0;
}
.adm-az-lesson-main { flex: 1; min-width: 0; }
.adm-az-lesson-title {
  font-weight: 600; font-size: 0.82rem; color: #fff;
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.adm-az-lesson-pills {
  display: flex; gap: 6px; margin-top: 4px;
}
.adm-az-pill {
  font-size: 0.66rem; font-weight: 600;
  padding: 2px 8px; border-radius: 4px;
  background: rgba(255,255,255,0.06);
  color: var(--adm-txt-dim);
  display: flex; align-items: center; gap: 4px;
}
.adm-az-pill.preview { background: rgba(0,212,255,0.12); color: var(--adm-cyan); }
.adm-az-lesson-actions { display: flex; gap: 4px; flex-shrink: 0; }

/* ── Academy: Drag-and-drop lessons ────────────────── */
.adm-az-lesson-grip {
  color: var(--adm-txt-mute); font-size: 12px;
  cursor: grab; flex-shrink: 0; width: 16px;
  display: grid; place-items: center;
  opacity: 0.4; transition: opacity 0.15s;
}
.adm-az-lesson:hover .adm-az-lesson-grip { opacity: 1; }
.adm-az-lesson-grip:active { cursor: grabbing; }
.adm-az-lesson.az-dragging {
  opacity: 0.35; border-color: var(--adm-cyan);
  box-shadow: 0 0 0 1px var(--adm-cyan);
}
.adm-az-lesson.az-drag-over {
  border-color: var(--adm-cyan);
  box-shadow: 0 -2px 0 0 var(--adm-cyan);
}

/* ── Academy: Cover upload ─────────────────────────── */
.adm-az-cover-upload {
  display: flex; gap: 8px; align-items: center;
}
.adm-az-cover-upload input {
  flex: 1;
  background: var(--adm-bg-1);
  border: 1px solid var(--adm-border);
  border-radius: 8px;
  padding: 10px 12px;
  color: var(--adm-txt);
  font-size: 0.84rem;
  font-family: inherit;
  outline: none;
  transition: border-color 0.2s;
}
.adm-az-cover-upload input:focus { border-color: var(--adm-red-hi); }
.adm-az-cover-btn {
  display: flex; align-items: center; gap: 6px;
  white-space: nowrap; cursor: pointer;
  flex-shrink: 0;
}

/* ── Academy: Modal ────────────────────────────────── */
.adm-az-modal-overlay {
  position: fixed; inset: 0;
  background: rgba(7,9,16,0.8);
  backdrop-filter: blur(4px);
  display: grid; place-items: center;
  z-index: 9999;
  animation: admFadeIn 0.15s;
}
@keyframes admFadeIn { from { opacity: 0; } to { opacity: 1; } }
.adm-az-modal {
  background: var(--adm-bg-2);
  border: 1px solid var(--adm-border-hi);
  border-radius: var(--adm-radius-lg);
  box-shadow: var(--adm-shadow);
  width: 92%; max-width: 520px;
  padding: 24px;
  max-height: 90vh;
  overflow-y: auto;
  animation: admSlideUp 0.2s;
}
@keyframes admSlideUp { from { transform: translateY(16px); opacity: 0; } to { transform: translateY(0); opacity: 1; } }
.adm-az-modal-head {
  display: flex; align-items: flex-start; justify-content: space-between;
  margin-bottom: 20px;
}
.adm-az-modal-head-inner { display: flex; align-items: center; gap: 12px; }
.adm-az-modal-icon {
  width: 40px; height: 40px;
  display: grid; place-items: center;
  background: rgba(255,70,85,0.12);
  color: var(--adm-red-hi);
  border-radius: 12px;
  font-size: 18px; flex-shrink: 0;
}
.adm-az-modal-head h3 { margin: 0; font-size: 1rem; color: #fff; }
.adm-az-modal-x {
  background: none; border: none;
  color: var(--adm-txt-dim); font-size: 16px;
  cursor: pointer; padding: 4px 8px;
  border-radius: 6px;
}
.adm-az-modal-x:hover { color: #fff; background: rgba(255,255,255,0.06); }
.adm-az-modal-actions {
  display: flex; justify-content: flex-end; gap: 8px;
  margin-top: 16px; padding-top: 16px;
  border-top: 1px solid var(--adm-border);
}

/* ── Responsive ─────────────────────────────────────── */
@media (max-width: 900px) {
  .adm-shell { grid-template-columns: 1fr; }
  .adm-side {
    position: relative;
    height: auto;
    flex-direction: row;
    overflow-x: auto;
    padding: 14px;
    gap: 6px;
  }
  .adm-brand, .adm-nav-label, .adm-side-foot { display: none; }
  .adm-nav-item { white-space: nowrap; }
  .adm-main { padding: 18px; }
  .adm-az-tabs { flex-wrap: wrap; }
  .adm-az-row { flex-wrap: wrap; }
  .adm-az-row-actions { width: 100%; justify-content: flex-end; }
  .adm-az-dir-grid { grid-template-columns: repeat(auto-fill, minmax(180px, 1fr)); }
  .adm-az-editor-cols { grid-template-columns: 1fr; }
  .adm-az-crow { flex-wrap: wrap; }
  .adm-az-crow-stat { min-width: 50px; }
  .adm-az-form-2col { grid-template-columns: 1fr; }
}

/* =====================================================
   Logs viewer (Log do Site)
   ===================================================== */
.adm-logs-card .log-toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 14px 20px;
  border-bottom: 1px solid rgba(255,255,255,0.05);
  background: rgba(255,255,255,0.01);
  flex-wrap: wrap;
}
.log-filters { display: flex; gap: 6px; flex-wrap: wrap; }
.log-filter-btn {
  display: inline-flex; align-items: center; gap: 6px;
  padding: 7px 12px; border-radius: 8px;
  background: rgba(255,255,255,0.03);
  border: 1px solid rgba(255,255,255,0.06);
  color: rgba(255,255,255,0.6);
  font-size: 0.74rem; font-weight: 700;
  letter-spacing: 0.05em; cursor: pointer; transition: 0.18s;
  font-family: inherit;
}
.log-filter-btn:hover { color: #fff; background: rgba(255,255,255,0.06); }
.log-filter-btn.active {
  color: #fff;
  background: linear-gradient(135deg, rgba(139,92,246,0.3), rgba(139,92,246,0.08));
  border-color: rgba(139,92,246,0.4);
}
.log-actions { display: flex; align-items: center; gap: 8px; }
.log-search-wrap {
  position: relative; display: flex; align-items: center;
}
.log-search-wrap i {
  position: absolute; left: 10px; color: rgba(255,255,255,0.3); font-size: 0.78rem;
}
.log-search {
  padding: 7px 10px 7px 28px; border-radius: 8px;
  background: rgba(0,0,0,0.3); border: 1px solid rgba(255,255,255,0.08);
  color: #fff; font-size: 0.78rem; width: 200px; font-family: inherit;
}
.log-search:focus { outline: none; border-color: rgba(139,92,246,0.5); }
.log-action-btn {
  padding: 7px 10px; border-radius: 8px;
  background: rgba(255,255,255,0.03);
  border: 1px solid rgba(255,255,255,0.06);
  color: rgba(255,255,255,0.6);
  cursor: pointer; transition: 0.18s;
}
.log-action-btn:hover { color: #fff; background: rgba(255,255,255,0.06); }
.log-action-btn.danger:hover { color: #ff6363; border-color: rgba(255,99,99,0.35); }
.log-viewer {
  font-family: 'JetBrains Mono', ui-monospace, 'SF Mono', Menlo, monospace;
  font-size: 0.78rem;
  background: #04060b;
  height: 480px; overflow-y: auto;
  padding: 8px 0;
}
.log-entry {
  display: grid;
  grid-template-columns: 70px 18px 80px 1fr;
  gap: 10px;
  padding: 4px 16px;
  border-left: 2px solid transparent;
  color: rgba(255,255,255,0.8);
  align-items: start;
  line-height: 1.45;
}
.log-entry:hover { background: rgba(255,255,255,0.02); }
.log-entry .log-time { color: rgba(255,255,255,0.35); }
.log-entry .log-type { font-weight: 700; text-transform: uppercase; font-size: 0.7rem; letter-spacing: 0.08em; }
.log-entry .log-msg { white-space: pre-wrap; word-break: break-word; }
.log-error  { border-left-color: #ff4655; }
.log-error  .log-icon, .log-error .log-type { color: #ff4655; }
.log-warn   { border-left-color: #ffb93b; }
.log-warn   .log-icon, .log-warn .log-type { color: #ffb93b; }
.log-network { border-left-color: #4a8eff; }
.log-network .log-icon, .log-network .log-type { color: #4a8eff; }
.log-load    { border-left-color: #1dd18a; }
.log-load    .log-icon, .log-load .log-type { color: #1dd18a; }
.log-resource { border-left-color: #c084fc; }
.log-resource .log-icon, .log-resource .log-type { color: #c084fc; }
.log-info    { border-left-color: rgba(255,255,255,0.2); }
.log-info    .log-icon, .log-info .log-type { color: rgba(255,255,255,0.6); }
.log-nav     { border-left-color: #38bdf8; }
.log-nav     .log-icon, .log-nav .log-type { color: #38bdf8; }

.log-empty {
  text-align: center; padding: 50px 20px;
  color: rgba(255,255,255,0.25); font-size: 0.9rem;
}
.log-empty i { color: #1dd18a; margin-right: 6px; }

.log-footer {
  display: flex; justify-content: space-between; align-items: center;
  padding: 10px 20px;
  border-top: 1px solid rgba(255,255,255,0.05);
  background: rgba(255,255,255,0.01);
  font-size: 0.75rem; color: rgba(255,255,255,0.5);
}
.log-autoscroll { display: flex; align-items: center; gap: 6px; cursor: pointer; user-select: none; }
.log-autoscroll input { accent-color: #8b5cf6; }

.log-header-stats { display: inline-flex; gap: 10px; }
.log-stat {
  display: inline-flex; padding: 4px 10px; border-radius: 6px;
  font-size: 0.7rem; font-weight: 700; letter-spacing: 0.05em;
  background: rgba(255,255,255,0.04); color: rgba(255,255,255,0.6);
}
.log-stat.log-error { color: #ff4655; background: rgba(255,70,85,0.08); }
.log-stat.log-warn  { color: #ffb93b; background: rgba(255,185,59,0.08); }
.log-stat.log-network { color: #4a8eff; background: rgba(74,142,255,0.08); }

/* Maps host within admin */
.adm-maps-host { padding: 20px 24px; }
.adm-maps-host .maps-page-premium { padding: 0; }

/* ── Admin login form ───────────────────────────────── */
.adm-login-form {
  max-width: 380px;
  text-align: left;
  display: flex;
  flex-direction: column;
  gap: 14px;
}
.adm-login-form i.fa-shield-halved {
  display: block;
  text-align: center;
  color: var(--adm-red-hi);
  margin-bottom: 4px;
}
.adm-login-form h2 { text-align: center; }
.adm-login-form > p { text-align: center; }
.adm-login-field { display: flex; flex-direction: column; gap: 6px; }
.adm-login-field label {
  font-size: 11px;
  color: var(--adm-txt-dim);
  letter-spacing: 0.08em;
  text-transform: uppercase;
  font-weight: 600;
}
.adm-login-field .adm-input { width: 100%; }
.adm-login-error {
  background: rgba(255,70,85,0.1);
  border: 1px solid rgba(255,70,85,0.35);
  color: var(--adm-red-hi);
  padding: 10px 12px;
  border-radius: 8px;
  font-size: 12px;
  text-align: center;
}
.adm-login-submit {
  justify-content: center;
  margin-top: 6px;
  padding: 12px 16px;
  font-size: 13px;
}
.adm-gate-actions {
  display: flex;
  gap: 10px;
  justify-content: center;
  flex-wrap: wrap;
}

/* ═══════════════════════════════════════════════════════
   HOME EDITOR
   ═══════════════════════════════════════════════════════ */
.adm-home-editor { display: flex; flex-direction: column; gap: 16px; }
.adm-form-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 12px;
}
.adm-field { display: flex; flex-direction: column; gap: 6px; font-size: 0.82rem; }
.adm-field span { color: #8a93a8; font-weight: 600; letter-spacing: 0.02em; }
.adm-field em { color: #6b7383; font-style: normal; font-size: 0.72rem; }
.adm-field-full { grid-column: 1 / -1; }
.adm-input {
  background: #0f1219;
  border: 1px solid rgba(255,255,255,0.08);
  border-radius: 8px;
  color: #e6eaf3;
  font: inherit;
  padding: 9px 12px;
  width: 100%;
  transition: border-color .15s;
}
.adm-input:focus { outline: none; border-color: #ff4655; }
textarea.adm-input { resize: vertical; font-family: inherit; }

.adm-toggle {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 0.8rem;
  color: #a6afc2;
  cursor: pointer;
  user-select: none;
}
.adm-toggle input { accent-color: #ff4655; width: 16px; height: 16px; }

.adm-subhead {
  margin: 16px 0 10px;
  font-size: 0.85rem;
  font-weight: 700;
  color: #a6afc2;
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

.adm-nav-editor { display: flex; flex-direction: column; gap: 8px; }
.adm-nav-row {
  display: grid;
  grid-template-columns: auto 140px 1fr 1fr auto auto auto;
  gap: 8px;
  align-items: center;
  padding: 8px;
  background: #0f1219;
  border: 1px solid rgba(255,255,255,0.06);
  border-radius: 10px;
}
.adm-nav-row .adm-input { padding: 7px 10px; font-size: 0.82rem; }
.adm-nav-vis { accent-color: #ff4655; width: 16px; height: 16px; }

.adm-cards-editor { display: flex; flex-direction: column; gap: 10px; }
.adm-card-row {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 12px;
  align-items: start;
  padding: 12px;
  background: #0f1219;
  border: 1px solid rgba(255,255,255,0.06);
  border-radius: 10px;
}
.adm-row-actions {
  display: flex;
  flex-direction: column;
  align-items: stretch;
  gap: 6px;
  min-width: 110px;
}

.adm-btn-icon {
  background: transparent;
  border: 1px solid rgba(255,255,255,0.08);
  color: #a6afc2;
  width: 32px;
  height: 32px;
  border-radius: 8px;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  transition: background .15s, color .15s;
}
.adm-btn-icon:hover { background: rgba(255,70,85,0.08); color: #ff4655; border-color: rgba(255,70,85,0.3); }
.adm-btn-icon.adm-btn-danger:hover { color: #ff4655; }

.adm-btn-primary {
  background: linear-gradient(135deg, #ff4655, #ff6b7a);
  border-color: transparent;
  color: #fff;
}
.adm-btn-primary:hover {
  filter: brightness(1.08);
  box-shadow: 0 6px 18px rgba(255,70,85,0.35);
}

@media (max-width: 820px) {
  .adm-nav-row { grid-template-columns: 1fr; }
  .adm-card-row { grid-template-columns: 1fr; }
  .adm-row-actions { flex-direction: row; flex-wrap: wrap; }
}

/* ─── HOME EDITOR · Premium header editor ─────────────── */
.adm-status {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 5px 10px;
  border-radius: 999px;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}
.adm-status.clean { background: rgba(52, 199, 89, 0.12); color: #34c759; }
.adm-status.dirty { background: rgba(255, 159, 10, 0.12); color: #ff9f0a; }
.adm-status i { font-size: 0.8em; }

@keyframes admPulse {
  0%,100% { box-shadow: 0 0 0 0 rgba(255,70,85,0.55); }
  50%     { box-shadow: 0 0 0 8px rgba(255,70,85,0); }
}
.adm-btn-pulse { animation: admPulse 1.6s ease-out infinite; }

.adm-subhead-hint {
  float: right;
  font-size: 0.7rem;
  text-transform: none;
  letter-spacing: 0;
  color: #6b7383;
  font-weight: 500;
}
.adm-subhead-hint i { margin: 0 2px; opacity: 0.7; }

/* Live preview bar (mirrors site header chrome) */
.adm-nav-preview {
  position: relative;
  margin: 4px 0 18px;
  padding: 14px 18px;
  background: linear-gradient(180deg, rgba(255,70,85,0.06), transparent),
              radial-gradient(1200px 200px at 50% -50%, rgba(255,70,85,0.18), transparent 60%),
              #0a0c12;
  border: 1px solid rgba(255,70,85,0.25);
  border-radius: 14px;
  overflow: hidden;
}
.adm-nav-preview::before {
  content: '';
  position: absolute; inset: 0 0 auto 0; height: 2px;
  background: linear-gradient(90deg, transparent, #ff4655, transparent);
  opacity: 0.6;
}
.adm-nav-preview-inner {
  display: flex;
  align-items: center;
  gap: 24px;
  flex-wrap: wrap;
}
.adm-preview-brand {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-weight: 800;
  letter-spacing: 0.04em;
  background: linear-gradient(135deg, #ff4655, #ff6b9d);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}
.adm-preview-brand i { color: #ff4655; -webkit-text-fill-color: #ff4655; }
.adm-preview-nav {
  display: flex;
  gap: 4px;
  flex-wrap: wrap;
  flex: 1;
}
.adm-preview-link {
  padding: 7px 12px;
  font-size: 0.82rem;
  font-weight: 600;
  color: #c8cdd9;
  text-decoration: none;
  border-radius: 8px;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  transition: background .15s, color .15s;
}
.adm-preview-link:hover { background: rgba(255,70,85,0.12); color: #fff; }
.adm-nav-preview-hint {
  position: absolute;
  top: 8px; right: 12px;
  font-size: 0.65rem;
  color: rgba(255,255,255,0.4);
  letter-spacing: 0.08em;
  text-transform: uppercase;
}
.adm-nav-preview-hint i { margin-right: 4px; color: #ff4655; }

/* Nav row — drag handle + visibility + label + href + key chip */
.adm-nav-editor { display: flex; flex-direction: column; gap: 6px; }
.adm-nav-row {
  display: grid;
  grid-template-columns: auto auto 1fr auto auto;
  gap: 10px;
  align-items: center;
  padding: 8px 10px;
  background: #0f1219;
  border: 1px solid rgba(255,255,255,0.06);
  border-radius: 10px;
  transition: border-color .15s, background .15s, transform .12s;
}
.adm-nav-row:hover { border-color: rgba(255,70,85,0.25); }
.adm-nav-row.is-dragging { opacity: 0.4; transform: scale(0.98); }
.adm-nav-row.is-drop-target { border-color: #ff4655; background: rgba(255,70,85,0.08); }
.adm-nav-row.is-hidden { opacity: 0.55; }
.adm-nav-row.is-invalid { border-color: #ff9f0a; }

.adm-nav-grip {
  background: transparent; border: 0; color: #54596a;
  cursor: grab; padding: 0 4px; font-size: 0.9rem;
}
.adm-nav-grip:active { cursor: grabbing; }
.adm-nav-row:hover .adm-nav-grip { color: #ff4655; }

.adm-nav-toggle {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 32px; height: 32px;
  border-radius: 8px;
  border: 1px solid rgba(255,255,255,0.08);
  background: #070a10;
  color: #54596a;
  cursor: pointer;
  transition: color .15s, border-color .15s;
}
.adm-nav-toggle input { position: absolute; inset: 0; opacity: 0; cursor: pointer; }
.adm-nav-toggle:has(input:checked) { color: #ff4655; border-color: rgba(255,70,85,0.4); }

.adm-nav-main {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
}
.adm-nav-main .adm-input { padding: 7px 10px; font-size: 0.85rem; }

.adm-nav-key-chip {
  font-family: ui-monospace, 'SF Mono', Menlo, monospace;
  font-size: 0.7rem;
  color: #8a93a8;
  background: rgba(255,255,255,0.04);
  border: 1px solid rgba(255,255,255,0.06);
  padding: 4px 8px;
  border-radius: 6px;
  min-width: 80px;
  text-align: center;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  max-width: 140px;
}

@media (max-width: 820px) {
  .adm-nav-row { grid-template-columns: auto auto 1fr auto; }
  .adm-nav-main { grid-template-columns: 1fr; }
  .adm-nav-key-chip { display: none; }
}

/* ═══════════════════════════════════════════════════════════════════
   BANNER TEMPLATES + SECTIONS ORDER (home editor)
   ═══════════════════════════════════════════════════════════════════ */
.adm-badge {
  display: inline-block;
  font-size: .72rem; font-weight: 600;
  padding: 2px 8px; border-radius: 999px;
  background: rgba(99,102,241,.15); color: #a5b4fc;
  margin-left: .5rem;
  vertical-align: middle;
}
.adm-badge-warn { background: rgba(245,158,11,.15); color: #fcd34d; }

.adm-help {
  font-size: .82rem; color: var(--adm-text-muted, #94a3b8);
  margin: .25rem 0 1rem; line-height: 1.45;
}
.adm-help i { margin-right: .35rem; color: #60a5fa; }

/* Template grid --------------------------------------------------- */
.adm-tpl-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
  gap: 1rem;
}
.adm-tpl-card {
  background: rgba(255,255,255,.03);
  border: 1px solid rgba(255,255,255,.08);
  border-radius: 12px;
  padding: 1rem;
  display: flex; flex-direction: column;
  gap: .75rem;
  transition: border-color .18s, transform .18s;
}
.adm-tpl-card:hover { border-color: rgba(99,102,241,.45); transform: translateY(-1px); }
.adm-tpl-card.is-off { opacity: .55; }
.adm-tpl-head { display: flex; align-items: center; justify-content: space-between; }
.adm-tpl-badge {
  display: inline-flex; align-items: center; gap: .35rem;
  font-size: .72rem; font-weight: 600;
  padding: 3px 8px; border-radius: 6px;
  background: color-mix(in srgb, var(--c, #6366f1) 18%, transparent);
  color: var(--c, #6366f1);
  border: 1px solid color-mix(in srgb, var(--c, #6366f1) 35%, transparent);
}
.adm-tpl-name { font-weight: 600; font-size: .95rem; }
.adm-tpl-preview {
  display: grid; grid-template-columns: repeat(3, 1fr); gap: .35rem;
  min-height: 80px;
}
.adm-tpl-thumb {
  aspect-ratio: 16/9;
  background: #0f172a center/cover no-repeat;
  border-radius: 6px;
  border: 1px solid rgba(255,255,255,.06);
}
.adm-tpl-thumb-empty {
  display: flex; align-items: center; justify-content: center;
  color: #475569; font-size: 1.3rem;
}
.adm-tpl-foot {
  display: flex; align-items: center; gap: .75rem;
  font-size: .75rem; color: #94a3b8;
  flex-wrap: wrap;
}
.adm-tpl-actions { margin-left: auto; display: flex; gap: .35rem; }

.adm-toggle-sm span {
  width: 32px; height: 18px;
}

/* Template modal -------------------------------------------------- */
.adm-modal-back {
  position: fixed; inset: 0; z-index: 9999;
  background: rgba(0,0,0,.65); backdrop-filter: blur(4px);
  display: flex; align-items: center; justify-content: center;
  padding: 1rem;
}
.adm-modal {
  background: #0f172a;
  border: 1px solid rgba(255,255,255,.08);
  border-radius: 14px;
  width: 100%; max-width: 640px;
  max-height: 90vh;
  display: flex; flex-direction: column;
  box-shadow: 0 20px 60px rgba(0,0,0,.5);
}
.adm-modal-lg { max-width: 820px; }
.adm-modal-head, .adm-modal-foot {
  padding: 1rem 1.25rem;
  border-bottom: 1px solid rgba(255,255,255,.08);
  display: flex; align-items: center; gap: .75rem;
}
.adm-modal-foot { border-bottom: 0; border-top: 1px solid rgba(255,255,255,.08); }
.adm-modal-head h3 { margin: 0; font-size: 1.05rem; }
.adm-modal-close {
  margin-left: auto;
  background: transparent; border: 0;
  color: #94a3b8; font-size: 1.5rem; cursor: pointer;
  width: 32px; height: 32px; border-radius: 8px;
}
.adm-modal-close:hover { background: rgba(255,255,255,.08); color: #fff; }
.adm-modal-body {
  padding: 1.25rem;
  overflow-y: auto;
  flex: 1;
}

.adm-tpl-types {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
  gap: .6rem;
}
.adm-tpl-type {
  display: flex; flex-direction: column; align-items: center; text-align: center;
  gap: .35rem;
  padding: .85rem .6rem;
  border: 1px solid rgba(255,255,255,.08);
  border-radius: 10px;
  background: rgba(255,255,255,.02);
  cursor: pointer;
  transition: all .15s;
}
.adm-tpl-type input { display: none; }
.adm-tpl-type i { font-size: 1.3rem; color: var(--c, #6366f1); }
.adm-tpl-type span { font-weight: 600; font-size: .85rem; }
.adm-tpl-type em { font-style: normal; font-size: .72rem; color: #94a3b8; line-height: 1.3; }
.adm-tpl-type:hover { border-color: color-mix(in srgb, var(--c, #6366f1) 55%, transparent); }
.adm-tpl-type.is-active {
  border-color: var(--c, #6366f1);
  background: color-mix(in srgb, var(--c, #6366f1) 12%, transparent);
  box-shadow: 0 0 0 1px color-mix(in srgb, var(--c, #6366f1) 40%, transparent);
}

.adm-tpl-slot {
  display: grid;
  grid-template-columns: 1fr;
  gap: .5rem;
  padding: .75rem;
  border: 1px solid rgba(255,255,255,.06);
  border-radius: 10px;
  margin-bottom: .5rem;
  background: rgba(255,255,255,.02);
}
.adm-tpl-slot-up { display: flex; align-items: center; gap: .5rem; flex-wrap: wrap; }
.adm-tpl-slot-preview {
  width: 140px; height: 80px;
  background: #1e293b center/cover no-repeat;
  border-radius: 8px;
  border: 1px solid rgba(255,255,255,.08);
}
.adm-tpl-slot-empty {
  display: flex; align-items: center; justify-content: center;
  color: #475569;
  font-size: .8rem;
  gap: .35rem;
}

/* Sections order list -------------------------------------------- */
.adm-sect-list {
  display: flex; flex-direction: column;
  gap: .5rem;
}
.adm-sect-item {
  display: grid;
  grid-template-columns: auto auto 1fr auto auto;
  align-items: center; gap: .75rem;
  padding: .75rem 1rem;
  background: rgba(255,255,255,.03);
  border: 1px solid rgba(255,255,255,.08);
  border-radius: 10px;
  cursor: grab;
  transition: all .15s;
}
.adm-sect-item:hover { border-color: rgba(99,102,241,.35); }
.adm-sect-item.is-dragging { opacity: .4; cursor: grabbing; }
.adm-sect-item.is-drop-target { border-color: #6366f1; box-shadow: 0 0 0 2px rgba(99,102,241,.35); }
.adm-sect-item.is-hidden { opacity: .55; }
.adm-sect-item.is-hidden .adm-sect-name { text-decoration: line-through; }

.adm-sect-grip { color: #475569; font-size: 1rem; }
.adm-sect-icon {
  width: 36px; height: 36px;
  border-radius: 8px;
  background: color-mix(in srgb, var(--c, #6366f1) 18%, transparent);
  color: var(--c, #6366f1);
  display: flex; align-items: center; justify-content: center;
  font-size: 1rem;
}
.adm-sect-info { min-width: 0; }
.adm-sect-name { font-weight: 600; font-size: .9rem; }
.adm-sect-desc { font-size: .75rem; color: #94a3b8; margin-top: 2px; }
.adm-sect-toggle {
  background: rgba(255,255,255,.04);
  border: 1px solid rgba(255,255,255,.1);
  color: #cbd5e1;
  width: 34px; height: 34px;
  border-radius: 8px;
  cursor: pointer;
}
.adm-sect-toggle:hover { background: rgba(99,102,241,.2); color: #fff; }
.adm-sect-num {
  width: 28px; height: 28px;
  border-radius: 50%;
  background: rgba(255,255,255,.06);
  color: #94a3b8;
  display: flex; align-items: center; justify-content: center;
  font-size: .75rem; font-weight: 600;
}
.adm-chip {
  display: inline-block;
  font-size: .65rem; font-weight: 600;
  padding: 1px 6px; border-radius: 4px;
  background: rgba(255,255,255,.08); color: #94a3b8;
  margin-left: .35rem;
  vertical-align: middle;
}
.adm-chip-accent { background: rgba(99,102,241,.2); color: #a5b4fc; }

.adm-btn-danger {
  background: rgba(239,68,68,.15) !important;
  color: #f87171 !important;
  border-color: rgba(239,68,68,.35) !important;
}
.adm-btn-danger:hover { background: rgba(239,68,68,.3) !important; }

/* =====================================================
   LIVE PREVIEWS — premium "glass + red glow" treatment
   Applied uniformly to every editable home section so the
   editor mirrors what will ship on zdval.site/.
   ===================================================== */

.adm-section-preview {
  position: relative;
  background: #0a0c12;
  background-image:
    radial-gradient(ellipse 80% 60% at 50% 0%, rgba(255,70,85,0.10), transparent 60%),
    radial-gradient(ellipse 40% 40% at 95% 100%, rgba(139,125,255,0.05), transparent 70%);
  border: 1px solid rgba(255,70,85,0.22);
  border-radius: 14px;
  padding: 20px 22px 16px;
  margin: 0 0 18px;
  overflow: hidden;
  box-shadow: 0 10px 40px rgba(0,0,0,0.45), inset 0 1px 0 rgba(255,255,255,0.04);
}
.adm-section-preview::before {
  content: '';
  position: absolute;
  top: 0; left: -40%;
  width: 40%; height: 2px;
  background: linear-gradient(90deg, transparent, rgba(255,70,85,0.9), transparent);
  animation: admShimmer 4s ease-in-out infinite;
}
@keyframes admShimmer {
  0%, 100% { left: -40%; }
  50% { left: 100%; }
}
.adm-section-preview-sm { padding: 14px 16px 12px; }
.adm-section-preview-inner { position: relative; z-index: 1; }
.adm-nav-preview-hint {
  position: absolute; bottom: 6px; right: 12px;
  font-size: 0.7rem; font-weight: 600;
  letter-spacing: 0.04em; text-transform: uppercase;
  color: rgba(255,70,85,0.65);
  display: flex; align-items: center; gap: 5px;
}

/* Hero preview */
.adm-hero-preview { text-align: center; padding: 10px 0 6px; }
.adm-hero-preview.is-off { opacity: 0.4; filter: grayscale(0.5); }
.adm-hero-badge {
  display: inline-flex; align-items: center; gap: 6px;
  background: rgba(255,70,85,0.12);
  border: 1px solid rgba(255,70,85,0.3);
  color: #ff8a95;
  padding: 5px 14px; border-radius: 99px;
  font-size: 0.72rem; font-weight: 700; letter-spacing: 0.12em;
  text-transform: uppercase; margin-bottom: 12px;
}
.adm-hero-title {
  font-size: 1.65rem; line-height: 1.15; margin: 0 0 10px;
  font-weight: 800; color: #fff;
}
.adm-hero-title .home-hero-accent {
  background: linear-gradient(135deg, #ff4655 0%, #ff8a4c 100%);
  -webkit-background-clip: text; background-clip: text;
  -webkit-text-fill-color: transparent; color: transparent;
}
.adm-hero-sub { color: #a8b0c3; margin: 0 auto 14px; max-width: 520px; font-size: 0.92rem; }
.adm-hero-actions { display: flex; gap: 10px; justify-content: center; flex-wrap: wrap; }
.adm-hero-btn {
  display: inline-flex; align-items: center; gap: 7px;
  padding: 8px 16px; border-radius: 8px;
  font-size: 0.82rem; font-weight: 700; letter-spacing: 0.04em;
  text-transform: uppercase;
}
.adm-hero-btn-primary {
  background: linear-gradient(135deg, #ff4655, #c42a3a); color: #fff;
  box-shadow: 0 6px 20px rgba(255,70,85,0.35);
}
.adm-hero-btn-ghost {
  background: rgba(255,255,255,0.04); color: #e6eaf3;
  border: 1px solid rgba(255,255,255,0.14);
}

/* Section title bar inside previews */
.adm-pv-section.is-off { opacity: 0.4; filter: grayscale(0.5); }
.adm-pv-tab, .adm-pv-title {
  display: inline-block; font-weight: 800; letter-spacing: 0.04em;
  color: #fff; font-size: 0.95rem; margin-bottom: 12px;
  padding: 4px 12px; border-radius: 6px;
  background: linear-gradient(135deg, rgba(255,70,85,0.14), rgba(255,70,85,0.04));
  border-left: 2px solid #ff4655;
}
.adm-pv-title { background: none; border-left: none; padding: 0; font-size: 1.05rem; }
.adm-pv-off {
  text-align: center; margin-top: 10px;
  font-size: 0.72rem; color: #ff8a95; font-weight: 700;
  letter-spacing: 0.08em; text-transform: uppercase;
}
.adm-pv-empty {
  padding: 20px; text-align: center; color: #6a7388;
  font-size: 0.82rem; font-style: italic;
}

/* Play preview — mini cards */
.adm-play-preview { display: grid; grid-template-columns: repeat(auto-fit, minmax(180px, 1fr)); gap: 10px; }
.adm-play-card-mini {
  padding: 14px; border-radius: 10px;
  background: linear-gradient(135deg, rgba(0,212,255,0.08), rgba(0,90,130,0.12));
  border: 1px solid rgba(0,212,255,0.22);
  min-height: 80px;
}
.adm-play-c-tournaments {
  background: linear-gradient(135deg, rgba(255,70,85,0.10), rgba(120,20,30,0.16));
  border-color: rgba(255,70,85,0.30);
}
.adm-play-card-title { font-weight: 800; color: #fff; font-size: 0.92rem; margin-bottom: 4px; }
.adm-play-card-desc { color: #a8b0c3; font-size: 0.78rem; line-height: 1.4; }

/* Features preview — mini feature cards */
.adm-feat-preview { display: grid; grid-template-columns: repeat(auto-fit, minmax(130px, 1fr)); gap: 8px; }
.adm-feat-card-mini {
  padding: 10px; border-radius: 9px;
  background: rgba(255,255,255,0.02);
  border: 1px solid rgba(255,255,255,0.08);
  text-align: center;
}
.adm-feat-icon {
  width: 36px; height: 36px; margin: 0 auto 8px;
  display: grid; place-items: center; border-radius: 8px;
  background: linear-gradient(135deg, rgba(255,70,85,0.18), rgba(255,70,85,0.05));
  color: #ff8a95; font-size: 0.95rem;
}
.adm-feat-card-title { font-weight: 700; color: #fff; font-size: 0.76rem; margin-bottom: 2px; line-height: 1.2; }
.adm-feat-card-desc {
  color: #8a93a8;
  font-size: 0.68rem;
  line-height: 1.3;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

/* Academy preview — dual side cards + main media card */
.adm-academy-preview {
  display: grid;
  grid-template-columns: 170px minmax(0, 1fr);
  gap: 10px;
}
.adm-academy-preview-side {
  display: grid;
  grid-template-rows: 1fr 1fr;
  gap: 8px;
}
.adm-academy-card-mini {
  min-height: 82px;
  border-radius: 10px;
  border: 1px solid rgba(56,189,248,0.3);
  background: linear-gradient(135deg, rgba(7, 28, 45, 0.42), rgba(7, 16, 30, 0.76));
  padding: 10px;
  display: flex;
  align-items: flex-end;
}
.adm-academy-card-mini span {
  color: #fff;
  font-family: 'Rajdhani', 'Inter', sans-serif;
  text-transform: uppercase;
  font-size: 0.95rem;
  font-weight: 700;
  line-height: 1;
  text-shadow: 0 2px 8px rgba(0,0,0,0.85);
}
.adm-academy-preview-main {
  min-height: 172px;
  border-radius: 10px;
  border: 1px solid rgba(56,189,248,0.28);
  background: radial-gradient(circle at 10% 14%, rgba(56,189,248,0.22), rgba(6,14,24,0.82) 56%);
  padding: 12px;
  display: flex;
  align-items: flex-end;
}
.adm-academy-main-title {
  margin: 0 0 4px;
  color: #fff;
  font-size: 1.28rem;
  font-family: 'Rajdhani', 'Inter', sans-serif;
  text-transform: uppercase;
  font-weight: 700;
  line-height: 1;
}
.adm-academy-main-sub {
  color: #b8c7dd;
  font-size: 0.72rem;
  line-height: 1.35;
}

@media (max-width: 900px) {
  .adm-academy-preview {
    grid-template-columns: 1fr;
  }
  .adm-academy-preview-side {
    grid-template-columns: 1fr 1fr;
    grid-template-rows: none;
  }
  .adm-academy-preview-main {
    min-height: 140px;
  }
}

/* Aside preview */
.adm-pv-aside.is-off { opacity: 0.4; filter: grayscale(0.5); }
.adm-aside-label {
  font-size: 0.65rem; font-weight: 700; letter-spacing: 0.14em;
  color: #ff8a95; text-transform: uppercase; margin-bottom: 8px;
}
.adm-aside-card-mini {
  background: rgba(255,255,255,0.02);
  border: 1px solid rgba(255,255,255,0.08);
  border-radius: 10px; padding: 12px; text-align: center;
}
.adm-aside-card-mini i {
  font-size: 1.2rem; color: #ff8a95; margin-bottom: 6px; display: block;
}
.adm-aside-card-mini h4 { margin: 0 0 4px; color: #fff; font-size: 0.88rem; font-weight: 700; }
.adm-aside-card-mini p  { margin: 0; color: #8a93a8; font-size: 0.74rem; line-height: 1.4; }
.adm-aside-media {
  display: block; width: 100%; aspect-ratio: 16/10;
  border-radius: 8px; overflow: hidden; object-fit: cover;
  margin: 0 auto 8px; border: 0;
}
.adm-aside-media-yt {
  display: flex; align-items: center; justify-content: center; gap: 6px;
  background: linear-gradient(135deg, #c4302b 0%, #7a1e1a 100%);
  color: #fff; font-weight: 700; font-size: 0.78rem;
  padding: 14px; border-radius: 8px; margin: 0 auto 8px;
}
.adm-aside-media-yt i { font-size: 1.1rem; margin: 0; color: #fff; }

/* YouTube badge inside the upload box (stx form) */
.stx-upload-ytbadge {
  display: flex; flex-direction: column; align-items: center; gap: 6px;
  color: #c4302b; font-weight: 700; font-size: 0.85rem;
}
.stx-upload-ytbadge i { font-size: 2.2rem; }

/* Aside grid — side by side like on home */
.adm-aside-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; }
@media (max-width: 900px) { .adm-aside-grid { grid-template-columns: 1fr; } }

/* Card rows — drag handle appearance consistent with nav rows */
.adm-card-row {
  position: relative;
  display: grid; grid-template-columns: 28px 1fr auto; gap: 12px;
  align-items: start;
  padding: 12px; margin-bottom: 10px;
  background: rgba(255,255,255,0.02);
  border: 1px solid rgba(255,255,255,0.08);
  border-radius: 10px;
  transition: transform .15s, border-color .15s, background .15s;
}
.adm-card-row.is-hidden { opacity: 0.55; }
.adm-card-row.is-dragging { opacity: 0.4; }
.adm-card-row.is-drop-target {
  border-color: rgba(255,70,85,0.55);
  background: rgba(255,70,85,0.05);
}
.adm-card-row:hover { border-color: rgba(255,70,85,0.22); }
.adm-card-row .adm-nav-grip {
  background: transparent; border: 0; color: #5a6377; cursor: grab;
  padding: 4px; align-self: stretch;
}
.adm-card-row .adm-nav-grip:hover { color: #ff8a95; }
.adm-card-row .adm-row-actions {
  display: flex; flex-direction: column; gap: 6px; align-items: flex-end;
}

/* Sticky save bar */
.adm-page-head {
  position: sticky; top: 0; z-index: 5;
  background: linear-gradient(180deg, rgba(7,9,16,0.96), rgba(7,9,16,0.88));
  backdrop-filter: blur(10px);
  padding: 18px 4px; margin: -18px -4px 18px;
  border-bottom: 1px solid rgba(255,255,255,0.04);
}

/* ═══════════════════════════════════════════════════════
   BANNER TEMPLATES — Stelcsite /admin/uploads parity
   Clean, minimal, green-accented, light-panel design.
   Prefix: stx-  (stelc-style)
   ═══════════════════════════════════════════════════════ */
:root {
  --stx-bg: #f7f8fa;
  --stx-panel: #ffffff;
  --stx-border: #e8e8e8;
  --stx-border-lo: #f0f0f0;
  --stx-text: #1a1a1a;
  --stx-muted: #666;
  --stx-light: #888;
  --stx-accent: #10b981;
  --stx-accent-hi: #059669;
  --stx-danger: #ef4444;
}

/* Empty state */
.stx-empty {
  text-align: center; padding: 2.5rem 1rem;
  background: var(--stx-panel);
  border: 2px dashed var(--stx-border);
  border-radius: 14px;
  color: var(--stx-muted);
}
.stx-empty i { font-size: 2.5rem; color: var(--stx-accent); margin-bottom: .75rem; display:block; }
.stx-empty p { margin: 0 0 .25rem; font-weight: 600; color: var(--stx-text); font-size: .95rem; }
.stx-empty span { font-size: .85rem; color: var(--stx-muted); }

/* Banner list (row items) */
.stx-banner-list { display: flex; flex-direction: column; gap: .5rem; }
.stx-banner-item {
  display: grid; grid-template-columns: 88px 1fr auto; gap: 1rem; align-items: center;
  padding: .75rem; background: var(--stx-panel);
  border: 1px solid var(--stx-border);
  border-radius: 12px;
  transition: all .2s;
}
.stx-banner-item:hover { border-color: var(--stx-accent); box-shadow: 0 2px 8px rgba(16,185,129,.08); }
.stx-banner-item.is-off { opacity: .55; }
.stx-banner-preview {
  width: 80px; height: 50px; border-radius: 8px; overflow: hidden;
  background: #fafafa; border: 1px solid var(--stx-border-lo);
  display: flex; align-items: center; justify-content: center;
}
.stx-banner-preview img { width: 100%; height: 100%; object-fit: cover; }
.stx-banner-preview video { width: 100%; height: 100%; object-fit: cover; }
.stx-banner-yt {
  width: 100%; height: 100%;
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  gap: 4px;
  background: linear-gradient(135deg, #c4302b 0%, #7a1e1a 100%);
  color: #fff;
  font-size: .7rem; font-weight: 700;
}
.stx-banner-yt i { font-size: 1rem; }
.stx-banner-placeholder {
  width: 100%; height: 100%;
  display: flex; align-items: center; justify-content: center;
  color: var(--stx-light); font-size: 1.1rem;
}
.stx-banner-info { min-width: 0; }
.stx-banner-title {
  font-size: .95rem; font-weight: 600; color: var(--stx-text);
  margin-bottom: .25rem;
  overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
}
.stx-banner-meta {
  display: flex; align-items: center; gap: .5rem; flex-wrap: wrap;
  font-size: .78rem; color: var(--stx-muted);
}
.stx-chip {
  display: inline-flex; align-items: center; gap: .35rem;
  padding: 3px 9px; border-radius: 99px;
  background: color-mix(in srgb, var(--c, #10b981) 12%, transparent);
  color: var(--c, #10b981);
  font-weight: 600; font-size: .72rem;
  border: 1px solid color-mix(in srgb, var(--c, #10b981) 25%, transparent);
}
.stx-meta-dot { display: inline-flex; align-items: center; gap: .3rem; color: var(--stx-light); }
.stx-banner-actions { display: flex; align-items: center; gap: .35rem; }

/* Small icon buttons */
.stx-btn-icon {
  width: 34px; height: 34px; border-radius: 8px;
  background: var(--stx-panel); border: 1px solid var(--stx-border);
  color: var(--stx-muted); cursor: pointer;
  display: inline-flex; align-items: center; justify-content: center;
  transition: all .15s;
}
.stx-btn-icon:hover {
  background: var(--stx-accent); color: #fff;
  border-color: var(--stx-accent);
}
.stx-btn-icon.stx-btn-danger:hover {
  background: var(--stx-danger); border-color: var(--stx-danger);
}

/* iOS-style switch */
.stx-switch { position: relative; display: inline-block; width: 40px; height: 22px; }
.stx-switch input { opacity: 0; width: 0; height: 0; }
.stx-switch-slider {
  position: absolute; inset: 0;
  background: #d1d5db; border-radius: 99px;
  cursor: pointer; transition: .2s;
}
.stx-switch-slider::before {
  content: ''; position: absolute;
  height: 16px; width: 16px; left: 3px; top: 3px;
  background: #fff; border-radius: 50%;
  transition: .2s; box-shadow: 0 1px 3px rgba(0,0,0,.25);
}
.stx-switch input:checked + .stx-switch-slider { background: var(--stx-accent); }
.stx-switch input:checked + .stx-switch-slider::before { transform: translateX(18px); }

/* ── Modal (Stelc light) ─────────────────────────────── */
.stx-modal-back {
  position: fixed; inset: 0; z-index: 9999;
  background: rgba(0,0,0,.5);
  -webkit-backdrop-filter: blur(6px); backdrop-filter: blur(6px);
  display: flex; align-items: center; justify-content: center;
  padding: 1rem; animation: stxFadeIn .18s ease-out;
}
@keyframes stxFadeIn { from { opacity: 0; } to { opacity: 1; } }
.stx-modal {
  background: var(--stx-panel); color: var(--stx-text);
  border-radius: 16px;
  width: min(720px, 100%); max-height: 92vh;
  display: flex; flex-direction: column;
  box-shadow: 0 20px 60px rgba(0,0,0,.35);
  animation: stxSlideUp .22s ease-out;
}
@keyframes stxSlideUp { from { transform: translateY(14px); opacity: 0; } to { transform: none; opacity: 1; } }
.stx-modal-head {
  display: flex; align-items: center; justify-content: space-between;
  padding: 1rem 1.25rem;
  border-bottom: 1px solid var(--stx-border-lo);
}
.stx-modal-head h3 {
  margin: 0; font-size: 1.05rem; font-weight: 700; color: var(--stx-text);
  display: flex; align-items: center; gap: .5rem;
}
.stx-modal-head h3 i { color: var(--stx-accent); }
.stx-modal-close {
  width: 34px; height: 34px; border-radius: 8px;
  background: transparent; border: 1px solid var(--stx-border);
  color: var(--stx-muted); cursor: pointer;
  display: grid; place-items: center; transition: all .15s;
}
.stx-modal-close:hover { background: var(--stx-border-lo); color: var(--stx-text); }
.stx-modal-body {
  padding: 1.25rem; overflow-y: auto; flex: 1;
  display: flex; flex-direction: column; gap: 1.1rem;
}
.stx-modal-foot {
  padding: .9rem 1.25rem;
  border-top: 1px solid var(--stx-border-lo);
  display: flex; align-items: center; gap: .5rem;
}
.stx-foot-right { margin-left: auto; display: flex; gap: .5rem; }

/* Form primitives */
.stx-form-row { display: flex; flex-direction: column; gap: .4rem; }
.stx-form-row-inline { flex-direction: row; align-items: center; gap: .75rem; }
.stx-form-row-inline .stx-label { margin-bottom: 0; flex: 0 0 auto; }
.stx-label {
  font-size: .82rem; font-weight: 600; color: var(--stx-text);
  display: flex; align-items: center; gap: .5rem;
}
.stx-label-hint { font-weight: 400; color: var(--stx-light); font-size: .75rem; }
.stx-input {
  width: 100%;
  padding: .6rem .8rem;
  background: var(--stx-panel); color: var(--stx-text);
  border: 1px solid var(--stx-border); border-radius: 8px;
  font-size: .9rem; transition: all .15s;
}
.stx-input:focus {
  outline: none; border-color: var(--stx-accent);
  box-shadow: 0 0 0 3px rgba(16,185,129,.12);
}
.stx-input-sm { width: 80px; }
.stx-input-group { display: inline-flex; align-items: center; gap: .5rem; }
.stx-input-suffix { font-size: .82rem; color: var(--stx-muted); }

/* Type chips */
.stx-type-chips {
  display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  gap: .5rem;
}
.stx-type-chip {
  text-align: left;
  display: flex; align-items: center; gap: .7rem;
  padding: .7rem .85rem;
  background: var(--stx-panel); border: 1px solid var(--stx-border);
  border-radius: 10px; cursor: pointer;
  transition: all .15s;
}
.stx-type-chip i {
  width: 34px; height: 34px; border-radius: 8px; flex: 0 0 auto;
  display: grid; place-items: center;
  background: #f0f9f5; color: var(--stx-accent); font-size: .9rem;
}
.stx-type-chip strong { display: block; font-size: .85rem; font-weight: 600; color: var(--stx-text); }
.stx-type-chip em { font-style: normal; font-size: .72rem; color: var(--stx-muted); }
.stx-type-chip:hover { border-color: var(--stx-accent); background: #f9fefb; }
.stx-type-chip.is-active {
  border-color: var(--stx-accent); background: #f0fdf7;
  box-shadow: 0 0 0 2px rgba(16,185,129,.15);
}
.stx-type-chip.is-active i { background: var(--stx-accent); color: #fff; }

/* Slots */
.stx-slots { display: flex; flex-direction: column; gap: .75rem; }
.stx-slot {
  display: grid; grid-template-columns: 220px 1fr; gap: .75rem;
  padding: .75rem; background: var(--stx-bg);
  border: 1px solid var(--stx-border-lo);
  border-radius: 12px;
}
.stx-upload-box {
  position: relative;
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  gap: .35rem; padding: 1rem;
  min-height: 120px;
  background: var(--stx-panel);
  border: 2px dashed var(--stx-border);
  border-radius: 10px; cursor: pointer;
  color: var(--stx-muted); text-align: center;
  transition: all .15s; overflow: hidden;
}
.stx-upload-box:hover { border-color: var(--stx-accent); background: #f9fefb; }
.stx-upload-box.is-drop { border-color: var(--stx-accent); background: #ecfdf5; }
.stx-upload-box i { font-size: 1.8rem; color: var(--stx-accent); }
.stx-upload-box span { font-size: .82rem; font-weight: 600; color: var(--stx-text); }
.stx-upload-box em { font-style: normal; font-size: .7rem; color: var(--stx-light); }
.stx-upload-box.has-image { padding: 0; border-style: solid; }
.stx-upload-preview {
  width: 100%; height: 100%; min-height: 120px;
  max-height: 200px; object-fit: cover;
}
.stx-slot-side { display: flex; flex-direction: column; gap: .5rem; justify-content: center; }
.stx-slot-tools { display: flex; align-items: center; gap: .5rem; }
.stx-slot-hint { font-size: .75rem; color: var(--stx-light); display: inline-flex; align-items: center; gap: .3rem; }

@media (max-width: 640px) {
  .stx-slot { grid-template-columns: 1fr; }
}

/* Buttons (light theme) */
.stx-btn {
  display: inline-flex; align-items: center; gap: .45rem;
  padding: .55rem 1rem; border-radius: 8px;
  font-size: .85rem; font-weight: 600;
  border: 1px solid var(--stx-border); background: var(--stx-panel); color: var(--stx-text);
  cursor: pointer; transition: all .15s;
}
.stx-btn:hover { border-color: var(--stx-accent); color: var(--stx-accent); }
.stx-btn-sm { padding: .35rem .65rem; font-size: .78rem; }
.stx-btn-primary {
  background: var(--stx-accent); border-color: var(--stx-accent); color: #fff;
}
.stx-btn-primary:hover { background: var(--stx-accent-hi); border-color: var(--stx-accent-hi); color: #fff; }
.stx-btn-ghost { background: transparent; }
.stx-btn-danger-ghost {
  background: transparent; color: var(--stx-danger);
  border-color: color-mix(in srgb, var(--stx-danger) 30%, transparent);
}
.stx-btn-danger-ghost:hover { background: var(--stx-danger); color: #fff; border-color: var(--stx-danger); }
.stx-btn-add { width: 100%; justify-content: center; border-style: dashed; }

/* The admin card wrapping stx content: neutralize dark overrides */
.adm-card.stx-card {
  background: var(--stx-panel); color: var(--stx-text);
  border: 1px solid var(--stx-border);
}
.adm-card.stx-card .adm-card-head h3 { color: var(--stx-text); }
.adm-card.stx-card .adm-card-head h3 i { color: var(--stx-accent); }
.adm-card.stx-card .adm-help { color: var(--stx-muted); }
.adm-card.stx-card .adm-help i { color: var(--stx-accent); }
.adm-card.stx-card .adm-badge { background: #f0fdf7; color: var(--stx-accent); border-color: rgba(16,185,129,.25); }
.adm-card.stx-card .adm-btn-sm,
.adm-card.stx-card .adm-btn {
  background: var(--stx-accent); border-color: var(--stx-accent); color: #fff;
}
.adm-card.stx-card .adm-btn-sm:hover,
.adm-card.stx-card .adm-btn:hover {
  background: var(--stx-accent-hi); border-color: var(--stx-accent-hi);
}
