/* ==========================================================
YUE YUAN LIGHTING - PRODUCT PAGE SYSTEM V3.0
Professional B2B Stage Lighting Detail Page Architecture
========================================================== */

/* ===============================
1. GLOBAL SETTINGS (基础全局设置)
================================ -->
* {
    box-sizing: border-box;
}

body {
    margin: 0;
    padding: 0;
    font-family: "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
    line-height: 1.5;
    color: #333333;
    background-color: #ffffff !important; 
}

/* 统一容器最大宽度，确保整站对齐 */
.site-container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 8px;
}

.hidden-ai-content {
    display: none !important;
}

p, span, li, a {
    color: #333333;
}

.section-lead, p.section-lead, section p, .product-section p {
    color: #444444 !important;
}

#site-header {
    min-height: 72px; 
    width: 100%;
    background: #000;
}

/* ===============================
2. SECTIONS & TYPOGRAPHY STANDARDS (统一间距与排版规范)
================================ */
section,
.product-section {
    max-width: 1200px;
    margin: 0 auto;
    padding: 6px 0 !important; /* 精简上下空白间距 */
    border-top: 1px solid #eee;
    background: #ffffff;
}

.product-section:first-of-type {
    border-top: none;
}

/* 统一重置所有 H 标题和列表的尺寸与对齐（严格遵循用户总结） */
h1, .product-section h1, .product-hero h1 {
    font-size: 1.2em !important;
    padding: 7px 0 !important;
    line-height: 1.0 !important;
    font-weight: 500 !important;
    margin: 0 0 8px 0 !important;
    text-align: left !important;
    color: #111111 !important;
}

h2, .product-section h2, .product-comparison h2, .product-faq h2, .buying-guide h2, .related-products-section h2, .engineering-inquiry-section h2 {
    font-size: 1.1em !important;
    padding: 6px 0 !important;
    line-height: 1.0 !important;
    font-weight: 500 !important;
    margin: 0 0 8px 0 !important;
    text-align: left !important; /* 强制所有 h2 居左 */
    color: #111111 !important;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

h3, .product-section h3, .guide-card h3, .related-content h3 {
    font-size: 1.0em !important;
    padding: 6px 0 !important;
    margin: 0 0 6px 0 !important;
    font-weight: 450 !important;
    text-align: left;
    color: #111111 !important;
}

.product-section li, ul li {
    font-size: 0.9em !important;
    padding: 5px 0 !important;
    line-height: 0.90;
    margin-bottom: 0 !important;
    color: #444;
}

.product-section h4 {  
    font-size: 0.9em !important;   
    margin: 5px 0 4px 0;   
    font-weight: 450;   
    color: #000;   
    border-bottom: 1px solid #eee;   
    padding-bottom: 4px;   
    display: inline-block;  
}
       
.product-section ul {
    margin: 4px 0 4px 18px;  
    padding-left: 0;  
    list-style: disc;   
}

.section-lead {
    font-size: 1.0em;
    line-height: 1.0;
    max-width: 900px;
    margin: 0 0 05px 0;
    text-align: left !important;
    color: #555;
}

/* 兼容浅灰横幅背景区块 */
#related-products, .light-section-fix, .package-section {
    background-color: #f8f9fa;
    color: #333333;
    max-width: 100%; 
    padding: 8px 0; 
}

#related-products > div, .light-section-fix > div, .package-section > div {  
    max-width: 1200px;  
    margin: 0 auto;
    padding: 0 8px;
} 

/* ==========================================================
3. PRODUCT HERO & Gallery
========================================================== */
.product-hero-content h1,
.product-hero h1 {
    font-size: 1.3em !important;
    padding: 8px 0 !important;
}

.hero-description p {
    margin-bottom: 4px;
    line-height: 1.0;
}

.product-hero-content p {
    font-size: 1.1em;
    line-height: 1.0;
    color: #475569;
    max-width: 1100px;
    margin-bottom: 8px;
}

.product-hero-inner {
    display: grid;
    grid-template-columns: 580px 1fr;
    gap: 8px;
    align-items: start;
    max-width: 1400px;
    margin: 0 auto;
}

.product-gallery {
    width: 100%;
}

.main-image, .product-gallery img {
    width: 100%;
    aspect-ratio: 1 / 1;
    object-fit: contain;
    border: 1px solid #eee;
    background: #fff;
    display: block;
}

.thumbs, .gallery-thumbnails {
    display: flex;
    gap: 8px;
    margin-top: 6px;
    flex-wrap: wrap;
}

.thumbs img, .gallery-thumbnails img {
    width: 75px;
    height: 75px;
    object-fit: contain;
    border: 1px solid #ddd;
    cursor: pointer;
    background: #fff;
}

.gallery-thumbnails .thumb-item:hover img, 
.gallery-thumbnails .thumb-item.active img {
    border-color: #ff6600;
}

.product-meta strong {
    display: block;
    margin-bottom: 4px;
    color: #111111;
}

.key-highlights {
    margin-top: 6px;
}

.key-highlights ul {
    display: grid;
    gap: 6px;
    padding-left: 0;
    list-style: none;
}

.key-highlights li {
    display: flex;
    align-items: flex-start;
    gap: 6px;
    color: #475569;
    padding: 4px 0 !important;
}

.key-highlights li::before {
    content: "✓";
    font-weight: bold;
    color: #16a34a;
}

.product-actions {
    display: flex;
    gap: 6px;
    margin-top: 4px;
    flex-wrap: wrap;
}

/* VIDEO MODAL */
.video-modal {
    display: none;    
    position: fixed;   
    z-index: 9999;   
    top: 0;   
    left: 0;   
    width: 100%;   
    height: 100%;  
    background: rgba(0,0,0,.85);   
    align-items: center;   
    justify-content: center;   
}
     
.video-modal.active {  
    display: flex;  
}
       
.video-modal-content {   
    width: 90%;  
    max-width: 1000px;  
    position: relative;  
}
    
.video-modal iframe { 
    width: 100%; 
    aspect-ratio: 16/9; 
}
      
.video-close {   
    position: absolute;  
    right: -45px;   
    top: -35px;   
    font-size: 40px;  
    color: #fff;  
    background: none; 
    border: none;
    cursor: pointer;
}

/* ===============================
4. SPECIFICATION SECTION
================================ */
.spec-grid {
    display: flex;
    gap: 15px;
    align-items: flex-start;
}

.spec-grid > div {
    flex: 1;
}

.features-grid, .package-grid, .case-grid {
    display: flex;
    gap: 10px;
    margin-top: 8px;
}

/* 链接按钮醒目样式 */
.download-link,
.lighting-notice a,
.lighting-designer-notice a {
    color: #ffffff !important;
    background: #2563eb !important;
    padding: 6px 12px;
    border-radius: 6px;
    display: inline-block;
    text-decoration: none;
    font-weight: 450;
    margin-top: 5px;
}
.download-link:hover,
.lighting-notice a:hover,
.lighting-designer-notice a:hover {
    background: #1d4ed8 !important;
}

/* ==========================================================
5. PRODUCT COMPARISON & BUYING GUIDE
========================================================== */
.product-comparison {
    padding: 8px 0;
    background: #ffffff !important; 
    color: #111827 !important;
}

.buying-guide {
    padding: 8px 0;
    background: #ffffff !important;
    color: #111827 !important;
}

.guide-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 10px;
    margin-top: 6px;
}

.guide-card {
    background: #ffffff !important;
    padding: 10px;
    border-radius: 8px;
    border: 1px solid #e5e7eb !important;
    box-shadow: 0 4px 12px rgba(0,0,0,0.03);
}

.guide-card p {
    font-size: 0.9em !important;
    padding: 4px 0 !important;
    color: #475569 !important;
}

/* ==========================================================
6. APPLICATION & PROJECT CASES
========================================================== */
.case-grid {
    display: grid;
    max-width: 1000px;
    grid-template-columns: repeat(3, 1fr);
    gap: 15px;
    margin: 15px auto;
}

.case-item {
    flex: 1;
    text-align: center;
}

.case-item img {
    width: 100%;
    height: 200px; /* 适当降低高度，避免图片过大 */
    object-fit: cover;
    border-radius: 8px;
    border: 1px solid #eee;
}  

.case-item span, .product-card span {
    display: block;
    margin-top: 8px;
    font-size: 13px;
    font-weight: 600;
    color: #222;
}  

/* ==========================================================
7. RELATED PRODUCTS
========================================================== */
.related-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 15px;
    margin-top: 6px;
}

.related-card {
    background: #ffffff;
    border: 1px solid #e5e7eb;
    border-radius: 8px;
    overflow: hidden;
    transition: .25s ease;
}

.related-card img {
    width: 100%;
    height: 180px; /* 控制图片高度适中 */
    object-fit: contain;
    padding: 8px;
    background: #fff;
    display: block;
}

.related-content {
    padding: 10px;
}

.related-category {
    display: block;
    color: #ff6600;
    font-size: 12px;
    margin-bottom: 6px;
}

.related-content p {
    font-size: 1em !important;
    padding: 4px 0 !important;
    color: #475569;
}

/* ==========================================================
8. FAQ FIX
========================================================== */
.product-faq,
.product-faq .faq-item,
.faq-question,
.faq-answer {
    background: #ffffff;
    color: #111827;
}

.faq-question {
    border: 1px solid #e5e7eb;
    border-radius: 4px;
    padding: 8px;
    margin-bottom: 4px;
    font-weight: 450;
}

.faq-answer {
    border: 1px solid #e5e7eb;
    border-top: none;
    border-radius: 0 0 4px 4px;
    padding: 6px;
    margin-top: -8px;
    margin-bottom: 6px;
}

/* ===============================
9. BOTTOM WIDGET & INQUIRY (修复AI助手折叠点击失效)
================================ */
.floating-faq-widget {
    max-width: 1200px;
    margin: 8px auto;
    padding: 0 7px;
    position: relative !important;
}

.ai-toggle-btn {
    background: #111111 !important;
    color: #ffffff !important;
    width: 100% !important;
    text-align: left !important;
    padding: 10px 16px;
    border-radius: 6px !important;
    font-size: 1rem !important;
    border: none !important;
    cursor: pointer !important;
    display: flex !important;
    justify-content: space-between !important;
    align-items: center !important;
    z-index: 10;
}

/* 核心：确保折叠面板默认隐藏，激活状态(`.active`)下显示，解决点击无反应问题 */
.ai-panel-content {
    display: none !important; 
    background: #fdfdfd !important;
    border: 1px solid #ddd !important;
    border-top: none !important;
    border-radius: 0 0 6px 6px !important;
    padding: 10px !important;
}
.ai-panel-content.active,
.ai-panel-content.show {
    display: block !important;
}

.inquiry-box {
    background: #f8f9fa !important;
    border: 1px solid #e5e5e5 !important;
    border-radius: 6px !important;
    padding: 10px !important;
    max-width: 1400px !important;
    margin: 0 auto !important;
}

.engineering-inquiry-section,
#inquiry-container {
    width: 100%;
    background: #f8fafc;
    padding: 10px 0;
    border-top: 1px solid #e5e7eb;
}

/* ==========================================================
10. PRINT & RESPONSIVE
========================================================== */
@media print {
    #siteHeader, #siteFooter, video, button {
        display: none !important;
    }
    body {
        background: #ffffff !important;
        color: #000000 !important;
    }
}

@media(max-width: 1100px) {
    .related-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media(max-width: 992px) {
    .product-hero-inner, .spec-grid, .features-grid, .package-grid, .case-grid {
        grid-template-columns: 1fr;
        gap: 10px;
    }
    .related-grid, .case-grid {
        grid-template-columns: 1fr;
    }
    .product-section {
        padding: 10px 10px !important;
    }
}

@media(max-width: 600px) {
    .related-card img {
        height: 140px;
    }
    .case-item img {
        height: 160px;
    }
}

/* =====================================================
FEATURED PRODUCT SECTION
===================================================== */
.featured-products {
    padding:60px 0;
    background:#fff;
}
     
.featured-products .container {
    max-width:1200px;
    margin:auto;
    padding:0 24px;
}
     
.featured-products h2 { 
    font-size:36px;
    font-weight:600;
    text-transform:uppercase;
    margin-bottom:10px; 
}
      
.section-description { 
    font-size:18px;
    color:#555;
    max-width:900px;
    margin-bottom:50px;
}
     
/* PRODUCT GRID */
.featured-product-grid {
    display:grid;
    grid-template-columns:repeat(4,1fr);
    gap:30px;
}
    
    /* CARD */
.featured-product-card {
    background:#fff;
    border:1px solid #eee;
    border-radius:12px;
    overflow:hidden;
    transition:all .35s ease;
}
    
.featured-product-card:hover {
    transform:translateY(-8px);
    box-shadow:0 15px 35px rgba(0,0,0,.12);
}
    
    /* IMAGE */
.featured-product-card img { 
    width:100%;
    height:260px;
    object-fit:contain;
    padding:25px;
    background:#fff;
}

    /* INFO */
.product-info { 
    padding:20px;
}
    
.product-category {
    font-size:14px;
    color:#f5a400;
    font-weight:600;
    text-transform:uppercase;
}
    
.product-info h3 {
    font-size:22px;
    margin:12px 0;
}
    
.product-info p {
    font-size:15px;
    color:#666;
    line-height:1.6;
}
    
@media(max-width:1024px){
.featured-product-grid{
    grid-template-columns:repeat(2,1fr);}
}

@media(max-width:768px){
.featured-product-grid{
    grid-template-columns:1fr;}
}

/* 修复 Related Lighting Solutions 网格卡片对齐 */
.solution-link-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
    gap: 20px;
    margin-top: 20px;
}

.solution-link-grid a {
    background: #fff;
    border: 1px solid #e5e7eb;
    border-radius: 6px;
    padding: 20px;
    text-align: left; /* 保持卡片内文字左对齐更显专业 */
    text-decoration: none;
    color: #1f2937;
    font-weight: 600;
    box-shadow: 0 1px 3px rgba(0,0,0,0.05);
    transition: all 0.2s;
    display: block;
}

.solution-link-grid a:hover {
    border-color: #2563eb;
    color: #2563eb;
    transform: translateY(-2px);
}

/* 确保 Why Choose 和 FAQ 区域文字左对齐，去除居中导致的乱版 */
.container-left-align {
    max-width: 900px; 
    margin: 0 auto; 
    text-align: left;
}
