/* Weather, wherever you are. Scoped to the mount root. */

.wxsec {
  --w-ink: var(--ink, #1e2a2f);
  --w-muted: var(--muted, #5f7178);
  --w-surface: var(--surface, #fffdf9);
  --w-line: var(--line, #e6e0d5);
  --w-accent: var(--accent, #2f7a74);
  --w-soft: var(--accent-soft, #dcebe7);
  color: var(--w-ink);
  font-family: var(--font, "Figtree", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif);
}
.wxsec-sheet { display: grid; gap: 12px; }
.wxsec-bar { display: flex; gap: 16px; align-items: flex-start; justify-content: space-between; }
.wxsec-kicker { margin: 0 0 4px; font-size: 12px; font-weight: 750; letter-spacing: .08em; text-transform: uppercase; color: var(--w-muted); }
.wxsec h2 { margin: 0; font-family: var(--display, var(--font, inherit)); font-size: clamp(28px, 4vw, 40px); font-weight: 500; letter-spacing: -.03em; }
.wxsec h3 { margin: 0; font-family: var(--display, var(--font, inherit)); font-size: 22px; font-weight: 500; }
.wxsec-actions { display: flex; flex-wrap: wrap; gap: 8px; justify-content: flex-end; align-items: center; }
.wxsec button, .wxsec-search input { font: inherit; color: inherit; }
.wxsec-actions > button, .wxsec-hits button {
  border: 1px solid var(--w-line); background: var(--w-surface); border-radius: 999px; padding: 8px 14px; cursor: pointer;
}
.wxsec-actions > button:hover, .wxsec-hits button:hover { border-color: var(--w-accent); }
.wxsec-actions > button:disabled { opacity: .55; cursor: default; }
.wxsec-units { display: inline-flex; padding: 3px; border-radius: 999px; background: var(--w-surface); border: 1px solid var(--w-line); }
.wxsec-units button { border: 0; background: transparent; border-radius: 999px; padding: 6px 12px; cursor: pointer; color: var(--w-muted); font-weight: 700; }
.wxsec-units button[aria-pressed="true"] { background: var(--w-accent); color: #fff; }
.wxsec-search input { width: 100%; border: 1px solid var(--w-line); border-radius: 14px; padding: 12px 14px; background: var(--w-surface); }
.wxsec-search input:focus { outline: none; border-color: var(--w-accent); box-shadow: 0 0 0 4px var(--w-soft); }
.wxsec-hits { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: 8px; }
.wxsec-error { margin: 0; color: #9b1c1c; background: #fde8e8; border-radius: 12px; padding: 10px 12px; }
.wxsec-hero {
  display: grid; grid-template-columns: minmax(0, 1.1fr) minmax(150px, 42%); gap: 8px; align-items: center;
  border-radius: 28px; padding: 22px 18px 16px 26px; overflow: hidden; min-height: 210px;
}
.wxsec-hero[data-scene="clear"] { background: linear-gradient(145deg, #8fd0ff 0%, #d9eeff 48%, #f8e7c4 100%); color: #14324f; }
.wxsec-hero[data-scene="night"], .wxsec-hero[data-scene="dusk"] { background: linear-gradient(160deg, #2c4a7e 0%, #121c33 78%); color: #f4f7fb; }
.wxsec-hero[data-scene="cloud"] { background: linear-gradient(160deg, #c5d5e2, #eef3f7); color: #243244; }
.wxsec-hero[data-scene="rain"] { background: linear-gradient(165deg, #5f86a8, #d5e2ec); color: #102433; }
.wxsec-hero[data-scene="storm"] { background: linear-gradient(165deg, #3e516c, #1b2636); color: #f4f7fb; }
.wxsec-hero[data-scene="snow"] { background: linear-gradient(165deg, #e7f1f8, #f8fbfe); color: #24384a; }
.wxsec-hero[data-scene="fog"] { background: linear-gradient(165deg, #d5dde4, #eef2f5); color: #2c3844; }
.wxsec-hero .wxsec-kicker { color: inherit; opacity: .72; }
.wxsec-temp { margin: 0; font-family: var(--display, var(--font, inherit)); font-weight: 500; font-size: clamp(72px, 8vw, 104px); line-height: .82; letter-spacing: -.045em; }
.wxsec-cond { margin: 8px 0 0; font-family: var(--display, var(--font, inherit)); font-size: 28px; font-weight: 500; }
.wxsec-sub, .wxsec-wait { margin: 8px 0 0; font-size: 16px; opacity: .86; }
.wxsec-art svg { width: 100%; height: auto; max-height: 200px; display: block; }
.wxsec-metrics { display: grid; grid-template-columns: repeat(auto-fill, minmax(140px, 1fr)); gap: 10px; }
.wxsec-metric { background: var(--w-surface); border: 1px solid var(--w-line); border-radius: 18px; padding: 12px 14px 11px; }
.wxsec-metric span { display: block; font-size: 11.5px; font-weight: 750; letter-spacing: .06em; text-transform: uppercase; color: var(--w-muted); }
.wxsec-metric b { display: block; margin-top: 4px; font-size: 20px; letter-spacing: -.02em; font-weight: 700; line-height: 1.2; }
.wxsec-metric small { display: block; margin-top: 3px; color: var(--w-muted); font-size: 13px; line-height: 1.3; }
.wxsec-brief { margin: 0; font-size: 17px; line-height: 1.55; color: var(--w-ink); }
.wxsec-split { display: grid; grid-template-columns: minmax(210px, 270px) minmax(0, 1fr); gap: 12px; align-items: start; }
.wxsec-panel { background: var(--w-surface); border: 1px solid var(--w-line); border-radius: 24px; padding: 16px 16px 12px; min-width: 0; }
.wxsec-panel-h { display: flex; justify-content: space-between; gap: 12px; align-items: baseline; flex-wrap: wrap; margin-bottom: 4px; }
.wxsec-legend { margin: 0; font-size: 13px; color: var(--w-muted); display: flex; align-items: center; gap: 7px; }
.wxsec-legend i { width: 16px; height: 4px; border-radius: 99px; background: var(--w-accent); display: inline-block; }
.wxsec-legend i.is-rain { width: 8px; height: 12px; border-radius: 3px; background: #3d8fd4; }
.wxsec-sun { text-align: left; }
.wxsec-sun-svg { width: min(100%, 200px); height: auto; display: block; margin: 6px auto; color: var(--w-muted); }
.wxsec-sun-times { display: flex; justify-content: space-between; gap: 12px; }
.wxsec-sun-times p { margin: 0; }
.wxsec-sun-times span { display: block; font-size: 11.5px; letter-spacing: .06em; text-transform: uppercase; color: var(--w-muted); font-weight: 750; }
.wxsec-sun-times b { font-size: 18px; }
.wxsec-sun-note { margin: 10px 0 0; color: var(--w-muted); font-size: 14px; }
.wxsec-chart { width: 100%; height: auto; display: block; overflow: visible; }
.wxsec-chart .wxsec-line { fill: none; stroke: var(--w-accent); stroke-width: 4; stroke-linejoin: round; stroke-linecap: round; }
.wxsec-chart .wxsec-area { fill: color-mix(in srgb, var(--w-accent) 22%, transparent); }
.wxsec-chart .wxsec-dot { fill: var(--w-surface); stroke: var(--w-accent); stroke-width: 3; }
.wxsec-chart .wxsec-pop { fill: #3d8fd4; }
.wxsec-chart .wxsec-base { stroke: var(--w-line); stroke-width: 1; }
.wxsec-chart .wxsec-tlab { fill: var(--w-ink); font-size: 20px; font-weight: 700; font-family: inherit; }
.wxsec-chart .wxsec-hlab { fill: var(--w-muted); font-size: 18px; font-family: inherit; }
.wxsec-hours { display: flex; gap: 8px; overflow-x: auto; padding: 8px 0 4px; }
.wxsec-hour { min-width: 68px; border-radius: 16px; background: color-mix(in srgb, var(--w-ink) 4%, var(--w-surface)); border: 1px solid var(--w-line); text-align: center; padding: 8px 6px; display: flex; flex-direction: column; align-items: center; gap: 2px; }
.wxsec-hour span, .wxsec-hour small { color: var(--w-muted); font-size: 12px; }
.wxsec-hour svg { width: 32px; height: 32px; }
.wxsec-hour strong { font-size: 15px; }
.wxsec-days { display: grid; }
.wxsec-day {
  display: grid; grid-template-columns: 86px 40px minmax(0, 1.15fr) minmax(100px, .9fr) 58px;
  grid-template-areas: "when glyph copy track temps";
  gap: 8px 10px; align-items: center; width: 100%; text-align: left;
  border: 0; border-top: 1px solid var(--w-line); background: transparent; border-radius: 0; padding: 10px 2px; cursor: pointer;
}
.wxsec-days .wxsec-day:first-child { border-top: 0; }
.wxsec-day.is-on { background: var(--w-soft); border-radius: 14px; border-top-color: transparent; box-shadow: inset 0 0 0 1.5px var(--w-accent); }
.wxsec-when { grid-area: when; }
.wxsec-when b { display: block; font-size: 15px; }
.wxsec-when small, .wxsec-copy small { display: block; color: var(--w-muted); font-size: 12.5px; font-weight: 500; }
.wxsec-glyph { grid-area: glyph; }
.wxsec-glyph svg { width: 36px; height: 36px; display: block; }
.wxsec-copy { grid-area: copy; min-width: 0; }
.wxsec-copy strong { display: block; font-size: 15px; font-weight: 700; }
.wxsec-track { grid-area: track; position: relative; height: 8px; border-radius: 99px; background: color-mix(in srgb, var(--w-ink) 8%, var(--w-line)); }
.wxsec-track i { position: absolute; top: -2px; height: 12px; border-radius: 99px; background: linear-gradient(90deg, #7eb0d4, #e0b15a); }
.wxsec-day[data-heat="cold"] .wxsec-track i { background: #7eb0d4; }
.wxsec-day[data-heat="warm"] .wxsec-track i { background: linear-gradient(90deg, #e0b15a, #e07a4a); }
.wxsec-day[data-heat="hot"] .wxsec-track i { background: #d4543c; }
.wxsec-track b { position: absolute; top: 50%; width: 11px; height: 11px; margin: -5.5px 0 0 -5.5px; border-radius: 50%; background: var(--w-ink); border: 2px solid var(--w-surface); }
.wxsec-temps { grid-area: temps; text-align: right; font-variant-numeric: tabular-nums; line-height: 1.15; }
.wxsec-temps b { display: block; font-size: 17px; }
.wxsec-temps small { display: block; color: var(--w-muted); font-size: 13px; }
.wxsec-pick { margin: 10px 0 4px; font-size: 15px; color: var(--w-muted); line-height: 1.45; }
.wxsec-pick b { color: var(--w-ink); }
.wxsec-note { margin: 0; color: var(--w-muted); font-size: 13.5px; }
.wxsec-note a { color: var(--w-accent); }
@keyframes wxsec-spin { to { transform: rotate(360deg); } }
@keyframes wxsec-drift { from { transform: translateX(-8px); } to { transform: translateX(10px); } }
@keyframes wxsec-fall { 0% { transform: translateY(-8px); opacity: .15; } 100% { transform: translateY(10px); opacity: 1; } }
.wxsec-art .spin { transform-box: view-box; transform-origin: 138px 74px; animation: wxsec-spin 40s linear infinite; }
.wxsec-art .drift { animation: wxsec-drift 7s ease-in-out infinite alternate; }
.wxsec-art .fall path { animation: wxsec-fall 1.2s linear infinite; }
.wxsec-art .fall path:nth-child(2n) { animation-delay: .25s; }
.wxsec-art .fall path:nth-child(3n) { animation-delay: .5s; }
@media (prefers-reduced-motion: reduce) {
  .wxsec-art .spin, .wxsec-art .drift, .wxsec-art .fall path { animation: none; }
}
@media (max-width: 800px) {
  .wxsec-bar, .wxsec-hero { display: flex; flex-direction: column; }
  .wxsec-actions { justify-content: flex-start; }
  .wxsec-hero { padding: 18px 16px 8px; }
  .wxsec-art { order: -1; width: min(240px, 100%); }
  .wxsec-split { grid-template-columns: 1fr; }
  .wxsec-day { grid-template-columns: 74px 36px minmax(0, 1fr) auto; grid-template-areas: "when glyph copy temps" "track track track track"; }
}
:root[data-theme="dark"] .wxsec-units button[aria-pressed="true"] { color: #0f191d; }
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) .wxsec-units button[aria-pressed="true"] { color: #0f191d; }
}

/* MET Norway version (Oct 2026): alerts, what to wear, city photo, radar, city pages. */
.wxsec-alerts { display: grid; gap: 8px; }
.wxsec-alert { border-radius: 18px; padding: 12px 16px; background: #fdf0e6; border: 1px solid #f0c9a8; color: #4a2a17; }
.wxsec-alert.is-severe { background: #fbe4e1; border-color: #e7a59c; color: #5a1d16; }
.wxsec-alert summary { cursor: pointer; display: grid; gap: 2px; font-size: 16px; min-height: 44px; }
.wxsec-alert summary b { font-size: 17px; }
.wxsec-alert p { margin: 8px 0 0; font-size: 16px; white-space: pre-line; }
.wxsec-alert-src { font-size: 14px; opacity: .8; }
:root[data-theme="dark"] .wxsec-alert { background: #3a2c25; border-color: #6b4a36; color: #f6e2d4; }
:root[data-theme="dark"] .wxsec-alert.is-severe { background: #3d2220; border-color: #7a3b33; color: #f8dcd8; }
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) .wxsec-alert { background: #3a2c25; border-color: #6b4a36; color: #f6e2d4; }
  :root:not([data-theme="light"]) .wxsec-alert.is-severe { background: #3d2220; border-color: #7a3b33; color: #f8dcd8; }
}
.wxsec-extras { display: grid; gap: 12px; grid-template-columns: 1fr; container-type: inline-size; }
.wxsec-wear p { margin: 4px 0 6px; font-size: 18px; line-height: 1.5; }
.wxsec-photo { margin: 0; border-radius: 24px; overflow: hidden; position: relative; background: var(--w-soft); }
.wxsec-photo img { display: block; width: 100%; aspect-ratio: 16 / 9; object-fit: cover; }
.wxsec-photo figcaption { font-size: 13.5px; padding: 8px 14px; background: var(--w-surface); border: 1px solid var(--w-line); border-top: 0; border-radius: 0 0 24px 24px; }
.wxsec-photo figcaption a, .wxsec-radar a, .wxsec-note a { color: var(--accent-2, #25635e); }
.wxsec-radar img { display: block; width: 100%; height: auto; border-radius: 14px; margin-top: 8px; background: #e9eef0; }
.wxsec-radar button { min-height: 44px; border-radius: 999px; border: 1px solid var(--w-line); background: var(--w-soft); color: var(--ink, #1e2a2f); padding: 8px 14px; font: inherit; font-weight: 600; cursor: pointer; }
.wxsec-radar .wxsec-panel-h { display: flex; gap: 10px; align-items: center; justify-content: space-between; flex-wrap: wrap; }
.wxsec-cities h3 { margin: 4px 0 8px; }
.wxsec-cities div { display: flex; flex-wrap: wrap; gap: 8px; }
.wxsec-cities a { min-height: 44px; box-sizing: border-box; display: inline-flex; align-items: center; padding: 8px 14px; border-radius: 999px; border: 1px solid var(--w-line); background: var(--w-surface); color: var(--ink, #1e2a2f); text-decoration: none; font-size: 15.5px; }
.wxsec-cities a.is-main { background: var(--w-accent); border-color: transparent; color: #fff; font-weight: 700; }
:root[data-theme="dark"] .wxsec-cities a.is-main { color: #0f191d; }
@container (min-width: 720px) {
  .wxsec-extras { grid-template-columns: 1fr 1fr; }
  .wxsec-extras .wxsec-cities, .wxsec-extras .wxsec-wear { grid-column: 1 / -1; }
}
