﻿/* ============================================================
   VILLAGE BUNDLE CSS — common + header + footer (minifié en 1 fichier)
   Généré automatiquement — ne pas éditer séparément
   ============================================================ */

/* =============================================================
   VILLAGE-COMMON.CSS — Variables, Reset, Typographie
   Base partagée par TOUTES les pages de The Village
   ✅ Ne modifie AUCUN visuel — ne fait que centraliser
   Alif Genesis Ltd — 2026
   ============================================================= */

/* --- 1. VARIABLES GLOBALES (Palette du Village) --- */
:root {
    /* Couleurs principales */
    --sable-fond: #F7EBD5;          /* Fond sable chaud (Thème B) */
    --marron-texte: #5D4037;         /* Texte principal marron terre */
    --blanc-pur: #FFFFFF;
    --blanc-lumineux: #F5F5F5;
    --bleu-nuit: #0B1C3F;           /* Bleu nuit profond */
    --bleu-profond: #050e24;         /* Dégradé footer */
    --or-solaire: #D4A649;           /* Or signature Alif Genesis */
    --sable-ancien: #E4CDA2;         /* Or clair / sable ancien */
    --indigo: #1A2F5D;

    /* Couleurs des Quartiers */
    --c-educatif: #417BF5;           /* Bleu éducatif */
    --c-medico: #27AE60;             /* Vert médico-social */
    --c-culture: #E67E22;            /* Ocre culture */
    --c-bienetre: #00897B;           /* Turquoise bien-être */
    --c-media: #6A1B9A;              /* Violet médiatique */
    --c-souk: #D4A649;               /* Or du Souk */
    --c-preceptorat: #00C853;        /* Vert préceptorat */
    --c-hijra: #0B3B24;              /* Vert hijra */

    /* Couleurs des Maisons (sous-quartier éducatif) */
    --c-savoir: #2962FF;             /* Bleu Maison Scolarité */
    --c-inter: #C62828;              /* Rouge Maison Internationale */
    --c-vacances: #EF6C00;           /* Orange Maison Vacances */
    --c-formation: #7B1FA2;          /* Violet Institut Formation */
    --c-excellence: #000000;         /* Noir Maison Excellence */

    /* Thème par défaut (Quartier Éducatif) — surchargé par chaque page */
    --theme-main: #134EC1;
    --theme-dark: #0D3380;
    --theme-light-bg: #E6EEFA;
    --theme-glow: 0 0 20px rgba(19, 78, 193, 0.4);

    /* Gradients des Maisons éducatives */
    --grad-ief: linear-gradient(110deg, #002366 20%, #D4A649 85%);
    --grad-mini: linear-gradient(110deg, #00c6ff 20%, #0072ff 85%);
    --grad-precep: linear-gradient(110deg, #009473 20%, #b2d732 85%);
    --grad-cambridge: linear-gradient(110deg, #012169 30%, #C8102E 80%);
    --grad-excell: linear-gradient(110deg, #000000 30%, #b3ecff 90%);
    --grad-formation: linear-gradient(110deg, #8E2DE2 10%, #4A00E0 90%);
}


/* --- 2. RESET & BASE --- */
* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

img {
    max-width: 100%;
    height: auto;
    display: block;
}


/* --- 3. TYPOGRAPHIE --- */

/* Corps de texte : Merriweather (serif) */
/* ⚠️ background-color et color ne sont PAS définis ici
   car ils varient selon les pages. Chaque page les définit
   dans son propre <style> */
body {
    margin: 0;
    padding: 0;
    font-family: 'Merriweather', serif;
    overflow-x: hidden;
    display: flex;
    flex-direction: column;
    min-height: 100vh;
}

/* Wrappers d'injection layout.js
   (garantit que le footer reste collé en bas) */
#inject-footer {
    margin-top: auto;
}

/* Titres & éléments UI : Fredoka (sans-serif) */
h1, h2, h3, h4, h5 {
    font-family: 'Fredoka', sans-serif;
}

/* Paragraphes et texte courant : Merriweather */
p {
    font-family: 'Merriweather', serif;
}


/* --- 4. UTILITAIRES COMMUNS --- */

/* Animation du texte défilant (bandeau d'annonce) */
@keyframes defilement {
    0% { transform: translate(0, 0); }
    100% { transform: translate(-100%, 0); }
}

/* Classe de verrouillage des tailles d'images (anti-explosion) */
.verrou-icon { width: 24px !important; height: 24px !important; object-fit: contain !important; }
.verrou-logo { height: 110px !important; width: auto !important; }
.verrou-footer-logo { height: 80px !important; width: auto !important; }


/* --- 5. ANIMATIONS AU SCROLL (IntersectionObserver) --- */
/* Utilisé avec village-perf.js — Ajouter .reveal sur les éléments */

.reveal {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 0.6s ease-out, transform 0.6s ease-out;
}
.reveal.revealed {
    opacity: 1;
    transform: translateY(0);
}

.reveal-left {
    opacity: 0;
    transform: translateX(-40px);
    transition: opacity 0.6s ease-out, transform 0.6s ease-out;
}
.reveal-left.revealed {
    opacity: 1;
    transform: translateX(0);
}

.reveal-right {
    opacity: 0;
    transform: translateX(40px);
    transition: opacity 0.6s ease-out, transform 0.6s ease-out;
}
.reveal-right.revealed {
    opacity: 1;
    transform: translateX(0);
}

.reveal-scale {
    opacity: 0;
    transform: scale(0.9);
    transition: opacity 0.6s ease-out, transform 0.6s ease-out;
}
.reveal-scale.revealed {
    opacity: 1;
    transform: scale(1);
}

/* Délais d'animation en cascade (pour les grilles de cartes) */
.reveal-delay-1 { transition-delay: 0.1s; }
.reveal-delay-2 { transition-delay: 0.2s; }
.reveal-delay-3 { transition-delay: 0.3s; }
.reveal-delay-4 { transition-delay: 0.4s; }


/* ── HEADER ───────────────────────────── */
/* =============================================================
   VILLAGE-HEADER.CSS — Header, Navigation, Bandeau d'annonce
   Styles pour la top-bar + nav desktop (pill-bar) + nav mobile (burger)
   Compatible avec les 3 thèmes (surcharge via --theme-main)
   Alif Genesis Ltd — 2026
   ============================================================= */


/* --- 1. BANDEAU D'ANNONCE (Top Bar) --- */
.top-bar {
    background-color: var(--bleu-nuit);
    color: var(--blanc-lumineux);
    height: 30px;
    padding: 0 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 0.8rem;
    z-index: 102;
    position: relative;
    overflow: hidden;
    font-family: 'Fredoka', sans-serif;
}

/* Conteneur du texte défilant */
.news-container {
    width: 60%;
    overflow: hidden;
    white-space: nowrap;
}

/* Texte défilant (ticker) */
.news-ticker {
    display: inline-block;
    font-style: italic;
    padding-left: 100%;
    animation: defilement 15s linear infinite;
    line-height: 30px;
    color: var(--blanc-lumineux);
}

/* Lien doré dans le ticker */
.news-ticker a,
.ticker-link {
    color: var(--or-solaire);
    text-decoration: none;
    font-weight: bold;
    border-bottom: 1px solid var(--or-solaire);
}

/* Icônes réseaux sociaux (header) */
.social-icons {
    display: flex;
    gap: 15px;
    align-items: center;
    flex-shrink: 0;
}

.social-icons img {
    height: 26px;
    transition: transform 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

.social-icons img:hover {
    transform: scale(1.3);
}


/* --- 2. NAVIGATION DESKTOP (Pill-Bar) --- */
nav {
    position: absolute;
    top: 40px;
    width: 100%;
    padding: 0 10px;
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    z-index: 100;
}

/* Logo */
.logo img {
    height: 130px;
    width: auto;
    aspect-ratio: 1 / 1;
    object-fit: contain;
    margin-top: 5px;
    background: radial-gradient(closest-side, rgba(255,255,255,0.8) 0%, rgba(255,255,255,0.0) 100%);
    border-radius: 50%;
    padding: 10px;
    margin-left: -10px;
    transition: transform 0.3s ease;
}

.logo img:hover {
    transform: scale(1.15);
}

/* Barre de navigation principale (pill-bar glassmorphism) */
.menu-links {
    position: absolute;
    left: 50%;
    transform: translateX(-50%);
    top: 25px;
    display: flex;
    background: rgba(255, 255, 255, 0.4);
    padding: 5px;
    border-radius: 50px;
    border: 1px solid rgba(255,255,255,0.5);
    backdrop-filter: blur(10px);
    flex-wrap: wrap;
    justify-content: center;
    gap: 2px;
    width: max-content;
    max-width: 95%;
    box-shadow: 0 5px 15px rgba(93, 64, 55, 0.05);
}

/* Liens de navigation */
.menu-links a {
    text-decoration: none;
    color: var(--marron-texte);
    font-family: 'Fredoka', sans-serif;
    font-weight: 600;
    font-size: 0.85rem;
    padding: 8px 12px;
    border-radius: 30px;
    transition: 0.3s;
    white-space: nowrap;
    position: relative;
}

/* Lien actif et hover — utilise la couleur du thème courant */
.menu-links a:hover,
.menu-links a.active {
    background: var(--theme-main);
    color: white;
    transform: translateY(-2px);
    box-shadow: var(--theme-glow);
}

/* Sous-titre "(Alif Genesis Online School)" sous le lien Quartier Éducatif */
.menu-links a span.subtitle {
    position: absolute;
    bottom: 0px;
    left: 50%;
    transform: translateX(-50%);
    font-size: 0.5rem;
    font-weight: bold;
    color: var(--or-solaire);
    white-space: nowrap;
    pointer-events: none;
    line-height: 1;
}

/* Bouton Connexion (Desktop) */
.connexion-wrapper {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-decoration: none;
    transition: 0.3s;
    margin-top: 10px;
    cursor: pointer;
}

.connexion-icon img {
    width: 75px;
    height: 75px;
    border-radius: 50%;
    border: 3px solid rgba(255,255,255,0.6);
    margin-bottom: 5px;
    transition: transform 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

.connexion-text {
    font-family: 'Fredoka', sans-serif;
    font-weight: 600;
    color: var(--marron-texte);
    transition: 0.3s;
    margin-top: 5px;
}

.connexion-wrapper:hover .connexion-icon img {
    transform: scale(1.15);
    border-color: var(--theme-main);
}

.connexion-wrapper:hover .connexion-text {
    color: var(--theme-main);
}


/* --- 3. ÉLÉMENTS MASQUÉS EN DESKTOP --- */
.burger-centered {
    display: none;
}

.mobile-connexion-right {
    display: none;
}

.close-menu-btn {
    display: none;
}


/* --- 4. RESPONSIVE MOBILE (max-width: 900px) --- */
@media (max-width: 900px) {

    /* Réorganisation de la nav */
    nav {
        display: flex;
        flex-direction: row;
        justify-content: space-between;
        align-items: center;
        position: absolute;
        top: 35px;
        width: 100%;
        padding: 0 20px;
        z-index: 200;
        background-color: var(--sable-fond) !important;
    }

    /* Logo réduit sur mobile */
    .logo img {
        height: 120px;
        width: auto;
        aspect-ratio: 1 / 1;
        object-fit: contain;
        margin: 0;
        padding: 0;
        background: none;
    }

    /* Masquer la pill-bar et le bouton connexion desktop */
    .menu-links,
    .connexion-wrapper {
        display: none;
    }

    /* Afficher le bouton burger (centré) */
    .burger-centered {
        display: flex;
        position: absolute;
        left: 50%;
        transform: translateX(-50%);
        font-size: 2rem;
        color: var(--bleu-nuit);
        cursor: pointer;
        background: rgba(255,255,255,0.5);
        padding: 5px 10px;
        border-radius: 10px;
    }

    /* Afficher le bouton connexion mobile (à droite) */
    .mobile-connexion-right {
        display: flex;
        flex-direction: column;
        align-items: center;
        text-decoration: none;
        gap: 2px;
    }

    .mobile-connexion-right img {
        width: 55px;
        height: 55px;
        border-radius: 50%;
        border: 2px solid white;
        box-shadow: 0 2px 5px rgba(0,0,0,0.1);
    }

    .mobile-connexion-right span {
        font-size: 0.85rem;
        font-weight: bold;
        color: var(--marron-texte);
        font-family: 'Fredoka', sans-serif;
    }

    /* Menu mobile (panneau latéral droit) — caché par défaut */
    .menu-links {
        transform: translateX(100%);
        transition: transform 0.3s ease;
    }

    /* Menu mobile ouvert */
    .menu-links.mobile-active {
        display: flex;
        flex-direction: column;
        position: fixed;
        top: 0;
        right: 0;
        width: 80%;
        height: 100vh;
        background: white;
        padding-top: 80px;
        box-shadow: -5px 0 20px rgba(0,0,0,0.1);
        z-index: 300;
        transform: translateX(0);
    }

    /* Liens dans le menu mobile */
    .menu-links a {
        font-size: 1.1rem;
        padding: 15px 20px;
        width: 100%;
        text-align: left;
        border-bottom: 1px solid #eee;
        border-radius: 0;
    }

    /* Subtitle en mobile : en dessous du lien, pas en absolute */
    .menu-links a span.subtitle {
        position: static;
        transform: none;
        margin-top: 2px;
        margin-left: 0;
        font-size: 0.75rem;
    }

    /* Bouton fermer le menu mobile */
    .close-menu-btn {
        display: block;
        position: absolute;
        top: 20px;
        right: 20px;
        font-size: 2rem;
        color: var(--marron-texte);
        cursor: pointer;
    }
}


/* ── FOOTER ───────────────────────────── */
/* =============================================================
   VILLAGE-FOOTER.CSS — Footer Standard 4 colonnes
   Partagé par toutes les pages qui ont le footer complet
   Alif Genesis Ltd — 2026
   ============================================================= */


/* --- 1. CONTENEUR FOOTER --- */
footer {
    /* FIX : background-color de fallback explicite au cas où la variable CSS n'est pas chargée */
    background-color: #0B1C3F;
    background: linear-gradient(to bottom, #0B1C3F, #050e24);
    background: linear-gradient(to bottom, var(--bleu-nuit, #0B1C3F), #050e24);
    color: #ffffff;
    padding: 60px 20px 20px;
    border-top: 4px solid #D4A649;
    border-top: 4px solid var(--or-solaire, #D4A649);
    position: relative;
    z-index: 2000;
    /* FIX : éviter le flash white avant rendu CSS */
    min-height: 250px;
}

/* Grille 4 colonnes responsive */
.footer-content {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 30px;
    max-width: 1200px;
    margin: 0 auto 30px auto;
}


/* --- 2. TITRES DES COLONNES --- */
.footer-col h4 {
    color: var(--or-solaire);
    font-family: 'Fredoka', sans-serif;
    font-size: 1.1rem;
    margin-bottom: 15px;
    position: relative;
    display: inline-block;
    text-transform: uppercase;
}

/* Barre dorée sous les titres — utilise la couleur thème de la page */
.footer-col h4::after {
    content: '';
    position: absolute;
    left: 0;
    bottom: -5px;
    width: 30px;
    height: 3px;
    background-color: var(--theme-main, var(--or-solaire));
    border-radius: 2px;
}


/* --- 3. COLONNE MARQUE (Logo + tagline + réseaux) --- */
.footer-brand {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
}

.footer-brand p {
    opacity: 0.8;
    font-size: 0.9rem;
    font-family: 'Merriweather', serif;
    line-height: 1.6;
    font-style: italic;
}

.footer-logo-mini {
    height: 90px;
    width: auto;
    object-fit: contain;
    margin-bottom: 10px;
    transition: transform 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    cursor: pointer;
}

.footer-logo-mini:hover {
    transform: scale(1.1);
}

/* Icônes réseaux sociaux du footer (version images) */
.footer-social-icons {
    margin-top: 20px;
    display: flex;
    gap: 15px;
    justify-content: center;
    align-items: center;
}

.footer-social-icons a {
    display: inline-block;
}

.footer-social-icons img {
    height: 32px;
    width: auto;
    transition: transform 0.3s ease;
}

.footer-social-icons img:hover {
    transform: scale(1.3);
}

/* Icônes réseaux sociaux du footer (version Font Awesome — layout.js) */
.footer-social-icons a.fa-icon-link {
    width: 35px;
    height: 35px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(255,255,255,0.1);
    border-radius: 50%;
    color: var(--blanc-lumineux, #F5F5F5);
    transition: 0.3s;
    font-size: 1.1rem;
}

.footer-social-icons a.fa-icon-link:hover {
    background: var(--or-solaire);
    color: var(--bleu-nuit);
    transform: translateY(-3px);
}


/* --- 4. COLONNES LIENS --- */
.footer-links ul {
    list-style: none;
    padding: 0;
}

.footer-links li {
    margin-bottom: 8px;
    font-family: 'Merriweather', serif;
}

.footer-links a {
    color: var(--blanc-lumineux, #F5F5F5);
    text-decoration: none;
    font-size: 0.85rem;
    opacity: 0.8;
    transition: all 0.3s ease;
    display: inline-block;
}

.footer-links a:hover {
    color: var(--theme-main, var(--or-solaire));
    transform: translateX(5px);
    opacity: 1;
}


/* --- 5. COLONNE NEWSLETTER --- */
.footer-newsletter p,
.newsletter-col p {
    font-size: 0.9rem;
    margin-bottom: 15px;
    opacity: 0.8;
    font-family: 'Merriweather', serif;
}

.newsletter-form {
    margin-top: 15px;
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.newsletter-input {
    padding: 10px;
    border-radius: 20px;
    border: none;
    font-family: 'Fredoka', sans-serif;
    font-size: 0.9rem;
}

.newsletter-btn {
    padding: 10px;
    border-radius: 20px;
    border: 2px solid var(--or-solaire);
    background-color: var(--or-solaire);
    color: var(--bleu-nuit);
    font-weight: bold;
    cursor: pointer;
    transition: 0.3s;
    font-family: 'Fredoka', sans-serif;
}

.newsletter-btn:hover {
    background-color: transparent;
    color: var(--or-solaire);
}


/* --- 6. BARRE INFÉRIEURE (copyright) --- */
.footer-bottom {
    text-align: center;
    border-top: 1px solid rgba(255,255,255,0.1);
    padding-top: 15px;
    font-size: 0.7rem;
    opacity: 0.6;
    font-family: 'Merriweather', serif;
}


/* --- 7. RESPONSIVE MOBILE --- */
@media (max-width: 900px) {
    footer {
        padding: 40px 15px 15px;
    }

    .footer-content {
        grid-template-columns: 1fr;
        gap: 25px;
        text-align: center;
    }

    .footer-links ul {
        text-align: center;
    }

    .footer-social-icons img {
        height: 28px;
    }

    .newsletter-form {
        max-width: 300px;
        margin: 15px auto 0 auto;
    }
}

