.shop-home { max-width: 1600px; margin: 0 auto; padding: 8px 20px 60px; }
.search-input { display: none !important; }
/* 去掉背景图 */
body { background: #eef0f4 !important; background-image: none !important; }
.uc-bg { display: none !important; }
/* 导航栏字体加大 */
.navbar { font-size: 16px; }
.navbar .navbar-brand { font-size: 20px; }
.navbar .nav-link { font-size: 16px; }
.navbar .btn { font-size: 14px; padding: 8px 16px; }

/* 搜索大卡 */
.hero-card {
    background: rgb(255 255 255 / .82);
    backdrop-filter: blur(24px);
    border: 1px solid rgb(255 255 255 / .4);
    border-radius: 20px;
    padding: 18px 22px;
    box-shadow: 0 10px 36px rgb(31 45 70 / .1);
}
.hero-head { display: flex; align-items: center; gap: 8px; color: #58606e; font-size: 14px; margin-bottom: 14px; }
.hero-input-row { display: flex; gap: 12px; align-items: center; }
.hero-input {
    flex: 1; border: 1px solid rgb(0 0 0 / .08); background: rgb(255 255 255 / .55);
    border-radius: 10px; padding: 11px 16px; font-size: 14px; color: #1f2733; outline: none;
}
.hero-input:focus { border-color: #4c96e0; box-shadow: 0 0 0 3px rgb(76 150 224 / .15); }
.hero-btn {
    flex: 0 0 auto; background: #22c55e; color: #fff; border: none; border-radius: 10px;
    padding: 11px 28px; font-size: 14px; cursor: pointer;
}
.hero-btn:hover { background: #16a34a; }
.notice-bar { font-size: 13px; line-height: 1.8; color: #58606e; }

/* 两栏布局 */
.home-layout { display: flex; gap: 20px; align-items: flex-start; margin-top: 20px; }
.side-card {
    width: 290px; flex: 0 0 290px; background: rgb(255 255 255 / .68);
    backdrop-filter: blur(24px); border: 1px solid rgb(255 255 255 / .4);
    border-radius: 20px; box-shadow: 0 10px 36px rgb(31 45 70 / .1);
    padding: 16px 12px; max-height: calc(100vh - 180px); overflow-y: auto;
    position: sticky; top: 80px;
}
.main-card {
    flex: 1; min-width: 0; background: rgb(255 255 255 / .68);
    backdrop-filter: blur(24px); border: 1px solid rgb(255 255 255 / .4);
    border-radius: 20px; box-shadow: 0 10px 36px rgb(31 45 70 / .1);
    padding: 16px 20px 20px; min-height: 420px;
}
.side-title, .main-title {
    display: flex; align-items: center; gap: 8px; font-size: 15px; font-weight: 600;
    color: #1f2733; margin-bottom: 16px; padding: 2px 8px;
}
.title-dot { width: 9px; height: 9px; border-radius: 50%; background: #4c96e0; flex: 0 0 9px; }

/* 分类树 */
.cate-tree { display: flex; flex-direction: column; gap: 8px; }
.cate-link {
    display: flex; align-items: center; gap: 10px; padding: 14px 12px; border-radius: 10px;
    color: #1f2733; cursor: pointer; text-decoration: none; font-size: 14px;
    transition: background .15s;
}
.cate-link:hover { background: rgb(0 0 0 / .05); }
.cate-link.is-active { color: #e8463f; font-weight: 600; }
.cate-icon {
    width: 22px; height: 22px; border-radius: 6px; flex: 0 0 22px;
    background: #eee center/cover no-repeat;
}
.cate-name { flex: 1; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }

/* 商品表格行 */
.goods-body { display: flex !important; flex-direction: column !important; padding: 0 !important; gap: 0 !important; }
.goods-thead {
    display: flex; align-items: center; padding: 10px 8px; color: #58606e;
    font-size: 13px; border-bottom: 1px solid rgb(0 0 0 / .08);
}
.th-name, .td-name { flex: 1; min-width: 0; }
.th-num, .td-num { width: 90px; text-align: center; flex: 0 0 90px; }
.th-op, .td-op { width: 110px; text-align: center; flex: 0 0 110px; }

.goods-row {
    display: flex !important; align-items: center; width: 100% !important;
    flex: 0 0 100% !important; padding: 16px 8px;
    border-bottom: 1px solid rgb(0 0 0 / .06); transition: background .15s;
}
.goods-row:hover { background: rgb(0 0 0 / .03); }

.td-name { display: flex; align-items: center; gap: 10px; text-decoration: none; color: #1f2733; line-height: 1.5; }
.goods-thumb { font-size: 18px; flex: 0 0 22px; text-align: center; }
.goods-name { font-size: 14px; color: #222; }
.goods-tag {
    font-size: 12px; padding: 2px 10px; border-radius: 6px; white-space: nowrap;
    background: rgb(0 0 0 / .05); color: #666;
}
.td-price { color: #ff5ca8; font-weight: 600; }
.td-stock { color: #22c55e; font-weight: 500; }
.td-warranty { color: #999; font-size: 13px; }

.op-btn {
    display: inline-flex; align-items: center; gap: 5px; padding: 5px 14px; border-radius: 8px;
    font-size: 13px; text-decoration: none; border: 1px solid transparent; white-space: nowrap;
}
.op-buy { color: #22c55e; border-color: #22c55e; }
.op-buy:hover { background: #22c55e; color: #fff; }
.op-disabled { color: #999; border-color: #ddd; }

.goods-empty { padding: 40px 0; text-align: center; color: #999; font-size: 14px; }
.goods-row.is-disabled { opacity: .5; }

/* 商品详情页 */
.item-detail-layout { display: flex; gap: 24px; align-items: flex-start; margin-top: 10px; }
.item-detail-left { flex: 1; min-width: 0; }
.item-detail-title {
    font-size: 20px; font-weight: 700; color: #1a1a1a;
    margin-bottom: 16px; padding: 14px 18px;
    background: #fff; border-radius: 12px;
    border: 1px solid rgb(0 0 0 / .06);
}
.item-detail-content {
    line-height: 1.8; font-size: 14px; color: #333;
    background: #fff; border-radius: 12px;
    border: 1px solid rgb(0 0 0 / .06);
    padding: 20px;
}
.item-detail-content > div,
.item-detail-content > section,
.item-detail-content > p {
    margin-bottom: 16px; padding-bottom: 16px;
    border-bottom: 1px solid rgb(0 0 0 / .06);
}
.item-detail-content > div:last-child,
.item-detail-content > section:last-child,
.item-detail-content > p:last-child {
    border-bottom: none; margin-bottom: 0; padding-bottom: 0;
}
.item-detail-content img {
    max-width: 100%; height: auto;
    border-radius: 10px;
}
.item-detail-content h2,
.item-detail-content h3,
.item-detail-content h4 {
    margin: 16px 0 10px;
}
.item-buy-card {
    width: 380px; flex: 0 0 380px;
    padding: 18px; position: sticky; top: 20px;
    background: #fff;
    border: 1px solid rgb(0 0 0 / .08);
    border-radius: 14px;
    box-shadow: 0 8px 24px rgb(31 45 70 / .08);
}
.item-buy-name {
    font-size: 18px; font-weight: 600;
    margin-bottom: 12px; color: #1a1a1a;
}
.item-buy-tags {
    display: flex; gap: 8px; flex-wrap: wrap;
    margin-bottom: 14px; padding-bottom: 14px;
    border-bottom: 1px solid rgb(0 0 0 / .08);
}
.item-buy-price {
    font-size: 26px; color: #e8463f; font-weight: 700;
    margin-bottom: 16px; padding-bottom: 16px;
    border-bottom: 1px solid rgb(0 0 0 / .08);
}
.item-buy-price .abacus-price { font-size: 26px; }
.item-buy-card .goods-tag {
    font-size: 12px; padding: 4px 10px; border-radius: 6px;
    background: #fff; border: 1px solid #22c55e; color: #22c55e;
}
.item-buy-card .goods-tag--blue { border-color: #4c96e0; color: #4c96e0; }
.item-buy-card .goods-tag--green { border-color: #22c55e; color: #22c55e; }
.item-buy-card form > div {
    margin-bottom: 14px;
}
.item-buy-card .form-label {
    font-size: 13px; color: #333; font-weight: 600;
    margin-bottom: 6px; display: block;
}
.item-buy-card .form-control {
    border: 1px solid #e0e0e0; border-radius: 8px;
    padding: 10px 14px; font-size: 14px;
}
.item-buy-card .qty-group {
    width: 180px;
    max-width: 100%;
    gap: 8px;
}
.item-buy-card .qty-group button {
    background: #fff; border: 1px solid #e0e0e0;
    color: #333; width: 40px;
}
.item-buy-card .input-group.qty-group > input[type="number"] {
    flex: 0 0 60px;
    min-width: 60px;
    padding: 0;
    border-top: 1px solid #e0e0e0;
    border-bottom: 1px solid #e0e0e0;
    border-radius: 0;
}
.item-buy-card .captcha-img { border: none; }
.item-buy-card .cash-pay {
    background: #f8fafc;
    border: 1px solid rgb(0 0 0 / .08);
    border-radius: 10px; padding: 14px;
    margin-top: 14px;
}
.item-buy-card .cash-pay .form-label {
    margin-bottom: 10px;
}
.item-buy-card .pay-list {
    display: flex; flex-wrap: wrap; gap: 8px;
}
.item-buy-card .pay-list button,
.item-buy-card .pay-list a {
    background: #fff; border: 1px solid #e0e0e0;
    border-radius: 8px; padding: 8px 14px;
    font-size: 13px;
}
.cate-drawer-btn {
    display: none; margin-left: auto;
    background: #1e40af; color: #fff; border: none;
    border-radius: 10px; padding: 8px 16px;
    font-size: 13px; cursor: pointer;
}
.cate-mask {
    display: none; position: fixed; inset: 0;
    background: rgb(0 0 0 / .5); z-index: 998;
}
.cate-drawer {
    position: fixed; top: 0; right: 0; bottom: 0;
    width: 80%; max-width: 340px;
    background: #fff; z-index: 999;
    transform: translateX(100%);
    transition: transform .25s ease;
    display: flex; flex-direction: column;
}
.cate-drawer.is-open { transform: translateX(0); }
.cate-mask.is-open { display: block; }
.cate-drawer-head {
    display: flex; justify-content: space-between; align-items: center;
    padding: 18px 20px; font-size: 18px; font-weight: 600;
    border-bottom: 1px solid #eee;
}
.cate-drawer-close {
    padding: 0; border: 0; background: transparent;
    cursor: pointer; color: #999; font-size: 18px;
}
.cate-drawer-body {
    flex: 1; overflow-y: auto; padding: 12px;
}
.cate-drawer-link {
    display: flex; align-items: center; gap: 10px;
    padding: 14px 12px; border-radius: 10px;
    color: #1f2733; cursor: pointer; text-decoration: none;
    font-size: 14px; margin-bottom: 4px;
}
.cate-drawer-link:hover { background: #f5f5f5; }
.cate-drawer-link.is-active { color: #1e40af; font-weight: 600; background: #eff6ff; }

@media (max-width: 900px) {
    .shop-home { padding: 8px 12px 40px; }
    .hero-card { padding: 14px 16px; border-radius: 16px; }
    .hero-head { margin-bottom: 10px; }
    .shop-home .cate-drawer-btn { display: inline-flex !important; align-items: center; gap: 6px; }
    .hero-input { padding: 10px 12px; }
    .hero-btn { padding: 10px 18px; }

    .home-layout { flex-direction: column; gap: 14px; margin-top: 14px; }
    .side-card { display: none; }

    .main-card { width: 100%; padding: 12px 14px 16px; border-radius: 16px; }
    .main-title { font-size: 14px; margin-bottom: 10px; }
    .goods-thead { display: none; }
    .goods-body { gap: 12px; }
    .goods-row {
        display: block !important; padding: 14px;
        border: 1px solid rgb(0 0 0 / .08); border-radius: 14px;
        background: rgb(255 255 255 / .7);
    }
    .td-name {
        display: flex; align-items: center; gap: 10px;
        margin-bottom: 10px; font-size: 15px; font-weight: 600;
    }
    .goods-thumb { font-size: 22px; }
    .goods-name { font-size: 15px; }
    .goods-tag-row {
        display: flex; flex-wrap: wrap; gap: 8px;
        margin-bottom: 10px;
    }
    .m-tag {
        font-size: 12px; padding: 5px 12px;
        border-radius: 8px; border: 1px solid #ddd;
    }
    .m-tag.price { color: #e8463f; border-color: #e8463f; }
    .m-tag.stock { color: #333; }
    .m-tag.warranty { color: #1e40af; border-color: #1e40af; }
    .m-tag.ship { color: #22c55e; border-color: #22c55e; }
    .m-buy-row {
        display: flex; justify-content: flex-end;
    }
    .m-buy {
        background: #22c55e; color: #fff;
        border: none; border-radius: 10px;
        padding: 10px 24px; font-size: 14px;
        text-decoration: none; display: inline-flex;
        align-items: center; gap: 6px;
    }
    .m-buy.disabled { background: #ccc; }
    .td-warranty, .td-price, .td-stock, .td-op { display: none; }
}

@media (max-width: 900px) {
    .item-detail-page { padding: 0; }
    .item-detail-layout {
        flex-direction: column; gap: 0;
    }
    .item-buy-card {
        width: 100%; flex: none;
        position: sticky; top: 0; z-index: 20;
        border-radius: 0; padding: 14px 16px;
        background: #fff;
        box-shadow: 0 2px 10px rgb(0 0 0 / .08);
    }
    .item-buy-name { font-size: 16px; margin-bottom: 8px; }
    .item-buy-tags { margin-bottom: 8px; }
    .item-buy-price { font-size: 22px; margin-bottom: 10px; }
    .item-detail-left {
        width: 100%; padding: 14px 16px;
    }
    .item-detail-title { font-size: 17px; margin-bottom: 12px; }
    .item-detail-content { font-size: 14px; }
    .item-detail-content img {
        max-width: 100%; height: auto;
        border-radius: 10px;
    }
    .item-detail-content table {
        display: block; width: 100%;
        overflow-x: auto;
    }
    .item-detail-content pre,
    .item-detail-content code {
        white-space: pre-wrap;
        word-break: break-all;
    }
}
