/* nikicarver.com, shared styles */

@font-face { font-family: "Silkscreen"; font-weight: 700; font-display: swap; src: url("../fonts/silkscreen-latin-700-normal.woff2") format("woff2"); }
@font-face { font-family: "Manrope"; font-weight: 400; font-display: swap; src: url("../fonts/manrope-latin-400-normal.woff2") format("woff2"); }
@font-face { font-family: "Manrope"; font-weight: 500; font-display: swap; src: url("../fonts/manrope-latin-500-normal.woff2") format("woff2"); }
@font-face { font-family: "Manrope"; font-weight: 600; font-display: swap; src: url("../fonts/manrope-latin-600-normal.woff2") format("woff2"); }
@font-face { font-family: "Manrope"; font-weight: 700; font-display: swap; src: url("../fonts/manrope-latin-700-normal.woff2") format("woff2"); }

:root {
  --ink: #151515;
  --body: #3d3d3d;
  --muted: #6b6b6b;
  --faint: #9a9a9a;
  --line: #e7e7e7;
  --bg: #ffffff;
  --soft: #f6f5f3;
  --purple: #a572ff;
  --heart: #ff6eb4;
  --grad: linear-gradient(90deg, #fcb375 0%, #fc6368 49%, #a572ff 100%);
  --grad-radial: radial-gradient(circle at 0 0, #fcb375, #fc6368 49%, #a572ff);
  --serif: "Manrope", "Helvetica Neue", Arial, sans-serif;
  --sans: "Manrope", "Helvetica Neue", Arial, sans-serif;
  --mono: "Manrope", "Helvetica Neue", Arial, sans-serif;
  --nav-h: 68px;
  --gutter: clamp(16px, 2.6vw, 40px);
  --max: 1680px;
  --top: 48px;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }
body { margin: 0; background: var(--bg); color: var(--body); font-family: var(--sans); font-size: 16px; line-height: 1.65; -webkit-font-smoothing: antialiased; }
img, video { display: block; max-width: 100%; height: auto; }
a { color: inherit; }
h1, h2, h3 { color: var(--ink); margin: 0; }
p { margin: 0 0 1.1em; }
p:last-child { margin-bottom: 0; }
.wrap { max-width: var(--max); margin: 0 auto; padding: 0 var(--gutter); }
.mono { font-family: var(--sans); font-weight: 600; font-size: 12px; letter-spacing: .05em; text-transform: uppercase; color: #8b8b8b; }
.skip { position: absolute; left: -9999px; }
.skip:focus { left: 16px; top: 12px; z-index: 100; background: #fff; padding: 8px 12px; }

/* ---------- Navbar ---------- */
.nav { position: sticky; top: 0; z-index: 50; background: rgba(255,255,255,.94); backdrop-filter: saturate(1.4) blur(10px); -webkit-backdrop-filter: saturate(1.4) blur(10px); }
.nav-inner { height: var(--nav-h); display: flex; align-items: center; justify-content: space-between; }
.brand { font-weight: 700; font-size: 14px; letter-spacing: .04em; text-decoration: none; background: var(--grad-radial); -webkit-background-clip: text; background-clip: text; -webkit-text-fill-color: transparent; }
.nav-links { display: flex; gap: 30px; list-style: none; margin: 0; padding: 0; }
.nav-links a { position: relative; text-decoration: none; color: var(--ink); font-size: 14.5px; font-weight: 500; letter-spacing: .01em; }
.nav-links a::after { content: ""; position: absolute; left: 0; right: 0; bottom: -4px; height: 2px; background: var(--grad); transform: scaleX(0); transform-origin: left; transition: transform .25s ease; }
.nav-links a:hover::after, .nav-links a[aria-current="page"]::after { transform: scaleX(1); }
.nav-toggle { display: none; background: none; border: 0; padding: 8px; margin-right: -8px; cursor: pointer; color: var(--ink); }
.nav-toggle span { display: block; width: 22px; height: 2px; background: currentColor; margin: 5px 0; transition: transform .2s, opacity .2s; }
.nav.is-open .nav-toggle span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.nav.is-open .nav-toggle span:nth-child(2) { opacity: 0; }
.nav.is-open .nav-toggle span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }
.nav-rule { height: 1px; background: var(--line); }

@media (max-width: 720px) {
  .nav-toggle { display: block; }
  .nav-links { display: none; position: absolute; top: var(--nav-h); left: 0; right: 0; flex-direction: column; gap: 0; background: #fff; border-bottom: 1px solid var(--line); padding: 8px var(--gutter) 16px; }
  .nav.is-open .nav-links { display: flex; }
  .nav-links a { display: block; padding: 12px 0; font-size: 17px; }
  .nav-links a::after { display: none; }
}

/* ---------- Reading progress (case studies) ---------- */
.progress { position: absolute; left: 0; right: 0; bottom: 0; height: 3px; background: transparent; }
.progress-fill { position: absolute; inset: 0 auto 0 0; width: 0; background: var(--grad); background-size: 100vw 100%; background-repeat: no-repeat; }













/* ---------- Case study header ---------- */
.cs-head { padding: var(--top) 0 0; }
.back { line-height: 1;  display: inline-flex; gap: 8px; align-items: center; text-decoration: none; color: var(--muted); }
.back:hover { color: var(--ink); }
.cs-title { font-family: var(--sans); font-weight: 300; font-size: clamp(24px, 2.3vw, 34px); line-height: 1.15; letter-spacing: -.012em; margin: 14px 0 12px; max-width: none; }
.cs-summary { font-size: 16px; line-height: 1.65; color: var(--body); max-width: 900px; margin: 0; }
.cs-meta { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 20px 32px; margin-top: 22px; padding: 18px 0 26px; border-top: 1px solid var(--line); }
.cs-meta dt { margin-bottom: 6px; }
.cs-meta dd { margin: 0; color: var(--ink); font-size: 15px; line-height: 1.5; }
@media (max-width: 900px) { .cs-meta { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 480px) { .cs-meta { grid-template-columns: 1fr; gap: 20px; } }

.cs-cover { margin: 0 0 8px; display: flex; justify-content: center; }
.cs-cover button { all: unset; display: block; cursor: zoom-in; width: 100%; }
.cs-cover button { width: auto; max-width: 100%; }
.cs-cover img { width: auto; max-width: 100%; height: auto; max-height: min(82vh, 980px); display: block; margin: 0 auto; border-radius: 6px; }

/* ---------- Case study body ---------- */
.cs-body { display: grid; grid-template-columns: 214px minmax(0, 1fr); gap: 44px; padding: 44px 0 40px; }
.cs-content { min-width: 0; }
.toc { position: sticky; top: calc(var(--nav-h) + 28px); align-self: start; max-height: calc(100vh - var(--nav-h) - 40px); overflow-y: auto; scrollbar-width: none; }
.toc::-webkit-scrollbar { display: none; }
.toc-sub { font-weight: 500; color: var(--ink); font-size: 14px; line-height: 1.4; letter-spacing: -.005em; margin: 0 0 8px; }
.toc-title { font-weight: 300; color: var(--ink); font-size: 24px; line-height: 1.1; letter-spacing: -.01em; margin: 0 0 20px; }
.toc-label { font-weight: 600; font-size: 11.5px; letter-spacing: .04em; text-transform: uppercase; color: #a3a3a3; margin: 22px 0 8px; }
.toc-label:first-of-type { margin-top: 0; }
.toc-credit { display: flex; justify-content: space-between; flex-wrap: wrap; gap: 0 10px; color: var(--ink); font-size: 13px; line-height: 1.5; }
.toc-tags { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: 6px; }
.toc-tags li { font-weight: 600; font-size: 10.5px; letter-spacing: .05em; text-transform: uppercase; color: #555; background: #f1f0f2; border-radius: 4px; padding: 5px 8px; }
.toc ol { list-style: none; margin: 0; padding: 0; position: relative; }
.toc li a { display: block; position: relative; padding: 7px 0 7px 22px; text-decoration: none; color: var(--muted); font-size: 14.5px; line-height: 1.4; transition: color .2s; }
.toc li.sub a { padding-left: 36px; font-size: 13.5px; }
.toc li a:hover { color: var(--ink); }
.toc li a.is-active { color: var(--ink); font-weight: 600; }
.toc-heart { position: absolute; left: 0; top: 0; width: 12px; height: 10px; transition: transform .45s cubic-bezier(.3,1.3,.5,1), opacity .2s; opacity: 0; pointer-events: none; }
.toc-heart svg { width: 100%; height: 100%; display: block; animation: heart-beat 1.4s ease-in-out infinite; transform-origin: 50% 60%; }
.toc-heart.is-on { opacity: 1; }
@keyframes heart-beat { 0%, 60%, 100% { transform: scale(1); } 20% { transform: scale(1.22); } 40% { transform: scale(.95); } }
@media (prefers-reduced-motion: reduce) { .toc-heart { transition: opacity .2s; } .toc-heart svg { animation: none; } }

.chips { display: none; }
@media (max-width: 960px) {
  .cs-body { grid-template-columns: minmax(0, 1fr); gap: 0; padding-top: 28px; }
  .toc { display: none; }
  .chips { display: flex; flex-wrap: wrap; gap: 8px; padding: 0 0 36px; margin: 0; list-style: none; }
  .chips::-webkit-scrollbar { display: none; }
  .chips a { display: block; white-space: nowrap; text-decoration: none; font-size: 13px; color: var(--ink); border: 1px solid var(--line); border-radius: 999px; padding: 6px 12px; }
.chips .chip-group { flex-basis: 100%; font-weight: 600; font-size: 11px; letter-spacing: .05em; text-transform: uppercase; color: #8b8b8b; margin-top: 6px; }
.chips .chip-group:first-child { margin-top: 0; }
}

.section { padding: 0 0 120px; scroll-margin-top: calc(var(--nav-h) + 24px); }
.section + .section { padding-top: 0; }
.section.is-sub { margin-top: -24px; }
.section-head { max-width: none; margin-bottom: 22px; }
.section-head .mono { display: block; margin-bottom: 8px; }
.section h2 { font-family: var(--sans); font-weight: 300; font-size: clamp(21px, 1.8vw, 26px); line-height: 1.2; letter-spacing: -.01em; margin-bottom: 12px; }
.section.is-sub h2 { font-size: clamp(23px, 2.1vw, 28px); }
.prose { max-width: none; font-size: 16px; line-height: 1.7; }

.stats { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 0; margin: 26px 0 60px; border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.stat { padding: 22px 22px 22px 0; }
.stat + .stat { padding-left: 22px; border-left: 1px solid var(--line); }

.stat-num { font-family: var(--sans); font-weight: 300; font-size: clamp(34px, 3.4vw, 46px); line-height: 1; letter-spacing: -.02em; background: linear-gradient(90deg, #fcb375, #fc6368 55%, #a572ff 110%); -webkit-background-clip: text; background-clip: text; -webkit-text-fill-color: transparent; padding-bottom: 6px; width: fit-content; font-variant-numeric: tabular-nums; }
.stat-label { color: var(--ink); font-size: 14.5px; line-height: 1.4; margin-top: 10px; }
.stat-note { margin-top: 6px; font-size: 11px; }
@media (max-width: 560px) { .stats { grid-template-columns: 1fr 1fr; } .stat { padding: 18px 12px 18px 0 !important; border-left: 0 !important; } .stat:nth-child(even) { padding-left: 16px !important; border-left: 1px solid var(--line) !important; } .stat:nth-child(n+3) { border-top: 1px solid var(--line); } }

/* Justified gallery rows: each item's flex-grow is its aspect ratio, so heights line up with no cropping */
.gallery { display: flex; flex-direction: column; gap: 14px; }
.g-row { display: flex; gap: 14px; }
.g-item { margin: 0; min-width: 0; }
.g-item img, .g-item video { width: 100%; height: auto; border-radius: 4px; }
.g-item button { all: unset; display: block; cursor: zoom-in; width: 100%; border-radius: 4px; }
.g-item button:focus-visible { outline: 2px solid var(--purple); outline-offset: 3px; }
@media (max-width: 640px) {
  .g-row { flex-wrap: wrap; }
  .g-row.n3 .g-item, .g-row.n4 .g-item { flex-basis: calc(50% - 7px) !important; flex-grow: 0 !important; }
  .g-row.n2 .g-item.tallish { flex-basis: calc(50% - 7px) !important; }
}

/* Next project */
.next { display: block; text-decoration: none; padding: 46px 0 64px; border-top: 1px solid var(--line); }
.next-title { font-family: var(--serif); font-weight: 300; font-size: clamp(24px, 2.8vw, 36px); line-height: 1.15; letter-spacing: -.012em; color: var(--ink); margin-top: 12px; max-width: 24em; }
.next-title .arrow { display: inline-block; transition: transform .25s; background: var(--grad-radial); -webkit-background-clip: text; background-clip: text; -webkit-text-fill-color: transparent; }
.next:hover .arrow { transform: translateX(6px); }

/* Lightbox */
.lb { position: fixed; inset: 0; z-index: 100; background: rgba(12,12,12,.92); display: none; align-items: center; justify-content: center; padding: 56px 20px; }
.lb.is-open { display: flex; }
.lb img { max-width: 100%; max-height: 100%; width: auto; height: auto; object-fit: contain; border-radius: 3px; }
.lb button { position: absolute; background: none; border: 0; color: #fff; font: 500 14px var(--mono); letter-spacing: .06em; cursor: pointer; padding: 12px; }
.lb-close { top: 10px; right: 14px; }
.lb-prev, .lb-next { top: 50%; transform: translateY(-50%); font-size: 26px !important; }
.lb-prev { left: 8px; } .lb-next { right: 8px; }

/* ---------- Home ---------- */
.hero { padding: var(--top) 0 44px; position: relative; }
.hero-title { font-family: var(--sans); font-weight: 300; font-size: clamp(24px, 2.6vw, 34px); line-height: 1.18; letter-spacing: -.012em; color: var(--ink); max-width: 20em; margin: 0 0 18px; }
.hero-name { font-weight: 600; font-size: 16px; color: var(--ink); letter-spacing: -.01em; margin: 0 0 clamp(48px, 7vw, 110px); }
.hero-sub { font-size: 16px; font-weight: 400; color: var(--body); letter-spacing: 0; max-width: 34em; margin: 0; }
.hero-flower-box { position: absolute; right: 0; bottom: 18px; }
@media (max-width: 720px) { .hero-flower-box { position: relative; bottom: auto; height: 100px; margin-top: 16px; } }

.work-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 64px 48px; padding: 48px 0 90px; border-top: 1px solid var(--line); scroll-margin-top: var(--nav-h); }
@media (max-width: 760px) { .work-grid { grid-template-columns: 1fr; gap: 48px; } }
.card { text-decoration: none; display: block; }
.card-img { aspect-ratio: 3 / 2; overflow: hidden; border-radius: 4px; background: var(--soft); }
.card-img img { width: 100%; height: 100%; object-fit: cover; transition: transform .6s cubic-bezier(.2,.7,.2,1); }
.card:hover .card-img img { transform: scale(1.03); }
.card-title { font-family: var(--serif); font-weight: 400; font-size: clamp(18px, 1.55vw, 21px); line-height: 1.28; letter-spacing: -.01em; color: var(--ink); margin: 20px 0 10px; }
.card-meta { margin: 0; }
.card-meta span + span::before { content: "|"; margin: 0 .7em; color: #c4c4c4; }

.intro-band { display: grid; grid-template-columns: 1fr 2fr; gap: 48px; padding: 72px 0 90px; border-top: 1px solid var(--line); }
.intro-band h2 { font-family: var(--serif); font-weight: 500; font-size: clamp(25px, 2.5vw, 33px); line-height: 1.18; letter-spacing: -.03em; margin-bottom: 18px; }
.skills { display: flex; flex-wrap: wrap; gap: 8px; list-style: none; padding: 0; margin: 26px 0 0; }
.skills li { font-size: 13.5px; color: var(--ink); border: 1px solid var(--line); border-radius: 999px; padding: 6px 14px; }
.exp { list-style: none; margin: 40px 0 0; padding: 0; border-top: 1px solid var(--line); }
.exp li { display: grid; grid-template-columns: 150px 1fr; gap: 16px; padding: 14px 0; border-bottom: 1px solid var(--line); }
.exp strong { color: var(--ink); font-weight: 600; }
@media (max-width: 760px) { .intro-band { grid-template-columns: 1fr; gap: 10px; } .exp li { grid-template-columns: 1fr; gap: 2px; } }

/* ---------- Simple pages ---------- */
.page-head { padding: var(--top) 0 40px; }
.page-head h1 { font-family: var(--sans); font-weight: 300; font-size: clamp(24px, 2.3vw, 34px); line-height: 1.15; letter-spacing: -.012em; margin: 14px 0 12px; }
.page-head p { font-size: 16px; max-width: 700px; }
.about-grid { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); gap: 64px; padding: 16px 0 90px; align-items: start; }
/* Pixel photo frames + bee */
.pixel-photos { position: relative; width: 100%; max-width: 488px; margin: 0 auto; }
.pf { position: absolute; margin: 0; }
.pf-stamp { transform: rotate(-3deg); }
.pf-polaroid { transform: rotate(4deg); }
.pf-frame { position: relative; display: block; width: 100%; height: auto; image-rendering: pixelated; image-rendering: crisp-edges; }
.pf-photo { position: absolute; object-fit: cover; display: block; max-width: none; }
.pf-polaroid figcaption { position: absolute; left: 0; right: 2.5%; display: flex; align-items: center; justify-content: center; line-height: 1; text-align: center; font: 700 clamp(14px, 1.6vw, 18px) 'Silkscreen', var(--sans); letter-spacing: .06em; text-transform: uppercase; color: #2a2433; }
.pf-bee { position: absolute; width: 8.5%; left: 68%; top: 30.5%; z-index: 3; pointer-events: none; transform: rotate(6deg); }
.pf-bee-flip { transform: scaleX(-1); }
.pf-bee svg { width: 100%; height: auto; display: block; }
.pf-bee .wings { animation: none; }
@keyframes pbee-bob { from { transform: translateY(0); } to { transform: translateY(-3px); } }
@keyframes pbee-flap { 0% { transform: scaleY(1); } 100% { transform: scaleY(.5); } }
@media (prefers-reduced-motion: reduce) { .pf-bee, .pf-bee-flip, .pf-bee svg, .pf-bee .wings { animation: none; } }
.facts { list-style: none; padding: 0; margin: 32px 0 0; border-top: 1px solid var(--line); }
.facts li { display: flex; gap: 14px; align-items: baseline; padding: 14px 0; border-bottom: 1px solid var(--line); color: var(--ink); }
.facts svg { width: 12px; height: 10px; flex: none; transform: translateY(1px); }
@media (max-width: 860px) { .about-grid { grid-template-columns: 1fr; gap: 32px; } }
.contact-big { font-family: var(--serif); font-weight: 500; letter-spacing: -.03em; font-size: clamp(26px, 4vw, 48px); letter-spacing: -.015em; color: var(--ink); text-decoration: none; background: var(--grad-radial); -webkit-background-clip: text; background-clip: text; -webkit-text-fill-color: transparent; word-break: break-word; }
.contact-links { display: flex; gap: 28px; margin: 28px 0 110px; }
.contact-links a { color: var(--ink); font-weight: 500; }
.play-grid { columns: 3 300px; column-gap: 16px; padding: 8px 0 90px; }
.play-grid figure { margin: 0 0 16px; break-inside: avoid; }
.play-grid img { width: 100%; border-radius: 4px; }

/* ---------- Footer ---------- */
.footer { background: #000; color: #fff; }
.footer-top { position: relative; padding-top: 110px; }
.footer-cta { display: inline-block; text-decoration: none; color: #fff; font-family: var(--sans); font-weight: 400; font-size: clamp(34px, 5vw, 64px); line-height: 1.12; letter-spacing: -.01em; padding-bottom: 14px; position: relative; }
.footer-cta .grad { background: var(--grad-radial); -webkit-background-clip: text; background-clip: text; -webkit-text-fill-color: transparent; font-weight: 500; }
.footer-cta::after { content: ""; position: absolute; left: 0; right: 0; bottom: 0; height: 2px; background: var(--grad-radial); transform: scaleX(0); transform-origin: left; transition: transform .5s cubic-bezier(.2,.7,.2,1); }
.footer-cta:hover::after { transform: scaleX(1); }
.footer-garden { position: relative; padding-bottom: 46px; border-bottom: 1px solid #262626; }
.footer-bottom { display: flex; justify-content: space-between; gap: 24px; flex-wrap: wrap; padding: 34px 0 48px; font-size: 15px; }
.footer-bottom p { margin: 0; }
.footer-bottom a { color: #fff; }
.footer-links { display: flex; gap: 30px; }
.footer-links a { text-decoration: none; }
.footer-links a:hover { text-decoration: underline; }


/* Original page layouts: bands of columns, measured from the Webflow site */
main { overflow-x: clip; }
.layout { display: flex; flex-direction: column; gap: 14px; }
.band { display: flex; gap: 14px; align-items: flex-start; }
.col { min-width: 0; display: flex; flex-direction: column; gap: 14px; }
.layout .g-item img, .layout .g-item video { width: 100%; height: auto; object-fit: cover; }
.g-item.yt iframe { display: block; width: 100%; height: auto; border: 0; border-radius: 4px; background: #000; }
.yt-link { display: inline-block; margin-top: 10px; text-decoration: none; }
.yt-link:hover { color: var(--ink); }
@media (max-width: 640px) {
  .band { flex-wrap: wrap; width: 100% !important; }
  .band.n2 .col { flex: 1 1 100% !important; }
  .band.n3 .col, .band.n4 .col, .band.n5 .col { flex: 1 1 calc(50% - 7px) !important; }
}

/* no lone words on a last line */
h1, h2, h3, .card-title, .next-title, .toc-title, .toc-sub { text-wrap: balance; }
p, li, dd, .stat-label { text-wrap: pretty; }
.card-meta span { white-space: nowrap; }

.toc-scope { margin: 0; display: flex; flex-wrap: wrap; row-gap: 2px; font-weight: 600; font-size: 11px; letter-spacing: .05em; text-transform: uppercase; color: #8b8b8b; line-height: 1.7; }
.toc-scope span { white-space: nowrap; }
.toc li a { padding-top: 6px; padding-bottom: 6px; font-size: 14px; }

.toc-scope span.line-start::before { content: none; }

/* floating pair: transparent artwork, centered with generous space between */
.band.float { justify-content: center; align-items: center; gap: clamp(32px, 7vw, 120px); padding: clamp(16px, 3vw, 40px) 0; }
.band.float .g-item { flex: 0 1 38%; }
.band.float .g-item img { border-radius: 0; }
@media (max-width: 640px) { .band.float { flex-wrap: wrap; gap: 28px; } .band.float .g-item { flex: 1 1 100%; } }


/* About page labels: same space above and below each list */
.about-label { margin: 56px 0 14px; }
.about-label + .facts, .about-label + .exp { margin-top: 0; }
.exp li { align-items: baseline; }

/* Odin: click and two pixel hearts (same hearts as the homepage flower) rise from his face and fade */
.pf-polaroid { cursor: pointer; z-index: 2; --px: 3px; }
.pf-polaroid:focus-visible { outline: 2px solid var(--heart); outline-offset: 6px; }
.pf-polaroid .heart {
  position: absolute; left: var(--x); top: var(--y);
  width: calc(var(--px) * 0.75 * 5 * var(--s) * 1.4);
  line-height: 0; pointer-events: none; z-index: 3; opacity: 0;
}
.pf-polaroid .heart svg { display: block; width: 100%; height: auto; }
.pf-polaroid.is-love .heart { animation: odin-heart 1.6s cubic-bezier(.25,.6,.35,1) var(--d) forwards; }
@keyframes odin-heart {
  0%   { opacity: 0; transform: translate(0, 0) scale(.3); }
  18%  { opacity: 1; transform: translate(calc(var(--dx) * .2), -10px) scale(1.1); }
  35%  { transform: translate(calc(var(--dx) * .4), -22px) scale(1); }
  100% { opacity: 0; transform: translate(var(--dx), -78px) scale(1); }
}
@media (prefers-reduced-motion: reduce) { .pf-polaroid.is-love .heart { animation-duration: .9s; } }

/* About: no visible page title; content starts right under the navbar */
.skip-title { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.about-grid { padding-top: var(--top); }
/* About: photos stay in view while the text scrolls (desktop) */
@media (min-width: 861px) { .about-photo { position: sticky; top: calc(var(--nav-h) + 32px); } }

@media (max-width: 640px) { .section { padding-bottom: 72px; } }

.cs-head > .back { margin-top: 0; }
.hero > :first-child, .page-head > :first-child, .cs-head > :first-child { margin-top: 0; }
/* first line on every page sits exactly --top below the navbar */
.page-head > .mono:first-child { display: block; line-height: 1; }
.cs-head > .back { display: flex; width: fit-content; line-height: 1; }
.about-grid { padding-top: calc(var(--top) + 8px); }
.about-grid { padding-top: calc(var(--top) + 5px); }
@media (max-width: 860px) { .about-grid { padding-top: calc(var(--top) + 3px); } }

/* project titles run the full width; only wrap when the screen is too narrow */
.cs-title { text-wrap: pretty; }

/* 404 */
.nf { background: var(--bg); color: var(--ink); min-height: calc(100vh - var(--nav-h)); display: flex; }
.nf-inner { flex: 1; display: flex; flex-direction: column; align-items: center; justify-content: center; text-align: center; padding-block: 64px 80px; }
.nf-digits { width: min(440px, 78%); height: auto; display: block; }
.nf-garden { position: relative; width: min(384px, 100%); aspect-ratio: 128 / 60; margin: 18px auto 0; }
.nf-garden .fp-patch { right: 0; left: 0; margin: 0 auto; }
.nf-title { font: 700 clamp(20px, 2.4vw, 28px) 'Silkscreen', var(--sans); letter-spacing: .04em; text-transform: uppercase; margin: 34px 0 10px; background: var(--grad-radial); -webkit-background-clip: text; background-clip: text; -webkit-text-fill-color: transparent; }
.nf-sub { color: var(--muted); font-size: 16px; margin: 0 0 26px; }
.nf-home { color: var(--ink); font-size: 16px; font-weight: 500; text-decoration: none; position: relative; padding-bottom: 6px; }
.nf-home::after { content: ""; position: absolute; left: 0; right: 0; bottom: 0; height: 2px; background: var(--grad-radial); transform: scaleX(0); transform-origin: left; transition: transform .4s cubic-bezier(.2,.7,.2,1); }
.nf-home:hover::after, .nf-home:focus-visible::after { transform: scaleX(1); }

/* 404 on white: tint the white bell-flower petals so they stay visible */
.nf-garden path[fill="#ffffff"] { fill: #d8cff0; }

/* covers run the full content width */
.cs-cover button { width: 100%; }
.cs-cover img { width: 100%; max-height: none; }

/* sidebar groups (e.g. NRG / San Francisco Shock) */
.toc-group { font-weight: 600; font-size: 11.5px; letter-spacing: .05em; text-transform: uppercase; color: #8b8b8b; padding: 0 0 4px 22px; margin-top: 4px; }
.toc-group ~ .toc-group { margin-top: 20px; }

/* pages without a cover: a rule separates the header from the work */
.cs-body.no-cover { border-top: 1px solid var(--line); }

/* every title uses the same light weight */
.card-title, .intro-band h2 { font-weight: 300; letter-spacing: -.012em; }
/* larger tap areas on small links (looks unchanged) */
.brand, .back, .yt-link { display: inline-flex; align-items: center; min-height: 44px; }
.cs-head > .back { margin-block: -16px -14px; }
.yt-link { margin-top: 0; }

/* ---- consistency pass ---- */
/* one paragraph rhythm everywhere */
main p, .prose, .cs-summary, .hero-sub, .nf-sub, .facts li { line-height: 1.7; }
/* one style for every small uppercase label */
.mono, .back, .toc-group, .chips .chip-group, .stat-note, .cs-meta dt, .toc-label, .card-meta, .yt-link {
  font-family: var(--sans); font-weight: 600; font-size: 12px; letter-spacing: .05em; text-transform: uppercase; color: #8b8b8b;
}
.back:hover, .yt-link:hover { color: var(--ink); }
/* one corner radius for all work images */
.cs-cover img, .g-item img, .g-item video, .card-img, .play-grid img, .g-item.yt iframe { border-radius: 4px; }
/* all section titles the same size */
.section.is-sub h2 { font-size: clamp(21px, 1.8vw, 26px); }
/* homepage headline scales like the project titles */
.hero-title { font-size: clamp(24px, 2.3vw, 34px); }
/* end of a project: one moderate gap before "Next project" */
.cs-content > .section:last-child { padding-bottom: 0; }
.cs-body { padding-bottom: 72px; }
@media (max-width: 640px) { .cs-body { padding-bottom: 56px; } }

/* clients nested under Cavolo */
.exp li.exp-client { border-top: 0; padding-top: 2px; }
.exp li.exp-client > span:last-child { position: relative; padding-left: 18px; }
.exp li.exp-client > span:last-child::before { content: ""; position: absolute; left: 2px; top: 3px; width: 9px; height: 9px; border-left: 1px solid #c4c4c4; border-bottom: 1px solid #c4c4c4; }
.exp-via { display: none; }
.exp li:has(+ .exp-client) { border-bottom: 0; padding-bottom: 6px; }
.exp li.exp-client { padding-top: 6px; padding-bottom: 6px; }
.exp li.exp-client:has(+ .exp-client) { border-bottom: 0; }
.exp li.exp-client:not(:has(+ .exp-client)) { padding-bottom: 14px; }
@media (max-width: 760px) { .exp li.exp-client > span.mono { padding-left: 18px; } }
/* never let a card or tag be wider than the screen */
.work-grid > .card { min-width: 0; }
@media (max-width: 760px) { .work-grid { grid-template-columns: minmax(0, 1fr); } }
.card-meta { display: flex; flex-wrap: wrap; row-gap: 2px; }
.card-meta span { white-space: normal; }
.card-meta span.line-start::before { content: none; }
.chips li { max-width: 100%; }
.chips a { white-space: normal; }
img, video, iframe { max-width: 100%; }
.card-meta span { min-width: 0; overflow-wrap: anywhere; }

/* breaks between image groups, matching the original pages */
.layout-break { height: clamp(28px, 4vw, 56px); }

/* slightly tighter gap between the sidebar and the work */
@media (min-width: 961px) { .cs-body { gap: 36px; } }
/* homepage titles: one line on laptops and desktops */
.card-title { max-width: none; }
/* sidebar heart: no pulse, no slide */
.toc-heart { transition: none; }
.toc-heart svg { animation: none; }
/* homepage previews never wider than their 750px source (stay crisp); extra width goes to the gap between columns */
@media (min-width: 761px) { .work-grid { grid-template-columns: repeat(2, minmax(0, 750px)); justify-content: space-between; column-gap: 48px; } }

/* homepage previews: no zoom on hover (keeps images pixel-sharp); a gentle dim instead */
.card-img img { transition: opacity .25s ease; transform: none !important; will-change: auto; }
.card:hover .card-img img { opacity: 1; }

/* Homepage intro line: a little wider so the longer copy sits on two lines */
.hero-sub { max-width: 42em; }

/* Homepage title matches the intro line width */
.hero-title, .hero-sub { max-width: 672px; }

/* Homepage cards: gradient line draws across the bottom of the image on hover */
.card-img { position: relative; }
.card-img::after { content: ""; position: absolute; left: 0; right: 0; bottom: 0; height: 4px; background: var(--grad); transform: scaleX(0); transform-origin: left; transition: transform .5s cubic-bezier(.2,.7,.2,1); pointer-events: none; }
.card:hover .card-img::after, .card:focus-visible .card-img::after { transform: scaleX(1); }
@media (prefers-reduced-motion: reduce) { .card-img::after { transition: none; } }

/* 404: keep the garden centered (no grass strip extending left on wide screens) */
.nf-garden .fp-ext { display: none !important; }

/* About: still pixel butterfly beside the photos, tilted like the footer one, in the brand gradient colors */
.ab-bfly { position: absolute; z-index: 3; pointer-events: none; }
.ab-bfly svg { display: block; width: 100%; height: auto; transform: rotate(-32deg); }

.hero { display: flex; flex-direction: column; box-sizing: border-box; }

/* Phones: flower sits above the intro text instead of below it */
@media (max-width: 720px) {
  .hero-flower-box { order: -1; position: relative; bottom: auto; height: 100px; margin: 0 0 20px; }
  .hero-flower-box .bee-flower-corner { left: 0; right: auto; bottom: 0; }
}

/* Laptop-height screens: slightly wider-crop previews so the next row of projects peeks in at the bottom, like on big monitors */
@media (min-width: 900px) and (max-height: 960px) {
  .hero { padding-top: 36px; padding-bottom: 32px; }
  .work-grid { padding-top: 36px; row-gap: 48px; }
  .card-img { aspect-ratio: 16 / 9; }
}
@media (min-width: 900px) and (max-height: 880px) { .card-img { aspect-ratio: 2 / 1; } }
@media (min-width: 900px) and (max-height: 780px) { .card-img { aspect-ratio: 12 / 5; } }


/* Homepage About band: content starts on the same line as the right-hand project column */
@media (min-width: 761px) { .intro-band { grid-template-columns: repeat(2, minmax(0, 750px)); justify-content: space-between; column-gap: 48px; } }

/* Scroll reveal: blocks ease up and fade in as they come into view (only when JS is running) */
.js-reveal .rv { opacity: 0; transform: translateY(26px); transition: opacity .9s cubic-bezier(.22,.61,.36,1), transform .9s cubic-bezier(.22,.61,.36,1); transition-delay: var(--rv-d, 0s); }
.js-reveal .rv.in { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) { .js-reveal .rv { opacity: 1; transform: none; transition: none; } }
@media (min-width: 761px) { .intro-band > div { grid-column: 2; } }

/* About: wooden frame with the crochet otter, above the stamp */
.pf-wood { transform: rotate(3deg); z-index: 2; }
/* if the photo collage is taller than the screen, let it scroll normally instead of sticking */
@media (min-width: 861px) and (max-height: 860px) { .about-photo { position: static; } }
