.accessibility-wrapper {
    position: fixed;
    top: 10px;
    right: 10px;
    z-index: 9999;
    display: flex;
    flex-direction: column;
    align-items: flex-end;
}

#toggle-accessibility-panel {
    color: white;
    border: none;
    padding: 10px;
    font-size: 20px;
    cursor: pointer;
    border-radius: 50%;
    width: 50px;
    height: 50px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.3s ease-in-out;
}
#toggle-accessibility-panel:hover {
    background: #444;
}

#accessibility-message {
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    color: black;    
    font-size: 5rem;    
    font-weight: bold;
    padding: 15px 25px;
    border-radius: 10px;
    display: none;      
    z-index: 10000;
    text-align: center;
    box-shadow: 0 0 15px rgba(0,0,0,0.3);
    background: white; 
    pointer-events: none; 
    max-width: 80%;
    word-wrap: break-word;
}

.accessibility-panel {
    padding: 10px;
    border-radius: 10px;
    display: flex;
    flex-direction: column; 
    gap: 10px;
    flex-wrap: wrap;
    justify-content: center;
    margin-top: 5px;
    transition: opacity 0.3s ease-in-out, transform 0.3s ease-in-out;
}
.hidden {
    display: none;
}

.accessibility-panel button {
    background: white;
    border: 1px solid #282c34;
    padding: 8px;
    cursor: pointer;
    font-size: 14px;
    transition: 0.3s;
    border-radius: 5px;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
}
.accessibility-panel button:hover {
    background: #ddd;
}

.grayscale {
    filter: grayscale(100%);
}

.dyslexic-font {
    font-family: 'OpenDyslexic', Arial, sans-serif;
}
body.dyslexic-font,
body.dyslexic-font * {
    font-family: 'OpenDyslexic', Arial, sans-serif !important;
}

.spaced-text {
    letter-spacing: 2px;
    line-height: 1.8;
}

.high-contrast {
    background: black !important;
    color: yellow !important;
}
body.high-contrast,
body.high-contrast * {
    color: white !important;
    border-color: white !important;
}
body.high-contrast {
    background: black !important;
}
body.high-contrast * {
    background-color: black !important;
}
body.high-contrast img,
body.high-contrast video,
body.high-contrast svg {
    filter: none !important;
    background: none !important;
}

.no-animation * {
    animation: none !important;
    transition: none !important;
}

.big-cursor {
    cursor: url('big-cursor.png'), auto;
}

html.zoom {
    font-size: 120%; 
}

#zoom-wrapper {
  transform-origin: top center;
  transition: transform 0.3s ease-in-out;
}

#zoom-wrapper.zoom-120 {
  transform: scale(1.2);
}

#zoom-wrapper.zoom-150 {
  transform: scale(1.5);
}
@media screen and (max-width: 1024px) {
  .accessibility-wrapper {
    position: absolute; 
    top: 35px; 
    left: 240px; 
    right: auto;
    flex-direction: row;
    align-items: center;
    justify-content: flex-start;
  }

  .accessibility-panel {
    flex-direction: row !important;
    gap: 8px;
    position: absolute; 
    top: 50px;
    left: 0;
    background: white;
    padding: 5px;
    border-radius: 8px;
    box-shadow: 0 0 8px rgba(0,0,0,0.2);
    z-index: 10000;
  }

  /* Masquer tous les boutons */
  .accessibility-panel button {
    display: none !important;
  }

  /* Afficher seulement les 3 voulus */
  .accessibility-panel button#toggle-contrast,
  .accessibility-panel button.toggle-dyslexic-font,
  .accessibility-panel button.toggle-letter-spacing {
    display: flex !important;
  }

  #accessibility-message {
    display: none !important;
  }
}
