/* ================================================================
   AcademIQ — Main Stylesheet
   Dark academic: deep navy base, gold accents, Sora + Playfair
   ================================================================ */

@import url('https://fonts.googleapis.com/css2?family=Sora:wght@300;400;500;600;700&family=JetBrains+Mono:wght@400;500&family=Playfair+Display:ital,wght@0,700;1,500&display=swap');

/* ── Variables ───────────────────────────────────────────── */
:root {
  --bg-base:        #0a0d14;
  --bg-surface:     #0f1420;
  --bg-elevated:    #151b2d;
  --bg-card:        rgba(21, 27, 45, 0.9);

  --gold:           #c9a84c;
  --gold-light:     #e2c06a;
  --gold-dim:       rgba(201, 168, 76, 0.12);
  --gold-glow:      rgba(201, 168, 76, 0.35);

  --accent-blue:    #4a7eff;
  --accent-teal:    #00c2a8;
  --accent-purple:  #8b5cf6;
  --accent-rose:    #f43f5e;

  --text-primary:   #e8eaf2;
  --text-secondary: #8b92a8;
  --text-muted:     #545c72;
  --bg-base-solid:  #0a0d14;

  --border:         rgba(255, 255, 255, 0.07);
  --border-gold:    rgba(201, 168, 76, 0.3);

  --risk-low:       #10b981;
  --risk-medium:    #f59e0b;
  --risk-high:      #ef4444;
  --risk-critical:  #dc2626;

  --font-sans:  'Sora', system-ui, sans-serif;
  --font-mono:  'JetBrains Mono', monospace;
  --font-serif: 'Playfair Display', Georgia, serif;

  --radius-sm:   6px;
  --radius-md:   12px;
  --radius-lg:   18px;
  --radius-xl:   24px;
  --radius-full: 9999px;

  --shadow-gold: 0 0 28px rgba(201, 168, 76, 0.18);
  --transition:  200ms cubic-bezier(0.4, 0, 0.2, 1);
  --navbar-h:    64px;
  --content-max: 1200px;
}

/* ── Reset ───────────────────────────────────────────────── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { font-size: 16px; scroll-behavior: smooth; }
body {
  font-family: var(--font-sans);
  background: var(--bg-base);
  color: var(--text-primary);
  line-height: 1.6;
  min-height: 100vh;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
}
a { color: var(--gold); text-decoration: none; transition: color var(--transition); }
a:hover { color: var(--gold-light); }
img { max-width: 100%; display: block; }

/* ── Background Orbs ─────────────────────────────────────── */
.bg-orb {
  position: fixed; border-radius: 50%;
  filter: blur(100px); pointer-events: none; z-index: 0;
}
.bg-orb--1 {
  width: 600px; height: 600px;
  background: radial-gradient(circle, rgba(74,126,255,0.07) 0%, transparent 70%);
  top: -200px; right: -100px;
  animation: orb1 20s ease-in-out infinite;
}
.bg-orb--2 {
  width: 500px; height: 500px;
  background: radial-gradient(circle, rgba(201,168,76,0.06) 0%, transparent 70%);
  bottom: 100px; left: -150px;
  animation: orb2 25s ease-in-out infinite;
}
.bg-orb--3 {
  width: 400px; height: 400px;
  background: radial-gradient(circle, rgba(139,92,246,0.05) 0%, transparent 70%);
  top: 40%; left: 40%;
  animation: orb3 30s ease-in-out infinite;
}
@keyframes orb1 { 0%,100%{transform:translate(0,0)} 50%{transform:translate(-60px,80px)} }
@keyframes orb2 { 0%,100%{transform:translate(0,0)} 50%{transform:translate(80px,-40px)} }
@keyframes orb3 { 0%,100%{transform:translate(0,0) scale(1)} 50%{transform:translate(-40px,60px) scale(1.1)} }

/* ── Navbar ──────────────────────────────────────────────── */
.navbar {
  position: fixed; top: 0; left: 0; right: 0;
  height: var(--navbar-h); z-index: 100;
  background: rgba(10,13,20,0.88);
  -webkit-backdrop-filter: blur(16px);
  backdrop-filter: blur(16px);
  border-bottom: 1px solid var(--border);
}
.navbar__inner {
  max-width: var(--content-max); margin: 0 auto;
  height: 100%; padding: 0 1.5rem;
  display: flex; align-items: center; gap: 2rem;
}
.navbar__brand {
  display: flex; align-items: center; gap: 0.75rem;
  color: var(--text-primary); flex-shrink: 0;
}
.brand-icon { color: var(--gold); display: flex; }
.brand-name { font-size: 1.2rem; font-weight: 600; letter-spacing: -0.02em; }
.brand-name em { font-style: normal; color: var(--gold); }

.navbar__links { display: flex; align-items: center; gap: 0.25rem; flex: 1; }
.nav-link {
  padding: 0.4rem 0.875rem; border-radius: var(--radius-sm);
  font-size: 0.875rem; font-weight: 500; color: var(--text-secondary);
  transition: color var(--transition), background var(--transition);
  position: relative; display: flex; align-items: center; gap: 0.4rem;
}
.nav-link:hover { color: var(--text-primary); background: var(--border); }
.nav-link.active { color: var(--gold); background: var(--gold-dim); }
.nav-link.active::after {
  content: ''; position: absolute; bottom: -1px; left: 50%;
  transform: translateX(-50%); width: 24px; height: 2px;
  background: var(--gold); border-radius: 2px;
}
.nav-link--cta {
  background: var(--gold) !important; color: #0a0d14 !important; font-weight: 600;
}
.nav-link--cta:hover { background: var(--gold-light) !important; }
.nav-link--warn { color: var(--risk-high) !important; }
.nav-link--warn:hover { background: rgba(239,68,68,0.1); }

.badge {
  background: var(--accent-rose); color: #fff;
  font-size: 0.65rem; font-weight: 700;
  padding: 1px 5px; border-radius: var(--radius-full);
}

.navbar__user { display: flex; align-items: center; gap: 0.75rem; margin-left: auto; }
.user-avatar {
  width: 34px; height: 34px; border-radius: var(--radius-full);
  background: linear-gradient(135deg, var(--gold), var(--accent-blue));
  display: flex; align-items: center; justify-content: center;
  font-size: 0.8rem; font-weight: 700; color: #0a0d14; flex-shrink: 0;
}
.user-info { display: flex; flex-direction: column; line-height: 1.2; }
.user-name { font-size: 0.825rem; font-weight: 600; }
.user-role { font-size: 0.7rem; color: var(--text-muted); text-transform: uppercase; letter-spacing: 0.05em; }
.nav-logout {
  color: var(--text-muted); padding: 0.4rem; border-radius: var(--radius-sm);
  display: flex; transition: color var(--transition), background var(--transition);
}
.nav-logout:hover { color: var(--risk-high); background: rgba(244,63,94,0.1); }

/* ── Main Content ────────────────────────────────────────── */
.main-content {
  position: relative; z-index: 1;
  margin-top: var(--navbar-h);
  min-height: calc(100vh - var(--navbar-h));
  padding: 2rem 1.5rem;
  max-width: var(--content-max);
  margin-left: auto; margin-right: auto;
}

/* ── Page Header ─────────────────────────────────────────── */
.page-header {
  margin-bottom: 2rem; padding-bottom: 1.5rem;
  border-bottom: 1px solid var(--border);
  display: flex; align-items: flex-end;
  justify-content: space-between; gap: 1rem;
}
.page-title {
  font-family: var(--font-serif);
  font-size: 2rem; font-weight: 700;
  letter-spacing: -0.02em; line-height: 1.2;
}
.page-subtitle { font-size: 0.9rem; color: var(--text-secondary); margin-top: 0.4rem; }

/* ── Stat Grid ───────────────────────────────────────────── */
.stat-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 1rem; margin-bottom: 2rem;
}
.stat-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 1.25rem 1.5rem;
  display: flex; flex-direction: column; gap: 0.5rem;
  position: relative; overflow: hidden;
  transition: border-color var(--transition), transform var(--transition);
  -webkit-backdrop-filter: blur(8px);
  backdrop-filter: blur(8px);
}
.stat-card:hover { border-color: var(--border-gold); transform: translateY(-2px); }
.stat-card::before {
  content: ''; position: absolute; top: 0; left: 0; right: 0; height: 2px;
  background: linear-gradient(90deg, var(--gold), var(--accent-blue));
  opacity: 0; transition: opacity var(--transition);
}
.stat-card:hover::before { opacity: 1; }
.stat-card__label {
  font-size: 0.68rem; font-weight: 600;
  text-transform: uppercase; letter-spacing: 0.12em; color: var(--text-muted);
}
.stat-card__value {
  font-family: var(--font-mono); font-size: 1.9rem;
  font-weight: 600; line-height: 1; color: var(--text-primary);
}
.stat-card__sub { font-size: 0.78rem; color: var(--text-secondary); }
.stat-card__icon {
  position: absolute; bottom: 1rem; right: 1rem;
  font-size: 1.8rem; opacity: 0.1;
}

/* ── Cards ───────────────────────────────────────────────── */
.card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 1.5rem;
  -webkit-backdrop-filter: blur(8px);
  backdrop-filter: blur(8px);
  transition: border-color var(--transition), box-shadow var(--transition);
}
.card:hover { border-color: var(--border-gold); }
.card--glow { box-shadow: var(--shadow-gold); border-color: var(--border-gold); }
.card__header {
  display: flex; align-items: center; justify-content: space-between;
  margin-bottom: 1.25rem; padding-bottom: 1rem;
  border-bottom: 1px solid var(--border);
}
.card__title {
  font-size: 0.72rem; font-weight: 600;
  text-transform: uppercase; letter-spacing: 0.1em; color: var(--text-muted);
}

/* ── Dashboard layout ────────────────────────────────────── */
.dashboard-grid {
  display: grid; grid-template-columns: 1fr 360px; gap: 1.5rem;
}
@media (max-width: 1024px) { .dashboard-grid { grid-template-columns: 1fr; } }
.dashboard-main, .dashboard-side { display: flex; flex-direction: column; gap: 1.5rem; }

/* ── Tables ──────────────────────────────────────────────── */
.table-wrap {
  border: 1px solid var(--border); border-radius: var(--radius-lg);
  overflow: hidden; background: var(--bg-card);
}
table { width: 100%; border-collapse: collapse; }
thead { background: rgba(255,255,255,0.03); border-bottom: 1px solid var(--border); }
thead th {
  padding: 0.75rem 1.25rem; text-align: left;
  font-size: 0.68rem; font-weight: 600;
  text-transform: uppercase; letter-spacing: 0.1em; color: var(--text-muted);
}
tbody tr { border-bottom: 1px solid var(--border); transition: background var(--transition); }
tbody tr:last-child { border-bottom: none; }
tbody tr:hover { background: rgba(255,255,255,0.025); }
tbody td { padding: 1rem 1.25rem; font-size: 0.875rem; color: var(--text-secondary); vertical-align: middle; }
.td-main { color: var(--text-primary); font-weight: 500; }
.td-mono { font-family: var(--font-mono); font-size: 0.8rem; }

/* ── Buttons ─────────────────────────────────────────────── */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 0.5rem;
  padding: 0.625rem 1.25rem; border-radius: var(--radius-md);
  font-family: var(--font-sans); font-size: 0.875rem; font-weight: 600;
  cursor: pointer; border: none;
  transition: all var(--transition); text-decoration: none; white-space: nowrap;
}
.btn:disabled { opacity: 0.5; cursor: not-allowed; }
.btn--primary { background: var(--gold); color: #0a0d14; }
.btn--primary:hover:not(:disabled) {
  background: var(--gold-light); box-shadow: 0 4px 16px var(--gold-glow);
  transform: translateY(-1px); color: #0a0d14;
}
.btn--secondary { background: transparent; color: var(--text-secondary); border: 1px solid var(--border); }
.btn--secondary:hover:not(:disabled) { border-color: var(--gold); color: var(--gold); background: var(--gold-dim); }
.btn--danger { background: transparent; color: var(--risk-high); border: 1px solid rgba(239,68,68,0.3); }
.btn--danger:hover { background: rgba(239,68,68,0.1); color: var(--risk-high); }
.btn--sm { padding: 0.4rem 0.875rem; font-size: 0.78rem; }
.btn--lg { padding: 0.875rem 2rem; font-size: 1rem; }
.w-full { width: 100%; }

/* ── Risk Badges ─────────────────────────────────────────── */
.risk-badge {
  display: inline-flex; align-items: center; gap: 0.4rem;
  padding: 3px 9px; border-radius: var(--radius-full);
  font-size: 0.68rem; font-weight: 700;
  text-transform: uppercase; letter-spacing: 0.08em;
}
.risk-badge::before { content: ''; width: 5px; height: 5px; border-radius: 50%; background: currentColor; }
.risk-badge--low      { background: rgba(16,185,129,0.15); color: var(--risk-low); }
.risk-badge--medium   { background: rgba(245,158,11,0.15);  color: var(--risk-medium); }
.risk-badge--high     { background: rgba(239,68,68,0.15);   color: var(--risk-high); }
.risk-badge--critical { background: rgba(220,38,38,0.2);    color: var(--risk-critical); animation: cpulse 2s ease-in-out infinite; }
@keyframes cpulse { 0%,100%{box-shadow:none} 50%{box-shadow:0 0 12px rgba(220,38,38,0.4)} }

/* ── Tags ────────────────────────────────────────────────── */
.tag {
  display: inline-block; padding: 2px 8px; border-radius: var(--radius-full);
  font-size: 0.7rem; font-weight: 600;
  background: var(--bg-elevated); color: var(--text-secondary); border: 1px solid var(--border);
}
.tag--gold { background: var(--gold-dim); color: var(--gold); border-color: var(--border-gold); }

/* ── Flash Messages ──────────────────────────────────────── */
.flash-container {
  position: fixed; top: calc(var(--navbar-h) + 1rem); right: 1.5rem;
  z-index: 200; display: flex; flex-direction: column; gap: 0.5rem; max-width: 400px;
}
.flash {
  display: flex; align-items: center; gap: 0.75rem;
  padding: 0.75rem 1rem; border-radius: var(--radius-md); border: 1px solid;
  font-size: 0.875rem; font-weight: 500;
  animation: flash-in 0.3s cubic-bezier(0.34,1.56,0.64,1);
  -webkit-backdrop-filter: blur(12px);
  backdrop-filter: blur(12px);
}
@keyframes flash-in { from{transform:translateX(40px);opacity:0} to{transform:translateX(0);opacity:1} }
.flash--success { background: rgba(16,185,129,0.15); border-color: rgba(16,185,129,0.4); color: #10b981; }
.flash--error   { background: rgba(239,68,68,0.15);  border-color: rgba(239,68,68,0.4);  color: #ef4444; }
.flash--warning { background: rgba(245,158,11,0.15); border-color: rgba(245,158,11,0.4); color: #f59e0b; }
.flash__icon { font-size: 1rem; flex-shrink: 0; }
.flash__msg { flex: 1; }
.flash__close { background: none; border: none; cursor: pointer; color: inherit; opacity: 0.6; font-size: 0.85rem; }
.flash__close:hover { opacity: 1; }

/* ── Forms ───────────────────────────────────────────────── */
.form-group { margin-bottom: 1.125rem; }
.form-label {
  display: block; font-size: 0.72rem; font-weight: 600;
  text-transform: uppercase; letter-spacing: 0.08em;
  color: var(--text-muted); margin-bottom: 0.5rem;
}
.form-input, .form-control, .form-select, .form-textarea {
  display: block; width: 100%;
  background: rgba(15,20,32,0.8);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  padding: 0.75rem 1rem;
  color: var(--text-primary);
  font-family: var(--font-sans); font-size: 0.95rem;
  outline: none; box-sizing: border-box;
  transition: border-color var(--transition), box-shadow var(--transition);
}
.form-input:focus, .form-control:focus, .form-select:focus, .form-textarea:focus {
  border-color: var(--gold); box-shadow: 0 0 0 3px var(--gold-dim);
}
.form-input::placeholder, .form-control::placeholder, .form-textarea::placeholder { color: var(--text-muted); }
.form-textarea { resize: vertical; min-height: 120px; }
.form-hint { font-size: 0.75rem; color: var(--text-muted); margin-top: 0.4rem; }
.form-error { font-size: 0.75rem; color: var(--risk-high); margin-top: 0.4rem; }

/* ── Upload Zone ─────────────────────────────────────────── */
.upload-zone {
  border: 2px dashed var(--border); border-radius: var(--radius-xl);
  padding: 3.5rem 2rem; text-align: center; cursor: pointer;
  transition: border-color var(--transition), background var(--transition);
  position: relative;
}
.upload-zone:hover, .upload-zone.drag-over { border-color: var(--gold); background: var(--gold-dim); }
.upload-zone input[type=file] { position: absolute; inset: 0; opacity: 0; cursor: pointer; width: 100%; height: 100%; }
.upload-zone__icon { font-size: 2.75rem; margin-bottom: 1rem; opacity: 0.45; }
.upload-zone__title { font-family: var(--font-serif); font-size: 1.2rem; color: var(--text-primary); margin-bottom: 0.35rem; }
.upload-zone__sub { font-size: 0.825rem; color: var(--text-muted); }
.progress-wrap { background: var(--border); border-radius: var(--radius-full); height: 6px; overflow: hidden; margin-top: 1rem; }
.progress-bar { height: 100%; background: linear-gradient(90deg, var(--gold), var(--accent-blue)); border-radius: var(--radius-full); width: 0%; transition: width 0.3s ease; }

/* ── Feature Bars ────────────────────────────────────────── */
.feature-bars { display: flex; flex-direction: column; gap: 0.75rem; }
.feature-bar-item { display: flex; flex-direction: column; gap: 0.2rem; }
.feature-bar-label { display: flex; justify-content: space-between; font-size: 0.75rem; color: var(--text-secondary); }
.feature-bar-label span:last-child { font-family: var(--font-mono); color: var(--text-primary); }
.feature-bar-track { height: 6px; background: var(--border); border-radius: var(--radius-full); overflow: hidden; }
.feature-bar-fill {
  height: 100%;
  background: linear-gradient(90deg, var(--accent-blue), var(--gold));
  border-radius: var(--radius-full);
  transition: width 1s cubic-bezier(0.4,0,0.2,1) 0.3s;
}

/* ── Trust Breakdown ─────────────────────────────────────── */
.trust-breakdown { display: flex; flex-direction: column; gap: 1rem; }
.trust-component { display: flex; align-items: center; gap: 1rem; }
.trust-component__label { width: 130px; font-size: 0.75rem; color: var(--text-secondary); flex-shrink: 0; }
.trust-component__bar { flex: 1; height: 7px; background: var(--border); border-radius: var(--radius-full); overflow: hidden; }
.trust-component__fill { height: 100%; border-radius: var(--radius-full); transition: width 1s cubic-bezier(0.4,0,0.2,1) 0.4s; }
.trust-component__fill--style  { background: linear-gradient(90deg, var(--accent-blue), #7dd3fc); }
.trust-component__fill--sim    { background: linear-gradient(90deg, var(--gold), var(--gold-light)); }
.trust-component__fill--beh    { background: linear-gradient(90deg, var(--accent-teal), #67e8f9); }
.trust-component__fill--time   { background: linear-gradient(90deg, var(--accent-purple), #c4b5fd); }
.trust-component__val { width: 44px; text-align: right; font-family: var(--font-mono); font-size: 0.75rem; color: var(--text-primary); }

/* ── Similarity Meter ────────────────────────────────────── */
.sim-meter { height: 9px; background: var(--border); border-radius: var(--radius-full); overflow: hidden; }
.sim-meter__fill { height: 100%; border-radius: var(--radius-full); transition: width 1s cubic-bezier(0.4,0,0.2,1); }
.sim-meter__fill--low      { background: var(--risk-low); }
.sim-meter__fill--medium   { background: var(--risk-medium); }
.sim-meter__fill--high     { background: var(--risk-high); }
.sim-meter__fill--critical { background: var(--risk-critical); }

/* ── Recommendation Cards ────────────────────────────────── */
.rec-list { display: flex; flex-direction: column; gap: 1rem; }
.rec-card {
  background: var(--bg-card); border: 1px solid var(--border);
  border-radius: var(--radius-lg); padding: 1.125rem;
  display: flex; gap: 1rem;
  transition: border-color var(--transition), transform var(--transition); cursor: pointer;
}
.rec-card:hover { border-color: var(--border-gold); transform: translateX(3px); }
.rec-card.unread { border-left: 3px solid var(--gold); }
.rec-card__icon {
  width: 42px; height: 42px; border-radius: var(--radius-md);
  display: flex; align-items: center; justify-content: center;
  font-size: 1.2rem; flex-shrink: 0;
}
.rec-card__icon--writing  { background: rgba(74,126,255,0.15); }
.rec-card__icon--resource { background: rgba(0,194,168,0.15); }
.rec-card__icon--revision { background: rgba(245,158,11,0.15); }
.rec-card__icon--warning  { background: rgba(239,68,68,0.15); }
.rec-card__content { flex: 1; }
.rec-card__type { font-size: 0.65rem; font-weight: 700; text-transform: uppercase; letter-spacing: 0.1em; margin-bottom: 0.25rem; }
.rec-card__type--writing  { color: var(--accent-blue); }
.rec-card__type--resource { color: var(--accent-teal); }
.rec-card__type--revision { color: var(--risk-medium); }
.rec-card__type--warning  { color: var(--risk-high); }
.rec-card__msg { font-size: 0.875rem; color: var(--text-secondary); line-height: 1.6; }
.rec-card__meta { font-size: 0.72rem; color: var(--text-muted); margin-top: 0.4rem; }

/* ── Analysis Grid ───────────────────────────────────────── */
.analysis-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 1.5rem; }
@media (max-width: 768px) { .analysis-grid { grid-template-columns: 1fr; } }

/* ── Trust Gauge ─────────────────────────────────────────── */
.trust-gauge { position: relative; overflow: visible; }
.gauge-center-text { position: absolute; bottom: 0; left: 50%; transform: translateX(-50%); text-align: center; white-space: nowrap; }
.gauge-score { font-family: var(--font-mono); font-size: 1.5rem; font-weight: 700; line-height: 1; }
.gauge-label { font-size: 0.62rem; font-weight: 600; text-transform: uppercase; letter-spacing: 0.1em; color: var(--text-muted); margin-top: 0.1rem; }

/* ── Word Frequency ──────────────────────────────────────── */
.word-freq-list { display: flex; flex-wrap: wrap; gap: 0.4rem; padding: 0.75rem 0; }
.word-freq-item {
  background: var(--bg-elevated); border: 1px solid var(--border);
  border-radius: var(--radius-sm); padding: 2px 8px;
  font-family: var(--font-mono); font-size: 0.72rem; color: var(--text-secondary);
  cursor: default; transition: all var(--transition);
}
.word-freq-item:hover { border-color: var(--gold); color: var(--gold); }

/* ── Chart Container ─────────────────────────────────────── */
.chart-container { position: relative; height: 260px; }

/* ── Empty State ─────────────────────────────────────────── */
.empty-state { text-align: center; padding: 4rem 2rem; color: var(--text-muted); }
.empty-state__icon { font-size: 2.75rem; margin-bottom: 1rem; opacity: 0.4; }
.empty-state__title { font-family: var(--font-serif); font-size: 1.2rem; color: var(--text-secondary); margin-bottom: 0.625rem; }
.empty-state__msg { font-size: 0.875rem; margin-bottom: 1.5rem; }

/* ── Pagination ──────────────────────────────────────────── */
.pagination { display: flex; align-items: center; justify-content: center; gap: 0.5rem; margin-top: 1.5rem; }
.page-btn {
  padding: 0.4rem 0.75rem; border-radius: var(--radius-sm);
  font-size: 0.8rem; font-weight: 500; color: var(--text-secondary);
  border: 1px solid var(--border); background: transparent; cursor: pointer;
  transition: all var(--transition); text-decoration: none;
}
.page-btn:hover, .page-btn.active { background: var(--gold-dim); border-color: var(--gold); color: var(--gold); }

/* ── Animations ──────────────────────────────────────────── */
@keyframes fade-up { from{opacity:0;transform:translateY(14px)} to{opacity:1;transform:translateY(0)} }
.animate-fade-up  { animation: fade-up 0.5s cubic-bezier(0.4,0,0.2,1) both; }
.delay-1 { animation-delay: 0.05s; }
.delay-2 { animation-delay: 0.10s; }
.delay-3 { animation-delay: 0.15s; }
.delay-4 { animation-delay: 0.20s; }
.delay-5 { animation-delay: 0.25s; }

/* ── Scrollbar ───────────────────────────────────────────── */
::-webkit-scrollbar { width: 6px; height: 6px; }
::-webkit-scrollbar-track { background: var(--bg-base); }
::-webkit-scrollbar-thumb { background: var(--border); border-radius: 3px; }
::-webkit-scrollbar-thumb:hover { background: var(--text-muted); }

/* ── Utilities ───────────────────────────────────────────── */
.text-sm       { font-size: 0.875rem; }
.text-xs       { font-size: 0.75rem; }
.text-muted    { color: var(--text-muted); }
.text-secondary{ color: var(--text-secondary); }
.font-mono     { font-family: var(--font-mono); }
.font-serif    { font-family: var(--font-serif); }

@media (max-width: 768px) {
  .main-content { padding: 1rem; }
  .navbar__inner { padding: 0 1rem; }
  .navbar__links { display: none; }
  .page-title { font-size: 1.5rem; }
  .stat-grid { grid-template-columns: 1fr 1fr; }
  .dashboard-grid { grid-template-columns: 1fr; }
  .analysis-grid { grid-template-columns: 1fr; }
}