:root {
  --wine: #6b2a2e;
  --wine-deep: #4e1c20;
  --wine-soft: #8c4046;
  --bg: #f7f5f0;
  --paper: #fffdf9;
  --tint: #efeae2;
  --cream: #f4f3ee;
  --ink: #1f1a1a;
  --muted: #6b6361;
  --line: #e2dcd2;
  --line-tint: rgba(78, 28, 32, .12);
  --display: "Bricolage Grotesque", "Arial Narrow", system-ui, sans-serif;
  --sans: "Instrument Sans", system-ui, -apple-system, "Segoe UI", sans-serif;
  --label: "Jost", "Futura", "Century Gothic", var(--sans);
  --body: var(--sans);
  --radius: 14px;
  --card: clamp(20px, 2.4vw, 28px);
  --gutter: clamp(16px, 4vw, 48px);
  --ease: cubic-bezier(.2, .7, .2, 1);
  interpolate-size: allow-keywords;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 96px; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--sans);
  font-size: 17px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}
img { max-width: 100%; height: auto; display: block; }
a { color: inherit; }
h1, h2, h3 { margin: 0; line-height: 1.05; font-weight: 700; }
h2 {
  font-family: var(--display);
  font-size: clamp(36px, 4.8vw, 62px);
  font-weight: 750;
  font-stretch: 85%;
  letter-spacing: -0.03em;
  line-height: 1;
  color: var(--wine);
  text-wrap: balance;
}
p { margin: 0 0 1em; }
strong { font-weight: 600; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

.wrap { width: 100%; max-width: 1200px; margin: 0 auto; padding: 0 var(--gutter); }
.skip { position: absolute; left: -999px; top: 8px; background: var(--wine); color: #fff; padding: 8px 14px; border-radius: 8px; z-index: 100; }
.skip:focus { left: 8px; }
:focus-visible { outline: 2px solid var(--wine-soft); outline-offset: 3px; }

/* Small labels: geometric capitals */
.kicker, .case__type, .brands__title, .job__when, .skillset h3, .facts h3, .case__meta dt, .hero__tags, .eyebrow, .metrics__live {
  font-family: var(--label);
  font-size: 13px;
  font-weight: 500;
  font-stretch: 100%;
  letter-spacing: .09em;
  word-spacing: .08em; /* room around the · dividers */
  text-transform: uppercase;
}

/* Buttons */
.btn {
  position: relative; overflow: hidden; isolation: isolate;
  display: inline-flex; align-items: center; justify-content: center; gap: .45em;
  padding: 13px 22px; border-radius: 999px;
  background: var(--wine); color: #fff; text-decoration: none;
  font: 600 15px/1.2 var(--sans); border: 1.5px solid var(--wine);
  transition: color .3s var(--ease), border-color .3s, transform .3s var(--ease);
  white-space: nowrap; cursor: pointer;
}
/* A fill that sweeps up from the bottom on hover */
.btn::before {
  content: ""; position: absolute; inset: 0; z-index: -1; border-radius: inherit;
  background: var(--wine-deep); transform: translateY(101%); transition: transform .35s var(--ease);
}
.btn:hover { transform: translateY(-2px); }
.btn:hover::before { transform: none; }
.btn--ghost { background: transparent; color: var(--wine); border-color: rgba(107, 42, 46, .35); }
.btn--ghost::before { background: var(--wine); }
.btn--ghost:hover { color: #fff; border-color: var(--wine); }
.btn--small { padding: 9px 16px; font-size: 14px; }
.btn--light { background: var(--cream); color: var(--wine); border-color: var(--cream); }
.btn--light::before { background: #fff; }
.btn--outline-light { background: transparent; color: var(--cream); border-color: rgba(244,243,238,.45); }
.btn--outline-light::before { background: var(--cream); }
.btn--outline-light:hover { color: var(--wine); border-color: var(--cream); }

/* Nav: a floating pill */
.nav { position: sticky; top: 0; z-index: 50; padding: 14px 0; }
.nav__inner {
  display: flex; align-items: center; justify-content: space-between;
  background: rgba(255, 253, 249, .86); color: var(--ink);
  -webkit-backdrop-filter: saturate(1.4) blur(12px); backdrop-filter: saturate(1.4) blur(12px);
  border: 1px solid var(--line); border-radius: 999px;
  padding: 7px 7px 7px 22px;
  max-width: calc(1200px - 2 * var(--gutter));
  width: calc(100% - 2 * var(--gutter));
  box-shadow: 0 8px 28px rgba(31, 26, 26, .06);
}
.nav__logo { font-family: var(--display); font-weight: 800; font-stretch: 85%; font-size: 20px; letter-spacing: -0.02em; color: var(--wine); text-decoration: none; white-space: nowrap; }
.nav__links { list-style: none; margin: 0; padding: 0; display: flex; align-items: center; gap: 26px; }
.nav__links a:not(.btn) {
  text-decoration: none; font-weight: 500; font-size: 15px; color: var(--muted);
  background: linear-gradient(var(--wine), var(--wine)) left bottom / 0 1.5px no-repeat;
  padding-bottom: 2px; transition: color .2s, background-size .3s var(--ease);
}
.nav__links a:not(.btn):hover { color: var(--wine); background-size: 100% 1.5px; }
.nav__left { display: flex; align-items: center; gap: 16px; }
.nav__right { display: flex; align-items: center; gap: 22px; }
.lang {
  position: relative; display: inline-grid; grid-template-columns: 1fr 1fr;
  padding: 3px; border-radius: 999px; border: 1px solid var(--line); background: var(--bg);
  isolation: isolate;
}
.lang::before {
  content: ""; position: absolute; z-index: -1; top: 3px; bottom: 3px; left: 3px;
  width: calc(50% - 3px); border-radius: 999px; background: var(--wine);
  transition: transform .3s var(--ease);
}
html[data-lang="es"] .lang::before { transform: translateX(100%); }
.lang button {
  border: 0; background: none; cursor: pointer; padding: 4px 10px; min-width: 38px;
  font: 600 12.5px/1.2 var(--sans); letter-spacing: .02em; color: var(--muted);
  border-radius: 999px; transition: color .2s;
}
.lang button[aria-pressed="true"] { color: #fff; }
.nav__toggle { display: none; background: none; border: 1px solid var(--line); color: var(--ink); border-radius: 999px; padding: 7px 14px; font: 500 14px var(--sans); cursor: pointer; }

/* Hero */
.hero { --px: 0; --py: 0; display: grid; grid-template-columns: 1.1fr .9fr; gap: 48px; align-items: center; padding-top: clamp(40px, 7vw, 96px); padding-bottom: clamp(56px, 8vw, 104px); }
.eyebrow { display: inline-flex; align-items: center; gap: 10px; color: var(--muted); background: var(--paper); border: 1px solid var(--line); padding: 7px 14px; border-radius: 999px; margin-bottom: 28px; line-height: 1.4; }
.dot { width: 7px; height: 7px; border-radius: 50%; background: #3f9a5a; box-shadow: 0 0 0 4px rgba(63,154,90,.16); flex: none; animation: breathe 2.4s ease-in-out infinite; }
@keyframes breathe { 50% { box-shadow: 0 0 0 7px rgba(63,154,90,.06); } }
.hero__title {
  font-family: var(--display); font-weight: 800; font-stretch: 78%;
  font-size: clamp(68px, 11.5vw, 150px); line-height: .86; letter-spacing: -0.035em;
  color: var(--wine);
}
.hero__title .line { display: block; overflow: hidden; padding-bottom: .04em; }
.hero__title .line > span { display: inline-block; animation: rise 1s var(--ease) both; }
.hero__title .line + .line > span { animation-delay: .09s; }
@keyframes rise { from { transform: translateY(105%); } }
.hero__role { font-family: var(--display); font-size: clamp(24px, 2.6vw, 32px); font-weight: 650; font-stretch: 90%; letter-spacing: -0.02em; margin: 26px 0 10px; }
.hero__tags { color: var(--muted); margin-bottom: 24px; }
.hero__lede { font-size: 18px; max-width: 50ch; color: #3d3533; }
.hero__lede strong { color: var(--ink); }
.hero__cta { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 30px; }
.hero__text > *:not(.hero__title) { animation: fadeUp .8s var(--ease) both .25s; }

.hero__media { position: relative; height: clamp(380px, 46vw, 580px); }
.phone {
  margin: 0; position: absolute; width: 50%; aspect-ratio: 390 / 844;
  border-radius: 36px; overflow: hidden; background: #111;
  border: 7px solid #1b1414; box-shadow: 0 24px 56px rgba(31, 26, 26, .2);
  container-type: inline-size;
  transition: translate .6s var(--ease);
}
.hero .phone { animation: phoneIn 1.1s var(--ease) both; }
.phone--back { right: 4%; top: 0; rotate: 5deg; translate: calc(var(--px) * -18px) calc(var(--py) * -14px); animation-delay: .15s !important; }
.phone--front { left: 8%; bottom: 0; rotate: -4deg; translate: calc(var(--px) * 26px) calc(var(--py) * 20px); animation-delay: .3s !important; }
@keyframes phoneIn { from { opacity: 0; transform: translateY(60px); } }
.hero .phone { cursor: pointer; }
@media (hover: hover) {
  .hero .phone { transition: translate .6s var(--ease), scale .4s var(--ease), box-shadow .4s; }
  .hero .phone:hover { scale: 1.04; box-shadow: 0 34px 70px rgba(31, 26, 26, .26); }
}

/* Inside each phone: a generic article page with the ad placed in the text */
.phone__screen { position: absolute; inset: 0; overflow: hidden; background: #fff; border-radius: 29px; }
.phone__notch { position: absolute; z-index: 2; top: 2.6cqw; left: 50%; width: 26cqw; height: 6.5cqw; margin-left: -13cqw; border-radius: 99px; background: #111; }
.page { position: absolute; left: 0; top: 0; width: 100%; padding: 13cqw 6cqw 10cqw; background: #fff; will-change: transform; transition: transform .25s linear; }
.page__bar { display: flex; align-items: center; justify-content: space-between; margin-bottom: 6cqw; padding-bottom: 4cqw; border-bottom: 1px solid #eee; }
.page__bar b { width: 30cqw; height: 4.6cqw; border-radius: 1.4cqw; background: #2a2222; }
.page__bar span { width: 6.5cqw; height: 4.4cqw; border-top: 1.1cqw solid #2a2222; border-bottom: 1.1cqw solid #2a2222; position: relative; }
.page__bar span::after { content: ""; position: absolute; left: 0; right: 0; top: 50%; height: 1.1cqw; margin-top: -.55cqw; background: #2a2222; }
.page i { display: block; height: 2.8cqw; border-radius: 1.4cqw; background: #e8e3dc; margin-bottom: 2.4cqw; }
.page__head i { height: 5.4cqw; background: #2a2222; margin-bottom: 2.2cqw; }
.page__meta i { height: 2.4cqw; background: #cfc8bf; margin: 3.4cqw 0 5cqw; }
.page__pic { height: 44cqw; border-radius: 3cqw; margin-bottom: 6cqw; background: linear-gradient(135deg, #efe9e0, #dcd3c7); }
.page__ad { margin: 5cqw -6cqw 6cqw; padding-top: 2.2cqw; background: #f3f1ed; }
.page__adlabel { display: block; padding-bottom: 2cqw; text-align: center; font: 500 2.9cqw/1 var(--sans); color: #9a918c; }
.page__ad img, .page__ad video { display: block; width: 100%; height: auto; }
video { display: block; max-width: 100%; height: auto; }
/* A video that is still loading takes no space, so the still image never shows twice. */
video.is-loading { position: absolute !important; top: 0; left: 0; width: 100% !important; height: 100% !important; opacity: 0; pointer-events: none; }
/* The still image after its video has taken over: hidden, but kept for its alt text. */
img.is-swapped { position: absolute !important; width: 1px !important; height: 1px !important; overflow: hidden; clip-path: inset(50%); opacity: 0; pointer-events: none; }
.page--still { transform: translateY(var(--dist)); transition: none; }

/* "Scroll down" nudge pinned to the bottom of the screen */
.nudge {
  position: fixed; left: 50%; bottom: 22px; z-index: 40;
  display: inline-flex; align-items: center; gap: 10px; padding: 11px 14px 11px 20px; border-radius: 999px;
  background: var(--wine); color: #fff; text-decoration: none; font: 600 14px/1 var(--sans);
  box-shadow: 0 14px 34px rgba(78, 28, 32, .3);
  opacity: 0; visibility: hidden; transform: translate(-50%, 20px);
  transition: opacity .4s, transform .5s var(--ease), visibility 0s .5s, background .2s;
}
.nudge.is-in { opacity: 1; visibility: visible; transform: translate(-50%, 0); transition: opacity .4s, transform .5s var(--ease), visibility 0s, background .2s; }
.nudge.is-gone { display: none; }
.nudge { white-space: nowrap; }
@media (max-width: 760px) { .nudge { display: none; } }
.nudge:hover { background: var(--wine-deep); }
.nudge i { position: relative; width: 22px; height: 22px; border-radius: 50%; background: rgba(255,255,255,.16); }
.nudge i::before { content: ""; position: absolute; left: 50%; top: 5px; width: 1.6px; height: 10px; margin-left: -.8px; background: #fff; animation: nudgeArrow 1.6s var(--ease) infinite; }
.nudge i::after { content: ""; position: absolute; left: 50%; top: 9px; width: 6px; height: 6px; margin-left: -3.5px; border-right: 1.6px solid #fff; border-bottom: 1.6px solid #fff; transform: rotate(45deg); animation: nudgeArrow 1.6s var(--ease) infinite; }
@keyframes nudgeArrow { 0%, 20% { translate: 0 -2px; opacity: 1; } 60% { translate: 0 3px; opacity: 1; } 100% { translate: 0 3px; opacity: 0; } }

/* Case-study phones scroll their page on a loop, pausing on the ad */
.case .page { animation: pageScroll 11s ease-in-out infinite; transition: none; }
.case:nth-of-type(2n) .page { animation-delay: -4s; }
.phone--case .phone__screen { border-radius: 21px; }
@keyframes pageScroll { 0%, 15% { transform: translateY(var(--a)); } 50%, 65% { transform: translateY(var(--b)); } 100% { transform: translateY(var(--a)); } }
@keyframes fadeUp { from { opacity: 0; transform: translateY(14px); } }

/* Brands: logo strip */
.brands { padding: 8px 0 0; }
.brands__title { color: var(--muted); margin: 0 0 18px; }
.marquee {
  overflow: hidden; padding: 18px 0;
  border-top: 1px solid var(--line); border-bottom: 1px solid var(--line);
  -webkit-mask-image: linear-gradient(90deg, transparent, #000 8%, #000 92%, transparent);
  mask-image: linear-gradient(90deg, transparent, #000 8%, #000 92%, transparent);
}
.marquee__track { display: flex; width: max-content; animation: marquee 78s linear infinite; }
.marquee:hover .marquee__track { animation-play-state: paused; }
@keyframes marquee { to { transform: translateX(-50%); } }
.brands__list { list-style: none; margin: 0; padding: 0 28px 0 0; display: flex; align-items: center; gap: 0 56px; }
.brands__list li { display: flex; align-items: center; height: 64px; flex: none; }
.brands__list img {
  height: 30px; width: auto; max-width: none;
  filter: grayscale(1) contrast(1.1); opacity: .5;
  transition: filter .35s, opacity .35s, transform .35s var(--ease);
}
/* Balances the logos by area; older browsers without sqrt() keep one height */
@supports (height: calc(1px * sqrt(4))) { .brands__list img { height: calc(46px / sqrt(var(--r, 1))); } }
/* Pale logos (yellow arches) need darkening to stay visible in grey */
.brands__list img[src*="mcdonalds"] { filter: grayscale(1) brightness(.55) contrast(1.6); }
.brands__list li:hover img { filter: none; opacity: 1; transform: scale(1.12); }

/* Metrics */
.metrics { display: grid; grid-template-columns: repeat(4, 1fr); margin-top: 56px; }
.metrics__live { grid-column: 1 / -1; display: inline-flex; align-items: center; gap: 10px; color: var(--muted); margin: 0 0 14px; }
/* A quiet "still counting" dot: burgundy, slow, small */
.live-dot { width: 7px; height: 7px; border-radius: 50%; background: var(--wine-soft); animation: livePulse 2.8s ease-out infinite; }
@keyframes livePulse { 0% { box-shadow: 0 0 0 0 rgba(140,64,70,.35); } 70%, 100% { box-shadow: 0 0 0 7px rgba(140,64,70,0); } }
.metric { padding: 28px 24px 26px; border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); cursor: default; transition: background .3s; }
.metric + .metric { border-left: 1px solid var(--line); }
.metrics__live + .metric { padding-left: 0; border-left: 0; }
.metric__num { transform-origin: 0 100%; transition: transform .45s var(--ease), color .3s; }
.metric:hover .metric__num { transform: scale(1.08); color: var(--wine-deep); }
.metric__num {
  display: block; font-family: var(--display); font-weight: 800; font-stretch: 80%;
  font-size: clamp(48px, 5.6vw, 76px); letter-spacing: -0.03em; color: var(--wine);
  line-height: 1; margin-bottom: 12px; font-variant-numeric: tabular-nums;
}
.metric__num small { font-size: .45em; margin-left: 3px; letter-spacing: 0; }
.odo { display: inline-flex; align-items: baseline; line-height: 1; }
.odo__reel { display: inline-block; height: 1em; overflow: hidden; -webkit-mask-image: linear-gradient(transparent, #000 18%, #000 82%, transparent); mask-image: linear-gradient(transparent, #000 18%, #000 82%, transparent); }
.odo__strip { display: block; will-change: transform; }
.odo__strip span { display: block; height: 1em; line-height: 1; text-align: center; }
.metric__label { font-size: 14px; color: var(--muted); line-height: 1.45; display: block; max-width: 22ch; }

/* Sections */
.section { padding-top: clamp(88px, 11vw, 144px); padding-bottom: 0; }
.section--tint { background: none; }
.section__head { margin-bottom: clamp(32px, 4vw, 52px); max-width: 780px; }
.kicker { color: var(--wine-soft); margin-bottom: 16px; }
.kicker--light { color: rgba(244,243,238,.7); }
p.kicker.kicker { font-size: 13px; } /* same size in About and Contact, whose paragraphs are larger */
.section__intro { font-size: 18px; color: var(--muted); margin-top: 20px; max-width: 58ch; }

/* Case studies: big rounded cards */
.case {
  display: grid; grid-template-columns: minmax(0, .85fr) minmax(0, 1.15fr);
  gap: clamp(28px, 4vw, 56px); align-items: center;
  background: var(--tint); border-radius: var(--card);
  padding: clamp(24px, 4vw, 52px);
  margin-bottom: 20px;
  transition: background .4s;
}
.case:hover { background: #ebe4da; }
.case__media, .case--flip .case__media { order: 2; position: relative; padding: 0 14% 9% 0; }
.case__wide { width: 100%; border-radius: var(--radius); box-shadow: 0 18px 40px rgba(31, 26, 26, .12); background: #ddd; transition: transform .6s var(--ease), box-shadow .6s; }
.phone--case, .case--flip .phone--case { width: 24%; right: 0; left: auto; bottom: 0; border-width: 5px; border-radius: 26px; rotate: 0deg; transition: transform .6s var(--ease); }
@media (hover: hover) {
  .case:hover .case__wide { transform: translateY(-6px) scale(1.015); box-shadow: 0 28px 56px rgba(31, 26, 26, .16); }
  .case:hover .phone--case { transform: translateY(-16px) rotate(4deg); }
}
.case__type { color: var(--wine-soft); margin-bottom: 10px; }
.case h3 { font-family: var(--display); font-weight: 800; font-stretch: 80%; font-size: clamp(42px, 4.6vw, 64px); letter-spacing: -0.03em; line-height: .95; color: var(--wine); margin-bottom: 14px; }
.case__summary { font-size: 19px; font-weight: 500; line-height: 1.4; color: var(--ink); max-width: 34ch; margin-bottom: 24px; }
.case__links { display: flex; align-items: center; flex-wrap: wrap; gap: 8px; }

/* Expandable sections (project details, experience) */
details > summary { list-style: none; cursor: pointer; }
details > summary::-webkit-details-marker { display: none; }
details::details-content { height: 0; overflow: clip; transition: height .45s var(--ease), content-visibility .45s allow-discrete; }
details[open]::details-content { height: auto; }
/* Open / close labels swap with the state */
details[open] > summary .more__open, details:not([open]) > summary .more__close { display: none; }
.more__icon { position: relative; width: 26px; height: 26px; border-radius: 50%; background: var(--wine); color: #fff; flex: none; transition: transform .4s var(--ease), background .3s, color .3s; }
.more__icon::before, .more__icon::after { content: ""; position: absolute; left: 50%; top: 50%; width: 10px; height: 1.8px; margin: -.9px 0 0 -5px; background: currentColor; border-radius: 1px; transition: transform .4s var(--ease); }
.more__icon::after { transform: rotate(90deg); }
details[open] > summary .more__icon { transform: rotate(180deg); }
details[open] > summary .more__icon::after { transform: rotate(0); }

/* Project details: a full-width button bar */
.more { margin-top: 20px; }
.more > summary {
  display: flex; align-items: center; justify-content: space-between; gap: 12px;
  padding: 10px 10px 10px 18px; border-radius: 14px;
  background: var(--paper); border: 1px solid var(--line-tint);
  font: 600 15px var(--sans); color: var(--wine);
  transition: background .3s, color .3s, border-color .3s;
}
.more > summary:hover { background: var(--wine); border-color: var(--wine); color: #fff; }
.more > summary:hover .more__icon { background: #fff; color: var(--wine); }
.more[open] > summary { background: transparent; }
.more[open] > summary:hover { background: var(--wine); }

/* Experience: a "See more" pill on each row */
.more__pill {
  display: inline-flex; align-items: center; gap: 10px; white-space: nowrap;
  padding: 5px 5px 5px 16px; border-radius: 999px; background: var(--paper); border: 1px solid var(--line);
  font: 600 14px var(--sans); color: var(--wine); transition: background .3s, color .3s, border-color .3s;
}
.job summary:hover .more__pill { background: var(--wine); border-color: var(--wine); color: #fff; }
.job summary:hover .more__pill .more__icon { background: #fff; color: var(--wine); }
.more__body { padding-top: 14px; }
.more__body > p { font-size: 16px; color: var(--muted); }
.case__meta { margin: 16px 0 0; display: grid; font-size: 14px; }
.case__meta div { display: grid; grid-template-columns: 104px 1fr; gap: 12px; border-top: 1px solid var(--line-tint); padding: 8px 0; }
.case__meta dt { color: var(--muted); padding-top: 1px; font-size: 12px; letter-spacing: .06em; }
.case__meta dd { margin: 0; }

/* "On your phone" QR popover */
.qrpop { position: relative; }
.qrpop__btn {
  display: inline-flex; align-items: center; gap: 6px; height: 38px; padding: 0 14px 0 11px;
  border-radius: 999px; border: 1.5px dashed rgba(107, 42, 46, .35); background: none;
  color: var(--wine); font: 600 14px var(--sans); cursor: pointer; transition: background .25s, border-color .25s;
}
.qrpop__btn svg { width: 16px; height: 16px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; }
.qrpop:hover .qrpop__btn, .qrpop.is-open .qrpop__btn { background: var(--paper); border-style: solid; }
.qrpop__card {
  position: absolute; left: 50%; bottom: calc(100% + 14px); z-index: 5; width: 200px;
  background: var(--paper); border: 1px solid var(--line); border-radius: 20px; padding: 14px 14px 12px;
  box-shadow: 0 24px 48px rgba(31, 26, 26, .16); text-align: center;
  opacity: 0; visibility: hidden; transform: translate(-50%, 10px) scale(.94); transform-origin: 50% 100%;
  transition: opacity .25s, transform .35s var(--ease), visibility 0s .35s;
}
.qrpop__card::after { content: ""; position: absolute; left: 50%; bottom: -7px; width: 12px; height: 12px; margin-left: -6px; background: var(--paper); border-right: 1px solid var(--line); border-bottom: 1px solid var(--line); transform: rotate(45deg); }
.qrpop__code { color: var(--wine); }
.qrpop__code svg { display: block; width: 100%; height: auto; }
.qr__logo { fill: var(--wine); }
.qr__mono { fill: var(--paper); font-family: var(--display); font-weight: 800; font-stretch: 80%; text-anchor: middle; dominant-baseline: central; letter-spacing: -0.04em; }
.qrpop__card p { margin: 10px 0 0; font-size: 13px; line-height: 1.35; color: var(--muted); }
.qrpop:hover .qrpop__card, .qrpop:focus-within .qrpop__card, .qrpop.is-open .qrpop__card {
  opacity: 1; visibility: visible; transform: translate(-50%, 0) scale(1); transition: opacity .25s, transform .35s var(--ease), visibility 0s;
}

/* Experience: expandable rows */
.timeline { list-style: none; margin: 0; padding: 0; border-top: 1px solid var(--line); }
.job { border-bottom: 1px solid var(--line); }
.job summary { display: grid; grid-template-columns: 220px 1fr auto; gap: 32px; align-items: center; padding: 26px 0; transition: padding .35s var(--ease); }
.job summary:hover { padding-left: 12px; }

.job__when { color: var(--wine); }
.job__main { display: block; }
.job__title { font-family: var(--display); font-size: clamp(22px, 2.2vw, 28px); font-weight: 700; font-stretch: 88%; letter-spacing: -0.02em; display: block; }
.job__where { display: block; color: var(--muted); margin-top: 4px; font-size: 15px; }
.job__body { padding: 0 0 28px calc(220px + 32px); }
.job ul { margin: 0; padding-left: 1.1em; max-width: 72ch; }
.job li { margin-bottom: 8px; color: #3d3533; }
.job li::marker { color: var(--wine-soft); }

/* Skills: three short cards */
.skills { display: grid; grid-template-columns: repeat(4, 1fr); gap: 14px; }
@media (max-width: 1100px) { .skills { grid-template-columns: repeat(2, 1fr); } }
.skill {
  position: relative; display: flex; flex-direction: column;
  background: var(--tint); border-radius: var(--card); padding: 28px 28px 26px;
  transition: background .4s var(--ease), color .4s, transform .4s var(--ease);
}
.skill__num { font: 500 13px var(--label); letter-spacing: .09em; color: var(--wine-soft); transition: color .4s; }
.skill h3 { font-family: var(--display); font-weight: 800; font-stretch: 80%; font-size: clamp(36px, 3.6vw, 48px); letter-spacing: -0.03em; color: var(--wine); margin: 44px 0 12px; transition: color .4s; }
.skill p { font-size: 15.5px; color: #3d3533; margin: 0 0 18px; transition: color .4s; }
.skill .skill__tools { margin: auto 0 0; padding-top: 14px; border-top: 1px solid var(--line-tint); font: 500 14px/1.55 var(--sans); word-spacing: .08em; color: var(--muted); transition: color .4s, border-color .4s; }
@media (hover: hover) {
  .skill:hover { background: var(--wine); transform: translateY(-6px); }
  .skill:hover h3, .skill:hover p { color: var(--cream); }
  .skill:hover .skill__num, .skill:hover .skill__tools { color: rgba(244, 243, 238, .7); border-color: rgba(244, 243, 238, .2); }
}
.skills__ai { margin: 20px 0 0; font-size: 15px; color: var(--muted); max-width: 70ch; }

/* About */
.about { display: grid; grid-template-columns: .8fr 1.2fr; gap: clamp(28px, 5vw, 72px); align-items: center; }
.about__photo { border-radius: var(--card); aspect-ratio: 4 / 5; object-fit: cover; width: 100%; transition: transform .6s var(--ease), border-radius .6s var(--ease); }
.about__photo:hover { transform: rotate(-2deg) scale(1.02); border-radius: 48px; }
.about__text h2 { margin-bottom: 22px; }
.about__text > p { font-size: 18px; color: #3d3533; max-width: 56ch; }
.facts { display: grid; grid-template-columns: 1fr 1fr; gap: 28px; margin-top: 32px; padding-top: 28px; border-top: 1px solid var(--line); }
.facts h3 { color: var(--wine); margin-bottom: 14px; }
.facts ul { list-style: none; margin: 0; padding: 0; }
.facts li { margin-bottom: 14px; font-size: 15px; line-height: 1.5; color: var(--muted); }
.facts li strong { color: var(--ink); font-weight: 600; }

/* Contact: a burgundy card */
.contact {
  position: relative; overflow: hidden;
  background: var(--wine); color: var(--cream);
  width: calc(100% - 2 * var(--gutter)); max-width: calc(1200px - 2 * var(--gutter));
  margin: clamp(88px, 11vw, 144px) auto 0; border-radius: var(--card);
  padding: clamp(44px, 7vw, 104px) 0;
}
.contact::before {
  content: ""; position: absolute; width: 520px; height: 520px; right: -160px; top: -200px; border-radius: 50%;
  background: radial-gradient(circle, rgba(244,243,238,.14), transparent 65%);
  animation: drift 12s ease-in-out infinite alternate;
}
@keyframes drift { to { transform: translate(-120px, 120px) scale(1.2); } }
.contact .wrap { position: relative; padding: 0 clamp(24px, 5vw, 72px); }
.contact h2 { color: var(--cream); max-width: 16ch; margin-bottom: 20px; font-size: clamp(40px, 5.6vw, 76px); }
.contact p { font-size: 18px; opacity: .85; max-width: 52ch; }
.contact__links { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 32px; }

.footer { color: var(--muted); font-size: 14px; padding: 28px 0 36px; }
.footer__inner { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 8px; }
.footer__legal { flex-basis: 100%; display: flex; flex-wrap: wrap; gap: 4px 18px; margin: 6px 0 0; font-size: 13px; opacity: .85; }
.footer__legal a { text-decoration: underline; text-decoration-color: var(--line); text-underline-offset: 3px; transition: color .2s, text-decoration-color .2s; }
.footer__legal a:hover { color: var(--wine); text-decoration-color: currentColor; }

/* Privacy & legal page */
.legal { padding-bottom: clamp(64px, 8vw, 104px); }
.legal > * { max-width: 780px; }
.legal__title {
  font-family: var(--display); font-size: clamp(38px, 5.4vw, 66px); font-weight: 750; font-stretch: 85%;
  letter-spacing: -0.03em; line-height: 1; color: var(--wine); text-wrap: balance; margin-bottom: 24px;
}
.legal__lede { font-size: 19px; max-width: 60ch; }
.legal__updated { font: 500 13px/1.4 var(--label); letter-spacing: .09em; text-transform: uppercase; color: var(--muted); }
.legal h2 { font-size: clamp(26px, 3vw, 34px); margin: 52px 0 16px; padding-top: 28px; border-top: 1px solid var(--line); }
.legal h3 { font-family: var(--display); font-size: 20px; font-weight: 700; font-stretch: 90%; color: var(--ink); margin: 26px 0 8px; }
.legal p, .legal li { color: #3d3534; max-width: 68ch; }
.legal ul { padding-left: 1.2em; margin: 0 0 1em; }
.legal li { margin-bottom: 6px; }
.legal li::marker { color: var(--wine-soft); }
.legal a:not(.btn) { color: var(--wine); text-underline-offset: 3px; }
.legal a:not(.btn):hover { color: var(--wine-deep); }
.legal__back { margin-top: 48px; }

/* Try-it-live trigger on case media */
.live-btn {
  position: absolute; top: 14px; left: 14px; z-index: 2;
  display: inline-flex; align-items: center; gap: 8px;
  padding: 9px 16px 9px 12px; border-radius: 999px; border: 0;
  background: rgba(31, 26, 26, .78); color: #fff; font: 600 14px/1 var(--sans);
  -webkit-backdrop-filter: blur(6px); backdrop-filter: blur(6px); cursor: pointer;
  transition: background .2s, transform .5s var(--ease);
}
.case--flip .live-btn { left: 14px; right: auto; }
.live-btn:hover { background: var(--wine); }
/* With a mouse, the cursor becomes the "Try it live" button over the image */
.live-cover { position: absolute; inset: 0; z-index: 3; display: block; }
.case__media .live-btn { transition: opacity .25s, transform .25s var(--ease), background .2s; }
/* Only once the custom cursor is running, so the button never vanishes without a replacement */
html.has-cursor .case__media:hover .live-btn:not(:hover) { opacity: 0; transform: translateY(-6px); }

/* Custom cursor */
html.has-cursor, html.has-cursor * { cursor: none !important; }
.cursor { position: fixed; inset: 0; z-index: 1000; pointer-events: none; opacity: 0; transition: opacity .3s; }
.cursor.is-visible { opacity: 1; }
.cursor__dot, .cursor__ring { position: absolute; left: 0; top: 0; will-change: transform; }
.cursor__dot { width: 8px; height: 8px; margin: -4px 0 0 -4px; border-radius: 50%; background: var(--wine); transition: opacity .2s, scale .2s; }
.cursor__ring { width: 0; height: 0; display: grid; place-items: center; }
.cursor__ring::before {
  content: ""; position: absolute; width: 34px; height: 34px; margin: -17px 0 0 -17px; left: 0; top: 0;
  border-radius: 50%; border: 1.5px solid rgba(107, 42, 46, .45);
  transition: width .3s var(--ease), height .3s var(--ease), margin .3s var(--ease), background .3s, border-color .3s;
}
.cursor[data-state="link"] .cursor__ring::before { width: 56px; height: 56px; margin: -28px 0 0 -28px; background: rgba(107, 42, 46, .08); border-color: rgba(107, 42, 46, .25); }
.cursor.is-down .cursor__ring::before { width: 26px; height: 26px; margin: -13px 0 0 -13px; }
.cursor__label {
  position: absolute; left: 0; top: 0; translate: -50% -50%; white-space: nowrap;
  display: inline-flex; align-items: center; gap: 8px; padding: 12px 18px 12px 14px; border-radius: 999px;
  background: var(--wine); color: #fff; font: 600 14px/1 var(--sans);
  box-shadow: 0 10px 30px rgba(78, 28, 32, .35);
  scale: .3; opacity: 0; transition: scale .35s var(--ease), opacity .2s;
}
.cursor__label i { width: 0; height: 0; border-left: 8px solid #fff; border-top: 5px solid transparent; border-bottom: 5px solid transparent; }
.cursor[data-state="play"] .cursor__label { scale: 1; opacity: 1; }
.cursor[data-state="play"] .cursor__ring::before { opacity: 0; }
.cursor[data-state="play"] .cursor__dot { opacity: 0; }
.live-btn__dot { width: 8px; height: 8px; border-radius: 50%; background: #ff5a5f; box-shadow: 0 0 0 0 rgba(255,90,95,.6); animation: pulse 1.8s infinite; }
@keyframes pulse { 70% { box-shadow: 0 0 0 8px rgba(255,90,95,0); } 100% { box-shadow: 0 0 0 0 rgba(255,90,95,0); } }
.btn--live { gap: 8px; }
.btn--live .live-btn__dot { background: #ff8a8e; }

/* Reveal on scroll */
.reveal { opacity: 0; transform: translateY(24px); transition: opacity .8s var(--ease), transform .8s var(--ease); }
.reveal.is-in { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *:not(.marquee__track), *::before, *::after { animation: none !important; } /* the slow logo strip keeps moving */
  .lang::before, .lang button, .btn, .btn::before { transition: none; }
  .reveal { opacity: 1; transform: none; transition: none; }
  details::details-content { transition: none; }
  .case .page, .page--still { transform: translateY(var(--dist)); }
}

/* Responsive */
@media (max-width: 960px) {
  .hero { grid-template-columns: 1fr; }
  .hero__media { height: 500px; max-width: 460px; width: 100%; margin: 0 auto; }
  .metrics { grid-template-columns: repeat(2, 1fr); }
  .metric:nth-child(4) { border-left: 0; padding-left: 0; }
  .metric:nth-child(n+4) { border-top: 0; }
  .case { grid-template-columns: 1fr; }
  .case__media, .case--flip .case__media { order: 0; }
  .about { grid-template-columns: 1fr; }
  .about__photo { max-width: 420px; }
  .skill { min-height: 0; }
  .skill h3 { margin-top: 20px; }
  .job summary { grid-template-columns: 160px 1fr auto; gap: 20px; }
  .job__body { padding-left: calc(160px + 20px); }
}
@media (max-width: 760px) {
  body { font-size: 16px; }
  .nav { padding: 10px 0; }
  .nav__toggle { display: inline-block; }
  .nav__right { gap: 8px; }
  .nav__left { gap: 10px; }
  .nav__logo { font-size: 17px; }
  .nav__inner { padding: 6px 6px 6px 16px; position: relative; }
  .lang button { min-width: 32px; padding: 4px 7px; }
  .nav__links {
    display: none; position: absolute; left: 0; right: 0; top: calc(100% + 8px);
    flex-direction: column; align-items: stretch; gap: 0;
    background: var(--paper); border: 1px solid var(--line); border-radius: 20px; padding: 8px 16px 16px;
    box-shadow: 0 16px 40px rgba(31,26,26,.12);
  }
  .nav__links.is-open { display: flex; }
  .nav__links li a:not(.btn) { display: block; padding: 13px 4px; border-bottom: 1px solid var(--line); color: var(--ink); background: none; }
  .nav__links .btn { margin-top: 14px; width: 100%; }
  .hero__media { height: 420px; }
  .brands__list { gap: 0 40px; }
  .brands__list img { height: calc(38px / sqrt(var(--r, 1))); }
  .metric { padding: 22px 14px 20px; }
  .metric:nth-child(even) { padding-left: 0; border-left: 0; }
  .metric__label { font-size: 13px; }
  .case { padding: 18px 18px 22px; }
  .case__media { padding: 0 12% 8% 0; }
  .qrpop { display: none; }
  .job summary { grid-template-columns: 1fr auto; gap: 4px 16px; padding: 20px 0; }
  .job summary:hover { padding-left: 0; }
  .job__when { grid-column: 1; }
  .job__main { grid-column: 1; }
  .job summary .more__pill { grid-column: 2; grid-row: 1 / span 2; }
  .job__body { padding-left: 0; }
  .skills { grid-template-columns: 1fr; }
  .facts { grid-template-columns: 1fr; }
  .hero__cta .btn, .contact__links .btn { flex: 1 1 100%; }
}
