/* ============================================
   CSS Variables & Reset
   ============================================ */
:root {
    --primary-color: #6366f1;
    --primary-dark: #4f46e5;
    --primary-light: #818cf8;
    --secondary-color: #8b5cf6;
    --accent-color: #ec4899;
    --success-color: #10b981;
    --text-primary: #1f2937;
    --text-secondary: #6b7280;
    --text-light: #9ca3af;
    --bg-primary: #ffffff;
    --bg-secondary: #f9fafb;
    --bg-tertiary: #f3f4f6;
    --border-color: #e5e7eb;
    --shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
    --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
    --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1);
    --shadow-xl: 0 20px 25px -5px rgba(0, 0, 0, 0.1);
    --gradient-primary: linear-gradient(135deg, #6366f1 0%, #8b5cf6 100%);
    --gradient-accent: linear-gradient(135deg, #ec4899 0%, #f97316 100%);
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', 'PingFang SC', 'Hiragino Sans GB', 
                 'Microsoft YaHei', 'Helvetica Neue', Helvetica, Arial, sans-serif;
    line-height: 1.6;
    color: var(--text-primary);
    background-color: var(--bg-primary);
    overflow-x: hidden;
}

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

/* ============================================
   Navigation
   ============================================ */
.navbar {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    border-bottom: 1px solid var(--border-color);
    z-index: 1000;
    transition: all 0.3s ease;
}

.navbar .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1rem 2rem;
}

.nav-brand .logo {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--primary-color);
}

.nav-menu {
    display: flex;
    list-style: none;
    gap: 2rem;
    align-items: center;
}

.nav-menu a {
    text-decoration: none;
    color: var(--text-secondary);
    font-weight: 500;
    transition: color 0.3s ease;
}

.nav-menu a:hover {
    color: var(--primary-color);
}

.nav-cta {
    padding: 0.5rem 1.5rem;
    background: var(--gradient-primary);
    color: white !important;
    border-radius: 0.5rem;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.nav-cta:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-lg);
}

/* ============================================
   Hero Section
   ============================================ */
.hero {
    padding: 8rem 0 6rem;
    background: linear-gradient(135deg, #f9fafb 0%, #f3f4f6 100%);
    position: relative;
    overflow: hidden;
}

.hero::before {
    content: '';
    position: absolute;
    top: -50%;
    right: -50%;
    width: 100%;
    height: 100%;
    background: radial-gradient(circle, rgba(99, 102, 241, 0.1) 0%, transparent 70%);
    animation: pulse 8s ease-in-out infinite;
}

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

.hero .container {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
    align-items: center;
    position: relative;
    z-index: 1;
}

.hero-content {
    animation: fadeInLeft 1s ease-out;
}

@keyframes fadeInLeft {
    from {
        opacity: 0;
        transform: translateX(-30px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

.hero-title {
    font-size: 3.5rem;
    font-weight: 800;
    line-height: 1.2;
    margin-bottom: 1.5rem;
    color: var(--text-primary);
}

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

.hero-description {
    font-size: 1.25rem;
    color: var(--text-secondary);
    margin-bottom: 2rem;
    line-height: 1.8;
}

.hero-buttons {
    display: flex;
    gap: 1rem;
}

.btn {
    padding: 0.875rem 2rem;
    border-radius: 0.5rem;
    text-decoration: none;
    font-weight: 600;
    transition: all 0.3s ease;
    display: inline-block;
    border: none;
    cursor: pointer;
    font-size: 1rem;
}

.btn-primary {
    background: var(--gradient-primary);
    color: white;
    box-shadow: var(--shadow-md);
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-xl);
}

.btn-secondary {
    background: white;
    color: var(--primary-color);
    border: 2px solid var(--primary-color);
}

.btn-secondary:hover {
    background: var(--primary-color);
    color: white;
}

.hero-visual {
    animation: fadeInRight 1s ease-out;
}

@keyframes fadeInRight {
    from {
        opacity: 0;
        transform: translateX(30px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

.card-3d {
    perspective: 1000px;
}

.card-content {
    transform-style: preserve-3d;
    transition: transform 0.6s ease;
}

.card-3d:hover .card-content {
    transform: rotateY(5deg) rotateX(5deg);
}

.browser-mockup {
    background: white;
    border-radius: 1rem;
    box-shadow: var(--shadow-xl);
    overflow: hidden;
}

.browser-header {
    background: #f3f4f6;
    padding: 1rem;
    display: flex;
    gap: 0.5rem;
}

.dot {
    width: 12px;
    height: 12px;
    border-radius: 50%;
    background: #d1d5db;
}

.browser-body {
    padding: 4rem 2rem;
    background: linear-gradient(135deg, #fafafa 0%, #f0f0f0 100%);
}

.data-flow {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 1rem;
    font-size: 2rem;
    animation: flowAnimation 2s ease-in-out infinite;
}

@keyframes flowAnimation {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.6; }
}

.flow-icon {
    animation: bounce 1s ease-in-out infinite;
}

.flow-icon:nth-child(1) { animation-delay: 0s; }
.flow-icon:nth-child(3) { animation-delay: 0.2s; }
.flow-icon:nth-child(5) { animation-delay: 0.4s; }

@keyframes bounce {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-10px); }
}

.arrow {
    color: var(--primary-color);
    font-weight: bold;
}

/* ============================================
   Section Styles
   ============================================ */
section {
    padding: 6rem 0;
}

.section-title {
    font-size: 2.5rem;
    font-weight: 700;
    text-align: center;
    margin-bottom: 1rem;
    color: var(--text-primary);
}

.section-subtitle {
    font-size: 1.25rem;
    text-align: center;
    color: var(--text-secondary);
    margin-bottom: 4rem;
}

/* ============================================
   Features Section
   ============================================ */
.features {
    background: white;
}

.features-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
    gap: 2rem;
}

.feature-card {
    background: var(--bg-secondary);
    padding: 2rem;
    border-radius: 1rem;
    border: 1px solid var(--border-color);
    transition: all 0.3s ease;
}

.feature-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-lg);
    border-color: var(--primary-light);
}

.feature-icon {
    font-size: 3rem;
    margin-bottom: 1rem;
}

.feature-card h3 {
    font-size: 1.5rem;
    font-weight: 700;
    margin-bottom: 1rem;
    color: var(--text-primary);
}

.feature-card p {
    color: var(--text-secondary);
    margin-bottom: 1rem;
    line-height: 1.7;
}

.feature-list {
    list-style: none;
    padding: 0;
}

.feature-list li {
    padding: 0.5rem 0;
    color: var(--text-secondary);
    position: relative;
    padding-left: 1.5rem;
}

.feature-list li::before {
    content: '✓';
    position: absolute;
    left: 0;
    color: var(--success-color);
    font-weight: bold;
}

/* ============================================
   How It Works Section
   ============================================ */
.how-it-works {
    background: linear-gradient(135deg, #f9fafb 0%, #ffffff 100%);
}

.workflow-diagram {
    display: flex;
    align-items: center;
    justify-content: center;
    flex-wrap: wrap;
    gap: 1rem;
    margin-bottom: 3rem;
}

.workflow-step {
    display: flex;
    flex-direction: column;
    align-items: center;
    max-width: 150px;
}

.step-number {
    width: 60px;
    height: 60px;
    background: var(--gradient-primary);
    color: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    font-weight: 700;
    margin-bottom: 1rem;
    box-shadow: var(--shadow-md);
}

.step-content h3 {
    font-size: 1.125rem;
    font-weight: 600;
    margin-bottom: 0.5rem;
    text-align: center;
}

.step-content p {
    font-size: 0.875rem;
    color: var(--text-secondary);
    text-align: center;
}

.workflow-arrow {
    font-size: 2rem;
    color: var(--primary-color);
    font-weight: bold;
}

.data-flow-visual {
    background: var(--text-primary);
    padding: 2rem;
    border-radius: 1rem;
    margin-top: 3rem;
}

.flow-code {
    display: block;
    color: #10b981;
    font-family: 'Monaco', 'Courier New', monospace;
    font-size: 1rem;
    text-align: center;
    white-space: pre-wrap;
    word-break: break-word;
}

/* ============================================
   Architecture Section
   ============================================ */
.architecture {
    background: white;
}

.architecture-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
}

.arch-card {
    background: linear-gradient(135deg, #fafafa 0%, #f5f5f5 100%);
    padding: 2rem;
    border-radius: 1rem;
    border: 1px solid var(--border-color);
}

.arch-card h3 {
    font-size: 1.5rem;
    font-weight: 700;
    margin-bottom: 1.5rem;
    color: var(--text-primary);
}

.arch-card ul {
    list-style: none;
    padding: 0;
}

.arch-card li {
    padding: 0.75rem 0;
    color: var(--text-secondary);
    border-bottom: 1px solid var(--border-color);
}

.arch-card li:last-child {
    border-bottom: none;
}

.arch-card strong {
    color: var(--primary-color);
}

/* ============================================
   Waitlist Section
   ============================================ */
.waitlist {
    background: linear-gradient(135deg, #6366f1 0%, #8b5cf6 100%);
    color: white;
}

.waitlist .section-title,
.waitlist .section-subtitle {
    color: white;
}

.waitlist-content {
    max-width: 600px;
    margin: 0 auto;
}

.waitlist-form {
    margin-top: 2rem;
}

.form-group {
    display: flex;
    gap: 1rem;
    margin-bottom: 1rem;
}

.email-input {
    flex: 1;
    padding: 1rem 1.5rem;
    border: 2px solid rgba(255, 255, 255, 0.3);
    border-radius: 0.5rem;
    font-size: 1rem;
    background: rgba(255, 255, 255, 0.1);
    color: white;
    backdrop-filter: blur(10px);
    transition: all 0.3s ease;
}

.email-input::placeholder {
    color: rgba(255, 255, 255, 0.7);
}

.email-input:focus {
    outline: none;
    border-color: white;
    background: rgba(255, 255, 255, 0.2);
}

.btn-large {
    padding: 1rem 2.5rem;
    font-size: 1rem;
    white-space: nowrap;
}

.waitlist-form .btn-primary {
    background: white;
    color: var(--primary-color);
}

.waitlist-form .btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.2);
}

.btn-loading {
    display: none;
}

.waitlist-form.loading .btn-text {
    display: none;
}

.waitlist-form.loading .btn-loading {
    display: inline;
}

.form-hint {
    text-align: center;
    font-size: 0.875rem;
    color: rgba(255, 255, 255, 0.8);
}

.success-message {
    text-align: center;
    padding: 3rem;
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(10px);
    border-radius: 1rem;
    margin-top: 2rem;
}

.success-message.hidden {
    display: none;
}

.success-icon {
    width: 80px;
    height: 80px;
    background: var(--success-color);
    color: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 3rem;
    margin: 0 auto 1.5rem;
    animation: scaleIn 0.5s ease-out;
}

@keyframes scaleIn {
    from {
        transform: scale(0);
        opacity: 0;
    }
    to {
        transform: scale(1);
        opacity: 1;
    }
}

.success-message h3 {
    font-size: 2rem;
    margin-bottom: 1rem;
}

.success-message p {
    font-size: 1.125rem;
    color: rgba(255, 255, 255, 0.9);
}

/* ============================================
   Footer
   ============================================ */
.footer {
    background: var(--text-primary);
    color: white;
    padding: 4rem 0 2rem;
}

.footer-content {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr 1fr;
    gap: 3rem;
    margin-bottom: 3rem;
}

.footer-brand .logo {
    font-size: 1.5rem;
    font-weight: 700;
    color: white;
    display: block;
    margin-bottom: 1rem;
}

.footer-brand p {
    color: var(--text-light);
}

.footer-column h4 {
    font-size: 1.125rem;
    font-weight: 600;
    margin-bottom: 1rem;
}

.footer-column ul {
    list-style: none;
    padding: 0;
}

.footer-column li {
    margin-bottom: 0.75rem;
}

.footer-column a {
    color: var(--text-light);
    text-decoration: none;
    transition: color 0.3s ease;
}

.footer-column a:hover {
    color: white;
}

.footer-bottom {
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    padding-top: 2rem;
    text-align: center;
    color: var(--text-light);
}

/* ============================================
   Responsive Design
   ============================================ */
@media (max-width: 968px) {
    .hero .container {
        grid-template-columns: 1fr;
        text-align: center;
    }

    .hero-buttons {
        justify-content: center;
    }

    .hero-visual {
        order: -1;
        max-width: 500px;
        margin: 0 auto;
    }

    .hero-title {
        font-size: 2.5rem;
    }

    .nav-menu {
        gap: 1rem;
        font-size: 0.875rem;
    }

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

    .workflow-diagram {
        flex-direction: column;
    }

    .workflow-arrow {
        transform: rotate(90deg);
    }

    .footer-content {
        grid-template-columns: 1fr;
        gap: 2rem;
    }

    .form-group {
        flex-direction: column;
    }
}

@media (max-width: 640px) {
    .container {
        padding: 0 1rem;
    }

    .hero {
        padding: 6rem 0 4rem;
    }

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

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

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

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

    section {
        padding: 4rem 0;
    }

    .nav-menu {
        display: none;
    }

    .navbar .container {
        justify-content: center;
    }
}

