/*
 * Light focus style for the "new look" pages.
 *
 * a11y.css gives every focused element a 3px dark-blue outline (!important), and the new-look
 * pages added a thick .2rem green glow on fields. Inside the new-look containers below we use:
 *   - fields: soft green border + faint 2px ring, no outline
 *   - radios / checkboxes / buttons / links: thin 1px green outline, keyboard focus only
 * Everything still has a visible focus indicator.
 *
 * Loaded from gg_top.php right after a11y.css. Uses !important because each page's own
 * <style> block comes later in the document.
 */

/* ---- text fields, dropdowns, textareas ---- */
:is(.acct-wrap, .don-wrap, .vol-wrap, .reg-wrap, #payModal, #waitModal, .tt-wrap, .cal-wrap,
    .rg-wrap, .ct-wrap, .cs-wrap, .inv-wrap, .pt-wrap, .gri, .enf-wrap, .nf-wrap, .ev-card)
  :is(.form-control, select, textarea, input:not([type="radio"]):not([type="checkbox"]):not([type="file"])):focus {
  outline: none !important;
  border-color: #5cb85c !important;
  box-shadow: 0 0 0 2px rgba(40, 167, 69, .12) !important;
}

:is(.acct-wrap, .don-wrap, .vol-wrap, .reg-wrap, #payModal, #waitModal, .tt-wrap, .cal-wrap,
    .rg-wrap, .ct-wrap, .cs-wrap, .inv-wrap, .pt-wrap, .gri, .enf-wrap, .nf-wrap, .ev-card)
  :is(.form-control, select, textarea, input):focus-visible {
  outline: none !important;
}

/* small inline fields: even lighter */
:is(.acct-wrap, .don-wrap, .vol-wrap, .reg-wrap, #payModal, #waitModal, .tt-wrap, .cal-wrap,
    .rg-wrap, .ct-wrap, .cs-wrap, .inv-wrap, .pt-wrap, .gri, .enf-wrap, .nf-wrap, .ev-card)
  .form-control-sm:focus {
  box-shadow: 0 0 0 1px rgba(40, 167, 69, .2) !important;
}

/* Bootstrap custom file picker draws its glow on the label */
:is(.acct-wrap, .don-wrap, .vol-wrap, .reg-wrap, #payModal, #waitModal, .tt-wrap, .cal-wrap,
    .rg-wrap, .ct-wrap, .cs-wrap, .inv-wrap, .pt-wrap, .gri, .enf-wrap, .nf-wrap, .ev-card)
  .custom-file-input:focus ~ .custom-file-label {
  border-color: #5cb85c !important;
  box-shadow: 0 0 0 2px rgba(40, 167, 69, .12) !important;
}

:is(.acct-wrap, .don-wrap, .vol-wrap, .reg-wrap, #payModal, #waitModal, .tt-wrap, .cal-wrap,
    .rg-wrap, .ct-wrap, .cs-wrap, .inv-wrap, .pt-wrap, .gri, .enf-wrap, .nf-wrap, .ev-card)
  .custom-file-input:focus-visible {
  outline: none !important;
}

/* ---- radios / checkboxes: no border to turn green, so a thin outline (keyboard only) ---- */
:is(.acct-wrap, .don-wrap, .vol-wrap, .reg-wrap, #payModal, #waitModal, .tt-wrap, .cal-wrap,
    .rg-wrap, .ct-wrap, .cs-wrap, .inv-wrap, .pt-wrap, .gri, .enf-wrap, .nf-wrap, .ev-card)
  :is(input[type="radio"], input[type="checkbox"]):focus-visible {
  outline: 1px solid #28a745 !important;
  outline-offset: 2px;
}

/* ---- buttons / links: nothing on mouse click, thin green outline for keyboard users ---- */
:is(.acct-wrap, .don-wrap, .vol-wrap, .reg-wrap, #payModal, #waitModal, .tt-wrap, .cal-wrap,
    .rg-wrap, .ct-wrap, .cs-wrap, .inv-wrap, .pt-wrap, .gri, .enf-wrap, .nf-wrap,
    .ev-card, .ev-cta, .ev-share, #header .nav-menu)
  :is(.btn, a, button, [role="button"]):focus {
  outline: 0;
}

:is(.acct-wrap, .don-wrap, .vol-wrap, .reg-wrap, #payModal, #waitModal, .tt-wrap, .cal-wrap,
    .rg-wrap, .ct-wrap, .cs-wrap, .inv-wrap, .pt-wrap, .gri, .enf-wrap, .nf-wrap,
    .ev-card, .ev-cta, .ev-share, #header .nav-menu)
  :is(.btn, a, button, [role="button"]):focus-visible {
  outline: 1px solid #28a745 !important;
  outline-offset: 2px;
}
