/* Loomloop — demo stylesheet */
:root {
  --oat: #f6f1e7;
  --paper: #fffdf8;
  --ink: #1f1d2b;
  --ink-2: #57536a;
  --ink-3: #8a8698;
  --line: #e4dccb;
  --line-2: #d6ccb6;
  --made: #2f3a8f;
  --made-soft: #e6e8f6;
  --loop: #13706a;
  --loop-soft: #dcefeb;
  --thread: #e0a526;
  --thread-soft: #fbefd2;
  --danger: #b4372f;
  --ok: #1f7a43;
  --radius: 14px;
  --radius-sm: 9px;
  --shadow: 0 1px 2px rgba(31, 29, 43, .06), 0 6px 22px rgba(31, 29, 43, .07);
  --display: 'Fraunces', Georgia, 'Times New Roman', serif;
  --body: 'Manrope', system-ui, -apple-system, 'Segoe UI', sans-serif;
  color-scheme: light;
}
* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; background: var(--oat); color: var(--ink); font: 15px/1.55 var(--body); overflow-x: hidden; }
body.locked { overflow: hidden; }
img, svg { max-width: 100%; }
a { color: inherit; }
h1, h2, h3, h4 { font-family: var(--display); font-weight: 600; letter-spacing: -.01em; line-height: 1.15; margin: 0 0 .4em; }
h1 { font-size: clamp(30px, 5vw, 50px); }
h2 { font-size: clamp(22px, 3vw, 30px); }
h3 { font-size: 19px; }
p { margin: 0 0 .8em; }
.wrap { max-width: 1240px; margin: 0 auto; padding: 0 20px; }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.muted { color: var(--ink-3); }
.ok { color: var(--ok); }
.ic { display: block; flex: none; }
:focus-visible { outline: 3px solid var(--thread); outline-offset: 2px; }

/* buttons */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; border: 0; border-radius: 999px; padding: 11px 20px; background: var(--ink); color: #fff; font: 700 14px/1.2 var(--body); text-decoration: none; cursor: pointer; transition: transform .12s, background .15s; }
.btn:hover { background: #33304a; }
.btn:active { transform: translateY(1px); }
.btn-made { background: var(--made); } .btn-made:hover { background: #262f78; }
.btn-loop { background: var(--loop); } .btn-loop:hover { background: #0e5c57; }
.btn-ghost { background: transparent; color: var(--ink); box-shadow: inset 0 0 0 1.5px var(--ink); }
.btn-ghost:hover { background: rgba(31, 29, 43, .06); }
.btn-ghost.on { background: var(--ink); color: #fff; }
.btn-sm { padding: 7px 14px; font-size: 13px; }
.btn-block { width: 100%; }
.btn[disabled] { opacity: .45; cursor: not-allowed; }
.link-btn { background: none; border: 0; padding: 0; color: var(--ink-2); font: 600 13px var(--body); text-decoration: underline; cursor: pointer; }
.icon-btn { display: inline-grid; place-items: center; width: 40px; height: 40px; border-radius: 50%; border: 0; background: transparent; color: var(--ink); cursor: pointer; text-decoration: none; position: relative; }
.icon-btn:hover { background: rgba(31, 29, 43, .07); }

/* header */
.preview-bar { background: var(--ink); color: #f2ecdf; font-size: 12px; text-align: center; padding: 4px 12px; letter-spacing: .02em; }
.site-header { background: var(--paper); border-bottom: 1px solid var(--line); position: sticky; top: 0; z-index: 40; }
.hdr { display: flex; align-items: center; gap: 16px; height: 66px; }
.brand { display: inline-flex; align-items: center; gap: 8px; text-decoration: none; font-family: var(--display); font-weight: 700; font-size: 25px; letter-spacing: -.02em; color: var(--ink); }
.hdr-search { flex: 1; display: flex; max-width: 640px; margin: 0 auto; background: var(--oat); border: 1.5px solid var(--line-2); border-radius: 999px; overflow: hidden; }
.hdr-search:focus-within { border-color: var(--ink); }
.hdr-search input { flex: 1; min-width: 0; border: 0; background: transparent; padding: 10px 16px; font: 15px var(--body); color: var(--ink); outline: none; }
.hdr-search button { border: 0; background: var(--ink); color: #fff; width: 44px; margin: 3px; border-radius: 999px; display: grid; place-items: center; cursor: pointer; }
.hdr-icons { display: flex; gap: 2px; }
.cart-count { position: absolute; top: 2px; right: 0; background: var(--thread); color: var(--ink); font-size: 11px; font-weight: 800; min-width: 18px; height: 18px; border-radius: 9px; display: grid; place-items: center; padding: 0 4px; }
.cart-count[hidden] { display: none; }
.nav-toggle { display: none; }
.main-nav { border-top: 1px solid var(--line); }
.main-nav .wrap { display: flex; gap: 4px; overflow-x: auto; scrollbar-width: none; }
.main-nav a { padding: 10px 12px; font-weight: 600; font-size: 14px; text-decoration: none; color: var(--ink-2); border-bottom: 2.5px solid transparent; white-space: nowrap; }
.main-nav a:hover { color: var(--ink); }
.main-nav a.active { color: var(--ink); border-color: var(--thread); }
.main-nav .nav-made { color: var(--made); } .main-nav .nav-loop { color: var(--loop); }
.main-nav .nav-made.active { border-color: var(--made); } .main-nav .nav-loop.active { border-color: var(--loop); }

/* footer */
.site-footer { background: #1f1d2b; color: #d9d4c8; margin-top: 70px; padding: 48px 0 24px; }
.site-footer .brand { color: #fff; }
.foot { display: grid; grid-template-columns: 2fr 1fr 1fr 1fr; gap: 28px; }
.foot h5 { font: 700 12px var(--body); text-transform: uppercase; letter-spacing: .08em; color: #fff; margin: 4px 0 10px; }
.foot a:not(.brand) { display: block; color: #d9d4c8; text-decoration: none; font-size: 14px; padding: 3px 0; }
.foot a:hover { color: #fff; }
.foot-brand p { margin-top: 10px; max-width: 280px; font-size: 14px; }
.foot-note { margin-top: 36px; padding-top: 18px; border-top: 1px solid #3a3750; font-size: 12px; color: #a39fb2; }

/* sections */
main { display: block; min-height: 50vh; }
.section { margin: 44px 0; }
.section-hd { display: flex; align-items: end; justify-content: space-between; gap: 16px; margin-bottom: 16px; }
.section-hd h2 { margin: 0; }
.section-hd a { font-weight: 700; font-size: 14px; }
.eyebrow { font: 800 11.5px var(--body); letter-spacing: .12em; text-transform: uppercase; color: var(--ink-3); margin-bottom: 6px; }
.panel { background: var(--paper); border: 1px solid var(--line); border-radius: var(--radius); padding: 22px; }
.crumbs { font-size: 13px; color: var(--ink-3); margin: 18px 0; }
.crumbs a { color: var(--ink-2); }

/* hero */
.hero { padding: 40px 0 10px; }
.hero-grid { display: grid; grid-template-columns: 1.15fr 1fr; gap: 36px; align-items: center; }
.hero h1 em { font-style: italic; color: var(--made); }
.hero h1 em.l { color: var(--loop); }
.hero p.lead { font-size: 17px; color: var(--ink-2); max-width: 520px; }
.hero-search { display: flex; background: var(--paper); border: 2px solid var(--ink); border-radius: 999px; padding: 4px; margin: 20px 0 14px; max-width: 560px; }
.hero-search input { flex: 1; min-width: 0; border: 0; background: none; padding: 10px 16px; font: 16px var(--body); outline: none; }
.side-switch { display: inline-flex; background: var(--paper); border: 1px solid var(--line-2); border-radius: 999px; padding: 4px; gap: 2px; }
.side-switch button { border: 0; background: transparent; padding: 8px 16px; border-radius: 999px; font: 700 14px var(--body); cursor: pointer; color: var(--ink-2); }
.side-switch button.on { background: var(--ink); color: #fff; }
.side-switch button.on[data-side="made"] { background: var(--made); }
.side-switch button.on[data-side="loop"] { background: var(--loop); }
.hero-art { display: grid; grid-template-columns: 1fr 1fr; grid-template-rows: 1fr 1fr; gap: 12px; aspect-ratio: 1.1; }
.hero-art a { border-radius: var(--radius); overflow: hidden; display: block; position: relative; box-shadow: var(--shadow); }
.hero-art a:first-child { grid-row: span 2; }
.hero-art .art { width: 100%; height: 100%; display: block; }
.hero-art span { position: absolute; left: 10px; bottom: 10px; background: rgba(255, 253, 248, .92); padding: 4px 10px; border-radius: 999px; font-size: 12px; font-weight: 700; }

.two-sides { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.side-card { border-radius: var(--radius); padding: 26px; color: #fff; position: relative; overflow: hidden; text-decoration: none; display: block; }
.side-card.made { background: var(--made); }
.side-card.loop { background: var(--loop); }
.side-card h3 { font-size: 26px; }
.side-card ul { margin: 10px 0 18px; padding-left: 18px; opacity: .92; }
.side-card .btn { background: #fff; color: var(--ink); }
.side-card svg.deco { position: absolute; right: -20px; bottom: -30px; width: 160px; opacity: .18; }

/* rails */
.rail { display: flex; gap: 14px; overflow-x: auto; scroll-snap-type: x mandatory; padding-bottom: 8px; scrollbar-width: thin; }
.rail > * { scroll-snap-align: start; flex: none; }
.cat-rail a { width: 112px; text-align: center; text-decoration: none; font-weight: 700; font-size: 13px; }
.cat-rail .ci { width: 112px; height: 112px; border-radius: 50%; overflow: hidden; display: block; margin-bottom: 8px; border: 3px solid var(--paper); box-shadow: var(--shadow); transition: transform .15s; }
.cat-rail a:hover .ci { transform: translateY(-3px); }
.cat-rail .ci .art { width: 100%; height: 100%; display: block; }
.card-rail .card { width: 210px; }

/* grid + card */
.grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(190px, 1fr)); gap: 18px; }
.card { position: relative; background: var(--paper); border-radius: var(--radius); overflow: hidden; border: 1px solid var(--line); transition: box-shadow .15s, transform .15s; display: flex; flex-direction: column; }
.card:hover { box-shadow: var(--shadow); transform: translateY(-2px); }
.card-img { display: block; aspect-ratio: 1; position: relative; overflow: hidden; }
.card-img .art { width: 100%; height: 100%; display: block; }
.side-badge { position: absolute; left: 8px; top: 8px; font: 800 10.5px var(--body); text-transform: uppercase; letter-spacing: .08em; padding: 3px 8px; border-radius: 999px; color: #fff; }
.side-made .side-badge { background: var(--made); }
.side-loop .side-badge { background: var(--loop); }
.nwt { position: absolute; left: 8px; bottom: 8px; background: var(--thread); font: 800 10.5px var(--body); padding: 3px 7px; border-radius: 5px; }
.fav { position: absolute; right: 8px; top: 8px; width: 36px; height: 36px; border-radius: 50%; border: 0; background: rgba(255, 253, 248, .94); display: grid; place-items: center; cursor: pointer; color: var(--ink); box-shadow: 0 1px 4px rgba(0, 0, 0, .12); }
.fav.on { color: #c4334f; }
.fav.on svg { fill: currentColor; }
.card-body { padding: 10px 12px 12px; text-decoration: none; display: block; flex: 1; }
.card-body h4 { font: 600 14px/1.35 var(--body); margin: 0 0 4px; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.price { margin: 0 0 3px; font-size: 15px; }
.price s { color: var(--ink-3); font-size: 13px; }
.price .free { font-style: normal; color: var(--ok); font-size: 12px; font-weight: 700; }
.meta { margin: 0; font-size: 12.5px; color: var(--ink-3); display: flex; flex-wrap: wrap; gap: 4px 10px; align-items: center; }
.chip-sm { background: var(--thread-soft); color: #7a5a10; border-radius: 4px; padding: 0 6px; font-weight: 700; font-size: 11px; }
.pick { display: flex; align-items: center; gap: 8px; padding: 8px 12px; border-top: 1px solid var(--line); font-size: 13px; font-weight: 700; cursor: pointer; background: var(--loop-soft); }
.pick input { width: 18px; height: 18px; accent-color: var(--loop); }

/* makers */
.makers { display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px; }
.maker { background: var(--paper); border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; text-decoration: none; display: block; }
.maker .mk-art { display: grid; grid-template-columns: 2fr 1fr; grid-template-rows: 1fr 1fr; gap: 3px; aspect-ratio: 1.5; }
.maker .mk-art > :first-child { grid-row: span 2; }
.maker .mk-art .art { width: 100%; height: 100%; display: block; }
.maker .mk-info { padding: 12px 14px; display: flex; gap: 10px; align-items: center; }
.maker .mk-info b { display: block; font-size: 15px; }
.maker .mk-info small { color: var(--ink-3); }
.avatar { display: inline-grid; place-items: center; border-radius: 50%; background: var(--av); color: #fff; font-weight: 800; flex: none; font-family: var(--body); }

/* drops feed */
.drops { display: grid; grid-template-columns: 1fr 1fr; gap: 24px; align-items: start; }
.drop-list { list-style: none; margin: 0; padding: 0; display: grid; gap: 10px; }
.drop { display: flex; gap: 12px; align-items: center; background: var(--paper); border: 1px solid var(--line); border-radius: var(--radius-sm); padding: 10px; animation: dropIn .45s ease; text-decoration: none; }
.drop .art { width: 58px; height: 58px; border-radius: 8px; flex: none; display: block; }
.drop .d-info { flex: 1; min-width: 0; }
.drop .d-info b { display: block; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; font-size: 14px; }
.drop .d-info small { color: var(--ink-3); }
.drop .d-price { font-weight: 800; }
.live-dot { display: inline-block; width: 9px; height: 9px; border-radius: 50%; background: #d63b3b; margin-right: 6px; animation: pulse 1.6s infinite; vertical-align: middle; }
@keyframes dropIn { from { opacity: 0; transform: translateY(-8px); } }
@keyframes pulse { 50% { opacity: .3; } }

/* search page */
.search-layout { display: grid; grid-template-columns: 250px 1fr; gap: 28px; align-items: start; }
.filters { position: sticky; top: 120px; background: var(--paper); border: 1px solid var(--line); border-radius: var(--radius); padding: 16px; max-height: calc(100vh - 140px); overflow: auto; }
.filters fieldset { border: 0; border-bottom: 1px solid var(--line); margin: 0; padding: 12px 0; }
.filters fieldset:last-of-type { border-bottom: 0; }
.filters legend { font-weight: 800; font-size: 13px; padding: 0; margin-bottom: 8px; }
.filters label.ck { display: flex; gap: 8px; align-items: center; font-size: 14px; padding: 3px 0; cursor: pointer; }
.filters input[type=checkbox], .filters input[type=radio] { width: 16px; height: 16px; accent-color: var(--ink); }
.price-row { display: flex; gap: 8px; align-items: center; }
.price-row input { width: 100%; }
.results-bar { display: flex; flex-wrap: wrap; gap: 10px; justify-content: space-between; align-items: center; margin-bottom: 16px; }
.results-bar h1 { font-size: clamp(24px, 3vw, 32px); margin: 0; }
.chips { display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: 14px; }
.chip { display: inline-flex; gap: 6px; align-items: center; border: 1px solid var(--line-2); background: var(--paper); border-radius: 999px; padding: 4px 10px; font-size: 13px; font-weight: 600; cursor: pointer; }
.chip:hover { border-color: var(--ink); }
.filter-toggle { display: none; }
.empty { text-align: center; padding: 50px 20px; color: var(--ink-2); }

/* forms */
input[type=text], input[type=search], input[type=number], input[type=email], input[type=tel], select, textarea {
  width: 100%; font: 15px var(--body); color: var(--ink); background: #fff; border: 1.5px solid var(--line-2); border-radius: var(--radius-sm); padding: 10px 12px; }
input:focus, select:focus, textarea:focus { border-color: var(--ink); outline: none; }
textarea { min-height: 90px; resize: vertical; }
.field { margin-bottom: 14px; }
.field > label, .field > .lbl { display: block; font-weight: 700; font-size: 13.5px; margin-bottom: 5px; }
.field small { color: var(--ink-3); display: block; margin-top: 4px; }
.row2 { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.row3 { display: grid; grid-template-columns: 1fr 1fr 1fr; gap: 12px; }
.seg { display: inline-flex; flex-wrap: wrap; gap: 6px; }
.seg button, .seg label { border: 1.5px solid var(--line-2); background: #fff; border-radius: 999px; padding: 7px 14px; font: 700 13px var(--body); cursor: pointer; }
.seg button.on, .seg input:checked + span { border-color: var(--ink); background: var(--ink); color: #fff; }
.seg label { padding: 0; border: 0; background: none; }
.seg label span { display: inline-block; border: 1.5px solid var(--line-2); background: #fff; border-radius: 999px; padding: 7px 14px; }
.seg input { position: absolute; opacity: 0; pointer-events: none; }
.seg input:focus-visible + span { outline: 3px solid var(--thread); }

/* item page */
.item-layout { display: grid; grid-template-columns: 1.15fr 1fr; gap: 40px; align-items: start; }
.gallery { display: grid; grid-template-columns: 74px 1fr; gap: 12px; position: sticky; top: 120px; }
.thumbs { display: flex; flex-direction: column; gap: 8px; }
.thumbs button { padding: 0; border: 2px solid transparent; border-radius: 10px; overflow: hidden; cursor: pointer; background: none; aspect-ratio: 1; }
.thumbs button.on { border-color: var(--ink); }
.thumbs .art { width: 100%; height: 100%; display: block; }
.main-img { border-radius: var(--radius); overflow: hidden; aspect-ratio: 1; position: relative; background: var(--paper); }
.main-img .art { width: 100%; height: 100%; display: block; }
.main-img .fav { width: 44px; height: 44px; right: 14px; top: 14px; }
.buy h1 { font-size: clamp(26px, 3.4vw, 36px); }
.buy .price-big { font-size: 28px; font-weight: 800; margin: 6px 0 2px; }
.buy .price-big s { font-size: 17px; color: var(--ink-3); font-weight: 500; margin-left: 6px; }
.buy .tax { font-size: 12.5px; color: var(--ink-3); margin-bottom: 14px; }
.facts { display: grid; grid-template-columns: repeat(3, 1fr); border: 1px solid var(--line); border-radius: var(--radius-sm); background: var(--paper); margin: 14px 0; }
.facts div { padding: 10px 12px; border-right: 1px solid var(--line); }
.facts div:last-child { border: 0; }
.facts small { display: block; color: var(--ink-3); font-size: 11.5px; text-transform: uppercase; letter-spacing: .06em; font-weight: 700; }
.facts b { font-size: 15px; }
.buy-actions { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin: 16px 0; }
.buy-actions .btn { padding: 14px; font-size: 15px; }
.buy-actions .full { grid-column: span 2; }
.social-row { display: flex; gap: 16px; align-items: center; font-size: 14px; color: var(--ink-2); flex-wrap: wrap; }
.social-row button { display: inline-flex; gap: 6px; align-items: center; background: none; border: 0; font: 700 14px var(--body); color: var(--ink-2); cursor: pointer; padding: 6px 0; }
.social-row button.on { color: #c4334f; }
.social-row button.on svg { fill: currentColor; }
.box { background: var(--paper); border: 1px solid var(--line); border-radius: var(--radius); padding: 16px 18px; margin: 14px 0; }
.box h3 { font-size: 16px; font-family: var(--body); font-weight: 800; margin-bottom: 8px; }
.ship-form { display: flex; gap: 8px; }
.ship-form input { max-width: 140px; }
.ship-out { margin-top: 10px; font-size: 14px; }
.seller-card { display: flex; gap: 14px; align-items: center; }
.seller-card .sc-info { flex: 1; min-width: 0; }
.seller-card .sc-info a { font-weight: 800; text-decoration: none; font-size: 16px; }
.seller-card .sc-info small { display: block; color: var(--ink-3); }
.stars { color: var(--line-2); letter-spacing: 1px; }
.stars .on { color: var(--thread); }
.mto-note { background: var(--thread-soft); border-radius: var(--radius-sm); padding: 10px 12px; font-size: 14px; margin: 10px 0; display: flex; gap: 8px; align-items: center; }
.comments { list-style: none; padding: 0; margin: 0 0 12px; }
.comments li { padding: 8px 0; border-bottom: 1px solid var(--line); font-size: 14px; }
.comments li b { margin-right: 6px; }
.comments li .seller-tag { background: var(--loop-soft); color: var(--loop); font-size: 11px; font-weight: 800; padding: 1px 6px; border-radius: 4px; margin-right: 6px; }
.comments li small { color: var(--ink-3); margin-left: 6px; }
.comment-form { display: flex; gap: 8px; }

/* offer */
.offer-quick { display: flex; gap: 6px; flex-wrap: wrap; margin: 10px 0; }
.offer-result { border-radius: var(--radius-sm); padding: 14px; margin-top: 14px; font-size: 15px; }
.offer-result.accepted { background: #e2f3e8; }
.offer-result.countered { background: var(--thread-soft); }
.offer-result.declined { background: #f8e2df; }
.offer-calc { font-size: 13px; color: var(--ink-2); margin-top: 6px; }

/* seller pages */
.seller-hero { position: relative; border-radius: 0 0 var(--radius) var(--radius); overflow: hidden; height: 180px; }
.seller-hero .art { width: 100%; height: 100%; display: block; }
.seller-hero.loop { height: 120px; }
.seller-head { display: flex; gap: 20px; align-items: end; margin-top: -46px; position: relative; flex-wrap: wrap; }
.seller-head .avatar { border: 4px solid var(--oat); }
.seller-head .sh-info { flex: 1; min-width: 220px; padding-top: 50px; }
.seller-head h1 { font-size: clamp(26px, 4vw, 38px); margin: 0; }
.seller-head .sh-meta { color: var(--ink-2); font-size: 14px; display: flex; gap: 6px 16px; flex-wrap: wrap; }
.seller-stats { display: flex; gap: 26px; margin: 18px 0; flex-wrap: wrap; }
.seller-stats div b { display: block; font-size: 20px; font-family: var(--display); }
.seller-stats div small { color: var(--ink-3); font-size: 12.5px; }
.tabs { display: flex; gap: 4px; border-bottom: 1px solid var(--line); margin: 20px 0; overflow-x: auto; scrollbar-width: none; }
.tabs button { background: none; border: 0; padding: 12px 14px; font: 700 14px var(--body); color: var(--ink-2); border-bottom: 2.5px solid transparent; cursor: pointer; white-space: nowrap; }
.tabs button.on { color: var(--ink); border-color: var(--thread); }
.tabs button .n { background: var(--line); border-radius: 999px; padding: 0 7px; font-size: 12px; margin-left: 4px; }
.bundle-bar { position: sticky; bottom: 0; z-index: 30; background: var(--ink); color: #fff; border-radius: var(--radius) var(--radius) 0 0; padding: 14px 20px; display: flex; gap: 14px; align-items: center; justify-content: space-between; flex-wrap: wrap; margin-top: 20px; }
.bundle-bar .btn { background: var(--thread); color: var(--ink); }
.bundle-bar .bb-sum s { opacity: .6; margin-right: 6px; }
.bundle-info { background: var(--loop-soft); border-radius: var(--radius); padding: 14px 18px; margin-bottom: 16px; display: flex; gap: 14px; flex-wrap: wrap; align-items: center; justify-content: space-between; }
.review { padding: 14px 0; border-bottom: 1px solid var(--line); display: flex; gap: 14px; }
.review .art { width: 56px; height: 56px; border-radius: 8px; flex: none; }
.review p { margin: 4px 0; }
.review small { color: var(--ink-3); }
.shop-cols { display: grid; grid-template-columns: 220px 1fr; gap: 28px; align-items: start; }
.shop-side a, .shop-side button { display: block; width: 100%; text-align: left; padding: 7px 10px; border-radius: 8px; text-decoration: none; font-weight: 600; font-size: 14px; background: none; border: 0; cursor: pointer; color: var(--ink-2); }
.shop-side button.on { background: var(--paper); color: var(--ink); box-shadow: inset 3px 0 0 var(--made); }
.announce { background: var(--made-soft); border-radius: var(--radius-sm); padding: 12px 16px; margin: 16px 0; font-size: 14px; }

/* drawer */
.drawer-bg { position: fixed; inset: 0; background: rgba(31, 29, 43, .45); z-index: 60; }
.drawer-bg[hidden] { display: none; }
.drawer { position: fixed; top: 0; right: 0; bottom: 0; width: min(420px, 100%); background: var(--oat); z-index: 61; transform: translateX(100%); transition: transform .25s ease; display: flex; flex-direction: column; visibility: hidden; }
.drawer.open { transform: none; visibility: visible; }
.drawer-hd { display: flex; justify-content: space-between; align-items: center; padding: 14px 18px; border-bottom: 1px solid var(--line); background: var(--paper); }
.drawer-hd h3 { margin: 0; }
.drawer-bd { flex: 1; overflow: auto; padding: 14px; }
.drawer-ft { padding: 14px 18px; border-top: 1px solid var(--line); background: var(--paper); }
.cg { background: var(--paper); border: 1px solid var(--line); border-radius: var(--radius); padding: 12px; margin-bottom: 12px; }
.cg header { display: flex; justify-content: space-between; align-items: center; margin-bottom: 8px; }
.cg header a { display: flex; gap: 8px; align-items: center; text-decoration: none; }
.tag-side { font: 800 10.5px var(--body); text-transform: uppercase; letter-spacing: .08em; padding: 2px 8px; border-radius: 999px; color: #fff; }
.tag-side.side-made { background: var(--made); } .tag-side.side-loop { background: var(--loop); }
.cl { display: flex; gap: 10px; padding: 8px 0; border-top: 1px solid var(--line); }
.cl-img { width: 64px; height: 64px; border-radius: 8px; overflow: hidden; flex: none; }
.cl-img .art { width: 100%; height: 100%; display: block; }
.cl-info { flex: 1; min-width: 0; font-size: 14px; }
.cl-info > a { font-weight: 700; text-decoration: none; display: block; }
.cl-info small { display: block; color: var(--ink-3); font-size: 12.5px; }
.cl-info small.ok { color: var(--ok); font-weight: 700; }
.cl-row { display: flex; justify-content: space-between; align-items: center; margin: 4px 0; }
.qty { display: inline-flex; border: 1.5px solid var(--line-2); border-radius: 999px; align-items: center; }
.qty button { border: 0; background: none; width: 28px; height: 28px; cursor: pointer; font-size: 16px; }
.qty span { min-width: 20px; text-align: center; font-weight: 700; }
.cg-row { display: flex; justify-content: space-between; gap: 10px; font-size: 14px; padding: 4px 0; }
.cg-row.big { font-weight: 800; font-size: 17px; border-top: 1px solid var(--line); margin-top: 6px; padding-top: 10px; margin-bottom: 12px; }
.cg-hint { font-size: 13px; background: var(--loop-soft); border-radius: 8px; padding: 6px 10px; margin: 6px 0; }

/* modal + toast */
.modal-wrap { position: fixed; inset: 0; z-index: 80; background: rgba(31, 29, 43, .5); display: grid; place-items: center; padding: 16px; }
.modal { background: var(--oat); border-radius: var(--radius); width: min(480px, 100%); max-height: calc(100vh - 32px); overflow: auto; box-shadow: 0 20px 60px rgba(0, 0, 0, .25); }
.modal-hd { display: flex; justify-content: space-between; align-items: center; padding: 14px 18px; border-bottom: 1px solid var(--line); background: var(--paper); position: sticky; top: 0; }
.modal-hd h3 { margin: 0; }
.modal-bd { padding: 18px; }
#toast { position: fixed; left: 50%; bottom: 24px; transform: translate(-50%, 30px); background: var(--ink); color: #fff; padding: 11px 18px; border-radius: 999px; font-weight: 700; font-size: 14px; opacity: 0; pointer-events: none; transition: .25s; z-index: 90; max-width: calc(100% - 32px); text-align: center; }
#toast.show { opacity: 1; transform: translate(-50%, 0); }

/* checkout */
.steps { display: flex; gap: 6px; margin: 20px 0 24px; list-style: none; padding: 0; counter-reset: s; flex-wrap: wrap; }
.steps li { counter-increment: s; display: flex; align-items: center; gap: 8px; font-weight: 700; font-size: 14px; color: var(--ink-3); }
.steps li::before { content: counter(s); width: 26px; height: 26px; border-radius: 50%; display: grid; place-items: center; background: var(--line); color: var(--ink-2); font-size: 13px; }
.steps li.on { color: var(--ink); }
.steps li.on::before { background: var(--ink); color: #fff; }
.steps li.done::before { content: '✓'; background: var(--ok); color: #fff; }
.steps li + li::after { content: none; }
.steps li:not(:last-child) { margin-right: 14px; }
.co-layout { display: grid; grid-template-columns: 1fr 360px; gap: 28px; align-items: start; }
.co-summary { position: sticky; top: 120px; }
.ship-opt { display: flex; gap: 10px; align-items: center; border: 1.5px solid var(--line-2); border-radius: var(--radius-sm); padding: 10px 12px; margin: 6px 0; cursor: pointer; background: #fff; }
.ship-opt:has(input:checked) { border-color: var(--ink); }
.ship-opt span { flex: 1; }
.ship-opt input { accent-color: var(--ink); }
.demo-stamp { border: 2px dashed var(--thread); background: var(--thread-soft); border-radius: var(--radius); padding: 16px; text-align: center; font-weight: 800; margin: 16px 0; }

/* order timeline */
.timeline { list-style: none; padding: 0; margin: 0; position: relative; }
.timeline li { position: relative; padding: 0 0 22px 36px; }
.timeline li::before { content: ''; position: absolute; left: 9px; top: 22px; bottom: 0; width: 2px; background: var(--line-2); }
.timeline li:last-child::before { display: none; }
.timeline li .dot { position: absolute; left: 0; top: 2px; width: 20px; height: 20px; border-radius: 50%; background: var(--paper); border: 2px solid var(--line-2); }
.timeline li.done .dot { background: var(--ok); border-color: var(--ok); }
.timeline li.done::before { background: var(--ok); }
.timeline li.now .dot { background: var(--thread); border-color: var(--thread); box-shadow: 0 0 0 5px var(--thread-soft); }
.timeline li b { display: block; }
.timeline li small { color: var(--ink-3); }

/* sell */
.sell-layout { display: grid; grid-template-columns: 1fr 340px; gap: 28px; align-items: start; }
.sell-preview { position: sticky; top: 120px; }
.swatches { display: flex; flex-wrap: wrap; gap: 8px; }
.swatches button { width: 34px; height: 34px; border-radius: 50%; border: 3px solid #fff; box-shadow: 0 0 0 1.5px var(--line-2); cursor: pointer; }
.swatches button.on { box-shadow: 0 0 0 2.5px var(--ink); }
.shape-pick { display: grid; grid-template-columns: repeat(auto-fill, minmax(58px, 1fr)); gap: 6px; max-height: 210px; overflow: auto; padding: 2px; }
.shape-pick button { padding: 0; border: 2px solid transparent; border-radius: 8px; overflow: hidden; cursor: pointer; aspect-ratio: 1; background: none; }
.shape-pick button.on { border-color: var(--ink); }
.shape-pick .art { width: 100%; height: 100%; display: block; }
.fee-table { width: 100%; border-collapse: collapse; font-size: 14px; }
.fee-table td { padding: 6px 0; border-bottom: 1px solid var(--line); }
.fee-table td:last-child { text-align: right; font-variant-numeric: tabular-nums; }
.fee-table tr.keep td { font-weight: 800; font-size: 17px; border: 0; padding-top: 10px; color: var(--ok); }
.made-only, .loop-only { display: none; }
[data-mode="made"] .made-only, [data-mode="loop"] .loop-only { display: block; }

/* dashboard */
.kpis { display: grid; grid-template-columns: repeat(5, 1fr); gap: 12px; }
.kpi { background: var(--paper); border: 1px solid var(--line); border-radius: var(--radius); padding: 14px 16px; }
.kpi small { color: var(--ink-2); font-weight: 700; font-size: 12.5px; }
.kpi b { display: block; font-family: var(--display); font-size: 28px; font-weight: 600; margin: 2px 0; font-variant-numeric: tabular-nums; }
.kpi .delta { font-size: 12.5px; font-weight: 700; color: var(--ink-2); }
.kpi .delta.up::before { content: '▲ '; color: var(--ok); }
.kpi .delta.dn::before { content: '▼ '; color: var(--danger); }
.charts { display: grid; grid-template-columns: 1.4fr 1fr; gap: 16px; margin-top: 16px; }
.chart-box { background: var(--paper); border: 1px solid var(--line); border-radius: var(--radius); padding: 16px; position: relative; }
.chart-box h3 { font-family: var(--body); font-size: 15px; font-weight: 800; margin: 0 0 2px; }
.chart-box .sub { font-size: 12.5px; color: var(--ink-3); margin-bottom: 8px; }
.chart { width: 100%; height: auto; display: block; overflow: visible; }
.chart text { font: 11px var(--body); fill: var(--ink-3); }
.chart .grid-l { stroke: var(--line); stroke-width: 1; }
.legend { display: flex; gap: 14px; font-size: 12.5px; color: var(--ink-2); margin-bottom: 6px; flex-wrap: wrap; }
.legend i { display: inline-block; width: 10px; height: 10px; border-radius: 3px; margin-right: 5px; vertical-align: -1px; }
.tip { position: absolute; pointer-events: none; background: var(--ink); color: #fff; padding: 7px 10px; border-radius: 8px; font-size: 12.5px; line-height: 1.35; white-space: nowrap; transform: translate(-50%, -110%); opacity: 0; transition: opacity .1s; z-index: 5; }
.tip.show { opacity: 1; }
.tbl-wrap { overflow-x: auto; }
table.data { width: 100%; border-collapse: collapse; font-size: 14px; min-width: 560px; }
table.data th { text-align: left; font-size: 12px; color: var(--ink-3); text-transform: uppercase; letter-spacing: .06em; padding: 8px 10px; border-bottom: 1.5px solid var(--line-2); }
table.data td { padding: 9px 10px; border-bottom: 1px solid var(--line); vertical-align: middle; }
table.data td.n, table.data th.n { text-align: right; font-variant-numeric: tabular-nums; }
table.data .ti { display: flex; gap: 10px; align-items: center; }
table.data .ti .art { width: 38px; height: 38px; border-radius: 6px; flex: none; }
details.tbl-toggle summary { cursor: pointer; font-size: 13px; font-weight: 700; color: var(--ink-2); margin-top: 8px; }

/* account + feed */
.acct-layout { display: grid; grid-template-columns: 230px 1fr; gap: 28px; align-items: start; }
.acct-nav { display: flex; flex-direction: column; gap: 2px; position: sticky; top: 120px; }
.acct-nav a { padding: 9px 12px; border-radius: 9px; text-decoration: none; font-weight: 700; font-size: 14px; color: var(--ink-2); display: flex; justify-content: space-between; }
.acct-nav a.on { background: var(--paper); color: var(--ink); box-shadow: inset 3px 0 0 var(--thread); }
.list-row { display: flex; gap: 14px; align-items: center; background: var(--paper); border: 1px solid var(--line); border-radius: var(--radius); padding: 12px; margin-bottom: 10px; flex-wrap: wrap; }
.list-row .art { width: 64px; height: 64px; border-radius: 8px; flex: none; }
.list-row .lr-info { flex: 1; min-width: 160px; }
.list-row .lr-info b { display: block; }
.list-row .lr-info small { color: var(--ink-3); }
.list-row .lr-act { display: flex; gap: 6px; flex-wrap: wrap; }
.status { font: 800 11px var(--body); text-transform: uppercase; letter-spacing: .06em; padding: 3px 8px; border-radius: 999px; background: var(--line); }
.status.accepted, .status.delivered { background: #d7efdf; color: var(--ok); }
.status.countered, .status.pending, .status.shipped { background: var(--thread-soft); color: #7a5a10; }
.status.declined { background: #f8e2df; color: var(--danger); }
.feed-layout { display: grid; grid-template-columns: 1fr 300px; gap: 28px; align-items: start; }
.post { background: var(--paper); border: 1px solid var(--line); border-radius: var(--radius); padding: 14px; margin-bottom: 14px; }
.post-hd { display: flex; gap: 10px; align-items: center; margin-bottom: 10px; font-size: 14px; }
.post-hd small { color: var(--ink-3); display: block; }
.post-item { display: flex; gap: 14px; text-decoration: none; background: var(--oat); border-radius: var(--radius-sm); padding: 10px; }
.post-item .art { width: 110px; height: 110px; border-radius: 8px; flex: none; }
.post-item b { display: block; font-size: 15px; }
.post .caption { margin: 0 0 10px; }
.post-ft { display: flex; gap: 16px; margin-top: 10px; }
.post-ft button, .post-ft a { background: none; border: 0; padding: 0; display: inline-flex; gap: 6px; align-items: center; font: 700 13px var(--body); color: var(--ink-2); cursor: pointer; text-decoration: none; }
.post-ft button.on { color: #c4334f; } .post-ft button.on svg { fill: currentColor; }
.follow-list { display: grid; gap: 8px; }
.follow-list .fl { display: flex; gap: 10px; align-items: center; }
.follow-list .fl a { flex: 1; text-decoration: none; font-weight: 700; font-size: 14px; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.follow-list .fl small { display: block; color: var(--ink-3); font-weight: 500; }

/* responsive */
@media (max-width: 1080px) {
  .kpis { grid-template-columns: repeat(3, 1fr); }
  .makers { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 900px) {
  .hero-grid, .item-layout, .drops, .co-layout, .sell-layout, .charts, .feed-layout { grid-template-columns: 1fr; }
  .gallery, .co-summary, .sell-preview { position: static; }
  .search-layout, .shop-cols, .acct-layout { grid-template-columns: 1fr; }
  .filters { position: static; max-height: none; display: none; }
  .filters.open { display: block; }
  .filter-toggle { display: inline-flex; }
  .acct-nav { position: static; flex-direction: row; overflow-x: auto; scrollbar-width: none; }
  .acct-nav a { white-space: nowrap; }
  .shop-side { display: flex; overflow-x: auto; gap: 4px; scrollbar-width: none; }
  .shop-side button { white-space: nowrap; width: auto; }
  .foot { grid-template-columns: 1fr 1fr; }
  .foot-brand { grid-column: span 2; }
}
@media (max-width: 720px) {
  .hdr { flex-wrap: wrap; height: auto; padding-top: 8px; padding-bottom: 8px; gap: 6px 8px; }
  .nav-toggle { display: inline-grid; }
  .brand { font-size: 22px; margin-right: auto; }
  .hdr-search { order: 5; flex-basis: 100%; max-width: none; }
  .main-nav { display: none; }
  .site-header.nav-open .main-nav { display: block; }
  .main-nav .wrap { flex-direction: column; padding: 6px 20px 12px; }
  .main-nav a { border-bottom: 0; border-left: 3px solid transparent; padding: 10px 12px; }
  .main-nav a.active { border-left-color: var(--thread); }
  .wrap { padding: 0 16px; }
  .two-sides, .makers { grid-template-columns: 1fr; }
  .grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
  .kpis { grid-template-columns: repeat(2, 1fr); }
  .gallery { grid-template-columns: 1fr; }
  .thumbs { flex-direction: row; order: 2; }
  .thumbs button { width: 64px; }
  .row2, .row3 { grid-template-columns: 1fr; }
  .facts { grid-template-columns: 1fr 1fr 1fr; }
  .facts div { padding: 8px; }
  .buy-actions { grid-template-columns: 1fr; }
  .buy-actions .full { grid-column: auto; }
  .card-rail .card { width: 160px; }
  .cat-rail a, .cat-rail .ci { width: 88px; }
  .cat-rail .ci { height: 88px; }
  .post-item .art { width: 80px; height: 80px; }
  .section { margin: 32px 0; }
  .panel { padding: 16px; }
  .seller-hero { height: 130px; }
}
@media (max-width: 420px) {
  .hdr-icons .icon-btn:first-child { display: none; }
  .card-body { padding: 8px 10px 10px; }
  .side-switch button { padding: 8px 12px; }
}

/* keep grid columns from overflowing on narrow screens */
.hero-grid > *, .item-layout > *, .drops > *, .co-layout > *, .sell-layout > *, .charts > *, .feed-layout > *, .search-layout > *, .shop-cols > *, .acct-layout > *, .row2 > *, .row3 > * { min-width: 0; }
