/* Shared styles: typography, layout, project components, and responsive behavior.
   Visible homepage filters are CSS-only; JS adds hidden-tag URLs and chronological masonry. */

/* === EB Garamond ========================================================== */
@font-face {
  font-family: 'EB Garamond'; font-style: normal; font-weight: 400; font-display: swap;
  src: url('/fonts/eb-garamond-normal-400.woff2') format('woff2');
}
@font-face {
  font-family: 'EB Garamond'; font-style: italic; font-weight: 400; font-display: swap;
  src: url('/fonts/eb-garamond-italic-400.woff2') format('woff2');
}
@font-face {
  font-family: 'EB Garamond'; font-style: normal; font-weight: 500; font-display: swap;
  src: url('/fonts/eb-garamond-normal-500.woff2') format('woff2');
}
@font-face {
  font-family: 'EB Garamond'; font-style: normal; font-weight: 700; font-display: swap;
  src: url('/fonts/eb-garamond-normal-700.woff2') format('woff2');
}
@font-face {
  font-family: 'EBGaramondSC'; font-style: normal; font-weight: 400; font-display: swap;
  src: url('/fonts/EBGaramond-Regular-SC.woff2') format('woff2');
}

@font-face {
  font-family: 'EB Garamond Fallback';
  src: local('Palatino Linotype');
  font-style: normal;
  font-weight: 400 700;
  size-adjust: 85%;
}

@font-face {
  font-family: 'EB Garamond Fallback';
  src: local('Palatino Linotype Italic'), local('Palatino Linotype');
  font-style: italic;
  font-weight: 400 700;
  size-adjust: 85%;
}

:root {
  --ink:    oklch(0.22 0 0);
  --ink-2:  oklch(0.47 0 0);
  --rule:   oklch(0.77 0 0);
  --paper:  oklch(0.97 0 0);
  --paper-2:oklch(0.94 0 0);
  --accent: var(--ink);

  --measure-about: 45rem;
  --measure-project: 50rem;
  --measure-index: 76rem;

  --page-pad: 3rem 2.5rem 3.5rem;
  --page-pad-mobile: 2rem 1.5rem 2.5rem;
  --page-pad-index: 5rem 3.5rem 3.5rem;
  --page-pad-index-mobile: 2rem 1.5rem 2.5rem;

  --sep-pad: 0 0.5rem;
  --sep-pad-wide: 0 0.75rem;
  --caption-color: var(--ink-2);

  --index-column-gap: 3rem;
  --index-stack-gap: 3rem;
  --index-image-text-gap: 0.75rem;
  --index-title-max: 2rem;

  --serif: 'EB Garamond', 'EB Garamond Fallback', 'Iowan Old Style', Palatino, serif;
  --serif-sc: 'EBGaramondSC', 'EB Garamond', 'EB Garamond Fallback', 'Iowan Old Style', Palatino, serif;
  --sans:  ui-sans-serif, system-ui, -apple-system, sans-serif;
  --mono:  ui-monospace, SFMono-Regular, Menlo, monospace;
}

@media (prefers-color-scheme: dark) {
  :root {
      --ink:    oklch(0.95 0 0);
      --ink-2:  oklch(0.63 0 0);
      --rule:   oklch(0.37 0 0);
      --paper:  oklch(0.18 0 0);
      --paper-2:oklch(0.22 0 0);
      --accent: oklch(0.86 0 0);
  }
}

/* === Global Resets ======================================================== */
* { box-sizing: border-box; }
html, body { margin: 0; }

body {
  background: var(--paper);
  color: var(--ink);
  font-family: var(--serif);
  font-size: 1.25rem;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

img { display: block; max-width: 100%; height: auto; background: var(--paper-2); }
a { color: inherit; }

a:focus-visible, button:focus-visible, [tabindex]:focus-visible {
  outline: 1.5px solid var(--ink); outline-offset: 2px;
}

mark, ins { color: var(--ink); padding: 0 0.12em; border-radius: 1px; }
mark { background-color: var(--paper-2); }
ins { background: none; text-decoration: underline; text-decoration-thickness: 1px; text-underline-offset: 0.14em; text-decoration-color: var(--ink-2); }

.sc { font-family: var(--serif-sc); letter-spacing: 0.04em; }

/* === Layout Shells ======================================================== */
.page { position: relative; margin: 0 auto; }
.index-page { max-width: var(--measure-index); padding: var(--page-pad-index); }
.about-page { max-width: var(--measure-about); padding: var(--page-pad); }
.project-page { max-width: var(--measure-project); padding: var(--page-pad); }

@media (max-width: 40rem) {
  .index-page { padding: var(--page-pad-index-mobile); }
  .about-page { padding: var(--page-pad-mobile); }
  .project-page {
    padding: 1.5rem 1.5rem 2.5rem;
  }
}

/* === Universal Utilities ================================================== */
.topbar { position: absolute; top: 0.5rem; right: 2.5rem; z-index: 2; margin: 0; padding: 0; font-family: var(--serif); font-style: italic; font-size: 1.1rem; color: var(--ink-2); }
.topbar a { text-decoration: none; padding: 0.5rem; margin: -0.5rem; display: inline-block; position: relative; }
.topbar a:hover, .topbar a:focus-visible { color: var(--ink); }

@media (max-width: 40rem) {
  .topbar { top: 0.75rem; right: 1rem; }
  .project-page .topbar { top: 0; right: 1.5rem; line-height: 1.5rem; }
  .project-page .topbar a { padding-block: 0; margin-block: 0; }
}

.contact { margin-top: 2rem; padding-top: 0; text-align: center; font-size: 1.25rem; color: var(--ink-2); }
.contact a { text-decoration: none; padding: 0.5rem; margin: -0.5rem; display: inline-block; }
.contact a:hover, .contact a:focus-visible { color: var(--ink); }
.contact .sep { padding: var(--sep-pad-wide); }

.fleuron { text-align: center; font-size: 1.875rem; color: var(--ink-2); margin: 2.5rem 0 1.5rem; line-height: 1; }
.fleuron svg { height: 0.8em; width: auto; }

/* === Index Page Specifics ================================================= */
.mast { text-align: center; padding: 0.5rem 0 2rem; }
.mast h1 { font-weight: 400; font-style: normal; font-size: clamp(2.375rem, 5.5vw, 4.5rem); margin: 0; line-height: 1.03; letter-spacing: 0; }
.mast .contact { margin-top: 0.75rem; font-family: var(--serif); font-size: 1.25rem; color: var(--ink-2); }

/* CSS-only visible filters; JS only enhances hidden tag URLs. */
.filter-wrap > input[type="radio"] {
  position: absolute;
  width: 1px;
  height: 1px;
  margin: -1px;
  padding: 0;
  overflow: hidden;
  clip: rect(0,0,0,0);
  white-space: nowrap;
  border: 0;
}

.index-nav {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 0.75rem 2rem;
  margin: 1rem 0 2rem;
  color: var(--ink-2);
  font-size: 1.25rem;
  text-align: center;
}

.index-nav label {
  cursor: pointer;
  user-select: none;
  padding-bottom: 0.08em;
  border-bottom: 1px solid transparent;
  transition: color 0.15s, border-color 0.15s;
}

.index-nav label:hover { color: var(--ink); }

/* If :has() is unavailable, hide the controls and show the complete portfolio. */
@supports not selector(:has(*)) {
  .index-nav { display: none; }
}

/* Component-scoped filter state: markup can change without sibling-selector coupling. */
.filter-wrap:has(#f-all:checked) label[for="f-all"],
.filter-wrap:has(#f-design:checked) label[for="f-design"],
.filter-wrap:has(#f-cine:checked) label[for="f-cine"],
.filter-wrap:has(#f-side:checked) label[for="f-side"] {
  color: var(--ink);
  border-bottom-color: var(--ink);
}

.filter-wrap:has(#f-all:focus-visible) label[for="f-all"],
.filter-wrap:has(#f-design:focus-visible) label[for="f-design"],
.filter-wrap:has(#f-cine:focus-visible) label[for="f-cine"],
.filter-wrap:has(#f-side:focus-visible) label[for="f-side"] {
  outline: 1.5px solid var(--ink);
  outline-offset: 3px;
}

.filter-wrap:has(#f-design:checked) .entry:not(.cat-design),
.filter-wrap:has(#f-cine:checked) .entry:not(.cat-cinematography),
.filter-wrap:has(#f-side:checked) .entry:not(.cat-side-project) {
  display: none;
}

/* Used only by progressive-enhancement hash filters such as #filter=star-trek. */
.entry.is-filtered-out {
  display: none !important;
}

.entry .thumb-link {
  display: block;
  order: -1;
  width: 100%;
}

.entries {
  display: block;
  columns: 2;
  column-gap: var(--index-column-gap);
  list-style: none;
  margin: 0;
  padding: 0;
}

@supports (display: grid-lanes) {
  .entries {
    display: grid-lanes;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: var(--index-stack-gap) var(--index-column-gap);
    flow-tolerance: 0;
    columns: auto;
  }
}

.entry {
  display: inline-flex;
  flex-direction: column;
  width: 100%;
  min-width: 0;
  margin: 0 0 var(--index-stack-gap);
  padding: 0;
  position: relative;
  vertical-align: top;
  break-inside: avoid;
}
.entry:last-child { margin-bottom: 0; }

@supports (display: grid-lanes) {
  .entry {
    display: flex;
    width: auto;
    margin: 0;
    break-inside: auto;
  }
}

.entry .year { display: none; }
.entry a.title-link { text-decoration: none; color: inherit; display: block; }
.entry .kicker { display: block; font-style: italic; font-size: 1.2rem; color: var(--ink-2); margin-bottom: 0.5rem; text-transform: capitalize; }
.entry .kicker .dot { padding: 0 0.35rem; }
.entry .title { font-size: clamp(1.77rem, 2vw + 0.77rem, var(--index-title-max)); font-weight: 400; line-height: 1.1; margin: 0; letter-spacing: -0.005em; }
.entry .title cite { font-style: italic; }
.entry a.title-link:hover .title, .entry a.title-link:focus-visible .title { text-decoration: underline; text-decoration-thickness: 1px; text-underline-offset: 3px; }

.entry .deck { color: var(--ink-2); margin: 0.5rem 0 0; font-size: 1.3rem; line-height: 1.45; }
.entry .meta { display: none; }
.entry .meta .dot { padding: 0 0.4rem; }

.entry .thumb { order: -1; width: 100%; height: auto; margin-bottom: var(--index-image-text-gap); object-fit: cover; }

.entry > .browser-window {
  order: -1;
  margin-bottom: var(--index-image-text-gap);
}
.entry .browser-window .thumb {
  order: initial;
  margin: 0;
}
.ar-anamorphic { aspect-ratio: 2.39 / 1; }
.ar-cinema     { aspect-ratio: 16 / 9; }
.ar-landscape  { aspect-ratio: 3 / 2; }
.ar-square     { aspect-ratio: 1 / 1; }
.ar-portrait   { aspect-ratio: 4 / 5; }
.ar-tall       { aspect-ratio: 3 / 4; }

.entries.js-masonry {
  position: relative;
  display: block;
  columns: auto;
}

.entries.js-masonry .entry {
  position: absolute;
  inset: 0 auto auto 0;
  width: calc((100% - var(--index-column-gap)) / 2);
  margin: 0;
}

footer { margin-top: 1.5rem; padding-top: 1.5rem; text-align: center; color: var(--ink-2); font-size: 1.2rem; }
footer .links { font-size: 1.25rem; margin-bottom: 1.5rem; }
footer .links a { text-decoration: none; margin: 0 0.75rem; padding: 0.5rem; display: inline-block; }
footer .links a:hover, footer .links a:focus-visible { color: var(--ink); }
footer .colophon { max-width: 38rem; margin: 0 auto; font-size: 1.2rem; color: var(--ink-2); }
footer .copy { margin-top: 2rem; font-size: 1.2rem; font-variant-numeric: oldstyle-nums; }

/* === About Page Specifics ================================================= */
.portrait { text-align: center; margin-bottom: 3rem; }
.portrait img { width: 12rem; height: auto; aspect-ratio: 4 / 5; margin: 0 auto; object-fit: cover; box-shadow: 0 0 0 1px var(--rule); background: #dcd4c2; }
.about-head { text-align: center; margin-bottom: 3rem; }
.about-head h1 { font-weight: 400; font-style: normal; font-size: 3.06rem; line-height: 1.04; margin: 0 0 0.75rem; }
.about-head .role { font-style: italic; font-size: 1.2rem; color: var(--ink-2); }
.socials { display: flex; justify-content: center; flex-wrap: wrap; gap: 2rem; margin: 0 0 3.5rem; font-size: 1.25rem; }
.socials a { color: var(--ink-2); text-decoration: none; padding: 0.5rem; margin: -0.5rem; display: inline-block; }
.socials a:hover, .socials a:focus-visible { color: var(--ink); }

/* === Project Article Specifics ============================================ */
.project-page .hero { margin: 0 0 1.5rem; }
.project-page .hero img { margin: 0 auto; }
.project-head { text-align: center; margin-bottom: 3rem; }
.project-head .kicker { font-style: italic; font-size: 1.125rem; color: var(--ink-2); margin-bottom: 0.5rem; text-transform: capitalize; }
.project-head h1 { font-weight: 400; font-size: clamp(2.06rem, 4.5vw, 2.93rem); line-height: 1.12; margin: 0 0 0.5rem; }
.project-head h1 cite { font-style: italic; }
.project-head .deck { font-size: 1.25rem; line-height: 1.45; margin: 0 auto 1rem; max-width: 32rem; }
.project-head .byline { font-style: italic; font-size: 1.125rem; color: var(--ink-2); font-variant-numeric: oldstyle-nums; }
.project-head .byline a { text-decoration: none; }
.project-head .byline a:hover, .project-head .byline a:focus-visible { color: var(--ink); }
.project-head .byline .sep { padding: var(--sep-pad); }

article { font-size: 1.375rem; line-height: 1.65; color: var(--ink); }
article p { margin: 0 0 1.5rem; hyphens: auto; }
@supports (text-wrap: pretty) { article p { text-wrap: pretty; } }
article a { text-decoration: underline; text-decoration-thickness: 1px; text-underline-offset: 3px; text-decoration-color: var(--ink); }
article a:hover, article a:focus-visible { text-decoration-thickness: 1.5px; }

.project-page.has-drop-cap article > p:first-of-type::first-letter {
  float: left;
  font-family: var(--serif);
  font-weight: 500;
  font-style: normal;
  font-variant: normal;
  font-size: 4.68rem;
  line-height: 0.85;
  margin: 0.1em 0.14em 0 0;
  color: var(--ink);
}

.leadin {
  font-family: var(--serif-sc);
  letter-spacing: 0.045em;
}

article h2, article h3 { font-weight: 400; letter-spacing: 0; text-align: left; }
article h2 { font-size: 1.68rem; line-height: 1.25; margin: 3rem 0 1rem; }
article h3 { font-size: 1.50rem; line-height: 1.3; margin: 2.5rem 0 0.75rem; }

.project-page.has-drop-cap article h2 { font-size: 1.93rem; text-align: center; }
.project-page.has-drop-cap article h3 { font-size: 1.56rem; }

article del { color: var(--ink-2); text-decoration-color: var(--ink-2); }
article blockquote { margin: 2.5rem 0 2.5rem 2.5rem; padding: 0; font-style: italic; color: var(--ink-2); font-size: 1.43rem; line-height: 1.55; }
article blockquote p { margin: 0 0 0.75rem; }
article blockquote footer, article blockquote cite {
  display: block;
  margin-top: 0.75rem;
  padding-top: 0;
  text-align: left;
  font-style: italic;
  font-size: 1.2rem;
}
article blockquote footer::before, article blockquote cite::before { content: "— "; }

article table { width: 100%; border-collapse: collapse; margin: 2.5rem 0; font-size: 1.2rem; font-variant-numeric: oldstyle-nums tabular-nums; }
article thead tr { border-top: 1px solid var(--ink-2); border-bottom: 1px solid var(--rule); }
article tbody tr:last-child { border-bottom: 1px solid var(--ink-2); }
article th { text-align: left; font-weight: 400; font-style: italic; padding: 0.5rem 1rem 0.5rem 0; color: var(--ink-2); }
article td { padding: 0.5rem 1rem 0.5rem 0; vertical-align: top; }

article dl { margin: 1.5rem 0; }
article dt { font-style: italic; margin-top: 1rem; }
article dd { margin: 0.25rem 0 0 1.75rem; }

article figure { margin: 2.5rem 0; }
article figure img,
article figure video,
article .motion-video { width: 100%; height: auto; display: block; background: var(--paper-2); }
article .motion-video { object-fit: cover; }
article figcaption,
.figure-caption {
  text-align: center; color: var(--caption-color); font-style: italic;
  margin: 0.75rem auto 0; font-size: 1.2rem; line-height: 1.45;
}

/* Markdown-native figures.
   Authoring contract:
   ![Alt](image_1000x782.avif "Caption")
   ::: figure-pair / ::: figure-rich / ::: gallery

   Eleventy marks/splits paragraphs inside figure containers into:
   <div class="figure-media">...</div> and/or <figcaption class="figure-caption">...</figcaption>.
   Captions do not need a blank line after media; the renderer splits leading media from trailing prose.
*/
article figure > p { margin: 0; }
article figure > figure { margin: 0; }
article figure > figure img,
article figure > figure video { width: 100%; }

.figure-media { margin: 0; }
.figure-media > img,
.figure-media > video,
.figure-media > .motion-video { width: 100%; height: auto; display: block; }

.figure-pair > .figure-media {
  display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 1rem; align-items: start;
}

.figure-pair > .figure-caption,
.figure-rich > .figure-caption,
.gallery > .figure-caption { max-width: 36rem; }

.figure-rich > .figure-media { margin-bottom: 0.5rem; }
.figure-rich > .figure-caption { margin-top: 0; }

/* === Static web-app screenshot component ================================= */

.browser-window {
  position: relative;
  display: block;
  width: 100%;
  margin: 0;
  overflow: hidden;
  background: var(--paper);
  border: 1px solid var(--rule);
  container-type: inline-size;
}

.browser-window__bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  min-width: 0;
  min-height: 2rem;
  padding: 0.35rem 0.75rem;
  border-bottom: 1px solid var(--rule);
  background: var(--paper-2);
  color: var(--ink-2);
  font-family: var(--mono);
  font-size: clamp(0.75rem, 2.5cqi, 0.875rem);
  line-height: 1.2;
}

.browser-window__address {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.browser-window__protocol { opacity: 0.5; }

.browser-window__tag {
  flex: none;
  margin-left: 0.5rem;
  padding-left: 0.5rem;
  border-left: 1px solid var(--rule);
  color: var(--ink-2);
  font-family: var(--serif-sc);
  font-size: clamp(0.75rem, 2.2cqi, 0.8125rem);
  letter-spacing: 0.06em;
  line-height: 1.1;
  text-transform: lowercase;
}

.browser-window__viewport,
.browser-window__link {
  display: block;
  width: 100%;
  color: inherit;
  text-decoration: none;
}

.browser-window img {
  display: block;
  width: 100%;
  height: auto;
  margin: 0;
  background: var(--paper-2);
}

.browser-window__link:hover img,
.browser-window__link:focus-visible img {
  filter: brightness(1.03);
}

.browser-window__link:focus-visible {
  outline: 1.5px solid var(--ink);
  outline-offset: -3px;
}

.browser-window--thumbnail .browser-window__bar {
  gap: 0.5rem;
  padding: 0.35rem 0.6rem;
}

.browser-window--thumbnail .browser-window__tag {
  margin-left: 0.25rem;
  padding-left: 0.4rem;
  letter-spacing: 0.05em;
}

@container (max-width: 20rem) {
  .browser-window__protocol { display: none; }
  .browser-window__bar { padding-inline: 0.55rem; }
}

@container (max-width: 14rem) {
  .browser-window__tag { display: none; }
}

.browser-figure { margin: 2.5rem 0; }
.browser-figure .figure-caption { max-width: 36rem; }

.browser-gallery {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(18rem, 100%), 1fr));
  gap: 1.5rem;
  align-items: start;
  margin: 2.5rem 0;
}

.browser-gallery > .browser-figure { margin: 0; }

.gallery > .figure-media {
  display: grid; grid-template-columns: repeat(auto-fit, minmax(min(9rem, 100%), 1fr));
  gap: 1rem; align-items: start;
}
.gallery figcaption { font-size: 1.2rem; }

figure.has-caption { margin-bottom: 0.5rem; }
figure.has-caption + p { text-align: center; font-style: italic; color: var(--caption-color); font-size: 1.2rem; max-width: 36rem; margin: 0 auto 2.5rem; }

.footnote-ref { font-size: 0.72em; vertical-align: super; line-height: 0; text-decoration: none; color: var(--ink-2); padding: 0 0.05em; font-variant-numeric: oldstyle-nums; }
.footnotes { margin: 2.5rem 0 0; font-size: 1.2rem; }
.footnotes::before { content: "Notes"; display: block; margin-bottom: 0.75rem; font-style: italic; color: var(--ink-2); }
.footnotes ol { list-style: none; counter-reset: fn; padding: 0; margin: 0; }
.footnotes li { counter-increment: fn; margin-bottom: 0.75rem; padding-left: 2rem; position: relative; }
.footnotes li::before { content: counter(fn) "."; position: absolute; left: 0; width: 1.5rem; text-align: right; font-variant-numeric: oldstyle-nums; }
.footnote-backref { margin-left: 0.5em; font-size: 0.85em; text-decoration: none; }

.correspondence { margin: 2.5rem 0; font-size: 1.25rem; }
.correspondence > header { font-style: italic; color: var(--ink-2); margin-bottom: 0.5rem; font-size: 1.2rem; font-variant-numeric: oldstyle-nums; }
.correspondence > header a { text-decoration: underline; text-decoration-color: var(--rule); text-underline-offset: 2px; }
.correspondence > .body p { margin: 0 0 0.75rem; }
.correspondence.reply > .prior { margin-bottom: 1rem; padding-left: 1.25rem; border-left: 1px solid var(--rule); color: var(--ink-2); }
.correspondence.reply > .response { padding-left: 1.75rem; position: relative; }
.correspondence.reply > .response::before { content: "↳"; position: absolute; left: 0; color: var(--rule); }
.correspondence > .quoted { margin-top: 1rem; padding-left: 1.25rem; border-left: 1px solid var(--rule); color: var(--ink-2); font-size: 1.2rem; }

.aside-link {
  display: block;
  margin: 3rem 0 3rem 3rem;
  padding: 0;
  text-decoration: none;
}

.aside-link .label {
  font-family: var(--serif-sc);
  letter-spacing: 0.045em;
  color: var(--ink-2);
  font-size: 1.2rem;
  display: block;
  margin-bottom: 0.5rem;
  font-style: normal;
  text-transform: lowercase;
}

.aside-link .ttl {
  position: relative;
  display: block;
  font-size: 1.56rem;
  line-height: 1.25;
}

.aside-link .aside-manicule {
  position: absolute;
  left: -2.5rem;
  top: 0.35em;
  width: 1em;
  height: auto;
  color: var(--ink-2);
  transition: color 0.15s ease;
}

.aside-link:hover .aside-manicule,
.aside-link:focus-visible .aside-manicule {
  color: var(--ink);
}

.aside-link .deck {
  color: var(--ink-2);
  font-size: 1.25rem;
  margin-top: 0.25rem;
}

.aside-link:hover .ttl {
  text-decoration: underline;
  text-underline-offset: 3px;
  text-decoration-thickness: 1.5px;
}
.asterism { text-align: center; color: var(--ink-2); margin: 2.5rem 0; letter-spacing: 0.6em; padding-left: 0.6em; font-size: 1.125rem; }

.pano { margin: 2.5rem 0; width: 100%; aspect-ratio: 2 / 1; background: linear-gradient(90deg, #e5e5e5 0%, #d0d0d0 50%, #e5e5e5 100%); position: relative; overflow: hidden; }
.pano-launch { border: 0; padding: 0; width: 100%; height: 100%; display: block; position: relative; overflow: hidden; background: var(--paper-2); color: white; cursor: pointer; font: inherit; }
.pano-launch img { width: 100%; height: 100%; display: block; object-fit: cover; transition: filter 160ms ease; }
.pano-launch:hover img { filter: brightness(1.08); }
.pano-launch:focus-visible { outline: 2px solid var(--ink); outline-offset: -4px; }
.pano-launch-label { position: absolute; inset: 0; display: flex; flex-direction: column; gap: 0.45rem; align-items: center; justify-content: center; font-style: italic; text-shadow: 0 1px 4px rgba(0, 0, 0, 0.8); }
.pano-launch-icon { width: 5rem; height: 5rem; display: flex; align-items: center; justify-content: center; border-radius: 50%; background: rgba(20, 18, 16, 0.72); font-style: normal; font-size: 1.15rem; letter-spacing: -0.04em; }
.pano-viewer { position: absolute; inset: 0; }
.pano-scene-picker { position: absolute; z-index: 3; left: 50%; bottom: 0.75rem; transform: translateX(-50%); display: flex; gap: 0.35rem; padding: 0.3rem; border-radius: 2rem; background: rgba(20, 18, 16, 0.72); }
.pano-scene-picker button { border: 0; border-radius: 1.5rem; padding: 0.35rem 0.75rem; background: transparent; color: white; font: inherit; font-size: 1rem; cursor: pointer; }
.pano-scene-picker button[aria-pressed="true"] { background: white; color: #141210; }
.pano-scene-picker button:focus-visible { outline: 2px solid white; outline-offset: 1px; }
.pano-figure { margin: 2.5rem 0; }
.pano-figure .pano { margin: 0; }
.pano-figure figcaption,
.pano + .pano-cap { text-align: center; font-style: italic; color: var(--caption-color); font-size: 1.2rem; margin-top: 0.75rem; margin-bottom: 0; }

.video { margin: 2.5rem 0; }
.video .frame { position: relative; width: 100%; aspect-ratio: 16 / 9; overflow: hidden; display: block; }
.video .frame:hover img { filter: brightness(1.08); }
.video .frame iframe { position: absolute; top: 0; left: 0; width: 100%; height: 100%; border: 0; }
.video .play { position: absolute; top: 50%; left: 50%; transform: translate(-50%, -50%); width: 5rem; height: 5rem; display: flex; align-items: center; justify-content: center; background: rgba(20, 18, 16, 0.7); color: white; border-radius: 50%; }
.video .play::before { content: ""; width: 0; height: 0; border-left: 1.25rem solid white; border-top: 0.75rem solid transparent; border-bottom: 0.75rem solid transparent; margin-left: 0.25rem; }
.video .meta { position: absolute; bottom: 0.75rem; right: 0.75rem; background: rgba(20,18,16,0.7); color: white; font-style: italic; font-size: 1.06rem; padding: 0.25rem 0.5rem; }

article code { font-family: var(--mono); font-size: 0.82em; background: var(--paper-2); padding: 0.1em 0.25em; border-radius: 1px; }
article pre { font-family: var(--mono); font-size: 1.06rem; line-height: 1.55; background: var(--paper-2); padding: 1rem 1.25rem; overflow-x: auto; margin: 2rem 0; }

.credits { margin: 2.5rem 0; display: grid; grid-template-columns: 1fr 1fr; column-gap: 1.5rem; row-gap: 0.5rem; font-size: 1.25rem; line-height: 1.45; }
.credits .role { font-style: italic; text-align: right; }

.pn { display: grid; grid-template-columns: 1fr 1fr; gap: 1.5rem; margin-top: 3.5rem; padding-top: 1.5rem; border-top: 1px solid var(--rule); font-size: 1.2rem; }
.project-page.has-drop-cap .pn { margin-top: 2.5rem; padding-top: 0; border-top: 0; }
.pn a { color: var(--ink-2); text-decoration: none; display: block; padding: 0.5rem; margin: -0.5rem; }
.pn a:hover { color: var(--ink); }
.pn .lbl { display: block; margin-bottom: 0.25rem; font-style: italic; }
.pn .ttl { font-size: 1.3rem; color: var(--ink); }
.pn .next { text-align: right; }

/* === Responsive Breakpoints =============================================== */
@media (max-width: 52rem) {
  .page { padding-left: 2.5rem; padding-right: 2.5rem; }
  .index-nav { gap: 0.5rem 1rem; }
  .entries { columns: 1; }

  .entries.js-masonry {
    height: auto !important;
  }

  .entries.js-masonry .entry {
    position: relative;
    width: 100%;
    margin: 0 0 var(--index-stack-gap);
    transform: none !important;
  }

  @supports (display: grid-lanes) {
    .entries { grid-template-columns: 1fr; }
  }
}

@media (max-width: 40rem) {
  .page { padding-left: 1.5rem; padding-right: 1.5rem; }
  .entry .kicker { margin-bottom: 0.25rem; }
  .entry .deck { font-size: 1.25rem; margin-top: 0.25rem; }
}

@media (max-width: 30rem) {
  .mast .contact, .contact { display: flex; flex-direction: column; gap: 0.25rem; }
  .mast .contact .sep, .contact .sep { display: none; }
  footer .links { display: flex; flex-wrap: wrap; justify-content: center; gap: 0.5rem 1.25rem; }
  footer .links a { margin: 0; }

  .portrait img { width: 9.5rem; }
  .about-head h1 { font-size: 2.5rem; }
  .socials { gap: 1rem 1.5rem; }

  article { font-size: 1.3rem; }
  .project-head h1 { font-size: 1.93rem; }
  .project-head .deck { font-size: 1.25rem; }
  article blockquote { margin: 2rem 0; padding-inline: 0.75rem; }
  .figure-pair > .figure-media { grid-template-columns: 1fr; }
  .credits { grid-template-columns: 1fr; row-gap: 0.1rem; }
  .credits .role { text-align: left; margin-top: 0.5rem; }
  .pn { gap: 1rem; }
  .pn a { overflow-wrap: anywhere; }
}

/* === Print Styles ========================================================= */
@media print {
  body { background: #fff; color: #000; font-size: 12pt; }
  .page { max-width: none; padding: 0; }
  .topbar, .socials, .fleuron, footer .links, .filter-wrap > input[type="radio"], .index-nav, .pn, .video .play, .video .meta { display: none; }
  .browser-window { border-color: #999; }
  .browser-window__bar { display: none; }

  .mast { padding: 0 0 1.5rem; border-bottom: 1px solid #000; }
  .mast .contact { display: none; }

  .entries { display: block; }
  .entry { display: block; width: auto; margin: 0; padding: 1rem 0; break-inside: avoid; }
  .entries.js-masonry { height: auto !important; }
  .entries.js-masonry .entry { position: static; width: auto; transform: none !important; }
  .entry + .entry { border-top: 1px solid #999; }
  .entry .year, .entry .meta { display: block; }
  .entry .thumb { display: none; }

  .portrait { margin-bottom: 1.5rem; }
  .portrait img { width: 8rem; box-shadow: 0 0 0 1px #999; }

  article { font-size: 12pt; line-height: 1.45; }
  article a { color: #000; text-decoration: underline; text-decoration-color: #000; }
  article pre, article code { background: #f1f1f1; }
  img, figure, table, blockquote { break-inside: avoid; }

  .contact { margin-top: 1.5rem; padding-top: 0; }
  footer { margin-top: 2rem; padding-top: 1rem; border-top: 1px solid #999; }
}
