/* ManBhaata — premium red / black / white / gold UI. No inline styles anywhere (strict CSP). */
:root {
  --red: #c8102e; --red-dark: #9e0c24; --red-soft: #fdecef;
  --black: #111111; --ink: #1c1c1e; --ink-2: #4a4a50; --muted: #6b6b73;
  --gold: #c9a227; --gold-soft: #fbf5e1;
  --line: #e6e6ea; --bg: #f5f5f7; --white: #ffffff;
  --ok: #157f3b; --ok-soft: #e7f6ec; --warn: #9a6200; --warn-soft: #fff4dc; --bad: #b42318; --bad-soft: #fdecea; --info: #1d4ed8; --info-soft: #e8efff;
  --radius: 12px; --radius-sm: 8px; --shadow: 0 1px 2px rgba(0,0,0,.05), 0 6px 20px rgba(0,0,0,.06);
  --font: "Segoe UI", system-ui, -apple-system, Roboto, "Helvetica Neue", Arial, "Noto Sans", sans-serif;
  --sidebar: 236px;
}
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; font-family: var(--font); font-size: 15px; line-height: 1.55; color: var(--ink); background: var(--bg); overflow-x: hidden; }
img, svg { max-width: 100%; height: auto; display: block; }
a { color: var(--red); text-decoration: none; }
a:hover { text-decoration: underline; }
h1, h2, h3, h4, h5 { line-height: 1.25; margin: 0 0 .6em; color: var(--black); }
h1 { font-size: clamp(1.4rem, 2.6vw, 2rem); letter-spacing: -.01em; }
h2 { font-size: 1.3rem; } .h4 { font-size: 1.08rem; } .h5 { font-size: 1rem; }
p { margin: 0 0 .8em; }
hr { border: 0; border-top: 1px solid var(--line); margin: .6rem 0; }
:focus-visible { outline: 3px solid var(--gold); outline-offset: 2px; border-radius: 4px; }
.sr-only { position: absolute !important; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.skip { position: absolute; left: -999px; top: 0; background: var(--black); color: #fff; padding: .6rem 1rem; z-index: 100; }
.skip:focus { left: 8px; }
.muted { color: var(--muted); } .small { font-size: .86rem; } .d-block { display: block; } .text-bad { color: var(--bad); }
.ic { width: 20px; height: 20px; flex: none; }

/* ---------- top strip & header ---------- */
.strip { background: var(--black); color: #f3e7bf; font-size: .82rem; text-align: center; padding: .4rem 1rem; letter-spacing: .02em; }
.topbar { position: sticky; top: 0; z-index: 40; display: flex; align-items: center; gap: 14px; padding: 10px 18px; background: var(--white); border-bottom: 3px solid var(--red); box-shadow: 0 2px 10px rgba(0,0,0,.05); }
.brand { display: flex; align-items: center; gap: 10px; flex: none; }
.brand img { height: 42px; width: auto; }
.panel-tag { font-size: .72rem; font-weight: 700; text-transform: uppercase; letter-spacing: .08em; background: var(--gold-soft); color: #7a5d00; padding: 3px 8px; border-radius: 99px; }
.search { position: relative; flex: 1; display: flex; max-width: 620px; min-width: 0; }
.search input { flex: 1; min-width: 0; height: 44px; border: 1.5px solid var(--line); border-right: 0; border-radius: 99px 0 0 99px; padding: 0 16px; font: inherit; background: #fafafa; }
.search input:focus { border-color: var(--red); background: #fff; outline: none; box-shadow: 0 0 0 3px var(--red-soft); }
.search button { width: 52px; height: 44px; border: 0; border-radius: 0 99px 99px 0; background: var(--red); color: #fff; display: grid; place-items: center; cursor: pointer; }
.suggest { position: absolute; top: 48px; left: 0; right: 0; background: #fff; border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow); z-index: 60; max-height: 420px; overflow: auto; }
.suggest a { display: flex; align-items: center; gap: 10px; padding: 8px 12px; color: var(--ink); border-bottom: 1px solid var(--line); }
.suggest a:hover, .suggest a.hl { background: var(--red-soft); text-decoration: none; }
.suggest img { width: 40px; height: 40px; object-fit: cover; border-radius: 6px; }
.suggest small { color: var(--muted); margin-left: auto; white-space: nowrap; }
.suggest .none { padding: 10px 12px; color: var(--muted); }
.top-actions { display: flex; align-items: center; gap: 4px; margin-left: auto; }
.top-actions a, .who { display: flex; flex-direction: column; align-items: center; gap: 1px; color: var(--ink); font-size: .74rem; padding: 6px 8px; border-radius: 8px; position: relative; min-width: 48px; }
.top-actions a:hover { background: var(--red-soft); text-decoration: none; color: var(--red); }
.top-actions .wa { color: #128c4b; }
.who { align-items: flex-end; font-weight: 600; } .who small { color: var(--muted); font-weight: 400; }
.count { position: absolute; top: 0; right: 4px; min-width: 18px; height: 18px; border-radius: 99px; background: var(--red); color: #fff; font-size: .7rem; display: grid; place-items: center; padding: 0 5px; }
.icon-btn { width: 44px; height: 44px; border: 0; background: transparent; border-radius: 10px; display: inline-grid; place-items: center; cursor: pointer; color: var(--ink); }
.icon-btn:hover { background: var(--red-soft); color: var(--red); }

/* ---------- shell ---------- */
.shell { display: flex; align-items: flex-start; min-height: 70vh; }
.sidebar { position: sticky; top: 68px; width: var(--sidebar); flex: none; height: calc(100vh - 68px); overflow-y: auto; background: var(--white); border-right: 1px solid var(--line); padding: 14px 10px 30px; }
.sidebar nav a, .sidebar nav button { display: flex; align-items: center; gap: 10px; width: 100%; padding: 9px 12px; color: var(--ink-2); border-radius: 9px; font-size: .93rem; border: 0; background: none; font: inherit; cursor: pointer; text-align: left; }
.sidebar nav a:hover, .sidebar nav button:hover { background: var(--bg); color: var(--black); text-decoration: none; }
.sidebar nav a.active { background: var(--red); color: #fff; }
.sidebar nav a.active .ic { color: #fff; }
.sidebar .ic { color: var(--red); }
.nav-h { margin: 14px 12px 4px; font-size: .7rem; font-weight: 700; text-transform: uppercase; letter-spacing: .1em; color: var(--muted); }
.logout-form { margin-top: 10px; border-top: 1px solid var(--line); padding-top: 8px; }
.drawer-head { display: flex; justify-content: space-between; align-items: center; padding: 0 6px 10px; }
.drawer-backdrop { position: fixed; inset: 0; background: rgba(0,0,0,.45); z-index: 49; }
.content { flex: 1; min-width: 0; padding: 22px clamp(14px, 2.4vw, 32px) 48px; }
.only-mobile { display: none; }

/* ---------- buttons & forms ---------- */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 44px; padding: 0 18px; border-radius: 10px; border: 1.5px solid var(--red); background: var(--red); color: #fff; font: inherit; font-weight: 600; cursor: pointer; text-decoration: none; white-space: nowrap; }
.btn:hover { background: var(--red-dark); border-color: var(--red-dark); text-decoration: none; color: #fff; }
.btn:disabled, .btn.disabled { opacity: .5; cursor: not-allowed; pointer-events: none; }
.btn-ghost { background: #fff; color: var(--red); } .btn-ghost:hover { background: var(--red-soft); color: var(--red-dark); }
.btn-gold { background: var(--gold); border-color: var(--gold); color: #1a1400; } .btn-gold:hover { background: #b38f1e; border-color: #b38f1e; color: #000; }
.btn-ghost-light { background: transparent; border-color: #fff; color: #fff; } .btn-ghost-light:hover { background: rgba(255,255,255,.12); }
.btn-danger { background: var(--bad); border-color: var(--bad); }
.btn-wa { background: #128c4b; border-color: #128c4b; }
.btn-link { background: none; border: 0; color: var(--red); padding: 0 6px; min-height: 36px; font-weight: 600; }
.btn-link:hover { background: none; color: var(--red-dark); text-decoration: underline; }
.btn-sm { min-height: 36px; padding: 0 12px; font-size: .86rem; }
.btn-lg { min-height: 50px; font-size: 1.02rem; }
.btn-block { width: 100%; }
.btn-row { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; }
.form label, label.field { display: flex; flex-direction: column; gap: 5px; font-weight: 600; font-size: .9rem; margin-bottom: 12px; color: var(--ink); }
.form label small { font-weight: 400; color: var(--muted); }
input, select, textarea { font: inherit; color: var(--ink); width: 100%; min-height: 44px; border: 1.5px solid var(--line); border-radius: var(--radius-sm); padding: 8px 12px; background: #fff; }
textarea { min-height: 90px; resize: vertical; }
input:focus, select:focus, textarea:focus { border-color: var(--red); outline: none; box-shadow: 0 0 0 3px var(--red-soft); }
input[type=checkbox], input[type=radio] { width: 20px; height: 20px; min-height: 0; accent-color: var(--red); flex: none; }
input[type=file] { padding: 8px; background: var(--bg); }
input:disabled { background: var(--bg); color: var(--muted); }
label.check { flex-direction: row; align-items: flex-start; gap: 10px; font-weight: 500; }
.input-row { display: flex; gap: 8px; } .input-row input { flex: 1; min-width: 0; }
.row2 { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.grid2 { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 18px; align-items: start; }
.grid3 { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; }
.grid4 { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 12px; }
.span2 { grid-column: span 2; }
fieldset { border: 1.5px dashed var(--line); border-radius: var(--radius); padding: 12px 14px; margin: 0 0 14px; }
legend { font-weight: 700; padding: 0 6px; }
.otp-input { font-size: 1.6rem; letter-spacing: .5em; text-align: center; font-weight: 700; }

/* ---------- cards & feedback ---------- */
.card { background: var(--white); border: 1px solid var(--line); border-radius: var(--radius); padding: 18px; box-shadow: var(--shadow); margin-bottom: 18px; min-width: 0; }
.center-card { max-width: 560px; margin: 30px auto; text-align: center; }
.center-card .btn-row { justify-content: center; }
.flash { padding: 12px 14px; border-radius: var(--radius-sm); margin-bottom: 16px; border: 1px solid; font-weight: 500; }
.flash-success { background: var(--ok-soft); border-color: #b7e2c4; color: #0d5a29; }
.flash-error { background: var(--bad-soft); border-color: #f5c2bd; color: #8a1c12; }
.flash-info { background: var(--info-soft); border-color: #c7d6ff; color: #173c9e; }
.badge { display: inline-block; padding: 2px 9px; border-radius: 99px; font-size: .76rem; font-weight: 700; white-space: nowrap; }
.badge-ok { background: var(--ok-soft); color: var(--ok); } .badge-bad { background: var(--bad-soft); color: var(--bad); } .badge-warn { background: var(--warn-soft); color: var(--warn); } .badge-info { background: var(--info-soft); color: var(--info); }
.empty { text-align: center; padding: 40px 16px; background: #fff; border: 1px dashed var(--line); border-radius: var(--radius); }
.toast { position: fixed; left: 50%; bottom: 22px; transform: translateX(-50%); background: var(--black); color: #fff; padding: 12px 18px; border-radius: 10px; z-index: 90; box-shadow: var(--shadow); max-width: calc(100vw - 32px); }
.toast.err { background: var(--bad); }
.crumbs { font-size: .84rem; color: var(--muted); margin-bottom: 10px; }
.page-head { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: 10px; margin-bottom: 12px; }
.page-head h1 { margin: 0; }
.block { margin: 26px 0; }
.block-head { display: flex; justify-content: space-between; align-items: baseline; gap: 10px; margin-bottom: 12px; }
.block-head h2 { margin: 0; }
.eyebrow { display: inline-block; font-size: .74rem; font-weight: 700; letter-spacing: .14em; text-transform: uppercase; color: var(--gold); }
.eyebrow.dark { color: #8a6c0d; }

/* ---------- tables ---------- */
.table-wrap { overflow-x: auto; -webkit-overflow-scrolling: touch; }
.table { width: 100%; border-collapse: collapse; font-size: .9rem; }
.table th, .table td { padding: 10px 10px; border-bottom: 1px solid var(--line); text-align: left; vertical-align: top; }
.table th { font-size: .76rem; text-transform: uppercase; letter-spacing: .05em; color: var(--muted); background: #fafafa; }
.table td.num, .table th.num { text-align: right; white-space: nowrap; }
.table tfoot td { font-weight: 700; }
.table tr.grand td { font-size: 1.05rem; border-top: 2px solid var(--black); }
.table tr.row-low td { background: var(--bad-soft); }

/* ---------- hero / home ---------- */
.hero { position: relative; border-radius: 18px; overflow: hidden; background: linear-gradient(115deg, #0b0b0c 0%, #1d1d20 52%, #6d0a1b 100%); color: #fff; min-height: 300px; }
.slide { display: grid; grid-template-columns: 1.05fr 1fr; align-items: center; gap: 10px; min-height: 300px; }
.slide[hidden] { display: none; }
.slide-text { padding: 34px clamp(18px, 4vw, 48px); }
.slide-text h1 { color: #fff; font-size: clamp(1.7rem, 4vw, 2.8rem); margin: .3em 0; }
.slide-text p { color: #e3e3e6; max-width: 46ch; }
.slide img { width: 100%; height: 100%; max-height: 360px; object-fit: cover; }
.slider-dots { position: absolute; left: clamp(18px, 4vw, 48px); bottom: 16px; display: flex; gap: 8px; }
.slider-dots button { width: 28px; height: 6px; border-radius: 99px; border: 0; background: rgba(255,255,255,.35); cursor: pointer; padding: 0; }
.slider-dots button[aria-selected=true] { background: var(--gold); }
.benefits { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 12px; margin: 18px 0; }
.benefits div { display: grid; grid-template-columns: auto 1fr; column-gap: 10px; align-items: center; background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: 14px; }
.benefits .ic { grid-row: span 2; width: 30px; height: 30px; color: var(--red); }
.benefits span { font-size: .82rem; color: var(--muted); }
.grid-cats { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 12px; }
.cat-card { display: block; background: #fff; border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; color: var(--ink); text-align: center; font-weight: 700; transition: transform .15s; }
.cat-card:hover { transform: translateY(-2px); text-decoration: none; border-color: var(--red); }
.cat-card img { width: 100%; aspect-ratio: 4 / 3; object-fit: cover; background: var(--bg); }
.cat-card span { display: block; padding: 10px 8px; font-size: .9rem; }
.offers-band { background: var(--gold-soft); border: 1px solid #efe1ad; border-radius: 16px; padding: 18px; }
.coupon-row { display: flex; flex-wrap: wrap; gap: 12px; margin-bottom: 16px; }
.coupon { display: flex; flex-direction: column; background: #fff; border: 2px dashed var(--gold); border-radius: 12px; padding: 10px 14px; min-width: 200px; }
.coupon b { color: var(--red); font-size: 1.15rem; letter-spacing: .06em; }
.winter-band { background: linear-gradient(180deg, #eef3f8, transparent); border-radius: 16px; padding: 18px; }
.biz-band { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: 16px; background: var(--black); color: #fff; border-radius: 16px; padding: 24px; }
.biz-band h2 { color: #fff; } .biz-band p { color: #cfcfd4; margin: 0; }
.biz-actions { display: flex; gap: 10px; flex-wrap: wrap; }

/* ---------- product cards ---------- */
.grid-products { display: grid; grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); gap: 14px; }
.card-product { background: #fff; border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; display: flex; flex-direction: column; transition: box-shadow .15s, transform .15s; }
.card-product:hover { box-shadow: var(--shadow); transform: translateY(-2px); }
.thumb { position: relative; display: block; background: var(--bg); }
.thumb img { width: 100%; aspect-ratio: 1 / 1; object-fit: cover; }
.ribbon { position: absolute; top: 10px; left: 10px; background: var(--red); color: #fff; font-size: .72rem; font-weight: 800; padding: 3px 8px; border-radius: 6px; }
.ribbon-new { left: auto; right: 10px; background: var(--gold); color: #1a1400; }
.illus { position: absolute; bottom: 8px; left: 8px; background: rgba(17,17,17,.75); color: #fff; font-size: .68rem; padding: 2px 7px; border-radius: 5px; }
.cp-body { padding: 12px; display: flex; flex-direction: column; gap: 4px; flex: 1; }
.cp-cat { font-size: .74rem; color: var(--muted); text-transform: uppercase; letter-spacing: .05em; }
.cp-body h3 { font-size: .97rem; margin: 0; font-weight: 600; }
.cp-body h3 a { color: var(--ink); }
.price b { font-size: 1.08rem; color: var(--black); } .price del { color: var(--muted); font-size: .86rem; }
.cp-actions { display: flex; gap: 6px; margin-top: auto; padding-top: 8px; align-items: center; }
.cp-actions form:first-child, .cp-actions > a, .cp-actions > button { flex: 1; }
.wish.on .ic, .wish[aria-pressed=true] .ic { fill: var(--red); color: var(--red); }
.stars { color: var(--gold); letter-spacing: 1px; } .stars .dim { color: #d9d9de; }
.cp-rating { font-size: .82rem; }

/* ---------- shop ---------- */
.chips { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 14px; }
.chip { padding: 7px 14px; border: 1.5px solid var(--line); border-radius: 99px; background: #fff; color: var(--ink); font-size: .88rem; font-weight: 600; }
.chip.on, .chip:hover { border-color: var(--red); color: var(--red); text-decoration: none; }
.shop-layout { display: grid; grid-template-columns: 230px minmax(0, 1fr); gap: 18px; align-items: start; }
.filters { position: sticky; top: 84px; }
.pager { display: flex; flex-wrap: wrap; gap: 6px; justify-content: center; margin: 20px 0; }
.pager a, .pager span { min-width: 40px; height: 40px; display: grid; place-items: center; padding: 0 10px; border-radius: 9px; border: 1px solid var(--line); background: #fff; color: var(--ink); }
.pager span[aria-current] { background: var(--red); color: #fff; border-color: var(--red); }
.is-loading { opacity: .5; pointer-events: none; }

/* ---------- product page ---------- */
.pdp { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 26px; background: #fff; border: 1px solid var(--line); border-radius: 16px; padding: 18px; }
.pdp-main { position: relative; border-radius: 12px; overflow: hidden; background: var(--bg); }
.pdp-main img { width: 100%; aspect-ratio: 1 / 1; object-fit: cover; }
.thumbs { display: flex; gap: 8px; margin-top: 10px; overflow-x: auto; }
.thumbs button { border: 2px solid var(--line); border-radius: 8px; padding: 0; background: none; cursor: pointer; flex: none; }
.thumbs button:hover, .thumbs button:focus-visible { border-color: var(--red); }
.thumbs img { width: 64px; height: 64px; object-fit: cover; border-radius: 6px; }
.pdp-price b { font-size: 1.7rem; color: var(--black); }
.pdp-price del { color: var(--muted); }
.variants { display: flex; flex-wrap: wrap; gap: 8px; border: 0; padding: 0; margin: 10px 0; }
.variants legend { padding: 0; margin-bottom: 6px; }
.variant { position: relative; }
.variant input { position: absolute; opacity: 0; }
.variant span { display: inline-block; min-width: 52px; padding: 9px 14px; border: 1.5px solid var(--line); border-radius: 9px; text-align: center; font-weight: 600; cursor: pointer; background: #fff; }
.variant input:checked + span { border-color: var(--red); background: var(--red-soft); color: var(--red-dark); }
.variant input:focus-visible + span { outline: 3px solid var(--gold); }
.variant.oos span { text-decoration: line-through; color: var(--muted); cursor: not-allowed; }
.stock-line { color: var(--ok); font-weight: 600; }
.buy-row { display: flex; gap: 10px; align-items: flex-end; flex-wrap: wrap; }
.buy-row .btn { flex: 1; min-width: 180px; }
.qty { display: flex; flex-direction: column; font-weight: 600; font-size: .86rem; gap: 4px; }
.qty input { width: 90px; }
.assure { list-style: none; padding: 0; margin: 14px 0; display: grid; gap: 8px; font-size: .9rem; }
.assure li { display: flex; gap: 8px; align-items: center; } .assure .ic { color: var(--red); }
.inline { display: inline-block; margin-top: 10px; }
.lead { font-size: 1.02rem; color: var(--ink-2); }
.pdp-tabs { display: grid; gap: 16px; margin-top: 18px; }
.pdp-tabs section { background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: 18px; }
.spec th { width: 34%; color: var(--ink-2); font-weight: 600; text-align: left; padding: 6px 8px; border-bottom: 1px solid var(--line); }
.spec td { padding: 6px 8px; border-bottom: 1px solid var(--line); }
.review { border-bottom: 1px solid var(--line); padding: 10px 0; }

/* ---------- cart / checkout ---------- */
.cart-layout, .checkout-layout { display: grid; grid-template-columns: minmax(0, 1fr) 340px; gap: 18px; align-items: start; }
.summary { position: sticky; top: 84px; }
.line-prod { display: flex; gap: 10px; align-items: center; }
.line-prod img { width: 64px; height: 64px; object-fit: cover; border-radius: 8px; background: var(--bg); }
.qty-form { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; }
.qty-form input { width: 76px; }
.totals { display: grid; grid-template-columns: 1fr auto; gap: 6px 12px; margin: 14px 0; }
.totals dt { color: var(--ink-2); } .totals dd { margin: 0; text-align: right; font-weight: 600; }
.totals .grand { font-size: 1.1rem; font-weight: 800; color: var(--black); border-top: 1px solid var(--line); padding-top: 8px; }
.mini-lines { list-style: none; padding: 0; margin: 0; }
.mini-lines li { display: flex; justify-content: space-between; gap: 10px; padding: 7px 0; border-bottom: 1px solid var(--line); font-size: .9rem; }
.addr-list { display: grid; gap: 8px; margin-bottom: 12px; }
.addr { flex-direction: row !important; align-items: flex-start; gap: 10px; border: 1.5px solid var(--line); border-radius: 10px; padding: 12px; font-weight: 400 !important; cursor: pointer; }
.addr:has(input:checked) { border-color: var(--red); background: var(--red-soft); }
.new-address[hidden] { display: none; }
.cod-box { display: flex; gap: 12px; background: var(--gold-soft); border: 1px solid #efe1ad; border-radius: 10px; padding: 12px; margin-bottom: 12px; }
.cod-box .ic { width: 32px; height: 32px; color: #8a6c0d; }
.success-mark { width: 70px; height: 70px; margin: 0 auto 10px; border-radius: 50%; background: var(--ok-soft); color: var(--ok); display: grid; place-items: center; }
.success-mark .ic { width: 38px; height: 38px; }

/* ---------- order tracking ---------- */
.stepper { list-style: none; padding: 0; margin: 16px 0; display: grid; grid-template-columns: repeat(6, 1fr); gap: 4px; counter-reset: s; }
.stepper li { position: relative; text-align: center; font-size: .76rem; color: var(--muted); padding-top: 30px; }
.stepper li::before { counter-increment: s; content: counter(s); position: absolute; top: 0; left: 50%; transform: translateX(-50%); width: 24px; height: 24px; border-radius: 50%; background: var(--line); color: var(--ink-2); display: grid; place-items: center; font-weight: 700; z-index: 1; }
.stepper li::after { content: ""; position: absolute; top: 11px; left: -50%; width: 100%; height: 3px; background: var(--line); }
.stepper li:first-child::after { display: none; }
.stepper li.done { color: var(--ink); font-weight: 600; }
.stepper li.done::before { background: var(--red); color: #fff; content: "✓"; }
.stepper li.done::after { background: var(--red); }
.timeline { list-style: none; padding: 0 0 0 16px; border-left: 2px solid var(--line); margin: 0; }
.timeline li { position: relative; padding: 0 0 12px 12px; display: flex; flex-direction: column; }
.timeline li::before { content: ""; position: absolute; left: -23px; top: 5px; width: 12px; height: 12px; border-radius: 50%; background: var(--red); border: 2px solid #fff; }
.timeline time, .timeline span { font-size: .82rem; color: var(--muted); }

/* ---------- auth ---------- */
.auth-wrap { display: grid; place-items: center; padding: 20px 0; }
.auth-card { width: 100%; max-width: 440px; }
.auth-links { text-align: center; font-size: .88rem; margin-top: 12px; }
.resend-form { text-align: center; }

/* ---------- account ---------- */
.tabs { display: flex; gap: 6px; overflow-x: auto; margin-bottom: 16px; padding-bottom: 4px; }
.tabs a { padding: 8px 14px; border-radius: 99px; background: #fff; border: 1px solid var(--line); color: var(--ink-2); white-space: nowrap; font-weight: 600; font-size: .88rem; }
.tabs a.on { background: var(--black); color: #fff; border-color: var(--black); }
.stats { display: grid; grid-template-columns: repeat(auto-fill, minmax(190px, 1fr)); gap: 12px; margin-bottom: 18px; }
.stat { background: #fff; border: 1px solid var(--line); border-left: 4px solid var(--red); border-radius: var(--radius); padding: 14px; color: var(--ink); display: flex; flex-direction: column; gap: 4px; min-width: 0; }
.stat:hover { text-decoration: none; box-shadow: var(--shadow); }
.stat small { color: var(--muted); font-size: .8rem; } .stat b { font-size: 1.35rem; color: var(--black); overflow-wrap: anywhere; }
.stat.gold { border-left-color: var(--gold); } .stat.ok { border-left-color: var(--ok); } .stat.bad { border-left-color: var(--bad); }
.addr-card p { margin: 0 0 6px; }
.ret-row { border-bottom: 1px solid var(--line); padding: 8px 0; }
.link-card { display: flex; flex-direction: column; gap: 6px; color: var(--ink); }
.link-card .ic { width: 30px; height: 30px; color: var(--red); }
.link-card:hover { text-decoration: none; border-color: var(--red); }
.prose { max-width: 75ch; } .prose ul { padding-left: 1.2rem; }
details { background: #fff; border: 1px solid var(--line); border-radius: 10px; padding: 12px 14px; margin-bottom: 10px; }
summary { font-weight: 700; cursor: pointer; }
.err-code { font-size: 3.2rem; font-weight: 800; color: var(--red); margin: 0; }

/* ---------- footer ---------- */
.footer { background: var(--black); color: #fff; padding: 34px clamp(16px, 4vw, 48px) 20px; margin-top: 30px; }
.footer-grid { display: grid; grid-template-columns: 1.4fr 1fr 1fr 1.2fr; gap: 24px; }
.footer h2 { color: var(--gold); font-size: .9rem; text-transform: uppercase; letter-spacing: .1em; }
.footer a { display: block; color: #e5e5e8; padding: 3px 0; font-size: .9rem; }
.footer p { color: #cfcfd4; font-size: .9rem; }
.muted-light { color: #bdbdc3 !important; }
.copyright { border-top: 1px solid #2a2a2d; margin-top: 22px; padding-top: 14px; font-size: .8rem; color: #9d9da3 !important; }

/* ---------- panel (admin/team) ---------- */
.panel-body { background: #f2f2f5; }
.panel-top { border-bottom-color: var(--black); }
.panel-content h1 { font-size: 1.5rem; }
.toolbar { display: flex; flex-wrap: wrap; gap: 8px; align-items: flex-end; margin-bottom: 14px; }
.toolbar label { margin: 0; font-size: .82rem; font-weight: 600; display: flex; flex-direction: column; gap: 4px; min-width: 120px; flex: 1 1 140px; max-width: 240px; }
.toolbar .btn { flex: none; }
.chart { width: 100%; height: auto; }
.chart .bar { fill: var(--red); } .chart .bar:hover { fill: var(--gold); }
.chart .axis { stroke: var(--line); stroke-width: 1; }
.chart .lbl { font-size: 10px; fill: var(--muted); text-anchor: middle; } .chart .lbl-max { text-anchor: start; }
progress { width: 100%; height: 10px; border-radius: 99px; overflow: hidden; appearance: none; border: 0; background: var(--line); }
progress::-webkit-progress-bar { background: var(--line); border-radius: 99px; }
progress::-webkit-progress-value { background: var(--red); border-radius: 99px; }
progress::-moz-progress-bar { background: var(--red); border-radius: 99px; }
.tree, .tree ul { list-style: none; margin: 0; padding-left: 18px; }
.tree { padding-left: 0; }
.tree li { position: relative; padding: 4px 0 4px 14px; border-left: 2px solid var(--line); }
.tree li::before { content: ""; position: absolute; left: 0; top: 18px; width: 12px; border-top: 2px solid var(--line); }
.node { display: inline-flex; flex-wrap: wrap; gap: 6px; align-items: center; background: #fff; border: 1px solid var(--line); border-radius: 9px; padding: 6px 10px; font-size: .88rem; }
.node small { color: var(--muted); }
.kv { display: grid; grid-template-columns: max-content 1fr; gap: 6px 14px; margin: 0; }
.kv dt { color: var(--muted); font-weight: 600; } .kv dd { margin: 0; overflow-wrap: anywhere; }
.task { border: 1px solid var(--line); border-radius: 10px; padding: 12px; margin-bottom: 10px; background: #fff; }
.task-notes { list-style: none; padding: 0; margin: 8px 0; font-size: .84rem; border-left: 2px solid var(--line); padding-left: 10px; }
.variant-table input { min-width: 90px; }
.report-notes { font-size: .84rem; color: var(--ink-2); padding-left: 1.1rem; }

/* ---------- print ---------- */
.print-body { background: #fff; }
.print-actions { padding: 12px 18px; display: flex; gap: 8px; }
.print-sheet { max-width: 900px; margin: 0 auto; padding: 16px 20px; }
.print-head { display: flex; justify-content: space-between; align-items: flex-start; gap: 16px; border-bottom: 3px solid var(--red); padding-bottom: 10px; margin-bottom: 14px; font-size: .86rem; text-align: right; }
@media print {
  .no-print, .print-actions { display: none !important; }
  body { background: #fff; font-size: 12px; }
  .print-sheet { padding: 0; max-width: none; }
  .table th { background: #eee !important; -webkit-print-color-adjust: exact; print-color-adjust: exact; }
  a { color: #000; }
}

/* ---------- responsive ---------- */
@media (max-width: 1100px) {
  .hide-md { display: none !important; }
  .footer-grid { grid-template-columns: 1fr 1fr; }
  .grid4 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 960px) {
  .only-mobile { display: inline-grid; }
  .drawer-head.only-mobile { display: flex; }
  .sidebar { position: fixed; top: 0; left: 0; bottom: 0; height: 100vh; z-index: 50; transform: translateX(-105%); transition: transform .2s ease; width: min(300px, 86vw); box-shadow: 4px 0 24px rgba(0,0,0,.25); }
  .sidebar.open { transform: none; }
  .shop-layout, .cart-layout, .checkout-layout, .pdp { grid-template-columns: minmax(0, 1fr); }
  .filters, .summary { position: static; }
  .benefits { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .slide { grid-template-columns: 1fr; }
  .slide img { max-height: 200px; order: -1; }
  .grid3 { grid-template-columns: minmax(0, 1fr); }
}
@media (max-width: 760px) {
  .topbar { flex-wrap: wrap; padding: 8px 10px; gap: 6px; }
  .brand img { height: 34px; }
  .search { order: 5; flex-basis: 100%; max-width: none; }
  .top-actions a, .who { min-width: 40px; padding: 4px; }
  .top-actions span { display: none; }
  .hide-sm { display: none !important; }
  .grid2, .row2 { grid-template-columns: minmax(0, 1fr); }
  .span2 { grid-column: auto; }
  .grid-products { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
  .cp-body { padding: 9px; }
  .cp-body h3 { font-size: .9rem; }
  .content { padding: 14px 12px 40px; }
  .card { padding: 14px; }
  .footer-grid { grid-template-columns: minmax(0, 1fr); }
  .stepper { grid-template-columns: repeat(3, 1fr); row-gap: 14px; }
  .stepper li:nth-child(4)::after { display: none; }
  /* responsive tables: stack rows into cards */
  .cart-table thead, .table-stack thead { display: none; }
  .cart-table tr, .table-stack tr { display: block; border: 1px solid var(--line); border-radius: 10px; margin-bottom: 10px; padding: 6px; }
  .cart-table td, .table-stack td { display: flex; justify-content: space-between; gap: 10px; border: 0; padding: 6px; }
  .cart-table td::before, .table-stack td::before { content: attr(data-label); font-weight: 700; color: var(--muted); font-size: .78rem; text-transform: uppercase; }
  .cart-table td:first-child::before { display: none; }
  .stats { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .toolbar label { max-width: none; flex: 1 1 45%; }
}
@media (max-width: 340px) {
  .grid-products { grid-template-columns: minmax(0, 1fr); }
  .benefits { grid-template-columns: minmax(0, 1fr); }
  .stats { grid-template-columns: minmax(0, 1fr); }
  .btn { white-space: normal; text-align: center; }
}
@media (prefers-reduced-motion: reduce) { *, *::before, *::after { transition: none !important; animation: none !important; } }

pre { background: var(--bg); border: 1px solid var(--line); border-radius: 8px; padding: 10px; overflow-x: auto; white-space: pre-wrap; word-break: break-all; }
.tabs span { padding: 8px 14px; border-radius: 99px; background: #fff; border: 1px solid var(--line); color: var(--ink-2); white-space: nowrap; font-weight: 600; font-size: .82rem; }
.tabs span.on { background: var(--black); color: #fff; border-color: var(--black); }
.install-card { max-width: 620px; }
