/* =========================================
   Capabilities Page Specific Styles
   ========================================= */

/* 1. Page Header (Hero) - 覆盖式设计 */
.cap-header {
    position: relative;
    height: 450px; /* 适中高度 */
    display: flex;
    align-items: center;
    background: url('./images/家庭文化4.png') center/cover no-repeat fixed; /* 视差效果 */
    margin-bottom: 2rem;
    overflow: hidden;
}

.cap-header-overlay {
    position: absolute;
    top: 0; left: 0; width: 100%; height: 100%;
    /* 渐变遮罩：左侧深色以突出文字，右侧透明 */
    background: linear-gradient(90deg, rgba(26, 32, 44, 0.9) 0%, rgba(26, 32, 44, 0.7) 50%, rgba(51, 128, 200, 0.2) 100%);
    z-index: 1;
}

.cap-header-content {
    position: relative;
    z-index: 2;
    color: white;
    padding-top: 40px;
}

.cap-badge {
    display: inline-block;
    background: rgba(51, 128, 200, 0.3);
    border: 1px solid rgba(51, 128, 200, 0.5);
    backdrop-filter: blur(4px);
    padding: 6px 16px;
    border-radius: 50px;
    font-size: 0.85rem;
    font-weight: 600;
    margin-bottom: 1.5rem;
    letter-spacing: 1px;
    color: #63b3ed;
    text-transform: uppercase;
}

.cap-title {
    font-size: 3rem;
    font-weight: 700;
    line-height: 1.2;
    margin-bottom: 1.5rem;
}

.cap-title .highlight {
    color: #63b3ed; /* 更亮的蓝色适配深色背景 */
    position: relative;
    display: inline-block;
}

.cap-title .highlight::after {
    content: '';
    position: absolute;
    bottom: 5px; left: 0; width: 100%; height: 8px;
    background: rgba(51, 128, 200, 0.4);
    z-index: -1;
    border-radius: 4px;
}

.cap-subtitle {
    font-size: 1.1rem;
    line-height: 1.8;
    color: #e2e8f0;
    max-width: 600px;
}

/* 2. Stats Grid (Bento Style) */
.cap-stats-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    grid-template-rows: auto;
    gap: 24px;
    margin-top: -60px; /* 负边距上移，产生重叠层级感 */
    position: relative;
    z-index: 10;
}

.cap-stat-card {
    background: rgba(255, 255, 255, 0.85);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border: 1px solid rgba(255, 255, 255, 0.6);
    border-radius: 20px;
    padding: 2rem;
    box-shadow: 0 10px 30px -5px rgba(0,0,0,0.08);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.cap-stat-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 20px 40px -10px rgba(51, 128, 200, 0.15);
    background: rgba(255, 255, 255, 0.95);
}

/* 主卡片跨两列 */
.cap-stat-card.main-stat {
    grid-column: span 2;
    background: linear-gradient(135deg, rgba(255,255,255,0.9), rgba(240, 249, 255, 0.9));
    position: relative;
    overflow: hidden;
}

.stat-icon-wrapper {
    width: 50px; height: 50px;
    background: rgba(51, 128, 200, 0.1);
    color: var(--primary-color);
    border-radius: 12px;
    display: flex; align-items: center; justify-content: center;
    margin-bottom: 1.5rem;
}
.stat-icon-wrapper.green { background: rgba(0, 200, 83, 0.1); color: var(--accent-color); }
.stat-icon-wrapper svg { width: 28px; height: 28px; }

.stat-info h3 { font-size: 1rem; color: var(--text-sub); margin-bottom: 0.5rem; font-weight: 500; }
.stat-number-group { display: flex; align-items: baseline; gap: 4px; margin-bottom: 0.5rem; }
.stat-counter { font-family: 'JetBrains Mono', monospace; font-size: 2.5rem; font-weight: 700; color: var(--text-main); }
.stat-unit { font-size: 1rem; color: var(--text-light); font-weight: 600; }
.stat-info p { font-size: 0.85rem; color: var(--text-light); }

/* 3. Tech Tabs */
.bg-light-glass {
    background: rgba(248, 250, 252, 0.5); /* 极淡的背景区分 */
    border-top: 1px solid rgba(255,255,255,0.2);
    border-bottom: 1px solid rgba(255,255,255,0.2);
}

.tech-tabs {
    display: flex;
    justify-content: center;
    gap: 1rem;
    margin-bottom: 3rem;
}

.tech-tab-btn {
    padding: 12px 28px;
    border: none;
    background: rgba(255, 255, 255, 0.5);
    border: 1px solid rgba(255, 255, 255, 0.6);
    border-radius: 50px;
    font-size: 1rem;
    font-weight: 500;
    color: var(--text-sub);
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 2px 5px rgba(0,0,0,0.02);
}

.tech-tab-btn:hover {
    background: white;
    color: var(--primary-color);
    transform: translateY(-2px);
}

.tech-tab-btn.active {
    background: var(--primary-color);
    color: white;
    box-shadow: 0 5px 15px rgba(51, 128, 200, 0.3);
    border-color: var(--primary-color);
}

/* Tab Contents */
.tab-content { display: none; opacity: 0; transform: translateY(10px); transition: all 0.4s ease; }
.tab-content.active { display: block; opacity: 1; transform: translateY(0); }

.equipment-grid-layout {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
    gap: 2rem;
}

.equip-card {
    background: white;
    border-radius: 16px;
    overflow: hidden;
    border: 1px solid rgba(0,0,0,0.05);
    box-shadow: var(--shadow-sm);
    transition: var(--transition);
    display: flex;
    flex-direction: column;
}

.equip-card:hover {
    box-shadow: var(--shadow-lg);
    transform: translateY(-5px);
    border-color: rgba(51, 128, 200, 0.2);
}

.equip-img-box {
    height: 220px;
    background: #f1f5f9;
    position: relative;
    overflow: hidden;
}

.equip-img-box img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s ease;
}

.equip-card:hover .equip-img-box img { transform: scale(1.05); }

.equip-tag {
    position: absolute;
    top: 12px; left: 12px;
    background: rgba(0,0,0,0.6);
    color: white;
    font-size: 0.75rem;
    padding: 4px 10px;
    border-radius: 4px;
    backdrop-filter: blur(4px);
}

.equip-info { padding: 1.5rem; flex-grow: 1; display: flex; flex-direction: column; }
.equip-info h3 { font-size: 1.25rem; margin-bottom: 1rem; color: var(--text-main); }

.specs-list {
    display: flex;
    gap: 1.5rem;
    margin-bottom: 1rem;
    padding-bottom: 1rem;
    border-bottom: 1px dashed #e2e8f0;
}

.spec-item { display: flex; flex-direction: column; font-size: 0.85rem; color: var(--text-sub); }
.spec-item strong { font-size: 1rem; color: var(--text-main); font-family: 'JetBrains Mono'; margin-top: 2px; }

.equip-desc { font-size: 0.9rem; color: var(--text-light); line-height: 1.6; }

/* 4. Process Timeline */
.process-timeline {
    position: relative;
    display: flex;
    justify-content: space-between;
    padding: 40px 20px;
    margin-top: 2rem;
}

.process-line {
    position: absolute;
    top: 70px; /* 图标中心位置 */
    left: 50px;
    right: 50px;
    height: 2px;
    background: repeating-linear-gradient(to right, #e2e8f0 0, #e2e8f0 10px, transparent 10px, transparent 20px);
    z-index: 0;
}

.process-node {
    position: relative;
    z-index: 1;
    text-align: center;
    width: 22%;
}

.node-icon {
    width: 60px; height: 60px;
    background: white;
    border: 2px solid #e2e8f0;
    border-radius: 50%;
    margin: 0 auto 1.5rem;
    display: flex; align-items: center; justify-content: center;
    color: var(--text-light);
    transition: all 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    box-shadow: 0 4px 10px rgba(0,0,0,0.03);
}

.node-icon svg { width: 28px; height: 28px; }

.process-node:hover .node-icon {
    border-color: var(--primary-color);
    color: white;
    background: var(--primary-color);
    transform: scale(1.15);
    box-shadow: 0 10px 25px rgba(51, 128, 200, 0.3);
}

.process-node h4 { font-size: 1.1rem; color: var(--text-main); margin-bottom: 0.5rem; font-weight: 600; }
.process-node p { font-size: 0.9rem; color: var(--text-light); }

/* 5. Certificate Card - Revised Structure */
.cert-glass-card {
    background: linear-gradient(120deg, rgba(255,255,255,0.8), rgba(255,255,255,0.4));
    border: 1px solid rgba(255,255,255,0.6);
    border-radius: 24px;
    padding: 2.5rem;
    display: flex;
    align-items: center;
    justify-content: space-between; /* 确保左右分布 */
    gap: 3rem; /* 增加间距 */
    box-shadow: var(--shadow-lg);
}

/* 左侧文字块，占据剩余空间 */
.cert-info-block {
    flex: 1;
}

/* 右侧图片块，固定宽度，不收缩 */
.cert-icon-block {
    flex-shrink: 0;
    width: 140px; /* 稍微加大尺寸 */
    height: 180px;
    border: 5px solid white;
    box-shadow: 0 10px 20px rgba(0,0,0,0.1);
    transform: rotate(3deg); /* 向右倾斜 */
    transition: transform 0.3s ease;
}
.cert-icon-block:hover { transform: rotate(0) scale(1.05); }
.cert-thumb { width: 100%; height: 100%; object-fit: cover; }

.cert-text h3 { font-size: 1.5rem; margin-bottom: 0.5rem; color: var(--text-main); }
.cert-text p { color: var(--text-sub); margin-bottom: 0.5rem; }
.cert-desc { margin-top: 1rem; font-size: 0.95rem; line-height: 1.6; max-width: 650px; }

.cert-badge-group { display: flex; gap: 10px; margin-top: 1.5rem; }
.cert-badge {
    background: rgba(251, 191, 36, 0.15);
    color: #b45309;
    padding: 6px 14px;
    border-radius: 6px;
    font-size: 0.85rem;
    font-weight: 600;
    border: 1px solid rgba(251, 191, 36, 0.3);
}

/* Mobile Responsiveness */
@media (max-width: 992px) {
    .cap-stats-grid { grid-template-columns: repeat(2, 1fr); margin-top: 0; }
    .cap-stat-card.main-stat { grid-column: span 2; }
}

@media (max-width: 768px) {
    .cap-header { height: 350px; }
    .cap-title { font-size: 2rem; }
    .cap-stats-grid { grid-template-columns: 1fr; }
    .cap-stat-card.main-stat { grid-column: span 1; }
    
    .process-timeline { flex-direction: column; gap: 2rem; padding-left: 20px; }
    .process-line { width: 2px; height: 100%; top: 0; left: 49px; right: auto; background: repeating-linear-gradient(to bottom, #e2e8f0 0, #e2e8f0 10px, transparent 10px, transparent 20px); }
    .process-node { width: 100%; display: flex; text-align: left; align-items: center; gap: 20px; }
    .node-icon { margin: 0; }
    
    /* Certificate Card Mobile - Stacked, Image on Top */
    .cert-glass-card {
        flex-direction: column-reverse; /* 反向堆叠，使HTML中靠后的图片显示在上方 */
        text-align: center;
        gap: 2rem;
    }
    .cert-icon-block {
        transform: rotate(0); /* 移动端取消倾斜 */
        margin-bottom: 0;
    }
    .cert-desc { margin-left: auto; margin-right: auto; }
    .cert-badge-group { justify-content: center; }
}