/* ==============================================================
   SOLD-OUT CARDS + INTEREST DIALOG
   Paired with js/availability-ui.js. Uses the existing palette
   tokens from styles.css so sold-out wines still look like part
   of the estate rather than broken listings.
   ============================================================== */

/* ---------- card ---------- */

.wine-card.is-sold-out {
  position: relative;
}

/* Dim the bottle and the copy, not the whole card: the wine should still
   read as part of the range, just unavailable today. */
.wine-card.is-sold-out .wine-bottle-wrap,
.wine-card.is-sold-out .wine-bottle-img,
.wine-card.is-sold-out .wine-icon,
.wine-card.is-sold-out .wine-region,
.wine-card.is-sold-out .wine-name,
.wine-card.is-sold-out .wine-year,
.wine-card.is-sold-out .wine-desc,
.wine-card.is-sold-out .wine-price {
  opacity: 0.45;
  filter: saturate(0.35);
  transition: opacity var(--transition-smooth, 0.3s ease),
              filter var(--transition-smooth, 0.3s ease);
}

.wine-card.is-sold-out:hover .wine-bottle-wrap,
.wine-card.is-sold-out:hover .wine-bottle-img,
.wine-card.is-sold-out:hover .wine-name,
.wine-card.is-sold-out:hover .wine-price {
  opacity: 0.7;
  filter: saturate(0.6);
}

.wine-card.is-sold-out .wine-price {
  text-decoration: line-through;
  text-decoration-thickness: 1px;
  text-decoration-color: var(--color-text-light, #8a8a8a);
}

.sold-out-badge {
  position: absolute;
  top: 14px;
  right: 14px;
  z-index: 3;
  padding: 5px 11px;
  border: 1px solid var(--color-gold, #c2a36e);
  border-radius: 2px;
  background: var(--color-cream, #f6f1eb);
  color: var(--color-burgundy, #6b2d3e);
  font-family: var(--font-accent, inherit);
  font-size: 0.62rem;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  white-space: nowrap;
  pointer-events: none;
}

/* ---------- notify button ---------- */

.wine-add-cart.notify-btn,
.product-add-btn.notify-btn {
  background: transparent;
  color: var(--color-burgundy, #6b2d3e);
  border: 1px solid var(--color-gold, #c2a36e);
  cursor: pointer;
  opacity: 1;
  filter: none;
  transition: background var(--transition-smooth, 0.3s ease),
              color var(--transition-smooth, 0.3s ease);
}

.wine-add-cart.notify-btn:hover,
.product-add-btn.notify-btn:hover {
  background: var(--color-gold, #c2a36e);
  color: var(--color-white, #fff);
}

.wine-add-cart.notify-btn svg,
.wine-add-cart.notify-btn .pour-fill {
  display: none;
}

/* ---------- interest dialog ---------- */

.md-interest-overlay {
  position: fixed;
  inset: 0;
  z-index: 10000;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
  background: rgba(43, 43, 43, 0.6);
  backdrop-filter: blur(3px);
  animation: mdInterestIn 0.22s ease;
}

@keyframes mdInterestIn {
  from { opacity: 0; }
  to   { opacity: 1; }
}

.md-interest-box {
  position: relative;
  width: 100%;
  max-width: 420px;
  padding: 36px 32px 32px;
  background: var(--color-white, #fff);
  border-top: 3px solid var(--color-gold, #c2a36e);
  box-shadow: 0 24px 60px rgba(0, 0, 0, 0.25);
  text-align: left;
}

.md-interest-close {
  position: absolute;
  top: 10px;
  right: 14px;
  border: 0;
  background: none;
  color: var(--color-text-light, #8a8a8a);
  font-size: 1.5rem;
  line-height: 1;
  cursor: pointer;
  padding: 4px 8px;
}

.md-interest-close:hover { color: var(--color-burgundy, #6b2d3e); }

.md-interest-wine {
  margin: 0 0 4px;
  color: var(--color-gold, #c2a36e);
  font-family: var(--font-accent, inherit);
  font-size: 0.66rem;
  font-weight: 600;
  letter-spacing: 0.16em;
  text-transform: uppercase;
}

.md-interest-title {
  margin: 0 0 10px;
  color: var(--color-burgundy, #6b2d3e);
  font-family: var(--font-display, Georgia, serif);
  font-size: 1.35rem;
  font-weight: 400;
  line-height: 1.25;
}

.md-interest-intro {
  margin: 0 0 18px;
  color: var(--color-text, #3a3a3a);
  font-size: 0.86rem;
  line-height: 1.6;
}

.md-interest-email {
  width: 100%;
  padding: 12px 14px;
  border: 1px solid var(--color-divider, #e2dbd2);
  border-radius: 0;
  background: var(--color-cream, #f6f1eb);
  color: var(--color-text, #3a3a3a);
  font-family: inherit;
  font-size: 0.92rem;
}

.md-interest-email:focus {
  outline: none;
  border-color: var(--color-gold, #c2a36e);
}

.md-interest-email:disabled { opacity: 0.6; }

.md-interest-send {
  width: 100%;
  margin-top: 14px;
  padding: 13px 16px;
  border: 0;
  background: var(--color-burgundy, #6b2d3e);
  color: var(--color-white, #fff);
  font-family: var(--font-accent, inherit);
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  cursor: pointer;
  transition: background var(--transition-smooth, 0.3s ease);
}

.md-interest-send:hover:not(:disabled) { background: var(--color-burgundy-deep, #541f2d); }
.md-interest-send:disabled { opacity: 0.55; cursor: default; }

.md-interest-msg {
  min-height: 1.1em;
  margin: 10px 0 0;
  font-size: 0.8rem;
  line-height: 1.45;
}

.md-interest-msg.is-ok    { color: #2e7d52; }
.md-interest-msg.is-error { color: var(--color-burgundy, #6b2d3e); }

@media (max-width: 480px) {
  .md-interest-box { padding: 30px 22px 24px; }
  .md-interest-title { font-size: 1.18rem; }
}

/* ---------- age gate: remember-me hint ---------- */

.age-gate-remember-hint {
  color: var(--color-text-light, #8a8a8a);
  font-size: 0.86em;
}

/* ---------- checkout: delivery area ---------- */

.checkout-country-note {
  margin: 6px 2px 0;
  color: var(--color-text-light, #8a8a8a);
  font-size: 0.78rem;
  line-height: 1.45;
}
