/* رونماهوا ۳ — ظاهر تازه، نوشته‌شده از صفر.
   ایده: بالای صفحه «آسمان زنده» است و منحنی دمای ۲۴ ساعت آینده، خط افق آن.
   بقیهٔ صفحه آرام و خوانا می‌ماند تا همان یک چیز دیده شود. */

@font-face {
  font-family: "Arad";
  src: url("/fonts/Arad.woff2?v=3.0.1") format("woff2");
  font-weight: 100 800;
  font-display: swap;
}

:root {
  color-scheme: light;
  --ink: #0b1b3a;          /* سرمه‌ای رونما */
  --primary: #006bfd;      /* آبی رونما */
  --primary-2: #0052c7;
  --sun: #f5a300;
  --rain: #2f7df6;
  --bg: #f2f4f8;           /* زمین صفحه؛ خط افق هم با همین رنگ پر می‌شود */
  --bg-2: #e9edf3;
  --surface: #ffffff;
  --surface-2: #f7f9fc;
  --line: #d9e0ea;
  --text: #0f1b33;
  --text-muted: #5a6780;
  --ok: #17824d;
  --warn: #9a6200;
  --bad: #c0392b;
  --r-lg: 22px;
  --r-md: 14px;
  --r-sm: 10px;
  --wrap: 1180px;
}
:root[data-theme="dark"] {
  color-scheme: dark;
  --primary: #4a9bff;
  --primary-2: #8dc0ff;
  --bg: #071022;
  --bg-2: #0d1930;
  --surface: #0f1d38;
  --surface-2: #13233f;
  --line: #213355;
  --text: #e9f0ff;
  --text-muted: #9aaccd;
  --ok: #5fd39a;
  --warn: #f2c26b;
  --bad: #ff8a7a;
}

*, *::before, *::after { box-sizing: border-box; }
html { direction: rtl; -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } *, *::before, *::after { animation: none !important; transition: none !important; } }
body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: "Arad", Tahoma, Arial, sans-serif;
  font-size: 15px;
  line-height: 1.8;
  font-feature-settings: "tnum" 1;
  overflow-x: hidden;
}
a { color: inherit; text-decoration: none; }
button, input { font: inherit; color: inherit; }
button { cursor: pointer; }
h1, h2, h3, p { margin: 0; }
img { display: block; }
.wrap { width: min(var(--wrap), calc(100% - 40px)); margin-inline: auto; }
.hidden, [hidden] { display: none !important; }
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; border: 0; }
:focus-visible { outline: 3px solid var(--primary); outline-offset: 2px; border-radius: 6px; }
.sky :focus-visible { outline-color: #fff; }
.skip { position: absolute; inset-inline-start: 12px; top: -60px; z-index: 2000; background: var(--ink); color: #fff; padding: 10px 16px; border-radius: var(--r-sm); }
.skip:focus { top: 12px; }

/* آیکون‌های خطی */
.ic { width: 1em; height: 1em; fill: none; stroke: currentColor; stroke-width: 1.7; stroke-linecap: round; stroke-linejoin: round; flex: none; }
.ic .s { stroke: var(--sun); }
.ic .c { stroke: var(--text-muted); }
.ic .r { stroke: var(--rain); }

/* ================= آسمان ================= */
.sky {
  --sky: linear-gradient(180deg, #0a47b8 0%, #2c76e4 46%, #86bcf6 100%);
  position: relative;
  display: flex;
  flex-direction: column;
  min-height: clamp(600px, 88vh, 840px);
  color: #fff;
  background: var(--sky);
  isolation: isolate;
  overflow: hidden;
}
.sky[data-sky="dawn"] { --sky: linear-gradient(180deg, #18275c 0%, #5d4a93 38%, #e0795f 76%, #ffc07a 100%); }
.sky[data-sky="dusk"] { --sky: linear-gradient(180deg, #121c4b 0%, #593b85 40%, #e2644d 78%, #ffab63 100%); }
.sky[data-sky="night"] { --sky: linear-gradient(180deg, #040919 0%, #0a1838 52%, #1c3567 100%); }
.sky[data-sky="day"][data-weather="cloud"] { --sky: linear-gradient(180deg, #1f4f96 0%, #4a7ebd 50%, #9bbade 100%); }
.sky[data-sky="day"][data-weather="rain"], .sky[data-sky="dawn"][data-weather="rain"], .sky[data-sky="dusk"][data-weather="rain"] { --sky: linear-gradient(180deg, #1c2b42 0%, #3a5271 52%, #6f869f 100%); }
.sky[data-sky="day"][data-weather="storm"], .sky[data-sky="dawn"][data-weather="storm"], .sky[data-sky="dusk"][data-weather="storm"] { --sky: linear-gradient(180deg, #121a2e 0%, #2a3352 52%, #566282 100%); }
.sky[data-sky="day"][data-weather="snow"] { --sky: linear-gradient(180deg, #3d5676 0%, #6f8aaa 52%, #a9bdd3 100%); }
.sky[data-sky="day"][data-weather="fog"] { --sky: linear-gradient(180deg, #46566b 0%, #76869a 52%, #a7b3c1 100%); }
.sky[data-sky="night"][data-weather="rain"], .sky[data-sky="night"][data-weather="storm"], .sky[data-sky="night"][data-weather="snow"], .sky[data-sky="night"][data-weather="fog"] { --sky: linear-gradient(180deg, #070c18 0%, #151f33 52%, #2b3a55 100%); }

.sky-art { position: absolute; inset: 0; z-index: -1; pointer-events: none; }
.sky-art i { position: absolute; display: block; }
.sky-orb {
  width: clamp(84px, 11vw, 150px); aspect-ratio: 1; border-radius: 50%;
  left: 50%; top: 20%; translate: -50% -50%;
  background: radial-gradient(circle at 50% 50%, #fffbe6 0 38%, #ffe07a 62%, #ffc93c 100%);
  box-shadow: 0 0 0 28px rgba(255, 221, 120, .12), 0 0 0 64px rgba(255, 221, 120, .07), 0 0 120px 60px rgba(255, 214, 102, .35);
  transition: left 1.2s ease, top 1.2s ease;
}
.sky[data-sky="dawn"] .sky-orb, .sky[data-sky="dusk"] .sky-orb { background: radial-gradient(circle, #fff3d0 0 34%, #ffb866 70%, #ff8f4f 100%); box-shadow: 0 0 0 30px rgba(255, 170, 100, .14), 0 0 140px 70px rgba(255, 150, 90, .4); }
.sky[data-sky="night"] .sky-orb { width: clamp(64px, 8vw, 108px); background: radial-gradient(circle at 36% 36%, #ffffff 0 30%, #dfe7f5 62%, #b9c6de 100%); box-shadow: 0 0 0 18px rgba(200, 215, 245, .07), 0 0 90px 30px rgba(170, 195, 245, .22); }
.sky[data-weather="cloud"] .sky-orb { opacity: .78; }
.sky[data-weather="rain"] .sky-orb, .sky[data-weather="storm"] .sky-orb, .sky[data-weather="snow"] .sky-orb, .sky[data-weather="fog"] .sky-orb { opacity: 0; }

.sky-stars { inset: 0; opacity: 0;
  background-image: radial-gradient(1.4px 1.4px at 12% 18%, #fff 50%, transparent 51%), radial-gradient(1px 1px at 27% 9%, #fff 50%, transparent 51%), radial-gradient(1.6px 1.6px at 41% 26%, #fff 50%, transparent 51%), radial-gradient(1px 1px at 58% 12%, #fff 50%, transparent 51%), radial-gradient(1.3px 1.3px at 69% 31%, #fff 50%, transparent 51%), radial-gradient(1px 1px at 83% 16%, #fff 50%, transparent 51%), radial-gradient(1.5px 1.5px at 92% 38%, #fff 50%, transparent 51%), radial-gradient(1px 1px at 6% 42%, #fff 50%, transparent 51%), radial-gradient(1.2px 1.2px at 35% 46%, #fff 50%, transparent 51%), radial-gradient(1px 1px at 76% 49%, #fff 50%, transparent 51%), radial-gradient(1.1px 1.1px at 50% 38%, #fff 50%, transparent 51%), radial-gradient(1px 1px at 20% 33%, #fff 50%, transparent 51%); }
.sky[data-sky="night"] .sky-stars { opacity: .85; }
.sky[data-sky="night"]:not([data-weather="clear"]):not([data-weather="cloud"]) .sky-stars { opacity: 0; }

.sky-cloud { border-radius: 50%; background: #fff; filter: blur(34px); opacity: 0; }
.sky-cloud.c1 { width: 46%; height: 26%; right: -8%; top: 16%; }
.sky-cloud.c2 { width: 38%; height: 22%; left: 4%; top: 30%; }
.sky-cloud.c3 { width: 52%; height: 24%; left: 28%; top: 6%; }
.sky[data-weather="cloud"] .sky-cloud { opacity: .2; }
.sky[data-weather="rain"] .sky-cloud, .sky[data-weather="storm"] .sky-cloud, .sky[data-weather="snow"] .sky-cloud { opacity: .16; }
.sky[data-weather="fog"] .sky-cloud { opacity: .3; filter: blur(60px); }
.sky[data-sky="night"] .sky-cloud { background: #9db0d6; }

.sky-fall { inset: -20% 0 0; opacity: 0; }
.sky[data-weather="rain"] .sky-fall, .sky[data-weather="storm"] .sky-fall {
  opacity: .5;
  background-image: repeating-linear-gradient(100deg, transparent 0 22px, rgba(255, 255, 255, .5) 22px 23px, transparent 23px 47px);
  background-size: 94px 180px;
  mask-image: linear-gradient(180deg, transparent, #000 30%, #000 70%, transparent);
  animation: fall .7s linear infinite;
}
.sky[data-weather="snow"] .sky-fall {
  opacity: .8;
  background-image: radial-gradient(2.4px 2.4px at 20% 20%, #fff 50%, transparent 51%), radial-gradient(1.8px 1.8px at 60% 50%, #fff 50%, transparent 51%), radial-gradient(2.2px 2.2px at 85% 80%, #fff 50%, transparent 51%), radial-gradient(1.6px 1.6px at 40% 85%, #fff 50%, transparent 51%);
  background-size: 180px 180px;
  animation: fall 7s linear infinite;
}
@keyframes fall { to { background-position: 0 180px; } }
/* باران تازه روی بوم کشیده می‌شود (sky.js)؛ نوارهای قدیمی فقط وقتی بوم نباشد دیده می‌شوند. */
.sky-rain { position: absolute; inset: 0; width: 100%; height: 100%; mask-image: linear-gradient(180deg, transparent 0, #000 18%, #000 72%, transparent 96%); -webkit-mask-image: linear-gradient(180deg, transparent 0, #000 18%, #000 72%, transparent 96%); }
.sky.has-rain-canvas[data-weather="rain"] .sky-fall, .sky.has-rain-canvas[data-weather="storm"] .sky-fall { opacity: 0; animation: none; }

/* ---------- سربرگ (فقط یکی) ---------- */
.top { position: relative; z-index: 30; }
.top-row { display: flex; align-items: center; gap: 18px; height: 76px; }
.brand { display: inline-flex; align-items: center; gap: 10px; font-size: 21px; font-weight: 800; letter-spacing: -.01em; white-space: nowrap; }
.brand img { width: 30px; height: 30px; filter: brightness(0) invert(1); }
.brand b { font-weight: 300; margin-inline-start: 5px; }
.search { position: relative; flex: 1 1 320px; max-width: 420px; display: flex; align-items: center; gap: 10px; height: 46px; padding-inline: 16px; border-radius: 999px; background: rgba(255, 255, 255, .16); border: 1px solid rgba(255, 255, 255, .28); backdrop-filter: blur(10px); transition: background .15s; }
.search:focus-within { background: rgba(255, 255, 255, .26); border-color: #fff; }
.search > .ic { font-size: 19px; opacity: .9; }
.search input { flex: 1; min-width: 0; height: 100%; border: 0; outline: 0; background: transparent; color: #fff; font-size: 15px; }
.search input::placeholder { color: rgba(255, 255, 255, .78); }
.top-links { display: flex; gap: 4px; margin-inline-start: auto; }
.top-links a { padding: 8px 14px; border-radius: 999px; font-size: 14.5px; font-weight: 500; }
.top-links a:hover { background: rgba(255, 255, 255, .16); }
.top-actions { display: flex; gap: 8px; }
.tbtn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-width: 44px; height: 44px; padding: 0; border-radius: 999px; border: 1px solid rgba(255, 255, 255, .28); background: rgba(255, 255, 255, .14); color: #fff; font-size: 20px; }
.tbtn:hover { background: rgba(255, 255, 255, .26); }
.tbtn-wide { padding-inline: 16px; }
.tbtn-wide span { font-size: 14.5px; font-weight: 600; }
.tbtn .ic .s, .tbtn .ic .c, .tbtn .ic .r { stroke: currentColor; }

.net { display: none; position: absolute; inset-inline: 0; top: 100%; background: var(--ink); color: #dbe6ff; border-top: 1px solid rgba(255, 255, 255, .12); box-shadow: 0 30px 60px rgba(4, 12, 30, .45); max-height: 76vh; overflow: auto; }
.net.open { display: block; }
.net-grid { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 28px; padding-block: 30px 34px; }
.net-col h3 { font-size: 13px; font-weight: 500; color: #8fa6d6; margin-bottom: 8px; }
.net-col a, .net-col button { display: block; width: 100%; text-align: start; padding: 6px 0; background: none; border: 0; font-size: 15px; color: #fff; }
.net-col a:hover, .net-col button:hover { color: #9cc4ff; }

.search-dropdown { position: absolute; inset-inline: 0; top: calc(100% + 8px); z-index: 40; background: var(--surface); color: var(--text); border: 1px solid var(--line); border-radius: var(--r-md); box-shadow: 0 24px 50px rgba(7, 18, 44, .28); padding: 6px; max-height: 340px; overflow: auto; }
.search-option { display: block; width: 100%; text-align: start; padding: 11px 14px; border: 0; border-radius: var(--r-sm); background: none; font-size: 15px; }
.search-option:hover, .search-option.active { background: var(--bg-2); color: var(--primary-2); }
.search-option.notice-row { color: var(--text-muted); display: flex; align-items: center; gap: 8px; }

/* ---------- متن روی آسمان ---------- */
.sky-body { flex: 1; display: flex; flex-direction: column; justify-content: flex-end; padding-block: 12px 26px; }
.sky-msg { align-self: flex-start; margin-bottom: 12px; padding: 9px 16px; border-radius: var(--r-md); background: rgba(8, 20, 48, .62); backdrop-filter: blur(8px); font-size: 14px; display: flex; gap: 10px; align-items: center; flex-wrap: wrap; }
.sky-msg .btn { min-height: 36px; padding: 0 14px; background: rgba(255, 255, 255, .16); border-color: rgba(255, 255, 255, .34); color: #fff; font-size: 13.5px; }
.sky-msg .btn:hover { background: rgba(255, 255, 255, .26); border-color: #fff; color: #fff; }
#loadState .notice { margin-bottom: 12px; background: rgba(8, 20, 48, .62); color: #fff; border: 0; backdrop-filter: blur(8px); }
.sky-main { display: grid; grid-template-columns: minmax(0, 1fr) minmax(280px, 400px); grid-template-areas: "where story" "now story"; column-gap: 48px; align-items: end; }
.sky-where { grid-area: where; }
.sky-place { font-size: clamp(30px, 4.4vw, 52px); font-weight: 800; line-height: 1.3; letter-spacing: -.02em; }
.sky-sub { display: flex; flex-wrap: wrap; gap: 4px 16px; font-size: 15px; opacity: .92; }
.sky-sub span:empty { display: none; }
.sky-now { grid-area: now; display: flex; align-items: flex-end; gap: clamp(14px, 3vw, 34px); margin-top: 4px; }
.sky-temp { font-size: clamp(104px, 19vw, 208px); font-weight: 800; line-height: .86; letter-spacing: -.055em; direction: ltr; padding-bottom: .06em; text-shadow: 0 6px 40px rgba(5, 20, 60, .25); }
.sky-cond { display: flex; flex-direction: column; gap: 2px; padding-bottom: clamp(10px, 2.4vw, 30px); font-size: 17px; }
.sky-cond b { font-size: clamp(20px, 2.4vw, 28px); font-weight: 700; line-height: 1.4; }
.sky-icon { font-size: clamp(34px, 4vw, 52px); line-height: 1; height: 1em; }
.sky-icon .ic .s, .sky-icon .ic .c, .sky-icon .ic .r { stroke: #fff; }
.sky-icon .ic { stroke-width: 1.3; }
.sky-range { opacity: .92; }
.sky-story { grid-area: story; padding: 22px 24px; border-radius: var(--r-lg); background: rgba(8, 20, 48, .34); border: 1px solid rgba(255, 255, 255, .2); backdrop-filter: blur(14px); margin-bottom: clamp(10px, 2.4vw, 30px); }
.sky-story h2 { font-size: 21px; font-weight: 800; line-height: 1.6; }
.sky-story p { font-size: 15px; opacity: .93; margin-top: 4px; }
.sky-actions { display: flex; gap: 8px; margin-top: 16px; }
.pill { display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-width: 44px; height: 44px; padding-inline: 14px; border-radius: 999px; border: 1px solid rgba(255, 255, 255, .34); background: rgba(255, 255, 255, .12); color: #fff; font-size: 19px; }
.pill span { font-size: 14px; }
.pill:hover { background: rgba(255, 255, 255, .26); }

/* ---------- خط افق: ۲۴ ساعت آینده ---------- */
.horizon { position: relative; overflow-x: auto; overflow-y: hidden; scrollbar-width: none; }
.horizon::-webkit-scrollbar { display: none; }
.horizon-track { position: relative; height: 232px; min-width: max(100%, calc(var(--n, 24) * 60px)); }
.horizon-track > svg { position: absolute; inset: 0; width: 100%; height: 100%; transform: scaleX(-1); }
.hz-land { fill: var(--bg); }
.hz-line { fill: none; stroke: var(--hz); stroke-width: 3; stroke-linecap: round; vector-effect: non-scaling-stroke; }
.horizon-track { --hz: #2f8bff; }
.hz-dot { position: absolute; left: 50%; width: 11px; height: 11px; margin: -5.5px 0 0 -5.5px; border-radius: 50%; background: #fff; border: 3px solid var(--hz); box-sizing: border-box; }
.horizon-track li.is-now .hz-dot { width: 15px; height: 15px; margin: -7.5px 0 0 -7.5px; background: var(--hz); border-color: #fff; box-shadow: 0 0 0 4px rgba(47, 139, 255, .28); }
.hz-cap { position: absolute; top: 2px; inset-inline-start: 16px; margin: 0; display: inline-flex; align-items: center; gap: 8px; padding: 4px 12px; border-radius: 999px; background: rgba(8, 20, 44, .42); color: #fff; font-size: 12.5px; font-weight: 600; line-height: 1.5; pointer-events: none; }
.hz-cap i { position: relative; width: 22px; height: 3px; border-radius: 3px; background: var(--hz); }
.hz-cap i::after { content: ""; position: absolute; left: 50%; top: 50%; width: 8px; height: 8px; margin: -4px 0 0 -4px; border-radius: 50%; background: #fff; border: 2px solid var(--hz); box-sizing: border-box; }
.horizon-track ol { position: absolute; inset: 0; margin: 0; padding: 0; list-style: none; display: grid; grid-template-columns: repeat(var(--n, 24), minmax(0, 1fr)); }
.horizon-track li { position: relative; }
.horizon-track li > b { position: absolute; inset-inline: 0; text-align: center; font-size: 17px; font-weight: 700; line-height: 1; color: #fff; text-shadow: 0 1px 10px rgba(5, 20, 60, .5); }
.horizon-track li > span { position: absolute; inset-inline: 0; text-align: center; color: var(--text); }
.hz-ic { top: 134px; font-size: 24px; line-height: 1; }
.hz-h { top: 168px; font-size: 13.5px; color: var(--text-muted) !important; }
.hz-p { top: 194px; font-size: 12.5px; font-weight: 700; color: var(--rain) !important; }
.horizon-track li.is-now .hz-h { color: var(--text) !important; font-weight: 800; }
.horizon-track li.is-now::after { content: ""; position: absolute; inset-inline: 22%; bottom: 0; height: 3px; border-radius: 3px 3px 0 0; background: var(--primary); }

/* ================= بدنهٔ صفحه ================= */
.page { padding-block: 6px 56px; }
.block { padding-block: 30px; border-top: 1px solid var(--line); }
.block-head, .section-head { display: flex; align-items: baseline; justify-content: space-between; gap: 12px; flex-wrap: wrap; margin-bottom: 16px; }
.block h2 { font-size: 22px; font-weight: 800; letter-spacing: -.01em; line-height: 1.5; }
.block-head > span, .section-head > span { font-size: 13.5px; color: var(--text-muted); }
.block > h2 { margin-bottom: 16px; }
.note { margin-top: 12px; font-size: 13px; color: var(--text-muted); }
.link-btn { background: none; border: 0; padding: 4px 0; font-size: 14.5px; font-weight: 600; color: var(--primary-2); border-bottom: 1px solid transparent; }
.link-btn:hover { border-bottom-color: currentColor; }
.btn { display: inline-flex; align-items: center; justify-content: center; min-height: 44px; padding: 0 18px; border-radius: 999px; border: 1px solid var(--line); background: var(--surface); font-size: 14.5px; font-weight: 600; }
.btn:hover { border-color: var(--primary); color: var(--primary-2); }
.btn.primary { background: var(--primary); border-color: var(--primary); color: #fff; }

.cols { display: grid; grid-template-columns: minmax(0, 1.55fr) minmax(0, 1fr); column-gap: 56px; align-items: start; border-top: 1px solid var(--line); }
#xGuide { border-top: 0; }
.cols .col-main > .block:first-child, .cols .col-side > .block:first-child { border-top: 0; }
.duo { display: grid; grid-template-columns: 1fr 1fr; column-gap: 56px; }
.trio { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 2.2fr); column-gap: 56px; border-top: 1px solid var(--line); }
.trio > .block, .trio .duo > .block { border-top: 0; }

.favs { padding-block: 18px 0; }
.favs-row { display: flex; gap: 8px; overflow-x: auto; scrollbar-width: none; }
.favorite-chip { flex: none; display: inline-flex; align-items: baseline; gap: 8px; padding: 9px 16px; border-radius: 999px; border: 1px solid var(--line); background: var(--surface); }
.favorite-chip small { color: var(--text-muted); font-size: 12.5px; }
.favorite-chip:hover { border-color: var(--primary); }

/* ---------- روزهای پیش رو ---------- */
.days { display: flex; flex-direction: column; }
.day { display: grid; grid-template-columns: 118px 30px minmax(0, 1fr) 76px 38px minmax(90px, 1.2fr) 38px; align-items: center; column-gap: 12px; min-height: 58px; border-bottom: 1px solid var(--line); }
.day:last-child { border-bottom: 0; }
.day.far { display: none; opacity: .82; }
.days.show-all .day.far { display: grid; }
.d-name { display: flex; flex-direction: column; line-height: 1.5; }
.d-name b { font-size: 15.5px; font-weight: 700; }
.d-name small { font-size: 12.5px; color: var(--text-muted); }
.d-ic { font-size: 26px; line-height: 1; height: 1em; }
.d-desc { font-size: 14px; color: var(--text-muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.d-rain { font-size: 12.5px; font-weight: 700; color: var(--rain); white-space: nowrap; text-align: end; }
.d-lo { color: var(--text-muted); text-align: start; }
.d-hi { font-weight: 800; text-align: end; }
.d-lo, .d-hi { font-size: 16px; }
.d-bar { position: relative; height: 8px; border-radius: 8px; background: var(--bg-2); }
.d-bar i { position: absolute; top: 0; bottom: 0; border-radius: 8px; }

/* ---------- هشدار، آگاهی ---------- */
.alert { padding: 14px 16px; border-radius: var(--r-md); background: color-mix(in srgb, var(--sun) 14%, var(--surface)); border-inline-start: 4px solid var(--sun); margin-bottom: 8px; }
.alert b { display: block; font-size: 15.5px; }
.alert small { display: block; font-size: 13.5px; color: var(--text-muted); }
.alert.ok { background: color-mix(in srgb, var(--ok) 10%, var(--surface)); border-inline-start-color: var(--ok); }
.notice { padding: 14px 16px; border-radius: var(--r-md); background: var(--surface); border: 1px solid var(--line); font-size: 15px; line-height: 1.9; }
.error-notice { display: flex; flex-direction: column; align-items: flex-start; gap: 6px; }
.spinner { display: inline-block; width: 16px; height: 16px; border-radius: 50%; border: 2px solid currentColor; border-inline-end-color: transparent; animation: spin .8s linear infinite; vertical-align: -3px; }
@keyframes spin { to { transform: rotate(360deg); } }

/* ---------- همین حالا ---------- */
.facts { margin: 0; display: grid; grid-template-columns: 1fr 1fr; column-gap: 28px; }
.facts > div { display: flex; align-items: baseline; justify-content: space-between; gap: 10px; padding-block: 11px; border-bottom: 1px solid var(--line); }
.facts > div:nth-last-child(-n+2) { border-bottom: 0; }
.facts dt { font-size: 14px; color: var(--text-muted); }
.facts dd { margin: 0; font-size: 16px; font-weight: 700; white-space: nowrap; }

.metrics { display: grid; grid-template-columns: repeat(auto-fill, minmax(210px, 1fr)); column-gap: 40px; }
.metric { display: flex; align-items: baseline; justify-content: space-between; gap: 10px; padding-block: 11px; border-bottom: 1px solid var(--line); }
.metric span { font-size: 14px; color: var(--text-muted); }
.metric b { font-size: 15.5px; font-weight: 700; text-align: end; }

/* ---------- کیفیت هوا ---------- */
.aqi { display: block; }
.aqi-main { display: flex; align-items: baseline; gap: 10px; flex-wrap: wrap; }
.aqi-main b { font-size: 56px; font-weight: 800; line-height: 1; letter-spacing: -.03em; }
.aqi-main span { font-size: 17px; font-weight: 700; }
.aqi-main small { font-size: 12.5px; color: var(--text-muted); }
.aqi[data-band="ok"] .aqi-main b, .aqi[data-band="ok"] .aqi-main span { color: var(--ok); }
.aqi[data-band="warn"] .aqi-main b, .aqi[data-band="warn"] .aqi-main span { color: var(--warn); }
.aqi[data-band="bad"] .aqi-main b, .aqi[data-band="bad"] .aqi-main span { color: var(--bad); }
.aqi-metrics { display: grid; grid-template-columns: 1fr 1fr; column-gap: 28px; margin-top: 10px; }
.aqi-explain { grid-column: 1 / -1; margin-top: 12px; font-size: 14px; color: var(--text-muted); line-height: 1.9; }
.aqi-explain b { color: var(--text); }

/* ---------- نقشه ---------- */
.seg { display: inline-flex; padding: 4px; border-radius: 999px; background: var(--bg-2); }
.layer-btn { min-width: 64px; height: 40px; padding: 0 16px; border: 0; border-radius: 999px; background: transparent; font-size: 14.5px; font-weight: 600; color: var(--text-muted); }
.layer-btn:hover { color: var(--text); }
.layer-btn.active { background: var(--surface); color: var(--text); box-shadow: 0 1px 3px rgba(11, 27, 58, .16); }
.map-shell { position: relative; height: clamp(360px, 62vh, 560px); border-radius: var(--r-lg); overflow: hidden; background: var(--bg-2); isolation: isolate; }
#mapFrame { width: 100%; height: 100%; }
.map-hint { position: absolute; top: 50%; inset-inline: 24px; translate: 0 -50%; z-index: 1200; text-align: center; padding: 12px 16px; border-radius: var(--r-md); background: rgba(11, 27, 58, .88); color: #fff; font-size: 14px; font-weight: 700; pointer-events: none; }
.map-foot { display: flex; align-items: center; gap: 14px 22px; flex-wrap: wrap; margin-top: 14px; }
.map-foot .note { margin: 0; flex: 1 1 260px; }
.radar-timeline { display: flex; align-items: center; gap: 12px; flex: 1 1 340px; }
.radar-timeline .tbtn { border-color: var(--line); background: var(--surface); color: var(--text); font-size: 16px; }
.radar-timeline .tbtn:disabled { opacity: .5; cursor: default; }
.radar-timeline span { font-size: 14px; font-weight: 700; min-width: 48px; text-align: center; }
.radar-timeline input[type="range"] { flex: 1; accent-color: var(--primary); direction: ltr; }
.map-legend { display: flex; align-items: center; gap: 8px; font-size: 12.5px; color: var(--text-muted); }
.map-legend:empty { display: none; }
.map-legend i { display: block; width: 130px; height: 8px; border-radius: 8px; }
.map-legend span:first-child { font-weight: 700; color: var(--text); }
:root[data-theme="dark"] .leaflet-tile-pane { filter: invert(1) hue-rotate(180deg) brightness(.92) contrast(.9); }
:root[data-theme="dark"] .leaflet-marker-icon:not(.xmw) { filter: invert(1) hue-rotate(180deg); }
.leaflet-container { font-family: inherit; }
.leaflet-control-zoom { border: 0 !important; box-shadow: 0 4px 16px rgba(11, 27, 58, .2) !important; border-radius: 12px !important; overflow: hidden; }
.leaflet-control-zoom a { background: var(--surface) !important; color: var(--text) !important; border-color: var(--line) !important; width: 40px !important; height: 40px !important; line-height: 40px !important; }
.leaflet-control-attribution { background: color-mix(in srgb, var(--surface) 80%, transparent) !important; color: var(--text-muted) !important; font-size: 10.5px !important; }
.leaflet-div-icon.xmw { background: transparent; border: 0; }
.xm { display: flex; align-items: center; gap: 3px; padding: 3px 9px; border-radius: 999px; font: 800 13px/1.5 "Arad", Tahoma, sans-serif; color: #0b1b3a; box-shadow: 0 2px 8px rgba(10, 30, 70, .3); border: 2px solid #fff; white-space: nowrap; transform: translate(-50%, -50%); width: max-content; }
.xm.dk { color: #fff; }
.xm svg { width: 13px; height: 13px; flex: none; }

/* ---------- راهنمای امروز ---------- */
.xg-top { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.xg-card { padding: 20px 22px; border-radius: var(--r-lg); background: var(--surface); }
.xg-title { display: flex; align-items: center; gap: 8px; font-size: 15px; font-weight: 700; color: var(--text-muted); margin-bottom: 6px; }
.xg-title span { font-size: 20px; line-height: 1; }
.xg-list { margin: 0; padding: 0; list-style: none; font-size: 18px; font-weight: 700; line-height: 1.9; }
.xg-sub { font-size: 13.5px; color: var(--text-muted); }
.xg-big { font-size: 40px; font-weight: 800; line-height: 1.3; letter-spacing: -.02em; color: var(--primary-2); }
.xg-acts { display: grid; grid-template-columns: repeat(auto-fill, minmax(250px, 1fr)); column-gap: 40px; margin-top: 10px; }
.xg-act { padding-block: 16px; border-bottom: 1px solid var(--line); }
.xg-act-h { display: flex; align-items: center; gap: 10px; margin-bottom: 8px; }
.xg-act-h b { flex: 1; font-size: 15.5px; }
.xg-act-h em { font-style: normal; font-size: 13px; font-weight: 800; }
.xg-ico { font-size: 22px; line-height: 1; height: 1em; }
.xg-bar { height: 5px; border-radius: 5px; background: var(--bg-2); overflow: hidden; }
.xg-bar i { display: block; height: 100%; border-radius: 5px; float: right; }
.xg-act p { margin-top: 8px; font-size: 13.5px; color: var(--text-muted); line-height: 1.8; }
.xg-act.ok .xg-bar i { background: var(--ok); } .xg-act.ok em { color: var(--ok); }
.xg-act.good .xg-bar i { background: #6fae3c; } .xg-act.good em { color: #5c9a2c; }
.xg-act.mid .xg-bar i { background: var(--sun); } .xg-act.mid em { color: var(--warn); }
.xg-act.bad .xg-bar i { background: var(--bad); } .xg-act.bad em { color: var(--bad); }

/* ---------- خورشید، باد، آفتاب ---------- */
.sun-arc { display: flex; flex-direction: column; gap: 4px; }
.sun-arc svg { width: 100%; max-width: 280px; height: auto; margin-inline: auto; overflow: visible; }
.arc-track { fill: none; stroke: var(--line); stroke-width: 2.5; stroke-linecap: round; stroke-dasharray: 2 7; }
.sun-dot { fill: var(--sun); filter: drop-shadow(0 0 10px color-mix(in srgb, var(--sun) 70%, transparent)); transition: cx .4s ease, cy .4s ease; }
.sun-times { display: flex; justify-content: space-between; }
.sun-times div { display: flex; flex-direction: column; line-height: 1.5; }
.sun-times div:last-child { text-align: end; }
.sun-times span { font-size: 13px; color: var(--text-muted); }
.sun-times b { font-size: 20px; font-weight: 800; }
.daylight-length { margin-top: 8px; font-size: 14px; color: var(--text-muted); }
.daylight-length b { color: var(--text); }
.xw-top { display: flex; align-items: center; gap: 20px; }
.xw-compass { width: 118px; height: 118px; flex: none; }
.xw-ring { fill: none; stroke: var(--line); stroke-width: 2; }
.xw-t text { font-size: 9.5px; fill: var(--text-muted); text-anchor: middle; font-family: inherit; }
.xw-arrow { fill: var(--primary); }
.xw-dot { fill: var(--bg); stroke: var(--primary); stroke-width: 2; }
.xw-speed { font-size: 42px; font-weight: 800; line-height: 1.2; letter-spacing: -.02em; }
.xw-speed small { font-size: 14px; font-weight: 500; color: var(--text-muted); letter-spacing: 0; }
.xw-bars { display: flex; gap: 6px; align-items: flex-end; height: 76px; margin-top: 8px; }
.xw-col { flex: 1; display: flex; flex-direction: column; align-items: center; gap: 4px; height: 100%; }
.xw-bar { flex: 1; width: 100%; display: flex; align-items: flex-end; }
.xw-bar i { display: block; width: 100%; background: var(--primary); border-radius: 4px 4px 1px 1px; opacity: .85; }
.xw-col small { font-size: 11px; color: var(--text-muted); }
.xu-top { display: flex; align-items: center; gap: 16px; margin-bottom: 14px; }
.xu-num { font-size: 56px; font-weight: 800; line-height: 1; letter-spacing: -.03em; }
.xu-scale { position: relative; height: 8px; border-radius: 8px; background: linear-gradient(to left, #2fa36b 0 25%, #d6a200 25% 50%, #e8820c 50% 66%, #d8432f 66% 91%, #8e3bb8 91%); }
.xu-scale i { position: absolute; top: -5px; width: 6px; height: 18px; border-radius: 4px; background: var(--text); border: 2px solid var(--bg); margin-right: -3px; }
.xu-lab { display: flex; justify-content: space-between; font-size: 11.5px; color: var(--text-muted); margin-top: 5px; }
#xUv > p, #xUv .xg-p { margin-top: 12px; font-size: 14px; line-height: 1.9; }

.xk-list { margin: 0; padding: 0; list-style: none; display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); column-gap: 40px; }
.xk-list li { padding-block: 11px; border-bottom: 1px solid var(--line); font-size: 15px; }
.xconf.ok { color: var(--ok); } .xconf.mid { color: var(--warn); } .xconf.bad { color: var(--bad); }
.chart-shell { position: relative; height: 250px; }

/* ---------- ایران، شهرها ---------- */
.rank-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); column-gap: 40px; }
.rank-card { display: flex; flex-direction: column; padding-block: 4px; }
.rank-card b { font-size: 13.5px; font-weight: 500; color: var(--text-muted); }
.rank-card span { font-size: 21px; font-weight: 800; line-height: 1.6; }
.nearby-grid { display: flex; flex-wrap: wrap; gap: 8px; }
.nearby-card { display: inline-flex; align-items: baseline; gap: 8px; padding: 9px 16px; border-radius: 999px; border: 1px solid var(--line); background: var(--surface); }
.nearby-card span { font-size: 12.5px; color: var(--text-muted); }
.nearby-card:hover { border-color: var(--primary); }
.provinces, .province-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(190px, 1fr)); column-gap: 40px; }
.province, .province-card { display: flex; align-items: baseline; justify-content: space-between; gap: 8px; padding-block: 11px; border-bottom: 1px solid var(--line); }
.province b, .province-card b { font-size: 15.5px; font-weight: 600; }
.province small, .province-card span { font-size: 12.5px; color: var(--text-muted); white-space: nowrap; }
.province:hover b, .province-card:hover b { color: var(--primary-2); }
.cities { display: flex; flex-wrap: wrap; gap: 8px; }
.city { display: inline-block; padding: 7px 15px; border-radius: 999px; border: 1px solid var(--line); background: var(--surface); font-size: 14.5px; }
.city:hover { border-color: var(--primary); color: var(--primary-2); }
.crumbs { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; font-size: 13.5px; color: var(--text-muted); margin-bottom: 8px; }
.crumbs a { color: var(--primary-2); }
.crumbs a:hover { text-decoration: underline; }
.crumbs b { color: var(--text); font-weight: 600; }
.city-intro p { max-width: 70ch; color: var(--text-muted); }
.city-facts { display: flex; flex-wrap: wrap; gap: 6px 24px; margin: 12px 0 0; padding: 0; list-style: none; font-size: 14px; color: var(--text-muted); }
.city-facts b { color: var(--text); }
.city-sibs { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; margin-top: 16px; }
.city-sibs > span { font-size: 13.5px; color: var(--text-muted); }
.muted { color: var(--text-muted); }
.small { font-size: 13px; }

.tools { display: grid; grid-template-columns: repeat(auto-fit, minmax(210px, 1fr)); column-gap: 48px; row-gap: 26px; border-top: 1px solid var(--line); padding-block: 30px; }
.tool h2 { font-size: 18px; font-weight: 800; }
.tool p { font-size: 14px; color: var(--text-muted); margin-block: 4px 14px; }

/* ---------- پابرگ ---------- */
.foot { background: var(--ink); color: #b8c8e8; font-size: 14px; padding-block: 40px 22px; }
.foot-top { display: flex; align-items: center; justify-content: space-between; gap: 16px; flex-wrap: wrap; padding-bottom: 26px; border-bottom: 1px solid rgba(255, 255, 255, .12); }
.foot-brand { display: inline-flex; align-items: center; gap: 12px; }
.foot-brand img { filter: brightness(0) invert(1); }
.foot-brand span { display: flex; flex-direction: column; line-height: 1.4; }
.foot-brand b { font-size: 20px; color: #fff; }
.foot-brand small { font-size: 12.5px; }
.foot-src { font-size: 13px; }
.rf-cols { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 24px; padding-block: 28px; }
.rf-col h4 { margin: 0 0 8px; font-size: 13px; font-weight: 500; color: #8fa6d6; }
.rf-col a { display: block; padding: 4px 0; color: #e6eeff; }
.rf-col a:hover, .rf-social a:hover, .foot-bottom a:hover { color: #9cc4ff; }
.rf-social { display: flex; flex-wrap: wrap; gap: 6px 18px; padding-block: 18px; border-top: 1px solid rgba(255, 255, 255, .12); }
.rf-social span { color: #8fa6d6; }
.foot-bottom { display: flex; justify-content: space-between; gap: 12px; flex-wrap: wrap; padding-top: 18px; border-top: 1px solid rgba(255, 255, 255, .12); font-size: 13px; }
.foot-bottom a { margin-inline-start: 18px; }

/* ================= صفحهٔ باریک ================= */
@media (max-width: 980px) {
  .cols, .duo, .trio { grid-template-columns: 1fr; }
  .cols .col-side > .block:first-child, .duo > .block + .block, .trio > .duo > .block:first-child { border-top: 1px solid var(--line); }
  .trio > .duo { border-top: 1px solid var(--line); }
  .trio > .duo > .block:first-child { border-top: 0; }
  .rank-grid { grid-template-columns: 1fr 1fr; row-gap: 14px; }
  .tools { grid-template-columns: 1fr; row-gap: 26px; }
  .net-grid, .rf-cols { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .top-links { display: none; }
  .top-actions { margin-inline-start: auto; }
  .sky-main { grid-template-columns: 1fr; grid-template-areas: "where" "now" "story"; }
  .sky-story { margin-top: 18px; margin-bottom: 6px; }
}
@media (max-width: 640px) {
  .wrap { width: calc(100% - 32px); }
  body { font-size: 15px; }
  .sky { min-height: 0; }
  .top-row { flex-wrap: wrap; height: auto; padding-block: 12px 4px; gap: 10px; }
  .brand { font-size: 19px; }
  .search { order: 3; flex: 1 1 100%; max-width: none; }
  .tbtn-wide span { display: none; }
  .tbtn-wide { padding-inline: 0; }
  .sky-body { padding-block: 28px 18px; }
  .sky-story { padding: 16px 18px; }
  .sky-story h2 { font-size: 18px; }
  .block { padding-block: 24px; }
  .block h2 { font-size: 20px; }
  .day { grid-template-columns: 84px 26px 34px minmax(60px, 1fr) 34px; column-gap: 10px; min-height: 56px; }
  .d-desc { display: none; }
  .d-rain { grid-column: 1 / -1; grid-row: 2; text-align: start; margin-top: -10px; padding-bottom: 6px; }
  .d-rain:empty { display: none; }
  .facts, .aqi-metrics { column-gap: 20px; }
  .xg-top { grid-template-columns: 1fr; }
  .net-grid { gap: 20px; padding-block: 22px; }
  .map-shell { height: 56vh; }
  .seg { width: 100%; }
  .layer-btn { flex: 1; min-width: 0; padding: 0 6px; }
}

/* اصلاح‌های پس از بازبینی */
.sun-arc.is-night .sun-dot { opacity: 0; }
.xw-speed small { display: block; margin-top: -4px; }
.facts dd, .metric b, .rank-card span { white-space: normal; text-align: end; }
.rank-card span { font-size: 19px; }
.sky-now { margin-top: 18px; }
.sky-temp { line-height: .9; }
.horizon-track li.is-now::after { display: none; }
.horizon-track { height: 224px; }
@media (max-width: 640px) {
  .sky { min-height: 0; }
  .sky-body { justify-content: flex-start; padding-block: 22px 14px; flex: none; }
  .sky-orb { width: 72px; }
  .sky-place { font-size: 34px; }
  .sky-temp { font-size: 112px; }
  .facts dd, .metric b { font-size: 15px; }
  .aqi-main b { font-size: 48px; }
}

/* ================= صفحه‌های فهرست (شهرها، استان‌ها، هر استان) ================= */
.sky-mini { min-height: 0; overflow: visible; }
.sky-mini .sky-art { overflow: hidden; }
.sky-mini .sky-orb { width: 92px; left: 14%; top: 62%; }
.sky-mini .sky-body { flex: none; justify-content: flex-start; padding-block: 34px 44px; }
.sky-mini .sky-sub { margin-top: 4px; max-width: 60ch; }
.sky .crumbs { color: rgba(255, 255, 255, .8); margin-bottom: 10px; }
.sky .crumbs a { color: #fff; text-decoration: underline; text-underline-offset: 4px; }
.sky .crumbs b { color: #fff; }
.block.first { border-top: 0; }
.pv-sum { display: flex; flex-wrap: wrap; gap: 14px 44px; margin-top: 22px; }
.pv-sum div { display: flex; flex-direction: column; line-height: 1.6; }
.pv-sum span { font-size: 13.5px; opacity: .85; }
.pv-sum b { font-size: 19px; font-weight: 800; }
.pv-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(250px, 1fr)); column-gap: 40px; }
.pv-city { display: flex; align-items: center; justify-content: space-between; gap: 12px; min-height: 72px; padding-block: 10px; border-bottom: 1px solid var(--line); }
.pv-city > span:first-child { display: flex; flex-direction: column; line-height: 1.6; }
.pv-city b { font-size: 17px; font-weight: 700; }
.pv-city small { font-size: 13px; color: var(--text-muted); }
.pv-temp { font-size: 30px; font-weight: 800; letter-spacing: -.02em; direction: ltr; }
.pv-city:hover b { color: var(--primary-2); }
.dir-search { width: 100%; max-width: 460px; height: 50px; padding-inline: 18px; border-radius: 999px; border: 1px solid var(--line); background: var(--surface); font-size: 16px; }
.dir-search:focus { outline: 0; border-color: var(--primary); box-shadow: 0 0 0 3px color-mix(in srgb, var(--primary) 22%, transparent); }
.province-tabs { display: flex; gap: 6px; overflow-x: auto; scrollbar-width: none; margin-block: 16px 6px; padding-bottom: 4px; }
.province-tabs::-webkit-scrollbar { display: none; }
.tab { flex: none; height: 40px; padding: 0 15px; border-radius: 999px; border: 1px solid var(--line); background: transparent; font-size: 14.5px; color: var(--text-muted); }
.tab:hover { color: var(--text); border-color: var(--text-muted); }
.tab.active { background: var(--ink); border-color: var(--ink); color: #fff; }
:root[data-theme="dark"] .tab.active { background: var(--primary); border-color: var(--primary); color: #04122b; }
.city-group { padding-block: 20px; border-bottom: 1px solid var(--line); }
.city-group:last-child { border-bottom: 0; }
.city-group h3 { margin: 0 0 12px; display: flex; align-items: baseline; gap: 10px; font-size: 18px; font-weight: 800; }
.city-group h3 a:hover { color: var(--primary-2); }
.city-group h3 span { font-size: 13px; font-weight: 400; color: var(--text-muted); }
@media (max-width: 640px) { .sky-mini .sky-body { padding-block: 22px 30px; } .sky-mini .sky-orb { display: none; } }

/* ---------- برنامک: نصب، پیام‌ها، قطع اینترنت ---------- */
.tool .note { margin-top: 10px; }
.btn:disabled { opacity: .7; cursor: default; }
.pwa-toast, .net-pill { position: fixed; inset-inline: 16px; bottom: calc(16px + env(safe-area-inset-bottom)); z-index: 90; margin-inline: auto; width: fit-content; max-width: calc(100vw - 32px); display: flex; align-items: center; gap: 12px; padding: 10px 16px; border-radius: var(--r-md); background: #0b1c40; color: #fff; font-size: 14px; box-shadow: 0 18px 40px rgba(7, 18, 44, .35); }
.pwa-toast .btn { min-height: 36px; padding: 0 14px; background: #fff; border-color: #fff; color: #0b1c40; font-size: 13.5px; }
.net-pill { bottom: auto; top: calc(12px + env(safe-area-inset-top)); background: #8a3b00; }
.pwa-bar { position: fixed; inset-inline: 16px; bottom: calc(16px + env(safe-area-inset-bottom)); z-index: 80; margin-inline: auto; max-width: 560px; display: grid; grid-template-columns: 44px minmax(0, 1fr) auto auto; align-items: center; gap: 12px; padding: 12px 14px; border-radius: 18px; background: var(--surface); color: var(--text); border: 1px solid var(--line); box-shadow: 0 24px 50px rgba(7, 18, 44, .28); }
.pwa-bar img { border-radius: 10px; }
.pwa-bar b { display: block; font-size: 15px; font-weight: 800; }
.pwa-bar small { display: block; font-size: 12.5px; color: var(--text-muted); line-height: 1.7; }
.pwa-bar .btn { min-height: 40px; }
.offline-page { min-height: 100vh; display: grid; align-content: center; justify-items: center; text-align: center; gap: 14px; padding-block: 48px; }
.offline-page h1 { font-size: 30px; font-weight: 800; }
.offline-page p { max-width: 46ch; color: var(--text-muted); }
.offline-actions { display: flex; gap: 10px; flex-wrap: wrap; justify-content: center; }
@media (max-width: 560px) {
  .pwa-bar { grid-template-columns: 44px minmax(0, 1fr); }
  .pwa-bar .btn { grid-column: 1 / -1; }
  .pwa-bar .link-btn { grid-column: 1 / -1; justify-self: center; }
}

/* ---------- آب و هوای ماه‌های سال و پرسش‌های پرتکرار (صفحهٔ شهر) ---------- */
.clim, .faq { margin-top: 28px; }
.clim h2, .faq h2 { font-size: 19px; margin: 0 0 8px; }
.clim-scroll { overflow-x: auto; margin-top: 14px; border: 1px solid var(--line); border-radius: 14px; }
.clim-table { width: 100%; min-width: 460px; border-collapse: collapse; font-size: 14px; font-variant-numeric: tabular-nums; }
.clim-table th, .clim-table td { padding: 9px 12px; text-align: center; border-bottom: 1px solid var(--line); white-space: nowrap; }
.clim-table tbody tr:last-child th, .clim-table tbody tr:last-child td { border-bottom: 0; }
.clim-table thead th { font-size: 12.5px; font-weight: 600; color: var(--text-muted); white-space: normal; }
.clim-table tbody th { text-align: start; font-weight: 600; color: var(--text); }
.clim-table small { font-weight: 400; font-size: 12px; color: var(--text-muted); margin-inline-start: 4px; }
.clim-table td { color: var(--text); }
.faq details { border-bottom: 1px solid var(--line); }
.faq summary { cursor: pointer; padding: 13px 0; font-weight: 600; color: var(--text); }
.faq summary:focus-visible { outline: 2px solid var(--primary-2); outline-offset: 2px; border-radius: 6px; }
.faq details p { margin: 0 0 14px; max-width: 70ch; color: var(--text-muted); }
.top-label { margin: 18px 0 10px; font-size: 14px; font-weight: 600; color: var(--text-muted); }
.top-label:first-of-type { margin-top: 0; }

/* ---------- پرچم، رتبه‌بندی و مقایسه (۳.۰.۵) ---------- */
:root { --hot: #c8430a; --cold: #1766c9; --wet: #0e7f8c; --gust: #5b6478; }
:root[data-theme="dark"] { --hot: #ff9a5c; --cold: #7db8ff; --wet: #5fd0dc; --gust: #aab6cf; }
.flag { flex: none; inline-size: 28px; block-size: 21px; object-fit: contain; filter: drop-shadow(0 0 .7px rgba(8, 20, 48, .55)); }
.flag[width="24"] { inline-size: 24px; block-size: 18px; }
.flag[width="48"] { inline-size: 48px; block-size: 36px; filter: drop-shadow(0 2px 6px rgba(4, 12, 32, .35)); }
.city-group h3 { align-items: center; }
.city.has-flag { display: inline-flex; align-items: center; gap: 8px; padding-inline-start: 11px; }
.sky-place.has-flag { display: flex; align-items: center; gap: 16px; flex-wrap: wrap; }
.city-facts li .flag { margin-inline-end: 6px; vertical-align: -3px; }
.city-cmp { margin-top: 16px; }

.rk-cols { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px 56px; }
.rk-cols + .rk-cols, .rk-more + .rk-cols { margin-top: 26px; }
.rk-col h3 { margin: 0 0 4px; font-size: 16px; font-weight: 800; color: var(--tone); }
.rk-col.is-hot { --tone: var(--hot); }
.rk-col.is-cold { --tone: var(--cold); }
.rk-col.is-rain { --tone: var(--wet); }
.rk-col.is-wind { --tone: var(--gust); }
.rk-list { margin: 0; padding: 0; list-style: none; min-block-size: 64px; }
.rank:not(.is-ready):not(.is-failed) .rk-list { background: repeating-linear-gradient(to bottom, var(--bg-2) 0 46px, transparent 46px 64px); border-radius: var(--r-sm); min-block-size: 320px; opacity: .7; }
.rank.is-failed .rk-cols, .rank.is-failed .rk-more { display: none; }
.rk-list a { position: relative; display: grid; grid-template-columns: 26px 28px minmax(0, 1fr) auto; align-items: center; gap: 12px; min-block-size: 64px; padding-block: 9px 12px; border-bottom: 1px solid var(--line); }
.rk-n { font-size: 14px; font-weight: 700; color: var(--text-muted); text-align: center; }
.rk-name { display: flex; flex-direction: column; line-height: 1.55; min-inline-size: 0; }
.rk-name b { font-size: 16.5px; font-weight: 700; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.rk-name small { font-size: 12.5px; color: var(--text-muted); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.rk-val { font-size: 24px; font-weight: 800; letter-spacing: -.02em; color: var(--tone); white-space: nowrap; }
.rk-col.is-rain .rk-val, .rk-col.is-wind .rk-val { font-size: 15px; letter-spacing: 0; }
.rk-bar { position: absolute; inset-block-end: -1px; inset-inline-start: 0; block-size: 3px; border-radius: 3px; background: var(--tone); opacity: .8; }
.rk-list a:hover .rk-name b { color: var(--primary-2); }
.rk-main .rk-list li:nth-child(n+6) { display: none; }
.rank.is-long .rk-main .rk-list li:nth-child(n+6) { display: block; }
.rank:not(.is-long) .rk-extra { display: none; }
.rk-more { margin: 10px 0 0; }
.rank:not(.is-ready) .rk-more { visibility: hidden; }

.cmp-form { display: grid; grid-template-columns: minmax(0, 1fr) 44px minmax(0, 1fr) auto; align-items: end; gap: 12px; max-inline-size: 860px; }
.cmp-field label { display: block; margin-bottom: 4px; font-size: 13.5px; font-weight: 600; color: var(--tone); }
.cmp-field input { inline-size: 100%; block-size: 50px; padding-inline: 18px; border-radius: 999px; border: 1px solid var(--line); border-block-end: 3px solid var(--tone); background: var(--surface); font-size: 16px; font-weight: 600; }
.cmp-field input:focus { outline: 0; border-color: var(--tone); box-shadow: 0 0 0 3px color-mix(in srgb, var(--tone) 22%, transparent); }
.is-a { --tone: var(--primary-2); }
.is-b { --tone: var(--hot); }
.cmp-swap { inline-size: 44px; block-size: 50px; display: grid; place-items: center; border-radius: 999px; border: 1px solid var(--line); background: var(--surface); color: var(--text-muted); }
.cmp-swap:hover { border-color: var(--primary); color: var(--primary-2); }
.cmp-form .btn { min-height: 50px; background: var(--ink); border-color: var(--ink); color: #fff; }
:root[data-theme="dark"] .cmp-form .btn { background: var(--primary); border-color: var(--primary); color: #04122b; }
.cmp-quick { grid-column: 1 / -1; display: flex; flex-wrap: wrap; align-items: center; gap: 8px; margin-top: 6px; }
.cmp-quick > span { font-size: 13.5px; color: var(--text-muted); }
.cmp-quick .city { font: inherit; font-size: 13.5px; padding: 5px 13px; cursor: pointer; }
.cmp-msg { min-block-size: 1.8em; margin: 14px 0 0; font-size: 14px; color: var(--text-muted); }
.cmp-msg.is-bad { color: var(--bad); }
.cmp-out[aria-busy="true"] { opacity: .5; }
.cmp-verdict { margin: 6px 0 20px; font-size: clamp(20px, 2.6vw, 28px); font-weight: 800; line-height: 1.6; letter-spacing: -.01em; }
.cmp-heads { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0; border-block: 1px solid var(--line); }
.cmp-city { padding: 22px 0; padding-inline-start: 20px; border-inline-start: 4px solid var(--tone); }
.cmp-city + .cmp-city { margin-inline-start: 20px; }
.cmp-where { display: flex; align-items: center; gap: 8px; margin: 0; font-size: 13.5px; color: var(--text-muted); }
.cmp-city h2 { margin: 2px 0 0; font-size: 24px; font-weight: 800; }
.cmp-city h2 a:hover { color: var(--primary-2); }
.cmp-temp { margin: 0; font-size: clamp(54px, 9vw, 92px); font-weight: 800; line-height: 1.15; letter-spacing: -.04em; color: var(--tone); }
.cmp-desc { margin: 0; font-size: 17px; font-weight: 600; }
.cmp-clock { margin: 4px 0 0; font-size: 13.5px; color: var(--text-muted); }
.cmp-table { inline-size: 100%; margin-top: 8px; border-collapse: collapse; table-layout: fixed; }
.cmp-table thead th { padding: 14px 0 6px; font-size: 14px; font-weight: 800; color: var(--tone); }
.cmp-table tbody tr { border-bottom: 1px solid var(--line); }
.cmp-table tbody th { inline-size: 34%; padding: 13px 8px; font-size: 13.5px; font-weight: 500; color: var(--text-muted); text-align: center; }
.cmp-table td { padding: 13px 0; font-size: 16.5px; font-weight: 700; }
.cmp-table .is-a { text-align: start; }
.cmp-table .is-b { text-align: end; }
.cmp-chart { margin: 30px 0 0; }
.cmp-chart figcaption { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 18px; margin-bottom: 6px; }
.cmp-chart figcaption b { font-size: 18px; font-weight: 800; margin-inline-end: auto; }
.cmp-key { display: inline-flex; align-items: center; gap: 7px; font-size: 13.5px; font-weight: 600; }
.cmp-key::before { content: ""; inline-size: 18px; block-size: 4px; border-radius: 4px; background: var(--tone); }
.cmp-chart svg { display: block; inline-size: 100%; block-size: auto; direction: ltr; }
.cmp-line { fill: none; stroke: var(--tone); stroke-width: 3; stroke-linecap: round; stroke-linejoin: round; }
.cmp-chart circle { fill: var(--bg); stroke: var(--tone); stroke-width: 3; }
.cmp-v { fill: var(--tone); font-size: 15px; font-weight: 800; }
.cmp-day { fill: var(--text-muted); font-size: 13.5px; }
.cmp-base { stroke: var(--line); stroke-width: 1; }
.cmp-links { display: flex; flex-wrap: wrap; gap: 8px 28px; margin: 22px 0 0; }
.cmp-foot { margin: 14px 0 0; }
@media (max-width: 760px) {
  .rk-cols { grid-template-columns: minmax(0, 1fr); gap: 26px; }
  .cmp-form { grid-template-columns: minmax(0, 1fr) 44px; }
  .cmp-field.is-a { grid-column: 1; grid-row: 1; }
  .cmp-field.is-b { grid-column: 1; grid-row: 2; }
  .cmp-swap { grid-column: 2; grid-row: 1 / span 2; align-self: center; margin-top: 20px; }
  .cmp-form .btn { grid-column: 1 / -1; }
  .cmp-city { padding: 16px 0; padding-inline-start: 12px; }
  .cmp-city + .cmp-city { margin-inline-start: 12px; }
  .cmp-city h2 { font-size: 20px; }
  .cmp-table td { font-size: 14.5px; }
  .cmp-table tbody th { font-size: 12.5px; padding-inline: 4px; }
  .cmp-v { font-size: 20px; }
  .cmp-day { font-size: 19px; }
}

/* کشورها: کارت پرچم‌دار، گروه‌بندی قاره‌ای */
.ct-nav { margin-block: 16px 4px; }
.ct-nav .city span { margin-inline-start: 4px; font-size: 12.5px; color: var(--text-muted); }
.ct-hits { margin-block: 14px 0; }
.ct-group { padding-block: 22px 6px; scroll-margin-top: 16px; }
.ct-group summary { display: flex; align-items: center; justify-content: space-between; gap: 12px; cursor: pointer; list-style: none; margin-bottom: 12px; }
.ct-group summary::-webkit-details-marker { display: none; }
.ct-group summary::after { content: ""; inline-size: 9px; block-size: 9px; margin-inline-end: 6px; border-inline-end: 2px solid var(--text-muted); border-block-end: 2px solid var(--text-muted); transform: rotate(45deg); transition: transform .15s; }
.ct-group[open] summary::after { transform: rotate(-135deg); }
.ct-group:not([open]) { padding-block: 14px 2px; border-bottom: 1px solid var(--line); }
.ct-group h3 { margin: 0; display: flex; align-items: baseline; gap: 10px; font-size: 18px; font-weight: 800; }
.ct-group h3 span { font-size: 13px; font-weight: 400; color: var(--text-muted); }
.ct-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(210px, 1fr)); gap: 10px; }
.ct-card { display: flex; align-items: center; gap: 12px; min-block-size: 62px; padding: 9px 14px; border-radius: var(--r-md); border: 1px solid var(--line); background: var(--surface); }
.ct-card .flag { inline-size: 36px; block-size: 27px; }
.ct-card > span { display: flex; flex-direction: column; min-inline-size: 0; line-height: 1.55; }
.ct-card b { font-size: 15.5px; font-weight: 700; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.ct-card small { font-size: 12px; color: var(--text-muted); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.ct-card:hover { border-color: var(--primary); }
.ct-card:hover b { color: var(--primary-2); }
@media (max-width: 520px) { .ct-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; } .ct-card { padding: 8px 10px; gap: 9px; } .ct-card .flag { inline-size: 30px; block-size: 22px; } }
