/* Scoped to the email sign-in dialog; load after the existing WarmBow styles. */
.gifts-auth {
  box-sizing: border-box;
  width: min(440px, calc(100% - 32px));
  max-width: none;
  max-height: calc(100vh - 32px);
  max-height: calc(100dvh - 32px);
  margin: auto;
  padding: 24px 32px 28px;
  overflow: auto;
  overscroll-behavior: contain;
  border: 1px solid #e3e9f2;
  border-radius: 24px;
  background: #fff;
  color: #142c58;
  box-shadow: 0 24px 80px #142c5833;
  font: 400 14px/1.6 'Inter', Arial, sans-serif;
  text-align: left;
  overflow-wrap: anywhere;
  color-scheme: light;
}
.gifts-auth *, .gifts-auth *::before, .gifts-auth *::after { box-sizing: border-box; }
.gifts-auth [hidden] { display: none !important; }
.gifts-auth::backdrop { background: #142c5873; backdrop-filter: blur(4px); }
.gifts-auth[open] { animation: gifts-auth-enter 180ms ease-out both; }
.gifts-auth[open]::backdrop { animation: gifts-auth-backdrop 180ms ease-out both; }
.gifts-auth button, .gifts-auth input { font: inherit; }
.gifts-auth button { cursor: pointer; touch-action: manipulation; }
.gifts-auth :is(button, input):focus-visible { outline: 3px solid #2557d6; outline-offset: 3px; }
.gifts-auth button:disabled { cursor: not-allowed; opacity: 1; }
.gifts-auth-toolbar { display: flex; align-items: center; justify-content: space-between; min-height: 44px; margin: -8px -12px 16px; }
.gifts-auth-close, .gifts-auth-back {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-width: 44px;
  min-height: 44px;
  padding: 8px 12px;
  border: 1px solid transparent;
  border-radius: 12px;
  background: transparent;
  color: #596b87;
  transition: color 150ms, background 150ms;
}
.gifts-auth-close { margin-left: auto; font-size: 28px !important; line-height: 1 !important; }
.gifts-auth-back { font-size: 13px !important; }
.gifts-auth-close:hover, .gifts-auth-back:hover { background: #eaf1ff; color: #2557d6; }
.gifts-auth-mark { display: grid; place-items: center; width: 56px; height: 56px; margin-bottom: 16px; border-radius: 17px; background: linear-gradient(145deg, #2d62e8, #1c47bc); color: #fff; box-shadow: 0 8px 20px #2557d624; transform: rotate(-5deg); }
.gifts-auth-mark svg { width: 34px; height: 34px; overflow: visible; }
.gifts-auth-mark .bow-loop { fill: #ffffff30; stroke: #fff; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.gifts-auth-mark .bow-tail { fill: none; stroke: #fff; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.gifts-auth-mark .bow-knot { fill: #ffd45a; stroke: none; }
.gifts-auth .gifts-auth-brand { margin: 0 0 16px; color: #2557d6; font: 800 16px/1.3 'Manrope', 'Inter', Arial, sans-serif; letter-spacing: -.04em; }
.gifts-auth-brand span { color: #be5279; }
.gifts-auth h2 { margin: 0 0 12px; color: #142c58; font: 800 30px/1.2 'Manrope', 'Inter', Arial, sans-serif; letter-spacing: -.035em; }
.gifts-auth .gifts-auth-description { margin: 0; color: #596b87; font-size: 14px; line-height: 1.65; }
.gifts-auth .gifts-auth-destination { margin: 4px 0 0; color: #142c58; font-size: 14px; font-weight: 600; line-height: 1.6; }
.gifts-auth form { margin-top: 24px; }
.gifts-auth-field { min-width: 0; }
.gifts-auth-field label { display: block; margin-bottom: 8px; color: #142c58; font-size: 13px; font-weight: 600; }
.gifts-auth-field input {
  display: block;
  width: 100%;
  min-width: 0;
  min-height: 52px;
  margin: 0;
  padding: 12px 14px;
  border: 1px solid #b5c6e1;
  border-radius: 12px;
  background: #fff;
  color: #142c58;
  font-size: 16px;
  line-height: 1.5;
  transition: border-color 150ms, box-shadow 150ms;
}
.gifts-auth-field input::placeholder { color: #6d7e98; opacity: 1; }
.gifts-auth-field input:focus { border-color: #2557d6; box-shadow: 0 0 0 3px #2557d614; }
.gifts-auth-field input:disabled { background: #f7f9fd; color: #596b87; opacity: 1; }
.gifts-auth-field input[aria-invalid='true'] { border-color: #a2223a; }
.gifts-auth #gifts-auth-code { padding-left: 24px; font-size: 26px; font-weight: 600; line-height: 1.5; letter-spacing: .3em; text-align: center; font-variant-numeric: tabular-nums; }
.gifts-auth .gifts-auth-hint { margin: 8px 0 0; color: #596b87; font-size: 12px; line-height: 1.6; }
.gifts-auth .gifts-auth-error { margin: 16px 0 0; padding: 12px 14px; border: 1px solid #e8bac6; border-radius: 10px; background: #fff3f6; color: #95223a; font-size: 13px; line-height: 1.6; }
.gifts-auth-submit {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  min-height: 50px;
  margin-top: 20px;
  padding: 12px 16px;
  border: 1px solid #2557d6;
  border-radius: 12px;
  background: #2557d6;
  color: #fff;
  font-weight: 600 !important;
  line-height: 1.5;
  transition: background 150ms, border-color 150ms, transform 150ms;
}
.gifts-auth-submit:hover:not(:disabled) { border-color: #1742b7; background: #1742b7; transform: translateY(-1px); }
.gifts-auth-submit:active:not(:disabled) { transform: translateY(0); }
.gifts-auth-submit:disabled { border-color: #d5deef; background: #eaf0fb; color: #51658a; }
.gifts-auth-actions { display: flex; justify-content: space-between; flex-wrap: wrap; gap: 4px 16px; margin-top: 12px; }
.gifts-auth-link { min-height: 44px; padding: 8px 0; border: 0; border-radius: 4px; background: transparent; color: #2557d6; font-size: 13px !important; text-decoration: underline; text-underline-offset: 4px; }
.gifts-auth-link:hover:not(:disabled) { color: #1742b7; }
.gifts-auth-link:disabled { color: #596b87; text-decoration: none; font-variant-numeric: tabular-nums; }
.gifts-auth .gifts-auth-status { margin: 8px 0 0; color: #2557d6; font-size: 12px; line-height: 1.6; }
.gifts-auth-status:empty { margin: 0; }
.gifts-auth .gifts-auth-note { margin: 16px 0 0; color: #596b87; font-size: 12px; line-height: 1.6; text-align: center; }
@keyframes gifts-auth-enter { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: translateY(0); } }
@keyframes gifts-auth-backdrop { from { opacity: 0; } to { opacity: 1; } }
@media (max-width: 400px) {
  .gifts-auth { padding: 20px 20px 24px; border-radius: 20px; }
  .gifts-auth h2 { font-size: 27px; }
  .gifts-auth-toolbar { margin-bottom: 12px; }
}
@media (max-height: 560px) {
  .gifts-auth { padding-top: 16px; padding-bottom: 20px; }
  .gifts-auth-mark { display: none; }
  .gifts-auth-toolbar { margin-bottom: 8px; }
}
@media (prefers-reduced-motion: reduce) {
  .gifts-auth[open], .gifts-auth[open]::backdrop { animation: none; }
  .gifts-auth *, .gifts-auth *::before, .gifts-auth *::after { transition: none !important; scroll-behavior: auto !important; }
}
