/**
 * Project Section (Timeline)
 * Styles for the "Your Project" section with interactive timeline
 * showing the work process steps
 */

/*--------------------------------------------------
 # Initial Flash Prevention
--------------------------------------------------*/
/* These styles initially hide animation elements to prevent a flash
   before JavaScript takes over */
.timeline-node {
    opacity: 0;
    transform: translateY(20px);
}

/* Completely hide the progress bar and background bar */
.timeline-bar {
    opacity: 0;
}

.timeline-bar .timeline-progress {
    width: 0;
    transition: none;
}

.step-detail.active h3,
.step-detail.active p,
.step-detail.active .step-detail-cta {
    opacity: 0;
    transform: translateY(10px);
}

/*--------------------------------------------------
 # Scroll Animations for Timeline
--------------------------------------------------*/
@keyframes fadeSlideUp {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Timeline-specific variables */
:root {
    --timeline-purple: #7b1fa2;
    --timeline-grey: #e0e0e0;
    --timeline-node-size: 48px;
    --timeline-bar-height: 10px;
}

/* Structure de base de la section */
.process-timeline-section {
    margin-top: 50px;
    padding: 80px 0;
    position: relative;
    overflow: hidden;
    background: #ffffff;
}

/* Decorative square on the left */
.process-timeline-section::before {
    content: '';
    position: absolute;
    left: -266px;
    top: 186px;
    width: 320px;
    height: 320px;
    border: 2px solid rgba(123, 31, 162, 0.08);
    background: linear-gradient(135deg, rgba(123, 31, 162, 0.09), rgba(64, 76, 186, 0.05));
    border-radius: 32px;
    transform: rotate(28deg);
    pointer-events: none;
    opacity: 0.75;
    z-index: 0;
    box-shadow: 0 15px 35px rgba(123, 31, 162, 0.08);
}

/* Decorative square on the right */
.process-timeline-section::after {
    content: '';
    position: absolute;
    right: -120px;
    bottom: 180px;
    width: 280px;
    height: 280px;
    border: 2px solid rgba(64, 76, 186, 0.09);
    background: linear-gradient(135deg, rgba(64, 76, 186, 0.08), rgba(123, 31, 162, 0.04));
    border-radius: 32px;
    transform: rotate(-8deg);
    pointer-events: none;
    opacity: 0.75;
    z-index: 0;
    box-shadow: 0 15px 35px rgba(64, 76, 186, 0.07);
}

/* Container de la timeline */
.timeline-container {
    width: 100%;
    position: relative;
    margin: 60px 0 40px 0;
    padding-bottom: 60px;
}

.timeline-wrapper {
    max-width: 800px;
    margin: 0 auto;
    position: relative;
    min-height: 100px;
}

/* Barre de progression de base */
.timeline-bar {
    position: absolute;
    left: 0;
    right: 0;
    top: 20px;
    height: var(--timeline-bar-height);
    background-color: var(--timeline-grey);
    z-index: 5;
    border-radius: calc(var(--timeline-bar-height) / 2);
    overflow: hidden;
}

/* Barre de progression violette */
.timeline-progress {
    position: absolute;
    left: 0;
    top: 0;
    height: 100%;
    width: 0%; /* Mis u00e0 jour par JS */
    background-color: var(--timeline-purple);
    transition: width 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
    z-index: 6;
    border-radius: calc(var(--timeline-bar-height) / 2);
}

/* Motif sur la barre de progression */
.timeline-bar::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: repeating-linear-gradient(
        90deg,
        transparent,
        transparent 5px,
        rgba(255, 255, 255, 0.1) 5px,
        rgba(255, 255, 255, 0.1) 10px
    );
    border-radius: var(--timeline-border-radius);
    z-index: 0;
    opacity: 0.5;
}

/* Container pour les points de la timeline */
.timeline-nodes {
    display: flex;
    justify-content: space-between;
    position: relative;
    width: 100%;
    z-index: 10;
}

/* Point individuel de la timeline */
.timeline-node {
    display: flex;
    flex-direction: column;
    align-items: center;
    position: relative;
    width: calc(100% / 6);
}

/* Cercle entourant le chiffre */
.timeline-circle {
    width: var(--timeline-node-size);
    height: var(--timeline-node-size);
    background-color: white;
    border: 2px solid #d0d0d0;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 10px;
    cursor: pointer;
    position: relative;
    z-index: 10;
    transition: all 0.3s ease;
    outline: none !important; /* Supprimer le contour de focus lors du clic */
    -webkit-tap-highlight-color: transparent !important; /* Supprimer highlight sur mobile */
    user-select: none !important; /* Empêcher la sélection de texte */
    -webkit-user-select: none !important;
    -moz-user-select: none !important;
    -ms-user-select: none !important;
    caret-color: transparent !important; /* Masquer le curseur de texte */
}

/* Règles spécifiques pour supprimer le contour dans tous les états */
.timeline-circle:focus,
.timeline-circle:active,
.timeline-circle:focus-visible,
.timeline-circle:focus-within {
    outline: none !important;
    box-shadow: none !important; /* Sauf si déjà défini ailleurs pour le style */
    border-style: solid !important; /* Maintenir le style de la bordure */
}

/* Numu00e9ro u00e0 l'intu00e9rieur du cercle */
.timeline-node span {
    position: relative;
    z-index: 11;
    color: #555;
    font-weight: 600;
    font-size: 1.1rem;
    pointer-events: none;
    user-select: none;
    -webkit-user-select: none;
    -moz-user-select: none;
    -ms-user-select: none;
}

/* Effet au survol du cercle */
.timeline-circle:hover {
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
}

/* Animation lors du clic sur un cercle */
.timeline-circle.pulse-click {
    animation: pulse-click 0.7s cubic-bezier(0.15, 0.85, 0.35, 1.25);
}

@keyframes pulse-click {
    0% { transform: scale(0.95); box-shadow: 0 0 0 0 rgba(123, 31, 162, 0.7); }
    70% { transform: scale(1); box-shadow: 0 0 0 10px rgba(123, 31, 162, 0); }
    100% { transform: scale(1); box-shadow: 0 0 0 0 rgba(123, 31, 162, 0); }
}

/* Styles pour le point actif */
/* Timeline node active state */
.timeline-node.active .timeline-circle {
    transform: scale(1.08);
    transform-origin: center center;
    border-color: var(--timeline-purple);
    border-width: 2px;
    box-shadow: 0 0 0 4px rgba(123, 31, 162, 0.2), 0 0 10px rgba(123, 31, 162, 0.3);
    animation: node-pulse 1.5s infinite alternate;
    background-color: rgba(123, 31, 162, 0.05); /* Fond légèrement teinté */
}

@keyframes node-pulse {
    0% { box-shadow: 0 0 0 4px rgba(123, 31, 162, 0.2), 0 0 10px rgba(123, 31, 162, 0.3); }
    100% { box-shadow: 0 0 0 6px rgba(123, 31, 162, 0.3), 0 0 15px rgba(123, 31, 162, 0.4); }
}

/* Ensure number maintains same size and position despite circle scaling */
.timeline-node.active span {
    color: var(--timeline-purple);
    font-weight: 600;
    transform: scale(0.926);
    transform-origin: center center;
    backface-visibility: hidden;
}

/* Styles pour les points complétés */
.timeline-node.completed .timeline-circle {
    border-color: var(--timeline-purple);
    background-color: var(--timeline-purple);
    box-shadow: 0 0 0 3px rgba(123, 31, 162, 0.1), 0 3px 5px rgba(0, 0, 0, 0.1);
}

.timeline-node.completed span {
    color: white; /* Texte blanc sur fond violet pour meilleur contraste */
    font-weight: 600;
    transform: none;
}

/* Styles des états actifs et complétés - version globale (non-responsive) */

/* Label de l'u00e9tape sous le cercle */
.timeline-step-label {
    text-align: center;
    font-size: 0.9rem;
    font-weight: 700;
    color: #555;
    width: 100%;
    margin-top: 5px;
    margin-bottom: 4px;
}

/* Description sous le label */
.timeline-step-description {
    font-size: 0.68rem;
    color: #767676;
    text-align: center;
    max-width: 120px;
    margin: 0 auto;
    line-height: 1.3;
    opacity: 0.8;
    transition: all 0.3s ease;
}

/* Styles pour le label et la description du point actif */
.timeline-node.active .timeline-step-label {
    color: var(--timeline-purple);
    font-weight: 600;
}

.timeline-node.active .timeline-step-description {
    color: #555;
    opacity: 1;
}

/* Boites de du00e9tails pour chaque u00e9tape */
.step-details-container {
    margin-top: 80px;
    position: relative;
    height: 300px;
    background: transparent;
}

.step-detail {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    background: #fff;
    border-radius: 15px;
    padding: 30px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.08);
    display: none; /* Masquer complètement par défaut */
    opacity: 0;
    transform: translateY(20px);
    transition: opacity 0.5s cubic-bezier(0.215, 0.61, 0.355, 1), transform 0.5s cubic-bezier(0.215, 0.61, 0.355, 1);
    pointer-events: none;
    height: 100%;
    overflow: hidden;
    z-index: 1;
}

/* Bou00eete de du00e9tails active */
.step-detail.active {
    display: flex; /* Afficher en flex quand actif */
    opacity: 1;
    transform: translateY(0);
    pointer-events: all;
}

/* Cotu00e9 gauche de la bou00eete de du00e9tails (texte) */
.step-detail-left {
    flex: 1;
    padding-right: 30px;
}

/* Titre dans la bou00eete de du00e9tails */
.step-detail-left h3 {
    font-size: 1.5rem;
    margin-bottom: 20px;
    color: #7b1fa2;
    position: relative;
    padding-bottom: 15px;
    text-align: center;
}

/* Barre sous le titre */
.step-detail-left h3::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 50px;
    height: 3px;
    background: currentColor;
    border-radius: 3px;
}

/* Paragraphes dans la bou00eete de du00e9tails */
.step-detail-left p {
    font-size: 1rem;
    line-height: 1.6;
    color: #555;
    margin-bottom: 20px;
}

/* Cotu00e9 droit de la bou00eete de du00e9tails (image) */
.step-detail-right {
    flex: 0 0 40%;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    overflow: hidden;
    border-radius: 10px;
}

.step-detail-right .step-illustration {
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    background: rgba(0, 0, 0, 0.03);
    border-radius: 10px;
}

/* Illustrations SVG */
.step-illustration svg {
    width: 80%;
    height: 80%;
    opacity: 0.8;
}

/* Bouton CTA dans la bou00eete de du00e9tails */
.step-detail-cta {
    margin-top: 30px;
    text-align: center;
}

.step-detail-cta .btn {
    display: inline-block;
    padding: 10px 20px;
    background-color: var(--timeline-purple);
    color: white;
    border-radius: 5px;
    font-weight: 500;
    text-decoration: none;
    transition: all 0.3s ease;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
}

.step-detail-cta .btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 8px rgba(0, 0, 0, 0.15);
}

/* Tous les styles responsifs ont été déplacés vers responsive.css */

/* Styles de base transférés vers responsive.css */
