/* ===== Reset & Base ===== */
*,
*::before,
*::after {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    --bg: #0a0a0f;
    --bg-elevated: #111118;
    --bg-card: rgba(255, 255, 255, 0.03);
    --bg-card-hover: rgba(255, 255, 255, 0.06);
    --border: rgba(255, 255, 255, 0.08);
    --border-hover: rgba(255, 255, 255, 0.15);
    --text: #e8ecf1;
    --text-secondary: #8b93a0;
    --text-muted: #5c6370;
    --accent: #4d7cfe;
    --accent-light: rgba(77, 124, 254, 0.15);
    --accent-glow: rgba(77, 124, 254, 0.35);
    --radius: 14px;
    --radius-sm: 10px;
    --transition: 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    --container: 1120px;
}

html {
    scroll-behavior: smooth;
    font-size: 16px;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", sans-serif;
    color: var(--text);
    background: var(--bg);
    line-height: 1.7;
    overflow-x: hidden;
    -webkit-font-smoothing: antialiased;
}

.container {
    max-width: var(--container);
    margin: 0 auto;
    padding: 0 24px;
}

a {
    text-decoration: none;
    color: inherit;
}

img {
    max-width: 100%;
    display: block;
}

/* ===== Header ===== */
.header {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 1000;
    background: transparent;
    border-bottom: 1px solid transparent;
    transition: var(--transition);
}

.header.scrolled {
    background: rgba(10, 10, 15, 0.8);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border-bottom-color: var(--border);
}

.header .container {
    max-width: none;
}

.header-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    height: 64px;
}

.logo-wrap {
    display: flex;
    align-items: center;
    gap: 10px;
}

.logo-img {
    width: 42px;
    height: 42px;
    object-fit: contain;
}

.logo-text {
    font-size: 1.2rem;
    font-weight: 700;
    color: var(--text);
    letter-spacing: 0.5px;
}

.nav {
    display: flex;
    align-items: center;
    gap: 4px;
}

.nav-link {
    padding: 7px 16px;
    font-size: 0.9rem;
    font-weight: 500;
    color: var(--text-secondary);
    border-radius: 50px;
    transition: var(--transition);
    margin: 0 8px;
}

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

.menu-toggle {
    display: none;
    flex-direction: column;
    justify-content: center;
    gap: 5px;
    width: 36px;
    height: 36px;
    padding: 6px;
    border: none;
    background: none;
    cursor: pointer;
}

.menu-toggle span {
    display: block;
    width: 100%;
    height: 2px;
    background: var(--text);
    border-radius: 1px;
    transition: var(--transition);
}

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

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

.menu-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;
    text-align: center;
    overflow: hidden;
    padding: 120px 0 80px;
}

.hero-bg {
    position: absolute;
    inset: 0;
    background:
        radial-gradient(ellipse 80% 60% at 50% -10%, rgba(77, 124, 254, 0.3) 0%, transparent 60%),
        radial-gradient(ellipse 50% 50% at 80% 80%, rgba(77, 124, 254, 0.2) 0%, transparent 60%),
        radial-gradient(ellipse 50% 50% at 20% 70%, rgba(77, 124, 254, 0.16) 0%, transparent 60%);
}

.hero-glow {
    position: absolute;
    border-radius: 50%;
    filter: blur(120px);
    opacity: 0.5;
}

.hero-glow--1 {
    width: 600px;
    height: 600px;
    background: rgba(77, 124, 254, 0.22);
    top: -300px;
    left: 50%;
    transform: translateX(-50%);
    animation: heroPulse 8s ease-in-out infinite;
}

.hero-glow--2 {
    width: 400px;
    height: 400px;
    background: rgba(77, 124, 254, 0.18);
    bottom: -100px;
    right: -100px;
    animation: heroPulse 10s ease-in-out 3s infinite;
}

@keyframes heroPulse {
    0%, 100% { transform: translateX(-50%) scale(1); opacity: 0.5; }
    50% { transform: translateX(-50%) scale(1.2); opacity: 0.7; }
}

.hero-particles {
    position: absolute;
    inset: 0;
    z-index: 0;
    pointer-events: none;
}

.hero-inner {
    position: relative;
    z-index: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    max-width: 720px;
}

.hero-title {
    font-size: 3.2rem;
    font-weight: 800;
    color: var(--text);
    line-height: 1.25;
    letter-spacing: -0.02em;
    margin-bottom: 20px;
    animation: fadeInUp 0.9s ease;
    white-space: nowrap;
}

.hero-desc {
    font-size: 1.35rem;
    color: #c8d2e0;
    margin-bottom: 40px;
    line-height: 1.7;
    animation: fadeInUp 0.9s ease 0.15s both;
    white-space: nowrap;
}

.hero-actions {
    display: flex;
    gap: 16px;
    animation: fadeInUp 0.9s ease 0.3s both;
}

.btn-primary {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 13px 32px;
    background: var(--accent);
    color: #fff;
    font-size: 0.95rem;
    font-weight: 600;
    border-radius: 50px;
    transition: var(--transition);
    border: none;
    cursor: pointer;
}

.btn-primary:hover {
    background: #3d6af0;
    transform: translateY(-2px);
    box-shadow: 0 8px 28px var(--accent-glow);
}

.btn-outline {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 13px 32px;
    background: transparent;
    color: var(--text);
    font-size: 0.95rem;
    font-weight: 600;
    border-radius: 50px;
    border: 1px solid var(--border);
    transition: var(--transition);
    cursor: pointer;
}

.btn-outline:hover {
    border-color: var(--border-hover);
    background: rgba(255, 255, 255, 0.04);
    transform: translateY(-2px);
}

/* ===== Section Common ===== */
section {
    padding: 100px 0;
}

.section-header {
    text-align: center;
    margin-bottom: 60px;
}

.section-title {
    font-size: 2.2rem;
    font-weight: 800;
    color: var(--text);
    margin-bottom: 8px;
    letter-spacing: -0.01em;
}

.section-subtitle {
    font-size: 0.8rem;
    color: var(--accent);
    font-weight: 600;
    letter-spacing: 4px;
    text-transform: uppercase;
    margin-bottom: 18px;
}

.section-divider {
    width: 44px;
    height: 3px;
    background: var(--accent);
    border-radius: 2px;
    margin: 0 auto;
    opacity: 0.6;
}

/* ===== About ===== */
.about {
    background: var(--bg-elevated);
}

.about-content {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 24px;
}

.about-card {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 42px 30px;
    text-align: center;
    transition: var(--transition);
    position: relative;
}

.about-card:hover {
    background: var(--bg-card-hover);
    border-color: var(--border-hover);
    transform: translateY(-4px);
    box-shadow: 0 20px 48px rgba(0, 0, 0, 0.3);
}

.about-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 72px;
    height: 72px;
    border-radius: 18px;
    background: var(--accent-light);
    color: var(--accent);
    margin-bottom: 22px;
    transition: var(--transition);
}

.about-card:hover .about-icon {
    background: var(--accent);
    color: #fff;
    transform: scale(1.06);
    box-shadow: 0 8px 28px var(--accent-glow);
}

.about-card h3 {
    font-size: 1.15rem;
    font-weight: 700;
    margin-bottom: 14px;
    color: var(--text);
}

.about-card p {
    font-size: 0.93rem;
    color: var(--text-secondary);
    line-height: 1.9;
    text-align: left;
}

/* ===== Services ===== */
.services {
    background: var(--bg);
}

.services-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 24px;
}

.service-card {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 44px 30px;
    text-align: center;
    transition: var(--transition);
    position: relative;
}

.service-card:hover {
    background: var(--bg-card-hover);
    border-color: var(--border-hover);
    transform: translateY(-4px);
    box-shadow: 0 20px 48px rgba(0, 0, 0, 0.3);
}

.service-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 76px;
    height: 76px;
    border-radius: 20px;
    background: var(--accent-light);
    color: var(--accent);
    margin-bottom: 22px;
    transition: var(--transition);
}

.service-card:hover .service-icon {
    background: var(--accent);
    color: #fff;
    transform: scale(1.06);
    box-shadow: 0 8px 28px var(--accent-glow);
}

.service-card h3 {
    font-size: 1.2rem;
    font-weight: 700;
    margin-bottom: 14px;
    color: var(--text);
}

.service-card p {
    font-size: 0.93rem;
    color: var(--text-secondary);
    line-height: 1.9;
    text-align: left;
}

/* ===== Contact ===== */
.contact {
    background: var(--bg-elevated);
}

.contact-content {
    max-width: 560px;
    margin: 0 auto;
}

.contact-info {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.contact-item {
    display: flex;
    align-items: flex-start;
    gap: 16px;
    padding: 22px 26px;
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    transition: var(--transition);
}

.contact-item:hover {
    border-color: var(--border-hover);
    background: var(--bg-card-hover);
}

.contact-icon {
    flex-shrink: 0;
    color: var(--accent);
    margin-top: 2px;
}

.contact-item h4 {
    font-size: 0.95rem;
    font-weight: 700;
    margin-bottom: 4px;
    color: var(--text);
}

.contact-item p {
    color: var(--text-secondary);
    font-size: 0.9rem;
}

/* ===== Footer ===== */
.footer {
    background: #06060a;
    border-top: 1px solid var(--border);
    padding: 40px 0;
    text-align: center;
}

.footer-inner {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 10px;
}

.footer-brand {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 4px;
}

.footer-logo {
    width: 28px;
    height: 28px;
    object-fit: contain;
}

.footer-brand span {
    font-size: 1.05rem;
    font-weight: 700;
    color: var(--text);
}

.footer-copy {
    font-size: 0.85rem;
    color: var(--text-muted);
}

.footer-icp {
    font-size: 0.8rem;
    color: var(--text-muted);
}

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

.fade-in {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 0.7s ease, transform 0.7s ease;
}

.fade-in.visible {
    opacity: 1;
    transform: translateY(0);
}

/* ===== Hero Title Responsive ===== */
@media (max-width: 768px) {
    .hero-title br {
        display: block;
    }
}

/* ===== Mobile ===== */
@media (max-width: 768px) {
    .nav {
        position: fixed;
        top: 64px;
        left: 0;
        right: 0;
        background: rgba(10, 10, 15, 0.96);
        backdrop-filter: blur(16px);
        flex-direction: column;
        padding: 16px 24px;
        gap: 4px;
        border-bottom: 1px solid var(--border);
        transform: translateY(-120%);
        opacity: 0;
        transition: var(--transition);
        pointer-events: none;
    }

    .nav.open {
        transform: translateY(0);
        opacity: 1;
        pointer-events: auto;
    }

    .nav-link {
        width: 100%;
        padding: 12px 16px;
        text-align: center;
        font-size: 1rem;
    }

    .menu-toggle {
        display: flex;
    }

    .hero {
        min-height: auto;
        padding: 140px 0 80px;
    }

    .hero-title {
        font-size: 2rem;
        white-space: normal;
    }

    .hero-desc {
        font-size: 1rem;
        white-space: normal;
        max-width: 100%;
    }

    .hero-actions {
        flex-direction: column;
        width: 100%;
        max-width: 280px;
    }

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

    .about-content,
    .services-grid {
        grid-template-columns: 1fr;
    }

    .about-card,
    .service-card {
        padding: 32px 24px;
    }

    section {
        padding: 64px 0;
    }

    .section-title {
        font-size: 1.6rem;
    }

    .section-header {
        margin-bottom: 40px;
    }
}

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