:root {
  /* Pages: warm ivory. Frame (top bar, header, footer): black with the logo's ivory. */
  --paper: #FAF8F3;
  --stone: #EEE8DC;
  --mist: #E2DACB;
  --line: #D3C9B8;
  --ink: #000;
  --muted: #6E675C;
  --faint: #B4AC9F;
  --ivory: #F3EDE2;        /* text and logo on black */
  --ivory-muted: #A39C90;  /* quieter text on black */
  --frame-line: #2A2723;   /* hairlines on black */
  --error: #9B2C2C;

  --font: "Jost", "Helvetica Neue", Arial, sans-serif;
  --serif: "Cormorant Garamond", "Cormorant", Garamond, "Times New Roman", serif;
  --gutter: clamp(16px, 2.4vw, 48px);
  --col-gap: clamp(8px, 0.8vw, 16px);
  --topbar-h: 34px;
  --header-h: 76px;
  --ease: cubic-bezier(.2, .7, .1, 1);
}

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

html {
  scroll-behavior: smooth;
  scroll-padding-top: calc(var(--header-h) + 12px);
  -webkit-text-size-adjust: 100%;
}
:root:has(dialog[open]) { overflow: hidden; }

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--font);
  font-size: 16px;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
}

img { display: block; max-width: 100%; }
button { font: inherit; color: inherit; background: none; border: 0; padding: 0; cursor: pointer; }
a { color: inherit; text-decoration: none; }
h1, h2, h3, h4, p { margin: 0; }
input, select { font: inherit; color: inherit; }
:focus-visible { outline: 1.5px solid var(--ink); outline-offset: 3px; }

.visually-hidden {
  position: absolute; width: 1px; height: 1px; margin: -1px; padding: 0;
  overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0;
}
.skip {
  position: absolute; left: 12px; top: -60px; z-index: 100;
  background: var(--ink); color: #fff; padding: 10px 16px; font-size: 14px;
}
.skip:focus { top: 12px; }

svg { width: 22px; height: 22px; fill: none; stroke: currentColor; stroke-width: 1.4; stroke-linecap: round; stroke-linejoin: round; }

.icon-btn { position: relative; display: inline-grid; place-items: center; width: 40px; height: 40px; }

.text-link {
  font-size: 14px;
  text-decoration: underline;
  text-underline-offset: 5px;
  text-decoration-thickness: 1px;
}
.text-link:hover { text-decoration-thickness: 2px; }

.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  height: 50px; padding: 0 28px;
  background: var(--ink); color: #fff;
  font-size: 14px; font-weight: 500; letter-spacing: .04em;
  border: 1px solid var(--ink); border-radius: 2px;
  transition: background .2s, color .2s;
}
.btn:hover { background: #2a2a2a; }
.btn-ghost { background: transparent; color: var(--ink); }
.btn-ghost:hover { background: var(--ink); color: #fff; }
.btn-block { width: 100%; }
.btn-lg { height: 58px; font-size: 15px; }

/* ---------- Top bar & header: the black frame ---------- */

.topbar {
  display: grid; grid-template-columns: 1fr auto 1fr; align-items: center;
  height: var(--topbar-h); padding: 0 var(--gutter);
  background: var(--ink); color: var(--ivory); font-size: 12px; letter-spacing: .06em;
  border-bottom: 1px solid var(--frame-line);
}
.topbar-msg { text-align: center; }
.topbar-side { color: var(--ivory-muted); }
.topbar-links { justify-self: end; display: flex; gap: 20px; }
.topbar-links a { color: var(--ivory); }
.topbar-links a:hover { text-decoration: underline; text-underline-offset: 3px; }

.header {
  position: sticky; top: 0; z-index: 40;
  display: grid; grid-template-columns: 1fr auto 1fr; align-items: center;
  height: var(--header-h); padding: 0 var(--gutter);
  background: var(--ink); color: var(--ivory);
}
.header :focus-visible { outline-color: var(--ivory); }
.header-nav { display: flex; align-items: center; }
/* Small tracked capitals, like the logo's lettering. */
.nav-links { display: flex; gap: clamp(20px, 2.2vw, 40px); font-size: 12.5px; letter-spacing: .14em; text-transform: uppercase; }
.nav-links a { position: relative; padding: 6px 0; }
.nav-links a::after {
  content: ""; position: absolute; left: 0; right: 0; bottom: 0; height: 1px;
  background: currentColor; transform: scaleX(0); transform-origin: left; transition: transform .35s var(--ease);
}
.nav-links a:hover::after, .nav-links a[aria-current="page"]::after { transform: scaleX(1); }
.menu-sheet a[aria-current="page"] { text-decoration: underline; text-underline-offset: 8px; text-decoration-thickness: 1px; }
.menu-btn { display: none; margin-left: -9px; }

/* LONDON in the serif, very widely spaced, as in the logo. */
.wordmark {
  font-family: var(--serif); font-size: 30px; font-weight: 500; text-transform: uppercase;
  letter-spacing: .42em;
  margin-right: -.42em; /* optically re-centre the tracked letters */
  line-height: 1;
}

.header-tools { justify-self: end; display: flex; align-items: center; gap: 6px; }
.search {
  width: clamp(150px, 13vw, 220px); height: 36px; margin-right: 14px;
  border-bottom: 1px solid var(--ivory-muted);
}
.search label { display: flex; align-items: center; gap: 10px; height: 100%; }
.search svg { width: 17px; height: 17px; flex: none; }
.search input {
  flex: 1; min-width: 0; height: 100%; border: 0; background: transparent; outline: none;
  font-size: 12.5px; letter-spacing: .14em; text-transform: uppercase;
}
.search input:not(:placeholder-shown) { text-transform: none; letter-spacing: .02em; font-size: 14px; }
.search input::placeholder { color: var(--ivory); }
.search:focus-within { border-bottom-color: var(--ivory); }

.bag-count, .wish-count {
  position: absolute; top: 3px; right: 1px;
  min-width: 17px; height: 17px; padding: 0 4px; border-radius: 9px;
  background: var(--ivory); color: var(--ink);
  font-size: 10.5px; font-weight: 500; line-height: 17px; text-align: center;
}
.bag-count.bump { animation: bump .5s var(--ease); }
@keyframes bump { 40% { transform: scale(1.35); } }

.menu-sheet {
  position: absolute; left: 0; right: 0; top: 100%;
  display: flex; flex-direction: column;
  padding: 8px var(--gutter) 28px;
  background: var(--ink); color: var(--ivory); border-top: 1px solid var(--frame-line);
}
.menu-sheet[hidden] { display: none; }
.menu-sheet a { padding: 14px 0; font-family: var(--serif); font-size: 28px; border-bottom: 1px solid var(--frame-line); }
.menu-search input {
  width: 100%; height: 48px; margin-bottom: 8px; padding: 0 14px;
  border: 1px solid var(--frame-line); border-radius: 2px; background: transparent; color: var(--ivory); font-size: 16px;
}
.menu-search input::placeholder { color: var(--ivory-muted); }

/* ---------- Hero ---------- */

/* Each half takes the photo's own 2:3 shape, so nobody is cropped. */
.hero { display: grid; grid-template-columns: 1fr 1fr; background: var(--stone); }
.hero-panel { position: relative; display: block; aspect-ratio: 2 / 3; overflow: hidden; background: var(--stone); }
.hero-panel img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
a.hero-panel::after {
  content: ""; position: absolute; inset: 0; pointer-events: none;
  background: linear-gradient(to bottom, rgba(0,0,0,.24), rgba(0,0,0,0) 18%);
}
.hero-label {
  position: absolute; z-index: 1; top: var(--gutter); left: var(--gutter);
  display: flex; flex-direction: column; gap: 4px; color: #fff;
}
.hero-label-name { font-family: var(--serif); font-size: clamp(30px, 2.6vw, 48px); font-weight: 400; line-height: 1.05; }
.hero-label-link { font-size: 14px; text-decoration: underline; text-underline-offset: 5px; text-decoration-thickness: 1px; }
.hero-panel:hover .hero-label-link { text-decoration-thickness: 2px; }

.season {
  display: flex; align-items: flex-end; justify-content: space-between; gap: 32px;
  padding: clamp(40px, 4vw, 72px) var(--gutter) 0;
}
.season-title { font-family: var(--serif); font-size: clamp(52px, 8.2vw, 190px); font-weight: 400; line-height: .92; letter-spacing: -.015em; white-space: nowrap; }
.season-note { font-size: 15px; color: var(--muted); max-width: 22em; padding-bottom: .6em; }

/* ---------- New this week rail ---------- */

.rail { padding: clamp(80px, 8vw, 150px) 0 clamp(90px, 9vw, 160px); }
.rail-head {
  display: flex; align-items: flex-end; justify-content: space-between; gap: 24px;
  padding: 0 var(--gutter) 28px;
}
.rail-title { font-family: var(--serif); font-size: clamp(38px, 4vw, 76px); font-weight: 400; line-height: 1; letter-spacing: -.01em; }
.rail-tools { display: flex; align-items: center; gap: 28px; }
.rail-arrows { display: flex; gap: 6px; margin-left: 8px; }
.rail-arrow {
  display: grid; place-items: center; width: 44px; height: 44px;
  border: 1px solid var(--ink); border-radius: 50%;
  transition: background .2s, color .2s, opacity .2s;
}
.rail-arrow:hover:not(:disabled) { background: var(--ink); color: #fff; }
.rail-arrow:disabled { opacity: .25; cursor: default; }
.rail-arrow svg { width: 18px; height: 18px; }
.rail-track {
  list-style: none; margin: 0;
  display: grid; grid-auto-flow: column;
  grid-auto-columns: calc((100% - var(--col-gap) * 4) / 4.5);
  gap: var(--col-gap);
  padding: 0 var(--gutter);
  overflow-x: auto; overscroll-behavior-x: contain;
  scroll-snap-type: x mandatory; scroll-padding: 0 var(--gutter);
  scrollbar-width: none;
}
.rail-track::-webkit-scrollbar { display: none; }
.rail-track > li { scroll-snap-align: start; }

/* ---------- Gender pages ---------- */

.page-top {
  display: flex; align-items: baseline; justify-content: space-between; gap: 24px;
  padding: 28px var(--gutter) 22px;
}
.page-title { font-family: var(--serif); font-size: clamp(36px, 3.2vw, 60px); font-weight: 400; line-height: 1.05; }
.page-note { font-size: 14px; color: var(--muted); }

.finder { margin-top: 8px; }
.finder + .shop-bar { border-top: 0; }
.finder-field {
  display: flex; align-items: center; gap: 18px;
  border-bottom: 1px solid var(--ink); padding-bottom: 10px;
}
.finder-field svg { width: clamp(24px, 2vw, 34px); height: clamp(24px, 2vw, 34px); flex: none; stroke-width: 1.2; }
.finder-field input {
  flex: 1; min-width: 0; border: 0; background: transparent; outline: none;
  font-size: clamp(24px, 2.6vw, 48px); font-weight: 300; letter-spacing: -.015em; padding: 4px 0;
}
.finder-field input::placeholder { color: var(--faint); }
.finder-field:focus-within { border-bottom-width: 2px; padding-bottom: 9px; }

/* Replace the browser's blue clear button with a quiet cross. */
input[type="search"]::-webkit-search-cancel-button {
  -webkit-appearance: none; appearance: none; cursor: pointer;
  width: 14px; height: 14px; margin-left: 8px;
  background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M5 5l14 14M19 5 5 19' stroke='%236F6B64' stroke-width='1.6' stroke-linecap='round'/%3E%3C/svg%3E") center / contain no-repeat;
}
.finder-field input::-webkit-search-cancel-button { width: 22px; height: 22px; }

/* ---------- Shop ---------- */

.shop { padding: 0 var(--gutter) clamp(90px, 9vw, 160px); }

.shop-bar {
  position: sticky; top: var(--header-h); z-index: 20;
  display: flex; align-items: center; justify-content: space-between; gap: 24px;
  margin-bottom: 28px; padding: 14px 0;
  background: var(--paper);
  border-top: 1px solid var(--ink); border-bottom: 1px solid var(--mist);
}
.chips { display: flex; gap: 22px; overflow-x: auto; scrollbar-width: none; padding: 4px 2px; }
.chips::-webkit-scrollbar { display: none; }
.chip { font-size: 14px; color: var(--muted); white-space: nowrap; padding: 4px 0; }
.chip:hover { color: var(--ink); }
.chip[aria-pressed="true"] { color: var(--ink); text-decoration: underline; text-underline-offset: 7px; }
.shop-meta { display: flex; align-items: center; gap: 22px; flex: none; font-size: 14px; }
.shop-count { color: var(--muted); }
.sort select {
  appearance: none; border: 0; background: transparent; font-size: 14px; padding: 6px 22px 6px 0; cursor: pointer;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 12 12'%3E%3Cpath d='M2 4.5 6 8l4-3.5' fill='none' stroke='%23000' stroke-width='1.2'/%3E%3C/svg%3E");
  background-repeat: no-repeat; background-position: right center; background-size: 12px;
}

.grid {
  list-style: none; margin: 0; padding: 0;
  display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); grid-auto-flow: row dense;
  column-gap: var(--col-gap); row-gap: clamp(36px, 3.2vw, 60px);
}
.tile article { display: flex; flex-direction: column; height: 100%; }
.tile-media { position: relative; aspect-ratio: 3 / 4; overflow: hidden; background: var(--stone); }
.tile-media img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.tile-open { position: absolute; inset: 0; width: 100%; height: 100%; }

.tile-wish {
  position: absolute; top: 8px; right: 8px; z-index: 2;
  display: grid; place-items: center; width: 38px; height: 38px;
}
.tile-wish svg { width: 20px; height: 20px; }
.tile-wish[aria-pressed="true"] svg, #pdpWish[aria-pressed="true"] svg { fill: currentColor; }

.tile-quick {
  position: absolute; z-index: 2; left: 8px; right: 8px; bottom: 8px;
  display: flex; align-items: center; justify-content: space-between; gap: 10px;
  padding: 8px 8px 8px 14px;
  background: rgba(250, 249, 247, .94); backdrop-filter: blur(8px);
  transform: translateY(calc(100% + 12px));
  transition: transform .5s var(--ease);
}
.tile-media:hover .tile-quick, .tile-quick:focus-within { transform: none; }
.tile-quick-label { font-size: 13px; white-space: nowrap; }
.tile-quick-sizes { display: flex; flex-wrap: wrap; justify-content: flex-end; gap: 2px; }
.tile-quick-sizes button { min-width: 34px; height: 32px; padding: 0 8px; font-size: 13px; border-radius: 2px; }
.tile-quick-sizes button:hover { background: var(--ink); color: #fff; }
@media (hover: none) { .tile-quick { display: none; } }

.tile-info { display: grid; grid-template-columns: 1fr auto; gap: 2px 16px; padding-top: 12px; font-size: 14px; }
.tile-name { font-size: 14px; font-weight: 400; }
.tile-name button { text-align: left; }
.tile-name button:hover { text-decoration: underline; text-underline-offset: 4px; }
.tile-colour { grid-column: 1 / -1; display: flex; align-items: center; gap: 8px; color: var(--muted); }
.swatch { width: 10px; height: 10px; border-radius: 50%; box-shadow: inset 0 0 0 1px rgba(0,0,0,.18); flex: none; }


.grid-empty[hidden] { display: none; }
.grid-empty { padding: 80px 0; display: flex; flex-direction: column; align-items: flex-start; gap: 20px; font-family: var(--serif); font-size: clamp(26px, 2.2vw, 38px); }

/* ---------- Atelier ---------- */

.atelier {
  display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); column-gap: var(--col-gap);
  padding: 0 var(--gutter) clamp(90px, 9vw, 160px);
}
.atelier-main { grid-column: 1 / span 7; width: 100%; height: min(94vh, 1180px); object-fit: cover; }
.atelier-side { grid-column: 9 / -1; display: flex; flex-direction: column; justify-content: space-between; gap: 48px; }
.atelier-copy { display: flex; flex-direction: column; gap: 18px; padding-top: clamp(0px, 4vw, 80px); }
.atelier-copy h2 { font-family: var(--serif); font-size: clamp(36px, 3.4vw, 64px); font-weight: 400; line-height: 1.04; letter-spacing: -.01em; margin-bottom: 10px; }
.atelier-copy p { color: var(--muted); max-width: 30em; }
.atelier-copy .text-link { align-self: flex-start; margin-top: 8px; }
.atelier-detail { width: 72%; aspect-ratio: 4 / 5; object-fit: cover; align-self: flex-end; }

/* ---------- Services & footer ---------- */

.services {
  display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); column-gap: var(--col-gap);
  padding: 0 var(--gutter) clamp(70px, 7vw, 120px);
}
.service { border-top: 1px solid var(--ink); padding-top: 16px; padding-right: 24px; }
.service h3 { font-size: 16px; font-weight: 500; margin-bottom: 6px; }
.service p { font-size: 15px; color: var(--muted); max-width: 26em; }

/* The footer: the bottom of the black frame, led by the full logo. */
.footer { background: var(--ink); color: var(--ivory); padding: clamp(72px, 8vw, 140px) var(--gutter) 28px; }
.footer :focus-visible { outline-color: var(--ivory); }

/* LD monogram: the D sits lower and overlaps the L's foot, as in the logo. */
.monogram { display: inline-flex; align-items: flex-start; font-family: var(--serif); font-weight: 500; line-height: .8; }
.monogram span:last-child { margin-left: -.3em; margin-top: .32em; }

.footer-logo { display: flex; flex-direction: column; align-items: center; gap: 22px; width: fit-content; margin: 0 auto clamp(72px, 8vw, 130px); }
.footer-logo .monogram { font-size: clamp(64px, 6vw, 96px); }
.footer-logo-name {
  font-family: var(--serif); font-weight: 500; text-transform: uppercase;
  font-size: clamp(34px, 4.2vw, 64px); letter-spacing: .42em; margin-right: -.42em; line-height: 1;
}
/* "EST. 2026" between two fine lines. */
.footer-logo-est {
  display: flex; align-items: center; gap: 24px; width: 100%;
  font-family: var(--serif); font-size: clamp(14px, 1.2vw, 18px); text-transform: uppercase; letter-spacing: .4em;
  font-variant-numeric: lining-nums; /* capital-height figures, as in the logo */
}
.footer-logo-est::before, .footer-logo-est::after { content: ""; flex: 1; height: 1px; background: var(--ivory); opacity: .7; }

.footer-top {
  display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); column-gap: var(--col-gap); row-gap: 56px;
  padding-top: clamp(48px, 5vw, 80px); border-top: 1px solid var(--frame-line);
}
.signup { grid-column: 1 / span 6; display: flex; flex-direction: column; gap: 24px; }
.signup-lead { font-family: var(--serif); font-size: clamp(26px, 2.3vw, 40px); font-weight: 400; line-height: 1.15; max-width: 18em; }
.signup-row { display: flex; gap: 10px; max-width: 560px; }
.signup-row input {
  flex: 1; min-width: 0; height: 50px; padding: 0 2px; border: 0; border-bottom: 1px solid var(--ivory-muted);
  background: transparent; color: var(--ivory); font-size: 16px; outline: none;
}
.signup-row input::placeholder { color: var(--ivory-muted); }
.signup-row input:focus { border-bottom-color: var(--ivory); }
.signup-row .btn { background: var(--ivory); color: var(--ink); border-color: var(--ivory); }
.signup-row .btn:hover { background: #fff; }
.signup-msg { font-size: 14px; min-height: 1.5em; }
.footer-cols { grid-column: 8 / -1; display: grid; grid-template-columns: repeat(3, 1fr); gap: var(--col-gap); }
.footer-cols div { display: flex; flex-direction: column; gap: 10px; font-size: 15px; }
.footer-cols h4 { font-size: 12px; font-weight: 500; letter-spacing: .14em; text-transform: uppercase; margin-bottom: 8px; }
.footer-cols a { color: var(--ivory-muted); }
.footer-cols a:hover { color: var(--ivory); }
.footer-bottom {
  display: flex; justify-content: space-between; gap: 20px; flex-wrap: wrap;
  margin-top: clamp(60px, 6vw, 110px); padding-top: 18px;
  border-top: 1px solid var(--frame-line); font-size: 13px; color: var(--ivory-muted);
}

/* ---------- Dialogs ---------- */

dialog { border: 0; padding: 0; color: var(--ink); background: var(--paper); }
dialog::backdrop { background: rgba(0, 0, 0, .32); }

.pdp { width: 100vw; height: 100dvh; max-width: none; max-height: none; margin: 0; }
.pdp[open] { animation: fade .35s var(--ease); }
.pdp-inner { position: relative; display: grid; grid-template-columns: minmax(0, 1.4fr) minmax(0, 1fr); height: 100%; }
.pdp-media { position: relative; overflow: hidden; background: var(--stone); }
.pdp-media img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.pdp-body {
  overflow-y: auto; display: flex; flex-direction: column; gap: 18px;
  padding: clamp(72px, 9vh, 120px) clamp(24px, 4.5vw, 96px) 48px;
}
.pdp-close { position: absolute; top: 16px; right: 16px; }
.pdp-crumbs { font-size: 14px; color: var(--muted); }
.pdp-name { font-family: var(--serif); font-size: clamp(38px, 3.2vw, 62px); font-weight: 400; line-height: 1.04; letter-spacing: -.01em; }
.pdp-price { font-size: 18px; }
.pdp-desc { color: var(--muted); max-width: 32em; }
.pdp-colour { display: flex; align-items: center; gap: 10px; font-size: 15px; }
.pdp-colour .swatch { width: 14px; height: 14px; }
.pdp-size { display: flex; flex-direction: column; gap: 10px; margin-top: 8px; }
.pdp-size-head { display: flex; justify-content: space-between; font-size: 15px; }
.pdp-sizes { display: grid; grid-template-columns: repeat(auto-fill, minmax(62px, 1fr)); gap: 6px; }
.pdp-sizes button {
  height: 48px; border: 1px solid var(--line); border-radius: 2px; font-size: 14px;
  transition: border-color .2s, background .2s, color .2s;
}
.pdp-sizes button:hover { border-color: var(--ink); }
.pdp-sizes button[aria-pressed="true"] { background: var(--ink); border-color: var(--ink); color: #fff; }
.pdp-error { font-size: 14px; color: var(--error); min-height: 1.5em; }
.pdp-error:empty { min-height: 0; }
#pdpWish { gap: 10px; }
#pdpWish svg { width: 18px; height: 18px; }
.pdp-details { border-top: 1px solid var(--mist); }
.pdp-details:last-child { border-bottom: 1px solid var(--mist); }
.pdp-details summary { padding: 14px 0; font-size: 15px; cursor: pointer; list-style: none; display: flex; justify-content: space-between; }
.pdp-details summary::-webkit-details-marker { display: none; }
.pdp-details summary::after { content: "+"; font-weight: 300; font-size: 20px; line-height: 1; }
.pdp-details[open] summary::after { content: "\2212"; }
.pdp-details p { padding-bottom: 16px; color: var(--muted); font-size: 15px; max-width: 34em; }

.drawer {
  margin: 0 0 0 auto; width: min(480px, 100vw); height: 100dvh; max-height: none; max-width: none;
}
.drawer[open] { animation: slideIn .5s var(--ease); }
.drawer[open]::backdrop { animation: fade .4s; }
@keyframes slideIn { from { transform: translateX(100%); } }
@keyframes fade { from { opacity: 0; } }
.drawer-inner { display: flex; flex-direction: column; height: 100%; }
.drawer-head { display: flex; justify-content: space-between; align-items: center; padding: 14px 16px 14px 28px; border-bottom: 1px solid var(--mist); }
.drawer-head h2 { font-family: var(--serif); font-size: 26px; font-weight: 400; }
.meter { padding: 16px 28px; border-bottom: 1px solid var(--mist); font-size: 14px; }
.meter[hidden] { display: none; }
.meter-track { height: 2px; margin-top: 10px; background: var(--mist); }
.meter-fill { height: 100%; background: var(--ink); transition: width .6s var(--ease); }
.bag-list { list-style: none; margin: 0; padding: 0 28px; flex: 1; overflow-y: auto; }
.bag-item { display: grid; grid-template-columns: 92px 1fr; gap: 18px; padding: 20px 0; border-bottom: 1px solid var(--mist); }
.bag-item img { width: 92px; aspect-ratio: 3 / 4; object-fit: cover; background: var(--stone); }
.bag-item-info { display: flex; flex-direction: column; gap: 2px; font-size: 14px; }
.bag-item-top { display: flex; justify-content: space-between; gap: 12px; }
.bag-item-name { font-size: 15px; }
.bag-item-meta { color: var(--muted); }
.bag-item-actions { display: flex; justify-content: space-between; align-items: center; margin-top: auto; padding-top: 10px; }
.qty { display: inline-flex; align-items: center; border: 1px solid var(--line); border-radius: 2px; }
.qty button { width: 32px; height: 32px; font-size: 16px; }
.qty button:hover { background: var(--stone); }
.qty span { min-width: 24px; text-align: center; font-size: 14px; }
.remove { font-size: 13px; color: var(--muted); text-decoration: underline; text-underline-offset: 4px; }
.remove:hover { color: var(--ink); }
.bag-empty { flex: 1; display: flex; flex-direction: column; align-items: flex-start; gap: 20px; padding: 40px 28px; font-family: var(--serif); font-size: 30px; }
.bag-empty[hidden] { display: none; }
.drawer-foot { padding: 20px 28px 28px; border-top: 1px solid var(--mist); display: flex; flex-direction: column; gap: 10px; }
.drawer-foot[hidden] { display: none; }
.row { display: flex; justify-content: space-between; gap: 16px; }
.drawer-foot .row { font-size: 17px; }
.drawer-note { font-size: 13px; color: var(--muted); margin-bottom: 6px; }

.toast {
  position: fixed; z-index: 60; left: 50%; bottom: 24px;
  display: flex; align-items: center; gap: 18px;
  padding: 14px 20px; background: var(--ink); color: #fff; font-size: 14px;
  transform: translate(-50%, 140%); opacity: 0;
  transition: transform .5s var(--ease), opacity .3s;
}
.toast.is-on { transform: translate(-50%, 0); opacity: 1; }
.toast button { text-decoration: underline; text-underline-offset: 4px; white-space: nowrap; }

/* Form groups (used by WooCommerce's account forms). */
fieldset { border: 0; margin: 0 0 52px; padding: 0; min-width: 0; }
legend { padding: 0; margin-bottom: 22px; font-size: 22px; font-weight: 400; }

/* ---------- Responsive ---------- */

@media (max-width: 1100px) {
  .grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .nav-links { gap: 18px; font-size: 14px; }
  .search { width: 130px; }
  .rail-track { grid-auto-columns: calc((100% - var(--col-gap) * 3) / 3.5); }
  .footer-cols { grid-column: 1 / -1; }
  .signup { grid-column: 1 / -1; }
}

@media (max-width: 900px) {
  :root { --header-h: 60px; }
  .menu-btn { display: inline-grid; }
  .nav-links, .search, .hide-sm, .topbar-side { display: none; }
  .topbar { grid-template-columns: 1fr; }
  .wordmark { font-size: 22px; }
  .rail-tools .text-link { display: none; }
  .rail-track { grid-auto-columns: calc((100% - var(--col-gap) * 2) / 2.3); }
  .shop-bar { flex-direction: column; align-items: stretch; gap: 10px; }
  .chips { max-width: 100%; }
  .shop-meta { justify-content: space-between; }
  .atelier { row-gap: 40px; }
  .atelier-main { grid-column: 1 / -1; height: auto; aspect-ratio: 4 / 5; }
  .atelier-side { grid-column: 1 / -1; }
  .services { grid-template-columns: repeat(2, minmax(0, 1fr)); row-gap: 32px; }
  .pdp-inner { grid-template-columns: 1fr; grid-template-rows: auto 1fr; overflow-y: auto; }
  .pdp-media { height: 62vh; }
  .pdp-body { overflow: visible; padding-top: 32px; }
  .pdp-close { background: var(--paper); border-radius: 50%; }
}

@media (max-width: 800px) {
  .hero:not(.hero-pair) { grid-template-columns: 1fr; }
  .season { flex-direction: column; align-items: flex-start; gap: 12px; }
  .season-title { font-size: 15vw; white-space: normal; }
  .shop-bar { position: static; }
  .grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

@media (max-width: 560px) {
  .services { grid-template-columns: 1fr; }
  .footer-cols { grid-template-columns: repeat(2, 1fr); row-gap: 32px; }
  .tile-info { grid-template-columns: 1fr; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation-duration: .001ms !important; animation-delay: 0s !important; transition-duration: .001ms !important; }
}

/* ---------- WordPress ---------- */

/* Logged-in users see WordPress's admin bar (32px, or 46px on small screens) above the page,
   so sticky elements start below it. Under 600px the admin bar scrolls away, so no offset. */
.admin-bar .header { top: 32px; }
.admin-bar .shop-bar { top: calc(var(--header-h) + 32px); }
@media (max-width: 782px) {
  .admin-bar .header { top: 46px; }
  .admin-bar .shop-bar { top: calc(var(--header-h) + 46px); }
}
@media (max-width: 600px) {
  .admin-bar .header { top: 0; }
  .admin-bar .shop-bar { top: var(--header-h); }
}

/* Plain pages (Cart, Checkout, My account). */
.page-content { padding: clamp(40px, 5vw, 80px) var(--gutter) clamp(80px, 8vw, 140px); min-height: 50vh; }
.page-content-title { font-family: var(--serif); font-size: clamp(40px, 4vw, 76px); font-weight: 400; letter-spacing: -.01em; line-height: 1; margin-bottom: 40px; }

/* ---------- WooCommerce pages ----------
   WooCommerce draws the Cart, Checkout and My account pages itself; these rules only restyle them
   to match London. Each rule starts with .page-content so it outweighs WooCommerce's own styles. */

/* Buttons: Place order, Proceed to checkout, Log in, Save address… */
.page-content .wc-block-components-button:not(.is-link),
.page-content .woocommerce .button {
  display: inline-flex; align-items: center; justify-content: center;
  min-height: 54px; padding: 0 28px;
  background: var(--ink); color: #fff;
  font-size: 14px; font-weight: 500; letter-spacing: .04em;
  border: 1px solid var(--ink); border-radius: 2px;
  transition: background .2s;
}
.page-content .wc-block-components-button:not(.is-link):hover,
.page-content .woocommerce .button:hover { background: #2a2a2a; color: #fff; }

/* Text fields and dropdowns */
.page-content .wc-block-components-text-input input[type],
.page-content .wc-blocks-components-select__select,
.page-content .wc-block-components-textarea,
.page-content .woocommerce form .form-row .input-text,
.page-content .woocommerce form .form-row select {
  background: #fff; border: 1px solid var(--line); border-radius: 2px; color: var(--ink);
  transition: border-color .2s, box-shadow .2s;
}
.page-content .woocommerce form .form-row .input-text,
.page-content .woocommerce form .form-row select { height: 50px; padding: 0 14px; }
.page-content .wc-block-components-text-input input[type]:focus,
.page-content .wc-blocks-components-select__select:focus,
.page-content .wc-block-components-textarea:focus,
.page-content .woocommerce form .form-row .input-text:focus,
.page-content .woocommerce form .form-row select:focus {
  outline: none; border-color: var(--ink); box-shadow: inset 0 0 0 1px var(--ink);
}
.page-content .wc-block-components-text-input.has-error input[type] { border-color: var(--error); box-shadow: inset 0 0 0 1px var(--error); }
.page-content .wc-block-components-validation-error { color: var(--error); }

/* Delivery and payment choices: white boxes, the chosen one outlined in black */
.page-content .wc-block-components-radio-control--highlight-checked,
.page-content .wc-block-components-radio-control--highlight-checked::after,
.page-content .wc-block-components-radio-control--highlight-checked .wc-block-components-radio-control__option--checked-option-highlighted,
.page-content .wc-block-components-radio-control-accordion-option--checked-option-highlighted {
  border-radius: 2px;
}
.page-content .wc-block-components-radio-control--highlight-checked { background: #fff; }
.page-content .wc-block-components-radio-control--highlight-checked::after { border-color: var(--line); }

/* Order summary and cart totals: a stone panel, like the bag */
.page-content .wp-block-woocommerce-checkout-order-summary-block {
  background: var(--stone); border: 0; border-radius: 2px;
}
.page-content .wc-block-components-totals-wrapper,
.page-content .wc-block-cart-items td,
.page-content .wc-block-cart-items th,
.page-content .wc-block-checkout__terms--with-separator { border-color: var(--line); }
.page-content .wc-block-components-quantity-selector { border-radius: 2px; }
.page-content .wc-block-components-quantity-selector::after { border-color: var(--line); border-radius: 2px; }

/* Small headings: WooCommerce writes some in capitals; London uses sentence case. */
.page-content .wc-block-cart-items__header th,
.page-content .wc-block-cart-items__header span,
.page-content .wc-block-cart__totals-title {
  text-transform: none; font-size: 14px; font-weight: 400; color: var(--muted);
}

/* Messages (e.g. "Your order was placed", "Wrong password") */
.page-content .wc-block-components-notice-banner { border-radius: 2px; }
.page-content .woocommerce-message,
.page-content .woocommerce-info,
.page-content .woocommerce-error {
  background: var(--stone); border-top-color: var(--ink); color: var(--ink);
}
.page-content .woocommerce-message::before,
.page-content .woocommerce-info::before { color: var(--ink); }
.page-content .woocommerce-error { border-top-color: var(--error); }
/* WooCommerce moves focus to a new message so screen readers announce it; no focus ring is needed on plain text. */
.page-content :is(.woocommerce-message, .woocommerce-info, .woocommerce-error, .wc-block-components-notice-banner):focus { outline: none; }
.page-content .woocommerce-error::before { color: var(--error); }

/* Log in / create account forms */
.page-content .woocommerce h2 { font-size: 22px; font-weight: 400; margin-bottom: 20px; }
.page-content .woocommerce :is(form.login, form.register, form.lost_reset_password) {
  max-width: 520px; margin: 0 0 40px; padding: 32px;
  background: #fff; border: 1px solid var(--line); border-radius: 2px;
}
.page-content .woocommerce form .form-row label { font-size: 13.5px; margin-bottom: 6px; }
.page-content .woocommerce form.login .form-row:has(.woocommerce-form-login__submit) {
  display: flex; align-items: center; gap: 20px; margin-top: 8px;
}
.page-content .woocommerce form.login .woocommerce-form-login__submit { order: -1; float: none; margin: 0; }
.page-content .woocommerce form.login .woocommerce-form-login__rememberme { margin: 0; }
.page-content .woocommerce form .form-row .required { color: var(--muted); }
/* Order received (and viewing an order in My account): summary, order table and addresses */
.page-content .woocommerce-thankyou-order-received { font-size: 22px; font-weight: 300; margin-bottom: 28px; }
.page-content .woocommerce ul.order_details {
  display: flex; flex-wrap: wrap; gap: 20px 48px; margin: 0 0 32px; padding: 0 0 32px; list-style: none;
  border-bottom: 1px solid var(--line);
}
.page-content .woocommerce ul.order_details::before,
.page-content .woocommerce ul.order_details::after { display: none; } /* WooCommerce's float fix, not needed here */
.page-content .woocommerce ul.order_details li {
  margin: 0; padding: 0; border: 0; float: none;
  font-size: 13.5px; text-transform: none; color: var(--muted);
}
.page-content .woocommerce ul.order_details li strong { display: block; margin-top: 4px; font-size: 18px; font-weight: 400; color: var(--ink); }
.page-content .woocommerce :is(.woocommerce-order-details, .woocommerce-customer-details) { margin-top: 48px; }
.page-content .woocommerce table.shop_table {
  background: #fff; border: 1px solid var(--line); border-radius: 2px; border-collapse: collapse;
}
.page-content .woocommerce table.shop_table :is(th, td) { padding: 14px 18px; border-color: var(--line); font-weight: 400; }
.page-content .woocommerce table.shop_table thead th { font-size: 13.5px; color: var(--muted); }
.page-content .woocommerce table.shop_table :is(th, td) strong { font-weight: 400; }
.page-content .woocommerce .woocommerce-customer-details address {
  padding: 18px; background: #fff; border: 1px solid var(--line); border-radius: 2px; line-height: 1.6;
}
.page-content .woocommerce :is(address, em) { font-style: normal; }

/* My account (logged in): a narrow menu on the left, the chosen page on the right */
.page-content .woocommerce:has(> .woocommerce-MyAccount-navigation) {
  display: grid; grid-template-columns: 220px minmax(0, 1fr); gap: 32px clamp(32px, 5vw, 96px); align-items: start;
}
.page-content .woocommerce:has(> .woocommerce-MyAccount-navigation)::before,
.page-content .woocommerce:has(> .woocommerce-MyAccount-navigation)::after { display: none; }
.page-content .woocommerce-MyAccount-navigation,
.page-content .woocommerce-MyAccount-content { float: none; width: auto; }
.page-content .woocommerce-MyAccount-navigation ul { margin: 0; padding: 0; list-style: none; border-top: 1px solid var(--line); }
.page-content .woocommerce-MyAccount-navigation li { border-bottom: 1px solid var(--line); }
.page-content .woocommerce .woocommerce-MyAccount-navigation li a {
  display: block; padding: 14px 0; font-size: 15px; color: var(--muted); text-decoration: none;
}
.page-content .woocommerce .woocommerce-MyAccount-navigation li a:hover,
.page-content .woocommerce .woocommerce-MyAccount-navigation .is-active a { color: var(--ink); }
.page-content .woocommerce-MyAccount-navigation .is-active a { font-weight: 500; }
.page-content .woocommerce-MyAccount-content { max-width: 920px; }
.page-content .woocommerce-MyAccount-content > p { margin-bottom: 16px; max-width: 62ch; }

/* My account → Orders: "View" as a link rather than a big button */
.page-content .woocommerce .woocommerce-orders-table .button {
  min-height: 0; padding: 0; background: none; border: 0; color: var(--ink);
  font-weight: 400; letter-spacing: 0; text-decoration: underline; text-underline-offset: 4px;
}

/* My account → Addresses: two cards side by side */
.page-content .woocommerce .woocommerce-Addresses {
  display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); gap: 24px; margin-top: 24px;
}
.page-content .woocommerce .woocommerce-Addresses::before,
.page-content .woocommerce .woocommerce-Addresses::after { display: none; }
.page-content .woocommerce .woocommerce-Addresses .woocommerce-Address {
  float: none; width: auto; max-width: none; padding: 24px;
  background: #fff; border: 1px solid var(--line); border-radius: 2px;
}
.page-content .woocommerce .woocommerce-Address-title {
  display: flex; justify-content: space-between; align-items: baseline; gap: 16px; margin-bottom: 14px;
}
.page-content .woocommerce .woocommerce-Address-title::before,
.page-content .woocommerce .woocommerce-Address-title::after { display: none; }
.page-content .woocommerce .woocommerce-Address-title h2 { margin: 0; font-size: 18px; }
.page-content .woocommerce .woocommerce-Address-title a { float: none; font-size: 14px; white-space: nowrap; }
.page-content .woocommerce .woocommerce-Address address { line-height: 1.6; }

/* My account → Account details and editing an address */
.page-content .woocommerce :is(.woocommerce-EditAccountForm, .woocommerce-address-fields) { max-width: 720px; }
.page-content .woocommerce .woocommerce-EditAccountForm fieldset { margin: 32px 0 0; }
.page-content .woocommerce .woocommerce-EditAccountForm legend { font-size: 18px; margin-bottom: 12px; }
/* Country: London only delivers to the UK, so WooCommerce shows a one-choice list. Show it as plain text. */
.page-content .woocommerce form .form-row select.country_to_state--single {
  height: auto; padding: 0; background: none; border: 0; font-weight: 400; pointer-events: none;
}
.page-content .woocommerce form .form-row :is(em, .description) { display: block; margin-top: 6px; font-size: 13.5px; color: var(--muted); }

@media (max-width: 780px) {
  .page-content .woocommerce:has(> .woocommerce-MyAccount-navigation) { grid-template-columns: 1fr; }
  .page-content .woocommerce-MyAccount-navigation ul { display: flex; flex-wrap: wrap; gap: 4px 20px; border-bottom: 1px solid var(--line); padding-bottom: 4px; }
  .page-content .woocommerce-MyAccount-navigation li { border: 0; }
  .page-content .woocommerce .woocommerce-MyAccount-navigation li a { padding: 10px 0; }

  /* On phones WooCommerce turns tables into label/value rows; keep the order number row and lighten the labels. */
  .page-content .woocommerce table.shop_table_responsive tbody th { display: block; text-align: right; }
  .page-content .woocommerce table.shop_table_responsive tbody th::before { content: attr(data-title) ": "; float: left; color: var(--muted); }
  .page-content .woocommerce table.shop_table_responsive tr td::before { font-weight: 400; color: var(--muted); }

  /* A message's button goes under the text instead of squeezing it. */
  .page-content .woocommerce :is(.woocommerce-message, .woocommerce-info):has(.button) { display: flex; flex-direction: column; align-items: flex-start; }
  .page-content .woocommerce :is(.woocommerce-message, .woocommerce-info) .button { order: 1; float: none; margin-top: 14px; }
}

.page-content .woocommerce a:not(.button) { text-decoration: underline; text-underline-offset: 4px; text-decoration-thickness: 1px; }
.page-content .woocommerce input[type="checkbox"] { accent-color: var(--ink); }

/* Sold-out sizes (stock comes from WooCommerce): crossed out and not clickable. */
.pdp-sizes button:disabled,
.tile-quick-sizes button:disabled { color: var(--faint); text-decoration: line-through; cursor: not-allowed; }
.pdp-sizes button:disabled:hover { border-color: var(--line); }
.tile-quick-sizes button:disabled:hover { background: none; color: var(--faint); }

/* Messages from WooCommerce inside the bag, e.g. "not enough stock". */
.bag-error { margin: 16px 28px 0; color: var(--error); font-size: 14px; }
.bag-error[hidden] { display: none; }
