/* ===== 基础变量 ===== */
:root {
    --bg-primary: #0a0e17;
    --bg-secondary: #111827;
    --bg-card: #1a2332;
    --bg-card-hover: #1f2b3d;
    --text-primary: #e5e7eb;
    --text-secondary: #9ca3af;
    --text-muted: #6b7280;
    --accent-blue: #3b82f6;
    --accent-purple: #8b5cf6;
    --accent-cyan: #06b6d4;
    --accent-green: #10b981;
    --gradient-main: linear-gradient(135deg, #3b82f6, #8b5cf6);
    --gradient-hero: linear-gradient(160deg, #0a0e17 0%, #1a1040 40%, #0f172a 100%);
    --border-color: rgba(255,255,255,0.06);
    --shadow-card: 0 4px 24px rgba(0,0,0,0.3);
    --radius: 12px;
    --radius-sm: 8px;
    --nav-height: 64px;
    --container-width: 1100px;
}

/* ===== Reset ===== */
*, *::before, *::after { margin: 0; padding: 0; box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: var(--nav-height); }
body {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Microsoft YaHei", sans-serif;
    background: var(--bg-primary);
    color: var(--text-primary);
    line-height: 1.7;
    -webkit-font-smoothing: antialiased;
}
a { color: inherit; text-decoration: none; }
ul { list-style: none; }
img { max-width: 100%; }

/* ===== 容器 ===== */
.container { max-width: var(--container-width); margin: 0 auto; padding: 0 24px; }

/* ===== 导航栏 ===== */
.navbar {
    position: fixed; top: 0; left: 0; right: 0; z-index: 1000;
    background: rgba(10,14,23,0.85);
    backdrop-filter: blur(16px);
    border-bottom: 1px solid var(--border-color);
    transition: background 0.3s;
}
.navbar.scrolled { background: rgba(10,14,23,0.95); }
.nav-container {
    max-width: var(--container-width); margin: 0 auto; padding: 0 24px;
    display: flex; align-items: center; justify-content: space-between;
    height: var(--nav-height);
}
.nav-logo { font-size: 18px; font-weight: 700; background: var(--gradient-main); -webkit-background-clip: text; -webkit-text-fill-color: transparent; }
.nav-menu { display: flex; gap: 28px; }
.nav-menu a { font-size: 14px; color: var(--text-secondary); transition: color 0.2s; position: relative; }
.nav-menu a:hover, .nav-menu a.active { color: var(--text-primary); }
.nav-menu a.active::after { content: ''; position: absolute; bottom: -4px; left: 0; right: 0; height: 2px; background: var(--gradient-main); border-radius: 1px; }

/* 汉堡菜单 */
.nav-toggle { display: none; background: none; border: none; cursor: pointer; padding: 8px; }
.nav-toggle span { display: block; width: 22px; height: 2px; background: var(--text-primary); margin: 5px 0; transition: all 0.3s; border-radius: 2px; }
.nav-toggle.active span:nth-child(1) { transform: rotate(45deg) translate(5px, 5px); }
.nav-toggle.active span:nth-child(2) { opacity: 0; }
.nav-toggle.active span:nth-child(3) { transform: rotate(-45deg) translate(5px, -5px); }

/* ===== Hero ===== */
.hero {
    position: relative; min-height: 100vh; display: flex; align-items: center; justify-content: center;
    padding: calc(var(--nav-height) + 40px) 24px 80px;
    overflow: hidden;
}
.hero-bg {
    position: absolute; inset: 0;
    background: var(--gradient-hero);
}
.hero-bg::before {
    content: ''; position: absolute; inset: 0;
    background: radial-gradient(ellipse 600px 400px at 70% 30%, rgba(59,130,246,0.12), transparent),
                radial-gradient(ellipse 500px 350px at 30% 70%, rgba(139,92,246,0.08), transparent);
}
.hero-bg::after {
    content: ''; position: absolute; inset: 0;
    background-image: radial-gradient(rgba(255,255,255,0.03) 1px, transparent 1px);
    background-size: 32px 32px;
}
.hero-content { position: relative; text-align: center; max-width: 700px; }
.hero-badge {
    display: inline-block; padding: 6px 16px; border-radius: 20px;
    background: rgba(59,130,246,0.15); border: 1px solid rgba(59,130,246,0.3);
    color: var(--accent-blue); font-size: 13px; font-weight: 500;
    margin-bottom: 24px;
}
.hero-name {
    font-size: clamp(40px, 8vw, 72px); font-weight: 800;
    background: linear-gradient(135deg, #fff 0%, #c4b5fd 50%, #93c5fd 100%);
    -webkit-background-clip: text; -webkit-text-fill-color: transparent;
    line-height: 1.1; margin-bottom: 12px;
}
.hero-title { font-size: clamp(18px, 3vw, 24px); color: var(--text-secondary); font-weight: 400; margin-bottom: 12px; }
.hero-tagline { font-size: clamp(15px, 2.5vw, 18px); color: var(--text-muted); margin-bottom: 8px; letter-spacing: 0.5px; }
.tagline-highlight {
    color: transparent; background: linear-gradient(90deg, #60a5fa, #a78bfa);
    -webkit-background-clip: text; -webkit-text-fill-color: transparent;
    font-weight: 700; padding: 0 2px;
}
.hero-subtitle { font-size: 14px; color: var(--text-muted); margin-bottom: 40px; }
.hero-stats { display: flex; justify-content: center; gap: 32px; margin-bottom: 40px; flex-wrap: wrap; }
.stat-item { text-align: center; }
.stat-number {
    display: block; font-size: 36px; font-weight: 800;
    background: var(--gradient-main); -webkit-background-clip: text; -webkit-text-fill-color: transparent;
}
.stat-label { font-size: 13px; color: var(--text-muted); }
.hero-actions { display: flex; gap: 16px; justify-content: center; }

/* 按钮 */
.btn {
    display: inline-flex; align-items: center; gap: 8px;
    padding: 12px 28px; border-radius: 8px; font-size: 15px; font-weight: 600;
    transition: all 0.2s; cursor: pointer; border: none;
}
.btn-primary { background: var(--gradient-main); color: #fff; }
.btn-primary:hover { transform: translateY(-2px); box-shadow: 0 8px 24px rgba(59,130,246,0.3); }
.btn-outline { background: transparent; color: var(--text-primary); border: 1px solid rgba(255,255,255,0.2); }
.btn-outline:hover { border-color: rgba(255,255,255,0.4); background: rgba(255,255,255,0.05); }

/* 滚动指示器 */
.scroll-indicator {
    position: absolute; bottom: 32px; left: 50%; transform: translateX(-50%);
    display: flex; flex-direction: column; align-items: center; gap: 8px;
    color: var(--text-muted); font-size: 12px;
}
.scroll-arrow { width: 20px; height: 20px; border-right: 2px solid var(--text-muted); border-bottom: 2px solid var(--text-muted);
    transform: rotate(45deg); animation: bounce 2s infinite; }
@keyframes bounce { 0%, 20%, 50%, 80%, 100% { transform: rotate(45deg) translateY(0); } 40% { transform: rotate(45deg) translateY(6px); } 60% { transform: rotate(45deg) translateY(3px); } }

/* ===== 通用区块 ===== */
.section { padding: 80px 0; }
.section-alt { background: var(--bg-secondary); }
.section-title {
    font-size: 28px; font-weight: 700; text-align: center; margin-bottom: 48px;
    position: relative; padding-bottom: 16px;
}
.section-title::after {
    content: ''; position: absolute; bottom: 0; left: 50%; transform: translateX(-50%);
    width: 48px; height: 3px; background: var(--gradient-main); border-radius: 2px;
}

/* ===== 核心亮点 ===== */
.highlights-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: 20px; }
.highlight-card {
    background: var(--bg-card); border: 1px solid var(--border-color); border-radius: var(--radius);
    padding: 28px 24px; transition: all 0.3s;
    opacity: 0; transform: translateY(20px);
}
.highlight-card.visible { opacity: 1; transform: translateY(0); }
.highlight-card:hover { background: var(--bg-card-hover); border-color: rgba(59,130,246,0.2); transform: translateY(-4px); box-shadow: var(--shadow-card); }
.highlight-icon { width: 44px; height: 44px; border-radius: 10px; background: rgba(59,130,246,0.12); color: var(--accent-blue); display: flex; align-items: center; justify-content: center; margin-bottom: 16px; }
.highlight-icon svg { width: 22px; height: 22px; }
.highlight-card h3 { font-size: 16px; font-weight: 600; margin-bottom: 8px; }
.highlight-card p { font-size: 14px; color: var(--text-secondary); line-height: 1.6; }

/* ===== 专业能力 ===== */
.skills-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 24px; }
.skill-card {
    background: var(--bg-card); border: 1px solid var(--border-color); border-radius: var(--radius);
    overflow: hidden; transition: all 0.3s;
}
.skill-card:hover { border-color: rgba(59,130,246,0.2); box-shadow: var(--shadow-card); }
.skill-header { display: flex; align-items: center; gap: 14px; padding: 20px 24px; border-bottom: 1px solid var(--border-color); }
.skill-icon {
    width: 40px; height: 40px; border-radius: 10px; display: flex; align-items: center; justify-content: center;
    font-size: 14px; font-weight: 800; color: #fff; flex-shrink: 0;
}
.skill-icon.ai { background: linear-gradient(135deg, #8b5cf6, #6366f1); }
.skill-icon.cloud { background: linear-gradient(135deg, #3b82f6, #06b6d4); }
.skill-icon.pm { background: linear-gradient(135deg, #10b981, #059669); }
.skill-icon.tool { background: linear-gradient(135deg, #f59e0b, #d97706); }
.skill-header h3 { font-size: 16px; font-weight: 600; }
.skill-body { padding: 20px 24px; }
.skill-body p { font-size: 14px; color: var(--text-secondary); margin-bottom: 14px; line-height: 1.6; }
.skill-tags { display: flex; flex-wrap: wrap; gap: 8px; }
.tag {
    padding: 4px 12px; border-radius: 6px; font-size: 12px; font-weight: 500;
    background: rgba(59,130,246,0.1); color: var(--accent-blue);
    border: 1px solid rgba(59,130,246,0.15);
}

/* ===== 时间线 ===== */
.timeline { position: relative; padding-left: 32px; }
.timeline::before { content: ''; position: absolute; left: 7px; top: 8px; bottom: 8px; width: 2px; background: linear-gradient(180deg, var(--accent-blue), var(--accent-purple), var(--accent-blue)); border-radius: 1px; }
.timeline-item { position: relative; margin-bottom: 40px; }
.timeline-item:last-child { margin-bottom: 0; }
.timeline-dot {
    position: absolute; left: -32px; top: 6px;
    width: 16px; height: 16px; border-radius: 50%;
    background: var(--bg-primary); border: 3px solid var(--accent-blue);
    z-index: 1;
}
.timeline-item:nth-child(2) .timeline-dot { border-color: var(--accent-purple); }
.timeline-item:nth-child(3) .timeline-dot { border-color: var(--accent-blue); }
.timeline-content {
    background: var(--bg-card); border: 1px solid var(--border-color); border-radius: var(--radius);
    padding: 24px; transition: all 0.3s;
}
.timeline-content:hover { border-color: rgba(59,130,246,0.2); box-shadow: var(--shadow-card); }
.timeline-header { display: flex; justify-content: space-between; align-items: flex-start; margin-bottom: 12px; gap: 16px; }
.timeline-company h3 { font-size: 18px; font-weight: 700; margin-bottom: 4px; }
.timeline-role { font-size: 14px; color: var(--accent-purple); font-weight: 500; }
.timeline-date {
    font-size: 13px; color: var(--text-muted); white-space: nowrap;
    padding: 4px 12px; background: rgba(255,255,255,0.04); border-radius: 6px;
}
.timeline-dept { font-size: 13px; color: var(--text-muted); margin-bottom: 12px; }
.timeline-achievements { padding-left: 16px; }
.timeline-achievements li {
    font-size: 14px; color: var(--text-secondary); margin-bottom: 6px;
    position: relative; padding-left: 12px; line-height: 1.6;
}
.timeline-achievements li::before { content: ''; position: absolute; left: 0; top: 10px; width: 4px; height: 4px; border-radius: 50%; background: var(--accent-purple); }

/* ===== 项目Tab ===== */
.project-tabs { display: flex; justify-content: center; gap: 12px; margin-bottom: 32px; flex-wrap: wrap; }
.tab-btn {
    padding: 10px 24px; border-radius: 8px; border: 1px solid var(--border-color);
    background: transparent; color: var(--text-secondary); font-size: 14px; font-weight: 500;
    cursor: pointer; transition: all 0.2s;
}
.tab-btn:hover { border-color: rgba(59,130,246,0.3); color: var(--text-primary); }
.tab-btn.active { background: var(--gradient-main); border-color: transparent; color: #fff; }
.tab-content { display: none; }
.tab-content.active { display: block; }

/* 项目卡片 */
.project-card {
    background: var(--bg-card); border: 1px solid var(--border-color); border-radius: var(--radius);
    margin-bottom: 16px; overflow: hidden; transition: all 0.3s;
}
.project-card:hover { border-color: rgba(59,130,246,0.2); box-shadow: var(--shadow-card); }
.project-header {
    display: flex; justify-content: space-between; align-items: flex-start;
    padding: 20px 24px; cursor: pointer; gap: 16px;
}
.project-header h3 { font-size: 16px; font-weight: 600; margin-bottom: 4px; }
.project-role { font-size: 13px; color: var(--accent-purple); font-weight: 500; }
.project-date { font-size: 13px; color: var(--text-muted); white-space: nowrap; }
.project-body { padding: 0 24px 20px; }
.project-body p { font-size: 14px; color: var(--text-secondary); margin-bottom: 12px; line-height: 1.6; }
.project-detail, .project-result { font-size: 14px; color: var(--text-secondary); margin-bottom: 10px; line-height: 1.6; }
.project-detail strong, .project-result strong { color: var(--text-primary); }
.project-tags { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 12px; }
.project-tags span {
    padding: 3px 10px; border-radius: 5px; font-size: 12px;
    background: rgba(139,92,246,0.1); color: var(--accent-purple);
    border: 1px solid rgba(139,92,246,0.15);
}

/* ===== 教育&证书 ===== */
.edu-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 20px; }
.edu-card {
    background: var(--bg-card); border: 1px solid var(--border-color); border-radius: var(--radius);
    padding: 28px 20px; text-align: center; transition: all 0.3s;
}
.edu-card:hover { border-color: rgba(59,130,246,0.2); transform: translateY(-4px); box-shadow: var(--shadow-card); }
.edu-icon {
    width: 52px; height: 52px; border-radius: 14px; margin: 0 auto 16px;
    background: rgba(59,130,246,0.12); color: var(--accent-blue);
    display: flex; align-items: center; justify-content: center;
}
.edu-icon.cert { background: rgba(139,92,246,0.12); color: var(--accent-purple); }
.edu-icon.lang { background: rgba(6,182,212,0.12); color: var(--accent-cyan); }
.edu-icon svg { width: 26px; height: 26px; }
.edu-card h3 { font-size: 16px; font-weight: 600; margin-bottom: 6px; }
.edu-card p { font-size: 13px; color: var(--text-secondary); }
.edu-date { font-size: 12px; color: var(--text-muted); display: inline-block; margin-top: 8px; }

/* ===== 联系方式 ===== */
.contact-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 20px; }
.contact-card {
    background: var(--bg-card); border: 1px solid var(--border-color); border-radius: var(--radius);
    padding: 28px 20px; text-align: center; transition: all 0.3s;
}
.contact-card:hover { border-color: rgba(59,130,246,0.2); transform: translateY(-4px); box-shadow: var(--shadow-card); }
.contact-icon {
    width: 48px; height: 48px; border-radius: 12px; margin: 0 auto 14px;
    background: rgba(59,130,246,0.12); color: var(--accent-blue);
    display: flex; align-items: center; justify-content: center;
}
.contact-icon svg { width: 22px; height: 22px; }
.contact-card h3 { font-size: 14px; font-weight: 600; margin-bottom: 6px; color: var(--text-muted); }
.contact-card p { font-size: 15px; color: var(--text-primary); line-height: 1.5; }

/* ===== Footer ===== */
.footer {
    padding: 24px 0; text-align: center; border-top: 1px solid var(--border-color);
    font-size: 13px; color: var(--text-muted);
}

/* ===== 滚动动画 ===== */
.fade-in {
    opacity: 0; transform: translateY(24px);
    transition: opacity 0.6s ease, transform 0.6s ease;
}
.fade-in.visible { opacity: 1; transform: translateY(0); }

/* ===== 响应式 ===== */
@media (max-width: 900px) {
    .skills-grid { grid-template-columns: 1fr; }
    .edu-grid { grid-template-columns: repeat(2, 1fr); }
    .contact-grid { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 768px) {
    :root { --nav-height: 56px; }
    
    /* 移动端导航 */
    .nav-toggle { display: block; }
    .nav-menu {
        position: fixed; top: var(--nav-height); left: 0; right: 0;
        background: rgba(10,14,23,0.98); backdrop-filter: blur(16px);
        flex-direction: column; gap: 0; padding: 8px 0;
        border-bottom: 1px solid var(--border-color);
        transform: translateY(-100%); opacity: 0;
        transition: all 0.3s; pointer-events: none;
    }
    .nav-menu.open { transform: translateY(0); opacity: 1; pointer-events: auto; }
    .nav-menu a { display: block; padding: 14px 24px; font-size: 15px; }
    .nav-menu a:hover { background: rgba(255,255,255,0.04); }
    
    /* Hero */
    .hero { padding-top: calc(var(--nav-height) + 24px); min-height: auto; padding-bottom: 60px; }
    .hero-stats { gap: 20px; }
    .stat-number { font-size: 28px; }
    .hero-actions { flex-direction: column; align-items: center; }
    .scroll-indicator { display: none; }
    
    /* 通用 */
    .section { padding: 56px 0; }
    .section-title { font-size: 24px; margin-bottom: 32px; }
    
    /* 亮点 */
    .highlights-grid { grid-template-columns: 1fr; }
    
    /* 时间线 */
    .timeline-header { flex-direction: column; gap: 6px; }
    .timeline-date { align-self: flex-start; }
    .timeline-company h3 { font-size: 16px; }
    
    /* 教育/联系 */
    .edu-grid { grid-template-columns: 1fr 1fr; }
    .contact-grid { grid-template-columns: 1fr 1fr; }
}

@media (max-width: 480px) {
    .container { padding: 0 16px; }
    .hero-name { font-size: 36px; }
    .hero-stats { gap: 16px; }
    .stat-item { min-width: 60px; }
    .stat-number { font-size: 24px; }
    .stat-label { font-size: 11px; }
    .highlight-card { padding: 20px; }
    .skill-body { padding: 16px; }
    .timeline { padding-left: 24px; }
    .timeline::before { left: 3px; }
    .timeline-dot { left: -24px; width: 12px; height: 12px; }
    .timeline-content { padding: 16px; }
    .project-header { padding: 16px; }
    .project-body { padding: 0 16px 16px; }
}
