
body {
    background-color: #F1EFE9;
}


/* SLIDER */
.slider {
    display: flex;
    justify-content: center;
    height: 100vh;
    background-size: 100%;
    background: url(../imgs/hero.jpeg);
    background-position: center center;
}

    .slider button {
        background-color: #31514C;
        color: white;
    }

.slidertxt {
    padding-top: 100px;
    font-weight: bold;
    width: 50%;
    text-align: center;
    color: white;
    font-size: 800;
}

.statistics {
    display: flex;
    justify-content: center;
    margin-top: -8%;
    background-image: linear-gradient( to right, #6FB7AC, #31514C);
    margin: -8% auto 0px auto;
    border-radius: 10px;
    width: 85%;
}

.statisticsitem {
    text-align: center;
    color: white;
    padding-left: 50px;
    padding-right: 50px;
}

    .statisticsitem i {
        color: #A78C61;
        font-size: 60px;
    }

.vr {
    width: 3px;
    background-color: #F9F4E9;
    height: 105px;
    margin-top: 20px;
    border-radius: 1px;
}








/* ABOUT SECTION */

.highlight {
    background: linear-gradient(to top, #FFAF00 50%, transparent 50%);
    display: inline;
}

.aboutsection {
    position: relative;
    margin-top: 100px;
    margin-bottom: 150px;
    display: inline-block;
}

    .aboutsection p {
        font-weight: 400;
        font-size: 30px;
        line-height: 1.5;
        text-align: right;
        width: 120%;
        color: #31514CB2;
    }

.about-img {
    width: 419px;
}

.before-img {
    width: 10px;
    height: 100%;
    margin-left: 10px;
    background-image: linear-gradient(to bottom, #31514C 50%, transparent 50%);
}

.after-img {
    width: 10px;
    height: 100%;
    margin-right: 10px;
    background-image: linear-gradient(to top, #A78C61 50%, transparent 50%);
}

.overlap-img {
    width: 419px;
    height: 441px;
    position: absolute;
    top: 60%;
    left: 25%;
}






.card img {
    height: 247px;
}






/* SWIPER */

.swiper {
    margin: -200px auto 0 auto;
    height: 500px;
    width: 70%;
}

.swiper-slide {
    text-align: center;
    font-size: 18px;
    height: 500px;
    margin-top: 100px;
    /* Center slide text vertically */
    display: flex;
    justify-content: center;
    align-items: center;
}

    .swiper-slide img {
        display: block;
        width: 100%;
        object-fit: cover;
    }


.sliderforswiper {
    background-image: url(../imgs/bgsvg.svg);
    background-position: top;
    background-color: #31514C;
    text-align: center;
    height: 500px;
}

.sliderhead {
    width: 100%;
    padding: 100px 0;
}

    .sliderhead h3 {
        color: #A78C61;
    }

    .sliderhead p {
        color: #F9F4E9B2;
    }

.swiper-slide-active {
    margin-top: 0px !important;
    height: 500px;
}






/* FIRST TERM */
.firstterm {
    text-align: center;
    margin: 150px auto;
}

.x {
    margin-right: 13rem;
}

.firsttermcard {
    text-align: center;
    margin: 10px;
    padding: 20px 0px;
    background-color: white;
    border-radius: 10px;
}













/*IADEALS HOME*/

.ideal {
    text-align: center;
    width: 90%;
    background-color: #E8E8E2;
    padding: 5rem;
    border-radius: 15px;
}

.idealtitle {
    margin-bottom: 5rem;
}

.ideal .card {
    margin-top: 5rem;
    box-shadow: -1px 1px 9px 0px #31514C80;
    background-color: #F9F4E9;
    border-radius: 10px;
}

.ideal .active {
    margin-top: 0rem;
}

.card p {
    font-size: 13px;
    font-weight: bold;
    line-height: 1;
}

    .card p span {
        font-weight: lighter;
    }

.idealtitle p {
    color: #31514c;
}

.idealcardimg {
    top: -15%;
    left: 25%;
    border-radius: 50%;
    overflow: hidden;
    position: absolute;
}

.ideal h5 {
    color: #31514c;
}




/* WHAT SLIDER */

.whatslider {
    background-image: url(../imgs//bg2svg.svg);
    background-repeat: no-repeat;
    background-color: #31514C;
    text-align: right;
    height: 650px;
}

    .whatslider .card {
        margin-top: 5rem;
        width: 100%;
        box-shadow: -1px 1px 9px 0px #31514C80;
    }

    .whatslider .active {
        margin-top: 0rem;
    }

.whatcardbody {
    display: flex;
    justify-content: space-between;
    background-image: url(../imgs/bg3svg.svg);
    background-repeat: no-repeat;
}

.whatcard img {
    width: 50px;
    height: 50px;
    border-radius: 50%;
}

.whatcarddetails {
    width: 80%;
}





/* FOOTER */

.footersection {
    background: #A78C6166 40%;
    padding: 5rem;
    margin-top: 5rem;
}

    .footersection span {
        color: #FFAF00;
    }

.fa-facebook {
    color: #1877f2;
}

.fa-whatsapp {
    color: #60D669;
}

.fa-x-twitter {
    color: #000000;
}

.fa-youtube {
    color: #FF0000;
}














/* LOGIN*/

.loginform {
    display: flex;
    justify-content: center;
    background: #DBDBDB0D;
    backdrop-filter: blur(25px);
    width: 50%;
    margin: -8% auto 0px auto;
    padding: 5rem;
}

    .loginform label {
        font-weight: bold;
    }

    .loginform p {
        line-height: 1;
        font-size: smaller;
        margin-bottom: 5rem;
    }

    .loginform .btn1 {
        color: white;
        background: #31514C;
        margin-bottom: 1rem;
    }

    .loginform .btn2 {
        border: 1px solid #31514C;
    }

    .loginform h3 {
        font-weight: 500;
        font-size: 48px;
        line-height: 100%;
        letter-spacing: 0%;
        text-align: center;
        vertical-align: middle;
        color: #FFAF00;
    }







/* IDEALS PAGE*/
.idealstext p {
    font-weight: 400;
    font-size: 24px;
    line-height: 1.5;
    letter-spacing: 0%;
    text-align: right;
    vertical-align: middle;
    margin: 3rem 0;
    color: #31514C;
}

.idealstext h3 {
    font-weight: 400;
    font-size: 36px;
    line-height: 1.5;
    letter-spacing: 0%;
    text-align: right;
    vertical-align: middle;
    color: #A78C61;
}

.idealstext h4 {
    font-weight: 400;
    font-size: 36px;
    line-height: 1.5;
    letter-spacing: 0%;
    text-align: right;
    vertical-align: middle;
    color: #31514C;
    text-underline-position: below;
    text-decoration: underline;
}












/*TAFSEER COURSE*/

.content {
    background: #F9F4E9B2;
    padding: 2rem;
    margin-top: 2rem;
}




/*STUDENT REGISTER*/

.sidebar {
    text-align: right;
    background-color: white;
    height: 100vh;
    padding: 0 2rem;
}

    .sidebar img {
        margin: 1rem 5rem 1rem 0;
    }

    .sidebar h5 {
        font-weight: 600;
        font-size: 18px;
        line-height: 2;
        letter-spacing: 0%;
        color: black;
    }

    .sidebar a {
        text-decoration: none;
        color: black;
    }

    .sidebar h5 i {
        color: #31514C;
        margin-left: 1rem;
    }

.settings {
    margin-top: 10rem;
}






.controlcard {
    background-color: white;
    border-radius: 15px;
    padding: 3rem;
}

    .controlcard h5 {
        padding: 0
    }

    .controlcard i {
        background-color: #F9F4E9;
        border-radius: 50%;
        padding: 1rem;
        margin-left: 3rem
    }
/* Navbar على خلفية بيضاء: روابط داكنة لتكون مرئية */
.navbar {
    background-color: #ffffff; /* تأكد أنّ الخلفية بيضاء */
}

    .navbar .nav-link {
        color: #31514C !important; /* لون داكن واضح */
    }

        .navbar .nav-link:hover,
        .navbar .nav-link.active {
            color: #FFAF00 !important; /* لون تمييز عند المرور أو العنصر النشط */
        }

    /* إذا لديك أزرار داخل الـnavbar */
    .navbar .btn1 {
        background-color: #31514C; /* زر أساسي داكن */
        color: #ffffff; /* نص الزر أبيض */
    }

    .navbar .btn2 {
        border-color: #31514C; /* إطار داكن */
        color: #31514C; /* نص الإطار داكن */
    }

/* إضافة على نهاية style.css */
.firstterm {
    position: relative; /* ليعمل التحريك على الـtop */
    opacity: 0; /* يبدأ مخفي */
    animation: slideUpFadeIn 3s ease-out forwards;
    animation-delay: 0.5s; /* تأخير نصف ثانية قبل بدء التحريك */
}

@keyframes slideUpFadeIn {
    from {
        transform: translateY(50px);
        opacity: 0;
    }

    to {
        transform: translateY(0);
        opacity: 1;
    }
}

/* جعل <span> الأرقام يتقلّب صعودًا وهبوطًا بلطف */
.firsttermcard h3 span {
    display: inline-block; /* ضروري لتطبيق التحويل */
    animation: bounce 2s ease infinite;
}

/* تعريف الحركة */
@keyframes bounce {
    0%, 20%, 50%, 80%, 100% {
        transform: translateY(0);
    }

    40% {
        transform: translateY(-15px);
    }

    60% {
        transform: translateY(-10px);
    }
}
/* —————— إظهار عناصر الإحصاء بالانزلاق والتلاشي —————— */
.statisticsitem {
    position: relative; /* ليعمل التحريك على top */
    opacity: 0; /* يبدأ مخفي */
    animation: slideUpFadeIn 3s ease-out forwards;
    animation-delay: 0.5s; /* تأخير قبل البدء */
}

    /* نفس keyframes الموجود مسبقًا للـslideUpFadeIn */

    /* —————— تأثير الـbounce على الأرقام —————— */
    .statisticsitem h6 {
        display: inline-block; /* ضروري لتطبيق التحويل */
        animation: bounce 2s ease infinite;
    }

/* نفس keyframes للـbounce الموجود لديك */

/* ======== Section Container ======== */
.prayer-calendar-section {
    background: #F9F4E9;
    border-radius: 12px;
    max-width: 1000px;
    margin: 50px auto;
}

/* ======== Cards Layout ======== */
/* Prayer cards wrapper */
.prayer-cards {
    display: flex;
    flex-wrap: wrap;
    gap: 1rem;
    justify-content: center;
    margin: 0 auto;
    padding: 0;
    list-style: none;
}

/* Each card: base half-width, up to a max, and shrink/grow */
.prayer-card {
    flex: 1 1 calc(50% - 1rem);
    max-width: calc(50% - 1rem);
    background-color: #fff;
    border-radius: 8px;
    padding: 1rem;
    box-shadow: 0 4px 8px rgba(0,0,0,0.1);
    text-align: center;
}

/* On tablets and up, show 3 per row */
@media (min-width: 768px) {
    .prayer-card {
        flex: 1 1 calc(33.333% - 1rem);
        max-width: calc(33.333% - 1rem);
    }
}

/* On very small phones, full-width */
@media (max-width: 576px) {
    .prayer-card {
        flex: 1 1 100%;
        max-width: 100%;
    }
}

/* ======== Hover Effect ======== */
.prayer-card:hover {
    transform: translateY(-5px) scale(1.03);
    box-shadow: 0 8px 16px rgba(0,0,0,0.15);
}

/* ======== Typography ======== */
.prayer-card h5 {
    margin-bottom: 0.5rem;
    font-size: 1.1rem;
    color: #31514C;
}

.prayer-card p {
    font-size: 1.4rem;
    font-weight: bold;
    color: #2E2E2E;
}
/* ======== Next Prayer Card ======== */
.next-prayer-card {
    max-width: 300px;
    margin: 0 auto 2rem;
    background: #31514C;
    color: #FFF;
    text-align: center;
    border-radius: 10px;
    padding: 1rem 0.5rem;
    box-shadow: 0 4px 12px rgba(0,0,0,0.2);
    animation: slideUpFadeIn 1.5s ease-out forwards;
    opacity: 0;
    animation-delay: 0.5s;
}


    .next-prayer-card h5 {
        margin-bottom: 0.5rem;
        font-size: 1.2rem;
    }

    .next-prayer-card p {
        margin: 0.2rem 0;
        font-size: 1.5rem;
        font-weight: bold;
    }

.next-prayer-card {
    background: #2E4B45; /* أخف بدرجة */
}

@keyframes pulse {
    0%, 100% {
        transform: scale(1);
    }

    50% {
        transform: scale(1.05);
    }
}

#next-prayer-timer {
    animation: pulse 2s ease-in-out infinite;
}

@media (max-width: 576px) {
    .next-prayer-card {
        width: 90%;
        margin: 1rem auto;
    }
}
/* ===== تحسين الاستجابة للـ Next Prayer Card ===== */
@media (max-width: 576px) {
    /* اجعل البطاقة بعرض مناسب مع مساحات جانبية */
    .next-prayer-card {
        width: 90%;
        max-width: none; /* الغي الحد الأقصى */
        margin: 1.5rem auto; /* مسافة أكبر من الأعلى والأسفل */
        padding: 1rem; /* حشو مناسب للنص */
        border-radius: 8px; /* تدوير أقل على الحواف */
    }

    /* إذا كنت تريد إخفاء بطاقات الصلاة الأخرى أو جعلها أسفل البطاقة */
    .prayer-cards {
        display: block; /* إخفاء البطاقات الأخرى في الموبايل */
    }
}








/* --- Responsive Enhancements & RTL Fixes --- */

/* General rule to prevent horizontal overflow */
body {
    overflow-x: hidden;
}

/* Ensure images are responsive by default */
img {
    max-width: 100%;
    height: auto;
}

/* Slider Section */
.slider {
    align-items: center;
    min-height: 60vh;
    background: url(../imgs/hero.jpeg) center center / cover no-repeat !important;
    padding: 20px 0;
}

.slidertxt {
    width: 90%;
    max-width: 700px;
    margin-left: auto;
    margin-right: auto;
    padding-top: 20px; /* Adjusted from original 100px, consider removing if slider align-items:center is enough */
}

    .slidertxt h3 {
        font-size: 2.5rem; /* Base size */
        line-height: 1.4;
    }

/* Statistics Section */
.statistics {
    width: 90%;
    max-width: 1140px;
    margin-top: -60px;
    padding: 20px 10px;
}

.statisticsitem {
    padding: 15px 5px;
}

    .statisticsitem i {
        font-size: 40px;
        margin-bottom: 8px;
    }

    .statisticsitem h4 {
        font-size: 1.1rem;
        margin-bottom: 4px;
    }

    .statisticsitem h6 {
        font-size: 1.5rem;
    }

/* Navbar specific RTL and mobile considerations */
.navbar-brand {
    margin-right: 0;
    margin-left: 1rem;
}

.navbar-collapse.collapse.show .navbar-nav,
.navbar-collapse.collapsing .navbar-nav {
    align-items: flex-end;
}

    .navbar-collapse.collapse.show .navbar-nav .nav-link,
    .navbar-collapse.collapsing .navbar-nav .nav-link {
        text-align: right;
        width: 100%;
    }

/* About Section - width: 120% was problematic */
.aboutsection p {
    width: 100%; /* Corrected from 120% */
    font-size: 1.1rem;
}

/* Mobile Responsiveness */
@media (max-width: 767.98px) {
    .slidertxt h3 {
        font-size: 1.5rem;
    }

    .slidertxt {
        padding-top: 20px;
    }

    .slider {
        min-height: 50vh;
    }

    .statistics {
        margin-top: -40px;
        width: 95%;
    }

    .statisticsitem i {
        font-size: 30px;
    }

    .statisticsitem h4 {
        font-size: 0.9rem;
    }

    .statisticsitem h6 {
        font-size: 1.3rem;
    }

    .next-prayer-card {
        font-size: 0.9em;
    }

        .next-prayer-card h5 {
            font-size: 1.1rem;
        }

        .next-prayer-card p {
            font-size: 1.3rem;
        }

    .aboutsection p {
        font-size: 1rem;
    }

    .aboutsection .col-md-6 {
        padding: 15px !important;
    }

    .about-img, .overlap-img {
        width: 100%;
        height: auto;
        position: static !important;
        margin-bottom: 15px;
    }

    .before-img, .after-img {
        display: none;
    }
}

/* عن المنصة */
.aboutsection .prayer-calendar-section {
    max-width: 600px;
    padding: 2rem;
    box-shadow: 0 4px 12px rgba(0,0,0,0.1);
}

/* الصور في القسم */
.aboutsection .overlap-img {
    position: absolute;
    top: 15%;
    right: -10%;
    width: 60%;
    border: 4px solid #fff;
}

/* Responsive Tweaks */
@media (max-width: 576px) {
    /* قلل البادينغ داخل prayer-calendar-section */
    .aboutsection .prayer-calendar-section {
        padding: 1rem;
        max-width: 100%;
    }
    /* ضع الصور بشكل طبيعي */
    .aboutsection .about-img,
    .aboutsection .overlap-img {
        position: static;
        width: 100%;
        margin: 0.5rem 0;
        border: none;
    }
}
