/* Revia storefront
   One bold element: the dress-code hang tag. Everything else stays quiet so the photos lead. */

:root {
  --ink: #221b26;
  --ash: #6c6571;
  --line: #e8dfe4;
  --petal: #f7f0f3;
  --paper: #ffffff;
  --jamun: #6b1f4f;
  --jamun-d: #4f1539;
  --zari: #b98a33;
  --ok: #2b6a4b;
  --off: #9a2f3a;
  --serif: "Young Serif", Georgia, "Times New Roman", serif;
  --sans: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  --r-sm: 6px;
  --r: 10px;
  --wrap: 1280px;
  --pad: clamp(14px, 4vw, 32px);
  --top-h: 60px;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-padding-top: calc(var(--top-h) + 12px); }
body { margin: 0; font: 16px/1.5 var(--sans); color: var(--ink); background: var(--paper); }
img { max-width: 100%; display: block; }
a { color: var(--jamun); text-underline-offset: 3px; }
a:hover { color: var(--jamun-d); }
h1, h2, h3 { font-family: var(--serif); font-weight: 400; line-height: 1.15; margin: 0 0 .5em; letter-spacing: -.005em; }
h1 { font-size: clamp(1.75rem, 1.3rem + 2vw, 2.6rem); }
h2 { font-size: clamp(1.3rem, 1.1rem + 1vw, 1.75rem); }
p { margin: 0 0 1em; }
button, input, select, textarea { font: inherit; color: inherit; }
svg { width: 22px; height: 22px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
:focus-visible { outline: 3px solid var(--zari); outline-offset: 2px; border-radius: 4px; }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.skip { position: absolute; left: -999px; top: 8px; background: var(--ink); color: #fff; padding: 8px 12px; z-index: 100; }
.skip:focus { left: 8px; }
[hidden] { display: none !important; }

/* ---------- buttons ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  min-height: 48px; padding: 0 22px; border: 1.5px solid var(--jamun); border-radius: 999px;
  background: var(--jamun); color: #fff; font-weight: 600; text-decoration: none; cursor: pointer;
  transition: background .15s, border-color .15s, color .15s;
}
.btn:hover { background: var(--jamun-d); border-color: var(--jamun-d); color: #fff; }
.btn.ghost { background: transparent; color: var(--jamun); }
.btn.ghost:hover { background: var(--petal); color: var(--jamun-d); }
.btn.block { width: 100%; }
.btn[disabled], .btn.busy { opacity: .6; pointer-events: none; }
.btn.loading { opacity: .85; pointer-events: none; }
.spinner { width: 18px; height: 18px; border: 2.5px solid rgba(255,255,255,.45); border-top-color: #fff; border-radius: 50%; animation: spin .8s linear infinite; flex: none; }
@keyframes spin { to { transform: rotate(360deg); } }
.upload-overlay { position: fixed; inset: 0; z-index: 90; display: grid; place-items: center; padding: 24px; background: rgba(34,27,38,.55); }
.upload-card { width: min(360px, 100%); background: #fff; border-radius: 14px; padding: 28px 22px 22px; text-align: center; box-shadow: 0 12px 40px rgba(34,27,38,.3); }
.spinner.big { width: 44px; height: 44px; border-width: 4px; border-color: var(--line); border-top-color: var(--jamun); margin: 0 auto 14px; display: block; }
.upload-title { font-weight: 700; font-size: 17px; margin: 0 0 6px; }
.upload-card .ur-text { text-align: center; color: var(--ash); font-size: 15px; margin: 0 0 14px; }
.upload-bar { height: 6px; background: var(--petal); border-radius: 3px; overflow: hidden; }
.upload-bar span { display: block; height: 100%; width: 0; background: var(--jamun); transition: width .2s; }
.upload-status { display: flex; align-items: center; gap: 10px; margin-top: 12px; color: var(--ash); font-size: 14px; }
.upload-status .spinner { border-color: var(--line); border-top-color: var(--jamun); }
.link-btn { background: none; border: 0; padding: 4px 0; color: var(--jamun); text-decoration: underline; text-underline-offset: 3px; cursor: pointer; }
.icon-btn {
  display: inline-grid; place-items: center; width: 44px; height: 44px; border: 0; border-radius: 50%;
  background: none; color: var(--ink); cursor: pointer; position: relative; text-decoration: none;
}
.icon-btn:hover { background: var(--petal); color: var(--ink); }

/* ---------- header ---------- */
.top { position: sticky; top: 0; z-index: 40; background: rgba(255,255,255,.96); backdrop-filter: saturate(1.4) blur(8px); border-bottom: 1px solid var(--line); }
.top-in {
  max-width: var(--wrap); margin: 0 auto; padding: 8px var(--pad);
  display: grid; grid-template-columns: auto 1fr auto auto; grid-template-areas: "menu brand track cart" "search search search search";
  align-items: center; column-gap: 4px; row-gap: 8px;
}
.menu-btn { grid-area: menu; }
.brand { grid-area: brand; justify-self: center; padding: 4px; }
.brand img { height: 26px; width: auto; }
.top-in > a[href$="track"] { grid-area: track; }
.cart-btn { grid-area: cart; }
.badge {
  position: absolute; top: 4px; right: 2px; min-width: 18px; height: 18px; padding: 0 5px; border-radius: 9px;
  background: var(--jamun); color: #fff; font-size: 11px; font-weight: 700; line-height: 18px; text-align: center;
}
.top-search { grid-area: search; display: flex; align-items: center; background: var(--petal); border-radius: 999px; padding-left: 16px; }
.top-search input { flex: 1; min-width: 0; height: 42px; border: 0; background: none; outline: none; }
.top-search input::placeholder { color: var(--ash); }
.top-search button { width: 44px; height: 42px; border: 0; background: none; cursor: pointer; color: var(--ink); }
.top-search:focus-within { box-shadow: 0 0 0 2px var(--jamun) inset; }

.cats {
  display: flex; gap: 6px; overflow-x: auto; scrollbar-width: none; padding: 10px var(--pad);
  max-width: var(--wrap); margin: 0 auto; -webkit-overflow-scrolling: touch;
}
.cats::-webkit-scrollbar { display: none; }
.cats a {
  flex: none; padding: 7px 14px; border: 1px solid var(--line); border-radius: 999px;
  color: var(--ink); text-decoration: none; font-size: 14px; white-space: nowrap;
}
.cats a:hover { border-color: var(--jamun); color: var(--jamun); }
.cats a.on { background: var(--ink); border-color: var(--ink); color: #fff; }

@media (min-width: 900px) {
  .top-in { grid-template-columns: auto auto 1fr auto auto; grid-template-areas: "menu brand search track cart"; column-gap: 12px; }
  .brand { justify-self: start; }
  .top-search { max-width: 560px; width: 100%; justify-self: center; }
}

/* ---------- sheets (menu, filters) ---------- */
.sheet { position: fixed; inset: 0; z-index: 60; background: rgba(34,27,38,.45); display: flex; }
.sheet-panel { background: var(--paper); overflow-y: auto; overscroll-behavior: contain; padding: 0 20px 20px; }
.sheet-panel.left { width: min(340px, 88vw); height: 100%; animation: in-left .22s ease-out; }
.sheet-panel.bottom { width: 100%; max-height: 88vh; margin-top: auto; border-radius: 18px 18px 0 0; animation: in-up .22s ease-out; }
.sheet-head { position: sticky; top: 0; background: var(--paper); display: flex; justify-content: space-between; align-items: center; padding: 12px 0; z-index: 1; font-size: 18px; }
.sheet-foot { position: sticky; bottom: -20px; background: var(--paper); display: flex; gap: 10px; padding: 14px 0 20px; margin-top: 8px; border-top: 1px solid var(--line); }
.sheet-foot .btn { flex: 1; }
@keyframes in-left { from { transform: translateX(-100%); } }
@keyframes in-up { from { transform: translateY(100%); } }
.menu-list { display: flex; flex-direction: column; margin-bottom: 20px; }
.menu-list a { padding: 12px 0; border-bottom: 1px solid var(--line); color: var(--ink); text-decoration: none; font-size: 17px; display: flex; justify-content: space-between; }
.menu-list.small a { font-size: 15px; padding: 9px 0; }
.menu-list span { color: var(--ash); font-size: 14px; }
.menu-h { font-size: 1.1rem; margin-top: 8px; }
.contact { list-style: none; padding: 0; margin: 0; display: grid; gap: 8px; }

/* ---------- flash / toast ---------- */
.flash { max-width: var(--wrap); margin: 12px auto 0; padding: 12px var(--pad); }
.flash.notice { background: #eef6f1; color: var(--ok); }
.flash.ur-text { text-align: right; font-size: 16px; }
.flash.error { background: #fbeef0; color: var(--off); }
.toast {
  position: fixed; left: 50%; bottom: calc(84px + env(safe-area-inset-bottom)); transform: translateX(-50%); z-index: 70;
  background: var(--ink); color: #fff; padding: 12px 18px; border-radius: 999px; font-size: 15px; max-width: 92vw; text-align: center;
  box-shadow: 0 8px 24px rgba(34,27,38,.25);
}
.toast a { color: #fff; font-weight: 700; margin-left: 8px; }

/* ---------- layout blocks ---------- */
main { min-height: 60vh; }
.block { max-width: var(--wrap); margin: 0 auto; padding: 28px var(--pad); }
.block-head { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; margin-bottom: 14px; }
.block-head h2 { margin: 0; }
.narrow { max-width: 720px; margin: 0 auto; padding: 24px var(--pad) 48px; }
.empty { padding: 32px 0; color: var(--ash); max-width: 60ch; }
.empty h2 { color: var(--ink); }
.hint { color: var(--ash); font-size: 14px; }

/* ---------- home: find by code ---------- */
.finder { background: var(--petal); border-bottom: 1px solid var(--line); }
.finder-in { max-width: var(--wrap); margin: 0 auto; padding: clamp(28px, 6vw, 64px) var(--pad); }
.finder h1 { font-size: clamp(2rem, 1.4rem + 3.6vw, 3.6rem); max-width: 14ch; }
.finder p { max-width: 46ch; color: var(--ash); font-size: 17px; }
.finder-form { display: flex; gap: 8px; max-width: 520px; margin: 18px 0 12px; }
.finder-form input {
  flex: 1; min-width: 0; height: 56px; padding: 0 18px; border: 1.5px solid var(--ink); border-radius: 999px; background: #fff;
  font-family: var(--serif); font-size: 22px; letter-spacing: .04em; text-transform: uppercase;
}
.finder-form input::placeholder { color: #b9b0b6; }
.finder-form .btn { min-height: 56px; }
.finder-alt { font-size: 15px !important; }

/* ---------- product grid + card ---------- */
.grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 18px 12px; }
@media (min-width: 640px) { .grid { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 24px 16px; } }
@media (min-width: 1100px) { .grid { grid-template-columns: repeat(4, minmax(0, 1fr)); } }
@media (min-width: 1100px) { .shop-body .grid { grid-template-columns: repeat(4, minmax(0, 1fr)); } }

.card-link { display: block; color: inherit; text-decoration: none; }
.card-img { position: relative; aspect-ratio: 9 / 16; background: var(--petal); border-radius: var(--r); overflow: hidden; }
.card-img img { width: 100%; height: 100%; object-fit: cover; transition: transform .4s ease; }
.card-link:hover .card-img img { transform: scale(1.025); }
.card-body { padding: 10px 2px 0; }
.card-price { font-weight: 700; font-size: 16px; margin: 0; }
.card-title { margin: 2px 0 0; font-size: 14px; color: var(--ink); line-height: 1.35; }
.card-meas { margin: 2px 0 0; font-size: 13px; color: var(--ash); }

/* The hang tag: the dress code as people say it in lives and on WhatsApp. */
.tag {
  position: absolute; top: 12px; left: 12px; z-index: 1;
  display: inline-flex; align-items: center; gap: 7px;
  padding: 5px 10px 5px 8px; background: #fff; color: var(--ink);
  font-family: var(--serif); font-size: 15px; line-height: 1.1; letter-spacing: .02em;
  clip-path: polygon(9px 0, 100% 0, 100% 100%, 9px 100%, 0 50%);
  padding-left: 14px;
  filter: drop-shadow(0 1px 1.5px rgba(34,27,38,.25));
}
.tag::before { content: ""; width: 6px; height: 6px; border-radius: 50%; background: var(--petal); box-shadow: 0 0 0 1.5px var(--zari); flex: none; }
.tag.big { position: static; font-size: 22px; padding: 8px 16px 8px 20px; margin: 0 0 12px; filter: none; background: var(--petal); clip-path: polygon(13px 0, 100% 0, 100% 100%, 13px 100%, 0 50%); }
.tag.big::before { width: 8px; height: 8px; background: #fff; }

.sold-band {
  position: absolute; left: 0; right: 0; bottom: 14px; z-index: 1; text-align: center;
  background: rgba(34,27,38,.82); color: #fff; padding: 7px 0; font-size: 14px; font-weight: 600; letter-spacing: .02em;
}
.sold-band.big { bottom: auto; top: 50%; font-size: 18px; padding: 10px 0; pointer-events: none; }
.is-sold .card-price { color: var(--ash); text-decoration: line-through; text-decoration-thickness: 1px; }
.has-video { position: absolute; right: 10px; top: 12px; width: 30px; height: 30px; border-radius: 50%; display: grid; place-items: center; background: rgba(255,255,255,.92); }
.has-video svg { width: 14px; height: 14px; fill: var(--ink); stroke: none; margin-left: 2px; }

/* ---------- styles / sizes on home ---------- */
.styles { display: grid; grid-auto-flow: column; grid-auto-columns: 42%; gap: 12px; overflow-x: auto; scrollbar-width: none; padding-bottom: 4px; scroll-snap-type: x mandatory; }
.styles::-webkit-scrollbar { display: none; }
@media (min-width: 640px) { .styles { grid-auto-columns: 24%; } }
@media (min-width: 1100px) { .styles { grid-auto-flow: row; grid-template-columns: repeat(4, 1fr); } }
.style { position: relative; display: block; aspect-ratio: 3 / 4; border-radius: var(--r); overflow: hidden; color: #fff; text-decoration: none; scroll-snap-align: start; background: var(--petal); }
.style img { width: 100%; height: 100%; object-fit: cover; object-position: top; }
.style::after { content: ""; position: absolute; inset: 45% 0 0; background: linear-gradient(transparent, rgba(34,27,38,.78)); }
.style-name, .style-count { position: absolute; left: 14px; z-index: 1; }
.style-name { bottom: 32px; font-family: var(--serif); font-size: 21px; }
.style-count { bottom: 12px; font-size: 13px; opacity: .9; }
.style:hover { color: #fff; }

.sizes { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; }
@media (min-width: 640px) { .sizes { grid-template-columns: repeat(6, 1fr); } }
.size-link { display: flex; flex-direction: column; align-items: center; padding: 14px 6px; border: 1px solid var(--line); border-radius: var(--r); color: var(--ink); text-decoration: none; }
.size-link strong { font-family: var(--serif); font-weight: 400; font-size: 24px; }
.size-link span { font-size: 13px; color: var(--ash); }
.size-link:hover { border-color: var(--jamun); color: var(--jamun); }

.how { border-top: 1px solid var(--line); }
.steps { counter-reset: s; list-style: none; padding: 0; margin: 0 0 16px; display: grid; gap: 14px; max-width: 900px; }
@media (min-width: 900px) { .steps { grid-template-columns: repeat(3, 1fr); gap: 24px; } }
.steps li { counter-increment: s; position: relative; padding-left: 44px; color: var(--ash); }
.steps li strong { display: block; color: var(--ink); }
.steps li::before { content: counter(s); position: absolute; left: 0; top: -2px; width: 32px; height: 32px; border-radius: 50%; border: 1.5px solid var(--zari); display: grid; place-items: center; font-family: var(--serif); color: var(--ink); }
.how-note { color: var(--ash); font-size: 14px; max-width: 70ch; }

/* ---------- listing ---------- */
.shop { max-width: var(--wrap); margin: 0 auto; padding: 18px var(--pad) 48px; }
.shop-head { display: flex; align-items: baseline; gap: 12px; flex-wrap: wrap; }
.shop-head h1 { margin: 0; }
.count { color: var(--ash); margin: 0; }
.toolbar { display: flex; gap: 8px; flex-wrap: wrap; margin: 14px 0 10px; align-items: center; }
.chip-btn {
  display: inline-flex; align-items: center; gap: 6px; height: 40px; padding: 0 14px;
  border: 1px solid var(--line); border-radius: 999px; background: #fff; color: var(--ink); text-decoration: none; font-size: 14px; cursor: pointer;
}
.chip-btn svg { width: 18px; height: 18px; }
.chip-btn:hover { border-color: var(--jamun); color: var(--jamun); }
.chip-btn.on { background: var(--ink); border-color: var(--ink); color: #fff; }
.chip-btn .n { background: var(--jamun); color: #fff; border-radius: 9px; min-width: 18px; height: 18px; font-size: 11px; display: inline-grid; place-items: center; padding: 0 5px; }
.sort select { height: 40px; border: 1px solid var(--line); border-radius: 999px; padding: 0 34px 0 14px; background: #fff url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23221b26' stroke-width='2'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E") no-repeat right 12px center / 14px; appearance: none; font-size: 14px; cursor: pointer; }
.toolbar .share { margin-left: auto; }
.pills { display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: 16px; }
.pill { display: inline-flex; align-items: center; gap: 4px; padding: 5px 8px 5px 12px; border-radius: 999px; background: var(--petal); color: var(--ink); text-decoration: none; font-size: 14px; }
.pill svg { width: 15px; height: 15px; }
.pill:hover { background: var(--line); color: var(--ink); }
.pill.clear { background: none; text-decoration: underline; color: var(--jamun); }

.filters fieldset { border: 0; border-top: 1px solid var(--line); padding: 14px 0 6px; margin: 0; }
.filters legend { font-family: var(--serif); font-size: 18px; padding: 0; float: left; width: 100%; margin-bottom: 10px; }
.opts { display: flex; flex-wrap: wrap; gap: 6px; clear: both; margin-bottom: 8px; }
.opt { position: relative; cursor: pointer; }
.opt input { position: absolute; opacity: 0; inset: 0; cursor: pointer; }
.opt span { display: inline-block; padding: 7px 13px; border: 1px solid var(--line); border-radius: 999px; font-size: 14px; }
.opt input:checked + span { background: var(--ink); border-color: var(--ink); color: #fff; }
.opt input:focus-visible + span { outline: 3px solid var(--zari); outline-offset: 2px; }
.opt.wide { display: block; margin: 14px 0; }
.opt-link { padding: 7px 13px; border: 1px dashed var(--line); border-radius: 999px; font-size: 14px; color: var(--ink); text-decoration: none; }
.price-row { display: flex; gap: 10px; clear: both; margin-bottom: 10px; }
.price-row label { flex: 1; min-width: 0; display: flex; flex-direction: column; font-size: 13px; color: var(--ash); gap: 4px; }
.price-row input { width: 100%; min-width: 0; height: 44px; border: 1px solid var(--line); border-radius: var(--r-sm); padding: 0 12px; }

@media (min-width: 1100px) {
  .shop-body { display: grid; grid-template-columns: 260px 1fr; gap: 32px; align-items: start; }
  .filters-sheet[hidden] { display: block !important; }
  .filters-sheet { z-index: 1; position: sticky; top: calc(var(--top-h) + 16px); inset: auto; background: none; display: block; max-height: calc(100vh - var(--top-h) - 32px); overflow-y: auto; }
  .filters-sheet .sheet-panel.bottom { max-height: none; border-radius: 0; padding: 0 4px 0 0; animation: none; }
  .filters-sheet .sheet-head { display: none; }
  .filters-sheet .sheet-foot { bottom: 0; }
  [data-open="filters"] { display: none; }
}
.more { text-align: center; margin-top: 28px; }

/* ---------- product page ---------- */
.crumbs { max-width: var(--wrap); margin: 0 auto; padding: 12px var(--pad) 0; font-size: 14px; color: var(--ash); display: flex; gap: 8px; flex-wrap: wrap; }
.crumbs a { color: var(--ash); }
.pdp { max-width: var(--wrap); margin: 0 auto; padding: 12px var(--pad) 24px; display: grid; gap: 20px; }
@media (min-width: 900px) { .pdp { grid-template-columns: minmax(0, 600px) minmax(320px, 460px); justify-content: center; gap: 48px; align-items: start; } }
.gallery { position: relative; margin: 0 calc(var(--pad) * -1); }
@media (min-width: 900px) { .gallery { margin: 0; display: grid; grid-template-columns: 76px 1fr; gap: 12px; } }
.slides { display: flex; overflow-x: auto; scroll-snap-type: x mandatory; scrollbar-width: none; scroll-behavior: smooth; }
.slides::-webkit-scrollbar { display: none; }
@media (min-width: 900px) { .slides { grid-column: 2; grid-row: 1; border-radius: var(--r); max-height: calc(100vh - var(--top-h) - 40px); aspect-ratio: 9 / 16; } }
.slide { flex: 0 0 100%; margin: 0; scroll-snap-align: start; aspect-ratio: 9 / 16; background: var(--petal); position: relative; }
.slide img, .slide iframe { width: 100%; height: 100%; object-fit: contain; border: 0; }
@media (min-width: 900px) { .slide { height: 100%; } }
.video-poster { all: unset; position: relative; display: block; width: 100%; height: 100%; cursor: pointer; }
.video-poster img { filter: brightness(.75); }
.play { position: absolute; inset: 0; display: grid; place-content: center; justify-items: center; gap: 10px; color: #fff; font-weight: 600; }
.play svg { width: 68px; height: 68px; padding: 18px 16px 18px 20px; border-radius: 50%; background: rgba(255,255,255,.95); fill: var(--jamun); stroke: none; }
.thumbs { display: flex; gap: 6px; justify-content: center; padding: 10px var(--pad) 0; }
.thumb { position: relative; width: 10px; height: 10px; border-radius: 50%; background: var(--line); overflow: hidden; flex: none; }
.thumb img { display: none; }
.thumb.on { background: var(--jamun); }
.thumb-play { display: none; }
@media (min-width: 900px) {
  .thumbs { grid-column: 1; grid-row: 1; flex-direction: column; justify-content: flex-start; padding: 0; gap: 8px; overflow-y: auto; max-height: calc(100vh - var(--top-h) - 40px); }
  .thumb { width: 76px; height: auto; aspect-ratio: 9 / 16; border-radius: var(--r-sm); border: 2px solid transparent; background: var(--petal); }
  .thumb img { display: block; width: 100%; height: 100%; object-fit: cover; }
  .thumb.on { border-color: var(--jamun); background: var(--petal); }
  .thumb-play { display: grid; position: absolute; inset: 0; place-items: center; background: rgba(34,27,38,.3); }
  .thumb-play svg { fill: #fff; stroke: none; width: 22px; }
}
.info { min-width: 0; }
@media (min-width: 900px) { .info { position: sticky; top: calc(var(--top-h) + 16px); } }
.info h1 { font-size: clamp(1.5rem, 1.2rem + 1.4vw, 2.1rem); margin-bottom: 6px; }
.price { font-size: 26px; font-weight: 700; margin-bottom: 6px; }
.pdp.is-sold .price { color: var(--ash); text-decoration: line-through; text-decoration-thickness: 1.5px; }
.status { font-size: 15px; display: flex; align-items: center; gap: 8px; }
.status::before { content: ""; width: 9px; height: 9px; border-radius: 50%; background: currentColor; }
.status.ok { color: var(--ok); }
.status.off { color: var(--off); }
.buy { display: grid; gap: 10px; margin: 16px 0 10px; }
.buy form .btn { width: 100%; }
.buy .btn { min-height: 52px; font-size: 17px; }
.facts { border-top: 1px solid var(--line); padding-top: 18px; margin-top: 20px; }
.facts h2 { font-size: 1.3rem; }
.facts-note { font-size: 14px; color: var(--ash); }
.meas { display: grid; grid-template-columns: repeat(auto-fill, minmax(88px, 1fr)); gap: 8px; margin: 0; }
.meas div { background: var(--petal); border-radius: var(--r-sm); padding: 10px 12px; }
.meas dt { font-size: 13px; color: var(--ash); }
.meas dd { margin: 0; font-family: var(--serif); font-size: 24px; }
.details { margin: 0; }
.details div { display: flex; justify-content: space-between; gap: 16px; padding: 9px 0; border-bottom: 1px solid var(--line); }
.details dt { color: var(--ash); }
.details dd { margin: 0; text-align: right; }
.notes { margin-top: 12px; }
.cat-links { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 12px; }
.cat-links a { font-size: 14px; padding: 5px 12px; border-radius: 999px; background: var(--petal); color: var(--ink); text-decoration: none; }
.terms summary { cursor: pointer; font-family: var(--serif); font-size: 1.15rem; padding: 2px 0; }
.terms ul { padding-left: 20px; color: var(--ash); }
.terms li { margin: 6px 0; }
.buy-bar {
  position: fixed; left: 0; right: 0; bottom: 0; z-index: 30; display: flex; align-items: center; justify-content: space-between; gap: 12px;
  padding: 10px var(--pad) calc(10px + env(safe-area-inset-bottom)); background: #fff; border-top: 1px solid var(--line);
  transform: translateY(110%); transition: transform .2s ease;
}
.buy-bar.show { transform: none; }
.buy-bar div { display: flex; flex-direction: column; line-height: 1.2; }
.buy-bar strong { font-family: var(--serif); font-weight: 400; font-size: 18px; }
.buy-bar span { font-weight: 700; }
@media (min-width: 900px) { .buy-bar { display: none; } }

/* ---------- cart, checkout, order ---------- */
.lines { list-style: none; padding: 0; margin: 0 0 16px; }
.line { display: grid; grid-template-columns: 140px 1fr auto; gap: 14px; padding: 14px 0; border-bottom: 1px solid var(--line); align-items: start; }
.line-img { display: block; }
.line-img img { width: 100%; height: auto; aspect-ratio: 9 / 16; object-fit: contain; border-radius: var(--r-sm); background: var(--petal); }
.line-code { font-family: var(--serif); font-size: 18px; margin: 0; }
.line-title { margin: 0; font-size: 14px; color: var(--ash); }
.line-gone { color: var(--off); font-size: 14px; margin: 4px 0 0; }
.line.gone .line-price { text-decoration: line-through; color: var(--ash); }
.line-end { text-align: right; }
.line-price { font-weight: 700; margin: 0 0 4px; }
.lines.compact .line { grid-template-columns: 120px 1fr auto; padding: 10px 0; }
@media (max-width: 360px) { .line { grid-template-columns: 112px 1fr auto; } .lines.compact .line { grid-template-columns: 100px 1fr auto; } }
.totals { margin: 0 0 12px; }
.totals div { display: flex; justify-content: space-between; gap: 12px; padding: 6px 0; }
.totals dt { color: var(--ash); }
.totals dd { margin: 0; text-align: right; }
.totals .muted dd { color: var(--ash); font-size: 14px; }
.totals .grand { border-top: 1px solid var(--line); margin-top: 4px; padding-top: 10px; font-weight: 700; }
.totals .grand dt { color: var(--ink); }
.totals .paynow { background: var(--petal); margin: 8px -12px 0; padding: 10px 12px; border-radius: var(--r-sm); font-weight: 700; }
.totals .paynow dt { color: var(--jamun); }
.actions { display: flex; gap: 10px; flex-wrap: wrap; justify-content: flex-end; margin-top: 16px; }

.checkout { max-width: var(--wrap); margin: 0 auto; padding: 20px var(--pad) 48px; }
.co { display: grid; gap: 20px; }
@media (min-width: 900px) { .co { grid-template-columns: minmax(0, 1fr) 380px; gap: 32px; align-items: start; } .co-side { position: sticky; top: calc(var(--top-h) + 16px); } }
.box { border: 1px solid var(--line); border-radius: var(--r); padding: 16px; margin: 0 0 16px; min-width: 0; }
.box legend, .box > h2 { font-family: var(--serif); font-size: 1.25rem; padding: 0 6px; margin-left: -6px; }
.box > h2 { padding: 0; margin: 0 0 10px; }
.field { margin-bottom: 14px; }
.field label { display: block; font-weight: 600; margin-bottom: 5px; font-size: 15px; }
.field input:not([type=radio]):not([type=checkbox]):not([type=file]), .field select, .field textarea {
  width: 100%; min-height: 48px; padding: 10px 12px; border: 1px solid #cfc4ca; border-radius: var(--r-sm); background: #fff; font-size: 16px;
}
.field textarea { min-height: 72px; resize: vertical; }
.field textarea.address-box { resize: none; min-height: 0; height: calc(3 * 1.5em + 22px); line-height: 1.5; overflow-y: auto; }
.field input:focus, .field select:focus, .field textarea:focus { outline: none; border-color: var(--jamun); box-shadow: 0 0 0 3px rgba(107,31,79,.15); }
.field [aria-invalid="true"] { border-color: var(--off) !important; }
.field-help { font-size: 13px; color: var(--ash); margin: 5px 0 0; }
.field-err { font-size: 14px; color: var(--off); margin: 5px 0 0; }
.opt-l { font-weight: 400; color: var(--ash); }
.two { display: grid; gap: 0 12px; }
@media (min-width: 560px) { .two { grid-template-columns: 1fr 1fr; } }
.form-err { background: #fbeef0; color: var(--off); padding: 12px 14px; border-radius: var(--r-sm); margin-bottom: 16px; }
.other-receiver summary { cursor: pointer; color: var(--jamun); margin-bottom: 10px; }
.hp { position: absolute; left: -9999px; }
.pay-opt { display: block; position: relative; margin-bottom: 10px; cursor: pointer; }
.pay-opt input { position: absolute; left: 16px; top: 18px; width: 20px; height: 20px; accent-color: var(--jamun); }
.pay-card { display: block; padding: 14px 14px 14px 48px; border: 1.5px solid var(--line); border-radius: var(--r); }
.pay-card strong { display: block; }
.pay-card span { color: var(--ash); font-size: 14px; }
.pay-opt input:checked + .pay-card { border-color: var(--jamun); background: var(--petal); }
.summary h2 { margin-bottom: 6px; }

.placed { background: var(--petal); border-radius: var(--r); padding: 20px; margin-bottom: 16px; }
.placed h1 { font-size: clamp(1.6rem, 1.3rem + 1.5vw, 2.2rem); }
.placed p { margin: 0; }
.order-status { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; margin-bottom: 16px; }
.order-status span { padding: 5px 12px; border-radius: 999px; font-weight: 600; font-size: 14px; }
.order-status.wait span { background: #fff4e0; color: #7a5410; }
.order-status.ok span { background: #e8f3ed; color: var(--ok); }
.order-status.off span { background: #f2eef0; color: var(--ash); }
.pay { border-color: var(--jamun); }
.accounts { list-style: none; padding: 0; margin: 0 0 18px; display: grid; gap: 8px; }
.accounts li { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 8px 12px; padding: 10px 12px; background: var(--petal); border-radius: var(--r-sm); min-width: 0; }
.acc-info { display: flex; flex-direction: column; min-width: 0; }
.acc-bank { font-weight: 700; }
.acc-title { font-size: 14px; color: var(--ash); overflow-wrap: anywhere; }
.acc-num {
  display: flex; align-items: center; gap: 10px; max-width: 100%; min-width: 0;
  border: 0; background: #fff; border-radius: var(--r-sm); padding: 8px 10px; cursor: pointer;
  font-family: var(--sans); font-size: 16px; font-weight: 600; font-variant-numeric: tabular-nums; letter-spacing: .02em; color: var(--ink);
}
.acc-digits { overflow-wrap: anywhere; text-align: left; }
.acc-copy { flex: none; font-size: 13px; font-weight: 600; color: var(--jamun); }
@media (max-width: 420px) { .acc-num { width: 100%; justify-content: space-between; } }
.proof { border-top: 1px solid var(--line); padding-top: 16px; }
/* Screenshot picker: the real file input sits invisibly over the whole box, so tapping anywhere opens the gallery. */
.field-label { display: block; font-weight: 600; margin-bottom: 5px; font-size: 15px; }
.pick { position: relative; display: block; border: 2px dashed var(--jamun); border-radius: var(--r); background: var(--petal); cursor: pointer; transition: background .15s; }
.pick:hover { background: #f1e6ec; }
.pick input[type=file] { position: absolute; inset: 0; width: 100%; height: 100%; opacity: 0; cursor: pointer; }
.pick:focus-within { outline: 3px solid var(--zari); outline-offset: 2px; }
.pick.has-error { border-color: var(--off); }
.pick-empty { display: flex; flex-direction: column; align-items: center; gap: 4px; padding: 22px 16px; text-align: center; pointer-events: none; }
.pick-empty svg { width: 40px; height: 40px; color: var(--jamun); margin-bottom: 4px; }
.pick-empty strong { font-size: 17px; color: var(--jamun); }
.pick-empty span { font-size: 14px; color: var(--ash); }
.pick-chosen { display: flex; align-items: center; gap: 14px; padding: 12px; pointer-events: none; }
.pick.chosen { border-style: solid; background: #fff; }
.pick-chosen img { width: 64px; height: 96px; object-fit: cover; border-radius: var(--r-sm); background: var(--petal); flex: none; }
.pick-info { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.pick-info strong { overflow-wrap: anywhere; font-size: 15px; }
.pick-change { color: var(--jamun); text-decoration: underline; font-size: 14px; }
.paid-to { border: 0; padding: 0; margin: 0 0 14px; }
.box .paid-to legend { font-family: var(--sans); font-weight: 600; font-size: 15px; margin: 0 0 6px; padding: 0; }
.proof-done ul { margin: 6px 0 0; padding-left: 18px; }
.proof-done p { margin: 0; }
.proof-done .ur-text { color: var(--ok); }
.proof-done { margin-top: 14px; background: #e8f3ed; color: var(--ok); padding: 10px 12px; border-radius: var(--r-sm); }
.addr { line-height: 1.6; }
.share-order { text-align: center; }

.notice-page { max-width: 720px; margin: 0 auto; padding: 40px var(--pad) 8px; }
.notice-page p { color: var(--ash); }

/* ---------- footer ---------- */
.foot { border-top: 1px solid var(--line); margin-top: 32px; background: var(--petal); }
.foot-in { max-width: var(--wrap); margin: 0 auto; padding: 32px var(--pad) 12px; display: grid; gap: 24px; }
@media (min-width: 760px) { .foot-in { grid-template-columns: 2fr 1fr 1fr; } }
.foot h2 { font-size: 1.1rem; }
.foot-in > div > a { display: block; margin: 6px 0; color: var(--ink); }
.foot p { color: var(--ash); max-width: 40ch; margin-top: 10px; }
.foot-note { max-width: var(--wrap); margin: 0 auto; padding: 0 var(--pad) calc(90px + env(safe-area-inset-bottom)); color: var(--ash); font-size: 13px; }

.wa-float {
  position: fixed; right: 16px; bottom: calc(16px + env(safe-area-inset-bottom)); z-index: 25;
  width: 54px; height: 54px; border-radius: 50%; display: grid; place-items: center; background: #25d366; color: #fff;
  box-shadow: 0 6px 18px rgba(0,0,0,.2);
}
.wa-float svg { width: 30px; height: 30px; stroke: none; }
.wa-float:hover { color: #fff; }
body.has-buy-bar .wa-float { bottom: calc(84px + env(safe-area-inset-bottom)); }

/* ---------- Urdu lines (text in app/Config/UrduText.php) ---------- */
.ur-text {
  display: block; direction: rtl; text-align: right; unicode-bidi: isolate;
  font-family: "Noto Nastaliq Urdu", "Jameel Noori Nastaleeq", "Urdu Typesetting", "Noto Naskh Arabic", "Segoe UI", Tahoma, sans-serif;
  line-height: 2; font-size: 16px; color: var(--ink);
}
.pay-card .ur-text { color: var(--ash); font-size: 15px; margin-top: 4px; }
.ur-note { background: var(--petal); border-radius: var(--r-sm); padding: 10px 14px; margin: 4px 0 0; }
.placed .ur-text { margin-top: 6px; }
.summary .ur-text.hint { font-size: 15px; color: var(--ash); }

/* ---------- searchable district ---------- */
.combo { position: relative; }
.combo-list {
  position: absolute; z-index: 20; left: 0; right: 0; top: calc(100% + 4px); max-height: 260px; overflow-y: auto;
  margin: 0; padding: 4px 0; list-style: none; background: #fff; border: 1px solid #cfc4ca; border-radius: var(--r-sm);
  box-shadow: 0 8px 24px rgba(34,27,38,.12);
}
.combo-list li { padding: 10px 12px; cursor: pointer; display: flex; justify-content: space-between; gap: 10px; }
.combo-list li span { color: var(--ash); font-size: 13px; }
.combo-list li[aria-selected="true"], .combo-list li:hover { background: var(--petal); }
.combo-list .combo-empty { color: var(--ash); cursor: default; }
.combo-list .combo-empty:hover { background: none; }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; scroll-behavior: auto !important; }
  .spinner { animation: spin 1.6s linear infinite !important; }
}
