/* Jack Nicholson — portfolio styles.
   Rebuilt from the Framer site. Breakpoints match Framer's:
     phone  < 810px
     tablet 810px – 1199px
     desktop 1200px – 1919px (the default below)
     large  ≥ 1920px
*/

@font-face { font-family: "Inter Display"; src: url("../fonts/InterDisplay-400.woff2") format("woff2"); font-weight: 400; font-style: normal; font-display: swap; }
@font-face { font-family: "Inter Display"; src: url("../fonts/InterDisplay-500.woff2") format("woff2"); font-weight: 500; font-style: normal; font-display: swap; }
@font-face { font-family: "Inter Display"; src: url("../fonts/InterDisplay-600.woff2") format("woff2"); font-weight: 600; font-style: normal; font-display: swap; }
@font-face { font-family: "Inter Display"; src: url("../fonts/InterDisplay-700.woff2") format("woff2"); font-weight: 700; font-style: normal; font-display: swap; }
@font-face { font-family: "Inter"; src: url("../fonts/Inter-400.woff2") format("woff2"); font-weight: 400; font-style: normal; font-display: swap; }
@font-face { font-family: "Inter"; src: url("../fonts/Inter-600.woff2") format("woff2"); font-weight: 600; font-style: normal; font-display: swap; }
@font-face { font-family: "Satoshi"; src: url("../fonts/Satoshi-400.woff2") format("woff2"); font-weight: 400; font-style: normal; font-display: swap; }
@font-face { font-family: "Satoshi"; src: url("../fonts/Satoshi-500.woff2") format("woff2"); font-weight: 500; font-style: normal; font-display: swap; }
@font-face { font-family: "Instrument Serif"; src: url("../fonts/InstrumentSerif-400i.woff2") format("woff2"); font-weight: 400; font-style: italic; font-display: swap; }

:root {
  --white: #fff;
  --black: #000;
  --muted: #ffffffa6;      /* white at 65% */
  --line: #ffffff1a;       /* white at 10% */
  --chip: #0d0d0d;
  --label: #b8b8b8;
  --desc: #858585;
  --display: "Inter Display", "Inter", system-ui, sans-serif;
  --inter: "Inter", system-ui, sans-serif;
  --satoshi: "Satoshi", "Inter", system-ui, sans-serif;
  --serif: "Instrument Serif", Georgia, serif;
  /* Springs. app.js replaces these with exact spring curves where the browser supports linear(). */
  --spring-snappy: cubic-bezier(0.25, 1, 0.5, 1);
  --spring-snappy-ms: 600ms;
  --ease-link: cubic-bezier(1, 0.17, 0.16, 0.88);
}

*, *::before, *::after { box-sizing: border-box; }
html { background: var(--black); -webkit-text-size-adjust: 100%; text-size-adjust: 100%; }
html.lenis, html.lenis body { height: auto; }
.lenis.lenis-smooth [data-lenis-prevent] { overscroll-behavior: contain; }
.lenis.lenis-stopped { overflow: clip; }
.lenis.lenis-smooth iframe { pointer-events: none; }
body {
  margin: 0;
  background: var(--black);
  color: var(--white);
  font-family: var(--inter);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
}
h1, h2, h3, h4, p { margin: 0; font-weight: inherit; }
a { color: inherit; text-decoration: none; }
img { display: block; max-width: none; }
button { font: inherit; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

/* Text styles (Framer presets) --------------------------------------------- */
.t-label { font: 400 15px/1.5 var(--inter); letter-spacing: -0.02em; color: var(--muted); text-align: center; }
.t-small { font: 500 14px/1.5 var(--display); letter-spacing: -0.02em; color: var(--muted); }
.t-h4 { font: 600 24px/1.4 var(--display); color: var(--white); }
.t-body { font: 400 18px/1.6 var(--display); color: var(--white); }
.t-h3 { font: 500 36px/1.2 var(--satoshi); letter-spacing: -0.01em; color: var(--white); }

/* Text that stretches to fill its box, like Framer's "fit" text. --vbw/--vbh is the
   box's shape and --fs the font size it was designed at. */
.fit { display: block; container-type: inline-size; width: 100%; aspect-ratio: var(--vbw) / var(--vbh); position: relative; }
.fit > .fit-text { display: block; font-size: calc(100cqw * var(--fs) / var(--vbw)); line-height: 1; white-space: nowrap; }

/* Page --------------------------------------------------------------------- */
.page { position: relative; display: flex; flex-direction: column; align-items: center; background: var(--black); overflow: clip; }
.home { width: 100%; display: flex; flex-direction: column; align-items: center; background: var(--black); }

/* Navigation --------------------------------------------------------------- */
.nav {
  position: fixed; top: 0; left: 0; right: 0; height: 60px; z-index: 5;
  mix-blend-mode: difference; pointer-events: none;
}
.nav-bar { display: flex; align-items: center; justify-content: center; gap: 10px; height: 60px; padding: 0 20px; }
.nav-content { position: relative; flex: 1 0 0; width: 1px; height: 100%; display: flex; align-items: center; justify-content: space-between; }
.nav-title {
  pointer-events: auto; z-index: 1; color: var(--white);
  font-family: var(--display); font-weight: 600; text-transform: uppercase;
  transform-origin: 0 0;
}
.nav-title .fit-text { text-align: center; }
/* Framer centres the name together with an empty 10px slot, which nudges it 5px left. */
.nav[data-state="big"] .nav-title { position: absolute; left: -5px; right: 5px; top: 70px; }
.nav[data-state="small"] .nav-title { position: relative; container-type: normal; aspect-ratio: auto; width: auto; }
.nav[data-state="small"] .nav-title .fit-text { font-size: 20px; text-align: left; }
.nav-links { display: flex; align-items: center; justify-content: space-between; flex: 1 0 0; width: 1px; overflow: hidden; }
.nav[data-state="small"] .nav-links { flex: none; width: auto; justify-content: flex-start; gap: 32px; }
.nav-link {
  pointer-events: auto; display: flex; align-items: center; gap: 6px; height: 34px; padding: 6px 12px;
  font: 500 16px/1.5 var(--display); text-transform: uppercase; white-space: nowrap;
  color: var(--muted); transition: color var(--spring-snappy-ms) var(--spring-snappy);
}
.nav-link:hover, .nav-link:focus-visible { color: var(--white); }
@media (max-width: 809.98px) {
  .nav[data-state="small"] .nav-content { overflow: hidden; }
  .nav[data-state="small"] .nav-links { flex: 0 1 auto; min-width: 0; gap: 0; }
  /* Smaller words once the nav shrinks, so all four links fit beside the name on a phone. */
  .nav[data-state="small"] .nav-title .fit-text { font-size: 15px; }
  .nav[data-state="small"] .nav-link { padding: 6px 5px; font-size: 12px; }
}
@media (max-width: 379.98px) {
  .nav[data-state="small"] .nav-title .fit-text { font-size: 14px; }
  .nav[data-state="small"] .nav-link { padding: 6px 3px; font-size: 11px; }
}

/* Hero ---------------------------------------------------------------------- */
.hero { position: relative; z-index: 1; width: 100%; height: 100vh; padding: 60px 40px; display: flex; flex-direction: column; align-items: center; gap: 24px; overflow: hidden; }
.hero-head { position: relative; z-index: 1; width: 100%; display: flex; flex-direction: column; align-items: center; justify-content: center; }
.hero-main { position: relative; z-index: 1; width: 100%; height: 100vh; padding-bottom: 160px; display: flex; flex-direction: column; align-items: center; }
.hero-top { width: 100%; height: 100%; display: flex; flex-direction: column; align-items: center; justify-content: space-between; }
.hero-trigger { width: 100%; height: 16vh; flex: none; }
.hero-copy { flex: 1 0 0; height: 1px; width: 100%; padding-bottom: 60px; display: flex; flex-direction: column; align-items: center; }
.tagline {
  flex: 1 0 0; width: 540px; max-width: 540px; height: 1px;
  display: flex; align-items: center; justify-content: center; text-align: center;
  font: 600 1.5rem/1.5em var(--display); letter-spacing: -0.02em; color: var(--white);
}
.tagline em { font-family: var(--serif); font-style: italic; font-weight: 400; }
.scroll-hint { flex: none; width: 100%; max-width: 640px; height: 38px; display: flex; align-items: center; justify-content: center; gap: 16px; }
.scroll-hint .t-label { white-space: nowrap; }
.scroll-hint-line { flex: 1 0 0; width: 1px; height: 1px; background: var(--white); opacity: 0.1; }
.scroll-hint-icon { flex: none; width: 25px; height: 100%; display: flex; align-items: center; }
.scroll-hint-icon svg { width: 25px; height: 25px; fill: var(--white); display: block; }
.mouse-bob { display: block; animation: mouse-bob 2s linear 1.1s infinite alternate; }
@keyframes mouse-bob { from { transform: translateY(0); } to { transform: translateY(10px); } }
.hero-bg { position: absolute; inset: 0; z-index: 0; overflow: hidden; }
.shader-wrap { position: absolute; left: 0; right: 0; top: 0; bottom: -198px; z-index: 1; }
.shader { position: relative; width: 100%; height: 100%; overflow: hidden; }
.shader canvas { display: block; width: 100%; height: 100%; }
.shader-noise { position: absolute; inset: 0; background-repeat: repeat; pointer-events: none; }
.hero-fade { position: absolute; inset: 0; z-index: 1; background: linear-gradient(180deg, rgba(4, 4, 4, 0) 55%, #000 100%); opacity: 0; }
@media (max-width: 809.98px) {
  .hero { z-index: 2; padding: 120px 18px 0; }
  .scroll-hint { display: none; }
}
@media (min-width: 810px) and (max-width: 1199.98px) {
  .hero-head { gap: 40px; }
}

/* Moving film grain ---------------------------------------------------------- */
.grain { position: absolute; left: 0; top: -156px; bottom: 0; width: 100%; z-index: 3; opacity: 0.05; pointer-events: none; }
.grain-clip { position: relative; width: 100%; height: 100%; overflow: hidden; }
.grain-layer {
  position: absolute; inset: -200%; width: 400%; height: 400%; opacity: 0.8;
  background-repeat: repeat; /* size is the image's own, as in Framer */
  animation: grain 8s steps(10, jump-start) infinite;
}
@keyframes grain {
  0%      { transform: translate(0, 0); }
  11.111% { transform: translate(-5%, -10%); }
  22.222% { transform: translate(-15%, 5%); }
  33.333% { transform: translate(7%, -25%); }
  44.444% { transform: translate(-5%, 25%); }
  55.556% { transform: translate(-15%, 10%); }
  66.667% { transform: translate(15%, 0); }
  77.778% { transform: translate(0, 15%); }
  88.889% { transform: translate(3%, 35%); }
  100%    { transform: translate(-10%, 10%); }
}

/* Selected works -------------------------------------------------------------- */
.works { position: relative; width: 100%; background: var(--white); padding: 20px 0; display: flex; flex-direction: column; overflow: hidden; }
.works-title { width: 100%; padding: 0 20px; overflow: hidden; }
.works-title .fit { --vbw: 1160; --vbh: 130; --fs: 130.58; }
.works-title .fit-text { font-family: var(--display); font-weight: 600; text-transform: uppercase; text-align: center; color: var(--black); }
@media (max-width: 1199.98px) { .works-title .fit { --vbh: 135; } }

/* Filters under the heading, the short list's "See all work", and the work page. */
.card[hidden] { display: none; }
.work-filters { position: relative; z-index: 4; display: flex; flex-wrap: wrap; justify-content: center; gap: 8px; padding: 12px 20px 28px; }
.work-filter { display: inline-flex; align-items: baseline; gap: 8px; padding: 9px 18px; border-radius: 100px; border: 1px solid rgba(0, 0, 0, 0.14); background: transparent; color: var(--black); font: 500 15px/1.3 var(--display); letter-spacing: -0.02em; cursor: pointer; transition: background-color 0.25s, color 0.25s, border-color 0.25s; }
.work-filter:hover { border-color: rgba(0, 0, 0, 0.4); }
.work-filter:focus-visible { outline: 2px solid var(--black); outline-offset: 2px; }
.work-filter[aria-pressed="true"] { background: var(--black); border-color: var(--black); color: var(--white); }
.work-filter-count { font: 400 12px/1 var(--inter); opacity: 0.55; font-variant-numeric: tabular-nums; }
.works-list { display: flex; flex-direction: column; width: 100%; }
.works-more { position: relative; z-index: 4; display: flex; justify-content: center; padding: 28px 20px 48px; }
.see-more { display: inline-flex; align-items: center; gap: 12px; padding: 16px 28px; border-radius: 100px; background: var(--black); color: var(--white); font: 500 17px/1.2 var(--display); letter-spacing: -0.02em; transition: transform 0.3s cubic-bezier(0.2, 0, 0, 1), background-color 0.3s; }
.see-more:hover { transform: translateY(-2px); background: #1a1a1a; }
.see-more:focus-visible { outline: 2px solid var(--black); outline-offset: 3px; }
.see-more-count { font: 400 13px/1 var(--inter); opacity: 0.6; font-variant-numeric: tabular-nums; }
.see-more-arrow { transition: transform 0.3s cubic-bezier(0.2, 0, 0, 1); }
.see-more:hover .see-more-arrow { transform: translateX(4px); }
.work-page { width: 100%; display: flex; flex-direction: column; align-items: center; background: var(--white); position: relative; z-index: 4; }
.works--all { padding: 120px 0 60px; }
.works-intro { position: relative; z-index: 4; color: rgba(0, 0, 0, 0.6); max-width: 560px; margin: 8px auto 0; padding: 0 20px; }
@media (max-width: 809.98px) {
  .work-filters { gap: 6px; padding: 8px 18px 20px; }
  .work-filter { padding: 8px 14px; font-size: 14px; }
  .works--all { padding-top: 90px; }
}

.card { display: grid; grid-template-columns: repeat(2, minmax(50px, 1fr)); grid-template-rows: minmax(0, 1fr); gap: 10px 16px; width: 100%; height: 50vh; padding: 20px; background: var(--white); color: var(--black); }
.card-image { width: 100%; height: 100%; border-radius: 8px; overflow: hidden; position: relative; }
.card-image img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.card-info { display: flex; flex-direction: column; align-items: center; gap: 10px; height: 100%; width: 100%; }
.card-head { display: flex; justify-content: space-between; align-items: flex-start; width: 100%; }
.card-title { flex: 1 0 0; width: 1px; max-width: 50%; color: var(--black); }
.card-number { color: var(--black); white-space: pre; }
.card-desc-wrap { flex: 1 0 0; height: 1px; width: 100%; display: flex; flex-direction: column; gap: 10px; }
.card-desc { max-width: 60%; width: 100%; color: var(--desc); }
.card-details { display: flex; align-items: center; gap: 10px; width: 100%; cursor: pointer; }
.card-col { display: flex; flex-direction: column; gap: 4px; width: 100%; }
.card-label { color: var(--label); text-align: left; }
.card-label.right { text-align: right; }
.card-value { color: var(--black); }
.card-value.right { text-align: right; }
.card-live { flex: 1 0 0; width: 1px; align-self: stretch; display: flex; flex-direction: column; align-items: flex-start; justify-content: space-between; }
.card-meta { flex: 1 0 0; width: 1px; display: flex; flex-direction: column; align-items: center; gap: 32px; }
.card-deliverables { flex: 1 0 0; width: 1px; align-self: stretch; display: flex; flex-direction: column; gap: 32px; }
.card-deliverables .card-col { flex: 1 0 0; }
.link-btn.card-button-2 { display: none; }

@media (max-width: 1199.98px) {
  .card { display: flex; flex-direction: column; align-items: center; height: auto; }
  .card-image { height: auto; aspect-ratio: 2.45 / 1; }
  .card-info { align-items: flex-start; gap: 12px; height: auto; }
  .card-title, .card-desc { max-width: none; }
  .card-desc-wrap { flex: none; height: auto; }
  .card-details { cursor: auto; padding-bottom: 32px; }
  .card-live { display: none; }
  .link-btn.card-button-2 { display: inline-flex; }
  /* Framer's tablet and phone cards set some values without the text style */
  .card-value.plain { font-size: 16px; }
}
@media (max-width: 809.98px) {
  .card-image { aspect-ratio: auto; height: 200px; }
  .card-details { padding-bottom: 0; }
  .card-meta { flex-direction: row; }
  .card-meta > .card-col { flex: 1 0 0; width: 1px; }
  .card-meta > .card-col:last-child .card-label,
  .card-meta > .card-col:last-child .card-value { text-align: right; }
  .card-deliverables { display: none; }
}

/* "View project" button */
.link-btn { display: inline-flex; flex-direction: column; gap: 8px; cursor: pointer; }
.link-btn-row { display: flex; align-items: center; gap: 10px; height: 19px; transition: gap 0.5s var(--ease-link); }
.link-btn-dot {
  position: relative; flex: none; width: 8px; height: 8px; border-radius: 100px; overflow: hidden;
  border: 1px solid rgba(0, 0, 0, 0.6); background: rgba(0, 0, 0, 0);
  transition: width 0.5s var(--ease-link), height 0.5s var(--ease-link), background-color 0.5s var(--ease-link), border-color 0.5s var(--ease-link);
}
.link-btn-icon { position: absolute; width: 16px; height: 16px; left: -20px; top: 50%; transform: translateY(-50%); overflow: hidden; transition: left 0.5s var(--ease-link); }
.link-btn-icon svg { position: absolute; inset: 0; width: 16px; height: 16px; }
.link-btn-icon .arrow-hover { inset: -4px; width: 24px; height: 24px; opacity: 0; }
.link-btn-text { font: 700 16px/1.2 var(--display); letter-spacing: -0.01em; color: var(--black); white-space: pre; user-select: none; }
.link-btn-line { height: 1px; display: flex; justify-content: flex-end; padding-left: 18px; overflow: hidden; }
.link-btn-line > span { flex: 1 0 0; width: 1px; height: 1px; background: var(--line); transition: flex-basis 0.5s var(--ease-link), flex-grow 0.5s var(--ease-link); }
.link-btn:hover .link-btn-line > span { flex: 0 0 1px; }
.link-btn:hover .link-btn-row { gap: 12px; }
.link-btn:hover .link-btn-dot { width: 28px; height: 28px; background: var(--black); border-color: var(--black); }
.link-btn:hover .link-btn-icon { left: calc(50% - 8px); }
.link-btn:hover .link-btn-icon .arrow-rest { opacity: 0; }
.link-btn:hover .link-btn-icon .arrow-hover { opacity: 1; }
.link-btn .arrow-hover path { stroke-dasharray: 1; stroke-dashoffset: 1; }
.link-btn:hover .arrow-hover path { stroke-dashoffset: 0; transition: stroke-dashoffset 0.5s var(--ease-link) 0.1s; }

/* About ----------------------------------------------------------------------- */
.about { position: relative; z-index: 4; width: 100%; background: var(--black); padding: 100px 20px; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 44px; overflow: hidden; }
.about-row { width: 100%; display: flex; flex-wrap: wrap; justify-content: center; align-items: flex-start; gap: 44px; }
.about-text { flex: 1 0 0; width: 1px; min-width: 460px; display: flex; flex-direction: column; gap: 32px; border-radius: 20px; overflow: hidden; box-shadow: 16px 24px 20px 8px rgba(0, 0, 0, 0.4); }
.about-heading .fit { --vbw: 471; --vbh: 92; --fs: 92; }
.about-heading .fit-text { font-family: var(--display); font-weight: 600; text-transform: uppercase; color: var(--white); }
.about-body { position: relative; z-index: 1; display: flex; flex-direction: column; gap: 32px; width: 100%; }
.about-bio { opacity: 0.7; }
.rule { width: 100%; height: 1px; background: var(--white); opacity: 0.1; flex: none; }
.skills { position: relative; z-index: 9; display: flex; flex-wrap: wrap; gap: 16px; list-style: none; margin: 0; padding: 0; }
.skill { display: flex; align-items: center; padding: 10px 12px; border-radius: 8px; background: var(--chip); }
.skill .t-label { white-space: pre; }
.experience { display: flex; flex-direction: column; gap: 20px; }
.job { display: flex; flex-wrap: wrap; justify-content: center; align-items: center; gap: 48px; padding: 16px; border-radius: 10px; background: var(--black); }
.job > p { flex: 1 0 0; width: 1px; text-align: left; }
.job > p:last-child { text-align: right; }
.portrait { flex: 1 0 0; width: 1px; min-width: 460px; align-self: stretch; position: relative; border-radius: 4px; overflow: hidden; }
.portrait img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.literature { width: 100%; display: flex; flex-direction: column; justify-content: center; align-items: flex-start; gap: 32px; padding: 40px 0; }
.literature-heading { width: 100%; white-space: pre-wrap; }
.literature-head { width: 100%; display: flex; flex-wrap: wrap; align-items: baseline; justify-content: space-between; gap: 12px 24px; }
.literature-head .literature-heading { width: auto; flex: 1 1 auto; }
.library-link { color: var(--muted); white-space: nowrap; transition: color 0.2s; }
.library-link:hover, .library-link:focus-visible { color: var(--white); }
/* On wide screens the shelf sits in the About column under the job history, cut off at the
   column's edge, and the portrait grows down beside it. Narrower screens stack the columns,
   so there the shelf stays full width below. The full collection is on /library/. */
.literature--inside { display: none; }
@media (min-width: 1200px) {
  .literature--inside { display: flex; padding: 8px 0 0; gap: 24px; overflow: hidden; }
  .literature--below { display: none; }
  .shelf--clipped { justify-content: flex-start; width: max-content; padding: 16px 0 24px; }
}
@media (min-width: 810px) and (max-width: 1199.98px) {
  .about-text { order: 1; }
  .portrait { order: 0; align-self: auto; height: 60vh; flex: 1 0 0; }
}
@media (max-width: 809.98px) {
  .about { padding: 80px 18px; }
  .about-row { flex-direction: column; }
  .about-text { flex: none; order: 1; width: 100%; min-width: 240px; }
  .about-heading .fit { --vbw: 225; --vbh: 44; --fs: 44; }
  .job { flex-direction: column; align-items: stretch; gap: 8px; }
  .job > p { flex: none; width: 100%; }
  .job > p:last-child { text-align: left; }
  .portrait { flex: none; order: 0; width: 100%; min-width: 0; height: 40vh; align-self: auto; }
  .literature--below { align-items: center; }
  .literature--below .literature-head { flex-direction: column; align-items: center; }
  .literature--below .literature-head .literature-heading { width: 100%; }
  .literature--below .literature-heading { container-type: inline-size; aspect-ratio: 199 / 34; }
  .literature--below .literature-heading .fit-text { font-size: calc(100cqw * 24 / 199); line-height: 1.4; }
}
@media (min-width: 810px) and (max-width: 1199.98px) {
  .about-heading .fit { --vbw: 328; --vbh: 64; --fs: 64; }
  /* On Framer this heading's box is 150px tall at tablet size (its text never shows there, a
     Framer glitch). Keep the box so the shelf sits where it did, but show the words. */
  .literature--below .literature-heading { min-height: 150px; }
}

/* Bookshelf: each book opens as you scroll past its trigger line. */
.shelf { display: flex; align-items: center; justify-content: center; gap: 23px; width: min-content; }
.shelf-spacer { align-self: stretch; width: 44px; flex: none; display: none; }
.shelf[data-open="3"] .shelf-spacer { display: block; }
.book { --dur: var(--spring-snappy-ms); --ease: var(--spring-snappy); flex: none; width: 44px; display: flex; align-items: center; transition: width var(--dur) var(--ease); }
.book.is-open { width: 235px; }
.book-body { display: flex; align-items: center; transform-style: preserve-3d; transform: perspective(1200px) rotateY(0deg); transition: transform var(--dur) var(--ease); }
.book.is-open .book-body { transform: perspective(1200px) rotateY(-75deg); }
.book-spine { position: relative; display: flex; flex-direction: column; align-items: center; gap: 10px; width: 44px; height: 267px; padding-top: 10px; overflow: hidden; }
.book-spine-bg { position: absolute; inset: 0; background: var(--book); filter: brightness(0.75); transition: background-color var(--dur) var(--ease); }
.book-spine-grain, .book-cover-grain { position: absolute; inset: 0; z-index: 1; opacity: 0.06; background-size: 150px; background-repeat: repeat; pointer-events: none; }
.book-title-wrap { position: relative; width: 1px; min-height: 121px; display: flex; justify-content: center; }
.book-title {
  position: absolute; left: 0; top: 0; z-index: 1; white-space: pre; user-select: none; pointer-events: none;
  font: 600 16px/1.2 var(--inter); color: var(--book-title); text-align: center;
  transform: translateY(-50%) rotate(90deg); transform-origin: 0 50%;
  transition: color var(--dur) var(--ease);
}
.book-cover { position: absolute; z-index: 1; width: 200px; height: 267px; left: calc(100% - 100px); top: calc(49.8127% - 133.5px); overflow: hidden; transform: translateZ(-100px) rotateY(90deg); background: #111; }
.book-cover img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.book-cover .cover-open { opacity: 0; }
.book.is-open .book-cover .cover-open { opacity: 1; }
.book-highlight {
  position: absolute; top: 0; bottom: 0; left: 1px; width: 12px; z-index: 1;
  background: linear-gradient(90deg, rgba(255, 255, 255, 0.25) 0%, rgba(255, 255, 255, 0) 27.98%, rgba(255, 255, 255, 0) 45.81%, rgba(255, 255, 255, 0.2) 46.5%, rgba(255, 255, 255, 0) 85.02%);
}
.book.is-open .book-highlight {
  background: linear-gradient(90deg, rgba(255, 255, 255, 0.25) 0%, rgba(255, 255, 255, 0) 27.98%, rgba(0, 0, 0, 0.05) 30.07%, rgba(0, 0, 0, 0.05) 45.78%, rgba(255, 255, 255, 0.2) 49.7%, rgba(255, 255, 255, 0) 85.02%);
}

/* Hover (or tap) a book to open it; click it for the review. */
.book { cursor: pointer; outline: none; -webkit-tap-highlight-color: transparent; }
.book:focus-visible .book-spine { outline: 1px solid var(--muted); outline-offset: 3px; }
/* Extra books only join the shelf while there is room for them (see fitShelves in app.js). */
.book--extra:not(.fits) { display: none; }
.book.is-lifted .book-body { opacity: 0; transition: none; }

/* Review panel: the book sits on the left, its page drops down beside it. */
.review { position: fixed; inset: 0; z-index: 12; display: flex; align-items: center; justify-content: center; padding: 96px 40px; }
.review[hidden] { display: none; }
.review-backdrop { position: absolute; inset: 0; background: rgba(0, 0, 0, 0.72); backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px); }
.review-layout { position: relative; width: 100%; max-width: 1040px; max-height: 100%; display: flex; align-items: flex-start; gap: 56px; }
.review-cover { position: relative; flex: none; width: 280px; aspect-ratio: 200 / 267; }
.review-cover img, .review-flyer img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.review-cover {
  --rx: 0deg; --ry: 0deg; --px: 50%; --py: 50%; --glare: 0;
  transform: perspective(900px) rotateX(var(--rx)) rotateY(var(--ry));
  transform-style: preserve-3d;
}
.review-cover img { box-shadow: var(--sx, 0px) calc(30px + var(--sy, 0px)) 60px -20px rgba(0, 0, 0, 0.8); }
/* Light catching the cover as it tilts. */
.review-cover::after {
  content: ""; position: absolute; inset: 0; pointer-events: none; opacity: var(--glare);
  background: radial-gradient(circle at var(--px) var(--py), rgba(255, 255, 255, 0.35), rgba(255, 255, 255, 0) 55%);
  mix-blend-mode: soft-light;
}
.review-cover:empty::after { display: none; }
.review-page { --rx: 0deg; --ry: 0deg; transform: perspective(1600px) rotateX(var(--rx)) rotateY(var(--ry)); }
.review-flyer { position: fixed; z-index: 2; pointer-events: none; transform-origin: 50% 50%; box-shadow: 0 30px 60px -20px rgba(0, 0, 0, 0.8); will-change: transform; }
.review-page {
  position: relative; flex: 1 0 0; width: 1px; max-height: calc(100vh - 192px); max-height: calc(100dvh - 192px); overflow-y: auto; overscroll-behavior: contain;
  padding: 40px 44px 44px; border-radius: 12px; background: var(--chip); border: 1px solid var(--line);
  scrollbar-width: thin; scrollbar-color: #ffffff26 transparent;
}
.review-content { display: flex; flex-direction: column; gap: 24px; }
.review-head { display: flex; flex-direction: column; gap: 8px; padding-right: 40px; }
.review-meta { display: flex; flex-wrap: wrap; align-items: center; gap: 12px; font: 400 14px/1.5 var(--inter); letter-spacing: -0.02em; color: var(--muted); }
.review-dot { width: 3px; height: 3px; border-radius: 50%; background: currentColor; opacity: 0.6; }
.review-stars { display: inline-flex; gap: 2px; letter-spacing: 0; }
.review-stars .star { color: #ffffff2e; }
.review-stars .star.on { color: var(--white); }
.review-title { font: 500 36px/1.15 var(--satoshi); letter-spacing: -0.01em; color: var(--white); }
.review-author { font: italic 400 22px/1.3 var(--serif); color: var(--muted); }
.review-body { display: flex; flex-direction: column; gap: 16px; font: 400 17px/1.7 var(--display); color: #ffffffd9; }
.review-body a { text-decoration: underline; text-underline-offset: 3px; }
.review-empty { font: 400 17px/1.7 var(--display); color: var(--desc); }
.review-link { align-self: flex-start; display: inline-flex; gap: 6px; padding: 10px 14px; border-radius: 8px; background: #ffffff0d; transition: color 0.2s, background-color 0.2s; }
.review-link:hover, .review-link:focus-visible { color: var(--white); background: #ffffff1a; }
.review-close { position: absolute; top: 28px; right: 28px; width: 36px; height: 36px; border: 0; border-radius: 50%; background: #ffffff0d; cursor: pointer; transition: background-color 0.2s; }
.review-close:hover, .review-close:focus-visible { background: #ffffff1f; }
.review-close span::before, .review-close span::after { content: ""; position: absolute; left: 50%; top: 50%; width: 14px; height: 1.5px; background: var(--white); transform: translate(-50%, -50%) rotate(45deg); }
.review-close span::after { transform: translate(-50%, -50%) rotate(-45deg); }
html.review-open { overflow: hidden; }
@media (max-width: 1199.98px) {
  .review-cover { width: 220px; }
  .review-layout { gap: 36px; }
}
@media (max-width: 809.98px) {
  .review { padding: 72px 18px 18px; align-items: stretch; }
  .review-layout { flex-direction: column; gap: 20px; height: 100%; }
  .review-cover { width: 104px; }
  .review-page { flex: 0 1 auto; width: 100%; min-height: 0; max-height: none; padding: 28px 22px 32px; }
  .review-close { top: 18px; right: 18px; }
  .review-title { font-size: 28px; }
  .review-author { font-size: 19px; }
  .review-body, .review-empty { font-size: 16px; }
}

/* The invisible lines that open each book (same sizes as on Framer). */
.shelf-triggers { position: absolute; z-index: 1; bottom: 100px; left: 50%; transform: translateX(-50%); width: 1040px; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 10px; overflow: clip; pointer-events: none; user-select: none; }
.shelf-triggers > div { flex: none; width: 1040px; height: 90px; }
.shelf-triggers > .xl { display: none; height: 68px; }
@media (min-width: 810px) and (max-width: 1199.98px) { .shelf-triggers { width: min-content; } }
@media (min-width: 1920px) {
  .shelf-triggers { height: 964px; width: 1760px; bottom: -260px; left: calc(50% - 880px); transform: none; }
  .shelf-triggers > div { height: 68px; }
  .shelf-triggers > .xl { display: block; }
}

/* Contact footer ------------------------------------------------------------ */
.footer-wrap { position: relative; z-index: 1; width: 100%; height: 100vh; order: 1002; }
.footer { position: relative; width: 100%; height: 100%; background: var(--black); padding: 0 80px; display: flex; flex-direction: column; align-items: center; justify-content: center; overflow: hidden; will-change: transform; }
.footer-inner { position: relative; z-index: 1; width: 100%; max-width: 1600px; height: 100vh; padding: 60px 0; display: flex; flex-direction: column; align-items: center; justify-content: space-between; }
.footer-spacer { width: 100%; height: 43px; flex: none; }
.footer-text { width: 100%; max-width: 840px; display: flex; flex-direction: column; align-items: center; gap: 32px; }
.footer-heading { width: 100%; text-align: center; }
.footer-cta-row { width: 100%; display: flex; justify-content: center; align-items: center; gap: 40px; }
.footer-bottom { width: 100%; display: flex; align-items: flex-end; justify-content: space-between; overflow: hidden; }
.footer-contact { flex: 1 0 0; width: 1px; display: flex; align-items: center; justify-content: space-between; }
.footer-email { color: var(--white); white-space: pre; }
.socials { display: flex; align-items: center; justify-content: center; gap: 24px; overflow: hidden; }
.social { display: flex; padding: 8px; border-radius: 100px; }
.social svg { width: 24px; height: 24px; fill: var(--white); }
.social-sep { width: 2px; height: 24px; background: var(--white); opacity: 0.2; flex: none; }
/* Jack's signature, between the email address and the socials (scripts/lib/signature.mjs). The
   outline is seen through a mask, and the mask is the pen's strokes in white: the outline shows
   wherever a stroke has passed. app.js adds "seen" when it scrolls into view, and then the strokes
   slide their dashes into place from left to right. With less motion asked for, it simply shows. */
.footer-contact { display: grid; grid-template-columns: 1fr auto 1fr; }
.footer-email { justify-self: start; }
.socials { justify-self: end; }
.signature { display: block; width: clamp(300px, 30vw, 440px); height: auto; aspect-ratio: 646 / 55; fill: var(--white); overflow: visible; }
/* The pen line is a hairline, so it is traced a little heavier to read on the dark footer. */
.signature .ink { stroke: var(--white); stroke-width: 1.1; stroke-linejoin: round; }
.signature .brush { fill: none; stroke: #fff; stroke-linecap: round; stroke-linejoin: round; }
.signature .whole { fill: #fff; }
@keyframes sign-stroke { to { stroke-dashoffset: 0; } }
@keyframes sign-whole { to { opacity: 1; } }
@media (prefers-reduced-motion: no-preference) {
  .js .signature .brush { stroke-dasharray: var(--dash); stroke-dashoffset: var(--from); }
  .js .signature .whole { opacity: 0; }
  .js .signature.seen .brush { animation: sign-stroke var(--for) calc(0.3s + var(--at)) cubic-bezier(0.37, 0, 0.63, 1) forwards; }
  .js .signature.seen .whole { animation: sign-whole 0.3s calc(0.3s + var(--at)) ease-out forwards; }
}
.footer-bg { position: absolute; inset: 0; z-index: 0; overflow: hidden; }
.footer-fade { position: absolute; inset: 0; z-index: 1; background: linear-gradient(180deg, rgba(4, 4, 4, 0) 55%, rgb(4, 4, 4) 100%); }
@media (min-width: 810px) and (max-width: 1199.98px) {
  .footer { padding: 0 30px; }
  .t-h3 { font-size: 34px; }
}
@media (max-width: 809.98px) {
  .footer-wrap { height: auto; }
  .footer-spacer, .footer-bg { display: none; }
  .footer { padding: 0 20px; justify-content: flex-end; will-change: auto; }
  .footer-inner { height: auto; gap: 80px; justify-content: center; }
  .footer-text { align-items: flex-start; }
  .footer-heading { text-align: left; }
  .footer-cta-row { flex-direction: column; align-items: flex-start; }
  .footer-bottom { flex-direction: column; align-items: center; justify-content: flex-start; gap: 24px; }
  .footer-contact { flex: none; width: 100%; display: flex; flex-direction: column; align-items: flex-start; justify-content: flex-start; gap: 24px; }
  .signature { width: min(360px, 88vw); }
  .t-h3 { font-size: 30px; }
}

/* "Available for work" badge */
.badge { position: relative; z-index: 4; display: flex; align-items: center; gap: 10px; border-radius: 40px; background: var(--black); }
.badge-inner { position: relative; z-index: 2; display: flex; align-items: center; gap: 10px; padding: 10px 16px; border-radius: 26px; background: rgba(10, 10, 10, 0.4); backdrop-filter: blur(68px); -webkit-backdrop-filter: blur(68px); overflow: hidden; }
.badge-dot { width: 7px; height: 7px; border-radius: 84px; background: var(--white); box-shadow: 0 0 14px 1px #bdbdbd; flex: none; }
.badge .t-label { color: var(--white); white-space: pre; }
.badge-edge { position: absolute; inset: -1px; z-index: 1; border-radius: 26px; background: linear-gradient(105deg, #fff -19%, rgba(0, 0, 0, 0) 20%); overflow: hidden; }

/* "Book a free call" button */
.cta { --t: var(--spring-snappy-ms) var(--spring-snappy); position: relative; z-index: 1; display: flex; flex-direction: column; align-items: center; gap: 10px; cursor: pointer; }
.cta-frame { position: relative; z-index: 2; align-self: stretch; display: flex; flex-direction: column; align-items: center; padding: 1.4px; border-radius: 11.5px; background: #3b3b3b; overflow: hidden; box-shadow: 0 1px 9px 0 rgba(255, 255, 255, 0); transition: box-shadow var(--t); }
.cta-inner { position: relative; z-index: 4; width: 100%; display: flex; justify-content: center; padding: 8px 24px; border-radius: 10px; background: var(--black); overflow: hidden; }
.cta-label { position: relative; z-index: 2; white-space: pre; user-select: none; pointer-events: none; }
.cta .glow { position: absolute; z-index: 1; overflow: hidden; border-radius: 999px; filter: blur(10px); transition: left var(--t), top var(--t), width var(--t), height var(--t), bottom var(--t), opacity var(--t), background var(--t); }
.cta .glow-a { width: 77px; height: 41px; left: calc(8.8235% - 38.5px); top: calc(118.1818% - 20.5px); background: radial-gradient(50% 50% at 50% 50%, #a3a3a3 0%, rgba(0, 0, 0, 0) 100%); opacity: 0.41; }
.cta .glow-b { width: 92px; height: 40px; left: calc(74.9035% - 46px); top: -20px; background: radial-gradient(50% 50% at 50% 50%, #737373 0%, rgba(0, 0, 0, 0) 100%); }
.cta .glow-c { width: 58px; height: 30px; left: -11px; top: calc(83.9506% - 15px); background: radial-gradient(50% 50% at 50% 50%, #ababab 0%, rgba(0, 0, 0, 0) 100%); }
.cta .glow-d { width: 74px; height: 41px; right: -12px; top: -7px; border-radius: 21px; background: radial-gradient(50% 50% at 50% 50%, #fff 0%, rgba(0, 0, 0, 0) 100%); opacity: 0.62; }
.cta .blob { position: absolute; z-index: 1; overflow: hidden; filter: blur(8px); transition: left var(--t), bottom var(--t), width var(--t), height var(--t); }
.cta .blob-top { width: 95px; height: 36px; right: -17px; top: -19px; background: var(--white); }
.cta .blob-a { width: 54px; height: 46px; left: -22px; bottom: -18px; background: #e6e6e6; }
.cta .blob-b { width: 40px; height: 34px; left: -22px; bottom: -17px; background: var(--white); }
.cta:not([href]) { cursor: default; }
.cta:hover .cta-frame { box-shadow: 0 1px 7px 0 rgba(255, 255, 255, 0.24); }
.cta:hover .glow-a { opacity: 0.5; height: 48px; left: calc(9.2105% - 38.5px); top: calc(108.8889% - 24px); }
.cta:hover .glow-b { background: radial-gradient(50% 50% at 50% 50%, #c2c2c2 0%, rgba(0, 0, 0, 0) 100%); }
.cta:hover .blob-a { bottom: -19px; height: 51px; left: -24px; width: 87px; }
.cta:hover .blob-b { bottom: -18px; height: 39px; left: -24px; width: 61px; }

/* Bottom-of-screen progressive blur ------------------------------------------ */
.edge-blur { position: fixed; left: 0; right: 0; bottom: 0; height: 100px; z-index: 10; pointer-events: none; }
.edge-blur > div { position: absolute; inset: 0; pointer-events: none; }

/* Custom cursor --------------------------------------------------------------- */
.cursor { position: fixed; left: 0; top: 0; z-index: 13; width: 12px; height: 12px; border-radius: 40px; background: #e6e6e6; box-shadow: 0 0 20px 4px rgba(196, 196, 196, 0.3); pointer-events: none; opacity: 0; will-change: transform; }
.cursor.is-visible { opacity: 1; }
@media (hover: none), (pointer: coarse) { .cursor { display: none; } }

/* Entrance animations: hidden until app.js plays them. Without JavaScript nothing is hidden. */
.js [data-appear] { opacity: 0.001; }
@media (prefers-reduced-motion: reduce) {
  .js [data-appear] { opacity: 1 !important; filter: none !important; transform: none !important; }
  .grain-layer { animation: none; }
}

/* Load-in intro (home page) ------------------------------------------------------
   The inline script at the top of <body> adds .intro plus .intro-full (first visit in a
   browser session) or .intro-quick (later visits). It never runs for reduced motion, and
   everything here needs .js too, so the page is never left hidden if app.js fails.

   1. A light curtain of five columns lifts away from the middle outwards, each column
      collapsing up into a hairline at the top of the screen; the hairlines then fade.
   2. Text rises into place from behind an invisible line (each .intro-rise slides up
      inside a box that clips its bottom edge): the tagline, then the name word by word
      with the nav links, then the scroll hint, left to right. */
:root {
  --intro-shift: 0ms;                                /* .intro-quick starts everything sooner */
  --intro-rise: cubic-bezier(0, 0.24, 0, 1);        /* quick off the line, long soft landing */
  --intro-curtain: cubic-bezier(0.88, 0, 0, 1);     /* slow start, fast middle, slow stop */
}
.intro-quick { --intro-shift: -900ms; }
.intro-mask, .intro-rise { display: inline-block; }
.tagline .intro-mask { display: block; }
.intro-curtain { display: none; }

.js.intro .intro-mask,
.js.intro .nav-link,
.js.intro .nav-title .fit-text { clip-path: inset(-100% -100% 0 -100%); }
.js.intro .intro-rise {
  transform: translateY(var(--intro-from, max(150px, 120%)));
  animation: intro-rise 900ms var(--intro-rise) calc(var(--intro-delay, 1100ms) + var(--intro-shift)) both;
}
@keyframes intro-rise { to { transform: none; } }

.js.intro .tagline .intro-rise { --intro-from: max(160px, 120%); --intro-delay: 1100ms; }
.js.intro .nav-title .intro-rise { --intro-from: max(160px, 130%); --intro-delay: 1300ms; }
.js.intro .nav-title .intro-rise + .intro-rise { --intro-delay: 1400ms; }
.js.intro .nav-link:nth-child(1) .intro-rise { --intro-delay: 1300ms; }
.js.intro .nav-link:nth-child(2) .intro-rise { --intro-delay: 1400ms; }
.js.intro .nav-link:nth-child(3) .intro-rise { --intro-delay: 1500ms; }
.js.intro .nav-link:nth-child(4) .intro-rise { --intro-delay: 1600ms; }
.js.intro .nav-link:nth-child(5) .intro-rise { --intro-delay: 1700ms; }
.js.intro .scroll-hint > :nth-child(1) .intro-rise { --intro-delay: 1900ms; }
.js.intro .scroll-hint > :nth-child(3) .intro-rise { --intro-delay: 2100ms; }
.js.intro .scroll-hint > :nth-child(5) .intro-rise { --intro-delay: 2300ms; }
/* The hint's two hairlines draw outwards from the mouse as the labels arrive. */
.js.intro .scroll-hint-line { animation: intro-line 1200ms var(--intro-rise) calc(1900ms + var(--intro-shift)) both; }
.js.intro .scroll-hint-line:nth-child(2) { transform-origin: 100% 50%; }
.js.intro .scroll-hint-line:nth-child(4) { transform-origin: 0 50%; }
@keyframes intro-line { from { transform: scaleX(0); } }

.js.intro-full .intro-curtain { position: fixed; inset: 0; z-index: 20; display: flex; pointer-events: none; }
.intro-curtain i {
  flex: 1 0 0; height: 100%; margin-right: -1px; background: #f5f5f5;   /* overlap hides seams */
  animation:
    intro-curtain 1800ms var(--intro-curtain) var(--d) both,
    intro-hairline 800ms ease-out 2200ms both;
}
.intro-curtain i:nth-child(3) { --d: 200ms; }                            /* the middle goes first */
.intro-curtain i:nth-child(2), .intro-curtain i:nth-child(4) { --d: 300ms; }
.intro-curtain i:nth-child(1), .intro-curtain i:nth-child(5) { --d: 400ms; }
@keyframes intro-curtain { from { clip-path: inset(0); } to { clip-path: inset(0 0 calc(100% - 1px) 0); } }
@keyframes intro-hairline { to { opacity: 0; } }

/* Library page: every book, in rows laid out by app.js. */
.library { padding-bottom: 160px; overflow: clip; }
.library-count { color: var(--muted); }
.shelf.shelf--library { width: 100%; max-width: 1760px; margin-top: 88px; display: flex; flex-direction: column; align-items: stretch; justify-content: flex-start; gap: 48px; }
.shelf-row { display: flex; align-items: center; justify-content: flex-start; gap: 23px; padding-bottom: 20px; border-bottom: 1px solid rgba(255, 255, 255, 0.08); }
@media (max-width: 809.98px) {
  .shelf.shelf--library { margin-top: 56px; gap: 36px; }
  .shelf-row { justify-content: center; }
}

/* Project pages ---------------------------------------------------------------- */
.project { position: relative; z-index: 4; width: 100%; background: var(--black); color: var(--white); display: flex; flex-direction: column; align-items: center; padding: 180px 40px 120px; }
.project-head { width: 100%; max-width: 1040px; display: flex; flex-direction: column; align-items: center; gap: 24px; text-align: center; }
.tags { display: flex; flex-wrap: wrap; justify-content: center; gap: 8px; }
.tag { padding: 6px 14px; border-radius: 100px; background: rgba(255, 255, 255, 0.06); border: 1px solid rgba(255, 255, 255, 0.1); font: 400 14px/1.4 var(--inter); color: var(--muted); }
.project-title { max-width: 960px; font: 400 92px/1 var(--display); letter-spacing: -0.02em; text-transform: uppercase; }
.project-sub { max-width: 640px; color: var(--muted); }
.project-visit { display: inline-flex; align-items: center; gap: 8px; padding: 10px 20px; border-radius: 100px; border: 1px solid rgba(255, 255, 255, 0.2); font: 400 15px/1.4 var(--inter); color: var(--white); transition: background-color 0.3s, border-color 0.3s; }
.project-visit:hover { background: rgba(255, 255, 255, 0.08); border-color: rgba(255, 255, 255, 0.4); }
.card-live-link { text-decoration: underline; text-decoration-thickness: 1px; text-underline-offset: 3px; }
/* Split layout: the facts stay on the left while the media scrolls on the right. */
/* Media scrolling up behind the nav fades out, so the nav stays readable. */
.top-fade { position: fixed; left: 0; right: 0; top: 0; height: 96px; z-index: 5; pointer-events: none; background: linear-gradient(#000 0%, rgba(0, 0, 0, 0.85) 45%, rgba(0, 0, 0, 0)); }
.project-split { padding: 140px 40px 120px; }
.case { width: 100%; max-width: 1760px; display: grid; grid-template-columns: minmax(0, 28fr) minmax(0, 72fr); gap: 48px; align-items: start; }
.case-info { position: sticky; top: 110px; }
.case-info-inner { max-height: calc(100vh - 130px); overflow-y: auto; scrollbar-width: none; display: flex; flex-direction: column; align-items: flex-start; gap: 24px; padding-bottom: 8px; }
.case-info-inner::-webkit-scrollbar { display: none; }
.case-info .tags { justify-content: flex-start; }
/* The left column is narrow, so the title is sized to it. */
.case-title { font: 400 60px/0.95 var(--display); letter-spacing: -0.03em; text-transform: uppercase; overflow-wrap: anywhere; }
.case-sub { color: var(--muted); max-width: 560px; }
.case-facts { margin: 8px 0 0; width: 100%; display: grid; grid-template-columns: 1fr 1fr; gap: 20px 24px; padding: 24px 0; border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.case-facts .fact { display: flex; flex-direction: column; gap: 4px; }
.case-facts dt { text-align: left; }
.case-facts dd { margin: 0; }
.case-back { color: var(--muted); transition: color 0.3s; }
.case-back:hover { color: var(--white); }
.case-media { display: flex; flex-direction: column; gap: 24px; min-width: 0; }
.media-item { margin: 0; width: 100%; border-radius: 20px; overflow: hidden; position: relative; }
.media-image { background: #111; }
.media-image img { display: block; width: 100%; height: 100%; object-fit: cover; }
.media-video { aspect-ratio: 16 / 9; background: #111; }
.project-hero-video { position: absolute; inset: 0; display: block; width: 100%; height: 100%; object-fit: cover; background: #111; }
.media-section { border-radius: 20px; background: var(--chip); border: 1px solid var(--line); }
.media-text { padding: 48px 56px 52px; display: flex; flex-direction: column; gap: 14px; }
.media-kicker { text-align: left; }
.media-heading { margin: 0; font: 400 48px/1.05 var(--satoshi); letter-spacing: -0.02em; }
.media-body { display: flex; flex-direction: column; gap: 18px; margin-top: 10px; color: rgba(255, 255, 255, 0.78); }
.media-body p { margin: 0; }
.media-body strong { font-weight: 600; color: var(--white); }
.media-body a { color: var(--white); text-decoration: underline; text-decoration-thickness: 1px; text-underline-offset: 3px; }
.media-overlay img { display: block; width: 100%; height: auto; }
.overlay-card { position: absolute; left: 24px; bottom: 24px; max-width: min(560px, calc(100% - 48px)); padding: 28px 32px; border-radius: 16px; background: rgba(0, 0, 0, 0.62); -webkit-backdrop-filter: blur(18px); backdrop-filter: blur(18px); border: 1px solid var(--line); }
.overlay-card .media-heading { font-size: 32px; }
.project-next { width: 100%; max-width: 1040px; margin-top: 160px; padding-top: 40px; border-top: 1px solid var(--line); display: flex; justify-content: space-between; align-items: flex-end; gap: 24px; }
.project-next a { display: flex; flex-direction: column; gap: 8px; }
.project-next .next-title { font: 400 56px/1.05 var(--satoshi); letter-spacing: -0.02em; transition: opacity 0.3s; }
.project-next a:hover .next-title { opacity: 0.7; }
.project-next .back { color: var(--muted); transition: color 0.3s; }
.project-next .back:hover { color: var(--white); }
.project-split .project-next { max-width: 1760px; }
@media (max-width: 1439.98px) {
  .case-title { font-size: 48px; }
  .media-heading { font-size: 40px; }
  .media-text { padding: 40px 44px 44px; }
}
@media (max-width: 1199.98px) {
  .project-title { font-size: 64px; }
  .project-next .next-title { font-size: 44px; }
  .case { gap: 32px; grid-template-columns: minmax(0, 32fr) minmax(0, 68fr); }
  .case-title { font-size: 40px; }
  .case-facts { grid-template-columns: 1fr; gap: 14px; }
  .media-heading { font-size: 34px; }
  .media-text { padding: 32px 32px 36px; }
}
@media (max-width: 999.98px) {
  .case { grid-template-columns: 1fr; gap: 48px; }
  .case-info { position: static; }
  .case-info-inner { max-height: none; overflow: visible; }
  .case-facts { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 809.98px) {
  .project { padding: 140px 18px 80px; }
  .project-split { padding: 120px 18px 80px; }
  .project-title { font-size: 40px; }
  .case-title { font-size: 44px; }
  .case-media { gap: 16px; }
  .media-item, .media-section { border-radius: 12px; }
  .media-text { padding: 28px 22px 30px; }
  .media-heading { font-size: 30px; }
  .overlay-card { position: static; max-width: none; border-radius: 0; border: 0; background: var(--chip); }
  .project-next .next-title { font-size: 34px; }
  .project-next { flex-direction: column; align-items: flex-start; margin-top: 96px; }
}
