:root {
    /* Colors - Midnight & Electric Blue */
    --bg: #030712; /* Deep Obsidian */
    --bg-subtle: #090e1a;
    --bg-card: #111827;
    --border: rgba(255, 255, 255, 0.05);
    --border-bright: rgba(255, 255, 255, 0.12);
    
    --text: #f9fafb;
    --text-muted: #9ca3af;
    --text-dim: #4b5563;
    
    --primary: #60a5fa; /* Electric Blue */
    --primary-glow: rgba(96, 165, 250, 0.2);
    --accent: #a78bfa; /* Soft Violet */
    --accent-glow: rgba(167, 139, 250, 0.2);
    
    --code-bg: #030712;
    --code-keyword: #60a5fa;
    --code-string: #34d399; /* Emerald Green */
    --code-comment: #6b7280;
    --code-ref: #f472b6; /* Pink Accent */

    /* Geometry */
    --radius-sm: 8px;
    --radius-md: 16px;
    --radius-lg: 32px;
    --container: 1200px;
    
    /* Typography */
    --font-sans: 'Inter', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
    --font-mono: 'JetBrains Mono', 'Fira Code', monospace;
}

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

html {
    scroll-behavior: smooth;
}

body {
    font-family: var(--font-sans);
    background-color: var(--bg);
    color: var(--text);
    line-height: 1.5;
    -webkit-font-smoothing: antialiased;
    overflow-x: hidden;
}

/* --- Layout --- */
.container {
    max-width: var(--container);
    margin: 0 auto;
    padding: 0 1.5rem;
}

section {
    padding: 8rem 0;
}

/* --- Typography --- */
h1, h2, h3 {
    letter-spacing: -0.03em;
    font-weight: 700;
}

.gradient-text {
    background: linear-gradient(135deg, #fff 30%, var(--primary) 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

/* --- Components --- */
.btn {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.75rem 1.5rem;
    border-radius: var(--radius-sm);
    font-weight: 500;
    font-size: 0.875rem;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    text-decoration: none;
}

.btn-primary {
    background: var(--text);
    color: var(--bg);
    border: 1px solid var(--text);
    box-shadow: 0 4px 12px rgba(255, 255, 255, 0.1);
}

.btn-primary:hover {
    background: transparent;
    color: var(--text);
    transform: translateY(-1px);
    box-shadow: 0 8px 20px rgba(255, 255, 255, 0.15);
}

.btn-secondary {
    background: rgba(255, 255, 255, 0.03);
    color: var(--text);
    border: 1px solid var(--border);
    backdrop-filter: blur(12px);
}

.btn-secondary:hover {
    background: rgba(255, 255, 255, 0.08);
    border-color: var(--border-bright);
    transform: translateY(-1px);
}

/* --- Navigation --- */
.navbar {
    position: fixed;
    top: 0;
    width: 100%;
    height: 72px;
    display: flex;
    align-items: center;
    border-bottom: 1px solid var(--border);
    background: rgba(3, 7, 18, 0.8);
    backdrop-filter: blur(16px);
    z-index: 1000;
}

.navbar .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    width: 100%;
}

.logo {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    font-weight: 600;
    font-size: 1.1rem;
}

.logo-icon {
    width: 20px;
    height: 20px;
    background: linear-gradient(135deg, var(--primary), var(--accent));
    border-radius: 4px;
    box-shadow: 0 0 15px var(--primary-glow);
}

.nav-links {
    display: flex;
    gap: 2rem;
}

.nav-links a {
    font-size: 0.875rem;
    color: var(--text-muted);
    transition: color 0.2s;
}

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

/* --- Hero --- */
.hero {
    padding-top: 10rem;
    padding-bottom: 4rem;
    text-align: center;
    position: relative;
}

.hero-badge {
    display: inline-flex;
    padding: 0.4rem 1rem;
    background: rgba(96, 165, 250, 0.05);
    border: 1px solid rgba(96, 165, 250, 0.2);
    border-radius: 100px;
    color: var(--primary);
    font-size: 0.75rem;
    font-weight: 600;
    margin-bottom: 2rem;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    box-shadow: 0 0 20px var(--primary-glow);
}

.hero h1 {
    font-size: 5rem;
    line-height: 1.05;
    margin-bottom: 1.5rem;
}

.hero-subtitle {
    font-size: 1.25rem;
    color: var(--text-muted);
    max-width: 750px;
    margin: 0 auto 3rem;
}

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

/* --- Mock IDE Editor --- */
.hero-visual {
    margin-top: 6rem;
    perspective: 2000px;
}

.editor-window {
    background: var(--bg-subtle);
    border: 1px solid var(--border-bright);
    border-radius: var(--radius-md);
    box-shadow: 
        0 30px 60px rgba(0, 0, 0, 0.6),
        0 0 0 1px rgba(255, 255, 255, 0.05);
    overflow: hidden;
    text-align: left;
    transform: rotateX(2deg);
    transition: transform 0.5s cubic-bezier(0.4, 0, 0.2, 1);
}

.editor-window:hover {
    transform: rotateX(0deg) translateY(-8px);
    box-shadow: 
        0 40px 80px rgba(0, 0, 0, 0.7),
        0 0 0 1px rgba(255, 255, 255, 0.08);
}

.editor-toolbar {
    height: 48px;
    background: rgba(255, 255, 255, 0.02);
    border-bottom: 1px solid var(--border);
    display: flex;
    align-items: center;
    padding: 0 1.25rem;
    gap: 1rem;
}

.editor-dots {
    display: flex;
    gap: 8px;
}

.editor-dots span {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: var(--border-bright);
}

.editor-tab {
    font-family: var(--font-mono);
    font-size: 0.75rem;
    color: var(--text-muted);
    padding: 6px 16px;
    background: var(--bg-subtle);
    border: 1px solid var(--border);
    border-bottom: none;
    border-radius: 6px 6px 0 0;
    margin-top: 10px;
}

.editor-content {
    display: grid;
    grid-template-columns: 260px 1fr 1fr;
    height: 580px;
}

/* Sidebar */
.editor-sidebar {
    border-right: 1px solid var(--border);
    padding: 2rem;
    background: rgba(0, 0, 0, 0.2);
}

.sidebar-label {
    font-size: 0.65rem;
    text-transform: uppercase;
    color: var(--text-dim);
    letter-spacing: 0.1em;
    margin-bottom: 1.5rem;
    display: block;
}

.asset-item {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    font-size: 0.8rem;
    color: var(--text-muted);
    margin-bottom: 1rem;
    padding: 0.4rem 0.75rem;
    border-radius: 6px;
    transition: all 0.2s;
}

.asset-item.active {
    background: rgba(255, 255, 255, 0.05);
    color: var(--text);
    box-shadow: inset 0 0 10px rgba(0, 0, 0, 0.2);
}

.asset-item i {
    width: 14px;
    height: 14px;
    border-radius: 3px;
    background: var(--text-dim);
}

/* Canvas */
.editor-canvas {
    border-right: 1px solid var(--border);
    padding: 2.5rem;
    background-image: radial-gradient(var(--border) 1px, transparent 1px);
    background-size: 24px 24px;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 2.5rem;
    position: relative;
}

.canvas-node {
    background: var(--bg-card);
    border: 1px solid var(--border-bright);
    border-radius: 12px;
    width: 200px;
    padding: 1.25rem;
    position: relative;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.5);
    z-index: 2;
}

.canvas-node::before {
    content: '';
    position: absolute;
    inset: -1px;
    border-radius: 9px;
    padding: 1px;
    background: linear-gradient(to bottom, var(--border-bright), transparent);
    -webkit-mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
    mask-composite: exclude;
    pointer-events: none;
}

.node-header {
    font-size: 0.7rem;
    font-weight: 600;
    color: var(--primary);
    margin-bottom: 0.5rem;
    display: flex;
    justify-content: space-between;
}

.node-title {
    font-size: 0.8rem;
    color: var(--text);
}

.node-conn {
    position: absolute;
    width: 8px;
    height: 8px;
    background: var(--bg-card);
    border: 1px solid var(--primary);
    border-radius: 50%;
    left: 50%;
    transform: translateX(-50%);
}

.node-conn-top { top: -5px; }
.node-conn-bottom { bottom: -5px; }

.canvas-line {
    position: absolute;
    width: 2px;
    background: linear-gradient(to bottom, var(--primary), var(--accent));
    height: 60px;
    z-index: 1;
    opacity: 0.5;
}

/* Code */
.editor-code {
    padding: 1.5rem;
    background: var(--code-bg);
    font-family: var(--font-mono);
    font-size: 0.8rem;
    line-height: 1.7;
    overflow-y: auto;
}

.code-keyword { color: var(--code-keyword); }
.code-string { color: var(--code-string); }
.code-ref { color: var(--code-ref); font-weight: 600; }
.code-comment { color: var(--code-comment); }

/* --- Features Bento --- */
.features-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    grid-template-rows: auto;
    gap: 2rem;
    margin-top: 5rem;
}

.bento-card {
    background: var(--bg-subtle);
    border: 1px solid var(--border);
    border-radius: var(--radius-md);
    padding: 3rem;
    position: relative;
    overflow: hidden;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.2);
}

.bento-card:hover {
    border-color: var(--border-bright);
    transform: translateY(-8px);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.4);
}

.bento-card.large {
    grid-column: span 2;
}

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

.bento-card p {
    color: var(--text-muted);
    font-size: 1rem;
    max-width: 440px;
    line-height: 1.6;
}

.bento-icon {
    display: inline-flex;
    padding: 0.5rem 1rem;
    margin-bottom: 2.5rem;
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid var(--border-bright);
    border-radius: var(--radius-sm);
    font-family: var(--font-mono);
    font-size: 0.7rem;
    font-weight: 600;
    letter-spacing: 0.12em;
    color: var(--text-muted);
    text-transform: uppercase;
    box-shadow: inset 0 0 10px rgba(255, 255, 255, 0.02);
}

.glow-effect {
    position: absolute;
    top: -100px;
    right: -100px;
    width: 300px;
    height: 300px;
    background: radial-gradient(circle, var(--primary-glow) 0%, transparent 70%);
    opacity: 0.4;
    pointer-events: none;
    transition: opacity 0.3s;
}

.bento-card:hover .glow-effect {
    opacity: 0.6;
}

/* --- Stats/Social Proof --- */
.stats {
    padding: 6rem 0;
    border-top: 1px solid var(--border);
    border-bottom: 1px solid var(--border);
    background: rgba(255, 255, 255, 0.01);
}

.stats-container {
    display: flex;
    justify-content: space-around;
    text-align: center;
}

.stat-item h4 {
    font-size: 3.5rem;
    margin-bottom: 0.5rem;
    background: linear-gradient(to bottom, #fff, var(--text-muted));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.stat-item p {
    font-size: 0.8rem;
    color: var(--text-dim);
    text-transform: uppercase;
    letter-spacing: 0.15em;
    font-weight: 600;
}

/* --- Call to Action --- */
.cta {
    text-align: center;
    background: radial-gradient(circle at top right, #090e1a 0%, #030712 100%);
    border-radius: var(--radius-lg);
    margin: 6rem 1.5rem;
    padding: 8rem 2rem;
    border: 1px solid var(--border-bright);
    position: relative;
    overflow: hidden;
    box-shadow: 0 40px 100px rgba(0, 0, 0, 0.6);
}

.cta::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: radial-gradient(circle at center, var(--primary-glow) 0%, transparent 40%);
    pointer-events: none;
}

.cta h2 {
    font-size: 3.5rem;
    margin-bottom: 1.5rem;
    position: relative;
    z-index: 1;
}

.cta .hero-subtitle {
    position: relative;
    z-index: 1;
    margin-bottom: 3rem;
}

.cta .hero-actions {
    position: relative;
    z-index: 1;
}

/* --- Footer --- */
footer {
    padding: 6rem 0;
    border-top: 1px solid var(--border);
    color: var(--text-dim);
    background: rgba(0, 0, 0, 0.2);
}

.footer-top {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr 1fr;
    gap: 4rem;
    margin-bottom: 6rem;
}

.footer-logo {
    color: var(--text);
    font-size: 1.25rem;
    font-weight: 700;
    margin-bottom: 1.5rem;
    display: block;
    letter-spacing: -0.02em;
}

.footer-link-group h5 {
    color: var(--text);
    font-size: 0.85rem;
    margin-bottom: 2rem;
    text-transform: uppercase;
    letter-spacing: 0.12em;
    font-weight: 600;
}

.footer-link-group a {
    display: block;
    font-size: 0.9375rem;
    margin-bottom: 1rem;
    color: var(--text-muted);
    text-decoration: none;
    transition: all 0.2s;
}

.footer-link-group a:hover {
    color: var(--primary);
    transform: translateX(4px);
}

.footer-bottom {
    padding-top: 2rem;
    border-top: 1px solid var(--border);
    display: flex;
    justify-content: space-between;
    align-items: center;
}

@media (max-width: 1024px) {
    .hero h1 { font-size: 4rem; }
    .editor-content { grid-template-columns: 1fr; height: auto; }
    .editor-sidebar { display: none; }
    .editor-canvas { border-right: none; border-bottom: 1px solid var(--border); }
    .footer-top { grid-template-columns: 1fr 1fr; }
}

@media (max-width: 768px) {
    section { padding: 5rem 0; }
    
    .navbar .nav-links { display: none; }
    
    .hero h1 { font-size: 3rem; }
    .hero-subtitle { font-size: 1.1rem; }
    
    .features-grid { grid-template-columns: 1fr; }
    .bento-card.large { grid-column: span 1; }
    .bento-card { padding: 2rem; }
    
    .stats-container {
        flex-direction: column;
        gap: 3rem;
    }
    
    .stat-item h4 { font-size: 3rem; }
    
    .cta h2 { font-size: 2.5rem; }
    .cta { padding: 4rem 1.5rem; margin: 2rem 1rem; }
    
    .footer-top {
        grid-template-columns: 1fr;
        gap: 2.5rem;
    }
    
    .footer-bottom {
        flex-direction: column;
        gap: 1.5rem;
        text-align: center;
    }
}

@media (max-width: 480px) {
    .hero h1 { font-size: 2.5rem; }
    
    .hero-actions {
        flex-direction: column;
        width: 100%;
    }
    
    .btn { width: 100%; justify-content: center; }
    
    .nav-actions .btn-secondary { display: none; }
    
    .canvas-node { width: 100%; max-width: 200px; }
}
