:root {
  --bg: #060807;
  --bg-elev: #0b0f0c;
  --card: rgba(16, 22, 18, 0.92);
  --card-solid: #101612;
  --card-2: #151e18;
  --ink: #f1f6ef;
  --muted: #98a89a;
  --dim: #67776a;
  --line: rgba(255, 255, 255, 0.08);
  --line-strong: rgba(255, 255, 255, 0.16);
  --lime: #b6f36c;
  --lime-deep: #7ed321;
  --lime-soft: rgba(182, 243, 108, 0.14);
  --fb: #3b82f6;
  --fb-soft: rgba(59, 130, 246, 0.16);
  --cyan: #38bdf8;
  --gold: #fbbf24;
  --violet: #c084fc;
  --coral: #fb7185;
  --emerald: #34d399;
  --radius: 18px;
  --radius-sm: 11px;
  --font-sans: Inter, -apple-system, BlinkMacSystemFont, "SF Pro Display", "Segoe UI", sans-serif;
  --font-mono: ui-monospace, SFMono-Regular, Menlo, Monaco, monospace;
}

html[data-theme="light"] {
  --bg: #f3f6f1;
  --bg-elev: #ffffff;
  --card: #ffffff;
  --card-solid: #ffffff;
  --card-2: #ebf1e8;
  --ink: #0c140a;
  --muted: #465748;
  --dim: #657667;
  --line: rgba(12, 20, 10, 0.1);
  --line-strong: rgba(12, 20, 10, 0.22);
  --lime: #367007;
  --lime-deep: #255004;
  --lime-soft: rgba(54, 112, 7, 0.11);
}

*, *::before, *::after { box-sizing: border-box; }

html, body {
  margin: 0;
  padding: 0;
  min-height: 100%;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--font-sans);
  -webkit-font-smoothing: antialiased;
  overflow-x: clip;
}

.ambient-mesh {
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 0;
  background:
    radial-gradient(620px 380px at 14% 8%, rgba(182, 243, 108, 0.085), transparent 68%),
    radial-gradient(540px 340px at 88% 12%, rgba(59, 130, 246, 0.095), transparent 70%),
    radial-gradient(480px 320px at 62% 88%, rgba(251, 191, 36, 0.055), transparent 70%);
}

html[data-theme="light"] .ambient-mesh { opacity: 0.45; }

.icon-sprite { position: absolute; width: 0; height: 0; overflow: hidden; }
.icon { width: 18px; height: 18px; flex: 0 0 auto; display: block; }
.icon-sm { width: 14px; height: 14px; }

@keyframes pulseRing {
  0%, 100% { box-shadow: 0 0 0 0 rgba(182, 243, 108, 0.55); }
  50% { box-shadow: 0 0 0 6px rgba(182, 243, 108, 0); }
}

@keyframes shimmerBar {
  0% { background-position: 0% 50%; }
  100% { background-position: 200% 50%; }
}

@keyframes fadeSlideUp {
  from { opacity: 0; transform: translateY(8px); }
  to { opacity: 1; transform: translateY(0); }
}

.live-dot {
  width: 8px;
  height: 8px;
  flex: 0 0 8px;
  border-radius: 50%;
  background: var(--lime);
  animation: pulseRing 2.1s infinite;
}

.arena-ticker[hidden],
.combined-bal-pill[hidden],
.modal-backdrop[hidden],
.drawer-backdrop[hidden] {
  display: none !important;
}

/* Live Ticker */
.arena-ticker {
  position: relative;
  z-index: 50;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding: 8px 16px;
  border-bottom: 1px solid rgba(182, 243, 108, 0.22);
  background: linear-gradient(90deg, rgba(182, 243, 108, 0.11), rgba(59, 130, 246, 0.12), rgba(251, 191, 36, 0.11));
  font-size: 12px;
  font-weight: 650;
  text-align: center;
}

/* Topbar */
.topbar {
  position: sticky;
  top: 0;
  z-index: 45;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  min-height: 66px;
  padding: 0 20px;
  border-bottom: 1px solid var(--line);
  background: rgba(6, 8, 7, 0.86);
  backdrop-filter: blur(20px);
}

html[data-theme="light"] .topbar { background: rgba(255, 255, 255, 0.94); }

.topbar-left, .topbar-right {
  display: flex;
  align-items: center;
  gap: 10px;
  min-width: 0;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
  color: inherit;
  min-width: 0;
}

.brand-logo {
  width: 38px;
  height: 38px;
  border-radius: 11px;
  flex: 0 0 38px;
  box-shadow: 0 6px 22px rgba(182, 243, 108, 0.18);
}

.brand-copy { display: grid; gap: 1px; min-width: 0; }
.brand-copy strong {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  font-size: 16.5px;
  font-weight: 850;
  letter-spacing: -0.04em;
  white-space: nowrap;
}

.studio-pill {
  font-style: normal;
  font-size: 9.5px;
  font-weight: 900;
  letter-spacing: 0.11em;
  padding: 2.5px 8px;
  border-radius: 999px;
  background: linear-gradient(135deg, #e0ffb5, #b6f36c 55%, #38bdf8);
  color: #071004;
}

.brand-copy small {
  font-size: 9px;
  font-weight: 700;
  letter-spacing: 0.1em;
  color: var(--dim);
  white-space: nowrap;
}

/* Geo Currency Switcher */
.currency-seg {
  display: inline-flex;
  padding: 3px;
  border-radius: 999px;
  border: 1px solid var(--line-strong);
  background: rgba(255, 255, 255, 0.035);
}

.currency-btn {
  padding: 5px 11px;
  border: 0;
  border-radius: 999px;
  background: transparent;
  color: var(--muted);
  font-size: 11px;
  font-weight: 800;
  cursor: pointer;
  transition: all 150ms ease;
  white-space: nowrap;
}

.currency-btn.active {
  background: linear-gradient(135deg, #dbffab, #b6f36c);
  color: #071104;
  box-shadow: 0 4px 14px rgba(182, 243, 108, 0.25);
}

html[data-theme="light"] .currency-btn.active {
  background: #2f6406;
  color: #ffffff;
}

.combined-bal-pill {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  min-height: 36px;
  padding: 0 12px;
  border: 1px solid rgba(182, 243, 108, 0.4);
  border-radius: 999px;
  background: rgba(182, 243, 108, 0.11);
  color: var(--ink);
  cursor: pointer;
  font-family: var(--font-mono);
}

.combined-bal-pill strong { font-size: 12.5px; color: var(--lime); }
.combined-bal-pill small { font-size: 9px; color: var(--muted); font-weight: 800; }

/* Buttons */
.primary-btn, .ghost-btn, .icon-btn, .accent-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  min-height: 38px;
  border-radius: var(--radius-sm);
  font-size: 12.5px;
  font-weight: 760;
  cursor: pointer;
  text-decoration: none;
  transition: transform 140ms ease, box-shadow 140ms ease, border-color 140ms ease, background 140ms ease;
  white-space: nowrap;
}

.primary-btn {
  padding: 0 16px;
  border: 0;
  color: #081204;
  background: linear-gradient(135deg, #e0ffb5 0%, #b6f36c 55%, #84d62e 100%);
  box-shadow: 0 8px 24px rgba(143, 221, 61, 0.24);
}

html[data-theme="light"] .primary-btn {
  color: #ffffff;
  background: linear-gradient(135deg, #43810c, #285504);
}

.accent-btn {
  padding: 0 15px;
  border: 1px solid rgba(59, 130, 246, 0.5);
  background: linear-gradient(135deg, rgba(59, 130, 246, 0.25), rgba(56, 189, 248, 0.14));
  color: #bae6fd;
}

html[data-theme="light"] .accent-btn { color: #1d4ed8; background: rgba(59, 130, 246, 0.12); }

.ghost-btn {
  padding: 0 13px;
  border: 1px solid var(--line-strong);
  background: rgba(255, 255, 255, 0.035);
  color: var(--ink);
}

.icon-btn {
  width: 38px;
  padding: 0;
  border: 1px solid var(--line-strong);
  background: rgba(255, 255, 255, 0.035);
  color: var(--ink);
}

.primary-btn:hover, .ghost-btn:hover, .icon-btn:hover, .accent-btn:hover {
  transform: translateY(-1.5px);
  border-color: rgba(182, 243, 108, 0.55);
}

.primary-btn:disabled { opacity: 0.45; cursor: not-allowed; transform: none; }
.full-width { width: 100%; }

.theme-toggle-btn .theme-icon-moon { display: none; }
html[data-theme="light"] .theme-toggle-btn .theme-icon-sun { display: none; }
html[data-theme="light"] .theme-toggle-btn .theme-icon-moon { display: block; }

.mobile-menu-btn, .drawer-head { display: none; }

/* Shell Layout */
.studio-shell {
  position: relative;
  display: grid;
  grid-template-columns: 268px minmax(0, 1fr);
  min-height: calc(100vh - 66px);
}

.sidebar {
  position: sticky;
  top: 66px;
  align-self: start;
  display: flex;
  flex-direction: column;
  min-width: 0;
  height: calc(100vh - 66px);
  padding: 16px 14px 36px;
  overflow-y: auto;
  overflow-x: hidden;
  border-right: 1px solid var(--line);
  background: rgba(9, 13, 10, 0.88);
  backdrop-filter: blur(18px);
}

html[data-theme="light"] .sidebar { background: #ffffff; }

.partner-card {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 10px;
  min-width: 0;
  padding: 13px;
  margin-bottom: 14px;
  overflow: hidden;
  border-radius: 15px;
  border: 1px solid rgba(182, 243, 108, 0.24);
  background: linear-gradient(155deg, rgba(182, 243, 108, 0.09), rgba(59, 130, 246, 0.06), rgba(0, 0, 0, 0.16));
}

.partner-card-top { display: flex; align-items: center; gap: 10px; min-width: 0; }
.partner-avatar {
  width: 38px;
  height: 38px;
  flex: 0 0 38px;
  display: grid;
  place-items: center;
  border-radius: 11px;
  background: linear-gradient(135deg, rgba(182, 243, 108, 0.28), rgba(56, 189, 248, 0.24));
  border: 1px solid rgba(182, 243, 108, 0.45);
  color: var(--lime);
  font-family: var(--font-mono);
  font-weight: 900;
  font-size: 13px;
}

.partner-meta { flex: 1 1 auto; min-width: 0; }
.partner-meta strong, .partner-meta small {
  display: block;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.partner-meta strong { font-size: 13px; }
.partner-meta small { font-size: 10.5px; color: var(--muted); margin-top: 1px; }

.partner-mini-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 7px; }
.partner-mini-cell {
  padding: 7px 8px;
  border-radius: 9px;
  background: rgba(0, 0, 0, 0.26);
  border: 1px solid var(--line);
  min-width: 0;
}
html[data-theme="light"] .partner-mini-cell { background: var(--card-2); }
.partner-mini-cell span { display: block; font-size: 8.5px; text-transform: uppercase; letter-spacing: 0.08em; color: var(--dim); }
.partner-mini-cell strong { display: block; margin-top: 2px; font-family: var(--font-mono); font-size: 12px; color: var(--lime); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

.nav-kicker {
  margin: 12px 10px 6px;
  font-size: 9.5px;
  font-weight: 850;
  letter-spacing: 0.14em;
  color: var(--dim);
  text-transform: uppercase;
}

.side-nav { display: grid; gap: 4px; }

.nav-item {
  display: flex;
  align-items: center;
  gap: 10px;
  min-width: 0;
  max-width: 100%;
  min-height: 44px;
  padding: 0 10px;
  border: 1px solid transparent;
  border-radius: 12px;
  background: transparent;
  color: var(--muted);
  cursor: pointer;
  text-align: left;
  transition: all 140ms ease;
}

.nav-item b {
  flex: 1 1 auto;
  min-width: 0;
  font-size: 12.5px;
  font-weight: 680;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.nav-item:hover { color: var(--ink); background: rgba(255, 255, 255, 0.04); }
.nav-item.active {
  border-color: rgba(182, 243, 108, 0.34);
  background: linear-gradient(90deg, rgba(182, 243, 108, 0.15), rgba(182, 243, 108, 0.03));
  color: var(--ink);
  box-shadow: inset 3px 0 0 var(--lime);
}

.nav-tile {
  width: 30px;
  height: 30px;
  flex: 0 0 30px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 9px;
  border: 1px solid var(--line);
}
.nav-tile .icon { width: 16px; height: 16px; }
.nav-tile--lime { background: linear-gradient(145deg, rgba(182, 243, 108, 0.26), rgba(132, 214, 46, 0.09)); border-color: rgba(182, 243, 108, 0.45); color: var(--lime); }
.nav-tile--fb { background: linear-gradient(145deg, rgba(59, 130, 246, 0.28), rgba(56, 189, 248, 0.12)); border-color: rgba(59, 130, 246, 0.48); color: #60a5fa; }
.nav-tile--gold { background: linear-gradient(145deg, rgba(251, 191, 36, 0.26), rgba(249, 115, 22, 0.12)); border-color: rgba(251, 191, 36, 0.48); color: var(--gold); }
.nav-tile--violet { background: linear-gradient(145deg, rgba(192, 132, 252, 0.26), rgba(139, 92, 246, 0.12)); border-color: rgba(192, 132, 252, 0.48); color: var(--violet); }
.nav-tile--cyan { background: linear-gradient(145deg, rgba(56, 189, 248, 0.26), rgba(16, 185, 129, 0.12)); border-color: rgba(56, 189, 248, 0.48); color: var(--cyan); }
.nav-tile--coral { background: linear-gradient(145deg, rgba(251, 113, 133, 0.26), rgba(244, 63, 94, 0.12)); border-color: rgba(251, 113, 133, 0.48); color: var(--coral); }

.nav-count {
  padding: 2px 7px;
  border-radius: 999px;
  border: 1px solid var(--line);
  font-family: var(--font-mono);
  font-size: 10px;
  font-weight: 800;
  color: var(--muted);
}
.nav-item.active .nav-count { border-color: rgba(182, 243, 108, 0.45); color: var(--lime); background: var(--lime-soft); }

.sidebar-links {
  display: grid;
  gap: 2px;
  margin-top: 14px;
  padding-top: 10px;
  border-top: 1px solid var(--line);
}
.sidebar-links a {
  display: flex;
  align-items: center;
  min-height: 31px;
  padding: 0 10px;
  border-radius: 8px;
  font-size: 11.5px;
  color: var(--muted);
  text-decoration: none;
}
.sidebar-links a:hover { color: var(--lime); background: rgba(255, 255, 255, 0.03); }

.sidebar-foot { margin-top: auto; padding-top: 14px; border-top: 1px solid var(--line); }
.authority-chip { display: flex; align-items: center; gap: 10px; padding: 6px 8px; }
.authority-chip strong { display: block; font-size: 11px; }
.authority-chip small { display: block; font-size: 10px; color: var(--dim); }

/* Main Stage & Bento Widgets */
.main-stage {
  min-width: 0;
  padding: clamp(18px, 2.8vw, 32px);
  max-width: 1400px;
  width: 100%;
  margin: 0 auto;
  animation: fadeSlideUp 220ms ease;
}

.eyebrow {
  margin: 0 0 6px;
  font-size: 10px;
  font-weight: 850;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--lime);
}

.widget {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--card);
  padding: 20px;
  min-width: 0;
  transition: border-color 180ms ease, box-shadow 180ms ease;
}

.widget:hover { border-color: rgba(255, 255, 255, 0.15); }
html[data-theme="light"] .widget { box-shadow: 0 4px 20px rgba(12, 20, 10, 0.04); }

/* Bento Row 1: Featured Facebook Campaign Deck + Dual-Income Simulator */
.bento-top {
  display: grid;
  grid-template-columns: minmax(0, 1.38fr) minmax(320px, 0.92fr);
  gap: 18px;
  margin-bottom: 18px;
}

.campaign-spotlight {
  padding: 0;
  overflow: hidden;
  border-color: rgba(59, 130, 246, 0.38);
  box-shadow: 0 20px 55px rgba(0, 0, 0, 0.36), 0 0 36px rgba(59, 130, 246, 0.08);
  display: flex;
  flex-direction: column;
}

.spotlight-cover {
  position: relative;
  height: 225px;
  overflow: hidden;
  background: #0a100c;
  border-bottom: 1px solid var(--line);
}

.spotlight-cover img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center 22%;
  filter: saturate(1.06) brightness(0.76);
  transition: transform 420ms ease;
}

.campaign-spotlight:hover .spotlight-cover img { transform: scale(1.03); }

.spotlight-scrim {
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(6, 8, 7, 0.38) 0%, rgba(6, 8, 7, 0.25) 45%, rgba(12, 17, 14, 0.97) 100%);
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  padding: 16px 20px;
}

.spotlight-badges {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  flex-wrap: wrap;
}

.chip {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 5px 11px;
  border-radius: 999px;
  font-size: 10.5px;
  font-weight: 850;
  letter-spacing: 0.07em;
  text-transform: uppercase;
  backdrop-filter: blur(10px);
}
.chip--fb { background: rgba(24, 119, 242, 0.92); color: #ffffff; box-shadow: 0 4px 16px rgba(24, 119, 242, 0.42); }
.chip--lime { background: rgba(182, 243, 108, 0.2); border: 1px solid rgba(182, 243, 108, 0.55); color: #dbffab; }
.chip--gold { background: rgba(251, 191, 36, 0.2); border: 1px solid rgba(251, 191, 36, 0.5); color: #fde68a; }
.chip--cyan { background: rgba(56, 189, 248, 0.2); border: 1px solid rgba(56, 189, 248, 0.48); color: #bae6fd; }
.chip--coral { background: rgba(251, 113, 133, 0.2); border: 1px solid rgba(251, 113, 133, 0.48); color: #fecdd3; }
.chip--muted { background: rgba(255, 255, 255, 0.08); border: 1px solid var(--line-strong); color: var(--muted); }
html[data-theme="light"] .chip--lime { color: #244f03; background: rgba(182, 243, 108, 0.38); }
html[data-theme="light"] .chip--gold { color: #92400e; }
html[data-theme="light"] .chip--cyan { color: #0369a1; }

.spotlight-rate-hero {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
}

.spotlight-rate-hero h1 {
  margin: 0;
  font-size: clamp(20px, 2.3vw, 27px);
  line-height: 1.15;
  letter-spacing: -0.03em;
  color: #ffffff;
}

.rate-pill-big {
  padding: 8px 14px;
  border-radius: 13px;
  background: rgba(10, 16, 11, 0.88);
  border: 1.5px solid rgba(182, 243, 108, 0.65);
  text-align: right;
  box-shadow: 0 8px 26px rgba(0, 0, 0, 0.45);
}
.rate-pill-big strong { display: block; font-family: var(--font-mono); font-size: 19px; color: #c9fb8c; line-height: 1.1; }
.rate-pill-big span { display: block; font-size: 10.5px; color: #cbd5cb; margin-top: 2px; font-weight: 700; }

.spotlight-body {
  padding: 18px 20px 20px;
  display: grid;
  gap: 15px;
}

.spotlight-summary { margin: 0; font-size: 13px; color: var(--muted); line-height: 1.55; }

/* Interactive 10K / 25K / 100K / 500K Payout Ladder */
.milestone-ladder {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 8px;
}

.milestone-btn {
  padding: 10px 10px;
  border-radius: 12px;
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.03);
  color: var(--ink);
  text-align: left;
  cursor: pointer;
  transition: all 160ms ease;
}

.milestone-btn:hover, .milestone-btn.active {
  border-color: rgba(182, 243, 108, 0.58);
  background: linear-gradient(150deg, rgba(182, 243, 108, 0.16), rgba(56, 189, 248, 0.08));
  transform: translateY(-2px);
}

.milestone-btn span { display: block; font-size: 10px; font-weight: 800; color: var(--dim); text-transform: uppercase; letter-spacing: 0.06em; }
.milestone-btn strong { display: block; margin-top: 4px; font-family: var(--font-mono); font-size: 15px; color: var(--lime); }
.milestone-btn small { display: block; margin-top: 2px; font-family: var(--font-mono); font-size: 10.5px; color: var(--muted); }

/* Animated Pool Meter */
.pool-meter {
  padding: 12px 14px;
  border-radius: 12px;
  border: 1px solid var(--line);
  background: rgba(0, 0, 0, 0.22);
  display: grid;
  gap: 7px;
}
html[data-theme="light"] .pool-meter { background: var(--card-2); }
.pool-meter-top { display: flex; justify-content: space-between; font-size: 12px; font-family: var(--font-mono); gap: 8px; flex-wrap: wrap; }
.pool-track { height: 9px; border-radius: 999px; background: rgba(255, 255, 255, 0.08); overflow: hidden; }
.pool-fill {
  height: 100%;
  border-radius: 999px;
  background: linear-gradient(90deg, #b6f36c, #38bdf8, #b6f36c);
  background-size: 200% 100%;
  animation: shimmerBar 3.5s linear infinite;
}

/* Conditions Preview Grid */
.cond-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 9px;
}

.cond-tile {
  display: flex;
  gap: 9px;
  align-items: start;
  padding: 10px 11px;
  border-radius: 11px;
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.025);
  min-width: 0;
}

.cond-tile small { display: block; font-size: 9.5px; font-weight: 800; text-transform: uppercase; letter-spacing: 0.07em; color: var(--dim); }
.cond-tile strong { display: block; margin-top: 2px; font-size: 12px; line-height: 1.38; color: var(--ink); word-break: break-word; }

/* Widget 2: Dual-Income Interactive Simulator */
.sim-widget {
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  gap: 14px;
  border-color: rgba(182, 243, 108, 0.28);
  background:
    radial-gradient(100% 70% at 100% 0%, rgba(251, 191, 36, 0.13), transparent 62%),
    var(--card);
}

.sim-total-box {
  padding: 15px 16px;
  border-radius: 14px;
  border: 1px solid rgba(182, 243, 108, 0.38);
  background: linear-gradient(155deg, rgba(182, 243, 108, 0.14), rgba(56, 189, 248, 0.07));
}

.sim-total-box small { display: block; font-size: 10px; font-weight: 800; letter-spacing: 0.1em; color: var(--muted); text-transform: uppercase; }
.sim-total-box strong { display: block; margin-top: 4px; font-family: var(--font-mono); font-size: 30px; letter-spacing: -0.03em; color: var(--lime); font-variant-numeric: tabular-nums; }
.sim-total-box em { display: block; font-style: normal; font-family: var(--font-mono); font-size: 12px; color: var(--muted); margin-top: 2px; }

.sim-stack-bar {
  display: flex;
  height: 10px;
  border-radius: 999px;
  overflow: hidden;
  background: rgba(255, 255, 255, 0.08);
  margin-top: 10px;
}
.sim-seg-views { background: var(--fb); transition: width 220ms ease; }
.sim-seg-comm { background: var(--lime); transition: width 220ms ease; }

.sim-legend {
  display: flex;
  justify-content: space-between;
  gap: 8px;
  margin-top: 8px;
  font-size: 11px;
  font-family: var(--font-mono);
}

.slider-group { display: grid; gap: 6px; }
.slider-head { display: flex; justify-content: space-between; align-items: baseline; font-size: 12px; }
.slider-head strong { font-family: var(--font-mono); color: var(--ink); }
.range-slider {
  -webkit-appearance: none;
  appearance: none;
  width: 100%;
  height: 7px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.14);
  accent-color: var(--lime);
  cursor: pointer;
}
html[data-theme="light"] .range-slider { background: rgba(12, 20, 10, 0.14); }
.range-slider::-webkit-slider-thumb {
  -webkit-appearance: none;
  appearance: none;
  width: 20px;
  height: 20px;
  border-radius: 50%;
  background: var(--lime);
  border: 2.5px solid #071104;
  box-shadow: 0 2px 10px rgba(182, 243, 108, 0.45);
}
.range-slider::-moz-range-thumb {
  width: 20px;
  height: 20px;
  border-radius: 50%;
  background: var(--lime);
  border: 2.5px solid #071104;
}

.spotlight-foot {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  padding-top: 4px;
}
.spotlight-actions, .vanity-actions {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}
.widget-head-row {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 10px;
  flex-wrap: wrap;
}
.caption-box-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
  margin-bottom: 8px;
}
.page-head-row {
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  gap: 12px;
  flex-wrap: wrap;
  margin-bottom: 16px;
}

/* Bento Row 2: Vanity Link Command Widget + Brand Assets Shelf */
.bento-mid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  gap: 18px;
  margin-bottom: 18px;
}

.vanity-box {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding: 12px 14px;
  border-radius: 12px;
  border: 1px solid rgba(56, 189, 248, 0.42);
  background: rgba(56, 189, 248, 0.08);
  margin: 12px 0;
}

.vanity-box code {
  font-family: var(--font-mono);
  font-size: 13px;
  font-weight: 700;
  color: var(--cyan);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.mini-kpi-row {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 8px;
}

.mini-kpi {
  padding: 9px 10px;
  border-radius: 10px;
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.025);
}
.mini-kpi span { display: block; font-size: 9px; text-transform: uppercase; color: var(--dim); letter-spacing: 0.06em; }
.mini-kpi strong { display: block; margin-top: 3px; font-family: var(--font-mono); font-size: 14px; }

/* Official Brand Assets Preview Cards */
.asset-preview-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
  margin: 12px 0;
}

.asset-preview-card {
  display: grid;
  gap: 8px;
  padding: 11px;
  border-radius: 12px;
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.025);
  text-decoration: none;
  color: inherit;
  transition: transform 150ms ease, border-color 150ms ease;
}

.asset-preview-card:hover { transform: translateY(-2px); border-color: rgba(182, 243, 108, 0.5); }

.checker-stage {
  height: 76px;
  border-radius: 9px;
  display: grid;
  place-items: center;
  background-color: #101511;
  background-image:
    linear-gradient(45deg, rgba(255,255,255,0.05) 25%, transparent 25%),
    linear-gradient(-45deg, rgba(255,255,255,0.05) 25%, transparent 25%),
    linear-gradient(45deg, transparent 75%, rgba(255,255,255,0.05) 75%),
    linear-gradient(-45deg, transparent 75%, rgba(255,255,255,0.05) 75%);
  background-size: 14px 14px;
  background-position: 0 0, 0 7px, 7px -7px, -7px 0;
  overflow: hidden;
}

.checker-stage img { max-width: 52px; max-height: 52px; object-fit: contain; }
.checker-stage img.thumb-fill { width: 100%; height: 100%; max-width: none; max-height: none; object-fit: cover; }
.asset-preview-card strong { font-size: 11.5px; display: block; }
.asset-preview-card small { font-size: 10px; color: var(--muted); display: block; }

/* Detail Brief, Forms & Tables */
.detail-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.3fr) minmax(320px, 0.9fr);
  gap: 18px;
  align-items: start;
}

.instructions-box {
  white-space: pre-line;
  font-size: 13.5px;
  line-height: 1.65;
  padding: 15px 16px;
  border-radius: 12px;
  border: 1px solid var(--line);
  background: rgba(0, 0, 0, 0.24);
}
html[data-theme="light"] .instructions-box { background: var(--card-2); }

.rules-list { list-style: none; padding: 0; margin: 0; display: grid; gap: 9px; }
.rules-list li { display: flex; gap: 9px; font-size: 13px; color: var(--muted); line-height: 1.45; }
.rules-list li::before { content: "✓"; color: var(--lime); font-weight: 900; }

.asset-list { display: grid; gap: 10px; }
.asset-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 12px 14px;
  border-radius: 12px;
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.025);
}
.asset-row strong { display: block; font-size: 13px; }
.asset-row small { display: block; font-size: 11.5px; color: var(--muted); margin-top: 2px; }

.kpi-grid-4 { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 14px; margin-bottom: 18px; }
.kpi-card { padding: 16px 18px; border-radius: 15px; border: 1px solid var(--line); background: var(--card); }
.kpi-card span { display: block; font-size: 10px; font-weight: 800; text-transform: uppercase; letter-spacing: 0.08em; color: var(--dim); }
.kpi-card strong { display: block; margin-top: 6px; font-family: var(--font-mono); font-size: 22px; }
.kpi-card strong.lime { color: var(--lime); }
.kpi-card strong.gold { color: var(--gold); }
.kpi-card strong.cyan { color: var(--cyan); }
.kpi-card small { display: block; margin-top: 4px; font-size: 11px; color: var(--muted); }

.form-stack { display: grid; gap: 12px; }
.form-grid-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.form-grid-3 { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 10px; }
.field { display: grid; gap: 5px; min-width: 0; }
.field label { font-size: 11.5px; font-weight: 700; color: var(--muted); }
.field input, .field select, .field textarea {
  width: 100%;
  min-height: 40px;
  padding: 8px 12px;
  border: 1px solid var(--line-strong);
  border-radius: 10px;
  background: rgba(0, 0, 0, 0.32);
  color: var(--ink);
  font-family: inherit;
  font-size: 13px;
  outline: none;
}
html[data-theme="light"] .field input, html[data-theme="light"] .field select, html[data-theme="light"] .field textarea { background: #f8faf7; }
.field input:focus, .field select:focus, .field textarea:focus { border-color: var(--lime); box-shadow: 0 0 0 3px var(--lime-soft); }

.form-error {
  margin: 0;
  padding: 10px 12px;
  border-radius: 10px;
  background: rgba(251, 113, 133, 0.14);
  border: 1px solid rgba(251, 113, 133, 0.45);
  color: var(--coral);
  font-size: 12.5px;
}

.table-wrap { width: 100%; overflow-x: auto; }
.data-table { width: 100%; border-collapse: collapse; font-size: 12.5px; }
.data-table th { text-align: left; padding: 10px 12px; font-size: 10px; text-transform: uppercase; letter-spacing: 0.09em; color: var(--dim); border-bottom: 1px solid var(--line); }
.data-table td { padding: 12px; border-bottom: 1px solid var(--line); vertical-align: top; }

.empty-box { padding: 30px; text-align: center; border: 1px dashed var(--line-strong); border-radius: 14px; color: var(--muted); }

/* Modal & Toast */
.modal-backdrop {
  position: fixed;
  inset: 0;
  z-index: 140;
  display: grid;
  place-items: center;
  padding: 16px;
  background: rgba(0, 0, 0, 0.74);
  backdrop-filter: blur(10px);
}
.modal-card {
  width: min(100%, 455px);
  padding: 24px;
  border-radius: 20px;
  border: 1px solid rgba(182, 243, 108, 0.38);
  background: var(--card-solid);
  box-shadow: 0 30px 80px rgba(0, 0, 0, 0.7);
}
.modal-head { display: flex; justify-content: space-between; align-items: start; gap: 12px; margin-bottom: 12px; }
.modal-head h2 { margin: 0; font-size: 20px; }
.partner-gate-note {
  display: flex;
  gap: 10px;
  align-items: start;
  padding: 11px 12px;
  margin-bottom: 14px;
  border-radius: 12px;
  background: rgba(251, 191, 36, 0.08);
  border: 1px solid rgba(251, 191, 36, 0.3);
  font-size: 12px;
  color: var(--muted);
  line-height: 1.5;
}
.modal-foot {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-top: 16px;
  padding-top: 14px;
  border-top: 1px solid var(--line);
  font-size: 12px;
  color: var(--muted);
}
.modal-foot a { color: var(--lime); font-weight: 750; text-decoration: none; }

.toast-stack { position: fixed; right: 18px; bottom: 18px; z-index: 160; display: grid; gap: 8px; max-width: 350px; }
.toast {
  padding: 11px 15px;
  border-radius: 12px;
  border: 1px solid rgba(182, 243, 108, 0.48);
  background: #0e1610;
  color: #eef5ec;
  font-size: 12.5px;
  font-weight: 650;
  box-shadow: 0 14px 36px rgba(0, 0, 0, 0.5);
}
.toast.is-error { border-color: rgba(251, 113, 133, 0.55); color: #fda4af; }

/* Mobile & Tablet Bottom Tab Bar */
.mobile-tabbar { display: none; }
.tab-badge[hidden] { display: none !important; }

.table-wrap { width: 100%; overflow-x: auto; -webkit-overflow-scrolling: touch; }

/* Responsive Hardening: Tablet Landscape (901px–1180px) */
@media (max-width: 1180px) {
  .studio-shell { grid-template-columns: 248px minmax(0, 1fr); }
  .sidebar { padding: 14px 12px 30px; }
  .main-stage { padding: 20px 22px 32px; }
  .bento-top, .bento-mid, .detail-grid { grid-template-columns: 1fr; }
  .kpi-grid-4 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

/* Responsive Hardening: Tablet Portrait (641px–900px) */
@media (max-width: 900px) {
  .studio-shell { display: block; }
  .mobile-menu-btn { display: inline-flex; }
  .hide-md { display: none !important; }
  .brand-copy small { display: none; }
  .topbar { min-height: 60px; padding: 0 14px; gap: 8px; }
  .topbar-left, .topbar-right { gap: 7px; }
  .brand-logo { width: 34px; height: 34px; flex: 0 0 34px; }
  .combined-bal-pill small { display: none; }
  .combined-bal-pill { padding: 0 10px; min-height: 34px; }
  .main-stage { padding: 16px 18px calc(92px + env(safe-area-inset-bottom)); }
  .spotlight-cover { height: 200px; }

  body.drawer-open { overflow: hidden; }
  .drawer-head { display: flex; justify-content: space-between; align-items: center; margin-bottom: 12px; }
  .sidebar {
    position: fixed;
    top: 0; left: 0; bottom: 0;
    z-index: 120;
    width: min(304px, 86vw);
    height: 100dvh;
    transform: translate3d(-105%, 0, 0);
    transition: transform 220ms cubic-bezier(0.22, 1, 0.36, 1);
    background: var(--bg-elev);
    box-shadow: 18px 0 60px rgba(0, 0, 0, 0.65);
  }
  body.drawer-open .sidebar { transform: translate3d(0, 0, 0); }
  .drawer-backdrop { position: fixed; inset: 0; z-index: 110; background: rgba(0, 0, 0, 0.68); backdrop-filter: blur(4px); }

  .mobile-tabbar {
    position: fixed;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 90;
    display: grid;
    grid-template-columns: repeat(5, minmax(0, 1fr));
    gap: 2px;
    padding: 6px 6px calc(8px + env(safe-area-inset-bottom));
    border-top: 1px solid var(--line-strong);
    background: rgba(8, 12, 9, 0.93);
    backdrop-filter: blur(22px);
    -webkit-backdrop-filter: blur(22px);
    box-shadow: 0 -10px 30px rgba(0, 0, 0, 0.44);
  }
  html[data-theme="light"] .mobile-tabbar {
    background: rgba(255, 255, 255, 0.96);
    box-shadow: 0 -8px 24px rgba(12, 20, 10, 0.08);
  }
  .tab-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 3px;
    min-height: 48px;
    padding: 4px 2px;
    border: 0;
    border-radius: 11px;
    background: transparent;
    color: var(--muted);
    font-size: 10px;
    font-weight: 750;
    cursor: pointer;
    transition: color 140ms ease, background 140ms ease;
    -webkit-tap-highlight-color: transparent;
  }
  .tab-ic {
    position: relative;
    width: 34px;
    height: 26px;
    border-radius: 9px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border: 1px solid transparent;
    transition: all 140ms ease;
  }
  .tab-ic .icon { width: 17px; height: 17px; }
  .tab-item.active { color: var(--ink); }
  .tab-item.active .tab-ic--lime { background: rgba(182, 243, 108, 0.2); border-color: rgba(182, 243, 108, 0.45); color: var(--lime); }
  .tab-item.active .tab-ic--fb { background: rgba(59, 130, 246, 0.22); border-color: rgba(59, 130, 246, 0.5); color: #60a5fa; }
  .tab-item.active .tab-ic--gold { background: rgba(251, 191, 36, 0.22); border-color: rgba(251, 191, 36, 0.5); color: var(--gold); }
  .tab-item.active .tab-ic--violet { background: rgba(192, 132, 252, 0.22); border-color: rgba(192, 132, 252, 0.5); color: var(--violet); }
  .tab-item.active .tab-ic--cyan { background: rgba(56, 189, 248, 0.22); border-color: rgba(56, 189, 248, 0.5); color: var(--cyan); }
  .tab-badge {
    position: absolute;
    top: -3px;
    right: -4px;
    min-width: 15px;
    height: 15px;
    padding: 0 4px;
    border-radius: 999px;
    background: var(--fb);
    color: #ffffff;
    font-style: normal;
    font-family: var(--font-mono);
    font-size: 9px;
    font-weight: 850;
    display: inline-flex;
    align-items: center;
    justify-content: center;
  }

  .toast-stack {
    left: 14px;
    right: 14px;
    bottom: calc(84px + env(safe-area-inset-bottom));
    max-width: none;
  }
}

/* Responsive Hardening: Mobile Phones (360px–640px) */
@media (max-width: 640px) {
  .arena-ticker {
    padding: 7px 12px;
    font-size: 11px;
    line-height: 1.38;
    text-align: left;
    justify-content: flex-start;
    gap: 8px;
  }
  .topbar {
    min-height: 56px;
    padding: 6px 10px;
    gap: 6px;
  }
  .topbar-left { gap: 6px; flex: 0 0 auto; }
  .topbar-right { gap: 5px; flex: 1 1 auto; justify-content: flex-end; }
  .mobile-menu-btn, .theme-toggle-btn {
    width: 34px;
    min-height: 34px;
    border-radius: 9px;
  }
  .mobile-menu-btn .icon, .theme-toggle-btn .icon { width: 16px; height: 16px; }
  .brand { gap: 6px; }
  .brand-logo { width: 30px; height: 30px; flex: 0 0 30px; border-radius: 9px; }
  .brand-copy strong { font-size: 15.5px; }
  .studio-pill, .hide-xs, .cur-flag, .cur-sym { display: none; }
  .currency-seg { padding: 2px; }
  .currency-btn { padding: 5px 8px; font-size: 10.5px; min-height: 26px; }
  .combined-bal-pill { display: none !important; }
  .auth-btn {
    min-height: 34px;
    padding: 0 10px;
    font-size: 11.5px;
    gap: 5px;
    border-radius: 9px;
    max-width: 118px;
    overflow: hidden;
    text-overflow: ellipsis;
  }

  .main-stage { padding: 12px 12px calc(88px + env(safe-area-inset-bottom)); }
  .bento-top, .bento-mid, .detail-grid { gap: 13px; margin-bottom: 13px; }
  .widget { padding: 14px; border-radius: 15px; }
  .campaign-spotlight { padding: 0; }
  .spotlight-cover { height: 164px; }
  .spotlight-scrim { padding: 10px 12px; }
  .spotlight-badges { gap: 5px; }
  .chip { padding: 3.5px 7.5px; font-size: 9px; gap: 4px; }
  .rate-pill-big { padding: 6px 10px; border-radius: 10px; }
  .rate-pill-big strong { font-size: 15px; }
  .rate-pill-big span { font-size: 9.5px; }
  .spotlight-body { padding: 14px; gap: 12px; }
  .spotlight-body h1 { font-size: 18.5px !important; line-height: 1.22 !important; }
  .spotlight-summary { font-size: 12.5px; }

  .milestone-ladder { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 7px; }
  .milestone-btn { padding: 9px 10px; }
  .milestone-btn strong { font-size: 14px; }
  .pool-meter { padding: 10px 11px; }
  .pool-meter-top { font-size: 11px; }
  .cond-grid { grid-template-columns: 1fr; gap: 7px; }
  .cond-tile { padding: 9px 10px; }

  .spotlight-foot { flex-direction: column; align-items: stretch; gap: 10px; }
  .spotlight-actions { display: grid; grid-template-columns: 1fr; gap: 7px; width: 100%; }
  .spotlight-actions button,
  .vanity-actions button,
  .vanity-actions a { width: 100%; min-height: 42px; }

  .sim-total-box { padding: 13px; }
  .sim-total-box strong { font-size: 24px; }
  .sim-total-box em { font-size: 11px; line-height: 1.4; }
  .sim-legend { flex-wrap: wrap; font-size: 10.5px; gap: 4px 10px; }
  .slider-head { font-size: 11.5px; gap: 8px; }
  .range-slider::-webkit-slider-thumb { width: 24px; height: 24px; }

  .vanity-box { flex-direction: column; align-items: stretch; gap: 8px; padding: 10px 11px; }
  .vanity-box code { white-space: normal; word-break: break-all; font-size: 12px; }
  .vanity-box button { width: 100%; min-height: 38px; }

  .mini-kpi-row, .kpi-grid-4 { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 7px; }
  .kpi-card { padding: 12px 13px; }
  .kpi-card strong { font-size: 18px; }

  .asset-preview-grid { grid-template-columns: repeat(2, minmax(0, 1fr)) !important; gap: 8px; }
  .asset-preview-grid > :nth-child(3):last-child { grid-column: 1 / -1; }
  .asset-row { flex-direction: column; align-items: stretch; gap: 9px; padding: 11px 12px; }
  .asset-row > a, .asset-row > button { width: 100%; min-height: 38px; }

  .form-grid-2, .form-grid-3 { grid-template-columns: 1fr; }
  .field input, .field select, .field textarea { font-size: 16px; min-height: 44px; }
  .data-table { min-width: 560px; }

  .page-head-row h1 { font-size: 20px !important; line-height: 1.2; }
  .page-head-row > a, .page-head-row > button { width: 100%; min-height: 42px; white-space: normal; text-align: center; padding: 8px 12px; }

  .modal-card { padding: 18px; max-height: 92dvh; overflow-y: auto; border-radius: 16px; }
  .modal-foot { flex-direction: column; align-items: flex-start; gap: 6px; }
}
