/* CSS Variables - Matching the program's color scheme */
:root {
    --bg-primary: #09090b;
    --bg-secondary: #0c0c0e;
    --bg-tertiary: #18181b;
    --bg-elevated: #1f1f23;
    --bg-card: rgba(17, 17, 19, 0.8);
    --bg-card-hover: rgba(28, 28, 31, 0.9);
    
    --text-primary: #fafafa;
    --text-secondary: #a1a1aa;
    --text-muted: #71717a;
    
    --accent: #6366f1;
    --accent-hover: #818cf8;
    --accent-muted: rgba(99, 102, 241, 0.15);
    --accent-gradient: linear-gradient(135deg, #6366f1 0%, #818cf8 50%, #a855f7 100%);
    --accent-glow: rgba(99, 102, 241, 0.4);
    
    --border-color: #27272a;
    --border-subtle: #1f1f23;
    --border-highlight: rgba(255, 255, 255, 0.15);
    
    --success: #22c55e;
    --success-muted: rgba(34, 197, 94, 0.15);
    
    --radius-sm: 6px;
    --radius-md: 8px;
    --radius-lg: 12px;
    --radius-xl: 16px;
    
    --shadow-sm: 0 1px 2px rgba(0, 0, 0, 0.4);
    --shadow-md: 0 4px 12px rgba(0, 0, 0, 0.3);
    --shadow-lg: 0 8px 24px rgba(0, 0, 0, 0.4);
    --shadow-glow: 0 0 40px var(--accent-glow);
}

/* Reset & Base */
*, *::before, *::after {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'DM Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    background: var(--bg-primary);
    color: var(--text-primary);
    line-height: 1.6;
    overflow-x: hidden;
    min-height: 100vh;
    font-size: 14px;
    -webkit-font-smoothing: antialiased;
}

/* Background Effects */
.background-effects {
    position: fixed;
    inset: 0;
    pointer-events: none;
    z-index: 0;
    overflow: hidden;
}

.grid-pattern {
    position: absolute;
    inset: 0;
    background-image: 
        linear-gradient(rgba(255, 255, 255, 0.02) 1px, transparent 1px),
        linear-gradient(90deg, rgba(255, 255, 255, 0.02) 1px, transparent 1px);
    background-size: 60px 60px;
    mask-image: radial-gradient(ellipse at 50% 0%, black 0%, transparent 70%);
}

.glow {
    position: absolute;
    border-radius: 50%;
    filter: blur(100px);
    opacity: 0.5;
}

.glow-1 {
    width: 500px;
    height: 500px;
    background: var(--accent);
    top: -200px;
    left: -100px;
    opacity: 0.12;
    animation: float 20s ease-in-out infinite;
}

.glow-2 {
    width: 400px;
    height: 400px;
    background: var(--accent-hover);
    top: 30%;
    right: -150px;
    opacity: 0.08;
    animation: float 25s ease-in-out infinite reverse;
}

.glow-3 {
    width: 350px;
    height: 350px;
    background: #a855f7;
    bottom: 10%;
    left: 20%;
    opacity: 0.06;
    animation: float 30s ease-in-out infinite;
}

@keyframes float {
    0%, 100% { transform: translate(0, 0) scale(1); }
    25% { transform: translate(30px, -30px) scale(1.05); }
    50% { transform: translate(-20px, 20px) scale(0.95); }
    75% { transform: translate(20px, 30px) scale(1.02); }
}

.floating-shapes {
    position: absolute;
    inset: 0;
}

.shape {
    position: absolute;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    opacity: 0.2;
}

.shape-1 {
    width: 80px;
    height: 80px;
    top: 15%;
    left: 10%;
    transform: rotate(45deg);
    animation: rotate 40s linear infinite;
}

.shape-2 {
    width: 60px;
    height: 60px;
    top: 60%;
    right: 15%;
    transform: rotate(20deg);
    animation: rotate 50s linear infinite reverse;
}

.shape-3 {
    width: 100px;
    height: 100px;
    bottom: 20%;
    left: 5%;
    transform: rotate(-15deg);
    animation: rotate 60s linear infinite;
}

@keyframes rotate {
    from { transform: rotate(0deg); }
    to { transform: rotate(360deg); }
}

/* Navbar */
.navbar {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 1000;
    padding: 1rem 2rem;
    background: transparent;
    border-bottom: 1px solid transparent;
    transition: background 0.3s ease, border-color 0.3s ease, padding 0.3s ease;
}

.navbar.scrolled {
    background: rgba(9, 9, 11, 0.95);
    backdrop-filter: blur(20px);
    border-bottom-color: var(--border-color);
    padding: 0.75rem 2rem;
}

.nav-container {
    max-width: 1200px;
    margin: 0 auto;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    text-decoration: none;
    color: var(--text-primary);
    font-weight: 600;
    font-size: 1.15rem;
}

.logo-icon {
    width: 28px;
    height: 28px;
    object-fit: contain;
}

.nav-links {
    display: flex;
    align-items: center;
    gap: 2rem;
}

.nav-links a {
    text-decoration: none;
    color: var(--text-secondary);
    font-weight: 500;
    font-size: 14px;
    transition: color 0.2s ease;
}

.nav-links a:hover {
    color: var(--text-primary);
}

.nav-btn {
    padding: 0.6rem 1.5rem;
    background: var(--accent);
    border-radius: var(--radius-md);
    color: white !important;
    transition: all 0.2s ease;
}

.nav-btn:hover {
    background: var(--accent-hover);
}

/* Hero Section */
.hero {
    position: relative;
    z-index: 1;
    min-height: 100vh;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
    align-items: center;
    max-width: 1400px;
    margin: 0 auto;
    padding: 8rem 2rem 4rem;
}

.hero-content {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.version-badge {
    display: inline-flex;
    align-items: center;
    gap: 0.75rem;
    padding: 0.5rem 1rem;
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: 100px;
    font-size: 0.8rem;
    color: var(--text-secondary);
    width: fit-content;
    backdrop-filter: blur(10px);
}

.pulse {
    width: 8px;
    height: 8px;
    background: var(--success);
    border-radius: 50%;
    animation: pulse 2s ease-in-out infinite;
}

@keyframes pulse {
    0%, 100% { opacity: 1; transform: scale(1); }
    50% { opacity: 0.5; transform: scale(1.2); }
}

h1 {
    font-size: clamp(2.5rem, 5vw, 3.5rem);
    font-weight: 700;
    line-height: 1.1;
    letter-spacing: -0.02em;
}

.gradient-text {
    display: block;
    background: var(--accent-gradient);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.hero-description {
    font-size: 1rem;
    color: var(--text-secondary);
    max-width: 500px;
    line-height: 1.7;
}

.hero-actions {
    display: flex;
    gap: 1rem;
    margin-top: 1rem;
}

/* Buttons */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    padding: 0.875rem 1.75rem;
    border-radius: var(--radius-md);
    font-weight: 500;
    font-size: 0.9rem;
    text-decoration: none;
    cursor: pointer;
    transition: all 0.2s ease;
    border: none;
    font-family: inherit;
}

.btn-primary {
    background: var(--accent);
    color: white;
    box-shadow: var(--shadow-md);
}

.btn-primary:hover {
    background: var(--accent-hover);
    transform: translateY(-2px);
    box-shadow: var(--shadow-lg), 0 0 30px var(--accent-glow);
}

.btn-ghost {
    background: transparent;
    color: var(--text-secondary);
    border: 1px solid var(--border-color);
}

.btn-ghost:hover {
    background: var(--bg-card);
    color: var(--text-primary);
    border-color: var(--border-highlight);
}

.btn-lg {
    padding: 1rem 2rem;
    font-size: 0.95rem;
}

.btn-xl {
    padding: 1.25rem 2.5rem;
    font-size: 1rem;
    border-radius: var(--radius-lg);
}

.btn-badge {
    background: rgba(255, 255, 255, 0.2);
    padding: 0.25rem 0.75rem;
    border-radius: 100px;
    font-size: 0.7rem;
    margin-left: 0.5rem;
}

/* Hero Stats */
.hero-stats {
    display: flex;
    align-items: center;
    gap: 2rem;
    margin-top: 2rem;
    padding-top: 2rem;
    border-top: 1px solid var(--border-color);
}

.stat {
    display: flex;
    flex-direction: column;
    gap: 0.25rem;
}

.stat-number {
    font-size: 1.5rem;
    font-weight: 700;
    font-family: 'JetBrains Mono', monospace;
    background: var(--accent-gradient);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.stat-label {
    font-size: 0.8rem;
    color: var(--text-muted);
}

.stat-divider {
    width: 1px;
    height: 40px;
    background: var(--border-color);
}

/* App Preview */
.hero-visual {
    display: flex;
    justify-content: center;
    align-items: center;
    perspective: 1000px;
}

.app-preview {
    width: 100%;
    max-width: 520px;
    background: var(--bg-secondary);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-xl);
    overflow: hidden;
    box-shadow: var(--shadow-lg), var(--shadow-glow);
    transform: rotateY(-5deg) rotateX(5deg);
    transition: transform 0.5s ease;
}

.app-preview:hover {
    transform: rotateY(0deg) rotateX(0deg);
}

.preview-header {
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: 1rem 1.25rem;
    background: var(--bg-tertiary);
    border-bottom: 1px solid var(--border-color);
}

.preview-dots {
    display: flex;
    gap: 0.5rem;
}

.dot {
    width: 12px;
    height: 12px;
    border-radius: 50%;
}

.dot.red { background: #ff5f57; }
.dot.yellow { background: #febc2e; }
.dot.green { background: #28c840; }

.preview-title {
    font-size: 0.85rem;
    color: var(--text-muted);
    font-weight: 500;
}

.preview-content {
    display: flex;
    min-height: 300px;
}

.preview-sidebar {
    width: 60px;
    background: var(--bg-tertiary);
    padding: 1rem 0.75rem;
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
    border-right: 1px solid var(--border-color);
}

.sidebar-item {
    height: 36px;
    background: var(--bg-card);
    border-radius: var(--radius-sm);
    transition: all 0.2s ease;
}

.sidebar-item.active {
    background: var(--accent);
}

.preview-main {
    flex: 1;
    padding: 1.25rem;
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.preview-input {
    height: 44px;
    background: var(--bg-tertiary);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
}

.preview-card {
    flex: 1;
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    padding: 1rem;
    display: flex;
    gap: 1rem;
}

.preview-thumbnail {
    width: 120px;
    height: 80px;
    background: linear-gradient(135deg, var(--bg-tertiary), var(--accent));
    border-radius: var(--radius-sm);
    opacity: 0.7;
}

.preview-info {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.preview-line {
    height: 12px;
    background: var(--bg-tertiary);
    border-radius: 4px;
}

.preview-line.long { width: 90%; }
.preview-line.short { width: 60%; }

.preview-qualities {
    display: flex;
    gap: 0.5rem;
    margin-top: auto;
}

.quality {
    padding: 0.25rem 0.75rem;
    background: var(--bg-tertiary);
    border-radius: 4px;
    font-size: 0.7rem;
    color: var(--text-muted);
    font-family: 'JetBrains Mono', monospace;
}

.quality.active {
    background: var(--accent);
    color: white;
}

.preview-button {
    height: 32px;
    background: var(--accent);
    border-radius: var(--radius-sm);
    margin-top: 0.5rem;
}

/* Sections */
section {
    position: relative;
    z-index: 1;
}

.section-header {
    text-align: center;
    max-width: 600px;
    margin: 0 auto 4rem;
}

.section-tag {
    display: inline-block;
    padding: 0.5rem 1rem;
    background: var(--accent-muted);
    border: 1px solid rgba(99, 102, 241, 0.3);
    border-radius: 100px;
    font-size: 0.8rem;
    color: var(--accent-hover);
    margin-bottom: 1rem;
    font-weight: 500;
}

.section-header h2 {
    font-size: clamp(1.75rem, 4vw, 2.5rem);
    font-weight: 700;
    margin-bottom: 1rem;
    letter-spacing: -0.02em;
}

.section-header p {
    color: var(--text-secondary);
    font-size: 1rem;
}

/* Features */
.features {
    padding: 6rem 2rem;
    max-width: 1200px;
    margin: 0 auto;
}

.features-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 1.5rem;
}

.feature-card {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    padding: 2rem;
    transition: all 0.3s ease;
    opacity: 0;
    transform: translateY(20px);
}

.feature-card.animate-in {
    opacity: 1;
    transform: translateY(0);
}

.feature-card:hover {
    background: var(--bg-card-hover);
    border-color: var(--border-highlight);
    transform: translateY(-4px);
}

.feature-icon {
    width: 52px;
    height: 52px;
    background: var(--accent-muted);
    border-radius: var(--radius-md);
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 1.5rem;
    color: var(--accent-hover);
    transition: all 0.2s ease;
}

.feature-card:hover .feature-icon {
    background: var(--accent);
    color: white;
    box-shadow: 0 0 20px var(--accent-glow);
}

.feature-card h3 {
    font-size: 1.15rem;
    font-weight: 600;
    margin-bottom: 0.75rem;
}

.feature-card p {
    color: var(--text-secondary);
    line-height: 1.7;
    font-size: 0.95rem;
}

/* How It Works */
.how-it-works {
    padding: 6rem 2rem;
    max-width: 1000px;
    margin: 0 auto;
}

.steps {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 1.5rem;
    flex-wrap: wrap;
}

.step {
    flex: 1;
    min-width: 250px;
    max-width: 300px;
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    padding: 2rem;
    text-align: center;
    opacity: 0;
    transform: translateY(20px);
    transition: all 0.3s ease;
}

.step.animate-in {
    opacity: 1;
    transform: translateY(0);
}

.step:hover {
    background: var(--bg-card-hover);
    border-color: var(--border-highlight);
}

.step-number {
    width: 48px;
    height: 48px;
    background: var(--accent);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.25rem;
    font-weight: 700;
    margin: 0 auto 1.5rem;
    font-family: 'JetBrains Mono', monospace;
}

.step-content h3 {
    font-size: 1.1rem;
    font-weight: 600;
    margin-bottom: 0.5rem;
}

.step-content p {
    color: var(--text-secondary);
    font-size: 0.9rem;
}

.step-connector {
    color: var(--text-muted);
}

/* Download Section */
.download-section {
    padding: 6rem 2rem;
    display: flex;
    justify-content: center;
}

.download-card {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-xl);
    padding: 4rem;
    text-align: center;
    max-width: 600px;
    width: 100%;
    position: relative;
    overflow: hidden;
    opacity: 0;
    transform: translateY(20px);
    transition: all 0.3s ease;
}

.download-card.animate-in {
    opacity: 1;
    transform: translateY(0);
}

.download-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 200px;
    height: 200px;
    background: var(--accent);
    filter: blur(120px);
    opacity: 0.15;
    pointer-events: none;
}

.download-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 2rem;
}

.download-icon img {
    width: 80px;
    height: 80px;
    object-fit: contain;
}

.download-card h2 {
    font-size: 1.75rem;
    font-weight: 700;
    margin-bottom: 0.75rem;
}

.download-card > p {
    color: var(--text-secondary);
    margin-bottom: 2rem;
}

.download-buttons {
    margin-bottom: 2rem;
}

.download-info {
    display: flex;
    justify-content: center;
    gap: 2rem;
    flex-wrap: wrap;
}

.info-item {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    color: var(--text-muted);
    font-size: 0.85rem;
}

.info-item svg {
    color: var(--success);
}

/* Footer */
.footer {
    position: relative;
    z-index: 1;
    padding: 2rem 2rem;
}

.footer-content {
    max-width: 1200px;
    margin: 0 auto;
    display: flex;
    justify-content: center;
    align-items: center;
}

.footer-text {
    color: var(--text-muted);
    font-size: 0.85rem;
}

/* Responsive */
@media (max-width: 1024px) {
    .hero {
        grid-template-columns: 1fr;
        text-align: center;
        gap: 3rem;
    }
    
    .hero-content {
        align-items: center;
    }
    
    .hero-description {
        max-width: 100%;
    }
    
    .hero-actions {
        justify-content: center;
    }
    
    .hero-stats {
        justify-content: center;
    }
    
    .app-preview {
        transform: none;
    }
}

@media (max-width: 768px) {
    .navbar {
        padding: 1rem;
    }
    
    .nav-links {
        gap: 1rem;
    }
    
    .nav-links a:not(.nav-btn) {
        display: none;
    }
    
    .hero {
        padding: 6rem 1.5rem 3rem;
    }
    
    .hero-stats {
        flex-wrap: wrap;
        gap: 1.5rem;
    }
    
    .stat-divider {
        display: none;
    }
    
    .features,
    .how-it-works,
    .download-section {
        padding: 4rem 1.5rem;
    }
    
    .step-connector {
        display: none;
    }
    
    .steps {
        flex-direction: column;
    }
    
    .download-card {
        padding: 2.5rem 1.5rem;
    }
    
    .download-info {
        flex-direction: column;
        gap: 0.75rem;
    }
}
