/* Niagara interactive map styling
   Change --map-background below to experiment with the exposed map background. */
:root{--map-background:#000;}
:root{--paper:#f1ede3;--paper2:#fffdf7;--ink:#181818;--muted:#6b665e;--line:#c9c1b3;--red:#9e2b25;--blue:#2f67a3;--gold:#d2a018;--purple:#7c49a5}
*{box-sizing:border-box}html,body,#map{height:100%;margin:0}body{font-family:Arial,Helvetica,sans-serif;color:var(--ink);overflow:hidden}#map{background:var(--map-background,#000)}.leaflet-container{background:#000}
.panel{position:absolute;z-index:1000;top:16px;left:16px;width:min(440px,calc(100vw - 32px));max-height:calc(100vh - 32px);display:flex;flex-direction:column;background:rgba(241,237,227,.97);border:1px solid var(--line);box-shadow:0 16px 42px rgba(0,0,0,.24);backdrop-filter:blur(7px)}
.header{padding:18px 19px 12px}.header h1{margin:0;font:500 28px/1.05 Georgia,serif;letter-spacing:-.02em}.header p{margin:8px 0 0;color:var(--muted);font-size:12px;line-height:1.45}
.tabs{display:grid;grid-template-columns:repeat(3,1fr);border-top:1px solid var(--line);border-bottom:1px solid var(--line)}.tab{padding:10px 6px;border:0;border-right:1px solid var(--line);background:transparent;text-transform:uppercase;letter-spacing:.08em;font-size:10px;color:var(--muted);cursor:pointer}.tab:last-child{border-right:0}.tab.active{background:var(--paper2);color:var(--ink);font-weight:700}
.view{display:none;overflow:auto;padding:15px 19px 20px}.view.active{display:block}.search{width:100%;padding:10px;border:1px solid var(--line);background:#fffdf8;font-size:14px}
.section{margin:15px 0 8px;padding-top:12px;border-top:1px solid var(--line);font-size:10px;font-weight:700;letter-spacing:.12em;text-transform:uppercase;color:var(--muted)}
.filter{display:grid;grid-template-columns:18px 1fr auto;gap:7px;align-items:center;padding:5px 0;font-size:12.5px}.swatch{display:inline-block;width:10px;height:10px;border:1px solid #333;border-radius:50%;margin-right:7px;vertical-align:-1px}.count{color:var(--muted)}
.nhap-notice{display:none;margin-top:10px;padding:9px 10px;border:1px solid #cfb56b;background:#fff4d8;font-size:10.5px;line-height:1.4}
.status{margin-top:14px;padding:10px;border-left:3px solid var(--red);background:rgba(255,255,255,.55);font-size:11.5px;line-height:1.45}.note{font-size:11px;line-height:1.45;color:var(--muted)}
.card{margin-bottom:8px;padding:10px 11px;border:1px solid #d6cfc2;background:rgba(255,255,255,.58);cursor:pointer}.card:hover{background:#fffdf7}.card h3{margin:0;font:600 14px/1.3 Georgia,serif}.meta{margin-top:5px;color:var(--muted);font-size:10.5px;line-height:1.4}.badge{display:inline-block;margin-top:6px;padding:3px 6px;border:1px solid #bdb4a6;background:#fffaf0;font-size:9.5px;font-weight:700}.viewbtn{margin-top:7px;padding:5px 8px;border:1px solid #bdb4a6;background:#f7f2e8;font-size:10px;cursor:pointer}
.legend-row{display:flex;align-items:center;gap:8px;margin:6px 0;font-size:11px}.marker-ra,.marker-th{width:14px;height:13px;clip-path:polygon(50% 0,100% 100%,0 100%);filter:drop-shadow(0 0 1px #111);flex:0 0 auto}.marker-ra{background:#FF2A2A}.marker-th{background:#009E73}
.popup-title{font:600 18px/1.15 Georgia,serif;margin-bottom:6px}.popup-meta{font-size:10.5px;color:#6b665e;line-height:1.4}.popup-section{margin-top:10px;padding-top:8px;border-top:1px solid #ddd5c7;font-size:10px;font-weight:700;text-transform:uppercase;letter-spacing:.08em}.popup-text{font-size:11px;line-height:1.45}.reading-grid{display:grid;grid-template-columns:1fr auto;gap:3px 10px;margin-top:6px;font-size:11px}.reading-grid strong{font-variant-numeric:tabular-nums}.reading-note{margin-top:6px;color:#6b665e;font-size:9.5px;line-height:1.35}.popup-link{font-size:10.5px}.warning{margin-top:9px;padding-top:8px;border-top:1px solid #ddd5c7;color:#766f66;font-size:9.5px;line-height:1.35}
.anomaly-icon{display:flex;align-items:center;justify-content:center;overflow:visible!important}.anomaly-shape{width:14px;height:13px;clip-path:polygon(50% 0,100% 100%,0 100%);filter:drop-shadow(0 0 1px #111) drop-shadow(0 1px 2px rgba(0,0,0,.35))}.anomaly-shape.ra{background:#FF2A2A}.anomaly-shape.th{background:#009E73}.anomaly-shape.active{width:24px;height:22px;filter:drop-shadow(0 0 2px #fff) drop-shadow(0 0 4px #111) drop-shadow(0 0 10px rgba(255,210,0,.95))}
.site-dot{border-radius:50%;border:1px solid #111}.brownfield-icon{display:flex;align-items:center;justify-content:center}.brownfield-diamond{width:12px;height:12px;transform:rotate(45deg);border:2px solid #5d1746;background:#E04AA7;box-shadow:0 0 0 1px rgba(255,255,255,.95),0 1px 3px rgba(0,0,0,.45);position:relative}.brownfield-diamond::after{content:'';position:absolute;inset:3px;background:#fff;border:1px solid #5d1746;border-radius:50%}.brownfield-diamond.active{width:18px;height:18px;border:3px solid #5d1746;box-shadow:0 0 0 3px #fff,0 0 16px 6px rgba(255,210,0,.95)}.brownfield-legend{display:inline-block;width:12px;height:12px;transform:rotate(45deg);border:2px solid #5d1746;background:#E04AA7;margin:0 6px 0 3px;vertical-align:-2px}.fusrap-icon{display:flex;align-items:center;justify-content:center;overflow:visible!important}.fusrap-hex{width:16px;height:16px;clip-path:polygon(25% 7%,75% 7%,100% 50%,75% 93%,25% 93%,0 50%);background:#245A9B;border:0;box-shadow:inset 0 0 0 3px #F2C94C,0 1px 4px rgba(0,0,0,.55);position:relative}.fusrap-hex::after{content:'';position:absolute;inset:5px;border-radius:50%;background:#fff}.fusrap-hex.active{width:22px;height:22px;box-shadow:inset 0 0 0 4px #F2C94C,0 0 0 3px #fff,0 0 16px 6px rgba(255,210,0,.95)}.fusrap-legend{display:inline-block;width:16px;height:16px;clip-path:polygon(25% 7%,75% 7%,100% 50%,75% 93%,25% 93%,0 50%);background:#245A9B;box-shadow:inset 0 0 0 3px #F2C94C;position:relative;margin:0 4px 0 1px;vertical-align:-3px}.fusrap-legend::after{content:'';position:absolute;inset:5px;border-radius:50%;background:#fff}.brownfield-hotspot-legend{display:inline-block;width:14px;height:14px;border-radius:50%;background:#FF1F1F;border:3px solid #FFD84D;box-shadow:0 0 0 1px #111;margin:0 5px 0 1px;vertical-align:-3px}.brownfield-hotspot-icon{display:flex;align-items:center;justify-content:center;overflow:visible!important}.brownfield-hotspot-dot{display:block;width:14px;height:14px;border-radius:50%;background:#FF1F1F;border:3px solid #FFD84D;box-shadow:0 0 0 1px #111,0 1px 5px rgba(0,0,0,.65)}.brownfield-hotspot-dot::after{content:'';display:block;width:4px;height:4px;border-radius:50%;background:#fff;margin:5px}.survey-clear-icon{display:flex;align-items:center;justify-content:center;overflow:visible!important}.survey-clear-dot{display:block;width:14px;height:14px;border-radius:50%;background:#fff;border:3px solid #2D73C8;box-shadow:0 0 0 1px #111,0 1px 5px rgba(0,0,0,.55);position:relative}.survey-clear-dot::after{content:'✓';position:absolute;left:1px;top:-5px;font-size:15px;font-weight:800;color:#2D73C8;transform:none}.survey-clear-legend{display:inline-flex;align-items:center;justify-content:center;width:14px;height:14px;border-radius:50%;background:#fff;border:3px solid #2D73C8;box-shadow:0 0 0 1px #111;margin:0 5px 0 1px;vertical-align:-3px;font-size:12px;font-weight:800;color:#2D73C8}.brownfield-area-legend{display:inline-block;width:19px;height:12px;border-radius:50%;border:2px dashed #C13B8A;background:rgba(224,74,167,.14);margin:0 3px 0 0}.globe-corridor-legend{display:inline-block;width:22px;height:0;border-top:4px dashed #B11919;margin:0 4px 3px 0}.modern-icon{display:flex;align-items:center;justify-content:center}.modern-diamond{width:18px;height:18px;transform:rotate(45deg);border:2px solid #111;background:#7a7a7a;box-shadow:0 1px 4px rgba(0,0,0,.45);position:relative}.modern-diamond::after{content:'';position:absolute;inset:4px;background:#fff;border:1px solid #111}.modern-diamond.active{width:26px;height:26px;border:3px solid #111;box-shadow:0 0 0 4px #fff,0 0 20px 8px rgba(255,210,0,.95)}.modern-legend{display:inline-block;width:14px;height:14px;transform:rotate(45deg);border:2px solid #111;background:#7a7a7a;position:relative;margin:0 5px 0 2px;vertical-align:-2px}.modern-legend::after{content:'';position:absolute;inset:3px;background:#fff;border:1px solid #111}.leaflet-popup-content-wrapper{border-radius:0}.leaflet-popup-content{min-width:245px;max-width:340px}
.show-more{width:100%;padding:9px;border:1px solid var(--line);background:var(--paper2);font-weight:700;cursor:pointer}#archiveView a{color:#111;text-decoration:none}#archiveView a:visited{color:#111}#archiveView a:hover{text-decoration:underline}.map-credit{background:rgba(241,237,227,.9);padding:4px 7px;border:1px solid var(--line);font-size:9.5px}
@media(max-width:700px){.panel{top:8px;left:8px;width:calc(100vw - 16px);max-height:50vh}.header{padding:13px 14px 9px}.header h1{font-size:23px}.view{padding:12px 14px 15px}.leaflet-control-layers{margin-top:51vh!important}}

.factory-survey-icon{display:flex;align-items:center;justify-content:center;overflow:visible!important}.factory-survey-shape{width:16px;height:15px;clip-path:polygon(50% 0,100% 100%,0 100%);filter:drop-shadow(0 0 1px #111) drop-shadow(0 1px 3px rgba(0,0,0,.55))}.factory-survey-shape.tam{background:#E04AA7}.factory-survey-shape.covanta{background:#F07824}.factory-survey-shape.powercity{background:#B11919}.factory-survey-shape.electromet{background:#376da8}.factory-tam-legend,.factory-covanta-legend,.factory-powercity-legend,.factory-electromet-legend{display:inline-block;width:15px;height:14px;clip-path:polygon(50% 0,100% 100%,0 100%);filter:drop-shadow(0 0 1px #111);flex:0 0 auto}.factory-tam-legend{background:#E04AA7}.factory-covanta-legend{background:#F07824}.factory-powercity-legend{background:#B11919}.factory-electromet-legend{background:#376da8}.aerial-footprint-legend{display:inline-block;width:22px;height:12px;border:2px dashed #4d4d4d;background:rgba(90,90,90,.06)}.aerial-ra-legend{display:inline-block;width:22px;height:12px;border:2px solid #B33A1D;background:rgba(216,91,45,.28);border-radius:50%}.aerial-th-legend{display:inline-block;width:22px;height:12px;border:2px solid #167A54;background:rgba(22,122,84,.25);border-radius:50%}.aerial-2023-boundary-legend{display:inline-block;width:22px;height:12px;border:3px dashed #7A3DB8;background:rgba(122,61,184,.04)}.robert-moses-icon{display:flex;align-items:center;justify-content:center;overflow:visible!important}.robert-moses-diamond{display:block;width:15px;height:15px;transform:rotate(45deg);background:#FFD84D;border:3px solid #B11919;box-shadow:0 0 0 1px rgba(255,255,255,.95),0 1px 4px rgba(0,0,0,.55)}.robert-moses-legend{display:inline-block;width:14px;height:14px;transform:rotate(45deg);background:#FFD84D;border:3px solid #B11919;box-shadow:0 0 0 1px rgba(255,255,255,.95);margin:0 6px 0 3px;vertical-align:-2px}.coord-progress{margin-top:10px;padding:8px 10px;border-left:3px solid #2f67a3;background:rgba(255,255,255,.55);font-size:10.5px;line-height:1.4}.unresolved-card{border-left:4px solid #777}.viewbtn[disabled]{opacity:.55;cursor:not-allowed}
.radioactive-waste-icon{display:flex;align-items:center;justify-content:center;overflow:visible!important}.radioactive-waste-square{display:block;width:17px;height:17px;background:#111;border:3px solid #FFD84D;box-shadow:0 0 0 1px #111,0 1px 5px rgba(0,0,0,.65)}.radioactive-waste-legend{display:inline-block;width:15px;height:15px;background:#111;border:3px solid #FFD84D;box-shadow:0 0 0 1px #111;margin:0 4px 0 1px;vertical-align:-3px}

.radioactive-creek-legend{display:inline-block;width:24px;height:0;border-top:5px solid #8B1E1E;margin:0 3px 2px 0}.hydrologic-pathway-legend{display:inline-block;width:24px;height:0;border-top:4px dashed #246B8E;margin:0 3px 2px 0}
.leaflet-top.leaflet-right{display:flex;flex-direction:row-reverse;align-items:flex-start;gap:8px;top:16px;right:16px}.leaflet-top.leaflet-right>.leaflet-control{margin:0}.radiation-guide{font-family:Arial,Helvetica,sans-serif}.radiation-guide-button{border:1px solid #000;background:#000;color:#fff;padding:11px 16px;font-size:13px;font-weight:700;cursor:pointer;box-shadow:0 2px 8px rgba(0,0,0,.22)}.radiation-guide-button:hover,.radiation-guide-button:focus{background:#222;color:#fff}.radiation-guide-panel{display:none;margin-top:5px;width:290px;padding:12px 13px;border:1px solid #8f877a;background:rgba(241,237,227,.98);box-shadow:0 8px 24px rgba(0,0,0,.24);font-size:11px;line-height:1.45}.radiation-guide-panel.open{display:block}.radiation-guide-panel strong{font-weight:700}.radiation-guide-panel p{margin:0 0 8px}.radiation-guide-panel p:last-child{margin-bottom:0}@media(max-width:700px){.radiation-guide-panel{width:min(290px,calc(100vw - 28px))}.radiation-guide{margin-top:6px!important;margin-right:6px!important}}

/* Editable historical-map background */
#map, .leaflet-container, .leaflet-map-pane, .leaflet-tile-pane { background: var(--map-background, #000); }

/* ==========================================================
   PROCESS PANEL
   ========================================================== */

.tabs{
    grid-template-columns:repeat(4,1fr);
}

.process-intro{
    margin:0 0 12px;
    color:var(--muted);
    font-size:11.5px;
    line-height:1.45;
}

.process-step{
    margin:0 0 8px;
    border:1px solid #d6cfc2;
    background:rgba(255,255,255,.58);
}

.process-step summary{
    display:grid;
    grid-template-columns:30px 1fr;
    gap:9px;
    align-items:center;
    padding:10px 11px;
    cursor:pointer;
    list-style:none;
}

.process-step summary::-webkit-details-marker{
    display:none;
}

.process-step summary:hover,
.process-step.active summary{
    background:#fffdf7;
}

.process-number{
    display:flex;
    align-items:center;
    justify-content:center;
    width:27px;
    height:27px;
    border:1px solid #181818;
    border-radius:50%;
    background:#fffdf7;
    font-weight:700;
    font-size:12px;
}

.process-name{
    font:600 14px/1.2 Georgia,serif;
}

.process-location{
    display:block;
    margin-top:2px;
    color:var(--muted);
    font:10px/1.3 Arial,Helvetica,sans-serif;
}

.process-body{
    padding:0 12px 12px 50px;
    color:#37332e;
    font-size:11px;
    line-height:1.5;
}

.process-map-button{
    margin-top:8px;
    padding:6px 9px;
    border:1px solid #181818;
    background:#181818;
    color:#fff;
    font-size:10px;
    font-weight:700;
    cursor:pointer;
}

.process-map-button:hover{
    background:#333;
}

.process-note{
    margin-top:12px;
    padding:9px 10px;
    border-left:3px solid var(--gold);
    background:rgba(255,255,255,.55);
    color:var(--muted);
    font-size:10.5px;
    line-height:1.45;
}

/* ==========================================================
   1985 SURVEY SOURCE LINK
   ========================================================== */

.survey-source-link{
    margin:0 0 12px;
    padding:10px 11px;
    border-left:3px solid var(--gold);
    background:rgba(255,255,255,.58);
    font-size:11px;
    line-height:1.5;
}

.survey-source-link a{
    color:#191919;
    text-decoration:underline;
    text-underline-offset:2px;
}

.survey-source-link a:hover{
    color:#6d4d00;
}



/* ==========================================================
   PROCESS — WASTE / STORAGE BRANCH
   ========================================================== */

.process-waste-step .process-body a{
    font-weight:700;
    text-decoration:underline;
    text-underline-offset:2px;
}





/* ==========================================================
   PROCESS MAP NUMBER BADGES
   ========================================================== */

.process-number-map-icon{
  background:transparent;
  border:0;
  overflow:visible;
pointer-events:auto;}

.process-number-map-icon span{
  display:flex;
  align-items:center;
  justify-content:center;
  width:27px;
  height:27px;
  box-sizing:border-box;
  border:2px solid #111;
  border-radius:50%;
  background:#f7f3e8;
  color:#111;
  font-family:Arial, Helvetica, sans-serif;
  font-size:13px;
  font-weight:800;
  line-height:1;
  box-shadow:0 1px 4px rgba(0,0,0,.48);
  transform:translateY(-28px);
}


/* ==========================================================
   SITE LINK COLOR
   ========================================================== */

a,
a:visited,
a:hover,
a:active,
.popup-link a,
.process-body a,
.survey-source-link a{
  color:#111 !important;
}


/* ==========================================================
   LAYERS PANEL CLOSE BUTTON
   ========================================================== */

.leaflet-control-layers{
  position:relative;
}

.layer-control-close{
  display:none;
  position:absolute;
  top:5px;
  right:6px;
  z-index:20;
  width:28px;
  height:28px;
  padding:0;
  border:0;
  background:transparent;
  color:#111;
  font:700 25px/28px Arial, sans-serif;
  text-align:center;
  cursor:pointer;
}

.leaflet-control-layers-expanded .layer-control-close{
  display:block;
}

.leaflet-control-layers-expanded{
  padding-top:30px;
}


.header a,
.process-body a,
.popup-text a,
.popup-link a,
.status a,
.note a{
  color:#111 !important;
}


/* Short leader line beneath each process number */
.process-number-map-icon i{
  position:absolute;
  left:14px;
  top:1px;
  width:2px;
  height:15px;
  background:#111;
  pointer-events:none;
}


/* ==========================================================
   LAYERS PANEL HEADING
   ========================================================== */

.layer-control-heading{
  display:block !important;
  width:100%;
  box-sizing:border-box;
  margin:0 0 8px;
  padding:0 0 7px;
  border-bottom:1px solid #c9c3b7;
  color:#111 !important;
  background:transparent;
  font:700 13px/1.2 Arial, sans-serif;
  letter-spacing:.08em;
  text-transform:uppercase;
}


/* ==========================================================
   RELATED PROCESS-SITE MAP ANCHOR
   ========================================================== */

.process-related-site-button{
  margin-top:7px;
}

/* =========================
   MOBILE
   ========================= */

@media (max-width: 768px) {
  html,
  body {
    width: 100%;
    min-width: 0;
    overflow-x: hidden;
  }

  body {
    font-size: 15px;
  }

  /* Main page structure */
  .app,
  .map-layout,
  .main-layout,
  .container {
    display: flex;
    flex-direction: column;
    width: 100%;
    height: auto;
    min-height: 100vh;
  }

  /* Left information panel */
  .sidebar,
  .left-panel,
  #sidebar {
    position: relative;
    width: 100%;
    max-width: none;
    height: auto;
    max-height: none;
    overflow: visible;
    box-sizing: border-box;
    padding: 16px;
    border-right: none;
    border-bottom: 4px solid #d3d3d3;
  }

  /* Map */
  #map,
  .map {
    position: relative;
    width: 100%;
    height: 65vh;
    min-height: 480px;
  }

  /* Header */
  .site-header,
  .header {
    padding: 14px 16px;
  }

  .site-title,
  .header h1,
  h1 {
    font-size: 24px;
    line-height: 1.1;
    overflow-wrap: anywhere;
  }

  .subtitle,
  .site-subtitle {
    font-size: 14px;
    line-height: 1.45;
  }

  /* Tabs */
  .tabs,
  .tab-buttons,
  .navigation-tabs {
    display: grid;
    grid-template-columns: 1fr 1fr;
    width: 100%;
    gap: 6px;
  }

  .tab-button,
  .tab-btn,
  .tabs button {
    width: 100%;
    min-width: 0;
    padding: 10px 8px;
    font-size: 13px;
    white-space: normal;
    line-height: 1.2;
  }

  /* Process sections */
  .process-item,
  .process-section,
  details {
    width: 100%;
    box-sizing: border-box;
  }

  .process-item summary,
  .process-section summary,
  details summary {
    padding: 12px 8px;
    line-height: 1.3;
  }

  /* Buttons and links */
  button,
  .map-button,
  .show-on-map,
  .reference-link {
    max-width: 100%;
    white-space: normal;
    overflow-wrap: anywhere;
  }

  /* Leaflet controls */
  .leaflet-top.leaflet-right {
    top: 8px;
    right: 8px;
  }

  .leaflet-top.leaflet-left {
    top: 8px;
    left: 8px;
  }

  .leaflet-control-layers {
    max-width: calc(100vw - 32px);
    max-height: 65vh;
    overflow-y: auto;
  }

  .leaflet-control-layers-expanded {
    width: calc(100vw - 32px);
    box-sizing: border-box;
  }

  /* Radiation Guide */
  .radiation-guide-button,
  .radiation-guide-btn,
  #radiation-guide-button {
    max-width: 150px;
    padding: 9px 11px;
    font-size: 13px;
    line-height: 1.2;
  }

  .radiation-guide-panel,
  #radiation-guide-panel {
    width: calc(100vw - 32px);
    max-width: none;
    max-height: 65vh;
    overflow-y: auto;
    box-sizing: border-box;
  }

  /* Popups */
  .leaflet-popup-content-wrapper {
    max-width: calc(100vw - 40px);
  }

  .leaflet-popup-content {
    width: auto !important;
    max-width: calc(100vw - 70px);
    margin: 14px 16px;
    font-size: 14px;
    line-height: 1.4;
    overflow-wrap: anywhere;
  }

  .leaflet-popup-content img,
  .leaflet-popup-content iframe,
  .leaflet-popup-content video {
    width: 100%;
    max-width: 100%;
    height: auto;
  }

  /* Numbered map markers */
  .process-number,
  .numbered-marker,
  .process-badge {
    transform: scale(0.88);
    transform-origin: center bottom;
  }
}


/* Rotate-phone message */
.rotate-to-view {
  display: none;
}

@media (max-width: 768px) and (orientation: portrait) {

  .rotate-to-view {
    position: fixed;
    inset: 0;
    z-index: 99999;

    display: flex !important;
    flex-direction: column !important;
    align-items: center !important;
    justify-content: center !important;
    gap: 18px;

    padding: 30px;
    box-sizing: border-box;
    background: #000;
    color: #fff;
    text-align: center;
  }

  .rotate-message {
    width: calc(100vw - 50px);
    max-width: 420px;
    padding: 28px 22px;
    border: 5px solid #fff;
    box-sizing: border-box;

    color: #fff;
    font-size: 1.2rem;
    font-weight: 400;
    letter-spacing: 0.10em;
    line-height: 1.35;
    text-align: center;
  }

  .rotate-phone-icon {
    position: relative;
    width: 80px;
    height: 80px;
    flex: 0 0 80px;
    animation: rotatePlus 2.2s linear 1 forwards;
  }

  .rotate-phone-icon::before,
  .rotate-phone-icon::after {
    content: "";
    position: absolute;
    top: 50%;
    left: 50%;
    width: 42px;
    height: 6px;
    background: #fff;
    transform-origin: center;
  }

  .rotate-phone-icon::before {
    transform: translate(-50%, -50%);
  }

  .rotate-phone-icon::after {
    transform: translate(-50%, -50%) rotate(90deg);
  }

  body > *:not(.rotate-to-view) {
    visibility: hidden;
  }

  @keyframes rotatePlus {
    from {
      transform: rotate(0deg);
    }

    to {
      transform: rotate(360deg);
    }
  }
}

/* Mobile landscape panel fix */
@media (max-width: 900px) and (orientation: landscape) {

  .panel {
    position: absolute;
    top: 8px;
    left: 8px;
    width: 38vw;
    max-width: 520px;
    height: calc(100vh - 16px);
    max-height: none;
    overflow: hidden;
  }

  .view {
    min-height: 0;
    overflow-y: auto;
  }

  .tabs {
    grid-template-columns: repeat(4, 1fr);
    gap: 0;
  }

  .tabs button {
    padding: 9px 3px;
    font-size: 10px;
    white-space: nowrap;
  }

  #map {
    width: 100vw;
    height: 100vh;
    min-height: 0;
  }
}

/* iPhone landscape - Smaller Layers control */
@media (max-width: 900px) and (orientation: landscape) {

  .leaflet-control-layers-expanded {
    width: 230px !important;
    max-width: 230px !important;
    max-height: calc(70vh - 90px) !important;
    overflow-y: auto !important;
    box-sizing: border-box;
  }

  .leaflet-control-layers-list {
    font-size: 10px;
    line-height: 1.1;
  }

  .leaflet-control-layers label {
    display: block;
    white-space: normal;
  }
}

/* Keep aerial survey images beneath hotspots and survey graphics */
.leaflet-overlay-pane .leaflet-image-layer {
  z-index: 0 !important;
}

.leaflet-overlay-pane svg,
.leaflet-overlay-pane canvas {
  z-index: 1 !important;
}

/* Keep TENORM / radioactive-waste markers above factory markers */
.leaflet-marker-icon.radioactive-waste-icon {
  z-index: 5000 !important;
  pointer-events: auto !important;
  cursor: pointer;
}

.radioactive-waste-icon * {
  pointer-events: auto !important;
}
