/* ==========================================================================
   Azkoo storefront — kilim palette: indigo, madder, weld, undyed wool
   ========================================================================== */

@font-face { font-family: "Vazirmatn FD"; src: url("../fonts/Vazirmatn-FD-Regular.woff2") format("woff2"); font-weight: 400; font-display: swap; }
@font-face { font-family: "Vazirmatn FD"; src: url("../fonts/Vazirmatn-FD-Medium.woff2") format("woff2"); font-weight: 500; font-display: swap; }
@font-face { font-family: "Vazirmatn FD"; src: url("../fonts/Vazirmatn-FD-Bold.woff2") format("woff2"); font-weight: 700; font-display: swap; }
@font-face { font-family: "Vazirmatn FD"; src: url("../fonts/Vazirmatn-FD-Black.woff2") format("woff2"); font-weight: 900; font-display: swap; }
@font-face { font-family: "Lalezar"; src: url("../fonts/Lalezar-arabic.woff2") format("woff2"); font-weight: 400; font-display: swap;
  unicode-range: U+0600-06FF, U+0750-077F, U+0870-088E, U+0890-0891, U+0898-08E1, U+08E3-08FF, U+200C-200E, U+2010-2011, U+204F, U+2E41, U+FB50-FDFF, U+FE70-FE74, U+FE76-FEFC; }
@font-face { font-family: "Lalezar"; src: url("../fonts/Lalezar-latin.woff2") format("woff2"); font-weight: 400; font-display: swap;
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }

:root {
  --indigo: #1E2852;
  --indigo-2: #2A3A72;
  --indigo-ink: #151C3D;
  --madder: #B22A2E;
  --madder-dk: #8E2228;
  --weld: #E0A526;
  --wool: #EEEBE4;
  --wool-2: #E4DFD4;
  --paper: #FFFFFF;
  --ink: #1B1E2E;
  --muted: #5E606E;
  --line: #D9D3C6;
  --pasture: #4F6D3A;
  --pasture-bg: #E6ECDD;
  --ok: #2F6B3A;
  --err: #A3262A;

  --r-s: 8px;
  --r: 14px;
  --r-l: 22px;
  --shadow: 0 1px 2px rgb(30 40 82 / .06), 0 10px 28px -14px rgb(30 40 82 / .28);
  --shadow-up: 0 2px 4px rgb(30 40 82 / .08), 0 18px 36px -16px rgb(30 40 82 / .36);

  --font: "Vazirmatn FD", "Vazirmatn", Tahoma, system-ui, sans-serif;
  --display: "Lalezar", "Vazirmatn FD", Tahoma, sans-serif;
  --gutter: 20px;
  --kilim: url("../img/kilim.svg");
  color-scheme: light;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-padding-top: 84px; }
@media (prefers-reduced-motion: no-preference) {
  html { scroll-behavior: smooth; }
  @view-transition { navigation: auto; }
}
body {
  margin: 0;
  font-family: var(--font);
  font-size: 16px;
  line-height: 1.85;
  color: var(--ink);
  background: var(--wool);
  text-rendering: optimizeLegibility;
  -webkit-font-smoothing: antialiased;
}
img, svg { max-width: 100%; height: auto; }
img { display: block; }
a { color: inherit; }
button, input, select, textarea { font: inherit; color: inherit; }
h1, h2, h3, h4 { margin: 0; line-height: 1.35; }
p { margin: 0 0 1em; }
ul, ol { margin: 0; padding: 0; }
dl, dd { margin: 0; }
:focus-visible { outline: 3px solid var(--weld); outline-offset: 2px; border-radius: 4px; }

.ic { width: 1.25em; height: 1.25em; flex: none; vertical-align: -0.22em; }
.ic--huge { width: 64px; height: 64px; }
.sr, .hp { position: absolute !important; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; inset-inline-start: 0; }
.hp { opacity: 0; pointer-events: none; }
.skip { position: absolute; inset-inline-start: 12px; top: -60px; z-index: 100; background: var(--weld); color: var(--indigo-ink); padding: 8px 16px; border-radius: var(--r-s); font-weight: 700; }
.skip:focus { top: 12px; }
[hidden] { display: none !important; }

.wrap { width: 100%; max-width: 1200px; margin-inline: auto; padding-inline: var(--gutter); }
.wrap--narrow { max-width: 760px; }

/* ---------- kilim band ---------- */
.kilim { height: 20px; background: var(--kilim) repeat-x center / auto 100%; }
.kilim--thin { height: 10px; }

/* ---------- buttons ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: .5em;
  min-height: 44px; padding: 10px 20px; border-radius: 10px; border: 1.5px solid transparent;
  font-weight: 700; font-size: 15px; line-height: 1.3; text-decoration: none; cursor: pointer;
  transition: background-color .18s, color .18s, border-color .18s, transform .12s, box-shadow .18s;
  -webkit-tap-highlight-color: transparent;
}
.btn:active { transform: translateY(1px) scale(.98); }
.btn[disabled] { opacity: .5; pointer-events: none; }
.btn--primary { background: var(--madder); color: #fff; box-shadow: 0 6px 16px -8px rgb(178 42 46 / .7); }
.btn--primary:hover { background: var(--madder-dk); }
.btn--light { background: #fff; color: var(--indigo); }
.btn--light:hover { background: var(--wool); }
.btn--ghost { background: transparent; border-color: var(--line); color: var(--ink); }
.btn--ghost:hover { border-color: var(--indigo); color: var(--indigo); }
.btn--lg { min-height: 52px; padding: 12px 26px; font-size: 16px; border-radius: 12px; }
.btn--sm { min-height: 36px; padding: 6px 14px; font-size: 14px; }
.btn--block { width: 100%; }
.btn--add { background: var(--indigo); color: #fff; min-height: 38px; padding: 6px 12px; font-size: 13.5px; border-radius: 9px; white-space: nowrap; flex: none; }
.btn--add:hover { background: var(--madder); }
.btn.is-busy { opacity: .7; pointer-events: none; }

.iconbtn {
  display: inline-grid; place-items: center; width: 42px; height: 42px; border-radius: 10px;
  border: 0; background: transparent; color: inherit; cursor: pointer;
}
.iconbtn:hover { background: rgb(30 40 82 / .08); }
.iconbtn--sm { width: 32px; height: 32px; }
.link { display: inline-flex; align-items: center; gap: 6px; color: var(--madder); font-weight: 700; text-decoration: none; }
.link:hover { text-decoration: underline; text-underline-offset: 5px; }

/* ---------- top bar ---------- */
.topbar { position: sticky; top: 0; z-index: 40; background: var(--indigo); color: #fff; }
.topbar__in { display: flex; align-items: center; gap: 24px; min-height: 68px; }
.brand { display: inline-flex; align-items: center; gap: 10px; text-decoration: none; color: inherit; }
.brand__mark, .brand__img { width: 40px; height: 40px; border-radius: 11px; }
.brand__img { object-fit: contain; background: #fff; }
.brand__name { font-family: var(--display); font-size: 30px; line-height: 1; padding-top: 4px; letter-spacing: 0; }
.mainnav { display: flex; gap: 4px; margin-inline-start: 12px; }
.mainnav a {
  position: relative; padding: 8px 12px; border-radius: 8px; text-decoration: none;
  color: rgb(255 255 255 / .78); font-weight: 500; font-size: 15px;
}
.mainnav a:hover { color: #fff; background: rgb(255 255 255 / .08); }
.mainnav a[aria-current="page"] { color: #fff; }
.mainnav a[aria-current="page"]::after {
  content: ""; position: absolute; inset-inline: 12px; bottom: 2px; height: 3px; border-radius: 3px; background: var(--weld);
}
.topbar__actions { display: flex; align-items: center; gap: 6px; margin-inline-start: auto; }
.cartbtn {
  position: relative; display: inline-flex; align-items: center; gap: 8px; min-height: 42px;
  padding: 8px 16px; border-radius: 999px; background: var(--madder); color: #fff; text-decoration: none; font-weight: 700; font-size: 14.5px;
}
.cartbtn:hover { background: var(--madder-dk); }
.cartbtn__count {
  display: inline-grid; place-items: center; min-width: 24px; height: 24px; padding: 0 6px;
  border-radius: 999px; background: var(--weld); color: var(--indigo-ink); font-size: 13px; font-weight: 900;
}
.cartbtn.is-bump .cartbtn__count { animation: bump .5s cubic-bezier(.3, 1.6, .5, 1); }
@keyframes bump { 0% { transform: scale(1); } 40% { transform: scale(1.45); } 100% { transform: scale(1); } }
.menubtn { display: none; color: #fff; }
.menubtn:hover { background: rgb(255 255 255 / .1); }

@media (max-width: 900px) {
  .mainnav { display: none; }
  .menubtn { display: inline-grid; }
  .cartbtn__label { display: none; }
  .cartbtn { padding-inline: 12px; }
  .topbar__in { min-height: 60px; gap: 12px; }
  .brand__name { font-size: 26px; }
}

/* ---------- flash ---------- */
.flashes { padding-top: 18px; display: grid; gap: 10px; }
.flash { display: flex; align-items: flex-start; gap: 10px; margin: 0; padding: 12px 16px; border-radius: var(--r-s); font-weight: 500; border: 1px solid; }
.flash .ic { margin-top: 4px; }
.flash--ok { background: #E8F1E3; color: var(--ok); border-color: #C9DEC0; }
.flash--err { background: #F8E7E6; color: var(--err); border-color: #EBC3C1; }

/* ---------- hero ---------- */
.hero { position: relative; overflow: hidden; color: #fff; background: var(--indigo); isolation: isolate; }
.hero__land {
  position: absolute; inset: auto 0 20px 0; height: min(52%, 380px); z-index: -1;
  background: url("../img/hero-landscape.svg") center bottom / cover no-repeat;
}
.hero__in { padding-block: clamp(40px, 7vw, 88px) clamp(190px, 26vw, 330px); }
.hero__copy { max-width: 640px; }
.hero__title { font-family: var(--display); font-weight: 400; display: grid; justify-items: start; gap: 4px; }
.hero__pre, .hero__post { font-size: clamp(34px, 6vw, 64px); line-height: 1.15; }
.hero__pre { color: rgb(255 255 255 / .82); }
.tag {
  position: relative; display: inline-flex; align-items: center; margin-block: 10px 6px;
  padding: 10px 28px 2px 30px; padding-inline-start: 64px;
  background: var(--madder); color: #fff; border-radius: 14px 26px 26px 14px;
  font-size: clamp(40px, 8.2vw, 92px); line-height: 1.25; min-height: 1.4em;
  transform: rotate(-2.5deg); transform-origin: 90% 0;
  box-shadow: 0 18px 40px -18px rgb(0 0 0 / .6), inset 0 -6px 0 rgb(0 0 0 / .12);
}
.tag__hole {
  position: absolute; inset-inline-start: 22px; top: 50%; width: 18px; height: 18px; margin-top: -9px;
  border-radius: 50%; background: var(--indigo); box-shadow: inset 0 2px 3px rgb(0 0 0 / .4);
}
.tag__hole::before {
  content: ""; position: absolute; width: 2px; height: 1.15em; bottom: 50%; left: 8px; transform: rotate(18deg); transform-origin: bottom;
  background: linear-gradient(var(--weld), rgb(224 165 38 / 0)); opacity: .8;
}
.tag__text { display: inline-block; white-space: nowrap; }
.tag.is-flip .tag__text { animation: flipOut .32s ease-in forwards; }
.tag.is-flop .tag__text { animation: flipIn .5s cubic-bezier(.2, 1.4, .4, 1) forwards; }
.tag.is-swing { animation: swing 1s cubic-bezier(.2, .9, .3, 1); }
@keyframes flipOut { to { transform: rotateX(90deg); opacity: 0; } }
@keyframes flipIn { from { transform: rotateX(-90deg); opacity: 0; } to { transform: none; opacity: 1; } }
@keyframes swing { 0% { transform: rotate(-2.5deg); } 25% { transform: rotate(-6deg); } 55% { transform: rotate(.5deg); } 80% { transform: rotate(-3.4deg); } 100% { transform: rotate(-2.5deg); } }
.hero__lead { max-width: 52ch; margin-top: 18px; font-size: clamp(16px, 1.6vw, 18.5px); color: rgb(255 255 255 / .86); }
.hero__cta { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 26px; }
.kilim--hero { position: absolute; inset: auto 0 0 0; }

@media (prefers-reduced-motion: no-preference) {
  .is-home .hero__pre, .is-home .tag, .is-home .hero__post, .is-home .hero__lead, .is-home .hero__cta { animation: rise .7s cubic-bezier(.2, .8, .2, 1) both; }
  .is-home .tag { animation-name: rise, swing; animation-duration: .7s, 1.2s; animation-delay: .12s, .6s; }
  .is-home .hero__post { animation-delay: .22s; }
  .is-home .hero__lead { animation-delay: .34s; }
  .is-home .hero__cta { animation-delay: .44s; }
  .is-home .hero__land { animation: landIn 1.2s cubic-bezier(.2, .8, .2, 1) both; }
}
@keyframes rise { from { opacity: 0; transform: translateY(18px); } }
@keyframes landIn { from { opacity: 0; transform: translateY(40px); } }
.tag { --r: -2.5deg; }

/* ---------- why strip ---------- */
.why { background: var(--paper); border-bottom: 1px solid var(--line); }
.why__list { display: flex; list-style: none; gap: 8px 28px; padding-block: 16px; overflow-x: auto; scrollbar-width: none; justify-content: space-between; }
.why__list::-webkit-scrollbar { display: none; }
.why__list li { display: flex; align-items: center; gap: 10px; white-space: nowrap; font-weight: 700; font-size: 15px; color: var(--indigo); }
.why__list .ic { color: var(--madder); width: 26px; height: 26px; }

/* ---------- sections ---------- */
.section { padding-block: clamp(48px, 7vw, 84px); }
.section--first { padding-top: 36px; }
.section--tight { padding-block: clamp(36px, 5vw, 56px); }
.section--wool { background: var(--wool-2); }
.section__head { margin-bottom: 28px; max-width: 760px; }
.section__head--row { display: flex; align-items: end; justify-content: space-between; gap: 16px; max-width: none; flex-wrap: wrap; }
.section__title { font-family: var(--display); font-weight: 400; font-size: clamp(28px, 4vw, 42px); color: var(--indigo); line-height: 1.3; }
.section__lead { margin: 8px 0 0; color: var(--muted); font-size: 17px; max-width: 60ch; }
.empty { padding: 32px; text-align: center; color: var(--muted); background: var(--paper); border-radius: var(--r); border: 1.5px dashed var(--line); }
.empty--big { display: grid; justify-items: center; gap: 12px; padding: 56px 24px; }
.empty--big .ic { color: var(--line); }

/* ---------- page head ---------- */
.pagehead { background: var(--indigo); color: #fff; padding-block: 36px 34px; position: relative; }
.pagehead::after { content: ""; position: absolute; inset: auto 0 0 0; height: 10px; background: var(--kilim) repeat-x center / auto 100%; }
.pagehead__title { font-family: var(--display); font-weight: 400; font-size: clamp(30px, 5vw, 48px); }
.pagehead__lead { margin: 6px 0 0; color: rgb(255 255 255 / .82); max-width: 64ch; }
.pagehead__row { display: flex; justify-content: space-between; align-items: end; gap: 20px; flex-wrap: wrap; }
.score { display: grid; text-align: center; background: rgb(255 255 255 / .08); padding: 10px 22px; border-radius: var(--r); margin: 0; }
.score b { font-family: var(--display); font-size: 44px; line-height: 1.1; color: var(--weld); }
.score span { font-size: 13px; color: rgb(255 255 255 / .8); }

/* ---------- badges & pills ---------- */
.badges { display: flex; flex-wrap: wrap; gap: 6px; list-style: none; }
.badges--col { flex-direction: column; align-items: flex-start; }
.badge { display: inline-flex; align-items: center; gap: 6px; padding: 3px 10px; border-radius: 999px; background: var(--pasture-bg); color: var(--pasture); font-size: 13px; font-weight: 700; line-height: 1.7; }
.badge .ic { width: 15px; height: 15px; }
.pill { display: inline-block; padding: 1px 10px; border-radius: 999px; font-size: 12.5px; font-weight: 700; line-height: 1.9; white-space: nowrap; }
.pill--amber { background: #FBEFD5; color: #7A5300; }
.pill--blue { background: #E1E7F7; color: #24397A; }
.pill--violet { background: #ECE3F6; color: #55307E; }
.pill--teal { background: #DDF0EE; color: #1D5E58; }
.pill--green { background: #E2EFDB; color: #2E6534; }
.pill--red { background: #F7E1E0; color: #8E2228; }
.pill--gray { background: #ECEAE5; color: #5E606E; }

/* ---------- rancher cards ---------- */
.rgrid { display: grid; grid-template-columns: repeat(auto-fill, minmax(272px, 1fr)); gap: 24px; }
@media (max-width: 640px) {
  .rgrid--scroll {
    grid-template-columns: none; grid-auto-flow: column; grid-auto-columns: 80%; overflow-x: auto;
    scroll-snap-type: x mandatory; margin-inline: calc(var(--gutter) * -1); padding: 4px var(--gutter) 16px; scrollbar-width: none;
  }
  .rgrid--scroll::-webkit-scrollbar { display: none; }
  .rgrid--scroll > * { scroll-snap-align: center; }
  .rgrid--scroll .rcard__intro { display: none; }
}
.rcard { display: flex; flex-direction: column; background: var(--paper); border-radius: 18px; overflow: hidden; box-shadow: var(--shadow); }
.rcard__photo { position: relative; display: block; aspect-ratio: 5 / 4; overflow: hidden; background: var(--wool-2); }
.rcard__photo img { width: 100%; height: 100%; object-fit: cover; object-position: center 22%; transition: transform .6s cubic-bezier(.2, .8, .2, 1); }
.rcard:hover .rcard__photo img { transform: scale(1.04); }
.rcard__photo::after { content: ""; position: absolute; inset: auto 0 0 0; height: 10px; background: var(--kilim) repeat-x center / auto 100%; }
.rcard__body { padding: 18px 20px 6px; display: grid; gap: 8px; flex: 1; align-content: start; }
.rcard__name { font-family: var(--display); font-weight: 400; font-size: 26px; color: var(--indigo); line-height: 1.3; }
.rcard__name a { text-decoration: none; }
.rcard__name a::after { content: ""; position: absolute; inset: 0; }
.rcard { position: relative; }
.rcard__place { display: flex; align-items: center; gap: 6px; margin: 0; color: var(--muted); font-size: 14px; }
.rcard__intro { margin: 0; font-size: 14.5px; color: var(--ink); line-height: 1.8; }
.rcard__facts { display: grid; grid-template-columns: repeat(3, 1fr); gap: 4px; padding: 10px 0; border-block: 1px dashed var(--line); margin-block: 4px; }
.rcard__facts div { display: grid; }
.rcard__facts dt { font-size: 12px; color: var(--muted); }
.rcard__facts dd { font-weight: 700; font-size: 14.5px; }
.rcard .badges { position: relative; z-index: 1; }
.rcard__foot {
  position: relative; z-index: 1; display: flex; align-items: center; justify-content: space-between; gap: 10px;
  margin-top: 10px; padding: 14px 20px; border-top: 1px solid var(--line); text-decoration: none; background: #FBFAF7;
}
.rcard__price { display: grid; line-height: 1.45; }
.rcard__price small { font-size: 12px; color: var(--muted); }
.rcard__price b { color: var(--ink); font-size: 15.5px; font-weight: 900; white-space: nowrap; }
.rcard__go { display: inline-flex; align-items: center; gap: 6px; color: var(--madder); font-weight: 700; font-size: 14px; white-space: nowrap; }
.rcard__foot:hover .rcard__go .ic { transform: translateX(-4px); }
.rcard__go .ic { transition: transform .2s; }

/* ---------- quality ---------- */
.quality__in { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.8fr); gap: 48px; align-items: start; }
.quality__head { position: sticky; top: 100px; }
.checks { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; list-style: none; }
.check { display: grid; grid-template-columns: 48px 1fr; gap: 4px 14px; align-items: start; background: var(--paper); padding: 18px; border-radius: var(--r); }
.check__ic { grid-row: span 2; display: grid; place-items: center; width: 48px; height: 48px; border-radius: 12px; background: var(--indigo); color: #fff; }
.check__ic .ic { width: 24px; height: 24px; }
.check h3 { font-size: 16.5px; font-weight: 700; color: var(--indigo); }
.check p { margin: 0; font-size: 14.5px; color: var(--muted); line-height: 1.8; }
@media (max-width: 900px) {
  .quality__in { grid-template-columns: 1fr; gap: 24px; }
  .quality__head { position: static; }
}
@media (max-width: 560px) { .checks { grid-template-columns: 1fr; } }

/* ---------- categories ---------- */
.cats { display: grid; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); gap: 18px; }
.cat { display: flex; flex-direction: column; background: var(--paper); border-radius: var(--r); overflow: hidden; text-decoration: none; box-shadow: var(--shadow); transition: box-shadow .25s, transform .25s; }
.cat:hover { box-shadow: var(--shadow-up); transform: translateY(-3px); }
.cat img { aspect-ratio: 4 / 3; object-fit: cover; width: 100%; }
.cat__body { display: grid; gap: 4px; padding: 14px 16px 16px; }
.cat__title { font-family: var(--display); font-size: 22px; color: var(--indigo); line-height: 1.35; }
.cat__desc { font-size: 14px; color: var(--muted); line-height: 1.75; }
.cat__price { font-size: 13.5px; font-weight: 700; color: var(--madder); margin-top: 4px; }

/* ---------- product cards ---------- */
.pgrid { display: grid; grid-template-columns: repeat(auto-fill, minmax(232px, 1fr)); gap: 20px; }
.pcard { display: flex; flex-direction: column; background: var(--paper); border-radius: var(--r); overflow: hidden; box-shadow: var(--shadow); }
.pcard__img { position: relative; display: block; aspect-ratio: 4 / 3; overflow: hidden; background: var(--wool-2); }
.pcard__img img { width: 100%; height: 100%; object-fit: cover; transition: transform .5s; }
.pcard:hover .pcard__img img { transform: scale(1.04); }
.pcard__off { position: absolute; top: 10px; inset-inline-start: 10px; background: var(--madder); color: #fff; font-size: 12px; font-weight: 700; padding: 2px 10px; border-radius: 999px; }
.pcard__body { display: grid; gap: 6px; padding: 14px 16px 4px; flex: 1; align-content: start; }
.pcard__title { font-size: 16.5px; font-weight: 700; line-height: 1.55; }
.pcard__title a { text-decoration: none; }
.pcard__title a:hover { color: var(--madder); }
.pcard__rancher { display: inline-flex; align-items: center; gap: 8px; color: var(--muted); font-size: 13.5px; text-decoration: none; }
.pcard__rancher img { width: 28px; height: 28px; border-radius: 50%; object-fit: cover; object-position: top; }
.pcard__rancher:hover { color: var(--indigo); }
.pcard__note { margin: 0; font-size: 13px; color: var(--muted); }
.pcard__foot { display: flex; align-items: center; justify-content: space-between; gap: 8px; padding: 12px 16px 16px; }
.pcard__soldout { font-size: 13px; color: var(--muted); font-weight: 700; }
.pcard.is-out .pcard__img img { filter: grayscale(.8); opacity: .7; }
.price { margin: 0; display: flex; flex-wrap: wrap; align-items: baseline; gap: 2px 6px; line-height: 1.4; }
.price b { font-size: 17px; font-weight: 900; color: var(--ink); }
.price small { font-size: 12px; color: var(--muted); }
.price s { flex-basis: 100%; font-size: 12.5px; color: var(--muted); }
.price--big b { font-size: 30px; font-family: var(--display); font-weight: 400; color: var(--indigo); }
.price--big small { font-size: 14px; }

/* ---------- stats band ---------- */
.stats { position: relative; background: var(--indigo); color: #fff; padding-block: 52px; }
.stats::before, .stats::after { content: ""; position: absolute; inset-inline: 0; height: 10px; background: var(--kilim) repeat-x center / auto 100%; }
.stats::before { top: 0; }
.stats::after { bottom: 0; }
.stats__in { display: grid; grid-template-columns: repeat(auto-fit, minmax(160px, 1fr)); gap: 24px; text-align: center; }
.stat { display: grid; }
.stat b { font-family: var(--display); font-weight: 400; font-size: clamp(42px, 6vw, 62px); line-height: 1.2; color: var(--weld); }
.stat span { color: rgb(255 255 255 / .82); }

/* ---------- reviews ---------- */
.reviews-strip {
  display: grid; grid-auto-flow: column; grid-auto-columns: minmax(290px, 360px); gap: 18px;
  overflow-x: auto; scroll-snap-type: x mandatory; padding: 4px 4px 18px; margin-inline: -4px; overscroll-behavior-x: contain;
  scrollbar-width: thin; scrollbar-color: var(--line) transparent;
}
.reviews-strip > * { scroll-snap-align: start; }
@media (min-width: 700px) {
  .reviews-strip { -webkit-mask-image: linear-gradient(to left, #000 88%, transparent); mask-image: linear-gradient(to left, #000 88%, transparent); }
}
.reviews-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: 18px; }
.review { display: flex; flex-direction: column; gap: 12px; margin: 0; padding: 22px; background: var(--paper); border-radius: var(--r); box-shadow: var(--shadow); }
.review blockquote { margin: 0; flex: 1; font-size: 15.5px; line-height: 1.95; }
.review figcaption { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; padding-top: 12px; border-top: 1px dashed var(--line); }
.review__avatar { display: grid; place-items: center; width: 40px; height: 40px; border-radius: 50%; background: var(--wool-2); color: var(--indigo); font-weight: 900; }
.review__who { display: grid; line-height: 1.5; }
.review__who small { color: var(--muted); font-size: 12.5px; }
.review__rancher { margin-inline-start: auto; font-size: 13px; color: var(--madder); font-weight: 700; text-decoration: none; }
.review__reply { margin: 0; padding: 10px 14px; background: var(--wool); border-radius: var(--r-s); font-size: 14px; }
.stars { display: flex; gap: 2px; color: var(--line); }
.stars .on { color: var(--weld); }
.stars .ic { width: 18px; height: 18px; fill: currentColor; }

/* ---------- follow ---------- */
.follow { padding-block: 48px; background: var(--paper); border-top: 1px solid var(--line); }
.follow__in { display: flex; align-items: center; justify-content: space-between; gap: 24px; flex-wrap: wrap; }
.follow p { margin: 6px 0 0; color: var(--muted); }
.social { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 12px; }
.social a { display: inline-flex; align-items: center; gap: 8px; padding: 8px 14px; border-radius: 999px; background: rgb(255 255 255 / .1); text-decoration: none; font-size: 14px; }
.social--big a { background: var(--indigo); color: #fff; padding: 12px 20px; font-weight: 700; }
.social--big a:hover { background: var(--madder); }

/* ---------- footer ---------- */
.footer { background: var(--indigo-ink); color: rgb(255 255 255 / .82); margin-top: 0; }
.footer__grid { display: grid; grid-template-columns: 1.4fr 1fr 1.2fr auto; gap: 36px; padding-block: 44px 28px; }
.footer h2 { font-size: 16px; color: #fff; margin-bottom: 12px; }
.footer__about p { margin-top: 14px; font-size: 14.5px; line-height: 1.95; max-width: 40ch; }
.brand--footer { color: #fff; }
.footer__links { display: grid; align-content: start; gap: 6px; }
.footer__links a { text-decoration: none; font-size: 14.5px; }
.footer__links a:hover, .footer__line:hover { color: #fff; }
.footer__line { display: flex; align-items: flex-start; gap: 8px; margin: 0 0 8px; text-decoration: none; font-size: 14.5px; }
.footer__line .ic { margin-top: 4px; color: var(--weld); }
.footer__seal img { background: #fff; border-radius: 10px; padding: 6px; }
.footer__bottom { padding-block: 16px 24px; border-top: 1px solid rgb(255 255 255 / .1); font-size: 13px; color: rgb(255 255 255 / .6); }
@media (max-width: 900px) { .footer__grid { grid-template-columns: 1fr 1fr; } }
@media (max-width: 560px) { .footer__grid { grid-template-columns: 1fr; gap: 26px; } }

/* ---------- drawers (dialog) ---------- */
.drawer {
  position: fixed; margin: 0; padding: 0; border: 0; inset-block: 0; inset-inline-end: 0; inset-inline-start: auto;
  width: min(420px, 92vw); max-width: none; height: 100dvh; max-height: none;
  background: var(--paper); color: var(--ink); box-shadow: -20px 0 50px -20px rgb(0 0 0 / .4);
  display: flex; flex-direction: column;
}
.drawer:not([open]) { display: none; }
.drawer--menu { inset-inline-start: 0; inset-inline-end: auto; width: min(340px, 86vw); }
.drawer::backdrop { background: rgb(21 28 61 / .55); }
@media (prefers-reduced-motion: no-preference) {
  .drawer[open] { animation: drawerIn .32s cubic-bezier(.2, .8, .2, 1); }
  .drawer--menu[open] { animation-name: drawerInStart; }
  .drawer[open]::backdrop { animation: fade .3s ease; }
  .drawer.is-closing { animation: drawerOut .22s ease-in forwards; }
  .drawer--menu.is-closing { animation-name: drawerOutStart; }
}
@keyframes drawerIn { from { transform: translateX(-100%); } }
@keyframes drawerOut { to { transform: translateX(-100%); } }
@keyframes drawerInStart { from { transform: translateX(100%); } }
@keyframes drawerOutStart { to { transform: translateX(100%); } }
@keyframes fade { from { opacity: 0; } }
.drawer__head { display: flex; align-items: center; justify-content: space-between; padding: 14px 18px; border-bottom: 1px solid var(--line); }
.drawer__title { font-family: var(--display); font-size: 24px; color: var(--indigo); }
.drawer__body { flex: 1; overflow-y: auto; padding: 8px 18px; }
.drawer__empty { padding: 40px 0; text-align: center; color: var(--muted); }
.drawer__foot { display: grid; gap: 10px; padding: 16px 18px calc(16px + env(safe-area-inset-bottom)); border-top: 1px solid var(--line); background: #FBFAF7; }
.drawer__sum { display: flex; justify-content: space-between; font-size: 16px; }
.drawer__sum strong { font-weight: 900; }
.drawer__nav { display: grid; padding: 10px; }
.drawer__nav a { padding: 12px 14px; border-radius: 10px; text-decoration: none; font-weight: 700; color: var(--indigo); }
.drawer__nav a:hover { background: var(--wool); }
.drawer__nav .drawer__sub { font-weight: 500; color: var(--muted); padding-block: 8px; padding-inline-start: 30px; }

.dline { display: grid; grid-template-columns: 64px minmax(0, 1fr); gap: 12px; align-items: center; padding: 14px 0; border-bottom: 1px solid var(--line); }
.dline img { width: 64px; height: 48px; border-radius: 8px; object-fit: cover; }
.dline__t { display: grid; line-height: 1.5; }
.dline__t a { font-weight: 700; text-decoration: none; font-size: 14.5px; }
.dline__t small { color: var(--muted); font-size: 12.5px; }
.dline__ctrl { display: flex; align-items: center; gap: 6px; margin-top: 6px; flex-wrap: wrap; }
.dline__ctrl button { width: 28px; height: 28px; border-radius: 8px; border: 1px solid var(--line); background: #fff; cursor: pointer; display: grid; place-items: center; }
.dline__ctrl button:hover { border-color: var(--indigo); }
.dline__ctrl .ic { width: 15px; height: 15px; }
.dline__ctrl span { min-width: 64px; text-align: center; font-size: 13.5px; font-weight: 700; }
.dline__sum { margin-inline-start: auto; font-weight: 900; font-size: 14px; white-space: nowrap; }
.dline.is-busy { opacity: .5; pointer-events: none; }

/* ---------- toasts & fly ---------- */
.toasts { position: fixed; inset-inline: 0; bottom: calc(16px + env(safe-area-inset-bottom)); z-index: 90; display: grid; justify-items: center; gap: 8px; pointer-events: none; padding-inline: 16px; }
.toast {
  pointer-events: auto; display: flex; align-items: center; gap: 10px; max-width: 460px;
  padding: 12px 18px; border-radius: 12px; background: var(--indigo-ink); color: #fff; box-shadow: var(--shadow-up); font-weight: 500;
}
.toast--err { background: var(--err); }
.toast a { color: var(--weld); font-weight: 700; white-space: nowrap; }
@media (prefers-reduced-motion: no-preference) {
  .toast { animation: toastIn .35s cubic-bezier(.2, 1.2, .4, 1); }
  .toast.is-out { animation: toastOut .25s ease-in forwards; }
}
@keyframes toastIn { from { opacity: 0; transform: translateY(16px) scale(.96); } }
@keyframes toastOut { to { opacity: 0; transform: translateY(10px); } }
.fly { position: fixed; z-index: 95; pointer-events: none; border-radius: 12px; object-fit: cover; box-shadow: var(--shadow-up); }

/* ---------- forms ---------- */
.card { background: var(--paper); border-radius: var(--r); box-shadow: var(--shadow); padding: 22px; margin: 0 0 20px; border: 0; min-width: 0; }
.card__title { font-size: 18px; font-weight: 900; color: var(--indigo); margin-bottom: 14px; padding: 0; display: flex; align-items: center; gap: 8px; }
fieldset.card > legend.card__title { float: inline-start; width: 100%; margin-bottom: 4px; }
.form { display: grid; gap: 14px; }
.form__grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px 16px; }
.field { display: grid; gap: 6px; min-width: 0; border: 0; padding: 0; margin: 0; }
.field--wide { grid-column: 1 / -1; }
.field > span, .field > legend { font-size: 14px; font-weight: 700; color: var(--ink); padding: 0; }
.field small { color: var(--muted); font-weight: 400; }
.field input, .field select, .field textarea {
  width: 100%; min-height: 46px; padding: 10px 14px; border-radius: 10px; border: 1.5px solid var(--line); background: #fff;
  transition: border-color .15s, box-shadow .15s;
}
.field textarea { resize: vertical; min-height: 90px; line-height: 1.8; }
.field input:focus, .field select:focus, .field textarea:focus { outline: none; border-color: var(--indigo); box-shadow: 0 0 0 4px rgb(30 40 82 / .12); }
.field input:user-invalid, .field select:user-invalid, .field textarea:user-invalid,
.field .user-invalid-fallback { border-color: var(--err); background: #FDF5F4; }
.field__err { display: none; font-style: normal; font-size: 13px; color: var(--err); }
.field input:user-invalid ~ .field__err, .field select:user-invalid ~ .field__err, .field textarea:user-invalid ~ .field__err,
.field .user-invalid-fallback ~ .field__err { display: block; }
.field--inline { display: flex; align-items: center; gap: 10px; }
.field--inline select { min-height: 40px; padding-block: 6px; width: auto; }
.check-inline { display: inline-flex; align-items: center; gap: 8px; font-size: 14px; color: var(--muted); cursor: pointer; }
.check-inline input { width: 18px; height: 18px; accent-color: var(--indigo); }
@media (max-width: 640px) { .form__grid { grid-template-columns: 1fr; } }

/* chips */
.chips { display: flex; flex-wrap: wrap; gap: 8px; }
.chip {
  position: relative; display: inline-flex; align-items: center; min-height: 38px; padding: 6px 16px; border-radius: 999px;
  border: 1.5px solid var(--line); background: #fff; color: var(--ink); font-size: 14px; font-weight: 500; text-decoration: none; cursor: pointer;
}
.chip:hover { border-color: var(--indigo); }
.chip.is-on, .chip:has(input:checked) { background: var(--indigo); border-color: var(--indigo); color: #fff; }
.chip input { position: absolute; opacity: 0; inset: 0; cursor: pointer; margin: 0; }
.chip:has(input:focus-visible) { outline: 3px solid var(--weld); outline-offset: 2px; }
.chip.is-full { opacity: .45; text-decoration: line-through; pointer-events: none; }
.chips--days .chip { border-radius: 12px; }
.chips--slots { margin-top: 12px; }
.chips--slots:empty { display: none; }

/* filters */
.filters { display: grid; gap: 14px; margin-bottom: 26px; }
.filters__row { display: flex; flex-wrap: wrap; align-items: center; gap: 12px 20px; }
.filters__count { margin-inline-start: auto; color: var(--muted); font-size: 14px; }

/* ---------- rancher profile ---------- */
.rprofile__cover {
  position: relative; color: #fff; padding-top: clamp(120px, 18vw, 220px);
  background: linear-gradient(180deg, rgb(21 28 61 / .1), rgb(21 28 61 / .85)), var(--cover) center / cover no-repeat, var(--indigo);
}
.rprofile__head { display: flex; align-items: flex-end; gap: 22px; padding-bottom: 26px; flex-wrap: wrap; }
.rprofile__photo { width: clamp(112px, 16vw, 168px); aspect-ratio: 1; object-fit: cover; object-position: top; border-radius: 22px; border: 4px solid #fff; box-shadow: var(--shadow-up); background: var(--wool-2); }
.rprofile__id { flex: 1; min-width: 220px; }
.rprofile__name { font-family: var(--display); font-weight: 400; font-size: clamp(34px, 5.4vw, 56px); line-height: 1.25; }
.rprofile__nick { margin: 2px 0 0; color: var(--weld); font-weight: 700; }
.rprofile__place { display: flex; align-items: center; gap: 6px; margin: 4px 0 0; color: rgb(255 255 255 / .85); }
.rprofile__share { margin-bottom: 6px; }
.rprofile__grid { display: grid; grid-template-columns: 320px minmax(0, 1fr); gap: 40px; padding-block: 40px 10px; align-items: start; }
.rprofile__intro { font-size: 20px; font-weight: 700; color: var(--indigo); line-height: 1.8; }
.idcard { position: sticky; top: 92px; background: var(--paper); border-radius: var(--r); box-shadow: var(--shadow); overflow: hidden; padding: 22px; }
.idcard::before { content: ""; display: block; height: 10px; margin: -22px -22px 18px; background: var(--kilim) repeat-x center / auto 100%; }
.idcard__title { font-family: var(--display); font-weight: 400; font-size: 24px; color: var(--indigo); margin-bottom: 10px; }
.idcard dl { display: grid; margin-bottom: 16px; }
.idcard dl div { display: flex; justify-content: space-between; gap: 12px; padding: 10px 0; border-bottom: 1px dashed var(--line); }
.idcard dt { color: var(--muted); font-size: 14px; white-space: nowrap; }
.idcard dd { font-weight: 700; text-align: end; font-size: 14.5px; }
.idcard__cert { display: grid; gap: 8px; margin-top: 16px; text-decoration: none; font-weight: 700; color: var(--madder); font-size: 14px; }
.idcard__cert img { border-radius: 10px; border: 1px solid var(--line); max-height: 180px; object-fit: cover; }
.idcard__cert span { display: flex; align-items: center; gap: 6px; }
@media (max-width: 900px) {
  .rprofile__grid { grid-template-columns: 1fr; gap: 24px; }
  .idcard { position: static; }
}

.prose { font-size: 17px; line-height: 2.05; max-width: 70ch; }
.prose p { margin-bottom: 1.1em; }
.prose h2 { font-family: var(--display); font-weight: 400; font-size: 28px; color: var(--indigo); margin-bottom: 12px; }
.prose--page { background: var(--paper); padding: clamp(22px, 4vw, 40px); border-radius: var(--r); box-shadow: var(--shadow); max-width: none; }
.gallery { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 10px; margin-top: 24px; }
.gallery a { display: block; border-radius: 12px; overflow: hidden; aspect-ratio: 1; background: var(--wool-2); }
.gallery img { width: 100%; height: 100%; object-fit: cover; transition: transform .4s; }
.gallery a:hover img { transform: scale(1.05); }
.mini-ranchers { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 12px; list-style: none; }
.mini-ranchers a { display: flex; align-items: center; gap: 12px; padding: 10px; border-radius: 14px; background: var(--paper); text-decoration: none; }
.mini-ranchers a:hover { box-shadow: var(--shadow); }
.mini-ranchers img { width: 56px; height: 56px; border-radius: 14px; object-fit: cover; object-position: top; }
.mini-ranchers span { display: grid; line-height: 1.5; }
.mini-ranchers small { color: var(--muted); font-size: 13px; }

/* ---------- product page ---------- */
.crumbs { display: flex; flex-wrap: wrap; gap: 4px; padding-block: 18px 6px; font-size: 13.5px; color: var(--muted); }
.crumbs a { text-decoration: none; }
.crumbs a:hover { color: var(--indigo); }
.crumbs > *:not(:last-child)::after { content: "/"; margin-inline-start: 6px; color: var(--line); }
.product { display: grid; grid-template-columns: minmax(0, 1.1fr) minmax(0, 1fr); gap: 40px; padding-block: 12px 36px; align-items: start; }
.product__main { display: block; border-radius: var(--r-l); overflow: hidden; background: var(--wool-2); box-shadow: var(--shadow); }
.product__main img { width: 100%; aspect-ratio: 4 / 3; object-fit: cover; }
.product__thumbs { display: flex; gap: 10px; margin-top: 12px; overflow-x: auto; }
.product__thumbs a { flex: none; width: 88px; border-radius: 10px; overflow: hidden; }
.product__thumbs img { aspect-ratio: 1; object-fit: cover; }
.product__info { display: grid; gap: 16px; }
.product__title { font-family: var(--display); font-weight: 400; font-size: clamp(30px, 4.4vw, 44px); color: var(--indigo); line-height: 1.3; }
.product__rancher {
  display: flex; align-items: center; gap: 12px; padding: 10px 14px; border-radius: 14px; background: var(--paper);
  text-decoration: none; box-shadow: var(--shadow); max-width: 420px;
}
.product__rancher img { width: 56px; height: 56px; border-radius: 14px; object-fit: cover; object-position: top; }
.product__rancher span { display: grid; flex: 1; line-height: 1.5; }
.product__rancher small { color: var(--muted); font-size: 12.5px; }
.product__rancher b { font-size: 16px; }
.product__rancher > .ic { color: var(--madder); }
.product__summary { margin: 0; color: var(--muted); font-size: 16px; }
.buybox { display: grid; gap: 14px; padding: 20px; background: var(--paper); border-radius: var(--r); box-shadow: var(--shadow); }
.buybox__note { display: flex; align-items: center; gap: 8px; margin: 0; color: var(--muted); font-size: 14.5px; }
.buybox__form { display: grid; gap: 14px; }
.buybox__row { display: flex; align-items: center; justify-content: space-between; gap: 14px; flex-wrap: wrap; }
.buybox__total { margin: 0; display: grid; text-align: end; line-height: 1.4; }
.buybox__total small { color: var(--muted); font-size: 13px; }
.buybox__total b { font-size: 20px; font-weight: 900; }
.buybox__btns { display: grid; grid-template-columns: 1.4fr 1fr; gap: 10px; }
.buybox__out { margin: 0; padding: 12px; background: var(--wool); border-radius: 10px; color: var(--muted); }
.buybox__stock { margin: 0; font-size: 13.5px; color: var(--muted); }
.product__more { display: grid; grid-template-columns: minmax(0, 1.4fr) minmax(0, 1fr); gap: 40px; padding-bottom: 30px; align-items: start; }
.specs { display: grid; background: var(--paper); border-radius: var(--r); padding: 8px 20px; box-shadow: var(--shadow); }
.specs div { display: flex; justify-content: space-between; gap: 16px; padding: 12px 0; border-bottom: 1px dashed var(--line); }
.specs div:last-child { border-bottom: 0; }
.specs dt { color: var(--muted); font-size: 14px; }
.specs dd { font-weight: 700; text-align: end; font-size: 14.5px; }
@media (max-width: 900px) {
  .product, .product__more { grid-template-columns: 1fr; gap: 22px; }
}

/* qty stepper */
.qty { display: inline-flex; align-items: center; gap: 4px; padding: 4px; border: 1.5px solid var(--line); border-radius: 12px; background: #fff; }
.qty__btn { display: grid; place-items: center; width: 40px; height: 40px; border-radius: 9px; border: 0; background: var(--wool); color: var(--indigo); cursor: pointer; }
.qty__btn:hover { background: var(--indigo); color: #fff; }
.qty__val { display: flex; align-items: baseline; gap: 4px; padding-inline: 4px; }
.qty__val input { width: 52px; border: 0; text-align: center; font-weight: 900; font-size: 18px; background: transparent; padding: 0; min-height: 0; }
.qty__val input:focus { outline: none; }
.qty__unit { font-size: 13px; color: var(--muted); }
.chips--qty .chip { min-height: 34px; }

/* ---------- cart page ---------- */
.cartpage { display: grid; grid-template-columns: minmax(0, 1fr) 340px; gap: 28px; align-items: start; }
.cartlist { list-style: none; display: grid; gap: 14px; }
.cartline { display: grid; grid-template-columns: 110px minmax(0, 1fr) auto auto 44px; gap: 16px; align-items: center; background: var(--paper); padding: 14px; border-radius: var(--r); box-shadow: var(--shadow); }
.cartline__img img { width: 110px; height: 82px; object-fit: cover; border-radius: 10px; }
.cartline__info { display: grid; line-height: 1.6; }
.cartline__title { font-weight: 700; text-decoration: none; }
.cartline__info small { color: var(--muted); font-size: 13px; }
.cartline__qty { display: flex; align-items: center; gap: 8px; }
.cartline__total { font-size: 16px; white-space: nowrap; }
.summary { display: grid; gap: 12px; }
.summary__row { display: flex; justify-content: space-between; gap: 10px; align-items: baseline; }
.summary__row--total { padding-top: 12px; border-top: 1px solid var(--line); font-size: 18px; }
.summary__row--total b { font-weight: 900; color: var(--indigo); }
.summary__hint { margin: 0; font-size: 13px; color: var(--muted); }
@media (max-width: 900px) {
  .cartpage { grid-template-columns: 1fr; }
  .cartline { grid-template-columns: 84px minmax(0, 1fr) 40px; }
  .cartline__img img { width: 84px; height: 64px; }
  .cartline__qty { grid-column: 1 / 3; }
  .cartline__total { grid-column: 3 / 4; grid-row: 1; justify-self: end; display: none; }
}

/* ---------- checkout ---------- */
.checkout { display: grid; grid-template-columns: minmax(0, 1fr) 360px; gap: 28px; align-items: start; }
.checkout__side { position: sticky; top: 92px; }
.minilines { list-style: none; display: grid; gap: 10px; margin-bottom: 4px; }
.minilines li { display: flex; align-items: center; gap: 10px; }
.minilines img { width: 56px; height: 42px; border-radius: 8px; object-fit: cover; }
.minilines span { flex: 1; display: grid; line-height: 1.5; min-width: 0; }
.minilines b { font-size: 14px; }
.minilines small { color: var(--muted); font-size: 12.5px; }
.minilines em { font-style: normal; font-weight: 700; font-size: 14px; white-space: nowrap; }
.minilines--order li { padding-bottom: 10px; border-bottom: 1px dashed var(--line); }
.paylist { display: grid; gap: 10px; }
.payopt { display: flex; align-items: center; gap: 14px; padding: 14px 16px; border: 1.5px solid var(--line); border-radius: 12px; cursor: pointer; background: #fff; }
.payopt:has(input:checked) { border-color: var(--indigo); box-shadow: 0 0 0 3px rgb(30 40 82 / .1); }
.payopt input { width: 20px; height: 20px; accent-color: var(--indigo); margin: 0; }
.payopt__ic { display: grid; place-items: center; width: 40px; height: 40px; border-radius: 10px; background: var(--wool); color: var(--indigo); }
.payopt__txt { display: grid; line-height: 1.55; }
.payopt__txt small { color: var(--muted); font-size: 13px; }
@media (max-width: 900px) {
  .checkout { grid-template-columns: 1fr; }
  .checkout__side { position: static; }
}

/* ---------- order page ---------- */
.pagehead--order { padding-block: 32px; }
.placed { display: flex; align-items: center; gap: 18px; }
.placed__ic { flex: none; display: grid; place-items: center; width: 64px; height: 64px; border-radius: 50%; background: var(--pasture); color: #fff; }
.placed__ic .ic { width: 34px; height: 34px; stroke-width: 2.6; }
@media (prefers-reduced-motion: no-preference) {
  .placed__ic { animation: pop .6s cubic-bezier(.2, 1.6, .4, 1) both; }
  .placed__ic .ic path { stroke-dasharray: 24; stroke-dashoffset: 24; animation: draw .5s .35s ease-out forwards; }
}
@keyframes pop { from { transform: scale(.3); opacity: 0; } }
@keyframes draw { to { stroke-dashoffset: 0; } }
.ordercode { display: flex; align-items: center; gap: 6px; margin: 14px 0 0; color: rgb(255 255 255 / .85); }
.ordercode b { font-size: 22px; letter-spacing: 2px; color: var(--weld); font-weight: 900; }
.ordercode .iconbtn { color: #fff; }
.orderpage { display: grid; grid-template-columns: minmax(0, 1fr) 360px; gap: 28px; align-items: start; }
.paybox { border: 2px solid var(--weld); }
.paybox__btns { display: flex; flex-wrap: wrap; gap: 10px; }
.steps { display: grid; grid-template-columns: repeat(5, 1fr); list-style: none; margin-bottom: 18px; counter-reset: s; }
.step { position: relative; display: grid; justify-items: center; gap: 6px; text-align: center; font-size: 13px; color: var(--muted); }
.step::before { content: ""; position: absolute; top: 14px; inset-inline-start: calc(50% + 16px); width: calc(100% - 32px); height: 2px; background: var(--line); }
.step:last-child::before { display: none; }
.step__dot { display: grid; place-items: center; width: 30px; height: 30px; border-radius: 50%; background: var(--wool); border: 2px solid var(--line); color: #fff; }
.step__dot .ic { width: 16px; height: 16px; stroke-width: 2.6; }
.step.is-done { color: var(--ink); }
.step.is-done .step__dot { background: var(--pasture); border-color: var(--pasture); }
.step.is-done::before { background: var(--pasture); }
.step.is-now { color: var(--indigo); font-weight: 700; }
.step.is-now .step__dot { background: var(--madder); border-color: var(--madder); box-shadow: 0 0 0 0 rgb(178 42 46 / .5); }
@media (prefers-reduced-motion: no-preference) { .step.is-now .step__dot { animation: ring 1.8s ease-out infinite; } }
@keyframes ring { 70% { box-shadow: 0 0 0 10px rgb(178 42 46 / 0); } 100% { box-shadow: 0 0 0 0 rgb(178 42 46 / 0); } }
.timeline { list-style: none; display: grid; gap: 10px; border-inline-start: 2px solid var(--line); padding-inline-start: 16px; }
.timeline li { display: grid; font-size: 14px; position: relative; }
.timeline li::before { content: ""; position: absolute; inset-inline-start: -22px; top: 9px; width: 10px; height: 10px; border-radius: 50%; background: var(--indigo); }
.timeline time { font-size: 12.5px; color: var(--muted); }
.kv { display: grid; }
.kv div { display: grid; grid-template-columns: 100px 1fr; gap: 10px; padding: 10px 0; border-bottom: 1px dashed var(--line); font-size: 14.5px; }
.kv dt { color: var(--muted); }
.kv dd { font-weight: 500; overflow-wrap: anywhere; }
.myorders { list-style: none; display: grid; gap: 8px; }
.myorders a { display: flex; align-items: center; gap: 12px; padding: 10px 14px; border-radius: 10px; background: var(--wool); text-decoration: none; flex-wrap: wrap; }
.myorders em { margin-inline-start: auto; font-style: normal; font-weight: 700; }
@media (max-width: 900px) {
  .orderpage { grid-template-columns: 1fr; }
  .steps { font-size: 11.5px; }
}
@media (max-width: 520px) { .step span:last-child { font-size: 11px; } }

/* ---------- reviews page ---------- */
.reviews-page { display: grid; grid-template-columns: minmax(0, 1fr) 360px; gap: 28px; align-items: start; }
.review-form { position: sticky; top: 92px; }
.reviews-page .reviews-grid { grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); }
.rating-input__stars { display: flex; flex-direction: row-reverse; justify-content: flex-end; gap: 4px; }
.rating-input__stars input { position: absolute; opacity: 0; width: 1px; height: 1px; }
.rating-input__stars label { cursor: pointer; color: var(--line); }
.rating-input__stars label .ic { width: 32px; height: 32px; fill: currentColor; }
.rating-input__stars input:checked ~ label, .rating-input__stars label:hover, .rating-input__stars label:hover ~ label { color: var(--weld); }
.rating-input__stars input:focus-visible + label { outline: 3px solid var(--weld); border-radius: 6px; }
.pager { display: flex; gap: 6px; justify-content: center; margin-top: 26px; }
.pager a { display: grid; place-items: center; min-width: 40px; height: 40px; border-radius: 10px; background: var(--paper); text-decoration: none; font-weight: 700; }
.pager a[aria-current] { background: var(--indigo); color: #fff; }
@media (max-width: 900px) {
  .reviews-page { grid-template-columns: 1fr; }
  .review-form { position: static; order: -1; }
}

/* ---------- error ---------- */
.errorpage { padding-block: 80px; text-align: center; }
.errorpage__code { font-family: var(--display); font-size: 120px; line-height: 1; color: var(--wool-2); -webkit-text-stroke: 2px var(--indigo); margin-bottom: 10px; display: flex; justify-content: center; }
.errorpage h1 { font-family: var(--display); font-weight: 400; font-size: 36px; color: var(--indigo); margin-bottom: 8px; }
.errorpage p { color: var(--muted); }
.errorpage__detail { text-align: left; white-space: pre-wrap; font-size: 12px; background: #fff; padding: 14px; border-radius: 10px; margin-top: 24px; overflow: auto; }

/* ---------- lightbox ---------- */
.lightbox { padding: 0; border: 0; background: transparent; max-width: 96vw; max-height: 92vh; }
.lightbox::backdrop { background: rgb(10 12 26 / .85); }
.lightbox img { max-width: 96vw; max-height: 86vh; border-radius: 12px; margin-inline: auto; }
.lightbox__bar { display: flex; justify-content: center; gap: 10px; margin-top: 10px; }
.lightbox__bar button { background: #fff; color: var(--indigo); }

/* ---------- QR landing page ---------- */
.qrpage-body { background: var(--wool); }
.qrpage { --tone: var(--indigo); max-width: 560px; margin-inline: auto; min-height: 100dvh; background: var(--paper); box-shadow: 0 0 60px -20px rgb(0 0 0 / .25); }
.qrpage__hero { position: relative; background: var(--tone); min-height: 120px; }
.qrpage__cover { width: 100%; aspect-ratio: 4 / 3; object-fit: cover; }
.qrpage__brand {
  position: absolute; top: 14px; inset-inline-start: 14px; display: inline-flex; align-items: center; gap: 8px; padding: 6px 12px 6px 8px;
  border-radius: 999px; background: rgb(255 255 255 / .92); color: var(--tone); text-decoration: none; font-family: var(--display); font-size: 20px; line-height: 1;
}
.qrpage__brand img { width: 30px; height: 30px; border-radius: 8px; }
.qrpage__brand span { padding-top: 3px; }
.qrpage__sheet { position: relative; margin-top: -26px; background: var(--paper); border-radius: 26px 26px 0 0; padding: 0 22px 28px; display: grid; gap: 16px; overflow: hidden; }
.qrpage__sheet > .kilim { margin-inline: -22px; }
.qrpage__title { font-family: var(--display); font-weight: 400; font-size: 34px; color: var(--tone); line-height: 1.3; margin-top: 8px; }
.qrpage__sub { margin: -10px 0 0; color: var(--muted); font-weight: 700; }
.qrpage__fields { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
.qrpage__fields div { background: var(--wool); padding: 10px 14px; border-radius: 12px; display: grid; line-height: 1.6; }
.qrpage__fields dt { font-size: 12.5px; color: var(--muted); }
.qrpage__fields dd { font-weight: 700; font-size: 15px; overflow-wrap: anywhere; }
.qrpage .prose { font-size: 16px; }
.qrpage .btn--primary { background: var(--tone); box-shadow: none; }
.qrpage .btn--primary:hover { filter: brightness(1.15); }
.qrpage .product__rancher { max-width: none; box-shadow: none; background: var(--wool); }
.qrpage__foot { text-align: center; color: var(--muted); font-size: 13px; margin: 6px 0 0; }
.gallery--qr { margin-top: 0; grid-template-columns: repeat(3, 1fr); }
@media (prefers-reduced-motion: no-preference) {
  .qrpage__sheet > * { animation: rise .6s cubic-bezier(.2, .8, .2, 1) both; }
  .qrpage__sheet > *:nth-child(3) { animation-delay: .08s; }
  .qrpage__sheet > *:nth-child(4) { animation-delay: .14s; }
  .qrpage__sheet > *:nth-child(5) { animation-delay: .2s; }
}

@media (max-width: 560px) {
  :root { --gutter: 16px; }
  .section__head { margin-bottom: 20px; }
  .rgrid { gap: 16px; }
  .pgrid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
  .pcard__body { padding: 10px 12px 2px; }
  .pcard__title { font-size: 14.5px; }
  .pcard__foot { flex-direction: column; align-items: stretch; padding: 10px 12px 12px; }
  .pcard__rancher span { font-size: 12px; }
  .btn--add { width: 100%; }
  .buybox__btns { grid-template-columns: 1fr; }
  .hero__cta .btn { flex: 1 1 auto; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .01ms !important; animation-iteration-count: 1 !important; transition-duration: .01ms !important; }
}

@media print {
  .topbar, .footer, .toasts, .drawer, .hero__cta, .why { display: none !important; }
  body { background: #fff; }
}

/* delivery time: card, product page, checkout reason */
.pcard__when, .buybox__when { display: inline-flex; align-items: center; gap: 6px; margin: 0; width: fit-content; max-width: 100%;
  color: var(--pasture); background: var(--pasture-bg); border-radius: 999px; font-weight: 700; line-height: 1.5; }
.pcard__when { font-size: 12.5px; padding: 3px 10px 3px 12px; }
.pcard__when span, .buybox__when span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.pcard__when .ic { width: 15px; height: 15px; flex: none; }
.buybox__when { font-size: 14px; padding: 6px 14px 6px 16px; }
.buybox__when span { white-space: normal; }
.buybox__when .ic { width: 18px; height: 18px; flex: none; }
.delivery-why { display: flex; gap: 8px; align-items: flex-start; margin: 0 0 12px; padding: 10px 12px; border-radius: var(--r-s);
  background: var(--wool); color: var(--ink); font-size: 14px; line-height: 1.8; }
.delivery-why[hidden] { display: none; }
.delivery-why .ic { width: 18px; height: 18px; flex: none; margin-top: 4px; color: var(--indigo-2); }
