/* ============================================================
   make_product_selector — Product switcher hero
   Reuses the timeline-hero look (.mpt__*) for each per-product panel,
   plus .mps__* rules for the pill switcher and panel show/hide.
   Self-contained: every hero rule the section needs is included here.
   ============================================================ */
.mpt {
  overflow: visible;
  position: relative;
  z-index: 0;
  isolation: isolate;
}

.mpt ~ *:not(.sticky-atc) {
  position: relative;
  z-index: 1;
}

.mpt .mpt__container {
  overflow: visible;
}

.mpt__inner {
  overflow: visible;
  position: relative;
}

/* ============================================================
   SWITCHER (product pills) — sits above the panels, full width
   ============================================================ */
.mps__switcher {
  width: 100%;
  margin: 0 0 28px;
}

.mps__pill-list {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

/* .mps__pill reuses the .mpt__flavor-btn look verbatim (no overrides) so the
   switcher matches the existing flavor pills exactly. */

.mps__empty {
  font-size: 14px;
  color: var(--clr-neutral);
  padding: 24px 0;
}

/* Panel show/hide */
.mps__panel.is-hidden { display: none !important; }

/* ============================================================
   HERO LAYOUT (per panel)
   ============================================================ */
.mpt__layout {
  display: grid;
  grid-template-columns: minmax(0, 2fr) minmax(0, 1fr);
  gap: 48px;
  align-items: start;
  position: relative;
  width: 100%;
  max-width: 100%;
  overflow: clip;
  box-sizing: border-box;
}

.mpt__layout > * {
  box-sizing: border-box;
  min-width: 0;
  max-width: 100%;
}

/* LEFT COLUMN: media gallery */
.mpt__media {
  grid-column: 1;
  display: flex;
  flex-direction: column;
  gap: 16px;
  min-width: 0;
  max-width: 100%;
  overflow: hidden;
  contain: layout style;
  box-sizing: border-box;
}

.mpt__media img,
.mpt__gallery img,
.mpt__gallery-item img {
  max-width: 100%;
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.mpt__gallery {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 8px;
  max-width: 100%;
  width: 100%;
  min-width: 0;
  overflow: hidden;
  box-sizing: border-box;
}

.mpt__gallery-item {
  overflow: hidden;
  box-sizing: border-box;
  aspect-ratio: 4 / 5;
  position: relative;
  display: block;
  border-radius: 4px;
  background: var(--clr-neutral-light, var(--clr-neutral-lighter));
  cursor: pointer;
}

@media (min-width: 768px) {
  .mpt__gallery-item {
    max-width: 100%;
    min-width: 0;
    width: 100%;
    flex: none;
  }
}

/* Mobile: horizontal swipeable strip */
@media (max-width: 767px) {
  .mpt__gallery {
    display: flex;
    flex-direction: row;
    flex-wrap: nowrap;
    overflow-x: auto;
    overflow-y: hidden;
    -webkit-overflow-scrolling: touch;
    scroll-snap-type: x mandatory;
    scroll-behavior: smooth;
    gap: 2px;
    padding: 0;
    border-top: 1px solid var(--clr-border-light);
    border-bottom: 1px solid var(--clr-border-light);
    grid-template-columns: none;
    scrollbar-width: none;
    -ms-overflow-style: none;
  }
  .mpt__gallery::-webkit-scrollbar { display: none; }

  .mpt__gallery-item {
    flex: 0 0 calc(80vw - 40px);
    width: calc(80vw - 40px);
    min-width: calc(80vw - 40px);
    max-width: calc(80vw - 40px);
    scroll-snap-align: start;
    aspect-ratio: 4 / 5;
    border-radius: 0;
  }
}

/* Ticker overlay — first gallery item */
.mpt__ticker-overlay {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  background: var(--clr-bg-card-secondary);
  padding: 10px 0;
  overflow: hidden;
  border-radius: 0 0 4px 4px;
}

.mpt__ticker-marquee {
  width: 100%;
  overflow: hidden;
}

.mpt__ticker-track {
  display: flex;
  animation: mps-ticker-scroll 20s linear infinite;
  white-space: nowrap;
  width: fit-content;
}

@keyframes mps-ticker-scroll {
  0% { transform: translateX(0); }
  100% { transform: translateX(-50%); }
}

.mpt__ticker-item {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 0 16px;
  font-size: 11px;
  font-weight: 400;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.mpt__ticker-dot { color: rgba(0, 0, 0, 0.3); }
.mpt__ticker-primary { color: var(--clr-primary, var(--clr-black)); }
.mpt__ticker-accent { color: var(--clr-primary, var(--clr-black)); font-weight: 400; }

/* Mobile gallery dots */
.mpt__gallery-dots { display: none; }

@media (max-width: 767px) {
  .mpt__gallery-dots {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 14px;
    padding: 12px 0 0;
  }

  .mpt__gallery-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: var(--clr-border-dark);
    border: none;
    padding: 0;
    cursor: pointer;
    transition: all 0.3s ease;
    position: relative;
  }
  .mpt__gallery-dot::after { content: ""; position: absolute; top: 50%; left: 50%; transform: translate(-50%, -50%); width: 24px; height: 44px; }

  .mpt__gallery-dot.active {
    background: var(--clr-black);
    width: 24px;
    border-radius: 4px;
  }
}

/* RIGHT COLUMN: product info (sticky on desktop) */
.mpt__info {
  grid-column: 2;
  min-width: 0;
  max-width: 100%;
  display: block;
  box-sizing: border-box;
  position: relative;
}

@media (min-width: 1024px) {
  .mpt__info { align-self: flex-start; }
  .mpt__info::-webkit-scrollbar { display: none; }
}

.mpt__info * {
  max-width: 100%;
  overflow-wrap: break-word;
}

.mpt__info-inner {
  display: flex;
  flex-direction: column;
  gap: 20px;
}

@media (max-width: 1023px) {
  .mpt__layout {
    grid-template-columns: 1fr;
    gap: 32px;
    overflow: hidden;
  }

  .mpt__media,
  .mpt__info {
    grid-column: 1;
    width: 100%;
    max-width: 100%;
    position: relative;
    top: auto;
    overflow: hidden;
  }
}

/* Title + eyebrow */
.mpt__title-wrap {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.mpt__eyebrow {
  font-family: var(--font-primary), system-ui, sans-serif;
  font-size: 11px;
  font-weight: 500;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--clr-neutral-mid);
  line-height: 1;
  min-height: 14px;
  width: 100%;
}

.mpt__title {
  margin: 0;
  font-family: var(--font-primary), sans-serif;
  font-size: 44px;
  font-weight: 400;
  line-height: 1.1;
  color: var(--clr-primary, var(--clr-black));
}

@media (min-width: 1024px) {
  .mpt__title { font-size: 52px; }
}

.mpt__subtitle {
  display: block;
  font-size: 24px;
  font-weight: 300;
  opacity: 0.6;
  margin-top: 4px;
}

@media (min-width: 1024px) {
  .mpt__subtitle { font-size: 28px; }
}

/* Rating */
.mpt__rating {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}

.mpt__stars { display: flex; gap: 2px; }
.mpt__stars svg { color: var(--clr-primary, var(--clr-black)); }

.mpt__rating-link {
  font-size: 14px;
  color: var(--clr-primary, var(--clr-black));
  text-decoration: underline;
  text-underline-offset: 2px;
}

/* Description */
.mpt__description {
  max-width: 100%;
  overflow: hidden;
}

.mpt__description p {
  font-size: 15px;
  line-height: 1.6;
  color: var(--clr-neutral);
  margin: 0 0 16px;
}

.mpt__description p:last-child { margin-bottom: 0; }

/* Parsed benefits list (when description has "Title: Description" pairs) */
.mpt__benefits-parsed {
  list-style: none;
  padding: 0;
  margin: 12px 0 0;
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.mpt__benefit-parsed-item {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 10px 16px;
  background: var(--clr-secondary-light);
  border-radius: 10px;
  transition: background 0.2s ease;
}

.mpt__benefit-parsed-item:hover { background: var(--clr-bg-card-secondary); }

.mpt__benefit-parsed-header {
  display: flex;
  align-items: center;
  gap: 8px;
}

.mpt__benefit-parsed-icon {
  flex-shrink: 0;
  width: 22px;
  height: 22px;
  background: rgba(0,0,0,0.06);
  border-radius: 6px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.mpt__benefit-parsed-icon svg { width: 10px; height: 10px; color: var(--clr-neutral); }

.mpt__benefit-parsed-title {
  font-size: 15px;
  font-weight: 400;
  color: var(--clr-text-primary);
  line-height: 1.3;
  letter-spacing: -0.01em;
}

.mpt__benefit-parsed-description {
  font-size: 15px;
  font-weight: 400;
  color: #777;
  line-height: 1.5;
  padding-left: 0;
  margin-top: 0;
}

/* ============================================================
   PILLS (shared flavor-pill look)
   ============================================================ */
.mpt__flavor-label {
  margin: 0 0 10px;
  font-family: var(--font-primary), system-ui, sans-serif;
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  line-height: 1.35;
  color: var(--clr-neutral);
  opacity: 0.55;
}

.mpt__flavor-list {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.mpt__flavor-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 8px 12px;
  border: 2px solid var(--clr-border-light);
  border-radius: 100px;
  background: var(--clr-white);
  cursor: pointer;
  font-family: var(--font-primary), system-ui, sans-serif;
  font-size: 11px;
  font-weight: 500;
  letter-spacing: 0.01em;
  color: var(--clr-neutral);
  transition: all 0.2s ease;
  white-space: normal;
  text-align: left;
  line-height: 1.35;
  flex: 1 1 auto;
  min-width: 0;
  max-width: calc(50% - 4px);
  box-sizing: border-box;
}

@media (max-width: 380px) {
  .mpt__flavor-btn { flex: 1 1 100%; max-width: 100%; }
}

.mpt__flavor-btn:hover { border-color: #aaa; }

.mpt__flavor-btn.active {
  border-color: var(--flavor-active-color, var(--clr-black));
  background: var(--flavor-active-bg, rgba(0,0,0,0.03));
  color: var(--clr-black);
}

.mpt__flavor-btn-text { min-width: 0; flex: 1; }

.mpt__flavor-swatch {
  width: 12px;
  height: 12px;
  border-radius: 50%;
  flex-shrink: 0;
  border: 1px solid rgba(0,0,0,0.1);
  align-self: flex-start;
  margin-top: 2px;
}

/* ============================================================
   PURCHASE OPTIONS
   ============================================================ */
.mpt__purchase { margin-top: 24px; }

.mpt__purchase-heading {
  font-size: 14px;
  font-weight: 500;
  color: var(--clr-neutral);
  margin: 0 0 12px;
}

.mpt__purchase-list {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.mpt__purchase-card {
  position: relative;
  border: 1px solid var(--clr-border-light);
  border-radius: 8px;
  background: var(--clr-white);
  transition: border-color 0.15s ease;
  cursor: pointer;
}

.mpt__purchase-card:hover { border-color: #ccc; }
.mpt__purchase-card.selected { border-color: var(--clr-black); }

.mpt__purchase-card input[type="radio"] {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}

.mpt__purchase-card label {
  display: block;
  padding: 16px 16px 16px 52px;
  cursor: pointer;
  position: relative;
}

.mpt__purchase-card::before {
  content: '';
  position: absolute;
  left: 16px;
  top: 20px;
  width: 20px;
  height: 20px;
  border: 2px solid var(--clr-border-dark);
  border-radius: 50%;
  background: var(--clr-white);
  transition: all 0.15s ease;
  box-sizing: border-box;
  z-index: 1;
}

.mpt__purchase-card.selected::before {
  border-color: var(--clr-black);
  background: var(--clr-black);
  box-shadow: inset 0 0 0 4px var(--clr-white);
}

.mpt__purchase-badge {
  position: absolute;
  top: -10px;
  right: 16px;
  padding: 3px 10px;
  font-family: var(--font-primary), system-ui, sans-serif;
  font-size: 11px;
  font-weight: 500;
  letter-spacing: 0.02em;
  color: var(--clr-white);
  background: var(--clr-black);
  border-radius: 100px;
  line-height: 1.4;
  z-index: 2;
}

.mpt__option-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.mpt__option-title {
  font-size: 15px;
  font-weight: 500;
  color: var(--clr-black);
}

.mpt__option-price {
  font-size: 15px;
  font-weight: 400;
  color: var(--clr-black);
}

.mpt__option-price .mpt__price-suffix {
  font-size: 15px;
  font-weight: 400;
  color: var(--clr-neutral-medium);
}

.mpt__option-details {
  margin-top: 12px;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.mpt__detail-item {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 15px;
  color: var(--clr-neutral-medium);
}

.mpt__detail-item svg { flex-shrink: 0; color: var(--clr-neutral-medium); }

/* ============================================================
   ADD TO CART + QTY
   ============================================================ */
.mpt__atc-section {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-top: 20px;
}

@media (max-width: 767px) {
  .mpt__atc-section {
    flex-direction: column;
    gap: 10px;
  }
  .mpt__atc-section .mpt__qty { align-self: flex-start; }
  .mpt__atc-section .mpt__atc-btn { width: 100% !important; flex: none !important; }
}

.mpt__qty {
  display: flex;
  align-items: center;
  gap: 0;
  background: var(--clr-neutral-lighter);
  border-radius: 30px;
  padding: 4px;
}

.mpt__qty-btn {
  width: 40px;
  height: 40px;
  border: none;
  background: var(--clr-white);
  border-radius: 50%;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.15s ease;
  color: var(--clr-black);
}

.mpt__qty-btn:hover { background: var(--clr-bg-card-secondary); }
.mpt__qty-btn:active { transform: scale(0.95); }
.mpt__qty-btn svg { width: 16px; height: 16px; }

.mpt__qty-input {
  width: 40px;
  text-align: center;
  font-size: 16px;
  font-weight: 400;
  border: none;
  background: transparent;
  color: var(--clr-black);
  -moz-appearance: textfield;
}

.mpt__qty-input::-webkit-outer-spin-button,
.mpt__qty-input::-webkit-inner-spin-button {
  -webkit-appearance: none;
  margin: 0;
}

.mpt__atc-btn {
  flex: 1;
  padding: 16px 24px;
  font-size: 16px;
  font-weight: 400;
  background: var(--clr-primary, var(--clr-black));
  color: var(--clr-white);
  border: none;
  border-radius: 30px;
  cursor: pointer;
  transition: all 0.15s ease;
  text-align: center;
  text-decoration: none;
  display: inline-block;
}

.mpt__atc-btn:hover { opacity: 0.9; }
.mpt__atc-btn.disabled { background: #ccc; cursor: not-allowed; }

/* Error message */
.mpt__error {
  background: #fef2f2;
  border: 1px solid #fecaca;
  border-radius: 8px;
  padding: 16px;
  color: #dc2626;
  font-size: 14px;
  text-align: center;
}

/* Video wrapper */
.mpt__gallery-video-wrap {
  position: relative;
  width: 100%;
  height: 100%;
}

.mpt__gallery-video-wrap video {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

/* ============================================================
   MODAL LIGHTBOX — above the fixed nav (9999)
   ============================================================ */
.mpt__modal {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.95);
  z-index: 100000;
  display: none;
  align-items: center;
  justify-content: center;
  padding: 32px;
}

.mpt__modal.is-active { display: flex; }

.mpt__modal-close {
  position: absolute;
  top: 16px;
  right: 16px;
  background: rgba(255,255,255,0.12);
  border: none;
  color: var(--clr-white);
  font-size: 28px;
  line-height: 1;
  cursor: pointer;
  z-index: 10002;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0;
  transition: background 0.15s ease;
}
.mpt__modal-close:hover { background: rgba(255,255,255,0.22); }

.mpt__modal-content {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 16px;
  max-width: 100%;
  width: 100%;
  height: 100%;
  position: relative;
}

.mpt__modal-stage {
  flex: 1;
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 0;
  position: relative;
}

.mpt__modal-stage img,
.mpt__modal-stage video {
  max-width: 100%;
  max-height: calc(100vh - 200px);
  object-fit: contain;
  border-radius: 4px;
}

.mpt__modal-arrow {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  background: rgba(255,255,255,0.12);
  border: none;
  color: var(--clr-white);
  width: 44px;
  height: 44px;
  border-radius: 50%;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 22px;
  transition: background 0.15s ease;
  z-index: 10001;
}

.mpt__modal-arrow:hover { background: rgba(255,255,255,0.22); }
.mpt__modal-arrow.prev { left: 24px; }
.mpt__modal-arrow.next { right: 24px; }

.mpt__modal-thumbs {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 8px;
  max-width: 600px;
}

.mpt__modal-thumb {
  width: 64px;
  height: 64px;
  border-radius: 4px;
  overflow: hidden;
  cursor: pointer;
  opacity: 0.5;
  border: 2px solid transparent;
  background: none;
  padding: 0;
  flex-shrink: 0;
}

.mpt__modal-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.mpt__modal-thumb.is-active {
  opacity: 1;
  border-color: var(--clr-white);
}

/* ============================================================
   STICKY ATC FOOTER
   ============================================================ */
.sticky-atc {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  z-index: 999;
  display: flex;
  justify-content: center;
  padding: 0 16px;
  transform: translateY(100%);
  transition: transform 0.45s cubic-bezier(0.16, 1, 0.3, 1);
  pointer-events: none;
}

.sticky-atc.is-visible {
  transform: translateY(0);
  pointer-events: auto;
}

.sticky-atc__inner {
  background: var(--clr-neutral-dark);
  border-radius: 14px 14px 0 0;
  width: 100%;
  max-width: 720px;
}

.sticky-atc__row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  padding: 16px 24px;
  padding-bottom: calc(16px + env(safe-area-inset-bottom, 0px));
}

.sticky-atc__product {
  display: flex;
  align-items: center;
  gap: 16px;
  min-width: 0;
  flex: 1;
}

.sticky-atc__thumb {
  width: 42px;
  height: 42px;
  object-fit: cover;
  border-radius: 6px;
  flex-shrink: 0;
}

.sticky-atc__info {
  display: flex;
  align-items: center;
  gap: 12px;
  min-width: 0;
}

.sticky-atc__title {
  font-family: var(--font-primary), system-ui, sans-serif;
  font-size: 14px;
  font-weight: 400;
  letter-spacing: -0.01em;
  color: var(--clr-white);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  line-height: 1;
}

.sticky-atc__divider {
  width: 1px;
  height: 14px;
  background: rgba(255, 255, 255, 0.2);
  flex-shrink: 0;
}

.sticky-atc__price {
  font-family: var(--font-primary), system-ui, sans-serif;
  font-size: 14px;
  font-weight: 400;
  color: rgba(255, 255, 255, 0.5);
  letter-spacing: -0.01em;
  line-height: 1;
  white-space: nowrap;
}

.sticky-atc__btn {
  flex-shrink: 0;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0;
  padding: 12px 28px;
  font-family: var(--font-primary), system-ui, sans-serif;
  font-size: 15px;
  font-weight: 400;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--clr-text-primary);
  background: var(--clr-white);
  border: none;
  border-radius: 0;
  cursor: pointer;
  white-space: nowrap;
  transition: background 0.2s ease, color 0.2s ease;
}

.sticky-atc__btn:hover { background: rgba(255, 255, 255, 0.85); }
.sticky-atc__btn:active { background: rgba(255, 255, 255, 0.7); }

@media (max-width: 767px) {
  .sticky-atc { padding: 0 12px; }
  .sticky-atc__inner { border-radius: 12px 12px 0 0; }
  .sticky-atc__row {
    gap: 12px;
    padding: 14px 16px;
    padding-bottom: calc(14px + env(safe-area-inset-bottom, 0px));
  }
  .sticky-atc__thumb { width: 36px; height: 36px; border-radius: 4px; }
  .sticky-atc__title { font-size: 15px; }
  .sticky-atc__price { font-size: 15px; }
  .sticky-atc__btn { padding: 14px 20px; font-size: 14px; }
}

@media (min-width: 768px) {
  .sticky-atc__inner { max-width: 800px; border-radius: 16px 16px 0 0; }
  .sticky-atc__row {
    padding: 18px 32px;
    padding-bottom: calc(18px + env(safe-area-inset-bottom, 0px));
  }
}
