:root{--w-accent:#0b57d0;--w-ink:#111;--w-focus:#ffbf00}
.a11y-w{position:fixed;left:16px;bottom:16px;z-index:2147483000;font:16px/1.4 system-ui,-apple-system,"Segoe UI",Roboto,sans-serif}
.a11y-w *{box-sizing:border-box}
.a11y-w__toggle{width:48px;height:48px;padding:0;border-radius:50%;border:2px solid #fff;background:var(--w-accent);color:#fff;cursor:pointer;display:grid;place-items:center;box-shadow:0 2px 10px rgba(0,0,0,.45)}
.a11y-w__toggle svg{width:28px;height:28px;fill:currentColor;pointer-events:none}
.a11y-w__panel{position:absolute;left:0;bottom:60px;width:min(340px,calc(100vw - 32px));max-height:calc(100vh - 100px);overflow:auto;background:#fff;color:var(--w-ink);border:2px solid var(--w-ink);border-radius:12px;padding:14px;box-shadow:0 8px 30px rgba(0,0,0,.35)}
.a11y-w__panel[hidden]{display:none}
.a11y-w__head{display:flex;align-items:center;justify-content:space-between;margin:0 0 10px}
.a11y-w__title{margin:0;font-size:1.125rem;font-weight:700}
.a11y-w__close{min-width:44px;min-height:44px;border:2px solid var(--w-ink);background:#fff;color:var(--w-ink);border-radius:8px;cursor:pointer;font:inherit}
.a11y-w__row{display:flex;gap:8px;align-items:center;margin:0 0 8px}
.a11y-w__label{flex:1;font-weight:600}
.a11y-w__btn{min-height:44px;padding:8px 12px;border:2px solid var(--w-ink);background:#fff;color:var(--w-ink);border-radius:8px;cursor:pointer;font:inherit;text-align:left}
.a11y-w__btn[aria-pressed="true"]{background:var(--w-accent);color:#fff;border-color:var(--w-accent)}
.a11y-w__btn[aria-disabled="true"]{opacity:.45;cursor:not-allowed}
.a11y-w__grid{display:grid;grid-template-columns:1fr 1fr;gap:8px;margin:0 0 8px}
.a11y-w__btn--full{width:100%;text-align:center}
.a11y-w button:focus-visible{outline:3px solid #ffbf00;outline-offset:2px}

/* Rozmiar tekstu (wymaga typografii w rem) */
html.a11y-size-1 body{zoom:1.125}
html.a11y-size-2 body{zoom:1.25}
html.a11y-size-3 body{zoom:1.5}
/* Wariant dla stron px-owych (np. Divi): zamiast powyższego użyj
   html.a11y-size-1 body{zoom:1.125} ...-2 {zoom:1.25} ...-3 {zoom:1.5} i przetestuj layout. */

/* Wysoki kontrast */
html.a11y-contrast,html.a11y-contrast body{background:#000!important;color:#fff!important}
html.a11y-contrast body *:not(img):not(svg):not(svg *):not(video):not(canvas):not(picture):not(iframe){background-color:#000!important;background-image:none!important;color:#fff!important;border-color:#fff!important;text-shadow:none!important;box-shadow:none!important}
html.a11y-contrast a,html.a11y-contrast a *{color:#ff0!important;text-decoration:underline!important}
html.a11y-contrast button,html.a11y-contrast input,html.a11y-contrast select,html.a11y-contrast textarea{border:2px solid #fff!important}
html.a11y-contrast :focus-visible{outline:3px solid #0ff!important;outline-offset:2px!important}
html.a11y-contrast .a11y-w__btn[aria-pressed="true"]{background:#ff0!important;color:#000!important}

/* Podkreślone linki */
html.a11y-links a{text-decoration:underline!important;text-underline-offset:.2em;text-decoration-thickness:2px!important}

/* Odstępy tekstu (1.4.12) */
html.a11y-spacing body *{line-height:1.5!important;letter-spacing:.12em!important;word-spacing:.16em!important}
html.a11y-spacing p{margin-bottom:2em!important}

/* Czytelna czcionka (nie rusza ikon) */
html.a11y-font body *:not(i):not([class*="icon"]):not([class*="fa-"]):not([class*="dashicons"]){font-family:Verdana,Tahoma,"Atkinson Hyperlegible",sans-serif!important}

/* Bez animacji */
html.a11y-motion *,html.a11y-motion *::before,html.a11y-motion *::after{animation:none!important;transition:none!important;scroll-behavior:auto!important}
