.half-width-card,
.half-width-card *,
.half-width-card *::before,
.half-width-card *::after {
  box-sizing: border-box;
}

/*
 * Keep the Paragraph and the common Layout Builder inline-block wrappers at
 * equal height when two cards share a row.
 */
.block-inline-blockhalf-width-card-block,
.block-inline-blockhalf-width-card {
  display: flex;
  min-width: 0;
  flex-direction: column;
}

.block-inline-blockhalf-width-card-block > .content,
.block-inline-blockhalf-width-card > .content {
  display: flex;
  width: 100%;
  min-width: 0;
  flex: 1 1 auto;
  flex-direction: column;
}

.block-inline-blockhalf-width-card-block .paragraph--type--half-width-card,
.block-inline-blockhalf-width-card .paragraph--type--half-width-card {
  flex: 1 1 auto;
}

.half-width-card {
  --half-width-card-background: #ffffff;
  --half-width-card-alternate: #003479;
  --half-width-card-body: var(--half-width-card-alternate);
  --half-width-card-tertiary: var(--half-width-card-background);

  display: flex;
  width: 100%;
  height: 100%;
  min-width: 0;
  padding: 12px 24px 12px 0;
  color: var(--half-width-card-body);
  background-color: var(--half-width-card-background);
}

.half-width-card__inner {
  position: relative;
  display: flex;
  width: 100%;
  min-width: 0;
  flex: 1 1 auto;
  flex-direction: column;
  align-items: flex-start;
  gap: 16px;
  padding-left: 17px;
}

/*
 * The rule belongs to the full inner card rather than an individual text
 * element, so it grows with an equal-height sibling card.
 */
.half-width-card__inner::before {
  position: absolute;
  top: 0;
  bottom: 0;
  left: 0;
  width: 1px;
  background-color: var(--half-width-card-alternate);
  content: "";
  opacity: 0.35;
}

.half-width-card__title {
  min-width: 0;
  margin: 0;
  color: var(--half-width-card-alternate);
  font-family: "Helvetica Neue", Helvetica, Arial, sans-serif;
  font-size: 24px;
  font-style: normal;
  font-weight: 700;
  line-height: 31px;
  overflow-wrap: anywhere;
}

.half-width-card__body {
  min-width: 0;
  color: var(--half-width-card-body);
  font-family: "Nunito Sans", Arial, sans-serif;
  font-size: 18px;
  font-style: normal;
  font-weight: 400;
  line-height: 27px;
  overflow-wrap: anywhere;
}

.half-width-card__body .field,
.half-width-card__body .field__item {
  margin: 0;
}

.half-width-card__body :first-child {
  margin-top: 0;
}

.half-width-card__body :last-child {
  margin-bottom: 0;
}

.half-width-card__body p {
  margin: 0 0 12px;
}

.half-width-card__link {
  display: inline-flex;
  width: 28px;
  height: 28px;
  flex: 0 0 28px;
  align-items: center;
  justify-content: center;
  border: 2px solid var(--half-width-card-alternate);
  border-radius: 50%;
  color: var(--half-width-card-alternate);
  background-color: transparent;
  text-decoration: none;
  transition:
    color 160ms ease,
    background-color 160ms ease;
}

.half-width-card__icon {
  display: block;
  width: 18px;
  height: 18px;
  fill: none;
  stroke: currentColor;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-width: 2;
}

.half-width-card__link:hover,
.half-width-card__link:active {
  border-color: var(--half-width-card-alternate);
  color: var(--half-width-card-tertiary);
  background-color: var(--half-width-card-alternate);
  text-decoration: none;
}

.half-width-card__link:focus-visible {
  border-color: var(--half-width-card-alternate);
  outline: 3px solid #ffbf47;
  outline-offset: 3px;
  color: var(--half-width-card-tertiary);
  background-color: var(--half-width-card-alternate);
}

/* Tablet uses the mobile type scale and the layout stacks to full width. */
@media (max-width: 991px) {
  .half-width-card {
    padding: 16px;
  }

  .half-width-card__title {
    font-size: 20px;
    line-height: 26px;
  }

  .half-width-card__body {
    font-size: 16px;
    line-height: 24px;
  }
}

@media (prefers-reduced-motion: reduce) {
  .half-width-card__link {
    transition: none;
  }
}

@media (forced-colors: active) {
  .half-width-card__inner::before {
    background-color: CanvasText;
    opacity: 1;
  }

  .half-width-card__link {
    border-color: LinkText;
    color: LinkText;
  }
}

