/* Project Details Page Styles */

/* Project Hero */
.project-hero {
    padding: 180px 0 60px;
    background-color: var(--white);
    text-align: right;
}

.project-badge {
    display: inline-block;
    font-size: 32px;
    font-weight: 400;
    color: var(--secondary-color);
    margin-bottom: 15px;
}

.project-title {
    font-size: 45px;
    font-weight: 700;
    color: var(--primary-color);
    line-height: 1.4;
}

/* Project Gallery Section */
.project-gallery-section {
    padding: 40px 0 80px;
    background-color: var(--white);
}

.project-content {
    display: flex;
    flex-direction: row-reverse;
    gap: 40px;
    align-items: flex-start;
    margin-bottom: 30px;
}

/* Project Info Box */
.project-info-box {
    width: 400px;
    min-width: 400px;
    background-color: var(--white);
    border-radius: 20px;
    padding: 30px;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.1);
}

.info-title {
    font-size: 24px;
    font-weight: 700;
    color: var(--primary-color);
    margin-bottom: 25px;
    text-align: center;
}

.info-item {
    margin-bottom: 20px;
    padding-bottom: 15px;
    border-bottom: 1px solid rgba(0, 0, 0, 0.1);
}

.info-item:last-child {
    margin-bottom: 0;
    padding-bottom: 0;
    border-bottom: none;
}

.info-label {
    display: block;
    font-size: 16px;
    font-weight: 700;
    color: var(--primary-color);
    margin-bottom: 8px;
}

.info-value {
    display: block;
    font-size: 18px;
    font-weight: 400;
    color: var(--text-light);
    line-height: 1.6;
}

/* Project Gallery */
.project-gallery {
    flex: 1;
}

/* ✅ Gallery Main */
.gallery-main {
    position: relative;
    width: 100%;
    max-width: 860px;
    border-radius: 20px;
    overflow: hidden;
    background-color: #f5f5f5;
}

/* ✅ Gallery Main Image - height ثابت */
.gallery-main img {
    width: 100%;
    height: 475px;
    object-fit: cover;
    display: block;
}

.gallery-btn {
    position: absolute;
    bottom: 20px;
    left: 20px;
    background-color: var(--secondary-color);
    color: var(--white);
    border: none;
    padding: 12px 25px;
    border-radius: 10px;
    font-size: 16px;
    font-weight: 700;
    cursor: pointer;
    transition: background-color 0.3s ease, transform 0.3s ease;
    z-index: 5;
}

.gallery-btn:hover {
    background-color: #e0a400;
    transform: translateY(-2px);
}

/* Thumbnails */
.gallery-thumbnails {
    display: flex;
    gap: 15px;
    justify-content: flex-start;
    margin-top: 20px;
}

.thumbnail {
    width: 150px;
    height: 100px;
    border-radius: 10px;
    overflow: hidden;
    cursor: pointer;
    opacity: 0.6;
    transition: opacity 0.3s ease, border-color 0.3s ease;
    border: 3px solid transparent;
}

.thumbnail:hover,
.thumbnail.active {
    opacity: 1;
    border-color: var(--secondary-color);
}

.thumbnail img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

/* Project Overview */
.project-overview {
    padding: 60px 0;
    background-color: var(--white);
}

.overview-title {
    font-size: 32px;
    font-weight: 700;
    color: var(--primary-color);
    margin-bottom: 25px;
    text-align: right;
}

.overview-text {
    font-size: 22px;
    font-weight: 400;
    color: rgba(31, 51, 78, 0.9);
    line-height: 1.9;
    text-align: right;
    margin-bottom: 20px;
}

.overview-text:last-child {
    margin-bottom: 0;
}

/* Challenges Section */
.project-challenges {
    padding: 0 0 60px;
    background-color: var(--white);
}

.challenges-title {
    font-size: 32px;
    font-weight: 700;
    color: var(--primary-color);
    margin-bottom: 25px;
    text-align: right;
}

.challenges-text {
    font-size: 22px;
    font-weight: 400;
    color: rgba(31, 51, 78, 0.9);
    line-height: 1.9;
    text-align: right;
    margin-bottom: 20px;
}

.challenges-text:last-child {
    margin-bottom: 0;
}

/* Lightbox */
.lightbox {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.95);
    z-index: 9999;
    display: none;
    justify-content: center;
    align-items: center;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.lightbox.active {
    display: flex;
    opacity: 1;
}

.lightbox-content {
    max-width: 90%;
    max-height: 85%;
    display: flex;
    justify-content: center;
    align-items: center;
}

.lightbox-content img {
    max-width: 100%;
    max-height: 85vh;
    object-fit: contain;
    border-radius: 10px;
}

.lightbox-close {
    position: absolute;
    top: 30px;
    right: 30px;
    background: none;
    border: none;
    color: var(--white);
    cursor: pointer;
    padding: 10px;
    transition: color 0.3s ease, transform 0.3s ease;
    z-index: 10000;
}

.lightbox-close:hover {
    color: var(--secondary-color);
    transform: scale(1.1);
}

.lightbox-nav {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background: rgba(255, 255, 255, 0.1);
    border: none;
    color: var(--white);
    cursor: pointer;
    padding: 15px;
    border-radius: 50%;
    transition: background-color 0.3s ease, color 0.3s ease;
    z-index: 10000;
}

.lightbox-nav:hover {
    background: var(--secondary-color);
    color: var(--white);
}

.lightbox-prev {
    right: 30px;
}

.lightbox-next {
    left: 30px;
}

.lightbox-counter {
    position: absolute;
    bottom: 30px;
    left: 50%;
    transform: translateX(-50%);
    color: var(--white);
    font-size: 18px;
    font-weight: 700;
}

/* Responsive */
@media (max-width: 1200px) {
    .project-title {
        font-size: 38px;
    }
    
    .overview-title,
    .challenges-title {
        font-size: 28px;
    }
    
    .overview-text,
    .challenges-text {
        font-size: 20px;
    }
    
    .gallery-main img {
        height: 400px;
    }
}

@media (max-width: 992px) {
    .project-content {
        flex-direction: column;
    }
    
    .project-info-box {
        width: 100%;
        min-width: auto;
    }
    
    .gallery-main {
        max-width: 100%;
    }
    
    .gallery-main img {
        height: 350px;
    }
    
    .project-title {
        font-size: 32px;
    }
    
    .project-badge {
        font-size: 24px;
    }
    
    .overview-title,
    .challenges-title {
        font-size: 26px;
    }
    
    .overview-text,
    .challenges-text {
        font-size: 18px;
    }
    
    .gallery-thumbnails {
        justify-content: center;
        flex-wrap: wrap;
    }
    
    .thumbnail {
        width: 120px;
        height: 80px;
    }
}

@media (max-width: 768px) {
    .project-hero {
        padding: 140px 0 40px;
        text-align: center;
    }
    
    .project-title {
        font-size: 26px;
    }
    
    .project-badge {
        font-size: 20px;
    }
    
    .gallery-main img {
        height: 280px;
    }
    
    .overview-title,
    .challenges-title {
        font-size: 24px;
        text-align: center;
    }
    
    .overview-text,
    .challenges-text {
        font-size: 16px;
        text-align: center;
    }
    
    .thumbnail {
        width: 80px;
        height: 60px;
    }
    
    .lightbox-nav {
        padding: 10px;
    }
    
    .lightbox-prev {
        right: 15px;
    }
    
    .lightbox-next {
        left: 15px;
    }
}