/* River pages (web/rivers/<slug>.html, built by build/pages.py). Extends app.css: hero with scrim, stats strip, grade pills, gradient
   chart, rapid list, status flags. Palette and components stay the site's. */
.hero { position:relative; height:min(60vh, 520px); min-height:250px; overflow:hidden; background:#000; border-radius:0 0 var(--radius) var(--radius); }
.hero img { width:100%; height:100%; object-fit:cover; display:block; }
.hero .scrim { position:absolute; left:0; right:0; bottom:0; padding:40px 18px 16px; background:linear-gradient(to top, rgba(0,0,0,.80), rgba(0,0,0,.38) 55%, transparent); }
.hero h1 { margin:0; color:#fff; font-size:clamp(26px, 5vw, 42px); line-height:1.08; text-shadow:0 1px 3px rgba(0,0,0,.6); }
.hero .sub { color:#eef2f4; opacity:.92; margin-top:5px; font-size:14px; display:flex; gap:8px; flex-wrap:wrap; align-items:center; }
.hero .cred { position:absolute; right:10px; top:8px; color:#fff; opacity:.8; font-size:11.5px; background:rgba(0,0,0,.4); padding:2px 8px; border-radius:6px; }
.hero.noimg { height:auto; min-height:0; background:var(--panel); border:1px solid var(--line); }
.hero.noimg .scrim { position:static; background:none; padding:18px; }
.hero.noimg h1 { color:var(--text); text-shadow:none; }
.hero.noimg .sub { color:var(--muted); }

.statstrip { display:flex; gap:10px; overflow-x:auto; padding:12px 2px 6px; margin:8px 0 2px; scrollbar-width:none; -webkit-overflow-scrolling:touch; }
.statstrip::-webkit-scrollbar { display:none; }
.stat { flex:0 0 auto; min-width:92px; background:var(--panel); border:1px solid var(--line); border-radius:var(--radius); padding:9px 12px; box-shadow:var(--shadow); }
.stat .v { font-size:19px; font-weight:650; letter-spacing:-.01em; font-variant-numeric:tabular-nums; line-height:1.15; white-space:nowrap; }
.stat .v small { font-size:12px; color:var(--muted); font-weight:400; margin-left:3px; }
.stat .l { color:var(--muted); font-size:11px; margin-top:3px; text-transform:uppercase; letter-spacing:.05em; white-space:nowrap; }

.gpill { display:inline-block; font-weight:700; font-size:12.5px; padding:1px 9px; border-radius:999px; color:#fff; background:var(--g4); letter-spacing:.02em; line-height:1.6; white-space:nowrap; vertical-align:1px; }
.gpill.g3 { background:var(--g3); } .gpill.g4 { background:var(--g4); } .gpill.g5 { background:var(--g5); } .gpill.gs { background:var(--gs); }
.gpill.gx { background:transparent; color:var(--text); box-shadow:inset 0 0 0 2px var(--gx); }
.lt-report { display:inline-block; font-size:11.5px; font-weight:600; letter-spacing:.03em; text-transform:uppercase; padding:2px 8px; border-radius:999px; border:1.5px solid var(--info); color:var(--info); line-height:1.5; white-space:nowrap; }
.lt-ours { display:inline-block; font-size:11.5px; font-weight:600; letter-spacing:.03em; text-transform:uppercase; padding:2px 8px; border-radius:999px; background:color-mix(in srgb, var(--ok) 18%, transparent); color:var(--ok); line-height:1.5; white-space:nowrap; }

.crumb { font-size:13px; color:var(--muted); margin:12px 0 4px; }
.crumb a { color:var(--muted); }
.sec { margin:30px 0 8px; padding-top:14px; border-top:1px solid var(--line); }
.sec h2 { margin:0 0 2px; font-size:22px; line-height:1.2; }
.sec .meta { color:var(--muted); font-size:13px; margin-bottom:4px; }
.river h3 { margin:22px 0 6px; font-size:16.5px; }
.river p { margin:8px 0; }
.river .md p + p { margin-top:10px; }
.naming { background:var(--panel2); border-left:3px solid var(--accent2); padding:8px 12px; border-radius:6px; font-size:13.5px; margin:12px 0; }

.rmap { height:min(56vh, 460px); min-height:280px; border-radius:var(--radius); border:1px solid var(--line); overflow:hidden; margin:10px 0 4px; }
.leaflet-container .phicon { font-size:17px; line-height:26px; text-align:center; filter:drop-shadow(0 1px 1px rgba(0,0,0,.6)); }
.leaflet-container .phicon.access { opacity:.8; } .leaflet-container .phicon.scenery { opacity:.65; }
.leaflet-container .accicon { width:11px; height:11px; border-radius:50%; background:var(--accent2); border:2px solid #fff; box-shadow:0 0 0 1px rgba(0,0,0,.4); }
.maplegend { font-size:12px; color:var(--muted); display:flex; gap:14px; flex-wrap:wrap; margin:4px 0 10px; }

.gchart { position:relative; margin:8px 0 0; }
.gchart svg { width:100%; height:auto; display:block; overflow:visible; }
.gchart .b { fill:var(--muted); opacity:.6; }
.gchart .b.watch { fill:var(--accent); opacity:.95; }
.gchart .b.estimated { fill:url(#hatch); stroke:var(--muted); stroke-width:.8; opacity:.9; }
.gchart .b:hover { opacity:1; }
.gchart .avg { stroke:var(--text); stroke-dasharray:4 4; stroke-width:1; opacity:.6; }
.gchart .ax text { fill:var(--muted); font-size:11px; } .gchart .ax line { stroke:var(--line); }
.gchart .tick { stroke:var(--accent2); stroke-width:1.3; } .gchart .tl { fill:var(--accent2); font-size:10.5px; font-weight:600; }
.gchart .tip { position:absolute; pointer-events:none; background:var(--panel2); border:1px solid var(--line); border-radius:8px; padding:5px 9px; font-size:12.5px; box-shadow:var(--shadow); white-space:nowrap; z-index:5; display:none; }
.gkey { font-size:12px; color:var(--muted); display:flex; gap:14px; flex-wrap:wrap; margin:4px 0 8px; }
.gkey i { display:inline-block; width:14px; height:10px; vertical-align:-1px; margin-right:5px; border-radius:2px; background:var(--muted); opacity:.6; }
.gkey i.watch { background:var(--accent); opacity:1; } .gkey i.estimated { background:repeating-linear-gradient(135deg, var(--muted) 0 2px, transparent 2px 5px); opacity:.9; }

.rap { display:grid; grid-template-columns:56px 1fr; gap:2px 12px; padding:7px 0; border-top:1px dashed var(--line); font-size:14px; align-items:baseline; }
.rap:first-child { border-top:0; }
.rap .km { color:var(--muted); font-variant-numeric:tabular-nums; font-size:13px; }
.rap .n { font-weight:600; } .rap .n .gpill { margin-left:6px; }
.rap .note { grid-column:2; color:var(--muted); font-size:13.5px; }

.visit .lv { color:var(--muted); font-size:13.5px; }
.gallery figure .d { display:block; color:var(--text); font-weight:500; }
.gallery figure.hide { display:none; }
.lightbox .cap .d { display:block; opacity:.8; font-size:13px; }
.lightbox .x { position:absolute; top:10px; right:14px; color:#fff; font-size:30px; line-height:1; cursor:pointer; min-width:44px; min-height:44px; text-align:center; }
.vid video { width:100%; max-height:70vh; border-radius:8px; background:#000; }

.twocol { display:grid; grid-template-columns:1fr 1fr; gap:18px; }
.src { font-size:13px; color:var(--muted); padding-left:22px; } .src li { margin:3px 0; } .src a { word-break:break-all; }
.prevnext { display:flex; justify-content:space-between; gap:10px; margin:28px 0 10px; }
.prevnext a { padding:10px 14px; border:1px solid var(--line); border-radius:var(--radius); background:var(--panel); min-height:44px; display:flex; align-items:center; }
@media (max-width:720px) { .hero { height:48vh; } .twocol { grid-template-columns:1fr; } .sec h2 { font-size:20px; }
  .statstrip { display:grid; grid-template-columns:repeat(3, 1fr); gap:8px; overflow:visible; } .stat { min-width:0; padding:8px 10px; } .stat .v { font-size:17px; white-space:normal; } .stat .l { white-space:normal; } }

/* Leaflet layers control without its sprite (vendor/images is not shipped) */
.leaflet-control-layers-toggle { background-image:none !important; width:auto !important; height:auto !important; padding:7px 9px; font:600 12px system-ui, sans-serif; color:#222; }
.leaflet-control-layers-toggle::after { content:"Sat · Topo"; }
@media (max-width:720px) { .river .gallery { grid-template-columns:1fr 1fr; } }

.gallery figcaption .pt { display:block; color:var(--accent); font-weight:700; text-transform:uppercase; font-size:11.5px; letter-spacing:.04em; }

.leaflet-container { isolation:isolate; z-index:0; }   /* keep Leaflet's controls under the sticky header */
.stat.txt .v { font-size:14px; font-weight:600; line-height:1.25; white-space:normal; }
