/* ==========================================================================
   CONFIGURATIONS GÉNÉRALES & VARIABLES
   ========================================================================== */
:root {
    /* Palette 2026 : Nuances de Bleus */
    --primary: #1a365d;        /* Bleu Nuit : Autorité et sécurité */
    --primary-light: #2c5282;  /* Bleu Médium : Interactions */
    --accent: #5a9bd5;         /* Bleu Ciel Doux : Boutons et accents */
    --bg-surface: #f4f7fa;     /* Bleu Brume : Fonds de section */
    
    /* Couleurs de texte */
    --text-main: #2d3748;      /* Gris foncé pour la lecture */
    --text-muted: #718096;     /* Gris bleu pour infos secondaires */
    --white: #ffffff;
    
    /* Système */
    --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    --shadow-soft: 0 4px 20px rgba(26, 54, 93, 0.05);
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'Inter', sans-serif;
    line-height: 1.6;
    color: var(--text-main);
    background-color: var(--white);
    -webkit-font-smoothing: antialiased;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 25px;
}

/* ==========================================================================
   HEADER & NAVIGATION
   ========================================================================== */
.main-header {
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    border-bottom: 1px solid rgba(26, 54, 93, 0.1);
    position: sticky;
    top: 0;
    z-index: 1000;
    padding: 1rem 0;
}

nav {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo a {
    font-weight: 600;
    font-size: 1.8rem;
    text-decoration: none;
    color: var(--primary);
    letter-spacing: 1px;
}

.nav-menu {
    display: flex;
    list-style: none;
    align-items: center;
}

.nav-menu > li {
    margin-left: 2rem;
    position: relative;
}

.nav-menu a {
    text-decoration: none;
    color: var(--primary);
    font-size: 0.95rem;
    font-weight: 500;
    transition: var(--transition);
}

.nav-menu a:hover {
    color: var(--accent);
}

/* Dropdown Menu */
.submenu {
    position: absolute;
    top: 100%;
    left: 0;
    background: var(--white);
    box-shadow: 0 10px 30px rgba(26, 54, 93, 0.1);
    padding: 1rem 0;
    min-width: 240px;
    display: none;
    border-radius: 8px;
    border: 1px solid rgba(26, 54, 93, 0.05);
    z-index: 100;
    /* --- ICI LA CORRECTION --- */
    list-style: none; 
}

/* On s'assure aussi que les éléments de liste n'ont pas de marge parasite */
.submenu li {
    margin: 0;
    padding: 0;
}

.dropdown:hover .submenu {
    display: block;
    animation: fadeIn 0.2s ease-out;
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(5px); }
    to { opacity: 1; transform: translateY(0); }
}

.submenu a {
    padding: 0.7rem 1.5rem;
    display: block;
    font-size: 0.9rem;
    color: var(--text-main);
}

.submenu a:hover {
    background-color: var(--bg-surface);
}

.btn-contact {
    background: var(--primary);
    color: var(--white) !important;
    padding: 0.7rem 1.8rem;
    border-radius: 50px;
    font-weight: 600 !important;
}

/* Pont de sécurité pour éviter que le menu ne se ferme au survol */
.dropdown::after {
    content: "";
    position: absolute;
    top: 100%;
    left: 0;
    width: 100%;
    height: 20px; /* Largeur du pont invisible */
    display: block;
}

/* ==========================================================================
   SECTION HERO (Accueil)
   ========================================================================== */
.hero {
    position: relative;
    height: 85vh;
    min-height: 600px;
    display: flex;
    align-items: center;
    color: var(--white);
    background-image: url('https://chesnaie.com/images/banniere_chesnaie.png');
    background-size: cover;
    background-position: center;
    overflow: hidden;
}

.hero-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, rgba(26, 54, 93, 0.9) 0%, rgba(26, 54, 93, 0.6) 50%, rgba(26, 54, 93, 0.3) 100%);
    z-index: 1;
}

.hero-content {
    position: relative;
    z-index: 2;
    max-width: 850px;
}

.hero-subtitle {
    display: block;
    text-transform: uppercase;
    letter-spacing: 2px;
    font-size: 0.85rem;
    font-weight: 600;
    margin-bottom: 1.5rem;
    color: var(--accent);
}

.hero h1 {
    font-size: clamp(2.5rem, 5vw, 3.8rem);
    line-height: 1.1;
    margin-bottom: 1.8rem;
    font-weight: 600;
}

.hero p {
    font-size: 1.25rem;
    margin-bottom: 3rem;
    opacity: 0.9;
}

.hero-actions {
    display: flex;
    gap: 1.5rem;
}

.btn-primary {
    background-color: var(--accent);
    color: var(--white);
    padding: 1.1rem 2.5rem;
    border-radius: 50px;
    text-decoration: none;
    font-weight: 600;
    transition: var(--transition);
}

.btn-outline {
    color: var(--white);
    border: 1px solid rgba(255, 255, 255, 0.4);
    padding: 1.1rem 2.5rem;
    border-radius: 50px;
    text-decoration: none;
    backdrop-filter: blur(5px);
    transition: var(--transition);
}

.btn-primary:hover, .btn-outline:hover {
    transform: translateY(-3px);
    background: var(--white);
    color: var(--primary);
}

/* Animation combinant un battement (scale) et une lueur (box-shadow) */
@keyframes heart-glow-pulse {
  0% {
    transform: scale(1);
    /* La lueur de base est visible */
    box-shadow: 0 0 10px 3px rgba(var(--accent-rgb, 37, 99, 235), 0.5);
  }
  14% {
    /* Légère augmentation de taille (début du battement) */
    transform: scale(1.05);
    /* La lueur s'intensifie et s'élargit légèrement */
    box-shadow: 0 0 15px 5px rgba(var(--accent-rgb, 37, 99, 235), 0.7);
  }
  28% {
    /* Retour à la taille normale */
    transform: scale(1);
    /* La lueur reste présente mais diminue un peu */
    box-shadow: 0 0 10px 3px rgba(var(--accent-rgb, 37, 99, 235), 0.5);
  }
  42% {
    /* Deuxième micro-battement pour l'effet "boum-boum" */
    transform: scale(1.03);
    box-shadow: 0 0 12px 4px rgba(var(--accent-rgb, 37, 99, 235), 0.6);
  }
  100% {
    /* Fin du cycle, retour à l'état initial */
    transform: scale(1);
    box-shadow: 0 0 10px 3px rgba(var(--accent-rgb, 37, 99, 235), 0.5);
  }
}

.btn-animated-primary {
  /* Vos styles de base (j'ai ajouté un fond pour que le glow se voit mieux sur l'image) */
  background-color: var(--accent, #2563eb);
  border: 1px solid rgba(255, 255, 255, 0.4);
  color: var(--white, #ffffff);
  padding: 1.1rem 2.5rem;
  border-radius: 50px;
  text-decoration: none;
  font-weight: 600;
  display: inline-block;
  
  /* Transition douce pour le survol */
  transition: background-color 0.3s ease, transform 0.2s ease, box-shadow 0.3s ease;
  
  /* Application de la nouvelle animation combinée (cycle de 2 secondes) */
  animation: heart-glow-pulse 2s infinite;
}

.btn-animated-primary:hover {
  background: var(--white);
  color: var(--primary);
  transform: translateY(-2px);
  /* On met une ombre plus classique et nette au survol */
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
  animation: none;
}

/* ==========================================================================
   CONTENU DES PAGES INTERNES
   ========================================================================== */
.page-intro {
    padding: 80px 0 40px;
    text-align: center;
}

.page-intro h1 {
    font-size: 3rem;
    color: var(--primary);
    margin-bottom: 20px;
}

.lead {
    font-size: 1.25rem;
    color: var(--text-muted);
    max-width: 800px;
    margin: 0 auto;
}

.content-section {
    padding: 60px 0 100px;
}

.text-block {
    max-width: 800px;
    margin-bottom: 50px;
}

.text-block h2 {
    font-size: 2rem;
    color: var(--primary);
    margin-bottom: 1.5rem;
}

.info-box {
    background: var(--primary);
    color: var(--white);
    padding: 40px;
    border-radius: 20px;
    margin: 40px 0;
}

/* Grilles Modernes (Concepts & UDF) */
.concept-grid, .udf-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 30px;
    margin: 40px 0;
}

.concept-card, .udf-item {
    background: var(--bg-surface);
    padding: 35px;
    border-radius: 15px;
    border: 1px solid rgba(26, 54, 93, 0.05);
    transition: var(--transition);
}

.concept-card:hover, .udf-item:hover {
    transform: translateY(-5px);
    background: var(--white);
    box-shadow: var(--shadow-soft);
}

.concept-card h3, .udf-item h4 {
    color: var(--primary);
    margin-bottom: 15px;
    font-size: 1.25rem;
}

/* ==========================================================================
   FOOTER
   ========================================================================== */
.main-footer {
    background-color: var(--primary);
    padding: 80px 0 0 0;
    color: var(--white);
}

.footer-grid {
    display: grid;
    grid-template-columns: 1.5fr 1fr 1.2fr;
    gap: 40px;
    padding-bottom: 60px;
}

.footer-brand h3 {
    font-size: 1.5rem;
    margin-bottom: 1.5rem;
    color: var(--white);
}

.footer-brand p {
    font-size: 0.9rem;
    opacity: 0.8;
}

.footer-links h4, .footer-contact h4 {
    font-size: 1.1rem;
    margin-bottom: 1.5rem;
    color: var(--accent);
}

.footer-links ul {
    list-style: none;
}

.footer-links ul li {
    margin-bottom: 0.8rem;
}

.footer-links ul li a {
    color: rgba(255, 255, 255, 0.8);
    text-decoration: none;
    font-size: 0.9rem;
}

.footer-phone {
    font-weight: 600;
    font-size: 1.1rem;
    margin-top: 10px;
}

.footer-email {
    color: var(--accent);
    text-decoration: none;
}

.footer-bottom {
    background-color: rgba(0, 0, 0, 0.2);
    padding: 25px 0;
    text-align: center;
    font-size: 0.85rem;
    opacity: 0.6;
}

/* ==========================================================================
   RESPONSIVITÉ (MOBILE)
   ========================================================================== */
@media (max-width: 768px) {
    .nav-menu {
        display: none; /* Menu burger nécessaire pour une version mobile avancée */
    }

    .hero {
        text-align: center;
        height: auto;
        padding: 120px 0 80px;
    }

    .hero-actions {
        flex-direction: column;
    }

    .page-intro h1 {
        font-size: 2.2rem;
    }

    .footer-grid {
        grid-template-columns: 1fr;
        text-align: center;
    }
}

/* ==========================================================================
   CSS POUR LES PAGES INTERNES (Habillement)
   ========================================================================== */

/* 1. Bannière de tête pour les pages internes */
.page-hero {
    height: 350px;
    background-size: cover;
    background-position: center;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    text-align: center;
}

.page-hero .container {
    position: relative;
    z-index: 2;
}

.page-hero h1 {
    font-size: 3.5rem;
    font-weight: 600;
    margin-bottom: 15px;
    text-shadow: 0 2px 15px rgba(0,0,0,0.3);
}

.page-hero .lead {
    color: white;
    opacity: 1;
    font-weight: 400;
    font-size: 1.3rem;
}

/* 2. Mise en page en Zig-Zag (Texte + Image) */
.feature-section {
    display: flex;
    align-items: center;
    gap: 70px; /* Grand espace entre texte et image */
    padding: 100px 25px;
}

.feature-section:nth-child(even) {
    flex-direction: row-reverse; /* Inverse l'image et le texte */
}

.feature-image {
    flex: 1.2; /* L'image prend un peu plus de place */
}

.feature-image img {
    width: 100%;
    height: 450px; /* Hauteur fixe pour l'uniformité */
    object-fit: cover; /* Recadre proprement */
    border-radius: 20px;
    box-shadow: 0 15px 40px rgba(26, 54, 93, 0.1);
}

.feature-text {
    flex: 1;
}

.feature-text h2 {
    color: var(--primary);
    margin-bottom: 25px;
    font-size: 2.3rem;
    font-weight: 600;
}

.feature-text p {
    margin-bottom: 1.5rem;
    font-size: 1.05rem;
    color: var(--text-main);
}

/* Fond alterné doux */
.bg-light {
    background-color: var(--bg-surface);
}

/* 3. Section de développement (plus simple) */
.development-section {
    padding: 80px 25px 120px;
    text-align: center;
}

.development-section h2 {
    color: var(--primary);
    margin-bottom: 40px;
}

.development-content {
    max-width: 800px;
    margin: 0 auto;
    text-align: left;
    columns: 2; /* Texte sur deux colonnes pour le style */
    column-gap: 40px;
}

@media (max-width: 768px) {
    .development-content { columns: 1; }
}