/* Public pages: docked navigation, touch layouts and safe-area spacing. */
html { scroll-padding-top: 110px; }
body { min-width: 320px; }
.topbar, body > nav {
  position: fixed;
  inset: 0 0 auto;
  width: 100%;
  z-index: 3000;
  box-sizing: border-box;
  padding: calc(12px + env(safe-area-inset-top, 0px)) max(20px, env(safe-area-inset-right, 0px)) 12px max(20px, env(safe-area-inset-left, 0px));
  background: rgba(38, 41, 44, .86);
  border-bottom: 1px solid rgba(255,255,255,.14);
  box-shadow: 0 8px 28px rgba(0,0,0,.2);
  -webkit-backdrop-filter: blur(22px) saturate(135%);
  backdrop-filter: blur(22px) saturate(135%);
  pointer-events: auto;
}
.topbar .brand { flex-shrink: 0; }
.topbar .top-actions { min-width: 0; }
.topbar .ghost-link { white-space: nowrap; }
.lang-btn { min-width: 32px; min-height: 44px; }
.cookie-banner[hidden] { display: none !important; }
.cookie-banner {
  bottom: calc(16px + env(safe-area-inset-bottom, 0px));
  max-height: calc(100dvh - 130px);
  overflow-y: auto;
  -webkit-backdrop-filter: blur(24px);
}
.cookie-banner button { min-height: 44px; }
#hub { scroll-margin-top: 110px; }
.route-grid { grid-template-columns: repeat(auto-fill, minmax(min(100%, 340px), 1fr)); }
.leaflet-control-attribution { max-width: 100%; white-space: normal; font-size: 10px; }
@media (max-width: 860px) {
  .topbar { gap: 12px; }
  .top-actions { gap: 8px; }
  .hub { padding: 110px 20px 64px; }
  .hub-header { margin-bottom: 40px; }
  .map-container { height: min(740px, 80svh); min-height: 480px; border-radius: 20px; }
  .map-top-controls { top: 12px; left: 12px; right: 12px; gap: 6px; flex-wrap: wrap; justify-content: flex-end; }
  .map-hint-wrapper { display: none; }
  .network-toggle { min-height: 44px; padding: 0 10px; font-size: .75rem; }
  .side-panels-wrap { top: 68px; left: 12px; width: min(320px, calc(100% - 24px)); max-height: calc(100% - 160px); overflow-y: auto; gap: 8px; }
  .side-panel.is-collapsed { width: min(220px, 100%); }
  .side-panel-header { min-height: 48px; padding: 12px 14px; }
  .side-panel-body { max-height: 240px; }
  .map-layer-toggle { width: 58px; height: 58px; bottom: 36px; right: 58px; }
  .leaflet-control-zoom { margin-bottom: 36px !important; }
  body > nav { padding-left: 16px; padding-right: 16px; gap: 12px; }
  body > nav > div { gap: 10px !important; flex-wrap: wrap; justify-content: flex-end; }
  .detail-header { left: 6%; right: 6%; max-width: none; }
  .detail-header h1 { white-space: normal; font-size: clamp(2rem, 7vw, 3.5rem); }
  .mega-grid { grid-template-columns: minmax(0, 1fr); gap: 32px; }
  .quick-info-card { padding: 32px 20px; width: calc(100% - 24px); height: 85dvh; }
  .quick-info-card h2 { margin-bottom: 32px; letter-spacing: .06em; }
  .legal-footer, .legal-links { flex-wrap: wrap; gap: 20px; }
  .legal-footer { margin-top: 48px; }
}
@media (max-width: 600px) {
  .topbar { align-items: center; gap: 8px; padding-left: 12px; padding-right: 12px; }
  .topbar .brand { font-size: 17px; }
  .topbar .top-actions { display: grid; grid-template-columns: auto auto; gap: 2px 8px; justify-items: end; }
  .topbar .lang-switcher { grid-column: 1 / -1; gap: 2px; }
  .topbar .lang-btn { min-height: 32px; font-size: 12px; padding: 4px; }
  .topbar .ghost-link { padding: 8px 10px; font-size: 12px; min-height: 36px; display: inline-flex; align-items: center; }
  .hero-copy, .footer-copy { margin-left: 0; padding-right: 0; }
  .beat { width: calc(100% - 40px); margin-left: 20px; padding-top: 112px; padding-bottom: 24px; }
  .beat h1 { font-size: clamp(2.5rem, 11vw, 4rem); overflow-wrap: anywhere; }
  .scene-text { font-size: 1rem; margin-top: 20px; }
  .hero-actions { gap: 8px; margin-top: 24px; }
  .hub { padding-left: 12px; padding-right: 12px; }
  .hub h2 { font-size: clamp(2rem, 9vw, 3rem); }
  .hub-intro { font-size: 1rem; }
  .poi-filter-bar { gap: 6px; margin-bottom: 24px; }
  .filter-chip { min-height: 40px; }
  .view-switcher { max-width: 100%; }
  .view-btn { padding: 12px; font-size: .8rem; }
  .route-grid, .hub-grid, .details-grid { grid-template-columns: minmax(0, 1fr); gap: 20px; }
  .cookie-banner { width: calc(100% - 24px); padding: 16px; gap: 12px; bottom: calc(12px + env(safe-area-inset-bottom, 0px)); }
  .cookie-banner button { width: 100%; }
  body > nav .logo { font-size: 1.15rem; }
  body > nav .back-link { font-size: .75rem; }
  body > nav .lang-switcher { gap: 2px !important; }
  .text-section { padding: 48px 20px; }
  .text-section h2 { font-size: 2rem; }
  .text-section p { font-size: 1rem; }
  .cms-inline-row { grid-template-columns: minmax(0, 1fr); }
  input, select, textarea { min-width: 0; max-width: 100%; font-size: 16px; }
}
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .cookie-banner { transition: none; }
}

.cookie-banner { z-index: 10000; }
.quick-info-overlay { z-index: 4000; }
@media (max-width: 600px) {
  .highlights { left: 6%; width: 88%; gap: 8px; }
  .highlight-item { padding: 12px; gap: 10px; }
  .highlight-item h3 { font-size: .85rem; letter-spacing: .03em; }
  .highlight-item p { font-size: .8rem; }
  .hero-title-container { left: 6%; right: 6%; bottom: 18%; }
  .status-bar { left: 6%; right: 6%; bottom: 24px; gap: 8px; flex-wrap: wrap; }
  .status-label { font-size: .65rem; letter-spacing: .05em; }
  .footer-end { padding: 60px 20px 32px; }
  .footer-beat { padding: 100px 20px 24px; }
  .footer-beat h1 { font-size: clamp(2rem, 10vw, 3rem); }
  .footer-beat .scene-text { font-size: 1rem; }
  .footer-grid > *, .highlight-content { min-width: 0; }
  .log-item { flex-wrap: wrap; gap: 6px; }
}

@media (max-width: 860px) {
  .hero-copy, .footer-copy { margin-left: 0; padding-right: 0; }
  .beat { width: calc(100% - 40px); margin-left: 20px; }
  .newsletter-box { right: 20px; max-width: calc(100% - 40px); transform: translateY(20px); padding: 24px; }
  .newsletter-box.is-visible { transform: none; }
}
