/* A reading spread in the existing atlas: illustration, a short thought, then time. */
.star-story-opener { color: var(--gold); text-align: left; min-height: 44px; }
.star-story {
  width: min(1200px, calc(100vw - 64px)); max-width: none;
  max-height: calc(100dvh - 48px); margin: auto; padding: 0;
  border: 1px solid var(--hairline); background: var(--night); color: var(--ink);
  overflow-y: auto; overscroll-behavior: contain;
}
.star-story::backdrop { background: rgba(4, 7, 9, .93); }
.star-story-sheet { padding: 32px 40px 24px; }
.star-story-header { position: sticky; top: 0; z-index: 1; display: flex; align-items: center; justify-content: space-between; gap: 24px; padding: 12px 0; background: var(--night); }
.star-story-header .eyebrow { margin: 0 0 8px; font-size: 9px; }
#star-story-title { margin: 0; font: 400 28px/1.2 var(--editorial); letter-spacing: -.02em; }
#close-star-story { min-height: 44px; flex-shrink: 0; color: var(--ink); }
.star-story-anchor { margin: 20px 0 8px; color: var(--gold); font-size: 10px; overflow-wrap: anywhere; }
.star-story-scope { max-width: 88ch; margin: 0; font-size: 11px; line-height: 1.8; color: var(--muted); }
.star-story-reading { display: grid; grid-template-columns: minmax(0, 1.25fr) minmax(0, 1fr); align-items: center; gap: 40px; min-height: 380px; padding: 28px 0; scroll-margin-top: 100px; }
.star-story-figure { margin: 0; min-width: 0; }
#star-story-art svg { display: block; width: 100%; height: auto; }
.star-story-figure figcaption { padding-top: 12px; color: var(--muted); text-align: center; font-size: 9px; }
.star-story-copy { min-width: 0; }
.star-stage-position { margin: 0 0 16px; color: var(--gold); font-size: 10px; letter-spacing: .13em; text-transform: uppercase; }
#star-stage-title { margin: 0 0 20px; font: 400 46px/1.08 var(--editorial); letter-spacing: -.035em; text-wrap: balance; outline-offset: 8px; }
.star-stage-summary { font-size: 14px; line-height: 1.8; margin: 0 0 14px; }
.star-stage-detail { font-size: 11px; line-height: 1.9; color: var(--muted); margin: 0; }
.star-stage-time { color: var(--gold); font-size: 10px; line-height: 1.8; margin: 18px 0 0; }
.star-story-sources { margin-top: 12px; font-size: 10px; }
.star-story-sources summary { width: fit-content; min-height: 44px; padding: 12px 0; cursor: pointer; color: var(--ink); }
.star-story-sources summary:focus-visible { outline: 2px solid var(--gold); outline-offset: 4px; }
.star-story-sources ul { padding: 0; margin: 0; list-style: none; display: grid; gap: 12px; }
.star-story-sources a { display: inline-block; color: var(--ink); text-decoration-color: var(--gold); text-underline-offset: 4px; overflow-wrap: anywhere; }
.star-story-sources small { display: block; color: var(--muted); padding-top: 4px; font-size: 9px; }
.star-story-footer { border-top: 1px solid var(--hairline); }
#star-story-stages { display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); gap: 12px; list-style: none; padding: 0; margin: 16px 0; }
.star-story-step { display: flex; flex-direction: column; gap: 8px; width: 100%; min-height: 58px; padding: 8px 0; border: 0; text-align: left; background: transparent; color: var(--muted); font-size: 10px; line-height: 1.5; }
.star-story-step > span:first-child { font-size: 9px; letter-spacing: .12em; }
.star-story-step[aria-current='step'] { color: var(--gold); }
.star-story-step:hover { color: var(--ink); }
.star-story-navigation { display: flex; align-items: center; justify-content: space-between; gap: 16px; border-top: 1px solid var(--soft-line); padding-top: 12px; }
.star-story-navigation > button { min-height: 44px; }
.star-story-navigation > p { margin: 0; color: var(--muted); font-size: 9px; line-height: 1.7; text-align: center; }
#star-story-next { width: auto; padding: 10px 16px; flex-shrink: 0; color: var(--gold); }
@media (min-width: 901px) and (max-height: 800px) {
  .star-story-sheet { padding: 16px 32px; }
  .star-story-header { padding: 8px 0; }
  .star-story-anchor { margin-top: 12px; }
  .star-story-reading { min-height: 300px; padding: 16px 0; }
  #star-story-art svg { max-height: 250px; }
  #star-stage-title { font-size: 38px; margin-bottom: 16px; }
  .star-stage-position { margin-bottom: 12px; }
  .star-stage-summary { font-size: 13px; }
}
@media (max-width: 900px) {
  .star-story-sheet { padding: 24px; }
  .star-story-reading { gap: 24px; }
  #star-stage-title { font-size: 36px; }
  #star-story-stages { gap: 8px; }
}
/* On phones the story is a scrollable page; no caption or source is clipped. */
@media (max-width: 600px) {
  .star-story { width: 100%; height: 100dvh; max-height: 100dvh; border: 0; }
  .star-story-sheet { padding: max(20px, env(safe-area-inset-top)) 24px max(24px, env(safe-area-inset-bottom)); }
  .star-story-header { align-items: flex-start; gap: 16px; }
  #star-story-title { font-size: 24px; }
  #close-star-story { max-width: 105px; padding: 0; text-align: right; font-size: 10px; }
  .star-story-anchor { margin-top: 20px; }
  .star-story-scope { font-size: 10px; }
  .star-story-reading { grid-template-columns: 1fr; gap: 24px; padding: 20px 0 28px; }
  .star-story-figure { width: 100%; max-width: 420px; justify-self: center; }
  .star-story-figure figcaption { padding-top: 6px; font-size: 8px; }
  .star-stage-position { margin-bottom: 12px; }
  #star-stage-title { max-width: 13ch; font-size: 38px; margin-bottom: 16px; }
  .star-stage-summary { font-size: 13px; }
  #star-story-stages { grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 8px 16px; }
  .star-story-step { font-size: 9px; min-height: 56px; gap: 4px; }
  .star-story-navigation { flex-wrap: wrap; gap: 8px 16px; }
  .star-story-navigation > p { order: 3; width: 100%; text-align: left; }
  #star-story-next { max-width: 57%; text-align: right; font-size: 10px; }
}
@media (max-height: 520px) and (min-width: 601px) {
  .star-story { width: 100%; max-height: 100dvh; height: 100dvh; border: 0; }
  .star-story-reading { padding: 20px 0; min-height: 0; }
}
