/* Pattern Heading block: centered heading flanked by a repeating pattern */
.pattern-heading {
  --pattern-height: clamp(1.5rem, 2.5vw, 2.5rem);
  display: flex;
  align-items: center;
  gap: clamp(1.5rem, 3vw, 3rem);
}

.pattern-heading--dots {
  --pattern-height: clamp(1.25rem, 2.2vw, 2.375rem);
}

.pattern-heading__title {
  flex: 0 1 auto;
  margin: 0;
  text-align: center;
}

.pattern-heading__fill {
  flex: 1 1 0;
  min-width: 2rem;
  height: var(--pattern-height);
  background-color: var(--pattern-color, currentColor);
  -webkit-mask-image: var(--pattern-image);
          mask-image: var(--pattern-image);
  -webkit-mask-size: auto 100%;
          mask-size: auto 100%;
  -webkit-mask-repeat: round no-repeat;
          mask-repeat: round no-repeat;
}

/* Mobile: one full-width band above the heading */
@media (max-width: 767px) {
  .pattern-heading {
    flex-direction: column;
    align-items: stretch;
  }

  .pattern-heading__fill {
    flex: none;
    width: 100%;
  }

  .pattern-heading__fill:last-child {
    display: none;
  }
}
