/* Tectonic Plates Explorer - Modern Geophysics UI */
@import url('https://fonts.googleapis.com/css2?family=Plus+Jakarta+Sans:wght@400;500;600;700;800&family=JetBrains+Mono:wght@400;500;600&display=swap');

:root {
  --font-main: 'Plus Jakarta Sans', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  --font-mono: 'JetBrains Mono', monospace;
  
  --bg-dark: #070b14;
  --bg-surface: #0f172a;
  --bg-card: rgba(15, 23, 42, 0.94);
  --bg-card-hover: #1e293b;
  --bg-glass: rgba(30, 41, 59, 0.88);
  --border-glass: rgba(255, 255, 255, 0.12);
  --border-subtle: rgba(255, 255, 255, 0.08);
  
  --color-convergent: #ff3860;
  --color-divergent: #fbbf24;
  --color-transform: #2dd4bf;
  --color-diffuse: #c084fc;
  
  --color-primary: #38bdf8;
  --color-primary-hover: #0284c7;
  --text-main: #f8fafc;
  --text-body: #e2e8f0;
  --text-muted: #94a3b8;
  --sidebar-width: 420px;
}

* {
  box-sizing: border-box;
}

html, body {
  margin: 0;
  padding: 0;
  width: 100%;
  min-height: 100%;
  overflow-x: hidden;
  overflow-y: auto;
  font-family: var(--font-main);
  background-color: var(--bg-dark);
  color: var(--text-body);
  scroll-behavior: smooth;
}

/* =========================================================
   BULMA DARK THEME RESETS & HIGH CONTRAST TYPOGRAPHY
   ========================================================= */
strong, b {
  color: #ffffff !important;
  font-weight: 700;
}

em {
  color: #38bdf8 !important;
  font-style: italic;
  font-weight: 600;
}

h1, h2, h3, h4, h5, h6,
.title, .subtitle {
  color: #ffffff !important;
  font-family: var(--font-main);
}

.content h1, .content h2, .content h3, .content h4, .content h5, .content h6,
.content strong {
  color: #ffffff !important;
}

.content em {
  color: #38bdf8 !important;
}

.content p {
  color: var(--text-body);
}

label {
  color: var(--text-body) !important;
}

/* Table Contrast Overrides */
.table {
  color: var(--text-body) !important;
  background-color: #1e293b !important;
}

.table thead th {
  color: #ffffff !important;
  background-color: #0f172a !important;
  border-bottom: 2px solid rgba(255, 255, 255, 0.15) !important;
  font-weight: 700;
}

.table tbody tr {
  background-color: transparent !important;
}

.table td {
  color: #e2e8f0 !important;
  border-color: rgba(255, 255, 255, 0.08) !important;
}

.table.is-striped tbody tr:not(.is-selected):nth-child(even) {
  background-color: rgba(255, 255, 255, 0.03) !important;
}

.table.is-hoverable tbody tr:not(.is-selected):hover {
  background-color: rgba(56, 189, 248, 0.08) !important;
}

a {
  color: #38bdf8;
  transition: color 0.15s ease;
}

a:hover {
  color: #7dd3fc;
}

/* App Container Layout */
#app {
  display: flex;
  flex-direction: column;
  width: 100%;
  min-height: 100vh;
  position: relative;
}

/* Bulma Navbar Customization */
.navbar.is-tectonic {
  background: rgba(11, 15, 25, 0.96);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border-bottom: 1px solid var(--border-glass);
  min-height: 3.5rem;
  position: sticky;
  top: 0;
  z-index: 50;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.4);
}

.brand-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.6rem;
  color: #ffffff !important;
}

.brand-h1 {
  font-size: 1.15rem;
  font-weight: 800;
  letter-spacing: -0.02em;
  margin: 0;
  padding: 0;
  color: #ffffff !important;
  display: flex;
  align-items: center;
  gap: 0.25rem;
  white-space: nowrap;
}

.brand-logo-img {
  width: 36px;
  height: 36px;
  border-radius: 8px;
  filter: drop-shadow(0 2px 8px rgba(56, 189, 248, 0.45));
  transition: transform 0.25s cubic-bezier(0.16, 1, 0.3, 1);
  display: block;
}

.brand-badge:hover .brand-logo-img {
  transform: scale(1.08) rotate(4deg);
}

.brand-icon {
  width: 34px;
  height: 34px;
  background: linear-gradient(135deg, #3b82f6 0%, #ec4899 100%);
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: white;
  font-size: 1.05rem;
  box-shadow: 0 2px 10px rgba(59, 130, 246, 0.5);
}

/* Search Box in Navbar */
.nav-search-wrap {
  position: relative;
  min-width: 280px;
  max-width: 380px;
}

.search-dropdown-menu {
  position: absolute;
  top: 100%;
  left: 0;
  right: 0;
  background: #1e293b;
  border: 1px solid var(--border-glass);
  border-radius: 8px;
  box-shadow: 0 10px 25px rgba(0,0,0,0.5);
  max-height: 320px;
  overflow-y: auto;
  z-index: 100;
  display: none;
}

.search-dropdown-menu.is-active {
  display: block;
}

.search-item {
  padding: 8px 14px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-bottom: 1px solid rgba(255, 255, 255, 0.05);
  transition: background 0.15s ease;
  font-size: 0.875rem;
}

.search-item:hover, .search-item.is-selected {
  background: #334155;
}

.search-item .item-title {
  font-weight: 600;
  color: #f1f5f9;
}

.search-item .item-type {
  font-size: 0.75rem;
  color: var(--text-muted);
}

/* Main Map Area */
.main-content {
  height: calc(100vh - 3.5rem);
  width: 100%;
  position: relative;
  display: flex;
  overflow: hidden;
}

#map-container {
  flex: 1;
  width: 100%;
  height: 100%;
  position: relative;
  background: #070a13;
}

/* MapLibre Canvas */
.maplibregl-canvas {
  outline: none;
}

/* Floating Layer Controls (Top Right Overlay) */
.floating-panel {
  position: absolute;
  top: 16px;
  right: 58px;
  background: var(--bg-card);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border: 1px solid var(--border-glass);
  border-radius: 12px;
  padding: 12px 14px;
  z-index: 30;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.5);
  max-width: 300px;
  transition: all 0.2s ease;
}

.floating-panel.is-collapsed {
  padding: 6px 14px;
  border-radius: 20px;
  background: rgba(15, 23, 42, 0.92);
  border: 1px solid rgba(255, 255, 255, 0.18);
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.6);
}

.floating-panel.is-collapsed .panel-body {
  display: none;
}

.floating-panel.is-collapsed .floating-panel-header {
  border-bottom: none;
  padding-bottom: 0;
  font-size: 0.8rem;
}

/* MapLibre Controls (Zoom & Orientation) */
.maplibregl-ctrl-top-right {
  top: 16px !important;
  right: 16px !important;
  z-index: 25 !important;
}

.maplibregl-ctrl-group {
  background: rgba(15, 23, 42, 0.9) !important;
  border: 1px solid rgba(255, 255, 255, 0.15) !important;
  backdrop-filter: blur(10px) !important;
  -webkit-backdrop-filter: blur(10px) !important;
  border-radius: 8px !important;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.5) !important;
  overflow: hidden;
}

.maplibregl-ctrl-group button {
  filter: invert(1);
  width: 30px !important;
  height: 30px !important;
}

.maplibregl-ctrl-group button:hover {
  background-color: rgba(255, 255, 255, 0.15) !important;
}

/* User Location GPS Red Pin Marker */
.user-location-marker {
  cursor: pointer;
  filter: drop-shadow(0 4px 10px rgba(0, 0, 0, 0.7));
  transition: transform 0.2s cubic-bezier(0.16, 1, 0.3, 1);
}

.user-location-marker:hover {
  transform: scale(1.18);
  filter: drop-shadow(0 6px 14px rgba(239, 68, 68, 0.6));
}

.floating-panel-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  cursor: pointer;
  font-weight: 700;
  font-size: 0.85rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: #cbd5e1;
  padding-bottom: 8px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.floating-panel-header:hover {
  color: #ffffff;
}

.layer-toggle-group {
  margin-top: 10px;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.layer-toggle-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 0.85rem;
  color: #e2e8f0;
  user-select: none;
  cursor: pointer;
}

.layer-toggle-item label {
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 8px;
}

.layer-color-dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  display: inline-block;
}

/* Map Style Switcher Pills */
.map-style-selector {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 6px;
  margin-top: 10px;
}

.style-btn {
  background: #1e293b;
  border: 1px solid rgba(255, 255, 255, 0.1);
  color: #cbd5e1;
  font-size: 0.75rem;
  padding: 5px 8px;
  border-radius: 6px;
  cursor: pointer;
  text-align: center;
  font-weight: 600;
  transition: all 0.2s ease;
}

.style-btn:hover {
  background: #334155;
  color: #ffffff;
}

.style-btn.is-active {
  background: #3b82f6;
  border-color: #60a5fa;
  color: #ffffff;
  box-shadow: 0 0 10px rgba(59, 130, 246, 0.4);
}

/* Floating Bottom Legend */
.map-legend {
  position: absolute;
  bottom: 24px;
  left: 20px;
  background: var(--bg-card);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border: 1px solid var(--border-glass);
  border-radius: 10px;
  padding: 10px 14px;
  z-index: 25;
  font-size: 0.78rem;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.5);
  max-width: 360px;
}

.legend-title {
  font-weight: 700;
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--text-muted);
  margin-bottom: 6px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.legend-items {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 6px 12px;
}

.legend-item {
  display: flex;
  align-items: center;
  gap: 6px;
  color: #cbd5e1;
}

.legend-line {
  width: 18px;
  height: 3px;
  border-radius: 2px;
}

.legend-line.convergent { background-color: var(--color-convergent); }
.legend-line.divergent { background-color: var(--color-divergent); }
.legend-line.transform { background-color: var(--color-transform); }
.legend-line.diffuse { background-color: var(--color-diffuse); }

.legend-dot.earthquake {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: #ff3b30;
  box-shadow: 0 0 6px #ff3b30;
}

.legend-dot.volcano {
  width: 10px;
  height: 10px;
  background: #ff9500;
  clip-path: polygon(50% 0%, 0% 100%, 100% 100%);
}

/* Quick Action Toolbar */
.quick-tools-bar {
  position: absolute;
  top: 16px;
  left: 16px;
  display: flex;
  gap: 8px;
  z-index: 28;
}

.tool-chip-btn {
  background: var(--bg-card);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border: 1px solid var(--border-glass);
  color: #f8fafc;
  font-size: 0.82rem;
  font-weight: 600;
  padding: 8px 14px;
  border-radius: 20px;
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 8px;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.4);
  transition: all 0.2s ease;
}

.tool-chip-btn:hover {
  background: #1e293b;
  border-color: rgba(255, 255, 255, 0.25);
  transform: translateY(-1px);
}

.tool-chip-btn.is-active {
  background: #3b82f6;
  border-color: #60a5fa;
  color: white;
}

/* Scroll Hint Indicator */
.scroll-hint-bar {
  position: absolute;
  bottom: 8px;
  left: 50%;
  transform: translateX(-50%);
  background: rgba(15, 23, 42, 0.9);
  backdrop-filter: blur(10px);
  border: 1px solid var(--border-glass);
  padding: 6px 16px;
  border-radius: 20px;
  font-size: 0.78rem;
  font-weight: 600;
  color: #cbd5e1;
  cursor: pointer;
  z-index: 25;
  display: flex;
  align-items: center;
  gap: 8px;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.4);
  transition: all 0.2s ease;
}

.scroll-hint-bar:hover {
  background: #1e293b;
  color: #ffffff;
  border-color: rgba(56, 189, 248, 0.4);
  transform: translateX(-50%) translateY(-2px);
}

/* Plate Inspector Sidebar */
.inspector-sidebar {
  width: var(--sidebar-width);
  height: 100%;
  background: #0f172a;
  border-left: 1px solid var(--border-glass);
  z-index: 40;
  display: flex;
  flex-direction: column;
  transition: transform 0.3s cubic-bezier(0.16, 1, 0.3, 1);
  box-shadow: -10px 0 30px rgba(0, 0, 0, 0.6);
  overflow: hidden;
}

.inspector-sidebar.is-hidden {
  transform: translateX(100%);
  position: absolute;
  right: 0;
  top: 0;
  bottom: 0;
}

.inspector-header {
  padding: 16px 20px;
  background: #1e293b;
  border-bottom: 1px solid var(--border-glass);
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
}

.inspector-title-wrap {
  flex: 1;
}

.inspector-plate-badge {
  display: inline-block;
  background: rgba(59, 130, 246, 0.25);
  color: #60a5fa;
  font-size: 0.75rem;
  font-weight: 700;
  padding: 2px 8px;
  border-radius: 4px;
  margin-bottom: 4px;
  font-family: var(--font-mono);
}

.inspector-plate-name {
  font-size: 1.35rem;
  font-weight: 800;
  line-height: 1.2;
  color: #ffffff !important;
  margin: 0;
}

.inspector-close-btn {
  background: transparent;
  border: none;
  color: #94a3b8;
  font-size: 1.25rem;
  cursor: pointer;
  padding: 4px 8px;
  border-radius: 6px;
  transition: color 0.2s ease, background 0.2s ease;
}

.inspector-close-btn:hover {
  color: #ffffff;
  background: rgba(255, 255, 255, 0.1);
}

.inspector-body {
  flex: 1;
  overflow-y: auto;
  padding: 20px;
  display: flex;
  flex-direction: column;
  gap: 18px;
}

/* Velocity & Stats Card */
.stat-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}

.stat-box {
  background: #1e293b;
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 10px;
  padding: 12px 14px;
}

.stat-label {
  font-size: 0.72rem;
  font-weight: 700;
  text-transform: uppercase;
  color: var(--text-muted);
  letter-spacing: 0.04em;
  margin-bottom: 4px;
}

.stat-value {
  font-size: 1.15rem;
  font-weight: 800;
  color: #ffffff;
  font-family: var(--font-mono);
}

.stat-sub {
  font-size: 0.72rem;
  color: #94a3b8;
  margin-top: 2px;
}

/* Speed Meter */
.speed-meter-wrap {
  background: #1e293b;
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 10px;
  padding: 14px;
}

.speed-meter-bar {
  height: 8px;
  background: #334155;
  border-radius: 4px;
  overflow: hidden;
  margin-top: 8px;
}

.speed-meter-fill {
  height: 100%;
  background: linear-gradient(90deg, #10b981 0%, #f59e0b 60%, #ef4444 100%);
  width: 0%;
  border-radius: 4px;
  transition: width 0.6s cubic-bezier(0.16, 1, 0.3, 1);
}

/* Sections */
.inspector-section {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.inspector-section-title {
  font-size: 0.82rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: #94a3b8;
  display: flex;
  align-items: center;
  gap: 6px;
}

.inspector-description {
  font-size: 0.92rem;
  line-height: 1.6;
  color: #e2e8f0;
}

.inspector-description p {
  margin: 0 0 0.75rem 0;
  line-height: 1.6;
}

.inspector-description p:last-child {
  margin-bottom: 0;
}

.facts-list {
  list-style: none;
  padding: 0;
  margin: 0;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.facts-list li {
  font-size: 0.88rem;
  line-height: 1.45;
  color: #e2e8f0;
  padding-left: 20px;
  position: relative;
}

.facts-list li::before {
  content: "•";
  position: absolute;
  left: 6px;
  color: #38bdf8;
  font-size: 1.2rem;
  line-height: 1;
}

.country-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.country-pill {
  background: #1e293b;
  border: 1px solid rgba(255, 255, 255, 0.1);
  color: #e2e8f0;
  font-size: 0.78rem;
  padding: 3px 10px;
  border-radius: 14px;
  font-weight: 500;
}

/* Earthquakes on this plate */
.plate-earthquakes-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.quake-mini-item {
  background: #1e293b;
  border: 1px solid rgba(255, 255, 255, 0.06);
  border-radius: 8px;
  padding: 8px 12px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  cursor: pointer;
  transition: background 0.15s ease;
}

.quake-mini-item:hover {
  background: #334155;
}

.quake-mag-badge {
  font-weight: 800;
  font-size: 0.85rem;
  padding: 2px 6px;
  border-radius: 4px;
  font-family: var(--font-mono);
}

.mag-low { background: rgba(59, 130, 246, 0.25); color: #60a5fa; }
.mag-mid { background: rgba(245, 158, 11, 0.25); color: #fbbf24; }
.mag-high { background: rgba(239, 68, 68, 0.25); color: #f87171; }

/* Custom Popups for MapLibre */
.maplibregl-popup {
  max-width: 320px;
  font-family: var(--font-main);
}

.maplibregl-popup-content {
  background: #0f172a !important;
  color: #f8fafc !important;
  border: 1px solid var(--border-glass) !important;
  border-radius: 12px !important;
  padding: 16px !important;
  box-shadow: 0 12px 32px rgba(0, 0, 0, 0.6) !important;
}

.maplibregl-popup-close-button {
  color: #94a3b8 !important;
  font-size: 16px !important;
  padding: 6px 10px !important;
}

.maplibregl-popup-close-button:hover {
  color: #ffffff !important;
  background: transparent !important;
}

.popup-title {
  font-weight: 800;
  font-size: 1.05rem;
  color: #ffffff;
  margin-bottom: 4px;
}

.popup-meta {
  font-size: 0.8rem;
  color: var(--text-muted);
  margin-bottom: 8px;
}

/* Modals */
.modal-card {
  max-width: 800px;
  border-radius: 14px;
  overflow: hidden;
  background: #0f172a;
  border: 1px solid var(--border-glass);
}

.modal-card-head {
  background: #1e293b;
  border-bottom: 1px solid var(--border-glass);
}

.modal-card-title {
  color: #ffffff !important;
  font-weight: 800;
}

.modal-card-body {
  background: #0f172a;
  color: #e2e8f0;
  padding: 24px;
  max-height: calc(100vh - 160px);
}

.modal-card-foot {
  background: #1e293b;
  border-top: 1px solid var(--border-glass);
  justify-content: flex-end;
}

/* =========================================================
   SEO KNOWLEDGE & GEOLOGY HUB SECTION (WCAG AAA CONTRAST)
   ========================================================= */
.seo-content-section {
  background: #070b14;
  border-top: 1px solid var(--border-glass);
  padding: 4.5rem 1.5rem 3rem;
  color: #e2e8f0;
}

.seo-container {
  max-width: 1100px;
  margin: 0 auto;
}

/* Hero Box with High-Contrast Highlights */
.seo-hero-box {
  background: linear-gradient(135deg, rgba(30, 41, 59, 0.95) 0%, rgba(15, 23, 42, 0.98) 100%);
  border: 1px solid rgba(56, 189, 248, 0.25);
  border-radius: 16px;
  padding: 2.5rem;
  margin-bottom: 3.5rem;
  box-shadow: 0 12px 35px rgba(0, 0, 0, 0.5);
}

.seo-hero-box p {
  color: #e2e8f0;
  font-size: 1.05rem;
  line-height: 1.8;
}

.seo-hero-box strong {
  color: #ffffff !important;
  font-weight: 700;
  background: rgba(56, 189, 248, 0.12);
  padding: 2px 7px;
  border-radius: 5px;
  border: 1px solid rgba(56, 189, 248, 0.28);
  display: inline-block;
  line-height: 1.4;
}

.seo-hero-box em {
  color: #38bdf8 !important;
  font-style: italic;
  font-weight: 600;
  text-decoration: underline;
  text-decoration-color: rgba(56, 189, 248, 0.35);
  text-underline-offset: 3px;
}

.seo-section-title {
  font-size: 1.85rem;
  font-weight: 800;
  color: #ffffff !important;
  margin-bottom: 1.5rem;
  letter-spacing: -0.02em;
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

/* Feature Cards */
.seo-card {
  background: #131d2e;
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 12px;
  padding: 1.75rem;
  height: 100%;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.3);
  transition: transform 0.2s ease, border-color 0.2s ease, box-shadow 0.2s ease;
}

.seo-card:hover {
  transform: translateY(-3px);
  border-color: rgba(56, 189, 248, 0.35);
  box-shadow: 0 8px 25px rgba(0, 0, 0, 0.45);
}

.seo-card-title {
  font-size: 1.25rem;
  font-weight: 800;
  margin-bottom: 0.85rem;
}

.seo-card p {
  color: #cbd5e1;
  font-size: 0.95rem;
  line-height: 1.65;
}

.seo-card strong {
  color: #ffffff !important;
}

/* FAQ Accordion Item */
.seo-faq-item {
  background: #131d2e;
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 10px;
  margin-bottom: 1rem;
  overflow: hidden;
  transition: border-color 0.2s ease;
}

.seo-faq-item:hover {
  border-color: rgba(56, 189, 248, 0.3);
}

.seo-faq-question {
  padding: 1.25rem 1.5rem;
  font-weight: 700;
  font-size: 1.05rem;
  color: #ffffff !important;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: space-between;
  user-select: none;
  transition: background 0.15s ease, color 0.15s ease;
}

.seo-faq-question:hover {
  background: #1e2c42;
  color: #38bdf8 !important;
}

.seo-faq-answer {
  padding: 0 1.5rem 1.35rem;
  font-size: 0.98rem;
  line-height: 1.7;
  color: #cbd5e1;
  border-top: 1px solid rgba(255, 255, 255, 0.05);
  padding-top: 1rem;
}

/* Footer */
.seo-footer {
  border-top: 1px solid rgba(255, 255, 255, 0.08);
  padding: 2.5rem 1.5rem;
  background: #04070d;
  color: #94a3b8;
  font-size: 0.85rem;
  text-align: center;
}

.seo-footer strong {
  color: #ffffff !important;
}

.seo-footer a {
  color: #38bdf8;
  text-decoration: none;
}

.seo-footer a:hover {
  text-decoration: underline;
}

/* End of Main Content Styles */

/* ==========================================================================
   Maps Hub Bar & Phenomena Selector (Matches user specification & screenshot)
   ========================================================================== */
.maps-hub-bar {
  position: absolute;
  top: 14px;
  left: 50%;
  transform: translateX(-50%);
  background: rgba(15, 23, 42, 0.94);
  backdrop-filter: blur(18px);
  -webkit-backdrop-filter: blur(18px);
  border: 1px solid rgba(255, 255, 255, 0.15);
  border-radius: 24px;
  padding: 12px 18px 12px;
  z-index: 35;
  box-shadow: 0 14px 40px rgba(0, 0, 0, 0.65);
  max-width: calc(100vw - 380px);
  transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
}

.maps-hub-bar.is-hidden {
  display: none !important;
}

.maps-hub-bar.is-minimized {
  padding-bottom: 8px;
  border-radius: 18px;
  cursor: pointer;
}

.maps-hub-bar.is-minimized .maps-grid {
  display: none;
}

.maps-hub-bar.is-minimized .maps-hub-toggle i {
  transform: rotate(180deg);
}

.maps-hub-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 6px;
  padding: 2px 4px;
  cursor: pointer;
  user-select: none;
}

.maps-hub-title {
  font-size: 0.78rem;
  font-weight: 800;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: #cbd5e1;
  display: flex;
  align-items: center;
  cursor: pointer;
  user-select: none;
  transition: color 0.18s ease;
}

.maps-hub-title i {
  cursor: pointer;
  transition: transform 0.18s ease;
}

.maps-hub-header:hover .maps-hub-title {
  color: #38bdf8;
}

.maps-hub-header:hover .maps-hub-title i {
  transform: rotate(15deg);
}

.maps-hub-header:hover .maps-hub-toggle {
  color: #ffffff;
  background: rgba(255, 255, 255, 0.12);
}

.maps-hub-toggle {
  background: transparent;
  border: none;
  color: #94a3b8;
  cursor: pointer;
  font-size: 0.75rem;
  padding: 2px 6px;
  border-radius: 6px;
  transition: all 0.15s ease;
  pointer-events: none;
}

.maps-grid {
  display: flex;
  align-items: center;
  gap: 12px;
  overflow-x: auto;
  overflow-y: visible;
  padding: 8px 6px 10px;
  scrollbar-width: thin;
}

.maps-grid::-webkit-scrollbar {
  height: 4px;
}

.maps-grid::-webkit-scrollbar-thumb {
  background: rgba(255, 255, 255, 0.2);
  border-radius: 2px;
}

/* Individual Phenomena Map Mode Card */
.map-mode-card {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  width: 90px;
  min-width: 90px;
  height: 90px;
  border-radius: 18px;
  border: 1.5px solid rgba(255, 255, 255, 0.14);
  background: rgba(255, 255, 255, 0.05);
  backdrop-filter: blur(10px);
  cursor: pointer;
  transition: border-color 0.2s ease, background 0.2s ease, box-shadow 0.2s ease, transform 0.2s ease;
  padding: 6px 4px;
  outline: none;
  text-decoration: none;
  box-sizing: border-box;
  position: relative;
}

.map-mode-card:hover {
  transform: translateY(-2px);
  border-color: rgba(255, 255, 255, 0.45);
  background: rgba(255, 255, 255, 0.1);
  box-shadow: 0 6px 16px rgba(0, 0, 0, 0.45);
  z-index: 2;
}

/* Active State matching user's screenshot with terracotta/coral highlight border */
.map-mode-card.is-active {
  border: 2px solid #f97316 !important;
  background: rgba(249, 115, 22, 0.18) !important;
  box-shadow: 0 0 16px rgba(249, 115, 22, 0.45), inset 0 0 10px rgba(249, 115, 22, 0.1) !important;
  z-index: 3;
}

.map-mode-card.is-active:hover {
  transform: translateY(-2px);
  box-shadow: 0 4px 22px rgba(249, 115, 22, 0.6), inset 0 0 10px rgba(249, 115, 22, 0.15) !important;
}

.map-card-icon {
  height: 40px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 4px;
}

.map-card-label {
  font-size: 0.72rem;
  font-weight: 600;
  text-align: center;
  line-height: 1.2;
  color: #cbd5e1;
  transition: color 0.15s ease;
}

.map-mode-card.is-active .map-card-label {
  color: #ffffff;
  font-weight: 700;
}


/* ==========================================================================
   Dynamic Mode Filter Bar (Top-Right Pill, matching competitor)
   ========================================================================== */
.mode-filter-bar {
  position: absolute;
  top: 16px;
  right: 240px;
  display: flex;
  align-items: center;
  gap: 8px;
  background: rgba(30, 41, 59, 0.94);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border: 1px solid rgba(255, 255, 255, 0.15);
  border-radius: 24px;
  padding: 4px 6px 4px 12px;
  z-index: 32;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.4);
  transition: all 0.2s ease;
}

.mode-filter-bar.is-hidden {
  display: none !important;
}

.mode-filter-select-wrap select {
  background: transparent;
  border: none;
  color: #f1f5f9;
  font-size: 0.82rem;
  font-weight: 600;
  outline: none;
  cursor: pointer;
  padding-right: 4px;
}

.mode-filter-select-wrap select option {
  background: #1e293b;
  color: #f1f5f9;
}

.mode-filter-badge {
  background: #d97706;
  color: #ffffff;
  font-size: 0.78rem;
  font-weight: 700;
  padding: 3px 10px;
  border-radius: 14px;
  min-width: 32px;
  text-align: center;
  box-shadow: 0 2px 8px rgba(217, 119, 6, 0.35);
}

/* ==========================================================================
   Dynamic Bottom Legend Pill (Bottom-Center, matching user screenshots)
   ========================================================================== */
.dynamic-legend-pill {
  position: absolute;
  bottom: 50px;
  left: 50%;
  transform: translateX(-50%);
  background: rgba(15, 23, 42, 0.92);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border: 1px solid rgba(255, 255, 255, 0.15);
  border-radius: 30px;
  padding: 8px 22px;
  z-index: 28;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.6);
  display: flex;
  align-items: center;
  justify-content: center;
  user-select: none;
  transition: all 0.25s ease;
}

.legend-scale-row {
  display: flex;
  align-items: center;
  gap: 16px;
  font-size: 0.82rem;
  font-weight: 600;
  color: #e2e8f0;
  white-space: nowrap;
}

.legend-scale-item {
  display: flex;
  align-items: center;
  gap: 6px;
}

.legend-circle {
  width: 11px;
  height: 11px;
  border-radius: 50%;
  display: inline-block;
  box-shadow: 0 1px 4px rgba(0,0,0,0.2);
}

.cyclone-dot {
  font-size: 1.1rem;
  line-height: 1;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  padding: 2px;
}

.volcano-triangle {
  color: #ef4444;
  font-size: 0.95rem;
  display: inline-block;
  transform: scaleY(1.1);
}

/* ==========================================================================
   Comprehensive Mobile & Tablet Responsive Architecture
   ========================================================================== */

/* Mobile Action Buttons in Navbar Brand */
.mobile-nav-actions {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-left: auto;
}

.mobile-action-btn {
  font-weight: 700 !important;
  font-size: 0.76rem !important;
  height: 32px !important;
  padding: 0 12px !important;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.4);
}

/* Tablet Screens (<= 1023px) */
@media screen and (max-width: 1023px) {
  .navbar-brand {
    display: flex;
    align-items: center;
    justify-content: space-between;
    width: 100%;
    padding: 0 14px;
    min-height: 3.5rem;
  }

  .navbar-burger {
    color: #ffffff !important;
    height: 3.2rem;
    width: 3.2rem;
    margin-left: 4px;
    border-radius: 8px;
    transition: background 0.2s ease;
  }

  .navbar-burger:hover {
    background: rgba(255, 255, 255, 0.08);
  }

  .navbar-burger span {
    height: 2px;
    width: 18px;
    background-color: #f1f5f9;
  }

  .navbar-burger.is-active span {
    background-color: #38bdf8;
  }

  /* Sleek Glass Drawer Dropdown Menu */
  .navbar-menu {
    background: rgba(11, 15, 25, 0.98) !important;
    backdrop-filter: blur(24px);
    -webkit-backdrop-filter: blur(24px);
    border-bottom: 1px solid rgba(255, 255, 255, 0.15);
    box-shadow: 0 24px 48px rgba(0, 0, 0, 0.85) !important;
    padding: 16px 20px 24px;
    display: none;
  }

  .navbar-menu.is-active {
    display: block !important;
    animation: mobileMenuSlide 0.22s cubic-bezier(0.16, 1, 0.3, 1);
  }

  .nav-search-wrap {
    min-width: 100%;
    max-width: 100%;
    margin-bottom: 12px;
  }

  .navbar-end .navbar-item {
    padding: 5px 0;
  }

  .navbar-end .button {
    width: 100%;
    justify-content: center;
    height: 38px;
    font-size: 0.9rem;
  }

  .maps-hub-bar {
    max-width: calc(100vw - 32px);
    top: 64px;
  }

  .mode-filter-bar {
    top: 64px;
    right: 14px;
  }
}

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

/* Smartphone Screens (<= 768px) */
@media screen and (max-width: 768px) {
  /* Prevent full-page scroll jumping when map is focused */
  .main-content {
    height: calc(100dvh - 3.5rem);
    height: calc(100vh - 3.5rem);
    position: relative;
    overflow: hidden;
  }

  /* 1. Quick Floating Tools Bar (Top-Left) */
  .quick-tools-bar {
    top: 10px;
    left: 10px;
    gap: 6px;
    z-index: 28;
  }

  .tool-chip-btn {
    font-size: 0.74rem;
    padding: 5px 10px;
    border-radius: 16px;
    gap: 5px;
    height: 30px;
    box-shadow: 0 3px 12px rgba(0, 0, 0, 0.5);
  }

  /* 2. Floating Layers Panel: Compact Pill by Default */
  .floating-panel {
    top: 10px;
    right: 10px;
    bottom: auto;
    max-width: 280px;
    width: auto;
    z-index: 32;
    padding: 6px 12px;
    border-radius: 20px;
    transition: all 0.25s cubic-bezier(0.16, 1, 0.3, 1);
  }

  .floating-panel.is-collapsed {
    padding: 6px 12px;
    border-radius: 20px;
    background: rgba(15, 23, 42, 0.92);
  }

  .floating-panel.is-collapsed .floating-panel-header {
    border-bottom: none;
    padding-bottom: 0;
    font-size: 0.74rem;
  }

  .floating-panel.is-collapsed .floating-panel-header i.fa-chevron-down {
    display: none;
  }

  .floating-panel:not(.is-collapsed) {
    top: 10px;
    right: 10px;
    width: calc(100vw - 20px);
    max-width: 320px;
    max-height: 82vh;
    overflow-y: auto;
    padding: 14px 16px;
    border-radius: 16px;
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.85);
    background: rgba(11, 15, 25, 0.97);
  }

  /* 3. MapLibre Controls (Zoom & Orientation) */
  .maplibregl-ctrl-top-right {
    top: 48px !important;
    right: 10px !important;
  }

  .maplibregl-ctrl-group {
    background: rgba(15, 23, 42, 0.9) !important;
    border: 1px solid rgba(255, 255, 255, 0.15) !important;
    backdrop-filter: blur(10px) !important;
    -webkit-backdrop-filter: blur(10px) !important;
    border-radius: 8px !important;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.5) !important;
  }

  .maplibregl-ctrl-group button {
    filter: invert(1);
    width: 30px !important;
    height: 30px !important;
  }

  /* 4. Mode Filter Bar (Left Side Under Quick Chips) */
  .mode-filter-bar {
    top: 48px;
    left: 10px;
    right: auto;
    font-size: 0.74rem;
    padding: 3px 8px;
    z-index: 27;
    height: 30px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.5);
  }

  .mode-filter-select-wrap select {
    font-size: 0.74rem;
  }

  .mode-filter-badge {
    font-size: 0.68rem;
    padding: 2px 7px;
    min-width: 22px;
  }

  /* 5. Maps Hub Bar: Docked Gracefully at the Bottom with Pill Toggle */
  .maps-hub-bar {
    position: absolute;
    top: auto;
    bottom: 12px;
    left: 10px;
    right: 10px;
    transform: none;
    max-width: none;
    border-radius: 20px;
    padding: 8px 12px 10px;
    background: rgba(11, 15, 25, 0.96);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border: 1px solid rgba(255, 255, 255, 0.18);
    box-shadow: 0 10px 32px rgba(0, 0, 0, 0.8);
    z-index: 38;
    transition: all 0.25s cubic-bezier(0.16, 1, 0.3, 1);
  }

  .maps-hub-bar.is-minimized {
    width: auto;
    left: 50%;
    right: auto;
    transform: translateX(-50%);
    padding: 6px 14px;
    border-radius: 22px;
    background: rgba(15, 23, 42, 0.94);
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.6);
    cursor: pointer;
  }

  .maps-hub-bar.is-minimized .maps-grid {
    display: none !important;
  }

  .maps-hub-bar.is-minimized .maps-hub-header {
    margin-bottom: 0;
    gap: 8px;
  }

  .maps-hub-bar.is-minimized .maps-hub-title {
    font-size: 0.75rem;
  }

  .maps-grid {
    gap: 8px;
    padding: 6px 2px 2px;
    scrollbar-width: none;
    -ms-overflow-style: none;
    -webkit-overflow-scrolling: touch;
  }

  .maps-grid::-webkit-scrollbar {
    display: none;
  }

  .map-mode-card {
    width: 68px;
    min-width: 68px;
    height: 72px;
    border-radius: 14px;
    padding: 4px 2px;
  }

  .map-card-icon {
    height: 30px;
    margin-bottom: 2px;
  }

  .map-card-icon svg {
    width: 26px;
    height: 26px;
  }

  .map-card-label {
    font-size: 0.64rem;
    line-height: 1.1;
  }

  /* 6. Dynamic Legend Pill (Above Bottom Dock) */
  .dynamic-legend-pill {
    bottom: 56px;
    left: 50%;
    transform: translateX(-50%);
    padding: 4px 12px;
    font-size: 0.7rem;
    max-width: calc(100vw - 24px);
    overflow-x: auto;
    scrollbar-width: none;
    -webkit-overflow-scrolling: touch;
    z-index: 26;
  }

  .dynamic-legend-pill::-webkit-scrollbar {
    display: none;
  }

  .legend-scale-row {
    gap: 8px;
    font-size: 0.7rem;
  }

  .scroll-hint-bar {
    display: none !important;
  }

  /* 7. Inspector Slide-Up Sheet */
  .inspector-sidebar {
    width: 100%;
    height: 72vh;
    max-height: 75vh;
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    top: auto;
    border-left: none;
    border-top: 1px solid rgba(255, 255, 255, 0.18);
    border-radius: 22px 22px 0 0;
    box-shadow: 0 -14px 44px rgba(0, 0, 0, 0.88);
    transform: translateY(0);
    z-index: 60;
  }

  .inspector-sidebar.is-hidden {
    transform: translateY(100%);
  }

  .sheet-handle {
    width: 44px;
    height: 5px;
    background: rgba(255, 255, 255, 0.35);
    border-radius: 3px;
    margin: 10px auto 4px;
    cursor: pointer;
    transition: background 0.15s ease;
  }

  .sheet-handle:active {
    background: #38bdf8;
  }

  /* 8. MapLibre Native Popups */
  .maplibregl-popup {
    max-width: 290px;
    width: 86vw;
    z-index: 55;
  }

  .maplibregl-popup-content {
    background: rgba(15, 23, 42, 0.96) !important;
    backdrop-filter: blur(16px) !important;
    -webkit-backdrop-filter: blur(16px) !important;
    border: 1px solid rgba(255, 255, 255, 0.18) !important;
    border-radius: 14px !important;
    padding: 12px 14px !important;
    box-shadow: 0 12px 36px rgba(0, 0, 0, 0.7) !important;
  }

  .maplibregl-popup-close-button {
    font-size: 1.3rem !important;
    padding: 6px 10px !important;
    color: #94a3b8 !important;
    top: 4px !important;
    right: 6px !important;
  }

  /* 9. Modals on Mobile */
  .modal-card {
    width: calc(100vw - 20px);
    max-width: calc(100vw - 20px);
    margin: 10px auto;
    max-height: calc(100vh - 40px);
    border-radius: 16px;
    overflow: hidden;
  }

  .modal-card-head {
    padding: 12px 16px;
  }

  .modal-card-title {
    font-size: 1.02rem;
  }

  .modal-card-body {
    padding: 12px;
    -webkit-overflow-scrolling: touch;
  }

  .modal-card-foot {
    padding: 10px 16px;
  }

  .table-container {
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
  }
}

/* Performance Optimizations: content-visibility & GPU Acceleration */
.seo-content-section {
  content-visibility: auto;
  contain-intrinsic-size: 1000px;
}

#comparison-modal,
#guide-modal {
  contain: layout style;
}

.floating-panel,
.maps-hub-bar,
.dynamic-legend-pill,
.mode-filter-bar {
  will-change: transform;
}

/* ==========================================================================
   Static Pages Theming (About, Contact, Privacy Policy, Terms of Service)
   ========================================================================== */
.static-content-wrap {
  min-height: calc(100vh - 3.5rem);
  padding: 3rem 1.5rem 5rem;
  background: radial-gradient(ellipse at 50% 0%, rgba(30, 58, 138, 0.2) 0%, #070b14 65%);
  background-color: #070b14;
}

.static-page-header {
  text-align: center;
  margin-bottom: 3.5rem;
  padding-bottom: 2rem;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.static-article {
  max-width: 860px;
  margin: 0 auto;
}

.static-feature-card {
  background: rgba(15, 23, 42, 0.85);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 16px;
  padding: 2rem 2.2rem;
  box-shadow: 0 16px 40px rgba(0, 0, 0, 0.5);
  margin-bottom: 2rem;
}

.data-source-card {
  background: #111a2e;
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 14px;
  padding: 1.5rem;
  display: flex;
  gap: 16px;
  height: 100%;
  transition: border-color 0.2s ease, transform 0.2s ease;
}

.data-source-card:hover {
  border-color: rgba(56, 189, 248, 0.35);
  transform: translateY(-2px);
}

.source-icon {
  font-size: 1.6rem;
  min-width: 40px;
  display: flex;
  align-items: flex-start;
  padding-top: 2px;
}

.contact-form-card {
  background: rgba(15, 23, 42, 0.9);
  backdrop-filter: blur(16px);
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 16px;
  padding: 2.2rem;
  box-shadow: 0 20px 48px rgba(0, 0, 0, 0.6);
}

.contact-info-card {
  background: #111a2e;
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 14px;
  padding: 1.6rem;
  margin-bottom: 1.5rem;
}

.policy-card {
  background: rgba(15, 23, 42, 0.7);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 14px;
  padding: 1.75rem 2rem;
  margin-bottom: 1.75rem;
}

.policy-card h2,
.policy-card h3 {
  color: #38bdf8 !important;
  margin-bottom: 0.75rem;
}

.policy-card p,
.policy-card li {
  color: #cbd5e1;
  font-size: 0.96rem;
  line-height: 1.7;
}

@media screen and (max-width: 768px) {
  .static-content-wrap {
    padding: 2rem 1rem 4rem;
  }
  .static-page-header {
    margin-bottom: 2rem;
  }
  .static-feature-card,
  .contact-form-card,
  .policy-card {
    padding: 1.4rem 1.2rem;
  }
}

/* Boundary Classification Quick Filters */
.boundary-subfilters {
  display: flex;
  gap: 6px;
  margin-top: 4px;
  margin-bottom: 8px;
  padding-left: 22px;
  flex-wrap: wrap;
}

.boundary-chip-btn {
  font-size: 0.7rem;
  font-weight: 700;
  padding: 2px 8px;
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.16);
  color: #cbd5e1;
  cursor: pointer;
  transition: all 0.2s ease;
  white-space: nowrap;
}

.boundary-chip-btn:hover {
  background: rgba(255, 255, 255, 0.16);
  color: #ffffff;
}

.boundary-chip-btn.is-active#btn-filter-convergent {
  background: rgba(255, 56, 96, 0.22);
  border-color: #ff3860;
  color: #ff6b8b;
  box-shadow: 0 0 8px rgba(255, 56, 96, 0.3);
}

.boundary-chip-btn.is-active#btn-filter-divergent {
  background: rgba(251, 191, 36, 0.22);
  border-color: #fbbf24;
  color: #fcd34d;
  box-shadow: 0 0 8px rgba(251, 191, 36, 0.3);
}

.boundary-chip-btn.is-active#btn-filter-transform {
  background: rgba(45, 212, 191, 0.22);
  border-color: #2dd4bf;
  color: #5eead4;
  box-shadow: 0 0 8px rgba(45, 212, 191, 0.3);
}

/* Compact MapLibre Attribution Button (Circular info button matching user screenshot) */
details.maplibregl-ctrl-attrib:not([open]) {
  background: transparent !important;
  margin: 0 10px 10px 0 !important;
  padding: 0 !important;
  border: none !important;
  border-radius: 50% !important;
  min-height: 24px !important;
  width: 24px !important;
  height: 24px !important;
  overflow: hidden !important;
}

details.maplibregl-ctrl-attrib:not([open]) > :not(summary) {
  display: none !important;
}

details.maplibregl-ctrl-attrib summary.maplibregl-ctrl-attrib-button {
  display: flex !important;
  align-items: center;
  justify-content: center;
  position: static !important;
  width: 24px !important;
  height: 24px !important;
  border-radius: 50% !important;
  background-color: #ffffff !important;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.45) !important;
  border: 1px solid rgba(0, 0, 0, 0.15) !important;
  cursor: pointer !important;
  color: #0f172a !important;
  outline: none !important;
  list-style: none !important;
}

details.maplibregl-ctrl-attrib summary::-webkit-details-marker {
  display: none !important;
}

details.maplibregl-ctrl-attrib[open] {
  display: inline-flex !important;
  align-items: center !important;
  gap: 8px !important;
  background: rgba(15, 23, 42, 0.94) !important;
  backdrop-filter: blur(14px) !important;
  border: 1px solid rgba(255, 255, 255, 0.15) !important;
  border-radius: 20px !important;
  padding: 4px 14px 4px 6px !important;
  color: #94a3b8 !important;
  font-size: 0.72rem !important;
  margin: 0 10px 10px 0 !important;
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.5) !important;
  white-space: nowrap !important;
}

details.maplibregl-ctrl-attrib[open] summary.maplibregl-ctrl-attrib-button {
  margin-right: 2px !important;
  flex-shrink: 0 !important;
}

details.maplibregl-ctrl-attrib[open] a {
  color: #38bdf8 !important;
}

/* Plate Directory Cards & Dark Contrast Styles */
.plate-dir-card {
  background: #0f172a !important;
  border: 1px solid rgba(255, 255, 255, 0.1) !important;
  border-radius: 12px;
  transition: transform 0.2s ease, box-shadow 0.2s ease, border-color 0.2s ease;
}

.plate-dir-card:hover {
  transform: translateY(-4px);
  border-color: rgba(56, 189, 248, 0.35) !important;
  box-shadow: 0 14px 28px -10px rgba(0, 0, 0, 0.65);
}

/* Breadcrumb Dark Overrides */
.breadcrumb li.is-active a {
  color: #f8fafc !important;
  font-weight: 700;
}

.breadcrumb a {
  color: #94a3b8 !important;
}

.breadcrumb a:hover {
  color: #38bdf8 !important;
}

.breadcrumb li + li::before {
  color: rgba(255, 255, 255, 0.3) !important;
}

/* Directory Filter Tabs */
.dir-tab-btn {
  background: rgba(30, 41, 59, 0.8) !important;
  color: #cbd5e1 !important;
  border: 1px solid rgba(255, 255, 255, 0.12) !important;
  font-weight: 600;
  transition: all 0.2s ease;
}

.dir-tab-btn:hover {
  background: #334155 !important;
  color: #ffffff !important;
}

.dir-tab-btn.is-active {
  background: #0284c7 !important;
  color: #ffffff !important;
  border-color: #38bdf8 !important;
  box-shadow: 0 0 12px rgba(56, 189, 248, 0.35);
}

.dir-badge-pill {
  background: rgba(56, 189, 248, 0.12);
  color: #38bdf8;
  border: 1px solid rgba(56, 189, 248, 0.3);
  font-weight: 700;
  border-radius: 20px;
  padding: 4px 14px;
  display: inline-block;
  margin-bottom: 12px;
  font-size: 0.75rem;
  letter-spacing: 0.04em;
}

.country-pill {
  display: inline-block;
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.08);
  color: #cbd5e1;
  font-size: 0.72rem;
  padding: 2px 7px;
  border-radius: 4px;
  margin: 2px;
}

/* --------------------------------------------------------------------------
   Search Input & Placeholder Contrast Fixes (Bright & High-Contrast)
   -------------------------------------------------------------------------- */
#dir-search-input,
#search-input,
.input[type="search"],
.input.is-rounded {
  color: #ffffff !important;
  background-color: #1e293b !important;
  border-color: rgba(255, 255, 255, 0.2) !important;
}

#dir-search-input:focus,
#search-input:focus,
.input[type="search"]:focus {
  border-color: #38bdf8 !important;
  box-shadow: 0 0 0 3px rgba(56, 189, 248, 0.25) !important;
}

/* High contrast placeholder styling across browsers */
#dir-search-input::placeholder,
#search-input::placeholder,
.input::placeholder,
.textarea::placeholder,
input::placeholder,
textarea::placeholder {
  color: #94a3b8 !important;
  opacity: 1 !important;
  -webkit-text-fill-color: #94a3b8 !important;
}

#dir-search-input::-webkit-input-placeholder,
#search-input::-webkit-input-placeholder,
.input::-webkit-input-placeholder,
.textarea::-webkit-input-placeholder,
input::-webkit-input-placeholder,
textarea::-webkit-input-placeholder {
  color: #94a3b8 !important;
  opacity: 1 !important;
  -webkit-text-fill-color: #94a3b8 !important;
}

#dir-search-input::-moz-placeholder,
#search-input::-moz-placeholder,
.input::-moz-placeholder,
.textarea::-moz-placeholder,
input::-moz-placeholder,
textarea::-moz-placeholder {
  color: #94a3b8 !important;
  opacity: 1 !important;
}

#dir-search-input:-ms-input-placeholder,
#search-input:-ms-input-placeholder,
.input:-ms-input-placeholder,
.textarea:-ms-input-placeholder,
input:-ms-input-placeholder,
textarea:-ms-input-placeholder {
  color: #94a3b8 !important;
  opacity: 1 !important;
}

/* --------------------------------------------------------------------------
   Attribution Control (Folded by default into compact info circle)
   -------------------------------------------------------------------------- */
.maplibregl-ctrl-attrib.maplibregl-compact {
  background-color: rgba(15, 23, 42, 0.9) !important;
  border: 1px solid rgba(255, 255, 255, 0.15) !important;
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  border-radius: 20px !important;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.5) !important;
}

.maplibregl-ctrl-attrib.maplibregl-compact summary {
  filter: invert(1);
}

.maplibregl-ctrl-attrib.maplibregl-compact a {
  color: #38bdf8 !important;
}


