/* 全局样式 */
:root {
    --primary-color: #1a1a1a;
    --secondary-color: #333333;
    --accent-color: #6c63ff;
    --light-color: #ffffff;
    --text-color: #333333;
    --text-light: #666666;
    --border-color: #e0e0e0;
    --shadow-sm: 0 2px 4px rgba(0, 0, 0, 0.08);
    --shadow-md: 0 4px 12px rgba(0, 0, 0, 0.12);
    --shadow-lg: 0 8px 24px rgba(0, 0, 0, 0.16);
    --radius-sm: 8px;
    --radius-md: 12px;
    --radius-lg: 16px;
    --transition: all 0.3s ease;
}

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

body {
    font-family: 'Inter', sans-serif;
    color: var(--text-color);
    line-height: 1.6;
    background-color: var(--light-color);
}

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

/* 导航栏 */
.navbar {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    background-color: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    border-bottom: 1px solid var(--border-color);
    z-index: 1000;
    transition: var(--transition);
}

.navbar.scrolled {
    box-shadow: var(--shadow-md);
}

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

.logo {
    font-size: 24px;
    font-weight: 800;
    color: var(--primary-color);
    text-decoration: none;
}

.nav-links {
    display: flex;
    list-style: none;
    gap: 30px;
}

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

.nav-link:hover {
    color: var(--accent-color);
}

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

.bar {
    width: 25px;
    height: 3px;
    background-color: var(--primary-color);
    margin: 3px 0;
    transition: var(--transition);
}

/* Hero区域 */
.hero {
    padding: 150px 0 100px;
    min-height: 100vh;
    display: flex;
    align-items: center;
}

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

.hero-title {
    font-size: 64px;
    font-weight: 800;
    line-height: 1.2;
    margin-bottom: 20px;
    color: var(--primary-color);
}

.hero-title span {
    display: block;
}

.hero-description {
    font-size: 18px;
    color: var(--text-light);
    margin-bottom: 40px;
}

.hero-buttons {
    display: flex;
    gap: 20px;
}

.btn {
    display: inline-block;
    padding: 15px 30px;
    font-weight: 600;
    text-decoration: none;
    border-radius: var(--radius-md);
    transition: var(--transition);
    border: none;
    cursor: pointer;
    font-size: 16px;
}

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

.btn-primary:hover {
    background-color: var(--secondary-color);
    transform: translateY(-2px);
    box-shadow: var(--shadow-md);
}

.btn-secondary {
    background-color: transparent;
    color: var(--primary-color);
    border: 2px solid var(--primary-color);
}

.btn-secondary:hover {
    background-color: var(--primary-color);
    color: var(--light-color);
}

.hero-image {
    display: flex;
    justify-content: center;
    align-items: center;
}

.profile-img {
    width: 100%;
    max-width: 400px;
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-lg);
    object-fit: cover;
}

/* 通用章节样式 */
.section-title {
    font-size: 48px;
    font-weight: 800;
    color: var(--primary-color);
    margin-bottom: 40px;
    text-align: center;
}

/* 作品展示区 */
.works {
    padding: 100px 0;
    background-color: #f9f9f9;
}

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

.work-card {
    background-color: var(--light-color);
    border-radius: var(--radius-md);
    overflow: hidden;
    box-shadow: var(--shadow-sm);
    transition: var(--transition);
}

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

.work-image {
    width: 100%;
    height: 250px;
    overflow: hidden;
}

.work-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: var(--transition);
}

.work-card:hover .work-image img {
    transform: scale(1.05);
}

.work-content {
    padding: 25px;
}

.work-title {
    font-size: 20px;
    font-weight: 700;
    margin-bottom: 10px;
    color: var(--primary-color);
}

.work-description {
    font-size: 14px;
    color: var(--text-light);
    margin-bottom: 15px;
    line-height: 1.5;
}

.work-tags {
    margin-bottom: 20px;
}

.tag {
    display: inline-block;
    padding: 5px 12px;
    background-color: #f0f0f0;
    color: var(--text-light);
    font-size: 12px;
    font-weight: 500;
    border-radius: 20px;
    margin-right: 8px;
}

.work-link {
    display: inline-block;
    color: var(--accent-color);
    font-weight: 600;
    text-decoration: none;
    transition: var(--transition);
}

.work-link:hover {
    text-decoration: underline;
}

/* 关于我区域 */
.about {
    padding: 100px 0;
}

.about-content {
    display: grid;
    grid-template-columns: 1fr 2fr;
    gap: 60px;
    align-items: center;
}

.about-image {
    display: flex;
    justify-content: center;
    align-items: center;
}

.about-text {
    max-width: 800px;
}

.about-text .section-title {
    text-align: left;
}

.about-description {
    font-size: 16px;
    color: var(--text-color);
    margin-bottom: 25px;
    line-height: 1.7;
}

.skills-title {
    font-size: 24px;
    font-weight: 700;
    margin-bottom: 20px;
    color: var(--primary-color);
}

.skills-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-bottom: 20px;
}

.skill-tag {
    display: inline-block;
    padding: 8px 16px;
    background-color: #f0f0f0;
    color: var(--text-color);
    font-size: 14px;
    font-weight: 500;
    border-radius: 25px;
    transition: var(--transition);
}

.skill-tag:hover {
    background-color: var(--accent-color);
    color: var(--light-color);
}

.experience-education {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 40px;
    margin-top: 40px;
}

.exp-edu-title {
    font-size: 24px;
    font-weight: 700;
    margin-bottom: 20px;
    color: var(--primary-color);
}

.timeline-item {
    margin-bottom: 25px;
    padding-left: 20px;
    border-left: 2px solid var(--border-color);
    position: relative;
}

.timeline-item::before {
    content: '';
    position: absolute;
    left: -6px;
    top: 0;
    width: 12px;
    height: 12px;
    border-radius: 50%;
    background-color: var(--accent-color);
}

.timeline-title {
    font-size: 18px;
    font-weight: 600;
    margin-bottom: 5px;
    color: var(--primary-color);
}

.timeline-company {
    font-size: 14px;
    font-weight: 500;
    color: var(--accent-color);
    margin-bottom: 5px;
}

.timeline-date {
    font-size: 12px;
    color: var(--text-light);
}

/* 联系我区域 */
.contact {
    padding: 100px 0;
    background-color: #f9f9f9;
}

.contact-form-container {
    max-width: 800px;
    margin: 0 auto;
}

.contact-form {
    background-color: var(--light-color);
    padding: 40px;
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-md);
}

.form-title {
    font-size: 28px;
    font-weight: 700;
    margin-bottom: 30px;
    color: var(--primary-color);
}

.form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
    margin-bottom: 20px;
}

.form-group {
    margin-bottom: 20px;
}

.form-label {
    display: block;
    font-weight: 600;
    margin-bottom: 8px;
    color: var(--text-color);
}

.form-input, .form-textarea {
    width: 100%;
    padding: 15px;
    border: 2px solid var(--border-color);
    border-radius: var(--radius-sm);
    font-size: 16px;
    transition: var(--transition);
    font-family: 'Inter', sans-serif;
}

.form-input:focus, .form-textarea:focus {
    outline: none;
    border-color: var(--accent-color);
    box-shadow: 0 0 0 3px rgba(108, 99, 255, 0.1);
}

.form-textarea {
    resize: vertical;
    min-height: 150px;
}

.btn-submit {
    width: 100%;
    padding: 18px;
    font-size: 18px;
    margin-top: 20px;
}

/* 页脚 */
.footer {
    padding: 60px 0;
    background-color: var(--primary-color);
    color: var(--light-color);
}

.footer-content {
    text-align: center;
}

.footer-logo {
    font-size: 28px;
    font-weight: 800;
    margin-bottom: 15px;
}

.footer-tagline {
    font-size: 16px;
    color: rgba(255, 255, 255, 0.8);
    margin-bottom: 30px;
}

.social-links {
    display: flex;
    justify-content: center;
    gap: 20px;
    margin-bottom: 30px;
}

.social-link {
    display: flex;
    justify-content: center;
    align-items: center;
    width: 45px;
    height: 45px;
    background-color: rgba(255, 255, 255, 0.1);
    color: var(--light-color);
    border-radius: 50%;
    transition: var(--transition);
}

.social-link:hover {
    background-color: var(--accent-color);
    transform: translateY(-3px);
}

.footer-copyright {
    font-size: 14px;
    color: rgba(255, 255, 255, 0.6);
}

/* 回到顶部按钮 */
.back-to-top {
    position: fixed;
    bottom: 30px;
    right: 30px;
    width: 50px;
    height: 50px;
    background-color: var(--primary-color);
    color: var(--light-color);
    border: none;
    border-radius: 50%;
    display: flex;
    justify-content: center;
    align-items: center;
    cursor: pointer;
    transition: var(--transition);
    opacity: 0;
    visibility: hidden;
    z-index: 999;
}

.back-to-top.visible {
    opacity: 1;
    visibility: visible;
}

.back-to-top:hover {
    background-color: var(--accent-color);
    transform: translateY(-5px);
}

/* 响应式设计 */
@media (max-width: 1024px) {
    .hero-content {
        grid-template-columns: 1fr;
        text-align: center;
        gap: 40px;
    }

    .hero-buttons {
        justify-content: center;
    }

    .works-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .about-content {
        grid-template-columns: 1fr;
        text-align: center;
    }

    .about-text .section-title {
        text-align: center;
    }

    .experience-education {
        grid-template-columns: 1fr;
    }

    .form-row {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 768px) {
    .nav-links {
        position: fixed;
        top: 80px;
        left: -100%;
        flex-direction: column;
        background-color: var(--light-color);
        width: 100%;
        padding: 20px;
        transition: var(--transition);
        box-shadow: var(--shadow-md);
        gap: 15px;
    }

    .nav-links.active {
        left: 0;
    }

    .menu-toggle {
        display: flex;
    }

    .hero-title {
        font-size: 48px;
    }

    .section-title {
        font-size: 36px;
    }

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

    .contact-form {
        padding: 25px;
    }

    .about-description {
        font-size: 15px;
    }
}

@media (max-width: 480px) {
    .hero-title {
        font-size: 36px;
    }

    .section-title {
        font-size: 28px;
    }

    .hero {
        padding: 120px 0 80px;
    }

    .works, .about, .contact {
        padding: 60px 0;
    }

    .btn {
        padding: 12px 24px;
        font-size: 14px;
    }

    .hero-buttons {
        flex-direction: column;
        align-items: center;
    }

    .back-to-top {
        width: 40px;
        height: 40px;
        bottom: 20px;
        right: 20px;
    }
}

/* 动画效果 */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes fadeIn {
    from {
        opacity: 0;
    }
    to {
        opacity: 1;
    }
}

@keyframes bounce {
    0%, 20%, 50%, 80%, 100% {
        transform: translateY(0);
    }
    40% {
        transform: translateY(-10px);
    }
    60% {
        transform: translateY(-5px);
    }
}

/* 图片懒加载 */
.lazy {
    opacity: 0;
    transition: opacity 0.3s ease;
}

.lazy.loaded {
    opacity: 1;
}