/* Montanha shop — builds on /styles.css tokens */
.shop-page { background: var(--wool); }
.nav.solid { background: rgba(19,21,27,.92); }
.nav-links a[aria-current="page"] { opacity: 1; }
.nav-links a[aria-current="page"]::after { transform: scaleX(1); }

.cart-btn {
  position: relative; display: grid; place-items: center; width: 40px; height: 40px;
  background: none; border: 0; color: inherit; cursor: pointer; border-radius: 50%;
}
.cart-btn:hover { background: rgba(243,236,225,.08); }
.cart-count {
  position: absolute; top: 2px; right: 0; min-width: 18px; height: 18px; padding: 0 5px; border-radius: 9px;
  background: var(--tan); color: var(--wool); font: 600 11px/18px var(--sans); text-align: center;
}
.cart-count.bump { animation: bump .5s var(--ease); }
@keyframes bump { 40% { transform: scale(1.35); } }

/* ---- hero ---- */
.shop-hero { position: relative; min-height: 58vh; display: flex; align-items: flex-end; overflow: hidden; color: var(--wool); background: var(--night); }
.shop-hero picture { position: absolute; inset: 0; }
.shop-hero img { width: 100%; height: 100%; object-fit: cover; animation: kenburns 18s ease-out both; }
.shop-hero-shade { position: absolute; inset: 0; background: linear-gradient(to bottom, rgba(19,21,27,.55), rgba(19,21,27,.25) 40%, rgba(19,21,27,.85)); }
.shop-hero-inner { position: relative; padding: 140px var(--gutter) clamp(40px, 6vw, 72px); max-width: 1100px; }
.eyebrow { font-size: 12px; letter-spacing: .3em; text-transform: uppercase; color: var(--tan-soft); margin: 0 0 14px; }
.shop-hero h1 {
  font-family: var(--serif); font-weight: 330; font-size: clamp(40px, 6.4vw, 92px); line-height: 1; letter-spacing: -.02em;
  margin: 0 0 18px; font-variation-settings: "SOFT" 80, "opsz" 144; text-wrap: balance;
}
.shop-hero p:last-child { max-width: 36em; font-size: clamp(16px, 1.5vw, 19px); color: rgba(243,236,225,.85); margin: 0; }

.notice { margin: 24px var(--gutter) 0; padding: 14px 18px; border-left: 3px solid var(--tan); background: var(--wool-2); font-size: 15px; }

/* ---- grid ---- */
.shop-grid-wrap { padding: clamp(40px, 6vw, 80px) var(--gutter); }
.shop-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 260px), 1fr)); gap: clamp(16px, 2vw, 28px); max-width: 1400px; margin: 0 auto; }
.loading { color: var(--muted); }
.card { opacity: 0; transform: translateY(20px); animation: cardIn .9s var(--ease) forwards; animation-delay: calc(var(--i) * 70ms); }
@keyframes cardIn { to { opacity: 1; transform: none; } }
.card-hit {
  all: unset; box-sizing: border-box; display: flex; flex-direction: column; width: 100%; height: 100%; cursor: pointer;
  background: #fbf7f0; border-radius: 3px; overflow: hidden; transition: transform .5s var(--ease), box-shadow .5s var(--ease);
}
.card-hit:hover { transform: translateY(-6px); box-shadow: 0 30px 60px -30px rgba(60,40,20,.45); }
.card-hit:focus-visible { outline: 2px solid var(--tan); outline-offset: 3px; }
.card-media { position: relative; aspect-ratio: 4/5; background: #fff; display: grid; place-items: center; overflow: hidden; }
.card-media picture, .card-media img { width: 100%; height: 100%; }
.card-media img { object-fit: contain; padding: 8%; transition: transform 1.1s var(--ease); }
.card-hit:hover .card-media img { transform: scale(1.06); }
.card-body { padding: 18px 20px 22px; }
.card-origin { margin: 0 0 4px; font-size: 11px; letter-spacing: .2em; text-transform: uppercase; color: var(--muted); }
.card h3 { font-family: var(--serif); font-weight: 450; font-size: 22px; line-height: 1.15; margin: 0 0 8px; font-variation-settings: "SOFT" 60; }
.card-price { margin: 0; font-family: var(--serif); font-size: 19px; color: var(--tan); }
.card.sold .card-media > :not(.badge) { opacity: .45; filter: grayscale(.6); }
.badge { position: absolute; top: 14px; left: 14px; background: var(--ink); color: var(--wool); font-size: 11px; letter-spacing: .14em; text-transform: uppercase; padding: 6px 10px; border-radius: 2px; }

/* woven swatch artwork when a product has no photo yet */
.swatch-art {
  width: 100%; height: 100%; display: grid; place-items: end start; padding: 22px; color: var(--wool);
  background:
    repeating-linear-gradient(45deg, rgba(255,255,255,.14) 0 2px, transparent 2px 7px),
    repeating-linear-gradient(-45deg, rgba(0,0,0,.18) 0 2px, transparent 2px 7px),
    var(--sw);
}
.swatch-art span { font-family: var(--serif); font-style: italic; font-size: 26px; line-height: 1.1; text-shadow: 0 1px 8px rgba(0,0,0,.25); }
.swatch-art.big span { font-size: clamp(30px, 4vw, 44px); }
.swatch-art.mini { width: 100%; height: 100%; padding: 0; }

/* ---- promises strip ---- */
.promises {
  display: grid; grid-template-columns: repeat(4, 1fr); gap: 24px; max-width: 1400px; margin: 0 auto;
  padding: 0 var(--gutter) clamp(64px, 8vw, 110px); font-size: 14.5px; color: var(--ink-soft);
}
.promises div { border-top: 2px solid var(--ink); padding-top: 16px; display: flex; flex-direction: column; gap: 4px; }
.promises strong { font-family: var(--serif); font-weight: 450; font-size: 19px; color: var(--ink); }
.promises a { color: var(--tan); }
@media (max-width: 900px) { .promises { grid-template-columns: 1fr 1fr; } }
@media (max-width: 520px) { .promises { grid-template-columns: 1fr; } }

/* ---- product dialog ---- */
.pd {
  width: min(1080px, calc(100vw - 32px)); max-height: calc(100dvh - 32px); padding: 0; border: 0; border-radius: 4px;
  background: var(--wool); color: var(--ink); box-shadow: 0 40px 120px rgba(0,0,0,.45); overflow: auto;
}
.pd::backdrop { background: rgba(13,15,21,.7); -webkit-backdrop-filter: blur(4px); backdrop-filter: blur(4px); }
.pd[open] { animation: pdIn .5s var(--ease); }
@keyframes pdIn { from { opacity: 0; transform: translateY(24px) scale(.98); } }
.pd-close {
  position: absolute; top: 12px; right: 12px; z-index: 2; width: 40px; height: 40px; border-radius: 50%;
  border: 0; background: rgba(243,236,225,.9); color: var(--ink); font-size: 26px; line-height: 1; cursor: pointer;
}
.pd-close:hover { background: var(--wool-3); }
.pd-grid { display: grid; grid-template-columns: 1.05fr 1fr; }
.pd-media { background: #fff; padding: 20px; display: flex; flex-direction: column; gap: 12px; }
.pd-main { aspect-ratio: 1; display: grid; place-items: center; overflow: hidden; }
.pd-main picture, .pd-main img { width: 100%; height: 100%; }
.pd-main img { object-fit: contain; }
.pd-thumbs { display: flex; gap: 8px; }
.pd-thumbs button { width: 64px; height: 64px; padding: 4px; border: 1px solid var(--wool-3); background: #fff; cursor: pointer; border-radius: 2px; }
.pd-thumbs button.on { border-color: var(--ink); }
.pd-thumbs img { width: 100%; height: 100%; object-fit: cover; }
.pd-info { padding: clamp(28px, 4vw, 52px); display: flex; flex-direction: column; }
.pd-origin { font-size: 11px; letter-spacing: .24em; text-transform: uppercase; color: var(--tan); margin: 0 0 8px; }
.pd-info h2 { font-family: var(--serif); font-weight: 400; font-size: clamp(32px, 3.6vw, 46px); line-height: 1.05; margin: 0 0 10px; font-variation-settings: "SOFT" 70, "opsz" 96; }
.pd-price { font-family: var(--serif); font-size: 24px; color: var(--tan); margin: 0 0 20px; }
.pd-desc { font-size: 16px; color: var(--ink-soft); margin: 0 0 12px; }
.pd-material { font-size: 14px; color: var(--muted); margin: 0 0 24px; }
.pd-material strong { color: var(--ink-soft); font-weight: 600; }
.pd-options { border: 0; padding: 0; margin: 0 0 12px; }
.pd-options legend { font-size: 12px; letter-spacing: .18em; text-transform: uppercase; color: var(--ink-soft); margin-bottom: 10px; font-weight: 600; }
.chips { display: flex; flex-wrap: wrap; gap: 8px; }
.chip {
  min-width: 48px; padding: 10px 14px; border: 1px solid var(--wool-3); background: #fbf7f0; border-radius: 3px;
  font: 500 14px var(--sans); color: var(--ink); cursor: pointer; transition: border-color .2s, background .2s;
}
.chip:hover:not(:disabled) { border-color: var(--ink); }
.chip.on { background: var(--ink); color: var(--wool); border-color: var(--ink); }
.chip:disabled { color: var(--muted); text-decoration: line-through; cursor: not-allowed; opacity: .6; }
.pd-stock { font-size: 14px; color: var(--muted); margin: 6px 0 20px; min-height: 1.4em; }
.pd-stock.low { color: var(--ember); font-weight: 600; }
.pd-buy { display: flex; gap: 12px; align-items: stretch; margin-top: auto; }
.qty { display: inline-flex; align-items: center; border: 1px solid var(--wool-3); border-radius: 999px; background: #fbf7f0; }
.qty button { width: 42px; height: 48px; border: 0; background: none; font-size: 20px; cursor: pointer; color: var(--ink); }
.qty button:disabled { color: var(--wool-3); cursor: default; }
.qty output { min-width: 22px; text-align: center; font-weight: 600; }
.qty.sm button { width: 32px; height: 32px; font-size: 16px; }
.btn-buy {
  flex: 1; border: 0; border-radius: 999px; padding: 0 26px; min-height: 50px; cursor: pointer;
  background: var(--tan); color: var(--wool); font: 600 14px var(--sans); letter-spacing: .1em; text-transform: uppercase;
  transition: background .3s, transform .3s var(--ease);
}
.btn-buy:hover:not(:disabled) { background: var(--ember); transform: translateY(-1px); }
.btn-buy:disabled { background: var(--wool-3); color: var(--muted); cursor: not-allowed; }
.btn-buy.wide { width: 100%; }
.btn-buy.busy { opacity: .7; pointer-events: none; }
.pd-vat { font-size: 12.5px; color: var(--muted); margin: 12px 0 0; }
@media (max-width: 760px) {
  .pd-grid { grid-template-columns: 1fr; }
  .pd-main { aspect-ratio: 4/3; }
}

/* ---- cart drawer ---- */
.drawer-scrim { position: fixed; inset: 0; z-index: 60; background: rgba(13,15,21,.55); opacity: 0; transition: opacity .4s; }
.drawer-scrim.open { opacity: 1; }
.drawer {
  position: fixed; top: 0; right: 0; bottom: 0; z-index: 61; width: min(460px, 100vw);
  background: var(--wool); display: flex; flex-direction: column; box-shadow: -30px 0 80px rgba(0,0,0,.3);
  transform: translateX(105%); transition: transform .45s var(--ease); visibility: hidden;
}
.drawer.open { transform: none; visibility: visible; }
.drawer-head { display: flex; align-items: center; justify-content: space-between; padding: 20px 24px; border-bottom: 1px solid var(--wool-3); }
.drawer-head h2 { font-family: var(--serif); font-weight: 400; font-size: 28px; margin: 0; }
.drawer-head .pd-close { position: static; }
.drawer-body { flex: 1; overflow: auto; padding: 8px 24px; }
.empty { padding: 60px 0; text-align: center; font-family: var(--serif); font-size: 22px; }
.empty .muted { font-size: 16px; color: var(--muted); font-style: italic; }
.line { display: grid; grid-template-columns: 72px 1fr auto; gap: 14px; padding: 18px 0; border-bottom: 1px solid var(--wool-3); }
.line-img { width: 72px; height: 88px; background: #fff; border-radius: 2px; overflow: hidden; }
.line-img img { width: 100%; height: 100%; object-fit: contain; padding: 6px; }
.line-name { font-family: var(--serif); font-size: 18px; margin: 0; line-height: 1.2; }
.line-var { font-size: 13px; color: var(--muted); margin: 2px 0 8px; }
.line-warn { font-size: 13px; color: var(--ember); font-weight: 600; margin: 0 0 6px; }
.line.over { background: rgba(168,60,52,.05); }
.line-end { text-align: right; display: flex; flex-direction: column; justify-content: space-between; align-items: flex-end; }
.line-end p { margin: 0; font-family: var(--serif); font-size: 17px; }
.link { background: none; border: 0; padding: 0; color: var(--muted); font: 13px var(--sans); text-decoration: underline; cursor: pointer; }
.drawer-foot { padding: 18px 24px 22px; border-top: 1px solid var(--wool-3); background: #fbf7f0; max-height: 70vh; overflow: auto; }
.ship { border: 0; padding: 0; margin: 0 0 14px; }
.ship legend { font-size: 12px; letter-spacing: .18em; text-transform: uppercase; font-weight: 600; color: var(--ink-soft); margin-bottom: 8px; }
.ship-opt { display: flex; align-items: center; gap: 10px; padding: 9px 12px; border: 1px solid var(--wool-3); border-radius: 3px; margin-bottom: 6px; cursor: pointer; font-size: 14.5px; background: var(--wool); }
.ship-opt.on { border-color: var(--ink); background: #fff; }
.ship-opt input { accent-color: var(--tan); margin: 0; }
.ship-name { flex: 1; display: flex; flex-direction: column; }
.ship-name small { color: var(--muted); font-size: 12px; }
.ship-cost { font-weight: 600; }
.totals { margin: 0 0 12px; }
.totals div { display: flex; justify-content: space-between; padding: 3px 0; font-size: 15px; }
.totals dt, .totals dd { margin: 0; }
.totals .grand { font-family: var(--serif); font-size: 22px; padding-top: 8px; margin-top: 6px; border-top: 1px solid var(--wool-3); }
.fine-print { font-size: 12px; color: var(--muted); margin: 0 0 12px; line-height: 1.5; }
.fine-print a { color: var(--ink-soft); }
.cart-error { color: var(--ember); font-size: 14px; font-weight: 600; margin: 0 0 10px; }
.secure { font-size: 12px; color: var(--muted); text-align: center; margin: 10px 0 0; }

/* ---- small footer ---- */
.foot.small { padding-top: 72px; }
.foot.small .foot-logo { width: 150px; }
.foot-links a { color: var(--tan-soft); text-decoration: none; }

/* ---- legal + thank-you pages ---- */
.doc { max-width: 760px; margin: 0 auto; padding: 130px var(--gutter) 90px; }
.doc h1 { font-family: var(--serif); font-weight: 350; font-size: clamp(36px, 5vw, 58px); line-height: 1.05; margin: 0 0 12px; font-variation-settings: "SOFT" 70, "opsz" 144; }
.doc h2 { font-family: var(--serif); font-weight: 450; font-size: 22px; margin: 36px 0 10px; }
.doc p, .doc li { font-size: 16px; color: var(--ink-soft); }
.doc .stand { color: var(--muted); font-size: 14px; }
.doc .draft { background: #fff4e4; border-left: 3px solid #e0a36b; padding: 12px 16px; font-size: 14px; color: var(--ink); }
.doc .form-box { border: 1px solid var(--wool-3); background: #fbf7f0; padding: 20px 24px; }
.thanks-mark { width: 120px; margin: 0 0 28px; }
.order-box { border: 1px solid var(--wool-3); background: #fbf7f0; padding: 20px 24px; margin: 28px 0; }
.order-box .row { display: flex; justify-content: space-between; gap: 16px; padding: 6px 0; font-size: 15px; }
.order-box .row.total { font-family: var(--serif); font-size: 20px; border-top: 1px solid var(--wool-3); margin-top: 8px; padding-top: 12px; }
.btn-line { display: inline-block; padding: 12px 22px; border: 1px solid var(--ink); border-radius: 999px; text-decoration: none; color: var(--ink); font-weight: 600; font-size: 14px; letter-spacing: .06em; }
