:root {
    color-scheme: light dark;

    --auth-bg: #f5f8fb;
    --auth-surface: #ffffff;
    --auth-surface-soft: #eef4f8;
    --auth-text: #132238;
    --auth-muted: #637083;
    --auth-line: rgba(19, 34, 56, .10);

    --auth-brand: #146f78;
    --auth-brand-deep: #0d5058;
    --auth-brand-soft: #dff1f1;

    --auth-shadow:
        0 24px 70px rgba(17, 37, 58, .10);
}

@media (prefers-color-scheme: dark) {
    :root {
        --auth-bg: #081219;
        --auth-surface: #101d26;
        --auth-surface-soft: #14252f;
        --auth-text: #edf5f7;
        --auth-muted: #a7b7c0;
        --auth-line: rgba(255, 255, 255, .10);

        --auth-brand: #52c5c6;
        --auth-brand-deep: #8bdcda;
        --auth-brand-soft: rgba(82, 197, 198, .12);

        --auth-shadow:
            0 24px 70px rgba(0, 0, 0, .32);
    }
}

* {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body.authenticator-public-page {
    margin: 0;
    min-height: 100vh;

    background:
        radial-gradient(
            circle at 10% 5%,
            var(--auth-brand-soft),
            transparent 28rem
        ),
        var(--auth-bg);

    color: var(--auth-text);

    font-family:
        "Noto Sans Arabic",
        "Segoe UI",
        Tahoma,
        Arial,
        sans-serif;

    line-height: 1.8;
}

.authenticator-public-page a {
    color: inherit;
}

.authenticator-container {
    width: min(1180px, calc(100% - 40px));
    margin-inline: auto;
}

.authenticator-header {
    border-bottom: 1px solid var(--auth-line);
    background: color-mix(
        in srgb,
        var(--auth-bg) 88%,
        transparent
    );
}

.authenticator-header__inner {
    min-height: 76px;

    display: flex;
    align-items: center;
    justify-content: space-between;

    gap: 20px;
}

.authenticator-brand {
    display: inline-flex;
    align-items: center;
    gap: 10px;

    text-decoration: none;
    font-size: 1.15rem;
    font-weight: 800;
}

.authenticator-brand__logo {
    width: 43px;
    height: 43px;
    object-fit: contain;
}

.authenticator-header__security {
    text-decoration: none;

    padding: 9px 16px;

    border: 1px solid var(--auth-line);
    border-radius: 12px;

    font-weight: 700;
}

.authenticator-hero {
    padding: 82px 0 72px;
}

.authenticator-hero__grid {
    display: grid;

    grid-template-columns:
        minmax(0, 1.15fr)
        minmax(300px, .85fr);

    align-items: center;
    gap: clamp(40px, 8vw, 100px);
}

.authenticator-badge {
    display: inline-flex;

    padding: 6px 13px;

    border-radius: 999px;

    background: var(--auth-brand-soft);
    color: var(--auth-brand-deep);

    font-size: .9rem;
    font-weight: 800;
}

.authenticator-hero h1 {
    margin: 20px 0 16px;

    font-size: clamp(2.7rem, 6vw, 5.4rem);
    line-height: 1.02;

    letter-spacing: -.035em;
}

.authenticator-hero h1 span {
    display: block;
    color: var(--auth-brand);
}

.authenticator-lead {
    max-width: 700px;

    margin: 0;

    color: var(--auth-muted);

    font-size: clamp(1.05rem, 2vw, 1.24rem);
}

.authenticator-actions {
    display: flex;
    flex-wrap: wrap;

    gap: 12px;

    margin-top: 30px;
}

.authenticator-btn {
    min-height: 50px;

    display: inline-flex;
    align-items: center;
    justify-content: center;

    padding: 11px 21px;

    border-radius: 14px;

    text-decoration: none;
    font-weight: 800;

    transition:
        transform .18s ease,
        box-shadow .18s ease;
}

.authenticator-btn:hover {
    transform: translateY(-2px);
}

.authenticator-btn--primary {
    background: var(--auth-brand);
    color: #fff !important;

    box-shadow:
        0 13px 32px
        color-mix(
            in srgb,
            var(--auth-brand) 26%,
            transparent
        );
}

.authenticator-btn--secondary {
    border: 1px solid var(--auth-line);
    background: var(--auth-surface);
}

.authenticator-platform-note {
    margin-top: 15px;

    color: var(--auth-muted);
    font-size: .9rem;
}

.authenticator-phone {
    width: min(100%, 390px);

    justify-self: center;

    padding: 22px;

    border: 1px solid var(--auth-line);
    border-radius: 38px;

    background: var(--auth-surface);

    box-shadow: var(--auth-shadow);
}

.authenticator-phone__top {
    display: flex;
    align-items: center;
    gap: 12px;

    padding: 4px 4px 20px;
}

.authenticator-phone__logo {
    width: 48px;
    height: 48px;
    object-fit: contain;
}

.authenticator-phone__top div {
    display: flex;
    flex-direction: column;
}

.authenticator-phone__top strong {
    font-size: 1.05rem;
}

.authenticator-phone__top span {
    color: var(--auth-muted);
    font-size: .85rem;
}

.authenticator-code-card {
    padding: 28px 22px;

    border-radius: 25px;

    background:
        linear-gradient(
            145deg,
            var(--auth-brand-soft),
            var(--auth-surface-soft)
        );

    text-align: center;
}

.authenticator-code-card__label {
    color: var(--auth-muted);
    font-size: .9rem;
}

.authenticator-code {
    display: block;

    margin: 11px 0 15px;

    direction: ltr;

    color: var(--auth-brand-deep);

    font-size: clamp(2.1rem, 7vw, 3.4rem);
    line-height: 1;

    letter-spacing: .08em;
}

.authenticator-timer {
    height: 5px;

    overflow: hidden;

    margin: 0 auto 12px;

    border-radius: 999px;

    background: var(--auth-line);
}

.authenticator-timer span {
    display: block;

    width: 64%;
    height: 100%;

    border-radius: inherit;

    background: var(--auth-brand);
}

.authenticator-code-card small {
    color: var(--auth-muted);
}

.authenticator-protection {
    display: flex;
    flex-direction: column;

    gap: 3px;

    margin-top: 16px;
    padding: 16px;

    border: 1px solid var(--auth-line);
    border-radius: 17px;
}

.authenticator-protection span {
    color: var(--auth-muted);
    font-size: .85rem;
}

.authenticator-section {
    padding: 70px 0;
}

.authenticator-section__heading {
    max-width: 620px;

    margin-bottom: 28px;
}

.authenticator-section__heading span,
.authenticator-install__eyebrow {
    color: var(--auth-brand);

    font-size: .9rem;
    font-weight: 800;
}

.authenticator-section h2 {
    margin: 5px 0 0;

    font-size: clamp(1.8rem, 4vw, 2.6rem);
    line-height: 1.25;
}

.authenticator-features {
    display: grid;

    grid-template-columns:
        repeat(3, minmax(0, 1fr));

    gap: 18px;
}

.authenticator-features article,
.authenticator-install__card,
.authenticator-integrity,
.authenticator-ios__card {
    border: 1px solid var(--auth-line);
    border-radius: 22px;

    background: var(--auth-surface);
}

.authenticator-features article {
    padding: 25px;
}

.authenticator-feature-icon {
    width: 45px;
    height: 45px;

    display: grid;
    place-items: center;

    border-radius: 13px;

    background: var(--auth-brand-soft);
    color: var(--auth-brand-deep);

    font-weight: 900;
}

.authenticator-features h3 {
    margin: 17px 0 6px;
}

.authenticator-features p {
    margin: 0;
    color: var(--auth-muted);
}

.authenticator-install__card {
    display: flex;
    align-items: center;
    justify-content: space-between;

    gap: 28px;

    padding: clamp(24px, 5vw, 45px);

    box-shadow: var(--auth-shadow);
}

.authenticator-install__card p {
    max-width: 660px;

    margin-bottom: 0;

    color: var(--auth-muted);
}

.authenticator-integrity {
    margin-top: 18px;
    padding: 22px;
}

.authenticator-integrity strong {
    display: block;
    margin-bottom: 9px;
}

.authenticator-integrity code {
    display: block;

    overflow-wrap: anywhere;

    direction: ltr;
    text-align: left;

    color: var(--auth-brand-deep);

    font-size: .82rem;
}

.authenticator-integrity p {
    margin-bottom: 0;
    color: var(--auth-muted);
}

.authenticator-ios__card {
    display: flex;
    align-items: center;

    gap: 20px;

    padding: 28px;
}

.authenticator-ios__status {
    flex: 0 0 auto;

    padding: 9px 15px;

    border-radius: 999px;

    background: var(--auth-surface-soft);
    color: var(--auth-muted);

    font-weight: 800;
}

.authenticator-ios h2 {
    margin: 0;
}

.authenticator-ios p {
    margin: 6px 0 0;
    color: var(--auth-muted);
}

.authenticator-footer {
    margin-top: 30px;

    border-top: 1px solid var(--auth-line);
}

.authenticator-footer .authenticator-container {
    min-height: 82px;

    display: flex;
    align-items: center;
    justify-content: space-between;

    gap: 20px;

    color: var(--auth-muted);
}

.authenticator-footer nav {
    display: flex;
    gap: 18px;
}

.authenticator-footer a {
    text-decoration: none;
}

@media (max-width: 820px) {
    .authenticator-hero {
        padding-top: 50px;
    }

    .authenticator-hero__grid {
        grid-template-columns: 1fr;
    }

    .authenticator-phone {
        width: min(100%, 420px);
    }

    .authenticator-features {
        grid-template-columns: 1fr;
    }

    .authenticator-install__card {
        align-items: stretch;
        flex-direction: column;
    }
}

@media (max-width: 560px) {
    .authenticator-container {
        width: min(100% - 24px, 1180px);
    }

    .authenticator-header__security {
        padding-inline: 10px;
        font-size: .85rem;
    }

    .authenticator-hero {
        padding: 38px 0 45px;
    }

    .authenticator-hero h1 {
        font-size: clamp(2.3rem, 13vw, 3.7rem);
    }

    .authenticator-actions {
        flex-direction: column;
    }

    .authenticator-btn {
        width: 100%;
    }

    .authenticator-phone {
        padding: 15px;
        border-radius: 28px;
    }

    .authenticator-ios__card {
        align-items: flex-start;
        flex-direction: column;
    }

    .authenticator-footer .authenticator-container {
        align-items: flex-start;
        flex-direction: column;

        padding: 22px 0;
    }
}

/* =========================================================
   MUNTIJI DOWNLOAD INTEGRITY R1
   ========================================================= */

.download-integrity-card{
    margin-top:18px;
    padding:24px 26px;

    border:1px solid rgba(15,124,130,.14);
    border-radius:20px;

    background:
        linear-gradient(
            180deg,
            rgba(255,255,255,.98),
            rgba(248,251,252,.98)
        );

    box-shadow:
        0 14px 34px rgba(15,23,42,.05);

    direction:rtl;
}

.download-integrity-card__head{
    display:flex;
    align-items:flex-start;
    justify-content:space-between;
    gap:20px;
}

.download-integrity-card__eyebrow{
    display:block;
    margin-bottom:5px;

    color:#0f7c82;
    font-size:12px;
    font-weight:800;
}

.download-integrity-card h3{
    margin:0;

    color:#0f172a;
    font-size:18px;
    line-height:1.45;
}

.download-integrity-card__status{
    flex:0 0 auto;

    padding:6px 10px;

    border-radius:999px;

    background:#e9f7f7;
    color:#0f7c82;

    font-size:11px;
    font-weight:800;
}

.download-integrity-card__description{
    margin:14px 0 18px;

    color:#64748b;
    font-size:13px;
    line-height:1.75;
}

.download-integrity-value{
    display:flex;
    align-items:center;
    gap:12px;

    padding:12px;

    border:1px solid #dfe7ee;
    border-radius:14px;

    background:#f8fafc;
}

.download-integrity-value code{
    flex:1;
    min-width:0;

    direction:ltr;
    text-align:left;
    unicode-bidi:isolate;

    overflow-wrap:anywhere;

    color:#0f5f66;

    font-family:
        "SFMono-Regular",
        Consolas,
        "Liberation Mono",
        monospace;

    font-size:12px;
    font-weight:700;
    letter-spacing:.015em;
}

.download-integrity-copy{
    flex:0 0 auto;

    min-height:38px;
    padding:8px 13px;

    border:1px solid #cddce2;
    border-radius:10px;

    background:#fff;
    color:#0f172a;

    font-size:12px;
    font-weight:800;

    cursor:pointer;

    transition:.16s ease;
}

.download-integrity-copy:hover{
    border-color:#0f7c82;
    color:#0f7c82;
}

.download-integrity-copy:disabled{
    opacity:.7;
    cursor:default;
}

.download-integrity-card__note{
    margin-top:11px;

    color:#94a3b8;
    font-size:11px;
}

/* Dark mode */

html[data-muntiji-color-mode="dark"] .download-integrity-card{
    background:#121c2b;
    border-color:#26364a;
}

html[data-muntiji-color-mode="dark"] .download-integrity-card h3{
    color:#f3f6fa;
}

html[data-muntiji-color-mode="dark"] .download-integrity-value{
    background:#172334;
    border-color:#26364a;
}

html[data-muntiji-color-mode="dark"] .download-integrity-value code{
    color:#79d7da;
}

html[data-muntiji-color-mode="dark"] .download-integrity-copy{
    background:#172334;
    border-color:#34485f;
    color:#f3f6fa;
}

@media (max-width:640px){
    .download-integrity-card{
        padding:20px;
    }

    .download-integrity-card__head{
        flex-direction:column;
        gap:10px;
    }

    .download-integrity-value{
        align-items:stretch;
        flex-direction:column;
    }

    .download-integrity-copy{
        width:100%;
    }
}
