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

:root {
    --primary-gradient: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    --secondary-gradient: linear-gradient(135deg, #f093fb 0%, #f5576c 100%);
    --dark-bg: #0f0f1a;
    --card-bg: rgba(255, 255, 255, 0.05);
    --glass-bg: rgba(255, 255, 255, 0.1);
    --text-primary: #ffffff;
    --text-secondary: rgba(255, 255, 255, 0.7);
    --accent-color: #667eea;
    --transition-speed: 0.3s;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'Outfit', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    background: var(--dark-bg);
    color: var(--text-primary);
    overflow-x: hidden;
    line-height: 1.6;
}

/* ===== 背景动画 ===== */
.background-animation {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: -1;
    overflow: hidden;
}

.floating-shape {
    position: absolute;
    border-radius: 50%;
    filter: blur(60px);
    opacity: 0.5;
    animation: float 20s ease-in-out infinite;
}

.shape-1 {
    width: 400px;
    height: 400px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    top: -100px;
    right: -100px;
    animation-delay: 0s;
}

.shape-2 {
    width: 300px;
    height: 300px;
    background: linear-gradient(135deg, #f093fb 0%, #f5576c 100%);
    bottom: -50px;
    left: -50px;
    animation-delay: -5s;
}

.shape-3 {
    width: 250px;
    height: 250px;
    background: linear-gradient(135deg, #4facfe 0%, #00f2fe 100%);
    top: 50%;
    left: 50%;
    animation-delay: -10s;
}

.shape-4 {
    width: 200px;
    height: 200px;
    background: linear-gradient(135deg, #43e97b 0%, #38f9d7 100%);
    top: 20%;
    left: 10%;
    animation-delay: -15s;
}

.shape-5 {
    width: 180px;
    height: 180px;
    background: linear-gradient(135deg, #fa709a 0%, #fee140 100%);
    bottom: 20%;
    right: 15%;
    animation-delay: -8s;
}

@keyframes float {
    0%, 100% {
        transform: translate(0, 0) rotate(0deg);
    }
    25% {
        transform: translate(50px, -50px) rotate(90deg);
    }
    50% {
        transform: translate(0, -100px) rotate(180deg);
    }
    75% {
        transform: translate(-50px, -50px) rotate(270deg);
    }
}

/* ===== 导航栏 ===== */
.navbar {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    padding: 1.2rem 5%;
    background: rgba(15, 15, 26, 0.8);
    backdrop-filter: blur(20px);
    z-index: 1000;
    transition: all var(--transition-speed) ease;
}

.navbar.scrolled {
    padding: 0.8rem 5%;
    background: rgba(15, 15, 26, 0.95);
    box-shadow: 0 4px 30px rgba(0, 0, 0, 0.3);
}

.nav-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    max-width: 1400px;
    margin: 0 auto;
}

.logo {
    display: flex;
    align-items: center;
    gap: 0.8rem;
    font-size: 1.5rem;
    font-weight: 700;
    background: var(--primary-gradient);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.logo-icon {
    font-size: 2rem;
}

.nav-menu {
    display: flex;
    gap: 2.5rem;
}

.nav-link {
    color: var(--text-secondary);
    text-decoration: none;
    font-weight: 500;
    font-size: 1rem;
    position: relative;
    padding: 0.5rem 0;
    transition: color var(--transition-speed) ease;
}

.nav-link::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 0;
    height: 2px;
    background: var(--primary-gradient);
    transition: width var(--transition-speed) ease;
}

.nav-link:hover,
.nav-link.active {
    color: var(--text-primary);
}

.nav-link:hover::after,
.nav-link.active::after {
    width: 100%;
}

.hamburger {
    display: none;
    flex-direction: column;
    gap: 6px;
    cursor: pointer;
    z-index: 1001;
}

.hamburger span {
    width: 30px;
    height: 3px;
    background: var(--text-primary);
    border-radius: 3px;
    transition: all var(--transition-speed) ease;
}

/* ===== 英雄区域 ===== */
.hero {
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    padding: 120px 5% 80px;
    text-align: center;
    position: relative;
}

.hero-content {
    max-width: 900px;
    animation: fadeInUp 1s ease;
}

.hero-badge {
    display: inline-flex;
    align-items: center;
    gap: 0.6rem;
    padding: 0.6rem 1.2rem;
    background: var(--glass-bg);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 50px;
    margin-bottom: 2rem;
    font-size: 0.95rem;
    backdrop-filter: blur(10px);
    animation: pulse 2s ease-in-out infinite;
}

.badge-icon {
    font-size: 1.2rem;
}

.hero-title {
    font-size: clamp(2.5rem, 6vw, 4.5rem);
    font-weight: 800;
    line-height: 1.2;
    margin-bottom: 1.5rem;
}

.title-line {
    display: block;
    color: var(--text-secondary);
    font-weight: 400;
    margin-bottom: 0.5rem;
}

.title-highlight {
    display: block;
    background: var(--primary-gradient);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.hero-subtitle {
    font-size: 1.2rem;
    color: var(--text-secondary);
    margin-bottom: 3rem;
    line-height: 1.8;
}

.hero-buttons {
    display: flex;
    gap: 1.5rem;
    justify-content: center;
    flex-wrap: wrap;
}

.btn {
    display: inline-flex;
    align-items: center;
    gap: 0.8rem;
    padding: 1rem 2rem;
    border-radius: 12px;
    font-size: 1rem;
    font-weight: 600;
    text-decoration: none;
    transition: all var(--transition-speed) ease;
    cursor: pointer;
    border: none;
}

.btn-primary {
    background: var(--primary-gradient);
    color: white;
    box-shadow: 0 8px 30px rgba(102, 126, 234, 0.4);
}

.btn-primary:hover {
    transform: translateY(-3px);
    box-shadow: 0 12px 40px rgba(102, 126, 234, 0.6);
}

.btn-secondary {
    background: var(--glass-bg);
    color: white;
    border: 1px solid rgba(255, 255, 255, 0.2);
    backdrop-filter: blur(10px);
}

.btn-secondary:hover {
    background: rgba(255, 255, 255, 0.15);
    border-color: rgba(255, 255, 255, 0.4);
}

/* ===== 统计数据 ===== */
.stats-container {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 1.5rem;
    width: 100%;
    max-width: 1000px;
    margin-top: 4rem;
}

.stat-card {
    background: var(--card-bg);
    backdrop-filter: blur(20px);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 20px;
    padding: 2rem 1.5rem;
    text-align: center;
    transition: all var(--transition-speed) ease;
    position: relative;
    overflow: hidden;
}

.stat-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 3px;
    background: var(--primary-gradient);
    transform: scaleX(0);
    transition: transform var(--transition-speed) ease;
}

.stat-card:hover {
    transform: translateY(-10px);
    border-color: rgba(102, 126, 234, 0.3);
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
}

.stat-card:hover::before {
    transform: scaleX(1);
}

.stat-number {
    font-size: 2.5rem;
    font-weight: 800;
    background: var(--primary-gradient);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    margin-bottom: 0.5rem;
}

.stat-label {
    font-size: 1rem;
    color: var(--text-secondary);
    margin-bottom: 0.5rem;
}

.stat-icon {
    font-size: 2rem;
    opacity: 0.6;
}

/* ===== 教程中心 ===== */
.tutorials {
    padding: 100px 5%;
    position: relative;
}

.section-header {
    text-align: center;
    margin-bottom: 4rem;
}

.section-title {
    font-size: clamp(2rem, 5vw, 3rem);
    font-weight: 800;
    margin-bottom: 1rem;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 1rem;
}

.title-number {
    font-size: 4rem;
    font-weight: 800;
    background: var(--secondary-gradient);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    line-height: 1;
}

.section-subtitle {
    font-size: 1.2rem;
    color: var(--text-secondary);
}

.tutorials-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
    max-width: 1200px;
    margin: 0 auto;
}

.tutorial-card {
    background: var(--card-bg);
    backdrop-filter: blur(20px);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 24px;
    padding: 2.5rem;
    position: relative;
    overflow: hidden;
    transition: all var(--transition-speed) ease;
    opacity: 0;
    transform: translateY(30px);
    text-decoration: none;
    color: inherit;
    display: block;
}

.tutorial-card.visible {
    opacity: 1;
    transform: translateY(0);
}

.tutorial-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: var(--primary-gradient);
    opacity: 0;
    transition: opacity var(--transition-speed) ease;
    z-index: 0;
}

.tutorial-card:hover::before {
    opacity: 0.1;
}

.tutorial-card:hover {
    transform: translateY(-10px) scale(1.02);
    box-shadow: 0 25px 60px rgba(0, 0, 0, 0.4);
}

.card-number {
    position: absolute;
    top: 1.5rem;
    right: 2rem;
    font-size: 4rem;
    font-weight: 800;
    color: rgba(255, 255, 255, 0.05);
    line-height: 1;
}

.card-icon {
    font-size: 3rem;
    margin-bottom: 1.5rem;
}

.tutorial-card h3 {
    font-size: 1.5rem;
    margin-bottom: 1rem;
    position: relative;
    z-index: 1;
    text-decoration: none;
}

.tutorial-card p {
    color: var(--text-secondary);
    margin-bottom: 1.5rem;
    line-height: 1.7;
    position: relative;
    z-index: 1;
    text-decoration: none;
}

.card-link {
    display: inline-flex;
    align-items: center;
    gap: 0.6rem;
    text-decoration: none;
    color: var(--accent-color);
    font-weight: 600;
    position: relative;
    z-index: 1;
    transition: all var(--transition-speed) ease;
}

.card-link:hover {
    gap: 1rem;
}

.card-link svg {
    transition: transform var(--transition-speed) ease;
}

.card-link:hover svg {
    transform: translateX(5px);
}

/* ===== 特色功能 ===== */
.features {
    padding: 100px 5%;
    background: linear-gradient(180deg, transparent 0%, rgba(102, 126, 234, 0.05) 100%);
}

.features-list {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 2rem;
    max-width: 1200px;
    margin: 0 auto;
}

.feature-item {
    display: flex;
    gap: 1.5rem;
    padding: 2rem;
    background: var(--card-bg);
    backdrop-filter: blur(20px);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 20px;
    transition: all var(--transition-speed) ease;
    opacity: 0;
    transform: translateY(30px);
}

.feature-item.visible {
    opacity: 1;
    transform: translateY(0);
}

.feature-item:hover {
    transform: translateY(-5px);
    border-color: rgba(102, 126, 234, 0.3);
    box-shadow: 0 15px 40px rgba(0, 0, 0, 0.3);
}

.feature-icon {
    flex-shrink: 0;
    width: 60px;
    height: 60px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--primary-gradient);
    border-radius: 16px;
    color: white;
}

.feature-content h3 {
    font-size: 1.3rem;
    margin-bottom: 0.5rem;
}

.feature-content p {
    color: var(--text-secondary);
    line-height: 1.6;
}

/* ===== 联系我们 ===== */
.contact {
    padding: 100px 5%;
}

.contact-content {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
    max-width: 1200px;
    margin: 0 auto;
    align-items: center;
}

.contact-info h2 {
    font-size: clamp(2rem, 5vw, 3rem);
    font-weight: 800;
    margin-bottom: 1rem;
}

.contact-info > p {
    font-size: 1.2rem;
    color: var(--text-secondary);
    margin-bottom: 2.5rem;
}

.contact-item {
    display: flex;
    align-items: center;
    gap: 1.5rem;
    padding: 1.5rem;
    background: var(--card-bg);
    backdrop-filter: blur(20px);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 16px;
    margin-bottom: 1rem;
    transition: all var(--transition-speed) ease;
}

.contact-item:hover {
    transform: translateX(10px);
    border-color: rgba(102, 126, 234, 0.3);
}

.contact-icon {
    font-size: 2.5rem;
    flex-shrink: 0;
}

.contact-text {
    display: flex;
    flex-direction: column;
    gap: 0.3rem;
}

.contact-text strong {
    font-size: 1.1rem;
}

.contact-text span {
    color: var(--text-secondary);
}

.contact-visual {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 1.5rem;
    position: relative;
}

.floating-card {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.8rem;
    padding: 2rem 1.5rem;
    background: var(--card-bg);
    backdrop-filter: blur(20px);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 20px;
    text-align: center;
    font-size: 1.1rem;
    font-weight: 600;
    animation: float 6s ease-in-out infinite;
}

.floating-card span:first-child {
    font-size: 3rem;
}

.card-a {
    grid-column: 1;
    grid-row: 1;
    animation-delay: 0s;
}

.card-b {
    grid-column: 2;
    grid-row: 1;
    animation-delay: -2s;
}

.card-c {
    grid-column: 1 / -1;
    grid-row: 2;
    animation-delay: -4s;
}

/* ===== 页脚 ===== */
.footer {
    padding: 2rem 5%;
    text-align: center;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    background: rgba(15, 15, 26, 0.8);
}

.footer-content p {
    color: var(--text-secondary);
    margin-bottom: 0.5rem;
}

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

@keyframes pulse {
    0%, 100% {
        transform: scale(1);
    }
    50% {
        transform: scale(1.05);
    }
}

/* ===== 响应式设计 ===== */
@media (max-width: 968px) {
    .nav-menu {
        position: fixed;
        top: 0;
        right: -100%;
        width: 80%;
        max-width: 300px;
        height: 100vh;
        background: rgba(15, 15, 26, 0.98);
        flex-direction: column;
        padding: 80px 2rem;
        transition: right var(--transition-speed) ease;
        backdrop-filter: blur(20px);
    }

    .nav-menu.active {
        right: 0;
    }

    .hamburger {
        display: flex;
    }

    .hamburger.active span:nth-child(1) {
        transform: rotate(45deg) translate(8px, 8px);
    }

    .hamburger.active span:nth-child(2) {
        opacity: 0;
    }

    .hamburger.active span:nth-child(3) {
        transform: rotate(-45deg) translate(7px, -7px);
    }

    .contact-content {
        grid-template-columns: 1fr;
    }

    .contact-visual {
        order: -1;
    }
}

@media (max-width: 640px) {
    .hero-title {
        font-size: 2rem;
    }

    .hero-subtitle {
        font-size: 1rem;
    }

    .hero-buttons {
        flex-direction: column;
        width: 100%;
    }

    .btn {
        width: 100%;
        justify-content: center;
    }

    .stats-container {
        grid-template-columns: 1fr 1fr;
    }

    .section-title {
        flex-direction: column;
        gap: 0.5rem;
    }

    .title-number {
        font-size: 3rem;
    }

    .tutorials-grid,
    .features-list {
        grid-template-columns: 1fr;
    }

    .contact-visual {
        grid-template-columns: 1fr;
    }
}