html {
  scroll-behavior: smooth;
}
body {
  padding-top: 26px !important;
}
.local-notice {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 99999;
  background: #37364c;
  color: white;
  text-align: center;
  font: 12px/26px Arial;
}
.local-hero {
  display: flex;
  position: relative;
  height: min(49vw, 700px);
  min-height: 280px;
  background: #696897;
  overflow: hidden;
}
.local-hero img {
  width: 50%;
  object-fit: cover;
}
.local-hero > div {
  width: 50%;
  display: grid;
  place-items: center;
  color: #fff;
  text-align: center;
}
.local-hero h2 {
  font: italic bold clamp(22px, 3vw, 42px)/1.15 Arial;
  color: #fff;
  text-shadow: 2px 2px #333;
}
.local-hero button {
  position: absolute;
  top: 45%;
  border: 0;
  background: transparent;
  color: white;
  font-size: 48px;
  cursor: pointer;
}
.slide-prev {
  left: 20px;
}
.slide-next {
  right: 20px;
}
.local-page {
  max-width: 1080px;
  margin: 40px auto;
  min-height: 65vh;
  padding: 24px;
}
.local-simple-header {
  display: flex;
  gap: 24px;
  padding: 24px;
  border-bottom: 1px solid #eee;
}
.local-page h1 {
  color: #686393;
}
#local-appointment,
#local-contact-note {
  max-width: 680px;
  margin: 30px auto;
  padding: 24px;
}
#local-appointment label,
#local-contact-note label {
  display: block;
  margin: 12px 0;
}
#local-appointment input:not([type="checkbox"]),
#local-appointment select,
#local-appointment textarea,
#local-contact-note input,
#local-contact-note textarea {
  display: block;
  width: 100%;
  padding: 10px;
  border: 1px solid #aaa;
}
#local-appointment button,
#local-contact-note button,
.local-page button {
  padding: 12px 22px;
  background: #8474b0;
  color: white;
  border: 0;
  cursor: pointer;
}

/* WP7 hosted payment layout */
.local-paypal { display: flex; flex-direction: column; align-items: center; gap: 16px; margin: 24px auto; }
.local-paypal-qr { display: block; width: 200px; max-width: 100%; height: auto; }
.local-paypal-button { width: 100%; max-width: 400px; min-height: 120px; }
.local-paypal-status { text-align: center; }
.local-video {
  display: block;
  padding: 30px;
  text-align: center;
  background: #ececec;
  color: #64608b;
  min-height: 180px;
}
.wpb_animate_when_almost_visible,
.wpex-animated,
.vc_animate_when_almost_visible {
  opacity: 1 !important;
  visibility: visible !important;
  animation: none !important;
  transform: none !important;
}
.local-gallery-open {
  position: fixed;
  inset: 0;
  z-index: 999999;
  background: #000d;
  display: flex;
  align-items: center;
  justify-content: center;
}
.local-gallery-open img {
  max-width: 90vw;
  max-height: 85vh;
  object-fit: contain;
}
.local-gallery-open button {
  position: absolute;
  right: 25px;
  top: 25px;
  color: white;
  background: none;
  border: 0;
  font-size: 40px;
}
.local-menu {
  display: block !important;
  visibility: visible !important;
  position: fixed !important;
  inset: 80px 0 auto !important;
  background: white;
  z-index: 9999;
  max-height: 75vh;
  overflow: auto;
  padding: 20px !important;
}
.local-menu ul {
  display: block !important;
}
.local-menu li {
  display: block !important;
  padding: 6px;
}
.local-menu .sub-menu {
  position: static !important;
  display: block !important;
  opacity: 1 !important;
  visibility: visible !important;
  box-shadow: none !important;
}
.local-simple-header a:focus,
button:focus-visible,
a:focus-visible,
input:focus-visible {
  outline: 3px solid #514785;
  outline-offset: 3px;
}
.local-hero h2 {
  margin: 0;
}
@media (max-width: 767px) {
  .local-hero {
    height: 310px;
    min-height: 0;
  }
  .local-hero h2 {
    font-size: 22px;
  }
  .local-hero img {
    object-position: 40%;
  }
  .local-simple-header {
    flex-wrap: wrap;
    gap: 12px;
  }
  .local-notice {
    font-size: 10px;
  }
  .local-hero button {
    font-size: 34px;
  }
  .vc_row {
    max-width: 100%;
  }
  body {
    overflow-x: hidden;
  }
  .local-page {
    margin: 10px auto;
  }
}
@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }
  * {
    animation: none !important;
    transition: none !important;
  }
}
.local-hero {
  width: 100vw;
  margin-left: calc(50% - 50vw);
}
.local-hero img,
.local-hero > div {
  flex: 0 0 50%;
  width: 50%;
  min-width: 0;
}
.local-hero img {
  object-fit: cover;
  object-position: left center;
}
.local-hero h2 {
  font-size: clamp(22px, 2.5vw, 38px);
}

.local-hero {
  height: 35.35vw;
  max-height: 700px;
  min-height: 250px;
}
.local-hero img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
  flex: none;
}
.local-hero > div {
  position: absolute;
  right: 0;
  top: 0;
  height: 100%;
  background: transparent;
}
.local-hero h2 {
  font-size: clamp(20px, 2.5vw, 38px);
}
@media (max-width: 767px) {
  .local-hero {
    height: 35.35vw;
    min-height: 180px;
  }
  .local-hero h2 {
    font-size: clamp(15px, 3vw, 24px);
  }
}

.wpex-vc-row-stretched {
  left: 0 !important;
  width: 100vw !important;
  max-width: none !important;
  margin-left: calc((100% - 100vw) / 2) !important;
  margin-right: 0 !important;
  padding-left: 0 !important;
  padding-right: 0 !important;
  box-sizing: border-box;
}
.local-hero {
  width: 100%;
  margin-left: 0;
}
.wpex-vc-row-stretched > .vc_column_container > .vc_column-inner {
  padding-left: 0;
  padding-right: 0;
}
#site-navigation li:hover > .sub-menu,
#site-navigation li:focus-within > .sub-menu {
  display: block !important;
  visibility: visible !important;
  opacity: 1 !important;
}

/* The preserved theme uses desktop-only dimensions; local controls must reflow. */
#site-navigation-wrap.local-menu {
  height: auto !important;
  min-height: 0 !important;
  margin: 0 !important;
  transform: none !important;
  width: 100% !important;
  max-height: calc(100dvh - var(--local-menu-top, 140px)) !important;
  inset: var(--local-menu-top, 140px) 0 auto !important;
  overflow-y: auto !important;
  box-sizing: border-box;
}
.local-menu .sf-menu > li {
  float: none !important;
  width: 100% !important;
}
.local-menu .sf-menu a {
  white-space: normal !important;
  height: auto !important;
  line-height: 1.5 !important;
  padding: 8px !important;
}
@media (max-width: 1199px) {
  #site-navigation-wrap:not(.local-menu) {
    display: none !important;
  }
  #mobile-menu,
  #wpex-mobile-menu-navbar {
    display: block !important;
  }
  #site-logo {
    max-width: calc(100% - 60px);
  }
}
.mobile-toggle-nav.wpex-mobile-menu {
  display: none !important;
}
#content a {
  overflow-wrap: anywhere;
}
.wpb_video_wrapper:has(.local-video) {
  padding-top: 0 !important;
  height: auto !important;
}
.local-hero button {
  width: 44px;
  height: 44px;
  min-height: 44px;
  padding: 0;
  line-height: 1;
  top: 50%;
  transform: translateY(-50%);
}
.local-hero .slide-prev {
  left: 0;
}
.local-hero .slide-next {
  right: 0;
}
.local-hero.no-caption > div {
  display: none;
}
.local-hero.caption-left > div {
  left: 0;
  right: auto;
  padding: 0 8px 0 44px;
}
.local-hero.caption-bottom > div {
  left: 0;
  right: 0;
  top: auto;
  bottom: 12%;
  width: 100%;
  height: auto;
  padding: 0 44px;
}
.local-hero > div {
  padding: 0 44px 0 8px;
  box-sizing: border-box;
}
.local-gallery-open {
  width: 100vw;
  height: 100dvh;
  max-width: none;
  max-height: none;
  margin: 0;
  padding: 48px 16px 16px;
  border: 0;
  box-sizing: border-box;
  background: #000e;
}
.local-gallery-open::backdrop {
  background: #000b;
}
.local-gallery-open img {
  width: 90vw;
  height: calc(100dvh - 80px);
  object-fit: contain;
  max-height: calc(100dvh - 80px);
}
.staff-entry-position {
  color: #28754e !important;
}
.unavailable-photo {
  padding: 24px;
  background: #f3f2f7;
  color: #555064;
  border: 1px solid #d7d3e1;
}
@media (max-width: 767px) {
  .local-hero {
    min-height: 0;
    height: 35.35vw;
  }
  .local-hero h2 {
    font-size: clamp(11px, 3vw, 20px);
    line-height: 1.15;
  }
  .home #single-blocks > .vc_row:not(.wpex-vc-row-stretched) {
    max-width: none;
  }
  .home h1 {
    font-size: clamp(24px, 6.5vw, 32px) !important;
    line-height: 1.35 !important;
  }
  .vc_custom_1536641672630 {
    margin-left: 0 !important;
    margin-right: 0 !important;
  }
}

/* WP8 click-to-load video player */
.local-video-player { position: relative; width: 100%; aspect-ratio: 16 / 9; }
.local-video-player iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }

/* BEGIN WP10 accessibility fixes */
/* Current-page breadcrumb was #bcbcbc on #f7f7f7 (1.8:1); darkened to meet 4.5:1 on the grey band. */
.trail-end {
  color: #6b6b6b;
}
/* The theme removes the focus outline on its buttons; keep a visible keyboard indicator. */
.vc_btn3:focus-visible,
.theme-button:focus-visible {
  outline: 3px solid #514785 !important;
  outline-offset: 3px;
}
/* The hamburger was 22 x 30 px; give it a usable touch and pointer target without moving the icon much. */
.mobile-menu-toggle {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 44px;
  min-height: 44px;
  box-sizing: border-box;
}
/* END WP10 accessibility fixes */

/* Readable fields for both clinic forms, including autofill and dark mode. */
#local-appointment :is(input, select, textarea),
#local-contact-note :is(input, select, textarea) {
  color: #222 !important;
  background-color: #fff !important;
  caret-color: #222;
  color-scheme: light;
}
#local-appointment :is(input, textarea)::placeholder,
#local-contact-note :is(input, textarea)::placeholder {
  color: #6b6b6b !important;
  opacity: 1;
}
#local-appointment :is(input, select, textarea):focus,
#local-contact-note :is(input, select, textarea):focus {
  outline: 2px solid #333;
  outline-offset: 2px;
}
#local-appointment :is(input, select, textarea):autofill,
#local-contact-note :is(input, select, textarea):autofill {
  -webkit-text-fill-color: #222;
  box-shadow: inset 0 0 0 1000px #fff;
}
#local-appointment select option,
#local-contact-note select option {
  color: #222;
  background-color: #fff;
}

/* WP15: locally hosted class video players */
.local-class-video { max-width: 100%; height: auto; }

/* WP18: YouTube posters and contact columns. */
.wpb_video_wrapper:has(.local-video-player) { padding-top: 0 !important; height: auto !important; }
.local-video.local-video-poster { position: relative; width: 100%; aspect-ratio: 16 / 9; min-height: 0; padding: 0; overflow: hidden; }
.local-video-poster img { display: block; width: 100%; height: 100%; object-fit: cover; }
.local-video-play { position: absolute; top: 50%; left: 50%; transform: translate(-50%, -50%); width: 72px; height: 52px; border-radius: 12px; background: #b40000; }
.local-video-play::after { content: ''; position: absolute; top: 14px; left: 29px; border-top: 12px solid transparent; border-bottom: 12px solid transparent; border-left: 19px solid white; }
.local-video-poster:hover .local-video-play { background: #e00000; }
.local-video-poster:focus-visible { outline: 4px solid #362275; outline-offset: 3px; }
/* The page builder sets its video wrapper's child to position: static, which let the player cover the fallback link. */
.wpb_video_wrapper > .local-video-player { position: relative !important; }
.local-video-fallback { display: inline-block; margin-top: 8px; font-size: 0.9em; }
.local-contact-columns { display: grid; gap: 32px; }
.local-contact-columns > div { min-width: 0; }
.local-contact-columns h2:first-child { margin-top: 0; }
.local-contact-form #local-contact-note { max-width: none; width: 100%; margin: 0; padding: 0; }
@media (min-width: 768px) {
  .local-contact-columns { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 40px; }
}
/* End WP18. */

/* WP17: center the thank-you message between the header and footer. */
body:has(.local-thank-you):not(:has(.local-notice)) {
  padding-top: 0 !important;
}
body:has(.local-thank-you) #main {
  display: flex;
  align-items: center;
  background: #f7f7f7;
}
body:has(.local-thank-you) #content-wrap {
  width: 100%;
  max-width: none;
  margin: 0;
  padding: 16px;
}
body:has(.local-thank-you) #content {
  width: 100%;
}
.local-thank-you {
  box-sizing: border-box;
  width: 100%;
  max-width: 640px;
  margin: 0 auto;
  background: #fff;
  padding: 40px;
  border-radius: 25px;
}
.local-thank-you a {
  color: #00699f;
}

/* WP25: keep the footer at the bottom when content is short. */
body {
  display: flex;
  flex-direction: column;
  min-height: 100vh;
  min-height: 100dvh;
  box-sizing: border-box;
}
#outer-wrap,
#wrap {
  display: flex;
  flex-direction: column;
  flex: 1 0 auto;
}
#main {
  flex: 1 0 auto;
}

/* WP23: center PayPal's own block (title, price, description, buttons) under the QR code. PayPal styles these by id, hence !important. */
.local-paypal-or { margin: 0; text-align: center; font-weight: 700; letter-spacing: 0.08em; color: #555; }
.local-paypal-button [id^="paypal-form-fields-container-"] { justify-content: center !important; align-items: center !important; }
.local-paypal-button [id^="form-container-"] { margin-left: auto !important; margin-right: auto !important; text-align: center !important; }
.local-paypal-button .item-header { align-items: center !important; justify-content: center !important; }
.local-paypal-button .item-header .item-title,
.local-paypal-button .item-header .price-container,
.local-paypal-button .item-header .discount-text,
.local-paypal-button .item-description { text-align: center !important; }
.local-paypal-button .item-header #price-label { justify-content: center !important; }
/* On phones the theme caps page-builder rows at max-width: 100% while keeping their -15px side margins, which shifts the content 15px left of center. */
.single-page-content:has(.local-paypal) .vc_row { max-width: none !important; }
/* End WP23. */
