/* =============================================
   屋百年大程序 - 方案 B 深度整合样式
   版本：V2.0
   创建时间：2025-03-16
   ============================================= */

/* =============================================
   1. 全屏轮播图样式（ihouse100）
   ============================================= */
.hero-banner {
    position: relative;
    height: 100vh;
    min-height: 600px;
    width: 100%;
    overflow: hidden;
}

.hero-banner .swiper-container {
    width: 100%;
    height: 100%;
}

.hero-banner .swiper-slide {
    position: relative;
    background: #000;
}

.hero-banner .swiper-slide img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    opacity: 0.9;
}

.hero-banner .slide-caption {
    position: absolute;
    bottom: 15%;
    left: 50%;
    transform: translateX(-50%);
    text-align: center;
    color: white;
    text-shadow: 0 2px 15px rgba(0,0,0,0.6);
    z-index: 10;
    max-width: 800px;
    padding: 0 20px;
}

.hero-banner .slide-caption h2 {
    font-size: 48px;
    font-weight: 700;
    margin-bottom: 15px;
    letter-spacing: 2px;
}

.hero-banner .slide-caption p {
    font-size: 20px;
    font-weight: 300;
    opacity: 0.95;
}

.hero-banner .swiper-pagination-bullet {
    background: white;
    opacity: 0.6;
}

.hero-banner .swiper-pagination-bullet-active {
    opacity: 1;
}

.hero-banner .swiper-button-next,
.hero-banner .swiper-button-prev {
    color: white;
    opacity: 0.7;
    transition: opacity 0.3s;
}

.hero-banner .swiper-button-next:hover,
.hero-banner .swiper-button-prev:hover {
    opacity: 1;
}

/* 移动端轮播图优化 */
@media (max-width: 768px) {
    .hero-banner {
        height: 70vh;
        min-height: 500px;
    }
    
    .hero-banner .slide-caption h2 {
        font-size: 28px;
    }
    
    .hero-banner .slide-caption p {
        font-size: 16px;
    }
}

/* =============================================
   2. 产品分类筛选样式
   ============================================= */
.product-filter {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 12px;
    margin-bottom: 50px;
    padding: 0 20px;
}

.product-filter .filter-btn {
    padding: 12px 24px;
    border: 1px solid rgba(0,0,0,0.1);
    background: white;
    border-radius: 25px;
    font-size: 14px;
    font-weight: 500;
    color: var(--wbn-black);
    cursor: pointer;
    transition: all 0.3s ease;
}

.product-filter .filter-btn:hover {
    background: var(--wbn-gray);
    transform: translateY(-2px);
}

.product-filter .filter-btn.active {
    background: var(--wbn-blue);
    color: white;
    border-color: var(--wbn-blue);
    box-shadow: 0 4px 15px rgba(0,113,227,0.3);
}

/* 产品卡片筛选动画 */
.product-card.filtered {
    display: none;
}

.product-card.visible {
    display: block;
    animation: fadeIn 0.5s ease;
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* =============================================
   3. 公司介绍 + 电视机模块（核心特色）
   ============================================= */
.about-tv-section {
    padding: 100px 0;
    background: var(--wbn-gray);
}

.about-tv-wrapper {
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 30px;
}

.about-tv-content {
    display: flex;
    gap: 80px;
    align-items: flex-start;
}

/* 左侧：公司介绍文字 */
.about-left {
    flex: 0 0 520px;
    padding-top: 10px;
}

.about-title {
    font-size: 28px;
    font-weight: 700;
    color: var(--wbn-black);
    margin-bottom: 12px;
    line-height: 1.3;
}

.about-subtitle {
    font-size: 17px;
    font-weight: 500;
    color: var(--wbn-dark-gray);
    margin-bottom: 20px;
}

.about-divider {
    display: block;
    width: 60px;
    height: 3px;
    background: var(--wbn-blue);
    margin-bottom: 25px;
    border-radius: 2px;
}

.about-text {
    font-size: 15px;
    line-height: 28px;
    color: var(--wbn-black);
    text-align: justify;
    max-width: 520px;
}

.about-text br {
    margin-bottom: 15px;
}

/* 右侧：电视机视频 */
.about-right {
    flex: 1;
    position: relative;
}

.video-frame {
    position: relative;
    width: 100%;
    max-width: 720px;
    aspect-ratio: 16/10;
    border-radius: 12px;
    overflow: hidden;
    /* 3D 边框效果 */
    box-shadow: 
        0 25px 50px rgba(0,0,0,0.15),
        0 0 0 1px rgba(0,0,0,0.05),
        inset 0 0 0 1px rgba(255,255,255,0.1);
    /* 轻微透视效果 */
    transform: perspective(1000px) rotateY(-2deg);
    transition: transform 0.4s ease, box-shadow 0.4s ease;
    background: #1a1a1a;
}

.video-frame:hover {
    transform: perspective(1000px) rotateY(0deg);
    box-shadow: 
        0 30px 60px rgba(0,0,0,0.2),
        0 0 0 1px rgba(0,0,0,0.08),
        inset 0 0 0 1px rgba(255,255,255,0.15);
}

.video-frame video {
    width: 100%;
    height: 100%;
    object-fit: cover;
    background-color: transparent;
    background-size: cover;
    background-position: center;
}

/* 视频播放覆盖层 */
.video-play-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    background: transparent;
    cursor: pointer;
    transition: all 0.3s ease;
    z-index: 10;
}

.video-play-overlay:hover {
    background: transparent;
}

.video-play-overlay:hover .play-button-circle {
    transform: scale(1.1);
}

.video-play-overlay.hidden {
    opacity: 0;
    pointer-events: none;
}

/* 播放按钮圆形 */
.play-button-circle {
    width: 70px;
    height: 70px;
    background: rgba(255,255,255,0.9);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 4px 20px rgba(0,0,0,0.2);
    transition: all 0.3s ease;
}

.play-button-circle svg {
    width: 28px;
    height: 28px;
    color: #1d1d1f;
    margin-left: 4px; /* 视觉居中调整 */
}

/* 播放按钮 - 精确居中（旧样式，保留兼容） */
.play-btn {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    cursor: pointer;
    transition: all 0.3s ease;
    z-index: 10;
    opacity: 1;
}

.play-btn:hover {
    transform: translate(-50%, -50%) scale(1.15);
}

.play-btn img {
    width: 90px;
    height: 90px;
    filter: drop-shadow(0 6px 20px rgba(0,0,0,0.5));
}

/* 播放按钮隐藏状态 */
.play-btn.hidden {
    opacity: 0;
    pointer-events: none;
}

/* 查看详情按钮 */
.view-more-btn {
    display: inline-block;
    margin-top: 25px;
    padding: 14px 32px;
    background: var(--wbn-blue);
    color: white;
    border-radius: 10px;
    text-decoration: none;
    font-size: 15px;
    font-weight: 600;
    transition: all 0.3s ease;
}

.view-more-btn:hover {
    background: #005bb5;
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(0,113,227,0.35);
}

/* 响应式 - 公司介绍 + 电视机 */
@media (max-width: 1200px) {
    .about-tv-content {
        gap: 50px;
    }
    
    .about-left {
        flex: 0 0 450px;
    }
    
    .video-frame {
        max-width: 600px;
    }
}

@media (max-width: 992px) {
    .about-tv-content {
        flex-direction: column;
        align-items: center;
    }
    
    .about-left {
        flex: none;
        width: 100%;
        max-width: 600px;
        text-align: center;
    }
    
    .about-text {
        margin: 0 auto;
    }
    
    .about-divider {
        margin: 0 auto 25px;
    }
    
    .about-right {
        width: 100%;
        display: flex;
        flex-direction: column;
        align-items: center;
    }
    
    .video-frame {
        max-width: 100%;
        transform: none;
    }
    
    .video-frame:hover {
        transform: none;
    }
}

/* =============================================
   4. 新闻中心样式（ihouse100）
   ============================================= */
.news-section {
    padding: 100px 0;
    background: var(--wbn-white);
}

.news-section .section-header {
    text-align: center;
    margin-bottom: 60px;
}

.news-section .section-header h2 {
    font-size: 36px;
    font-weight: 700;
    color: var(--wbn-black);
    margin-bottom: 15px;
}

.news-section .section-header p {
    font-size: 17px;
    color: var(--wbn-dark-gray);
}

.news-swiper {
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 30px;
    position: relative;
}

.news-swiper .swiper-container {
    width: 100%;
    padding-bottom: 50px !important;
}

.news-card {
    background: var(--wbn-gray);
    border-radius: 18px;
    overflow: hidden;
    transition: all 0.4s ease;
    height: 100%;
    display: flex;
    flex-direction: column;
}

.news-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 20px 50px rgba(0,0,0,0.12);
}

.news-card a {
    text-decoration: none;
    color: inherit;
    display: flex;
    flex-direction: column;
    height: 100%;
}

.news-image {
    width: 100%;
    height: 220px;
    overflow: hidden;
    background: #e0e0e0;
}

.news-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.4s ease;
}

.news-card:hover .news-image img {
    transform: scale(1.08);
}

.news-content {
    padding: 25px;
    flex: 1;
    display: flex;
    flex-direction: column;
}

.news-content h3 {
    font-size: 17px;
    font-weight: 600;
    color: var(--wbn-black);
    margin-bottom: 12px;
    line-height: 1.5;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.news-content p {
    font-size: 14px;
    color: var(--wbn-dark-gray);
    line-height: 1.8;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
    margin-top: auto;
}

/* 新闻中心导航按钮 */
.news-swiper .swiper-button-next,
.news-swiper .swiper-button-prev {
    width: 50px;
    height: 50px;
    background: white;
    border-radius: 50%;
    box-shadow: 0 4px 15px rgba(0,0,0,0.1);
    transition: all 0.3s ease;
}

.news-swiper .swiper-button-next:hover,
.news-swiper .swiper-button-prev:hover {
    background: var(--wbn-blue);
    box-shadow: 0 6px 20px rgba(0,113,227,0.3);
}

.news-swiper .swiper-button-next::after,
.news-swiper .swiper-button-prev::after {
    font-size: 18px;
    font-weight: 700;
    color: var(--wbn-black);
}

.news-swiper .swiper-button-next:hover::after,
.news-swiper .swiper-button-prev:hover::after {
    color: white;
}

/* 响应式 - 新闻中心 */
@media (max-width: 1200px) {
    .news-swiper .swiper-container {
        padding: 0 40px 50px !important;
    }
}

@media (max-width: 768px) {
    .news-section {
        padding: 60px 0;
    }
    
    .news-section .section-header h2 {
        font-size: 28px;
    }
    
    .news-swiper {
        padding: 0 20px;
    }
    
    .news-image {
        height: 180px;
    }
    
    .news-content h3 {
        font-size: 16px;
    }
}

/* =============================================
   5. 轮播图 Caption 样式（备用）
   ============================================= */
.banner-caption {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    text-align: center;
    color: white;
    text-shadow: 0 2px 15px rgba(0,0,0,0.6);
    z-index: 10;
    max-width: 900px;
    padding: 0 30px;
}

.banner-caption h1 {
    font-size: 56px;
    font-weight: 700;
    margin-bottom: 20px;
    letter-spacing: 3px;
}

.banner-caption p {
    font-size: 22px;
    font-weight: 300;
    opacity: 0.95;
}

@media (max-width: 768px) {
    .banner-caption h1 {
        font-size: 32px;
    }
    
    .banner-caption p {
        font-size: 16px;
    }
}

/* =============================================
   6. 通用增强样式
   ============================================= */

/* 清除浮动 */
.clear::after {
    content: '';
    display: table;
    clear: both;
}

/* 板块间距优化 */
section + section {
    margin-top: 0;
}

/* 容器最大宽度统一 */
.container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 30px;
}

/* 标题统一样式 */
.section-header h2 {
    font-size: 36px;
    font-weight: 700;
    color: var(--wbn-black);
    text-align: center;
    margin-bottom: 15px;
}

.section-header p {
    font-size: 17px;
    color: var(--wbn-dark-gray);
    text-align: center;
}

/* 动画效果 */
.wow {
    visibility: hidden;
}

.animated {
    visibility: visible;
}

/* 加载动画 */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.fadeInUp {
    animation: fadeInUp 0.6s ease forwards;
}

/* =============================================
   7. 视频控件样式覆盖
   ============================================= */
.video-frame video::-webkit-media-controls {
    background: transparent;
}

.video-frame video::-webkit-media-controls-play-button {
    background: rgba(255,255,255,0.9);
    border-radius: 50%;
}

/* =============================================
   8. 移动端导航优化
   ============================================= */
@media (max-width: 768px) {
    /* 轮播图自动播放暂停 on touch */
    .hero-banner.swiper-container {
        touch-action: pan-y;
    }
    
    /* 产品筛选横向滚动 */
    .product-filter {
        overflow-x: auto;
        flex-wrap: nowrap;
        padding-bottom: 10px;
    }
    
    .product-filter .filter-btn {
        flex: 0 0 auto;
    }
}

/* =============================================
   9. 性能优化
   ============================================= */

/* 图片懒加载占位 */
img[loading="lazy"] {
    background: linear-gradient(90deg, #f0f0f0 25%, #e0e0e0 50%, #f0f0f0 75%);
    background-size: 200% 100%;
    animation: loading 1.5s infinite;
}

@keyframes loading {
    0% { background-position: 200% 0; }
    100% { background-position: -200% 0; }
}

/* 减少重绘 */
.video-frame,
.news-card,
.product-card {
    will-change: transform;
}

/* =============================================
   End of Scheme B Styles
   ============================================= */
