/* ==========================================================================
   InstaPe — Marketing landing page
   --------------------------------------------------------------------------
   1. Design tokens
   2. Reset & base
   3. Layout
   4. Components
      4.1 Logo
      4.2 Badge
      4.3 Typography (hero copy)
      4.4 Feature list
      4.5 Store buttons
      4.6 Stats
      4.7 Hero visual
      4.8 Bottom features bar
   5. Responsive
   ========================================================================== */

/* ==========================================================================
   1. Design tokens
   ========================================================================== */

:root {
    /* Brand */
    --color-brand: #1f6fff;
    --color-brand-soft: #e7f0ff;

    /* Surfaces */
    --color-surface: #f7f9fc;
    --color-surface-alt: #f9f5fe;
    --color-border: #e6ebf2;
    --color-black: #000;
    --color-white: #fff;

    /* Text */
    --color-text: #1e2430;
    --color-text-muted: #606b7b;
    --color-text-soft: #3b4453;
    --color-text-subtle: #4b5563;

    /* Typography */
    --font-sans: 'Inter', sans-serif;

    /* Layout */
    --layout-max-width: 1200px;
    --radius-pill: 20px;
    --radius-md: 8px;
}

/* ==========================================================================
   2. Reset & base
   ========================================================================== */

*,
*::before,
*::after {
    box-sizing: border-box;
}

* {
    margin: 0;
    padding: 0;
}

body {
    background: var(--color-surface);
    color: var(--color-text);
    font-family: var(--font-sans);
}

/* ==========================================================================
   3. Layout
   ========================================================================== */

.wrapper {
    max-width: var(--layout-max-width);
    margin: auto;
    padding: 60px 40px 30px;
}

.hero {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 40px;
}

.hero__content {
    max-width: 550px;
}

/* ==========================================================================
   4. Components
   ========================================================================== */

/* 4.1 Logo ---------------------------------------------------------------- */

.logo {
    display: block;
    max-width: 120px;
    height: auto;
    margin-bottom: 20px;
}

/* 4.2 Badge --------------------------------------------------------------- */

.badge {
    display: inline-block;
    margin-bottom: 20px;
    padding: 8px 16px;
    border-radius: var(--radius-pill);
    background: var(--color-brand-soft);
    color: var(--color-brand);
    font-size: 13px;
    font-weight: 500;
}

/* 4.3 Typography (hero copy) --------------------------------------------- */

h1 {
    margin-bottom: 20px;
    color: var(--color-text);
    font-size: 48px;
    font-weight: 800;
    line-height: 1.2;
}

.description {
    margin-bottom: 20px;
    color: var(--color-text-muted);
    font-size: 15px;
    line-height: 1.6;
}

/* 4.4 Feature list ------------------------------------------------------- */

.features {
    margin-bottom: 20px;
    list-style: none;
}

.features li {
    display: flex;
    margin-bottom: 12px;
    color: var(--color-text-soft);
    font-size: 14px;
    font-weight: 500;
}

.features li::before {
    content: "\2714";
    margin-right: 10px;
    color: var(--color-brand);
    font-weight: 700;
}

/* 4.5 Store buttons ------------------------------------------------------ */

.store-buttons {
    display: flex;
    gap: 12px;
    margin-top: 20px;
    margin-bottom: 20px;
}

.store-btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 10px 16px;
    border-radius: var(--radius-md);
    background: var(--color-black);
    color: var(--color-white);
    font-size: 13px;
    font-weight: 600;
    text-decoration: none;
}

.store-btn img {
    display: block;
    max-height: 40px;
    width: auto;
}

/* 4.6 Stats -------------------------------------------------------------- */

.stats {
    display: flex;
    gap: 40px;
    margin-top: 30px;
}

.stat h3 {
    margin-bottom: 5px;
    color: var(--color-brand);
    font-size: 24px;
    font-weight: 700;
}

.stat p {
    color: var(--color-text-muted);
    font-size: 13px;
    font-weight: 500;
}

/* 4.7 Hero visual -------------------------------------------------------- */

.hero__visual img {
    display: block;
    width: 100%;
    max-width: 100%;
    height: auto;
}

/* 4.8 Bottom features bar ------------------------------------------------ */

.bottom-features {
    display: flex;
    justify-content: space-between;
    gap: 20px;
    margin-top: 70px;
    padding: 35px 20px;
    border-top: 1px solid var(--color-border);
    background-color: var(--color-surface-alt);
    color: var(--color-text-subtle);
    font-size: 13px;
}

.feature-row {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 10px 0;
}

.feature-icon {
    font-size: 16px;
}

/* ==========================================================================
   5. Responsive
   ========================================================================== */

@media (max-width: 1000px) {
    .hero {
        flex-direction: column;
        text-align: center;
    }

    .hero__content {
        max-width: 100%;
    }

    .stats {
        flex-direction: column;
        align-items: center;
        gap: 20px;
        margin-top: 20px;
    }

    .store-buttons {
        justify-content: center;
    }

    .bottom-features {
        flex-direction: column;
        gap: 15px;
        text-align: center;
    }

    h1 {
        font-size: 36px;
    }
}

@media (max-width: 600px) {
    .wrapper {
        padding: 40px 20px 20px;
    }

    .hero {
        gap: 20px;
    }

    .bottom-features {
        margin-top: 50px;
        font-size: 12px;
    }

    h1 {
        font-size: 28px;
    }
}

@media (max-width: 400px) {
    .store-buttons {
        flex-wrap: wrap;
        justify-content: center;
    }
}

.redirect-loader {
    position: fixed;
    inset: 0;
    width: 100vw;
    height: 100vh;
    background: rgba(255, 255, 255, 0.95);
    z-index: 999999;
    display: flex;
    justify-content: center;
    align-items: center;
    pointer-events: all;
}

.hidden {
    display: none;
}

.loader-content {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 16px;
}

.spinner {
    width: 48px;
    height: 48px;
    border: 4px solid #d9d9d9;
    border-top: 4px solid #040050;
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

.loader-text {
    font-size: 18px;
    font-weight: 600;
    color: #040050;
}

@keyframes spin {
    from {
        transform: rotate(0deg);
    }

    to {
        transform: rotate(360deg);
    }
}

/* Aadhaar loader close fallback (?actionType=aadharLoader) --------------- */

.aadhar-close-fallback {
    position: fixed;
    inset: 0;
    width: 100vw;
    height: 100vh;
    background: rgba(255, 255, 255, 0.95);
    z-index: 999999;
    display: flex;
    justify-content: center;
    align-items: center;
    pointer-events: all;
}

/* .hidden alone loses this tie: same specificity as .aadhar-close-fallback,
   but declared earlier in the file, so source order would otherwise let
   this rule's `display: flex` win and show the panel unconditionally. */
.aadhar-close-fallback.hidden {
    display: none;
}

.aadhar-close-fallback__content {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 16px;
    padding: 0 20px;
    text-align: center;
}

.aadhar-close-fallback__text {
    color: #040050;
    font-size: 18px;
    font-weight: 600;
}

.aadhar-close-fallback__btn {
    padding: 10px 28px;
    border: none;
    border-radius: var(--radius-md);
    background: var(--color-brand);
    color: var(--color-white);
    font-size: 15px;
    font-weight: 600;
    cursor: pointer;
}