:root {
  --bg: #0a0f1c; --bg2: #0e1526; --card: #121a2e; --line: #222e4a; --line2: #2c3a5c;
  --tx: #eef2fa; --mut: #8d9bb8; --ac: #5fb4ff; --ac2: #9a7bff;
  --ok: #3ddc97; --warn: #ffd43b; --orange: #ff8c1a; --red: #ff3b5c; --violet: #be28dc;
  --r: 14px;
}
* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0; color: var(--tx); font: 15px/1.45 Inter, system-ui, -apple-system, sans-serif;
  background: radial-gradient(1200px 600px at 80% -10%, #1a2350 0%, transparent 60%), var(--bg);
  background-attachment: fixed; min-height: 100vh;
}
a { color: var(--ac); }
h1, h2, h3 { margin: 0; letter-spacing: -.01em; }
h2 { font-size: 1rem; font-weight: 700; }
.muted { color: var(--mut); font-size: .85rem; margin: 4px 0 8px; }
button { font: inherit; color: inherit; cursor: pointer; }

/* Header */
.top {
  position: sticky; top: 0; z-index: 1000; display: flex; flex-wrap: wrap; align-items: center; gap: 10px 16px;
  padding: 12px 16px; background: rgba(10, 15, 28, .85); backdrop-filter: blur(12px); border-bottom: 1px solid var(--line);
}
.brand { display: flex; align-items: center; gap: 10px; margin-right: auto; }
.brand h1 { font-size: 1.15rem; font-weight: 800; }
.brand p { margin: 0; color: var(--mut); font-size: .75rem; }
.status { display: flex; gap: 6px; flex-wrap: wrap; }
.pill { display: inline-flex; align-items: center; gap: 6px; padding: 4px 10px; border-radius: 999px; font-size: .75rem; background: var(--bg2); border: 1px solid var(--line); color: var(--mut); }
.pill i { width: 7px; height: 7px; border-radius: 50%; background: var(--ok); }
.pill.bad i { background: var(--red); } .pill.warn i { background: var(--warn); }

/* Segmented / chips */
.seg { display: inline-flex; background: var(--bg2); border: 1px solid var(--line); border-radius: 10px; padding: 3px; gap: 2px; }
.seg button { border: 0; background: none; padding: 7px 12px; border-radius: 8px; color: var(--mut); font-weight: 600; font-size: .85rem; white-space: nowrap; }
.seg button.on { background: var(--ac); color: #04121f; }
.seg.small button { padding: 5px 9px; font-size: .78rem; }
.chips { display: flex; flex-wrap: wrap; gap: 6px; }
.chip { border: 1px solid var(--line2); background: var(--bg2); border-radius: 999px; padding: 5px 11px; font-size: .8rem; color: var(--mut); font-weight: 500; }
.chip.on { border-color: var(--ac); color: var(--tx); background: rgba(95, 180, 255, .14); }

/* Layout */
.layout {
  max-width: 1400px; margin: 0 auto; padding: 16px; display: grid; gap: 14px;
  grid-template-columns: minmax(0, 1fr) 400px;
  grid-template-areas: "hero rank" "storm rank" "plan rank" "smn rank" "map rank";
  align-items: start;
}
.smn { grid-area: smn; } .hero { grid-area: hero; } .mapcard { grid-area: map; } .rank { grid-area: rank; position: sticky; top: 80px; max-height: calc(100vh - 96px); overflow: auto; }
.guide { max-width: 1400px; margin: 0 auto; padding: 0 16px 16px; display: grid; gap: 14px; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); }
.card { background: linear-gradient(180deg, #141d34, var(--card)); border: 1px solid var(--line); border-radius: var(--r); padding: 16px; min-width: 0; }
@media (max-width: 1000px) {
  .layout { grid-template-columns: minmax(0, 1fr); grid-template-areas: "hero" "storm" "plan" "smn" "map" "rank"; }
  .rank { position: static; max-height: none; }
}

/* SMN */
.smn { display: flex; flex-direction: column; gap: 10px; }
.smn.none { border-color: rgba(61, 220, 151, .35); }
.smnhead { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.smnhead h2 { margin-right: auto; }
.al { border-radius: 10px; padding: 10px 12px; border-left: 4px solid var(--c); background: color-mix(in srgb, var(--c) 12%, transparent); }
.al b { display: block; } .al small { color: var(--mut); display: block; margin-top: 2px; }
.al .tag { display: inline-block; font-size: .7rem; font-weight: 800; text-transform: uppercase; letter-spacing: .04em; padding: 1px 7px; border-radius: 5px; background: var(--c); color: #111; margin-right: 6px; }
.al.mine { box-shadow: 0 0 0 1px var(--c); }
.al details { margin-top: 6px; font-size: .85rem; color: #c9d3e8; } .al summary { cursor: pointer; color: var(--ac); }

/* Hero */
.hero { display: grid; gap: 14px; grid-template-columns: auto 1fr; align-items: center; }
.gauge { --v: 0; --c: var(--mut); width: 112px; aspect-ratio: 1; border-radius: 50%; display: grid; place-items: center;
  background: conic-gradient(var(--c) calc(var(--v) * 1%), #1e2945 0); position: relative; }
.gauge::before { content: ""; position: absolute; inset: 10px; border-radius: 50%; background: var(--card); }
.gauge span { position: relative; text-align: center; font-size: 2rem; font-weight: 800; line-height: 1; }
.gauge small { display: block; font-size: .65rem; font-weight: 600; color: var(--mut); text-transform: uppercase; letter-spacing: .06em; margin-top: 4px; }
.hero .kicker { color: var(--mut); font-size: .8rem; text-transform: uppercase; letter-spacing: .06em; font-weight: 600; }
.hero h2 { font-size: 1.5rem; font-weight: 800; margin: 2px 0 4px; }
.hero .verdict { margin: 0 0 4px; }
.hero .sub { color: var(--mut); font-size: .85rem; }
.metrics { grid-column: 1 / -1; display: grid; gap: 8px; grid-template-columns: repeat(auto-fit, minmax(118px, 1fr)); }
.m { background: var(--bg2); border: 1px solid var(--line); border-radius: 10px; padding: 8px 10px; }
.m span { display: block; font-size: .7rem; color: var(--mut); text-transform: uppercase; letter-spacing: .04em; }
.m b { font-size: 1.1rem; } .m em { font-style: normal; font-size: .72rem; margin-left: 4px; }
.m.good { border-color: rgba(255, 59, 92, .55); } .m.good em { color: #ff7a90; }
.m.mid { border-color: rgba(255, 140, 26, .5); } .m.mid em { color: var(--orange); }
.m.low em { color: var(--mut); }
.hero .go, .row .go, .pbtns .go, .hform .go { display: inline-flex; align-items: center; gap: 6px; background: var(--ac); color: #04121f; padding: 8px 14px; border-radius: 9px; font-weight: 700; text-decoration: none; font-size: .85rem; margin-top: 6px; }

/* Map */
.mapcard { padding: 12px; display: flex; flex-direction: column; gap: 10px; }
.maptop { display: flex; flex-wrap: wrap; gap: 8px; justify-content: space-between; align-items: center; }
.pane { position: relative; }
#map, .pane iframe { width: 100%; height: 560px; border: 0; border-radius: 10px; background: #0b1020; display: block; }
@media (max-width: 700px) { #map, .pane iframe { height: 62vh; min-height: 380px; } }
.radarstamp, .legend { position: absolute; z-index: 500; background: rgba(10, 15, 28, .82); border: 1px solid var(--line); border-radius: 8px; padding: 5px 9px; font-size: .75rem; color: var(--mut); pointer-events: none; }
.radarstamp { top: 10px; right: 10px; }
.radarstamp:empty { display: none; }
.legend { bottom: 10px; left: 10px; display: flex; align-items: center; gap: 8px; }
.legend .grad { display: block; width: 110px; height: 8px; border-radius: 4px; background: linear-gradient(90deg, rgb(255,230,80), rgb(255,170,40), rgb(255,90,40), rgb(235,30,90), rgb(190,40,220)); }
.legend .lbls { display: none; }
.timebar { display: flex; align-items: center; gap: 10px; }
.timebar input { flex: 1; accent-color: var(--ac); }
.timebar output { min-width: 46px; font-weight: 700; font-variant-numeric: tabular-nums; }
.icon { width: 34px; height: 34px; border-radius: 50%; border: 1px solid var(--line2); background: var(--bg2); }
.timebar.off input, .timebar.off output { opacity: .45; }
.note { color: var(--mut); font-size: .8rem; margin: 6px 0 0; }
.leaflet-container { font: inherit; }
.leaflet-tooltip { background: #0e1526; color: var(--tx); border: 1px solid var(--line2); border-radius: 8px; box-shadow: none; }
.leaflet-tooltip-top::before { border-top-color: var(--line2); }
.leaflet-control-attribution { background: rgba(10, 15, 28, .7) !important; color: var(--mut) !important; }
.leaflet-control-attribution a { color: var(--mut) !important; }
.leaflet-bar a { background: var(--card); color: var(--tx); border-color: var(--line) !important; }
.townlbl { background: none; border: 0; box-shadow: none; color: #dfe6f5; font-size: .7rem; font-weight: 600; text-shadow: 0 1px 3px #000, 0 0 2px #000; padding: 0; }
.townlbl::before { display: none; }

/* Ranking */
.rankhead { display: flex; justify-content: space-between; align-items: center; gap: 8px; flex-wrap: wrap; }
#list { list-style: none; margin: 0; padding: 0; }
.row { display: grid; grid-template-columns: 44px 1fr auto; gap: 4px 10px; align-items: center; padding: 10px 0; border-top: 1px solid var(--line); cursor: pointer; }
.row:first-child { border-top: 0; }
.row:hover .nm { color: var(--ac); }
.sc { width: 44px; height: 44px; border-radius: 10px; display: grid; place-items: center; font-weight: 800; color: #111; font-size: 1rem; }
.nm { font-weight: 700; }
.row small { color: var(--mut); display: block; font-size: .76rem; }
.row .go { margin: 0; padding: 6px 10px; font-size: .78rem; }
.spark { grid-column: 2 / 4; height: 22px; width: 100%; }

/* Guide */
.guide ul, .guide ol { margin: 8px 0 0; padding-left: 18px; color: #c9d3e8; font-size: .9rem; }
.guide li { margin-bottom: 6px; }
.links { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; align-content: start; }
.links h2 { grid-column: 1 / -1; }
.links a { background: var(--bg2); border: 1px solid var(--line); border-radius: 9px; padding: 11px 8px; text-align: center; color: var(--tx); text-decoration: none; font-weight: 600; font-size: .85rem; }
.links a:hover { border-color: var(--ac); }
footer { max-width: 1400px; margin: 0 auto; padding: 4px 16px 40px; color: var(--mut); font-size: .78rem; }
footer p { margin: 4px 0; }
@media (max-width: 560px) {
  .top { padding: 10px 12px; } .brand p { display: none; }
  .hero { grid-template-columns: 1fr; text-align: center; justify-items: center; }
  .metrics { text-align: left; width: 100%; grid-template-columns: 1fr 1fr; }
}
[hidden] { display: none !important; }
.more { width: 100%; margin-top: 8px; padding: 9px; }
.seg .tablink { padding: 7px 12px; border-radius: 8px; color: var(--mut); font-weight: 600; font-size: .85rem; text-decoration: none; }
.seg .tablink:hover { color: var(--tx); }
.smn.hot { border-color: rgba(255, 59, 92, .6); box-shadow: 0 0 0 1px rgba(255, 59, 92, .25), 0 0 30px rgba(255, 59, 92, .12); }
.al summary { cursor: pointer; list-style: none; color: var(--tx); }
.al summary::-webkit-details-marker { display: none; }
.al summary::after { content: "▾"; float: right; color: var(--mut); }
.al[open] summary::after { content: "▴"; }
.al .cnt { color: var(--mut); font-size: .8rem; margin-left: 4px; }
.al p { font-size: .85rem; color: #c9d3e8; margin: 6px 0 0; }
.how { grid-column: 1 / -1; font-size: .85rem; color: #c9d3e8; }
.how summary { cursor: pointer; color: var(--ac); font-weight: 600; }
.how ul { margin: 6px 0 0; padding-left: 18px; }

/* Confianza del pronóstico por día */
.conf { display: inline-block; margin-left: 6px; padding: 1px 7px; border-radius: 999px; font-size: .7rem; letter-spacing: .03em; border: 1px solid currentColor; }
.conf-alta { color: #3ddc97; } .conf-media { color: #ffd43b; } .conf-baja { color: #ff8c1a; }
.conftxt { font-size: .8rem; margin-top: 4px; }
.cdot { display: inline-block; width: 6px; height: 6px; border-radius: 50%; margin-left: 6px; vertical-align: middle; background: currentColor; }

/* Leyenda de colores y guía */
.mlegend { grid-column: 1 / -1; margin: 0; font-size: .8rem; color: var(--mut); }
.mlegend a { color: var(--ac); }
.sw { font-weight: 700; }
.sw-good { color: #ff7a90; } .sw-mid { color: var(--orange); } .sw-low { color: var(--mut); }
.gtable { width: 100%; border-collapse: collapse; font-size: .82rem; margin: 10px 0; }
.gtable th, .gtable td { text-align: left; padding: 6px 6px; border-bottom: 1px solid var(--line); vertical-align: top; }
.gtable th { color: var(--mut); font-weight: 600; font-size: .75rem; text-transform: uppercase; letter-spacing: .03em; }
.gtable td:last-child { white-space: nowrap; }
@media (min-width: 900px) { .guide > .wide { grid-column: span 2; } }
.guide h3 { margin: 14px 0 4px; font-size: .95rem; }

/* Plan de caza */
.plan { grid-area: plan; }
.plan:empty { display: none; }
.planhead { display: flex; align-items: center; justify-content: space-between; gap: 10px; flex-wrap: wrap; }
.planhead h2 { margin: 0; }
.pbadge { padding: 4px 10px; border-radius: 999px; font-weight: 700; font-size: .8rem; border: 1px solid currentColor; }
.pbadge.go { color: var(--red); } .pbadge.maybe { color: var(--orange); } .pbadge.no { color: var(--mut); }
.plantitle { margin: 8px 0 4px; font-size: 1.05rem; }
.pwarn { background: rgba(255, 140, 26, .08); border: 1px solid rgba(255, 140, 26, .35); border-radius: 10px; padding: 4px 12px; margin: 10px 0; font-size: .88rem; }
.pwarn p { margin: 6px 0; }
.psteps { margin: 10px 0; padding-left: 20px; color: #c9d3e8; font-size: .92rem; }
.psteps li { margin-bottom: 8px; }
.psteps a, .plan .sub a { color: var(--ac); }
.pbtns { margin: 6px 0 12px; }
.pcols { display: grid; gap: 10px; grid-template-columns: repeat(auto-fit, minmax(190px, 1fr)); }
.pcols > div { background: var(--bg2); border: 1px solid var(--line); border-radius: 10px; padding: 10px 12px; }
.pcols h3 { margin: 0 0 4px; font-size: .8rem; text-transform: uppercase; letter-spacing: .04em; color: var(--mut); }
.pcols ul { margin: 0; padding-left: 16px; font-size: .85rem; color: #c9d3e8; }
.pcols li { margin-bottom: 4px; }

/* Dibujo de la tormenta y formas de radar */
.diagram { width: 100%; max-width: 380px; height: auto; display: block; margin: 6px auto; }
.diagram text { font: 600 15px system-ui, sans-serif; fill: #c9d3e8; }
.diagram .d-small { font-size: 13px; font-weight: 500; fill: var(--mut); }
.d-rain { fill: rgba(95, 180, 255, .18); stroke: rgba(95, 180, 255, .5); stroke-width: 1.5; }
.d-hail { fill: rgba(190, 40, 220, .45); stroke: #be28dc; stroke-width: 1.5; }
.diagram .d-hail-t { fill: #f0c8ff; }
.d-rot { fill: rgba(255, 59, 92, .25); stroke: var(--red); stroke-width: 2; }
.d-spin { fill: none; stroke: var(--red); stroke-width: 2.5; }
.diagram .d-rot-t { fill: #ff7a90; }
.d-move { stroke: #c9d3e8; stroke-width: 3; }
.diagram .d-move-t { fill: #eef2fa; }
.d-nogo-bg { fill: rgba(255, 59, 92, .06); } .d-nogo-line { stroke: rgba(255, 59, 92, .35); stroke-width: 3; }
.d-nogo { stroke: rgba(255, 59, 92, .6); stroke-dasharray: 6 5; stroke-width: 1.5; }
.diagram .d-nogo-t { fill: #ff7a90; font-size: 13px; }
.d-you { fill: var(--ok); stroke: #0a0f1c; stroke-width: 2; }
.diagram .d-you-t { fill: var(--ok); font-weight: 800; }
.d-escape { stroke: var(--ok); stroke-width: 2.5; stroke-dasharray: 7 5; }
.d-dist { stroke: var(--mut); stroke-width: 1; stroke-dasharray: 3 4; }
.d-north line { stroke: var(--mut); stroke-width: 2; } .d-north text { fill: var(--mut); font-size: 13px; }
.dwrap { display: grid; gap: 12px; grid-template-columns: minmax(0, 380px) 1fr; align-items: center; margin: 8px 0 12px; }
@media (max-width: 700px) { .dwrap { grid-template-columns: 1fr; } }
.dwrap ul { margin: 0; padding-left: 18px; font-size: .88rem; color: #c9d3e8; }
.dwrap li { margin-bottom: 6px; }
.rshapes { display: grid; gap: 10px; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); margin: 10px 0; }
.rshape { margin: 0; background: var(--bg2); border: 1px solid var(--line); border-radius: 10px; padding: 8px 10px; font-size: .84rem; color: #c9d3e8; }
.rshape.good { border-color: rgba(61, 220, 151, .45); }
.rshape svg { width: 100%; height: 80px; display: block; }
.rshape .r1 { fill: rgba(95, 180, 255, .45); } .rshape .r2 { fill: #ffd43b; } .rshape .r3 { fill: #ff3b5c; }
.rshape .thick { fill: none; stroke: rgba(95, 180, 255, .55); stroke-width: 16; stroke-linecap: round; }
.rshape .mid { fill: none; stroke: #ffd43b; stroke-width: 6; stroke-linecap: round; }
.rshape .hookring { fill: none; stroke: var(--ok); stroke-width: 2; stroke-dasharray: 3 3; }
.rscale { display: flex; height: 12px; border-radius: 6px; overflow: hidden; margin: 6px 0 2px; }
.rscale i { flex: 1; }
.rscale-l { display: flex; justify-content: space-between; font-size: .75rem; color: var(--mut); }
.daytable { width: 100%; border-collapse: collapse; font-size: .86rem; margin: 6px 0 12px; }
.daytable td { padding: 6px; border-bottom: 1px solid var(--line); vertical-align: top; color: #c9d3e8; }
.daytable td:first-child { white-space: nowrap; font-weight: 700; color: var(--tx); width: 1%; }
.plan h3.ptitle { margin: 14px 0 4px; font-size: .95rem; }

.windysw { display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: 8px; }
.windysw a.chip { text-decoration: none; }
.windyhint { margin: 0 0 8px; font-size: 13px; opacity: .85; }

.safeinfo { position: absolute; left: 10px; bottom: 44px; z-index: 500; max-width: min(420px, calc(100% - 24px)); background: rgba(10,15,28,.88); border: 1px solid var(--line); border-left: 4px solid #5fb4ff; border-radius: 10px; padding: 8px 10px; font-size: .8rem; line-height: 1.35; pointer-events: none; }
.safeinfo:empty { display: none; }
.safeinfo.in, .safeinfo.close { border-left-color: #ff3b5c; }
.safeinfo.safe { border-left-color: #3ddc97; }

.rainlegend { position: absolute; left: 56px; top: 10px; z-index: 500; max-width: min(360px, calc(100% - 70px)); background: rgba(10,15,28,.88); border: 1px solid var(--line); border-radius: 8px; padding: 6px 9px; font-size: .74rem; color: var(--mut); pointer-events: none; display: flex; flex-direction: column; gap: 4px; }
.rainlegend[hidden] { display: none; }
.rainlegend .rl { display: flex; align-items: center; gap: 4px; }
.rainlegend .rl i { display: inline-block; width: 16px; height: 8px; border-radius: 2px; }
.zonelabel span { display: inline-block; transform: translate(-50%, -120%); white-space: nowrap; font-weight: 700; font-size: .78rem; color: #fff; background: rgba(10,15,28,.85); border: 1.5px solid var(--c); border-radius: 999px; padding: 2px 8px; }
.zonelabel.below span { transform: translate(-50%, 20%); }

.howlink { color: var(--tx); text-decoration: none; font-weight: 600; font-size: .85rem; border: 1px solid var(--line); border-radius: 999px; padding: 6px 12px; white-space: nowrap; }
.howlink:hover { border-color: #5fb4ff; }
.howto { border-color: #5fb4ff55; }
.howto h3 { margin-top: 14px; }
#como-usar { scroll-margin-top: 90px; }
.inzone { font-size: .8rem; }

.tracklabel span { display: inline-block; transform: translate(-50%, -50%); font-size: .7rem; font-weight: 700; color: #fff; background: rgba(10,15,28,.8); border: 1px solid rgba(255,255,255,.4); border-radius: 6px; padding: 0 4px; white-space: nowrap; }
.vpmark span { display: inline-block; transform: translate(-50%, -50%); font-size: 1.4rem; filter: drop-shadow(0 0 3px #000); }

.vpmark span b { font-size: .7rem; color: #fff; background: #0a0f1c; border-radius: 999px; padding: 0 4px; margin-left: -4px; vertical-align: top; }
.opts { display: grid; gap: 10px; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); margin-bottom: 12px; }
.opt { border: 1px solid var(--line); border-left: 4px solid var(--c); border-radius: 10px; padding: 10px 12px; background: var(--bg2); }
.opt p { margin: 4px 0; font-size: .85rem; }
.opt .ohead { display: flex; justify-content: space-between; align-items: center; gap: 8px; }
.opt .sc { color: #0a0f1c; font-weight: 800; border-radius: 8px; padding: 2px 8px; }
.opt .owarn { color: #ffb3b3; } .opt .ook { color: #9be8c4; }

#list .optrow { list-style: none; border: 1px solid var(--line); border-left: 4px solid var(--c); border-radius: 10px; padding: 10px 12px; margin-bottom: 10px; background: var(--bg2); }
#list .optrow.dim { opacity: .6; }
#list .optrow p { margin: 4px 0; font-size: .85rem; }
#list .optrow .ohead { display: flex; align-items: center; gap: 8px; }
#list .optrow .sc { color: #0a0f1c; font-weight: 800; border-radius: 8px; padding: 2px 8px; }
.owarn { color: #ffb3b3; } .ook { color: #9be8c4; }
#list .townsbox { list-style: none; margin-top: 6px; }
#list .townsbox summary { cursor: pointer; color: var(--mut); font-size: .85rem; padding: 6px 0; }
#list ol.towns { padding: 0; margin: 0; }

.pinbox { border: 1px solid var(--line); border-left: 4px solid #3ddc97; border-radius: 10px; padding: 8px 12px; margin-bottom: 10px; background: var(--bg2); font-size: .88rem; }
.pinbox.warn { border-left-color: #ff8c1a; }
.pinbox p { margin: 4px 0; }
.pin-bad { color: #ffb3b3; } .pin-go { color: #ff8fa3; font-weight: 600; } .pin-info { color: var(--mut); }
.pintag { font-size: .8rem; color: #9be8c4; align-self: center; }
.otmark span { display: inline-block; transform: translate(-50%, -110%); font-size: 1rem; filter: drop-shadow(0 0 2px #000); }
.nclabel span { display: inline-block; transform: translate(4px, -50%); font-size: .68rem; font-weight: 700; color: var(--c); text-shadow: 0 0 3px #000, 0 0 3px #000; }

/* Historial */
.history { max-width: 1400px; margin: 0 auto; padding: 0 16px 16px; }
.history h2 { margin: 0 0 6px; }
.hsum { display: grid; gap: 8px; grid-template-columns: repeat(auto-fit, minmax(140px, 1fr)); margin: 12px 0; }
.hsum > div { background: var(--bg2); border: 1px solid var(--line); border-radius: 10px; padding: 8px 12px; }
.hsum b { display: block; font-size: 1.3rem; }
.hsum span { font-size: .78rem; color: var(--mut); }
.hform { margin: 10px 0 14px; border: 1px solid var(--line); border-radius: 10px; padding: 10px 12px; background: var(--bg2); }
.hform summary { cursor: pointer; font-weight: 700; }
.hform form { display: grid; gap: 10px; margin-top: 10px; font-size: .9rem; }
.hform label { display: grid; gap: 4px; color: #c9d3e8; }
.hform fieldset { border: 1px solid var(--line); border-radius: 8px; padding: 6px 10px 8px; display: flex; flex-wrap: wrap; gap: 6px 14px; margin: 0; }
.hform fieldset label { display: inline-flex; align-items: center; gap: 6px; }
.hform legend { color: var(--mut); font-size: .8rem; padding: 0 4px; }
.hform input[type="date"], .hform input[name="donde"], .hform textarea { background: var(--card); color: var(--tx); border: 1px solid var(--line2); border-radius: 8px; padding: 8px; font: inherit; max-width: 100%; }
.hform .go { justify-self: start; border: 0; cursor: pointer; }
.hdays { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; }
.hday { border: 1px solid var(--line); border-radius: 10px; padding: 10px 12px; }
.hdate { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; margin-bottom: 6px; }
.hver { font-size: .8rem; padding: 2px 8px; border-radius: 999px; border: 1px solid var(--line2); color: var(--mut); }
.hver.ok { color: var(--ok); border-color: rgba(61, 220, 151, .5); }
.hver.no { color: var(--mut); }
.hver.warn { color: var(--orange); border-color: rgba(255, 140, 26, .5); }
.hgrid { display: grid; gap: 8px 14px; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); font-size: .86rem; color: #c9d3e8; }
.hgrid span { display: block; font-size: .72rem; text-transform: uppercase; letter-spacing: .04em; color: var(--mut); }
.hgrid small { display: block; color: var(--mut); }
.hgrid a, .history .linkbtn { color: var(--ac); }
.linkbtn { background: none; border: 0; padding: 0; font: inherit; cursor: pointer; text-decoration: underline; }

/* Desde dónde salís */
.originbar { flex-wrap: wrap; }
.originbar select { background: transparent; color: var(--mut); border: 0; border-radius: 8px; padding: 5px 6px; font: inherit; font-size: .78rem; font-weight: 600; max-width: 150px; cursor: pointer; }
.originbar select.on { background: var(--ac); color: #04121f; }
.originbar select option { color: #000; }
.originask { max-width: 1400px; margin: 12px auto 0; box-sizing: border-box; width: calc(100% - 32px); display: flex; flex-wrap: wrap; align-items: center; gap: 8px 12px; background: rgba(95, 180, 255, .1); border: 1px solid rgba(95, 180, 255, .4); border-radius: 12px; padding: 10px 14px; font-size: .9rem; }
.originask[hidden] { display: none; }
.originask .go { display: inline-flex; align-items: center; gap: 6px; background: var(--ac); color: #04121f; padding: 7px 12px; border-radius: 9px; font-weight: 700; border: 0; cursor: pointer; font-size: .85rem; }

/* Red de tormentas */
.red { max-width: 1400px; margin: 0 auto; padding: 0 16px 16px; }
.redhead { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 8px; }
.redhead h2 { margin: 0; }
.authbtn { display: inline-flex; align-items: center; gap: 6px; background: none; cursor: pointer; font: inherit; font-weight: 600; font-size: .85rem; }
.authbtn img { border-radius: 50%; }
.redform { display: grid; gap: 10px; margin-top: 10px; font-size: .9rem; }
.redform label { display: grid; gap: 4px; color: #c9d3e8; }
.redform fieldset { border: 1px solid var(--line); border-radius: 8px; padding: 6px 10px 8px; display: flex; flex-wrap: wrap; gap: 6px 14px; margin: 0; }
.redform fieldset label { display: inline-flex; align-items: center; gap: 6px; }
.redform legend { color: var(--mut); font-size: .8rem; padding: 0 4px; }
.redform input[type="datetime-local"], .redform input[type="url"], .redform input[type="file"], .redform textarea { background: var(--card); color: var(--tx); border: 1px solid var(--line2); border-radius: 8px; padding: 8px; font: inherit; max-width: 100%; box-sizing: border-box; }
.redform .safe { margin: 0; background: rgba(255, 140, 26, .08); border: 1px solid rgba(255, 140, 26, .35); border-radius: 10px; padding: 8px 12px; }
.locrow { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; }
.red .go, #redlogin .go { display: inline-flex; align-items: center; gap: 6px; background: var(--ac); color: #04121f; padding: 8px 14px; border-radius: 9px; font-weight: 700; border: 0; cursor: pointer; font-size: .85rem; justify-self: start; }
.red .go:disabled { opacity: .6; cursor: wait; }
.publist { list-style: none; margin: 10px 0 0; padding: 0; display: grid; gap: 10px; grid-template-columns: repeat(auto-fill, minmax(min(100%, 320px), 1fr)); }
.pub { border: 1px solid var(--line); border-radius: 12px; padding: 10px 12px; background: var(--bg2); display: grid; gap: 6px; align-content: start; min-width: 0; }
.pub.fuerte { border-color: rgba(255, 59, 92, .6); }
.pub.oculto { opacity: .6; }
.pub p { margin: 0; }
.phead { display: flex; align-items: center; gap: 8px; }
.phead img, .phead .noav { width: 32px; height: 32px; border-radius: 50%; display: grid; place-items: center; background: var(--card); }
.phead small { display: block; color: var(--mut); font-size: .76rem; }
.pplace { font-size: .85rem; color: #c9d3e8; }
.pchips { display: flex; flex-wrap: wrap; gap: 4px; }
.pchips span { font-size: .75rem; border: 1px solid var(--line2); border-radius: 999px; padding: 2px 8px; color: #c9d3e8; }
.pchips span.hot { border-color: var(--red); color: #ff7a90; font-weight: 700; }
.pdesc { font-size: .88rem; color: #c9d3e8; overflow-wrap: anywhere; }
.pvideo { position: relative; aspect-ratio: 16 / 9; border-radius: 10px; overflow: hidden; background: #000; }
.pvideo iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }
.pvlink { color: var(--ac); font-weight: 600; font-size: .9rem; }
.pfoto { width: 100%; max-height: 320px; object-fit: cover; border-radius: 10px; display: block; }
.pfc { font-size: .82rem; color: var(--mut); }
.pfc.ok { color: var(--ok); }
.pfc.warn { color: var(--orange); }
.pact { display: flex; flex-wrap: wrap; gap: 6px; }
.pubpin { font-size: 18px; line-height: 28px; text-align: center; background: rgba(10, 15, 28, .85); border: 2px solid #5fb4ff; border-radius: 50%; }
.pubpin.fuerte { border-color: #ff3b5c; box-shadow: 0 0 0 3px rgba(255, 59, 92, .35); }
.pubpin.viejo { opacity: .45; border-color: var(--mut); box-shadow: none; }
.pubpin.nuevo { animation: pubpulse 1.6s ease-out infinite; }
@keyframes pubpulse { 0% { box-shadow: 0 0 0 0 rgba(95, 180, 255, .7); } 100% { box-shadow: 0 0 0 16px rgba(95, 180, 255, 0); } }
.pubpin.fuerte.nuevo { animation-name: pubpulsered; }
@keyframes pubpulsered { 0% { box-shadow: 0 0 0 0 rgba(255, 59, 92, .8); } 100% { box-shadow: 0 0 0 18px rgba(255, 59, 92, 0); } }
@media (prefers-reduced-motion: reduce) { .pubpin.nuevo { animation: none; box-shadow: 0 0 0 4px rgba(95, 180, 255, .5); } }
.history .go { display: inline-flex; align-items: center; gap: 6px; background: var(--ac); color: #04121f; padding: 8px 14px; border-radius: 9px; font-weight: 700; text-decoration: none; font-size: .85rem; }
.hpubs { margin: 8px 0 0; padding-left: 18px; font-size: .84rem; color: #c9d3e8; display: grid; gap: 4px; }
.hpubs li.hot { color: #ff7a90; }
.hpubs a { color: var(--ac); }
.agree { font-weight: 700; }
.agree.alto { color: var(--ok); } .agree.medio { color: var(--warn); } .agree.bajo { color: var(--orange); }
.otmark.salto span { font-size: 1.15rem; filter: drop-shadow(0 0 3px #ffd43b) drop-shadow(0 0 2px #000); }

/* Avisos SMN: dónde, cuándo y si te afecta */
.al summary { display: grid; gap: 3px; }
.al summary::after { position: absolute; right: 12px; top: 12px; }
.al { position: relative; padding-right: 30px; }
.alrow { display: flex; flex-wrap: wrap; align-items: center; gap: 4px 8px; }
.alrow b { display: inline; }
.al .dist { font-size: .78rem; color: var(--mut); }
.al .you { font-size: .78rem; font-weight: 700; color: var(--c); }
.al.far { opacity: .7; }
.al .mean { color: var(--tx); }
.al .instr { white-space: pre-line; }
.al .almap { margin-top: 8px; }
.al p b { display: inline; }

/* ⛈️ Tormenta o granizo hacia tu ubicación */
.storm { grid-area: storm; display: grid; gap: 6px; }
.storm h2 { margin: 0; font-size: 1.05rem; }
.storm.ok { padding: 10px 16px; border-color: rgba(61, 220, 151, .35); }
.storm.ok h2 { font-size: .95rem; font-weight: 600; }
.storm.alta { border-color: rgba(255, 59, 92, .7); box-shadow: 0 0 30px rgba(255, 59, 92, .15); }
.storm.media { border-color: rgba(255, 140, 26, .7); }
.storm.baja { border-color: rgba(255, 212, 59, .6); }
.storm p { margin: 0; }
.storm .why { color: var(--mut); font-size: .88rem; }

/* 🎯 Punto para ver la mejor tormenta */
.intermark span { font-size: 22px; filter: drop-shadow(0 0 4px rgba(0, 0, 0, .8)); }
.leaflet-tooltip.intertip { white-space: normal; width: min(260px, 70vw); }

.nacmark span { font-size: 18px; filter: drop-shadow(0 0 3px rgba(0,0,0,.7)); }

.smnyo { margin: 0; padding: 8px 10px; border-radius: 10px; background: rgba(61,220,151,.08); border: 1px solid rgba(61,220,151,.35); }
.smnyo.dentro { background: rgba(255,140,26,.10); border-color: rgba(255,140,26,.6); }
