/* V15 audit: readable journeys, comfortable controls and resilient layouts. */
html{scroll-padding-top:100px}
.brand-logo img{object-fit:contain}
.site-header.menu-open .brand-logo img{filter:invert(1) hue-rotate(180deg) saturate(.7) brightness(1.15)}
@media(min-width:881px) and (max-width:1080px){.site-header .brand-logo{width:175px}.site-header .header-inner{gap:12px}.site-header .site-nav{gap:10px}.site-header .site-nav a{font-size:.74rem}}
@media(max-width:480px){html[data-theme=night] .brand-logo img,.site-header.menu-open .brand-logo img{filter:none}.brand-logo{background:#f5f6f1!important}}
.story-controls{margin-bottom:28px}
.story-mode{display:flex;align-items:center;flex-wrap:wrap;gap:12px 22px;margin-bottom:18px;font-size:.8rem;color:var(--ink-soft)}
.story-mode button,.pub-empty button{min-height:44px;padding:10px 18px;border:1px solid var(--control-edge);border-radius:999px;background:var(--surface);color:var(--ink);font:inherit;cursor:pointer}
.story-mode button[aria-pressed=true]{background:var(--lime);color:var(--on-lime)}
.story-mode a{color:var(--accent-text);text-underline-offset:4px}
.story-jump{display:grid;grid-template-columns:repeat(6,minmax(0,1fr));border:1px solid var(--hair);border-radius:16px;overflow:hidden;background:var(--surface)}
.story-jump a{display:flex;flex-direction:column;gap:8px;padding:16px 12px;min-height:64px;text-decoration:none;font-size:.8rem;color:var(--ink);border-right:1px solid var(--hair)}
.story-jump a:last-child{border-right:0}.story-jump a span{font-size:.65rem;color:var(--ink-soft)}
.story-jump a:hover,.story-jump a[aria-current=step]{background:var(--v13-panel);color:var(--accent-text)}
.story-jump a:focus-visible{outline-offset:-4px}
.story-steps>.story-step{opacity:1;scroll-margin-top:110px}
.story-steps>.story-step:not(.is-active){border-left-color:var(--hair)}
.story-reading .story-layout{grid-template-columns:1fr}
.story-reading .story-stage{display:none}
.story-reading .story-steps{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:20px}
.story-reading .story-steps>.story-step{min-height:0;justify-content:flex-start;padding:26px;border:1px solid var(--hair);border-radius:18px;background:var(--surface)}
.story-reading .story-step h3{font-size:1.4rem}
.story-reading .story-pubs li{background:var(--cream)}
.story-reading .story-actions{margin-top:auto}
.pub-empty{padding:34px;border:1px dashed var(--control-edge);border-radius:18px;background:var(--surface);margin:22px 0;color:var(--ink)}
.pub-empty[hidden]{display:none}.pub-empty h2{font-size:1.5rem;letter-spacing:-.025em}.pub-empty p{color:var(--ink-body);margin:12px 0 20px}
.rv-dot{width:min(32px,100%);height:32px}.rv-chart,.rv-years{gap:2px}
.rv-chip,.rv-year,.tl-jump button,.topic-chips button,.card-nav button,.card-copy,.card-close{min-height:44px}
.rv-tip{width:min(300px,calc(100% - 24px));max-width:calc(100% - 24px);box-sizing:border-box}
.card-save:disabled{opacity:.55;cursor:wait}
.card-note{min-height:2.8em;line-height:1.6}
@media(max-width:900px){.story-stage{position:relative;top:0;height:350px;margin-bottom:20px}.story-steps>.story-step,.story-steps>.story-step:last-child{min-height:0;padding:30px 0 30px 20px}.story-reading .story-steps>.story-step{padding:22px}.story-jump{grid-template-columns:repeat(3,minmax(0,1fr))}.story-jump a:nth-child(3){border-right:0}.story-jump a:nth-child(-n+3){border-bottom:1px solid var(--hair)}}
@media(max-width:620px){.story-reading .story-steps{grid-template-columns:1fr}.story-jump a{font-size:.74rem;padding:13px 10px}.story-mode{gap:12px}.story-mode>span{width:100%}.card-dialog{padding:18px 14px}.card-dialog-bar{align-items:stretch}.card-actions{flex-wrap:wrap}.card-save,.card-copy{min-height:44px}.rv-dot{width:min(28px,100%);height:32px}.pub-empty{padding:24px}}
@media(prefers-reduced-motion:reduce){html{scroll-behavior:auto!important}.v14-reveal{opacity:1!important;transform:none!important}.pub-entry.is-highlight{animation:none;outline:2px solid var(--focus-ring)}.story-stage{position:relative;top:0}.story-steps>.story-step,.story-steps>.story-step:last-child{min-height:0;padding-block:28px}.timeline.v14-track::after{transition:none}}
@media print{.story-stage,.story-controls,.card-dialog,.record-viz,.topic-chips,.tl-jump{display:none!important}.story-layout,.story-reading .story-steps{display:block}.story-steps>.story-step,.story-steps>.story-step:last-child{min-height:0;padding:18px 0;opacity:1;break-inside:avoid}.v14-reveal{opacity:1!important;transform:none!important}}
