/* ===== WCAG fixes for modified sphinx-rtd-theme 3.0.0 ===== */

/* A. Links: visible, not just color */
.rst-content a:not(.headerlink) {
  text-decoration: underline;
  text-underline-offset: 2px;
}
.rst-content a:hover,
.rst-content a:focus-visible {
  text-decoration-thickness: 3px;
}

/* B. Strong, consistent keyboard focus */
a:focus-visible, button:focus-visible, [role="button"]:focus-visible,
[tabindex]:focus-visible, .wy-menu-vertical a:focus-visible,
.wy-nav-top i:focus-visible {
  outline: 3px solid #ffcb2f;   /* brand yellow */
  outline-offset: 3px;
  box-shadow: none;
}

/* C. Code & console blocks: guarantee legibility on dark pages */
.rst-content pre,
.rst-content code,
.rst-content div.highlight,
.rst-content div[class^="highlight"] {
  background: #f7f7f7;          /* light background for contrast */
  color: #111;
}

/* Your console override had low-contrast gray on white; fix it */
.rst-content .highlight-console pre,
.rst-content .highlight-console code {
  background: #fff !important;
  color: #111 !important;
  border: 1px solid #e0e0e0;
}

/* If any tokens were forced to black, keep them readable */
.rst-content .highlight-console .o,
.rst-content .highlight-console .m,
.rst-content .highlight-console .n,
.rst-content .highlight-console .s,
.rst-content .highlight-console .p,
.rst-content .highlight-console .nf,
.rst-content .highlight-console .na,
.rst-content .highlight-console .nn,
.rst-content .highlight-console .nc,
.rst-content .highlight-console .nt,
.rst-content .highlight-console .gr,
.rst-content .highlight-console .gd,
.rst-content .highlight-console .gi,
.rst-content .highlight-console .gh,
.rst-content .highlight-console .go,
.rst-content .highlight-console .gp,
.rst-content .highlight-console .gs,
.rst-content .highlight-console .gu,
.rst-content .highlight-console .gt {
  color: #111 !important; /* high-contrast against white */
}

/* D. Tabs (sphinx-design / sphinx-tabs): focus & selected state */
.sd-tab-set [role="tab"] { outline: none; }
.sd-tab-set [role="tab"]:focus-visible {
  outline: 3px solid #ffcb2f; outline-offset: 2px;
}
.sd-tab-set [role="tab"][aria-selected="true"] {
  border-bottom: 3px solid #ffcb2f;
  font-weight: 700;
}

/* E. Skip link style (when injected; see step 3) */
.skip-to-content {
  position: absolute; left: -999px; top: 0;
  background: #ffcb2f; color: #000; padding: .5rem .75rem; font-weight: 700;
}
.skip-to-content:focus {
  left: 8px; top: 8px; z-index: 10000;
}

/* F. Ensure main region can receive focus outline if needed */
[role="main"], .wy-nav-content { outline: none; }
