* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: "PingFang SC", "Microsoft YaHei UI", -apple-system, sans-serif;
}
body {
    background-color: #f7f7f7;
    color: #333;
    max-width: 750px;
    margin: 0 auto;
    overflow-y: auto;
    height: auto;
    min-height: 100vh;
}

/* 微信主题色 */
:root {
    --wx-primary: #07C160;
    --wx-primary-dark: #06AD56;
    --wx-text: #1A1A1A;
    --wx-text-light: #666666;
    --wx-bg: #f7f7f7;
    --wx-border: #e5e5e5;
    --wx-rating: #FF6B35;
    --wx-price: #FF4D4F;
}

/* 商品图片轮播 */
.wx-goods-slider {
    position: relative;
    overflow: hidden;
    height: 300px;
    background-color: white;
}

.wx-goods-slider-wrapper {
    display: flex;
    transition: transform 0.3s ease;
    height: 100%;
}

.wx-goods-slider-item {
    flex: 0 0 100%;
    height: 100%;
}

.wx-goods-slider-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.wx-goods-slider-dots {
    position: absolute;
    bottom: 12px;
    left: 0;
    right: 0;
    display: flex;
    justify-content: center;
    gap: 6px;
}

.wx-goods-slider-dot {
    width: 6px;
    height: 6px;
    border-radius: 3px;
    background-color: rgba(255, 255, 255, 0.6);
    transition: all 0.3s ease;
}

.wx-goods-slider-dot.active {
    width: 16px;
    background-color: white;
}

/* 商品信息 */
.wx-goods-info {
    background-color: white;
    padding: 16px;
    margin-bottom: 8px;
}

.wx-goods-title-container {
    margin-bottom: 12px;
    position: relative;
}

.wx-goods-title {
    font-size: 18px;
    font-weight: 600;
    color: var(--wx-text);
    line-height: 1.4;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    text-overflow: ellipsis;
    padding-right: 20px;
}

.wx-goods-title.expanded {
    display: block;
    -webkit-line-clamp: unset;
    padding-right: 0;
}

.wx-title-expand {
    position: absolute;
    right: 0;
    bottom: 0;
    color: var(--wx-primary);
    font-size: 14px;
    cursor: pointer;
    background-color: white;
    padding: 0 4px;
    line-height: 1;
}

.wx-expand-arrow {
    font-size: 12px;
    transition: transform 0.2s;
}

/* 服务保障卡片 */
.wx-service-card {
    background-color: white;
    border-radius: 8px;
    padding: 16px;
    margin-bottom: 12px;
}

.wx-service-item {
    display: flex;
    align-items: center;
    padding: 8px 0;
    gap: 12px;
}

.wx-service-item:first-child {
    padding-top: 0;
}

.wx-service-item:last-child {
    padding-bottom: 0;
}

.wx-service-title {
    font-size: 14px;
    font-weight: 600;
    color: var(--wx-text-light);
    min-width: 40px;
}

.wx-service-desc {
    font-size: 13px;
    color: var(--wx-text);
    flex: 1;
}

.wx-service-sub {
    font-size: 11px;
    color: var(--wx-text-light);
    margin-top: 2px;
}

/* 商品评价卡片 */
.wx-reviews-card {
    background-color: white;
    margin-bottom: 8px;
}

.wx-reviews-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 16px 20px;
    border-bottom: 1px solid var(--wx-border);
}

.wx-reviews-title {
    font-size: 16px;
    font-weight: 600;
    color: var(--wx-text);
}

.wx-reviews-more {
    color: var(--wx-text-light);
    font-size: 14px;
}

.wx-arrow-icon {
    font-weight: 600;
}

.wx-review-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    padding: 12px 20px;
    border-bottom: 1px solid var(--wx-border);
}

.wx-review-tag {
    display: inline-block;
    padding: 4px 8px;
    background-color: #f8f9fa;
    color: var(--wx-text);
    font-size: 12px;
    border-radius: 4px;
    line-height: 1;
}

.wx-review-list {
    padding: 0 20px;
}

.wx-review-item {
    padding: 16px 0;
    border-bottom: 1px solid var(--wx-border);
}

.wx-review-item:last-child {
    border-bottom: none;
}

.wx-review-user {
    display: flex;
    align-items: center;
    margin-bottom: 12px;
}

.wx-user-avatar {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    overflow: hidden;
    margin-right: 12px;
}

.wx-user-avatar img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.wx-user-info {
    display: flex;
    flex-direction: column;
}

.wx-user-name {
    font-size: 14px;
    color: var(--wx-text);
    margin-bottom: 4px;
}

.wx-review-time {
    font-size: 12px;
    color: var(--wx-text-light);
}

.wx-review-content {
    padding-left: 44px;
}

.wx-review-text {
    font-size: 14px;
    color: var(--wx-text);
    line-height: 1.5;
    margin-bottom: 8px;
}

.wx-review-images {
    display: flex;
    gap: 8px;
    margin-top: 8px;
}

.wx-review-image-item {
    width: 60px;
    height: 60px;
    border-radius: 4px;
    overflow: hidden;
}

.wx-review-image-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.wx-review-image-more {
    width: 60px;
    height: 60px;
    border-radius: 4px;
    background-color: rgba(0, 0, 0, 0.05);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--wx-text-light);
    font-size: 12px;
}

.wx-no-review {
    padding: 40px 0;
    text-align: center;
    color: var(--wx-text-light);
    font-size: 14px;
}

.wx-service-arrow {
    color: var(--wx-text-light);
    font-size: 14px;
    font-weight: 600;
}





.wx-price-sales-row {
    display: flex;
    justify-content: space-between;
    align-items: flex-end;
    margin-bottom: 12px;
}

.wx-goods-price {
    display: flex;
    align-items: baseline;
    gap: 8px;
}

.wx-goods-price-current {
    font-size: 24px;
    font-weight: 700;
    color: var(--wx-price);
}

.wx-goods-price-original {
    font-size: 14px;
    color: var(--wx-text-light);
    text-decoration: line-through;
}



.wx-goods-sales {
    font-size: 13px;
    color: var(--wx-text-light);
    text-align: right;
}

/* 商品详情 */
.wx-goods-detail {
    background-color: white;
    padding: 16px;
    margin-bottom: 0;
}

.wx-goods-detail-title {
    font-size: 16px;
    font-weight: 600;
    color: var(--wx-text);
    margin-bottom: 12px;
    position: relative;
    padding-left: 12px;
}

.wx-goods-detail-title:before {
    content: '';
    position: absolute;
    left: 0;
    top: 50%;
    transform: translateY(-50%);
    width: 4px;
    height: 18px;
    background-color: var(--wx-primary);
    border-radius: 2px;
}

.wx-goods-detail-content {
    font-size: 14px;
    line-height: 1.6;
    color: var(--wx-text);
}

/* 底部购买栏 */
.wx-buy-bar {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    max-width: 750px;
    margin: 0 auto;
    background-color: white;
    border-top: 1px solid var(--wx-border);
    padding: 12px 16px;
    display: flex;
    align-items: center;
    gap: 12px;
    z-index: 100;
}

.wx-buy-btn {
    flex: 1;
    background-color: #FF4D4F;
    color: white;
    border: none;
    padding: 12px;
    border-radius: 8px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: background-color 0.2s;
    height: 44px;
}

.wx-buy-btn:hover {
    background-color: #FF7875;
}

.wx-shop-btn,
.wx-service-btn {
    width: 44px;
    height: 44px;
    background-color: white;
    border: none;
    border-radius: 8px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: background-color 0.2s;
    gap: 2px;
}

.wx-shop-btn:hover,
.wx-service-btn:hover {
    background-color: #f8f9fa;
}

.wx-shop-icon,
.wx-service-icon {
    font-size: 16px;
    line-height: 1;
}

.wx-btn-text {
    font-size: 10px;
    color: var(--wx-text-light);
    line-height: 1;
}

.wx-cart-btn {
    width: 44px;
    height: 44px;
    background-color: var(--wx-bg);
    border: 1px solid var(--wx-border);
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: background-color 0.2s;
}

.wx-cart-btn:hover {
    background-color: #e8e8e8;
}

.wx-cart-icon {
    width: 20px;
    height: 20px;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath fill='%23666666' d='M7 18c-1.1 0-1.99.9-1.99 2S5.9 22 7 22s2-.9 2-2-.9-2-2-2zM1 2v2h2l3.6 7.59-1.35 2.45c-.16.28-.25.61-.25.96 0 1.1.9 2 2 2h12v-2H7.42c-.14 0-.25-.11-.25-.25l.03-.12L8.1 13h7.45c.75 0 1.41-.41 1.75-1.03L21.7 4H5.21l-.94-2H1zm16 16c-1.1 0-1.99.9-1.99 2s.89 2 1.99 2 2-.9 2-2-.9-2-2-2z'%3E%3C/path%3E%3C/svg%3E");
    background-size: contain;
    background-repeat: no-repeat;
}

.wx-gift-btn {
    flex: 1;
    height: 44px;
    background-color: #FFF1F0;
    border: 1px solid #FFE7E6;
    border-radius: 8px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: background-color 0.2s;
    gap: 2px;
}

.wx-gift-btn:hover {
    background-color: #FFE7E6;
}

.wx-gift-btn svg {
    width: 16px;
    height: 16px;
}

.wx-gift-text {
    font-size: 10px;
    color: #FF4D4F;
    line-height: 1;
}

/* 为底部购买栏腾出空间 */
.wx-content {
    margin-bottom: 80px;
    height: auto;
    overflow-y: visible;
    padding-top: 0;
    padding-bottom: 80px;
}

/* 购买弹窗样式 */
.wx-buy-popup-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: rgba(0, 0, 0, 0.5);
    display: flex;
    align-items: flex-end;
    z-index: 1000;
}

.wx-buy-popup {
    background-color: white;
    width: 100%;
    max-width: 750px;
    margin: 0 auto;
    border-radius: 16px 16px 0 0;
    max-height: 80vh;
    overflow-y: auto;
}

.wx-buy-popup-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 16px 20px;
    border-bottom: 1px solid var(--wx-border);
}

.wx-buy-popup-title {
    font-size: 16px;
    font-weight: 600;
    color: var(--wx-text);
}

.wx-buy-popup-close {
    font-size: 24px;
    color: var(--wx-text-light);
    cursor: pointer;
    width: 24px;
    height: 24px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.wx-buy-popup-content {
    padding: 20px;
}

.wx-section-title {
    font-size: 14px;
    font-weight: 600;
    color: var(--wx-text);
    margin-bottom: 12px;
}

/* 地址部分 */
.wx-address-section {
    margin-bottom: 20px;
}

.wx-address-info {
    background-color: var(--wx-bg);
    border-radius: 8px;
    padding: 16px;
    cursor: pointer;
}

.wx-add-address-text {
    color: var(--wx-primary);
    font-size: 14px;
}

.wx-address-user {
    font-size: 14px;
    color: var(--wx-text);
    margin-bottom: 4px;
}

.wx-address-detail {
    font-size: 13px;
    color: var(--wx-text-light);
}

/* 规格部分 */
.wx-spec-section {
    margin-bottom: 20px;
}

.wx-spec-items {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.wx-spec-item {
    padding: 8px 12px;
    border: 1px solid var(--wx-border);
    border-radius: 6px;
    font-size: 13px;
    color: var(--wx-text);
    cursor: pointer;
    transition: all 0.2s;
}

.wx-spec-item[data-selected="true"] {
    background-color: var(--wx-primary);
    color: white;
    border-color: var(--wx-primary);
}

/* 数量部分 */
.wx-quantity-section {
    margin-bottom: 20px;
}

.wx-number-input {
    display: flex;
    align-items: center;
    border: 1px solid var(--wx-border);
    border-radius: 6px;
    width: fit-content;
}

.wx-minus, .wx-plus {
    width: 36px;
    height: 36px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    font-size: 18px;
    color: var(--wx-text);
    background-color: var(--wx-bg);
}

.wx-number-input input {
    width: 60px;
    height: 36px;
    border: none;
    text-align: center;
    font-size: 14px;
}

/* 底部 */
.wx-buy-popup-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 16px 20px;
    border-top: 1px solid var(--wx-border);
    background-color: white;
}

.wx-total-price {
    font-size: 16px;
    font-weight: 600;
    color: var(--wx-price);
}

.wx-confirm-btn {
    background-color: #FF4D4F;
    color: white;
    border: none;
    padding: 12px 24px;
    border-radius: 8px;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: background-color 0.2s;
}
.wx-confirm-btn:hover {
    background-color: #FF7875;
}

/* 地址表单弹窗 */
.wx-address-popup-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: rgba(0, 0, 0, 0.5);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 1001;
}

.wx-address-popup {
    background-color: white;
    width: 90%;
    max-width: 400px;
    border-radius: 12px;
    max-height: 80vh;
    overflow-y: auto;
}

.wx-address-popup-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 16px 20px;
    border-bottom: 1px solid var(--wx-border);
}

.wx-address-popup-title {
    font-size: 16px;
    font-weight: 600;
    color: var(--wx-text);
}

.wx-address-popup-close {
    font-size: 24px;
    color: var(--wx-text-light);
    cursor: pointer;
}

.wx-address-popup-content {
    padding: 20px;
}

.wx-address-form {
    margin-bottom: 20px;
}

.wx-form-item {
    margin-bottom: 16px;
}

.wx-form-item label {
    display: block;
    font-size: 14px;
    color: var(--wx-text);
    margin-bottom: 8px;
}

.wx-form-item input,
.wx-form-item textarea {
    width: 100%;
    padding: 12px;
    border: 1px solid var(--wx-border);
    border-radius: 6px;
    font-size: 14px;
    box-sizing: border-box;
}

.wx-form-item textarea {
    height: 80px;
    resize: none;
}

.wx-save-address-btn {
    background-color: var(--wx-primary);
    color: white;
    text-align: center;
    padding: 12px;
    border-radius: 8px;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
}

/* 地区选择器样式 */
.wx-region-selector {
    position: relative;
    display: flex;
    align-items: center;
    border: 1px solid var(--wx-border);
    border-radius: 6px;
    background-color: white;
    cursor: pointer;
}

.wx-region-selector input {
    flex: 1;
    border: none;
    padding: 12px;
    font-size: 14px;
    background: transparent;
    cursor: pointer;
}

.wx-region-arrow {
    padding: 0 12px;
    color: var(--wx-text-light);
    font-size: 12px;
}

/* 地区选择器弹窗 */
.wx-region-picker-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: rgba(0, 0, 0, 0.5);
    display: flex;
    align-items: flex-end;
    z-index: 1002;
}

.wx-region-picker {
    background-color: white;
    width: 100%;
    border-radius: 16px 16px 0 0;
    max-height: 60vh;
    overflow: hidden;
}

.wx-region-picker-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 16px 20px;
    border-bottom: 1px solid var(--wx-border);
}

.wx-region-picker-cancel,
.wx-region-picker-confirm {
    font-size: 14px;
    color: var(--wx-primary);
    cursor: pointer;
}

.wx-region-picker-title {
    font-size: 16px;
    font-weight: 600;
    color: var(--wx-text);
}

.wx-region-picker-content {
    height: 400px;
    overflow-y: auto;
}

.wx-region-list {
    padding: 0 0 96px;
    padding-bottom: calc(96px + constant(safe-area-inset-bottom));
    padding-bottom: calc(96px + env(safe-area-inset-bottom));
}

.wx-region-item {
    padding: 16px 20px;
    border-bottom: 1px solid var(--wx-border);
    font-size: 16px;
    color: var(--wx-text);
    cursor: pointer;
    transition: background-color 0.2s;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.wx-region-item:hover {
    background-color: var(--wx-bg);
}

.wx-region-item.selected {
    color: var(--wx-primary);
    font-weight: 600;
}

.wx-region-item .wx-region-arrow {
    color: var(--wx-text-light);
    font-size: 14px;
}

.wx-region-picker-back {
    font-size: 14px;
    color: var(--wx-primary);
    cursor: pointer;
}
.wx-left-btns {
    display: flex;
    gap: 4px;
    align-items: center;
    margin-left: 0;
    margin-right: 4px;
}

/* 客服联系信息样式 */
.wx-contact-info {
    padding: 20px;
    font-size: 14px;
    line-height: 1.6;
}

.wx-contact-item {
    margin-bottom: 12px;
    display: flex;
    align-items: center;
}

.wx-contact-item label {
    font-weight: 600;
    color: #333;
    min-width: 80px;
    margin-right: 10px;
}

.wx-contact-item span {
    color: #666;
}
