/* Bundle tiers: one column per card (--bt-columns, set from the block count) on a subgrid so quick facts, title, price and button share rows; the contents list grows below. */
.bundle-tiers {
  --bt-black: #14130f;
  --bt-olive: #655f3b;
  --bt-flame: #c0532b;
  --bt-paper: #fffdf6;
  --bt-ink: #23211a;
  --bt-muted: #6d6853;
  --bt-line: rgba(101, 95, 59, 0.22);
  --bt-chip: rgba(101, 95, 59, 0.1);
  --bt-display: "Cormorant Garamond", "Cormorant", Garamond, "Times New Roman", serif;
  --bt-body: "Poppins", "Helvetica Neue", Arial, sans-serif;
  background-color: rgb(var(--color-background));
  color: var(--bt-black);
}

.bundle-tiers__heading {
  margin: 0 0 10px;
  font-family: var(--bt-display);
  font-weight: 500;
  font-size: clamp(28px, 3.2vw, 40px);
  line-height: 1.15;
  letter-spacing: 0.04em;
  text-align: center;
  text-wrap: balance;
}

.bundle-tiers__lede {
  max-width: 52ch;
  margin: 0 auto;
  font-family: var(--bt-body);
  font-size: 15px;
  line-height: 1.6;
  text-align: center;
  color: var(--bt-muted);
}

.bundle-tiers__grid {
  display: grid;
  grid-template-columns: repeat(var(--bt-columns, 4), minmax(0, 1fr));
  grid-template-rows: auto auto auto auto auto 1fr;
  gap: 0 20px;
  max-width: 1380px;
  margin: 44px auto 0;
  padding-top: 16px; /* room for the badge on the top edge */
}

.bundle-tiers__card {
  position: relative;
  display: grid;
  grid-row: span 6;
  grid-template-rows: subgrid;
  min-width: 0;
  background: var(--bt-paper);
  color: var(--bt-ink);
  border: 2px solid transparent;
  border-radius: 16px;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.bundle-tiers__card.is-featured {
  border-color: var(--bt-olive);
  box-shadow: 0 18px 40px -22px rgba(20, 19, 15, 0.45);
}

.bundle-tiers__badge {
  position: absolute;
  top: 0;
  left: 50%;
  z-index: 2;
  transform: translate(-50%, -50%);
  padding: 9px 16px 8px;
  border-radius: 999px;
  background: var(--bt-flame);
  color: #fff8ee;
  font: 600 12px/1 var(--bt-body);
  letter-spacing: 0.16em;
  text-transform: uppercase;
  white-space: nowrap;
  box-shadow: 0 6px 16px -6px rgba(192, 83, 43, 0.7);
}

.bundle-tiers__media {
  display: block;
  aspect-ratio: 1;
  overflow: hidden;
  border-radius: 14px 14px 0 0;
  background: #ececec;
}

.bundle-tiers__media img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.3s ease;
}

.bundle-tiers__meta {
  display: flex;
  flex-wrap: wrap;
  gap: 4px 10px;
  padding: 18px 22px 0;
  font: 500 11px/1.4 var(--bt-body);
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--bt-muted);
}

.bundle-tiers__meta span + span::before {
  content: "\00b7";
  margin-right: 10px;
}

.bundle-tiers__title {
  margin: 0;
  padding: 6px 22px 0;
  font-family: var(--bt-display);
  font-weight: 600;
  font-size: clamp(22px, 1.75vw, 27px);
  line-height: 1.12;
  text-wrap: balance;
  overflow-wrap: anywhere;
}

.bundle-tiers__title a {
  color: inherit;
  text-decoration: none;
}

/* link mode: the title link stretches over the whole card */
.bundle-tiers__card.is-linked .bundle-tiers__title a::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 1;
  border-radius: 16px;
}

.bundle-tiers__card.is-linked .bundle-tiers__title a:focus-visible {
  outline: none;
}

.bundle-tiers__card.is-linked:has(.bundle-tiers__title a:focus-visible) {
  outline: 2px solid var(--bt-flame);
  outline-offset: 3px;
}

.bundle-tiers__price-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px 12px;
  padding: 10px 22px 0;
}

.bundle-tiers__price {
  font: 500 18px/1 var(--bt-body);
  font-variant-numeric: tabular-nums;
}

.bundle-tiers__compare {
  font: 400 14px/1 var(--bt-body);
  color: var(--bt-muted);
}

.bundle-tiers__chip {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 9px;
  border-radius: 6px;
  background: var(--bt-chip);
  color: var(--bt-olive);
  font: 500 11px/1 var(--bt-body);
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.bundle-tiers__chip svg {
  flex: none;
  width: 14px;
  height: 14px;
}

.bundle-tiers__cta {
  padding: 18px 22px 0;
}

.bundle-tiers__cta .block-product-buy-button-wrapper {
  padding: 0;
}

.bundle-tiers__cta .bundle-tiers__link-button {
  z-index: 2;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  text-decoration: none;
}

.bundle-tiers__cta .block-product-buy-button {
  position: relative;
  overflow: hidden;
  width: 100%;
  min-height: 0;
  padding: 16px 18px;
  border: 0;
  border-radius: 8px;
  background: var(--bt-olive);
  color: #faf7ec;
  font: 600 14px/1 var(--bt-body);
  letter-spacing: 0.1em;
  text-transform: uppercase;
  transition: filter 0.2s ease;
}

.bundle-tiers__card.is-featured .block-product-buy-button {
  background: var(--bt-flame);
  color: #fff8ee;
}

/* drop the native outline ring; the shine sweep is the hover */
.bundle-tiers__cta .block-product-buy-button::after {
  display: none;
}

.bundle-tiers__cta .block-product-buy-button::before {
  content: "";
  position: absolute;
  top: 0;
  bottom: 0;
  left: -60%;
  width: 40%;
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.45), transparent);
  transform: skewX(-20deg);
  pointer-events: none;
}

.bundle-tiers__cta .block-product-buy-button:focus-visible {
  outline: 2px solid var(--bt-flame);
  outline-offset: 3px;
}

.bundle-tiers__contents {
  padding: 22px 22px 26px;
}

.bundle-tiers__contents-heading {
  margin: 0 0 12px;
  padding-top: 18px;
  border-top: 1px solid var(--bt-line);
  font: 600 13px/1.4 var(--bt-body);
  color: var(--bt-ink);
}

.bundle-tiers__contents-heading em {
  font-style: normal;
  color: var(--bt-olive);
}

.bundle-tiers__list {
  display: grid;
  gap: 9px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.bundle-tiers__list li {
  display: grid;
  grid-template-columns: 16px 1fr;
  gap: 10px;
  align-items: start;
  font: 400 14px/1.45 var(--bt-body);
}

.bundle-tiers__list svg {
  width: 16px;
  height: 16px;
  margin-top: 2px;
  color: var(--bt-olive);
}

@media (hover: hover) {
  .bundle-tiers__card:hover {
    transform: translateY(-4px);
    box-shadow: 0 22px 44px -24px rgba(20, 19, 15, 0.5);
  }

  .bundle-tiers__card:hover .bundle-tiers__media img {
    transform: scale(1.05);
  }

  .bundle-tiers__cta .block-product-buy-button:hover {
    filter: brightness(0.94);
  }

  .bundle-tiers__cta .block-product-buy-button:hover::before {
    animation: bundle-tiers-sweep 0.7s ease forwards;
  }
}

@keyframes bundle-tiers-sweep {
  to {
    left: 130%;
  }
}

@media (prefers-reduced-motion: reduce) {
  .bundle-tiers__card,
  .bundle-tiers__media img {
    transition: none;
  }

  .bundle-tiers__card:hover {
    transform: none;
  }

  .bundle-tiers__cta .block-product-buy-button:hover::before {
    animation: none;
  }
}

/* under 1100px: 2 x 2 */
@media (max-width: 1099px) {
  .bundle-tiers__grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    grid-template-rows: none;
    gap: 34px 20px;
  }

  .bundle-tiers__card {
    grid-row: auto;
    grid-template-rows: auto auto auto auto auto 1fr;
  }
}

/* three cards keep one row down to 900px */
@media (min-width: 900px) and (max-width: 1099px) {
  .bundle-tiers__grid--count-3 {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    grid-template-rows: auto auto auto auto auto 1fr;
    gap: 0 20px;
  }

  .bundle-tiers__grid--count-3 .bundle-tiers__card {
    grid-row: span 6;
    grid-template-rows: subgrid;
  }
}

/* three cards on two columns: center the last one */
@media (min-width: 641px) and (max-width: 899px) {
  .bundle-tiers__grid--count-3 .bundle-tiers__card:last-child {
    grid-column: 1 / -1;
    justify-self: center;
    width: calc(50% - 10px);
  }
}

/* phones: swipe row, one card plus a peek of the next */
@media (max-width: 640px) {
  .bundle-tiers__grid {
    display: flex;
    gap: 14px;
    margin: 28px -20px 0;
    padding: 16px 20px 8px;
    overflow-x: auto;
    scroll-snap-type: x mandatory;
    scroll-padding-inline: 20px;
    scrollbar-width: none;
  }

  .bundle-tiers__grid::-webkit-scrollbar {
    display: none;
  }

  .bundle-tiers__card {
    flex: 0 0 84%;
    scroll-snap-align: start;
  }
}
