/*
 * Smart Accessibility – efectele aplicate paginii.
 * Toate regulile depind de o clasă `sa-*` pusă pe <html>, deci fără nicio
 * ajustare activă foaia aceasta nu schimbă nimic în sit.
 * Panoul widgetului stă într-un Shadow DOM și are stilurile lui, separat.
 */

@font-face { font-family: "SA OpenDyslexic"; font-weight: 400; font-display: swap; src: url("../fonts/opendyslexic-latin-400-normal.woff2") format("woff2"); }
@font-face { font-family: "SA OpenDyslexic"; font-weight: 700; font-display: swap; src: url("../fonts/opendyslexic-latin-700-normal.woff2") format("woff2"); }
@font-face { font-family: "SA Atkinson"; font-weight: 400; font-display: swap; src: url("../fonts/atkinson-hyperlegible-latin-400-normal.woff2") format("woff2"); unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }
@font-face { font-family: "SA Atkinson"; font-weight: 700; font-display: swap; src: url("../fonts/atkinson-hyperlegible-latin-700-normal.woff2") format("woff2"); unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }
@font-face { font-family: "SA Atkinson"; font-weight: 400; font-display: swap; src: url("../fonts/atkinson-hyperlegible-latin-ext-400-normal.woff2") format("woff2"); unicode-range: U+0100-02AF, U+1E00-1EFF, U+2020, U+20A0-20AB, U+20AD-20CF, U+2113, U+2C60-2C7F, U+A720-A7FF; }
@font-face { font-family: "SA Atkinson"; font-weight: 700; font-display: swap; src: url("../fonts/atkinson-hyperlegible-latin-ext-700-normal.woff2") format("woff2"); unicode-range: U+0100-02AF, U+1E00-1EFF, U+2020, U+20A0-20AB, U+20AD-20CF, U+2113, U+2C60-2C7F, U+A720-A7FF; }

/* ---------- Link „Salt la conținut” ---------- */
.sa-skip-link {
	position: fixed !important; top: -200px; left: 12px; z-index: 2147483646;
	padding: 12px 18px; border-radius: 8px;
	background: #111 !important; color: #fff !important;
	font: 600 16px/1.2 system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
	text-decoration: none !important; box-shadow: 0 4px 16px rgba(0, 0, 0, .35);
}
.sa-skip-link:focus { top: 12px; outline: 3px solid #ffbf47; outline-offset: 2px; }

/* ---------- Text și fonturi ---------- */
html.sa-ls-1 body * { letter-spacing: .06em !important; }
html.sa-ls-2 body * { letter-spacing: .12em !important; }
html.sa-ls-3 body * { letter-spacing: .18em !important; }

html.sa-ws-1 body * { word-spacing: .16em !important; }
html.sa-ws-2 body * { word-spacing: .32em !important; }
html.sa-ws-3 body * { word-spacing: .48em !important; }

html.sa-lh-1 body * { line-height: 1.5 !important; }
html.sa-lh-2 body * { line-height: 1.8 !important; }
html.sa-lh-3 body * { line-height: 2.1 !important; }

/* Fonturile de pictograme rămân neatinse, altfel pictogramele devin litere. */
html.sa-font-dys body *:not(:is(i, .fa, .fas, .far, .fab, .fal, .dashicons, .material-icons, .material-symbols-outlined, [class*="icon"], [class*="fa-"], svg, svg *)) {
	font-family: "SA OpenDyslexic", "Comic Sans MS", Verdana, sans-serif !important;
}
html.sa-font-read body *:not(:is(i, .fa, .fas, .far, .fab, .fal, .dashicons, .material-icons, .material-symbols-outlined, [class*="icon"], [class*="fa-"], svg, svg *)) {
	font-family: "SA Atkinson", Verdana, Tahoma, Arial, sans-serif !important;
}

html.sa-align-1 body * { text-align: left !important; }
html.sa-align-2 body * { text-align: center !important; }
html.sa-align-3 body * { text-align: right !important; }
html.sa-align-4 body * { text-align: justify !important; }

html.sa-titles body :is(h1, h2, h3, h4, h5, h6, [role="heading"]) {
	outline: 3px solid #0b5fff !important; outline-offset: 3px !important;
	background-color: #fff3b0 !important; color: #111 !important;
}
html.sa-titles body :is(h1, h2, h3, h4, h5, h6, [role="heading"]) * { color: #111 !important; background-color: transparent !important; }

html.sa-links body a[href] {
	outline: 2px solid #d9480f !important; outline-offset: 2px !important;
	text-decoration: underline !important; text-decoration-thickness: 2px !important;
}

/* ---------- Culori și contrast ---------- */
html.sa-filter { filter: var(--sa-filter) !important; }
html.sa-invert { background-color: #fff !important; }
html.sa-invert body :is(img, video, picture, canvas, iframe, embed, object, svg image) { filter: invert(1) hue-rotate(180deg) !important; }

html.sa-scheme-hc { background: #000 !important; }
html.sa-scheme-hc body,
html.sa-scheme-hc body *:not(:is(img, video, canvas, svg, svg *, iframe, picture, object, embed)) {
	background-color: #000 !important; background-image: none !important;
	color: #fff !important; border-color: #fff !important;
	box-shadow: none !important; text-shadow: none !important;
}
html.sa-scheme-hc body *::before, html.sa-scheme-hc body *::after { color: #fff !important; }
html.sa-scheme-hc body a[href], html.sa-scheme-hc body a[href] * { color: #ffea00 !important; text-decoration: underline !important; }
html.sa-scheme-hc body :is(button, input, select, textarea, [role="button"]) { border: 1px solid #fff !important; }
html.sa-scheme-hc body ::placeholder { color: #d0d0d0 !important; opacity: 1 !important; }

html.sa-scheme-dark { background: #121212 !important; }
html.sa-scheme-dark body,
html.sa-scheme-dark body *:not(:is(img, video, canvas, svg, svg *, iframe, picture, object, embed)) {
	background-color: #121212 !important; background-image: none !important;
	color: #e6e6e6 !important; border-color: #4a4a4a !important;
	box-shadow: none !important; text-shadow: none !important;
}
html.sa-scheme-dark body *::before, html.sa-scheme-dark body *::after { color: #e6e6e6 !important; }
html.sa-scheme-dark body a[href], html.sa-scheme-dark body a[href] * { color: #8ab4f8 !important; }
html.sa-scheme-dark body :is(button, input, select, textarea, [role="button"]) { border: 1px solid #777 !important; }
html.sa-scheme-dark body ::placeholder { color: #b5b5b5 !important; opacity: 1 !important; }

html.sa-scheme-light { background: #fff !important; }
html.sa-scheme-light body,
html.sa-scheme-light body *:not(:is(img, video, canvas, svg, svg *, iframe, picture, object, embed)) {
	background-color: #fff !important; background-image: none !important;
	color: #111 !important; border-color: #767676 !important;
	box-shadow: none !important; text-shadow: none !important;
}
html.sa-scheme-light body *::before, html.sa-scheme-light body *::after { color: #111 !important; }
html.sa-scheme-light body a[href], html.sa-scheme-light body a[href] * { color: #0645ad !important; }
html.sa-scheme-light body :is(button, input, select, textarea, [role="button"]) { border: 1px solid #555 !important; }
html.sa-scheme-light body ::placeholder { color: #555 !important; opacity: 1 !important; }

/* Culorile alese de vizitator vin după scheme, deci au ultimul cuvânt. */
html.sa-bg { background: var(--sa-bg) !important; }
html.sa-bg body,
html.sa-bg body *:not(:is(img, video, canvas, svg, svg *, iframe, picture, object, embed)) {
	background-color: var(--sa-bg) !important; background-image: none !important;
}
html.sa-tc body, html.sa-tc body *:not(:is(img, video, canvas, iframe)) { color: var(--sa-tc) !important; }
html.sa-tc body *::before, html.sa-tc body *::after { color: var(--sa-tc) !important; }
html.sa-lc body a[href], html.sa-lc body a[href] * { color: var(--sa-lc) !important; }

/* Forme desenate din elemente goale în butoane (de exemplu liniuțele meniului „hamburger”):
   cu fundalul forțat ar dispărea, așa că iau culoarea textului. */
html:is(.sa-scheme-hc, .sa-scheme-dark, .sa-scheme-light, .sa-bg) body :is(button, [role="button"], summary, a[aria-label], [class*="burger"], [class*="toggle"]) > :is(span, i, b, div):empty {
	background-color: currentColor !important;
}

/* ---------- Navigare și concentrare ---------- */
html.sa-cursor, html.sa-cursor * {
	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.5-6.6 1.6 4.1 7.2-3.2 1.7-4-7.3L4 19z' fill='%23000' stroke='%23fff' stroke-width='1.4' stroke-linejoin='round'/%3E%3C/svg%3E") 8 4, auto !important;
}
html.sa-cursor :is(a[href], button, [role="button"], [role="link"], [role="tab"], label, select, summary, input[type="submit"], input[type="button"], input[type="checkbox"], input[type="radio"]),
html.sa-cursor :is(a[href], button, [role="button"], [role="link"], [role="tab"], label, summary) * {
	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='M9 11V3.8a1.6 1.6 0 013.2 0V10l5.6 1.2a2.4 2.4 0 011.9 2.6l-.7 5.4A3.2 3.2 0 0115.8 22h-4.3a3.2 3.2 0 01-2.6-1.3L4.6 14.9a1.5 1.5 0 012.3-1.9z' fill='%23ffea00' stroke='%23000' stroke-width='1.4' stroke-linejoin='round'/%3E%3C/svg%3E") 21 4, pointer !important;
}

html.sa-focus body *:focus {
	outline: 4px solid #ff8a00 !important; outline-offset: 3px !important;
	box-shadow: 0 0 0 8px rgba(0, 0, 0, .8) !important;
}

html.sa-interactive body :is(a[href], button, [role="button"], [role="link"], [role="tab"], input:not([type="hidden"]), select, textarea, summary, [tabindex]:not([tabindex="-1"])) {
	outline: 2px dashed #7b2ff7 !important; outline-offset: 2px !important;
}

html.sa-stop, html.sa-stop * , html.sa-stop *::before, html.sa-stop *::after {
	animation-duration: .001s !important; animation-delay: 0s !important; animation-iteration-count: 1 !important;
	transition-duration: .001s !important; transition-delay: 0s !important;
	scroll-behavior: auto !important;
}

html.sa-noimg body img:is([alt=""], :not([alt]), [role="presentation"], [role="none"], [aria-hidden="true"]),
html.sa-noimg body [aria-hidden="true"] img { visibility: hidden !important; }
