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

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background-color: #0a0a0a;
    color: #e0e0e0;
    line-height: 1.6;
    overflow-x: hidden;
}

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

/* 科技风格的渐变背景 */
body::before {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, rgba(10, 10, 10, 0.8) 0%, rgba(20, 20, 30, 0.9) 100%);
    z-index: -1;
}

/* 英雄区域 */
.hero {
    min-height: 100vh;
    display: flex;
    align-items: center;
    position: relative;
    overflow: hidden;
}

.hero::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: radial-gradient(circle at 50% 50%, rgba(30, 64, 175, 0.1) 0%, transparent 50%);
    z-index: -1;
}

.hero .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
}

.hero-content {
    flex: 1;
    min-width: 300px;
    padding-right: 40px;
}

.hero h1 {
    font-size: 4rem;
    font-weight: 700;
    margin-bottom: 1rem;
    background: linear-gradient(90deg, #64b5f6, #4fc3f7, #29b6f6);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    animation: glow 2s ease-in-out infinite alternate;
}

@keyframes glow {
    from {
        text-shadow: 0 0 20px rgba(100, 181, 246, 0.5);
    }
    to {
        text-shadow: 0 0 30px rgba(100, 181, 246, 0.8), 0 0 40px rgba(100, 181, 246, 0.5);
    }
}

.subtitle {
    font-size: 1.2rem;
    margin-bottom: 1rem;
    color: #b0bec5;
}

.tagline {
    font-size: 1.1rem;
    margin-bottom: 2rem;
    color: #64b5f6;
}

.social-links {
    display: flex;
    gap: 15px;
    margin-top: 2rem;
}

.social-link {
    display: inline-block;
    padding: 10px 20px;
    background: rgba(100, 181, 246, 0.1);
    border: 1px solid rgba(100, 181, 246, 0.3);
    border-radius: 5px;
    color: #64b5f6;
    text-decoration: none;
    transition: all 0.3s ease;
    font-size: 0.9rem;
}

.social-link:hover {
    background: rgba(100, 181, 246, 0.2);
    border-color: #64b5f6;
    box-shadow: 0 0 15px rgba(100, 181, 246, 0.5);
}

.hero-visual {
    flex: 1;
    min-width: 300px;
    display: flex;
    justify-content: center;
    align-items: center;
}

.ai-animation {
    position: relative;
    width: 300px;
    height: 300px;
}

.particle {
    position: absolute;
    width: 10px;
    height: 10px;
    background: #64b5f6;
    border-radius: 50%;
    animation: float 6s ease-in-out infinite;
    box-shadow: 0 0 10px rgba(100, 181, 246, 0.8);
}

.particle:nth-child(1) {
    top: 20%;
    left: 20%;
    animation-delay: 0s;
}

.particle:nth-child(2) {
    top: 60%;
    left: 80%;
    animation-delay: 1s;
}

.particle:nth-child(3) {
    top: 80%;
    left: 40%;
    animation-delay: 2s;
}

.particle:nth-child(4) {
    top: 40%;
    left: 60%;
    animation-delay: 3s;
}

.particle:nth-child(5) {
    top: 30%;
    left: 70%;
    animation-delay: 4s;
}

@keyframes float {
    0%, 100% {
        transform: translateY(0) translateX(0);
        opacity: 1;
    }
    50% {
        transform: translateY(-20px) translateX(20px);
        opacity: 0.5;
    }
}

/* 通用部分样式 */
section {
    padding: 100px 0;
    position: relative;
}

section::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 1px;
    background: linear-gradient(90deg, transparent, rgba(100, 181, 246, 0.3), transparent);
}

section h2 {
    font-size: 2.5rem;
    margin-bottom: 40px;
    text-align: center;
    background: linear-gradient(90deg, #64b5f6, #4fc3f7);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    position: relative;
}

section h2::after {
    content: '';
    position: absolute;
    bottom: -10px;
    left: 50%;
    transform: translateX(-50%);
    width: 100px;
    height: 2px;
    background: linear-gradient(90deg, transparent, #64b5f6, transparent);
}

/* 关于我部分 */
.about-content {
    max-width: 800px;
    margin: 0 auto;
    text-align: center;
    font-size: 1.1rem;
    line-height: 1.8;
    color: #b0bec5;
}

/* 技能部分 */
.skills-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 30px;
    margin-top: 40px;
}

.skill-card {
    background: rgba(20, 20, 30, 0.8);
    border: 1px solid rgba(100, 181, 246, 0.2);
    border-radius: 10px;
    padding: 30px;
    text-align: center;
    transition: all 0.3s ease;
    backdrop-filter: blur(10px);
}

.skill-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 10px 30px rgba(100, 181, 246, 0.2);
    border-color: rgba(100, 181, 246, 0.5);
}

.skill-icon {
    font-size: 3rem;
    margin-bottom: 20px;
}

.skill-card h3 {
    font-size: 1.3rem;
    margin-bottom: 15px;
    color: #64b5f6;
}

.skill-card ul {
    list-style: none;
    text-align: left;
}

.skill-card li {
    padding: 5px 0;
    color: #b0bec5;
    position: relative;
    padding-left: 20px;
}

.skill-card li::before {
    content: '>';
    position: absolute;
    left: 0;
    color: #64b5f6;
}

/* 项目部分 */
.projects-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 30px;
    margin-top: 40px;
}

.project-card {
    background: rgba(20, 20, 30, 0.8);
    border: 1px solid rgba(100, 181, 246, 0.2);
    border-radius: 10px;
    overflow: hidden;
    transition: all 0.3s ease;
    backdrop-filter: blur(10px);
}

.project-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 10px 30px rgba(100, 181, 246, 0.2);
    border-color: rgba(100, 181, 246, 0.5);
}

.project-image {
    height: 200px;
    background: linear-gradient(135deg, rgba(100, 181, 246, 0.1), rgba(79, 195, 247, 0.1));
    display: flex;
    align-items: center;
    justify-content: center;
    border-bottom: 1px solid rgba(100, 181, 246, 0.2);
}

.project-placeholder {
    width: 100px;
    height: 100px;
    background: rgba(100, 181, 246, 0.2);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #64b5f6;
    font-weight: bold;
    text-transform: uppercase;
    font-size: 0.9rem;
}

.project-card h3 {
    padding: 20px;
    padding-bottom: 10px;
    color: #64b5f6;
}

.project-card p {
    padding: 0 20px 20px;
    color: #b0bec5;
    font-size: 0.95rem;
}

/* 联系部分 */
.contact-content {
    max-width: 800px;
    margin: 0 auto;
    text-align: center;
}

.contact-content p {
    margin-bottom: 30px;
    font-size: 1.1rem;
    color: #b0bec5;
}

.contact-info {
    display: flex;
    flex-direction: column;
    gap: 20px;
    align-items: center;
}

.contact-item {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 15px 30px;
    background: rgba(20, 20, 30, 0.8);
    border: 1px solid rgba(100, 181, 246, 0.2);
    border-radius: 50px;
    width: 100%;
    max-width: 400px;
    transition: all 0.3s ease;
}

.contact-item:hover {
    border-color: rgba(100, 181, 246, 0.5);
    box-shadow: 0 0 20px rgba(100, 181, 246, 0.2);
}

.contact-label {
    font-weight: bold;
    color: #64b5f6;
    min-width: 80px;
}

.contact-value {
    color: #b0bec5;
}

/* 页脚 */
footer {
    padding: 40px 0;
    text-align: center;
    border-top: 1px solid rgba(100, 181, 246, 0.2);
    background: rgba(10, 10, 10, 0.8);
}

footer p {
    color: #b0bec5;
    font-size: 0.9rem;
}

/* 响应式设计 */
@media (max-width: 768px) {
    .hero .container {
        flex-direction: column;
        text-align: center;
    }
    
    .hero-content {
        padding-right: 0;
        margin-bottom: 40px;
    }
    
    .hero h1 {
        font-size: 3rem;
    }
    
    .ai-animation {
        width: 250px;
        height: 250px;
    }
    
    section {
        padding: 60px 0;
    }
    
    section h2 {
        font-size: 2rem;
    }
    
    .skills-grid,
    .projects-grid {
        grid-template-columns: 1fr;
    }
}

/* 滚动条样式 */
::-webkit-scrollbar {
    width: 8px;
}

::-webkit-scrollbar-track {
    background: #0a0a0a;
}

::-webkit-scrollbar-thumb {
    background: rgba(100, 181, 246, 0.5);
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: rgba(100, 181, 246, 0.8);
}

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

section {
    animation: fadeIn 1s ease-out;
}

/* 数字雨效果 */
#matrix {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -1;
    opacity: 0.1;
}