/* ===== 基础重置 & 变量 ===== */
:root {
    --bg-primary: #0a0a0a;
    --bg-secondary: #111111;
    --bg-card: #1a1a1a;
    --text-primary: #ffffff;
    --text-secondary: #a0a0a0;
    --text-muted: #666666;
    --accent: #2d8a4e;
    --accent-hover: #246b3d;
    --accent-glow: rgba(45, 138, 78, 0.3);
    --border: #222222;
    --font-sans: 'Segoe UI', 'PingFang SC', 'Microsoft YaHei', sans-serif;
    --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    --shadow: 0 4px 30px rgba(0, 0, 0, 0.3);
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
    scroll-padding-top: 70px;
}

body {
    font-family: var(--font-sans);
    background-color: var(--bg-primary);
    color: var(--text-primary);
    line-height: 1.7;
    overflow-x: hidden;
}

a {
    text-decoration: none;
    color: inherit;
    transition: var(--transition);
}

ul {
    list-style: none;
}

img {
    max-width: 100%;
    display: block;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 24px;
}

/* ===== 导航栏 ===== */
.navbar {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 1000;
    padding: 20px 0;
    transition: var(--transition);
}

.navbar.scrolled {
    background: rgba(10, 10, 10, 0.95);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    padding: 12px 0;
    border-bottom: 1px solid var(--border);
}

.nav-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 24px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.nav-logo {
    font-size: 24px;
    font-weight: 800;
    letter-spacing: -1px;
    background: linear-gradient(135deg, var(--accent), #4caf50);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.nav-menu {
    display: flex;
    gap: 36px;
}

.nav-link {
    font-size: 15px;
    color: var(--text-secondary);
    position: relative;
    padding: 4px 0;
}

.nav-link::after {
    content: '';
    position: absolute;
    bottom: -2px;
    left: 0;
    width: 0;
    height: 2px;
    background: var(--accent);
    transition: var(--transition);
    border-radius: 2px;
}

.nav-link:hover,
.nav-link.active {
    color: var(--text-primary);
}

.nav-link:hover::after,
.nav-link.active::after {
    width: 100%;
}

.nav-toggle {
    display: none;
    flex-direction: column;
    gap: 5px;
    cursor: pointer;
    padding: 4px;
}

.nav-toggle span {
    display: block;
    width: 24px;
    height: 2px;
    background: var(--text-primary);
    transition: var(--transition);
    border-radius: 2px;
}

.nav-toggle.active span:nth-child(1) {
    transform: rotate(45deg) translate(5px, 5px);
}

.nav-toggle.active span:nth-child(2) {
    opacity: 0;
}

.nav-toggle.active span:nth-child(3) {
    transform: rotate(-45deg) translate(5px, -5px);
}

/* ===== Hero 区域 ===== */
.hero {
    position: relative;
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    background: linear-gradient(135deg, #0a0a0a 0%, #0a1a0f 50%, #0a0a0a 100%);
}

.hero::before {
    content: '';
    position: absolute;
    top: -50%;
    right: -30%;
    width: 800px;
    height: 800px;
    background: radial-gradient(circle, var(--accent-glow) 0%, transparent 70%);
    pointer-events: none;
    animation: floatGlow 8s ease-in-out infinite;
}

.hero::after {
    content: '';
    position: absolute;
    bottom: -30%;
    left: -20%;
    width: 600px;
    height: 600px;
    background: radial-gradient(circle, rgba(45, 138, 78, 0.15) 0%, transparent 70%);
    pointer-events: none;
    animation: floatGlow 10s ease-in-out infinite reverse;
}

@keyframes floatGlow {
    0%, 100% { transform: translate(0, 0) scale(1); }
    50% { transform: translate(30px, -30px) scale(1.1); }
}

.hero-overlay {
    position: absolute;
    inset: 0;
    background: url("data:image/svg+xml,%3Csvg viewBox='0 0 256 256' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='noiseFilter'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23noiseFilter)' opacity='0.03'/%3E%3C/svg%3E");
    pointer-events: none;
}

.hero-content {
    position: relative;
    z-index: 2;
    text-align: center;
    max-width: 800px;
    padding: 0 24px;
}

.hero-greeting {
    font-size: 18px;
    color: var(--accent);
    letter-spacing: 4px;
    text-transform: uppercase;
    margin-bottom: 16px;
    opacity: 0;
    animation: fadeInUp 0.8s ease forwards;
}

.hero-title {
    font-size: clamp(48px, 8vw, 96px);
    font-weight: 800;
    line-height: 1.1;
    margin-bottom: 20px;
    opacity: 0;
    animation: fadeInUp 0.8s ease 0.2s forwards;
}

.accent {
    background: linear-gradient(135deg, var(--accent), #4caf50);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.hero-subtitle {
    font-size: clamp(18px, 2.5vw, 24px);
    color: var(--text-secondary);
    margin-bottom: 16px;
    opacity: 0;
    animation: fadeInUp 0.8s ease 0.4s forwards;
}

.hero-desc {
    font-size: 16px;
    color: var(--text-muted);
    margin-bottom: 40px;
    line-height: 1.8;
    opacity: 0;
    animation: fadeInUp 0.8s ease 0.6s forwards;
}

.hero-actions {
    display: flex;
    gap: 16px;
    justify-content: center;
    flex-wrap: wrap;
    margin-bottom: 48px;
    opacity: 0;
    animation: fadeInUp 0.8s ease 0.8s forwards;
}

.btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 14px 36px;
    border-radius: 50px;
    font-size: 15px;
    font-weight: 600;
    cursor: pointer;
    transition: var(--transition);
    border: 2px solid transparent;
    font-family: inherit;
}

.btn-primary {
    background: var(--accent);
    color: #fff;
    border-color: var(--accent);
}

.btn-primary:hover {
    background: var(--accent-hover);
    border-color: var(--accent-hover);
    transform: translateY(-2px);
    box-shadow: 0 8px 30px var(--accent-glow);
}

.btn-outline {
    background: transparent;
    color: var(--text-primary);
    border-color: var(--border);
}

.btn-outline:hover {
    border-color: var(--accent);
    color: var(--accent);
    transform: translateY(-2px);
}

.hero-social {
    display: flex;
    gap: 20px;
    justify-content: center;
    opacity: 0;
    animation: fadeInUp 0.8s ease 1s forwards;
}

.social-link {
    width: 44px;
    height: 44px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 1px solid var(--border);
    color: var(--text-secondary);
    font-size: 18px;
    transition: var(--transition);
}

.social-link:hover {
    border-color: var(--accent);
    color: var(--accent);
    transform: translateY(-3px);
    box-shadow: 0 4px 20px var(--accent-glow);
}

.scroll-indicator {
    position: absolute;
    bottom: 40px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
    color: var(--text-muted);
    font-size: 12px;
    letter-spacing: 2px;
    text-transform: uppercase;
    animation: fadeInUp 0.8s ease 1.2s forwards;
    opacity: 0;
}

.scroll-arrow {
    width: 24px;
    height: 36px;
    border: 2px solid var(--text-muted);
    border-radius: 12px;
    position: relative;
}

.scroll-arrow::before {
    content: '';
    position: absolute;
    top: 6px;
    left: 50%;
    transform: translateX(-50%);
    width: 3px;
    height: 8px;
    background: var(--accent);
    border-radius: 2px;
    animation: scrollDot 2s ease-in-out infinite;
}

@keyframes scrollDot {
    0% { transform: translateX(-50%) translateY(0); opacity: 1; }
    100% { transform: translateX(-50%) translateY(12px); opacity: 0; }
}

/* ===== 通用 Section 样式 ===== */
section {
    padding: 120px 0;
}

.section-header {
    text-align: center;
    margin-bottom: 64px;
}

.section-title {
    font-size: clamp(32px, 5vw, 48px);
    font-weight: 700;
    margin-bottom: 16px;
}

.section-divider {
    width: 60px;
    height: 3px;
    background: linear-gradient(90deg, var(--accent), transparent);
    margin: 0 auto 16px;
    border-radius: 2px;
}

.section-desc {
    color: var(--text-secondary);
    font-size: 17px;
}

/* ===== About 区域 ===== */
.about {
    background: var(--bg-secondary);
    position: relative;
}

.about-content {
    display: grid;
    grid-template-columns: 1fr 1.5fr;
    gap: 64px;
    align-items: center;
}

.about-image {
    display: flex;
    justify-content: center;
}

.about-image-frame {
    width: 300px;
    height: 300px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--accent), #4caf50);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 120px;
    color: rgba(255, 255, 255, 0.3);
    position: relative;
    overflow: hidden;
}

.about-image-frame::before {
    content: '';
    position: absolute;
    inset: 6px;
    border-radius: 50%;
    background: var(--bg-secondary);
}

.about-avatar {
    position: relative;
    z-index: 1;
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: 50%;
}

.about-text h3 {
    font-size: 28px;
    margin-bottom: 20px;
    background: linear-gradient(135deg, var(--text-primary), var(--text-secondary));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.about-text p {
    color: var(--text-secondary);
    margin-bottom: 16px;
    font-size: 16px;
}

.about-stats {
    display: flex;
    gap: 48px;
    margin-top: 36px;
    padding-top: 36px;
    border-top: 1px solid var(--border);
}

.stat {
    display: flex;
    flex-direction: column;
}

.stat-num {
    font-size: 36px;
    font-weight: 800;
    background: linear-gradient(135deg, var(--accent), #4caf50);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.stat-label {
    font-size: 14px;
    color: var(--text-muted);
    margin-top: 4px;
}

/* ===== Works 作品集 ===== */
.works {
    background: var(--bg-primary);
}

.works-filter {
    display: flex;
    justify-content: center;
    gap: 12px;
    margin-bottom: 48px;
    flex-wrap: wrap;
}

.filter-btn {
    padding: 10px 28px;
    border-radius: 50px;
    background: transparent;
    color: var(--text-secondary);
    border: 1px solid var(--border);
    cursor: pointer;
    font-size: 14px;
    font-family: inherit;
    transition: var(--transition);
}

.filter-btn:hover {
    border-color: var(--accent);
    color: var(--text-primary);
}

.filter-btn.active {
    background: var(--accent);
    border-color: var(--accent);
    color: #fff;
}

.works-list {
    display: flex;
    flex-direction: column;
    gap: 48px;
}

.work-row {
    display: flex;
    align-items: center;
    gap: 40px;
    background: var(--bg-card);
    border-radius: 20px;
    border: 1px solid var(--border);
    overflow: hidden;
    transition: var(--transition);
}

.work-row:hover {
    border-color: var(--accent);
    box-shadow: 0 20px 60px rgba(45, 138, 78, 0.12);
}

.work-row:nth-child(even) {
    flex-direction: row-reverse;
}

.work-media {
    flex: 0 0 45%;
    cursor: pointer;
    position: relative;
}

.work-thumb {
    position: relative;
    overflow: hidden;
    aspect-ratio: 16/10;
}

.work-thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.6s ease;
}

.work-video {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    transition: transform 0.6s ease;
}

.work-row:hover .work-thumb img,
.work-row:hover .work-thumb video {
    transform: scale(1.08);
}

.work-play {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%) scale(0);
    width: 64px;
    height: 64px;
    border-radius: 50%;
    background: var(--accent);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 22px;
    color: #fff;
    transition: var(--transition);
    z-index: 2;
    box-shadow: 0 4px 20px var(--accent-glow);
}

.work-row:hover .work-play {
    transform: translate(-50%, -50%) scale(1);
}

.work-detail {
    flex: 1;
    padding: 32px 32px 32px 0;
}

.work-row:nth-child(even) .work-detail {
    padding: 32px 0 32px 32px;
}

.work-detail-header {
    margin-bottom: 20px;
}

.work-detail-title {
    font-size: 24px;
    font-weight: 700;
    margin-bottom: 8px;
}

.work-detail-tag {
    display: inline-block;
    padding: 4px 14px;
    border-radius: 50px;
    background: rgba(45, 138, 78, 0.15);
    color: var(--accent);
    font-size: 13px;
    font-weight: 500;
}

.work-detail-body {
    margin-bottom: 24px;
}

.work-detail-body p {
    color: var(--text-secondary);
    font-size: 15px;
    line-height: 1.8;
    margin-bottom: 12px;
}

.work-detail-body p:last-child {
    margin-bottom: 0;
}

.work-detail-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 16px;
    padding-top: 20px;
    border-top: 1px solid var(--border);
}

.work-detail-meta span {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    font-size: 13px;
    color: var(--text-muted);
}

.work-detail-meta span i {
    color: var(--accent);
    font-size: 14px;
}

/* ===== Contact 联系我 ===== */
.contact {
    background: var(--bg-secondary);
}

.contact-content {
    display: grid;
    grid-template-columns: 1fr 1.5fr;
    gap: 64px;
}

.contact-info {
    display: flex;
    flex-direction: column;
    gap: 24px;
}

.contact-card {
    padding: 28px 32px;
    background: var(--bg-card);
    border-radius: 16px;
    border: 1px solid var(--border);
    transition: var(--transition);
}

.contact-card:hover {
    border-color: var(--accent);
    transform: translateY(-4px);
    box-shadow: 0 10px 40px rgba(45, 138, 78, 0.12);
}

.contact-card i {
    font-size: 28px;
    color: var(--accent);
    margin-bottom: 12px;
}

.contact-card h4 {
    font-size: 16px;
    font-weight: 600;
    margin-bottom: 6px;
}

.contact-card p {
    color: var(--text-secondary);
    font-size: 15px;
}

.contact-form {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.form-group input,
.form-group textarea {
    width: 100%;
    padding: 16px 20px;
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: 12px;
    color: var(--text-primary);
    font-size: 15px;
    font-family: inherit;
    transition: var(--transition);
    outline: none;
}

.form-group input:focus,
.form-group textarea:focus {
    border-color: var(--accent);
    box-shadow: 0 0 0 3px var(--accent-glow);
}

.form-group input::placeholder,
.form-group textarea::placeholder {
    color: var(--text-muted);
}

.form-group textarea {
    min-height: 140px;
    resize: vertical;
}

.btn-submit {
    align-self: flex-start;
}

/* ===== Footer ===== */
.footer {
    padding: 48px 0 24px;
    border-top: 1px solid var(--border);
}

.footer-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 32px;
}

.footer-logo {
    font-size: 22px;
    font-weight: 800;
    background: linear-gradient(135deg, var(--accent), #4caf50);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.footer-social {
    display: flex;
    gap: 16px;
}

.footer-social .social-link {
    width: 36px;
    height: 36px;
    font-size: 15px;
}

.footer-bottom {
    text-align: center;
    color: var(--text-muted);
    font-size: 14px;
    padding-top: 24px;
    border-top: 1px solid var(--border);
}

/* ===== 视频弹窗 ===== */
.video-modal {
    display: none;
    position: fixed;
    inset: 0;
    z-index: 2000;
    align-items: center;
    justify-content: center;
}

.video-modal.active {
    display: flex;
}

.video-modal-backdrop {
    position: absolute;
    inset: 0;
    background: rgba(0, 0, 0, 0.9);
    backdrop-filter: blur(8px);
}

.video-modal-content {
    position: relative;
    width: 90%;
    max-width: 1000px;
    max-height: 85vh;
    animation: fadeInUp 0.4s ease;
}

.video-modal-close {
    position: absolute;
    top: -44px;
    right: 0;
    background: none;
    border: none;
    color: #fff;
    font-size: 36px;
    cursor: pointer;
    padding: 4px 12px;
    line-height: 1;
    transition: var(--transition);
    opacity: 0.7;
}

.video-modal-close:hover {
    opacity: 1;
    transform: rotate(90deg);
}

.video-modal-player {
    width: 100%;
    max-height: 85vh;
    border-radius: 12px;
    background: #000;
    display: block;
    outline: none;
}

/* ===== 动画 ===== */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(40px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* ===== 滚动触发动画 ===== */
.reveal {
    opacity: 0;
    transform: translateY(40px);
    transition: all 0.8s cubic-bezier(0.4, 0, 0.2, 1);
}

.reveal.active {
    opacity: 1;
    transform: translateY(0);
}

/* ===== 响应式设计 ===== */
@media (max-width: 1024px) {
    .works-list {
        gap: 36px;
    }

    .work-row {
        gap: 24px;
    }

    .work-detail {
        padding: 24px 24px 24px 0;
    }

    .work-row:nth-child(even) .work-detail {
        padding: 24px 0 24px 24px;
    }
}

@media (max-width: 768px) {
    section {
        padding: 80px 0;
    }

    .nav-menu {
        position: fixed;
        top: 0;
        right: -100%;
        width: 280px;
        height: 100vh;
        background: rgba(10, 10, 10, 0.98);
        backdrop-filter: blur(20px);
        flex-direction: column;
        justify-content: center;
        align-items: center;
        gap: 32px;
        transition: var(--transition);
        border-left: 1px solid var(--border);
    }

    .nav-menu.active {
        right: 0;
    }

    .nav-toggle {
        display: flex;
    }

    .about-content {
        grid-template-columns: 1fr;
        gap: 40px;
        text-align: center;
    }

    .about-stats {
        justify-content: center;
    }

    .works-list {
        gap: 32px;
    }

    .work-row {
        flex-direction: column !important;
        gap: 0;
    }

    .work-media {
        flex: none;
        width: 100%;
    }

    .work-thumb {
        aspect-ratio: 16/9;
        border-radius: 0;
    }

    .work-detail {
        padding: 24px !important;
    }

    .work-detail-title {
        font-size: 20px;
    }

    .contact-content {
        grid-template-columns: 1fr;
        gap: 40px;
    }

    .btn-submit {
        align-self: stretch;
    }

    .hero-actions {
        flex-direction: column;
        align-items: center;
    }

    .btn {
        width: 100%;
        max-width: 280px;
        justify-content: center;
    }
}

@media (max-width: 480px) {
    .about-stats {
        flex-direction: column;
        gap: 24px;
        align-items: center;
    }

    .about-image-frame {
        width: 220px;
        height: 220px;
        font-size: 80px;
    }

    .contact-card {
        padding: 20px 24px;
    }
}
