/* SACCC官网样式 - 基于GESP风格 */

/* 重置和基础样式 */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    /* 主色调 - 参考GESP蓝色 */
    --primary-color: #0066cc;
    --primary-light: #e6f2ff;
    --secondary-color: #00a8ff;
    --accent-color: #ff6b35;
    --text-color: #333;
    --text-light: #666;
    --border-color: #e0e0e0;
    --bg-light: #f8f9fa;
    --shadow-color: rgba(0, 0, 0, 0.1);
}

body {
    font-family: "Microsoft YaHei", "Segoe UI", "PingFang SC", "Hiragino Sans GB", sans-serif;
    color: var(--text-color);
    line-height: 1.6;
    padding-top: 76px; /* 固定导航栏高度 */
}

/* 导航栏样式 */
.navbar {
    background: linear-gradient(135deg, var(--primary-color), #0052b3) !important;
    box-shadow: 0 2px 10px var(--shadow-color);
    padding: 0.8rem 0;
    transition: all 0.3s ease;
}

.navbar-brand {
    font-weight: 700;
    font-size: 1.2rem;
    color: white !important;
}

.navbar-brand img {
    transition: transform 0.3s ease;
}

.navbar-brand:hover img {
    transform: scale(1.05);
}

.nav-link {
    color: rgba(255, 255, 255, 0.9) !important;
    font-weight: 500;
    padding: 0.5rem 1rem !important;
    transition: all 0.3s ease;
    position: relative;
}

.nav-link:hover,
.nav-link.active {
    color: white !important;
    background-color: rgba(255, 255, 255, 0.1);
    border-radius: 4px;
}

.nav-link.active::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 1rem;
    right: 1rem;
    height: 3px;
    background-color: white;
    border-radius: 3px 3px 0 0;
}

/* 主横幅区域 */
.hero-section {
    background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%);
    padding: 4rem 0;
    position: relative;
    overflow: hidden;
}

.hero-section::before {
    content: '';
    position: absolute;
    top: 0;
    right: 0;
    width: 50%;
    height: 100%;
    background: linear-gradient(135deg, var(--primary-light), transparent);
    clip-path: polygon(100% 0, 100% 100%, 0 100%);
    z-index: 0;
}

.hero-section h1 {
    font-weight: 700;
    line-height: 1.2;
    position: relative;
    z-index: 1;
}

.hero-section .lead {
    font-size: 1.2rem;
    color: var(--text-light);
    position: relative;
    z-index: 1;
}

/* 设备模拟框 */
.device-mockup {
    position: relative;
    padding: 20px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    border-radius: 20px;
    display: inline-block;
}

.device-frame {
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 20px 40px rgba(0,0,0,0.1);
    transition: transform 0.3s ease;
}

.device-frame:hover {
    transform: translateY(-5px);
}

/* 二维码区域 */
.qrcode-section {
    background: white;
    padding: 1.5rem;
    border-radius: 10px;
    box-shadow: 0 5px 15px rgba(0,0,0,0.1);
    display: inline-block;
    margin-top: 2rem;
}

/* 卡片样式 */
.card {
    border: none;
    border-radius: 12px;
    transition: all 0.3s ease;
    overflow: hidden;
}

.card:hover {
    box-shadow: 0 10px 30px rgba(0,0,0,0.15) !important;
    transform: translateY(-3px);
}

.card-header {
    border-bottom: 2px solid var(--primary-light);
    font-weight: 600;
}

/* 列表组项样式 */
.list-group-item {
    border-left: none;
    border-right: none;
    padding: 1rem 1.5rem;
    transition: all 0.3s ease;
}

.list-group-item:first-child {
    border-top: none;
}

.list-group-item:last-child {
    border-bottom: none;
}

.list-group-item:hover {
    background-color: var(--primary-light);
    padding-left: 2rem;
}

/* 角标样式 */
.badge {
    padding: 0.4em 0.8em;
    font-weight: 500;
    border-radius: 4px;
}

/* 图标圆圈 */
.icon-circle {
    width: 60px;
    height: 60px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
}

/* 日期角标 */
.date-badge {
    width: 60px;
    height: 60px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    font-size: 0.9rem;
}

/* 新闻项 */
.news-item {
    transition: all 0.3s ease;
    border: 1px solid var(--border-color) !important;
}

.news-item:hover {
    border-color: var(--primary-color) !important;
    box-shadow: 0 5px 15px rgba(0,102,204,0.1);
}

/* 按钮样式 */
.btn {
    border-radius: 6px;
    font-weight: 500;
    transition: all 0.3s ease;
    padding: 0.5rem 1.5rem;
}

.btn-lg {
    padding: 0.75rem 2rem;
}

.btn-primary {
    background: linear-gradient(135deg, var(--primary-color), #0052b3);
    border: none;
}

.btn-primary:hover {
    background: linear-gradient(135deg, #0052b3, var(--primary-color));
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(0,102,204,0.3);
}

.btn-outline-primary {
    border: 2px solid var(--primary-color);
    color: var(--primary-color);
}

.btn-outline-primary:hover {
    background-color: var(--primary-color);
    border-color: var(--primary-color);
    transform: translateY(-2px);
}

.btn-warning {
    background: linear-gradient(135deg, #ff9a3c, #ff6b35);
    border: none;
    color: white;
}

.btn-warning:hover {
    background: linear-gradient(135deg, #ff6b35, #ff9a3c);
    transform: translateY(-2px);
    color: white;
}

/* 轮播图区域 */
.carousel-section {
    background-color: var(--bg-light);
    padding: 3rem 0;
}

.swiper {
    width: 100%;
    height: 300px;
    border-radius: 12px;
    overflow: hidden;
}

.swiper-slide {
    text-align: center;
    font-size: 18px;
    display: flex;
    justify-content: center;
    align-items: center;
}

.swiper-slide img {
    display: block;
    width: 100%;
    height: 200px;
    object-fit: cover;
}

.swiper-button-next,
.swiper-button-prev {
    color: var(--primary-color);
    background-color: white;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    box-shadow: 0 2px 10px var(--shadow-color);
}

.swiper-button-next:after,
.swiper-button-prev:after {
    font-size: 18px;
    font-weight: bold;
}

/* 底部样式 */
.footer {
    background: linear-gradient(135deg, #1a1a1a, #2d3436);
}

.footer a {
    text-decoration: none;
    transition: color 0.3s ease;
}

.footer a:hover {
    color: var(--secondary-color) !important;
    padding-left: 5px;
}

.social-icons a {
    display: inline-block;
    width: 40px;
    height: 40px;
    line-height: 40px;
    text-align: center;
    background-color: rgba(255,255,255,0.1);
    border-radius: 50%;
    transition: all 0.3s ease;
}

.social-icons a:hover {
    background-color: var(--primary-color);
    transform: translateY(-3px);
}

/* 模态框样式 */
.modal-content {
    border-radius: 12px;
    border: none;
}

.modal-header {
    background: linear-gradient(135deg, var(--primary-color), #0052b3);
    color: white;
    border-radius: 12px 12px 0 0;
}

/* 粘性侧边栏 */
.sticky-top {
    position: sticky;
    z-index: 1019;
}

/* 响应式调整 */
@media (max-width: 768px) {
    body {
        padding-top: 66px;
    }
    
    .hero-section {
        padding: 2rem 0;
    }
    
    .hero-section h1 {
        font-size: 2rem;
    }
    
    .device-mockup {
        margin-top: 2rem;
    }
    
    .swiper {
        height: 250px;
    }
    
    .navbar-collapse {
        background-color: var(--primary-color);
        padding: 1rem;
        border-radius: 8px;
        margin-top: 1rem;
    }
}

/* 修改轮播图样式 */
.main-banner-carousel {
    margin-top: 20px; /* 导航栏高度 */
    position: relative;
    width: 100%;
    height: 600px; /* 固定高度，根据图片调整 */
    overflow: hidden;
    background-color: #f8f9fa; /* 背景色 */
}

.banner-slider {
    position: relative;
    width: 100%;
    height: 100%;
    display: flex;
    justify-content: center;
    align-items: center;
}

.banner-slide {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    opacity: 0;
    transition: opacity 0.8s ease;
    z-index: 1;
    display: flex;
    justify-content: center;
    align-items: center;
}

.banner-slide.active {
    opacity: 1;
    z-index: 2;
}

/* 关键修复：图片完整显示，不裁剪，保持比例 */
.banner-image {
    max-width: 100%;
    max-height: 100%;
    width: auto;
    height: auto;
    object-fit: contain; /* 改为contain，完整显示图片 */
    display: block;
    margin: 0 auto;
}

/* 控制层 */
.banner-overlay {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    z-index: 3;
    padding: 20px 0;
}

.banner-controls {
    display: flex;
    justify-content: space-between;
    align-items: center;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 40px;
}

/* 导航箭头 - 固定在两侧 */
.navigation-arrows {
    position: absolute;
    top: 50%;
    left: 0;
    right: 0;
    transform: translateY(-50%);
    display: flex;
    justify-content: space-between;
    padding: 0 20px;
    z-index: 4;
    pointer-events: none; /* 允许点击穿透到图片 */
}

.nav-arrow {
    width: 50px;
    height: 50px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.9);
    border: 2px solid rgba(0, 102, 204, 0.3);
    color: #0066cc;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.3s ease;
    font-size: 1.5rem;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
    pointer-events: auto; /* 恢复点击事件 */
}

.nav-arrow:hover {
    background: #0066cc;
    color: white;
    border-color: #0066cc;
    transform: scale(1.1);
    box-shadow: 0 6px 20px rgba(0, 102, 204, 0.3);
}

/* 页码指示器 */
.page-indicators {
    display: flex;
    gap: 10px;
    background: rgba(0, 0, 0, 0.5);
    padding: 8px 15px;
    border-radius: 20px;
    backdrop-filter: blur(5px);
}

.page-indicator {
    width: 35px;
    height: 35px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.2);
    border: 2px solid rgba(255, 255, 255, 0.3);
    color: white;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1rem;
}

.page-indicator:hover {
    background: rgba(255, 255, 255, 0.3);
    border-color: white;
}

.page-indicator.active {
    background: white;
    color: #0066cc;
    border-color: white;
    transform: scale(1.1);
}

/* 页码显示 */
.page-counter {
    background: rgba(0, 0, 0, 0.5);
    color: white;
    padding: 8px 20px;
    border-radius: 20px;
    font-size: 1rem;
    font-weight: 500;
    backdrop-filter: blur(5px);
    border: 1px solid rgba(255, 255, 255, 0.2);
}

.current-page {
    color: #ffd700;
    font-weight: bold;
    font-size: 1.2rem;
}

.total-pages {
    color: rgba(255, 255, 255, 0.8);
}

/* ===================== 报名弹窗样式 ===================== */

/* 模态框内容 */
.modal-content {
    border-radius: 12px;
    border: none;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2);
}

/* 模态框头部 */
.modal-header {
    background: linear-gradient(135deg, #0066cc, #00a8ff);
    color: white;
    border-radius: 12px 12px 0 0;
    padding: 1.2rem 1.5rem;
    border-bottom: none;
}

.modal-title {
    font-weight: 600;
    font-size: 1.3rem;
}

/* 关闭按钮 */
.modal-header .btn-close {
    filter: invert(1) grayscale(100%) brightness(200%);
    opacity: 0.8;
    transition: opacity 0.3s;
}

.modal-header .btn-close:hover {
    opacity: 1;
}

/* 模态框主体 */
.modal-body {
    padding: 2rem 1.5rem;
}

/* 二维码容器 */
.qrcode-container {
    position: relative;
    display: inline-block;
    padding: 15px;
    background: white;
    border-radius: 10px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
    transition: transform 0.3s ease;
}

.qrcode-container:hover {
    transform: scale(1.02);
}

.qrcode-container img {
    width: 250px;
    height: 250px;
    object-fit: contain;
    border: 1px solid #eee;
}

/* 操作说明 */
.instructions {
    background: #f8f9fa;
    border-left: 4px solid #0066cc;
}

.instructions h6 {
    color: #0066cc;
    font-weight: 600;
}

.instructions ol {
    padding-left: 1.2rem;
    margin-bottom: 0;
}

.instructions li {
    margin-bottom: 0.5rem;
    color: #666;
}

.instructions li:last-child {
    margin-bottom: 0;
}

/* 提示信息 */
.alert {
    border: none;
    border-radius: 8px;
    padding: 0.8rem 1rem;
    margin-bottom: 0;
}

.alert-info {
    background-color: rgba(13, 110, 253, 0.1);
    color: #084298;
    border-left: 4px solid #0d6efd;
}

/* 模态框底部 */
.modal-footer {
    border-top: 1px solid #eee;
    padding: 1.2rem 1.5rem;
    justify-content: center;
}

/* 按钮样式 */
.modal-footer .btn {
    padding: 0.5rem 1.5rem;
    font-weight: 500;
    border-radius: 6px;
    transition: all 0.3s ease;
}

.modal-footer .btn-outline-secondary:hover {
    background-color: #6c757d;
    color: white;
    transform: translateY(-2px);
}

.modal-footer .btn-outline-primary:hover {
    background-color: #0066cc;
    color: white;
    transform: translateY(-2px);
}

/* 动画效果 */
@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(-20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.modal.fade .modal-dialog {
    animation: fadeIn 0.3s ease-out;
}

/* 移动端适配 */
@media (max-width: 768px) {
    .modal-dialog {
        margin: 0.5rem;
    }
    
    .modal-content {
        border-radius: 8px;
    }
    
    .modal-header {
        padding: 1rem;
    }
    
    .modal-body {
        padding: 1.5rem 1rem;
    }
    
    .qrcode-container img {
        width: 200px;
        height: 200px;
    }
    
    .modal-footer {
        padding: 1rem;
    }
    
    .modal-footer .btn {
        padding: 0.4rem 1rem;
        font-size: 0.9rem;
    }
}

/* 平板端适配 */
@media (min-width: 769px) and (max-width: 992px) {
    .modal-dialog {
        max-width: 500px;
    }
}

/* 暗色模式支持 */
@media (prefers-color-scheme: dark) {
    .modal-content {
        background-color: #2d3748;
        color: #e2e8f0;
    }
    
    .modal-header {
        background: linear-gradient(135deg, #2d3748, #4a5568);
    }
    
    .instructions {
        background-color: #4a5568;
        color: #cbd5e0;
    }
    
    .alert-info {
        background-color: rgba(13, 110, 253, 0.2);
        color: #90cdf4;
    }
    
    .modal-footer {
        border-top-color: #4a5568;
    }
}

/* 关于认证页面特定样式 */
.about-page {
    min-height: 100vh;
}

.page-header {
    background: linear-gradient(135deg, #0066cc, #00a8ff);
}

/* 根据图片中的颜色精确匹配 */
/* 等级标签样式 - 根据图片设计 */
.nav-pills .nav-link {
    padding: 0.5rem 1.5rem;
    margin: 0 0.5rem;
    border-radius: 25px;
    font-weight: 500;
    transition: all 0.3s ease;
    border: 2px solid transparent; /* 添加边框 */
}

/* 当前选中的标签（一级） */
.nav-pills .nav-link.active {
    background-color: #0066cc; /* 蓝色背景 */
    color: white; /* 白色文字 */
    border-color: #0066cc; /* 蓝色边框 */
    box-shadow: 0 4px 12px rgba(0, 102, 204, 0.3);
    transform: scale(1.05);
}

/* 未选中的标签（二级到六级） */
.nav-pills .nav-link:not(.active) {
    background-color: transparent; /* 透明背景 */
    color: #666; /* 深灰色文字 */
    border-color: #ddd; /* 浅灰色边框 */
}

/* 未选中标签的悬停效果 */
.nav-pills .nav-link:not(.active):hover {
    background-color: rgba(0, 102, 204, 0.1); /* 浅蓝色背景 */
    color: #0066cc; /* 蓝色文字 */
    border-color: #0066cc; /* 蓝色边框 */
}

/* 或者使用更接近图片的浅色样式 */
.level-tab-inactive {
    background-color: transparent;
    color: #999 !important; /* 浅灰色文字 */
    border-color: #eee !important; /* 很浅的边框 */
}

/* 悬停时稍微加深 */
.level-tab-inactive:hover {
    color: #666 !important;
    border-color: #ddd !important;
    background-color: rgba(0, 0, 0, 0.02);
}

/* 常见问题页面特定样式 */
.faq-page {
    min-height: 100vh;
}

/* 导航标签样式 */
.faq-nav .nav-pills .nav-link {
    padding: 0.6rem 1.5rem;
    margin: 0 0.5rem;
    border-radius: 25px;
    font-weight: 500;
    color: #666;
    background-color: #f8f9fa;
    border: 1px solid #e9ecef;
    transition: all 0.3s ease;
}

.faq-nav .nav-pills .nav-link:hover {
    background-color: #e9ecef;
    color: #0066cc;
}

.faq-nav .nav-pills .nav-link.active {
    background-color: #0066cc;
    color: white;
    border-color: #0066cc;
    box-shadow: 0 2px 8px rgba(0, 102, 204, 0.2);
}

/* 问题类别标题 */
.faq-category-header {
    position: relative;
    padding-bottom: 1rem;
}

.faq-category-header::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 60px;
    height: 3px;
    background: linear-gradient(90deg, #0066cc, #00a8ff);
    border-radius: 2px;
}

/* 手风琴样式 */
.accordion-button {
    background-color: #f8f9fa;
    color: #333;
    font-weight: 500;
    border: none;
    border-radius: 8px !important;
    padding: 1rem 1.25rem;
    transition: all 0.3s ease;
}

.accordion-button:not(.collapsed) {
    background-color: #0066cc;
    color: white;
    box-shadow: 0 2px 8px rgba(0, 102, 204, 0.2);
}

.accordion-button:focus {
    box-shadow: 0 0 0 0.25rem rgba(0, 102, 204, 0.25);
    border-color: #0066cc;
}

.accordion-button::after {
    background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16' fill='%23333'%3e%3cpath fill-rule='evenodd' d='M1.646 4.646a.5.5 0 0 1 .708 0L8 10.293l5.646-5.647a.5.5 0 0 1 .708.708l-6 6a.5.5 0 0 1-.708 0l-6-6a.5.5 0 0 1 0-.708z'/%3e%3c/svg%3e");
}

.accordion-button:not(.collapsed)::after {
    background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16' fill='white'%3e%3cpath fill-rule='evenodd' d='M1.646 4.646a.5.5 0 0 1 .708 0L8 10.293l5.646-5.647a.5.5 0 0 1 .708.708l-6 6a.5.5 0 0 1-.708 0l-6-6a.5.5 0 0 1 0-.708z'/%3e%3c/svg%3e");
}

.accordion-body {
    padding: 1.25rem;
    line-height: 1.8;
}

/* 信息列表样式 */
.info-list .info-item {
    padding: 0.5rem 0;
    border-bottom: 1px solid #f0f0f0;
}

.info-list .info-item:last-child {
    border-bottom: none;
}

.info-list i {
    width: 20px;
    text-align: center;
}

/* 响应式调整 */
@media (max-width: 768px) {
    .faq-nav .nav-pills {
        flex-wrap: nowrap;
        overflow-x: auto;
        padding-bottom: 0.5rem;
    }
    
    .faq-nav .nav-pills .nav-link {
        white-space: nowrap;
        margin: 0 0.25rem;
        padding: 0.5rem 1rem;
        font-size: 0.9rem;
    }
    
    .accordion-button {
        font-size: 0.95rem;
        padding: 0.75rem 1rem;
    }
}

.link-color {
    color:#0052b3;
}


/* 学习资源页面特定样式 */
.resources-page {
    min-height: 100vh;
}

/* 资源导航样式 - 与常见问题页面保持一致 */
.resource-nav {
    background-color: white;
    border-bottom: 1px solid #f0f0f0;
}

.resource-nav .nav-pills {
    display: flex;
    gap: 8px;
    padding: 4px;
    background-color: white;
    border-radius: 25px;
    border: 1px solid #f0f0f0;
    box-shadow: 0 1px 3px rgba(0,0,0,0.05);
}

.resource-nav .nav-pills .nav-link {
    padding: 8px 24px;
    border-radius: 20px;
    font-weight: 500;
    font-size: 0.95rem;
    border: 1px solid transparent;
    transition: all 0.2s ease;
    white-space: nowrap;
    min-width: 100px;
    text-align: center;
}

/* 非选中按钮 - 修复可见性问题 */
.resource-nav .nav-pills .nav-link:not(.active) {
    background-color: transparent;
    color: #999; /* 较深的灰色，使其可见 */
    border-color: #ddd; /* 可见的边框 */
}

/* 非选中按钮悬停效果 */
.resource-nav .nav-pills .nav-link:not(.active):hover {
    background-color: rgba(0, 0, 0, 0.02);
    color: #666;
    border-color: #bbb;
}

/* 选中按钮 */
.resource-nav .nav-pills .nav-link.active {
    background-color: #0066cc;
    color: white;
    border-color: #0066cc;
    box-shadow: 0 2px 8px rgba(0, 102, 204, 0.2);
}

/* 资源卡片样式 */
.resource-card {
    transition: all 0.3s ease;
    border: 1px solid rgba(0, 0, 0, 0.1) !important;
}

.resource-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.1) !important;
    border-color: #0066cc !important;
}

.resource-card .btn-primary {
    padding: 0.25rem 1rem;
    font-size: 0.875rem;
    border-radius: 6px;
}

.resource-icon {
    transition: all 0.3s ease;
}

.resource-card:hover .resource-icon {
    transform: scale(1.1);
}

/* 使用说明卡片 */
.instructions-section .card {
    border-left: 4px solid #0066cc;
}

/* 移动端适配 */
@media (max-width: 768px) {
    .resource-nav .nav-pills {
        overflow-x: auto;
        width: 100%;
        justify-content: flex-start;
    }
    
    .resource-nav .nav-pills .nav-link {
        padding: 6px 16px;
        font-size: 0.9rem;
        min-width: 90px;
    }
    
    .resource-card {
        margin-bottom: 1rem;
    }
    
    .resource-card .card-body {
        padding: 1.5rem;
    }
}