* { box-sizing: border-box; }
html, body { margin: 0; min-height: 100%; }
body {
  background: #eaeded;
  font-family: system-ui, "Segoe UI", Tahoma, Arial, sans-serif;
  color: #0f1111;
  font-size: 14px;
  line-height: 1.5;
}
.page { max-width: 720px; margin: 0 auto; padding: 10px 10px 24px; }
a { color: #8a6414; }
button { font-family: inherit; }

/* Marketplace-style dark header */
.st-header { display: flex; flex-direction: column; gap: 6px; }
.st-topbar { display: flex; align-items: center; justify-content: space-between; gap: 12px; background: #141414; color: #fff; padding: 10px 14px; border-radius: 10px; }
.st-brand { font-weight: 700; font-size: 16px; color: #fff; }
.st-cartlink { position: relative; display: inline-flex; align-items: center; color: #fff; text-decoration: none; padding: 6px; }
.st-cartcount { position: absolute; top: -2px; inset-inline-end: -4px; background: #e2b84b; color: #0f1111; font-size: 11px; font-weight: 700; border-radius: 999px; min-width: 18px; height: 18px; display: inline-flex; align-items: center; justify-content: center; padding: 0 4px; }
.st-cartcount[hidden] { display: none; }

.st-tabs { display: flex; flex-wrap: wrap; gap: 2px 16px; background: #141414; border-radius: 10px; padding: 0 12px; }
.st-tabs a { padding: 8px 0; color: #d5dbdb; text-decoration: none; font-size: 13px; display: inline-flex; align-items: center; min-height: 40px; }
.st-tabs a.active { color: #fff; font-weight: 600; box-shadow: inset 0 -2px 0 #e2b84b; }

/* Hero banner */
.st-hero { display: flex; flex-direction: column; gap: 6px; margin: 12px 0 0; padding: 14px 16px; border-radius: 12px; background: linear-gradient(135deg, #141414 0%, #2b2417 55%, #b8892b 100%); color: #fff; }
.st-herotitle { font-size: 16px; font-weight: 700; }
.st-herosub { font-size: 12px; line-height: 18px; color: #e8ecef; }

/* Generic kit-ish blocks */
.group { background: #fff; border: 1px solid #e3e6e6; border-radius: 10px; padding: 14px; margin-top: 14px; display: flex; flex-direction: column; gap: 10px; }
.group-title { font-weight: 700; font-size: 16px; }
.callout { border-radius: 8px; padding: 10px 12px; font-size: 13px; line-height: 20px; border: 1px solid; }
.callout strong { display: block; margin-bottom: 2px; }
.callout.note { background: #f0f7ff; border-color: #b8d6f5; color: #0f1111; }
.callout.warning { background: #fff8e1; border-color: #f0d67a; color: #0f1111; }
.callout.positive { background: #e9f7ef; border-color: #9ed6b2; color: #0f1111; }
.caption { color: #565959; font-size: 12px; line-height: 18px; }
.field { display: flex; flex-direction: column; gap: 4px; }
.field label { font-weight: 600; font-size: 13px; }
.field input { border: 1px solid #d5d9d9; border-radius: 8px; padding: 10px 12px; font-size: 15px; font-family: inherit; background: #fff; }
.field input:focus { outline: 2px solid #8a6414; outline-offset: -1px; }

.btn { display: inline-flex; align-items: center; justify-content: center; border-radius: 999px; padding: 10px 18px; font-size: 14px; font-weight: 600; cursor: pointer; text-decoration: none; border: 1px solid transparent; min-height: 44px; }
.btn.primary { background: #e2b84b; color: #0f1111; border-color: #fcd200; }
.btn.primary:hover { background: #f7ca00; }
.btn.primary[disabled] { background: #f0f2f2; color: #565959; border-color: #e3e6e6; cursor: default; }
.btn.secondary { background: #fff; color: #0f1111; border-color: #d5d9d9; }
.btn.secondary:hover { background: #f7fafa; }
.btn.ghost { background: transparent; color: #8a6414; border-color: transparent; padding: 6px 10px; min-height: 36px; }
.btn.compact { padding: 6px 14px; min-height: 36px; font-size: 13px; }

/* Search + filter controls */
.st-controls { display: flex; flex-direction: column; margin-top: 12px; }
.st-controls > * + * { margin-top: 10px; }
.choices { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.choices .choices-label { font-weight: 600; font-size: 13px; }
.choice { border: 1px solid #d5d9d9; background: #fff; border-radius: 999px; padding: 6px 14px; font-size: 13px; cursor: pointer; min-height: 36px; }
.choice.selected { background: #141414; color: #fff; border-color: #141414; }
.choice[disabled] { color: #a2a6a6; text-decoration: line-through; cursor: default; }

/* Sections, rails, grid, cards */
.st-section { margin-top: 16px; }
.st-sectionhead { display: flex; align-items: baseline; justify-content: space-between; margin-bottom: 8px; }
.st-sectiontitle { font-weight: 700; font-size: 16px; }
.st-viewall { color: #8a6414; font-size: 13px; text-decoration: none; font-weight: 600; }
.st-rail { display: flex; gap: 12px; overflow-x: auto; scroll-snap-type: x mandatory; padding-bottom: 8px; -webkit-overflow-scrolling: touch; }
.st-rail > * { scroll-snap-align: start; flex: 0 0 200px; }
@media (max-width: 360px) { .st-rail > * { flex-basis: 172px; } }
.st-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 14px 12px; }
@media (max-width: 360px) { .st-grid { grid-template-columns: 1fr; } }
@media (min-width: 768px) { .st-grid { grid-template-columns: repeat(3, 1fr); gap: 18px 16px; } }

.st-mini { display: flex; flex-direction: column; gap: 7px; min-width: 0; background: #fff; border-radius: 10px; padding: 10px; border: 1px solid #e3e6e6; }
.st-photowrap { position: relative; }
.st-photo { width: 100%; aspect-ratio: 1; object-fit: cover; border-radius: 8px; display: block; background: #f6f6f6; }
.st-heart { position: absolute; top: 8px; inset-inline-start: 8px; width: 36px; height: 36px; border-radius: 50%; border: 1px solid #e3e6e6; background: rgba(255,255,255,0.95); color: #8a6414; font-size: 17px; line-height: 1; cursor: pointer; display: flex; align-items: center; justify-content: center; padding: 0; }
.st-heart.is-on { color: #c2255c; border-color: #c2255c; }
.st-minititle { font-size: 13px; line-height: 18px; min-height: 36px; font-weight: 600; }
.st-miniprice { font-size: 16px; font-weight: 700; }
.st-note { color: #565959; font-size: 12px; line-height: 18px; }
.st-buyrow { display: flex; align-items: center; justify-content: space-between; gap: 8px; flex-wrap: wrap; }
.st-stepper { display: inline-flex; align-items: center; gap: 4px; }
.st-qty { min-width: 24px; text-align: center; font-weight: 600; }

/* Cart */
.st-lines { display: flex; flex-direction: column; background: #fff; border-radius: 10px; padding: 4px 14px; border: 1px solid #e3e6e6; }
.st-line { display: flex; align-items: center; gap: 12px; padding: 12px 0; border-bottom: 1px solid #e3e6e6; }
.st-line:last-child { border-bottom: none; }
.st-thumb { width: 56px; height: 56px; object-fit: cover; border-radius: 8px; flex-shrink: 0; background: #f6f6f6; }
.st-lineinfo { display: flex; flex-direction: column; gap: 4px; flex: 1; min-width: 0; }
.st-lineprice { font-weight: 700; white-space: nowrap; }
.st-total { display: flex; justify-content: space-between; align-items: baseline; padding-top: 4px; font-size: 16px; }

.st-closing { color: #565959; font-size: 12px; text-align: center; margin: 18px 0 10px; }
.st-photonote { position: absolute; bottom: 6px; inset-inline-start: 6px; background: rgba(15,17,17,0.75); color: #fff; font-size: 10px; line-height: 1; padding: 4px 7px; border-radius: 6px; }

/* ===== v2 redesign ===== */
body { background: #f2f3f3; padding-bottom: 76px; }
.page { padding: 0 0 20px; max-width: 760px; }
#app { padding: 0 12px; }
.top { position: sticky; top: 0; z-index: 30; background: #141414; color: #fff; padding: 8px 12px 0; }
.top-row { display: flex; align-items: center; justify-content: space-between; }
.brand { color: #fff; text-decoration: none; font-weight: 800; font-size: 19px; letter-spacing: .2px; }
.brand::after { content: ""; display: inline-block; width: 8px; height: 8px; border-radius: 50%; background: #e2b84b; margin-inline-start: 6px; }
.cartlink { position: relative; color: #fff; padding: 8px; display: inline-flex; }
.cartcount { position: absolute; top: 0; inset-inline-end: -2px; background: #e2b84b; color: #0f1111; font-size: 11px; font-weight: 700; border-radius: 999px; min-width: 18px; height: 18px; display: inline-flex; align-items: center; justify-content: center; padding: 0 4px; }
.cartcount[hidden] { display: none; }
.searchbar { display: flex; margin: 4px 0 8px; border-radius: 10px; overflow: hidden; background: #fff; }
.searchbar input { flex: 1; border: 0; padding: 11px 12px; font-size: 15px; font-family: inherit; min-width: 0; outline: none; }
.searchbar button { border: 0; background: #e2b84b; color: #0f1111; font-weight: 700; padding: 0 16px; font-family: inherit; cursor: pointer; }
.pills { display: flex; gap: 8px; overflow-x: auto; padding: 0 0 10px; }
.pills a { flex: none; color: #fff; text-decoration: none; font-size: 13px; padding: 6px 14px; border-radius: 999px; border: 1px solid #485769; }
.pills a.active { background: #fff; color: #141414; border-color: #fff; font-weight: 700; }
.bottomnav { position: fixed; bottom: 0; inset-inline: 0; z-index: 40; background: #fff; border-top: 1px solid #d5d9d9; display: flex; max-width: 760px; margin: 0 auto; }
.bottomnav a { flex: 1; display: flex; flex-direction: column; align-items: center; gap: 2px; padding: 8px 2px 10px; color: #565959; text-decoration: none; font-size: 11px; }
.bottomnav a.active { color: #8a6414; font-weight: 700; box-shadow: inset 0 2px 0 #8a6414; }
.foot { text-align: center; color: #565959; font-size: 12px; padding: 16px 12px 0; }
.crumbs { font-size: 12px; color: #565959; margin: 12px 0 8px; }
.crumbs a { color: #8a6414; text-decoration: none; }
.hero { margin-top: 12px; border-radius: 14px; padding: 22px 18px; color: #fff; background: linear-gradient(135deg, #141414, #2b2417 55%, #b8892b); }
.hero h1 { margin: 0 0 6px; font-size: 20px; }
.hero p { margin: 0 0 14px; font-size: 13px; color: #e8ecef; }
.trust { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; margin-top: 12px; }
.trust div { background: #fff; border-radius: 10px; padding: 10px 6px; text-align: center; display: flex; flex-direction: column; align-items: center; gap: 3px; color: #8a6414; border: 1px solid #e3e6e6; }
.trust b { color: #0f1111; font-size: 12px; } .trust small { color: #565959; font-size: 10.5px; line-height: 14px; }
.cats { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin-top: 12px; }
.cat { display: flex; flex-direction: column; gap: 2px; padding: 18px 14px; border-radius: 12px; background: #fde8ef; color: #0f1111; text-decoration: none; font-weight: 700; font-size: 16px; }
.cat.alt { background: #e3f0fb; } .cat small { font-weight: 400; color: #565959; font-size: 12px; }
.block { margin-top: 18px; } .block h2, .bh h2 { margin: 0; font-size: 17px; }
.bh { display: flex; justify-content: space-between; align-items: baseline; margin: 14px 0 8px; }
.bh a { color: #8a6414; font-size: 13px; text-decoration: none; font-weight: 600; }
.how { background: #fff; border-radius: 12px; padding: 14px; border: 1px solid #e3e6e6; } .how ol { margin: 8px 0 0; padding-inline-start: 20px; line-height: 26px; }
.rail { display: flex; gap: 10px; overflow-x: auto; scroll-snap-type: x mandatory; padding-bottom: 8px; }
.rail > .pc { flex: 0 0 168px; scroll-snap-align: start; }
.pgrid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 10px; }
@media (min-width: 640px) { .pgrid { grid-template-columns: repeat(3, 1fr); } }
.pc { position: relative; display: flex; flex-direction: column; gap: 4px; background: #fff; border-radius: 12px; padding: 8px; border: 1px solid #e3e6e6; min-width: 0; }
.pc-img { position: relative; display: block; }
.pc-img img { width: 100%; aspect-ratio: 1; object-fit: cover; border-radius: 8px; display: block; background: #f6f6f6; }
.pc-badge { position: absolute; bottom: 6px; inset-inline-end: 6px; background: #141414; color: #fff; font-size: 10px; padding: 3px 8px; border-radius: 999px; }
.pc-badge.out { background: #b12704; }
.pc-heart { position: absolute; top: 12px; inset-inline-start: 12px; width: 34px; height: 34px; border-radius: 50%; border: 1px solid #e3e6e6; background: rgba(255,255,255,.95); color: #565959; font-size: 18px; cursor: pointer; display: flex; align-items: center; justify-content: center; padding: 0; z-index: 2; }
.pc-heart.on { color: #c2255c; border-color: #c2255c; }
.pc-title { color: #0f1111; text-decoration: none; font-size: 13px; line-height: 18px; font-weight: 600; min-height: 36px; }
.pc-price { font-size: 17px; font-weight: 800; color: #b12704; } .pc-from { font-size: 11px; font-weight: 400; color: #565959; }
.pc-meta { font-size: 11px; color: #565959; }
.pc-actions { display: flex; flex-direction: column; gap: 4px; margin-top: 4px; }
.pc-actions .btn { width: 100%; }
.btn.buy { background: #c9962f; border-color: #ff8f00; color: #0f1111; }
.btn[disabled] { opacity: .5; cursor: default; }
.tools { display: flex; align-items: center; justify-content: space-between; margin: 8px 0; }
.count { font-size: 13px; color: #565959; }
.sel { display: inline-flex; align-items: center; gap: 6px; font-size: 13px; }
.sel select { border: 1px solid #d5d9d9; border-radius: 8px; padding: 7px 8px; background: #f0f2f2; font-family: inherit; font-size: 13px; }
.chips { display: flex; gap: 8px; overflow-x: auto; padding: 4px 0 8px; }
.chip { flex: none; border: 1px solid #d5d9d9; background: #fff; border-radius: 999px; padding: 6px 14px; font-size: 13px; cursor: pointer; text-decoration: none; color: #0f1111; font-family: inherit; }
.chip.sel { background: #141414; color: #fff; border-color: #141414; }
.empty { background: #fff; border-radius: 12px; padding: 24px; text-align: center; margin-top: 12px; display: flex; flex-direction: column; gap: 10px; align-items: center; }
.detail { padding-bottom: 0; }
.d-main { position: relative; background: #fff; border-radius: 12px; border: 1px solid #e3e6e6; padding: 8px; }
.d-main img { width: 100%; max-height: 420px; object-fit: contain; aspect-ratio: 1; display: block; border-radius: 8px; }
.d-share { position: absolute; top: 12px; inset-inline-end: 12px; width: 34px; height: 34px; border-radius: 50%; border: 1px solid #e3e6e6; background: rgba(255,255,255,.95); color: #565959; display: flex; align-items: center; justify-content: center; padding: 0; cursor: pointer; }
.caption.warn { color: #8a4b00; background: #fff8e1; border-radius: 8px; padding: 6px 10px; margin-top: 8px; }
.thumbs { display: flex; gap: 8px; overflow-x: auto; margin-top: 8px; padding-bottom: 4px; }
.th { flex: none; width: 56px; height: 56px; padding: 0; border: 2px solid #e3e6e6; border-radius: 8px; background: #fff; overflow: hidden; cursor: pointer; }
.th.sel { border-color: #e47911; } .th img { width: 100%; height: 100%; object-fit: cover; display: block; }
.d-title { font-size: 19px; line-height: 28px; margin: 14px 0 4px; }
.d-price { font-size: 26px; font-weight: 800; color: #b12704; }
.d-stock { font-weight: 700; font-size: 14px; margin: 2px 0 6px; } .d-stock.in { color: #067d62; } .d-stock.out { color: #b12704; }
.d-sec { margin-top: 14px; } .d-lbl { font-size: 14px; margin-bottom: 8px; }
.swatches { display: flex; flex-wrap: wrap; gap: 8px; }
.sw { border: 1px solid #d5d9d9; background: #fff; border-radius: 10px; padding: 9px 14px; font-size: 13px; cursor: pointer; font-family: inherit; min-height: 40px; }
.sw.sel { border: 2px solid #e47911; background: #fef8f2; font-weight: 700; }
.sw.off { color: #a2a6a6; text-decoration: line-through; background: #f7f7f7; }
.stepper { display: inline-flex; align-items: center; border: 1px solid #d5d9d9; border-radius: 10px; background: #fff; overflow: hidden; }
.stepper button { width: 44px; height: 42px; border: 0; background: #f0f2f2; font-size: 20px; cursor: pointer; }
.stepper span { min-width: 44px; text-align: center; font-weight: 700; }
.d-total { margin-top: 12px; font-size: 14px; } .d-total b { font-size: 16px; }
.d-cta { display: flex; flex-direction: column; gap: 8px; margin-top: 12px; } .d-cta .btn { width: 100%; min-height: 48px; font-size: 15px; }
.d-info { margin-top: 14px; background: #fff; border: 1px solid #e3e6e6; border-radius: 12px; padding: 4px 12px; }
.d-info div { display: flex; align-items: center; gap: 10px; padding: 10px 0; border-bottom: 1px solid #eee; color: #8a6414; font-size: 13px; } .d-info div:last-child { border: 0; } .d-info span { color: #0f1111; }
.d-desc { margin: 0; line-height: 24px; }
.stickybar { display: none; }
.on-detail .stickybar { display: flex; position: fixed; bottom: 58px; inset-inline: 0; max-width: 760px; margin: 0 auto; z-index: 35; background: #fff; border-top: 1px solid #d5d9d9; padding: 8px 12px; align-items: center; justify-content: space-between; gap: 12px; }
.stickybar div { display: flex; flex-direction: column; line-height: 1.2; } .stickybar small { color: #565959; font-size: 11px; } .stickybar b { font-size: 17px; color: #b12704; } .stickybar .btn { flex: 1; max-width: 220px; }
.on-detail .detail { padding-bottom: 0; }
body.on-detail { padding-bottom: 104px; }
.toast { position: fixed; bottom: 134px; inset-inline: 12px; max-width: 420px; margin: 0 auto; background: #0f1111; color: #fff; border-radius: 10px; padding: 12px 14px; display: flex; justify-content: space-between; gap: 12px; font-size: 13px; z-index: 60; opacity: 0; transform: translateY(10px); pointer-events: none; transition: .2s; }
.toast.show { opacity: 1; transform: none; pointer-events: auto; } .toast a { color: #e2b84b; font-weight: 700; text-decoration: none; white-space: nowrap; }
.line-ctl { display: flex; align-items: center; gap: 12px; } .linkbtn { background: none; border: 0; color: #8a6414; font-size: 13px; cursor: pointer; font-family: inherit; }
.st-line .st-stepper button { width: 34px; }
#app .group { margin-top: 12px; }

.d-stock.unk { color: #565959; font-weight: 600; }
.cmp-note{}
.cmpwrap{overflow-x:auto}
.cmp{width:100%;border-collapse:collapse;font-size:13px;min-width:0;table-layout:fixed}
.cmp th{width:56px;text-align:right;color:#666;font-weight:600;vertical-align:top;padding:8px 4px}
.cmp td{vertical-align:top;padding:8px 4px;border-top:1px solid #eee;word-break:break-word}
.cmp img{width:100%;aspect-ratio:1;object-fit:cover;border-radius:10px}
.pc .cmpbtn{display:block;margin:2px auto 8px;font-size:12px}
.steps{display:flex;gap:4px;list-style:none;padding:0;margin:10px 0;font-size:12px}
.steps li{flex:1;text-align:center;padding:8px 2px;border-radius:8px;background:#eee;color:#777}
.steps li.done{background:#16794a;color:#fff}

.demobar{background:#e2b84b;color:#141414;text-align:center;font-size:12px;font-weight:700;padding:6px 10px}
.hero{position:relative;overflow:hidden;display:flex;flex-direction:column;gap:10px}
.hero-img{width:100%;height:190px;object-fit:cover;border-radius:10px;display:block}
.hero h1{color:#e2b84b}

.cats{grid-template-columns:1fr 1fr}
.cats .cat{position:relative;min-height:112px;display:flex;flex-direction:column;justify-content:flex-end;color:#fff!important;background-size:cover;background-position:center;border-radius:12px;padding:12px;font-weight:800;font-size:16px;text-shadow:0 1px 3px rgba(0,0,0,.5)}
.cats .cat small{color:#f1e3b8;font-weight:600}
.cats .cat:last-child:nth-child(odd){grid-column:1/-1}
.pc-price,.d-price{color:#8a6414!important;font-size:14px!important;font-weight:700!important}
.d-price{font-size:18px!important}
.stickybar b,.d-total b{color:#8a6414!important;font-size:15px}
.pills{scrollbar-width:none}
.pills::-webkit-scrollbar{display:none}
