/* objects.css — Space Vector in-game object visual polish
   Layers on top of styles.css + polish.css
   Covers: ship animations, asteroid shading, mine spots, starbase pulse, hit feedback
*/

/* ════════════════════════════════════════
   KEYFRAME LIBRARY
════════════════════════════════════════ */

/* Engine glow pulse — applied to .engine-glow path elements */
@keyframes engine-glow-pulse {
  0%, 100% { opacity: 0.55; filter: drop-shadow(0 0 2px currentColor); stroke-width: 1.8; }
  50%       { opacity: 1;    filter: drop-shadow(0 0 6px currentColor) drop-shadow(0 0 12px currentColor); stroke-width: 2.6; }
}

/* Reactor core pulse — starbase reactor tile */
@keyframes reactor-pulse {
  0%, 100% { opacity: 0.65; filter: drop-shadow(0 0 3px currentColor); }
  50%       { opacity: 1;    filter: drop-shadow(0 0 9px currentColor) drop-shadow(0 0 18px currentColor); }
}

/* Slow reactor ring rotation */
@keyframes reactor-ring-spin {
  from { transform-origin: 38px 38px; transform: rotate(0deg); }
  to   { transform-origin: 38px 38px; transform: rotate(360deg); }
}

/* Mine spot pulse */
@keyframes mine-pulse {
  0%, 100% { opacity: 0.55; filter: drop-shadow(0 0 2px var(--yellow)); }
  50%       { opacity: 1;    filter: drop-shadow(0 0 8px var(--yellow)) drop-shadow(0 0 16px rgba(255,200,50,0.4)); }
}

/* Hit flash — added/removed by JS */
@keyframes hit-flash {
  0%   { filter: brightness(3) saturate(0.2); }
  40%  { filter: brightness(2) saturate(0.4); }
  100% { filter: brightness(1) saturate(1); }
}

/* Ship spawn-in pop */
@keyframes ship-pop-in {
  0%   { transform: scale(0.5); opacity: 0; }
  70%  { transform: scale(1.1); opacity: 1; }
  100% { transform: scale(1);   opacity: 1; }
}

/* Sensor lock warning pulse */
@keyframes sensor-lock-warn {
  0%, 100% { box-shadow: 0 0 0 2px rgba(255,200,0,0.5); }
  50%       { box-shadow: 0 0 0 4px rgba(255,200,0,0.8), 0 0 12px rgba(255,200,0,0.3); }
}

/* Mine spot crystal spin */
@keyframes crystal-rotate {
  from { transform: rotate(0deg); }
  to   { transform: rotate(360deg); }
}

/* Sentry mode outer ring */
@keyframes sentry-ring-pulse {
  0%, 100% { box-shadow: 0 0 0 2px rgba(61,240,128,0.3), inset 0 0 6px rgba(61,240,128,0.1); }
  50%       { box-shadow: 0 0 0 3px rgba(61,240,128,0.6), inset 0 0 10px rgba(61,240,128,0.2); }
}

/* Frozen ship shimmer */
@keyframes frozen-shimmer {
  0%, 100% { filter: brightness(1) hue-rotate(0deg); }
  50%       { filter: brightness(1.2) hue-rotate(20deg); }
}

/* Destroy explosion flash */
@keyframes destroy-flash {
  0%   { filter: brightness(4) saturate(0) sepia(1); opacity: 1; }
  50%  { filter: brightness(2) saturate(0.5); opacity: 0.7; }
  100% { filter: brightness(1) saturate(1); opacity: 0; }
}

/* ════════════════════════════════════════
   DREADNOUGHT & CARRIER BODY SEGMENTS
   SVG-based, overflow:visible so strokes
   bleed across cell boundaries.
════════════════════════════════════════ */

/* Body cells need relative positioning so the absolute SVG fills them */
.dread-body,
.carrier-body {
  position: absolute;
  inset: 0;
  overflow: visible;
  z-index: 1;
}

/* The body SVG fills its cell and bleeds past edges */
.dread-body-svg,
.carrier-body-svg {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  overflow: visible;
}

/* Dread body stroke styles — inherit player color */
.dread-body.p1 .dread-body-svg .outer-stroke { stroke: var(--p1); }
.dread-body.p2 .dread-body-svg .outer-stroke { stroke: var(--p2); }
.dread-body.p1 .dread-body-svg .inner-stroke { stroke: var(--p1); }
.dread-body.p2 .dread-body-svg .inner-stroke { stroke: var(--p2); }
.dread-body.p1 .dread-body-svg .detail-stroke { stroke: var(--p1); }
.dread-body.p2 .dread-body-svg .detail-stroke { stroke: var(--p2); }
.dread-body.p1 .dread-body-svg .engine-glow { stroke: var(--p1); }
.dread-body.p2 .dread-body-svg .engine-glow { stroke: var(--p2); }

/* Carrier body stroke styles */
.carrier-body.p1 .carrier-body-svg .outer-stroke { stroke: var(--p1); }
.carrier-body.p2 .carrier-body-svg .outer-stroke { stroke: var(--p2); }
.carrier-body.p1 .carrier-body-svg .inner-stroke { stroke: var(--p1); }
.carrier-body.p2 .carrier-body-svg .inner-stroke { stroke: var(--p2); }
.carrier-body.p1 .carrier-body-svg .detail-stroke { stroke: var(--p1); }
.carrier-body.p2 .carrier-body-svg .detail-stroke { stroke: var(--p2); }

/* Stroke widths for body segment SVGs */
.dread-body-svg .outer-stroke,
.carrier-body-svg .outer-stroke {
  stroke-width: 2.4;
  fill: none;
  opacity: 0.22;
  filter: drop-shadow(0 0 10px currentColor);
}
.dread-body-svg .inner-stroke,
.carrier-body-svg .inner-stroke {
  stroke-width: 1.8;
  fill: none;
  filter: drop-shadow(0 0 6px currentColor) drop-shadow(0 0 2px rgba(255,255,255,0.25));
}
.dread-body-svg .detail-stroke,
.carrier-body-svg .detail-stroke {
  stroke-width: 1.0;
  fill: none;
  opacity: 0.75;
}
.dread-body-svg .engine-glow,
.carrier-body-svg .engine-glow {
  stroke-width: 1.6;
  fill: none;
  animation: engine-glow-pulse 2.8s ease-in-out infinite;
}

/* Ghost body cells */
.dread-body.ghost .dread-body-svg,
.carrier-body.ghost .carrier-body-svg {
  opacity: 0.4;
  filter: saturate(0.6);
}

/* Selected highlight ring on body cells */
.dread-body.selected,
.carrier-body.selected {
  box-shadow: inset 0 0 0 2px rgba(255,204,0,0.5);
}

/* ════════════════════════════════════════
   SHIP MARKER — base enhancements
════════════════════════════════════════ */

/* All new ship markers pop in */
.ship-marker {
  animation: ship-pop-in 0.25s cubic-bezier(0.18, 1, 0.3, 1) both;
}

/* Ghost ships — no animation */
.ship-marker.ghost {
  animation: none;
}

/* Hit flash class — added by combat.js on damage */
.ship-marker.hit-flash {
  animation: hit-flash 0.35s ease both !important;
}

/* Sentry mode ring */
.ship-marker.sentry-mode-active {
  animation: sentry-ring-pulse 2s ease-in-out infinite !important;
}

/* Sensor lock warning on the locked ship */
.ship-marker .sensor-lock-indicator {
  animation: sensor-lock-warn 1.5s ease-in-out infinite;
  border-radius: 50%;
  width: 10px;
  height: 10px;
  background: var(--yellow);
  position: absolute;
  top: -4px;
  left: -4px;
  z-index: 6;
}

/* Frozen ship — blue tint shimmer */
.ship-marker.frozen .ship-svg {
  animation: frozen-shimmer 1.2s ease-in-out infinite;
}

/* ════════════════════════════════════════
   ENGINE GLOW — animated on all ship SVGs
════════════════════════════════════════ */

/* Apply the pulse to all engine-glow paths */
.ship-svg .engine-glow {
  animation: engine-glow-pulse 2.2s ease-in-out infinite;
}

/* Interceptor — faster, more aggressive pulse */
.interceptor-svg .engine-glow {
  animation-duration: 1.6s;
}

/* Fighter — fastest */
.fighter-svg .engine-glow {
  animation-duration: 1.3s;
  animation-delay: 0.2s;
}

/* Dreadnought — slowest, heaviest */
.dread-head-svg .engine-glow {
  animation-duration: 2.8s;
  animation-delay: 0.4s;
}

/* Carrier — staggered pair */
.carrier-svg .engine-glow:first-of-type {
  animation-duration: 2.4s;
}
.carrier-svg .engine-glow:last-of-type {
  animation-duration: 2.4s;
  animation-delay: 0.8s;
}

/* Mining ship — industrial slow pulse */
.mining-ship-svg .engine-glow {
  animation-duration: 3s;
}

/* Engineer drone — two engines offset */
.engineer-drone-svg .engine-glow:first-of-type {
  animation-duration: 2s;
}
.engineer-drone-svg .engine-glow:last-of-type {
  animation-duration: 2s;
  animation-delay: 1s;
}

/* Frigate — triple nozzles staggered */
.frigate-svg .engine-glow:nth-of-type(1) { animation-duration: 2s; }
.frigate-svg .engine-glow:nth-of-type(2) { animation-duration: 2.2s; animation-delay: 0.3s; }
.frigate-svg .engine-glow:nth-of-type(3) { animation-duration: 2s; animation-delay: 0.6s; }

/* ════════════════════════════════════════
   SHIP SVG — stroke quality improvements
════════════════════════════════════════ */

/* Sharper, higher-contrast outer hull stroke */
.interceptor-svg .outer-stroke {
  stroke: currentColor;
  stroke-width: 2.0;
  fill: rgba(0,0,0,0.0);
  opacity: 0.22;
  filter: drop-shadow(0 0 8px currentColor);
}
.interceptor-svg .inner-stroke {
  stroke: currentColor;
  stroke-width: 1.6;
  fill: rgba(0,0,0,0);
  filter: drop-shadow(0 0 6px currentColor) drop-shadow(0 0 2px rgba(255,255,255,0.5));
}
.interceptor-svg .detail-stroke {
  stroke: currentColor;
  stroke-width: 1.0;
  fill: none;
  opacity: 0.85;
  filter: drop-shadow(0 0 3px rgba(255,255,255,0.2));
}

.frigate-svg .outer-stroke {
  stroke: currentColor;
  stroke-width: 2.2;
  fill: rgba(0,0,0,0);
  opacity: 0.2;
  filter: drop-shadow(0 0 10px currentColor);
}
.frigate-svg .inner-stroke {
  stroke: currentColor;
  stroke-width: 1.7;
  fill: rgba(0,0,0,0);
  filter: drop-shadow(0 0 6px currentColor) drop-shadow(0 0 2px rgba(255,255,255,0.4));
}
.frigate-svg .detail-stroke {
  stroke: currentColor;
  stroke-width: 1.0;
  fill: none;
  opacity: 0.8;
}

.dread-head-svg .outer-stroke {
  stroke: currentColor;
  stroke-width: 2.4;
  fill: rgba(0,0,0,0);
  opacity: 0.2;
  filter: drop-shadow(0 0 12px currentColor);
}
.dread-head-svg .inner-stroke {
  stroke: currentColor;
  stroke-width: 1.8;
  fill: rgba(0,0,0,0);
  filter: drop-shadow(0 0 8px currentColor) drop-shadow(0 0 2px rgba(255,255,255,0.4));
}
.dread-head-svg .detail-stroke {
  stroke: currentColor;
  stroke-width: 1.1;
  fill: none;
  opacity: 0.78;
}

.carrier-svg .outer-stroke {
  stroke: currentColor;
  stroke-width: 2.2;
  fill: rgba(0,0,0,0);
  opacity: 0.2;
  filter: drop-shadow(0 0 10px currentColor);
}
.carrier-svg .inner-stroke {
  stroke: currentColor;
  stroke-width: 1.7;
  fill: rgba(0,0,0,0);
  filter: drop-shadow(0 0 7px currentColor) drop-shadow(0 0 2px rgba(255,255,255,0.35));
}
.carrier-svg .detail-stroke {
  stroke: currentColor;
  stroke-width: 1.0;
  fill: none;
  opacity: 0.78;
}

.fighter-svg .outer-stroke {
  stroke: currentColor;
  stroke-width: 1.8;
  fill: rgba(0,0,0,0);
  opacity: 0.2;
  filter: drop-shadow(0 0 7px currentColor);
}
.fighter-svg .inner-stroke {
  stroke: currentColor;
  stroke-width: 1.5;
  fill: rgba(0,0,0,0);
  filter: drop-shadow(0 0 5px currentColor) drop-shadow(0 0 2px rgba(255,255,255,0.4));
}
.fighter-svg .detail-stroke {
  stroke: currentColor;
  stroke-width: 0.9;
  fill: none;
  opacity: 0.82;
}

.mining-ship-svg .outer-stroke {
  stroke: currentColor;
  stroke-width: 2.0;
  fill: rgba(0,0,0,0);
  opacity: 0.2;
  filter: drop-shadow(0 0 8px currentColor);
}
.mining-ship-svg .inner-stroke {
  stroke: currentColor;
  stroke-width: 1.5;
  fill: rgba(0,0,0,0);
  filter: drop-shadow(0 0 5px currentColor);
}
.mining-ship-svg .detail-stroke {
  stroke: currentColor;
  stroke-width: 1.0;
  fill: none;
  opacity: 0.8;
}

.mining-base-svg .outer-stroke {
  stroke: currentColor;
  stroke-width: 1.8;
  fill: rgba(0,0,0,0);
  opacity: 0.22;
  filter: drop-shadow(0 0 8px currentColor);
}
.mining-base-svg .inner-stroke {
  stroke: currentColor;
  stroke-width: 1.5;
  fill: rgba(0,0,0,0);
  filter: drop-shadow(0 0 5px currentColor);
}
.mining-base-svg .detail-stroke {
  stroke: currentColor;
  stroke-width: 0.9;
  fill: none;
  opacity: 0.75;
}
.mining-base-svg .mining-base-reactor {
  fill: rgba(0,0,0,0);
  animation: reactor-pulse 2s ease-in-out infinite;
}

.engineer-drone-svg .outer-stroke {
  stroke: currentColor;
  stroke-width: 2.0;
  fill: rgba(0,0,0,0);
  opacity: 0.2;
  filter: drop-shadow(0 0 8px currentColor);
}
.engineer-drone-svg .inner-stroke {
  stroke: currentColor;
  stroke-width: 1.6;
  fill: rgba(0,0,0,0);
  filter: drop-shadow(0 0 6px currentColor) drop-shadow(0 0 2px rgba(255,255,255,0.3));
}
.engineer-drone-svg .detail-stroke {
  stroke: currentColor;
  stroke-width: 1.0;
  fill: none;
  opacity: 0.78;
}

.turret-svg .outer-stroke {
  stroke: currentColor;
  stroke-width: 2.0;
  fill: rgba(0,0,0,0);
  opacity: 0.2;
  filter: drop-shadow(0 0 8px currentColor);
}
.turret-svg .inner-stroke {
  stroke: currentColor;
  stroke-width: 1.5;
  fill: rgba(0,0,0,0);
  filter: drop-shadow(0 0 5px currentColor);
}
.turret-svg .detail-stroke {
  stroke: currentColor;
  stroke-width: 0.9;
  fill: none;
  opacity: 0.8;
}

/* ════════════════════════════════════════
   STARBASE TILE STROKES
════════════════════════════════════════ */
.starbase-tile-svg .outer-stroke {
  stroke: currentColor;
  stroke-width: 5.5;
  fill: none;
  opacity: 0.16;
  filter: drop-shadow(0 0 14px currentColor);
}
.starbase-tile-svg .inner-stroke {
  stroke: currentColor;
  stroke-width: 2.4;
  fill: none;
  filter: drop-shadow(0 0 8px currentColor) drop-shadow(0 0 2px rgba(255,255,255,0.3));
}
.starbase-tile-svg .detail-stroke {
  stroke: currentColor;
  stroke-width: 1.1;
  fill: none;
  opacity: 0.75;
}

/* Reactor core pulse */
.starbase-reactor-core {
  fill: none;
  animation: reactor-pulse 1.8s ease-in-out infinite;
}
.starbase-reactor-fill {
  animation: reactor-pulse 1.8s ease-in-out infinite;
}
.starbase-reactor-ring {
  fill: none;
  opacity: 0.45;
}

/* Starbase weapon upgrade badges — glow when armed */
.starbase-upgrade-badge.beam {
  background: rgba(0,200,255,0.6);
  box-shadow: 0 0 6px rgba(0,200,255,0.8);
  animation: reactor-pulse 2s ease-in-out infinite;
}
.starbase-upgrade-badge.missile {
  background: rgba(255,160,0,0.6);
  box-shadow: 0 0 6px rgba(255,160,0,0.8);
  animation: reactor-pulse 2.4s ease-in-out infinite;
}
.starbase-upgrade-badge.torpedo {
  background: rgba(200,80,255,0.6);
  box-shadow: 0 0 6px rgba(200,80,255,0.8);
  animation: reactor-pulse 2.8s ease-in-out infinite;
}

/* ════════════════════════════════════════
   MINE SPOTS — replace emoji with SVG
════════════════════════════════════════ */
.mine-spot-marker {
  font-size: 0; /* hide emoji text */
  width: 36px;
  height: 36px;
  position: absolute;
  top: calc((var(--board-cell-size) - 36px) / 2);
  left: calc((var(--board-cell-size) - 36px) / 2);
  pointer-events: none;
  z-index: 1;
  /* SVG background mine crystal */
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 36 36'%3E%3Cdefs%3E%3CradialGradient id='mg' cx='38%25' cy='32%25' r='68%25'%3E%3Cstop offset='0%25' stop-color='%23fff8c0'/%3E%3Cstop offset='45%25' stop-color='%23ffcc33'/%3E%3Cstop offset='100%25' stop-color='%23cc8800'/%3E%3C/radialGradient%3E%3C/defs%3E%3C!-- outer dashed orbit ring --%3E%3Ccircle cx='18' cy='18' r='16' fill='none' stroke='rgba(255,200,50,0.45)' stroke-width='1.5' stroke-dasharray='4 3'/%3E%3C!-- main ore crystal --%3E%3Cpath d='M18 5 L23 11 L21 18 L18 22 L15 18 L13 11 Z' fill='url(%23mg)' stroke='rgba(255,220,80,0.7)' stroke-width='1'/%3E%3C!-- side crystal spires --%3E%3Cpath d='M18 5 L11 9 L13 16' fill='none' stroke='rgba(255,200,50,0.6)' stroke-width='0.9'/%3E%3Cpath d='M18 5 L25 9 L23 16' fill='none' stroke='rgba(255,200,50,0.6)' stroke-width='0.9'/%3E%3C!-- small gem chips --%3E%3Cpath d='M10 20 L13 17 L14 21 Z' fill='rgba(255,200,50,0.55)' stroke='rgba(255,200,50,0.4)' stroke-width='0.7'/%3E%3Cpath d='M26 20 L23 17 L22 21 Z' fill='rgba(255,200,50,0.55)' stroke='rgba(255,200,50,0.4)' stroke-width='0.7'/%3E%3Cpath d='M18 24 L21 22 L20 27 Z' fill='rgba(255,200,50,0.5)' stroke='rgba(255,200,50,0.35)' stroke-width='0.7'/%3E%3C!-- glint dot --%3E%3Ccircle cx='16' cy='9' r='1.2' fill='rgba(255,255,200,0.9)'/%3E%3C/svg%3E");
  background-size: contain;
  background-repeat: no-repeat;
  background-position: center;
  animation: mine-pulse 2.5s ease-in-out infinite;
}

/* Active mine spot (has a base on it) */
.cell.mine-spot-cell.mine-active .mine-spot-marker {
  display: none;
}

/* ════════════════════════════════════════
   CONTROL POINTS — improved
════════════════════════════════════════ */
.control-point {
  font-size: 13px;
  font-weight: 700;
  color: var(--cp-color);
  opacity: 0.6;
  width: 32px;
  height: 32px;
  border: 1.5px dashed rgba(0,255,200,0.5);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  position: absolute;
  top: calc((var(--board-cell-size) - 32px) / 2);
  left: calc((var(--board-cell-size) - 32px) / 2);
  pointer-events: none;
  transition: opacity 0.2s, box-shadow 0.2s;
}

.cell.cp-cell:hover .control-point {
  opacity: 0.9;
  box-shadow: 0 0 10px rgba(0,255,200,0.3);
}

.cell.cp-owned-1 .control-point {
  border-color: rgba(74,168,255,0.7);
  color: var(--p1);
  opacity: 0.85;
  box-shadow: 0 0 8px rgba(74,168,255,0.3);
  animation: reactor-pulse 2.5s ease-in-out infinite;
}

.cell.cp-owned-2 .control-point {
  border-color: rgba(255,100,68,0.7);
  color: var(--p2);
  opacity: 0.85;
  box-shadow: 0 0 8px rgba(255,100,68,0.3);
  animation: reactor-pulse 2.5s ease-in-out infinite;
}

/* ════════════════════════════════════════
   NEBULA CELLS — richer glow
════════════════════════════════════════ */
.cell.nebula::before {
  content: '';
  position: absolute;
  inset: 4px;
  border-radius: 48% 52% 55% 45% / 43% 57% 45% 55%;
  background:
    radial-gradient(ellipse at 40% 35%, rgba(200,140,255,0.22), transparent 55%),
    radial-gradient(ellipse at 65% 70%, rgba(80,200,255,0.14), transparent 50%);
  border: 1px solid rgba(200,140,255,0.2);
  box-shadow: 0 0 14px rgba(180,120,255,0.18), inset 0 0 8px rgba(150,100,255,0.1);
  pointer-events: none;
  animation: reactor-pulse 4s ease-in-out infinite alternate;
}

.cell.nebula::after {
  content: '';
  position: absolute;
  inset: 10px;
  border-radius: 59% 41% 47% 53% / 51% 49% 56% 44%;
  border: 1px solid rgba(100,220,230,0.14);
  opacity: 0.7;
  pointer-events: none;
}

/* ════════════════════════════════════════
   GRAVITY WELL — animated pull rings
════════════════════════════════════════ */
@keyframes gravity-spin {
  from { transform: rotate(0deg); }
  to   { transform: rotate(-360deg); }
}

.cell.gravity-well::before {
  content: '';
  position: absolute;
  inset: 6px;
  border-radius: 50%;
  border: 1.5px solid rgba(154,126,255,0.3);
  box-shadow:
    0 0 16px rgba(154,126,255,0.2),
    inset 0 0 14px rgba(96,86,180,0.25);
  pointer-events: none;
  animation: gravity-spin 6s linear infinite;
}

.cell.gravity-well::after {
  content: '';
  position: absolute;
  inset: 14px;
  border-radius: 50%;
  background:
    radial-gradient(circle, rgba(10,6,26,0.94) 0 28%, rgba(52,36,96,0.5) 50%, transparent 75%);
  box-shadow: 0 0 20px rgba(124,98,255,0.3);
  pointer-events: none;
  animation: gravity-spin 3s linear infinite reverse;
}

/* ════════════════════════════════════════
   DEPLOY ZONE IMPROVEMENTS
════════════════════════════════════════ */
.cell.deploy-zone-1 {
  background: linear-gradient(180deg, rgba(74,168,255,0.1), rgba(74,168,255,0.04));
  box-shadow: inset 0 0 0 1px rgba(74,168,255,0.18);
}
.cell.deploy-zone-2 {
  background: linear-gradient(180deg, rgba(255,100,68,0.1), rgba(255,100,68,0.04));
  box-shadow: inset 0 0 0 1px rgba(255,100,68,0.18);
}

/* ════════════════════════════════════════
   HP BARS — slightly taller, cleaner
════════════════════════════════════════ */
.ship-hp-bar {
  position: absolute;
  bottom: 2px;
  left: 3px;
  right: 3px;
  height: 4px;
  background: rgba(2,6,14,0.85);
  border-radius: 2px;
  overflow: hidden;
}

.ship-hp-bar-fill {
  height: 100%;
  background: linear-gradient(90deg, #22b358, var(--green));
  transition: width 0.3s ease;
  border-radius: 2px;
}

/* HP bar turns red at low health */
.ship-hp-bar-fill[style*="width: 2"],
.ship-hp-bar-fill[style*="width: 1"],
.ship-hp-bar-fill[style*="width:2"],
.ship-hp-bar-fill[style*="width:1"] {
  background: linear-gradient(90deg, #cc1122, #ff3344);
  animation: reactor-pulse 0.8s ease-in-out infinite;
}

/* ════════════════════════════════════════
   SHIELD PIPS — rounder, better contrast
════════════════════════════════════════ */
.sh-pip {
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: rgba(80,150,255,0.9);
  box-shadow: 0 0 5px rgba(80,150,255,0.6), 0 0 2px rgba(255,255,255,0.3);
  flex-shrink: 0;
}
.sh-pip.lost {
  background: rgba(20,30,50,0.8);
  box-shadow: none;
}

/* P2 shields */
.ship-marker.p2 .sh-pip {
  background: rgba(255,120,80,0.9);
  box-shadow: 0 0 5px rgba(255,120,80,0.6), 0 0 2px rgba(255,255,255,0.3);
}

/* ════════════════════════════════════════
   WRECK MARKERS — warmer, more visible
════════════════════════════════════════ */
.wreck-marker {
  opacity: 1;
}

.wreck-marker::before {
  box-shadow:
    0 0 10px rgba(200,160,100,0.22),
    inset 0 0 8px rgba(100,200,255,0.07);
}

/* ════════════════════════════════════════
   TORPEDO PENDING INDICATOR — brighter
════════════════════════════════════════ */
.torpedo-pending {
  background: var(--purple);
  border: 1.5px solid rgba(200,100,255,0.8);
  box-shadow: 0 0 8px rgba(200,100,255,0.6);
  animation: reactor-pulse 1s ease-in-out infinite;
}

/* ════════════════════════════════════════
   SELECTED SHIP — stronger highlight
════════════════════════════════════════ */
.ship-marker.selected {
  box-shadow:
    0 0 0 2px rgba(255,200,0,0.7),
    0 0 14px rgba(255,200,0,0.35),
    0 0 28px rgba(255,200,0,0.12);
  z-index: 3;
}

/* ════════════════════════════════════════
   NO-ACTIONS DIM — clearer
════════════════════════════════════════ */
.ship-marker.no-actions {
  opacity: 0.38;
  filter: saturate(0.5);
}

/* ════════════════════════════════════════
   COMMANDER PING MARKERS
════════════════════════════════════════ */
.commander-ping-marker {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 28px;
  height: 28px;
  border-radius: 50%;
  pointer-events: none;
  z-index: 4;
}

.hunt-ping-marker {
  border: 2px solid rgba(255,60,60,0.6);
  box-shadow: 0 0 10px rgba(255,60,60,0.3);
  animation: reactor-pulse 1.5s ease-in-out infinite;
}

.defend-ping-marker {
  border: 2px solid rgba(60,200,255,0.6);
  box-shadow: 0 0 10px rgba(60,200,255,0.3);
  animation: reactor-pulse 2s ease-in-out infinite;
}

/* ════════════════════════════════════════
   CONVERTING BADGE — more visible
════════════════════════════════════════ */
.converting-badge {
  font-family: var(--font-ui, 'Space Grotesk', system-ui);
  font-size: 8px;
  font-weight: 700;
  background: rgba(0,0,0,0.8);
  border: 1.5px solid rgba(255,200,50,0.9);
  border-radius: 3px;
  color: rgba(255,200,50,1);
  padding: 2px 4px;
  animation: mine-pulse 1s ease-in-out infinite;
}

/* ════════════════════════════════════════
   RANK ICONS — cleaner glow
════════════════════════════════════════ */
.rank-icon.rank-veteran {
  color: #88ccff;
  text-shadow: 0 0 6px #88ccff, 0 0 2px rgba(255,255,255,0.4);
  font-size: 8px;
}
.rank-icon.rank-elite {
  color: var(--yellow);
  text-shadow: 0 0 8px var(--yellow), 0 0 3px rgba(255,255,255,0.4);
  font-size: 8px;
}

/* ════════════════════════════════════════
   CELL HIGHLIGHT IMPROVEMENTS
════════════════════════════════════════ */
.cell.hl-move {
  background: linear-gradient(180deg, rgba(0,210,255,0.22), rgba(0,210,255,0.1));
  box-shadow: inset 0 0 0 1px rgba(0,220,255,0.5), inset 0 0 12px rgba(0,210,255,0.12);
  cursor: crosshair;
}
.cell.hl-attack {
  background: linear-gradient(180deg, rgba(255,55,55,0.4), rgba(255,55,55,0.22));
  box-shadow: inset 0 0 0 1px rgba(255,100,100,0.55), inset 0 0 14px rgba(255,55,55,0.18);
  cursor: crosshair;
}
.cell.hl-deploy {
  background: linear-gradient(180deg, rgba(80,255,140,0.2), rgba(80,255,140,0.08));
  box-shadow: inset 0 0 0 1px rgba(100,255,160,0.35);
  cursor: crosshair;
}
.cell.hl-dest {
  background: linear-gradient(180deg, rgba(255,210,40,0.25), rgba(255,210,40,0.1));
  box-shadow: inset 0 0 0 1px rgba(255,220,100,0.4);
}
