:root {
    color-scheme: dark;
    --bg: #06121d;
    --surface: #102330;
    --line: #365360;
    --text: #f4fbf9;
    --muted: #bdd2d8;
    --accent: #89efdf;
    font-family: system-ui, sans-serif;
    line-height: 1.55;
}

* { box-sizing: border-box; }
body { margin: 0; color: var(--text); background: radial-gradient(ellipse at 18% 0%, #133440 0, var(--bg) 42rem); }
a { color: var(--accent); text-underline-offset: .2em; }
a:focus-visible, video:focus-visible { outline: 2px solid var(--accent); outline-offset: 4px; }
img { max-width: 100%; height: auto; }
.site-header, main, .site-footer { width: min(1120px, calc(100% - 2rem)); margin-inline: auto; }
.site-header { display: flex; justify-content: space-between; align-items: center; gap: .5rem 1.5rem; padding-block: 1rem; border-bottom: 1px solid var(--line); }
.site-header nav { display: flex; justify-content: flex-end; flex-wrap: wrap; gap: 0 1rem; margin-inline-start: auto; }
.site-header a { min-height: 44px; display: inline-flex; align-items: center; gap: .5rem; color: var(--text); font-size: .9rem; text-decoration: none; }
.site-header a[aria-current] { color: var(--accent); }
.site-header a:hover { text-decoration: underline; }
.brand { flex-shrink: 0; font-weight: 750; }
.brand img { width: 2rem; height: 2rem; }
.skip-link { position: absolute; left: 1rem; top: -10rem; padding: .6rem 1rem; z-index: 1; background: var(--bg); }
.skip-link:focus { top: 1rem; }
.hero { max-width: 54rem; padding-block: clamp(2.5rem, 6vw, 6rem) 1rem; }
.hero h1, .detail h1 { margin: .25em 0; font-size: clamp(2.35rem, 7vw, 5rem); font-weight: 730; line-height: 1.03; letter-spacing: -.055em; text-wrap: balance; overflow-wrap: anywhere; }
.eyebrow { display: block; color: var(--accent); font-size: .76rem; font-weight: 760; letter-spacing: .14em; text-transform: uppercase; }
.intro { max-width: 38rem; color: var(--muted); font-size: clamp(1rem, 2vw, 1.22rem); }
.button { display: inline-flex; align-items: center; min-height: 44px; max-width: 100%; padding: .5rem 1rem; border: 1px solid var(--line); border-radius: 999px; text-decoration: none; font-weight: 680; }
.button:hover { border-color: var(--accent); }
.button-primary { color: #071b1c; background: var(--accent); border-color: var(--accent); }
.download-actions { margin-block: 1.15rem .8rem; scroll-margin: 1rem; }
.download-actions h2 { font-size: 1.05rem; margin-block: 0 .45rem; }
.store-links { display: flex; flex-wrap: wrap; gap: .55rem; }
.featured, .library { margin-block: 2rem 3rem; }
h2 { margin-block: 0 .6rem; font-size: clamp(1.45rem, 3vw, 2rem); letter-spacing: -.025em; }
.grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 190px), 1fr)); gap: 1rem; list-style: none; margin: 0; padding: 0; }
.card, .library-row, .notice { overflow: hidden; border-radius: 1rem; border: 1px solid var(--line); background: var(--surface); }
.card a, .library-row a { display: block; height: 100%; color: var(--text); text-decoration: none; }
.card a:focus-visible, .library-row a:focus-visible { outline-offset: -3px; }
.card a:hover strong, .library-row a:hover strong { color: var(--accent); text-decoration: underline; }
.card img { display: block; width: 100%; height: auto; aspect-ratio: 4 / 3; object-fit: cover; object-position: 50% 38%; background: var(--bg); }
.card-copy { display: grid; padding: .8rem; gap: .25rem; }
.card-copy strong { font-size: 1.06rem; }
.card-copy small, .library-row small, .notice, .rhythm { color: var(--muted); }
.library-list { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 275px), 1fr)); gap: .75rem; list-style: none; margin: 0; padding: 0; }
.library-row a { min-height: 44px; padding: .7rem 1rem; }
.library-row strong, .library-row small { display: block; }
.detail { display: grid; grid-template-columns: minmax(0, 1fr) minmax(260px, .72fr); grid-template-areas: 'copy video' 'notes video'; grid-template-rows: auto 1fr; align-items: start; column-gap: clamp(1rem, 5vw, 5rem); padding-block: clamp(1.6rem, 5vw, 4rem) 3.5rem; }
.detail-copy { grid-area: copy; }
.detail-notes { grid-area: notes; margin-top: 1rem; }
.detail h1 { font-size: clamp(2.25rem, 5.5vw, 4rem); }
.back-link { display: inline-flex; align-items: center; min-height: 44px; margin-bottom: 1.25rem; }
.detail-actions { display: flex; flex-wrap: wrap; gap: .6rem; margin-block: .65rem 1.25rem; }
.notice { padding: 1rem 1.2rem; max-width: 38rem; }
.notice strong { color: var(--text); }
.notice p { margin-block: .35rem; }
.rhythm { max-width: 38rem; margin-top: 1rem; }
.rhythm summary { cursor: pointer; display: list-item; min-height: 44px; padding-block: .55rem; color: var(--accent); }
.rhythm summary:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; }
.rhythm li + li { margin-top: .25rem; }
.video-frame { display: grid; grid-area: video; justify-items: center; margin: 0; }
.video-frame video, .video-frame img { display: block; width: min(100%, 360px); height: auto; aspect-ratio: 9 / 16; object-fit: cover; border: 1px solid var(--line); border-radius: 1.15rem; background: #030b11; }
.video-frame img { aspect-ratio: 4 / 5; }
.site-footer { border-top: 1px solid var(--line); color: var(--muted); padding: 1.5rem 0 2rem; font-size: .9rem; }
@media (max-width: 680px) {
    .detail { grid-template-columns: 1fr; grid-template-areas: 'copy' 'video' 'notes'; grid-template-rows: auto; }
    .site-header nav { gap: 0 .65rem; }
}
