/* Accessibility Styles */

/* Accessibility Button */
.accessibility-button {
  position: fixed;
  bottom: 20px;
  left: 20px;
  width: 50px;
  height: 50px;
  border-radius: 50%;
  background-color: var(--primary-color);
  color: white;
  border: none;
  font-size: 24px;
  cursor: pointer;
  z-index: 9999;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.3);
  transition: all 0.3s ease;
}

.accessibility-button:hover,
.accessibility-button:focus {
  transform: translateY(-3px);
  box-shadow: 0 5px 15px rgba(0, 0, 0, 0.4);
  outline: none;
}

/* Accessibility Panel */
.accessibility-panel {
  position: fixed;
  left: 20px;
  bottom: 80px;
  width: 300px;
  background-color: white;
  border-radius: 15px;
  box-shadow: 0 5px 20px rgba(0, 0, 0, 0.2);
  z-index: 9998;
  transform: translateY(20px);
  opacity: 0;
  visibility: hidden;
  transition: all 0.3s ease;
  font-family: Arial, sans-serif;
}

.accessibility-panel.active {
  transform: translateY(0);
  opacity: 1;
  visibility: visible;
}

.accessibility-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 15px 20px;
  border-bottom: 1px solid #eee;
}

.accessibility-header h3 {
  margin: 0;
  font-size: 18px;
  color: var(--primary-color);
}

.close-panel {
  background: none;
  border: none;
  font-size: 24px;
  cursor: pointer;
  color: #999;
}

.close-panel:hover {
  color: #333;
}

.accessibility-options {
  padding: 15px;
}

.accessibility-option {
  display: flex;
  align-items: center;
  margin-bottom: 15px;
}

.accessibility-option button {
  width: 40px;
  height: 40px;
  border-radius: 20%;
  background-color: #f5f5f5;
  border: 1px solid #ddd;
  margin-right: 15px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 16px;
  color: #555;
  transition: all 0.2s ease;
}

.accessibility-option button:hover,
.accessibility-option button:focus {
  background-color: #e0e0e0;
  outline: none;
}

.accessibility-option button.active {
  background-color: var(--primary-color);
  color: white;
  border-color: var(--primary-color);
}

.accessibility-option span {
  font-size: 14px;
  color: #555;
}

/* Accessibility Features */

/* High Contrast Mode */
body.high-contrast {
  background-color: #000 !important;
  color: #fff !important;
}

body.high-contrast * {
  background-color: #000 !important;
  color: #fff !important;
  border-color: #fff !important;
}

body.high-contrast a,
body.high-contrast button,
body.high-contrast .btn {
  background-color: #000 !important;
  color: #ffff00 !important;
  border: 1px solid #ffff00 !important;
}

body.high-contrast img {
  filter: grayscale(100%) contrast(120%);
}

/* Negative Contrast */
body.negative-contrast {
  background-color: #000 !important;
  color: #ffff00 !important;
}

body.negative-contrast * {
  background-color: #000 !important;
  color: #ffff00 !important;
}

body.negative-contrast a,
body.negative-contrast button,
body.negative-contrast .btn {
  background-color: #ffff00 !important;
  color: #000 !important;
}

body.negative-contrast img {
  filter: invert(100%);
}

/* Links Underline */
body.links-underline a {
  text-decoration: underline !important;
  text-underline-offset: 2px;
}

/* Readable Font */
body.readable-font,
body.readable-font * {
  font-family: Arial, Helvetica, sans-serif !important;
  letter-spacing: 0.12em !important;
  word-spacing: 0.16em !important;
  line-height: 1.8 !important;
}

/* Focus Outline for Better Keyboard Navigation */
a:focus,
button:focus,
input:focus,
select:focus,
textarea:focus {
  outline: 3px solid var(--primary-color) !important;
  outline-offset: 2px !important;
}

/* Skip to Content Link */
.skip-to-content {
  position: absolute;
  top: -40px;
  left: 0;
  background: var(--primary-color);
  color: white;
  padding: 8px 15px;
  z-index: 10000;
  transition: top 0.3s;
}

.skip-to-content:focus {
  top: 0;
}

/* Mobile Optimizations */
@media (max-width: 576px) {
  .accessibility-panel {
    width: calc(100% - 40px);
    left: 20px;
    right: 20px;
  }
  
  .accessibility-button {
    width: 45px;
    height: 45px;
    font-size: 20px;
  }
}

