/* YHealth site-wide fixes and helpers (loaded on every page after the theme). */

/* --- Accessibility fixes to the Kajabi theme (WCAG 2.1 AA) --- */
/* Links inside text must not rely on color alone. */
main p a, main li a, .blog-post-body a { text-decoration: underline; }
/* Blue buttons: white text on #4c80ed was 3.7:1; this blue is 5.2:1. */
.btn--solid, #cta-btn, #opt-in-btn { background-color: #2d62d3 !important; border-color: #2d62d3 !important; color: #fff !important; }
/* Grey small print was 3.5:1. */
.blog-post-optin__disclaimer-text { color: #595959 !important; }
/* Light blue links in pasted text were 4.3:1. */
[style*="#2980b9"], [style*="#2980B9"] { color: #1f6391 !important; }
/* Cookie banner "Accept all" was 2.3:1. */
#cookiescript_accept { background-color: #2e7d32 !important; }
/* Keyboard users must see where they are. */
a:focus-visible, button:focus-visible, summary:focus-visible, input:focus-visible { outline: 3px solid #1a4fbf; outline-offset: 2px; }

/* --- Visitor's accessibility choices (set by yhealth.js) --- */
html.yh-text-large { font-size: 125%; }
html.yh-text-large body, html.yh-text-large p, html.yh-text-large li { font-size: 1.15em !important; line-height: 1.6 !important; }
html.yh-contrast body, html.yh-contrast section, html.yh-contrast .section, html.yh-contrast header, html.yh-contrast footer { background: #000 !important; }
html.yh-contrast body *:not(.yh-fab):not(.yh-panel):not(.yh-panel *) { color: #fff !important; background-color: transparent !important; border-color: #fff !important; }
html.yh-contrast a:not(.yh-panel a) { color: #ffeb3b !important; text-decoration: underline !important; }
html.yh-underline a { text-decoration: underline !important; }
html.yh-no-motion *, html.yh-no-motion *::before, html.yh-no-motion *::after { animation: none !important; transition: none !important; scroll-behavior: auto !important; }

/* --- Quick help + Accessibility buttons and panels --- */
.yh-fab { position: fixed; bottom: 16px; z-index: 2147483000; font: 600 16px/1 system-ui, -apple-system, sans-serif;
  color: #fff; background: #1a4fbf; border: 0; border-radius: 24px; padding: 12px 16px; cursor: pointer;
  box-shadow: 0 2px 8px rgba(0,0,0,.25); }
.yh-fab span { margin-right: 6px; }
.yh-fab.yh-right { right: 16px; }
/* Stacked above Quick help: the cookie banner keeps its own icon in the bottom-left corner. */
.yh-fab.yh-left { right: 16px; bottom: 68px; }
.yh-panel { position: fixed; bottom: 124px; z-index: 2147483001; width: min(360px, calc(100vw - 32px));
  max-height: calc(100vh - 96px); overflow: auto; background: #fff; color: #1f2328; border-radius: 12px;
  box-shadow: 0 8px 28px rgba(0,0,0,.3); padding: 16px; font: 16px/1.5 system-ui, -apple-system, sans-serif; text-align: left; }
.yh-panel[hidden] { display: none; }
.yh-panel.yh-right { right: 16px; }
.yh-panel.yh-left { right: 16px; }
.yh-panel-title { font-size: 18px; margin: 0 32px 12px 0; color: #1f2328; }
.yh-close { position: absolute; top: 8px; right: 8px; width: 36px; height: 36px; font-size: 24px; line-height: 1;
  background: none; border: 0; color: #1f2328; cursor: pointer; border-radius: 6px; }
.yh-panel a { color: #1a4fbf; text-decoration: underline; }
.yh-topics details { border-top: 1px solid #d0d7de; }
.yh-topics summary { padding: 10px 0; cursor: pointer; font-weight: 600; }
.yh-answer { padding: 0 0 10px; }
.yh-answer ul { margin: 0; padding-left: 20px; }
.yh-answer p { margin: 0 0 8px; }
.yh-note { font-size: 14px; color: #3d444d; margin: 12px 0 0; border-top: 1px solid #d0d7de; padding-top: 10px; }
.yh-toggle { display: block; width: 100%; text-align: left; margin: 0 0 8px; padding: 10px 12px; font: 600 16px system-ui, sans-serif;
  color: #1f2328; background: #f6f8fa; border: 1px solid #d0d7de; border-radius: 8px; cursor: pointer; }
.yh-toggle[aria-pressed="true"] { background: #1a4fbf; color: #fff; border-color: #1a4fbf; }
.yh-toggle[aria-pressed="true"]::after { content: "  ✓ on"; }
@media (max-width: 480px) {
  .yh-fab { font-size: 14px; padding: 10px 12px; }
  .yh-fab.yh-left { bottom: 60px; }
  .yh-panel { bottom: 108px; max-height: calc(100vh - 124px); }
}
@media print { .yh-fab, .yh-panel { display: none !important; } }
