/* ═══════════════════════════════════════════════════════════════
   NASA — Solar System Exploration
   explore.css | Typography: Space Grotesk throughout
   Glitch-Free Word-to-Rocket Transformation & Planetary Entry
   ═══════════════════════════════════════════════════════════════ */

*, *::before, *::after {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html, body {
  width: 100%;
  min-height: 100%;
  overflow-x: hidden;
  overflow-y: auto;
  background-color: #010206;
  color: #ffffff;
  font-family: 'Space Grotesk', -apple-system, sans-serif;
  user-select: none;
  -webkit-user-select: none;
  scroll-behavior: smooth;
}

/* ── GALAXY CANVAS BACKGROUND ───────────────────────────────── */
#space-bg {
  position: fixed;
  inset: 0;
  width: 100vw;
  height: 100vh;
  z-index: 0;
  display: block;
}

/* ── FLIGHT FX CANVAS (THRUSTERS, SMOKE, ENTRY PLASMA) ──────── */
#fx-canvas {
  position: fixed;
  inset: 0;
  width: 100vw;
  height: 100vh;
  z-index: 20;
  pointer-events: none;
  display: block;
}

/* ── TOP NAVIGATION / HUD ───────────────────────────────────── */
.explore-header {
  position: fixed;
  top: 24px;
  left: 32px;
  right: 32px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  z-index: 40;
  pointer-events: none;
}

.explore-header > * {
  pointer-events: auto;
}

.archive-jump-btn {
  font-family: 'Space Grotesk', sans-serif;
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: #ffffff;
  background: rgba(14, 24, 40, 0.75);
  border: 1px solid rgba(255, 255, 255, 0.25);
  padding: 8px 16px;
  border-radius: 4px;
  cursor: pointer;
  backdrop-filter: blur(8px);
  transition: all 0.25s ease;
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

.theme-mars .archive-jump-btn {
  border-color: rgba(255, 120, 60, 0.45);
  color: #ff9966;
}

.theme-mars .archive-jump-btn:hover {
  background: rgba(255, 100, 40, 0.25);
  border-color: rgba(255, 140, 80, 0.85);
  box-shadow: 0 0 16px rgba(255, 90, 30, 0.4);
}

.theme-moon .archive-jump-btn {
  border-color: rgba(140, 200, 255, 0.45);
  color: #99d5ff;
}

.theme-moon .archive-jump-btn:hover {
  background: rgba(100, 180, 255, 0.25);
  border-color: rgba(150, 220, 255, 0.85);
  box-shadow: 0 0 16px rgba(100, 180, 255, 0.4);
}

.back-link {
  font-family: 'Space Grotesk', sans-serif;
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: rgba(220, 235, 255, 0.75);
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 8px 16px;
  background: rgba(12, 16, 26, 0.65);
  border: 1px solid rgba(255, 255, 255, 0.18);
  border-radius: 4px;
  backdrop-filter: blur(8px);
  transition: all 0.3s ease;
}

.back-link:hover {
  color: #ffffff;
  border-color: rgba(255, 255, 255, 0.5);
  background: rgba(20, 26, 42, 0.85);
  transform: translateX(-3px);
}

.mission-telemetry {
  font-family: 'Space Grotesk', sans-serif;
  font-size: 0.65rem;
  font-weight: 600;
  letter-spacing: 0.28em;
  text-transform: uppercase;
  color: #8be4d5;
  background: rgba(6, 20, 22, 0.6);
  padding: 6px 14px;
  border-radius: 4px;
  border: 1px solid rgba(139, 228, 213, 0.3);
  backdrop-filter: blur(8px);
}

/* ── MAIN STAGE ─────────────────────────────────────────────── */
#explore-stage {
  position: relative;
  z-index: 10;
  width: 100vw;
  height: 100vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: space-between;
  padding: 70px 20px 40px;
}

/* ── 3D TARGET PLANET VIEWPORT ──────────────────────────────── */
.planet-target-area {
  position: relative;
  width: 100%;
  max-width: 700px;
  height: 52vh;
  display: flex;
  align-items: center;
  justify-content: center;
}

#target-canvas {
  display: block;
  border-radius: 50%;
  outline: none;
  filter: drop-shadow(0 0 50px rgba(0, 0, 0, 0.8));
}

/* Planet Entry Target Ring Overlay */
.target-orbit-ring {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 380px;
  height: 380px;
  border-radius: 50%;
  border: 1px dashed rgba(255, 255, 255, 0.12);
  pointer-events: none;
  animation: rotateRing 30s linear infinite;
}

@keyframes rotateRing {
  from { transform: translate(-50%, -50%) rotate(0deg); }
  to { transform: translate(-50%, -50%) rotate(360deg); }
}

/* ── TRANSFORMATION ZONE (WORDS TO COMPLETE ROCKET) ─────────── */
.launch-control-area {
  position: relative;
  width: 100%;
  max-width: 600px;
  height: 36vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 16px;
}

/* Status Banner */
.mission-status-text {
  font-family: 'Space Grotesk', sans-serif;
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.32em;
  text-transform: uppercase;
  color: #fce4b8;
  opacity: 0.85;
  transition: all 0.4s ease;
}

/* Rocket Morphing Stage Container */
.rocket-stage-container {
  position: relative;
  width: 360px;
  height: 320px;
  display: flex;
  align-items: center;
  justify-content: center;
}

/* Realistic 3D Aerospace Spacecraft Assembly */
#rocket-svg-assembly {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 180px;
  height: 300px;
  pointer-events: none;
  z-index: 5;
  transition: opacity 0.8s ease;
  overflow: visible;
}

/* Mars rocket — incandescent iron-copper glow */
.theme-mars #rocket-svg-assembly {
  filter:
    drop-shadow(0 16px 36px rgba(0, 0, 0, 0.90))
    drop-shadow(0 0 22px rgba(230, 90, 20, 0.35));
}

/* Moon rocket — arctic cryogenic blue-white aura */
.theme-moon #rocket-svg-assembly {
  filter:
    drop-shadow(0 16px 36px rgba(0, 0, 0, 0.90))
    drop-shadow(0 0 22px rgba(120, 190, 255, 0.28));
}

/* Mechanical assembly hull plates smoothly lock into place */
.rocket-hull-part {
  opacity: 0;
  transition: opacity 0.85s cubic-bezier(0.2, 0.8, 0.25, 1);
}

.assembled .rocket-hull-part {
  opacity: 1;
}

/* ── WORD LETTERS CONTAINER ─────────────────────────────────── */
.word-letters-wrapper {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 240px;
  height: 60px;
  z-index: 10;
  transition: all 0.9s cubic-bezier(0.2, 0.9, 0.3, 1);
}

/* Precision Machined Aerospace Letters */
.morph-letter {
  font-family: 'Space Grotesk', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  font-size: 2.7rem;
  font-weight: 800;
  letter-spacing: 0;
  line-height: 1;
  width: 60px;
  height: 60px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  position: relative;
  will-change: transform, opacity, filter;
  transition: transform 1.1s cubic-bezier(0.2, 0.9, 0.25, 1),
              opacity 0.6s ease,
              filter 0.6s ease;
  background-size: cover;
  background-position: center;
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  color: transparent;
}

/* Mars Theme Letters — Machined Titanium with Hot Core Backlight */
.theme-mars .morph-letter {
  filter: brightness(2.4) contrast(1.3) drop-shadow(0 2px 4px rgba(0, 0, 0, 0.9)) drop-shadow(0 0 16px rgba(240, 100, 35, 0.85));
}

/* Moon Theme Letters — Polished Silver Alloy with Cryogenic Blue Glow */
.theme-moon .morph-letter {
  filter: brightness(2.3) contrast(1.25) drop-shadow(0 2px 4px rgba(0, 0, 0, 0.9)) drop-shadow(0 0 16px rgba(160, 210, 255, 0.8));
}

/* Moon Gradient for O and O */
.theme-moon .letter-o1,
.theme-moon .letter-o2 {
  background-image: radial-gradient(circle at 38% 36%, #ffffff 0%, #cbd5e1 40%, #60a5fa 75%, #1e3a8a 100%) !important;
  -webkit-background-clip: text !important;
  background-clip: text !important;
  -webkit-text-fill-color: transparent !important;
}

/* ═══════════════════════════════════════════════════════════════
   MORPHING COORDINATES & TRANSFORMATIONS
   All letters fit strictly INSIDE the rocket's shaded chambers!
   ═══════════════════════════════════════════════════════════════ */

/* ── MARS: S inside nose cone, R inside upper fuselage/wings,
            A inside lower fuselage, M inside bottom thruster bay ── */

/* S (index 3, starts at x=+90) -> moves to nose cone center (x=0, y=-92px) */
.morphing-active.theme-mars .letter-s {
  transform: translate(-90px, -92px) scale(0.60);
  filter: brightness(2.6) drop-shadow(0 0 14px rgba(255, 140, 50, 0.95));
}

/* R (index 2, starts at x=+30) -> moves to upper fuselage reactor bay (x=0, y=-36px) */
.morphing-active.theme-mars .letter-r {
  transform: translate(-30px, -36px) scale(0.66);
  filter: brightness(2.4) drop-shadow(0 0 12px rgba(235, 110, 40, 0.85));
}

/* A (index 1, starts at x=-30) -> moves to lower propellant bay (x=0, y=26px) */
.morphing-active.theme-mars .letter-a {
  transform: translate(30px, 26px) scale(0.66);
  filter: brightness(2.3) drop-shadow(0 0 12px rgba(215, 90, 30, 0.8));
}

/* M (index 0, starts at x=-90) -> moves to propulsion thrust bay (x=0, y=80px) */
.morphing-active.theme-mars .letter-m {
  transform: translate(90px, 80px) scale(0.70);
  filter: brightness(2.8) drop-shadow(0 0 16px rgba(255, 120, 50, 0.95));
}

/* ── MOON: N inside nose cone, O1 inside upper propellant tank,
            O2 inside lower propellant tank, M inside bottom thruster bay ── */

/* N (index 3, starts at x=+90) -> moves to nose cone center (x=0, y=-92px) */
.morphing-active.theme-moon .letter-n {
  transform: translate(-90px, -92px) scale(0.60);
  filter: brightness(2.6) drop-shadow(0 0 14px rgba(220, 240, 255, 0.95));
}

/* O1 (index 1, starts at x=-30) -> moves to upper cryo tank (x=0, y=-36px) */
.morphing-active.theme-moon .letter-o1 {
  transform: translate(30px, -36px) scale(0.64);
  filter: brightness(2.5) drop-shadow(0 0 14px rgba(200, 225, 255, 0.9));
}

/* O2 (index 2, starts at x=+30) -> moves to lower cryo tank (x=0, y=26px) */
.morphing-active.theme-moon .letter-o2 {
  transform: translate(-30px, 26px) scale(0.64);
  filter: brightness(2.5) drop-shadow(0 0 14px rgba(200, 225, 255, 0.9));
}

/* M (index 0, starts at x=-90) -> moves to propulsion thrust base (x=0, y=80px) */
.morphing-active.theme-moon .letter-m {
  transform: translate(90px, 80px) scale(0.70);
  filter: brightness(2.8) drop-shadow(0 0 16px rgba(220, 240, 255, 0.95));
}

/* ── RESPONSIVE DESIGN ──────────────────────────────────────── */
@media (max-width: 768px) {
  .explore-header {
    top: 16px;
    left: 18px;
    right: 18px;
    flex-wrap: wrap;
  }
  .planet-target-area {
    height: 44vh;
  }
  .launch-control-area {
    height: 42vh;
  }
  .archive-jump-btn {
    font-size: 0.6rem;
    padding: 6px 10px;
  }
}

/* ── DISCARDED EQUIPMENT ARCHIVE SECTION — PLANETARY TERRAIN BACKDROP ─── */
.equipment-archive-section {
  position: relative;
  z-index: 30;
  width: 100%;
  min-height: 100vh;
  padding: 0;
  overflow: hidden;
  border-top: 1px solid rgba(255, 255, 255, 0.08);
}

/* ═══ MARS TERRAIN BACKDROP ═══ */
.theme-mars .equipment-archive-section {
  background:
    linear-gradient(180deg,
      rgba(2, 1, 4, 0.72) 0%,
      rgba(14, 5, 2, 0.60) 20%,
      rgba(10, 4, 2, 0.55) 60%,
      rgba(3, 1, 1, 0.80) 100%),
    url('../assets/equipment/opportunity-rover.jpg') center center / cover no-repeat fixed;
}

/* ═══ MOON TERRAIN BACKDROP ═══ */
.theme-moon .equipment-archive-section {
  background:
    linear-gradient(180deg,
      rgba(2, 3, 8, 0.72) 0%,
      rgba(6, 10, 18, 0.60) 20%,
      rgba(4, 7, 14, 0.55) 60%,
      rgba(1, 2, 5, 0.80) 100%),
    url('../assets/equipment/ranger7-surface.jpg') center center / cover no-repeat fixed;
}

/* ═══ GLASS DECK WRAPPER — Frosted Glassmorphic Full-Section Container ═══ */
.archive-glass-deck {
  position: relative;
  width: 100%;
  min-height: 100vh;
  padding: 110px 32px 80px;
  backdrop-filter: blur(32px) saturate(160%);
  -webkit-backdrop-filter: blur(32px) saturate(160%);
}

/* Mars glass tint */
.theme-mars .archive-glass-deck {
  background: rgba(18, 7, 3, 0.48);
  box-shadow: inset 0 0 120px rgba(230, 90, 20, 0.08);
}

/* Moon glass tint */
.theme-moon .archive-glass-deck {
  background: rgba(8, 14, 26, 0.48);
  box-shadow: inset 0 0 120px rgba(100, 180, 255, 0.07);
}

/* Top specular rim highlight */
.theme-mars .archive-glass-deck::before,
.theme-moon .archive-glass-deck::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 1px;
  pointer-events: none;
}
.theme-mars .archive-glass-deck::before {
  background: linear-gradient(90deg, transparent 0%, rgba(255, 150, 70, 0.55) 50%, transparent 100%);
}
.theme-moon .archive-glass-deck::before {
  background: linear-gradient(90deg, transparent 0%, rgba(180, 220, 255, 0.5) 50%, transparent 100%);
}

.archive-inner {
  max-width: 1340px;
  margin: 0 auto;
  position: relative;
  z-index: 2;
}

.archive-header-banner {
  margin-bottom: 36px;
  text-align: center;
}

.archive-badge {
  display: inline-block;
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.25em;
  padding: 5px 14px;
  border-radius: 4px;
  text-transform: uppercase;
  margin-bottom: 12px;
}

.theme-mars .archive-badge {
  background: rgba(255, 90, 30, 0.15);
  color: #ff8c4e;
  border: 1px solid rgba(255, 110, 50, 0.4);
}

.theme-moon .archive-badge {
  background: rgba(100, 180, 255, 0.15);
  color: #99d5ff;
  border: 1px solid rgba(130, 200, 255, 0.4);
}

.archive-title {
  font-size: clamp(1.8rem, 3.2vw, 2.8rem);
  font-weight: 800;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  margin-bottom: 10px;
  color: #ffffff;
}

.archive-subtitle {
  font-size: 0.95rem;
  color: rgba(255, 255, 255, 0.65);
  letter-spacing: 0.04em;
  max-width: 720px;
  margin: 0 auto 28px;
  line-height: 1.5;
}

.archive-controls {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 16px;
  padding: 16px 24px;
  border-radius: 10px;
  backdrop-filter: blur(20px) saturate(150%);
  -webkit-backdrop-filter: blur(20px) saturate(150%);
}

.theme-mars .archive-controls {
  background: rgba(22, 8, 3, 0.55);
  border: 1px solid rgba(255, 150, 60, 0.25);
  box-shadow: inset 0 1px 0 rgba(255, 180, 90, 0.15);
}

.theme-moon .archive-controls {
  background: rgba(8, 14, 28, 0.55);
  border: 1px solid rgba(160, 210, 255, 0.22);
  box-shadow: inset 0 1px 0 rgba(200, 235, 255, 0.12);
}

.sort-control-group {
  display: flex;
  align-items: center;
  gap: 12px;
}

.control-label {
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.18em;
  color: rgba(255, 255, 255, 0.7);
}

.sort-select {
  background: rgba(6, 10, 18, 0.9);
  color: #ffffff;
  font-family: 'Space Grotesk', sans-serif;
  font-size: 0.82rem;
  font-weight: 600;
  border: 1px solid rgba(255, 255, 255, 0.22);
  border-radius: 6px;
  padding: 8px 14px;
  cursor: pointer;
  outline: none;
  transition: all 0.2s ease;
}

.sort-select:hover, .sort-select:focus {
  border-color: rgba(255, 255, 255, 0.55);
}

.artifact-counter {
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.18em;
  color: rgba(255, 255, 255, 0.6);
}

/* Equipment Grid */
.equipment-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(295px, 1fr));
  gap: 24px;
  margin-top: 32px;
}

.equipment-card {
  background: rgba(10, 4, 2, 0.52);
  border: 1px solid rgba(255, 255, 255, 0.10);
  border-radius: 14px;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  transition: transform 0.28s cubic-bezier(0.4, 0, 0.2, 1), border-color 0.28s ease, box-shadow 0.28s ease;
  cursor: pointer;
  backdrop-filter: blur(24px) saturate(160%);
  -webkit-backdrop-filter: blur(24px) saturate(160%);
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.55), inset 0 1px 0 rgba(255, 255, 255, 0.08);
}

/* Mars glass card */
.theme-mars .equipment-card {
  background: rgba(22, 8, 3, 0.52);
  border-top: 1px solid rgba(255, 160, 80, 0.30);
  box-shadow: 0 10px 36px rgba(0, 0, 0, 0.60), inset 0 1px 0 rgba(255, 180, 90, 0.18);
}

/* Moon glass card */
.theme-moon .equipment-card {
  background: rgba(8, 14, 28, 0.52);
  border-top: 1px solid rgba(180, 220, 255, 0.30);
  box-shadow: 0 10px 36px rgba(0, 0, 0, 0.60), inset 0 1px 0 rgba(190, 225, 255, 0.18);
}

/* Staggered entrance animation when automatically revealed after launch */
.equipment-archive-section.active-revealed .equipment-card {
  animation: cardReveal 0.6s cubic-bezier(0.4, 0, 0.2, 1) both;
}

@keyframes cardReveal {
  from {
    opacity: 0;
    transform: translateY(28px) scale(0.97);
  }
  to {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

.equipment-archive-section.active-revealed .equipment-card:nth-child(1) { animation-delay: 0.05s; }
.equipment-archive-section.active-revealed .equipment-card:nth-child(2) { animation-delay: 0.12s; }
.equipment-archive-section.active-revealed .equipment-card:nth-child(3) { animation-delay: 0.19s; }
.equipment-archive-section.active-revealed .equipment-card:nth-child(4) { animation-delay: 0.26s; }
.equipment-archive-section.active-revealed .equipment-card:nth-child(5) { animation-delay: 0.33s; }
.equipment-archive-section.active-revealed .equipment-card:nth-child(6) { animation-delay: 0.40s; }
.equipment-archive-section.active-revealed .equipment-card:nth-child(7) { animation-delay: 0.47s; }
.equipment-archive-section.active-revealed .equipment-card:nth-child(8) { animation-delay: 0.54s; }

.equipment-card:hover {
  transform: translateY(-7px);
}

.theme-mars .equipment-card:hover {
  border-color: rgba(255, 130, 55, 0.70);
  box-shadow: 0 20px 50px rgba(230, 70, 10, 0.32), inset 0 1px 0 rgba(255, 200, 120, 0.25);
}

.theme-moon .equipment-card:hover {
  border-color: rgba(150, 210, 255, 0.70);
  box-shadow: 0 20px 50px rgba(80, 160, 255, 0.28), inset 0 1px 0 rgba(200, 235, 255, 0.22);
}

.card-image-wrap {
  position: relative;
  width: 100%;
  height: 200px;
  background: #050810;
  overflow: hidden;
}

.card-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.4s ease;
  filter: contrast(1.05) brightness(0.96);
}

.equipment-card:hover .card-img {
  transform: scale(1.06);
}

.card-year-badge {
  position: absolute;
  top: 12px;
  left: 12px;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  padding: 4px 10px;
  border-radius: 4px;
  background: rgba(0, 0, 0, 0.82);
  backdrop-filter: blur(6px);
  border: 1px solid rgba(255, 255, 255, 0.3);
  color: #ffffff;
}

.card-type-badge {
  position: absolute;
  top: 12px;
  right: 12px;
  font-size: 0.65rem;
  font-weight: 600;
  letter-spacing: 0.1em;
  padding: 4px 8px;
  border-radius: 4px;
  text-transform: uppercase;
  background: rgba(10, 18, 32, 0.85);
  border: 1px solid rgba(255, 255, 255, 0.22);
  color: rgba(255, 255, 255, 0.88);
}

.card-body {
  padding: 22px;
  display: flex;
  flex-direction: column;
  flex-grow: 1;
}

.card-title {
  font-size: 1.15rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  color: #ffffff;
  margin-bottom: 6px;
  line-height: 1.3;
}

.card-location {
  font-size: 0.72rem;
  font-weight: 600;
  color: rgba(255, 255, 255, 0.6);
  letter-spacing: 0.08em;
  text-transform: uppercase;
  margin-bottom: 12px;
  display: flex;
  align-items: center;
  gap: 6px;
}

.card-status-row {
  margin-bottom: 14px;
  display: flex;
  align-items: center;
  gap: 8px;
}

.status-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  flex-shrink: 0;
}

.status-inactive .status-dot {
  background: #ffaa44;
  box-shadow: 0 0 8px #ff8800;
}

.status-left-surface .status-dot {
  background: #4ade80;
  box-shadow: 0 0 8px #22c55e;
}

.status-impacted .status-dot {
  background: #f87171;
  box-shadow: 0 0 8px #ef4444;
}

.status-mission-ended .status-dot {
  background: #a78bfa;
  box-shadow: 0 0 8px #8b5cf6;
}

.card-status-text {
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.06em;
  color: rgba(255, 255, 255, 0.85);
}

.card-summary {
  font-size: 0.82rem;
  line-height: 1.55;
  color: rgba(255, 255, 255, 0.7);
  margin-bottom: 20px;
  flex-grow: 1;
}

.card-dossier-btn {
  width: 100%;
  padding: 10px 16px;
  font-family: 'Space Grotesk', sans-serif;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  border-radius: 6px;
  border: 1px solid rgba(255, 255, 255, 0.2);
  background: rgba(255, 255, 255, 0.05);
  color: #ffffff;
  cursor: pointer;
  transition: all 0.2s ease;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
}

.equipment-card:hover .card-dossier-btn {
  background: rgba(255, 255, 255, 0.15);
  border-color: rgba(255, 255, 255, 0.45);
}

/* ── MISSION DOSSIER MODAL ───────────────────────────────────── */
.dossier-modal-backdrop {
  position: fixed;
  inset: 0;
  z-index: 1000;
  background: rgba(2, 4, 8, 0.88);
  backdrop-filter: blur(16px);
  display: none;
  align-items: center;
  justify-content: center;
  padding: 24px;
  opacity: 0;
  transition: opacity 0.3s ease;
}

.dossier-modal-backdrop.active {
  display: flex;
  opacity: 1;
}

.dossier-modal-card {
  position: relative;
  width: 100%;
  max-width: 960px;
  max-height: 90vh;
  border-radius: 20px;
  overflow-y: auto;
  animation: modalSlideUp 0.35s cubic-bezier(0.4, 0, 0.2, 1);
  backdrop-filter: blur(36px) saturate(170%);
  -webkit-backdrop-filter: blur(36px) saturate(170%);
  scrollbar-width: thin;
  scrollbar-color: rgba(255,255,255,0.15) transparent;
}

/* Mars modal glass */
.theme-mars .dossier-modal-card {
  background: rgba(18, 7, 3, 0.68);
  border: 1px solid rgba(255, 160, 70, 0.28);
  border-top: 1px solid rgba(255, 180, 100, 0.55);
  box-shadow:
    0 40px 100px rgba(0, 0, 0, 0.90),
    inset 0 1px 0 rgba(255, 200, 130, 0.22),
    0 0 60px rgba(230, 80, 20, 0.08);
}

/* Moon modal glass */
.theme-moon .dossier-modal-card {
  background: rgba(8, 14, 28, 0.68);
  border: 1px solid rgba(170, 215, 255, 0.28);
  border-top: 1px solid rgba(190, 230, 255, 0.55);
  box-shadow:
    0 40px 100px rgba(0, 0, 0, 0.90),
    inset 0 1px 0 rgba(200, 235, 255, 0.20),
    0 0 60px rgba(80, 160, 255, 0.07);
}

@keyframes modalSlideUp {
  from { transform: translateY(30px) scale(0.97); }
  to { transform: translateY(0) scale(1); }
}

.dossier-close-btn {
  position: absolute;
  top: 18px;
  right: 20px;
  width: 38px;
  height: 38px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.1);
  border: 1px solid rgba(255, 255, 255, 0.25);
  color: #ffffff;
  font-size: 1.4rem;
  line-height: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  z-index: 10;
  transition: all 0.2s ease;
}

.dossier-close-btn:hover {
  background: rgba(255, 255, 255, 0.25);
  transform: rotate(90deg);
}

.dossier-layout {
  display: grid;
  grid-template-columns: 1fr 1.35fr;
  gap: 32px;
  padding: 36px;
}

@media (max-width: 860px) {
  .dossier-layout {
    grid-template-columns: 1fr;
    padding: 24px;
    gap: 24px;
  }
}

.dossier-image-col {
  display: flex;
  flex-direction: column;
  gap: 18px;
}

.dossier-img {
  width: 100%;
  border-radius: 10px;
  border: 1px solid rgba(255, 255, 255, 0.16);
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.6);
  object-fit: cover;
  max-height: 320px;
}

.dossier-telemetry-table {
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border-radius: 10px;
  padding: 16px;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.theme-mars .dossier-telemetry-table {
  background: rgba(18, 7, 3, 0.65);
  border: 1px solid rgba(255, 150, 60, 0.22);
  box-shadow: inset 0 1px 0 rgba(255, 180, 90, 0.12);
}

.theme-moon .dossier-telemetry-table {
  background: rgba(8, 14, 28, 0.65);
  border: 1px solid rgba(160, 210, 255, 0.20);
  box-shadow: inset 0 1px 0 rgba(200, 235, 255, 0.10);
}

.telemetry-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 0.76rem;
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
  padding-bottom: 6px;
}

.telemetry-row:last-child {
  border-bottom: none;
  padding-bottom: 0;
}

.telemetry-label {
  color: rgba(255, 255, 255, 0.5);
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.telemetry-val {
  color: #ffffff;
  font-weight: 600;
  text-align: right;
}

.locate-planet-btn {
  width: 100%;
  padding: 12px;
  font-family: 'Space Grotesk', sans-serif;
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  border-radius: 8px;
  border: 1px solid;
  cursor: pointer;
  transition: all 0.25s ease;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
}

.theme-mars .locate-planet-btn {
  background: rgba(255, 90, 30, 0.2);
  border-color: rgba(255, 120, 60, 0.6);
  color: #ff9966;
}

.theme-mars .locate-planet-btn:hover {
  background: rgba(255, 90, 30, 0.35);
  box-shadow: 0 0 16px rgba(255, 90, 30, 0.5);
}

.theme-moon .locate-planet-btn {
  background: rgba(100, 180, 255, 0.2);
  border-color: rgba(140, 200, 255, 0.6);
  color: #99d5ff;
}

.theme-moon .locate-planet-btn:hover {
  background: rgba(100, 180, 255, 0.35);
  box-shadow: 0 0 16px rgba(100, 180, 255, 0.5);
}

.dossier-info-col {
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.dossier-title {
  font-size: 1.6rem;
  font-weight: 800;
  letter-spacing: 0.04em;
  line-height: 1.25;
  color: #ffffff;
}

.dossier-section-title {
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.5);
  margin-bottom: 6px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
  padding-bottom: 4px;
}

.dossier-text {
  font-size: 0.88rem;
  line-height: 1.65;
  color: rgba(255, 255, 255, 0.85);
}

.dossier-list {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.dossier-list li {
  font-size: 0.85rem;
  line-height: 1.55;
  color: rgba(255, 255, 255, 0.85);
  position: relative;
  padding-left: 18px;
}

.theme-mars .dossier-list li::before {
  content: "▪";
  position: absolute;
  left: 0;
  color: #ff9966;
}

.theme-moon .dossier-list li::before {
  content: "▪";
  position: absolute;
  left: 0;
  color: #99d5ff;
}
