/* ==========================================================================
   Weather Hill — World dashboard (desktop)
   Page chrome follows [data-theme] on <html>; each tile follows its own
   location's day/night through [data-theme] on the tile.
   ========================================================================== */

:root {
  --page: #dfe6ee;
  --panel: rgba(255, 255, 255, 0.82);
  --panel-solid: #f8fafc;
  --text: #0f172a;
  --text-2: #475569;
  --line: rgba(15, 23, 42, 0.1);
  --accent: #0b6bcb;
  --accent-ink: #fff;
  --ink: #1e293b;
  --holiday: #d23b3b;
  --temp: #e0602a; --temp-2: #c98a5a; --precip: #2f7fd9; --night: rgba(40, 60, 110, 0.08);
  --shadow: 0 8px 28px rgba(15, 23, 42, 0.14);
  --glass: rgba(248, 250, 253, 0.74);
  --glass-border: rgba(255, 255, 255, 0.6);
  --font-head: 'Outfit', 'Inter', system-ui, sans-serif;
  --font-body: 'Inter', system-ui, -apple-system, 'Segoe UI', Roboto, sans-serif;
  --font-fa: 'Vazirmatn', 'Inter', system-ui, sans-serif;
  color-scheme: light;
}
:root[data-theme="dark"] {
  --page: #0b1018;
  --panel: rgba(17, 23, 34, 0.86);
  --panel-solid: #121924;
  --text: #e8eef6;
  --text-2: #a7b4c6;
  --line: rgba(255, 255, 255, 0.1);
  --accent: #7cb4ff;
  --accent-ink: #0b1220;
  --ink: #dbe4f0;
  --holiday: #ff7a7a;
  --temp: #ff9a62; --temp-2: #c99a7a; --precip: #6fb3ff; --night: rgba(140, 170, 255, 0.08);
  --shadow: 0 8px 28px rgba(0, 0, 0, 0.45);
  color-scheme: dark;
}
/* per-tile glass follows the tile's own day/night */
.tile { --glass: rgba(248, 250, 253, 0.74); --glass-border: rgba(255, 255, 255, 0.6); --g-text: #0f172a; --g-text-2: #475569; --ink: #1e293b; }
.tile[data-theme="dark"] { --glass: rgba(12, 17, 27, 0.62); --glass-border: rgba(255, 255, 255, 0.12); --g-text: #e8eef6; --g-text-2: #b3c0d2; --ink: #dbe4f0; }

* { box-sizing: border-box; }
html, body { margin: 0; height: 100%; }
body { background: var(--page); color: var(--text); font: 14px/1.45 var(--font-body); overflow: hidden; transition: background-color 0.5s; }
#gl { position: fixed; inset: 0; width: 100vw; height: 100vh; z-index: 0; pointer-events: none; }
a { color: var(--accent); }
h1, h2, h3 { font-family: var(--font-head); margin: 0; line-height: 1.2; }
.muted { color: var(--text-2); }
.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(--accent); outline-offset: 2px; }
.icon { width: 1.3em; height: 1.3em; vertical-align: -0.28em; flex: none; overflow: visible; }
[lang="fa"] { font-family: var(--font-fa); }

/* ---------- top bar ---------- */
.topbar { position: relative; z-index: 3; height: 52px; display: flex; align-items: center; gap: 16px; padding: 0 16px; }
.brand { font-size: 1.15rem; font-weight: 600; }
.brand span { color: var(--text-2); font-weight: 400; }
.settings-wrap { position: relative; }
.icon-btn { width: 40px; height: 40px; display: grid; place-items: center; border: 0; border-radius: 50%; background: transparent; color: var(--text); cursor: pointer; padding: 0; }
.icon-btn:hover { background: var(--line); }
.icon-btn .icon { width: 24px; height: 24px; vertical-align: 0; }
.panel { background: var(--panel); border: 1px solid var(--line); border-radius: 16px; box-shadow: var(--shadow); color: var(--text); -webkit-backdrop-filter: blur(16px); backdrop-filter: blur(16px); }
.settings { position: absolute; right: 0; top: 46px; width: 330px; padding: 14px; z-index: 20; }
.settings form { display: grid; gap: 10px; }
fieldset { border: 0; margin: 0; padding: 0; display: grid; grid-template-columns: 64px 1fr; align-items: center; gap: 8px; }
legend { float: left; padding: 0; font-weight: 600; font-size: 0.85rem; }
.seg { display: inline-flex; flex-wrap: wrap; background: var(--line); border-radius: 999px; padding: 3px; gap: 2px; }
.seg input { position: absolute; opacity: 0; pointer-events: none; }
.seg label { padding: 4px 11px; border-radius: 999px; cursor: pointer; font-size: 0.84rem; }
.seg input:checked + label { background: var(--accent); color: var(--accent-ink); }
.seg input:focus-visible + label { outline: 3px solid var(--accent); outline-offset: 1px; }

/* ---------- board: 5 tiles + calendar ---------- */
.board {
  position: relative; z-index: 1;
  height: calc(100vh - 52px - 26px);
  display: grid; grid-template-columns: repeat(3, 1fr); grid-template-rows: repeat(2, 1fr);
  gap: 12px; padding: 0 12px;
}
.tile { position: relative; overflow: hidden; border-radius: 16px; color: var(--g-text); min-height: 0; }
/* paint the page colour into the corners so the square WebGL viewport looks rounded */
.tile::after { content: ''; position: absolute; inset: 0; border-radius: 16px; box-shadow: 0 0 0 24px var(--page); pointer-events: none; z-index: 4; }
.tile-view { position: absolute; inset: 0; touch-action: none; cursor: grab; }
.tile-view:active { cursor: grabbing; }
.glass {
  background: var(--glass); border: 1px solid var(--glass-border); color: var(--g-text);
  -webkit-backdrop-filter: blur(14px) saturate(150%); backdrop-filter: blur(14px) saturate(150%);
  box-shadow: 0 6px 22px rgba(15, 23, 42, 0.16); transition: background-color 0.6s, color 0.6s;
}
.tile-top { position: absolute; top: 10px; left: 10px; right: 10px; display: flex; justify-content: space-between; align-items: flex-start; gap: 8px; z-index: 2; pointer-events: none; }
.tile-top > *, .tile-bottom > * { pointer-events: auto; }
.tile-place { border-radius: 14px; padding: 6px 12px 7px; max-width: 62%; position: relative; }
.place-btn { display: flex; align-items: center; gap: 4px; border: 0; background: none; color: inherit; font: 600 1.15rem var(--font-head); padding: 0; cursor: pointer; max-width: 100%; }
.place-name { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.place-btn .chev { width: 16px; height: 16px; opacity: 0.6; flex: none; }
.place-btn:hover .chev { opacity: 1; }
.place-sub { display: block; font-size: 0.76rem; color: var(--g-text-2); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.place-search input { width: 230px; font: inherit; color: var(--g-text); background: transparent; border: 1px solid var(--glass-border); border-radius: 10px; padding: 6px 10px; }
.search-list { position: absolute; left: 0; top: calc(100% + 6px); width: 300px; margin: 0; padding: 5px; list-style: none; border-radius: 12px; max-height: 260px; overflow: auto; z-index: 30; background: var(--panel-solid); color: var(--text); }
.search-list li { padding: 7px 9px; border-radius: 8px; cursor: pointer; }
.search-list li[aria-selected="true"], .search-list li:hover { background: var(--line); }
.search-list li.empty { cursor: default; }
.opt-name { font-weight: 600; }
.tile-clock { border-radius: 14px; padding: 5px 12px 6px; text-align: right; }
.clock-time { display: block; font: 300 1.75rem/1.05 var(--font-head); font-variant-numeric: tabular-nums; letter-spacing: -0.5px; }
.clock-date { font-size: 0.76rem; color: var(--g-text-2); white-space: nowrap; }
.tile-bottom { position: absolute; left: 10px; right: 10px; bottom: 10px; display: flex; justify-content: space-between; align-items: flex-end; gap: 8px; z-index: 2; pointer-events: none; }
.tile-wx { border-radius: 14px; padding: 8px 12px; min-width: 0; }
.wx-main { display: flex; align-items: center; gap: 8px; }
.wx-main .icon { width: 40px; height: 40px; }
.wx-temp { font: 300 2.1rem/1 var(--font-head); }
.wx-cond { display: flex; flex-direction: column; font-size: 0.8rem; min-width: 0; }
.wx-cond strong { font-size: 0.9rem; }
.wx-cond span { color: var(--g-text-2); white-space: nowrap; }
.wx-chips { display: flex; gap: 10px; margin-top: 4px; font-size: 0.78rem; color: var(--g-text-2); flex-wrap: wrap; }
.wx-chips .icon { width: 16px; height: 16px; }
.wx-chips .stale { color: #c98a1e; }
.tile-more { border-radius: 999px; padding: 8px 14px; font: 600 0.82rem var(--font-body); cursor: pointer; min-height: 36px; }
.tile-more:hover { filter: brightness(1.08); }

/* ---------- calendar ---------- */
.calendar { padding: 12px 14px; display: flex; flex-direction: column; min-height: 0; overflow: hidden; container-type: size; }
/* two fixed halves: month on the right, upcoming events on the left (stacked when the panel is taller than wide) */
.cal-body { flex: 1; min-height: 0; display: grid; grid-template-columns: 1fr 1fr; grid-template-rows: minmax(0, 1fr); gap: 14px; margin-top: 8px; }
.cal-head { display: flex; align-items: center; gap: 8px; }
.cal-title { flex: 1; min-width: 0; }
.cal-month { font: 700 1.35rem var(--font-fa); text-align: right; }
.cal-sub { margin: 0; font-size: 0.78rem; color: var(--text-2); text-align: right; }
.cal-head { flex-direction: row-reverse; }
.cal-nav { display: flex; gap: 4px; }
.cal-btn { min-width: 32px; height: 32px; border: 1px solid var(--line); border-radius: 9px; background: transparent; color: var(--text); cursor: pointer; font-size: 1.1rem; }
.cal-btn.text { font-size: 0.8rem; padding: 0 10px; }
.cal-btn:hover { background: var(--line); }
.cal-add { height: 32px; border: 0; border-radius: 9px; background: var(--accent); color: var(--accent-ink); font-weight: 600; padding: 0 12px; cursor: pointer; }
.cal-grid { grid-area: 1 / 2; min-height: 0; display: grid; grid-template-columns: repeat(7, 1fr); gap: 3px; }
.wd { text-align: center; font: 600 0.8rem var(--font-fa); color: var(--text-2); padding-bottom: 2px; }
.wd.fri { color: var(--holiday); }
.cday {
  position: relative; border: 1px solid transparent; border-radius: 9px; background: var(--line); color: var(--text);
  display: grid; grid-template-columns: 1fr auto; grid-template-rows: 1fr auto; align-items: center; column-gap: 4px; direction: rtl;
  padding: 2px 6px 3px; cursor: pointer; min-height: 0; overflow: hidden; font: inherit; text-align: right;
}
.cday:hover { border-color: var(--accent); }
.cday .pd { grid-area: 1 / 1; font: 600 1.05rem/1.1 var(--font-fa); }
.cday .gd { grid-area: 1 / 2; align-self: start; padding-top: 2px; font-size: 0.68rem; line-height: 1; color: var(--text-2); text-align: left; direction: ltr; white-space: nowrap; }
.cday .dots { grid-area: 2 / 1 / 3 / 3; display: flex; justify-content: center; gap: 2px; height: 5px; }
.cday .dots i { display: block; width: 5px; height: 5px; border-radius: 50%; }
.cday.today .dots i { box-shadow: 0 0 0 1.5px var(--accent-ink); }
.cal-upcoming i, .ev > i { display: inline-block; width: 7px; height: 7px; border-radius: 50%; }
.cday.other { opacity: 0.38; }
.cday.holiday .pd { color: var(--holiday); }
.cday.today { background: var(--accent); }
.cday.today .pd, .cday.today .gd { color: var(--accent-ink); }
.cal-foot { grid-area: 1 / 1; min-height: 0; display: flex; flex-direction: column; border-right: 1px solid var(--line); padding-right: 12px; }
/* too narrow for both day numbers in a cell: keep the Persian one */
@container (orientation: landscape) and (max-width: 560px) { .cday .gd { display: none; } }
@container (orientation: portrait) and (max-width: 300px) { .cday .gd { display: none; } }
@container (orientation: portrait) {
  .cal-body { grid-template-columns: minmax(0, 1fr); grid-template-rows: minmax(0, 1fr) minmax(0, 1fr); }
  .cal-grid { grid-area: 1 / 1; }
  .cal-foot { grid-area: 2 / 1; border-right: 0; padding-right: 0; border-top: 1px solid var(--line); padding-top: 8px; }
}
.cal-foot h3 { font-size: 0.85rem; margin-bottom: 4px; }
.cal-upcoming { flex: 1; min-height: 0; overflow-y: auto; list-style: none; margin: 0; padding: 0; display: grid; align-content: start; gap: 2px; }
.cal-upcoming .up { width: 100%; display: grid; grid-template-columns: 8px minmax(0, 1fr); grid-template-rows: auto auto; align-items: center; column-gap: 8px; border: 0; background: none; color: var(--text); font: inherit; font-size: 0.8rem; text-align: left; padding: 3px 4px; border-radius: 6px; cursor: pointer; }
.cal-upcoming .up:hover { background: var(--line); }
.cal-upcoming .up > i { grid-row: 1 / 3; }
.up-title { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; text-align: left; }
.up-meta { font-size: 0.72rem; color: var(--text-2); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.cal-store { margin: 4px 0 0; font-size: 0.72rem; }
.cal-sync { font-style: normal; }
.cal-sync .link { font-size: inherit; padding: 0 2px; }
.cal-err { color: var(--holiday); }

/* ---------- dialogs ---------- */
dialog { padding: 0; color: var(--text); }
dialog::backdrop { background: rgba(5, 10, 20, 0.45); -webkit-backdrop-filter: blur(3px); backdrop-filter: blur(3px); }
.dlg-head { display: flex; justify-content: space-between; align-items: flex-start; gap: 12px; padding: 16px 18px 8px; }
.dlg-head h2 { font-size: 1.35rem; }
.dlg-head p { margin: 2px 0 0; font-size: 0.85rem; }
.detail { width: min(1100px, 94vw); max-height: 90vh; background: var(--panel-solid); }
.dlg-body { padding: 4px 18px 18px; overflow: auto; max-height: calc(90vh - 70px); display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
.card { background: var(--line); border-radius: 14px; padding: 12px 14px; min-width: 0; }
.card.wide { grid-column: 1 / -1; }
.card h2 { font-size: 1rem; margin-bottom: 8px; }
.now-head .loc { font-size: 1.2rem; }
.now-head p { margin: 2px 0 0; font-size: 0.82rem; color: var(--text-2); }
.now-main { display: flex; align-items: center; gap: 12px; margin-top: 6px; }
.now-icon .icon { width: 56px; height: 56px; }
.now-temp { font: 300 3rem/1 var(--font-head); }
.now-temp small { font-size: 1.1rem; vertical-align: top; color: var(--text-2); }
.now-meta p { margin: 1px 0; }
.now-meta .cond { font-weight: 600; }
.highlights { list-style: none; margin: 0; padding: 0; display: grid; gap: 5px; }
.hl { display: flex; align-items: center; gap: 8px; padding: 5px 9px; border-radius: 9px; background: var(--panel-solid); border-left: 3px solid var(--line); }
.hl .icon { width: 22px; height: 22px; }
.hl.warn { border-left-color: #f0a020; } .hl.alert { border-left-color: #e5484d; }
.chart-wrap { position: relative; }
#chart { width: 100%; height: 180px; display: block; }
.chart-tip { position: absolute; top: 4px; pointer-events: none; font-size: 0.8rem; background: var(--panel-solid); border: 1px solid var(--line); border-radius: 8px; padding: 5px 8px; white-space: nowrap; }
table { border-collapse: collapse; width: 100%; font-variant-numeric: tabular-nums; }
.kv th, .kv td { padding: 5px 4px; border-bottom: 1px solid var(--line); text-align: left; }
.kv th { font-weight: 500; color: var(--text-2); }
.kv th .icon { width: 20px; height: 20px; margin-right: 4px; vertical-align: -5px; }
.kv.three th { width: auto; }
.scroll { overflow-x: auto; }
.card .grid { width: max-content; min-width: 100%; }
.card .grid th, .card .grid td { padding: 5px 8px; text-align: center; white-space: nowrap; border-bottom: 1px solid var(--line); }
.card .grid thead th { font-size: 0.76rem; color: var(--text-2); }
.card .grid tbody th { text-align: left; color: var(--text-2); font-weight: 500; }
.card .grid .sticky { position: sticky; left: 0; background: var(--panel-solid); }
.card .grid .day { display: block; font-size: 0.7rem; color: var(--accent); }
.card .grid .ico .icon { width: 28px; height: 28px; }
.card .grid .left { text-align: left; }
.card .grid .hi { color: var(--precip); font-weight: 650; }
.chip { display: inline-block; padding: 1px 8px; border-radius: 999px; font-size: 0.76rem; font-weight: 600; margin-left: 4px; }
.lv-1 { background: #7fd67f; color: #0d2a0d; } .lv-2 { background: #d9e86a; color: #2a2c05; } .lv-3 { background: #ffd24d; color: #3a2a00; }
.lv-4 { background: #ff9a4d; color: #3a1500; } .lv-5 { background: #f0605d; color: #fff; } .lv-6 { background: #a64ac9; color: #fff; }
.uvnum { display: inline-block; min-width: 22px; border-radius: 6px; padding: 0 4px; }
.arrow { display: inline-block; color: var(--accent); font-weight: 700; }
.trend { color: var(--text-2); margin-left: 4px; }

.day-dialog { width: min(560px, 94vw); background: var(--panel-solid); }
.day-dialog > h3, .day-dialog > ul, .day-dialog > form { margin-left: 18px; margin-right: 18px; }
.dd-fa { font: 700 1.4rem var(--font-fa); }
.dd-hol { list-style: none; padding: 0; color: var(--holiday); font-size: 0.88rem; margin-top: 0; }
.day-dialog h3 { font-size: 0.95rem; margin-top: 10px; margin-bottom: 6px; }
.dd-events { list-style: none; padding: 0; display: grid; gap: 6px; }
.ev { display: grid; grid-template-columns: 10px 1fr auto auto; gap: 10px; align-items: start; padding: 8px 10px; border-radius: 10px; background: var(--line); }
.ev > i { margin-top: 6px; }
.ev-body { display: flex; flex-direction: column; }
.ev-body p { margin: 2px 0 0; font-size: 0.85rem; }
.link { border: 0; background: none; color: var(--accent); cursor: pointer; font: inherit; padding: 2px 4px; }
.link.danger { color: var(--holiday); }
.dd-form { display: grid; gap: 8px; padding-bottom: 18px; }
.dd-form label { display: grid; gap: 3px; font-size: 0.82rem; color: var(--text-2); }
.dd-form input, .dd-form textarea, .dd-form select { font: inherit; color: var(--text); background: var(--page); border: 1px solid var(--line); border-radius: 8px; padding: 7px 9px; }
.row3 { display: grid; grid-template-columns: 1.4fr 1fr 1fr; gap: 8px; }
.form-actions { display: flex; justify-content: flex-end; gap: 8px; }
.btn { border: 1px solid var(--line); background: transparent; color: var(--text); border-radius: 10px; padding: 8px 14px; font: 600 0.88rem var(--font-body); cursor: pointer; }
.btn.primary { background: var(--accent); color: var(--accent-ink); border-color: transparent; }

.attribution { position: relative; z-index: 1; height: 26px; margin: 0; display: flex; justify-content: center; align-items: center; gap: 4px; white-space: nowrap; font-size: 0.72rem; color: var(--text-2); }
.attribution a { color: var(--text-2); }

/* ---------- rendering mode toggle ---------- */
.seg.mode { margin-left: auto; }

/* ---------- 2D lite mode ---------- */
.tile-flat { display: none; }
body[data-mode="2d"] #gl, body[data-mode="2d"] .tile-view { display: none; }
body[data-mode="2d"] .tile-flat { display: block; position: absolute; inset: 0; }
body[data-mode="2d"] .tile::after { display: none; }
.tile-flat svg { display: block; width: 100%; height: 100%; }
/* lighter glass in 2D: no backdrop blur to repaint */
body[data-mode="2d"] .glass { -webkit-backdrop-filter: none; backdrop-filter: none; }
body[data-mode="2d"] .tile { --glass: rgba(248, 250, 253, 0.86); }
body[data-mode="2d"] .tile[data-theme="dark"] { --glass: rgba(12, 17, 27, 0.78); }

/* photo scenes (landmark cities in 2D lite) */
.photo-scene { position: absolute; inset: 0; overflow: hidden; background: #111; }
.photo-scene img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.photo-scene .ph-tint { position: absolute; inset: 0; mix-blend-mode: multiply; pointer-events: none; }
.photo-scene svg { position: absolute; inset: 0; width: 100%; height: 100%; }
.flat .kenburns { transform-origin: 50% 60%; animation: kenburns 30s ease-in-out infinite alternate; }
@keyframes kenburns { from { transform: scale(1); } to { transform: scale(1.08); } }
.photo-credit {
  position: absolute; left: 50%; bottom: 3px; transform: translateX(-50%); z-index: 3; max-width: 60%;
  font-size: 0.62rem; color: rgba(255, 255, 255, 0.85); text-decoration: none; white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.8);
}
.photo-credit:hover { text-decoration: underline; color: #fff; }
body[data-mode="2d"] .tile-bottom { bottom: 18px; }

/* every moving part is paused until the tile is hovered or focused → idle CPU ≈ 0 */
/* (selectors are more specific than the `animation:` shorthands below, which would reset play-state) */
.tile .flat .anim { animation-play-state: paused; }
.tile:hover .flat .anim, .tile:focus-within .flat .anim { animation-play-state: running; }
.flat .drift { animation: drift 50s ease-in-out infinite alternate; }
.flat .rays, .flat .spin { transform-origin: 0 0; }
.flat .rays { animation: spin 24s linear infinite; }
.flat .spin { animation: spin 5s linear infinite; }
.flat .sway { transform-origin: 0 0; animation: sway 2.6s ease-in-out infinite alternate; }
.flat .sway-grass { transform-box: fill-box; transform-origin: 50% 100%; animation: grass 2.2s ease-in-out infinite alternate; }
.flat .fall { animation: fall 0.75s linear infinite; }
.flat .snowfall { animation: fall 7s linear infinite; }
.flat .twinkle { animation: twinkle 2.4s ease-in-out infinite alternate; }
.flat .leaf-fall { animation: leaf 5s linear infinite; }
.flat .bolt { opacity: 0; animation: bolt 5s steps(1, end) infinite; }
.flat .flash { animation: flash 5s steps(1, end) infinite; }
@keyframes drift { from { transform: translateX(-28px); } to { transform: translateX(28px); } }
@keyframes spin { to { transform: rotate(360deg); } }
@keyframes sway { from { transform: rotate(calc(var(--sway) * -0.6)); } to { transform: rotate(var(--sway)); } }
@keyframes grass { from { transform: skewX(calc(var(--sway) * -1)); } to { transform: skewX(var(--sway)); } }
@keyframes fall { to { transform: translateY(300px); } }
@keyframes twinkle { from { opacity: 0.25; } to { opacity: 1; } }
@keyframes leaf { from { transform: translate(0, 0) rotate(0); opacity: 1; } to { transform: translate(26px, 80px) rotate(540deg); opacity: 0; } }
@keyframes bolt { 0% { opacity: 0; } 70% { opacity: 1; } 73% { opacity: 0; } 76% { opacity: 1; } 80% { opacity: 0; } }
@keyframes flash { 0% { opacity: 0; } 70% { opacity: 0.45; } 73% { opacity: 0; } 76% { opacity: 0.3; } 80% { opacity: 0; } }
@media (prefers-reduced-motion: reduce) { .flat .anim { animation: none !important; } }

/* narrower desktop windows: two columns, page scrolls */
@media (max-width: 1150px) {
  body { overflow: auto; }
  .board { height: auto; grid-template-columns: repeat(2, 1fr); grid-template-rows: none; grid-auto-rows: 360px; }
  .calendar { grid-row: span 2; }
  .dlg-body { grid-template-columns: 1fr; }
}
@media (prefers-reduced-motion: reduce) { * { transition: none !important; } }
