/* Ambika — "postcard" redesign. One stylesheet for every page. */

@font-face { font-family: "Anton"; src: url("fonts/anton.woff2") format("woff2"); font-weight: 400; font-display: swap; }
@font-face { font-family: "DM Mono"; src: url("fonts/dm-mono-400.woff2") format("woff2"); font-weight: 400; font-display: swap; }
@font-face { font-family: "DM Mono"; src: url("fonts/dm-mono-500.woff2") format("woff2"); font-weight: 500; font-display: swap; }
@font-face { font-family: "Instrument Sans"; src: url("fonts/instrument-sans-400.woff2") format("woff2"); font-weight: 400; font-display: swap; }
@font-face { font-family: "Instrument Sans"; src: url("fonts/instrument-sans-500.woff2") format("woff2"); font-weight: 500; font-display: swap; }
@font-face { font-family: "Instrument Sans"; src: url("fonts/instrument-sans-600.woff2") format("woff2"); font-weight: 600; font-display: swap; }

:root {
  /* cobalt blue and grey */
  --cream: #e2e2e2;
  --paper: #f0f0f0;
  --wine: #0052b4;
  --wine-deep: #002454;
  --mustard: #9cc0f0;
  --blush: #eef2fa;
  --line: rgba(0, 82, 180, .32);
  --line-soft: rgba(0, 82, 180, .16);
  --on-wine: #eef2fa;
  --on-wine-soft: rgba(238, 242, 250, .72);

  --display: "Anton", "Impact", "Arial Narrow", sans-serif;
  --mono: "DM Mono", ui-monospace, "SFMono-Regular", Menlo, monospace;
  --sans: "Instrument Sans", system-ui, -apple-system, "Segoe UI", sans-serif;

  --gutter: clamp(16px, 3.4vw, 40px);
  --nav-h: 56px;
  --max: 1440px;
  --ease: cubic-bezier(.2, .8, .2, 1);
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; overflow-x: clip; }
body {
  margin: 0;
  background: var(--cream);
  color: var(--wine);
  font: 400 17px/1.45 var(--sans);
  -webkit-font-smoothing: antialiased;
  overflow-x: clip;
}
img, video { display: block; max-width: 100%; }
a { color: inherit; }
button { font: inherit; color: inherit; }
::selection { background: var(--wine); color: var(--on-wine); }
:focus-visible { outline: 2px solid var(--mustard); outline-offset: 3px; }

.skip { position: absolute; left: 8px; top: -60px; z-index: 200; background: var(--wine-deep); color: var(--on-wine); padding: 10px 14px; font: 500 12px var(--mono); }
.skip:focus { top: 8px; }

.wrap { width: 100%; max-width: var(--max); margin: 0 auto; padding: 0 var(--gutter); }

/* ---------- Type ---------- */
.display {
  font-family: var(--display);
  font-weight: 400;
  text-transform: uppercase;
  line-height: .98;
  letter-spacing: .005em;
  margin: 0;
}
.d-xxl { font-size: clamp(76px, 15vw, 230px); line-height: .9; }
.d-xl { font-size: clamp(64px, 11vw, 168px); line-height: .94; }
.d-l { font-size: clamp(48px, 7.4vw, 112px); }
.d-m { font-size: clamp(32px, 4.2vw, 60px); line-height: 1.02; }
.d-s { font-size: clamp(24px, 2.4vw, 36px); line-height: 1.05; }
.d-xs { font-size: clamp(20px, 1.7vw, 25px); line-height: 1.1; }

.mono {
  font-family: var(--mono);
  font-size: 12px;
  line-height: 1.5;
  letter-spacing: .06em;
  text-transform: uppercase;
}
.lede { font-size: clamp(17px, 1.45vw, 21px); line-height: 1.32; max-width: 33em; margin: 0; text-wrap: pretty; }
.small { font-size: 14px; line-height: 1.45; }
.muted { opacity: .72; }
p { text-wrap: pretty; }

.pill {
  display: inline-flex; align-items: center; gap: 6px;
  border: 1px solid currentColor; border-radius: 999px;
  padding: 6px 14px 5px;
  font: 400 11px/1 var(--mono); letter-spacing: .08em; text-transform: uppercase;
  white-space: nowrap; text-decoration: none;
}
.pills { display: flex; flex-wrap: wrap; gap: 8px; }

.btn {
  display: inline-flex; align-items: center; justify-content: space-between; gap: 22px;
  min-height: 44px; padding: 0 16px 0 18px;
  background: var(--wine); color: var(--on-wine);
  border: 0; border-radius: 0;
  font: 500 12px/1 var(--mono); letter-spacing: .08em; text-transform: uppercase;
  text-decoration: none; cursor: pointer;
  transition: background .25s var(--ease), color .25s var(--ease);
}
.btn svg { width: 14px; height: 14px; transition: transform .3s var(--ease); flex: none; }
.btn:hover { background: var(--wine-deep); }
.btn:hover svg { transform: translateX(4px); }
.btn.light { background: var(--paper); color: var(--wine); }
.btn.light:hover { background: var(--mustard); color: var(--wine-deep); }
.btn.ghost { background: transparent; color: inherit; border: 1px solid currentColor; }
.btn.ghost:hover { background: var(--on-wine); color: var(--wine-deep); }

.link-wavy {
  text-decoration: underline wavy;
  text-decoration-thickness: 1px;
  text-underline-offset: 4px;
  text-decoration-color: currentColor;
}
.link-wavy:hover { text-decoration-color: var(--mustard); }

.rule { border: 0; border-top: 1px solid var(--line); margin: 0; }

/* ---------- Nav: tab row ---------- */
.nav {
  position: sticky; top: 0; z-index: 50;
  height: var(--nav-h);
  display: flex; align-items: stretch; justify-content: space-between;
  background: var(--cream);
  border-bottom: 1px solid var(--line);
}
.brand {
  display: flex; align-items: center; gap: 10px;
  padding: 0 var(--gutter);
  text-decoration: none;
}
.brand-mark { width: 36px; height: 36px; flex: none; transition: transform .6s var(--ease); }
.brand:hover .brand-mark { transform: rotate(-12deg) scale(1.06); }
.brand-name { font: 400 17px/.92 var(--display); text-transform: uppercase; letter-spacing: .01em; }

.tabs { display: flex; align-items: stretch; height: 100%; margin: 0; padding: 0; list-style: none; }
.tabs li { display: flex; }
.nav > nav { display: flex; }
.tab {
  position: relative;
  display: flex; align-items: flex-start;
  width: clamp(92px, 8.4vw, 124px);
  padding: 10px 10px 0;
  border-left: 1px solid var(--line);
  font: 400 15px/1 var(--display); text-transform: uppercase; letter-spacing: .02em;
  text-decoration: none;
  transition: background .3s var(--ease), color .3s var(--ease);
}
.tab::after {
  content: ""; position: absolute; right: 4px; bottom: 4px;
  width: 9px; height: 9px;
  background: currentColor;
  clip-path: polygon(100% 0, 100% 100%, 0 100%);
  transition: width .35s var(--ease), height .35s var(--ease);
}
.tab:hover { background: var(--wine); color: var(--on-wine); }
.tab:hover::after, .tab[aria-current="page"]::after { width: 16px; height: 16px; }
.tab[aria-current="page"] { background: var(--blush); }
.tab.hello { background: var(--wine-deep); color: var(--on-wine); width: clamp(110px, 10.4vw, 152px); }
.tab.hello:hover { background: var(--mustard); color: var(--wine-deep); }
.tab.menu-btn { display: none; background: none; border-top: 0; border-right: 0; border-bottom: 0; cursor: pointer; text-align: left; }

.menu-panel {
  position: fixed; inset: var(--nav-h) 0 0 0; z-index: 49;
  background: var(--wine-deep); color: var(--on-wine);
  padding: 28px var(--gutter);
  display: flex; flex-direction: column; justify-content: space-between;
  transform: translateY(-102%); visibility: hidden;
  transition: transform .55s var(--ease), visibility 0s .55s;
}
.menu-panel.open { transform: none; visibility: visible; transition: transform .55s var(--ease); }
.menu-panel a.big { display: block; font: 400 clamp(48px, 14vw, 88px)/.95 var(--display); text-transform: uppercase; text-decoration: none; }
.menu-panel a.big:hover { color: var(--mustard); }

@media (max-width: 760px) {
  .tabs .tab:not(.hello):not(.menu-btn) { display: none; }
  .tab.menu-btn { display: flex; }
}

/* ---------- Sections ---------- */
section { position: relative; }
.pad { padding-top: clamp(72px, 9vw, 128px); padding-bottom: clamp(72px, 9vw, 128px); }
.wine { background: var(--wine); color: var(--on-wine); }
.wine-deep { background: var(--wine-deep); color: var(--on-wine); }
.wine ::selection, .wine-deep ::selection { background: var(--mustard); color: var(--wine-deep); }
.grid-bg {
  background-image:
    linear-gradient(rgba(247, 233, 225, .08) 1px, transparent 1px),
    linear-gradient(90deg, rgba(247, 233, 225, .08) 1px, transparent 1px);
  background-size: 56px 56px;
}

.head-row { display: flex; flex-wrap: wrap; align-items: flex-end; justify-content: space-between; gap: 24px 48px; }
.head-row .lede { max-width: 26em; }

/* ---------- Hero (home) ---------- */
.hero { padding: 18px 0 0; overflow: hidden; }
.hero-meta {
  display: flex; justify-content: space-between; gap: 16px; flex-wrap: wrap;
  padding-bottom: 12px; border-bottom: 1px solid rgba(247, 233, 225, .5);
}
.status-dot { display: inline-block; width: 8px; height: 8px; border-radius: 50%; background: var(--mustard); margin-right: 8px; vertical-align: 1px; animation: blink 2.4s infinite; }
.cream .status-dot, .status-dot.wine { background: var(--wine); }
@keyframes blink { 0%, 60% { opacity: 1; } 70%, 90% { opacity: .2; } 100% { opacity: 1; } }

.hero-stage { position: relative; display: grid; grid-template-columns: auto 1fr; align-items: end; gap: 24px; padding-top: 28px; }
.reel {
  position: relative; align-self: start;
  display: flex; align-items: flex-start; gap: 12px;
  text-decoration: none; background: none; border: 0; padding: 0; cursor: pointer; color: inherit; text-align: left;
}
.reel-badge { position: relative; width: 92px; height: 92px; flex: none; }
.reel-badge svg.ring { position: absolute; inset: 0; animation: spin 14s linear infinite; }
.reel-badge .play {
  position: absolute; inset: 22px; border-radius: 50%; background: var(--on-wine); color: var(--wine);
  display: grid; place-items: center; transition: transform .35s var(--ease);
}
.reel:hover .play { transform: scale(1.12); }
.reel > span:last-child .mono { gap: 10px; }
.reel-thumb { width: 116px; border: 4px solid var(--on-wine); transform: rotate(-3deg); transition: transform .4s var(--ease); }
.reel:hover .reel-thumb { transform: rotate(2deg) scale(1.04); }
@keyframes spin { to { transform: rotate(360deg); } }

.stretch-word {
  display: flex; align-items: flex-end; justify-content: flex-end;
  font: 400 clamp(92px, 21vw, 330px)/.8 var(--display);
  text-transform: uppercase; color: var(--on-wine);
  user-select: none; margin: 0;
  height: clamp(150px, 31vw, 480px);
}
.stretch-word span {
  display: inline-block; transform-origin: 50% 100%;
  transform: scaleY(var(--sy, 1));
  transition: transform .7s cubic-bezier(.3, 1.5, .5, 1);
}
.hero-foot { display: flex; justify-content: space-between; align-items: flex-end; flex-wrap: wrap; gap: 20px; padding: 18px 0 30px; border-top: 1px solid rgba(247, 233, 225, .5); }
.hero-foot .lede { max-width: 25em; }

@media (max-width: 760px) {
  .hero-stage { grid-template-columns: 1fr; }
  .reel-thumb { display: none; }
  .stretch-word { justify-content: flex-start; }
}

/* ---------- Project rows (home) ---------- */
.proj-row { padding: 40px 0 46px; border-top: 1px solid var(--line); }
.proj-row-head { display: grid; grid-template-columns: 1fr; gap: 16px 48px; align-items: start; margin-bottom: 26px; }
.proj-row-head a { text-decoration: none; }
.proj-row-head a:hover .display { color: var(--wine-deep); }
@media (max-width: 760px) { .proj-row-head { grid-template-columns: 1fr; } }

.strip {
  display: flex; gap: 10px;
  overflow-x: auto; scroll-snap-type: x proximity; scrollbar-width: none;
  margin-right: calc(-1 * var(--gutter));
  padding-right: var(--gutter);
  cursor: grab;
}
.strip::-webkit-scrollbar { display: none; }
.strip.dragging { cursor: grabbing; scroll-snap-type: none; }
.strip figure { margin: 0; flex: none; height: clamp(190px, 20vw, 290px); overflow: hidden; background: var(--paper); scroll-snap-align: start; }
.strip img { height: 100%; width: auto; object-fit: cover; pointer-events: none; transition: transform .8s var(--ease); }
.strip figure:hover img { transform: scale(1.05); }
.strip-foot { display: flex; justify-content: space-between; align-items: center; gap: 16px; flex-wrap: wrap; margin-top: 20px; }

/* ---------- Services: stacked sticky cards ---------- */
.stack { position: relative; }
.stack-card {
  position: sticky; top: calc(var(--nav-h) + 28px);
  display: grid; grid-template-columns: 1.05fr .95fr; gap: 24px;
  min-height: clamp(420px, 58vh, 560px);
  margin: 0 auto 28px; max-width: 980px;
  padding: clamp(24px, 3.6vw, 44px);
  background: var(--paper); color: var(--wine);
  box-shadow: 0 -18px 40px -24px rgba(30, 6, 14, .55);
  overflow: hidden;
}
.stack-card:nth-child(even) { background: var(--wine-deep); color: var(--on-wine); }
.stack-card .num { position: absolute; top: clamp(24px, 3.6vw, 44px); right: clamp(24px, 3.6vw, 44px); font: 400 clamp(40px, 5vw, 64px)/1 var(--display); opacity: .55; }
.stack-card .body { display: flex; flex-direction: column; gap: 16px; position: relative; z-index: 1; }
.stack-card .body .btn { margin-top: auto; align-self: flex-start; }
.inside { list-style: none; padding: 0; margin: 8px 0 0; max-width: 360px; }
.inside li { display: flex; align-items: center; gap: 8px; padding: 4px 0; font: 400 12px/1.4 var(--mono); letter-spacing: .06em; text-transform: uppercase; }
.inside li::after { content: "+"; order: 3; }
.inside li span { order: 2; flex: 1; border-bottom: 1px dotted currentColor; opacity: .5; transform: translateY(-3px); }
.polaroid {
  background: #fffdf8; padding: 12px 12px 44px; position: relative;
  box-shadow: 0 18px 40px -14px rgba(30, 6, 14, .45);
}
.polaroid img { width: 100%; aspect-ratio: 1; object-fit: cover; }
.polaroid figcaption { position: absolute; left: 14px; bottom: 12px; font: 400 12px var(--mono); color: var(--wine); }
.stack-card .polaroid { align-self: center; justify-self: end; width: min(100%, 330px); transform: rotate(var(--rot, 8deg)); transition: transform .9s var(--ease); }
@media (max-width: 760px) {
  .stack-card { grid-template-columns: 1fr; min-height: 0; }
  .stack-card .polaroid { justify-self: center; width: 70%; }
  .stack-card .num { font-size: 30px; }
  .stack-card h3 { padding-right: 44px; }
}

/* ---------- Process ---------- */
.steps { display: grid; grid-template-columns: repeat(4, 1fr); gap: 20px; }
.step { border-top: 1px solid var(--line); padding-top: 14px; }
.step h3 { margin: 10px 0 10px; }
.step p { margin: 0; font-size: 15px; }
.steps.three { grid-template-columns: repeat(3, 1fr); }
@media (max-width: 900px) { .steps, .steps.three { grid-template-columns: 1fr 1fr; } }
@media (max-width: 560px) { .steps, .steps.three { grid-template-columns: 1fr; } }

/* ---------- Stickers board ---------- */
.board { position: relative; min-height: clamp(460px, 70vh, 640px); overflow: hidden; cursor: pointer; display: grid; place-items: center; text-align: center; user-select: none; }
.board .hint { position: relative; z-index: 2; pointer-events: none; }
.board .name-tag {
  position: absolute; left: 6%; top: 12%; transform: rotate(-8deg);
  background: var(--paper); color: var(--wine); border-radius: 999px; padding: 10px 26px 12px;
  box-shadow: 0 10px 24px -10px rgba(0, 0, 0, .4);
  text-align: center;
}
.sticker {
  position: absolute; z-index: 3; max-width: 230px;
  padding: 14px 16px 16px;
  font: 500 15px/1.3 var(--sans); text-align: left;
  box-shadow: 0 12px 28px -12px rgba(0, 0, 0, .5);
  animation: stick .5s cubic-bezier(.3, 1.6, .5, 1) both;
  cursor: grab;
}
.sticker .mono { display: block; margin-bottom: 6px; font-size: 10px; opacity: .7; }
.sticker.s0 { background: var(--mustard); color: var(--wine-deep); }
.sticker.s1 { background: var(--paper); color: var(--wine); border-radius: 18px; }
.sticker.s2 { background: var(--blush); color: var(--wine-deep); border-radius: 50% 50% 46% 54% / 50% 46% 54% 50%; padding: 26px 24px; max-width: 210px; text-align: center; }
.sticker.s3 { background: var(--wine-deep); color: var(--on-wine); outline: 2px dashed rgba(247, 233, 225, .5); outline-offset: -7px; }
@keyframes stick { from { transform: translate(-50%, -50%) rotate(var(--r)) scale(.2); opacity: 0; } to { transform: translate(-50%, -50%) rotate(var(--r)) scale(1); opacity: 1; } }

/* ---------- Postcards (work history) ---------- */
.cards-stage { position: relative; height: clamp(420px, 46vw, 520px); margin-top: 40px; overflow: hidden; }
.postcard {
  position: absolute; left: 50%; top: 10px;
  width: clamp(240px, 26vw, 300px);
  padding: 22px 20px 18px;
  background: var(--paper); color: var(--wine);
  /* each edge gets its own row of notches, spaced to fit that edge exactly, so the bottom matches the top */
  --perf: radial-gradient(circle at 50% 0, transparent 5px, #000 5.5px) top / 16px 8px round no-repeat,
          radial-gradient(circle at 50% 100%, transparent 5px, #000 5.5px) bottom / 16px 8px round no-repeat,
          radial-gradient(circle at 0 50%, transparent 5px, #000 5.5px) left / 8px 16px no-repeat round,
          radial-gradient(circle at 100% 50%, transparent 5px, #000 5.5px) right / 8px 16px no-repeat round,
          linear-gradient(#000 0 0) center / calc(100% - 15px) calc(100% - 15px) no-repeat;
  -webkit-mask: var(--perf);
  mask: var(--perf);
  transition: transform .8s var(--ease), opacity .8s var(--ease), filter .8s var(--ease);
  transform-origin: 50% 120%;
}
.postcard .stamp-img { position: absolute; right: 18px; top: 18px; width: 56px; height: 64px; padding: 4px; background: #fffdf8; box-shadow: 0 0 0 1px var(--line-soft); transform: rotate(4deg); }
.postcard .stamp-img img { width: 100%; height: 100%; object-fit: cover; }
.postcard h3 { margin: 6px 64px 14px 0; }
.postcard dl { margin: 0 0 14px; display: grid; grid-template-columns: auto 1fr; gap: 6px 12px; border-top: 1px solid var(--line); padding-top: 10px; font-size: 15px; }
.postcard dt { font: 400 11px/1.6 var(--mono); text-transform: uppercase; letter-spacing: .06em; }
.postcard dd { margin: 0; border-bottom: 1px solid var(--line); padding-bottom: 6px; }
.postcard p { margin: 0 0 16px; font-size: 15px; }
.postcard .foot { display: flex; justify-content: space-between; font: 400 10px var(--mono); letter-spacing: .06em; text-transform: uppercase; }
.cards-nav { display: flex; justify-content: center; gap: 8px; margin-top: 12px; }
.sq-btn { width: 44px; height: 44px; display: grid; place-items: center; background: transparent; border: 1px solid currentColor; cursor: pointer; transition: background .25s, color .25s; }
.sq-btn:hover { background: var(--on-wine); color: var(--wine); }
.cream .sq-btn:hover { background: var(--wine); color: var(--on-wine); }

/* ---------- FAQ envelopes ---------- */
.faq { display: grid; grid-template-columns: minmax(240px, .8fr) 1.2fr; gap: 40px; align-items: start; }
@media (max-width: 860px) { .faq { grid-template-columns: 1fr; } }
.env { position: relative; background: var(--paper); color: var(--wine); margin-bottom: 14px; }
.env::before {
  content: ""; position: absolute; left: 0; right: 0; top: 0; height: 64px;
  background: linear-gradient(to bottom right, transparent 49.6%, var(--line-soft) 50%, transparent 50.6%) left / 50.2% 100% no-repeat,
              linear-gradient(to bottom left, transparent 49.6%, var(--line-soft) 50%, transparent 50.6%) right / 50.2% 100% no-repeat;
  pointer-events: none;
}
.env summary {
  list-style: none; cursor: pointer;
  display: flex; flex-direction: column; align-items: flex-start; gap: 20px;
  padding: 18px 22px 24px;
}
.env summary::-webkit-details-marker { display: none; }
.env .seal {
  align-self: center; width: 34px; height: 34px; border-radius: 50%;
  display: grid; place-items: center; position: relative; z-index: 1;
  background: var(--wine); color: var(--on-wine);
  font: 400 20px/1 var(--sans);
  transition: transform .4s var(--ease), background .3s;
}
.env[open] .seal { transform: rotate(45deg); background: var(--mustard); color: var(--wine-deep); }
.env .answer { padding: 0 22px 24px; max-width: 40em; }
.env .answer p { margin: 0; }
.env summary:hover .seal { transform: scale(1.12); }
.env[open] summary:hover .seal { transform: rotate(45deg) scale(1.12); }

/* ---------- Say-hello ring ---------- */
.ring-sec { position: relative; overflow: hidden; height: clamp(600px, 78vw, 1000px); }
.ring-sec .orbit { position: absolute; left: 50%; top: 50%; width: 0; height: 0; }
.ring-sec .orbit-line { position: absolute; left: 50%; top: 50%; border: 1px solid rgba(247, 233, 225, .2); border-radius: 50%; transform: translate(-50%, -50%); pointer-events: none; }
.ring-sec .spinner { position: absolute; left: 0; top: 0; width: 0; height: 0; will-change: transform; }
.ring-sec .pol {
  position: absolute; left: 0; top: 0;
  width: clamp(92px, 12vw, 150px);
  background: #fffdf8; padding: 7px 7px 26px;
  box-shadow: 0 16px 30px -12px rgba(0, 0, 0, .5);
  transition: scale .4s var(--ease);
}
.ring-sec .pol img { width: 100%; aspect-ratio: 1; object-fit: cover; }
.ring-sec .pol:hover { scale: 1.12; z-index: 2; }
.greet {
  position: absolute; left: 50%; top: 50%; transform: translate(-50%, -50%);
  z-index: 3; text-align: center; white-space: nowrap;
  display: flex; flex-direction: column; align-items: center; gap: 22px;
}
.greet-word { display: flex; justify-content: center; font: 400 clamp(52px, 9vw, 136px)/.86 var(--display); text-transform: uppercase; color: var(--on-wine); text-decoration: none; }
.greet-word .slot { display: inline-block; overflow: hidden; height: .9em; vertical-align: top; }
.greet-word .slot > span { display: block; transition: transform .6s cubic-bezier(.6, 0, .2, 1); }
.greet-word .slot > span > span { display: block; height: .9em; }
@media (max-width: 640px) {
  .ring-sec .pol:nth-child(even) { display: none; }
  .greet-word { flex-direction: column; align-items: center; }
}

/* ---------- Footer envelope ---------- */
.footer { position: relative; padding: 40px 0 28px; overflow: hidden; }
.env-wrap { position: relative; max-width: 1240px; margin: 0 auto; padding-top: 12px; overflow: hidden; }
.letter {
  position: relative; z-index: 1;
  width: 86%; margin: 0 auto -1px;
  background: var(--paper); color: var(--wine);
  padding: clamp(24px, 3.4vw, 40px) clamp(22px, 4vw, 48px) 90px;
  transform: translateY(var(--lift, 70%));
  transition: transform .2s linear;
}
.letter .cols { display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; }
.letter .cols a { display: block; text-decoration: none; font-size: 17px; line-height: 1.55; }
.letter .cols a:hover { color: var(--wine-deep); text-decoration: underline wavy; text-decoration-thickness: 1px; text-underline-offset: 3px; }
.letter .top { display: flex; justify-content: space-between; align-items: flex-start; gap: 20px; margin-bottom: 30px; }
.postmark { width: 120px; height: 70px; flex: none; }
@media (max-width: 640px) { .letter .cols { grid-template-columns: 1fr 1fr; } .letter { width: 94%; } .postmark { display: none; } }

.envelope {
  position: relative; z-index: 2;
  background: var(--paper); color: var(--wine);
  padding: clamp(36px, 5vw, 64px) clamp(24px, 4vw, 48px) clamp(24px, 3vw, 36px);
  border: 10px solid transparent;
  border-image: repeating-linear-gradient(-45deg, var(--wine) 0 14px, var(--paper) 14px 26px, var(--mustard) 26px 40px, var(--paper) 40px 52px) 10;
  display: flex; justify-content: space-between; align-items: flex-end; gap: 24px; flex-wrap: wrap;
}
.envelope address { font-style: normal; font-size: clamp(17px, 1.5vw, 21px); line-height: 1.3; }
.envelope .credit { text-align: right; font-size: 13px; }

/* ---------- Work index ---------- */
.page-head { padding-top: clamp(40px, 6vw, 80px); padding-bottom: clamp(36px, 5vw, 64px); }
.page-head .lede { margin-top: 20px; }
.work-grid { display: grid; grid-template-columns: 1fr 1fr; gap: clamp(48px, 6vw, 88px) clamp(20px, 2.6vw, 36px); padding-bottom: clamp(80px, 10vw, 140px); }
@media (max-width: 760px) { .work-grid { grid-template-columns: 1fr; } }
.wcard { position: relative; text-decoration: none; display: block; }
.wcard .img { position: relative; aspect-ratio: 11 / 10; overflow: hidden; background: var(--paper); }
.wcard .img img { width: 100%; height: 100%; object-fit: cover; transition: transform 1s var(--ease); }
.wcard:hover .img img { transform: scale(1.06); }
.wcard .pm { position: absolute; right: -14px; top: -26px; width: clamp(96px, 9vw, 128px); z-index: 2; transition: transform .8s var(--ease); pointer-events: none; }
.wcard:hover .pm { transform: rotate(-24deg) scale(1.06); }
.wcard .title-row { display: flex; align-items: center; gap: 12px; margin-top: 18px; }
.wcard .new { background: var(--wine); color: var(--on-wine); font: 500 10px/1 var(--mono); padding: 4px 6px; letter-spacing: .08em; }
.wcard .desc { margin: 8px 0 22px; max-width: 24em; min-height: calc(2 * 1.45em); line-height: 1.45; }
.wcard .meta { display: flex; justify-content: space-between; gap: 12px; border-top: 1px solid var(--line); padding-top: 12px; }

/* ---------- Project page ---------- */
.back { display: inline-flex; gap: 8px; align-items: center; text-decoration: none; padding: 22px 0 10px; }
.back:hover { text-decoration: underline; }
.back svg, .mono svg { width: 14px; height: 14px; flex: none; }
.facts { display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px; border-top: 1px solid var(--line); padding: 14px 0 24px; margin-top: 30px; }
.facts dt { margin-bottom: 4px; }
.facts dd { margin: 0; font-size: 15px; }
@media (max-width: 760px) { .facts { grid-template-columns: 1fr 1fr; } }
.cover { width: 100%; aspect-ratio: 16 / 8.4; object-fit: cover; background: var(--paper); }
.story { max-width: 760px; margin: 0 auto; padding: clamp(60px, 8vw, 110px) var(--gutter); }
.story h2 { margin: 0 0 20px; }
.story h3 { margin: 40px 0 10px; }
.story p { margin: 0 0 14px; font-size: 17px; }
.table { width: 100%; border-collapse: collapse; border: 1px solid var(--wine); margin: 8px 0 20px; font-size: 14px; }
.table th, .table td { text-align: left; padding: 8px 12px; border-bottom: 1px solid var(--line); vertical-align: top; }
.table th { font: 500 11px var(--mono); text-transform: uppercase; letter-spacing: .06em; border-bottom-color: var(--wine); }
.table tr:last-child td { border-bottom: 0; }
.swatches { display: flex; flex-wrap: wrap; gap: 8px; margin: 8px 0 20px; }
.swatch { width: 96px; font: 400 11px/1.3 var(--mono); }
.swatch i { display: block; height: 56px; margin-bottom: 6px; box-shadow: inset 0 0 0 1px var(--line-soft); }
.gallery { display: grid; grid-template-columns: 1fr 1fr; gap: clamp(12px, 1.6vw, 20px); padding: 0 var(--gutter) clamp(80px, 9vw, 120px); max-width: var(--max); margin: 0 auto; }
.gallery figure { margin: 0; overflow: hidden; background: var(--paper); }
.gallery figure.wide { grid-column: 1 / -1; }
.gallery img, .gallery video { width: 100%; height: 100%; object-fit: cover; }
.gallery figure:not(.wide) img { aspect-ratio: 4 / 5; }
.gallery figure.contain img { object-fit: contain; }
@media (max-width: 640px) { .gallery { grid-template-columns: 1fr; } .gallery figure:not(.wide) img { aspect-ratio: 1; } }
.credits { display: grid; grid-template-columns: auto 1fr; gap: 6px 20px; font-size: 15px; margin: 12px 0 0; }
.credits dt { font: 400 11px/1.9 var(--mono); text-transform: uppercase; letter-spacing: .06em; }
.credits dd { margin: 0; }

.pn { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; }
.pn a { text-decoration: none; display: block; }
.pn .img { aspect-ratio: 16 / 9; overflow: hidden; margin: 12px 0 14px; background: rgba(0, 0, 0, .15); }
.pn img { width: 100%; height: 100%; object-fit: cover; transition: transform 1s var(--ease); }
.pn a:hover img { transform: scale(1.05); }
.pn .ttl { display: flex; align-items: center; gap: 8px; }
@media (max-width: 640px) { .pn { grid-template-columns: 1fr; } }

/* ---------- About ---------- */
.about-head { display: grid; grid-template-columns: 1fr auto; gap: 24px; align-items: start; }
.about-head .d-xl { line-height: 1.06; } /* room for the comma after Namaste, which drops below the line */
.badge { width: clamp(90px, 11vw, 150px); animation: spin 22s linear infinite; }
.badge-wrap { position: relative; }
.badge-wrap .mark { position: absolute; inset: 0; display: grid; place-items: center; font: 400 clamp(36px, 5vw, 64px)/1 var(--display); color: var(--on-wine); pointer-events: none; }
.about-sub { display: grid; grid-template-columns: 1fr auto; gap: 24px 48px; align-items: start; margin-top: 30px; }
@media (max-width: 760px) { .about-sub { grid-template-columns: 1fr; } }
@media (max-width: 560px) { .about-head { grid-template-columns: 1fr; } .badge-wrap { display: none; } }
.duo { width: 100%; aspect-ratio: 16 / 7; object-fit: cover; margin-top: 28px; filter: grayscale(1) contrast(1.05); mix-blend-mode: multiply; }
.duo-wrap { background: var(--wine); }

.timeline { display: grid; grid-template-columns: minmax(200px, .8fr) 1.2fr; gap: 40px; }
.timeline .sticky { position: sticky; top: calc(var(--nav-h) + 40px); align-self: start; }
.tl-item { border-top: 1px solid var(--line); padding: 14px 0 64px; }
.tl-item h3 { margin: 6px 0 10px; }
.tl-item p { margin: 0 0 18px; max-width: 34em; }
.tl-item img { width: 100%; max-width: 560px; aspect-ratio: 16 / 10; object-fit: cover; }
.tl-item .logo { width: 72px; height: 72px; border-radius: 12px; }
@media (max-width: 760px) { .timeline { grid-template-columns: 1fr; } .timeline .sticky { position: static; } }

.bento { display: grid; grid-template-columns: repeat(4, 1fr); grid-template-rows: auto auto; gap: 12px; }
.bento .wide2 { grid-column: span 2; }
.bento > div { position: relative; padding: 18px; min-height: 230px; display: flex; flex-direction: column; justify-content: space-between; gap: 14px; overflow: hidden; }
.bento .tall { grid-row: span 2; }
.bento .paper { background: var(--paper); border: 1px solid var(--line-soft); }
.bento .ink { background: var(--wine); color: var(--on-wine); }
.bento .deep { background: var(--wine-deep); color: var(--on-wine); }
.bento .photo { background-size: cover; background-position: center; color: var(--on-wine); }
.bento .photo::before { content: ""; position: absolute; inset: 0; background: linear-gradient(180deg, rgba(62, 20, 36, .1), rgba(62, 20, 36, .85)); }
.bento .photo > * { position: relative; }
.bento .top { display: flex; justify-content: space-between; }
@media (max-width: 860px) { .bento { grid-template-columns: 1fr 1fr; } .bento .tall { grid-row: auto; } .bento .wide2 { grid-column: 1 / -1; } }
@media (max-width: 520px) { .bento { grid-template-columns: 1fr; } }

.note {
  position: relative; max-width: 980px; margin: 0 auto;
  background: var(--paper); color: var(--wine);
  padding: clamp(28px, 5vw, 64px);
  /* each edge gets its own row of notches, spaced to fit that edge exactly */
  --perf: radial-gradient(circle at 50% 0, transparent 6px, #000 6.5px) top / 18px 9px round no-repeat,
          radial-gradient(circle at 50% 100%, transparent 6px, #000 6.5px) bottom / 18px 9px round no-repeat,
          radial-gradient(circle at 0 50%, transparent 6px, #000 6.5px) left / 9px 18px no-repeat round,
          radial-gradient(circle at 100% 50%, transparent 6px, #000 6.5px) right / 9px 18px no-repeat round,
          linear-gradient(#000 0 0) center / calc(100% - 17px) calc(100% - 17px) no-repeat;
  -webkit-mask: var(--perf);
  mask: var(--perf);
}
.note blockquote { margin: 26px 0 22px; }
.note .sign { display: flex; align-items: center; gap: 12px; border-top: 1px solid var(--line); padding-top: 16px; margin-top: 28px; }
.note .sign img { width: 44px; height: 44px; object-fit: cover; padding: 3px; background: #fffdf8; box-shadow: 0 0 0 1px var(--line-soft); }
.note .postmark { position: absolute; right: clamp(20px, 4vw, 48px); top: clamp(20px, 4vw, 40px); width: 150px; height: 86px; }

.tools { display: grid; grid-template-columns: 1fr 1fr; gap: 40px; }
.tools ul { list-style: none; margin: 14px 0 0; padding: 0; }
.tools li { display: flex; justify-content: space-between; border-top: 1px solid var(--line); padding: 10px 0; }
@media (max-width: 760px) { .tools { grid-template-columns: 1fr; } }

/* ---------- Playground ---------- */
.pin-board { columns: 4 220px; column-gap: 18px; padding-bottom: clamp(80px, 10vw, 130px); }
.pin-board figure { break-inside: avoid; margin: 0 0 22px; display: inline-block; width: 100%; }
.pin-board .polaroid { padding: 10px 10px 40px; transform: rotate(var(--rot, 0deg)); transition: transform .5s var(--ease); }
.pin-board .polaroid:hover { transform: rotate(0deg) scale(1.03); }
.pin-board .polaroid img { aspect-ratio: auto; }
/* motion plays on its own while it is on screen; films play in place; sound has its own player */
.pin-board .polaroid video { width: 100%; display: block; background: #000; }
.pin-board .polaroid .vimeo-play { width: 54px; }
.pin-board .polaroid .vimeo-play::after { border-width: 10px 0 10px 17px; }
/* films and motion: big, straight players, two to a row, one on phones, so they're comfortable to watch */
.video-wall { padding-bottom: clamp(50px, 7vw, 90px); }
.video-wall h2, .vw-h2 { margin: 0 0 22px; }
.vw-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: clamp(18px, 2.4vw, 32px); }
.vw-grid figure { margin: 0; }
.vw-grid .polaroid { padding: 12px 12px 46px; }
.vw-grid .polaroid video { width: 100%; aspect-ratio: 16 / 9; display: block; background: #000; object-fit: cover; }
.vw-grid .polaroid figcaption { font-size: 13px; bottom: 15px; }
@media (max-width: 760px) { .vw-grid { grid-template-columns: 1fr; } }
.pin-board .polaroid audio { width: 100%; height: 36px; display: block; margin-top: 8px; }

/* ---------- Contact ---------- */
.contact-grid { display: grid; grid-template-columns: 1.1fr .9fr; gap: clamp(28px, 4vw, 56px); align-items: start; }
@media (max-width: 900px) { .contact-grid { grid-template-columns: minmax(0, 1fr); } }
.pc-form {
  position: relative; background: var(--paper); padding: clamp(24px, 3.4vw, 40px);
  /* each edge gets its own row of notches, spaced to fit that edge exactly */
  --perf: radial-gradient(circle at 50% 0, transparent 6px, #000 6.5px) top / 18px 9px round no-repeat,
          radial-gradient(circle at 50% 100%, transparent 6px, #000 6.5px) bottom / 18px 9px round no-repeat,
          radial-gradient(circle at 0 50%, transparent 6px, #000 6.5px) left / 9px 18px no-repeat round,
          radial-gradient(circle at 100% 50%, transparent 6px, #000 6.5px) right / 9px 18px no-repeat round,
          linear-gradient(#000 0 0) center / calc(100% - 17px) calc(100% - 17px) no-repeat;
  -webkit-mask: var(--perf);
  mask: var(--perf);
}
.pc-form .head { display: flex; justify-content: space-between; align-items: flex-start; gap: 20px; margin-bottom: 30px; }
.pc-form .stamp { width: 64px; height: 74px; padding: 6px; background: #fffdf8; box-shadow: 0 0 0 1px var(--line-soft); transform: rotate(4deg); display: grid; place-items: center; }
.pc-form .cols { display: grid; grid-template-columns: 1fr 1fr; gap: 0 28px; }
.pc-form .cols > div:first-child { border-right: 1px solid var(--line); padding-right: 28px; }
@media (max-width: 640px) { .pc-form .cols { grid-template-columns: 1fr; } .pc-form .cols > div:first-child { border-right: 0; padding-right: 0; padding-bottom: 26px; margin-bottom: 22px; border-bottom: 1px solid var(--line); } }
.field { display: block; margin-bottom: 18px; }
.field .mono { display: block; margin-bottom: 4px; font-size: 11px; }
.field input, .field textarea {
  width: 100%; border: 0; border-bottom: 1px solid var(--line); background: transparent; color: var(--wine);
  font: 400 16px/1.9 var(--sans); padding: 2px 0; border-radius: 0;
}
.field textarea { resize: vertical; min-height: 140px; background: repeating-linear-gradient(transparent 0 29px, var(--line-soft) 29px 30px); line-height: 30px; border-bottom: 0; }
.field input::placeholder, .field textarea::placeholder { color: color-mix(in srgb, var(--wine) 50%, transparent); }
.field input:focus, .field textarea:focus { outline: none; border-bottom-color: var(--wine); }
.chips { display: flex; flex-wrap: wrap; gap: 6px; }
.chip { position: relative; }
.chip input { position: absolute; opacity: 0; inset: 0; cursor: pointer; }
.chip span { display: inline-flex; align-items: center; gap: 6px; border: 1px solid var(--line); border-radius: 999px; padding: 6px 12px 5px; font: 400 11px/1 var(--mono); letter-spacing: .06em; text-transform: uppercase; transition: background .2s, color .2s; }
.chip span::before { content: ""; width: 9px; height: 9px; border: 1px solid currentColor; border-radius: 2px; }
.chip.radio span::before { border-radius: 50%; }
.chip input:checked + span { background: var(--wine); color: var(--on-wine); border-color: var(--wine); }
.chip input:checked + span::before { background: var(--mustard); border-color: var(--mustard); }
.chip input:focus-visible + span { outline: 2px solid var(--mustard); outline-offset: 2px; }
.pc-form .bottom { display: flex; justify-content: space-between; align-items: center; gap: 16px; flex-wrap: wrap; margin-top: 18px; }
.ways .row { display: flex; justify-content: space-between; align-items: center; gap: 16px; border-top: 1px solid var(--line); padding: 14px 0; }
.ways .row:last-child { border-bottom: 1px solid var(--line); }
.ways .row .right { text-align: right; }

/* ---------- Motion helpers ---------- */
.reveal { opacity: 0; transform: translateY(28px); transition: opacity .9s var(--ease), transform .9s var(--ease); transition-delay: var(--d, 0s); }
.reveal.in { opacity: 1; transform: none; }
.scramble { white-space: pre-line; }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .01ms !important; animation-iteration-count: 1 !important; transition-duration: .01ms !important; scroll-behavior: auto !important; }
  .reveal { opacity: 1; transform: none; }
  .letter { transform: none; }
  .env-flap { transform: perspective(900px) rotateX(180deg); z-index: 0; }
}

.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; border: 0; }

dialog.reel-dlg { border: 0; padding: 0; background: transparent; max-width: min(92vw, 1100px); width: 100%; }
dialog.reel-dlg::backdrop { background: rgba(30, 6, 14, .86); }
dialog.reel-dlg video { width: 100%; }
dialog.reel-dlg .close { position: absolute; right: 0; top: -52px; width: 44px; height: 44px; background: var(--on-wine); color: var(--wine); border: 0; cursor: pointer; font: 400 22px/1 var(--sans); }

/* ===================== Template-matching components ===================== */

/* project rows: uniform portrait tiles */
.strip figure { width: clamp(170px, 15.6vw, 236px); height: auto; aspect-ratio: 3 / 4; }
.strip img { width: 100%; height: 100%; object-fit: cover; }
.strip figure:first-child { width: clamp(64px, 5.4vw, 82px); }

/* hero caption under the reel thumb */
.reel-cap { display: flex; justify-content: space-between; gap: 10px; margin-top: 8px; }

/* buttons */
.btn.block { display: flex; width: 100%; margin-top: auto; }
.btn.ghost-ink { background: transparent; color: var(--wine); border: 1px solid var(--wine); }
.btn.ghost-ink:hover { background: var(--wine); color: var(--on-wine); }

/* ways to work together: 2 x 2 cards with perforated stamps */
.offers { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
@media (max-width: 760px) { .offers { grid-template-columns: 1fr; } }
.offer { display: flex; flex-direction: column; padding: clamp(22px, 2.6vw, 34px); background: var(--paper); border: 1px solid var(--line-soft); min-height: 520px; }
.offer.ink { background: var(--wine); color: var(--on-wine); border-color: var(--wine); }
.offer-top { display: flex; justify-content: space-between; align-items: flex-start; gap: 16px; margin-bottom: 40px; }
.offer-top h3 { margin: 6px 0 0; }
.stamp {
  flex: none; width: 112px; padding: 12px 6px 10px; text-align: center; transform: rotate(4deg);
  display: flex; flex-direction: column; align-items: center; gap: 2px;
  background: var(--wine); color: var(--on-wine);
  box-shadow: 0 10px 20px -10px rgba(30, 6, 14, .6);
  --perf: radial-gradient(circle at 50% 0, transparent 3.5px, #000 4.0px) top / 10px 5px round no-repeat, radial-gradient(circle at 50% 100%, transparent 3.5px, #000 4.0px) bottom / 10px 5px round no-repeat, radial-gradient(circle at 0 50%, transparent 3.5px, #000 4.0px) left / 5px 10px no-repeat round, radial-gradient(circle at 100% 50%, transparent 3.5px, #000 4.0px) right / 5px 10px no-repeat round, linear-gradient(#000 0 0) center / calc(100% - 9px) calc(100% - 9px) no-repeat;
  -webkit-mask: var(--perf); mask: var(--perf);
}
.stamp b { font: 400 30px/1 var(--display); letter-spacing: .01em; }
.stamp .mono { font-size: 9px; }
.offer.ink .stamp { background: var(--paper); color: var(--wine); }
.offer:nth-child(4) .stamp { transform: rotate(-5deg); }
.offer-desc { margin: 0 0 22px; padding-bottom: 22px; border-bottom: 1px solid currentColor; border-bottom-color: color-mix(in srgb, currentColor 25%, transparent); max-width: 26em; }
.ticks { list-style: none; margin: 0 0 30px; padding: 0; }
.ticks li { display: flex; gap: 10px; align-items: center; padding: 4px 0; font-size: 15px; }
.ticks svg { width: 12px; height: 12px; flex: none; }
.offers-foot { display: flex; align-items: baseline; gap: 24px; flex-wrap: wrap; border-top: 1px solid var(--line); margin-top: 28px; padding-top: 18px; }

/* every project: index list with a peek image that follows the pointer */
.index { position: relative; border-top: 1px solid var(--line); }
.ix-row { display: grid; grid-template-columns: 80px 1fr 1fr 40px; align-items: center; gap: 20px; padding: 16px 12px; border-bottom: 1px solid var(--line); text-decoration: none; transition: background .3s var(--ease), color .3s var(--ease); }
.ix-name { font-size: clamp(30px, 3.6vw, 52px); line-height: 1; text-align: right; text-transform: uppercase; }
.ix-arrow svg { width: 20px; height: 20px; transition: transform .3s var(--ease); }
.ix-row:hover { background: var(--wine); color: var(--on-wine); }
.ix-row:hover .ix-arrow svg { transform: translateX(6px); }
.ix-peek { position: absolute; left: 50%; top: 50%; width: 200px; aspect-ratio: 1; overflow: hidden; pointer-events: none; z-index: 5; opacity: 0; transform: translate(-50%, -50%) scale(.6) rotate(-4deg); transition: opacity .25s, transform .35s var(--ease); box-shadow: 0 18px 40px -16px rgba(30, 6, 14, .6); }
.ix-peek.on { opacity: 1; transform: translate(-50%, -50%) scale(1) rotate(-4deg); }
.ix-peek img { width: 100%; height: 100%; object-fit: cover; }
@media (max-width: 640px) { .ix-row { grid-template-columns: 1fr auto; } .ix-row .mono:first-child, .ix-genre { display: none; } .ix-name { text-align: left; } .ix-peek { display: none; } }

/* sticker board tooltip */
.board-tip { position: absolute; left: 0; top: 0; z-index: 4; pointer-events: none; background: var(--on-wine); color: var(--wine); padding: 5px 8px; font-size: 10px; opacity: 0; transition: opacity .2s; white-space: nowrap; }
.board:hover .board-tip { opacity: 1; }
@media (hover: none) { .board-tip { display: none; } }

/* photo band */
.band { position: relative; contain: paint; height: clamp(420px, 52vw, 680px); overflow: hidden; background: var(--wine-deep); color: var(--on-wine); }
.band-img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; filter: grayscale(1) blur(2px) contrast(1.05); opacity: .55; transform: scale(1.05); }
.band-in { position: relative; height: 100%; display: flex; flex-direction: column; justify-content: space-between; padding-top: clamp(40px, 6vw, 80px); padding-bottom: 28px; }
/* without a photo the band only needs room for its words */
.band:not(:has(.band-img)) { height: auto; }
.band:not(:has(.band-img)) .band-in { gap: clamp(56px, 8vw, 110px); }
.band-text { font-size: clamp(18px, 1.9vw, 26px); line-height: 1; max-width: 21em; }
.band-foot { display: flex; justify-content: space-between; align-items: center; gap: 16px; flex-wrap: wrap; border-top: 1px solid rgba(247, 233, 225, .35); padding-top: 18px; }

/* process: accordion rows */
.process { border-top: 1px solid var(--line); }
.pr-row { border-bottom: 1px solid var(--line); }
.pr-row summary { list-style: none; cursor: pointer; display: grid; grid-template-columns: minmax(110px, 1fr) 3.2fr 56px; align-items: center; min-height: 92px; }
.pr-row summary::-webkit-details-marker { display: none; }
.pr-row summary > * { padding: 18px var(--gutter); }
.pr-num { font-size: clamp(30px, 3.2vw, 46px); line-height: 1; border-right: 1px solid var(--line); align-self: stretch; display: flex; align-items: center; }
.pr-title { font-size: clamp(26px, 2.8vw, 40px); line-height: 1.05; text-transform: uppercase; }
.pr-row summary > .pr-plus { font: 300 28px/1 var(--sans); transition: transform .4s var(--ease); padding: 0; justify-self: center; }
.pr-row[open] .pr-plus { transform: rotate(45deg); }
/* the description sits under the title, in the same column */
.pr-body { display: grid; grid-template-columns: minmax(110px, 1fr) 3.2fr 56px; }
.pr-body::before { content: ""; grid-column: 1; grid-row: 1 / span 3; border-right: 1px solid var(--line); }
.pr-body > * { grid-column: 2; }
.pr-body > :not(.btn) { padding: 0 var(--gutter); }
.pr-body .lede { margin: 0 0 14px; max-width: 34em; }
.pr-body .pr-label { margin-bottom: 18px; color: var(--muted); }
.pr-body .btn { justify-self: start; margin: 0 var(--gutter) 30px; padding-inline: 22px; }
@media (max-width: 760px) {
  .pr-row summary, .pr-body { grid-template-columns: 70px 1fr 40px; }
  .pr-row summary > * { padding: 14px 14px; }
}

/* postcards: tinted cards behind, header bar */
.cards-bar { display: flex; justify-content: space-between; padding: 10px 0; }
.postcard[aria-hidden="true"] { opacity: .38; }
.postcard .pc-mark { position: absolute; right: 54px; top: 50px; width: 96px; height: 56px; color: var(--wine); opacity: .7; pointer-events: none; }
.postcard dd { font-size: 15px; }

/* made for fun: list + feature */
.journal { display: grid; grid-template-columns: 1fr 1fr; gap: 36px; }
@media (max-width: 860px) { .journal { grid-template-columns: 1fr; } }
.j-list { border-top: 1px solid var(--line); }
.j-item { display: grid; grid-template-columns: 150px 1fr 44px; gap: 20px; align-items: start; padding: 18px 0; border-bottom: 1px solid var(--line); text-decoration: none; }
.j-item img { width: 150px; aspect-ratio: 3 / 2; object-fit: cover; }
.j-item h3 { margin: 6px 0 6px; font: 500 21px/1.15 var(--sans); }
.j-item p { margin: 0; }
.j-go { width: 40px; height: 26px; border: 1px solid var(--line); border-radius: 999px; display: grid; place-items: center; font-size: 13px; transition: background .25s, color .25s; }
.j-item:hover .j-go { background: var(--wine); color: var(--on-wine); }
.j-item:hover h3 { text-decoration: underline; text-underline-offset: 3px; }
@media (max-width: 520px) { .j-item { grid-template-columns: 100px 1fr; } .j-item img { width: 100px; } .j-go { display: none; } }
.j-feature { position: relative; display: block; min-height: 480px; overflow: hidden; text-decoration: none; background: var(--wine); }
.j-feature > img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; transition: transform 1s var(--ease); }
.j-feature:hover > img { transform: scale(1.04); }
.j-card { position: absolute; left: 14px; right: 14px; bottom: 14px; background: var(--paper); padding: 22px; display: grid; grid-template-columns: 110px 1fr; gap: 16px; }
.j-card h3 { margin: 0 0 8px; font: 500 22px/1.15 var(--sans); }
.j-card p { margin: 0 0 16px; }
@media (max-width: 520px) { .j-card { grid-template-columns: 1fr; } }

/* FAQ: closing card */
.ring-card { background: var(--wine); color: var(--on-wine); padding: 26px 24px; margin-top: 14px; }

/* about: crew + room for one more */
.team { display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px; }
@media (max-width: 860px) { .team { grid-template-columns: 1fr 1fr; } }
.crew { background: var(--paper); padding: 16px 16px 20px;
  /* each edge gets its own row of notches, spaced to fit that edge exactly, so the bottom matches the top */
  --perf: radial-gradient(circle at 50% 0, transparent 5px, #000 5.5px) top / 16px 8px round no-repeat,
          radial-gradient(circle at 50% 100%, transparent 5px, #000 5.5px) bottom / 16px 8px round no-repeat,
          radial-gradient(circle at 0 50%, transparent 5px, #000 5.5px) left / 8px 16px no-repeat round,
          radial-gradient(circle at 100% 50%, transparent 5px, #000 5.5px) right / 8px 16px no-repeat round,
          linear-gradient(#000 0 0) center / calc(100% - 15px) calc(100% - 15px) no-repeat;
  -webkit-mask: var(--perf); mask: var(--perf); }
.crew-stamp { aspect-ratio: 1; background: var(--wine); color: var(--on-wine); display: grid; place-items: center; margin-bottom: 14px; }
.crew-stamp .display { font-size: clamp(48px, 6vw, 88px); }
.crew:nth-child(even) .crew-stamp { background: var(--wine-deep); }
.crew h3 { margin: 0; }
.room { max-width: 560px; margin: clamp(56px, 7vw, 96px) auto 0; text-align: center; display: flex; flex-direction: column; align-items: center; gap: 14px; }
.room h2 { margin: 6px 0 0; }
.room p { margin: 0 0 8px; max-width: 30em; }
.room-stamp { width: 120px; height: 140px; border: 2px dashed var(--wine); display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 4px; transform: rotate(-3deg); }
.room-stamp b { font: 400 30px/1 var(--display); text-transform: uppercase; }

/* project gallery: uniform two-column tiles */
.gallery figure, .gallery figure.wide { grid-column: auto; aspect-ratio: 4 / 5; }
.gallery figure.video { grid-column: 1 / -1; aspect-ratio: 16 / 9; }
.gallery figure img, .gallery figure:not(.wide) img { width: 100%; height: 100%; aspect-ratio: auto; object-fit: cover; }
.gallery figure.contain img { object-fit: contain; padding: 6%; }

/* ring: bigger polaroids, letter overlaps the ring section */
.ring-sec { height: clamp(760px, 88vw, 1240px); }
.ring-sec .pol { width: clamp(100px, 12vw, 180px); }
.footer { padding-top: 0; }
.ring-sec + .footer, main:has(.ring-sec:last-child) + .footer { margin-top: 0; }
.letter .brand-line { display: flex; align-items: center; gap: 10px; }
.letter .brand-line img { width: 40px; height: 40px; }

/* ===================== Round 3: hero, marquee, fun, model, book ===================== */
.hero { padding-top: clamp(28px, 4vw, 56px); }
.hero-stage { grid-template-columns: 1fr; justify-items: center; padding-top: 0; }
.stretch-word { justify-content: center; width: 100%; height: clamp(170px, 32vw, 500px); font-size: clamp(100px, 23vw, 360px); }
.hero-foot { margin-top: 6px; }

.d-l { line-height: 1; }
.head-row h2 + .lede, .head-row .lede { padding-bottom: 6px; }
.hint { line-height: 1.02; }
.stack-card h3 { line-height: 1; }

/* project rows: mockups drift slowly sideways */
.marquee { overflow: hidden; margin-right: calc(-1 * var(--gutter)); margin-left: calc(-1 * var(--gutter)); -webkit-mask: linear-gradient(90deg, transparent, #000 4%, #000 96%, transparent); mask: linear-gradient(90deg, transparent, #000 4%, #000 96%, transparent); }
.marquee-track { display: flex; gap: 12px; width: max-content; animation: drift var(--dur, 60s) linear infinite; }
.marquee:hover .marquee-track { animation-play-state: paused; }
.marquee figure { margin: 0; flex: none; width: clamp(190px, 17vw, 260px); aspect-ratio: 4 / 5; overflow: hidden; background: var(--paper); }
.marquee img { width: 100%; height: 100%; object-fit: cover; transition: transform .8s var(--ease); }
.marquee figure:hover img { transform: scale(1.05); }
@keyframes drift { to { transform: translateX(calc(-50% - 6px)); } }
.proj-row { padding: 44px 0 48px; }
.proj-row-head { margin-bottom: 28px; }

/* made for fun: nothing cropped */
.j-item { grid-template-columns: 140px 1fr 44px; align-items: center; }
.j-thumb { width: 140px; aspect-ratio: 4 / 3; background: var(--paper); display: grid; place-items: center; overflow: hidden; border: 1px solid var(--line-soft); }
.j-item img, .j-thumb img { width: 100%; height: 100%; object-fit: contain; aspect-ratio: auto; }
.j-feature { min-height: 0; background: var(--paper); border: 1px solid var(--line-soft); display: grid; grid-template-columns: 1fr; }
.j-feature > img { display: none; }
.j-pic { padding: clamp(18px, 2.4vw, 32px); display: grid; place-items: center; background: var(--wine-deep); }
.j-pic img { max-height: 440px; width: auto; max-width: 100%; box-shadow: 0 18px 40px -16px rgba(0, 0, 0, .6); transition: transform .8s var(--ease); }
.j-feature:hover .j-pic img { transform: rotate(-2deg) scale(1.02); }
.j-card { position: static; }
@media (max-width: 520px) { .j-item { grid-template-columns: 96px 1fr; } .j-thumb { width: 96px; } }

/* project page features */
.feature { padding-top: 8px; padding-bottom: clamp(60px, 8vw, 110px); }
.feature-head { max-width: 760px; margin: 0 auto 28px; }
.feature-head h2 { margin: 8px 0 12px; }
.feature-head p { margin: 0; }
.model-box { position: relative; height: clamp(360px, 52vw, 640px); background: radial-gradient(circle at 50% 40%, #fff 0, var(--paper) 55%, var(--blush) 100%); border: 1px solid var(--line-soft); }
.model-box model-viewer { width: 100%; height: 100%; --poster-color: transparent; }
.model-hint { position: absolute; left: 16px; bottom: 14px; pointer-events: none; }

.book-wrap { display: flex; flex-direction: column; align-items: center; gap: 16px; }
/* the book sits on its own white page with room around it, like a book open on a table */
.book-wrap { background: #fff; padding: clamp(36px, 6vw, 96px) clamp(28px, 9vw, 160px) clamp(28px, 4vw, 56px); }
.book-wrap .flipbook { width: min(100%, 900px); }
.flipbook { position: relative; width: min(100%, 1040px); aspect-ratio: 2 / 1; cursor: pointer; outline-offset: 8px; box-shadow: 0 26px 44px -18px rgba(62, 20, 36, .45); }
.flipbook .base, .flipbook .leaf { position: absolute; top: 0; width: 50%; height: 100%; }
.flipbook .base.left { left: 0; }
.flipbook .base.right, .flipbook .leaf { left: 50%; }
.flipbook img { width: 100%; height: 100%; object-fit: cover; display: block; user-select: none; -webkit-user-drag: none; }
.flipbook .leaf { transform-origin: 0 50%; transform-style: preserve-3d; transition: transform .9s cubic-bezier(.45, .05, .25, 1); z-index: calc(40 - var(--i)); }
.flipbook .leaf.turned { transform: rotateY(-180deg); z-index: calc(var(--i) + 1); }
.flipbook .face { position: absolute; inset: 0; backface-visibility: hidden; -webkit-backface-visibility: hidden; overflow: hidden; }
.flipbook .face.verso { transform: rotateY(180deg); }
.flipbook .face.front::after { content: ""; position: absolute; inset: 0; background: linear-gradient(90deg, rgba(0, 0, 0, .12), transparent 8%); pointer-events: none; }
.flipbook .face.verso::after { content: ""; position: absolute; inset: 0; background: linear-gradient(270deg, rgba(0, 0, 0, .12), transparent 8%); pointer-events: none; }
.flipbook .spine { position: absolute; left: 50%; top: 0; bottom: 0; width: 2px; transform: translateX(-1px); background: rgba(0, 0, 0, .08); z-index: 60; pointer-events: none; }
.flipbook.at-start { cursor: e-resize; }
.flipbook.at-end { cursor: w-resize; }
.book-count { margin: 0; }

.pc-form, .ways { min-width: 0; }
.ways .row { flex-wrap: wrap; }
.ways .row .right { overflow-wrap: anywhere; }
.model-fallback { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: contain; padding: 4%; }
.model-box model-viewer { position: relative; z-index: 1; }
.model-box.ready .model-fallback { display: none; }

/* ===================== Round 4: clean mockup ticker, story, odometer ===================== */
.marquee-track { animation: none; gap: 16px; will-change: transform; }
.marquee figure { width: auto; height: clamp(260px, 27vw, 400px); aspect-ratio: auto; background: none; }
.marquee img { width: auto; height: 100%; object-fit: contain; }
.marquee figure:hover img { transform: none; }
.marquee { cursor: default; }

.tl-item { padding-bottom: 72px; }
.tl-item p { font-size: 18px; }
.tl-pic { margin: 0; max-width: 560px; aspect-ratio: 16 / 10; overflow: hidden; background: var(--paper); }
.tl-pic img { width: 100%; height: 100%; object-fit: cover; transition: transform 1s var(--ease); }
.tl-item:hover .tl-pic img { transform: scale(1.04); }

.odo { display: flex; overflow: hidden; height: .92em; line-height: .92; }
.odo .col { display: flex; flex-direction: column; transition: transform .9s cubic-bezier(.65, 0, .25, 1); }
.odo .col span { display: block; height: .92em; }
.tools li span:last-child:empty { display: none; }
.cover.contain { object-fit: contain; background: #f8eae8; }

/* ===================== Round 5: outcome / process, whole pictures ===================== */
.wcard .img img, .pn .img img { object-fit: contain; }
.wcard .img, .pn .img { display: grid; place-items: center; }
.psec { padding-top: clamp(40px, 6vw, 80px); }
.psec-head { display: flex; align-items: baseline; gap: 16px; border-top: 1px solid var(--line); padding-top: 18px; margin-bottom: 26px; }
.psec-head h2 { margin: 0; }
.jgallery { display: flex; flex-direction: column; gap: 8px; padding-bottom: clamp(40px, 6vw, 80px); }
.jrow { display: flex; gap: 8px; width: 100%; }
.jrow figure { margin: 0; min-width: 0; }
.jrow img { width: 100%; height: auto; display: block; }
@media (max-width: 640px) { .jrow { flex-direction: column; } .jrow figure { flex: none !important; } }
/* social posts stay two side by side, even on phones */
@media (max-width: 640px) { .jgallery .jrow.two { flex-direction: row; } .jgallery .jrow.two figure { flex: 1 1 0 !important; } }
.pvideo { width: 100%; display: block; background: #000; }
.feature { padding-top: clamp(30px, 4vw, 56px); }
.stack-card { min-height: clamp(360px, 46vh, 460px); }
.stack-card .body { justify-content: center; }

/* cards fill their frame, cropped around each picture's main part */
.wcard .img { aspect-ratio: 4 / 3; display: block; }
.pn .img { aspect-ratio: 4 / 3; display: block; }
.wcard .img img, .pn .img img { width: 100%; height: 100%; object-fit: cover; object-position: var(--pos, 50% 50%); }
.ix-peek { width: 240px; aspect-ratio: 4 / 3; }

/* ShelfLife: the working app inside a phone */
.app-phone {
  /* a real iPhone 15: body 71.6 x 147.6 mm, screen 393 x 852 pt with even bezels */
  --w: min(400px, 80vw, calc((100svh - var(--nav-h) - 48px) * 71.6 / 147.6));
  position: relative; width: var(--w); aspect-ratio: 71.6 / 147.6; margin: 0 auto;
  border-radius: calc(var(--w) * .165);
  background: linear-gradient(150deg, #a3a7ad 0%, #4a4d52 16%, #24262a 46%, #3a3d42 72%, #a9adb3 100%);
  box-shadow: inset 0 0 0 calc(var(--w) * .004) rgba(255, 255, 255, .35), 0 42px 80px -32px rgba(0, 36, 84, .6), 0 16px 30px -16px rgba(0, 0, 0, .45);
}
/* the black glass: a thin frame of metal shows around it */
.app-phone .screen { position: absolute; inset: calc(var(--w) * .012); border-radius: calc(var(--w) * .158); background: #050506; padding: calc(var(--w) * .0335); }
/* the app runs at a real iPhone's 393 x 852 pt and is scaled down to the screen (site.js sets --s), so it isn't zoomed in */
.app-phone .screen { overflow: hidden; }
.app-phone iframe { width: 393px; height: 852px; border: 0; display: block; border-radius: 55px; background: #c9d2ea; transform: scale(var(--s, 1)); transform-origin: 0 0; }
/* Dynamic Island: 126 x 37 pt, 11 pt below the top of the screen */
.app-phone .island { position: absolute; top: calc(var(--w) * .071); left: 50%; transform: translateX(-50%); width: calc(var(--w) * .291); height: calc(var(--w) * .0856); background: #000; border-radius: 999px; z-index: 2; pointer-events: none; }
.app-phone .key { position: absolute; width: calc(var(--w) * .011); border-radius: 2px; background: linear-gradient(90deg, #2e3135, #9a9ea5); }
.app-phone .k1 { left: calc(var(--w) * -.009); top: 15.5%; height: 3.4%; }
.app-phone .k2 { left: calc(var(--w) * -.009); top: 22%; height: 6.6%; }
.app-phone .k3 { left: calc(var(--w) * -.009); top: 30%; height: 6.6%; }
.app-phone .k4 { right: calc(var(--w) * -.009); top: 24%; height: 10.5%; background: linear-gradient(270deg, #2e3135, #9a9ea5); }
.app-foot { display: flex; justify-content: center; margin-top: 18px; }
.brand-mark { border-radius: 0; }

/* ring: project cards, each a link */
.ring-sec .pol { display: block; text-decoration: none; }
.ring-sec .pol img { aspect-ratio: 1; object-fit: cover; }
.ring-sec .pol .mono { position: absolute; left: 8px; right: 8px; bottom: 6px; font-size: 9px; color: var(--wine-deep); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }

/* What I do: title and description only, cards still stack */
.stack-card.simple { grid-template-columns: 1fr; min-height: clamp(260px, 34vh, 340px); align-items: end; }
.stack-card.simple .body { justify-content: flex-end; }

/* ===================== Resume ===================== */
.rs-actions { display: flex; justify-content: space-between; align-items: center; gap: 16px; flex-wrap: wrap; padding-top: 32px; padding-bottom: 20px; }
.rs-sheet { max-width: 900px; margin: 0 auto clamp(60px, 8vw, 110px); background: var(--paper); color: var(--wine-deep); padding: clamp(24px, 5vw, 56px); }
.rs-head { display: grid; grid-template-columns: 1fr auto; gap: 24px; align-items: end; border-bottom: 2px solid var(--wine); padding-bottom: 20px; }
.rs-id { display: flex; gap: 18px; align-items: center; }
.rs-stamp { width: 74px; height: 74px; flex: none; transform: rotate(-4deg); }
.rs-name { font-size: clamp(44px, 7vw, 80px); line-height: .95; color: var(--wine); margin: 0; }
.rs-title { margin: 8px 0 0; font-size: 15px; }
/* two lines: what she is, then the degree and college together; the college name never splits */
.rs-title .rs-line { display: block; }
.rs-title .rs-school { white-space: nowrap; }
.rs-title .nw { white-space: nowrap; }
@media (max-width: 420px) { .rs-title .rs-school { white-space: normal; } }
.rs-contact { margin: 0; display: grid; gap: 4px; font-size: 13px; }
.rs-contact div { display: grid; grid-template-columns: 70px 1fr; gap: 10px; }
.rs-contact dt { font-size: 10px; color: var(--wine); padding-top: 2px; }
.rs-contact dd { margin: 0; }
.rs-link { color: inherit; text-decoration: none; }
.rs-link:hover { text-decoration: underline; text-underline-offset: 3px; }
.rs-intro { font-size: 17px; line-height: 1.45; margin: 22px 0 8px; max-width: 40em; }
.rs-sec h2 { font-size: 26px; line-height: 1; color: var(--wine); margin: 26px 0 10px; }
.rs-exp { list-style: none; margin: 0; padding: 0; }
.rs-exp li { display: grid; grid-template-columns: 170px 1fr auto; gap: 16px; padding: 9px 0; border-top: 1px solid var(--line); font-size: 14px; align-items: baseline; }
.rs-exp li:last-child { border-bottom: 1px solid var(--line); }
.rs-org { font-weight: 600; }
.rs-when { font-size: 11px; white-space: nowrap; color: var(--wine); }
.rs-cols { display: grid; grid-template-columns: 1fr 1fr; gap: 28px; }
/* skills run four across under Experience; tools two across */
.rs-grid4 { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); column-gap: 20px; }
.rs-grid2 { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); column-gap: 20px; }
.rs-sub { margin: 12px 0 6px; font-size: 10px; }
/* one column of blocks, so the text in the PDF reads top to bottom in order (scanners read it this way) */
.rs-sheet { display: flex; flex-direction: column; }
.rs-sheet > * { min-width: 0; }
.rs-intro { margin-bottom: 0; }
.rs-edu p { margin: 0 0 12px; font-size: 14px; line-height: 1.5; }
.rs-edu .mono { font-size: 10px; color: var(--wine); }
.rs-list { list-style: none; margin: 0; padding: 0; font-size: 14px; }
.rs-list li { padding: 4px 0; border-top: 1px solid var(--line-soft); }
.rs-foot { display: flex; justify-content: space-between; gap: 16px; flex-wrap: wrap; margin-top: 28px; padding-top: 14px; border-top: 2px solid var(--wine); font: 400 11px/1.4 var(--mono); text-transform: uppercase; letter-spacing: .06em; }
@media (max-width: 760px) {
  .rs-head { grid-template-columns: 1fr; }
  .rs-exp li { grid-template-columns: 1fr; gap: 2px; }
  .rs-cols { grid-template-columns: 1fr; gap: 0; }
  .rs-grid4 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
/* print and the PDF: exactly the sheet as it looks on a desktop screen (900px wide, same type,
   same columns, perforated edge, page colour around it), scaled down to fit one A4 page */
@media print {
  @page { size: A4; margin: 0; }
  * { -webkit-print-color-adjust: exact; print-color-adjust: exact; }
  .nav, .menu-panel, .footer, .rs-actions, .skip, .ring-sec, .loader { display: none !important; }
  html, body { height: auto; }
  .rs-page { padding: 46px 0 0 !important; margin: 0 !important; }
  .rs-sheet { width: 900px; max-width: none; margin: 0 auto; padding: 56px; zoom: .84; break-inside: avoid; }
  .rs-name { font-size: 80px; }
  .rs-head { grid-template-columns: 1fr auto; }
  .rs-exp li { grid-template-columns: 170px 1fr auto; gap: 16px; }
  .rs-cols { grid-template-columns: 1fr 1fr; gap: 28px; }
  .rs-grid4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
}

/* ===================== About: pinned story ===================== */
.story-pin { position: relative; height: calc(var(--n) * 75vh + 40vh); }
.sp-sticky { position: sticky; top: var(--nav-h); height: calc(100vh - var(--nav-h)); display: flex; align-items: center; overflow: hidden; }
.sp-grid { display: grid; grid-template-columns: minmax(220px, .8fr) 1.2fr; gap: 48px; align-items: center; width: 100%; }
.sp-left .odo { font-size: clamp(90px, 15vw, 230px); margin-top: 18px; color: var(--wine); }
.sp-left .odo-word { display: none; font-size: clamp(90px, 15vw, 230px); line-height: .92; margin: 18px 0 0; color: var(--wine); }
.is-word .sp-left .odo { display: none; }
.is-word .sp-left .odo-word { display: block; animation: odo-word-in .7s var(--ease) both; }
@keyframes odo-word-in { from { opacity: 0; transform: translateY(.3em); } to { opacity: 1; transform: none; } }
.sp-dots { display: flex; gap: 8px; margin-top: 22px; }
.sp-dots i { width: 22px; height: 3px; background: var(--line); transition: background .4s; }
.sp-dots i.on { background: var(--wine); }
.sp-right { position: relative; min-height: min(68vh, 560px); }
.sp-ch { position: absolute; inset: 0; display: flex; flex-direction: column; justify-content: center; overflow: hidden; gap: 12px; opacity: 0; transform: translateY(40px); transition: opacity .6s var(--ease), transform .7s var(--ease); pointer-events: none; }
.sp-ch.on { opacity: 1; transform: none; pointer-events: auto; }
.sp-ch.past { transform: translateY(-40px); }
.sp-ch h3 { margin: 4px 0 0; }
.sp-ch .lede { max-width: 30em; margin: 0; }
.sp-pic { margin: 8px 0 0; max-width: 520px; width: 100%; aspect-ratio: 16 / 10; max-height: 38vh; overflow: hidden; background: var(--paper); }
.sp-pic img { width: 100%; height: 100%; object-fit: contain; }
@media (max-width: 760px) {
  .sp-grid { grid-template-columns: 1fr; gap: 10px; align-content: start; padding-top: 24px; }
  .sp-left .odo, .sp-left .odo-word { font-size: 84px; margin-top: 8px; }
  .sp-dots { margin-top: 10px; }
  .sp-right { min-height: 56vh; }
  .sp-pic { max-width: 100%; }
}
@media (prefers-reduced-motion: reduce) { .story-pin { height: auto; } .sp-sticky { position: static; height: auto; } .sp-right { min-height: 0; } .sp-ch { position: static; opacity: 1; transform: none; margin-bottom: 48px; } }
.sp-right { min-height: min(46vh, 380px); }
.sp-ch .lede { font-size: clamp(19px, 1.7vw, 24px); line-height: 1.4; }
@media (max-width: 760px) { .sp-right { min-height: 44vh; } }

/* What I do: no empty space above the title */
.stack-card.simple { min-height: 0; align-items: start; padding-top: clamp(26px, 3vw, 40px); padding-bottom: clamp(30px, 3.6vw, 48px); }
.stack-card.simple .body { justify-content: flex-start; padding-right: 80px; }

.badge-logo { width: clamp(90px, 11vw, 150px); height: auto; display: block; transform: rotate(-6deg); }
.plain-mail { text-decoration: none; }
.plain-mail:hover { text-decoration: underline; text-underline-offset: 3px; }
@media (max-width: 760px) { .stack-card.simple .body { padding-right: 44px; min-width: 0; } }


/* About intro: the availability note lines up with the paragraph */
.about-sub { align-items: start; }
.about-sub > div { padding-top: 0; border-left: 1px solid var(--line); padding-left: 18px; }
.about-sub > div > p:first-child { font-size: clamp(17px, 1.45vw, 21px); line-height: 1.32; margin: 0 0 6px !important; }
.about-sub > div > p:first-child .status-dot { vertical-align: .15em; }
@media (max-width: 760px) { .about-sub > div { border-left: 0; padding-left: 0; padding-top: 0; } }

/* Milka viewer */
.model-box { overflow: hidden; touch-action: pan-y; }
.model-box canvas { position: absolute; inset: 0; display: block; cursor: grab; }
.model-box canvas:active { cursor: grabbing; }
.model-box .model-hint { z-index: 2; }
.model-box.ready .model-fallback { display: none; }

/* Milka: renders and the 3D viewer sit straight on the page, no backdrop */
.model-box { background: none; border: 0; height: clamp(380px, 56vw, 720px); }
.model-box .model-fallback { padding: 0; }
.about-sub .lede { margin-top: 0; }
@media (max-width: 760px) { .pr-num { white-space: nowrap; font-size: 24px; } }

/* ===================== Loading screen (home) ===================== */
.loader { position: fixed; inset: 0; z-index: 1000; background: var(--wine); color: var(--on-wine); display: grid; place-items: center; transition: transform .9s cubic-bezier(.76, 0, .24, 1); }
html:not(.loading) .loader { display: none; }
html.loading body { overflow: hidden; }
.ld-name { display: flex; align-items: flex-end; gap: .22em; font-size: clamp(72px, 13.5vw, 230px); line-height: .8; text-transform: uppercase; user-select: none; }
.ld-w { display: flex; align-items: flex-end; }
/* each letter springs up from the floor, overshoots and settles: the same squish as the name on the home page */
.ld-name span span { display: inline-block; transform-origin: 50% 100%; transform: scaleY(var(--sy, 1)); transition: transform .6s cubic-bezier(.3, 1.5, .5, 1);
  animation: ld-squish .9s cubic-bezier(.3, 1.2, .5, 1) backwards; animation-delay: calc(var(--i) * 55ms + .1s); }
@keyframes ld-squish {
  0% { transform: scale(1.25, 0); }
  45% { transform: scale(.86, 1.45); }
  70% { transform: scale(1.06, .9); }
  100% { transform: scale(1, 1); }
}
@media (max-width: 700px) {
  .ld-name { flex-direction: column; align-items: center; gap: .2em; font-size: clamp(84px, 26vw, 200px); }
}
.ld-foot { position: absolute; left: var(--gutter); right: var(--gutter); bottom: clamp(22px, 3.4vw, 40px); display: flex; justify-content: space-between; align-items: flex-end; gap: 16px; }
.ld-foot .mono { color: var(--on-wine-soft); padding-bottom: .4em; text-align: right; }
.ld-num { font-size: clamp(30px, 4vw, 60px); line-height: .82; font-variant-numeric: tabular-nums; }
.ld-num b { font-weight: inherit; }
.ld-bar { position: absolute; left: 0; right: 0; bottom: 0; height: 3px; background: rgba(238, 242, 250, .18); }
.ld-bar i { display: block; height: 100%; width: var(--p, 0%); background: var(--on-wine); }
.loader.done { transform: translateY(-100%); }
@media (prefers-reduced-motion: reduce) {
  .ld-name span span { animation: none; transform: none; }
  .loader { transition: opacity .3s; }
  .loader.done { transform: none; opacity: 0; }
}

/* labelled process galleries */
.jlabel { padding: clamp(36px, 5vw, 72px) var(--gutter) 4px; border-top: 1px solid var(--line-soft); }
.jgallery > .jlabel:first-child { border-top: 0; padding-top: 0; }
.jlabel h3 { margin: 0; }
.jrow.people { gap: clamp(12px, 2vw, 28px); padding: 0 var(--gutter); }
.jrow.people figcaption { padding: 14px 2px 0; max-width: 30em; }
.jrow.people figcaption b { display: block; font-weight: 400; font-size: clamp(22px, 2vw, 28px); line-height: 1.1; text-transform: uppercase; color: var(--wine); margin-bottom: 6px; }
.jrow.screen { justify-content: center; }
.jrow.screen figure { height: calc(100svh - var(--nav-h) - 24px); }
.jrow.screen img { height: 100%; width: auto; }
@media (max-width: 640px) {
  .jrow.screen figure { height: auto; }
  .jrow.screen img { width: 100%; height: auto; }
  .jrow.people figcaption { padding-bottom: 18px; }
}
.duo-wrap .duo { object-position: 50% 40%; }
.jvideo { width: 100%; height: auto; display: block; background: #000; aspect-ratio: 848 / 478; }

/* film pages: the full film from Vimeo, then the teaser */
.film { margin-bottom: clamp(28px, 4vw, 48px); }
.film-label { margin: 0 0 12px; }
.vimeo { position: relative; aspect-ratio: 16 / 9; background: #000; }
.vimeo iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }
.film-link { margin: 12px 0 0; }
.film-link a { text-decoration: none; }

/* the turning page keeps the book's exact height: no perspective growth, just a shadow while it lifts */
.flipbook .leaf .face::before { content: ""; position: absolute; inset: 0; background: #000; opacity: 0; pointer-events: none; z-index: 1; transition: opacity .45s ease; }
.flipbook .leaf.turning .face::before { opacity: .18; }

/* the envelope opens: the flap swings up first, then the letter rises out */
.env-flap {
  position: absolute; left: 0; right: 0; top: var(--flap-top, 0px); height: clamp(70px, 10vw, 140px);
  transform-origin: 50% 0; transform: perspective(900px) rotateX(var(--flap, 0deg));
  z-index: 3; pointer-events: none;
}
.env-flap::before {
  content: ""; position: absolute; inset: 0; clip-path: polygon(0 0, 100% 0, 50% 100%);
  background: linear-gradient(180deg, #e6e9f2, var(--paper)); filter: drop-shadow(0 3px 2px rgba(0, 36, 84, .18));
}
.env-flap.open { z-index: 0; }
.env-flap.open::before { background: linear-gradient(0deg, #dfe3ee, #eef0f6); }

/* phones: personas at a comfortable size, and the book as wide as the screen */
@media (max-width: 640px) {
  .jrow.people figure img { width: min(100%, 260px); margin: 0 auto; }
  .jrow.people figcaption { text-align: center; margin: 0 auto; }
  .book-wrap { padding: 28px 14px 20px; }
  .book-wrap .flipbook { width: 100%; box-shadow: 0 16px 28px -14px rgba(62, 20, 36, .45); }
}
.tab.menu-btn[aria-expanded="true"] { background: var(--wine); color: var(--on-wine); opacity: 1; }

/* galleries: a row is never taller than the screen, so every picture can be seen whole */
/* process pictures get room to breathe: more space between rows, still edge to edge */
/* process pictures sit as close together as the outcome ones; only diagrams without a background get extra room */
.jgallery .jrow:has(img[src$="-cut.webp"]) { margin-block: clamp(20px, 4vw, 56px); }
/* two cut-out boards in a row share one gap instead of stacking two */
.jgallery .jrow:has(img[src$="-cut.webp"]) + .jrow:has(img[src$="-cut.webp"]) { margin-top: clamp(8px, 2vw, 28px); }
.jgallery .jlabel + .jrow:has(img[src$="-cut.webp"]) { margin-top: 0; }
.jgallery.proc .jlabel { margin-top: clamp(8px, 2vw, 32px); }
/* diagrams without a background never sit against the screen edge */
.jgallery figure.cut { padding-inline: clamp(16px, 5vw, 80px); }
@media (max-width: 640px) {
  .jgallery .jrow { width: 100%; }
  .jgallery .jrow:has(img[src$="-cut.webp"]) { margin-block: 20px; }
  .jgallery figure.cut { padding-inline: 16px; }
}
.jgallery .jrow.logo-row { width: min(66%, calc(var(--a) * 62svh)); margin-inline: auto; }
@media (max-width: 640px) { .jgallery .jrow.logo-row { width: 86%; } }
/* the film: a cover with a play button; the Vimeo player loads in its place when pressed */
.vimeo-cover { position: absolute; inset: 0; display: block; color: #fff; text-decoration: none; cursor: pointer; }
.vimeo-cover img { width: 100%; height: 100%; object-fit: cover; display: block; filter: brightness(.72); transition: filter .3s; }
.vimeo-cover:hover img { filter: brightness(.6); }
.vimeo-play { position: absolute; left: 50%; top: 50%; width: clamp(64px, 8vw, 96px); aspect-ratio: 1; transform: translate(-50%, -50%); border-radius: 50%; background: var(--wine); box-shadow: 0 10px 30px rgba(0, 0, 0, .35); transition: transform .3s var(--ease); }
.vimeo-play::after { content: ""; position: absolute; left: 54%; top: 50%; transform: translate(-50%, -50%); border-style: solid; border-width: 13px 0 13px 22px; border-color: transparent transparent transparent #fff; }
.vimeo-cover:hover .vimeo-play { transform: translate(-50%, -50%) scale(1.08); }
.vimeo-cap { position: absolute; left: 50%; top: calc(50% + clamp(48px, 6vw, 70px)); transform: translateX(-50%); white-space: nowrap; }
.jgallery .jrow.narrow-row { width: min(64%, calc(var(--a) * 72svh)); margin-inline: auto; }
.jgallery .jrow.narrow-row + .jrow.narrow-row { margin-top: clamp(16px, 2.4vw, 32px); }
@media (max-width: 640px) { .jgallery .jrow.narrow-row { width: 100%; } }
/* a screenshot shown in the phone, centred in the gallery */
.jgallery .jrow.phone-row { justify-content: center; padding-block: clamp(28px, 5vw, 64px); }
/* the screenshot keeps its whole height and scrolls inside the screen, below the status bar */
.app-phone.still .screen { background: #0c0d10; }
.app-phone.still .feed { width: 100%; height: 100%; overflow-y: auto; overscroll-behavior: contain; scrollbar-width: none; padding-top: calc(var(--w) * .125); border-radius: calc(var(--w) * .127); background: #0b0e15; }
.app-phone.still .feed::-webkit-scrollbar { display: none; }
.app-phone.still .feed img { width: 100%; height: auto; display: block; }

/* colour: a note, the swatches as small chips, then why each colour is there */
.colour-note { margin: 4px 0 14px; max-width: 40em; }
.colour-why { display: grid; grid-template-columns: max-content 1fr; gap: 6px 16px; margin: 0 0 24px; font-size: 15px; line-height: 1.45; }
.colour-why dt { font: 400 11px/1.9 var(--mono); text-transform: uppercase; letter-spacing: .06em; }
.colour-why dd { margin: 0; }
@media (max-width: 640px) { .colour-why { grid-template-columns: 1fr; gap: 2px; } .colour-why dd { margin-bottom: 8px; } }

/* reading comfort: a little more air in intro paragraphs, the address and long project text */
.lede { line-height: 1.42; }
.envelope address { line-height: 1.42; }
.story p { line-height: 1.6; }

/* postcards: all the same size, the footer line sits at the bottom of each */
.postcard { display: flex; flex-direction: column; }
.postcard .foot { margin-top: auto; }
/* say hello on phones: smaller polaroids that stay on screen, a little air between the two words */
@media (max-width: 640px) {
  /* smaller polaroids let the ring open wider, so it clears the words in the middle */
  .ring-sec .pol { width: 62px; padding: 4px 4px 15px; }
  .ring-sec .pol .mono { font-size: 6px; left: 4px; right: 4px; bottom: 3px; }
  .greet-word { font-size: 40px; gap: .12em; }
}

/* footer envelope: a real DL letter envelope (220 x 110 mm, 2:1), as tall as the screen allows
   while the letter above it stays fully in view; phones use a C6 (162 x 114 mm) */
.env-wrap { --env-h: clamp(320px, calc(100svh - var(--nav-h) - 420px), 480px); max-width: none; width: 100%; container-type: inline-size; }
.envelope { min-height: var(--env-h); align-items: center; align-content: center; }
.env-flap { height: calc(var(--env-h) * .5); }
.envelope .credit { align-self: flex-end; }
@media (min-width: 641px) and (max-height: 780px) { .letter .top p.small { display: none; } .footer .letter { padding-top: 22px; } .footer .letter .top { margin-bottom: 10px; } }
.letter { padding: 30px clamp(22px, 4vw, 48px) 34px; }
.letter .top { margin-bottom: 18px; }
.letter .top p.small { max-width: 34em !important; }
.letter .cols a { line-height: 1.45; }
@media (max-width: 640px) {
  .letter { padding: 20px 18px 22px; }
  .letter .top { margin-bottom: 14px; }
  .letter .top p.small { display: none; }
  .letter .cols > div:nth-child(2) { display: none; }
  .letter .cols a { font-size: 15px; line-height: 1.5; }
  .env-wrap { width: 100%; }
  .envelope { aspect-ratio: 162 / 114; min-height: 0; }
  .env-flap { height: 35cqw; }
  /* on phones the address and credit sit tighter so the C6 shape holds */
  .footer .envelope { padding: 22px 18px 14px; gap: 10px; }
  .footer .envelope address { font-size: 15px; line-height: 1.35; }
  .footer .envelope .small.muted { display: none; }
  .footer .envelope .credit { font-size: 12px; }
}
@media (max-width: 640px) and (max-height: 700px) {
  .footer .letter .cols a { line-height: 1.4; }
}

/* gallery headings: a little air before the pictures start */
.jgallery .jlabel { padding-bottom: clamp(14px, 1.8vw, 26px); }
/* Lifespring type sheet: bigger than the other narrow rows */
.jgallery .jrow.narrow-row:has(img[src*="life-type"]) { width: min(86%, 1280px); }
@media (max-width: 640px) { .jgallery .jrow.narrow-row:has(img[src*="life-type"]) { width: 100%; } }


/* resume on the smallest phones: a smaller stamp and name so the header stays inside the sheet,
   and contact labels above their values so the email fits on one line */
@media (max-width: 360px) {
  .rs-id { gap: 12px; } .rs-stamp { width: 52px; height: 52px; } .rs-name { font-size: 34px; }
  .rs-head { grid-template-columns: minmax(0, 1fr); }
  .rs-contact { gap: 8px; } .rs-contact div { grid-template-columns: minmax(0, 1fr); gap: 1px; }
}