/* 商品详情页移动端专用样式 */

/* 基础重置 */
* {
    box-sizing: border-box;
}

/* 移动端专用样式 */
@media screen and (max-width: 768px) {
    
    /* 页面容器 */
    body {
        font-size: 14px;
        -webkit-text-size-adjust: 100%;
    }
    
    /* 主容器 */
    .wrapper {
        width: 100% !important;
        max-width: 100% !important;
        padding: 0 10px !important;
        margin: 0 auto;
    }
    
    /* 面包屑导航 */
    .location {
        margin-top: 10px !important;
        padding: 10px 0;
        overflow-x: auto;
        white-space: nowrap;
    }
    
    .location .el-breadcrumb {
        display: inline-block;
    }
    
    /* 商品信息主容器 */
    .goods-info {
        display: flex !important;
        flex-direction: column !important;
        margin-top: 15px !important;
        gap: 10px;
    }
    
    /* 左侧图片区域 */
    .goods-info .left-box {
        width: 100% !important;
        max-width: 100% !important;
        margin: 0 !important;
        border-radius: 8px !important;
        overflow: hidden;
    }
    
    .goods-info .left-box .swiper-gallery {
        width: 100% !important;
        height: 280px !important;
        position: relative;
    }
    
    .goods-info .left-box .swiper-gallery .swiper-container {
        width: 100%;
        height: 100%;
    }
    
    .goods-info .left-box .swiper-gallery .swiper-slide {
        display: flex;
        justify-content: center;
        align-items: center;
        background: #f5f5f5;
    }
    
    .goods-info .left-box .swiper-gallery .swiper-slide img {
        width: 100% !important;
        height: 100% !important;
        object-fit: contain;
    }
    
    /* 缩略图区域 */
    .goods-info .left-box .swiper-thumbs {
        margin: 10px 5px !important;
        padding: 0 !important;
    }
    
    .goods-info .left-box .swiper-thumbs .swiper-container {
        padding: 0 25px !important;
    }
    
    .goods-info .left-box .swiper-thumbs .swiper-slide {
        width: 55px !important;
        height: 55px !important;
        margin: 0 4px !important;
        border: 2px solid #e5e5e5 !important;
        border-radius: 4px;
        overflow: hidden;
    }
    
    .goods-info .left-box .swiper-thumbs .swiper-slide img {
        width: 100% !important;
        height: 100% !important;
        object-fit: cover;
    }
    
    .goods-info .left-box .swiper-thumbs .swiper-slide.swiper-slide-thumb-active {
        border-color: #0D62BE !important;
    }
    
    .goods-info .left-box .swiper-thumbs .swiper-button-prev,
    .goods-info .left-box .swiper-thumbs .swiper-button-next {
        width: 20px !important;
        height: 100% !important;
        margin-top: 0 !important;
    }
    
    .goods-info .left-box .swiper-thumbs .swiper-button-prev {
        left: 0 !important;
    }
    
    .goods-info .left-box .swiper-thumbs .swiper-button-next {
        right: 0 !important;
    }
    
    .goods-info .left-box .swiper-thumbs .swiper-button-prev::after,
    .goods-info .left-box .swiper-thumbs .swiper-button-next::after {
        font-size: 14px !important;
        font-weight: bold;
    }
    
    /* 右侧信息区域 */
    .goods-info .right-box {
        width: 100% !important;
        max-width: 100% !important;
        padding: 15px !important;
        margin: 0 !important;
        border-radius: 8px !important;
    }
    
    .goods-info .right-box .gtitle {
        font-size: 16px !important;
        line-height: 1.5 !important;
        font-weight: 600;
        margin-bottom: 8px;
    }
    
    .goods-info .right-box .stitle {
        font-size: 13px !important;
        line-height: 1.4 !important;
        margin-top: 8px !important;
        color: #666;
    }
    
    /* 微信二维码图片 */
    .pro_img_weixin {
        display: flex !important;
        justify-content: center;
        align-items: center;
        gap: 15px;
        margin: 20px 0 !important;
        padding: 15px;
        background: #f9f9f9;
        border-radius: 8px;
    }
    
    .pro_img_weixin img {
        max-width: 45% !important;
        height: auto !important;
        border-radius: 4px;
        box-shadow: 0 2px 8px rgba(0,0,0,0.1);
    }
    
    /* 商品详情区域 */
    .goods-detail {
        display: flex !important;
        flex-direction: column !important;
        margin-top: 15px !important;
        gap: 10px;
    }
    
    .goods-detail .left-box {
        display: none !important; /* 移动端隐藏侧边栏 */
    }
    
    .goods-detail .right-box {
        width: 100% !important;
        max-width: 100% !important;
        margin: 0 !important;
        border-radius: 8px !important;
    }
    
    .goods-detail .right-box .head-box {
        display: flex !important;
        justify-content: flex-start !important;
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
        border-bottom: 1px solid #e5e5e5;
    }
    
    .goods-detail .right-box .head-box .item-box {
        flex-shrink: 0;
        padding: 0 15px !important;
        height: 44px !important;
        font-size: 14px !important;
        white-space: nowrap;
    }
    
    .goods-detail .right-box .content {
        padding: 15px !important;
    }
    
    .goods-detail .right-box .content .param {
        display: flex !important;
        flex-direction: column !important;
        gap: 8px;
    }
    
    .goods-detail .right-box .content .param .text {
        width: 100% !important;
        padding: 8px 0 !important;
        font-size: 13px !important;
        border-bottom: 1px solid #f0f0f0;
    }
    
    .goods-detail .right-box .content .detail {
        padding-top: 15px !important;
    }
    
    .goods-detail .right-box .content .detail img {
        width: 100% !important;
        height: auto !important;
        display: block;
        margin: 10px 0;
    }
    
    .goods-detail .right-box .content .detail p {
        margin: 10px 0 !important;
        line-height: 1.6 !important;
        font-size: 14px;
    }
    
    /* 留言表单区域 */
    .tab-content {
        padding: 0 !important;
    }
    
    .content-box {
        padding: 10px !important;
    }
    
    .content-box .el-tabs {
        width: 100% !important;
    }
    
    .content-box .el-tabs__header {
        margin: 0 0 15px !important;
    }
    
    .content-box .el-tabs__item {
        padding: 0 15px !important;
        font-size: 14px !important;
    }
    
    .content-box .el-form {
        width: 100% !important;
    }
    
    .content-box .el-form-item {
        width: 100% !important;
        margin-bottom: 15px !important;
    }
    
    .content-box .el-form-item__label {
        width: 100% !important;
        text-align: left !important;
        float: none !important;
        display: block !important;
        padding: 0 0 8px 0 !important;
        line-height: 1.5 !important;
        font-size: 14px !important;
    }
    
    .content-box .el-form-item__content {
        width: 100% !important;
        margin-left: 0 !important;
    }
    
    .content-box .el-input,
    .content-box .el-textarea {
        width: 100% !important;
    }
    
    .content-box .el-input__inner {
        width: 100% !important;
        font-size: 16px !important; /* 防止iOS缩放 */
        padding: 10px 15px !important;
    }
    
    .content-box .el-textarea__inner {
        width: 100% !important;
        font-size: 16px !important; /* 防止iOS缩放 */
        padding: 10px 15px !important;
        min-height: 100px !important;
    }
    
    /* 底部按钮区域 */
    .footer-box {
        padding: 15px 10px !important;
        background: #fff;
        border-top: 1px solid #e5e5e5;
    }
    
    .footer-btn {
        display: flex !important;
        flex-direction: column !important;
        gap: 10px !important;
        width: 100%;
    }
    
    .footer-btn .el-button {
        width: 100% !important;
        margin: 0 !important;
        padding: 12px 20px !important;
        font-size: 15px !important;
    }
    
    /* Element UI 按钮优化 */
    .el-button {
        padding: 10px 20px !important;
        font-size: 14px !important;
    }
    
    .el-button--primary {
        background-color: #0D62BE !important;
        border-color: #0D62BE !important;
    }
    
    /* 隐藏桌面端特定元素 */
    .goods-info .left-box .btn-box {
        display: none !important;
    }
}

/* 小屏手机优化 */
@media screen and (max-width: 480px) {
    .goods-info .left-box .swiper-gallery {
        height: 240px !important;
    }
    
    .goods-info .left-box .swiper-thumbs .swiper-slide {
        width: 48px !important;
        height: 48px !important;
        margin: 0 3px !important;
    }
    
    .goods-info .right-box {
        padding: 12px !important;
    }
    
    .goods-info .right-box .gtitle {
        font-size: 15px !important;
    }
    
    .goods-info .right-box .stitle {
        font-size: 12px !important;
    }
    
    .pro_img_weixin {
        gap: 10px;
        padding: 12px;
    }
    
    .pro_img_weixin img {
        max-width: 46% !important;
    }
    
    .goods-detail .right-box .content {
        padding: 12px !important;
    }
    
    .content-box {
        padding: 8px !important;
    }
}

/* 超小屏幕优化 */
@media screen and (max-width: 375px) {
    .wrapper {
        padding: 0 8px !important;
    }
    
    .goods-info .left-box .swiper-gallery {
        height: 220px !important;
    }
    
    .goods-info .left-box .swiper-thumbs .swiper-slide {
        width: 45px !important;
        height: 45px !important;
    }
    
    .goods-info .right-box {
        padding: 10px !important;
    }
    
    .goods-info .right-box .gtitle {
        font-size: 14px !important;
    }
    
    .pro_img_weixin img {
        max-width: 45% !important;
    }
}

/* 横屏模式优化 */
@media screen and (max-width: 768px) and (orientation: landscape) {
    .goods-info .left-box .swiper-gallery {
        height: 200px !important;
    }
    
    .pro_img_weixin {
        margin: 15px 0 !important;
        padding: 10px;
    }
}
