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

:root {
    --blue-50: #eff6ff;
    --blue-100: #dbeafe;
    --blue-200: #bfdbfe;
    --blue-300: #93c5fd;
    --blue-400: #60a5fa;
    --blue-500: #3b82f6;
    --blue-600: #2563eb;
    --blue-700: #1d4ed8;
    --blue-800: #1e40af;
    --blue-900: #1e3a8a;

    --white: #ffffff;
    --gray-50: #f8fafc;
    --gray-100: #f1f5f9;
    --gray-200: #e2e8f0;
    --gray-300: #cbd5e1;
    --gray-400: #94a3b8;
    --gray-500: #64748b;
    --gray-600: #475569;
    --gray-700: #334155;
    --gray-800: #1e293b;
    --gray-900: #0f172a;

    --green-500: #22c55e;
    --red-500: #ef4444;
    --yellow-500: #eab308;
    --purple-500: #a855f7;
    --pink-500: #ec4899;
    --cyan-500: #06b6d4;
    --orange-500: #f97316;
    --teal-500: #14b8a6;

    --font-sans: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    --font-mono: 'JetBrains Mono', 'Fira Code', 'Cascadia Code', monospace;

    --shadow-sm: 0 1px 2px rgba(0,0,0,0.05);
    --shadow-md: 0 4px 6px -1px rgba(0,0,0,0.07), 0 2px 4px -2px rgba(0,0,0,0.05);
    --shadow-lg: 0 10px 15px -3px rgba(0,0,0,0.08), 0 4px 6px -4px rgba(0,0,0,0.04);
    --shadow-xl: 0 20px 25px -5px rgba(0,0,0,0.08), 0 8px 10px -6px rgba(0,0,0,0.04);
    --shadow-2xl: 0 25px 50px -12px rgba(0,0,0,0.15);
    --shadow-blue: 0 4px 14px rgba(59,130,246,0.35);

    --radius-sm: 6px;
    --radius-md: 10px;
    --radius-lg: 16px;
    --radius-xl: 24px;
    --radius-full: 9999px;
}

html {
    scroll-behavior: smooth;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

body {
    font-family: var(--font-sans);
    color: var(--gray-800);
    background: var(--white);
    line-height: 1.6;
    overflow-x: hidden;
    transition: background-color 0.4s ease, color 0.4s ease;
}

a {
    text-decoration: none;
    color: inherit;
    transition: color 0.2s;
}

img { max-width: 100%; height: auto; }

*,
*::before,
*::after {
    transition: background-color 0.4s ease, border-color 0.4s ease, box-shadow 0.4s ease, color 0.3s ease;
}

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

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

@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

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

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

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

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

[data-animate] {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 0.7s cubic-bezier(0.16, 1, 0.3, 1), 
                transform 0.7s cubic-bezier(0.16, 1, 0.3, 1);
}

[data-animate].visible {
    opacity: 1;
    transform: translateY(0);
}

/* ===== GRADIENT TEXT ===== */
.gradient-text {
    background: linear-gradient(135deg, var(--blue-600), var(--blue-400), var(--cyan-500));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

/* ===== NAVBAR ===== */
.navbar {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 1000;
    padding: 16px 0;
    transition: all 0.3s ease;
    background: rgba(255,255,255,0);
}

.navbar.scrolled {
    background: rgba(255,255,255,0.85);
    backdrop-filter: blur(20px) saturate(180%);
    -webkit-backdrop-filter: blur(20px) saturate(180%);
    border-bottom: 1px solid rgba(0,0,0,0.06);
    padding: 10px 0;
}

.nav-container {
    display: flex;
    align-items: center;
    gap: 16px;
    position: relative;
}

.nav-logo {
    display: flex;
    align-items: center;
    gap: 10px;
    font-weight: 700;
    font-size: 1.15rem;
    color: var(--gray-900);
    margin-right: auto;
}

.logo-icon {
    display: flex;
    width: 32px;
    height: 32px;
}

.logo-accent {
    color: var(--blue-600);
}

.nav-links {
    display: flex;
    align-items: center;
    gap: 24px;
    position: absolute;
    left: 50%;
    transform: translateX(-50%);
    white-space: nowrap;
}

.nav-links a {
    font-size: 0.875rem;
}

.nav-links a {
    font-weight: 500;
    color: var(--gray-600);
    transition: color 0.2s;
    position: relative;
}

.nav-links a:hover {
    color: var(--blue-600);
}

.nav-links a::after {
    content: '';
    position: absolute;
    bottom: -4px;
    left: 0;
    width: 0;
    height: 2px;
    background: var(--blue-600);
    transition: width 0.3s;
    border-radius: 1px;
}

.nav-links a:hover::after {
    width: 100%;
}

.nav-cta {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 0.8rem;
    font-weight: 600;
    padding: 7px 14px;
    border-radius: var(--radius-full);
    background: var(--blue-600);
    color: var(--white) !important;
    transition: all 0.2s;
    white-space: nowrap;
    flex-shrink: 0;
}

.nav-cta:hover {
    background: var(--blue-700);
    transform: translateY(-1px);
    box-shadow: var(--shadow-blue);
}

.nav-cta-secondary {
    background: transparent;
    color: var(--gray-700) !important;
    border: 1.5px solid var(--gray-200);
}

.nav-cta-secondary:hover {
    background: var(--gray-50);
    border-color: var(--gray-300);
    box-shadow: var(--shadow-sm);
}

.nav-toggle {
    display: none;
    flex-direction: column;
    gap: 5px;
    background: none;
    border: none;
    cursor: pointer;
    padding: 4px;
}

.nav-toggle span {
    width: 22px;
    height: 2px;
    background: var(--gray-800);
    border-radius: 2px;
    transition: all 0.3s;
}

/* ===== HERO ===== */
.hero {
    position: relative;
    padding: 160px 0 80px;
    overflow: hidden;
    min-height: 100vh;
    display: flex;
    align-items: center;
}

.hero-bg {
    position: absolute;
    inset: 0;
    overflow: hidden;
}

.hero-grid {
    position: absolute;
    inset: 0;
    background-image: 
        linear-gradient(rgba(59,130,246,0.04) 1px, transparent 1px),
        linear-gradient(90deg, rgba(59,130,246,0.04) 1px, transparent 1px);
    background-size: 60px 60px;
    mask-image: radial-gradient(ellipse at 50% 30%, black 20%, transparent 70%);
    -webkit-mask-image: radial-gradient(ellipse at 50% 30%, black 20%, transparent 70%);
}

.hero-glow {
    position: absolute;
    top: -200px;
    left: 50%;
    transform: translateX(-50%);
    width: 900px;
    height: 600px;
    border-radius: 50%;
    background: radial-gradient(circle, rgba(59,130,246,0.1) 0%, rgba(59,130,246,0.03) 40%, transparent 70%);
    pointer-events: none;
}

.hero-mouse-glow {
    position: absolute;
    width: 600px;
    height: 600px;
    border-radius: 50%;
    pointer-events: none;
    opacity: 0;
    transition: opacity 0.3s ease;
    transform: translate(-50%, -50%);
    background: radial-gradient(
        circle,
        rgba(59, 130, 246, 0.15) 0%,
        rgba(99, 102, 241, 0.08) 25%,
        rgba(139, 92, 246, 0.04) 45%,
        transparent 70%
    );
    mix-blend-mode: screen;
    z-index: 1;
    will-change: left, top;
}

.hero:hover .hero-mouse-glow {
    opacity: 1;
}

[data-theme="dark"] .hero-mouse-glow {
    background: radial-gradient(
        circle,
        rgba(59, 130, 246, 0.25) 0%,
        rgba(99, 102, 241, 0.12) 25%,
        rgba(139, 92, 246, 0.06) 45%,
        transparent 70%
    );
}

.hero-container {
    position: relative;
    text-align: center;
}

.hero-badge {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 6px 16px 6px 12px;
    border-radius: var(--radius-full);
    background: var(--blue-50);
    border: 1px solid var(--blue-200);
    color: var(--blue-700);
    font-size: 0.85rem;
    font-weight: 600;
    margin-bottom: 28px;
}

.badge-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: var(--blue-500);
    animation: pulse 2s infinite;
}

.hero-title {
    font-size: clamp(2.5rem, 6vw, 4.5rem);
    font-weight: 800;
    line-height: 1.1;
    letter-spacing: -0.03em;
    color: var(--gray-900);
    margin-bottom: 24px;
}

.hero-subtitle {
    font-size: clamp(1rem, 2vw, 1.2rem);
    color: var(--gray-500);
    max-width: 640px;
    margin: 0 auto 40px;
    line-height: 1.7;
}

.hero-actions {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 16px;
    margin-bottom: 64px;
}

/* ===== BUTTONS ===== */
.btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    font-family: var(--font-sans);
    font-weight: 600;
    border: none;
    cursor: pointer;
    transition: all 0.25s cubic-bezier(0.16, 1, 0.3, 1);
    border-radius: var(--radius-full);
    white-space: nowrap;
}

.btn-sm {
    padding: 10px 20px;
    font-size: 0.85rem;
}

.btn-lg {
    padding: 14px 28px;
    font-size: 0.95rem;
}

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

.btn-primary:hover {
    background: var(--blue-700);
    transform: translateY(-2px);
    box-shadow: 0 8px 20px rgba(59,130,246,0.4);
}

.btn-outline {
    background: var(--white);
    color: var(--gray-700);
    border: 1.5px solid var(--gray-200);
}

.btn-outline:hover {
    border-color: var(--blue-300);
    color: var(--blue-600);
    transform: translateY(-2px);
    box-shadow: var(--shadow-md);
}

.btn-white {
    background: var(--white);
    color: var(--blue-600);
    font-weight: 600;
}

.btn-white:hover {
    background: var(--blue-50);
    transform: translateY(-2px);
}

/* ===== CODE WINDOW ===== */
.hero-visual {
    max-width: 780px;
    margin: 0 auto;
    perspective: 1200px;
}

.code-window {
    border-radius: var(--radius-lg);
    overflow: hidden;
    box-shadow: var(--shadow-2xl), 0 0 0 1px rgba(0,0,0,0.06);
    background: #1e1e2e;
    transform: rotateX(2deg);
    transition: transform 0.5s cubic-bezier(0.16, 1, 0.3, 1);
}

.code-window:hover {
    transform: rotateX(0deg);
}

.code-window-header {
    display: flex;
    align-items: center;
    padding: 12px 16px;
    background: #181825;
    border-bottom: 1px solid rgba(255,255,255,0.06);
    gap: 12px;
}

.window-dots {
    display: flex;
    gap: 7px;
}

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

.dot.red { background: #ff5f57; }
.dot.yellow { background: #febc2e; }
.dot.green { background: #28c840; }

.window-title {
    flex: 1;
    text-align: center;
    font-size: 0.8rem;
    color: rgba(255,255,255,0.4);
    font-family: var(--font-mono);
}

.window-session {
    display: flex;
    align-items: center;
    gap: 12px;
}

.session-badge {
    font-family: var(--font-mono);
    font-size: 0.75rem;
    font-weight: 600;
    padding: 3px 10px;
    border-radius: var(--radius-full);
    background: rgba(59,130,246,0.15);
    color: var(--blue-400);
}

.session-users {
    display: flex;
    align-items: center;
    gap: 4px;
    font-size: 0.75rem;
    color: rgba(255,255,255,0.4);
}

.user-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    display: inline-block;
}

.code-window-body {
    padding: 16px 0;
    font-family: var(--font-mono);
    font-size: 0.85rem;
    line-height: 1.75;
}

.code-line {
    padding: 0 20px 0 0;
    display: flex;
    align-items: center;
    position: relative;
    min-height: 28px;
}

.code-line.active-line {
    background: rgba(59,130,246,0.08);
}

.code-line.comment-line {
    background: rgba(245,158,11,0.05);
}

.line-num {
    display: inline-block;
    width: 48px;
    text-align: right;
    padding-right: 20px;
    color: rgba(255,255,255,0.2);
    font-size: 0.8rem;
    user-select: none;
    flex-shrink: 0;
}

.code-indent { display: inline-block; width: 24px; }
.code-tag { color: #89b4fa; }
.code-attr { color: #f9e2af; }
.code-string { color: #a6e3a1; }
.code-text { color: #cdd6f4; }
.code-comment { color: #6c7086; font-style: italic; }

.cursor-indicator {
    position: relative;
    display: inline-flex;
    align-items: flex-start;
    margin-left: 4px;
}

.cursor-line {
    width: 2px;
    height: 20px;
    background: var(--cursor-color);
    border-radius: 1px;
    animation: blink 1.2s infinite;
}

.cursor-label {
    position: absolute;
    bottom: 100%;
    left: -4px;
    background: var(--cursor-color);
    color: white;
    font-size: 0.65rem;
    padding: 1px 6px;
    border-radius: 3px 3px 3px 0;
    white-space: nowrap;
    font-family: var(--font-sans);
    font-weight: 600;
}

.inline-comment {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    margin-left: 16px;
    font-size: 0.72rem;
    color: #f9e2af;
    font-family: var(--font-sans);
    opacity: 0.7;
}

/* ===== SECTIONS ===== */
.section-header {
    text-align: center;
    margin-bottom: 64px;
}

.section-label {
    display: inline-block;
    font-size: 0.8rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    color: var(--blue-600);
    margin-bottom: 16px;
}

.section-title {
    font-size: clamp(2rem, 4vw, 3rem);
    font-weight: 800;
    line-height: 1.15;
    letter-spacing: -0.02em;
    color: var(--gray-900);
    margin-bottom: 16px;
}

.section-desc {
    font-size: 1.1rem;
    color: var(--gray-500);
    max-width: 560px;
    margin: 0 auto;
    line-height: 1.7;
}

/* ===== FEATURES ===== */
.features {
    padding: 120px 0;
    background: var(--gray-50);
}

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

.feature-card {
    background: var(--white);
    border: 1px solid var(--gray-200);
    border-radius: var(--radius-lg);
    padding: 32px;
    transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
    position: relative;
    overflow: hidden;
}

.feature-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: linear-gradient(90deg, var(--blue-400), var(--blue-600));
    opacity: 0;
    transition: opacity 0.3s;
}

.feature-card:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-xl);
    border-color: var(--blue-200);
}

.feature-card:hover::before {
    opacity: 1;
}

.feature-card-lg {
    grid-column: span 1;
}

.feature-icon {
    width: 48px;
    height: 48px;
    border-radius: var(--radius-md);
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 20px;
}

.icon-red { background: #fef2f2; color: var(--red-500); }
.icon-blue { background: var(--blue-50); color: var(--blue-500); }
.icon-green { background: #f0fdf4; color: var(--green-500); }
.icon-purple { background: #faf5ff; color: var(--purple-500); }
.icon-yellow { background: #fefce8; color: var(--yellow-500); }
.icon-pink { background: #fdf2f8; color: var(--pink-500); }
.icon-cyan { background: #ecfeff; color: var(--cyan-500); }
.icon-orange { background: #fff7ed; color: var(--orange-500); }
.icon-teal { background: #f0fdfa; color: var(--teal-500); }

.feature-card h3 {
    font-size: 1.1rem;
    font-weight: 700;
    margin-bottom: 8px;
    color: var(--gray-900);
}

.feature-card p {
    font-size: 0.9rem;
    color: var(--gray-500);
    line-height: 1.6;
}

/* ===== HOW IT WORKS ===== */
.how-it-works {
    padding: 120px 0;
}

.steps-grid {
    display: flex;
    align-items: flex-start;
    justify-content: center;
    gap: 0;
    margin-bottom: 80px;
}

.step-card {
    flex: 1;
    max-width: 320px;
    text-align: center;
    padding: 32px 24px;
}

.step-number {
    font-size: 0.85rem;
    font-weight: 800;
    color: var(--blue-400);
    font-family: var(--font-mono);
    margin-bottom: 16px;
}

.step-icon {
    width: 64px;
    height: 64px;
    border-radius: 50%;
    background: var(--blue-50);
    color: var(--blue-600);
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 20px;
    border: 2px solid var(--blue-200);
}

.step-card h3 {
    font-size: 1.15rem;
    font-weight: 700;
    color: var(--gray-900);
    margin-bottom: 12px;
}

.step-card p {
    font-size: 0.9rem;
    color: var(--gray-500);
    line-height: 1.6;
}

.step-connector {
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--blue-300);
    padding-top: 72px;
    flex-shrink: 0;
}

/* ===== ARCHITECTURE ===== */
.architecture-block {
    background: var(--gray-50);
    border: 1px solid var(--gray-200);
    border-radius: var(--radius-xl);
    padding: 48px;
    text-align: center;
}

.arch-title {
    font-size: 1.3rem;
    font-weight: 700;
    color: var(--gray-900);
    margin-bottom: 40px;
}

.arch-diagram {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 24px;
}

.arch-node {
    background: var(--white);
    border: 1.5px solid var(--gray-200);
    border-radius: var(--radius-md);
    padding: 16px 24px;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 4px;
    transition: all 0.3s;
}

.arch-node:hover {
    border-color: var(--blue-300);
    box-shadow: var(--shadow-md);
}

.arch-main {
    border-color: var(--blue-300);
    background: var(--blue-50);
    padding: 20px 40px;
}

.arch-node-icon {
    color: var(--blue-600);
    margin-bottom: 4px;
}

.arch-node-label {
    font-weight: 700;
    font-size: 0.9rem;
    color: var(--gray-800);
}

.arch-node-sub {
    font-size: 0.75rem;
    color: var(--gray-400);
    font-family: var(--font-mono);
}

.arch-connections {
    display: flex;
    gap: 120px;
    position: relative;
}

.arch-connections::before {
    content: '';
    position: absolute;
    top: 0;
    left: 50%;
    transform: translateX(-50%);
    width: calc(100% - 40px);
    height: 1px;
    background: var(--gray-300);
}

.arch-line {
    width: 1px;
    height: 32px;
    background: var(--gray-300);
}

.arch-children {
    display: flex;
    gap: 20px;
}

.arch-child {
    min-width: 140px;
}

.arch-client-line {
    width: 1px;
    height: 24px;
    background: var(--gray-300);
    margin: 0 auto;
}

.arch-clients-row {
    display: flex;
    gap: 20px;
    justify-content: center;
}

.arch-client {
    min-width: 120px;
}

.arch-role {
    font-size: 0.65rem;
    font-weight: 800;
    letter-spacing: 0.08em;
    padding: 2px 10px;
    border-radius: var(--radius-full);
    margin-bottom: 2px;
}

.arch-role.host {
    background: var(--blue-100);
    color: var(--blue-700);
}

.arch-role.viewer {
    background: var(--gray-100);
    color: var(--gray-600);
}

.arch-role.editor {
    background: #dcfce7;
    color: #15803d;
}

/* ===== ROLES ===== */
.roles {
    padding: 120px 0;
    background: var(--gray-50);
}

.roles-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 20px;
}

.role-card {
    background: var(--white);
    border: 1.5px solid var(--gray-200);
    border-radius: var(--radius-lg);
    padding: 32px 24px;
    transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

.role-card:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-xl);
}

.role-host:hover { border-color: var(--blue-300); }
.role-admin:hover { border-color: var(--purple-500); }
.role-editor:hover { border-color: var(--green-500); }
.role-viewer:hover { border-color: var(--gray-400); }

.role-header {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 12px;
}

.role-badge {
    font-size: 0.65rem;
    font-weight: 800;
    letter-spacing: 0.08em;
    padding: 4px 12px;
    border-radius: var(--radius-full);
}

.role-badge.host { background: var(--blue-100); color: var(--blue-700); }
.role-badge.admin { background: #f3e8ff; color: #7c3aed; }
.role-badge.editor-b { background: #dcfce7; color: #15803d; }
.role-badge.viewer-b { background: var(--gray-100); color: var(--gray-600); }

.role-header h3 {
    font-size: 1.15rem;
    font-weight: 700;
    color: var(--gray-900);
}

.role-desc {
    font-size: 0.85rem;
    color: var(--gray-500);
    margin-bottom: 20px;
    line-height: 1.6;
}

.role-perms {
    list-style: none;
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.role-perms li {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 0.85rem;
    font-weight: 500;
}

.perm-yes { color: var(--green-500); }
.perm-no { color: var(--gray-400); }

.perm-note {
    font-size: 0.75rem;
    color: var(--gray-400);
    font-weight: 400;
}

/* ===== CODE RUNNER ===== */
.runner {
    padding: 120px 0;
}

.runner-layout {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 64px;
    align-items: center;
}

.runner-info .section-title {
    text-align: left;
}

.runner-info .section-desc {
    text-align: left;
    margin: 0 0 32px;
}

.runner-langs {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}

.lang-chip {
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 6px 14px;
    border-radius: var(--radius-full);
    background: var(--gray-50);
    border: 1px solid var(--gray-200);
    font-size: 0.8rem;
    font-weight: 600;
    color: var(--gray-700);
    transition: all 0.2s;
}

.lang-chip:hover {
    border-color: var(--blue-300);
    background: var(--blue-50);
}

.lang-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
}

/* ===== TERMINAL ===== */
.terminal-window {
    border-radius: var(--radius-lg);
    overflow: hidden;
    background: #0d1117;
    box-shadow: var(--shadow-2xl);
}

.terminal-header {
    display: flex;
    align-items: center;
    padding: 12px 16px;
    background: #161b22;
    border-bottom: 1px solid rgba(255,255,255,0.06);
    gap: 12px;
}

.terminal-title {
    flex: 1;
    font-size: 0.8rem;
    color: rgba(255,255,255,0.4);
    font-family: var(--font-mono);
}

.terminal-run {
    display: flex;
    align-items: center;
    gap: 6px;
    font-family: var(--font-sans);
    font-size: 0.75rem;
    font-weight: 600;
    padding: 4px 12px;
    border-radius: var(--radius-full);
    background: var(--green-500);
    color: white;
    border: none;
    cursor: pointer;
}

.terminal-body {
    padding: 20px;
    font-family: var(--font-mono);
    font-size: 0.82rem;
    line-height: 1.8;
}

.terminal-line {
    white-space: pre;
}

.terminal-line.prompt { color: #8b949e; }
.terminal-line.stdout { color: #c9d1d9; }
.terminal-line.stdout.success { color: #3fb950; }
.terminal-line.stderr { color: #f97583; }

.terminal-cursor {
    display: inline-block;
    width: 8px;
    height: 16px;
    background: rgba(255,255,255,0.6);
    animation: blink 1s infinite;
    vertical-align: text-bottom;
}

/* ===== TECH STACK ===== */
.tech-stack {
    padding: 120px 0;
    background: var(--gray-50);
}

.tech-grid {
    display: grid;
    grid-template-columns: repeat(6, 1fr);
    gap: 16px;
}

.tech-item {
    background: var(--white);
    border: 1px solid var(--gray-200);
    border-radius: var(--radius-lg);
    padding: 28px 16px;
    text-align: center;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
    transition: all 0.3s;
}

.tech-item:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-lg);
    border-color: var(--blue-200);
}

.tech-icon {
    color: var(--blue-500);
    margin-bottom: 4px;
}

.tech-name {
    font-weight: 700;
    font-size: 0.85rem;
    color: var(--gray-800);
}

.tech-ver {
    font-size: 0.75rem;
    color: var(--gray-400);
    font-family: var(--font-mono);
}

/* ===== GET STARTED ===== */
.get-started {
    padding: 120px 0;
}

.start-steps {
    max-width: 680px;
    margin: 0 auto 48px;
    display: flex;
    flex-direction: column;
    gap: 0;
}

.start-step {
    display: flex;
    gap: 24px;
    padding: 24px 0;
    border-bottom: 1px solid var(--gray-100);
}

.start-step:last-child {
    border-bottom: none;
}

.start-step-num {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: var(--blue-600);
    color: var(--white);
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 800;
    font-size: 0.9rem;
    flex-shrink: 0;
}

.start-step-content h3 {
    font-size: 1.05rem;
    font-weight: 700;
    color: var(--gray-900);
    margin-bottom: 8px;
}

.start-step-content p {
    font-size: 0.9rem;
    color: var(--gray-500);
    line-height: 1.6;
}

kbd {
    display: inline-block;
    padding: 2px 8px;
    border-radius: 4px;
    background: var(--gray-100);
    border: 1px solid var(--gray-200);
    font-family: var(--font-mono);
    font-size: 0.8rem;
    font-weight: 600;
    color: var(--gray-700);
    box-shadow: 0 1px 0 var(--gray-300);
}

.code-block {
    display: flex;
    align-items: center;
    background: var(--gray-900);
    border-radius: var(--radius-md);
    padding: 12px 16px;
    margin-top: 8px;
}

.code-block code {
    flex: 1;
    font-family: var(--font-mono);
    font-size: 0.85rem;
    color: #a6e3a1;
}

.copy-btn {
    background: none;
    border: none;
    color: var(--gray-400);
    cursor: pointer;
    padding: 4px;
    border-radius: 4px;
    transition: all 0.2s;
}

.copy-btn:hover {
    color: var(--white);
    background: rgba(255,255,255,0.1);
}

/* ===== NGROK BLOCK ===== */
.ngrok-block {
    max-width: 680px;
    margin: 0 auto;
    display: flex;
    align-items: flex-start;
    gap: 20px;
    padding: 28px 32px;
    background: var(--blue-50);
    border: 1px solid var(--blue-200);
    border-radius: var(--radius-lg);
}

.ngrok-icon {
    flex-shrink: 0;
    width: 48px;
    height: 48px;
    border-radius: 50%;
    background: var(--white);
    color: var(--blue-600);
    display: flex;
    align-items: center;
    justify-content: center;
}

.ngrok-info h3 {
    font-size: 1.05rem;
    font-weight: 700;
    color: var(--gray-900);
    margin-bottom: 8px;
}

.ngrok-info p {
    font-size: 0.9rem;
    color: var(--gray-600);
    line-height: 1.6;
}

/* ===== CTA ===== */
.cta-section {
    padding: 120px 0;
    background: var(--gray-50);
}

.cta-block {
    text-align: center;
    padding: 80px 48px;
    background: linear-gradient(135deg, var(--blue-600), var(--blue-800));
    border-radius: var(--radius-xl);
    position: relative;
    overflow: hidden;
}

.cta-block::before {
    content: '';
    position: absolute;
    top: -50%;
    right: -20%;
    width: 500px;
    height: 500px;
    border-radius: 50%;
    background: rgba(255,255,255,0.05);
}

.cta-block::after {
    content: '';
    position: absolute;
    bottom: -30%;
    left: -10%;
    width: 300px;
    height: 300px;
    border-radius: 50%;
    background: rgba(255,255,255,0.03);
}

.cta-block h2 {
    font-size: clamp(1.8rem, 3.5vw, 2.5rem);
    font-weight: 800;
    color: var(--white);
    line-height: 1.2;
    margin-bottom: 16px;
    position: relative;
    z-index: 1;
}

.cta-block .gradient-text {
    background: linear-gradient(135deg, #93c5fd, #bfdbfe);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.cta-block p {
    color: rgba(255,255,255,0.7);
    font-size: 1.1rem;
    margin-bottom: 32px;
    position: relative;
    z-index: 1;
}

.cta-actions {
    display: flex;
    justify-content: center;
    gap: 16px;
    position: relative;
    z-index: 1;
}

.cta-actions .btn-primary {
    background: var(--white);
    color: var(--blue-700);
    box-shadow: var(--shadow-lg);
}

.cta-actions .btn-primary:hover {
    background: var(--blue-50);
    box-shadow: var(--shadow-xl);
}

/* ===== FOOTER ===== */
.footer {
    padding: 64px 0 32px;
    border-top: 1px solid var(--gray-200);
}

.footer-content {
    display: grid;
    grid-template-columns: 1.5fr 2fr;
    gap: 64px;
    margin-bottom: 48px;
}

.footer-brand .nav-logo {
    margin-bottom: 16px;
}

.footer-desc {
    font-size: 0.875rem;
    color: var(--gray-500);
    line-height: 1.6;
    max-width: 300px;
}

.footer-links {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 32px;
}

.footer-col h4 {
    font-size: 0.8rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    color: var(--gray-900);
    margin-bottom: 16px;
}

.footer-col a {
    display: block;
    font-size: 0.875rem;
    color: var(--gray-500);
    padding: 4px 0;
    transition: color 0.2s;
}

.footer-col a:hover {
    color: var(--blue-600);
}

.footer-bottom {
    padding-top: 24px;
    border-top: 1px solid var(--gray-100);
}

.footer-bottom p {
    font-size: 0.8rem;
    color: var(--gray-400);
    text-align: center;
}

/* ===== ROADMAP ===== */
.roadmap {
    padding: 120px 0;
}

.roadmap-timeline {
    position: relative;
    max-width: 680px;
    margin: 0 auto 64px;
}

.roadmap-line {
    position: absolute;
    left: 20px;
    top: 0;
    bottom: 0;
    width: 2px;
    background: linear-gradient(to bottom, var(--blue-400), var(--blue-200), var(--gray-200));
    border-radius: 1px;
}

.roadmap-item {
    position: relative;
    display: flex;
    gap: 24px;
    padding-bottom: 32px;
}

.roadmap-item:last-child {
    padding-bottom: 0;
}

.roadmap-dot {
    width: 42px;
    height: 42px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    z-index: 1;
    position: relative;
}

.roadmap-item.done .roadmap-dot {
    background: var(--blue-600);
    color: white;
    box-shadow: 0 0 0 4px var(--blue-100);
}

.roadmap-item.active .roadmap-dot {
    background: var(--white);
    border: 2.5px solid var(--blue-500);
    box-shadow: 0 0 0 4px var(--blue-100);
}

.dot-pulse {
    width: 12px;
    height: 12px;
    border-radius: 50%;
    background: var(--blue-500);
    animation: pulse 2s infinite;
}

.roadmap-item.upcoming .roadmap-dot {
    background: var(--gray-100);
    border: 2px solid var(--gray-300);
}

.roadmap-card {
    flex: 1;
    background: var(--white);
    border: 1px solid var(--gray-200);
    border-radius: var(--radius-lg);
    padding: 24px;
    transition: all 0.3s;
}

.roadmap-card:hover {
    transform: translateX(4px);
    box-shadow: var(--shadow-lg);
}

.roadmap-item.active .roadmap-card {
    border-color: var(--blue-300);
    box-shadow: 0 0 0 1px var(--blue-100), var(--shadow-md);
}

.roadmap-tag {
    display: inline-block;
    font-size: 0.7rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    padding: 3px 10px;
    border-radius: var(--radius-full);
    margin-bottom: 10px;
}

.tag-done {
    background: var(--blue-100);
    color: var(--blue-700);
}

.tag-active {
    background: #dcfce7;
    color: #15803d;
}

.tag-upcoming {
    background: var(--gray-100);
    color: var(--gray-500);
}

.roadmap-card h3 {
    font-size: 1.05rem;
    font-weight: 700;
    color: var(--gray-900);
    margin-bottom: 8px;
}

.roadmap-card p {
    font-size: 0.88rem;
    color: var(--gray-500);
    line-height: 1.6;
}

/* Community Block */
.roadmap-community {
    position: relative;
    max-width: 720px;
    margin: 0 auto;
    border-radius: var(--radius-xl);
    background: linear-gradient(135deg, var(--blue-50), rgba(59,130,246,0.04));
    border: 1px solid var(--blue-200);
    padding: 48px;
    overflow: hidden;
}

.community-glow {
    position: absolute;
    top: -40px;
    right: -40px;
    width: 200px;
    height: 200px;
    border-radius: 50%;
    background: radial-gradient(circle, rgba(59,130,246,0.12) 0%, transparent 70%);
    pointer-events: none;
}

.community-content {
    position: relative;
    text-align: center;
}

.community-icon {
    width: 64px;
    height: 64px;
    border-radius: 50%;
    background: var(--white);
    border: 2px solid var(--blue-200);
    color: var(--blue-500);
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 20px;
    animation: float 4s ease-in-out infinite;
}

.community-content h3 {
    font-size: 1.3rem;
    font-weight: 800;
    color: var(--gray-900);
    margin-bottom: 12px;
}

.community-content p {
    font-size: 0.95rem;
    color: var(--gray-600);
    line-height: 1.7;
    max-width: 540px;
    margin: 0 auto 28px;
}

.community-actions {
    display: flex;
    justify-content: center;
    gap: 12px;
    flex-wrap: wrap;
}

/* ===== LANGUAGE TOGGLE ===== */
.lang-toggle {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    border: 1.5px solid var(--gray-200);
    background: var(--white);
    color: var(--gray-600);
    cursor: pointer;
    transition: all 0.3s ease;
    flex-shrink: 0;
    font-family: var(--font-sans);
    font-size: 0.7rem;
    font-weight: 700;
    letter-spacing: 0.03em;
}

.lang-toggle:hover {
    border-color: var(--blue-300);
    color: var(--blue-600);
    background: var(--blue-50);
}

[data-theme="dark"] .lang-toggle {
    border-color: var(--gray-200);
    background: var(--gray-50);
    color: var(--gray-600);
}

[data-theme="dark"] .lang-toggle:hover {
    border-color: var(--blue-400);
    background: rgba(59,130,246,0.1);
    color: var(--blue-400);
}

/* ===== THEME TOGGLE ===== */
.theme-toggle {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    border: 1.5px solid var(--gray-200);
    background: var(--white);
    color: var(--gray-600);
    cursor: pointer;
    transition: all 0.3s ease;
    flex-shrink: 0;
}

.theme-toggle:hover {
    border-color: var(--blue-300);
    color: var(--blue-600);
    background: var(--blue-50);
    transform: rotate(15deg);
}

.icon-moon { display: none; }
.icon-sun { display: block; }

/* ===== DARK THEME ===== */
[data-theme="dark"] {
    --white: #0f172a;
    --gray-50: #1e293b;
    --gray-100: #1e293b;
    --gray-200: #334155;
    --gray-300: #475569;
    --gray-400: #64748b;
    --gray-500: #94a3b8;
    --gray-600: #cbd5e1;
    --gray-700: #e2e8f0;
    --gray-800: #f1f5f9;
    --gray-900: #f8fafc;

    --blue-50: rgba(59,130,246,0.1);
    --blue-100: rgba(59,130,246,0.15);
    --blue-200: rgba(59,130,246,0.25);

    --shadow-sm: 0 1px 2px rgba(0,0,0,0.3);
    --shadow-md: 0 4px 6px -1px rgba(0,0,0,0.4), 0 2px 4px -2px rgba(0,0,0,0.3);
    --shadow-lg: 0 10px 15px -3px rgba(0,0,0,0.4), 0 4px 6px -4px rgba(0,0,0,0.3);
    --shadow-xl: 0 20px 25px -5px rgba(0,0,0,0.4), 0 8px 10px -6px rgba(0,0,0,0.3);
    --shadow-2xl: 0 25px 50px -12px rgba(0,0,0,0.5);
    --shadow-blue: 0 4px 14px rgba(59,130,246,0.25);
}

[data-theme="dark"] .icon-moon { display: block; }
[data-theme="dark"] .icon-sun { display: none; }

[data-theme="dark"] .theme-toggle {
    border-color: var(--gray-200);
    background: var(--gray-50);
    color: var(--yellow-500);
}

[data-theme="dark"] .theme-toggle:hover {
    border-color: var(--yellow-500);
    background: rgba(234,179,8,0.1);
    color: var(--yellow-500);
}

[data-theme="dark"] .navbar.scrolled {
    background: rgba(15,23,42,0.85);
    border-bottom-color: rgba(255,255,255,0.06);
}

[data-theme="dark"] .hero-grid {
    background-image:
        linear-gradient(rgba(59,130,246,0.06) 1px, transparent 1px),
        linear-gradient(90deg, rgba(59,130,246,0.06) 1px, transparent 1px);
}

[data-theme="dark"] .hero-glow {
    background: radial-gradient(circle, rgba(59,130,246,0.15) 0%, rgba(59,130,246,0.05) 40%, transparent 70%);
}

[data-theme="dark"] .gradient-text {
    background: linear-gradient(135deg, var(--blue-400), var(--blue-300), var(--cyan-500));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

[data-theme="dark"] .feature-card {
    background: #1e293b;
    border-color: #334155;
}

[data-theme="dark"] .feature-card:hover {
    border-color: var(--blue-400);
}

[data-theme="dark"] .icon-red { background: rgba(239,68,68,0.12); }
[data-theme="dark"] .icon-blue { background: rgba(59,130,246,0.12); }
[data-theme="dark"] .icon-green { background: rgba(34,197,94,0.12); }
[data-theme="dark"] .icon-purple { background: rgba(168,85,247,0.12); }
[data-theme="dark"] .icon-yellow { background: rgba(234,179,8,0.12); }
[data-theme="dark"] .icon-pink { background: rgba(236,72,153,0.12); }
[data-theme="dark"] .icon-cyan { background: rgba(6,182,212,0.12); }
[data-theme="dark"] .icon-orange { background: rgba(249,115,22,0.12); }
[data-theme="dark"] .icon-teal { background: rgba(20,184,166,0.12); }

[data-theme="dark"] .step-icon {
    background: rgba(59,130,246,0.12);
    border-color: rgba(59,130,246,0.3);
}

[data-theme="dark"] .architecture-block {
    background: #1e293b;
    border-color: #334155;
}

[data-theme="dark"] .arch-node {
    background: #0f172a;
    border-color: #334155;
}

[data-theme="dark"] .arch-main {
    background: rgba(59,130,246,0.1);
    border-color: rgba(59,130,246,0.3);
}

[data-theme="dark"] .role-card {
    background: #1e293b;
    border-color: #334155;
}

[data-theme="dark"] .role-badge.host { background: rgba(59,130,246,0.15); }
[data-theme="dark"] .role-badge.admin { background: rgba(124,58,237,0.15); }
[data-theme="dark"] .role-badge.editor-b { background: rgba(34,197,94,0.15); }
[data-theme="dark"] .role-badge.viewer-b { background: rgba(100,116,139,0.2); }

[data-theme="dark"] .lang-chip {
    background: #1e293b;
    border-color: #334155;
}

[data-theme="dark"] .lang-chip:hover {
    background: rgba(59,130,246,0.1);
    border-color: rgba(59,130,246,0.3);
}

[data-theme="dark"] .tech-item {
    background: #1e293b;
    border-color: #334155;
}

[data-theme="dark"] .tech-item:hover {
    border-color: rgba(59,130,246,0.4);
}

[data-theme="dark"] .code-block {
    background: #0d1117;
}

[data-theme="dark"] .ngrok-block {
    background: rgba(59,130,246,0.08);
    border-color: rgba(59,130,246,0.2);
}

[data-theme="dark"] .ngrok-icon {
    background: #1e293b;
}

[data-theme="dark"] .cta-block {
    background: linear-gradient(135deg, #1e40af, #1e3a8a);
}

[data-theme="dark"] .footer {
    border-top-color: #334155;
}

[data-theme="dark"] .footer-bottom {
    border-top-color: #1e293b;
}

[data-theme="dark"] .btn-outline {
    background: #1e293b;
    border-color: #334155;
    color: var(--gray-700);
}

[data-theme="dark"] .btn-outline:hover {
    border-color: var(--blue-400);
    background: rgba(59,130,246,0.08);
}

[data-theme="dark"] .nav-cta-secondary {
    background: transparent;
    border-color: #334155;
    color: var(--gray-600) !important;
}

[data-theme="dark"] .nav-cta-secondary:hover {
    background: #1e293b;
    border-color: #475569;
}

[data-theme="dark"] kbd {
    background: #1e293b;
    border-color: #334155;
    box-shadow: 0 1px 0 #475569;
    color: var(--gray-700);
}

[data-theme="dark"] .nav-links {
    background: #0f172a;
}

[data-theme="dark"] .roadmap-card {
    background: #1e293b;
    border-color: #334155;
}

[data-theme="dark"] .roadmap-item.active .roadmap-card {
    border-color: rgba(59,130,246,0.4);
    box-shadow: 0 0 0 1px rgba(59,130,246,0.15), var(--shadow-md);
}

[data-theme="dark"] .roadmap-item.done .roadmap-dot {
    box-shadow: 0 0 0 4px rgba(59,130,246,0.15);
}

[data-theme="dark"] .roadmap-item.active .roadmap-dot {
    background: #1e293b;
    box-shadow: 0 0 0 4px rgba(59,130,246,0.15);
}

[data-theme="dark"] .roadmap-item.upcoming .roadmap-dot {
    background: #334155;
    border-color: #475569;
}

[data-theme="dark"] .tag-done {
    background: rgba(59,130,246,0.15);
    color: var(--blue-400);
}

[data-theme="dark"] .tag-active {
    background: rgba(34,197,94,0.12);
    color: #4ade80;
}

[data-theme="dark"] .tag-upcoming {
    background: #334155;
    color: var(--gray-400);
}

[data-theme="dark"] .stat-card {
    background: #1e293b;
    border-color: #334155;
}

[data-theme="dark"] .stat-card:hover {
    border-color: transparent;
}

[data-theme="dark"] .back-to-top {
    background: var(--blue-600);
    box-shadow: 0 4px 14px rgba(59,130,246,0.3);
}

[data-theme="dark"] .scroll-progress {
    box-shadow: 0 0 15px rgba(59,130,246,0.6);
}

[data-theme="dark"] .particle:nth-child(1) { background: rgba(147,197,253,0.6); }
[data-theme="dark"] .particle:nth-child(2) { background: rgba(6,182,212,0.5); }
[data-theme="dark"] .particle:nth-child(3) { background: rgba(168,85,247,0.5); }
[data-theme="dark"] .particle:nth-child(4) { background: rgba(59,130,246,0.6); }
[data-theme="dark"] .particle:nth-child(5) { background: rgba(147,197,253,0.5); }
[data-theme="dark"] .particle:nth-child(6) { background: rgba(6,182,212,0.5); }
[data-theme="dark"] .particle:nth-child(7) { background: rgba(168,85,247,0.5); }
[data-theme="dark"] .particle:nth-child(8) { background: rgba(147,197,253,0.5); }

[data-theme="dark"] .roadmap-community {
    background: linear-gradient(135deg, rgba(59,130,246,0.08), rgba(59,130,246,0.03));
    border-color: rgba(59,130,246,0.2);
}

[data-theme="dark"] .community-icon {
    background: #1e293b;
    border-color: rgba(59,130,246,0.3);
}

/* ===== SCROLL PROGRESS BAR ===== */
.scroll-progress {
    position: fixed;
    top: 0;
    left: 0;
    height: 3px;
    width: 0%;
    background: linear-gradient(90deg, var(--blue-400), var(--blue-600), var(--cyan-500));
    z-index: 10000;
    transition: width 0.05s linear;
    border-radius: 0 2px 2px 0;
    box-shadow: 0 0 10px rgba(59,130,246,0.5);
}

/* ===== BACK TO TOP BUTTON ===== */
.back-to-top {
    position: fixed;
    bottom: 32px;
    right: 32px;
    width: 48px;
    height: 48px;
    border-radius: 50%;
    background: var(--blue-600);
    color: white;
    border: none;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 999;
    opacity: 0;
    visibility: hidden;
    transform: translateY(20px) scale(0.8);
    transition: all 0.4s cubic-bezier(0.16, 1, 0.3, 1);
    box-shadow: var(--shadow-blue), var(--shadow-lg);
}

.back-to-top.visible {
    opacity: 1;
    visibility: visible;
    transform: translateY(0) scale(1);
}

.back-to-top:hover {
    background: var(--blue-700);
    transform: translateY(-4px) scale(1.1);
    box-shadow: 0 8px 25px rgba(59,130,246,0.5);
}

.back-to-top:active {
    transform: translateY(-2px) scale(1.05);
}

/* ===== HERO PARTICLES ===== */
.hero-particles {
    position: absolute;
    inset: 0;
    overflow: hidden;
    pointer-events: none;
}

.particle {
    position: absolute;
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: var(--blue-400);
    opacity: 0;
    animation: particleFloat 8s ease-in-out infinite;
}

.particle:nth-child(1) { left: 10%; top: 20%; animation-delay: 0s; animation-duration: 7s; width: 4px; height: 4px; background: var(--blue-300); }
.particle:nth-child(2) { left: 25%; top: 60%; animation-delay: 1s; animation-duration: 9s; width: 8px; height: 8px; background: var(--cyan-500); }
.particle:nth-child(3) { left: 50%; top: 15%; animation-delay: 2s; animation-duration: 6s; width: 5px; height: 5px; background: var(--purple-500); }
.particle:nth-child(4) { left: 70%; top: 40%; animation-delay: 3s; animation-duration: 10s; width: 6px; height: 6px; background: var(--blue-500); }
.particle:nth-child(5) { left: 85%; top: 70%; animation-delay: 1.5s; animation-duration: 8s; width: 4px; height: 4px; background: var(--blue-400); }
.particle:nth-child(6) { left: 40%; top: 80%; animation-delay: 4s; animation-duration: 7s; width: 7px; height: 7px; background: var(--cyan-500); }
.particle:nth-child(7) { left: 15%; top: 50%; animation-delay: 2.5s; animation-duration: 11s; width: 5px; height: 5px; background: var(--purple-500); }
.particle:nth-child(8) { left: 90%; top: 25%; animation-delay: 0.5s; animation-duration: 9s; width: 6px; height: 6px; background: var(--blue-300); }

@keyframes particleFloat {
    0% { opacity: 0; transform: translateY(0) translateX(0) scale(0); }
    10% { opacity: 0.6; transform: scale(1); }
    50% { opacity: 0.3; transform: translateY(-80px) translateX(30px) scale(1.2); }
    90% { opacity: 0.5; transform: translateY(-160px) translateX(-20px) scale(0.8); }
    100% { opacity: 0; transform: translateY(-200px) translateX(10px) scale(0); }
}

/* ===== STATS SECTION ===== */
.stats-section {
    padding: 40px 0;
    position: relative;
    overflow: hidden;
}

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

.stat-card {
    text-align: center;
    padding: 32px 16px;
    border-radius: var(--radius-lg);
    background: var(--white);
    border: 1px solid var(--gray-200);
    transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
    position: relative;
    overflow: hidden;
}

.stat-card::before {
    content: '';
    position: absolute;
    inset: 0;
    border-radius: var(--radius-lg);
    padding: 1.5px;
    background: linear-gradient(135deg, var(--blue-400), var(--cyan-500), var(--purple-500));
    -webkit-mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
    mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
    -webkit-mask-composite: xor;
    mask-composite: exclude;
    opacity: 0;
    transition: opacity 0.4s ease;
}

.stat-card:hover::before {
    opacity: 1;
}

.stat-card:hover {
    transform: translateY(-6px);
    box-shadow: var(--shadow-xl);
    border-color: transparent;
}

.stat-number {
    font-size: 2.5rem;
    font-weight: 800;
    background: linear-gradient(135deg, var(--blue-600), var(--cyan-500));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    line-height: 1.2;
    margin-bottom: 8px;
    font-family: var(--font-sans);
}

.stat-label {
    font-size: 0.85rem;
    font-weight: 600;
    color: var(--gray-500);
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

/* ===== FEATURE CARD GLOW EFFECT ===== */
.feature-card {
    --glow-x: 50%;
    --glow-y: 50%;
}

.feature-card::after {
    content: '';
    position: absolute;
    inset: 0;
    border-radius: var(--radius-lg);
    background: radial-gradient(
        300px circle at var(--glow-x) var(--glow-y),
        rgba(59,130,246,0.08) 0%,
        transparent 100%
    );
    opacity: 0;
    transition: opacity 0.4s ease;
    pointer-events: none;
}

.feature-card:hover::after {
    opacity: 1;
}

/* ===== SMOOTH PAGE LOAD ===== */
@keyframes pageLoad {
    from {
        opacity: 0;
    }
    to {
        opacity: 1;
    }
}

body {
    animation: pageLoad 0.6s ease-out;
}

/* ===== RESPONSIVE ===== */
@media (max-width: 1024px) {
    .features-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .roles-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .tech-grid {
        grid-template-columns: repeat(3, 1fr);
    }

    .stats-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .runner-layout {
        grid-template-columns: 1fr;
        gap: 48px;
    }

    .runner-info .section-title,
    .runner-info .section-desc {
        text-align: center;
    }

    .runner-langs {
        justify-content: center;
    }

    .arch-connections {
        gap: 60px;
    }
}

@media (max-width: 768px) {
    .nav-links {
        display: none;
        position: absolute;
        top: 100%;
        left: 0;
        right: 0;
        transform: none;
        background: var(--white);
        flex-direction: column;
        padding: 24px;
        gap: 16px;
        border-bottom: 1px solid var(--gray-200);
        box-shadow: var(--shadow-lg);
    }

    .nav-links.open {
        display: flex;
    }

    .nav-toggle {
        display: flex;
        order: 10;
    }

    .nav-container {
        gap: 10px;
        flex-wrap: nowrap;
    }

    .nav-cta-secondary {
        display: none;
    }

    .nav-cta {
        font-size: 0.75rem;
        padding: 6px 12px;
    }

    .lang-toggle,
    .theme-toggle {
        width: 36px;
        height: 36px;
    }

    .hero {
        padding: 120px 0 60px;
        min-height: auto;
    }

    .hero-actions {
        flex-direction: column;
    }

    .hero-visual {
        margin: 0 -12px;
    }

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

    .feature-card-lg {
        grid-column: span 1;
    }

    .steps-grid {
        flex-direction: column;
        align-items: center;
    }

    .step-connector {
        padding: 0;
        transform: rotate(90deg);
    }

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

    .tech-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .footer-content {
        grid-template-columns: 1fr;
        gap: 40px;
    }

    .footer-links {
        grid-template-columns: repeat(2, 1fr);
    }

    .architecture-block {
        padding: 32px 16px;
        overflow-x: auto;
    }

    .arch-children {
        flex-direction: column;
    }

    .arch-connections {
        flex-direction: column;
        gap: 0;
    }

    .arch-connections::before {
        display: none;
    }

    .arch-clients-row {
        flex-direction: column;
    }

    .cta-block {
        padding: 48px 24px;
    }

    .cta-actions {
        flex-direction: column;
        align-items: center;
    }

    .session-users, .window-session {
        display: none;
    }

    .window-title {
        font-size: 0.7rem;
    }

    .ngrok-block {
        flex-direction: column;
        align-items: center;
        text-align: center;
    }

    .stats-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .back-to-top {
        bottom: 20px;
        right: 20px;
        width: 42px;
        height: 42px;
    }
}

@media (max-width: 480px) {
    .container {
        padding: 0 16px;
    }

    .nav-container {
        gap: 8px;
    }

    .nav-logo span {
        font-size: 1rem;
    }

    .nav-cta {
        font-size: 0.7rem;
        padding: 5px 10px;
        gap: 4px;
    }

    .nav-cta svg {
        width: 14px;
        height: 14px;
    }

    .lang-toggle,
    .theme-toggle {
        width: 32px;
        height: 32px;
    }

    .lang-toggle .lang-label {
        font-size: 0.6rem;
    }

    .theme-toggle svg {
        width: 15px;
        height: 15px;
    }

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

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

    .code-window-body {
        font-size: 0.72rem;
    }

    .line-num {
        width: 36px;
        padding-right: 12px;
    }

    .start-step {
        gap: 16px;
    }

    .tech-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 12px;
    }
}
