/* ==========================================================================
   InboxSync Marketing Design System & Theme CSS
   ========================================================================== */

:root {
    --font-primary: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
    --font-heading: 'Outfit', sans-serif;
    
    /* Dark Theme (Default) */
    --bg-color: #060913;
    --text-color: #f1f5f9;
    --text-muted: rgba(241, 245, 249, 0.82);
    --card-bg: rgba(255, 255, 255, 0.02);
    --card-border: rgba(255, 255, 255, 0.08);
    --card-hover-border: rgba(99, 102, 241, 0.35);
    --card-shadow: 0 20px 50px rgba(0, 0, 0, 0.5);
    
    /* Primary Accents */
    --primary-hsl: 239, 84%, 67%;
    --primary-color: #6366f1;
    --accent-cyan: #00f0ff;
    --accent-indigo: #818cf8;
    
    /* Neon Pills & Badges */
    --neon-badge-text: #00f0ff;
    --neon-badge-bg: rgba(0, 240, 255, 0.08);
    --neon-badge-border: rgba(0, 240, 255, 0.25);
    
    /* Nav & Glass Surface */
    --nav-bg: rgba(6, 9, 19, 0.75);
    --glass-blur: blur(20px) saturate(180%);
    
    /* Ambient Glows */
    --aurora-blend: screen;
    --aurora-opacity: 0.25;
    
    --transition-fast: 0.2s cubic-bezier(0.16, 1, 0.3, 1);
    --transition-smooth: 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}

/* Light Theme Overrides */
html.light-theme {
    --bg-color: #f8fafc;
    --text-color: #0f172a;
    --text-muted: rgba(15, 23, 42, 0.82);
    --card-bg: rgba(255, 255, 255, 0.7);
    --card-border: rgba(226, 232, 240, 0.8);
    --card-hover-border: rgba(99, 102, 241, 0.4);
    --card-shadow: 0 20px 50px rgba(148, 163, 184, 0.15);
    
    --neon-badge-text: #0284c7;
    --neon-badge-bg: rgba(2, 132, 199, 0.08);
    --neon-badge-border: rgba(2, 132, 199, 0.25);
    
    --nav-bg: rgba(248, 250, 252, 0.8);
    --aurora-blend: multiply;
    --aurora-opacity: 0.08;
}

/* Reset & Base Lock */
*, *::before, *::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html, body {
    width: 100%;
    overflow-x: hidden;
    background-color: var(--bg-color);
    color: var(--text-color);
    font-family: var(--font-primary);
    line-height: 1.6;
    scroll-behavior: smooth;
    transition: background-color var(--transition-smooth), color var(--transition-smooth);
}

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

/* Ambient Aurora Blobs Wrapper */
.ambient-glows {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    overflow: hidden;
    pointer-events: none;
    z-index: -1;
}

.aurora-blob {
    position: absolute;
    border-radius: 50%;
    filter: blur(100px);
    mix-blend-mode: var(--aurora-blend);
    opacity: var(--aurora-opacity);
    transition: opacity var(--transition-smooth);
}

.blob-1 {
    top: -100px;
    left: 15%;
    width: 600px;
    height: 600px;
    background: radial-gradient(circle, #6366f1 0%, #00f0ff 100%);
}

.blob-2 {
    top: 600px;
    right: 5%;
    width: 500px;
    height: 500px;
    background: radial-gradient(circle, #3b82f6 0%, #818cf8 100%);
}

.blob-3 {
    top: 1400px;
    left: 10%;
    width: 550px;
    height: 550px;
    background: radial-gradient(circle, #4f46e5 0%, #06b6d4 100%);
}

/* Navigation Header */
.navbar {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    z-index: 1000;
    background: var(--nav-bg);
    backdrop-filter: var(--glass-blur);
    -webkit-backdrop-filter: var(--glass-blur);
    border-bottom: 1px solid var(--card-border);
    transition: all var(--transition-smooth);
}

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

.brand-logo {
    display: flex;
    align-items: center;
    gap: 12px;
    text-decoration: none;
    color: var(--text-color);
}

.nav-logo-icon {
    width: 40px;
    height: 40px;
    border-radius: 10px;
    object-fit: cover;
}

.logo-text {
    font-family: var(--font-heading);
    font-size: 1.4rem;
    font-weight: 800;
    letter-spacing: -0.02em;
}

.hero-gradient-text {
    color: var(--text-color);
}

.gradient-text {
    background: linear-gradient(135deg, #6366f1 0%, #00f0ff 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.nav-links {
    display: flex;
    gap: 32px;
}

.nav-links a {
    color: var(--text-muted);
    text-decoration: none;
    font-weight: 500;
    font-size: 0.95rem;
    transition: color var(--transition-fast);
}

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

.nav-cta {
    display: flex;
    align-items: center;
    gap: 16px;
}

/* Buttons & Controls */
.theme-toggle-btn {
    background: var(--card-bg);
    border: 1px solid var(--card-border);
    color: var(--text-color);
    width: 44px;
    height: 44px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all var(--transition-fast);
}

.theme-toggle-btn:hover {
    border-color: var(--primary-color);
    transform: translateY(-2px);
}

.theme-toggle-btn svg {
    width: 20px;
    height: 20px;
}

.sun-icon { display: none; }
.moon-icon { display: block; }

html.light-theme .sun-icon { display: block; }
html.light-theme .moon-icon { display: none; }

.glow-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 12px 24px;
    border-radius: 14px;
    background: linear-gradient(135deg, #4f46e5 0%, #0284c7 100%);
    color: #ffffff !important;
    font-weight: 600;
    font-size: 0.95rem;
    text-decoration: none;
    box-shadow: 0 10px 25px rgba(79, 70, 229, 0.35);
    transition: all var(--transition-fast);
}

.glow-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 15px 35px rgba(79, 70, 229, 0.5);
}

.btn-secondary {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 12px 24px;
    border-radius: 14px;
    background: var(--card-bg);
    border: 1px solid var(--card-border);
    color: var(--text-color);
    font-weight: 600;
    font-size: 0.95rem;
    text-decoration: none;
    backdrop-filter: var(--glass-blur);
    transition: all var(--transition-fast);
}

.btn-secondary:hover {
    border-color: var(--primary-color);
    transform: translateY(-2px);
}

/* Glass Cards */
.glass-card {
    background: var(--card-bg);
    border: 1px solid var(--card-border);
    backdrop-filter: var(--glass-blur);
    -webkit-backdrop-filter: var(--glass-blur);
    border-radius: 24px;
    box-shadow: var(--card-shadow);
    transition: all var(--transition-smooth);
}

/* Hero Section */
.hero-section {
    padding: 160px 0 100px;
    position: relative;
}

.hero-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 60px;
    align-items: center;
}

.promo-badge {
    display: inline-flex;
    padding: 6px 16px;
    border-radius: 999px;
    background: var(--neon-badge-bg);
    border: 1px solid var(--neon-badge-border);
    color: var(--neon-badge-text);
    font-size: 0.85rem;
    font-weight: 700;
    margin-bottom: 24px;
}

.hero-title {
    font-family: var(--font-heading);
    font-size: 3.2rem;
    font-weight: 800;
    line-height: 1.15;
    letter-spacing: -0.03em;
    margin-bottom: 24px;
}

.hero-description {
    font-size: 1.15rem;
    color: var(--text-muted);
    margin-bottom: 36px;
    max-width: 520px;
}

.hero-actions {
    display: flex;
    align-items: center;
    gap: 16px;
    margin-bottom: 40px;
    flex-wrap: wrap;
}

.play-store-badge-img {
    height: 52px;
    width: auto;
    transition: transform var(--transition-fast);
}

.play-store-badge-img:hover {
    transform: scale(1.04);
}

.hero-stats {
    display: flex;
    align-items: center;
    gap: 24px;
    padding-top: 24px;
    border-top: 1px solid var(--card-border);
}

.stat-item {
    display: flex;
    flex-direction: column;
}

.stat-num {
    font-family: var(--font-heading);
    font-size: 1.25rem;
    font-weight: 800;
    color: var(--text-color);
}

.stat-label {
    font-size: 0.82rem;
    color: var(--text-muted);
}

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

.hero-image-card {
    padding: 12px;
    border-radius: 32px;
    overflow: hidden;
}

.hero-graphic-img {
    width: 100%;
    height: auto;
    border-radius: 20px;
    display: block;
}

/* Features Section */
.features-section {
    padding: 100px 0;
}

.feature-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 60px;
    align-items: center;
    margin-bottom: 120px;
}

.feature-row:last-child {
    margin-bottom: 0;
}

.feature-row.reverse {
    direction: ltr;
}

.feature-text {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
}

.neon-badge {
    display: inline-flex;
    padding: 4px 12px;
    border-radius: 999px;
    background: var(--neon-badge-bg);
    border: 1px solid var(--neon-badge-border);
    color: var(--neon-badge-text);
    font-size: 0.8rem;
    font-weight: 700;
    margin-bottom: 16px;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.feature-text h2 {
    font-family: var(--font-heading);
    font-size: 2.2rem;
    font-weight: 800;
    line-height: 1.25;
    margin-bottom: 20px;
    letter-spacing: -0.02em;
}

.feature-text p {
    font-size: 1.05rem;
    color: var(--text-muted);
    margin-bottom: 24px;
}

.feature-bullets {
    list-style: none;
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.feature-bullets li {
    position: relative;
    padding-left: 28px;
    font-size: 0.95rem;
    font-weight: 500;
    color: var(--text-color);
}

.feature-bullets li::before {
    content: "✓";
    position: absolute;
    left: 0;
    top: 0;
    color: var(--primary-color);
    font-weight: 800;
}

.feature-image-wrapper {
    width: 100%;
    padding: 12px;
    border-radius: 32px;
    background: var(--card-bg);
    border: 1px solid var(--card-border);
    box-shadow: var(--card-shadow);
    backdrop-filter: var(--glass-blur);
    transition: transform var(--transition-smooth), border-color var(--transition-smooth);
}

.feature-image-wrapper:hover {
    transform: scale(1.02);
    border-color: var(--card-hover-border);
}

.feature-image-wrapper img {
    width: 100%;
    height: auto;
    border-radius: 20px;
    display: block;
}

/* Indie Pillars Section */
.indie-pillars-section {
    padding: 100px 0;
    position: relative;
}

.section-header {
    margin-bottom: 60px;
}

.section-header.center {
    text-align: center;
}

.section-header h2 {
    font-family: var(--font-heading);
    font-size: 2.5rem;
    font-weight: 800;
    margin-bottom: 16px;
    letter-spacing: -0.02em;
}

.section-header p {
    font-size: 1.1rem;
    color: var(--text-muted);
    max-width: 600px;
    margin: 0 auto;
}

.pillars-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 30px;
}

.pillar-card {
    padding: 40px 32px;
    display: flex;
    flex-direction: column;
    align-items: flex-start;
}

.pillar-icon {
    font-size: 2.5rem;
    margin-bottom: 20px;
}

.pillar-card h3 {
    font-family: var(--font-heading);
    font-size: 1.35rem;
    font-weight: 700;
    margin-bottom: 12px;
}

.pillar-card p {
    font-size: 0.95rem;
    color: var(--text-muted);
}

/* App Family Showcase */
.app-family-showcase {
    padding: 100px 0;
}

.family-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 30px;
}

.family-card {
    padding: 36px 28px;
    display: flex;
    flex-direction: column;
    height: 100%;
}

.family-card-header {
    display: flex;
    align-items: center;
    gap: 16px;
    margin-bottom: 20px;
}

.family-app-icon {
    width: 56px;
    height: 56px;
    border-radius: 14px;
    object-fit: cover;
    background: rgba(0, 0, 0, 0.1);
}

.family-app-info h3 {
    font-size: 1.25rem;
    font-weight: 700;
    margin-bottom: 2px;
}

.family-app-domain {
    font-size: 0.85rem;
    color: var(--accent-indigo);
    font-weight: 600;
}

.family-app-desc {
    font-size: 0.95rem;
    color: var(--text-muted);
    margin-bottom: 24px;
    flex-grow: 1;
}

.family-card-footer {
    display: flex;
    align-items: center;
}

.family-visit-link {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    font-size: 0.9rem;
    font-weight: 600;
    color: var(--text-color);
    text-decoration: none;
    transition: color var(--transition-fast);
}

.family-visit-link:hover {
    color: var(--primary-color);
}

.family-card.current-app {
    border-color: var(--primary-color);
}

.family-badge-active {
    margin-left: auto;
    padding: 4px 10px;
    border-radius: 999px;
    background: var(--neon-badge-bg);
    border: 1px solid var(--neon-badge-border);
    color: var(--neon-badge-text);
    font-size: 0.75rem;
    font-weight: 700;
}

/* Footer */
.footer {
    padding: 80px 0 40px;
    background: rgba(0, 0, 0, 0.2);
    border-top: 1px solid var(--card-border);
}

.footer-grid {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr;
    gap: 60px;
    margin-bottom: 60px;
}

.footer-tagline {
    font-size: 0.95rem;
    color: var(--text-muted);
    margin: 16px 0 24px;
}

.developer-card {
    padding: 24px;
    border-radius: 16px;
}

.developer-card h4 {
    font-family: var(--font-heading);
    font-size: 1.1rem;
    font-weight: 700;
    margin-bottom: 8px;
}

.developer-card p {
    font-size: 0.88rem;
    color: var(--text-muted);
    margin-bottom: 12px;
}

.dev-email {
    color: var(--primary-color);
    font-weight: 600;
    text-decoration: none;
    font-size: 0.9rem;
}

.footer-links-column h4 {
    font-family: var(--font-heading);
    font-size: 1.1rem;
    font-weight: 700;
    margin-bottom: 20px;
}

.footer-links-column ul {
    list-style: none;
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.footer-links-column a {
    color: var(--text-muted);
    text-decoration: none;
    font-size: 0.9rem;
    transition: color var(--transition-fast);
}

.footer-links-column a:hover {
    color: var(--primary-color);
}

#footer-version-meta {
    font-size: 0.85rem;
    color: var(--text-muted);
}

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

/* RTL Support for Arabic */
body.rtl {
    direction: rtl;
}

body.rtl .feature-bullets li {
    padding-left: 0;
    padding-right: 28px;
}

body.rtl .feature-bullets li::before {
    left: auto;
    right: 0;
}

body.rtl .family-badge-active {
    margin-left: 0;
    margin-right: auto;
}

/* Responsive Media Queries */
@media (max-width: 992px) {
    .hero-grid, .feature-row, .footer-grid {
        grid-template-columns: 1fr;
        gap: 40px;
    }
    
    .feature-row.reverse {
        direction: ltr;
    }

    .pillars-grid {
        grid-template-columns: 1fr;
    }
    
    .hero-title {
        font-size: 2.5rem;
    }
}

@media (max-width: 768px) {
    .nav-links {
        display: none;
    }

    .hero-section {
        padding: 120px 0 60px;
    }

    .hero-stats {
        flex-direction: column;
        align-items: flex-start;
        gap: 16px;
    }

    .stat-divider {
        display: none;
    }
}
