:root {
    /* Core Colors */
    --bg-primary: #050014;
    --bg-secondary: #0a0f1c;
    --text-primary: #ffffff;
    --text-secondary: #94a3b8;
    --accent-primary: #64FFDA;
    /* Teal */
    --accent-secondary: #7F00FF;
    /* Purple */
    --border-color: rgba(255, 255, 255, 0.08);

    /* Typography */
    --font-sans: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
    --font-mono: 'JetBrains Mono', monospace;

    /* Spacing */
    --container-width: 1280px;
    --section-padding: 120px;

    /* Animation */
    --ease-out: cubic-bezier(0.215, 0.61, 0.355, 1);
}

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

html {
    scroll-behavior: smooth;
}

body {
    background-color: var(--bg-primary);
    color: var(--text-primary);
    font-family: var(--font-sans);
    line-height: 1.6;
    overflow-x: hidden;
    cursor: none;
    /* Custom cursor */
}

/* Custom Cursor */
.cursor-dot,
.cursor-outline {
    position: fixed;
    top: 0;
    left: 0;
    transform: translate(-50%, -50%);
    border-radius: 50%;
    z-index: 9999;
    pointer-events: none;
}

.cursor-dot {
    width: 8px;
    height: 8px;
    background-color: var(--accent-primary);
}

.cursor-outline {
    width: 40px;
    height: 40px;
    border: 1px solid rgba(100, 255, 218, 0.5);
    transition: width 0.2s, height 0.2s, background-color 0.2s;
}

body:hover .cursor-outline {
    width: 40px;
    height: 40px;
}

/* Utility Classes */
.container {
    max-width: var(--container-width);
    margin: 0 auto;
    padding: 0 2rem;
}

.text-gradient {
    background: linear-gradient(135deg, #fff 0%, var(--accent-secondary) 100%);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    color: transparent;
    /* Fallback/Standard */
}

.btn {
    display: inline-flex;
    align-items: center;
    gap: 1rem;
    padding: 1rem 2rem;
    font-weight: 600;
    text-decoration: none;
    border-radius: 4px;
    transition: all 0.3s var(--ease-out);
    font-size: 0.95rem;
    letter-spacing: 0.02em;
    position: relative;
    overflow: hidden;
}

.btn-primary {
    background: var(--accent-primary);
    color: var(--bg-primary);
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 30px rgba(100, 255, 218, 0.2);
}

.btn-outline {
    border: 1px solid var(--border-color);
    color: var(--text-primary);
}

.btn-outline:hover {
    border-color: var(--text-primary);
    background: rgba(255, 255, 255, 0.05);
}

/* Navigation */
.navbar {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    padding: 1.5rem 0;
    z-index: 100;
    background: rgba(5, 0, 20, 0.8);
    backdrop-filter: blur(20px);
    border-bottom: 1px solid var(--border-color);
    transition: padding 0.3s;
}

.navbar.scrolled {
    padding: 1rem 0;
}

.nav-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo {
    display: flex;
    align-items: center;
    gap: 1rem;
    text-decoration: none;
    color: var(--text-primary);
}

.logo-symbol {
    width: 40px;
    height: 40px;
    background: var(--accent-primary);
    color: var(--bg-primary);
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 800;
    font-family: var(--font-mono);
    font-size: 1.2rem;
}

.logo-text {
    font-weight: 700;
    letter-spacing: -0.02em;
    font-size: 1.1rem;
}

.nav-right {
    display: flex;
    align-items: center;
    gap: 3rem;
}

.nav-links {
    display: flex;
    gap: 2.5rem;
    list-style: none;
}

.nav-link {
    color: var(--text-secondary);
    text-decoration: none;
    font-size: 0.95rem;
    transition: color 0.2s;
}

.nav-link:hover {
    color: var(--text-primary);
}

/* Hero Section */
.hero {
    min-height: 100vh;
    display: flex;
    align-items: center;
    position: relative;
    padding-top: 80px;
    overflow: hidden;
}

.grid-background {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -1;
    perspective: 1000px;
}

.grid-lines {
    position: absolute;
    width: 200%;
    height: 200%;
    background-image:
        linear-gradient(rgba(255, 255, 255, 0.03) 1px, transparent 1px),
        linear-gradient(90deg, rgba(255, 255, 255, 0.03) 1px, transparent 1px);
    background-size: 60px 60px;
    transform: rotateX(60deg) translateY(-20%) translateZ(-200px);
    animation: gridMove 20s linear infinite;
    left: -50%;
}

.grid-fade {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 80%;
    background: linear-gradient(to bottom, transparent, var(--bg-primary));
}

@keyframes gridMove {
    0% {
        transform: rotateX(60deg) translateY(0) translateZ(-200px);
    }

    100% {
        transform: rotateX(60deg) translateY(60px) translateZ(-200px);
    }
}

.hero-container {
    width: 100%;
    display: grid;
    grid-template-columns: 1.5fr 1fr;
    gap: 4rem;
    align-items: center;
}

.hero-label {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    font-family: var(--font-mono);
    color: var(--accent-primary);
    font-size: 0.85rem;
    margin-bottom: 1.5rem;
    letter-spacing: 0.05em;
}

.status-indicator {
    width: 6px;
    height: 6px;
    background: var(--accent-primary);
    border-radius: 50%;
    box-shadow: 0 0 10px var(--accent-primary);
    animation: pulse 2s infinite;
}

.hero-title {
    font-size: 4.5rem;
    line-height: 1.1;
    font-weight: 800;
    margin-bottom: 1.5rem;
    letter-spacing: -0.03em;
}

.hero-subtitle {
    font-size: 1.25rem;
    color: var(--text-secondary);
    max-width: 540px;
    margin-bottom: 2.5rem;
}

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

.hero-stats {
    display: grid;
    grid-template-columns: 1fr auto 1fr auto 1fr;
    align-items: center;
    background: rgba(255, 255, 255, 0.03);
    padding: 2rem;
    border: 1px solid var(--border-color);
    backdrop-filter: blur(10px);
}

.stat-item {
    text-align: center;
}

.stat-value {
    display: block;
    font-size: 2rem;
    font-weight: 700;
    color: var(--text-primary);
    margin-bottom: 0.25rem;
}

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

.stat-divider {
    width: 1px;
    height: 40px;
    background: var(--border-color);
}

/* Marquee */
.marquee-section {
    padding: 2rem 0;
    border-bottom: 1px solid var(--border-color);
    overflow: hidden;
    background: var(--bg-secondary);
}

.marquee-label {
    font-family: var(--font-mono);
    font-size: 0.75rem;
    color: var(--text-secondary);
    margin-bottom: 1rem;
    text-align: center;
}

.marquee-track {
    display: flex;
    white-space: nowrap;
}

.marquee-content {
    display: flex;
    gap: 3rem;
    animation: marquee 20s linear infinite;
    font-size: 1.5rem;
    font-weight: 700;
    color: rgba(255, 255, 255, 0.2);
}

.separator {
    color: var(--accent-primary);
}

@keyframes marquee {
    0% {
        transform: translateX(0);
    }

    100% {
        transform: translateX(-50%);
    }
}

/* Sections General */
.section {
    padding: var(--section-padding) 0;
}

.section-header {
    margin-bottom: 4rem;
}

.section-tag {
    font-family: var(--font-mono);
    color: var(--accent-primary);
    font-size: 0.9rem;
    display: block;
    margin-bottom: 1rem;
}

.section-title {
    font-size: 3rem;
    font-weight: 700;
    letter-spacing: -0.02em;
}

/* Intro Section */
.intro-grid {
    display: grid;
    grid-template-columns: 1.2fr 0.8fr;
    gap: 4rem;
    align-items: start;
}

.section-heading {
    font-size: 2.5rem;
    line-height: 1.3;
    font-weight: 600;
}

.intro-body p {
    color: var(--text-secondary);
    font-size: 1.1rem;
    margin-bottom: 2rem;
}

.text-link {
    color: var(--accent-primary);
    text-decoration: none;
    font-weight: 600;
    border-bottom: 1px solid var(--accent-primary);
    padding-bottom: 2px;
}

/* Services List */
.services-list {
    display: flex;
    flex-direction: column;
}

.service-item {
    border-top: 1px solid var(--border-color);
    padding: 3rem 0;
    display: grid;
    grid-template-columns: 1fr 1.5fr;
    gap: 2rem;
    transition: background-color 0.3s;
    cursor: pointer;
}

.service-item:last-child {
    border-bottom: 1px solid var(--border-color);
}

.service-item:hover {
    background: rgba(255, 255, 255, 0.02);
}

.service-item:hover .service-title {
    color: var(--accent-primary);
    transform: translateX(10px);
}

.service-header {
    display: flex;
    align-items: flex-start;
    gap: 2rem;
}

.service-number {
    font-family: var(--font-mono);
    color: var(--text-secondary);
    opacity: 0.5;
}

.service-title {
    font-size: 1.75rem;
    font-weight: 600;
    transition: all 0.3s var(--ease-out);
}

.service-icon {
    margin-left: auto;
    font-size: 1.5rem;
    color: var(--accent-primary);
    opacity: 0;
    transform: translateX(-10px);
    transition: all 0.3s;
}

.service-item:hover .service-icon {
    opacity: 1;
    transform: translateX(0);
}

.service-desc {
    color: var(--text-secondary);
    margin-bottom: 1.5rem;
    max-width: 600px;
}

.tech-stack {
    display: flex;
    gap: 1rem;
    flex-wrap: wrap;
}

.tech-stack span {
    font-family: var(--font-mono);
    font-size: 0.8rem;
    background: rgba(255, 255, 255, 0.05);
    padding: 0.25rem 0.75rem;
    border-radius: 100px;
    color: var(--text-secondary);
}

/* Protocol Section */
.protocol-section {
    background: var(--bg-secondary);
}

.protocol-grid {
    display: grid;
    grid-template-columns: 1fr 1.5fr;
    gap: 6rem;
}

.protocol-desc {
    color: var(--text-secondary);
    margin-bottom: 2rem;
    font-size: 1.1rem;
}

.protocol-steps {
    display: flex;
    flex-direction: column;
    gap: 2rem;
}

.p-step {
    padding-left: 2rem;
    border-left: 2px solid var(--border-color);
    transition: all 0.3s;
}

.p-step:hover,
.p-step.active {
    border-left-color: var(--accent-primary);
}

.p-step-header {
    display: flex;
    align-items: center;
    gap: 1rem;
    margin-bottom: 0.5rem;
}

.p-number {
    font-family: var(--font-mono);
    color: var(--accent-primary);
    font-size: 0.9rem;
}

.p-step h4 {
    font-size: 1.25rem;
    font-weight: 600;
}

.p-step p {
    color: var(--text-secondary);
    font-size: 0.95rem;
}

/* CTA Section */
.cta-section {
    text-align: center;
    padding: 8rem 0;
}

.cta-title {
    font-size: 4rem;
    line-height: 1.1;
    margin-bottom: 1.5rem;
}

.cta-text {
    font-size: 1.25rem;
    color: var(--text-secondary);
    margin-bottom: 3rem;
}

.contact-form {
    max-width: 500px;
    margin: 0 auto;
}

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

.form-group input {
    flex: 1;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid var(--border-color);
    padding: 1rem 1.5rem;
    color: var(--text-primary);
    border-radius: 4px;
    font-family: var(--font-sans);
}

.form-group input:focus {
    outline: none;
    border-color: var(--accent-primary);
}

/* Footer */
.footer {
    border-top: 1px solid var(--border-color);
    padding: 4rem 0 2rem;
    background: #02000a;
}

.footer-top {
    display: flex;
    justify-content: space-between;
    margin-bottom: 4rem;
}

.footer-brand {
    display: flex;
    align-items: center;
    gap: 1rem;
    font-weight: 700;
    font-size: 1.25rem;
}

.footer-nav {
    display: flex;
    gap: 4rem;
}

.f-col h4 {
    font-size: 0.9rem;
    color: var(--text-secondary);
    margin-bottom: 1.5rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.f-col a {
    display: block;
    color: var(--text-primary);
    text-decoration: none;
    margin-bottom: 0.75rem;
    transition: color 0.2s;
}

.f-col a:hover {
    color: var(--accent-primary);
}

.footer-bottom {
    display: flex;
    justify-content: space-between;
    color: var(--text-secondary);
    font-size: 0.9rem;
    padding-top: 2rem;
    border-top: 1px solid var(--border-color);
}

.footer-legal {
    display: flex;
    gap: 2rem;
}

.footer-legal a {
    color: var(--text-secondary);
    text-decoration: none;
}

/* Mobile Menu Button (Base Styles) */
.mobile-menu-btn {
    display: none;
    background: none;
    border: none;
    cursor: pointer;
    width: 30px;
    height: 20px;
    position: relative;
    z-index: 101;
}

.mobile-menu-btn span {
    display: block;
    width: 100%;
    height: 2px;
    background: var(--text-primary);
    position: absolute;
    transition: all 0.3s;
}

.mobile-menu-btn span:first-child {
    top: 0;
}

.mobile-menu-btn span:nth-child(2) {
    top: 50%;
    transform: translateY(-50%);
}

.mobile-menu-btn span:last-child {
    bottom: 0;
}

/* Hamburger Animation */
.mobile-menu-btn.active span:first-child {
    transform: rotate(45deg);
    top: 9px;
}

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

.mobile-menu-btn.active span:last-child {
    transform: rotate(-45deg);
    bottom: 9px;
}

/* Responsive Design */
@media (max-width: 1024px) {
    :root {
        --section-padding: 80px;
    }

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

    .hero-container {
        grid-template-columns: 1fr;
        text-align: center;
        gap: 3rem;
    }

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

    .hero-subtitle {
        margin: 0 auto 2.5rem;
    }

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

    .hero-stats {
        margin-top: 3rem;
        grid-template-columns: 1fr 1fr;
        gap: 2rem;
        border: none;
        background: transparent;
        backdrop-filter: none;
    }

    .stat-divider {
        display: none;
    }

    .intro-grid,
    .protocol-grid {
        grid-template-columns: 1fr;
        gap: 3rem;
    }

    .service-item {
        grid-template-columns: 1fr;
        gap: 1.5rem;
    }

    .service-header {
        align-items: center;
    }

    .service-icon {
        opacity: 1;
        transform: none;
    }

    /* Mobile Navigation */
    .nav-right {
        position: fixed;
        top: 0;
        right: -100%;
        width: 100%;
        height: 100vh;
        background: var(--bg-primary);
        flex-direction: column;
        justify-content: center;
        transition: right 0.4s var(--ease-out);
        padding: 2rem;
        z-index: 99;
        /* Ensure visibility */
        display: flex !important;
    }

    .nav-right.active {
        right: 0;
    }

    .nav-links {
        flex-direction: column;
        align-items: center;
        gap: 2rem;
        margin-bottom: 3rem;
    }

    .nav-link {
        font-size: 1.5rem;
    }

    .mobile-menu-btn {
        display: block;
    }
}

@media (max-width: 768px) {
    :root {
        --section-padding: 60px;
    }

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

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

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

    .footer-top {
        flex-direction: column;
        gap: 3rem;
    }

    .footer-nav {
        flex-direction: column;
        gap: 2rem;
    }

    .hero-stats {
        grid-template-columns: 1fr;
        gap: 1.5rem;
    }
}

/* Animations */
.fade-in-up {
    opacity: 0;
    transform: translateY(30px);
    animation: fadeInUp 0.8s var(--ease-out) forwards;
}

.delay-1 {
    animation-delay: 0.1s;
}

.delay-2 {
    animation-delay: 0.2s;
}

.delay-3 {
    animation-delay: 0.3s;
}

.delay-4 {
    animation-delay: 0.4s;
}

@keyframes fadeInUp {
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.reveal-text {
    opacity: 0;
    transform: translateY(20px);
    transition: all 0.8s var(--ease-out);
}

.reveal-text.visible {
    opacity: 1;
    transform: translateY(0);
}

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

.impact-card {
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid var(--border-color);
    padding: 2.5rem;
    transition: all 0.3s var(--ease-out);
}

.impact-card:hover {
    background: rgba(255, 255, 255, 0.05);
    transform: translateY(-5px);
    border-color: var(--accent-primary);
}

.impact-icon {
    font-size: 2.5rem;
    margin-bottom: 1.5rem;
}

.impact-card h3 {
    font-size: 1.25rem;
    font-weight: 600;
    margin-bottom: 1rem;
    color: var(--text-primary);
}

.impact-card p {
    color: var(--text-secondary);
    font-size: 0.95rem;
    line-height: 1.6;
}

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

.insight-card {
    display: flex;
    flex-direction: column;
    border-top: 1px solid var(--border-color);
    padding-top: 2rem;
    transition: all 0.3s;
}

.insight-card:hover {
    border-top-color: var(--accent-secondary);
}

.insight-date {
    font-family: var(--font-mono);
    font-size: 0.8rem;
    color: var(--accent-primary);
    margin-bottom: 1rem;
}

.insight-card h3 {
    font-size: 1.5rem;
    font-weight: 600;
    margin-bottom: 1rem;
    line-height: 1.3;
}

.insight-card p {
    color: var(--text-secondary);
    font-size: 1rem;
    margin-bottom: 1.5rem;
    flex-grow: 1;
}

.read-more {
    color: var(--text-primary);
    text-decoration: none;
    font-weight: 600;
    font-size: 0.9rem;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    transition: gap 0.2s;
}

.read-more:hover {
    gap: 0.8rem;
    color: var(--accent-primary);
}

/* Intro Image */
.intro-image {
    position: relative;
    border-radius: 4px;
    overflow: hidden;
    border: 1px solid var(--border-color);
}

.intro-image img {
    width: 100%;
    height: auto;
    display: block;
    transition: transform 0.5s var(--ease-out);
}

.intro-image:hover img {
    transform: scale(1.05);
}

/* Insight Images */
.insight-card {
    display: flex;
    flex-direction: column;
    border-top: 1px solid var(--border-color);
    padding-top: 0;
    /* Reset padding */
    transition: all 0.3s;
    overflow: hidden;
    background: rgba(255, 255, 255, 0.02);
    /* Slight background */
    border: 1px solid var(--border-color);
    /* Full border */
}

.insight-image {
    width: 100%;
    height: 200px;
    overflow: hidden;
    border-bottom: 1px solid var(--border-color);
}

.insight-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s var(--ease-out);
}

.insight-card:hover .insight-image img {
    transform: scale(1.1);
}

.insight-content {
    padding: 2rem;
    display: flex;
    flex-direction: column;
    flex-grow: 1;
}

.insight-card:hover {
    border-color: var(--accent-secondary);
    transform: translateY(-5px);
}