/* Premium Color Scheme with Sophisticated Dark Theme */
:root {
    --bg-primary: #0A0A0B;
    --bg-surface: #111113;
    --bg-elevated: #1A1A1D;
    --accent-primary: #FF6B35;
    --accent-secondary: #4ECDC4;
    --accent-tertiary: #FFE66D;
    --text-primary: #F5F5F7;
    --text-secondary: #A1A1A6;
    --text-muted: #6E6E73;
    --highlight: #F7931E;
    --border-subtle: rgba(255, 255, 255, 0.06);
    --gradient: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    --gradient-accent: linear-gradient(135deg, #FF6B35 0%, #F7931E 100%);
    --shadow-sm: 0 2px 4px rgba(0, 0, 0, 0.1);
    --shadow-md: 0 4px 6px rgba(0, 0, 0, 0.15);
    --shadow-lg: 0 10px 15px rgba(0, 0, 0, 0.2);
    --shadow-xl: 0 20px 25px rgba(0, 0, 0, 0.25);
}

/* Reset and Base Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    background-color: var(--bg-primary);
    color: var(--text-primary);
    line-height: 1.7;
    overflow-x: hidden;
    font-weight: 400;
    letter-spacing: -0.011em;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

a {
    color: var(--accent-secondary);
    text-decoration: none;
    transition: all 0.3s ease;
}

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

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

/* Navigation */
.navbar {
    background-color: rgba(10, 10, 11, 0.8);
    backdrop-filter: blur(20px) saturate(180%);
    -webkit-backdrop-filter: blur(20px) saturate(180%);
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 1000;
    padding: 1.2rem 0;
    border-bottom: 1px solid var(--border-subtle);
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: 0 1px 0 0 rgba(255, 255, 255, 0.05);
}

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

.nav-brand a {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    font-size: 1.4rem;
    font-weight: 700;
    color: var(--text-primary);
    letter-spacing: -0.02em;
    transition: opacity 0.3s ease;
}

.nav-brand a:hover {
    opacity: 0.8;
}

.nav-logo {
    height: 32px;
    width: auto;
    display: block;
}

.nav-menu {
    display: flex;
    list-style: none;
    gap: 2rem;
    align-items: center;
}

.nav-menu a {
    color: var(--text-secondary);
    font-weight: 500;
    font-size: 0.95rem;
    position: relative;
    padding: 0.5rem 0;
    transition: color 0.3s ease;
}

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

.nav-menu a::after {
    content: '';
    position: absolute;
    bottom: -2px;
    left: 0;
    width: 0;
    height: 1px;
    background: var(--gradient-accent);
    transition: width 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

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

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

.nav-toggle span {
    width: 25px;
    height: 2px;
    background: var(--text-primary);
    transition: all 0.3s ease;
}

/* Hero Section */
.hero {
    position: relative;
    width: 100%;
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 120px 0 80px;
    background: radial-gradient(ellipse at top, rgba(102, 126, 234, 0.05), transparent 50%),
                radial-gradient(ellipse at bottom right, rgba(118, 75, 162, 0.05), transparent 50%),
                var(--bg-primary);
    overflow: hidden;
}

.hero::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: url('data:image/svg+xml,<svg width="60" height="60" viewBox="0 0 60 60" xmlns="http://www.w3.org/2000/svg"><g fill="none" fill-rule="evenodd"><g fill="%23ffffff" fill-opacity="0.02"><path d="M36 34v-4h-2v4h-4v2h4v4h2v-4h4v-2h-4zm0-30V0h-2v4h-4v2h4v4h2V6h4V4h-4zM6 34v-4H4v4H0v2h4v4h2v-4h4v-2H6zM6 4V0H4v4H0v2h4v4h2V6h4V4H6z"/></g></g></svg>') repeat;
    opacity: 0.5;
}

.hero-content {
    text-align: center;
    max-width: 800px;
    margin: 0 auto;
}

.hero-title {
    font-size: clamp(3rem, 6vw, 5rem);
    font-weight: 800;
    margin-bottom: 1.5rem;
    line-height: 1.1;
    letter-spacing: -0.03em;
}

.gradient-text {
    background: var(--gradient);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.hero-subtitle {
    font-size: 1.25rem;
    color: var(--text-secondary);
    margin-bottom: 3rem;
    font-weight: 400;
    max-width: 600px;
    margin-left: auto;
    margin-right: auto;
    line-height: 1.6;
}

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

/* Buttons */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0.875rem 2rem;
    border-radius: 12px;
    font-weight: 600;
    font-size: 0.95rem;
    letter-spacing: -0.01em;
    transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
    overflow: hidden;
    text-transform: none;
    white-space: nowrap;
}

.btn-primary {
    background: var(--gradient-accent);
    color: #FFFFFF;
    box-shadow: var(--shadow-md), inset 0 1px 0 rgba(255, 255, 255, 0.15);
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.btn-primary:hover {
    transform: translateY(-1px);
    box-shadow: var(--shadow-lg), inset 0 1px 0 rgba(255, 255, 255, 0.2);
    filter: brightness(1.1);
    color: #FFFFFF;
}

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

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

.btn-large {
    padding: 1.2rem 3rem;
    font-size: 1.1rem;
}

/* Section Styles */
section {
    padding: 5rem 0;
}

.section-title {
    font-size: clamp(2.5rem, 4vw, 3.5rem);
    text-align: center;
    margin-bottom: 4rem;
    color: var(--text-primary);
    font-weight: 700;
    letter-spacing: -0.03em;
    position: relative;
}

.section-title::after {
    content: '';
    position: absolute;
    bottom: -1rem;
    left: 50%;
    transform: translateX(-50%);
    width: 60px;
    height: 3px;
    background: var(--gradient-accent);
    border-radius: 2px;
}

/* Content wrapper for sections after hero */
.content-wrapper {
    position: relative;
    background: var(--bg-primary);
}

/* Features Section */
.features {
    background: var(--bg-primary);
    position: relative;
    z-index: 2;
    padding: 6rem 0;
}

.features-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 2.5rem;
    max-width: 1100px;
    margin: 0 auto;
}

@media (max-width: 768px) {
    .features-grid {
        grid-template-columns: 1fr;
    }
}

.feature-card {
    background: var(--bg-surface);
    padding: 3rem;
    border-radius: 24px;
    text-align: center;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    border: 1px solid var(--border-subtle);
    min-height: 300px;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    align-items: center;
    position: relative;
    overflow: hidden;
}

.feature-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 1px;
    background: var(--gradient);
    opacity: 0;
    transition: opacity 0.4s ease;
}

.feature-card:hover {
    transform: translateY(-8px);
    border-color: rgba(255, 255, 255, 0.1);
    box-shadow: var(--shadow-xl), 0 0 0 1px rgba(255, 255, 255, 0.05);
}

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

.feature-icon {
    font-size: 2.5rem;
    margin-bottom: 2rem;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 80px;
    height: 80px;
    background: var(--gradient);
    border-radius: 20px;
    box-shadow: var(--shadow-md);
}

.feature-card h3 {
    font-size: 1.3rem;
    margin-bottom: 1.2rem;
    color: var(--text-primary);
    font-weight: 600;
    letter-spacing: -0.02em;
}

.feature-card p {
    color: var(--text-secondary);
    line-height: 1.7;
    flex: 1;
    display: flex;
    align-items: center;
    text-align: center;
    font-size: 0.95rem;
}

/* Demo Section */
.demo {
    background: var(--bg-surface);
    padding: 6rem 0;
}

.demo-description {
    text-align: center;
    color: var(--text-secondary);
    font-size: 1.1rem;
    margin-bottom: 3rem;
    max-width: 700px;
    margin-left: auto;
    margin-right: auto;
    line-height: 1.7;
}

.demo-container {
    background: var(--bg-elevated);
    border-radius: 24px;
    overflow: hidden;
    box-shadow: var(--shadow-xl), inset 0 0 0 1px var(--border-subtle);
    border: 1px solid var(--border-subtle);
    max-width: 1200px;
    margin: 0 auto;
}

.demo-container iframe {
    display: block;
    border: none;
}

/* Research Section */
.research {
    background: var(--bg-primary);
    padding: 6rem 0;
    position: relative;
}

.research::before {
    content: '';
    position: absolute;
    top: -100px;
    left: 0;
    right: 0;
    height: 200px;
    background: linear-gradient(180deg, transparent, var(--bg-primary));
    pointer-events: none;
}

.research-card {
    background: var(--bg-surface);
    padding: 4rem;
    border-radius: 32px;
    box-shadow: var(--shadow-xl);
    border: 1px solid var(--border-subtle);
    position: relative;
    overflow: hidden;
}

.research-card::before {
    content: '';
    position: absolute;
    top: -50%;
    right: -50%;
    width: 100%;
    height: 100%;
    background: radial-gradient(circle, rgba(102, 126, 234, 0.05), transparent);
    pointer-events: none;
}

.research-card h3 {
    font-size: 2.2rem;
    margin-bottom: 2rem;
    color: var(--text-primary);
    font-weight: 700;
    letter-spacing: -0.02em;
}

.research-card h4 {
    font-size: 1.1rem;
    margin: 3rem 0 1.5rem;
    color: var(--text-primary);
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    opacity: 0.8;
}

.research-card ul {
    list-style: none;
    padding-left: 0;
}

.research-card li {
    padding: 1rem 0;
    padding-left: 2.5rem;
    position: relative;
    color: var(--text-secondary);
    line-height: 1.7;
    transition: all 0.3s ease;
}

.research-card li:hover {
    color: var(--text-primary);
    transform: translateX(5px);
}

.research-card li::before {
    content: '';
    position: absolute;
    left: 0;
    top: 50%;
    transform: translateY(-50%);
    width: 6px;
    height: 6px;
    background: var(--gradient-accent);
    border-radius: 50%;
    transition: all 0.3s ease;
}

.research-card li:hover::before {
    width: 20px;
    border-radius: 3px;
}

.research-stats {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 2rem;
    margin: 4rem 0;
    text-align: center;
}

@media (max-width: 768px) {
    .research-stats {
        grid-template-columns: 1fr;
        gap: 1.5rem;
    }
}

.stat {
    padding: 2.5rem 2rem;
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.03), rgba(255, 255, 255, 0.01));
    backdrop-filter: blur(10px);
    border-radius: 20px;
    border: 1px solid var(--border-subtle);
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.stat::before {
    content: '';
    position: absolute;
    top: -2px;
    left: -2px;
    right: -2px;
    bottom: -2px;
    background: var(--gradient);
    border-radius: 20px;
    opacity: 0;
    z-index: -1;
    transition: opacity 0.3s ease;
}

.stat:hover {
    transform: translateY(-5px);
    border-color: transparent;
}

.stat:hover::before {
    opacity: 0.3;
}

.stat-number {
    font-size: 3rem;
    font-weight: 800;
    background: var(--gradient-accent);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    letter-spacing: -0.02em;
    line-height: 1;
    margin-bottom: 0.8rem;
}

.stat-label {
    color: var(--text-secondary);
    font-size: 0.9rem;
    font-weight: 500;
    letter-spacing: 0.02em;
}

.research-card .btn {
    display: inline-block;
    margin: 2rem auto 0;
}

.research-card {
    text-align: center;
}

.research-card h3,
.research-card h4,
.research-card p,
.research-card ul {
    text-align: left;
}

/* Documentation Section */
.documentation {
    background: var(--bg-surface);
    padding: 6rem 0;
}

.docs-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(450px, 1fr));
    gap: 3rem;
    margin-bottom: 4rem;
    max-width: 1100px;
    margin-left: auto;
    margin-right: auto;
}

.doc-card {
    background: var(--bg-primary);
    padding: 2.5rem;
    border-radius: 24px;
    border: 1px solid var(--border-subtle);
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.doc-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-lg);
    border-color: rgba(255, 255, 255, 0.1);
}

.doc-card h3 {
    color: var(--text-primary);
    margin-bottom: 2rem;
    font-size: 1.4rem;
    font-weight: 600;
    letter-spacing: -0.02em;
}

pre {
    background: var(--bg-elevated);
    padding: 2rem;
    border-radius: 16px;
    overflow-x: auto;
    border: 1px solid var(--border-subtle);
    box-shadow: inset 0 2px 4px rgba(0, 0, 0, 0.1);
    position: relative;
}

pre::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 40px;
    background: linear-gradient(180deg, rgba(0, 0, 0, 0.1), transparent);
    border-radius: 16px 16px 0 0;
    pointer-events: none;
}

code {
    color: var(--text-secondary);
    font-family: 'SF Mono', 'Monaco', 'Inconsolata', 'Fira Code', monospace;
    font-size: 0.875rem;
    line-height: 1.6;
}

.docs-links {
    text-align: center;
    display: flex;
    gap: 1.5rem;
    justify-content: center;
    flex-wrap: wrap;
}

/* Use Cases Section */
.use-cases {
    background: var(--bg-primary);
    padding: 6rem 0;
}

.use-cases-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 3rem;
    max-width: 1200px;
    margin: 0 auto;
}

.use-case {
    background: var(--bg-surface);
    padding: 3rem;
    border-radius: 24px;
    border: 1px solid var(--border-subtle);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
    overflow: hidden;
}

.use-case::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 3px;
    background: var(--gradient);
    transform: translateY(-100%);
    transition: transform 0.3s ease;
}

.use-case:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-lg);
    border-color: transparent;
}

.use-case:hover::before {
    transform: translateY(0);
}

.use-case h3 {
    color: var(--text-primary);
    margin-bottom: 1.2rem;
    font-size: 1.25rem;
    font-weight: 600;
    letter-spacing: -0.02em;
}

.use-case p {
    color: var(--text-secondary);
    line-height: 1.7;
    font-size: 0.95rem;
}

/* CTA Section */
.cta {
    background: var(--bg-surface);
    padding: 8rem 0;
    text-align: center;
    position: relative;
    overflow: hidden;
}

.cta::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 800px;
    height: 800px;
    background: radial-gradient(circle, rgba(102, 126, 234, 0.1), transparent 60%);
    pointer-events: none;
}

.cta h2 {
    font-size: clamp(2.5rem, 5vw, 3.5rem);
    margin-bottom: 1.5rem;
    font-weight: 700;
    letter-spacing: -0.03em;
    color: var(--text-primary);
}

.cta p {
    font-size: 1.15rem;
    color: var(--text-secondary);
    margin-bottom: 3rem;
    max-width: 600px;
    margin-left: auto;
    margin-right: auto;
    line-height: 1.7;
}

.cta-buttons {
    display: flex;
    gap: 1.5rem;
    justify-content: center;
    flex-wrap: wrap;
}

/* Footer */
.footer {
    background: var(--bg-elevated);
    padding: 4rem 0 2rem;
    border-top: 1px solid var(--border-subtle);
    position: relative;
}

.footer::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 1px;
    background: linear-gradient(90deg, transparent, var(--accent-primary), var(--accent-secondary), transparent);
    opacity: 0.3;
}

.footer-content {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 3rem;
    margin-bottom: 2rem;
}

.footer-section h4 {
    color: var(--text-primary);
    margin-bottom: 1.5rem;
    font-size: 1.1rem;
    font-weight: 600;
    letter-spacing: -0.01em;
}

.footer-section ul {
    list-style: none;
}

.footer-section li {
    padding: 0.6rem 0;
}

.footer-section a {
    color: var(--text-secondary);
    transition: all 0.2s ease;
    font-size: 0.95rem;
}

.footer-section a:hover {
    color: var(--text-primary);
    transform: translateX(3px);
}

.footer-bottom {
    text-align: center;
    padding-top: 3rem;
    margin-top: 3rem;
    border-top: 1px solid var(--border-subtle);
    color: var(--text-muted);
    font-size: 0.9rem;
}

/* Responsive Design */
@media (max-width: 768px) {
    .hero {
        padding: 80px 20px 50px;
    }
    
    .content-wrapper {
        margin-top: 100vh;
    }
    .nav-menu {
        display: none;
        position: absolute;
        top: 100%;
        left: 0;
        right: 0;
        background: var(--bg-surface);
        flex-direction: column;
        padding: 2rem;
        box-shadow: 0 10px 30px rgba(0, 0, 0, 0.5);
    }
    
    .nav-menu.active {
        display: flex;
    }
    
    .nav-toggle {
        display: flex;
    }
    
    .hero-buttons {
        flex-direction: column;
        align-items: center;
    }
    
    .docs-grid {
        grid-template-columns: 1fr;
    }
    
    pre {
        font-size: 0.8rem;
    }
}

/* Loading Animation */
@keyframes pulse {
    0% {
        box-shadow: 0 0 0 0 rgba(255, 61, 0, 0.4);
    }
    70% {
        box-shadow: 0 0 0 20px rgba(255, 61, 0, 0);
    }
    100% {
        box-shadow: 0 0 0 0 rgba(255, 61, 0, 0);
    }
}

/* Scroll Progress Bar */
.scroll-progress {
    position: fixed;
    top: 0;
    left: 0;
    height: 2px;
    background: var(--gradient-accent);
    z-index: 1001;
    transition: width 0.2s ease;
    box-shadow: 0 0 10px rgba(255, 107, 53, 0.5);
}

/* Smooth Fade-in Animation */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.hero-content > * {
    animation: fadeInUp 0.8s ease-out forwards;
}

.hero-title {
    animation-delay: 0.1s;
}

.hero-subtitle {
    animation-delay: 0.2s;
}

.hero-buttons {
    animation-delay: 0.3s;
}

/* Hover transitions for all interactive elements */
* {
    transition-timing-function: cubic-bezier(0.4, 0, 0.2, 1);
}

/* Media Queries for Use Cases Grid */
@media (max-width: 768px) {
    .use-cases-grid {
        grid-template-columns: 1fr;
        gap: 2rem;
    }
}