/* ============================================================
   SEYLUNE — SITE STYLES
   One stylesheet for every page. Home adds home/scenes.css for
   its six full-screen scenes; every other page is a "room":
   one half holds still (a photograph, or the order summary)
   while the other half moves.
   1.  Tokens + base
   2.  Accessibility
   3.  Buttons, links, small controls
   4.  Header
   5.  The menu room
   6.  Liquid image boxes
   7.  Page frame: dusk, reveal, footer
   8.  Rooms (split layout)
   9.  The index (collection + search lists)
   9b. Ledger rooms (cart + checkout)
   10. Product cards (saved pieces, related)
   11. Filters + sort
   12. Forms
   13. Toast, heart, modal, empty state
   13b. Layers: bag drawer, quick view, zoom
   14. Tablets + phones
============================================================ */


/* ============================================================
   1. TOKENS + BASE
============================================================ */
:root {
  color-scheme: dark;

  /* Seylune's original palette */
  --bg-main: #151116;
  --bg-card: #221A24;
  --bg-deep: #0F0D10;
  --text-main: #F4EEE8;
  --text-soft: #B9A8AE;
  --gold: #C6A36B;
  --gold-hover: #D7B980;
  --error: #E59A9A;

  --line: rgba(244, 238, 232, 0.14);
  --line-strong: rgba(244, 238, 232, 0.3);
  --line-gold: rgba(198, 163, 107, 0.45);

  --font-display: "Tenor Sans", "Futura", sans-serif;
  --font-body: "Manrope", system-ui, sans-serif;
  --font-heading: var(--font-display);

  /* The corner header's height; --header is the clear zone every
     page keeps under it, so text never sits beneath the words */
  --nav: 76px;
  --header: var(--nav);
  --pad: clamp(1.25rem, 3.4vw, 3.5rem);
  --index-room: var(--pad);
  --gap-y: clamp(1rem, 4.5vh, 3rem);

  --radius: 0px;
  --ease: cubic-bezier(0.22, 1, 0.36, 1);
  --transition: 0.5s var(--ease);
}

*,
*::before,
*::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  -webkit-text-size-adjust: 100%;
}

body {
  font-family: var(--font-body);
  font-size: 16px;
  line-height: 1.6;
  color: var(--text-main);
  background: var(--bg-deep);
  -webkit-font-smoothing: antialiased;
}

::selection {
  background: var(--gold);
  color: var(--bg-deep);
}

a {
  color: inherit;
  text-decoration: none;
}

img,
video {
  display: block;
  max-width: 100%;
}

button,
input,
select,
textarea {
  font: inherit;
  color: inherit;
}

button {
  background: none;
  border: none;
  cursor: pointer;
}

ul,
ol {
  list-style: none;
}

h1,
h2,
h3,
h4 {
  font-weight: 400;
}

/* Small tracked label that names a scene or a section */
.scene-kicker,
.kicker {
  font-family: var(--font-body);
  font-size: 0.7rem;
  font-weight: 500;
  letter-spacing: 0.32em;
  text-transform: uppercase;
  color: var(--gold);
}

/* The large uppercase titles */
.display {
  font-family: var(--font-display);
  line-height: 1.04;
  letter-spacing: 0.03em;
  text-transform: uppercase;
}


/* ============================================================
   2. ACCESSIBILITY
============================================================ */
.skip-link {
  position: absolute;
  left: 1rem;
  top: -100px;
  z-index: 1000;
  background: var(--gold);
  color: var(--bg-deep);
  padding: 0.7rem 1.2rem;
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.2em;
  text-transform: uppercase;
}

.skip-link:focus {
  top: 1rem;
}

main:focus {
  outline: none;
}

a:focus-visible,
button:focus-visible,
input:focus-visible,
select:focus-visible,
textarea:focus-visible,
summary:focus-visible,
[tabindex]:focus-visible {
  outline: 1px solid var(--gold);
  outline-offset: 4px;
}

.visually-hidden {
  position: absolute !important;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
}

[hidden] {
  display: none !important;
}


/* ============================================================
   3. BUTTONS, LINKS, SMALL CONTROLS
============================================================ */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.6rem;
  min-height: 50px;
  padding: 0 2rem;
  font-family: var(--font-body);
  font-size: 0.7rem;
  font-weight: 600;
  letter-spacing: 0.26em;
  text-transform: uppercase;
  white-space: nowrap;
  border: 1px solid transparent;
  transition: background-color 0.4s var(--ease), color 0.4s var(--ease), border-color 0.4s var(--ease);
}

.btn-primary {
  background: var(--gold);
  color: var(--bg-deep);
}

.btn-primary:hover {
  background: var(--text-main);
}

.btn-ghost,
.btn-outline {
  border-color: rgba(244, 238, 232, 0.4);
  color: var(--text-main);
}

.btn-ghost:hover,
.btn-outline:hover {
  background: var(--text-main);
  border-color: var(--text-main);
  color: var(--bg-deep);
}

.btn-small {
  min-height: 40px;
  padding: 0 1.2rem;
  font-size: 0.66rem;
}

.btn-block {
  width: 100%;
}

.btn:disabled {
  opacity: 0.5;
  cursor: default;
}

.text-link {
  display: inline-block;
  font-size: 0.7rem;
  font-weight: 600;
  letter-spacing: 0.24em;
  text-transform: uppercase;
  padding-bottom: 0.3rem;
  border-bottom: 1px solid var(--line-gold);
  transition: color 0.3s, border-color 0.3s;
}

.text-link:hover {
  color: var(--gold);
  border-color: var(--gold);
}

/* Round sizes: one tap adds that size to the cart */
.size-pill,
.size-btn {
  width: 46px;
  height: 46px;
  border-radius: 50%;
  border: 1px solid var(--line-strong);
  font-size: 0.76rem;
  font-weight: 600;
  letter-spacing: 0.04em;
  transition: background-color 0.35s var(--ease), color 0.35s, border-color 0.35s;
}

.size-pill:hover,
.size-btn:hover:not(:disabled) {
  border-color: var(--gold);
  color: var(--gold);
}

.size-pill.added,
.size-pill:disabled,
.size-btn.active {
  background: var(--gold);
  border-color: var(--gold);
  color: var(--bg-deep);
}

/* "One Size" (accessories) needs a pill, not a circle */
.size-pill.is-wide,
.size-btn.is-wide,
.plate-sizes .size-pill.is-wide,
.card-sizes .size-pill.is-wide {
  width: auto;
  padding: 0 1.1em;
  border-radius: 999px;
}

/* A size this piece is not made in */
.size-btn:disabled {
  color: rgba(244, 238, 232, 0.25);
  border-color: rgba(244, 238, 232, 0.1);
  background: linear-gradient(to top right, transparent 49%, rgba(244, 238, 232, 0.16) 50%, transparent 51%);
  cursor: not-allowed;
}

.round-btn {
  width: 50px;
  height: 50px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  border: 1px solid var(--line-strong);
  transition: background-color 0.35s var(--ease), color 0.35s, border-color 0.35s;
}

.round-btn:hover {
  background: var(--text-main);
  border-color: var(--text-main);
  color: var(--bg-deep);
}

/* A sale: the full price struck through, the sale price in gold */
.price-was {
  margin-right: 0.35em;
  color: var(--text-soft);
  opacity: 0.6;
  text-decoration-thickness: 1px;
}

.price-now,
.sale-word {
  color: var(--gold);
}

.swatch {
  display: inline-block;
  width: 11px;
  height: 11px;
  border-radius: 50%;
  border: 1px solid rgba(244, 238, 232, 0.35);
  flex-shrink: 0;
}


/* ============================================================
   4. HEADER
   No bar across the photographs: the house name sits in the
   top-left corner, three words in the top-right.
============================================================ */
.navbar {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 70;
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: var(--nav);
  padding: 0 var(--pad);
  color: var(--text-main);
  pointer-events: none;
}

.navbar > * {
  pointer-events: auto;
}

.nav-logo {
  display: inline-flex;
  align-items: center;
  gap: 0.85rem;
  font-family: var(--font-display);
  font-size: 1.12rem;
  letter-spacing: 0.44em;
  text-transform: uppercase;
}

.nav-logo img {
  width: 26px;
  height: auto;
  transition: transform 1.2s var(--ease);
}

.nav-logo:hover img {
  transform: rotate(-24deg);
}

.nav-actions {
  display: flex;
  align-items: center;
  gap: clamp(1.2rem, 2.4vw, 2.4rem);
}

/* The three words: Search, Cart, Menu */
.nav-word {
  position: relative;
  display: inline-flex;
  align-items: center;
  gap: 0.55rem;
  min-height: 44px;
  font-size: 0.7rem;
  font-weight: 600;
  letter-spacing: 0.26em;
  text-transform: uppercase;
  color: var(--text-main);
}

.nav-word::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0.26em;
  bottom: 9px;
  height: 1px;
  background: var(--gold);
  transform: scaleX(0);
  transform-origin: 100% 50%;
  transition: transform 0.6s var(--ease);
}

.nav-word:hover::after,
.nav-word:focus-visible::after,
.nav-word[aria-current="page"]::after {
  transform: scaleX(1);
  transform-origin: 0 50%;
}

.menu-toggle::after {
  display: none;
}

/* The count rides beside the word, small and gold */
.cart-badge {
  display: none;
  align-items: center;
  justify-content: center;
  min-width: 18px;
  height: 18px;
  padding: 0 5px;
  border-radius: 999px;
  background: var(--gold);
  color: var(--bg-deep);
  font-size: 0.6rem;
  font-weight: 700;
  letter-spacing: 0;
}

/* Menu: the word, and two lines that close into a cross */
.menu-toggle-lines {
  position: relative;
  width: 26px;
  height: 10px;
}

.menu-toggle-lines span {
  position: absolute;
  left: 0;
  width: 100%;
  height: 1px;
  background: currentColor;
  transition: transform 0.6s var(--ease), width 0.6s var(--ease), top 0.6s var(--ease);
}

.menu-toggle-lines span:first-child {
  top: 1px;
}

.menu-toggle-lines span:last-child {
  top: 8px;
  width: 60%;
  left: auto;
  right: 0;
}

.menu-toggle:hover .menu-toggle-lines span:last-child {
  width: 100%;
}

.menu-open .menu-toggle-lines span:first-child {
  top: 4.5px;
  transform: rotate(45deg);
}

.menu-open .menu-toggle-lines span:last-child {
  top: 4.5px;
  width: 100%;
  transform: rotate(-45deg);
}


/* ============================================================
   5. THE MENU ROOM
   A full-screen room: the names on the left, a photograph on
   the right that melts to each name you point at.
============================================================ */
.menu-overlay {
  position: fixed;
  inset: 0;
  z-index: 65;
  background:
    radial-gradient(ellipse 60% 70% at 70% 50%, rgba(34, 26, 36, 0.9), transparent 70%),
    var(--bg-deep);
  clip-path: inset(0 0 100% 0);
  transition: clip-path 0.9s var(--ease);
}

.menu-overlay.is-open {
  clip-path: inset(0 0 0 0);
}

.menu-inner {
  display: grid;
  grid-template-columns: minmax(0, 1.15fr) minmax(0, 0.85fr);
  grid-template-rows: 1fr auto;
  column-gap: clamp(2rem, 6vw, 6rem);
  height: 100%;
  padding: calc(var(--nav) + var(--gap-y)) var(--pad) clamp(1rem, 3vh, 2rem);
}

.menu-links {
  display: flex;
  align-items: center;
  min-height: 0;
}

.menu-links ol {
  width: 100%;
}

.menu-links a {
  display: flex;
  align-items: baseline;
  gap: 1.2rem;
  padding: clamp(0.15rem, 0.9vh, 0.5rem) 0;
}

.menu-name {
  font-family: var(--font-display);
  /* eight names have to fit the height of the screen */
  font-size: clamp(1.8rem, min(4.8vw, 6.4vh), 5.2rem);
  line-height: 1.06;
  letter-spacing: 0.03em;
  text-transform: uppercase;
  white-space: nowrap;
  color: rgba(244, 238, 232, 0.32);
  transition: color 0.5s var(--ease), transform 0.8s var(--ease);
}

.menu-note {
  font-size: 0.66rem;
  font-weight: 600;
  letter-spacing: 0.26em;
  text-transform: uppercase;
  color: var(--gold);
  white-space: nowrap;
  opacity: 0;
  transform: translateX(-8px);
  transition: opacity 0.5s var(--ease), transform 0.6s var(--ease);
}

.menu-links a.is-active .menu-name,
.menu-links a:hover .menu-name,
.menu-links a:focus-visible .menu-name {
  color: var(--text-main);
  transform: translateX(0.6rem);
}

.menu-links a.is-active .menu-note {
  opacity: 1;
  transform: none;
}

/* The page you are on is marked with a small gold crescent dot */
.menu-links a[aria-current="page"] .menu-name::after {
  content: "";
  display: inline-block;
  width: 0.14em;
  height: 0.14em;
  margin-left: 0.3em;
  vertical-align: 0.6em;
  border-radius: 50%;
  background: var(--gold);
}

.menu-media {
  position: relative;
  grid-row: 1 / span 2;
  grid-column: 2;
  min-height: 0;
}

.menu-media .liquid-box {
  position: absolute;
  inset: 0;
}

.menu-foot {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  justify-content: space-between;
  gap: 1rem 2rem;
  padding-top: clamp(0.8rem, 2.4vh, 1.4rem);
  border-top: 1px solid var(--line);
}

.menu-search {
  display: flex;
  align-items: center;
  gap: 0.8rem;
  flex: 1 1 18rem;
  max-width: 26rem;
  color: var(--gold);
  border-bottom: 1px solid var(--line-gold);
}

.menu-search input {
  flex: 1;
  min-width: 0;
  padding: 0.7rem 0;
  background: transparent;
  border: none;
  outline: none;
  font-size: 0.95rem;
  color: var(--text-main);
}

.menu-search input::placeholder {
  color: var(--text-soft);
}

.menu-search input::-webkit-search-cancel-button {
  display: none;
}

.menu-contact {
  font-size: 0.78rem;
  color: var(--text-soft);
}

.menu-contact a:hover {
  color: var(--gold);
}

body.menu-open {
  overflow: hidden;
}


/* ============================================================
   6. LIQUID IMAGE BOXES
   The images are the fallback; once WebGL is drawing, the
   canvas sits on top and the images stay for screen readers.
============================================================ */
.liquid-box {
  overflow: hidden;
  background: var(--bg-card);
}

.liquid-box img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: 50% 18%;
  opacity: 0;
  transition: opacity 0.9s var(--ease);
}

.liquid-box img.is-current {
  opacity: 1;
}

/* Only the photo on show is part of the page, so the browser downloads
   the others only when they are needed (liquid.js fetches them itself) */
.liquid-box img {
  display: none;
}

.liquid-box img.is-current,
.liquid-box:not(:has(img.is-current)) img:first-child {
  display: block;
}

/* Once the moving photograph is drawing, it covers the plain images */
.liquid-box.is-liquid img {
  display: none;
}

.liquid-canvas {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  display: block;
}


/* ============================================================
   7. PAGE FRAME — dusk under the header, reveal, footer
============================================================ */
/* A faint dusk at the top keeps the corner words legible over
   whatever scrolls beneath them */
body.page::before {
  content: "";
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 60;
  height: 120px;
  background: linear-gradient(to bottom, rgba(15, 13, 16, 0.85), rgba(15, 13, 16, 0));
  pointer-events: none;
}

/* Words that rise in when the page arrives (site.js). If the
   script never runs they appear on their own after a moment. */
.anim body.page .reveal {
  opacity: 0;
  animation: revealSafety 0s 2.5s forwards;
}

@keyframes revealSafety {
  to { opacity: 1; }
}

/* site.js fades the page out before following a link */
body {
  transition: opacity 0.35s var(--ease);
}

body.is-leaving {
  opacity: 0;
}

.site-footer {
  display: grid;
  gap: 0.6rem;
  padding: clamp(2rem, 6vh, 3.4rem) var(--pad) 2rem;
  border-top: 1px solid var(--line);
  font-size: 0.78rem;
  color: var(--text-soft);
  text-align: center;
  background: var(--bg-deep);
}

.site-footer .footer-mark {
  width: 34px;
  height: auto;
  margin: 0 auto 0.6rem;
}

.footer-links {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 0.4rem 1.8rem;
  font-size: 0.66rem;
  font-weight: 600;
  letter-spacing: 0.24em;
  text-transform: uppercase;
  color: var(--text-main);
}

.footer-links a {
  display: inline-flex;
  align-items: center;
  min-height: 32px;
}

.footer-links a:hover,
.footer-contact a:hover {
  color: var(--gold);
}

.footer-legal {
  font-size: 0.72rem;
  opacity: 0.8;
}


/* ============================================================
   8. ROOMS — the split layout every inner page uses
   .room-media holds still (sticky) while .room-body scrolls.
============================================================ */
.room {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  min-height: 100svh;
  background: var(--bg-main);
}

.room-media {
  position: sticky;
  top: 0;
  height: 100svh;
  overflow: hidden;
  background: var(--bg-card);
}

.room-media > .liquid-box {
  position: absolute;
  inset: 0;
}

.room-body {
  min-width: 0;
  padding: calc(var(--header) + var(--gap-y)) var(--pad) clamp(3rem, 9vh, 6rem);
}

/* The page title: large, uppercase, set from the screen size */
.room-title {
  font-family: var(--font-display);
  font-size: clamp(2.4rem, min(5.4vw, 9vh), 5.6rem);
  line-height: 1;
  letter-spacing: 0.02em;
  text-transform: uppercase;
  margin: clamp(0.6rem, 1.8vh, 1rem) 0 clamp(0.8rem, 2.2vh, 1.3rem);
}

.room-lede {
  max-width: 30rem;
  color: var(--text-soft);
}

/* Small "Home / Dresses / Noira" trail */
.trail {
  display: flex;
  flex-wrap: wrap;
  gap: 0.6rem;
  margin-bottom: clamp(1.2rem, 4vh, 2.4rem);
  font-size: 0.64rem;
  font-weight: 600;
  letter-spacing: 0.24em;
  text-transform: uppercase;
  color: var(--text-soft);
}

.trail a:hover {
  color: var(--gold);
}

.trail span[aria-hidden] {
  opacity: 0.5;
}

/* A plum panel that stays beside a scrolling list (cart, checkout) */
.room-side {
  position: sticky;
  top: 0;
  align-self: start;
  min-height: 100svh;
  padding: calc(var(--header) + var(--gap-y)) var(--pad) var(--gap-y);
  background:
    radial-gradient(ellipse 80% 60% at 50% 0%, rgba(198, 163, 107, 0.07), transparent 70%),
    var(--bg-card);
}

.section-head {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 1rem;
  padding-bottom: 0.9rem;
  margin-bottom: 1.6rem;
  border-bottom: 1px solid var(--line);
}

.section-title {
  font-family: var(--font-display);
  font-size: clamp(1.5rem, 2.4vw, 2.1rem);
  letter-spacing: 0.04em;
  text-transform: uppercase;
}


/* ============================================================
   9. THE INDEX — collection and search lists
   The names run down the left like the menu; the photograph on
   the right melts to the piece you point at, with its sizes.
============================================================ */
.index-room {
  grid-template-columns: minmax(0, 1.05fr) minmax(0, 0.95fr);
}

.index-head {
  margin-bottom: clamp(1.2rem, 4vh, 2.6rem);
}

.index-tools {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 0.8rem 1.6rem;
  padding: 0.6rem 0;
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
}

.index-tools-left {
  display: flex;
  align-items: center;
  gap: 1.6rem;
}

.result-count {
  font-size: 0.66rem;
  font-weight: 600;
  letter-spacing: 0.24em;
  text-transform: uppercase;
  color: var(--text-soft);
}

.index-list {
  counter-reset: piece;
  margin-top: clamp(0.6rem, 2vh, 1.2rem);
}

.index-row {
  position: relative;
  counter-increment: piece;
  border-bottom: 1px solid var(--line);
}

.index-link {
  display: grid;
  grid-template-columns: 2.4rem minmax(0, 1fr) auto;
  align-items: baseline;
  column-gap: 1rem;
  padding: clamp(0.55rem, 1.6vh, 0.95rem) 0;
}

.index-link::before {
  content: counter(piece, decimal-leading-zero);
  font-size: 0.66rem;
  font-weight: 600;
  letter-spacing: 0.12em;
  color: var(--text-soft);
  font-variant-numeric: tabular-nums;
}

.index-thumb {
  display: none;
}

.index-name {
  font-family: var(--font-display);
  font-size: clamp(1.25rem, min(2vw, 4.4vh), 2.2rem);
  line-height: 1.08;
  letter-spacing: 0.02em;
  text-transform: uppercase;
  color: rgba(244, 238, 232, 0.36);
  transition: color 0.5s var(--ease), transform 0.8s var(--ease);
}

.index-price {
  font-family: var(--font-display);
  font-size: 0.95rem;
  letter-spacing: 0.06em;
  color: var(--text-soft);
  white-space: nowrap;
  text-align: right;
  transition: color 0.5s var(--ease);
}

.index-row.is-active .index-name,
.index-link:hover .index-name,
.index-link:focus-visible .index-name {
  color: var(--text-main);
  transform: translateX(0.5rem);
}

.index-row.is-active .index-link::before {
  color: var(--gold);
}

.index-row.is-active .index-price {
  color: var(--gold);
}

/* On a wide screen the heart lives on the photograph's plate */
.index-row .wishlist-btn {
  display: none;
}

/* The photograph and its plate */
.index-media::after {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  background: linear-gradient(to top, rgba(15, 13, 16, 0.92) 0%, rgba(15, 13, 16, 0.4) 26%, rgba(15, 13, 16, 0) 46%);
}

.index-plate {
  position: absolute;
  left: clamp(1.25rem, 3vw, 2.6rem);
  right: clamp(1.25rem, 3vw, 2.6rem);
  bottom: clamp(1.25rem, 4vh, 2.6rem);
  z-index: 2;
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: end;
  gap: 0.6rem 1.4rem;
}

.plate-category {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.64rem;
  font-weight: 600;
  letter-spacing: 0.28em;
  text-transform: uppercase;
  color: var(--text-soft);
}

.plate-name {
  font-family: var(--font-display);
  font-size: clamp(1.5rem, min(2.4vw, 4.4vh), 2.4rem);
  line-height: 1.04;
  letter-spacing: 0.02em;
  text-transform: uppercase;
  margin: 0.3rem 0 0.4rem;
}

.plate-name a:hover {
  color: var(--gold);
}

.plate-price {
  font-family: var(--font-display);
  letter-spacing: 0.06em;
  color: var(--gold);
}

.plate-sizes {
  grid-column: 1 / -1;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.45rem;
}

.plate-sizes .size-pill {
  width: 42px;
  height: 42px;
  background: rgba(15, 13, 16, 0.4);
}

.plate-sizes .size-pill.added {
  background: var(--gold);
}

.plate-label {
  margin-right: 0.6rem;
  font-size: 0.62rem;
  font-weight: 600;
  letter-spacing: 0.24em;
  text-transform: uppercase;
  color: var(--text-soft);
}

.plate-actions {
  display: flex;
  align-items: center;
  gap: 0.8rem;
  align-self: start;
}

.plate-actions .wishlist-btn {
  position: static;
}

/* Collections page: a line about the collection and four of its pieces */
.plate-text {
  max-width: 28rem;
  font-size: 0.9rem;
  line-height: 1.6;
  color: var(--text-soft);
}

.plate-pieces {
  grid-column: 1 / -1;
  display: flex;
  gap: 0.5rem;
  margin-top: 0.4rem;
}

.plate-pieces a {
  display: block;
  width: 54px;
  aspect-ratio: 3 / 4;
  overflow: hidden;
  border: 1px solid rgba(244, 238, 232, 0.25);
  transition: border-color 0.35s var(--ease);
}

.plate-pieces a:hover,
.plate-pieces a:focus-visible {
  border-color: var(--gold);
}

.plate-pieces img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: 50% 12%;
}

/* Fewer, larger names than a collection's list of pieces */
@media (min-width: 861px) {
  .collection-index .index-name {
    font-size: clamp(1.6rem, min(3vw, 6vh), 3.2rem);
  }
}


/* ============================================================
   9b. LEDGER ROOMS — cart + checkout
   The list or form on the left, the summary holding still on
   the right.
============================================================ */
.ledger-room {
  grid-template-columns: minmax(0, 1.35fr) minmax(22rem, 0.65fr);
}

.ledger-room .room-body {
  padding-right: clamp(1.5rem, 5vw, 5rem);
}


/* ---------- The summary ---------- */
.summary-rows {
  margin-top: 1.4rem;
}

.summary-row {
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  padding: 0.8rem 0;
  border-bottom: 1px solid var(--line);
  font-size: 0.92rem;
}

.summary-row dt {
  color: var(--text-soft);
}

.summary-total {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 1rem;
  margin: clamp(1.2rem, 4vh, 2.2rem) 0 clamp(1rem, 3vh, 1.6rem);
}

.summary-total span:first-child {
  font-size: 0.66rem;
  font-weight: 600;
  letter-spacing: 0.26em;
  text-transform: uppercase;
  color: var(--text-soft);
}

.summary-total span:last-child {
  font-family: var(--font-display);
  font-size: clamp(1.8rem, 3vw, 2.6rem);
  letter-spacing: 0.04em;
}

.delivery-track {
  position: relative;
  height: 1px;
  margin-bottom: 0.8rem;
  background: var(--line-strong);
}

.delivery-track span {
  position: absolute;
  left: 0;
  top: -0.5px;
  height: 2px;
  width: 0;
  background: var(--gold);
  transition: width 1s var(--ease);
}

.summary-note {
  margin-bottom: 1.6rem;
  font-size: 0.82rem;
  color: var(--text-soft);
}

.summary-message {
  min-height: 1.3rem;
  margin-top: 0.8rem;
  font-size: 0.84rem;
  color: var(--gold);
}

.summary-message.error {
  color: var(--error);
}


/* ============================================================
   10. PRODUCT CARDS — saved pieces, related pieces
============================================================ */
.product-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(min(100%, 13rem), 1fr));
  gap: 2.4rem 1rem;
}

.product-card {
  position: relative;
}

.product-frame {
  position: relative;
}

.product-image-link {
  display: block;
}

.product-image {
  position: relative;
  aspect-ratio: 3 / 4;
  overflow: hidden;
  background: var(--bg-card);
}

.product-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: 50% 15%;
  transition: transform 1.4s var(--ease), filter 0.8s var(--ease);
}

.product-card:hover .product-image img {
  transform: scale(1.04);
}

.product-info,
.product-info-card {
  padding-top: 0.9rem;
}

.product-card-category {
  font-size: 0.62rem;
  font-weight: 600;
  letter-spacing: 0.26em;
  text-transform: uppercase;
  color: var(--text-soft);
  margin-bottom: 0.3rem;
}

.product-card .product-name {
  font-family: var(--font-display);
  font-size: 1rem;
  line-height: 1.25;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.product-card .product-name a:hover {
  color: var(--gold);
}

.product-card .product-price {
  margin-top: 0.25rem;
  font-family: var(--font-display);
  font-size: 0.92rem;
  letter-spacing: 0.06em;
  color: var(--gold);
}

/* Sizes rise over the photograph on hover; on touch they sit below */
.card-sizes {
  position: absolute;
  left: 0.6rem;
  right: 0.6rem;
  bottom: 0.6rem;
  z-index: 2;
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem;
  opacity: 0;
  transform: translateY(8px);
  transition: opacity 0.5s var(--ease), transform 0.6s var(--ease);
}

.product-card:hover .card-sizes,
.product-card:focus-within .card-sizes {
  opacity: 1;
  transform: none;
}

.card-sizes .size-pill {
  width: 36px;
  height: 36px;
  font-size: 0.66rem;
  background: rgba(15, 13, 16, 0.72);
  border-color: rgba(244, 238, 232, 0.4);
}

.card-sizes .size-pill.added {
  background: var(--gold);
}

@media (hover: none) {
  .card-sizes {
    position: static;
    margin-top: 0.7rem;
    opacity: 1;
    transform: none;
  }

  .card-sizes .size-pill {
    background: transparent;
  }
}


/* ============================================================
   11. FILTERS + SORT
============================================================ */
.filter-toggle {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  min-height: 40px;
  font-size: 0.66rem;
  font-weight: 600;
  letter-spacing: 0.24em;
  text-transform: uppercase;
  color: var(--text-main);
}

.filter-toggle:hover,
.filter-toggle[aria-expanded="true"] {
  color: var(--gold);
}

.filter-toggle-lines {
  position: relative;
  width: 16px;
  height: 9px;
  border-top: 1px solid currentColor;
  border-bottom: 1px solid currentColor;
}

.filter-count {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 18px;
  height: 18px;
  padding: 0 5px;
  border-radius: 999px;
  background: var(--gold);
  color: var(--bg-deep);
  font-size: 0.6rem;
  font-weight: 700;
  letter-spacing: 0;
}

.filter-panel {
  padding: 1.4rem 0 0.4rem;
  border-bottom: 1px solid var(--line);
  animation: filterIn 0.5s var(--ease);
}

@keyframes filterIn {
  from { opacity: 0; transform: translateY(-6px); }
  to   { opacity: 1; transform: none; }
}

.filter-panel-inner {
  display: grid;
  gap: 1.2rem;
}

.filter-group {
  display: grid;
  grid-template-columns: 5rem minmax(0, 1fr);
  align-items: baseline;
  gap: 0.8rem;
}

.filter-label {
  font-size: 0.62rem;
  font-weight: 600;
  letter-spacing: 0.26em;
  text-transform: uppercase;
  color: var(--text-soft);
}

.filter-options {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
}

.filter-chip {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  min-height: 34px;
  padding: 0 0.9rem;
  font-size: 0.72rem;
  letter-spacing: 0.06em;
  color: var(--text-main);
  border: 1px solid var(--line);
  transition: border-color 0.35s var(--ease), color 0.35s, background-color 0.35s;
}

.filter-chip:hover {
  border-color: var(--gold);
  color: var(--gold);
}

.filter-chip.active {
  background: var(--gold);
  border-color: var(--gold);
  color: var(--bg-deep);
}

.filter-actions {
  padding: 0.4rem 0 1rem 5.8rem;
}

.filter-actions .btn {
  min-height: 0;
  padding: 0 0 0.3rem;
  border: none;
  border-bottom: 1px solid var(--line-gold);
  font-size: 0.64rem;
}

.filter-actions .btn:hover {
  background: none;
  color: var(--gold);
}

.sort-control {
  display: flex;
  align-items: center;
  gap: 0.8rem;
}

.sort-control label {
  font-size: 0.62rem;
  font-weight: 600;
  letter-spacing: 0.24em;
  text-transform: uppercase;
  color: var(--text-soft);
}

.sort-control select,
.select {
  appearance: none;
  -webkit-appearance: none;
  min-height: 40px;
  padding: 0 1.6rem 0 0;
  background: transparent url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='10' height='6' fill='none' stroke='%23C6A36B' stroke-width='1.2'%3E%3Cpath d='M1 1l4 4 4-4'/%3E%3C/svg%3E") no-repeat right 0.2rem center;
  border: none;
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--text-main);
  cursor: pointer;
}

.sort-control select option,
.select option {
  background: var(--bg-card);
  color: var(--text-main);
  text-transform: none;
}


/* ============================================================
   12. FORMS
   Hairline fields: a label above, a line below.
============================================================ */
.field,
.form-group {
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
  margin-bottom: 1.4rem;
}

.field label,
.form-group label {
  font-size: 0.62rem;
  font-weight: 600;
  letter-spacing: 0.24em;
  text-transform: uppercase;
  color: var(--text-soft);
}

.optional {
  letter-spacing: 0.1em;
  text-transform: none;
  opacity: 0.7;
}

.field input,
.field select,
.field textarea,
.form-group input,
.form-group textarea {
  width: 100%;
  padding: 0.7rem 0;
  background: transparent;
  border: none;
  border-bottom: 1px solid var(--line-strong);
  border-radius: 0;
  font-size: 0.98rem;
  color: var(--text-main);
  transition: border-color 0.4s var(--ease);
}

.field textarea,
.form-group textarea {
  resize: vertical;
  min-height: 3rem;
}

.field input::placeholder,
.field textarea::placeholder,
.form-group input::placeholder,
.form-group textarea::placeholder {
  color: rgba(185, 168, 174, 0.55);
}

.field input:focus,
.field select:focus,
.field textarea:focus,
.form-group input:focus,
.form-group textarea:focus {
  outline: none;
  border-color: var(--gold);
}

.field.error input,
.field.error textarea,
.form-group.error input,
.form-group.error textarea {
  border-color: var(--error);
}

.field-error,
.form-error {
  min-height: 1.1rem;
  font-size: 0.76rem;
  color: var(--error);
}

.field-row {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0 1.6rem;
}

input[type="checkbox"],
input[type="radio"] {
  accent-color: var(--gold);
  width: 16px;
  height: 16px;
  flex-shrink: 0;
}

.form-check,
.form-checkbox {
  display: flex;
  align-items: center;
  gap: 0.7rem;
  font-size: 0.86rem;
  color: var(--text-soft);
  cursor: pointer;
}

/* A choice row: radio, title + note, price */
.choice {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  align-items: center;
  gap: 1rem;
  padding: 1rem 1.1rem;
  margin-bottom: 0.6rem;
  border: 1px solid var(--line);
  cursor: pointer;
  transition: border-color 0.4s var(--ease), background-color 0.4s var(--ease);
}

.choice:hover {
  border-color: var(--line-strong);
}

.choice:has(input:checked) {
  border-color: var(--gold);
  background: rgba(198, 163, 107, 0.06);
}

.choice-body {
  display: flex;
  flex-direction: column;
}

.choice-title {
  font-size: 0.74rem;
  font-weight: 600;
  letter-spacing: 0.18em;
  text-transform: uppercase;
}

.choice-text {
  font-size: 0.84rem;
  color: var(--text-soft);
}

.choice-price {
  font-family: var(--font-display);
  letter-spacing: 0.06em;
  color: var(--gold);
}

.form-feedback,
.form-success {
  min-height: 1.4rem;
  margin-top: 0.8rem;
  font-size: 0.86rem;
  color: var(--gold);
}

.form-feedback.error {
  color: var(--error);
}

/* Quantity: − 1 + */
.qty-control {
  display: inline-flex;
  align-items: center;
  border: 1px solid var(--line-strong);
}

.qty-btn {
  width: 40px;
  height: 40px;
  font-size: 1rem;
  transition: color 0.3s;
}

.qty-btn:hover:not(:disabled) {
  color: var(--gold);
}

.qty-btn:disabled {
  opacity: 0.3;
  cursor: default;
}

.qty-value {
  min-width: 2rem;
  text-align: center;
  font-size: 0.9rem;
  font-variant-numeric: tabular-nums;
}


/* ============================================================
   13. TOAST, HEART, MODAL, EMPTY STATE
============================================================ */
.toast {
  position: fixed;
  left: 50%;
  bottom: 1.6rem;
  z-index: 500;
  max-width: calc(100% - 2rem);
  padding: 0.95rem 1.4rem;
  background: var(--bg-card);
  border: 1px solid var(--line-gold);
  font-size: 0.86rem;
  color: var(--text-main);
  box-shadow: 0 18px 50px rgba(0, 0, 0, 0.5);
  opacity: 0;
  visibility: hidden;
  transform: translate(-50%, 16px);
  transition: opacity var(--transition), transform var(--transition), visibility var(--transition);
}

.toast.show {
  opacity: 1;
  visibility: visible;
  transform: translate(-50%, 0);
}

.toast a {
  margin-left: 0.7rem;
  font-size: 0.66rem;
  font-weight: 600;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--gold);
  border-bottom: 1px solid currentColor;
}

.wishlist-btn {
  position: absolute;
  top: 0.7rem;
  right: 0.7rem;
  z-index: 3;
  width: 40px;
  height: 40px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  background: rgba(15, 13, 16, 0.55);
  border: 1px solid rgba(244, 238, 232, 0.25);
  color: var(--text-main);
  transition: color 0.35s, border-color 0.35s, background-color 0.35s;
}

.wishlist-btn:hover {
  color: var(--gold);
  border-color: var(--gold);
}

.wishlist-btn.saved {
  color: var(--gold);
  border-color: var(--gold);
}

.wishlist-btn.saved svg {
  fill: var(--gold);
}

.modal {
  position: fixed;
  inset: 0;
  z-index: 600;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1.2rem;
  background: rgba(15, 13, 16, 0.82);
  animation: modalFade 0.4s var(--ease);
}

@keyframes modalFade {
  from { opacity: 0; }
  to   { opacity: 1; }
}

.modal-dialog {
  position: relative;
  width: 100%;
  max-width: 560px;
  max-height: 90vh;
  overflow-y: auto;
  padding: 2.6rem 2.2rem 2.2rem;
  background: var(--bg-card);
  border: 1px solid var(--line-gold);
}

.modal-close {
  position: absolute;
  top: 0.8rem;
  right: 0.8rem;
  width: 44px;
  height: 44px;
  font-size: 1.5rem;
  color: var(--text-soft);
  transition: color 0.3s;
}

.modal-close:hover {
  color: var(--gold);
}

.modal-title {
  font-family: var(--font-display);
  font-size: 2rem;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  margin: 0.5rem 0;
}

.modal-text {
  margin-bottom: 1.4rem;
  font-size: 0.9rem;
  color: var(--text-soft);
}

.size-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.88rem;
}

.size-table th,
.size-table td {
  padding: 0.75rem 0.5rem;
  text-align: center;
  border-bottom: 1px solid var(--line);
}

.size-table th {
  font-size: 0.62rem;
  font-weight: 600;
  letter-spacing: 0.24em;
  text-transform: uppercase;
  color: var(--gold);
}

.size-table tr td:first-child {
  font-family: var(--font-display);
  color: var(--gold);
}

.empty-state {
  padding: clamp(2.4rem, 8vh, 4rem) 0;
  color: var(--text-soft);
}

.empty-state h2 {
  font-family: var(--font-display);
  font-size: clamp(1.5rem, 3vw, 2.2rem);
  letter-spacing: 0.03em;
  text-transform: uppercase;
  color: var(--text-main);
  margin-bottom: 0.7rem;
}

.empty-state p {
  margin-bottom: 1.4rem;
}

/* A quiet, centred room for "nothing here yet" and "thank you" moments */
.still-room {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  min-height: 100svh;
  padding: calc(var(--header) + var(--gap-y)) var(--pad) var(--gap-y);
  text-align: center;
  background:
    radial-gradient(ellipse 50% 55% at 50% 45%, rgba(34, 26, 36, 0.95), transparent 70%),
    var(--bg-deep);
}

.still-room .still-mark {
  width: clamp(40px, 6vh, 58px);
  height: auto;
  margin-bottom: clamp(1rem, 3vh, 1.8rem);
}

.still-room .room-title {
  margin-top: 0.8rem;
}

.still-room .room-lede {
  margin: 0 auto clamp(1.4rem, 4vh, 2.4rem);
}

.still-actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 0.7rem;
}


/* ============================================================
   13b. LAYERS — bag drawer, quick view, zoom
   Built by site.js on first use. Each slides or fades in over a
   deep scrim; the page underneath stops scrolling.
============================================================ */
body.layer-open {
  overflow: hidden;
}

.layer {
  position: fixed;
  inset: 0;
  z-index: 400;
}

/* While a layer fades out it no longer catches clicks */
.layer:not(.is-open) {
  pointer-events: none;
}

.layer-scrim {
  position: absolute;
  inset: 0;
  background: rgba(15, 13, 16, 0.72);
  opacity: 0;
  transition: opacity 0.6s var(--ease);
}

.layer.is-open .layer-scrim {
  opacity: 1;
}

/* Sold-out sizes: struck through, still focusable so they can be announced */
.size-pill.is-sold-out {
  color: rgba(244, 238, 232, 0.3);
  border-color: rgba(244, 238, 232, 0.12);
  background: linear-gradient(to top right, transparent 49%, rgba(244, 238, 232, 0.2) 50%, transparent 51%);
  cursor: not-allowed;
}

.size-pill.is-sold-out:hover {
  color: rgba(244, 238, 232, 0.3);
  border-color: rgba(244, 238, 232, 0.12);
}

/* ---------- Quick view button on cards ---------- */
.quick-btn {
  position: absolute;
  top: 0.7rem;
  left: 0.7rem;
  z-index: 3;
  min-height: 40px;
  padding: 0 0.9rem;
  background: rgba(15, 13, 16, 0.62);
  border: 1px solid rgba(244, 238, 232, 0.25);
  font-size: 0.6rem;
  font-weight: 600;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--text-main);
  opacity: 0;
  transform: translateY(-4px);
  transition: opacity 0.4s var(--ease), transform 0.5s var(--ease), border-color 0.3s, color 0.3s;
}

.product-card:hover .quick-btn,
.quick-btn:focus-visible {
  opacity: 1;
  transform: none;
}

.quick-btn:hover {
  color: var(--gold);
  border-color: var(--gold);
}

@media (hover: none) {
  .quick-btn {
    opacity: 1;
    transform: none;
  }
}

/* On a wide screen the index has its plate instead */
@media (min-width: 861px) {
  .index-row .quick-btn {
    display: none;
  }
}

/* ---------- The bag drawer ---------- */
.bag {
  position: absolute;
  top: 0;
  right: 0;
  bottom: 0;
  display: flex;
  flex-direction: column;
  width: min(30rem, 100%);
  background:
    radial-gradient(ellipse 90% 40% at 50% 0%, rgba(198, 163, 107, 0.06), transparent 70%),
    var(--bg-card);
  border-left: 1px solid var(--line);
  transform: translateX(100%);
  transition: transform 0.7s var(--ease);
}

.bag-layer.is-open .bag {
  transform: none;
}

.bag-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  min-height: var(--nav);
  padding: 0 clamp(1.25rem, 3vw, 2rem);
  border-bottom: 1px solid var(--line);
}

.bag-title {
  font-family: var(--font-display);
  font-size: 1.3rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.bag-title span {
  color: var(--gold);
}

.bag-close::after {
  display: none;
}

.bag-close:hover {
  color: var(--gold);
}

.bag-added {
  padding: 0 clamp(1.25rem, 3vw, 2rem);
  font-size: 0.82rem;
  color: var(--gold);
}

.bag-added:not(:empty) {
  padding-top: 1rem;
}

.bag-lines {
  flex: 1;
  overflow-y: auto;
  overscroll-behavior: contain;
  padding: 0.4rem clamp(1.25rem, 3vw, 2rem);
}

.bag-line {
  display: grid;
  grid-template-columns: 72px minmax(0, 1fr) auto;
  align-items: start;
  gap: 1rem;
  padding: 1.1rem 0;
  border-bottom: 1px solid var(--line);
}

.bag-line-image img {
  width: 72px;
  aspect-ratio: 3 / 4;
  object-fit: cover;
  object-position: 50% 15%;
}

.bag-line-name {
  font-family: var(--font-display);
  font-size: 0.98rem;
  line-height: 1.25;
  letter-spacing: 0.05em;
  text-transform: uppercase;
}

.bag-line-name a:hover {
  color: var(--gold);
}

.bag-line-meta {
  margin: 0.2rem 0 0.7rem;
  font-size: 0.8rem;
  color: var(--text-soft);
}

.bag-line-row {
  display: flex;
  align-items: center;
  gap: 1rem;
}

.bag-line-row .qty-btn {
  width: 34px;
  height: 34px;
}

.bag-line-total {
  font-family: var(--font-display);
  font-size: 0.92rem;
  letter-spacing: 0.05em;
  white-space: nowrap;
}

.remove-btn {
  min-height: 40px;
  font-size: 0.62rem;
  font-weight: 600;
  letter-spacing: 0.24em;
  text-transform: uppercase;
  color: var(--text-soft);
  transition: color 0.3s;
}

.remove-btn:hover {
  color: var(--error);
}

.bag-empty {
  display: grid;
  justify-items: start;
  gap: 1rem;
  padding: 2.4rem 0;
}

.bag-empty-title {
  font-family: var(--font-display);
  font-size: 1.6rem;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.bag-foot {
  display: grid;
  gap: 0.8rem;
  padding: 1.2rem clamp(1.25rem, 3vw, 2rem) clamp(1.2rem, 3vh, 1.8rem);
  border-top: 1px solid var(--line);
}

.bag-subtotal {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  font-size: 0.66rem;
  font-weight: 600;
  letter-spacing: 0.24em;
  text-transform: uppercase;
  color: var(--text-soft);
}

.bag-subtotal span:last-child {
  font-family: var(--font-display);
  font-size: 1.5rem;
  font-weight: 400;
  letter-spacing: 0.04em;
  text-transform: none;
  color: var(--text-main);
}

.bag-foot .delivery-track {
  margin: 0;
}

.bag-foot .summary-note {
  margin: 0 0 0.4rem;
}

.bag-view {
  justify-self: center;
}

/* ---------- Quick view ---------- */
.quick {
  position: absolute;
  left: 50%;
  top: 50%;
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  width: min(62rem, calc(100% - 2rem));
  max-height: calc(100svh - 2rem);
  overflow: hidden;
  background: var(--bg-main);
  border: 1px solid var(--line);
  opacity: 0;
  transform: translate(-50%, calc(-50% + 18px));
  transition: opacity 0.5s var(--ease), transform 0.7s var(--ease);
}

.quick-layer.is-open .quick {
  opacity: 1;
  transform: translate(-50%, -50%);
}

.quick-close {
  position: absolute;
  top: 0.4rem;
  right: 1.2rem;
  z-index: 2;
}

.quick-close::after {
  display: none;
}

.quick-close:hover {
  color: var(--gold);
}

.quick-media {
  position: relative;
  min-height: 0;
  background: var(--bg-card);
}

.quick-frames {
  position: relative;
  height: 100%;
  min-height: 26rem;
}

.quick-frames img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: 50% 12%;
  opacity: 0;
  transition: opacity 0.6s var(--ease);
}

.quick-frames img.is-current {
  opacity: 1;
}

.quick-thumbs {
  position: absolute;
  left: 1rem;
  bottom: 1rem;
  display: flex;
  gap: 0.4rem;
}

.quick-thumb {
  width: 40px;
  aspect-ratio: 3 / 4;
  overflow: hidden;
  opacity: 0.55;
  outline: 1px solid transparent;
  outline-offset: 2px;
}

.quick-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.quick-thumb[aria-pressed="true"] {
  opacity: 1;
  outline-color: var(--gold);
}

.quick-body {
  overflow-y: auto;
  padding: clamp(2.6rem, 6vh, 3.4rem) clamp(1.4rem, 3.4vw, 2.6rem) clamp(1.6rem, 4vh, 2.4rem);
}

.quick-name {
  margin: 0.6rem 0 0.5rem;
  font-family: var(--font-display);
  font-size: clamp(1.8rem, 3vw, 2.6rem);
  line-height: 1.04;
  letter-spacing: 0.02em;
  text-transform: uppercase;
}

.quick-price {
  font-family: var(--font-display);
  font-size: 1.3rem;
  letter-spacing: 0.06em;
  color: var(--gold);
  margin-bottom: 1rem;
}

.quick-short {
  margin-bottom: 1.2rem;
  font-size: 0.92rem;
  color: var(--text-soft);
}

.quick-colour {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  margin-bottom: 1.4rem;
  font-size: 0.88rem;
}

.quick-colour .option-label {
  margin-right: 0.5rem;
}

.option-label {
  font-size: 0.62rem;
  font-weight: 600;
  letter-spacing: 0.24em;
  text-transform: uppercase;
  color: var(--text-soft);
}

.quick-label {
  margin-bottom: 0.7rem;
}

.quick-sizes {
  display: flex;
  flex-wrap: wrap;
  gap: 0.45rem;
}

.quick-stock {
  min-height: 1.3rem;
  margin: 0.7rem 0 1.4rem;
  font-size: 0.78rem;
  color: var(--gold);
}

.quick-actions {
  display: flex;
  align-items: center;
  gap: 1rem;
}

.quick-heart {
  position: static;
}

/* ---------- Zoom ---------- */
.zoom-layer {
  background: var(--bg-deep);
  opacity: 0;
  transition: opacity 0.5s var(--ease);
}

.zoom-layer.is-open {
  opacity: 1;
}

.zoom {
  position: absolute;
  inset: 0;
}

.zoom-stage {
  position: absolute;
  inset: 0;
  display: flex;
  overflow: hidden;
  cursor: zoom-in;
}

.zoom-stage img {
  height: 100%;
  width: auto;
  max-width: 100%;
  margin: auto;
  object-fit: contain;
}

.zoom-stage.is-zoomed {
  display: block;
  overflow: auto;
  cursor: zoom-out;
  scrollbar-width: none;
}

.zoom-stage.is-zoomed::-webkit-scrollbar {
  display: none;
}

.zoom-stage.is-zoomed img {
  width: max(100%, 180vh);
  height: auto;
  max-width: none;
}

.zoom-close {
  position: absolute;
  top: 0.8rem;
  right: var(--pad);
}

.zoom-close::after {
  display: none;
}

.zoom-close:hover {
  color: var(--gold);
}

.zoom-prev,
.zoom-next {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  background: rgba(15, 13, 16, 0.5);
}

.zoom-prev {
  left: var(--pad);
}

.zoom-next {
  right: var(--pad);
}

.zoom-count,
.zoom-hint {
  position: absolute;
  bottom: 1.2rem;
  font-size: 0.62rem;
  font-weight: 600;
  letter-spacing: 0.24em;
  text-transform: uppercase;
  color: var(--text-soft);
  pointer-events: none;
}

.zoom-count {
  left: var(--pad);
}

.zoom-hint {
  right: var(--pad);
}

@media (max-width: 760px) {
  .quick {
    top: auto;
    bottom: 0;
    left: 0;
    grid-template-columns: 1fr;
    grid-template-rows: 46svh auto;
    width: 100%;
    max-height: 92svh;
    transform: translateY(24px);
    border-left: none;
    border-right: none;
    border-bottom: none;
  }

  .quick-layer.is-open .quick {
    transform: none;
  }

  .quick-frames {
    min-height: 0;
  }

  .quick-close {
    top: 0.5rem;
    right: 0.8rem;
    padding: 0 0.6rem;
    background: rgba(15, 13, 16, 0.6);
  }

  .quick-body {
    padding-top: 1.4rem;
  }

  .zoom-hint {
    display: none;
  }

  .zoom-prev,
  .zoom-next {
    width: 44px;
    height: 44px;
  }
}


/* ============================================================
   14. TABLETS + PHONES
============================================================ */
@media (max-width: 960px) {
  .menu-inner {
    grid-template-columns: 1fr;
  }

  .menu-media {
    display: none;
  }

  .menu-note {
    opacity: 1;
    transform: none;
    color: var(--text-soft);
  }
}

@media (max-width: 960px) {
  .ledger-room {
    grid-template-columns: 1fr;
  }

  .ledger-room .room-side {
    position: static;
    min-height: 0;
    padding-top: var(--gap-y);
  }
}

@media (max-width: 860px) {
  :root {
    --nav: 60px;
  }

  .nav-logo {
    font-size: 0.95rem;
    letter-spacing: 0.34em;
    gap: 0.6rem;
  }

  .nav-logo img {
    width: 22px;
  }

  .nav-actions {
    gap: 1rem;
  }

  /* On a phone the search lives inside the menu */
  #searchOpen {
    display: none;
  }

  .menu-toggle-word {
    position: absolute;
    width: 1px;
    height: 1px;
    overflow: hidden;
    clip: rect(0 0 0 0);
  }

  .menu-name {
    font-size: clamp(1.5rem, min(9vw, 4.6vh), 2.6rem);
  }

  .menu-links a {
    flex-direction: column;
    gap: 0.1rem;
    padding: clamp(0.25rem, 0.9vh, 0.55rem) 0;
  }

  /* A very short phone scrolls the menu instead of overlapping it */
  .menu-inner {
    grid-template-rows: minmax(min-content, 1fr) auto;
    overflow-y: auto;
  }

  .menu-note {
    font-size: 0.6rem;
  }

  .menu-links a.is-active .menu-name,
  .menu-links a:hover .menu-name {
    transform: none;
  }

  body.page::before {
    height: 90px;
  }

  /* Rooms stack: the still half goes on top (or away) */
  .room {
    grid-template-columns: 1fr;
  }

  .room-media {
    position: relative;
    height: 68svh;
  }

  .room-side {
    position: static;
    min-height: 0;
    padding-top: var(--gap-y);
  }

  .room-title {
    font-size: clamp(2.2rem, 11vw, 3.2rem);
  }

  /* The index becomes a two-column lookbook of photographs */
  .index-room .room-media {
    display: none;
  }

  .index-list {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 1.8rem 0.8rem;
    margin-top: 1.4rem;
  }

  .index-row {
    border-bottom: none;
  }

  .index-link {
    display: flex;
    flex-direction: column;
    padding: 0;
  }

  .index-link::before {
    display: none;
  }

  .index-thumb {
    display: block;
    width: 100%;
    height: auto;
    aspect-ratio: 3 / 4;
    object-fit: cover;
    object-position: 50% 15%;
    margin-bottom: 0.8rem;
    background: var(--bg-card);
  }

  .index-name {
    font-size: 0.95rem;
    line-height: 1.25;
    letter-spacing: 0.06em;
    color: var(--text-main);
  }

  .index-row.is-active .index-name,
  .index-link:hover .index-name {
    transform: none;
  }

  .index-price {
    margin-top: 0.2rem;
    text-align: left;
    color: var(--gold);
  }

  .index-row .wishlist-btn {
    display: flex;
  }

  .filter-group {
    grid-template-columns: 1fr;
    gap: 0.5rem;
  }

  .filter-actions {
    padding-left: 0;
  }

  .field-row {
    grid-template-columns: 1fr;
  }

  .modal-dialog {
    padding: 2.4rem 1.3rem 1.6rem;
  }
}

@media (max-width: 420px) {
  .index-tools-left {
    gap: 1rem;
  }

  .sort-control label {
    display: none;
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }
}
