/* ========== 产品详情页完整样式 ========== */
:root {
    /* 页面专属变量：不与全局（style.css）冲突 */
    --sidebar-width: 280px;
    --content-gap: 30px;
}
.page-container {
    max-width: var(--content-max-width);
    margin: 0 auto;
    padding: 0 20px;
    background: #fff;
    box-shadow: none;
}
/* 详情页页头不吸顶（仅产品详情页生效，避免与 Tab 吸顶互相遮挡） */
.single-myps_product .site-header {
    position: static;
}
.main-layout {
    display: grid;
    grid-template-columns: var(--sidebar-width) 1fr;
    gap: var(--content-gap);
    align-items: start;
    padding: 30px 0 60px;
}
.sidebar {
    position: -webkit-sticky;
    position: sticky;
    top: 20px;
    align-self: start;
}
.sidebar-block {
    background: #fff;
    border-radius: 8px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.05);
    margin-bottom: 20px;
    overflow: hidden;
    border: 1px solid #e0e0e0;
}
.sidebar-title {
    background: #fafafa;
    color: #222;
    padding: 14px 20px;
    font-size: 16px;
    font-weight: 600;
    letter-spacing: 0.5px;
    border-left: 4px solid var(--main-color);
    border-bottom: 1px solid #e0e0e0;
    display: flex;
    justify-content: space-between;
    align-items: center;
    cursor: default;
}
.accordion-arrow {
    display: none;
    font-size: 14px;
    transition: transform 0.3s;
}
.sidebar-body {
    padding: 14px 20px;
}
.category-list {
    list-style: none;
}
.category-list li {
    padding: 10px 0;
    border-bottom: 1px solid #f0f0f0;
}
.category-list li:last-child {
    border-bottom: none;
}
.category-list a {
    color: #444;
    text-decoration: none;
    font-size: 14px;
    transition: 0.2s;
    display: flex;
    justify-content: space-between;
    align-items: center;
}
.category-list a:hover {
    color: var(--main-color);
    padding-left: 4px;
}
/* 二级分类子列表：缩进嵌套，不与一级平级 */
.category-sub-list {
    list-style: none;
    padding-left: 16px;
}
.category-sub-list li {
    padding: 8px 0;
}
.category-sub-list a {
    font-size: 13px;
}
.hot-product-item {
    display: block;
    padding: 12px 0;
    border-bottom: 1px solid #f0f0f0;
    text-decoration: none;
    color: #333;
    transition: 0.2s;
}
.hot-product-item:last-child {
    border-bottom: none;
}
.hot-product-item:hover {
    color: var(--main-color);
}
.hot-product-item img {
    width: 100%;
    height: auto;
    aspect-ratio: 3/2;
    object-fit: cover;
    border-radius: 4px;
    margin-bottom: 8px;
}
.hot-product-name {
    font-size: 13px;
    line-height: 1.4;
}
.contact-info p {
    font-size: 13px;
    color: #555;
    margin-bottom: 8px;
    line-height: 1.5;
}
.contact-info p:last-child {
    margin-bottom: 0;
}
.contact-info a {
    color: var(--main-color);
    text-decoration: none;
}
.contact-info a:hover {
    text-decoration: underline;
}
.download-block {
    text-align: center;
}
.download-block .btn-pdf {
    width: 100%;
    height: 46px;
    font-size: 14px;
    border: 2px solid var(--main-color);
    background: transparent;
    color: var(--main-color);
    border-radius: var(--btn-radius);
    cursor: pointer;
    font-weight: 600;
    transition: 0.25s ease;
    margin-top: 8px;
}
.download-block .btn-pdf:hover {
    background-color: var(--main-color);
    color: #fff;
}
.download-desc {
    font-size: 12px;
    color: #999;
    margin-top: 8px;
}
.product-top-wrap {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 40px;
    padding-bottom: 40px;
    align-items: start;
}
.img-box {
    position: relative;
}
.main-image {
    width: 100%;
    aspect-ratio: 3/2;
    object-fit: cover;
    cursor: zoom-in;
    border-radius: 6px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
}
.thumbnail-list {
    display: flex;
    gap: 10px;
    margin-top: 12px;
    flex-wrap: wrap;
}
.thumbnail-item {
    width: 80px;
    height: 80px;
    object-fit: cover;
    border-radius: 4px;
    cursor: pointer;
    border: 2px solid transparent;
    transition: 0.2s;
    opacity: 0.7;
    flex-shrink: 0;
}
.thumbnail-item.active {
    border-color: var(--main-color);
    opacity: 1;
}
.thumbnail-item:hover {
    opacity: 1;
}
.info-box h1 {
    font-size: 30px;
    color: #111;
    margin-bottom: 16px;
    line-height: 1.3;
    font-weight: 700;
}
.desc-text {
    font-size: 15px;
    color: #555;
    margin-bottom: 24px;
    line-height: 1.8;
}
.param-list {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 12px;
    margin-bottom: 28px;
}
.param-item {
    padding: 14px 16px;
    background-color: #fafafa;
    border: 1px solid #e8e8e8;
    border-radius: 6px;
    display: flex;
    flex-direction: column;
}
.param-name {
    font-size: 13px;
    color: #777;
    margin-bottom: 4px;
}
.param-value {
    font-size: 16px;
    font-weight: 600;
    color: #222;
}
.btn-group-hero {
    display: none;
    gap: 14px;
    flex-wrap: wrap;
}
.btn {
    height: 50px;
    padding: 0 26px;
    font-size: 15px;
    border-radius: var(--btn-radius);
    cursor: pointer;
    border: none;
    font-weight: 600;
    transition: 0.25s ease;
    white-space: nowrap;
}
.btn-inquiry {
    background-color: var(--main-color);
    color: #fff;
}
.btn-inquiry:hover {
    background-color: var(--main-dark);
}
.tab-nav-wrap {
    width: 100%;
    background: #fff;
    border-bottom: 1px solid #eee;
    position: -webkit-sticky;
    position: sticky;
    top: 0; /* 详情页页头不吸顶，Tab 吸顶贴视口顶部 */
    z-index: 999;
    transition: box-shadow 0.25s ease;
    margin: 0 -20px;
    padding: 0 20px;
}
.tab-nav-wrap.is-stuck {
    box-shadow: 0 3px 12px rgba(0, 0, 0, 0.1);
    border-bottom: 2px solid var(--main-color);
}
.tab-nav-container {
    max-width: var(--content-max-width);
    margin: 0 auto;
    display: flex;
    align-items: center;
    justify-content: space-between;
    width: 100%;
    max-width: 100%;
}
.tab-list {
    display: flex;
    flex-wrap: wrap;
    gap: 0;
}
.tab-nav-item {
    padding: 18px 22px;
    font-size: 15px;
    cursor: pointer;
    color: #444;
    position: relative;
    white-space: nowrap;
    transition: 0.2s;
    font-weight: 500;
}
.tab-nav-item.active {
    color: var(--main-color);
    font-weight: 600;
}
.tab-nav-item.active::after {
    content: "";
    width: 100%;
    height: 3px;
    background: var(--main-color);
    position: absolute;
    bottom: -1px;
    left: 0;
}
.btn-group-nav {
    display: flex;
    gap: 12px;
}
.section-wrap {
    padding: 50px 0;
    scroll-margin-top: 70px; /* 仅 Tab 吸顶高度 */
}
.section-wrap h2 {
    font-size: 24px;
    margin-bottom: 24px;
    color: #111;
    position: relative;
    padding-bottom: 10px;
    font-weight: 700;
}
.section-wrap h2::after {
    content: "";
    width: 50px;
    height: 3px;
    background: var(--main-color);
    position: absolute;
    left: 0;
    bottom: 0;
}
.section-bg-gray {
    background: #f8f8f8;
    margin: 0 -20px;
    padding-left: 20px;
    padding-right: 20px;
}
.advantages-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 18px;
}
.advantage-item {
    background: #fff;
    padding: 20px;
    border-radius: 8px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);
    border: 1px solid #e8e8e8;
    border-bottom: 3px solid var(--main-color);
    transition: 0.3s;
}
.advantage-item:hover {
    transform: translateY(-3px);
    box-shadow: 0 6px 16px rgba(0, 0, 0, 0.08);
}
.advantage-item h4 {
    margin-bottom: 8px;
    font-size: 16px;
    color: #222;
    font-weight: 600;
}
.advantage-item p {
    font-size: 13px;
    color: #666;
    line-height: 1.7;
}
.spec-top-control {
    display: flex;
    gap: 10px;
    margin-bottom: 18px;
}
.spec-control-btn {
    padding: 8px 16px;
    border: 1px solid #ddd;
    background: #fff;
    border-radius: var(--btn-radius);
    cursor: pointer;
    transition: 0.2s;
    font-size: 14px;
}
.spec-control-btn:hover {
    border-color: var(--main-color);
    color: var(--main-color);
}
.spec-container {
    display: grid;
    grid-template-columns: 1fr;
    gap: 14px;
}
.spec-group {
    background: #fff;
    border-radius: 8px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);
    overflow: hidden;
    border: 1px solid #eee;
}
.spec-group-title {
    background: #f5f5f5;
    color: #222;
    padding: 14px 20px;
    font-size: 15px;
    font-weight: 600;
    cursor: pointer;
    display: flex;
    justify-content: space-between;
    align-items: center;
    user-select: none;
}
.spec-group-title .arrow {
    transition: transform 0.32s cubic-bezier(0.4, 0, 0.2, 1);
    font-size: 12px;
}
.spec-group-title.open .arrow {
    transform: rotate(180deg);
}
.spec-group-list {
    padding: 8px 0;
    max-height: 0;
    overflow: hidden;
    transition: var(--transition-smooth);
}
.spec-row {
    display: flex;
    padding: 10px 20px;
    border-bottom: 1px solid #f0f0f0;
    font-size: 14px;
}
.spec-row:last-child {
    border-bottom: none;
}
.spec-label {
    width: 45%;
    color: #666;
}
.spec-value {
    width: 55%;
    font-weight: 500;
    color: #222;
}
.gallery-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 18px;
}
.gallery-grid img {
    aspect-ratio: 3/2;
    object-fit: cover;
    border-radius: 6px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.06);
    transition: none;
    cursor: zoom-in;
}
.case-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 20px;
}
.case-item {
    display: block;
    background: #fff;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);
    transition: 0.3s;
    text-decoration: none;
    color: inherit;
    border: 1px solid #eee;
}
.case-item:hover {
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.1);
    transform: translateY(-3px);
}
.case-item img {
    width: 100%;
    aspect-ratio: 3/2;
    object-fit: cover;
}
.case-text {
    padding: 14px 16px;
}
.case-text h4 {
    margin-bottom: 6px;
    font-size: 16px;
    color: #222;
    font-weight: 600;
}
.case-text p {
    color: #666;
    font-size: 13px;
    line-height: 1.6;
}
.video-wrap {
    position: relative;
    aspect-ratio: 16/9;
    background: #000;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.1);
}
.video-placeholder {
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #fff;
    font-size: 17px;
    background: linear-gradient(135deg, #1a1a1a, #333);
    font-weight: 500;
}
.accessories-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 18px;
}
.accessory-item {
    background: #fff;
    border-radius: 8px;
    padding: 20px 16px;
    text-align: center;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);
    transition: 0.3s;
    border: 1px solid #eee;
}
.accessory-item:hover {
    transform: translateY(-4px);
    box-shadow: 0 8px 18px rgba(0, 0, 0, 0.08);
}
.accessory-item img {
    width: 70px;
    height: 70px;
    object-fit: contain;
    margin: 0 auto 12px;
    transition: none;
}
.accessory-item h4 {
    font-size: 14px;
    color: #222;
    margin-bottom: 4px;
    font-weight: 600;
}
.accessory-item p {
    font-size: 12px;
    color: #777;
}
.application-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 18px;
}
.application-item {
    position: relative;
    border-radius: 8px;
    overflow: hidden;
    aspect-ratio: 16/9;
    cursor: pointer;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.08);
}
.application-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.4s ease;
}
.application-item:hover img {
    transform: scale(1.08);
}
.application-overlay {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    padding: 24px;
    background: linear-gradient(transparent, rgba(0,0,0,0.8));
    color: #fff;
}
.application-overlay h4 {
    font-size: 18px;
    margin-bottom: 4px;
    font-weight: 600;
}
.application-overlay p {
    font-size: 13px;
    opacity: 0.9;
}
.related-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 20px;
}
.related-item {
    background: #fff;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);
    transition: 0.3s;
    border: 1px solid #eee;
}
.related-item:hover {
    box-shadow: 0 8px 18px rgba(0, 0, 0, 0.08);
    transform: translateY(-3px);
}
.related-item img {
    width: 100%;
    aspect-ratio: 3/2;
    object-fit: cover;
}
.related-name {
    padding: 14px 16px;
    font-size: 14px;
    font-weight: 600;
    text-align: center;
}
.related-item a {
    color: #222;
    text-decoration: none;
    display: block;
}
.faq-item {
    background: #fff;
    border-radius: 6px;
    margin-bottom: 10px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.04);
    overflow: hidden;
    border: 1px solid #eee;
}
.faq-question {
    padding: 14px 20px;
    font-weight: 600;
    cursor: pointer;
    display: flex;
    justify-content: space-between;
    align-items: center;
    user-select: none;
    background: #f5f5f5;
    transition: 0.2s;
    font-size: 15px;
}
.faq-question.open {
    color: var(--main-color);
}
.faq-question .arrow {
    transition: transform 0.32s cubic-bezier(0.4, 0, 0.2, 1);
    display: inline-block;
    font-size: 12px;
}
.faq-question.open .arrow {
    transform: rotate(180deg);
}
.faq-answer {
    max-height: 0;
    overflow: hidden;
    transition: var(--transition-smooth);
}
.faq-answer-inner {
    padding: 12px 20px 16px;
    color: #555;
    font-size: 14px;
    line-height: 1.8;
}
/* ===== 修改：表单容器铺满 ===== */
.inquiry-form {
    width: 100%;
    max-width: 100%;
    margin: 0;
    background: #fff;
    padding: 28px;
    border-radius: 8px;
    box-shadow: 0 2px 12px rgba(0, 0, 0, 0.06);
    border: 1px solid #eee;
}
.lightbox {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.92);
    z-index: 9999;
    display: none;
    align-items: center;
    justify-content: center;
    padding: 20px;
}
.lightbox.show {
    display: flex;
}
.lightbox-close {
    position: absolute;
    top: 15px;
    right: 25px;
    color: #fff;
    font-size: 36px;
    cursor: pointer;
    line-height: 1;
    z-index: 10;
    font-weight: 300;
}
.lightbox-prev,
.lightbox-next {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    width: 44px;
    height: 44px;
    border-radius: 50%;
    background: rgba(255,255,255,0.2);
    border: none;
    color: #fff;
    font-size: 22px;
    cursor: pointer;
    z-index: 10;
    transition: 0.2s;
}
.lightbox-prev:hover,
.lightbox-next:hover {
    background: rgba(255,255,255,0.3);
}
.lightbox-prev { left: 20px; }
.lightbox-next { right: 20px; }
.lightbox-img {
    max-width: 92%;
    max-height: 92%;
    object-fit: contain;
    border-radius: 4px;
}

/* ========== 平板端适配 ========== */
@media (max-width: 1024px) and (min-width: 769px) {
    .main-layout {
        grid-template-columns: 240px 1fr;
        gap: 24px;
    }
    .sidebar-title {
        font-size: 15px;
        padding: 12px 16px;
    }
    .sidebar-body {
        padding: 12px 16px;
    }
    .product-top-wrap {
        gap: 30px;
    }
    .info-box h1 {
        font-size: 26px;
    }
    .advantages-grid,
    .related-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    .case-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    .tab-nav-item {
        padding: 16px 18px;
        font-size: 14px;
    }
    .btn-group-nav {
        display: none;
    }
}

/* ========== 手机端适配 ========== */
@media (max-width: 768px) {
    .page-container {
        padding: 0 15px;
        overflow-x: visible;
    }
    .main-layout {
        grid-template-columns: 1fr;
        padding: 20px 0 40px;
    }
    .sidebar {
        display: block;
        position: static;
        margin-bottom: 20px;
    }
    .sidebar-block {
        margin-bottom: 10px;
        border: 1px solid #e0e0e0;
        box-shadow: 0 2px 8px rgba(0,0,0,0.05);
    }
    .sidebar-title {
        cursor: pointer;
        background: #fafafa;
        border-left: 4px solid var(--main-color);
        border-bottom: 1px solid #e0e0e0;
        padding: 12px 16px;
    }
    .accordion-arrow {
        display: inline-block;
        font-size: 14px;
        transition: transform 0.3s;
    }
    .sidebar-block.collapsed .accordion-arrow {
        transform: rotate(-90deg);
    }
    .sidebar-body {
        max-height: 0;
        overflow: hidden;
        padding: 0 16px;
        transition: max-height 0.32s ease, padding 0.32s ease;
    }
    .sidebar-block.open .sidebar-body {
        max-height: 500px;
        padding: 12px 16px;
    }
    .product-top-wrap {
        grid-template-columns: 1fr;
        padding-bottom: 24px;
        gap: 20px;
    }
    .info-box h1 {
        font-size: 20px;
        margin-bottom: 12px;
    }
    .desc-text {
        font-size: 14px;
        margin-bottom: 20px;
        line-height: 1.7;
    }
    .thumbnail-item {
        width: 64px;
        height: 64px;
    }
    .thumbnail-list {
        gap: 8px;
        margin-top: 10px;
    }
    .param-list {
        grid-template-columns: 1fr;
        gap: 10px;
        margin-bottom: 24px;
    }
    .param-item {
        flex-direction: row;
        justify-content: space-between;
        align-items: center;
        gap: 10px;
        padding: 12px 14px;
    }
    .param-name {
        margin-bottom: 0;
        flex-shrink: 0;
        font-size: 13px;
    }
    .param-value {
        text-align: right;
        font-size: 15px;
    }
    .btn-group-hero {
        display: flex;
    }
    .btn-group-hero .btn {
        width: 100%;
    }
    .btn-group-hero .btn-pdf {
        display: none;
    }
    .btn-group-nav {
        display: none;
    }
    .tab-nav-wrap {
        margin: 0 -15px;
        padding: 0 15px;
        top: 0;
        width: 100%;
        left: 0;
        right: 0;
    }
    .tab-nav-container {
        overflow-x: visible;
        -webkit-overflow-scrolling: auto;
        scrollbar-width: auto;
        width: 100%;
        max-width: 100%;
    }
    .tab-list {
        flex-wrap: wrap;
        width: 100%;
        gap: 4px 0;
    }
    .tab-nav-item {
        flex: 1 0 auto;
        text-align: center;
        padding: 12px 8px;
        font-size: 13px;
        white-space: nowrap;
        border-bottom: 1px solid #f0f0f0;
    }
    .tab-nav-item.active::after {
        bottom: -1px;
    }
    .section-wrap {
        padding: 30px 0;
        scroll-margin-top: 58px; /* 仅 Tab 吸顶高度 */
    }
    .section-wrap h2 {
        font-size: 20px;
        margin-bottom: 18px;
    }
    .section-bg-gray {
        margin: 0 -15px;
        padding-left: 15px;
        padding-right: 15px;
    }
    .advantages-grid,
    .application-grid,
    .accessories-grid {
        grid-template-columns: 1fr;
    }
    .advantage-item {
        padding: 16px 14px;
    }
    .advantage-item h4 {
        font-size: 14px;
    }
    .advantage-item p {
        font-size: 12px;
        line-height: 1.6;
    }
    /* 手机端详情图：纵向堆叠，图片宽度 100% */
    .gallery-grid {
        display: grid;
        grid-template-columns: 1fr;
        gap: 10px;
    }
    .gallery-grid img {
        width: 100%;
    }
    .application-grid {
        gap: 10px;
    }
    .application-overlay {
        padding: 12px;
    }
    .application-overlay h4 {
        font-size: 13px;
    }
    .application-overlay p {
        font-size: 11px;
    }
    .accessories-grid {
        gap: 12px;
    }
    .accessory-item {
        padding: 16px 12px;
    }
    .accessory-item img {
        width: 60px;
        height: 60px;
    }
    .accessory-item h4 {
        font-size: 13px;
    }
    .case-grid {
        grid-template-columns: 1fr;
        gap: 14px;
    }
    .related-grid {
        grid-template-columns: 1fr 1fr;
        gap: 12px;
    }
    .related-name {
        padding: 12px;
        font-size: 13px;
    }
    .spec-row {
        flex-wrap: nowrap;
        padding: 10px 16px;
        font-size: 13px;
    }
    .spec-label {
        width: 45%;
        flex-shrink: 0;
    }
    .spec-value {
        width: 55%;
        text-align: right;
        word-break: break-word;
    }
    .spec-group-title {
        padding: 12px 16px;
        font-size: 14px;
    }
    .faq-question {
        padding: 12px 16px;
        font-size: 14px;
    }
    .faq-answer-inner {
        padding: 10px 16px 14px;
        font-size: 13px;
    }
    .inquiry-form {
        padding: 20px;
    }
    .lightbox {
        padding: 10px;
    }
    .lightbox-close {
        top: 10px;
        right: 15px;
        font-size: 30px;
    }
    .lightbox-prev,
    .lightbox-next {
        width: 36px;
        height: 36px;
        font-size: 18px;
    }
    .lightbox-prev { left: 10px; }
    .lightbox-next { right: 10px; }
}