/* --- 核心字体配置 --- */
@font-face {
    font-family: 'Lolita';
    src: url('./Lolita.woff') format('woff');
    font-display: swap;
}

:root {
    --matcha: #8BBF5C;       /* 主题抹茶绿 */
    --matcha-dark: #5E8240;   /* 深绿文字 */
    --cream: #FAF9F6;         /* 奶油底色 */
    --white: #FFFFFF;
    --pink: #FFB7C5;          /* 小安粉 */
    --gray: #666;
}

/* --- 全局重置 --- */
* { margin: 0; padding: 0; box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
    background-color: var(--cream);
    color: #444;
    font-family: "PingFang SC", "Microsoft YaHei", sans-serif; /* 正文用黑体 */
    line-height: 1.7;
    overflow-x: hidden;
}

/* 标题使用可爱字体 */
h1, h2, h3, .nav-brand, .hero-slogan, .status-date, .email-link {
    font-family: 'Lolita', cursive; 
}

a { text-decoration: none; transition: 0.3s; }

/* --- 动态背景 (Floating Blobs) --- */
.background-shapes {
    position: fixed; top: 0; left: 0; width: 100%; height: 100%;
    z-index: -1; overflow: hidden; pointer-events: none;
}
.blob {
    position: absolute; border-radius: 50%;
    filter: blur(60px); opacity: 0.4;
    animation: float 10s infinite ease-in-out;
}
.blob-1 { width: 400px; height: 400px; background: #E6F0DC; top: -10%; left: -10%; animation-delay: 0s; }
.blob-2 { width: 300px; height: 300px; background: #FFEFF2; bottom: 20%; right: -5%; animation-delay: 2s; }
.blob-3 { width: 200px; height: 200px; background: #E0EEDB; top: 40%; left: 30%; animation-delay: 4s; }

@keyframes float {
    0%, 100% { transform: translateY(0) scale(1); }
    50% { transform: translateY(-20px) scale(1.05); }
}

/* --- 🚑 导航栏修复 (Navbar Fix) --- */
.main-nav {
    position: fixed; top: 20px; left: 50%; transform: translateX(-50%);
    width: 90%; max-width: 900px;
    background: rgba(255, 255, 255, 0.7); backdrop-filter: blur(15px);
    border-radius: 50px; 
    height: 60px;
    box-shadow: 0 5px 20px rgba(0,0,0,0.03); 
    z-index: 100;
    /* 关键修复：让内部容器居中 */
    display: flex; justify-content: center; align-items: center;
}

/* 关键修复：nav-content 必须撑开宽度并使用 Flex */
.nav-content {
    width: 100%; padding: 0 30px;
    display: flex; justify-content: space-between; align-items: center;
}

.nav-brand { font-size: 1.5rem; color: var(--matcha); }
.nav-links { display: flex; list-style: none; gap: 25px; }
.nav-links a { color: #666; font-size: 0.95rem; transition: 0.3s; font-weight: 500; }
.nav-links a:hover { color: var(--matcha); }

/* --- Hero --- */
.hero {
    min-height: 90vh; display: flex; flex-direction: column; justify-content: center; align-items: center;
    text-align: center; position: relative; padding-bottom: 100px;
}
.hero-title { font-size: 5rem; color: var(--matcha); margin-bottom: 10px; }
.hero-subtitle { font-size: 1rem; letter-spacing: 3px; color: #999; font-family: sans-serif; margin-bottom: 30px; }
.hero-slogan {
    background: #fff; padding: 12px 30px; border-radius: 30px;
    color: var(--matcha-dark); box-shadow: 0 10px 30px rgba(139,191,92,0.15);
    transform: rotate(-1deg);
}
.wave-separator { position: absolute; bottom: -5px; left: 0; width: 100%; }

/* --- About (3D Photo) --- */
.about { background: #fff; padding: 100px 20px; }
.about-content-wrapper { max-width: 900px; margin: 0 auto; display: grid; grid-template-columns: 1fr 1.5fr; gap: 50px; align-items: center; }

.about-visual {
    position: relative; width: 280px; height: 280px; margin: 0 auto;
    border-radius: 50%; transform-style: preserve-3d; cursor: pointer;
}
.about-visual img {
    width: 100%; height: 100%; object-fit: cover; border-radius: 50%;
    box-shadow: 20px 20px 60px rgba(139,191,92,0.2);
    transition: transform 0.1s; 
}
.about-text h2 { font-size: 2.5rem; color: var(--matcha-dark); margin-bottom: 20px; }
.tags span {
    background: var(--cream); padding: 6px 15px; border-radius: 20px;
    font-size: 0.85rem; color: #777; margin-right: 10px; display: inline-block;
}

/* --- Timeline (时间轴) --- */
.timeline-section { padding: 100px 20px; background: var(--cream); text-align: center; }
.timeline-section h2 { font-size: 2.5rem; color: var(--matcha-dark); margin-bottom: 60px; }
.timeline-container {
    max-width: 700px; margin: 0 auto; position: relative;
    border-left: 2px solid rgba(139,191,92,0.2); text-align: left; padding-left: 40px;
}

.timeline-item { position: relative; margin-bottom: 50px; }
.status-dot {
    position: absolute; left: -46px; top: 5px; width: 14px; height: 14px;
    background: #ddd; border-radius: 50%; border: 2px solid #fff;
    box-shadow: 0 0 0 2px #eee;
}
.timeline-item.completed .status-dot { background: var(--matcha); box-shadow: 0 0 0 2px var(--matcha-dark); }
.timeline-item.active .status-dot { background: var(--pink); box-shadow: 0 0 0 2px #FF9EB5; }

.pulse { animation: pulse 2s infinite; }
@keyframes pulse { 0% { box-shadow: 0 0 0 0 rgba(255, 183, 197, 0.7); } 70% { box-shadow: 0 0 0 10px rgba(255, 183, 197, 0); } 100% { box-shadow: 0 0 0 0 rgba(255, 183, 197, 0); } }

.status-date { font-size: 1.2rem; color: var(--matcha); margin-bottom: 5px; }
.status-content h3 { font-size: 1.2rem; color: #333; margin-bottom: 5px; }
.status-content p { font-size: 0.9rem; color: #666; }
.status-badge {
    display: inline-block; background: var(--pink); color: #fff;
    font-size: 0.7rem; padding: 2px 8px; border-radius: 4px; margin-top: 5px;
}

/* --- Project Card --- */
.project { background: #fff; padding: 100px 20px; }
.project-card {
    background: #fff; border-radius: 30px; box-shadow: 0 20px 50px rgba(0,0,0,0.05);
    max-width: 800px; margin: 0 auto; overflow: hidden; border: 1px solid #f0f0f0;
    transform-style: preserve-3d;
}
.card-image img { width: 100%; height: 300px; object-fit: cover; }
.card-info { padding: 40px; text-align: left; }
.meta-row { margin-bottom: 20px; display: flex; gap: 10px; }
.role-tag { background: var(--matcha); color: #fff; padding: 4px 12px; border-radius: 6px; font-size: 0.8rem; }
.date-tag { background: #eee; color: #666; padding: 4px 12px; border-radius: 6px; font-size: 0.8rem; }

.action-buttons { margin-top: 30px; display: flex; gap: 15px; flex-wrap: wrap; }
.btn-primary {
    background: var(--matcha); color: #fff; padding: 10px 25px; border-radius: 50px;
    font-weight: bold; transition: 0.3s;
}
.btn-primary:hover { background: var(--matcha-dark); transform: translateY(-2px); }
.btn-secondary {
    background: transparent; color: #666; padding: 10px 25px; border-radius: 50px;
    border: 1px solid #ddd; transition: 0.3s;
}
.btn-secondary:hover { border-color: var(--matcha); color: var(--matcha); }

/* --- 🚑 底部联系修复 (Footer Fix) --- */
.contact { padding: 100px 20px 150px; text-align: center; } /* 底部留空 */

.contact-box {
    background: #fff; padding: 60px; border-radius: 40px;
    max-width: 600px; margin: 0 auto;
    box-shadow: 0 20px 60px rgba(139, 191, 92, 0.1);
}

.contact-box h2 { font-size: 2.5rem; color: var(--matcha-dark); margin-bottom: 30px; }

/* 修复邮箱链接：去下划线，变大，变绿 */
.email-link {
    display: block; font-size: 2rem; color: var(--matcha); 
    margin-bottom: 30px; transition: 0.3s;
}
.email-link:hover { transform: scale(1.05); color: var(--matcha-dark); }

/* 修复社交图标：变回按钮 */
.social-icons { display: flex; justify-content: center; gap: 15px; }
.social-icons a {
    background: #f5f5f5; padding: 10px 25px; border-radius: 50px;
    color: #666; font-size: 0.9rem; transition: 0.3s;
}
.social-icons a:hover {
    background: var(--matcha); color: #fff; transform: translateY(-3px);
}

.footer { text-align: center; padding: 30px; color: #aaa; font-size: 0.85rem; }

/* --- 动画类 --- */
.stagger-text { opacity: 0; transform: translateY(20px); animation: fadeUp 0.8s forwards; }
.hero-title { animation-delay: 0.1s; }
.hero-subtitle { animation-delay: 0.3s; }
.hero-slogan { animation-delay: 0.5s; }

.fade-up { opacity: 0; transform: translateY(30px); transition: 0.8s ease; }
.fade-up-stagger { opacity: 0; transform: translateX(-20px); transition: 0.6s ease; }
.visible { opacity: 1; transform: translate(0); }

@keyframes fadeUp { to { opacity: 1; transform: translateY(0); } }

/* Mobile */
@media (max-width: 768px) {
    .main-nav { top: 10px; padding: 0 10px; }
    .nav-content { padding: 0 15px; } /* 修复移动端内边距 */
    .nav-links { display: none; }
    .hero-title { font-size: 3.5rem; }
    .about-content-wrapper { grid-template-columns: 1fr; text-align: center; }
    .timeline-container { padding-left: 20px; border-left-width: 1px; }
    .status-dot { left: -26px; width: 12px; height: 12px; }
    .action-buttons { justify-content: center; }
    .email-link { font-size: 1.5rem; word-break: break-all; } /* 防止邮箱炸开屏幕 */
}