/* 全局样式 */
:root {
    --primary-color: #4e73df;
    --secondary-color: #6c757d;
    --success-color: #1cc88a;
    --info-color: #36b9cc;
    --warning-color: #f6c23e;
    --danger-color: #e74a3b;
    --light-color: #f8f9fc;
    --dark-color: #5a5c69;
}

body {
    font-family: "Segoe UI", "Microsoft YaHei", sans-serif;
    color: #444;
    line-height: 1.6;
}

/* 图标样式 */
.feature-icon {
    width: 45px;
    height: 45px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    font-size: 1.2rem;
}

.process-icon {
    width: 30px;
    height: 30px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.9rem;
    font-weight: bold;
}

.step-icon {
    font-size: 1.2rem;
}

/* 按钮动画效果 */
.btn {
    transition: all 0.3s ease;
}

.btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
}

/* 卡片悬浮效果 */
.card {
    transition: all 0.3s ease;
}

.card:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.1) !important;
}

/* 导航栏样式 */
.navbar {
    padding: 0.8rem 1rem;
    transition: all 0.3s ease;
}

.navbar-brand {
    font-weight: 700;
    color: var(--primary-color);
}

.nav-link {
    position: relative;
    font-weight: 500;
    padding: 0.5rem 1rem;
}

.nav-link::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 50%;
    width: 0;
    height: 2px;
    background-color: var(--primary-color);
    transition: all 0.3s ease;
    transform: translateX(-50%);
}

.nav-link:hover::after,
.nav-link.active::after {
    width: 80%;
}

/* Hero 区域样式 */
.hero-section {
    background: linear-gradient(135deg, #4e73df 0%, #224abe 100%);
    position: relative;
    z-index: 1;
}

.hero-section::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-image: url("data:image/svg+xml,%3Csvg width='100' height='100' viewBox='0 0 100 100' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M11 18c3.866 0 7-3.134 7-7s-3.134-7-7-7-7 3.134-7 7 3.134 7 7 7zm48 25c3.866 0 7-3.134 7-7s-3.134-7-7-7-7 3.134-7 7 3.134 7 7 7zm-43-7c1.657 0 3-1.343 3-3s-1.343-3-3-3-3 1.343-3 3 1.343 3 3 3zm63 31c1.657 0 3-1.343 3-3s-1.343-3-3-3-3 1.343-3 3 1.343 3 3 3zM34 90c1.657 0 3-1.343 3-3s-1.343-3-3-3-3 1.343-3 3 1.343 3 3 3zm56-76c1.657 0 3-1.343 3-3s-1.343-3-3-3-3 1.343-3 3 1.343 3 3 3zM12 86c2.21 0 4-1.79 4-4s-1.79-4-4-4-4 1.79-4 4 1.79 4 4 4zm28-65c2.21 0 4-1.79 4-4s-1.79-4-4-4-4 1.79-4 4 1.79 4 4 4zm23-11c2.76 0 5-2.24 5-5s-2.24-5-5-5-5 2.24-5 5 2.24 5 5 5zm-6 60c2.21 0 4-1.79 4-4s-1.79-4-4-4-4 1.79-4 4 1.79 4 4 4zm29 22c2.76 0 5-2.24 5-5s-2.24-5-5-5-5 2.24-5 5 2.24 5 5 5zM32 63c2.76 0 5-2.24 5-5s-2.24-5-5-5-5 2.24-5 5 2.24 5 5 5zm57-13c2.76 0 5-2.24 5-5s-2.24-5-5-5-5 2.24-5 5 2.24 5 5 5zm-9-21c1.105 0 2-.895 2-2s-.895-2-2-2-2 .895-2 2 .895 2 2 2zM60 91c1.105 0 2-.895 2-2s-.895-2-2-2-2 .895-2 2 .895 2 2 2zM35 41c1.105 0 2-.895 2-2s-.895-2-2-2-2 .895-2 2 .895 2 2 2zM12 60c1.105 0 2-.895 2-2s-.895-2-2-2-2 .895-2 2 .895 2 2 2z' fill='%23ffffff' fill-opacity='0.05' fill-rule='evenodd'/%3E%3C/svg%3E");
    opacity: 0.6;
    z-index: -1;
    pointer-events: none;
}

/* 确保按钮在最上层并可点击 */
.detection-btn, .reduction-btn {
    position: relative;
    z-index: 10;
}

/* 修复可能导致按钮无法点击的悬浮数据区域 */
.hero-section .position-absolute {
    z-index: 5;
    pointer-events: none;
}

.hero-section .position-absolute .container,
.hero-section .position-absolute .row,
.hero-section .position-absolute .col-md-3 {
    pointer-events: auto;
}

/* 表格样式 */
.table th {
    font-weight: 600;
}

.table-striped tbody tr:nth-of-type(odd) {
    background-color: rgba(78, 115, 223, 0.05);
}

/* 进度条样式 */
.progress {
    height: 0.8rem;
    background-color: #eaecf4;
    border-radius: 0.5rem;
    overflow: hidden;
}

.progress-bar {
    border-radius: 0.5rem;
}

/* 手风琴样式 */
.accordion-button:not(.collapsed) {
    background-color: rgba(78, 115, 223, 0.1);
    color: var(--primary-color);
    box-shadow: none;
}

.accordion-button:focus {
    box-shadow: none;
    border-color: rgba(78, 115, 223, 0.3);
}

/* 回到顶部按钮 */
.back-to-top {
    position: fixed;
    bottom: 30px;
    right: 30px;
    width: 45px;
    height: 45px;
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 99;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.2);
}

.back-to-top.show {
    opacity: 1;
    visibility: visible;
}

/* 调整移动端响应式样式 */
@media (max-width: 767.98px) {
    .hero-section {
        padding-top: 2rem;
        padding-bottom: 3rem;
    }
    
    h1 {
        font-size: 2rem;
    }
    
    h2 {
        font-size: 1.7rem;
    }
    
    .process-step {
        flex-direction: column;
        align-items: center;
        text-align: center;
    }
    
    .process-icon {
        margin-bottom: 0.5rem;
    }
    
    .table {
        font-size: 0.85rem;
    }
}

/* 自定义动画 */
@keyframes pulse {
    0% {
        transform: scale(1);
    }
    50% {
        transform: scale(1.05);
    }
    100% {
        transform: scale(1);
    }
}

.pulse {
    animation: pulse 2s infinite;
}

/* 快捷导航栏 */
.quick-nav {
    font-size: 0.85rem;
    border-bottom: 1px solid rgba(0, 0, 0, 0.05);
}

.quick-nav a:hover {
    color: var(--primary-color) !important;
}

/* 社交分享按钮 */
.social-links a {
    transition: all 0.3s ease;
}

.social-links a:hover {
    transform: translateY(-3px);
}

/* 案例卡片样式 */
.reduction-comparison h6 {
    font-size: 0.9rem;
}

/* 表单样式 */
.form-control:focus {
    border-color: rgba(78, 115, 223, 0.3);
    box-shadow: 0 0 0 0.25rem rgba(78, 115, 223, 0.1);
}

/* 页脚样式 */
footer {
    background-color: #212529;
}

footer .social-links a:hover {
    color: var(--primary-color) !important;
}