/* Rebelote home: a navy-and-ivory lookbook. The real pieces, cut out from their hanger photos, stand in an
   ivory arch like a boutique mirror; everything else stays quiet and close-set. */

/* ---------- hero ---------- */
.hx { position: relative; background: var(--navy); color: var(--ivory); padding: calc(var(--nav) + clamp(32px, 5vw, 72px)) 0 clamp(40px, 5vw, 72px); overflow: hidden; }
.hx::before { content: ""; position: absolute; inset: auto -10% -40% 40%; height: 90%; background: radial-gradient(closest-side, rgb(207 168 96 / .16), transparent); pointer-events: none; }
.hx__grid { position: relative; display: grid; grid-template-columns: minmax(0, 6fr) minmax(0, 6fr); gap: clamp(24px, 4vw, 72px); align-items: center; }
.hx__kicker { margin: 0 0 var(--s-5); font: 500 15px/22px var(--font-text); color: var(--gold); letter-spacing: .02em; }
.hx h1 { margin: 0; font: 500 clamp(44px, 5.6vw, 84px)/.98 var(--font-display); letter-spacing: -.02em; color: var(--ivory); }
.hx h1 em { font-style: italic; color: var(--gold); }
.hx__lead { margin: var(--s-5) 0 var(--s-6); max-width: 33em; font: 400 clamp(17px, 1.3vw, 19px)/1.6 var(--font-text); color: rgb(247 244 238 / .86); }
.hx .btn-row { flex-wrap: wrap; }
.hx__facts { display: grid; grid-template-columns: repeat(3, auto); justify-content: start; gap: var(--s-6); margin: var(--s-7) 0 0; padding-top: var(--s-5); border-top: 1px solid rgb(247 244 238 / .18); }
.hx__facts div { display: grid; gap: 2px; }
.hx__facts dt { font: 500 clamp(24px, 2.2vw, 32px)/1.1 var(--font-display); color: var(--ivory); }
.hx__facts dd { margin: 0; font-size: 14px; color: rgb(247 244 238 / .7); }

.hx__stage { position: relative; aspect-ratio: 5 / 5.4; max-height: calc(100svh - var(--nav) - 80px); margin-left: auto; width: 100%; }
.hx__arch { position: absolute; inset: 4% 14% 0; border-radius: 999px 999px 0 0; background: var(--ivory); box-shadow: inset 0 0 0 1px rgb(207 168 96 / .5); }
.hx__arch::after { content: ""; position: absolute; inset: 12px 12px 0; border-radius: 999px 999px 0 0; border: 1px solid rgb(207 168 96 / .55); border-bottom: 0; }
.hx__floor { position: absolute; left: 6%; right: 6%; bottom: 0; height: 1px; background: rgb(207 168 96 / .6); }
.hx__piece { position: absolute; bottom: 3%; display: block; transition: transform 200ms cubic-bezier(0, 0, .2, 1); }
.hx__piece img { display: block; width: 100%; height: auto; filter: drop-shadow(0 12px 16px rgb(11 21 48 / .08)); }
.hx__piece:hover, .hx__piece:focus-visible { transform: translateY(-8px); }
.hx__piece--l { left: 2%; width: 36%; bottom: 7%; z-index: 1; }
.hx__piece--c { left: 30%; width: 40%; z-index: 3; }
.hx__piece--r { right: 2%; width: 30%; bottom: 6%; z-index: 2; }
.tag { position: absolute; z-index: 4; display: grid; gap: 1px; padding: 8px 12px 8px 24px; background: var(--ivory); color: var(--navy); font: 500 13px/20px var(--font-text);
  border: 1px solid rgb(11 21 48 / .12); box-shadow: 0 4px 12px rgb(11 21 48 / .08); clip-path: polygon(10px 0, 100% 0, 100% 100%, 10px 100%, 0 50%); white-space: nowrap; }
.tag::before { content: ""; position: absolute; left: 9px; top: 50%; width: 5px; height: 5px; margin-top: -2.5px; border-radius: 50%; background: var(--navy); }
.tag b { font: 600 16px/20px var(--font-display); }
.hx__piece--l .tag { left: 0; top: 4%; }
.hx__piece--c .tag { right: -8%; top: 30%; }
.hx__piece--r .tag { right: 4%; top: -4%; }

@media (max-width: 1023px) {
  .hx__grid { grid-template-columns: 1fr; }
  .hx__stage { max-width: 560px; margin: var(--s-5) auto 0; aspect-ratio: 1 / 1; }
  .hx__facts { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: var(--s-4); }
}
@media (max-width: 639px) {
  .hx__facts dt { font-size: 24px; }
  .tag { font-size: 12px; padding: 4px 8px 4px 20px; }
  .tag b { font-size: 14px; }
  .hx .btn-row .btn { width: 100%; }
}

/* the hero's one entrance: the copy rises, then the pieces arrive into the arch */
@media (prefers-reduced-motion: no-preference) {
  .hx__copy > * { animation: rise 300ms var(--ease) both; }
  .hx__copy > :nth-child(2) { animation-delay: 30ms; } .hx__copy > :nth-child(3) { animation-delay: 60ms; }
  .hx__copy > :nth-child(4) { animation-delay: 90ms; } .hx__copy > :nth-child(5) { animation-delay: 120ms; }
  .hx__arch { animation: arch 300ms var(--ease) both; transform-origin: 50% 100%; }
  .hx__piece { animation: piece 300ms var(--ease) both; }
  .hx__piece--c { animation-delay: 150ms; } .hx__piece--l { animation-delay: 180ms; } .hx__piece--r { animation-delay: 200ms; }
  .tag { animation: rise 300ms var(--ease) 300ms both; }
}
@keyframes rise { from { opacity: 0; transform: translateY(14px); } }
@keyframes arch { from { opacity: 0; transform: scaleY(.85); } }
@keyframes piece { from { opacity: 0; transform: translateY(40px); } }

/* ---------- brand ribbon ---------- */
/* the designers on the rail scroll past in one line (two identical lists, so the loop has no seam). It pauses
   on hover, on keyboard focus and with its own button (moving content needs a pause, WCAG 2.2.2), and stands
   still, wrapped, when the visitor asks for reduced motion. */
.ribbon { --gap: clamp(28px, 4vw, 56px); position: relative; background: var(--paper); border-block: 1px solid var(--line); overflow: hidden; }
.ribbon__track { display: flex; width: max-content; animation: slide 40s linear infinite; }
.ribbon:hover .ribbon__track, .ribbon:focus-within .ribbon__track, .ribbon.is-paused .ribbon__track { animation-play-state: paused; }
.ribbon__list { display: flex; flex-wrap: nowrap; align-items: center; gap: var(--gap); margin: 0; padding: 12px var(--gap) 12px 0; list-style: none; }
.ribbon__list li { display: flex; align-items: center; gap: var(--gap); }
.ribbon__list li::before { content: ""; width: 6px; height: 6px; transform: rotate(45deg); background: var(--gold); flex: none; }
.ribbon__list a { display: inline-flex; align-items: center; min-height: 44px; font: 500 clamp(22px, 2vw, 28px)/1 var(--font-display); color: var(--navy); text-decoration: none; white-space: nowrap; }
.ribbon__list a:hover { color: #8a6a2c; }
.ribbon__pause { position: absolute; right: 8px; top: 50%; transform: translateY(-50%); z-index: 2; background: var(--paper); color: var(--navy); border: 1px solid var(--line-strong); border-radius: 50%; }
.ribbon__pause:hover { background: var(--ivory); }
.ribbon__pause .i-play { display: none; }
.ribbon.is-paused .ribbon__pause .i-play { display: block; }
.ribbon.is-paused .ribbon__pause .i-pause { display: none; }
.ribbon__pause[data-tip]::after { top: auto; bottom: calc(100% + 8px); }
@keyframes slide { to { transform: translateX(-50%); } }
@media (prefers-reduced-motion: reduce) {
  .ribbon__track { animation: none; width: auto; justify-content: center; }
  .ribbon__list { flex-wrap: wrap; justify-content: center; padding: 12px 16px; }
  .ribbon__list[aria-hidden="true"], .ribbon__pause { display: none; }
}

/* the large card of the selection: the photo takes the card's extra height, never the text under it */
.feat > .pcard:first-child .pcard__body { flex: none; }
.feat > .pcard:first-child .pcard__img { flex: 1 1 auto; }
.feat > .pcard:first-child .pcard__img > img:first-child { position: absolute; inset: 0; }


/* ---------- shared section shell (the home page sets its own rhythm, close-set) ---------- */
.hs { padding: clamp(56px, 7vw, 104px) 0; }
.hs__head { display: flex; justify-content: space-between; align-items: end; gap: var(--s-5); margin-bottom: clamp(24px, 3vw, 40px); flex-wrap: wrap; }
.hs__head h2 { margin: 0; font: 500 clamp(32px, 3.6vw, 52px)/1.04 var(--font-display); letter-spacing: -.015em; }
.hs__head p { margin: var(--s-2) 0 0; font-size: 17px; line-height: 26px; color: var(--muted); max-width: 36em; }

/* ---------- the selection: one large piece and four beside it ---------- */
.feat { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); grid-template-rows: auto auto; gap: var(--gutter); list-style: none; margin: 0; padding: 0; }
.feat > .pcard:first-child { grid-column: 1 / span 2; grid-row: 1 / span 2; }
.feat > .pcard:first-child .pcard__img { aspect-ratio: auto; flex: 1; min-height: 420px; }
.feat > .pcard:first-child .pcard__name { font: 500 26px/1.15 var(--font-display); }
.feat > .pcard:first-child .pcard__price { font-size: 20px; }
@media (max-width: 1023px) { .feat { grid-template-columns: repeat(2, minmax(0, 1fr)); } .feat > .pcard:first-child { grid-row: auto; } .feat > .pcard:first-child .pcard__img { min-height: 0; aspect-ratio: 4 / 5; flex: none; } }

/* ---------- try-on showcase ---------- */
.tryx { background: var(--navy); color: var(--ivory); }
.tryx__grid { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 6fr); gap: clamp(32px, 5vw, 88px); align-items: center; }
.tryx h2 { margin: 0 0 var(--s-4); font: 500 clamp(34px, 3.8vw, 56px)/1.02 var(--font-display); color: var(--ivory); letter-spacing: -.015em; }
.tryx__lead { margin: 0 0 var(--s-6); font-size: 18px; line-height: 28px; color: rgb(247 244 238 / .84); max-width: 32em; }
.steps3 { list-style: none; margin: 0 0 var(--s-7); padding: 0; display: grid; gap: var(--s-4); counter-reset: s; }
.steps3 li { counter-increment: s; display: grid; grid-template-columns: 44px 1fr; gap: var(--s-4); align-items: start; font-size: 17px; line-height: 26px; color: rgb(247 244 238 / .9); }
.steps3 li::before { content: counter(s); width: 44px; height: 44px; display: grid; place-items: center; border: 1px solid rgb(207 168 96 / .6); border-radius: 50%; font: 500 20px/1 var(--font-display); color: var(--gold); }
.steps3 strong { display: block; color: var(--ivory); font-weight: 500; }
.ba { position: relative; aspect-ratio: 3 / 4; overflow: hidden; background: #18223c; max-height: 760px; margin-inline: auto; width: 100%; user-select: none; touch-action: pan-y; }
.ba img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; object-position: 50% 20%; }
.ba__after { position: absolute; inset: 0; clip-path: inset(0 0 0 var(--cut, 50%)); }
.ba__line { position: absolute; top: 0; bottom: 0; left: var(--cut, 50%); width: 2px; margin-left: -1px; background: var(--ivory); pointer-events: none; }
.ba__knob { position: absolute; top: 50%; left: var(--cut, 50%); width: 52px; height: 52px; margin: -26px 0 0 -26px; border-radius: 50%; background: var(--ivory); color: var(--navy); display: grid; place-items: center; border: 1px solid rgb(11 21 48 / .16); pointer-events: none; }
.ba input { position: absolute; inset: 0; width: 100%; height: 100%; margin: 0; opacity: 0; cursor: ew-resize; }
.ba input:focus-visible + .ba__knob { outline: 2px solid var(--gold); outline-offset: 3px; }
.ba__label { position: absolute; bottom: var(--s-4); padding: 6px 12px; background: rgb(11 21 48 / .78); color: var(--ivory); font: 500 13px/18px var(--font-text); pointer-events: none; }
.ba__label--l { left: var(--s-4); } .ba__label--r { right: var(--s-4); }
.ba__garment { position: absolute; top: var(--s-4); right: var(--s-4); width: 26%; background: var(--ivory); padding: 8px; border: 1px solid rgb(247 244 238 / .5); pointer-events: none; }
.ba__garment img { position: static; width: 100%; height: auto; aspect-ratio: 3 / 4; object-fit: cover; }
@media (max-width: 1023px) { .tryx__grid { grid-template-columns: 1fr; } .ba { max-width: 520px; } }

/* ---------- departments ---------- */
.aisles { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: var(--gutter); }
.aisle { position: relative; display: block; overflow: hidden; aspect-ratio: 3 / 4; background: var(--paper); color: var(--ivory); text-decoration: none; }
.aisle img { width: 100%; height: 100%; object-fit: cover; transition: transform 300ms cubic-bezier(0, 0, .2, 1); }
.aisle:hover img { transform: scale(1.04); }
.aisle__label { position: absolute; left: 0; right: 0; bottom: 0; display: flex; justify-content: space-between; align-items: baseline; gap: var(--s-3); padding: 64px var(--s-5) var(--s-5);
  background: linear-gradient(to top, rgb(11 21 48 / .88), rgb(11 21 48 / 0)); }
.aisle__label b { font: 500 clamp(24px, 2.2vw, 32px)/1 var(--font-display); }
.aisle__label span { font-size: 14px; color: rgb(247 244 238 / .85); }
@media (max-width: 1023px) { .aisles { grid-template-columns: repeat(2, minmax(0, 1fr)); } }

/* ---------- the house and the visit ---------- */
.house { display: grid; grid-template-columns: minmax(0, 7fr) minmax(0, 5fr); gap: var(--gutter); align-items: stretch; }
.house__story { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: var(--gutter); background: var(--paper); }
.house__story img { width: 100%; height: 100%; object-fit: cover; min-height: 360px; display: block; }
.house__text { padding: clamp(24px, 3vw, 48px) clamp(24px, 3vw, 40px) clamp(24px, 3vw, 48px) 0; display: flex; flex-direction: column; justify-content: center; }
.house__text h2 { margin: 0 0 var(--s-4); font: 500 clamp(30px, 3vw, 44px)/1.05 var(--font-display); }
.house__text p { margin: 0 0 var(--s-5); font-size: 17px; line-height: 27px; }
.visitcard { background: var(--navy); color: var(--ivory); padding: clamp(24px, 3vw, 44px); display: flex; flex-direction: column; gap: var(--s-5); }
.visitcard h2 { margin: 0; font: 500 clamp(28px, 2.6vw, 38px)/1.1 var(--font-display); color: var(--ivory); }
.visitcard .open { margin: 0; display: inline-flex; align-items: center; gap: var(--s-2); font: 500 15px/22px var(--font-text); color: var(--gold); }
.visitcard .open::before { content: ""; width: 8px; height: 8px; border-radius: 50%; background: currentColor; }
.visitcard address { font: 500 22px/1.35 var(--font-display); font-style: normal; }
.visitcard address a { color: inherit; text-decoration: underline 1px; text-decoration-color: rgb(207 168 96 / .6); text-underline-offset: 4px; }
.visitcard .hours { --ink: var(--ivory); color: var(--ivory); font-size: 16px; }
.visitcard .hours dt { color: rgb(247 244 238 / .75); }
.visitcard .btn-row { margin-top: auto; flex-wrap: wrap; }
@media (max-width: 1023px) { .house { grid-template-columns: 1fr; } }
@media (max-width: 639px) { .house__story { grid-template-columns: 1fr; } .house__text { padding: 0 var(--s-5) var(--s-5); } .house__story img { min-height: 0; aspect-ratio: 4 / 3; } }

/* the kit makes every section .wrap a flex column; these wraps are grids */
main > section > .wrap:is(.hx__grid, .tryx__grid, .house):not(#_) { display: grid; }
main > section > .wrap:not(#_) { justify-content: normal; }
/* the kit pads every main > section; the home page sets its own, close-set rhythm */
main > section.ribbon:not(#_) { padding: 0; }
main > section.hs:not(#_) { padding-block: clamp(56px, 7vw, 104px); }
main > section#maison:not(#_) { padding-top: 0; }
main > section.hx:not(#_) { padding: calc(var(--nav) + clamp(32px, 5vw, 72px)) 0 clamp(40px, 5vw, 72px); }

/* phone: the pieces come right after the headline, so the first screen shows the shop's own clothes */
@media (max-width: 1023px) {
  .hx__grid { display: flex !important; flex-direction: column; align-items: stretch; gap: 0; }
  .hx__copy { display: contents; }
  .hx__kicker { order: 1; } .hx h1 { order: 2; } .hx__stage { order: 3; margin: var(--s-5) auto var(--s-2); }
  .hx__lead { order: 4; } .hx .btn-row { order: 5; } .hx__facts { order: 6; }
}
@media (max-width: 639px) {
  .hx h1 { font-size: 42px; line-height: 1; }
  .hx__kicker { font-size: 14px; margin-bottom: var(--s-3); }
  .hx__stage { width: 100%; }
  .hx__facts { margin-top: var(--s-6); gap: var(--s-3); }
  .hx__facts dt { font-size: 22px; white-space: nowrap; }
  .hx__facts dd { font-size: 13px; line-height: 18px; }
  .hx__lead { margin-top: var(--s-4); }
}

@media (prefers-reduced-motion: reduce) {
  .hx__piece, .aisle img { transition: none; }
  .hx__piece:hover, .hx__piece:focus-visible, .aisle:hover img { transform: none; }
}

/* lining figures for the hero facts and price tags (the kit resets figures on dt) */
.hx .hx__facts dt, .hx .tag b, .feat .pcard__price { font-variant-numeric: lining-nums; font-feature-settings: "lnum" 1; }
