/* === Popup mineurs ===*/
#popup-overlay {
  position: fixed;
  top: 0; left: 0;
  width: 100vw;
  height: 100vh;
  background: radial-gradient(circle at center, rgba(0,0,0,0.85) 0%, rgba(0,0,0,0.6) 100%);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 9999;
  padding: 2rem;
  box-sizing: border-box;
}

#popup-content {
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  max-width: 90vw;
  max-height: 90vh;
  color: white;
  opacity: 1;
  transition: opacity 0.6s ease;
}

#popup-content h1 {
  font-size: 3rem;
  font-weight: bold;
  margin-bottom: 1rem;
  text-shadow: 0 0 6px rgba(0, 0, 0, 0.4);
}

#popup-text {
  max-width: 60ch;
  margin-bottom: 1.5rem;
  font-size: 1.2rem;
  line-height: 1.6;
  text-shadow: 0 0 4px rgba(0, 0, 0, 0.3);
}

#popup-bottle {
  height: 35vh;
  max-height: 300px;
  margin: 1rem 0;
  display: block;
}

#popup-buttons {
  display: flex;
  gap: 1rem;
  flex-wrap: wrap;
  justify-content: center;
  margin-top: 1rem;
}

#popup-buttons button {
  font-size: 1rem;
  padding: 0.75rem 1.5rem;
  border: 1px solid black;
  background: white;
  color: black;
  font-weight: bold;
  border-radius: 0;
  cursor: pointer;
  transition: background 0.2s ease;
}

#popup-buttons button:hover {
  background: #f0f0f0;
}

@media (max-width: 768px) {
  #popup-content h1 {
    font-size: 2rem;
  }

  #popup-text {
    font-size: 1rem;
  }

  #popup-bottle {
    height: 28vh;
  }

  #popup-buttons button {
    width: 100%;
    padding: 0.75rem;
  }

  #popup-buttons {
    flex-direction: column;
    align-items: stretch;
  }
}



/* === Container principal === */
html, body {
  height: 100%;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  font-family: 'Helvetica Neue', sans-serif;
  overflow-x: hidden;
}

body {
  flex: 1;
cursor: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' height='32' width='32'%3E%3Ctext y='24' font-size='24'%3E🦔%3C/text%3E%3C/svg%3E") 0 0, auto;
}


main {
  flex: 1;
  display: flex;
  flex-direction: column;
}

footer {
  flex-shrink: 0;
  background: rgba(255,255,255,0.2);
  backdrop-filter: blur(8px);
  padding: 1rem 2rem;
  border-top: 1px solid rgba(255,255,255,0.3);
  z-index: 1;
  position: relative;
  margin-top: auto;
}

/* === Overlay flouté === */
.overlay {
  position: absolute;
  top: 0; left: 0;
  width: 70%; height: 70%;
  backdrop-filter: blur(3px);
  z-index: -1;
}

/* === Structure du contenu === */
.container {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-start;
  justify-content: center;
  gap: 2rem;
  max-width: 1200px;
  margin: 0 auto;
  padding: 2rem;
}




.main-title {
  font-size: 0.4rem;
  font-weight: bold;
  color: white;
  margin-top: 1rem;
  text-align: justify;
}







.bottle {
  flex: 0 0 auto;
  margin-right: 2rem;
  max-height: 40vh;
  filter: blur(2px);
  transition: filter 0.3s ease-in-out;
  animation: focusPulse 6s ease-in-out infinite;
}

.bottle:hover, .bottle:focus-within {
  filter: blur(0);
}



.content {
  position: relative;
  z-index: 1;
  color: white;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: flex-start;
  padding: 5vw;
  margin: 2vw;
  max-width: 90vw;
  background: rgba(255,255,255,0.1);
  backdrop-filter: blur(10px);
  border-radius: 0;
  text-align: justify;
  box-sizing: border-box;
  padding-bottom: 200px;
  flex-grow: 1;
}

.content h1 {
  font-size: 6vw;
  margin-bottom: 1em;
  text-shadow: 0 2px 4px rgba(0,0,0,0.5);
}

.content p {
  font-size: 1.4em;
  line-height: 1.6em;
  max-width: 60ch;
}

.content a {
  display: inline-block;
  margin-top: 2em;
  padding: 0.75em 1.5em;
  background: rgba(255,255,255,0.2);
  color: white;
  border: 1px solid white;
  border-radius: 5px;
  backdrop-filter: blur(5px);
  transition: all 0.3s ease-in-out;
}

.content a:hover {
  background: rgba(255,255,255,0.4);
  color: black;
  border-color: black;
}

/* === Logos === */
.content img.logo, .logoip {
  display: block;
  margin-bottom: 1rem;
}

.logoip {
  width: clamp(60px, 8vw, 100px);
  background: white;
  padding: 0.5rem;
  border-radius: 50%;
  box-shadow: 0 0 2px rgba(0,0,0,0.05);
}

.text-block {
  display: flex;
  flex: 1;
  flex-direction: column;
  align-items: flex-start;
  width: clamp(300px, 100%, 400px); /* force une base plus lisible sur desktop */
}

.text-block h1 {
  font-size: 1.5rem;
  margin-bottom: 1rem;
}








.text-block .logo {
  width: 100%;
  height: auto;
  margin-bottom: 1rem;
}

.text-block .logoip {
  width: 72px;
  margin-bottom: 1rem;
}

.text-block .text {
  width: 100%;
  font-size: 1.1rem;
  line-height: 1.6;
  text-align: left;
  margin-bottom: 1rem;
}

.text-block .cta-container {
  margin: 1rem 0;
}

.extra-links.clean {
  display: block;
  font-size: 1rem;
  color: white;
  margin-top: 2rem;
  line-height: 1.6;
  text-align: left;
}



.extra-links.clean a {
  color: white;
  text-decoration: underline;
  margin: 0 0.25em;
  font-weight: normal;
  font-style: normal;
  background: none !important;
  border: none !important;
  padding: 0 !important;
  box-shadow: none !important;
  display: inline;
}

.extra-links.clean a:hover {
  color: #ddd;
  text-decoration: underline;
}












.text-with-logo .logoip {
  margin-bottom: 0;
}

/* === Pied de page === */
.footer {
  margin-top: 1.5rem;
  background: white;
  color: black;
  padding: 0.5rem;
  border-radius: 0.5rem;
  font-size: 0.8rem;
  display: inline-block;
}

.links {
  margin-top: 1rem;
  font-size: 0.85rem;
}

.links a {
  color: white;
  margin: 0 0.5rem;
  text-decoration: underline;
}

#footer-box {
  max-width: 600px;
  margin: 2rem auto;
  padding: 1rem;
  background: #f9f9f9;
  border-radius: 0;
  box-shadow: 0 2px 6px rgba(0,0,0,0.08);
  text-align: center;
}

#footer-links {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 0.75rem;
  font-size: 1.12em;
  font-weight: 600;
}

#footer-links a {
  text-decoration: underline;
  transition: opacity 0.2s ease;
}

#footer-links a:hover {
  opacity: 0.8;
}

/* === Liens ====*/
.extra-links {
  margin-top: 1.5rem;
  padding-top: 1rem;
  border-top: 1px solid rgba(255, 255, 255, 0.2);
  font-size: 0.95rem;
}

.extra-links ul {
  list-style: none;
  padding: 0;
  margin: 0;
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem 1.25rem;
}

.extra-links li {
  display: inline;
}

.extra-links a {
  color: white;
  text-decoration: underline;
  transition: opacity 0.2s ease;
}

.extra-links a:hover {
  opacity: 0.8;
}

@media (max-width: 768px) {
  .extra-links ul {
    flex-direction: column;
    align-items: center;
  }

  .extra-links {
    text-align: center;
  }
}



/* === Accessibilité & Modes === */


#readable-toggle {
  background: none;
  color: white;
  border: none;
  font-weight: normal;
  text-decoration: underline;
  font-size: 1rem;
  padding: 0;
  margin-left: 0.25em;
  cursor: pointer;
}

#readable-toggle:hover {
  color: #FF0000;
}



.night-toggle {
  bottom: 1rem;
  right: 1rem;
  background: #111;
  color: #f0f0f0;
  border: 1px solid #444;
  font-size: 1rem;
}

.night-toggle:hover {
  background: #222;
}

body.night-mode {
  background: #000;
  color: #dcdcdc;
  cursor: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' height='32' width='32'%3E%3Ctext y='24' font-size='24'%3E🦔%3C/text%3E%3C/svg%3E") 0 0, auto;
}

body.night-mode .logoip {
  content: url('moon.png');
 width: 120px;         /* augmente la largeur */
  height: auto;         /* conserve les proportions */
  filter: drop-shadow(0 0 6px rgba(255,255,255,0.3)) blur(0.8px);
  animation: moon-shimmer 3s ease-in-out infinite;
}



.night-mode .content {
  background: rgba(0,0,0,0.6);
  backdrop-filter: blur(8px);
}

.night-mode a {
  color: #bbb;
}

.night-mode a:hover {
  color: #fff;
}

.night-mode img {
  filter: brightness(0.4) contrast(1.3) grayscale(40%);
}

body.night-mode .logo-ip {
  height: 2em;
  transform: rotate(-10deg);
  filter: drop-shadow(0 0 6px rgba(255,255,255,0.3)) blur(0.8px);
  animation: moon-shimmer 3s ease-in-out infinite;
}



@keyframes moon-shimmer {
  0%, 100% { filter: drop-shadow(0 0 6px rgba(255,255,255,0.3)) blur(0.8px); }
  50%      { filter: drop-shadow(0 0 12px rgba(255,255,255,0.6)) blur(1.4px); }
}

/* === Arrière-plan animé === */
.background-container {
  position: fixed;
  top: 0; left: 0;
  width: 100vw; height: 100vh;
  z-index: -1;
  overflow: hidden;
}

.background-container img {
  position: absolute;
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0;
  animation: fade 60s infinite;
}

.background-container img:nth-child(1) { animation-delay: 0s; }
.background-container img:nth-child(2) { animation-delay: 15s; }
.background-container img:nth-child(3) { animation-delay: 30s; }
.background-container img:nth-child(4) { animation-delay: 45s; }

@keyframes fade {
  0% { opacity: 0; }
  10% { opacity: 1; }
  40% { opacity: 1; }
  50% { opacity: 0; }
  100% { opacity: 0; }
}

@keyframes focusPulse {
  0%, 100% { filter: blur(2px); }
  45%, 55% { filter: blur(0); }
}

/* === Responsive mobile === */
@media (max-width: 768px) {
  .container {
    flex-direction: column;
    align-items: center;
  }

  .bottle {
    margin: 0 0 1rem;
    max-height: 30vh;
    filter: none;
  }

  .content, .content h1, .content p {
    align-items: center;
    text-align: center;
    padding: 2rem;
    font-size: 1em;
    text-shadow: 0 0 4px rgba(0,0,0,0.4);
  }

  .content h1 {
    font-size: 2em;
  }

  .text-with-logo .logo, .text-with-logo .logoip {
    max-width: 60%;
    margin: 0 auto 1rem;
  }

  .cta-container {
    flex-direction: column;
    gap: 0.75rem;
    width: 100%;
    margin-top: 1rem;
  }

  .text {
    max-width: 90vw;
  }
}

/* === Accessibilité et lecture aisée === */
.visually-hidden {
  position: absolute !important;
  width: 1px !important;
  height: 1px !important;
  margin: -1px !important;
  padding: 0 !important;
  overflow: hidden !important;
  clip: rect(0 0 0 0) !important;
  white-space: nowrap !important;
  border: 0 !important;
}

.readable-mode .content {
  background: #fff !important;
  color: #111 !important;
  font-size: 1.5em;
  line-height: 1.8em;
}

.readable-mode .text {
  font-size: 1.5rem;
  line-height: 1.8;
}

.readable-mode .background-container {
  display: none;
}

@media (prefers-contrast: more) {
  .content {
    background: #fff !important;
    color: #000 !important;
  }
  .content a {
    background: #000 !important;
    color: #fff !important;
  }
}


.cta {
  all: unset;
  background: red !important;
  color: white !important;
  font-weight: bold !important;
  font-style: italic !important;
  font-size: 130% !important;
  padding: 0.9rem 1.8rem !important;
  display: inline-block !important;
  cursor: pointer !important;
  text-align: center;
  line-height: 1;
}


.cta:hover {
  background: #cc0000;
}

/* === MODE HAUTE-LISIBILITÉ CORRIGÉ === */

.readable-mode body,
.readable-mode main {
  background: white !important;
  color: black !important;
}

.readable-mode .background-container,
.readable-mode img,
.readable-mode .logo,
.readable-mode .logoip,
.readable-mode .bottle {
  display: none !important;
}

.readable-mode .content,
.readable-mode .text,
.readable-mode .text-block {
  background: none !important;
  color: black !important;
  font-size: 1.5rem !important;
  line-height: 1.8 !important;
}

.readable-mode .extra-links {
  background: none !important;
  color: black !important;
  font-size: 1.3rem !important;
  line-height: 1.8 !important;
}

.readable-mode a {
  color: black !important;
  text-decoration: underline !important;
}

.readable-mode a:hover {
  color: #FF0000 !important;
}

/* 🎯 Ciblage exclusif du bouton Denner */
.readable-mode .cta {
  background: red !important;
  color: white !important;
  font-weight: bold;
  font-style: italic;
  font-size: 130%;
  border: none;
  border-radius: 0;
  text-decoration: none;
  display: inline-block;
  padding: 0.9rem 1.8rem;
  line-height: 1;
}

.readable-mode .cta:hover {
  background: #cc0000 !important;
  color: white !important;
}

#readable-toggle,
#night-toggle {
  color: white;
  text-decoration: underline;
  font-weight: normal;
  font-size: 1rem;
  cursor: pointer;
}

#readable-toggle:hover,
#night-toggle:hover {
  color: #FF0000;
}






