/**
 * Template A — CMS image frames (cover / contain, gap-free)
 */

@media (min-width: 768px) {
  body.cms-active-template-templateA .ta-template-a-page .ta-hero-shell.ta-hero-fullbleed.ta-hero-shell--has-bg {
    background-size: contain !important;
    background-position: center center !important;
    background-repeat: no-repeat !important;
    background-color: var(--dark) !important;
  }
}

body.cms-active-template-templateA .ta-template-a-page .ta-about-media.ta-cms-media {
  position: relative;
  width: 100%;
  aspect-ratio: 800 / 400;
  overflow: hidden;
  line-height: 0;
  background: transparent;
  padding: 0 !important;
  min-height: 0 !important;
}

body.cms-active-template-templateA .ta-template-a-page .ta-about-media-img,
body.cms-active-template-templateA .ta-template-a-page .ta-about-media-img[data-cms-field="about.image"] {
  position: absolute;
  inset: 0;
  width: 100% !important;
  height: 100% !important;
  max-width: none !important;
  max-height: none !important;
  min-height: 0 !important;
  object-fit: cover !important;
  object-position: center center !important;
  display: block;
  background: transparent !important;
}

@media (min-width: 992px) {
  body.cms-active-template-templateA .ta-template-a-page .ta-about-media.ta-cms-media {
    padding: 0 !important;
  }
}

body.cms-active-template-templateA .ta-template-a-page .ta-fact-icon-wrap.ta-cms-media {
  width: 64px;
  height: 64px;
  max-width: 64px;
  overflow: hidden;
  line-height: 0;
  display: flex;
  align-items: center;
  justify-content: center;
}

body.cms-active-template-templateA .ta-template-a-page .ta-fact-icon-wrap .ta-fact-icon-img {
  width: 100%;
  height: 100%;
  max-width: 64px;
  max-height: 64px;
  object-fit: contain;
  object-position: center center;
  display: block;
  background: transparent;
}

body.cms-active-template-templateA .ta-template-a-page .ta-facts-bg,
body.cms-active-template-templateA .ta-template-a-page .ta-cms-bg-layer {
  background-size: cover !important;
  background-position: center center !important;
  background-repeat: no-repeat !important;
}

body.cms-active-template-templateA .ta-template-a-page .ta-menu-item-media.ta-cms-media {
  width: 100%;
  aspect-ratio: 840 / 280;
  overflow: hidden;
  display: block;
  line-height: 0;
  background: #f4f6f8;
}

body.cms-active-template-templateA .ta-template-a-page .ta-menu-item-media .ta-menu-item-img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  max-width: none;
  max-height: none;
  object-fit: contain;
  object-position: center center;
  display: block;
  background: transparent;
}

body.cms-active-template-templateA .ta-template-a-page .ta-menu-item-media.ta-cms-media {
  position: relative;
}

body.cms-active-template-templateA .ta-template-a-page .ta-svc-icon-wrap.ta-cms-media,
body.cms-active-template-templateA .ta-template-a-page .ta-svc-icon-wrap.ta-cms-media[data-cms-aspect="services.items.icon_image"] {
  width: 64px !important;
  height: 64px !important;
  max-width: 64px !important;
  aspect-ratio: 1 / 1 !important;
  margin-left: auto !important;
  margin-right: auto !important;
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
  overflow: hidden;
  line-height: 0;
  background: transparent;
  padding: 0 !important;
}

body.cms-active-template-templateA .ta-template-a-page .ta-svc-icon-wrap .ta-svc-icon-img,
body.cms-active-template-templateA .ta-template-a-page .ta-svc-icon-wrap img[data-cms-field="services.items.icon_image"] {
  width: 100% !important;
  height: 100% !important;
  max-width: 64px !important;
  max-height: 64px !important;
  object-fit: contain !important;
  object-position: center center !important;
  display: block !important;
  background: transparent !important;
}

@media (max-width: 991.98px) {
  body.cms-active-template-templateA .ta-template-a-page .ta-svc-icon-wrap.ta-cms-media,
  body.cms-active-template-templateA .ta-template-a-page .ta-svc-icon-wrap.ta-cms-media[data-cms-aspect="services.items.icon_image"] {
    width: 50px !important;
    height: 50px !important;
    max-width: 50px !important;
  }

  body.cms-active-template-templateA .ta-template-a-page .ta-svc-icon-wrap .ta-svc-icon-img,
  body.cms-active-template-templateA .ta-template-a-page .ta-svc-icon-wrap img[data-cms-field="services.items.icon_image"] {
    max-width: 50px !important;
    max-height: 50px !important;
  }
}

body.cms-active-template-templateA .ta-template-a-page .ta-team-photo-media.ta-cms-media {
  aspect-ratio: 1 / 1;
  overflow: hidden;
  line-height: 0;
  background: #f4f6f8;
}

body.cms-active-template-templateA .ta-template-a-page .ta-team-photo-media .ta-team-photo-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center center;
  display: block;
  background: transparent;
}

body.cms-active-template-templateA .ta-template-a-page .ta-testimonial-avatar.ta-cms-media {
  width: 60px;
  height: 60px;
  overflow: hidden;
  border-radius: 50%;
  line-height: 0;
}

body.cms-active-template-templateA .ta-template-a-page .ta-testimonial-avatar .ta-testimonial-avatar-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center center;
  display: block;
  background: transparent;
}

body.cms-active-template-templateA .ta-template-a-page .ta-video-media.ta-cms-media {
  aspect-ratio: 960 / 480;
  overflow: hidden;
  line-height: 0;
  background: #111;
}

body.cms-active-template-templateA .ta-template-a-page .ta-video-media .ta-video-thumb-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center center;
  display: block;
  background: transparent;
}

body.cms-active-template-templateA .ta-template-a-page .ta-blog-card-media.ta-cms-media {
  width: 100%;
  aspect-ratio: 840 / 280;
  overflow: hidden;
  display: block;
  line-height: 0;
  background: #f4f6f8;
  position: relative;
}

body.cms-active-template-templateA .ta-template-a-page .ta-blog-card-media .ta-blog-card-img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  max-width: none;
  max-height: none;
  object-fit: cover;
  object-position: center center;
  display: block;
  background: transparent;
}

body.cms-active-template-templateA .ta-template-a-page .ta-offer-bg,
body.cms-active-template-templateA #app .ta-template-a-page .ta-cms-bg-frame {
  background-size: cover !important;
  background-position: center center !important;
  background-repeat: no-repeat !important;
}

body.cms-active-template-templateA #app .ta-template-a-page .ta-cms-bg-frame.ta-offer-cms-frame {
  position: relative !important;
  width: min(100%, 1200px) !important;
  max-width: 1200px !important;
  margin-left: auto !important;
  margin-right: auto !important;
  overflow: hidden !important;
  border-radius: 8px;
  background-color: var(--dark);
}

/* Offer outer shell — no theme .appointment carousel bg */
body.cms-active-template-templateA .ta-template-a-page .ta-offer-section {
  background: transparent !important;
  background-image: none !important;
}
