.hsg-hail-popup,
.hsg-hail-popup * {
  box-sizing: border-box;
}

.hsg-hail-popup[hidden] {
  display: none !important;
}

.hsg-hail-popup {
  --hsg-blue: #044d9a;
  --hsg-blue-dark: #033d78;
  --hsg-blue-deep: #082f57;
  --hsg-orange: #f2b91e;
  --hsg-ink: #171a1f;
  --hsg-muted: #646b75;
  position: fixed;
  inset: 0;
  z-index: 2147483000;
  display: grid;
  place-items: center;
  padding: 24px;
  font-family: "Rubik", "Segoe UI", system-ui, -apple-system, BlinkMacSystemFont, sans-serif;
  line-height: 1.5;
}

.hsg-hail-popup__backdrop {
  position: absolute;
  inset: 0;
  background: rgba(5, 24, 43, 0.72);
  -webkit-backdrop-filter: blur(4px);
  backdrop-filter: blur(4px);
  opacity: 0;
  transition: opacity 220ms ease;
}

.hsg-hail-popup__dialog {
  position: relative;
  width: min(760px, 100%);
  max-height: min(760px, calc(100vh - 48px));
  display: grid;
  grid-template-columns: minmax(230px, 0.78fr) minmax(0, 1.22fr);
  overflow: auto;
  color: var(--hsg-ink);
  background: #fff;
  border: 1px solid rgba(255, 255, 255, 0.72);
  border-top: 4px solid var(--hsg-orange);
  border-radius: 10px;
  box-shadow: 0 28px 80px rgba(3, 26, 49, 0.34);
  opacity: 0;
  transform: translateY(18px) scale(0.975);
  transition: opacity 220ms ease, transform 280ms cubic-bezier(0.22, 1, 0.36, 1);
}

.hsg-hail-popup.is-visible .hsg-hail-popup__backdrop {
  opacity: 1;
}

.hsg-hail-popup.is-visible .hsg-hail-popup__dialog {
  opacity: 1;
  transform: translateY(0) scale(1);
}

.hsg-hail-popup__close {
  position: absolute;
  z-index: 2;
  top: 15px;
  right: 15px;
  width: 40px;
  height: 40px;
  display: grid;
  place-items: center;
  padding: 0;
  color: #536170;
  background: #f2f5f8;
  border: 0;
  border-radius: 50%;
  cursor: pointer;
  font: inherit;
  transition: color 150ms ease, background 150ms ease, transform 150ms ease;
}

.hsg-hail-popup__close span {
  display: block;
  margin-top: -3px;
  font-size: 29px;
  font-weight: 300;
  line-height: 1;
}

.hsg-hail-popup__close:hover {
  color: var(--hsg-blue-dark);
  background: #e8eef4;
  transform: rotate(4deg);
}

.hsg-hail-popup__close:focus-visible,
.hsg-hail-popup__button:focus-visible {
  outline: 3px solid rgba(242, 185, 30, 0.82);
  outline-offset: 3px;
}

.hsg-hail-popup__brand-panel {
  position: relative;
  min-height: 470px;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  overflow: hidden;
  padding: 38px 34px;
  color: #fff;
  background:
    radial-gradient(circle at 30% 23%, rgba(73, 146, 211, 0.38), transparent 34%),
    linear-gradient(150deg, #0a5aa7 0%, var(--hsg-blue-deep) 72%);
}

.hsg-hail-popup__brand-panel::after {
  position: absolute;
  right: -45px;
  bottom: -65px;
  width: 190px;
  height: 190px;
  border: 1px solid rgba(255, 255, 255, 0.13);
  border-radius: 50%;
  content: "";
}

.hsg-hail-popup__hail-mark {
  position: absolute;
  top: 128px;
  left: 50%;
  width: 142px;
  height: 142px;
  transform: translateX(-50%);
}

.hsg-hail-popup__hail-mark::before,
.hsg-hail-popup__hail-mark::after,
.hsg-hail-popup__hail-mark span {
  position: absolute;
  display: block;
  border-radius: 50%;
  content: "";
}

.hsg-hail-popup__hail-mark::before {
  inset: 7px;
  border: 1px solid rgba(255, 255, 255, 0.25);
}

.hsg-hail-popup__hail-mark::after {
  inset: 25px;
  border: 1px solid rgba(255, 255, 255, 0.13);
}

.hsg-hail-popup__hail-mark span {
  width: 20px;
  height: 20px;
  background: rgba(255, 255, 255, 0.96);
  box-shadow: 0 5px 12px rgba(1, 25, 49, 0.28);
}

.hsg-hail-popup__hail-mark span:nth-child(1) { top: 23px; left: 62px; }
.hsg-hail-popup__hail-mark span:nth-child(2) { top: 57px; left: 30px; width: 15px; height: 15px; }
.hsg-hail-popup__hail-mark span:nth-child(3) { top: 69px; left: 82px; width: 27px; height: 27px; }
.hsg-hail-popup__hail-mark span:nth-child(4) { top: 101px; left: 52px; width: 13px; height: 13px; }
.hsg-hail-popup__hail-mark span:nth-child(5) { top: 43px; left: 107px; width: 11px; height: 11px; }

.hsg-hail-popup__brand-panel p,
.hsg-hail-popup__brand-panel strong {
  position: relative;
  z-index: 1;
  margin: 0;
}

.hsg-hail-popup__brand-panel p {
  color: rgba(255, 255, 255, 0.72);
  font-size: 13px;
}

.hsg-hail-popup__brand-panel strong {
  margin-top: 4px;
  color: #fff;
  font-size: 22px;
  line-height: 1.25;
}

.hsg-hail-popup__content {
  align-self: center;
  padding: 64px 52px 48px;
}

.hsg-hail-popup__eyebrow {
  margin: 0 0 11px;
  color: var(--hsg-blue);
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0.075em;
  line-height: 1.3;
  text-transform: uppercase;
}

.hsg-hail-popup__content h2 {
  margin: 0;
  color: var(--hsg-ink);
  font-size: clamp(27px, 4vw, 38px);
  font-weight: 800;
  letter-spacing: -0.035em;
  line-height: 1.08;
}

.hsg-hail-popup__message {
  margin: 20px 0 0;
  color: var(--hsg-muted);
  font-size: 15px;
  line-height: 1.68;
}

.hsg-hail-popup__details {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
  margin-top: 22px;
}

.hsg-hail-popup__details span {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 9px;
  color: #44515e;
  background: #f2f5f8;
  border-radius: 4px;
  font-size: 11px;
  font-weight: 700;
}

.hsg-hail-popup__details span::before {
  color: var(--hsg-blue);
  content: "✓";
  font-weight: 900;
}

.hsg-hail-popup__button {
  min-height: 52px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  margin-top: 28px;
  padding: 13px 18px;
  color: #fff !important;
  background: var(--hsg-blue);
  border: 0;
  border-radius: 5px;
  box-shadow: 0 10px 24px rgba(4, 77, 154, 0.2);
  font-size: 14px;
  font-weight: 800;
  line-height: 1.2;
  text-decoration: none !important;
  transition: background 160ms ease, transform 160ms ease, box-shadow 160ms ease;
}

.hsg-hail-popup__button:hover {
  color: #fff !important;
  background: var(--hsg-blue-dark);
  box-shadow: 0 12px 28px rgba(4, 77, 154, 0.28);
  transform: translateY(-1px);
}

.hsg-hail-popup__button span {
  font-size: 21px;
  font-weight: 400;
}

.hsg-hail-popup__note {
  margin: 12px 0 0;
  color: #818892;
  font-size: 11px;
  text-align: center;
}

body.hsg-hail-popup-open {
  overflow: hidden;
}

@media (max-width: 680px) {
  .hsg-hail-popup {
    align-items: end;
    padding: 12px;
  }

  .hsg-hail-popup__dialog {
    width: 100%;
    max-height: calc(100dvh - 24px);
    grid-template-columns: 1fr;
    border-radius: 10px;
  }

  .hsg-hail-popup__brand-panel {
    min-height: 112px;
    justify-content: flex-end;
    padding: 58px 24px 18px;
  }

  .hsg-hail-popup__hail-mark {
    top: -15px;
    right: 44px;
    left: auto;
    width: 126px;
    height: 126px;
    opacity: 0.42;
    transform: none;
  }

  .hsg-hail-popup__brand-panel p,
  .hsg-hail-popup__brand-panel strong {
    display: none;
  }

  .hsg-hail-popup__close {
    top: 14px;
    right: 14px;
    color: #fff;
    background: rgba(255, 255, 255, 0.14);
  }

  .hsg-hail-popup__close:hover {
    color: #fff;
    background: rgba(255, 255, 255, 0.23);
  }

  .hsg-hail-popup__content {
    padding: 30px 24px 24px;
  }

  .hsg-hail-popup__content h2 {
    max-width: 290px;
    font-size: 29px;
  }

  .hsg-hail-popup__message {
    margin-top: 15px;
    font-size: 14px;
  }

  .hsg-hail-popup__details { margin-top: 17px; }
  .hsg-hail-popup__button { margin-top: 22px; }
}

@media (max-height: 590px) and (min-width: 681px) {
  .hsg-hail-popup__dialog { max-height: calc(100vh - 24px); }
  .hsg-hail-popup__brand-panel { min-height: 450px; }
  .hsg-hail-popup__content { padding-block: 48px 36px; }
}

@media (prefers-reduced-motion: reduce) {
  .hsg-hail-popup__backdrop,
  .hsg-hail-popup__dialog,
  .hsg-hail-popup__close,
  .hsg-hail-popup__button {
    transition: none;
  }
}
