
:root {
  --bg: #000000;
  --text: #f4f1e8;
  --gold: #f4b13d;
  --gold-dark: #d6901b;
  --panel: rgba(10, 10, 10, 0.9);
  --panel-soft: rgba(20, 20, 20, 0.78);
  --danger: #ff6666;
  --success: #6eff93;
  --muted: #cfc7b5;
  --shadow: 0 18px 40px rgba(0, 0, 0, 0.45);
}

* {
  box-sizing: border-box;
}

html,
body {
  margin: 0;
  min-height: 100%;
  background: var(--bg);
  color: var(--text);
  font-family: Georgia, "Times New Roman", serif;
}

body {
  overflow-x: hidden;
}

button,
input {
  font: inherit;
}

a {
  color: var(--gold);
}

img {
  max-width: 100%;
  display: block;
}

#app {
  min-height: 100vh;
}

/* Shared */
.screen {
  min-height: 100vh;
  width: 100%;
  background: #000;
  color: var(--text);
}

.center-screen {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 32px 20px;
  text-align: center;
}

.game-button {
  appearance: none;
  border: 2px solid var(--gold);
  background: linear-gradient(180deg, #1b1b1b 0%, #0f0f0f 100%);
  color: var(--text);
  padding: 14px 26px;
  border-radius: 10px;
  cursor: pointer;
  box-shadow: var(--shadow);
  transition: transform 120ms ease, border-color 120ms ease, background 120ms ease;
  min-width: 220px;
}

.game-button:hover {
  transform: translateY(-2px);
  border-color: #ffd36f;
}

.game-button:disabled {
  opacity: 0.5;
  cursor: not-allowed;
  transform: none;
}

.secondary-button {
  border-color: #d9d2c5;
}

.menu-stack,
.button-stack {
  display: flex;
  flex-direction: column;
  gap: 14px;
  align-items: center;
}

.title-card {
  background: var(--panel-soft);
  padding: 24px;
  border-radius: 18px;
  box-shadow: var(--shadow);
  border: 1px solid rgba(255, 255, 255, 0.12);
}

/* HUD */
.top-hud {
  position: fixed;
  top: 14px;
  left: 14px;
  right: 14px;
  display: flex;
  justify-content: space-between;
  gap: 12px;
  z-index: 20;
  pointer-events: none;
}

.hud-pill {
  pointer-events: auto;
  background: rgba(10, 10, 10, 0.82);
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 999px;
  padding: 10px 16px;
  box-shadow: var(--shadow);
  font-size: 15px;
}

.hud-right {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 10px;
}

/* Intro */
.intro-screen {
  position: relative;
  background: #000 url("FINAL Intro Screen.png") no-repeat center center;
  background-size: contain;
}

.intro-overlay {
  min-height: 100vh;
  background: linear-gradient(
    180deg,
    rgba(0, 0, 0, 0.22) 0%,
    rgba(0, 0, 0, 0.15) 40%,
    rgba(0, 0, 0, 0.7) 74%,
    rgba(0, 0, 0, 0.92) 100%
  );
  display: flex;
  align-items: flex-end;
  justify-content: center;
  padding: 24px 20px 32px;
}

.main-menu {
  width: min(760px, 92vw);
  display: flex;
  justify-content: center;
}

.main-menu .menu-stack {
  align-items: flex-start;
  background: rgba(5, 5, 5, 0.52);
  border-radius: 18px;
  padding: 24px 28px;
  backdrop-filter: blur(3px);
}

.menu-option {
  appearance: none;
  border: none;
  background: transparent;
  color: #f1e5cb;
  font-size: clamp(28px, 2.6vw, 46px);
  font-weight: 700;
  text-shadow: 0 4px 12px rgba(0, 0, 0, 0.9);
  cursor: pointer;
  text-align: left;
  line-height: 1.05;
  padding: 0;
}

.menu-option:hover {
  color: #ffd36f;
}

.menu-option::before {
  content: "◆ ";
}

/* Image info screens */
.graphic-screen {
  padding: 34px 20px 28px;
}

.graphic-frame {
  width: min(1000px, 94vw);
  margin: 0 auto;
  text-align: center;
}

.graphic-frame .hero-image {
  max-height: 90vh;
  max-width: 100%;
  width: auto;    
  height: auto;       
  margin: 0 auto 24px;
}

.learn-copy {
  width: min(920px, 94vw);
  margin: 0 auto;
  background: var(--panel-soft);
  padding: 24px;
  border-radius: 18px;
  box-shadow: var(--shadow);
  border: 1px solid rgba(255,255,255,0.08);
  line-height: 1.65;
  font-size: 20px;
}

.learn-copy p {
  margin: 0 0 20px;
}

.learn-copy .byline {
  font-style: italic;
  color: var(--muted);
  margin-bottom: 18px;
}

.link-block {
  margin: 18px 0;
}

/* Character grid */
.character-screen {
  padding: 86px 20px 36px;
}

.screen-title {
  margin: 0 0 28px;
  font-size: clamp(34px, 4vw, 52px);
  text-align: center;
}

.character-grid {
  width: min(1180px, 96vw);
  margin: 0 auto 24px;
  display: grid;
  grid-template-columns: repeat(3, minmax(210px, 1fr));
  gap: 24px;
}

.character-card {
  background: transparent;
  border: 3px solid transparent;
  border-radius: 16px;
  cursor: pointer;
  padding: 10px;
  transition: transform 120ms ease, border-color 120ms ease, background 120ms ease;
}

.character-card:hover {
  transform: translateY(-4px);
  border-color: rgba(255, 210, 90, 0.7);
  background: rgba(255, 255, 255, 0.03);
}

.character-card.selected {
  border-color: var(--gold);
  background: rgba(255, 193, 59, 0.08);
}

.character-card img {
  width: 100%;
  height: auto;
  margin: 0 auto;
}

.character-controls {
  display: flex;
  justify-content: center;
  gap: 12px;
  flex-wrap: wrap;
}

/* Notebook */
.notebook-layout {
  min-height: 100vh;
  display: grid;
  grid-template-columns: minmax(220px, 370px) minmax(300px, 1fr);
  gap: 28px;
  align-items: center;
  width: min(1220px, 96vw);
  margin: 0 auto;
  padding: 2px 20px 34px;
}

.character-preview img {
  width: 100%;
  max-height: 70vh;
  object-fit: contain;
}

.notebook-panel {
  position: relative;
  display: flex;
  justify-content: center;
  align-items: center;
}

.notebook-panel img {
  width: 80%;
  max-width: 1200px; /* optional safety cap */
}

.notebook-text {
  position: absolute;
  inset: 18% 22% 8% 30%;
  color: #1b1b1b;
  overflow-y: auto;
  padding-right: 10px;
  font-family: "Trebuchet MS", "Segoe UI", Arial, sans-serif;
}

.notebook-text h2 {
  text-align: center;
  font-size: clamp(22px, 2.2vw, 32px);
  margin: 0 0 12px;
}

.notebook-text p {
  line-height: 1.45;
  font-size: clamp(13px, 1.05vw, 18px);
  margin: 0;
}

.notebook-actions {
  position: fixed;
  left: 50%;
  bottom: 22px;
  transform: translateX(-50%);
  z-index: 10;
}

/* Name entry */
.form-screen {
  padding: 100px 20px 32px;
}

.form-card {
  width: min(760px, 94vw);
  margin: 0 auto;
  text-align: center;
  background: var(--panel-soft);
  padding: 26px;
  border-radius: 18px;
  box-shadow: var(--shadow);
}

.form-card h2 {
  margin-top: 20px;
  font-size: clamp(22px, 2.5vw, 32px);
}

.form-card img {
  margin: 0 auto;
  max-height: 320px;
  width: auto;
}

.label-row {
  text-align: left;
  margin: 14px 0;
}

.label-row label {
  display: block;
  font-size: 20px;
  margin-bottom: 8px;
}

.text-input {
  width: 100%;
  padding: 14px 16px;
  border-radius: 10px;
  border: 2px solid rgba(255, 255, 255, 0.2);
  background: rgba(5, 5, 5, 0.82);
  color: var(--text);
  font-size: 20px;
}

.crew-list {
  display: grid;
  gap: 14px;
  text-align: left;
  margin-top: 16px;
}

.crew-item {
  display: grid;
  grid-template-columns: 60px 1fr;
  align-items: center;
  gap: 12px;
}

.crew-number {
  font-size: 22px;
  color: #ffd36f;
}

.crew-lock {
  display: flex;
  align-items: center;
  min-height: 56px;
  padding: 0 16px;
  border-radius: 10px;
  background: rgba(255,255,255,0.08);
  font-size: 20px;
}

/* Travel intro */
.travel-intro-card {
  width: min(900px, 95vw);
  margin: 0 auto;
  text-align: center;
  background: var(--panel-soft);
  border-radius: 18px;
  padding: 28px;
  box-shadow: var(--shadow);
}

.travel-intro-card img {
  margin: 0 auto 24px;
  max-height: 260px;
  width: auto;
}

.travel-intro-card p {
  line-height: 1.6;
  font-size: clamp(20px, 2vw, 28px);
}

/* Driving scene */
.driving-screen {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

.drive-stage {
  position: relative;
  height: 52vh;
  overflow: hidden;
  background: #111;
  border-bottom: 1px solid rgba(255,255,255,0.1);
}

.drive-bg {
  position: absolute;
  inset: 0;
  background: url("Driving Background1.png") no-repeat center center;
  background-size: cover;
}

.drive-jeep {
  position: absolute;
  bottom: 8%;
  right: -360px;
  width: min(25vw, 360px);
  animation: jeepAcross 14s linear forwards;
  filter: drop-shadow(0 12px 18px rgba(0,0,0,0.45));
}

#jeepCanvas {
  position: absolute;
  bottom: 60px; /* sits on the road */
  left: 0;
  pointer-events: none;
}

.drive-hint {
  position: absolute;
  left: 50%;
  bottom: 14px;
  transform: translateX(-50%);
  background: rgba(0, 0, 0, 0.55);
  padding: 8px 14px;
  border-radius: 999px;
  font-size: 14px;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.drive-report {
  flex: 1;
  padding: 28px 20px 34px;
  width: min(980px, 96vw);
  margin: 0 auto;
}

.report-card {
  background: var(--panel-soft);
  border-radius: 18px;
  padding: 28px;
  box-shadow: var(--shadow);
  opacity: 0;
  transform: translateY(18px);
  transition: opacity 300ms ease, transform 300ms ease;
}

.report-card.visible {
  opacity: 1;
  transform: translateY(0);
}

.report-card h2 {
  margin-top: 0;
  font-size: clamp(32px, 4vw, 50px);
  text-align: center;
}

.report-card h3 {
  margin-bottom: 12px;
  color: #ffd36f;
  font-size: 28px;
}

.events-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 24px;
}

.event-list {
  margin: 0;
  padding-left: 24px;
  line-height: 1.6;
  font-size: 19px;
}

.event-list li {
  margin-bottom: 10px;
}

.event-list.good li::marker {
  color: var(--success);
}

.event-list.bad li::marker {
  color: var(--danger);
}

.points-summary {
  margin-top: 22px;
  padding: 14px 16px;
  border-radius: 12px;
  background: rgba(255,255,255,0.06);
  font-size: 22px;
  text-align: center;
}

/* Arrival */
.arrival-card {
  width: min(1000px, 96vw);
  margin: 0 auto;
  text-align: center;
  background: var(--panel-soft);
  border-radius: 18px;
  padding: 26px;
  box-shadow: var(--shadow);
}

.arrival-card img {
  margin: 0 auto 24px;
  max-height: 44vh;
  width: auto;
}

.arrival-card h1 {
  margin: 0 0 18px;
  font-size: clamp(26px, 3vw, 40px);
}

.arrival-card p {
  margin: 0 auto 20px;
  width: min(880px, 100%);
  line-height: 1.6;
  font-size: clamp(20px, 2vw, 28px);
}

/* Noob fail */
.noob-screen {
  min-height: 100vh;
  display: grid;
  grid-template-columns: minmax(240px, 460px) minmax(280px, 1fr);
  align-items: center;
  gap: 24px;
  width: min(1160px, 95vw);
  margin: 0 auto;
  padding: 92px 20px 32px;
}

.noob-screen img {
  width: 100%;
  max-height: 72vh;
  object-fit: contain;
}

.noob-copy {
  text-align: center;
}

.noob-copy .dotnet {
  font-size: clamp(70px, 13vw, 150px);
  line-height: 1;
  margin: 0 0 16px;
  color: #f1f1f1;
  text-shadow: 0 0 20px rgba(255,255,255,0.14);
}

.noob-copy p {
  font-size: 24px;
  color: var(--muted);
  margin: 0 0 20px;
}

/* Fade */
.fade-in {
  animation: fadeIn 300ms ease;
}

@keyframes fadeIn {
  from { opacity: 0; }
  to { opacity: 1; }
}

@keyframes scrollRoad {
  from { background-position-x: 0; }
  to { background-position-x: -2048px; }
}

@keyframes jeepAcross {
  0% { right: -360px; }
  100% { right: calc(100% + 360px); }
}

@media (max-width: 980px) {
  .character-grid {
    grid-template-columns: repeat(2, minmax(220px, 1fr));
  }

  .notebook-layout,
  .noob-screen {
    grid-template-columns: 1fr;
    padding-top: 86px;
  }

  .character-preview {
    display: flex;
    justify-content: center;
  }

  .character-preview img {
    max-height: 300px;
    width: auto;
  }

  .notebook-panel img {
    max-height: none;
    width: min(720px, 100%);
  }

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

@media (max-width: 620px) {
  .character-grid {
    grid-template-columns: 1fr;
  }

  .top-hud {
    position: static;
    padding: 14px 14px 0;
    flex-direction: column;
  }

  .hud-right {
    justify-content: flex-start;
  }

  .intro-overlay {
    align-items: flex-end;
    padding-bottom: 18px;
  }

  .main-menu .menu-stack {
    padding: 16px 18px;
  }

  .menu-option {
    font-size: clamp(22px, 7vw, 36px);
  }

  .notebook-layout {
    padding: 72px 10px 96px;
    gap: 14px;
  }

  .notebook-panel {
    width: 100%;
    max-width: 430px;
    margin: 0 auto;
  }

  .notebook-panel img {
    width: 100%;
  }

  .notebook-text {
    inset: 13% 10% 10% 17%;
    padding-right: 4px;
    max-height: 72%;
  }

  .notebook-text h2 {
    font-size: clamp(18px, 5vw, 23px);
    margin-bottom: 8px;
  }

  .notebook-text p {
    font-size: clamp(11px, 3.4vw, 14px);
    line-height: 1.32;
  }

  .notebook-actions {
    bottom: 18px;
  }

  .drive-stage {
    height: 40vh;
  }
.intro-screen {
    background-position: center 18%;
    background-size: 115% auto;
  }

  .intro-overlay {
    align-items: flex-start;
    justify-content: center;
    padding-top: 54vh;
    padding-bottom: 120px;
  }

  .main-menu {
    width: 92vw;
  }

  .main-menu .menu-stack {
    align-items: flex-start;
    width: 100%;
    padding: 18px 22px;
  }

  .menu-option {
    font-size: clamp(30px, 9vw, 44px);
    line-height: 1.05;
  }
}
