:root {
  /* ----------------- fonts --------------- */
  --font-serif: "CMU Serif", serif;
  --font-sans-serif: "Geist", sans-serif;
  --font-display: "Praise", cursive;
  --font-display: "CMU Serif", cursive;

  /* ------------------ couleurs ---------------- */
  --color-light-beige: #f7f2e4;
  --color-mauve-med: #341830;
  --color-mauve-dark: #3f0036;

  --background: #f7f2e4;
  --text: var(--color-mauve-med);
  --links: var(--color-mauve-dark);
}

html {
  scroll-behavior: smooth;
  scroll-padding-top: 3rem;
}

body {
  background-color: var(--background);
  font-family: var(--font-serif);
}

/* ----------- texte --------------  */
.d1 {
  font-family: var(--font-display);
  color: var(--text);
  font-size: 4rem;
  font-weight: 600;
}

/* pour Quoi de neuf ? et le titre des articles blog */
.d2 {
  font-family: var(--font-display);
  font-size: 3rem;
  font-weight: 600;
  color: var(--text);
}

h1,
h2,
h3,
h4,
h5 {
  font-family: var(--font-serif) !important;
  color: var(--text);
  font-weight: 600;
  margin-top: 3rem;
  margin-bottom: 1.5rem;
}

p {
  font-size: 1.25rem;
  line-height: 1.6;
  font-family: var(--font-serif);
}

.katex {
  font-size: 1.25rem;
}

@media (max-width: 600px) {
  p {
    font-size: 1rem; /* 16px sur mobile */
    line-height: 1.55;
  } 

  .katex {
  font-size: 1rem;
}
}

@media (min-width: 600px) {
   .text-decoration-lg-none {
    text-decoration: none !important;
  }
}

hr {
  all: unset;
  display: block;
  height: 2px;
  max-width: 500px;
  opacity: 0.5;
  background-image: linear-gradient(
    to right,
    var(--text) 0%,
    var(--text) 80%,
    transparent 100%
  );
  margin-bottom: 1.5rem;
}

a {
  font-style: italic;
  font-family: var(--font-serif);
  color: var(--color-mauve-dark);
  transition: opacity 0.5s cubic-bezier(0.4, 0, 0.2, 1) !important;
}

a:hover {
    cursor: pointer !important;
    opacity: 0.6 !important;
    transition: opacity 0s steps(1, start) !important;
}

i {
  color: var(--text);
}

.toc-h2 {
  padding-left: 0.5rem;
}

.toc-h3 {
  padding-left: 1rem;
}

.toc-h4 {
  padding-left: 1.5rem;
}

.toc-h5 {
  padding-left: 2rem;
}

.my-chevron-123 {
    bottom: 4% !important;
    font-size: 2rem !important;
} 


@media (max-width: 576px) {
  .slide-in-left {
    max-width: 6rem !important;
  }

  .gap-4 {
    gap: 1rem !important;
  }

  .my-nav-link {
    font-size: 1rem;
  }
}

.elfsight-app-5e059b5c-451b-4804-ba57-5a7f0413227a {
  margin: 0 auto !important;
} 
/* ---------------------------
            gallery 
--------------------------- */

.gallery {
  display: grid;
  grid-template-columns: 1fr;
  gap: 1rem;
}

@media (min-width: 768px) and (max-width: 991.98px) {
  .gallery {
    grid-template-columns: repeat(2, 1fr);
  }
}

/* Desktop: ≥992px */
@media (min-width: 992px) {
  .gallery {
    grid-template-columns: repeat(3, 1fr);
  }
}

.gallery-item {
  display: block;
  transition: transform 0.3s ease;
}

.gallery-item img:hover {
  opacity: 90%;
  transition-duration: 400ms;
  transform: scale(0.99);
}

.card-columns {
  column-count: 1;
  column-gap: 1.25rem;
}

@media (min-width: 576px) {
  .card-columns {
    column-count: 2;
  }
}

@media (min-width: 768px) {
  .card-columns {
    column-count: 3;
  }
}

@media (min-width: 992px) {
  .card-columns {
    column-count: 4;
  }
}

@media (min-width: 1200px) {
  .card-columns {
    column-count: 5;
  }
}

.gallery-item img {
  width: 100%;
  border-radius: 8px;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
}

/* card-columns  */

@media screen and (min-width: 925px) {
  .card-columns {
    column-count: 3;
  }
}

.filter-buttons {
  margin-bottom: 2rem;
}

.filter-buttons button {
  background: #eee;
  border: 2px #341830;
  padding: 0.5rem 1rem;
  margin: 0 5px;
  border-radius: 5px;
  cursor: pointer;
  transition: background 0.3s;
}

.filter-buttons button:hover,
.filter-buttons button.active {
  background: #341830;
  color: white;
}

/* status dot */

.status-dot {
  position: absolute;
  top: 10px;
  right: 10px;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  border: 1px solid white;
  z-index: 2;
}

.dot-green {
  background-color: #28a745;
}

.dot-red {
  background-color: #dc3545;
}

/* Toggle Switch Stylé */
.toggle-switch {
  position: relative;
  display: inline-block;
  width: 60px;
  height: 34px;
}

.toggle-switch input {
  opacity: 0;
  width: 0;
  height: 0;
}

.slider {
  position: absolute;
  cursor: pointer;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background-color: #ccc;
  transition: 0.4s;
  border-radius: 34px;
}

.slider:before {
  position: absolute;
  content: "";
  height: 26px;
  width: 26px;
  left: 4px;
  bottom: 4px;
  background-color: white;
  transition: 0.4s;
  border-radius: 50%;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
}

input:checked + .slider {
  background-color: #341830;
}

input:checked + .slider:before {
  transform: translateX(26px);
}

.gallery-hover-wrapper {
  position: relative;
}

.gallery-overlay {
  position: absolute;
  bottom: 0;
  left: 0;
  width: 100%;
  background: rgba(52, 24, 48, 0.8);
  /* Semi-transparent dark overlay */
  color: white;
  padding: 5px 10px;
  font-size: 0.9rem;
  opacity: 0;
  transition: opacity 0.3s ease;
  pointer-events: none;
  border-bottom-left-radius: 8px;
  border-bottom-right-radius: 8px;
}

.gallery-hover-wrapper:hover .gallery-overlay {
  opacity: 1;
}

.overlay-text {
  display: block;
}

@media (max-width: 768px) {
  .container-index {
    padding: 1rem;
  }

  .slide-in-left {
    max-width: 8rem !important;
  }

  .my-chevron-123 {
    margin-top: 1rem !important;
    font-size: 1.5rem !important;
  }

  .button2 {
    font-size: 1.1rem;
  }
}

/* -----------------------------------
                  buttons 
------------------------------------ */
/* my-nav-li */
.button2 {
  padding: 0;
  margin: 0;
  border: none;
  background: none;
  cursor: pointer;
}

.button2 {
  --hovered-color: #4a2344;
  position: relative;
  display: flex;
  gap: 0.5rem;
  align-items: center;
  font-size: 1.3rem;
}

.button2 p {
  margin: 0;
  position: relative;
  color: var(--hovered-color);
}

.button2::after {
  position: absolute;
  content: "";
  width: 0;
  left: 0;
  bottom: -7px;
  background: #4a2344;
  height: 2px;
  transition: 0.3s ease-out;
}

.button2 p::before {
  position: absolute;
  /*   box-sizing: border-box; */
  width: 0%;
  inset: 0;
  color: #4a2344;
  overflow: hidden;
  transition: 0.3s ease-out;
}

.button2:hover::after {
  width: 100%;
}

.button2:hover p::before {
  width: 100%;
}

.button2:hover svg {
  transform: translateX(4px);
  color: #4a2344;
}

.button2 svg {
  color: #341830;
  transition: 0.2s;
  position: relative;
  width: 15px;
  transition-delay: 0.2s;
}

.btn-primary {
  background-color: #341830 !important;
  padding: 0.8rem 1.4rem !important;
  border-color: #341830 !important;
  font-size: 1.3rem !important;
  border-radius: 30px !important;
}

.btn-primary:hover,
.btn-primary:focus,
.btn-primary:active {
  background-color: #4a2344 !important;
  border-color: #4a2344 !important;
}

.btn-outline-primary:hover {
  background-color: #341830 !important;
  color: white !important;
}

.btn-outline-primary:hover i {
  /* background-color: #341830 !important;   */
  color: white !important;
}

.btn-outline-primary {
  border-color: #341830 !important;
  color: #341830 !important;
}



/* ------------------------- animations -------------------------  */
.fade-in {
  opacity: 0;
  animation: fadeIn 0.5s ease-out forwards;
}

@keyframes fadeIn {
  to {
    opacity: 1;
  }
}

.slide-in-left {
  opacity: 0;
  transform: translateX(-100px) rotate(-10deg);
  animation: slideInLeft 1s ease-out forwards;
}

@keyframes slideInLeft {
  to {
    opacity: 1;
    transform: translateX(0) rotate(0deg);
  }
}

.my-chevron-animation {
  animation: chevron 1s ease-in-out infinite alternate;
}

@keyframes chevron {
  from {
    transform: translateY(10px);
  }

  to {
    transform: translateY(0px);
  }
}

.gradient-line {
  max-width: min(300px, 90vw);
  height: 2px;
  margin-left: auto;
  margin-right: auto;
  border: none;
  background: linear-gradient(
    to right,
    transparent 0%,
    currentColor 25%,
    currentColor 75%,
    transparent 100%
  );
  opacity: 0.6;
}