/* Shared layout for the six Community destination pages. */

#main-content:has(> .rmc-community-subpage) {
  width: 100%;
  max-width: none;
  padding: 0;
}

#Content.rmc-community-subpage {
  --community-subpage-stone: #f0ebe4;
  --community-subpage-border: #dfd7cb;
  --community-subpage-teal: #10383b;
  --community-subpage-gold: #efc474;
  min-height: 100%;
  padding: 0 0 clamp(2.5rem, 7vw, 4.5rem);
  background: var(--community-subpage-stone);
  color: #243d40;
}

.rmc-community-subpage-hero-inner,
.rmc-community-subpage-content {
  width: min(calc(100% - 2 * var(--rmc-page-gutter)), 72rem);
  margin-inline: auto;
}

.rmc-community-subpage-content {
  padding-top: clamp(1.25rem, 3.3vw, 3rem);
}

/* Each WebP supplies its own dark fade. */
.rmc-community-subpage-hero {
  display: flex;
  align-items: center;
  min-height: clamp(22rem, 30vw, 30rem);
  padding-block: clamp(2rem, 4vw, 3.5rem);
  background: var(--community-subpage-teal) var(--community-subpage-image) left center / cover no-repeat;
  color: #fff;
  text-align: left;
}

.rmc-community-subpage-hero .rmc-community-subpage-eyebrow {
  margin: 0 0 0.65rem;
  color: var(--community-subpage-gold);
  font-size: 0.875rem;
  font-weight: 700;
  line-height: 1.4;
  letter-spacing: 0.16em;
  text-transform: uppercase;
}

.rmc-community-subpage-hero h1 {
  max-width: 34rem;
  margin: 0;
  color: #fff;
  font-family: Georgia, "Times New Roman", serif;
  font-size: clamp(2.625rem, 4.2vw, 3.625rem);
  font-weight: 400;
  line-height: 1.08;
  letter-spacing: -0.025em;
  text-wrap: balance;
}

.rmc-community-subpage-hero .rmc-community-subpage-description {
  max-width: 28rem;
  margin: 0.875rem 0 0;
  color: #fff;
  font-size: clamp(0.9375rem, 2vw, 1.0625rem);
  font-weight: 600;
  line-height: 1.6;
}

.rmc-community-subpage-hero :is(h1, p) {
  text-shadow: 0 1px 4px rgba(0, 0, 0, 0.8);
}

.rmc-community-subpage-hero .rmc-community-subpage-back {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 44px;
  margin-top: 1.125rem;
  padding: 0.625rem 1rem;
  border: 1px solid transparent;
  border-radius: var(--rmc-radius-sm);
  background: var(--community-subpage-gold);
  color: #17383d;
  font-size: 0.9375rem;
  font-weight: 700;
  line-height: 1.3;
  text-decoration: none;
}

.rmc-community-subpage-hero .rmc-community-subpage-back:hover {
  background: #ddb05f;
}

.rmc-community-subpage-hero .rmc-community-subpage-back:focus-visible {
  outline: 2px solid #fff;
  outline-offset: 3px;
}

@media (max-width: 767px) {
  .rmc-community-subpage-hero {
    display: block;
    min-height: 0;
    padding: 0;
    background: var(--community-subpage-teal);
  }

  .rmc-community-subpage-hero::before {
    display: block;
    height: 200px;
    background: var(--community-subpage-image) right center / cover no-repeat;
    content: "";
  }

  .rmc-community-subpage-hero-inner {
    padding-block: 1.375rem 1.25rem;
  }

  .rmc-community-subpage-hero h1 {
    font-size: clamp(1.625rem, 8.5vw, 2.75rem);
    line-height: 1.1;
    text-wrap: wrap;
  }

  .rmc-community-subpage-hero :is(h1, p) {
    text-shadow: none;
  }

  .rmc-community-subpage-hero .rmc-community-subpage-description {
    display: none;
  }

  .rmc-community-subpage-hero .rmc-community-subpage-back {
    width: 100%;
    margin-top: 0.875rem;
  }
}
