:root {
    --primary: #5c7f76;
    --secondary: #3e534f;
    --glass: rgba(255, 255, 255, 0.06);
    --muted: rgba(255, 255, 255, 0.8);
    --card-bg: rgba(255, 255, 255, 0.98);
    --dark: #1f3631;
    --radius: 18px;
    --neon: 0 0 18px rgba(92, 127, 118, 0.26), 0 0 48px rgba(92, 127, 118, 0.08);
    --soft-shadow: 0 14px 40px rgba(0, 0, 0, 0.28);
    --header-h: 86px;
    --gMain: linear-gradient(135deg, var(--secondary) 0%, var(--primary) 100%);
    /* إضافة متغير لـ Section Padding الرئيسي لتوحيد المسافات */
    --section-v-padding: 80px;
}


* {
    box-sizing: border-box
}

html,
body {
    margin: 0;
    font-family: 'Tajawal', system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial;
    background: linear-gradient(-45deg, #5c7f76, #3e534f, #5c7f76, #3e534f);
    background-size: 400% 400%;
    animation: gradientMove 10s ease infinite;
    color: var(--muted);
    direction: rtl;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

@keyframes gradientMove {
    0% {
        background-position: 0% 50%;
    }

    50% {
        background-position: 100% 50%;
    }

    100% {
        background-position: 0% 50%;
    }
}


/* top floating blobs (subtle neon) */
.bg-blob {
    position: fixed;
    inset: 0;
    pointer-events: none;
    z-index: 0
}

.blob {
    position: absolute;
    border-radius: 50%;
    filter: blur(72px);
    opacity: 0.32;
    mix-blend-mode: screen
}

.b1 {
    width: 520px;
    height: 520px;
    background: radial-gradient(circle at 20% 20%, rgba(255, 255, 255, 0.08), transparent 40%);
    left: -120px;
    top: 30px;
    animation: floatA 12s ease-in-out infinite
}

.b2 {
    width: 420px;
    height: 420px;
    background: radial-gradient(circle at 70% 30%, rgba(255, 255, 255, 0.06), transparent 45%);
    right: -120px;
    top: 120px;
    animation: floatB 16s ease-in-out infinite
}

.b3 {
    width: 300px;
    height: 300px;
    background: radial-gradient(circle at 50% 50%, rgba(255, 255, 255, 0.04), transparent 45%);
    left: 44%;
    bottom: -110px;
    animation: floatC 18s ease-in-out infinite
}

@keyframes floatA {
    0% {
        transform: translateY(0)
    }

    50% {
        transform: translateY(-26px)
    }

    100% {
        transform: translateY(0)
    }
}

@keyframes floatB {
    0% {
        transform: translateY(0)
    }

    50% {
        transform: translateY(30px)
    }

    100% {
        transform: translateY(0)
    }
}

@keyframes floatC {
    0% {
        transform: translateY(0)
    }

    50% {
        transform: translateY(-44px)
    }

    100% {
        transform: translateY(0)
    }
}

/* container */
.container {
    max-width: 1300px;
    margin: 0 auto;
    padding: 0 20px;
    position: relative;
    z-index: 6
}



/* Header (القائمة العلوية) */
.header {
    position: fixed;
    top: 10px;
    left: 0;
    right: 0;
    margin: 12px auto;
    background: linear-gradient(180deg, rgba(255, 255, 255, 0.98), rgba(255, 255, 255, 0.95));
    height: var(--header-h);
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 54px 18px;
    border-radius: 40px;
    box-shadow: var(--soft-shadow);
    z-index: 999
}

/* base.css: ADD NEW RULE */
.top-scroll-blocker {
    position: sticky;
    top: 0;
    left: 0;
    right: 0;
    /* الارتفاع الإجمالي للمسافة التي نريد تغطيتها (35px + 12px) */
    height: 140px;

    /* استخدام لون الخلفية الأساسي أو الداكن لدمج أفضل */
    background: #5c7f76;
    /* #1f3631 - اللون الداكن قد يكون أفضل لتباين خلفية الجسم */

    /* لمنع ظهور المحتوى من خلاله */
    z-index: 998;
}

.logo {
    display: flex;
    align-items: center;
    gap: 12px
}

.logo-marks {
    display: flex;
    align-items: center;
    gap: 4px;
}

.logo-marks .mark {
    width: 75px;
    height: 75px;
    border-radius: 14px;
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.98), rgba(255, 255, 255, 0.96));
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: var(--neon);
    overflow: hidden;
    padding: 8px;

}

.logo-marks .mark img {
    width: 100%;
    height: 100%;
    object-fit: contain;

}

.logo .text {
    font-weight: 900;
    color: var(--primary);
    font-size: 20px
}

nav .links {
    display: flex;
    gap: 8px;
    align-items: center
}

nav a {
    color: var(--dark);
    text-decoration: none;
    font-weight: 700;
    padding: 8px 12px;
    border-radius: 12px
}

nav a:hover {
    color: #5c7f76;
}




/*********************************************************/
/* تنسيق الرابط النشط في شريط التنقل الرئيسي */
.header .links a.is-active {
    /* يمكنك اختيار أي تنسيق تفضله */
    font-weight: 700; /* جعل الخط سميكًا */
    color: var(--primary); /* تغيير لون النص إلى اللون الأساسي */
    position: relative;
}

/* يمكنك إضافة خط تحت الرابط النشط لتمييز إضافي */
.header .links a.is-active::after {
    content: '';
    position: absolute;
    bottom: -5px; /* ضع الخط تحت الرابط بقليل */
    left: 0;
    right: 0;
    height: 3px; /* سمك الخط */
    background: var(--primary); /* لون الخط */
    border-radius: 2px;
}

/* تأكد من تطبيق هذا التنسيق في حالة الجوال أيضاً */
@media (max-width: 992px) {
    .header .links.is-open a.is-active::after {
        /* قد تحتاج لإلغاء أو تعديل التمييز في قائمة الجوال المفتوحة */
        display: none; 
    }
    
    .header .links.is-open a.is-active {
        background-color: var(--secondary); /* لون خلفية مميز في قائمة الجوال */
        color: white !important;
        border-radius: 8px;
    }
}
/**********************************************************/

.cta {
    background: var(--primary);
    color: #fff;
    padding: 10px 18px;
    border-radius: 999px;
    font-weight: 900;
    box-shadow: var(--neon)

}

.cta:hover{
    background: var(--primary);
    color: #fff;
    padding: 10px 18px;
    border-radius: 999px;
    font-weight: 900;
    box-shadow: var(--neon)

}



.cta2 {
    background: #fff;
    color: var(--primary);
    padding: 15px 20px;
    border-radius: 999px;
    font-weight: 900;
    box-shadow: var(--neon);
    margin-top: 20px;
}

.cta2:hover {
    background: var(--secondary);
    color: #fff;

}

.menu-toggle {
    display: none;
    background: transparent;
    border: 0;
    font-size: 20px;
    color: var(--dark);
    cursor: pointer
}

/* section specific adjustments */

/* mission section */
#mission {
    padding-top: 0;
    /* هذا القسم أسفل الهيدر مباشرةً، نضبط له Padding خاص */
    padding-bottom: calc(var(--section-v-padding) / 2);
    margin-top: 50px;
}

.mission-section {
    text-align: center;
}

.mission-card {
    background: linear-gradient(180deg, rgba(255, 255, 255, 0.08), rgba(255, 255, 255, 0.02));
    border-radius: 22px;
    padding: 35px;
    backdrop-filter: blur(6px);
    box-shadow: var(--soft-shadow);
    border: 1px solid rgba(255, 255, 255, 0.06);
    color: #fff;
}

.hes {
    text-align: center;
    font-size: 32px;
    font-weight: 900;
    margin: 33px 0px;
    color: #fff;
    text-shadow: 0 0 10px rgba(92, 127, 118, 0.4);
}

.mission-card .slogan {
    color: var(--card-bg);
    font-weight: 800;
    font-size: 18px;
    display: block;
    margin-bottom: 20px;
}

.mission-card .mantra-grid {
    display: flex;
    justify-content: center;
    gap: 20px;
    margin: 20px 0 30px;
}

.mantra-grid div {
    font-weight: 700;
    color: var(--muted);
    position: relative;
    padding: 0 15px;
    font-size: 17px;
}

.mantra-grid div:not(:last-child)::after {
    content: '|';
    position: absolute;
    left: 0;
    color: var(--primary);
    opacity: 0.6;
}

.mission-card p {
    max-width: 800px;
    margin: 0 auto;
    line-height: 1.8;
    color: rgba(255, 255, 255, 0.9);
    font-weight: 500;
}

/* base.css: إضافة تنسيق المؤشر */
.mantra-dynamic-text {
    /* للحفاظ على الكلمات بنفس تنسيق mantra-grid */
    font-weight: 700;
    color: var(--muted);
    font-size: 17px;
    display: inline-block;
    padding-inline-end: 8px;
    /* مسافة للمؤشر */
    position: relative;
}

/* تصميم المؤشر */
.mantra-dynamic-text::after {
    content: '|';
    position: absolute;
    font-weight: 300;
    color: var(--primary);
    animation: blink .8s infinite;
}

/* إخفاء المؤشر أثناء المسح */
.mantra-dynamic-text.has-cursor::after {
    content: '';
    /* إخفاء المؤشر عندما تكون عملية المسح شغالة */
}

@keyframes blink {
    50% {
        opacity: 0;
    }
}

/* hukm moments section (special background/padding needed) */
.hukm-moments-section-v3 {
    padding-top: calc(var(--section-v-padding) / 2);
    padding-bottom: var(--section-v-padding);
    position: relative;
    overflow: hidden;
    text-align: center;
    direction: rtl;
}

.section-title-wrapper-v3 {
    margin-bottom: 70px;
    position: relative;
    z-index: 2;
}

.moments-title-v3 {
    font-size: 40px;
    font-weight: 900;
    color: #f7f7f7;
    margin-bottom: 5px;
}

.highlight-moment-v3 {

    color: white;

}

.media-gallery-v3 {
    display: flex;
    flex-wrap: nowrap;
    justify-content: center;
    gap: 10px;
    max-width: 1200px;
    margin: 0 auto;
    position: relative;
    z-index: 2;
    padding: 20px 0;
}


.media-item-v3 {
    width: 180px;
    height: 400px;
    flex-shrink: 0;
    overflow: hidden;
    border-radius: 10px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.15);
    transition: all 0.5s ease-in-out;
    position: relative;
}

.media-item-v3:hover {
    width: 350px;
    transform: scale(1.05);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
    z-index: 10;
}

.media-item-v3 img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    transition: opacity 0.3s;
}

.media-item-v3::after {
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(-45deg, #5c7f76, #3e534f, #5c7f76, #3e534f);
    opacity: 0.45;
    pointer-events: none;
}

.media-item-v3.text-highlight {
    width: 120px;
    background: #fff;
    color: transparent;
    padding: 0px 10px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    text-align: center;
    transition: all 0.5s ease-in-out;
}

.media-item-v3.text-highlight h3 {
    background-image: linear-gradient(145deg, #2E4175, #18B29B);
    background-clip: text;
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.media-item-v3.text-highlight:hover {
    width: 350px;
}

.text-highlight .highlight-text {
    font-size: 20px;
    font-weight: 700;
    margin-bottom: 0;
}


/* hero section (needs min-height and padding-top 0 since mission is above it) */
#hero {
    min-height: 82vh;
    display: flex;
    align-items: center;
    position: relative;
    padding-top: 0;
    padding-bottom: var(--section-v-padding);
    margin-top: 90px;
}

.hero-grid {
    display: grid;
    grid-template-columns: 1fr 420px;
    gap: 28px;
    align-items: center
}

.hero-card {
    background: linear-gradient(180deg, rgba(255, 255, 255, 0.06), rgba(255, 255, 255, 0.02));
    border-radius: 22px;
    padding: 28px;
    backdrop-filter: blur(8px);
    box-shadow: var(--soft-shadow);
    border: 1px solid rgba(255, 255, 255, 0.06)
}

.hero h1 {
    font-size: 46px;
    line-height: 1.02;
    color: #fff;
    margin: 6px 0;
    font-weight: 900;
    text-shadow: 0 18px 40px rgba(0, 0, 0, 0.45)
}

.tag {
    font-size: 20px;
    font-weight: 800;
    color: rgba(255, 255, 255, 0.95);
    margin-bottom: 12px
}

.hero p.lead {
    max-width: 760px;
    color: rgba(255, 255, 255, 0.92);
    font-weight: 600
}

.neon-title {
    display: inline-block;
    padding: 6px 12px;
    border-radius: 12px;
    background: linear-gradient(90deg, rgba(255, 255, 255, 0.06), rgba(255, 255, 255, 0.03));
    box-shadow: 0 10px 36px rgba(62, 83, 79, 0.14), 0 0 28px rgba(92, 127, 118, 0.08)
}

.accent {
    color: var(--primary);
    font-weight: 900
}

.cards {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
    gap: 18px;
    margin-top: 18px
}

.card {
    background: var(--card-bg);
    color: var(--dark);
    padding: 20px;
    border-radius: 14px;
    box-shadow: 0 12px 30px rgba(0, 0, 0, 0.12);
    transform: translateY(28px);
    opacity: 0;
    transition: all .6s cubic-bezier(.2, .9, .2, 1)
}

.card.visible {
    transform: none;
    opacity: 1
}

.card .icon {
    width: 56px;
    height: 56px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 20px;
    background: linear-gradient(180deg, var(--primary), var(--secondary));
    color: #fff;
    box-shadow: var(--neon)
}

.card h3 {
    margin: 12px 0 6px;
    font-weight: 800
}

.card p {
    color: #334;
    opacity: 0.9
}


/* features hero section (adjusted padding for a slight curve effect) */
#features-hero {
    padding-bottom: calc(var(--section-v-padding) / 2);
}

.features-hero {
    text-align: center
}

.features-hero h2 {
    color: #fff;
    font-weight: 900;
    font-size: 36px;
    margin: 0 0 10px
}

.features-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 24px;
    margin-top: 30px
}

.feature-card {
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.08), rgba(255, 255, 255, 0.02));
    border-radius: var(--radius);
    padding: 30px 20px;
    border: 1px solid rgba(255, 255, 255, 0.1);
    box-shadow: var(--soft-shadow);
    transition: transform .3s ease, box-shadow .3s ease;
    backdrop-filter: blur(4px);
    position: relative;
    overflow: hidden;
    text-align: center;
}

.feature-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.35), var(--neon);
}

.feature-card .icon-lrg {
    font-size: 40px;
    color: var(--primary);
    background: rgba(255, 255, 255, 0.1);
    width: 70px;
    height: 70px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 15px;
    box-shadow: var(--neon);
    position: relative;
    z-index: 2;
}

.feature-card h3 {
    color: #fff;
    font-weight: 800;
    margin: 0 0 8px;
    position: relative;
    z-index: 2;
}

.feature-card p {
    color: var(--muted);
    position: relative;
    z-index: 2;
}


.programs {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 18px;
    margin-top: 18px
}

.program {
    border-radius: 14px;
    overflow: hidden;
    border: 1px solid rgba(0, 0, 0, 0.04)
}

.program .head {
    padding: 18px;
    background: linear-gradient(90deg, var(--secondary), var(--primary));
    color: #fff;
    font-weight: 900
}

.program .body {
    padding: 18px;
    background: var(--card-bg);
    color: var(--dark)
}

.stats {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 14px;
    margin-top: 18px
}

.stat {
    background: rgba(255, 255, 255, 0.95);
    padding: 18px;
    border-radius: 12px;
    text-align: center;
    color: var(--dark);
    box-shadow: 0 12px 30px rgba(0, 0, 0, 0.06)
}

.stat .num {
    font-size: 24px;
    font-weight: 900;
    color: var(--secondary)
}

.contact-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 16px
}

.channel {
    display: block;
    padding: 16px;
    border-radius: 12px;
    background: var(--card-bg);
    color: var(--dark);
    text-decoration: none;
    box-shadow: 0 10px 26px rgba(0, 0, 0, 0.08)
}

#map {
    height: 260px;
    border-radius: 12px;
    box-shadow: var(--soft-shadow);
    overflow: hidden
}

/* contact section (adjusted padding to allow space for footer curve) */
#contact {
    padding-top: var(--section-v-padding);
    padding-bottom: calc(var(--section-v-padding) / 2);
}

/* footer */
footer {
    margin-top: 40px;
    padding: 48px 0;
    background: var(--card-bg);
    border-top-left-radius: 60px;
    border-top-right-radius: 60px;
    color: var(--primary);
    text-align: center;
    max-width: 1300px;
    margin: 0 auto;
    margin-top: 50px;
}

/* curves */
.curve-wrap {
    position: relative;
    width: 100%;
    pointer-events: none;
    margin-top: -30px
}

.curve-wrap svg {
    display: block;
    width: 100%;
    height: 90px
}

/* small screens (Responsiveness) */
@media(max-width:980px) {
    .hero-grid {
        grid-template-columns: 1fr
    }

    /* تصحيح تنسيق القائمة الجانبية للجوال (Mobile Menu) */
    .menu-toggle {
        display: block;
        z-index: 1000;
        color: var(--dark);
        cursor: pointer;
    }

    /* تهيئة القائمة في وضع الجوال: (التأثير المبهر الجديد) */
    nav .links {
        display: flex;
        flex-direction: column;
        position: fixed;
        top: 130px;
        right: 0;
        width: 70%;
        max-width: 300px;
       
        background: var(--card-bg);
        padding: 24px 18px;
        box-shadow: -4px 0 30px rgba(0, 0, 0, 0.4);
        /* ظل أقوى */
        z-index: 998;
        gap: 0;
        overflow-y: auto;
        border-top-left-radius: 30px;
        /* زوايا منحنية */
        border-bottom-left-radius: 30px;

        /* حالة الإخفاء: يتم سحبها لليمين ووضعها في حالة إخفاء بصرية */
        transform: translateX(100%) scale(0.9) rotateY(-10deg);
        opacity: 0;
        visibility: hidden;
        transition: transform 0.4s cubic-bezier(0.2, 0.9, 0.2, 1), opacity 0.4s ease-in, visibility 0s 0.4s;
    }

    /* حالة الفتح: (تأثير الظهور المبهر) */
    nav .links.is-open {
        transform: translateX(0) scale(1) rotateY(0deg);
        opacity: 1;
        visibility: visible;
        transition: transform 0.4s cubic-bezier(0.2, 0.9, 0.2, 1), opacity 0.4s ease-out, visibility 0s;
    }

    /* تنسيق عناصر القائمة داخل القائمة الجانبية */
    nav .links a {
        padding: 12px 12px;
        width: 100%;
        text-align: right;
        border-radius: 8px;
        font-size: 18px;
    }

    nav .links .cta {
        margin-top: 15px;
    }

    /* توحيد مسافات الأقسام للجوال */
    main section {
        padding-top: 50px;
        padding-bottom: 50px;
    }

    /* تعديل الأقسام التي تحتاج تعديل خاص للجوال */
    #mission {
        padding-bottom: 25px;
    }

    .hukm-moments-section-v3 {
        padding-top: 25px;
        padding-bottom: 50px;
    }

    #hero {
        padding-bottom: 50px;
    }

    #features-hero {
        padding-bottom: 25px;
    }

    #contact {
        padding-bottom: 25px;
    }
}

@media(max-width:768px) {
    .features-grid {
        grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    }

    .media-gallery-v3 {
        overflow-x: scroll;
        justify-content: flex-start;
        padding-bottom: 10px;
    }

    .media-item-v3 {
        width: 100px;
        height: 300px;
    }

    .media-item-v3:hover {
        width: 280px;
        transform: none;
    }

    .media-item-v3.text-highlight:hover {
        width: 280px;
    }
}

@media(max-width:640px) {
    .stats {
        grid-template-columns: repeat(2, 1fr)
    }

    .hero h1 {
        font-size: 28px
    }

    .container {
        padding: 0 12px
    }

    .header {
        padding: 0 12px;
        margin-left: 35px;
        margin-right: 35px;
    }

    .hero h1 {
        font-size: 24px;
    }

    .features-hero h2 {
        font-size: 28px;
    }
}

.slide-in-left {
    transform: translateX(26px);
    opacity: 0;
    transition: all .7s cubic-bezier(.2, .9, .2, 1)
}

.slide-in-right {
    transform: translateX(-26px);
    opacity: 0;
    transition: all .7s cubic-bezier(.2, .9, .2, 1)
}

.in-view {
    transform: none;
    opacity: 1
}

.btn-ghost {
    border-radius: 12px;
    padding: 10px 16px;
    border: 1px solid rgba(255, 255, 255, 0.08);
    background: transparent;
    color: #fff;
    font-weight: 800;
    transition: all 0.3s ease
}

.btn-ghost:hover {
    transform: translateY(-4px);
    box-shadow: var(--neon)
}

a:focus,
button:focus {
    outline: 3px solid rgba(92, 127, 118, 0.18);
    outline-offset: 3px
}







/* ======================================================= */
/* تنسيقات قسم الشراكات (Partnerships Section Styles) */
/* ======================================================= */

/* 1. حاوية الرؤية (The Viewport Container) - ثابتة وبعرض الشاشة */
.partnerships-grid {
    display: flex;
    align-items: center;
    overflow: hidden; 
    width: 100%; 
    padding: 20px 0;
    
    /* توسيط الشعارات في منتصف الشريط الأفقي */
    justify-content: center;
    margin-bottom: 80px;
}

/* 2. المحتوى الداخلي (Scrolling Content) - الآن هو محتوى ثابت */
.scrolling-content {
    display: flex;
    flex-wrap: wrap; /* لتوزيع الشعارات في صفوف إذا لم يتسع سطر واحد */
    gap: 20px;
    
    /* إلغاء أي عرض زائد أو حركة سابقة */
    min-width: unset; 
    animation: none; 
    
    /* توسيط الشعارات داخل الحاوية */
    justify-content: center;
    width: 100%;
}

/* 3. تنسيق شعار الشريك */
.partnership-logo {
    background: white;
    border-radius: 12px;
    padding: 15px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.05);
    /* Transition فقط للعناصر التي تتغير بشكل سلس (مثل الظل) */
    transition: box-shadow var(--transition);
    display: flex;
    align-items: center;
    justify-content: center;
    /* تحديد حجم ثابت للصندوق */
    min-width: 140px; 
    height: 100px;
}

/* 4. تنسيق الصورة داخل الشعار */
.partnership-logo img {
    max-width: 100%;
    width: auto;
    max-height: 100%;
    object-fit: contain; /* لضمان ظهور الشعار كاملاً دون اقتصاص */
}

/* 5. تأثيرات التفاعل (Hover Effects) */
.partnership-logo:hover {
    /* تطبيق التكبير والظل */
    transform: scale(1.05); 
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.1);
    
    /* تطبيق حركة الاهتزاز عند التمرير بالماوس */
    animation: jiggle 0.4s ease-in-out infinite; /* تتكرر الحركة اللانهائية */
}

/* ======================================================= */
/* 6. تعريف الحركة (Jiggle Keyframes) */
/* ======================================================= */
@keyframes jiggle {
    0%, 100% {
        /* العودة للوضع الطبيعي مع التكبير */
        transform: translateX(0) scale(1.05); 
    }
    25% {
        /* اهتزاز خفيف لليسار */
        transform: translateX(-3px) scale(1.05); 
    }
    75% {
        /* اهتزاز خفيف لليمين */
        transform: translateX(3px) scale(1.05); 
    }
}


/* ======================================================= */
/* Mobile Optimization for Partnerships Section */
/* ======================================================= */
@media(max-width: 768px) {
    
    /* 1. تعديل حاوية الرؤية (The Viewport Container) */
    .partnerships-grid {
        /* إزالة أي حشو (Padding) أفقي زائد قد يعيق التمرير */
        padding: 0;
    }

    /* 2. تعديل المحتوى الداخلي (Scrolling Content) لتمكين التمرير */
    .scrolling-content {
        /* إجبار الشعارات على البقاء في سطر واحد */
        flex-wrap: nowrap; 
        
        /* تمكين التمرير الأفقي */
        overflow-x: scroll;
        
        /* لإخفاء شريط التمرير (اختياري) */
        -ms-overflow-style: none; /* IE and Edge */
        scrollbar-width: none; /* Firefox */
        
        /* إضافة حشو (Padding) أفقي لجعل الشعار الأول لا يلتصق بحافة الشاشة */
        padding: 0 16px; 
        
        /* التأكد من أن الشعارات تبدأ من اليمين (RTL) */
        justify-content: flex-start;
    }
    
    /* إخفاء شريط التمرير في متصفحات Webkit (Chrome, Safari) */
    .scrolling-content::-webkit-scrollbar {
        display: none;
    }

    /* 3. تعديل حجم الشعار للهاتف المحمول */
    .partnership-logo {
        /* جعل الشعارات أصغر قليلاً لتناسب شاشات الجوال */
        min-width: 110px; 
        height: 80px;
        
        /* مهم: منع الشعارات من الانكماش أو التمدد لتثبيت حجمها */
        flex-shrink: 0; 
        flex-grow: 0;
        
        /* تقليل الفجوة عن العرض الكامل */
        margin-left: 20px;
        margin-right: 0;
    }
    
    /* 4. إلغاء تأثير الاهتزاز عند التمرير في الجوال (لأن اللمس ليس Hover) */
    .partnership-logo:hover {
        transform: none; 
        box-shadow: 0 5px 15px rgba(0, 0, 0, 0.05); /* العودة للظل العادي */
        animation: none;
    }
}