.runner-body {
  min-height: 100vh;
  background:
    radial-gradient(circle at 12% 8%, rgba(255, 209, 102, 0.14), transparent 24rem),
    radial-gradient(circle at 88% 20%, rgba(92, 200, 255, 0.22), transparent 27rem),
    linear-gradient(145deg, #07111d 0%, #0c1b21 48%, #111725 100%);
}

.runner-header {
  position: relative;
}

.runner-shell {
  padding: clamp(1rem, 4vw, 3rem);
}

.runner-stage {
  min-height: calc(100vh - 7rem);
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: 8px;
  background:
    linear-gradient(135deg, rgba(255, 255, 255, 0.09), transparent 34%),
    rgba(5, 13, 24, 0.64);
  box-shadow: 0 30px 120px rgba(0, 0, 0, 0.34);
  overflow: hidden;
}

.game-topline {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: clamp(1rem, 4vw, 2rem);
  border-bottom: 1px solid rgba(255, 255, 255, 0.12);
}

.game-topline h1 {
  margin: 0;
  font-size: clamp(2.8rem, 8vw, 6.8rem);
}

.pilot-card {
  display: inline-flex;
  align-items: center;
  gap: 0.65rem;
  min-height: 2.5rem;
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: 999px;
  padding: 0.55rem 0.85rem;
  background: rgba(255, 255, 255, 0.06);
  color: #dce8f5;
  font-weight: 800;
}

.pilot-dot {
  width: 0.7rem;
  aspect-ratio: 1;
  border-radius: 50%;
  background: var(--yellow);
  box-shadow: 0 0 18px rgba(255, 209, 102, 0.8);
}

.pilot-dot.live {
  background: var(--green);
  box-shadow: 0 0 18px rgba(99, 212, 113, 0.9);
}

.pilot-dot.danger {
  background: var(--red);
  box-shadow: 0 0 18px rgba(255, 107, 107, 0.9);
}

.runner-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.5fr) minmax(20rem, 0.72fr);
  gap: 1rem;
  padding: clamp(1rem, 4vw, 2rem);
}

.map-panel,
.control-panel {
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: 8px;
  background: rgba(8, 18, 29, 0.74);
}

.map-panel {
  position: relative;
  min-height: 36rem;
  overflow: hidden;
}

.route-sky {
  position: absolute;
  inset: 0;
  background:
    linear-gradient(90deg, rgba(255, 255, 255, 0.055) 1px, transparent 1px),
    linear-gradient(rgba(255, 255, 255, 0.055) 1px, transparent 1px);
  background-size: 34px 34px;
  opacity: 0.68;
}

.route-sky span {
  position: absolute;
  width: 12rem;
  height: 12rem;
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 50%;
}

.route-sky span:nth-child(1) {
  left: 8%;
  top: 10%;
}

.route-sky span:nth-child(2) {
  right: 9%;
  top: 16%;
}

.route-sky span:nth-child(3) {
  left: 34%;
  bottom: -5rem;
}

.route-sky span:nth-child(4) {
  right: -5rem;
  bottom: 16%;
}

.route-track {
  position: relative;
  z-index: 2;
  padding: 1rem;
}

.route-track svg {
  width: 100%;
  height: auto;
  overflow: visible;
}

.route-line {
  fill: none;
  stroke: rgba(255, 255, 255, 0.22);
  stroke-dasharray: 10 12;
  stroke-linecap: round;
  stroke-width: 6;
}

.route-node {
  fill: #24384b;
  stroke: rgba(255, 255, 255, 0.36);
  stroke-width: 4;
}

.route-node.done {
  fill: var(--green);
  stroke: #d9ffe0;
}

.route-node.current {
  fill: var(--yellow);
  stroke: #fff3c4;
  filter: drop-shadow(0 0 12px rgba(255, 209, 102, 0.9));
}

.outline-wrap {
  position: relative;
  z-index: 2;
  display: grid;
  min-height: 23rem;
  place-items: center;
  padding: 1rem;
}

#country-svg {
  width: min(88%, 38rem);
  max-height: 23rem;
  filter: drop-shadow(0 30px 40px rgba(0, 0, 0, 0.42));
}

#country-path {
  fill: rgba(99, 212, 113, 0.17);
  stroke: #a7ffb2;
  stroke-linejoin: round;
  stroke-width: 5;
  transition: fill 180ms ease, stroke 180ms ease, transform 180ms ease;
  transform-origin: center;
}

#country-path.flash-good {
  fill: rgba(99, 212, 113, 0.42);
  stroke: #ffffff;
  transform: scale(1.03);
}

#country-path.flash-bad {
  fill: rgba(255, 107, 107, 0.28);
  stroke: #ffc2c2;
}

.clue-strip {
  position: relative;
  z-index: 2;
  display: flex;
  flex-wrap: wrap;
  gap: 0.6rem;
  padding: 0 1rem 1rem;
}

.clue-strip span,
.message {
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.06);
}

.clue-strip span {
  padding: 0.55rem 0.7rem;
  color: #dce8f5;
  font-weight: 800;
}

.control-panel {
  display: flex;
  flex-direction: column;
  gap: 1rem;
  padding: 1rem;
}

.stat-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 0.7rem;
}

.stat-grid div {
  min-height: 5.5rem;
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 8px;
  padding: 0.85rem;
  background: rgba(255, 255, 255, 0.055);
}

.stat-grid span,
.energy-label span,
.answer-form label {
  display: block;
  color: var(--muted);
  font-size: 0.78rem;
  font-weight: 800;
  text-transform: uppercase;
}

.stat-grid strong {
  display: block;
  margin-top: 0.5rem;
  font-size: clamp(1.7rem, 4vw, 2.35rem);
  line-height: 1;
}

.energy-block {
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 8px;
  padding: 1rem;
  background: rgba(255, 255, 255, 0.055);
}

.energy-label {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  margin-bottom: 0.75rem;
}

.energy-meter {
  height: 1rem;
  overflow: hidden;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.11);
}

.energy-meter span {
  display: block;
  width: 100%;
  height: 100%;
  border-radius: inherit;
  background: linear-gradient(90deg, var(--green), var(--yellow));
  transition: width 120ms linear, background 180ms ease;
}

.energy-meter span.low {
  background: linear-gradient(90deg, var(--red), var(--yellow));
}

.answer-form {
  display: grid;
  gap: 0.7rem;
}

.answer-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 0.6rem;
}

.answer-row input {
  width: 100%;
  min-height: 2.8rem;
  border: 1px solid rgba(255, 255, 255, 0.16);
  border-radius: 8px;
  padding: 0.8rem 0.9rem;
  background: rgba(255, 255, 255, 0.08);
  color: var(--ink);
  font: inherit;
  outline: none;
}

.answer-row input:focus {
  border-color: rgba(92, 200, 255, 0.7);
  box-shadow: 0 0 0 3px rgba(92, 200, 255, 0.16);
}

.button-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.7rem;
}

button {
  border: 0;
  cursor: pointer;
  font: inherit;
}

button:disabled,
input:disabled {
  cursor: not-allowed;
  opacity: 0.55;
}

.message {
  min-height: 5.3rem;
  margin: 0;
  padding: 0.9rem;
  color: #dce8f5;
  line-height: 1.5;
}

@media (max-width: 960px) {
  .game-topline,
  .runner-grid {
    grid-template-columns: 1fr;
  }

  .game-topline {
    align-items: flex-start;
    flex-direction: column;
  }

  .map-panel {
    min-height: 30rem;
  }

  .runner-grid {
    display: grid;
  }
}

@media (max-width: 560px) {
  .runner-shell {
    padding: 0;
  }

  .runner-stage {
    border-left: 0;
    border-right: 0;
  }

  .runner-grid {
    padding: 0.75rem;
  }

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