/* ==========================================================================
   PAGE D'ACCUEIL - CONTENU UNIQUE (style.css)
   ========================================================================== */

/* CONTENEUR GLOBAL DE DÉFILEMENT */
.scroll-container {
    width: 100%;
    transition: transform 1s cubic-bezier(0.76, 0, 0.24, 1);
    will-change: transform;
}

.page-section {
    height: 100vh;
    width: 100%;
    display: flex;
    justify-content: center;
    align-items: center;
    position: relative;
    padding: 0 8%;
    background-color: var(--bg-creme);
}

/* NOM GÉANT INTERACTIF */
.center-stage {
    height: 100vh;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    position: relative;
    z-index: 10;
}

.name-wrapper {
    text-align: center;
}

.interactive-text {
    font-size: 10rem;
    font-weight: 800;
    letter-spacing: -4px;
    line-height: 0.8;
    display: flex;
    justify-content: center;
    user-select: none;
    opacity: 0;
    animation: smoothFadeUp 1.4s cubic-bezier(0.215, 0.610, 0.355, 1) forwards;
}

.interactive-text.ln {
    font-size: 13.5rem;
    font-weight: 900;
    letter-spacing: -6px;
    margin-top: 30px; 
    animation-delay: 0.2s;
}

.letter-box {
    position: relative;
    display: inline-block;
}

.reveal-letter {
    display: inline-block;
    cursor: pointer;
    color: var(--text-dark);
    transition: transform 0.2s ease-out, color 0.2s ease;
}

.letter-box:hover .reveal-letter {
    color: #857966;
    transform: translateY(-8px) scale(1.06) rotate(1.5deg);
    transition: transform 0.1s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

.letter-box::after {
    content: attr(data-adj);
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    display: flex;
    justify-content: center;
    align-items: center;
    font-size: 1.15rem;
    font-weight: 700;
    text-transform: uppercase;
    color: var(--accent-orange);                   
    background-color: var(--bg-creme);     
    white-space: nowrap;
    pointer-events: none;
    opacity: var(--opacity, 0);
    clip-path: circle(28px at var(--x, 0px) var(--y, 0px));
    letter-spacing: 2px;
    transition: opacity 0.15s ease;
    z-index: 30;
}

.letter-box.is-vertical::after {
    writing-mode: vertical-rl;
    text-orientation: upright;
    white-space: normal;
    letter-spacing: -3px;
    line-height: 0.85;          
}

.scroll-hint {
    position: absolute;
    bottom: 40px;
    font-size: 0.7rem;
    text-transform: uppercase;
    letter-spacing: 2px;
    font-weight: 600;
    opacity: 0.3;
    animation: pulseScroll 2s infinite ease-in-out;
}

/* SECTION 2 : DOUBLE GRILLE ÉPURÉE (À PROPOS) */
.intro-content {
    max-width: 1300px;
    width: 100%;
    margin-top: 60px;
}

.intro-grid {
    display: grid;
    grid-template-columns: 1.1fr 0.9fr;
    gap: 100px;
    align-items: center;
}

.grid-left {
    display: flex;
    flex-direction: column;
}

.intro-tag {
    font-size: 0.75rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 2px;
    color: var(--accent-orange);
    margin-bottom: 20px;
    transform: translateY(30px);
    opacity: 0;
    transition: transform 0.8s cubic-bezier(0.25, 1, 0.5, 1), opacity 0.8s ease;
}

.intro-title {
    font-size: 3rem;
    font-weight: 700;
    line-height: 1.15;
    letter-spacing: -1px;
    color: var(--text-dark);
    transform: translateY(40px);
    opacity: 0;
    transition: transform 1s cubic-bezier(0.25, 1, 0.5, 1) 0.1s, opacity 1s ease 0.1s;
}

.intro-text {
    font-size: 1.15rem;
    line-height: 1.65;
    color: var(--text-dark);
    margin-top: 30px;
    opacity: 0;
    transform: translateY(40px);
    transition: transform 1s cubic-bezier(0.25, 1, 0.5, 1) 0.2s, opacity 1s ease 0.2s;
}

.cta-wrapper {
    margin-top: 40px;
    opacity: 0;
    transform: translateY(30px);
    transition: transform 1s cubic-bezier(0.25, 1, 0.5, 1) 0.3s, opacity 1s ease 0.3s;
}

.btn-discover {
    display: inline-flex;
    text-decoration: none;
    color: var(--text-dark);
    font-size: 0.8rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1px;
    border: 1px solid rgba(18, 18, 18, 0.15);
    padding: 16px 32px;
    border-radius: 30px;
    transition: background-color 0.3s, color 0.3s, border-color 0.3s, transform 0.3s;
}

.btn-discover:hover {
    background-color: var(--text-dark);
    color: var(--bg-creme);
    border-color: var(--text-dark);
    transform: translateY(-2px);
}

.grid-right {
    display: flex;
    justify-content: flex-end;
}

.skills-card {
    background: transparent;
    width: 100%;
    max-width: 480px;
    display: flex;
    flex-direction: column;
    gap: 24px;
}

.skills-card-title {
    font-size: 1.6rem;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: -0.5px;
    color: var(--text-dark);
    margin-bottom: 10px;
    opacity: 0;
    transform: translateY(20px);
    transition: transform 0.8s ease 0.1s, opacity 0.8s ease 0.1s;
}

.skill-item {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.skill-info {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.skill-name {
    font-size: 1rem;
    font-weight: 700;
    color: var(--text-dark);
}

.skill-percentage {
    font-size: 0.95rem;
    font-weight: 700;
    color: var(--text-dark);
    opacity: 0.8;
}

.skill-progress-bg {
    width: 100%;
    height: 4px;
    background-color: rgba(18, 18, 18, 0.08);
    border-radius: 2px;
    overflow: hidden;
}

.skill-progress-bar {
    height: 100%;
    width: 0%; 
    background-color: var(--accent-orange);
    border-radius: 2px;
    transition: width 1.5s cubic-bezier(0.25, 1, 0.5, 1);
}

.page-section.section-visible .intro-tag,
.page-section.section-visible .intro-title,
.page-section.section-visible .intro-text,
.page-section.section-visible .cta-wrapper,
.page-section.section-visible .skills-card-title {
    transform: translateY(0);
    opacity: 1;
}

.page-section.section-visible .skill-progress-bar {
    width: var(--target-width);
}

/* SECTION 3 : CARROUSEL 3D DES TRACES */
.trace-section {
    display: flex;
    flex-direction: column;
    justify-content: flex-start;
    padding-top: 70px; 
    height: auto;
}

.traces-container {
    width: 100%;
    max-width: 1300px;
    position: relative;
    display: flex;
    flex-direction: column;
}

.traces-header {
    text-align: left;
    margin-bottom: 5px; 
}

.traces-tag {
    font-size: 0.75rem;
    font-weight: 700;
    letter-spacing: 2px;
    color: var(--accent-orange);
    display: block;
    margin-bottom: 3px;
}

.traces-title {
    font-size: 3.8rem;
    font-weight: 900;
    line-height: 0.95;
    letter-spacing: -1.5px;
    color: var(--text-dark);
}

/* Structure de la Scène 3D */
.carousel-3d-wrapper {
    position: relative;
    width: 100%;
    height: 360px;
    margin-top: -10px;
    perspective: 1400px;
}

.carousel-track {
    position: relative;
    width: 100%;
    height: 100%;
    /* SUPPRIME transform-style: preserve-3d; */
}

/* Style d'une carte Trace */
.trace-card {
    position: absolute;
    width: 375px;
    background-color: #ffffff;
    border-radius: 16px;
    padding: 0;
    box-shadow: 0 12px 35px rgba(0, 0, 0, 0.05);
    overflow: hidden;
    top: 0;
    left: 50%;
    margin-left: -187.5px; 
    transition: transform 0.75s cubic-bezier(0.25, 1, 0.3, 1), opacity 0.75s ease, box-shadow 0.4s ease;
    will-change: transform, opacity;
}

.trace-img-holder {
    width: 100%;
    height: 190px;
    background-color: #e0ded9;
    overflow: hidden;
    position: relative;
}

.trace-image-src {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.trace-info-block {
    padding: 22px;
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.trace-badge {
    align-self: flex-start;
    font-size: 0.65rem;
    font-weight: 700;
    letter-spacing: 1px;
    padding: 3px 9px;
    border-radius: 12px;
}

.badge-programme { background-color: #bbf7d0; color: #166534; }
.badge-texte { background-color: #fef08a; color: #713f12; }

.trace-card-title {
    font-size: 0.92rem;
    font-weight: 800;
    line-height: 1.3;
    color: var(--text-dark);
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    height: 38px;
}

.trace-meta {
    font-size: 0.7rem;
    font-weight: 500;
    color: var(--text-dark);
    opacity: 0.4;
}

/* ÉTATS 3D DES CARTES */
.trace-card.position-center {
    transform: translateX(0) scale(1);
    opacity: 1;
    z-index: 50;
    pointer-events: auto;
    box-shadow: 0 20px 50px rgba(0,0,0,0.12);
}

.trace-card.position-left {
    transform: translateX(-360px) scale(0.86);
    opacity: 0.65;
    z-index: 35;
    cursor: pointer;
    pointer-events: auto;
}

.trace-card.position-right {
    transform: translateX(360px) scale(0.86);
    opacity: 0.65;
    z-index: 35;
    cursor: pointer;
    pointer-events: auto;
}

.trace-card.position-center:hover {
    transform: translateX(0) translateY(-12px) scale(1.02);
    box-shadow: 0 30px 65px rgba(0, 0, 0, 0.12);
}

/* BOUTON ALL TRACES */
.traces-footer {
    display: flex;
    justify-content: center; 
    margin-top: 15px; 
    margin-bottom: 80px; 
    width: 100%;
    z-index: 90;
    position: relative;
}

.btn-all-traces {
    display: inline-flex;
    text-decoration: none;
    color: #ffffff;
    background-color: var(--accent-orange);
    font-size: 0.8rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1px;
    padding: 16px 40px;
    border-radius: 30px;
    transition: transform 0.3s cubic-bezier(0.25, 1, 0.2, 1), background-color 0.3s;
}

.btn-all-traces:hover {
    transform: translateY(-2px);
    background-color: #f25c22;
}


/* KEYFRAMES ANIMATIONS */
@keyframes smoothFadeUp {
    from { opacity: 0; transform: translateY(40px); }
    to { opacity: 1; transform: translateY(0); }
}

@keyframes pulseScroll {
    0%, 100% { transform: translateY(0); opacity: 0.3; }
    50% { transform: translateY(6px); opacity: 0.6; }
}

