@font-face {
  font-family: "MidnightFlame";
  src: url("MidnightFlame.woff2") format("woff2");
}

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

body {
  color: #e9e3eb;
  font-family: "MidnightFlame", serif;
  background-color: #1A1422;
  line-height: 1.6;
}

/* Header: Centered and Clean */
header {
  display: flex;
  justify-content: center; /* Centers the text horizontally */
  align-items: center;     /* Centers vertically if height varies */
  padding: 20px;
  font-family: "MidnightFlame", serif;
  font-size: 20pt;
  background-color: rgba(0, 0, 0, 0.2); /* Optional: subtle background */
  width: 100%;
  margin-bottom: 25px;
}

/* Gallery : Masonry */
.gallery {
  column-count: 6; /* Creates 6 columns that stack vertically */
  column-gap: 25px; /* Space between columns */
  width: 98%;
  margin: 0 auto;
}

/* Image Styling */
.gallery img {
  display: block;
  width: 100%; /* Fill the column width */
  height: auto;      /* Keeps aspect ratio */
  border-radius: 15px; /* Optional: rounded corners */
  box-shadow: 0 4px 6px rgba(0,0,0,0.3); /* Optional: nice shadow */
  margin-bottom: 25px; /* Space between cards in the SAME column */
  break-inside: avoid; /* Prevents card from splitting across columns */
  
  /* Your original protection settings */
  -webkit-user-select: none;
  -moz-user-select: none;
  -ms-user-select: none;
  user-select: none;
  
  cursor: pointer; /* Indique visuellement que c'est cliquable */
  object-fit: contain;
  transition: transform 0.2s ease;
}

.gallery img:hover {
  transform: scale(1.02); /* Petit effet de zoom au survol */
}

/* --- LIGHTBOX / MODAL STYLES --- */
.modal {
  display: none; /* Hidden by default */
  position: fixed;
  z-index: 1000;
  left: 0;
  top: 0;
  width: 100%;
  height: 100%;
  overflow: auto;
  background-color: rgba(0, 0, 0, 0.95);
}

.modal-content {
  margin: auto;
  display: block;
  max-width: 100%;
  max-height: 85vh;
  border-radius: 10px;
  box-shadow: 0 0 20px rgba(233, 227, 235, 0.3);
  animation: zoom 0.3s;
}

@keyframes zoom {
  from {transform: scale(0)}
  to {transform: scale(1)}
}

#caption {
  margin: auto;
  display: block;
  width: 80%;
  max-width: 700px;
  text-align: center;
  color: #e9e3eb;
  padding: 10px 0;
  font-size: 14pt;
  font-family: "MidnightFlame", serif;
}

.close {
  position: absolute;
  top: 20px;
  right: 35px;
  color: #e9e3eb;
  font-size: 40px;
  font-weight: bold;
  cursor: pointer;
  transition: 0.3s;
  z-index: 1001;
}

.close:hover,
.close:focus {
  color: #fff;
  text-decoration: none;
  cursor: pointer;
}

/* Animation pour l'apparition */
.modal.show {
  display: block;
}

/* Désactiver le scroll quand le modal est ouvert */
.modal-open {
  overflow: hidden;
}

/* Responsive adjustments */
@media (max-width: 1290px) {
  .gallery {
    column-count: 4;
  }
}

@media (max-width: 1024px) {
  .gallery {
    column-count: 3;
  }
}

@media (max-width: 768px) {
  .gallery {
    column-count: 2;
  }
  
  header {
    font-size: 16pt;
  }
}




