@font-face { font-family: 'Crimson Pro'; font-weight: 300; font-style: normal; font-display: optional; src: url('crimson-pro.ttf') format('truetype'); }
* { box-sizing: border-box; }
:root { --gold: #fdde9b; --muted: #ddcba8; --line: #fdde9b45; }
html { min-height: 100%; background: #10051d; color: var(--gold); }
body { margin: 0; min-height: 100vh; min-height: 100dvh; display: flex; flex-direction: column; position: relative; isolation: isolate; background: #10051d; font-family: 'Crimson Pro', Georgia, serif; font-weight: 300; }
button, select { font: inherit; color: inherit; }
a { color: inherit; text-underline-offset: .25em; }
button, select, .date-link { border: 1px solid var(--line); background: #130920a8; border-radius: 4px; padding: .7rem 1rem; min-height: 44px; }
button, select { cursor: pointer; }
button:disabled { opacity: .4; cursor: default; }
:focus-visible { outline: 3px solid var(--gold); outline-offset: 5px; }
.skip { position: fixed; left: 1rem; top: -5rem; padding: .8rem; background: #170b28; z-index: 10; }
.skip:focus { top: 1rem; }
.shell { width: min(1060px, calc(100% - 40px)); margin: auto; }
.topbar { display: flex; align-items: center; justify-content: space-between; gap: 20px; padding: 24px 0 14px; }
.brand { display: block; flex: 0 0 100px; }
.brand img { display: block; width: 100%; }
.sign-nav { display: flex; flex-wrap: wrap; justify-content: flex-end; gap: 4px; }
.sign-nav a { width: 44px; height: 48px; display: grid; place-items: center; border-bottom: 1px solid transparent; border-radius: 4px; }
.sign-nav a[aria-current=page] { border-color: var(--gold); background: #fdde9b12; }
.sign-nav img { width: 29px; height: 29px; object-fit: contain; }
.sign-icon { transform: rotate(var(--rotation)); }
.home { text-align: center; padding-top: 22px; }
.eyebrow { text-transform: uppercase; letter-spacing: .18em; font: .72rem/1.5 system-ui, sans-serif; color: var(--muted); }
h1 { font-size: clamp(2.8rem, 6vw, 4.8rem); font-weight: 300; line-height: 1.08; margin: 12px 0; }
.home h1 { font-size: clamp(2rem, 4vw, 2.9rem); }
.intro { font-size: 1.15rem; line-height: 1.6; color: var(--muted); margin: 10px auto; max-width: 580px; }
.wheel { position: relative; width: min(570px, 100%, max(264px, calc(100svh - 100px))); aspect-ratio: 1; margin: 8px auto 18px; }
.sun { position: absolute; left: 50%; top: 50%; width: 43%; transform: translate(-50%,-50%); }
.wheel a { position: absolute; width: 17%; height: 17%; left: var(--x); top: var(--y); transform: translate(-50%,-50%); display: grid; place-items: center; border-radius: 50%; text-decoration: none; }
.wheel a img { width: 77%; height: 77%; object-fit: contain; transform: rotate(var(--angle)); transition: scale .2s; }
.wheel a:hover img, .wheel a:focus-visible img { scale: 1.12; }
.wheel-label { position: absolute; bottom: -6px; font-size: .84rem; opacity: 0; background: #170b28; padding: 2px 6px; border-radius: 3px; }
.wheel a:hover .wheel-label, .wheel a:focus-visible .wheel-label { opacity: 1; }
.sign-picker { margin: 12px auto 22px; display: flex; align-items: center; justify-content: center; gap: 12px; }
.reader { padding: 20px 0 36px; }
.back { display: inline-block; margin-bottom: 26px; font-size: 1rem; }
.reading-head { display: flex; justify-content: space-between; align-items: center; gap: 20px; }
.reading-head img { width: 78px; height: 78px; object-fit: contain; margin-right: 12px; }
.datebar { display: flex; flex-wrap: wrap; gap: 12px; align-items: center; margin: 24px 0 8px; }
.datebar label { color: var(--muted); }
.datebar select { min-width: 200px; }
.datebar .today { margin-left: auto; }
.period { font: .78rem/1.6 system-ui,sans-serif; color: var(--muted); }
.sky-note { margin: 32px 0 26px; padding: 14px 0; border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); font-size: 1.08rem; line-height: 1.6; }
.sky-note span { color: var(--muted); }
.theme-label { font-size: 1.12rem; font-weight: 300; margin: 0; }
.theme { font-size: clamp(2rem,4vw,2.8rem); margin: 10px 0 28px; font-style: italic; font-weight: 300; }
.reading-summary { max-width: 840px; font-size: clamp(1.2rem,2.3vw,1.45rem); line-height: 1.65; margin: 0 0 32px; }
.about { text-align: left; font-size: .95rem; width: 100%; max-width: 720px; margin: 30px auto 0; border-top: 1px solid var(--line); padding-top: 10px; }
.about h3 { font-size: 1.05rem; font-weight: 300; color: var(--gold); }
.home > .eyebrow { margin: 10px 0; }
.cards { display: grid; grid-template-columns: 1fr 1fr; gap: 30px; }
.card { border-top: 1px solid var(--line); padding-top: 22px; }
.card h2 { font-size: 1.15rem; font-weight: 300; color: var(--muted); margin: 0 0 14px; }
.card p { font-size: clamp(1.25rem,2.5vw,1.55rem); line-height: 1.5; margin: 0; }
.day-nav { display: grid; grid-template-columns: 1fr 1fr; gap: 22px; margin: 32px 0 12px; }
.day-nav button { font-size: 1.12rem; border-color: var(--gold); background: transparent; }
button:not(:disabled):hover, .date-link:hover { background: #fdde9b14; }
.boundary { min-height: 1.5em; font-size: .9rem; color: var(--muted); }
details { margin: 26px 0; color: var(--muted); line-height: 1.6; }
summary { cursor: pointer; min-height: 44px; padding: 8px 0; color: var(--gold); }
table { width: 100%; border-collapse: collapse; margin: 12px 0; font-variant-numeric: tabular-nums; }
th,td { padding: 8px; border-bottom: 1px solid var(--line); text-align: left; }
.method { max-width: 720px; }
.disclaimer { color: var(--muted); font-size: .85rem; line-height: 1.6; max-width: 720px; margin: 25px 0; }
footer { padding: 18px 20px; color: var(--muted); text-align: right; font-size: .8rem; }
.error { padding: 60px 0; }
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; overflow: hidden; clip: rect(0,0,0,0); white-space: nowrap; border: 0; }
@media (max-width: 640px) {
 .shell { width: calc(100% - 32px); }
 .topbar { gap: 12px; align-items: flex-start; }
 .brand { flex-basis: 65px; padding-top: 5px; }
 .sign-nav { max-width: 290px; gap: 0; }
 .sign-nav a { width: 36px; height: 44px; }
 .sign-nav img { width: 24px; height: 24px; }
 .cards { grid-template-columns: 1fr; gap: 28px; }
 .reading-head img { width: 56px; height: 56px; }
 .datebar .today { margin-left: 0; }
 .home { padding-top: 22px; }
 .day-nav { gap: 12px; }
 .reader { padding-top: 12px; }
}
@media (prefers-reduced-motion: reduce) { * { transition: none !important; } }
@media (max-height: 380px) {
 .home { padding-top: 8px; }
 .home > .eyebrow { margin: 4px 0; }
}

/* Original galaxy artwork and gradients stay intact underneath the stars. */
.galaxy{position:fixed;inset:-32px;pointer-events:none;overflow:hidden;z-index:0;user-select:none;contain:strict}
.star-layer{position:absolute;top:32px;left:32px;width:1px;height:1px;border-radius:50%;pointer-events:none}
.star-layer-1{width:1.5px;height:1.5px}.star-layer-2{width:2px;height:2px}
#app,.evergreen{position:relative;z-index:1}
.evergreen{max-width:700px;margin:32px auto;padding:0 24px;line-height:1.6;text-align:center}
.evergreen nav{display:flex;flex-wrap:wrap;justify-content:center;gap:8px 16px}
@media(prefers-reduced-motion:reduce),(pointer:coarse),(hover:none){.star-layer{transform:none!important}}

/* Native 1672×941 nebula; smaller delivery for narrow viewports, no upscale. */

.star-pulse{position:absolute;width:inherit;height:inherit;border-radius:50%;pointer-events:none;background:#fdde9b;opacity:.08;animation-name:star-pulse;animation-timing-function:ease-in-out;animation-iteration-count:infinite;animation-play-state:paused}
.galaxy.pulsing .star-pulse{animation-play-state:running}
@keyframes star-pulse{0%,100%{opacity:.08}50%{opacity:.45}}
@media(prefers-reduced-motion:reduce),(pointer:coarse),(hover:none){.star-pulse{display:none;animation:none}}

/* A continuous 20px orbit over 180s gives only the distant stars subtle depth.
   Nested transforms preserve pointer parallax; the nebula and UI stay fixed. */
.distant-sky{position:absolute;inset:0;pointer-events:none;animation:distant-drift 180s linear infinite;animation-play-state:paused}
.galaxy.pulsing .distant-sky{animation-play-state:running}
@keyframes distant-drift{from{transform:rotate(0deg) translateX(20px) rotate(0deg)}to{transform:rotate(360deg) translateX(20px) rotate(-360deg)}}
.motion-note{font-size:.9em;color:var(--muted)}
#toggle-sky-motion[aria-pressed=true]{background:#fdde9b25}
@media(prefers-reduced-motion:reduce),(pointer:coarse),(hover:none){.distant-sky{animation:none;transform:none}}

.guide-actions{display:flex;flex-wrap:wrap;justify-content:space-between;align-items:center;gap:12px;margin-top:16px}
.guide-actions #close-help{margin-left:auto}
#app>.initial-reader{min-height:70svh}
.initial-reader .initial-loading{min-height:1.5em;color:var(--muted)}
#app main{animation:reading-enter .24s ease-out}
@keyframes reading-enter{from{opacity:.88;transform:translateY(2px)}to{opacity:1;transform:translateY(0)}}
@media(prefers-reduced-motion:reduce){#app main{animation:none}}

/* Viewport backdrop is independent of document height and collapsed margins. */
body::before{content:"";position:fixed;inset:0;z-index:-1;pointer-events:none;background: linear-gradient(127deg,rgba(2,0,26,.8),rgba(19,0,37,.9),rgba(43,4,0,.8)),url('assets/nebula-v2.jpg') center / cover no-repeat}
.site-footer{position:relative;z-index:1;margin-top:auto;flex-shrink:0;width:100%}
#app{width:100%;min-width:0}
@media(max-width:700px){body::before{background-image:linear-gradient(127deg,rgba(2,0,26,.8),rgba(19,0,37,.9),rgba(43,4,0,.8)),url('assets/nebula-v2-mobile.jpg')}}
