:root {
  color-scheme: dark;
  --page: #17152f;
  --page-deep: #111024;
  --surface: #201d3c;
  --surface-raised: #272344;
  --text: #f7f4ff;
  --muted: #c0bbd4;
  --quiet: #938da9;
  --line: rgba(228, 220, 255, .13);
  --accent: #ffc06f;
  --accent-ink: #292039;
  --radius-card: 18px;
  --radius-control: 999px;
}

* { box-sizing: border-box; }
html { min-width: 320px; min-height: 100%; background: var(--page-deep); }
body {
  min-width: 320px;
  min-height: 100dvh;
  margin: 0;
  overflow-x: hidden;
  color: var(--text);
  background:
    radial-gradient(ellipse at 73% 20%, rgba(105, 78, 141, .19), transparent 38rem),
    linear-gradient(132deg, #211c43 0%, var(--page) 48%, #15132d 100%);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Microsoft YaHei", sans-serif;
  -webkit-font-smoothing: antialiased;
}
button, a { font: inherit; }
a { color: inherit; text-decoration: none; }
button { color: inherit; }
img { display: block; max-width: 100%; }
button:focus-visible, a:focus-visible { outline: 2px solid var(--accent); outline-offset: 4px; }

.page-shell { width: min(1480px, calc(100% - 72px)); min-height: 100dvh; margin: 0 auto; display: flex; flex-direction: column; }
.site-header { height: 82px; display: flex; align-items: center; justify-content: space-between; border-bottom: 1px solid var(--line); }
.brand { display: inline-flex; align-items: center; gap: 12px; }
.brand img { width: 42px; height: 42px; border: 1px solid rgba(255,255,255,.15); border-radius: 12px; box-shadow: 0 5px 18px rgba(8,7,30,.25); }
.brand-name { font-size: 16px; font-weight: 750; letter-spacing: .07em; }
.location-chip { display: inline-flex; align-items: center; gap: 10px; min-height: 46px; padding: 5px 8px 5px 13px; border: 1px solid rgba(225,218,255,.17); border-radius: var(--radius-control); background: rgba(27,24,54,.46); color: #e4dff2; font-size: 12px; }
.location-copy { display: flex; min-width: 0; flex-direction: column; gap: 2px; }
.location-copy strong { overflow: hidden; color: #eee9fa; font-size: 11px; font-weight: 650; text-overflow: ellipsis; white-space: nowrap; }
.location-copy small { color: var(--quiet); font-size: 9px; font-variant-numeric: tabular-nums; white-space: nowrap; }
.location-action { min-height: 31px; padding: 0 10px; border: 1px solid rgba(255,192,111,.45); border-radius: 9px; background: rgba(255,192,111,.17); color: #ffd39f; cursor: pointer; font-size: 10px; font-weight: 700; white-space: nowrap; }
.location-action:hover { border-color: rgba(255,192,111,.72); background: rgba(255,192,111,.23); }
.relocate-button { min-height: 31px; padding: 0 10px; border: 1px solid rgba(255,192,111,.28); border-radius: 9px; background: rgba(255,192,111,.09); color: #f0c38f; cursor: pointer; font-size: 10px; font-weight: 650; white-space: nowrap; }
.relocate-button:hover { border-color: rgba(255,192,111,.55); background: rgba(255,192,111,.15); }
.relocate-button:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
.location-pin { position: relative; width: 9px; height: 9px; border: 2px solid var(--accent); border-radius: 50%; }
.location-pin::after { position: absolute; left: 1px; bottom: -5px; width: 3px; height: 3px; content: ""; border-right: 1px solid var(--accent); border-bottom: 1px solid var(--accent); transform: rotate(45deg); }

.home-layout { flex: 1; display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: clamp(22px, 2.6vw, 40px); align-items: start; padding: 18px 0 20px; }
.brand-panel { min-width: 0; display: flex; flex-direction: column; align-items: stretch; padding: 0 4px 0 0; }
.brand-copy { max-width: 680px; }
.brand-kicker { margin: 0 0 14px; color: #d6c8e8; font-size: 11px; font-weight: 600; letter-spacing: .16em; }
.brand-copy h1 { margin: 0; font-size: clamp(27px, 2.05vw, 35px); font-weight: 720; letter-spacing: -.055em; line-height: 1.5; }
.brand-heading-accent { color: var(--accent); }
.brand-intro { max-width: 460px; margin: 14px 0 0; color: var(--muted); font-size: 13px; line-height: 1.75; }
.brand-slogan { margin: 8px 0 0; color: #ece6f7; font-size: 12px; font-weight: 600; letter-spacing: .02em; }
.mini-program-entry { display: flex; align-items: center; gap: 14px; min-height: 88px; margin-top: 15px; }
.mini-program-qr { width: 84px; height: 84px; flex: 0 0 84px; padding: 3px; border-radius: 8px; background: #fff; object-fit: contain; }
.mini-program-copy { display: grid; gap: 7px; }
.mini-program-copy strong { color: #e7e2f1; font-size: 12px; font-weight: 550; }
.mini-program-copy span { color: var(--accent); font-size: 11px; font-weight: 650; letter-spacing: .03em; }
.availability-block { margin-top: 13px; padding: 12px 0 0; border-top: 1px solid var(--line); }
.availability-row { display: grid; grid-template-columns: 82px minmax(0, 1fr); align-items: baseline; gap: 12px; padding: 5px 0; }
.availability-row + .availability-row { margin-top: 4px; padding-top: 9px; border-top: 1px solid rgba(228,220,255,.09); }
.availability-label { font-size: 11px; font-weight: 650; }
.availability-label.is-available { color: #8ed0b9; }
.availability-label.is-improving { color: var(--accent); }
.availability-row p { margin: 0; color: var(--muted); font-size: 11px; line-height: 1.55; }
.recent-updates { margin-top: 13px; padding-top: 12px; border-top: 1px solid var(--line); }
.recent-updates-heading { display: flex; align-items: baseline; justify-content: space-between; gap: 12px; margin-bottom: 7px; }
.recent-updates-heading h2 { margin: 0; color: #f0ecf8; font-size: 13px; font-weight: 650; }
.recent-updates-heading span { color: var(--quiet); font-size: 9px; letter-spacing: .13em; }
.update-item { display: grid; grid-template-columns: 65px minmax(0, 1fr); gap: 10px; padding: 5px 0; }
.update-item h3 { margin: 0; color: #c6bfd9; font-size: 10px; font-weight: 600; line-height: 1.65; }
.update-item p { margin: 0; color: var(--quiet); font-size: 10px; line-height: 1.65; }

.forecast-panel { min-width: 0; }
.sky-scene { position: relative; height: clamp(120px, 13.5vh, 150px); overflow: hidden; border: 1px solid rgba(233,225,255,.17); border-radius: 18px; isolation: isolate; background: #292443; box-shadow: 0 14px 34px rgba(10,8,31,.2); }
.sky-scene > img { position: absolute; z-index: -2; inset: 0; width: 100%; height: 100%; object-fit: cover; object-position: 50% 58%; }
.scene-shade { position: absolute; z-index: -1; inset: 0; background: linear-gradient(105deg, rgba(133,39,24,.78), rgba(207,67,39,.54) 52%, rgba(242,126,63,.36)), linear-gradient(0deg, rgba(92,28,26,.35), transparent 72%); }
.scene-copy { position: absolute; left: clamp(20px, 2.1vw, 32px); bottom: 20px; max-width: 82%; }
.scene-copy p { margin: 0 0 6px; color: #f1d9c3; font-size: 10px; letter-spacing: .08em; }
.scene-copy h2 { max-width: 540px; margin: 0; font-size: clamp(19px, 1.55vw, 24px); font-weight: 650; letter-spacing: -.04em; line-height: 1.3; text-wrap: balance; }
.scene-caption { position: absolute; right: 15px; bottom: 12px; color: rgba(249,240,240,.72); font-size: 9px; }

.version-note { display: grid; grid-template-columns: auto minmax(0, 1fr); align-items: start; gap: 10px; margin: 9px 0 0; }
.v2-test-badge { display: inline-flex; min-height: 21px; align-items: center; justify-content: center; padding: 0 8px; border: 1px solid rgba(255,192,111,.3); border-radius: var(--radius-control); background: rgba(255,192,111,.08); color: #efbd83; font-size: 10px; font-weight: 650; line-height: 1; white-space: nowrap; }
.version-note p { margin: 1px 0 0; color: #b7b1ca; font-size: 10px; line-height: 1.55; }
.forecast-toolbar { display: flex; align-items: center; justify-content: space-between; gap: 14px; margin: 9px 0 10px; }
.mode-tabs { display: inline-flex; align-items: center; gap: 5px; padding: 4px; border: 1px solid rgba(230,224,255,.12); border-radius: var(--radius-control); background: rgba(16,14,37,.48); }
.mode-tab { min-width: 78px; min-height: 34px; padding: 0 14px; border: 0; border-radius: var(--radius-control); background: transparent; color: var(--muted); cursor: pointer; font-size: 12px; font-weight: 650; transition: color .18s ease, background-color .18s ease, transform .18s ease; }
.mode-tab:hover { color: var(--text); }
.mode-tab:active { transform: scale(.97); }
.mode-tab.is-active { color: var(--accent-ink); background: var(--accent); box-shadow: 0 3px 12px rgba(255,192,111,.16); }
.toolbar-note { margin: 0; color: var(--quiet); font-size: 10px; text-align: right; }
.forecast-refresh { min-height: 34px; padding: 0 12px; border: 1px solid rgba(255,192,111,.38); border-radius: 9px; background: rgba(255,192,111,.1); color: #ffd39c; cursor: pointer; font-size: 10px; font-weight: 650; white-space: nowrap; }
.forecast-refresh:hover { background: rgba(255,192,111,.18); }
.location-prompt { grid-column: 1 / -1; display: grid; min-height: 176px; align-content: center; justify-items: center; gap: 8px; padding: 24px; border: 1px solid rgba(230,224,255,.12); border-radius: var(--radius-card); background: linear-gradient(155deg, rgba(45,41,75,.74), rgba(30,27,57,.84)); color: var(--muted); text-align: center; }
.location-prompt strong { color: #eee9fa; font-size: 15px; font-weight: 650; }
.location-prompt p { max-width: 460px; margin: 0; font-size: 11px; line-height: 1.7; }
.location-prompt .location-error-copy { color: #e7c7a7; }
.location-prompt-actions { display: flex; flex-wrap: wrap; justify-content: center; gap: 8px; margin-top: 4px; }
.location-prompt-button { min-height: 34px; padding: 0 13px; border: 1px solid rgba(230,224,255,.2); border-radius: 9px; background: rgba(255,255,255,.035); color: #e9e3f5; cursor: pointer; font-size: 11px; font-weight: 600; }
.location-prompt-button:hover { background: rgba(255,255,255,.08); }
.location-prompt-button.is-primary { border-color: rgba(255,192,111,.48); background: rgba(255,192,111,.15); color: #ffd39f; }

.visually-hidden { position: absolute; width: 1px; height: 1px; padding: 0; overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; clip-path: inset(50%); }
.location-dialog { width: min(520px, calc(100% - 28px)); max-width: none; max-height: min(82dvh, 720px); padding: 0; overflow: visible; border: 1px solid rgba(230,224,255,.18); border-radius: 20px; background: #211e3e; color: var(--text); box-shadow: 0 24px 80px rgba(5,4,20,.55); }
.location-dialog::backdrop { background: rgba(9,8,25,.72); backdrop-filter: blur(5px); }
.location-dialog-panel { max-height: min(82dvh, 720px); padding: 23px; overflow: auto; }
.location-dialog-header { display: flex; align-items: flex-start; justify-content: space-between; gap: 18px; }
.location-dialog-header h2 { margin: 0; color: #f5f0ff; font-size: 19px; font-weight: 680; letter-spacing: -.025em; }
.location-dialog-header p { margin: 7px 0 0; color: #bcb5cf; font-size: 11px; line-height: 1.6; }
.location-dialog-close { display: grid; width: 32px; height: 32px; flex: 0 0 auto; place-items: center; border: 1px solid rgba(230,224,255,.15); border-radius: 50%; background: rgba(255,255,255,.04); color: #dcd5eb; cursor: pointer; font-size: 21px; line-height: 1; }
.location-search-form { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 8px; margin-top: 19px; }
.location-search-form input { min-width: 0; min-height: 43px; padding: 0 13px; border: 1px solid rgba(230,224,255,.2); border-radius: 11px; outline: none; background: rgba(14,12,34,.64); color: var(--text); font: inherit; font-size: 13px; }
.location-search-form input::placeholder { color: #89839f; }
.location-search-form input:focus { border-color: rgba(255,192,111,.66); box-shadow: 0 0 0 3px rgba(255,192,111,.1); }
.location-search-submit { min-width: 72px; min-height: 43px; padding: 0 14px; border: 1px solid rgba(255,192,111,.48); border-radius: 11px; background: rgba(255,192,111,.17); color: #ffd39f; cursor: pointer; font-size: 12px; font-weight: 700; }
.location-search-submit:disabled { cursor: wait; opacity: .68; }
.location-search-status { min-height: 18px; margin: 12px 1px 8px; color: #b5aec8; font-size: 11px; line-height: 1.6; }
.city-reference-shortcut { display: grid; justify-items: start; gap: 6px; margin-top: 10px; }
.city-reference-shortcut p { margin: 0; color: #928aa5; font-size: 10px; line-height: 1.5; }
.location-search-results { display: grid; max-height: min(42dvh, 360px); gap: 7px; overflow: auto; }
.manual-coordinate-form { display: grid; gap: 10px; margin-top: 18px; padding: 14px; border: 1px solid rgba(230,224,255,.14); border-radius: 13px; background: rgba(14,12,34,.38); }
.manual-coordinate-form h3 { margin: 0; color: #e8e0f7; font-size: 12px; }
.manual-coordinate-fields { display: grid; grid-template-columns: repeat(2, minmax(0,1fr)); gap: 9px; }
.manual-coordinate-fields label { display: grid; gap: 5px; color: #bcb5cf; font-size: 11px; }
.manual-coordinate-fields input { width: 100%; min-width: 0; min-height: 40px; padding: 0 10px; border: 1px solid rgba(230,224,255,.2); border-radius: 9px; background: rgba(14,12,34,.64); color: var(--text); font: inherit; }
.manual-coordinate-form p { margin: 0; color: #928aa5; font-size: 10px; line-height: 1.5; }
.location-result { display: grid; gap: 4px; width: 100%; padding: 11px 13px; border: 1px solid rgba(230,224,255,.11); border-radius: 11px; background: rgba(255,255,255,.035); color: inherit; cursor: pointer; text-align: left; }
.location-result:hover, .location-result:focus-visible { border-color: rgba(255,192,111,.42); background: rgba(255,192,111,.075); }
.location-result-name { color: #f3eefc; font-size: 13px; font-weight: 650; }
.location-result-detail { color: #a7a0ba; font-size: 10px; line-height: 1.5; }
.location-attribution { margin: 14px 0 0; color: #8f89a4; font-size: 9px; line-height: 1.6; }

.day-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); grid-auto-rows: 1fr; align-items: stretch; gap: 12px; }
.day-card { position: relative; min-width: 0; min-height: 226px; padding: 14px 12px 12px; overflow: hidden; border: 1px solid rgba(230,224,255,.14); border-radius: 16px; background: linear-gradient(155deg, rgba(45,41,75,.9), rgba(30,27,57,.94)); box-shadow: 0 9px 22px rgba(8,7,28,.14); }
.day-card { display: flex; flex-direction: column; height: 100%; }
.day-card-head { display: flex; align-items: center; justify-content: space-between; gap: 6px; }
.day-label { color: var(--text); font-size: 14px; font-weight: 700; }
.day-state { color: #bcb5cf; font-size: 10px; white-space: nowrap; }
.day-card:not(.is-unavailable) .day-state::before { display: inline-block; width: 5px; height: 5px; margin: 0 6px 1px 0; border-radius: 50%; background: var(--accent); content: ""; }
.day-date { margin: 6px 0 10px; color: var(--quiet); font-size: 10px; }
.day-retrieved-at { margin: -6px 0 9px; color: #a59db6; font-size: 8px; line-height: 1.35; }
.probability-label { margin: 0; color: #d6d0e4; font-size: 11px; }
.probability { margin: 1px 0 1px -2px; color: #fff7ec; font-size: clamp(38px, 3vw, 52px); font-weight: 720; letter-spacing: -.07em; line-height: 1.08; font-variant-numeric: tabular-nums; }
.probability.is-zero { color: #d8d1e4; }
.event-time { margin: 0; color: #c3bdd3; font-size: 11px; }
.day-card-divider { height: 1px; margin: 11px 0 9px; background: rgba(226,220,247,.12); }
.day-metrics { display: grid; grid-template-columns: 1fr 1fr; gap: 7px; }
.d0-fusion-preview { display: flex; flex-wrap: wrap; align-items: baseline; justify-content: space-between; gap: 4px 8px; margin-top: 10px; padding: 8px 9px; border: 1px solid rgba(255,192,111,.2); border-radius: 9px; background: rgba(255,192,111,.055); }
.d0-fusion-preview-label { color: var(--quiet); font-size: 9px; line-height: 1.4; }
.d0-fusion-preview-value { color: #ffd39f; font-size: 12px; font-variant-numeric: tabular-nums; }
.day-metric { display: grid; gap: 5px; min-width: 0; }
.metric-label { overflow: hidden; color: var(--quiet); font-size: 10px; text-overflow: ellipsis; white-space: nowrap; }
.metric-value { color: #eee9f8; font-size: 12px; font-weight: 600; font-variant-numeric: tabular-nums; }
.day-details { grid-column: 1 / -1; min-width: 0; margin-top: 12px; border-top: 1px solid rgba(226,220,247,.12); }
.day-card > .day-details { margin-top: auto; }
.day-details > summary, .pressure-summary { width: fit-content; padding: 10px 0 2px; color: #d5cee4; cursor: pointer; font-size: 10px; font-weight: 650; list-style: none; }
.day-details > summary::-webkit-details-marker, .pressure-summary::-webkit-details-marker { display: none; }
.day-details > summary::after, .pressure-summary::after { display: inline-block; margin-left: 7px; color: var(--accent); content: "+"; }
.day-details[open] > summary::after, .pressure-details[open] > summary::after { content: "−"; }
.data-section { margin-top: 12px; }
.data-section-title { margin: 0 0 8px; color: #c9c1d9; font-size: 10px; font-weight: 650; }
.data-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 7px; }
.environment-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.data-tile { display: grid; align-content: start; gap: 4px; min-width: 0; padding: 8px 7px; border: 1px solid rgba(230,224,255,.08); border-radius: 9px; background: rgba(12,10,34,.16); }
.data-tile-label { overflow: hidden; color: var(--quiet); font-size: 9px; text-overflow: ellipsis; white-space: nowrap; }
.data-tile-value { overflow-wrap: anywhere; color: #eee9f8; font-size: 11px; font-weight: 620; font-variant-numeric: tabular-nums; }
.data-tile-source { color: #c3a879; font-size: 8px; line-height: 1.3; }
.pressure-details { margin-top: 11px; border-top: 1px solid rgba(226,220,247,.08); }
.pressure-summary { color: #bcb5cf; font-size: 9px; }
.pressure-table-wrap { max-width: 100%; overflow-x: auto; }
.pressure-table { width: 100%; border-collapse: collapse; color: #d9d3e6; font-size: 9px; font-variant-numeric: tabular-nums; }
.pressure-table th, .pressure-table td { padding: 6px 5px; border-bottom: 1px solid rgba(226,220,247,.07); text-align: right; white-space: nowrap; }
.pressure-table th:first-child, .pressure-table td:first-child { text-align: left; }
.pressure-table th { color: var(--quiet); font-weight: 550; }
.pressure-empty { margin: 7px 0 0; color: var(--quiet); font-size: 9px; }
.day-card.is-unavailable { border-color: rgba(230,224,255,.1); background: linear-gradient(155deg, rgba(38,35,64,.84), rgba(29,26,53,.9)); }
.day-card.is-unavailable .probability { color: #b5aec8; }
.day-card.is-unavailable .event-time { color: var(--quiet); }
.unavailable-message { min-height: 31px; margin: 10px 0 0; color: #dbc8aa; font-size: 10px; line-height: 1.55; }
.reference-site-history { display: grid; gap: 6px; margin-top: 10px; padding: 9px; border: 1px solid rgba(255,192,111,.28); border-radius: 10px; background: rgba(255,192,111,.055); }
.reference-site-title { color: #f3d4ae; font-size: 9px; line-height: 1.45; }
.reference-site-coordinate, .reference-site-result { margin: 0; color: #c3bdd3; font-size: 9px; line-height: 1.5; overflow-wrap: anywhere; }
.reference-site-button { justify-self: start; min-height: 28px; padding: 0 9px; border: 1px solid rgba(255,192,111,.4); border-radius: 8px; background: rgba(255,192,111,.1); color: #ffd39f; cursor: pointer; font-size: 9px; font-weight: 650; }
.reference-site-button:disabled { opacity: .65; cursor: progress; }
.day-retry { min-height: 31px; margin-top: 8px; padding: 0 10px; border: 1px solid rgba(255,192,111,.38); border-radius: 9px; background: rgba(255,192,111,.09); color: #f2c58f; cursor: pointer; font-size: 10px; font-weight: 650; }
.day-retry:hover { background: rgba(255,192,111,.16); }

.target-date-control { display: inline-flex; align-items: center; gap: 7px; color: var(--muted); font-size: 10px; white-space: nowrap; }
.target-date-control input { min-height: 33px; max-width: 150px; padding: 0 9px; border: 1px solid var(--line); border-radius: 9px; color: var(--text); background: rgba(14,12,34,.55); font: inherit; color-scheme: dark; }
.day-provenance { margin: 9px 0 0; color: var(--quiet); font-size: 9px; line-height: 1.55; overflow-wrap: anywhere; }

.satellite-module-details { margin-top: 14px; border: 1px solid rgba(228,220,255,.14); border-radius: 13px; background: rgba(31,28,58,.62); }
.satellite-module-details > summary { display: flex; align-items: center; justify-content: space-between; min-height: 46px; padding: 0 15px; color: #eee8fa; cursor: pointer; font-size: 12px; font-weight: 650; list-style: none; }
.satellite-module-details > summary::-webkit-details-marker { display: none; }
.satellite-module-details > summary::after { content: ""; width: 8px; height: 8px; margin-left: 14px; border-right: 1.5px solid var(--accent); border-bottom: 1.5px solid var(--accent); transform: rotate(45deg) translateY(-2px); transition: transform .16s ease; }
.satellite-module-details[open] > summary::after { transform: rotate(225deg) translate(-2px, -1px); }
.satellite-module-details > summary:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; border-radius: 12px; }
.satellite-module-details[open] > .observation-panel { margin: 0 14px; }
.satellite-module-details[open] > .shadow-panel { margin: 0 14px 14px; }
.observation-panel { margin-top: 0; padding: 11px 2px 8px; border: 0; border-top: 1px solid var(--line); border-radius: 0; background: transparent; }
.observation-line { display: grid; grid-template-columns: auto auto minmax(0, 1fr); align-items: center; gap: 7px 12px; }
.observation-title { display: flex; flex: 0 0 auto; align-items: center; gap: 7px; }
.observation-mark { width: 15px; height: 15px; border: 1px solid rgba(255,192,111,.65); border-radius: 50%; box-shadow: inset 0 0 0 3px rgba(255,192,111,.08); }
.observation-title h3 { margin: 0; color: #f1edf9; font-size: 12px; font-weight: 650; }
.observation-status { flex: 0 0 auto; color: #e7c18f; font-size: 9px; }
.observation-status.is-stale { color: #d9bd98; }
.observation-time { min-width: 0; margin: 0; color: var(--muted); font-size: 9px; text-align: right; }
.observation-phase, .observation-slot-times { min-width: 0; margin: 0; color: var(--muted); font-size: 9px; overflow-wrap: anywhere; }
.observation-product { flex-basis: 100%; min-width: 0; margin: 3px 0 0; color: #e7e1f1; font-size: 10px; line-height: 1.5; }
.observation-product-source { flex-basis: 100%; min-width: 0; margin: 0; color: var(--quiet); font-size: 8px; line-height: 1.45; }
.observation-slot-times { flex-basis: 100%; color: var(--quiet); line-height: 1.5; }
.observation-title { grid-column: 1; }
.observation-status { grid-column: 2; }
.observation-time { grid-column: 3; }
#satellite-phase { grid-column: 1; }
#satellite-radiation { grid-column: 2; }
#satellite-motion { grid-column: 3; }
#satellite-radiation-source, #satellite-motion-source, #satellite-slot-times { grid-column: 1 / -1; }
.observation-line .fusion-note { grid-column: 1 / -1; }
.fusion-note { display: flex; flex: 0 0 auto; align-items: center; gap: 6px; margin: 0; color: var(--quiet); font-size: 9px; white-space: nowrap; }
.fusion-note strong { color: #dfd6ef; font-size: 10px; font-weight: 600; }
.history-date-help { margin: 7px 0 0; color: var(--quiet); font-size: 10px; line-height: 1.5; }
.observation-error { margin: 11px 0 0; color: #d8c6ac; font-size: 10px; line-height: 1.6; }

.shadow-panel { margin-top: 0; padding: 15px; border: 1px solid rgba(228,220,255,.13); border-radius: 15px; background: linear-gradient(145deg, rgba(39,35,68,.72), rgba(26,24,50,.58)); }
.shadow-header { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.shadow-kicker { margin: 0 0 4px; color: #b6a7d2; font-size: 8px; letter-spacing: .14em; }
.shadow-header h3 { margin: 0; color: var(--text); font-size: 13px; font-weight: 680; }
.shadow-refresh { min-height: 31px; padding: 0 11px; border: 1px solid rgba(255,192,111,.38); border-radius: 9px; color: #f2c58f; background: rgba(255,192,111,.09); cursor: pointer; font-size: 10px; white-space: nowrap; }
.shadow-refresh:hover { background: rgba(255,192,111,.17); }
.shadow-disclaimer { margin: 9px 0; color: var(--quiet); font-size: 9px; line-height: 1.55; }
.shadow-state { margin: 0 0 9px; color: #a9dec6; font-size: 10px; line-height: 1.55; overflow-wrap: anywhere; }
.shadow-state.is-stale { color: #f0c58f; }
.shadow-meta-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 7px; }
.satellite-observation-details, .fusion-history-details { margin-top: 10px; color: var(--muted); font-size: 9px; line-height: 1.6; }
.satellite-observation-details > summary, .fusion-history-details > summary { color: #d9d1ec; cursor: pointer; padding: 7px 0; }
.satellite-observation-details[open] > summary, .fusion-history-details[open] > summary { margin-bottom: 8px; }
.fusion-history-details { border-top: 1px solid rgba(228,220,255,.09); padding-top: 8px; }
.daily-forecast-history-card { border-color: rgba(133,180,217,.16); }
.shadow-meta-tile { min-width: 0; display: grid; gap: 4px; padding: 8px; border: 1px solid rgba(228,220,255,.08); border-radius: 10px; background: rgba(255,255,255,.025); }
.shadow-meta-label, .shadow-roi-label { color: var(--quiet); font-size: 8px; line-height: 1.4; }
.shadow-meta-value { color: #f0ebfa; font-size: 10px; font-variant-numeric: tabular-nums; overflow-wrap: anywhere; }
.shadow-meta-detail { color: #a39bb9; font-size: 8px; line-height: 1.45; overflow-wrap: anywhere; }
.shadow-roi-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 205px), 1fr)); gap: 8px; margin-top: 9px; }
.shadow-roi-card { min-width: 0; padding: 10px; border: 1px solid rgba(228,220,255,.1); border-radius: 11px; background: rgba(17,16,36,.3); }
.shadow-roi-title { margin: 0; color: #f1edf9; font-size: 10px; font-weight: 680; }
.shadow-roi-subtitle { margin: 4px 0 7px; color: var(--quiet); font-size: 8px; }
.shadow-roi-values { display: grid; gap: 5px; }
.shadow-roi-value { display: flex; align-items: baseline; justify-content: space-between; gap: 8px; }
.shadow-roi-number { color: #e7e0f4; font-size: 9px; font-variant-numeric: tabular-nums; text-align: right; }
.shadow-roi-phase { margin: 7px 0 0; color: #a9a2b9; font-size: 8px; line-height: 1.5; overflow-wrap: anywhere; }
.shadow-quality { margin-top: 9px; padding: 9px; border-radius: 10px; background: rgba(255,255,255,.025); }
.shadow-quality-summary { margin: 0 0 5px; color: #d2ccdf; font-size: 9px; line-height: 1.5; }
.shadow-series-list { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 2px 12px; }
.shadow-series-row { margin: 0; color: var(--quiet); font-size: 8px; line-height: 1.5; overflow-wrap: anywhere; }
.shadow-fusion-details { margin-top: 10px; color: var(--muted); font-size: 9px; line-height: 1.6; }
.shadow-fusion-details > summary { color: #f0c58f; cursor: pointer; }
.shadow-fusion-details p { margin: 6px 0 0; }
.fusion-exp-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 3px 12px; margin-top: 8px; }
.fusion-exp-grid p { padding: 8px; border: 1px solid rgba(226,220,247,.1); border-radius: 9px; background: rgba(255,255,255,.025); }
.fusion-exp-grid strong { color: #f4d6ac; }
.fusion-contributions { margin: 7px 0; padding-left: 18px; }
.fusion-contributions li { margin: 3px 0; }
.fusion-export { margin-top: 8px; padding: 7px 10px; border: 1px solid rgba(226,220,247,.18); border-radius: 8px; background: rgba(255,255,255,.04); color: var(--text); cursor: pointer; }
.fusion-export:hover { background: rgba(255,255,255,.1); }
.manual-v1-record { display: grid; gap: 6px; margin: 9px 0 0; padding: 8px; border: 1px solid rgba(226,220,247,.12); border-radius: 9px; }
.manual-v1-record legend { color: #c9b8a0; }
.manual-v1-record label { display: grid; grid-template-columns: minmax(120px, .8fr) minmax(120px, 1.2fr); align-items: center; gap: 8px; }
.manual-v1-record input, .manual-v1-record select { min-width: 0; padding: 6px 8px; border: 1px solid rgba(226,220,247,.17); border-radius: 7px; background: rgba(0,0,0,.16); color: var(--text); }
.fusion-history { margin-top: 12px; padding: 10px; border: 1px solid rgba(226,220,247,.12); border-radius: 10px; background: rgba(0,0,0,.12); }
.fusion-history-head { display: flex; justify-content: space-between; align-items: center; gap: 12px; }
.fusion-history-head h4 { margin: 0; color: #f1dfc8; }
.fusion-history-head p, .fusion-history-meta, .fusion-history-annotation, .fusion-history-empty { color: var(--muted); font-size: .86rem; line-height: 1.5; }
.fusion-history-list { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; }
.fusion-history-card { min-width: 0; padding: 9px; border: 1px solid rgba(226,220,247,.1); border-radius: 8px; background: rgba(255,255,255,.025); overflow-wrap: anywhere; }
.fusion-history-card h5 { margin: 0 0 6px; color: #f4d6ac; }
.fusion-history-card p { margin: 4px 0; }
.fusion-history-annotation { color: #d9c7a8; }

.is-loading { animation: appear .28s ease both; }
.loading-line { height: 9px; border-radius: var(--radius-control); background: linear-gradient(90deg, rgba(217,210,241,.08), rgba(217,210,241,.16), rgba(217,210,241,.08)); background-size: 180% 100%; animation: loading-shimmer 1.6s ease-in-out infinite; }
.loading-short { width: 40%; margin: 4px 0 17px; }
.loading-date { width: 58%; height: 7px; margin-bottom: 24px; }
.loading-number { width: 65%; height: 47px; margin-bottom: 9px; }
.loading-rule { height: 1px; margin: 16px 0 14px; background: rgba(226,220,247,.1); }
.loading-detail { width: 84%; height: 7px; margin: 11px 0; }
.loading-detail:last-child { width: 67%; }
@keyframes loading-shimmer { 0%, 100% { background-position: 100% 0; } 50% { background-position: 0 0; } }
@keyframes appear { from { opacity: .55; } to { opacity: 1; } }

.site-footer { display: flex; min-height: 54px; align-items: center; justify-content: space-between; gap: 16px; border-top: 1px solid var(--line); color: var(--quiet); font-size: 10px; }
.site-footer-meta { display: flex; align-items: center; gap: 9px; white-space: nowrap; }
.site-footer-meta > span[aria-hidden="true"] { color: #706a88; }
.site-footer a { text-decoration: underline; text-decoration-color: rgba(192,187,212,.35); text-underline-offset: 3px; }
.site-footer a:hover { color: var(--text); }
.security-filing { display: inline-flex; align-items: center; gap: 5px; }
.security-filing img { width: 16px; height: 18px; object-fit: contain; }

@media (max-width: 1120px) {
  .page-shell { width: min(100% - 48px, 1050px); }
  .home-layout { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 20px; }
  .brand-panel { padding-right: 0; }
  .brand-copy h1 { font-size: clamp(32px, 3.4vw, 43px); }
  .brand-intro { font-size: 12px; }
  .mini-program-qr { width: 78px; height: 78px; }
  .day-grid { gap: 10px; }
  .day-card { padding: 16px 13px 13px; }
  .day-state { font-size: 9px; }
  .metric-label { font-size: 9px; }
}

@media (max-width: 860px) {
  .page-shell { width: min(100% - 40px, 680px); }
  .site-header { height: 72px; }
  .home-layout { grid-template-columns: 1fr; gap: 25px; padding: 20px 0 28px; }
  .forecast-panel { order: -1; }
  .brand-panel { order: 1; }
  .brand-panel { min-height: 0; display: flex; flex-direction: column; align-items: stretch; gap: 0; padding: 5px 0 0; }
  .brand-copy { max-width: 600px; }
  .brand-copy h1 { font-size: clamp(28px, 5vw, 38px); }
  .brand-kicker { margin-bottom: 10px; font-size: 11px; }
  .brand-intro { margin-top: 9px; font-size: 12px; line-height: 1.6; }
  .brand-slogan { margin: 17px 0 10px; }
  .mini-program-entry { min-width: 0; margin-top: 12px; }
  .mini-program-qr { width: 78px; height: 78px; }
  .availability-block { margin-top: 16px; }
  .recent-updates { margin-top: 16px; }
  .sky-scene { height: 138px; }
  .version-note { gap: 8px; }
  .version-note p { font-size: 10px; }
  .day-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .day-card { min-height: 0; }
  .probability { font-size: clamp(34px, 6vw, 44px); }
  .site-footer { align-items: flex-start; flex-direction: column; justify-content: center; gap: 9px; padding: 13px 0; }
}

@media (max-width: 560px) {
  .page-shell { width: min(100% - 30px, 450px); }
  .site-header { height: auto; min-height: 65px; flex-wrap: wrap; gap: 8px; padding: 9px 0; }
  .brand img { width: 36px; height: 36px; border-radius: 10px; }
  .brand-name { font-size: 14px; }
  .location-chip { width: 100%; min-height: 36px; flex: 1 1 100%; justify-content: space-between; gap: 7px; padding: 3px 5px 3px 9px; font-size: 10px; }
  .location-copy { min-width: 0; max-width: none; flex: 1 1 auto; }
  .location-copy strong { max-width: none; font-size: 10px; }
  .location-copy small { font-size: 8px; }
  .location-action, .relocate-button { min-height: 29px; padding: 0 7px; font-size: 9px; }
  .location-dialog-panel { padding: 18px 16px; }
  .location-dialog-header h2 { font-size: 17px; }
  .home-layout { gap: 23px; padding-top: 19px; }
  .brand-copy h1 { font-size: clamp(25px, 7vw, 32px); line-height: 1.18; }
  .brand-kicker { max-width: none; font-size: 10px; line-height: 1.5; }
  .brand-intro { max-width: none; font-size: 11px; }
  .brand-slogan { font-size: 12px; }
  .mini-program-entry { gap: 11px; }
  .mini-program-qr { width: 72px; height: 72px; }
  .mini-program-copy strong { font-size: 11px; }
  .mini-program-copy span { font-size: 10px; }
  .availability-row { grid-template-columns: 62px minmax(0, 1fr); gap: 8px; }
  .availability-row p { font-size: 10px; }
  .update-item { grid-template-columns: 68px minmax(0, 1fr); gap: 9px; }
  .update-item p { font-size: 10px; }
  .sky-scene { height: 124px; border-radius: 18px; }
  .version-note { grid-template-columns: 1fr; gap: 6px; margin-top: 8px; }
  .version-note p { margin-top: 0; }
  .forecast-toolbar { margin-top: 8px; }
  .sky-scene > img { object-position: 43% 56%; }
  .scene-copy { left: 18px; bottom: 23px; max-width: 86%; }
  .scene-copy p { margin-bottom: 7px; font-size: 10px; }
  .scene-copy h2 { font-size: 19px; }
  .scene-caption { right: 13px; bottom: 10px; font-size: 9px; }
  .forecast-toolbar { align-items: flex-end; flex-wrap: wrap; gap: 8px; margin: 19px 0 12px; }
  .mode-tabs { gap: 2px; padding: 3px; }
  .mode-tab { min-width: 72px; min-height: 34px; padding: 0 13px; font-size: 12px; }
  .toolbar-note { max-width: 145px; font-size: 9px; line-height: 1.45; }
  .target-date-control { flex: 1 1 120px; justify-content: flex-end; font-size: 9px; }
  .target-date-control input { max-width: 128px; min-width: 0; min-height: 32px; padding: 0 5px; font-size: 9px; }
  .toolbar-note { max-width: none; flex: 1 1 100%; text-align: left; }
  .day-grid { grid-template-columns: 1fr; gap: 9px; }
  .day-card, .day-card:first-child { min-height: 0; display: grid; grid-template-columns: minmax(0, 1fr) auto; align-items: center; gap: 0 12px; padding: 13px 15px; border-radius: 15px; }
  .day-card:first-child { grid-column: 1; }
  .day-card-head { grid-column: 1 / -1; }
  .day-date { grid-column: 1 / -1; margin: 4px 0 8px; }
  .probability-label { grid-column: 1; align-self: end; }
  .probability { grid-column: 1; grid-row: span 2; margin: -1px 0 0; font-size: 42px; }
  .event-time { grid-column: 2; grid-row: 3; align-self: center; text-align: right; }
  .day-card-divider { grid-column: 1 / -1; width: 100%; margin: 10px 0 9px; }
  .day-metrics, .d0-fusion-preview { grid-column: 1 / -1; }
  .day-metrics { grid-template-columns: 1fr 1fr; }
  .day-metric { grid-template-columns: auto 1fr; align-items: center; gap: 8px; }
  .metric-value { text-align: right; }
  .day-details { margin-top: 10px; }
  .day-details > summary { padding: 10px 0 2px; }
  .data-grid, .environment-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .data-tile { grid-template-columns: minmax(0, 1fr) auto; align-items: center; gap: 3px 8px; }
  .data-tile-label { white-space: normal; }
  .data-tile-value { text-align: right; }
  .data-tile-source { grid-column: 1 / -1; }
  .shadow-panel { padding: 11px; }
  .satellite-module-details[open] > .observation-panel { margin: 0 10px; }
  .satellite-module-details[open] > .shadow-panel { margin: 0 10px 10px; }
  .fusion-exp-grid { grid-template-columns: 1fr; gap: 2px; }
  .fusion-history-list { grid-template-columns: 1fr; }
  .fusion-history-head { align-items: flex-start; flex-direction: column; }
  .shadow-meta-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .shadow-series-list { grid-template-columns: 1fr; }
  .unavailable-message { grid-column: 1 / -1; min-height: 0; margin: 8px 0 0; }
  .observation-panel { margin-top: 12px; padding: 13px 14px; border-radius: 15px; }
  .observation-content { align-items: flex-start; flex-direction: column; gap: 8px; margin-top: 10px; }
  .observation-line { grid-template-columns: auto auto minmax(0,1fr); gap: 8px 10px; }
  .observation-title { grid-column: 1; }
  .observation-status { grid-column: 2; }
  .observation-time { grid-column: 3; }
  #satellite-phase, #satellite-radiation, #satellite-motion { grid-column: 1 / -1; }
  #satellite-radiation-source, #satellite-motion-source, #satellite-slot-times { grid-column: 1 / -1; }
  .observation-line .fusion-note { grid-column: 1 / -1; }
  .day-retry { grid-column: 1 / -1; justify-self: start; }
  .observation-time { font-size: 10px; }
  .fusion-note { font-size: 9px; }
  .site-footer { gap: 7px; font-size: 9px; }
  .site-footer-meta { flex-wrap: wrap; gap: 7px; font-size: 9px; white-space: normal; }
}

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