/* 全局样式 */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    --primary-color: #2563eb;
    --secondary-color: #1e40af;
    --text-primary: #1f2937;
    --text-secondary: #6b7280;
    --bg-primary: #ffffff;
    --bg-secondary: #f9fafb;
    --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);
    --transition: all 0.3s ease;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', 'PingFang SC', 'Hiragino Sans GB',
        'Microsoft YaHei', 'Helvetica Neue', Helvetica, Arial, sans-serif;
    line-height: 1.6;
    color: var(--text-primary);
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    min-height: 100vh;
    padding: 2rem 1rem;
}

.container {
    max-width: 1000px;
    margin: 0 auto;
    background: var(--bg-primary);
    border-radius: 16px;
    box-shadow: var(--shadow-lg);
    overflow: hidden;
    animation: fadeIn 0.6s ease-out;
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* 头部样式 */
.header {
    background: linear-gradient(135deg, var(--primary-color) 0%, var(--secondary-color) 100%);
    color: white;
    padding: 3rem 2rem;
    position: relative;
    overflow: hidden;
}

.header::before {
    content: '';
    position: absolute;
    top: -50%;
    right: -10%;
    width: 300px;
    height: 300px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 50%;
}

.header-content {
    position: relative;
    z-index: 1;
}

.name {
    font-size: 2.5rem;
    font-weight: 700;
    margin-bottom: 0.5rem;
    letter-spacing: -0.5px;
}

.title-line {
    font-size: 1.1rem;
    margin-bottom: 1.5rem;
    opacity: 0.95;
    font-weight: 400;
}

.contact-info {
    display: flex;
    flex-wrap: wrap;
    gap: 2rem;
}

.contact-item {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.95rem;
}

.icon {
    width: 20px;
    height: 20px;
    stroke-width: 2;
}

/* 主要内容 */
.main-content {
    padding: 2rem;
}

.section {
    margin-bottom: 3rem;
    animation: slideIn 0.6s ease-out;
}

@keyframes slideIn {
    from {
        opacity: 0;
        transform: translateX(-20px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

.section-title {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--text-primary);
    margin-bottom: 1.5rem;
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding-bottom: 0.75rem;
    border-bottom: 3px solid var(--primary-color);
}

.title-icon {
    font-size: 1.75rem;
}

.section-content {
    padding-left: 0.5rem;
}

/* 个人简介 */
.summary {
    font-size: 1.05rem;
    line-height: 1.8;
    color: var(--text-secondary);
    text-align: justify;
}

/* 工作经验 */
.experience-item {
    margin-bottom: 2rem;
    padding: 1.5rem;
    background: var(--bg-secondary);
    border-radius: 12px;
    border-left: 4px solid var(--primary-color);
    transition: var(--transition);
}

.experience-item:hover {
    transform: translateX(5px);
    box-shadow: var(--shadow-md);
}

.experience-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 1rem;
    flex-wrap: wrap;
    gap: 1rem;
}

.company-name {
    font-size: 1.25rem;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 0.25rem;
}

.job-title {
    font-size: 1rem;
    color: var(--text-secondary);
    font-weight: 500;
}

.date {
    font-size: 0.9rem;
    color: var(--text-secondary);
    background: white;
    padding: 0.25rem 0.75rem;
    border-radius: 20px;
    white-space: nowrap;
}

.responsibilities {
    list-style: none;
    padding-left: 0;
}

.responsibilities li {
    padding-left: 1.5rem;
    margin-bottom: 0.5rem;
    position: relative;
    color: var(--text-secondary);
}

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

/* 项目经验 */
.project-item {
    margin-bottom: 2rem;
    padding: 1.5rem;
    background: var(--bg-secondary);
    border-radius: 12px;
    transition: var(--transition);
}

.project-item:hover {
    box-shadow: var(--shadow-md);
    transform: translateY(-2px);
}

.project-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 0.75rem;
    flex-wrap: wrap;
    gap: 0.5rem;
}

.project-name {
    font-size: 1.2rem;
    font-weight: 600;
    color: var(--text-primary);
}

.project-role {
    font-size: 0.85rem;
    color: var(--primary-color);
    background: rgba(37, 99, 235, 0.1);
    padding: 0.25rem 0.75rem;
    border-radius: 20px;
    font-weight: 500;
}

.project-desc {
    color: var(--text-secondary);
    margin-bottom: 1rem;
    line-height: 1.6;
}

.tech-stack {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    margin-bottom: 1rem;
}

.tech-tag {
    background: var(--primary-color);
    color: white;
    padding: 0.25rem 0.75rem;
    border-radius: 20px;
    font-size: 0.85rem;
    font-weight: 500;
}

.project-highlights {
    list-style: none;
    padding-left: 0;
}

.project-highlights li {
    padding-left: 1.5rem;
    margin-bottom: 0.5rem;
    position: relative;
    color: var(--text-secondary);
    font-size: 0.95rem;
}

.project-highlights li::before {
    content: '✓';
    position: absolute;
    left: 0;
    color: #10b981;
    font-weight: bold;
}

/* 技能特长 */
.skills-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 1.5rem;
}

.skill-category {
    background: var(--bg-secondary);
    padding: 1.5rem;
    border-radius: 12px;
    transition: var(--transition);
}

.skill-category:hover {
    box-shadow: var(--shadow-md);
    transform: translateY(-2px);
}

.skill-category-title {
    font-size: 1.1rem;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 1rem;
}

.skill-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
}

.skill-tag {
    background: white;
    color: var(--text-primary);
    padding: 0.4rem 0.9rem;
    border-radius: 20px;
    font-size: 0.9rem;
    border: 1px solid var(--border-color);
    transition: var(--transition);
}

.skill-tag:hover {
    background: var(--primary-color);
    color: white;
    border-color: var(--primary-color);
    transform: scale(1.05);
}

.skill-tag.skill-expert {
    background: var(--primary-color);
    color: white;
    border-color: var(--primary-color);
    font-weight: 600;
}

.skill-tag.skill-expert:hover {
    background: var(--secondary-color);
    border-color: var(--secondary-color);
}

/* 教育背景 */
.education-item {
    padding: 1.5rem;
    background: var(--bg-secondary);
    border-radius: 12px;
    border-left: 4px solid var(--primary-color);
}

.education-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 1rem;
    flex-wrap: wrap;
    gap: 1rem;
}

.school-name {
    font-size: 1.2rem;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 0.25rem;
}

.degree {
    font-size: 1rem;
    color: var(--text-secondary);
}

.education-details {
    list-style: none;
    padding-left: 0;
}

.education-details li {
    padding-left: 1.5rem;
    margin-bottom: 0.5rem;
    position: relative;
    color: var(--text-secondary);
}

.education-details li::before {
    content: '•';
    position: absolute;
    left: 0;
    color: var(--primary-color);
    font-weight: bold;
    font-size: 1.2rem;
}

/* 获奖荣誉 */
.awards-list {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 1.5rem;
}

.award-item {
    display: flex;
    gap: 1rem;
    padding: 1.5rem;
    background: var(--bg-secondary);
    border-radius: 12px;
    transition: var(--transition);
    border-left: 4px solid var(--primary-color);
}

.award-item:hover {
    box-shadow: var(--shadow-md);
    transform: translateX(5px);
}

.award-icon {
    font-size: 2rem;
    flex-shrink: 0;
}

.award-content {
    flex: 1;
}

.award-title {
    font-size: 1.1rem;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 0.5rem;
}

.award-desc {
    font-size: 0.95rem;
    color: var(--text-secondary);
    line-height: 1.6;
}

/* 自我评价 */
.self-evaluation {
    background: var(--bg-secondary);
    padding: 1.5rem;
    border-radius: 12px;
    line-height: 1.8;
}

.self-evaluation p {
    color: var(--text-secondary);
    margin-bottom: 1rem;
    text-align: justify;
    text-indent: 2em;
}

.self-evaluation p:last-child {
    margin-bottom: 0;
}

/* 页脚 */
.footer {
    background: var(--bg-secondary);
    padding: 2rem;
    text-align: center;
    color: var(--text-secondary);
    font-size: 0.9rem;
    border-top: 1px solid var(--border-color);
}

/* 响应式设计 */
@media (max-width: 768px) {
    body {
        padding: 1rem 0.5rem;
    }

    .container {
        border-radius: 8px;
    }

    .header {
        padding: 2rem 1.5rem;
    }

    .name {
        font-size: 2rem;
    }

    .contact-info {
        flex-direction: column;
        gap: 1rem;
    }

    .main-content {
        padding: 1.5rem;
    }

    .section-title {
        font-size: 1.3rem;
    }

    .experience-header,
    .education-header {
        flex-direction: column;
    }

    .skills-grid {
        grid-template-columns: 1fr;
    }

    .project-header {
        flex-direction: column;
        align-items: flex-start;
    }

    .awards-list {
        grid-template-columns: 1fr;
    }

    .award-item {
        flex-direction: column;
        text-align: center;
    }
}

@media print {
    body {
        background: white;
        padding: 0;
    }

    .container {
        box-shadow: none;
        border-radius: 0;
    }

    .section {
        page-break-inside: avoid;
    }

    .experience-item,
    .project-item,
    .skill-category {
        box-shadow: none;
    }
}
