* { margin: 0; padding: 0; box-sizing: border-box; }

html { scroll-behavior: smooth; }

html, body { font-family: system-ui, -apple-system, "Segoe UI", sans-serif; }

body { background: #14161a; color: #e8e8e8; }

/* La carte occupe tout l'écran ; le contenu éditorial (#infos) défile en dessous. */
#app {
  display: flex;
  flex-direction: column;
  height: 100vh;
  height: 100dvh;
}

#topbar {
  display: flex;
  align-items: baseline;
  gap: 14px;
  padding: 10px 18px;
  background: #1c1f26;
  border-bottom: 1px solid #2c313c;
  flex-wrap: wrap;
}

#topbar h1 { font-size: 1.15rem; font-weight: 700; }

#subtitle { font-size: 0.85rem; font-weight: 400; color: #9aa3b2; }

#statusbar { margin-left: auto; font-size: 0.8rem; color: #9aa3b2; }

#topnav { display: flex; gap: 14px; }

#topnav a {
  font-size: 0.8rem;
  color: #ffb347;
  text-decoration: none;
  white-space: nowrap;
}
#topnav a:hover { text-decoration: underline; }

#map { flex: 1; min-height: 0; background: #14161a; }

.noscript-note {
  padding: 24px;
  max-width: 720px;
  margin: 0 auto;
  line-height: 1.6;
}
.noscript-note a { color: #ffb347; }

/* ---- Contenu éditorial sous la carte ---- */
#infos { background: #14161a; border-top: 1px solid #2c313c; }

.content {
  max-width: 860px;
  margin: 0 auto;
  padding: 40px 20px 24px;
  line-height: 1.7;
  font-size: 0.95rem;
}

.content h2 {
  font-size: 1.25rem;
  color: #ffb347;
  margin: 36px 0 12px;
}
.content h2:first-child { margin-top: 0; }

.content p { margin-bottom: 12px; color: #c9cfd9; }

.content a { color: #ffb347; }

.content ul { margin: 0 0 12px 4px; list-style: none; }
.content li { margin-bottom: 6px; color: #c9cfd9; }

.content .dot {
  display: inline-block;
  width: 11px;
  height: 11px;
  border-radius: 50%;
  margin-right: 8px;
  vertical-align: -1px;
}

.content .square {
  display: inline-block;
  width: 11px;
  height: 11px;
  margin-right: 8px;
  background: rgba(160, 82, 45, 0.55);
  border: 1px solid #a0522d;
  vertical-align: -1px;
}

.content .live {
  padding: 10px 14px;
  border-left: 3px solid #ff9500;
  background: #1c1f26;
  border-radius: 0 8px 8px 0;
  color: #e8e8e8;
}

.content details {
  background: #1c1f26;
  border: 1px solid #2c313c;
  border-radius: 8px;
  padding: 10px 14px;
  margin-bottom: 8px;
}
.content summary {
  cursor: pointer;
  font-weight: 600;
  color: #e8e8e8;
}
.content details p { margin: 10px 0 2px; }

#site-footer {
  background: #101216;
  border-top: 1px solid #2c313c;
  font-size: 0.8rem;
  color: #9aa3b2;
}
#site-footer .content { padding: 18px 20px; }
#site-footer a { color: #ffb347; text-decoration: none; }
#site-footer a:hover { text-decoration: underline; }

/* Légende */
.legend {
  background: rgba(28, 31, 38, 0.92);
  color: #e8e8e8;
  padding: 10px 14px;
  border-radius: 8px;
  font-size: 0.8rem;
  line-height: 1.7;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.4);
}

.legend h4 { margin-bottom: 4px; font-size: 0.85rem; }

.legend .dot {
  display: inline-block;
  width: 11px;
  height: 11px;
  border-radius: 50%;
  margin-right: 7px;
  vertical-align: -1px;
}

.legend .square {
  display: inline-block;
  width: 11px;
  height: 11px;
  margin-right: 7px;
  background: rgba(160, 82, 45, 0.55);
  border: 1px solid #a0522d;
  vertical-align: -1px;
}

/* Popups adaptées au thème sombre */
.leaflet-popup-content-wrapper, .leaflet-popup-tip {
  background: #1c1f26;
  color: #e8e8e8;
  box-shadow: 0 2px 12px rgba(0, 0, 0, 0.5);
}

.leaflet-popup-content { font-size: 0.85rem; line-height: 1.5; }

.leaflet-popup-content b { color: #ffb347; }

.leaflet-container a.leaflet-popup-close-button { color: #9aa3b2; }
