/* /services (v3) — "Which job is yours?" (docs/DESIGN-V3.md §8.2). Loaded after assets/css/v3/base.css; this page's layout
   and its motion signature only (§6.5): the 3D service index (a four-faced prism, CENTRED, turns 90° per service across one
   sticky run; the four service names in a row under it light the current one with a filled ring numeral) and the written quote
   (a folded sheet slides up and opens in thirds).
   Default rules = the designed STATIC layout (no-js, ?noanim=1, reduced motion, a late motion script, and every phone): the
   numbered list with its "When …" lines (desktop: the four photos beside it as a small set; phones and tablets: a thumbnail in
   each row) and the open sheet. Motion start states and the 3D layout apply only under html.a-motion from 768 px up. */

/* ------------------------------------------------------------------ 1 hero (a still: the photo settles, then drifts as it leaves) */
.s-hero .a-phero__media { will-change: transform; }
.s-hero .a-phero__media img { object-position: 38% 50%; }
.s-hero .a-label { margin-bottom: clamp(16px, 2.4vh, 24px); }
.s-hero .a-h1 { max-width: none; }
.s-hero__foot { position: absolute; left: 0; right: 0; bottom: clamp(52px, 9vh, 104px); z-index: 2; display: flex; justify-content: flex-end; align-items: center; pointer-events: none; }
.s-hero__tag { display: flex; align-items: center; gap: 10px; min-height: 44px; font: 500 12px/1 var(--mono); letter-spacing: .12em; text-transform: uppercase; color: rgba(255, 255, 255, .9); white-space: nowrap; text-shadow: 0 1px 10px rgba(0, 0, 0, .55); }
.s-hero__tag i { width: 7px; height: 7px; border-radius: 50%; background: var(--gold-2); box-shadow: 0 0 0 4px rgba(232, 190, 87, .18); }
.a-motion .s-hero .a-label { animation: aUp .7s .12s var(--ease) both; }
.a-motion .s-hero__foot > * { animation: aUp .9s .42s var(--ease) both; }
@media (max-width: 1024px) and (max-aspect-ratio: 4/5) { .s-hero .a-phero__media img { object-position: 50% 50%; } }
@media (max-width: 767px) {
  .s-hero__foot { top: calc(var(--head-h) + 36px); bottom: auto; }
  .s-hero__tag { font-size: 12px; letter-spacing: .08em; }
  .s-hero .a-label { letter-spacing: .08em; gap: 10px; }
  .s-hero .a-label::before { width: 20px; }
}

/* ------------------------------------------------------------------ 2 the four services, STATIC: the numbered list (+ the photo set on desktop) */
.s-idx { background: var(--ink); color: var(--on-dark); }
.s-idx__stage { padding: var(--sec) 0; }
.s-idx__grid { display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); column-gap: var(--gap); align-items: start; }
.s-idx__head { grid-column: 1 / span 6; grid-row: 1; margin-bottom: 0; }
.s-idx__list { grid-column: 1 / span 6; grid-row: 2; margin-top: var(--head-gap); display: grid; gap: 6px; }
.s-idx__foot { grid-column: 1 / span 6; grid-row: 3; margin-top: clamp(28px, 3vw, 44px); display: grid; justify-items: start; gap: 10px; }
.s-idx__view { grid-column: 8 / span 5; grid-row: 1 / span 3; align-self: center; }
.s-idx__mixed { font-size: var(--fs-lead); line-height: 1.5; color: var(--on-dark-2); max-width: 40ch; text-wrap: balance; }
.s-idx__mixed b { font-weight: 600; color: var(--on-dark); }
/* the faces: photos + a type chip only (the names live in the list) */
.s-prism { display: grid; grid-template-columns: 1fr 1fr; gap: var(--gap); }
.s-face { position: relative; display: block; aspect-ratio: 4 / 5; overflow: hidden; border-radius: var(--r); background: var(--ink-3); color: #fff; isolation: isolate; }
.s-face__img { position: absolute; inset: 0; display: block; transition: transform 1.1s var(--ease); }
.s-face__img img { width: 100%; height: 100%; object-fit: cover; object-position: var(--pos, 50% 50%); }
.s-face::before { content: ''; position: absolute; inset: 0; z-index: 1; pointer-events: none; background: linear-gradient(180deg, rgba(8, 10, 12, .42) 0%, rgba(8, 10, 12, 0) 34%); }
.s-face > .a-chip { left: 12px; top: 12px; bottom: auto; z-index: 2; }
.s-face__go { position: absolute; right: 12px; bottom: 12px; z-index: 2; width: 40px; height: 40px; border-radius: 50%; display: grid; place-items: center; background: rgba(9, 11, 14, .38); border: 1px solid rgba(255, 255, 255, .42); transition: background-color .35s, border-color .35s, color .35s, transform .5s var(--ease); }
.s-face__go .icon { width: 16px; height: 16px; }
.s-face:hover .s-face__img { transform: scale(1.05); }
.s-face:hover .s-face__go { background: var(--gold); border-color: var(--gold); color: var(--ink); transform: rotate(-45deg); }
.s-prism-rig { position: relative; }
.s-prism__floor { display: none; }
/* the rows: a ring numeral (this page's numeral: mono in a ring, filled gold when current), the name, the "When …" line */
.s-row { position: relative; display: grid; grid-template-columns: minmax(0, 1fr) 40px; align-items: center; gap: 0 16px; padding: 14px 0; color: var(--on-dark); }
.s-row__img { display: none; }
.s-row__b { display: grid; gap: 6px; min-width: 0; }
.s-row__t { display: flex; align-items: center; gap: 14px; font-size: var(--fs-h3); font-weight: 600; letter-spacing: -.015em; line-height: 1.12; }
.s-row__n { flex: none; width: 34px; height: 34px; border-radius: 50%; display: grid; place-items: center; font: 500 12px/1 var(--mono); letter-spacing: .02em; color: var(--on-dark-2); border: 1px solid rgba(242, 238, 231, .3);
  transition: background-color .45s var(--ease), border-color .45s var(--ease), color .45s var(--ease); }
.s-row__w { font-size: 15px; line-height: 1.4; color: rgba(242, 238, 231, .74); padding-left: 48px; }
.s-row__go { width: 40px; height: 40px; border-radius: 50%; display: grid; place-items: center; border: 1px solid rgba(242, 238, 231, .3); transition: background-color .3s, border-color .3s, color .3s, transform .5s var(--ease); }
.s-row__go .icon { width: 16px; height: 16px; }
.s-row:hover .s-row__go { background: var(--gold); border-color: var(--gold); color: var(--ink); transform: rotate(-45deg); }
.s-row:hover .s-row__n { border-color: var(--gold-2); color: var(--gold-2); }
.s-row:focus-visible { outline-offset: 2px; }
/* tablets and phones, static: title, the list with a thumbnail per row, the mixed-job line (the photo set stays off: the rows carry it) */
@media (max-width: 1023px) {
  .s-idx__grid { display: flex; flex-direction: column; align-items: stretch; }
  .s-idx__view { display: none; }
  .s-idx__head { order: 1; } .s-idx__list { order: 2; } .s-idx__foot { order: 3; }
  .s-idx__list { margin-top: clamp(24px, 4vw, 40px); gap: 4px; }
  .s-row { grid-template-columns: 80px minmax(0, 1fr) 40px; gap: 0 18px; padding: 8px 0; }
  .s-row__img { display: block; position: relative; aspect-ratio: 4 / 5; overflow: hidden; border-radius: var(--r); background: var(--ink-3); }
  .s-row__img img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
  .s-row__w { padding-left: 0; }
}
@media (max-width: 767px) {
  .s-idx__list { gap: 2px; }
  .s-row { grid-template-columns: 64px minmax(0, 1fr) 32px; gap: 0 14px; padding: 7px 0; min-height: 48px; }
  .s-row__n { display: none; }
  .s-row__b { gap: 3px; }
  .s-row__t { font-size: 18px; }
  .s-row__w { font-size: 14px; line-height: 1.35; }
  .s-row__go { width: 32px; height: 32px; }
  .s-row__go .icon { width: 14px; height: 14px; }
  .s-idx__foot { margin-top: 26px; }
  .s-idx__mixed { font-size: 16px; }
  /* phones never run the sticky scene (one sticky run per phone page is plenty, §6.3): the section is its static layout */
  .a-motion .s-idx .a-seq { height: auto; }
  .a-motion .s-idx .a-seq__stage { position: static; height: auto; min-height: 0; overflow: visible; }
}
/* a very short landscape view gets the static layout too (JS adds .is-flat) */
.a-motion .s-idx.is-flat .a-seq { height: auto; }
.a-motion .s-idx.is-flat .a-seq__stage { position: static; height: auto; min-height: 0; overflow: visible; }

/* ------------------------------------------------------------------ 2 the four services, MOTION (768 px up): the prism centred, the names under it */
/* the stage (base .a-seq__stage) sticks for the run; the prism is four 4:5 faces round a square core. --fw / --fh = one face. */
@media (min-width: 768px) {
  .a-motion .s-idx:not(.is-flat) .s-idx__stage { padding: 0; }
  .a-motion .s-idx:not(.is-flat) .s-idx__grid { height: 100%; display: grid; grid-template-columns: minmax(0, 1fr) auto; grid-template-rows: auto minmax(0, 1fr) auto; column-gap: 40px; row-gap: clamp(12px, 2vh, 24px);
    align-items: end; padding-top: calc(var(--head-h) + clamp(10px, 2.4vh, 28px)); padding-bottom: clamp(22px, 4vh, 48px); }
  .a-motion .s-idx:not(.is-flat) .s-idx__head { grid-column: 1; grid-row: 1; }
  .a-motion .s-idx:not(.is-flat) .s-idx__foot { grid-column: 2; grid-row: 1; margin: 0; justify-items: end; text-align: right; gap: 2px; }
  .a-motion .s-idx:not(.is-flat) .s-idx__mixed { font-size: 15px; max-width: 32ch; }
  .a-motion .s-idx:not(.is-flat) .s-idx__view { display: grid; place-items: center; grid-column: 1 / -1; grid-row: 2; align-self: stretch; min-height: 0;
    --fh: clamp(220px, calc(100svh - 440px), 500px); --fw: calc(var(--fh) * .8); }
  @supports (container-type: size) {   /* the prism takes exactly the height the title and the names leave */
    .a-motion .s-idx:not(.is-flat) .s-idx__view { container-type: size; --fh: min(calc(100cqh - 34px), 500px, calc(100cqw * .6)); }
  }
  .a-motion .s-idx:not(.is-flat) .s-idx__list { grid-column: 1 / -1; grid-row: 3; margin: 0; display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 0 var(--gap); }
  .a-motion .s-idx:not(.is-flat) .s-prism-rig { width: var(--fw); height: calc(var(--fw) * 1.25); perspective: 1700px; }
  .a-motion .s-idx:not(.is-flat) .s-prism { display: block; position: relative; width: 100%; height: 100%; transform-style: preserve-3d;
    transform: translate3d(0, var(--y0, 0px), calc(var(--fw) * -.5)) rotateY(var(--ry, 0deg)) scale3d(var(--sc, 1), var(--sc, 1), var(--sc, 1)); }
  .a-motion .s-idx:not(.is-flat) .s-face { position: absolute; inset: 0; aspect-ratio: auto; border-radius: 0; backface-visibility: hidden; -webkit-backface-visibility: hidden; pointer-events: none;
    transform: rotateY(calc(var(--i) * 90deg)) translateZ(calc(var(--fw) * .5)); box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .06); }
  .a-motion .s-idx:not(.is-flat) .s-face.is-front { pointer-events: auto; }
  .a-motion .s-idx:not(.is-flat) .s-face__go { opacity: 0; transform: scale(.7); transition: opacity .4s, transform .5s var(--ease), background-color .35s, border-color .35s, color .35s; }
  .a-motion .s-idx:not(.is-flat) .s-face.is-front .s-face__go { opacity: 1; transform: none; }
  .a-motion .s-idx:not(.is-flat) .s-face.is-front:hover .s-face__go { transform: rotate(-45deg); }
  /* the face turning away darkens; a soft sheen crosses it mid-turn (from --shade / --gl / --sheen, set per frame) */
  .a-motion .s-idx:not(.is-flat) .s-face::after { content: ''; position: absolute; inset: 0; z-index: 3; pointer-events: none;
    background: linear-gradient(100deg, rgba(255, 246, 228, 0) 38%, rgba(255, 246, 228, calc(var(--gl, 0) * .2)) 50%, rgba(255, 246, 228, 0) 62%) calc(var(--sheen, 50) * 1%) 0 / 300% 100% no-repeat,
      rgba(6, 8, 10, calc(var(--shade, 0) * .86)); }
  .a-motion .s-idx:not(.is-flat) .s-prism__floor { display: block; position: absolute; left: -10%; right: -10%; top: calc(100% + 4px); height: 48px; pointer-events: none;
    background: radial-gradient(50% 50% at 50% 50%, rgba(0, 0, 0, .7), rgba(0, 0, 0, 0) 72%); transform: scaleX(var(--fx, 1)); opacity: var(--fo, 1); }
  /* the names under the prism: resting names dimmed (still ≥ 4.5:1), the current one lit, its ring filled gold, its "When …" line shown */
  .a-motion .s-idx:not(.is-flat) .s-row { grid-template-columns: minmax(0, 1fr); align-items: start; padding: 10px 0 0; }
  .a-motion .s-idx:not(.is-flat) .s-row__img, .a-motion .s-idx:not(.is-flat) .s-row__go { display: none; }
  .a-motion .s-idx:not(.is-flat) .s-row__t { font-size: clamp(17px, 1.45vw, 22px); gap: 12px; opacity: .62; transition: opacity .5s var(--ease); }
  .a-motion .s-idx:not(.is-flat) .s-row__n { width: 32px; height: 32px; }
  .a-motion .s-idx:not(.is-flat) .s-row__w { padding-left: 44px; min-height: 2.8em; font-size: 14px; opacity: 0; transform: translateY(6px); transition: opacity .5s var(--ease), transform .6s var(--ease); }
  .a-motion .s-idx:not(.is-flat) .s-row.is-on .s-row__t, .a-motion .s-idx:not(.is-flat) .s-row:hover .s-row__t { opacity: 1; }
  .a-motion .s-idx:not(.is-flat) .s-row.is-on .s-row__w { opacity: 1; transform: none; }
  .a-motion .s-idx:not(.is-flat) .s-row.is-on .s-row__n { background: var(--gold-2); border-color: var(--gold-2); color: var(--ink); }
}
@media (min-width: 768px) and (max-width: 1023px) {
  .a-motion .s-idx:not(.is-flat) .s-idx__list { grid-template-columns: 1fr 1fr; }
  .a-motion .s-idx:not(.is-flat) .s-row__w { min-height: 0; }
  .a-motion .s-idx:not(.is-flat) .s-idx__view { --fh: clamp(220px, calc(100svh - 520px), 460px); }
  @supports (container-type: size) { .a-motion .s-idx:not(.is-flat) .s-idx__view { --fh: min(calc(100cqh - 30px), 460px, calc(100cqw * .6)); } }
}

/* ------------------------------------------------------------------ 3 the written quote: a typographic document (static: open) */
.s-quote { overflow-x: clip; }   /* the tilted sheet's near edge may pass the screen edge by a few px while it rises */
.s-quote__grid { align-items: start; }
.s-quote__text .a-lead { margin-top: 24px; }
.s-quote__turn { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; margin-top: 20px; font-size: 15px; color: var(--muted); }
.s-quote__turn .c-chip { margin: 0; }
@media (min-width: 1024px) { .s-quote__text { position: sticky; top: calc(var(--head-h) + 56px); } }
.s-sheetwrap { position: relative; width: 100%; max-width: 620px; margin: 0 auto; perspective: 2400px; perspective-origin: 50% 0; }
.s-doc { --ph: 252px; position: relative; height: calc(var(--ph) * 3); transform-style: preserve-3d; transform-origin: 50% 0; color: var(--text); }
.s-doc__shadow { position: absolute; inset: 0; border-radius: 2px; box-shadow: 0 50px 90px -46px rgba(40, 30, 10, .42), 0 2px 6px rgba(40, 30, 10, .06); transform-origin: 50% 0; pointer-events: none; }
.s-doc__p { height: var(--ph); }
.s-doc__p--1 { position: relative; }
.s-doc__p--2 { position: absolute; left: 0; right: 0; top: var(--ph); transform-style: preserve-3d; transform-origin: 50% 0; }
.s-doc__p--3 { position: absolute; left: 0; right: 0; top: 100%; transform-style: preserve-3d; transform-origin: 50% 0; }
.s-doc__face, .s-doc__back { position: absolute; inset: 0; background: var(--white); -webkit-backface-visibility: hidden; backface-visibility: hidden; }
.s-doc__face { display: flex; flex-direction: column; gap: 14px; padding: 26px clamp(22px, 3vw, 38px); }
.s-doc__p--1 .s-doc__face { border-radius: 2px 2px 0 0; box-shadow: inset 0 3px 0 var(--gold); }   /* the letterhead edge (printed) */
.s-doc__p--3 .s-doc__face { border-radius: 0 0 2px 2px; }
/* the creases stay on an opened sheet (printed, never drawn) */
.s-doc__p--2 > .s-doc__face, .s-doc__p--3 > .s-doc__face { box-shadow: inset 0 1px 0 rgba(18, 20, 23, .05), inset 0 14px 16px -16px rgba(18, 20, 23, .16); }
.s-doc__back { transform: rotateX(180deg); background: #EEEAE3; }
.s-doc__top { display: flex; justify-content: space-between; align-items: baseline; gap: 16px; }
.s-doc__title { font-size: clamp(21px, 1.7vw, 26px); font-weight: 600; letter-spacing: -.015em; line-height: 1.1; }
.s-doc__tag { font: 500 11px/1 var(--mono); letter-spacing: .14em; text-transform: uppercase; color: var(--gold-ink); padding: 6px 9px; border: 1px solid rgba(122, 90, 16, .35); border-radius: 2px; }
.s-doc__meta { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; margin-top: -4px; }
.s-doc__field { display: flex; align-items: flex-end; gap: 10px; font: 500 11px/1 var(--mono); letter-spacing: .14em; text-transform: uppercase; color: var(--muted-2); }
.s-doc__field::after { content: ''; flex: 1; height: 1px; background: rgba(18, 20, 23, .16); }
.s-doc__sec { display: grid; gap: 9px; }
.s-doc__h { display: flex; align-items: baseline; gap: 12px; font-size: 16px; font-weight: 600; letter-spacing: -.005em; }
.s-doc__h b { font: 500 11px/1 var(--mono); letter-spacing: .12em; color: var(--gold-ink); }
.s-doc__ln { padding-left: 30px; font: 500 12px/1.45 var(--mono); letter-spacing: .01em; color: var(--muted); }   /* one typed example line per heading (never a skeleton bar) */
.s-doc__items { display: grid; grid-template-columns: 1fr 1fr; gap: 9px 20px; padding-left: 30px; font-size: 15px; line-height: 1.3; }
.s-doc__items li { display: flex; align-items: baseline; gap: 10px; }
.s-doc__items li::before { content: ''; flex: none; width: 5px; height: 5px; transform: translateY(-2px); background: var(--gold); }
.s-doc__sign { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; margin-top: auto; }
@media (max-width: 1023px) { .s-sheetwrap { max-width: 600px; } }
@media (max-width: 767px) {
  .s-sheetwrap { perspective: 1600px; }
  .s-doc { --ph: 240px; }
  .s-doc__face { gap: 13px; padding: 20px 18px; }
  .s-doc__h { font-size: 15px; gap: 10px; }
  .s-doc__ln, .s-doc__items { padding-left: 27px; }
  .s-doc__items { gap: 7px 12px; font-size: 13.5px; }
  .s-doc__items li { gap: 8px; }
  .s-doc__tag { font-size: 12px; letter-spacing: .08em; }
  .s-doc__field { font-size: 12px; letter-spacing: .08em; }
}
/* MOTION: folded in thirds (accordion), the sheet slides up and opens: --rise, --u2, --u3 run 0 → 1 (services.js) */
.a-motion .s-doc { transform: translate3d(0, calc((1 - var(--rise, 0)) * var(--ph) * .9), 0) rotateX(calc((1 - var(--rise, 0)) * 16deg)); }
.a-motion .s-doc__p--2 { transform: rotateX(calc((1 - var(--u2, 0)) * -178deg)); }
.a-motion .s-doc__p--3 { transform: rotateX(calc((1 - var(--u3, 0)) * -176deg)); visibility: hidden; }   /* rolled in behind panel 2 (never towards the viewer); shown once panel 2 is past edge-on (services.js) */
.a-motion .s-doc__shadow { transform: scaleY(calc((1 + var(--u2, 0) + var(--u3, 0)) / 3)); }
.a-motion .s-doc__p--2 > .s-doc__face::after, .a-motion .s-doc__p--3 > .s-doc__face::after { content: ''; position: absolute; inset: 0; pointer-events: none; background: #1d1a14; }
.a-motion .s-doc__p--2 > .s-doc__face::after { opacity: calc((1 - var(--u2, 0)) * .26); }
.a-motion .s-doc__p--3 > .s-doc__face::after { opacity: calc((1 - var(--u3, 0)) * .26); }

/* ------------------------------------------------------------------ 4 easier by phone? (the number at display size) */
.s-phone .a-head2__row { align-items: flex-end; }
.s-phone__mail { font-size: var(--fs-lead); line-height: 1.5; color: var(--muted); padding-bottom: 6px; }
.s-phone__mail a { display: inline-block; padding: 10px 0; margin: -10px 0; color: var(--text); font-weight: 600; text-decoration: underline; text-decoration-color: rgba(18, 20, 23, .3); text-decoration-thickness: 1px; text-underline-offset: 5px; transition: text-decoration-color .3s, color .3s; }
.s-phone__mail a:hover { color: var(--gold-ink); text-decoration-color: var(--gold-ink); }
.s-phone__num { display: inline-flex; align-items: center; gap: .26em; max-width: 100%; font-size: clamp(40px, 9vw, 136px); font-weight: 600; font-stretch: 106%; letter-spacing: -.04em; line-height: 1; font-variant-numeric: tabular-nums; white-space: nowrap; color: var(--text); transition: color .3s; }
.s-phone__num .a-line { padding-bottom: .06em; }
.s-phone__ic { flex: none; width: .6em; height: .6em; border-radius: 50%; display: grid; place-items: center; background: var(--gold); color: var(--ink); transition: background-color .3s, transform .6s var(--ease); }
.s-phone__ic .icon { width: 40%; height: 40%; }
.s-phone__num:hover { color: #000; }
.s-phone__num:hover .s-phone__ic { background: var(--gold-2); transform: rotate(-14deg) scale(1.04); }
.s-phone__ready { display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); column-gap: var(--gap); row-gap: 20px; align-items: center; margin-top: clamp(40px, 5vw, 72px); padding-top: 28px; border-top: 1px solid var(--line); }
.s-phone__ready .a-label { grid-column: 1 / span 3; margin: 0; }
.s-phone__list { grid-column: 4 / span 9; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: var(--gap); }
.s-phone__list li { display: flex; align-items: center; gap: 14px; font-size: 17px; font-weight: 600; letter-spacing: -.005em; line-height: 1.3; }
.s-phone__list .icon { width: 22px; height: 22px; color: var(--gold-ink); }
@media (max-width: 1023px) {
  .s-phone__ready .a-label, .s-phone__list { grid-column: 1 / -1; }
}
@media (max-width: 767px) {
  .s-phone__mail { font-size: 16px; padding-bottom: 0; }
  .s-phone__num { font-size: min(11.2vw, 52px); }
  .s-phone__list { grid-template-columns: 1fr; gap: 14px; }
  .s-phone__list li { font-size: 16px; }
}
