/* ===== 订单 / 支付 / 售后（orders app） ===== */
.order-row {
    display: flex;
    justify-content: space-between;
    padding: 10px 0;
    border-bottom: 1px solid var(--border, #eee);
    font-size: 0.95rem;
}
.order-row span { color: var(--text-muted); }

.pay-channel-list { display: flex; gap: 12px; flex-wrap: wrap; }
.pay-channel {
    flex: 1;
    min-width: 140px;
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 14px 18px;
    border: 1px solid var(--border, #e5e7eb);
    border-radius: 12px;
    text-decoration: none;
    color: var(--text);
    font-weight: 600;
    transition: .2s;
}
.pay-channel:hover { border-color: var(--accent); transform: translateY(-2px); }
.pay-wechat:hover { border-color: #07c160; box-shadow: 0 6px 18px rgba(7,193,96,.18); }
.pay-alipay:hover { border-color: #1677ff; box-shadow: 0 6px 18px rgba(22,119,255,.18); }
.pay-ico { font-size: 1.3rem; }

.pay-dev-note {
    margin-top: 16px;
    padding: 12px 14px;
    background: rgba(255,179,71,.12);
    border: 1px solid rgba(255,179,71,.4);
    border-radius: 10px;
    font-size: 0.85rem;
    color: var(--text-muted);
    line-height: 1.6;
}

.status-badge {
    display: inline-block;
    padding: 3px 10px;
    border-radius: 999px;
    font-size: 0.78rem;
    font-weight: 600;
}
.status-pending { background: rgba(255,179,71,.18); color: #d9890a; }
.status-paid { background: rgba(52,199,89,.18); color: #1a9b3f; }
.status-closed { background: rgba(120,120,120,.18); color: #666; }
.status-refunding { background: rgba(91,140,255,.18); color: #3a6df0; }
.status-refunded { background: rgba(120,120,120,.18); color: #666; }

.delivery-box {
    margin-top: 18px;
    padding: 16px;
    border: 1px solid rgba(52,199,89,.4);
    background: rgba(52,199,89,.08);
    border-radius: 12px;
}
.delivery-box h4 { margin: 0 0 8px; }
.delivery-hint {
    margin: 10px 0 0;
    font-size: 0.78rem;
    color: var(--text-muted);
    line-height: 1.5;
}

.form-textarea {
    width: 100%;
    padding: 10px;
    border: 1px solid var(--border, #e5e7eb);
    border-radius: 10px;
    font-family: inherit;
    resize: vertical;
    background: var(--bg, #fff);
    color: var(--text);
}

.aftersale-item {
    display: flex;
    gap: 10px;
    align-items: center;
    padding: 8px 0;
    border-bottom: 1px solid var(--border, #eee);
    font-size: 0.88rem;
}

.order-list { display: flex; flex-direction: column; gap: 12px; }
.order-card {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 16px;
    border: 1px solid var(--border, #e5e7eb);
    border-radius: 14px;
    text-decoration: none;
    color: var(--text);
    transition: .2s;
    background: var(--bg, #fff);
}
.order-card:hover {
    border-color: var(--accent);
    transform: translateY(-2px);
    box-shadow: 0 8px 22px rgba(0,0,0,.08);
}
.order-card-title { font-weight: 600; margin-bottom: 4px; }
.order-card-meta { font-size: 0.82rem; color: var(--text-muted); }
.order-card-right { text-align: right; }
.order-card-amount { font-weight: 700; color: var(--accent); margin-bottom: 6px; }

/* ===== 购物车页 ===== */
.cart-list { display: flex; flex-direction: column; gap: 10px; }
.cart-row {
    display: grid;
    grid-template-columns: 28px 1fr 110px 80px;
    align-items: center;
    gap: 14px;
    padding: 14px 16px;
    border: 1px solid var(--border, #e5e7eb);
    border-radius: 14px;
    background: var(--bg, #fff);
}
.cart-row--head { font-size: 0.82rem; color: var(--text-muted); border: none; background: transparent; padding-bottom: 0; }
.cart-col-head { font-weight: 600; letter-spacing: .03em; }
.cart-row:not(.cart-row--head):hover { border-color: var(--primary-soft, #fed7aa); background: var(--primary-light, #ffedd5); }
.cart-check { width: 18px; height: 18px; accent-color: var(--primary, #c2410c); cursor: pointer; }
.cart-item-main { display: flex; align-items: center; gap: 14px; text-decoration: none; color: var(--text); min-width: 0; }
.cart-thumb {
    flex: none; width: 56px; height: 56px; border-radius: 12px; overflow: hidden;
    display: grid; place-items: center; color: #fff; font-weight: 800; font-size: 1.3rem;
}
.cart-thumb--premium { background: linear-gradient(135deg, #7c2d12, #c2410c, #fb923c); }
.cart-thumb--discount { background: linear-gradient(135deg, #064e3b, #047857, #10b981); }
.cart-thumb--normal { background: linear-gradient(135deg, #1e293b, #334155, #475569); }
.cart-item-info { display: flex; flex-direction: column; min-width: 0; }
.cart-item-title { font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; transition: color .2s; }
.cart-item-cat { font-size: 0.78rem; color: var(--text-muted); }
.cart-item-main:hover .cart-item-title { color: var(--primary); }
.cart-col-price { font-weight: 700; color: var(--accent); }
.cart-remove { color: var(--text-muted); font-size: 0.85rem; text-decoration: none; transition: color .2s; }
.cart-remove:hover { color: #d9480f; }
.cart-footer {
    display: flex; align-items: center; justify-content: space-between; gap: 16px;
    margin-top: 18px; padding: 18px 20px; border-radius: 16px;
    background: var(--bg-card, #fff); border: 1px solid var(--border, #e5e7eb);
    position: sticky; bottom: 16px;
}
.cart-total { font-size: 0.95rem; color: var(--text-secondary); }
.cart-total strong { color: var(--accent); }
.cart-total-num { color: var(--primary); font-size: 1.4rem; font-weight: 800; }

/* ===== 结账页（checkout） ===== */
.co-title { font-size: 1.05rem; font-weight: 800; color: var(--text); margin: 4px 0 14px; }
.co-qty { font-size: .8rem; color: var(--text-muted); font-weight: 600; margin-left: 4px; }
.co-info {
    margin-top: 16px; padding: 18px 20px;
    background: var(--bg-card, #fff); border: 1px solid var(--border); border-radius: 16px;
}
.co-status { color: var(--primary); }
.co-info .cart-summary-row { border-bottom: 1px dashed var(--border); }
.co-info .cart-summary-row:last-child { border-bottom: none; }

/* ===== 订单明细（结账 / 详情） ===== */
.checkout-items { margin: 6px 0 4px; border: 1px solid var(--border, #e5e7eb); border-radius: 12px; overflow: hidden; }
.checkout-item { display: flex; justify-content: space-between; padding: 10px 14px; border-bottom: 1px solid var(--border, #eee); font-size: 0.92rem; }
.checkout-item:last-child { border-bottom: none; }
.checkout-item-sub { color: var(--text-muted); }

/* ===== 头部购物车角标 ===== */
.header-cart {
    position: relative; display: inline-flex; align-items: center; justify-content: center;
    width: 38px; height: 38px; border-radius: 10px; color: var(--text, #333);
    text-decoration: none; transition: background .2s, color .2s;
}
.header-cart:hover { background: var(--primary-light, #ffedd5); color: var(--primary-darker, #7c2d12); }
.cart-badge {
    position: absolute; top: -4px; right: -4px; min-width: 18px; height: 18px; padding: 0 5px;
    border-radius: 999px; background: var(--primary, #c2410c); color: #fff;
    font-size: 0.7rem; font-weight: 700; display: grid; place-items: center; line-height: 1;
}

/* ===== 商品卡「加购」 ===== */
.card-add-cart {
    font-size: 0.82rem; font-weight: 600; color: var(--primary, #c2410c);
    border: 1px solid var(--primary-soft, #fed7aa); background: var(--primary-light, #ffedd5);
    padding: 5px 12px; border-radius: 999px; text-decoration: none; transition: .2s;
}
.card-add-cart:hover { background: var(--primary, #c2410c); color: #fff; border-color: var(--primary, #c2410c); }

@media (max-width: 880px) {
    .cart-layout { grid-template-columns: 1fr; }
    .cart-side { position: static; }
    .cart-summary { box-shadow: none; }
}
@media (max-width: 720px) {
    .cart-rec-grid { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 560px) {
    .cart-card { flex-wrap: wrap; gap: 12px; }
    .cart-card-price { margin-left: auto; }
    .cart-rec-grid { grid-template-columns: 1fr; }
    .cart-head { flex-wrap: wrap; }
    .cart-head-count { margin-left: 0; }
    .cart-continue { margin-left: auto; }
    .bs-card { padding: 22px 18px; }
}

/* ===== 购物车页头 / 空态 ===== */
.cart-head { display: flex; align-items: center; gap: 14px; margin-bottom: 24px; }
.cart-head-ico {
    width: 44px; height: 44px; border-radius: 13px; flex: none;
    display: grid; place-items: center; color: #fff;
    background: linear-gradient(135deg, #9a3412, #c2410c);
    box-shadow: 0 6px 16px rgba(194, 65, 12, .25);
}
.cart-head-ico svg { width: 24px; height: 24px; }
.cart-head-titles { display: flex; flex-direction: column; gap: 2px; }
.cart-eyebrow { font-size: .74rem; font-weight: 700; letter-spacing: .1em; color: var(--primary); }
.cart-head-title { font-size: 1.6rem; font-weight: 800; color: var(--text); margin: 0; }
.cart-head-count {
    margin-left: auto; font-size: 0.82rem; color: var(--text-muted);
    background: var(--bg-card, #fff); border: 1px solid var(--border);
    padding: 4px 12px; border-radius: 999px;
}
.cart-continue { margin-left: 12px; color: var(--primary); font-weight: 600; text-decoration: none; transition: opacity .2s; }
.cart-continue:hover { opacity: .7; text-decoration: underline; }

/* ===== 购物车两栏布局 ===== */
.cart-layout { display: grid; grid-template-columns: 1fr 320px; gap: 24px; align-items: start; }
.cart-main { min-width: 0; }
.cart-toolbar {
    display: flex; align-items: center; gap: 10px;
    font-size: .88rem; color: var(--text-secondary); margin-bottom: 14px;
    cursor: pointer;
}
.cart-toolbar-count { color: var(--text-muted); }
.cart-toolbar-count b { color: var(--primary); }
.cart-cards { display: flex; flex-direction: column; gap: 12px; }

.cart-card {
    position: relative;
    display: flex; align-items: center; gap: 16px;
    padding: 16px; border: 1px solid var(--border); border-radius: 16px;
    background: var(--bg-card, #fff); transition: all .2s;
}
.cart-card:hover { border-color: var(--primary-soft, #fed7aa); box-shadow: 0 8px 22px rgba(15,23,42,.06); }
.cart-thumb {
    position: relative; flex: none; width: 64px; height: 64px; border-radius: 14px; overflow: hidden;
    display: grid; place-items: center; color: #fff; font-weight: 800; font-size: 1.4rem;
}
.cart-thumb--premium { background: linear-gradient(135deg, #7c2d12, #c2410c, #fb923c); }
.cart-thumb--discount { background: linear-gradient(135deg, #064e3b, #047857, #10b981); }
.cart-thumb--normal { background: linear-gradient(135deg, #1e293b, #334155, #475569); }
.cart-thumb-badge {
    position: absolute; right: 4px; bottom: 4px;
    font-size: .62rem; font-weight: 700; color: #fff;
    background: rgba(15,23,42,.55); backdrop-filter: blur(4px);
    padding: 1px 6px; border-radius: 999px; letter-spacing: .02em;
}
.cart-card-body { flex: 1; min-width: 0; }
.cart-card-titleline { display: flex; align-items: center; gap: 8px; }
.cart-card-title { font-weight: 700; font-size: 1rem; color: var(--text); text-decoration: none; transition: color .2s; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.cart-card-title:hover { color: var(--primary); }
.cart-rec-tag { flex: none; font-size: .68rem; font-weight: 700; color: var(--primary); background: var(--primary-light, #ffedd5); border: 1px solid var(--primary-soft, #fed7aa); padding: 1px 7px; border-radius: 999px; }
.cart-card-cat { font-size: .78rem; color: var(--text-muted); margin-top: 3px; }
.cart-card-meta { font-size: .76rem; color: var(--text-secondary); margin-top: 6px; }
.cart-card-price { font-weight: 800; font-size: 1.1rem; color: var(--accent); flex: none; }
.cart-remove { flex: none; color: var(--text-muted); font-size: .84rem; text-decoration: none; transition: color .2s; }
.cart-remove:hover { color: #d9480f; }

/* ===== 订单摘要侧栏 ===== */
.cart-side { position: sticky; top: 90px; }
.cart-summary {
    background: var(--bg-card, #fff); border: 1px solid var(--border);
    border-radius: 18px; padding: 22px; box-shadow: 0 10px 30px rgba(15,23,42,.06);
}
.cart-summary-title { margin: 0 0 16px; font-size: 1.1rem; font-weight: 800; color: var(--text); }
.cart-summary-row { display: flex; justify-content: space-between; align-items: center; font-size: .9rem; color: var(--text-secondary); padding: 7px 0; }
.cart-summary-row b { color: var(--text); }
.cart-summary-amount { font-weight: 800; color: var(--primary); font-size: 1.25rem; }
.cart-checkout-btn { width: 100%; margin: 14px 0 4px; }
.cart-get { margin-top: 18px; padding-top: 16px; border-top: 1px dashed var(--border); }
.cart-get-title { font-size: .82rem; font-weight: 700; color: var(--text-muted); margin-bottom: 10px; letter-spacing: .03em; }
.cart-get-list { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 9px; }
.cart-get-list li { display: flex; align-items: center; gap: 9px; font-size: .85rem; color: var(--text-secondary); }
.cart-get-ico { width: 18px; height: 18px; flex: none; border-radius: 50%; background: rgba(7,193,96,.15); color: #1a9b3f; display: grid; place-items: center; font-size: .7rem; font-weight: 800; }
.cart-trust {
    display: flex; gap: 9px; align-items: flex-start; margin-top: 16px;
    padding: 12px; border-radius: 12px; background: var(--primary-light, #ffedd5);
    font-size: .76rem; color: var(--primary-darker, #7c2d12); line-height: 1.5;
}
.cart-trust svg { width: 18px; height: 18px; flex: none; margin-top: 1px; color: var(--primary); }

/* ===== 推荐位 ===== */
.cart-rec { margin-top: 40px; }
.cart-rec-head { font-size: 1.1rem; font-weight: 800; color: var(--text); margin-bottom: 16px; }
.cart-rec-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 14px; }
.cart-rec-card {
    display: flex; align-items: center; gap: 12px; padding: 12px;
    border: 1px solid var(--border); border-radius: 14px; background: var(--bg-card, #fff);
    transition: all .2s;
}
.cart-rec-card:hover { border-color: var(--primary-soft, #fed7aa); transform: translateY(-2px); box-shadow: 0 8px 20px rgba(15,23,42,.07); }
.cart-rec-thumb { flex: none; width: 46px; height: 46px; border-radius: 11px; display: grid; place-items: center; color: #fff; font-weight: 800; font-size: 1.1rem; }
.cart-rec-info { flex: 1; min-width: 0; }
.cart-rec-name { font-size: .85rem; font-weight: 600; color: var(--text); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.cart-rec-price { font-size: .82rem; font-weight: 700; color: var(--accent); margin-top: 2px; }
.cart-rec-add {
    flex: none; font-size: .78rem; font-weight: 700; color: var(--primary, #c2410c);
    border: 1px solid var(--primary-soft, #fed7aa); background: var(--primary-light, #ffedd5);
    padding: 5px 11px; border-radius: 999px; text-decoration: none; transition: .2s;
}
.cart-rec-add:hover { background: var(--primary, #c2410c); color: #fff; border-color: var(--primary, #c2410c); }

.cart-empty {
    text-align: center; padding: 56px 24px; border: 1px dashed var(--border);
    border-radius: 18px; background: var(--bg-card, #fff);
}
.cart-empty-ico {
    display: inline-grid; place-items: center; width: 72px; height: 72px;
    border-radius: 50%; background: var(--primary-light, #ffedd5); color: var(--primary);
    margin-bottom: 16px;
}
.cart-empty-ico svg { width: 34px; height: 34px; }
.cart-empty-text { font-size: 1.15rem; font-weight: 700; color: var(--text); margin: 0 0 6px; }
.cart-empty-sub { font-size: 0.85rem; color: var(--text-muted); margin: 0 0 20px; }

/* ===== 选择支付页（buy_select） ===== */
.bs-card {
    background: var(--bg-card, #fff);
    border: 1px solid var(--border);
    border-radius: 20px;
    padding: 32px;
    box-shadow: 0 10px 30px rgba(15, 23, 42, .06);
}
.bs-head { text-align: center; margin-bottom: 24px; }
.bs-eyebrow {
    display: inline-block; font-size: .76rem; font-weight: 700; letter-spacing: .08em;
    color: var(--primary); background: var(--primary-light, #ffedd5);
    padding: 4px 12px; border-radius: 999px; margin-bottom: 10px;
}
.bs-title { font-size: 1.5rem; font-weight: 800; color: var(--text); margin: 0 0 8px; }
.bs-sub { font-size: .85rem; color: var(--text-muted); line-height: 1.6; margin: 0; }

.bs-product {
    display: flex; align-items: center; gap: 14px;
    padding: 16px; border: 1px solid var(--border); border-radius: 14px;
    background: var(--bg, #f8fafc);
}
.bs-thumb {
    width: 62px; height: 62px; border-radius: 14px; flex: none;
    display: grid; place-items: center; color: #fff; font-weight: 800; font-size: 1.5rem;
}
.bs-thumb--premium { background: linear-gradient(135deg, #7c2d12, #c2410c, #fb923c); }
.bs-thumb--discount { background: linear-gradient(135deg, #064e3b, #047857, #10b981); }
.bs-thumb--normal { background: linear-gradient(135deg, #1e293b, #334155, #475569); }
.bs-product-info { flex: 1; min-width: 0; }
.bs-product-title { font-weight: 700; font-size: 1rem; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.bs-product-cat { font-size: .78rem; color: var(--text-muted); margin-top: 2px; }
.bs-product-qty { font-size: .85rem; color: var(--text-secondary); font-weight: 600; }

.bs-amount {
    display: flex; align-items: center; justify-content: space-between;
    margin: 18px 0 6px; padding: 14px 16px; border-radius: 14px;
    background: linear-gradient(135deg, rgba(194, 65, 12, .08), rgba(194, 65, 12, .02));
    border: 1px solid var(--primary-soft, #fed7aa);
}
.bs-amount-label { font-size: .9rem; color: var(--text-secondary); }
.bs-amount-value { font-size: 1.6rem; font-weight: 800; color: var(--primary); }

.bs-section-label { font-size: .82rem; font-weight: 700; color: var(--text-muted); margin: 22px 0 10px; letter-spacing: .03em; }

.bs-channels { display: flex; flex-direction: column; gap: 12px; }
.bs-channel {
    display: flex; align-items: center; gap: 14px;
    padding: 16px 18px; border: 1.5px solid var(--border); border-radius: 14px;
    text-decoration: none; color: var(--text); background: var(--bg-card, #fff);
    transition: all .2s cubic-bezier(.16, 1, .3, 1); cursor: pointer;
}
.bs-channel:hover { transform: translateY(-2px); }
.bs-channel--wechat:hover { border-color: #07c160; box-shadow: 0 8px 22px rgba(7, 193, 96, .18); }
.bs-channel--alipay:hover { border-color: #1677ff; box-shadow: 0 8px 22px rgba(22, 119, 255, .18); }
.bs-channel-ico { width: 42px; height: 42px; border-radius: 12px; display: grid; place-items: center; flex: none; }
.bs-channel--wechat .bs-channel-ico { background: #07c160; }
.bs-channel--alipay .bs-channel-ico { background: #1677ff; }
.bs-ico-svg { width: 24px; height: 24px; }
.bs-channel-text { flex: 1; display: flex; flex-direction: column; min-width: 0; }
.bs-channel-name { font-weight: 700; font-size: 1rem; }
.bs-channel-desc { font-size: .76rem; color: var(--text-muted); margin-top: 1px; }
.bs-channel-arrow { font-size: 1.5rem; color: var(--text-muted); transition: transform .2s; }
.bs-channel:hover .bs-channel-arrow { transform: translateX(3px); color: var(--primary); }

.bs-devnote {
    display: flex; gap: 10px; align-items: flex-start;
    margin-top: 16px; padding: 12px 14px;
    background: rgba(255, 179, 71, .12); border: 1px solid rgba(255, 179, 71, .4); border-radius: 12px;
    font-size: .82rem; color: var(--text-secondary); line-height: 1.6;
}
.bs-devnote-ico { width: 18px; height: 18px; color: #d9890a; flex: none; margin-top: 1px; }
.bs-back { width: 100%; margin-top: 18px; }
