/* ═══════════════════════════════════════════════
   Kitsap Audubon – Where to Bird Map
   style.css

   Branding pulled from kitsapaudubon.org:
   - Dark navy header: #1a2b3c
   - Body white: #ffffff
   - Accent green: #4a7c59
   - Warm text: #333333
   - Muted bg: #f7f7f5
   - Orange CTA accent: #c8622a
   - Sand/warm rule: #e0d9cc
   Typography: Georgia (serif headings), system sans body
═══════════════════════════════════════════════ */

:root {
  --navy:        #1a2b3c;
  --navy-mid:    #243648;
  --green:       #4a7c59;
  --green-light: #e8f0eb;
  --orange:      #c8622a;
  --white:       #ffffff;
  --off-white:   #f7f7f5;
  --rule:        #e0d9cc;
  --text:        #333333;
  --text-mid:    #555555;
  --text-light:  #888888;
  --panel-w:     420px;
  --header-h:    56px;
  --footer-h:    38px;
  --transition:  0.25s ease;
  --radius:      6px;
  --shadow:      0 2px 16px rgba(0,0,0,0.12);
  --shadow-lg:   0 4px 32px rgba(0,0,0,0.16);
}

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

html, body {
  height: 100%;
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Helvetica, Arial, sans-serif;
  font-size: 15px;
  color: var(--text);
  background: var(--white);
  overflow: hidden;
}

a { color: var(--green); text-decoration: none; }
a:hover { text-decoration: underline; }

/* ─── HEADER ─────────────────────────────────── */
.site-header {
  height: var(--header-h);
  background: var(--navy);
  display: flex;
  align-items: center;
  padding: 0 1.25rem;
  box-shadow: 0 2px 8px rgba(0,0,0,0.3);
  z-index: 1000;
  position: relative;
  flex-shrink: 0;
}

.header-logo {
  display: flex;
  align-items: center;
  gap: 0.65rem;
}

.logo-img {
  width: 36px;
  height: 36px;
  object-fit: contain;
  border-radius: 3px;
  flex-shrink: 0;
}

.logo-text {
  font-family: Georgia, 'Times New Roman', serif;
  font-size: 1.05rem;
  font-weight: normal;
  letter-spacing: 0.02em;
  color: var(--white);
}

/* ─── LAYOUT ─────────────────────────────────── */
.map-layout {
  display: flex;
  height: calc(100vh - var(--header-h) - var(--footer-h));
  position: relative;
}

/* ─── MAP ────────────────────────────────────── */
#map {
  flex: 1;
  z-index: 1;
  background: #e8ecef;
}

/* ─── LEAFLET OVERRIDES ──────────────────────── */
.site-tooltip {
  background: var(--navy) !important;
  color: var(--white) !important;
  border: none !important;
  border-radius: 4px !important;
  padding: 4px 9px !important;
  font-size: 0.78rem !important;
  font-weight: 600 !important;
  box-shadow: 0 2px 6px rgba(0,0,0,0.25) !important;
  white-space: nowrap !important;
}
.site-tooltip::before { border-top-color: var(--navy) !important; }

.leaflet-control-attribution {
  font-size: 0.65rem !important;
  background: rgba(255,255,255,0.8) !important;
}

/* ─── BIRD MARKER ────────────────────────────── */
.bird-marker { background: none !important; border: none !important; }

.marker-pin {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  overflow: hidden;
  border: 2px solid var(--navy);
  box-shadow: 0 2px 8px rgba(0,0,0,0.3);
  cursor: pointer;
  transition: transform var(--transition), box-shadow var(--transition);
  background: var(--white);
}
.marker-pin img { width: 100%; height: 100%; object-fit: cover; display: block; }
.marker-pin:hover {
  transform: scale(1.18);
  box-shadow: 0 4px 14px rgba(0,0,0,0.4);
}

/* ─── DETAIL PANEL ───────────────────────────── */
.detail-panel {
  width: 0;
  overflow: hidden;
  overflow-y: auto;
  background: var(--white);
  border-left: 1px solid var(--rule);
  box-shadow: var(--shadow-lg);
  transition: width var(--transition);
  z-index: 10;
  flex-shrink: 0;
  outline: none;
  display: flex;
  flex-direction: column;
}
.detail-panel.open { width: var(--panel-w); }

/* ─── PANEL HEADER ───────────────────────────── */
.panel-header {
  background: var(--navy);
  color: var(--white);
  position: sticky;
  top: 0;
  z-index: 20;
  display: flex;
  align-items: flex-start;
  gap: 0.5rem;
  padding: 0.9rem 0.75rem 0.9rem 1.25rem;
  flex-shrink: 0;
}

.panel-header-text { flex: 1; min-width: 0; }

.panel-header h2 {
  font-family: Georgia, 'Times New Roman', serif;
  font-size: 1.2rem;
  font-weight: normal;
  line-height: 1.25;
  color: var(--white);
}

.panel-area {
  font-size: 0.7rem;
  font-weight: 600;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: rgba(255,255,255,0.55);
  margin-top: 0.25rem;
}

.panel-close {
  flex-shrink: 0;
  background: rgba(255,255,255,0.12);
  border: none;
  color: var(--white);
  cursor: pointer;
  width: 28px;
  height: 28px;
  border-radius: 50%;
  font-size: 1.2rem;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background var(--transition);
  margin-top: 2px;
}
.panel-close:hover { background: rgba(255,255,255,0.25); }

/* ─── DIRECTIONS BAR ─────────────────────────── */
.directions-bar {
  padding: 0.6rem 1.25rem;
  background: var(--off-white);
  border-bottom: 1px solid var(--rule);
  display: flex;
  gap: 0.5rem;
  flex-wrap: wrap;
}

.directions-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  background: var(--orange);
  color: var(--white);
  font-size: 0.82rem;
  font-weight: 600;
  letter-spacing: 0.02em;
  padding: 0.45rem 0.9rem;
  border-radius: var(--radius);
  text-decoration: none;
  transition: background var(--transition), transform var(--transition);
  box-shadow: 0 1px 4px rgba(0,0,0,0.15);
}
.directions-btn svg { width: 13px; height: 13px; flex-shrink: 0; }
.directions-btn:hover {
  background: #b35522;
  transform: translateY(-1px);
  text-decoration: none;
}

.learn-more-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  background: var(--navy);
  color: var(--white);
  font-size: 0.82rem;
  font-weight: 600;
  letter-spacing: 0.02em;
  padding: 0.45rem 0.9rem;
  border-radius: var(--radius);
  text-decoration: none;
  transition: background var(--transition), transform var(--transition);
  box-shadow: 0 1px 4px rgba(0,0,0,0.15);
}
.learn-more-btn svg { width: 13px; height: 13px; flex-shrink: 0; }
.learn-more-btn:hover {
  background: var(--navy-mid);
  transform: translateY(-1px);
  text-decoration: none;
}

/* ─── SLIDESHOW ──────────────────────────────── */
.slideshow-wrap {
  position: relative;
  background: #1a1a1a;
  width: 100%;
  height: 210px;
  overflow: hidden;
  flex-shrink: 0;
}
.slideshow { width: 100%; height: 100%; position: relative; }

/* Smart image fitting — object-fit cover keeps consistent box,
   object-position center focuses on subject */
.slide-img {
  position: absolute; inset: 0;
  width: 100%; height: 100%;
  object-fit: cover;
  object-position: center;
  opacity: 0;
  transition: opacity 0.45s ease;
  /* Subtle sharpening via filter for low-quality uploads */
  image-rendering: auto;
}
.slide-img.active { opacity: 1; }

/* Gradient vignette at bottom for readability */
.slideshow::after {
  content: '';
  position: absolute;
  bottom: 0; left: 0; right: 0;
  height: 60px;
  background: linear-gradient(transparent, rgba(0,0,0,0.35));
  pointer-events: none;
  z-index: 1;
}

.slide-btn {
  position: absolute;
  top: 50%; transform: translateY(-50%);
  background: rgba(26,43,60,0.65);
  color: var(--white);
  border: none;
  width: 30px; height: 30px;
  border-radius: 50%;
  font-size: 1rem;
  display: flex; align-items: center; justify-content: center;
  cursor: pointer; z-index: 2;
  transition: background var(--transition);
}
.slide-btn:hover { background: var(--navy); }
.slide-prev { left: 0.5rem; }
.slide-next { right: 0.5rem; }

.slide-dots {
  position: absolute; bottom: 0.4rem; left: 50%;
  transform: translateX(-50%);
  display: flex; gap: 5px; z-index: 2;
}
.dot {
  width: 6px; height: 6px; border-radius: 50%;
  background: rgba(255,255,255,0.4);
  border: none; cursor: pointer; padding: 0;
  transition: background var(--transition), transform var(--transition);
}
.dot.active { background: var(--white); transform: scale(1.35); }

/* Expand button — bottom-right corner of slideshow */
.expand-btn {
  position: absolute;
  bottom: 0.5rem;
  right: 0.5rem;
  background: rgba(26,43,60,0.65);
  border: none;
  color: var(--white);
  width: 28px; height: 28px;
  border-radius: 5px;
  display: flex; align-items: center; justify-content: center;
  cursor: pointer;
  z-index: 3;
  transition: background var(--transition);
}
.expand-btn:hover { background: var(--navy); }
.expand-btn svg { width: 14px; height: 14px; }

/* ─── LIGHTBOX ───────────────────────────────── */
.lightbox {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.92);
  z-index: 9999;
  align-items: center;
  justify-content: center;
  flex-direction: column;
}
.lightbox.open { display: flex; }

.lightbox-img-wrap {
  max-width: 92vw;
  max-height: 82vh;
  display: flex;
  align-items: center;
  justify-content: center;
}

#lightbox-img {
  max-width: 92vw;
  max-height: 82vh;
  object-fit: contain;
  border-radius: 4px;
  box-shadow: 0 8px 40px rgba(0,0,0,0.6);
  /* Auto-enhance: slight contrast boost for variable quality photos */
  filter: contrast(1.03) saturate(1.05);
}

.lightbox-close {
  position: absolute;
  top: 1rem; right: 1.25rem;
  background: none;
  border: none;
  color: rgba(255,255,255,0.8);
  font-size: 2rem;
  cursor: pointer;
  line-height: 1;
  transition: color var(--transition);
  z-index: 2;
}
.lightbox-close:hover { color: var(--white); }

.lightbox-nav {
  position: absolute;
  top: 50%; transform: translateY(-50%);
  background: rgba(255,255,255,0.12);
  border: none;
  color: var(--white);
  font-size: 1.5rem;
  width: 44px; height: 44px;
  border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  cursor: pointer;
  transition: background var(--transition);
  z-index: 2;
}
.lightbox-nav:hover { background: rgba(255,255,255,0.25); }
.lightbox-prev { left: 1rem; }
.lightbox-next { right: 1rem; }

.lightbox-caption {
  color: rgba(255,255,255,0.55);
  font-size: 0.8rem;
  margin-top: 0.75rem;
  letter-spacing: 0.05em;
}



/* ─── PANEL SECTIONS ─────────────────────────── */
.panel-section {
  padding: 1rem 1.25rem;
  border-bottom: 1px solid var(--rule);
}
.panel-section:last-child { border-bottom: none; }

.section-label {
  font-size: 0.65rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--green);
  margin-bottom: 0.55rem;
}

#panel-description {
  font-size: 0.88rem;
  line-height: 1.7;
  color: var(--text);
}

/* ─── ACCESSIBILITY ──────────────────────────── */
.access-list { list-style: none; display: flex; flex-direction: column; gap: 0.4rem; }
.access-list li {
  display: flex; align-items: baseline; gap: 0.4rem;
  font-size: 0.84rem; line-height: 1.4;
}
.access-icon { font-size: 0.9rem; width: 1.3rem; text-align: center; flex-shrink: 0; }
.access-label { font-weight: 600; color: var(--navy); flex-shrink: 0; }

/* ─── YOUTUBE ────────────────────────────────── */
.youtube-wrap {
  width: 100%;
  border-radius: var(--radius);
  overflow: hidden;
  background: #000;
  aspect-ratio: 16 / 9;
}
.youtube-wrap iframe { width: 100%; height: 100%; border: none; display: block; }

/* ─── INCOMPLETE SITE MARKER ─────────────────── */
.marker-incomplete {
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background: #aab0b8;
  border: 2px solid #fff;
  box-shadow: 0 1px 4px rgba(0,0,0,0.25);
  cursor: default;
}

.site-tooltip--incomplete {
  background: #6b7280 !important;
  color: rgba(255,255,255,0.85) !important;
}
.site-tooltip--incomplete::before {
  border-top-color: #6b7280 !important;
}

.tooltip-coming-soon {
  font-size: 0.65rem;
  font-style: italic;
  opacity: 0.75;
  margin-left: 0.25rem;
}

/* ─── RARITIES DRAWER (left side) ───────────── */
.rarities-drawer {
  width: 0;
  overflow: hidden;
  background: var(--white);
  border-right: 1px solid var(--rule);
  box-shadow: 2px 0 16px rgba(0,0,0,0.1);
  transition: width var(--transition);
  z-index: 10;
  flex-shrink: 0;
  display: flex;
  flex-direction: column;
  outline: none;
}
.rarities-drawer.open {
  width: 300px;
  overflow-y: auto;
}

.rarities-drawer-header {
  background: #c0392b;
  color: var(--white);
  padding: 0.85rem 1rem;
  position: sticky;
  top: 0;
  z-index: 5;
  flex-shrink: 0;
}
.rarities-drawer-title {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  margin-bottom: 0.2rem;
}
.rarities-drawer-title h2 {
  font-family: Georgia, serif;
  font-size: 0.95rem;
  font-weight: normal;
  color: var(--white);
  line-height: 1.2;
}
.rarities-drawer-meta {
  font-size: 0.68rem;
  color: rgba(255,255,255,0.7);
  letter-spacing: 0.03em;
}

.rarities-drawer-loading {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  padding: 1rem;
  font-size: 0.82rem;
  color: var(--text-light);
}

.rarities-drawer-list {
  list-style: none;
  flex: 1;
  overflow-y: auto;
}

.rarity-row {
  padding: 0.7rem 1rem;
  border-bottom: 1px solid var(--rule);
  cursor: pointer;
  transition: background var(--transition);
}
.rarity-row:hover { background: var(--off-white); }
.rarity-row:last-child { border-bottom: none; }

.rarity-row-name {
  font-weight: 700;
  font-size: 0.86rem;
  color: var(--text);
  margin-bottom: 0.1rem;
}
.rarity-row-sci {
  font-style: italic;
  font-size: 0.72rem;
  color: var(--text-light);
  margin-bottom: 0.3rem;
}
.rarity-row-meta {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.3rem 0.5rem;
}
.rarity-row-loc {
  font-size: 0.74rem;
  color: var(--text-mid);
  display: flex;
  align-items: center;
  gap: 0.2rem;
}
.rarity-row-date {
  font-size: 0.7rem;
  color: var(--text-light);
  margin-left: auto;
  white-space: nowrap;
}
.rarity-row-count {
  background: var(--navy);
  color: var(--white);
  font-size: 0.65rem;
  font-weight: 700;
  padding: 1px 5px;
  border-radius: 10px;
}

.rarities-drawer-empty {
  padding: 1.5rem 1rem;
  font-size: 0.84rem;
  color: var(--text-light);
  font-style: italic;
  text-align: center;
}

/* Scrollbar for drawer */
.rarities-drawer::-webkit-scrollbar { width: 4px; }
.rarities-drawer::-webkit-scrollbar-track { background: transparent; }
.rarities-drawer::-webkit-scrollbar-thumb { background: rgba(0,0,0,0.12); border-radius: 2px; }

/* Mobile: drawer becomes top strip */
@media (max-width: 767px) {
  .rarities-drawer {
    width: 100% !important;
    max-height: 0;
    border-right: none;
    border-bottom: 1px solid var(--rule);
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
    transition: max-height var(--transition);
    overflow: hidden;
  }
  .rarities-drawer.open {
    width: 100% !important;
    max-height: 45vh;
    overflow-y: auto;
  }
}

/* ─── MAP LAYER TOGGLE CONTROLS ──────────────── */
.map-layer-controls {
  margin-top: 0.5rem;
}

.layer-toggle-group {
  background: var(--white);
  border-radius: var(--radius);
  box-shadow: 0 2px 8px rgba(0,0,0,0.18);
  overflow: hidden;
  display: flex;
  flex-direction: column;
}

.layer-toggle {
  display: flex;
  align-items: center;
  gap: 0.45rem;
  padding: 0.5rem 0.75rem;
  font-size: 0.75rem;
  font-weight: 600;
  background: var(--white);
  border: none;
  border-bottom: 1px solid var(--rule);
  cursor: pointer;
  color: var(--text-mid);
  transition: background var(--transition), color var(--transition);
  white-space: nowrap;
  text-align: left;
}
.layer-toggle:last-of-type { border-bottom: none; }
.layer-toggle:hover { background: var(--off-white); color: var(--text); }
.layer-toggle.active { background: var(--off-white); color: var(--text); }
.layer-toggle.active .layer-dot { opacity: 1; }

.layer-dot {
  width: 10px; height: 10px;
  border-radius: 50%;
  flex-shrink: 0;
  opacity: 0.45;
  transition: opacity var(--transition);
}
.layer-dot--rarity { background: #c0392b; }

.layer-status {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  padding: 0.4rem 0.75rem;
  font-size: 0.7rem;
  color: var(--text-light);
  border-top: 1px solid var(--rule);
}

.layer-spinner {
  width: 12px; height: 12px;
  border: 2px solid var(--rule);
  border-top-color: var(--green);
  border-radius: 50%;
  animation: spin 0.7s linear infinite;
  flex-shrink: 0;
  display: inline-block;
}

/* ─── LAYER MARKERS ──────────────────────────── */
.layer-marker {
  width: 14px; height: 14px;
  border-radius: 50%;
  border: 2px solid rgba(255,255,255,0.9);
  box-shadow: 0 1px 4px rgba(0,0,0,0.35);
  cursor: pointer;
  transition: transform 0.15s ease;
}
.layer-marker:hover { transform: scale(1.3); }
.layer-marker--rarity { background: #c0392b; }

/* ─── LAYER POPUPS ───────────────────────────── */
.layer-popup { font-family: inherit; min-width: 160px; }
.popup-name  { font-weight: 700; font-size: 0.88rem; color: var(--text); margin-bottom: 0.1rem; }
.popup-sci   { font-style: italic; font-size: 0.73rem; color: var(--text-light); margin-bottom: 0.35rem; }
.popup-meta  { display: flex; align-items: center; gap: 0.3rem; flex-wrap: wrap; margin-bottom: 0.3rem; }
.popup-loc   { font-size: 0.75rem; color: var(--text-mid); }
.popup-count {
  background: var(--navy); color: var(--white);
  font-size: 0.68rem; font-weight: 700;
  padding: 1px 5px; border-radius: 10px;
}
.popup-date  { font-size: 0.72rem; color: var(--text-light); }

/* ─── EBIRD RANGE PILLS ──────────────────────── */
.ebird-range-row {
  display: flex;
  gap: 0.35rem;
  margin-bottom: 0.75rem;
}

.range-pill {
  flex: 1;
  padding: 0.3rem 0;
  font-size: 0.75rem;
  font-weight: 600;
  border: 1px solid var(--rule);
  border-radius: 20px;
  background: var(--white);
  color: var(--text-mid);
  cursor: pointer;
  transition: all var(--transition);
  text-align: center;
}
.range-pill:hover {
  border-color: var(--navy);
  color: var(--navy);
}
.range-pill.active {
  background: var(--navy);
  border-color: var(--navy);
  color: var(--white);
}

/* ─── EBIRD TABS ─────────────────────────────── */
.ebird-tabs {
  display: flex;
  border-bottom: 2px solid var(--rule);
  margin-bottom: 0.75rem;
  gap: 0;
}

.ebird-tab {
  flex: 1;
  padding: 0.45rem 0.25rem;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.02em;
  border: none;
  background: none;
  color: var(--text-light);
  cursor: pointer;
  border-bottom: 2px solid transparent;
  margin-bottom: -2px;
  transition: color var(--transition), border-color var(--transition);
  white-space: nowrap;
  text-align: center;
}
.ebird-tab:hover { color: var(--navy); }
.ebird-tab.active {
  color: var(--navy);
  border-bottom-color: var(--orange);
}

/* ─── EBIRD PANES ────────────────────────────── */
.ebird-pane-empty {
  font-size: 0.82rem;
  color: var(--text-light);
  font-style: italic;
  padding: 0.5rem 0;
}


.ebird-loading {
  display: flex; align-items: center; gap: 0.5rem;
  color: var(--text-light); font-size: 0.82rem;
  padding: 0.3rem 0;
}
.spinner {
  width: 16px; height: 16px;
  border: 2px solid var(--rule);
  border-top-color: var(--green);
  border-radius: 50%;
  animation: spin 0.7s linear infinite;
  flex-shrink: 0;
}
@keyframes spin { to { transform: rotate(360deg); } }

.ebird-none { font-size: 0.82rem; color: var(--text-light); font-style: italic; padding: 0.3rem 0; }
.ebird-content { display: flex; flex-direction: column; gap: 0.85rem; }

.ebird-block-title {
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--navy);
  margin-bottom: 0.35rem;
  padding-bottom: 0.25rem;
  border-bottom: 1px solid var(--rule);
}

.ebird-list { list-style: none; display: flex; flex-direction: column; gap: 0.25rem; }

.ebird-item {
  font-size: 0.8rem;
  line-height: 1.4;
  padding: 0.3rem 0.5rem;
  border-radius: 4px;
  background: var(--off-white);
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 0.3rem;
}
.obs-name { font-weight: 600; color: var(--text); }
.obs-sci { font-style: italic; font-size: 0.72rem; color: var(--text-light); }
.obs-count {
  background: var(--navy); color: var(--white);
  font-size: 0.68rem; font-weight: 700;
  padding: 1px 5px; border-radius: 10px;
}
.obs-date { font-size: 0.7rem; color: var(--text-light); margin-left: auto; white-space: nowrap; }
.obs-badge {
  font-size: 0.64rem; font-weight: 700;
  padding: 1px 5px; border-radius: 10px;
  text-transform: uppercase; letter-spacing: 0.04em;
}
.badge-rare { background: #c0392b; color: #fff; }

.ebird-external-link {
  display: inline-block;
  margin-top: 0.65rem;
  font-size: 0.78rem;
  font-weight: 600;
  color: var(--green);
}
.ebird-external-link:hover { text-decoration: underline; }

/* ─── FOOTER ─────────────────────────────────── */
.site-footer {
  height: var(--footer-h);
  background: var(--navy);
  color: rgba(255,255,255,0.5);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.7rem;
  flex-shrink: 0;
  letter-spacing: 0.02em;
}
.site-footer a { color: rgba(255,255,255,0.7); }
.site-footer a:hover { color: var(--white); }

/* ═══════════════════════════════════════════════
   MOBILE — panel becomes full-width bottom sheet
═══════════════════════════════════════════════ */
@media (max-width: 767px) {
  html, body { overflow: auto; }

  .map-layout {
    flex-direction: column;
    height: auto;
  }

  #map {
    height: 52vw;
    min-height: 260px;
    width: 100%;
  }

  .detail-panel {
    width: 100% !important;
    max-height: 0;
    overflow: hidden;
    border-left: none;
    border-top: 2px solid var(--navy);
    transition: max-height 0.35s ease;
    box-shadow: none;
  }
  .detail-panel.open {
    width: 100% !important;
    max-height: 9999px;
    overflow-y: auto;
  }

  .logo-text { font-size: 0.9rem; }

  .ebird-controls { gap: 0.35rem; }
}

@media (max-width: 900px) and (min-width: 768px) {
  :root { --panel-w: 360px; }
}

/* ─── SCROLLBAR ──────────────────────────────── */
.detail-panel::-webkit-scrollbar { width: 4px; }
.detail-panel::-webkit-scrollbar-track { background: transparent; }
.detail-panel::-webkit-scrollbar-thumb { background: rgba(0,0,0,0.15); border-radius: 2px; }
.detail-panel::-webkit-scrollbar-thumb:hover { background: rgba(0,0,0,0.28); }