:root {
  --petrol: #124b53;
  --petrol-dark: #0a363d;
  --cream: #f6f2e8;
  --paper: #fffdf8;
  --gold: #daa02a;
  --gold-soft: #fff0c8;
  --coral: #de6d50;
  --sage: #dcebe3;
  --line: #d9ded8;
  --text: #173f44;
  --muted: #617071;
  --shadow: 0 24px 70px rgba(13, 58, 65, .14);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

* { box-sizing: border-box; }
[hidden] { display: none !important; }
body {
  margin: 0;
  min-height: 100vh;
  color: var(--text);
  background:
    radial-gradient(circle at 8% 5%, rgba(218,160,42,.16), transparent 24rem),
    radial-gradient(circle at 94% 84%, rgba(18,75,83,.09), transparent 28rem),
    var(--cream);
}

button { font: inherit; }
button:focus-visible, a:focus-visible { outline: 4px solid rgba(218,160,42,.4); outline-offset: 3px; }

.topbar {
  min-height: 72px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  padding: 13px clamp(20px, 5vw, 72px);
  color: white;
  background: var(--petrol);
}

.brand { color: white; font-size: 31px; font-weight: 900; letter-spacing: -1.8px; text-decoration: none; }
.top-actions { display: flex; align-items: center; gap: 20px; }
.top-note { color: rgba(255,255,255,.76); font-size: 14px; }
.tool-link { color: white; font-weight: 700; text-decoration: none; }
.tool-link:hover { text-decoration: underline; text-underline-offset: 3px; }
.back-link { display: inline-flex; align-items: center; min-height: 38px; padding: 8px 13px; border: 1px solid rgba(255,255,255,.34); border-radius: 9px; color: white; font-size: 13px; font-weight: 780; text-decoration: none; }
.back-link:hover { background: rgba(255,255,255,.1); }

.shell { width: min(1000px, calc(100% - 30px)); margin: 38px auto 60px; }
.eyebrow { margin-bottom: 12px; color: #8a5d08; font-size: 12px; font-weight: 850; letter-spacing: .13em; text-transform: uppercase; }
.eyebrow::before { content: ""; display: inline-block; width: 8px; height: 8px; margin-right: 8px; border-radius: 50%; background: var(--gold); }

h1, h2, h3, p { margin-top: 0; }
h1 {
  max-width: 850px;
  margin-bottom: 13px;
  font-family: Georgia, "Times New Roman", serif;
  font-size: clamp(38px, 6vw, 64px);
  line-height: 1.02;
  letter-spacing: -.04em;
}

.lead { max-width: 760px; margin-bottom: 26px; color: var(--muted); font-size: clamp(17px, 2vw, 20px); line-height: 1.58; }

.progress-wrap { display: grid; grid-template-columns: 1fr auto; gap: 15px; align-items: center; margin-bottom: 14px; }
.progress { height: 7px; overflow: hidden; border-radius: 999px; background: #e0e2db; }
.progress > div { width: 0; height: 100%; border-radius: inherit; background: linear-gradient(90deg, var(--gold), #f2c258); transition: width .25s ease; }
.progress > .progress-step-0 { width: 0; }
.progress > .progress-step-1 { width: 25%; }
.progress > .progress-step-2 { width: 50%; }
.progress > .progress-step-3 { width: 75%; }
.progress > .progress-step-4 { width: 100%; }
.progress-label { color: var(--muted); font-size: 13px; font-weight: 750; }

.game-card { overflow: hidden; border: 1px solid rgba(18,75,83,.13); border-radius: 20px; background: var(--paper); box-shadow: var(--shadow); }
.panel { display: none; min-height: 470px; padding: clamp(24px, 5vw, 52px); }
.panel.active { display: block; }
.panel h2 { margin-bottom: 11px; font-family: Georgia, "Times New Roman", serif; font-size: clamp(28px, 4vw, 42px); line-height: 1.1; }
.copy { max-width: 720px; color: var(--muted); line-height: 1.62; }
.spaced-title { margin-top: 12px; }
.copy.no-bottom { margin-bottom: 0; }

.rules { display: grid; grid-template-columns: repeat(3, 1fr); gap: 13px; margin: 28px 0 34px; }
.rule { padding: 18px; border: 1px solid var(--line); border-radius: 14px; background: white; }
.rule-number { display: grid; place-items: center; width: 30px; height: 30px; margin-bottom: 13px; border-radius: 50%; color: white; background: var(--petrol); font-weight: 850; }
.rule strong { display: block; margin-bottom: 6px; }
.rule span { color: var(--muted); font-size: 14px; line-height: 1.45; }

.team-note { display: flex; gap: 13px; align-items: flex-start; margin: 0 0 28px; padding: 16px 18px; border-radius: 12px; background: var(--gold-soft); }
.team-note b { font-size: 22px; }
.team-note span { line-height: 1.5; }

.scenario-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 13px; margin: 27px 0 30px; }
.scenario {
  min-height: 156px;
  padding: 20px;
  border: 1px solid var(--line);
  border-radius: 15px;
  color: var(--text);
  background: white;
  cursor: pointer;
  text-align: left;
  transition: transform .15s ease, border-color .15s ease, box-shadow .15s ease;
}
.scenario:hover { transform: translateY(-3px); border-color: #91aead; box-shadow: 0 12px 25px rgba(13,58,65,.09); }
.scenario.selected { border: 2px solid var(--petrol); background: #eff6f3; box-shadow: inset 0 -5px 0 var(--gold); }
.scenario-icon { display: block; margin-bottom: 14px; font-size: 27px; }
.scenario strong { display: block; margin-bottom: 7px; font-size: 16px; }
.scenario span { color: var(--muted); font-size: 13px; line-height: 1.4; }

.actions { display: flex; flex-wrap: wrap; gap: 11px; align-items: center; margin-top: 28px; }
.btn {
  display: inline-flex;
  justify-content: center;
  align-items: center;
  min-height: 49px;
  padding: 12px 21px;
  border: 1px solid var(--petrol);
  border-radius: 10px;
  color: white;
  background: var(--petrol);
  cursor: pointer;
  font-weight: 820;
  text-decoration: none;
}
.btn:hover { background: var(--petrol-dark); }
.btn.secondary { color: var(--petrol); background: transparent; }
.btn.secondary:hover { background: #eef2ed; }
.btn:disabled { opacity: .4; cursor: not-allowed; }
.micro { color: var(--muted); font-size: 13px; }

.handoff-head { display: flex; justify-content: space-between; gap: 20px; align-items: center; margin-bottom: 20px; }
.role-chip { display: inline-flex; padding: 7px 11px; border-radius: 999px; color: #6f4a07; background: var(--gold-soft); font-size: 12px; font-weight: 850; letter-spacing: .05em; text-transform: uppercase; }
.timer { display: grid; place-items: center; width: 62px; height: 62px; border: 5px solid var(--gold); border-radius: 50%; color: var(--petrol); background: white; font-size: 20px; font-weight: 900; }
.timer.urgent { border-color: var(--coral); color: var(--coral); animation: pulse .65s infinite alternate; }
@keyframes pulse { to { transform: scale(1.06); } }

.hidden-card { display: grid; place-items: center; min-height: 280px; padding: 28px; border: 2px dashed #b5c1bc; border-radius: 17px; background: #f4f2ea; text-align: center; }
.hidden-card strong { display: block; margin-bottom: 7px; font-family: Georgia, serif; font-size: 27px; }
.hidden-card p { max-width: 500px; margin-bottom: 0; color: var(--muted); line-height: 1.55; }

.handoff-card { display: none; min-height: 280px; padding: clamp(24px, 5vw, 38px); border-radius: 17px; color: white; background: var(--petrol); }
.handoff-card.show { display: block; }
.handoff-card h3 { margin-bottom: 17px; font-family: Georgia, serif; font-size: 28px; }
.handoff-card p { margin-bottom: 0; font-size: clamp(17px, 2vw, 20px); line-height: 1.7; }
.handoff-tip { margin-top: 16px; color: rgba(255,255,255,.68); font-size: 12px; }

.question { padding: 21px 0; border-bottom: 1px solid var(--line); }
.question:first-of-type { margin-top: 24px; border-top: 1px solid var(--line); }
.question-title { margin-bottom: 12px; font-weight: 800; line-height: 1.4; }
.options { display: flex; flex-wrap: wrap; gap: 8px; }
.option { position: relative; }
.option input { position: absolute; opacity: 0; pointer-events: none; }
.option label { display: flex; align-items: center; min-height: 44px; padding: 11px 14px; border: 1px solid #b9c3bf; border-radius: 9px; background: white; cursor: pointer; font-size: 14px; }
.option input:checked + label { border-color: var(--petrol); color: white; background: var(--petrol); }
.error { min-height: 20px; margin-top: 13px; color: #ad4236; font-size: 14px; font-weight: 750; }

.score-area { display: grid; grid-template-columns: 220px 1fr; gap: 32px; align-items: start; margin-top: 28px; }
.score-card { padding: 25px 18px; border-radius: 17px; color: white; background: var(--petrol); text-align: center; }
.score-card strong { display: block; font-family: Georgia, serif; font-size: 69px; line-height: 1; }
.score-card span { color: rgba(255,255,255,.72); font-size: 13px; }
.score-card em { display: block; margin-top: 14px; color: white; font-size: 12px; font-style: normal; font-weight: 850; letter-spacing: .07em; text-transform: uppercase; }

.lost-list { margin: 15px 0 0; padding: 0; list-style: none; }
.lost-list li { position: relative; margin: 9px 0; padding-left: 24px; color: #415354; line-height: 1.45; }
.lost-list li::before { content: "?"; position: absolute; left: 0; display: grid; place-items: center; width: 17px; height: 17px; border-radius: 50%; color: white; background: var(--coral); font-size: 11px; font-weight: 900; }

.discussion { margin-top: 30px; padding: 24px; border-radius: 15px; background: var(--sage); }
.discussion h3 { margin-bottom: 13px; font-family: Georgia, serif; font-size: 25px; }
.discussion ol { margin: 0; padding-left: 23px; }
.discussion li { margin: 9px 0; line-height: 1.45; }
.kit-preview { margin-top: 22px; padding: 24px; border: 1px solid #e4d3a8; border-radius: 15px; background: #fff8e7; }
.kit-preview h3 { margin-bottom: 8px; font-family: Georgia, serif; font-size: 25px; }
.kit-preview p { margin-bottom: 15px; color: var(--muted); line-height: 1.5; }
.kit-list { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 9px 20px; margin: 0; padding: 0; list-style: none; }
.kit-list li { position: relative; padding-left: 23px; line-height: 1.4; }
.kit-list li::before { content: "✓"; position: absolute; left: 0; color: #8a5d08; font-weight: 900; }
.disclaimer { margin: 18px 0 0; color: var(--muted); font-size: 12px; line-height: 1.55; }
.return-line { margin: 18px 0 0; text-align: center; }
.return-line a { color: var(--petrol); font-size: 14px; font-weight: 780; }

@media (max-width: 760px) {
  .top-note { display: none; }
  .shell { margin-top: 27px; }
  .rules, .scenario-grid { grid-template-columns: 1fr; }
  .kit-list { grid-template-columns: 1fr; }
  .panel { min-height: 0; }
  .score-area { grid-template-columns: 1fr; }
  .score-card { max-width: 220px; }
  .handoff-head { align-items: flex-start; }
}
