/* Dostępność cyfrowa – przycisk, panel ułatwień i tryby wyświetlania. */

.dc-sr { position: absolute !important; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; border: 0; }

/* ------------------------------------------------------------------ przycisk */

.dc-przycisk {
    --dc-kolor: #14213d; --dc-kolor-ikony: #fff; --dc-rozmiar: 56px;
    position: fixed; z-index: 9990; width: var(--dc-rozmiar); height: var(--dc-rozmiar); border-radius: 50%;
    display: grid; place-items: center; padding: 0; cursor: pointer;
    background: var(--dc-kolor); color: var(--dc-kolor-ikony); border: 3px solid #fff;
    box-shadow: 0 6px 20px rgba(0, 0, 0, .28); transition: transform .18s ease, box-shadow .18s ease;
}
.dc-przycisk:hover { transform: scale(1.06); box-shadow: 0 10px 26px rgba(0, 0, 0, .34); }
.dc-przycisk:focus-visible { outline: 4px solid #ffbf47; outline-offset: 3px; }
.dc-przycisk--lewo-dol { left: 18px; bottom: 18px; }
.dc-przycisk--prawo-dol { right: 18px; bottom: 18px; }
.dc-przycisk--lewo-srodek { left: 12px; top: 50%; transform: translateY(-50%); }
.dc-przycisk--prawo-srodek { right: 12px; top: 50%; transform: translateY(-50%); }
.dc-przycisk--lewo-srodek:hover, .dc-przycisk--prawo-srodek:hover { transform: translateY(-50%) scale(1.06); }
.dc-przycisk--aktywny::after {
    content: ''; position: absolute; top: -2px; right: -2px; width: 14px; height: 14px; border-radius: 50%;
    background: #2e9e5b; border: 2px solid #fff;
}
.dc-przycisk svg { width: 60%; height: 60%; }

/* --------------------------------------------------------------------- panel */

.dc-panel {
    position: fixed; z-index: 9991; bottom: 88px; width: min(390px, calc(100vw - 24px)); max-height: calc(100vh - 110px);
    display: flex; flex-direction: column; background: #fff; color: #1c2331; border-radius: 14px;
    box-shadow: 0 24px 60px rgba(10, 16, 30, .35); border: 1px solid #d9dde5; overflow: hidden;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Arial, sans-serif; font-size: 16px; line-height: 1.4;
}
.dc-panel[hidden] { display: none; }
.dc-panel--lewo { left: 18px; }
.dc-panel--prawo { right: 18px; }
.dc-panel__gora { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 14px 16px; background: #14213d; color: #fff; }
.dc-panel__tytul { display: flex; align-items: center; gap: 10px; margin: 0; font-size: 1.1rem; color: #fff !important; font-family: inherit; }
.dc-zamknij { width: 40px; height: 40px; border-radius: 50%; border: 1px solid rgba(255, 255, 255, .4); background: transparent; color: #fff; font-size: 1.6rem; line-height: 1; cursor: pointer; }
.dc-zamknij:hover { background: rgba(255, 255, 255, .12); }
.dc-panel__tresc { padding: 14px 16px 16px; overflow-y: auto; }
.dc-panel :focus-visible { outline: 3px solid #a4161a; outline-offset: 2px; }

.dc-grupa { margin-bottom: 14px; }
.dc-grupa__tytul { margin: 0 0 8px; font-weight: 700; font-size: .95rem; }
.dc-rozmiar { display: grid; grid-template-columns: 1fr 1.4fr 1fr; gap: 8px; }
.dc-rozmiar button, .dc-kontrast {
    min-height: 44px; border: 2px solid #c9ced8; border-radius: 10px; background: #f6f7f9; color: #1c2331;
    font: inherit; font-weight: 700; cursor: pointer;
}
.dc-rozmiar button:hover:not(:disabled), .dc-kontrast:hover { border-color: #14213d; }
.dc-rozmiar button:disabled { opacity: .45; cursor: not-allowed; }
.dc-kontrasty { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; }
.dc-kontrast { font-size: .88rem; padding: 6px; }
.dc-kontrast--zolty { background: #000; color: #ff0; border-color: #000; }
.dc-kontrast--ciemny { background: #000; color: #fff; border-color: #000; }
.dc-kontrast--jasny { background: #fff; color: #000; border-color: #000; }
.dc-kontrast[aria-pressed="true"], .dc-rozmiar button[aria-pressed="true"] { box-shadow: 0 0 0 3px #a4161a; }

.dc-opcje { list-style: none; margin: 0; padding: 0; display: grid; gap: 6px; }
.dc-opcja {
    width: 100%; display: grid; grid-template-columns: 36px 1fr 44px; gap: 10px; align-items: center; text-align: left;
    padding: 9px 10px; border: 2px solid #e1e4ea; border-radius: 10px; background: #fff; color: #1c2331; font: inherit; cursor: pointer;
}
.dc-opcja:hover { border-color: #14213d; background: #f7f8fb; }
.dc-opcja__ikona { display: grid; place-items: center; width: 36px; height: 36px; border-radius: 8px; background: #eef1f6; color: #14213d; }
.dc-opcja__tekst strong { display: block; font-size: .95rem; }
.dc-opcja__tekst span { display: block; font-size: .8rem; color: #4d5566; }
.dc-opcja__stan { position: relative; width: 40px; height: 22px; border-radius: 11px; background: #c3c8d2; transition: background .15s; }
.dc-opcja__stan::after { content: ''; position: absolute; top: 3px; left: 3px; width: 16px; height: 16px; border-radius: 50%; background: #fff; transition: transform .15s; }
.dc-opcja[aria-pressed="true"] { border-color: #14213d; background: #f1f4fa; }
.dc-opcja[aria-pressed="true"] .dc-opcja__stan { background: #1d7a46; }
.dc-opcja[aria-pressed="true"] .dc-opcja__stan::after { transform: translateX(18px); }
.dc-opcja[aria-pressed="true"] .dc-opcja__ikona { background: #14213d; color: #fff; }

.dc-panel__dol { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: 10px; margin-top: 14px; padding-top: 12px; border-top: 1px solid #e1e4ea; }
.dc-reset { border: 0; background: none; color: #a4161a; font: inherit; font-weight: 700; text-decoration: underline; cursor: pointer; padding: 6px 0; min-height: 44px; }
.dc-link { color: #14213d; font-weight: 600; }

.dc-linijka {
    position: fixed; left: 0; right: 0; top: 0; height: 40px; z-index: 9989; pointer-events: none;
    background: rgba(255, 221, 87, .22); border-top: 3px solid #14213d; border-bottom: 3px solid #14213d;
}
.dc-linijka[hidden] { display: none; }

@media (max-width: 560px) {
    .dc-panel { left: 8px !important; right: 8px; width: auto; bottom: 80px; max-height: calc(100vh - 96px); }
    .dc--bez-telefonu .dc-przycisk { display: none; }
}
@media print { .dc { display: none !important; } }

/* ================================================================ TRYBY */

/* Rozmiar tekstu */
html.dc-tekst-115 { font-size: 115%; }
html.dc-tekst-130 { font-size: 130%; }
html.dc-tekst-150 { font-size: 150%; }
html.dc-tekst-175 { font-size: 175%; }
html.dc-tekst-200 { font-size: 200%; }
html.dc-tekst-115 body { font-size: calc(var(--rozmiar-bazowy, 17px) * 1.15); }
html.dc-tekst-130 body { font-size: calc(var(--rozmiar-bazowy, 17px) * 1.3); }
html.dc-tekst-150 body { font-size: calc(var(--rozmiar-bazowy, 17px) * 1.5); }
html.dc-tekst-175 body { font-size: calc(var(--rozmiar-bazowy, 17px) * 1.75); }
html.dc-tekst-200 body { font-size: calc(var(--rozmiar-bazowy, 17px) * 2); }
html[class*="dc-tekst-"] body { overflow-wrap: break-word; }
html[class*="dc-tekst-"] .dc-panel { font-size: 16px; }

/* Odstępy w tekście (WCAG 1.4.12) */
html.dc-odstepy body *:not(.dc-panel *):not(svg *) { line-height: 1.9 !important; letter-spacing: .12em !important; word-spacing: .16em !important; }
html.dc-odstepy body p { margin-bottom: 2em !important; }

/* Kontrasty */
html.dc-kontrast-zolty body, html.dc-kontrast-zolty body *:not(svg *):not(img),
html.dc-kontrast-ciemny body, html.dc-kontrast-ciemny body *:not(svg *):not(img),
html.dc-kontrast-jasny body, html.dc-kontrast-jasny body *:not(svg *):not(img) {
    background-image: none !important; box-shadow: none !important; text-shadow: none !important;
}
html.dc-kontrast-zolty body, html.dc-kontrast-zolty body *:not(svg *):not(img) { background-color: #000 !important; color: #ff0 !important; border-color: #ff0 !important; }
html.dc-kontrast-ciemny body, html.dc-kontrast-ciemny body *:not(svg *):not(img) { background-color: #000 !important; color: #fff !important; border-color: #fff !important; }
html.dc-kontrast-jasny body, html.dc-kontrast-jasny body *:not(svg *):not(img) { background-color: #fff !important; color: #000 !important; border-color: #000 !important; }
html.dc-kontrast-zolty a, html.dc-kontrast-ciemny a { text-decoration: underline !important; }
html.dc-kontrast-zolty a *, html.dc-kontrast-zolty a { color: #ff0 !important; }
html.dc-kontrast-ciemny a *, html.dc-kontrast-ciemny a { color: #0ff !important; }
html.dc-kontrast-jasny a *, html.dc-kontrast-jasny a { color: #00e !important; text-decoration: underline !important; }
html[class*="dc-kontrast-"] *::before, html[class*="dc-kontrast-"] *::after { background-image: none !important; }
html[class*="dc-kontrast-"] :focus-visible { outline: 4px solid currentColor !important; outline-offset: 3px !important; }
html[class*="dc-kontrast-"] .dc-opcja__stan { background: transparent !important; border: 2px solid currentColor !important; }
html[class*="dc-kontrast-"] .dc-opcja[aria-pressed="true"] .dc-opcja__stan::after { background: currentColor !important; }
html[class*="dc-kontrast-"] .dc-opcja[aria-pressed="true"] { outline: 3px solid currentColor; }

/* Odcienie szarości */
html.dc-szarosc { filter: grayscale(1); }

/* Podkreślone odnośniki */
html.dc-linki body a:not(.dc-panel a), html.dc-linki body button:not(.dc *) {
    text-decoration: underline !important; text-decoration-thickness: 2px !important; text-underline-offset: 3px !important;
    outline: 2px dashed currentColor !important; outline-offset: 2px !important;
}
html.dc-linki body a:not(.dc-panel a):not([class*="dc-kontrast"]) { background-color: #fff3a8 !important; color: #000 !important; }

/* Nagłówki */
html.dc-naglowki body :is(h1, h2, h3, h4, h5, h6):not(.dc *) { outline: 2px dashed #a4161a !important; outline-offset: 4px; position: relative; }
html.dc-naglowki body :is(h1, h2, h3, h4, h5, h6):not(.dc *)::before {
    display: inline-block; margin-right: 8px; padding: 1px 6px; font: 700 12px/1.4 Arial, sans-serif !important;
    background: #a4161a; color: #fff; border-radius: 3px; vertical-align: middle; letter-spacing: 0 !important;
}
html.dc-naglowki body h1:not(.dc *)::before { content: 'H1'; }
html.dc-naglowki body h2:not(.dc *)::before { content: 'H2'; }
html.dc-naglowki body h3:not(.dc *)::before { content: 'H3'; }
html.dc-naglowki body h4:not(.dc *)::before { content: 'H4'; }
html.dc-naglowki body h5:not(.dc *)::before { content: 'H5'; }
html.dc-naglowki body h6:not(.dc *)::before { content: 'H6'; }

/* Czytelna czcionka */
html.dc-czcionka body, html.dc-czcionka body *:not(svg *) { font-family: Verdana, Tahoma, Arial, sans-serif !important; font-style: normal !important; }

/* Duży kursor */
html.dc-kursor, html.dc-kursor * {
    cursor: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='48' height='48' viewBox='0 0 24 24'%3E%3Cpath d='M4 2l15 9-6.5 1.6L9.6 19z' fill='%23000' stroke='%23fff' stroke-width='1.4'/%3E%3C/svg%3E") 4 2, auto !important;
}
html.dc-kursor a, html.dc-kursor button, html.dc-kursor a *, html.dc-kursor button * {
    cursor: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='48' height='48' viewBox='0 0 24 24'%3E%3Cpath d='M4 2l15 9-6.5 1.6L9.6 19z' fill='%23a4161a' stroke='%23fff' stroke-width='1.4'/%3E%3C/svg%3E") 4 2, pointer !important;
}

/* Wyraźny fokus */
html.dc-fokus :focus, html.dc-fokus :focus-visible { outline: 4px solid #ffbf47 !important; outline-offset: 2px !important; box-shadow: 0 0 0 8px #000 !important; }

/* Zatrzymane animacje */
html.dc-bez-animacji *, html.dc-bez-animacji *::before, html.dc-bez-animacji *::after {
    animation-duration: .001ms !important; animation-iteration-count: 1 !important; transition-duration: .001ms !important; scroll-behavior: auto !important;
}

/* Ukryte obrazy */
html.dc-obrazy body img:not(.dc *), html.dc-obrazy body picture, html.dc-obrazy body video { visibility: hidden !important; }
html.dc-obrazy body [style*="background-image"] { background-image: none !important; }

/* Tekst do lewej */
html.dc-wyrownanie body *:not(.dc *) { text-align: left !important; }
html[class*="dc-kontrast-"] .dc-kontrast[aria-pressed="true"],
html[class*="dc-kontrast-"] .dc-rozmiar button[aria-pressed="true"] { outline: 4px solid currentColor !important; outline-offset: 2px; text-decoration: underline !important; }
html[class*="dc-kontrast-"].dc-naglowki body :is(h1, h2, h3, h4, h5, h6):not(.dc *) { outline-color: currentColor !important; }
