/* Carasso accessibility layer (Plan 2, E21-E23): toolbar, focus rings, reduced motion, contrast fixes, display modes. */

/* ---------- Trigger ---------- */
.cr-a11y-trigger {
	display: inline-flex; align-items: center; gap: 8px;
	min-height: 44px; min-width: 44px; padding: 0 16px;
	border: 1.5px solid var(--c-navy); border-radius: 999px;
	background: transparent; color: var(--c-navy);
	font: inherit; font-size: 15px; font-weight: 700; line-height: 1; cursor: pointer; white-space: nowrap;
}
.cr-a11y-trigger:hover, .cr-a11y-trigger:focus-visible, .cr-a11y-trigger[aria-expanded="true"] { background: var(--c-cyan-tint); color: var(--c-navy); }
.cr-a11y-icon { flex: 0 0 auto; }
/* The header slot is a shortcode widget; keep it compact (the nav widget gets flex: 1). */
.elementor-location-header .elementor-widget-shortcode:has(.cr-a11y-trigger--header) { flex: 0 0 auto; width: auto; max-width: none; }
.cr-nav__panel .cr-a11y-trigger--panel {
	display: none; justify-content: flex-start; width: 100%; margin-top: 8px; padding: 14px 16px;
	border-radius: 14px; font-size: 20px; font-weight: 600; min-height: 52px;
}
@media (max-width: 1080px) {
	.elementor-location-header .elementor-widget-shortcode:has(.cr-a11y-trigger--header) { display: none; }
	.cr-nav__panel .cr-a11y-trigger--panel { display: flex; }
}

/* ---------- Panel (dialog) ---------- */
.cr-a11y-panel {
	position: fixed; z-index: 100001; top: 84px; left: max(16px, calc((100vw - 1280px) / 2 + 16px));
	width: min(380px, calc(100vw - 32px)); max-height: calc(100vh - 100px); overflow-y: auto;
	background: #fff; color: var(--c-navy);
	border: 1.5px solid var(--c-navy); border-radius: 18px;
	box-shadow: 0 24px 48px rgba(26, 25, 75, .22);
	padding: 18px 18px 14px; font-size: 16px; line-height: 1.4;
}
.cr-a11y-panel[hidden] { display: none; }
.cr-a11y-panel__head { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 12px; }
.cr-a11y-panel__title { margin: 0; font-size: 20px; font-weight: 800; color: var(--c-navy); }
.cr-a11y-close {
	width: 44px; height: 44px; border-radius: 50%; border: 1.5px solid var(--c-navy); background: transparent; color: var(--c-navy);
	font-size: 26px; line-height: 1; cursor: pointer; display: inline-flex; align-items: center; justify-content: center; padding: 0;
}
.cr-a11y-close:hover, .cr-a11y-close:focus-visible { background: var(--c-cyan-tint); color: var(--c-navy); }
.cr-a11y-group { margin: 0 0 12px; }
.cr-a11y-group__label { margin: 0 0 6px; font-weight: 700; font-size: 15px; color: var(--c-navy); }
.cr-a11y-size { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; }
.cr-a11y-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; margin-bottom: 8px; }
.cr-a11y-panel .cr-a11y-btn {
	display: flex; align-items: center; gap: 8px; min-height: 48px; padding: 8px 12px; width: 100%;
	border: 1.5px solid var(--c-border); border-radius: 12px; background: var(--c-paper); color: var(--c-navy);
	font: inherit; font-size: 15px; font-weight: 600; text-align: start; cursor: pointer;
}
.cr-a11y-panel .cr-a11y-btn:hover { border-color: var(--c-navy); background: #fff; color: var(--c-navy); }
.cr-a11y-panel .cr-a11y-btn[aria-pressed="true"] { border-color: var(--c-navy); background: var(--c-navy); color: #fff; }
.cr-a11y-btn--size { justify-content: center; flex-direction: column; gap: 0; }
.cr-a11y-size__a { font-weight: 800; line-height: 1.1; }
.cr-a11y-size__a--0 { font-size: 16px; } .cr-a11y-size__a--1 { font-size: 20px; } .cr-a11y-size__a--2 { font-size: 24px; }
.cr-a11y-size__pct { font-size: 13px; }
.cr-a11y-btn__box { flex: 0 0 auto; width: 18px; height: 18px; border: 2px solid currentColor; border-radius: 5px; position: relative; }
.cr-a11y-btn[aria-pressed="true"] .cr-a11y-btn__box::after {
	content: ""; position: absolute; inset: 2px 4px 5px; border: solid currentColor; border-width: 0 2.5px 2.5px 0; transform: rotate(45deg);
}
.cr-a11y-panel .cr-a11y-btn--reset { justify-content: center; background: transparent; border-style: dashed; }
.cr-a11y-links { display: flex; flex-wrap: wrap; gap: 4px 18px; margin: 12px 0 0; font-size: 15px; }
.cr-a11y-links a { color: var(--c-cyan-text); text-decoration: underline; text-underline-offset: 3px; display: inline-flex; align-items: center; min-height: 44px; }
.cr-a11y-status { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(1px, 1px, 1px, 1px); white-space: nowrap; margin: 0; }
@media (max-width: 640px) {
	.cr-a11y-panel { top: auto; bottom: 0; left: 0; right: 0; width: auto; max-height: 85vh; border-radius: 18px 18px 0 0; border-bottom: 0; }
}

/* ---------- Landmark + skip link target ---------- */
#content.cr-main { display: block; outline: 0; scroll-margin-top: 90px; }

/* ---------- Focus rings (E22) ---------- */
a:focus-visible, button:focus-visible, input:focus-visible, select:focus-visible, textarea:focus-visible,
summary:focus-visible, [role="button"]:focus-visible, [tabindex]:not([tabindex="-1"]):focus-visible,
.cr-chip:focus-visible, [class*="chip"]:focus-visible {
	outline: 3px solid var(--c-cyan-deep) !important; outline-offset: 2px !important; box-shadow: 0 0 0 5px #fff;
}
.elementor-location-footer a:focus-visible, .elementor-location-footer button:focus-visible { outline-color: var(--c-cyan-on-dark) !important; box-shadow: none; }

/* ---------- Reduced motion (OS setting) and "stop motion" (toolbar) ---------- */
@media (prefers-reduced-motion: reduce) {
	*, *::before, *::after { animation-duration: .01ms !important; animation-iteration-count: 1 !important; transition-duration: .01ms !important; scroll-behavior: auto !important; }
}
html.a11y-motion { scroll-behavior: auto !important; }
html.a11y-motion *, html.a11y-motion *::before, html.a11y-motion *::after {
	animation: none !important; transition: none !important; scroll-behavior: auto !important;
}

/* ---------- Contrast fixes (E23) ---------- */
/* Topic tile numerals: navy on paper inside a ring of the topic colour. */
.cr-topic-tile__n { background: var(--c-paper) !important; box-shadow: inset 0 0 0 3px var(--dot); color: var(--c-navy) !important; }
/* Disabled press prev/next cards: readable grey instead of 50% opacity. */
.cr-press-nav__card.is-disabled { opacity: 1; }
.cr-press-nav__card.is-disabled .cr-press-nav__label, .cr-press-nav__card.is-disabled .cr-press-nav__title { color: #6B7287; }

/* Small white text on cyan surfaces: use cyan-deep (#0077B0, 4.9:1). Home hero badge "הקליניקה" and the clinic hero badge. */
html:not(.a11y-dark):not(.a11y-contrast) :is(.elementor-4581 .e-10401818-1e6f, .elementor-5897 .e-8df501d-faf0,
.elementor [data-interaction-id="e7a7173"], .elementor [data-interaction-id="69ebc67d"]) { background-color: var(--c-cyan-deep) !important; }

/* ---------- Text size (zoom: atomic styles are in px) ---------- */
html.a11y-size-1 { zoom: 1.15; }
html.a11y-size-2 { zoom: 1.3; }
/* Turnstile renders a fixed 300px iframe: undo the zoom so it fits a 390px phone. */
html.a11y-size-1 .cf-turnstile { zoom: .87; }
html.a11y-size-2 .cf-turnstile { zoom: .77; }
/* The toolbar panel keeps its own (already large) size at every step so it always fits a phone. */
html.a11y-size-1 .cr-a11y-panel { zoom: .87; }
html.a11y-size-2 .cr-a11y-panel { zoom: .77; }

/* ---------- Highlight links ---------- */
html.a11y-links a { text-decoration: underline !important; text-underline-offset: 3px; text-decoration-thickness: 2px !important; outline: 2px dashed currentColor; outline-offset: 2px; }

/* ---------- Readable font ---------- */
html.a11y-font body, html.a11y-font body *:not(svg):not(svg *) {
	font-family: system-ui, -apple-system, "Segoe UI", Arial, sans-serif !important; letter-spacing: .02em !important; word-spacing: .08em !important;
}

/* ---------- Larger cursor ---------- */
html.a11y-cursor, html.a11y-cursor * {
	cursor: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='40' height='40' viewBox='0 0 40 40'%3E%3Cpath d='M4 3l26 13-11 3-5 11z' fill='%23000' stroke='%23fff' stroke-width='2.5' stroke-linejoin='round'/%3E%3C/svg%3E") 4 3, auto !important;
}
html.a11y-cursor a, html.a11y-cursor a *, html.a11y-cursor button, html.a11y-cursor button *, html.a11y-cursor [role="button"], html.a11y-cursor label, html.a11y-cursor summary {
	cursor: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='40' height='40' viewBox='0 0 40 40'%3E%3Cpath d='M4 3l26 13-11 3-5 11z' fill='%230077B0' stroke='%23fff' stroke-width='2.5' stroke-linejoin='round'/%3E%3C/svg%3E") 4 3, pointer !important;
}

/* ---------- High contrast: navy text on white, strong borders ---------- */
html.a11y-contrast body { background: #fff !important; }
html.a11y-contrast body *:not(svg):not(svg *):not(img):not(video):not(iframe):not(picture) {
	background-color: #fff !important; background-image: none !important; color: #12123A !important;
	text-shadow: none !important; box-shadow: none !important; backdrop-filter: none !important;
}
html.a11y-contrast body :is([class$="card"], [class*="card "], [class$="tile"], [class*="tile "]), html.a11y-contrast body :is([class$="chip"], [class*="chip "]),
html.a11y-contrast body button, html.a11y-contrast body input, html.a11y-contrast body select, html.a11y-contrast body textarea,
html.a11y-contrast body .e-con[class*="box"], html.a11y-contrast .cr-a11y-panel {
	border: 2px solid #12123A !important;
}
html.a11y-contrast body a, html.a11y-contrast body a * { color: #0B3D91 !important; text-decoration: underline !important; }
html.a11y-contrast body button[aria-pressed="true"], html.a11y-contrast body button[aria-pressed="true"] *,
html.a11y-contrast body .cr-nav__cta, html.a11y-contrast body .cr-nav__cta * { background-color: #12123A !important; color: #fff !important; }
html.a11y-contrast .elementor-location-footer, html.a11y-contrast .elementor-location-footer * { border-color: #12123A !important; }
html.a11y-contrast .elementor-location-header { border-bottom: 2px solid #12123A !important; }
html.a11y-contrast img { filter: none !important; }

/* ---------- Dark mode: light text on navy-deep ---------- */
html.a11y-dark body { background: #1A194B !important; color: #F2F3FA !important; }
html.a11y-dark body *:not(svg):not(svg *):not(img):not(video):not(iframe):not(picture) {
	background-color: #1A194B !important; background-image: none !important; color: #F2F3FA !important;
	border-color: #6A6C9C !important; text-shadow: none !important; box-shadow: none !important; backdrop-filter: none !important;
}
html.a11y-dark body :is([class$="card"], [class*="card "], [class$="tile"], [class*="tile "]), html.a11y-dark body button,
html.a11y-dark body input, html.a11y-dark body select, html.a11y-dark body textarea, html.a11y-dark .cr-a11y-panel {
	background-color: #24255E !important; border: 1.5px solid #8A8CC0 !important;
}
html.a11y-dark body a, html.a11y-dark body a *:not(svg) { color: #9EDCFB !important; }
html.a11y-dark body button[aria-pressed="true"], html.a11y-dark body button[aria-pressed="true"] *,
html.a11y-dark body .cr-nav__cta, html.a11y-dark body .cr-nav__cta * { background-color: #9EDCFB !important; color: #1A194B !important; }
html.a11y-dark body input::placeholder, html.a11y-dark body textarea::placeholder { color: #C5C7E0 !important; }
html.a11y-dark .cr-nav__burger span { background: #F2F3FA !important; }
html.a11y-contrast .cr-nav__burger span { background: #12123A !important; }
/* Logos are dark-on-light PNGs: give them a light plate in dark mode. */
html.a11y-dark .elementor-location-header img, html.a11y-dark .elementor-location-footer img { background: #FCFAF6 !important; border-radius: 10px; padding: 4px; }
