/* Variables CSS pour faciliter les changements de thème */
:root {
    --primary-color: #2c3e50; /* Bleu profond, quasi noir */
    --secondary-color: #3498db; /* Bleu clair dynamique, pour les accents */
    --tertiary-color: #014979; /* Bleu intermédiaire, pour les autres éléments  */
    --accent-color: #f39c12; /* Touche d'orange pour les CTA importants */
    --text-color: #333;
    --light-gray: #f8f8f8;
    --dark-gray: #555;
    --border-color: #ddd;
    --shadow-light: 0 2px 8px rgba(0,0,0,0.06); /* Ombre légère pour pro */
    --shadow-hover: 0 4px 16px rgba(0,0,0,0.12); /* Ombre au hover */
    --font-heading: 'Playfair Display', serif; /* Exemple de police élégante pour les titres */
    --font-body: 'Open Sans', sans-serif; /* Exemple de police moderne et lisible pour le corps */
}

/* Base */
body {
    font-family: var(--font-body);
    line-height: 1.6;
    color: var(--text-color);
    margin: 0;
    background-color: #fff;
    overflow-x: hidden; /* Empêche le scroll horizontal indésirable */
}

h1, h2, h3, h4, h5, h6 {
    font-family: var(--font-heading);
    color: var(--primary-color);
    margin-bottom: 1rem;
    line-height: 1.2;
}

a {
    text-decoration: none;
    color: var(--secondary-color);
    transition: color 0.3s ease;
}

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

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


/* --- Header / Navigation --- */
header {
    background-color: rgba(255, 255, 255, 0.95); /* Légèrement transparent */
    padding: 15px 0;
    position: sticky; /* ou fixed si vous préférez */
    top: 0;
    z-index: 1000;
    box-shadow: var(--shadow-light);
    transition: all 0.3s ease;
}

header.scrolled { /* Classe ajoutée par JS au scroll */
    background-color: #fff;
    box-shadow: var(--shadow-hover);
    padding: 10px 0;
}

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

.logo {
    font-family: var(--font-heading);
    font-size: 1.8rem;
    font-weight: bold;
    color: var(--primary-color);
    display: flex;
    align-items: center;
    text-decoration: none; /* Pour que le logo ne soit pas souligné */
}
.logo img { /* Si le logo est une image */
    height: 60px; /* Ajustez selon votre logo */
    margin-right: 30px;
}

.nav-links {
    list-style: none;
    margin: 0;
    padding: 0;
    display: flex;
}

.nav-links li {
    margin-left: 30px;
}

.nav-links a {
    color: var(--primary-color);
    font-weight: 500;
    position: relative;
    padding-bottom: 5px; /* Espace pour l'underline animée */
}

.nav-links a::after { /* Underline animée */
    content: '';
    position: absolute;
    width: 0;
    height: 2px;
    background-color: var(--secondary-color);
    left: 0;
    bottom: 0;
    transition: width 0.3s ease;
}

.nav-links a:hover::after,
.nav-links a.active::after { /* Active pour la page courante */
    width: 100%;
}

/* --- Section Héro (Accueil) et Page Hero (autres pages) --- */
.hero, .page-hero {
    position: relative;
    height: 80vh; /* Ajustez la hauteur selon l'image */
    background-size: cover;
    background-position: center;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #fff;
    text-align: center;
    overflow: hidden;
    margin-bottom: 0; /* Pas de marge sous le hero */
}

.page-hero {
    height: 40vh; /* Plus petite pour les pages internes */
}

.hero::before, .page-hero::before { /* Overlay pour meilleure lisibilité du texte */
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.3); /* Légèrement transparent */
    z-index: 1;
}

.hero-content, .page-hero .container {
    position: relative;
    z-index: 2;
    max-width: 800px;
    padding: 20px;
}

.hero-content h1, .page-hero h1 {
    font-size: 3.5rem;
    margin-bottom: 1rem;
    color: #fff;
}
.page-hero h1 {
    font-size: 2.8rem;
}

.hero-content p, .page-hero p {
    font-size: 1.2rem;
    margin-bottom: 2rem;
    color: #eee;
}

/* Animations AOS de base (remplaceront les styles des éléments cachés par JS) */
[data-aos] {
    opacity: 0;
    transform: translateY(20px);
    transition-property: opacity, transform;
}
[data-aos].aos-animate {
    opacity: 1;
    transform: translateY(0);
}


/* --- Section Aperçu Appartements (Accueil) et Liste (Nos Appartements) --- */
.appartments-overview, .appartments-list {
    padding: 80px 0;
    background-color: var(--light-gray);
    text-align: center;
}
.appartments-list {
    background-color: #fff; /* Fond blanc pour la liste */
}


.appartments-overview h2, .appartments-list h2 {
    margin-bottom: 50px;
    font-size: 2.5rem;
}

.appartment-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 30px;
}

.appartment-card {
    background-color: #fff;
    border-radius: 8px; /* Légèrement arrondi pour pro */
    overflow: hidden;
    box-shadow: var(--shadow-light);
    transition: all 0.3s ease; /* Transition fluide */
    text-align: left;
}

.appartment-card:hover {
    transform: translateY(-4px); /* Lift subtil */
    box-shadow: var(--shadow-hover);
}

.appartment-card img {
    width: 100%;
    height: 220px;
    object-fit: cover;
    display: block;
    transition: transform 0.4s ease; /* Plus doux */
}

.appartment-card:hover img {
    transform: scale(1.02); /* Zoom minimal pour élégance */
}

.appartment-card-content {
    padding: 28px; /* Plus d'espace pour aéré */
}

.appartment-card h3 {
    margin-top: 0;
    font-size: 1.5rem;
    margin-bottom: 12px;
    color: var(--primary-color);
}

.appartment-card p {
    color: var(--dark-gray);
    font-size: 0.95rem;
    line-height: 1.6; /* Meilleure lisibilité */
    margin-bottom: 24px;
}

.appartment-card .btn {
    width: auto;
    font-size: 0.9rem;
    padding: 10px 20px;
}

/* --- Section Why Choose Us (Accueil) --- */
.why-choose-us {
    padding: 80px 0;
    background-color: #f0f4f7;
    text-align: center;
}

.why-choose-us h2 {
    margin-bottom: 50px;
}

.features-grid {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 30px;
    margin-top: 40px;
}

.feature-item {
    flex: 1 1 280px;
    background-color: #fff;
    padding: 30px;
    border-radius: 8px;
    box-shadow: var(--shadow-light);
    transition: all 0.3s ease;
}
.feature-item:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-hover);
}

.feature-item img {
    height: 50px;
    margin-bottom: 15px;
}

.feature-item h3 {
    font-size: 1.3rem;
    margin-bottom: 10px;
}

/* --- CTA Banner (Accueil) --- */
.cta-banner {
    background-size: cover;
    background-position: center;
    padding: 100px 0;
    text-align: center;
    color: #fff;
    position: relative;
}

.cta-banner .overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0,0,0,0.4);
    z-index: 0;
}

.cta-banner .container {
    position: relative;
    z-index: 1;
}

.cta-banner h2 {
    color: #fff;
    font-size: 2.5rem;
}

.cta-banner p {
    font-size: 1.2rem;
    max-width: 700px;
    margin: 20px auto 40px auto;
}

/* --- Section Appartement Détaillé --- */
.appartment-header {
    background-color: var(--primary-color); /* Couleur d'en-tête pour la page de l'appart */
    color: #fff;
    padding: 60px 0 40px 0;
    text-align: center;
}

.appartment-header h1 {
    font-size: 3rem;
    color: #fff;
}
.appartment-header .subtitle {
    font-size: 1.3rem;
    color: #eee;
    margin-top: 10px;
}

.gallery-section {
    padding: 60px 0;
}

.gallery-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 15px;
}

.gallery-grid a img {
    width: 100%;
    height: 200px;
    object-fit: cover;
    border-radius: 5px;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}
.gallery-grid a:hover img {
    transform: scale(1.03);
    box-shadow: var(--shadow-light);
}

.appartment-details {
    padding: 60px 0;
    background-color: var(--light-gray);
}

.appartment-details .container {
    display: flex;
    flex-wrap: wrap;
    gap: 40px;
}

.appartment-details .details-content {
    flex: 2;
    min-width: 300px;
}

.appartment-details .details-sidebar {
    flex: 1;
    min-width: 280px;
    background-color: #fff;
    padding: 30px;
    border-radius: 8px;
    box-shadow: var(--shadow-light);
}

.details-sidebar h3 {
    font-size: 1.5rem;
    margin-bottom: 20px;
}

.features-list {
    list-style: none;
    padding: 0;
    margin-bottom: 30px;
}

.features-list li {
    margin-bottom: 12px;
    font-size: 1rem;
    color: var(--dark-gray);
}
.features-list li strong {
    color: var(--primary-color);
    font-weight: 600;
}

.location-map {
    padding: 60px 0;
    text-align: center;
}

.location-map h2 {
    margin-bottom: 30px;
}

.map-container {
    margin-top: 30px;
    height: 400px;
    background-color: #eee;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: var(--shadow-light);
}

.map-container iframe {
    width: 100%;
    height: 100%;
    border: 0;
}

.cta-book {
    background-color: var(--secondary-color);
    color: #fff;
    padding: 60px 0;
    text-align: center;
}
.cta-book h2 {
    color: #fff;
    font-size: 2.2rem;
}
.cta-book p {
    font-size: 1.1rem;
    margin-bottom: 30px;
}
.cta-book .btn {
    background-color: var(--accent-color);
    color: #fff;
}

/* --- Page Vannes et ses environs --- */
.vannes-section {
    padding: 80px 0;
}

.vannes-intro {
    text-align: center;
    margin-bottom: 60px;
}

.vannes-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 30px;
}

.vannes-card {
    background-color: #fff;
    border-radius: 8px;
    box-shadow: var(--shadow-light);
    overflow: hidden;
}

.vannes-card img {
    width: 100%;
    height: 250px;
    object-fit: cover;
    display: block;
}

.vannes-card-content {
    padding: 25px;
}

.vannes-card h3 {
    font-size: 1.5rem;
    margin-bottom: 10px;
}

/* --- Page À Propos --- */
.about-section {
    padding: 80px 0;
    background-color: var(--light-gray);
}

.about-content {
    display: flex;
    flex-wrap: wrap;
    gap: 40px;
    align-items: center;
}

.about-text {
    flex: 2;
    min-width: 300px;
}

.about-image {
    flex: 1;
    min-width: 250px;
    text-align: center;
}

.about-image img {
    max-width: 100%;
    height: auto;
    border-radius: 8px;
    box-shadow: var(--shadow-light);
}

.team-section {
    padding: 60px 0;
    text-align: center;
}
.team-grid {
    display: flex;
    justify-content: center;
    gap: 30px;
    margin-top: 40px;
    flex-wrap: wrap;
}
.team-member {
    background-color: #fff;
    padding: 30px;
    border-radius: 8px;
    box-shadow: var(--shadow-light);
    width: 280px;
}
.team-member img {
    width: 120px;
    height: 120px;
    border-radius: 50%;
    object-fit: cover;
    margin-bottom: 15px;
    border: 3px solid var(--secondary-color);
}
.team-member h3 {
    margin-bottom: 5px;
}
.team-member p {
    color: var(--dark-gray);
    font-size: 0.9rem;
}


/* --- Page Contact --- */
.contact-form-section {
    padding: 80px 0;
}

.contact-form-section .container {
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
    gap: 40px;
}

.contact-info {
    flex: 1;
    min-width: 300px;
}

.contact-info h2 {
    margin-bottom: 25px;
}

.contact-info p {
    margin-bottom: 30px;
}

.info-item {
    margin-bottom: 20px;
}

.info-item h3 {
    font-size: 1.3rem;
    margin-bottom: 8px;
    color: var(--primary-color);
}

.info-item p {
    font-size: 1.1rem;
    margin: 0;
}

.form-wrapper {
    flex: 2;
    min-width: 400px;
    background-color: #fff;
    padding: 40px;
    border-radius: 8px;
    box-shadow: var(--shadow-light);
}

.form-wrapper h2 {
    margin-bottom: 15px;
}

.form-wrapper p {
    margin-bottom: 30px;
    color: var(--dark-gray);
}

.form-group {
    margin-bottom: 20px;
}

.form-group label {
    display: block;
    margin-bottom: 8px;
    font-weight: 600;
    color: var(--primary-color);
}

.form-group input[type="text"],
.form-group input[type="email"],
.form-group input[type="tel"],
.form-group input[type="number"],
.form-group input[type="date"],
.form-group select,
.form-group textarea {
    width: 100%;
    padding: 12px;
    border: 1px solid var(--border-color);
    border-radius: 6px; /* Léger arrondi pour inputs */
    font-size: 1rem;
    background-color: #fff;
    transition: border-color 0.3s ease, box-shadow 0.3s ease;
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
    border-color: var(--secondary-color);
    outline: none;
    box-shadow: 0 0 0 3px rgba(52, 152, 219, 0.2);
}

.form-group textarea {
    resize: vertical; /* Permet le redimensionnement vertical */
    min-height: 100px;
}

.form-wrapper .btn {
    width: 100%;
    padding: 15px;
    font-size: 1.1rem;
}


/* --- Mentions Légales / Politique de Confidentialité --- */
.legal-content {
    padding: 80px 0;
}
.legal-content h1 {
    text-align: center;
    margin-bottom: 60px;
}
.legal-content h2 {
    margin-top: 40px;
    margin-bottom: 20px;
    color: var(--secondary-color);
}
.legal-content p, .legal-content ul {
    margin-bottom: 15px;
}
.legal-content ul {
    list-style: disc;
    padding-left: 20px;
}


/* --- Footer --- */
footer {
    background-color: var(--primary-color);
    color: #fff;
    padding: 50px 0;
    text-align: center;
}

.footer-content {
    display: flex;
    justify-content: space-between;
    flex-wrap: wrap;
    text-align: left;
    gap: 20px; /* Ajout d'un écart pour les petites résolutions */
}

.footer-section {
    flex: 1;
    min-width: 250px; /* Taille minimale pour les colonnes */
    margin: 10px;
}

.footer-section h4 {
    color: var(--secondary-color);
    margin-bottom: 20px;
    position: relative;
    font-size: 1.3rem;
}

.footer-section h4::after {
    content: '';
    display: block;
    width: 50px;
    height: 2px;
    background-color: var(--secondary-color);
    margin-top: 10px;
}

.footer-section ul {
    list-style: none;
    padding: 0;
}

.footer-section ul li {
    margin-bottom: 10px;
}

.footer-section a {
    color: #ccc;
    transition: color 0.3s ease;
}

.footer-section a:hover {
    color: #fff;
}

.footer-section .social-links img {
    height: 24px;
    margin-right: 15px;
    transition: transform 0.3s ease;
}
.footer-section .social-links img:hover {
    transform: translateY(-3px);
}

.footer-bottom {
    margin-top: 40px;
    padding-top: 20px;
    border-top: 1px solid rgba(255,255,255,0.1);
    font-size: 0.9rem;
}

/* Media Queries pour le Responsive Design */
@media (max-width: 992px) {
    .appartment-details .container,
    .contact-form-section .container,
    .about-content {
        flex-direction: column;
        align-items: center;
    }
    .appartment-details .details-sidebar,
    .contact-info,
    .form-wrapper,
    .about-text,
    .about-image {
        min-width: unset;
        width: 100%;
        max-width: 600px; /* Pour éviter que les blocs ne soient trop larges sur tablettes */
    }
    .footer-content {
        justify-content: center;
        text-align: center;
    }
    .footer-section h4::after {
        margin: 10px auto;
    }
}

@media (max-width: 768px) {
    .navbar {
        flex-direction: column;
    }
    .nav-links {
        margin-top: 20px;
        flex-direction: column;
        align-items: center;
    }
    .nav-links li {
        margin: 10px 0;
    }
    .hero-content h1 {
        font-size: 2.5rem;
    }
    .page-hero h1 {
        font-size: 2rem;
    }
    .appartment-grid {
        grid-template-columns: 1fr;
    }
    .footer-content {
        flex-direction: column;
        text-align: center;
    }
    .footer-section {
        margin: 20px auto;
    }
    .footer-section h4::after {
        margin: 10px auto;
    }
    .form-wrapper {
        padding: 30px;
    }
    .contact-info {
        text-align: center;
    }
}

@media (max-width: 480px) {
    .hero-content h1 {
        font-size: 2rem;
    }
    .hero-content p {
        font-size: 1rem;
    }
    h2 {
        font-size: 1.8rem;
    }
    .appartment-card-content {
        padding: 15px;
    }
}

/* === BOUTONS UNIFORMES (version pro : rectangulaires avec léger arrondi) === */
.btn {
  display: inline-block;
  background-color: var(--primary-color);
  color: #fff;
  padding: 12px 28px;
  border-radius: 6px; /* Arrondi subtil pour pro, au lieu de 30px rond */
  font-weight: 600;
  text-decoration: none;
  transition: all 0.3s ease;
  border: none;
  cursor: pointer;
  text-transform: uppercase; /* Optionnel : majuscules pour CTA pro */
  letter-spacing: 0.5px; /* Espacement pour élégance */
}

.btn:hover {
  background-color: var(--secondary-color); /* Changement de couleur au hover pour dynamisme */
  color: #fff !important;
  transform: translateY(-1px); /* Lift minimal */
  box-shadow: var(--shadow-hover);
  text-decoration: none; /* Pas de soulignement */
}

/* Apparitions animées */
[data-aos] {
  transition: all 0.6s ease !important;
}

/* Effet léger sur le hero */
.hero {
  background-attachment: fixed;
  background-position: center;
  background-size: cover;
  position: relative;
}

/* Corrections pour le responsive mobile du formulaire de contact */

/* Forcer box-sizing sur tous les éléments pour éviter les débordements */
*, *::before, *::after {
    box-sizing: border-box;
}

/* Correction de la largeur minimale du form-wrapper */
.form-wrapper {
    flex: 2;
    min-width: 320px;
    max-width: 100%; /* Ajout important */
    background-color: #fff;
    padding: 40px;
    border-radius: 8px;
    box-shadow: var(--shadow-light);
}

/* Correction des inputs pour qu'ils respectent le padding du parent */
.form-group input[type="text"],
.form-group input[type="email"],
.form-group input[type="tel"],
.form-group input[type="number"],
.form-group input[type="date"],
.form-group select,
.form-group textarea {
    width: 100%;
    max-width: 100%; /* Sécurité supplémentaire */
    padding: 12px;
    border: 1px solid var(--border-color);
    border-radius: 6px;
    font-size: 1rem;
    background-color: #fff;
    transition: border-color 0.3s ease, box-shadow 0.3s ease;
    box-sizing: border-box; /* Important pour éviter que padding + border ne dépasse */
}

/* Correction du bouton */
.form-wrapper .btn {
    width: 100%;
    max-width: 100%;
    padding: 15px;
    font-size: 1.1rem;
    box-sizing: border-box;
}

/* Media queries spécifiques pour mobile */
@media (max-width: 768px) {
    .contact-form-section .container {
        padding: 0 15px; /* Réduction du padding sur mobile */
    }
    
    .form-wrapper {
        min-width: unset;
        width: 100%;
        padding: 25px 20px; /* Réduction du padding interne sur mobile */
        margin: 0; /* Suppression des marges */
    }
    
    .contact-info {
        width: 100%;
        padding: 0;
    }
}

@media (max-width: 480px) {
    .container {
        padding: 0 15px; /* Padding réduit sur très petits écrans */
    }
    
    .form-wrapper {
        padding: 20px 15px; /* Encore moins de padding sur très petits écrans */
        border-radius: 0; /* Optionnel : supprime les bords arrondis pour gagner de l'espace */
    }
    
    .form-group input[type="text"],
    .form-group input[type="email"],
    .form-group input[type="tel"],
    .form-group input[type="number"],
    .form-group input[type="date"],
    .form-group select,
    .form-group textarea {
        font-size: 16px; /* Évite le zoom automatique sur iOS */
        padding: 10px;
    }
    
    .form-wrapper .btn {
        font-size: 1rem;
        padding: 12px;
    }
}