/* AGV运维管理师培训课程 - 主样式文件 */

/* ========== 全局样式 ========== */
:root {
    --primary-color: #2563eb;
    --secondary-color: #10b981;
    --danger-color: #ef4444;
    --warning-color: #f59e0b;
    --dark-color: #1f2937;
    --light-color: #f9fafb;
    --text-primary: #111827;
    --text-secondary: #6b7280;
    --border-color: #e5e7eb;
    --shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
    --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
    --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1);
    --shadow-xl: 0 20px 25px -5px rgba(0, 0, 0, 0.1);
    --transition: all 0.3s ease;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', 'PingFang SC', 'Microsoft YaHei', sans-serif;
    color: var(--text-primary);
    line-height: 1.6;
    background-color: #ffffff;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

/* ========== 导航栏 ========== */
.navbar {
    background: #ffffff;
    box-shadow: var(--shadow-sm);
    position: sticky;
    top: 0;
    z-index: 1000;
    transition: var(--transition);
}

.navbar .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1rem 20px;
}

.nav-brand {
    display: flex;
    align-items: center;
    font-size: 1.25rem;
    font-weight: 600;
    color: var(--primary-color);
}

.nav-brand i {
    margin-right: 0.5rem;
    font-size: 1.5rem;
}

.nav-menu {
    display: flex;
    list-style: none;
    gap: 2rem;
}

.nav-menu a {
    text-decoration: none;
    color: var(--text-primary);
    font-weight: 500;
    transition: var(--transition);
    position: relative;
}

.nav-menu a:hover {
    color: var(--primary-color);
}

.nav-menu a::after {
    content: '';
    position: absolute;
    bottom: -5px;
    left: 0;
    width: 0;
    height: 2px;
    background: var(--primary-color);
    transition: width 0.3s ease;
}

.nav-menu a:hover::after {
    width: 100%;
}

.nav-toggle {
    display: none;
    flex-direction: column;
    cursor: pointer;
}

.nav-toggle span {
    width: 25px;
    height: 3px;
    background: var(--text-primary);
    margin: 3px 0;
    transition: var(--transition);
}

/* ========== 英雄区域 ========== */
.hero {
    padding: 80px 0;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
}

.hero .container {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 60px;
    align-items: center;
}

.hero-content h1 {
    font-size: 3rem;
    margin-bottom: 1rem;
    line-height: 1.2;
}

.hero-subtitle {
    font-size: 1.25rem;
    margin-bottom: 2rem;
    opacity: 0.9;
}

.hero-features {
    display: flex;
    gap: 2rem;
    margin-bottom: 2rem;
}

.feature-item {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.feature-item i {
    font-size: 1.25rem;
}

.hero-actions {
    display: flex;
    gap: 1rem;
}

.btn {
    padding: 12px 24px;
    border: none;
    border-radius: 6px;
    font-size: 1rem;
    font-weight: 500;
    cursor: pointer;
    transition: var(--transition);
    text-decoration: none;
    display: inline-block;
}

.btn-primary {
    background: white;
    color: var(--primary-color);
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-lg);
}

.btn-outline {
    background: transparent;
    color: white;
    border: 2px solid white;
}

.btn-outline:hover {
    background: white;
    color: var(--primary-color);
}

.hero-image img {
    width: 100%;
    height: auto;
}

/* ========== 学习路径 ========== */
.learning-path {
    padding: 80px 0;
    background: var(--light-color);
}

.section-title {
    font-size: 2.5rem;
    text-align: center;
    margin-bottom: 3rem;
    color: var(--text-primary);
}

.path-timeline {
    display: flex;
    justify-content: space-between;
    position: relative;
}

.path-timeline::before {
    content: '';
    position: absolute;
    top: 30px;
    left: 10%;
    right: 10%;
    height: 2px;
    background: var(--border-color);
    z-index: 0;
}

.path-item {
    background: white;
    padding: 2rem;
    border-radius: 12px;
    box-shadow: var(--shadow-md);
    position: relative;
    z-index: 1;
    flex: 1;
    margin: 0 10px;
    text-align: center;
    transition: var(--transition);
}

.path-item:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-xl);
}

.path-number {
    width: 60px;
    height: 60px;
    background: var(--primary-color);
    color: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    font-weight: bold;
    margin: 0 auto 1rem;
}

.path-item h3 {
    font-size: 1.25rem;
    margin-bottom: 0.5rem;
}

.path-item p {
    color: var(--text-secondary);
    margin-bottom: 1rem;
}

.duration {
    font-size: 0.875rem;
    color: var(--primary-color);
    font-weight: 500;
}

/* ========== 课程模块 ========== */
.course-modules {
    padding: 80px 0;
}

.section-subtitle {
    text-align: center;
    color: var(--text-secondary);
    font-size: 1.125rem;
    margin-top: -2rem;
    margin-bottom: 3rem;
}

.modules-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
    gap: 30px;
}

.module-card {
    background: white;
    border-radius: 12px;
    padding: 2rem;
    box-shadow: var(--shadow-md);
    transition: var(--transition);
    border: 1px solid var(--border-color);
}

.module-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-xl);
    border-color: var(--primary-color);
}

.module-icon {
    width: 60px;
    height: 60px;
    background: linear-gradient(135deg, var(--primary-color), #8b5cf6);
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 1.5rem;
}

.module-icon i {
    font-size: 1.75rem;
    color: white;
}

.module-card h3 {
    font-size: 1.5rem;
    margin-bottom: 1rem;
    color: var(--text-primary);
}

.module-topics {
    list-style: none;
    margin-bottom: 1.5rem;
}

.module-topics li {
    padding: 0.5rem 0;
    padding-left: 1.5rem;
    position: relative;
    color: var(--text-secondary);
}

.module-topics li::before {
    content: '✓';
    position: absolute;
    left: 0;
    color: var(--secondary-color);
    font-weight: bold;
}

.module-problems {
    background: var(--light-color);
    padding: 1rem;
    border-radius: 8px;
    margin-bottom: 1.5rem;
}

.problem-tag {
    display: inline-block;
    background: var(--warning-color);
    color: white;
    padding: 0.25rem 0.75rem;
    border-radius: 4px;
    font-size: 0.875rem;
    font-weight: 500;
    margin-bottom: 0.5rem;
}

.module-problems p {
    color: var(--text-secondary);
    font-size: 0.95rem;
}

.btn-module {
    display: inline-block;
    width: 100%;
    text-align: center;
    padding: 0.75rem;
    background: var(--primary-color);
    color: white;
    text-decoration: none;
    border-radius: 6px;
    font-weight: 500;
    transition: var(--transition);
}

.btn-module:hover {
    background: #1d4ed8;
    transform: translateY(-2px);
}

/* ========== 问题导向学习 ========== */
.problem-based-learning {
    padding: 80px 0;
    background: var(--light-color);
}

.problem-categories {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 20px;
    margin-bottom: 3rem;
}

.category-card {
    background: white;
    padding: 1.5rem;
    border-radius: 12px;
    text-align: center;
    cursor: pointer;
    transition: var(--transition);
    border: 2px solid transparent;
}

.category-card:hover,
.category-card.active {
    border-color: var(--primary-color);
    transform: translateY(-3px);
    box-shadow: var(--shadow-lg);
}

.category-card i {
    font-size: 2rem;
    color: var(--primary-color);
    margin-bottom: 0.5rem;
}

.category-card h4 {
    font-size: 1.125rem;
    margin-bottom: 0.25rem;
}

.category-card .count {
    color: var(--text-secondary);
    font-size: 0.875rem;
}

.problem-list {
    display: flex;
    flex-direction: column;
    gap: 20px;
    margin-bottom: 2rem;
}

.problem-item {
    background: white;
    border-radius: 12px;
    padding: 1.5rem;
    display: flex;
    align-items: center;
    gap: 1.5rem;
    box-shadow: var(--shadow-md);
    transition: var(--transition);
}

.problem-item:hover {
    box-shadow: var(--shadow-lg);
}

.problem-severity {
    padding: 0.5rem 1rem;
    border-radius: 6px;
    font-weight: 600;
    text-transform: uppercase;
    font-size: 0.875rem;
}

.problem-severity.high {
    background: #fee2e2;
    color: var(--danger-color);
}

.problem-severity.medium {
    background: #fed7aa;
    color: var(--warning-color);
}

.problem-severity.low {
    background: #dbeafe;
    color: var(--primary-color);
}

.problem-content {
    flex: 1;
}

.problem-content h4 {
    font-size: 1.25rem;
    margin-bottom: 0.5rem;
}

.problem-content p {
    color: var(--text-secondary);
    margin-bottom: 1rem;
}

.problem-meta {
    display: flex;
    gap: 2rem;
    font-size: 0.875rem;
    color: var(--text-secondary);
}

.problem-meta i {
    margin-right: 0.25rem;
}

.btn-solve {
    padding: 0.75rem 1.5rem;
    background: var(--primary-color);
    color: white;
    border: none;
    border-radius: 6px;
    cursor: pointer;
    font-weight: 500;
    transition: var(--transition);
}

.btn-solve:hover {
    background: #1d4ed8;
    transform: translateX(5px);
}

.btn-more-problems {
    display: block;
    margin: 0 auto;
    padding: 1rem 2rem;
    background: white;
    color: var(--primary-color);
    border: 2px solid var(--primary-color);
    border-radius: 6px;
    cursor: pointer;
    font-weight: 500;
    font-size: 1rem;
    transition: var(--transition);
}

.btn-more-problems:hover {
    background: var(--primary-color);
    color: white;
}

/* ========== 实践案例 ========== */
.case-studies {
    padding: 80px 0;
}

.cases-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
    gap: 30px;
}

.case-card {
    background: white;
    border-radius: 12px;
    padding: 2rem;
    box-shadow: var(--shadow-md);
    transition: var(--transition);
}

.case-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-xl);
}

.case-header {
    display: flex;
    justify-content: space-between;
    margin-bottom: 1rem;
}

.case-type {
    background: var(--primary-color);
    color: white;
    padding: 0.25rem 0.75rem;
    border-radius: 4px;
    font-size: 0.875rem;
}

.case-difficulty {
    color: var(--text-secondary);
    font-size: 0.875rem;
}

.case-card h3 {
    font-size: 1.25rem;
    margin-bottom: 1rem;
}

.case-card p {
    color: var(--text-secondary);
    margin-bottom: 1rem;
}

.case-points {
    list-style: none;
    margin-bottom: 1.5rem;
}

.case-points li {
    padding: 0.5rem 0;
    padding-left: 1.5rem;
    position: relative;
    color: var(--text-secondary);
}

.case-points li::before {
    content: '→';
    position: absolute;
    left: 0;
    color: var(--primary-color);
    font-weight: bold;
}

.btn-case {
    display: inline-block;
    padding: 0.75rem 1.5rem;
    background: transparent;
    color: var(--primary-color);
    border: 2px solid var(--primary-color);
    border-radius: 6px;
    text-decoration: none;
    font-weight: 500;
    transition: var(--transition);
}

.btn-case:hover {
    background: var(--primary-color);
    color: white;
}

/* ========== 互动练习 ========== */
.interactive-exercises {
    padding: 80px 0;
    background: var(--light-color);
}

.exercise-types {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 30px;
}

.exercise-card {
    background: white;
    padding: 2rem;
    border-radius: 12px;
    text-align: center;
    box-shadow: var(--shadow-md);
    transition: var(--transition);
}

.exercise-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-xl);
}

.exercise-card i {
    font-size: 3rem;
    color: var(--primary-color);
    margin-bottom: 1rem;
}

.exercise-card h3 {
    font-size: 1.25rem;
    margin-bottom: 0.5rem;
}

.exercise-card p {
    color: var(--text-secondary);
    margin-bottom: 1.5rem;
}

.btn-start {
    padding: 0.75rem 2rem;
    background: var(--secondary-color);
    color: white;
    border: none;
    border-radius: 6px;
    cursor: pointer;
    font-weight: 500;
    transition: var(--transition);
}

.btn-start:hover {
    background: #059669;
    transform: translateY(-2px);
}

/* ========== 认证考核 ========== */
.certification {
    padding: 80px 0;
}

.cert-info {
    display: grid;
    grid-template-columns: 2fr 1fr;
    gap: 40px;
}

.cert-card {
    background: white;
    padding: 3rem;
    border-radius: 12px;
    box-shadow: var(--shadow-lg);
}

.cert-icon {
    width: 80px;
    height: 80px;
    background: linear-gradient(135deg, #fbbf24, #f59e0b);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 1.5rem;
}

.cert-icon i {
    font-size: 2.5rem;
    color: white;
}

.cert-card h3 {
    font-size: 1.75rem;
    margin-bottom: 1rem;
}

.cert-card p {
    color: var(--text-secondary);
    margin-bottom: 1.5rem;
}

.cert-requirements {
    list-style: none;
    margin-bottom: 2rem;
}

.cert-requirements li {
    padding: 0.75rem 0;
    padding-left: 2rem;
    position: relative;
    color: var(--text-secondary);
    border-bottom: 1px solid var(--border-color);
}

.cert-requirements li::before {
    content: '✓';
    position: absolute;
    left: 0;
    color: var(--secondary-color);
    font-weight: bold;
    font-size: 1.25rem;
}

.btn-apply {
    padding: 1rem 2rem;
    background: var(--warning-color);
    color: white;
    border: none;
    border-radius: 6px;
    cursor: pointer;
    font-size: 1.125rem;
    font-weight: 600;
    transition: var(--transition);
}

.btn-apply:hover {
    background: #d97706;
    transform: translateY(-2px);
    box-shadow: var(--shadow-lg);
}

.cert-benefits h4 {
    font-size: 1.25rem;
    margin-bottom: 1.5rem;
}

.benefit-item {
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: 1rem 0;
}

.benefit-item i {
    color: var(--secondary-color);
    font-size: 1.25rem;
}

/* ========== 学习工具 ========== */
.learning-tools {
    padding: 80px 0;
    background: var(--light-color);
}

.tools-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 30px;
}

.tool-card {
    background: white;
    padding: 2rem;
    border-radius: 12px;
    text-align: center;
    box-shadow: var(--shadow-md);
    transition: var(--transition);
    cursor: pointer;
}

.tool-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-xl);
}

.tool-card i {
    font-size: 2.5rem;
    color: var(--primary-color);
    margin-bottom: 1rem;
}

.tool-card h4 {
    font-size: 1.125rem;
    margin-bottom: 0.5rem;
}

.tool-card p {
    color: var(--text-secondary);
    font-size: 0.875rem;
}

/* ========== 资源下载 ========== */
.resources {
    padding: 80px 0;
}

.resource-categories {
    display: flex;
    justify-content: center;
    gap: 2rem;
    margin-bottom: 3rem;
}

.resource-tab {
    padding: 0.75rem 1.5rem;
    background: white;
    border: 2px solid var(--border-color);
    border-radius: 6px;
    cursor: pointer;
    font-weight: 500;
    transition: var(--transition);
}

.resource-tab.active,
.resource-tab:hover {
    background: var(--primary-color);
    color: white;
    border-color: var(--primary-color);
}

.resource-list {
    display: none;
}

.resource-list.active {
    display: block;
}

.resource-item {
    display: flex;
    align-items: center;
    gap: 1.5rem;
    padding: 1.5rem;
    background: white;
    border-radius: 12px;
    box-shadow: var(--shadow-md);
    margin-bottom: 1rem;
    transition: var(--transition);
}

.resource-item:hover {
    box-shadow: var(--shadow-lg);
}

.resource-item i {
    font-size: 2rem;
    color: var(--primary-color);
}

.resource-info {
    flex: 1;
}

.resource-info h4 {
    font-size: 1.125rem;
    margin-bottom: 0.25rem;
}

.resource-info p {
    color: var(--text-secondary);
    font-size: 0.875rem;
}

.btn-download {
    padding: 0.75rem 1.5rem;
    background: var(--secondary-color);
    color: white;
    border: none;
    border-radius: 6px;
    cursor: pointer;
    font-weight: 500;
    transition: var(--transition);
}

.btn-download:hover {
    background: #059669;
    transform: translateX(5px);
}

/* ========== 页脚 ========== */
.footer {
    background: var(--dark-color);
    color: white;
    padding: 60px 0 20px;
}

.footer-content {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr;
    gap: 40px;
    margin-bottom: 2rem;
}

.footer-section h4 {
    font-size: 1.25rem;
    margin-bottom: 1rem;
}

.footer-section p {
    color: #9ca3af;
    line-height: 1.8;
}

.footer-section ul {
    list-style: none;
}

.footer-section ul li {
    padding: 0.5rem 0;
}

.footer-section ul a {
    color: #9ca3af;
    text-decoration: none;
    transition: var(--transition);
}

.footer-section ul a:hover {
    color: white;
}

.footer-section i {
    margin-right: 0.5rem;
    color: var(--primary-color);
}

.footer-bottom {
    text-align: center;
    padding-top: 2rem;
    border-top: 1px solid #374151;
    color: #9ca3af;
}

/* ========== 浮动按钮 ========== */
.floating-buttons {
    position: fixed;
    bottom: 30px;
    right: 30px;
    display: flex;
    flex-direction: column;
    gap: 15px;
    z-index: 999;
}

.fab-button {
    width: 56px;
    height: 56px;
    border-radius: 50%;
    background: var(--primary-color);
    color: white;
    border: none;
    box-shadow: var(--shadow-lg);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.25rem;
    transition: var(--transition);
}

.fab-button:hover {
    transform: scale(1.1);
    box-shadow: var(--shadow-xl);
}

#backToTop {
    display: none;
}

/* ========== 模态窗口 ========== */
.modal {
    display: none;
    position: fixed;
    z-index: 2000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.5);
}

.modal-content {
    background-color: white;
    margin: 5% auto;
    padding: 2rem;
    border-radius: 12px;
    width: 80%;
    max-width: 600px;
    position: relative;
}

.close {
    position: absolute;
    right: 1.5rem;
    top: 1.5rem;
    font-size: 2rem;
    font-weight: bold;
    color: var(--text-secondary);
    cursor: pointer;
}

.close:hover {
    color: var(--text-primary);
}

.progress-bar {
    width: 100%;
    height: 8px;
    background: var(--border-color);
    border-radius: 4px;
    overflow: hidden;
    margin: 0.5rem 0;
}

.progress-fill {
    height: 100%;
    background: var(--primary-color);
    transition: width 0.5s ease;
}

/* ========== 响应式设计 ========== */
@media (max-width: 1024px) {
    .hero .container {
        grid-template-columns: 1fr;
        text-align: center;
    }
    
    .hero-features {
        flex-direction: column;
        align-items: center;
    }
    
    .path-timeline {
        flex-direction: column;
    }
    
    .path-timeline::before {
        display: none;
    }
    
    .path-item {
        margin: 10px 0;
    }
    
    .modules-grid {
        grid-template-columns: 1fr;
    }
    
    .problem-categories {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .exercise-types {
        grid-template-columns: 1fr;
    }
    
    .tools-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .cert-info {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 768px) {
    .nav-menu {
        display: none;
        position: absolute;
        top: 100%;
        left: 0;
        width: 100%;
        background: white;
        flex-direction: column;
        padding: 1rem;
        box-shadow: var(--shadow-md);
    }
    
    .nav-menu.active {
        display: flex;
    }
    
    .nav-toggle {
        display: flex;
    }
    
    .hero-content h1 {
        font-size: 2rem;
    }
    
    .section-title {
        font-size: 1.75rem;
    }
    
    .problem-categories {
        grid-template-columns: 1fr;
    }
    
    .footer-content {
        grid-template-columns: 1fr;
        text-align: center;
    }
    
    .floating-buttons {
        bottom: 20px;
        right: 20px;
    }
    
    .fab-button {
        width: 48px;
        height: 48px;
        font-size: 1rem;
    }
}

/* ========== 动画 ========== */
@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.animate-fade-in {
    animation: fadeIn 0.6s ease-out;
}

@keyframes pulse {
    0% {
        transform: scale(1);
    }
    50% {
        transform: scale(1.05);
    }
    100% {
        transform: scale(1);
    }
}

.animate-pulse {
    animation: pulse 2s infinite;
}

/* ========== 加载动画 ========== */
.loader {
    border: 3px solid var(--border-color);
    border-top: 3px solid var(--primary-color);
    border-radius: 50%;
    width: 40px;
    height: 40px;
    animation: spin 1s linear infinite;
    margin: 0 auto;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* ========== 工具提示 ========== */
.tooltip {
    position: relative;
    display: inline-block;
}

.tooltip .tooltiptext {
    visibility: hidden;
    width: 200px;
    background-color: var(--dark-color);
    color: white;
    text-align: center;
    border-radius: 6px;
    padding: 0.5rem;
    position: absolute;
    z-index: 1;
    bottom: 125%;
    left: 50%;
    margin-left: -100px;
    opacity: 0;
    transition: opacity 0.3s;
    font-size: 0.875rem;
}

.tooltip:hover .tooltiptext {
    visibility: visible;
    opacity: 1;
}

/* ========== 自定义滚动条 ========== */
::-webkit-scrollbar {
    width: 10px;
    height: 10px;
}

::-webkit-scrollbar-track {
    background: var(--light-color);
}

::-webkit-scrollbar-thumb {
    background: var(--primary-color);
    border-radius: 5px;
}

::-webkit-scrollbar-thumb:hover {
    background: #1d4ed8;
}
