/* ============================================
   7-11 ONE PIECE MAP — Dark Cyberpunk-Pirate
   ============================================ */

/* ---------- Design Tokens ---------- */
:root {
  --bg-primary: #0a0e17;
  --bg-secondary: #111827;
  --bg-tertiary: #1a2236;
  --bg-glass: rgba(17, 24, 39, 0.82);
  --bg-glass-heavy: rgba(10, 14, 23, 0.92);
  --border-glass: rgba(255, 255, 255, 0.07);
  --border-glass-hover: rgba(255, 255, 255, 0.14);

  --text-primary: #f0f4f8;
  --text-secondary: #8b9dc3;
  --text-muted: #4a5e80;

  --accent-op15: #ff6b35;
  --accent-op16: #00d4ff;
  --accent-both: #a855f7;
  --accent-gold: #fbbf24;

  --glow-op15: rgba(255, 107, 53, 0.45);
  --glow-op16: rgba(0, 212, 255, 0.45);
  --glow-both: rgba(168, 85, 247, 0.35);

  --radius-sm: 8px;
  --radius-md: 14px;
  --radius-lg: 22px;
  --radius-full: 999px;

  --shadow-sm: 0 2px 8px rgba(0, 0, 0, 0.25);
  --shadow-md: 0 8px 30px rgba(0, 0, 0, 0.4);
  --shadow-lg: 0 16px 60px rgba(0, 0, 0, 0.55);
  --shadow-glow-op15: 0 0 20px var(--glow-op15), 0 0 60px rgba(255, 107, 53, 0.15);
  --shadow-glow-op16: 0 0 20px var(--glow-op16), 0 0 60px rgba(0, 212, 255, 0.15);

  --font-display: 'Outfit', system-ui, sans-serif;
  --font-body: 'DM Sans', system-ui, sans-serif;

  --ease-out-expo: cubic-bezier(0.16, 1, 0.3, 1);
  --ease-spring: cubic-bezier(0.34, 1.56, 0.64, 1);

  --safe-bottom: env(safe-area-inset-bottom, 0px);
  --safe-top: env(safe-area-inset-top, 0px);
  --safe-left: env(safe-area-inset-left, 0px);
  --safe-right: env(safe-area-inset-right, 0px);
}

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

html, body {
  height: 100%;
  overflow: hidden;
  font-family: var(--font-body);
  font-weight: 400;
  color: var(--text-primary);
  background: var(--bg-primary);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  -webkit-tap-highlight-color: transparent;
}

/* Prevent pull-to-refresh on mobile */
body {
  overscroll-behavior: none;
}

/* ---------- Scrollbar ---------- */
::-webkit-scrollbar {
  width: 5px;
}
::-webkit-scrollbar-track {
  background: transparent;
}
::-webkit-scrollbar-thumb {
  background: rgba(255, 255, 255, 0.12);
  border-radius: 10px;
}
::-webkit-scrollbar-thumb:hover {
  background: rgba(255, 255, 255, 0.22);
}

/* ---------- App Shell ---------- */
#app {
  position: relative;
  width: 100%;
  height: 100%;
  overflow: hidden;
}

#map {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
}

/* ---------- Animations ---------- */
@keyframes fadeIn {
  from { opacity: 0; }
  to { opacity: 1; }
}
@keyframes fadeOut {
  from { opacity: 1; }
  to { opacity: 0; }
}
@keyframes slideUp {
  from { transform: translateY(100%); opacity: 0; }
  to { transform: translateY(0); opacity: 1; }
}
@keyframes slideDown {
  from { transform: translateY(0); opacity: 1; }
  to { transform: translateY(100%); opacity: 0; }
}
@keyframes slideInLeft {
  from { transform: translateX(-24px); opacity: 0; }
  to { transform: translateX(0); opacity: 1; }
}
@keyframes pulse {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.5; }
}
@keyframes glowPulse {
  0%, 100% { box-shadow: 0 0 6px var(--accent-op16); }
  50% { box-shadow: 0 0 24px var(--accent-op16), 0 0 48px rgba(0, 212, 255, 0.2); }
}
@keyframes glowPulseOP15 {
  0%, 100% { box-shadow: 0 0 6px var(--accent-op15); }
  50% { box-shadow: 0 0 24px var(--accent-op15), 0 0 48px rgba(255, 107, 53, 0.2); }
}
@keyframes shimmer {
  0% { background-position: -200% 0; }
  100% { background-position: 200% 0; }
}
@keyframes skullFloat {
  0%, 100% { transform: translateY(0) rotate(0deg); }
  50% { transform: translateY(-8px) rotate(3deg); }
}
@keyframes loadProgress {
  0% { width: 0%; }
  50% { width: 70%; }
  90% { width: 95%; }
  100% { width: 100%; }
}
@keyframes countUp {
  from { transform: translateY(8px); opacity: 0; }
  to { transform: translateY(0); opacity: 1; }
}

/* ---------- Overlay Screens (Loading / Error / Token) ---------- */
.overlay-screen {
  position: fixed;
  inset: 0;
  z-index: 9999;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--bg-primary);
  animation: fadeIn 0.3s ease;
}

.overlay-screen.hiding {
  animation: fadeOut 0.4s var(--ease-out-expo) forwards;
  pointer-events: none;
}

.overlay-card {
  text-align: center;
  max-width: 420px;
  padding: 48px 36px;
  background: var(--bg-secondary);
  border: 1px solid var(--border-glass);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-lg);
}

.overlay-icon {
  font-size: 56px;
  margin-bottom: 20px;
  animation: skullFloat 3s ease-in-out infinite;
}

.overlay-title {
  font-family: var(--font-display);
  font-size: 1.5rem;
  font-weight: 700;
  margin-bottom: 12px;
  background: linear-gradient(135deg, var(--accent-op16), var(--accent-op15));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.overlay-text {
  font-size: 0.95rem;
  color: var(--text-secondary);
  line-height: 1.7;
  margin-bottom: 28px;
}
.overlay-text code {
  background: var(--bg-tertiary);
  padding: 2px 8px;
  border-radius: 6px;
  font-size: 0.85em;
  color: var(--accent-op16);
}

.overlay-btn {
  display: inline-block;
  padding: 12px 32px;
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 0.95rem;
  color: var(--bg-primary);
  background: linear-gradient(135deg, var(--accent-op16), #00a3cc);
  border: none;
  border-radius: var(--radius-full);
  cursor: pointer;
  text-decoration: none;
  transition: transform 0.2s var(--ease-spring), box-shadow 0.2s;
}
.overlay-btn:hover {
  transform: scale(1.04);
  box-shadow: var(--shadow-glow-op16);
}

/* Loading */
.loading-content {
  text-align: center;
}
.loading-luffy {
  width: 96px;
  height: 96px;
  object-fit: contain;
  animation: skullFloat 2.5s ease-in-out infinite;
  margin-bottom: 28px;
  filter: drop-shadow(0 0 12px rgba(0, 212, 255, 0.4));
}
.loading-bar-track {
  width: 200px;
  height: 4px;
  background: var(--bg-tertiary);
  border-radius: 4px;
  overflow: hidden;
  margin: 0 auto 16px;
}
.loading-bar-fill {
  height: 100%;
  background: linear-gradient(90deg, var(--accent-op15), var(--accent-op16));
  border-radius: 4px;
  animation: loadProgress 2.5s var(--ease-out-expo) forwards;
}
.loading-text {
  font-family: var(--font-display);
  font-size: 0.9rem;
  color: var(--text-secondary);
  letter-spacing: 0.03em;
}

/* ---------- Controls Overlay ---------- */
#controls-overlay {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  z-index: 100;
  padding: calc(12px + var(--safe-top)) 16px 0;
  pointer-events: none;
  animation: fadeIn 0.6s 0.3s both;
}
#controls-overlay > * {
  pointer-events: auto;
}

/* Brand Bar */
#brand-bar {
  display: flex;
  align-items: center;
  margin-bottom: 10px;
}
.brand-logo {
  display: flex;
  align-items: center;
  gap: 8px;
}
.brand-flag {
  font-size: 22px;
  filter: drop-shadow(0 0 8px rgba(255, 107, 53, 0.5));
}
.brand-name {
  font-family: var(--font-display);
  font-weight: 800;
  font-size: clamp(1rem, 2.5vw, 1.25rem);
  letter-spacing: -0.02em;
  background: linear-gradient(135deg, var(--text-primary) 30%, var(--accent-op16));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

/* ---------- Search ---------- */
#search-container {
  position: relative;
  margin-bottom: 10px;
}

.search-input-wrap {
  position: relative;
  display: flex;
  align-items: center;
  background: var(--bg-glass-heavy);
  backdrop-filter: blur(24px);
  -webkit-backdrop-filter: blur(24px);
  border: 1px solid var(--border-glass);
  border-radius: var(--radius-md);
  transition: border-color 0.3s, box-shadow 0.3s;
  overflow: hidden;
}
.search-input-wrap:focus-within {
  border-color: rgba(0, 212, 255, 0.35);
  box-shadow: 0 0 0 3px rgba(0, 212, 255, 0.08), var(--shadow-md);
}

.search-icon {
  width: 20px;
  height: 20px;
  margin-left: 16px;
  color: var(--text-muted);
  flex-shrink: 0;
  transition: color 0.3s;
}
.search-input-wrap:focus-within .search-icon {
  color: var(--accent-op16);
}

#search-input {
  flex: 1;
  padding: 14px 12px;
  background: none;
  border: none;
  outline: none;
  font-family: var(--font-body);
  font-size: 0.95rem;
  color: var(--text-primary);
}
#search-input::placeholder {
  color: var(--text-muted);
}

.search-clear-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  background: none;
  border: none;
  cursor: pointer;
  color: var(--text-muted);
  transition: color 0.2s;
  flex-shrink: 0;
}
.search-clear-btn:hover {
  color: var(--text-primary);
}
.search-clear-btn svg {
  width: 16px;
  height: 16px;
}

/* Search Results Dropdown */
.search-results {
  position: absolute;
  top: calc(100% + 6px);
  left: 0;
  right: 0;
  max-height: 320px;
  overflow-y: auto;
  background: var(--bg-glass-heavy);
  backdrop-filter: blur(24px);
  -webkit-backdrop-filter: blur(24px);
  border: 1px solid var(--border-glass);
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-lg);
  animation: fadeIn 0.2s ease;
  z-index: 110;
}

.search-result-item {
  display: flex;
  flex-direction: column;
  gap: 3px;
  padding: 12px 16px;
  cursor: pointer;
  border-bottom: 1px solid var(--border-glass);
  transition: background 0.15s;
}
.search-result-item:last-child {
  border-bottom: none;
}
.search-result-item:hover,
.search-result-item:focus {
  background: rgba(0, 212, 255, 0.06);
}

.result-name {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 0.9rem;
  color: var(--text-primary);
}
.result-address {
  font-size: 0.8rem;
  color: var(--text-secondary);
}
.result-tags {
  display: flex;
  gap: 6px;
  margin-top: 2px;
}

.search-no-results {
  padding: 20px 16px;
  text-align: center;
  color: var(--text-muted);
  font-size: 0.85rem;
}

/* ---------- Filter Pills ---------- */
#filter-pills {
  display: flex;
  align-items: center;
  gap: 8px;
  overflow-x: auto;
  scrollbar-width: none;
  -ms-overflow-style: none;
  padding-bottom: 4px;
}
#filter-pills::-webkit-scrollbar {
  display: none;
}

.filter-pill {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 8px 16px;
  font-family: var(--font-display);
  font-weight: 500;
  font-size: 0.82rem;
  color: var(--text-secondary);
  background: var(--bg-glass-heavy);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border: 1px solid var(--border-glass);
  border-radius: var(--radius-full);
  cursor: pointer;
  white-space: nowrap;
  transition: all 0.25s var(--ease-out-expo);
  min-height: 44px;
}
.filter-pill:hover {
  border-color: var(--border-glass-hover);
  background: rgba(17, 24, 39, 0.95);
}
.filter-pill.active {
  color: var(--text-primary);
  border-color: var(--accent-op16);
  background: rgba(0, 212, 255, 0.08);
  box-shadow: 0 0 12px rgba(0, 212, 255, 0.12);
}
.filter-pill.active[data-filter="op15"] {
  border-color: var(--accent-op15);
  background: rgba(255, 107, 53, 0.08);
  box-shadow: 0 0 12px rgba(255, 107, 53, 0.12);
}
.filter-pill.active[data-filter="op16"] {
  border-color: var(--accent-op16);
  background: rgba(0, 212, 255, 0.08);
  box-shadow: 0 0 12px rgba(0, 212, 255, 0.12);
}
.filter-pill.locating {
  animation: glowPulse 1.5s ease-in-out infinite;
  color: var(--accent-op16);
  border-color: rgba(0, 212, 255, 0.3);
}

.pill-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  flex-shrink: 0;
}
.dot-all {
  background: linear-gradient(135deg, var(--accent-op15), var(--accent-op16));
}
.dot-op15 {
  background: var(--accent-op15);
  box-shadow: 0 0 6px var(--glow-op15);
}
.dot-op16 {
  background: var(--accent-op16);
  box-shadow: 0 0 6px var(--glow-op16);
}

.filter-divider {
  width: 1px;
  height: 24px;
  background: var(--border-glass);
  flex-shrink: 0;
}

.city-filter-wrap {
  position: relative;
  flex-shrink: 0;
}
.city-filter {
  appearance: none;
  -webkit-appearance: none;
  padding: 8px 32px 8px 14px;
  font-family: var(--font-display);
  font-weight: 500;
  font-size: 0.82rem;
  color: var(--text-secondary);
  background: var(--bg-glass-heavy) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 24 24' fill='none' stroke='%238b9dc3' stroke-width='2.5' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolyline points='6 9 12 15 18 9'%3E%3C/polyline%3E%3C/svg%3E") no-repeat right 12px center;
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border: 1px solid var(--border-glass);
  border-radius: var(--radius-full);
  cursor: pointer;
  white-space: nowrap;
  min-height: 44px;
  transition: all 0.25s var(--ease-out-expo);
}
.city-filter:focus {
  outline: none;
  border-color: var(--accent-op16);
  box-shadow: 0 0 12px rgba(0, 212, 255, 0.12);
}

/* ---------- Geolocate FAB ---------- */
.fab-btn {
  position: absolute;
  bottom: calc(64px + var(--safe-bottom));
  right: 16px;
  z-index: 9999;
  width: 52px;
  height: 52px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--bg-glass-heavy);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border: 1px solid var(--border-glass);
  border-radius: 50%;
  cursor: pointer;
  color: var(--text-secondary);
  box-shadow: var(--shadow-md);
  transition: all 0.25s var(--ease-out-expo);
  animation: fadeIn 0.5s 0.6s both;
}
.fab-btn svg {
  width: 22px;
  height: 22px;
}
.fab-btn.with-text {
  width: auto;
  padding: 0 20px;
  border-radius: 26px;
  gap: 8px;
  font-weight: 600;
  letter-spacing: 0.5px;
  color: var(--accent-op16);
  border-color: rgba(0, 212, 255, 0.4);
  box-shadow: 0 0 16px rgba(0, 212, 255, 0.15);
}
.fab-btn:hover {
  color: var(--accent-op16);
  border-color: rgba(0, 212, 255, 0.3);
  box-shadow: var(--shadow-glow-op16);
  transform: scale(1.08);
}
.fab-btn:active {
  transform: scale(0.95);
}
.fab-btn.locating {
  animation: glowPulse 1.5s ease-in-out infinite;
  color: var(--accent-op16);
}

/* ---------- Store Detail Panel ---------- */
.store-panel {
  position: absolute;
  z-index: 200;
  background: var(--bg-glass-heavy);
  backdrop-filter: blur(28px);
  -webkit-backdrop-filter: blur(28px);
  border: 1px solid var(--border-glass);
  overflow: hidden;
  animation: slideUp 0.45s var(--ease-out-expo);
}
.store-panel.closing {
  animation: slideDown 0.35s var(--ease-out-expo) forwards;
}

/* Mobile: bottom sheet */
@media (max-width: 768px) {
  .store-panel {
    bottom: 0;
    left: 0;
    right: 0;
    border-radius: var(--radius-lg) var(--radius-lg) 0 0;
    max-height: 55vh;
    padding-bottom: var(--safe-bottom);
  }
}
/* Desktop: side panel */
@media (min-width: 769px) {
  .store-panel {
    top: 20px;
    right: 20px;
    bottom: auto;
    left: auto;
    width: 380px;
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-lg);
    animation: slideInLeft 0.4s var(--ease-out-expo);
  }
}

.panel-drag-handle {
  display: flex;
  justify-content: center;
  padding: 12px 0 4px;
}
.panel-drag-handle span {
  width: 40px;
  height: 4px;
  background: rgba(255, 255, 255, 0.15);
  border-radius: 4px;
}
@media (min-width: 769px) {
  .panel-drag-handle { display: none; }
}

.panel-close-btn {
  position: absolute;
  top: 12px;
  right: 12px;
  width: 36px;
  height: 36px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(255, 255, 255, 0.06);
  border: none;
  border-radius: 50%;
  cursor: pointer;
  color: var(--text-muted);
  transition: all 0.2s;
}
.panel-close-btn:hover {
  background: rgba(255, 255, 255, 0.12);
  color: var(--text-primary);
}
.panel-close-btn svg {
  width: 18px;
  height: 18px;
}

.panel-content {
  padding: 8px 24px 24px;
}

.panel-header {
  margin-bottom: 20px;
}

.panel-name {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: clamp(1.15rem, 3vw, 1.4rem);
  line-height: 1.3;
  margin-bottom: 10px;
  padding-right: 32px;
}

.panel-tags {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}

.tag {
  display: inline-flex;
  align-items: center;
  padding: 4px 12px;
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 0.75rem;
  letter-spacing: 0.04em;
  border-radius: var(--radius-full);
  text-transform: uppercase;
}
.tag-op15 {
  color: var(--accent-op15);
  background: rgba(255, 107, 53, 0.12);
  border: 1px solid rgba(255, 107, 53, 0.25);
}
.tag-op16 {
  color: var(--accent-op16);
  background: rgba(0, 212, 255, 0.1);
  border: 1px solid rgba(0, 212, 255, 0.25);
}

.panel-details {
  display: flex;
  flex-direction: column;
  gap: 14px;
  margin-bottom: 24px;
}

.detail-row {
  display: flex;
  align-items: flex-start;
  gap: 12px;
}
.detail-icon {
  width: 18px;
  height: 18px;
  color: var(--text-muted);
  flex-shrink: 0;
  margin-top: 2px;
}
.detail-text {
  font-size: 0.9rem;
  color: var(--text-secondary);
  line-height: 1.5;
}
.detail-link {
  font-size: 0.9rem;
  color: var(--accent-op16);
  text-decoration: none;
  transition: color 0.2s;
}
.detail-link:hover {
  color: #33dfff;
  text-decoration: underline;
}

.navigate-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  width: 100%;
  padding: 14px 20px;
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 0.92rem;
  color: var(--bg-primary);
  background: linear-gradient(135deg, var(--accent-op16), #00a3cc);
  border: none;
  border-radius: var(--radius-md);
  cursor: pointer;
  text-decoration: none;
  transition: all 0.25s var(--ease-spring);
  min-height: 48px;
}
.navigate-btn svg {
  width: 18px;
  height: 18px;
}
.navigate-btn:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-glow-op16);
}
.navigate-btn:active {
  transform: translateY(0) scale(0.98);
}

/* ---------- Stats Bar ---------- */
#stats-bar {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  z-index: 100;
  padding: 0 16px calc(12px + var(--safe-bottom));
  background: linear-gradient(to top, var(--bg-primary) 40%, transparent);
  pointer-events: none;
  animation: fadeIn 0.5s 0.5s both;
}

.stats-content {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 2px;
  padding: 10px 0;
  font-family: var(--font-display);
  font-size: 0.8rem;
  color: var(--text-muted);
  letter-spacing: 0.03em;
}

.stats-count,
.stats-total {
  font-weight: 700;
  color: var(--text-secondary);
  min-width: 1ch;
  display: inline-block;
}
.stats-count {
  color: var(--accent-op16);
}

.stats-count.animating {
  animation: countUp 0.3s var(--ease-out-expo);
}

/* ---------- Leaflet Overrides ---------- */

/* Map Container */
.leaflet-container {
  background: var(--bg-primary);
  font-family: var(--font-body);
}

/* Popup */
.leaflet-popup {
  z-index: 150;
  margin-bottom: 20px;
}
.leaflet-popup-content-wrapper {
  background: var(--bg-glass-heavy) !important;
  backdrop-filter: blur(24px);
  -webkit-backdrop-filter: blur(24px);
  border: 1px solid var(--border-glass) !important;
  border-radius: var(--radius-md) !important;
  padding: 0 !important;
  box-shadow: var(--shadow-lg) !important;
  color: var(--text-primary);
}
.leaflet-popup-content {
  margin: 16px 20px !important;
  min-width: 220px;
}
.leaflet-popup-tip-container {
  overflow: visible;
}
.leaflet-popup-tip {
  background: var(--bg-glass-heavy) !important;
  border: 1px solid var(--border-glass) !important;
  border-top: none !important;
  border-left: none !important;
  box-shadow: var(--shadow-sm);
}
.leaflet-popup-close-button {
  color: var(--text-muted) !important;
  font-size: 20px !important;
  padding: 8px !important;
  right: 4px !important;
  top: 4px !important;
  transition: color 0.2s;
  text-decoration: none;
}
.leaflet-popup-close-button:hover {
  color: var(--text-primary) !important;
  background: none !important;
}

/* Popup Inner */
.store-popup {}
.popup-name {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 1rem;
  margin-bottom: 6px;
  line-height: 1.3;
  color: var(--text-primary);
}
.popup-address {
  font-size: 0.82rem;
  color: var(--text-secondary);
  margin-bottom: 4px;
  line-height: 1.5;
}
.popup-phone {
  display: inline-block;
  font-size: 0.82rem;
  color: var(--accent-op16);
  text-decoration: none;
  margin-bottom: 8px;
  transition: color 0.2s;
}
.popup-phone:hover {
  color: #33dfff;
}
.popup-tags {
  display: flex;
  gap: 6px;
  flex-wrap: wrap;
}

/* Controls */
.leaflet-bar {
  border: 1px solid var(--border-glass) !important;
  border-radius: var(--radius-sm) !important;
  box-shadow: var(--shadow-md) !important;
  overflow: hidden;
}
.leaflet-bar a,
.leaflet-bar a:hover {
  background: var(--bg-glass-heavy) !important;
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  color: var(--text-primary) !important;
  width: 36px !important;
  height: 36px !important;
  line-height: 36px !important;
  border-bottom: 1px solid var(--border-glass) !important;
}
.leaflet-bar a:last-child {
  border-bottom: none !important;
}
.leaflet-control-attribution {
  background: rgba(10, 14, 23, 0.7) !important;
  color: var(--text-muted) !important;
  font-size: 10px !important;
}
.leaflet-control-attribution a {
  color: var(--text-muted) !important;
}

/* Cluster Markers */
.marker-cluster {
  background-clip: padding-box;
  border-radius: 50%;
}
.marker-cluster div {
  width: 34px;
  height: 34px;
  margin-left: 3px;
  margin-top: 3px;
  text-align: center;
  border-radius: 50%;
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 13px;
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 2px solid rgba(255,255,255,0.15);
}

.cluster-both { background-color: rgba(168, 85, 247, 0.12); }
.cluster-both div { background-color: var(--accent-both); }

.cluster-op15 { background-color: rgba(255, 107, 53, 0.12); }
.cluster-op15 div { background-color: var(--accent-op15); }

.cluster-op16 { background-color: rgba(0, 212, 255, 0.12); }
.cluster-op16 div { background-color: var(--accent-op16); }

/* Point Markers */
.custom-point {
  border-radius: 50%;
  border: 2px solid rgba(255,255,255,0.25);
  background-clip: padding-box;
}
.point-op15 { background-color: var(--accent-op15); box-shadow: 0 0 12px var(--accent-op15); }
.point-op16 { background-color: var(--accent-op16); box-shadow: 0 0 12px var(--accent-op16); }
.point-both { background-color: var(--accent-both); box-shadow: 0 0 12px var(--accent-both); }

/* ---------- Custom Marker Animations ---------- */
.marker-pulse {
  animation: glowPulse 2s ease-in-out infinite;
}
.marker-pulse-op15 {
  animation: glowPulseOP15 2s ease-in-out infinite;
}

/* ---------- Empty State ---------- */
.empty-state {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  z-index: 50;
  text-align: center;
  padding: 32px;
  pointer-events: none;
}
.empty-state-icon {
  font-size: 48px;
  margin-bottom: 16px;
  opacity: 0.6;
}
.empty-state-text {
  font-family: var(--font-display);
  font-size: 1rem;
  color: var(--text-muted);
  line-height: 1.6;
}

/* ---------- Responsive Layout ---------- */

/* Desktop */
@media (min-width: 769px) {
  #controls-overlay {
    max-width: 420px;
    padding: calc(20px + var(--safe-top)) 20px 0;
  }

  .fab-btn {
    bottom: calc(72px + var(--safe-bottom));
    right: 20px;
  }

  #stats-bar {
    padding: 0 20px calc(16px + var(--safe-bottom));
  }
}

/* Small mobile */
@media (max-width: 380px) {
  .filter-pill {
    padding: 7px 12px;
    font-size: 0.78rem;
  }
  .panel-content {
    padding: 8px 18px 20px;
  }
}
