/* ============================================
   AZC Notify — toasts & popins premium
   ============================================ */

/* ---------- Toasts ---------- */
#azc-toast-wrap {
  position: fixed;
  top: 20px;
  left: 0;
  right: 0;
  margin: 0 auto;
  z-index: 2147483000;
  display: flex;
  flex-direction: column;
  gap: 10px;
  align-items: center;
  pointer-events: none;
  width: calc(100% - 32px);
  max-width: 480px;
}

.azc-toast {
  pointer-events: auto;
  cursor: pointer;
  background: #1a1a1a;
  color: #fff;
  padding: 13px 20px;
  border-radius: 12px;
  font-size: 14px;
  line-height: 1.45;
  box-shadow: 0 8px 30px rgba(0, 0, 0, 0.18);
  opacity: 0;
  transform: translateY(-8px);
  transition: opacity 0.25s ease, transform 0.25s ease;
  white-space: pre-line;
  max-width: 100%;
}

.azc-toast--show {
  opacity: 1;
  transform: translateY(0);
}

.azc-toast--error   { background: #b3261e; }
.azc-toast--success { background: #1b7a43; }

/* ---------- Popins ---------- */
.azc-popin-overlay {
  position: fixed;
  /* Ancrage explicite (pas de inset/vw) : insensible aux débordements
     horizontaux de la page et aux conteneurs transformés sur mobile */
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  box-sizing: border-box;
  background: rgba(20, 16, 12, 0.45);
  backdrop-filter: blur(2px);
  z-index: 2147483001;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
  opacity: 0;
  transition: opacity 0.2s ease;
}

.azc-popin-overlay *,
.azc-popin-overlay *::before,
.azc-popin-overlay *::after {
  box-sizing: border-box;
}

.azc-popin-overlay--show { opacity: 1; }

.azc-popin {
  /* Centrage absolu autoportant : indispensable sur mobile où le flex
     du calque peut être neutralisé par le CSS du thème. Le !important
     verrouille contre toute règle concurrente. */
  position: fixed !important;
  top: 50% !important;
  left: 50% !important;
  transform: translate(-50%, -50%) scale(0.96) !important;
  background: #fff;
  border-radius: 16px;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.25);
  padding: 26px 24px 22px;
  width: calc(100% - 40px);
  max-width: 380px;
  transition: transform 0.2s ease;
  text-align: center;
}

.azc-popin-overlay--show .azc-popin {
  transform: translate(-50%, -50%) scale(1) !important;
}

.azc-popin__img {
  display: block;
  margin: 0 auto 14px;
  max-height: 115px;
  width: auto;
  border-radius: 7px;
}

.azc-popin__message {
  font-size: 15px;
  line-height: 1.5;
  color: #1a1a1a;
  margin-bottom: 18px;
}

.azc-popin__hint {
  display: block;
  font-size: 12.5px;
  color: #8a8a8a;
  margin-top: 4px;
}

.azc-popin__qty {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  margin-bottom: 14px;
}

.azc-popin__stepper {
  width: 100px;
  height: 42px;
  border: 1px solid #ddd;
  border-radius: 7px !important;
  background: #fff;
  font-size: 20px;
  line-height: 1;
  cursor: pointer;
  color: #1a1a1a;
}

.azc-popin__stepper:hover { background: #f6f3ef; }

.azc-popin__input {
  width: 82px;
  height: 42px;
  text-align: center;
  font-size: 17px;
  font-weight: 600;
  border: 1px solid #ddd;
  border-radius: 7px !important;
  -moz-appearance: textfield;
}

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

.azc-popin__error {
  color: #b3261e;
  font-size: 13px;
  margin-bottom: 12px;
}

.azc-popin__actions {
  display: flex;
  gap: 10px;
  justify-content: center;
}

.azc-popin__btn {
  min-width: 110px;
  padding: 11px 18px;
  border-radius: 7px !important;
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  border: 1px solid transparent;
  transition: opacity 0.15s ease, background 0.15s ease;
}

.azc-popin__btn--primary {
  background: #1a1a1a;
  color: #fff;
}

.azc-popin__btn--primary:hover { opacity: 0.88; }

.azc-popin__btn--ghost {
  background: #fff;
  color: #1a1a1a;
  border-color: #ddd;
}

.azc-popin__btn--ghost:hover { background: #f6f3ef; }
