/* style.css */
:root {
    --bg-dark: #091E42;
    --yellow: #D4ED31;
    --yellow-hover: #b8cf26;
    --white: #ffffff;
    --text-dark: #1f2937;
    --gray-light: #f3f4f6;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Poppins', sans-serif;
}

body {
    background-color: var(--gray-light);
    color: var(--text-dark);
    overflow-x: hidden;
}

.text-yellow { color: var(--yellow); }
.container { max-width: 1200px; margin: 0 auto; padding: 0 5%; }

/* --- ANIMATIONS --- */
@keyframes float {
    0% { transform: translateY(0px); }
    50% { transform: translateY(-15px); }
    100% { transform: translateY(0px); }
}

@keyframes pulse {
    0% { box-shadow: 0 0 0 0 rgba(212, 237, 49, 0.7); }
    70% { box-shadow: 0 0 0 15px rgba(212, 237, 49, 0); }
    100% { box-shadow: 0 0 0 0 rgba(212, 237, 49, 0); }
}

/* Classes de Révélation au Scroll */
.reveal {
    opacity: 0;
    transition: all 0.8s cubic-bezier(0.5, 0, 0, 1);
}
.reveal.active { opacity: 1; transform: translate(0, 0); }
.fade-up { transform: translateY(50px); }
.slide-right { transform: translateX(-50px); }
.slide-left { transform: translateX(50px); }

/* --- HEADER --- */
.navbar {
    position: fixed;
    top: 0; width: 100%;
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    z-index: 1000;
    padding: 15px 0;
    box-shadow: 0 4px 30px rgba(0, 0, 0, 0.05);
}

.nav-container {
    display: flex; justify-content: space-between; align-items: center;
}

.logo { display: flex; flex-direction: column; line-height: 1.1; }
.logo-ymy { font-weight: 900; font-size: 1.5rem; color: var(--bg-dark); }
.logo-yomiye { font-size: 0.9rem; font-weight: 600; color: #555; }

.btn-outline {
    border: 2px solid var(--bg-dark);
    color: var(--bg-dark);
    padding: 8px 24px;
    border-radius: 30px;
    text-decoration: none;
    font-weight: 700;
    transition: all 0.3s ease;
}
.btn-outline:hover { background: var(--bg-dark); color: var(--yellow); }

/* --- HERO SECTION --- */
.hero {
    position: relative;
    min-height: 100vh;
    display: flex;
    align-items: center;
    /* Image mise à jour : Enfants africains à l'école */
    background: url('https://images.unsplash.com/photo-1524069290683-0457abfe42c3?ixlib=rb-4.0.3&auto=format&fit=crop&w=1920&q=80') center/cover no-repeat;
    padding-top: 80px;
}

.hero-overlay {
    position: absolute;
    top: 0; left: 0; width: 100%; height: 100%;
    background: linear-gradient(135deg, rgba(9, 30, 66, 0.95) 0%, rgba(9, 30, 66, 0.75) 100%);
}

.hero-grid {
    position: relative;
    z-index: 10;
    display: grid;
    grid-template-columns: 1.2fr 1fr;
    gap: 50px;
    align-items: center;
    width: 100%;
}

/* Texte Hero */
.hero-text { color: var(--white); }
.badge {
    display: inline-block;
    background: rgba(255,255,255,0.1);
    backdrop-filter: blur(5px);
    padding: 8px 16px;
    border-radius: 20px;
    font-size: 0.9rem;
    font-weight: 600;
    margin-bottom: 20px;
    border: 1px solid rgba(255,255,255,0.2);
}
.hero-text h1 { font-size: 4rem; line-height: 1.1; font-weight: 900; margin-bottom: 10px; }
.hero-text h2 { font-size: 2rem; font-weight: 400; margin-bottom: 20px; }
.hero-text p { font-size: 1.1rem; opacity: 0.9; margin-bottom: 30px; max-width: 500px; }

.hero-stats { display: flex; gap: 30px; }
.stat-item { display: flex; align-items: center; gap: 10px; font-weight: 600; font-size: 1.1rem; }
.stat-item i { color: var(--yellow); font-size: 1.5rem; }

/* Formulaire Glassmorphism */
.glass-form {
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(15px);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 24px;
    padding: 40px;
    box-shadow: 0 20px 40px rgba(0,0,0,0.2);
    color: var(--white);
}

.glass-form h3 { text-align: center; font-size: 1.8rem; margin-bottom: 25px; }

/* Barre de progression */
.funding-status { margin-bottom: 30px; }
.progress-info { display: flex; justify-content: space-between; font-size: 0.9rem; margin-bottom: 8px; font-weight: 600; }
.progress-bar-bg { background: rgba(255,255,255,0.2); height: 12px; border-radius: 10px; overflow: hidden; }
.progress-bar-fill {
    height: 100%;
    width: 0%;
    background: var(--yellow);
    border-radius: 10px;
    transition: width 1.5s cubic-bezier(0.25, 1, 0.5, 1);
    box-shadow: 0 0 10px var(--yellow);
}

/* Grille des montants */
.form-label { display: block; margin-bottom: 10px; font-size: 0.9rem; font-weight: 600; opacity: 0.9; }
.amount-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 10px; margin-bottom: 25px; }
.amount-option {
    background: rgba(255,255,255,0.1);
    border: 1px solid rgba(255,255,255,0.3);
    padding: 12px;
    text-align: center;
    border-radius: 12px;
    cursor: pointer;
    font-weight: 600;
    transition: all 0.3s;
}
.amount-option:hover { background: rgba(255,255,255,0.2); }
.amount-option.active { background: var(--yellow); color: var(--bg-dark); border-color: var(--yellow); }
.amount-option.custom { padding: 0; background: rgba(0,0,0,0.2); border: 1px dashed rgba(255,255,255,0.4); }
.amount-option.custom input {
    width: 100%; height: 100%;
    background: transparent; border: none;
    color: white; text-align: center; font-weight: 600; font-family: 'Poppins', sans-serif;
}
.amount-option.custom input::placeholder { color: rgba(255,255,255,0.6); }
.amount-option.custom input:focus { outline: none; }

/* Inputs */
.input-group { position: relative; margin-bottom: 20px; }
.input-group i { position: absolute; left: 15px; top: 50%; transform: translateY(-50%); color: rgba(255,255,255,0.6); }
.input-group input {
    width: 100%; padding: 15px 15px 15px 45px;
    background: rgba(255,255,255,0.1);
    border: 1px solid rgba(255,255,255,0.2);
    border-radius: 12px;
    color: white; font-size: 1rem; font-family: 'Poppins', sans-serif;
    transition: border-color 0.3s, background 0.3s;
}
.input-group input::placeholder { color: rgba(255,255,255,0.6); }
.input-group input:focus { outline: none; border-color: var(--yellow); background: rgba(255,255,255,0.2); }

/* Bouton Submit */
.btn-submit {
    width: 100%; padding: 16px;
    background: var(--yellow); color: var(--bg-dark);
    border: none; border-radius: 12px;
    font-size: 1.1rem; font-weight: 800; text-transform: uppercase;
    cursor: pointer;
    display: flex; justify-content: center; align-items: center; gap: 10px;
    transition: transform 0.3s;
    margin-top: 10px;
}
.btn-submit:hover { transform: translateY(-3px); }
.pulse-effect { animation: pulse 2s infinite; }
.secure-text { text-align: center; font-size: 0.8rem; margin-top: 15px; opacity: 0.7; }

/* --- SECTION MISSION --- */
.mission { padding: 80px 0; background: var(--white); }
.section-header { text-align: center; margin-bottom: 50px; }
.section-header h2 { font-size: 2.5rem; color: var(--bg-dark); font-weight: 800; }
.separator { height: 4px; width: 60px; background: var(--yellow); margin: 15px auto 0; border-radius: 2px; }

.mission-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); gap: 40px; }
.mission-card {
    background: var(--gray-light);
    padding: 40px 25px;
    border-radius: 24px;
    text-align: center;
    transition: transform 0.4s, box-shadow 0.4s;
    border: 1px solid transparent;
}
.mission-card:hover { transform: translateY(-10px); box-shadow: 0 20px 40px rgba(9, 30, 66, 0.08); background: var(--white); border-color: rgba(9, 30, 66, 0.05); }
.icon-wrapper {
    width: 70px; height: 70px;
    background: var(--bg-dark); color: var(--yellow);
    border-radius: 50%;
    display: flex; justify-content: center; align-items: center;
    font-size: 2rem; margin: 0 auto 20px;
    box-shadow: 0 10px 20px rgba(9, 30, 66, 0.2);
}
.floating { animation: float 4s ease-in-out infinite; }
.mission-card h3 { color: var(--bg-dark); font-size: 1.3rem; margin-bottom: 15px; }
.mission-card p { color: #555; line-height: 1.6; font-size: 0.95rem; }

/* --- FOOTER --- */
footer { background: var(--bg-dark); color: var(--white); padding: 50px 0 30px; }
.footer-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(250px, 1fr)); gap: 40px; }
.footer-brand h2 { color: var(--white); margin-bottom: 10px; font-size: 1.5rem; }
.footer-contact h3 { margin-bottom: 15px; color: var(--yellow); font-size: 1.2rem; }
.footer-contact p { margin-bottom: 10px; display: flex; align-items: center; gap: 10px; opacity: 0.8; font-size: 0.9rem; }
.footer-motto { font-size: 1.1rem; font-style: italic; font-weight: 600; display: flex; align-items: center; }

/* ========================================= */
/*       OPTIMISATIONS RESPONSIVE (MOBILE)   */
/* ========================================= */

@media (max-width: 1024px) {
    .hero-text h1 { font-size: 3rem; }
    .hero-text h2 { font-size: 1.6rem; }
}

@media (max-width: 992px) {
    .hero-grid { grid-template-columns: 1fr; text-align: center; gap: 30px; }
    .hero { padding-top: 110px; padding-bottom: 50px; height: auto; }
    .hero-text p { margin: 0 auto 30px; }
    .hero-stats { justify-content: center; }
}

@media (max-width: 768px) {
    .hero-text h1 { font-size: 2.2rem; }
    .hero-text h2 { font-size: 1.3rem; }
    .hero-text p { font-size: 0.95rem; }
    .badge { font-size: 0.8rem; padding: 6px 12px; }
    
    .nav-container { padding: 0 10px; }
    .logo-ymy { font-size: 1.2rem; }
    .logo-yomiye { font-size: 0.75rem; }
    .btn-outline { padding: 6px 16px; font-size: 0.9rem; }
    
    .section-header h2 { font-size: 1.8rem; }
}

@media (max-width: 480px) {
    .hero { padding-top: 90px; }
    .glass-form { padding: 25px 15px; border-radius: 16px; }
    .glass-form h3 { font-size: 1.4rem; margin-bottom: 20px; }
    
    /* Maintient les montants sur 2 colonnes sur mobile pour plus d'ergonomie */
    .amount-grid { gap: 8px; margin-bottom: 20px; }
    .amount-option { padding: 10px; font-size: 0.9rem; }
    
    .input-group input { padding: 12px 12px 12px 40px; font-size: 0.9rem; }
    
    .btn-submit { font-size: 1rem; padding: 14px; }
    
    /* Empile les stats sur mobile */
    .hero-stats { flex-direction: column; gap: 10px; align-items: center; }
    .stat-item { font-size: 1rem; }
    
    .mission { padding: 60px 0; }
    .mission-card { padding: 30px 20px; }
    
    .footer-brand h2 { font-size: 1.3rem; }
    .footer-motto { font-size: 1rem; text-align: center; }
}




/* ========================================= */
/*       MODAL & LISTE DES DONATEURS         */
/* ========================================= */

/* Bouton sous la barre de progression */
.btn-donors-modal {
    background: rgba(255, 255, 255, 0.15);
    border: 1px solid rgba(255, 255, 255, 0.3);
    color: var(--white);
    padding: 8px 15px;
    border-radius: 20px;
    font-size: 0.85rem;
    font-weight: 600;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    margin-top: 15px;
    transition: all 0.3s ease;
}

.btn-donors-modal:hover {
    background: rgba(255, 255, 255, 0.25);
    transform: translateY(-2px);
}

.btn-donors-modal i { color: var(--yellow); }

/* Overlay (Fond flouté de la modale) */
.modal-overlay {
    position: fixed;
    top: 0; left: 0; width: 100%; height: 100%;
    background: rgba(9, 30, 66, 0.6);
    backdrop-filter: blur(8px);
    z-index: 2000;
    display: flex;
    justify-content: center;
    align-items: center;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.3s ease, visibility 0.3s ease;
}

.modal-overlay.active {
    opacity: 1;
    visibility: visible;
}

/* Conteneur principal de la modale */
.modal-container {
    background: var(--gray-light);
    width: 90%;
    max-width: 500px;
    border-radius: 24px;
    box-shadow: 0 25px 50px rgba(0, 0, 0, 0.3);
    transform: translateY(30px) scale(0.95);
    transition: transform 0.4s cubic-bezier(0.25, 1, 0.5, 1);
    display: flex;
    flex-direction: column;
    max-height: 85vh; /* Pour scroller si la liste est longue */
    overflow: hidden;
}

.modal-overlay.active .modal-container {
    transform: translateY(0) scale(1);
}

/* En-tête de la modale */
.modal-header {
    background: var(--bg-dark);
    padding: 20px 25px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.modal-header h3 {
    color: var(--white);
    font-size: 1.2rem;
    display: flex;
    align-items: center;
    gap: 10px;
}

.modal-close {
    background: rgba(255, 255, 255, 0.1);
    border: none;
    color: var(--white);
    width: 35px;
    height: 35px;
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    justify-content: center;
    align-items: center;
    transition: background 0.3s;
}

.modal-close:hover { background: rgba(255, 255, 255, 0.2); }

/* Corps de la modale */
.modal-body {
    padding: 25px;
    overflow-y: auto; /* Scroll actif */
}

.modal-desc {
    font-size: 0.9rem;
    color: #555;
    text-align: center;
    margin-bottom: 20px;
}

/* Liste et Cartes (Cards) des donateurs */
.donors-list {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.donor-card {
    background: var(--white);
    border-radius: 16px;
    padding: 15px;
    display: flex;
    align-items: center;
    gap: 15px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.03);
    transition: transform 0.2s, box-shadow 0.2s;
    border: 1px solid rgba(0, 0, 0, 0.02);
}

.donor-card:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.06);
}

.donor-avatar {
    width: 45px; height: 45px;
    background: #E8F0FE;
    color: var(--bg-dark);
    border-radius: 50%;
    display: flex; justify-content: center; align-items: center;
    font-size: 1.2rem;
}

.donor-avatar.anon {
    background: #f3f4f6;
    color: #9ca3af;
}

.donor-info {
    flex: 1; /* Prend tout l'espace central */
}

.donor-info h4 {
    color: var(--text-dark);
    font-size: 1rem;
    margin-bottom: 3px;
}

.donor-time {
    font-size: 0.75rem;
    color: #888;
}

.donor-amount {
    background: rgba(212, 237, 49, 0.2);
    color: var(--bg-dark);
    font-weight: 800;
    padding: 6px 12px;
    border-radius: 10px;
    font-size: 0.95rem;
    border: 1px solid rgba(212, 237, 49, 0.5);
}

/* Pied de la modale */
.modal-footer {
    padding: 15px;
    text-align: center;
    background: var(--white);
    border-top: 1px solid #eee;
    font-size: 0.8rem;
    color: #888;
    font-weight: 600;
}

/* Ajustement pour les petits écrans */
@media (max-width: 480px) {
    .modal-container { width: 95%; max-height: 90vh; }
    .modal-header h3 { font-size: 1.1rem; }
    .donor-card { padding: 12px; gap: 10px; }
    .donor-info h4 { font-size: 0.9rem; }
    .donor-amount { font-size: 0.85rem; padding: 5px 10px; }
}