/* Global Variables */
:root {
    --primary-color: #5b21b6;
    --primary-light: #7c3aed;
    --accent-color: #06b6d4;
    --accent-light: #22d3ee;
    --bg-dark: #0a0a0b;
    --bg-darker: #050506;
    --bg-card: #111113;
    --bg-card-hover: #18181b;
    --text-primary: #f4f4f5;
    --text-secondary: #a1a1aa;
    --text-muted: #71717a;
    --border-color: #27272a;
    --success-color: #10b981;
    --gradient-primary: linear-gradient(135deg, #5b21b6 0%, #7c3aed 50%, #06b6d4 100%);
    --gradient-text: linear-gradient(135deg, #7c3aed 0%, #06b6d4 100%);
    --shadow-card: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
    --shadow-hover: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
    --font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
}

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

html {
    scroll-behavior: smooth;
}

body {
    font-family: var(--font-family);
    background-color: var(--bg-dark);
    color: var(--text-primary);
    line-height: 1.6;
    overflow-x: hidden;
}

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

/* Typography */
h1, h2, h3, h4, h5, h6 {
    font-weight: 600;
    line-height: 1.2;
    margin-bottom: 1rem;
}

.section-title {
    font-size: clamp(2rem, 5vw, 3rem);
    text-align: center;
    margin-bottom: 3rem;
}

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

.text-accent {
    color: var(--accent-color);
}

/* Navigation */
.navbar {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 1000;
    background: rgba(10, 10, 11, 0.8);
    backdrop-filter: blur(10px);
    border-bottom: 1px solid var(--border-color);
    transition: all 0.3s ease;
}

.nav-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0.5rem 0;
}

.logo {
    display: flex;
    align-items: center;
    text-decoration: none;
    color: var(--text-primary);
    font-size: 1.5rem;
    font-weight: 700;
}

.logo img {
    height: 60px;
    width: auto;
    object-fit: contain;
}

.nav-cta {
    padding: 0.5rem 1.5rem;
    background: var(--gradient-primary);
    color: white;
    text-decoration: none;
    border-radius: 8px;
    font-weight: 500;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.nav-cta:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 25px -5px rgba(124, 58, 237, 0.3);
}

/* Hero Section */
.hero {
    position: relative;
    min-height: 100vh;
    display: flex;
    align-items: center;
    padding: 6rem 0 4rem;
    overflow: hidden;
}

.hero-background {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: -1;
}

.gradient-mesh {
    position: absolute;
    width: 150%;
    height: 150%;
    top: -25%;
    left: -25%;
    background: radial-gradient(circle at 20% 50%, rgba(124, 58, 237, 0.15) 0%, transparent 50%),
                radial-gradient(circle at 80% 80%, rgba(6, 182, 212, 0.1) 0%, transparent 50%);
    filter: blur(40px);
}

#particle-canvas {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    opacity: 0.5;
}

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

.hero-title {
    font-size: clamp(2.5rem, 8vw, 5rem);
    font-weight: 700;
    margin-bottom: 1rem;
    letter-spacing: -0.02em;
}

.hero-subtitle {
    font-size: clamp(1.5rem, 4vw, 2rem);
    color: var(--text-secondary);
    margin-bottom: 1.5rem;
}

.hero-description {
    font-size: 1.125rem;
    color: var(--text-secondary);
    margin-bottom: 3rem;
    max-width: 600px;
    margin-left: auto;
    margin-right: auto;
}

.hero-form {
    display: flex;
    gap: 1rem;
    max-width: 500px;
    margin: 0 auto;
}

.hero-form input {
    flex: 1;
    padding: 1rem 1.5rem;
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: 8px;
    color: var(--text-primary);
    font-size: 1rem;
    transition: border-color 0.2s ease;
}

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

/* Buttons */
.btn-primary {
    padding: 1rem 2rem;
    background: var(--gradient-primary);
    color: white;
    border: none;
    border-radius: 8px;
    font-size: 1rem;
    font-weight: 500;
    cursor: pointer;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
    white-space: nowrap;
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 25px -5px rgba(124, 58, 237, 0.3);
}

.btn-large {
    padding: 1.25rem 2.5rem;
    font-size: 1.125rem;
}

/* Problem Section */
.problem {
    padding: 5rem 0;
    background: var(--bg-darker);
}

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

.problem-card {
    background: var(--bg-card);
    padding: 2rem;
    border-radius: 12px;
    border: 1px solid var(--border-color);
    transition: all 0.3s ease;
}

.problem-card:hover {
    background: var(--bg-card-hover);
    transform: translateY(-4px);
    box-shadow: var(--shadow-hover);
}

.problem-icon {
    width: 48px;
    height: 48px;
    background: rgba(124, 58, 237, 0.1);
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 1rem;
    color: var(--primary-light);
}

.problem-card h3 {
    font-size: 1.25rem;
    margin-bottom: 0.5rem;
}

.problem-card p {
    color: var(--text-secondary);
    font-size: 0.9rem;
}

.stat-callout {
    text-align: center;
    padding: 2rem;
    background: var(--bg-card);
    border-radius: 12px;
    border: 1px solid var(--border-color);
}

.stat-number {
    font-size: 2.5rem;
    font-weight: 700;
    color: var(--accent-color);
}

.stat-highlight {
    color: var(--primary-light);
    font-weight: 600;
}

/* Solution Section */
.solution {
    padding: 5rem 0;
}

.solution-diagram {
    margin-bottom: 4rem;
}

.diagram-container {
    position: relative;
    max-width: 600px;
    margin: 0 auto;
    padding: 3rem 0;
}

.your-app {
    background: var(--bg-card);
    border: 2px solid var(--primary-light);
    border-radius: 12px;
    padding: 1rem 2rem;
    text-align: center;
    font-weight: 600;
    margin-bottom: 2rem;
}

.nextist-hub {
    background: var(--gradient-primary);
    border-radius: 16px;
    padding: 2rem;
    text-align: center;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1rem;
    margin-bottom: 2rem;
    box-shadow: 0 20px 40px -10px rgba(124, 58, 237, 0.3);
}

.nextist-hub img {
    height: 80px;
    width: auto;
    object-fit: contain;
}

.nextist-hub span {
    color: white;
    font-weight: 600;
    font-size: 1.25rem;
}

.providers {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(100px, 1fr));
    gap: 1rem;
}

.provider {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: 8px;
    padding: 0.75rem 1rem;
    text-align: center;
    font-size: 0.875rem;
    color: var(--text-secondary);
    transition: all 0.2s ease;
}

.provider:hover {
    border-color: var(--primary-light);
    color: var(--text-primary);
}

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

.feature-card {
    background: var(--bg-card);
    padding: 2rem;
    border-radius: 12px;
    border: 1px solid var(--border-color);
    transition: all 0.3s ease;
}

.feature-card:hover {
    background: var(--bg-card-hover);
    transform: translateY(-4px);
    box-shadow: var(--shadow-hover);
    border-color: var(--primary-light);
}

.feature-icon {
    width: 48px;
    height: 48px;
    background: rgba(6, 182, 212, 0.1);
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 1rem;
    color: var(--accent-color);
}

.feature-card h3 {
    font-size: 1.25rem;
    margin-bottom: 0.5rem;
}

.feature-card p {
    color: var(--text-secondary);
    font-size: 0.9rem;
}

/* Benefits Section */
.benefits {
    padding: 5rem 0;
    background: var(--bg-darker);
}

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

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

.benefit-stat {
    font-size: 3rem;
    font-weight: 700;
    background: var(--gradient-text);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    margin-bottom: 1rem;
}

.benefit-card h3 {
    font-size: 1.5rem;
    margin-bottom: 0.5rem;
}

.benefit-card p {
    color: var(--text-secondary);
}

/* How It Works Section */
.how-it-works {
    padding: 5rem 0;
}

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

.step {
    text-align: center;
    position: relative;
}

.step-number {
    width: 64px;
    height: 64px;
    background: var(--gradient-primary);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 1.5rem;
    font-size: 1.5rem;
    font-weight: 700;
    color: white;
}

.step h3 {
    font-size: 1.25rem;
    margin-bottom: 0.5rem;
}

.step p {
    color: var(--text-secondary);
}

/* Code Example */
.code-example {
    background: var(--bg-darker);
    border-radius: 12px;
    overflow: hidden;
    border: 1px solid var(--border-color);
}

.code-header {
    background: var(--bg-card);
    padding: 1rem 1.5rem;
    display: flex;
    align-items: center;
    justify-content: space-between;
    border-bottom: 1px solid var(--border-color);
}

.code-dots {
    display: flex;
    gap: 0.5rem;
}

.code-dots span {
    width: 12px;
    height: 12px;
    border-radius: 50%;
    background: var(--border-color);
}

.code-dots span:nth-child(1) { background: #ef4444; }
.code-dots span:nth-child(2) { background: #f59e0b; }
.code-dots span:nth-child(3) { background: #10b981; }

.code-title {
    color: var(--text-secondary);
    font-size: 0.875rem;
}

.code-comparison {
    display: grid;
    grid-template-columns: 1fr 1fr;
}

.code-before, .code-after {
    padding: 2rem;
    position: relative;
}

.code-before {
    border-right: 1px solid var(--border-color);
}

.code-label {
    position: absolute;
    top: 1rem;
    right: 1rem;
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: var(--text-muted);
}

.code-after .code-label {
    color: var(--success-color);
}

pre {
    font-family: 'Courier New', monospace;
    font-size: 0.875rem;
    line-height: 1.6;
    overflow-x: auto;
}

code {
    color: var(--text-primary);
}

.comment { color: var(--text-muted); }
.keyword { color: var(--primary-light); }
.function { color: var(--accent-color); }
.string { color: #10b981; }
.number { color: #f59e0b; }

/* Security Section */
.security {
    padding: 5rem 0;
    background: var(--bg-darker);
}

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

.badge {
    text-align: center;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1rem;
    color: var(--primary-light);
}

.badge span {
    font-size: 0.875rem;
    font-weight: 500;
}

.security-note {
    text-align: center;
    color: var(--text-secondary);
    max-width: 600px;
    margin: 0 auto;
}

/* Contact Section */
.contact {
    padding: 5rem 0;
}

.contact-subtitle {
    text-align: center;
    color: var(--text-secondary);
    font-size: 1.125rem;
    margin-bottom: 3rem;
}

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

.form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1rem;
    margin-bottom: 1rem;
}

.form-group {
    display: flex;
    flex-direction: column;
}

.form-group label {
    margin-bottom: 0.5rem;
    color: var(--text-secondary);
    font-size: 0.875rem;
}

.form-group input,
.form-group select,
.form-group textarea {
    padding: 0.75rem 1rem;
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: 8px;
    color: var(--text-primary);
    font-size: 1rem;
    font-family: inherit;
    transition: border-color 0.2s ease;
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
    outline: none;
    border-color: var(--primary-light);
}

.form-group textarea {
    resize: vertical;
}

.form-success {
    text-align: center;
    padding: 3rem;
    background: var(--bg-card);
    border-radius: 12px;
    border: 1px solid var(--success-color);
}

.form-success svg {
    color: var(--success-color);
    margin-bottom: 1rem;
}

.form-success h3 {
    font-size: 1.5rem;
    margin-bottom: 0.5rem;
}

.form-success p {
    color: var(--text-secondary);
}

/* Footer */
.footer {
    padding: 3rem 0 2rem;
    background: var(--bg-darker);
    border-top: 1px solid var(--border-color);
}

.footer-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 2rem;
}

.footer-left img {
    height: 80px;
    width: auto;
    object-fit: contain;
    margin-bottom: 1rem;
}

.footer-left p {
    color: var(--text-secondary);
    margin-top: 0.5rem;
}

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

.footer-right a {
    color: var(--text-secondary);
    text-decoration: none;
    transition: color 0.2s ease;
}

.footer-right a:hover {
    color: var(--primary-light);
}

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

/* Responsive Design */
@media (max-width: 768px) {
    .hero-form {
        flex-direction: column;
    }
    
    .form-row {
        grid-template-columns: 1fr;
    }
    
    .code-comparison {
        grid-template-columns: 1fr;
    }
    
    .code-before {
        border-right: none;
        border-bottom: 1px solid var(--border-color);
    }
    
    .footer-content {
        flex-direction: column;
        gap: 2rem;
        text-align: center;
    }
    
    .problem-grid,
    .features-grid {
        grid-template-columns: 1fr;
    }
    
    .steps {
        gap: 2rem;
    }
}

/* Animations */
@keyframes float {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-10px); }
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(20px); }
    to { opacity: 1; transform: translateY(0); }
}

.hero-content {
    animation: fadeIn 1s ease-out;
}

/* Accessibility */
:focus-visible {
    outline: 2px solid var(--primary-light);
    outline-offset: 2px;
}

/* Utility Classes */
.visually-hidden {
    position: absolute;
    width: 1px;
    height: 1px;
    margin: -1px;
    padding: 0;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}