/* 基础样式 - 美化版 */
:root {
    --primary: #3498db;
    --primary-dark: #2980b9;
    --secondary: #2c3e50;
    --accent: #e74c3c;
    --accent-dark: #c0392b;
    --light: #f8f9fa;
    --gray: #95a5a6;
    --dark: #34495e;
    --shadow: 0 10px 30px rgba(0, 0, 0, 0.08);
    --shadow-hover: 0 15px 40px rgba(0, 0, 0, 0.12);
    --radius: 12px;
    --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

* { margin: 0; padding: 0; box-sizing: border-box; }
body { 
    font-family: 'Inter', 'Segoe UI', 'Microsoft YaHei', sans-serif; 
    line-height: 1.7; 
    color: var(--dark); 
    background: linear-gradient(135deg, #f5f7fa 0%, #e4e8f0 100%);
    min-height: 100vh;
}

/* 现代导航栏 */
.navbar { 
    background: rgba(255, 255, 255, 0.95); 
    backdrop-filter: blur(10px);
    padding: 1.2rem 0; 
    position: fixed; 
    width: 100%; 
    top: 0; 
    z-index: 1000; 
    box-shadow: 0 2px 20px rgba(0, 0, 0, 0.05);
    border-bottom: 1px solid rgba(0, 0, 0, 0.05);
    transition: var(--transition);
}
.nav-container { 
    max-width: 1280px; 
    margin: 0 auto; 
    display: flex; 
    justify-content: space-between; 
    align-items: center; 
    padding: 0 2rem; 
}
.logo { 
    font-size: 1.8rem; 
    font-weight: 700; 
    background: linear-gradient(135deg, var(--primary), var(--secondary));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    letter-spacing: -0.5px;
}
.nav-links { 
    display: flex; 
    list-style: none; 
    gap: 2.5rem;
}
.nav-links li { margin-left: 0; }
.nav-links a { 
    color: var(--dark); 
    text-decoration: none; 
    font-weight: 500;
    font-size: 1.05rem;
    padding: 0.5rem 0;
    position: relative;
    transition: var(--transition);
}
.nav-links a::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 0;
    height: 2px;
    background: linear-gradient(90deg, var(--primary), var(--accent));
    transition: width 0.3s ease;
}
.nav-links a:hover { 
    color: var(--primary); 
}
.nav-links a:hover::after {
    width: 100%;
}

/* 容器 */
.container { 
    max-width: 1280px; 
    margin: 100px auto 0; 
    padding: 2rem; 
}

/* 页面头部 */
.page-header { 
    text-align: center; 
    margin-bottom: 3rem; 
    padding: 2.5rem; 
    background: white; 
    border-radius: var(--radius); 
    box-shadow: var(--shadow);
    border: 1px solid rgba(0,0,0,0.05);
}
.page-header h1 { 
    color: var(--secondary); 
    font-size: 2.8rem; 
    margin-bottom: 1rem; 
    font-weight: 700;
}
.page-header h2 {
    color: var(--secondary);
    font-size: 2.5rem;
    margin-bottom: 1rem;
    font-weight: 700;
}
.page-header p { 
    color: var(--gray); 
    font-size: 1.2rem; 
    max-width: 800px; 
    margin: 0 auto; 
}

/* 英雄区域美化 */
.hero { 
    background: linear-gradient(135deg, 
        rgba(52, 152, 219, 0.9) 0%, 
        rgba(41, 128, 185, 0.9) 100%),
        url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 100 100" preserveAspectRatio="none"><path d="M0,0 L100,0 L100,100 Z" fill="rgba(255,255,255,0.1)"/></svg>');
    color: white; 
    padding: 12rem 2rem 6rem; 
    text-align: center; 
    margin-top: 0;
    position: relative;
    overflow: hidden;
}
.hero::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: radial-gradient(circle at 30% 20%, rgba(255,255,255,0.1) 0%, transparent 50%);
}
.hero h1 { 
    font-size: 3.5rem; 
    font-weight: 800; 
    margin-bottom: 1.5rem; 
    line-height: 1.2;
    position: relative;
    z-index: 1;
    text-shadow: 0 2px 10px rgba(0,0,0,0.1);
}
.hero p { 
    font-size: 1.3rem; 
    max-width: 700px; 
    margin: 0 auto 3rem; 
    opacity: 0.95;
    position: relative;
    z-index: 1;
}

/* 现代化按钮 */
.cta-button { 
    display: inline-flex;
    align-items: center;
    gap: 0.8rem;
    background: linear-gradient(135deg, var(--accent), var(--accent-dark)); 
    color: white; 
    padding: 1.2rem 2.5rem; 
    text-decoration: none; 
    border-radius: var(--radius); 
    font-weight: 600; 
    font-size: 1.1rem;
    transition: var(--transition);
    border: none;
    cursor: pointer;
    position: relative;
    z-index: 1;
    overflow: hidden;
    box-shadow: var(--shadow);
}
.cta-button::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255,255,255,0.2), transparent);
    transition: left 0.6s;
}
.cta-button:hover { 
    background: linear-gradient(135deg, var(--accent-dark), #a93226);
    transform: translateY(-3px);
    box-shadow: var(--shadow-hover);
}
.cta-button:hover::before {
    left: 100%;
}

/* 关于内容 */
.about-content { 
    display: grid; 
    grid-template-columns: 1fr 1fr; 
    gap: 3rem; 
    align-items: center; 
    margin-bottom: 3rem;
}
.about-text h3 { 
    color: var(--primary); 
    font-size: 1.5rem;
    margin-bottom: 1rem; 
    font-weight: 600;
}
.skills { 
    display: flex; 
    flex-wrap: wrap; 
    gap: 1rem; 
    margin-top: 2rem; 
}
.skill-tag { 
    background: linear-gradient(135deg, var(--light), #eef2f7);
    color: var(--dark); 
    padding: 0.6rem 1.2rem; 
    border-radius: 50px; 
    font-size: 0.95rem; 
    font-weight: 500;
    border: 1px solid rgba(52, 152, 219, 0.1);
    transition: var(--transition);
}
.skill-tag:hover {
    background: linear-gradient(135deg, var(--primary), var(--primary-dark));
    color: white;
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(52, 152, 219, 0.2);
}

/* 现代化项目卡片 */
.projects-grid { 
    display: grid; 
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr)); 
    gap: 2.5rem; 
    margin-bottom: 3rem;
}
.project-card { 
    background: white; 
    border-radius: var(--radius); 
    overflow: hidden; 
    box-shadow: var(--shadow); 
    transition: var(--transition);
    height: 100%;
    border: 1px solid rgba(0,0,0,0.05);
}
.project-card:hover { 
    transform: translateY(-10px); 
    box-shadow: var(--shadow-hover);
}
.project-img { 
    height: 220px; 
    background: linear-gradient(135deg, var(--primary), var(--secondary)); 
    display: flex; 
    align-items: center; 
    justify-content: center; 
    color: white; 
    font-size: 3rem; 
    position: relative;
    overflow: hidden;
}
.project-img::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(45deg, rgba(255,255,255,0.1), transparent);
}
.project-content { 
    padding: 2rem; 
}
.project-content h3 { 
    color: var(--secondary); 
    font-size: 1.4rem; 
    margin-bottom: 1rem; 
    font-weight: 600;
}
.project-content p { 
    color: var(--gray); 
    margin-bottom: 1.5rem; 
    line-height: 1.6;
}

/* 联系卡片美化 */
.contact-grid { 
    display: grid; 
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); 
    gap: 2.5rem; 
    margin-bottom: 3rem;
}
.contact-item-home { 
    text-align: center; 
    padding: 2.5rem 2rem; 
    background: white; 
    border-radius: var(--radius); 
    border: 1px solid rgba(0,0,0,0.05);
    transition: var(--transition);
}
.contact-item-home:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-hover);
}
.contact-icon-home { 
    font-size: 2.5rem; 
    margin-bottom: 1.5rem; 
    display: inline-block;
    background: linear-gradient(135deg, var(--primary), var(--secondary));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

/* 联系信息 */
.contact-info { 
    background: white; 
    padding: 2.5rem; 
    border-radius: var(--radius); 
    box-shadow: var(--shadow); 
    max-width: 700px; 
    margin: 0 auto; 
    border: 1px solid rgba(0,0,0,0.05);
}
.contact-item { 
    display: flex; 
    align-items: center; 
    margin-bottom: 2rem; 
    padding-bottom: 2rem; 
    border-bottom: 1px solid rgba(0,0,0,0.1); 
}
.contact-item:last-child { 
    border-bottom: none; 
    margin-bottom: 0; 
    padding-bottom: 0; 
}
.contact-icon { 
    background: linear-gradient(135deg, var(--primary), var(--primary-dark)); 
    color: white; 
    width: 60px; 
    height: 60px; 
    border-radius: 50%; 
    display: flex; 
    align-items: center; 
    justify-content: center; 
    margin-right: 1.5rem; 
    flex-shrink: 0; 
    font-size: 1.8rem; 
}
.contact-details h3 { 
    color: var(--secondary); 
    margin-bottom: 0.5rem; 
    font-size: 1.3rem;
}
.contact-details p { 
    color: var(--gray); 
    font-size: 1.1rem;
}

/* 页脚美化 */
footer { 
    background: var(--secondary); 
    color: white; 
    text-align: center; 
    padding: 3rem 2rem; 
    margin-top: 6rem; 
    position: relative;
}
footer::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: linear-gradient(90deg, var(--primary), var(--accent));
}
footer p { 
    opacity: 0.9; 
    margin: 0.5rem 0;
    font-size: 1.1rem;
}

/* 响应式优化 */
@media (max-width: 768px) {
    .hero { 
        padding: 10rem 1.5rem 4rem !important; 
    }
    .hero h1 { 
        font-size: 2.5rem !important; 
    }
    .hero p { 
        font-size: 1.1rem !important; 
    }
    .nav-links { 
        display: none; 
    }
    .container { 
        padding: 1.5rem; 
    }
    .page-header { 
        padding: 1.5rem; 
    }
    .page-header h1 { 
        font-size: 2rem; 
    }
    .page-header h2 {
        font-size: 1.8rem;
    }
    .about-content { 
        grid-template-columns: 1fr; 
        gap: 2rem; 
    }
    .projects-grid {
        grid-template-columns: 1fr;
        gap: 2rem;
    }
    .contact-grid {
        grid-template-columns: 1fr;
        gap: 1.5rem;
    }
}

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

.fade-in {
    animation: fadeInUp 0.6s ease-out forwards;
}
