/* ==========================================================================
   BRAMBLE & TAIL — site stylesheet
   ========================================================================== */

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

:root {
  --ink: #2a2622;
  --ink-2: #4c453c;
  --ink-soft: #7d766a;
  --line: #e5ddd1;
  --paper: #fbf8f4;
  --paper-2: #f4ece1;
  --accent: #a4633f;
  --gold: #b07d52;
  --white: #fff;
  --max: 1240px;
  --ease: cubic-bezier(.22,.61,.36,1);
}

html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }

body {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "Helvetica Neue", Arial, sans-serif;
  color: var(--ink);
  background: var(--paper);
  line-height: 1.62;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

img { display: block; max-width: 100%; height: auto; }
a { color: inherit; text-decoration: none; }
button { font: inherit; cursor: pointer; border: none; background: none; color: inherit; }
input, select, textarea { font: inherit; color: inherit; }
ul { list-style: none; }

.serif { font-family: Georgia, "Times New Roman", "Songti SC", serif; }
.wrap { max-width: var(--max); margin: 0 auto; padding: 0 24px; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

/* ---------- announcement ---------- */
.announce {
  background: var(--ink);
  color: #f4ece3;
  text-align: center;
  font-size: 11px;
  letter-spacing: .16em;
  text-transform: uppercase;
  padding: 11px 16px;
  font-weight: 500;
}
.announce b { color: var(--gold); font-weight: 600; }

/* ---------- header ---------- */
.site-header {
  position: sticky; top: 0; z-index: 60;
  background: rgba(250,248,245,.95);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--line);
}
.header-inner {
  max-width: var(--max); margin: 0 auto;
  display: flex; align-items: center; justify-content: space-between;
  gap: 20px; padding: 15px 24px;
}
.brand {
  font-family: Georgia, "Times New Roman", serif;
  font-size: 17px; letter-spacing: .24em; text-transform: uppercase;
  white-space: nowrap; line-height: 1;
}
.brand em { font-style: normal; color: var(--accent); }
.nav { display: flex; gap: 26px; }
.nav a {
  font-size: 11.5px; letter-spacing: .12em; text-transform: uppercase;
  color: var(--ink-soft); position: relative; padding: 4px 0; transition: color .25s;
}
.nav a::after {
  content: ""; position: absolute; left: 0; bottom: 0; height: 1px; width: 0;
  background: var(--ink); transition: width .3s var(--ease);
}
.nav a:hover, .nav a.on { color: var(--ink); }
.nav a:hover::after, .nav a.on::after { width: 100%; }

.header-tools { display: flex; align-items: center; gap: 18px; }
.cart-btn {
  display: inline-flex; align-items: center; gap: 7px;
  font-size: 11.5px; letter-spacing: .1em; text-transform: uppercase;
  padding: 7px 0; color: var(--ink-soft); transition: color .2s;
}
.cart-btn:hover { color: var(--ink); }
.cart-count {
  min-width: 18px; height: 18px; padding: 0 5px;
  display: inline-flex; align-items: center; justify-content: center;
  background: var(--ink); color: var(--paper);
  border-radius: 9px; font-size: 10px; letter-spacing: 0; font-weight: 600;
}
.cart-count[data-n="0"] { opacity: .35; }

.burger { display: none; width: 26px; height: 16px; position: relative; }
.burger span {
  position: absolute; left: 0; width: 100%; height: 1.5px; background: var(--ink);
  transition: transform .3s var(--ease), opacity .2s;
}
.burger span:nth-child(1) { top: 0; }
.burger span:nth-child(2) { top: 7px; }
.burger span:nth-child(3) { top: 14px; }
body.menu-open .burger span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
body.menu-open .burger span:nth-child(2) { opacity: 0; }
body.menu-open .burger span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

/* ---------- hero ---------- */
.hero { position: relative; background: #1e1e18; overflow: hidden; }
.hero-media { position: relative; height: clamp(380px, 58vh, 640px); }
.hero-media img { width: 100%; height: 100%; object-fit: cover; opacity: .82; }
.hero-media::after {
  content: ""; position: absolute; inset: 0;
  background: linear-gradient(90deg, rgba(20,18,14,.84) 0%, rgba(20,18,14,.62) 32%, rgba(20,18,14,.26) 60%, rgba(20,18,14,.04) 100%);
}
.hero-copy {
  position: absolute; inset: 0; display: flex; align-items: center;
  max-width: var(--max); margin: 0 auto; padding: 0 24px;
}
.hero-box { max-width: 470px; color: #f8f5ea; }
.hero-eyebrow {
  font-size: 11px; letter-spacing: .28em; text-transform: uppercase;
  color: var(--gold); margin-bottom: 18px;
}
.hero-title {
  font-family: Georgia, "Times New Roman", serif;
  font-size: clamp(30px, 4.2vw, 52px); line-height: 1.1; letter-spacing: -.01em;
  margin-bottom: 16px; font-weight: 400;
}
.hero-sub { font-size: 14.5px; color: rgba(247,242,234,.8); max-width: 380px; margin-bottom: 26px; }

/* ---------- buttons ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 9px;
  font-size: 11.5px; letter-spacing: .16em; text-transform: uppercase; font-weight: 600;
  padding: 14px 30px; border: 1px solid transparent;
  transition: background .25s var(--ease), color .25s var(--ease), border-color .25s;
}
.btn-dark { background: var(--ink); color: var(--paper); }
.btn-dark:hover { background: #35352c; }
.btn-light { background: #f8f5ea; color: var(--ink); }
.btn-light:hover { background: #fff; }
.btn-line { border-color: var(--ink); color: var(--ink); background: transparent; }
.btn-line:hover { background: var(--ink); color: var(--paper); }
.btn-block { width: 100%; }
.btn[disabled] { opacity: .42; cursor: not-allowed; }

/* ---------- sections ---------- */
.section { padding: 74px 0; }
.section.tight { padding: 48px 0; }
.section.alt { background: var(--paper-2); }
.sec-head {
  display: flex; align-items: flex-end; justify-content: space-between;
  gap: 20px; margin-bottom: 34px; flex-wrap: wrap;
}
.sec-title {
  font-family: Georgia, serif; font-size: clamp(22px, 2.4vw, 31px);
  font-weight: 400; letter-spacing: -.01em; line-height: 1.2;
}
.sec-sub { font-size: 12px; letter-spacing: .14em; text-transform: uppercase; color: var(--ink-soft); margin-bottom: 8px; }
.sec-link {
  font-size: 11.5px; letter-spacing: .14em; text-transform: uppercase;
  border-bottom: 1px solid var(--ink); padding-bottom: 3px; white-space: nowrap;
}
.sec-link:hover { color: var(--accent); border-color: var(--accent); }

/* ---------- product grid ---------- */
.grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 28px 22px; }
.grid.three { grid-template-columns: repeat(3, 1fr); }

.card { display: block; }
.card-img {
  position: relative; overflow: hidden; background: var(--paper-2);
  aspect-ratio: 4 / 5;
}
.card-img img {
  width: 100%; height: 100%; object-fit: cover;
  transition: transform .7s var(--ease);
}
.card-img img.back {
  position: absolute; inset: 0; opacity: 0; transition: opacity .45s var(--ease), transform .7s var(--ease);
}
.card:hover .card-img img { transform: scale(1.035); }
.card:hover .card-img img.back { opacity: 1; }
.badge {
  position: absolute; top: 12px; left: 12px; z-index: 2;
  background: rgba(250,248,245,.94); color: var(--ink);
  font-size: 9.5px; letter-spacing: .16em; text-transform: uppercase;
  padding: 5px 9px; font-weight: 600;
}
.badge.gold { background: var(--gold); color: #fff; }
.card-meta { padding-top: 13px; }
.card-name { font-size: 13.5px; letter-spacing: .01em; margin-bottom: 3px; }
.card-type { font-size: 11px; letter-spacing: .1em; text-transform: uppercase; color: var(--ink-soft); }
.card-price { font-size: 13.5px; color: var(--ink-2); margin-top: 5px; }

/* ---------- filters ---------- */
.filters { display: flex; flex-wrap: wrap; gap: 9px; margin-bottom: 32px; }
.chip {
  font-size: 11px; letter-spacing: .11em; text-transform: uppercase;
  padding: 8px 16px; border: 1px solid var(--line); color: var(--ink-soft);
  background: transparent; transition: all .22s;
}
.chip:hover { border-color: var(--ink); color: var(--ink); }
.chip.on { background: var(--ink); border-color: var(--ink); color: var(--paper); }

/* ---------- page head ---------- */
.page-head { padding: 54px 0 34px; border-bottom: 1px solid var(--line); }
.page-head h1 {
  font-family: Georgia, serif; font-weight: 400;
  font-size: clamp(26px, 3.4vw, 40px); line-height: 1.15; letter-spacing: -.015em;
}
.page-head p { color: var(--ink-soft); font-size: 14px; margin-top: 12px; max-width: 620px; }
.crumb { font-size: 11px; letter-spacing: .12em; text-transform: uppercase; color: var(--ink-soft); margin-bottom: 16px; }
.crumb a:hover { color: var(--ink); }

/* ---------- promise strip ---------- */
.promises { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1px; background: var(--line); border-block: 1px solid var(--line); }
.promise { background: var(--paper); padding: 34px 28px; }
.promise h3 { font-size: 12px; letter-spacing: .16em; text-transform: uppercase; margin-bottom: 9px; }
.promise p { font-size: 13px; color: var(--ink-soft); line-height: 1.65; }

/* ---------- editorial split ---------- */
.split { display: grid; grid-template-columns: 1fr 1fr; align-items: center; gap: 0; }
.split-media { aspect-ratio: 3 / 2; overflow: hidden; background: var(--paper-2); }
.split-media img { width: 100%; height: 100%; object-fit: cover; }
.split-body { padding: 20px clamp(24px, 5vw, 76px); }
.split-body h2 {
  font-family: Georgia, serif; font-weight: 400; font-size: clamp(23px, 2.6vw, 34px);
  line-height: 1.2; margin-bottom: 18px;
}
.split-body p { font-size: 14.5px; color: var(--ink-2); margin-bottom: 15px; }
.split-body .btn { margin-top: 12px; }

/* ---------- newsletter ---------- */
.newsletter { background: var(--ink); color: #f4efe7; padding: 64px 0; text-align: center; }
.newsletter h2 { font-family: Georgia, serif; font-weight: 400; font-size: clamp(22px, 2.6vw, 32px); margin-bottom: 10px; }
.newsletter p { font-size: 13.5px; color: rgba(244,239,231,.72); margin-bottom: 26px; }
.nl-form { display: flex; gap: 10px; max-width: 440px; margin: 0 auto; }
.nl-form input {
  flex: 1; background: transparent; border: 1px solid rgba(244,239,231,.28);
  color: #f4efe7; padding: 13px 16px; font-size: 13px;
}
.nl-form input::placeholder { color: rgba(244,239,231,.42); }
.nl-form input:focus { outline: none; border-color: rgba(244,239,231,.65); }
.nl-msg { font-size: 12px; color: var(--gold); margin-top: 14px; min-height: 16px; letter-spacing: .06em; }

/* ---------- footer ---------- */
.site-footer { background: #191913; color: #cbc8bb; padding: 62px 0 0; }
.foot-grid { display: grid; grid-template-columns: 1.6fr 1fr 1fr 1.2fr; gap: 40px; padding-bottom: 44px; }
.foot-brand { font-family: Georgia, serif; font-size: 15px; letter-spacing: .24em; text-transform: uppercase; color: #f4efe7; margin-bottom: 14px; }
.foot-desc { font-size: 12.5px; line-height: 1.75; color: #a09d92; max-width: 300px; }
.foot-h { font-size: 10.5px; letter-spacing: .18em; text-transform: uppercase; color: #f4efe7; margin-bottom: 16px; }
.foot-list li { margin-bottom: 9px; }
.foot-list a, .foot-list span { font-size: 12.5px; color: #a09d92; transition: color .2s; }
.foot-list a:hover { color: #f4efe7; }
.foot-bottom {
  border-top: 1px solid rgba(255,255,255,.08);
  padding: 22px 0 26px; display: flex; justify-content: space-between; gap: 18px;
  flex-wrap: wrap; font-size: 11.5px; color: #7d766c;
}
.pay { display: flex; gap: 7px; align-items: center; flex-wrap: wrap; }
.pay span {
  font-size: 9.5px; letter-spacing: .1em; padding: 5px 8px;
  border: 1px solid rgba(255,255,255,.14); color: #a8a096; border-radius: 2px;
}

/* ---------- PDP ---------- */
.pdp { display: grid; grid-template-columns: 1.15fr .85fr; gap: clamp(26px, 4vw, 62px); padding: 44px 0 20px; align-items: start; }
.gallery { display: grid; gap: 12px; }
.gallery figure { background: var(--paper-2); aspect-ratio: 4 / 5; overflow: hidden; }
.gallery img { width: 100%; height: 100%; object-fit: cover; }
.pdp-info { position: sticky; top: 92px; }
.pdp-type { font-size: 11px; letter-spacing: .16em; text-transform: uppercase; color: var(--ink-soft); margin-bottom: 10px; }
.pdp-name { font-family: Georgia, serif; font-weight: 400; font-size: clamp(24px, 2.8vw, 34px); line-height: 1.15; margin-bottom: 10px; }
.pdp-price { font-size: 16px; color: var(--ink-2); margin-bottom: 20px; }
.pdp-blurb { font-size: 14px; color: var(--ink-2); margin-bottom: 26px; }
.opt-label { font-size: 10.5px; letter-spacing: .16em; text-transform: uppercase; color: var(--ink-soft); margin-bottom: 10px; display: block; }
.opt-label b { color: var(--ink); font-weight: 600; letter-spacing: .06em; text-transform: none; }
.swatches { display: flex; gap: 9px; flex-wrap: wrap; margin-bottom: 22px; }
.swatch {
  font-size: 11.5px; letter-spacing: .04em; padding: 9px 15px;
  border: 1px solid var(--line); background: transparent; color: var(--ink-2);
  transition: all .2s;
}
.swatch:hover { border-color: var(--ink-soft); }
.swatch.on { border-color: var(--ink); background: var(--ink); color: var(--paper); }
.sizes { display: flex; gap: 8px; flex-wrap: wrap; margin-bottom: 26px; }
.size {
  min-width: 46px; padding: 11px 14px; text-align: center;
  border: 1px solid var(--line); font-size: 12px; letter-spacing: .06em;
  transition: all .2s;
}
.size:hover { border-color: var(--ink-soft); }
.size.on { border-color: var(--ink); background: var(--ink); color: var(--paper); }
.add-row { display: flex; gap: 10px; margin-bottom: 14px; }
.qty { display: flex; border: 1px solid var(--line); }
.qty button { width: 40px; font-size: 15px; color: var(--ink-soft); }
.qty button:hover { color: var(--ink); }
.qty input {
  width: 44px; text-align: center; border: none; background: transparent;
  font-size: 13px; -moz-appearance: textfield;
}
.qty input::-webkit-outer-spin-button, .qty input::-webkit-inner-spin-button { -webkit-appearance: none; margin: 0; }
.pdp-note { font-size: 12px; color: var(--ink-soft); margin-bottom: 22px; }
.acc { border-top: 1px solid var(--line); }
.acc details { border-bottom: 1px solid var(--line); }
.acc summary {
  padding: 15px 0; font-size: 11.5px; letter-spacing: .12em; text-transform: uppercase;
  cursor: pointer; list-style: none; display: flex; justify-content: space-between;
}
.acc summary::-webkit-details-marker { display: none; }
.acc summary::after { content: "+"; color: var(--ink-soft); }
.acc details[open] summary::after { content: "–"; }
.acc .acc-body { padding: 0 0 16px; font-size: 13px; color: var(--ink-soft); line-height: 1.75; }
.acc .acc-body li { padding-left: 14px; position: relative; margin-bottom: 5px; }
.acc .acc-body li::before { content: "·"; position: absolute; left: 0; }

/* ---------- cart ---------- */
.cart-wrap { display: grid; grid-template-columns: 1.5fr .85fr; gap: clamp(24px, 4vw, 56px); padding: 40px 0 30px; align-items: start; }
.cart-lines { border-top: 1px solid var(--line); }
.cart-line { display: grid; grid-template-columns: 104px 1fr auto; gap: 18px; padding: 20px 0; border-bottom: 1px solid var(--line); align-items: center; }
.cart-line img { width: 104px; aspect-ratio: 4/5; object-fit: cover; background: var(--paper-2); }
.cl-name { font-size: 13.5px; margin-bottom: 4px; }
.cl-opt { font-size: 11.5px; color: var(--ink-soft); letter-spacing: .04em; }
.cl-remove { font-size: 11px; color: var(--ink-soft); text-decoration: underline; text-underline-offset: 3px; margin-top: 8px; }
.cl-remove:hover { color: var(--ink); }
.cl-price { font-size: 13.5px; text-align: right; }
.cl-line-total { font-weight: 600; }
.summary { background: var(--paper-2); padding: 26px; position: sticky; top: 92px; }
.summary h2 { font-size: 11.5px; letter-spacing: .16em; text-transform: uppercase; margin-bottom: 20px; }
.sum-row { display: flex; justify-content: space-between; font-size: 13px; color: var(--ink-2); padding: 8px 0; }
.sum-row.total { border-top: 1px solid var(--line); margin-top: 12px; padding-top: 15px; font-size: 15px; font-weight: 600; color: var(--ink); }
.ship-bar { height: 3px; background: #ded6ca; margin: 16px 0 8px; overflow: hidden; }
.ship-bar i { display: block; height: 100%; background: var(--gold); transition: width .4s var(--ease); }
.ship-note { font-size: 11.5px; color: var(--ink-soft); margin-bottom: 18px; }
.empty { padding: 70px 0; text-align: center; color: var(--ink-soft); font-size: 14px; }

/* ---------- forms ---------- */
.form-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.field { display: flex; flex-direction: column; gap: 6px; }
.field.full { grid-column: 1 / -1; }
.field label { font-size: 10.5px; letter-spacing: .14em; text-transform: uppercase; color: var(--ink-soft); }
.field input, .field select, .field textarea {
  border: 1px solid var(--line); background: #fff; padding: 12px 14px;
  font-size: 13.5px; transition: border-color .2s;
}
.field input:focus, .field select:focus, .field textarea:focus { outline: none; border-color: var(--ink-soft); }
.form-sec { margin-bottom: 26px; }
.form-sec h3 { font-size: 11.5px; letter-spacing: .16em; text-transform: uppercase; margin-bottom: 14px; padding-bottom: 10px; border-bottom: 1px solid var(--line); }

/* ---------- prose ---------- */
.prose { max-width: 760px; padding: 44px 0 60px; }
.prose h2 { font-family: Georgia, serif; font-weight: 400; font-size: 21px; margin: 34px 0 12px; }
.prose h3 { font-size: 12px; letter-spacing: .14em; text-transform: uppercase; margin: 26px 0 10px; }
.prose p { font-size: 14px; color: var(--ink-2); margin-bottom: 13px; line-height: 1.78; }
.prose ul { margin: 0 0 16px; }
.prose li { font-size: 14px; color: var(--ink-2); padding-left: 16px; position: relative; margin-bottom: 7px; }
.prose li::before { content: "—"; position: absolute; left: 0; color: var(--ink-soft); }
.prose a { border-bottom: 1px solid var(--line); }
.prose a:hover { border-color: var(--ink); }
.prose .lede { font-size: 15.5px; color: var(--ink); }

.info-cards { display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px; padding: 34px 0 0; }
.info-card { border: 1px solid var(--line); padding: 24px; background: #fff; }
.info-card h3 { font-size: 10.5px; letter-spacing: .16em; text-transform: uppercase; color: var(--ink-soft); margin-bottom: 9px; }
.info-card p, .info-card a { font-size: 14px; line-height: 1.7; }
.info-card a:hover { color: var(--accent); }

/* ---------- toast ---------- */
.toast {
  position: fixed; left: 50%; bottom: 30px; transform: translate(-50%, 20px);
  background: var(--ink); color: var(--paper); padding: 13px 24px;
  font-size: 12px; letter-spacing: .08em; z-index: 200;
  opacity: 0; pointer-events: none; transition: all .35s var(--ease);
}
.toast.show { opacity: 1; transform: translate(-50%, 0); }

/* ---------- responsive ---------- */
@media (max-width: 1080px) {
  .grid { grid-template-columns: repeat(3, 1fr); }
  .foot-grid { grid-template-columns: 1fr 1fr; gap: 32px; }
}
@media (max-width: 860px) {
  .nav {
    position: absolute; top: 100%; left: 0; right: 0;
    display: none; flex-direction: column; gap: 0;
    padding: 4px 24px 16px;
    background: var(--paper);
    border-bottom: 1px solid var(--line);
    box-shadow: 0 20px 34px -22px rgba(20, 18, 16, .35);
    z-index: 55;
  }
  body.menu-open .nav { display: flex; animation: navIn .26s var(--ease); }
  @keyframes navIn { from { opacity: 0; transform: translateY(-7px); } to { opacity: 1; transform: none; } }
  .nav a { font-size: 15px; letter-spacing: .08em; padding: 16px 0; border-bottom: 1px solid var(--line); }
  .nav a:last-child { border-bottom: none; }
  .nav a::after { display: none; }
  .burger { display: block; }
  .header-inner { padding: 14px 18px; }
  .brand { font-size: 14px; letter-spacing: .2em; }
  .grid, .grid.three { grid-template-columns: repeat(2, 1fr); gap: 24px 14px; }
  .promises { grid-template-columns: 1fr; }
  .split { grid-template-columns: 1fr; }
  .split-media { aspect-ratio: 16 / 11; }
  .split-body { padding: 34px 22px 40px; }
  .pdp { grid-template-columns: 1fr; padding-top: 26px; }
  .pdp-info { position: static; }
  .gallery { grid-template-columns: 1fr 1fr; }
  .cart-wrap { grid-template-columns: 1fr; }
  .summary { position: static; }
  .info-cards { grid-template-columns: 1fr; }
  .section { padding: 52px 0; }
  .page-head { padding: 34px 0 26px; }
  .hero-copy { padding: 0 20px; }
  .hero-media { height: 62vh; min-height: 400px; }
  .hero-media::after {
    background: linear-gradient(180deg, rgba(20,18,14,.18) 0%, rgba(20,18,14,.34) 30%, rgba(20,18,14,.62) 62%, rgba(20,18,14,.72) 100%);
  }
  .foot-grid { grid-template-columns: 1fr; gap: 28px; }
  .cart-line { grid-template-columns: 84px 1fr; }
  .cart-line img { width: 84px; }
  .cl-price { grid-column: 2; text-align: left; margin-top: -6px; }
}
@media (max-width: 520px) {
  .grid, .grid.three { grid-template-columns: 1fr; }
  .nl-form { flex-direction: column; }
  .form-grid { grid-template-columns: 1fr; }
  .gallery { grid-template-columns: 1fr; }
  .add-row { flex-wrap: wrap; }
  .add-row .btn { flex: 1; }
}
