/* Site opening (Wardrobe doors) + "Ready to wear or Made to measure?" choice.
   Emil rules: a first-visit moment, so it may carry delight, but it is short (~2.4s),
   skippable with any tap or key, plays once per session, and collapses to a fade for
   reduced motion. Only transform, opacity and clip-path animate. */

.intro { position: fixed; inset: 0; z-index: 100; color: #f1ead9; font-family: "Inter", system-ui, sans-serif; }
.intro[hidden] { display: none; }
html.intro-on { overflow: hidden; }
.intro__open { position: absolute; inset: 0; z-index: 2; }
.intro__skip { position: absolute; z-index: 5; right: 18px; bottom: calc(18px + env(safe-area-inset-bottom)); height: 30px; padding: 0 14px; border-radius: 15px; background: rgba(255,255,255,.1); color: inherit; font-size: 11px; font-weight: 500; letter-spacing: .08em; text-transform: uppercase; opacity: .7; transition: opacity 200ms ease; }
.intro[data-stage="choice"] .intro__skip, .intro[data-stage="leaving"] .intro__skip { opacity: 0; pointer-events: none; }

/* ── Opening 2 · Wardrobe doors (default). Lacquered navy wardrobe doors: wood grain under the paint,
   raised panels with a brass inlay, brass pulls, the gw roundel split across the meeting stiles.
   Timeline (one 2.5s run, first visit only): warm light leaks through the gap → the roundel
   catches a gleam → the doors unlatch a few degrees → they swing open on their hinges while
   the room behind is lit and the camera steps in. ── */
.o-doors { position: absolute; inset: 0; perspective: 1700px; perspective-origin: 50% 45%; }
/* the light behind the doors, seen through the gap */
.o-doors__gap { position: absolute; z-index: 0; top: 0; bottom: 0; left: 50%; width: 2px; margin-left: -1px; background: #ffe2b0; box-shadow: 0 0 18px 6px rgba(255, 196, 120, .55), 0 0 70px 24px rgba(255, 180, 100, .22); opacity: 0; transform: scaleX(1); }
.o-door { position: absolute; z-index: 1; top: 0; bottom: 0; width: 50%; overflow: hidden; backface-visibility: hidden; will-change: transform;
  background:
    var(--grain) 0 0 / 360px 900px,
    linear-gradient(90deg, rgba(255,255,255,.03), rgba(255,255,255,0) 40%, rgba(0,0,0,.18)),
    linear-gradient(180deg, #1b2850 0%, #17234a 45%, #121c3b 100%);
  background-blend-mode: overlay, normal, normal; }
.o-door--l { left: 0; transform-origin: 0 50%; }
.o-door--r { right: 0; transform-origin: 100% 50%; }
.o-door--r { background:
    var(--grain) 180px 300px / 360px 900px,
    linear-gradient(270deg, rgba(255,255,255,.03), rgba(255,255,255,0) 40%, rgba(0,0,0,.18)),
    linear-gradient(180deg, #1b2850 0%, #17234a 45%, #121c3b 100%); background-blend-mode: overlay, normal, normal; }
/* meeting stile: the edges where the two doors touch */
.o-door--l::after, .o-door--r::after { content: ""; position: absolute; top: 0; bottom: 0; width: 10px; }
.o-door--l::after { right: 0; background: linear-gradient(90deg, rgba(0,0,0,0), rgba(0,0,0,.45)); }
.o-door--r::after { left: 0; background: linear-gradient(270deg, rgba(255,255,255,0), rgba(255,255,255,.05) 70%, rgba(0,0,0,.4)); }
/* raised panels with a hairline brass inlay */
.o-panel { position: absolute; left: 11%; right: 11%; border-radius: 2px;
  box-shadow: inset 0 0 0 1px rgba(0,0,0,.35), inset 3px 3px 0 rgba(255,255,255,.05), inset -3px -3px 0 rgba(0,0,0,.28), 0 1px 0 rgba(255,255,255,.04);
  background: linear-gradient(180deg, rgba(255,255,255,.025), rgba(0,0,0,.08)); }
.o-panel::before { content: ""; position: absolute; inset: 14px; border: 1px solid rgba(201, 164, 92, .38); border-radius: 1px; }
.o-panel--t { top: 6%; height: 50%; }
.o-panel--b { top: 62%; bottom: 6%; }
/* brass pulls */
.o-pull { position: absolute; top: calc(50% - 70px); width: 12px; height: 140px; }
.o-door--l .o-pull { right: 34px; }
.o-door--r .o-pull { left: 34px; }
.o-pull::before, .o-pull::after { content: ""; position: absolute; left: 3px; width: 6px; height: 14px; border-radius: 2px; background: linear-gradient(90deg, #6f5326, #c9a45c); }
.o-pull::before { top: 0; } .o-pull::after { bottom: 0; }
.o-pull i { position: absolute; top: 4px; bottom: 4px; left: 0; width: 12px; border-radius: 6px; background: linear-gradient(90deg, #7a5b2a 0%, #e9d29a 38%, #b8904c 60%, #6f5326 100%); box-shadow: 4px 6px 10px rgba(0,0,0,.45); }
/* the roundel, split across the doors; brass with a moving gleam */
.o-mark { position: absolute; top: 50%; width: var(--mk); height: var(--mk); margin-top: calc(var(--mk) / -2 - 120px); --mk: min(200px, 40vw); }
.o-door--l .o-mark { right: calc(var(--mk) / -2); }
.o-door--r .o-mark { left: calc(var(--mk) / -2); }
.o-mark__metal { position: absolute; inset: 0; overflow: hidden; -webkit-mask: url(assets/brand/gw-mark.svg) center / contain no-repeat; mask: url(assets/brand/gw-mark.svg) center / contain no-repeat;
  background: linear-gradient(135deg, #7c5e2c 0%, #d9bb7a 30%, #a9843f 55%, #e6cf95 75%, #7c5e2c 100%); }
.o-mark__metal i { position: absolute; top: -20%; bottom: -20%; width: 38%; left: 0; background: linear-gradient(90deg, rgba(255,255,255,0), rgba(255,250,235,.85), rgba(255,255,255,0)); transform: translateX(-160%) skewX(-18deg); }
.o-mark { filter: drop-shadow(0 2px 2px rgba(0,0,0,.5)); }
.o-doors__line { position: absolute; z-index: 2; left: 0; right: 0; bottom: calc(64px + env(safe-area-inset-bottom)); text-align: center; font-family: "Cormorant Garamond", serif; font-style: italic; font-size: 19px; color: #e9dcc0; opacity: 0; }
/* the room behind, lit as the doors part */
.intro .choice { transform: scale(1.06); transition: transform 2200ms cubic-bezier(0.25, 0.46, 0.45, 0.94), opacity 420ms ease; }
.intro .choice::after { content: ""; position: absolute; inset: 0; z-index: 4; pointer-events: none; background: radial-gradient(60% 80% at 50% 50%, rgba(255, 214, 150, .55), rgba(10, 16, 32, .9)); opacity: 1; transition: opacity 1400ms ease 300ms; }
.intro[data-stage="choice"] .choice, .intro[data-stage="leaving"] .choice { transform: none; }
.intro[data-stage="choice"] .choice::after, .intro[data-stage="leaving"] .choice::after { opacity: 0; }
.intro[data-stage="leaving"] .choice { transform: translateY(-100%); }

/* the run */
.intro[data-run] .o-doors__gap { animation: gap 2500ms linear forwards; }
@keyframes gap { 0% { opacity: 0; } 22% { opacity: .55; } 40% { opacity: .7; } 46% { opacity: 1; transform: scaleX(3); } 56% { opacity: 1; transform: scaleX(2); } 70% { opacity: 0; transform: scaleX(30); } 100% { opacity: 0; } }
.intro[data-run] .o-mark__metal i { animation: gleam 1100ms cubic-bezier(0.45, 0.05, 0.35, 1) 450ms forwards; }
@keyframes gleam { to { transform: translateX(380%) skewX(-18deg); } }
.intro[data-run] .o-doors__line { animation: line 2500ms ease forwards; }
@keyframes line { 0%, 12% { opacity: 0; } 26%, 50% { opacity: .75; } 60%, 100% { opacity: 0; } }
/* unlatch (a few degrees, a beat), then swing; the face darkens as it turns away from the light */
.intro[data-run] .o-door--l { animation: swing-l 2500ms forwards; }
.intro[data-run] .o-door--r { animation: swing-r 2500ms forwards; }
@keyframes swing-l { 0%, 40% { transform: rotateY(0); animation-timing-function: cubic-bezier(0.3, 0, 0.2, 1); } 47% { transform: rotateY(-4deg); animation-timing-function: ease-in-out; } 54% { transform: rotateY(-3deg); animation-timing-function: cubic-bezier(0.55, 0, 0.25, 1); } 100% { transform: rotateY(-104deg); } }
@keyframes swing-r { 0%, 40% { transform: rotateY(0); animation-timing-function: cubic-bezier(0.3, 0, 0.2, 1); } 47% { transform: rotateY(4.5deg); animation-timing-function: ease-in-out; } 54% { transform: rotateY(3.2deg); animation-timing-function: cubic-bezier(0.55, 0, 0.25, 1); } 100% { transform: rotateY(104deg); } }
.o-door__shade { position: absolute; inset: 0; z-index: 3; background: #05070d; opacity: 0; pointer-events: none; }
.intro[data-run] .o-door__shade { animation: shade 2500ms forwards; }
@keyframes shade { 0%, 54% { opacity: 0; } 100% { opacity: .75; } }
/* skipped: open quickly from wherever they are */
.intro[data-fast] .o-door--l { animation: swing-l-fast 650ms cubic-bezier(0.55, 0, 0.25, 1) forwards; }
.intro[data-fast] .o-door--r { animation: swing-r-fast 650ms cubic-bezier(0.55, 0, 0.25, 1) forwards; }
.intro[data-fast] .o-doors__gap, .intro[data-fast] .o-doors__line { animation: none; opacity: 0; }
@keyframes swing-l-fast { to { transform: rotateY(-104deg); } }
@keyframes swing-r-fast { to { transform: rotateY(104deg); } }
.intro[data-stage="leaving"] .o-doors { visibility: hidden; }
@media (max-width: 820px) {
  .o-pull { height: 96px; top: calc(50% - 48px); width: 10px; }
  .o-door--l .o-pull { right: 20px; } .o-door--r .o-pull { left: 20px; }
  .o-panel { left: 12%; right: 12%; }
  .o-panel::before { inset: 9px; }
  .o-mark { margin-top: calc(var(--mk) / -2 - 150px); }
}
@media (prefers-reduced-motion: reduce) {
  .intro[data-run] .o-door--l, .intro[data-run] .o-door--r, .intro[data-fast] .o-door--l, .intro[data-fast] .o-door--r { animation: none; }
  .intro[data-stage="choice"] .o-doors { opacity: 0; transition: opacity 300ms ease !important; }
}

/* ── The choice: two doors into the wardrobe ── */
.choice { position: absolute; inset: 0; z-index: 1; display: grid; grid-template-columns: 1fr 1fr; background: #0d1427; transition: opacity 420ms ease, transform 700ms var(--ease-in-out); }
.choice__q { position: absolute; z-index: 3; top: calc(34px + env(safe-area-inset-top)); left: 0; right: 0; text-align: center; pointer-events: none; }
.choice__q small { display: block; font-size: 10.5px; font-weight: 600; letter-spacing: .3em; text-transform: uppercase; opacity: .7; }
.choice__q h2 { margin-top: 10px; font-family: "Playfair Display", serif; font-weight: 600; font-size: clamp(28px, 3.4vw, 46px); line-height: 1.05; letter-spacing: -0.01em; }
.choice__q h2 i { font-family: "Mrs Saint Delafield", cursive; font-style: normal; font-weight: 400; font-size: 1.35em; color: #e2c891; margin-left: .08em; }
.door { position: relative; overflow: hidden; text-align: left; color: inherit; isolation: isolate; }
.door__img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; transform: scale(1.06); transition: transform 1600ms cubic-bezier(0.25, 0.46, 0.45, 0.94), filter 400ms ease; }
.door::before { content: ""; position: absolute; inset: 0; z-index: 1; background: linear-gradient(180deg, rgba(10,16,32,.62) 0%, rgba(10,16,32,.05) 34%, rgba(10,16,32,.1) 52%, rgba(10,16,32,.82) 100%); }
.door::after { content: ""; position: absolute; inset: 0; z-index: 1; background: #0d1427; opacity: 0; transition: opacity 300ms ease; }
.door + .door { box-shadow: inset 1px 0 0 rgba(241,234,217,.18); }
.door__copy { position: absolute; z-index: 2; left: clamp(22px, 4vw, 56px); right: clamp(22px, 4vw, 56px); bottom: calc(clamp(28px, 6vh, 64px) + env(safe-area-inset-bottom)); display: grid; gap: 10px; }
.door__k { font-size: 11px; font-weight: 600; letter-spacing: .22em; text-transform: uppercase; color: #e2c891; }
.door b { font-family: "Playfair Display", serif; font-weight: 600; font-size: clamp(32px, 3.6vw, 54px); line-height: 1; letter-spacing: -0.015em; }
.door small { max-width: 34ch; font-size: 14px; line-height: 1.55; opacity: .78; }
.door em { justify-self: start; margin-top: 8px; display: inline-flex; align-items: center; gap: 10px; height: 44px; padding: 0 20px; border-radius: 22px; background: #f1ead9; color: #16213d; font-style: normal; font-size: 11.5px; font-weight: 600; letter-spacing: .1em; text-transform: uppercase; transition: transform 160ms var(--ease-out); }
.door em span { transition: transform 260ms var(--ease-out); }
.door:active em { transform: scale(.97); }
/* Copy rises in, staggered, as the doors open */
.door__copy > * { opacity: 0; transform: translateY(14px); transition: opacity 500ms var(--ease-out), transform 600ms var(--ease-out); }
.intro[data-stage="choice"] .door__img { transform: scale(1); }
.intro[data-stage="choice"] .door__copy > * { opacity: 1; transform: none; transition-delay: calc(var(--d, 0ms) + var(--i, 0) * 60ms); }
.choice__q > * { opacity: 0; transform: translateY(10px); transition: opacity 500ms ease, transform 600ms var(--ease-out); }
.intro[data-stage="choice"] .choice__q > * { opacity: 1; transform: none; transition-delay: calc(var(--d, 0ms) + var(--i, 0) * 70ms); }
.choice__browse { position: absolute; z-index: 3; left: 50%; bottom: calc(22px + env(safe-area-inset-bottom)); transform: translateX(-50%); font-size: 12px; font-weight: 500; opacity: 0; transition: opacity 400ms ease; }
.intro[data-stage="choice"] .choice__browse { opacity: .75; transition-delay: calc(var(--d, 0ms) + 400ms); }
@media (hover: hover) and (pointer: fine) {
  .choice:has(.door:hover) .door:not(:hover)::after { opacity: .45; }
  .door:hover .door__img { transform: scale(1.03); transition-duration: 1200ms; transition-timing-function: var(--ease-out); }
  .door:hover em span { transform: translateX(4px); }
  .choice__browse:hover { opacity: 1; }
}
.door:focus-visible { outline: 2px solid #e2c891; outline-offset: -6px; }
/* Choosing: the other door dims and slides away; then the layer lifts (ready) or hands over to booking (custom) */
.choice[data-picked] .door:not([data-on])::after { opacity: .85; }
.choice[data-picked="ready"] .door[data-k="custom"], .choice[data-picked="custom"] .door[data-k="ready"] { transform: translateX(var(--away)); transition: transform 600ms var(--ease-in-out); }
.door[data-k="ready"] { --away: -12%; }
.door[data-k="custom"] { --away: 12%; }
.choice[data-picked] .door__copy > * { opacity: 0; transform: translateY(-6px); transition: opacity 180ms ease, transform 200ms ease; }
.intro[data-stage="leaving"] .choice { transform: translateY(-100%); transition-delay: 280ms; }
.intro[data-stage="leaving"][data-go="custom"] .choice { transform: none; opacity: 1; }

@media (max-width: 820px) {
  .choice { grid-template-columns: 1fr; grid-template-rows: 1fr 1fr; }
  .door + .door { box-shadow: inset 0 1px 0 rgba(241,234,217,.18); }
  .choice__q { top: calc(22px + env(safe-area-inset-top)); }
  .choice__q h2 { font-size: 24px; padding: 0 24px; }
  .choice__q h2 > span { display: block; }
  .choice__browse { left: auto; right: 16px; transform: none; bottom: auto; top: calc(50% + 14px); }
  .door__copy { bottom: 22px; gap: 6px; }
  .door[data-k="custom"] .door__copy { bottom: calc(52px + env(safe-area-inset-bottom)); }
  .door[data-k="ready"] .door__copy { bottom: 20px; }
  .door b { font-size: 30px; }
  .door small { font-size: 12.5px; }
  .door em { height: 38px; padding: 0 16px; margin-top: 4px; font-size: 10.5px; }
  .door[data-k="ready"] { --away: 0; }
  .door[data-k="custom"] { --away: 0; }
  .choice[data-picked="ready"] .door[data-k="custom"] { transform: translateY(12%); }
  .choice[data-picked="custom"] .door[data-k="ready"] { transform: translateY(-12%); }
  .o-door__handle { height: 64px; margin-top: 130px; }
}

@media (prefers-reduced-motion: reduce) {
  .intro *, .intro *::before, .intro *::after { transition-duration: 1ms !important; transition-delay: 0ms !important; }
  .intro__open { transition: opacity 300ms ease !important; }
  .intro[data-stage="choice"] .intro__open { opacity: 0; }
  .choice { transition: opacity 300ms ease !important; }
  .intro[data-stage="leaving"] .choice { transform: none; opacity: 0; }
}

/* Once the doors have opened, the opening layer must not catch taps meant for the choice. */
.intro[data-stage="choice"] .intro__open, .intro[data-stage="leaving"] .intro__open { pointer-events: none; }

/* ── The choice, luxury-house treatment: a still wordmark, full-bleed photographs, a single
   uppercase title and one hairline link per side. No paragraphs, no pills, no ornament. ── */
.choice { background: #000; }
.choice__mark { position: absolute; z-index: 3; top: calc(30px + env(safe-area-inset-top)); left: 0; right: 0; display: flex; justify-content: center; pointer-events: none; opacity: 0; transition: opacity 700ms ease; }
.choice__mark svg { width: clamp(128px, 11vw, 168px); height: auto; color: #fff; }
.intro[data-stage="choice"] .choice__mark { opacity: 1; transition-delay: var(--d, 0ms); }
.door::before { background: linear-gradient(180deg, rgba(0,0,0,.34) 0%, rgba(0,0,0,0) 22%, rgba(0,0,0,0) 62%, rgba(0,0,0,.5) 100%); }
.door::after { background: #000; }
.door + .door { box-shadow: none; }
.door__copy { left: 0; right: 0; bottom: calc(clamp(40px, 8vh, 76px) + env(safe-area-inset-bottom)); display: grid; justify-items: center; gap: 16px; text-align: center; }
.door b { font-family: "Inter", system-ui, sans-serif; font-weight: 500; font-size: clamp(15px, 1.25vw, 19px); letter-spacing: .32em; text-transform: uppercase; line-height: 1; padding-left: .32em; }
.door em { justify-self: center; margin: 0; height: auto; padding: 0 0 5px; border-radius: 0; background: none; color: #fff; font-style: normal; font-size: 10.5px; font-weight: 500; letter-spacing: .22em; text-transform: uppercase; box-shadow: inset 0 -1px 0 rgba(255,255,255,.85); transition: box-shadow 240ms var(--ease-out), opacity 200ms ease; }
.door:active em { transform: none; }
.door:active { transform: none; }
@media (hover: hover) and (pointer: fine) {
  .door:hover em { box-shadow: inset 0 -1px 0 rgba(255,255,255,.35); }
  .choice:has(.door:hover) .door:not(:hover)::after { opacity: .5; }
}
.door:focus-visible { outline: 1px solid #fff; outline-offset: -10px; }
@media (max-width: 820px) {
  .choice__mark { top: calc(22px + env(safe-area-inset-top)); }
  .choice__mark svg { width: 124px; }
  .door__copy, .door[data-k="ready"] .door__copy, .door[data-k="custom"] .door__copy { bottom: 30px; gap: 12px; }
  .door b { font-size: 14px; }
  .door + .door { box-shadow: inset 0 1px 0 rgba(255,255,255,.12); }
}
.door__copy { color: #fff; text-shadow: 0 1px 14px rgba(0, 0, 0, .35); }

/* ── Hand-over to the home page ── */
/* 1 · the chosen photo grows to the whole screen; the other half dims and recedes */
.door[data-grow] { position: absolute; inset: 0; z-index: 4; transition: clip-path 700ms var(--ease-in-out); }
.door[data-grow] .door__img { transform: scale(1.04); transition: transform 1400ms var(--ease-out); }
.door[data-grow]::before { opacity: .6; transition: opacity 600ms ease; }
.choice[data-picked] .door:not([data-on]) { transform: scale(.96); opacity: .35; transition: transform 700ms var(--ease-in-out), opacity 500ms ease; }
.choice[data-picked] .choice__mark { opacity: 0; transition: opacity 240ms ease; }
/* 2 · a curtain lifts off the home page, a brass hairline riding its lower edge */
.intro[data-stage="leaving"] .choice { transform: none !important; opacity: 1; clip-path: inset(0 0 100% 0); transition: clip-path 1050ms cubic-bezier(0.65, 0, 0.35, 1); }
.choice { clip-path: inset(0 0 0 0); }
.intro__edge { position: absolute; z-index: 6; left: 0; right: 0; top: 0; height: 1px; background: linear-gradient(90deg, rgba(201,164,92,0), #e2c891 18%, #f4e3b8 50%, #e2c891 82%, rgba(201,164,92,0)); box-shadow: 0 0 14px rgba(226,200,145,.55); transform: translateY(100svh); opacity: 0; pointer-events: none; }
.intro[data-stage="leaving"] .intro__edge { opacity: 1; transform: translateY(-2px); transition: transform 1050ms cubic-bezier(0.65, 0, 0.35, 1), opacity 200ms ease; }
.intro[data-stage="leaving"] { pointer-events: none; }
@media (prefers-reduced-motion: reduce) {
  .door[data-grow], .intro[data-stage="leaving"] .choice { clip-path: none !important; transition: opacity 300ms ease !important; }
  .intro[data-stage="leaving"] .choice { opacity: 0; }
  .intro__edge { display: none; }
}

/* ── Choice entrance: as the doors part, each photograph "lights up" (dark, soft and slightly
   close → bright, sharp, settled), Ready to wear first and Made to measure a beat later; then the
   wordmark and each title rise in. Independent `scale` so the hover zoom (transform) still works. */
.door__img { filter: brightness(.38) blur(10px); scale: 1.1;
  transition: filter 1300ms cubic-bezier(0.23, 1, 0.32, 1), scale 1900ms cubic-bezier(0.23, 1, 0.32, 1), transform 1600ms cubic-bezier(0.25, 0.46, 0.45, 0.94); }
.intro[data-stage="choice"] .door__img { filter: none; scale: 1; transition-delay: calc(var(--d, 0ms) - 300ms); }
.intro[data-stage="choice"] .door[data-k="custom"] .door__img { transition-delay: calc(var(--d, 0ms) - 160ms); }
.door__copy > * { opacity: 0; transform: translateY(16px); filter: blur(4px); transition: opacity 600ms var(--ease-out), transform 750ms var(--ease-out), filter 600ms var(--ease-out); }
.intro[data-stage="choice"] .door__copy > * { opacity: 1; transform: none; filter: none; transition-delay: calc(var(--d, 0ms) + 260ms + var(--i, 0) * 90ms); }
.choice__mark { transform: translateY(-8px); filter: blur(4px); transition: opacity 800ms ease, transform 900ms var(--ease-out), filter 700ms var(--ease-out); }
.intro[data-stage="choice"] .choice__mark { transform: none; filter: none; }
.intro[data-fast][data-stage="choice"] .door__img { transition-duration: 900ms, 1200ms, 1600ms; transition-delay: 0ms; }
.intro[data-fast][data-stage="choice"] .door[data-k="custom"] .door__img { transition-delay: 90ms; }
@media (prefers-reduced-motion: reduce) { .door__img, .door__copy > *, .choice__mark { filter: none !important; scale: 1 !important; transform: none !important; } }
