﻿/* ══════════════════════════════════════════════════════════════
   samra-app-stats.css
   Styles for the reusable Samra app-download + stats sections
   (_SamraAppStats.cshtml) on the Event AND E-commerce layouts.

   • smr- prefixed → no collision with event.css / ecommerce.css.
   • Gold values inlined → renders correctly even without samra.css :root.
   • Includes .lbl language switching scoped to these sections, keyed on
     html[dir]/lang + body.lang-en, so it follows the language toggle on
     BOTH the Event (.lbl) and E-commerce (data-i18n) pages.

   Load AFTER samra.css in each layout's <head>.
   Put it in: wwwroot/css/samra-app-stats.css
   ══════════════════════════════════════════════════════════════ */

@import url('https://fonts.googleapis.com/css2?family=Playfair+Display:wght@600;700&family=Tajawal:wght@300;400;500;700&display=swap');

/* ── Bilingual .lbl visibility (Arabic default; flips with dir/lang) ── */
.smr-app-section .lbl-en,
.smr-stats-section .lbl-en {
    display: none;
}

.smr-app-section .lbl-ar,
.smr-stats-section .lbl-ar {
    display: inline;
}

html[lang="en"] .smr-app-section .lbl-ar,
html[dir="ltr"] .smr-app-section .lbl-ar,
body.lang-en .smr-app-section .lbl-ar,
html[lang="en"] .smr-stats-section .lbl-ar,
html[dir="ltr"] .smr-stats-section .lbl-ar,
body.lang-en .smr-stats-section .lbl-ar {
    display: none;
}

html[lang="en"] .smr-app-section .lbl-en,
html[dir="ltr"] .smr-app-section .lbl-en,
body.lang-en .smr-app-section .lbl-en,
html[lang="en"] .smr-stats-section .lbl-en,
html[dir="ltr"] .smr-stats-section .lbl-en,
body.lang-en .smr-stats-section .lbl-en {
    display: inline;
}

/* ═══════════ APP SECTION ═══════════ */
.smr-app-section {
    background: #000000;
    padding: 80px 120px;
    overflow: hidden;
}

.smr-app-inner {
    max-width: 1488px;
    margin: 0 auto;
    display: flex;
    align-items: center;
    gap: 80px;
    flex-direction: row;
}

[dir="ltr"] .smr-app-inner {
    flex-direction: row-reverse;
}

.smr-app-phone-wrap {
    position: relative;
    width: 420px;
    height: 520px;
    flex-shrink: 0;
    display: flex;
    align-items: center;
    justify-content: center;
}

.smr-app-glow {
    position: absolute;
    width: 500px;
    height: 500px;
    top: 50%;
    left: 50%;
    transform: translate(-50%,-50%);
    object-fit: contain;
    z-index: 1;
    pointer-events: none;
}

.smr-app-blob {
    position: absolute;
    width: 400px;
    height: 380px;
    top: 50%;
    left: 50%;
    transform: translate(-50%,-45%);
    object-fit: contain;
    z-index: 2;
    pointer-events: none;
}

.smr-app-phone-img {
    position: relative;
    z-index: 3;
    width: 300px;
    object-fit: contain;
}

.smr-app-content {
    display: flex;
    flex-direction: column;
    gap: 16px;
    max-width: 760px;
    flex: 1;
}

[dir="rtl"] .smr-app-content {
    align-items: flex-end;
}

[dir="ltr"] .smr-app-content {
    align-items: flex-start;
}

.smr-app-title {
    font-family: 'Tajawal', sans-serif;
    font-size: 40px;
    font-weight: 700;
    background: linear-gradient(254.65deg, #69452B 10.34%, #CF8855 105.49%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    width: 100%;
}

[dir="rtl"] .smr-app-title {
    text-align: right;
}

[dir="ltr"] .smr-app-title {
    text-align: left;
}

.smr-app-subtitle {
    font-family: 'Tajawal', sans-serif;
    font-size: 22px;
    font-weight: 400;
    color: rgba(255,255,255,0.75);
}

[dir="rtl"] .smr-app-subtitle {
    text-align: right;
}

[dir="ltr"] .smr-app-subtitle {
    text-align: left;
}

.smr-app-divider {
    width: 100%;
    height: 1px;
    background: #CF8855;
    border: none;
    margin: 8px 0;
}

.smr-app-desc {
    font-family: 'Tajawal', sans-serif;
    font-size: 22px;
    font-weight: 500;
    color: rgba(255,255,255,0.85);
    line-height: 1.7;
    width: 100%;
}

[dir="rtl"] .smr-app-desc {
    text-align: right;
}

[dir="ltr"] .smr-app-desc {
    text-align: left;
}

.smr-app-store-btns {
    display: flex;
    flex-direction: row;
    align-items: center;
    gap: 20px;
    margin-top: 8px;
}

[dir="rtl"] .smr-app-store-btns {
    justify-content: flex-end;
}

[dir="ltr"] .smr-app-store-btns {
    justify-content: flex-start;
}

.smr-btn-store {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    height: 64px;
    padding: 0 28px;
    background: linear-gradient(231.82deg, #69452B 27.99%, #CF8855 102.97%);
    border-radius: 10px;
    color: #fff;
    font-family: 'Tajawal', sans-serif;
    font-size: 22px;
    font-weight: 700;
    border: none;
    cursor: pointer;
    transition: opacity 0.28s ease, transform 0.28s ease;
    text-decoration: none;
}

    .smr-btn-store:hover {
        opacity: 0.88;
        transform: translateY(-2px);
    }

    .smr-btn-store svg {
        width: 28px;
        height: 28px;
        flex-shrink: 0;
        color: #fff;
    }

/* ═══════════ STATS SECTION ═══════════ */
.smr-stats-section {
    position: relative;
    padding: 60px 80px;
    background-size: cover;
    background-position: center;
    background-attachment: fixed;
    display: flex;
    align-items: center;
    justify-content: center;
}

.smr-stats-overlay {
    position: absolute;
    inset: 0;
    background: rgba(61,51,44,0.75);
    backdrop-filter: blur(2px);
}

.smr-stats-grid {
    position: relative;
    z-index: 2;
    display: flex;
    align-items: stretch;
    justify-content: center;
    width: 100%;
    max-width: 1488px;
    gap: 0;
}

.smr-stat-item {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    padding: 16px 48px;
    border-right: 2px solid rgba(255,255,255,0.2);
    gap: 12px;
}

    .smr-stat-item:last-child {
        border-right: none;
    }

[dir="rtl"] .smr-stat-item {
    border-right: none;
    border-left: 2px solid rgba(255,255,255,0.2);
    align-items: flex-end;
}

    [dir="rtl"] .smr-stat-item:last-child {
        border-left: none;
    }

[dir="ltr"] .smr-stat-item {
    align-items: flex-start;
}

.smr-stat-label {
    font-family: 'Tajawal', sans-serif;
    font-size: 20px;
    font-weight: 500;
    color: #C8A27A;
    text-align: right;
}

[dir="ltr"] .smr-stat-label {
    text-align: left;
}

.smr-stat-number {
    font-family: 'Inter','Playfair Display',serif;
    font-size: clamp(40px,5vw,60px);
    font-weight: 500;
    color: #C8A27A;
    line-height: 1.15;
}

[dir="rtl"] .smr-stat-number {
    font-family: 'Tajawal',serif;
}

.smr-stat-desc {
    font-family: 'Tajawal', sans-serif;
    font-size: 14px;
    font-weight: 400;
    color: rgba(255,255,255,0.75);
    line-height: 1.5;
    max-width: 200px;
    text-align: right;
}

[dir="ltr"] .smr-stat-desc {
    text-align: left;
}

/* ═══════════ RESPONSIVE (tablet / mobile) ═══════════ */
@media (max-width: 1100px) {
    .smr-app-section {
        padding: 60px 40px;
    }

    .smr-stats-section {
        padding: 48px 32px;
    }
}

@media (max-width: 900px) {
    .smr-app-inner,
    [dir="ltr"] .smr-app-inner {
        flex-direction: column;
        gap: 40px;
        text-align: center;
    }

    .smr-app-content,
    [dir="rtl"] .smr-app-content,
    [dir="ltr"] .smr-app-content {
        align-items: center;
        max-width: 640px;
    }

    .smr-app-title, .smr-app-subtitle, .smr-app-desc {
        text-align: center;
    }

    .smr-app-store-btns {
        justify-content: center;
    }

    .smr-stats-grid {
        flex-wrap: wrap;
    }

    .smr-stat-item {
        flex: 1 1 45%;
        border-right: none !important;
        border-left: none !important;
        align-items: center;
        text-align: center;
    }

    .smr-stat-label, .smr-stat-desc {
        text-align: center;
    }
}

@media (max-width: 560px) {
    .smr-app-section {
        padding: 48px 20px;
    }

    .smr-app-phone-wrap {
        width: 300px;
        height: 400px;
    }

    .smr-app-phone-img {
        width: 230px;
    }

    .smr-app-title {
        font-size: 30px;
    }

    .smr-app-subtitle, .smr-app-desc {
        font-size: 18px;
    }

    .smr-stats-section {
        background-attachment: scroll;
        padding: 40px 18px;
    }

    .smr-stat-item {
        flex: 1 1 100%;
        padding: 14px;
    }
}
