/* Customer Service 24/7 - C8007
   Mobile-first: vertical stack on a light neutral background, two small
   overlapping employee avatars inside the header, three stacked blue contact
   cards, full-width yellow bar CTA. */

.c8007-container .eyebrow::after {
    width: 5rem;
}

.c8007-section {
  position: relative;
  overflow: hidden;
  background-color: #f9f9f9;
  padding-top: 2.5rem;
  padding-bottom: 2.5rem;
}

.c8007-container {
  position: relative;
  z-index: 2;
}

.c8007-header {
  text-align: center;
}

.c8007-headline {
  margin-top: 1rem;
  font-family: jost-variable, sans-serif;
  font-weight: 600;
  font-size: 1.5rem;
  line-height: 1.1;
  color: #0d123d;
}

/* Rich-text wraps the headline in <p>; the global `p { font-weight: 300 }`
   base style otherwise overrides the semibold weight above. */
.c8007-headline p {
  font-weight: inherit;
  line-height: 1.25;
  padding-bottom: 0;
}

.c8007-subtext {
  margin-top: 1rem;
  font-family: "DM Sans", sans-serif;
  font-size: 0.875rem;
  line-height: 1.5;
  color: #0d123d;
  text-align: center;
}

.c8007-subtext p {
  padding-bottom: 0;
  line-height: inherit;
  color: inherit;
}

/* Two overlapping circular avatars, shown only on mobile. On desktop the
   employee photos become full-height cutouts flanking the section, and this
   block is hidden (lg:hidden). */
.c8007-mobile-avatars {
  display: flex;
  justify-content: center;
  margin-top: 1.5rem;
}

.c8007-mobile-avatar {
  position: relative;
  width: 10rem;
  height: 10rem;
  border-radius: 9999px;
  background-color: #f5f5f5;
  border: 1px solid #e7e7e7;
  overflow: hidden;
  flex-shrink: 0;
}

/* Image field's ratio="1:1" requests a Wagtail fill rendition cropped to the
   image's focal point, so the picture/img just need to fill the circle. */
.c8007-mobile-avatar picture {
  position: absolute;
  inset: 0;
}

.c8007-mobile-avatar img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

/* The right avatar overlaps the left one. */
.c8007-mobile-avatar--left {
  margin-right: -1.25rem;
}

/* Fallback path only: no dedicated mobile headshot has been set, so we're
   reusing the desktop cutout photo (framed for a tall cutout, not a circle).
   The focal-point fill rendition centers the face; scale up further so it
   reads as a headshot instead of showing shoulders/torso. Each photo's focal
   box is a different size relative to its source image, so the two sides
   need slightly different amounts of extra zoom to land on the same tight
   crop. Once a page sets image_left_mobile/image_right_mobile, none of this
   applies — that photo is expected to already be a clean headshot crop. */
.c8007-mobile-avatar--fallback img {
  transform: scale(var(--avatar-zoom, 1.3));
}

.c8007-mobile-avatar--left.c8007-mobile-avatar--fallback {
  --avatar-zoom: 1.3;
}

.c8007-mobile-avatar--right.c8007-mobile-avatar--fallback {
  --avatar-zoom: 1.7;
}

.c8007-award {
  margin-top: 1.5rem;
  padding: 1.5rem;
  border: 1px solid #cccccc;
  border-radius: 0.5rem;
  background-image: linear-gradient(236.5deg, #eaeaea 8%, #ffffff 20%, #ffffff 79%, #f7f7f7 98%);
  text-align: center;
}

.c8007-award__intro {
  font-family: jost-variable, sans-serif;
  font-weight: 700;
  font-size: 0.875rem;
  line-height: 1.3;
  letter-spacing: 0.02em;
  text-transform: uppercase;
  color: #474747;
}

.c8007-award__row {
  display: flex;
  gap: 1rem;
  align-items: center;
  justify-content: center;
  margin-top: 1rem;
  flex-wrap: wrap;
}

.c8007-award__rank {
  font-family: jost-variable, sans-serif;
  font-weight: 500;
  font-size: 2rem;
  line-height: 1;
  color: #f9a606;
}

.c8007-award__label {
  font-family: "DM Sans", sans-serif;
  font-weight: 500;
  font-size: 1rem;
  line-height: 1.5;
  color: #0d123d;
}

/* Contact cards + bar CTA cluster. On mobile the cards stack; on desktop the
   3 cards form a row and the bar CTA sits underneath at the same width. */
.c8007-actions {
  margin-top: 1.5rem;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.c8007-cards {
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
}

.c8007-card {
  display: grid;
  grid-template-columns: auto 1fr auto;
  grid-template-areas:
    "icon title arrow"
    "icon subtitle arrow";
  column-gap: 1.5rem;
  align-items: center;
  padding: 1.5rem;
  border-radius: 0.5rem;
  background-color: #0071ba;
  color: #ffffff;
  text-decoration: none;
  transition: background-color 200ms ease;
}

.c8007-card:hover,
.c8007-card:focus {
  background-color: #005a94;
  color: #ffffff;
  text-decoration: none;
}

.c8007-card__icon {
  grid-area: icon;
  color: #ffffff;
  flex-shrink: 0;
  width: 2rem;
  height: 2rem;
}

.c8007-card__title {
  grid-area: title;
  font-family: jost-variable, sans-serif;
  font-weight: 500;
  font-size: 1.25rem;
  line-height: 1.25;
  color: #ffffff;
}

.c8007-card__subtitle {
  grid-area: subtitle;
  font-family: "DM Sans", sans-serif;
  font-weight: 400;
  font-size: 0.875rem;
  line-height: 1.5;
  color: #ffffff;
}

.c8007-card__subtitle-arrow {
  display: none;
}

/* Trailing arrow — used on mobile only. Yellow to match the CTA arrow colour;
   inline SVG so it renders standalone without a network asset. */
.c8007-card__trailing-arrow {
  grid-area: arrow;
  width: 1.5rem;
  height: 1.5rem;
  color: #ffcc5b;
  flex-shrink: 0;
}

.c8007-bar-cta .btn-cta {
  display: flex;
  width: 100%;
  align-items: center;
  justify-content: center;
  border-radius: 4px;
}

/* --- Desktop --- */
@media (min-width: 1026px) {
  .c8007-section {
    padding-top: 5.5rem;
    padding-bottom: 5.5rem;
  }

  .container.c8007-container {
    max-width: none;
    padding-left: 9rem;
    padding-right: 9rem;
  }

  .c8007-header {
    max-width: 51rem;
    margin-left: auto;
    margin-right: auto;
  }

  .c8007-headline {
    margin-top: 1.5rem;
    font-family: jost-variable, sans-serif;
    font-weight: 500;
    font-size: 4rem;
    line-height: 1.1;
  }

  .c8007-subtext {
    margin-top: 1.5rem;
    font-size: 1.25rem;
    line-height: 1.6;
  }

  /* Award callout floats between the header and the actions on desktop. */
  .c8007-award {
    margin-top: 2.5rem;
    margin-left: auto;
    margin-right: auto;
    max-width: 45rem;
    padding: 1.5rem 2rem;
  }

  .c8007-award__intro {
    font-size: 0.875rem;
    letter-spacing: 0.02em;
  }

  .c8007-award__rank {
    font-size: 2rem;
  }

  .c8007-award__label {
    font-size: 1.25rem;
  }

  .c8007-actions {
    margin-top: 2.5rem;
    max-width: 67.5rem;
    margin-left: auto;
    margin-right: auto;
    gap: 1rem;
  }

  /* 3-card row on desktop; equal-width, single-line title layout inside each
     card. Trailing arrow (used on mobile) is hidden. */
  .c8007-cards {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 1rem;
  }

  .c8007-card {
    grid-template-columns: 1fr;
    grid-template-areas:
      "icon"
      "title"
      "subtitle";
    row-gap: 1.5rem;
    justify-items: center;
    text-align: center;
    padding: 1.5rem;
    min-height: 14.8125rem; /* 237.33px from Figma */
  }

  .c8007-card__icon {
    width: 2.75rem; /* 44px */
    height: 2.75rem;
  }

  .c8007-card__title {
    font-size: 1.75rem; /* 28px */
    line-height: 1.2;
  }

  .c8007-card__subtitle {
    font-size: 1rem;
  }

  /* Inline arrow at the end of the subtitle on desktop (e.g. "Start A Live
     Chat →"), replacing the mobile trailing arrow. */
  .c8007-card__trailing-arrow {
    display: none;
  }

  .c8007-card__subtitle-arrow {
    display: inline;
    margin-left: 0.25rem;
  }

  .c8007-mobile-avatars {
    display: none;
  }

  /* Bar CTA fills the same 3-card-wide row. */
  .c8007-bar-cta {
    width: 100%;
  }

  .c8007-cutout {
    position: absolute;
    width: 33.07vw;
    max-width: 634.948px;
    z-index: 1;
    pointer-events: none;
    overflow: hidden;
  }

  .c8007-cutout picture {
    position: absolute;
    inset: 0;
  }

  /* Image field's ratio="635:826" requests a Wagtail fill rendition cropped
     to the image's focal point; object-fit:cover is just a safety net for
     the box's actual height, which flexes with top/bottom rather than being
     pinned to that exact ratio. */
  .c8007-cutout img {
    width: 100%;
    height: 100%;
    object-fit: cover;
  }

  /* Inset to the nav's fluid width (component/static/component/css/navigation_update/navigation_update.css),
     same as c8011 does when it sits alone at the bottom of the page, so the
     cutout photos never extend past the nav logo (left) or Support link
     (right). */
  .c8007-cutout--left {
    left: 3rem;
    top: 25%;
    bottom: 0;
  }

  .c8007-cutout--right {
    right: 3rem;
    top: 10%;
    bottom: 0;
  }
}

@media (min-width: 1920px) {
  .container.c8007-container {
    padding-left: calc((100vw - 1584px) / 2);
    padding-right: calc((100vw - 1584px) / 2);
  }

  .c8007-cutout--left {
    left: calc((100vw - 1824px) / 2);
  }

  .c8007-cutout--right {
    right: calc((100vw - 1824px) / 2);
  }
}
