/* ==========================================================================
   Tactical Wildlife Survey Deliverable - Stylesheet
   Executive Dark Glassmorphism Aesthetic
   ========================================================================== */

:root {
  --bg-dark: #0a0e14;
  --bg-card: rgba(16, 23, 34, 0.85);
  --bg-card-hover: rgba(24, 35, 52, 0.95);
  --border-glow: rgba(0, 229, 255, 0.25);
  --border-subtle: rgba(255, 255, 255, 0.1);
  
  /* Species Color Codes */
  --c-nontypical: #f59e0b; /* Amber/Gold Crown */
  --c-nontypical-glow: rgba(245, 158, 11, 0.45);
  --c-wt-buck: #0284c7;    /* Sky Blue / Cyan (Matches Doe Color Family) */
  --c-wt-doe: #06b6d4;     /* Cyan */
  --c-axis-buck: #f97316;  /* Vivid Orange */
  --c-axis-doe: #fb923c;   /* Soft Orange */
  --c-stag-bull: #ef4444;  /* Crimson Red */
  --c-stag-hind: #f43f5e;  /* Rose Red */
  --c-turkey: #d97706;     /* Bronze / Copper */
  --c-hogs: #64748b;       /* Charcoal / Slate */
  
  --accent-cyan: #00e5ff;
  --accent-blue: #3b82f6;
  --text-main: #f1f5f9;
  --text-muted: #94a3b8;
  --text-dim: #64748b;
  
  --font-tactical: 'Chakra Petch', sans-serif;
  --font-sans: 'Inter', sans-serif;
  --header-height: 68px;
  --sidebar-width: 380px;
}

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
  -webkit-print-color-adjust: exact !important;
  print-color-adjust: exact !important;
}

html {
  height: 100%;
  width: 100%;
  overflow: hidden;
  background: var(--bg-dark);
}

body {
  font-family: var(--font-sans);
  background: var(--bg-dark);
  color: var(--text-main);
  overflow: hidden;
  position: fixed;
  top: var(--app-offset-top, 0px);
  left: 0;
  height: 100vh;
  height: 100dvh;
  height: var(--app-height, 100dvh);
  width: 100%;
  overscroll-behavior: none;
  user-select: none;
}

/* Glass panel utility */
.glass-panel {
  background: var(--bg-card);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border: 1px solid var(--border-subtle);
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.6);
  border-radius: 12px;
}

/* App Container */
#app-container {
  display: flex;
  flex-direction: column;
  height: 100%;
  width: 100%;
  overflow: hidden;
}

/* ==========================================================================
   Header Bar
   ========================================================================== */
#header-bar {
  height: var(--header-height);
  background: rgba(10, 14, 20, 0.95);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--border-subtle);
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 20px;
  z-index: 1000;
  flex-shrink: 0;
}

.header-left {
  display: flex;
  align-items: center;
  gap: 14px;
}

.logo-badge {
  width: 50px;
  height: 50px;
  background: rgba(10, 14, 20, 0.8);
  border: 1.5px solid var(--accent-cyan);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  box-shadow: 0 0 15px rgba(0, 229, 255, 0.35);
  flex-shrink: 0;
}

.header-logo-img {
  width: 108%;
  height: 108%;
  object-fit: cover;
  display: block;
  filter: brightness(1.45) contrast(1.18);
}

.title-group .eyebrow {
  font-family: var(--font-tactical);
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 1.5px;
  color: var(--accent-cyan);
  display: flex;
  align-items: center;
  gap: 6px;
}

.live-dot {
  width: 7px;
  height: 7px;
  background: #10b981;
  border-radius: 50%;
  display: inline-block;
  box-shadow: 0 0 8px #10b981;
  animation: pulse-live 2s infinite;
}

@keyframes pulse-live {
  0% { transform: scale(0.95); opacity: 0.7; }
  50% { transform: scale(1.3); opacity: 1; }
  100% { transform: scale(0.95); opacity: 0.7; }
}

.title-group h1 {
  font-family: var(--font-tactical);
  font-size: 1.2rem;
  font-weight: 700;
  letter-spacing: 0.5px;
  color: #fff;
  white-space: nowrap;
}

/* Header Stats Center */
.header-center {
  display: flex;
  align-items: center;
  gap: 10px;
}

.stat-pill {
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid var(--border-subtle);
  border-radius: 8px;
  padding: 6px 14px;
  display: flex;
  flex-direction: column;
  align-items: center;
  min-width: 82px;
  transition: all 0.2s ease;
}

.stat-pill:hover {
  background: rgba(255, 255, 255, 0.08);
  border-color: rgba(255, 255, 255, 0.2);
}

.stat-pill.trophy-pill {
  border-color: rgba(245, 158, 11, 0.5);
  background: rgba(245, 158, 11, 0.1);
  box-shadow: 0 0 12px rgba(245, 158, 11, 0.2);
}

.stat-pill.trophy-pill .stat-num {
  color: var(--c-nontypical);
}

.stat-num {
  font-family: var(--font-tactical);
  font-size: 1.25rem;
  font-weight: 700;
  line-height: 1.1;
  color: #fff;
}

.stat-lbl {
  font-size: 0.62rem;
  font-weight: 600;
  letter-spacing: 0.8px;
  color: var(--text-muted);
}

/* Header Right Buttons */
.header-right {
  display: flex;
  align-items: center;
  gap: 10px;
}

.tactical-btn {
  background: linear-gradient(135deg, #0ea5e9, #2563eb);
  color: #fff;
  border: none;
  font-family: var(--font-tactical);
  font-size: 0.82rem;
  font-weight: 600;
  letter-spacing: 0.5px;
  padding: 8px 16px;
  border-radius: 8px;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  transition: all 0.2s ease;
  box-shadow: 0 4px 14px rgba(14, 165, 233, 0.3);
}

.tactical-btn:hover {
  filter: brightness(1.15);
  transform: translateY(-1px);
}

.tactical-btn.secondary {
  background: rgba(255, 255, 255, 0.07);
  border: 1px solid var(--border-subtle);
  box-shadow: none;
}

.tactical-btn.secondary:hover {
  background: rgba(255, 255, 255, 0.15);
  border-color: var(--border-glow);
}

/* ==========================================================================
   Main Stage Layout
   ========================================================================== */
#main-stage {
  flex: 1;
  position: relative;
  display: flex;
  overflow: hidden;
}

#map {
  flex: 1;
  height: 100%;
  width: 100%;
  background: #0d131a;
  z-index: 1;
}

/* Tactical Dark Recon Tile Filter (Dimmed Night-Vision / High-Contrast Satellite) */
.tactical-dark-tiles {
  filter: brightness(0.45) contrast(1.25) saturate(0.25) hue-rotate(175deg);
}

/* ==========================================================================
   Filter Dock (Floating Top Center Overlay)
   ========================================================================== */
#filter-dock {
  position: absolute;
  top: 16px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 500;
  background: rgba(13, 20, 30, 0.88);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border: 1px solid var(--border-subtle);
  border-radius: 12px;
  padding: 8px 16px;
  display: flex;
  align-items: center;
  gap: 14px;
  box-shadow: 0 12px 36px rgba(0, 0, 0, 0.6);
}

.filter-group {
  display: flex;
  align-items: center;
  gap: 6px;
}

.filter-label {
  font-family: var(--font-tactical);
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.8px;
  color: var(--text-muted);
  display: flex;
  align-items: center;
  gap: 5px;
  margin-right: 2px;
}

.filter-chip {
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid transparent;
  color: var(--text-muted);
  font-size: 0.78rem;
  font-weight: 500;
  padding: 5px 12px;
  border-radius: 6px;
  cursor: pointer;
  transition: all 0.2s;
  display: inline-flex;
  align-items: center;
  gap: 5px;
}

.filter-chip:hover {
  background: rgba(255, 255, 255, 0.12);
  color: #fff;
}

.filter-chip.active {
  background: rgba(0, 229, 255, 0.15);
  border-color: var(--accent-cyan);
  color: #fff;
  font-weight: 600;
  box-shadow: 0 0 10px rgba(0, 229, 255, 0.25);
}

.filter-chip.trophy-chip.active {
  background: rgba(245, 158, 11, 0.2);
  border-color: var(--c-nontypical);
  color: #fbbf24;
  box-shadow: 0 0 12px rgba(245, 158, 11, 0.35);
}

.divider {
  width: 1px;
  height: 22px;
  background: rgba(255, 255, 255, 0.15);
}

.search-box {
  display: flex;
  align-items: center;
  background: rgba(0, 0, 0, 0.3);
  border: 1px solid var(--border-subtle);
  border-radius: 6px;
  padding: 4px 10px;
  gap: 8px;
  color: var(--text-dim);
}

.search-box input {
  background: transparent;
  border: none;
  outline: none;
  color: #fff;
  font-size: 0.8rem;
  width: 170px;
}

.search-box input::placeholder {
  color: var(--text-dim);
}

/* ==========================================================================
   Map Control Buttons (Top Right Overlay)
   ========================================================================== */
#map-controls {
  position: absolute;
  top: 16px;
  right: calc(var(--sidebar-width) + 20px);
  z-index: 500;
  display: flex;
  flex-direction: column;
  gap: 8px;
  transition: right 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

.sidebar-collapsed #map-controls {
  right: 20px;
}

.map-ctrl-btn {
  width: 40px;
  height: 40px;
  background: rgba(13, 20, 30, 0.88);
  backdrop-filter: blur(10px);
  border: 1px solid var(--border-subtle);
  border-radius: 8px;
  color: var(--text-muted);
  font-size: 1rem;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.2s;
  box-shadow: 0 4px 16px rgba(0,0,0,0.4);
}

.map-ctrl-btn:hover {
  background: rgba(24, 35, 52, 0.95);
  color: #fff;
  border-color: var(--accent-cyan);
}

.map-ctrl-btn.active {
  color: var(--accent-cyan);
  border-color: var(--accent-cyan);
  box-shadow: 0 0 10px rgba(0, 229, 255, 0.3);
}

/* ==========================================================================
   Map Legend (Bottom Left)
   ========================================================================== */
#map-legend {
  position: absolute;
  bottom: 24px;
  left: 20px;
  z-index: 500;
  padding: 14px 18px;
  min-width: 250px;
  max-width: 310px;
  transition: padding 0.2s ease, min-width 0.2s ease;
}

#map-legend.legend-collapsed {
  min-width: auto;
  padding: 10px 14px;
}

.legend-header {
  width: 100%;
  background: transparent;
  border: none;
  font-family: var(--font-tactical);
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 1px;
  color: var(--text-muted);
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 10px;
  margin-bottom: 10px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
  padding-bottom: 6px;
  cursor: pointer;
  text-align: left;
}

.legend-header-right {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  flex-shrink: 0;
}

.legend-chevron {
  font-size: 0.7rem;
  color: var(--text-muted);
  transition: transform 0.2s ease;
}

#map-legend.legend-collapsed .legend-header {
  margin-bottom: 0;
  padding-bottom: 0;
  border-bottom: none;
}

#map-legend.legend-collapsed .legend-chevron {
  transform: rotate(180deg);
}

#map-legend.legend-collapsed .legend-items {
  display: none;
}

.legend-items {
  display: flex;
  flex-direction: column;
  gap: 7px;
}

.legend-item {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 0.78rem;
  color: #cbd5e1;
}

.marker-dot {
  width: 20px;
  height: 20px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.65rem;
  color: #fff;
  flex-shrink: 0;
}

.legend-shape {
  width: 22px;
  height: 24px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.65rem;
  flex-shrink: 0;
}

.legend-antler-svg {
  width: 14px;
  height: 14px;
  fill: #ffffff;
  filter: drop-shadow(0 1px 2px rgba(0,0,0,0.6));
}

.legend-pip-cyan .doe-inner-dot,
.legend-pip-orange .doe-inner-dot {
  width: 4px;
  height: 4px;
  border-radius: 50%;
  background: #ffffff;
}

.legend-shield-gold {
  background: linear-gradient(135deg, #fbbf24, #d97706);
  clip-path: polygon(50% 0%, 100% 25%, 100% 75%, 50% 100%, 0% 75%, 0% 25%);
  color: #000;
  box-shadow: 0 0 6px #fbbf24;
}

.legend-shield-green {
  background: linear-gradient(135deg, #38bdf8, #0284c7);
  clip-path: polygon(50% 0%, 100% 25%, 100% 75%, 50% 100%, 0% 75%, 0% 25%);
  color: #fff;
  box-shadow: 0 0 6px #38bdf8;
}

.legend-pip-cyan {
  width: 14px;
  height: 14px;
  border-radius: 50%;
  background: radial-gradient(circle, #38bdf8, #0284c7);
  border: 1.5px solid #fff;
  box-shadow: 0 0 6px #38bdf8;
  margin: 0 4px;
}

.legend-shield-orange {
  background: linear-gradient(135deg, #f97316, #c2410c);
  clip-path: polygon(50% 0%, 100% 25%, 100% 75%, 50% 100%, 0% 75%, 0% 25%);
  color: #fff;
}

.legend-pip-orange {
  width: 14px;
  height: 14px;
  border-radius: 50%;
  background: radial-gradient(circle, #fb923c, #ea580c);
  border: 1.5px solid #fff;
  box-shadow: 0 0 6px #fb923c;
  margin: 0 4px;
}

.legend-shield-red {
  background: linear-gradient(135deg, #ef4444, #991b1b);
  clip-path: polygon(50% 0%, 100% 25%, 100% 75%, 50% 100%, 0% 75%, 0% 25%);
  color: #fff;
}

.legend-disc-turkey {
  border-radius: 50%;
  background: #d97706;
  border: 1px solid #fef3c7;
  color: #fff;
}

.legend-disc-hogs {
  border-radius: 50%;
  background: linear-gradient(135deg, #b91c1c, #450a0a);
  border: 1.5px solid #fca5a5;
  color: #fff;
}

.perimeter-line {
  width: 20px;
  height: 3px;
  background: #facc15;
  border-radius: 2px;
  box-shadow: 0 0 8px #facc15;
}

.badge {
  background: rgba(255, 255, 255, 0.1);
  padding: 2px 8px;
  border-radius: 10px;
  font-size: 0.7rem;
  color: var(--accent-cyan);
  white-space: nowrap;
}

/* ==========================================================================
   Tactical Map Scale Control (Bottom Right)
   ========================================================================== */
.leaflet-control-scale {
  background: rgba(10, 14, 20, 0.9) !important;
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border: 1px solid rgba(0, 229, 255, 0.35);
  border-radius: 8px;
  padding: 5px 10px 7px;
  box-shadow: 0 6px 20px rgba(0, 0, 0, 0.65), inset 0 1px 0 rgba(255, 255, 255, 0.06);
  margin-right: 12px !important;
  margin-bottom: 12px !important;
  display: flex;
  flex-direction: column;
  align-items: center;
}

.leaflet-control-scale::before {
  content: 'SCALE';
  font-family: var(--font-tactical);
  font-size: 0.56rem;
  font-weight: 700;
  letter-spacing: 1.5px;
  color: var(--accent-cyan);
  margin-bottom: 3px;
  line-height: 1;
}

.leaflet-control-scale-line {
  background: linear-gradient(
    to top,
    rgba(0, 229, 255, 0.16) 0%,
    transparent 70%
  ) !important;
  border: none !important;
  border-left: 2px solid var(--accent-cyan) !important;
  border-right: 2px solid var(--accent-cyan) !important;
  border-bottom: 2px solid var(--accent-cyan) !important;
  border-radius: 0 0 2px 2px;
  color: #f8fafc !important;
  font-family: var(--font-tactical) !important;
  font-size: 0.72rem !important;
  font-weight: 700 !important;
  letter-spacing: 0.8px;
  line-height: 1.2 !important;
  padding: 1px 6px 3px !important;
  text-shadow: none !important;
  text-align: center;
  box-shadow: 0 3px 10px -2px rgba(0, 229, 255, 0.45);
}

/* ==========================================================================
   Custom Tactical Marker Architecture (Option 1 - Shape Hierarchy)
   ========================================================================== */

.survey-leaflet-icon {
  background: transparent !important;
  border: none !important;
}

.custom-survey-marker {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
}

/* 1. WHITETAIL NON-TYPICAL (Crest Shield + Gold Pulse) */
.shield-nontypical {
  width: 30px;
  height: 33px;
  background: linear-gradient(135deg, #fbbf24 0%, #d97706 50%, #78350f 100%);
  clip-path: polygon(50% 0%, 100% 25%, 100% 75%, 50% 100%, 0% 75%, 0% 25%);
  display: flex;
  align-items: center;
  justify-content: center;
  filter: drop-shadow(0 0 10px rgba(245, 158, 11, 0.9)) drop-shadow(0 4px 10px rgba(0,0,0,0.8));
  cursor: pointer;
  transition: transform 0.2s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

.shield-nontypical i {
  color: #000;
  font-size: 0.85rem;
  filter: drop-shadow(0 1px 2px rgba(255,255,255,0.6));
}

.shield-nontypical:hover {
  transform: scale(1.3);
  z-index: 9999 !important;
}

/* 2. WHITETAIL TYPICAL BUCK (Tactical Hex Shield + Antler Rack) */
.shield-buck {
  width: 25px;
  height: 28px;
  background: linear-gradient(135deg, #38bdf8 0%, #0284c7 100%);
  clip-path: polygon(50% 0%, 100% 25%, 100% 75%, 50% 100%, 0% 75%, 0% 25%);
  display: flex;
  align-items: center;
  justify-content: center;
  filter: drop-shadow(0 0 8px rgba(56, 189, 248, 0.8)) drop-shadow(0 4px 10px rgba(0,0,0,0.8));
  cursor: pointer;
  transition: transform 0.2s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

.shield-buck svg {
  width: 15px;
  height: 15px;
  fill: #fff;
  filter: drop-shadow(0 1px 2px rgba(0,0,0,0.6));
}

.shield-buck:hover {
  transform: scale(1.3);
  z-index: 9999 !important;
}

/* 3. WHITETAIL DOE (Clean Minimal Circular Pip - Prevents Clutter) */
.doe-pip {
  width: 22px;
  height: 22px;
  border-radius: 50%;
  background: radial-gradient(circle, #38bdf8 20%, #0284c7 100%);
  border: 2px solid #ffffff;
  box-shadow: 0 0 8px rgba(56, 189, 248, 0.7), 0 2px 6px rgba(0,0,0,0.7);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.2s;
}

.doe-pip .doe-inner-dot {
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: #ffffff;
}

.doe-pip:hover {
  transform: scale(1.5);
  box-shadow: 0 0 14px #38bdf8;
  z-index: 9999 !important;
}

/* 4. AXIS BUCK (Orange Hex Shield) */
.shield-axis-buck {
  width: 25px;
  height: 28px;
  background: linear-gradient(135deg, #f97316 0%, #c2410c 100%);
  clip-path: polygon(50% 0%, 100% 25%, 100% 75%, 50% 100%, 0% 75%, 0% 25%);
  display: flex;
  align-items: center;
  justify-content: center;
  filter: drop-shadow(0 0 8px rgba(249, 115, 22, 0.8)) drop-shadow(0 4px 10px rgba(0,0,0,0.8));
  cursor: pointer;
  transition: transform 0.2s;
}
.shield-axis-buck svg { width: 15px; height: 15px; fill: #fff; }
.shield-axis-buck:hover { transform: scale(1.3); z-index: 9999 !important; }

/* 5. AXIS DOE (Orange Pip) */
.pip-axis-doe {
  width: 22px;
  height: 22px;
  border-radius: 50%;
  background: radial-gradient(circle, #fb923c 20%, #ea580c 100%);
  border: 2px solid #ffffff;
  box-shadow: 0 0 8px rgba(251, 146, 60, 0.7);
  cursor: pointer;
  transition: all 0.2s;
  display: flex;
  align-items: center;
  justify-content: center;
}
.pip-axis-doe .doe-inner-dot { width: 5px; height: 5px; border-radius: 50%; background: #fff; }
.pip-axis-doe:hover { transform: scale(1.5); z-index: 9999 !important; }

/* 6. RED STAG BULL (Crimson Crown Crest) */
.shield-stag {
  width: 28px;
  height: 31px;
  background: linear-gradient(135deg, #ef4444 0%, #991b1b 100%);
  clip-path: polygon(50% 0%, 100% 25%, 100% 75%, 50% 100%, 0% 75%, 0% 25%);
  display: flex;
  align-items: center;
  justify-content: center;
  filter: drop-shadow(0 0 10px rgba(239, 68, 68, 0.9)) drop-shadow(0 6px 12px rgba(0,0,0,0.8));
  cursor: pointer;
  transition: transform 0.2s;
}
.shield-stag i { color: #fff; font-size: 0.8rem; }
.shield-stag:hover { transform: scale(1.3); z-index: 9999 !important; }

/* 7. TURKEY (Bronze Circular Disc + Feather) */
.disc-turkey {
  width: 26px;
  height: 26px;
  border-radius: 50%;
  background: linear-gradient(135deg, #d97706, #78350f);
  border: 2px solid #fef3c7;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  font-size: 0.75rem;
  box-shadow: 0 0 8px rgba(217, 119, 6, 0.8);
  cursor: pointer;
}
.disc-turkey:hover { transform: scale(1.3); z-index: 9999 !important; }

/* 8. HOGS (Standalone Charging Red Razorback Emblem) */
.emblem-razorback {
  width: 38px;
  height: 28px;
  display: flex;
  align-items: center;
  justify-content: center;
  filter: drop-shadow(0 0 10px rgba(220, 38, 38, 0.95)) drop-shadow(0 4px 8px rgba(0,0,0,0.85));
  cursor: pointer;
  transition: transform 0.2s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}
.emblem-razorback svg {
  width: 38px;
  height: 28px;
}
.emblem-razorback:hover {
  transform: scale(1.35);
  z-index: 9999 !important;
}

/* Custom Leaflet Tooltip */
.custom-marker-tooltip {
  background: rgba(13, 20, 30, 0.95) !important;
  border: 1px solid var(--accent-cyan) !important;
  color: #fff !important;
  font-family: var(--font-tactical) !important;
  font-size: 0.75rem !important;
  border-radius: 6px !important;
  padding: 4px 8px !important;
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.6) !important;
}
.custom-marker-tooltip:before {
  border-top-color: var(--accent-cyan) !important;
}

/* ==========================================================================
   Gallery Sidebar (Right)
   ========================================================================== */
#gallery-sidebar {
  width: var(--sidebar-width);
  height: 100%;
  background: rgba(10, 14, 20, 0.92);
  backdrop-filter: blur(16px);
  border-left: 1px solid var(--border-subtle);
  display: flex;
  flex-direction: column;
  z-index: 600;
  transition: transform 0.3s cubic-bezier(0.16, 1, 0.3, 1), margin-right 0.3s;
  flex-shrink: 0;
}

#gallery-sidebar.sidebar-closed {
  transform: translateX(100%);
  margin-right: calc(-1 * var(--sidebar-width));
}

.sidebar-header {
  padding: 16px 20px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-bottom: 1px solid var(--border-subtle);
}

.sidebar-title {
  font-family: var(--font-tactical);
  font-size: 0.88rem;
  font-weight: 700;
  letter-spacing: 1px;
  display: flex;
  align-items: center;
  gap: 10px;
  color: #fff;
}

.sidebar-subbar {
  padding: 8px 20px;
  background: rgba(255, 255, 255, 0.02);
  border-bottom: 1px solid var(--border-subtle);
  font-size: 0.75rem;
  color: var(--text-dim);
}

.icon-btn {
  background: transparent;
  border: none;
  color: var(--text-muted);
  cursor: pointer;
  font-size: 1rem;
  width: 32px;
  height: 32px;
  border-radius: 6px;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.2s;
}

.icon-btn:hover {
  background: rgba(255, 255, 255, 0.1);
  color: #fff;
}

.cards-list {
  flex: 1;
  min-height: 0;
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
  padding: 14px 16px;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

/* Custom Scrollbar */
.cards-list::-webkit-scrollbar {
  width: 6px;
}
.cards-list::-webkit-scrollbar-thumb {
  background: rgba(255, 255, 255, 0.15);
  border-radius: 3px;
}
.cards-list::-webkit-scrollbar-thumb:hover {
  background: rgba(255, 255, 255, 0.25);
}

/* Sighting Card */
.sighting-card {
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: 10px;
  overflow: hidden;
  cursor: pointer;
  transition: all 0.25s ease;
  display: flex;
  flex-direction: column;
  flex-shrink: 0;
}

.sighting-card:hover {
  transform: translateY(-2px);
  border-color: var(--accent-cyan);
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.5);
}

.sighting-card.card-nontypical {
  border-color: rgba(245, 158, 11, 0.4);
}
.sighting-card.card-nontypical:hover {
  border-color: var(--c-nontypical);
  box-shadow: 0 8px 24px rgba(245, 158, 11, 0.25);
}

.card-thumb-container {
  position: relative;
  width: 100%;
  height: 155px;
  overflow: hidden;
  background: #0b111a;
  flex-shrink: 0;
}

.card-thumb-container.no-photo {
  height: 115px;
  padding-top: 22px;
  background: rgba(15, 23, 42, 0.6);
  display: flex;
  align-items: center;
  justify-content: center;
}

.no-photo-placeholder {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
  color: var(--text-dim);
  font-size: 0.75rem;
}

.no-photo-placeholder i {
  font-size: 1.5rem;
  color: rgba(255, 255, 255, 0.15);
}

.multi-count-badge {
  font-family: var(--font-tactical);
  font-size: 0.65rem;
  font-weight: 700;
  padding: 3px 7px;
  border-radius: 4px;
  color: #fff;
  background: rgba(14, 165, 233, 0.8);
  backdrop-filter: blur(6px);
  display: inline-flex;
  align-items: center;
  gap: 4px;
}

.card-thumb-container img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.4s ease;
}

.sighting-card:hover .card-thumb-container img {
  transform: scale(1.05);
}

.card-badges {
  position: absolute;
  top: 8px;
  left: 8px;
  display: flex;
  gap: 6px;
}

.spec-badge {
  font-family: var(--font-tactical);
  font-size: 0.65rem;
  font-weight: 700;
  letter-spacing: 0.5px;
  padding: 3px 8px;
  border-radius: 4px;
  text-transform: uppercase;
  color: #fff;
  background: rgba(0, 0, 0, 0.7);
  backdrop-filter: blur(6px);
}

.spec-badge.badge-nontypical {
  background: var(--c-nontypical);
  color: #000;
  font-weight: 800;
}
.spec-badge.badge-wt { background: var(--c-wt-buck); }
.spec-badge.badge-axis { background: var(--c-axis-buck); }
.spec-badge.badge-stag { background: var(--c-stag-bull); }
.spec-badge.badge-turkey { background: var(--c-turkey); }
.spec-badge.badge-hogs { background: #334155; border: 1px solid #ef4444; }

.card-body {
  padding: 12px;
}

.card-title-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 4px;
}

.card-id {
  font-family: var(--font-tactical);
  font-size: 0.85rem;
  font-weight: 700;
  color: #fff;
}

.card-sex {
  font-size: 0.72rem;
  font-weight: 600;
  color: var(--text-muted);
}

.card-notes {
  font-size: 0.74rem;
  color: var(--text-muted);
  line-height: 1.4;
  margin-bottom: 8px;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.card-meta-row {
  display: flex;
  justify-content: space-between;
  font-size: 0.68rem;
  color: var(--text-dim);
  font-family: var(--font-tactical);
  border-top: 1px solid rgba(255, 255, 255, 0.05);
  padding-top: 6px;
}

/* ==========================================================================
   Photo Lightbox Modal
   ========================================================================== */
.lightbox-modal {
  position: fixed;
  top: var(--app-offset-top, 0px);
  left: 0;
  width: 100%;
  height: 100vh;
  height: 100dvh;
  height: var(--app-height, 100dvh);
  z-index: 2000;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 30px;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.25s ease;
}

.lightbox-modal.modal-active {
  opacity: 1;
  pointer-events: auto;
}

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

.lightbox-container {
  position: relative;
  z-index: 10;
  width: 95vw;
  max-width: 1280px;
  height: 85vh;
  height: 85dvh;
  max-height: calc(var(--app-height, 100dvh) - 60px);
  display: flex;
  flex-direction: column;
  overflow: hidden;
  border: 1px solid rgba(0, 229, 255, 0.3);
  box-shadow: 0 25px 60px rgba(0, 0, 0, 0.8), 0 0 30px rgba(0, 229, 255, 0.15);
}

.lightbox-header {
  min-height: 60px;
  height: auto;
  padding: 10px 24px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  border-bottom: 1px solid var(--border-subtle);
  background: rgba(13, 20, 30, 0.95);
  flex-shrink: 0;
}

.lightbox-title-area {
  display: flex;
  align-items: center;
  gap: 14px;
  min-width: 0;
}

.modal-map-btn .btn-label-mobile {
  display: none;
}

.lightbox-title-area h2 {
  font-family: var(--font-tactical);
  font-size: 1.15rem;
  font-weight: 700;
  color: #fff;
}

.meta-item {
  font-size: 0.75rem;
  color: var(--text-dim);
}

.lightbox-actions {
  display: flex;
  align-items: center;
  gap: 12px;
}

.lightbox-body {
  flex: 1;
  display: flex;
  overflow: hidden;
}

/* Lightbox Left: Image Stage */
.lightbox-photo-stage {
  flex: 1.5;
  background: #06090e;
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
}

.image-wrapper {
  position: relative;
  max-width: 100%;
  max-height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 16px;
}

.image-wrapper img {
  max-width: 100%;
  max-height: calc(85vh - 150px);
  object-fit: contain;
  border-radius: 8px;
  box-shadow: 0 10px 30px rgba(0,0,0,0.8);
}

#multi-photo-strip-container {
  position: absolute;
  bottom: 16px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 30;
}

.multi-photo-strip {
  display: flex;
  gap: 8px;
  background: rgba(10, 14, 20, 0.85);
  backdrop-filter: blur(8px);
  padding: 6px 12px;
  border-radius: 10px;
  border: 1px solid var(--border-glow);
}

.thumb-shot {
  width: 50px;
  height: 40px;
  object-fit: cover;
  border-radius: 5px;
  cursor: pointer;
  border: 2px solid transparent;
  opacity: 0.6;
  transition: all 0.2s;
}

.thumb-shot:hover {
  opacity: 1;
  transform: scale(1.08);
}

.thumb-shot.active {
  border-color: var(--accent-cyan);
  opacity: 1;
  box-shadow: 0 0 10px var(--accent-cyan);
}

.image-zoom-overlay {
  position: absolute;
  top: 26px;
  right: 26px;
}

.zoom-btn {
  background: rgba(0, 0, 0, 0.65);
  color: #fff;
  padding: 6px 12px;
  border-radius: 6px;
  text-decoration: none;
  font-size: 0.75rem;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  border: 1px solid rgba(255, 255, 255, 0.2);
  transition: all 0.2s;
}

.zoom-btn:hover {
  background: rgba(0, 229, 255, 0.3);
  border-color: var(--accent-cyan);
}

.modal-nav-btn {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  width: 44px;
  height: 44px;
  background: rgba(13, 20, 30, 0.75);
  border: 1px solid var(--border-subtle);
  border-radius: 50%;
  color: #fff;
  font-size: 1.1rem;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.2s;
  z-index: 20;
}

.modal-nav-btn:hover {
  background: var(--accent-cyan);
  color: #000;
  box-shadow: 0 0 15px rgba(0, 229, 255, 0.6);
}

.prev-btn { left: 16px; }
.next-btn { right: 16px; }

/* Lightbox Right: Intel Stage */
.lightbox-intel-stage {
  flex: 1;
  min-width: 0;
  background: rgba(13, 20, 30, 0.98);
  border-left: 1px solid var(--border-subtle);
  padding: 24px;
  display: flex;
  flex-direction: column;
  gap: 20px;
  overflow-y: auto;
  overflow-x: hidden;
}

.intel-section h3 {
  font-family: var(--font-tactical);
  font-size: 0.76rem;
  font-weight: 700;
  letter-spacing: 1.2px;
  color: var(--accent-cyan);
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 12px;
}

.intel-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}

.intel-grid.vertical {
  grid-template-columns: minmax(0, 1fr);
}

.intel-box {
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid var(--border-subtle);
  border-radius: 8px;
  padding: 10px 14px;
  display: flex;
  flex-direction: column;
  min-width: 0;
  max-width: 100%;
  overflow: hidden;
}

.intel-box.full-width {
  grid-column: 1 / -1;
}

.intel-box .lbl {
  font-size: 0.65rem;
  font-weight: 600;
  letter-spacing: 0.5px;
  color: var(--text-dim);
  margin-bottom: 4px;
}

.intel-box .val {
  font-size: 0.88rem;
  font-weight: 600;
  color: #fff;
  min-width: 0;
  max-width: 100%;
  overflow-wrap: anywhere;
  word-break: break-word;
}

.intel-box .val.highlight {
  color: var(--c-nontypical);
  font-family: var(--font-tactical);
  font-size: 1.05rem;
}

.intel-box .val.monospace {
  font-family: monospace;
  font-size: 0.8rem;
  color: #cbd5e1;
  word-break: break-all;
  overflow-wrap: anywhere;
}

.notes-box {
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid var(--border-subtle);
  border-radius: 8px;
  padding: 14px;
  font-size: 0.85rem;
  line-height: 1.5;
  color: #cbd5e1;
  min-height: 90px;
}

.intel-footer {
  margin-top: auto;
  padding-top: 16px;
  border-top: 1px solid var(--border-subtle);
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.status-indicator {
  font-size: 0.72rem;
  color: #10b981;
  display: flex;
  align-items: center;
  gap: 6px;
  font-family: var(--font-tactical);
}

.status-dot {
  width: 8px;
  height: 8px;
  background: #10b981;
  border-radius: 50%;
  box-shadow: 0 0 6px #10b981;
}

.photo-idx-counter {
  font-family: var(--font-tactical);
  font-size: 0.75rem;
  color: var(--text-dim);
}

/* ==========================================================================
   Mobile & Tablet Responsive Styles (iPhone, iPad, Android Field Use)
   ========================================================================== */
@media (max-width: 1180px) {
  #header-bar {
    height: auto;
    flex-wrap: wrap;
    padding: 10px 14px;
    gap: 10px;
  }
  .header-center {
    order: 3;
    width: 100%;
    overflow-x: auto;
    justify-content: flex-start;
    padding-bottom: 4px;
    scrollbar-width: none;
  }
  .header-center::-webkit-scrollbar {
    display: none;
  }
  .stat-pill {
    flex-shrink: 0;
  }
}

@media (max-width: 768px) {
  #header-bar {
    padding: max(12px, env(safe-area-inset-top)) max(12px, env(safe-area-inset-right)) 8px max(12px, env(safe-area-inset-left));
    gap: 8px;
  }
  .title-group h1 {
    font-size: 0.95rem;
  }
  .title-group .eyebrow {
    font-size: 0.58rem;
    letter-spacing: 0.8px;
  }
  .logo-badge {
    width: 38px;
    height: 38px;
  }
  .header-right .tactical-btn span {
    display: none;
  }
  .tactical-btn {
    padding: 8px 10px;
  }
  #filter-dock {
    top: 8px;
    left: 8px;
    right: 54px;
    transform: none;
    max-width: calc(100vw - 66px);
    overflow-x: auto;
    flex-wrap: nowrap;
    gap: 10px;
    padding: 6px 10px;
    scrollbar-width: none;
  }
  #filter-dock::-webkit-scrollbar {
    display: none;
  }
  .filter-group, .filter-label, .divider, .search-box {
    flex-shrink: 0;
    white-space: nowrap;
  }
  .filter-chip {
    flex-shrink: 0;
    white-space: nowrap;
    font-size: 0.72rem;
    padding: 5px 10px;
  }
  .search-box input {
    width: 115px;
  }
  #map-controls {
    top: 8px;
    right: 8px !important;
  }
  /* Keep Legend clear of bottom browser buttons, collapsed as a vertical tab on left */
  #map-legend {
    bottom: calc(34px + env(safe-area-inset-bottom));
    left: 8px;
    padding: 10px 12px;
    min-width: 205px;
    max-width: min(260px, calc(100vw - 24px));
  }
  #map-legend.legend-collapsed {
    width: 38px;
    min-width: 38px;
    max-width: 38px;
    padding: 12px 0;
    background: rgba(10, 14, 20, 0.94);
  }
  .legend-header {
    font-size: 0.7rem;
  }
  #map-legend.legend-collapsed .legend-header {
    writing-mode: horizontal-tb;
    transform: none;
    width: 100%;
    height: auto;
    padding: 0;
    display: flex;
    flex-direction: column-reverse;
    align-items: center;
    justify-content: center;
    gap: 8px;
  }
  #map-legend.legend-collapsed .legend-header-right {
    width: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
  }
  #map-legend.legend-collapsed .legend-title-label {
    writing-mode: vertical-rl;
    transform: rotate(180deg);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 18px;
    height: auto;
    line-height: 18px;
    white-space: nowrap;
    text-align: center;
    color: #f1f5f9;
  }
  #map-legend.legend-collapsed .legend-chevron {
    writing-mode: horizontal-tb;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    transform: rotate(-90deg);
  }
  .legend-items {
    gap: 5px;
    max-height: calc(var(--app-height, 100dvh) - 180px);
    overflow-y: auto;
  }
  .legend-item {
    font-size: 0.72rem;
    gap: 8px;
  }
  .leaflet-bottom.leaflet-right {
    bottom: calc(28px + env(safe-area-inset-bottom));
  }
  #gallery-sidebar {
    position: absolute;
    right: 0;
    top: 0;
    bottom: 0;
    width: 88vw;
    max-width: 360px;
    padding-bottom: env(safe-area-inset-bottom);
  }
  .lightbox-modal {
    padding: max(14px, env(safe-area-inset-top)) 8px max(68px, calc(16px + env(safe-area-inset-bottom))) 8px;
    align-items: center;
  }
  .lightbox-container {
    width: 100%;
    height: auto;
    max-height: 100%;
  }
  .lightbox-header {
    padding: 10px 12px;
    height: auto;
    min-height: 52px;
    gap: 8px;
  }
  .lightbox-title-area {
    flex-direction: column;
    align-items: flex-start;
    gap: 4px;
    flex: 1;
    min-width: 0;
  }
  .lightbox-title-area .spec-badge {
    white-space: nowrap;
    font-size: 0.6rem;
    padding: 2px 7px;
  }
  .lightbox-title-area h2 {
    font-size: 0.88rem;
    line-height: 1.25;
  }
  .lightbox-title-area .meta-item {
    display: none;
  }
  .lightbox-actions {
    gap: 6px;
    flex-shrink: 0;
  }
  .modal-map-btn {
    padding: 7px 10px !important;
    font-size: 0.74rem;
    white-space: nowrap;
  }
  .modal-map-btn .btn-label-desktop {
    display: none;
  }
  .modal-map-btn .btn-label-mobile {
    display: inline !important;
  }
  .lightbox-body {
    flex-direction: column;
    overflow-y: auto;
    overflow-x: hidden;
  }
  .lightbox-photo-stage {
    flex: none;
    height: 44dvh;
    min-height: 240px;
  }
  .image-wrapper img {
    max-height: 39dvh;
  }
  .lightbox-intel-stage {
    flex: none;
    border-left: none;
    border-top: 1px solid var(--border-subtle);
    padding: 14px;
    overflow-y: visible;
    overflow-x: hidden;
  }
  .intel-grid {
    grid-template-columns: minmax(0, 1fr);
  }
}

/* ==========================================================================
   Print / Client Executive Report Styles (Landscape Map + Deer Quantities)
   ========================================================================== */
@page {
  size: landscape;
  margin: 0;
}

/* Hide print-only summary page on interactive screen & pre-print staging */
#print-summary-page {
  display: none;
}

/* Pre-print staging mode so Leaflet computes bounds for exact Landscape paper dimensions */
body.print-preview-mode #app-container {
  width: 1056px !important;
  height: 816px !important;
  display: flex !important;
  flex-direction: column !important;
}

body.print-preview-mode .header-right,
body.print-preview-mode #filter-dock,
body.print-preview-mode #map-controls,
body.print-preview-mode #gallery-sidebar,
body.print-preview-mode #photo-lightbox {
  display: none !important;
}

body.print-preview-mode #header-bar {
  display: flex !important;
  flex-wrap: wrap !important;
  height: auto !important;
  background: #0a0e14 !important;
  border-bottom: 2px solid #00e5ff !important;
  padding: 10px 20px !important;
  gap: 8px !important;
  justify-content: space-between !important;
  align-items: center !important;
  flex-shrink: 0 !important;
}

body.print-preview-mode .header-center {
  display: flex !important;
  width: 100% !important;
  justify-content: space-between !important;
  gap: 8px !important;
  order: 3 !important;
}

body.print-preview-mode .stat-pill {
  flex: 1 !important;
  min-width: 0 !important;
  background: #101722 !important;
  border: 1px solid rgba(255, 255, 255, 0.22) !important;
  padding: 6px 8px !important;
}

body.print-preview-mode .stat-pill.trophy-pill {
  background: #241909 !important;
  border: 1.5px solid #f59e0b !important;
  box-shadow: none !important;
}

body.print-preview-mode #main-stage {
  flex: 1 1 auto !important;
  min-height: 0 !important;
  width: 100% !important;
}

@page {
  size: letter landscape;
  margin: 0;
}

@media print {
  html, body {
    position: static !important;
    top: auto !important;
    left: auto !important;
    width: 1056px !important;
    height: auto !important;
    min-height: 0 !important;
    overflow: visible !important;
    margin: 0 !important;
    padding: 0 !important;
    background: #0a0e14 !important;
    color: #f1f5f9 !important;
    -webkit-print-color-adjust: exact !important;
    print-color-adjust: exact !important;
  }

  /* Hide interactive-only buttons, filter bar, sidebar, and modals */
  .header-right,
  #filter-dock,
  #map-controls,
  #gallery-sidebar,
  #photo-lightbox {
    display: none !important;
  }

  #app-container {
    display: flex !important;
    flex-direction: column !important;
    width: 1056px !important;
    height: 815px !important;
    overflow: hidden !important;
    break-after: page !important;
    page-break-after: always !important;
  }

  /* Keep the Executive Header Bar with Ranch Title + All Deer Quantities */
  #header-bar {
    display: flex !important;
    flex-wrap: wrap !important;
    height: auto !important;
    background: #0a0e14 !important;
    border-bottom: 2px solid #00e5ff !important;
    padding: 10px 20px !important;
    gap: 8px !important;
    justify-content: space-between !important;
    align-items: center !important;
    flex-shrink: 0 !important;
  }

  .header-center {
    display: flex !important;
    width: 100% !important;
    justify-content: space-between !important;
    gap: 8px !important;
    order: 3 !important;
  }

  .stat-pill {
    flex: 1 !important;
    min-width: 0 !important;
    background: #101722 !important;
    border: 1px solid rgba(255, 255, 255, 0.22) !important;
    padding: 6px 8px !important;
  }

  .stat-pill.trophy-pill {
    background: #241909 !important;
    border: 1.5px solid #f59e0b !important;
    box-shadow: none !important;
  }

  #main-stage {
    flex: 1 1 auto !important;
    min-height: 0 !important;
    position: relative !important;
    width: 100% !important;
  }

  #map {
    width: 100% !important;
    height: 100% !important;
  }

  /* Keep dark background & full expanded horizontal layout on Survey Classification Legend */
  #map-legend,
  #map-legend.legend-collapsed {
    display: block !important;
    background: #0d141e !important;
    border: 1px solid rgba(255, 255, 255, 0.25) !important;
    color: #f1f5f9 !important;
    bottom: 16px !important;
    left: 16px !important;
    width: auto !important;
    padding: 14px 18px !important;
    min-width: 250px !important;
    max-width: none !important;
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.7) !important;
  }

  #map-legend .legend-header,
  #map-legend.legend-collapsed .legend-header {
    display: flex !important;
    flex-direction: row !important;
    justify-content: space-between !important;
    align-items: center !important;
    width: 100% !important;
    height: auto !important;
    margin-bottom: 10px !important;
    padding: 0 0 6px 0 !important;
    border-bottom: 1px solid rgba(255, 255, 255, 0.15) !important;
    color: #94a3b8 !important;
  }

  #map-legend .legend-title-label,
  #map-legend.legend-collapsed .legend-title-label {
    writing-mode: horizontal-tb !important;
    transform: none !important;
    width: auto !important;
    line-height: normal !important;
    text-align: left !important;
    color: #94a3b8 !important;
  }

  #map-legend .legend-items,
  #map-legend.legend-collapsed .legend-items {
    display: flex !important;
    max-height: none !important;
    overflow: visible !important;
  }

  .legend-chevron {
    display: none !important;
  }

  .legend-item {
    color: #f1f5f9 !important;
  }

  /* Print-Only Page 2: Executive Species Count Summary */
  #print-summary-page {
    display: flex !important;
    flex-direction: column !important;
    width: 1056px !important;
    height: 815px !important;
    padding: 28px 36px !important;
    background: #0a0e14 !important;
    color: #f1f5f9 !important;
    overflow: hidden !important;
    box-sizing: border-box !important;
    break-inside: avoid !important;
    page-break-inside: avoid !important;
  }

  .print-page-header {
    display: flex !important;
    justify-content: space-between !important;
    align-items: center !important;
    padding-bottom: 14px !important;
    margin-bottom: 18px !important;
    border-bottom: 2px solid #00e5ff !important;
    flex-shrink: 0 !important;
  }

  #print-ranch-title {
    font-family: var(--font-tactical) !important;
    font-size: 1.45rem !important;
    font-weight: 700 !important;
    letter-spacing: 0.8px !important;
    color: #ffffff !important;
    line-height: 1.1 !important;
  }

  .print-report-meta {
    display: flex !important;
    flex-direction: column !important;
    align-items: flex-end !important;
    gap: 5px !important;
  }

  .print-badge {
    font-family: var(--font-tactical) !important;
    font-size: 0.78rem !important;
    font-weight: 700 !important;
    letter-spacing: 1px !important;
    color: #00e5ff !important;
    background: rgba(0, 229, 255, 0.12) !important;
    border: 1px solid rgba(0, 229, 255, 0.45) !important;
    padding: 4px 12px !important;
    border-radius: 6px !important;
  }

  .print-meta-sub {
    font-size: 0.78rem !important;
    color: #94a3b8 !important;
  }

  .print-kpi-row {
    display: grid !important;
    grid-template-columns: repeat(3, minmax(0, 1fr)) !important;
    gap: 14px !important;
    margin-bottom: 18px !important;
    flex-shrink: 0 !important;
  }

  .print-kpi-card {
    background: #101722 !important;
    border: 1px solid rgba(255, 255, 255, 0.16) !important;
    border-radius: 10px !important;
    padding: 14px 18px !important;
    display: flex !important;
    flex-direction: column !important;
    gap: 3px !important;
  }

  .print-kpi-card.accent-cyan {
    border-color: rgba(0, 229, 255, 0.5) !important;
    background: #0d1d29 !important;
  }

  .print-kpi-lbl {
    font-family: var(--font-tactical) !important;
    font-size: 0.72rem !important;
    font-weight: 700 !important;
    letter-spacing: 0.8px !important;
    color: #94a3b8 !important;
  }

  .print-kpi-val {
    font-family: var(--font-tactical) !important;
    font-size: 2rem !important;
    font-weight: 700 !important;
    line-height: 1.1 !important;
    color: #ffffff !important;
  }

  .print-kpi-card.accent-cyan .print-kpi-val {
    color: #00e5ff !important;
  }

  .print-kpi-sub {
    font-size: 0.76rem !important;
    color: #cbd5e1 !important;
  }

  .print-table-card {
    background: #101722 !important;
    border: 1px solid rgba(255, 255, 255, 0.16) !important;
    border-radius: 12px !important;
    overflow: hidden !important;
    flex: 1 1 auto !important;
    min-height: 0 !important;
    display: flex !important;
    flex-direction: column !important;
  }

  .print-table-title-row {
    display: flex !important;
    justify-content: space-between !important;
    align-items: center !important;
    padding: 12px 18px !important;
    background: #0d141e !important;
    border-bottom: 1px solid rgba(255, 255, 255, 0.14) !important;
  }

  .print-table-title-row h3 {
    font-family: var(--font-tactical) !important;
    font-size: 0.92rem !important;
    font-weight: 700 !important;
    letter-spacing: 0.8px !important;
    color: #00e5ff !important;
    display: flex !important;
    align-items: center !important;
    gap: 8px !important;
  }

  .print-table-note {
    font-size: 0.75rem !important;
    color: #94a3b8 !important;
  }

  .print-species-table {
    width: 100% !important;
    border-collapse: collapse !important;
  }

  .print-species-table th {
    text-align: left !important;
    font-family: var(--font-tactical) !important;
    font-size: 0.72rem !important;
    font-weight: 700 !important;
    letter-spacing: 0.8px !important;
    color: #94a3b8 !important;
    padding: 10px 18px !important;
    background: #0e151f !important;
    border-bottom: 1px solid rgba(255, 255, 255, 0.12) !important;
  }

  .print-species-table th.num-col,
  .print-species-table td.num-col {
    text-align: right !important;
  }

  .print-species-table tbody tr {
    border-bottom: 1px solid rgba(255, 255, 255, 0.08) !important;
  }

  .print-species-table tbody td {
    padding: 12px 18px !important;
    font-size: 0.88rem !important;
    vertical-align: middle !important;
  }

  .print-species-cell {
    display: flex !important;
    align-items: center !important;
    gap: 10px !important;
  }

  .print-species-dot {
    width: 11px !important;
    height: 11px !important;
    border-radius: 50% !important;
    flex-shrink: 0 !important;
  }

  .print-species-name {
    font-weight: 600 !important;
    color: #ffffff !important;
    font-size: 0.94rem !important;
  }

  .print-row-tag {
    font-size: 0.68rem !important;
    font-weight: 600 !important;
    color: #7dd3fc !important;
    background: rgba(56, 189, 248, 0.14) !important;
    border: 1px solid rgba(56, 189, 248, 0.35) !important;
    padding: 2px 7px !important;
    border-radius: 999px !important;
  }

  .print-detail-cell {
    color: #cbd5e1 !important;
    font-size: 0.82rem !important;
  }

  .print-share-wrap {
    display: flex !important;
    align-items: center !important;
    gap: 10px !important;
  }

  .print-share-track {
    width: 150px !important;
    height: 8px !important;
    background: rgba(255, 255, 255, 0.1) !important;
    border-radius: 999px !important;
    overflow: hidden !important;
  }

  .print-share-fill {
    height: 100% !important;
    border-radius: 999px !important;
  }

  .print-share-pct {
    font-family: var(--font-tactical) !important;
    font-size: 0.84rem !important;
    font-weight: 600 !important;
    color: #cbd5e1 !important;
    min-width: 44px !important;
  }

  .print-count-cell {
    font-family: var(--font-tactical) !important;
    font-size: 1.25rem !important;
    font-weight: 700 !important;
    color: #ffffff !important;
  }

  .print-species-table tfoot td {
    padding: 13px 18px !important;
    background: #0d1d29 !important;
    border-top: 2px solid rgba(0, 229, 255, 0.45) !important;
  }

  .tfoot-label {
    font-family: var(--font-tactical) !important;
    font-size: 0.84rem !important;
    font-weight: 700 !important;
    letter-spacing: 0.8px !important;
    color: #00e5ff !important;
  }

  .tfoot-pct {
    font-family: var(--font-tactical) !important;
    font-size: 0.84rem !important;
    font-weight: 700 !important;
    color: #94a3b8 !important;
  }

  .tfoot-total {
    font-family: var(--font-tactical) !important;
    font-size: 1.4rem !important;
    font-weight: 700 !important;
    color: #00e5ff !important;
  }

  .print-page-footer {
    margin-top: 14px !important;
    padding-top: 10px !important;
    border-top: 1px solid rgba(255, 255, 255, 0.12) !important;
    display: flex !important;
    justify-content: space-between !important;
    align-items: center !important;
    font-size: 0.74rem !important;
    color: #94a3b8 !important;
    flex-shrink: 0 !important;
  }
}
