/* main.css */

:root {
    --bg-color: #0F172A;
    --surface-color: rgba(255, 255, 255, 0.05);
    --border-color: rgba(255, 255, 255, 0.1);
    --primary-color: #22C55E;
    --text-primary: #F8FAFC;
    --text-secondary: #94A3B8;
    --accent-glow: rgba(34, 197, 94, 0.15);
    --accent-glow-strong: rgba(34, 197, 94, 0.3);

    --font-heading: 'Orbitron', sans-serif;
    --font-body: 'Exo 2', sans-serif;

    --transition-fast: 0.2s ease;
    --transition-smooth: 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    background-color: var(--bg-color);
    color: var(--text-primary);
    font-family: var(--font-body);
    line-height: 1.6;
    overflow-x: hidden;
    position: relative;
    min-height: 100vh;
}

/* Background Gradients */
.bg-gradient {
    position: fixed;
    border-radius: 50%;
    filter: blur(120px);
    z-index: -10;
    /* Changed from -1 to ensure it's firmly in the back */
    animation: drift 20s infinite alternate cubic-bezier(0.2, 0.8, 0.2, 0.8);
    opacity: 0.4;
    pointer-events: none;
    /* Crucial: Gradients should NEVER intercept clicks */
}

.bg-gradient-1 {
    top: -20vh;
    left: -10vw;
    width: 60vw;
    height: 60vw;
    background: radial-gradient(circle, rgba(100, 100, 100, 0.15) 0%, rgba(0, 0, 0, 0) 70%);
}

.bg-gradient-2 {
    bottom: -30vh;
    right: -20vw;
    width: 80vw;
    height: 80vw;
    background: radial-gradient(circle, rgba(80, 80, 90, 0.2) 0%, rgba(0, 0, 0, 0) 70%);
    animation-delay: -10s;
}

@keyframes drift {
    0% {
        transform: translate(0, 0) scale(1);
    }

    100% {
        transform: translate(10vw, 5vh) scale(1.1);
    }
}

/* Typography */
h1,
h2,
h3,
h4 {
    font-family: var(--font-heading);
    font-weight: 700;
    line-height: 1.2;
    margin-bottom: 1rem;
}

h1 {
    font-size: clamp(2.5rem, 6vw, 5rem);
    letter-spacing: -0.03em;
}

h2 {
    font-size: clamp(2rem, 4vw, 3rem);
    letter-spacing: -0.02em;
}

p {
    color: var(--text-secondary);
    font-size: 1.125rem;
    max-width: 600px;
}

.text-gradient {
    /* Subtle silver/white gradient for "Autonomy" */
    background: linear-gradient(135deg, #ffffff 0%, #888888 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

/* Buttons */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0.75rem 1.5rem;
    border-radius: 6px;
    font-weight: 600;
    font-family: var(--font-body);
    text-decoration: none;
    transition: var(--transition-smooth);
    cursor: pointer;
    border: 1px solid transparent;
}

.btn-primary {
    background-color: var(--primary-color);
    color: #000;
}

.btn-primary:hover {
    background-color: #22C55E;
    opacity: 0.9;
    transform: translateY(-2px);
    box-shadow: 0 4px 20px rgba(34, 197, 94, 0.4);
}

.btn-secondary {
    background-color: transparent;
    color: var(--text-primary);
    border-color: var(--border-color);
}

.btn-secondary:hover {
    background-color: rgba(255, 255, 255, 0.05);
    border-color: rgba(255, 255, 255, 0.2);
    transform: translateY(-2px);
}

.btn-large {
    padding: 1rem 2rem;
    font-size: 1.125rem;
}

/* Upgrade In App Badge (Not a real button) */
.btn-badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0.75rem 1.5rem;
    border-radius: 6px;
    font-weight: 600;
    font-family: var(--font-body);
    font-size: 0.85rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    background: rgba(255, 255, 255, 0.03);
    color: var(--text-secondary);
    border: 1px dashed rgba(255, 255, 255, 0.2);
    cursor: default;
    /* Not clickable pointer */
    transition: var(--transition-smooth);
}

.btn-badge:hover {
    background: rgba(255, 255, 255, 0.08);
    color: var(--text-primary);
    border: 1px dashed rgba(255, 255, 255, 0.4);
}

/* Glass panel utility */
.glass-panel {
    background: var(--surface-color);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border: 1px solid var(--border-color);
    border-radius: 16px;
}

/* Navbar */
.navbar {
    position: fixed;
    top: 0;
    width: 100%;
    z-index: 9999;
    transition: var(--transition-smooth);
    padding: 1.5rem 0;
    backdrop-filter: blur(0px);
    background: rgba(5, 5, 5, 0);
    border-bottom: 1px solid transparent;
    pointer-events: none;
    /* Let the navbar container pass clicks through... */
}

.nav-container {
    max-width: 1280px;
    margin: 0 auto;
    padding: 0 2rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    pointer-events: auto;
    /* ...but catch them on the actual container/links */
}

.navbar.scrolled {
    padding: 1rem 0;
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    background: rgba(5, 5, 5, 0.8);
    border-bottom: 1px solid var(--border-color);
}

.nav-container {
    max-width: 1280px;
    margin: 0 auto;
    padding: 0 2rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.nav-logo {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    text-decoration: none;
    color: var(--text-primary);
    position: relative;
    z-index: 10001;
    /* Ensure link sits above the invisible bounding boxes */
    pointer-events: auto;
}

.logo-image {
    height: 140px;
    /* Increased further */
    width: auto;
    object-fit: contain;
    max-height: none;
    pointer-events: none;
    /* Let clicks pass through the invisible corners of this large image box */
}

.nav-logo .logo-text {
    font-family: var(--font-heading);
    font-weight: 800;
    font-size: 1.5rem;
    letter-spacing: -0.02em;
}

.nav-links {
    display: flex;
    gap: 2.5rem;
    list-style: none;
    position: relative;
    z-index: 10001;
    /* Ensure these are above the logo container's bounding box to be clickable */
}

.nav-links a {
    color: var(--text-secondary);
    text-decoration: none;
    font-weight: 500;
    font-size: 0.95rem;
    transition: var(--transition-fast);
}

.nav-links a:hover {
    color: var(--text-primary);
}

.nav-actions {
    display: flex;
    gap: 1rem;
    align-items: center;
}

/* Mobile Menu */
.mobile-menu-btn {
    display: none;
    flex-direction: column;
    gap: 6px;
    cursor: pointer;
    z-index: 1001;
}

.mobile-menu-btn .bar {
    width: 24px;
    height: 2px;
    background-color: var(--text-primary);
    transition: var(--transition-fast);
}

.mobile-nav {
    position: fixed;
    top: 0;
    right: -100%;
    width: 100%;
    height: 100vh;
    background: rgba(5, 5, 5, 0.98);
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    z-index: 999;
    transition: right var(--transition-smooth);
}

.mobile-nav.active {
    right: 0;
}

.mobile-nav-links {
    list-style: none;
    text-align: center;
    display: flex;
    flex-direction: column;
    gap: 2rem;
}

.mobile-nav-link {
    color: var(--text-primary);
    text-decoration: none;
    font-size: 1.5rem;
    font-weight: 600;
    font-family: var(--font-heading);
}

@media (max-width: 768px) {

    .nav-links,
    .nav-actions {
        display: none;
    }

    .mobile-menu-btn {
        display: flex;
    }
}

/* Hero Section */
.hero {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    padding: 8rem 2rem 4rem;
    position: relative;
    overflow: hidden;
}

.ai-core-canvas {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 0;
    pointer-events: none; /* Let clicks pass through to the UI */
    opacity: 0.8; /* Subtle blend into background */
}

.hero-content {
    max-width: 900px;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1.5rem;
    position: relative;
    z-index: 1;
}

.hero-subtitle {
    font-size: clamp(1.125rem, 2vw, 1.35rem);
    margin-bottom: 1rem;
}

.hero-ctas {
    display: flex;
    gap: 1.5rem;
    flex-wrap: wrap;
    justify-content: center;
    margin-top: 1rem;
}

/* Animations */
.animate-text {
    opacity: 0;
    transform: translateY(20px);
    animation: fadeUp 0.8s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

.animate-fade-in {
    opacity: 0;
    transform: translateY(20px);
    animation: fadeUp 0.8s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

.delay-1 {
    animation-delay: 0.2s;
}

.delay-2 {
    animation-delay: 0.4s;
}

@keyframes fadeUp {
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Prompt Hero Section */
.prompt-container {
    background: rgba(15, 23, 42, 0.8);
    border: 1px solid var(--border-color);
    border-radius: 12px;
    width: 100%;
    max-width: 800px;
    margin: 0 auto;
    overflow: hidden;
    box-shadow: var(--shadow-lg), 0 0 40px rgba(34, 197, 94, 0.1);
    backdrop-filter: blur(16px);
}

.prompt-header {
    background: rgba(255, 255, 255, 0.05);
    padding: 12px 16px;
    display: flex;
    align-items: center;
    gap: 8px;
    border-bottom: 1px solid var(--border-color);
}

.dot {
    width: 12px;
    height: 12px;
    border-radius: 50%;
}
.dot.red { background: #ef4444; }
.dot.yellow { background: #eab308; }
.dot.green { background: #22c55e; }

.prompt-title {
    margin-left: auto;
    margin-right: auto;
    color: var(--text-secondary);
    font-size: 0.85rem;
    font-family: var(--font-body);
    letter-spacing: 0.05em;
}

.prompt-body {
    padding: 24px;
    display: flex;
    align-items: center;
    gap: 12px;
    min-height: 120px;
}

.prompt-symbol {
    color: var(--primary-color);
    font-size: 2rem;
    font-weight: 700;
    font-family: var(--font-heading);
}

.type-text {
    font-size: clamp(1.5rem, 4vw, 3rem);
    text-align: left;
    margin: 0;
    line-height: 1.2;
}

.cursor {
    font-size: clamp(1.5rem, 4vw, 3rem);
    color: var(--primary-color);
    animation: blink 1s infinite;
}

@keyframes blink {
    0%, 100% { opacity: 1; }
    50% { opacity: 0; }
}

.glow-btn {
    box-shadow: 0 0 20px rgba(34, 197, 94, 0.4);
}

/* Pulse animation for play button & similar elements */
.pulse-effect {
    animation: pulseGlow 2s ease-in-out infinite;
}

@keyframes pulseGlow {
    0%, 100% {
        box-shadow: 0 0 0 0 rgba(255, 255, 255, 0.3);
    }
    50% {
        box-shadow: 0 0 0 16px rgba(255, 255, 255, 0);
    }
}

/* Demo Video Section */
.demo-section {
    padding: 6rem 2rem;
    position: relative;
    max-width: 1280px;
    margin: 0 auto;
}

.demo-header {
    text-align: center;
    margin-bottom: 4rem;
}

.demo-header p {
    margin: 0 auto;
}

.video-wrapper {
    position: relative;
    width: 100%;
    aspect-ratio: 16 / 9;
    max-width: 1000px;
    margin: 0 auto;
    overflow: hidden;
    cursor: pointer;
    transition: transform var(--transition-smooth), box-shadow var(--transition-smooth);
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.5);
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(145deg, rgba(20, 20, 20, 0.8) 0%, rgba(5, 5, 5, 0.9) 100%);
}

.video-wrapper:hover {
    transform: scale(1.01) translateY(-5px);
    box-shadow: 0 20px 50px rgba(255, 255, 255, 0.05), 0 0 40px rgba(255, 255, 255, 0.02);
    border-color: rgba(255, 255, 255, 0.2);
}

.video-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 1.5rem;
    z-index: 2;
    transition: opacity var(--transition-smooth);
    background: rgba(15, 15, 15, 0.6);
    backdrop-filter: blur(3px);
}

.video-wrapper:hover .video-overlay {
    opacity: 0.8;
}

.play-button {
    width: 80px;
    height: 80px;
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(8px);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: var(--transition-smooth);
}

.play-button svg {
    width: 32px;
    height: 32px;
    margin-left: 4px;
    /* Centering the triangle visually */
}

.video-wrapper:hover .play-button {
    background: rgba(255, 255, 255, 1);
    transform: scale(1.1);
}

.video-wrapper:hover .play-button svg path {
    fill: black;
}

.video-overlay span {
    font-family: var(--font-heading);
    font-weight: 600;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    font-size: 0.875rem;
    color: var(--text-secondary);
}

/* User's Future Video Tag styles */
.video-wrapper video {
    width: 100%;
    height: 100%;
    object-fit: cover;
    position: absolute;
    top: 0;
    left: 0;
}

/* Features Section - Bento Grid */
.features-section {
    padding: 6rem 2rem;
    max-width: 1280px;
    margin: 0 auto;
}

.features-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    grid-template-rows: auto auto;
    gap: 2rem;
}

/* Bento Item Sizing */
.feature-card {
    padding: 2.5rem;
    transition: var(--transition-smooth);
    background: rgba(30, 41, 59, 0.5); /* Slate 800 with opacity */
    backdrop-filter: blur(12px);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 20px;
    display: flex;
    flex-direction: column;
    justify-content: center;
}

/* Feature 1: Large Span */
.feature-card:nth-child(1) {
    grid-column: span 2;
}

/* Feature 2: Standard */
.feature-card:nth-child(2) {
    grid-column: span 1;
}

/* Feature 3: Full Width */
.feature-card:nth-child(3) {
    grid-column: span 3;
    display: flex;
    flex-direction: row;
    align-items: center;
    gap: 3rem;
}

.feature-card:hover {
    transform: translateY(-5px) scale(1.02);
    border-color: rgba(34, 197, 94, 0.3);
    background: rgba(30, 41, 59, 0.8);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.4), 0 0 20px rgba(34, 197, 94, 0.1);
}

.feature-icon {
    width: 56px;
    height: 56px;
    margin-bottom: 1.5rem;
    color: var(--primary-color);
    background: rgba(34, 197, 94, 0.1);
    border-radius: 16px;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 12px;
    border: 1px solid rgba(34, 197, 94, 0.2);
}

.feature-card h3 {
    font-size: 1.75rem;
    margin-bottom: 1rem;
    color: var(--text-primary);
}

@media (max-width: 1024px) {
    .features-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    .feature-card:nth-child(1) { grid-column: span 2; }
    .feature-card:nth-child(2) { grid-column: span 2; }
    .feature-card:nth-child(3) { 
        grid-column: span 2; 
        flex-direction: column;
        align-items: flex-start;
        gap: 1.5rem;
    }
}

@media (max-width: 768px) {
    .features-grid {
        grid-template-columns: 1fr;
    }
    .feature-card:nth-child(1),
    .feature-card:nth-child(2),
    .feature-card:nth-child(3) {
        grid-column: span 1;
    }
}

/* Footer */
.footer {
    border-top: 1px solid var(--border-color);
    padding: 4rem 2rem 2rem;
    margin-top: 4rem;
    background: rgba(0, 0, 0, 0.5);
}

.footer-content {
    max-width: 1280px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: 2fr 1fr;
    gap: 4rem;
    margin-bottom: 4rem;
}

.footer-brand .footer-logo {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    margin-bottom: 1rem;
    font-family: var(--font-heading);
    font-weight: 800;
    font-size: 1.25rem;
}

.logo-image-footer {
    height: 180px;
    /* Increased further */
    width: auto;
    object-fit: contain;
    max-height: none;
}

.footer-links {
    display: flex;
    gap: 4rem;
}

.link-column {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.link-column h4 {
    font-size: 1rem;
    margin-bottom: 0.5rem;
}

.link-column a {
    color: var(--text-secondary);
    text-decoration: none;
    transition: var(--transition-fast);
    font-size: 0.9rem;
}

.link-column a:hover {
    color: var(--text-primary);
}

.footer-bottom {
    max-width: 1280px;
    margin: 0 auto;
    padding-top: 2rem;
    border-top: 1px solid var(--border-color);
    text-align: center;
    font-size: 0.875rem;
}

@media (max-width: 768px) {
    .footer-content {
        grid-template-columns: 1fr;
        gap: 2rem;
    }

    .footer-links {
        flex-wrap: wrap;
        gap: 2rem;
    }
}

/* Scroll Animations */
.fade-in-scroll {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 0.8s ease, transform 0.8s ease;
}

.fade-in-scroll.visible {
    opacity: 1;
    transform: translateY(0);
}