.delivery-clip-defs {
  position: absolute;
  width: 0;
  height: 0;
  overflow: hidden;
}

.delivery-section {
  margin: clamp(2rem, 4vw, 3rem) 0 0;
  padding: 0;
  --delivery-radius: calc(var(--radius) + 8px);
  --delivery-aspect: 2.45;
}

.delivery-section__list {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: clamp(0.65rem, 1.25vw, 1rem);
  align-items: start;
}

.delivery-card {
  position: relative;
  min-width: 0;
  --delivery-text-max: 52%;
  container-type: inline-size;
  container-name: delivery-card;
  border-radius: var(--delivery-radius);
  overflow: hidden;
  filter: drop-shadow(0 8px 24px color-mix(in srgb, var(--text) 8%, transparent));
  transition: filter 0.55s cubic-bezier(0.32, 0.72, 0, 1);
}

.delivery-card:hover {
  filter: drop-shadow(0 12px 28px color-mix(in srgb, var(--text) 11%, transparent));
}

.delivery-card__stage {
  position: relative;
  width: 100%;
  aspect-ratio: var(--delivery-aspect) / 1;
  isolation: isolate;
  background: var(--surface-2);
}

.delivery-card__copy,
.delivery-card__media {
  position: absolute;
  inset: 0;
}

.delivery-card__copy {
  z-index: 2;
  pointer-events: none;
}

.delivery-card__copy-bg {
  position: absolute;
  inset: 0;
  background: var(--delivery-panel, var(--brand-blue));
  clip-path: url(#deliveryClipText);
}

.delivery-card__copy-inner {
  position: relative;
  z-index: 1;
  box-sizing: border-box;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  justify-content: flex-start;
  width: var(--delivery-text-max);
  max-width: var(--delivery-text-max);
  height: 100%;
  padding: 5% 4% 12% 8%;
  color: #fff;
  overflow: visible;
}

.delivery-card__icon {
  flex: 0 0 auto;
  width: clamp(1.45rem, 12cqi, 2.5rem);
  height: clamp(1.45rem, 12cqi, 2.5rem);
  margin-top: 1%;
  color: #fff;
}

.delivery-card__icon svg {
  width: 100%;
  height: 100%;
  display: block;
}

.delivery-card__title {
  margin: auto 0 0;
  padding-top: 0.35em;
  width: 100%;
  max-width: 100%;
  font-size: clamp(0.68rem, 4.15cqi, 1.05rem);
  font-weight: 800;
  font-style: normal;
  letter-spacing: 0.025em;
  line-height: 1.14;
  text-transform: uppercase;
  color: #fff;
  overflow-wrap: break-word;
  hyphens: manual;
  text-wrap: balance;
  flex-shrink: 0;
}

@media (min-width: 901px) and (max-width: 1500px) {
  .delivery-section {
    --delivery-aspect: 2.32;
  }
}

@container delivery-card (max-width: 280px) {
  .delivery-card__title {
    font-size: clamp(0.62rem, 3.85cqi, 0.92rem);
    letter-spacing: 0.015em;
    line-height: 1.12;
  }

  .delivery-card {
    --delivery-text-max: 52%;
  }
}

@container delivery-card (min-width: 340px) {
  .delivery-card__title {
    font-size: clamp(0.78rem, 4cqi, 1.05rem);
  }
}

.delivery-card__media {
  z-index: 1;
  clip-path: url(#deliveryClipMedia);
  background: var(--surface-2);
}

.delivery-card__media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
  display: block;
}

.delivery-card__media--placeholder {
  background: linear-gradient(
    120deg,
    color-mix(in srgb, var(--delivery-panel, var(--brand-blue)) 18%, var(--surface-2)),
    var(--surface-2)
  );
}

@media (max-width: 900px) {
  .delivery-section__list {
    grid-template-columns: 1fr;
    gap: clamp(1rem, 2.5vw, 1.35rem);
  }

  .delivery-section {
    --delivery-aspect: 2.65;
  }

  .delivery-card {
    --delivery-text-max: 44%;
  }
}

@media (max-width: 720px) {
  .delivery-section {
    --delivery-aspect: 2.35;
  }

  .delivery-card {
    --delivery-text-max: 100%;
  }

  .delivery-card__copy-bg {
    clip-path: none;
    border-radius: var(--delivery-radius) var(--delivery-radius) 0 0;
  }

  .delivery-card__copy,
  .delivery-card__media {
    position: relative;
    inset: auto;
  }

  .delivery-card__media {
    clip-path: none;
  }

  .delivery-card__stage {
    display: flex;
    flex-direction: column;
    aspect-ratio: auto;
  }

  .delivery-card__copy-inner {
    width: 100%;
    max-width: 100%;
    padding: clamp(1rem, 4vw, 1.35rem);
  }

  .delivery-card__title {
    font-size: clamp(0.92rem, 4.2vw, 1.12rem);
    margin-top: 0.75rem;
    padding-top: 0;
  }

  .delivery-card__icon {
    width: clamp(2rem, 8vw, 2.65rem);
    height: clamp(2rem, 8vw, 2.65rem);
    margin-top: 0;
  }

  .delivery-card__media {
    aspect-ratio: 2.2 / 1;
    width: 100%;
  }
}
