:root { --dark: #120e0c; --ink: #efe4c9; --dim: #a89c84; --gold: #e2ac2f; --red: #c0281f; --f: "News Cycle", "Franklin Gothic Medium", "Arial Narrow", sans-serif; }
* { box-sizing: border-box; }
html, body { margin: 0; background: var(--dark); color: var(--ink); font-family: var(--f); -webkit-font-smoothing: antialiased; }
body { min-height: 100vh; overflow-x: hidden; }
body.locked { overflow: hidden; }
button { font: inherit; color: inherit; cursor: pointer; }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
:focus-visible { outline: 3px solid var(--gold); outline-offset: 3px; }

/* the house lights go down */
#houselights { position: fixed; inset: 0; pointer-events: none; z-index: 50; background: radial-gradient(ellipse at 50% 30%, rgba(255, 196, 120, .55), rgba(120, 60, 20, .35) 60%, rgba(40, 20, 8, .2)); opacity: 0; transition: opacity 1.6s ease; }
body.house-up #houselights { opacity: 1; transition: none; }
#houselights.dim { opacity: 0; }
#houselights.black { background: #000; opacity: 1; transition: opacity .45s ease; }
#houselights.black.dim { opacity: 0; }

/* masthead */
#mast { position: relative; height: clamp(200px, 34vh, 36vw); }
#mastcv { position: absolute; inset: 0; width: 100%; height: 100%; display: block; }
#bar { position: absolute; top: max(12px, env(safe-area-inset-top)); right: 16px; display: flex; gap: 6px; z-index: 3; }
#bar button, #seqctl button, .rbar button, .rbar a { background: rgba(18, 14, 12, .72); border: 1px solid rgba(239, 228, 201, .35); padding: 9px 14px 8px; font-size: 13px; letter-spacing: .22em; text-transform: uppercase; font-weight: 700; border-radius: 0; text-decoration: none; color: var(--ink); }
#bar button:hover, #seqctl button:hover, .rbar button:hover, .rbar a:hover { background: var(--ink); color: var(--dark); }

/* the program: a card per title, best first */
#cards { list-style: none; margin: 0 auto; padding: 22px clamp(16px, 3vw, 40px) 80px; display: grid; grid-template-columns: repeat(auto-fill, minmax(330px, 1fr)); gap: clamp(14px, 2vw, 26px); max-width: 1720px; }
#cards li { opacity: 0; transform: translateY(14px); transition: opacity .25s, transform .35s cubic-bezier(.2, 1.4, .4, 1); }
#cards li.on { opacity: 1; transform: none; }
.card { display: block; width: 100%; padding: 0; border: 0; background: none; text-align: left; }
.card .frame { position: relative; aspect-ratio: 16 / 9; background: #000; box-shadow: 0 10px 26px rgba(0, 0, 0, .55), 0 0 0 1px rgba(239, 228, 201, .06); overflow: hidden; transition: transform .25s ease, box-shadow .25s; }
.card canvas { position: absolute; inset: 0; width: 100%; height: 100%; display: block; }
.card:hover .frame, .card:focus-visible .frame { transform: translateY(-3px) rotate(-.25deg); box-shadow: 0 16px 34px rgba(0, 0, 0, .7), 0 0 0 2px var(--gold); }
.card .cap { display: flex; justify-content: space-between; gap: 10px; padding: 9px 2px 0; font-size: 13px; letter-spacing: .2em; text-transform: uppercase; }
.card .cap b { font-weight: 700; }
.card .cap span { color: var(--dim); font-weight: 400; text-align: right; }

/* the title sequence, full screen */
#theater { position: fixed; inset: 0; z-index: 40; background: #000; }
#seqcv { position: absolute; inset: 0; width: 100%; height: 100%; display: block; }
#seqctl { position: absolute; right: 16px; bottom: max(16px, env(safe-area-inset-bottom)); display: flex; gap: 6px; opacity: .78; transition: opacity .2s; }
#seqctl:hover { opacity: 1; }

/* the work */
#reader { position: fixed; inset: 0; z-index: 30; overflow-y: auto; background: #0d0a09; -webkit-overflow-scrolling: touch; }
.rbar { position: sticky; top: 0; z-index: 5; display: flex; gap: 6px; align-items: center; padding: max(10px, env(safe-area-inset-top)) 16px 10px; background: linear-gradient(#0d0a09 70%, rgba(13, 10, 9, 0)); }
.rbar .sp { flex: 1; }
.rbar .nav { max-width: 34vw; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.screen { width: min(100%, 1280px, calc((100vh - 140px) * 16 / 9)); margin: 6px auto 0; padding: 0 16px; }
.screen.vert { width: min(100%, 420px, calc((100vh - 140px) * 9 / 16)); }
.film { position: relative; aspect-ratio: 16 / 9; background: #000; box-shadow: 0 0 0 1px #000, 0 30px 80px rgba(0, 0, 0, .8); }
.film.vert { aspect-ratio: 9 / 16; }
.film img.poster { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.film iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }
.film .play { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; background: rgba(0, 0, 0, .12); display: grid; place-items: center; }
.film .play svg { width: clamp(64px, 12%, 110px); filter: drop-shadow(2px 4px 5px rgba(0, 0, 0, .5)); transition: transform .2s; }
.film .play:hover svg, .film .play:focus-visible svg { transform: scale(1.08) rotate(-2deg); }
.film .play:hover { background: rgba(0, 0, 0, .02); }
.film .label { position: absolute; left: 12px; bottom: 10px; font-size: 12px; letter-spacing: .24em; text-transform: uppercase; background: rgba(13, 10, 9, .8); padding: 5px 9px 4px; pointer-events: none; }
.billing { max-width: 1280px; margin: 34px auto 0; padding: 0 16px; display: grid; grid-template-columns: minmax(0, 1.1fr) minmax(0, 1fr); gap: clamp(18px, 3vw, 44px); align-items: start; }
.billing .key { aspect-ratio: 16 / 9; position: relative; box-shadow: 0 14px 40px rgba(0, 0, 0, .6); }
.billing .key canvas { position: absolute; inset: 0; width: 100%; height: 100%; }
.billing h2 { margin: 0; font-size: clamp(34px, 4.6vw, 64px); line-height: .98; letter-spacing: .04em; text-transform: uppercase; }
.billing .client { margin: 10px 0 0; color: var(--gold); letter-spacing: .32em; font-size: 14px; text-transform: uppercase; }
.billing .desc { margin: 18px 0 0; font-size: 19px; line-height: 1.45; color: #e6dcc4; max-width: 40em; }
.credits { margin: 22px 0 0; display: grid; grid-template-columns: max-content 1fr; gap: 6px 18px; font-size: 14px; letter-spacing: .16em; text-transform: uppercase; }
.credits dt { color: var(--dim); font-weight: 400; }
.credits dd { margin: 0; font-weight: 700; }
.reel { max-width: 1280px; margin: 56px auto 0; padding: 0 16px; }
.reel h3 { margin: 0 0 6px; font-size: 14px; letter-spacing: .34em; text-transform: uppercase; color: var(--gold); }
.reel p { margin: 0 0 16px; font-size: 17px; line-height: 1.45; color: #d9cfb8; max-width: 46em; }
.films { display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: 16px; }
.films.vert { grid-template-columns: repeat(auto-fill, minmax(170px, 1fr)); }
.imgs { display: grid; gap: 10px; }
.imgs.row-2 { grid-template-columns: repeat(2, 1fr); } .imgs.row-3 { grid-template-columns: repeat(3, 1fr); } .imgs.row-4 { grid-template-columns: repeat(4, 1fr); }
.imgs img { width: 100%; height: auto; display: block; background: #1b1512; box-shadow: 0 8px 22px rgba(0, 0, 0, .5); }
.radio { display: grid; gap: 10px; max-width: 760px; }
.radio figure { margin: 0; display: grid; grid-template-columns: 1fr; gap: 6px; padding: 12px 14px; background: #1b1512; border-left: 4px solid var(--gold); }
.radio figcaption { font-size: 14px; letter-spacing: .18em; text-transform: uppercase; font-weight: 700; }
.radio audio { width: 100%; }
.next { max-width: 1280px; margin: 70px auto 0; padding: 0 16px 90px; display: flex; justify-content: space-between; gap: 12px; }
.next button { background: none; border: 0; padding: 0; text-align: left; letter-spacing: .2em; text-transform: uppercase; font-size: 13px; color: var(--dim); }
.next button b { display: block; color: var(--ink); font-size: clamp(20px, 3vw, 34px); letter-spacing: .06em; margin-top: 4px; }
.next button:last-child { text-align: right; }
.next button:hover b { color: var(--gold); }

/* index: the program listing */
#index { position: fixed; inset: 0; z-index: 45; background: rgba(8, 6, 5, .9); overflow-y: auto; }
#index .sheet { max-width: 880px; margin: 0 auto; padding: 70px 18px 60px; }
#indexlist { list-style: none; padding: 0; margin: 0; columns: 2 300px; column-gap: 40px; }
#indexlist li { break-inside: avoid; }
#indexlist button { display: flex; width: 100%; justify-content: space-between; gap: 12px; align-items: baseline; background: none; border: 0; border-bottom: 1px solid rgba(239, 228, 201, .14); padding: 10px 2px; text-align: left; }
#indexlist b { font-size: 20px; letter-spacing: .06em; text-transform: uppercase; }
#indexlist span { color: var(--dim); font-size: 12px; letter-spacing: .2em; text-transform: uppercase; white-space: nowrap; }
#indexlist button:hover b { color: var(--gold); }
.close { position: fixed; top: max(12px, env(safe-area-inset-top)); right: 16px; z-index: 3; width: 46px; height: 46px; background: rgba(18, 14, 12, .8); border: 1px solid rgba(239, 228, 201, .35); font-size: 26px; line-height: 1; }

/* about: the end credits */
#about { position: fixed; inset: 0; z-index: 45; background: #000; }
#crawl { position: absolute; inset: 0; overflow-y: auto; text-align: center; padding: 0 18px; scrollbar-width: none; }
#crawl::-webkit-scrollbar { display: none; }
#crawl .pad { height: 92vh; }
#crawl canvas { width: min(900px, 100%); aspect-ratio: 16 / 5; display: block; margin: 0 auto; }
#crawl .role { margin: 34px 0 0; color: var(--gold); font-size: 13px; letter-spacing: .36em; text-transform: uppercase; }
#crawl .name { margin: 6px 0 0; font-size: clamp(22px, 3vw, 30px); letter-spacing: .1em; text-transform: uppercase; font-weight: 700; }
#crawl .bio { max-width: 32em; margin: 22px auto 0; font-size: 19px; line-height: 1.5; color: #e6dcc4; }
#crawl a { color: var(--ink); }

#snow { position: fixed; inset: 0; width: 100%; height: 100%; pointer-events: none; z-index: 20; display: none; }

@media (max-width: 600px) {
  #cards { grid-template-columns: 1fr; padding-top: 14px; }
  .billing { grid-template-columns: 1fr; }
  .imgs.row-3, .imgs.row-4 { grid-template-columns: repeat(2, 1fr); }
  #bar button, #seqctl button, .rbar button { padding: 8px 10px 7px; font-size: 11px; letter-spacing: .16em; }
  .rbar .nav { display: none; }
  #mast { height: 250px; min-height: 0; }
}
@media (prefers-reduced-motion: reduce) {
  #cards li { transition: none; }
  .card .frame, #houselights { transition: none !important; }
}
