/*


 */

/* ===== RESET & BASE ===== */
*,
*::before,
*::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html,
body {
  width: 100%;
  height: 100%;
  font-family: "Courier New", monospace;
  background: #0a0a0f;
  color: #e0e0e0;
}

/* Game view locks scroll; shop page needs it */
body:has(#game-root) {
  overflow: hidden;
}

/* ===== GAME ROOT ===== */
#game-root {
  position: relative;
  width: 100vw;
  height: 100vh;
  overflow: hidden;
}

/* ===== MAP ===== */
#map {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  z-index: 1;
  cursor: crosshair !important;
}

#map .leaflet-container {
  background: #0d1117;
}

/* ===== HUD TOP BAR ===== */
#hud-top {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 48px;
  background: linear-gradient(
    180deg,
    rgba(0, 0, 0, 0.92) 0%,
    rgba(0, 0, 0, 0.7) 100%
  );
  border-bottom: 1px solid #ff4400;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 16px;
  z-index: 1000;
  backdrop-filter: blur(4px);
}

#hud-title {
  font-size: 18px;
  font-weight: bold;
  color: #ff4400;
  letter-spacing: 3px;
  text-shadow: 0 0 10px #ff4400;
}

#hud-stats {
  display: flex;
  gap: 24px;
  font-size: 13px;
  color: #aaa;
}

#hud-stats b {
  color: #ff6600;
}

#hud-ammo {
  font-size: 13px;
  color: #aaa;
}

#hud-ammo b {
  color: #00ff88;
}

/* ===== WEAPON PANEL ===== */
#weapon-panel {
  position: absolute;
  top: 58px;
  left: 10px;
  width: 190px;
  background: rgba(5, 8, 15, 0.93);
  border: 1px solid #333;
  border-radius: 6px;
  padding: 10px;
  z-index: 1000;
  backdrop-filter: blur(8px);
  box-shadow:
    0 4px 24px rgba(0, 0, 0, 0.7),
    0 0 20px rgba(255, 68, 0, 0.1);
}

.panel-title {
  font-size: 10px;
  letter-spacing: 2px;
  color: #666;
  margin-bottom: 6px;
  margin-top: 2px;
}

.filter-row {
  display: flex;
  align-items: center;
  gap: 4px;
  flex-wrap: nowrap;
}

.panel-divider {
  height: 1px;
  background: #222;
  margin: 10px 0;
}

.weapon-btn {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  width: 100%;
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid #2a2a2a;
  border-radius: 4px;
  padding: 8px 10px;
  cursor: pointer;
  margin-bottom: 6px;
  color: #ccc;
  transition: all 0.15s;
  text-align: left;
}

.weapon-btn:hover {
  background: rgba(255, 68, 0, 0.12);
  border-color: #ff4400;
  color: #fff;
}

.weapon-btn.active {
  background: rgba(255, 68, 0, 0.2);
  border-color: #ff4400;
  color: #fff;
  box-shadow: 0 0 10px rgba(255, 68, 0, 0.3);
}

.weapon-icon {
  width: 24px;
  height: 24px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 2px;
}
.weapon-icon img {
  width: 22px;
  height: 22px;
  display: block;
  object-fit: contain;
}

.weapon-label {
  font-size: 12px;
  font-weight: bold;
  letter-spacing: 1px;
}

.weapon-key {
  font-size: 10px;
  color: #555;
}

.filter-btn {
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid #2a2a2a;
  border-radius: 4px;
  color: #888;
  cursor: pointer;
  padding: 3px 7px;
  font-size: 10px;
  margin-right: 0;
  margin-bottom: 0;
  font-family: "Courier New", monospace;
  transition: all 0.15s;
  white-space: nowrap;
}

.filter-btn:hover,
.filter-btn.active {
  border-color: #ff4400;
  color: #ff6600;
  background: rgba(255, 68, 0, 0.1);
}

#btn-reset {
  width: 24px;
  min-width: 24px;
  height: 24px;
  background: transparent;
  border: 1px solid #333;
  border-radius: 4px;
  color: #666;
  cursor: pointer;
  padding: 0;
  margin-left: 2px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 13px;
  line-height: 1;
  font-family: "Courier New", monospace;
  transition: all 0.15s;
}

#btn-reset:hover {
  border-color: #888;
  color: #ccc;
}

/* ===== INFO PANEL ===== */
#info-panel {
  position: absolute;
  bottom: 20px;
  left: 50%;
  transform: translateX(-50%);
  width: 320px;
  background: rgba(5, 8, 15, 0.95);
  border: 1px solid #ff4400;
  border-radius: 6px;
  padding: 16px;
  z-index: 1000;
  backdrop-filter: blur(10px);
  box-shadow: 0 4px 30px rgba(255, 68, 0, 0.3);
  transition: all 0.2s;
}

#info-panel.hidden {
  display: none;
}

#info-close {
  position: absolute;
  top: 8px;
  right: 12px;
  cursor: pointer;
  color: #666;
  font-size: 14px;
}

#info-close:hover {
  color: #fff;
}

#info-visual {
  display: flex;
  justify-content: center;
  margin: 4px 0 10px;
}

#info-target-icon-wrap {
  position: relative;
  width: 86px;
  height: 86px;
  border-radius: 16px;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 1px solid rgba(255, 136, 0, 0.55);
  background: radial-gradient(
    circle at 30% 30%,
    rgba(255, 170, 0, 0.22),
    rgba(255, 90, 0, 0.08) 45%,
    rgba(0, 0, 0, 0.35) 100%
  );
  box-shadow:
    inset 0 0 18px rgba(255, 140, 0, 0.16),
    0 0 16px rgba(255, 95, 0, 0.28);
}

#info-target-icon {
  width: 66px;
  height: 66px;
  object-fit: contain;
  filter: drop-shadow(0 0 8px rgba(255, 166, 0, 0.75));
}

#info-target-fire {
  position: absolute;
  left: 50%;
  bottom: 6px;
  width: 24px;
  height: 34px;
  transform: translateX(-50%);
  border-radius: 50% 50% 35% 35%;
  opacity: 0;
  pointer-events: none;
}

#info-target-fire.active {
  opacity: 1;
  background: radial-gradient(
    ellipse at 50% 100%,
    #ffe16a 0%,
    #ffb117 28%,
    #ff6212 58%,
    rgba(255, 72, 0, 0) 100%
  );
  filter: drop-shadow(0 0 8px rgba(255, 196, 0, 0.8));
  animation: fireFlicker 0.28s ease-in-out infinite alternate;
}

#info-target-fire.active.destroyed {
  width: 30px;
  height: 42px;
  background: radial-gradient(
    ellipse at 50% 100%,
    #ffe687 0%,
    #ffaf18 25%,
    #ff4d11 55%,
    rgba(255, 72, 0, 0) 100%
  );
}

#info-name {
  font-size: 16px;
  font-weight: bold;
  color: #fff;
  letter-spacing: 1px;
  margin-bottom: 4px;
}

#info-type {
  font-size: 11px;
  color: #ff6600;
  letter-spacing: 2px;
  text-transform: uppercase;
  margin-bottom: 4px;
}

#info-city {
  font-size: 12px;
  color: #888;
  margin-bottom: 8px;
}

#info-intel {
  font-size: 11px;
  color: #c8d7ff;
  line-height: 1.35;
  margin-bottom: 6px;
}

#info-source {
  font-size: 10px;
  color: #7e8799;
  margin-bottom: 10px;
}

#info-status {
  font-size: 12px;
  color: #00ff88;
  margin-bottom: 12px;
}

#info-status.damaged {
  color: #ff9900;
}

#info-status.destroyed {
  color: #ff2200;
}

#btn-strike {
  width: 100%;
  background: linear-gradient(135deg, #ff2200, #cc1100);
  border: none;
  border-radius: 4px;
  color: #fff;
  cursor: pointer;
  padding: 10px;
  font-size: 14px;
  font-weight: bold;
  letter-spacing: 2px;
  font-family: "Courier New", monospace;
  transition: all 0.15s;
  text-shadow: 0 1px 3px rgba(0, 0, 0, 0.5);
}

#btn-strike:hover {
  background: linear-gradient(135deg, #ff4400, #ee2200);
  box-shadow: 0 0 20px rgba(255, 68, 0, 0.5);
}

#btn-strike:disabled {
  background: #333;
  color: #666;
  cursor: not-allowed;
  box-shadow: none;
}

/* ===== STRIKE LOG ===== */
#strike-log {
  position: absolute;
  top: 58px;
  right: 10px;
  width: 220px;
  max-height: 340px;
  background: rgba(5, 8, 15, 0.9);
  border: 1px solid #222;
  border-radius: 6px;
  padding: 10px;
  z-index: 1000;
  backdrop-filter: blur(8px);
  overflow: hidden;
}

#global-log {
  position: absolute;
  top: 408px;
  right: 10px;
  width: 220px;
  max-height: 220px;
  background: rgba(5, 8, 15, 0.9);
  border: 1px solid #224;
  border-radius: 6px;
  padding: 10px;
  z-index: 1000;
  backdrop-filter: blur(8px);
  overflow: hidden;
}

.log-title {
  font-size: 10px;
  letter-spacing: 2px;
  color: #555;
  margin-bottom: 6px;
}

#log-entries {
  display: flex;
  flex-direction: column;
  gap: 4px;
  max-height: 300px;
  overflow-y: auto;
}

#global-log-entries {
  display: flex;
  flex-direction: column;
  gap: 5px;
  max-height: 180px;
  overflow-y: auto;
}

.log-entry {
  font-size: 11px;
  color: #888;
  border-left: 2px solid #333;
  padding-left: 6px;
  animation: logFadeIn 0.3s ease;
}

.log-entry.hit {
  color: #ff6600;
  border-left-color: #ff4400;
}

.log-entry.destroyed {
  color: #ff2200;
  border-left-color: #ff0000;
}

.log-entry .log-time {
  color: #444;
  font-size: 10px;
}

.global-entry {
  font-size: 10px;
  line-height: 1.35;
  color: #aab8d6;
  border-left: 2px solid #364d7a;
  padding-left: 6px;
  animation: logFadeIn 0.3s ease;
}
.global-entry.launch {
  border-left-color: #2f8fff;
  color: #8dc6ff;
}
.global-entry.impact {
  border-left-color: #ff7a33;
  color: #ffc48a;
}
.global-time {
  color: #6f7f9d;
  font-size: 9px;
}

.log-weapon-icon {
  width: 12px;
  height: 12px;
  display: inline-block;
  vertical-align: -1px;
  margin-right: 3px;
  object-fit: contain;
}

@keyframes logFadeIn {
  from {
    opacity: 0;
    transform: translateX(8px);
  }
  to {
    opacity: 1;
    transform: translateX(0);
  }
}

/* ===== CROSSHAIR ===== */
#crosshair {
  position: fixed;
  width: 28px;
  height: 28px;
  pointer-events: none;
  z-index: 9999;
  transform: translate(-50%, -50%);
  display: none;
}

#crosshair::before,
#crosshair::after {
  content: "";
  position: absolute;
  background: rgba(255, 68, 0, 0.8);
}

#crosshair::before {
  width: 2px;
  height: 100%;
  left: 50%;
  top: 0;
  transform: translateX(-50%);
}

#crosshair::after {
  width: 100%;
  height: 2px;
  top: 50%;
  left: 0;
  transform: translateY(-50%);
}

/* ===== LEAFLET MARKER OVERRIDES ===== */
.target-marker {
  background: transparent;
  border: none;
}

/* ===== TARGET MARKERS (svg icons) ===== */
.marker-icon {
  line-height: 1;
  cursor: pointer;
  user-select: none;
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 2px;
  filter: drop-shadow(0 0 4px rgba(255, 68, 0, 0.8));
  animation: markerPulse 2.5s infinite;
  transition: filter 0.2s;
}
.marker-sprite {
  width: 30px;
  height: 30px;
  display: block;
  object-fit: contain;
  position: relative;
  z-index: 2;
}

.marker-fire {
  position: absolute;
  left: 50%;
  bottom: 11px;
  width: 20px;
  height: 30px;
  transform: translateX(-50%);
  pointer-events: none;
  z-index: 3;
  border-radius: 50% 50% 34% 34%;
  background: radial-gradient(
    ellipse at 50% 100%,
    #ffe97f 0%,
    #ffb21f 30%,
    #ff6615 58%,
    rgba(255, 82, 0, 0) 100%
  );
  filter: drop-shadow(0 0 7px rgba(255, 190, 0, 0.85));
  animation: fireFlicker 0.25s ease-in-out infinite alternate;
}

.marker-fire.destroyed {
  width: 26px;
  height: 38px;
  bottom: 8px;
}
.marker-icon:hover {
  filter: drop-shadow(0 0 8px #fff) brightness(1.3);
}

.marker-icon.military {
  filter: drop-shadow(0 0 5px rgba(255, 0, 0, 0.9));
}
.marker-icon.airport {
  filter: drop-shadow(0 0 5px rgba(255, 204, 0, 0.9));
}
.marker-icon.civil {
  filter: drop-shadow(0 0 5px rgba(255, 136, 0, 0.9));
}
.marker-icon.defense {
  filter: drop-shadow(0 0 5px rgba(0, 220, 255, 0.9));
}
.marker-icon.carrier {
  filter: drop-shadow(0 0 6px rgba(30, 120, 255, 1));
}
.marker-icon.carrier .marker-sprite {
  width: 28px;
  height: 28px;
}

.map-dot {
  width: 12px;
  height: 12px;
  border-radius: 50%;
  border: 2px solid rgba(255, 255, 255, 0.9);
  box-shadow: 0 0 8px rgba(0, 0, 0, 0.5);
}
.map-dot.military {
  background: #ff4d4f;
}
.map-dot.airport {
  background: #ffd166;
}
.map-dot.civil {
  background: #ff9f43;
}
.map-dot.defense {
  background: #2ec4ff;
}
.map-dot.carrier {
  background: #6ba4ff;
}
.map-dot.launch {
  background: #ffb347;
}
.map-dot.damaged {
  box-shadow: 0 0 8px rgba(255, 140, 0, 0.9);
}
.map-dot.destroyed {
  background: #5a5a5a;
  border-color: rgba(180, 180, 180, 0.8);
  opacity: 0.7;
}

.marker-icon.damaged {
  animation: markerDamaged 0.8s infinite;
}
.marker-icon.destroyed {
  opacity: 0.62;
  animation: none;
}

.marker-icon.destroyed .marker-sprite {
  filter: grayscale(0.55) brightness(0.62);
  opacity: 0.82;
}

/* HP bar under icon */
.marker-hp {
  width: 26px;
  height: 3px;
  background: rgba(0, 0, 0, 0.6);
  border-radius: 2px;
  overflow: hidden;
  position: relative;
  z-index: 4;
}
.marker-hp span {
  display: block;
  height: 100%;
  background: linear-gradient(90deg, #ff4400, #ffcc00);
  border-radius: 2px;
  transition: width 0.3s;
}

@keyframes markerPulse {
  0%,
  100% {
    transform: scale(1);
  }
  50% {
    transform: scale(1.12);
  }
}
@keyframes markerDamaged {
  0%,
  100% {
    transform: scale(1);
    filter: drop-shadow(0 0 4px #ff9900);
  }
  50% {
    transform: scale(1.15);
    filter: drop-shadow(0 0 10px #ff4400);
  }
}

/* ===== CITY LABEL ===== */
.city-label {
  background: transparent !important;
  border: none !important;
  box-shadow: none !important;
}

.city-label-text {
  color: #ffcc00;
  font-size: 11px;
  font-weight: bold;
  letter-spacing: 1px;
  text-shadow:
    0 0 6px rgba(0, 0, 0, 0.9),
    0 0 12px rgba(0, 0, 0, 0.8);
  font-family: "Courier New", monospace;
  white-space: nowrap;
  pointer-events: none;
}

/* ===== EXPLOSION OVERLAY ===== */
.explosion-ring {
  position: absolute;
  border-radius: 50%;
  border: 3px solid #ff4400;
  pointer-events: none;
  z-index: 999;
  animation: explodeRing 0.8s ease-out forwards;
}

@keyframes explodeRing {
  0% {
    width: 0;
    height: 0;
    opacity: 1;
    transform: translate(-50%, -50%) scale(0);
  }
  100% {
    width: 120px;
    height: 120px;
    opacity: 0;
    transform: translate(-50%, -50%) scale(1);
  }
}

.explosion-flash {
  position: absolute;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: radial-gradient(
    circle,
    #ffff88 0%,
    #ff8800 40%,
    #ff2200 70%,
    transparent 100%
  );
  pointer-events: none;
  z-index: 999;
  transform: translate(-50%, -50%);
  animation: explodeFlash 0.5s ease-out forwards;
}

@keyframes explodeFlash {
  0% {
    transform: translate(-50%, -50%) scale(0);
    opacity: 1;
  }
  60% {
    transform: translate(-50%, -50%) scale(1.8);
    opacity: 0.8;
  }
  100% {
    transform: translate(-50%, -50%) scale(2.5);
    opacity: 0;
  }
}

.drone-icon-flying {
  position: absolute;
  font-size: 18px;
  pointer-events: none;
  z-index: 998;
  animation: droneFly 0.1s linear;
}

/* ===== LEAFLET POPUP STYLE ===== */
.leaflet-popup-content-wrapper {
  background: rgba(5, 8, 15, 0.95) !important;
  border: 1px solid #ff4400 !important;
  border-radius: 4px !important;
  color: #ccc !important;
  font-family: "Courier New", monospace !important;
  font-size: 12px !important;
}

.leaflet-popup-tip {
  background: #ff4400 !important;
}

.leaflet-popup-close-button {
  color: #ff4400 !important;
}

/* ===== CANVAS for 3D buildings ===== */
#buildings-canvas {
  position: absolute;
  inset: 0;
  pointer-events: none;
  z-index: 500;
}

/* ===== SCROLLBAR ===== */
::-webkit-scrollbar {
  width: 4px;
}
::-webkit-scrollbar-track {
  background: #111;
}
::-webkit-scrollbar-thumb {
  background: #333;
  border-radius: 2px;
}
::-webkit-scrollbar-thumb:hover {
  background: #555;
}

/* ===== TOAST notifications ===== */
.game-toast {
  position: fixed;
  top: 60px;
  left: 50%;
  transform: translateX(-50%);
  background: rgba(255, 68, 0, 0.9);
  color: #fff;
  padding: 8px 20px;
  border-radius: 4px;
  font-size: 13px;
  letter-spacing: 1px;
  z-index: 9000;
  animation: toastAnim 2s ease forwards;
  pointer-events: none;
}

@keyframes toastAnim {
  0% {
    opacity: 0;
    transform: translateX(-50%) translateY(-10px);
  }
  15% {
    opacity: 1;
    transform: translateX(-50%) translateY(0);
  }
  75% {
    opacity: 1;
  }
  100% {
    opacity: 0;
  }
}

/* ===== MINIMAP ===== */
.leaflet-control-attribution {
  display: none !important;
}

/* ===== LAUNCH PANEL ===== */
#launch-panel {
  position: absolute;
  top: 58px;
  left: 210px;
  width: 200px;
  background: rgba(5, 8, 15, 0.93);
  border: 1px solid #333;
  border-radius: 6px;
  padding: 12px;
  z-index: 1000;
  backdrop-filter: blur(8px);
  box-shadow:
    0 4px 24px rgba(0, 0, 0, 0.7),
    0 0 20px rgba(255, 68, 0, 0.08);
  max-height: calc(100vh - 80px);
  overflow-y: auto;
}

#launch-site-list {
  display: flex;
  flex-direction: column;
  gap: 3px;
}

.launch-site-btn {
  display: flex;
  flex-direction: column;
  width: 100%;
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid #2a2a2a;
  border-radius: 4px;
  padding: 5px 8px;
  cursor: pointer;
  color: #bbb;
  font-family: "Courier New", monospace;
  font-size: 11px;
  text-align: left;
  transition: all 0.15s;
}

.launch-site-btn:hover {
  background: rgba(255, 150, 0, 0.1);
  border-color: #ff9900;
  color: #fff;
}

.launch-site-btn.active {
  background: rgba(255, 150, 0, 0.2);
  border-color: #ff9900;
  color: #ffcc00;
  box-shadow: 0 0 8px rgba(255, 153, 0, 0.3);
}

.launch-site-name {
  font-weight: bold;
  letter-spacing: 0.5px;
}

.launch-site-region {
  color: #555;
  font-size: 10px;
}

/* ===== SWARM BUTTONS ===== */
#swarm-btns {
  display: flex;
  gap: 4px;
  flex-wrap: wrap;
}

.swarm-btn {
  flex: 1;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid #2a2a2a;
  border-radius: 4px;
  color: #888;
  cursor: pointer;
  padding: 5px 4px;
  font-size: 11px;
  font-family: "Courier New", monospace;
  font-weight: bold;
  transition: all 0.15s;
  text-align: center;
}

.swarm-btn:hover {
  border-color: #ff9900;
  color: #ffcc00;
  background: rgba(255, 153, 0, 0.1);
}

.swarm-btn.active {
  border-color: #ff9900;
  color: #ffcc00;
  background: rgba(255, 153, 0, 0.2);
  box-shadow: 0 0 6px rgba(255, 153, 0, 0.3);
}

/* ===== FLIGHT TIME DISPLAY ===== */
#info-flighttime {
  font-size: 11px;
  color: #4499ff;
  margin-bottom: 10px;
  letter-spacing: 0.5px;
}

/* ===== LAUNCH SITE MARKER ===== */
.launch-marker-dot {
  width: 14px;
  height: 14px;
  border-radius: 50%;
  border: 2px solid #ff9900;
  background: rgba(255, 153, 0, 0.5);
  box-shadow: 0 0 10px rgba(255, 153, 0, 0.7);
  animation: launchPulse 1s infinite;
}

.launch-marker-icon {
  width: 22px;
  height: 22px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  filter: drop-shadow(0 0 8px rgba(255, 153, 0, 0.85));
}

.launch-marker-icon img {
  width: 22px;
  height: 22px;
  display: block;
  object-fit: contain;
}

@keyframes launchPulse {
  0%,
  100% {
    box-shadow: 0 0 0 0 rgba(255, 153, 0, 0.7);
  }
  50% {
    box-shadow: 0 0 0 8px rgba(255, 153, 0, 0);
  }
}

.launch-site-line {
  stroke: rgba(255, 153, 0, 0.3);
  stroke-width: 1;
  stroke-dasharray: 6 4;
  fill: none;
}

/* ===== LAUNCH GROUP TABS ===== */
#launch-group-tabs {
  display: flex;
  gap: 4px;
  margin-bottom: 8px;
}

.launch-tab {
  flex: 1;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid #2a2a2a;
  border-radius: 4px;
  color: #888;
  cursor: pointer;
  padding: 5px 4px;
  font-size: 11px;
  font-family: "Courier New", monospace;
  font-weight: bold;
  transition: all 0.15s;
  text-align: center;
}

.launch-tab:hover {
  border-color: #ff9900;
  color: #ffcc00;
  background: rgba(255, 153, 0, 0.1);
}

.launch-tab.active {
  border-color: #ff9900;
  color: #ffcc00;
  background: rgba(255, 153, 0, 0.2);
  box-shadow: 0 0 6px rgba(255, 153, 0, 0.3);
}

/* ===== TARGET TOOLTIP BALLOON ===== */
.target-tooltip.leaflet-tooltip {
  background: rgba(5, 8, 18, 0.97) !important;
  border: 1px solid #ff4400 !important;
  border-radius: 6px !important;
  padding: 10px 13px !important;
  box-shadow:
    0 0 16px rgba(255, 68, 0, 0.35),
    0 4px 20px rgba(0, 0, 0, 0.7) !important;
  font-family: "Courier New", monospace !important;
  min-width: 180px;
  pointer-events: none;
  white-space: nowrap;
}

/* Tooltip arrow */
.target-tooltip.leaflet-tooltip-top::before {
  border-top-color: #ff4400 !important;
}

.tt-name {
  font-size: 13px;
  font-weight: bold;
  color: #fff;
  margin-bottom: 0;
  white-space: normal;
  line-height: 1.3;
}

.tt-head {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  margin-bottom: 4px;
}

.tt-icon {
  width: 42px;
  height: 42px;
  display: block;
  flex: 0 0 42px;
  object-fit: contain;
}

.tt-meta {
  font-size: 11px;
  color: #888;
  margin-bottom: 2px;
}

.tt-intel {
  font-size: 10px;
  color: #c3cff5;
  line-height: 1.35;
  margin: 4px 0;
}

.tt-source {
  font-size: 9px;
  color: #79839a;
  margin: 0 0 6px;
}

.tt-type {
  font-size: 11px;
  color: #aaa;
  margin-bottom: 7px;
}

.tt-hp-track {
  width: 100%;
  height: 4px;
  background: rgba(255, 255, 255, 0.1);
  border-radius: 3px;
  overflow: hidden;
  margin-bottom: 6px;
}

.tt-hp-fill {
  height: 100%;
  border-radius: 3px;
  transition: width 0.3s;
}

.tt-status {
  font-size: 11px;
  font-weight: bold;
  letter-spacing: 0.5px;
  margin-bottom: 5px;
}

.tt-hint {
  font-size: 10px;
  color: #444;
  margin-top: 4px;
  border-top: 1px solid #1a1a1a;
  padding-top: 4px;
}

/* ===== INTERCEPTOR ANIMATION ===== */
.interceptor-dot {
  position: absolute;
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: #00ffcc;
  z-index: 999;
  pointer-events: none;
  box-shadow: 0 0 8px 3px rgba(0, 255, 200, 0.8);
}

.intercept-flash {
  position: absolute;
  width: 30px;
  height: 30px;
  border-radius: 50%;
  background: radial-gradient(circle, #ffffff 0%, #00ffcc 40%, transparent 70%);
  transform: translate(-50%, -50%);
  z-index: 999;
  pointer-events: none;
  animation: interceptFlash 0.5s ease-out forwards;
}

@keyframes interceptFlash {
  0% {
    opacity: 1;
    transform: translate(-50%, -50%) scale(0.5);
  }
  50% {
    opacity: 1;
    transform: translate(-50%, -50%) scale(2);
  }
  100% {
    opacity: 0;
    transform: translate(-50%, -50%) scale(3);
  }
}

/* Adjust weapon panel to sit below launch panel on small screens */
@media (max-width: 900px) {
  #launch-panel {
    left: 10px;
    top: 380px;
  }
}

/* ===== PROJECTILE VISUALS ===== */
.projectile-rocket,
.projectile-drone,
.projectile-cruise {
  position: absolute;
  z-index: 998;
  pointer-events: none;
  line-height: 1;
  user-select: none;
  transform-origin: center center;
}
.projectile-sprite {
  width: 24px;
  height: 24px;
  display: block;
  object-fit: contain;
  object-position: center center;
}
.projectile-rocket {
  filter: drop-shadow(0 0 9px #ffd24a);
}
.projectile-drone {
  filter: drop-shadow(0 0 7px #88ff88);
}
.projectile-cruise {
  filter: drop-shadow(0 0 7px #ffcc00);
}
.projectile-rocket .projectile-sprite {
  width: 38px;
  height: 38px;
}
.projectile-drone .projectile-sprite {
  width: 32px;
  height: 32px;
}
.projectile-cruise .projectile-sprite {
  width: 34px;
  height: 34px;
}

.aircraft-munition {
  position: absolute;
  z-index: 999;
  pointer-events: none;
  transform-origin: center center;
}
.aircraft-munition::before {
  content: "";
  display: block;
  border-radius: 999px;
}
.aircraft-munition--rocket::before {
  width: 9px;
  height: 3px;
  background: linear-gradient(90deg, #ffd86b 0%, #ff6a00 100%);
  box-shadow: 0 0 10px rgba(255, 170, 20, 0.8);
}
.aircraft-munition--bomb::before {
  width: 7px;
  height: 7px;
  background: radial-gradient(circle at 35% 35%, #fff2a8, #ff9e2c 70%, #d94f00);
  box-shadow: 0 0 11px rgba(255, 132, 0, 0.85);
}

/* ===== HUD AUTH SECTION ===== */
#hud-auth {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 12px;
}
#hud-user-link {
  border: none !important;
  padding: 0 !important;
  color: inherit !important;
  text-decoration: none;
}
#hud-user-link:hover {
  background: transparent !important;
}
#hud-user-pill {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 2px 8px 2px 4px;
  border: 1px solid #2b2b2b;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.04);
  cursor: pointer;
}
#hud-avatar,
#hud-avatar-fallback {
  width: 22px;
  height: 22px;
  border-radius: 50%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  object-fit: cover;
  border: 1px solid rgba(255, 153, 0, 0.45);
  background: rgba(15, 15, 15, 0.85);
}
#hud-username {
  color: #ddd;
  font-size: 11px;
  max-width: 110px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
#hud-auth a {
  color: #ff9900;
  text-decoration: none;
  padding: 3px 8px;
  border: 1px solid #ff9900;
  border-radius: 3px;
  font-size: 11px;
  font-family: "Courier New", monospace;
  font-weight: bold;
  transition: all 0.15s;
}
#hud-auth a:hover {
  background: rgba(255, 153, 0, 0.2);
  color: #ffcc00;
}
#btn-shop {
  border-color: #00ccff !important;
  color: #00ccff !important;
}
#btn-shop:hover {
  background: rgba(0, 204, 255, 0.15) !important;
}
#hud-ammo {
  font-size: 12px;
  color: #ccc;
}
#hud-ammo b {
  color: #ffcc00;
}

/* ===== FLASH MESSAGES ===== */
.flash {
  position: fixed;
  top: 52px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 9999;
  padding: 10px 24px;
  border-radius: 5px;
  font-family: "Courier New", monospace;
  font-size: 13px;
  font-weight: bold;
  animation: flashFade 4s ease-out forwards;
}
.flash-notice {
  background: rgba(0, 180, 80, 0.9);
  color: #fff;
  border: 1px solid #00ff88;
}
.flash-alert {
  background: rgba(200, 30, 30, 0.9);
  color: #fff;
  border: 1px solid #ff4444;
}
@keyframes flashFade {
  0% {
    opacity: 1;
  }
  70% {
    opacity: 1;
  }
  100% {
    opacity: 0;
  }
}

/* ===== SHOP PAGE ===== */
html body #shop-page {
  overflow: auto;
  min-height: 100vh;
  height: auto;
  background: #0a0a0f;
  color: #e0e0e0;
  font-family: "Courier New", monospace;
  padding: 0 0 60px;
}

#shop-header {
  background: linear-gradient(
    180deg,
    rgba(0, 0, 0, 0.95) 0%,
    rgba(10, 10, 20, 0.98) 100%
  );
  border-bottom: 2px solid #ff4400;
  padding: 16px 32px;
  display: flex;
  align-items: center;
  gap: 24px;
  flex-wrap: wrap;
}
#shop-back {
  color: #ff9900;
  text-decoration: none;
  font-size: 13px;
  border: 1px solid #ff9900;
  padding: 4px 12px;
  border-radius: 4px;
}
#shop-back:hover {
  background: rgba(255, 153, 0, 0.15);
}
#shop-header h1 {
  font-size: 18px;
  color: #ff4400;
  letter-spacing: 2px;
  flex: 1;
}
#shop-balance {
  font-size: 13px;
  color: #aaa;
}
#shop-balance b {
  color: #ffcc00;
}

.shop-notice {
  margin: 16px 32px;
  padding: 10px 20px;
  background: rgba(0, 180, 80, 0.15);
  border: 1px solid #00cc66;
  border-radius: 5px;
  color: #00ff88;
  font-size: 13px;
}
.shop-alert {
  margin: 16px 32px;
  padding: 10px 20px;
  background: rgba(200, 30, 30, 0.15);
  border: 1px solid #cc3333;
  border-radius: 5px;
  color: #ff6666;
  font-size: 13px;
}

.shop-section {
  padding: 24px 32px 8px;
}
.shop-section h2 {
  font-size: 15px;
  color: #ff9900;
  letter-spacing: 1px;
  margin-bottom: 6px;
  border-bottom: 1px solid #222;
  padding-bottom: 8px;
}
.shop-hint {
  color: #666;
  font-size: 12px;
  margin-bottom: 16px;
}
.shop-section > .shop-hint {
  display: block;
}

.shop-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
  gap: 16px;
  margin-top: 12px;
}

.shop-card {
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid #222;
  border-radius: 8px;
  padding: 16px;
  display: flex;
  flex-direction: column;
  gap: 8px;
  transition: border-color 0.2s;
}
.coin-card {
  border-color: #1a4a6a;
}
.coin-card:hover {
  border-color: #00aaff;
}
.ammo-card {
  border-color: #3a2a0a;
}
.ammo-card:hover {
  border-color: #ff9900;
}

.shop-card-title {
  font-size: 13px;
  font-weight: bold;
  color: #fff;
}
.shop-card-coins {
  font-size: 22px;
  color: #ffcc00;
}
.shop-card-price {
  font-size: 18px;
  color: #00ccff;
  font-weight: bold;
}
.shop-card-contents {
  font-size: 11px;
  color: #aaa;
  line-height: 1.6;
}
.shop-card-cost {
  font-size: 15px;
  color: #ffcc00;
  font-weight: bold;
}

.shop-btn {
  margin-top: auto;
  padding: 8px 12px;
  border: none;
  border-radius: 4px;
  font-family: "Courier New", monospace;
  font-size: 12px;
  font-weight: bold;
  cursor: pointer;
  letter-spacing: 1px;
  transition: all 0.15s;
}
.coin-btn {
  background: linear-gradient(135deg, #004080, #0066cc);
  color: #fff;
}
.coin-btn:hover {
  background: linear-gradient(135deg, #0055aa, #0088ff);
}
.ammo-btn {
  background: linear-gradient(135deg, #7a3a00, #cc6600);
  color: #fff;
}
.ammo-btn:hover {
  background: linear-gradient(135deg, #aa5500, #ff8800);
}
.shop-btn:disabled {
  background: #222;
  color: #555;
  cursor: not-allowed;
}

/* ===== FLOATING PLAN ATTACK BUTTON ===== */
#btn-plan-attack {
  position: absolute;
  bottom: 32px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 1000;
  padding: 14px 36px;
  background: linear-gradient(135deg, #8b1a00, #cc2200);
  border: 2px solid #ff4400;
  border-radius: 6px;
  color: #fff;
  font-family: "Courier New", monospace;
  font-size: 15px;
  font-weight: bold;
  letter-spacing: 3px;
  cursor: pointer;
  box-shadow:
    0 0 20px rgba(255, 68, 0, 0.5),
    0 4px 16px rgba(0, 0, 0, 0.6);
  transition: all 0.15s;
  animation: planBtnPulse 2.5s infinite;
}
#btn-plan-attack:hover {
  background: linear-gradient(135deg, #aa2200, #ff3300);
  box-shadow:
    0 0 30px rgba(255, 68, 0, 0.8),
    0 4px 20px rgba(0, 0, 0, 0.7);
  transform: translateX(-50%) scale(1.04);
}
@keyframes planBtnPulse {
  0%,
  100% {
    box-shadow:
      0 0 20px rgba(255, 68, 0, 0.5),
      0 4px 16px rgba(0, 0, 0, 0.6);
  }
  50% {
    box-shadow:
      0 0 35px rgba(255, 68, 0, 0.9),
      0 4px 20px rgba(0, 0, 0, 0.7);
  }
}

/* ===== MISSION PLANNER MODAL ===== */
#mission-modal {
  position: fixed;
  inset: 0;
  z-index: 5000;
  display: flex;
  align-items: center;
  justify-content: center;
}
#mission-modal.hidden {
  display: none;
}

#mission-modal-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.82);
  backdrop-filter: blur(3px);
}

#mission-modal-box {
  position: relative;
  z-index: 1;
  width: min(960px, 96vw);
  max-height: 88vh;
  background: rgba(4, 6, 14, 0.98);
  border: 1px solid #ff4400;
  border-radius: 10px;
  display: flex;
  flex-direction: column;
  box-shadow:
    0 0 60px rgba(255, 68, 0, 0.25),
    0 20px 60px rgba(0, 0, 0, 0.8);
  overflow: hidden;
}

#modal-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px 24px;
  border-bottom: 1px solid #1e1e1e;
  background: rgba(255, 68, 0, 0.06);
  flex-shrink: 0;
}
#modal-title {
  font-size: 16px;
  font-weight: bold;
  color: #ff4400;
  letter-spacing: 3px;
}
#modal-close {
  background: none;
  border: 1px solid #333;
  color: #888;
  width: 28px;
  height: 28px;
  border-radius: 4px;
  cursor: pointer;
  font-size: 13px;
  line-height: 1;
  transition: all 0.15s;
}
#modal-close:hover {
  border-color: #ff4400;
  color: #ff4400;
}

/* Scrollable body */
#mission-modal-box > .modal-section,
#mission-modal-box > #modal-footer {
  flex-shrink: 0;
}
#mission-modal-box {
  overflow-y: auto;
}

.modal-section {
  padding: 18px 24px 14px;
  border-bottom: 1px solid #111;
}
.modal-section-title {
  font-size: 11px;
  letter-spacing: 3px;
  color: #ff9900;
  font-weight: bold;
  margin-bottom: 10px;
}

/* Filter pills */
.modal-filters {
  display: flex;
  gap: 6px;
  flex-wrap: wrap;
  margin-bottom: 12px;
}
.mf-btn {
  padding: 4px 10px;
  background: transparent;
  border: 1px solid #2a2a2a;
  border-radius: 3px;
  color: #777;
  font-family: "Courier New", monospace;
  font-size: 11px;
  cursor: pointer;
  transition: all 0.12s;
}
.mf-btn:hover {
  border-color: #ff9900;
  color: #ffcc00;
}
.mf-btn.active {
  border-color: #ff4400;
  color: #ff6600;
  background: rgba(255, 68, 0, 0.1);
}

/* Target grid */
#modal-target-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(175px, 1fr));
  gap: 8px;
  max-height: 220px;
  overflow-y: auto;
  padding-right: 4px;
}

.modal-target-card {
  background: rgba(255, 255, 255, 0.055);
  border: 1px solid #2f3950;
  border-radius: 6px;
  padding: 11px 11px 9px;
  cursor: pointer;
  transition: all 0.15s;
  display: flex;
  flex-direction: column;
  gap: 4px;
}
.modal-target-card:hover {
  border-color: #ff6600;
  background: rgba(255, 68, 0, 0.07);
}
.modal-target-card.selected {
  border-color: #ff4400;
  background: rgba(255, 68, 0, 0.15);
  box-shadow: 0 0 8px rgba(255, 68, 0, 0.3);
}
.modal-target-card.destroyed {
  opacity: 0.4;
  cursor: not-allowed;
}

.mtc-icon {
  line-height: 1;
  margin-bottom: 2px;
}
.mtc-icon img {
  width: 26px;
  height: 26px;
  display: block;
  object-fit: contain;
}
.mtc-name {
  font-size: 13px;
  color: #eef3ff;
  font-weight: bold;
  line-height: 1.35;
}
.mtc-city {
  font-size: 12px;
  color: #cfd7e8;
}
.mtc-flag {
  font-size: 50px;
  line-height: 1;
  vertical-align: -1px;
  margin-right: 2px;
}
.mtc-intel {
  font-size: 11px;
  color: #dde6ff;
  line-height: 1.45;
}
.mtc-source {
  font-size: 10px;
  color: #bdc8de;
  line-height: 1.35;
}
.mtc-hp-track {
  height: 3px;
  background: rgba(255, 255, 255, 0.08);
  border-radius: 2px;
  overflow: hidden;
  margin: 3px 0;
}
.mtc-hp-fill {
  height: 100%;
  background: linear-gradient(90deg, #ff3300, #ffcc00);
  border-radius: 2px;
}
.mtc-status {
  font-size: 11px;
  font-weight: bold;
}
.mtc-status.destroyed {
  color: #cc3333;
}
.mtc-status.damaged {
  color: #ff9900;
}

/* Launch site grid */
#modal-site-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
  gap: 8px;
  max-height: 160px;
  overflow-y: auto;
}
.modal-site-card {
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid #30405f;
  border-radius: 6px;
  padding: 10px;
  cursor: pointer;
  transition: all 0.15s;
  display: flex;
  flex-direction: column;
  gap: 3px;
}
.modal-site-card:hover {
  border-color: #00aaff;
  background: rgba(0, 150, 255, 0.06);
}
.modal-site-card.selected {
  border-color: #0088ff;
  background: rgba(0, 120, 255, 0.12);
  box-shadow: 0 0 8px rgba(0, 120, 255, 0.3);
}
.msc-icon {
  line-height: 1;
}
.msc-icon img {
  width: 22px;
  height: 22px;
  display: block;
  object-fit: contain;
}
.msc-name {
  font-size: 13px;
  color: #edf3ff;
  font-weight: bold;
  line-height: 1.3;
}
.msc-region {
  font-size: 11px;
  color: #c8d2e8;
}

/* Weapon configurator */
#modal-weapons {
  display: flex;
  flex-direction: column;
  gap: 8px;
  max-height: 260px;
  overflow-y: auto;
  padding-right: 4px;
}
.modal-weapon-row {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 8px 10px;
  background: rgba(255, 255, 255, 0.02);
  border: 1px solid #1a1a1a;
  border-radius: 5px;
}
.mw-icon {
  width: 28px;
  text-align: center;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}
.mw-icon img {
  width: 22px;
  height: 22px;
  display: block;
  object-fit: contain;
}
.mw-name {
  flex: 1;
  font-size: 12px;
  color: #ccc;
  display: flex;
  flex-direction: column;
  gap: 2px;
}
.mw-type {
  font-size: 9px;
  letter-spacing: 1px;
  color: #777;
}
.mw-spec {
  font-size: 9px;
  color: #8b8b8b;
}
.mw-controls {
  display: flex;
  align-items: center;
  gap: 8px;
}
.mw-btn {
  width: 26px;
  height: 26px;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid #333;
  color: #ccc;
  border-radius: 4px;
  font-size: 16px;
  line-height: 1;
  cursor: pointer;
  transition: all 0.12s;
  font-family: monospace;
}
.mw-btn:hover {
  border-color: #ff9900;
  color: #ffcc00;
  background: rgba(255, 153, 0, 0.1);
}
.mw-count {
  font-size: 18px;
  font-weight: bold;
  color: #ffcc00;
  min-width: 28px;
  text-align: center;
}
.mw-stock {
  font-size: 10px;
  color: #555;
  white-space: nowrap;
}
.mw-stock b {
  color: #888;
}

/* Modal footer */
#modal-footer {
  padding: 16px 24px;
  border-top: 1px solid #1a1a1a;
  background: rgba(0, 0, 0, 0.4);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  flex-shrink: 0;
}
#modal-summary {
  font-size: 12px;
  color: #888;
  flex: 1;
}
#modal-summary b {
  color: #fff;
}

#btn-modal-launch {
  padding: 12px 28px;
  background: linear-gradient(135deg, #8b1a00, #cc2200);
  border: 1px solid #ff4400;
  border-radius: 5px;
  color: #fff;
  font-family: "Courier New", monospace;
  font-size: 13px;
  font-weight: bold;
  letter-spacing: 2px;
  cursor: pointer;
  transition: all 0.15s;
  white-space: nowrap;
}
#btn-modal-launch:hover:not(:disabled) {
  background: linear-gradient(135deg, #aa2200, #ff3300);
  box-shadow: 0 0 16px rgba(255, 68, 0, 0.5);
}
#btn-modal-launch:disabled {
  background: #1a1a1a;
  border-color: #333;
  color: #555;
  cursor: not-allowed;
}

/* ===== FIRE & SMOKE MARKERS ===== */
.fire-marker {
  position: relative;
  width: 52px;
  height: 64px;
  pointer-events: none;
}

.fire-flame {
  position: absolute;
  bottom: 0;
  left: 50%;
  transform: translateX(-50%);
  width: 22px;
  height: 34px;
  background: radial-gradient(
    ellipse at 50% 100%,
    #ffe16a 0%,
    #ffaf17 32%,
    #ff5a14 60%,
    transparent 100%
  );
  border-radius: 50% 50% 30% 30%;
  animation: fireFlicker 0.3s ease-in-out infinite alternate;
  filter: blur(1px);
}

.destroyed-fire .fire-flame {
  width: 30px;
  height: 44px;
  background: radial-gradient(
    ellipse at 50% 100%,
    #ffe884 0%,
    #ffb226 28%,
    #ff5314 58%,
    transparent 100%
  );
}

.fire-smoke {
  position: absolute;
  bottom: 20px;
  left: 50%;
  transform: translateX(-50%);
  width: 12px;
  height: 12px;
  background: rgba(60, 60, 60, 0.7);
  border-radius: 50%;
  animation: smokeDrift 1.2s ease-out infinite;
}
.destroyed-fire .fire-smoke {
  width: 20px;
  height: 20px;
  background: rgba(40, 40, 40, 0.85);
}

@keyframes fireFlicker {
  0% {
    transform: translateX(-50%) scaleX(1) scaleY(1);
    opacity: 0.95;
  }
  33% {
    transform: translateX(-48%) scaleX(0.9) scaleY(1.08);
    opacity: 1;
  }
  66% {
    transform: translateX(-52%) scaleX(1.1) scaleY(0.95);
    opacity: 0.9;
  }
  100% {
    transform: translateX(-50%) scaleX(0.95) scaleY(1.05);
    opacity: 1;
  }
}

@keyframes smokeDrift {
  0% {
    transform: translateX(-50%) translateY(0) scale(1);
    opacity: 0.7;
  }
  100% {
    transform: translateX(-44%) translateY(-28px) scale(2.5);
    opacity: 0;
  }
}

/* ===== AUTH PAGES (Devise) ===== */
.auth-page {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  background: #0a0a0f;
  background-image:
    radial-gradient(
      ellipse at 20% 50%,
      rgba(255, 60, 0, 0.06) 0%,
      transparent 60%
    ),
    radial-gradient(
      ellipse at 80% 50%,
      rgba(255, 60, 0, 0.04) 0%,
      transparent 60%
    );
  font-family: "Courier New", monospace;
}

.auth-box {
  width: 100%;
  max-width: 420px;
  background: rgba(5, 8, 15, 0.97);
  border: 1px solid #ff4400;
  border-radius: 8px;
  padding: 36px 40px;
  box-shadow:
    0 0 40px rgba(255, 68, 0, 0.15),
    0 0 80px rgba(255, 68, 0, 0.06);
}

.auth-title {
  font-size: 22px;
  font-weight: bold;
  color: #ff4400;
  letter-spacing: 3px;
  text-align: center;
  margin-bottom: 4px;
}

.auth-subtitle {
  font-size: 11px;
  color: #666;
  letter-spacing: 4px;
  text-align: center;
  margin-bottom: 28px;
  border-bottom: 1px solid #1a1a1a;
  padding-bottom: 20px;
}

.auth-field {
  margin-bottom: 18px;
  display: flex;
  flex-direction: column;
  gap: 5px;
}

.auth-label {
  font-size: 10px;
  color: #888;
  letter-spacing: 2px;
  font-weight: bold;
}

.auth-hint {
  font-size: 10px;
  color: #555;
}

.auth-input {
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid #2a2a2a;
  border-radius: 4px;
  color: #e0e0e0;
  font-family: "Courier New", monospace;
  font-size: 13px;
  padding: 9px 12px;
  outline: none;
  transition: border-color 0.15s;
  width: 100%;
}

.auth-input:focus {
  border-color: #ff4400;
  box-shadow: 0 0 0 2px rgba(255, 68, 0, 0.15);
}

.auth-input::placeholder {
  color: #444;
}

.auth-check {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 18px;
}
.auth-checkbox {
  accent-color: #ff4400;
}
.auth-check-label {
  font-size: 12px;
  color: #888;
  cursor: pointer;
}

.auth-starter-info {
  font-size: 11px;
  color: #556;
  background: rgba(255, 153, 0, 0.06);
  border: 1px solid #332200;
  border-radius: 4px;
  padding: 8px 12px;
  margin-bottom: 18px;
  line-height: 1.6;
}

.auth-btn {
  width: 100%;
  padding: 12px;
  background: linear-gradient(135deg, #8b1a00, #cc2200);
  border: 1px solid #ff4400;
  border-radius: 4px;
  color: #fff;
  font-family: "Courier New", monospace;
  font-size: 13px;
  font-weight: bold;
  letter-spacing: 2px;
  cursor: pointer;
  transition: all 0.15s;
  margin-top: 4px;
}
.auth-btn:hover {
  background: linear-gradient(135deg, #aa2200, #ff3300);
  box-shadow: 0 0 12px rgba(255, 68, 0, 0.4);
}

.auth-links {
  margin-top: 20px;
  padding-top: 16px;
  border-top: 1px solid #1a1a1a;
  font-size: 11px;
  text-align: center;
  line-height: 2;
}
.auth-links a {
  color: #ff9900;
  text-decoration: none;
  display: block;
}
.auth-links a:hover {
  color: #ffcc00;
  text-decoration: underline;
}

/* Devise error messages */
#error_explanation {
  background: rgba(200, 30, 30, 0.12);
  border: 1px solid #cc3333;
  border-radius: 4px;
  padding: 10px 14px;
  margin-bottom: 18px;
  font-size: 12px;
  color: #ff8888;
}
#error_explanation h2 {
  font-size: 12px;
  margin-bottom: 6px;
  color: #ff6666;
}
#error_explanation ul {
  padding-left: 16px;
}
#error_explanation li {
  margin-bottom: 3px;
}

/* ===== GUEST HOME ===== */
#guest-home {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  background: radial-gradient(circle at 20% 10%, rgba(255, 68, 0, 0.14), transparent 55%),
    radial-gradient(circle at 70% 35%, rgba(0, 255, 136, 0.08), transparent 60%),
    #0a0a0f;
}

.guest-topbar {
  position: sticky;
  top: 0;
  z-index: 20;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px 18px;
  background: rgba(0, 0, 0, 0.72);
  border-bottom: 1px solid rgba(255, 68, 0, 0.6);
  backdrop-filter: blur(8px);
}

.guest-brand {
  font-size: 16px;
  font-weight: bold;
  letter-spacing: 4px;
  color: #ff4400;
  text-shadow: 0 0 10px rgba(255, 68, 0, 0.5);
}

.guest-nav {
  display: flex;
  gap: 10px;
}

.guest-nav-link {
  color: #ff9900;
  text-decoration: none;
  padding: 6px 12px;
  border: 1px solid #ff9900;
  border-radius: 4px;
  font-size: 12px;
  letter-spacing: 1px;
  font-weight: bold;
  transition: all 0.15s;
}

.guest-nav-link[type="button"] {
  appearance: none;
  background: transparent;
  font-family: "Courier New", monospace;
  cursor: pointer;
}

.guest-nav-link:hover {
  background: rgba(255, 153, 0, 0.15);
  color: #ffcc00;
}

.guest-nav-link.primary {
  border-color: #ff4400;
  color: #fff;
  background: linear-gradient(135deg, #8b1a00, #cc2200);
}

.guest-nav-link.primary:hover {
  background: linear-gradient(135deg, #aa2200, #ff3300);
  box-shadow: 0 0 14px rgba(255, 68, 0, 0.35);
}

.guest-main {
  flex: 1;
  padding: 26px 18px 50px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.guest-hero {
  width: 100%;
  max-width: 1180px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: 420px 1fr;
  gap: 26px;
  align-items: center;
}

.guest-copy {
  padding-top: 10px;
}

.guest-kicker {
  font-size: 11px;
  color: #8aa;
  letter-spacing: 2px;
  text-transform: uppercase;
  margin-bottom: 10px;
}

.guest-title {
  font-size: 34px;
  letter-spacing: 2px;
  color: #fff;
  margin-bottom: 12px;
  line-height: 1.12;
}

.guest-subtitle {
  color: #b8b8b8;
  font-size: 13px;
  line-height: 1.7;
  margin-bottom: 18px;
}

.guest-cta {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
}

.guest-cta-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  text-decoration: none;
  padding: 10px 14px;
  border-radius: 4px;
  border: 1px solid #ff4400;
  background: linear-gradient(135deg, #8b1a00, #cc2200);
  color: #fff;
  font-size: 12px;
  font-weight: bold;
  letter-spacing: 2px;
  transition: all 0.15s;
}

.guest-cta-btn:hover {
  box-shadow: 0 0 14px rgba(255, 68, 0, 0.35);
}

.guest-cta-btn.ghost {
  background: transparent;
  border-color: #ff9900;
  color: #ffcc00;
}

.guest-cta-btn.ghost:hover {
  background: rgba(255, 153, 0, 0.12);
  box-shadow: none;
}

.guest-contact {
  margin-top: 30px;
  display: flex;
  flex-direction: column;
  gap: 8px;
  align-items: flex-start;
}

.guest-logo {
  display: block;
  max-width: 320px;
  height: auto;
  opacity: 0.9;
}

.contact-email {
  font-size: 20px;
  color: #888;
  font-family: "Courier New", monospace;
}

.guest-footer {
  margin-top: auto;
  padding: 20px;
  border-top: 1px solid rgba(255, 68, 0, 0.2);
  background: rgba(0, 0, 0, 0.6);
  backdrop-filter: blur(4px);
  text-align: center;
}

.footer-links {
  display: flex;
  gap: 20px;
  justify-content: center;
  align-items: center;
  flex-wrap: wrap;
  font-size: 11px;
  color: #666;
}

.footer-link {
  color: #888;
  text-decoration: none;
  transition: color 0.15s;
}

.footer-link:hover {
  color: #ff9900;
}

.footer-copy {
  color: #444;
  margin-left: 10px;
}

/* ===== STATIC PAGES ===== */
.static-page {
  min-height: 100vh;
  padding: 80px 20px 40px;
  background: #0a0a0f;
  color: #e0e0e0;
}

.static-container {
  max-width: 800px;
  margin: 0 auto;
}

.static-title {
  font-size: 28px;
  color: #ff4400;
  margin-bottom: 30px;
  letter-spacing: 2px;
  border-bottom: 1px solid #333;
  padding-bottom: 10px;
}

.static-section {
  margin-bottom: 30px;
}

.static-section h2 {
  font-size: 16px;
  color: #ffcc00;
  margin-bottom: 10px;
  letter-spacing: 1px;
}

.static-section p,
.static-section ul {
  font-size: 13px;
  line-height: 1.6;
  color: #aaa;
  margin-bottom: 10px;
}

.static-section ul {
  padding-left: 20px;
}

.static-section li {
  margin-bottom: 6px;
}

.contact-email {
  color: #ff9900;
  font-weight: bold;
}

.static-actions {
  margin-top: 40px;
  border-top: 1px solid #222;
  padding-top: 20px;
}

.static-back-btn {
  display: inline-block;
  padding: 8px 16px;
  border: 1px solid #444;
  border-radius: 4px;
  color: #888;
  text-decoration: none;
  font-size: 12px;
  transition: all 0.15s;
}

.static-back-btn:hover {
  border-color: #ff9900;
  color: #ffcc00;
}

.promo-slider {
  position: relative;
  overflow: hidden;
  border-radius: 10px;
  border: 1px solid rgba(255, 68, 0, 0.55);
  background: #000;
  box-shadow: 0 8px 30px rgba(0, 0, 0, 0.7);
}

.promo-track {
  display: flex;
  width: 100%;
  transition: transform 480ms ease;
}

.promo-slide {
  min-width: 100%;
  height: min(60vh, 520px);
  display: flex;
  align-items: center;
  justify-content: center;
  background: #05070b;
}

.promo-slide img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.promo-arrow {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  width: 42px;
  height: 42px;
  border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, 0.18);
  background: rgba(0, 0, 0, 0.55);
  color: #fff;
  font-size: 22px;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  transition: all 0.15s;
}

.promo-arrow:hover {
  border-color: rgba(255, 68, 0, 0.7);
  box-shadow: 0 0 18px rgba(255, 68, 0, 0.25);
}

.promo-arrow.left {
  left: 10px;
}

.promo-arrow.right {
  right: 10px;
}

.promo-thumbs {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  justify-content: center;
  padding: 12px 4px 0;
}

.promo-thumb {
  width: 72px;
  height: 46px;
  border-radius: 6px;
  padding: 0;
  border: 1px solid rgba(255, 255, 255, 0.18);
  background: rgba(0, 0, 0, 0.35);
  cursor: pointer;
  overflow: hidden;
  opacity: 0.78;
  transition: all 0.15s;
}

.promo-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.promo-thumb:hover {
  opacity: 0.95;
  border-color: rgba(255, 153, 0, 0.55);
}

.promo-thumb.active {
  opacity: 1;
  border-color: rgba(255, 68, 0, 0.85);
  box-shadow: 0 0 18px rgba(255, 68, 0, 0.25);
}

@media (max-width: 980px) {
  .guest-hero {
    grid-template-columns: 1fr;
  }

  .promo-slide {
    height: min(54vh, 420px);
  }
}

.about-wrap {
  max-width: 860px;
  margin: 0 auto;
}

.about-title {
  font-size: 24px;
  letter-spacing: 3px;
  color: #fff;
  margin: 10px 0 14px;
}

.about-card {
  background: rgba(0, 0, 0, 0.55);
  border: 1px solid rgba(255, 68, 0, 0.35);
  border-radius: 10px;
  padding: 18px 18px 16px;
  backdrop-filter: blur(8px);
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.65);
  line-height: 1.8;
  color: #cfcfcf;
}

.about-card p + p {
  margin-top: 12px;
}

.about-actions {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
  margin-top: 16px;
}
