/* --- CSS COMPLET (style.css) --- */

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html, body {
    width: 100%;
    height: 100%;
    margin: 0;
    padding: 0;
    overflow-x: hidden;
}

#preloader {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: #f1f1f1;
    z-index: 9999;
    display: flex;
    justify-content: center;
    align-items: center;
    opacity: 1;
    transition: opacity 0.3s ease-out;
}

#preloader.hidden {
    opacity: 0;
    pointer-events: none;
}

.loader {
    border: 4px solid #f3f3f3;
    border-top: 4px solid #3498db;
    border-radius: 50%;
    width: 40px;
    height: 40px;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

#main {
    position: relative;
    overflow: hidden;
    background-color: #f1f1f1;
}

#page {
    height: 100vh;
    width: 100vw;
    position: relative;
}

canvas {
    position: relative;
    z-index: 9;
    max-width: 100vw;
    max-height: 100vh;
}

.overlay-text {
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    z-index: 10;
    opacity: 0;
    pointer-events: none; /* Le conteneur principal n'intercepte pas les clics */
    transition: opacity 0.01s;
    width: 100%;
    text-align: center;
}

.overlay-text.visible {
    opacity: 1;
}

.kokorner-text {
    font-family: Raleway, sans-serif;
    font-weight: 700;
    font-size: 120px;
    color: white;
    text-shadow: 2px 2px 8px rgba(0, 0, 0, 0.7);
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    transition: opacity 0.2s ease-in-out;
    width: 100%;
}

.production-text, .agence-text {
    font-family: Raleway, sans-serif;
    font-weight: 700;
    font-size: 120px;
    color: white;
    text-shadow: 2px 2px 8px rgba(0, 0, 0, 0.7);
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -110%);
    transition: opacity 0.2s ease-in-out;
    width: 100%;
    opacity: 0;
}

.lorem-text, .lorem-text-agence {
    font-family: Raleway, sans-serif;
    font-weight: 400;
    font-size: 24px;
    color: white;
    text-shadow: 1px 1px 4px rgba(0, 0, 0, 0.7);
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -15%);
    max-width: 800px;
    line-height: 1.4;
    text-align: center;
    opacity: 0;
    transition: opacity 0.2s ease-in-out;
}


.button-container {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, 220px); 
    z-index: 11;
    opacity: 0;
    display: flex;
    gap: 20px;
    transition: opacity 0.2s ease-in-out;
    pointer-events: auto; /* La valeur par défaut pour les conteneurs */
}

.button-container.is-disabled {
    pointer-events: none !important;
}


.btn {
    display: inline-block;
    padding: 12px 24px;
    background-color: transparent;
    color: white;
    font-family: Raleway, sans-serif;
    font-weight: 600;
    font-size: 16px;
    text-decoration: none;
    border-radius: 50px;
    border: 1px solid white;
    transition: color 0.3s, border-color 0.3s;
}

.btn:hover {
    color: #e0e0e0;
    border-color: #e0e0e0;
}