/* storev2 订单查询 & 购物车样式 */

/* 订单查询页面 */
.query-page {
    padding: 1rem;
    padding-bottom: 5rem;
    max-width: 1200px;
    margin: 0 auto;
}

.query-search {
    display: flex;
    gap: 0.5rem;
    margin-bottom: 1rem;
}

.query-search input {
    flex: 1;
    padding: 0.7rem 1rem;
    background: var(--glass);
    border: 1px solid var(--glass-border);
    border-radius: 10px;
    color: var(--text);
    font-size: 0.9rem;
    outline: none;
}

.query-search input:focus {
    border-color: var(--primary);
}

.query-search button {
    padding: 0.7rem 1.25rem;
    background: var(--gradient-primary);
    border: none;
    border-radius: 10px;
    color: white;
    font-weight: 600;
    cursor: pointer;
}

/* 状态标签 */
.status-tabs {
    display: flex;
    gap: 0.5rem;
    margin-bottom: 1rem;
    overflow-x: auto;
    padding-bottom: 0.25rem;
}

.status-tab {
    flex-shrink: 0;
    padding: 0.4rem 0.9rem;
    background: var(--glass);
    border: 1px solid var(--glass-border);
    border-radius: 20px;
    color: var(--text-muted);
    font-size: 0.8rem;
    cursor: pointer;
    transition: all 0.3s;
    text-decoration: none;
}

.status-tab.active {
    background: var(--gradient-primary);
    color: white;
    border-color: transparent;
}

/* 订单卡片 */
.order-card {
    background: var(--glass);
    border: 1px solid var(--glass-border);
    border-radius: 12px;
    padding: 1rem;
    margin-bottom: 0.75rem;
}

.order-card .order-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 0.75rem;
}

.order-card .order-name {
    font-weight: 600;
    font-size: 0.9rem;
    flex: 1;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    margin-right: 0.5rem;
}

.order-card .order-status {
    font-size: 0.8rem;
    font-weight: 600;
    flex-shrink: 0;
}

.order-status.done { color: var(--success); }
.order-status.processing { color: var(--warning); }
.order-status.error { color: var(--danger); }
.order-status.refund { color: var(--text-muted); }
.order-status.pending { color: var(--accent); }

.order-card .order-body {
    display: flex;
    gap: 0.75rem;
}

.order-card .order-img {
    width: 60px;
    height: 60px;
    border-radius: 8px;
    overflow: hidden;
    flex-shrink: 0;
    background: var(--dark-light);
}

.order-card .order-img img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.order-card .order-info {
    flex: 1;
    font-size: 0.8rem;
    color: var(--text-muted);
    line-height: 1.7;
}

.order-card .order-actions {
    display: flex;
    gap: 0.5rem;
    margin-top: 0.75rem;
    justify-content: flex-end;
}

.order-card .order-btn {
    padding: 0.35rem 0.9rem;
    background: var(--glass);
    border: 1px solid var(--glass-border);
    border-radius: 6px;
    color: var(--text);
    font-size: 0.75rem;
    cursor: pointer;
    text-decoration: none;
    transition: all 0.3s;
}

.order-card .order-btn:hover {
    background: var(--primary);
    border-color: var(--primary);
}

.order-card .order-btn.primary {
    background: var(--gradient-primary);
    border: none;
    color: white;
}

/* 空状态 */
.empty-state {
    text-align: center;
    padding: 3rem 1rem;
    color: var(--text-muted);
}

.empty-state img {
    width: 120px;
    opacity: 0.5;
    margin-bottom: 1rem;
}

.empty-state a {
    display: inline-block;
    margin-top: 1rem;
    padding: 0.5rem 1.5rem;
    background: var(--gradient-primary);
    color: white;
    border-radius: 20px;
    text-decoration: none;
    font-size: 0.85rem;
}

/* 分页 */
.pagination {
    display: flex;
    justify-content: space-between;
    margin-top: 1rem;
    gap: 0.5rem;
}

.pagination button {
    flex: 1;
    padding: 0.6rem;
    background: var(--glass);
    border: 1px solid var(--glass-border);
    border-radius: 8px;
    color: var(--text);
    cursor: pointer;
    font-size: 0.85rem;
}

.pagination button:hover {
    background: var(--primary);
    border-color: var(--primary);
}

/* 购物车页面 */
.cart-page {
    padding: 1rem;
    padding-bottom: 6rem;
    max-width: 1200px;
    margin: 0 auto;
}

.cart-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 1rem;
}

.cart-header h2 {
    font-size: 1.2rem;
}

.cart-header .cart-count {
    color: var(--text-muted);
    font-size: 0.85rem;
}

/* 购物车商品项 */
.cart-item {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    background: var(--glass);
    border: 1px solid var(--glass-border);
    border-radius: 12px;
    padding: 0.75rem;
    margin-bottom: 0.75rem;
}

.cart-item .cart-checkbox {
    width: 20px;
    height: 20px;
    border-radius: 50%;
    border: 2px solid var(--glass-border);
    cursor: pointer;
    flex-shrink: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s;
}

.cart-item .cart-checkbox.checked {
    background: var(--primary);
    border-color: var(--primary);
}

.cart-item .cart-checkbox.checked::after {
    content: '✓';
    color: white;
    font-size: 0.7rem;
}

.cart-item .cart-img {
    width: 60px;
    height: 60px;
    border-radius: 8px;
    overflow: hidden;
    flex-shrink: 0;
}

.cart-item .cart-img img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.cart-item .cart-info {
    flex: 1;
    min-width: 0;
}

.cart-item .cart-name {
    font-size: 0.85rem;
    font-weight: 600;
    margin-bottom: 0.25rem;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.cart-item .cart-price {
    color: var(--danger);
    font-weight: 700;
    font-size: 0.9rem;
}

.cart-item .cart-remove {
    color: var(--text-muted);
    cursor: pointer;
    padding: 0.25rem;
}

.cart-item .cart-remove:hover {
    color: var(--danger);
}

/* 购物车底部结算栏 */
.cart-footer {
    position: fixed;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 100%;
    max-width: 1200px;
    background: rgba(15, 23, 42, 0.95);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-top: 1px solid var(--glass-border);
    padding: 0.75rem 1rem calc(0.75rem + env(safe-area-inset-bottom));
    display: flex;
    align-items: center;
    justify-content: space-between;
    z-index: 100;
}

.cart-footer .select-all {
    display: flex;
    align-items: center;
    gap: 0.4rem;
    color: var(--text-muted);
    font-size: 0.85rem;
    cursor: pointer;
}

.cart-footer .select-all .cart-checkbox {
    width: 18px;
    height: 18px;
}

.cart-footer .total-info {
    flex: 1;
    text-align: right;
    margin-right: 1rem;
}

.cart-footer .total-label {
    font-size: 0.8rem;
    color: var(--text-muted);
}

.cart-footer .total-price {
    color: var(--danger);
    font-size: 1.2rem;
    font-weight: 700;
}

.cart-footer .checkout-btn {
    padding: 0.6rem 1.5rem;
    background: var(--gradient-primary);
    border: none;
    border-radius: 25px;
    color: white;
    font-weight: 600;
    cursor: pointer;
    box-shadow: var(--shadow-glow);
}

/* 猜你喜欢 */
.recommend-section {
    margin-top: 2rem;
}

.recommend-title {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    margin-bottom: 1rem;
    font-size: 1rem;
    font-weight: 700;
}

.recommend-title::before {
    content: '';
    width: 4px;
    height: 18px;
    background: var(--gradient-accent);
    border-radius: 2px;
}

/* 客服页面 */
.kf-page {
    padding: 2rem 1rem;
    max-width: 500px;
    margin: 0 auto;
}

.kf-card {
    background: var(--glass);
    border: 1px solid var(--glass-border);
    border-radius: 20px;
    padding: 2rem;
    text-align: center;
}

.kf-card .kf-avatar {
    width: 80px;
    height: 80px;
    border-radius: 50%;
    background: var(--gradient-primary);
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 1rem;
    font-size: 2rem;
    box-shadow: var(--shadow-glow);
}

.kf-card .kf-title {
    font-size: 1.1rem;
    font-weight: 700;
    margin-bottom: 0.5rem;
}

.kf-card .kf-info {
    color: var(--text-muted);
    font-size: 0.9rem;
    margin-bottom: 1rem;
}

.kf-card .kf-qrcode {
    width: 200px;
    height: 200px;
    margin: 1rem auto;
    border-radius: 12px;
    overflow: hidden;
    background: white;
    padding: 8px;
}

.kf-card .kf-qrcode img {
    width: 100%;
    height: 100%;
}

.kf-card .kf-action {
    display: inline-block;
    margin-top: 1rem;
    padding: 0.6rem 1.5rem;
    background: var(--gradient-primary);
    color: white;
    border-radius: 25px;
    text-decoration: none;
    font-weight: 600;
}

/* ===== 购物车 cart.js 样式适配 ===== */
.gwc1_1, .gwc1_2 {
    margin-bottom: 0.75rem;
}
.gwc1_1 {
    display: flex;
    align-items: center;
    justify-content: space-between;
    background: var(--glass);
    border: 1px solid var(--glass-border);
    border-radius: 12px;
    padding: 0.75rem 1rem;
}
.gwc1_1 .g1 {
    display: flex;
    align-items: center;
}
.gwc1_1 .g2 a {
    color: var(--text);
    text-decoration: none;
    display: flex;
    align-items: center;
    gap: 0.3rem;
}
.gwc1_1 .g2 img {
    width: 18px;
    height: 18px;
}
.gwccheck {
    width: 20px;
    height: 20px;
    border: 2px solid var(--text-muted);
    border-radius: 50%;
    cursor: pointer;
    transition: all 0.2s;
    display: inline-block;
}
.gwccheck.on {
    background: var(--accent);
    border-color: var(--accent);
}
.gwccheck.on::after {
    content: '\f00c';
    font-family: 'FontAwesome';
    color: white;
    font-size: 11px;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    height: 100%;
}
.gwcone {
    display: flex;
    align-items: stretch;
    background: var(--glass);
    border: 1px solid var(--glass-border);
    border-radius: 12px;
    padding: 0.75rem;
    margin-bottom: 0.5rem;
    gap: 0.5rem;
}
.gwcone .go1 {
    display: flex;
    align-items: center;
    padding: 0 0.3rem;
}
.gwcone .go2 {
    width: 70px;
    height: 70px;
    border-radius: 8px;
    overflow: hidden;
    flex-shrink: 0;
    background: var(--dark-light);
}
.gwcone .go2 img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}
.gwcone .go3 {
    flex: 1;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    min-width: 0;
}
.gwcone .go3_1 {
    margin-bottom: 0.25rem;
}
.gwcone .go3_1 a {
    text-decoration: none;
}
.gwcone .go3_1 .p1 {
    color: var(--text);
    font-size: 0.9rem;
    font-weight: 500;
    margin: 0;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}
.gwcone .go3_1 .p2 {
    color: var(--text-muted);
    font-size: 0.7rem;
    margin: 0;
}
.gwcone .go3_2 {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin: 0.25rem 0;
}
.gwcone .go3_2 .p3 {
    color: var(--text-muted);
    font-size: 0.75rem;
    margin: 0;
    flex: 1;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    margin-right: 0.5rem;
}
.gwcone .go3_2 .p4 {
    color: var(--danger);
    font-weight: 700;
    font-size: 0.95rem;
    margin: 0;
}
.gwcone .go3_3 {
    display: flex;
    align-items: center;
    gap: 0.3rem;
}
.gwcone .num1, .gwcone .num3 {
    width: 24px;
    height: 24px;
    border-radius: 50%;
    background: var(--glass-border);
    color: var(--text);
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    font-size: 0.9rem;
    user-select: none;
}
.gwcone .num1:hover, .gwcone .num3:hover {
    background: var(--accent);
}
.gwcone .num2 {
    min-width: 28px;
    text-align: center;
    color: var(--text);
    font-size: 0.9rem;
}
.gwcone .del {
    margin-left: auto;
    cursor: pointer;
}
.gwcone .del img {
    width: 16px;
    height: 16px;
    filter: brightness(0) invert(1) opacity(0.6);
}
.gwcone .del:hover img {
    filter: brightness(0) invert(1) opacity(1);
}
.clear {
    clear: both;
}
.hejiBox {
    display: none;
}

/* 推荐商品 */
.recommend-section {
    margin-top: 1rem;
    padding-bottom: 5rem;
}
.recommend-title {
    font-size: 1rem;
    font-weight: 600;
    margin-bottom: 0.5rem;
    color: var(--text);
}
.goods-list .goods-card {
    background: var(--glass);
    border: 1px solid var(--glass-border);
    border-radius: 10px;
    overflow: hidden;
    display: block;
    text-decoration: none;
    margin-bottom: 0.5rem;
}
.goods-list .goods-card img {
    width: 100%;
    height: 80px;
    object-fit: cover;
}
.goods-list .goods-card .goods-info {
    padding: 0.5rem;
}
.goods-list .goods-card .goods-name {
    color: var(--text);
    font-size: 0.8rem;
    margin-bottom: 0.25rem;
}
.goods-list .goods-card .goods-price {
    color: var(--danger);
    font-weight: 700;
    font-size: 0.85rem;
}
