@import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700;800&display=swap');

* { 
    box-sizing: border-box; 
}
  body { 
    font-family: 'Inter', 'Segoe UI', system-ui, sans-serif; 
    background: #f0f2f5; 
    display: flex;
    flex-direction: column;
    min-height: 100vh;
    margin: 0;
}

  .btn-profil {
    width: 34px; 
    height: 34px; 
    border-radius: 50%;
    background: #f4bc5d; 
    color: #fff; 
    font-weight: 700; 
    font-size: 13px;
    display: flex; 
    align-items: center; 
    justify-content: center;
  }

  .section-hero {
    width: 100%;
    position: relative;
  }

  .hero {
    padding: 0; 
    color: #fff;
    width: 100%;
    margin: 0;
  }
  .hero h1 { 
    font-size: 26px; 
    font-weight: 700; 
    margin-bottom: 6px; 
}
  .hero p { 
    font-size: 13px; 
    opacity: .8; 
    margin-bottom: 20px; 
}

.carré {
  position: relative;
  width: 100%;
  padding: 0;
  max-height: 500px;
  height: 70vh;
  overflow: hidden;
  margin: 0;
  background-color: transparent;
}
.carré-item {
  display: none;
  position: relative;
  width: 100%;
  height: 100vh;
  overflow: hidden;
}
.carré-item.active {
  display: block;
  position: relative;
  width: 100%;
  height: 500px;
  overflow: hidden;
}
.carré-item img { 
  width: 100%;                  
  height: 100%;
  display: block;
  object-fit: cover;
}
.carré-item .caption {
 position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  text-align: center;
  color: white;
  min-width: 800px;
  width: 90%;
  z-index: 10;
  background: none;
}
.carré-item .caption h1 {
  font-size: 3rem;
  margin-bottom: 10px;
  text-shadow: 2px 2px 8px rgba(0,0,0,0.7);
}
.carré-item .caption h3 {
  font-size: 30px;
  text-align: left;
  margin-left: 40px;
  margin-top: 10px;
}
.carré-item .caption p {
  font-size: 1.2rem;
  margin-bottom: 20px;
  text-shadow: 1px 1px 4px rgba(0,0,0,0.7);
}
.carré-item::after {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: 1;
}

/* --- Bloc texte hero (titre, description, boutons, stats) --- */
.hero-texte-bloc {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    padding: 48px 40px;
    color: #ffffff;
    font-family: 'Inter', Arial, sans-serif;
    z-index: 5;
    display: flex;
    flex-direction: row;
    align-items: center;
    justify-content: space-between;
    gap: 24px;
}

.hero-texte-gauche {
    flex: 1;
    min-width: 0;
    background: rgba(0,0,0,0.45);
    border-radius: 16px;
    padding: 28px 32px;
    backdrop-filter: blur(2px);
}

.hero-texte-gauche h2 {
    text-shadow: none;
}

.hero-texte-gauche > p {
    text-shadow: none;
}

.hero-texte-bloc h2 {
    font-size: 2.4em;
    font-weight: 800;
    margin-bottom: 16px;
}

.hero-texte-bloc > p {
    font-size: 1.05em;
    color: #dceadb;
    max-width: 480px;
    margin-bottom: 28px;
    line-height: 1.5;
}

.hero-boutons {
    display: flex;
    gap: 14px;
    margin-bottom: 36px;
}

.btn-blanc {
    background: #ffffff;
    color: #2e5a44;
    text-decoration: none;
    font-weight: bold;
    padding: 14px 26px;
    border-radius: 999px;
}

.btn-transparent {
    background: transparent;
    color: #ffffff;
    text-decoration: none;
    font-weight: bold;
    padding: 14px 26px;
    border-radius: 999px;
    border: 1.5px solid rgba(255,255,255,0.6);
}

.hero-texte-gauche {
    flex: 1;
    min-width: 0;
}

.hero-stats {
    display: flex;
    gap: 16px;
    flex-wrap: wrap;
    flex-shrink: 0;
}

.hero-stats .stat {
    background: rgba(0,0,0,0.45);
    border-radius: 14px;
    padding: 18px 26px;
    text-align: center;
    min-width: 100px;
    backdrop-filter: blur(2px);
}

.hero-stats .stat-num {
    display: block;
    font-size: 1.6em;
    font-weight: 800;
    color: #ffffff;
}

.hero-stats .stat-lab {
    display: block;
    font-size: 0.85em;
    color: #dceadb;
    margin-top: 2px;
}

  .section-new {
    background-color: #C2D5BB;
    padding-top: 40px;
    padding-bottom: 20px;
    padding-left: 30px;
    padding-right: 30px;
  }

.flex-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 12px;
}

.flex-header .titre-section,
.flex-header .section-titre {
    margin-bottom: 0;
}

.btn-voir-plus {
    color: #2e5a44;
    font-weight: 600;
    text-decoration: none;
    font-size: 0.9rem;
}

.btn-voir-plus:hover {
    text-decoration: underline;
}

  .titre-section { 
    font-size: 20px; 
    font-weight: 700; 
    color: #444; 
    margin-bottom: 12px; 
    text-transform: uppercase; 
    letter-spacing: .5px; 
}

  .grille {
    display: flex;
    flex-wrap: wrap;       
    gap: 30px;              
    justify-content: center;
    padding: 20px;
}

.book-card {
    background: #ffffff;
    border-radius: 15px;
    padding: 25px;
    width: 220px;
    text-align: center;
    box-shadow: 0 4px 10px rgba(0,0,0,0.05);
    display: flex;
    flex-direction: column;
    align-items: center;    
}

.bulle-cat {
    width: 60px;
    height: 60px;
    background-color: #e8f0e8;
    border: 1.5px solid #e5e9e2;
    border-radius: 14px;
    margin-bottom: 15px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.icone-cat {
    font-size: 1.8rem;
    line-height: 1;
}

.nblivres {
    font-size: 0.85rem;
    color: #777;
    margin-bottom: 10px;
}

.cat-livre {
    background-color: #fdf2e9; 
    color: #e67e22;
    padding: 3px 12px;
    border-radius: 15px;
    font-size: 0.75rem;
    font-weight: 600;
}


.container-livres {
    background-color: #f2f4d2;
    padding-top: 40px;
    padding-bottom: 20px;
    padding-left: 30px;
    padding-right: 30px;
}
.section-titre { 
    font-size: 20px; 
    font-weight: 700; 
    color: #444; 
    margin-bottom: 12px; 
    text-transform: uppercase; 
    letter-spacing: .5px; 
}
.badge-violet {
    display: inline-block;
    background-color: #f3e8ff; 
    color: #7e22ce;           
    padding: 3px 12px;
    border-radius: 15px;
    font-size: 0.75rem;
    font-weight: 600; 
}
.grille-livres {
    display: flex;
    justify-content: center;
    gap: 70px;
    padding: 20px;
    flex-wrap: wrap;
}

.card-livre {
    background: #ffffff;
    border-radius: 15px;      
    overflow: hidden;         
    display: flex;
    flex-direction: column;
    width: 200px;             
    box-shadow: 0 4px 10px rgba(0,0,0,0.1);
    text-align: center;
    padding-bottom: 15px;
}

.card-livre img {
    width: 100%;              
    height: 250px;            
    object-fit: cover;       
    margin-bottom: 15px;      
}

.infos-livre {
    padding: 0 10px;        
}

.infos-livre h4 {
    font-size: 1rem;
    margin: 5px 0;
}

.infos-livre span {
    color: #888;
    font-size: 0.85rem;
}

  @media (max-width: 900px) {
    .main { grid-template-columns: 1fr; }
  }