/* SECTIONS — intro video, selected work (01–06), lightbox, closing line, footer.
   Scoped to new class names only: nothing here targets the hero.
   Mobile first: one column, one video in view at a time; desktop: ordered grid.
   Video cards use transform/opacity only for motion; no backdrop blur over
   playing video (too costly on phones).
   Reveal is progressive enhancement: the hidden state exists only under
   html.sr-on, which js/sections.js adds when motion is allowed. */

:root {
  --sx-max: 1280px;
  --sx-gap: clamp(14px, 2.2vw, 32px);
  --sx-section-y: clamp(72px, 9vw, 150px);
  --sx-fs-intro: clamp(2.1rem, 1.3rem + 3vw, 4rem);
  --sx-radius: 12px;
  --card-w: min(100%, 32svh, 340px);          /* one vertical card on a phone */
}

/* ---- Layout helpers -------------------------------------------------- */
.sx-wrap {
  width: 100%;
  max-width: calc(var(--sx-max) + 2 * var(--pad-x));
  margin-inline: auto;
  padding-inline: var(--pad-x);
}
.sx-kicker {
  display: flex; align-items: center; gap: 14px;
  font-family: var(--font-ui); font-size: var(--fs-micro); font-weight: 500;
  letter-spacing: var(--track-wide); text-transform: uppercase; color: var(--c-ivory-muted);
}
.sx-kicker::before { content: ""; flex: none; width: 28px; height: 1px; background: var(--c-gold); }

/* ---- Video card: poster + muted loop + play mark; tap = full video ------ */
.vcard { margin: 0; display: grid; gap: 10px; }
.vcard__media {
  position: relative; display: block; width: 100%; aspect-ratio: 9 / 16;
  padding: 0; margin: 0; border: 1px solid var(--c-line); border-radius: var(--sx-radius);
  overflow: hidden; background: var(--c-bg-deep); cursor: pointer;
  -webkit-tap-highlight-color: transparent;
  box-shadow: 0 30px 70px -36px rgba(0, 0, 0, .8);
  transition: border-color var(--dur-xs) var(--ease-out);
}
.vcard__media:hover, .vcard__media:focus-visible { border-color: var(--c-gold-a55); }
.vcard__media:focus-visible { outline-offset: 4px; border-radius: var(--sx-radius); }
.vcard__loop {
  position: absolute; inset: 0; width: 100%; height: 100%;
  object-fit: cover; background: var(--c-bg-deep); pointer-events: none;
}
.vcard__media::after { /* soft vignette so the play mark reads on any frame */
  content: ""; position: absolute; inset: 0; pointer-events: none;
  background: radial-gradient(60% 40% at 50% 50%, rgba(14, 11, 8, .28), transparent 75%);
}
.vcard__play {
  position: absolute; z-index: 2; left: 50%; top: 50%;
  width: 56px; height: 56px; margin: -28px 0 0 -28px;
  display: grid; place-items: center; border-radius: 50%;
  background: rgba(20, 16, 12, .55);
  border: 1px solid rgba(241, 232, 218, .55);
  box-shadow: 0 0 0 1px rgba(156, 123, 60, .35), 0 10px 30px rgba(0, 0, 0, .35);
  color: var(--c-ivory);
  transition: transform var(--dur-xs) var(--ease-out), background-color var(--dur-xs) var(--ease-out), opacity var(--dur-sm) var(--ease-out);
}
.vcard__play svg { width: 22px; height: 22px; margin-left: 3px; fill: currentColor; }
.vcard__media:hover .vcard__play, .vcard__media:focus-visible .vcard__play { transform: scale(1.07); background: rgba(156, 123, 60, .72); }
.vcard__media:active .vcard__play { transform: scale(.96); }
/* while a loop runs, the small play mark steps back (still tappable: the whole card is the button) */
.vcard__media.is-live .vcard__play:not(.vcard__play--lg) { opacity: .7; }

/* intro: a large, labelled PLAY */
.vcard__play--lg {
  width: auto; height: 60px; margin: -30px 0 0; transform: translateX(-50%);
  grid-auto-flow: column; gap: 12px; padding: 0 26px 0 22px; border-radius: 999px;
  background: rgba(20, 16, 12, .62);
  border-color: rgba(196, 164, 104, .85);
  font-size: .78rem; font-weight: 500; letter-spacing: var(--track-wide); text-transform: uppercase;
}
.vcard__play--lg svg { width: 22px; height: 22px; margin: 0; color: var(--c-gold-light); }
.vcard__media:hover .vcard__play--lg, .vcard__media:focus-visible .vcard__play--lg { transform: translateX(-50%) scale(1.05); }
.vcard__media:active .vcard__play--lg { transform: translateX(-50%) scale(.97); }
.vcard__cap {
  font-size: var(--fs-micro); font-weight: 500; letter-spacing: var(--track-mid);
  text-transform: uppercase; color: var(--c-ivory-dim); line-height: 1.4;
}

/* "Tap for sound": a small cue under PLAY, only on the card in front
   (phone/tablet intro, centred card of the phone carousel, front card of the
   desktop wheel). Hidden while the full video is open. */
.snd-hint {
  position: absolute; z-index: 2; left: 50%; top: calc(50% + 40px);
  display: none; align-items: center; gap: 7px;
  padding: 5px 11px 5px 9px; border-radius: 999px;
  background: rgba(14, 11, 8, .42);
  font-family: var(--font-ui); font-size: .6rem; font-weight: 400; line-height: 1;
  letter-spacing: var(--track-wide); text-transform: uppercase; white-space: nowrap;
  color: rgba(241, 232, 218, .86); text-shadow: 0 1px 6px rgba(0, 0, 0, .55);
  transform: translateX(-50%); pointer-events: none;
  transition: opacity var(--dur-sm) var(--ease-out);
}
.snd-hint svg { flex: none; width: 12px; height: 12px; fill: none; stroke: #D9B26A; stroke-width: 1.2; stroke-linecap: round; stroke-linejoin: round; }
.vcard--intro .snd-hint { display: inline-flex; top: calc(50% + 44px); }
@media (max-width: 599px) {
  .cases .is-centre .snd-hint { display: inline-flex; }
}
html.lb-open .snd-hint { opacity: 0; visibility: hidden; }

/* ---- Intro (right under the hero) --------------------------------------- */
.intro { position: relative; z-index: 1; padding-block: clamp(36px, 6vw, 96px) var(--sx-section-y); scroll-margin-top: 16px; }
.intro__in { display: grid; gap: 22px; justify-items: center; }
.intro__copy { justify-self: stretch; }
.intro__line {
  margin-top: 16px;
  font-family: var(--font-display); font-weight: 400;
  font-size: var(--sx-fs-intro); line-height: 1.04; letter-spacing: -.015em; color: var(--c-ivory);
}
.intro__line em { font-style: italic; }
.vcard--intro { width: min(100%, 40svh, 420px); }
.intro__side { justify-self: stretch; display: grid; gap: 18px; }

/* ---- Skills: chips enter one at a time, land on four "tracks", then breathe -- */
.skills { position: relative; }
.skills__list { margin: 0; padding: 0; list-style: none; display: flex; flex-wrap: wrap; gap: 7px 6px; }
.skills__lane { display: contents; }
.chip {
  position: relative;
  display: inline-flex; align-items: center; gap: 6px;
  padding: 6px 10px 6px 8px; border-radius: 999px;
  font-family: var(--font-ui); font-size: .72rem; font-weight: 400; letter-spacing: .02em; line-height: 1.2;
  white-space: nowrap; color: var(--c-ivory);
  background: linear-gradient(155deg, rgba(64, 51, 40, .55), rgba(26, 21, 17, .78));
  border: 1px solid rgba(217, 178, 106, .38);
  box-shadow: inset 0 1px 0 rgba(241, 232, 218, .06), 0 10px 24px -14px rgba(0, 0, 0, .8);
}
.chip svg { flex: none; width: 13px; height: 13px; fill: none; stroke: #D9B26A; stroke-width: 1.2; stroke-linecap: round; stroke-linejoin: round; }
.chip::after { /* the gold "light" a chip gets as it lands */
  content: ""; position: absolute; inset: -1px; border-radius: inherit; pointer-events: none; opacity: 0;
  border: 1px solid #F0C75E;
  box-shadow: 0 0 14px rgba(240, 180, 80, .55), inset 0 0 10px rgba(240, 199, 94, .22);
}

@media (min-width: 1024px) {
  .intro__in { align-items: stretch; }
  .intro__side { grid-template-rows: auto 1fr; gap: clamp(28px, 5vh, 56px); align-self: stretch; }
  .intro__copy { align-self: start; }
  .skills { align-self: center; }
  .skills__list { display: grid; gap: clamp(14px, 2.6vh, 26px); }
  .skills__lane {
    position: relative; display: flex; flex-wrap: wrap; gap: 12px;
    padding: 6px 0 6px calc(56px + var(--lane-x, 0px));
  }
  .skills__lane:nth-child(2) { --lane-x: 7%; }
  .skills__lane:nth-child(3) { --lane-x: 2.5%; }
  .skills__lane:nth-child(4) { --lane-x: 11%; }
  .skills__lane::before { /* track hairline */
    content: ""; position: absolute; left: 30px; right: 0; top: 50%; height: 1px;
    background: linear-gradient(90deg, rgba(217, 178, 106, .32), rgba(241, 232, 218, .05) 85%, transparent);
  }
  .skills__lane::after { /* track label: V2 / V1 / A1 / A2 */
    content: attr(data-lane); position: absolute; left: 0; top: 50%; transform: translateY(-50%);
    font-size: var(--fs-nano); font-weight: 500; letter-spacing: var(--track-mid); color: var(--c-ivory-dim);
  }
  .chip { gap: 9px; padding: 10px 18px 10px 14px; font-size: clamp(.82rem, .7rem + .25vw, .95rem); }
  .chip svg { width: 16px; height: 16px; }
}

/* motion: only under html.sr-on (motion allowed) */
@keyframes chip-in {
  0%   { opacity: 0; transform: translate3d(var(--fx, 0px), var(--fy, 24px), 0) scale(.86); }
  55%  { opacity: 1; }
  72%  { transform: translate3d(calc(var(--fx, 0px) * -.08), calc(var(--fy, 24px) * -.08), 0) scale(1.03); }
  100% { opacity: 1; transform: none; }
}
@keyframes chip-lit {
  0%, 30% { opacity: 0; } 42% { opacity: 1; } 100% { opacity: 0; }
}
@keyframes chip-text { 0%, 30% { color: var(--c-ivory); } 42% { color: #F6D88E; } 100% { color: var(--c-ivory); } }
@keyframes chip-pop { 0% { opacity: 0; transform: scale(.55); } 60% { opacity: 1; transform: scale(1.1); } 100% { opacity: 1; transform: none; } }
@keyframes chip-breathe { from { translate: 0 -1.5px; } to { translate: 0 1.5px; } }
.sr-on .skills .chip { opacity: 0; }
.sr-on .skills.is-in .chip {
  opacity: 1;
  animation:
    chip-in 760ms cubic-bezier(.3, 1.35, .5, 1) calc(var(--i) * 150ms) both,
    chip-text 1500ms var(--ease-out) calc(var(--i) * 150ms) both,
    chip-breathe calc(3.6s + var(--i) * .17s) var(--ease-in-out) calc(2.4s + var(--i) * .11s) infinite alternate both;
  animation-play-state: paused;
}
.sr-on .skills.is-in .chip::after { animation: chip-lit 1500ms var(--ease-out) calc(var(--i) * 150ms) both; }
.sr-on .skills.is-in.is-awake .chip { animation-play-state: running; }

/* ---- Selected work ------------------------------------------------------- */
.work { position: relative; z-index: 1; padding-bottom: var(--sx-section-y); scroll-margin-top: 16px; }
.work__head { margin-bottom: clamp(30px, 4.5vw, 64px); }
.work__line {
  margin-top: 16px; max-width: 15ch;
  font-family: var(--font-display); font-weight: 400;
  font-size: var(--sx-fs-intro); line-height: 1.04; letter-spacing: -.015em; color: var(--c-ivory);
}
.work__line em { font-style: italic; }

.cases {
  margin: 0; padding: 0; list-style: none;
  display: grid; grid-template-columns: minmax(0, 1fr);
  gap: clamp(44px, 7vw, 56px) var(--sx-gap);
  justify-items: center;
}
.case-card { width: var(--card-w); display: grid; gap: 12px; align-content: start; }
.case-card--pair { width: 100%; max-width: 560px; }
.case-card__title {
  display: flex; align-items: baseline; gap: 12px;
  font-family: var(--font-display); font-weight: 400;
  font-size: clamp(1.25rem, 1.1rem + .5vw, 1.55rem); line-height: 1.15; letter-spacing: -.005em; color: var(--c-ivory);
}
.case-card__num {
  font-family: var(--font-ui); font-size: var(--fs-micro); font-weight: 500;
  letter-spacing: var(--track-wide); color: var(--c-gold-light);
}
.pair { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }

.case-dots { display: none; }

/* phone: the cases become one horizontal, snapping carousel (8 cards) */
@media (max-width: 599px) {
  .work { padding-bottom: clamp(48px, 12vw, 72px); }
  .work__head { margin-bottom: 22px; }
  .cases {
    --car-w: min(74vw, 35svh, 340px);
    display: flex; gap: 14px; justify-items: initial;
    margin-inline: calc(-1 * var(--pad-x));
    padding: 4px calc((100vw - var(--car-w)) / 2) 6px;
    overflow-x: auto; overscroll-behavior-x: contain;
    scroll-snap-type: x mandatory; scrollbar-width: none;
    -webkit-overflow-scrolling: touch;
  }
  .cases::-webkit-scrollbar { display: none; }
  .case-card--pair, .case-card--pair .pair { display: contents; }
  .case-card--pair > .case-card__title { display: none; }
  .cases > .case-card:not(.case-card--pair), .case-card--pair .vcard {
    flex: 0 0 var(--car-w); width: var(--car-w);
    scroll-snap-align: center; scroll-snap-stop: always;
    display: flex; flex-direction: column; gap: 10px;
  }
  .cases > .case-card:not(.case-card--pair) > .case-card__title { order: 2; font-size: 1.05rem; }
  .vcard__cap { font-size: .66rem; }
  /* no reveal inside the carousel: cards are always there (no black frames) */
  .sr-on .cases [data-sr]:not(.is-in) { opacity: 1; transform: none; }
  .case-dots { display: flex; justify-content: center; gap: 0; margin-top: 12px; }
  .case-dots button {
    width: 22px; height: 22px; padding: 0; border: 0; background: none; cursor: pointer;
    display: grid; place-items: center; -webkit-tap-highlight-color: transparent;
  }
  .case-dots button::before {
    content: ""; width: 6px; height: 6px; border-radius: 50%; background: rgba(241, 232, 218, .25);
    transition: transform var(--dur-xs) var(--ease-out), background-color var(--dur-xs) var(--ease-out);
  }
  .case-dots button[aria-current="true"]::before { background: #D9B26A; transform: scale(1.35); }
  .closing { padding-block: 64px 56px; }
}

/* tablet: two columns */
@media (min-width: 600px) {
  .cases { grid-template-columns: repeat(2, minmax(0, 1fr)); justify-items: stretch; }
  .case-card { width: auto; }
  .case-card--pair { grid-column: 1 / -1; max-width: none; }
  .pair { gap: var(--sx-gap); }
  .case-card--pair .pair { width: 100%; }
}
/* desktop: intro beside its title; cases 01–04 in one row, 05 and 06 (pairs) in the next */
@media (min-width: 1024px) {
  .intro__in { grid-template-columns: minmax(0, 1fr) auto; align-items: center; justify-items: stretch; column-gap: clamp(40px, 6vw, 120px); }
  .vcard--intro { width: calc(min(78vh, 760px) * 9 / 16); }
  .cases { grid-template-columns: repeat(4, minmax(0, 1fr)); row-gap: clamp(56px, 6vw, 88px); }
  .case-card--pair { grid-column: span 2; }
}

/* ---- Lightbox (full video, with sound) ---------------------------------- */
html.lb-open { overflow: hidden; }
.lb {
  position: fixed; inset: 0; z-index: 50;
  width: 100vw; height: 100vh; height: 100dvh; max-width: none; max-height: none;
  margin: 0; padding: 0; border: 0;
  background: rgba(10, 8, 6, .97); color: var(--c-ivory);
  overscroll-behavior: contain;
}
.lb:not([open]) { display: none; }
.lb::backdrop { background: rgba(10, 8, 6, .9); }
.lb[open] { animation: lb-in .28s var(--ease-out) both; }
@keyframes lb-in { from { opacity: 0; } to { opacity: 1; } }
/* the whole frame is visible: object-fit contain, never cropped (captions burned into the video stay whole) */
.lb__frame {
  position: absolute; inset: 0;
  display: flex; align-items: center; justify-content: center; overflow: hidden;
  padding: calc(64px + env(safe-area-inset-top, 0px)) 0 env(safe-area-inset-bottom, 0px);
}
.lb__video {
  display: block; width: 100%; height: 100%; max-width: 100%; max-height: 100%; min-height: 0;
  object-fit: contain; object-position: center; background: #000;
}
.lb__title {
  position: absolute; z-index: 2; left: 18px; right: 80px;
  top: calc(24px + env(safe-area-inset-top, 0px));
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis; color: var(--c-ivory-muted);
}
.lb__close {
  position: absolute; z-index: 3; right: 12px; top: calc(8px + env(safe-area-inset-top, 0px));
  width: 48px; height: 48px; display: grid; place-items: center;
  border-radius: 50%; border: 1px solid rgba(241, 232, 218, .4);
  background: rgba(36, 29, 23, .85); color: var(--c-ivory); cursor: pointer;
  -webkit-tap-highlight-color: transparent;
}
.lb__close svg { width: 20px; height: 20px; fill: none; stroke: currentColor; stroke-width: 1.6; stroke-linecap: round; }
.lb__close:hover { border-color: var(--c-gold-light); }
@media (min-width: 861px) {
  .lb__frame { padding: 4vh 0; }
  .lb__video { width: auto; height: 100%; aspect-ratio: 9 / 16; border-radius: 10px; }
  .lb__close { right: 24px; top: 20px; }
  .lb__title { left: 28px; top: 34px; }
}

/* ---- Closing line + footer ------------------------------------------- */
.closing { position: relative; z-index: 1; padding-block: clamp(90px, 13vw, 200px) clamp(80px, 11vw, 160px); border-top: 1px solid var(--c-line-soft); }
.closing__line {
  max-width: 13ch;
  font-family: var(--font-display); font-weight: 400;
  font-size: clamp(2.5rem, 1.2rem + 4.4vw, 5.5rem); line-height: 1.02; letter-spacing: -.018em; color: var(--c-ivory);
}
.closing__line em { font-style: italic; }
.closing__dot { color: var(--c-gold); }
.site-footer { position: relative; z-index: 1; border-top: 1px solid var(--c-line-soft); }
.site-footer__in {
  display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 10px 24px;
  padding-block: 30px calc(30px + env(safe-area-inset-bottom, 0px));
}
.site-footer__name { font-size: .75rem; font-weight: 500; letter-spacing: .32em; text-transform: uppercase; color: var(--c-ivory); }

/* =========================================================================
   DESKTOP (>= 900 px) — Hero → Start here (3D wheel + chips) → closing → footer.
   The wheel and the hiding of the case list depend on html.wheel-on
   (js/sections.js): without JS the previous layout stays usable.
   Phone (<= 599 px) and tablet (600–899 px) keep their own layout untouched.
   ========================================================================= */
.site-nav__link--d, .intro__story, .wheel, .closing__cta, .closing__glow { display: none; }

@media (min-width: 900px) {
  .site-nav__link--m { display: none; }
  .site-nav__link--d { display: inline-block; }
  .intro__kicker { display: none; }

  .wheel-on .work, .wheel-on .vcard--intro { display: none; }

  /* ---- Start here: title top-left, wheel centre-left, story + chips right ---- */
  .wheel-on .intro { padding-block: clamp(28px, 5vh, 64px) clamp(36px, 6vh, 72px); scroll-margin-top: 0; }
  .wheel-on .intro__in {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(0, 38%);
    grid-template-rows: auto minmax(0, 1fr) minmax(0, 1fr);
    grid-template-areas: "title ." "wheel story" "wheel skills";
    column-gap: clamp(24px, 3vw, 64px); row-gap: 0;
    align-items: stretch; justify-items: stretch;
  }
  .wheel-on .intro__side { display: contents; }
  .wheel-on .intro__copy { grid-area: title; align-self: end; }
  .wheel-on .intro__line { margin-top: 0; }
  .wheel-on .intro__story {
    display: block; grid-area: story; align-self: end; max-width: 13ch;
    font-family: var(--font-display); font-weight: 400;
    font-size: clamp(1.7rem, .8rem + 1.9vw, 3.1rem); line-height: 1.08; letter-spacing: -.012em; color: var(--c-ivory);
  }
  .intro__story em, .closing__line .cw--gold {
    font-style: italic;
    background: linear-gradient(90deg, #D9B26A, #F0C75E);
    -webkit-background-clip: text; background-clip: text;
    -webkit-text-fill-color: transparent; color: transparent;
    padding: 0 .12em .12em; margin: 0 -.12em;
  }
  .wheel-on .skills { grid-area: skills; align-self: start; margin-top: clamp(22px, 3.6vh, 40px); }
  .wheel-on .wheel { display: block; grid-area: wheel; align-self: center; position: relative; }

  /* chips: smaller, on the right */
  .wheel-on .skills__list { gap: 7px 6px; }
  .wheel-on .chip { gap: 6px; padding: 6px 11px 6px 9px; font-size: clamp(.66rem, .52rem + .22vw, .73rem); }
  .wheel-on .chip svg { width: 12px; height: 12px; }
}
@media (min-width: 1024px) {
  .wheel-on .skills__list { display: grid; gap: clamp(8px, 1.5vh, 14px); }
  .wheel-on .skills__lane { gap: 5px; padding: 3px 0 3px calc(34px + var(--lane-x, 0px)); }
  .wheel-on .skills__lane:nth-child(1) { --lane-x: 12px; }
  .wheel-on .skills__lane:nth-child(2) { --lane-x: 0px; }
  .wheel-on .skills__lane:nth-child(3) { --lane-x: 22px; }
  .wheel-on .skills__lane:nth-child(4) { --lane-x: 0px; }
  .wheel-on .skills__lane::before { left: 22px; }
  .wheel-on .chip { padding: 5px 9px 5px 8px; gap: 5px; }
}
@media (min-width: 1280px) { .wheel-on .skills__lane { flex-wrap: nowrap; } }

/* ---- The wheel ------------------------------------------------------------ */
@media (min-width: 900px) {
  .wheel__stage {
    position: relative; margin: 0; padding: 0; list-style: none;
    height: var(--stage-h, clamp(420px, calc(100vh - 290px), 780px));
    perspective: var(--persp, 1700px); perspective-origin: 50% 46%;
    touch-action: pan-y; user-select: none; -webkit-user-select: none;
    cursor: grab;
  }
  .wheel.is-dragging .wheel__stage { cursor: grabbing; }
  .wheel__stage::after { /* soft floor shadow under the front card */
    content: ""; position: absolute; z-index: 0; left: 50%; bottom: -18px;
    width: calc(var(--cw, 300px) * 2.6); height: 60px; margin-left: calc(var(--cw, 300px) * -1.3);
    background: radial-gradient(50% 50% at 50% 50%, rgba(8, 6, 4, .55), transparent 70%);
    pointer-events: none;
  }
  .wcard {
    position: absolute; left: 50%; top: 0;
    width: var(--cw, 300px); margin-left: calc(var(--cw, 300px) / -2);
    display: grid; grid-template-rows: 48px auto; row-gap: 12px;
    transform-origin: 50% 55%; will-change: transform;
    backface-visibility: hidden; -webkit-backface-visibility: hidden;
  }
  .wcard__title { margin: 0; display: grid; align-content: end; justify-items: center; gap: 3px; text-align: center; white-space: nowrap; }
  .wcard__num { font-size: var(--fs-nano); font-weight: 500; letter-spacing: var(--track-mid); text-transform: uppercase; color: var(--c-gold-light); }
  .wcard__name { font-family: var(--font-display); font-size: clamp(1.05rem, .7rem + .6vw, 1.45rem); line-height: 1.1; color: var(--c-ivory); }
  .wcard__media {
    position: relative; display: block; width: 100%; aspect-ratio: 9 / 16;
    padding: 0; margin: 0; border: 1px solid var(--c-line); border-radius: 14px;
    overflow: hidden; background: var(--c-bg-deep); cursor: pointer; color: inherit;
    -webkit-tap-highlight-color: transparent;
    box-shadow: 0 46px 80px -44px rgba(0, 0, 0, .95), 0 18px 34px -26px rgba(0, 0, 0, .7);
    transition: border-color .4s var(--ease-out), box-shadow .6s var(--ease-out);
  }
  .wcard.is-front .wcard__media {
    border-color: rgba(217, 178, 106, .55);
    box-shadow: 0 0 0 1px rgba(240, 199, 94, .1), 0 56px 90px -44px rgba(0, 0, 0, .95), 0 0 70px -24px rgba(217, 178, 106, .35);
  }
  .wcard__media:focus-visible { outline: 1px solid #F0C75E; outline-offset: 5px; }
  .wcard__loop { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; pointer-events: none; background: var(--c-bg-deep); }
  .wcard__media::after { /* vignette so PLAY reads on any frame */
    content: ""; position: absolute; inset: 0; pointer-events: none;
    background: radial-gradient(70% 45% at 50% 50%, rgba(14, 11, 8, .3), transparent 75%),
                linear-gradient(180deg, rgba(14, 11, 8, .25), transparent 22%, transparent 78%, rgba(14, 11, 8, .35));
  }
  .wcard__shade { position: absolute; z-index: 3; inset: 0; background: #0E0B08; opacity: 0; pointer-events: none; }
  .wcard__play {
    position: absolute; z-index: 2; left: 50%; top: 50%;
    display: inline-flex; align-items: center; gap: 12px;
    height: 62px; padding: 0 28px 0 23px; border-radius: 999px;
    background: rgba(20, 16, 12, .6); border: 1px solid rgba(217, 178, 106, .85);
    box-shadow: 0 0 0 1px rgba(156, 123, 60, .3), 0 14px 34px rgba(0, 0, 0, .4);
    color: var(--c-ivory); font-family: var(--font-ui); font-size: .8rem; font-weight: 500; line-height: 1;
    letter-spacing: var(--track-wide); text-transform: uppercase; white-space: nowrap;
    opacity: 0; transform: translate(-50%, -50%) scale(.86);
    transition: opacity .45s var(--ease-out), transform .45s var(--ease-out), background-color .22s var(--ease-out);
  }
  .wcard__play svg { width: 22px; height: 22px; fill: #F0C75E; }
  .wcard__play::before { /* slow ring pulse: "press me" */
    content: ""; position: absolute; inset: -1px; border-radius: inherit; pointer-events: none;
    border: 1px solid rgba(240, 199, 94, .7); opacity: 0;
  }
  .wcard.is-front .wcard__play { opacity: 1; transform: translate(-50%, -50%) scale(1); }
  .wcard.is-front .wcard__media:hover .wcard__play,
  .wcard.is-front .wcard__media:focus-visible .wcard__play { transform: translate(-50%, -50%) scale(1.06); background: rgba(156, 123, 60, .78); }
  .wcard.is-front .wcard__media:active .wcard__play { transform: translate(-50%, -50%) scale(.97); }
  .motion .wcard.is-front .wcard__play::before { animation: play-ring 2.6s var(--ease-out) 1s infinite; }
  .wcard .snd-hint { display: inline-flex; top: calc(50% + 46px); opacity: 0; transition: opacity .45s var(--ease-out); }
  .wcard.is-front .snd-hint { opacity: 1; }
  html.lb-open .wcard .snd-hint { opacity: 0; }
  @keyframes play-ring { 0% { opacity: .8; transform: scale(1); } 70%, 100% { opacity: 0; transform: scale(1.28, 1.5); } }

  .wheel__nav { position: relative; z-index: 5; display: flex; align-items: center; justify-content: center; gap: 18px; margin-top: 22px; }
  .wheel__btn {
    width: 42px; height: 42px; padding: 0; display: grid; place-items: center; border-radius: 50%;
    border: 1px solid rgba(217, 178, 106, .42); background: rgba(36, 29, 23, .6); color: var(--c-ivory); cursor: pointer;
    transition: border-color var(--dur-xs) var(--ease-out), background-color var(--dur-xs) var(--ease-out), transform var(--dur-xs) var(--ease-out);
  }
  .wheel__btn svg { width: 18px; height: 18px; fill: none; stroke: currentColor; stroke-width: 1.6; stroke-linecap: round; stroke-linejoin: round; }
  .wheel__btn:hover, .wheel__btn:focus-visible { border-color: #F0C75E; background: rgba(156, 123, 60, .35); }
  .wheel__btn:active { transform: scale(.94); }
  .wheel__count { min-width: 24ch; display: flex; align-items: center; justify-content: center; gap: 10px; color: var(--c-ivory-muted); }
  .wheel__count i { width: 22px; height: 1px; background: var(--c-gold); }
  .wheel__count [data-wheel-now] { color: var(--c-gold-light); }
}
.wheel__dots { display: none; }

/* =========================================================================
   PHONE + TABLET (< 900 px) — one vertical 3D wheel with every video.
   Depends on html.wheel-on (js/sections.js): without JS the previous layout
   (intro video + case carousel) stays. Order: title → chips (one scrolling
   row) → wheel (~74 svh) → "From raw footage…" → closing.
   The wheel takes a vertical swipe only when it can move in that direction;
   at the first / last card the gesture is left to the page (touch-action:
   pan-y + a per-gesture decision in JS, no permanent preventDefault).
   ========================================================================= */
@media (max-width: 899.98px) {
  .wheel-on .work, .wheel-on .vcard--intro { display: none; }
  .wheel-on .intro { padding-block: clamp(26px, 5svh, 48px) clamp(26px, 5svh, 44px); scroll-margin-top: 0; }
  .wheel-on .intro__in { display: grid; grid-template-columns: minmax(0, 1fr); gap: 0; justify-items: stretch; }
  .wheel-on .intro__side { display: contents; }
  .wheel-on .intro__copy { order: 1; }
  .wheel-on .intro__line { margin-top: 0; font-size: clamp(1.9rem, 1.2rem + 3vw, 2.6rem); }
  .wheel-on .skills { order: 2; margin: 10px 0 0; }
  .wheel-on .wheel { order: 3; display: block; position: relative; margin-top: 2px; }
  .wheel-on .intro__story {
    order: 4; display: block; margin-top: clamp(14px, 3svh, 26px); max-width: 15ch;
    font-family: var(--font-display); font-weight: 400;
    font-size: clamp(1.75rem, 1.1rem + 3.2vw, 2.6rem); line-height: 1.06; letter-spacing: -.012em; color: var(--c-ivory);
  }
  .wheel-on .intro__story em {
    font-style: italic;
    background: linear-gradient(90deg, #D9B26A, #F0C75E);
    -webkit-background-clip: text; background-clip: text;
    -webkit-text-fill-color: transparent; color: transparent;
    padding: 0 .12em .12em; margin: 0 -.12em;
  }

  /* chips: all 14 visible, small, on compact wrapped rows (no sideways scroll).
     Entrance (motion only): the first three are there at once, the others pop in
     one after another and light up gold for an instant, like markers being hit. */
  .wheel-on .skills__list { flex-wrap: wrap; gap: 4px 4px; }
  .wheel-on .chip { flex: none; gap: 4px; padding: 2px 7px 2px 5px; font-size: .75rem; line-height: 1.2; }
  .wheel-on .chip svg { width: 11px; height: 11px; }
  .sr-on.wheel-on .skills.is-in .chip {
    animation:
      chip-pop 420ms cubic-bezier(.3, 1.5, .5, 1) calc(max(0, var(--i) - 2) * 130ms) both,
      chip-text 900ms var(--ease-out) calc(max(0, var(--i) - 2) * 130ms) both,
      chip-breathe calc(3.6s + var(--i) * .17s) var(--ease-in-out) calc(2.4s + var(--i) * .11s) infinite alternate both;
    animation-play-state: paused;
  }
  .sr-on.wheel-on .skills.is-in .chip::after { animation: chip-lit 900ms var(--ease-out) calc(max(0, var(--i) - 2) * 130ms) both; }
  .sr-on.wheel-on .skills.is-in.is-awake .chip { animation-play-state: running; }
  .sr-on.wheel-on .skills.is-in .skills__lane:first-child .chip { animation-duration: 1ms, 900ms, calc(3.6s + var(--i) * .17s); }

  /* the wheel */
  .wheel__stage {
    position: relative; margin: 0; padding: 0; list-style: none;
    height: 80vh; height: 80svh; min-height: 400px;                /* exact height set by js */
    perspective: var(--persp, 1100px); perspective-origin: 50% 50%;
    touch-action: pan-y; user-select: none; -webkit-user-select: none;
    overflow: hidden;
    -webkit-mask-image: linear-gradient(180deg, transparent 0, #000 14px, #000 calc(100% - 14px), transparent);
            mask-image: linear-gradient(180deg, transparent 0, #000 14px, #000 calc(100% - 14px), transparent);
  }
  .wcard {
    position: absolute; left: 50%; top: 50%;
    width: var(--cw, 220px); margin-left: calc(var(--cw, 220px) / -2);
    margin-top: calc(var(--ch, 440px) / -2);
    display: grid; grid-template-rows: 34px auto; row-gap: 6px;
    transform-origin: 50% 50%; will-change: transform;
    backface-visibility: hidden; -webkit-backface-visibility: hidden;
  }
  .wcard__title { margin: 0; display: grid; align-content: end; justify-items: center; gap: 2px; text-align: center; white-space: nowrap; }
  .wcard__num { font-size: var(--fs-nano); font-weight: 500; letter-spacing: var(--track-mid); text-transform: uppercase; color: var(--c-gold-light); }
  .wcard__name { font-family: var(--font-display); font-size: 1rem; line-height: 1.1; color: var(--c-ivory); }
  .wcard__media {
    position: relative; display: block; width: 100%; aspect-ratio: 9 / 16;
    padding: 0; margin: 0; border: 1px solid var(--c-line); border-radius: 14px;
    overflow: hidden; background: var(--c-bg-deep); cursor: pointer; color: inherit;
    -webkit-tap-highlight-color: transparent;
    box-shadow: 0 30px 60px -34px rgba(0, 0, 0, .95);
    transition: border-color .4s var(--ease-out);
  }
  .wcard.is-front .wcard__media { border-color: rgba(217, 178, 106, .55); box-shadow: 0 0 0 1px rgba(240, 199, 94, .1), 0 36px 70px -34px rgba(0, 0, 0, .95), 0 0 50px -22px rgba(217, 178, 106, .35); }
  .wcard__media:focus-visible { outline: 1px solid #F0C75E; outline-offset: 4px; }
  .wcard__loop { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; pointer-events: none; background: var(--c-bg-deep); }
  .wcard__media::after {
    content: ""; position: absolute; inset: 0; pointer-events: none;
    background: radial-gradient(70% 45% at 50% 50%, rgba(14, 11, 8, .3), transparent 75%),
                linear-gradient(180deg, rgba(14, 11, 8, .25), transparent 22%, transparent 78%, rgba(14, 11, 8, .35));
  }
  .wcard__shade { position: absolute; z-index: 3; inset: 0; background: #0E0B08; opacity: 0; pointer-events: none; }
  .wcard__play {
    position: absolute; z-index: 2; left: 50%; top: 50%;
    display: inline-flex; align-items: center; gap: 10px;
    height: 44px; padding: 0 18px 0 15px; border-radius: 999px;
    background: rgba(20, 16, 12, .6); border: 1px solid rgba(217, 178, 106, .85);
    box-shadow: 0 0 0 1px rgba(156, 123, 60, .3), 0 12px 30px rgba(0, 0, 0, .4);
    color: var(--c-ivory); font-family: var(--font-ui); font-size: .68rem; font-weight: 500; line-height: 1;
    letter-spacing: var(--track-wide); text-transform: uppercase; white-space: nowrap;
    opacity: 0; transform: translate(-50%, -50%) scale(.86);
    transition: opacity .4s var(--ease-out), transform .4s var(--ease-out);
  }
  .wcard__play svg { width: 17px; height: 17px; fill: #F0C75E; }
  .wcard.is-front .wcard__play { opacity: 1; transform: translate(-50%, -50%) scale(1); }
  .wcard.is-front .wcard__media:active .wcard__play { transform: translate(-50%, -50%) scale(.96); }
  .wcard .snd-hint { display: inline-flex; top: calc(50% + 32px); font-size: .56rem; opacity: 0; transition: opacity .4s var(--ease-out); }
  .wcard.is-front .snd-hint { opacity: 1; }
  html.lb-open .wcard .snd-hint { opacity: 0; }

  /* side indicator: small up/down arrows with one dot per video between them */
  .wheel__nav {
    position: absolute; z-index: 120; right: max(2px, calc(var(--pad-x) - 16px)); top: 50%; transform: translateY(-50%);
    display: flex; flex-direction: column; align-items: center; gap: 4px;
  }
  .wheel__count { display: none; }
  .wheel__btn {
    width: 36px; height: 36px; padding: 0; display: grid; place-items: center; border-radius: 50%;
    border: 1px solid rgba(217, 178, 106, .42); background: rgba(36, 29, 23, .6); color: var(--c-ivory); cursor: pointer;
    -webkit-tap-highlight-color: transparent;
    transition: opacity var(--dur-xs) var(--ease-out), border-color var(--dur-xs) var(--ease-out);
  }
  .wheel__btn svg { width: 15px; height: 15px; fill: none; stroke: currentColor; stroke-width: 1.6; stroke-linecap: round; stroke-linejoin: round; transform: rotate(90deg); }
  .wheel__btn:active { border-color: #F0C75E; }
  .wheel__btn:disabled { opacity: .3; cursor: default; }
  .wheel__dots { display: flex; flex-direction: column; align-items: center; margin: 2px 0; }
  .wheel__dots button {
    width: 22px; height: 15px; padding: 0; border: 0; background: none; cursor: pointer;
    display: grid; place-items: center; -webkit-tap-highlight-color: transparent;
  }
  .wheel__dots button::before {
    content: ""; width: 5px; height: 5px; border-radius: 50%; background: rgba(241, 232, 218, .28);
    transition: transform var(--dur-xs) var(--ease-out), background-color var(--dur-xs) var(--ease-out);
  }
  .wheel__dots button[aria-current="true"]::before { background: #D9B26A; transform: scale(1.5); }
}
@media (max-width: 899.98px) and (prefers-reduced-motion: reduce) {
  .wcard__play, .wcard__media, .wcard .snd-hint, .wheel__dots button::before { transition: none; }
}

/* ---- Closing: words enter one by one, gold "edit", call to action ------------ */
@media (min-width: 900px) {
  .closing { overflow: clip; padding-block: clamp(96px, 15vh, 180px) clamp(84px, 12vh, 150px); }
  .closing__glow {
    display: block; position: absolute; z-index: -1; left: 58%; top: 50%;
    width: min(70vw, 1100px); aspect-ratio: 1; transform: translate(-50%, -50%);
    border-radius: 50%; pointer-events: none;
    background: radial-gradient(closest-side, rgba(156, 123, 60, .16), rgba(156, 123, 60, .05) 55%, transparent);
  }
  .closing__in { position: relative; display: grid; justify-items: start; gap: clamp(30px, 5vh, 52px); }
  .closing__line .cw { display: inline-block; }
  .closing__line .cw--gold { position: relative; }
  .closing__line .cw--gold::after { /* gold underline drawn under "edit" */
    content: ""; position: absolute; left: .12em; right: .1em; bottom: .02em; height: 2px;
    background: linear-gradient(90deg, #D9B26A, #F0C75E); transform-origin: left; border-radius: 2px;
  }
  .closing__cta { display: flex; flex-wrap: wrap; gap: 14px; }
  .cta {
    position: relative; overflow: hidden;
    display: inline-flex; align-items: center; gap: 12px; height: 54px; padding: 0 28px;
    border-radius: 999px; border: 1px solid transparent; cursor: pointer;
    font-family: var(--font-ui); font-size: .78rem; font-weight: 500; line-height: 1;
    letter-spacing: var(--track-wide); text-transform: uppercase;
    transition: transform var(--dur-xs) var(--ease-out), box-shadow .3s var(--ease-out), border-color var(--dur-xs) var(--ease-out), background-color var(--dur-xs) var(--ease-out);
  }
  .cta svg { flex: none; width: 18px; height: 18px; }
  .cta--primary { color: #1A1511; background: linear-gradient(135deg, #D9B26A, #F0C75E); box-shadow: 0 18px 40px -18px rgba(217, 178, 106, .6); }
  .cta--primary svg { fill: currentColor; }
  .cta--primary::after { /* a playhead-like gloss crossing the button */
    content: ""; position: absolute; top: 0; bottom: 0; left: -40%; width: 30%;
    background: linear-gradient(100deg, transparent, rgba(255, 246, 220, .55), transparent);
    transform: translate3d(-60%, 0, 0) skewX(-12deg); pointer-events: none;
  }
  .motion .cta--primary::after { animation: cta-gloss 5.5s var(--ease-in-out) 2s infinite; }
  @keyframes cta-gloss { 0% { transform: translate3d(-60%, 0, 0) skewX(-12deg); } 30%, 100% { transform: translate3d(560%, 0, 0) skewX(-12deg); } }
  .cta--primary:hover, .cta--primary:focus-visible { transform: translateY(-2px); box-shadow: 0 26px 50px -18px rgba(240, 199, 94, .7); }
  .cta--ghost { color: var(--c-ivory); border-color: rgba(241, 232, 218, .28); background: rgba(36, 29, 23, .35); }
  .cta--ghost svg { fill: none; stroke: currentColor; stroke-width: 1.6; stroke-linecap: round; stroke-linejoin: round; }
  .cta--ghost:hover, .cta--ghost:focus-visible { border-color: var(--c-gold-light); transform: translateY(-2px); }
  .cta:active { transform: scale(.98); }

  /* entrance: the block stays, words rise one after another, then line + buttons */
  .sr-on .closing__in[data-sr], .sr-on .closing__in[data-sr]:not(.is-in) { opacity: 1; transform: none; }
  .sr-on .closing__line .cw { transition: opacity .8s var(--ease-out), transform .95s var(--ease-out); transition-delay: calc(var(--i) * 90ms); }
  .sr-on .closing__in:not(.is-in) .cw { opacity: 0; transform: translate3d(0, .5em, 0); }
  .sr-on .closing__line .cw--gold::after { transform: scaleX(0); transition: transform .9s var(--ease-out) .8s; }
  .sr-on .closing__in.is-in .cw--gold::after { transform: scaleX(1); }
  .sr-on .closing__cta { transition: opacity .8s var(--ease-out) .75s, transform .8s var(--ease-out) .75s; }
  .sr-on .closing__in:not(.is-in) .closing__cta { opacity: 0; transform: translate3d(0, 14px, 0); }
}

/* light parallax (scroll-driven, no JS), desktop + motion only */
@supports (animation-timeline: view()) {
  @media (min-width: 900px) and (prefers-reduced-motion: no-preference) {
    @keyframes par-a { from { translate: 0 34px; } to { translate: 0 -34px; } }
    @keyframes par-b { from { translate: 0 18px; } to { translate: 0 -18px; } }
    @keyframes par-glow { from { translate: 0 -90px; } to { translate: 0 90px; } }
    .motion.wheel-on .intro__story { animation: par-a linear both; animation-timeline: view(); }
    .motion.wheel-on .skills { animation: par-b linear both; animation-timeline: view(); }
    .motion .closing__glow { animation: par-glow linear both; animation-timeline: view(); }
  }
}

/* =========================================================================
   REVEAL — only under html.sr-on (set by js/sections.js); never on
   reduced motion or ?static=1. Without JS everything stays visible.
   ========================================================================= */
.sr-on [data-sr] { transition: opacity var(--dur-sm) var(--ease-out), transform var(--dur-sm) var(--ease-out); transition-delay: var(--sr-d, 0ms); }
.sr-on [data-sr]:not(.is-in) { opacity: 0; transform: translate3d(0, var(--rise-sm), 0); }

@media (prefers-reduced-motion: reduce) {
  .sr-on [data-sr], .sr-on [data-sr]:not(.is-in) { opacity: 1; transform: none; transition: none; }
  .lb[open] { animation: none; }
  .vcard__play, .vcard__media { transition: none; }
  .sr-on .closing__line .cw, .sr-on .closing__cta, .sr-on .closing__line .cw--gold::after { transition: none; opacity: 1; transform: none; }
  .wcard__play, .wcard__media, .cta { transition: none; }
}

/* =========================================================================
   ITALIAN PAGE — contacts in the closing and footer, on every screen size
   ========================================================================= */
.site-nav__link { display: inline-block; }
.work__line em {
  font-style: italic;
  background: linear-gradient(90deg, #D9B26A, #F0C75E);
  -webkit-background-clip: text; background-clip: text;
  -webkit-text-fill-color: transparent; color: transparent;
  padding: 0 .12em .12em; margin: 0 -.12em;
}
.closing__in { display: grid; justify-items: start; gap: 30px; }
.closing__cta--contact { display: flex; flex-wrap: wrap; gap: 12px; }
.closing__cta--contact .cta {
  position: relative; overflow: hidden;
  display: inline-flex; align-items: center; justify-content: center; gap: 10px;
  height: 54px; min-width: 150px; padding: 0 26px;
  border-radius: 999px; border: 1px solid transparent; cursor: pointer;
  font-family: var(--font-ui); font-size: .8rem; font-weight: 500; line-height: 1;
  letter-spacing: var(--track-wide); text-transform: uppercase; text-decoration: none;
  transition: transform var(--dur-xs) var(--ease-out), box-shadow .3s var(--ease-out), border-color var(--dur-xs) var(--ease-out), background-color var(--dur-xs) var(--ease-out);
}
.closing__cta--contact .cta--primary { color: #1A1511; background: linear-gradient(135deg, #D9B26A, #F0C75E); box-shadow: 0 18px 40px -18px rgba(217, 178, 106, .6); }
.closing__cta--contact .cta--ghost { color: var(--c-ivory); border-color: rgba(217, 178, 106, .7); background: rgba(36, 29, 23, .55); }
.closing__cta--contact .cta__ico { flex: none; width: 19px; height: 19px; fill: none; stroke: currentColor; stroke-width: 1.6; stroke-linecap: round; stroke-linejoin: round; }
.closing__cta--contact .cta--primary .cta__ico path + path { fill: currentColor; stroke: none; }
.closing__cta--contact .cta:hover, .closing__cta--contact .cta:focus-visible { transform: translateY(-2px); }
.closing__cta--contact .cta--ghost:hover, .closing__cta--contact .cta--ghost:focus-visible { border-color: #F0C75E; }
@media (max-width: 599px) {
  .closing__cta--contact { width: 100%; }
  .closing__cta--contact .cta { flex: 1 1 0; min-width: 0; padding: 0 18px; }
}
.site-footer__in { flex-direction: column; align-items: flex-start; justify-content: flex-start; gap: 14px; }
.site-footer__contacts { margin: 0; padding: 0; list-style: none; display: grid; gap: 8px; }
.site-footer__contacts li { display: flex; align-items: baseline; gap: 12px; flex-wrap: wrap; }
.site-footer__contacts .label { min-width: 74px; color: var(--c-ivory-dim); }
.site-footer__contacts a { color: var(--c-ivory); font-size: .9rem; letter-spacing: .02em; text-decoration: none; border-bottom: 1px solid rgba(217, 178, 106, .45); padding-bottom: 1px; }
.site-footer__contacts a:hover, .site-footer__contacts a:focus-visible { color: #F0C75E; border-bottom-color: #F0C75E; }