:root {
  --hud-blue: #00f3ff;
  --hud-alert: #ff003c;
  --hud-amber: #ffae00;
  --hud-magenta: #ff00aa;
  --hud-opacity: 0.8;
  --hud-glow-alpha: 0.8;
  --hud-chroma-alpha: 0.85;
  --eye-blur: 0px;

  --csat-paper: #f4f1ea;
  --csat-ink: #111111;
  --omr-pink: #d9534f;
  --omr-pink-soft: #fdf2f2;
  --omr-grid-border: #e48c89;
}

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

html,
body {
  width: 100%;
  height: 100%;
  overflow: hidden;
  user-select: none;
  background-color: #16181d;
  font-family: 'Noto Sans KR', sans-serif;
  color: #111;
}

/* =========================================================
   Main 3-Part 1st-Person Layout
   ========================================================= */
#game-viewport {
  width: 100vw;
  height: 100vh;
  display: flex;
  flex-direction: column;
  overflow: hidden;
}

/* =========================================================
   TOP (32%): Classroom & Proctor
   ========================================================= */
#classroom-section {
  position: relative;
  width: 100%;
  height: 32vh;
  min-height: 200px;
  display: flex;
  flex-direction: column;
  background: linear-gradient(180deg, #cfd6dc 0%, #bfc7ce 78%, #9aa3ab 100%);
  overflow: hidden;
  flex-shrink: 0;
}

.classroom-wall {
  position: relative;
  flex: 1;
  display: flex;
  align-items: flex-end;
  justify-content: center;
  padding: 10px 260px 0;
}

/* Ambient Classroom Windows */
.classroom-window {
  position: absolute;
  top: 12px;
  width: 130px;
  height: 76%;
  background: linear-gradient(180deg, #e7f3fb 0%, #cde2f0 100%);
  border: 4px solid #7c6855;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 4px;
  padding: 4px;
  opacity: 0.72;
  box-shadow: inset 0 0 18px rgba(255, 255, 255, 0.8);
}

.classroom-window-left {
  left: 36px;
}

.classroom-window-right {
  right: 36px;
}

.window-pane {
  border: 1px solid rgba(124, 104, 85, 0.5);
  background: linear-gradient(135deg, rgba(255, 255, 255, 0.55), rgba(185, 219, 240, 0.3));
}

/* Chalkboard */
#chalkboard {
  position: relative;
  width: clamp(360px, 46vw, 620px);
  height: 88%;
  margin-bottom: 6px;
  background: radial-gradient(circle at 35% 35%, #234937 0%, #193729 65%, #12291e 100%);
  border: 6px solid #754c29;
  border-radius: 4px;
  box-shadow:
    inset 0 0 24px rgba(0, 0, 0, 0.45),
    0 6px 14px rgba(0, 0, 0, 0.25);
  padding: 10px 18px 14px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  color: rgba(245, 245, 240, 0.92);
  z-index: 2;
}

.chalkboard-top-bar {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  border-bottom: 1px dashed rgba(255, 255, 255, 0.28);
  padding-bottom: 4px;
  padding-right: 175px; /* Keep clear of proctor silhouette on right */
  gap: 2px;
}

.chalk-label {
  font-size: clamp(12px, 1.15vw, 15px);
  font-weight: 700;
  letter-spacing: 0.03em;
}

.chalk-sub {
  font-size: clamp(11px, 0.95vw, 13px);
  color: #fde68a;
}

.chalkboard-main {
  display: flex;
  align-items: center;
  justify-content: flex-start;
  gap: 18px;
  padding-right: 110px; /* Keep space clear on right for proctor silhouette */
}

.timer-box {
  display: flex;
  flex-direction: column;
  gap: 2px;
  background: rgba(0, 0, 0, 0.22);
  border: 1px solid rgba(255, 255, 255, 0.22);
  border-radius: 4px;
  padding: 5px 12px;
}

.timer-caption {
  font-size: 11px;
  color: rgba(255, 255, 255, 0.72);
}

#timer-display {
  font-family: 'Share Tech Mono', monospace;
  font-size: clamp(18px, 2vw, 26px);
  font-weight: 700;
  color: #fff8dc;
  letter-spacing: 0.04em;
}

#timer-display.timer-urgent {
  color: #ff6b6b;
}

.chalk-notes {
  display: flex;
  flex-direction: column;
  gap: 3px;
  font-size: clamp(10px, 0.85vw, 12px);
  color: rgba(255, 255, 255, 0.76);
}

.chalk-tray {
  position: absolute;
  bottom: -6px;
  left: 16px;
  right: 16px;
  height: 8px;
  background: #5b3a1d;
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 0 14px;
}

.chalk-stick {
  width: 18px;
  height: 4px;
  border-radius: 2px;
  background: #f5f5f5;
  transform: translateY(-4px);
}

.chalk-stick.yellow {
  background: #fde047;
}

.chalk-eraser {
  width: 28px;
  height: 7px;
  border-radius: 1px;
  background: #2f2f2f;
  border-top: 3px solid #9e6b3f;
  transform: translateY(-5px);
}

/* Proctor SVG Stage */
#proctor-stage {
  position: absolute;
  bottom: 0;
  left: 58%;
  transform: translateX(-50%);
  width: clamp(160px, 15.5vw, 220px);
  height: 86%;
  z-index: 4;
  pointer-events: none;
  display: flex;
  align-items: flex-end;
  justify-content: center;
}

#proctor-mover {
  position: relative;
  width: 100%;
  height: 100%;
  display: flex;
  align-items: flex-end;
  justify-content: center;
}

#proctor-svg {
  width: 100%;
  height: 100%;
  overflow: visible;
  filter: drop-shadow(0 6px 10px rgba(0, 0, 0, 0.35));
}

#proctor-vision-cone {
  transition: opacity 0.2s ease, filter 0.2s ease;
}

#proctor-vision-cone.watching {
  filter: drop-shadow(0 0 12px rgba(255, 0, 60, 0.75));
}

#proctor-alert-badge {
  position: absolute;
  top: -22px;
  left: 50%;
  transform: translateX(-50%);
  padding: 2px 10px;
  border-radius: 999px;
  font-family: 'Black Han Sans', 'Noto Sans KR', sans-serif;
  font-size: 20px;
  line-height: 1.1;
  letter-spacing: 0.04em;
  z-index: 15;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.35);
  pointer-events: none;
  white-space: nowrap;
}

#proctor-alert-badge.badge-question {
  background: #ffd600;
  color: #111111;
  border: 2px solid #111111;
}

#proctor-alert-badge.badge-danger {
  background: #ff003c;
  color: #ffffff;
  border: 2px solid #ffffff;
  box-shadow: 0 0 16px rgba(255, 0, 60, 0.85);
}

#proctor-speech-bubble {
  position: absolute;
  top: 14px;
  right: calc(100% - 16px);
  min-width: 190px;
  max-width: 260px;
  padding: 7px 11px;
  background: #ffffff;
  color: #111111;
  border: 2px solid #111111;
  border-radius: 8px;
  font-family: 'Noto Sans KR', sans-serif;
  font-size: 11.5px;
  font-weight: 800;
  text-align: center;
  line-height: 1.35;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.28);
  z-index: 16;
  pointer-events: none;
}

#proctor-speech-bubble.angry {
  background: #ff003c;
  color: #ffffff;
  border-color: #ffffff;
}

.podium-ledge {
  height: 10px;
  width: 100%;
  background: linear-gradient(180deg, #6e4e32 0%, #4b331f 100%);
  border-top: 2px solid #8a6443;
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.35);
  z-index: 5;
}

/* =========================================================
   BOTTOM (68%): Desk Area (72% Exam Paper + 28% OMR Card)
   ========================================================= */
#desk-section {
  width: 100%;
  height: 68vh;
  display: flex;
  background: linear-gradient(135deg, #b88c5e 0%, #9b7044 52%, #855e36 100%);
  box-shadow: inset 0 12px 24px rgba(0, 0, 0, 0.25);
  overflow: hidden;
}

/* Bottom-Left (72%): Korean CSAT Exam Paper (Zero Dead Space 2-Column Layout) */
#exam-paper-container {
  width: 72%;
  height: 100%;
  padding: 5px 8px 5px 12px;
  display: flex;
}

#exam-paper {
  width: 100%;
  height: 100%;
  background-color: var(--csat-paper);
  background-image:
    radial-gradient(rgba(0, 0, 0, 0.03) 1px, transparent 0),
    linear-gradient(90deg, rgba(0, 0, 0, 0.015) 50%, transparent 50%);
  background-size: 16px 16px, 4px 100%;
  color: var(--csat-ink);
  font-family: 'Nanum Myeongjo', serif;
  padding: 4px 12px 4px;
  border: 1px solid #cfc9bc;
  box-shadow:
    3px 5px 14px rgba(0, 0, 0, 0.3),
    inset 0 0 28px rgba(170, 155, 125, 0.16);
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  gap: 2px;
  position: relative;
  overflow: hidden;
  filter: blur(var(--eye-blur));
  transition: filter 0.16s ease;
}

/* Heat Distortion Filter >= 70% combined with Eye Blur */
#exam-paper.heat-active {
  filter: url(#heat-distortion) blur(var(--eye-blur));
}

.csat-header {
  flex-shrink: 0;
}

.csat-double-box {
  border-top: 3.5px solid #111;
  border-bottom: 1.5px solid #111;
  padding: 2px 6px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  position: relative;
}

.csat-badge {
  font-size: 13px;
  font-weight: 900;
  border: 1.5px solid #111;
  padding: 2px 7px;
  white-space: nowrap;
}

.csat-title-stack {
  flex: 1;
  min-width: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  flex-wrap: wrap;
}

.csat-title {
  font-size: clamp(15px, 1.35vw, 18.5px);
  font-weight: 900;
  letter-spacing: -0.02em;
  text-align: center;
}

.csat-examinee-strip {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-family: 'Noto Sans KR', sans-serif;
  font-size: 13.5px;
  font-weight: 700;
  background: rgba(17, 17, 17, 0.06);
  border: 1px solid #444;
  padding: 1px 8px;
  border-radius: 2px;
  white-space: nowrap;
}

.csat-examinee-strip strong {
  color: #111;
  font-weight: 900;
}

.csat-page-num {
  font-size: 14px;
  font-weight: 900;
  white-space: nowrap;
}

/* 2-Column CSAT Grid (Left 1~3 / Right 4~5 per page) */
#exam-paper-grid {
  flex: 1;
  min-height: 0;
  display: grid;
  grid-template-columns: 1fr 1fr;
  border-top: 1.5px solid #222;
  border-bottom: 1.5px solid #222;
  overflow: hidden;
}

.exam-paper-col {
  min-height: 0;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  gap: 1px;
  overflow-y: auto;
}

#exam-col-left {
  border-right: 1px solid #222;
  padding: 2px 8px 2px 2px;
}

#exam-col-right {
  padding: 2px 2px 2px 8px;
  gap: 4px;
}

.csat-q-block {
  flex: 1 0 auto;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  gap: 1px;
  padding: 1px 5px;
  border-bottom: 1px dashed #a8a092;
  cursor: crosshair;
  position: relative;
  border-radius: 2px;
  transition: background-color 0.14s ease, box-shadow 0.14s ease;
}

.csat-q-block:last-child {
  border-bottom: none;
}

.csat-q-block:hover {
  background: rgba(0, 168, 181, 0.05);
}

.csat-q-block.active-q {
  background: rgba(0, 168, 181, 0.08);
  box-shadow: inset 3px 0 0 #008b99;
}

.csat-q-block.scanning-active {
  background: rgba(0, 243, 255, 0.13);
  box-shadow:
    inset 0 0 16px rgba(0, 243, 255, 0.25),
    0 0 8px rgba(0, 180, 216, 0.28);
}

.csat-q-title-line {
  font-size: 15px;
  font-weight: 800;
  line-height: 1.12;
  color: #111;
}

.csat-q-num {
  font-size: 16px;
  font-weight: 900;
  margin-right: 4px;
}

.csat-q-pts {
  display: inline-block;
  font-size: 12px;
  font-weight: 800;
  border: 1px solid #222;
  background: rgba(255, 255, 255, 0.55);
  padding: 0 4px;
  margin-left: 4px;
  vertical-align: baseline;
}

.csat-q-subj {
  font-family: 'Noto Sans KR', sans-serif;
  font-size: 12px;
  font-weight: 700;
  color: #444;
  margin-left: 4px;
}

.csat-q-scan-badge {
  font-family: 'Share Tech Mono', 'Noto Sans KR', monospace;
  font-size: 12px;
  font-weight: 800;
  color: #0369a1;
  background: rgba(0, 243, 255, 0.14);
  border: 1px solid #0284c7;
  padding: 0 5px;
  border-radius: 2px;
  margin-left: 4px;
}

.csat-q-passage {
  background: rgba(255, 255, 255, 0.5);
  border: 1px solid #2b2b2b;
  padding: 1px 6px;
  font-size: 15px;
  line-height: 1.14;
  color: #151515;
  text-align: justify;
}

.csat-q-bogi {
  background: rgba(255, 255, 255, 0.34);
  border: 1px solid #444;
  padding: 1px 6px;
  font-size: 15px;
  line-height: 1.13;
  color: #151515;
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 0px 8px;
}

.bogi-tag {
  font-weight: 900;
  font-size: 13.5px;
  letter-spacing: 0.04em;
  color: #111;
  margin-right: 2px;
}

.bogi-item {
  font-weight: 600;
}

.csat-q-options {
  list-style: none;
  display: flex;
  flex-wrap: wrap;
  gap: 0px 8px;
  margin: 0;
  padding: 0;
}

.exam-option-item {
  font-size: 15px;
  font-weight: 700;
  line-height: 1.12;
  padding: 0px 4px;
  border-radius: 3px;
  cursor: pointer;
  border: 1px solid transparent;
  transition: background-color 0.12s ease;
}

.exam-option-item:hover {
  background-color: rgba(0, 0, 0, 0.08);
}

.exam-option-item.selected-on-paper {
  background-color: rgba(17, 17, 17, 0.14);
  border-color: #111;
  font-weight: 900;
}

.csat-q-scan-bar {
  position: absolute;
  left: 6px;
  right: 6px;
  bottom: 2px;
  height: 4px;
  background: rgba(0, 243, 255, 0.18);
  border-radius: 2px;
  overflow: hidden;
  pointer-events: none;
}

.csat-q-scan-bar.hidden {
  display: none;
}

.csat-q-scan-fill {
  height: 100%;
  width: 0%;
  background: linear-gradient(90deg, #0284c7, #00f3ff);
  box-shadow: 0 0 6px #00f3ff;
}

.exam-footer {
  flex-shrink: 0;
  padding-top: 2px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

.exam-footer-center {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1px;
}

.exam-footer-meta-row {
  display: flex;
  align-items: center;
  gap: 8px;
}

.blink-pill-btn {
  font-family: 'Noto Sans KR', sans-serif;
  font-size: 12.5px;
  font-weight: 800;
  padding: 2px 9px;
  border: 1px solid #333;
  border-radius: 999px;
  background: rgba(17, 17, 17, 0.08);
  color: #111;
  cursor: pointer;
  transition: background-color 0.15s ease, color 0.15s ease, border-color 0.15s ease;
}

.blink-pill-btn:hover {
  background: #111;
  color: #f4f1ea;
}

.blink-pill-btn.blink-urgent {
  background: #ff003c;
  color: #ffffff;
  border-color: #9e0025;
  box-shadow: 0 0 8px rgba(255, 0, 60, 0.5);
}

#question-progress {
  font-family: 'Noto Sans KR', sans-serif;
  font-size: 14px;
  font-weight: 900;
}

.csat-copyright {
  font-family: 'Noto Sans KR', sans-serif;
  font-size: 11px;
  color: #444;
  font-weight: 700;
}

.exam-nav-btn {
  font-family: 'Noto Sans KR', sans-serif;
  font-size: 15.5px;
  font-weight: 900;
  padding: 6px 14px;
  border: 2px solid #222;
  background: #ece7dc;
  color: #111;
  cursor: pointer;
  border-radius: 3px;
  white-space: nowrap;
  transition: background-color 0.15s ease, color 0.15s ease;
}

.exam-nav-btn:hover:not(.active-page) {
  background: #d8d0c0;
}

.exam-nav-btn.active-page {
  background: #111;
  color: #f4f1ea;
}

/* Bottom-Right (28%): Pink/Red CSAT OMR Card */
#omr-card-container {
  width: 28%;
  height: 100%;
  padding: 12px 16px 12px 6px;
  display: flex;
}

#omr-card {
  width: 100%;
  height: 100%;
  background: #ffffff;
  border: 2px solid var(--omr-pink);
  border-radius: 3px;
  box-shadow: 3px 5px 14px rgba(0, 0, 0, 0.3);
  padding: 8px 10px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  overflow: hidden;
}

.omr-header {
  flex-shrink: 0;
  border-bottom: 2px solid var(--omr-pink);
  padding-bottom: 5px;
  margin-bottom: 4px;
}

.omr-title-row {
  display: flex;
  align-items: center;
  gap: 6px;
  margin-bottom: 3px;
}

.omr-tag {
  background: var(--omr-pink);
  color: #fff;
  font-size: 10px;
  font-weight: 900;
  padding: 1px 5px;
  border-radius: 2px;
}

.omr-title {
  font-size: clamp(12px, 1.05vw, 14px);
  font-weight: 900;
  color: #b5322e;
}

.omr-info-strip {
  display: flex;
  justify-content: space-between;
  font-size: 10.5px;
  color: #a94442;
  font-weight: 700;
}

.omr-table-header {
  flex-shrink: 0;
  display: grid;
  grid-template-columns: 42px repeat(5, 1fr);
  align-items: center;
  text-align: center;
  background: var(--omr-pink-soft);
  border: 1px solid var(--omr-pink);
  border-bottom: none;
  font-size: 11px;
  font-weight: 800;
  color: #b5322e;
  height: 22px;
}

#omr-grid {
  flex: 1;
  min-height: 0;
  display: grid;
  grid-template-rows: repeat(10, 1fr);
  border: 1px solid var(--omr-pink);
}

.omr-row {
  display: grid;
  grid-template-columns: 42px repeat(5, 1fr);
  align-items: center;
  border-bottom: 1px solid var(--omr-grid-border);
  transition: background-color 0.15s ease;
}

.omr-row:last-child {
  border-bottom: none;
}

.omr-row.active-row {
  background-color: rgba(217, 83, 79, 0.1);
}

.omr-q-num {
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 11.5px;
  font-weight: 800;
  color: #b5322e;
  border-right: 1px solid var(--omr-grid-border);
  background: var(--omr-pink-soft);
  cursor: pointer;
}

.omr-cell {
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  border-right: 1px dashed rgba(217, 83, 79, 0.32);
}

.omr-cell:last-child {
  border-right: none;
}

.omr-bubble {
  width: 14px;
  height: 20px;
  max-height: 76%;
  border: 1.5px solid var(--omr-pink);
  border-radius: 50%;
  background: #fff;
  color: #b5322e;
  font-size: 9.5px;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: transform 0.1s ease, border-color 0.12s ease;
}

.omr-bubble:hover {
  transform: scale(1.1);
  border-color: #111;
}

.omr-bubble.marked {
  background: #141414;
  border-color: #141414;
  color: #141414; /* Filled black computer-sign-pen oval */
  box-shadow: inset 0 0 2px rgba(255, 255, 255, 0.2);
}

.omr-footer {
  flex-shrink: 0;
  padding-top: 6px;
  display: flex;
  flex-direction: column;
  gap: 5px;
}

.omr-warning-note {
  font-size: 9.5px;
  color: #b5322e;
  text-align: center;
  font-weight: 500;
}

#btn-submit-omr {
  width: 100%;
  padding: 8px 10px;
  background: var(--omr-pink);
  color: #ffffff;
  border: none;
  border-radius: 3px;
  font-family: 'Noto Sans KR', sans-serif;
  font-size: 13.5px;
  font-weight: 800;
  cursor: pointer;
  letter-spacing: 0.04em;
  box-shadow: 0 2px 0 #9f2d2a;
  transition: background-color 0.15s ease, transform 0.1s ease;
}

#btn-submit-omr:hover {
  background: #c13935;
}

#btn-submit-omr:active {
  transform: translateY(1px);
}

#btn-submit-omr.submitted {
  background: #2f7a4f;
  box-shadow: 0 2px 0 #1f5335;
}

/* =========================================================
   FRONT OVERLAY: AR Smart Glasses HUD (pointer-events: none)
   ========================================================= */
#glasses-off-indicator {
  position: fixed;
  top: 10px;
  right: 14px;
  z-index: 95;
  pointer-events: none;
  font-family: 'Share Tech Mono', 'Noto Sans KR', monospace;
  font-size: 11px;
  padding: 5px 10px;
  border-radius: 3px;
  background: rgba(15, 18, 22, 0.72);
  border: 1px solid rgba(150, 160, 175, 0.45);
  color: #a8b3c2;
  opacity: 0;
  transition: opacity 0.2s ease;
}

#glasses-off-indicator.visible {
  opacity: 1;
}

#ar-hud {
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 100;
  font-family: 'Share Tech Mono', 'Noto Sans KR', monospace;
  color: var(--hud-blue);
  opacity: var(--hud-opacity);
  text-shadow:
    -1px 0 rgba(255, 0, 85, var(--hud-chroma-alpha)),
    1px 0 rgba(0, 243, 255, var(--hud-chroma-alpha)),
    0 0 calc(8px * var(--hud-glow-alpha)) rgba(0, 243, 255, var(--hud-glow-alpha));
  transition: opacity 0.12s linear;
}

#ar-hud.hud-alert {
  color: var(--hud-alert);
  text-shadow:
    -1px 0 rgba(255, 0, 60, var(--hud-chroma-alpha)),
    1px 0 rgba(0, 243, 255, var(--hud-chroma-alpha)),
    0 0 calc(10px * var(--hud-glow-alpha)) rgba(255, 0, 60, var(--hud-glow-alpha));
}

#ar-hud.hud-glitch {
  filter: url(#glitch-filter);
}

/* Required Scanline Overlay */
#hud-scanlines {
  position: absolute;
  inset: 0;
  pointer-events: none;
  background: repeating-linear-gradient(
    0deg,
    rgba(0, 243, 255, 0.04) 0px,
    rgba(0, 243, 255, 0.04) 1px,
    transparent 1px,
    transparent 3px
  );
}

.hud-lens-vignette {
  position: absolute;
  inset: 0;
  pointer-events: none;
  background: radial-gradient(
    ellipse at center,
    transparent 62%,
    rgba(0, 243, 255, 0.06) 88%,
    rgba(0, 18, 30, 0.22) 100%
  );
}

/* AR Lens Corner Brackets */
.hud-corner {
  position: absolute;
  width: 24px;
  height: 24px;
  border-color: rgba(0, 243, 255, 0.65);
  border-style: solid;
  pointer-events: none;
}

.hud-corner-tl {
  top: 8px;
  left: 8px;
  border-width: 2px 0 0 2px;
}

.hud-corner-tr {
  top: 8px;
  right: 8px;
  border-width: 2px 2px 0 0;
}

.hud-corner-bl {
  bottom: 8px;
  left: 8px;
  border-width: 0 0 2px 2px;
}

.hud-corner-br {
  bottom: 8px;
  right: 8px;
  border-width: 0 2px 2px 0;
}

/* Shared HUD Panel Box */
.hud-panel {
  position: absolute;
  background: rgba(4, 16, 26, 0.86);
  border: 1px solid rgba(0, 243, 255, 0.65);
  box-shadow:
    inset 0 0 12px rgba(0, 243, 255, 0.14),
    0 0 10px rgba(0, 243, 255, 0.18);
  backdrop-filter: blur(3px);
  border-radius: 3px;
  pointer-events: none;
}

.hud-panel-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  padding: 4px 8px;
  font-size: 11px;
  letter-spacing: 0.06em;
  border-bottom: 1px solid rgba(0, 243, 255, 0.35);
  background: rgba(0, 243, 255, 0.08);
}

.hud-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--hud-blue);
  box-shadow: 0 0 6px var(--hud-blue);
  display: inline-block;
  margin-right: 4px;
}

/* Top-Left AI Computation Output Window */
#hud-ai-panel {
  top: 12px;
  left: 14px;
  width: 252px;
}

#hud-ai-panel .hud-panel-header {
  justify-content: flex-start;
}

.hud-panel-body {
  padding: 6px 9px;
}

.hud-ai-meta {
  display: flex;
  justify-content: space-between;
  font-size: 10.5px;
  margin-bottom: 5px;
  opacity: 0.9;
}

#hud-ai-log {
  font-size: 10.5px;
  line-height: 1.38;
  min-height: 54px;
  max-height: 112px;
  overflow: hidden;
  word-break: keep-all;
}

/* Top-Right Telemetry & Brightness Panel */
#hud-status-panel {
  top: 10px;
  right: 14px;
  width: 238px;
}

#hud-power-badge {
  font-size: 10px;
  padding: 1px 5px;
  border: 1px solid currentColor;
  border-radius: 2px;
}

.hud-gauges {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.gauge-row {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.gauge-label {
  display: flex;
  justify-content: space-between;
  font-size: 10.5px;
  line-height: 1.1;
}

.gauge-track {
  width: 100%;
  height: 6px;
  background: rgba(0, 243, 255, 0.14);
  border: 1px solid rgba(0, 243, 255, 0.35);
  overflow: hidden;
}

.gauge-fill {
  height: 100%;
  transition: width 0.2s ease;
}

.fill-cyan {
  background: var(--hud-blue);
  box-shadow: 0 0 6px var(--hud-blue);
}

.fill-amber {
  background: var(--hud-amber);
  box-shadow: 0 0 6px var(--hud-amber);
}

.fill-red {
  background: var(--hud-alert);
  box-shadow: 0 0 6px var(--hud-alert);
}

.fill-magenta {
  background: var(--hud-magenta);
  box-shadow: 0 0 6px var(--hud-magenta);
}

.hud-brightness-row {
  margin-top: 3px;
  padding-top: 4px;
  border-top: 1px dashed rgba(0, 243, 255, 0.35);
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 11px;
  font-weight: 700;
}

/* Hide native cursor on CSAT Exam Paper so the AR Smart Lens becomes the pointer */
#exam-paper,
#exam-paper-grid,
#exam-paper .csat-q-block,
#exam-paper .csat-q-passage,
#exam-paper .csat-q-bogi {
  cursor: none;
}

/* Mouse-Following Horizontal AR Smart Glasses Lens Viewfinder (320x160) */
#hud-reticle {
  position: fixed;
  top: 0;
  left: 0;
  width: 320px;
  height: 160px;
  margin-left: -160px;
  margin-top: -80px;
  pointer-events: none;
  z-index: 125;
  will-change: transform;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  padding: 7px 10px;
  border-radius: 6px;
  overflow: hidden;
  border: 1.5px solid rgba(0, 243, 255, 0.78);
  box-shadow:
    0 0 22px rgba(0, 243, 255, 0.28),
    inset 0 0 18px rgba(0, 243, 255, 0.18);
  transition: opacity 0.16s ease, border-color 0.18s ease, box-shadow 0.18s ease;
}

#hud-reticle[data-state="scanning"] {
  border-color: #00f3ff;
  box-shadow:
    0 0 28px rgba(0, 243, 255, 0.48),
    inset 0 0 22px rgba(0, 243, 255, 0.28);
}

#hud-reticle[data-state="complete"] {
  border-color: #4ade80;
  box-shadow:
    0 0 26px rgba(74, 222, 128, 0.42),
    inset 0 0 20px rgba(0, 243, 255, 0.24);
}

#hud-reticle[data-state="off"] {
  border-color: rgba(148, 163, 184, 0.45);
  box-shadow: none;
  opacity: 0.4;
}

#hud-reticle.over-omr {
  opacity: 0.35;
}

.lens-glass-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(3, 15, 26, 0.8);
  backdrop-filter: blur(1.5px);
  z-index: 0;
}

.lens-scanlines {
  position: absolute;
  inset: 0;
  z-index: 1;
  background: repeating-linear-gradient(
    0deg,
    rgba(0, 243, 255, 0.09) 0px,
    rgba(0, 243, 255, 0.09) 1px,
    transparent 1px,
    transparent 3px
  );
  pointer-events: none;
}

.lens-laser-sweep {
  position: absolute;
  left: 0;
  right: 0;
  height: 18px;
  z-index: 2;
  background: linear-gradient(180deg, transparent, rgba(0, 243, 255, 0.38), transparent);
  opacity: 0;
  pointer-events: none;
}

#hud-reticle[data-state="scanning"] .lens-laser-sweep {
  opacity: 1;
  animation: lensSweepY 0.9s linear infinite;
}

@keyframes lensSweepY {
  0% {
    top: -18px;
  }
  100% {
    top: 160px;
  }
}

.lens-bracket {
  position: absolute;
  width: 14px;
  height: 14px;
  border-color: #00f3ff;
  border-style: solid;
  z-index: 3;
}

.lens-bracket.tl {
  top: 2px;
  left: 2px;
  border-width: 2.5px 0 0 2.5px;
}

.lens-bracket.tr {
  top: 2px;
  right: 2px;
  border-width: 2.5px 2.5px 0 0;
}

.lens-bracket.bl {
  bottom: 2px;
  left: 2px;
  border-width: 0 0 2.5px 2.5px;
}

.lens-bracket.br {
  bottom: 2px;
  right: 2px;
  border-width: 0 2.5px 2.5px 0;
}

.lens-top-bar {
  position: relative;
  z-index: 4;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 6px;
  font-size: 11px;
  font-weight: 800;
  color: #00f3ff;
  letter-spacing: 0.04em;
}

#lens-target-tag {
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.lens-meta-right {
  display: flex;
  align-items: center;
  gap: 6px;
  flex-shrink: 0;
}

#lens-dwell-pct {
  color: #fde047;
  font-weight: 900;
}

.reticle-coords {
  font-size: 10px;
  color: #93c5fd;
  background: rgba(4, 18, 28, 0.72);
  padding: 0 4px;
  border: 1px solid rgba(0, 243, 255, 0.35);
  border-radius: 2px;
  white-space: nowrap;
}

#lens-dwell-track {
  position: relative;
  z-index: 4;
  width: 100%;
  height: 5px;
  background: rgba(0, 243, 255, 0.16);
  border: 1px solid rgba(0, 243, 255, 0.45);
  border-radius: 2px;
  overflow: hidden;
}

#lens-dwell-fill {
  height: 100%;
  width: 0%;
  background: linear-gradient(90deg, #00c4ff 0%, #00f3ff 60%, #4ade80 100%);
  box-shadow: 0 0 10px #00f3ff;
}

#lens-stream-body {
  position: relative;
  z-index: 4;
  flex: 1;
  min-height: 0;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  gap: 3px;
  padding-top: 3px;
}

.lens-line-ocr {
  font-size: 11px;
  line-height: 1.2;
  color: #fde047;
  font-weight: 700;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.lens-line-comment {
  font-size: 11.5px;
  line-height: 1.24;
  color: #e0f2fe;
  min-height: 29px;
  max-height: 30px;
  overflow: hidden;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
}

.lens-answer-box {
  padding: 3px 8px;
  background: rgba(0, 243, 255, 0.22);
  border: 1.5px solid #00f3ff;
  border-radius: 4px;
  color: #ffffff;
  font-size: 14.5px;
  font-weight: 900;
  text-align: center;
  letter-spacing: 0.03em;
  text-shadow: 0 0 10px #00f3ff;
  box-shadow: 0 0 14px rgba(0, 243, 255, 0.42);
}

#hud-reticle[data-state="complete"] .lens-answer-box {
  border-color: #4ade80;
  background: rgba(22, 163, 74, 0.28);
  box-shadow: 0 0 16px rgba(74, 222, 128, 0.45);
}

/* =========================================================
   Utility & Proctor/Bluff/GameOver Overlays
   ========================================================= */
.hidden {
  display: none !important;
}

#hud-warning-banner {
  position: absolute;
  top: 6px;
  left: 50%;
  transform: translateX(-50%);
  padding: 4px 12px;
  background: rgba(255, 0, 60, 0.92);
  color: #ffffff;
  border: 1.5px solid #ffffff;
  border-radius: 3px;
  font-family: 'Noto Sans KR', sans-serif;
  font-size: 11.5px;
  font-weight: 900;
  letter-spacing: 0.03em;
  box-shadow: 0 0 18px rgba(255, 0, 60, 0.75);
  z-index: 115;
  white-space: nowrap;
}

#bluff-skill-container {
  position: fixed;
  bottom: 58px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 140;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 5px;
  max-width: 90vw;
}

#bluff-readiness-hint {
  background: rgba(12, 16, 24, 0.9);
  color: #fde047;
  border: 1px solid #ffd600;
  padding: 3px 10px;
  border-radius: 999px;
  font-size: 11px;
  font-weight: 700;
  box-shadow: 0 3px 10px rgba(0, 0, 0, 0.4);
}

#bluff-readiness-hint.ready-safe {
  color: #4ade80;
  border-color: #22c55e;
}

#btn-bluff-skill {
  padding: 12px 22px;
  background: linear-gradient(135deg, #ff003c 0%, #c8002f 100%);
  color: #ffffff;
  border: 3px solid #ffd600;
  border-radius: 6px;
  font-family: 'Noto Sans KR', sans-serif;
  font-size: clamp(13px, 1.25vw, 16px);
  font-weight: 900;
  cursor: pointer;
  box-shadow:
    0 6px 22px rgba(255, 0, 60, 0.55),
    0 0 14px rgba(255, 214, 0, 0.6);
  transition: transform 0.12s ease, filter 0.15s ease;
}

#btn-bluff-skill:hover {
  transform: scale(1.03);
  filter: brightness(1.08);
}

#btn-bluff-skill:active {
  transform: scale(0.98);
}

#gameover-overlay {
  position: fixed;
  inset: 0;
  z-index: 200;
  background: rgba(8, 10, 15, 0.86);
  backdrop-filter: blur(4px);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
}

.gameover-card {
  width: min(480px, 92vw);
  background: #141821;
  color: #f4f6f9;
  border: 3px solid #ff003c;
  border-radius: 8px;
  padding: 28px 24px;
  text-align: center;
  box-shadow: 0 12px 40px rgba(255, 0, 60, 0.35);
}

.gameover-stamp {
  display: inline-block;
  padding: 4px 14px;
  border: 3px solid #ff003c;
  color: #ff003c;
  font-family: 'Black Han Sans', sans-serif;
  font-size: 22px;
  letter-spacing: 0.08em;
  transform: rotate(-4deg);
  margin-bottom: 12px;
}

#gameover-title {
  font-size: 22px;
  font-weight: 900;
  margin-bottom: 10px;
  color: #ffffff;
}

#gameover-reason {
  font-size: 14px;
  line-height: 1.6;
  color: #d0d6e0;
  margin-bottom: 16px;
}

.gameover-stats {
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: 4px;
  padding: 10px 12px;
  font-size: 13px;
  margin-bottom: 18px;
  display: flex;
  justify-content: space-around;
}

#btn-restart-game {
  padding: 10px 24px;
  background: #ff003c;
  color: #ffffff;
  border: none;
  border-radius: 4px;
  font-family: 'Noto Sans KR', sans-serif;
  font-size: 14px;
  font-weight: 800;
  cursor: pointer;
}

#btn-restart-game:hover {
  background: #e00034;
}

/* =========================================================
   Eye Blink Black Curtain & Overheat Shutdown Badge
   ========================================================= */
#blink-curtain-overlay {
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 180;
}

#eyelid-top,
#eyelid-bottom {
  position: fixed;
  left: 0;
  right: 0;
  height: 0%;
  background: #040507;
  pointer-events: none;
}

#eyelid-top {
  top: 0;
  border-bottom: 2px solid rgba(0, 0, 0, 0.9);
}

#eyelid-bottom {
  bottom: 0;
  border-top: 2px solid rgba(0, 0, 0, 0.9);
}

#overheat-badge {
  margin-top: 3px;
  padding: 3px 6px;
  text-align: center;
  background: rgba(255, 0, 60, 0.9);
  color: #ffffff;
  border: 1px solid #ffffff;
  border-radius: 2px;
  font-size: 10.5px;
  font-weight: 900;
  letter-spacing: 0.03em;
}

/* =========================================================
   Classroom Villain Banners & Raw Ramen E-Key Button
   ========================================================= */
#villain-event-banner {
  position: fixed;
  top: calc(32vh - 18px);
  left: 50%;
  transform: translateX(-50%);
  z-index: 145;
  padding: 6px 16px;
  background: rgba(20, 14, 34, 0.94);
  color: #fde047;
  border: 2px solid #facc15;
  border-radius: 4px;
  font-family: 'Noto Sans KR', sans-serif;
  font-size: 12.5px;
  font-weight: 900;
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.45);
  pointer-events: none;
  white-space: nowrap;
}

#ramen-report-container {
  position: fixed;
  bottom: 126px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 146;
}

#btn-report-ramen {
  padding: 10px 20px;
  background: linear-gradient(135deg, #f97316 0%, #dc2626 100%);
  color: #ffffff;
  border: 3px solid #fef08a;
  border-radius: 6px;
  font-family: 'Noto Sans KR', sans-serif;
  font-size: 14px;
  font-weight: 900;
  cursor: pointer;
  box-shadow: 0 6px 20px rgba(249, 115, 22, 0.55);
}

#btn-report-ramen:hover {
  filter: brightness(1.08);
  transform: scale(1.03);
}

#ramen-timer-val {
  background: rgba(0, 0, 0, 0.45);
  padding: 2px 7px;
  border-radius: 999px;
  margin-left: 6px;
  font-family: 'Share Tech Mono', monospace;
}

/* =========================================================
   2000s Flash B-Grade Spam Ad Popup
   ========================================================= */
#spam-ad-popup {
  position: fixed;
  inset: 0;
  z-index: 155;
  display: flex;
  align-items: center;
  justify-content: center;
  pointer-events: none;
}

.spam-ad-card {
  width: min(440px, 86vw);
  pointer-events: auto;
  background: linear-gradient(135deg, #ff00cc 0%, #ffcc00 45%, #00ffff 100%);
  border: 5px ridge #ff0000;
  box-shadow:
    0 0 0 3px #00ff00,
    0 12px 36px rgba(0, 0, 0, 0.72);
  border-radius: 4px;
  overflow: hidden;
  text-align: center;
}

.spam-ad-topbar {
  background: linear-gradient(90deg, #0000aa, #ff0066, #0000aa);
  color: #ffff00;
  padding: 5px 8px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-weight: 900;
  font-size: 12px;
  border-bottom: 2px solid #ffffff;
}

#spam-ad-badge {
  background: #ff0000;
  color: #ffffff;
  padding: 1px 8px;
  border: 1px solid #ffff00;
  font-size: 11px;
}

/* Prominent Fake Close Button Top-Right */
#btn-spam-fake-close {
  width: 24px;
  height: 24px;
  background: #e11d48;
  color: #ffffff;
  border: 2px outset #ffffff;
  font-size: 14px;
  font-weight: 900;
  line-height: 1;
  cursor: pointer;
}

#spam-ad-body {
  padding: 16px 18px 14px;
  cursor: pointer;
  background: radial-gradient(circle, rgba(255, 255, 0, 0.92) 0%, rgba(255, 80, 180, 0.88) 100%);
}

#spam-ad-headline {
  font-family: 'Black Han Sans', 'Noto Sans KR', sans-serif;
  font-size: clamp(20px, 2.1vw, 26px);
  color: #d00000;
  text-shadow:
    -2px -2px 0 #ffffff,
    2px -2px 0 #ffffff,
    -2px 2px 0 #ffffff,
    2px 2px 0 #ffffff,
    0 4px 6px rgba(0, 0, 0, 0.4);
  line-height: 1.25;
  margin-bottom: 8px;
}

#spam-ad-sub {
  font-size: 13px;
  font-weight: 900;
  color: #0b1354;
  background: rgba(255, 255, 255, 0.78);
  padding: 4px 8px;
  border-radius: 3px;
  margin-bottom: 12px;
}

#btn-spam-cta {
  padding: 9px 22px;
  background: linear-gradient(180deg, #22c55e 0%, #15803d 100%);
  color: #ffffff;
  border: 3px outset #bbf7d0;
  font-family: 'Black Han Sans', 'Noto Sans KR', sans-serif;
  font-size: 17px;
  letter-spacing: 0.04em;
  cursor: pointer;
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.35);
}

.spam-ad-corner-footer {
  background: #18181b;
  padding: 3px 6px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.spam-ad-disclaimer {
  font-size: 9.5px;
  color: #71717a;
}

/* Tiny Real Close Button tucked in corner */
#btn-spam-real-close {
  background: transparent;
  border: 1px solid #3f3f46;
  color: #a1a1aa;
  font-size: 9.5px;
  padding: 1px 5px;
  cursor: pointer;
  border-radius: 2px;
}

#btn-spam-real-close:hover {
  background: #27272a;
  color: #ffffff;
}

/* =========================================================
   Bluetooth Speaker Malfunction Crisis Modal
   ========================================================= */
#bluetooth-crisis-modal {
  position: fixed;
  inset: 0;
  z-index: 170;
  background: rgba(120, 0, 24, 0.52);
  backdrop-filter: blur(2px);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 16px;
}

.crisis-card {
  width: min(460px, 90vw);
  background: #18080c;
  color: #ffffff;
  border: 4px solid #ff003c;
  border-radius: 8px;
  padding: 20px 22px;
  text-align: center;
  box-shadow: 0 0 36px rgba(255, 0, 60, 0.8);
}

.crisis-badge {
  display: inline-block;
  padding: 2px 10px;
  background: #ff003c;
  color: #ffffff;
  font-family: 'Share Tech Mono', monospace;
  font-size: 11px;
  font-weight: 900;
  letter-spacing: 0.08em;
  margin-bottom: 8px;
}

.crisis-title {
  font-size: 17px;
  font-weight: 900;
  color: #fde047;
  margin-bottom: 8px;
}

.crisis-desc {
  font-size: 13px;
  line-height: 1.5;
  color: #f3f4f6;
  margin-bottom: 14px;
}

#crisis-timer-val {
  color: #ff4d6d;
  font-family: 'Share Tech Mono', monospace;
  font-size: 16px;
}

.crisis-meter-wrap {
  margin-bottom: 14px;
}

.crisis-meter-labels {
  display: flex;
  justify-content: space-between;
  font-size: 12px;
  font-weight: 700;
  margin-bottom: 4px;
}

.crisis-meter-track {
  width: 100%;
  height: 14px;
  background: rgba(255, 255, 255, 0.14);
  border: 1px solid #ff4d6d;
  border-radius: 3px;
  overflow: hidden;
}

#crisis-mute-fill {
  width: 0%;
  height: 100%;
  background: linear-gradient(90deg, #f97316, #22c55e);
  transition: width 0.08s ease;
}

#btn-crisis-mute {
  width: 100%;
  padding: 12px 16px;
  background: #ff003c;
  color: #ffffff;
  border: 2px solid #fde047;
  border-radius: 5px;
  font-family: 'Noto Sans KR', sans-serif;
  font-size: 14.5px;
  font-weight: 900;
  cursor: pointer;
}

#btn-crisis-mute:hover {
  background: #e00034;
}

/* =========================================================
   3-Column Hardware Hacker Modding Workstation (28% : 44% : 28%, 100vh)
   ========================================================= */
#intro-screen {
  position: fixed;
  inset: 0;
  z-index: 250;
  width: 100vw;
  height: 100vh;
  background: #0a0d14;
  color: #e2e8f0;
  font-family: 'Noto Sans KR', sans-serif;
  font-size: 15px;
  display: grid;
  grid-template-columns: 28% 44% 28%;
  grid-template-rows: 100vh;
  overflow: hidden;
}

.ws-col {
  height: 100vh;
  min-height: 0;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  border-right: 1px solid #1e293b;
}

#ws-left-col {
  background: #0c111b;
}

#ws-right-col {
  border-right: none;
}

/* ---------------- LEFT TOP (28%): ABC NEWS Breaking Live Widget ---------------- */
#abc-news-widget {
  flex: 0 0 28%;
  min-height: 0;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  background: linear-gradient(180deg, #0b162c 0%, #09101f 100%);
  border-bottom: 2px solid #dc2626;
  cursor: pointer;
  user-select: none;
  overflow: hidden;
}

#abc-news-widget:hover {
  filter: brightness(1.06);
}

.abc-top-bar {
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 6px;
  padding: 3px 8px;
  background: #0f172a;
  border-bottom: 1px solid #1e3a8a;
}

.abc-live-badge {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  background: #dc2626;
  color: #ffffff;
  font-size: 13.5px;
  font-weight: 900;
  padding: 1px 7px;
  border-radius: 3px;
  letter-spacing: 0.02em;
  white-space: nowrap;
}

.abc-live-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: #fef08a;
  animation: abcPulse 1s ease-in-out infinite;
}

@keyframes abcPulse {
  0%, 100% {
    opacity: 1;
    transform: scale(1);
  }
  50% {
    opacity: 0.35;
    transform: scale(0.8);
  }
}

.abc-step-pill {
  font-size: 12.5px;
  font-weight: 800;
  color: #93c5fd;
  background: rgba(30, 58, 138, 0.55);
  border: 1px solid #3b82f6;
  padding: 1px 7px;
  border-radius: 3px;
  white-space: nowrap;
}

.abc-studio-row {
  flex: 1;
  min-height: 0;
  display: grid;
  grid-template-columns: 106px 1fr;
  gap: 7px;
  align-items: center;
  padding: 4px 8px;
}

#abc-news-svg {
  width: 100%;
  height: 100%;
  max-height: 82px;
}

.abc-headline-box {
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 2px;
  min-width: 0;
}

.abc-kicker {
  align-self: flex-start;
  font-size: 11.5px;
  font-weight: 900;
  color: #fde047;
  background: rgba(220, 38, 38, 0.28);
  border-left: 3px solid #ef4444;
  padding: 0 5px;
}

#abc-news-headline {
  font-size: 14.5px;
  font-weight: 800;
  line-height: 1.26;
  color: #f8fafc;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.abc-ticker-bar {
  flex-shrink: 0;
  height: 27px;
  display: flex;
  align-items: center;
  background: #7f1d1d;
  border-top: 1px solid #ef4444;
  overflow: hidden;
}

.abc-ticker-tag {
  flex-shrink: 0;
  background: #fde047;
  color: #0f172a;
  font-size: 13.5px;
  font-weight: 900;
  padding: 0 8px;
  height: 100%;
  display: flex;
  align-items: center;
}

.abc-ticker-track {
  flex: 1;
  overflow: hidden;
  white-space: nowrap;
  padding-left: 8px;
}

#abc-news-ticker-text {
  display: inline-block;
  font-size: 15px;
  font-weight: 700;
  color: #fef2f2;
  animation: abcTickerScroll 16s linear infinite;
}

@keyframes abcTickerScroll {
  0% {
    transform: translateX(0%);
  }
  100% {
    transform: translateX(-55%);
  }
}

/* ---------------- LEFT MIDDLE (50%): Community Gallery & Telegram Tabs ---------------- */
#left-community-section {
  flex: 0 0 50%;
  min-height: 0;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  border-bottom: 2px solid #1e293b;
}

.ws-tabs {
  flex-shrink: 0;
  height: 36px;
  display: grid;
  grid-template-columns: 1fr 1fr;
  background: #0f1420;
  border-bottom: 1px solid #263147;
}

.ws-tab {
  background: #0f1420;
  color: #94a3b8;
  border: none;
  border-right: 1px solid #1e293b;
  font-family: 'Noto Sans KR', sans-serif;
  font-size: 15.5px;
  font-weight: 800;
  cursor: pointer;
  transition: background-color 0.15s ease, color 0.15s ease;
}

.ws-tab:last-child {
  border-right: none;
}

.ws-tab.active {
  background: #172033;
  color: #00f3ff;
  box-shadow: inset 0 -2px 0 #00f3ff;
}

.ws-tab-panel {
  flex: 1;
  min-height: 0;
  display: flex;
  flex-direction: column;
  overflow: hidden;
}

/* TAB 1: DCInside Gallery (Flush Top List + Full Bottom Post/Comments, Zero Dead Space) */
.gallery-top-half {
  flex: 1.05;
  min-height: 0;
  display: flex;
  flex-direction: column;
  background: #111622;
  border-bottom: 2px solid #2b3852;
}

.dc-board-bar {
  flex-shrink: 0;
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 3px 8px;
  background: #161d2e;
  border-bottom: 1px solid #28354f;
}

.dc-mini-badge {
  background: #3b4890;
  color: #ffffff;
  font-size: 13px;
  font-weight: 900;
  padding: 1px 7px;
  border-radius: 2px;
}

.dc-board-live {
  font-size: 13px;
  font-weight: 700;
  color: #93c5fd;
}

#gallery-table-body {
  flex: 1;
  min-height: 0;
  display: grid;
  grid-template-rows: repeat(6, 1fr);
}

.dc-row {
  display: grid;
  grid-template-columns: 44px 1fr 72px;
  gap: 5px;
  align-items: center;
  padding: 0 7px;
  border-bottom: 1px solid #1e283c;
  font-size: 15px;
  cursor: pointer;
  background: #111622;
  transition: background-color 0.12s ease;
}

.dc-row:last-child {
  border-bottom: none;
}

.dc-row:hover {
  background: #182133;
}

.dc-row.active {
  background: #1e2a42;
  box-shadow: inset 3px 0 0 #60a5fa;
}

.dc-tag {
  font-size: 12.5px;
  font-weight: 900;
  padding: 1px 4px;
  border-radius: 2px;
  text-align: center;
  background: #28354f;
  color: #cbd5e1;
}

.dc-tag.tag-notice {
  background: #dc2626;
  color: #ffffff;
}

.dc-tag.tag-hot {
  background: #3b4890;
  color: #fde047;
}

.dc-row-title {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  color: #f1f5f9;
  font-size: 15px;
  font-weight: 700;
}

.dc-row-author {
  font-size: 13px;
  color: #94a3b8;
  text-align: right;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.gallery-bottom-half {
  flex: 1;
  min-height: 0;
  display: flex;
  flex-direction: column;
  background: #0d111a;
  padding: 5px 8px;
  gap: 4px;
}

.gallery-detail-header {
  flex-shrink: 0;
  border-bottom: 1px dashed #263248;
  padding-bottom: 3px;
}

#gallery-detail-title {
  font-size: 15px;
  font-weight: 900;
  color: #f8fafc;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

#gallery-detail-meta {
  font-size: 12.5px;
  color: #64748b;
}

#gallery-detail-body {
  flex-shrink: 0;
  max-height: 44px;
  overflow-y: auto;
  font-size: 15px;
  line-height: 1.32;
  color: #cbd5e1;
  background: #131926;
  border: 1px solid #1f2a3f;
  border-radius: 3px;
  padding: 3px 6px;
}

.gallery-comments-wrap {
  flex: 1;
  min-height: 0;
  display: flex;
  flex-direction: column;
  gap: 2px;
  background: #111622;
  border: 1px solid #1e283c;
  border-radius: 3px;
  padding: 4px 6px;
  overflow-y: auto;
}

.comments-label {
  flex-shrink: 0;
  font-size: 13px;
  font-weight: 800;
  color: #93c5fd;
  border-bottom: 1px solid #1f2a3f;
  padding-bottom: 2px;
}

#gallery-detail-comments {
  display: flex;
  flex-direction: column;
  gap: 3px;
}

.dc-comment-row {
  font-size: 15px;
  line-height: 1.28;
  color: #cbd5e1;
  border-bottom: 1px dotted #1e273a;
  padding-bottom: 2px;
}

.dc-comment-row:last-child {
  border-bottom: none;
  padding-bottom: 0;
}

.dc-comment-nick {
  color: #e2e8f0;
  font-weight: 800;
  margin-right: 4px;
}

/* TAB 2: Telegram Black-Market Broker (@DarkOptic_KR) */
#left-panel-telegram {
  background: #0e1621;
}

.tg-header {
  flex-shrink: 0;
  display: flex;
  align-items: center;
  gap: 9px;
  padding: 6px 10px;
  background: #17212b;
  border-bottom: 1px solid #243140;
}

.tg-avatar {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: linear-gradient(135deg, #00c4ff, #0066cc);
  color: #ffffff;
  font-family: 'Share Tech Mono', monospace;
  font-weight: 900;
  font-size: 14px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.tg-peer-info {
  display: flex;
  flex-direction: column;
}

.tg-peer-info strong {
  color: #ffffff;
  font-size: 15px;
}

.tg-peer-info span {
  color: #6ab2f2;
  font-size: 12.5px;
}

#telegram-chat-list {
  flex: 1;
  min-height: 0;
  padding: 8px;
  display: flex;
  flex-direction: column;
  gap: 7px;
  overflow-y: auto;
}

.tg-msg {
  max-width: 92%;
  padding: 7px 9px;
  border-radius: 8px;
  font-size: 15px;
  line-height: 1.4;
  background: #182533;
  color: #e2e8f0;
  border: 1px solid #233347;
  align-self: flex-start;
}

.tg-msg.tg-warn {
  background: rgba(220, 38, 38, 0.22);
  border-color: #ef4444;
  color: #fecaca;
}

.tg-msg.tg-user {
  align-self: flex-end;
  background: #2b5278;
  border-color: #3a6a98;
  color: #ffffff;
}

.tg-msg-time {
  display: block;
  margin-top: 2px;
  font-size: 11px;
  color: #93c5fd;
  text-align: right;
}

.tg-loan-footer {
  flex-shrink: 0;
  padding: 6px 10px;
  background: #17212b;
  border-top: 1px solid #243140;
}

#btn-take-loan {
  width: 100%;
  padding: 8px 10px;
  background: linear-gradient(135deg, #b91c1c, #dc2626);
  color: #ffffff;
  border: 1.5px solid #fca5a5;
  border-radius: 5px;
  font-family: 'Noto Sans KR', sans-serif;
  font-size: 17px;
  font-weight: 900;
  cursor: pointer;
  transition: filter 0.15s ease;
}

#btn-take-loan:hover:not(:disabled) {
  filter: brightness(1.12);
}

#btn-take-loan:disabled {
  background: #273242;
  border-color: #475569;
  color: #94a3b8;
  cursor: not-allowed;
}

/* ---------------- LEFT BOTTOM (22%): 'OO냥이' Examinee Ticket Generator ---------------- */
#examinee-card-widget {
  flex: 0 0 22%;
  min-height: 0;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  background: linear-gradient(180deg, #10192b 0%, #0a101c 100%);
  border-top: 2px solid #00f3ff;
  padding: 6px 10px;
  gap: 5px;
  overflow: hidden;
}

.ticket-header {
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-bottom: 1px solid #1e3a5f;
  padding-bottom: 3px;
}

.ticket-title {
  font-size: 15.5px;
  font-weight: 900;
  color: #f8fafc;
}

.ticket-id-pill {
  font-family: 'Share Tech Mono', 'Noto Sans KR', monospace;
  font-size: 14px;
  color: #94a3b8;
  background: rgba(0, 243, 255, 0.1);
  border: 1px solid rgba(0, 243, 255, 0.4);
  padding: 1px 6px;
  border-radius: 3px;
}

.ticket-id-pill strong {
  color: #00f3ff;
}

.ticket-body {
  flex: 1;
  min-height: 0;
  display: flex;
  align-items: center;
  gap: 10px;
}

.ticket-photo-box {
  height: 100%;
  max-height: 104px;
  aspect-ratio: 88 / 94;
  flex-shrink: 0;
  border: 1.5px solid #38bdf8;
  border-radius: 4px;
  overflow: hidden;
  background: #dbeafe;
  box-shadow: 0 0 12px rgba(0, 243, 255, 0.18);
}

#cat-id-svg {
  width: 100%;
  height: 100%;
  display: block;
}

.ticket-controls {
  flex: 1;
  min-width: 0;
  height: 100%;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  gap: 4px;
}

.ticket-name-display {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 15px;
}

.ticket-lbl {
  color: #94a3b8;
  font-weight: 700;
}

#examinee-name-val {
  font-size: 17px;
  font-weight: 900;
  color: #00f3ff;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

#input-cat-name {
  width: 100%;
  background: #070c16;
  border: 1.5px solid #334155;
  border-radius: 4px;
  padding: 4px 8px;
  font-family: 'Noto Sans KR', sans-serif;
  font-size: 15px;
  font-weight: 700;
  color: #ffffff;
  outline: none;
}

#input-cat-name:focus {
  border-color: #00f3ff;
}

#btn-random-cat {
  width: 100%;
  padding: 4px 8px;
  background: linear-gradient(135deg, #1d4ed8 0%, #0284c7 100%);
  color: #ffffff;
  border: 1px solid #38bdf8;
  border-radius: 4px;
  font-family: 'Noto Sans KR', sans-serif;
  font-size: 15px;
  font-weight: 900;
  cursor: pointer;
}

#btn-random-cat:hover {
  filter: brightness(1.12);
}

/* ---------------- CENTER COLUMN (44%): Oversized SVG Glasses & 5-Specs ---------------- */
#ws-center-col {
  background: #0b0f18;
  padding: 8px 12px;
  gap: 7px;
}

.ws-center-header {
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-bottom: 1px solid #1e293b;
  padding-bottom: 5px;
}

.ws-center-title-group {
  display: flex;
  flex-direction: column;
  gap: 1px;
}

.ws-sys-tag {
  font-family: 'Share Tech Mono', monospace;
  font-size: 12px;
  color: #00f3ff;
  letter-spacing: 0.08em;
}

.ws-main-title {
  font-size: 21px;
  font-weight: 900;
  color: #f8fafc;
  line-height: 1.15;
}

.intro-rf-alert {
  background: rgba(255, 0, 60, 0.18);
  border: 1.5px solid #ff003c;
  color: #ff809b;
  padding: 4px 10px;
  border-radius: 4px;
  font-size: 14px;
  font-weight: 900;
}

#blueprint-stage {
  position: relative;
  flex: 1.45;
  min-height: 0;
  background: radial-gradient(circle at 50% 45%, #0b1628 0%, #050911 100%);
  border: 1px solid #1d2d44;
  border-radius: 5px;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
}

.blueprint-grid-overlay {
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(rgba(0, 243, 255, 0.07) 1px, transparent 1px),
    linear-gradient(90deg, rgba(0, 243, 255, 0.07) 1px, transparent 1px);
  background-size: 20px 20px;
  pointer-events: none;
}

#blueprint-svg {
  width: 97%;
  height: 95%;
  max-height: 100%;
  z-index: 2;
}

.bt-wave {
  animation: btWavePulse 1.3s ease-in-out infinite;
}

.bt-wave.wave-2 {
  animation-delay: 0.22s;
}

.bt-wave.wave-3 {
  animation-delay: 0.44s;
}

@keyframes btWavePulse {
  0%, 100% {
    opacity: 0.25;
  }
  50% {
    opacity: 1;
  }
}

.gold-circuit-pulse {
  stroke-dasharray: 8 4;
  animation: goldCircuitPulse 1s linear infinite;
}

@keyframes goldCircuitPulse {
  from {
    stroke-dashoffset: 24;
  }
  to {
    stroke-dashoffset: 0;
  }
}

.bp-callout {
  position: absolute;
  z-index: 3;
  background: rgba(7, 15, 26, 0.94);
  border: 1.5px solid rgba(0, 243, 255, 0.52);
  border-radius: 4px;
  padding: 3px 9px;
  font-size: 13.5px;
  font-weight: 700;
  color: #cbd5e1;
  white-space: nowrap;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.55);
}

.bp-callout strong {
  color: #00f3ff;
  font-weight: 900;
}

.bp-c-frame {
  top: 7px;
  left: 8px;
}

.bp-c-camera {
  top: 7px;
  left: 50%;
  transform: translateX(-50%);
}

.bp-c-coating {
  top: 7px;
  right: 8px;
}

.bp-c-power {
  bottom: 7px;
  left: 8px;
}

.bp-c-firmware {
  bottom: 7px;
  right: 8px;
}

/* Live AR Lens Pre-Test Overlay */
#bp-ar-preview-overlay {
  position: absolute;
  inset: 0;
  z-index: 6;
  padding: 10px 12px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  background: radial-gradient(
    circle at 50% 50%,
    rgba(0, 243, 255, var(--ar-preview-center-alpha, 0.14)) 0%,
    rgba(0, 110, 255, var(--ar-preview-edge-alpha, 0.28)) 100%
  );
  border: 1.5px solid rgba(0, 243, 255, 0.7);
  box-shadow: inset 0 0 24px rgba(0, 243, 255, var(--ar-preview-glow-alpha, 0.26));
  pointer-events: none;
  transition: background 0.15s ease, box-shadow 0.15s ease, border-color 0.15s ease;
}

#bp-ar-preview-overlay.hidden {
  display: none;
}

#bp-ar-preview-overlay.is-danger {
  border-color: rgba(255, 0, 60, 0.85);
  box-shadow: inset 0 0 30px rgba(255, 0, 60, 0.36);
}

#bp-ar-preview-overlay.is-off {
  background: rgba(3, 6, 12, 0.72);
  border-color: rgba(100, 116, 139, 0.65);
  box-shadow: none;
}

.bp-ar-scanlines {
  position: absolute;
  inset: 0;
  background: repeating-linear-gradient(
    0deg,
    rgba(0, 243, 255, 0.16) 0px,
    rgba(0, 243, 255, 0.16) 1px,
    transparent 1px,
    transparent 4px
  );
  opacity: 0.75;
  pointer-events: none;
}

.bp-ar-reticle {
  position: absolute;
  inset: 0;
  margin: auto;
  width: 72px;
  height: 72px;
  border: 1.5px dashed rgba(0, 243, 255, 0.75);
  border-radius: 50%;
  box-shadow: 0 0 12px rgba(0, 243, 255, 0.35);
}

.bp-ar-reticle::before,
.bp-ar-reticle::after {
  content: '';
  position: absolute;
  inset: 0;
  margin: auto;
  background: rgba(0, 243, 255, 0.85);
}

.bp-ar-reticle::before {
  width: 16px;
  height: 2px;
}

.bp-ar-reticle::after {
  width: 2px;
  height: 16px;
}

.bp-ar-top-bar,
.bp-ar-bottom-bar {
  position: relative;
  z-index: 2;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  background: rgba(4, 10, 18, 0.88);
  border: 1px solid rgba(0, 243, 255, 0.4);
  padding: 4px 8px;
  border-radius: 3px;
  font-family: 'Share Tech Mono', 'Noto Sans KR', monospace;
  font-size: 13px;
  white-space: nowrap;
}

.bp-ar-chromatic {
  color: #e0f2fe;
  font-weight: 800;
  text-shadow:
    2px 0 0 rgba(255, 0, 60, 0.75),
    -2px 0 0 rgba(0, 243, 255, 0.85);
}

.bp-ar-bright-badge {
  color: #00f3ff;
  font-weight: 800;
}

.bp-ar-wheel-hint {
  color: #cbd5e1;
  font-size: 12.5px;
}

.bp-ar-status-safe {
  color: #4ade80;
  font-size: 13px;
}

.bp-ar-status-danger {
  color: #ff4d6d;
  font-size: 13px;
  text-shadow: 0 0 8px rgba(255, 0, 60, 0.6);
}

.bp-ar-status-off {
  color: #94a3b8;
  font-size: 13px;
}

#workstation-specs-panel {
  flex-shrink: 0;
  background: #101624;
  border: 1px solid #22304a;
  border-radius: 5px;
  padding: 7px 11px;
  display: flex;
  flex-direction: column;
  gap: 5px;
}

.specs-header-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 6px;
  font-size: 15px;
  font-weight: 900;
  color: #f1f5f9;
  border-bottom: 1px solid #1f2b42;
  padding-bottom: 4px;
  white-space: nowrap;
}

.specs-header-actions {
  display: flex;
  align-items: center;
  gap: 6px;
}

.ar-preview-toggle-btn {
  background: rgba(0, 243, 255, 0.12);
  border: 1.5px solid rgba(0, 243, 255, 0.65);
  color: #00f3ff;
  padding: 2px 8px;
  border-radius: 4px;
  font-family: 'Noto Sans KR', sans-serif;
  font-size: 13.5px;
  font-weight: 900;
  cursor: pointer;
  white-space: nowrap;
  transition: background 0.15s ease, box-shadow 0.15s ease;
}

.ar-preview-toggle-btn:hover {
  background: rgba(0, 243, 255, 0.25);
}

.ar-preview-toggle-btn.active {
  background: #00f3ff;
  color: #04101a;
  box-shadow: 0 0 12px rgba(0, 243, 255, 0.6);
}

.threshold-badge {
  font-size: 13.5px;
  background: rgba(0, 243, 255, 0.1);
  border: 1px solid rgba(0, 243, 255, 0.45);
  padding: 2px 7px;
  border-radius: 4px;
  color: #cbd5e1;
  white-space: nowrap;
}

.threshold-badge strong {
  color: #00f3ff;
}

.specs-bars-grid {
  display: flex;
  flex-direction: column;
  gap: 5px;
}

.spec-row {
  display: grid;
  grid-template-columns: 112px 1fr 48px;
  align-items: center;
  gap: 8px;
  font-size: 15px;
}

.spec-name {
  color: #e2e8f0;
  font-weight: 800;
}

.spec-track {
  height: 10px;
  background: #1a2436;
  border: 1px solid #2a3954;
  border-radius: 3px;
  overflow: hidden;
}

.spec-fill {
  height: 100%;
  background: linear-gradient(90deg, #0099ff, #00f3ff);
  transition: width 0.25s ease;
}

.spec-fill.fill-amber {
  background: linear-gradient(90deg, #f59e0b, #fbbf24);
}

.spec-fill.fill-green {
  background: linear-gradient(90deg, #16a34a, #4ade80);
}

.spec-fill.fill-purple {
  background: linear-gradient(90deg, #8b5cf6, #c084fc);
}

.spec-num {
  font-family: 'Share Tech Mono', monospace;
  font-size: 15px;
  font-weight: 800;
  color: #00f3ff;
  text-align: right;
}

.ws-center-footer {
  flex-shrink: 0;
  display: grid;
  grid-template-columns: 1fr 1.45fr;
  gap: 8px;
}

.intro-btn-secondary {
  padding: 9px 10px;
  background: #1a2334;
  color: #f8fafc;
  border: 1.5px solid #475569;
  border-radius: 5px;
  font-family: 'Noto Sans KR', sans-serif;
  font-size: 17px;
  font-weight: 900;
  cursor: pointer;
}

.intro-btn-secondary:hover {
  border-color: #94a3b8;
  background: #233046;
}

.intro-btn-primary {
  padding: 9px 12px;
  background: linear-gradient(135deg, #00c4ff 0%, #0066ff 100%);
  color: #ffffff;
  border: none;
  border-radius: 5px;
  font-family: 'Noto Sans KR', sans-serif;
  font-size: 17.5px;
  font-weight: 900;
  cursor: pointer;
  box-shadow: 0 4px 16px rgba(0, 196, 255, 0.35);
}

.intro-btn-primary:hover {
  filter: brightness(1.1);
}

/* ---------------- RIGHT COLUMN (28%): 5-Slot Flex-1 Equal Fill Parts Shop ---------------- */
#ws-right-col {
  background: #0d121d;
}

.shop-header {
  flex-shrink: 0;
  padding: 5px 9px;
  background: #141c2e;
  border-bottom: 2px solid #26354f;
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.shop-title-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 6px;
}

.shop-title-main {
  font-size: 20px;
  font-weight: 900;
  color: #f8fafc;
  line-height: 1.1;
}

.shop-hint-pill {
  font-size: 12px;
  font-weight: 800;
  color: #00f3ff;
  background: rgba(0, 243, 255, 0.12);
  border: 1px solid rgba(0, 243, 255, 0.45);
  padding: 1px 6px;
  border-radius: 3px;
  white-space: nowrap;
}

.shop-budget-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.budget-block {
  display: flex;
  align-items: baseline;
  gap: 5px;
}

.budget-block.align-right {
  text-align: right;
}

.budget-label {
  font-size: 13.5px;
  font-weight: 700;
  color: #94a3b8;
}

#shop-budget-val {
  font-family: 'Share Tech Mono', 'Noto Sans KR', monospace;
  font-size: 17px;
  font-weight: 900;
  color: #4ade80;
}

#shop-spent-val {
  font-family: 'Share Tech Mono', 'Noto Sans KR', monospace;
  font-size: 16px;
  font-weight: 900;
  color: #00f3ff;
}

#shop-feedback-msg {
  font-size: 13px;
  font-weight: 700;
  color: #93c5fd;
  background: rgba(0, 243, 255, 0.08);
  border-radius: 3px;
  padding: 2px 6px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

#shop-feedback-msg.msg-error {
  color: #fda4af;
  background: rgba(255, 0, 60, 0.18);
}

#parts-shop-list {
  flex: 1;
  min-height: 0;
  padding: 4px 7px;
  display: flex;
  flex-direction: column;
  gap: 3px;
  overflow: hidden;
}

.shop-slot-group {
  flex: 1;
  min-height: 0;
  display: flex;
  flex-direction: column;
  gap: 2px;
  background: #121a2b;
  border: 1px solid #25344f;
  border-radius: 5px;
  padding: 3px 6px;
  overflow: hidden;
}

.shop-slot-title {
  flex-shrink: 0;
  font-size: 14px;
  font-weight: 900;
  color: #bae6fd;
  border-left: 4px solid #00f3ff;
  padding-left: 6px;
  line-height: 1.1;
}

.shop-slot-cards {
  flex: 1;
  min-height: 0;
  display: grid;
  grid-auto-flow: column;
  grid-auto-columns: 1fr;
  gap: 4px;
  align-items: stretch;
}

.part-card {
  height: 100%;
  min-width: 0;
  text-align: left;
  background: #172034;
  border: 1.5px solid #2c3c5c;
  border-radius: 4px;
  padding: 3px 5px;
  color: #f1f5f9;
  cursor: pointer;
  font-family: 'Noto Sans KR', sans-serif;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  gap: 1px;
  overflow: hidden;
  transition: border-color 0.12s ease, background-color 0.12s ease;
}

.part-card:hover {
  border-color: #38bdf8;
  background: #1e2a44;
}

.part-card.equipped {
  border-color: #00f3ff;
  background: rgba(0, 243, 255, 0.14);
  box-shadow: inset 0 3px 0 #00f3ff, 0 0 10px rgba(0, 243, 255, 0.2);
}

.part-card.unaffordable:not(.equipped) {
  opacity: 0.6;
}

.part-name {
  font-size: 17px;
  font-weight: 900;
  color: #ffffff;
  line-height: 1.08;
  letter-spacing: -0.04em;
  word-break: keep-all;
}

.part-badge-row {
  flex-shrink: 0;
  display: flex;
  flex-wrap: wrap;
  gap: 2px;
}

.part-spec-badge {
  font-size: 11px;
  font-weight: 800;
  padding: 1px 3px;
  border-radius: 2px;
  line-height: 1.08;
  white-space: nowrap;
}

.part-spec-badge.buff {
  background: rgba(34, 197, 94, 0.18);
  color: #86efac;
  border: 1px solid rgba(74, 222, 128, 0.45);
}

.part-spec-badge.warn {
  background: rgba(239, 68, 68, 0.18);
  color: #fda4af;
  border: 1px solid rgba(248, 113, 113, 0.45);
}

.part-spec-badge.neutral {
  background: rgba(148, 163, 184, 0.16);
  color: #cbd5e1;
  border: 1px solid rgba(148, 163, 184, 0.35);
}

.part-price {
  font-family: 'Share Tech Mono', 'Noto Sans KR', monospace;
  font-size: 13px;
  font-weight: 800;
  line-height: 1.1;
  color: #fbbf24;
  white-space: nowrap;
}

.part-card.equipped .part-price {
  color: #00f3ff;
}

/* =========================================================
   Ending Codex Modal
   ========================================================= */
#codex-modal {
  position: fixed;
  inset: 0;
  z-index: 320;
  background: rgba(5, 8, 14, 0.86);
  backdrop-filter: blur(4px);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
}

.codex-card {
  width: min(820px, 94vw);
  max-height: 88vh;
  background: #121722;
  color: #f1f5f9;
  border: 2px solid #00f3ff;
  border-radius: 8px;
  padding: 18px 20px;
  display: flex;
  flex-direction: column;
  gap: 12px;
  box-shadow: 0 12px 40px rgba(0, 243, 255, 0.22);
}

.codex-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  border-bottom: 1px solid #283449;
  padding-bottom: 10px;
}

#codex-title {
  font-size: 18px;
  font-weight: 900;
  color: #00f3ff;
}

.codex-subtitle {
  font-size: 12px;
  color: #94a3b8;
  margin-top: 2px;
}

#btn-close-codex {
  padding: 6px 12px;
  background: #1e293b;
  color: #e2e8f0;
  border: 1px solid #475569;
  border-radius: 4px;
  font-family: 'Noto Sans KR', sans-serif;
  font-size: 12.5px;
  font-weight: 800;
  cursor: pointer;
}

#codex-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 10px;
  overflow-y: auto;
}

.codex-slot {
  background: #171d2b;
  border: 1px solid #2b374e;
  border-radius: 5px;
  padding: 10px 12px;
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.codex-slot.unlocked {
  border-color: #22c55e;
  background: rgba(34, 197, 94, 0.1);
  cursor: pointer;
}

.codex-slot.unlocked:hover {
  background: rgba(34, 197, 94, 0.18);
}

.codex-slot-code {
  font-family: 'Share Tech Mono', monospace;
  font-size: 11px;
  color: #64748b;
}

.codex-slot.unlocked .codex-slot-code {
  color: #4ade80;
}

.codex-slot-title {
  font-size: 13px;
  font-weight: 800;
  color: #e2e8f0;
}

.codex-slot-hint {
  font-size: 11px;
  line-height: 1.4;
  color: #94a3b8;
}

/* =========================================================
   Priority 8 Cloud Final Dilemma Modal
   ========================================================= */
#cloud-choice-modal {
  position: fixed;
  inset: 0;
  z-index: 285;
  background: rgba(4, 5, 8, 0.92);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
}

.cloud-choice-card {
  width: min(560px, 92vw);
  background: #0c0d10;
  color: #e4e4e7;
  border: 2px solid #d4d4d8;
  padding: 26px 28px;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.85);
}

.cloud-choice-tag {
  font-family: 'Share Tech Mono', monospace;
  font-size: 11px;
  letter-spacing: 0.12em;
  color: #a1a1aa;
  border-bottom: 1px solid #27272a;
  padding-bottom: 6px;
  margin-bottom: 12px;
}

#cloud-choice-title {
  font-size: 20px;
  font-weight: 900;
  color: #ffffff;
  margin-bottom: 10px;
}

.cloud-choice-desc {
  font-size: 13.5px;
  line-height: 1.65;
  color: #a1a1aa;
  margin-bottom: 20px;
}

.cloud-choice-actions {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.choice-btn {
  width: 100%;
  padding: 13px 16px;
  font-family: 'Noto Sans KR', sans-serif;
  font-size: 14px;
  font-weight: 800;
  cursor: pointer;
  border-radius: 2px;
  transition: background-color 0.15s ease, color 0.15s ease, border-color 0.15s ease;
}

.choice-btn-silence {
  background: #18181b;
  color: #f4f4f5;
  border: 1.5px solid #71717a;
}

.choice-btn-silence:hover {
  background: #ffffff;
  color: #09090b;
  border-color: #ffffff;
}

.choice-btn-whistleblow {
  background: #09090b;
  color: #d4d4d8;
  border: 1.5px dashed #52525b;
}

.choice-btn-whistleblow:hover {
  background: #27272a;
  color: #ffffff;
  border-color: #e4e4e7;
}

/* =========================================================
   Noir Terminal Crime-Thriller Ending Screen
   ========================================================= */
#ending-screen {
  position: fixed;
  inset: 0;
  z-index: 290;
  background: #040405;
  color: #e4e4e7;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
}

.ending-dossier {
  width: min(760px, 94vw);
  max-height: 90vh;
  background: #0a0a0c;
  border: 2px solid #d4d4d8;
  box-shadow: 0 0 80px rgba(0, 0, 0, 0.95);
  padding: 24px 28px;
  display: flex;
  flex-direction: column;
  gap: 14px;
  font-family: 'Noto Sans KR', sans-serif;
}

.ending-dossier-header {
  border-bottom: 2px solid #27272a;
  padding-bottom: 10px;
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.ending-header-meta {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 11.5px;
  color: #71717a;
  font-family: 'Share Tech Mono', 'Noto Sans KR', monospace;
}

.ending-code-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

#ending-code {
  font-family: 'Share Tech Mono', monospace;
  font-size: 14px;
  letter-spacing: 0.1em;
  color: #a1a1aa;
}

#ending-stamp {
  font-size: 12px;
  font-weight: 900;
  letter-spacing: 0.08em;
  padding: 2px 10px;
  border: 1.5px solid #e4e4e7;
  color: #ffffff;
  background: #18181b;
}

#ending-title {
  font-size: clamp(22px, 2.3vw, 28px);
  font-weight: 900;
  color: #ffffff;
  letter-spacing: -0.02em;
}

#ending-subreason {
  font-size: 13px;
  font-weight: 700;
  color: #d4d4d8;
  background: #18181b;
  border-left: 3px solid #ffffff;
  padding: 6px 10px;
}

.ending-story-box {
  background: #050506;
  border: 1px solid #27272a;
  padding: 16px 18px;
  min-height: 150px;
  max-height: 260px;
  overflow-y: auto;
  cursor: pointer;
}

#ending-story-text {
  display: inline;
  font-size: 14.5px;
  line-height: 1.78;
  color: #d4d4d8;
  white-space: pre-line;
}

.noir-cursor {
  display: inline-block;
  color: #ffffff;
  animation: noirBlink 0.9s steps(1) infinite;
  margin-left: 2px;
}

@keyframes noirBlink {
  0%, 49% {
    opacity: 1;
  }
  50%, 100% {
    opacity: 0;
  }
}

#ending-meta-stats {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 8px;
  padding: 9px 12px;
  background: #111114;
  border: 1px solid #27272a;
  font-family: 'Share Tech Mono', 'Noto Sans KR', monospace;
  font-size: 12px;
  color: #a1a1aa;
}

#ending-meta-stats strong {
  color: #ffffff;
}

.ending-footer {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  padding-top: 4px;
}

.ending-btn-primary,
.ending-btn-secondary {
  flex: 1;
  padding: 11px 16px;
  font-family: 'Noto Sans KR', sans-serif;
  font-size: 13.5px;
  font-weight: 800;
  cursor: pointer;
  border-radius: 2px;
  transition: background-color 0.15s ease, color 0.15s ease;
}

.ending-btn-primary {
  background: #f4f4f5;
  color: #09090b;
  border: 1.5px solid #f4f4f5;
}

.ending-btn-primary:hover {
  background: #ffffff;
}

.ending-btn-secondary {
  background: #141418;
  color: #e4e4e7;
  border: 1.5px solid #52525b;
}

.ending-btn-secondary:hover {
  border-color: #d4d4d8;
  background: #1f1f24;
}

/* =========================================================
   2.5s Firmware Flashing Launch Terminal Modal
   ========================================================= */
#firmware-flash-modal {
  position: fixed;
  inset: 0;
  z-index: 340;
  background: rgba(2, 6, 12, 0.9);
  backdrop-filter: blur(5px);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
}

#firmware-flash-modal.hidden {
  display: none;
}

.flash-terminal-card {
  width: min(560px, 92vw);
  background: #040912;
  border: 1.5px solid #00f3ff;
  border-radius: 6px;
  box-shadow:
    0 0 40px rgba(0, 243, 255, 0.22),
    0 18px 45px rgba(0, 0, 0, 0.85);
  overflow: hidden;
  font-family: 'Share Tech Mono', 'Noto Sans KR', monospace;
}

.flash-terminal-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding: 9px 14px;
  background: #0a1424;
  border-bottom: 1px solid #1e3a5f;
  font-size: 11.5px;
  color: #00f3ff;
}

.flash-dot-group {
  display: flex;
  align-items: center;
  gap: 5px;
}

.flash-dot {
  width: 9px;
  height: 9px;
  border-radius: 50%;
}

.flash-dot.red {
  background: #ff4d6d;
}

.flash-dot.amber {
  background: #fbbf24;
}

.flash-dot.green {
  background: #4ade80;
}

#flash-modal-title {
  font-weight: 800;
  letter-spacing: 0.04em;
}

.flash-port-tag {
  font-size: 10.5px;
  color: #94a3b8;
}

#flash-log-output {
  min-height: 185px;
  max-height: 220px;
  overflow-y: auto;
  padding: 12px 15px;
  background: #02050a;
  font-size: 12px;
  line-height: 1.65;
  color: #4ade80;
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.flash-log-line.sys {
  color: #00f3ff;
}

.flash-log-line.warn {
  color: #fbbf24;
}

.flash-log-line.ok {
  color: #4ade80;
  font-weight: 700;
}

.flash-log-line.danger {
  color: #ff6b8b;
}

.flash-progress-wrap {
  padding: 10px 15px 14px;
  background: #07101c;
  border-top: 1px solid #16263d;
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.flash-progress-meta {
  display: flex;
  justify-content: space-between;
  font-size: 11.5px;
  color: #cbd5e1;
}

#flash-progress-pct {
  color: #00f3ff;
  font-weight: 800;
}

.flash-progress-track {
  height: 10px;
  background: #0f1b2e;
  border: 1px solid #1e3a5f;
  border-radius: 3px;
  overflow: hidden;
}

#flash-progress-fill {
  height: 100%;
  width: 0%;
  background: linear-gradient(90deg, #0099ff 0%, #00f3ff 65%, #4ade80 100%);
  box-shadow: 0 0 10px rgba(0, 243, 255, 0.55);
  transition: width 0.14s linear;
}

/* ============================================================
   2027 Regular Admission 3-Column Enterprise Portal (Zero Dead Space)
   ============================================================ */
#admission-screen {
  position: fixed;
  inset: 0;
  z-index: 260;
  background: #e2e8f0;
  color: #0f172a;
  font-family: 'Pretendard', 'Noto Sans KR', sans-serif;
  display: flex;
  cursor: auto;
}

#admission-screen.hidden {
  display: none;
}

.admission-portal-shell {
  width: 100%;
  height: 100vh;
  display: flex;
  flex-direction: column;
  overflow: hidden;
}

.admission-topbar {
  height: 50px;
  flex-shrink: 0;
  background: linear-gradient(90deg, #0b2149 0%, #163e7d 60%, #1d4ed8 100%);
  color: #ffffff;
  padding: 0 16px;
  border-bottom: 3px solid #f59e0b;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

.adm-brand-block {
  display: flex;
  align-items: center;
  gap: 10px;
}

.adm-brand-badge {
  background: #f59e0b;
  color: #111827;
  font-size: 11px;
  font-weight: 900;
  padding: 3px 8px;
  border-radius: 3px;
  letter-spacing: 0.04em;
}

#admission-main-title {
  margin: 0;
  font-size: 18px;
  font-weight: 900;
  letter-spacing: -0.02em;
}

.adm-score-cluster {
  display: flex;
  align-items: center;
  gap: 12px;
  font-size: 14px;
  font-weight: 700;
}

.adm-server-status {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  background: rgba(15, 23, 42, 0.45);
  border: 1px solid rgba(74, 222, 128, 0.55);
  padding: 3px 9px;
  border-radius: 12px;
  font-size: 12px;
  color: #bbf7d0;
}

.adm-live-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: #4ade80;
  box-shadow: 0 0 6px #4ade80;
}

#adm-examinee-info {
  color: #dbeafe;
  font-size: 14px;
}

.adm-score-pill {
  background: #ffffff;
  color: #0f172a;
  padding: 4px 12px;
  border-radius: 18px;
  font-size: 14.5px;
  font-weight: 800;
  border: 2px solid #f59e0b;
}

.adm-score-pill strong {
  color: #1d4ed8;
  font-size: 15.5px;
}

#adm-legal-disclaimer {
  flex-shrink: 0;
  background: #fefce8;
  color: #713f12;
  border-bottom: 1px solid #fde047;
  padding: 3px 16px;
  font-size: 12px;
  font-weight: 800;
  text-align: center;
}

.admission-body {
  flex: 1;
  min-height: 0;
  display: grid;
  grid-template-columns: 22fr 40fr 38fr;
  gap: 8px;
  padding: 8px 10px;
}

.admission-left-col,
.admission-center-col,
.admission-right-col {
  background: #ffffff;
  border: 1.5px solid #cbd5e1;
  border-radius: 6px;
  min-height: 0;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  box-shadow: 0 3px 12px rgba(15, 23, 42, 0.08);
}

/* LEFT COLUMN (22%): University Directory */
.adm-col-head {
  flex-shrink: 0;
  padding: 8px 11px;
  background: #0f172a;
  color: #f8fafc;
  font-size: 15px;
  font-weight: 900;
}

#adm-group-tabs {
  flex-shrink: 0;
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 3px;
  padding: 6px;
  background: #f1f5f9;
  border-bottom: 1px solid #cbd5e1;
}

.adm-group-tab {
  padding: 5px 2px;
  border: 1px solid #cbd5e1;
  border-radius: 4px;
  background: #ffffff;
  color: #334155;
  font-size: 13px;
  font-weight: 800;
  cursor: pointer;
}

.adm-group-tab:hover {
  border-color: #2563eb;
  color: #1d4ed8;
}

.adm-group-tab.active {
  background: #1d4ed8;
  border-color: #1e40af;
  color: #ffffff;
}

#adm-univ-list {
  flex: 1;
  min-height: 0;
  overflow-y: auto;
  padding: 6px;
  display: flex;
  flex-direction: column;
  gap: 5px;
  background: #f8fafc;
}

.adm-dir-item {
  width: 100%;
  display: flex;
  align-items: center;
  gap: 9px;
  padding: 8px 9px;
  background: #ffffff;
  border: 1.5px solid #cbd5e1;
  border-radius: 6px;
  text-align: left;
  cursor: pointer;
  transition: border-color 0.12s ease, background 0.12s ease;
}

.adm-dir-item:hover {
  border-color: #2563eb;
  background: #f8fafc;
}

.adm-dir-item.active {
  border-color: #1d4ed8;
  background: #eff6ff;
  box-shadow: inset 3px 0 0 #1d4ed8;
}

.adm-dir-emblem {
  width: 34px;
  height: 34px;
  border-radius: 6px;
  color: #ffffff;
  font-size: 16px;
  font-weight: 900;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.adm-dir-info {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 3px;
}

.adm-dir-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 4px;
}

.adm-dir-name {
  font-size: 15px;
  font-weight: 900;
  color: #0f172a;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.adm-dir-status {
  font-size: 11px;
  font-weight: 800;
  padding: 1px 6px;
  border-radius: 10px;
  flex-shrink: 0;
}

.adm-dir-status.open {
  background: #dcfce7;
  color: #166534;
}

.adm-dir-status.urgent {
  background: #fee2e2;
  color: #b91c1c;
}

.adm-dir-meta {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 12px;
  color: #475569;
  font-weight: 700;
}

.adm-dir-group-pill {
  background: #e2e8f0;
  color: #1e293b;
  padding: 0 5px;
  border-radius: 3px;
  font-weight: 800;
}

/* CENTER COLUMN (40%): Department Competition Rate Table & Guidelines */
.adm-center-banner {
  flex-shrink: 0;
  background: linear-gradient(135deg, #1e293b 0%, #0f172a 100%);
  color: #ffffff;
  padding: 10px 14px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  border-bottom: 2px solid #2563eb;
}

.adm-center-banner-left {
  min-width: 0;
}

#adm-center-univ-title {
  font-size: 16px;
  font-weight: 900;
  color: #ffffff;
  margin-bottom: 3px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

#adm-center-univ-meta {
  font-size: 13px;
  color: #cbd5e1;
  font-weight: 600;
}

.adm-deadline-box {
  flex-shrink: 0;
  background: rgba(220, 38, 38, 0.18);
  border: 1.5px solid #f87171;
  border-radius: 6px;
  padding: 5px 10px;
  text-align: center;
}

.adm-deadline-label {
  display: block;
  font-size: 10.5px;
  color: #fecaca;
  font-weight: 700;
}

#adm-deadline-timer {
  font-family: 'JetBrains Mono', monospace;
  font-size: 17px;
  font-weight: 900;
  color: #fde047;
}

.adm-table-headbar {
  flex-shrink: 0;
  padding: 8px 12px;
  background: #f1f5f9;
  border-bottom: 1px solid #cbd5e1;
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 14.5px;
  font-weight: 900;
  color: #0f172a;
}

.adm-live-sync-tag {
  font-size: 12px;
  font-weight: 800;
  color: #dc2626;
}

.adm-table-container {
  flex: 1;
  min-height: 0;
  overflow-y: auto;
  padding: 8px 10px;
  background: #ffffff;
}

#adm-dept-table {
  width: 100%;
  border-collapse: collapse;
  border: 1px solid #cbd5e1;
  font-size: 14px;
}

#adm-dept-table th {
  background: #e2e8f0;
  color: #0f172a;
  font-weight: 900;
  font-size: 13px;
  padding: 9px 5px;
  border: 1px solid #cbd5e1;
  text-align: center;
  white-space: nowrap;
}

#adm-dept-table td {
  padding: 13px 6px;
  border: 1px solid #cbd5e1;
  color: #1e293b;
  font-weight: 600;
  vertical-align: middle;
}

#adm-dept-table tbody tr {
  cursor: pointer;
  transition: background 0.1s ease;
}

#adm-dept-table tbody tr:nth-child(even) {
  background: #f8fafc;
}

#adm-dept-table tbody tr:hover {
  background: #eff6ff;
}

#adm-dept-table tbody tr.selected-row {
  background: #dbeafe;
  outline: 2px solid #1d4ed8;
  outline-offset: -2px;
}

#adm-dept-table .col-radio,
#adm-dept-table .col-group,
#adm-dept-table .col-num {
  text-align: center;
  white-space: nowrap;
}

#adm-dept-table .col-college {
  font-size: 13px;
  color: #475569;
  text-align: center;
}

#adm-dept-table .col-dept {
  font-size: 15px;
  font-weight: 900;
  color: #0f172a;
}

#adm-dept-table .col-rate {
  text-align: center;
  font-family: 'JetBrains Mono', monospace;
  font-weight: 900;
  font-size: 14px;
  color: #dc2626;
  white-space: nowrap;
}

.tbl-group-tag {
  background: #e2e8f0;
  color: #0f172a;
  font-size: 12px;
  font-weight: 800;
  padding: 2px 6px;
  border-radius: 3px;
}

.adm-center-footer-boxes {
  flex-shrink: 0;
  padding: 8px 10px 10px;
  background: #f8fafc;
  border-top: 1.5px solid #cbd5e1;
  display: flex;
  flex-direction: column;
  gap: 7px;
}

.adm-info-box {
  border-radius: 6px;
  padding: 8px 11px;
  border: 1.5px solid #cbd5e1;
  background: #ffffff;
}

.adm-info-box.method {
  border-color: #93c5fd;
  background: #f0f9ff;
}

.adm-info-box.caution {
  border-color: #fca5a5;
  background: #fef2f2;
}

.adm-info-title {
  font-size: 14px;
  font-weight: 900;
  color: #0f172a;
  margin-bottom: 3px;
}

.adm-info-box.caution .adm-info-title {
  color: #991b1b;
}

.adm-info-box p {
  margin: 0;
  font-size: 12.5px;
  line-height: 1.45;
  color: #334155;
  font-weight: 600;
}

/* RIGHT COLUMN (38%): Common Application Form / 1.5s Lookup / Reject Table / Pass Canvas */
.admission-right-col {
  padding: 8px 11px;
  position: relative;
  background: #f8fafc;
}

#admission-toast {
  position: absolute;
  top: 52px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 25;
  background: rgba(15, 23, 42, 0.94);
  color: #fef08a;
  border: 1.5px solid #f59e0b;
  padding: 6px 14px;
  border-radius: 18px;
  font-size: 12.5px;
  font-weight: 800;
  max-width: calc(100% - 24px);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  box-shadow: 0 6px 18px rgba(0, 0, 0, 0.36);
}

#admission-toast.hidden {
  display: none;
}

.adm-state-panel {
  flex: 1;
  min-height: 0;
  display: flex;
  flex-direction: column;
}

.adm-state-panel.hidden {
  display: none;
}

/* State 1: Official Standard Common Application Form */
#admission-form-panel {
  background: #ffffff;
  border: 1.5px solid #94a3b8;
  border-radius: 5px;
  padding: 8px 10px;
  justify-content: space-between;
  gap: 6px;
}

.adm-form-doc-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  padding-bottom: 6px;
  border-bottom: 2px solid #0f172a;
}

.adm-doc-title-group {
  display: flex;
  align-items: center;
  gap: 6px;
  min-width: 0;
}

.adm-doc-status-badge {
  background: #1d4ed8;
  color: #ffffff;
  font-size: 11px;
  font-weight: 900;
  padding: 2px 6px;
  border-radius: 3px;
  flex-shrink: 0;
}

.adm-doc-title-group h3 {
  margin: 0;
  font-size: 16px;
  font-weight: 900;
  color: #0f172a;
  letter-spacing: -0.02em;
  white-space: nowrap;
}

.adm-barcode-box {
  flex-shrink: 0;
}

.adm-doc-section {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.adm-doc-sec-title {
  font-size: 13px;
  font-weight: 900;
  color: #1e3a8a;
  background: #eff6ff;
  border-left: 3.5px solid #1d4ed8;
  padding: 2px 7px;
}

.adm-profile-grid {
  display: flex;
  gap: 8px;
  align-items: stretch;
}

.adm-photo-frame {
  width: 58px;
  flex-shrink: 0;
  border: 1.5px solid #94a3b8;
  background: #f1f5f9;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
}

.adm-doc-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 13.5px;
}

.adm-doc-table th,
.adm-doc-table td {
  border: 1px solid #cbd5e1;
  padding: 5px 6px;
  text-align: left;
  vertical-align: middle;
  word-break: keep-all;
}

.adm-doc-table th {
  background: #f1f5f9;
  color: #334155;
  font-weight: 800;
  font-size: 12.5px;
  white-space: nowrap;
}

.adm-doc-table td {
  color: #0f172a;
  font-weight: 700;
  font-size: 13px;
}

.adm-doc-strong {
  font-size: 14.5px;
  font-weight: 900 !important;
  color: #1e3a8a !important;
}

.adm-highlight-cell {
  background: #fefce8;
}

.adm-consent-row {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 5px 8px;
  background: #f0fdf4;
  border: 1px solid #86efac;
  border-radius: 4px;
  font-size: 12.5px;
  font-weight: 800;
  color: #166534;
}

.adm-check-box {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 16px;
  height: 16px;
  border-radius: 3px;
  background: #16a34a;
  color: #ffffff;
  font-size: 11px;
  font-weight: 900;
  flex-shrink: 0;
}

.adm-sign-section {
  background: #f8fafc;
  border: 1px solid #cbd5e1;
  border-radius: 5px;
  padding: 7px 8px;
}

.adm-fee-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 13px;
  color: #0f172a;
  padding: 2px 0;
}

.adm-fee-paid {
  background: #dcfce7;
  color: #166534;
  font-size: 11.5px;
  font-weight: 800;
  padding: 2px 7px;
  border-radius: 10px;
}

.adm-oath-text {
  margin: 0;
  font-size: 12px;
  line-height: 1.4;
  color: #475569;
  font-weight: 600;
}

#btn-apply-univ {
  width: 100%;
  margin-top: 2px;
  padding: 11px 12px;
  border: none;
  border-radius: 6px;
  background: linear-gradient(135deg, #1d4ed8 0%, #0f172a 100%);
  color: #ffffff;
  font-size: 15px;
  font-weight: 900;
  cursor: pointer;
  box-shadow: 0 4px 12px rgba(29, 78, 216, 0.35);
}

#btn-apply-univ:hover {
  filter: brightness(1.09);
}

/* State 2: 1.5s Lookup Loading Card */
.adm-loading-card,
.adm-fail-card {
  margin: auto;
  width: 100%;
  max-width: 440px;
  padding: 24px 20px;
  border-radius: 8px;
  background: #ffffff;
  border: 1.5px solid #cbd5e1;
  text-align: center;
  box-shadow: 0 6px 20px rgba(15, 23, 42, 0.08);
}

.adm-spinner {
  width: 42px;
  height: 42px;
  margin: 0 auto 12px;
  border-radius: 50%;
  border: 4px solid #dbeafe;
  border-top-color: #1d4ed8;
  animation: admSpin 0.8s linear infinite;
}

@keyframes admSpin {
  to {
    transform: rotate(360deg);
  }
}

.adm-loading-serial {
  display: inline-block;
  font-family: 'JetBrains Mono', monospace;
  font-size: 12px;
  font-weight: 800;
  color: #1d4ed8;
  background: #eff6ff;
  border: 1px solid #93c5fd;
  padding: 2px 10px;
  border-radius: 12px;
  margin-bottom: 8px;
}

.adm-loading-card h3 {
  margin: 0 0 6px;
  font-size: 16px;
  font-weight: 900;
  color: #0f172a;
}

.adm-loading-card p {
  margin: 0 0 14px;
  font-size: 14px;
  color: #475569;
  font-weight: 600;
}

.adm-loading-track {
  width: 100%;
  height: 10px;
  background: #e2e8f0;
  border-radius: 5px;
  overflow: hidden;
}

#adm-loading-fill {
  width: 0%;
  height: 100%;
  background: linear-gradient(90deg, #1d4ed8, #0284c7, #16a34a);
}

/* State 3: Formal Rejection Result Notice */
.adm-fail-card {
  max-width: 100%;
  padding: 16px;
  border: 2px solid #94a3b8;
  text-align: left;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.adm-fail-header-bar {
  background: #1e293b;
  color: #f8fafc;
  font-size: 13px;
  font-weight: 800;
  padding: 6px 10px;
  border-radius: 4px;
  text-align: center;
}

#adm-fail-title {
  margin: 0;
  font-size: 15.5px;
  font-weight: 900;
  color: #991b1b;
  text-align: center;
}

.adm-result-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 14px;
}

.adm-result-table th,
.adm-result-table td {
  border: 1px solid #cbd5e1;
  padding: 8px 10px;
}

.adm-result-table th {
  width: 34%;
  background: #f1f5f9;
  color: #334155;
  font-weight: 800;
}

.adm-result-reject {
  color: #dc2626;
  font-weight: 900;
  background: #fef2f2;
}

#adm-fail-desc {
  margin: 0;
  font-size: 13.5px;
  line-height: 1.5;
  color: #334155;
  background: #f8fafc;
  padding: 9px 10px;
  border: 1px solid #cbd5e1;
  border-radius: 4px;
}

.adm-fail-actions {
  display: flex;
  flex-direction: column;
  gap: 7px;
}

.adm-btn-reapply,
.adm-btn-ending {
  padding: 11px 12px;
  border-radius: 6px;
  font-size: 14px;
  font-weight: 900;
  cursor: pointer;
}

.adm-btn-reapply {
  border: none;
  background: #1d4ed8;
  color: #ffffff;
}

.adm-btn-ending {
  border: 1.5px solid #1e293b;
  background: #0f172a;
  color: #f8fafc;
}

/* State 4: Pass Certificate Showcase */
#admission-pass-panel {
  gap: 7px;
}

.adm-pass-toprow {
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 6px;
}

#adm-pass-headline {
  flex: 1;
  padding: 6px 10px;
  border-radius: 5px;
  background: linear-gradient(90deg, #fef3c7, #fde68a);
  border: 1.5px solid #f59e0b;
  color: #78350f;
  font-size: 14px;
  font-weight: 900;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

#btn-pass-back-form {
  flex-shrink: 0;
  padding: 6px 10px;
  border-radius: 5px;
  border: 1.5px solid #94a3b8;
  background: #ffffff;
  color: #1e293b;
  font-size: 12.5px;
  font-weight: 800;
  cursor: pointer;
}

.adm-canvas-stage {
  flex: 1;
  min-height: 0;
  background: #0f172a;
  border-radius: 6px;
  padding: 6px;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
}

#admission-cert-canvas {
  max-width: 100%;
  max-height: 100%;
  width: auto;
  height: auto;
  aspect-ratio: 800 / 1050;
  border-radius: 2px;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.5);
}

.adm-cert-actions {
  flex-shrink: 0;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 6px;
}

.adm-action-btn {
  padding: 8px 8px;
  border-radius: 6px;
  border: 1.5px solid #cbd5e1;
  background: #ffffff;
  color: #0f172a;
  font-size: 12.5px;
  font-weight: 800;
  line-height: 1.25;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
}

.adm-action-btn:hover {
  background: #f1f5f9;
}

.adm-action-btn.primary {
  border-color: #16a34a;
  background: #16a34a;
  color: #ffffff;
}

.adm-action-btn.danger-ending {
  border-color: #991b1b;
  background: linear-gradient(135deg, #18181b 0%, #7f1d1d 100%);
  color: #fef2f2;
}
