/*=============== PROJECT DETAILS STYLES ===============*/

/* Hero Slider Section */
.header-details {
    margin-top: 80px;
    /* Space for navbar */
    background: var(--body-color);
}

.portfolio-details-slider {
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
    overflow: hidden;
}

.portfolio-details-slider img {
    width: 100%;
    height: 60vh;
    object-fit: cover;
}

/* About Section for Projects */
.about {
    padding: 4rem 0;
    background: var(--body-color);
}

.about .content h3 {
    font-weight: 700;
    font-size: 2rem;
    margin-bottom: 1.5rem;
    color: var(--title-color);
}

.about .content p {
    margin-bottom: 1.5rem;
    line-height: 1.8;
    color: var(--text-color);
    opacity: 0.9;
}

.about-btn {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    background: #efc1a9;
    color: #fff;
    padding: 0.75rem 2rem;
    border-radius: 0.5rem;
    font-weight: 600;
    transition: 0.3s;
}

.about-btn:hover {
    background: #d4a894;
    color: #fff;
    transform: translateY(-3px);
}

/* Icon Boxes */
.icon-box {
    background: var(--container-color);
    padding: 1.5rem;
    border-radius: 1rem;
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.05);
    margin-bottom: 1rem;
    border: 1px solid rgba(239, 193, 169, 0.1);
    transition: 0.3s;
}

.icon-box:hover {
    transform: translateY(-5px);
    border-color: #efc1a9;
}

.icon-box h5 {
    font-size: 1.1rem;
    font-weight: 700;
    margin-bottom: 0.5rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    color: var(--title-color);
}

.icon-box h5 i {
    color: #efc1a9;
    font-size: 1.4rem;
}

.icon-box p {
    margin: 0;
    color: var(--text-color);
    opacity: 0.8;
    font-size: 0.95rem;
}

/* Features Section (Services) */
.services {
    padding: 4rem 0;
    background: var(--first-color-lighten);
}

.project-ion .services {
    background: rgba(239, 193, 169, 0.8);
}

.project-midtower .services,
.project-harmont .services {
    background: #240dfd17;
}

.dark-theme .services {
    background: var(--container-color);
}

.section-title {
    text-align: center;
    margin-bottom: 3rem;
}

.section-title h2 {
    font-size: 2rem;
    font-weight: 700;
    margin-bottom: 1rem;
    position: relative;
    display: inline-block;
}

.section-title h2::after {
    content: '';
    position: absolute;
    width: 50px;
    height: 3px;
    background: #efc1a9;
    bottom: -10px;
    left: 50%;
    transform: translateX(-50%);
}

.services .icon-box {
    text-align: center;
    height: 100%;
}

.services .icon-box .icon {
    width: 60px;
    height: 60px;
    background: rgba(239, 193, 169, 0.1);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 1.5rem;
    transition: 0.3s;
}

.services .icon-box:hover .icon {
    background: #efc1a9;
}

.services .icon-box:hover .icon i {
    color: #fff;
}

.services .icon-box .icon i {
    font-size: 2rem;
    color: #efc1a9;
}

.services .icon-box h4 {
    font-size: 1.25rem;
    font-weight: 700;
    margin-bottom: 1rem;
}

/* Swiper overrides */
.swiper-pagination-bullet-active {
    background: #efc1a9 !important;
}

/* RTL Specifics */
body.rtl .about .content h3 {
    text-align: right;
}

body.rtl .about .content p {
    text-align: right;
}

body.rtl .icon-box {
    text-align: right;
}

body.rtl .icon-box h5 {
    flex-direction: row;
    /* Icon then text */
}

body.rtl .icon-box h5 i {
    margin-left: 0.5rem;
    margin-right: 0;
}

@media (max-width: 991px) {
    .portfolio-details-slider img {
        height: 40vh;
    }

    .about .content {
        margin-bottom: 2rem;
    }
}

/*=============== ENHANCED ARABIC MOBILE PROJECT STYLES ===============*/
@media screen and (max-width: 1023px) {

    /* بطاقات المشاريع للموبايل بالعربي */
    body.rtl .projects__container,
    body[dir="rtl"] .projects__container {
        display: grid;
        grid-template-columns: 1fr;
        gap: 2rem;
        padding: 0 1rem;
    }

    body.rtl .project-card,
    body[dir="rtl"] .project-card {
        direction: rtl;
        text-align: right;
        border-radius: 1rem;
        overflow: hidden;
    }

    body.rtl .project-card__image,
    body[dir="rtl"] .project-card__image {
        height: 220px;
        width: 100%;
    }

    body.rtl .project-card__content,
    body[dir="rtl"] .project-card__content {
        padding: 1.5rem;
        text-align: right;
    }

    body.rtl .project-card__title,
    body[dir="rtl"] .project-card__title {
        font-size: 1.25rem;
        margin-bottom: 0.75rem;
        text-align: right;
        line-height: 1.4;
    }

    body.rtl .project-card__description,
    body[dir="rtl"] .project-card__description {
        font-size: 0.938rem;
        line-height: 1.7;
        text-align: right;
        margin-bottom: 1rem;
    }

    body.rtl .project-card__button,
    body[dir="rtl"] .project-card__button {
        display: inline-flex;
        flex-direction: row-reverse;
        align-items: center;
        gap: 0.5rem;
        padding: 0.75rem 1.5rem;
        font-size: 0.938rem;
    }

    body.rtl .project-card__button::after,
    body[dir="rtl"] .project-card__button::after {
        transform: scaleX(-1);
    }

    /* قسم الـ About للمشاريع */
    body.rtl .about .content,
    body[dir="rtl"] .about .content {
        text-align: right;
    }

    body.rtl .about .content h3,
    body[dir="rtl"] .about .content h3 {
        font-size: 1.5rem;
        text-align: right;
        line-height: 1.4;
    }

    body.rtl .about .content p,
    body[dir="rtl"] .about .content p {
        font-size: 0.938rem;
        text-align: right;
        line-height: 1.8;
    }

    body.rtl .about-btn,
    body[dir="rtl"] .about-btn {
        flex-direction: row-reverse;
    }

    /* صناديق الأيقونات */
    body.rtl .icon-box,
    body[dir="rtl"] .icon-box {
        text-align: right;
        padding: 1.25rem;
    }

    body.rtl .icon-box h5,
    body[dir="rtl"] .icon-box h5 {
        flex-direction: row-reverse;
        justify-content: flex-start;
    }

    body.rtl .icon-box p,
    body[dir="rtl"] .icon-box p {
        text-align: right;
    }

    /* قسم الميزات */
    body.rtl .services,
    body[dir="rtl"] .services {
        padding: 3rem 0;
    }

    body.rtl .services .icon-box,
    body[dir="rtl"] .services .icon-box {
        text-align: center;
    }

    body.rtl .section-title,
    body[dir="rtl"] .section-title {
        text-align: center;
    }

    body.rtl .section-title h2,
    body[dir="rtl"] .section-title h2 {
        font-size: 1.5rem;
    }
}

@media screen and (max-width: 576px) {

    body.rtl .project-card__image,
    body[dir="rtl"] .project-card__image {
        height: 180px;
    }

    body.rtl .project-card__content,
    body[dir="rtl"] .project-card__content {
        padding: 1.25rem;
    }

    body.rtl .project-card__title,
    body[dir="rtl"] .project-card__title {
        font-size: 1.125rem;
    }

    body.rtl .project-card__description,
    body[dir="rtl"] .project-card__description {
        font-size: 0.875rem;
    }

    body.rtl .project-card__button,
    body[dir="rtl"] .project-card__button {
        font-size: 0.875rem;
        padding: 0.625rem 1.25rem;
    }

    body.rtl .about .content h3,
    body[dir="rtl"] .about .content h3 {
        font-size: 1.375rem;
    }

    body.rtl .icon-box,
    body[dir="rtl"] .icon-box {
        padding: 1rem;
    }

    body.rtl .icon-box h5,
    body[dir="rtl"] .icon-box h5 {
        font-size: 1rem;
    }

    body.rtl .icon-box p,
    body[dir="rtl"] .icon-box p {
        font-size: 0.875rem;
    }
}

@media screen and (max-width: 400px) {

    body.rtl .project-card__image,
    body[dir="rtl"] .project-card__image {
        height: 160px;
    }

    body.rtl .project-card__content,
    body[dir="rtl"] .project-card__content {
        padding: 1rem;
    }

    body.rtl .project-card__title,
    body[dir="rtl"] .project-card__title {
        font-size: 1rem;
    }

    body.rtl .project-card__description,
    body[dir="rtl"] .project-card__description {
        font-size: 0.813rem;
    }

    body.rtl .about .content h3,
    body[dir="rtl"] .about .content h3 {
        font-size: 1.25rem;
    }

    body.rtl .about .content p,
    body[dir="rtl"] .about .content p {
        font-size: 0.875rem;
    }
}

/*=============== PROJECT CARD SLIDER (SWIPER) ENHANCED ===============*/
/*=============== PROJECT CARD SLIDER (SWIPER) ENHANCED ===============*/
.project-card {
    background: var(--container-color);
    border-radius: 1.5rem;
    overflow: hidden;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.08);
    border: 1px solid rgba(239, 193, 169, 0.15);
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
    display: flex;
    flex-direction: column;
}

.project-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 20px 40px rgba(239, 193, 169, 0.2);
    border-color: rgba(239, 193, 169, 0.4);
}

.project-card__image-container {
    position: relative;
    width: 100%;
    height: 280px;
    overflow: hidden;
}

/* Elegant radial overlay for image depth */
.project-card__image-container::after {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(to top, rgba(0, 0, 0, 0.6) 0%, transparent 50%, transparent 100%);
    z-index: 2;
    pointer-events: none;
}

.project-card__slider {
    width: 100%;
    height: 100%;
}

.project-card__slide {
    width: 100%;
    height: 100%;
    background-size: cover;
    background-position: center;
    transition: transform 1.2s cubic-bezier(0.4, 0, 0.2, 1);
}

.project-card:hover .project-card__slide {
    transform: scale(1.08);
}

/* PAGINATION - BOTTOM STYLE */
.project-card-swiper-pagination {
    bottom: 20px !important;
    left: 20px !important;
    width: auto !important;
    text-align: left !important;
    z-index: 10 !important;
}

body.rtl .project-card-swiper-pagination,
body[dir="rtl"] .project-card-swiper-pagination {
    left: auto !important;
    right: 20px !important;
    text-align: right !important;
}

.project-card-swiper-pagination .swiper-pagination-bullet {
    background: #fff;
    opacity: 0.5;
    width: 20px;
    height: 3px;
    border-radius: 2px;
    transition: all 0.4s ease;
    margin: 0 3px !important;
}

.project-card-swiper-pagination .swiper-pagination-bullet-active {
    background: #efc1a9 !important;
    opacity: 1;
    width: 35px;
}

/* NAVIGATION ARROWS - BOTTOM POSITION TOGETHER */
.project-card-swiper-button-next,
.project-card-swiper-button-prev {
    top: auto !important;
    bottom: 15px !important;
    width: 40px !important;
    height: 40px !important;
    background: rgba(255, 255, 255, 0.2) !important;
    backdrop-filter: blur(8px);
    border: 1px solid rgba(255, 255, 255, 0.3);
    border-radius: 8px;
    color: #efc1a9 !important;
    margin: 0 !important;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1) !important;
    display: flex !important;
    align-items: center;
    justify-content: center;
}

/* Position them side by side */
.project-card-swiper-button-prev {
    right: 65px !important;
    left: auto !important;
}

.project-card-swiper-button-next {
    right: 15px !important;
}

/* RTL Support for arrows */
body.rtl .project-card-swiper-button-prev,
body[dir="rtl"] .project-card-swiper-button-prev {
    right: auto !important;
    left: 65px !important;
}

body.rtl .project-card-swiper-button-next,
body[dir="rtl"] .project-card-swiper-button-next {
    right: auto !important;
    left: 15px !important;
}

.project-card-swiper-button-next::after,
.project-card-swiper-button-prev::after {
    font-size: 18px !important;
    font-weight: 900;
}

.project-card-swiper-button-next:hover,
.project-card-swiper-button-prev:hover {
    background: #efc1a9 !important;
    color: #fff !important;
    border-color: #efc1a9 !important;
    transform: translateY(-3px);
    box-shadow: 0 4px 12px rgba(239, 193, 169, 0.3);
}

/* Arrows always visible on modern cards */
.project-card-swiper-button-next,
.project-card-swiper-button-prev {
    opacity: 0.8;
    visibility: visible;
}

.project-card:hover .project-card-swiper-button-next,
.project-card:hover .project-card-swiper-button-prev {
    opacity: 1;
    background: rgba(255, 255, 255, 0.2);
}

/* Grid layout for home projects container */
@media screen and (min-width: 1024px) {
    .projects__container {
        grid-template-columns: repeat(3, 1fr) !important;
        gap: 2rem !important;
    }
}

@media screen and (max-width: 768px) {
    .project-card__image-container {
        height: 220px;
    }

    .project-card-swiper-button-next,
    .project-card-swiper-button-prev {
        width: 32px !important;
        height: 32px !important;
    }

    .project-card-swiper-button-prev {
        right: 52px !important;
    }

    body.rtl .project-card-swiper-button-prev,
    body[dir="rtl"] .project-card-swiper-button-prev {
        left: 52px !important;
    }
}