/* HHM accessibility toolkit + WCAG 2.2 AA base fixes */
@font-face{font-family:"Atkinson Hyperlegible";font-style:normal;font-weight:400;font-display:swap;src:url("fonts/atkinson-hyperlegible-latin-400-normal.woff2") format("woff2")}
@font-face{font-family:"Atkinson Hyperlegible";font-style:normal;font-weight:700;font-display:swap;src:url("fonts/atkinson-hyperlegible-latin-700-normal.woff2") format("woff2")}

:root{--hhm-a11y-bottom:64px;--hhm-a11y-gold:#8a6508;--hhm-a11y-focus:#0b57d0}

/* ---------- Visible keyboard focus (>=3:1 on light AND dark backgrounds: blue ring + white halo) ---------- */
html body a:focus-visible,html body button:focus-visible,html body input:focus-visible,html body select:focus-visible,html body textarea:focus-visible,
html body summary:focus-visible,html body [tabindex]:focus-visible,html body [role="button"]:focus-visible{
  outline:3px solid var(--hhm-a11y-focus)!important;outline-offset:2px!important;box-shadow:0 0 0 2px #fff!important}

/* ---------- Skip link (ours is only shown when the theme has none) ---------- */
.hhm-a11y-skip,.skip-link.screen-reader-text:focus{position:fixed;left:8px;top:8px;z-index:100010;background:#111;color:#fff;padding:12px 18px;border-radius:6px;font:600 16px/1.2 system-ui,sans-serif;text-decoration:underline}
.hhm-a11y-skip:not(:focus){position:absolute;width:1px;height:1px;overflow:hidden;clip:rect(0 0 0 0);white-space:nowrap;padding:0}
.skip-link.screen-reader-text:focus{clip:auto!important;width:auto!important;height:auto!important}
#content:focus,#hhm-main:focus{outline:none}

/* ---------- Contrast fixes in our own / theme-child surfaces ---------- */
.hhm-cookie-banner__text a{text-decoration:underline}
.header-tagline__pop{color:#7a5a00!important;animation-name:hhmPopA11y!important}
@keyframes hhmPopA11y{0%{transform:scale(.92)}15%{transform:scale(1.08)}25%,100%{transform:scale(1)}}
html.hhm-a11y-still .header-tagline__pop{animation:none!important;opacity:1!important;transform:none!important}
@media (prefers-reduced-motion:reduce){.header-tagline__pop{animation:none!important;opacity:1!important;transform:none!important}}
.hhm-founder-badge .hhm-badge-label{color:#7a5a00!important}
#content :is(p,li,td,dd) a:not([class]){color:#0269a4;text-decoration:underline}            /* animated gold word: was as light as 1.0:1 on white */
.hhm-legal-footer{color:#4b5563}
.hhm-a11y-sr{position:absolute;width:1px;height:1px;overflow:hidden;clip:rect(0 0 0 0);white-space:nowrap}

/* Overlay contrast fixes for surfaces owned by other streams (search notice, directory REN line, review dates) */
.hhm-ss-note__text strong{color:#8a5300!important}
.hhm-agent-directory__ren{color:#595959!important}
.hp-result-count,body time{color:#5f6368!important}
.hp-listing__categories a,.hp-listing__category a{color:#4b5563!important}
.desk a,.desk+a,[class*="proto"] nav a{min-height:24px;display:inline-flex;align-items:center}
.hhm-tap24 a{min-height:24px;display:inline-block}

/* ---------- Floating button + panel ---------- */
.hhm-a11y-btn{position:fixed;left:14px;bottom:var(--hhm-a11y-bottom);z-index:99996;width:52px;height:52px;border-radius:50%;
  border:3px solid #fff;background:#1a1a1a;color:#fff;cursor:pointer;display:flex;align-items:center;justify-content:center;
  box-shadow:0 2px 10px rgba(0,0,0,.4);padding:0;transition:none}
.hhm-a11y-btn:hover{background:#000}
.hhm-a11y-panel{position:fixed;left:14px;bottom:calc(var(--hhm-a11y-bottom) + 62px);z-index:100005;width:min(340px,calc(100vw - 28px));
  max-height:calc(100vh - var(--hhm-a11y-bottom) - 90px);overflow:auto;background:#fff;color:#111;border:2px solid #111;border-radius:14px;
  box-shadow:0 8px 30px rgba(0,0,0,.35);font:16px/1.4 system-ui,-apple-system,"Segoe UI",Roboto,sans-serif;text-align:left}
.hhm-a11y-panel[hidden]{display:none}
.hhm-a11y-head{display:flex;align-items:center;justify-content:space-between;padding:12px 14px;border-bottom:1px solid #d1d5db;background:#f3f4f6;border-radius:12px 12px 0 0}
.hhm-a11y-head h2{margin:0;font-size:18px;font-weight:700;line-height:1.2;color:#111;padding:0}
.hhm-a11y-close{width:44px;height:44px;border:2px solid #111;border-radius:8px;background:#fff;color:#111;font-size:26px;line-height:1;cursor:pointer}
.hhm-a11y-body{padding:12px 14px 14px;display:grid;gap:8px}
.hhm-a11y-panel button,.hhm-a11y-panel a{font:600 15px/1.2 system-ui,sans-serif}
.hhm-a11y-row{display:flex;align-items:center;justify-content:space-between;gap:10px}
.hhm-a11y-lab{font-weight:700}
.hhm-a11y-zoom{display:flex;align-items:center;gap:6px}
.hhm-a11y-zoom output{min-width:52px;text-align:center;font-weight:700}
.hhm-a11y-panel button{min-height:44px;min-width:44px;padding:8px 12px;border:2px solid #111;border-radius:8px;background:#fff;color:#111;cursor:pointer;text-align:left}
.hhm-a11y-zoom button,.hhm-a11y-btnrow button,.hhm-a11y-foot button{text-align:center}
.hhm-a11y-tog[aria-pressed="true"]{background:#111;color:#fff}
.hhm-a11y-tog[aria-pressed="true"]::after{content:" \2713";}
.hhm-a11y-read{border:1px solid #9ca3af;border-radius:8px;padding:8px 10px;display:grid;gap:8px;margin:0;min-width:0}
.hhm-a11y-read legend{font-size:15px;font-weight:700;padding:0 4px;width:auto;color:#111}
.hhm-a11y-btnrow{display:flex;gap:6px;flex-wrap:wrap}
.hhm-a11y-btnrow button{flex:1 1 30%}
.hhm-a11y-hint{margin:0;font-size:13px;color:#374151}
.hhm-a11y-foot{display:flex;justify-content:space-between;align-items:center;gap:10px}
.hhm-a11y-foot a{color:#0b3a8f;text-decoration:underline;min-height:24px;display:inline-block;padding:10px 4px}
.hhm-a11y-speaking{outline:3px dashed #0b57d0!important;outline-offset:3px}

/* ---------- Text size: done in JS by scaling real font sizes (keeps the layout responsive, like browser text zoom) ---------- */
html.hhm-a11y-zoomed{overflow-wrap:anywhere}

/* ---------- Easy-read font ---------- */
html.hhm-a11y-dys body *:not(i):not(svg):not(svg *):not([class*="icon"]):not([class*="fa-"]):not(.dashicons):not(.material-icons){
  font-family:"Atkinson Hyperlegible",Verdana,Tahoma,"Trebuchet MS",sans-serif!important;letter-spacing:.02em;word-spacing:.08em}
html.hhm-a11y-dys body p,html.hhm-a11y-dys body li{line-height:1.7!important}

/* ---------- Bigger cursor ---------- */
html.hhm-a11y-cur,html.hhm-a11y-cur *{cursor:url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='48' height='48' viewBox='0 0 24 24'><path d='M3 2l16 9-7 2 4 8-3 1.5-4-8-5 5z' fill='black' stroke='white' stroke-width='1.6' stroke-linejoin='round'/></svg>") 4 2,auto!important}
html.hhm-a11y-cur a,html.hhm-a11y-cur a *,html.hhm-a11y-cur button,html.hhm-a11y-cur button *,html.hhm-a11y-cur [role="button"],html.hhm-a11y-cur label,html.hhm-a11y-cur select,html.hhm-a11y-cur summary{
  cursor:url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='48' height='48' viewBox='0 0 24 24'><path d='M9 2.5a1.6 1.6 0 013.2 0V10l1.2-.4a1.5 1.5 0 011.9 1l.5-.1a1.5 1.5 0 011.8 1l.4-.1a1.5 1.5 0 011.7 1.4l.3 5.4c0 3-1.6 5-4.6 5H12c-2 0-3.4-1-4.4-2.6L4 14.8a1.6 1.6 0 012.6-1.8l2.4 2.6z' fill='white' stroke='black' stroke-width='1.4' stroke-linejoin='round'/></svg>") 12 3,pointer!important}

/* ---------- Links underlined + highlighted ---------- */
html.hhm-a11y-links body a:not(.hhm-a11y-btn){text-decoration:underline!important;text-underline-offset:3px;text-decoration-thickness:2px!important;
  background-color:#fff59d!important;color:#0a2a6b!important;outline:1px solid #c9b400}
html.hhm-a11y-links body a img{outline:2px solid #0a2a6b}

/* ---------- Pause animations (also automatic for prefers-reduced-motion) ---------- */
html.hhm-a11y-still *,html.hhm-a11y-still *::before,html.hhm-a11y-still *::after{
  animation-duration:.001ms!important;animation-iteration-count:1!important;animation-delay:0s!important;transition-duration:.001ms!important;scroll-behavior:auto!important}
@media (prefers-reduced-motion:reduce){
  html *,html *::before,html *::after{animation-duration:.001ms!important;animation-iteration-count:1!important;transition-duration:.001ms!important;scroll-behavior:auto!important}
}

/* ---------- High contrast ---------- */
html.hhm-a11y-hc body,html.hhm-a11y-hc body *:not(svg):not(svg *):not(video):not(img):not(#hhm-a11y-root):not(#hhm-a11y-root *){
  background-color:#000!important;background-image:none!important;color:#fff!important;border-color:#fff!important;text-shadow:none!important;box-shadow:none!important}
html.hhm-a11y-hc body a:not(#hhm-a11y-root *){color:#ffff33!important;text-decoration:underline!important}
html.hhm-a11y-hc body a:visited:not(#hhm-a11y-root *){color:#ffb3ff!important}
html.hhm-a11y-hc body button:not(#hhm-a11y-root *),html.hhm-a11y-hc body input:not(#hhm-a11y-root *),html.hhm-a11y-hc body select:not(#hhm-a11y-root *),html.hhm-a11y-hc body textarea:not(#hhm-a11y-root *){border:2px solid #fff!important}
html.hhm-a11y-hc body *:focus-visible:not(#hhm-a11y-root *){outline:3px solid #00ffff!important;box-shadow:none!important}
html.hhm-a11y-hc body svg:not([fill="none"]) *:not([fill="none"]):not(#hhm-a11y-root *){fill:#fff!important}
html.hhm-a11y-hc body svg [stroke]:not([stroke="none"]):not(#hhm-a11y-root *){stroke:#fff!important}
html.hhm-a11y-hc body ::placeholder{color:#ddd!important;opacity:1!important}
html.hhm-a11y-hc body input,html.hhm-a11y-hc body textarea,html.hhm-a11y-hc body select{color:#fff!important;-webkit-text-fill-color:#fff}
html.hhm-a11y-hc .hhm-a11y-panel{background:#000;color:#fff;border-color:#fff}
html.hhm-a11y-hc .hhm-a11y-head{background:#000;border-color:#fff}
html.hhm-a11y-hc .hhm-a11y-head h2,html.hhm-a11y-hc .hhm-a11y-hint,html.hhm-a11y-hc .hhm-a11y-lab,html.hhm-a11y-hc .hhm-a11y-read legend{color:#fff}
html.hhm-a11y-hc .hhm-a11y-panel button{background:#000;color:#fff;border-color:#fff}
html.hhm-a11y-hc .hhm-a11y-tog[aria-pressed="true"]{background:#ffff33;color:#000}
html.hhm-a11y-hc .hhm-a11y-foot a{color:#ffff33}
html.hhm-a11y-hc .hhm-a11y-btn{background:#000;border-color:#ffff33;color:#ffff33}
html.hhm-a11y-hc .hhm-a11y-read{border-color:#fff}

@media (max-width:600px){
  .hhm-a11y-panel{left:8px;width:calc(100vw - 16px)}
}
