/* ══════════════════════════════════════════
   NIGHTWINGS — Shared Design System
   ══════════════════════════════════════════ */
@import url('https://fonts.googleapis.com/css2?family=Bricolage+Grotesque:opsz,wght@12..96,400..800&family=Hanken+Grotesk:wght@400;500;600;700;800&display=swap');

:root {
  --nw-void:   #0D0820;
  --nw-deep:   #1A0E3D;
  --nw-dark:   #2D1B69;
  --nw-rich:   #3D2B8A;
  --nw-mid:    #5B4EAE;
  --nw-soft:   #8B87C4;
  --nw-pale:   #B4B2DC;
  --nw-gold:   #F5B800;
  --nw-gold2:  #E8A800;
  --nw-white:  #FFFFFF;
  --nw-danger: #E05A37;
  --nw-success:#4CAF8A;

  --surface:       rgba(29,18,61,0.7);
  --surface-solid: #1D123D;
  --border:        rgba(180,178,220,0.1);
  --border-gold:   rgba(245,184,0,0.3);

  --text-1: #FFFFFF;
  --text-2: var(--nw-pale);
  --text-3: var(--nw-soft);

  --font-d:  'Bricolage Grotesque', sans-serif;
  --font-ui: 'Hanken Grotesk', sans-serif;

  --r-sm: 8px;
  --r-md: 12px;
  --r-lg: 16px;
  --r-xl: 24px;
  --r-pill: 999px;

  --nav-h: 68px;
  --sidebar-w: 220px;
  --t: 200ms ease;

  --shadow-card: 0 4px 24px rgba(0,0,0,0.35);
  --shadow-glow: 0 0 40px rgba(245,184,0,0.15);
}

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

html { scroll-behavior: smooth; }

body {
  font-family: var(--font-ui);
  background: var(--nw-void);
  color: var(--text-1);
  min-height: 100vh;
  -webkit-font-smoothing: antialiased;
}

/* ── Typography ── */
h1,h2,h3,h4 { font-family: var(--font-d); }
a { color: inherit; text-decoration: none; }
img { display: block; max-width: 100%; }

.label {
  font-size: 11px; letter-spacing: 3px; text-transform: uppercase;
  font-weight: 700; color: var(--nw-gold);
}
.t-display { font-family: var(--font-d); font-size: clamp(52px,8vw,88px); font-weight: 800; letter-spacing: -3px; line-height: 0.95; }
.t-h1 { font-family: var(--font-d); font-size: clamp(32px,5vw,48px); font-weight: 800; letter-spacing: -1.5px; line-height: 1.05; }
.t-h2 { font-family: var(--font-d); font-size: clamp(24px,3.5vw,32px); font-weight: 800; letter-spacing: -1px; }
.t-h3 { font-family: var(--font-d); font-size: 20px; font-weight: 700; }
.t-body { font-size: 16px; line-height: 1.65; color: var(--text-2); }
.t-small { font-size: 13px; color: var(--text-3); }

/* ── Gold divider ── */
.gold-line { width: 64px; height: 3px; background: var(--nw-gold); border-radius: 2px; }

/* ── Buttons ── */
.btn {
  display: inline-flex; align-items: center; gap: 8px;
  font-family: var(--font-ui); font-weight: 700; font-size: 14px;
  border: none; border-radius: var(--r-md); cursor: pointer;
  padding: 12px 24px; transition: var(--t); white-space: nowrap;
}
.btn-gold  { background: var(--nw-gold); color: var(--nw-deep); }
.btn-gold:hover { background: var(--nw-gold2); transform: translateY(-1px); }
.btn-outline {
  background: transparent; color: var(--text-1);
  border: 1.5px solid rgba(180,178,220,0.3);
}
.btn-outline:hover { border-color: rgba(180,178,220,0.6); background: rgba(255,255,255,0.05); }
.btn-ghost { background: rgba(255,255,255,0.06); color: var(--text-1); }
.btn-ghost:hover { background: rgba(255,255,255,0.1); }
.btn-danger { background: var(--nw-danger); color: #fff; }
.btn-sm { padding: 7px 16px; font-size: 13px; }
.btn-lg { padding: 15px 32px; font-size: 16px; }

/* ── Cards ── */
.card {
  background: linear-gradient(145deg, rgba(61,43,138,0.25), rgba(13,8,32,0.6));
  border: 1px solid var(--border);
  border-radius: var(--r-xl);
  padding: 24px;
  transition: var(--t);
}
.card:hover { border-color: rgba(180,178,220,0.22); transform: translateY(-2px); box-shadow: var(--shadow-card); }
.card-gold { border-color: var(--border-gold); }

/* ── Section wrapper ── */
.section { padding: 80px 0; position: relative; }
.section-inner { max-width: 1200px; margin: 0 auto; padding: 0 56px; }
.section-header { margin-bottom: 48px; }
.section-header .label { margin-bottom: 12px; display: block; }

/* ── Horizontal rule ── */
.nw-hr { border: none; border-top: 1px solid var(--border); margin: 0; }

/* ── Badge ── */
.badge {
  display: inline-flex; align-items: center; gap: 6px;
  font-size: 12px; font-weight: 700; padding: 4px 10px;
  border-radius: var(--r-pill); letter-spacing: 0.5px;
}
.badge-gold   { background: rgba(245,184,0,0.12); color: var(--nw-gold); border: 1px solid rgba(245,184,0,0.25); }
.badge-purple { background: rgba(91,78,174,0.2);  color: var(--nw-pale); border: 1px solid rgba(91,78,174,0.3); }
.badge-danger { background: rgba(224,90,55,0.15); color: #FF7A5A;         border: 1px solid rgba(224,90,55,0.25); }
.badge-success{ background: rgba(76,175,138,0.15); color: #5ECFA6;        border: 1px solid rgba(76,175,138,0.25); }

/* ── Form elements ── */
.form-group { display: flex; flex-direction: column; gap: 6px; }
.form-label { font-size: 12px; font-weight: 700; letter-spacing: 0.5px; color: var(--text-3); text-transform: uppercase; }
.form-input, .form-select, .form-textarea {
  background: rgba(29,18,61,0.8); border: 1.5px solid var(--border);
  border-radius: var(--r-md); color: var(--text-1);
  font-family: var(--font-ui); font-size: 14px;
  padding: 10px 14px; transition: var(--t);
  width: 100%;
}
.form-input:focus, .form-select:focus, .form-textarea:focus {
  outline: none; border-color: rgba(245,184,0,0.5);
  box-shadow: 0 0 0 3px rgba(245,184,0,0.1);
}
.form-textarea { resize: vertical; min-height: 100px; }

/* ── Table ── */
.nw-table { width: 100%; border-collapse: collapse; }
.nw-table th {
  font-size: 11px; font-weight: 700; letter-spacing: 2px; text-transform: uppercase;
  color: var(--text-3); padding: 12px 16px; text-align: left;
  border-bottom: 1px solid var(--border);
}
.nw-table td { padding: 14px 16px; font-size: 14px; border-bottom: 1px solid rgba(180,178,220,0.06); }
.nw-table tr:hover td { background: rgba(255,255,255,0.03); }

/* ── Public Nav ── */
.main-nav {
  display: flex; align-items: center; justify-content: space-between;
  height: var(--nav-h); padding: 0 56px;
  background: rgba(13,8,32,0.85);
  border-bottom: 1px solid var(--border);
  backdrop-filter: blur(12px);
  position: sticky; top: 0; z-index: 100;
}
.nav-brand { display: flex; align-items: center; gap: 12px; text-decoration: none; }
.nav-brand img { width: 38px; height: 38px; border-radius: 50%; object-fit: cover; }
.nav-brand span { font-family: var(--font-d); font-weight: 800; font-size: 17px; color: #fff; letter-spacing: -0.5px; }
.nav-links { display: flex; gap: 4px; }
.nav-links a {
  font-size: 13px; font-weight: 500; color: rgba(255,255,255,0.65);
  padding: 7px 12px; border-radius: var(--r-sm); transition: var(--t);
  position: relative;
}
.nav-links a:hover { color: #fff; background: rgba(255,255,255,0.06); }
.nav-links a.active { color: var(--nw-gold); font-weight: 700; }
.nav-links a.active::after {
  content: ''; position: absolute; bottom: 2px; left: 50%; transform: translateX(-50%);
  width: 16px; height: 2px; background: var(--nw-gold); border-radius: 1px;
}
.nav-cta { display: flex; gap: 8px; align-items: center; }

/* ── Member Layout ── */
.member-layout { display: flex; min-height: 100vh; }

.sidebar {
  width: var(--sidebar-w); background: rgba(16,8,42,0.98);
  border-right: 1px solid var(--border);
  display: flex; flex-direction: column;
  position: fixed; top: 0; bottom: 0; left: 0;
  z-index: 50; overflow-y: auto;
}
.sidebar-brand { display: flex; align-items: center; gap: 10px; padding: 20px 20px 16px; }
.sidebar-brand img { width: 32px; height: 32px; border-radius: 50%; object-fit: cover; }
.sidebar-brand span { font-family: var(--font-d); font-weight: 800; font-size: 14px; color: #fff; }
.sidebar-section-label {
  font-size: 10px; letter-spacing: 2px; text-transform: uppercase;
  color: var(--text-3); font-weight: 700; padding: 12px 20px 4px;
}
.sidebar-link {
  display: flex; align-items: center; gap: 10px;
  padding: 9px 20px; margin: 1px 8px;
  border-radius: var(--r-sm); cursor: pointer; transition: var(--t);
  border-left: 3px solid transparent; font-size: 13px; font-weight: 500;
  color: rgba(255,255,255,0.65); text-decoration: none;
}
.sidebar-link:hover { background: rgba(255,255,255,0.05); color: rgba(255,255,255,0.9); }
.sidebar-link.active {
  background: rgba(245,184,0,0.1); color: var(--nw-gold);
  border-left-color: var(--nw-gold); font-weight: 700;
}
.sidebar-link .icon { font-size: 15px; min-width: 20px; }
.sidebar-footer {
  margin-top: auto; padding: 16px 20px;
  border-top: 1px solid var(--border);
}
.sidebar-user { display: flex; align-items: center; gap: 10px; }
.sidebar-avatar {
  width: 32px; height: 32px; border-radius: 50%;
  background: linear-gradient(135deg, var(--nw-rich), var(--nw-mid));
  display: flex; align-items: center; justify-content: center;
  font-size: 13px; font-weight: 700; color: #fff; flex-shrink: 0;
}
.sidebar-user-name { font-size: 12px; color: #fff; font-weight: 600; }
.sidebar-user-role { font-size: 10px; color: var(--text-3); }

.member-main {
  margin-left: var(--sidebar-w); flex: 1;
  padding: 28px 32px; min-height: 100vh;
  background: var(--nw-void);
}
.member-header {
  display: flex; align-items: center; justify-content: space-between;
  margin-bottom: 28px;
}
.member-header h1 { font-family: var(--font-d); font-size: 26px; font-weight: 800; }
.member-header .subtitle { font-size: 13px; color: var(--text-3); margin-top: 2px; }

/* ── Stat card ── */
.stat-card {
  background: rgba(45,27,105,0.3); border: 1px solid var(--border);
  border-radius: var(--r-lg); padding: 18px;
}
.stat-card .stat-label { font-size: 11px; font-weight: 700; letter-spacing: 1.5px; text-transform: uppercase; }
.stat-card .stat-value { font-family: var(--font-d); font-size: 30px; font-weight: 800; letter-spacing: -1px; margin-top: 8px; }

/* ── Page hero ── */
.page-hero {
  padding: 80px 56px 60px;
  max-width: 1200px; margin: 0 auto;
}

/* ── Footer ── */
.site-footer {
  background: rgba(16,8,42,0.9); border-top: 1px solid var(--border);
  padding: 48px 56px 32px;
}
.footer-inner { max-width: 1200px; margin: 0 auto; }
.footer-grid { display: grid; grid-template-columns: 2fr 1fr 1fr 1fr; gap: 40px; margin-bottom: 40px; }
.footer-brand-desc { font-size: 14px; color: var(--text-3); line-height: 1.6; margin-top: 12px; }
.footer-col h4 { font-size: 12px; font-weight: 700; letter-spacing: 2px; text-transform: uppercase; color: var(--text-3); margin-bottom: 14px; }
.footer-col a { display: block; font-size: 14px; color: rgba(255,255,255,0.6); margin-bottom: 8px; transition: var(--t); }
.footer-col a:hover { color: var(--nw-gold); }
.footer-bottom { display: flex; justify-content: space-between; align-items: center; padding-top: 24px; border-top: 1px solid var(--border); font-size: 13px; color: var(--text-3); }

/* ── BG decorative orbs ── */
.bg-orb {
  position: absolute; border-radius: 50%; pointer-events: none;
  background: radial-gradient(circle, rgba(61,43,138,0.45) 0%, transparent 70%);
}

/* ── Glow pulse dot ── */
.pulse-dot {
  width: 8px; height: 8px; border-radius: 50%;
  background: var(--nw-gold);
  box-shadow: 0 0 0 0 rgba(245,184,0,0.4);
  animation: pulse 2s infinite;
}
@keyframes pulse {
  0%   { box-shadow: 0 0 0 0 rgba(245,184,0,0.4); }
  70%  { box-shadow: 0 0 0 8px rgba(245,184,0,0); }
  100% { box-shadow: 0 0 0 0 rgba(245,184,0,0); }
}

/* ── Scroll fade-in ── */
.fade-up { opacity: 0; transform: translateY(24px); transition: opacity 0.6s var(--t), transform 0.6s var(--t); }
.fade-up.visible { opacity: 1; transform: none; }

/* ── Responsive ── */
@media (max-width: 900px) {
  .section-inner { padding: 0 24px; }
  .main-nav { padding: 0 24px; }
  .nav-links { display: none; }
  .footer-grid { grid-template-columns: 1fr 1fr; }
  .page-hero { padding: 48px 24px 40px; }
}
