:root {
  --text-main: #ffffff;
  --text-muted: rgba(255, 255, 255, 0.74);
  --text-faint: rgba(255, 255, 255, 0.56);
  --glass: rgba(18, 28, 42, 0.28);
  --glass-strong: rgba(12, 20, 32, 0.46);
  --glass-border: rgba(255, 255, 255, 0.16);
  --hairline: rgba(255, 255, 255, 0.12);
  --shadow: 0 14px 34px rgba(0, 0, 0, 0.16);
  --radius-lg: 22px;
  --radius-md: 16px;
  --accent: #eaf6ff;
  --accent-blue: #62b7f2;
  --safe-top: max(18px, env(safe-area-inset-top));
  --safe-bottom: max(22px, env(safe-area-inset-bottom));
  --theme-overlay: rgba(0, 0, 0, 0.06);
}

* { box-sizing: border-box; }
html, body { margin: 0; min-height: 100%; background: #07111d; }
body {
  font-family: Arial, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  color: var(--text-main);
  display: flex;
  justify-content: center;
  overflow: hidden;
}
button, input { font: inherit; }
button { -webkit-tap-highlight-color: transparent; }

.app-shell {
  position: relative;
  width: min(100%, 480px);
  height: 100dvh;
  overflow: hidden;
  background: linear-gradient(180deg, #4f9fda 0%, #83c6ee 58%, #d5e8ef 100%);
  isolation: isolate;
  transition: background 450ms ease;
}
.app-shell::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  pointer-events: none;
  background: var(--theme-overlay);
}

/* Weather x day/night theme engine */
.theme-clear-day { background: radial-gradient(circle at 72% 18%, rgba(255,244,174,.60) 0 5%, transparent 19%), linear-gradient(180deg,#3b96db 0%,#77c4f4 58%,#d8edf6 100%); }
.theme-clear-night { background: radial-gradient(circle at 76% 17%, rgba(232,241,255,.20) 0 4%, transparent 14%), linear-gradient(180deg,#07172f 0%,#102d53 54%,#183e63 100%); }
.theme-partly-cloudy-day { background: linear-gradient(180deg,#4b9bd8 0%,#8bbddd 48%,#d5dee2 100%); }
.theme-partly-cloudy-night { background: linear-gradient(180deg,#0d1b35 0%,#253b61 52%,#5b667d 100%); }
.theme-cloudy-day { background: linear-gradient(180deg,#687e93 0%,#96aaba 52%,#c6d0d6 100%); }
.theme-cloudy-night { background: linear-gradient(180deg,#121d2c 0%,#293848 52%,#445461 100%); }
.theme-overcast-day { background: linear-gradient(180deg,#586b7d 0%,#7e919f 54%,#aab5bc 100%); }
.theme-overcast-night { background: linear-gradient(180deg,#0d1723 0%,#202f3c 54%,#35434e 100%); }
.theme-fog-day { background: linear-gradient(180deg,#8ca2ae 0%,#b3c0c6 54%,#d8dfe1 100%); }
.theme-fog-night { background: linear-gradient(180deg,#263542 0%,#495965 54%,#6f7d86 100%); }
.theme-light-rain-day { background: linear-gradient(180deg,#526f87 0%,#6f8fa5 52%,#a8bac3 100%); }
.theme-light-rain-night { background: linear-gradient(180deg,#09192a 0%,#17354d 54%,#244b63 100%); }
.theme-heavy-rain-day { background: linear-gradient(180deg,#3b596f 0%,#536f83 50%,#78919f 100%); }
.theme-heavy-rain-night { background: linear-gradient(180deg,#07131f 0%,#122a3a 52%,#1f4053 100%); }
.theme-thunderstorm-day { background: linear-gradient(180deg,#343e52 0%,#505c6c 55%,#726f7d 100%); }
.theme-thunderstorm-night { background: linear-gradient(180deg,#080d1a 0%,#171c36 52%,#39345e 100%); }
.theme-snow-day { background: linear-gradient(180deg,#8caac1 0%,#c6d9e4 55%,#eef5f7 100%); --theme-overlay: rgba(25,46,64,.07); }
.theme-snow-night { background: linear-gradient(180deg,#13263a 0%,#31506a 55%,#687d8d 100%); }
.theme-windy-day { background: linear-gradient(180deg,#5d8ead 0%,#93b8ca 56%,#cedde3 100%); }
.theme-windy-night { background: linear-gradient(180deg,#0b2034 0%,#27475e 56%,#506a78 100%); }

.safe-top { height: var(--safe-top); flex: 0 0 auto; }
.app-view { position: absolute; inset: 0; display: none; }
.app-view.active { display: flex; flex-direction: column; }
.scroll-view { flex: 1; overflow-y: auto; overscroll-behavior-y: contain; scrollbar-width: none; }
.scroll-view::-webkit-scrollbar { display: none; }
.current-content, .places-content, .details-content { padding: 0 16px; }
.bottom-space { height: var(--safe-bottom); }

.global-loading {
  position: absolute; inset: 0; z-index: 5000; display: flex; flex-direction: column;
  align-items: center; justify-content: center; gap: 12px; background: rgba(7,17,29,.90);
  backdrop-filter: blur(18px); font-size: 14px;
}
.global-loading.hidden { display: none; }
.loading-spinner { width: 28px; height: 28px; border: 2px solid rgba(255,255,255,.24); border-top-color: #fff; border-radius: 50%; animation: spin .8s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }
.toast { position: absolute; left: 50%; bottom: calc(var(--safe-bottom) + 12px); transform: translate(-50%, 24px); opacity: 0; pointer-events: none; z-index: 6000; background: rgba(10,18,28,.88); border: 1px solid var(--glass-border); border-radius: 999px; padding: 9px 14px; font-size: 12px; transition: 220ms ease; white-space: nowrap; }
.toast.show { opacity: 1; transform: translate(-50%, 0); }

/* Shared glass */
.glass-card, .saved-place-card, .details-location-menu {
  background: var(--glass);
  border: 1px solid var(--glass-border);
  box-shadow: var(--shadow);
  backdrop-filter: blur(18px) saturate(120%);
  -webkit-backdrop-filter: blur(18px) saturate(120%);
  border-radius: var(--radius-lg);
}

/* Current view */
.top-status-row { display: flex; justify-content: space-between; align-items: center; color: var(--text-muted); font-size: 11px; min-height: 32px; }
.icon-button { width: 38px; height: 38px; border: 1px solid var(--glass-border); color: #fff; background: var(--glass); border-radius: 50%; cursor: pointer; display: inline-grid; place-items: center; font-size: 25px; line-height: 1; }
.icon-button.subtle { width: 32px; height: 32px; font-size: 17px; background: rgba(255,255,255,.09); }
.weather-hero { text-align: center; padding: 16px 0 24px; }
.location-header-row { display: flex; justify-content: center; align-items: center; gap: 9px; }
.weather-hero h1 { margin: 0; font-size: 28px; font-weight: 600; letter-spacing: -.55px; }
.favorite-button { width: 30px; height: 30px; display: grid; place-items: center; padding: 0; border: 0; background: transparent; color: rgba(255,255,255,.78); font-size: 25px; cursor: pointer; }
.favorite-button.active { color: #fff3b5; text-shadow: 0 0 12px rgba(255,229,115,.45); }
.temp-large { font-size: 78px; font-weight: 300; letter-spacing: -4px; line-height: 1; margin-top: 12px; }
.condition-text { font-size: 18px; font-weight: 600; margin-top: 8px; }
.feels-high-low { color: var(--text-muted); font-size: 14px; margin-top: 6px; }
.near-rain { margin: 10px auto 0; width: fit-content; max-width: 95%; background: rgba(13,30,45,.22); border: 1px solid rgba(255,255,255,.12); border-radius: 999px; padding: 7px 11px; font-size: 12px; }

.hourly-card { padding: 14px 10px; margin-bottom: 22px; }
.hourly-track { display: flex; overflow-x: auto; gap: 4px; scrollbar-width: none; padding: 1px 2px 4px; }
.hourly-track::-webkit-scrollbar { display:none; }
.hourly-item { min-width: 58px; display: flex; flex-direction: column; align-items: center; gap: 7px; font-size: 12px; color: var(--text-muted); }
.hourly-item strong { color: #fff; font-size: 14px; }
.weather-icon { width: 29px; height: 29px; display: block; }
.weather-icon.large { width: 36px; height: 36px; }
.weather-icon svg { width: 100%; height: 100%; display: block; overflow: visible; }
.hourly-event { min-width: 70px; }
.hourly-event .event-time { font-size: 10px; }

.outlook-section { margin-bottom: 22px; }
.outlook-section h2 { margin: 0 0 6px 2px; font-size: 20px; letter-spacing: -.2px; }
.outlook-summary { margin: 0 2px 13px; color: rgba(255,255,255,.88); font-size: 13px; line-height: 1.45; }
.outlook-card { padding: 12px; }
.outlook-stage { height: 230px; }
.outlook-panel { height: 100%; width: 100%; border: 0; padding: 0; color: inherit; background: transparent; }
.precip-chart { height: 100%; display: flex; flex-direction: column; justify-content: flex-end; cursor: pointer; }
.precip-bars { flex: 1; min-height: 0; display: grid; grid-template-columns: repeat(24, minmax(4px, 1fr)); align-items: end; gap: 3px; border-bottom: 1px solid rgba(255,255,255,.20); position: relative; padding-top: 18px; }
.precip-bars::before, .precip-bars::after { position: absolute; left: 0; color: var(--text-faint); font-size: 9px; }
.precip-bars::before { content: "Heavy"; top: 0; }
.precip-bars::after { content: "Light"; bottom: 3px; }
.precip-bar { min-height: 2px; border-radius: 4px 4px 1px 1px; background: rgba(80,182,239,.22); transition: height 300ms ease; }
.precip-bar.has-rain { box-shadow: 0 0 8px rgba(91,193,246,.12); }
.precip-axis { display: grid; grid-template-columns: repeat(4,1fr); padding-top: 7px; color: var(--text-faint); font-size: 9px; text-align: center; }
.radar-panel { cursor: pointer; text-align: left; }
.radar-map { position: relative; overflow: hidden; height: calc(100% - 18px); border-radius: 14px; background: #8194a0; }
.radar-tiles { position: absolute; inset: 0; overflow: hidden; }
.radar-tile-layer { position: absolute; width: 100%; height: 100%; }
.radar-tile { position: absolute; width: 256px; height: 256px; user-select: none; pointer-events: none; }
.radar-location-dot { position: absolute; left: 50%; top: 50%; width: 10px; height: 10px; border-radius: 50%; background: #b9bec3; border: 2px solid #fff; transform: translate(-50%,-50%); box-shadow: 0 0 0 4px rgba(0,0,0,.18); z-index: 5; }
.radar-loading-label { position: absolute; inset: 0; display: grid; place-items: center; background: rgba(15,24,33,.28); font-size: 12px; z-index: 4; }
.radar-attribution { text-align: right; font-size: 8px; color: var(--text-faint); margin-top: 5px; }
.segmented-control { position: relative; margin-top: 10px; height: 37px; border-radius: 12px; padding: 3px; background: rgba(105,109,116,.34); display: grid; grid-template-columns: 1fr 1fr; }
.segment-slider { position: absolute; left: 3px; top: 3px; width: calc(50% - 3px); height: 31px; background: rgba(62,65,71,.68); border-radius: 9px; transition: transform 220ms ease; }
.segmented-control.radar-selected .segment-slider { transform: translateX(100%); }
.segment-button { z-index: 1; border: 0; background: transparent; color: rgba(255,255,255,.65); cursor: pointer; font-size: 12px; font-weight: 600; }
.segment-button.active { color: #fff; }

.daily-card { padding: 9px 14px 4px; margin-bottom: 16px; }
.daily-mode-row { display:grid; grid-template-columns: 1fr auto; min-height: 34px; align-items:center; border-bottom: 1px solid var(--hairline); }
.daily-mode-toggle { display:flex; gap: 4px; }
.mode-button { border: 0; background: transparent; color: var(--text-faint); font-size: 11px; padding: 5px 7px; cursor:pointer; border-radius: 8px; }
.mode-button.active { color: #fff; background: rgba(255,255,255,.11); }
.daily-row { display: grid; grid-template-columns: 68px 88px 1fr; gap: 8px; min-height: 86px; align-items: center; border-bottom: 1px solid var(--hairline); cursor: pointer; }
.daily-row:last-child { border-bottom:0; }
.daily-day { font-size: 13px; font-weight: 700; }
.daily-primary { display:flex; flex-direction:column; align-items:center; gap:4px; }
.daily-high-low { font-size: 10px; color: var(--text-muted); }
.daily-granular { min-width: 0; }
.daynight-mini { display:grid; grid-template-columns:1fr 1fr; gap: 6px; }
.daynight-cell { background: rgba(255,255,255,.07); border-radius: 11px; padding: 7px 4px; text-align:center; min-width:0; }
.daynight-label { display:block; font-size:9px; color:var(--text-faint); margin-bottom:4px; }
.daynight-cell .weather-icon { margin:0 auto; width:23px; height:23px; }
.daynight-pop { margin-top:3px; font-size:9px; color:var(--text-muted); }
.mini-temp-chart { width:100%; height:72px; }
.mini-temp-chart svg { width:100%; height:100%; overflow:visible; }

.pull-indicator { position:absolute; left:0; right:0; top:var(--safe-top); height:34px; display:flex; justify-content:center; align-items:center; gap:7px; color:var(--text-muted); font-size:11px; transform:translateY(-42px); opacity:0; z-index:15; transition: opacity 100ms ease; }
.pull-indicator.visible { opacity:1; }
.pull-icon { transition: transform 150ms ease; }
.pull-indicator.ready .pull-icon { transform: rotate(180deg); }

/* Places */
#view-places { background: linear-gradient(180deg, rgba(8,17,29,.74), rgba(10,23,37,.58)); backdrop-filter: blur(9px); }
.places-content { flex:1; overflow-y:auto; padding-bottom:var(--safe-bottom); }
.search-wrapper { position:relative; margin-bottom:18px; }
.search-wrapper.compact { margin:0; }
.search-bar { width:100%; border:1px solid var(--glass-border); outline:none; background:rgba(255,255,255,.13); color:#fff; border-radius:14px; padding:12px 14px; font-size:15px; box-shadow: inset 0 1px 0 rgba(255,255,255,.06); }
.search-bar::placeholder { color:var(--text-muted); }
.suggestions-dropdown { position:absolute; z-index:100; left:0; right:0; top:calc(100% + 5px); max-height:230px; overflow-y:auto; border:1px solid var(--glass-border); background:rgba(12,20,30,.96); backdrop-filter:blur(18px); border-radius:14px; box-shadow:var(--shadow); }
.suggestion-item { width:100%; text-align:left; color:#fff; background:transparent; border:0; border-bottom:1px solid rgba(255,255,255,.08); padding:11px 13px; cursor:pointer; }
.suggestion-item:last-child { border-bottom:0; }
.suggestion-main { font-size:13px; font-weight:600; display:block; }
.suggestion-sub { font-size:10px; color:var(--text-muted); display:block; margin-top:2px; }
.section-heading-row { display:flex; align-items:center; justify-content:space-between; margin-bottom:10px; }
.section-heading-row h1 { margin:0; font-size:22px; }
.text-button { border:0; background:transparent; color:rgba(255,255,255,.62); padding:5px; cursor:pointer; font-size:13px; }
.edit-actions { display:flex; justify-content:flex-end; gap:8px; margin:-4px 0 10px; }
.primary-button, .secondary-button { border-radius:10px; padding:7px 12px; cursor:pointer; border:1px solid var(--glass-border); font-size:12px; }
.primary-button { background:rgba(255,255,255,.18); color:#fff; }
.secondary-button { background:transparent; color:var(--text-muted); }
.saved-places-list { display:flex; flex-direction:column; gap:11px; }
.saved-place-card { position:relative; overflow:hidden; min-height:111px; padding:16px; cursor:pointer; background:var(--place-bg, linear-gradient(135deg,#497e9e,#83acc0)); }
.saved-place-card::after { content:""; position:absolute; inset:0; pointer-events:none; background:linear-gradient(90deg,rgba(8,19,29,.17),rgba(8,19,29,.02)); }
.saved-place-content { position:relative; z-index:2; display:grid; grid-template-columns:1fr auto; gap:10px; }
.place-name { margin:0; font-size:18px; font-weight:700; }
.place-time { margin-top:5px; color:rgba(255,255,255,.73); font-size:11px; }
.place-condition { margin-top:20px; font-size:11px; color:rgba(255,255,255,.86); }
.place-temp-area { text-align:right; }
.place-temp { font-size:35px; font-weight:300; letter-spacing:-2px; }
.place-hi-lo { font-size:10px; color:rgba(255,255,255,.76); margin-top:3px; }
.place-edit-tools { position:absolute; right:12px; bottom:10px; z-index:3; display:flex; gap:6px; }
.edit-icon-button { width:31px; height:31px; border-radius:50%; border:1px solid rgba(255,255,255,.20); color:#fff; background:rgba(8,16,24,.34); display:grid; place-items:center; cursor:pointer; font-size:14px; }
.place-name-input { width:100%; max-width:210px; border:1px solid rgba(255,255,255,.25); background:rgba(8,16,24,.25); color:#fff; border-radius:8px; padding:6px 8px; outline:none; }
.current-location-badge { display:inline-block; margin-left:6px; font-size:9px; border:1px solid rgba(255,255,255,.25); border-radius:999px; padding:2px 5px; vertical-align:2px; color:var(--text-muted); }

/* Details */
#view-details { background: rgba(8,16,27,.30); backdrop-filter: blur(7px); }
.details-header { display:grid; grid-template-columns:44px 1fr 44px; align-items:center; padding:0 12px 10px; }
.details-location-button { justify-self:center; max-width:280px; border:1px solid var(--glass-border); background:rgba(255,255,255,.11); color:#fff; border-radius:13px; padding:9px 13px; cursor:pointer; display:flex; gap:8px; align-items:center; font-weight:700; overflow:hidden; }
.details-location-button span:first-child { overflow:hidden; text-overflow:ellipsis; white-space:nowrap; }
.details-location-menu { position:absolute; z-index:1000; left:16px; right:16px; top:calc(var(--safe-top) + 54px); padding:12px; background:rgba(10,19,29,.95); }
.details-favorite-list { margin-top:10px; display:flex; flex-direction:column; gap:4px; }
.details-favorite-item { width:100%; text-align:left; border:0; background:rgba(255,255,255,.06); color:#fff; padding:9px 10px; border-radius:9px; cursor:pointer; font-size:12px; }
.details-content { padding-top:4px; }
.date-strip { display:flex; gap:7px; overflow-x:auto; scrollbar-width:none; margin-bottom:14px; }
.date-strip::-webkit-scrollbar { display:none; }
.date-chip { min-width:66px; border:1px solid var(--glass-border); background:rgba(255,255,255,.07); color:var(--text-muted); border-radius:12px; padding:8px 7px; cursor:pointer; text-align:center; font-size:10px; }
.date-chip.active { background:rgba(255,255,255,.18); color:#fff; }
.date-chip strong { display:block; font-size:12px; margin-bottom:2px; }
.detail-hero { padding:6px 2px 14px; }
.detail-date-title { font-size:23px; font-weight:700; }
.detail-summary { color:var(--text-muted); font-size:12px; line-height:1.4; margin-top:5px; }
.hourly-detail-list { border-top:1px solid var(--hairline); }
.detail-hour-row { display:grid; grid-template-columns:58px 38px 42px 1fr; align-items:center; gap:7px; min-height:67px; border-bottom:1px solid var(--hairline); }
.detail-time { font-size:12px; font-weight:700; }
.detail-temp { font-size:19px; font-weight:500; }
.detail-metrics { display:grid; grid-template-columns:repeat(2,minmax(0,1fr)); gap:3px 8px; font-size:9px; color:var(--text-muted); }
.detail-metrics span { overflow:hidden; white-space:nowrap; text-overflow:ellipsis; }

@media (max-width: 360px) {
  .temp-large { font-size:70px; }
  .daily-row { grid-template-columns:60px 76px 1fr; }
  .daily-card { padding-left:10px; padding-right:10px; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: 0.001ms !important; animation-iteration-count: 1 !important; scroll-behavior: auto !important; transition-duration: 0.001ms !important; }
}

/* =========================================================
   Revision: universal refresh + richer precipitation UI
   ========================================================= */
.top-action-group, .details-header-actions { display:flex; align-items:center; gap:7px; }
.refresh-icon-button { font-size:18px !important; font-weight:600; }
.view-refresh-row { min-height:38px; display:flex; justify-content:flex-end; align-items:center; }
.view-refresh-spacer { flex:1; }

.hourly-rain-meta {
  max-width: 78px;
  text-align: center;
  font-size: 8px;
  line-height: 1.2;
  color: rgba(210,240,255,.88);
  white-space: normal;
}
.hourly-item:has(.hourly-rain-meta) { min-width: 78px; }

#precip-panel { display:flex; flex-direction:column; min-height:0; }
#precip-panel[hidden] { display:none; }
#precip-panel .precip-chart { flex:1; min-height:0; height:auto; }
.precip-bar {
  position: relative;
  overflow: hidden;
  background:
    linear-gradient(180deg, rgba(192,239,255,calc(var(--rain-opacity, .25) * .72)) 0%, rgba(73,187,242,var(--rain-opacity, .25)) 48%, rgba(20,126,205,var(--rain-opacity, .25)) 100%);
  box-shadow: inset 0 1px 0 rgba(255,255,255,.28), inset 0 -5px 9px rgba(12,92,158,.12);
}
.precip-bar.has-rain::after {
  content:"";
  position:absolute;
  inset:-45% 0 0;
  background: repeating-linear-gradient(115deg, transparent 0 7px, rgba(255,255,255,.22) 8px 9px, transparent 10px 16px);
  opacity:.55;
  animation: rainFlow 1.4s linear infinite;
}
@keyframes rainFlow { to { transform: translateY(34px); } }
.precip-legend {
  display:flex;
  justify-content:center;
  flex-wrap:wrap;
  gap:7px 14px;
  min-height:28px;
  align-items:center;
  padding-top:6px;
  color:var(--text-faint);
  font-size:8px;
}
.precip-legend span { display:inline-flex; align-items:center; gap:5px; }
.precip-legend i { display:inline-block; width:18px; height:8px; border-radius:4px; }
.legend-height { background:linear-gradient(90deg,rgba(72,181,239,.30),rgba(72,181,239,.95)); clip-path:polygon(0 70%,33% 70%,33% 42%,66% 42%,66% 8%,100% 8%,100% 100%,0 100%); }
.legend-color { background:linear-gradient(90deg,rgba(72,181,239,.18),rgba(72,181,239,1)); }

.hourly-graph-metric-toggle { display:flex; gap:4px; align-items:center; }
.hourly-graph-metric-toggle[hidden] { display:none; }
.metric-button {
  border:0;
  background:transparent;
  color:var(--text-faint);
  font-size:10px;
  padding:5px 7px;
  cursor:pointer;
  border-radius:8px;
}
.metric-button.active { color:#fff; background:rgba(66,165,222,.24); }
.mini-precip-chart svg { filter: drop-shadow(0 1px 2px rgba(33,151,220,.10)); }

.details-header { grid-template-columns:44px minmax(0,1fr) auto; }
.details-header-actions { justify-self:end; }
.detail-metrics span:nth-child(4) { grid-column:1 / -1; white-space:normal; overflow:visible; text-overflow:clip; }

@media (max-width: 390px) {
  .details-header { grid-template-columns:40px minmax(0,1fr) auto; gap:4px; padding-left:8px; padding-right:8px; }
  .details-header-actions { gap:4px; }
  .details-header-actions .icon-button.subtle { width:30px; height:30px; }
  .details-location-button { padding-left:9px; padding-right:9px; max-width:210px; }
  .precip-legend { gap:5px 10px; }
}

/* =========================================================
   Final desktop-to-mobile polish: white favorite, precise sun events,
   precipitation amount labels and probability legend
   ========================================================= */
.favorite-button.active {
  color: #ffffff;
  text-shadow: 0 0 10px rgba(255,255,255,.28);
}

.precip-bars {
  grid-template-columns: repeat(24, minmax(11px, 1fr));
  gap: 2px;
  overflow-x: auto;
  overflow-y: hidden;
  padding-top: 21px;
}
.precip-column {
  height: 100%;
  min-width: 11px;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  align-items: stretch;
  position: relative;
}
.precip-amount-label {
  position: absolute;
  top: -17px;
  left: 50%;
  transform: translateX(-50%) rotate(-60deg);
  transform-origin: center;
  white-space: nowrap;
  color: rgba(225,245,255,.72);
  font-size: 6px;
  line-height: 1;
  pointer-events: none;
}
.precip-column .precip-bar {
  width: 100%;
  display: block;
}
.precip-legend {
  justify-content: space-between;
  gap: 8px 14px;
  padding: 8px 2px 1px;
  font-size: 8px;
}
.legend-height-item {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  white-space: nowrap;
}
.legend-height-item .legend-height { width: 22px; height: 10px; }
.legend-probability {
  width: min(190px, 58%);
  display: grid;
  gap: 2px;
}
.legend-probability-values,
.legend-probability-labels {
  display: flex;
  justify-content: space-between;
  align-items: center;
  color: rgba(255,255,255,.58);
  font-size: 7px;
  line-height: 1;
}
.legend-probability-gradient {
  width: 100%;
  height: 8px;
  border-radius: 5px;
  background: linear-gradient(90deg, rgba(192,239,255,.32) 0%, rgba(73,187,242,.64) 50%, rgba(20,126,205,1) 100%);
  box-shadow: inset 0 1px 0 rgba(255,255,255,.22);
}
.details-sun-row {
  margin: 0 14px 12px;
  padding: 10px 12px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  border-radius: 12px;
  background: rgba(0,0,0,.16);
  border: 1px solid rgba(255,255,255,.09);
  color: rgba(255,255,255,.84);
  font-size: 11px;
}
.details-sun-row span {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  white-space: nowrap;
}
.details-sun-row .weather-icon { width: 20px; height: 20px; }
.details-sun-row strong { color: #fff; font-weight: 600; }

@media (max-width: 390px) {
  .precip-legend { align-items: flex-start; }
  .legend-probability { width: 56%; }
  .details-sun-row { font-size: 10px; gap: 6px; padding-left: 9px; padding-right: 9px; }
}
