/*
 * TechnoScrap accessibility overrides.
 * Loaded after the Consulting theme and child-theme styles.
 */

/* Screen-reader-only page title used when WPBakery does not output an H1. */
.a11y-page-title,
.screen-reader-text {
  border: 0 !important;
  clip: rect(1px, 1px, 1px, 1px) !important;
  clip-path: inset(50%) !important;
  height: 1px !important;
  margin: -1px !important;
  overflow: hidden !important;
  padding: 0 !important;
  position: absolute !important;
  width: 1px !important;
  white-space: nowrap !important;
}

.a11y-page-title:focus,
.screen-reader-text:focus {
  clip: auto !important;
  clip-path: none !important;
  height: auto !important;
  margin: 0 !important;
  overflow: visible !important;
  padding: 12px 16px !important;
  position: fixed !important;
  top: 8px !important;
  left: 8px !important;
  width: auto !important;
  z-index: 100000 !important;
  color: #111 !important;
  background: #fff !important;
}

/* Visible keyboard focus on both light and dark backgrounds. */
a:focus,
button:focus,
input:focus,
select:focus,
textarea:focus,
[tabindex]:focus {
  outline: 3px solid #fff !important;
  outline-offset: 2px !important;
  box-shadow: 0 0 0 5px #111 !important;
}

#menu_toggle > button,
#menu_toggle_button > button {
  min-width: 44px !important;
  min-height: 44px !important;
  cursor: pointer !important;
}

/*
 * Slider Revolution puts white text over photographs. WAVE treats the
 * transparent layer as a light background, so each text layer gets a solid,
 * high-contrast backing.
 */
.rev_slider_wrapper .tp-caption[data-type="text"],
.rev_slider .tp-caption[data-type="text"],
.tp-revslider-mainul .tp-caption[data-type="text"],
.rev_slider_wrapper .tp-caption:not(.tp-shape):not(.tp-shapewrapper),
.rev_slider .tp-caption:not(.tp-shape):not(.tp-shapewrapper) {
  color: #fff !important;
  background-color: #4a0e0a !important;
  padding: 8px 12px !important;
  box-decoration-break: clone !important;
  -webkit-box-decoration-break: clone !important;
}

.rev_slider_wrapper .tp-caption[data-type="text"] *,
.rev_slider .tp-caption[data-type="text"] *,
.tp-revslider-mainul .tp-caption[data-type="text"] * {
  color: #fff !important;
}

/* Do not place a background behind image-only slider layers. */
.rev_slider_wrapper .tp-caption img,
.rev_slider .tp-caption img,
.tp-revslider-mainul .tp-caption img {
  background: transparent !important;
}

/* Stronger, explicit contrast for the red home-page content section. */
body.home .homepage-exp-row,
body.home .homepage-exp-row > .vc_row,
body.home .homepage-exp-content-container,
body.home .homepage-exp-content-container > .vc_column-inner,
body.home .homepage-exp-content-text,
body.home .homepage-exp-content-text > .wpb_wrapper {
  color: #fff !important;
  background-color: #72140e !important;
}

body.home .homepage-exp-content-text h1,
body.home .homepage-exp-content-text h2,
body.home .homepage-exp-content-text h3,
body.home .homepage-exp-content-text h4,
body.home .homepage-exp-content-text h5,
body.home .homepage-exp-content-text h6,
body.home .homepage-exp-content-text p,
body.home .homepage-exp-content-text span,
body.home .homepage-exp-content-text strong,
body.home .homepage-exp-content-text em,
body.home .homepage-exp-content-text li,
body.home .homepage-exp-content-text a {
  color: #fff !important;
}

/* Preserve the existing visual styling after JavaScript corrects H3 to H2. */
.homepage-exp-content-text h2,
.homepage-serv-content-text h2 {
  text-align: left !important;
  font-size: 23px !important;
  line-height: 1.35 !important;
  font-weight: 700 !important;
  padding: 10px 0 !important;
}

/* Newsletter placeholder was black on a dark field in the old child CSS. */
#footer .tnp-widget-minimal input.tnp-email,
section#newsletterwidgetminimal-2 .tnp-widget-minimal input.tnp-email {
  color: #fff !important;
  background-color: #333 !important;
  border: 1px solid #fff !important;
}

#footer .tnp-widget-minimal input.tnp-email::placeholder,
section#newsletterwidgetminimal-2 .tnp-widget-minimal input.tnp-email::placeholder {
  color: #fff !important;
  opacity: 1 !important;
}

#footer .tnp-widget-minimal input.tnp-email::-webkit-input-placeholder,
section#newsletterwidgetminimal-2 .tnp-widget-minimal input.tnp-email::-webkit-input-placeholder {
  color: #fff !important;
  opacity: 1 !important;
}

#footer .tnp-widget-minimal input.tnp-email::-moz-placeholder,
section#newsletterwidgetminimal-2 .tnp-widget-minimal input.tnp-email::-moz-placeholder {
  color: #fff !important;
  opacity: 1 !important;
}

/* Avoid the low-contrast grey hover colour from the original child theme. */
.custom-footer-right-links a:hover,
.custom-footer-right-links a:focus {
  color: #05244a !important;
  text-decoration: underline !important;
}
