@import url("https://fonts.googleapis.com/css2?family=Space+Grotesk:wght@400;500;600&family=Zilla+Slab:wght@600;700&family=JetBrains+Mono:wght@400;600&display=swap");

* {
  box-sizing: border-box;
}

html,
body {
  margin: 0;
  padding: 0;
  font-family: "JetBrains Mono", monospace;
  background: #14131a;
  color: #f0ece7;
}

h1,
h2 {
  font-family: "Zilla Slab", serif;
}

.game-theme {
  background: radial-gradient(circle at 20% 10%, #24212c, #14131a 45%, #0f0e12 100%);
  color: #f0ece7;
}

.nav {
  position: relative;
  z-index: 2;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 20px clamp(20px, 4vw, 64px) 0;
  font-family: "Space Grotesk", sans-serif;
}

.nav .brand {
  font-family: "Zilla Slab", serif;
  font-size: 1.2rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: #ffd166;
}

.nav .links {
  display: flex;
  gap: 14px;
}

.nav a {
  text-decoration: none;
  color: #f0ece7;
  font-size: 0.9rem;
  padding: 8px 14px;
  border-radius: 999px;
  border: 1px solid transparent;
}

.nav a.active {
  border-color: rgba(242, 106, 75, 0.6);
  background: rgba(242, 106, 75, 0.2);
}

.nav a:hover {
  border-color: rgba(63, 136, 197, 0.6);
}

.bg-orbs {
  position: fixed;
  inset: 0;
  z-index: 0;
  overflow: hidden;
  pointer-events: none;
}

.orb {
  position: absolute;
  border-radius: 50%;
  opacity: 0.35;
  mix-blend-mode: screen;
  animation: drift 18s ease-in-out infinite alternate;
}

.orb-1 {
  width: 380px;
  height: 380px;
  background: #f26a4b;
  top: -120px;
  left: -80px;
}

.orb-2 {
  width: 320px;
  height: 320px;
  background: #3f88c5;
  bottom: -120px;
  right: -40px;
  animation-delay: 2s;
}

.orb-3 {
  width: 220px;
  height: 220px;
  background: #fdeaa8;
  top: 40%;
  left: 55%;
  animation-delay: 4s;
}

.view-container {
  width: 100%;
  min-height: 100vh;
  display: flex;
  overflow: hidden;
  align-items: center;
  justify-content: center;
  background: transparent;
  position: relative;
  z-index: 1;
}

.inner-card {
  max-width: 750px;
  width: 100%;
  border: 2px solid rgba(240, 236, 231, 0.2);
  padding: 1rem;
  position: relative;
  background: rgba(24, 22, 30, 0.9);
  margin: 1rem;
  animation: slide-in forwards 0.5s;
  transition: 0.5s;
  color: #f0ece7;
}

.inner-card.out {
  transform: translateY(-100vw);
}

@keyframes slide-in {
  0% {
    transform: translateY(-150vh);
  }
  100% {
    transform: translateY(0);
  }
}

.animated-header {
  font-family: "Zilla Slab", serif;
  text-align: center;
  font-size: 3.2rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: #ffd166;
  position: relative;
}

.animated-header::after {
  content: "";
  display: block;
  height: 3px;
  width: 140px;
  margin: 12px auto 0;
  background: linear-gradient(90deg, transparent, #ffd166, transparent);
  animation: shimmer 2.2s ease-in-out infinite;
}

@keyframes shimmer {
  0%,
  100% {
    opacity: 0.4;
    transform: scaleX(0.9);
  }
  50% {
    opacity: 1;
    transform: scaleX(1.1);
  }
}

.options-container {
  display: flex;
  justify-content: space-between;
  gap: 16px;
}

.options-list {
  width: 30%;
  margin: 1rem 0;
}

@media (max-width: 750px) {
  .options-container {
    display: block;
  }

  .options-list {
    border-top: 2px solid #888;
    width: 100%;
    margin: 0.5rem 0 0;
    padding-top: 0.5rem;
  }
}

.styled-button {
  padding: 0.25rem 0.75rem;
  font-size: 1.3rem;
  background: #f26a4b;
  color: #fff;
  border-radius: 3px;
  display: inline-block;
  border: 2px solid #f26a4b;
  cursor: pointer;
  transition: 0.25s;
  will-change: transform;
  box-shadow: -1px 1px 0px rgba(0, 0, 0, 0.35),
    -2px 2px 0px rgba(0, 0, 0, 0.35),
    -3px 3px 0px rgba(0, 0, 0, 0.35),
    -4px 4px 0px rgba(0, 0, 0, 0.35);
}

.styled-button:hover {
  transform: scale(1.05);
  box-shadow: -1px 1px 0px #333, -2px 2px 0px #333, -3px 3px 0px #333,
    -4px 4px 0px #333, -5px 5px 0px #333, -6px 6px 0px #333;
}

.styled-button:active {
  transform: scale(0.95);
  box-shadow: -1px 1px 0px #222, -2px 2px 0px #222;
}

.block-label {
  display: block;
  margin: 10px 0;
  position: relative;
  font-size: 1.2rem;
  cursor: pointer;
  transition: 0.25s;
}

.block-label input {
  display: none;
}

.block-label span {
  display: block;
  padding-left: 50px;
}

.block-label span::before {
  content: "";
  position: absolute;
  height: 10px;
  width: 10px;
  border: 2px solid #f0ece7;
  left: 20px;
  top: 5px;
  transition: 0.25s;
}

.block-label input:checked + span {
  font-size: 1.3rem;
}

.block-label input:checked + span::before {
  border-top: none;
  border-left: none;
  transform: rotate(45deg);
  height: 20px;
  top: -2px;
}

.game-container {
  padding: 0 1rem;
  height: 100vh;
  overflow: hidden;
  position: relative;
  animation: slide-in forwards 0.5s;
  transition: 0.5s;
  background: rgba(20, 19, 26, 0.85);
  color: #f0ece7;
}

.targets-layer {
  position: absolute;
  inset: 0;
  pointer-events: none;
}

.game-container.out {
  top: 150vh;
  background: #f46652;
}

.game-score {
  margin: 0;
  padding: 1rem 0 0 0;
  font-family: "Space Grotesk", sans-serif;
  letter-spacing: 0.02em;
}

.game-timer {
  font-family: "Space Grotesk", sans-serif;
  font-size: 1.1rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  margin-top: 6px;
  color: #ffd166;
}

.target {
  position: absolute;
  font-size: 2rem;
  border: none;
  padding: 0.5rem 0.6rem;
  transform: translate3d(-50%, 0, 0);
  transition: none;
  background: rgba(30, 27, 36, 0.95);
  z-index: 2;
  box-shadow: 0 12px 24px rgba(0, 0, 0, 0.35);
  will-change: transform;
}

.target.hit {
  transform: translate(-50%, 0) scale(2) rotate(360deg);
  opacity: 0;
  transition: 500ms;
}

.target.missed {
  color: #f30a13;
}

.target.bomb {
  border-color: #ff5c3a;
  background: rgba(255, 92, 58, 0.15);
  color: #ff5c3a;
  box-shadow: 0 12px 24px rgba(255, 92, 58, 0.35);
}

.target.bomb::after {
  content: "";
  position: absolute;
  top: -8px;
  right: -8px;
  width: 10px;
  height: 10px;
  background: #ffd166;
  border-radius: 50%;
  box-shadow: 0 0 8px #ffd166;
  animation: spark 0.6s infinite alternate;
}

.health-hud {
  position: absolute;
  bottom: 28px;
  left: 50%;
  transform: translateX(-50%);
  width: min(680px, 80%);
  display: grid;
  grid-template-columns: auto 1fr auto;
  gap: 16px;
  align-items: center;
  padding: 12px 16px;
  background: rgba(30, 27, 36, 0.8);
  border: 1px solid rgba(240, 236, 231, 0.2);
  border-radius: 999px;
  box-shadow: 0 16px 40px rgba(0, 0, 0, 0.35);
  backdrop-filter: blur(10px);
}

.health-label {
  font-family: "Space Grotesk", sans-serif;
  text-transform: uppercase;
  letter-spacing: 0.2em;
  font-size: 0.7rem;
  color: rgba(240, 236, 231, 0.8);
}

.health-meter {
  position: relative;
  height: 16px;
  border-radius: 999px;
  background: rgba(240, 236, 231, 0.08);
  overflow: hidden;
}

.health-track {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  transition: width 0.35s ease;
  background: linear-gradient(90deg, #3f88c5, #f26a4b);
  box-shadow: 0 0 18px rgba(242, 106, 75, 0.6);
}

.health-glow {
  position: absolute;
  inset: -6px;
  border-radius: 999px;
  border: 1px solid rgba(242, 106, 75, 0.4);
  animation: pulse 1.4s ease-in-out infinite;
  pointer-events: none;
}

.health-value {
  font-family: "Space Grotesk", sans-serif;
  font-size: 1.1rem;
  font-weight: 600;
  color: #ffd166;
}

.game-over h2 {
  text-align: center;
  font-size: 2.5rem;
  animation: scale-in 2s forwards;
}

@keyframes scale-in {
  0% {
    transform: scale(0);
  }
  100% {
    transform: scale(1);
  }
}

.hidden-input {
  position: absolute;
  opacity: 0;
  height: 1px;
  width: 1px;
  pointer-events: none;
}

.right-actions {
  text-align: right;
}

.gun {
  position: absolute;
  bottom: 60px;
  left: 50%;
  transform: translateX(-50%);
  width: 140px;
  height: 40px;
  z-index: 3;
  display: flex;
  align-items: center;
  gap: 8px;
}

.gun-base {
  width: 60px;
  height: 30px;
  background: #2f2b45;
  border-radius: 6px;
  box-shadow: inset 0 0 0 2px rgba(240, 236, 231, 0.2);
}

.gun-barrel {
  width: 70px;
  height: 12px;
  background: #3f88c5;
  border-radius: 6px;
  position: relative;
}

.gun.fire .gun-barrel {
  animation: recoil 0.2s ease;
}

.muzzle {
  position: absolute;
  right: -8px;
  top: -6px;
  width: 18px;
  height: 18px;
  background: radial-gradient(circle, #ffd166, transparent 70%);
  opacity: 0;
}

.gun.fire .muzzle {
  opacity: 1;
  animation: flash 0.2s ease;
}

.bullet {
  position: absolute;
  width: 6px;
  height: 12px;
  background: #ffd166;
  border-radius: 3px;
  left: 50%;
  bottom: 80px;
  transform: translateX(-50%);
  animation: bullet-travel 0.3s ease-out forwards;
  z-index: 4;
}

.explosion {
  position: absolute;
  width: 24px;
  height: 24px;
  border-radius: 50%;
  background: radial-gradient(circle, #ff5c3a, transparent 70%);
  animation: boom 0.4s ease-out forwards;
  z-index: 4;
}

@keyframes bullet-travel {
  from {
    transform: translate(-50%, 0);
    opacity: 1;
  }
  to {
    transform: translate(-50%, -400px);
    opacity: 0;
  }
}

@keyframes recoil {
  0% {
    transform: translateX(0);
  }
  50% {
    transform: translateX(-6px);
  }
  100% {
    transform: translateX(0);
  }
}

@keyframes flash {
  0% {
    transform: scale(0.6);
    opacity: 1;
  }
  100% {
    transform: scale(1.2);
    opacity: 0;
  }
}

@keyframes boom {
  0% {
    transform: scale(0.5);
    opacity: 0.9;
  }
  100% {
    transform: scale(2.5);
    opacity: 0;
  }
}

@keyframes spark {
  from {
    transform: scale(0.8);
  }
  to {
    transform: scale(1.2);
  }
}

@keyframes drift {
  from {
    transform: translateY(0) translateX(0) scale(1);
  }
  to {
    transform: translateY(-20px) translateX(16px) scale(1.05);
  }
}
