:root {
  color-scheme: light;
  --paper: #f5f0e7;
  --card: #fffaf1;
  --ink: #192e2b;
  --muted: #505e55;
  --line: #dbd7c9;
  --ocean: #153b39;
  --accent: #ab4d2b;
  --amber: #ffcb73;
  --serif: Georgia, "Times New Roman", serif;
  font-family: system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body { margin: 0; color: var(--ink); background: var(--paper); }
h1, h2, p { margin: 0; }
button { font: inherit; }
a { color: inherit; }
[hidden] { display: none !important; }
:focus-visible { outline: 2px solid #9a421f; outline-offset: 4px; }
.container { max-width: 1304px; width: calc(100% - 96px); margin-inline: auto; }
.site-header { border-bottom: 1px solid var(--line); }
.header-inner, .footer-inner { display: flex; align-items: center; justify-content: space-between; gap: 16px; }
.header-inner { min-height: 66px; }
.wordmark { display: inline-flex; align-items: center; gap: 10px; font-weight: 800; letter-spacing: -.035em; text-decoration: none; }
.compass-mark { display: inline-grid; width: 27px; height: 27px; place-items: center; border: 1px solid #8b624f; border-radius: 50%; }
.compass-mark::before { content: ""; width: 17px; height: 17px; background: var(--accent); clip-path: polygon(50% 0, 62% 38%, 100% 50%, 62% 62%, 50% 100%, 38% 62%, 0 50%, 38% 38%); }
nav { display: flex; gap: 23px; font-size: .85rem; font-weight: 650; }
nav a { text-decoration: none; }
nav a:hover, .footer-inner a:hover { text-decoration: underline; }

.intro { display: flex; align-items: end; justify-content: space-between; gap: 22px; padding: 29px 0 23px; }
.intro h1 { font: 500 clamp(3.6rem, 6.8vw, 6.1rem)/.89 var(--serif); letter-spacing: -.088em; }
.intro h1 span { color: var(--accent); }
.intro p { color: var(--muted); font-size: .95rem; margin-top: 13px; }
.intro .game-meta { display: flex; gap: 13px; align-items: center; font-size: .78rem; font-weight: 650; padding-bottom: 1px; }
.game-meta span + span { border-left: 1px solid #bdb9ac; padding-left: 13px; }

.game { display: grid; grid-template-columns: minmax(0, 1.7fr) minmax(0, 1fr); overflow: hidden; border: 1px solid #cfcab9; border-radius: 20px; box-shadow: 0 14px 38px #34322412; background: var(--card); scroll-margin-top: 12px; }
.map-panel {
  min-width: 0;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  color: #f6edd6;
  background: radial-gradient(ellipse at 50% 50%, #23514b 0%, var(--ocean) 68%, #102d2d 100%);
}
.map-header, .map-footer { display: flex; justify-content: space-between; gap: 12px; padding: 24px 26px; }
.origin { display: flex; align-items: flex-start; gap: 10px; }
.origin > i { margin-top: 3px; width: 11px; height: 11px; border: 2px solid var(--amber); border-radius: 50%; box-shadow: 0 0 0 3px #ffcb732b; flex: 0 0 auto; }

.label { font-size: .68rem; font-weight: 750; letter-spacing: .11em; text-transform: uppercase; }
.origin .label { color: #e6c38c; margin-bottom: 4px; }
.origin strong { font: 500 clamp(1.6rem, 3vw, 2.4rem)/1 var(--serif); display: block; }
.origin span { color: #d4ded3; display: block; margin-top: 5px; font-size: .79rem; }
.map-north { color: #eed7ae; display: flex; flex-direction: column; align-items: center; padding-top: 3px; gap: 5px; font-size: .66rem; font-weight: 750; }
.map-north i { width: 16px; height: 23px; background: #eed7ae; clip-path: polygon(50% 0, 100% 100%, 50% 67%, 0 100%); }
#map { display: block; width: 100%; aspect-ratio: 1000 / 456; height: auto; }
.map-footer { justify-content: flex-start; color: #dce3d9; font-size: .69rem; align-items: center; padding-block: 18px; }
.map-footer span { display: inline-flex; align-items: center; gap: 6px; }
.map-footer i { width: 7px; height: 7px; border: 1px solid var(--amber); border-radius: 50%; }
#route-key i { width: 16px; height: 2px; border: 0; border-radius: 0; background: var(--amber); }

.game-panel { min-width: 0; display: flex; flex-direction: column; padding: 24px clamp(20px, 2.4vw, 34px) 20px; }
.status-row { display: flex; align-items: center; justify-content: space-between; gap: 8px; color: var(--muted); }
#score strong { margin-left: 4px; color: var(--ink); }
.steps { height: 4px; display: grid; grid-template-columns: repeat(5, 1fr); gap: 5px; margin: 9px 0 19px; }
.steps span { border-radius: 8px; background: #e8e0d1; }
.steps .is-current { background: #ad532f; }
.steps .is-complete { background: #548575; }
.game-panel h2, .instructions h2 { font: 500 clamp(1.8rem, 2.9vw, 2.8rem)/.99 var(--serif); letter-spacing: -.045em; }
.question-hint { font-size: .8rem; color: var(--muted); margin: 8px 0 13px; }
.answers { display: grid; gap: 7px; }
.answer {
  display: grid;
  grid-template-columns: 26px minmax(0, 1fr) auto;
  align-items: center;
  gap: 8px;
  width: 100%;
  min-height: 44px;
  border: 1px solid #ded8ca;
  border-radius: 8px;
  background: #fcf7ee;
  color: var(--ink);
  text-align: left;
  padding: 7px 9px;
  cursor: pointer;
}
.answer:not(:disabled):hover { border-color: #a86b4c; background: #f5ead9; }
.answer:disabled { cursor: default; }
.answer strong { font-size: .85rem; line-height: 1.12; overflow-wrap: anywhere; }
.answer-index { display: grid; width: 23px; height: 23px; place-items: center; border-radius: 5px; background: #eee7d9; color: #524d41; font-size: .67rem; font-weight: 800; }
.answer-distance { font-size: .73rem; font-weight: 650; white-space: nowrap; font-variant-numeric: tabular-nums; }
.answer--correct { background: #e3efe4; border-color: #75a38a; }
.answer--correct .answer-index { background: #2c624f; color: #fff; }
.answer--wrong { background: #f8e7dc; border-color: #ca947b; }

.answer--wrong .answer-index { background: #9c4128; color: #fff; }
.reveal { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; justify-content: space-between; margin-top: 13px; min-height: 41px; }
#feedback { flex: 1 1 135px; min-width: 0; color: #344d42; font-size: .76rem; line-height: 1.25; font-weight: 650; }
.next { min-height: 41px; border: 0; border-radius: 7px; padding: 8px 12px; color: #fff8ea; background: #204b40; font-weight: 750; font-size: .77rem; cursor: pointer; }
.next:hover { background: #132f29; }
.next span { margin-left: 4px; }
.results { display: flex; flex-direction: column; align-items: flex-start; justify-content: center; flex: 1; padding-block: 16px 24px; }
.results .label { color: var(--accent); }
.results h2 { font-size: clamp(3.5rem, 7vw, 6rem); line-height: 1.06; margin-top: 5px; }
#result-note { color: var(--muted); margin-bottom: 18px; }

.instructions { display: grid; grid-template-columns: 1.35fr 1fr; gap: clamp(20px, 7vw, 94px); padding: 39px 0; align-items: start; }
.instructions h2 { font-size: clamp(1.8rem, 3.5vw, 2.6rem); }
.instructions p { color: var(--muted); font-size: .89rem; line-height: 1.6; margin-top: 10px; max-width: 61ch; }
.faq details { border-bottom: 1px solid var(--line); padding: 12px 0; }
.faq details:first-child { border-top: 1px solid var(--line); }
.faq summary { cursor: pointer; font-size: .86rem; font-weight: 650; }
.site-footer { border-top: 1px solid var(--line); }
.footer-inner { color: var(--muted); min-height: 63px; font-size: .73rem; }
.footer-inner a { text-decoration: none; }

@media (max-width: 900px) {
  .container { width: calc(100% - 48px); }
  .game { grid-template-columns: minmax(0, 1.25fr) minmax(0, 1fr); }
  .map-header, .map-footer { padding-inline: 19px; }
}

@media (max-width: 680px) {
  .container { width: calc(100% - 28px); }
  .header-inner { min-height: 49px; }
  nav { gap: 15px; font-size: .76rem; }
  .intro { padding: 17px 0 13px; gap: 7px; }
  .intro h1 { font-size: clamp(2.75rem, 11vw, 4rem); }
  .intro p { margin-top: 6px; font-size: .78rem; }
  .intro .game-meta { flex-direction: column; align-items: end; gap: 3px; font-size: .63rem; }
  .game-meta span + span { padding: 0; border: 0; }
  .game { grid-template-columns: minmax(0, 1fr); border-radius: 13px; }
  .map-header { padding: 11px 13px 3px; }
  .origin { gap: 8px; }
  .origin .label { font-size: .59rem; }
  .origin span { margin-top: 2px; font-size: .7rem; }
  .map-footer { padding: 2px 13px 9px; font-size: .62rem; }
  .game-panel { padding: 13px 12px 12px; }
  .steps { margin-bottom: 11px; }
  .game-panel h2 { font-size: 1.8rem; }
  .question-hint { margin: 4px 0 8px; }
  .answers { gap: 5px; }
  .answer { padding-block: 4px; }
  .reveal { min-height: 0; margin-top: 9px; }
  .reveal:has(button[hidden]) { margin-top: 0; }

  .instructions { grid-template-columns: 1fr; padding-block: 24px; gap: 20px; }
  .footer-inner { flex-wrap: wrap; justify-content: flex-start; gap: 5px 15px; padding-block: 13px; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
}
