/* ═══════════════════════════════════════════════════════════════
   ASTRA THEMES  —  mirrors RunAstra mobile app Solar/Lunar/Nebula
   ═══════════════════════════════════════════════════════════════ */

:root,
[data-theme="solar"] {
    --bg-dark: #0f0f13;
    --bg-card: #16161e;
    --primary: #ff7a00;
    --primary-hover: #ff8c20;
    --primary-rgb: 255, 122, 0;
    --text-main: #ffffff;
    --text-muted: #a0a0ab;
    --border: rgba(255, 255, 255, 0.1);
    --navbar-bg: rgba(15, 15, 19, 0.85);
}

[data-theme="lunar"] {
    --bg-dark: #020617;
    --bg-card: #0f172a;
    --primary: #94a3b8;
    --primary-hover: #cbd5e1;
    --primary-rgb: 148, 163, 184;
    --text-main: #f1f5f9;
    --text-muted: #8892a4;
    --border: rgba(255, 255, 255, 0.08);
    --navbar-bg: rgba(2, 6, 23, 0.9);
}

[data-theme="nebula"] {
    --bg-dark: #080412;
    --bg-card: #16133d;
    --primary: #a855f7;
    --primary-hover: #c084fc;
    --primary-rgb: 168, 85, 247;
    --text-main: #f5f3ff;
    --text-muted: #a18cd1;
    --border: rgba(168, 85, 247, 0.15);
    --navbar-bg: rgba(8, 4, 18, 0.9);
}

/* ═══════════════════════════════════════════════════════════════
   BASE
   ═══════════════════════════════════════════════════════════════ */

* { margin: 0; padding: 0; box-sizing: border-box; }

html, body { width: 100%; overflow-x: hidden; position: relative; }

body {
    font-family: 'Inter', sans-serif;
    background-color: var(--bg-dark);
    color: var(--text-main);
    line-height: 1.6;
    transition: background-color 0.4s ease, color 0.4s ease;
}

a { text-decoration: none; color: inherit; }

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

.highlight { color: var(--primary); }

/* ═══════════════════════════════════════════════════════════════
   NAVIGATION
   ═══════════════════════════════════════════════════════════════ */

.navbar {
    border-bottom: 1px solid var(--border);
    background: var(--navbar-bg);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    position: fixed;
    top: 0; width: 100%; z-index: 100;
    transition: background 0.4s ease, border-color 0.4s ease;
}
.nav-container {
    display: flex; justify-content: space-between; align-items: center;
    max-width: 1200px; margin: 0 auto; padding: 1.25rem 5%;
}
.logo {
    display: flex; align-items: center; gap: 0.8rem;
    font-weight: 900; font-size: 1.2rem;
}
.logo-icon {
    width: 32px; height: 32px;
    background: var(--primary); color: #000;
    border-radius: 50%;
    display: flex; align-items: center; justify-content: center;
    font-size: 0.9rem;
    transition: background 0.4s ease;
}
.nav-right { display: flex; align-items: center; gap: 2rem; }
.nav-links { display: flex; gap: 2rem; font-weight: 600; font-size: 0.9rem; color: var(--text-muted); }
.nav-links a:hover { color: var(--text-main); }

/* Theme Switcher */
.theme-switcher {
    display: flex;
    align-items: center;
    gap: 0.35rem;
    background: rgba(255,255,255,0.05);
    border: 1px solid var(--border);
    border-radius: 100px;
    padding: 0.35rem 0.55rem;
    transition: border-color 0.4s ease;
}
.theme-dot {
    width: 16px; height: 16px;
    border-radius: 50%;
    border: 2px solid transparent;
    cursor: pointer;
    transition: transform 0.2s ease, border-color 0.2s ease;
    padding: 0;
    outline: none;
    flex-shrink: 0;
}
.theme-dot:hover { transform: scale(1.2); }
.theme-dot.active { border-color: var(--text-main); transform: scale(1.2); }
.theme-dot[data-theme-name="solar"]  { background: #ff7a00; }
.theme-dot[data-theme-name="lunar"]  { background: #94a3b8; }
.theme-dot[data-theme-name="nebula"] { background: #a855f7; }

/* ═══════════════════════════════════════════════════════════════
   BUTTONS
   ═══════════════════════════════════════════════════════════════ */

.btn {
    padding: 1rem 2rem; border-radius: 100px;
    font-weight: 800; font-size: 0.9rem;
    transition: all 0.2s ease;
    display: inline-block; cursor: pointer; text-align: center;
}
.btn-primary {
    background: var(--primary); color: #000;
    box-shadow: 0 10px 30px rgba(var(--primary-rgb), 0.2);
    border: none;
}
.btn-primary:hover {
    background: var(--primary-hover);
    transform: translateY(-2px);
    box-shadow: 0 15px 40px rgba(var(--primary-rgb), 0.3);
}
.btn-secondary {
    background: var(--bg-card); color: var(--text-main);
    border: 1px solid var(--border);
}
.btn-secondary:hover { background: rgba(255,255,255,0.05); transform: translateY(-2px); }

/* ═══════════════════════════════════════════════════════════════
   HERO
   ═══════════════════════════════════════════════════════════════ */

.hero { padding: 12rem 0 6rem; width: 100%; }
.hero-content { display: grid; grid-template-columns: 1fr 1fr; gap: 4rem; align-items: center; }

.badge {
    display: inline-block; padding: 0.4rem 1rem; border-radius: 100px;
    background: rgba(var(--primary-rgb), 0.1);
    color: var(--primary);
    font-size: 0.75rem; font-weight: 800;
    text-transform: uppercase; letter-spacing: 2px;
    margin-bottom: 1.5rem;
    border: 1px solid rgba(var(--primary-rgb), 0.2);
    transition: background 0.4s ease, color 0.4s ease, border-color 0.4s ease;
}

.hero h1 { font-size: 4.5rem; font-weight: 900; line-height: 1.1; letter-spacing: -2px; margin-bottom: 1.5rem; }
.hero p { font-size: 1.1rem; color: var(--text-muted); margin-bottom: 2.5rem; max-width: 90%; }
.cta-group { display: flex; gap: 1rem; margin-bottom: 3rem; flex-wrap: wrap; }
.platform-support p { font-size: 0.75rem; text-transform: uppercase; letter-spacing: 1px; margin-bottom: 0.5rem; font-weight: 800; color: #555; }
.platforms { display: flex; gap: 1rem; align-items: center; font-size: 0.85rem; color: var(--text-muted); font-weight: 600; flex-wrap: wrap; }
.dot { color: var(--primary); }

/* Phone Mockup */
.phone-mockup {
    position: relative;
    width: 290px; height: 580px;
    margin: 0 auto;
    background: #000;
    border-radius: 44px;
    padding: 10px;
    box-shadow:
        0 30px 60px rgba(0,0,0,0.8),
        0 0 100px rgba(var(--primary-rgb), 0.15),
        inset 0 0 2px 2px rgba(255,255,255,0.1);
    transform: perspective(1000px) rotateY(-15deg) rotateX(5deg);
    transition:
        transform 0.6s cubic-bezier(0.23, 1, 0.32, 1),
        box-shadow 0.4s ease;
    z-index: 1;
}
.phone-mockup:hover { transform: perspective(1000px) rotateY(0deg) rotateX(0deg) scale(1.05); }
.phone-hardware .camera {
    position: absolute; top: 25px; left: 50%; transform: translateX(-50%);
    width: 12px; height: 12px; background: #111; border-radius: 50%; z-index: 10;
    border: 1px solid rgba(255,255,255,0.1);
}
.volume-btn, .power-btn { position: absolute; background: #222; border-radius: 2px 0 0 2px; left: -2px; }
.volume-btn { top: 100px; width: 3px; height: 60px; }
.power-btn  { top: 180px; width: 3px; height: 40px; }
.screen { position: relative; width: 100%; height: 100%; background: #000; border-radius: 36px; overflow: hidden; z-index: 5; }
.carousel { position: relative; width: 100%; height: 100%; }
.carousel img {
    position: absolute; top: 50%; left: 50%; transform: translate(-50%, -50%);
    width: 90%; height: 94%; object-fit: contain; border-radius: 24px;
    opacity: 0; transition: opacity 0.8s ease-in-out;
}
.carousel img.active { opacity: 1; z-index: 6; }
.phone-reflection {
    position: absolute; top: 0; left: 0; width: 100%; height: 100%;
    background: linear-gradient(135deg, rgba(255,255,255,0.1) 0%, transparent 50%);
    border-radius: 44px; pointer-events: none; z-index: 10;
}

.brand-showcase-box {
    background: rgba(var(--primary-rgb), 0.05);
    border-left: 3px solid var(--primary);
    padding: 20px 25px; border-radius: 12px; margin: 30px 0;
    transition: background 0.4s ease, border-color 0.4s ease;
}
.brand-showcase-box h3 { font-size: 1.2rem; margin-bottom: 8px; color: var(--text-main); }
.brand-showcase-box p { font-size: 0.95rem; margin-bottom: 0 !important; }

/* ═══════════════════════════════════════════════════════════════
   FEATURES
   ═══════════════════════════════════════════════════════════════ */

.features-section {
    padding: 8rem 0;
    background: var(--bg-card);
    border-top: 1px solid var(--border);
    border-bottom: 1px solid var(--border);
    transition: background 0.4s ease, border-color 0.4s ease;
}
.section-header { text-align: center; margin-bottom: 4rem; }
.section-header h2 { font-size: 3rem; font-weight: 900; letter-spacing: -1px; margin-bottom: 1rem; }
.section-header p { color: var(--text-muted); font-size: 1.1rem; }
.features-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); gap: 2rem; }
.feature-card {
    background: var(--bg-dark); padding: 2.5rem;
    border-radius: 24px; border: 1px solid var(--border);
    transition: transform 0.3s ease, border-color 0.3s ease, background 0.4s ease;
}
.feature-card:hover { transform: translateY(-10px); border-color: rgba(var(--primary-rgb), 0.35); }
.feature-icon { font-size: 2.5rem; margin-bottom: 1.5rem; }
.feature-card h3 { font-size: 1.3rem; font-weight: 800; margin-bottom: 1rem; }
.feature-card p { color: var(--text-muted); font-size: 0.95rem; }

/* ═══════════════════════════════════════════════════════════════
   AI SECTION
   ═══════════════════════════════════════════════════════════════ */

.ai-section { padding: 8rem 0; }
.ai-container { display: grid; grid-template-columns: 1fr 1fr; gap: 6rem; align-items: center; }
.badge-ai { background: rgba(59, 130, 246, 0.1); color: #3b82f6; border-color: rgba(59, 130, 246, 0.2); }
.ai-text h2 { font-size: 3.5rem; font-weight: 900; letter-spacing: -1.5px; margin-bottom: 1.5rem; }
.ai-text p { color: var(--text-muted); font-size: 1.1rem; margin-bottom: 2rem; }
.ai-list { list-style: none; }
.ai-list li { margin-bottom: 1rem; padding-left: 2rem; position: relative; color: var(--text-muted); }
.ai-list li::before { content: "→"; position: absolute; left: 0; color: var(--primary); font-weight: bold; transition: color 0.4s ease; }
.ai-list li strong { color: var(--text-main); }

.ai-orb { position: relative; width: 300px; height: 300px; margin: 0 auto; display: flex; align-items: center; justify-content: center; }
.ring { position: absolute; border-radius: 50%; animation: pulse 4s infinite linear; }
.r1 { width: 100%; height: 100%; border: 2px solid rgba(var(--primary-rgb), 0.1); animation-delay: 0s; }
.r2 { width: 70%; height: 70%; border: 2px solid rgba(var(--primary-rgb), 0.4); animation-delay: -1s; }
.r3 {
    width: 40%; height: 40%;
    background: radial-gradient(circle, var(--primary) 0%, transparent 70%);
    border: none;
    box-shadow: 0 0 50px var(--primary);
    animation: glow-orb 2s infinite alternate;
}

@keyframes pulse { 0% { transform: scale(0.8); opacity: 1; } 100% { transform: scale(1.5); opacity: 0; } }
@keyframes glow-orb { 0% { opacity: 0.6; transform: scale(0.9); } 100% { opacity: 1; transform: scale(1.1); } }

/* ═══════════════════════════════════════════════════════════════
   ORGANIZER SECTION
   ═══════════════════════════════════════════════════════════════ */

.organizer-section { padding: 8rem 0; }
.organizer-banner {
    background: linear-gradient(135deg, var(--bg-card) 0%, var(--bg-dark) 100%);
    border: 1px solid var(--border);
    border-radius: 48px; padding: 5rem;
    position: relative; overflow: hidden;
    transition: background 0.4s ease, border-color 0.4s ease;
}
.organizer-banner::after {
    content: ''; position: absolute;
    top: -50%; right: -20%;
    width: 600px; height: 600px;
    background: radial-gradient(circle, rgba(var(--primary-rgb), 0.05) 0%, transparent 70%);
    pointer-events: none;
    transition: background 0.4s ease;
}
.organizer-text { position: relative; z-index: 1; max-width: 700px; }
.organizer-text h2 { font-size: 3rem; font-weight: 900; margin-bottom: 1.5rem; letter-spacing: -1px; }
.organizer-text p { font-size: 1.1rem; color: var(--text-muted); margin-bottom: 2rem; line-height: 1.6; }
.badge-secondary { background: rgba(255,255,255,0.05); color: var(--text-muted); }
.organizer-self-serve-note { margin-top: 1.5rem; font-size: 0.9rem; color: var(--text-muted); font-style: italic; }

/* ═══════════════════════════════════════════════════════════════
   DOWNLOAD CTA
   ═══════════════════════════════════════════════════════════════ */

.cta-section {
    text-align: center; padding: 8rem 0;
    background: linear-gradient(180deg, var(--bg-card) 0%, var(--bg-dark) 100%);
    border-top: 1px solid var(--border);
    transition: background 0.4s ease, border-color 0.4s ease;
}
.cta-section h2 { font-size: 2.5rem; font-weight: 900; margin-bottom: 1rem; }
.cta-section p { color: var(--text-muted); margin-bottom: 3rem; }
.subscribe-form { display: flex; max-width: 500px; margin: 0 auto; gap: 1rem; padding: 0 5%; }
.subscribe-form input {
    flex: 1; padding: 1rem 1.5rem; border-radius: 100px;
    border: 1px solid var(--border);
    background: rgba(0,0,0,0.5); color: var(--text-main);
    outline: none; font-family: inherit; width: 100%;
    transition: border-color 0.2s ease;
}
.subscribe-form input:focus { border-color: var(--primary); }

/* ═══════════════════════════════════════════════════════════════
   FOOTER
   ═══════════════════════════════════════════════════════════════ */

footer { padding: 4rem 0; border-top: 1px solid var(--border); }
.footer-container { display: flex; justify-content: space-between; align-items: center; margin-bottom: 2rem; }
.footer-links { display: flex; gap: 2rem; font-size: 0.85rem; color: var(--text-muted); font-weight: 600; flex-wrap: wrap; }
.footer-links a:hover { color: var(--text-main); }
.footer-bottom { text-align: center; font-size: 0.8rem; color: #555; padding-top: 2rem; border-top: 1px solid var(--border); }

/* ═══════════════════════════════════════════════════════════════
   RESPONSIVE
   ═══════════════════════════════════════════════════════════════ */

@media (max-width: 1024px) {
    .hero h1 { font-size: 3.5rem; }
    .ai-container { gap: 3rem; }
    .ai-text h2 { font-size: 3rem; }
}

@media (max-width: 768px) {
    .hero { padding-top: 8rem; }
    .hero-content { grid-template-columns: 1fr; text-align: center; gap: 3rem; }
    .hero h1 { font-size: 2.8rem; letter-spacing: -1px; }
    .hero p { margin: 0 auto 2rem; font-size: 1rem; }
    .cta-group { justify-content: center; }
    .platforms { justify-content: center; }

    .phone-mockup { width: 250px; height: 500px; transform: none; }
    .phone-mockup:hover { transform: scale(1.02); }

    .section-header h2 { font-size: 2.2rem; }
    .features-section { padding: 5rem 0; }

    .ai-section { padding: 5rem 0; }
    .ai-container { grid-template-columns: 1fr; text-align: center; gap: 3rem; }
    .ai-orb { width: 240px; height: 240px; }
    .ai-text h2 { font-size: 2.5rem; }

    .organizer-section { padding: 5rem 0; }
    .organizer-banner { padding: 3rem 1.5rem; border-radius: 32px; }
    .organizer-text h2 { font-size: 2rem; }

    .footer-container { flex-direction: column; gap: 2rem; text-align: center; }
    .footer-links { justify-content: center; gap: 1.5rem; }
}

@media (max-width: 480px) {
    .hero h1 { font-size: 2.2rem; }
    .btn { width: 100%; }
    .cta-group { flex-direction: column; width: 100%; }
    .nav-links { display: none; }
    .logo { font-size: 1.1rem; }

    .subscribe-form { flex-direction: column; }

    .organizer-banner { padding: 2rem 1rem; }
    .organizer-text h2 { font-size: 1.6rem; }
    .brand-showcase-box { padding: 15px; margin: 20px 0; }
    .brand-showcase-box h3 { font-size: 1.1rem; }

    .platforms { font-size: 0.75rem; gap: 0.5rem; }
}

/* ═══════════════════════════════════════════════════════════════
   MODAL
   ═══════════════════════════════════════════════════════════════ */

.modal-overlay {
    position: fixed; inset: 0;
    background: rgba(0, 0, 0, 0.82);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    z-index: 1000;
    display: flex; align-items: center; justify-content: center;
    padding: 1rem;
    opacity: 0; pointer-events: none;
    transition: opacity 0.25s ease;
}
.modal-overlay.active { opacity: 1; pointer-events: all; }

.modal {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: 28px;
    padding: 2.5rem;
    width: 100%; max-width: 540px; max-height: 90vh;
    overflow-y: auto;
    position: relative;
    transform: translateY(24px) scale(0.97);
    transition:
        transform 0.25s ease,
        background 0.4s ease,
        border-color 0.4s ease;
    scrollbar-width: thin;
    scrollbar-color: rgba(255,255,255,0.1) transparent;
}
.modal-overlay.active .modal { transform: translateY(0) scale(1); }

.modal-close {
    position: absolute; top: 1.25rem; right: 1.25rem;
    background: rgba(255,255,255,0.08); border: none;
    color: var(--text-muted);
    width: 32px; height: 32px; border-radius: 50%;
    font-size: 1.2rem; cursor: pointer;
    display: flex; align-items: center; justify-content: center;
    transition: background 0.2s, color 0.2s;
}
.modal-close:hover { background: rgba(255,255,255,0.15); color: var(--text-main); }

.modal-badge {
    display: inline-block; padding: 0.3rem 0.9rem; border-radius: 100px;
    background: rgba(var(--primary-rgb), 0.1);
    color: var(--primary);
    font-size: 0.7rem; font-weight: 800;
    text-transform: uppercase; letter-spacing: 2px;
    border: 1px solid rgba(var(--primary-rgb), 0.2);
    margin-bottom: 1rem;
    transition: background 0.4s ease, color 0.4s ease, border-color 0.4s ease;
}
.modal-header { margin-bottom: 1.75rem; }
.modal-header h2 { font-size: 1.6rem; font-weight: 900; margin-bottom: 0.5rem; letter-spacing: -0.5px; }
.modal-header p { color: var(--text-muted); font-size: 0.9rem; }

/* Form */
.form-group { margin-bottom: 1.25rem; }
.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; }
.form-group label {
    display: block;
    font-size: 0.75rem; font-weight: 700;
    color: var(--text-muted);
    text-transform: uppercase; letter-spacing: 0.8px;
    margin-bottom: 0.5rem;
}
.form-group input,
.form-group textarea {
    width: 100%; padding: 0.85rem 1rem;
    background: rgba(0,0,0,0.4);
    border: 1px solid var(--border);
    border-radius: 12px;
    color: var(--text-main);
    font-family: inherit; font-size: 0.9rem;
    outline: none;
    transition: border-color 0.2s ease;
    resize: none; box-sizing: border-box;
}
.form-group input:focus,
.form-group textarea:focus { border-color: var(--primary); }
.form-group textarea { min-height: 80px; }
.required { color: var(--primary); font-size: 0.75rem; font-weight: 900; margin-left: 2px; transition: color 0.4s ease; }
.optional { color: var(--text-muted); font-size: 0.7rem; font-weight: 600; margin-left: 4px; text-transform: none; letter-spacing: 0; }
.form-error {
    color: #f87171; font-size: 0.85rem;
    margin: 0.75rem 0; padding: 0.75rem 1rem;
    background: rgba(248, 113, 113, 0.08);
    border-radius: 10px;
    border: 1px solid rgba(248, 113, 113, 0.2);
}
.btn-full { width: 100%; justify-content: center; margin-top: 0.5rem; }

/* OTP boxes */
.otp-section { text-align: center; }
.otp-boxes { display: flex; gap: 0.6rem; justify-content: center; margin: 2rem 0 1.5rem; }
.otp-box {
    width: 48px; height: 56px;
    background: rgba(0,0,0,0.4);
    border: 2px solid var(--border);
    border-radius: 12px;
    color: var(--text-main);
    font-size: 1.4rem; font-weight: 900;
    text-align: center;
    outline: none;
    transition: border-color 0.2s ease, background 0.2s ease;
    font-family: inherit;
}
.otp-box:focus { border-color: var(--primary); background: rgba(var(--primary-rgb), 0.05); }
.otp-note { margin-top: 1.25rem; font-size: 0.85rem; color: var(--text-muted); }
.link-btn {
    background: none; border: none;
    color: var(--primary); font-size: inherit; font-family: inherit;
    cursor: pointer; padding: 0;
    text-decoration: underline;
    transition: color 0.4s ease;
}

/* Success */
.modal-success { text-align: center; padding: 2rem 0; }
.success-icon {
    width: 64px; height: 64px;
    background: rgba(74, 222, 128, 0.12);
    border: 2px solid rgba(74, 222, 128, 0.35);
    color: #4ade80;
    border-radius: 50%; font-size: 1.8rem;
    display: flex; align-items: center; justify-content: center;
    margin: 0 auto 1.5rem;
}
.modal-success h2 { font-size: 1.8rem; font-weight: 900; margin-bottom: 0.75rem; }
.modal-success p { color: var(--text-muted); margin-bottom: 2rem; font-size: 0.95rem; }

@media (max-width: 600px) {
    .modal { padding: 1.75rem 1.25rem; border-radius: 20px; }
    .form-row { grid-template-columns: 1fr; }
    .otp-box { width: 40px; height: 50px; font-size: 1.2rem; }
    .otp-boxes { gap: 0.4rem; }
}
