:root {
  color-scheme: only light;
  --ink: #0f1a23;
  --muted: #65707c;
  --shell: #f4f1eb;
  --card: #fefcf9;
  --accent: #e1463f;
  --accent-dark: #b83a34;
  --accent-soft: #f7c1be;
  --map-fill: #173444;
  --dot: #cfd6db;
  --shadow: 0 25px 60px rgba(16, 32, 45, 0.18);
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  font-family: "Space Grotesk", "Segoe UI", sans-serif;
  background: radial-gradient(circle at top, #efe9df 0%, #f9f5f0 35%, #e7e1d8 100%);
  color: var(--ink);
  min-height: 100vh;
}

.back-link {
  position: fixed;
  top: 24px;
  left: 24px;
  z-index: 10;
  text-decoration: none;
  font-weight: 600;
  color: var(--ink);
  background: rgba(255, 255, 255, 0.8);
  padding: 10px 16px;
  border-radius: 999px;
  box-shadow: 0 10px 30px rgba(15, 26, 35, 0.12);
  backdrop-filter: blur(6px);
}

.backdrop {
  position: fixed;
  inset: 0;
  background-image: radial-gradient(circle at 15% 20%, rgba(226, 96, 83, 0.25), transparent 50%),
    radial-gradient(circle at 80% 10%, rgba(30, 107, 132, 0.25), transparent 45%),
    radial-gradient(circle at 80% 80%, rgba(180, 210, 224, 0.4), transparent 50%);
  pointer-events: none;
  z-index: 0;
}

.page {
  position: relative;
  z-index: 1;
  max-width: 1150px;
  margin: 0 auto;
  padding: 110px 28px 80px;
}

.hero {
  max-width: 720px;
  margin-bottom: 48px;
}

.kicker {
  letter-spacing: 0.2em;
  font-size: 0.75rem;
  text-transform: uppercase;
  color: var(--muted);
  margin: 0 0 12px;
}

.hero h1 {
  font-family: "Fraunces", "Times New Roman", serif;
  font-size: clamp(2.4rem, 3.8vw, 3.8rem);
  margin: 0 0 16px;
}

.lead {
  font-size: 1.05rem;
  line-height: 1.6;
  color: #2f3b44;
  margin: 0 0 20px;
}

.hero-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
}

.chip {
  border: 1px solid rgba(15, 26, 35, 0.12);
  border-radius: 999px;
  padding: 6px 14px;
  font-size: 0.85rem;
  background: rgba(255, 255, 255, 0.6);
}

.layout {
  display: grid;
  grid-template-columns: minmax(0, 1.1fr) minmax(0, 0.9fr);
  gap: 28px;
}

.card {
  background: var(--card);
  border-radius: 28px;
  padding: 26px;
  box-shadow: var(--shadow);
  border: 1px solid rgba(15, 26, 35, 0.08);
}

.card-header h2 {
  margin: 0 0 6px;
  font-size: 1.35rem;
}

.card-header p {
  margin: 0 0 18px;
  color: var(--muted);
}

.map-frame {
  background: #0f1f2a;
  border-radius: 22px;
  padding: 20px;
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.08);
}

#nlMap {
  width: 100%;
  height: auto;
  display: block;
}

.nl-shape {
  fill: url(#mapFill);
  stroke: rgba(255, 255, 255, 0.2);
  stroke-width: 2;
}

.city-dot {
  fill: var(--dot);
  transition: transform 0.2s ease, fill 0.2s ease;
}

.city-dot.is-active {
  fill: var(--accent);
  transform: scale(1.4);
  transform-origin: center;
  animation: pulse 1.4s ease-in-out infinite;
}

@keyframes pulse {
  0%,
  100% {
    opacity: 0.85;
    filter: drop-shadow(0 0 0 rgba(225, 70, 63, 0.3));
  }
  50% {
    opacity: 1;
    filter: drop-shadow(0 0 10px rgba(225, 70, 63, 0.65));
  }
}

.map-legend {
  margin-top: 16px;
  display: flex;
  gap: 18px;
  flex-wrap: wrap;
  color: var(--muted);
  font-size: 0.9rem;
}

.legend-item {
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

.legend-dot {
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background: var(--dot);
  display: inline-block;
}

.legend-dot--active {
  background: var(--accent);
}

.quiz-card {
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.quiz-meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 12px;
  font-size: 0.95rem;
  color: var(--muted);
}

.divider {
  width: 4px;
  height: 4px;
  background: var(--muted);
  border-radius: 50%;
  display: inline-block;
  margin: 0 8px;
}

.timer {
  display: flex;
  flex-direction: column;
  gap: 6px;
  align-items: flex-end;
  min-width: 140px;
}

.timer-bar {
  width: 140px;
  height: 6px;
  background: rgba(15, 26, 35, 0.12);
  border-radius: 999px;
  overflow: hidden;
}

.timer-bar__fill {
  height: 100%;
  width: 100%;
  background: linear-gradient(90deg, #f1c46b, #e1463f);
  transition: width 0.1s linear;
}

.prompt {
  font-size: 1.1rem;
  font-weight: 600;
  min-height: 2.2rem;
}

.options {
  display: grid;
  gap: 12px;
}

.option {
  border: 1px solid rgba(15, 26, 35, 0.16);
  border-radius: 16px;
  padding: 12px 16px;
  background: #fff;
  font-size: 1rem;
  text-align: left;
  cursor: pointer;
  transition: border 0.2s ease, transform 0.2s ease, box-shadow 0.2s ease;
}

.option:hover {
  transform: translateY(-2px);
  box-shadow: 0 14px 30px rgba(15, 26, 35, 0.12);
}

.option.correct {
  border-color: #2f8d68;
  background: #e3f4ed;
}

.option.incorrect {
  border-color: var(--accent);
  background: var(--accent-soft);
}

.feedback {
  min-height: 2.6rem;
  color: var(--muted);
}

.primary,
.ghost {
  border: none;
  padding: 12px 18px;
  border-radius: 999px;
  font-size: 1rem;
  cursor: pointer;
  font-weight: 600;
  align-self: flex-start;
}

.primary {
  background: var(--accent);
  color: #fff;
  box-shadow: 0 16px 34px rgba(225, 70, 63, 0.3);
}

.primary:hover {
  background: var(--accent-dark);
}

.ghost {
  background: transparent;
  color: var(--ink);
  border: 1px solid rgba(15, 26, 35, 0.2);
}

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

  .timer {
    align-items: flex-start;
  }
}

@media (max-width: 720px) {
  .page {
    padding: 100px 20px 70px;
  }

  .back-link {
    position: static;
    margin: 20px;
    display: inline-block;
  }
}
