/* ===== Accessibility widget (תפריט נגישות) ===== */
/* כפתור צף עם אייקון כיסא גלגלים + פאנל כלי נגישות */

.a11y-btn {
  position: fixed; bottom: 22px; right: 22px; z-index: 1000;
  width: 56px; height: 56px; border-radius: 50%;
  background: #2a5db0; color: #fff; border: 3px solid #fff;
  display: flex; align-items: center; justify-content: center;
  box-shadow: 0 6px 20px rgba(0,0,0,0.25); cursor: pointer;
  transition: transform .2s, box-shadow .2s;
}
.a11y-btn:hover { transform: translateY(-2px); box-shadow: 0 10px 26px rgba(0,0,0,0.3); }
.a11y-btn svg { width: 30px; height: 30px; }

.a11y-panel {
  position: fixed; bottom: 88px; right: 22px; z-index: 1000;
  width: 290px; max-width: calc(100vw - 44px);
  background: #fff; color: #222; border-radius: 16px;
  box-shadow: 0 16px 48px rgba(0,0,0,0.22);
  padding: 18px; display: none;
  font-family: 'Assistant', system-ui, sans-serif;
}
.a11y-panel.open { display: block; }
.a11y-panel h2 { font-size: 1.15rem; margin: 0 0 4px; color: #1a1a1a; }
.a11y-panel .a11y-sub { font-size: 0.82rem; color: #555; margin-bottom: 14px; }

.a11y-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.a11y-opt {
  display: flex; flex-direction: column; align-items: center; gap: 5px;
  background: #f3f4f6; border: 2px solid transparent; border-radius: 10px;
  padding: 12px 6px; font-size: 0.82rem; font-weight: 600; color: #222;
  cursor: pointer; text-align: center; transition: background .15s, border-color .15s;
}
.a11y-opt:hover { background: #e8eaed; }
.a11y-opt[aria-pressed="true"] { background: #e6f0ff; border-color: #2a5db0; color: #1a4894; }
.a11y-opt .a11y-ic { font-size: 1.25rem; line-height: 1; }

.a11y-reset {
  width: 100%; margin-top: 10px; padding: 10px; border-radius: 10px;
  background: #fbeaea; color: #a12; border: none; font-weight: 700;
  cursor: pointer; font-size: 0.9rem;
}
.a11y-reset:hover { background: #f6dada; }
.a11y-statement-link {
  display: block; text-align: center; margin-top: 12px;
  font-size: 0.85rem; color: #2a5db0; font-weight: 600;
}
.a11y-close {
  position: absolute; top: 10px; left: 12px; background: none; border: none;
  font-size: 1.3rem; line-height: 1; color: #888; cursor: pointer;
}
.a11y-close:hover { color: #222; }

.a11y-btn:focus-visible, .a11y-opt:focus-visible,
.a11y-reset:focus-visible, .a11y-close:focus-visible,
.a11y-statement-link:focus-visible {
  outline: 3px solid #ffbf00; outline-offset: 2px;
}

/* ===== מצבי נגישות שמופעלים על <html> ===== */

/* הגדלת טקסט (3 רמות) — באמצעות zoom לתאימות רחבה */
html.a11y-text-1 body { zoom: 1.15; }
html.a11y-text-2 body { zoom: 1.3; }

/* ניגודיות גבוהה */
html.a11y-contrast body { background: #ffffff !important; }
html.a11y-contrast,
html.a11y-contrast p,
html.a11y-contrast li,
html.a11y-contrast span,
html.a11y-contrast h1,
html.a11y-contrast h2,
html.a11y-contrast h3 { color: #111 !important; }
html.a11y-contrast .hero,
html.a11y-contrast .about,
html.a11y-contrast .card,
html.a11y-contrast .quote { background: #fff !important; }
html.a11y-contrast .card,
html.a11y-contrast .quote { border: 2px solid #111 !important; }
html.a11y-contrast a { color: #0040a0 !important; }

/* הדגשת קישורים */
html.a11y-links a { text-decoration: underline !important; text-underline-offset: 3px; }

/* עצירת אנימציות */
html.a11y-noanim *, html.a11y-noanim *::before, html.a11y-noanim *::after {
  animation: none !important; transition: none !important; scroll-behavior: auto !important;
}
