/* --- CHARTE GRAPHIQUE I AM SOFT SKILLS --- */
@import url('https://fonts.googleapis.com/css2?family=Poppins:wght@400;600;800&display=swap');

:root {
    --clair: #D3DFF0;
    --fonce: #5B7C99;
    --fond-parallax: #88B2BE;
    --shadow-btn: rgba(91, 124, 153, 0.4);
    --shadow-icon: rgba(0, 0, 0, 0.25);
}

* { box-sizing: border-box; }

html, body {
    margin: 0 !important;
    padding: 0 !important;
    width: 100% !important;
    height: 100% !important;
    overflow-x: hidden !important;
    overflow-y: hidden !important;
    font-family: 'Poppins', sans-serif;
    background-color: #FFFFFF !important;
    position: fixed;
}

h1, h2, h3, p, span, button {
    text-shadow: none !important;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

.text-legibility-halo {
    text-shadow:
        0 0 8px rgba(255, 255, 255, 0.9),
        0 0 4px rgba(255, 255, 255, 0.8) !important;
}

/* Boutons */
.btn-long {
    width: 85%; max-width: 350px; padding: 16px 20px;
    background-color: var(--fonce); border: 1px solid rgba(211, 223, 240, 0.5);
    color: var(--clair); border-radius: 16px; font-family: 'Poppins';
    font-weight: 600; font-size: 16px; cursor: pointer;
    box-shadow: 0px 10px 20px var(--shadow-btn); transition: transform 0.2s; outline: none;
}
.btn-long:active { transform: scale(0.96); }

.btn-modal {
    width: 100%; padding: 15px; border-radius: 16px;
    font-family: 'Poppins'; background-color: var(--fonce);
    border: 1px solid rgba(211, 223, 240, 0.5); color: var(--clair);
    font-weight: 600; font-size: 15px; cursor: pointer; outline: none;
}

/* Inputs */
.input-style {
    width: 100%; padding: 12px; border: 1px solid var(--clair);
    border-radius: 12px; font-family: 'Poppins'; outline: none;
    color: var(--fonce); box-sizing: border-box; font-size: 16px !important;
}

/* Sheets */
.up-sheet {
    position: absolute; bottom: 0; left: 0; width: 100%;
    background: #FFFFFF; z-index: 1950; border-top: 1px solid var(--fonce);
    border-top-left-radius: 25px; border-top-right-radius: 25px;
    display: none; flex-direction: column; align-items: center;
    transform: translateY(100%); transition: transform 0.4s ease-out;
    box-sizing: border-box; overflow: hidden;
}
.up-sheet.open { transform: translateY(0); }

.sheet-header-fixed {
    position: absolute; top: 0; left: 0; width: 100%;
    background: #FFFFFF; z-index: 10; padding: 20px 25px 15px 25px;
    box-sizing: border-box; text-align: center;
}

.central-modal {
    position: absolute; top: 50%; left: 50%; transform: translate(-50%, -50%);
    width: 90%; max-width: 380px; background: #FFFFFF; z-index: 1950;
    border: 1px solid var(--fonce); border-radius: 25px; padding: 30px 20px;
    display: none; flex-direction: column; align-items: center;
    box-sizing: border-box; text-align: center;
    box-shadow: 0px 20px 40px rgba(0,0,0,0.2);
}

/* Scroll */
.custom-scroll { scrollbar-width: none; -ms-overflow-style: none; }
.custom-scroll::-webkit-scrollbar { width: 0px; height: 0px; background: transparent; }

/* Images */
.image-fade {
    -webkit-mask-image: linear-gradient(to bottom, rgba(0,0,0,0) 0%, rgba(0,0,0,1) 25%, rgba(0,0,0,1) 85%, rgba(0,0,0,0) 100%);
    mask-image: linear-gradient(to bottom, rgba(0,0,0,0) 0%, rgba(0,0,0,1) 25%, rgba(0,0,0,1) 85%, rgba(0,0,0,0) 100%);
}

.bg-overlay {
    background: linear-gradient(rgba(255,255,255,0.4), rgba(255,255,255,0.6));
    position: absolute; inset: 0; pointer-events: none; z-index: 2;
}

/* Indicateurs de scroll */
.scroll-indicator-unit {
    width: 40px; height: 40px; display: flex; justify-content: center;
    align-items: center; animation: bounce 2s infinite; pointer-events: none; z-index: 100;
}
.scroll-arrow-icon { border: solid var(--fonce); border-width: 0 4px 4px 0; display: inline-block; padding: 6px; transform: rotate(45deg); opacity: 0.6; }

@keyframes bounce {
    0%, 20%, 50%, 80%, 100% { transform: translateY(0); }
    40% { transform: translateY(-10px); }
    60% { transform: translateY(-5px); }
}

/* Logo flottant */
.floating-logo { animation: floatAnim 3.5s ease-in-out infinite; }
@keyframes floatAnim {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-6px); }
}

/* Menu latéral */
#side-menu {
    position: fixed; top: 0; left: 0; width: 280px; height: 100%;
    background-color: var(--fonce); z-index: 3000; transform: translateX(-100%);
    transition: transform 0.3s ease-out; display: flex; flex-direction: column;
    padding: 40px 25px; box-sizing: border-box;
    box-shadow: none !important;
}
.open-side { transform: translateX(0) !important; }

.menu-header { display: flex; align-items: center; margin-bottom: 40px; }
.menu-logo { width: 50px; filter: drop-shadow(0px 4px 4px rgba(0,0,0,0.3)); margin-right: 15px; }
.menu-title { color: var(--clair); font-weight: 800; font-size: 1.2rem; }

.nav-links { display: flex; flex-direction: column; gap: 20px; }
.nav-item { color: var(--clair); text-decoration: none; font-size: 16px; font-weight: 600; cursor: pointer; }
.nav-sub-item { padding-left: 15px; font-size: 15px; font-weight: 400; opacity: 0.85; }

/* Hamburger */
.hamburger-icon { display: flex; flex-direction: column; justify-content: center; align-items: center; }

/* Langue */
.lang-text-link { font-size: 16px; font-weight: 600; color: var(--fonce); cursor: pointer; text-decoration: underline; }

/* Overlays */
#menu-overlay { position: fixed; inset: 0; background: rgba(0,0,0,0.4); z-index: 2950; display: none; }
#modal-overlay { position: fixed; inset: 0; background: rgba(0,0,0,0.4); z-index: 1900; display: none; }

/* Bibliothèques latérales */
.side-library {
    position: fixed; top: 0; left: 0; width: 280px; height: 100%;
    background-color: var(--fonce); z-index: 1500; transform: translateX(-100%);
    transition: transform 0.3s ease-out; display: flex; flex-direction: column;
    padding: 40px 25px; box-sizing: border-box;
    box-shadow: none !important;
}

/* ============================================================
   QUESTIONNAIRES DE PERSONNALITÉ
   ============================================================ */

.bg-img {
    position: fixed; top: 0; left: 0;
    width: 100%; height: 100%;
    background-size: cover; background-position: center;
    background-repeat: no-repeat; z-index: -1;
    transform: scale(1.15); transition: transform 0.1s ease-out;
}

#module-quiz {
    position: fixed; top: 0; left: 0;
    width: 100%; height: 100%; z-index: 3;
}

.scroll-quiz {
    width: 100%; height: 100%;
    overflow-y: scroll; overflow-x: hidden;
    scroll-snap-type: y mandatory;
    -webkit-overflow-scrolling: touch;
}

.step {
    width: 100%; height: 100vh;
    display: flex; flex-direction: column;
    justify-content: center; align-items: center;
    text-align: center; padding: 40px 25px;
    scroll-snap-align: start; scroll-snap-stop: always;
    box-sizing: border-box; position: relative;
}

.profile-photo-container {
    position: relative; width: 140px; height: 140px;
    margin: 0 auto 30px auto;
}

.profile-img {
    width: 100%; height: 100%; object-fit: cover;
    border-radius: 50%; border: 3px solid var(--fonce);
    box-shadow: 0px 8px 20px var(--shadow-btn);
}

.profile-edit-badge {
    position: absolute; bottom: 0; right: 0;
    width: 40px; height: 40px; cursor: pointer; z-index: 2;
}
.profile-edit-badge img { width: 100%; height: auto; display: block; }

.hidden { display: none !important; }

.q-title {
    font-family: 'Poppins', sans-serif; font-weight: 800; font-size: 22px;
    color: var(--fonce); margin: 0 0 20px 0; line-height: 1.3; text-align: center;
    text-shadow: 0 0 8px rgba(255,255,255,0.9), 0 0 4px rgba(255,255,255,0.8) !important;
}

.q-text {
    font-family: 'Poppins', sans-serif; font-weight: 600; font-size: 16px;
    color: var(--fonce); line-height: 1.5; margin: 0 0 30px 0;
    width: 100%; max-width: 320px; text-align: left;
    text-shadow: 0 0 8px rgba(255,255,255,0.9), 0 0 4px rgba(255,255,255,0.8) !important;
}

#intro .q-text, #step-final .q-text { text-align: center; }

.interpellation {
    font-family: 'Poppins', sans-serif; font-weight: 600; font-size: 15px;
    color: var(--fonce); line-height: 1.4; margin: 0 0 20px 0;
    text-shadow: 0 0 8px rgba(255,255,255,0.9), 0 0 4px rgba(255,255,255,0.8) !important;
}

.btn-round-group {
    display: flex; flex-direction: column; align-items: center;
    gap: 15px; margin: 0 auto;
}
.btn-round-row { display: flex; justify-content: center; gap: 30px; }

.btn-round {
    width: 60px; height: 60px; border-radius: 50%;
    background-color: var(--clair); border: 2px solid var(--fonce);
    color: var(--fonce); font-family: 'Poppins', sans-serif;
    font-weight: 800; font-size: 22px;
    display: flex; justify-content: center; align-items: center;
    cursor: pointer; box-shadow: 0px 6px 14px var(--shadow-btn);
    transition: transform 0.2s, background-color 0.2s, color 0.2s;
    user-select: none;
}
.btn-round:active { transform: scale(0.92); }
.btn-round.selected { background-color: var(--fonce); color: var(--clair); transform: scale(1.05); }

.scroll-arrow {
    font-size: 36px; color: var(--fonce); margin-top: 20px;
    animation: bounce 2s infinite;
    text-shadow: 0 0 6px rgba(255,255,255,0.9), 0 0 3px rgba(255,255,255,0.8) !important;
}

.nav-section-title {
    font-size: 11px; font-weight: 600; color: var(--clair);
    opacity: 0.6; margin-top: 10px; margin-bottom: 5px; letter-spacing: 0.5px;
}

/* ============================================================
   SAS — COMPTE À REBOURS PLEIN ÉCRAN
   ============================================================ */

#sas-screen {
    position: fixed; top: 0; left: 0;
    width: 100%; height: 100%; z-index: 5000;
    display: none; justify-content: center; align-items: center;
    transform: scale(0); opacity: 0;
    transition: transform 0.8s cubic-bezier(0.34, 1.2, 0.64, 1), opacity 0.6s ease;
}
#sas-screen.sas-open { transform: scale(1); opacity: 1; }

.sas-bg {
    position: absolute; top: 0; left: 0; width: 100%; height: 100%;
    background-image: url('/SHARED/IMAGES/fond-sas.png');
    background-size: cover; background-position: center;
    background-repeat: no-repeat; z-index: 0;
}

.sas-overlay {
    position: absolute; top: 0; left: 0; width: 100%; height: 100%;
    background: linear-gradient(rgba(255,255,255,0.4), rgba(255,255,255,0.6));
    z-index: 1; pointer-events: none;
}

.sas-content {
    position: relative; z-index: 2; text-align: center;
    width: 85%; max-width: 400px;
    display: flex; flex-direction: column; align-items: center;
}

#sas-intro {
    font-family: 'Poppins', sans-serif;
    font-size: 14px; font-weight: 800;
    color: var(--fonce); line-height: 1.6;
    text-align: center; margin-bottom: 30px;
    opacity: 1; padding: 0 10px;
    text-shadow: 0 0 8px rgba(255,255,255,0.9), 0 0 4px rgba(255,255,255,0.8) !important;
}

#sas-animation {
    width: 100px; height: 100px;
    display: flex; justify-content: center; align-items: center;
    margin: 0 auto 20px auto;
}

#status-msg {
    font-family: 'Poppins', sans-serif; font-size: 16px; font-weight: 600;
    color: var(--fonce); margin: 10px 0 25px 0;
    min-height: 48px; line-height: 1.4;
    text-shadow: 0 0 8px rgba(255,255,255,0.9), 0 0 4px rgba(255,255,255,0.8) !important;
}

.progress-container {
    width: 100%; height: 6px; background: var(--clair);
    border-radius: 3px; overflow: hidden; margin-bottom: 20px;
}
.progress-bar {
    width: 0%; height: 100%; background: var(--fonce);
    border-radius: 3px; transition: width 1s linear;
}

/* ============================================================
   SAS — ANIMATIONS DES 4 PHASES
   ============================================================ */

/* PHASE 1 — Engrenage CSS */
.sas-gear {
    width: 60px; height: 60px; position: relative;
    display: flex; justify-content: center; align-items: center;
    animation: gearSpin 5s linear infinite;
}
.sas-gear::before {
    content: '⚙'; font-size: 60px; color: var(--fonce); opacity: 0.8;
    text-shadow: 0 0 10px rgba(255,255,255,0.9) !important;
}
@keyframes gearSpin {
    from { transform: rotate(0deg); }
    to { transform: rotate(360deg); }
}

/* PHASE 2 — Flèches pointant l'une vers l'autre */
.sas-arrows {
    position: relative; width: 80px; height: 40px;
    display: flex; justify-content: space-between; align-items: center;
}
.sas-arrow-1, .sas-arrow-2 {
    width: 0; height: 0; opacity: 0.85;
}
/* Flèche gauche → pointant vers la droite */
.sas-arrow-1 {
    border-top: 14px solid transparent;
    border-bottom: 14px solid transparent;
    border-left: 22px solid var(--fonce);
    animation: arrowLeft 1.8s ease-in-out infinite;
}
/* Flèche droite → pointant vers la gauche */
.sas-arrow-2 {
    border-top: 14px solid transparent;
    border-bottom: 14px solid transparent;
    border-right: 22px solid var(--fonce);
    animation: arrowRight 1.8s ease-in-out infinite;
}

@keyframes arrowLeft {
    0%, 100% { transform: translateX(0); opacity: 0.85; }
    50% { transform: translateX(10px); opacity: 0.3; }
}
@keyframes arrowRight {
    0%, 100% { transform: translateX(0); opacity: 0.85; }
    50% { transform: translateX(-10px); opacity: 0.3; }
}

/* PHASE 3 — Countdown */
.sas-countdown {
    font-family: 'Poppins', sans-serif; font-size: 72px; font-weight: 800;
    color: var(--fonce); line-height: 1;
    text-shadow: 0 0 12px rgba(255,255,255,0.9), 0 0 6px rgba(255,255,255,0.8) !important;
    transition: transform 0.3s ease-out;
}

/* PHASE 4 — Points animés */
.sas-dots {
    display: flex; gap: 10px; align-items: center; justify-content: center;
}
.sas-dot {
    width: 12px; height: 12px; border-radius: 50%;
    background: var(--fonce); opacity: 0.2;
    animation: dotPulse 1.4s ease-in-out infinite;
}
.sas-dot:nth-child(1) { animation-delay: 0s; }
.sas-dot:nth-child(2) { animation-delay: 0.2s; }
.sas-dot:nth-child(3) { animation-delay: 0.4s; }
.sas-dot:nth-child(4) { animation-delay: 0.6s; }
.sas-dot:nth-child(5) { animation-delay: 0.8s; }

@keyframes dotPulse {
    0%, 100% { opacity: 0.2; transform: scale(0.8); }
    50% { opacity: 1; transform: scale(1.3); }
}
