/* Live NWS wind meter — map control and compact header chip. */
.wind-meter {
  font-family: var(--ui, "Segoe UI", system-ui, sans-serif);
  color: var(--ink, #1c2420);
  box-sizing: border-box;
}
.wind-meter * { box-sizing: border-box; }

.wind-meter-mount.map {
  position: absolute;
  z-index: 450;
  /* Sit in the open map, just to the right of the Layers panel — not over zoom, dock, or the panel. */
  top: 12px;
  left: calc(12px + min(280px, 100% - 24px) + 8px);
  bottom: auto;
  right: auto;
  max-width: 250px;
  pointer-events: auto;
}
/* Only hide the meter when the trip sheet covers the mobile map. */
@media (max-width: 820px) {
  .map-stage.sheet-open .wind-meter-mount.map { display: none; }
}

.wind-meter.map {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 10px;
  align-items: center;
  background: rgba(244, 239, 228, 0.95);
  backdrop-filter: blur(8px);
  border: 1px solid var(--line, rgba(28, 36, 32, 0.14));
  border-left: 4px solid var(--water, #1b4f5e);
  border-radius: 10px;
  box-shadow: var(--shadow, 0 10px 30px rgba(18, 32, 28, 0.12));
  padding: 8px 10px 8px 8px;
}
.wind-meter.map.comfort-calm { border-left-color: #2a7a6a; }
.wind-meter.map.comfort-ok { border-left-color: #3d6b3a; }
.wind-meter.map.comfort-caution { border-left-color: #c9a227; }
.wind-meter.map.comfort-avoid { border-left-color: #b85a2a; }
.wind-meter.map.comfort-unknown { border-left-color: #6b6b6b; }

.wm-dial-wrap { flex: 0 0 auto; }
.wind-meter.map .wm-dial { width: 88px; height: 88px; display: block; }
.wm-ring { fill: #f7f3ea; stroke: #1b4f5e; stroke-width: 2; }
.wm-tick { stroke: #8a928c; stroke-width: 1.2; }
.wm-tick-maj { stroke: #123843; stroke-width: 2; }
.wm-cardinal {
  font-family: var(--ui, "Segoe UI", system-ui, sans-serif);
  font-size: 9px;
  font-weight: 700;
  fill: #123843;
}
.wm-head { fill: #123843; }
.wm-tail { fill: #1b4f5e; opacity: 0.55; }
.wm-hub { fill: #c9a227; stroke: #123843; stroke-width: 1.2; }
.wm-hub-empty { fill: #d8d2c4; stroke: #8a928c; stroke-width: 1.2; }

.wind-meter.map .wm-body { flex: 1 1 110px; min-width: 0; line-height: 1.25; }
.wm-speed { font-family: var(--font, Palatino, Georgia, serif); }
.wm-speed strong { font-size: 1.7rem; font-weight: 600; letter-spacing: -0.02em; }
.wm-speed span { font-size: 12px; color: var(--ink-soft, #3d4a44); }
.wm-speed.wm-na { font-size: 13px; font-family: var(--ui, system-ui, sans-serif); }
.wm-from { font-weight: 700; font-size: 13px; margin-top: 1px; }
.wm-gust { font-size: 11px; color: var(--ink-soft, #3d4a44); }
.wm-muted { font-weight: 400; color: var(--ink-soft, #3d4a44); }
.wm-pill {
  display: inline-block;
  margin-top: 5px;
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  padding: 2px 7px;
  border-radius: 999px;
  background: #e6efe8;
  color: #2a4a32;
}
.comfort-calm .wm-pill { background: #d8efe9; color: #1a5c50; }
.comfort-ok .wm-pill { background: #e0edc9; color: #2d4a1e; }
.comfort-caution .wm-pill { background: #f3e4b3; color: #6a4e0b; }
.comfort-avoid .wm-pill { background: #f3d4c4; color: #7a2e14; }
.comfort-unknown .wm-pill { background: #e6e2d8; color: #4a4a44; }
.wm-time { font-size: 10px; color: var(--ink-soft, #3d4a44); margin-top: 5px; line-height: 1.35; }

.wm-hours {
  flex: 1 1 100%;
  display: flex;
  gap: 2px;
  margin-top: 2px;
  padding-top: 6px;
  border-top: 1px solid var(--line, rgba(28, 36, 32, 0.14));
}
.wm-h {
  flex: 1;
  text-align: center;
  font-size: 10px;
  line-height: 1.15;
  color: var(--ink-soft, #3d4a44);
}
.wm-h-arr { display: block; font-size: 11px; color: #123843; line-height: 1; }
.wm-h-arr.wm-h-na, .wm-h-arr.wm-h-na { opacity: 0.3; }
.wm-h-mph { display: block; font-weight: 700; color: var(--ink, #1c2420); }
.wm-h-t { display: block; font-size: 9px; }

/* Compact chip for content pages (header). */
.wind-meter-mount.header {
  padding: 0 20px 8px;
  display: flex;
  justify-content: flex-end;
}
.wind-meter.compact {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: rgba(243, 238, 227, 0.12);
  border: 1px solid rgba(243, 238, 227, 0.22);
  border-left: 3px solid #9ad7e0;
  border-radius: 8px;
  padding: 4px 10px 4px 6px;
  color: #f3eee3;
  max-width: 100%;
}
.site-header .wind-meter.compact { color: #f3eee3; }
.site-header .wm-ring { fill: rgba(18, 56, 67, 0.4); stroke: #f3eee3; }
.site-header .wm-tick { stroke: rgba(243, 238, 227, 0.55); }
.site-header .wm-tick-maj { stroke: #f3eee3; }
.site-header .wm-cardinal { fill: #f3eee3; }
.site-header .wm-head { fill: #f3eee3; }
.site-header .wm-tail { fill: #9ad7e0; opacity: 0.8; }
.site-header .wm-hub { fill: #c9a227; stroke: #f3eee3; }
.wind-meter.compact .wm-dial { width: 40px; height: 40px; display: block; }
.wind-meter.compact .wm-body { line-height: 1.25; min-width: 0; }
.wind-meter.compact .wm-line { font-size: 13px; }
.wind-meter.compact .wm-line strong { font-size: 14px; }
.wind-meter.compact .wm-pill {
  margin-top: 0;
  margin-left: 6px;
  vertical-align: middle;
  font-size: 9px;
  padding: 1px 6px;
}
.wind-meter.compact .wm-time { margin-top: 1px; font-size: 10px; color: rgba(243, 238, 227, 0.75); }
.site-header .comfort-calm { border-left-color: #8fd4c4; }
.site-header .comfort-ok { border-left-color: #b4d47a; }
.site-header .comfort-caution { border-left-color: #e2c45a; }
.site-header .comfort-avoid { border-left-color: #e08a5a; }

@media (max-width: 820px) {
  .wind-meter-mount.map {
    left: 8px;
    right: auto;
    bottom: auto;
    top: 86px; /* below the collapsed Layers / Conditions toggles */
    max-width: calc(50% - 16px);
  }
  .wind-meter.map { padding: 6px 8px 6px 6px; gap: 6px; }
  .wind-meter.map .wm-dial { width: 68px; height: 68px; }
  .wm-speed strong { font-size: 1.35rem; }
  .wm-hours { gap: 0; }
  .wm-h-t { display: none; }
  .wind-meter-mount.header { padding: 0 12px 8px; justify-content: flex-start; }
  .wind-meter.compact .wm-dial { width: 34px; height: 34px; }
  .wind-meter.compact .wm-line { font-size: 12px; }
}
