/**
 * 产品服务页样式 - 烽云科技
 * Author: Bruce (ID: 19314067)
 * 创建时间: 2026-02-26
 * 描述: 产品服务展示页面专属样式
 */

/* ==================== 页面 Banner 区域 ==================== */
section.page-banner,
.page-banner {
    position: relative;
    width: 100%;
    height: 500px;
    overflow: hidden;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-top: 70px !important; /* 导航栏高度补偿，使用!important确保优先级 */
}

/* Banner背景图片 */
.banner-bg-image {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center;
    z-index: 0;
}

/* Banner遮罩层 - 确保文字可读性 */
.banner-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: 
        linear-gradient(135deg, rgba(15, 23, 42, 0.85) 0%, rgba(30, 58, 95, 0.8) 50%, rgba(14, 165, 233, 0.75) 100%),
        radial-gradient(circle at 20% 80%, rgba(14, 165, 233, 0.2) 0%, transparent 50%),
        radial-gradient(circle at 80% 20%, rgba(37, 99, 235, 0.2) 0%, transparent 50%);
    z-index: 1;
    pointer-events: none;
}

.banner-content {
    position: relative;
    z-index: 2;
    text-align: center;
    padding: 0 24px;
    max-width: 800px;
}

.banner-title {
    font-size: 48px;
    font-weight: 700;
    color: #ffffff;
    margin-bottom: 16px;
    text-shadow: 0 2px 20px rgba(0, 0, 0, 0.3);
    animation: fadeInUp 0.8s ease-out;
}

.banner-subtitle {
    font-size: 20px;
    color: rgba(255, 255, 255, 0.9);
    line-height: 1.6;
    animation: fadeInUp 0.8s ease-out 0.2s both;
}

@keyframes fadeInUp {
    from { opacity: 0; transform: translateY(30px); }
    to { opacity: 1; transform: translateY(0); }
}

/* ==================== 二级栏目选项卡 ==================== */
.category-tabs-section {
    background: #ffffff;
    border-bottom: 1px solid #e2e8f0;
    position: sticky;
    top: 70px;
    z-index: 100;
}

.category-tabs-container {
    max-width: 1280px;
    margin: 0 auto;
    padding: 0 24px;
}

.category-tabs {
    display: flex;
    justify-content: center;
    gap: 8px;
    overflow-x: auto;
    scrollbar-width: none;
    -ms-overflow-style: none;
}

.category-tabs::-webkit-scrollbar { display: none; }

.category-tab {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 20px 30px;
    font-size: 16px;
    font-weight: 500;
    color: #64748b;
    background: transparent;
    border: none;
    border-bottom: 3px solid transparent;
    cursor: pointer;
    transition: all 0.3s ease;
    white-space: nowrap;
}

.category-tab:hover {
    color: #1a72b3;
    background: rgba(37, 99, 235, 0.05);
}

.category-tab.active {
    color: #1a72b3;
    border-bottom-color: #1a72b3;
}

.category-tab svg {
    width: 20px;
    height: 20px;
}

/* ==================== 三级栏目内容区域 ==================== */
.products-content-section {
    padding: 60px 0;
    background: #f8fafc;
    min-height: 600px;
}

.category-panel {
    display: none;
    margin-top: 50px;
}

.category-panel.active {
    display: block;
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(20px); }
    to { opacity: 1; transform: translateY(0); }
}

/* 三级栏目卡片 */
.product-detail-card {
    max-width: 1280px;
    margin: 0 auto 48px;
    padding: 0 24px;
    position: relative;
    scroll-margin-top: 120px; /* 为锚点滚动预留导航栏高度 */
}

.product-detail-inner {
    background: #ffffff;
    border-radius: 20px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
    overflow: hidden;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.product-detail-inner:hover {
    transform: translateY(-4px);
    box-shadow: 0 12px 40px rgba(0, 0, 0, 0.12);
}

/* 栏目头部区域 */
.product-header {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 0;
    min-height: 400px;
}

.product-header.reversed {
    direction: rtl;
}

.product-header.reversed > * {
    direction: ltr;
}

/* 栏目图片 */
.product-image-wrapper {
    position: relative;
    overflow: hidden;
    background: linear-gradient(135deg, #f0f9ff 0%, #e0f2fe 100%);
}

.product-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s ease;
}

.product-detail-inner:hover .product-image {
    transform: scale(1.05);
}

/* 栏目信息 */
.product-info {
    padding: 48px;
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.product-tag {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 6px 14px;
    background: linear-gradient(135deg, #2563eb 0%, #0ea5e9 100%);
    color: #ffffff;
    font-size: 12px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 1px;
    border-radius: 100px;
    margin-bottom: 20px;
    width: fit-content;
}

.product-title {
    font-size: 32px;
    font-weight: 700;
    color: #1e293b;
    margin-bottom: 16px;
    line-height: 1.3;
}

.product-description {
    font-size: 16px;
    color: #64748b;
    line-height: 1.8;
    margin-bottom: 28px;
}

/* 特性列表 */
.product-features {
    list-style: none;
    padding: 0;
    margin: 0 0 28px 0;
}

.product-features li {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    margin-bottom: 12px;
    font-size: 15px;
    color: #475569;
}

.feature-icon {
    width: 20px;
    height: 20px;
    color: #10b981;
    flex-shrink: 0;
    margin-top: 2px;
}

/* 操作按钮 */
.product-actions {
    display: flex;
    gap: 16px;
    flex-wrap: wrap;
}

.btn-primary {
    display: inline-flex;
    align-items: center;
    padding: 12px 28px;
    background: linear-gradient(135deg, #2563eb 0%, #1d4ed8 100%);
    color: #ffffff;
    font-size: 15px;
    font-weight: 600;
    text-decoration: none;
    border-radius: 100px;
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(37, 99, 235, 0.3);
    cursor: pointer;
    border: none;
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(37, 99, 235, 0.4);
}

.btn-secondary {
    display: inline-flex;
    align-items: center;
    padding: 12px 28px;
    background: transparent;
    color: #2563eb;
    font-size: 15px;
    font-weight: 600;
    text-decoration: none;
    border-radius: 100px;
    border: 2px solid #2563eb;
    transition: all 0.3s ease;
    cursor: pointer;
}

.btn-secondary:hover {
    background: rgba(37, 99, 235, 0.1);
}

/* ==================== 应用场景区域 ==================== */
.scenarios-section {
    padding: 40px 48px 48px;
    background: #f8fafc;
    border-top: 1px solid #e2e8f0;
}

.scenarios-title {
    font-size: 20px;
    font-weight: 600;
    color: #1e293b;
    margin-bottom: 24px;
    display: flex;
    align-items: center;
    gap: 8px;
}

.scenarios-title svg {
    width: 24px;
    height: 24px;
    color: #2563eb;
}

.scenarios-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 24px;
}

.scenario-card {
    background: #ffffff;
    border-radius: 16px;
    overflow: hidden;
    box-shadow: 0 2px 12px rgba(0, 0, 0, 0.06);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    cursor: pointer;
}

.scenario-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.1);
}

.scenario-image {
    width: 100%;
    height: 160px;
    object-fit: cover;
}

.scenario-content {
    padding: 20px;
}

.scenario-name {
    font-size: 16px;
    font-weight: 600;
    color: #1e293b;
    margin-bottom: 8px;
}

.scenario-desc {
    font-size: 14px;
    color: #64748b;
    line-height: 1.6;
}

/* ==================== 响应式设计 ==================== */

/* 平板端 (768px - 1199px) */
@media (max-width: 1199px) {
    .page-banner {
        height: 420px;
    }
    
    .banner-title {
        font-size: 36px;
    }
}

/* 移动端 (< 768px) */
@media (max-width: 767px) {
    section.page-banner,
    .page-banner {
        height: 380px;
        margin-top: 60px !important; /* 移动端导航栏高度补偿 */
    }
    
    .banner-title {
        font-size: 32px;
    }
    
    .banner-subtitle {
        font-size: 16px;
    }
}

@media (max-width: 1024px) {
    .product-header {
        grid-template-columns: 1fr;
    }
    
    .product-image-wrapper {
        height: 280px;
    }
    
    .scenarios-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 768px) {
    .banner-title {
        font-size: 32px;
    }
    
    .banner-subtitle {
        font-size: 16px;
    }
    
    .category-tabs-section {
        top: 60px;
    }
    
    .category-tab {
        padding: 12px 16px;
        font-size: 14px;
    }
    
    .product-info {
        padding: 32px 24px;
    }
    
    .product-title {
        font-size: 24px;
    }
    
    .scenarios-section {
        padding: 32px 24px;
    }
    
    .scenarios-grid {
        grid-template-columns: 1fr;
    }
    
    .product-actions {
        flex-direction: column;
    }
    
    .btn-primary,
    .btn-secondary {
        width: 100%;
        justify-content: center;
    }
}

/* ==================== 卡片定位高亮效果 ==================== */

/**
 * 产品卡片定位高亮动画
 * 当通过URL参数定位到具体产品卡片时，添加此样式
 */
.highlight-card .product-detail-inner {
    animation: highlightPulse 3s ease-in-out;
    box-shadow: 0 0 0 4px rgba(37, 99, 235, 0.4), 0 12px 40px rgba(37, 99, 235, 0.2);
}

@keyframes highlightPulse {
    0% {
        box-shadow: 0 0 0 4px rgba(37, 99, 235, 0.6), 0 12px 40px rgba(37, 99, 235, 0.3);
        transform: scale(1);
    }
    25% {
        box-shadow: 0 0 0 8px rgba(37, 99, 235, 0.4), 0 16px 48px rgba(37, 99, 235, 0.25);
        transform: scale(1.01);
    }
    50% {
        box-shadow: 0 0 0 4px rgba(37, 99, 235, 0.6), 0 12px 40px rgba(37, 99, 235, 0.3);
        transform: scale(1);
    }
    75% {
        box-shadow: 0 0 0 8px rgba(37, 99, 235, 0.4), 0 16px 48px rgba(37, 99, 235, 0.25);
        transform: scale(1.01);
    }
    100% {
        box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
        transform: scale(1);
    }
}

/* 高亮效果期间的边框增强 */
.highlight-card .product-detail-inner::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    border-radius: 20px;
    border: 2px solid rgba(37, 99, 235, 0.5);
    pointer-events: none;
    animation: borderFade 3s ease-in-out;
}

@keyframes borderFade {
    0%, 100% {
        opacity: 0;
    }
    20%, 80% {
        opacity: 1;
    }
}

/* 确保卡片容器有相对定位以便边框定位 */
.product-detail-card {
    position: relative;
}
