/* ✅ 只作用于产品详情页的内容区域，不影响导航栏 */
.product-detail .container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 40px 20px;
    margin-top: -100px;
}

.back {
    margin-bottom: 20px
}

.back a {
    color: #fa709a;
    text-decoration: none
}

.product-header {
    background: #fff;
    border-radius: 12px;
    padding: 30px;
    margin-bottom: 30px
}

.product-header h1 {
    font-size: 26px;
    color: #1a2b48;
    margin-bottom: 10px
}

.cate {
    display: inline-block;
    padding: 4px 10px;
    background: #fef1f6;
    color: #fa709a;
    border-radius: 4px;
    font-size: 14px
}

/* 产品主图样式 */
.product-image {
    background: #fff;
    border-radius: 12px;
    padding: 30px;
    margin-bottom: 20px;
    text-align: center;
    display: flex;
    justify-content: center;
    align-items: center;
}

.product-image img {
    max-width: 100%;
    height: auto;
    max-height: 400px;
    object-fit: contain;
    border-radius: 8px;
    display: block;
    margin: 0 auto;
}

/* 多图片并排样式 - 横向滚动 */
.product-images-wrapper {
    position: relative;
    margin-top: -50px;
    margin-bottom: 20px;
}

.product-images {
    background: #fff;
    border-radius: 12px;
    padding: 30px;
    display: flex;
    gap: 20px;
    overflow-x: auto;
    scroll-behavior: smooth;
    scrollbar-width: none; /* Firefox */
    -ms-overflow-style: none; /* IE and Edge */
}

.product-images::-webkit-scrollbar {
    display: none; /* Chrome, Safari, Opera */
}

.product-image-item {
    min-width: calc(33.333% - 14px);
    flex-shrink: 0;
    text-align: center;
    display: flex;
    justify-content: center;
    align-items: center;
}

.product-image-item img {
    width: 100%;
    height: auto;
    max-height: 300px;
    object-fit: contain;
    border-radius: 8px;
    display: block;
}


/* 滚动按钮样式 */
.scroll-btn {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background: rgba(250, 112, 154, 0.8);
    color: white;
    border: none;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    font-size: 20px;
    cursor: pointer;
    z-index: 10;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
}

.scroll-btn:hover {
    background: rgba(250, 112, 154, 1);
    transform: translateY(-50%) scale(1.1);
}

.scroll-left {
    left: 10px;
}

.scroll-right {
    right: 10px;
}

.section {
    background: #fff;
    border-radius: 12px;
    padding: 30px;
    margin-bottom: -10px
}

.section h2 {
    font-size: 20px;
    color: #1a2b48;
    margin-bottom: 16px;
    border-left: 4px solid #fa709a;
    padding-left: 12px
}

.section p {
    color: #555;
    margin-bottom: 10px
}

.section ul {
    padding-left: 20px;
    color: #555
}

.section li {
    margin-bottom: 8px
}

/* 技术参数表格样式 - 靠左对齐 */
.spec-table {
    width: 100%;
    border-collapse: collapse;
    margin: 12px 0;
    font-size: 15px;
    color: #555;
}

.spec-table tr {
    border-bottom: 1px solid #f0f0f0;
}

.spec-table tr:last-child {
    border-bottom: none;
}

.spec-table th,
.spec-table td {
    padding: 10px 16px;
    text-align: left;
    vertical-align: top;
    line-height: 1.6;
}

.spec-table th {
    width: 150px;
    min-width: 120px;
    color: #1a2b48;
    font-weight: 600;
    background: #f9fafb;
    white-space: nowrap;
}

.spec-table td {
    color: #555;
}

/* 子标题行（如"设定精度""回读精度""分辨率"） */
.spec-table .sub-header {
    background: #fef1f6;
    color: #fa709a;
    font-weight: 600;
    font-size: 14px;
}

.spec-table .sub-header td {
    color: #fa709a;
    font-weight: 600;
}

/* 小标题（h4）旁边的表格间距微调 */
h4 + .spec-table {
    margin-top: 4px;
}

/* 移动端适配 */
@media (max-width: 768px) {
    .spec-table {
        font-size: 14px;
    }
    .spec-table th,
    .spec-table td {
        padding: 8px 12px;
    }
    .spec-table th {
        width: 110px;
        min-width: 90px;
    }
}

.img-box {
    height: 450px;
    width:  80%;
    background: #eef2f7;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 24px;
    margin: 20px -30px
}

.img-box img {
    width: 100%;
    height: 100%;
}

/* 咨询浮动按钮 */
.consult-float {
    position: fixed;
    bottom: 100px;
    right: 30px;
    z-index: 100
}

.consult-btn {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 15px 25px;
    background: linear-gradient(135deg, #fa709a 0%, #fee140 100%);
    color: #fff;
    text-decoration: none;
    border-radius: 50px;
    font-weight: bold;
    font-size: 16px;
    box-shadow: 0 4px 15px rgba(250, 112, 154, .4);
    transition: .3s
}

.consult-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(250, 112, 154, .5)
}

.cta {
    background: linear-gradient(135deg, #fa709a 0%, #fee140 100%);
    color: #fff;
    text-align: center;
    padding: 30px;
    border-radius: 12px;
}

.cta h2 {
    margin-bottom: 20px;
}

.cta-buttons {
    display: flex;
    gap: 15px;
    justify-content: center;
    flex-wrap: wrap;
}

.cta-buttons a {
    display: inline-block;
    padding: 12px 30px;
    border-radius: 6px;
    font-weight: bold;
    text-decoration: none;
    transition: all 0.3s ease;
}

.btn-primary {
    background: #fff;
    color: #fa709a;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 16px rgba(0, 0, 0, 0.2);
}

.btn-secondary {
    background: transparent;
    color: #fff;
    border: 2px solid #fff;
}

.btn-secondary:hover {
    background: rgba(255, 255, 255, 0.2);
    transform: translateY(-2px);
}

/* ======================================
   产品详情页响应式媒体查询
   ====================================== */

/* 平板适配 */
@media (max-width: 1024px) {
    .product-detail .container {
        padding: 30px 20px;
    }
}

/* 移动端适配 */
@media (max-width: 768px) {
    .product-detail .container {
        padding: 20px 15px;
    }
    
    .back {
        margin-bottom: 15px;
        font-size: 14px;
    }
    
    .product-header {
        padding: 20px;
        margin-bottom: 20px;
    }
    
    .product-header h1 {
        font-size: 22px;
    }
    
    .section {
        padding: 20px;
        margin-bottom: 15px;
    }
    
    .section h2 {
        font-size: 18px;
        margin-bottom: 12px;
    }
    
    .section p,
    .section li {
        font-size: 14px;
    }
    
    /* 产品图片移动端适配 */
    .product-image {
        padding: 20px;
        margin-bottom: 15px;
    }
    
    .product-image img {
        max-height: 300px;
    }
    
    /* 多图片移动端适配 */
    .product-images-wrapper {
        margin-top: -30px;
    }
    
    .product-images {
        padding: 20px;
        margin-bottom: 15px;
    }
    
    .product-image-item {
        min-width: calc(80% - 10px);
    }
    
    .product-image-item img {
        max-height: 250px;
    }
    
    .scroll-btn {
        width: 35px;
        height: 35px;
        font-size: 16px;
    }
    
    /* 图片自适应 */
    .img-box {
        height: auto !important;
        width: 100% !important;
        margin: 15px 0 !important;
        padding: 0 !important;
    }
    
    .img-box img {
        width: 100% !important;
        height: auto !important;
    }
    
    /* CTA区域调整 */
    .cta {
        padding: 20px;
    }
    
    .cta h2 {
        font-size: 18px;
        margin-bottom: 12px;
    }
    
    .cta a {
        padding: 8px 20px;
        font-size: 14px;
    }
}

/* 小屏手机适配 */
@media (max-width: 480px) {
    .product-header h1 {
        font-size: 20px;
    }
    
    .section {
        padding: 15px;
    }
    
    .section h2 {
        font-size: 17px;
    }
    
    .section p,
    .section li {
        font-size: 13px;
    }
}
