/* ============================================================
   VIEW-PRODUCT.CSS - 产品详情页
   大图画廊 + 核心参数 + 规格表 + 特性交替展示
   ============================================================ */

:root {
    --primary: #e63946;
    --primary-dark: #c1121f;
    --secondary: #1d3557;
    --accent: #f4a261;
    --white: #ffffff;
    --light: #f8f9fa;
    --light-blue: #e0f2fe;
    --border: #e5e7eb;
    --text: #1a1a2e;
    --text-muted: #6c757d;
    --radius: 8px;
    --radius-lg: 12px;
    --shadow: 0 2px 8px rgba(0,0,0,0.08);
    --shadow-hover: 0 8px 24px rgba(0,0,0,0.12);
    --transition: 0.3s ease;
}

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }
body { font-family: 'Segoe UI', sans-serif; line-height: 1.6; color: var(--text); background: var(--white); }
img { max-width: 100%; height: auto; display: block; }
a { text-decoration: none; color: inherit; }
ul { list-style: none; }
.container { width: 100%; max-width: 1200px; margin: 0 auto; padding: 0 16px; }

/* ==================== HEADER ==================== */
.header { position: fixed; top: 0; left: 0; right: 0; z-index: 100; background: var(--white); box-shadow: var(--shadow); }
.header-container { display: flex; align-items: center; justify-content: space-between; padding: 10px 16px; max-width: 1200px; margin: 0 auto; }
.logo img { height: 36px; }
.nav-toggle { display: flex; flex-direction: column; justify-content: center; align-items: center; width: 44px; height: 44px; background: var(--primary); border: none; border-radius: var(--radius); cursor: pointer; z-index: 101; }
.hamburger { width: 20px; height: 2px; background: var(--white); position: relative; }
.hamburger::before, .hamburger::after { content: ''; position: absolute; width: 20px; height: 2px; background: var(--white); }
.hamburger::before { top: -6px; }
.hamburger::after { top: 6px; }
.nav-toggle.active .hamburger { background: transparent; }
.nav-toggle.active .hamburger::before { transform: rotate(45deg); top: 0; }
.nav-toggle.active .hamburger::after { transform: rotate(-45deg); top: 0; }
.nav-menu { position: fixed; top: 0; right: -280px; width: 280px; height: 100vh; background: var(--white); box-shadow: var(--shadow-hover); padding: 70px 16px 24px; transition: right var(--transition); }
.nav-menu.active { right: 0; }
.nav-list { display: flex; flex-direction: column; gap: 4px; }
.nav-link { display: block; padding: 12px 16px; font-size: 15px; font-weight: 500; border-radius: var(--radius); }
.nav-link:hover, .nav-link.active { background: var(--light-blue); color: var(--primary); }
.nav-link.nav-cta { background: var(--primary); color: var(--white); text-align: center; margin-top: 8px; }

/* ==================== BREADCRUMB ==================== */
.breadcrumb-bar { padding: 70px 0 12px; background: var(--light); }
.breadcrumb { display: flex; align-items: center; gap: 8px; font-size: 13px; color: var(--text-muted); }
.breadcrumb a:hover { color: var(--primary); }
.breadcrumb span { color: var(--border); }
.breadcrumb .current { color: var(--text); }

/* ==================== PRODUCT HERO ==================== */
.product-hero { padding: 24px 0 40px; background: var(--light); }
.hero-grid { display: grid; gap: 32px; }

/* 图片画廊 */
.hero-gallery { position: relative; }
.main-image { position: relative; border-radius: var(--radius-lg); overflow: hidden; background: var(--white); }
.main-image img { width: 100%; aspect-ratio: 4/3; object-fit: cover; }
.image-badge { position: absolute; top: 12px; right: 12px; padding: 6px 14px; font-size: 11px; font-weight: 600; text-transform: uppercase; color: var(--white); background: var(--primary); border-radius: 20px; }
.thumb-list { display: flex; gap: 8px; margin-top: 12px; overflow-x: auto; padding-bottom: 4px; }
.thumb-item { flex-shrink: 0; width: 64px; height: 64px; padding: 0; border: 2px solid transparent; border-radius: var(--radius); overflow: hidden; cursor: pointer; background: none; }
.thumb-item img { width: 100%; height: 100%; object-fit: cover; }
.thumb-item.active { border-color: var(--primary); }

/* 产品信息 */
.hero-info {}
.product-series { display: inline-block; padding: 4px 12px; font-size: 12px; font-weight: 600; color: var(--primary); background: rgba(230,57,70,0.1); border-radius: 20px; margin-bottom: 12px; }
.product-title { font-size: 24px; font-weight: 700; color: var(--secondary); line-height: 1.3; margin-bottom: 8px; }
.product-subtitle { font-size: 14px; color: var(--text-muted); margin-bottom: 24px; }

/* 核心参数 */
.key-specs { display: grid; grid-template-columns: repeat(2, 1fr); gap: 12px; margin-bottom: 24px; }
.spec-item { background: var(--white); border-radius: var(--radius); padding: 16px; text-align: center; box-shadow: var(--shadow); }
.spec-value { font-size: 28px; font-weight: 700; color: var(--primary); line-height: 1; }
.spec-unit { font-size: 14px; font-weight: 600; color: var(--primary); margin-left: 2px; }
.spec-label { display: block; font-size: 11px; color: var(--text-muted); margin-top: 4px; text-transform: uppercase; }

/* 产品亮点 */
.product-highlights { margin-bottom: 24px; }
.highlight-item { display: flex; align-items: flex-start; gap: 10px; padding: 8px 0; }
.highlight-item i { color: #22c55e; font-size: 14px; margin-top: 3px; }
.highlight-item span { font-size: 14px; color: var(--text); }

/* 操作按钮 */
.hero-actions { display: flex; flex-direction: column; gap: 12px; }
.btn-primary, .btn-secondary { display: flex; align-items: center; justify-content: center; gap: 8px; padding: 14px 24px; font-size: 15px; font-weight: 600; border-radius: var(--radius); transition: var(--transition); }
.btn-primary { background: var(--primary); color: var(--white); }
.btn-primary:hover { background: var(--primary-dark); }
.btn-secondary { background: var(--white); color: var(--secondary); border: 2px solid var(--secondary); }
.btn-secondary:hover { background: var(--secondary); color: var(--white); }

/* ==================== PRODUCT DESCRIPTION ==================== */
.product-description { padding: 40px 0; background: var(--white); }
.desc-content { max-width: 900px; }
.desc-content h2 { font-size: 22px; color: var(--secondary); margin-bottom: 16px; }
.desc-content p { font-size: 15px; color: var(--text-muted); line-height: 1.8; margin-bottom: 16px; }

/* ==================== SPECS TABLE ==================== */
.specs-section { padding: 40px 0; background: var(--light); }
.section-title { font-size: 22px; color: var(--secondary); margin-bottom: 24px; text-align: center; }
.specs-table-wrapper { overflow-x: auto; }
.specs-table { width: 100%; border-collapse: collapse; background: var(--white); border-radius: var(--radius-lg); overflow: hidden; box-shadow: var(--shadow); }
.specs-table th, .specs-table td { padding: 14px 16px; text-align: left; font-size: 14px; border-bottom: 1px solid var(--border); }
.specs-table th { width: 40%; color: var(--secondary); font-weight: 600; background: var(--light-blue); }
.specs-table td { color: var(--text); }
.specs-table tr:last-child th, .specs-table tr:last-child td { border-bottom: none; }

/* ==================== FEATURES SECTION ==================== */
.features-section { padding: 48px 0; background: var(--white); }
.feature-block { display: grid; gap: 24px; margin-bottom: 40px; }
.feature-block:last-child { margin-bottom: 0; }
.feature-image { border-radius: var(--radius-lg); overflow: hidden; }
.feature-image img { width: 100%; aspect-ratio: 16/10; object-fit: cover; }
.feature-content {}
.feature-tag { display: inline-block; padding: 4px 12px; font-size: 11px; font-weight: 600; text-transform: uppercase; color: var(--white); background: var(--accent); border-radius: 20px; margin-bottom: 12px; }
.feature-content h3 { font-size: 20px; color: var(--secondary); margin-bottom: 12px; }
.feature-content > p { font-size: 14px; color: var(--text-muted); line-height: 1.7; margin-bottom: 16px; }
.feature-list { display: flex; flex-direction: column; gap: 8px; }
.feature-list li { display: flex; align-items: center; gap: 10px; font-size: 14px; color: var(--text); }
.feature-list i { color: var(--primary); font-size: 12px; }

/* ==================== APPLICATIONS ==================== */
.applications-section { padding: 48px 0; background: linear-gradient(135deg, var(--light-blue) 0%, #bae6fd 100%); }
.app-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 16px; }
.app-card { background: var(--white); border-radius: var(--radius-lg); padding: 20px; text-align: center; box-shadow: var(--shadow); transition: var(--transition); }
.app-card:hover { transform: translateY(-4px); box-shadow: var(--shadow-hover); }
.app-icon { width: 48px; height: 48px; margin: 0 auto 12px; background: var(--light-blue); border-radius: 50%; display: flex; justify-content: center; align-items: center; font-size: 20px; color: var(--primary); }
.app-card h4 { font-size: 14px; color: var(--secondary); margin-bottom: 4px; }
.app-card p { font-size: 12px; color: var(--text-muted); }

/* ==================== RELATED PRODUCTS ==================== */
.related-section { padding: 48px 0; background: var(--white); }
.related-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; }
.related-card { background: var(--light); border-radius: var(--radius-lg); overflow: hidden; transition: var(--transition); }
.related-card:hover { box-shadow: var(--shadow-hover); }
.related-image { aspect-ratio: 4/3; overflow: hidden; }
.related-image img { width: 100%; height: 100%; object-fit: cover; transition: transform 0.5s; }
.related-card:hover .related-image img { transform: scale(1.05); }
.related-info { padding: 12px; text-align: center; }
.related-info h4 { font-size: 16px; color: var(--secondary); margin-bottom: 2px; }
.related-info p { font-size: 12px; color: var(--text-muted); }

/* ==================== CTA SECTION ==================== */
.cta-section { padding: 48px 0; background: var(--light); }
.cta-box { display: flex; flex-direction: column; align-items: center; text-align: center; gap: 24px; padding: 32px 20px; background: var(--secondary); border-radius: var(--radius-lg); }
.cta-content h2 { font-size: 22px; color: var(--white); margin-bottom: 8px; }
.cta-content p { font-size: 14px; color: rgba(255,255,255,0.8); }
.cta-actions { display: flex; flex-direction: column; gap: 12px; }
.btn-cta, .btn-whatsapp { display: flex; align-items: center; justify-content: center; gap: 8px; padding: 14px 28px; font-size: 15px; font-weight: 600; border-radius: var(--radius); transition: var(--transition); }
.btn-cta { background: var(--primary); color: var(--white); }
.btn-cta:hover { background: var(--primary-dark); }
.btn-whatsapp { background: #25D366; color: var(--white); }
.btn-whatsapp:hover { background: #1da851; }

/* ==================== FOOTER ==================== */
.footer { background: linear-gradient(135deg, #e3f2fd 0%, #bbdefb 50%, #90caf9 100%); color: var(--white); padding: 48px 0 24px; }
.footer-grid { display: grid; gap: 32px; margin-bottom: 32px; }
.footer-col h4 { font-size: 15px; margin-bottom: 16px; color: var(--accent); }
.footer-col li { margin-bottom: 10px; }
.footer-col a { color: rgba(255,255,255,0.75); font-size: 14px; }
.footer-col a:hover { color: var(--white); }
.contact-list li { display: flex; align-items: center; gap: 8px; color: rgba(255,255,255,0.75); font-size: 13px; }
.contact-list i { color: var(--accent); width: 16px; }
.footer-bottom { text-align: center; padding-top: 24px; border-top: 1px solid rgba(255,255,255,0.1); }
.footer-bottom p { font-size: 13px; color: rgba(255,255,255,0.5); }

.back-to-top { position: fixed; bottom: 20px; right: 20px; width: 44px; height: 44px; background: var(--primary); color: var(--white); border: none; border-radius: 50%; cursor: pointer; opacity: 0; visibility: hidden; transition: var(--transition); z-index: 99; }
.back-to-top.visible { opacity: 1; visibility: visible; }

/* ==================== TABLET (768px) ==================== */
@media (min-width: 768px) {
    .header-container { padding: 8px 24px; }
    .logo img { height: 32px; }
    .nav-toggle { display: none; }
    .nav-menu { position: static; width: auto; height: auto; background: none; box-shadow: none; padding: 0; }
    .nav-list { flex-direction: row; gap: 0; }
    .nav-link { padding: 6px 8px; font-size: 13px; }
    .nav-link:hover, .nav-link.active { background: none; }
    .nav-link.nav-cta { padding: 6px 12px; margin-top: 0; margin-left: 4px; background: var(--primary); color: var(--white); }
    .nav-link.nav-cta:hover, .nav-link.nav-cta.active { background: var(--primary-dark); color: var(--white); }
    
    .breadcrumb-bar { padding: 80px 0 16px; }
    .hero-grid { grid-template-columns: 1fr 1fr; gap: 40px; align-items: start; }
    .product-title { font-size: 28px; }
    .key-specs { grid-template-columns: repeat(4, 1fr); }
    .hero-actions { flex-direction: row; }
    
    .feature-block { grid-template-columns: 1fr 1fr; gap: 40px; align-items: center; }
    .feature-block.reverse .feature-image { order: 2; }
    .feature-block.reverse .feature-content { order: 1; }
    
    .app-grid { grid-template-columns: repeat(3, 1fr); }
    
    .cta-box { flex-direction: row; justify-content: space-between; text-align: left; padding: 40px; }
    .cta-actions { flex-direction: row; }
    
    .footer-grid { grid-template-columns: repeat(3, 1fr); }
}

/* ==================== DESKTOP (1024px) ==================== */
@media (min-width: 1024px) {
    .header-container { padding: 10px 32px; gap: 32px; justify-content: flex-start; }
    .logo img { height: 42px; }
    .nav-link { padding: 8px 14px; font-size: 15px; }
    .nav-link.nav-cta { padding: 8px 20px; font-size: 15px; }
    
    .breadcrumb-bar { padding: 90px 0 20px; }
    .hero-grid { gap: 60px; }
    .main-image img { aspect-ratio: 1/1; }
    .thumb-item { width: 80px; height: 80px; }
    .product-title { font-size: 32px; }
    .spec-value { font-size: 32px; }
    
    .section-title { font-size: 28px; }
    .desc-content h2 { font-size: 26px; }
    .desc-content p { font-size: 16px; }
    
    .feature-block { gap: 60px; }
    .feature-content h3 { font-size: 24px; }
    
    .app-grid { grid-template-columns: repeat(6, 1fr); gap: 20px; }
    .app-card { padding: 24px 16px; }
    
    .cta-content h2 { font-size: 28px; }
}
