/* --- Reset & variables --- */
:root {
  --wood-1: #6b4a2b;
  --wood-2: #b7834f;
  --accent: #f5a844;
  --muted: #f7f5f2;
  --radius: 16px;
  --transition: .3s cubic-bezier(.4, .2, .2, 1);
  --primary-color: var(--wood-1);
  --secondary-color: var(--wood-2);
  --button-color: var(--accent)
}

* {
  box-sizing: border-box
}

body {
  margin: 0;
  font-family: system-ui, -apple-system, Segoe UI, Roboto, 'Helvetica Neue', Arial, sans-serif;
  line-height: 1.55;
  color: #2c261f;
  -webkit-font-smoothing: antialiased
}

body.home {
  padding-top: 0;
}

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

/* --- Navigation --- */
.navbar {
  backdrop-filter: saturate(1.2) blur(6px)
}

.navbar .nav-link {
  position: relative;
  padding: .55rem .9rem;
  border-radius: 10px;
  font-weight: 500;
  color: #4a4138
}

.navbar .nav-link.active,
.navbar .nav-link:hover {
  background: #ece7e2;
  color: #2e2721
}

/* --- Hero --- */
.hero {
  position: relative;
  border-radius: var(--radius);
  padding: 3.4rem clamp(1.25rem, 4vw, 3rem);
  background: linear-gradient(130deg, var(--primary-color), var(--secondary-color));
  overflow: hidden;
  color: #fff
}

.hero:after {
  content: "";
  position: absolute;
  inset: 0;
  background: radial-gradient(circle at 65% 35%, rgba(255, 255, 255, .25), transparent 60%);
  mix-blend-mode: overlay;
  opacity: .5
}

.hero h1 {
  font-weight: 600;
  margin: 0 0 .6rem
}

.hero .lead {
  max-width: 680px;
  font-size: 1.13rem;
  font-weight: 400
}

.hero-video-wrapper {
  margin-top: 0;
}

/* --- Section titles --- */
.section-title {
  font-weight: 600;
  display: flex;
  align-items: center;
  gap: .65rem;
  font-size: 1.35rem;
  margin: 0 0 1.25rem
}

.section-title:before {
  content: "";
  width: 42px;
  height: 4px;
  border-radius: 4px;
  background: var(--button-color)
}

/* --- Carousel --- */
.carousel-inner img {
  filter: brightness(.95)
}

.carousel-caption {
  backdrop-filter: blur(4px)
}

/* --- Category cards --- */
.category-card {
  display: block;
  position: relative;
  border-radius: 14px;
  overflow: hidden;
  background: #fff;
  border: 1px solid #eee;
  transition: var(--transition);
  color: inherit;
  text-decoration: none
}

.category-card img {
  height: 160px;
  width: 100%;
  object-fit: cover;
  transition: var(--transition)
}

.category-card .overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(to top, rgba(0, 0, 0, .55), rgba(0, 0, 0, .05));
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  padding: 1rem;
  color: #fff
}

.category-card:hover {
  box-shadow: 0 8px 28px -8px rgba(0, 0, 0, .25);
  transform: translateY(-4px)
}

.category-card:hover img {
  transform: scale(1.05)
}

/* --- Timeline --- */
.timeline {
  list-style: none;
  margin: 0;
  padding: 0
}

.timeline li {
  display: flex;
  gap: 1rem;
  align-items: center;
  background: #fff;
  border: 1px solid #e9e3dc;
  border-radius: 14px;
  padding: .85rem 1rem;
  margin-bottom: .75rem;
  transition: var(--transition)
}

.timeline li:hover {
  box-shadow: 0 6px 18px -6px rgba(0, 0, 0, .18);
  transform: translateY(-3px)
}

.badge-date {
  background: var(--primary-color);
  color: #fff;
  padding: .45rem .7rem;
  border-radius: 9px;
  font-size: .7rem;
  font-weight: 600;
  letter-spacing: .5px;
  min-width: 72px;
  text-align: center
}

/* Past events (grisés) */
.timeline li.past {
  opacity: .6;
  filter: grayscale(.35);
  background: #f5f3f1;
  border-color: #e1dbd4
}

.timeline li.past:hover {
  box-shadow: none;
  transform: none
}

.timeline li.past .badge-date {
  background: #9c968f
}

/* --- Video --- */
.video-wrapper video {
  border-radius: 14px;
  box-shadow: 0 12px 32px -14px rgba(0, 0, 0, .35)
}

/* --- Forms / Cards --- */

.card-creation img {
  width: 100%;
  height: 210px;
  object-fit: cover;
  border-radius: 12px 12px 0 0;
  transition: var(--transition)
}

/* Hover zoom + icon */
.card-creation .creation-image-wrapper {
  position: relative;
  overflow: hidden;
  border-radius: 12px 12px 0 0
}

.card-creation .zoom-btn {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(0, 0, 0, .0);
  color: #fff;
  font-size: 2.1rem;
  border: 0;
  cursor: pointer;
  opacity: 0;
  transition: var(--transition);
  text-shadow: 0 4px 14px rgba(0, 0, 0, .6)
}

.card-creation:hover img {
  filter: grayscale(.35) brightness(.82)
}

.card-creation:hover .zoom-btn {
  opacity: 1;
  background: rgba(0, 0, 0, .35)
}

.card-creation .zoom-btn:focus-visible {
  outline: 3px solid var(--button-color);
  outline-offset: 2px
}

.card-creation img.zoomable {
  cursor: zoom-in
}

/* Lightbox */
#image-lightbox {
  position: fixed;
  inset: 0;
  z-index: 2000;
  background: rgba(0, 0, 0, .85);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 2rem;
  animation: fadeIn .25s ease
}

#image-lightbox img {
  max-width: 90vw;
  max-height: 85vh;
  border-radius: 16px;
  box-shadow: 0 18px 50px -10px rgba(0, 0, 0, .6)
}

#image-lightbox .close-btn {
  position: absolute;
  top: 1rem;
  right: 1rem;
  background: rgba(0, 0, 0, .55);
  color: #fff;
  border: 0;
  font-size: 2.2rem;
  line-height: 1;
  padding: .2rem .7rem;
  border-radius: 10px;
  cursor: pointer;
  box-shadow: 0 4px 18px -6px rgba(0, 0, 0, .5);
}

#image-lightbox .close-btn:hover {
  background: rgba(0, 0, 0, .8)
}

#image-lightbox .close-btn:focus-visible {
  outline: 3px solid var(--button-color);
  outline-offset: 2px
}

/* --- Footer --- */
.site-footer {
  font-size: .85rem
}

.site-footer a:hover {
  text-decoration: underline
}

/* --- Utilities --- */
.fade-in {
  animation: fadeIn .5s ease both
}

@keyframes fadeIn {
  from {
    opacity: 0;
    transform: translateY(8px)
  }

  to {
    opacity: 1;
    transform: none
  }
}

.btn {
  border-radius: 12px
}

.btn-light.shadow-sm {
  box-shadow: 0 4px 10px -4px rgba(0, 0, 0, .25) !important
}

.shadow-soft {
  box-shadow: 0 4px 18px -8px rgba(0, 0, 0, .15)
}

.text-muted-small {
  font-size: .85rem;
  color: #6d6258
}

a {
  text-decoration: none
}

a:hover {
  text-decoration: underline
}

/* Critical-ish styles extracted for above-the-fold (can be inlined if desired) */
:root {
  --bg: #fff;
  --text: #212529;
  --muted: #6c757d;
}

body {
  background: var(--bg);
  color: var(--text);
}

.section-title {
  font-weight: 600;
  letter-spacing: .2px;
}

.card-creation {
  background: #fff;
  border-radius: 1rem;
  box-shadow: 0 2px 10px rgba(0, 0, 0, .06);
}

.creation-image-wrapper {
  position: relative;
  background: #f6f6f6;
  aspect-ratio: 4/3;
}

.creation-image-wrapper img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

/* Ancienne version: petite pastille ronde en bas à droite.
   Demandé: recouvrir toute l'image et centrer l'icône (overlay).
   On aligne donc avec le style déjà défini plus haut pour .card-creation .zoom-btn */
.creation-image-wrapper .zoom-btn {
  position: absolute;
  inset: 0; /* couvre toute l'image */
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(0,0,0,0); /* transparent initialement */
  border: 0;
  border-radius: 0;
  color: #fff;
  font-size: 2.1rem;
  opacity: 0; /* même comportement que règle précédente (hover) */
  transition: var(--transition);
  text-shadow: 0 4px 14px rgba(0,0,0,.6);
  cursor: pointer;
}

/* Utility: thumbnail placeholder */
.img-thumb {
  width: 100%;
  height: auto;
  display: block;
  background: #eee;
}

/* Responsive grid tweaks */
@media (min-width: 992px) {
  .container {
    max-width: 1000px;
  }
}