/* ============================================================
   QST Training Portal — visual system v2 "Northern Lights"
   Brand: royal blue #0f62e2 · dark industrial · cinematic
   (class contracts preserved from v1 — purely visual upgrade)
   ============================================================ */

@font-face {
  font-family: 'Inter';
  font-style: normal;
  font-weight: 100 900;
  font-display: swap;
  src: url('/fonts/Inter-var.woff2') format('woff2');
}
@font-face {
  font-family: 'Space Grotesk';
  font-style: normal;
  font-weight: 300 700;
  font-display: swap;
  src: url('/fonts/SpaceGrotesk-var.woff2') format('woff2');
}

:root {
  --bg-0: #030509;
  --bg-1: #060a12;
  --bg-2: #0a101c;
  --bg-3: #0f1726;
  --panel: rgba(148, 178, 255, .025);
  --panel-strong: rgba(148, 178, 255, .05);
  --line: rgba(148, 178, 255, .09);
  --line-strong: rgba(148, 178, 255, .18);
  --blue: #0f62e2;
  --blue-bright: #3b82f6;
  --blue-light: #4d8dff;
  --blue-sky: #7cb5ff;
  --cyan: #67e8f9;
  --green: #22c55e;
  --amber: #f59e0b;
  --red: #ef4444;
  --ink: #eef3fb;
  --muted: #9fadc4;
  --muted-2: #66748d;
  --grad: linear-gradient(135deg, #0f62e2 0%, #3b82f6 45%, #4d8dff 100%);
  --grad-text: linear-gradient(100deg, #5e9bff 0%, #9cc8ff 45%, #67b4ff 80%, #4d8dff 100%);
  --fd: 'Space Grotesk', 'Inter', system-ui, sans-serif;
  --fb: 'Inter', system-ui, sans-serif;
  --radius: 16px;
  --radius-lg: 22px;
  --glow: 0 0 34px rgba(15, 98, 226, .38);
  --ease: cubic-bezier(.16, 1, .3, 1);
  --spring: cubic-bezier(.34, 1.56, .64, 1);
}

@property --ga {
  syntax: '<angle>';
  initial-value: 0deg;
  inherits: false;
}

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

body {
  font-family: var(--fb);
  font-size: 15.5px;
  line-height: 1.65;
  color: var(--ink);
  background: var(--bg-0);
  min-height: 100vh;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

/* film grain over everything */
body::after {
  content: ''; position: fixed; inset: 0; z-index: 2000; pointer-events: none;
  opacity: .05; mix-blend-mode: overlay;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='140' height='140'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.85' numOctaves='2'/%3E%3C/filter%3E%3Crect width='140' height='140' filter='url(%23n)' opacity='.6'/%3E%3C/svg%3E");
}

img { max-width: 100%; display: block; }
a { color: var(--blue-sky); text-decoration: none; transition: color .25s; }
a:hover { color: #fff; }
button { font: inherit; color: inherit; background: none; border: 0; cursor: pointer; }
ul { list-style: none; }
::selection { background: rgba(15, 98, 226, .5); color: #fff; }
h1, h2, h3, h4 { font-family: var(--fd); font-weight: 700; letter-spacing: -.015em; line-height: 1.12; text-wrap: balance; }

/* scrollbar */
* { scrollbar-width: thin; scrollbar-color: rgba(77, 141, 255, .35) transparent; }
::-webkit-scrollbar { width: 11px; height: 11px; }
::-webkit-scrollbar-track { background: var(--bg-0); }
::-webkit-scrollbar-thumb {
  background: linear-gradient(180deg, rgba(59, 130, 246, .5), rgba(15, 98, 226, .35));
  border-radius: 99px; border: 3px solid var(--bg-0);
}
::-webkit-scrollbar-thumb:hover { background: rgba(77, 141, 255, .7); }

/* ---------- Atmosphere layers (fixed, behind everything) ---------- */
.fx-aurora {
  position: fixed; inset: -20%; z-index: -3; pointer-events: none;
  background:
    radial-gradient(42% 38% at 78% 8%, rgba(15, 98, 226, .20), transparent 65%),
    radial-gradient(36% 34% at 12% 28%, rgba(37, 99, 235, .13), transparent 65%),
    radial-gradient(30% 34% at 60% 88%, rgba(103, 232, 249, .05), transparent 60%),
    radial-gradient(45% 40% at 30% 105%, rgba(15, 98, 226, .10), transparent 65%);
  animation: auroraDrift 26s ease-in-out infinite alternate;
}
@keyframes auroraDrift {
  from { transform: translate(0, 0) scale(1); }
  to   { transform: translate(2.5%, 3%) scale(1.07); }
}
.fx-grid {
  position: fixed; inset: 0; z-index: -2; pointer-events: none; opacity: .55;
  background-image:
    linear-gradient(rgba(124, 181, 255, .04) 1px, transparent 1px),
    linear-gradient(90deg, rgba(124, 181, 255, .04) 1px, transparent 1px);
  background-size: 58px 58px;
  mask-image: radial-gradient(75% 60% at 50% 32%, #000 20%, transparent 100%);
  -webkit-mask-image: radial-gradient(75% 60% at 50% 32%, #000 20%, transparent 100%);
}
.fx-particles { position: fixed; inset: 0; z-index: -1; pointer-events: none; }
.fx-particles canvas { width: 100%; height: 100%; }

/* ---------- Boot / preloader ---------- */
.preboot {
  position: fixed; inset: 0; z-index: 3000;
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 26px;
  background: var(--bg-0);
  transition: opacity .55s ease, visibility .55s;
}
.preboot.is-done { opacity: 0; visibility: hidden; }
.preboot img { width: min(250px, 55vw); opacity: 0; animation: bootLogo .9s var(--ease) .05s forwards; }
@keyframes bootLogo {
  from { opacity: 0; transform: translateY(16px) scale(.96); filter: blur(6px); }
  to   { opacity: 1; transform: none; filter: blur(0); }
}
.preboot .bar {
  width: min(250px, 55vw); height: 2px; border-radius: 2px;
  background: rgba(255, 255, 255, .08); overflow: hidden; position: relative;
}
.preboot .bar i {
  position: absolute; inset: 0; transform: scaleX(0); transform-origin: left;
  background: var(--grad); border-radius: 2px;
  box-shadow: 0 0 16px rgba(59, 130, 246, .9);
  animation: bootBar 1s var(--ease) .2s forwards;
}
@keyframes bootBar { to { transform: scaleX(1); } }
.preboot small {
  font-family: var(--fd); font-size: 11px; font-weight: 500;
  letter-spacing: .34em; text-transform: uppercase; color: var(--muted-2);
  opacity: 0; animation: fadeIn .7s ease .45s forwards;
}

@keyframes rise { from { opacity: 0; transform: translateY(18px); } to { opacity: 1; transform: none; } }
@keyframes fadeIn { from { opacity: 0; } to { opacity: 1; } }
@keyframes popIn { from { opacity: 0; transform: scale(.6); } to { opacity: 1; transform: scale(1); } }
.anim { animation: rise .6s var(--ease) both; }
.anim-d1 { animation-delay: .08s; } .anim-d2 { animation-delay: .16s; } .anim-d3 { animation-delay: .24s; }

/* ---------- App shell ---------- */
.shell { min-height: 100vh; display: flex; flex-direction: column; }

.topbar {
  position: sticky; top: 0; z-index: 100;
  display: flex; align-items: center; gap: 18px;
  padding: 0 clamp(16px, 3vw, 34px); height: 70px;
  background: rgba(4, 7, 13, .72);
  backdrop-filter: blur(20px) saturate(1.4); -webkit-backdrop-filter: blur(20px) saturate(1.4);
  border-bottom: 1px solid var(--line);
}
.topbar::after {  /* hairline glow along the bottom edge */
  content: ''; position: absolute; left: 0; right: 0; bottom: -1px; height: 1px;
  background: linear-gradient(90deg, transparent, rgba(77, 141, 255, .45) 30%, rgba(77, 141, 255, .45) 70%, transparent);
  opacity: .6; pointer-events: none;
}
.topbar__logo { position: relative; overflow: hidden; border-radius: 8px; }
.topbar__logo img { height: 38px; width: auto; }
.topbar__logo::after {
  content: ''; position: absolute; inset: 0;
  background: linear-gradient(105deg, transparent 40%, rgba(255, 255, 255, .18) 50%, transparent 60%);
  transform: translateX(-130%);
  transition: transform .7s var(--ease);
}
.topbar__logo:hover::after { transform: translateX(130%); }

.topbar__nav { display: flex; gap: 2px; margin-left: 8px; }
.topbar__nav a {
  position: relative; padding: 9px 15px; border-radius: 10px; color: var(--muted);
  font-family: var(--fd); font-weight: 500; font-size: 14.5px;
  transition: color .25s, background-color .25s;
}
.topbar__nav a::after {
  content: ''; position: absolute; left: 15px; right: 15px; bottom: 3px; height: 2px;
  border-radius: 2px; background: var(--grad);
  transform: scaleX(0); transform-origin: left;
  transition: transform .35s var(--ease);
  box-shadow: 0 0 8px rgba(59, 130, 246, .8);
}
.topbar__nav a:hover { color: #fff; }
.topbar__nav a:hover::after, .topbar__nav a.on::after { transform: scaleX(1); }
.topbar__nav a.on { color: #fff; background: rgba(15, 98, 226, .12); }

.topbar__spacer { flex: 1; }
.topbar__user { display: flex; align-items: center; gap: 12px; }
.avatar {
  position: relative; width: 38px; height: 38px; border-radius: 50%; flex: none;
  display: grid; place-items: center;
  background: var(--grad); color: #fff;
  font-family: var(--fd); font-weight: 700; font-size: 15px;
  box-shadow: var(--glow), inset 0 1px 0 rgba(255, 255, 255, .3);
}
.topbar__user .avatar::after {
  content: ''; position: absolute; inset: -4px; border-radius: 50%;
  border: 1.5px solid rgba(77, 141, 255, .5);
  animation: avatarPulse 2.6s var(--ease) infinite;
}
@keyframes avatarPulse {
  0% { transform: scale(.82); opacity: 1; }
  70%, 100% { transform: scale(1.22); opacity: 0; }
}
.topbar__name { font-family: var(--fd); font-weight: 600; font-size: 14px; line-height: 1.25; }
.topbar__name small { display: block; color: var(--muted-2); font-family: var(--fb); font-weight: 400; font-size: 11.5px; }

.burger {
  display: none; width: 42px; height: 42px; border-radius: 10px;
  border: 1px solid var(--line-strong); background: rgba(255, 255, 255, .03);
  flex-direction: column; align-items: center; justify-content: center; gap: 4px;
}
.burger span { width: 17px; height: 2px; background: #fff; border-radius: 2px; transition: transform .3s var(--spring); }

.main {
  flex: 1; width: min(1180px, 100%); margin-inline: auto;
  padding: clamp(22px, 3.5vw, 42px) clamp(14px, 3vw, 30px) 80px;
  animation: viewIn .55s var(--ease) both;
}
@keyframes viewIn {
  from { opacity: 0; transform: translateY(14px); filter: blur(3px); }
  to   { opacity: 1; transform: none; filter: blur(0); }
}

@media (max-width: 860px) {
  .topbar__nav {
    display: none; position: fixed; top: 70px; left: 0; right: 0;
    flex-direction: column; padding: 12px;
    background: rgba(4, 7, 13, .97); backdrop-filter: blur(20px);
    border-bottom: 1px solid var(--line-strong);
  }
  .topbar__nav.open { display: flex; animation: fadeIn .25s ease; }
  .topbar__nav a { padding: 14px 16px; font-size: 16px; }
  .topbar__nav a::after { display: none; }
  .burger { display: flex; }
  .topbar__name small { display: none; }
}

/* ---------- Buttons ---------- */
.btn {
  position: relative; display: inline-flex; align-items: center; justify-content: center; gap: 9px;
  font-family: var(--fd); font-weight: 600; font-size: 14.5px;
  padding: 12px 22px; border-radius: 12px; white-space: nowrap;
  transition: transform .35s var(--spring), box-shadow .35s, background-color .35s, border-color .35s, opacity .3s, color .3s;
  overflow: hidden; isolation: isolate;
}
.btn:disabled { opacity: .45; cursor: not-allowed; }
.btn-p { background: var(--grad); color: #fff; box-shadow: 0 8px 26px rgba(15, 98, 226, .38), inset 0 1px 0 rgba(255, 255, 255, .25); }
.btn-p::before {
  content: ''; position: absolute; inset: 0; z-index: -1;
  background: linear-gradient(110deg, transparent 30%, rgba(255, 255, 255, .35) 50%, transparent 70%);
  transform: translateX(-130%);
  transition: transform .75s var(--ease);
}
.btn-p:hover:not(:disabled) { transform: translateY(-2px); box-shadow: 0 14px 38px rgba(15, 98, 226, .55), inset 0 1px 0 rgba(255, 255, 255, .25); }
.btn-p:hover:not(:disabled)::before { transform: translateX(130%); }
.btn-g {
  color: var(--ink); border: 1px solid var(--line-strong);
  background: rgba(148, 178, 255, .04);
  backdrop-filter: blur(8px);
}
.btn-g:hover:not(:disabled) { transform: translateY(-2px); border-color: rgba(124, 181, 255, .55); background: rgba(77, 141, 255, .1); color: #fff; box-shadow: 0 10px 28px rgba(3, 7, 15, .5); }
.btn-danger { color: #ffb4b4; border: 1px solid rgba(239, 68, 68, .4); background: rgba(239, 68, 68, .08); }
.btn-danger:hover:not(:disabled) { background: rgba(239, 68, 68, .18); color: #fff; transform: translateY(-2px); }
.btn-sm { padding: 8px 14px; font-size: 13px; border-radius: 9px; }
.btn-lg { padding: 15px 30px; font-size: 16px; border-radius: 14px; }
.btn-block { width: 100%; }

/* ---------- Badges ---------- */
.badge {
  display: inline-flex; align-items: center; gap: 6px;
  font-family: var(--fd); font-size: 11.5px; font-weight: 600;
  letter-spacing: .07em; text-transform: uppercase;
  padding: 4px 11px; border-radius: 999px;
  color: var(--blue-sky); border: 1px solid rgba(77, 141, 255, .38);
  background: linear-gradient(160deg, rgba(15, 98, 226, .16), rgba(15, 98, 226, .06));
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, .06);
}
.badge.green { color: #86efac; border-color: rgba(34, 197, 94, .45); background: linear-gradient(160deg, rgba(34, 197, 94, .16), rgba(34, 197, 94, .05)); }
.badge.amber { color: #fcd34d; border-color: rgba(245, 158, 11, .45); background: linear-gradient(160deg, rgba(245, 158, 11, .16), rgba(245, 158, 11, .05)); }
.badge.red { color: #fca5a5; border-color: rgba(239, 68, 68, .45); background: linear-gradient(160deg, rgba(239, 68, 68, .16), rgba(239, 68, 68, .05)); }
.badge.grey { color: var(--muted); border-color: var(--line-strong); background: rgba(255, 255, 255, .04); }

/* ---------- Fields ---------- */
.field { margin-bottom: 16px; }
.field label {
  display: block; font-family: var(--fd); font-size: 11.5px; font-weight: 600;
  letter-spacing: .12em; text-transform: uppercase; color: var(--muted); margin-bottom: 7px;
}
.field input, .field select, .field textarea {
  width: 100%; padding: 13px 15px; border-radius: 11px;
  border: 1px solid var(--line-strong);
  background: rgba(3, 5, 10, .6); color: var(--ink);
  font: inherit; font-size: 15px;
  transition: border-color .3s, box-shadow .3s, background-color .3s;
  appearance: none;
}
.field select {
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8'%3E%3Cpath d='M1 1l5 5 5-5' stroke='%239fadc4' stroke-width='1.8' fill='none' stroke-linecap='round'/%3E%3C/svg%3E");
  background-repeat: no-repeat; background-position: right 15px center;
}
.field textarea { min-height: 110px; resize: vertical; }
.field input:focus, .field select:focus, .field textarea:focus {
  outline: none; border-color: var(--blue-bright);
  box-shadow: 0 0 0 4px rgba(15, 98, 226, .18), 0 0 24px rgba(15, 98, 226, .12);
  background: rgba(3, 5, 10, .85);
}
.field .hint { font-size: 12.5px; color: var(--muted-2); margin-top: 5px; }

/* ---------- Panels ---------- */
.panel {
  position: relative;
  border-radius: var(--radius-lg); border: 1px solid var(--line);
  background: linear-gradient(160deg, var(--panel-strong), var(--panel));
  backdrop-filter: blur(6px);
  padding: clamp(20px, 3vw, 30px);
  transition: border-color .4s, box-shadow .4s;
  overflow: hidden;
}
.panel::before {  /* mouse-follow sheen */
  content: ''; position: absolute; inset: 0; z-index: 0; opacity: 0; pointer-events: none;
  background: radial-gradient(560px circle at var(--mx, 50%) var(--my, 50%), rgba(59, 130, 246, .08), transparent 65%);
  transition: opacity .5s;
}
.panel:hover::before { opacity: 1; }
.panel > * { position: relative; z-index: 1; }
.panel + .panel { margin-top: 18px; }
.panel h2 { font-size: 21px; margin-bottom: 6px; }
.panel > p.sub { color: var(--muted); font-size: 14.5px; margin-bottom: 20px; }

.grid { display: grid; gap: 18px; }
.grid-2 { grid-template-columns: repeat(2, 1fr); }
.grid-3 { grid-template-columns: repeat(3, 1fr); }
.grid-4 { grid-template-columns: repeat(4, 1fr); }
@media (max-width: 1020px) { .grid-4, .grid-3 { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 640px)  { .grid-2, .grid-3, .grid-4 { grid-template-columns: 1fr; } }

.page-head { margin-bottom: clamp(24px, 3.5vw, 36px); }
.page-head .kicker {
  display: inline-flex; align-items: center; gap: 10px;
  font-family: var(--fd); font-size: 11.5px; font-weight: 600;
  letter-spacing: .28em; text-transform: uppercase; color: var(--blue-sky); margin-bottom: 10px;
}
.page-head .kicker::before {
  content: ''; width: 28px; height: 1.5px; background: var(--grad);
  box-shadow: 0 0 10px rgba(59, 130, 246, .8);
}
.page-head h1 { font-size: clamp(27px, 4vw, 40px); letter-spacing: -.02em; }
.page-head p { color: var(--muted); margin-top: 8px; max-width: 640px; }
.grad-text {
  background: var(--grad-text);
  background-size: 200% 100%;
  -webkit-background-clip: text; background-clip: text;
  -webkit-text-fill-color: transparent; color: transparent;
  animation: gradSlide 7s ease-in-out infinite alternate;
}
@keyframes gradSlide { from { background-position: 0% 0; } to { background-position: 100% 0; } }

/* ---------- Stat tiles ---------- */
.stat {
  position: relative; overflow: hidden;
  border-radius: var(--radius); border: 1px solid var(--line);
  background: linear-gradient(160deg, var(--panel-strong), var(--panel));
  padding: 20px 22px;
  transition: transform .45s var(--ease), border-color .45s, box-shadow .45s;
}
.stat:hover {
  transform: translateY(-4px);
  border-color: rgba(124, 181, 255, .4);
  box-shadow: 0 18px 44px rgba(2, 6, 16, .55);
}
.stat::after {
  content: ''; position: absolute; right: -34px; top: -34px; width: 120px; height: 120px;
  background: radial-gradient(circle, rgba(15, 98, 226, .22), transparent 65%);
  transition: transform .5s var(--ease);
}
.stat:hover::after { transform: scale(1.35); }
.stat::before {  /* blueprint corner ticks */
  content: ''; position: absolute; inset: 9px; pointer-events: none; opacity: 0;
  background:
    linear-gradient(var(--blue-sky), var(--blue-sky)) top left / 12px 1.5px,
    linear-gradient(var(--blue-sky), var(--blue-sky)) top left / 1.5px 12px,
    linear-gradient(var(--blue-sky), var(--blue-sky)) bottom right / 12px 1.5px,
    linear-gradient(var(--blue-sky), var(--blue-sky)) bottom right / 1.5px 12px;
  background-repeat: no-repeat;
  transition: opacity .4s;
}
.stat:hover::before { opacity: .6; }
.stat b {
  display: block; font-family: var(--fd); font-size: 31px; font-weight: 700;
  letter-spacing: -.02em; line-height: 1.15;
  font-variant-numeric: tabular-nums;
}
.stat span { color: var(--muted); font-size: 12px; letter-spacing: .11em; text-transform: uppercase; font-weight: 500; }

/* ---------- Progress bars ---------- */
.pbar {
  position: relative; height: 8px; border-radius: 99px;
  background: rgba(255, 255, 255, .07); overflow: hidden;
}
.pbar i {
  display: block; height: 100%; border-radius: 99px; position: relative;
  background: var(--grad); box-shadow: 0 0 14px rgba(59, 130, 246, .75);
  transition: width .9s var(--ease);
  overflow: hidden;
}
.pbar i::after {  /* moving shimmer */
  content: ''; position: absolute; inset: 0;
  background: linear-gradient(105deg, transparent 30%, rgba(255, 255, 255, .45) 50%, transparent 70%);
  animation: pbarShine 2.4s ease-in-out infinite;
}
@keyframes pbarShine {
  0% { transform: translateX(-130%); }
  55%, 100% { transform: translateX(130%); }
}
.pbar.done i { background: linear-gradient(90deg, #16a34a, #22c55e); box-shadow: 0 0 14px rgba(34, 197, 94, .65); }

/* ---------- Course cards ---------- */
.ccard {
  position: relative;
  display: flex; flex-direction: column; overflow: hidden;
  border-radius: var(--radius-lg); border: 1px solid var(--line);
  background: linear-gradient(170deg, var(--bg-3), var(--bg-2));
  transition: transform .5s var(--ease), border-color .5s, box-shadow .5s;
  transform-style: preserve-3d;
  will-change: transform;
}
.ccard:hover {
  border-color: rgba(124, 181, 255, .45);
  box-shadow: 0 30px 70px rgba(2, 6, 16, .7), 0 0 0 1px rgba(15, 98, 226, .12), 0 0 44px rgba(15, 98, 226, .1);
}
.ccard::after {  /* hover shine sweep across the whole card */
  content: ''; position: absolute; inset: 0; z-index: 3; pointer-events: none;
  background: linear-gradient(105deg, transparent 42%, rgba(255, 255, 255, .09) 50%, transparent 58%);
  transform: translateX(-140%);
  transition: transform .9s var(--ease);
}
.ccard:hover::after { transform: translateX(140%); }
.ccard__media { position: relative; height: 155px; overflow: hidden; }
.ccard__media img {
  width: 100%; height: 100%; object-fit: cover;
  filter: saturate(.85) contrast(1.02);
  transition: transform .9s var(--ease), filter .5s;
}
.ccard:hover .ccard__media img { transform: scale(1.09); filter: saturate(1.05); }
.ccard__media::after {
  content: ''; position: absolute; inset: 0;
  background: linear-gradient(180deg, rgba(15, 98, 226, .14), transparent 40%, rgba(10, 16, 28, .96));
}
.ccard__division { position: absolute; top: 12px; left: 12px; z-index: 2; }
.ccard__body { padding: 20px 22px 22px; display: flex; flex-direction: column; flex: 1; gap: 10px; }
.ccard__body h3 { font-size: 18px; transition: color .3s; }
.ccard:hover .ccard__body h3 { color: var(--blue-sky); }
.ccard__body .desc { color: var(--muted); font-size: 13.5px; flex: 1; }
.ccard__meta { display: flex; flex-wrap: wrap; gap: 12px; color: var(--muted-2); font-size: 12.5px; font-weight: 500; }
.ccard__meta span { display: inline-flex; align-items: center; gap: 5px; }
.ccard__foot { display: flex; align-items: center; gap: 10px; margin-top: 6px; }

/* ---------- Auth ---------- */
.auth-wrap { min-height: 100vh; display: grid; grid-template-columns: 1.05fr 1fr; }
.auth-side {
  position: relative; overflow: hidden; display: flex; flex-direction: column;
  justify-content: space-between; padding: clamp(28px, 4vw, 54px);
  background: url('/img/helmets.jpg') center/cover no-repeat;
}
.auth-side::before {
  content: ''; position: absolute; inset: 0;
  background:
    radial-gradient(90% 70% at 15% 8%, rgba(15, 98, 226, .42), transparent 60%),
    linear-gradient(200deg, rgba(3, 6, 12, .5), rgba(3, 5, 9, .94));
}
.auth-side::after {  /* blueprint grid over the photo */
  content: ''; position: absolute; inset: 0; opacity: .5;
  background-image:
    linear-gradient(rgba(124, 181, 255, .06) 1px, transparent 1px),
    linear-gradient(90deg, rgba(124, 181, 255, .06) 1px, transparent 1px);
  background-size: 56px 56px;
  mask-image: radial-gradient(80% 75% at 40% 35%, #000 25%, transparent 100%);
  -webkit-mask-image: radial-gradient(80% 75% at 40% 35%, #000 25%, transparent 100%);
}
.auth-side > * { position: relative; z-index: 2; }
.auth-side img.logo { height: 52px; width: auto; }
.auth-side h1 {
  font-size: clamp(30px, 3.6vw, 50px); max-width: 500px; margin-bottom: 16px;
  letter-spacing: -.025em;
}
.auth-side h1 .aline { display: block; overflow: hidden; }
.auth-side h1 .aline > span {
  display: inline-block; transform: translateY(115%);
  animation: lineUp 1s var(--ease) forwards;
  animation-delay: var(--ld, .15s);
}
@keyframes lineUp { to { transform: translateY(0); } }
.auth-side p { color: var(--muted); max-width: 440px; }
.auth-side .points { display: flex; flex-direction: column; gap: 12px; margin-top: 26px; }
.auth-side .points div {
  display: flex; gap: 12px; align-items: flex-start; color: #c3cede; font-size: 14.5px;
  opacity: 0; animation: rise .7s var(--ease) forwards;
}
.auth-side .points div:nth-child(1) { animation-delay: .55s; }
.auth-side .points div:nth-child(2) { animation-delay: .7s; }
.auth-side .points div:nth-child(3) { animation-delay: .85s; }
.auth-side .points svg { width: 20px; height: 20px; color: var(--blue-light); flex: none; margin-top: 1px; filter: drop-shadow(0 0 6px rgba(77, 141, 255, .8)); }

/* floating glass chips on the auth photo */
.auth-chip {
  position: absolute; z-index: 2;
  display: flex; align-items: center; gap: 11px;
  padding: 13px 18px; border-radius: 15px;
  background: rgba(6, 10, 18, .78); backdrop-filter: blur(14px);
  border: 1px solid var(--line-strong);
  box-shadow: 0 18px 44px rgba(2, 6, 16, .6);
  font-family: var(--fd); font-size: 13.5px; font-weight: 600;
  animation: chipFloat 6.5s ease-in-out infinite;
}
.auth-chip small { display: block; font-family: var(--fb); font-weight: 400; font-size: 11.5px; color: var(--muted); }
.auth-chip .cico {
  width: 36px; height: 36px; border-radius: 10px; flex: none;
  display: grid; place-items: center; color: #fff;
  background: var(--grad); box-shadow: var(--glow);
}
.auth-chip .cico svg { width: 18px; height: 18px; }
.auth-chip--1 { top: 24%; right: 7%; }
.auth-chip--2 { bottom: 20%; right: 13%; animation-delay: -3.2s; }
@keyframes chipFloat {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-12px); }
}

.auth-form { display: flex; align-items: center; justify-content: center; padding: clamp(24px, 4vw, 60px); position: relative; }
.auth-card {
  position: relative; width: min(440px, 100%);
  padding: clamp(26px, 3vw, 36px);
  border-radius: 24px;
  background: linear-gradient(165deg, rgba(15, 23, 38, .88), rgba(6, 10, 18, .92));
  backdrop-filter: blur(18px);
  box-shadow: 0 40px 90px rgba(2, 5, 12, .7);
}
.auth-card::before {  /* rotating conic border */
  content: ''; position: absolute; inset: -1.5px; z-index: -1; border-radius: 25px;
  background: conic-gradient(from var(--ga, 0deg),
    rgba(77, 141, 255, .0) 0%, rgba(77, 141, 255, .55) 12%, rgba(103, 232, 249, .35) 22%,
    rgba(77, 141, 255, .0) 38%, rgba(77, 141, 255, .0) 55%, rgba(15, 98, 226, .5) 72%, rgba(77, 141, 255, .0) 90%);
  animation: borderSpin 7s linear infinite;
}
.auth-card::after {  /* soft outer glow */
  content: ''; position: absolute; inset: -40px; z-index: -2; border-radius: 60px;
  background: radial-gradient(60% 60% at 50% 45%, rgba(15, 98, 226, .16), transparent 70%);
  pointer-events: none;
}
@keyframes borderSpin { to { --ga: 360deg; } }
@supports not (background: conic-gradient(from var(--ga), red, blue)) {
  .auth-card::before { background: linear-gradient(135deg, rgba(77, 141, 255, .4), rgba(15, 98, 226, .1), rgba(77, 141, 255, .35)); animation: none; }
}

.auth-card .logo-sm { height: 44px; width: auto; margin: 0 auto 26px; display: none; }
.auth-tabs {
  position: relative; display: flex;
  background: rgba(3, 5, 10, .6);
  border: 1px solid var(--line-strong); border-radius: 13px; padding: 4px; margin-bottom: 26px;
}
.auth-tabs::before {  /* sliding pill */
  content: ''; position: absolute; top: 4px; bottom: 4px; left: 4px;
  width: calc(50% - 4px); border-radius: 10px;
  background: var(--grad); box-shadow: 0 6px 18px rgba(15, 98, 226, .45);
  transition: transform .4s var(--spring);
}
.auth-tabs.tab-2::before { transform: translateX(100%); }
.auth-tabs button {
  position: relative; z-index: 1; flex: 1; padding: 11px; border-radius: 10px;
  font-family: var(--fd); font-weight: 600; font-size: 14.5px; color: var(--muted);
  transition: color .3s;
}
.auth-tabs button.on { color: #fff; }
.auth-card h2 { font-size: 24px; margin-bottom: 4px; }
.auth-card > p.sub, .auth-card #auth-body p.sub { color: var(--muted); font-size: 14px; margin-bottom: 24px; }
@media (max-width: 900px) {
  .auth-wrap { grid-template-columns: 1fr; }
  .auth-side { display: none; }
  .auth-card .logo-sm { display: block; }
}

/* ---------- Learn / player ---------- */
.learn { display: grid; grid-template-columns: 330px 1fr; gap: 22px; align-items: start; }
@media (max-width: 980px) { .learn { grid-template-columns: 1fr; } }
.syllabus {
  border-radius: var(--radius-lg); border: 1px solid var(--line);
  background: linear-gradient(165deg, rgba(15, 23, 38, .7), rgba(6, 10, 18, .8));
  backdrop-filter: blur(10px);
  overflow: hidden; position: sticky; top: 88px;
  box-shadow: 0 24px 60px rgba(2, 6, 16, .45);
}
@media (max-width: 980px) { .syllabus { position: static; } }
.syllabus__head {
  display: flex; align-items: center; gap: 16px;
  padding: 18px 20px; border-bottom: 1px solid var(--line);
  background: linear-gradient(180deg, rgba(15, 98, 226, .08), transparent);
}
.syllabus__head h3 { font-size: 15px; flex: 1; }
.syllabus__head .pct { font-size: 11.5px; color: var(--muted); margin-top: 5px; }

/* circular progress ring */
.ring { position: relative; width: 62px; height: 62px; flex: none; }
.ring svg { width: 62px; height: 62px; transform: rotate(-90deg); }
.ring circle { fill: none; stroke-width: 5; stroke-linecap: round; }
.ring .track { stroke: rgba(255, 255, 255, .08); }
.ring .fill {
  stroke: url(#ringGrad); stroke-dasharray: 163.4;   /* 2πr, r=26 */
  stroke-dashoffset: 163.4;
  transition: stroke-dashoffset 1.1s var(--ease);
  filter: drop-shadow(0 0 5px rgba(59, 130, 246, .8));
}
.ring.done .fill { stroke: #22c55e; filter: drop-shadow(0 0 5px rgba(34, 197, 94, .8)); }
.ring b {
  position: absolute; inset: 0; display: grid; place-items: center;
  font-family: var(--fd); font-size: 14px; font-weight: 700;
  font-variant-numeric: tabular-nums;
}

.sy-mod { border-bottom: 1px solid var(--line); }
.sy-mod:last-child { border-bottom: 0; }
.sy-mod__title {
  padding: 13px 20px 9px; font-family: var(--fd); font-size: 11px; font-weight: 700;
  letter-spacing: .16em; text-transform: uppercase; color: var(--blue-sky);
}
.sy-lesson {
  position: relative;
  display: flex; align-items: center; gap: 11px; width: 100%; text-align: left;
  padding: 10px 20px; color: var(--muted); font-size: 13.5px;
  transition: background-color .25s, color .25s, padding-left .3s var(--ease);
}
.sy-lesson:hover { background: rgba(148, 178, 255, .05); color: #fff; padding-left: 24px; }
.sy-lesson.on {
  background: linear-gradient(90deg, rgba(15, 98, 226, .22), rgba(15, 98, 226, .05));
  color: #fff; box-shadow: inset 3px 0 0 var(--blue-bright);
}
.sy-lesson .dot {
  width: 19px; height: 19px; border-radius: 50%; flex: none;
  border: 1.5px solid var(--line-strong); display: grid; place-items: center;
  transition: background-color .35s, border-color .35s, transform .35s var(--spring);
}
.sy-lesson .dot svg { width: 11px; height: 11px; }
.sy-lesson.done .dot { background: var(--green); border-color: var(--green); color: #04220f; animation: popIn .4s var(--spring); }
.sy-lesson .mins { margin-left: auto; font-size: 11px; color: var(--muted-2); flex: none; }
.sy-assess {
  display: flex; align-items: center; gap: 11px; width: 100%;
  padding: 15px 20px; text-align: left;
  font-family: var(--fd); font-weight: 600; font-size: 14px; color: var(--ink);
  background: linear-gradient(90deg, rgba(15, 98, 226, .14), rgba(15, 98, 226, .04));
  transition: background-color .3s, padding-left .3s var(--ease);
}
.sy-assess:hover:not(:disabled) { background: rgba(15, 98, 226, .24); padding-left: 24px; }
.sy-assess:disabled { opacity: .5; cursor: not-allowed; }
.sy-assess.on { background: rgba(15, 98, 226, .3); box-shadow: inset 3px 0 0 var(--blue-bright); }

.lesson-view { min-width: 0; }
.lesson-view .crumb {
  font-family: var(--fd); font-size: 11.5px; letter-spacing: .18em;
  text-transform: uppercase; color: var(--blue-sky); margin-bottom: 8px;
  display: inline-flex; align-items: center; gap: 10px;
}
.lesson-view .crumb::before { content: ''; width: 22px; height: 1.5px; background: var(--grad); }
.lesson-view h1 { font-size: clamp(22px, 3vw, 32px); margin-bottom: 18px; }
.lesson-body { color: #ccd6e8; font-size: 15.5px; }
.lesson-body p { margin-bottom: 14px; }
.lesson-body h3 {
  position: relative;
  font-size: 17px; margin: 26px 0 10px; padding-left: 14px;
}
.lesson-body h3::before {
  content: ''; position: absolute; left: 0; top: .12em; bottom: .12em; width: 3px;
  border-radius: 3px; background: var(--grad);
  box-shadow: 0 0 10px rgba(59, 130, 246, .7);
}
.lesson-body ul { margin: 0 0 14px; padding-left: 4px; }
.lesson-body ul li { position: relative; padding-left: 24px; margin-bottom: 8px; }
.lesson-body ul li::before {
  content: ''; position: absolute; left: 4px; top: .58em;
  width: 7px; height: 7px; border-radius: 2px; background: var(--grad); transform: rotate(45deg);
  box-shadow: 0 0 6px rgba(59, 130, 246, .55);
}
.lesson-body strong { color: #fff; }
.lesson-body .callout {
  position: relative; margin: 18px 0; padding: 14px 18px 14px 44px; border-radius: 13px;
  border: 1px solid rgba(77, 141, 255, .35);
  background: linear-gradient(135deg, rgba(15, 98, 226, .14), rgba(15, 98, 226, .05));
  color: #dbe7ff; font-size: 14.5px;
}
.lesson-body .callout::before {
  content: '!'; position: absolute; left: 14px; top: 14px;
  width: 20px; height: 20px; border-radius: 7px;
  display: grid; place-items: center;
  background: var(--grad); color: #fff;
  font-family: var(--fd); font-weight: 700; font-size: 12px;
  box-shadow: 0 0 12px rgba(15, 98, 226, .6);
}
.lesson-nav { display: flex; gap: 12px; margin-top: 28px; flex-wrap: wrap; }
.lesson-nav .spacer { flex: 1; }

/* ---------- Quiz ---------- */
.quiz-q {
  border-radius: var(--radius); border: 1px solid var(--line);
  background: linear-gradient(160deg, var(--panel-strong), var(--panel));
  padding: 22px 24px; margin-bottom: 16px;
  transition: border-color .35s, box-shadow .35s;
}
.quiz-q:focus-within, .quiz-q:hover { border-color: rgba(124, 181, 255, .3); }
.quiz-q h3 { font-size: 16.5px; margin-bottom: 14px; display: flex; gap: 10px; }
.quiz-q h3 .qn { color: var(--blue-light); flex: none; }
.opt {
  display: flex; align-items: center; gap: 12px; width: 100%; text-align: left;
  padding: 12px 15px; border-radius: 11px; margin-bottom: 9px;
  border: 1px solid var(--line-strong); background: rgba(3, 5, 10, .45);
  color: var(--muted); font-size: 14.5px;
  transition: border-color .25s, background-color .25s, color .25s, transform .25s var(--ease);
}
.opt:hover { border-color: rgba(124, 181, 255, .5); color: #fff; transform: translateX(4px); }
.opt.sel {
  border-color: var(--blue-bright); background: rgba(15, 98, 226, .17); color: #fff;
  box-shadow: 0 0 0 3px rgba(15, 98, 226, .16), 0 0 22px rgba(15, 98, 226, .12);
}
.opt .radio {
  width: 18px; height: 18px; border-radius: 50%; flex: none;
  border: 2px solid var(--muted-2); display: grid; place-items: center;
  transition: border-color .25s;
}
.opt.sel .radio { border-color: var(--blue-light); }
.opt.sel .radio::after {
  content: ''; width: 8px; height: 8px; border-radius: 50%;
  background: var(--blue-light); animation: popIn .3s var(--spring);
  box-shadow: 0 0 8px rgba(77, 141, 255, .9);
}
.opt.correct { border-color: rgba(34, 197, 94, .6); background: rgba(34, 197, 94, .1); color: #d8ffe6; }
.opt.wrong { border-color: rgba(239, 68, 68, .6); background: rgba(239, 68, 68, .08); color: #ffd9d9; }
.quiz-explain {
  margin-top: 8px; font-size: 13.5px; color: var(--muted);
  padding: 10px 14px; border-radius: 10px;
  background: rgba(148, 178, 255, .05); border: 1px dashed var(--line-strong);
}

/* ---------- Result ---------- */
.result-hero {
  position: relative; text-align: center; padding: clamp(34px, 5vw, 54px);
  border-radius: var(--radius-lg); border: 1px solid var(--line-strong); overflow: hidden;
  background:
    radial-gradient(85% 130% at 50% -20%, rgba(15, 98, 226, .32), transparent 60%),
    linear-gradient(170deg, var(--bg-3), var(--bg-1));
  box-shadow: 0 34px 80px rgba(2, 6, 16, .6);
}
.result-hero::before {
  content: ''; position: absolute; inset: 0; opacity: .5; pointer-events: none;
  background-image:
    linear-gradient(rgba(124, 181, 255, .05) 1px, transparent 1px),
    linear-gradient(90deg, rgba(124, 181, 255, .05) 1px, transparent 1px);
  background-size: 46px 46px;
  mask-image: radial-gradient(70% 90% at 50% 10%, #000, transparent);
  -webkit-mask-image: radial-gradient(70% 90% at 50% 10%, #000, transparent);
}
.result-hero > * { position: relative; z-index: 1; }

/* big score gauge */
.gauge { position: relative; width: 168px; height: 168px; margin: 0 auto 16px; }
.gauge svg { width: 168px; height: 168px; transform: rotate(-90deg); }
.gauge circle { fill: none; stroke-width: 10; stroke-linecap: round; }
.gauge .track { stroke: rgba(255, 255, 255, .07); }
.gauge .fill {
  stroke-dasharray: 452.4;      /* 2πr, r=72 */
  stroke-dashoffset: 452.4;
  transition: stroke-dashoffset 1.6s var(--ease) .2s;
}
.gauge.pass .fill { stroke: url(#gaugeGradPass); filter: drop-shadow(0 0 10px rgba(34, 197, 94, .7)); }
.gauge.fail .fill { stroke: url(#gaugeGradFail); filter: drop-shadow(0 0 10px rgba(239, 68, 68, .55)); }
.gauge .score {
  position: absolute; inset: 0; display: grid; place-items: center;
  font-family: var(--fd); font-size: 44px; font-weight: 700; letter-spacing: -.02em;
  font-variant-numeric: tabular-nums;
}
.gauge.pass .score { color: #4ade80; text-shadow: 0 0 34px rgba(34, 197, 94, .55); }
.gauge.fail .score { color: #f87171; }
.result-hero h2 { font-size: clamp(21px, 3vw, 30px); margin: 8px 0 6px; }
.result-hero p { color: var(--muted); max-width: 460px; margin: 0 auto 22px; }
.score.pass, .score.fail { font-family: var(--fd); }   /* legacy class kept harmless */

.confetti-canvas {
  position: fixed; inset: 0; z-index: 1500; pointer-events: none;
}

/* ---------- Tables ---------- */
.tbl-wrap {
  overflow-x: auto; border-radius: var(--radius); border: 1px solid var(--line);
  background: rgba(3, 5, 10, .3);
}
table { width: 100%; border-collapse: collapse; font-size: 13.5px; }
th {
  position: sticky; top: 0;
  text-align: left; padding: 12px 15px;
  font-family: var(--fd); font-size: 10.5px; font-weight: 600;
  letter-spacing: .14em; text-transform: uppercase; color: var(--muted-2);
  border-bottom: 1px solid var(--line-strong); white-space: nowrap;
  background: rgba(10, 16, 28, .95); backdrop-filter: blur(8px);
  z-index: 2;
}
td { padding: 12px 15px; border-bottom: 1px solid var(--line); color: var(--muted); vertical-align: middle; }
tr:last-child td { border-bottom: 0; }
tbody tr { transition: background-color .25s, box-shadow .25s; }
tbody tr:hover { background: rgba(15, 98, 226, .07); box-shadow: inset 2px 0 0 var(--blue-bright); }
td b { color: var(--ink); font-weight: 600; }
td .sub { display: block; font-size: 12px; color: var(--muted-2); }

/* ---------- Admin editor ---------- */
.ed-mod {
  border: 1px solid var(--line); border-radius: var(--radius);
  background: rgba(148, 178, 255, .02); margin-bottom: 14px; overflow: hidden;
  transition: border-color .3s;
}
.ed-mod:hover { border-color: rgba(124, 181, 255, .28); }
.ed-mod__head {
  display: flex; align-items: center; gap: 10px; padding: 13px 16px;
  background: linear-gradient(90deg, rgba(15, 98, 226, .08), transparent);
  border-bottom: 1px solid var(--line);
}
.ed-mod__head h4 { font-size: 15px; flex: 1; }
.ed-lesson {
  display: flex; align-items: center; gap: 10px; padding: 10px 16px 10px 26px;
  border-bottom: 1px solid var(--line); font-size: 13.5px; color: var(--muted);
  transition: background-color .2s;
}
.ed-lesson:hover { background: rgba(148, 178, 255, .04); }
.ed-lesson:last-child { border-bottom: 0; }
.ed-lesson .t { flex: 1; color: var(--ink); }
.iconbtn {
  width: 30px; height: 30px; border-radius: 8px; display: grid; place-items: center;
  color: var(--muted); border: 1px solid transparent;
  transition: color .2s, border-color .2s, background-color .2s, transform .25s var(--spring);
}
.iconbtn:hover { color: #fff; border-color: var(--line-strong); background: rgba(255, 255, 255, .06); transform: translateY(-2px); }
.iconbtn.danger:hover { color: #fca5a5; border-color: rgba(239, 68, 68, .4); background: rgba(239, 68, 68, .08); }
.iconbtn svg { width: 15px; height: 15px; }

.filters { display: flex; gap: 10px; flex-wrap: wrap; margin-bottom: 18px; align-items: center; }
.filters input[type="search"], .filters input[type="text"] {
  padding: 11px 15px; border-radius: 11px; min-width: 250px;
  border: 1px solid var(--line-strong); background: rgba(3, 5, 10, .6); color: var(--ink);
  font: inherit; font-size: 14px;
  transition: border-color .3s, box-shadow .3s;
}
.filters input:focus { outline: none; border-color: var(--blue-bright); box-shadow: 0 0 0 4px rgba(15, 98, 226, .15); }
.chip {
  padding: 8px 16px; border-radius: 999px; font-family: var(--fd); font-weight: 600; font-size: 12.5px;
  color: var(--muted); border: 1px solid var(--line-strong); background: rgba(148, 178, 255, .04);
  transition: color .25s, border-color .25s, background-color .25s, transform .3s var(--spring), box-shadow .3s;
}
.chip:hover { color: #fff; border-color: rgba(124, 181, 255, .5); transform: translateY(-2px); }
.chip.on {
  color: #fff; background: linear-gradient(160deg, rgba(15, 98, 226, .35), rgba(15, 98, 226, .18));
  border-color: rgba(77, 141, 255, .6);
  box-shadow: 0 6px 20px rgba(15, 98, 226, .3), inset 0 1px 0 rgba(255, 255, 255, .12);
}

/* ---------- Modal ---------- */
.modal-back {
  position: fixed; inset: 0; z-index: 300;
  background: rgba(2, 4, 8, .74); backdrop-filter: blur(8px);
  display: grid; place-items: center; padding: 18px;
  animation: fadeIn .22s ease;
}
.modal {
  position: relative;
  width: min(560px, 100%); max-height: 88vh; overflow-y: auto;
  border-radius: var(--radius-lg); border: 1px solid var(--line-strong);
  background: linear-gradient(165deg, var(--bg-3), var(--bg-1));
  padding: 26px 26px 24px;
  animation: modalIn .4s var(--spring);
  box-shadow: 0 40px 100px rgba(1, 3, 8, .8), 0 0 0 1px rgba(15, 98, 226, .08), 0 0 60px rgba(15, 98, 226, .07);
}
@keyframes modalIn {
  from { opacity: 0; transform: translateY(22px) scale(.96); }
  to   { opacity: 1; transform: none; }
}
.modal.wide { width: min(760px, 100%); }
.modal h3 { font-size: 19px; margin-bottom: 18px; }
.modal .actions { display: flex; gap: 10px; justify-content: flex-end; margin-top: 20px; }

/* ---------- Toasts ---------- */
#toasts { position: fixed; bottom: 22px; right: 22px; z-index: 2200; display: flex; flex-direction: column; gap: 10px; }
.toast {
  position: relative;
  padding: 13px 18px 13px 22px; border-radius: 13px; max-width: 340px;
  font-size: 14px; font-weight: 500; color: #fff;
  background: rgba(8, 12, 20, .92); backdrop-filter: blur(14px);
  border: 1px solid var(--line-strong);
  box-shadow: 0 18px 44px rgba(1, 4, 10, .7);
  animation: toastIn .45s var(--spring);
  overflow: hidden;
}
@keyframes toastIn {
  from { opacity: 0; transform: translateX(40px) scale(.95); }
  to   { opacity: 1; transform: none; }
}
.toast::before {
  content: ''; position: absolute; left: 0; top: 0; bottom: 0; width: 4px;
  background: var(--grad); box-shadow: 0 0 12px rgba(59, 130, 246, .8);
}
.toast.ok::before { background: linear-gradient(180deg, #16a34a, #22c55e); box-shadow: 0 0 12px rgba(34, 197, 94, .8); }
.toast.err::before { background: linear-gradient(180deg, #dc2626, #ef4444); box-shadow: 0 0 12px rgba(239, 68, 68, .8); }

/* ---------- Empty state ---------- */
.empty {
  text-align: center; padding: 54px 20px; color: var(--muted);
  border: 1.5px dashed var(--line-strong); border-radius: var(--radius-lg);
  background: radial-gradient(60% 80% at 50% 0%, rgba(15, 98, 226, .05), transparent 70%);
}
.empty svg { width: 44px; height: 44px; margin: 0 auto 14px; color: var(--muted-2); }
.empty b { display: block; font-family: var(--fd); font-size: 17px; color: var(--ink); margin-bottom: 5px; }

.footer-bar {
  border-top: 1px solid var(--line); padding: 20px clamp(16px, 3vw, 34px);
  display: flex; gap: 12px; flex-wrap: wrap; align-items: center; justify-content: space-between;
  color: var(--muted-2); font-size: 12.5px;
  background: linear-gradient(180deg, transparent, rgba(3, 5, 9, .6));
}
.footer-bar a { color: var(--muted); }

/* ---------- Reduced motion ---------- */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: .01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: .01ms !important;
  }
  html { scroll-behavior: auto; }
  .fx-particles { display: none !important; }
}
