/* MATÉZZ gift promotion – scoped to avoid theme/Elementor/CheckoutWC collisions. */
.mgf-promo {
  --mgf-green: #245a43;
  --mgf-green-light: #39795c;
  --mgf-bg: #f3f8f2;
  --mgf-text: #173c2c;
  --mgf-muted: #52685a;
  box-sizing: border-box;
  width: 100%;
  max-width: none;
  margin: 16px 0 20px;
  border: 1px solid #d8e7d7;
  border-radius: 12px;
  padding: 16px 18px;
  background: var(--mgf-bg);
  color: var(--mgf-text);
  line-height: 1.45;
  font-family: inherit;
  clear: both;
}
.mgf-promo *, .mgf-promo *::before, .mgf-promo *::after { box-sizing: border-box; }
.mgf-promo__inner { display: flex; gap: 20px; align-items: center; justify-content: space-between; }
.mgf-promo__copy { display: flex; flex: 1 1 54%; flex-direction: column; min-width: 0; gap: 2px; }
.mgf-promo__eyebrow {
  color: var(--mgf-green-light);
  font-size: 10px;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 1.2px;
}
.mgf-promo__title { font-size: 15px; line-height: 1.4; font-weight: 750; color: var(--mgf-text); }
.mgf-promo__status { font-size: 12px; line-height: 1.5; color: var(--mgf-muted); }
.mgf-promo__track-wrap { flex: 0 1 260px; min-width: 155px; }
.mgf-promo__track {
  position: relative;
  overflow: hidden;
  width: 100%;
  height: 9px;
  border-radius: 999px;
  background: #d9e4d7;
}
.mgf-promo__fill {
  display: block;
  height: 100%;
  border-radius: inherit;
  background: var(--mgf-green-light);
  transition: width .35s ease;
}
.mgf-promo__progress-label { display: block; margin-top: 5px; text-align: right; color: var(--mgf-muted); font-size: 11px; font-variant-numeric: tabular-nums; }
.mgf-promo.is-qualified {
  border-color: #b7d4bb;
  background: #e9f5e9;
}
.mgf-promo.is-qualified .mgf-promo__status { color: #235c3a; font-weight: 650; }
.mgf-promo.is-qualified .mgf-promo__fill { background: #2e9153; }

/* Always a compact full-bleed row above the theme's header. */
.mgf-promo--top {
  width: 100%;
  border: 0;
  border-radius: 0;
  background: #245a43;
  color: #fff;
  padding: 8px 16px;
  margin: 0;
  position: relative;
  z-index: 20;
}
.mgf-promo--top .mgf-promo__inner { max-width: 1320px; margin: 0 auto; gap: 14px; }
.mgf-promo--top .mgf-promo__copy { flex: 1 1 auto; flex-direction: row; flex-wrap: wrap; align-items: baseline; column-gap: 10px; row-gap: 2px; }
.mgf-promo--top .mgf-promo__eyebrow { color: #d6efcf; letter-spacing: .9px; white-space: nowrap; }
.mgf-promo--top .mgf-promo__title { color: #fff; font-size: 12px; }
.mgf-promo--top .mgf-promo__status { color: #e5f0e5; font-size: 11px; }
.mgf-promo--top .mgf-promo__track-wrap { flex: 0 1 185px; min-width: 110px; }
.mgf-promo--top .mgf-promo__track { height: 6px; background: #527c66; }
.mgf-promo--top .mgf-promo__fill { background: #c5e9b5; }
.mgf-promo--top .mgf-promo__progress-label { color: #e7f0e6; margin-top: 2px; font-size: 10px; }
.mgf-promo--top.is-qualified { background: #225640; }
.mgf-promo--top.is-qualified .mgf-promo__status { color: #e5f0e5; }
.mgf-promo--top.is-qualified .mgf-promo__fill { background: #b9e8a0; }

/* Keep product widget inside the normal product-details column. */
.mgf-promo--product { margin-top: 15px; margin-bottom: 20px; }
.mgf-promo--cart, .mgf-promo--checkout { margin: 0 0 22px; }
.mgf-gift-tag { display: inline-block; color: #245a43; font-size: 10px; font-weight: 800; white-space: nowrap; margin-left: 5px; }
.mgf-gift-qty { font-size: 12px; font-weight: 600; color: #245a43; }

@media (max-width: 768px) {
  .mgf-promo { padding: 13px 14px; margin-top: 14px; }
  .mgf-promo__inner { align-items: stretch; flex-direction: column; gap: 11px; }
  .mgf-promo__track-wrap { flex: auto; width: 100%; min-width: 0; }
  .mgf-promo__title { font-size: 14px; }
  .mgf-promo--top { padding: 7px 12px; margin: 0; }
  .mgf-promo--top .mgf-promo__inner { gap: 6px; }
  .mgf-promo--top .mgf-promo__copy { justify-content: center; gap: 2px 7px; text-align: center; }
  .mgf-promo--top .mgf-promo__eyebrow { font-size: 9px; }
  .mgf-promo--top .mgf-promo__title { font-size: 11px; }
  .mgf-promo--top .mgf-promo__status { display: block; width: 100%; font-size: 10px; }
  .mgf-promo--top .mgf-promo__track-wrap { width: min(420px, 100%); margin: 0 auto; }
  .mgf-promo--top .mgf-promo__progress-label { text-align: center; }
}
@media (prefers-reduced-motion: reduce) {
  .mgf-promo__fill { transition: none; }
}

/* Keep threshold and currency together on narrow screens. */
.mgf-promo .mgf-nowrap { white-space: nowrap; display: inline-block; }
.mgf-promo__progress-label { white-space: nowrap; }

/* v1.0.2: dark campaign system, compact mobile top bar and dismiss control. */
.mgf-promo { --mgf-bg: #17251f; --mgf-text: #f6fbf7; --mgf-muted: #b7c8bc; --mgf-green-light: #b9e3aa; border-color: #344a3c; background: var(--mgf-bg); color: var(--mgf-text); }
.mgf-promo__track { background: #40554a; }
.mgf-promo__fill { background: #b9e3aa; }
.mgf-promo.is-qualified { background: #193727; border-color: #457653; }
.mgf-promo.is-qualified .mgf-promo__status { color: #d4f0d8; }
.mgf-promo.is-qualified .mgf-promo__fill { background: #9cdda6; }
.mgf-promo--top, .mgf-promo--top.is-qualified {
  background: #101c17;
  border: 0;
  padding: 9px 46px 9px 14px;
  margin: 0;
  width: 100%;
  height: auto;
  min-height: 0;
  max-height: none;
  display: block;
  overflow: visible;
}
.mgf-promo--top .mgf-promo__inner { min-height: 0; height: auto; align-items: center; }
.mgf-promo--top .mgf-promo__copy { min-height: 0; }
.mgf-promo--top .mgf-promo__eyebrow { color: #afdba9; }
.mgf-promo--top .mgf-promo__track { background: #395046; }
.mgf-promo--top .mgf-promo__fill { background: #b9e3aa; }
.mgf-promo--top .mgf-promo__progress-label { color: #dce9de; }
.mgf-promo__close {
  appearance: none;
  position: absolute;
  top: 50%; right: 12px;
  transform: translateY(-50%);
  display: flex; align-items: center; justify-content: center;
  width: 28px; height: 28px;
  padding: 0; margin: 0;
  background: rgba(255,255,255,.07);
  border: 1px solid rgba(255,255,255,.16);
  color: #fff; border-radius: 50%;
  font-size: 23px; font-weight: 400; line-height: 1;
  cursor: pointer; z-index: 2;
}
.mgf-promo__close:hover, .mgf-promo__close:focus-visible { background: rgba(255,255,255,.18); color: #fff; outline-offset: 2px; }
@media (max-width: 768px) {
  .mgf-promo--top, .mgf-promo--top.is-qualified {
    margin: 0 !important;
    padding: 8px 42px 8px 10px !important;
    height: auto !important;
    min-height: 0 !important;
    max-height: 115px !important;
    overflow: hidden;
  }
  .mgf-promo--top .mgf-promo__inner {
    display: grid !important;
    grid-template-columns: minmax(0, 1fr);
    grid-auto-rows: min-content;
    gap: 5px !important;
    align-items: start !important;
    justify-items: stretch;
    height: auto !important;
    min-height: 0 !important;
    max-height: none !important;
  }
  .mgf-promo--top .mgf-promo__copy {
    display: block !important;
    width: 100%;
    flex: none !important;
    min-height: 0 !important;
    margin: 0;
    text-align: center;
    line-height: 1.25;
  }
  .mgf-promo--top .mgf-promo__eyebrow { display: none; }
  .mgf-promo--top .mgf-promo__title { display: block; font-size: 11px; line-height: 1.3; }
  .mgf-promo--top .mgf-promo__status { display: block; margin-top: 3px; font-size: 10px; line-height: 1.25; }
  .mgf-promo--top .mgf-promo__track-wrap {
    display: block !important;
    width: 100% !important;
    height: auto !important;
    min-height: 0 !important;
    max-height: 24px !important;
    flex: none !important;
    margin: 0 !important;
    padding: 0;
    align-self: start;
  }
  .mgf-promo--top .mgf-promo__track { height: 5px; }
  .mgf-promo--top .mgf-promo__progress-label { display: block; margin: 2px 0 0; font-size: 9px; line-height: 1.2; }
  .mgf-promo--top .mgf-promo__close { width: 24px; height: 24px; right: 9px; font-size: 21px; }
}
