/* ── Variables ── */
:root {
  --sky:       #4fc3f7;
  --blue:      #2979ff;
  --violet:    #7c4dff;
  --purple:    #9c27b0;
  --grad:      linear-gradient(135deg, #4fc3f7 0%, #7c4dff 60%, #b040d8 100%);
  --grad-text: linear-gradient(90deg, #4fc3f7, #9c6fff);
  --dark:      #09080f;
  --panel:     #0f0d1a;
  --card:      #141221;
  --border:    rgba(124,77,255,0.2);
  --border-hi: rgba(124,77,255,0.5);
  --smoke:     #6e6a85;
  --bone:      #d4cfea;
  --white:     #f0eeff;
}

/* ── Reset ── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }

body {
  background: var(--dark);
  color: var(--bone);
  font-family: 'Outfit', sans-serif;
  font-weight: 300;
  overflow-x: hidden;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

/* ── Noise overlay ── */
body::before {
  content: '';
  position: fixed; inset: 0;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 200 200' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.85' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)' opacity='0.035'/%3E%3C/svg%3E");
  pointer-events: none;
  z-index: 9999;
  opacity: 0.5;
}

/* ── Scrollbar ── */
::-webkit-scrollbar { width: 5px; }
::-webkit-scrollbar-track { background: var(--dark); }
::-webkit-scrollbar-thumb { background: var(--violet); border-radius: 3px; }

/* ── NAV ── */
nav {
  position: fixed; top: 0; left: 0; right: 0; z-index: 100;
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  padding: 0 2rem; height: 66px;
  background: rgba(9,8,15,0.85);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border-bottom: 1px solid var(--border);
  gap: 1.5rem;
}

.nav-logo {
  display: flex; align-items: center; gap: 0.75rem;
  text-decoration: none;
  cursor: pointer;
  justify-self: start;
}
.nav-logo img { width: 34px; height: 34px; object-fit: contain; }
.nav-logo-text {
  font-family: 'Bebas Neue', sans-serif;
  font-size: 1.7rem;
  letter-spacing: 0.12em;
  background: var(--grad-text);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.nav-links {
  display: flex; gap: 2.5rem; list-style: none;
  justify-content: center;
}
.nav-links a {
  font-family: 'Share Tech Mono', monospace;
  font-size: 0.74rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--smoke);
  text-decoration: none;
  transition: color .2s;
  position: relative;
}
.nav-links a::after {
  content: '';
  position: absolute; bottom: -4px; left: 0; right: 0;
  height: 1px;
  background: var(--grad);
  transform: scaleX(0); transform-origin: left;
  transition: transform .25s;
}
.nav-links a:hover,
.nav-links a.active { color: var(--white); }
.nav-links a:hover::after,
.nav-links a.active::after { transform: scaleX(1); }

.nav-discord {
  display: flex; align-items: center; gap: 0.5rem;
  font-family: 'Share Tech Mono', monospace;
  font-size: 0.68rem;
  letter-spacing: 0.1em;
  text-decoration: none;
  padding: 0.45rem 1rem;
  border-radius: 6px;
  background: linear-gradient(135deg, rgba(79,195,247,0.1), rgba(124,77,255,0.1));
  border: 1px solid var(--border-hi);
  color: var(--sky);
  transition: background .2s, border-color .2s, color .2s;
  white-space: nowrap;
}
.nav-discord:hover {
  background: linear-gradient(135deg, rgba(79,195,247,0.2), rgba(124,77,255,0.2));
  border-color: var(--sky);
  color: var(--white);
}

/* ── Nav actions group ── */
.nav-actions {
  display: flex; align-items: center; gap: 0.75rem;
  justify-self: end;
}

/* Ensure both nav buttons share the same height */
.nav-discord,
.nav-steam {
  height: 34px;
  box-sizing: border-box;
}

/* ── Sign in with Steam button ── */
.nav-steam {
  display: flex; align-items: center; gap: 0.5rem;
  font-family: 'Share Tech Mono', monospace;
  font-size: 0.68rem;
  letter-spacing: 0.1em;
  text-decoration: none;
  padding: 0.45rem 1rem;
  border-radius: 6px;
  background: linear-gradient(135deg, rgba(79,195,247,0.12), rgba(124,77,255,0.12));
  border: 1px solid var(--border-hi);
  color: var(--sky);
  transition: background .2s, border-color .2s, color .2s;
  white-space: nowrap;
}
.nav-steam:hover {
  background: linear-gradient(135deg, rgba(79,195,247,0.2), rgba(124,77,255,0.2));
  border-color: var(--sky);
  color: var(--white);
}
.steam-logo {
  flex-shrink: 0;
  display: block;
}

/* ── Account dropdown ── */
.nav-account {
  position: relative;
}

.nav-account-btn {
  display: flex; align-items: center; gap: 0.5rem;
  font-family: 'Share Tech Mono', monospace;
  font-size: 0.68rem;
  letter-spacing: 0.1em;
  padding: 0.35rem 0.75rem 0.35rem 0.45rem;
  border-radius: 6px;
  background: linear-gradient(135deg, rgba(124,77,255,0.1), rgba(79,195,247,0.08));
  border: 1px solid var(--border-hi);
  color: var(--bone);
  cursor: pointer;
  transition: background .2s, border-color .2s;
  white-space: nowrap;
}
.nav-account-btn:hover,
.nav-account.open .nav-account-btn {
  background: linear-gradient(135deg, rgba(124,77,255,0.2), rgba(79,195,247,0.14));
  border-color: var(--sky);
  color: var(--white);
}

.account-avatar {
  width: 26px; height: 26px;
  border-radius: 4px;
  object-fit: cover;
  flex-shrink: 0;
}
.account-avatar--icon {
  display: flex; align-items: center; justify-content: center;
  background: rgba(124,77,255,0.2);
  color: var(--violet);
  font-size: 0.75rem;
}
.account-name {
  max-width: 120px;
  overflow: hidden;
  text-overflow: ellipsis;
}
.account-rank-icon {
  width: 20px;
  height: 20px;
  object-fit: contain;
  flex-shrink: 0;
  image-rendering: -webkit-optimize-contrast;
  image-rendering: crisp-edges;
  filter: drop-shadow(0 0 4px rgba(124,77,255,0.55));
}

.account-chevron {
  font-size: 0.55rem;
  opacity: 0.6;
  transition: transform .2s;
}
.nav-account.open .account-chevron {
  transform: rotate(180deg);
}

.account-dropdown {
  position: absolute; top: calc(100% + 10px); right: 0;
  min-width: 180px;
  background: var(--panel);
  border: 1px solid var(--border-hi);
  border-radius: 10px;
  padding: 0.4rem 0;
  list-style: none;
  box-shadow: 0 8px 32px rgba(0,0,0,0.5);
  opacity: 0;
  visibility: hidden;
  transform: translateY(-6px);
  transition: opacity .18s, transform .18s, visibility .18s;
  z-index: 200;
}
.nav-account.open .account-dropdown {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}

.account-dropdown a {
  display: flex; align-items: center; gap: 0.65rem;
  padding: 0.6rem 1rem;
  font-family: 'Share Tech Mono', monospace;
  font-size: 0.7rem;
  letter-spacing: 0.1em;
  color: var(--smoke);
  text-decoration: none;
  transition: color .15s, background .15s;
}
.account-dropdown a:hover {
  color: var(--white);
  background: rgba(124,77,255,0.1);
}
.account-dropdown a i {
  width: 14px; text-align: center; opacity: 0.7;
}
.dropdown-divider {
  height: 1px;
  background: var(--border);
  margin: 0.35rem 0;
}
.dropdown-logout,
.dropdown-admin {
  color: #e57373 !important;
}
.dropdown-logout:hover,
.dropdown-admin:hover {
  background: rgba(229,115,115,0.1) !important;
  color: #ef9a9a !important;
}

/* ── Page wrapper ── */
#page-content {
  flex: 1;
  padding-top: 66px;
  transition: opacity 0.25s ease;
}
#page-content.fade-out { opacity: 0; }
#page-content.fade-in  { opacity: 1; }

/* ── Footer ── */
footer {
  background: var(--panel);
  border-top: 1px solid var(--border);
  padding: 2rem 3rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  flex-wrap: wrap;
}
.footer-logo {
  display: flex; align-items: center; gap: 0.6rem;
  text-decoration: none;
}
.footer-logo img { width: 24px; height: 24px; opacity: 0.7; }
.footer-logo-text {
  font-family: 'Bebas Neue', sans-serif;
  font-size: 1.1rem;
  letter-spacing: 0.12em;
  background: var(--grad-text);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  opacity: 0.8;
}
.footer-copy {
  font-family: 'Share Tech Mono', monospace;
  font-size: 0.68rem;
  letter-spacing: 0.1em;
  color: var(--smoke);
}
.footer-links {
  display: flex; gap: 1.5rem; list-style: none;
}
.footer-links a {
  font-family: 'Share Tech Mono', monospace;
  font-size: 0.68rem;
  letter-spacing: 0.1em;
  color: var(--smoke);
  text-decoration: none;
  transition: color .2s;
}
.footer-links a:hover { color: var(--sky); }

/* ── Buttons ── */
.btn {
  display: inline-flex; align-items: center; gap: 0.5rem;
  font-family: 'Share Tech Mono', monospace;
  font-size: 0.8rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  text-decoration: none;
  padding: 0.75rem 1.75rem;
  border-radius: 8px;
  cursor: pointer;
  transition: transform .15s, box-shadow .2s, opacity .2s;
  border: none;
}
.btn:hover { transform: translateY(-2px); }
.btn:active { transform: translateY(0); }

.btn-primary {
  background: var(--grad);
  color: #fff;
  box-shadow: 0 4px 20px rgba(124,77,255,0.35);
}
.btn-primary:hover {
  box-shadow: 0 6px 28px rgba(124,77,255,0.55);
}
.btn-outline {
  background: transparent;
  border: 1px solid var(--border-hi);
  color: var(--bone);
}
.btn-outline:hover {
  border-color: var(--sky);
  color: var(--white);
}

/* ── Section helpers ── */
.section {
  padding: 5rem 3rem;
  max-width: 1200px;
  margin: 0 auto;
  width: 100%;
}
.section-full {
  padding: 5rem 3rem;
  width: 100%;
}

.section-label {
  font-family: 'Share Tech Mono', monospace;
  font-size: 0.7rem;
  letter-spacing: 0.3em;
  text-transform: uppercase;
  color: var(--violet);
  margin-bottom: 0.75rem;
  display: block;
}
.section-title {
  font-family: 'Bebas Neue', sans-serif;
  font-size: clamp(2rem, 4vw, 3rem);
  letter-spacing: 0.06em;
  color: var(--white);
  line-height: 1.1;
}
.section-sub {
  color: var(--smoke);
  font-size: 0.95rem;
  line-height: 1.7;
  margin-top: 0.75rem;
  max-width: 540px;
}

/* ── Cards ── */
.card {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 1.75rem;
  transition: border-color .2s, box-shadow .2s;
}
.card:hover {
  border-color: var(--border-hi);
  box-shadow: 0 4px 24px rgba(124,77,255,0.12);
}

/* ── Divider ── */
.divider {
  border: none;
  height: 1px;
  background: var(--border);
  margin: 0;
}

/* ════════════════════════════════════════════════════════════════════════════
   HOME PAGE
   ════════════════════════════════════════════════════════════════════════════ */

/* ── Hero ── */
.hero {
  min-height: calc(100vh - 66px);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 4rem 2rem;
  position: relative;
  overflow: hidden;
}
.hero::after {
  content: '';
  position: absolute;
  top: 50%; left: 50%;
  transform: translate(-50%, -50%);
  width: 800px; height: 500px;
  background: radial-gradient(ellipse at center, rgba(124,77,255,0.15) 0%, transparent 70%);
  pointer-events: none;
}
.hero-logo {
  width: 100px; height: 100px;
  object-fit: contain;
  margin-bottom: 1.5rem;
  filter: drop-shadow(0 0 24px rgba(124,77,255,0.5));
  animation: float 4s ease-in-out infinite;
}
@keyframes float {
  0%, 100% { transform: translateY(0); }
  50%       { transform: translateY(-10px); }
}
.hero-eyebrow {
  font-family: 'Share Tech Mono', monospace;
  font-size: 0.72rem;
  letter-spacing: 0.35em;
  text-transform: uppercase;
  color: var(--violet);
  margin-bottom: 1rem;
}
.hero-title {
  font-family: 'Bebas Neue', sans-serif;
  font-size: clamp(4rem, 10vw, 8rem);
  letter-spacing: 0.08em;
  line-height: 1;
  background: var(--grad-text);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  margin-bottom: 1rem;
}
.hero-tagline {
  font-size: clamp(1rem, 2vw, 1.2rem);
  color: var(--bone);
  font-weight: 300;
  max-width: 520px;
  line-height: 1.7;
  margin-bottom: 2.5rem;
}
.hero-actions {
  display: flex; gap: 1rem; flex-wrap: wrap; justify-content: center;
}

/* ── Features ── */
.features-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 1.5rem;
  margin-top: 3rem;
}
.feature-card {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 2rem 1.75rem;
  transition: border-color .2s, box-shadow .2s, transform .2s;
}
.feature-card:hover {
  border-color: var(--border-hi);
  box-shadow: 0 4px 28px rgba(124,77,255,0.14);
  transform: translateY(-4px);
}
.feature-icon {
  font-size: 1.6rem;
  margin-bottom: 1rem;
  background: var(--grad-text);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}
.feature-title {
  font-family: 'Bebas Neue', sans-serif;
  font-size: 1.3rem;
  letter-spacing: 0.06em;
  color: var(--white);
  margin-bottom: 0.5rem;
}
.feature-desc {
  font-size: 0.875rem;
  color: var(--smoke);
  line-height: 1.7;
}

/* ── CTA Banner ── */
.cta-banner {
  background: var(--panel);
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
  padding: 4rem 2rem;
  text-align: center;
}
.cta-banner .section-title { margin-bottom: 0.75rem; }
.cta-banner .section-sub { margin: 0 auto 2rem; }
.btn-group {
  display: flex; gap: 1rem; justify-content: center; flex-wrap: wrap;
}

/* ════════════════════════════════════════════════════════════════════════════
   MODAL (shared — reusable across all pages)
   ════════════════════════════════════════════════════════════════════════════ */

.modal-backdrop {
  position: fixed; inset: 0;
  background: rgba(0, 0, 0, 0.75);
  z-index: 900;
  display: flex; align-items: center; justify-content: center;
  padding: 1rem;
  opacity: 0; pointer-events: none;
  transition: opacity 0.2s ease;
}
.modal-backdrop.is-open {
  opacity: 1; pointer-events: all;
}
.modal {
  background: var(--panel);
  border: 1px solid var(--border-hi);
  border-radius: 16px;
  padding: 2.5rem 2rem;
  max-width: 460px;
  width: 100%;
  transform: translateY(20px) scale(0.97);
  transition: transform 0.2s ease;
}
.modal-backdrop.is-open .modal {
  transform: translateY(0) scale(1);
}
.modal-icon {
  width: 52px; height: 52px;
  border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  font-size: 1.4rem;
  margin: 0 auto 1.5rem;
}
.modal-icon--danger {
  background: rgba(239, 68, 68, 0.12);
  color: #ef4444;
  border: 1px solid rgba(239, 68, 68, 0.25);
}
.modal-icon--warning {
  background: rgba(124, 77, 255, 0.12);
  color: var(--violet);
  border: 1px solid rgba(124, 77, 255, 0.25);
}
.modal-title {
  font-family: 'Bebas Neue', sans-serif;
  font-size: 1.6rem;
  letter-spacing: 0.06em;
  color: var(--white);
  text-align: center;
  margin-bottom: 0.75rem;
}
.modal-body {
  font-size: 0.9rem;
  color: var(--smoke);
  line-height: 1.7;
  text-align: center;
  margin-bottom: 2rem;
}
.modal-body strong {
  color: var(--bone);
}
.modal-actions {
  display: flex; gap: 0.75rem; justify-content: center; flex-wrap: wrap;
}
.btn-danger {
  background: rgba(239, 68, 68, 0.15);
  border: 1px solid rgba(239, 68, 68, 0.4);
  color: #ef4444;
}
.btn-danger:hover {
  background: rgba(239, 68, 68, 0.25);
  border-color: #ef4444;
  color: #fff;
}
.btn-danger:disabled,
.btn-danger.is-loading {
  opacity: 0.5; cursor: not-allowed; pointer-events: none;
}

/* ════════════════════════════════════════════════════════════════════════════
   SETTINGS PAGE
   ════════════════════════════════════════════════════════════════════════════ */

.settings-layout {
  padding: 3rem 2rem;
  max-width: 760px;
  margin: 0 auto;
  width: 100%;
}
.settings-header {
  margin-bottom: 2.5rem;
}
.settings-header .section-label {
  margin-bottom: 0.5rem;
}
.settings-header .section-title {
  margin-bottom: 0;
}

/* Settings section card */
.settings-section {
  background: var(--panel);
  border: 1px solid var(--border);
  border-radius: 12px;
  overflow: hidden;
  margin-bottom: 1.5rem;
}
.settings-section-header {
  padding: 1.25rem 1.75rem;
  border-bottom: 1px solid var(--border);
  display: flex; align-items: center; gap: 0.75rem;
}
.settings-section-header i {
  font-size: 0.9rem;
  background: var(--grad-text);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}
.settings-section-title {
  font-family: 'Share Tech Mono', monospace;
  font-size: 0.75rem;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--bone);
}

/* Individual setting row */
.settings-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1.5rem;
  padding: 1.5rem 1.75rem;
}
.settings-row + .settings-row {
  border-top: 1px solid var(--border);
}
.settings-row-info {
  flex: 1;
}
.settings-row-label {
  font-size: 0.95rem;
  font-weight: 600;
  color: var(--white);
  margin-bottom: 0.25rem;
}
.settings-row-desc {
  font-size: 0.82rem;
  color: var(--smoke);
  line-height: 1.5;
}

/* ════════════════════════════════════════════════════════════════════════════
   RANK COLOR TOKENS
   Applied via [data-rank="X"] on cards, tier headers, and rank labels.
   --rank-s     : gradient start hex   --rank-s-rgb : start as bare r,g,b
   --rank-e     : gradient end hex     --rank-e-rgb : end   as bare r,g,b
   ════════════════════════════════════════════════════════════════════════════ */

/* Trial Moderator / Trial Administrator – teal → green */
[data-rank="6"],
[data-rank="9"]  { --rank-s: #2BFBAF; --rank-e: #36E13D; --rank-s-rgb: 43,251,175; --rank-e-rgb: 54,225,61;  }

/* Moderator / Administrator – blue → cyan */
[data-rank="7"],
[data-rank="10"] { --rank-s: #2B7AFB; --rank-e: #36DDE1; --rank-s-rgb: 43,122,251; --rank-e-rgb: 54,221,225; }

/* Senior Moderator / Senior Administrator – purple → indigo */
[data-rank="8"],
[data-rank="11"] { --rank-s: #902BFB; --rank-e: #3649E1; --rank-s-rgb: 144,43,251; --rank-e-rgb: 54,73,225;  }

/* Manager / Co-Owner – orange → crimson */
[data-rank="12"],
[data-rank="13"] { --rank-s: #FB752B; --rank-e: #E13661; --rank-s-rgb: 251,117,43; --rank-e-rgb: 225,54,97;  }

/* Owner – gold → ember */
[data-rank="14"] { --rank-s: #FBDD2B; --rank-e: #E16236; --rank-s-rgb: 251,221,43; --rank-e-rgb: 225,98,54;  }

/* ════════════════════════════════════════════════════════════════════════════
   STAFF PAGE
   ════════════════════════════════════════════════════════════════════════════ */

/* ── Hero ── */
.staff-hero {
  text-align: center;
  padding-bottom: 1.5rem;
}
.staff-hero-sub {
  max-width: 560px;
  margin: 1rem auto 0;
  font-size: 0.95rem;
  color: var(--smoke);
  line-height: 1.7;
}
.staff-hero-link {
  color: var(--sky);
  text-decoration: none;
  transition: color 0.15s;
}
.staff-hero-link:hover { color: var(--white); }

/* ── Org chart wrapper ── */
.staff-org-section { padding-top: 0.5rem; }

.staff-org {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0;
  padding-bottom: 3rem;
}

/* ── Tier ── */
.staff-tier {
  display: flex;
  flex-direction: column;
  align-items: center;
  width: 100%;
  max-width: 1000px;
}

.staff-tier-header {
  display: inline-flex;
  align-items: center;
  gap: 0.55rem;
  font-family: 'Share Tech Mono', monospace;
  font-size: 0.72rem;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  background:
    linear-gradient(#09080f, #09080f) padding-box,
    linear-gradient(135deg, var(--rank-s, #78909c), var(--rank-e, #78909c)) border-box;
  border: 2px solid transparent;
  border-radius: 999px;
  padding: 0.35rem 1rem 0.35rem 0.65rem;
  margin-bottom: 0.65rem;
}
.staff-tier-header span {
  color: var(--white);
}

/* ── Tier job description ── */
.staff-tier-desc {
  font-size: 0.82rem;
  color: var(--smoke);
  line-height: 1.65;
  text-align: center;
  max-width: 520px;
  margin: 0 auto 1.25rem;
  padding: 0 0.5rem;
}
.staff-tier-icon {
  width: 18px;
  height: 18px;
  object-fit: contain;
}

/* ── Cards row ── */
.staff-cards {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 1.25rem;
  width: 100%;
}

/* ── Individual card ── */
.staff-card {
  border: 1px solid transparent;
  background:
    linear-gradient(var(--card), var(--card)) padding-box,
    linear-gradient(135deg, var(--rank-s, #78909c), var(--rank-e, #78909c)) border-box;
  border-radius: 14px;
  padding: 1.5rem 1.25rem 1.25rem;
  width: 172px;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  gap: 0.45rem;
  box-shadow:
    -6px 0 20px rgba(var(--rank-s-rgb, 120,144,156), 0.18),
     6px 0 20px rgba(var(--rank-e-rgb, 120,144,156), 0.18),
     0 4px 20px rgba(var(--rank-s-rgb, 120,144,156), 0.1);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}
.staff-card:hover {
  transform: translateY(-4px);
  box-shadow:
    -10px 0 28px rgba(var(--rank-s-rgb, 120,144,156), 0.35),
     10px 0 28px rgba(var(--rank-e-rgb, 120,144,156), 0.35),
     0 6px 28px rgba(var(--rank-s-rgb, 120,144,156), 0.18);
}

/* ── Avatar ── */
.staff-card-avatar-wrap {
  position: relative;
  width: 72px;
  height: 72px;
  margin-bottom: 0.25rem;
  flex-shrink: 0;
}
.staff-card-avatar {
  width: 72px;
  height: 72px;
  border-radius: 50%;
  object-fit: cover;
  border: 2px solid transparent;
  background:
    linear-gradient(var(--card), var(--card)) padding-box,
    linear-gradient(135deg, var(--rank-s, #78909c), var(--rank-e, #78909c)) border-box;
}
.staff-card-avatar--fallback {
  width: 72px;
  height: 72px;
  border-radius: 50%;
  border: 2px solid transparent;
  background:
    rgba(var(--rank-s-rgb, 120,144,156), 0.1) padding-box,
    linear-gradient(135deg, var(--rank-s, #78909c), var(--rank-e, #78909c)) border-box;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.5rem;
  color: rgba(var(--rank-s-rgb, 120,144,156), 0.7);
}
.staff-card-rank-badge {
  position: absolute;
  bottom: -2px;
  right: -4px;
  width: 24px;
  height: 24px;
  object-fit: contain;
  filter: drop-shadow(0 1px 3px rgba(0,0,0,0.7));
}

/* ── Name, rank label, dates ── */
.staff-card-name {
  font-family: 'Outfit', sans-serif;
  font-weight: 600;
  font-size: 0.9rem;
  color: var(--white);
  line-height: 1.2;
  word-break: break-word;
}
.staff-card-rank {
  font-family: 'Share Tech Mono', monospace;
  font-size: 0.68rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  background: linear-gradient(90deg, var(--rank-s, var(--smoke)), var(--rank-e, var(--smoke)));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}
.staff-card-dates {
  display: flex;
  flex-direction: column;
  gap: 0.3rem;
  margin-top: 0.4rem;
  width: 100%;
}
.staff-card-date {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.4rem;
  font-size: 0.75rem;
  color: var(--smoke);
}
.staff-card-date i {
  font-size: 0.65rem;
  color: rgba(var(--rank-s-rgb, 120,144,156), 0.65);
}

/* ── Connector between tiers ── */
.staff-connector {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0;
  margin: 0.5rem 0;
  color: rgba(124, 77, 255, 0.35);
}
.staff-connector-line {
  width: 1px;
  height: 16px;
  background: linear-gradient(to bottom, rgba(124,77,255,0.4), rgba(79,195,247,0.25));
}
.staff-connector-chevron {
  font-size: 0.5rem;
  opacity: 0.45;
}

/* ── Y-split connector (Manager → both branches) ── */
.staff-split-connector {
  display: flex;
  flex-direction: column;
  align-items: center;
  width: 100%;
  max-width: 1000px;
}
.staff-split-stem {
  width: 2px;
  height: 20px;
  background: linear-gradient(to bottom, rgba(124,77,255,0.5), rgba(124,77,255,0.35));
}
.staff-split-bar {
  /* spans from center-of-left-column to center-of-right-column */
  width: 52%;
  height: 2px;
  background: linear-gradient(90deg,
    rgba(79,195,247,0.3),
    rgba(124,77,255,0.45),
    rgba(79,195,247,0.3));
}
.staff-split-drops {
  width: 52%;
  display: flex;
  justify-content: space-between;
}
.staff-split-drop {
  width: 2px;
  height: 20px;
  background: linear-gradient(to bottom, rgba(124,77,255,0.35), rgba(79,195,247,0.25));
}

/* ── Two-team branch container ── */
.staff-branches {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 2rem;
  width: 100%;
  max-width: 1000px;
  align-items: start;
}
.staff-branches--single {
  grid-template-columns: 1fr;
  max-width: 500px;
}

/* ── Individual branch column ── */
.staff-branch {
  display: flex;
  flex-direction: column;
  align-items: center;
}

/* Branch team label */
.staff-branch-label {
  font-family: 'Share Tech Mono', monospace;
  font-size: 0.65rem;
  letter-spacing: 0.25em;
  text-transform: uppercase;
  color: var(--smoke);
  opacity: 0.55;
  margin-bottom: 1rem;
}

/* Descriptions inside a branch column don't need a hard max-width */
.staff-branch .staff-tier-desc {
  max-width: 100%;
}

/* ── Empty state ── */
.staff-empty {
  text-align: center;
  padding: 4rem 1rem;
  color: var(--smoke);
}
.staff-empty-icon {
  font-size: 2.5rem;
  margin-bottom: 1rem;
  opacity: 0.35;
  display: block;
}

/* ── Responsive ── */
@media (max-width: 768px) {
  nav {
    padding: 0 1.25rem;
    grid-template-columns: 1fr auto;
    gap: 1rem;
  }
  .nav-links { display: none; }
  .section, .section-full { padding: 3rem 1.25rem; }
  footer { padding: 1.5rem 1.25rem; flex-direction: column; align-items: flex-start; }

  /* Stack branches vertically on mobile */
  .staff-branches {
    grid-template-columns: 1fr;
    gap: 0;
  }
  .staff-branches--single {
    max-width: 100%;
  }
  /* Hide the Y-split on mobile — replaced by a simple connector between the stacked branches */
  .staff-split-connector {
    display: none;
  }
  /* Add a simple connector above the second branch on mobile */
  .staff-branch + .staff-branch::before {
    content: '';
    display: block;
    width: 2px;
    height: 40px;
    background: linear-gradient(to bottom, rgba(124,77,255,0.4), rgba(79,195,247,0.25));
    margin: 0 auto 0;
  }
}

/* ════════════════════════════════════════════════════════════════════════════
   ADMIN PORTAL
   ════════════════════════════════════════════════════════════════════════════ */

/* ── Hero ── */
.admin-hero {
  text-align: center;
  padding-bottom: 0.5rem;
}

/* ── Sub-navigation tabs ── */
.admin-subnav {
  display: flex;
  align-items: center;
  gap: 0.25rem;
  padding: 0 2rem 0;
  border-bottom: 1px solid rgba(255,255,255,0.06);
  margin-bottom: 0;
}
.admin-subnav-spacer { flex: 1; }
.admin-subnav-exit {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  font-family: 'Share Tech Mono', monospace;
  font-size: 0.72rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: rgba(255,255,255,0.35);
  text-decoration: none;
  padding: 0.75rem 0 0.75rem 1.25rem;
  transition: color 0.15s;
}
.admin-subnav-exit:hover { color: #f87171; }
.admin-subnav-link {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  font-family: 'Share Tech Mono', monospace;
  font-size: 0.72rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--smoke);
  text-decoration: none;
  padding: 0.75rem 1.25rem;
  border-bottom: 2px solid transparent;
  transition: color 0.15s, border-color 0.15s;
  position: relative;
  bottom: -1px;
}
.admin-subnav-link:hover { color: var(--white); }
.admin-subnav-link.active {
  color: var(--violet);
  border-bottom-color: var(--violet);
}

/* ── Section wrapper ── */
.admin-section { padding-top: 2rem; }

/* ── Toolbar: title + Add Staff button ── */
.admin-table-toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 1.25rem;
  gap: 1rem;
}
.admin-table-title {
  font-family: 'Bebas Neue', sans-serif;
  font-size: 1.4rem;
  letter-spacing: 0.08em;
  color: var(--white);
  display: flex;
  align-items: center;
  gap: 0.6rem;
}
.admin-table-count {
  font-family: 'Share Tech Mono', monospace;
  font-size: 0.75rem;
  background: rgba(124,77,255,0.15);
  border: 1px solid rgba(124,77,255,0.3);
  color: var(--violet);
  border-radius: 999px;
  padding: 0.1rem 0.6rem;
  letter-spacing: 0.05em;
}

/* ── Table wrapper (horizontal scroll on small screens) ── */
.admin-table-wrap {
  overflow-x: auto;
  border-radius: 12px;
  border: 1px solid rgba(255,255,255,0.06);
}

/* ── Table ── */
.admin-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.88rem;
}
.admin-table thead tr {
  background: rgba(255,255,255,0.03);
  border-bottom: 1px solid rgba(255,255,255,0.07);
}
.admin-table th {
  font-family: 'Share Tech Mono', monospace;
  font-size: 0.65rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--smoke);
  padding: 0.75rem 1rem;
  text-align: left;
  white-space: nowrap;
}
.admin-table tbody tr {
  border-bottom: 1px solid rgba(255,255,255,0.04);
  border-left: 3px solid var(--rank-s, rgba(255,255,255,0.08));
  transition: background 0.15s;
}
.admin-table tbody tr:last-child { border-bottom: none; }
.admin-table tbody tr:hover { background: rgba(255,255,255,0.03); }
.admin-table td {
  padding: 0.75rem 1rem;
  color: var(--white);
  vertical-align: middle;
}

/* Column widths */
.col-avatar  { width: 52px; padding-right: 0 !important; }
.col-rank    { width: 220px; }
.col-name    { }
.col-steamid         { font-family: 'Share Tech Mono', monospace; font-size: 0.78rem; color: rgba(255,255,255,0.5); white-space: nowrap; }
.col-blacklist-reason { max-width: 260px; color: rgba(255,255,255,0.7); font-size: 0.85rem; }
.col-date    { width: 130px; color: var(--smoke) !important; font-size: 0.82rem; white-space: nowrap; }
.col-actions { width: 220px; }

/* ── Avatar in table ── */
.admin-table-avatar {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  object-fit: cover;
  display: block;
  border: 1px solid rgba(var(--rank-s-rgb, 120,144,156), 0.4);
}
.admin-table-avatar--fallback {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: rgba(255,255,255,0.05);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.9rem;
  color: var(--smoke);
}

/* ── Rank cell ── */
.admin-table-rank-cell {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}
.admin-table-rank-icon {
  width: 20px;
  height: 20px;
  object-fit: contain;
  flex-shrink: 0;
}
.admin-table-rank-label {
  font-family: 'Share Tech Mono', monospace;
  font-size: 0.72rem;
  letter-spacing: 0.1em;
  background: linear-gradient(90deg, var(--rank-s, var(--smoke)), var(--rank-e, var(--smoke)));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

/* ── Action buttons ── */
.admin-table-actions {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  flex-wrap: wrap;
}
.btn-sm {
  display: inline-flex;
  align-items: center;
  gap: 0.3rem;
  font-family: 'Share Tech Mono', monospace;
  font-size: 0.65rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  padding: 0.3rem 0.65rem;
  border-radius: 6px;
  border: none;
  cursor: pointer;
  transition: opacity 0.15s, transform 0.1s;
  white-space: nowrap;
}
.btn-sm:hover   { opacity: 0.85; transform: translateY(-1px); }
.btn-sm:active  { transform: translateY(0); }
.btn-sm:disabled { opacity: 0.4; cursor: not-allowed; transform: none; }

.btn-promote   { background: rgba(34,197,94,0.15);  color: #4ade80; border: 1px solid rgba(34,197,94,0.3);  }
.btn-demote    { background: rgba(234,179,8,0.15);  color: #fbbf24; border: 1px solid rgba(234,179,8,0.3);  }
.btn-remove    { background: rgba(239,68,68,0.15);  color: #f87171; border: 1px solid rgba(239,68,68,0.3);  }
.btn-blacklist { background: rgba(255,255,255,0.05); color: rgba(255,255,255,0.5); border: 1px solid rgba(255,255,255,0.12); }
.btn-blacklist:hover { background: rgba(255,255,255,0.09); color: rgba(255,255,255,0.75); border-color: rgba(255,255,255,0.2); }

/* Confirmation modal action buttons (full-weight) */
.btn-promote-action   { background: #16a34a; color: #fff; }
.btn-promote-action:hover   { background: #15803d; }
.btn-demote-action    { background: #b45309; color: #fff; }
.btn-demote-action:hover    { background: #92400e; }
.btn-remove-action    { background: #dc2626; color: #fff; }
.btn-remove-action:hover    { background: #b91c1c; }
.btn-blacklist-action { background: #2a2a2a; color: rgba(255,255,255,0.85); border: 1px solid rgba(255,255,255,0.15); }
.btn-blacklist-action:hover { background: #383838; }

/* Modal reason section */
.modal-reason-field { margin: 1rem 0 0.25rem; text-align: left; }
.modal-reason-other { margin-top: 0.5rem; }

.admin-no-action { color: rgba(255,255,255,0.2); font-size: 0.85rem; }

/* ── Modal additions for admin ── */
.modal-icon--promote    { background: rgba(34,197,94,0.15); color: #4ade80; }
.modal-icon--blacklist  { background: rgba(255,255,255,0.06); color: rgba(255,255,255,0.45); }
.modal-error {
  font-size: 0.82rem;
  color: #f87171;
  text-align: center;
  margin: 0.5rem 0 0;
  display: none;
}
.modal-error.is-visible { display: block; }

/* ── Add Staff modal ── */
.admin-input {
  width: 100%;
  background: rgba(255,255,255,0.05);
  border: 1px solid rgba(255,255,255,0.1);
  border-radius: 8px;
  padding: 0.6rem 0.85rem;
  color: var(--white);
  font-family: 'Share Tech Mono', monospace;
  font-size: 0.88rem;
  margin: 0.75rem 0 0;
  box-sizing: border-box;
  transition: border-color 0.15s;
}
.admin-input:focus {
  outline: none;
  border-color: rgba(124,77,255,0.5);
}
.admin-input::placeholder { color: rgba(255,255,255,0.25); }

.admin-field       { margin-top: 1rem; }
.admin-field-label {
  display: block;
  font-family: 'Share Tech Mono', monospace;
  font-size: 0.7rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--smoke);
  margin-bottom: 0.4rem;
}
.admin-select {
  width: 100%;
  background: rgba(255,255,255,0.05);
  border: 1px solid rgba(255,255,255,0.1);
  border-radius: 8px;
  padding: 0.6rem 0.85rem;
  color: var(--white);
  font-family: 'Outfit', sans-serif;
  font-size: 0.88rem;
  cursor: pointer;
  box-sizing: border-box;
}
.admin-select:focus { outline: none; border-color: rgba(124,77,255,0.5); }
.admin-select option { background: var(--panel); }

/* Add Staff search result preview */
.add-staff-result {
  display: flex;
  align-items: center;
  gap: 0.85rem;
  background: rgba(255,255,255,0.04);
  border: 1px solid rgba(255,255,255,0.08);
  border-radius: 10px;
  padding: 0.85rem 1rem;
  margin-top: 0.25rem;
}
.add-staff-avatar {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  object-fit: cover;
  flex-shrink: 0;
}
.add-staff-user-name   { font-weight: 600; color: var(--white); font-size: 0.95rem; }
.add-staff-user-status { font-size: 0.8rem; color: var(--smoke); margin-top: 0.15rem; }
.add-staff-user-status strong { color: var(--violet); }

/* ── Admin empty state ── */
.admin-empty {
  text-align: center;
  padding: 4rem 2rem;
  color: var(--smoke);
}
.admin-empty i {
  font-size: 2.5rem;
  margin-bottom: 1rem;
  display: block;
  opacity: 0.3;
}
