﻿* {
    box-sizing: border-box;
    margin: 0;
    padding: 0
}


body {
    background: #fff;
    direction: rtl;
    font-family: 'Cairo', sans-serif;
}

a {
    text-decoration: none; /* لإزالة الخط تحت الرابط */
    color: inherit;
}

.container {
    width: 85%;
    margin: 0 auto
}

hr {
    border: 0;
    border-top: 1px solid #ccc;
    margin: 5px 0
}

.flex {
    display: flex;
    align-items: center;
    justify-content: space-between;
}
/* ================= 1. Social ICON ========================== */
.social-icons {
    display: flex;
    gap: 10px;
}

    .social-icons a {
        display: inline-flex;
        align-items: center;
        justify-content: center;
        width: 32px;
        height: 32px;
        background-color: #ddd;
        font-weight: 700; /* = bold (الافتراضي) */
        color: #333;
        text-decoration: none;
        font-size: 16px;
    }

        .social-icons a.facebook {
            background-color: #3b5998;
            color: #fff;
        }
        /* أزرق الفيسبوك */
        .social-icons a.twitter {
            background-color: #55acee;
            color: #fff;
        }
        /* أزرق تويتر */
        .social-icons a.instagram {
            background-color: #e1306c;
            color: #fff;
        }
        /* وردي انستجرام */

        .social-icons a:hover {
            opacity: 0.8;
        }


/* ================= 1. Header ========================== */
.header .row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap; /* يسمح بانتظام العناصر على عدة أسطر عند ضيق المساحة */
    padding: 8px 0;
    gap: 10px; /* مسافة مرنة بين العناصر */
}

.header .social-icons img {
    width: 24px;
    margin-left: 8px;
    cursor: pointer
}

.header .info {
    font-size: .9rem
}

    .header .info span, .header .info a {
        margin-left: 12px;
        color: #333;
        text-decoration: none
    }

.header .ads {
    flex: 1; /* يحتل المساحة المتبقية */
    margin: 0; /* إزالة الهوامش الثابتة */
    height: auto; /* يتكيف مع محتواه */
    max-height: 100px; /* لكن لا يزيد عن 100px */
    display: flex;
    align-items: center;
    justify-content: center;
}

    .header .ads img {
        width: 100%;
        height: 100%;
        object-fit: cover;
    }

.header .logo img {
    height: 60px;
    margin: 0; /* إزالة الهوامش الثابتة */
}


.header .row:nth-of-type(2) {
    gap: 20px
}

/* ترتيب أيقونات التواصل والمعلومات */
.header .social-icons,
.header .info {
    display: flex;
    align-items: center;
    gap: 8px;
}


/* ================= 2. Navbar ========================= */
nav {
    position: sticky;
    top: 0;
    background: white;
    z-index: 1000;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 10px 20px;
    border-bottom: 1px solid #ddd;
}

    nav ul {
        list-style: none;
        display: flex;
        gap: 15px;
        margin: 0;
        padding: 0;
    }

        nav ul li a {
            text-decoration: none;
            color: #333;
            font-weight: 700; /* = bold (الافتراضي) */
            transition: color 0.3s ease;
            font-size: 12px;
        }

            nav ul li a:hover {
                color: #b13446;
            }

    nav .search {
        margin-left: 20px;
        flex: 0 0 auto;
    }

        nav .search input {
            width: 200px;
            padding: 6px;
            font-size: 1rem;
        }

/* =================== Section 1 =================== */
.SECTION1 {
    margin: 20px 0;
}

.SECTION1-row1 {
    display: flex;
    justify-content: space-between;
    gap: 20px;
    margin-bottom: 30px;
}

    .SECTION1-row1 .image-container {
        position: relative; /* للتأكد من أن النصوص ستبقى داخل الصورة */
        width: 100%;
        overflow: hidden; /* منع أي شيء من الخروج عن إطار الصورة */
        height: 500px;
    }

        .SECTION1-row1 .image-container img {
            width: 100%;
            height: 500px;
            object-fit: cover;
        }

    .SECTION1-row1 .text-overlay {
        position: absolute;
        bottom: 0; /* جعل الخلفية تبدأ من أسفل الصورة */
        left: 0; /* بدء الخلفية من أقصى اليسار */
        width: 100%; /* لتغطية كامل عرض الصورة */
        color: white; /* لتكون النصوص واضحة على الصورة */
        text-align: right; /* محاذاة النص لليسار */
        padding: 20px;
        background: rgba(0, 0, 0, 0.5); /* إضافة خلفية شفافة لتسليط الضوء على النص */
        backdrop-filter: blur(4px); /* تأثير الضبابية للخلفية */
        border-radius: 0 0 10px 10px; /* حواف دائرية فقط للأسفل */
        clip-path: inset(0 0 0 0); /* لضمان أن الخلفية لن تخرج عن إطار الصورة */
    }

        .SECTION1-row1 .text-overlay .headline {
            text-align: right;
            margin-bottom: 10px;
        }

            .SECTION1-row1 .text-overlay .headline a {
                font-weight: 700;
                font-size: 18px; /*big title size */
                color: #fff; /*white*/
              
            }

                .SECTION1-row1 .text-overlay .headline a:hover {
                    color: #b13446; /*red*/
                    transition: color 0.7s ease;
                }

        .SECTION1-row1 .text-overlay .content-text {
            text-align: right;
            font-size: 14px;
            line-height: 2;
            color: #fff;
        }

/* الصف الثاني: عمودين */
.SECTION1-row2 {
    display: flex;
    gap: 20px;
}

    .SECTION1-row2 .column {
        flex: 1;
    }



        .SECTION1-row2 .column .image-container {
            max-height: 300px; /* أو أي ارتفاع تريده */
            overflow: hidden;
        }

            .SECTION1-row2 .column .image-container img {
                width: 100%;
                height: 100%;
                object-fit: cover;
            }

        .SECTION1-row2 .column .text-container {
            text-align: right;
        }

            .SECTION1-row2 .column .text-container .headline {
                margin: 10px 0;
                text-align: right;
            }

                .SECTION1-row2 .column .text-container .headline a {
                    font-weight: 700;
                    font-size: 14px; /*big title size */
                    color:#000; /*black*/
                }

                    .SECTION1-row2 .column .text-container .headline a:hover {
                        color: #b13446; /*red*/
                        transition: color 0.7s ease;
                    }

            .SECTION1-row2 .column .text-container .content-text {
                text-align: right;
                font-size: 14px;
                line-height: 2;
                color: #555;
            }

/* =================== Section 2 =================== */

.SECTION2 {
    margin: 20px 0;
}

.SECTION2-row {
    display: flex;
    gap: 20px;
}

    .SECTION2-row .news-item {
        flex: 1;
        text-align: right;
    }

        .SECTION2-row .news-item .image-container {
            height: 200px; /* تحديد ارتفاع ثابت للحاوية */
            overflow: hidden; /* منع خروج الصورة عن هذا الإطار */
        }

            .SECTION2-row .news-item .image-container img {
                width: 100%;
                height: 100%;
                object-fit: cover; /* لجعل الصورة تغطي الحاوية دون تشويه */
            }


        .SECTION2-row .news-item .text-container .headline {
            margin: 10px 0;
            text-align: right;
        }

            .SECTION2-row .news-item .text-container .headline a {
                font-weight: 700;
                font-size: 14px; /*big title size */
                color:#000; /*black*/
            }

            .SECTION2-row .news-item .text-container .headline a:hover {
                color: #b13446; /*red*/
                transition: color 0.7s ease;
            }

        .SECTION2-row .news-item .text-container .content-text {
            text-align: right;
            font-size: 14px;
            line-height: 2;
            color: #555;
        }

        .SECTION2-row .news-item .text-container .date {
            font-size: .8rem;
            color: #666;
        }

/* =================== Section 3 =================== */
.SECTION3 {
    margin: 20px 0;
}

    .SECTION3 .ad-container img {
        width: 100%;
        height: 100px;
        object-fit: cover;
    }

/* =================== Section 4 =================== */
.SECTION4 {
    margin: 20px 0;
}

.SECTION4-row {
    display: flex;
    gap: 20px;
    justify-content: space-between;
}

    .SECTION4-row .news-item {
        flex: 1;
        text-align: right;
    }

        .SECTION4-row .news-item .headline {
            margin: 10px 0;
            text-align: right;
        }

            .SECTION4-row .news-item .headline a {
                font-weight: 700;
                font-size: 14px; /*big title size */
                color:#000; /*black*/
            }

                .SECTION4-row .news-item .headline a:hover {
                    color: #b13446; /*red*/
                    transition: color 0.7s ease;
                }

      

        .SECTION4-row .news-item .date {
            text-align: right;
            font-size: 14px;
            line-height: 2;
            color: #555;
        }

/* =================== Section 5 =================== */

.SECTION5 {
    margin: 20px 0;
}

.SECTION5-row {
    display: flex;
    gap: 20px;
    align-items: stretch; /* يساوي ارتفاع الأعمدة */
}

    /* 2. تعريف الأعمدة */
    .SECTION5-row .column {
        flex: 1;
        display: flex;
        flex-direction: column;
    }

        .SECTION5-row .column .headline {
            min-height: 2.8em; /* ارتفاع مبدئي لسطرين */
            overflow: hidden;
        }

            .SECTION5-row .column .headline a {
                display: -webkit-box;
                -webkit-line-clamp: 2;
                -webkit-box-orient: vertical;
                overflow: hidden;
                text-overflow: ellipsis; /* إضافة نقاط في نهايات الجمل الطويلة */
            }


        .SECTION5-row .column .news-item {
            text-align: right;
            margin-bottom: 30px;
            flex: 1; /* اجعل الأخبار تتمّدِّد بالتساوي */
            display: flex;
            flex-direction: column;
        }

            .SECTION5-row .column .news-item .image-container {
                height: 200px; /* أو أي ارتفاع تريده */
                overflow: hidden;
            }

                .SECTION5-row .column .news-item .image-container img {
                    width: 100%;
                    height: 100%;
                    object-fit: cover;
                }




            .SECTION5-row .column .news-item .text-container .headline {
                margin: 10px 0;
                text-align: right;
            }

                .SECTION5-row .column .news-item .text-container .headline a {
                    font-weight: 700;
                    font-size: 14px; /*big title size */
                    color:#000; /*black*/
                }

                .SECTION5-row .column .news-item .text-container .headline a:hover {
                    color: #b13446; /*red*/
                    transition: color 0.7s ease;
                }

            .SECTION5-row .column .news-item .text-container .content-text {
                text-align: right;
                font-size: 14px;
                line-height: 2;
                color: #555;
            }

            .SECTION5-row .column .news-item .text-container .date {
                font-size: .8rem;
                color: #666;
            }

        /* تخصيص العمود الرابع ليحتوي فقط على صورة إعلانية */
        .SECTION5-row .column.ad-column {
            display: flex;
            flex-direction: column;
        }

            .SECTION5-row .column.ad-column .image-container {
                flex: 1; /* تأخذ كامل ارتفاع العمود */
                width: 100%; /* تأخذ كامل عرض العمود */
                overflow: hidden;
            }

                .SECTION5-row .column.ad-column .image-container img {
                    width: 100%;
                    height: 100%;
                    object-fit: cover;
                }



/* =================== Footer =================== */
.site-footer {
    background-color: #b13446;
    padding: 40px 20px 20px;
    direction: rtl;
    text-align: right;
}

.footer-container {
    display: flex;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 30px;
}

.footer-column {
    flex: 1;
    min-width: 250px;
}

.footer-title {
    font-size: 1.2rem;
    font-weight: 700;
    color: #ffffff; /* أبيض للعناوين */
    margin-bottom: 20px;
    border-bottom: 2px solid #ffffff50; /* خط سفلي شفاف قليلاً */
    padding-bottom: 8px;
}


.footer-logo {
    width: 300px;
    margin-bottom: 15px;
}

.footer-description {
    font-size: 0.9rem;
    color: #dddddd; /* 🔵 نبذة بلون رمادي فاتح واضح */
    line-height: 1.6;
}

/* =================== Social Post =================== */
/* توحيد ارتفاع كل بوست */
.social-post {
    display: flex;
    align-items: center;
    gap: 15px;
    min-height: 100px;
    max-height: 100px;
    overflow: hidden;
    background-color: transparent;
    text-decoration: none;
    color: inherit;
}

/* إطار الصورة */
.social-img-frame {
    width: 130px;
    height: 80px;
    flex-shrink: 0;
    overflow: hidden;
    background-color: #111;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 5px;
}

    /* الصورة داخل الإطار */
    .social-img-frame img {
        width: 100%;
        height: 100%;
        object-fit: cover;
        display: block;
        transition: transform 0.4s ease;
    }


/* عند المرور تكبر الصورة */
.social-post:hover .social-img-frame img {
    transform: scale(1.1);
}
/* =================== Title and Date =================== */
.post-info {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.post-title {
    font-size: 0.88rem;
    font-weight: 700;
    color: #eeeeee;
    margin-bottom: 5px;
    line-height: 1.3;
    max-height: 2.6em; /* سطرين */
    overflow: hidden;
    text-overflow: ellipsis;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
}




.post-date {
    font-size: 0.75rem;
    color: #cccccc; /* 🔵 تاريخ الخبر بلون رمادي أفتح */
}

/* =================== Hover Effects =================== */
/* عند المرور على الفيسبوك: لون خاص للعنوان */
.facebook .social-post:hover .post-title {
    color: #5ab0bd; /* لون وردي فاتح يتناسق مع الخلفية */
    transition: color 0.3s ease;
    font-weight: 700;
}

/* عند المرور على انستغرام: لون خاص للعنوان */
.instagram .social-post:hover .post-title {
    color: #f56040; /* لون أصفر ذهبي دافئ يتناسب مع الخلفية */
    transition: color 0.3s ease;
    font-weight: 700;
}


/* خط سفلي للفوتر */
.footer-bottom {
    text-align: center;
    font-size: 0.8rem;
    color: #dddddd; /* 🔵 نص الحقوق بلون واضح */
    margin-top: 40px;
    padding-top: 20px;
    border-top: 1px solid #ffffff50; /* 🔵 خط أبيض شفاف */
}

.fb-posts-wrapper {
    display: flex;
    flex-wrap: wrap;
    gap: 20px;
}

.fb-post-col {
    flex: 1;
    min-width: 250px;
    display: flex;
    flex-direction: column;
    gap: 15px;
}

/* ======= Hamburger Menu (≤768px) ======= */
.menu-toggle {
  display: none;
  font-size: 1.5rem;
  background: transparent;
  border: none;
  cursor: pointer;
  color: #333;
  padding: 0.5rem;
}

/* ======= Tablet (≤1024px) ======= */
@media (max-width: 1024px) {
  .container {
    width: 90%;
  }

  /* Section 1: from 3 cols → 2 cols */
  .SECTION1-row1, .SECTION1-row2 {
    flex-wrap: wrap;
  }
  .SECTION1-row1 .image-container,
  .SECTION1-row2 .column {
    flex: 1 1 100%;
  }

  /* Section 2: stack into single column */
  .SECTION2-row {
    flex-direction: column;
  }

  /* Section 3: sidebar under main */
  .SECTION3 {
    flex-wrap: wrap;
  }
  .SECTION3 .ad-container,
  .SECTION3 .news-item {
    flex: 1 1 100%;
  }

  /* Section 4: stack cards */
  .SECTION4-row {
    flex-direction: column;
  }

  /* Section 5: each column full width */
  .SECTION5-row {
    flex-wrap: wrap;
  }
  .SECTION5-row .column {
    flex: 1 1 100%;
  }
}

/* ======= Mobile-Large (≤768px) ======= */
@media (max-width: 768px) {
    /* ===== Hamburger Menu ===== */
    .menu-toggle {
        display: block;
    }

    nav ul {
        display: none;
        flex-direction: column;
        background: #fff;
        position: absolute;
        top: 100%;
        right: 0;
        width: 200px;
        box-shadow: 0 2px 8px rgba(0,0,0,0.15);
        z-index: 1400;
    }

        nav ul li {
            border-bottom: 1px solid #eee;
        }

            nav ul li:last-child {
                border-bottom: none;
            }

            nav ul li a {
                display: block;
                padding: 12px;
                font-size: 14px;
            }

        nav ul.open {
            display: flex;
        }

    nav .search {
        display: none;
    }

    /* ===== Header ===== */
    .header .row {
        flex-direction: column;
        align-items: center;
    }

    .header .logo img {
        height: 50px;
    }

    .header .ads {
        display: none;
    }

    .header .social-icons {
        gap: 5px;
    }

    /* ===== Sections 1–5 ===== */
    .SECTION1-row1,
    .SECTION1-row2,
    .SECTION2-row,
    .SECTION3,
    .SECTION4-row,
    .SECTION5-row {
        flex-direction: column;
        align-items: stretch;
    }

        .SECTION1-row1 .image-container,
        .SECTION1-row2 .column,
        .SECTION2-row .news-item,
        .SECTION3 .ad-container,
        .SECTION4-row .news-item,
        .SECTION5-row .column {
            flex: 1 1 100%;
        }

            /* ===== Fluid images in ads & section5 ===== */
            .SECTION3 .ad-container img,
            .SECTION5-row .column .image-container img {
                width: 100%;
                height: auto;
            }
}


/* ======= Mobile-Small (≤480px) ======= */
@media (max-width: 480px) {
  /* typography scale ↓ */
  .SECTION1-row1 .text-overlay .headline a,
  .SECTION2-row .headline a,
  .SECTION3 .small-card .news-meta .title a,
  .SECTION5-row .headline a {
    font-size: 14px;
  }
  .SECTION1-row1 .text-overlay .content-text,
  .SECTION2-row .content-text,
  .SECTION3 .small-card .news-meta .source,
  .SECTION5-row .content-text {
    font-size: 13px;
    line-height: 1.6;
  }
  nav ul li a {
    font-size: 10px;
  }


    .header .social-icons {
        gap: 5px; /* تقليل المسافات بين الأيقونات */
    }

    .header .info {
        font-size: 0.8rem; /* تصغير النص */
    }
}

@media (max-width: 576px) {
    /* typography scale ↓ */
    .SECTION1-row1 .text-overlay .headline a,
    .SECTION2-row .headline a,
    .SECTION3 .small-card .news-meta .title a,
    .SECTION5-row .headline a {
        font-size: 14px;
    }

    .SECTION1-row1 .text-overlay .content-text,
    .SECTION2-row .content-text,
    .SECTION3 .small-card .news-meta .source,
    .SECTION5-row .content-text {
        font-size: 13px;
        line-height: 1.6;
    }

    nav ul li a {
        padding: 10px;
        font-size: 1rem;
    }


    .header .social-icons {
        gap: 5px; /* تقليل المسافات بين الأيقونات */
    }

    .header .info {
        font-size: 0.8rem; /* تصغير النص */
    }
}
