/* =========================================================
   FEED THE KRAKEN - Nautical Luxury UI & Mobile Architecture
   ========================================================= */

@import url('https://fonts.googleapis.com/css2?family=Cinzel:wght@600;700;900&family=Outfit:wght@300;400;500;600;700;800&display=swap');

:root {
  --bg-dark: #070d18;
  --bg-surface: rgba(13, 23, 42, 0.92);
  --bg-glass: rgba(15, 23, 42, 0.82);
  --border-glass: rgba(255, 255, 255, 0.12);
  
  --color-sailor: #38bdf8;
  --color-sailor-glow: rgba(56, 189, 248, 0.45);
  --color-pirate: #ef4444;
  --color-pirate-glow: rgba(239, 68, 68, 0.45);
  --color-cult: #eab308;
  --color-cult-glow: rgba(234, 179, 8, 0.45);
  
  --gold-accent: #f59e0b;
  --gold-bright: #fbbf24;
  --text-primary: #f8fafc;
  --text-secondary: #94a3b8;
  --text-muted: #64748b;
  
  --shadow-lg: 0 16px 36px -8px rgba(0, 0, 0, 0.65), 0 0 20px rgba(0, 0, 0, 0.4);
  --shadow-gold: 0 0 25px rgba(245, 158, 11, 0.25);
  
  --safe-top: env(safe-area-inset-top, 0px);
  --safe-bottom: env(safe-area-inset-bottom, 0px);
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
  user-select: none;
  -webkit-tap-highlight-color: transparent;
}

html, body {
  font-family: 'Outfit', sans-serif;
  background-color: #030712;
  color: var(--text-primary);
  height: 100%;
  height: 100dvh;
  width: 100vw;
  overflow: hidden;
  position: fixed;
  inset: 0;
}

/* =========================================================
   1. LAPTOP SMARTPHONE SIMULATOR FRAME (DESKTOP ONLY)
   ========================================================= */

/* Desktop view when simulator is active */
@media (min-width: 901px) {
  body.sim-active {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    background: radial-gradient(circle at 50% 30%, #0f172a 0%, #020617 100%);
  }

  body.sim-active::before {
    content: '';
    position: absolute;
    inset: 0;
    background-image: 
      radial-gradient(rgba(245, 158, 11, 0.08) 1px, transparent 1px),
      radial-gradient(rgba(56, 189, 248, 0.05) 1px, transparent 1px);
    background-size: 32px 32px;
    background-position: 0 0, 16px 16px;
    pointer-events: none;
    opacity: 0.8;
  }

  /* Desktop Simulator Toolbar */
  .sim-toolbar {
    position: fixed;
    top: 12px;
    left: 50%;
    transform: translateX(-50%);
    z-index: 1000;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 14px;
    background: rgba(15, 23, 42, 0.88);
    backdrop-filter: blur(20px);
    border: 1px solid rgba(245, 158, 11, 0.35);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.6), 0 0 20px rgba(245, 158, 11, 0.15);
    padding: 6px 16px;
    border-radius: 30px;
  }

  body.sim-inactive .sim-toolbar {
    top: 10px;
    right: 18px;
    left: auto;
    transform: none;
    background: rgba(15, 23, 42, 0.95);
  }

  /* Device Simulator Bezel */
  body.sim-active .device-sim-container {
    position: relative;
    z-index: 10;
    display: flex;
    flex-direction: column;
    background: #000;
    overflow: hidden;
    box-shadow: 
      0 25px 80px -10px rgba(0, 0, 0, 0.9),
      0 0 0 1px rgba(255, 255, 255, 0.1),
      0 0 40px rgba(245, 158, 11, 0.15);
    transition: all 0.3s ease;
  }

  body.sim-active .device-sim-container.iphone-15-pro {
    width: 393px;
    height: 852px;
    border-radius: 52px;
    border: 10px solid #27272a;
  }

  body.sim-active .device-sim-container.iphone-15-max {
    width: 430px;
    height: 932px;
    border-radius: 54px;
    border: 11px solid #27272a;
  }

  body.sim-active .device-sim-container.galaxy-s24 {
    width: 412px;
    height: 915px;
    border-radius: 44px;
    border: 9px solid #1e293b;
  }

  body.sim-active .device-sim-container.pixel-8 {
    width: 412px;
    height: 892px;
    border-radius: 48px;
    border: 9px solid #18181b;
  }

  body.sim-active .device-sim-container.landscape {
    transform: rotate(-90deg);
  }

  /* Island & Status Bar */
  .device-bezel-island {
    position: absolute;
    top: 11px;
    left: 50%;
    transform: translateX(-50%);
    z-index: 200;
    pointer-events: none;
  }

  .device-island-pill {
    width: 116px;
    height: 30px;
    background: #000;
    border-radius: 20px;
    display: flex;
    align-items: center;
    justify-content: flex-end;
    padding-right: 12px;
    gap: 10px;
  }

  .island-camera {
    width: 11px;
    height: 11px;
    border-radius: 50%;
    background: radial-gradient(circle at 35% 35%, #1e293b 0%, #020617 80%);
    border: 1px solid rgba(255, 255, 255, 0.15);
  }

  .island-sensor {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: #09090b;
  }

  .device-status-bar {
    height: 42px;
    background: transparent;
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    padding: 0 24px 6px;
    z-index: 190;
    font-size: 13px;
    font-weight: 700;
    color: #f8fafc;
    pointer-events: none;
    flex-shrink: 0;
  }

  .status-indicators {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 11px;
  }

  .status-battery {
    width: 22px;
    height: 11px;
    border: 1px solid rgba(255, 255, 255, 0.8);
    border-radius: 3px;
    padding: 1px;
    position: relative;
  }

  .status-battery::after {
    content: '';
    position: absolute;
    right: -3px;
    top: 3px;
    width: 2px;
    height: 4px;
    background: rgba(255, 255, 255, 0.8);
    border-radius: 0 1px 1px 0;
  }

  .battery-fill {
    display: block;
    width: 80%;
    height: 100%;
    background: #22c55e;
    border-radius: 1px;
  }

  .device-home-indicator {
    position: absolute;
    bottom: 8px;
    left: 50%;
    transform: translateX(-50%);
    width: 134px;
    height: 5px;
    background: rgba(255, 255, 255, 0.6);
    border-radius: 10px;
    z-index: 200;
    pointer-events: none;
  }
}

/* =========================================================
   2. NATIVE SMARTPHONE & FULLSCREEN RULES
   ========================================================= */

/* On real mobile screens or when sim is inactive */
@media (max-width: 900px) {
  .sim-toolbar,
  .device-bezel-island,
  .device-status-bar,
  .device-home-indicator {
    display: none !important;
  }

  .device-sim-container {
    width: 100vw !important;
    height: 100dvh !important;
    border: none !important;
    border-radius: 0 !important;
    box-shadow: none !important;
    transform: none !important;
    background: transparent !important;
  }
}

body.sim-inactive {
  display: block;
  width: 100vw;
  height: 100vh;
  height: 100dvh;
}

body.sim-inactive .device-sim-container {
  width: 100vw !important;
  height: 100dvh !important;
  border: none !important;
  border-radius: 0 !important;
  box-shadow: none !important;
  transform: none !important;
  background: transparent !important;
}

body.sim-inactive .device-bezel-island,
body.sim-inactive .device-status-bar,
body.sim-inactive .device-home-indicator {
  display: none !important;
}

/* =========================================================
   3. APP VIEWPORT & MOBILE LAYOUT (DEFAULT FOR ALL PHONES)
   ========================================================= */

.app-viewport-inner {
  display: flex;
  flex-direction: column;
  position: relative;
  overflow: hidden;
  height: 100%;
  width: 100%;
}

/* App Header */
.app-header {
  height: 48px;
  background: var(--bg-surface);
  backdrop-filter: blur(16px);
  border-bottom: 1px solid var(--border-glass);
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 10px;
  z-index: 50;
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.4);
  flex-shrink: 0;
  padding-top: var(--safe-top);
}

.brand-container {
  display: flex;
  align-items: center;
  gap: 6px;
}

.brand-icon {
  font-size: 20px;
  filter: drop-shadow(0 0 6px var(--color-cult-glow));
}

.brand-title {
  font-family: 'Cinzel', serif;
  font-size: 14px;
  font-weight: 900;
  letter-spacing: 1px;
  background: linear-gradient(135deg, #fef08a 0%, #f59e0b 50%, #d97706 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

.brand-subtitle {
  display: none;
}

/* Header Room Badge */
.header-room-info {
  display: flex;
  align-items: center;
  gap: 4px;
}

.room-pill-code {
  background: rgba(245, 158, 11, 0.15);
  border: 1px solid rgba(245, 158, 11, 0.4);
  color: var(--gold-bright);
  font-size: 11px;
  font-weight: 800;
  padding: 2px 6px;
  border-radius: 10px;
}

.room-pill-players {
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.15);
  color: #cbd5e1;
  font-size: 10px;
  font-weight: 700;
  padding: 2px 5px;
  border-radius: 10px;
}

.room-pill-captain {
  background: rgba(245, 158, 11, 0.2);
  border: 1px solid rgba(245, 158, 11, 0.5);
  color: #fef08a;
  font-size: 10px;
  font-weight: 800;
  padding: 2px 6px;
  border-radius: 10px;
  max-width: 90px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.header-actions {
  display: flex;
  align-items: center;
  gap: 5px;
}

.btn-icon, .btn-icon-gold {
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.15);
  color: #e2e8f0;
  width: 32px;
  height: 32px;
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 14px;
  cursor: pointer;
  transition: all 0.15s ease;
}

.btn-icon:active, .btn-icon-gold:active {
  transform: scale(0.92);
}

.btn-icon-gold {
  background: rgba(245, 158, 11, 0.2);
  border-color: rgba(245, 158, 11, 0.5);
  color: #fef08a;
}

.btn-header-room, .btn-header-reset {
  display: none;
}

/* =========================================================
   4. CANVAS VIEWPORT & FLOATING CONTROLS
   ========================================================= */

.app-container {
  flex: 1;
  min-height: 0;
  display: flex;
  position: relative;
  overflow: hidden;
  width: 100%;
}

.canvas-container {
  flex: 1;
  position: relative;
  background: radial-gradient(circle at center, #0f1f38 0%, #060b14 100%);
  overflow: hidden;
  touch-action: none;
  width: 100%;
  height: 100%;
}

#boardCanvas {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  display: block;
}

/* Floating Zoom Controls */
.viewport-toolbar {
  position: absolute;
  top: 10px;
  right: 10px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
  z-index: 30;
  background: rgba(15, 23, 42, 0.88);
  backdrop-filter: blur(14px);
  padding: 5px;
  border-radius: 12px;
  border: 1px solid rgba(245, 158, 11, 0.35);
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.6);
}

.tool-btn {
  width: 32px;
  height: 32px;
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.15);
  color: var(--text-primary);
  font-size: 13px;
  font-weight: 800;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.15s ease;
}

.tool-btn:hover {
  background: rgba(245, 158, 11, 0.2);
  border-color: var(--gold-bright);
  color: #fff;
}

.tool-btn:active {
  transform: scale(0.92);
}

.zoom-pill {
  font-size: 9.5px;
  font-weight: 800;
  color: var(--gold-bright);
  padding: 2px 4px;
  text-align: center;
  cursor: pointer;
}

/* Player Seats Around Board Overlay */
.player-seats-overlay {
  position: absolute;
  inset: 0;
  pointer-events: none;
  z-index: 15;
  overflow: hidden;
}

.board-player-seat {
  position: absolute;
  pointer-events: auto;
  transform: translate(-50%, -50%);
  width: 52px;
  height: 52px;
  border-radius: 50%;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  background: radial-gradient(circle at 35% 30%, #1e293b 0%, #0f172a 75%, #020617 100%);
  border: 2.5px solid rgba(245, 158, 11, 0.75);
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.8), inset 0 0 8px rgba(0, 0, 0, 0.75), 0 0 10px rgba(245, 158, 11, 0.25);
  user-select: none;
  cursor: pointer;
  transition: transform 0.15s ease, border-color 0.2s ease, box-shadow 0.2s ease;
  z-index: 20;
}

@media (min-width: 768px) {
  .board-player-seat {
    width: 62px;
    height: 62px;
  }
}

.board-player-seat:hover, .board-player-seat:active {
  transform: translate(-50%, -50%) scale(1.1);
  border-color: #fbbf24;
  box-shadow: 0 6px 18px rgba(0, 0, 0, 0.9), 0 0 16px rgba(245, 158, 11, 0.6);
}

.board-player-seat.is-captain {
  border-color: #f59e0b;
  border-width: 3px;
  background: radial-gradient(circle at 35% 30%, #292524 0%, #1c1917 65%, #0c0a09 100%);
  box-shadow: 0 0 22px rgba(245, 158, 11, 0.75), inset 0 0 10px rgba(245, 158, 11, 0.4);
}

.board-player-seat.is-lieutenant {
  border-color: #3b82f6;
  border-width: 3px;
  background: radial-gradient(circle at 35% 30%, #1e3a8a 0%, #0f172a 75%, #020617 100%);
  box-shadow: 0 0 20px rgba(59, 130, 246, 0.75), inset 0 0 10px rgba(59, 130, 246, 0.4);
}

.board-player-seat.is-navigator {
  border-color: #10b981;
  border-width: 3px;
  background: radial-gradient(circle at 35% 30%, #064e3b 0%, #0f172a 75%, #020617 100%);
  box-shadow: 0 0 20px rgba(16, 185, 129, 0.75), inset 0 0 10px rgba(16, 185, 129, 0.4);
}

.board-player-seat.is-me {
  border-color: #38bdf8;
  box-shadow: 0 0 14px rgba(56, 189, 248, 0.5), inset 0 0 8px rgba(56, 189, 248, 0.25);
}

.board-player-seat.selectable-candidate {
  cursor: pointer;
  animation: pulseCandidate 1.4s ease-in-out infinite;
}

@keyframes pulseCandidate {
  0%, 100% {
    transform: translate(-50%, -50%) scale(1);
    box-shadow: 0 0 12px rgba(245, 158, 11, 0.4);
  }
  50% {
    transform: translate(-50%, -50%) scale(1.12);
    box-shadow: 0 0 24px rgba(245, 158, 11, 0.9), 0 0 10px #fbbf24;
    border-color: #fbbf24;
  }
}

.seat-crown-crest,
.seat-lieutenant-crest,
.seat-navigator-crest {
  position: absolute;
  top: -16px;
  left: 50%;
  transform: translateX(-50%);
  font-size: 19px;
  line-height: 1;
  filter: drop-shadow(0 2px 5px rgba(0, 0, 0, 0.9));
  animation: crownFloat 3s ease-in-out infinite;
  z-index: 30;
  pointer-events: none;
}

.seat-crown-crest {
  filter: drop-shadow(0 2px 5px rgba(0, 0, 0, 0.9)) drop-shadow(0 0 8px rgba(245, 158, 11, 0.85));
}

.seat-lieutenant-crest {
  filter: drop-shadow(0 2px 5px rgba(0, 0, 0, 0.9)) drop-shadow(0 0 8px rgba(59, 130, 246, 0.85));
}

.seat-navigator-crest {
  filter: drop-shadow(0 2px 5px rgba(0, 0, 0, 0.9)) drop-shadow(0 0 8px rgba(16, 185, 129, 0.85));
}

@keyframes crownFloat {
  0%, 100% {
    transform: translateX(-50%) translateY(0) rotate(0deg);
  }
  50% {
    transform: translateX(-50%) translateY(-2px) rotate(-3deg);
  }
}

@media (min-width: 768px) {
  .seat-crown-crest,
  .seat-lieutenant-crest,
  .seat-navigator-crest {
    top: -19px;
    font-size: 23px;
  }
}

.seat-circle-inner {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 2px 4px;
  width: 100%;
  height: 100%;
  box-sizing: border-box;
}

.seat-circle-name {
  font-family: 'Cinzel', serif;
  font-size: 10px;
  font-weight: 800;
  color: #f8fafc;
  line-height: 1.15;
  letter-spacing: 0.2px;
  text-shadow: 0 1px 3px rgba(0, 0, 0, 0.95);
  max-width: 44px;
  overflow: hidden;
  text-overflow: ellipsis;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  word-break: break-word;
}

@media (min-width: 768px) {
  .seat-circle-name {
    font-size: 11.5px;
    max-width: 52px;
  }
}

.seat-badge-tag {
  position: absolute;
  bottom: -6px;
  font-size: 7.5px;
  font-weight: 800;
  padding: 1px 4px;
  border-radius: 4px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  white-space: nowrap;
}

.seat-badge-tag.captain {
  background: linear-gradient(135deg, #f59e0b 0%, #d97706 100%);
  color: #000;
  font-weight: 900;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.7), 0 0 8px rgba(245, 158, 11, 0.5);
  border: 1px solid rgba(254, 243, 199, 0.6);
}

.seat-badge-tag.lieutenant {
  background: linear-gradient(135deg, #3b82f6 0%, #1d4ed8 100%);
  color: #fff;
  font-weight: 900;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.7), 0 0 8px rgba(59, 130, 246, 0.5);
  border: 1px solid rgba(191, 219, 254, 0.6);
}

.seat-badge-tag.navigator {
  background: linear-gradient(135deg, #10b981 0%, #047857 100%);
  color: #fff;
  font-weight: 900;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.7), 0 0 8px rgba(16, 185, 129, 0.5);
  border: 1px solid rgba(167, 243, 208, 0.6);
}

.seat-badge-tag.you {
  background: rgba(56, 189, 248, 0.95);
  color: #000;
  font-weight: 900;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.6);
}

.seat-badge-tag.off-duty {
  background: linear-gradient(135deg, #475569 0%, #1e293b 100%);
  color: #fbbf24;
  font-weight: 900;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.7), 0 0 8px rgba(100, 116, 139, 0.5);
  border: 1px solid rgba(251, 191, 36, 0.6);
}

.seat-badge-tag.mutiny-ready {
  background: linear-gradient(135deg, #10b981 0%, #059669 100%);
  color: #ffffff;
  font-weight: 900;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.7), 0 0 8px rgba(16, 185, 129, 0.5);
  border: 1px solid rgba(167, 243, 208, 0.6);
}

.seat-badge-tag.mutiny-thinking {
  background: linear-gradient(135deg, #334155 0%, #1e293b 100%);
  color: #94a3b8;
  font-weight: 700;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.7);
  border: 1px solid rgba(148, 163, 184, 0.3);
}

.board-player-seat.is-off-duty {
  border-color: #64748b !important;
  border-style: dashed !important;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.7) !important;
  opacity: 0.8;
}

.board-player-seat.is-off-duty:hover {
  border-color: #f59e0b !important;
  cursor: not-allowed !important;
}

.seat-offduty-crest {
  position: absolute;
  top: -16px;
  left: 50%;
  transform: translateX(-50%);
  font-size: 17px;
  line-height: 1;
  filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.9));
  z-index: 30;
  pointer-events: none;
  animation: sleepFloat 2.5s ease-in-out infinite;
}

@keyframes sleepFloat {
  0%, 100% {
    transform: translateX(-50%) translateY(0);
    opacity: 0.85;
  }
  50% {
    transform: translateX(-50%) translateY(-3px);
    opacity: 1;
  }
}

/* Mobile Location Floating Pill */
.mobile-location-pill {
  position: absolute;
  top: 10px;
  left: 10px;
  z-index: 30;
  display: inline-flex;
  align-items: center;
  pointer-events: none;
}

.pill-dot,
#mobilePillName {
  display: none !important;
}

.pill-zone {
  font-size: 9px;
  padding: 2.5px 8px;
  border-radius: 8px;
  font-weight: 800;
  letter-spacing: 0.5px;
  text-transform: uppercase;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.4);
  flex-shrink: 0;
}

.pill-zone.zone-calm {
  background: rgba(56, 189, 248, 0.22);
  border: 1.5px solid rgba(56, 189, 248, 0.65);
  color: #38bdf8;
  box-shadow: 0 0 8px rgba(56, 189, 248, 0.35);
}

.pill-zone.zone-wild {
  background: rgba(99, 102, 241, 0.22);
  border: 1.5px solid rgba(99, 102, 241, 0.65);
  color: #a5b4fc;
  box-shadow: 0 0 8px rgba(99, 102, 241, 0.35);
}

.pill-zone.zone-cult {
  background: rgba(234, 179, 8, 0.22);
  border: 1.5px solid rgba(234, 179, 8, 0.65);
  color: #facc15;
  box-shadow: 0 0 8px rgba(234, 179, 8, 0.35);
}

/* Player Guns Pill (Displays actual gun icons under Calm pill) */
.player-guns-pill {
  position: absolute;
  top: 35px;
  left: 10px;
  z-index: 30;
  background: rgba(15, 23, 42, 0.92);
  backdrop-filter: blur(14px);
  border: 1.5px solid rgba(245, 158, 11, 0.45);
  padding: 2.5px 8px;
  border-radius: 12px;
  display: flex;
  align-items: center;
  gap: 5px;
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.65), 0 0 10px rgba(245, 158, 11, 0.15);
  transition: all 0.2s ease;
}

.guns-pill-label {
  font-family: 'Cinzel', serif;
  font-size: 9.5px;
  font-weight: 800;
  color: var(--gold-bright);
  letter-spacing: 0.5px;
}

.guns-pill-icons {
  display: flex;
  align-items: center;
  gap: 3px;
}

.gun-icon {
  font-size: 13.5px;
  line-height: 1;
  filter: drop-shadow(0 1px 3px rgba(0, 0, 0, 0.9)) drop-shadow(0 0 5px rgba(245, 158, 11, 0.5));
  transition: transform 0.2s ease, opacity 0.2s ease;
  display: inline-block;
}

.gun-icon.spent {
  opacity: 0.2;
  filter: grayscale(1);
}

/* Sidebar is strictly hidden on mobile / phone view */
.sidebar-panel {
  display: none !important;
}

/* =========================================================
   5. MOBILE ERGONOMIC SAILING DOCK & BOTTOM NAV
   ========================================================= */

/* Navigation Phase Card (Movement Locked for Cards) */
.navigation-phase-card {
  background: rgba(15, 23, 42, 0.75);
  border: 1px solid rgba(245, 158, 11, 0.35);
  border-radius: 12px;
  padding: 12px;
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.phase-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.phase-badge {
  font-size: 10px;
  font-weight: 800;
  color: var(--gold-bright);
  letter-spacing: 0.5px;
}

.phase-step {
  font-size: 11px;
  font-weight: 700;
  color: var(--text-secondary);
}

.phase-desc {
  font-size: 11px;
  color: var(--text-secondary);
  line-height: 1.4;
}

/* =========================================================
   PHASE 1: APPOINT NAVIGATION TEAM COMMAND BAR
   ========================================================= */

.game-phase-bar {
  position: relative;
  flex-shrink: 0;
  margin: 2px 6px 4px 6px;
  background: linear-gradient(180deg, rgba(17, 24, 39, 0.96) 0%, rgba(10, 15, 29, 0.98) 100%);
  border: 1.5px solid rgba(245, 158, 11, 0.45);
  border-radius: 12px;
  padding: 4px 8px;
  display: flex;
  flex-direction: column;
  gap: 4px;
  box-shadow: 0 4px 18px rgba(0, 0, 0, 0.7), 0 0 12px rgba(245, 158, 11, 0.12);
  backdrop-filter: blur(14px);
  z-index: 45;
  transition: all 0.25s ease;
}

@media (min-width: 768px) {
  .game-phase-bar {
    max-width: 520px;
    margin: 4px auto 8px auto;
    width: 100%;
  }
}

.phase-info-row {
  display: flex;
  align-items: center;
  gap: 7px;
}

.phase-badge-pill {
  display: flex;
  align-items: center;
  gap: 4px;
  background: rgba(245, 158, 11, 0.18);
  border: 1px solid rgba(245, 158, 11, 0.45);
  border-radius: 10px;
  padding: 1px 6px;
  flex-shrink: 0;
}

.phase-badge-pill .phase-dot {
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: #f59e0b;
  box-shadow: 0 0 6px #f59e0b;
  animation: pulseDot 2s infinite;
}

@keyframes pulseDot {
  0%, 100% { opacity: 0.6; transform: scale(0.9); }
  50% { opacity: 1; transform: scale(1.15); }
}

.phase-step-num {
  font-family: 'Cinzel', serif;
  font-size: 9.5px;
  font-weight: 800;
  color: var(--gold-bright);
  letter-spacing: 0.5px;
}

.phase-instruction {
  font-size: 11px;
  color: #e2e8f0;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  flex: 1;
  min-width: 0;
}

.phase-instruction strong {
  color: var(--gold-bright);
  font-weight: 700;
}

.btn-admin-pill {
  margin-left: auto;
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 2px 7px;
  height: 20px;
  border-radius: 10px;
  background: rgba(16, 185, 129, 0.2);
  border: 1px solid rgba(16, 185, 129, 0.55);
  color: #6ee7b7;
  font-size: 9px;
  font-weight: 700;
  cursor: pointer;
  white-space: nowrap;
  transition: all 0.2s ease;
  user-select: none;
  flex-shrink: 0;
}

.btn-admin-pill.disabled {
  background: rgba(148, 163, 184, 0.12);
  border-color: rgba(148, 163, 184, 0.35);
  color: #94a3b8;
}

.btn-admin-pill:hover {
  transform: translateY(-1px);
}

.phase-officers-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 5px;
}

.officer-slot-card {
  background: rgba(15, 23, 42, 0.7);
  border: 1.5px dashed rgba(148, 163, 184, 0.35);
  border-radius: 8px;
  padding: 4px 6px;
  display: flex;
  flex-direction: column;
  gap: 1px;
  position: relative;
  cursor: pointer;
  user-select: none;
  transition: all 0.18s ease;
}

.officer-slot-card:hover {
  border-color: rgba(245, 158, 11, 0.6);
  background: rgba(30, 41, 59, 0.65);
  transform: translateY(-1px);
}

.officer-slot-card:active {
  transform: scale(0.98);
}

.officer-slot-card.officer-slot-readonly {
  cursor: default;
  opacity: 0.85;
}

.officer-slot-card.officer-slot-readonly:hover {
  border-color: rgba(148, 163, 184, 0.35);
  background: rgba(15, 23, 42, 0.7);
  transform: none;
}

.officer-slot-card.active-selecting {
  border-color: #fbbf24;
  border-style: solid;
  background: rgba(245, 158, 11, 0.14);
  box-shadow: 0 0 14px rgba(245, 158, 11, 0.45);
  animation: pulseCard 1.5s infinite;
}

@keyframes pulseCard {
  0%, 100% { box-shadow: 0 0 10px rgba(245, 158, 11, 0.35); }
  50% { box-shadow: 0 0 18px rgba(245, 158, 11, 0.75); }
}

.officer-slot-card.is-filled-lt {
  border-style: solid;
  border-color: rgba(59, 130, 246, 0.65);
  background: rgba(30, 58, 138, 0.25);
  box-shadow: 0 0 12px rgba(59, 130, 246, 0.25);
}

.officer-slot-card.is-filled-nav {
  border-style: solid;
  border-color: rgba(16, 185, 129, 0.65);
  background: rgba(6, 78, 59, 0.25);
  box-shadow: 0 0 12px rgba(16, 185, 129, 0.25);
}

.officer-slot-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 4px;
}

.officer-slot-badge {
  font-size: 8px;
  font-weight: 800;
  letter-spacing: 0.5px;
  text-transform: uppercase;
  color: #94a3b8;
}

.officer-slot-card.is-filled-lt .officer-slot-badge {
  color: #60a5fa;
}

.officer-slot-card.is-filled-nav .officer-slot-badge {
  color: #34d399;
}

.btn-officer-clear {
  font-size: 8px;
  font-weight: 800;
  padding: 1px 5px;
  border-radius: 4px;
  background: rgba(239, 68, 68, 0.22);
  border: 1px solid rgba(239, 68, 68, 0.45);
  color: #fca5a5;
  cursor: pointer;
  transition: all 0.15s ease;
  line-height: 1.3;
}

.btn-officer-clear:hover {
  background: rgba(239, 68, 68, 0.45);
  color: #fff;
}

.officer-slot-name {
  font-family: 'Cinzel', serif;
  font-size: 11px;
  font-weight: 700;
  color: #cbd5e1;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  min-height: 18px;
  display: flex;
  align-items: center;
}

.officer-slot-card.active-selecting .officer-slot-name {
  color: #fbbf24;
  font-style: italic;
}

.officer-slot-card.is-filled-lt .officer-slot-name,
.officer-slot-card.is-filled-nav .officer-slot-name {
  color: #f8fafc;
  font-weight: 800;
}

.phase-submit-row {
  margin-top: 1px;
}

.btn-confirm-team {
  width: 100%;
  height: 29px;
  border-radius: 8px;
  font-family: 'Cinzel', serif;
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0.5px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: linear-gradient(135deg, #f59e0b 0%, #d97706 100%);
  color: #020617;
  border: 1px solid rgba(254, 243, 199, 0.7);
  box-shadow: 0 4px 14px rgba(245, 158, 11, 0.4);
  cursor: pointer;
  transition: all 0.2s ease;
}

.btn-confirm-team:not(.disabled):hover {
  transform: translateY(-1px);
  box-shadow: 0 6px 20px rgba(245, 158, 11, 0.6);
}

.btn-confirm-team.disabled {
  opacity: 0.45;
  cursor: not-allowed;
  background: rgba(30, 41, 59, 0.8);
  color: #64748b;
  border-color: rgba(255, 255, 255, 0.1);
  box-shadow: none;
}

.btn-confirm-team.is-confirmed {
  background: linear-gradient(135deg, #059669 0%, #047857 100%);
  color: #fff;
  border-color: rgba(167, 243, 208, 0.6);
  box-shadow: 0 0 16px rgba(16, 185, 129, 0.5);
}

/* =========================================================
   APPOINTMENT MODAL (QUICK ACTION POPOVER)
   ========================================================= */

.appointment-modal {
  position: fixed;
  inset: 0;
  z-index: 100;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 16px;
}

.appointment-modal-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.75);
  backdrop-filter: blur(8px);
}

.appointment-modal-card {
  position: relative;
  width: 100%;
  max-width: 330px;
  background: linear-gradient(180deg, #1e293b 0%, #0f172a 100%);
  border: 2px solid rgba(245, 158, 11, 0.5);
  border-radius: 18px;
  padding: 16px 18px;
  box-shadow: 0 16px 40px rgba(0, 0, 0, 0.85), 0 0 20px rgba(245, 158, 11, 0.25);
  display: flex;
  flex-direction: column;
  gap: 12px;
  animation: modalPop 0.22s cubic-bezier(0.16, 1, 0.3, 1);
}

@keyframes modalPop {
  0% { opacity: 0; transform: scale(0.92); }
  100% { opacity: 1; transform: scale(1); }
}

.appointment-card-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}

.appointment-title-icon {
  font-size: 20px;
}

.appointment-modal-title {
  font-family: 'Cinzel', serif;
  font-size: 16px;
  font-weight: 800;
  color: var(--gold-bright);
  flex: 1;
}

.appointment-close-btn {
  background: rgba(255, 255, 255, 0.1);
  border: 1px solid rgba(255, 255, 255, 0.2);
  color: #fff;
  width: 28px;
  height: 28px;
  border-radius: 50%;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 13px;
  transition: background 0.15s;
}

.appointment-close-btn:hover {
  background: rgba(239, 68, 68, 0.4);
}

.appointment-subtitle {
  font-size: 12px;
  color: #cbd5e1;
  margin: 0;
}

.appointment-choices {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.btn-appoint-choice {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px 12px;
  border-radius: 12px;
  background: rgba(15, 23, 42, 0.8);
  border: 1.5px solid transparent;
  cursor: pointer;
  text-align: left;
  transition: all 0.18s ease;
}

.btn-appoint-choice:hover {
  transform: translateX(3px);
}

.btn-appoint-choice.choice-lt {
  border-color: rgba(59, 130, 246, 0.5);
  background: linear-gradient(90deg, rgba(30, 58, 138, 0.35) 0%, rgba(15, 23, 42, 0.8) 100%);
}

.btn-appoint-choice.choice-lt:hover {
  border-color: #3b82f6;
  box-shadow: 0 0 14px rgba(59, 130, 246, 0.4);
}

.btn-appoint-choice.choice-nav {
  border-color: rgba(16, 185, 129, 0.5);
  background: linear-gradient(90deg, rgba(6, 78, 59, 0.35) 0%, rgba(15, 23, 42, 0.8) 100%);
}

.btn-appoint-choice.choice-nav:hover {
  border-color: #10b981;
  box-shadow: 0 0 14px rgba(16, 185, 129, 0.4);
}

.btn-appoint-choice.choice-clear {
  border-color: rgba(239, 68, 68, 0.4);
  background: rgba(239, 68, 68, 0.1);
}

.btn-appoint-choice.choice-clear:hover {
  background: rgba(239, 68, 68, 0.25);
  border-color: #ef4444;
}

.choice-icon {
  font-size: 22px;
  flex-shrink: 0;
}

.choice-text {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.choice-role {
  font-family: 'Cinzel', serif;
  font-size: 13.5px;
  font-weight: 800;
  color: #fff;
}

.choice-desc {
  font-size: 10px;
  color: #94a3b8;
  line-height: 1.3;
}

/* =========================================================
   PHASE 2: A QUESTION OF LOYALTY (MUTINY)
   ========================================================= */

.phase-badge-pill.phase2-pill {
  background: rgba(239, 68, 68, 0.22);
  border-color: rgba(239, 68, 68, 0.55);
}

.phase-dot.phase2-dot {
  background: #ef4444;
  box-shadow: 0 0 6px #ef4444;
}

.phase2-threshold-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  background: rgba(15, 23, 42, 0.65);
  border: 1px dashed rgba(245, 158, 11, 0.35);
  border-radius: 8px;
  padding: 3px 8px;
}

.threshold-label {
  font-size: 9px;
  color: #94a3b8;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.threshold-target {
  font-family: 'Cinzel', serif;
  font-size: 10px;
  font-weight: 800;
  color: #f87171;
}

.phase2-bid-panel {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.bid-crew-section {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.bid-header-prompt {
  font-size: 9.5px;
  font-weight: 700;
  color: #cbd5e1;
}

/* Choices container: Accept Team vs Mutiny */
.bid-choices-container {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.btn-loyalty-choice {
  display: flex;
  align-items: center;
  gap: 7px;
  padding: 4px 8px;
  border-radius: 7px;
  background: rgba(30, 41, 59, 0.6);
  border: 1.5px solid rgba(148, 163, 184, 0.3);
  color: #e2e8f0;
  cursor: pointer;
  text-align: left;
  transition: all 0.15s ease;
}

.btn-loyalty-choice:hover:not(:disabled) {
  background: rgba(59, 130, 246, 0.2);
  border-color: rgba(96, 165, 250, 0.6);
}

.btn-loyalty-choice.selected {
  background: linear-gradient(135deg, rgba(2, 132, 199, 0.4) 0%, rgba(3, 105, 161, 0.6) 100%);
  border-color: #38bdf8;
  box-shadow: 0 0 12px rgba(56, 189, 248, 0.35);
}

.btn-loyalty-choice:disabled {
  opacity: 0.6;
  cursor: not-allowed;
}

.choice-icon {
  font-size: 16px;
  line-height: 1;
}

.choice-labels {
  display: flex;
  flex-direction: column;
  gap: 1px;
}

.choice-main {
  font-size: 10.5px;
  font-weight: 800;
  color: #ffffff;
}

.choice-sub {
  font-size: 8.5px;
  color: #94a3b8;
}

/* Mutiny Card */
.bid-mutiny-card {
  padding: 4px 8px;
  border-radius: 7px;
  background: rgba(30, 41, 59, 0.6);
  border: 1.5px solid rgba(148, 163, 184, 0.3);
  display: flex;
  flex-direction: column;
  gap: 3px;
  transition: all 0.15s ease;
}

.bid-mutiny-card.has-selection {
  border-color: #f87171;
  background: linear-gradient(135deg, rgba(220, 38, 38, 0.25) 0%, rgba(153, 27, 27, 0.35) 100%);
  box-shadow: 0 0 12px rgba(239, 68, 68, 0.3);
}

.mutiny-card-header {
  display: flex;
  align-items: center;
  gap: 6px;
}

.mutiny-guns-hint {
  margin-left: auto;
  font-size: 8.5px;
  color: #fca5a5;
  font-weight: 700;
}

.bid-guns-selector {
  display: flex;
  align-items: center;
  gap: 5px;
}

.btn-gun-choice {
  flex: 1;
  height: 25px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 3px;
  border-radius: 5px;
  border: 1.5px solid rgba(148, 163, 184, 0.3);
  background: rgba(15, 23, 42, 0.7);
  color: #e2e8f0;
  font-size: 10px;
  font-weight: 700;
  cursor: pointer;
  transition: all 0.15s ease;
}

.btn-gun-choice:hover:not(:disabled) {
  border-color: rgba(239, 68, 68, 0.6);
  background: rgba(220, 38, 38, 0.25);
}

.btn-gun-choice.selected {
  border-color: #ef4444;
  background: linear-gradient(135deg, #dc2626 0%, #991b1b 100%);
  color: #fff;
  box-shadow: 0 0 12px rgba(239, 68, 68, 0.5);
}

.btn-gun-choice:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

.no-guns-hint {
  font-size: 9px;
  color: #94a3b8;
  font-style: italic;
  padding: 1px 0;
}

/* Submit & Lock Decision Button */
.bid-submit-row {
  margin-top: 1px;
}

.btn-submit-loyalty {
  width: 100%;
  height: 30px;
  border-radius: 7px;
  font-family: 'Cinzel', serif;
  font-size: 10.5px;
  font-weight: 800;
  cursor: pointer;
  transition: all 0.2s ease;
  display: flex;
  align-items: center;
  justify-content: center;
}

.btn-submit-loyalty.style-peace {
  background: linear-gradient(135deg, #0284c7 0%, #0369a1 100%);
  border: 1px solid #38bdf8;
  color: #ffffff;
  box-shadow: 0 2px 10px rgba(2, 132, 199, 0.4);
}

.btn-submit-loyalty.style-peace:hover:not(:disabled) {
  filter: brightness(1.15);
  box-shadow: 0 4px 14px rgba(2, 132, 199, 0.6);
  transform: translateY(-1px);
}

.btn-submit-loyalty.style-mutiny {
  background: linear-gradient(135deg, #dc2626 0%, #991b1b 100%);
  border: 1px solid #f87171;
  color: #ffffff;
  box-shadow: 0 2px 10px rgba(220, 38, 38, 0.4);
}

.btn-submit-loyalty.style-mutiny:hover:not(:disabled) {
  filter: brightness(1.15);
  box-shadow: 0 4px 14px rgba(220, 38, 38, 0.6);
  transform: translateY(-1px);
}

.btn-submit-loyalty.is-locked,
.btn-submit-loyalty:disabled {
  background: #1e293b !important;
  border-color: #475569 !important;
  color: #94a3b8 !important;
  cursor: not-allowed !important;
  box-shadow: none !important;
  transform: none !important;
  filter: none !important;
}

/* Locked status card */
.bid-locked-status {
  padding: 6px 10px;
  border-radius: 8px;
  background: rgba(15, 23, 42, 0.85);
  border: 1px solid rgba(56, 189, 248, 0.4);
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.locked-status-content {
  display: flex;
  align-items: center;
  gap: 8px;
}

.locked-badge-icon {
  font-size: 16px;
  line-height: 1;
}

.locked-badge-title {
  font-size: 10px;
  font-weight: 800;
  color: #38bdf8;
}

.locked-badge-desc {
  font-size: 9px;
  color: #cbd5e1;
  margin: 0;
}

.crew-progress-tracker {
  font-size: 9.5px;
  font-weight: 700;
  color: #fbbf24;
}

/* Captain Section */
.bid-captain-section {
  display: flex;
  flex-direction: column;
  gap: 5px;
}

.captain-waiting-card {
  padding: 8px 12px;
  border-radius: 8px;
  background: rgba(15, 23, 42, 0.8);
  border: 1.5px solid rgba(245, 158, 11, 0.4);
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.captain-waiting-header {
  display: flex;
  align-items: center;
  gap: 8px;
}

.cap-waiting-icon {
  font-size: 20px;
  line-height: 1;
}

.cap-waiting-title {
  font-family: 'Cinzel', serif;
  font-size: 11px;
  font-weight: 800;
  color: #f59e0b;
  margin: 0;
}

.cap-waiting-desc {
  font-size: 9.5px;
  color: #cbd5e1;
  margin: 0;
}

.crew-progress-box {
  display: flex;
  flex-direction: column;
  gap: 3px;
}

.crew-progress-label {
  display: flex;
  justify-content: space-between;
  font-size: 9.5px;
  color: #e2e8f0;
}

.crew-progress-label strong {
  color: #fbbf24;
}

.crew-progress-track {
  width: 100%;
  height: 6px;
  border-radius: 3px;
  background: rgba(30, 41, 59, 0.8);
  overflow: hidden;
  border: 1px solid rgba(148, 163, 184, 0.2);
}

.crew-progress-fill {
  height: 100%;
  background: linear-gradient(90deg, #f59e0b, #10b981);
  border-radius: 3px;
  transition: width 0.3s ease;
}

.captain-auto-reveal-note {
  font-size: 9px;
  color: #94a3b8;
  font-style: italic;
}

.btn-admin-pass-mutiny {
  width: 100%;
  height: 28px;
  background: rgba(245, 158, 11, 0.2);
  border: 1px dashed #f59e0b;
  color: #fbbf24;
  border-radius: 6px;
  font-family: 'Cinzel', serif;
  font-size: 10px;
  font-weight: 800;
  cursor: pointer;
  transition: all 0.2s ease;
  display: flex;
  align-items: center;
  justify-content: center;
}

.btn-admin-pass-mutiny:hover {
  background: rgba(245, 158, 11, 0.35);
  transform: translateY(-1px);
}

/* =========================================================
   MUTINY RESULTS MODAL
   ========================================================= */

.mutiny-modal {
  position: fixed;
  inset: 0;
  z-index: 100;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 16px;
}

.mutiny-modal-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.82);
  backdrop-filter: blur(10px);
}

.mutiny-modal-card {
  position: relative;
  width: 100%;
  max-width: 350px;
  background: linear-gradient(180deg, #1e293b 0%, #0f172a 100%);
  border: 2px solid rgba(245, 158, 11, 0.5);
  border-radius: 18px;
  padding: 15px 16px;
  box-shadow: 0 16px 45px rgba(0, 0, 0, 0.9), 0 0 24px rgba(245, 158, 11, 0.2);
  display: flex;
  flex-direction: column;
  gap: 9px;
  animation: modalPop 0.22s cubic-bezier(0.16, 1, 0.3, 1);
  max-height: 85vh;
  overflow-y: auto;
}

.mutiny-card-header {
  display: flex;
  align-items: center;
  gap: 10px;
}

.mutiny-header-icon {
  font-size: 24px;
}

.mutiny-header-titles {
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 1px;
}

.mutiny-modal-title {
  font-family: 'Cinzel', serif;
  font-size: 15px;
  font-weight: 800;
  color: var(--gold-bright);
  margin: 0;
}

.mutiny-modal-subtitle {
  font-size: 10.5px;
  color: #94a3b8;
}

.mutiny-close-btn {
  background: rgba(255, 255, 255, 0.1);
  border: 1px solid rgba(255, 255, 255, 0.2);
  color: #fff;
  width: 26px;
  height: 26px;
  border-radius: 50%;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 12px;
}

.mutiny-breakdown-list {
  display: flex;
  flex-direction: column;
  gap: 3px;
  background: rgba(15, 23, 42, 0.7);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 10px;
  padding: 6px 9px;
  max-height: 160px;
  overflow-y: auto;
}

.mutiny-player-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 3px 0;
  border-bottom: 1px solid rgba(255, 255, 255, 0.05);
  font-size: 11px;
}

.mutiny-player-row:last-child {
  border-bottom: none;
}

.mutiny-p-name {
  color: #e2e8f0;
  font-weight: 600;
}

.mutiny-p-guns {
  display: flex;
  align-items: center;
  gap: 2px;
}

.mutiny-verdict-box {
  background: rgba(15, 23, 42, 0.8);
  border-radius: 10px;
  padding: 8px 10px;
  border-left: 4px solid #f59e0b;
}

.mutiny-verdict-box.success {
  border-left-color: #ef4444;
  background: linear-gradient(90deg, rgba(239, 68, 68, 0.15) 0%, rgba(15, 23, 42, 0.8) 100%);
}

.mutiny-verdict-box.failed {
  border-left-color: #3b82f6;
  background: linear-gradient(90deg, rgba(59, 130, 246, 0.15) 0%, rgba(15, 23, 42, 0.8) 100%);
}

.verdict-title {
  font-family: 'Cinzel', serif;
  font-size: 13px;
  font-weight: 800;
  color: #fff;
  margin-bottom: 2px;
}

.verdict-desc {
  font-size: 10.5px;
  color: #cbd5e1;
  line-height: 1.35;
}

.mutiny-tie-box {
  background: linear-gradient(135deg, rgba(245, 158, 11, 0.15) 0%, rgba(239, 68, 68, 0.15) 100%);
  border: 1.5px dashed rgba(245, 158, 11, 0.6);
  border-radius: 12px;
  padding: 10px 12px;
  display: flex;
  flex-direction: column;
  gap: 8px;
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.4);
}

.tie-instruction {
  font-size: 11px;
  color: var(--gold-bright);
  font-weight: 700;
  line-height: 1.35;
}

.tie-candidates-row {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.btn-tie-eliminate {
  padding: 8px 12px;
  border-radius: 8px;
  background: linear-gradient(135deg, rgba(239, 68, 68, 0.3) 0%, rgba(185, 28, 28, 0.4) 100%);
  border: 1px solid rgba(248, 113, 113, 0.6);
  color: #fff;
  font-size: 11px;
  font-weight: 800;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  transition: all 0.15s ease;
}

.btn-tie-eliminate:hover {
  background: linear-gradient(135deg, rgba(239, 68, 68, 0.5) 0%, rgba(185, 28, 28, 0.6) 100%);
  transform: translateY(-1px);
  box-shadow: 0 3px 10px rgba(239, 68, 68, 0.4);
}

.btn-proceed-mutiny {
  width: 100%;
  height: 36px;
  border-radius: 10px;
  background: linear-gradient(135deg, #f59e0b 0%, #d97706 100%);
  color: #020617;
  font-family: 'Cinzel', serif;
  font-size: 11.5px;
  font-weight: 800;
  border: 1px solid rgba(254, 243, 199, 0.7);
  cursor: pointer;
  box-shadow: 0 4px 14px rgba(245, 158, 11, 0.4);
  transition: all 0.15s ease;
}

.btn-proceed-mutiny:hover {
  transform: translateY(-1px);
  box-shadow: 0 6px 18px rgba(245, 158, 11, 0.6);
}

/* Mobile Bottom Navigation Dock Bar */
.mobile-nav-bar {
  height: 52px;
  background: rgba(8, 12, 22, 0.98);
  backdrop-filter: blur(20px);
  border-top: 1px solid var(--border-glass);
  display: flex;
  align-items: center;
  justify-content: space-around;
  padding: 0 6px;
  padding-bottom: var(--safe-bottom);
  z-index: 50;
  flex-shrink: 0;
}

.mobile-nav-item {
  flex: 1;
  background: transparent;
  border: none;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 2px;
  color: var(--text-muted);
  cursor: pointer;
  padding: 5px 0;
  transition: all 0.15s ease;
}

.mobile-nav-item .nav-icon {
  font-size: 16px;
  transition: transform 0.15s ease;
}

.mobile-nav-item .nav-label {
  font-size: 9px;
  font-weight: 700;
  letter-spacing: 0.3px;
}

.mobile-nav-item.active {
  color: var(--gold-bright);
}

.mobile-nav-item.active .nav-icon {
  transform: translateY(-2px);
  filter: drop-shadow(0 0 6px rgba(245, 158, 11, 0.5));
}

/* =========================================================
   6. BOTTOM SHEETS & SECRET DOSSIER MODAL
   ========================================================= */

/* Bottom Sheet Drawer */
.mobile-bottom-sheet {
  position: absolute;
  inset: 0;
  z-index: 150;
  pointer-events: none;
  visibility: hidden;
  transition: visibility 0.25s ease;
}

.mobile-bottom-sheet.active {
  pointer-events: auto;
  visibility: visible;
}

.sheet-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.65);
  backdrop-filter: blur(6px);
  opacity: 0;
  transition: opacity 0.25s ease;
}

.mobile-bottom-sheet.active .sheet-backdrop {
  opacity: 1;
}

.sheet-content {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  background: linear-gradient(180deg, rgba(17, 24, 39, 0.98) 0%, rgba(10, 15, 29, 0.99) 100%);
  border-top: 2px solid rgba(245, 158, 11, 0.5);
  border-radius: 24px 24px 0 0;
  padding: 16px 20px 24px;
  padding-bottom: calc(24px + var(--safe-bottom));
  min-height: 46vh;
  max-height: 82vh;
  display: flex;
  flex-direction: column;
  box-shadow: 0 -12px 48px rgba(0, 0, 0, 0.85);
  transform: translateY(100%);
  transition: transform 0.28s cubic-bezier(0.16, 1, 0.3, 1);
}

.mobile-bottom-sheet.active .sheet-content {
  transform: translateY(0);
}

.sheet-handle-bar {
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
  margin-bottom: 14px;
}

.sheet-handle {
  width: 44px;
  height: 5px;
  border-radius: 5px;
  background: rgba(255, 255, 255, 0.35);
}

.sheet-close-btn {
  position: absolute;
  right: 0;
  top: -6px;
  background: rgba(255, 255, 255, 0.12);
  border: 1px solid rgba(255, 255, 255, 0.25);
  color: #fff;
  width: 32px;
  height: 32px;
  font-size: 15px;
  border-radius: 50%;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background 0.15s ease;
}

.sheet-close-btn:hover, .sheet-close-btn:active {
  background: rgba(239, 68, 68, 0.4);
}

.sheet-title {
  font-family: 'Cinzel', serif;
  font-size: 19px;
  font-weight: 700;
  color: var(--gold-bright);
  margin-bottom: 14px;
  letter-spacing: 0.5px;
}

.sheet-body {
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
  max-height: 65vh;
  padding-right: 2px;
}

/* Mobile Secret Dossier Modal */
.mobile-dossier-modal {
  position: absolute;
  inset: 0;
  z-index: 160;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 14px;
  pointer-events: none;
  visibility: hidden;
  opacity: 0;
  transition: opacity 0.25s ease, visibility 0.25s ease;
}

.mobile-dossier-modal.active {
  pointer-events: auto;
  visibility: visible;
  opacity: 1;
}

.dossier-modal-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(3, 7, 18, 0.88);
  backdrop-filter: blur(12px);
}

.dossier-modal-card {
  position: relative;
  width: 100%;
  max-width: 350px;
  background: linear-gradient(135deg, rgba(30, 27, 20, 0.96), rgba(15, 23, 42, 0.98));
  border: 1.5px solid rgba(245, 158, 11, 0.4);
  border-radius: 18px;
  padding: 16px;
  box-shadow: 0 20px 50px rgba(0, 0, 0, 0.9), 0 0 30px rgba(245, 158, 11, 0.2);
}

.dossier-modal-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 12px;
}

.dossier-modal-title {
  font-family: 'Cinzel', serif;
  font-size: 15px;
  font-weight: 800;
  color: var(--gold-bright);
}

.dossier-modal-close {
  background: rgba(255, 255, 255, 0.1);
  border: 1px solid rgba(255, 255, 255, 0.2);
  color: #fff;
  width: 26px;
  height: 26px;
  border-radius: 50%;
  cursor: pointer;
}

.mobile-dossier-shield {
  text-align: center;
  padding: 16px 8px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
}

.shield-lock-icon {
  font-size: 34px;
  filter: drop-shadow(0 0 8px rgba(245, 158, 11, 0.4));
}

.shield-title {
  font-size: 15px;
  font-weight: 800;
  color: #f1f5f9;
}

.shield-desc {
  font-size: 11px;
  color: var(--text-secondary);
  line-height: 1.4;
  margin-bottom: 6px;
}

/* =========================================================
   7. LANDING SCREEN & WAITING ROOM MODALS
   ========================================================= */

.landing-screen, .waiting-screen {
  position: absolute;
  inset: 0;
  z-index: 120;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 10px;
  opacity: 0;
  pointer-events: none;
  visibility: hidden;
  transition: opacity 0.3s ease, visibility 0.3s ease;
}

.landing-screen.active, .waiting-screen.active {
  opacity: 1;
  pointer-events: auto;
  visibility: visible;
}

.landing-backdrop {
  position: absolute;
  inset: 0;
  background: radial-gradient(circle at center, rgba(15, 23, 42, 0.94) 0%, rgba(3, 7, 18, 0.98) 100%);
  backdrop-filter: blur(16px);
}

.landing-card, .waiting-card {
  position: relative;
  width: 100%;
  max-width: 440px;
  max-height: 90%;
  overflow-y: auto;
  overflow-x: hidden;
  -webkit-overflow-scrolling: touch;
  background: rgba(13, 23, 42, 0.95);
  border: 1.5px solid rgba(251, 191, 36, 0.35);
  box-shadow: 0 25px 60px -15px rgba(0, 0, 0, 0.8), 0 0 30px rgba(245, 158, 11, 0.15);
  border-radius: 18px;
  padding: 18px 16px;
  display: flex;
  flex-direction: column;
  gap: 14px;
  box-sizing: border-box;
}

.landing-brand, .waiting-brand {
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 3px;
}

.landing-icon {
  font-size: 34px;
  filter: drop-shadow(0 0 12px rgba(234, 179, 8, 0.5));
}

.landing-title {
  font-family: 'Cinzel', serif;
  font-size: 20px;
  font-weight: 900;
  letter-spacing: 1.5px;
  background: linear-gradient(135deg, #fef08a 0%, #f59e0b 50%, #d97706 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

.landing-subtitle {
  font-size: 11px;
  color: var(--text-secondary);
}

/* Landing Tabs */
.landing-tabs {
  display: flex;
  background: rgba(15, 23, 42, 0.7);
  border: 1px solid rgba(255, 255, 255, 0.1);
  padding: 3px;
  border-radius: 12px;
  gap: 4px;
}

.landing-tab {
  flex: 1;
  background: transparent;
  border: none;
  color: var(--text-secondary);
  font-family: 'Outfit', sans-serif;
  font-size: 13px;
  font-weight: 600;
  padding: 8px 10px;
  border-radius: 9px;
  cursor: pointer;
  transition: all 0.15s ease;
}

.landing-tab.active {
  background: linear-gradient(135deg, rgba(245, 158, 11, 0.25), rgba(217, 119, 6, 0.25));
  color: var(--gold-bright);
  border: 1px solid rgba(245, 158, 11, 0.4);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
}

/* Room Setup Fields */
.room-setup-box {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.setup-field {
  display: flex;
  flex-direction: column;
  gap: 5px;
}

.setup-label-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.setup-label {
  font-size: 10.5px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.8px;
  color: var(--gold-bright);
}

.player-count-pill {
  background: rgba(245, 158, 11, 0.15);
  border: 1px solid rgba(245, 158, 11, 0.35);
  color: var(--gold-bright);
  font-size: 10px;
  font-weight: 800;
  padding: 2px 7px;
  border-radius: 10px;
}

.room-code-input-wrapper {
  display: flex;
  gap: 6px;
}

.room-code-input {
  flex: 1;
  background: rgba(15, 23, 42, 0.8);
  border: 1.5px solid rgba(255, 255, 255, 0.15);
  border-radius: 10px;
  color: #fff;
  font-family: 'Outfit', sans-serif;
  font-size: 14px;
  font-weight: 700;
  padding: 9px 12px;
  outline: none;
}

.room-code-input:focus {
  border-color: var(--gold-bright);
  box-shadow: 0 0 12px rgba(245, 158, 11, 0.25);
}

.btn-dice {
  width: 40px;
  background: rgba(245, 158, 11, 0.15);
  border: 1px solid rgba(245, 158, 11, 0.35);
  border-radius: 10px;
  color: var(--gold-bright);
  font-size: 16px;
  cursor: pointer;
}

/* Player Selector Chips */
.player-selector-grid {
  display: flex;
  gap: 4px;
  overflow-x: auto;
  padding-bottom: 2px;
}

.player-btn {
  flex: 1;
  min-width: 36px;
  height: 36px;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.15);
  border-radius: 8px;
  color: #e2e8f0;
  font-family: 'Outfit', sans-serif;
  font-size: 13px;
  font-weight: 700;
  cursor: pointer;
}

.player-btn.active {
  background: linear-gradient(135deg, #f59e0b, #d97706);
  border-color: #fbbf24;
  color: #0f172a;
  font-weight: 900;
  box-shadow: 0 0 12px rgba(245, 158, 11, 0.4);
}

/* Distribution Preview Card */
.journey-hint-pill {
  font-size: 9px;
  font-weight: 700;
  padding: 2px 6px;
  border-radius: 6px;
  background: rgba(255, 255, 255, 0.08);
  color: #94a3b8;
}

.journey-mode-selector {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  gap: 6px;
  margin-top: 4px;
  width: 100%;
  box-sizing: border-box;
}

.journey-btn {
  background: rgba(15, 23, 42, 0.75);
  border: 1.5px solid rgba(255, 255, 255, 0.12);
  border-radius: 10px;
  padding: 7px 8px;
  display: flex;
  align-items: center;
  gap: 6px;
  cursor: pointer;
  transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1);
  text-align: left;
  min-width: 0;
  width: 100%;
  box-sizing: border-box;
}

.journey-btn:hover:not(.disabled) {
  border-color: rgba(251, 191, 36, 0.5);
  background: rgba(30, 41, 59, 0.85);
  transform: translateY(-1px);
}

.journey-btn.active {
  border-color: #fbbf24;
  background: linear-gradient(135deg, rgba(217, 119, 6, 0.25), rgba(15, 23, 42, 0.9));
  box-shadow: 0 0 14px rgba(251, 191, 36, 0.3);
}

.journey-btn.disabled {
  opacity: 0.38;
  cursor: not-allowed;
  filter: grayscale(0.8);
}

.journey-btn-icon {
  font-size: 16px;
  flex-shrink: 0;
}

.journey-btn-info {
  display: flex;
  flex-direction: column;
  gap: 1px;
  min-width: 0;
  flex: 1;
  overflow: hidden;
}

.journey-btn-title {
  font-family: 'Cinzel', serif;
  font-size: 10.5px;
  font-weight: 800;
  color: #f1f5f9;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.journey-btn.active .journey-btn-title {
  color: #fde047;
}

.journey-btn-sub {
  font-size: 8px;
  color: #94a3b8;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

@media (max-width: 380px) {
  .journey-mode-selector {
    gap: 4px;
  }
  .journey-btn {
    padding: 6px 5px;
    gap: 4px;
  }
  .journey-btn-icon {
    font-size: 14px;
  }
  .journey-btn-title {
    font-size: 9px;
  }
  .journey-btn-sub {
    font-size: 7.5px;
  }
}

.room-pill-journey {
  font-size: 9.5px;
  font-weight: 800;
  padding: 2px 7px;
  border-radius: 6px;
  background: rgba(56, 189, 248, 0.15);
  border: 1px solid rgba(56, 189, 248, 0.35);
  color: #38bdf8;
}

.room-pill-journey.quick {
  background: rgba(56, 189, 248, 0.2);
  border-color: rgba(56, 189, 248, 0.5);
  color: #38bdf8;
}

.room-pill-journey.long {
  background: rgba(234, 179, 8, 0.2);
  border-color: rgba(234, 179, 8, 0.5);
  color: #facc15;
}

.distribution-card {
  background: rgba(15, 23, 42, 0.6);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 12px;
  padding: 10px;
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.distrib-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.journey-badge {
  font-size: 9.5px;
  font-weight: 800;
  padding: 2px 7px;
  border-radius: 8px;
}

.journey-quick {
  background: rgba(56, 189, 248, 0.15);
  border: 1px solid rgba(56, 189, 248, 0.35);
  color: #38bdf8;
}

.journey-long {
  background: rgba(234, 179, 8, 0.15);
  border: 1px solid rgba(234, 179, 8, 0.35);
  color: #facc15;
}

.cultist-note {
  font-size: 9.5px;
  color: var(--text-muted);
}

.role-pills-row {
  display: flex;
  gap: 5px;
}

.role-pill {
  flex: 1;
  display: flex;
  align-items: center;
  gap: 3px;
  padding: 4px 6px;
  border-radius: 6px;
}

.pill-sailor { background: rgba(59, 130, 246, 0.15); border: 1px solid rgba(59, 130, 246, 0.35); color: #60a5fa; }
.pill-pirate { background: rgba(239, 68, 68, 0.15); border: 1px solid rgba(239, 68, 68, 0.35); color: #f87171; }
.pill-cult { background: rgba(234, 179, 8, 0.15); border: 1px solid rgba(234, 179, 8, 0.35); color: #facc15; }
.pill-cultist { background: rgba(168, 85, 247, 0.15); border: 1px solid rgba(168, 85, 247, 0.35); color: #c084fc; }

.role-pill-count {
  font-size: 11px;
  font-weight: 800;
}

.role-pill-name {
  font-size: 9px;
  font-weight: 600;
}

.distrib-notes {
  font-size: 9.5px;
  color: var(--text-muted);
  line-height: 1.3;
}

/* Embark Button */
.btn-embark {
  background: linear-gradient(135deg, #f59e0b 0%, #d97706 100%);
  border: 1.5px solid #fbbf24;
  color: #0f172a;
  font-family: 'Cinzel', serif;
  font-size: 14px;
  font-weight: 900;
  letter-spacing: 1px;
  padding: 11px;
  border-radius: 10px;
  cursor: pointer;
  box-shadow: 0 6px 18px rgba(245, 158, 11, 0.35);
  width: 100%;
}

.btn-embark.disabled, .btn-embark:disabled {
  opacity: 0.5;
  cursor: not-allowed;
  filter: grayscale(0.5);
  box-shadow: none;
}

.btn-secondary {
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.15);
  color: #e2e8f0;
  font-size: 12px;
  font-weight: 700;
  padding: 9px 14px;
  border-radius: 10px;
  cursor: pointer;
}

/* Waiting Room Slots Grid */
.slots-container {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.slots-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 11px;
  font-weight: 800;
  color: var(--gold-bright);
}

.player-slots-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 6px;
  max-height: 220px;
  overflow-y: auto;
}

.slot-card {
  background: rgba(15, 23, 42, 0.7);
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 10px;
  padding: 6px 8px;
  display: flex;
  align-items: center;
  gap: 6px;
}

.slot-card.filled {
  border-color: rgba(56, 189, 248, 0.3);
}

.slot-card.is-host {
  border-color: rgba(245, 158, 11, 0.5);
  background: linear-gradient(135deg, rgba(245, 158, 11, 0.12), rgba(15, 23, 42, 0.8));
}

.slot-card.empty {
  opacity: 0.65;
  border-style: dashed;
  cursor: pointer;
  transition: all 0.2s ease;
}

.slot-card.empty:hover, .slot-card.empty:active {
  opacity: 1;
  border-color: var(--gold-bright);
  background: rgba(245, 158, 11, 0.12);
  transform: translateY(-1px);
}

.slot-avatar {
  font-size: 18px;
}

.slot-info {
  display: flex;
  flex-direction: column;
  overflow: hidden;
}

.slot-name {
  font-size: 11px;
  font-weight: 700;
  color: #f8fafc;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.slot-role-tag {
  font-size: 8.5px;
  color: var(--text-muted);
}

.btn-slot-remove {
  background: rgba(239, 68, 68, 0.2);
  border: 1px solid rgba(239, 68, 68, 0.4);
  color: #fca5a5;
  width: 20px;
  height: 20px;
  border-radius: 5px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 10px;
  cursor: pointer;
  margin-left: auto;
}

.waiting-actions-bar {
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin-top: 8px;
  border-top: 1px solid rgba(255, 255, 255, 0.08);
  padding-top: 8px;
}

.test-helpers {
  display: flex;
  gap: 6px;
  width: 100%;
}

.btn-outline {
  flex: 1;
  background: rgba(245, 158, 11, 0.12);
  border: 1px solid rgba(245, 158, 11, 0.4);
  color: var(--gold-bright);
  font-size: 11px;
  font-weight: 700;
  padding: 8px 10px;
  border-radius: 8px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 4px;
  transition: all 0.15s ease;
}

.btn-outline:hover, .btn-outline:active {
  background: rgba(245, 158, 11, 0.25);
  border-color: var(--gold-bright);
  color: #fff;
  transform: translateY(-1px);
}

.main-lobby-buttons {
  display: flex;
  gap: 6px;
  width: 100%;
}

.btn-copy {
  background: rgba(245, 158, 11, 0.15);
  border: 1px solid rgba(245, 158, 11, 0.4);
  color: var(--gold-bright);
  font-size: 9.5px;
  font-weight: 700;
  padding: 2px 6px;
  border-radius: 6px;
  cursor: pointer;
}

.waiting-warning-box {
  display: flex;
  gap: 6px;
  background: rgba(245, 158, 11, 0.1);
  border: 1px solid rgba(245, 158, 11, 0.3);
  padding: 7px 10px;
  border-radius: 8px;
}

.warning-icon { font-size: 14px; }
.warning-title { font-size: 10.5px; font-weight: 800; color: var(--gold-bright); }
.warning-text { font-size: 9.5px; color: #e2e8f0; }

.join-info-box {
  display: flex;
  gap: 6px;
  background: rgba(56, 189, 248, 0.1);
  border: 1px solid rgba(56, 189, 248, 0.3);
  padding: 7px 10px;
  border-radius: 8px;
  font-size: 10.5px;
  color: #bae6fd;
}

/* =========================================================
   8. DOSSIER & LOCATION CARDS
   ========================================================= */

.location-card {
  background: rgba(15, 23, 42, 0.7);
  border-radius: 14px;
  padding: 16px 18px;
  border: 1px solid rgba(245, 158, 11, 0.25);
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.35);
}

.location-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 12px;
  margin-bottom: 8px;
}

.location-name {
  font-family: 'Cinzel', serif;
  font-size: 22px;
  font-weight: 800;
  color: #fff;
  letter-spacing: 0.5px;
  line-height: 1.25;
}

.location-sub {
  font-size: 13px;
  color: #94a3b8;
  font-weight: 500;
  margin-top: 3px;
}

.location-badges {
  display: flex;
  align-items: center;
  gap: 6px;
  flex-shrink: 0;
  flex-wrap: wrap;
  justify-content: flex-end;
}

.zone-badge {
  padding: 4px 10px;
  border-radius: 8px;
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0.5px;
  text-transform: uppercase;
}

.zone-calm { background: rgba(56, 189, 248, 0.18); color: #38bdf8; border: 1px solid rgba(56, 189, 248, 0.4); }
.zone-wild { background: rgba(99, 102, 241, 0.22); color: #a5b4fc; border: 1px solid rgba(99, 102, 241, 0.5); }
.zone-pirate { background: rgba(239, 68, 68, 0.18); color: #ef4444; border: 1px solid rgba(239, 68, 68, 0.4); }
.zone-sailor { background: rgba(59, 130, 246, 0.18); color: #60a5fa; border: 1px solid rgba(59, 130, 246, 0.4); }
.zone-cult { background: rgba(234, 179, 8, 0.18); color: #facc15; border: 1px solid rgba(234, 179, 8, 0.4); }

.action-box {
  margin-top: 14px;
  background: rgba(0, 0, 0, 0.5);
  border-radius: 12px;
  padding: 16px 18px;
  border-left: 4px solid var(--gold-bright);
  border-top: 1px solid rgba(255, 255, 255, 0.06);
}

.action-card-header {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 8px;
}

.action-badge {
  font-size: 11px;
  font-weight: 800;
  padding: 4px 10px;
  border-radius: 6px;
  background: rgba(245, 158, 11, 0.2);
  color: var(--gold-bright);
  display: inline-block;
  letter-spacing: 0.5px;
}

.action-badge.badge-calm {
  background: rgba(56, 189, 248, 0.22);
  color: #38bdf8;
  border: 1px solid rgba(56, 189, 248, 0.5);
}

.action-badge.badge-wild {
  background: rgba(99, 102, 241, 0.22);
  color: #a5b4fc;
  border: 1px solid rgba(99, 102, 241, 0.5);
}

.action-badge.badge-search {
  background: rgba(56, 189, 248, 0.22);
  color: #38bdf8;
  border: 1px solid rgba(56, 189, 248, 0.5);
}

.action-badge.badge-neutral {
  background: rgba(148, 163, 184, 0.18);
  color: #cbd5e1;
  border: 1px solid rgba(148, 163, 184, 0.35);
}

.action-badge.badge-sailor {
  background: rgba(59, 130, 246, 0.22);
  color: #60a5fa;
  border: 1px solid rgba(59, 130, 246, 0.5);
}

.action-badge.badge-pirate {
  background: rgba(239, 68, 68, 0.22);
  color: #f87171;
  border: 1px solid rgba(239, 68, 68, 0.5);
}

.action-badge.badge-cult {
  background: rgba(234, 179, 8, 0.22);
  color: #facc15;
  border: 1px solid rgba(234, 179, 8, 0.5);
}

.action-title {
  display: none; /* Removed duplicate title per user request */
}

.action-details {
  font-size: 16px;
  font-weight: 500;
  color: #f8fafc;
  line-height: 1.6;
  margin: 0 0 10px 0;
}

.action-flavor {
  font-size: 13px;
  color: #94a3b8;
  line-height: 1.45;
  font-style: italic;
  margin: 0;
  padding-top: 8px;
  border-top: 1px dashed rgba(255, 255, 255, 0.12);
}

.dossier-card {
  padding: 10px;
  border-radius: 10px;
  display: flex;
  flex-direction: column;
  gap: 4px;
  margin-bottom: 8px;
}

.dossier-card.faction-blue {
  background: rgba(59, 130, 246, 0.15);
  border: 1px solid rgba(59, 130, 246, 0.4);
}

.dossier-card.faction-red {
  background: rgba(239, 68, 68, 0.15);
  border: 1px solid rgba(239, 68, 68, 0.4);
}

.dossier-card.faction-yellow {
  background: rgba(234, 179, 8, 0.15);
  border: 1px solid rgba(234, 179, 8, 0.4);
}

.dossier-card-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.dossier-card-name {
  font-size: 12px;
  font-weight: 800;
  display: flex;
  align-items: center;
  gap: 5px;
}

.faction-blue .dossier-card-name { color: #60a5fa; }
.faction-red .dossier-card-name { color: #f87171; }
.faction-yellow .dossier-card-name { color: #fde047; }

.dossier-card-trigger {
  font-size: 8.5px;
  font-weight: 800;
  text-transform: uppercase;
  padding: 2px 5px;
  border-radius: 5px;
  background: rgba(255, 255, 255, 0.1);
  color: #cbd5e1;
}

.dossier-card-desc {
  font-size: 10.5px;
  line-height: 1.35;
  color: #e2e8f0;
}

.dossier-captain-badge {
  background: linear-gradient(90deg, rgba(245, 158, 11, 0.25), rgba(245, 158, 11, 0.08));
  border: 1px solid rgba(245, 158, 11, 0.5);
  color: #fef08a;
  font-size: 10.5px;
  font-weight: 800;
  padding: 5px 8px;
  border-radius: 8px;
  display: flex;
  align-items: center;
  gap: 5px;
  margin-bottom: 8px;
}

/* History log */
.history-list {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.history-item {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 6px 8px;
  background: rgba(15, 23, 42, 0.6);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 6px;
  font-size: 11px;
}

.history-item.current-step {
  border-color: var(--gold-bright);
  background: rgba(245, 158, 11, 0.1);
}

.step-num {
  font-size: 10px;
  font-weight: 700;
  color: var(--text-muted);
}

.step-dir {
  font-weight: 700;
  font-size: 10px;
}

.step-name {
  color: #fff;
  font-weight: 600;
}

/* Free Move Switch */
.switch {
  position: relative;
  display: inline-block;
  width: 38px;
  height: 22px;
}

.switch input { opacity: 0; width: 0; height: 0; }

.slider {
  position: absolute;
  cursor: pointer;
  inset: 0;
  background-color: rgba(255, 255, 255, 0.15);
  border-radius: 22px;
  transition: 0.2s;
}

.slider:before {
  position: absolute;
  content: "";
  height: 16px;
  width: 16px;
  left: 3px;
  bottom: 3px;
  background-color: white;
  border-radius: 50%;
  transition: 0.2s;
}

input:checked + .slider { background-color: var(--gold-bright); }
input:checked + .slider:before { transform: translateX(16px); }

/* Status Toast */
/* Status Toast - Upper area below header, 2-line wrapped, clean mobile boundaries */
.status-toast {
  position: absolute;
  top: 56px;
  bottom: auto;
  left: 50%;
  transform: translateX(-50%) translateY(-12px);
  background: rgba(15, 23, 42, 0.96);
  border: 1.5px solid var(--gold-bright);
  color: #fff;
  font-size: 11px;
  font-weight: 700;
  line-height: 1.4;
  text-align: center;
  white-space: normal;
  word-break: normal;
  overflow-wrap: break-word;
  padding: 8px 16px;
  border-radius: 12px;
  box-shadow: 0 10px 28px rgba(0, 0, 0, 0.75), 0 0 10px rgba(0, 0, 0, 0.5);
  z-index: 1000;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.25s cubic-bezier(0.16, 1, 0.3, 1), transform 0.25s cubic-bezier(0.16, 1, 0.3, 1);
  width: max-content;
  max-width: calc(100% - 32px);
  box-sizing: border-box;
}

.status-toast.show {
  opacity: 1;
  transform: translateX(-50%) translateY(0);
}

.status-toast.info {
  border-color: var(--color-sailor);
  box-shadow: 0 10px 28px rgba(0, 0, 0, 0.75), 0 0 12px rgba(56, 189, 248, 0.3);
}

.status-toast.warning {
  border-color: var(--color-pirate);
  box-shadow: 0 10px 28px rgba(0, 0, 0, 0.75), 0 0 12px rgba(239, 68, 68, 0.35);
}

.status-toast.success {
  border-color: var(--gold-bright);
  box-shadow: 0 10px 28px rgba(0, 0, 0, 0.75), 0 0 12px rgba(245, 158, 11, 0.35);
}

/* Victory Banner */
.victory-overlay {
  position: absolute;
  inset: 0;
  z-index: 80;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 16px;
  background: rgba(3, 7, 18, 0.88);
  backdrop-filter: blur(12px);
  opacity: 0;
  pointer-events: none;
  visibility: hidden;
  transition: all 0.3s ease;
}

.victory-overlay.active {
  opacity: 1;
  pointer-events: auto;
  visibility: visible;
}

.victory-content {
  background: rgba(15, 23, 42, 0.95);
  border: 2px solid var(--gold-bright);
  border-radius: 18px;
  padding: 20px;
  text-align: center;
  max-width: 320px;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.9), 0 0 40px rgba(245, 158, 11, 0.3);
}

.victory-icon {
  font-size: 40px;
  margin-bottom: 6px;
}

.victory-title {
  font-family: 'Cinzel', serif;
  font-size: 20px;
  font-weight: 900;
  color: var(--gold-bright);
  margin-bottom: 4px;
}

/* =========================================================
   9. DESKTOP FULLSCREEN MODE (Widescreen >= 1024px)
   ========================================================= */

@media (min-width: 1024px) {
  body.sim-inactive .app-header {
    height: 56px;
    padding: 0 20px;
  }

  body.sim-inactive .brand-title {
    font-size: 18px;
  }

  body.sim-inactive .brand-subtitle {
    display: inline;
    font-size: 11px;
    color: var(--text-muted);
    margin-left: 6px;
  }

  body.sim-inactive .btn-header-room,
  body.sim-inactive .btn-header-reset {
    display: inline-flex;
  }

  body.sim-inactive .app-container {
    flex: 1;
    min-height: 0;
    height: auto;
  }

  body.sim-inactive .sidebar-panel {
    display: flex !important;
    width: 380px;
    background: var(--bg-surface);
    backdrop-filter: blur(20px);
    border-left: 1px solid var(--border-glass);
    flex-direction: column;
    z-index: 40;
    overflow-y: auto;
    padding: 16px;
    gap: 14px;
  }

  body.sim-inactive .mobile-sailing-bar,
  body.sim-inactive .mobile-nav-bar,
  body.sim-inactive .mobile-location-pill {
    display: none !important;
  }

  /* Desktop sidebar directional buttons */
  body.sim-inactive .sailing-section {
    display: flex;
    flex-direction: column;
    gap: 8px;
  }

  body.sim-inactive .sailing-grid {
    display: flex;
    flex-direction: column;
    gap: 6px;
  }

  body.sim-inactive .sail-card-btn {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 10px 12px;
    border-radius: 10px;
    border: 1px solid transparent;
    cursor: pointer;
    background: rgba(15, 23, 42, 0.7);
    color: #fff;
    transition: all 0.15s ease;
  }

  body.sim-inactive .btn-sail-red {
    border-color: rgba(239, 68, 68, 0.4);
    background: linear-gradient(135deg, rgba(239, 68, 68, 0.15), rgba(15, 23, 42, 0.8));
  }

  body.sim-inactive .btn-sail-yellow {
    border-color: rgba(234, 179, 8, 0.4);
    background: linear-gradient(135deg, rgba(234, 179, 8, 0.15), rgba(15, 23, 42, 0.8));
  }

  body.sim-inactive .btn-sail-blue {
    border-color: rgba(59, 130, 246, 0.4);
    background: linear-gradient(135deg, rgba(59, 130, 246, 0.15), rgba(15, 23, 42, 0.8));
  }

  body.sim-inactive .sail-btn-info {
    display: flex;
    align-items: center;
    gap: 8px;
  }

  body.sim-inactive .sail-btn-name {
    font-size: 12px;
    font-weight: 800;
  }

  body.sim-inactive .sail-btn-sub {
    font-size: 10px;
    color: var(--text-muted);
  }

  body.sim-inactive .sail-btn-key {
    font-size: 10px;
    color: var(--text-muted);
    background: rgba(255, 255, 255, 0.08);
    padding: 2px 6px;
    border-radius: 4px;
  }
}

/* =========================================================
   PHASE 3: NAVIGATION DECK & DRAW PILE STYLES
   ========================================================= */

.phase3-deck-strip {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  background: rgba(15, 23, 42, 0.85);
  border: 1px solid rgba(148, 163, 184, 0.25);
  border-radius: 10px;
  padding: 6px 10px;
  margin-top: 5px;
}

.deck-pile-slot {
  display: flex;
  align-items: center;
  cursor: pointer;
  user-select: none;
}

.deck-card-mini {
  width: 48px;
  height: 52px;
  border-radius: 8px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 1px;
  border: 1.5px solid rgba(245, 158, 11, 0.6);
  background: linear-gradient(135deg, #1e293b 0%, #0f172a 100%);
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.6);
  transition: all 0.15s ease;
}

.deck-card-mini:hover {
  transform: translateY(-1px);
}

.deck-card-mini.draw-pile {
  border-color: rgba(245, 158, 11, 0.7);
  background: linear-gradient(135deg, rgba(245, 158, 11, 0.22) 0%, rgba(15, 23, 42, 0.95) 100%);
}

.deck-card-mini.discard-pile {
  border-color: rgba(56, 189, 248, 0.55);
  background: linear-gradient(135deg, rgba(56, 189, 248, 0.18) 0%, rgba(15, 23, 42, 0.95) 100%);
}

.deck-mini-icon {
  font-size: 14px;
}

.deck-mini-label {
  font-size: 7.5px;
  font-weight: 800;
  letter-spacing: 0.5px;
  color: #94a3b8;
}

.deck-mini-count {
  font-size: 12px;
  font-weight: 900;
  color: var(--gold-bright);
}

.phase3-team-flow-pill {
  display: flex;
  align-items: center;
  gap: 4px;
  background: rgba(30, 41, 59, 0.7);
  padding: 4px 8px;
  border-radius: 8px;
  border: 1px solid rgba(148, 163, 184, 0.2);
}

.flow-officer {
  font-size: 9.5px;
  font-weight: 700;
  color: #e2e8f0;
  white-space: nowrap;
}

.flow-arrow {
  font-size: 9px;
  color: var(--gold-bright);
}

.btn-deck-overview {
  margin-left: auto;
  flex-shrink: 0;
  white-space: nowrap;
  padding: 2px 8px;
  height: 24px;
  border-radius: 12px;
  background: rgba(56, 189, 248, 0.18);
  border: 1px solid rgba(56, 189, 248, 0.55);
  color: #7dd3fc;
  font-size: 9.5px;
  font-weight: 700;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 4px;
  transition: all 0.2s ease;
  user-select: none;
}

.btn-deck-overview span,
.btn-deck-overview strong {
  white-space: nowrap;
}

.btn-deck-overview .btn-deck-item {
  display: inline-flex;
  align-items: center;
  gap: 2px;
  white-space: nowrap;
}

.btn-deck-overview .btn-deck-divider {
  opacity: 0.45;
  margin: 0 1px;
}

.btn-deck-overview:hover {
  background: rgba(56, 189, 248, 0.3);
  transform: translateY(-1px);
}

/* Navigation Deck Overview Modal */
.deck-modal {
  position: fixed;
  inset: 0;
  z-index: 950;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 12px;
}

.deck-modal-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(3, 7, 18, 0.85);
  backdrop-filter: blur(8px);
}

.deck-modal-card {
  position: relative;
  width: 100%;
  max-width: 440px;
  max-height: 85vh;
  background: linear-gradient(135deg, #111827 0%, #0b0f19 100%);
  border: 1px solid var(--gold-bright);
  border-radius: 14px;
  padding: 12px;
  display: flex;
  flex-direction: column;
  gap: 10px;
  box-shadow: 0 16px 40px rgba(0, 0, 0, 0.8), 0 0 20px rgba(245, 158, 11, 0.2);
  animation: modalPop 0.25s cubic-bezier(0.16, 1, 0.3, 1);
}

.deck-modal-header {
  display: flex;
  align-items: center;
  gap: 8px;
  border-bottom: 1px solid rgba(245, 158, 11, 0.3);
  padding-bottom: 8px;
}

.deck-header-icon {
  font-size: 22px;
}

.deck-modal-title {
  font-family: 'Cinzel', serif;
  font-size: 13px;
  font-weight: 800;
  color: var(--gold-bright);
  margin: 0;
}

.deck-modal-subtitle {
  font-size: 10px;
  color: #94a3b8;
}

.deck-close-btn {
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.15);
  color: #cbd5e1;
  width: 26px;
  height: 26px;
  border-radius: 50%;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 12px;
}

.btn-modal-peek {
  background: rgba(56, 189, 248, 0.15);
  border: 1px solid rgba(56, 189, 248, 0.4);
  color: #38bdf8;
  font-size: 10px;
  font-weight: 800;
  padding: 3px 8px;
  border-radius: 6px;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 4px;
  margin-left: auto;
  margin-right: 4px;
  transition: all 0.15s;
  white-space: nowrap;
}

.btn-modal-peek:hover {
  background: rgba(56, 189, 248, 0.3);
  border-color: #38bdf8;
  color: #ffffff;
  box-shadow: 0 0 8px rgba(56, 189, 248, 0.4);
}

.deck-modal.is-minimized,
.appointment-modal.is-minimized,
.mutiny-modal.is-minimized {
  pointer-events: none !important;
  background: transparent !important;
  padding: 0 !important;
}

.deck-modal.is-minimized .deck-modal-backdrop,
.appointment-modal.is-minimized .appointment-modal-backdrop,
.mutiny-modal.is-minimized .mutiny-modal-backdrop {
  display: none !important;
}

.deck-modal.is-minimized .deck-modal-card,
.appointment-modal.is-minimized .appointment-modal-card,
.mutiny-modal.is-minimized .mutiny-modal-card {
  display: none !important;
}

/* FLOATING MINIMIZED ACTION DOCK */
.minimized-action-dock {
  position: fixed;
  bottom: 74px;
  left: 50%;
  transform: translateX(-50%);
  width: calc(100% - 24px);
  max-width: 480px;
  z-index: 1050;
  background: linear-gradient(135deg, rgba(15, 23, 42, 0.96) 0%, rgba(3, 7, 18, 0.98) 100%);
  border: 1.5px solid #fbbf24;
  border-radius: 12px;
  padding: 8px 12px;
  box-shadow: 0 12px 32px rgba(0, 0, 0, 0.85), 0 0 18px rgba(251, 191, 36, 0.35);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  backdrop-filter: blur(10px);
  animation: slideUpFade 0.22s cubic-bezier(0.16, 1, 0.3, 1);
  cursor: pointer;
}

.dock-content-wrap {
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
  gap: 10px;
}

.dock-left-group {
  display: flex;
  align-items: center;
  gap: 10px;
  min-width: 0;
  flex: 1;
}

.dock-pulse-icon {
  font-size: 22px;
  display: flex;
  align-items: center;
  justify-content: center;
  animation: pulseBeacon 1.8s infinite ease-in-out;
}

@keyframes pulseBeacon {
  0%, 100% { transform: scale(1); filter: drop-shadow(0 0 2px #facc15); }
  50% { transform: scale(1.18); filter: drop-shadow(0 0 8px #facc15); }
}

.dock-info-col {
  display: flex;
  flex-direction: column;
  gap: 2px;
  min-width: 0;
}

.dock-action-title {
  font-family: 'Cinzel', serif;
  font-size: 11.5px;
  font-weight: 800;
  color: #fbbf24;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.dock-boat-info {
  font-size: 10px;
  color: #cbd5e1;
  display: flex;
  align-items: center;
  gap: 6px;
  flex-wrap: wrap;
}

.dock-boat-loc strong {
  color: #38bdf8;
}

.dock-boat-routes {
  display: inline-flex;
  gap: 5px;
  flex-wrap: wrap;
}

.route-badge {
  font-size: 9px;
  font-weight: 700;
  padding: 1px 5px;
  border-radius: 4px;
}
.route-badge.red { background: rgba(239, 68, 68, 0.2); color: #fca5a5; border: 1px solid rgba(239, 68, 68, 0.4); }
.route-badge.blue { background: rgba(56, 189, 248, 0.2); color: #93c5fd; border: 1px solid rgba(56, 189, 248, 0.4); }
.route-badge.yellow { background: rgba(250, 204, 21, 0.2); color: #fde047; border: 1px solid rgba(250, 204, 21, 0.4); }

.btn-dock-restore {
  background: linear-gradient(135deg, #d97706, #b45309);
  color: #ffffff;
  border: 1px solid #fde047;
  border-radius: 8px;
  padding: 6px 12px;
  font-size: 11px;
  font-weight: 800;
  cursor: pointer;
  box-shadow: 0 2px 8px rgba(217, 119, 6, 0.5);
  display: flex;
  align-items: center;
  gap: 4px;
  white-space: nowrap;
  transition: transform 0.15s, box-shadow 0.15s;
}

.btn-dock-restore:hover {
  transform: translateY(-1px);
  box-shadow: 0 4px 14px rgba(245, 158, 11, 0.7);
}

.nav-card-dest-badge {
  margin-top: 4px;
  font-size: 8px;
  font-weight: 700;
  padding: 2px 5px;
  border-radius: 4px;
  display: block;
  width: 100%;
  max-width: 100%;
  box-sizing: border-box;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  text-align: center;
}
.nav-card-dest-badge.red { background: rgba(239, 68, 68, 0.2); color: #fca5a5; border: 1px solid rgba(239, 68, 68, 0.35); }
.nav-card-dest-badge.blue { background: rgba(56, 189, 248, 0.2); color: #93c5fd; border: 1px solid rgba(56, 189, 248, 0.35); }
.nav-card-dest-badge.yellow { background: rgba(250, 204, 21, 0.2); color: #fde047; border: 1px solid rgba(250, 204, 21, 0.35); }

.deck-modal-tabs {
  display: flex;
  gap: 6px;
  background: rgba(15, 23, 42, 0.65);
  padding: 3px;
  border-radius: 8px;
  border: 1px solid rgba(148, 163, 184, 0.2);
}

.deck-tab-btn {
  flex: 1;
  padding: 5px 8px;
  font-size: 10px;
  font-weight: 700;
  border-radius: 6px;
  background: transparent;
  border: 1px solid transparent;
  color: #94a3b8;
  cursor: pointer;
  transition: all 0.15s ease;
  white-space: nowrap;
}

.deck-tab-btn.active {
  background: rgba(245, 158, 11, 0.25);
  color: var(--gold-bright);
  border-color: rgba(245, 158, 11, 0.45);
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.4);
}

.deck-cards-scroll-container {
  overflow-y: auto;
  max-height: 60vh;
  padding-right: 2px;
}

.deck-cards-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
  width: 100%;
  box-sizing: border-box;
}

.nav-card-item {
  background: rgba(15, 23, 42, 0.85);
  border: 1.5px solid rgba(148, 163, 184, 0.3);
  border-radius: 10px;
  padding: 8px 6px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 5px;
  position: relative;
  width: 100%;
  min-width: 0;
  box-sizing: border-box;
  transition: all 0.15s ease;
}

.nav-card-item:hover {
  transform: translateY(-1px);
}

.nav-card-item.color-blue {
  border-color: rgba(56, 189, 248, 0.7);
  background: linear-gradient(135deg, rgba(56, 189, 248, 0.1) 0%, rgba(15, 23, 42, 0.9) 100%);
}

.nav-card-item.color-yellow {
  border-color: rgba(234, 179, 8, 0.7);
  background: linear-gradient(135deg, rgba(234, 179, 8, 0.1) 0%, rgba(15, 23, 42, 0.9) 100%);
}

.nav-card-item.color-red {
  border-color: rgba(239, 68, 68, 0.7);
  background: linear-gradient(135deg, rgba(239, 68, 68, 0.1) 0%, rgba(15, 23, 42, 0.9) 100%);
}

.nav-card-img-wrap {
  width: 76px;
  height: 76px;
  max-width: 100%;
  border-radius: 8px;
  overflow: hidden;
  background: #000;
  border: 1px solid rgba(255, 255, 255, 0.15);
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.6);
  flex-shrink: 0;
}

.nav-card-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.nav-card-badge-count {
  position: absolute;
  top: 5px;
  right: 5px;
  background: var(--gold-bright);
  color: #0b0f19;
  font-size: 10px;
  font-weight: 900;
  padding: 1px 6px;
  border-radius: 8px;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.5);
}

.nav-card-info {
  text-align: center;
  width: 100%;
  min-width: 0;
  box-sizing: border-box;
  overflow: hidden;
}

.nav-card-title {
  font-size: 10px;
  font-weight: 800;
  color: #fff;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  width: 100%;
  max-width: 100%;
  box-sizing: border-box;
}

.nav-card-sub {
  font-size: 8.5px;
  color: #94a3b8;
  margin-top: 1px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  width: 100%;
  max-width: 100%;
  box-sizing: border-box;
}

/* =========================================================
   PHASE 3 STEP 2: OFFICER CARD DRAW & LOGBOOK SELECTION
   ========================================================= */

.flow-officer.active-turn {
  color: var(--gold-bright);
  font-weight: 900;
  text-shadow: 0 0 8px rgba(245, 158, 11, 0.8);
  animation: pulseOfficer 1.5s infinite alternate;
}

@keyframes pulseOfficer {
  0% { transform: scale(1); filter: brightness(1); }
  100% { transform: scale(1.06); filter: brightness(1.3); text-shadow: 0 0 12px var(--gold-bright); }
}

.phase3-action-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 6px;
  margin-top: 5px;
  padding: 4px 6px;
  background: rgba(15, 23, 42, 0.65);
  border: 1px solid rgba(245, 158, 11, 0.25);
  border-radius: 8px;
  box-sizing: border-box;
  width: 100%;
  max-width: 100%;
  overflow: hidden;
}

.phase3-badges-group {
  display: flex;
  align-items: center;
  gap: 4px;
  flex-shrink: 0;
}

.phase3-logbook-badge {
  display: inline-flex;
  align-items: center;
  gap: 3px;
  padding: 2px 6px;
  background: rgba(245, 158, 11, 0.15);
  border: 1px solid rgba(245, 158, 11, 0.4);
  border-radius: 6px;
  font-size: 9px;
  flex-shrink: 0;
  white-space: nowrap;
}

.phase3-logbook-badge .logbook-icon {
  font-size: 10px;
}

.phase3-logbook-badge .logbook-count {
  color: var(--gold-bright);
  font-weight: 800;
}

.phase3-resume-badge {
  display: inline-flex;
  align-items: center;
  gap: 3px;
  padding: 2px 6px;
  background: rgba(56, 189, 248, 0.12);
  border: 1px solid rgba(56, 189, 248, 0.35);
  border-radius: 6px;
  font-size: 9px;
  flex-shrink: 0;
  white-space: nowrap;
}

.phase3-resume-badge .resume-icon {
  font-size: 10px;
}

.phase3-resume-badge .resume-cards-list {
  color: #38bdf8;
  font-weight: 800;
  display: inline-flex;
  gap: 2px;
  align-items: center;
}

.phase3-officer-prompt {
  display: flex;
  align-items: center;
  gap: 5px;
  margin-left: auto;
  flex-shrink: 1;
  min-width: 0;
}

.officer-turn-info {
  display: flex;
  flex-direction: column;
  text-align: right;
  line-height: 1.1;
  flex-shrink: 1;
  min-width: 0;
}

.officer-turn-role {
  font-size: 8.5px;
  font-weight: 800;
  color: var(--gold-bright);
  white-space: nowrap;
}

.officer-turn-name {
  font-size: 8px;
  color: #94a3b8;
  max-width: 60px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.btn-officer-draw {
  padding: 3px 8px;
  height: 25px;
  border-radius: 12px;
  background: linear-gradient(135deg, #f59e0b 0%, #d97706 100%);
  border: 1px solid #fbbf24;
  color: #0b0f19;
  font-size: 9.5px;
  font-weight: 900;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 3px;
  box-shadow: 0 2px 8px rgba(245, 158, 11, 0.4);
  transition: all 0.2s ease;
  white-space: nowrap;
  flex-shrink: 0;
}

.btn-officer-draw:hover {
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(245, 158, 11, 0.6);
  filter: brightness(1.1);
}

.btn-officer-bot {
  padding: 2px 5px;
  height: 23px;
  border-radius: 10px;
  background: rgba(99, 102, 241, 0.2);
  border: 1px solid rgba(99, 102, 241, 0.5);
  color: #a5b4fc;
  font-size: 8.5px;
  font-weight: 700;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 2px;
  transition: all 0.2s ease;
  flex-shrink: 0;
}

@media (max-width: 440px) {
  .phase3-action-row {
    gap: 4px;
    padding: 3px 4px;
  }
  .officer-turn-name {
    max-width: 48px;
  }
  .btn-officer-draw {
    padding: 2px 6px;
    font-size: 9px;
  }
}

.btn-officer-bot:hover {
  background: rgba(99, 102, 241, 0.35);
  transform: translateY(-1px);
}

/* Phase 3 Step 2 Officer Card Draw Modal */
.officer-draw-card,
.navigator-logbook-card {
  max-width: 440px;
  max-height: 90vh;
  width: 100%;
  box-sizing: border-box;
}

.officer-cards-container {
  padding: 4px 0;
  overflow-x: hidden;
  overflow-y: auto;
  max-height: 60vh;
  width: 100%;
  box-sizing: border-box;
}

.officer-cards-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
  width: 100%;
  box-sizing: border-box;
}

.officer-card-slot {
  display: flex;
  flex-direction: column;
  gap: 6px;
  background: rgba(15, 23, 42, 0.7);
  border: 1.5px solid rgba(148, 163, 184, 0.25);
  border-radius: 12px;
  padding: 6px;
  width: 100%;
  min-width: 0;
  box-sizing: border-box;
  transition: transform 0.2s cubic-bezier(0.34, 1.56, 0.64, 1), border-color 0.2s ease, box-shadow 0.2s ease, opacity 0.2s ease, background 0.2s ease;
  position: relative;
  cursor: pointer;
  user-select: none;
  touch-action: manipulation;
}

.officer-card-slot:hover {
  transform: translateY(-3px);
  border-color: rgba(245, 158, 11, 0.7);
  box-shadow: 0 6px 18px rgba(0, 0, 0, 0.5), 0 0 14px rgba(245, 158, 11, 0.3);
}

.officer-card-slot:active {
  transform: scale(0.97);
}

.officer-card-slot.assigned-discard {
  border: 1.5px dashed rgba(56, 189, 248, 0.65);
  background: rgba(14, 116, 144, 0.12);
  box-shadow: 0 0 10px rgba(56, 189, 248, 0.2);
  opacity: 0.72;
}

.officer-card-slot.assigned-discard:hover {
  opacity: 0.95;
  border-color: rgba(56, 189, 248, 0.9);
}

.officer-card-slot.assigned-logbook {
  border: 2px solid #fbbf24;
  background: linear-gradient(180deg, rgba(245, 158, 11, 0.25) 0%, rgba(15, 23, 42, 0.85) 100%);
  box-shadow: 0 0 20px rgba(245, 158, 11, 0.55), inset 0 0 12px rgba(245, 158, 11, 0.2);
  opacity: 1;
}

.officer-card-assignment-tag {
  text-align: center;
  font-size: 9.5px;
  font-weight: 800;
  padding: 4px 4px;
  border-radius: 6px;
  background: rgba(0, 0, 0, 0.4);
  min-height: 22px;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.2s ease;
  width: 100%;
  max-width: 100%;
  box-sizing: border-box;
  overflow: hidden;
  white-space: nowrap;
}

.officer-card-slot.assigned-discard .officer-card-assignment-tag {
  background: rgba(14, 116, 144, 0.55);
  color: #7dd3fc;
  border: 1px solid rgba(56, 189, 248, 0.4);
}

.officer-card-slot.assigned-logbook .officer-card-assignment-tag {
  background: rgba(245, 158, 11, 0.4);
  color: #fef08a;
  border: 1px solid rgba(251, 191, 36, 0.6);
  text-shadow: 0 0 8px rgba(245, 158, 11, 0.8);
}

.assignment-placeholder {
  color: #94a3b8;
  font-size: 9px;
  font-weight: 700;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 2px;
  width: 100%;
  max-width: 100%;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.officer-card-slot:hover .assignment-placeholder {
  color: #fbbf24;
}

.officer-modal-footer {
  display: flex;
  flex-direction: column;
  gap: 8px;
  border-top: 1px solid rgba(245, 158, 11, 0.25);
  padding-top: 8px;
}

.officer-decision-status {
  font-size: 10px;
  color: #cbd5e1;
  text-align: center;
}

.officer-modal-btn-row {
  display: flex;
  gap: 8px;
}

.btn-officer-confirm {
  flex: 1;
  height: 36px;
  border-radius: 8px;
  background: linear-gradient(135deg, #f59e0b 0%, #d97706 100%);
  border: 1px solid #fbbf24;
  color: #0b0f19;
  font-family: 'Cinzel', serif;
  font-size: 11px;
  font-weight: 900;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 4px 14px rgba(245, 158, 11, 0.4);
  transition: all 0.2s ease;
}

.btn-officer-confirm:hover:not(.disabled) {
  filter: brightness(1.1);
  transform: translateY(-1px);
}

.btn-officer-confirm.disabled {
  opacity: 0.45;
  cursor: not-allowed;
  filter: grayscale(0.8);
  box-shadow: none;
}

.btn-officer-random {
  padding: 0 10px;
  height: 36px;
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.2);
  color: #cbd5e1;
  font-size: 11px;
  font-weight: 700;
  cursor: pointer;
  transition: all 0.2s ease;
}

.btn-officer-random:hover {
  background: rgba(255, 255, 255, 0.16);
}

/* Navigator Steer & Overboard Actions */
.officer-card-slot.assigned-steer {
  border: 2px solid #10b981;
  background: linear-gradient(180deg, rgba(16, 185, 129, 0.25) 0%, rgba(15, 23, 42, 0.85) 100%);
  box-shadow: 0 0 20px rgba(16, 185, 129, 0.55), inset 0 0 12px rgba(16, 185, 129, 0.2);
  opacity: 1;
}

.officer-card-slot.assigned-steer .officer-card-assignment-tag {
  background: rgba(16, 185, 129, 0.4);
  color: #6ee7b7;
  border: 1px solid rgba(16, 185, 129, 0.6);
  text-shadow: 0 0 8px rgba(16, 185, 129, 0.8);
}

.btn-officer-draw.waiting {
  background: rgba(51, 65, 85, 0.4) !important;
  border-color: rgba(100, 116, 139, 0.4) !important;
  color: #94a3b8 !important;
  cursor: not-allowed !important;
  box-shadow: none !important;
  pointer-events: none;
}

.btn-jump-overboard {
  padding: 0 8px;
  height: 36px;
  border-radius: 8px;
  background: rgba(239, 68, 68, 0.15);
  border: 1px solid rgba(239, 68, 68, 0.4);
  color: #fca5a5;
  font-size: 10px;
  font-weight: 800;
  cursor: pointer;
  transition: all 0.2s ease;
}

.btn-jump-overboard:hover {
  background: rgba(239, 68, 68, 0.3);
  border-color: #ef4444;
  color: #fff;
}

/* =========================================================
   PHASE 3 STEP 4: NAVIGATION CARD REVEAL & SAILING MODAL
   ========================================================= */

.navigation-reveal-card {
  max-width: 440px;
  max-height: 92vh;
  border: 2px solid rgba(245, 158, 11, 0.5);
  box-shadow: 0 10px 40px rgba(0, 0, 0, 0.8), 0 0 25px rgba(245, 158, 11, 0.25);
  display: flex;
  flex-direction: column;
}

.reveal-content-body {
  display: flex;
  flex-direction: column;
  gap: 12px;
  padding: 8px 0;
  overflow-y: auto;
}

.reveal-card-spotlight {
  display: flex;
  justify-content: center;
  align-items: center;
  padding: 6px 0;
}

.reveal-spotlight-card {
  width: 140px;
  background: #0f172a;
  border-radius: 12px;
  padding: 8px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.6);
  position: relative;
  transition: transform 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
  animation: revealZoom 0.5s cubic-bezier(0.34, 1.56, 0.64, 1);
}

@keyframes revealZoom {
  0% { transform: scale(0.6) rotate(-4deg); opacity: 0; }
  100% { transform: scale(1) rotate(0deg); opacity: 1; }
}

.reveal-spotlight-card.color-blue {
  border: 2px solid #38bdf8;
  box-shadow: 0 0 24px rgba(56, 189, 248, 0.55);
}

.reveal-spotlight-card.color-red {
  border: 2px solid #ef4444;
  box-shadow: 0 0 24px rgba(239, 68, 68, 0.55);
}

.reveal-spotlight-card.color-yellow {
  border: 2px solid #eab308;
  box-shadow: 0 0 24px rgba(234, 179, 8, 0.55);
}

.reveal-spotlight-img {
  width: 100%;
  aspect-ratio: 5 / 7;
  object-fit: cover;
  border-radius: 8px;
  border: 1px solid rgba(255, 255, 255, 0.15);
}

.reveal-spotlight-name {
  font-family: 'Cinzel', serif;
  font-size: 12px;
  font-weight: 800;
  color: #f8fafc;
  text-align: center;
}

.reveal-spotlight-direction {
  font-size: 10px;
  font-weight: 800;
  padding: 2px 8px;
  border-radius: 10px;
  text-align: center;
}

.reveal-spotlight-direction.color-blue {
  background: rgba(56, 189, 248, 0.25);
  color: #38bdf8;
  border: 1px solid rgba(56, 189, 248, 0.5);
}

.reveal-spotlight-direction.color-red {
  background: rgba(239, 68, 68, 0.25);
  color: #fca5a5;
  border: 1px solid rgba(239, 68, 68, 0.5);
}

.reveal-spotlight-direction.color-yellow {
  background: rgba(234, 179, 8, 0.25);
  color: #fde047;
  border: 1px solid rgba(234, 179, 8, 0.5);
}

.reveal-voyage-box {
  background: rgba(15, 23, 42, 0.7);
  border: 1px solid rgba(245, 158, 11, 0.25);
  border-radius: 10px;
  padding: 8px 12px;
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.voyage-route-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}

.voyage-step {
  display: flex;
  flex-direction: column;
  flex: 1;
}

.voyage-step.current {
  text-align: left;
}

.voyage-step.destination {
  text-align: right;
}

.voyage-label {
  font-size: 8.5px;
  color: #94a3b8;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.voyage-name {
  font-size: 11px;
  font-weight: 800;
  color: #f8fafc;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.voyage-step.destination .voyage-name {
  color: var(--gold-bright);
}

.voyage-arrow {
  font-size: 14px;
  color: var(--gold-bright);
  animation: pulseArrow 1.2s infinite alternate;
}

@keyframes pulseArrow {
  0% { transform: translateX(0); opacity: 0.7; }
  100% { transform: translateX(4px); opacity: 1; }
}

.voyage-event-info {
  display: flex;
  align-items: center;
  gap: 6px;
  padding-top: 4px;
  border-top: 1px solid rgba(255, 255, 255, 0.08);
  font-size: 9.5px;
  color: #cbd5e1;
}

.voyage-event-info .event-badge {
  padding: 1px 6px;
  border-radius: 4px;
  font-size: 8.5px;
  font-weight: 800;
  background: rgba(56, 189, 248, 0.2);
  color: #38bdf8;
  border: 1px solid rgba(56, 189, 248, 0.4);
  flex-shrink: 0;
}

.reveal-action-box {
  background: rgba(15, 23, 42, 0.65);
  border: 1px solid rgba(148, 163, 184, 0.25);
  border-radius: 10px;
  padding: 8px 12px;
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.reveal-action-title {
  font-size: 10px;
  font-weight: 800;
  color: #f59e0b;
  display: flex;
  align-items: center;
  gap: 4px;
}

.reveal-action-desc {
  font-size: 9.5px;
  color: #cbd5e1;
  line-height: 1.35;
}

.reveal-interactive-controls {
  margin-top: 6px;
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.reveal-modal-footer {
  display: flex;
  gap: 8px;
  padding-top: 8px;
  border-top: 1px solid rgba(245, 158, 11, 0.25);
}

.btn-reveal-sail {
  flex: 1.4;
  height: 38px;
  border-radius: 8px;
  background: linear-gradient(135deg, #0284c7 0%, #0369a1 100%);
  border: 1px solid #38bdf8;
  color: #ffffff;
  font-family: 'Cinzel', serif;
  font-size: 11px;
  font-weight: 800;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 4px 14px rgba(2, 132, 199, 0.4);
  transition: all 0.2s ease;
}

.btn-reveal-sail:hover:not(:disabled) {
  filter: brightness(1.15);
  transform: translateY(-1px);
  box-shadow: 0 6px 18px rgba(2, 132, 199, 0.6);
}

.btn-reveal-sail:disabled {
  opacity: 0.5;
  cursor: not-allowed;
  filter: grayscale(0.8);
}

.btn-reveal-finish {
  flex: 1.1;
  height: 38px;
  border-radius: 8px;
  background: linear-gradient(135deg, #f59e0b 0%, #d97706 100%);
  border: 1px solid #fbbf24;
  color: #0b0f19;
  font-family: 'Cinzel', serif;
  font-size: 11px;
  font-weight: 900;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 4px 14px rgba(245, 158, 11, 0.4);
  transition: all 0.2s ease;
}

.btn-reveal-finish:hover:not(.disabled) {
  filter: brightness(1.15);
  transform: translateY(-1px);
}

.btn-reveal-finish.disabled {
  opacity: 0.4;
  cursor: not-allowed;
  filter: grayscale(0.8);
  box-shadow: none;
}

/* Off-Duty Status Badges */
.badge-off-duty {
  display: inline-flex;
  align-items: center;
  gap: 3px;
  padding: 1px 5px;
  background: rgba(148, 163, 184, 0.2);
  border: 1px solid rgba(148, 163, 184, 0.5);
  border-radius: 4px;
  color: #94a3b8;
  font-size: 8px;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.player-seat-pin.is-off-duty {
  opacity: 0.75;
  filter: saturate(0.7);
}

.player-seat-pin.is-off-duty .seat-name {
  color: #94a3b8;
}

/* =========================================================
   DRUNK CAPTAIN BADGE & CREST
   ========================================================= */
.seat-badge-tag.drunk {
  background: linear-gradient(135deg, #78350f, #451a03);
  color: #fde68a;
  border-color: rgba(245, 158, 11, 0.7);
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.6);
  font-weight: 800;
}

.seat-drunk-crest {
  position: absolute;
  top: -16px;
  right: -4px;
  font-size: 16px;
  filter: drop-shadow(0 2px 5px rgba(0, 0, 0, 0.8));
  animation: wobbleBeer 1.8s ease-in-out infinite alternate;
  z-index: 10;
}

@keyframes wobbleBeer {
  0% { transform: rotate(-10deg); }
  100% { transform: rotate(15deg) scale(1.08); }
}

/* =========================================================
   INSPECTED SEAT BADGE & CREST
   ========================================================= */
.seat-badge-tag.inspected {
  background: linear-gradient(135deg, #0369a1, #0c4a6e);
  color: #7dd3fc;
  border-color: rgba(56, 189, 248, 0.7);
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.6);
  font-weight: 800;
}

.seat-inspected-crest {
  position: absolute;
  top: -14px;
  left: -4px;
  font-size: 15px;
  filter: drop-shadow(0 2px 5px rgba(0, 0, 0, 0.9));
  z-index: 10;
}

/* =========================================================
   CULT RITUAL MODAL STYLING
   ========================================================= */
.cult-modal-card {
  border-color: #a855f7 !important;
  box-shadow: 0 16px 45px rgba(0, 0, 0, 0.9), 0 0 25px rgba(168, 85, 247, 0.35) !important;
  background: linear-gradient(145deg, #180d2b 0%, #0d0718 100%) !important;
}

.cult-header {
  border-bottom: 1px solid rgba(168, 85, 247, 0.4) !important;
}

.cult-eyebrow {
  font-size: 9px;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.8px;
  color: #c084fc;
}

.cult-title {
  color: #f3e8ff !important;
  text-shadow: 0 0 10px rgba(168, 85, 247, 0.6);
}

.cult-modal-body {
  display: flex;
  flex-direction: column;
  gap: 12px;
  padding: 8px 0;
  max-height: 62vh;
  overflow-y: auto;
}

.cult-card-display {
  display: flex;
  align-items: center;
  gap: 12px;
  background: rgba(33, 14, 58, 0.6);
  border: 1px solid rgba(168, 85, 247, 0.35);
  border-radius: 10px;
  padding: 10px;
}

.cult-card-img {
  width: 72px;
  height: 104px;
  object-fit: cover;
  border-radius: 6px;
  border: 1px solid #c084fc;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.7);
  flex-shrink: 0;
}

.cult-card-info {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.cult-card-name {
  font-family: 'Cinzel', serif;
  font-size: 13px;
  font-weight: 800;
  color: #e9d5ff;
  margin: 0;
}

.cult-card-desc {
  font-size: 10.5px;
  color: #cbd5e1;
  line-height: 1.35;
  margin: 0;
}

.cult-action-panel {
  display: flex;
  flex-direction: column;
  gap: 8px;
  background: rgba(15, 23, 42, 0.65);
  border: 1px dashed rgba(168, 85, 247, 0.4);
  border-radius: 8px;
  padding: 10px;
}

.cult-panel-prompt {
  font-size: 10.5px;
  font-weight: 700;
  color: #c084fc;
  margin: 0 0 4px 0;
}

/* Candidate item for conversion */
.cult-candidates-list {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.cult-candidate-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 6px 8px;
  background: rgba(30, 41, 59, 0.7);
  border: 1px solid rgba(148, 163, 184, 0.2);
  border-radius: 6px;
}

.cult-candidate-item.ineligible {
  opacity: 0.5;
  background: rgba(15, 23, 42, 0.5);
}

.cult-candidate-name {
  font-size: 11px;
  font-weight: 700;
  color: #f1f5f9;
}

.btn-convert-player {
  padding: 4px 10px;
  font-family: 'Cinzel', serif;
  font-size: 10px;
  font-weight: 800;
  background: linear-gradient(135deg, #9333ea, #7e22ce);
  border: 1px solid #c084fc;
  color: #fff;
  border-radius: 5px;
  cursor: pointer;
  transition: all 0.15s ease;
}

.btn-convert-player:hover:not(:disabled) {
  filter: brightness(1.2);
  transform: translateY(-1px);
}

.btn-convert-player:disabled {
  opacity: 0.4;
  cursor: not-allowed;
  background: #334155;
  border-color: #475569;
}

/* Guns distribution stepper */
.cult-guns-distribution-list {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.cult-guns-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 6px 8px;
  background: rgba(30, 41, 59, 0.7);
  border-radius: 6px;
}

.cult-guns-stepper {
  display: flex;
  align-items: center;
  gap: 8px;
}

.btn-cult-stepper {
  width: 24px;
  height: 24px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: #334155;
  border: 1px solid #64748b;
  color: #fff;
  border-radius: 4px;
  cursor: pointer;
  font-weight: bold;
}

.cult-guns-count {
  font-size: 11px;
  font-weight: 800;
  color: #fbbf24;
  min-width: 16px;
  text-align: center;
}

/* Cabin search officer cards */
.cult-cabin-grid {
  display: grid;
  grid-template-columns: 1fr 1fr 1fr;
  gap: 8px;
}

.cult-officer-slot {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
  padding: 8px 4px;
  background: rgba(30, 41, 59, 0.8);
  border-radius: 8px;
  text-align: center;
}

.cult-officer-slot.sailor {
  border: 1.5px solid #38bdf8;
  background: linear-gradient(145deg, rgba(2, 132, 199, 0.25), rgba(15, 23, 42, 0.9));
}

.cult-officer-slot.pirate {
  border: 1.5px solid #f87171;
  background: linear-gradient(145deg, rgba(220, 38, 38, 0.25), rgba(15, 23, 42, 0.9));
}

.cult-officer-slot.cult {
  border: 1.5px solid #c084fc;
  background: linear-gradient(145deg, rgba(147, 51, 234, 0.25), rgba(15, 23, 42, 0.9));
}

.cult-officer-role {
  font-size: 8.5px;
  color: #94a3b8;
  font-weight: 700;
  text-transform: uppercase;
}

.cult-officer-name {
  font-size: 10px;
  font-weight: 800;
  color: #fff;
}

.cult-officer-faction-pill {
  font-size: 9.5px;
  font-weight: 800;
  padding: 2px 6px;
  border-radius: 4px;
}

/* Spectator Notice */
.cult-spectator-notice {
  display: flex;
  align-items: center;
  gap: 8px;
  background: rgba(30, 41, 59, 0.8);
  border: 1px dashed rgba(168, 85, 247, 0.5);
  border-radius: 8px;
  padding: 10px;
}

.spectator-icon {
  font-size: 20px;
}

.cult-spectator-notice p {
  font-size: 10px;
  color: #e2e8f0;
  margin: 0;
  line-height: 1.35;
}

.btn-cult-dismiss {
  width: 100%;
  padding: 9px;
  font-family: 'Cinzel', serif;
  font-size: 11px;
  font-weight: 800;
  background: linear-gradient(135deg, #6b21a8, #581c87);
  border: 1px solid #a855f7;
  color: #f3e8ff;
  border-radius: 8px;
  cursor: pointer;
  transition: all 0.15s ease;
}

.btn-cult-dismiss:hover {
  filter: brightness(1.2);
}

/* =========================================================
   MERMAID & TELESCOPE MODALS
   ========================================================= */
.mermaid-cards-grid {
  display: flex;
  gap: 8px;
  justify-content: center;
}

.mermaid-card-thumb {
  width: 80px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
  background: rgba(15, 23, 42, 0.7);
  border-radius: 8px;
  padding: 6px;
  border: 1px solid rgba(56, 189, 248, 0.4);
}

.mermaid-card-thumb img {
  width: 100%;
  border-radius: 6px;
}

.mermaid-card-label {
  font-size: 9px;
  font-weight: 800;
  color: #38bdf8;
  text-align: center;
}

.btn-mermaid-close {
  width: 100%;
  padding: 8px;
  background: rgba(56, 189, 248, 0.2);
  border: 1px solid #38bdf8;
  color: #e0f2fe;
  font-weight: 800;
  font-size: 11px;
  border-radius: 8px;
  cursor: pointer;
}

.telescope-card-slot {
  display: flex;
  justify-content: center;
  padding: 8px;
}

.telescope-card-slot img {
  width: 100px;
  border-radius: 8px;
  border: 1.5px solid var(--gold-bright);
  box-shadow: 0 6px 18px rgba(0, 0, 0, 0.7);
}

.telescope-prompt {
  font-size: 10.5px;
  color: #cbd5e1;
  text-align: center;
  margin: 6px 0;
}

.telescope-choice-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
}

.btn-telescope-keep {
  padding: 9px 6px;
  background: rgba(34, 197, 94, 0.2);
  border: 1px solid #22c55e;
  color: #86efac;
  font-size: 10px;
  font-weight: 800;
  border-radius: 8px;
  cursor: pointer;
}

.btn-telescope-discard {
  padding: 9px 6px;
  background: rgba(239, 68, 68, 0.2);
  border: 1px solid #ef4444;
  color: #fca5a5;
  font-size: 10px;
  font-weight: 800;
  border-radius: 8px;
  cursor: pointer;
}

/* =========================================================
   SECRET CONVERSION MODAL
   ========================================================= */
.cult-converted-modal .cult-converted-card {
  position: relative;
  width: 100%;
  max-width: 380px;
  background: linear-gradient(145deg, #2e1065, #0f0728);
  border: 2px solid #a855f7;
  box-shadow: 0 20px 50px rgba(0, 0, 0, 0.9), 0 0 30px rgba(168, 85, 247, 0.5);
  border-radius: 16px;
  padding: 16px;
  display: flex;
  flex-direction: column;
  gap: 12px;
  animation: modalPop 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

.cult-converted-header {
  display: flex;
  align-items: center;
  gap: 10px;
  border-bottom: 1px solid rgba(168, 85, 247, 0.4);
  padding-bottom: 8px;
}

.cult-converted-icon {
  font-size: 28px;
  filter: drop-shadow(0 0 8px #c084fc);
}

.cult-converted-title {
  font-family: 'Cinzel', serif;
  font-size: 15px;
  font-weight: 900;
  color: #f3e8ff;
  margin: 0;
}

.cult-converted-body {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.cult-converted-text {
  font-size: 11.5px;
  color: #e9d5ff;
  line-height: 1.4;
  margin: 0;
}

.cult-converted-badge {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 6px 10px;
  background: rgba(147, 51, 234, 0.3);
  border: 1px solid #c084fc;
  border-radius: 8px;
  font-size: 11px;
  color: #fbbf24;
}

.cult-converted-subtext {
  font-size: 10px;
  color: #cbd5e1;
  font-style: italic;
  margin: 0;
  line-height: 1.35;
}

.btn-cult-embrace {
  width: 100%;
  padding: 10px;
  font-family: 'Cinzel', serif;
  font-size: 11px;
  font-weight: 800;
  background: linear-gradient(135deg, #7c3aed, #4c1d95);
  border: 1px solid #c084fc;
  color: #fff;
  border-radius: 8px;
  cursor: pointer;
  box-shadow: 0 4px 14px rgba(124, 58, 237, 0.4);
}

/* =========================================================
   CABIN INSPECTION SPACE MODAL STYLING (PLATE ACTION)
   ========================================================= */
.inspection-modal-card {
  border-color: #38bdf8 !important;
  box-shadow: 0 16px 45px rgba(0, 0, 0, 0.9), 0 0 25px rgba(56, 189, 248, 0.35) !important;
  background: linear-gradient(145deg, #0c1c2e 0%, #060e18 100%) !important;
}

.inspection-header {
  border-bottom: 1px solid rgba(56, 189, 248, 0.35) !important;
}

.inspection-eyebrow {
  font-size: 9px;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.8px;
  color: #38bdf8;
}

.inspection-modal-body {
  display: flex;
  flex-direction: column;
  gap: 12px;
  padding: 10px 0;
  max-height: 65vh;
  overflow-y: auto;
}

.inspection-prompt {
  font-size: 11px;
  color: #cbd5e1;
  line-height: 1.4;
  margin: 0 0 8px 0;
}

.inspection-candidates-list {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.inspection-candidate-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 8px 10px;
  background: rgba(30, 41, 59, 0.7);
  border: 1px solid rgba(148, 163, 184, 0.25);
  border-radius: 8px;
  transition: all 0.15s ease;
}

.inspection-candidate-row:hover {
  background: rgba(30, 41, 59, 0.9);
  border-color: rgba(56, 189, 248, 0.5);
}

.inspection-candidate-info {
  display: flex;
  align-items: center;
  gap: 8px;
}

.inspection-candidate-name {
  font-size: 11.5px;
  font-weight: 700;
  color: #f1f5f9;
}

.btn-inspect-target {
  padding: 5px 12px;
  font-family: 'Cinzel', serif;
  font-size: 10px;
  font-weight: 800;
  background: linear-gradient(135deg, #0284c7, #0369a1);
  border: 1px solid #38bdf8;
  color: #fff;
  border-radius: 5px;
  cursor: pointer;
  transition: all 0.15s ease;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.4);
}

.btn-inspect-target:hover {
  filter: brightness(1.2);
  transform: translateY(-1px);
}

/* Inspection Result Card */
.inspection-result-box {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
  padding: 16px;
  border-radius: 10px;
  text-align: center;
  background: rgba(15, 23, 42, 0.85);
  box-shadow: 0 6px 20px rgba(0, 0, 0, 0.6);
}

.inspection-result-box.sailor {
  border: 2px solid #38bdf8;
  box-shadow: 0 0 20px rgba(56, 189, 248, 0.3);
}

.inspection-result-box.pirate {
  border: 2px solid #f87171;
  box-shadow: 0 0 20px rgba(248, 113, 113, 0.3);
}

.inspection-result-box.cult {
  border: 2px solid #c084fc;
  box-shadow: 0 0 20px rgba(192, 132, 252, 0.3);
}

.inspection-result-avatar {
  font-size: 32px;
}

.inspection-result-player-name {
  font-family: 'Cinzel', serif;
  font-size: 14px;
  font-weight: 800;
  color: #f1f5f9;
}

.inspection-result-faction-banner {
  font-size: 12px;
  font-weight: 800;
  padding: 6px 14px;
  border-radius: 6px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.inspection-result-faction-banner.sailor {
  background: rgba(2, 132, 199, 0.3);
  color: #38bdf8;
  border: 1px solid #38bdf8;
}

.inspection-result-faction-banner.pirate {
  background: rgba(220, 38, 38, 0.3);
  color: #f87171;
  border: 1px solid #f87171;
}

.inspection-result-faction-banner.cult {
  background: rgba(147, 51, 234, 0.3);
  color: #c084fc;
  border: 1px solid #c084fc;
}

.inspection-result-desc {
  font-size: 11px;
  color: #cbd5e1;
  line-height: 1.35;
  max-width: 280px;
}

.inspection-inspected-alert {
  font-size: 10px;
  color: #fbbf24;
  background: rgba(245, 158, 11, 0.15);
  border: 1px solid rgba(245, 158, 11, 0.4);
  padding: 4px 8px;
  border-radius: 4px;
  margin-top: 4px;
}

.btn-inspection-dismiss {
  width: 100%;
  padding: 8px 14px;
  font-family: 'Cinzel', serif;
  font-size: 11px;
  font-weight: 800;
  background: linear-gradient(135deg, #0284c7, #0369a1);
  border: 1px solid #38bdf8;
  color: #fff;
  border-radius: 6px;
  cursor: pointer;
  transition: all 0.15s ease;
}

.btn-inspection-dismiss:hover {
  filter: brightness(1.2);
}

/* =========================================================
   KNIFE / CUT TONGUE MODAL STYLING
   ========================================================= */
.knife-modal-card {
  border-color: #ef4444 !important;
  box-shadow: 0 16px 45px rgba(0, 0, 0, 0.9), 0 0 25px rgba(239, 68, 68, 0.35) !important;
  background: linear-gradient(145deg, #2b0d0d 0%, #150606 100%) !important;
}

.knife-header {
  border-bottom: 1px solid rgba(239, 68, 68, 0.4) !important;
}

.knife-eyebrow {
  font-size: 9px;
  font-weight: 800;
  color: #f87171;
  text-transform: uppercase;
  letter-spacing: 1px;
  display: block;
  margin-bottom: 3px;
}

.knife-prompt {
  font-size: 12px;
  color: #fecaca;
  margin-bottom: 12px;
  line-height: 1.4;
}

.knife-candidates-list,
.kraken-candidates-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
  max-height: 240px;
  overflow-y: auto;
  margin-bottom: 10px;
}

.knife-candidate-row,
.kraken-candidate-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 8px 12px;
  background: rgba(15, 23, 42, 0.6);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 6px;
  transition: all 0.15s ease;
}

.knife-candidate-row:hover,
.kraken-candidate-row:hover {
  background: rgba(30, 41, 59, 0.8);
  border-color: rgba(255, 255, 255, 0.2);
}

.btn-cut-tongue {
  padding: 6px 12px;
  font-family: 'Cinzel', serif;
  font-size: 11px;
  font-weight: 800;
  background: linear-gradient(135deg, #dc2626, #991b1b);
  border: 1px solid #f87171;
  color: #fff;
  border-radius: 5px;
  cursor: pointer;
  transition: all 0.15s ease;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.4);
}

.btn-cut-tongue:hover {
  filter: brightness(1.2);
  transform: translateY(-1px);
}

.btn-knife-dismiss {
  width: 100%;
  padding: 8px 14px;
  font-family: 'Cinzel', serif;
  font-size: 11px;
  font-weight: 800;
  background: linear-gradient(135deg, #dc2626, #991b1b);
  border: 1px solid #f87171;
  color: #fff;
  border-radius: 6px;
  cursor: pointer;
  transition: all 0.15s ease;
}

.btn-knife-dismiss:hover {
  filter: brightness(1.2);
}

.knife-result-box {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
  padding: 16px;
  border-radius: 10px;
  text-align: center;
  background: rgba(15, 23, 42, 0.85);
  border: 2px solid #ef4444;
  box-shadow: 0 0 20px rgba(239, 68, 68, 0.3);
}

/* =========================================================
   KRAKEN PERIL MODAL STYLING
   ========================================================= */
.kraken-modal-card {
  border-color: #eab308 !important;
  box-shadow: 0 16px 45px rgba(0, 0, 0, 0.95), 0 0 30px rgba(234, 179, 8, 0.4) !important;
  background: linear-gradient(145deg, #1c1503 0%, #0c0800 100%) !important;
}

.kraken-header {
  border-bottom: 1px solid rgba(234, 179, 8, 0.4) !important;
}

.kraken-eyebrow {
  font-size: 9px;
  font-weight: 800;
  color: #facc15;
  text-transform: uppercase;
  letter-spacing: 1px;
  display: block;
  margin-bottom: 3px;
}

.kraken-prompt {
  font-size: 12px;
  color: #fef08a;
  margin-bottom: 12px;
  line-height: 1.4;
}

.btn-feed-kraken {
  padding: 6px 12px;
  font-family: 'Cinzel', serif;
  font-size: 11px;
  font-weight: 800;
  background: linear-gradient(135deg, #ca8a04, #854d0e);
  border: 1px solid #facc15;
  color: #fff;
  border-radius: 5px;
  cursor: pointer;
  transition: all 0.15s ease;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.4);
}

.btn-feed-kraken:hover {
  filter: brightness(1.25);
  transform: translateY(-1px);
}

.btn-kraken-dismiss {
  width: 100%;
  padding: 8px 14px;
  font-family: 'Cinzel', serif;
  font-size: 11px;
  font-weight: 800;
  background: linear-gradient(135deg, #ca8a04, #854d0e);
  border: 1px solid #facc15;
  color: #fff;
  border-radius: 6px;
  cursor: pointer;
  transition: all 0.15s ease;
}

.btn-kraken-dismiss:hover {
  filter: brightness(1.2);
}

.kraken-sacrifice-box {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
  padding: 16px;
  border-radius: 10px;
  text-align: center;
  background: rgba(15, 23, 42, 0.9);
  border: 2px solid #eab308;
  box-shadow: 0 0 25px rgba(234, 179, 8, 0.35);
}

.kraken-sacrifice-box.cult-win {
  border-color: #c084fc;
  box-shadow: 0 0 35px rgba(192, 132, 252, 0.5);
  background: linear-gradient(145deg, #2b0e45 0%, #11051e 100%);
}

/* =========================================================
   SEAT BADGES & CRESTS FOR MUTED & ELIMINATED PLAYERS
   ========================================================= */
.seat-badge-tag.tongue-cut {
  background: linear-gradient(135deg, #475569, #334155);
  color: #f87171;
  border-color: rgba(239, 68, 68, 0.6);
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.6);
  font-weight: 800;
}

.seat-tongue-crest {
  position: absolute;
  top: -16px;
  left: -4px;
  font-size: 16px;
  filter: drop-shadow(0 2px 5px rgba(0, 0, 0, 0.8));
  animation: pulseMute 2s ease-in-out infinite alternate;
  z-index: 10;
}

@keyframes pulseMute {
  0% { transform: scale(0.95); opacity: 0.85; }
  100% { transform: scale(1.1); opacity: 1; }
}

.seat-badge-tag.eliminated {
  background: linear-gradient(135deg, #1e293b, #0f172a);
  color: #94a3b8;
  border-color: rgba(148, 163, 184, 0.4);
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.7);
  font-weight: 800;
  text-decoration: line-through;
}

.seat-eliminated-crest {
  position: absolute;
  top: -16px;
  right: -4px;
  font-size: 16px;
  filter: drop-shadow(0 2px 5px rgba(0, 0, 0, 0.8));
  z-index: 10;
}

/* ==============================================================================
   ROBUST CONNECTION & RECONNECTION UI STYLES
   ============================================================================== */

.room-pill-conn {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  font-size: 10px;
  font-weight: 800;
  padding: 2px 8px;
  border-radius: 10px;
  transition: all 0.3s ease;
  user-select: none;
}

.room-pill-conn .conn-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  display: inline-block;
  flex-shrink: 0;
}

.room-pill-conn.conn-online {
  background: rgba(34, 197, 94, 0.15);
  border: 1px solid rgba(34, 197, 94, 0.45);
  color: #86efac;
}

.room-pill-conn.conn-online .conn-dot {
  background: #22c55e;
  box-shadow: 0 0 6px rgba(34, 197, 94, 0.85);
}

.room-pill-conn.conn-reconnecting {
  background: rgba(234, 179, 8, 0.2);
  border: 1px solid rgba(234, 179, 8, 0.6);
  color: #fef08a;
  animation: pulseConn 1.2s infinite;
}

.room-pill-conn.conn-reconnecting .conn-dot {
  background: #eab308;
  box-shadow: 0 0 8px rgba(234, 179, 8, 0.9);
}

.room-pill-conn.conn-offline {
  background: rgba(239, 68, 68, 0.2);
  border: 1px solid rgba(239, 68, 68, 0.55);
  color: #fca5a5;
}

.room-pill-conn.conn-offline .conn-dot {
  background: #ef4444;
}

@keyframes pulseConn {
  0%, 100% { opacity: 1; transform: scale(1); }
  50% { opacity: 0.6; transform: scale(0.97); }
}

/* Floating Reconnection Banner */
.connection-banner {
  position: fixed;
  top: 58px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 9999;
  width: calc(100% - 24px);
  max-width: 500px;
  background: rgba(15, 23, 42, 0.96);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border: 1.5px solid rgba(245, 158, 11, 0.7);
  box-shadow: 0 12px 36px rgba(0, 0, 0, 0.85), 0 0 24px rgba(245, 158, 11, 0.35);
  border-radius: 12px;
  padding: 10px 14px;
  animation: slideDownBanner 0.35s cubic-bezier(0.16, 1, 0.3, 1);
}

.connection-banner.banner-offline {
  border-color: rgba(239, 68, 68, 0.8);
  box-shadow: 0 12px 36px rgba(0, 0, 0, 0.85), 0 0 24px rgba(239, 68, 68, 0.35);
}

.connection-banner.banner-success {
  border-color: rgba(34, 197, 94, 0.8);
  box-shadow: 0 12px 36px rgba(0, 0, 0, 0.85), 0 0 24px rgba(34, 197, 94, 0.35);
}

.conn-banner-content {
  display: flex;
  align-items: center;
  gap: 12px;
}

.conn-banner-icon {
  font-size: 22px;
  line-height: 1;
  flex-shrink: 0;
}

.conn-banner-text-col {
  display: flex;
  flex-direction: column;
  flex: 1;
  min-width: 0;
}

.conn-banner-title {
  font-size: 13px;
  font-weight: 800;
  color: #fbbf24;
  letter-spacing: 0.3px;
}

.banner-offline .conn-banner-title {
  color: #f87171;
}

.banner-success .conn-banner-title {
  color: #4ade80;
}

.conn-banner-sub {
  font-size: 11px;
  color: #cbd5e1;
  margin-top: 1px;
}

.btn-conn-reconnect {
  background: linear-gradient(135deg, #f59e0b 0%, #d97706 100%);
  color: #0f172a;
  border: none;
  font-size: 11px;
  font-weight: 800;
  padding: 7px 13px;
  border-radius: 8px;
  cursor: pointer;
  white-space: nowrap;
  box-shadow: 0 2px 8px rgba(245, 158, 11, 0.45);
  transition: all 0.2s ease;
  flex-shrink: 0;
}

.btn-conn-reconnect:hover {
  transform: translateY(-1px);
  box-shadow: 0 4px 14px rgba(245, 158, 11, 0.7);
}

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

/* Active Session Recovery Card on Landing Page */
.resume-session-banner {
  background: linear-gradient(135deg, rgba(30, 58, 138, 0.45) 0%, rgba(15, 23, 42, 0.8) 100%);
  border: 1.5px solid rgba(96, 165, 250, 0.6);
  border-radius: 12px;
  padding: 12px 14px;
  margin-bottom: 16px;
  box-shadow: 0 6px 20px rgba(0, 0, 0, 0.45), inset 0 0 14px rgba(59, 130, 246, 0.2);
  animation: fadeInResume 0.3s ease;
}

.resume-session-content {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  margin-bottom: 10px;
}

.resume-icon {
  font-size: 26px;
  line-height: 1;
  flex-shrink: 0;
}

.resume-info {
  flex: 1;
  min-width: 0;
}

.resume-eyebrow {
  font-size: 10px;
  font-weight: 800;
  text-transform: uppercase;
  color: #60a5fa;
  letter-spacing: 0.6px;
}

.resume-title {
  font-size: 14px;
  font-weight: 800;
  color: #f8fafc;
  margin: 2px 0 3px;
}

.resume-sub {
  font-size: 11px;
  color: #94a3b8;
  line-height: 1.35;
  margin: 0;
}

.resume-actions {
  display: flex;
  gap: 8px;
}

.btn-resume-action {
  flex: 1;
  padding: 9px 12px;
  font-size: 12px;
  font-weight: 800;
  background: linear-gradient(135deg, #2563eb 0%, #1d4ed8 100%);
  border: 1px solid rgba(147, 197, 253, 0.5);
  color: #fff;
  border-radius: 8px;
  cursor: pointer;
  box-shadow: 0 4px 12px rgba(37, 99, 235, 0.4);
  transition: all 0.2s ease;
}

.btn-resume-action:hover {
  transform: translateY(-1px);
  box-shadow: 0 6px 16px rgba(37, 99, 235, 0.6);
}

.btn-resume-dismiss {
  padding: 8px 12px;
  font-size: 11px;
  border-radius: 8px;
  border: 1px solid rgba(255, 255, 255, 0.15);
  background: rgba(255, 255, 255, 0.08);
  color: #cbd5e1;
  cursor: pointer;
}

.btn-resume-dismiss:hover {
  background: rgba(255, 255, 255, 0.14);
}

@keyframes fadeInResume {
  from { opacity: 0; transform: translateY(-6px); }
  to { opacity: 1; transform: translateY(0); }
}

/* Player Seat Offline Indication */
.board-player-seat.is-offline {
  opacity: 0.55;
  filter: grayscale(60%);
  border-style: dashed;
}

.seat-offline-dot {
  position: absolute;
  top: -2px;
  right: -2px;
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background: #ef4444;
  border: 2px solid #0f172a;
  box-shadow: 0 0 6px rgba(239, 68, 68, 0.8);
  z-index: 12;
}

/* Card Modals Mobile & Simulator Responsive Layout */
@media (max-width: 480px) {
  .deck-modal {
    padding: 8px;
  }
  .deck-modal-card {
    padding: 10px 8px;
    gap: 8px;
    max-width: 100%;
  }
  .deck-modal-header {
    gap: 6px;
    padding-bottom: 6px;
  }
  .deck-modal-header > div {
    flex: 1;
    min-width: 0;
  }
  .deck-modal-title {
    font-size: 11.5px;
  }
  .deck-modal-subtitle {
    font-size: 9px;
  }
  .btn-modal-peek {
    font-size: 9.5px;
    padding: 3px 6px;
  }
  .officer-cards-grid {
    gap: 6px;
  }
  .officer-card-slot {
    padding: 5px 4px;
    gap: 4px;
  }
  .nav-card-item {
    padding: 6px 3px;
    gap: 3px;
  }
  .nav-card-img-wrap {
    width: 66px;
    height: 66px;
  }
  .nav-card-title {
    font-size: 9.5px;
  }
  .nav-card-sub {
    font-size: 8px;
  }
  .nav-card-dest-badge {
    font-size: 7.5px;
    padding: 2px 3px;
  }
  .officer-card-assignment-tag {
    font-size: 8.5px;
    padding: 3px 2px;
    min-height: 20px;
  }
  .assignment-placeholder {
    font-size: 8px;
  }
  .officer-decision-status {
    font-size: 9px;
  }
  .btn-officer-confirm {
    font-size: 10px;
    height: 32px;
  }
  .btn-officer-random {
    font-size: 10px;
    height: 32px;
    padding: 0 8px;
  }
}

body.sim-active .deck-modal {
  padding: 8px;
}
body.sim-active .deck-modal-card {
  padding: 10px 8px;
  gap: 8px;
  max-width: 100%;
}
body.sim-active .deck-modal-header {
  gap: 6px;
  padding-bottom: 6px;
}
body.sim-active .deck-modal-header > div {
  flex: 1;
  min-width: 0;
}
body.sim-active .deck-modal-title {
  font-size: 11.5px;
}
body.sim-active .deck-modal-subtitle {
  font-size: 9px;
}
body.sim-active .btn-modal-peek {
  font-size: 9.5px;
  padding: 3px 6px;
}
body.sim-active .officer-cards-grid {
  gap: 6px;
}
body.sim-active .officer-card-slot {
  padding: 5px 4px;
  gap: 4px;
}
body.sim-active .nav-card-item {
  padding: 6px 3px;
  gap: 3px;
}
body.sim-active .nav-card-img-wrap {
  width: 66px;
  height: 66px;
}
body.sim-active .nav-card-title {
  font-size: 9.5px;
}
body.sim-active .nav-card-sub {
  font-size: 8px;
}
body.sim-active .nav-card-dest-badge {
  font-size: 7.5px;
  padding: 2px 3px;
}
body.sim-active .officer-card-assignment-tag {
  font-size: 8.5px;
  padding: 3px 2px;
  min-height: 20px;
}
body.sim-active .assignment-placeholder {
  font-size: 8px;
}
body.sim-active .officer-decision-status {
  font-size: 9px;
}
body.sim-active .btn-officer-confirm {
  font-size: 10px;
  height: 32px;
}
body.sim-active .btn-officer-random {
  font-size: 10px;
  height: 32px;
  padding: 0 8px;
}


