/* Gallery Section */
.gallery-section {
    padding: 80px 0;
    background: linear-gradient(135deg, #ffffff 0%, #f5f7fa 50%, #ebebec 100%);
    min-height: 100vh;
    position: relative;
    overflow: hidden;
}

.gallery-section::before {
    content: '';
    position: absolute;
    top: 0;
    right: 0;
    width: 500px;
    height: 500px;
    background: radial-gradient(circle, rgba(246, 90, 42, 0.08) 0%, transparent 70%);
    border-radius: 50%;
    z-index: 0;
}

.gallery-section::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 500px;
    height: 500px;
    background: radial-gradient(circle, rgba(28, 43, 57, 0.05) 0%, transparent 70%);
    border-radius: 50%;
    z-index: 0;
}

.gallery-section > .container {
    position: relative;
    z-index: 1;
}

/* Title Section */
.text-center.mb-5 {
    margin-bottom: 70px !important;
    animation: slideDown 0.6s ease;
}

.section-title-large {
    font-size: 48px !important;
    font-weight: 800 !important;
    letter-spacing: -1px;
    text-transform: uppercase;
    background: linear-gradient(135deg, #1c2b39 0%, #f65a2a 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    margin-bottom: 20px !important;
    text-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);
}

.section-subtitle {
    font-size: 18px !important;
    color: #555 !important;
    max-width: 700px;
    margin: 0 auto !important;
    line-height: 1.8;
    font-weight: 500;
}

@keyframes slideDown {
    from {
        opacity: 0;
        transform: translateY(-30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Projects Tabs Container */
.projects-tabs-container {
    margin-bottom: 70px;
    background: white;
    border-radius: 20px;
    padding: 0;
    box-shadow: 0 12px 40px rgba(0, 0, 0, 0.1);
    backdrop-filter: blur(10px);
    animation: slideUp 0.6s ease 0.2s both;
}

@keyframes slideUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.projects-tabs-list {
    display: flex;
    list-style: none;
    padding: 0;
    margin: 0;
    gap: 0;
    border-radius: 20px;
    overflow: hidden;
    background: linear-gradient(90deg, #f8f9fa 0%, #ffffff 100%);
}

.projects-tab-item {
    flex: 1;
    display: flex;
}

.projects-tab-btn {
    flex: 1;
    background: transparent;
    color: #1c2b39;
    border: none;
    padding: 20px 28px;
    font-size: 16px;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.35s cubic-bezier(0.23, 1, 0.320, 1);
    text-transform: uppercase;
    letter-spacing: 1px;
    border-bottom: 4px solid transparent;
    text-decoration: none;
    position: relative;
    overflow: hidden;
}

.projects-tab-btn::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(246, 90, 42, 0.1), transparent);
    transition: left 0.5s ease;
}

.projects-tab-btn:first-child {
    border-left: none;
}

.projects-tab-btn:not(:last-child) {
    border-right: 2px solid #e8e8e8;
}

.projects-tab-btn:hover {
    background: rgba(246, 90, 42, 0.08);
    color: #f65a2a;
    transform: translateY(-2px);
}

.projects-tab-btn:hover::before {
    left: 100%;
}

.projects-tab-btn.active {
    background: linear-gradient(135deg, rgba(246, 90, 42, 0.12), rgba(234, 102, 59, 0.08));
    color: #f65a2a;
    border-bottom-color: #f65a2a;
    box-shadow: inset 0 -4px 0 #f65a2a;
    font-weight: 800;
}

/* Projects Content */
.projects-content {
    animation: fadeIn 0.6s ease;
}

.project-content {
    display: none;
    animation: fadeIn 0.5s ease;
}

.project-content.active {
    display: block;
    animation: slideIn 0.5s cubic-bezier(0.23, 1, 0.320, 1);
}

@keyframes slideIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes fadeIn {
    from {
        opacity: 0;
    }
    to {
        opacity: 1;
    }
}

/* Project Info */
.project-info {
    background: white;
    padding: 50px;
    /* border-radius: 18px; */
    margin-bottom: 60px;
    box-shadow: 0 15px 45px rgba(0, 0, 0, 0.1);
    border-top: 6px solid #f65a2a;
    border-left: 6px solid rgba(246, 90, 42, 0.3);
    position: relative;
    overflow: hidden;
}

.project-info::before {
    content: '';
    position: absolute;
    top: -50%;
    right: -50%;
    width: 400px;
    height: 400px;
    background: radial-gradient(circle, rgba(246, 90, 42, 0.05) 0%, transparent 70%);
    border-radius: 50%;
}

.project-info > * {
    position: relative;
    z-index: 1;
}

.project-info h2 {
    color: #1c2b39;
    font-size: 38px;
    font-weight: 800;
    margin-bottom: 30px;
    text-transform: uppercase;
    letter-spacing: 1.5px;
    position: relative;
    display: inline-block;
}

.project-info h2::after {
    content: '';
    position: absolute;
    bottom: -10px;
    left: 0;
    width: 60px;
    height: 5px;
    background: linear-gradient(90deg, #f65a2a, #ea663b);
    border-radius: 3px;
}

.project-info p {
    color: #555;
    font-size: 16px;
    line-height: 2;
    margin-bottom: 15px;
    font-weight: 500;
}

.project-info p:last-child {
    margin-bottom: 0;
}

.project-info strong {
    color: #f65a2a;
    font-weight: 800;
    letter-spacing: 0.5px;
}

/* Project Gallery Grid */
.project-gallery {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 40px;
    padding: 20px;
}

/* Item Galerie */
.gallery-item {
    opacity: 1;
    transform: scale(1);
    transition: all 0.5s ease;
    cursor: pointer;
    animation: fadeInScale 0.6s ease;
}

@keyframes fadeInScale {
    from {
        opacity: 0;
        transform: scale(0.85);
    }
    to {
        opacity: 1;
        transform: scale(1);
    }
}

.gallery-image-wrapper {
    position: relative;
    overflow: hidden;
    border-radius: 18px;
    box-shadow: 0 15px 40px rgba(0, 0, 0, 0.15);
    aspect-ratio: 1;
    background: linear-gradient(135deg, #e0e0e0 0%, #d0d0d0 100%);
    transition: all 0.4s ease;
}

.gallery-image-wrapper:hover {
    box-shadow: 0 25px 60px rgba(246, 90, 42, 0.3);
    transform: translateY(-8px);
}

.gallery-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.6s cubic-bezier(0.23, 1, 0.320, 1);
    display: block;
}

.gallery-item:hover .gallery-image {
    transform: scale(1.2) rotate(2deg);
    filter: brightness(0.6) saturate(1.2);
}

/* Overlay */
.gallery-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(135deg, rgba(0, 0, 0, 0.5) 0%, rgba(246, 90, 42, 0.3) 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: opacity 0.35s ease;
    border-radius: 18px;
}

.gallery-item:hover .gallery-overlay {
    opacity: 1;
}

.view-btn {
    width: 80px;
    height: 80px;
    background: linear-gradient(135deg, #f65a2a, #ea663b);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 32px;
    transition: all 0.35s cubic-bezier(0.23, 1, 0.320, 1);
    box-shadow: 0 15px 35px rgba(246, 90, 42, 0.5);
    text-decoration: none;
    position: relative;
}

.view-btn::before {
    content: '';
    position: absolute;
    inset: -3px;
    background: linear-gradient(135deg, #f65a2a, #ea663b);
    border-radius: 50%;
    opacity: 0;
    transition: opacity 0.35s ease;
    filter: blur(10px);
}

.view-btn:hover {
    transform: scale(1.2) rotate(10deg);
    box-shadow: 0 20px 50px rgba(246, 90, 42, 0.7);
}

.view-btn:hover::before {
    opacity: 0.5;
}

/* Lightbox personnalisée */
.lightbox {
    background-color: rgba(0, 0, 0, 0.95) !important;
}

.lightbox img {
    border-radius: 15px;
}

/* Réactivité */
@media (max-width: 1024px) {
    .gallery-section {
        padding: 60px 0;
    }

    .section-title-large {
        font-size: 40px !important;
    }

    .project-info {
        padding: 40px;
    }

    .project-info h2 {
        font-size: 32px;
    }

    .projects-tabs-container {
        margin-bottom: 50px;
    }
}

@media (max-width: 768px) {
    .gallery-section {
        padding: 50px 0;
    }

    .section-title-large {
        font-size: 32px !important;
    }

    .section-subtitle {
        font-size: 16px !important;
    }

    .project-gallery {
        grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
        gap: 25px;
        padding: 15px;
    }

    .projects-tab-btn {
        padding: 16px 18px;
        font-size: 14px;
        letter-spacing: 0.5px;
    }

    .project-info {
        padding: 30px;
        margin-bottom: 45px;
    }

    .project-info h2 {
        font-size: 26px;
    }

    .project-info p {
        font-size: 15px;
        line-height: 1.7;
    }

    .view-btn {
        width: 70px;
        height: 70px;
        font-size: 28px;
    }

    .gallery-image-wrapper {
        border-radius: 15px;
    }

    .text-center.mb-5 {
        margin-bottom: 50px !important;
    }
}

@media (max-width: 480px) {
    .gallery-section {
        padding: 40px 0;
        background: linear-gradient(135deg, #ffffff 0%, #f5f7fa 100%);
    }

    .gallery-section::before,
    .gallery-section::after {
        display: none;
    }

    .section-title-large {
        font-size: 28px !important;
        margin-bottom: 15px !important;
    }

    .section-subtitle {
        font-size: 15px !important;
        margin-top: 12px !important;
    }

    .project-gallery {
        grid-template-columns: 1fr;
        gap: 18px;
        padding: 10px;
    }

    .projects-tabs-list {
        flex-direction: column;
        border-radius: 15px;
    }

    .projects-tab-btn {
        padding: 14px 14px;
        font-size: 13px;
        letter-spacing: 0.3px;
        border-right: none !important;
        border-bottom: 2px solid #e0e0e0 !important;
    }

    .projects-tab-item:not(:last-child) .projects-tab-btn {
        border-bottom: 2px solid #e0e0e0 !important;
    }

    .projects-tab-btn.active {
        border-bottom: 3px solid #f65a2a !important;
        border-right: none !important;
        border-left: 4px solid #f65a2a;
    }

    .projects-tabs-container {
        margin-bottom: 40px;
        border-radius: 15px;
    }

    .project-info {
        padding: 20px;
        margin-bottom: 35px;
        border-radius: 15px;
        border-top: 4px solid #f65a2a;
    }

    .project-info h2 {
        font-size: 22px;
        margin-bottom: 20px;
    }

    .project-info h2::after {
        width: 50px;
    }

    .project-info p {
        font-size: 14px;
        line-height: 1.6;
        margin-bottom: 12px;
    }

    .gallery-image-wrapper {
        border-radius: 12px;
    }

    .view-btn {
        width: 60px;
        height: 60px;
        font-size: 24px;
    }

    .text-center.mb-5 {
        margin-bottom: 35px !important;
    }
}
