/* Tuesday Rose */

@font-face {
  font-family: "TR Display";
  src: url("/assets/fonts/display.woff2") format("woff2");
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "TR Text";
  src: url("/assets/fonts/text.woff2") format("woff2");
  font-weight: 400 800;
  font-style: normal;
  font-display: swap;
}

:root {
  --pink: #f8c8d6;
  --pink-soft: #fde9ef;
  --rose: #c2255c;
  --ink: #131313;
  --ink-soft: #55504f;
  --white: #fff;
  --line: rgba(19, 19, 19, 0.16);

  --display: "TR Display", "Bodoni 72", Didot, "Times New Roman", serif;
  --text: "TR Text", "Helvetica Neue", Arial, sans-serif;

  --gutter: clamp(1rem, 4vw, 3.5rem);
  --gap: clamp(0.5rem, 1.4vw, 1.5rem);
  --max: 96rem;
  --head-h: 4rem;
}

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

html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; scroll-padding-top: var(--head-h); }
body {
  margin: 0;
  background: var(--white);
  color: var(--ink);
  font-family: var(--text);
  font-size: 1rem;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
}
html.bag-is-open { overflow: hidden; }

img { display: block; width: 100%; height: auto; }
a { color: inherit; }
h1, h2, h3, p, ul, fieldset, legend { margin: 0; padding: 0; }
ul { list-style: none; }
fieldset { border: 0; min-width: 0; }
button { font: inherit; color: inherit; background: none; border: 0; padding: 0; cursor: pointer; }

h1, h2, h3 { font-family: var(--display); font-weight: 400; line-height: 1.02; letter-spacing: -0.01em; text-wrap: balance; }
p { text-wrap: pretty; }

:focus-visible { outline: 2px solid var(--ink); outline-offset: 3px; }

.skip { position: absolute; left: -999rem; top: 0; background: var(--ink); color: var(--white); padding: 0.75rem 1rem; z-index: 100; }
.skip:focus { left: 0; }

/* ---------- header ---------- */

.site-head {
  position: sticky; top: 0; z-index: 20;
  display: grid; grid-template-columns: 1fr auto 1fr; align-items: center;
  height: var(--head-h);
  padding: 0 var(--gutter);
  background: var(--white);
  border-bottom: 1px solid var(--line);
}
.head-nav { display: flex; gap: 1.75rem; }
.head-nav a, .bag-open { font-size: 0.9375rem; text-decoration: none; padding: 0.5rem 0; }
.head-nav a:hover, .bag-open:hover { text-decoration: underline; text-underline-offset: 0.3em; }
.nav-narrow { display: none; }
.wordmark {
  font-family: var(--display);
  font-size: clamp(1.5rem, 2.4vw, 1.875rem);
  line-height: 1;
  letter-spacing: -0.01em;
  text-decoration: none;
  white-space: nowrap;
}
.head-bag { justify-self: end; }
.bag-count {
  display: inline-block; min-width: 1.5rem; margin-left: 0.25rem; padding: 0.05rem 0.4rem;
  background: var(--pink); border-radius: 1rem; text-align: center;
}

/* ---------- buttons, sizes ---------- */

.btn {
  display: flex; align-items: center; justify-content: space-between; gap: 1rem;
  width: 100%; min-height: 3.25rem; padding: 0 1.25rem;
  background: var(--ink); color: var(--white);
  font-weight: 600; font-size: 0.9375rem; letter-spacing: 0.01em;
  transition: background-color 0.15s ease;
}
.btn:hover { background: var(--rose); }
.btn:disabled { background: var(--ink-soft); cursor: default; }
.btn-price { font-weight: 500; }
.bag .btn { justify-content: center; }

.more { display: inline-block; font-size: 0.9375rem; text-underline-offset: 0.3em; }
.more:hover { color: var(--rose); }

.sizes legend { font-size: 0.8125rem; font-weight: 600; margin-bottom: 0.5rem; }
.size-row { display: flex; flex-wrap: wrap; gap: 0.3125rem; }
.size { position: relative; }
.size input { position: absolute; inset: 0; width: 100%; height: 100%; margin: 0; opacity: 0; cursor: pointer; }
.size span {
  display: grid; place-items: center;
  min-width: 2.75rem; height: 2.75rem; padding: 0 0.4rem;
  border: 1px solid var(--line); background: var(--white);
  font-size: 0.875rem; font-weight: 500;
  transition: border-color 0.15s ease, background-color 0.15s ease, color 0.15s ease;
}
.size input:hover + span { border-color: var(--ink); }
.size input:checked + span { background: var(--ink); border-color: var(--ink); color: var(--white); }
.size input:focus-visible + span { outline: 2px solid var(--ink); outline-offset: 3px; }

.buy { display: grid; gap: 0.875rem; }
.buy-msg, .bag-msg { font-size: 0.875rem; font-weight: 600; color: var(--rose); }

/* ---------- hero + strip ---------- */

.hero { background: var(--pink); padding: clamp(2.5rem, 7vw, 6.5rem) var(--gutter) clamp(2rem, 4vw, 3.5rem); }
.hero-copy {
  max-width: var(--max); margin: 0 auto;
  display: grid; grid-template-columns: minmax(0, 8fr) minmax(0, 4fr); gap: var(--gap); align-items: end;
}
.hero h1 { font-size: clamp(2.75rem, 7.6vw, 8rem); line-height: 0.94; letter-spacing: -0.025em; }
.hero p { font-size: clamp(1rem, 1.25vw, 1.1875rem); max-width: 26rem; justify-self: end; padding-bottom: 0.6em; }

.strip {
  display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: var(--gap);
  padding: 0 var(--gutter) clamp(3.5rem, 8vw, 7rem);
  background: linear-gradient(var(--pink) 0, var(--pink) 42%, var(--white) 42%);
}
.card { display: block; text-decoration: none; }
.card-img { position: relative; display: block; aspect-ratio: 2 / 3; overflow: hidden; background: var(--pink-soft); }
.card-img img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.card-alt { opacity: 0; transition: opacity 0.35s ease; }
@media (hover: hover) {
  .card:hover .card-alt { opacity: 1; }
  .card:hover .card-name { text-decoration: underline; text-underline-offset: 0.3em; }
}
.card-cap { display: flex; justify-content: space-between; gap: 1rem; padding-top: 0.75rem; font-size: 0.9375rem; }
.card-name { font-weight: 600; }

/* ---------- chapters ---------- */

.chapter { padding: clamp(3.5rem, 8vw, 7.5rem) var(--gutter); }
.chapter-dark { background: var(--pink); }
.chapter-head {
  max-width: var(--max); margin: 0 auto clamp(2.5rem, 5vw, 4.5rem);
  display: grid; grid-template-columns: minmax(0, 8fr) minmax(0, 4fr); gap: var(--gap); align-items: end;
  padding-bottom: clamp(1.25rem, 2vw, 2rem); border-bottom: 1px solid var(--ink);
}
.chapter-head h2 { font-size: clamp(2.5rem, 6vw, 6rem); letter-spacing: -0.02em; }
.chapter-head p { max-width: 26rem; justify-self: end; padding-bottom: 0.4em; }

.feature {
  max-width: var(--max); margin: 0 auto;
  display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); column-gap: var(--gap); align-items: start;
}
.feature + .feature { margin-top: clamp(4rem, 9vw, 9rem); }
.f-main, .f-side { display: block; aspect-ratio: 2 / 3; overflow: hidden; background: var(--pink-soft); }
.f-main img, .f-side img { width: 100%; height: 100%; object-fit: cover; }
.f-main { grid-column: 1 / span 5; grid-row: 1; }
.f-side { grid-column: 6 / span 3; grid-row: 1; margin-top: clamp(3rem, 9vw, 9rem); }
.f-text { grid-column: 9 / span 4; grid-row: 1; align-self: center; padding-left: clamp(0rem, 1.5vw, 2rem); display: grid; gap: 1.25rem; }
.feature.flip .f-text { grid-column: 1 / span 4; padding-left: 0; padding-right: clamp(0rem, 1.5vw, 2rem); }
.feature.flip .f-side { grid-column: 5 / span 3; }
.feature.flip .f-main { grid-column: 8 / span 5; }
.f-text h3 { font-size: clamp(1.875rem, 3vw, 2.875rem); }
.f-text h3 a { text-decoration: none; }
.f-text h3 a:hover { color: var(--rose); }
.f-lead { max-width: 30rem; }

/* ---------- product page ---------- */

.pdp-grid {
  display: grid; grid-template-columns: minmax(0, 8fr) minmax(0, 4fr); gap: clamp(1.5rem, 3.5vw, 4rem);
  max-width: var(--max); margin: 0 auto; padding: var(--gap) var(--gutter) clamp(3.5rem, 7vw, 6rem);
}
.gallery { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: var(--gap); }
.gallery li { aspect-ratio: 2 / 3; overflow: hidden; background: var(--pink-soft); }
.gallery img { width: 100%; height: 100%; object-fit: cover; }
.gallery-count { display: none; }

.pdp-info { position: sticky; top: calc(var(--head-h) + 1.5rem); align-self: start; display: grid; gap: 1rem; padding-top: clamp(0.5rem, 2vw, 2rem); }
.crumb { font-size: 0.875rem; }
.crumb a { text-underline-offset: 0.3em; }
.pdp-info h1 { font-size: clamp(2.25rem, 3.6vw, 3.5rem); }
.pdp-price { font-size: 1.25rem; }
.pdp-colour { font-size: 0.9375rem; color: var(--ink-soft); }
.pdp-info .buy { margin: 0.5rem 0 0.75rem; }
.pdp-copy { display: grid; gap: 0.875rem; padding-top: 1.5rem; border-top: 1px solid var(--line); }
.pdp-copy h2 { font-family: var(--text); font-size: 0.8125rem; font-weight: 600; letter-spacing: 0; margin-top: 0.5rem; }
.pdp-copy ul { display: grid; gap: 0.375rem; }
.pdp-copy li { position: relative; padding-left: 1.1rem; }
.pdp-copy li::before { content: ""; position: absolute; left: 0; top: 0.72em; width: 0.5rem; height: 1px; background: var(--ink); }

.others { background: var(--pink); padding: clamp(3rem, 6vw, 5.5rem) var(--gutter); }
.others h2 { max-width: var(--max); margin: 0 auto clamp(1.5rem, 3vw, 2.5rem); font-size: clamp(2rem, 4vw, 3.5rem); }
.others-row { max-width: var(--max); margin: 0 auto; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: var(--gap); }

/* ---------- plain pages ---------- */

.plain { min-height: 60vh; padding: clamp(4rem, 12vw, 10rem) var(--gutter); background: var(--pink); display: grid; align-content: center; gap: 1.25rem; }
.plain h1 { font-size: clamp(2.5rem, 7vw, 6.5rem); max-width: 14ch; }

/* ---------- footer ---------- */

.site-foot { padding: clamp(3rem, 6vw, 5rem) var(--gutter) 1.5rem; border-top: 1px solid var(--line); overflow: hidden; }
.foot-cols { max-width: var(--max); margin: 0 auto; display: grid; grid-template-columns: minmax(0, 8fr) minmax(0, 4fr); gap: 2rem var(--gap); }
.foot-about { display: grid; gap: 1rem; max-width: 28rem; }
.foot-about a { text-underline-offset: 0.3em; }
.foot-about a:hover { color: var(--rose); }
.site-foot h2 { font-family: var(--text); font-size: 0.8125rem; font-weight: 600; letter-spacing: 0; margin-bottom: 0.75rem; }
.site-foot li + li { margin-top: 0.375rem; }
.site-foot li a { text-decoration: none; }
.site-foot li a:hover { text-decoration: underline; text-underline-offset: 0.3em; }
.foot-mark {
  font-family: var(--display); font-size: clamp(3.5rem, 15.6vw, 17rem); line-height: 1.12; letter-spacing: -0.03em;
  white-space: nowrap; text-align: center; margin: clamp(1.5rem, 4vw, 3.5rem) 0 clamp(0.75rem, 1.5vw, 1.5rem);
}
.foot-legal { font-size: 0.8125rem; color: var(--ink-soft); text-align: center; }

/* ---------- bag ---------- */

.scrim { position: fixed; inset: 0; z-index: 40; background: rgba(19, 19, 19, 0.35); }
.bag {
  position: fixed; top: 0; right: 0; bottom: 0; z-index: 50;
  width: min(27rem, 100%);
  display: grid; grid-template-rows: auto 1fr auto;
  background: var(--white);
  transform: translateX(100%); transition: transform 0.28s cubic-bezier(0.2, 0.7, 0.2, 1);
}
.bag[hidden] { display: none; }
html.bag-is-open .bag { transform: none; }
.bag-head { display: flex; align-items: baseline; justify-content: space-between; padding: 1.25rem 1.5rem; border-bottom: 1px solid var(--line); }
.bag-head h2 { font-size: 1.875rem; }
.bag-x { font-size: 0.9375rem; text-decoration: underline; text-underline-offset: 0.3em; padding: 0.5rem 0; }
.bag-body { overflow-y: auto; padding: 0 1.5rem; }
.bag-empty { display: grid; gap: 0.75rem; justify-items: start; padding: 2rem 0; }
.line { display: grid; grid-template-columns: 4.5rem 1fr auto; gap: 1rem; padding: 1.25rem 0; border-bottom: 1px solid var(--line); }
.line-img { display: block; aspect-ratio: 2 / 3; overflow: hidden; background: var(--pink-soft); }
.line-img img { width: 100%; height: 100%; object-fit: cover; }
.line-name { font-weight: 600; text-decoration: none; }
.line-name:hover { text-decoration: underline; text-underline-offset: 0.3em; }
.line-meta { font-size: 0.875rem; color: var(--ink-soft); }
.line-price { white-space: nowrap; }
.line-controls { display: flex; align-items: center; gap: 1rem; margin-top: 0.75rem; }
.qty { display: inline-grid; grid-template-columns: 2.25rem 2rem 2.25rem; align-items: center; border: 1px solid var(--line); text-align: center; font-variant-numeric: tabular-nums; }
.qty button { height: 2.25rem; }
.qty button:hover:not(:disabled) { background: var(--pink); }
.qty button:disabled { color: var(--line); cursor: default; }
.line-remove { font-size: 0.875rem; color: var(--ink-soft); text-decoration: underline; text-underline-offset: 0.3em; }
.line-remove:hover { color: var(--ink); }
.bag-foot { display: grid; gap: 0.875rem; padding: 1.25rem 1.5rem 1.5rem; border-top: 1px solid var(--ink); background: var(--pink-soft); }
.bag-foot[hidden] { display: none; }
.bag-total { display: flex; justify-content: space-between; font-weight: 600; }

/* ---------- smaller screens ---------- */

@media (max-width: 899px) {
  .pdp-grid { grid-template-columns: minmax(0, 1fr); padding-left: 0; padding-right: 0; padding-top: 0; gap: 0; }
  .gallery {
    display: flex; gap: 0.375rem; overflow-x: auto; scroll-snap-type: x mandatory;
    scrollbar-width: none; -webkit-overflow-scrolling: touch;
  }
  .gallery::-webkit-scrollbar { display: none; }
  .gallery li { flex: 0 0 86%; scroll-snap-align: start; }
  .gallery-count { display: block; padding: 0.625rem var(--gutter) 0; font-size: 0.8125rem; color: var(--ink-soft); font-variant-numeric: tabular-nums; }
  .pdp-info { position: static; padding: 1.25rem var(--gutter) 0; }
}

@media (max-width: 799px) {
  :root { --head-h: 3.5rem; }
  .nav-wide { display: none; }
  .nav-narrow { display: inline; }

  .hero-copy, .chapter-head { grid-template-columns: minmax(0, 1fr); gap: 1rem; }
  .hero p, .chapter-head p { justify-self: start; padding-bottom: 0; }

  .strip { grid-template-columns: repeat(2, minmax(0, 1fr)); row-gap: 1.75rem; background: linear-gradient(var(--pink) 0, var(--pink) 18%, var(--white) 18%); }
  .card-cap { flex-direction: column; gap: 0.125rem; }

  .feature { grid-template-columns: minmax(0, 3fr) minmax(0, 2fr); row-gap: 1.5rem; }
  .feature .f-main, .feature.flip .f-main { grid-column: 1; grid-row: 1; }
  .feature .f-side, .feature.flip .f-side { grid-column: 2; grid-row: 1; margin-top: 0; align-self: end; }
  .feature .f-text, .feature.flip .f-text { grid-column: 1 / -1; grid-row: 2; padding: 0; }
  .feature.flip .f-main { grid-column: 2; }
  .feature.flip .f-side { grid-column: 1; }
  .feature.flip { grid-template-columns: minmax(0, 2fr) minmax(0, 3fr); }

  .others-row { grid-template-columns: repeat(3, minmax(9.5rem, 1fr)); overflow-x: auto; scrollbar-width: none; margin-right: calc(var(--gutter) * -1); padding-right: var(--gutter); }
  .others-row::-webkit-scrollbar { display: none; }

  .size-row { display: grid; grid-template-columns: repeat(8, minmax(0, 1fr)); }
  .size span { min-width: 0; padding: 0; font-size: 0.8125rem; }

  .foot-cols { grid-template-columns: minmax(0, 1fr); }
}

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