/* ClickMonster Accessibility widget */

/* ---------- Widget (isolated from theme styles) ---------- */
#cma-root {
	--cma-brand: #0b4f8a;
	--cma-lead: #0b4f8a;
	--cma-size: 56px; --cma-r: 50%; --cma-ox: 20px; --cma-oy: 20px;
	--cma-msize: 44px; --cma-mr: 50%; --cma-mox: 12px; --cma-moy: 12px;
	--cma-ring: #ffbf47;
	position: static;
	font-size: 16px;
	line-height: 1.5;
	color: #1a1a1a;
}
#cma-root, #cma-root * {
	box-sizing: border-box;
	font-family: system-ui, -apple-system, "Segoe UI", Roboto, Arial, sans-serif !important;
	letter-spacing: normal !important;
	word-spacing: normal !important;
	text-transform: none;
	text-shadow: none;
	float: none;
}
#cma-root [hidden] { display: none !important; }
#cma-root .cma-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;
}

/* Corner button */
#cma-root .cma-toggle {
	display: flex; align-items: center; justify-content: center;
	position: fixed; z-index: 2147483000;
	width: var(--cma-size); height: var(--cma-size); min-width: 0; margin: 0; padding: 0;
	border: 2px solid #fff; border-radius: var(--cma-r);
	background: var(--cma-brand); color: #fff;
	box-shadow: 0 2px 10px rgba(0, 0, 0, .35);
	cursor: pointer; line-height: 1;
}
#cma-root .cma-toggle:hover { filter: brightness(1.12); }
#cma-root .cma-icon { fill: currentColor; width: 56%; height: 56%; }

/* Panel */
#cma-root .cma-panel {
	position: fixed; z-index: 2147483001;
	width: min(360px, calc(100vw - 40px));
	max-height: min(640px, calc(100vh - 40px));
	overflow-y: auto;
	background: #fff; color: #1a1a1a;
	border: 1px solid #6b6b6b; border-radius: 12px;
	box-shadow: 0 10px 40px rgba(0, 0, 0, .3);
	text-align: left;
}

/* Desktop placement */
@media (min-width: 768px) {
	#cma-root.cma-dx-right .cma-toggle, #cma-root.cma-dx-right .cma-panel { right: var(--cma-ox); }
	#cma-root.cma-dx-left .cma-toggle, #cma-root.cma-dx-left .cma-panel { left: var(--cma-ox); }
	#cma-root.cma-dy-bottom .cma-toggle { bottom: var(--cma-oy); }
	#cma-root.cma-dy-top .cma-toggle { top: var(--cma-oy); }
	#cma-root.cma-dy-center .cma-toggle { top: calc(50% - var(--cma-size) / 2 + var(--cma-oy)); }
	#cma-root.cma-dy-bottom .cma-panel { bottom: calc(var(--cma-oy) + var(--cma-size) + 12px); max-height: min(640px, calc(100vh - var(--cma-oy) - var(--cma-size) - 32px)); }
	#cma-root.cma-dy-top .cma-panel { top: calc(var(--cma-oy) + var(--cma-size) + 12px); max-height: min(640px, calc(100vh - var(--cma-oy) - var(--cma-size) - 32px)); }
	#cma-root.cma-dy-center .cma-panel { top: 50%; transform: translateY(-50%); width: min(360px, calc(100vw - var(--cma-ox) - var(--cma-size) - 32px)); }
	#cma-root.cma-dy-center.cma-dx-right .cma-panel { right: calc(var(--cma-ox) + var(--cma-size) + 12px); }
	#cma-root.cma-dy-center.cma-dx-left .cma-panel { left: calc(var(--cma-ox) + var(--cma-size) + 12px); }
}

#cma-root .cma-head {
	display: flex; align-items: center; justify-content: space-between;
	padding: 12px 12px 12px 18px; background: var(--cma-lead); color: #fff;
	border-radius: 11px 11px 0 0;
}
#cma-root .cma-title { margin: 0; padding: 0; font-size: 20px; font-weight: 700; line-height: 1.3; color: #fff; border: 0; }
#cma-root .cma-close {
	display: flex; align-items: center; justify-content: center;
	width: 44px; height: 44px; margin: 0; padding: 0;
	background: transparent; color: #fff; border: 2px solid transparent; border-radius: 8px; cursor: pointer;
}
#cma-root .cma-close svg { fill: currentColor; }
#cma-root .cma-close:hover { border-color: #fff; }

#cma-root .cma-body { padding: 14px 18px 6px; }
#cma-root p { margin: 0 0 10px; padding: 0; font-size: 15px; line-height: 1.5; color: #1a1a1a; }
#cma-root .cma-reviewed { font-weight: 600; }
#cma-root .cma-note { font-size: 14px; color: #4a4a4a; }

#cma-root .cma-links { list-style: none; margin: 12px 0 16px; padding: 0; }
#cma-root .cma-links li { margin: 0 0 8px; padding: 0; list-style: none; }
#cma-root .cma-links li::before { content: none; }
#cma-root .cma-btn {
	display: block; padding: 10px 14px; border: 2px solid var(--cma-lead); border-radius: 8px;
	background: #fff; color: var(--cma-lead); font-size: 15px; font-weight: 600;
	text-decoration: underline; text-align: center; line-height: 1.35;
}
#cma-root .cma-btn-primary { background: var(--cma-lead); color: #fff; }
#cma-root .cma-btn:hover { text-decoration-thickness: 2px; }

#cma-root .cma-sub { margin: 14px 0 4px; padding: 14px 0 0; border-top: 1px solid #d0d0d0; font-size: 17px; font-weight: 700; color: #1a1a1a; line-height: 1.3; }

#cma-root fieldset { margin: 0 0 10px; padding: 0; border: 0; min-width: 0; }
#cma-root legend { padding: 0; margin: 0 0 6px; font-size: 15px; font-weight: 600; color: #1a1a1a; }
#cma-root .cma-sizes { display: block; }
#cma-root .cma-sizes label { display: inline-flex; margin: 0 14px 0 0; }
#cma-root .cma-toggles label, #cma-root .cma-sizes label {
	align-items: center; gap: 8px; min-height: 36px; padding: 0;
	font-size: 15px; font-weight: 400; color: #1a1a1a; cursor: pointer; line-height: 1.3;
}
#cma-root .cma-toggles label { display: flex; }
#cma-root input[type="checkbox"], #cma-root input[type="radio"] {
	-webkit-appearance: auto; appearance: auto; position: static; opacity: 1;
	width: 20px; height: 20px; min-width: 20px; margin: 0; padding: 0;
	accent-color: var(--cma-lead); cursor: pointer;
}
#cma-root .cma-reset {
	margin: 8px 0 6px; padding: 8px 12px; min-height: 40px;
	background: #fff; color: #1a1a1a; border: 2px solid #595959; border-radius: 8px;
	font-size: 14px; font-weight: 600; cursor: pointer; line-height: 1.2;
}
#cma-root .cma-reset:hover { background: #f0f0f0; }
#cma-root .cma-status { min-height: 1em; font-size: 14px; margin: 0 0 6px; }

#cma-root .cma-credit { margin: 0; padding: 10px 18px 12px; border-top: 1px solid #d0d0d0; font-size: 13px; color: #4a4a4a; }
#cma-root .cma-credit a { color: #4a4a4a; text-decoration: underline; }

/* Strong focus for everything in the widget */
#cma-root a:focus-visible, #cma-root button:focus-visible, #cma-root input:focus-visible {
	outline: 3px solid var(--cma-ring) !important; outline-offset: 2px !important;
	box-shadow: 0 0 0 6px #1a1a1a !important;
}
#cma-root .cma-title:focus { outline: none; }

/* Mobile placement */
@media (max-width: 767px) {
	#cma-root.cma-hide-mobile { display: none !important; }
	#cma-root .cma-toggle { width: var(--cma-msize); height: var(--cma-msize); border-radius: var(--cma-mr); }
	#cma-root.cma-mx-right .cma-toggle { right: var(--cma-mox); }
	#cma-root.cma-mx-left .cma-toggle { left: var(--cma-mox); }
	#cma-root.cma-my-bottom .cma-toggle { bottom: var(--cma-moy); }
	#cma-root.cma-my-top .cma-toggle { top: var(--cma-moy); }
	#cma-root.cma-my-center .cma-toggle { top: calc(50% - var(--cma-msize) / 2 + var(--cma-moy)); }
	#cma-root .cma-panel { left: 12px; right: 12px; width: auto; }
	#cma-root.cma-my-bottom .cma-panel { bottom: calc(var(--cma-moy) + var(--cma-msize) + 10px); max-height: calc(100vh - var(--cma-moy) - var(--cma-msize) - 24px); }
	#cma-root.cma-my-top .cma-panel { top: calc(var(--cma-moy) + var(--cma-msize) + 10px); max-height: calc(100vh - var(--cma-moy) - var(--cma-msize) - 24px); }
	#cma-root.cma-my-center .cma-panel { top: 50%; transform: translateY(-50%); max-height: calc(100vh - 24px); }
}
@media print { #cma-root { display: none !important; } }
@media (forced-colors: active) {
	#cma-root .cma-toggle, #cma-root .cma-panel { border: 2px solid CanvasText; }
}

/* Statement page lists: comfortable spacing and target size */
.cma-statement ul li { margin-bottom: .6em; }
.cma-statement ul li a { display: inline-block; padding: 4px 0; min-height: 24px; }

/* ---------- Visitor display preferences (page content only, never the widget) ---------- */

/* Text size: zooms the page so layouts reflow like browser zoom */
html.cma-text-1 body > :not(#cma-root) { zoom: 1.15; }
html.cma-text-2 body > :not(#cma-root) { zoom: 1.3; }

/* High contrast */
html.cma-contrast body { background: #fff !important; }
html.cma-contrast body > :not(#cma-root),
html.cma-contrast body > :not(#cma-root) *:not(img):not(svg):not(svg *):not(video):not(iframe) {
	color: #000 !important;
	background-color: #fff !important;
	background-image: none !important;
	border-color: #000 !important;
	text-shadow: none !important;
	box-shadow: none !important;
}
html.cma-contrast body > :not(#cma-root) a,
html.cma-contrast body > :not(#cma-root) a * { color: #0000c8 !important; text-decoration: underline !important; }
html.cma-contrast body > :not(#cma-root) ::placeholder { color: #333 !important; opacity: 1 !important; }
html.cma-contrast body > :not(#cma-root) input,
html.cma-contrast body > :not(#cma-root) select,
html.cma-contrast body > :not(#cma-root) textarea,
html.cma-contrast body > :not(#cma-root) button,
html.cma-contrast body > :not(#cma-root) .fusion-button,
html.cma-contrast body > :not(#cma-root) .button,
html.cma-contrast body > :not(#cma-root) .wp-block-button__link { border: 2px solid #000 !important; }

/* Underline links */
html.cma-underline body > :not(#cma-root) a { text-decoration: underline !important; text-underline-offset: 2px; }

/* Easy-to-read font (skips icon fonts) */
html.cma-font body > :not(#cma-root),
html.cma-font body > :not(#cma-root) *:not(i):not([class*="icon"]):not([class*="fa-"]):not([class*="dashicons"]) {
	font-family: Verdana, Tahoma, Arial, sans-serif !important;
}

/* More text spacing (WCAG 1.4.12 values) */
html.cma-spacing body > :not(#cma-root) p,
html.cma-spacing body > :not(#cma-root) li,
html.cma-spacing body > :not(#cma-root) td,
html.cma-spacing body > :not(#cma-root) dd,
html.cma-spacing body > :not(#cma-root) blockquote {
	line-height: 1.6 !important;
	letter-spacing: .12em !important;
	word-spacing: .16em !important;
}
html.cma-spacing body > :not(#cma-root) p { margin-bottom: 2em !important; }

/* Stop animations */
html.cma-pause body > :not(#cma-root),
html.cma-pause body > :not(#cma-root) *,
html.cma-pause body > :not(#cma-root) *::before,
html.cma-pause body > :not(#cma-root) *::after {
	animation-duration: .001ms !important;
	animation-iteration-count: 1 !important;
	transition-duration: .001ms !important;
	scroll-behavior: auto !important;
}

/* Highlight keyboard focus */
html.cma-focus body > :not(#cma-root) :focus-visible {
	outline: 3px solid #ffbf47 !important;
	outline-offset: 2px !important;
	box-shadow: 0 0 0 6px #000 !important;
}
