/* --- VARIABLES ET BASES --- */
:root { 
    --gold: #E1AD01; 
    --dark: #3E2723; 
    --white: #FFFFFF; 
    --cream: #FFF9E1; 
}

body { 
    font-family: 'Poppins', sans-serif; 
    margin: 0; 
    background: #fdfdfd; 
    color: var(--dark); 
    overflow-x: hidden; 
}

/* --- ARRIÈRE-PLAN ANIMÉ --- */
.slideshow-bg { position: fixed; top: 0; left: 0; width: 100%; height: 100%; z-index: -1; }
.slide { position: absolute; width: 100%; height: 100%; opacity: 0; animation: fadeBg 12s infinite; }
.slide:nth-child(1) { animation-delay: 0s; } 
.slide:nth-child(2) { animation-delay: 4s; } 
.slide:nth-child(3) { animation-delay: 8s; }
@keyframes fadeBg { 0%, 100% {opacity:0} 10%, 33% {opacity:1} }

header { background: var(--gold); padding: 15px; text-align: center; color: white; font-weight: bold; font-size: 1.5rem; text-transform: uppercase; letter-spacing: 2px; }
.container { max-width: 480px; margin: auto; padding: 15px; }
.step { display: none; }
.step.active { display: block; animation: fadeIn 0.4s ease; }

/* --- CARTES ET FORMULAIRES --- */
.auth-card, .hero-card { 
    background: white; padding: 25px; border-radius: 20px; 
    box-shadow: 0 10px 30px rgba(0,0,0,0.08); margin-bottom: 20px; 
}
input, select, textarea { 
    width: 100%; padding: 12px; margin: 10px 0; border: 1.5px solid #eee; 
    border-radius: 12px; box-sizing: border-box; font-family: 'Poppins', sans-serif; 
    text-transform: uppercase; font-size: 0.85rem;
}
textarea { resize: none; height: 100px; text-transform: none; } /* On laisse le texte libre dans le textarea */

/* --- TÉMOIGNAGES --- */
.testimonials-container { 
    background: var(--cream); padding: 15px; border-radius: 15px; 
    margin: 20px 0 10px 0; min-height: 85px; display: flex; 
    align-items: center; justify-content: center; border: 1px dashed var(--gold); 
}
.testimonial-slide { display: none; text-align: center; font-size: 0.85rem; font-style: italic; }
.testimonial-slide.active { display: block; }

/* --- SYSTÈME CAMÉRA --- */
.camera-wrapper { position: relative; height: 320px; background: #000; border-radius: 25px; overflow: hidden; border: 4px solid var(--gold); }
#video { width: 100%; height: 100%; object-fit: cover; }

.camera-wrapper::after {
    content: ""; position: absolute; top: 0; left: 0; width: 100%; height: 3px;
    background: rgba(255, 255, 255, 0.6); box-shadow: 0 0 15px 2px var(--gold);
    animation: laserScan 3s linear infinite; z-index: 10;
}
@keyframes laserScan { 0% { top: 0; } 50% { top: 100%; } 100% { top: 0; } }

.camera-overlay { 
    position: absolute; top: 50%; left: 50%; transform: translate(-50%,-50%); 
    width: 220px; height: 220px; border: 2px dashed rgba(255,255,255,0.5); 
    border-radius: 50%; box-shadow: 0 0 0 1000px rgba(0,0,0,0.4); z-index: 5;
}

.previews { display: grid; grid-template-columns: repeat(5, 1fr); gap: 8px; margin-top: 15px; }
.previews div { 
    height: 65px; background: #eee; border-radius: 10px; 
    background-size: cover; border: 1.5px solid var(--gold); 
    background-position: center; transition: 0.3s;
}

/* --- CHARGEMENT IA --- */
.loader-content { text-align: center; padding: 40px 20px; }
.spinner { 
    width: 50px; height: 50px; border: 5px solid var(--cream); 
    border-top: 5px solid var(--gold); border-radius: 50%; 
    margin: 0 auto 20px; animation: spin 1s linear infinite; 
}
@keyframes spin { 0% { transform: rotate(0deg); } 100% { transform: rotate(360deg); } }

/* --- BILAN ET JAUGE DE VITALITÉ --- */
#pdf-area { border: 1px solid #eee; box-shadow: 0 5px 15px rgba(0,0,0,0.05); }
.score-circle-container { text-align: center; padding: 10px 0; }
.big-score { font-size: 5.5rem; font-weight: 900; color: var(--gold); line-height: 1; margin: 0; text-shadow: 2px 2px 0px var(--cream); }
.score-label { font-size: 0.8rem; text-transform: uppercase; letter-spacing: 2px; font-weight: 600; opacity: 0.7; }

/* Styles de la Jauge */
.gauge-bg { width: 100%; height: 14px; background: #eee; border-radius: 20px; overflow: hidden; margin-top: 8px; }
#vitality-gauge-fill { height: 100%; width: 0%; border-radius: 20px; transition: width 2s cubic-bezier(0.1, 0.7, 1.0, 0.1), background-color 0.5s; }
.gauge-labels { display: flex; justify-content: space-between; font-size: 9px; color: #888; margin-top: 5px; font-weight: bold; }

.stats-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin: 20px 0; }
.s-box { background: var(--cream); border: 1.5px solid var(--gold); padding: 12px; border-radius: 12px; text-align: center; font-size: 0.75rem; font-weight: 700; text-transform: uppercase; }
.gold-title { color: var(--gold); margin-bottom: 8px; font-size: 0.9rem; text-transform: uppercase; font-weight: bold; border-bottom: 1px solid #eee; padding-bottom: 5px; }
.section-bilan { margin-bottom: 20px; }
.week-box { background: #fafafa; border-left: 4px solid var(--gold); padding: 12px; border-radius: 8px; font-size: 0.85rem; margin-bottom: 10px; text-transform: uppercase; }

/* --- BOUTONS --- */
.btn-main, .btn-wa, .btn-pdf, .btn-secondary, .btn-capture { 
    border: none; padding: 16px; border-radius: 14px; width: 100%; 
    font-weight: bold; cursor: pointer; transition: 0.3s; font-family: 'Poppins', sans-serif;
    text-transform: uppercase; letter-spacing: 1px;
}
.btn-main { background: var(--gold); color: white; margin-top: 10px; box-shadow: 0 4px 15px rgba(225, 173, 1, 0.3); }
.btn-secondary { background: #555; color: white; padding: 12px; }
.btn-capture { background: var(--dark); color: white; }
.btn-wa { background: #25D366 !important; color: white; margin-top: 15px; }
.btn-pdf { background: #333; color: white; margin-bottom: 10px; }

.btn-main:active { transform: scale(0.97); }

/* --- ANIMATIONS --- */
@keyframes fadeIn { from { opacity: 0; transform: translateY(15px); } to { opacity: 1; transform: translateY(0); } }

.success-message { 
    background: #e8f5e9; color: #2e7d32; padding: 10px; 
    border-radius: 10px; text-align: center; font-weight: bold; 
    font-size: 0.8rem; margin-bottom: 15px; text-transform: uppercase;
}