/* ANYONE HOME — EVENTS */

:where(.ah-events-hero, .ah-events-library) {
  --ah-events-navy: #04182a;
  --ah-events-ink: #09213f;
  --ah-events-blue: #076f9c;
  --ah-events-lime: #87cf36;
  --ah-events-muted: #53677a;
  position: relative;
  isolation: isolate;
}

/* :where(.ah-events-hero, .ah-events-library) :is(h1, h2, h3, p, a) {
  font-family: "Manrope", sans-serif;
} */

:where(.ah-events-hero, .ah-events-library) :is(h1, h2, h3) {
  font-weight: 700;
}

.ah-events-hero .et_pb_row,
.ah-events-library .et_pb_row {
  position: relative;
  z-index: 2;
  width: min(90%, 1300px) !important;
  max-width: 1300px !important;
}

/* 01 — HERO / FEATURED EVENT */

.ah-events-hero.et_pb_section {
  overflow: hidden;
  padding: clamp(155px, 11vw, 190px) 0 clamp(106px, 9vw, 140px) !important;
  background: #04182a !important;
  color: #fff;
}

.ah-events-hero::before {
  content: "";
  position: absolute;
  inset: 0;
  background:
    radial-gradient(
      ellipse 49% 57% at 87% 33%,
      rgba(7, 111, 156, 0.3),
      transparent 73%
    ),
    radial-gradient(
      ellipse 44% 35% at 5% 12%,
      rgba(135, 207, 54, 0.095),
      transparent 78%
    ),
    repeating-linear-gradient(
      90deg,
      rgba(255, 255, 255, 0.018) 0 1px,
      transparent 1px 170px
    );
  pointer-events: none;
}

.ah-events-hero::after {
  content: "";
  position: absolute;
  top: -240px;
  right: -330px;
  width: min(78vw, 960px);
  aspect-ratio: 1;
  border: 1px solid rgba(135, 207, 54, 0.16);
  border-radius: 50%;
  box-shadow: 0 0 0 115px rgba(7, 111, 156, 0.018);
  pointer-events: none;
}

.ah-events-hero__intro.et_pb_row {
  margin-bottom: clamp(60px, 6vw, 88px) !important;
}

.ah-events-hero__title {
  text-align: center;
}

.ah-events-hero__title h1 {
  max-width: 1090px;
  margin: 0 auto !important;
  padding: 0 !important;
  color: #fff !important;
  font-size: clamp(57px, 6vw, 94px) !important;
  font-weight: 700 !important;
  line-height: 0.99 !important;
  letter-spacing: -0.045em !important;
  text-transform: uppercase;
  text-wrap: balance;
}

/* Original "Anyone Home" remains in the H1 as a subtle eyebrow. */
.ah-events-hero__title h1 > span:first-child {
  display: block;
  margin-bottom: 22px;
  color: var(--ah-events-lime) !important;
  font-size: 13px;
  font-weight: 700;
  line-height: 1.4;
  letter-spacing: 2.6px;
  text-transform: uppercase;
}

/* Hide the original line break visually after making the first span a block. */
.ah-events-hero__title h1 > br {
  display: none;
}

.ah-events-hero__title h1 > span:nth-of-type(2) {
  color: #fff !important;
}
.ah-events-hero__title h1 .green {
  color: var(--ah-events-lime) !important;
}

/* Remove default Divi column float rules for the feature card only. */
.ah-events-featured.et_pb_row {
  display: flex !important;
  align-items: center;
  gap: clamp(34px, 5vw, 78px);
  padding: clamp(30px, 4.5vw, 66px) !important;
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: 32px;
  background: linear-gradient(
    125deg,
    rgba(16, 65, 92, 0.87),
    rgba(7, 37, 61, 0.86) 63%,
    rgba(9, 44, 62, 0.91)
  );
  box-shadow: 0 40px 105px rgba(0, 0, 0, 0.2);
  backdrop-filter: blur(7px);
}

.ah-events-featured > .et_pb_column {
  float: none !important;
  flex: 1 1 0;
  min-width: 0;
  width: auto !important;
  margin: 0 !important;
}
.ah-events-featured > .et_pb_column:first-child {
  flex: 1.03 1 0;
}
.ah-events-featured > .et_pb_column:last-child {
  flex: 1 1 0;
}

.ah-events-featured__copy {
  margin-bottom: 28px !important;
}
.ah-events-featured__copy .blue-rect {
  display: inline-flex;
  align-items: center;
  width: auto !important;
  margin: 0 0 24px !important;
  padding: 9px 13px !important;
  color: #04182a !important;
  background: #87cf36 !important;
  border-radius: 5px;
  font-size: 12px !important;
  font-weight: 700 !important;
  line-height: 1.3 !important;
  letter-spacing: 1.8px;
  text-transform: uppercase;
}

.ah-events-featured__copy h2 {
  max-width: 610px;
  margin: 0 0 24px !important;
  padding: 0 !important;
  color: #fff !important;
  font-size: clamp(37px, 4vw, 62px) !important;
  font-weight: 700 !important;
  line-height: 1.06 !important;
  letter-spacing: -0.038em !important;
  text-transform: uppercase;
  text-wrap: balance;
}
.ah-events-featured__copy h2 span {
  color: #fff !important;
}
.ah-events-featured__copy .sub-text,
.ah-events-featured__copy .inline-text-byline {
  margin: 0 !important;
  padding: 0 !important;
}
.ah-events-featured__copy .inline-text-byline {
  color: rgba(255, 255, 255, 0.68);
  font-size: 14px;
  line-height: 1.6;
  letter-spacing: 0.01em;
}
.ah-events-featured__copy .inline-text-byline em {
  font-style: normal;
}
.ah-events-featured__copy .inline-text-padding {
  max-width: 540px;
  margin: 22px 0 0 !important;
  color: rgba(255, 255, 255, 0.8);
  font-size: 17px;
  font-weight: 400;
  line-height: 1.7;
}
.ah-events-featured__copy .inline-text-padding span {
  color: inherit !important;
}

.ah-events-featured__cta {
  margin: 0 !important;
}
.ah-events-featured__cta .cta-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 51px;
  padding: 15px 24px !important;
  border: 1px solid transparent;
  border-radius: 8px;
  color: #05233a !important;
  background: #87cf36 !important;
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 0.4px;
  line-height: 1.2;
  text-decoration: none !important;
  text-transform: uppercase;
  transition:
    transform 220ms ease,
    background-color 220ms ease,
    box-shadow 220ms ease;
  box-shadow: 0 16px 32px rgba(0, 0, 0, 0.16);
}
.ah-events-featured__cta .cta-button:hover {
  transform: translateY(-3px);
  background: #a1e453 !important;
  box-shadow: 0 20px 36px rgba(0, 0, 0, 0.23);
}
.ah-events-featured__cta .cta-button:focus-visible {
  outline: 3px solid #fff;
  outline-offset: 4px;
}

.ah-events-featured__image {
  position: relative;
  width: 100%;
  margin: 0 !important;
  filter: drop-shadow(0 25px 32px rgba(0, 0, 0, 0.24));
}
.ah-events-featured__image::before {
  content: "";
  position: absolute;
  z-index: -1;
  inset: -15px -17px 15px 17px;
  border: 1px solid rgba(135, 207, 54, 0.4);
  border-radius: 24px;
  transform: rotate(2deg);
  pointer-events: none;
}
.ah-events-featured__image .et_pb_image_wrap {
  display: block;
  overflow: hidden;
  width: 100%;
  border-radius: 20px;
}
.ah-events-featured__image img {
  display: block;
  width: 100%;
  height: auto;
  aspect-ratio: 2 / 1;
  object-fit: contain;
  transition: transform 550ms ease;
}
.ah-events-featured__image:hover img {
  transform: scale(1.025);
}

/* 02 — WEBINAR LIBRARY */

.ah-events-library.et_pb_section {
  overflow: hidden;
  padding: clamp(90px, 8vw, 130px) 0 clamp(104px, 10vw, 156px) !important;
  background: #f6fafc !important;
}
.ah-events-library::before {
  content: "";
  position: absolute;
  top: -440px;
  right: -260px;
  width: 750px;
  aspect-ratio: 1;
  border: 1px solid rgba(7, 111, 156, 0.1);
  border-radius: 50%;
  pointer-events: none;
}
.ah-events-library::after {
  content: "";
  position: absolute;
  right: -250px;
  bottom: -400px;
  width: 660px;
  height: 660px;
  border: 1px solid rgba(7, 111, 156, 0.07);
  border-radius: 50%;
  pointer-events: none;
}

.ah-events-library__headings.et_pb_row {
  text-align: center;
  margin-bottom: clamp(42px, 5vw, 68px) !important;
}

/* There are no upcoming-event modules in the source export. Keep
   the original heading, but give it a lightweight editorial treatment. */
.ah-events-library__upcoming {
  position: relative;
  margin: 0 auto clamp(62px, 7vw, 100px) !important;
  padding: 0 0 35px !important;
  border-bottom: 1px solid rgba(9, 33, 63, 0.11);
}
.ah-events-library__upcoming::after {
  content: "";
  position: absolute;
  left: 50%;
  bottom: -2px;
  width: 68px;
  height: 3px;
  background: #076f9c;
  transform: translateX(-50%);
}
.ah-events-library__upcoming h2 {
  margin: 0 !important;
  padding: 0 !important;
  color: var(--ah-events-ink) !important;
  font-size: clamp(26px, 2.6vw, 39px) !important;
  font-weight: 700 !important;
  letter-spacing: -0.035em;
  line-height: 1.1;
  text-transform: uppercase;
}
.ah-events-library__upcoming h2 span {
  color: var(--ah-events-lime) !important;
}

.ah-events-library__webinars-title h2 {
  max-width: 1040px;
  margin: 0 auto !important;
  padding: 0 !important;
  color: var(--ah-events-ink) !important;
  font-size: clamp(47px, 5vw, 70px) !important;
  font-weight: 700 !important;
  letter-spacing: -0.042em !important;
  line-height: 1.02 !important;
  text-transform: uppercase;
  text-wrap: balance;
}
.ah-events-library__webinars-title h2 span {
  color: var(--ah-events-lime) !important;
}

/* EVENTS — EDITORIAL WEBINAR SHOWCASE */
.ah-events-webinars-showcase.et_pb_row {
  margin: 0 auto !important;
  padding: 0 !important;
}
.ah-events-webinars-showcase__items.et_pb_column {
  display: grid !important;
  grid-template-columns: minmax(0, 1.12fr) minmax(0, 1fr);
  grid-template-rows: repeat(4, minmax(165px, auto));
  gap: 18px !important;
  width: 100% !important;
  float: none !important;
  margin: 0 !important;
  padding: 0 !important;
  align-items: stretch;
}
.ah-events-webinars-showcase__items > .et_pb_blog {
  min-width: 0;
  min-height: 0;
  width: 100%;
  margin: 0 !important;
}
.ah-events-webinars-showcase__items > .et_pb_blog:first-child {
  grid-column: 1;
  grid-row: 1 / span 4;
}
.ah-events-webinars-showcase__items > .et_pb_blog:nth-child(n + 2) {
  grid-column: 2;
}
.ah-events-webinars-showcase__items .et_pb_ajax_pagination_container,
.ah-events-webinars-showcase__items .et_pb_posts {
  height: 100%;
}
.ah-events-webinars-showcase__items .et_pb_post {
  position: relative;
  height: 100%;
  margin: 0 !important;
  overflow: hidden;
  transition:
    border-color 240ms ease,
    box-shadow 240ms ease,
    transform 240ms ease;
}
.ah-events-webinars-showcase__items .et_pb_post:hover {
  transform: translateY(-3px);
}
.ah-events-webinars-showcase__items .et_pb_image_container {
  margin: 0 !important;
}
.ah-events-webinars-showcase__items .entry-featured-image-url {
  display: block;
  overflow: hidden;
  margin: 0 !important;
}
.ah-events-webinars-showcase__items .entry-featured-image-url img {
  display: block;
  width: 100%;
  object-fit: cover;
  transition: transform 450ms ease;
}
.ah-events-webinars-showcase__items
  .et_pb_post:hover
  .entry-featured-image-url
  img {
  transform: scale(1.045);
}
.ah-events-webinars-showcase__items .entry-title {
  margin: 0 !important;
  font-weight: 700 !important;
  letter-spacing: -0.035em !important;
  line-height: 1.2 !important;
}
.ah-events-webinars-showcase__items .entry-title a {
  color: inherit !important;
  text-decoration: none !important;
}
.ah-events-webinars-showcase__items .post-meta {
  margin: 0 !important;
  font-size: 11px !important;
  font-weight: 700 !important;
  letter-spacing: 0.06em;
  line-height: 1.5;
  text-transform: uppercase;
}
.ah-events-webinars-showcase__items .post-content {
  min-width: 0;
  margin: 0 !important;
  font-size: 14px;
  line-height: 1.6;
}
.ah-events-webinars-showcase__items .post-content p {
  margin: 0 !important;
  padding: 0 !important;
  font-size: inherit !important;
  line-height: inherit !important;
}
.ah-events-webinars-showcase__items .more-link {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  width: fit-content;
  font-size: 12px;
  font-weight: 700;
  text-decoration: none !important;
}
.ah-events-webinars-showcase__items .more-link::after {
  content: "↗";
  font-size: 16px;
}
.ah-events-webinars-showcase__items a:focus-visible {
  outline: 3px solid #076f9c;
  outline-offset: 3px;
}

/* Main webinar takes the visual spotlight: full-size image, large title,
   and a dark card that ties back to the Events hero. */
.ah-events-webinars-showcase__items > .et_pb_blog:first-child .et_pb_post {
  display: flex;
  flex-direction: column;
  min-height: 100%;
  border: 1px solid rgba(7, 111, 156, 0.22);
  border-radius: 24px;
  background: linear-gradient(153deg, #0a4363 0%, #052940 60%, #04182a 100%);
  box-shadow: 0 28px 75px rgba(5, 35, 58, 0.2);
  color: #fff;
}
.ah-events-webinars-showcase__items
  > .et_pb_blog:first-child
  :is(.et_pb_image_container, .entry-featured-image-url) {
  width: 100%;
}
.ah-events-webinars-showcase__items
  > .et_pb_blog:first-child
  .entry-featured-image-url
  img {
  aspect-ratio: 16 / 9;
  height: auto;
}
.ah-events-webinars-showcase__items > .et_pb_blog:first-child .entry-title {
  padding: 32px 32px 12px !important;
  color: #fff !important;
  font-size: clamp(30px, 3vw, 42px) !important;
}
.ah-events-webinars-showcase__items > .et_pb_blog:first-child .post-meta {
  padding: 0 32px !important;
  color: rgba(199, 228, 240, 0.72) !important;
}
.ah-events-webinars-showcase__items > .et_pb_blog:first-child .post-content {
  display: flex;
  flex-direction: column;
  flex: 1 1 auto;
  padding: 18px 32px 30px !important;
  color: rgba(236, 248, 252, 0.84);
  font-size: 16px;
  line-height: 1.75;
}
.ah-events-webinars-showcase__items > .et_pb_blog:first-child .post-content p {
  color: inherit;
}
.ah-events-webinars-showcase__items > .et_pb_blog:first-child .more-link {
  margin-top: 20px !important;
  color: #87cf36 !important;
  font-size: 14px;
}
.ah-events-webinars-showcase__items
  > .et_pb_blog:first-child
  .et_pb_post:hover {
  box-shadow: 0 35px 85px rgba(5, 35, 58, 0.28);
}
.ah-events-webinars-showcase__items > .et_pb_blog:first-child a:focus-visible {
  outline-color: #87cf36;
}

/* Four supporting webinars become compact editorial rows instead of
   repeating the same full-sized blog card layout. */
.ah-events-webinars-showcase__items > .et_pb_blog:nth-child(n + 2) .et_pb_post {
  display: grid;
  grid-template-columns: minmax(145px, 39%) minmax(0, 1fr);
  grid-template-rows: min-content min-content 1fr;
  column-gap: 0;
  min-height: 165px;
  border: 1px solid rgba(7, 111, 156, 0.12);
  border-radius: 18px;
  background: #fff;
  box-shadow: 0 14px 36px rgba(9, 33, 63, 0.055);
}
.ah-events-webinars-showcase__items
  > .et_pb_blog:nth-child(n + 2)
  .et_pb_post:hover {
  border-color: rgba(7, 111, 156, 0.3);
  box-shadow: 0 19px 47px rgba(9, 33, 63, 0.12);
}
.ah-events-webinars-showcase__items
  > .et_pb_blog:nth-child(n + 2)
  .et_pb_image_container,
.ah-events-webinars-showcase__items
  > .et_pb_blog:nth-child(n + 2)
  .entry-featured-image-url {
  grid-column: 1;
  grid-row: 1 / 5;
  width: 100%;
  height: 100%;
  min-height: 165px;
}
.ah-events-webinars-showcase__items
  > .et_pb_blog:nth-child(n + 2)
  .entry-featured-image-url
  img {
  height: 100%;
  min-height: 165px;
  aspect-ratio: auto;
  object-fit: contain;
  background: #082d43;
}
.ah-events-webinars-showcase__items
  > .et_pb_blog:nth-child(n + 2)
  .entry-title {
  grid-column: 2;
  grid-row: 1;
  padding: 17px 19px 6px !important;
  color: #09213f !important;
  font-size: clamp(17px, 1.4vw, 20px) !important;
}
.ah-events-webinars-showcase__items > .et_pb_blog:nth-child(n + 2) .post-meta {
  grid-column: 2;
  grid-row: 2;
  padding: 0 19px !important;
  color: #668094 !important;
}
.ah-events-webinars-showcase__items
  > .et_pb_blog:nth-child(n + 2)
  .post-content {
  grid-column: 2;
  grid-row: 3;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  padding: 8px 19px 17px !important;
  color: #53677a;
  font-size: 13px;
}
.ah-events-webinars-showcase__items
  > .et_pb_blog:nth-child(n + 2)
  .post-content-inner {
  display: -webkit-box;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
  overflow: hidden;
  margin-bottom: 12px;
}
.ah-events-webinars-showcase__items > .et_pb_blog:nth-child(n + 2) .more-link {
  color: #076f9c !important;
}

/* Right-hand thumbnails include lettering; keep the entire artwork legible. */
.ah-events-webinars-showcase__items
  > .et_pb_blog:nth-child(n + 2)
  .et_pb_post:hover
  .entry-featured-image-url
  img {
  transform: none;
}

/* 03 — RESPONSIVE */

@media (max-width: 1100px) and (min-width: 981px) {
  .ah-events-featured.et_pb_row {
    gap: 30px;
  }
  .ah-events-featured__copy h2 {
    font-size: clamp(37px, 3.6vw, 46px) !important;
  }
  .ah-events-webinars-showcase__items.et_pb_column {
    gap: 18px !important;
  }
}

@media (max-width: 980px) {
  .ah-events-hero.et_pb_section {
    padding: 155px 0 90px !important;
  }
  .ah-events-hero__intro.et_pb_row {
    margin-bottom: 54px !important;
  }
  .ah-events-hero__title h1 {
    font-size: clamp(51px, 8vw, 78px) !important;
  }
  .ah-events-featured.et_pb_row {
    display: flex !important;
    flex-direction: column;
    gap: 44px;
    padding: 44px !important;
  }
  .ah-events-featured > .et_pb_column {
    flex: 0 1 auto !important;
    width: 100% !important;
  }
  .ah-events-featured__copy h2 {
    max-width: 100%;
  }
  .ah-events-featured__image {
    max-width: 780px;
    margin: 0 auto !important;
  }
  .ah-events-webinars-showcase__items.et_pb_column {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    grid-template-rows: auto;
    gap: 22px !important;
  }
  .ah-events-webinars-showcase__items > .et_pb_blog:first-child {
    grid-column: 1 / -1;
    grid-row: auto;
  }
  .ah-events-webinars-showcase__items > .et_pb_blog:nth-child(n + 2) {
    grid-column: auto;
  }
  .ah-events-webinars-showcase__items
    > .et_pb_blog:nth-child(n + 2)
    .et_pb_post {
    display: flex;
    flex-direction: column;
    min-height: 100%;
    padding-bottom: 22px !important;
    border: 1px solid rgba(7, 111, 156, 0.11);
    border-radius: 18px;
    background: #fff;
  }
  .ah-events-webinars-showcase__items
    > .et_pb_blog:nth-child(n + 2)
    .et_pb_image_container,
  .ah-events-webinars-showcase__items
    > .et_pb_blog:nth-child(n + 2)
    .entry-featured-image-url {
    width: 100%;
    height: auto;
    grid-row: auto;
    grid-column: auto;
    border-radius: 0;
  }
  .ah-events-webinars-showcase__items
    > .et_pb_blog:nth-child(n + 2)
    .entry-featured-image-url
    img {
    aspect-ratio: 16 / 9;
    height: auto;
  }
  .ah-events-webinars-showcase__items
    > .et_pb_blog:nth-child(n + 2)
    :is(.entry-title, .post-meta, .post-content) {
    grid-column: auto;
    grid-row: auto;
    padding: 0 20px;
  }
  .ah-events-webinars-showcase__items
    > .et_pb_blog:nth-child(n + 2)
    .entry-title {
    padding-top: 18px;
  }

  .ah-events-library.et_pb_section {
    padding: 92px 0 110px !important;
  }
}

@media (max-width: 767px) {
  .ah-events-hero.et_pb_section {
    padding: 132px 0 74px !important;
  }
  .ah-events-hero__title h1 {
    font-size: clamp(40px, 10.2vw, 60px) !important;
    letter-spacing: -0.045em !important;
  }
  .ah-events-hero__title h1 > span:first-child {
    font-size: 12px;
    margin-bottom: 16px;
    letter-spacing: 2px;
  }
  .ah-events-hero__intro.et_pb_row {
    margin-bottom: 42px !important;
  }
  .ah-events-featured.et_pb_row {
    padding: 24px !important;
    border-radius: 23px;
    gap: 28px;
  }
  .ah-events-featured__copy {
    margin-bottom: 18px !important;
  }
  .ah-events-featured__copy h2 {
    font-size: clamp(33px, 8vw, 48px) !important;
  }
  .ah-events-featured__copy .inline-text-padding {
    font-size: 16px;
  }
  .ah-events-featured__image::before {
    inset: -8px -7px 8px 7px;
    border-radius: 18px;
  }
  .ah-events-featured__image .et_pb_image_wrap {
    border-radius: 14px;
  }
  .ah-events-library.et_pb_section {
    padding: 78px 0 96px !important;
  }
  .ah-events-library__upcoming {
    margin-bottom: 70px !important;
  }
  .ah-events-library__upcoming h2 {
    font-size: 29px !important;
  }
  .ah-events-library__webinars-title h2 {
    font-size: clamp(39px, 9vw, 58px) !important;
  }
  .ah-events-library__headings.et_pb_row {
    margin-bottom: 38px !important;
  }
  .ah-events-webinars-showcase__items.et_pb_column {
    grid-template-columns: 1fr;
    gap: 18px !important;
  }
  .ah-events-webinars-showcase__items > .et_pb_blog:first-child {
    grid-column: auto;
  }
  .ah-events-webinars-showcase__items > .et_pb_blog:first-child .entry-title {
    font-size: 30px !important;
  }

  .ah-events-webinars-showcase__items .entry-title {
    font-size: 22px !important;
  }
}

@media (prefers-reduced-motion: reduce) {
  .ah-events-featured__cta .cta-button,
  .ah-events-featured__image img,
  .ah-events-webinars-showcase__items .et_pb_post,
  .ah-events-webinars-showcase__items .entry-featured-image-url img {
    transition: none !important;
  }
  .ah-events-webinars-showcase__items .et_pb_post:hover,
  .ah-events-featured__cta .cta-button:hover {
    transform: none !important;
  }
}
