* {
  box-sizing: border-box;
}

:root {
  --gold: #ead47d;
  --gold2: #b99342;
  --bg: #030303;
  --ink: #fff4cf;
  --muted: #cdbf91;
  --panel: rgba(0, 0, 0, 0.78);
  --panel2: rgba(10, 8, 5, 0.9);
  --red: #d83a35;
  --amber1: #a84d1c;
  --amber2: #c47720;
  --amber3: #d9ad38;
  --green: #39c76d;
  --orange: #ff9f1c;
  --line: rgba(234, 212, 125, 0.34);
}

html,
body {
  margin: 0;
  background: #000;
  color: var(--ink);
  font-family: Impact, Haettenschweiler, "Arial Narrow Bold", sans-serif;
  letter-spacing: 1px;
  overflow-x: hidden;
}

body {
  min-height: 100vh;
}

button,
input {
  font-family: inherit;
}

button {
  cursor: pointer;
  border: 0;
}

.screen {
  min-height: 100vh;
  background-size: cover;
  background-position: center;
  position: relative;
  padding: 24px 16px 34px;
}

.screen::before {
  content: "";
  position: absolute;
  inset: 0;
  background:
    radial-gradient(circle at top, rgba(234, 212, 125, 0.08), transparent 28%),
    linear-gradient(rgba(0, 0, 0, 0.64), rgba(0, 0, 0, 0.9));
  z-index: 0;
}

.content {
  position: relative;
  z-index: 1;
  max-width: 980px;
  margin: 0 auto;
}

.tight {
  max-width: 720px;
}

h1 {
  font-size: clamp(64px, 16vw, 140px);
  line-height: 0.86;
  margin: 46px 0 12px;
  color: var(--gold);
  text-shadow: 0 0 30px rgba(0, 0, 0, 0.9);
}

h2 {
  font-size: clamp(26px, 7vw, 52px);
  line-height: 1;
  margin: 10px 0;
  color: var(--gold);
}

h3 {
  font-size: 25px;
  margin: 8px 0;
  color: var(--ink);
}

p,
li,
label {
  font-family: Arial, sans-serif;
  letter-spacing: 0;
  font-size: 17px;
  line-height: 1.45;
}

.small {
  font-family: Arial, sans-serif;
  font-size: 13px;
  letter-spacing: 0;
  color: var(--muted);
}

.panel {
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: 24px;
  padding: 18px;
  margin: 16px 0;
  box-shadow: 0 0 36px rgba(0, 0, 0, 0.45);
}

.panel.dark {
  background: var(--panel2);
}

.panel.reveal {
  border: 2px solid var(--gold);
  background:
    radial-gradient(circle at top, rgba(234, 212, 125, 0.18), transparent 45%),
    rgba(0, 0, 0, 0.86);
  box-shadow: 0 0 44px rgba(234, 212, 125, 0.2);
  animation: revealPulse 1.8s ease-in-out infinite alternate;
}

@keyframes revealPulse {
  from {
    box-shadow: 0 0 20px rgba(234, 212, 125, 0.12);
  }

  to {
    box-shadow: 0 0 52px rgba(234, 212, 125, 0.32);
  }
}

.primary,
.secondary,
.ghost {
  width: 100%;
  padding: 17px;
  border-radius: 22px;
  margin-top: 14px;
  font-size: clamp(20px, 5.5vw, 32px);
  letter-spacing: 3px;
}

.primary {
  background: linear-gradient(#f3dd88, #b99142);
  color: #080808;
  border: 2px solid #e6cd76;
}

.secondary {
  background: rgba(0, 0, 0, 0.48);
  color: var(--gold);
  border: 2px solid var(--gold);
}

.ghost {
  background: rgba(255, 255, 255, 0.06);
  color: var(--ink);
  border: 1px solid rgba(255, 255, 255, 0.2);
}

.button-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}

.statgrid {
  display: grid;
  grid-template-columns: 1.25fr 1fr;
  gap: 10px;
}

.stat {
  border: 2px solid rgba(234, 212, 125, 0.45);
  border-radius: 22px;
  padding: 12px;
  min-height: 94px;
  background: rgba(0, 0, 0, 0.58);
}

.stat .label {
  font-size: 17px;
  color: var(--ink);
}

.stat .value {
  font-size: clamp(22px, 6vw, 31px);
  color: var(--gold);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.case-list {
  display: grid;
  gap: 12px;
}

.case-pill {
  border: 1px solid rgba(234, 212, 125, 0.35);
  border-radius: 18px;
  padding: 14px;
  background: rgba(0, 0, 0, 0.45);
}

.case-pill.done {
  border-color: var(--green);
}

.topbar {
  position: sticky;
  top: 0;
  left: 0;
  right: 0;
  z-index: 999;
  background: rgba(0, 0, 0, 0.96);
  border-bottom: 1px solid var(--line);
  padding: max(10px, env(safe-area-inset-top)) 10px 8px;
  backdrop-filter: blur(10px);
}

.hudrow {
  display: grid;
  grid-template-columns: 1.4fr 0.65fr 1.15fr;
  gap: 8px;
  text-align: center;
  color: var(--gold);
}

.hudcell {
  border: 1px solid rgba(234, 212, 125, 0.22);
  border-radius: 12px;
  padding: 6px 4px;
  background: rgba(255, 255, 255, 0.04);
}

.hudlabel {
  display: block;
  font-family: Arial, sans-serif;
  letter-spacing: 0;
  font-size: 10px;
  color: var(--muted);
}

.hudvalue {
  display: block;
  font-size: clamp(13px, 3.8vw, 18px);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.theory-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
  margin: 14px 0;
}

.theory-card {
  border: 1px solid rgba(234, 212, 125, 0.28);
  background: rgba(0, 0, 0, 0.68);
  border-radius: 16px;
  padding: 10px;
  min-height: 74px;
}

.theory-card h4 {
  margin: 0 0 6px;
  color: var(--gold);
  font-size: 19px;
}

.theory-card p {
  margin: 0;
  font-size: 14px;
  color: var(--ink);
}

.evidence-board {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
}

.evidence-box {
  border: 1px solid rgba(234, 212, 125, 0.28);
  border-radius: 16px;
  padding: 10px;
  background: rgba(0, 0, 0, 0.68);
  min-height: 76px;
}

.evidence-box h4 {
  margin: 0 0 6px;
  color: var(--gold);
  font-size: 16px;
}

.evidence-tag {
  display: inline-block;
  margin: 3px;
  padding: 5px 8px;
  border-radius: 999px;
  background: #113d23;
  border: 1px solid var(--green);
  font-family: Arial, sans-serif;
  font-size: 12px;
  letter-spacing: 0;
}

.progress-shell {
  height: 24px;
  border-radius: 999px;
  border: 1px solid rgba(234, 212, 125, 0.35);
  background: #111;
  overflow: hidden;
  margin: 14px 0;
}

.progress-bar {
  height: 100%;
  width: 0%;
  border-radius: 999px;
  transition: width 1.35s ease, background 0.25s;
}

.progress-label {
  font-size: 25px;
  color: var(--gold);
  text-align: center;
  margin-top: 4px;
}

.carousel-block {
  margin: 20px 0;
  background: rgba(0, 0, 0, 0.5);
  border: 1px solid rgba(234, 212, 125, 0.25);
  border-radius: 22px;
  padding: 12px 0 16px;
  overflow: hidden;
}

.carousel-title {
  font-size: clamp(31px, 8vw, 52px);
  color: var(--gold);
  margin: 0 16px 8px;
}

.carousel-wrap {
  position: relative;
}

/* A fixed marker at dead centre of the carousel viewport -- unlike the
   cards, it never scrolls, so it's always obvious which slot is "in
   focus" even mid-fast-scroll, before any card has settled there. Sits
   ABOVE the cards (z-index higher than .carousel).
   Deliberately NOT a rounded-rectangle outline: every card already has
   one of those (its own border), so a second one just reads as visual
   noise/another card edge, not a distinct "frame" indicator. Four
   L-shaped corner brackets -- a camera-viewfinder/focus-target look --
   are unambiguously a different kind of mark than a card's own border,
   at any rotation the card's rounded corners might be at. */
.carousel-frame {
  position: absolute;
  top: 2px;
  bottom: 10px;
  left: 50%;
  width: 240px;
  transform: translateX(-50%);
  pointer-events: none;
  z-index: 2;
}

.carousel-frame::before,
.carousel-frame::after,
.frame-corner-tr,
.frame-corner-br {
  content: "";
  position: absolute;
  width: 34px;
  height: 34px;
  border: 4px solid var(--ink);
  filter: drop-shadow(0 0 8px rgba(255, 244, 207, 0.55));
}

.carousel-frame::before {
  top: -3px;
  left: -3px;
  border-right: 0;
  border-bottom: 0;
  border-top-left-radius: 14px;
}

.carousel-frame::after {
  bottom: -3px;
  left: -3px;
  border-right: 0;
  border-top: 0;
  border-bottom-left-radius: 14px;
}

.frame-corner-tr {
  top: -3px;
  right: -3px;
  border-left: 0;
  border-bottom: 0;
  border-top-right-radius: 14px;
}

.frame-corner-br {
  bottom: -3px;
  right: -3px;
  border-left: 0;
  border-top: 0;
  border-bottom-right-radius: 14px;
}

.carousel {
  /* No scroll-snap-type here on purpose: JS (settleCarousel(), fired once
     scrolling stops -- see script.js) is now the sole thing responsible
     for precisely centring a card, firing the lock + haptic once it has.
     CSS scroll-snap running at the same time fights it -- it can silently
     re-adjust a JS-assigned scrollLeft towards its own idea of the
     nearest snap point, so a corrective assignment only partially lands
     and the two systems fight to a stalemate instead of converging. */
  position: relative;
  z-index: 1;
  display: flex;
  overflow-x: auto;
  gap: 46px;
  scroll-behavior: auto;
  padding: 12px 34px 20px;
  -webkit-overflow-scrolling: touch;
  overscroll-behavior-x: contain;
  perspective: 900px;
}

.carousel::-webkit-scrollbar {
  display: none;
}

/* Cards tilt/recede on a curve as they move from centre (--dist, set
   continuously by updateLiveCards()) -- a fan/reel look, not a flat strip.
   Deliberately simpler than the true rotating-ring version that was tried
   and reverted (it broke rendering entirely on Safari, which is untestable
   in this environment -- only Chromium is available here): a single
   element, no card-back/flip, no split scroll+3D containers, no
   pointer-events surgery. rotateY is capped well short of 90deg so a card
   never goes edge-on/reveals a "back" that doesn't exist, and
   transform-style stays at its flat default since there's no child that
   needs its own 3D position -- opacity/filter/border-color can all live
   directly on .card because of that (only a *preserve-3d* element's
   descendants are at risk of the opacity/filter-forces-flat rule). */
.card {
  flex: 0 0 228px;
  min-height: 404px;
  background: #070707;
  border: 3px solid rgba(234, 212, 125, 0.38);
  border-radius: 22px;
  padding: 10px;
  touch-action: pan-x;
  --card-scale: 0.92;
  --card-opacity: 0.78;
  --card-brightness: 0.9;
  --card-rotate: rotateY(clamp(-55deg, calc(var(--dist, 0) * 24deg), 55deg));
  --card-depth: translateZ(calc(-1 * min(var(--dist-abs, 0), 2.2) * 40px));
  transform: var(--card-rotate) var(--card-depth) scale(var(--card-scale));
  opacity: var(--card-opacity);
  filter: brightness(var(--card-brightness)) saturate(0.92);
  /* ease-out, no overshoot: this is the transition for every continuous,
     scroll-driven --dist change (a handful of times a second while
     scrolling). A bouncy easing here was overshooting on *every* one of
     those, not just the deliberate lock/select moment, which is what read
     as jittering / odd-looking angles while actively scrolling. The
     deliberate bounce lives only in .card.popping's animation below,
     which is scoped to the two discrete moments that should feel like a
     decisive pop: settling into the frame, and being tapped to select. */
  transition:
    transform 0.15s ease-out,
    opacity 0.12s,
    filter 0.12s,
    border-color 0.12s,
    box-shadow 0.12s;
}

.card.live {
  --card-scale: 1.02;
  --card-opacity: 1;
  --card-brightness: 1.05;
  border-color: var(--gold);
}

/* Fired by settleCarousel() the moment a card is confirmed centred in
   .carousel-frame, and by selectCard() the moment a tap selects a card --
   the two moments that should feel like a deliberate "it just locked in",
   not a passive drift. A CSS *animation* (not the .card transition above)
   so its bounce is scoped to just these moments: an animation on the same
   property as an active transition wins for as long as it's running, so
   this doesn't fight the calm transition used while actively scrolling.
   The keyframes re-state rotate/depth from the same --card-rotate/
   --card-depth custom properties .card itself uses, so the card's current
   tilt carries through the bounce instead of snapping flat for its
   duration. */
.card.locked,
.card.popping {
  animation: cardPop 0.32s cubic-bezier(0.34, 1.56, 0.64, 1);
}

@keyframes cardPop {
  0% {
    transform: var(--card-rotate) var(--card-depth) scale(calc(var(--card-scale) * 0.94));
    filter: brightness(calc(var(--card-brightness) * 1.35)) saturate(0.92);
    box-shadow: 0 0 0 3px rgba(234, 212, 125, 0.85), 0 0 34px rgba(234, 212, 125, 0.55);
  }
  60% {
    transform: var(--card-rotate) var(--card-depth) scale(calc(var(--card-scale) * 1.05));
  }
  100% {
    transform: var(--card-rotate) var(--card-depth) scale(var(--card-scale));
    filter: brightness(var(--card-brightness)) saturate(0.92);
    box-shadow: none;
  }
}

/* 1.05 is deliberate, not just "a bit bigger than live's 1.02": at the
   card's 228px base width and the frame's 240px width, this is what
   actually brings the card out to meet the frame's edges -- picking a
   card should visibly fill the frame, not just look slightly larger than
   its neighbours. */
.card.selected {
  --card-scale: 1.05;
  --card-opacity: 1;
  --card-brightness: 1.08;
  border-color: var(--orange);
  box-shadow: 0 0 24px rgba(255, 159, 28, 0.3);
}

.card.correct {
  --card-scale: 1.05;
  --card-opacity: 1;
  --card-brightness: 1.16;
  border-color: var(--green);
  box-shadow: 0 0 24px rgba(57, 199, 109, 0.34);
}

.card.incorrect {
  border-color: var(--red);
  --card-opacity: 0.48;
  --card-brightness: 0.66;
}

.card img {
  width: 100%;
  height: 178px;
  object-fit: contain;
  object-position: center;
  border-radius: 14px;
  background: #000;
  border: 1px solid rgba(234, 212, 125, 0.18);
}

.card img.contain {
  object-fit: contain;
  padding: 0;
}
.playable-attributes,
.details {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 5px;
}

.attribute-heading {
  font-family: Arial, sans-serif;
  letter-spacing: 0;
  font-size: 12px;
  font-weight: 700;
  color: var(--muted);
  text-align: center;
  margin: 9px 0 6px;
}

.playable-attribute,
.detail {
  font-family: Arial, sans-serif;
  letter-spacing: 0;
  font-weight: 700;
  font-size: 11px;
  padding: 4px 5px;
  border: 1px solid rgba(234, 212, 125, 0.35);
  border-radius: 999px;
  text-align: center;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.playable-attribute.revealed,
.detail.revealed {
  background: #14532d;
  border-color: var(--green);
  color: #fff;
}

.bottomhud {
  position: sticky;
  bottom: 0;
  z-index: 50;
  margin: 18px -16px -34px;
  padding: 12px 16px calc(16px + env(safe-area-inset-bottom));
  background: linear-gradient(rgba(0, 0, 0, 0.72), rgba(0, 0, 0, 0.97));
  border-top: 1px solid var(--line);
  backdrop-filter: blur(10px);
}

.feedback-grid {
  display: grid;
  gap: 8px;
}

.feedback-line {
  border: 1px solid rgba(234, 212, 125, 0.24);
  border-radius: 14px;
  padding: 9px;
  background: rgba(0, 0, 0, 0.65);
  font-family: Arial, sans-serif;
  font-size: 13px;
  letter-spacing: 0;
}

.feedback-line b {
  font-family: Impact, Haettenschweiler, "Arial Narrow Bold", sans-serif;
  letter-spacing: 1px;
  color: var(--gold);
  font-size: 17px;
}

.green {
  color: var(--green);
}

.red {
  color: var(--red);
}

.result-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
  align-items: stretch;
}

.result-card {
  border: 1px solid rgba(234, 212, 125, 0.45);
  border-radius: 20px;
  padding: 10px;
  background: rgba(0, 0, 0, 0.72);
  min-height: 228px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}

.result-card img {
  width: 100%;
  aspect-ratio: 1 / 1;
  object-fit: contain;
  border-radius: 12px;
  background: #000;
}

.result-card img.contain {
  object-fit: contain;
  padding: 6px;
}

.result-card h2 {
  font-size: clamp(22px, 6vw, 35px);
  margin: 8px 0 2px;
}

.result-card p {
  margin: 0;
  font-size: 14px;
}

.end-title {
  font-size: clamp(48px, 13vw, 118px);
  line-height: 0.86;
  color: var(--gold);
  margin: 42px 0 10px;
}

.subtitle {
  font-size: clamp(25px, 7vw, 56px);
  color: var(--ink);
  margin-bottom: 14px;
}

.name-input {
  width: 100%;
  padding: 16px;
  border-radius: 18px;
  border: 2px solid var(--gold);
  background: #090909;
  color: var(--ink);
  font-size: 26px;
  letter-spacing: 1px;
  text-align: center;
}

.toggle-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  padding: 14px;
  border: 1px solid rgba(234, 212, 125, 0.28);
  border-radius: 16px;
  background: rgba(0, 0, 0, 0.45);
  margin: 10px 0;
}

.switch {
  width: 58px;
  height: 32px;
  border-radius: 999px;
  border: 1px solid var(--line);
  background: #222;
  position: relative;
  flex: 0 0 auto;
}

.switch::before {
  content: "";
  position: absolute;
  width: 24px;
  height: 24px;
  border-radius: 50%;
  left: 4px;
  top: 3px;
  background: #777;
  transition: 0.2s;
}

.switch.on {
  background: #123d23;
  border-color: var(--green);
}

.switch.on::before {
  left: 28px;
  background: var(--green);
}

.overlay {
  position: fixed;
  inset: 0;
  z-index: 2000;
  background: rgba(0, 0, 0, 0.92);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
}

.loader-card {
  width: min(620px, 100%);
  background: var(--panel2);
  border: 1px solid var(--line);
  border-radius: 28px;
  padding: 22px;
  text-align: center;
  box-shadow: 0 0 80px rgba(0, 0, 0, 0.8);
}

.loader-title {
  font-size: clamp(32px, 9vw, 62px);
  color: var(--gold);
  line-height: 1;
  margin: 0 0 14px;
}

.loader-text {
  font-family: Arial, sans-serif;
  letter-spacing: 0;
  color: var(--muted);
  font-size: 16px;
}

.email-note {
  font-family: Arial, sans-serif;
  letter-spacing: 0;
  color: var(--muted);
  font-size: 14px;
  margin-top: 8px;
}

.prologue-banner {
  border: 2px solid var(--gold);
  box-shadow: 0 0 30px rgba(234, 212, 125, 0.18);
  background: linear-gradient(180deg, rgba(234, 212, 125, 0.13), rgba(0, 0, 0, 0.75));
}

.season-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin-top: 10px;
}

.season-case-row {
  text-align: left;
}

.info-tabs {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 8px;
}

.info-tabs button {
  padding: 10px 6px;
  border-radius: 14px;
  background: rgba(0, 0, 0, 0.55);
  color: var(--gold);
  border: 1px solid var(--line);
  font-size: 14px;
}

.info-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 12px;
}

.info-entry {
  display: grid;
  grid-template-columns: 92px 1fr;
  gap: 12px;
  align-items: start;
  border: 1px solid rgba(234, 212, 125, 0.24);
  border-radius: 18px;
  padding: 10px;
  background: rgba(0, 0, 0, 0.56);
}

.info-entry img {
  width: 92px;
  height: 92px;
  border-radius: 12px;
  object-fit: cover;
  background: #000;
}

.info-entry img.contain {
  object-fit: contain;
  padding: 5px;
}

.vault-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(96px, 1fr));
  gap: 10px;
  margin-top: 10px;
}

.vault-item {
  position: relative;
  border: 1px solid rgba(234, 212, 125, 0.28);
  border-radius: 14px;
  padding: 8px;
  background: rgba(0, 0, 0, 0.5);
  text-align: center;
}

.vault-item img {
  width: 100%;
  aspect-ratio: 1 / 1;
  object-fit: cover;
  border-radius: 10px;
  background: #000;
}

.vault-item p {
  font-size: 11px;
  margin: 6px 0 0;
  color: var(--muted);
}

.vault-item.locked img {
  opacity: 0.25;
  filter: grayscale(1);
}

.vault-lock {
  display: block;
  font-size: 10px;
  letter-spacing: 1px;
  color: var(--muted);
  margin-top: 4px;
}

.promotion-panel {
  text-align: center;
}

.certificate-img {
  width: 100%;
  max-width: 260px;
  aspect-ratio: 4 / 3;
  object-fit: cover;
  border-radius: 14px;
  margin: 10px auto;
  display: block;
  border: 2px solid var(--gold);
}

.certificate-name {
  font-size: clamp(22px, 6vw, 30px);
  color: var(--gold);
  margin: 4px 0;
}

.info-entry h3 {
  margin-top: 0;
}

.audit-table {
  display: grid;
  gap: 8px;
}

.audit-row {
  border: 1px solid rgba(234, 212, 125, 0.24);
  border-radius: 14px;
  padding: 10px;
  background: rgba(0, 0, 0, 0.58);
}

mark {
  background: rgba(234, 212, 125, 0.22);
  color: var(--gold);
  padding: 0 6px;
  border-radius: 6px;
}

@media (min-width: 760px) {
  .statgrid {
    grid-template-columns: repeat(4, 1fr);
  }

  .card {
    flex-basis: 242px;
  }

  .card img {
    height: 188px;
    object-fit: contain;
  }

  .playable-attribute,
  .detail {
    font-size: 12px;
  }

  .feedback-grid {
    grid-template-columns: 1fr 1fr;
  }

  .carousel {
    padding-left: 60px;
    padding-right: 60px;
  }

  .bottomhud {
    margin-left: 0;
    margin-right: 0;
    border-radius: 24px 24px 0 0;
  }

  .info-grid {
    grid-template-columns: 1fr 1fr;
  }
}

@media (max-width: 480px) {
  .card img {
    height: 128px;
    object-fit: contain;
  }

  .button-row {
    grid-template-columns: 1fr;
  }

  .evidence-board {
    grid-template-columns: 1fr;
  }

  .result-grid {
    grid-template-columns: 1fr 1fr;
  }

  .card {
    flex-basis: 168px;
    min-height: 340px;
  }

  .primary,
  .secondary,
  .ghost {
    letter-spacing: 2px;
  }
}


/* V2.2 coded pass */

.investigation-screen {
  background-image:
    linear-gradient(rgba(0, 0, 0, 0.78), rgba(0, 0, 0, 0.9)),
    url("assets/investigation/investigation.jpg") !important;
  background-size: cover;
  background-position: center;
}

.information-screen {
  background-image:
    linear-gradient(rgba(0, 0, 0, 0.78), rgba(0, 0, 0, 0.9)),
    url("assets/casefile/casefile.PNG") !important;
  background-size: cover;
  background-position: center;
}

.result-screen {
  background-image:
    linear-gradient(rgba(0, 0, 0, 0.75), rgba(0, 0, 0, 0.9)),
    url("assets/caseclosed/caseclosed.PNG") !important;
  background-size: cover;
  background-position: center;
}

.investigation-content {
  padding-top: 116px;
}

.compact-hud {
  position: fixed;
}

.hudline {
  color: var(--gold);
  text-align: center;
  font-size: 18px;
  margin-bottom: 6px;
}

.hudselections {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 5px;
  font-family: Arial, sans-serif;
  font-size: 11px;
  letter-spacing: 0;
  color: var(--ink);
}

.hudselections span {
  border: 1px solid rgba(234, 212, 125, 0.2);
  border-radius: 9px;
  padding: 5px;
  background: rgba(255,255,255,0.04);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.sticky-return {
  position: sticky;
  top: 0;
  z-index: 1000;
  padding: max(8px, env(safe-area-inset-top)) 16px 4px;
  background: linear-gradient(rgba(0,0,0,0.96), rgba(0,0,0,0.72));
  backdrop-filter: blur(8px);
  margin: -24px -16px 12px;
}

.sticky-return .secondary {
  margin-top: 0;
}

.info-tabs button.active {
  background: linear-gradient(#f3dd88, #b99142);
  color: #080808;
}

.info-content {
  padding-bottom: 30px;
}

.info-entry {
  transition: transform 0.16s ease, border-color 0.16s ease, box-shadow 0.16s ease;
}

.info-entry.expanded {
  border-color: var(--gold);
  box-shadow: 0 0 22px rgba(234, 212, 125, 0.18);
}

.info-image-button {
  padding: 0;
  background: transparent;
  border: 0;
  width: 92px;
  height: 92px;
}

.info-image-button img,
.info-entry img {
  width: 92px;
  height: 92px;
  object-fit: contain;
  background: #000;
}

.feedback-line.confirmed {
  border-color: var(--green);
  box-shadow: 0 0 18px rgba(57, 199, 109, 0.24);
}

.card img {
  object-fit: contain;
  object-position: center;
}

.card-role {
  display: none;
}


/* V2.4 root progression fix */

.home-screen {
  background-image:
    linear-gradient(rgba(0, 0, 0, 0.34), rgba(0, 0, 0, 0.84)),
    url("assets/frontpage/frontpage.PNG") !important;
  background-size: cover;
  background-position: center top;
}

.home-spacer {
  min-height: 34vh;
}

.result-screen {
  background-image:
    linear-gradient(rgba(0, 0, 0, 0.75), rgba(0, 0, 0, 0.9)),
    url("assets/caseclosed/caseclosed.PNG") !important;
  background-size: cover;
  background-position: center;
}

.investigation-screen {
  background-image:
    linear-gradient(rgba(0, 0, 0, 0.78), rgba(0, 0, 0, 0.9)),
    url("assets/investigation/investigation.jpg") !important;
}

.information-screen {
  background-image:
    linear-gradient(rgba(0, 0, 0, 0.78), rgba(0, 0, 0, 0.9)),
    url("assets/casefile/casefile.PNG") !important;
}

.info-entry {
  width: 100%;
  color: var(--ink);
  font: inherit;
  text-align: left;
  cursor: pointer;
}

.info-expanded {
  display: none;
}

.info-entry.expanded .info-expanded {
  display: block;
}

.info-tabs {
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 6px;
}

.info-tabs button {
  font-size: 12px;
  padding: 10px 3px;
  letter-spacing: 0;
}

.feedback-line.confirmed {
  border-color: var(--green);
  box-shadow: 0 0 18px rgba(57, 199, 109, 0.24);
  background: rgba(20, 83, 45, 0.42);
}

.end-buttons {
  margin-top: 24px;
}

.progress-bar {
  transition: width 1.35s ease, background 0.25s;
}
