/* ==========================================================================
   יונק'ה — Accessibility toolbar (נגישות)
   Standalone: loads after styles.css on every page. Self-contained so the
   widget stays usable in every adjustment mode it applies.
   Israeli Standard 5568 (WCAG 2.0 AA) support layer.
   ========================================================================== */

/* ---------- Floating button ---------- */
.acc-fab {
  position: fixed;
  left: 16px;
  bottom: 16px;
  z-index: 80;
  width: 56px;
  height: 56px;
  border: none;
  border-radius: 50%;
  background: #B24C23;
  color: #fff;
  display: grid;
  place-items: center;
  cursor: pointer;
  box-shadow: 0 8px 24px -8px rgba(0, 0, 0, 0.55);
  transition: transform 180ms cubic-bezier(0.23, 1, 0.32, 1), box-shadow 180ms ease;
}
.acc-fab:hover { transform: scale(1.06); }
.acc-fab:active { transform: scale(0.95); }
.acc-fab:focus-visible { outline: 3px solid #0b5cad; outline-offset: 3px; }
.acc-fab svg { width: 32px; height: 32px; display: block; }

/* lift above the sticky mobile CTA */
@media (max-width: 820px) {
  .acc-fab { bottom: 5rem; }
}

/* ---------- Panel ---------- */
.acc-panel {
  position: fixed;
  left: 16px;
  bottom: 84px;
  z-index: 81;
  width: min(340px, calc(100vw - 32px));
  max-height: min(80vh, 640px);
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
  background: #ffffff;
  color: #1c1c16;
  border: 1px solid #d8d8c4;
  border-radius: 14px;
  box-shadow: 0 24px 70px -24px rgba(0, 0, 0, 0.55);
  padding: 16px;
  font-family: "Heebo", -apple-system, "Segoe UI", Arial, sans-serif;
  font-size: 16px;
  line-height: 1.4;
  direction: rtl;
  text-align: right;
}
@media (max-width: 820px) {
  .acc-panel { bottom: calc(5rem + 68px); }
}
.acc-panel[hidden] { display: none; }

.acc-panel__head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 12px;
  padding-bottom: 10px;
  border-bottom: 1px solid #ececd8;
}
.acc-panel__title {
  margin: 0;
  font-size: 1.15rem;
  font-weight: 800;
  color: #1c1c16;
}
.acc-panel__close {
  flex: none;
  width: 38px;
  height: 38px;
  border: none;
  border-radius: 9px;
  background: #f2f0e6;
  color: #444;
  font-size: 1.5rem;
  line-height: 1;
  cursor: pointer;
  transition: background 150ms ease;
}
.acc-panel__close:hover { background: #e4e1d2; }
.acc-panel__close:focus-visible { outline: 3px solid #0b5cad; outline-offset: 2px; }

/* ---------- Font-size row ---------- */
.acc-fontrow {
  display: flex;
  align-items: stretch;
  gap: 8px;
  margin-bottom: 12px;
}
.acc-fontrow__label {
  flex: 1;
  display: flex;
  align-items: center;
  padding-inline-start: 4px;
  font-weight: 700;
  font-size: 0.95rem;
}
.acc-fontbtn {
  flex: none;
  min-width: 44px;
  min-height: 44px;
  border: 1.5px solid #d8d8c4;
  border-radius: 10px;
  background: #faf9f3;
  color: #1c1c16;
  font-weight: 800;
  cursor: pointer;
  transition: border-color 150ms ease, background 150ms ease;
}
.acc-fontbtn:hover { border-color: #B24C23; }
.acc-fontbtn:focus-visible { outline: 3px solid #0b5cad; outline-offset: 2px; }
.acc-fontbtn--sm { font-size: 0.85rem; }
.acc-fontbtn--lg { font-size: 1.25rem; }

/* ---------- Options grid ---------- */
.acc-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
}
.acc-opt {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 7px;
  min-height: 78px;
  padding: 12px 8px;
  border: 1.5px solid #d8d8c4;
  border-radius: 11px;
  background: #faf9f3;
  color: #1c1c16;
  font-size: 0.85rem;
  font-weight: 600;
  line-height: 1.25;
  text-align: center;
  cursor: pointer;
  transition: border-color 150ms ease, background 150ms ease, color 150ms ease;
}
.acc-opt:hover { border-color: #B24C23; }
.acc-opt:focus-visible { outline: 3px solid #0b5cad; outline-offset: 2px; }
.acc-opt[aria-pressed="true"] {
  background: #B24C23;
  color: #fff;
  border-color: #B24C23;
}
.acc-opt__ico {
  display: grid;
  place-items: center;
  width: 26px;
  height: 26px;
  font-size: 20px;
  line-height: 1;
}

/* ---------- Footer ---------- */
.acc-panel__foot {
  margin-top: 14px;
  padding-top: 12px;
  border-top: 1px solid #ececd8;
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.acc-reset {
  width: 100%;
  min-height: 44px;
  border: 1.5px solid #B24C23;
  border-radius: 10px;
  background: #fff;
  color: #B24C23;
  font-weight: 700;
  font-size: 0.95rem;
  cursor: pointer;
  transition: background 150ms ease, color 150ms ease;
}
.acc-reset:hover { background: #B24C23; color: #fff; }
.acc-reset:focus-visible { outline: 3px solid #0b5cad; outline-offset: 2px; }
.acc-statement-link {
  display: block;
  text-align: center;
  font-weight: 700;
  font-size: 0.95rem;
  color: #0b5cad;
  text-decoration: underline;
}
.acc-statement-link:focus-visible { outline: 3px solid #0b5cad; outline-offset: 2px; }
.acc-coord {
  margin: 0;
  text-align: center;
  font-size: 0.8rem;
  color: #555;
  line-height: 1.5;
}
.acc-coord a { color: #0b5cad; font-weight: 600; }

/* ==========================================================================
   ADJUSTMENT MODES  (classes toggled on <html>)
   Content overrides are scoped to header/main/footer so the toolbar itself
   is never affected.
   ========================================================================== */

/* ---- High contrast: dark ---- */
html.acc-contrast-dark,
html.acc-contrast-dark body { background: #000 !important; }
html.acc-contrast-dark .hero__media,
html.acc-contrast-dark .closing__media { display: none !important; }
html.acc-contrast-dark :is(header, main, footer, .mobilemenu)
  :where(section, div, article, figure, ul, ol, li, blockquote, header, nav,
         p, span, strong, em, h1, h2, h3, h4, h5, h6, dl, dt, dd, form, label,
         figcaption, time, small) {
  background-color: transparent !important;
  background-image: none !important;
  color: #fff !important;
  border-color: #666 !important;
  text-shadow: none !important;
}
html.acc-contrast-dark :is(header, main, footer) a { color: #ffff00 !important; text-decoration: underline !important; }
html.acc-contrast-dark :is(header, main, footer) :is(input, textarea, select) {
  background: #000 !important;
  color: #fff !important;
  border: 1px solid #fff !important;
}
html.acc-contrast-dark :is(header, main, footer) .btn,
html.acc-contrast-dark :is(header, main, footer) button[type="submit"] {
  background: #000 !important;
  color: #ffff00 !important;
  border: 2px solid #ffff00 !important;
}
html.acc-contrast-dark :is(header, main, footer) img { border: 1px solid #fff; }

/* ---- High contrast: light ---- */
html.acc-contrast-light,
html.acc-contrast-light body { background: #fff !important; }
html.acc-contrast-light .hero__media,
html.acc-contrast-light .closing__media { display: none !important; }
html.acc-contrast-light :is(header, main, footer, .mobilemenu)
  :where(section, div, article, figure, ul, ol, li, blockquote, header, nav,
         p, span, strong, em, h1, h2, h3, h4, h5, h6, dl, dt, dd, form, label,
         figcaption, time, small) {
  background-color: transparent !important;
  background-image: none !important;
  color: #000 !important;
  border-color: #333 !important;
  text-shadow: none !important;
}
html.acc-contrast-light :is(header, main, footer) a { color: #0000cc !important; text-decoration: underline !important; }
html.acc-contrast-light :is(header, main, footer) :is(input, textarea, select) {
  background: #fff !important;
  color: #000 !important;
  border: 1px solid #000 !important;
}
html.acc-contrast-light :is(header, main, footer) .btn,
html.acc-contrast-light :is(header, main, footer) button[type="submit"] {
  background: #fff !important;
  color: #0000cc !important;
  border: 2px solid #0000cc !important;
}

/* ---- Grayscale ---- */
html.acc-grayscale { filter: grayscale(100%) !important; }

/* ---- Readable font ---- */
html.acc-readable-font :is(header, main, footer),
html.acc-readable-font :is(header, main, footer) * {
  font-family: Arial, "Segoe UI", Tahoma, sans-serif !important;
  letter-spacing: 0.03em !important;
}

/* ---- Increased line spacing ---- */
html.acc-line-height :is(header, main, footer)
  :is(p, li, a, span, dt, dd, blockquote, h1, h2, h3, h4, h5, h6, label, figcaption) {
  line-height: 2 !important;
}

/* ---- Highlight links ---- */
html.acc-highlight-links :is(header, main, footer) a {
  text-decoration: underline !important;
  outline: 2px solid #ffbf00 !important;
  outline-offset: 2px;
  font-weight: 700 !important;
}

/* ---- Stop animations / motion ---- */
html.acc-no-motion *,
html.acc-no-motion *::before,
html.acc-no-motion *::after {
  animation-duration: 0.001ms !important;
  animation-iteration-count: 1 !important;
  transition-duration: 0.001ms !important;
  scroll-behavior: auto !important;
}
html.acc-no-motion .reveal { opacity: 1 !important; transform: none !important; }

/* ---- Big cursor ---- */
html.acc-big-cursor,
html.acc-big-cursor * {
  cursor: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='48' height='48' viewBox='0 0 48 48'%3E%3Cpath d='M8 4l30 18-13 3 8 15-5 3-8-15-9 9z' fill='%23000' stroke='%23fff' stroke-width='2' stroke-linejoin='round'/%3E%3C/svg%3E") 6 4, auto !important;
}

/* ==========================================================================
   Keep the toolbar readable inside every mode
   ========================================================================== */
html.acc-grayscale .acc-fab { filter: none; }
.acc-fab, .acc-panel, .acc-panel * { text-shadow: none !important; }
