:root {
  --bg: #02050a;
  --bg-2: #06111d;
  --panel: rgba(5, 12, 22, 0.82);
  --panel-strong: rgba(7, 18, 32, 0.94);
  --line: rgba(112, 189, 255, 0.16);
  --line-2: rgba(112, 189, 255, 0.30);
  --text: #ecf7ff;
  --muted: #8ca9c5;
  --dim: #58718a;
  --blue: #1f73ff;
  --cyan: #3ee8ff;
  --green: #64ffd2;
  --amber: #ffd166;
  --danger: #ff5d7d;
  --shadow: 0 28px 95px rgba(0, 0, 0, 0.62);
  --radius: 24px;
}

* { box-sizing: border-box; }
html { min-height: 100%; background: var(--bg); }
body {
  margin: 0;
  min-height: 100vh;
  color: var(--text);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  overflow-x: hidden;
  background: #02050a;
}
button, input, textarea, select { font: inherit; }
button { cursor: pointer; }
button:disabled { cursor: not-allowed; opacity: .48; }
::selection { background: rgba(62, 232, 255, .28); color: #fff; }

.kmar-bg {
  position: fixed;
  inset: 0;
  z-index: -10;
  overflow: hidden;
  background:
    radial-gradient(circle at 12% 10%, rgba(31, 115, 255, .26), transparent 30%),
    radial-gradient(circle at 86% 18%, rgba(62, 232, 255, .12), transparent 28%),
    radial-gradient(circle at 48% 86%, rgba(255, 209, 102, .055), transparent 34%),
    linear-gradient(135deg, #010307 0%, #071325 46%, #02050a 100%);
}
.bg-gradient {
  position: absolute;
  inset: -20%;
  background:
    conic-gradient(from 160deg at 58% 44%, transparent 0deg, rgba(31, 115, 255, .20) 60deg, transparent 120deg, rgba(62, 232, 255, .10) 190deg, transparent 260deg, rgba(2, 5, 10, .2) 360deg);
  filter: blur(45px);
  opacity: .82;
  animation: atmosphere 18s ease-in-out infinite alternate;
}
.bg-grid {
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(rgba(96, 176, 255, .08) 1px, transparent 1px),
    linear-gradient(90deg, rgba(96, 176, 255, .08) 1px, transparent 1px),
    linear-gradient(rgba(96, 176, 255, .035) 1px, transparent 1px),
    linear-gradient(90deg, rgba(96, 176, 255, .035) 1px, transparent 1px);
  background-size: 92px 92px, 92px 92px, 23px 23px, 23px 23px;
  mask-image: radial-gradient(circle at 50% 30%, #000 0 52%, transparent 88%);
  opacity: .7;
  transform: perspective(900px) rotateX(58deg) translateY(-16%);
  transform-origin: top center;
  animation: gridDrift 22s linear infinite;
}
.bg-topography {
  position: absolute;
  inset: -80px;
  opacity: .24;
  background-image: url("data:image/svg+xml,%3Csvg width='760' height='760' viewBox='0 0 760 760' xmlns='http://www.w3.org/2000/svg'%3E%3Cg fill='none' stroke='%234abfff' stroke-opacity='.34' stroke-width='1'%3E%3Cpath d='M20 240c80-44 143-14 190 22s102 45 172 2 151-68 243-25 108 119 55 171-126 52-194 30-133-29-208 11S96 507 33 456-60 318 20 240z'/%3E%3Cpath d='M82 266c64-32 110-6 149 24s91 29 149-5 130-42 196-11 78 83 34 119-98 34-154 16-112-20-169 12-138 47-187 12-82-119-18-167z'/%3E%3Cpath d='M154 289c44-21 72 2 101 20s63 17 106-7 89-26 134-6 54 57 23 81-70 21-111 9-80-11-119 9-94 29-127 5-51-80-7-111z'/%3E%3Cpath d='M228 315c27-9 46 3 66 16s43 12 70-4 58-13 84 3 31 37 11 52-46 11-73 5-52-6-78 6-59 18-82 1-25-61 2-79z'/%3E%3C/g%3E%3C/svg%3E");
  background-size: 760px 760px;
  animation: topoMove 34s linear infinite;
}
.bg-radar {
  position: absolute;
  right: -220px;
  top: -210px;
  width: 720px;
  height: 720px;
  border-radius: 50%;
  border: 1px solid rgba(62, 232, 255, .10);
  box-shadow: inset 0 0 80px rgba(31, 115, 255, .05), 0 0 90px rgba(31, 115, 255, .10);
  opacity: .72;
}
.bg-radar::before,
.bg-radar::after {
  content: "";
  position: absolute;
  inset: 18%;
  border-radius: 50%;
  border: 1px solid rgba(62, 232, 255, .10);
}
.bg-radar::after { inset: 36%; }
.bg-radar span {
  position: absolute;
  left: 50%; top: 50%;
  width: 50%; height: 2px;
  transform-origin: left center;
  background: linear-gradient(90deg, rgba(62,232,255,.6), transparent);
  animation: radarSweep 6s linear infinite;
}
.bg-scan {
  position: absolute;
  inset: 0;
  pointer-events: none;
  background:
    linear-gradient(112deg, transparent 0 43%, rgba(255, 209, 102, .08) 43.2% 43.8%, transparent 44% 100%),
    repeating-linear-gradient(0deg, rgba(255,255,255,.035) 0 1px, transparent 1px 5px),
    radial-gradient(circle at center, transparent 0 45%, rgba(0,0,0,.62) 100%);
  mix-blend-mode: screen;
  opacity: .15;
}

.view { display: none; min-height: 100vh; }
.view.active { display: block; }
.hidden, .hidden-hard { display: none !important; }

.topbar {
  position: relative;
  min-height: 82px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  padding: 22px clamp(18px, 4vw, 50px);
  z-index: 2;
}
.topbar.solid {
  position: sticky;
  top: 0;
  backdrop-filter: blur(22px);
  background: linear-gradient(180deg, rgba(4,10,20,.92), rgba(4,10,20,.62));
  border-bottom: 1px solid rgba(100,185,255,.12);
}
.brand-mini {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  min-width: 0;
  color: #fff;
  font-weight: 900;
  letter-spacing: .04em;
  text-transform: uppercase;
}
.brand-mini img {
  width: 46px;
  height: 46px;
  object-fit: contain;
  border-radius: 12px;
  filter: drop-shadow(0 0 16px rgba(34, 131, 255, .72));
}
.brand-mini span { font-size: .92rem; }

.home-shell {
  min-height: calc(100vh - 82px);
  display: grid;
  place-items: center;
  padding: 28px clamp(16px, 4vw, 54px) 96px;
}
.command-layout {
  width: min(520px, 100%);
  display: grid;
  grid-template-columns: 1fr;
  gap: 0;
  align-items: center;
  justify-items: center;
}

.glass-card {
  position: relative;
  background: linear-gradient(145deg, rgba(6, 14, 27, .90), rgba(2, 6, 13, .78));
  border: 1px solid var(--line);
  box-shadow: var(--shadow), inset 0 1px 0 rgba(255, 255, 255, .055);
  backdrop-filter: blur(24px);
  border-radius: var(--radius);
  overflow: hidden;
}
.glass-card::before {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: inherit;
  padding: 1px;
  background: linear-gradient(135deg, rgba(62,232,255,.34), transparent 32%, rgba(31,115,255,.22) 68%, transparent);
  -webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0);
  -webkit-mask-composite: xor;
  mask-composite: exclude;
  pointer-events: none;
  opacity: .78;
}

.ops-visual {
  min-height: 452px;
  padding: 24px;
  animation: riseIn .9s ease both;
}
.ops-visual::after {
  content: "";
  position: absolute;
  inset: auto 26px 22px 26px;
  height: 2px;
  background: linear-gradient(90deg, transparent, rgba(255,209,102,.70), rgba(62,232,255,.46), transparent);
  box-shadow: 0 0 22px rgba(255,209,102,.20);
}
.ops-head {
  display: flex;
  gap: 8px;
  margin-bottom: 18px;
}
.ops-head span {
  width: 10px;
  height: 10px;
  border-radius: 999px;
  background: rgba(62,232,255,.55);
  box-shadow: 0 0 16px rgba(62,232,255,.44);
}
.ops-head span:nth-child(2) { opacity: .48; }
.ops-head span:nth-child(3) { opacity: .26; }
.map-frame {
  position: relative;
  min-height: 384px;
  border-radius: 22px;
  border: 1px solid rgba(114,190,255,.14);
  background:
    radial-gradient(circle at 72% 15%, rgba(62,232,255,.18), transparent 30%),
    radial-gradient(circle at 30% 80%, rgba(31,115,255,.20), transparent 34%),
    rgba(1, 8, 18, .62);
  overflow: hidden;
}
.map-frame::before {
  content: "";
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(rgba(92,170,255,.08) 1px, transparent 1px),
    linear-gradient(90deg, rgba(92,170,255,.08) 1px, transparent 1px);
  background-size: 34px 34px;
  animation: mapGrid 18s linear infinite;
}
.map-frame::after {
  content: "";
  position: absolute;
  width: 440px;
  height: 440px;
  right: -160px;
  top: -170px;
  border-radius: 50%;
  border: 1px solid rgba(62,232,255,.14);
  background: conic-gradient(from 0deg, rgba(62,232,255,.25), transparent 48deg, transparent 360deg);
  animation: rotate 7s linear infinite;
  opacity: .72;
}
.route-lines {
  position: absolute;
  inset: 20px;
  width: calc(100% - 40px);
  height: calc(100% - 40px);
  overflow: visible;
  z-index: 2;
}
.route {
  fill: none;
  stroke-linecap: round;
  stroke-linejoin: round;
}
.route-main {
  stroke: url(#routeGlow);
  stroke-width: 4;
  filter: drop-shadow(0 0 10px rgba(62,232,255,.55));
  stroke-dasharray: 16 14;
  animation: dash 11s linear infinite;
}
.route-muted {
  stroke: rgba(114,190,255,.30);
  stroke-width: 2;
  stroke-dasharray: 6 14;
  animation: dash 17s linear infinite reverse;
}
.route-muted.alt { opacity: .58; }
.map-node {
  fill: #3ee8ff;
  filter: drop-shadow(0 0 10px rgba(62,232,255,.72));
}
.map-node.active {
  fill: #fff;
  animation: pulse 1.8s ease-in-out infinite;
}
.radar-dot {
  position: absolute;
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--green);
  box-shadow: 0 0 20px rgba(100,255,210,.78);
  z-index: 3;
}
.radar-dot.one { left: 22%; top: 68%; animation: blink 2.4s infinite; }
.radar-dot.two { left: 48%; top: 52%; animation: blink 2.4s .5s infinite; }
.radar-dot.three { right: 18%; top: 25%; animation: blink 2.4s 1s infinite; }
.login-panel {
  width: min(520px, 100%);
  padding: clamp(28px, 4vw, 42px);
  animation: riseIn .9s .08s ease both;
}
.login-panel::after {
  content: "";
  position: absolute;
  inset: -1px;
  border-radius: inherit;
  pointer-events: none;
  background:
    radial-gradient(circle at 18% 0%, rgba(62,232,255,.17), transparent 34%),
    radial-gradient(circle at 92% 92%, rgba(31,115,255,.16), transparent 34%);
  opacity: .85;
}
.login-panel > * { position: relative; z-index: 1; }
.panel-stripe {
  position: absolute;
  left: 0;
  top: 18%;
  bottom: 18%;
  width: 3px;
  background: linear-gradient(180deg, transparent, var(--cyan), var(--blue), transparent);
  box-shadow: 0 0 24px rgba(62,232,255,.74);
}
.eyebrow {
  margin: 0 0 10px;
  color: var(--cyan);
  text-transform: uppercase;
  letter-spacing: .18em;
  font-size: .72rem;
  font-weight: 900;
}
h1, h2, h3, h4, p { margin-top: 0; }
h1 {
  margin-bottom: 10px;
  font-size: clamp(46px, 8vw, 82px);
  line-height: .9;
  letter-spacing: -.065em;
  text-shadow: 0 0 30px rgba(31, 115, 255, .45);
}
.login-sub {
  margin: 0 0 22px;
  color: var(--muted);
  font-weight: 600;
}
.stack { display: grid; gap: 13px; }
.field, textarea, select {
  width: 100%;
  color: var(--text);
  background: rgba(1, 8, 18, .76);
  border: 1px solid rgba(115, 190, 255, .18);
  outline: none;
  border-radius: 16px;
  padding: 15px 16px;
  box-shadow: inset 0 0 0 1px rgba(255,255,255,.018);
  transition: border .18s ease, box-shadow .18s ease, transform .18s ease, background .18s ease;
}
.field:focus, textarea:focus, select:focus {
  border-color: rgba(62, 232, 255, .72);
  box-shadow: 0 0 0 4px rgba(62, 232, 255, .10), 0 0 34px rgba(31, 115, 255, .18);
  transform: translateY(-1px);
  background: rgba(2, 12, 26, .86);
}
textarea { min-height: 118px; resize: vertical; }
input::placeholder, textarea::placeholder { color: rgba(169, 197, 220, .58); }

.primary-btn, .ghost-btn, .file-btn {
  position: relative;
  min-height: 48px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  border-radius: 16px;
  padding: 0 18px;
  color: var(--text);
  text-decoration: none;
  overflow: hidden;
  transition: transform .18s ease, border-color .18s ease, background .18s ease, box-shadow .18s ease;
}
.primary-btn {
  border: 1px solid rgba(116, 210, 255, .34);
  background: linear-gradient(135deg, #0b46d9, #1384ff 46%, #32d8ff);
  font-weight: 900;
  box-shadow: 0 16px 38px rgba(14, 118, 255, .34), inset 0 1px 0 rgba(255,255,255,.24);
}
.primary-btn::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(100deg, transparent, rgba(255,255,255,.26), transparent);
  transform: translateX(-120%);
  transition: transform .55s ease;
}
.primary-btn:hover::after { transform: translateX(120%); }
.ghost-btn, .file-btn {
  border: 1px solid rgba(116, 190, 255, .18);
  background: rgba(5, 16, 31, .56);
  font-weight: 800;
}
.primary-btn:hover, .ghost-btn:hover, .file-btn:hover {
  transform: translateY(-2px);
  border-color: rgba(62, 232, 255, .46);
  box-shadow: 0 14px 35px rgba(0,0,0,.26), 0 0 28px rgba(31, 115, 255, .14);
}
.command-btn { min-width: 205px; }
.small { min-height: 38px; padding-inline: 13px; border-radius: 12px; font-size: .88rem; }
.wide { width: 100%; }
.file-btn input { display: none; }

.tiny { min-height: 18px; margin: 10px 0 0; font-size: .82rem; }
.muted { color: var(--muted); }
.error-line { color: var(--danger); }
.small-text { font-size: .9rem; }
.gap-top { margin-top: 16px; display: block; }

.exam-shell {
  width: min(1060px, calc(100% - 34px));
  margin: 0 auto;
  padding: 26px 0 96px;
}
.exam-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  padding: 24px;
  margin-bottom: 18px;
}
.exam-head h2 { margin: 0; font-size: clamp(22px, 3.2vw, 34px); letter-spacing: -.03em; }
.exam-meta { display: flex; align-items: center; gap: 12px; color: var(--muted); font-weight: 800; }
.progress-wrap { min-width: 230px; }
.progress-wrap > span { display: block; text-align: right; color: var(--cyan); font-weight: 900; margin-bottom: 8px; }
.progress-track {
  width: 100%; height: 10px; border-radius: 999px; overflow: hidden;
  background: rgba(128,190,255,.12); border: 1px solid rgba(128,190,255,.12);
}
.progress-track span {
  display: block; width: 0; height: 100%; border-radius: inherit;
  background: linear-gradient(90deg, var(--blue), var(--cyan));
  box-shadow: 0 0 18px rgba(62,232,255,.55);
  transition: width .28s ease;
}
.question-list { display: grid; gap: 16px; }
.question-card {
  position: relative;
  padding: 20px;
  border-radius: 22px;
  background: rgba(5, 13, 25, .72);
  border: 1px solid rgba(116,190,255,.14);
  box-shadow: 0 18px 50px rgba(0,0,0,.24);
  animation: cardIn .55s ease both;
}
.question-card label {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  font-weight: 850;
  line-height: 1.38;
  margin-bottom: 14px;
}
.q-number {
  flex: 0 0 auto;
  width: 32px;
  height: 32px;
  display: grid;
  place-items: center;
  border-radius: 11px;
  color: #fff;
  background: linear-gradient(135deg, rgba(31,115,255,.82), rgba(62,232,255,.72));
  box-shadow: 0 0 20px rgba(31,115,255,.28);
}
.question-card textarea { min-height: 150px; }
.exam-actions {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 14px;
  padding: 18px;
  margin-top: 18px;
}

.result-view { display: none; place-items: center; padding: 24px; }
.result-view.active { display: grid; }
.result-card { width: min(470px, 94vw); padding: 34px; text-align: center; }
.result-card h2 { margin-bottom: 10px; font-size: 2.1rem; letter-spacing: -.04em; }
.result-card p { color: var(--muted); margin-bottom: 22px; }

.admin-view.active { display: grid; grid-template-columns: 280px 1fr; }
.sidebar {
  min-height: 100vh;
  padding: 24px 18px;
  background: linear-gradient(180deg, rgba(5, 12, 24, .96), rgba(2, 6, 13, .90));
  border-right: 1px solid rgba(116,190,255,.13);
  position: sticky;
  top: 0;
  overflow: auto;
}
.side-brand {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 24px;
  padding: 14px;
  border-radius: 18px;
  background: rgba(6,16,31,.62);
  border: 1px solid rgba(116,190,255,.11);
}
.side-brand img { width: 46px; height: 46px; object-fit: contain; filter: drop-shadow(0 0 14px rgba(31,115,255,.72)); }
.side-brand strong { display: block; letter-spacing: .04em; }
.side-brand small { color: var(--muted); }
.nav-btn {
  width: 100%;
  min-height: 48px;
  margin-bottom: 10px;
  padding: 0 14px;
  text-align: left;
  border-radius: 16px;
  color: var(--muted);
  border: 1px solid transparent;
  background: transparent;
  font-weight: 850;
  transition: .18s ease;
}
.nav-btn:hover, .nav-btn.active {
  color: var(--text);
  border-color: rgba(62,232,255,.22);
  background: linear-gradient(135deg, rgba(31,115,255,.20), rgba(62,232,255,.08));
  box-shadow: inset 3px 0 0 rgba(62,232,255,.70);
}
.nav-btn.exit { margin-top: 18px; color: #ff9bad; }
.admin-main { padding: 28px clamp(18px, 3.4vw, 42px) 90px; }
.admin-header {
  display: flex;
  justify-content: space-between;
  gap: 20px;
  align-items: flex-end;
  margin-bottom: 22px;
}
.admin-header h2 { margin: 0; font-size: clamp(28px, 4.4vw, 52px); letter-spacing: -.055em; }
.admin-identity { display: none; }
.admin-stats { display: flex; gap: 12px; flex-wrap: wrap; }
.admin-stats span {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  min-height: 44px;
  padding: 0 14px;
  border-radius: 14px;
  border: 1px solid rgba(116,190,255,.14);
  background: rgba(5,15,29,.58);
  color: var(--muted);
  font-weight: 800;
}
.admin-stats b { color: var(--cyan); font-size: 1.1rem; }
.tab { display: none; }
.tab.active { display: block; }
.admin-grid { display: grid; gap: 18px; align-items: start; }
.admin-grid.two { grid-template-columns: minmax(300px, 420px) 1fr; }
.admin-grid.split { grid-template-columns: minmax(310px, .86fr) minmax(420px, 1.14fr); }
.admin-card { padding: 22px; }
.admin-card h3 { margin-bottom: 16px; letter-spacing: -.02em; font-size: 1.24rem; }
.form-grid { display: grid; gap: 12px; }
.inline-field { display: grid; grid-template-columns: 1fr auto; gap: 10px; }
.created-link { margin-top: 18px; display: grid; gap: 10px; }
.created-link label, .feedback-box label { color: var(--muted); font-size: .82rem; font-weight: 900; text-transform: uppercase; letter-spacing: .10em; }
.created-link textarea { min-height: 80px; }
.list { display: grid; gap: 12px; }
.empty {
  padding: 20px;
  border-radius: 16px;
  border: 1px dashed rgba(116,190,255,.18);
  color: var(--muted);
  background: rgba(2, 8, 18, .42);
}
.item-card {
  padding: 16px;
  border-radius: 18px;
  border: 1px solid rgba(116,190,255,.13);
  background: rgba(2, 9, 20, .62);
  transition: transform .18s ease, border .18s ease, background .18s ease;
}
.item-card:hover { transform: translateY(-2px); border-color: rgba(62,232,255,.28); background: rgba(5,16,32,.74); }
.item-top { display: flex; align-items: flex-start; justify-content: space-between; gap: 12px; margin-bottom: 12px; }
.item-title { font-weight: 900; }
.item-sub { margin-top: 4px; color: var(--muted); font-size: .86rem; line-height: 1.35; word-break: break-word; }
.badge {
  flex: 0 0 auto;
  border-radius: 999px;
  padding: 7px 10px;
  color: var(--green);
  background: rgba(100,255,210,.08);
  border: 1px solid rgba(100,255,210,.20);
  font-size: .74rem;
  font-weight: 950;
  text-transform: uppercase;
  letter-spacing: .08em;
}
.badge.off { color: var(--danger); background: rgba(255,93,125,.08); border-color: rgba(255,93,125,.20); }
.item-actions, .row-actions { display: flex; gap: 10px; flex-wrap: wrap; }
.item-actions .ghost-btn { min-height: 38px; padding-inline: 12px; border-radius: 12px; font-size: .84rem; }
.card-row { display: flex; align-items: center; justify-content: space-between; gap: 14px; margin-bottom: 12px; }
.card-row h3 { margin: 0; }
.review-panel { min-height: 420px; }
.review-answers { display: grid; gap: 14px; margin-top: 18px; }
.answer-block {
  padding: 16px;
  border-radius: 17px;
  background: rgba(2, 8, 18, .55);
  border: 1px solid rgba(116,190,255,.12);
}
.answer-block h4 { margin-bottom: 10px; line-height: 1.35; }
.answer-text {
  color: #d8e9f8;
  white-space: pre-wrap;
  line-height: 1.58;
  padding: 14px;
  border-radius: 14px;
  background: rgba(0,0,0,.22);
  border: 1px solid rgba(116,190,255,.08);
}
.score-row { display: flex; align-items: center; gap: 10px; margin-top: 12px; }
.score-input { max-width: 100px; padding: 10px 12px; }
.feedback-box { display: grid; gap: 10px; margin-top: 18px; }
.backup-card { max-width: 680px; }
.wrap { flex-wrap: wrap; }

.logs-card { max-width: 980px; }
.log-entry {
  display: grid;
  grid-template-columns: 155px 1fr;
  gap: 14px;
  padding: 15px;
  border-radius: 17px;
  border: 1px solid rgba(116,190,255,.12);
  background: rgba(2, 9, 20, .58);
}
.log-time { color: var(--muted); font-size: .82rem; font-weight: 850; }
.log-main { display: grid; gap: 5px; }
.log-action { color: var(--text); font-weight: 950; }
.log-detail { color: #bfd4e7; line-height: 1.45; }
.log-actor { color: var(--dim); font-size: .82rem; }
.item-actions .danger-action { color: #ffb5c3; border-color: rgba(255,93,125,.22); }
.item-actions .danger-action:hover { border-color: rgba(255,93,125,.42); background: rgba(255,93,125,.10); }

.creator-credit {
  position: fixed;
  right: 18px;
  bottom: 18px;
  z-index: 30;
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 7px 10px 7px 7px;
  border-radius: 999px;
  border: 1px solid rgba(116,190,255,.18);
  background: rgba(2, 7, 15, .70);
  backdrop-filter: blur(18px);
  box-shadow: 0 18px 50px rgba(0,0,0,.34);
  pointer-events: none;
}
.creator-credit img {
  width: 34px;
  height: 34px;
  object-fit: cover;
  border-radius: 999px;
  border: 1px solid rgba(255,255,255,.18);
}
.creator-credit span { display: block; color: var(--muted); font-size: .58rem; line-height: 1; letter-spacing:.03em; }
.creator-credit strong { display: block; color: #fff; font-size: .74rem; line-height: 1.08; font-weight: 900; }

.modal {
  position: fixed;
  inset: 0;
  z-index: 50;
  display: grid;
  place-items: center;
  padding: 22px;
  background: rgba(0, 3, 8, .70);
  backdrop-filter: blur(12px);
}
.modal-card { width: min(420px, 96vw); padding: 28px; animation: popIn .22s ease both; }
.modal-card h2 { margin-bottom: 18px; }
.close-btn {
  position: absolute;
  right: 14px;
  top: 12px;
  width: 38px;
  height: 38px;
  border: 1px solid rgba(116,190,255,.14);
  border-radius: 13px;
  color: var(--text);
  background: rgba(2, 8, 18, .55);
}
.toast {
  position: fixed;
  left: 50%;
  bottom: 25px;
  transform: translateX(-50%) translateY(18px);
  opacity: 0;
  z-index: 60;
  padding: 12px 16px;
  border-radius: 999px;
  color: var(--text);
  border: 1px solid rgba(62,232,255,.24);
  background: rgba(2, 8, 18, .82);
  backdrop-filter: blur(16px);
  box-shadow: 0 18px 50px rgba(0,0,0,.34);
  pointer-events: none;
  transition: .24s ease;
  font-weight: 800;
}
.toast.show { opacity: 1; transform: translateX(-50%) translateY(0); }

@keyframes atmosphere { from { transform: translate3d(-2%, -1%, 0) rotate(0deg) scale(1); } to { transform: translate3d(2%, 1%, 0) rotate(8deg) scale(1.06); } }
@keyframes gridDrift { from { background-position: 0 0, 0 0, 0 0, 0 0; } to { background-position: 92px 92px, 92px 92px, 23px 23px, 23px 23px; } }
@keyframes topoMove { from { background-position: 0 0; } to { background-position: 760px 380px; } }
@keyframes radarSweep { from { transform: rotate(0deg); } to { transform: rotate(360deg); } }
@keyframes rotate { from { transform: rotate(0deg); } to { transform: rotate(360deg); } }
@keyframes dash { to { stroke-dashoffset: -220; } }
@keyframes blink { 0%, 100% { opacity: .32; transform: scale(.78); } 45% { opacity: 1; transform: scale(1.28); } }
@keyframes pulse { 0%,100% { filter: drop-shadow(0 0 8px rgba(62,232,255,.55)); opacity: .9; } 50% { filter: drop-shadow(0 0 24px rgba(62,232,255,.98)); opacity: 1; } }
@keyframes mapGrid { from { background-position: 0 0; } to { background-position: 68px 68px; } }
@keyframes riseIn { from { opacity: 0; transform: translateY(22px) scale(.985); } to { opacity: 1; transform: translateY(0) scale(1); } }
@keyframes cardIn { from { opacity: 0; transform: translateY(14px); } to { opacity: 1; transform: translateY(0); } }
@keyframes popIn { from { opacity: 0; transform: scale(.96) translateY(8px); } to { opacity: 1; transform: scale(1) translateY(0); } }

@media (max-width: 980px) {
  .command-layout { grid-template-columns: 1fr; }
  .admin-view.active { grid-template-columns: 1fr; }
  .sidebar { position: relative; min-height: auto; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
  .side-brand { grid-column: 1 / -1; margin-bottom: 0; }
  .nav-btn { margin: 0; text-align: center; }
  .admin-grid.two, .admin-grid.split { grid-template-columns: 1fr; }
}
@media (max-width: 680px) {
  .topbar { padding: 16px; align-items: flex-start; }
  .brand-mini span { display: none; }
  .command-btn { min-width: 0; font-size: .86rem; padding-inline: 12px; }
  .home-shell { padding: 10px 16px 92px; }
  .login-panel { width: 100%; }
  .exam-head { align-items: stretch; flex-direction: column; }
  .progress-wrap { min-width: 100%; }
  .exam-meta span { max-width: 42vw; overflow: hidden; white-space: nowrap; text-overflow: ellipsis; }
  .exam-actions { flex-direction: column; align-items: stretch; }
  .inline-field { grid-template-columns: 1fr; }
  .admin-header { flex-direction: column; align-items: stretch; }
  .log-entry { grid-template-columns: 1fr; }
  .admin-stats { width: 100%; }
  .admin-stats span { flex: 1; }
  .creator-credit { right: 10px; bottom: 10px; transform: scale(.88); transform-origin: right bottom; }
}

/* v7: startmenu + fout/goed beoordeling */
.portal-menu {
  width: min(560px, 100%);
  padding: clamp(30px, 5vw, 50px);
  text-align: center;
  animation: riseIn .85s ease both;
  background:
    radial-gradient(circle at 50% 0%, rgba(62,232,255,.16), transparent 38%),
    linear-gradient(145deg, rgba(5, 13, 25, .94), rgba(1, 5, 12, .86));
}
.portal-menu::after {
  content: "";
  position: absolute;
  inset: auto 28px 22px 28px;
  height: 2px;
  background: linear-gradient(90deg, transparent, rgba(62,232,255,.60), rgba(255,209,102,.45), transparent);
  box-shadow: 0 0 24px rgba(62,232,255,.18);
}
.portal-logo-mark {
  width: 104px;
  height: 104px;
  margin: 0 auto 18px;
  display: grid;
  place-items: center;
  border-radius: 30px;
  border: 1px solid rgba(62,232,255,.18);
  background:
    linear-gradient(135deg, rgba(31,115,255,.18), rgba(62,232,255,.06)),
    rgba(0,0,0,.16);
  box-shadow: inset 0 0 40px rgba(31,115,255,.12), 0 20px 60px rgba(0,0,0,.34);
}
.portal-logo-mark img {
  width: 88px;
  height: 88px;
  object-fit: contain;
  filter: drop-shadow(0 0 20px rgba(31,115,255,.68));
}
.portal-menu h1 {
  margin-bottom: 20px;
  font-size: clamp(40px, 7vw, 68px);
}
.mode-buttons {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
  margin-top: 18px;
}
.access-form {
  margin-top: 18px;
  padding-top: 18px;
  border-top: 1px solid rgba(116,190,255,.13);
  animation: popIn .22s ease both;
}
.review-grid {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-top: 12px;
}
.review-buttons {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
}
.review-choice-btn {
  min-width: 112px;
  padding: 11px 16px;
  border-radius: 14px;
  border: 1px solid rgba(116,190,255,.14);
  background: rgba(2, 9, 20, .72);
  color: var(--text);
  font-weight: 950;
  letter-spacing: .03em;
  cursor: pointer;
  transition: transform .18s ease, background .18s ease, border .18s ease, box-shadow .18s ease;
}
.review-choice-btn:hover { transform: translateY(-1px); }
.review-choice-btn.good { color: var(--green); border-color: rgba(100,255,210,.24); }
.review-choice-btn.good.active { background: rgba(100,255,210,.16); border-color: rgba(100,255,210,.65); box-shadow: 0 0 28px rgba(100,255,210,.13); }
.review-choice-btn.wrong { color: var(--danger); border-color: rgba(255,93,125,.28); }
.review-choice-btn.wrong.active { background: rgba(255,93,125,.16); border-color: rgba(255,93,125,.68); box-shadow: 0 0 28px rgba(255,93,125,.13); }
.result-strip {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px;
  margin: 12px 0 10px;
  padding: 12px;
  border-radius: 16px;
  border: 1px solid rgba(255,209,102,.22);
  background: rgba(255,209,102,.07);
  color: var(--amber);
}
.result-strip span { color: var(--text); opacity: .86; font-weight: 800; }
.result-strip.result-passed {
  color: var(--green);
  border-color: rgba(100,255,210,.22);
  background: rgba(100,255,210,.07);
}
.result-strip.result-failed {
  color: var(--danger);
  border-color: rgba(255,93,125,.24);
  background: rgba(255,93,125,.08);
}
.badge.result-passed { color: var(--green); background: rgba(100,255,210,.08); border-color: rgba(100,255,210,.20); }
.badge.result-failed { color: var(--danger); background: rgba(255,93,125,.08); border-color: rgba(255,93,125,.20); }
.badge.result-open { color: var(--amber); background: rgba(255,209,102,.08); border-color: rgba(255,209,102,.20); }
@media (max-width: 720px) {
  .mode-buttons { grid-template-columns: 1fr; }
  .review-grid { grid-template-columns: 1fr; }
  .portal-menu h1 { font-size: 42px; }
}
.backup-download {
  margin-top: 10px;
  opacity: .72;
  transform: scale(.98);
}

.save-state {
  display: inline-flex;
  align-items: center;
  min-height: 40px;
  padding: 0 12px;
  border-radius: 999px;
  border: 1px solid rgba(100,255,210,.22);
  background: rgba(100,255,210,.08);
  color: var(--green);
  font-weight: 900;
  letter-spacing: .02em;
}

/* v10: live beoordeling + leiding lock */
.lock-note {
  margin: 10px 0 12px;
  padding: 11px 13px;
  border-radius: 14px;
  border: 1px solid rgba(255, 209, 102, .22);
  background: rgba(255, 209, 102, .07);
  color: #ffd98a;
  font-size: .9rem;
  font-weight: 800;
}
.review-choice-btn:disabled {
  cursor: not-allowed;
  opacity: .62;
  transform: none !important;
  filter: grayscale(.35);
}
.review-choice-btn:disabled:hover { transform: none; }

/* v13: accounts + active link account grid */
.ticket-meta-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 8px;
  margin-top: 10px;
  color: var(--muted);
  font-size: .82rem;
}
.ticket-meta-grid span {
  min-width: 0;
  padding: 8px 10px;
  border-radius: 12px;
  border: 1px solid rgba(116,190,255,.10);
  background: rgba(0, 0, 0, .16);
  overflow-wrap: anywhere;
}
.ticket-meta-grid b {
  display: block;
  color: #dcefff;
  font-size: .68rem;
  text-transform: uppercase;
  letter-spacing: .08em;
  margin-bottom: 3px;
}
.account-meta-grid { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.account-card .item-title,
.ticket-card .item-title { letter-spacing: .01em; }

@media (max-width: 780px) {
  .ticket-meta-grid,
  .account-meta-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 460px) {
  .ticket-meta-grid,
  .account-meta-grid { grid-template-columns: 1fr; }
}

.account-summary {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
  margin: 12px 0 18px;
}
.account-summary span {
  border: 1px solid rgba(159, 211, 255, .16);
  background: rgba(4, 12, 22, .46);
  border-radius: 16px;
  padding: 12px 14px;
}
.account-summary b {
  display: block;
  color: rgba(231, 243, 255, .55);
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: .12em;
  margin-bottom: 6px;
}
.account-summary em {
  font-style: normal;
  color: #f4fbff;
  font-weight: 800;
}
.compact-form {
  max-width: 520px;
}
.success-line {
  color: #7dffbf !important;
}
@media (max-width: 720px) {
  .account-summary { grid-template-columns: 1fr; }
}


/* v18: account names */
.account-name-form {
  margin-bottom: 14px;
}
.account-edit-row {
  display: grid;
  grid-template-columns: minmax(160px, 1fr) auto;
  gap: 10px;
  margin: 12px 0;
}
.account-edit-row .field {
  min-height: 38px;
  padding: 10px 12px;
}
@media (max-width: 560px) {
  .account-edit-row { grid-template-columns: 1fr; }
}

/* KMar overzicht + doorgevoerde toetsen */
.kader-tools-card {
  margin-bottom: 18px;
  background:
    linear-gradient(135deg, rgba(31,115,255,.10), rgba(62,232,255,.045)),
    rgba(3, 12, 26, .72);
}
.kader-stats {
  display: grid;
  grid-template-columns: repeat(4, minmax(140px, 1fr));
  gap: 12px;
  margin: 12px 0 10px;
}
.kader-stat {
  padding: 14px;
  border-radius: 16px;
  border: 1px solid rgba(116,190,255,.13);
  background: rgba(2,8,18,.55);
}
.kader-stat b {
  display: block;
  font-size: 1.55rem;
  color: var(--cyan);
  line-height: 1;
  margin-bottom: 6px;
}
.kader-stat span {
  color: var(--muted);
  font-size: .78rem;
  font-weight: 900;
  text-transform: uppercase;
  letter-spacing: .08em;
}
.archive-section {
  margin-top: 22px;
  padding-top: 16px;
  border-top: 1px solid rgba(116,190,255,.12);
}
.archive-head { margin-bottom: 10px; }
.archive-head h4 { margin: 0; font-size: .95rem; color: var(--muted); text-transform: uppercase; letter-spacing: .10em; }
.compact-list { gap: 8px; }
.compact-submission {
  padding: 11px 12px;
  border-radius: 14px;
  opacity: .82;
  background: rgba(2, 8, 18, .46);
}
.compact-submission .item-top { margin-bottom: 8px; }
.compact-submission .item-title { font-size: .94rem; }
.compact-submission .item-sub { font-size: .78rem; }
.compact-submission .item-actions .ghost-btn { min-height: 32px; padding-inline: 10px; font-size: .76rem; }
.no-margin { margin: 0; }
@media (max-width: 920px) {
  .kader-stats { grid-template-columns: repeat(2, minmax(130px, 1fr)); }
}
@media (max-width: 520px) {
  .kader-stats { grid-template-columns: 1fr; }
}

/* v18: KMar stemronde per transcript */
.vote-box {
  display: grid;
  gap: 12px;
  margin-top: 18px;
  padding: 15px;
  border-radius: 18px;
  border: 1px solid rgba(116,190,255,.13);
  background:
    radial-gradient(circle at 18% 0%, rgba(62,232,255,.10), transparent 36%),
    rgba(2, 8, 18, .48);
}
.vote-box label {
  color: var(--muted);
  font-size: .82rem;
  font-weight: 950;
  text-transform: uppercase;
  letter-spacing: .10em;
}
.vote-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
}
.vote-counts {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  justify-content: flex-end;
}
.vote-counts span {
  display: inline-flex;
  min-height: 32px;
  align-items: center;
  padding: 6px 10px;
  border-radius: 999px;
  border: 1px solid rgba(116,190,255,.14);
  background: rgba(0,0,0,.18);
  color: var(--text);
  font-weight: 900;
  font-size: .82rem;
}
.vote-buttons {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}
.vote-choice {
  min-width: 126px;
  padding: 12px 16px;
  border-radius: 14px;
  border: 1px solid rgba(116,190,255,.14);
  background: rgba(2, 9, 20, .72);
  color: var(--text);
  font-weight: 950;
  cursor: pointer;
  transition: transform .18s ease, background .18s ease, border .18s ease, box-shadow .18s ease;
}
.vote-choice:hover { transform: translateY(-1px); }
.vote-choice.yes { color: var(--green); border-color: rgba(100,255,210,.24); }
.vote-choice.yes.active { background: rgba(100,255,210,.16); border-color: rgba(100,255,210,.70); box-shadow: 0 0 28px rgba(100,255,210,.12); }
.vote-choice.no { color: var(--danger); border-color: rgba(255,93,125,.28); }
.vote-choice.no.active { background: rgba(255,93,125,.16); border-color: rgba(255,93,125,.70); box-shadow: 0 0 28px rgba(255,93,125,.12); }
.vote-state:empty { display: none; }
.vote-list {
  display: grid;
  gap: 8px;
  margin-top: 2px;
}
.vote-entry {
  border: 1px solid rgba(116,190,255,.12);
  background: rgba(0,0,0,.17);
  border-radius: 14px;
  padding: 11px;
}
.vote-entry.yes { border-color: rgba(100,255,210,.18); }
.vote-entry.no { border-color: rgba(255,93,125,.20); }
.vote-entry-top {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
}
.vote-entry-top strong { color: var(--text); }
.vote-entry-top em, .vote-entry-top small {
  color: var(--muted);
  font-style: normal;
  font-size: .78rem;
}
.vote-mark {
  display: inline-grid;
  place-items: center;
  width: 26px;
  height: 26px;
  border-radius: 999px;
  border: 1px solid rgba(255,255,255,.12);
  background: rgba(0,0,0,.18);
  font-weight: 950;
}
.vote-entry.yes .vote-mark { color: var(--green); border-color: rgba(100,255,210,.28); }
.vote-entry.no .vote-mark { color: var(--danger); border-color: rgba(255,93,125,.30); }
.vote-entry p {
  margin: 8px 0 0;
  color: var(--muted);
  white-space: pre-wrap;
  line-height: 1.45;
}
.vote-empty { padding: 10px; }
@media (max-width: 720px) {
  .vote-head { flex-direction: column; }
  .vote-counts { justify-content: flex-start; }
  .vote-choice { flex: 1; min-width: 0; }
}


/* vote-only decision system */
.vote-decision-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}
.vote-decision-card {
  border: 1px solid rgba(116,190,255,.13);
  background: rgba(0,0,0,.16);
  border-radius: 16px;
  padding: 13px;
  min-height: 130px;
}
.vote-decision-card.yes { border-color: rgba(100,255,210,.22); }
.vote-decision-card.no { border-color: rgba(255,93,125,.25); }
.vote-decision-card h4 {
  margin: 0 0 6px;
  color: var(--muted);
  text-transform: uppercase;
  letter-spacing: .10em;
  font-size: .76rem;
}
.vote-decision-count {
  font-size: 2rem;
  line-height: 1;
  font-weight: 1000;
  margin-bottom: 10px;
}
.vote-decision-card.yes .vote-decision-count { color: var(--green); }
.vote-decision-card.no .vote-decision-count { color: var(--danger); }
.vote-mini, .vote-own-card {
  display: grid;
  gap: 8px;
  border: 1px solid rgba(116,190,255,.10);
  background: rgba(3,9,18,.46);
  border-radius: 13px;
  padding: 10px;
}
.vote-mini {
  grid-template-columns: 26px 1fr;
  align-items: flex-start;
  margin-top: 8px;
}
.vote-mini-mark {
  display: inline-grid;
  place-items: center;
  width: 24px;
  height: 24px;
  border-radius: 999px;
  border: 1px solid rgba(255,255,255,.12);
  font-weight: 1000;
}
.vote-mini.yes .vote-mini-mark { color: var(--green); border-color: rgba(100,255,210,.28); }
.vote-mini.no .vote-mini-mark { color: var(--danger); border-color: rgba(255,93,125,.30); }
.vote-mini strong { display: block; }
.vote-mini small { display: block; color: var(--muted); font-size: .76rem; margin-top: 2px; }
.vote-mini p { margin: 7px 0 0; color: var(--muted); white-space: pre-wrap; }
.vote-mini-empty { color: var(--muted); font-size: .82rem; padding: 8px 0; }
.vote-own-card { margin-top: 2px; }
@media (max-width: 720px) {
  .vote-decision-grid { grid-template-columns: 1fr; }
}

/* v24: Discord puntentelling zonder website-nakijken */
.points-pill{
  display:inline-flex;
  margin-left:8px;
  padding:4px 8px;
  border-radius:999px;
  border:1px solid rgba(67,223,255,.25);
  background:rgba(67,223,255,.08);
  color:#72e6ff;
  font-size:11px;
  font-weight:800;
  vertical-align:middle;
}
.answer-block h5{
  margin:14px 0 7px;
  color:rgba(196,222,246,.78);
  font-size:11px;
  text-transform:uppercase;
  letter-spacing:.09em;
}
.answer-text.answer-key{
  border-color:rgba(112,255,211,.22);
  background:rgba(4,19,22,.55);
}
