/* Ausadhium247 Prescription Banner
   Palette taken from the site banner: deep blue + mint. */

.axrx-banner,
.axrx-modal {
  --axrx-blue-900: #0a3f7e;
  --axrx-blue-700: #1058a7;
  --axrx-blue-500: #1a6fc9;
  --axrx-mint-300: #7bf0d4;
  --axrx-mint-500: #2dd4bf;
  --axrx-ink: #0b2a4a;
  --axrx-mist: #f2f7fd;
  --axrx-line: #d3deec;
  --axrx-danger: #c62f3a;
  --axrx-radius: 8px;
}

.axrx-banner,
.axrx-banner *,
.axrx-modal,
.axrx-modal * { box-sizing: border-box; }


/* ============ BANNER (always 2 columns) ============ */

.axrx-banner {
  position: relative;
  isolation: isolate;
  overflow: hidden;
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  gap: 16px;
  width: 100%;
  min-height: 92px;
  margin: 16px 0;
  padding: 14px clamp(14px, 3vw, 40px);
  border-radius: var(--axrx-radius);
  background: linear-gradient(100deg, var(--axrx-blue-900) 0%, var(--axrx-blue-700) 50%, var(--axrx-blue-500) 100%);
  color: #fff;
  font-family: inherit;
}

.axrx-banner__text {
  display: flex;
  align-items: center;
  gap: 18px;
  min-width: 0;
}

.axrx-banner__icon {
  position: relative;
  flex: 0 0 auto;
  display: grid;
  place-items: center;
  width: 54px;
  height: 54px;
  border-radius: 50%;
  background: rgba(255, 255, 255, .14);
  color: #fff;
}
.axrx-banner__icon::after {
  content: "";
  position: absolute;
  inset: -2px;
  border-radius: 50%;
  border: 2px solid var(--axrx-mint-300);
  opacity: 0;
  animation: axrx-ring 3.2s ease-out infinite;
}

.axrx-banner__copy { min-width: 0; }

.axrx-banner .axrx-banner__title {
  margin: 0;
  padding: 0;
  color: #fff;
  font-family: inherit;
  font-size: clamp(17px, 2.3vw, 26px);
  font-weight: 800;
  line-height: 1.15;
  letter-spacing: -.01em;
  text-transform: none;
}

.axrx-banner .axrx-banner__desc {
  margin: 4px 0 0;
  padding: 0;
  color: #d4e6ff;
  font-size: clamp(12px, 1.35vw, 15px);
  line-height: 1.35;
}

/* decoration (kept faint; the button is the one loud thing) */
.axrx-deco { position: absolute; z-index: -1; pointer-events: none; color: rgba(255, 255, 255, .13); }
.axrx-deco--wave { top: 8px; right: 270px; animation: axrx-drift 9s ease-in-out infinite alternate; }
.axrx-deco--plus { font-weight: 700; line-height: 1; animation: axrx-float 7s ease-in-out infinite; }
.axrx-deco--p1 { right: 24%; top: 16%; font-size: 26px; }
.axrx-deco--p2 { right: 9%;  bottom: 12%; font-size: 34px; animation-delay: -2.5s; }
.axrx-deco--p3 { right: 38%; bottom: 18%; font-size: 18px; animation-delay: -4.5s; }


/* ============ CTA BUTTON ============ */

.axrx-banner .axrx-cta {
  position: relative;
  overflow: hidden;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  height: auto;
  min-height: 0;
  margin: 0;
  padding: 13px 24px;
  border: 0;
  border-radius: 999px;
  background: linear-gradient(135deg, var(--axrx-mint-300), var(--axrx-mint-500));
  color: var(--axrx-ink);
  font-family: inherit;
  font-size: 15px;
  font-weight: 800;
  line-height: 1.2;
  letter-spacing: 0;
  text-transform: none;
  text-decoration: none;
  white-space: nowrap;
  cursor: pointer;
  box-shadow: 0 6px 18px rgba(4, 28, 62, .35);
  transition: transform .2s ease, box-shadow .2s ease;
  animation: axrx-pulse 2.4s ease-out infinite;
  -webkit-tap-highlight-color: transparent;
}
.axrx-banner .axrx-cta:hover,
.axrx-banner .axrx-cta:focus-visible {
  transform: translateY(-2px);
  box-shadow: 0 10px 24px rgba(4, 28, 62, .45);
  color: var(--axrx-ink);
}
.axrx-banner .axrx-cta:active { transform: translateY(0) scale(.97); }
.axrx-banner .axrx-cta:focus-visible { outline: 3px solid #fff; outline-offset: 3px; }

/* light sweep */
.axrx-cta::before {
  content: "";
  position: absolute;
  top: 0; bottom: 0; left: -60%;
  width: 40%;
  background: linear-gradient(100deg, transparent, rgba(255, 255, 255, .65), transparent);
  transform: skewX(-20deg);
  animation: axrx-sweep 3.6s ease-in-out infinite;
}

.axrx-cta__icon { display: grid; place-items: center; animation: axrx-lift 1.6s ease-in-out infinite; }
.axrx-cta__label--short { display: none; }


/* ============ MODAL ============ */

.axrx-modal {
  position: fixed;
  inset: 0;
  z-index: 999999;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 16px;
  visibility: hidden;
  opacity: 0;
  transition: opacity .25s ease, visibility 0s linear .25s;
  font-family: inherit;
  color: var(--axrx-ink);
}
.axrx-modal.is-open { visibility: visible; opacity: 1; transition-delay: 0s; }

.axrx-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(6, 28, 58, .6);
  -webkit-backdrop-filter: blur(3px);
  backdrop-filter: blur(3px);
}

.axrx-dialog {
  position: relative;
  display: flex;
  flex-direction: column;
  width: 100%;
  max-width: 560px;
  max-height: min(92vh, 720px);
  max-height: min(92dvh, 720px);
  overflow: hidden;
  border-radius: 16px;
  background: #fff;
  box-shadow: 0 30px 80px rgba(4, 22, 48, .45);
  transform: translateY(24px) scale(.97);
  transition: transform .32s cubic-bezier(.2, .9, .3, 1.15);
  outline: none;
}
.axrx-modal.is-open .axrx-dialog { transform: none; }

.axrx-dialog__head {
  position: relative;
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 18px 56px 18px 20px;
  background: linear-gradient(100deg, var(--axrx-blue-900), var(--axrx-blue-700));
  color: #fff;
}
.axrx-dialog__badge {
  flex: 0 0 auto;
  display: grid;
  place-items: center;
  width: 46px; height: 46px;
  border-radius: 50%;
  background: rgba(255, 255, 255, .15);
}
.axrx-dialog__head h2 { margin: 0; color: #fff; font-family: inherit; font-size: 19px; font-weight: 800; line-height: 1.2; text-transform: none; }
.axrx-dialog__head p { margin: 3px 0 0; color: #cfe3ff; font-size: 13px; line-height: 1.3; }

.axrx-modal .axrx-close {
  position: absolute;
  top: 12px; right: 12px;
  display: grid;
  place-items: center;
  width: 36px; height: 36px;
  margin: 0; padding: 0;
  border: 0;
  border-radius: 50%;
  background: rgba(255, 255, 255, .15);
  color: #fff;
  cursor: pointer;
  transition: background .2s, transform .2s;
}
.axrx-modal .axrx-close:hover { background: rgba(255, 255, 255, .28); transform: rotate(90deg); }
.axrx-modal .axrx-close:focus-visible { outline: 3px solid var(--axrx-mint-300); outline-offset: 2px; }

.axrx-dialog__body { padding: 20px; overflow-y: auto; -webkit-overflow-scrolling: touch; overscroll-behavior: contain; }


/* ============ FORM ============ */

.axrx-row { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.axrx-field { margin-bottom: 14px; min-width: 0; }

.axrx-field > label:not(.axrx-drop),
.axrx-label { display: block; margin: 0 0 6px; color: var(--axrx-ink); font-size: 13.5px; font-weight: 700; }
.axrx-field > label:not(.axrx-drop) span { color: #6b7f96; font-weight: 400; }
.axrx-field > label:not(.axrx-drop) b, .axrx-label b { color: var(--axrx-danger); }

.axrx-modal .axrx-field input[type="text"],
.axrx-modal .axrx-field input[type="tel"] {
  display: block;
  width: 100%;
  height: 46px;
  margin: 0;
  padding: 0 14px;
  border: 1.5px solid var(--axrx-line);
  border-radius: 10px;
  background: #fff;
  color: var(--axrx-ink);
  font-family: inherit;
  font-size: 16px; /* 16px stops iOS zooming on focus */
  box-shadow: none;
  transition: border-color .2s, box-shadow .2s;
}
.axrx-modal .axrx-field input:focus {
  outline: none;
  border-color: var(--axrx-mint-500);
  box-shadow: 0 0 0 4px rgba(45, 212, 191, .22);
}
.axrx-modal .axrx-field input.is-invalid { border-color: var(--axrx-danger); box-shadow: 0 0 0 4px rgba(198, 47, 58, .12); }

/* honeypot, off-screen */
.axrx-hp { position: absolute !important; left: -9999px; width: 1px; height: 1px; overflow: hidden; }

/* drop zone */
.axrx-drop {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
  margin: 0;
  padding: 20px 16px;
  border: 2px dashed rgba(16, 88, 167, .4);
  border-radius: 12px;
  background: var(--axrx-mist);
  text-align: center;
  cursor: pointer;
  transition: border-color .2s, background .2s, transform .2s;
}
.axrx-drop:hover,
.axrx-drop.is-over { border-color: var(--axrx-mint-500); background: #e8faf6; }
.axrx-drop.is-over { transform: scale(1.015); }
.axrx-drop:focus-within { border-color: var(--axrx-mint-500); box-shadow: 0 0 0 4px rgba(45, 212, 191, .22); }
.axrx-drop input { position: absolute; width: 1px; height: 1px; opacity: 0; pointer-events: none; }

.axrx-drop__icon {
  display: grid; place-items: center;
  width: 44px; height: 44px;
  border-radius: 50%;
  background: var(--axrx-blue-700);
  color: #fff;
  animation: axrx-lift 1.8s ease-in-out infinite;
}
.axrx-drop__main { color: var(--axrx-ink); font-size: 15px; font-weight: 700; }
.axrx-drop__sub { color: #5d7390; font-size: 12.5px; line-height: 1.35; }

/* selected files */
.axrx-files { list-style: none; margin: 10px 0 0; padding: 0; }
.axrx-files li {
  display: flex; align-items: center; gap: 10px;
  margin: 0 0 8px; padding: 8px 10px;
  border: 1px solid var(--axrx-line);
  border-radius: 10px;
  background: #fff;
  animation: axrx-pop .28s ease-out;
}
.axrx-files .axrx-thumb {
  flex: 0 0 auto;
  display: grid; place-items: center;
  width: 40px; height: 40px;
  border-radius: 8px;
  background: #e6effa center / cover no-repeat;
  color: var(--axrx-blue-700);
  font-size: 11px; font-weight: 800;
}
.axrx-files .axrx-meta { flex: 1 1 auto; min-width: 0; }
.axrx-files .axrx-fname { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; color: var(--axrx-ink); font-size: 13.5px; font-weight: 600; }
.axrx-files .axrx-fsize { display: block; color: #6b7f96; font-size: 12px; }
.axrx-files .axrx-remove {
  flex: 0 0 auto;
  display: grid; place-items: center;
  width: 30px; height: 30px;
  margin: 0; padding: 0;
  border: 0; border-radius: 50%;
  background: transparent;
  color: #6b7f96;
  cursor: pointer;
}
.axrx-files .axrx-remove:hover { background: #fde8ea; color: var(--axrx-danger); }
.axrx-files .axrx-remove:focus-visible { outline: 2px solid var(--axrx-blue-700); }

.axrx-error {
  margin: 0 0 12px; padding: 10px 12px;
  border-radius: 10px;
  background: #fde8ea;
  color: #8f1d27;
  font-size: 13.5px; line-height: 1.35;
  animation: axrx-shake .35s ease;
}
.axrx-error[hidden] { display: none; }

/* submit */
.axrx-modal .axrx-submit {
  position: relative;
  overflow: hidden;
  display: flex; align-items: center; justify-content: center;
  width: 100%;
  height: auto; min-height: 0;
  margin: 0; padding: 14px 20px;
  border: 0; border-radius: 12px;
  background: var(--axrx-blue-700);
  color: #fff;
  font-family: inherit;
  font-size: 16px; font-weight: 800; line-height: 1.2;
  text-transform: none; letter-spacing: 0;
  cursor: pointer;
  transition: background .2s, transform .15s;
}
.axrx-modal .axrx-submit:hover { background: var(--axrx-blue-900); color: #fff; }
.axrx-modal .axrx-submit:active { transform: scale(.985); }
.axrx-modal .axrx-submit:focus-visible { outline: 3px solid var(--axrx-mint-500); outline-offset: 3px; }
.axrx-modal .axrx-submit:disabled { cursor: progress; background: var(--axrx-blue-900); }
.axrx-submit__text { position: relative; z-index: 1; }
.axrx-submit__bar {
  position: absolute; z-index: 0;
  top: 0; bottom: 0; left: 0;
  width: 0;
  background: linear-gradient(90deg, var(--axrx-mint-500), var(--axrx-mint-300));
  transition: width .2s ease;
}
.axrx-submit.is-loading .axrx-submit__text { color: var(--axrx-ink); }

.axrx-note {
  display: flex; align-items: center; justify-content: center; gap: 6px;
  margin: 12px 0 0;
  color: #5d7390; font-size: 12.5px; line-height: 1.35; text-align: center;
}
.axrx-note svg { flex: 0 0 auto; }

/* success */
.axrx-success { text-align: center; padding: 10px 0 4px; }
.axrx-success[hidden] { display: none; }
.axrx-success h3 { margin: 10px 0 6px; color: var(--axrx-ink); font-family: inherit; font-size: 22px; font-weight: 800; text-transform: none; }
.axrx-success p { margin: 0 auto 20px; max-width: 340px; color: #4b6280; font-size: 14.5px; line-height: 1.45; }
.axrx-check__ring { stroke: var(--axrx-mint-500); stroke-width: 3; stroke-dasharray: 145; stroke-dashoffset: 145; }
.axrx-check__tick { stroke: var(--axrx-blue-700); stroke-width: 4; stroke-linecap: round; stroke-linejoin: round; stroke-dasharray: 40; stroke-dashoffset: 40; }
.axrx-success.is-shown .axrx-check__ring { animation: axrx-draw .6s ease forwards; }
.axrx-success.is-shown .axrx-check__tick { animation: axrx-draw .4s .45s ease forwards; }

html.axrx-lock, html.axrx-lock body { overflow: hidden !important; }


/* ============ KEYFRAMES ============ */

@keyframes axrx-pulse {
  0%   { box-shadow: 0 6px 18px rgba(4, 28, 62, .35), 0 0 0 0 rgba(123, 240, 212, .65); }
  70%  { box-shadow: 0 6px 18px rgba(4, 28, 62, .35), 0 0 0 16px rgba(123, 240, 212, 0); }
  100% { box-shadow: 0 6px 18px rgba(4, 28, 62, .35), 0 0 0 0 rgba(123, 240, 212, 0); }
}
@keyframes axrx-sweep { 0%, 55% { left: -60%; } 100% { left: 140%; } }
@keyframes axrx-lift  { 0%, 100% { transform: translateY(2px); } 50% { transform: translateY(-3px); } }
@keyframes axrx-ring  { 0% { transform: scale(1); opacity: .8; } 60%, 100% { transform: scale(1.28); opacity: 0; } }
@keyframes axrx-float { 0%, 100% { transform: translateY(0) rotate(0); } 50% { transform: translateY(-8px) rotate(12deg); } }
@keyframes axrx-drift { from { transform: translateX(0); } to { transform: translateX(18px); } }
@keyframes axrx-pop   { from { opacity: 0; transform: translateY(6px) scale(.97); } to { opacity: 1; transform: none; } }
@keyframes axrx-shake { 0%, 100% { transform: translateX(0); } 25% { transform: translateX(-5px); } 75% { transform: translateX(5px); } }
@keyframes axrx-draw  { to { stroke-dashoffset: 0; } }


/* ============ RESPONSIVE ============ */

@media (max-width: 782px) {
  .axrx-banner { min-height: 84px; gap: 12px; }
  .axrx-banner__icon { width: 44px; height: 44px; }
  .axrx-banner__icon svg { width: 22px; height: 22px; }
  .axrx-banner__text { gap: 11px; }
  .axrx-banner .axrx-cta { padding: 12px 18px; font-size: 14px; }
}

@media (max-width: 520px) {
  .axrx-deco--wave { display: none; }
  .axrx-banner { min-height: 76px; gap: 10px; padding: 12px 12px; }
  .axrx-banner__icon { display: none; }
  .axrx-banner .axrx-banner__title { font-size: 16px; }
  .axrx-banner .axrx-banner__desc {
    font-size: 11.5px;
    display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden;
  }
  .axrx-banner .axrx-cta { flex-direction: column; gap: 3px; padding: 10px 14px; border-radius: 14px; font-size: 12.5px; }
  .axrx-cta__label--long { display: none; }
  .axrx-cta__label--short { display: inline; }
  .axrx-deco--p1, .axrx-deco--p3 { display: none; }

  /* bottom sheet */
  .axrx-modal { align-items: flex-end; padding: 0; }
  .axrx-dialog {
    max-width: none;
    max-height: 90vh; max-height: 90dvh;
    border-radius: 20px 20px 0 0;
    transform: translateY(100%);
  }
  .axrx-dialog__head { padding: 16px 54px 16px 16px; }
  .axrx-dialog__head h2 { font-size: 17px; }
  .axrx-dialog__body { padding: 16px 16px calc(16px + env(safe-area-inset-bottom, 0px)); }
  .axrx-row { grid-template-columns: 1fr; gap: 0; }
}

@media (prefers-reduced-motion: reduce) {
  .axrx-banner *, .axrx-banner, .axrx-modal, .axrx-modal * {
    animation: none !important;
    transition-duration: .01ms !important;
  }
  .axrx-check__ring, .axrx-check__tick { stroke-dashoffset: 0 !important; }
}
