/* ========== RESET DE BASE ========== */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

a {
  text-decoration: none;
  color: #0a3d91; /* ← plus contrasté que #576D88 */
  transition: all 0.3s ease;
  font-weight: 600;
}

a:hover {
  color: #034d96; /* ← couleur d’accent plus vive */
  text-decoration: underline; /* ← pour l’accessibilité */
}

body {
  font-family: "Segoe UI", Tahoma, Geneva, Verdana, sans-serif;
   /* font-size: 16px;         légèrement réduit, pour affiner la hiérarchie */
  line-height: 1.4;
  background-color: #f9f9f9;
  color: #333;
}

/* ========== TYPOGRAPHIE GÉNÉRALE ========== */
h1 {
	font-size: 1.6rem;
	text-align: left;
	flex: 1;
	margin: 0;
}

h2 {
  color: #3E4E62;
  font-size: 1.5rem;
  margin: 1rem 0;
}

h3 {
	font-size: 1.4rem;
	margin-top: 1rem;      /* espace avant le titre */
	margin-bottom: 0.5rem;   /* espace après le titre */
	color: #576D88;
}

h4 {
	font-size: 1.1rem;
	margin-top: 0.5rem;     /* Espace au-dessus pour aérer */
	margin-bottom: 0.5rem;
	color: #576D88;
}

.textegras {
  font-weight: bold;     /* texte en gras */
  display: inline;       /* reste dans le flux du texte */
  color: inherit;        /* garde la couleur du paragraphe */
}


/* ========== EN-TÊTE ========== */
header {
  background-color: #576D88;
  color: white;
  padding: 1rem;
  position: relative;
}

.header-container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 1rem;
}

header h1 {
	font-size: 1.8rem;
	margin-bottom: 0.5rem;
}

.bandeau {
  max-width: 100%;
  height: auto;
  display: block;
  margin-bottom: 1rem;
}

/* ========== NAVIGATION ========== */
.menu-toggle {
  display: none;
}

.menu-label {
  display: none;
  font-size: 1.5rem;
  cursor: pointer;
  position: absolute;
  top: 1rem;
  right: 1rem;
  font-weight: bolder;
  z-index: 10;
}

.nav-links {
  display: flex;
  gap: 0.3rem; /* Réduire l'espace entre les items */
  margin-top: 0.5rem;
}

.nav-links a {
  color: white;
  padding: 0.3rem 0.2rem; /* Padding réduit */
  border-radius: 4px;
  flex: 1; /* Chaque item prend une part égale */
  min-width: 0; /* Essential pour le text wrapping */
  white-space: normal;
  text-align: center;
  line-height: 1;
  font-size: 0.8rem; /* Taille de police légèrement réduite */
  display: flex;
  align-items: top;
  justify-content: center;
}

.nav-links a:hover {
  background-color: rgba(255, 255, 255, 0.1); /* Fond légèrement visible */
}

.note-exclusivite {
  background-color: #f0f4fa;          /* même teinte que les cartes .livre-card */
  border: 1px solid #d0ddea;
  border-radius: 6px;
  padding: 1rem 1.2rem;
  font-size: 1rem;
  color: #2f3e5c;
  line-height: 1.5;
  text-align: justify;
  margin: 1rem 0 1.5rem 0;
  box-shadow: 0 2px 6px rgba(0,0,0,0.05);
}

.note-exclusivite strong {
  color: #034d96;    /* ton bleu principal */
}

.note-exclusivite em {
  color: #576D88;    /* ton secondaire pour l’accent du nom */
}
/* ========== CONTENU PRINCIPAL ========== */
main {
  padding: 2rem;
  max-width: 1200px;
  margin: auto;
  background-color: #fff;
}

.titre-nouveau {
  display: flex;           /* mode flex */
  align-items: center;     /* centre verticalement l'image et le texte */
  gap: 8px;                /* espace entre image et texte */
  flex-wrap: wrap;         /* permet au texte de passer sur plusieurs lignes */
}

.titre-nouveau img {
  flex-shrink: 0;          /* empêche l'image de rétrécir */
}

.titre-nouveau a {
  text-decoration: none;   /* enlève le soulignement par défaut */
  color: inherit;          /* reprend la couleur du texte du h3 */
}

.presentation-livre {
  display: flex;
  flex-wrap: wrap;
  gap: 2rem;
  align-items: center; /* align-items: flex-start;  annule le centrage vertical*/ 
  justify-content: center;
  padding: 1rem;
  border-radius: 8px;
  background-color: #fff;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.05);
}

/* Image à gauche */
.presentation-livre .livre-image {
  flex: 0 0 auto;             
  max-width: 100%;
  height: auto;
  border-radius: 8px;
  box-shadow: 2px 2px 10px rgba(0, 0, 0, 0.08);
  display: block;
  max-height: none;     /* Ne dépasse pas en hauteur */
}

/* Texte à droite */
.presentation-livre .livre-texte {
  flex: 1 1 400px;
  flex-direction: column;
  gap: 0.75rem;
  font-size: 1rem;
  text-align: justify;
  line-height: 1.4;
}

/* Titres internes en couleur */
.presentation-livre .livre-texte strong {
  display: inline;  /* ← au lieu de block */
  margin: 0;        /* supprime les marges parasites */
  color: #034d96;
  font-weight: 600;
}

.livre-texte-centre {
  display: flex;
  flex-direction: column;       /* empile le contenu verticalement */
  justify-content: center;      /* centre verticalement par rapport à l'image */
  flex: 1 1 400px;              /* garde largeur flexible */
  gap: 0.75rem;                 /* espace entre paragraphes si plusieurs */
  font-size: 1rem;
  line-height: 1.4;
  text-align: justify;
}

.aligned-list {
  max-width: 800px;
  margin: 1.5rem auto;
  padding: 1rem 1.5rem 1rem 2rem;  /* ↑ plus de padding à gauche pour les puces */
  background-color: #f5f6f8;
  border: 1px solid #dce1e8;
  border-radius: 8px;
  line-height: 1.5;
  color: #2f3e5c;
  font-weight: 500;
  list-style-position: outside;    /* garde les puces à l'extérieur */
}

.aligned-list li {
  margin-bottom: 0.5rem;
}

.aligned-list li::marker {
  color: #034d96;
  font-size: 1.1em;
}


/* ========== TEXTES ET IMAGES ========== */
.textejustify {
  margin-bottom: 1rem;
  text-align: justify;
}

.textejustify p {
  margin-bottom: 1.5rem;
  text-align: justify;
  margin-top: 1rem;
}

.images-container {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  justify-content: space-between;
  align-items: flex-end; 
  width: 100%;
}

.imagebloc {
  flex: 1 1 calc(25% - 1rem);
  min-width: none;
  margin-bottom: 1rem;
}

.imagebloc img {
  max-width: 100%;
  height: auto;
  display: block;
  border: 1px solid #ccc;
  box-shadow: 2px 2px 6px rgba(0, 0, 0, 0.1);
}

/* ========== GALERIE AVEC LÉGENDE ========== */
.galerie-legendee {
  display: flex;
  flex-wrap: nowrap; /* ← Empêche le retour à la ligne */
  overflow-x: auto; /* ← Active le défilement horizontal */
  gap: 1rem;
  padding-bottom: 0.5rem; /* Espace pour ne pas couper les ombres */
  -webkit-overflow-scrolling: touch; /* Smooth scrolling sur iOS */
  scrollbar-width: thin; /* Pour Firefox */
  scrollbar-color: #576D88 #f1f1f1; /* Pour Firefox */
}

.bloc-legende {
  flex: 0 0 auto; /* ← Empêche le rétrécissement */
  width: 300px; /* ← Largeur fixe ou min-width */
  display: flex;
  flex-direction: column;
  margin-bottom: 1rem;
}

.bloc-legende img {
  max-width: 100%;
  height: auto;
  display: block;
  border: 1px solid #ccc;
  border-radius: 4px;
  box-shadow: 2px 2px 6px rgba(0, 0, 0, 0.1);
  margin-bottom: 0.5rem;
}

.bloc-legende figcaption {
  font-size: 0.8rem;
  color: #333;
  line-height: 1.4;
  text-align: justify;
  padding: 0 0.5rem;
}

/* ===== BLOC INFO SOUS GALERIE ===== */
.bloc-info {
  max-width: 800px;              /* largeur max du bloc sur grand écran */
  margin: 1rem auto;              /* centré horizontalement + espace autour */
  padding: 1.5rem;
  background-color: #f9f9f9;      /* fond clair pour contraster */
  border: 2px solid #ccc;         /* bordure grise */
  border-radius: 8px;             /* angles arrondis */
  box-shadow: 0 2px 8px rgba(0,0,0,0.1); /* légère ombre */
  font-size: 1rem;
  line-height: 1.4;
  text-align: center;             /* texte centré */
}

.bloc-info a {
  display: inline-block;
  margin-top: 0.5rem;
  color: #2a5d9f;
  font-weight: bold;
  text-decoration: none;
}

.bloc-info a:hover {
  text-decoration: underline;
}

/* ========== GALERIE LIGHTBOX ========== */
.gallery {
  display: flex;
  flex-wrap: wrap;          /* Retour à la ligne sur desktop si nécessaire */
  gap: 1rem;                /* Espace entre les images */
  justify-content: space-between;
}

.gallery a {
  flex: 1 1 calc(25% - 1rem); /* 4 images par ligne desktop */
  display: block;
  text-align: center;
}

.gallery a img {
  width: 100%;
  height: auto;
  border-radius: 4px;
  border: 1px solid #ccc;
  box-shadow: 2px 2px 6px rgba(0,0,0,0.1);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.gallery a:hover img {
  transform: scale(1.03);
  box-shadow: 4px 4px 12px rgba(0,0,0,0.15);
}

/* Lightbox plein écran */
#lightbox-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  background: rgba(0,0,0,0.85);
  display: none;
  justify-content: center;
  align-items: center;
  z-index: 9999;
}

#lightbox-overlay img {
  max-width: 90%;
  max-height: 90%;
  border-radius: 8px;
  box-shadow: 0 0 20px rgba(0,0,0,0.5);
}

#lightbox-overlay .close-lightbox {
  position: absolute;
  top: 1rem;
  right: 1rem;
  font-size: 2rem;
  color: #fff;
  cursor: pointer;
  user-select: none;
}

/* --- Galerie spécifique aux meubles --- */
.gallery-meubles img {
  width: 300px;       /* largeur fixe sur desktop */
  height: auto;
  max-width: 100%;    /* se réduit si l’écran est plus petit */
  display: block;
  margin: auto;
}

/* ========== SECTIONS LIVRE ET PACK ========== */
.livre-offres {
  display: flex;
  justify-content: center;
  gap: 2rem;
  flex-wrap: wrap;
  margin: 2rem auto;
}

.livre-card {
  background-color: #f0f4fa;
  border: 1px solid #d0ddea;
  border-radius: 10px;
  padding: 1.5rem;
  width: 100%;
  max-width: 500px;
  text-align: center;
  box-shadow: 0 4px 8px rgba(0,0,0,0.05);
}

.livre-card-italique {
	background-color: #f0f4fa;
	text-align: center;
	font-size: 0.6rem;
	font-style: italic;
}

.livre-card h3 {
  font-size: 1.3rem;
  color: #034d96;
  margin-bottom: 1rem;
  text-align: center;
}

.livre-card p {
  margin-bottom: 1rem;
  font-size: 1rem;
}

.prix-livre {
  font-size: 1.2rem;
  color: #034d96;
  margin-bottom: 1.5rem;
  font-weight: bold;
}


/* ========== BOUTON D'ACHAT ========== */
.bouton-achat {
  display: inline-block;
  font-family: inherit;
  font-size: 1rem;
  font-weight: 600;
  color: #fff;
  background-color: #034d96;
  padding: 0.75rem 1.5rem;
  border: none;
  border-radius: 8px;
  cursor: pointer;
  text-align: center;
  transition: all 0.3s ease;
  box-shadow: 0 4px 8px rgba(0,0,0,0.1);
  animation: fadeInUp 0.6s ease forwards;
}

.bouton-achat:hover {
  background-color: #023a70;
  transform: translateY(-2px);
  box-shadow: 0 6px 12px rgba(0,0,0,0.15);
}

.livre-texte .bouton-achat {
  margin-top: 1.5rem; /* un peu plus d’air */
}

/* ====== MENU ONGLET PIÈCES ====== */
.titre-onglets {
  display: flex;
  justify-content: center;  /* centre horizontalement */
  align-items: center;      /* centre verticalement */
  margin-top: 1.5rem;
  margin-bottom: 1rem;
  width: 100%;
}

.onglets-pieces {
  margin-top: 1rem;
}

.onglets-pieces ul {
  display: flex;
  flex-direction: row; /* ← Explicitement horizontal */
  flex-wrap: wrap;
  justify-content: center;
  gap: 1rem;
  list-style: none;
  padding: 0;
}

.onglets-pieces li {
  margin: 0;
}

.onglets-pieces a {
  display: inline-block;
  padding: 0.5rem 1rem;
  background-color: #e6ecf4;
  color: #034d96;
  border-radius: 6px;
  font-weight: 500;
  box-shadow: 0 2px 4px rgba(0,0,0,0.1);
  transition: background-color 0.3s ease, transform 0.2s ease;
}

.onglets-pieces a:hover {
  background-color: #d1deed;
  transform: translateY(-2px);
}


/* ========== ANIMATION ========== */
@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* ========== PIED DE PAGE ========== */
footer {
  background-color: #576D88;
  color: white;
  padding: 1.5rem;
  margin-top: 2rem;
}

.footer-links {
  display: flex;
  justify-content: center;
  gap: 2rem;
}

.footer-links a {
  color: white;
  padding: 0.5rem;
}

.footer-links a:hover {
  color: #ddd;
}

.footer-copyright {
  margin-top: 1rem;
  font-size: 0.8rem;
  text-align: center;
}

/* ========== RESPONSIVE ========== */
/* ==================== */
/* ===== MOBILE ===== */
/* ==================== */
@media (max-width: 768px) {
  .menu-label {
    display: block;
    z-index: 10;
  }

  .nav-links {
	display: none;
	flex-direction: column;
	background-color: #425368;
	position: absolute;
	top: 100%;
	left: 0;
	width: 100%;
	padding: 1rem;
	z-index: 9;
	font-weight: bolder;
  }

  .presentation-livre {
    flex-direction: column;
    padding: 1.5rem 1rem;
  }

  /* L’image passe au-dessus, centrée */
  .presentation-livre .livre-image {
    align-self: center;
    width: auto;             /* ← très important : évite l'étirement */
    max-width: 100%;
    height: auto;
  }

  /* Le texte suit en dessous, fluide */
  .presentation-livre .livre-texte {
    flex: 1 1 auto;
    padding-top: 1rem;
  }
    
  .vente-annonce {
    flex-direction: column;
    align-items: center;
  }

  .annonce-image {
    max-width: 100%;
    height: auto;
    width: auto;
  }

  .annonce-texte {
    width: 100%;
  }
  
  .menu-toggle:checked + .menu-label + .nav-links {
    display: flex;
  }

  .textejustify,
  .promo-livre,
  .vente-annonce,
  .plan-content {
    flex-direction: column;
  }

  .texte-image,
  .vente-annonce .annonce-texte,
  .plan-content .texte-image,
  .plan-content .imagebloc {
    flex: 1 1 100%;
  }

  /* Scroll horizontal pour les images */
  .images-container {
    display: flex;
    flex-wrap: nowrap;
    overflow-x: auto;
    gap: 0.5rem;
    padding-bottom: 1rem;
    -webkit-overflow-scrolling: touch;
    scroll-snap-type: x proximity;
    align-items: flex-start;
  }

  .imagebloc {
    flex: 0 0 auto;
    width: auto;
    max-width: none;
  }

  .imagebloc img {
    height: 300px;
    width: auto;
    max-width: 100%;
    object-fit: contain;
    border-radius: 8px;
  }

  /* Galerie avec légende */
  .galerie-legendee {
    flex-wrap: nowrap;
    overflow-x: auto;
    padding-bottom: 1rem;
    -webkit-overflow-scrolling: touch;
    scroll-snap-type: x proximity;
  }

  .bloc-legende {
    width: 280px; /* Un peu plus large sur mobile */
    scroll-snap-align: start; /* Alignement au défilement */
  }

  .bloc-legende figcaption {
    font-size: 0.85rem;
    padding: 0 0.25rem;
    text-align: left;
  }


  .aligned-list {
    padding: 0.8rem 1rem 0.8rem 1.5rem;  /* moins de padding sur mobile */
    margin: 1rem auto;
    font-size: 0.95rem;
  }
  
  
  /* ========== RESPONSIVE MOBILE POUR GALERIE ========== */
  .gallery {
    flex-wrap: nowrap;          /* Scroll horizontal */
    overflow-x: auto;
    padding-bottom: 1rem;
    -webkit-overflow-scrolling: touch;
    scroll-snap-type: x proximity;
  }

  .gallery a {
    flex: 0 0 auto;             /* Empêche le rétrécissement */
    width: 200px;                /* Largeur fixe par image */
    scroll-snap-align: start;
  }

  .gallery a img {
    height: 150px;
    object-fit: cover;
  }
  
  .gallery-meubles img {
    width: 100%;   /* en mobile les images prennent toute la largeur */
    height: auto;
  }
  
  /* Footer mobile */
  footer {
    padding: 1rem;
  }

  .footer-links {
    justify-content: flex-start;
    flex-direction: column;
    gap: 0.5rem;
    padding-left: 1rem;
  }

  .footer-links a {
    padding: 0.2rem 0;
  }
}

/* ==================== */
/* ===== TABLETTE ===== */
/* (769px à 1024px) */
/* ==================== */
@media (min-width: 769px) and (max-width: 1024px) {
  /* Ajustements généraux */
  main {
    padding: 1.5rem;
  }

  /* Navigation */
  .nav-links {
    gap: 0.75rem;
  }

  /* Grille d'images : 3 colonnes */
  .images-container {
    gap: 0.75rem;
  }

  .imagebloc {
    flex: 1 1 calc(33.33% - 0.75rem); /* 3 images/ligne */
    min-width: 200px; /* Largeur minimale réduite */
  }

  /* Sections annonces/promos */
  .vente-annonce,
  .promo-livre,
  .promo-plan {
    flex-direction: row; /* Rétablit la disposition horizontale */
    gap: 1rem;
    padding: 1rem;
  }

  .vente-annonce .annonce-texte,
  .promo-livre .texte-image {
    flex: 1 1 50%; /* Ratio 50/50 */
  }

  .promo-livre .images-container {
    flex: 1 1 40%;
  }

  /* Section Plan */
  .plan-content .texte-image {
    flex: 1 1 50%;
  }

  .plan-content .imagebloc {
    flex: 1 1 40%;
  }

  .bloc-legende {
    width: 250px; /* Largeur légèrement réduite */
  }
  
  /* ========== TABLETTE (3 images par ligne) ========== */
  .gallery a {
    flex: 1 1 calc(33.33% - 0.75rem);
  }
  
  /* Footer tablette */
  .footer-links {
    gap: 1.5rem;
  }
}
