/* ==========================================================================
   AAFL 商城前端原型 · Shopee 风格视觉系统
   参照：Shopee 首页 / 全页 / 分类列表 / 个人中心四张截图
   纯本地资源，无外部字体、无 CDN、无图片生成
   ========================================================================== */
:root {
    --sp:        #ee4d2d;          /* 主橙红 */
    --sp-dark:   #d63c20;
    --sp-deep:   #b02a16;
    --sp-soft:   #fff3ef;
    --sp-line:   #ffd9cd;
    --grad:      linear-gradient(-180deg, #f53d2d, #f63, #ee4d2d);
    --ink:       #222222;
    --ink-2:     #444444;
    --muted:     #757575;
    --muted-2:   #9b9b9b;
    --line:      #e8e8e8;
    --line-2:    #f0f0f0;
    --bg:        #f5f5f5;
    --white:     #ffffff;
    --star:      #ffb400;
    --green:     #26aa99;
    --wrap:      1200px;
    --radius:    2px;
    --shadow:    0 1px 2px rgba(0,0,0,.06);
    --shadow-h:  0 6px 20px rgba(0,0,0,.12);
    --font:      -apple-system, BlinkMacSystemFont, "Segoe UI", Arial,
                 "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", sans-serif;
}
* { margin: 0; padding: 0; box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
    font-family: var(--font); font-size: 13px; line-height: 1.5;
    color: var(--ink); background: var(--bg);
    -webkit-font-smoothing: antialiased;
}
a { color: inherit; text-decoration: none; }
img { max-width: 100%; display: block; }
ul, ol { list-style: none; }
button, input, select, textarea { font-family: inherit; font-size: inherit; color: inherit; }
button { cursor: pointer; border: 0; background: none; }
:focus-visible { outline: 2px solid var(--sp); outline-offset: 2px; }
.wrap { max-width: var(--wrap); margin: 0 auto; padding-inline: 0; }
.svg { width: 1em; height: 1em; display: inline-block; vertical-align: -.13em; flex: none; fill: currentColor; }
.ico { fill: none !important; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

/* ============ 顶部工具条 ============ */
.util {
    background: var(--grad); color: #fff; font-size: 12px;
    border-bottom: 1px solid rgba(255,255,255,.22);
}
.util-in { height: 31px; display: flex; align-items: center; justify-content: space-between; }
.util a { opacity: .92; transition: opacity .15s; }
.util a:hover { opacity: 1; text-decoration: underline; }
.util-l, .util-r { display: flex; align-items: center; gap: 0; }
.util-l a, .util-r a, .util-r .util-item {
    padding: 0 11px; border-right: 1px solid rgba(255,255,255,.38);
    line-height: 1; white-space: nowrap;
}
.util-l a:first-child { padding-left: 0; }
.util-r a:last-child, .util-r .util-item:last-child { border-right: 0; padding-right: 0; }
.util-r .util-item { display: inline-flex; align-items: center; gap: 5px; }
.util-sep { border-right: 1px solid rgba(255,255,255,.38); height: 13px; }
.util-ico { font-size: 13px; }
.lang-wrap { position: relative; }
.lang-menu {
    display: none; position: absolute; top: 100%; right: 0; z-index: 70;
    background: #fff; color: var(--ink); min-width: 154px; padding: 5px 0;
    box-shadow: var(--shadow-h); border: 1px solid var(--line); border-radius: var(--radius);
}
.lang-wrap:hover .lang-menu, .lang-wrap.open .lang-menu { display: block; }
.lang-menu a { display: block; padding: 8px 14px; color: var(--ink-2) !important; opacity: 1 !important; border: 0 !important; font-size: 12.5px; }
.lang-menu a:hover { background: var(--sp-soft); color: var(--sp) !important; text-decoration: none !important; }

/* ============ 主头部：Logo + 搜索 + 购物车 ============ */
.masthead { background: var(--grad); color: #fff; }
.mast-in {
    min-height: 92px; display: grid;
    grid-template-columns: 210px minmax(0, 1fr) 138px;
    align-items: start; gap: 20px; padding-top: 18px; padding-bottom: 12px;
}
.logo { display: flex; align-items: center; gap: 10px; padding-top: 4px; }
.logo-mark {
    display: block; width: 34px; height: 38px; position: relative; flex: none;
    border: 2.5px solid #fff; border-radius: 4px 4px 6px 6px;
}
.logo-mark::before {
    content: ''; position: absolute; left: 50%; top: -8px; width: 17px; height: 13px;
    transform: translateX(-50%); border: 2.5px solid #fff; border-bottom: 0;
    border-radius: 9px 9px 0 0;
}
/* 品牌图标字母：与数据库 brand_name（AAFL）首字母保持一致，换品牌时同步改这里 */
.logo-mark::after {
    content: 'A'; position: absolute; inset: 0; display: grid; place-items: center;
    font-size: 17px; font-weight: 700; font-style: italic; color: #fff;
}
.logo-txt { font-size: 27px; font-weight: 500; letter-spacing: .5px; line-height: 1; }
.logo-sub { display: block; font-size: 9.5px; letter-spacing: 2.4px; opacity: .82; margin-top: 5px; font-weight: 400; }

.search-col { min-width: 0; padding-top: 2px; }
.search-box {
    display: flex; height: 40px; background: #fff; border-radius: var(--radius);
    box-shadow: 0 1px 3px rgba(0,0,0,.10); overflow: hidden;
}
.search-box input {
    flex: 1; min-width: 0; border: 0; outline: 0; padding: 0 14px;
    font-size: 13.5px; color: var(--ink); background: #fff;
}
.search-box input::placeholder { color: #a4a4a4; }
.search-box button {
    width: 62px; flex: none; background: var(--sp); color: #fff;
    display: grid; place-items: center; font-size: 17px;
    transition: background .15s;
}
.search-box button:hover { background: var(--sp-dark); }
.hotwords { display: flex; gap: 14px; margin-top: 8px; font-size: 11.5px; overflow: hidden; white-space: nowrap; }
.hotwords a { opacity: .86; }
.hotwords a:hover { opacity: 1; text-decoration: underline; }

.cart-col { display: flex; justify-content: flex-end; padding-top: 8px; }
.cart-btn { position: relative; display: block; padding: 4px 8px; }
.cart-btn svg { width: 27px; height: 27px; stroke: #fff; fill: none; stroke-width: 1.6; }
.cart-num {
    position: absolute; top: -2px; right: -3px; min-width: 19px; height: 17px;
    padding: 0 5px; border: 1.5px solid #fff; border-radius: 10px;
    background: #fff; color: var(--sp); font-size: 11px; font-weight: 700;
    display: grid; place-items: center; line-height: 1;
}

/* ============ 分类导航条 ============ */
.catnav { background: #fff; box-shadow: 0 1px 2px rgba(0,0,0,.05); }
.catnav-in { height: 44px; display: flex; align-items: center; gap: 0; }
.catnav a {
    padding: 0 20px; font-size: 13px; color: var(--ink-2); height: 100%;
    display: inline-flex; align-items: center; gap: 7px; white-space: nowrap;
    border-bottom: 2px solid transparent; transition: color .15s;
}
.catnav a:first-child { padding-left: 0; }
.catnav a:hover, .catnav a.on { color: var(--sp); }
.catnav a.on { border-bottom-color: var(--sp); font-weight: 600; }
.catnav .cn-spacer { flex: 1; }
.catnav .cn-side { color: var(--sp); font-weight: 600; padding-right: 0; }
.catnav .dot { width: 4px; height: 4px; border-radius: 50%; background: var(--sp); display: inline-block; }

/* ============ 通用区块 ============ */
.page { padding: 22px 0 46px; min-height: 500px; }
.sec { background: #fff; margin-bottom: 18px; border-radius: var(--radius); box-shadow: var(--shadow); }
.sec-head {
    display: flex; align-items: center; justify-content: space-between;
    padding: 16px 20px; border-bottom: 1px solid var(--line-2);
}
.sec-head h2 { font-size: 16px; font-weight: 600; color: var(--ink); display: flex; align-items: center; gap: 9px; }
.sec-head h2 .en { font-size: 11px; font-weight: 400; color: var(--muted-2); letter-spacing: 1.2px; text-transform: uppercase; }
.sec-head .more { font-size: 12.5px; color: var(--sp); display: inline-flex; align-items: center; gap: 4px; }
.sec-head .more:hover { text-decoration: underline; }
.sec-mid { padding: 0 20px 20px; }
.pad { padding: 20px; }

/* 区块标头（大写、橙左侧竖条，Shopee 区块常见） */
.sp-title {
    font-size: 16px; font-weight: 500; color: var(--sp);
    text-transform: uppercase; letter-spacing: .4px;
    border-bottom: 1px solid var(--line-2); padding: 15px 0 12px;
    display: flex; align-items: center; gap: 10px;
}
.sp-title::before { content: ''; width: 4px; height: 17px; background: var(--sp); border-radius: 1px; }

/* ============ 首页 Banner ============ */
.hero { display: grid; grid-template-columns: minmax(0, 1fr) 246px; gap: 10px; margin-bottom: 18px; }
.hero-main {
    position: relative; height: 330px; overflow: hidden; border-radius: var(--radius);
    background: linear-gradient(115deg, #f94b2b 0%, #ee4d2d 46%, #ff7a45 100%);
    color: #fff;
}
.hero-slide {
    position: absolute; inset: 0; display: none;
    align-items: center; padding: 34px 42px;
    animation: fadeIn .35s ease both;
}
.hero-slide.on { display: flex; }
@keyframes fadeIn { from { opacity: .35; } to { opacity: 1; } }
.hero-slide.s2 { background: linear-gradient(115deg, #b8331d 0%, #d94a2a 52%, #f08a4b 100%); }
.hero-slide.s3 { background: linear-gradient(115deg, #7a3420 0%, #b3552c 50%, #e1954e 100%); }
.hero-copy { position: relative; z-index: 2; max-width: 52%; }
.hero-kicker {
    display: inline-block; font-size: 11.5px; letter-spacing: 2px;
    border: 1px solid rgba(255,255,255,.6); border-radius: 2px;
    padding: 4px 10px; margin-bottom: 18px;
}
.hero-copy h1 { font-size: 40px; line-height: 1.18; font-weight: 700; letter-spacing: 1px; }
.hero-copy h1 small { display: block; font-size: 17px; font-weight: 400; letter-spacing: 4px; margin-top: 10px; opacity: .9; }
.hero-copy p { font-size: 13.5px; opacity: .9; margin: 16px 0 22px; line-height: 1.8; }
.hero-btn {
    display: inline-flex; align-items: center; gap: 9px; background: #fff; color: var(--sp);
    font-size: 14px; font-weight: 600; padding: 10px 24px; border-radius: 2px;
    transition: transform .18s, box-shadow .18s;
}
.hero-btn:hover { transform: translateY(-2px); box-shadow: 0 6px 18px rgba(0,0,0,.16); }
.hero-art {
    position: absolute; right: 4%; top: 50%; transform: translateY(-50%);
    width: 330px; height: 260px; z-index: 1;
}
.hero-art .halo {
    position: absolute; inset: 0; border-radius: 50%;
    background: radial-gradient(circle, rgba(255,255,255,.28) 0%, rgba(255,255,255,0) 68%);
}
.hero-art .pic {
    position: absolute; width: 168px; height: 168px; border-radius: 50%;
    object-fit: cover; border: 5px solid rgba(255,255,255,.9);
    box-shadow: 0 14px 34px rgba(0,0,0,.22);
}
.hero-art .pic.a { left: 6px; top: 44px; }
.hero-art .pic.b { right: 0; top: 6px; width: 138px; height: 138px; }
.hero-art .pic.c { right: 26px; bottom: 0; width: 116px; height: 116px; }
.hero-dots { position: absolute; bottom: 16px; left: 42px; display: flex; gap: 7px; z-index: 3; }
.hero-dots button { width: 18px; height: 4px; border-radius: 2px; background: rgba(255,255,255,.5); }
.hero-dots button.on { background: #fff; width: 28px; }
.hero-arrow {
    position: absolute; top: 50%; transform: translateY(-50%); z-index: 3;
    width: 32px; height: 46px; background: rgba(0,0,0,.18); color: #fff;
    display: grid; place-items: center; font-size: 20px; opacity: 0; transition: opacity .2s;
}
.hero-main:hover .hero-arrow { opacity: 1; }
.hero-arrow.prev { left: 0; border-radius: 0 3px 3px 0; }
.hero-arrow.next { right: 0; border-radius: 3px 0 0 3px; }
.hero-side { display: grid; grid-template-rows: 1fr 1fr; gap: 10px; }
.side-banner {
    position: relative; overflow: hidden; border-radius: var(--radius);
    padding: 18px 20px; color: #fff; display: flex; flex-direction: column; justify-content: center;
}
.side-banner.b1 { background: linear-gradient(120deg, #b52d18, #e4562f); }
.side-banner.b2 { background: linear-gradient(120deg, #fdf3e7, #f6e2c8); color: #8a4a22; }
.side-banner .sb-tag { font-size: 10.5px; letter-spacing: 2px; opacity: .85; }
.side-banner strong { font-size: 19px; font-weight: 700; margin: 6px 0 4px; line-height: 1.3; }
.side-banner span { font-size: 11.5px; opacity: .88; }
.side-banner img { position: absolute; right: -14px; bottom: -12px; width: 108px; height: 108px; object-fit: cover; border-radius: 50%; opacity: .92; border: 3px solid rgba(255,255,255,.5); }
.side-banner.b2 img { border-color: rgba(255,255,255,.9); }

/* ============ 服务承诺条 ============ */
.assure { display: grid; grid-template-columns: repeat(4, 1fr); background: #fff; margin-bottom: 18px; border-radius: var(--radius); box-shadow: var(--shadow); }
.assure-item { display: flex; align-items: center; gap: 13px; padding: 19px 22px; border-right: 1px solid var(--line-2); }
.assure-item:last-child { border-right: 0; }
.assure-ico { width: 38px; height: 38px; flex: none; border: 1.5px solid var(--sp); border-radius: 50%; color: var(--sp); display: grid; place-items: center; font-size: 18px; }
.assure-item b { display: block; font-size: 13.5px; font-weight: 600; }
.assure-item small { display: block; font-size: 11.5px; color: var(--muted); margin-top: 3px; }

/* ============ 四个分类卡 ============ */
.cats { display: grid; grid-template-columns: repeat(4, 1fr); gap: 1px; background: var(--line-2); }
.cat-card { background: #fff; padding: 26px 18px 24px; text-align: center; transition: background .18s; }
.cat-card:hover { background: var(--sp-soft); }
.cat-thumb {
    display: block; width: 116px; height: 116px; margin: 0 auto 16px; border-radius: 50%;
    overflow: hidden; border: 1px solid var(--line-2); background: #fafafa;
    box-shadow: 0 3px 10px rgba(0,0,0,.05);
}
.cat-thumb img { width: 100%; height: 100%; object-fit: cover; transition: transform .4s; }
.cat-card:hover .cat-thumb img { transform: scale(1.08); }
.cat-card b { display: block; font-size: 14.5px; font-weight: 600; }
.cat-card small { display: block; font-size: 11.5px; color: var(--muted); margin-top: 5px; }
.cat-card .cat-arrow { display: inline-block; margin-top: 12px; font-size: 12px; color: var(--sp); }

/* ============ 商品卡（全站核心） ============ */
.p-grid { display: grid; grid-template-columns: repeat(6, minmax(0, 1fr)); gap: 8px; }
.p-grid.cols5 { grid-template-columns: repeat(5, minmax(0, 1fr)); }
.p-grid.cols4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.p-card {
    background: #fff; position: relative; display: flex; flex-direction: column;
    border: 1px solid transparent; border-radius: var(--radius); overflow: hidden;
    transition: border-color .16s, transform .16s, box-shadow .16s;
}
.p-card:hover { border-color: var(--sp); transform: translateY(-1px); box-shadow: var(--shadow-h); z-index: 2; }
.p-ph { position: relative; display: block; aspect-ratio: 1 / 1; background: #fafafa; overflow: hidden; }
.p-ph img { width: 100%; height: 100%; object-fit: cover; transition: transform .35s; }
.p-card:hover .p-ph img { transform: scale(1.045); }
.p-flag { position: absolute; top: 8px; left: 0; background: var(--sp); color: #fff; font-size: 10px; padding: 3px 7px 3px 6px; border-radius: 0 2px 2px 0; }
.p-flag.green { background: var(--green); }
.p-free { position: absolute; left: 0; bottom: 0; right: 0; background: rgba(38,170,153,.92); color: #fff; font-size: 10px; text-align: center; padding: 2px 0; letter-spacing: .3px; }
.p-body { padding: 9px 9px 10px; display: flex; flex-direction: column; flex: 1; }
.p-name {
    font-size: 12.5px; line-height: 1.45; color: var(--ink-2); height: 36px;
    overflow: hidden; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical;
}
.p-tags { display: flex; gap: 4px; margin: 6px 0 4px; flex-wrap: wrap; min-height: 17px; }
.p-tags em { font-style: normal; font-size: 9.5px; color: var(--sp); border: 1px solid var(--sp-line); padding: 0 3px; border-radius: 1px; line-height: 15px; }
.p-tags em.solid { background: var(--sp); color: #fff; border-color: var(--sp); }
.p-price-row { display: flex; align-items: baseline; gap: 6px; margin-top: auto; padding-top: 6px; }
.p-price { color: var(--sp); font-size: 16px; font-weight: 600; font-variant-numeric: tabular-nums; }
.p-price .cur { font-size: 11px; margin-right: 1px; }
.p-old { color: var(--muted-2); font-size: 11px; text-decoration: line-through; }
.p-meta { display: flex; align-items: center; justify-content: space-between; gap: 4px; margin-top: 7px; font-size: 10.5px; color: var(--muted); }
.p-stars { color: var(--star); letter-spacing: -.5px; font-size: 10.5px; white-space: nowrap; }
.p-stars .num { color: var(--muted); margin-left: 3px; }
.p-loc { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.p-add {
    position: absolute; left: 0; right: 0; bottom: 0; height: 32px;
    background: var(--sp); color: #fff; font-size: 12px; font-weight: 600;
    display: flex; align-items: center; justify-content: center; gap: 6px;
    transform: translateY(100%); transition: transform .18s;
}
.p-card:hover .p-add { transform: translateY(0); }
.p-add:hover { background: var(--sp-dark); }

/* 列表视图 */
.p-grid.listview { grid-template-columns: 1fr; gap: 10px; }
.p-grid.listview .p-card { flex-direction: row; align-items: stretch; }
.p-grid.listview .p-ph { width: 180px; height: 180px; aspect-ratio: auto; flex: none; }
.p-grid.listview .p-body { padding: 16px 18px; }
.p-grid.listview .p-name { height: auto; font-size: 15px; -webkit-line-clamp: 2; }
.p-grid.listview .p-price { font-size: 19px; }
.p-grid.listview .p-meta { justify-content: flex-start; gap: 18px; margin-top: 12px; }
.p-grid.listview .p-add { position: static; transform: none; width: 130px; height: auto; margin: auto 18px auto 0; border-radius: 2px; }

/* ============ 排序工具条 / 分页 ============ */
.sortbar {
    display: flex; align-items: center; gap: 8px; background: #fbeae5;
    padding: 10px 14px; margin-bottom: 12px; border-radius: var(--radius);
}
.sortbar .sb-label { font-size: 12.5px; color: var(--ink-2); margin-right: 4px; flex: none; }
.sort-btn { padding: 7px 18px; background: #fff; color: var(--ink-2); font-size: 12.5px; border: 1px solid transparent; border-radius: 2px; }
.sort-btn:hover { color: var(--sp); }
.sort-btn.on { background: var(--sp); color: #fff; border-color: var(--sp); }
.sort-combo { position: relative; }
.sort-combo select {
    appearance: none; background: #fff; border: 1px solid var(--line); border-radius: 2px;
    padding: 7px 28px 7px 12px; font-size: 12.5px; cursor: pointer;
}
.sort-combo::after { content: '▾'; position: absolute; right: 10px; top: 50%; transform: translateY(-50%); pointer-events: none; font-size: 10px; color: var(--muted); }
.sortbar .spacer { flex: 1; }
.sort-page { display: flex; align-items: center; gap: 8px; font-size: 12.5px; color: var(--ink-2); }
.sort-page b { color: var(--sp); font-size: 15px; }
.view-toggle { display: flex; margin-left: 10px; }
.view-toggle button { width: 34px; height: 30px; background: #fff; border: 1px solid var(--line); color: var(--muted); display: grid; place-items: center; }
.view-toggle button + button { border-left: 0; }
.view-toggle button.on { background: var(--sp); color: #fff; border-color: var(--sp); }
.view-toggle svg { width: 15px; height: 15px; fill: currentColor; }

.pager { display: flex; align-items: center; justify-content: center; gap: 6px; padding: 30px 0 8px; flex-wrap: wrap; }
.pager button {
    min-width: 36px; height: 36px; padding: 0 10px; background: #fff; border: 1px solid var(--line);
    border-radius: 2px; font-size: 13px; color: var(--ink-2);
}
.pager button:hover:not(:disabled) { border-color: var(--sp); color: var(--sp); }
.pager button.on { background: var(--sp); color: #fff; border-color: var(--sp); }
.pager button:disabled { color: #c9c9c9; background: #fafafa; cursor: not-allowed; }
.pager .dots { padding: 0 4px; color: var(--muted); }

/* ============ 分类列表页 ============ */
.crumb { display: flex; align-items: center; gap: 8px; font-size: 12px; color: var(--muted); padding: 4px 0 14px; }
.crumb a:hover { color: var(--sp); }
.crumb i { font-style: normal; color: #bbb; }
.list-layout { display: grid; grid-template-columns: 196px minmax(0, 1fr); gap: 14px; align-items: start; }
.filter { background: #fff; border-radius: var(--radius); box-shadow: var(--shadow); padding: 0 16px 18px; }
.filter-block { padding: 16px 0; border-bottom: 1px solid var(--line-2); }
.filter-block:last-of-type { border-bottom: 0; }
.filter-block h3 { font-size: 13.5px; font-weight: 600; margin-bottom: 12px; display: flex; align-items: center; gap: 7px; }
.filter-cats { display: flex; flex-direction: column; gap: 2px; }
.filter-cats a { padding: 7px 8px; font-size: 12.5px; color: var(--ink-2); border-radius: 2px; display: flex; align-items: center; justify-content: space-between; }
.filter-cats a:hover { background: var(--sp-soft); color: var(--sp); }
.filter-cats a.on { background: var(--sp-soft); color: var(--sp); font-weight: 600; }
.filter-cats a span { font-size: 11px; color: var(--muted-2); font-weight: 400; }
.price-row { display: flex; align-items: center; gap: 6px; }
.price-row input { width: 100%; min-width: 0; border: 1px solid var(--line); border-radius: 2px; padding: 6px 7px; font-size: 12px; outline: 0; }
.price-row input:focus { border-color: var(--sp); }
.price-row span { color: var(--muted); }
.chk { display: flex; align-items: center; gap: 8px; padding: 5px 0; font-size: 12.5px; color: var(--ink-2); cursor: pointer; }
.chk input { appearance: none; width: 15px; height: 15px; border: 1px solid #c8c8c8; border-radius: 2px; flex: none; position: relative; cursor: pointer; }
.chk input:checked { background: var(--sp); border-color: var(--sp); }
.chk input:checked::after { content: '✓'; position: absolute; inset: -2px 0 0; text-align: center; color: #fff; font-size: 12px; font-weight: 700; }
.chk:hover { color: var(--sp); }
.stars-filter { color: var(--star); font-size: 14px; letter-spacing: 1px; }
.btn-filter {
    width: 100%; background: var(--sp); color: #fff; font-size: 13px; font-weight: 600;
    padding: 10px; border-radius: 2px; margin-top: 14px;
}
.btn-filter:hover { background: var(--sp-dark); }
.btn-clear { width: 100%; background: #fff; color: var(--muted); border: 1px solid var(--line); padding: 9px; font-size: 12.5px; border-radius: 2px; margin-top: 8px; }
.btn-clear:hover { color: var(--sp); border-color: var(--sp); }

.brandwall { display: grid; grid-template-columns: repeat(4, 1fr); gap: 8px; margin-bottom: 12px; }
.brandwall .bw {
    background: #fff; border: 1px solid var(--line-2); border-radius: var(--radius);
    height: 62px; display: flex; align-items: center; justify-content: center; gap: 8px;
    color: var(--ink-2); transition: border-color .16s, color .16s;
}
.brandwall .bw:hover { border-color: var(--sp); color: var(--sp); }
.bw-logo { font-size: 18px; font-weight: 700; letter-spacing: 1px; font-style: italic; }
.bw-logo.a { font-family: Georgia, serif; font-style: normal; letter-spacing: 3px; font-size: 16px; }
.bw-logo.b { color: #2f6f8f; }
.bw-logo.c { color: #8c5b2f; }
.bw-logo.d { color: #3f7a5c; }
.brandwall .bw small { font-size: 10px; color: var(--muted-2); }

/* ============ 商品详情页 ============ */
.detail-card { background: #fff; border-radius: var(--radius); box-shadow: var(--shadow); padding: 22px; display: grid; grid-template-columns: 420px minmax(0, 1fr); gap: 34px; }
.gallery-main { aspect-ratio: 1/1; border: 1px solid var(--line-2); background: #fafafa; overflow: hidden; }
.gallery-main img { width: 100%; height: 100%; object-fit: cover; }
.gallery-thumbs { display: grid; grid-template-columns: repeat(5, 1fr); gap: 8px; margin-top: 10px; }
.gallery-thumbs button { aspect-ratio: 1/1; border: 1px solid var(--line-2); overflow: hidden; background: #fafafa; }
.gallery-thumbs button.on, .gallery-thumbs button:hover { border: 2px solid var(--sp); }
.gallery-thumbs img { width: 100%; height: 100%; object-fit: cover; }
.gallery-share { display: flex; align-items: center; gap: 14px; margin-top: 18px; font-size: 12px; color: var(--muted); }
.gallery-share .s-ico { display: inline-flex; gap: 8px; }
.gallery-share .s-ico i { width: 24px; height: 24px; border-radius: 50%; display: grid; place-items: center; font-style: normal; font-size: 11px; color: #fff; }
.gallery-share .s-ico i:nth-child(1) { background: #3b5998; }
.gallery-share .s-ico i:nth-child(2) { background: #1da1f2; }
.gallery-share .s-ico i:nth-child(3) { background: #e6162d; }
.gallery-share .s-ico i:nth-child(4) { background: #25a85b; }

.d-title { font-size: 21px; font-weight: 500; line-height: 1.45; }
.d-rating { display: flex; align-items: center; gap: 14px; margin-top: 12px; font-size: 13px; color: var(--muted); }
.d-rating .stars { color: var(--star); font-size: 15px; letter-spacing: 1px; }
.d-rating b { color: var(--sp); font-size: 15px; border-bottom: 1px solid var(--sp); }
.d-rating span + span { border-left: 1px solid var(--line); padding-left: 14px; }
.d-pricebox { background: #fafafa; padding: 18px 22px; margin: 18px 0; border-radius: 2px; }
.d-pricebox .old { font-size: 13px; color: var(--muted-2); text-decoration: line-through; }
.d-price { color: var(--sp); font-size: 32px; font-weight: 600; line-height: 1.2; font-variant-numeric: tabular-nums; }
.d-price .cur { font-size: 18px; }
.d-rows { display: flex; flex-direction: column; gap: 16px; padding: 4px 0 8px; }
.d-row { display: flex; align-items: flex-start; gap: 18px; font-size: 13px; }
.d-row > label { width: 76px; flex: none; color: var(--muted); padding-top: 5px; }
.d-row .val { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; }
.chip { border: 1px solid var(--line); padding: 6px 13px; font-size: 12.5px; color: var(--ink-2); background: #fff; border-radius: 2px; }
.chip:hover, .chip.on { border-color: var(--sp); color: var(--sp); }
.chip.on { position: relative; }
.qty { display: inline-flex; align-items: stretch; height: 32px; border: 1px solid var(--line); background: #fff; }
.qty button { width: 32px; font-size: 16px; color: var(--muted); border-right: 1px solid var(--line); }
.qty button:last-child { border-right: 0; border-left: 1px solid var(--line); }
.qty input { width: 54px; text-align: center; border: 0; outline: 0; font-size: 13px; }
.qty-note { color: var(--muted-2); font-size: 12px; }
.d-actions { display: flex; gap: 12px; margin-top: 20px; }
.btn-cart { background: var(--sp-soft); color: var(--sp); border: 1px solid var(--sp); padding: 12px 28px; font-size: 14.5px; font-weight: 600; border-radius: 2px; display: inline-flex; align-items: center; gap: 8px; }
.btn-cart:hover { background: #ffe6dd; }
.btn-buy { background: var(--sp); color: #fff; padding: 12px 40px; font-size: 14.5px; font-weight: 600; border-radius: 2px; }
.btn-buy:hover { background: var(--sp-dark); }
.d-guard { display: flex; flex-wrap: wrap; gap: 22px; margin-top: 22px; padding-top: 18px; border-top: 1px solid var(--line-2); font-size: 12px; color: var(--muted); }
.d-guard span { display: inline-flex; align-items: center; gap: 6px; }
.d-guard svg { color: var(--sp); font-size: 15px; }

.tabs { display: flex; border-bottom: 1px solid var(--line); background: #fff; margin-top: 18px; border-radius: var(--radius) var(--radius) 0 0; }
.tabs button { padding: 14px 30px; font-size: 14px; color: var(--ink-2); border-bottom: 2px solid transparent; }
.tabs button.on, .tabs button:hover { color: var(--sp); }
.tabs button.on { border-bottom-color: var(--sp); font-weight: 600; }
.tab-panel { display: none; background: #fff; padding: 24px; border-radius: 0 0 var(--radius) var(--radius); box-shadow: var(--shadow); }
.tab-panel.on { display: block; }
.tab-panel h3 { font-size: 15px; font-weight: 600; margin-bottom: 14px; color: var(--sp); }
.tab-panel p { font-size: 13px; line-height: 2; color: var(--ink-2); margin-bottom: 12px; }
.spec-table { width: 100%; border-collapse: collapse; font-size: 13px; }
.spec-table th, .spec-table td { border: 1px solid var(--line-2); padding: 10px 14px; text-align: left; }
.spec-table th { width: 180px; background: #fafafa; color: var(--muted); font-weight: 400; }
.review { display: flex; gap: 14px; padding: 16px 0; border-bottom: 1px solid var(--line-2); }
.review:last-child { border-bottom: 0; }
.review-av { width: 40px; height: 40px; border-radius: 50%; background: #eee; display: grid; place-items: center; color: #999; font-size: 14px; flex: none; }
.review b { font-size: 13px; }
.review .rstars { color: var(--star); font-size: 12px; margin: 3px 0 6px; }
.review p { font-size: 12.5px; color: var(--ink-2); line-height: 1.8; margin: 0; }
.review small { color: var(--muted-2); font-size: 11px; display: block; margin-top: 7px; }

/* ============ 个人中心 ============ */
.acct-layout { display: grid; grid-template-columns: 200px minmax(0, 1fr); gap: 18px; align-items: start; }
.acct-side { background: #fff; border-radius: var(--radius); box-shadow: var(--shadow); padding-bottom: 14px; }
.acct-user { display: flex; align-items: center; gap: 12px; padding: 18px 16px; border-bottom: 1px solid var(--line-2); }
.acct-av { width: 46px; height: 46px; border-radius: 50%; background: #e9e9e9; color: #a8a8a8; display: grid; place-items: center; font-size: 22px; flex: none; }
.acct-user b { display: block; font-size: 13.5px; }
.acct-user a { font-size: 11.5px; color: var(--muted); display: inline-flex; align-items: center; gap: 4px; margin-top: 3px; }
.acct-user a:hover { color: var(--sp); }
.acct-group { padding: 12px 0 4px; border-bottom: 1px solid var(--line-2); }
.acct-group:last-child { border-bottom: 0; }
.acct-group h4 { font-size: 13px; font-weight: 600; padding: 4px 16px 9px; display: flex; align-items: center; gap: 8px; }
.acct-group h4 svg { color: var(--sp); width: 15px; height: 15px; fill: currentColor; }
.acct-group a { display: block; padding: 7px 16px 7px 38px; font-size: 12.5px; color: var(--ink-2); }
.acct-group a:hover { color: var(--sp); }
.acct-group a.on { color: var(--sp); font-weight: 600; }
.acct-main { background: #fff; border-radius: var(--radius); box-shadow: var(--shadow); padding: 22px 28px 34px; min-height: 470px; }
.acct-main h1 { font-size: 19px; font-weight: 500; }
.acct-main .sub { color: var(--muted); font-size: 12.5px; margin: 3px 0 18px; }
.acct-main hr { border: 0; border-top: 1px solid var(--line-2); margin-bottom: 24px; }
.form-grid { display: grid; grid-template-columns: minmax(0, 1fr) 250px; gap: 34px; }
.form-row { display: flex; align-items: flex-start; gap: 16px; margin-bottom: 20px; }
.form-row > label { width: 108px; flex: none; text-align: right; padding-top: 9px; font-size: 13px; color: var(--ink-2); }
.form-ctl { flex: 1; min-width: 0; }
.form-ctl input[type=text], .form-ctl input[type=email], .form-ctl select {
    width: 100%; max-width: 380px; border: 1px solid #d9d9d9; border-radius: 2px;
    padding: 9px 11px; font-size: 13px; outline: 0; background: #fff;
}
.form-ctl input:focus, .form-ctl select:focus { border-color: var(--sp); }
.form-ctl .hint { font-size: 11.5px; color: var(--muted-2); margin-top: 6px; }
.form-ctl .link { color: #2a7ac4; font-size: 12.5px; text-decoration: underline; margin-left: 8px; }
.form-ctl .link:hover { color: var(--sp); }
.radios { display: flex; gap: 26px; padding-top: 9px; }
.radios label { display: inline-flex; align-items: center; gap: 7px; font-size: 13px; cursor: pointer; }
.radios input { accent-color: var(--sp); width: 15px; height: 15px; }
.birth { display: flex; gap: 10px; }
.birth select { max-width: 120px; }
.btn-save { background: var(--sp); color: #fff; padding: 10px 30px; font-size: 13.5px; font-weight: 600; border-radius: 2px; margin-left: 124px; }
.btn-save:hover { background: var(--sp-dark); }
.av-box { border-left: 1px solid var(--line-2); padding-left: 34px; text-align: center; }
.av-preview { width: 120px; height: 120px; border-radius: 50%; background: #e9e9e9; color: #b0b0b0; display: grid; place-items: center; font-size: 52px; margin: 4px auto 16px; }
.btn-av { border: 1px solid #d9d9d9; background: #fff; padding: 8px 18px; font-size: 12.5px; border-radius: 2px; }
.btn-av:hover { border-color: var(--sp); color: var(--sp); }
.av-box p { font-size: 11.5px; color: var(--muted); margin-top: 12px; line-height: 1.7; }

/* ============ 页脚 ============ */
.footer { background: #fff; border-top: 4px solid var(--sp); margin-top: 12px; }
.footer-mid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 26px; padding: 36px 0 28px; border-bottom: 1px solid var(--line); }
.footer-mid h5 { font-size: 11.5px; font-weight: 700; text-transform: uppercase; color: var(--ink); margin-bottom: 12px; }
.footer-mid a { display: block; font-size: 12px; color: var(--muted); padding: 3px 0; }
.footer-mid a:hover { color: var(--sp); }
.footer-bottom { padding: 22px 0 30px; font-size: 11.5px; color: var(--muted); line-height: 1.9; }
.footer-bottom .fb-company { font-size: 12.5px; font-weight: 600; color: var(--ink-2); margin-bottom: 6px; }
.footer-langs { display: flex; flex-wrap: wrap; gap: 0; margin: 14px 0 10px; }
.footer-langs a { font-size: 11.5px; color: var(--muted); padding: 0 10px; border-right: 1px solid #d5d5d5; line-height: 1.2; }
.footer-langs a:first-child { padding-left: 0; }
.footer-langs a:last-child { border-right: 0; }
.footer-langs a:hover { color: var(--sp); }
.footer-langs a.on { color: var(--sp); font-weight: 600; }

/* ============ Toast / 弹层 ============ */
.toast {
    position: fixed; left: 50%; top: 76px; transform: translate(-50%, -16px);
    background: rgba(30,30,30,.92); color: #fff; padding: 11px 22px; border-radius: 3px;
    font-size: 13px; z-index: 999; opacity: 0; pointer-events: none;
    transition: opacity .22s, transform .22s; box-shadow: var(--shadow-h);
}
.toast.show { opacity: 1; transform: translate(-50%, 0); }
.toast .ok { color: #7ee0a8; margin-right: 8px; }

/* 移动端菜单按钮 */
.burger { display: none; color: #fff; font-size: 22px; padding: 4px 8px; }
.mobile-nav { display: none; background: #fff; border-bottom: 1px solid var(--line); }
.mobile-nav.open { display: flex; flex-wrap: wrap; }
.mobile-nav a { padding: 11px 16px; font-size: 13px; color: var(--ink-2); border-bottom: 1px solid var(--line-2); }

/* ============ 响应式 ============ */
@media (max-width: 1240px) {
    .wrap { padding-inline: 16px; }
}
@media (max-width: 1024px) {
    .mast-in { grid-template-columns: 170px minmax(0,1fr) 60px; gap: 12px; }
    .logo-txt { font-size: 23px; }
    .p-grid { grid-template-columns: repeat(4, minmax(0, 1fr)); }
    .p-grid.cols5 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
    .hero { grid-template-columns: minmax(0, 1fr) 200px; }
    .hero-art { width: 260px; }
    .hero-copy h1 { font-size: 32px; }
    .detail-card { grid-template-columns: 340px minmax(0,1fr); gap: 24px; }
}
@media (max-width: 780px) {
    .util-l { display: none; }
    .util-r { width: 100%; justify-content: flex-end; }
    .mast-in { grid-template-columns: 1fr auto; grid-template-areas: "logo cart" "search search"; padding-top: 12px; gap: 10px; }
    .logo { grid-area: logo; }
    .search-col { grid-area: search; padding-bottom: 8px; }
    .cart-col { grid-area: cart; align-items: center; }
    .burger { display: block; order: -1; }
    .hotwords { display: none; }
    .catnav { display: none; }
    .hero { grid-template-columns: 1fr; }
    .hero-side { grid-template-columns: 1fr 1fr; grid-template-rows: 1fr; }
    .hero-main { height: 260px; }
    .hero-copy h1 { font-size: 27px; }
    .hero-art { width: 210px; height: 190px; right: 0; }
    .hero-art .pic { width: 110px; height: 110px; }
    .hero-art .pic.b { width: 92px; height: 92px; }
    .hero-art .pic.c { width: 78px; height: 78px; }
    .assure { grid-template-columns: repeat(2, 1fr); }
    .assure-item:nth-child(2) { border-right: 0; }
    .assure-item:nth-child(-n+2) { border-bottom: 1px solid var(--line-2); }
    .cats { grid-template-columns: repeat(2, 1fr); }
    .p-grid, .p-grid.cols5, .p-grid.cols4 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
    .list-layout { grid-template-columns: 1fr; }
    .filter { display: none; }
    .filter.open { display: block; }
    .filter-toggle { display: inline-flex !important; }
    .brandwall { grid-template-columns: repeat(2, 1fr); }
    .detail-card { grid-template-columns: 1fr; }
    .acct-layout { grid-template-columns: 1fr; }
    .acct-side { display: none; }
    .form-grid { grid-template-columns: 1fr; }
    .av-box { border-left: 0; border-top: 1px solid var(--line-2); padding: 24px 0 0; }
    .footer-mid { grid-template-columns: repeat(2, 1fr); }
}
.filter-toggle { display: none; align-items: center; gap: 6px; background: #fff; border: 1px solid var(--line); padding: 7px 14px; font-size: 12.5px; border-radius: 2px; margin-bottom: 10px; }
@media (max-width: 560px) {
    .util-r .util-item.hide-sm, .util-r a.hide-sm { display: none; }
    .logo-txt { font-size: 21px; }
    .logo-mark { width: 28px; height: 32px; }
    .p-grid, .p-grid.cols5, .p-grid.cols4 { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 6px; }
    .p-grid.listview { grid-template-columns: 1fr; }
    .p-grid.listview .p-ph { width: 110px; height: 110px; }
    .p-grid.listview .p-add { display: none; }
    .hero-copy { max-width: 62%; }
    .hero-copy h1 { font-size: 23px; }
    .hero-copy p { font-size: 12px; margin: 10px 0 14px; }
    .hero-art { opacity: .7; }
    .hero-side { grid-template-columns: 1fr 1fr; }
    .side-banner { padding: 12px; }
    .side-banner strong { font-size: 15px; }
    .side-banner small { padding-right: 58px; font-size: 10px; }
    .side-banner img { width: 70px; height: 70px; }
    .sortbar { flex-wrap: wrap; }
    .sort-page { display: none; }
    .d-price { font-size: 26px; }
    .d-actions { flex-wrap: wrap; }
    .btn-cart, .btn-buy { flex: 1; justify-content: center; padding-inline: 10px; }
    .form-row { flex-direction: column; gap: 6px; }
    .form-row > label { text-align: left; width: auto; padding-top: 0; }
    .btn-save { margin-left: 0; }
    .tabs button { padding: 12px 16px; font-size: 13px; }
}

/* ==========================================================================
   补充：详情页（Lazada 参照）/ 加购侧栏 / 购物车页
   ========================================================================== */

/* ---------- 详情页：价格与信息行 ---------- */
.d-pricebox { background: #fff8f5; }
.d-price-line { display: flex; align-items: baseline; gap: 12px; flex-wrap: wrap; }
.d-info-rows { display: flex; flex-direction: column; gap: 0; margin: 0 0 6px; }
.d-info-row { display: flex; align-items: flex-start; gap: 16px; padding: 11px 0; border-bottom: 1px dashed var(--line-2); font-size: 12.5px; }
.d-info-row:last-child { border-bottom: 0; }
.d-info-row > label { width: 92px; flex: none; color: var(--muted); }
.d-info-row .val { color: var(--ink-2); line-height: 1.8; }
.d-info-row .val .lnk { color: #2a7ac4; cursor: pointer; }
.d-info-row .val .lnk:hover { color: var(--sp); }
.d-info-row .val .guarantee { display: inline-flex; align-items: center; gap: 6px; margin-right: 16px; }
.d-info-row .val .guarantee svg { color: var(--green); }
.d-chip { display: inline-block; border: 1px solid var(--line); padding: 5px 12px; font-size: 12px; border-radius: 2px; background: #fff; }
.d-chip.on { border-color: var(--sp); color: var(--sp); }
.d-actions { gap: 12px; margin-top: 22px; }
.d-actions .btn-buy { background: var(--sp-soft); color: var(--sp); border: 1px solid var(--sp); order: 0; }
.d-actions .btn-buy:hover { background: #ffe6dd; }
.d-actions .btn-cart { background: var(--sp); color: #fff; border: 1px solid var(--sp); order: 1; }
.d-actions .btn-cart:hover { background: var(--sp-dark); color: #fff; }
.d-side-actions { display: flex; gap: 20px; align-items: center; margin-left: 10px; font-size: 12px; color: var(--muted); }
.d-side-actions span { display: inline-flex; align-items: center; gap: 5px; cursor: pointer; }
.d-side-actions span:hover { color: var(--sp); }

/* 店铺信息条 */
.d-shopbar {
    background: #fff; border-radius: var(--radius); box-shadow: var(--shadow);
    padding: 16px 22px; margin-top: 14px; display: flex; align-items: center; gap: 18px; flex-wrap: wrap;
}
.d-shopbar .sb-logo { width: 42px; height: 42px; border-radius: 50%; background: var(--sp); color: #fff; display: grid; place-items: center; font-weight: 700; font-size: 15px; flex: none; }
.d-shopbar .sb-main { min-width: 160px; }
.d-shopbar .sb-main b { font-size: 14px; display: flex; align-items: center; gap: 8px; }
.d-shopbar .sb-main b em { font-style: normal; font-size: 10px; background: var(--sp); color: #fff; padding: 1px 5px; border-radius: 2px; }
.d-shopbar .sb-main small { color: var(--muted); font-size: 11.5px; }
.d-shopbar .sb-stats { display: flex; gap: 22px; flex: 1; flex-wrap: wrap; }
.d-shopbar .sb-stats span { font-size: 11.5px; color: var(--muted); }
.d-shopbar .sb-stats b { display: block; color: var(--ink); font-size: 14px; font-weight: 600; }
.d-shopbar .sb-go { border: 1px solid var(--sp); color: var(--sp); padding: 8px 18px; font-size: 12.5px; border-radius: 2px; white-space: nowrap; }
.d-shopbar .sb-go:hover { background: var(--sp-soft); }

/* 推荐横条 */
.sponsor { background: #fff; border-radius: var(--radius); box-shadow: var(--shadow); margin-top: 14px; padding: 0 20px 20px; }
.sponsor-head { display: flex; align-items: center; justify-content: space-between; padding: 16px 0 12px; font-size: 15px; font-weight: 600; }
.sponsor-head small { font-size: 11.5px; color: var(--muted-2); font-weight: 400; }
.p-grid.cols6 { grid-template-columns: repeat(6, minmax(0, 1fr)); }

/* 评价区 */
.review-summary { display: flex; gap: 40px; align-items: center; padding: 8px 0 22px; border-bottom: 1px solid var(--line-2); margin-bottom: 8px; flex-wrap: wrap; }
.rs-score { text-align: center; min-width: 130px; }
.rs-score b { font-size: 38px; color: var(--sp); font-weight: 600; line-height: 1; font-variant-numeric: tabular-nums; }
.rs-score .st { color: var(--star); font-size: 17px; letter-spacing: 2px; margin: 8px 0 4px; }
.rs-score small { color: var(--muted); font-size: 11.5px; }
.rs-bars { flex: 1; min-width: 220px; max-width: 420px; }
.rs-bar { display: flex; align-items: center; gap: 10px; font-size: 11.5px; color: var(--muted); margin: 5px 0; }
.rs-bar .track { flex: 1; height: 7px; background: #f0f0f0; border-radius: 4px; overflow: hidden; }
.rs-bar .track i { display: block; height: 100%; background: var(--star); }
.rs-filters { display: flex; gap: 8px; flex-wrap: wrap; padding: 16px 0; }
.rs-filters button { border: 1px solid var(--line); padding: 6px 14px; font-size: 12px; border-radius: 2px; color: var(--ink-2); }
.rs-filters button.on, .rs-filters button:hover { border-color: var(--sp); color: var(--sp); background: var(--sp-soft); }
.review-photos { display: flex; gap: 7px; margin-top: 10px; }
.review-photos img { width: 54px; height: 54px; object-fit: cover; border: 1px solid var(--line-2); border-radius: 2px; }

/* ---------- 加购后右侧购物车侧栏 ---------- */
.cd-mask { position: fixed; inset: 0; background: rgba(0,0,0,.28); z-index: 190; display: none; }
.cd-mask.open { display: block; }
.cart-drawer {
    position: fixed; top: 0; right: 0; height: 100vh; width: 306px; z-index: 200;
    background: #fff; box-shadow: -8px 0 32px rgba(0,0,0,.16);
    display: flex; flex-direction: column;
    transform: translateX(102%); transition: transform .26s cubic-bezier(.2,.7,.2,1);
}
.cart-drawer.open { transform: translateX(0); }
.cd-head { display: flex; align-items: center; justify-content: space-between; padding: 15px 16px; border-bottom: 1px solid var(--line); }
.cd-head b { font-size: 14px; }
.cd-head button { color: var(--muted); font-size: 20px; line-height: 1; padding: 0 4px; }
.cd-head button:hover { color: var(--sp); }
.cd-total { padding: 16px; border-bottom: 1px solid var(--line-2); background: #fffaf8; }
.cd-total .lab { font-size: 12px; color: var(--muted); }
.cd-total .amt { font-size: 21px; color: var(--sp); font-weight: 600; font-variant-numeric: tabular-nums; }
.cd-actions { padding: 12px 16px; display: flex; flex-direction: column; gap: 8px; border-bottom: 1px solid var(--line-2); }
.cd-actions button { padding: 10px; font-size: 13px; font-weight: 600; border-radius: 2px; text-align: center; }
.cd-actions .check { background: var(--sp); color: #fff; }
.cd-actions .check:hover { background: var(--sp-dark); }
.cd-actions .go { background: #fff; color: var(--sp); border: 1px solid var(--sp); }
.cd-actions .go:hover { background: var(--sp-soft); }
.cd-body { flex: 1; overflow-y: auto; padding: 4px 16px 20px; }
.cd-group-title { font-size: 12px; font-weight: 700; padding: 14px 0 8px; border-bottom: 1px solid var(--line-2); display: flex; align-items: center; gap: 7px; }
.cd-group-title em { font-style: normal; font-size: 10px; background: var(--sp); color: #fff; padding: 1px 5px; border-radius: 2px; }
.cd-item { display: grid; grid-template-columns: 18px 64px minmax(0, 1fr); gap: 10px; padding: 12px 0; border-bottom: 1px solid var(--line-2); align-items: start; }
.cd-item .ckbox { margin-top: 22px; }
.cd-item img { width: 64px; height: 64px; object-fit: cover; border: 1px solid var(--line-2); }
.cd-item .nm { font-size: 12px; line-height: 1.5; color: var(--ink-2); display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.cd-item .pr { color: var(--sp); font-size: 13px; font-weight: 600; margin-top: 5px; }
.cd-item .cd-qty { display: inline-flex; align-items: center; gap: 0; margin-top: 6px; border: 1px solid var(--line); }
.cd-item .cd-qty button { width: 24px; height: 22px; font-size: 13px; color: var(--muted); }
.cd-item .cd-qty span { min-width: 30px; text-align: center; font-size: 12px; border-left: 1px solid var(--line); border-right: 1px solid var(--line); }
.cd-item .cd-del { font-size: 11px; color: var(--muted-2); margin-left: 10px; }
.cd-item .cd-del:hover { color: var(--sp); }
.cd-empty { text-align: center; color: var(--muted); font-size: 12.5px; padding: 60px 10px; }
.cd-foot { padding: 12px 16px; border-top: 1px solid var(--line); font-size: 11.5px; color: var(--muted); text-align: center; }

/* ---------- 购物车页（勾选 + 订单摘要） ---------- */
.cart-layout { display: grid; grid-template-columns: minmax(0, 1fr) 290px; gap: 14px; align-items: start; }
.cart-left { background: #fff; border-radius: var(--radius); box-shadow: var(--shadow); min-height: 220px; }
.cart-bar { display: flex; align-items: center; justify-content: space-between; padding: 14px 18px; border-bottom: 1px solid var(--line-2); font-size: 12.5px; }
.cart-bar .l { display: flex; align-items: center; gap: 9px; font-weight: 600; }
.cart-bar .l small { color: var(--muted); font-weight: 400; }
.cart-bar .del { color: var(--muted); display: inline-flex; align-items: center; gap: 5px; font-size: 12px; }
.cart-bar .del:hover { color: var(--sp); }
.cart-shop { display: flex; align-items: center; gap: 9px; padding: 11px 18px; border-bottom: 1px solid var(--line-2); font-size: 12.5px; font-weight: 600; }
.cart-shop em { font-style: normal; font-size: 10px; background: var(--sp); color: #fff; padding: 1px 5px; border-radius: 2px; }
.cart-shop .chat { margin-left: auto; color: var(--sp); border: 1px solid var(--sp); padding: 3px 10px; font-size: 11px; font-weight: 400; border-radius: 2px; }
.cart-row {
    display: grid; grid-template-columns: 18px minmax(0, 1fr) 108px 126px 100px 54px;
    gap: 12px; align-items: center; padding: 16px 18px; border-bottom: 1px solid var(--line-2);
}
.cart-row:last-child { border-bottom: 0; }
.cart-row .ckbox { align-self: center; }
.cart-p { display: flex; gap: 12px; align-items: center; min-width: 0; }
.cart-p img { width: 76px; height: 76px; object-fit: cover; border: 1px solid var(--line-2); flex: none; }
.cart-p div { min-width: 0; }
.cart-p a { font-size: 12.5px; line-height: 1.5; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.cart-p a:hover { color: var(--sp); }
.cart-p small { display: block; color: var(--muted-2); font-size: 11.5px; margin-top: 6px; }
.cart-price { color: var(--sp); font-size: 14px; font-weight: 600; }
.cart-price s { display: block; color: var(--muted-2); font-size: 11px; font-weight: 400; margin-top: 4px; }
.cart-sub { color: var(--sp); font-size: 14px; font-weight: 600; }
.cart-del { color: var(--muted); font-size: 12px; }
.cart-del:hover { color: var(--sp); }
input.ckbox { appearance: none; width: 16px; height: 16px; border: 1px solid #c8c8c8; border-radius: 2px; flex: none; position: relative; cursor: pointer; background: #fff; }
input.ckbox:checked { background: var(--sp); border-color: var(--sp); }
input.ckbox:checked::after { content: '✓'; position: absolute; inset: -2px 0 0; text-align: center; color: #fff; font-size: 12px; font-weight: 700; }
.order-summary { background: #fff; border-radius: var(--radius); box-shadow: var(--shadow); padding: 18px; }
.order-summary h3 { font-size: 15px; font-weight: 600; padding-bottom: 14px; border-bottom: 1px solid var(--line-2); }
.os-row { display: flex; align-items: center; justify-content: space-between; padding: 9px 0; font-size: 12.5px; color: var(--muted); }
.os-row b { color: var(--ink); font-weight: 500; font-variant-numeric: tabular-nums; }
.os-row .green { color: var(--green); }
.os-row.total { border-top: 1px solid var(--line-2); margin-top: 8px; padding-top: 16px; font-size: 13.5px; color: var(--ink); }
.os-row.total b { color: var(--sp); font-size: 20px; font-weight: 600; }
.os-check { width: 100%; background: var(--sp); color: #fff; padding: 12px; font-size: 13.5px; font-weight: 600; border-radius: 2px; margin-top: 12px; }
.os-check:hover { background: var(--sp-dark); }
.os-note { font-size: 11px; color: var(--muted-2); text-align: center; margin-top: 10px; line-height: 1.7; }
.cart-empty { background: #fff; padding: 76px 20px; text-align: center; color: var(--muted); border-radius: 2px; }
.cart-empty p { margin: 14px 0 20px; font-size: 14px; }

@media (max-width: 1024px) {
    .p-grid.cols6 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
    .cart-row { grid-template-columns: 18px minmax(0, 1fr) 90px 110px 84px 44px; gap: 8px; }
}
@media (max-width: 780px) {
    .p-grid.cols6 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
    .cart-layout { grid-template-columns: 1fr; }
    .cart-row { grid-template-columns: 18px minmax(0, 1fr) 84px; gap: 10px; }
    .cart-row .cart-qtycell { grid-column: 2; }
    .cart-row .cart-sub, .cart-row .cart-del { display: none; }
    .d-side-actions { display: none; }
}
@media (max-width: 560px) {
    .p-grid.cols6 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .cart-drawer { width: 100%; }
    .cart-row { grid-template-columns: 16px minmax(0, 1fr) 78px; padding: 12px; }
    .cart-p img { width: 58px; height: 58px; }
    .review-summary { gap: 18px; }
    .d-actions { flex-wrap: nowrap; }
    .d-actions .btn-buy, .d-actions .btn-cart { padding: 11px 10px; font-size: 13px; }
}

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