/* U&C styling for out-of-stock states:
   - the native "En rupture" product flag (.product-flags .badge.out_of_stock)
   - the ps_emailalerts "Prévenez-moi lorsque le produit est disponible" block.
   Replaces the default Hummingbird/Bootstrap blue with the U&C navy/red. */

/* ---------- "En rupture" flag ---------- */
.product-flags .badge.out_of_stock {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 7px 11px;
  border: 0;
  border-radius: 2px;
  background: var(--uc-navy, #17354d);
  box-shadow: 0 6px 16px rgba(23, 53, 77, .18);
  color: #fff;
  font-family: 'Barlow', Arial, sans-serif;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: .12em;
  line-height: 1;
  text-transform: uppercase;
}

.product-flags .badge.out_of_stock::before {
  content: "";
  flex: 0 0 auto;
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--uc-red, #ed2939);
  box-shadow: 0 0 0 3px rgba(237, 41, 57, .25);
}

/* ---------- "Prévenez-moi" block (ps_emailalerts) ---------- */
.ps-emailalerts--product .ps-emailalerts__content {
  position: relative;
  gap: .65rem;
  padding: 20px 22px 22px;
  background: #fafafa;
  border: 1px solid #e0e4e8;
  border-top: 4px solid var(--uc-navy, #17354d);
  border-radius: 0;
  box-shadow: 0 8px 20px rgba(23, 53, 77, .04);
}

.ps-emailalerts--product .ps-emailalerts__content > .h4 {
  display: flex;
  align-items: center;
  gap: 10px;
  color: var(--uc-navy, #17354d);
  font-family: 'Barlow', Arial, sans-serif;
  font-size: 1.05rem;
  font-weight: 700;
  letter-spacing: .02em;
  line-height: 1.25;
  text-transform: uppercase;
}

.ps-emailalerts--product .ps-emailalerts__content > .h4::before {
  content: "notifications_active";
  flex: 0 0 auto;
  color: var(--uc-red, #ed2939);
  font-family: 'Material Icons';
  font-size: 22px;
  font-weight: normal;
  letter-spacing: normal;
  line-height: 1;
  text-transform: none;
  -webkit-font-feature-settings: 'liga';
  font-feature-settings: 'liga';
}

.ps-emailalerts--product .ps-emailalerts__content > p:not(.h4) {
  color: #687684;
  font-size: .92rem;
  line-height: 1.6;
}

.ps-emailalerts--product .ps-emailalerts__content .form-control {
  height: 50px;
  padding-inline: 16px;
  border: 1px solid #c9d3dc;
  border-radius: 4px;
  background: #fff;
  color: var(--uc-navy, #17354d);
  font-size: .95rem;
}

.ps-emailalerts--product .ps-emailalerts__content .form-control:focus {
  border-color: var(--uc-navy, #17354d);
  box-shadow: 0 0 0 .2rem rgba(23, 53, 77, .15);
}

.ps-emailalerts--product .ps-emailalerts__content .btn.btn-primary {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 50px;
  padding: 0 22px;
  border: 0;
  border-radius: 4px;
  background: var(--uc-navy, #17354d);
  box-shadow: 0 10px 24px rgba(23, 53, 77, .18);
  color: #fff;
  font-size: 13px;
  font-weight: 800;
  letter-spacing: .02em;
  line-height: 1.2;
  text-transform: uppercase;
}

.ps-emailalerts--product .ps-emailalerts__content .btn.btn-primary::before {
  content: "mail_outline";
  font-family: 'Material Icons';
  font-size: 19px;
  font-weight: normal;
  letter-spacing: normal;
  line-height: 1;
  text-transform: none;
  -webkit-font-feature-settings: 'liga';
  font-feature-settings: 'liga';
}

/* Hover turns red, like the other U&C primary buttons (uc-buttons.css). */
.ps-emailalerts--product .ps-emailalerts__content .btn.btn-primary:focus-visible {
  outline: 2px solid var(--uc-red, #ed2939);
  outline-offset: 3px;
}

/* GDPR consent text under the button. */
.ps-emailalerts--product .ps-emailalerts__content .text-body-secondary {
  color: #75818b !important;
  font-size: .78rem !important;
  line-height: 1.5;
}

.ps-emailalerts--product .ps-emailalerts__content .text-body-secondary a {
  color: var(--uc-red, #ed2939);
}

/* Feedback messages: subscription confirmed / already subscribed / error. */
.ps-emailalerts--product .alert {
  margin: 0 0 1rem;
  padding: 14px 18px;
  border: 0;
  border-left: 4px solid var(--uc-navy, #17354d);
  border-radius: 0;
  background: #eef2f5;
  color: var(--uc-navy, #17354d);
  font-size: .92rem;
  font-weight: 600;
}

.ps-emailalerts--product .alert-success {
  border-left-color: #2e8540;
  background: #edf6ef;
  color: #1f5c2c;
}

.ps-emailalerts--product .alert-danger {
  border-left-color: var(--uc-red, #ed2939);
  background: #fdeeef;
  color: #a9151b;
}

@media (max-width: 575.98px) {
  .ps-emailalerts--product .ps-emailalerts__content {
    padding: 16px;
  }

  .ps-emailalerts--product .ps-emailalerts__content .btn.btn-primary {
    width: 100%;
    padding-inline: 14px;
  }
}
