/* ========================================
   SECTION PROJETS (RÉALISATIONS)
   ======================================== */

/* Section Projets */
.section-projets {
    position: relative;
    display: flex;
    justify-content: flex-end;
    align-items: stretch;
    padding: 0;
    overflow: hidden;
    background-color: #212121;
    font-family: Arial, sans-serif;
}

/* Image de fond avec la télé (avec transparence) */
.background-tv {
    position: absolute;
    bottom: -3%;
    left: -17%;
    width: 140%;
    height: 140%;
    z-index: 1;
    opacity: 0;
    object-fit: cover;
    background-color: #212121;
}

.section-projets.section-visible .background-tv {
    animation: fadeInBackground 1s ease forwards;
}

@keyframes fadeInBackground {
    to {
        opacity: 1;
    }
}

.tv-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center;
    transform: scale(1.1);
    pointer-events: none;
    z-index: 10;
}

.section-projets.section-visible .tv-image {
    animation: zoomIn 1.2s ease forwards;
}

@keyframes zoomIn {
    to {
        transform: scale(1);
    }
}

/* Zone de l'écran de télé - CENTRÉ */
.tv-screen {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 100%;
    height: 100%;
    overflow: hidden;
    z-index: 0;
    background-color: #212121;
    
}

/* ============================================
   LOGO PAR DÉFAUT - RÈGLES CRITIQUES
   ============================================ */
.project-preview.default-preview {
    position: absolute;
    top: 0;
    left: 0;
    width: 0%;
    height: 0%;
    object-fit: cover;
    object-position: center;
    z-index: 0;
    
    transition: opacity 0.3s ease, transform 0.3s ease;
    pointer-events: none;
}

/* ============================================
   VIDÉOS D'APERÇU
   ============================================ */
.project-preview.video-preview {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center;
    z-index: 0;
    opacity: 0;
    filter: brightness(0.9) contrast(1.05);
    
    transition: opacity 0.4s ease, transform 0.4s ease;
    pointer-events: none;
}

.project-preview.video-preview.active {
    opacity: 1;
    z-index: 1;
}

/* Section tableau */

.projets-titre {
    
    position: absolute;
    top: 15%;
    left: 25%;
    transform: translate(-50%, -50%) scaleY(2);
    font-size: 3.5vw;
    font-weight: 1000;
    color: #2272ff;
    text-transform: uppercase;
    line-height: 0.75;
    letter-spacing: -1px;
    white-space: nowrap;
    font-family: 'ImpactWeb', Impact, Arial, sans-serif;
    transform-origin: center center;
    z-index: 1001;
    pointer-events: none;
}

.table-section {
    position: relative;
    z-index: 100;
    width: 45%;
    min-height: 100vh;
    background: transparent;
    overflow-y: auto;
    padding: 80px 40px 40px;
    opacity: 0;
    transform: translateX(50px);
}

.section-projets.section-visible .table-section {
    animation: slideInFromRight 0.8s ease forwards 0.3s;
}

@keyframes slideInFromRight {
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

.table-section::-webkit-scrollbar {
    width: 6px;
}

.table-section::-webkit-scrollbar-track {
    background: rgba(255, 255, 255, 0.1);
}

.table-section::-webkit-scrollbar-thumb {
    background: rgba(34, 114, 255, 0.7);
    border-radius: 3px;
}

.table-section::-webkit-scrollbar-thumb:hover {
    background: #2272ff;
}

.table-header {
    margin-bottom: 40px;
    opacity: 0;
    background: transparent;
    padding: 0;
    border-radius: 0;
    box-shadow: none;
    transform: translateY(20px);
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.section-projets.section-visible .table-header {
    animation: fadeInUp 0.6s ease forwards 0.5s;
}

@keyframes fadeInUp {
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.table-header h2 {
    font-family: 'ImpactWeb', Impact, Arial, sans-serif;
    font-size: 3.5vh;
    transform: scaleY(1.8);
    font-weight: 1000;
    color: #2272ff;
    margin-bottom: 0;
    letter-spacing: -2px;
    margin-left: 0;
    white-space: nowrap;
    text-transform: uppercase;
    text-align: left;
    align-self: flex-start;
}

.subtitle {
    font-size: 0.88rem;
    color: white;
    font-weight: 600;
    letter-spacing: 0.02em;
    margin-bottom: 0;
    padding: 28px;
    background: rgba(21, 21, 21, 1);
    border-radius: 10px;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.2);
    text-align: center;
}

/* Tableau des projets */
.projects-table {
    opacity: 1;
}

.table-headers {
    display: grid;
    grid-template-columns: 2fr 3fr 1fr;
    gap: 20px;
    padding: 15px 20px;
    border-bottom: 2px solid rgba(26, 26, 26, 0.3);
    margin-bottom: 8px;
    background: rgba(255, 255, 255, 0.3);
    border-radius: 6px;
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.1);
    opacity: 0;
    transform: translateY(20px);
}

.section-projets.section-visible .table-headers {
    animation: fadeInUp 0.1s ease forwards 0.1s;
}

.header-cell {
    font-family: 'Work Sans', sans-serif;
    font-size: 0.68rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.15em;
    color: black;
}

.table-body {
    display: flex;
    flex-direction: column;
}

/* ============================================
   LIGNES DE PROJET
   ============================================ */

.project-row {
    display: grid;
    grid-template-columns: 2fr 3fr 1fr;
    gap: 20px;
    padding: 20px 20px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    cursor: pointer;
    transition: all 0.1s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
    background: rgba(255, 255, 255, 0);
    margin-bottom: 6px;
    border-radius: 6px;
    overflow: hidden;
    opacity: 0;
    transform: translateX(-30px);
}

.projets-titre{
    top: 12%;
    left: 27%;
}
.section-projets.section-visible .project-row {
    animation: slideInFromLeft 0.5s ease forwards;
}

@keyframes slideInFromLeft {
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

/* Animation échelonnée pour chaque projet */
.section-projets.section-visible .project-row:nth-child(1) { animation-delay: 1.2s; }
.section-projets.section-visible .project-row:nth-child(2) { animation-delay: 1.3s; }
.section-projets.section-visible .project-row:nth-child(3) { animation-delay: 1.4s; }
.section-projets.section-visible .project-row:nth-child(4) { animation-delay: 1.5s; }
.section-projets.section-visible .project-row:nth-child(5) { animation-delay: 1.6s; }
.section-projets.section-visible .project-row:nth-child(6) { animation-delay: 1.7s; }
.section-projets.section-visible .project-row:nth-child(7) { animation-delay: 1.8s; }
.section-projets.section-visible .project-row:nth-child(8) { animation-delay: 1.9s; }

.project-row::before {
    content: '';
    position: absolute;
    left: 0;
    top: 0;
    width: 3px;
    height: 0%;
    background-color: #2272ff;
    transition: height 0.2s cubic-bezier(0.4, 0, 0.2, 1);
    border-radius: 6px 0 0 6px;
}

.project-row:hover {
    background: rgba(255, 255, 255, 0.1);
    box-shadow: 0 12px 40px rgba(0, 0, 0, 0.2);
    transform: translateX(0px);
}

.project-row:hover::before {
    height: 100%;
}

/* État déplié */
.project-row.expanded {
    grid-template-columns: 1fr;
    padding: 10px;
    background: rgba(255, 255, 255, 0.15);
    margin: 0px 0;
}

.project-row.expanded::before {
    height: 100%;
}

.project-row.expanded .cell {
    display: block;
}

.cell {
    display: flex;
    flex-direction: column;
    justify-content: center;
    transition: all 0s cubic-bezier(0.4, 0, 0.2, 1);
}

.cell.project-name {
    display: flex;
    align-items: left;
    font-family: Impact, 'Arial Narrow Bold', sans-serif;
    font-weight: 10;
}

.cell.project-duration {
    display: flex;
    align-items: center;
}

.project-name {
    font-size: 1.2rem;
    font-weight: 600;
    color: White;
    letter-spacing: -0.01em;
}

/* Description courte (visible par défaut) */
.project-desc-short {
    font-size: 1rem;
    color: white;
    line-height: 1.6;
    font-weight: 400;
    transition: opacity 0.3s ease;
    display: block;
    width: 100%;
}

/* Description longue (visible quand déplié) */
.project-desc-long {
    font-size: 0.80rem;
    color: white;
    line-height: 1.2;
    font-weight: 400;
    max-height: 0;
    opacity: 0;
    overflow: hidden;
    margin-top: 0;
    display: block;
    width: 100%;
}

.project-row.expanded .project-desc-short {
    opacity: 0;
    max-height: 0;
    overflow: hidden;
    transition: all 0s ease;
}

.project-row.expanded .project-desc-long {
    max-height: 500px;
    opacity: 1;
    margin-top: 16px;
}

.project-duration {
    font-size: 0.92rem;
    color: white;
    font-weight: 500;
    text-align: right;
    justify-content: flex-end;
}

/* Bouton "Voir le projet" */
.project-button {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 10px 10px;
    margin-top: 18px;
    background: linear-gradient(135deg, #2272ff, #1a5acc);
    color: white;
    text-decoration: none;
    font-family: 'Work Sans', sans-serif;
    font-size: 0.78rem;
    font-weight: 600;
    border-radius: 6px;
    border: 2px solid transparent;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    max-height: 0;
    opacity: 0;
    overflow: hidden;
    pointer-events: none;
}

.project-row.expanded .project-button {
    max-height: 50px;
    opacity: 1;
    pointer-events: auto;
}

.project-button:hover {
    background: linear-gradient(135deg, #1a5acc, #2272ff);
    border-color: white;
    transform: translateY(-2px);
    box-shadow: 0 8px 20px rgba(34, 114, 255, 0.4);
}

.project-button::after {
    content: '→';
    font-size: 1.1rem;
    transition: transform 0.3s ease;
}

.project-button:hover::after {
    transform: translateX(5px);
}

/* Animation au survol (quand NON déplié) */
.project-row:not(.expanded):hover .project-name {
    color: #2272ff;
    transform: translateX(5px);
}

.project-row:not(.expanded):hover .project-desc-short {
    color: white;
}

.project-row:not(.expanded):hover .project-duration {
    color: #2272ff;
    font-weight: 600;
}

/* Animation d'entrée progressive pour chaque ligne */
.project-row {
    opacity: 1;
}


.cinego{
    color: #2272ff;
    font-weight: 700;
}