/* --- Root Variables & Global Reset --- */
:root {
    --bg1: #02040a;
    --bg2: #0b0f1d;
    --accent: #35e8ff; /* Bright Blue/Cyan */
    --accent2: #6c5ce7; /* Purple */
    --soft: #9bb1ff;
    --text-primary: #c7d4ff;
    --text-secondary: #a6b1d9;
    --glass: rgba(255, 255, 255, 0.04);
    --border-color: rgba(255, 255, 255, 0.06);
    --font-title: 'Orbitron', sans-serif;
    --font-body: 'Inter', sans-serif;
}

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

body {
    background: radial-gradient(circle at 20% 20%, #0d1230, #02040a);
    font-family: var(--font-body);
    color: var(--text-primary);
    overflow-x: hidden;
    line-height: 1.6;
}

html { scroll-behavior: smooth; }

/* --- Header & Nav --- */
.header {
    position: fixed; top: 0; left: 0; right: 0;
    padding: 15px 40px;
    display: flex; justify-content: space-between; align-items: center;
    background: rgba(0, 0, 0, 0.6);
    backdrop-filter: blur(15px);
    border-bottom: 1px solid var(--border-color);
    z-index: 1000;
}

.logo {
    font-family: var(--font-title);
    color: var(--accent);
    font-size: 1.5rem;
    font-weight: 700;
    text-shadow: 0 0 18px rgba(53, 232, 255, 0.4);
    letter-spacing: 1px;
    z-index: 1001;
}

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

.nav-link {
    color: var(--text-primary);
    text-decoration: none;
    font-size: 0.95rem;
    font-weight: 500;
    transition: 0.3s;
    position: relative;
}

.nav-link:hover {
    color: var(--accent);
    text-shadow: 0 0 8px rgba(53, 232, 255, 0.6);
}

/* --- Menu Toggle (Hamburger) --- */
.menu-toggle {
    display: none; /* Hidden on Desktop */
    flex-direction: column;
    cursor: pointer;
    z-index: 1001;
}

.bar {
    width: 25px;
    height: 3px;
    background-color: var(--text-primary);
    margin: 3px 0;
    transition: 0.4s;
}
/* Hamburger animation */
.menu-toggle.active .bar:nth-child(2) { opacity: 0; }
.menu-toggle.active .bar:nth-child(1) { transform: translateY(8px) rotate(45deg); }
.menu-toggle.active .bar:nth-child(3) { transform: translateY(-8px) rotate(-45deg); }

/* --- Buttons --- */
.btn {
    padding: 12px 28px;
    border-radius: 12px;
    font-family: var(--font-body);
    font-weight: 700;
    cursor: pointer;
    transition: all 0.3s ease;
    text-decoration: none;
    display: inline-block;
    font-size: 1rem;
    text-align: center;
}

/* Connect Wallet Button - DOUBLE WIDTH */
.btn-cta, .primary-btn {
    border: none;
    background: linear-gradient(90deg, var(--accent), var(--accent2));
    color: #000;
    box-shadow: 0 0 20px rgba(53, 232, 255, 0.3);
    min-width: 240px;
    padding: 14px 40px;
    font-size: 1.1rem;
    letter-spacing: 0.5px;
}

.btn-cta:hover, .primary-btn:hover {
    transform: translateY(-3px);
    box-shadow: 0 0 40px rgba(53, 232, 255, 0.6);
}

.secondary-btn {
    background: transparent;
    color: var(--accent);
    border: 2px solid var(--accent);
    box-shadow: 0 0 10px rgba(53, 232, 255, 0.1);
}

.secondary-btn:hover {
    background: rgba(53, 232, 255, 0.1);
    box-shadow: 0 0 20px rgba(53, 232, 255, 0.3);
    transform: translateY(-3px);
}

main { padding-top: 100px; }

/* --- Hero Section --- */
.hero-section {
    max-width: 1400px; margin: auto; padding: 60px 40px;
    display: grid; grid-template-columns: 1.2fr 0.8fr; gap: 40px;
    align-items: center;
}

.hero-content h1 {
    font-family: var(--font-title);
    font-size: 3.2rem;
    color: var(--accent);
    text-shadow: 0 0 30px rgba(53, 232, 255, 0.5);
    line-height: 1.2;
    margin-bottom: 25px;
}

.hero-content p {
    font-size: 1.1rem;
    margin-bottom: 35px;
    color: #d7e1ff;
    max-width: 600px;
}

/* KPIs */
.kpis {
    display: flex; gap: 15px; flex-wrap: wrap; margin-bottom: 35px;
}

.kpi {
    backdrop-filter: blur(10px);
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid var(--border-color);
    padding: 15px 20px;
    border-radius: 12px;
    min-width: 150px;
    flex: 1;
    transition: 0.3s;
}

.kpi strong {
    display: block; color: white;
    font-family: var(--font-title); font-size: 1.2rem; margin-bottom: 5px;
}

.kpi span { color: var(--text-secondary); font-size: 0.8rem; font-weight: 600; }

#aiCore {
    width: 100%; height: 500px;
    border-radius: 30px;
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid var(--border-color);
    box-shadow: 0 0 50px rgba(0, 0, 0, 0.5);
    overflow: hidden;
}

/* --- Section Styles --- */
.section {
    max-width: 1400px; margin: 60px auto; padding: 40px;
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid var(--border-color);
    border-radius: 24px;
    backdrop-filter: blur(12px);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.3);
}

.section h2 {
    font-family: var(--font-title);
    font-size: 2rem;
    margin-bottom: 30px;
    color: var(--accent);
    text-align: center;
}

.chart-wrap {
    height: 400px;
    background: rgba(0, 0, 0, 0.3);
    border-radius: 20px;
    padding: 20px;
    border: 1px solid var(--border-color);
}

/* Stats */
.stats { display: flex; gap: 20px; flex-wrap: wrap; margin-top: 30px; }
.stat {
    flex: 1; min-width: 200px;
    padding: 20px;
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid var(--border-color);
    border-radius: 18px;
    text-align: center;
}
.stat div:first-child { color: var(--text-secondary); font-size: 0.9rem; margin-bottom: 8px; }
.value { color: white; font-size: 1.4rem; font-family: var(--font-title); }

#neuralField {
    height: 400px; width: 100%;
    border-radius: 20px;
    background: rgba(0, 0, 0, 0.2);
    border: 1px solid var(--border-color);
    overflow: hidden;
}

.content-section p {
    font-size: 1rem; color: var(--text-secondary); text-align: center; max-width: 900px; margin: auto;
}

.footer {
    background: rgba(0, 0, 0, 0.5); padding: 30px 0; text-align: center;
    border-top: 1px solid var(--border-color); color: var(--text-secondary); font-size: 0.8rem; margin-top: 60px;
}

/* --- RESPONSIVE DESIGN (MOBILE) --- */
@media (max-width: 768px) {
    .header { padding: 15px 20px; }

    /* Mobile Menu Logic */
    .menu-toggle { display: flex; } /* Show Hamburger */

    .nav {
        position: fixed;
        left: -100%; /* Hidden by default */
        top: 70px;
        gap: 0;
        flex-direction: column;
        background: rgba(11, 15, 29, 0.98);
        width: 100%;
        text-align: center;
        transition: left 0.3s ease-in-out;
        border-bottom: 1px solid var(--border-color);
        padding: 20px 0;
        height: calc(100vh - 70px); /* Full height on mobile */
        overflow-y: auto;
    }

    .nav.active { left: 0; } /* Show Nav when active */

    .nav-link { margin: 15px 0; display: block; font-size: 1.1rem; }

    /* Button in mobile menu */
    .connect-wallet-btn {
        margin: 20px auto;
        width: 80%;
        min-width: unset;
        display: block;
    }

    /* Hero Layout Adjustments */
    .hero-section { grid-template-columns: 1fr; text-align: center; padding: 40px 20px; }
    .hero-content h1 { font-size: 2.2rem; }
    .hero-content p { font-size: 1rem; padding: 0 10px; }
    .hero-image { order: -1; margin-bottom: 30px; }
    #aiCore { height: 300px; }
    .kpis { justify-content: center; }
    .cta-buttons { justify-content: center; display: flex; flex-direction: column; gap: 15px; }
    .btn { width: 100%; }

    /* Section Adjustments */
    .section { padding: 30px 15px; margin: 40px auto; }
    .section h2 { font-size: 1.6rem; }
    .chart-wrap, #neuralField { height: 300px; }
    .stats { flex-direction: column; }
    .stat { width: 100%; }
}
