/* Invitani's welcome offer dialog (storefront-welcome.js, welcome-offer.ts). Premium-home palette: wine card, paper text,
   pink figure, gold hairline; pill buttons; phone first. Self-contained, because it rides every marketing page. */
.welcome-offer {
  padding: 0;
  border: 0;
  background: transparent;
  max-width: min(440px, calc(100vw - 32px));
  width: 100%;
  color: #fff8e9;
  /* Never taller than the screen: on a short screen the card scrolls inside the dialog, so its buttons stay reachable. */
  max-height: calc(100vh - 32px);
  max-height: calc(100dvh - 32px - env(safe-area-inset-top, 0px) - env(safe-area-inset-bottom, 0px));
  overflow: auto;
  overscroll-behavior: contain;
  -webkit-overflow-scrolling: touch;
}
.welcome-offer::backdrop {
  background: rgba(20, 8, 16, 0.62);
  backdrop-filter: blur(6px);
}
.welcome-offer[open] { animation: welcome-offer-in 0.42s cubic-bezier(0.2, 0.8, 0.2, 1) both; }
@keyframes welcome-offer-in {
  from { opacity: 0; transform: translateY(18px) scale(0.98); }
  to { opacity: 1; transform: none; }
}
.welcome-offer-card {
  position: relative;
  display: grid;
  gap: 14px;
  justify-items: center;
  text-align: center;
  padding: 36px 26px 22px;
  border-radius: 18px;
  background:
    radial-gradient(120% 80% at 50% 0%, rgba(247, 173, 193, 0.22), transparent 62%),
    linear-gradient(160deg, #4a1530, #3c1025 58%, #2b0b1b);
  border: 1px solid rgba(230, 205, 143, 0.45);
  box-shadow: 0 30px 70px -28px rgba(0, 0, 0, 0.75), inset 0 1px 0 rgba(255, 248, 233, 0.08);
}
.welcome-offer-x {
  position: absolute;
  top: 10px;
  right: 12px;
  width: 36px;
  height: 36px;
  border: 0;
  border-radius: 999px;
  background: transparent;
  color: rgba(255, 248, 233, 0.75);
  font-size: 24px;
  line-height: 1;
  cursor: pointer;
}
.welcome-offer-x:hover { background: rgba(255, 248, 233, 0.08); color: #fff8e9; }
.welcome-offer-figure {
  margin: 0;
  font-family: "Brand Display", "VF Serif", Palatino, Georgia, serif;
  font-variant-numeric: tabular-nums;
  font-size: clamp(64px, 18vw, 92px);
  line-height: 0.9;
  color: #f7adc1;
  letter-spacing: -0.02em;
  text-shadow: 0 10px 30px rgba(247, 173, 193, 0.25);
}
.welcome-offer-figure span { font-size: 0.5em; margin-left: 2px; vertical-align: 0.6em; }
.welcome-offer h2 {
  margin: 0;
  font-family: "Brand Display", "VF Serif", Palatino, Georgia, serif;
  font-weight: 400;
  font-size: clamp(24px, 6.4vw, 30px);
  line-height: 1.15;
  text-wrap: balance;
  color: #fff8e9;
}
.welcome-offer-body {
  margin: 0;
  max-width: 34ch;
  font-size: 15.5px;
  line-height: 1.55;
  color: rgba(255, 248, 233, 0.86);
}
.welcome-offer-fine {
  margin: -4px 0 0;
  max-width: 34ch;
  font-size: 13px;
  line-height: 1.45;
  color: rgba(255, 248, 233, 0.7);
}
.welcome-offer-actions {
  display: grid;
  gap: 10px;
  width: 100%;
  margin-top: 6px;
  justify-items: center;
}
.welcome-offer-actions .btn {
  width: 100%;
  justify-content: center;
  border-radius: 999px;
  background: #f7adc1;
  color: #3c1025;
  border-color: transparent;
  box-shadow: 0 14px 28px -16px rgba(247, 173, 193, 0.9);
  font-weight: 600;
}
.welcome-offer-actions .btn:hover { background: #fbc4d3; color: #3c1025; transform: translateY(-1px); }
.welcome-offer-actions .btn:active { transform: translateY(1px) scale(0.98); }
.welcome-offer-login {
  color: #e6cd8f;
  font-size: 14.5px;
  text-decoration: underline;
  text-underline-offset: 3px;
  padding: 6px 10px;
}
.welcome-offer-dismiss {
  border: 0;
  background: transparent;
  color: rgba(255, 248, 233, 0.6);
  font: inherit;
  font-size: 13.5px;
  padding: 6px 12px;
  cursor: pointer;
}
.welcome-offer-dismiss:hover { color: #fff8e9; }
.welcome-offer :focus-visible { outline: 2px solid #e6cd8f; outline-offset: 3px; }
/* Above the order button, for a signed-in customer: ready, or one email away. */
.welcome-offer-note {
  margin: 0 0 12px;
  padding: 10px 14px;
  border-radius: 14px;
  border: 1px solid rgba(110, 47, 62, 0.22);
  background: #fdeef2;
  color: #3c1025;
  font-size: 14.5px;
  line-height: 1.45;
  max-width: 46ch;
}
.welcome-offer-note a { color: #6e2f3e; font-weight: 600; text-underline-offset: 3px; }
/* Phones: a bottom sheet the thumb reaches, not a box over the middle of the page. */
@media (max-width: 600px) {
  .welcome-offer {
    margin: auto 0 0;
    max-width: 100vw;
    width: 100vw;
    max-height: calc(100vh - 12px);
    max-height: calc(100dvh - 12px - env(safe-area-inset-top, 0px));
  }
  .welcome-offer-card {
    border-radius: 22px 22px 0 0;
    border-bottom: 0;
    padding: 30px 20px calc(18px + env(safe-area-inset-bottom, 0px));
  }
  .welcome-offer[open] { animation-name: welcome-offer-up; }
  @keyframes welcome-offer-up {
    from { transform: translateY(100%); }
    to { transform: none; }
  }
}
/* Short screens (a phone on its side, a small laptop window): a smaller figure and tighter spacing, so the buttons are
   on screen without scrolling where they can be; the dialog still scrolls when they cannot. */
@media (max-height: 620px) {
  .welcome-offer-card { gap: 10px; padding-top: 26px; padding-bottom: calc(14px + env(safe-area-inset-bottom, 0px)); }
  .welcome-offer-figure { font-size: clamp(48px, 12vh, 64px); }
  .welcome-offer h2 { font-size: clamp(20px, 5vh, 26px); }
  .welcome-offer-body { font-size: 14.5px; line-height: 1.45; }
}
@media (prefers-reduced-motion: reduce) {
  .welcome-offer[open] { animation: none; }
}
