body.home-post-popup-open {
  overflow: hidden;
}

.home-post-popup[hidden] {
  display: none;
}

.home-post-popup {
  position: fixed;
  z-index: 99999;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1rem;
}

.home-post-popup__backdrop {
  position: absolute;
  inset: 0;
  background: rgba(10, 19, 38, 0.72);
  backdrop-filter: blur(8px);
  opacity: 0;
  transition: opacity 0.35s ease;
}

.home-post-popup__dialog {
  position: relative;
  display: grid;
  grid-template-columns: minmax(0, 0.95fr) minmax(0, 1.05fr);
  width: min(960px, calc(100vw - 2rem));
  max-height: calc(100vh - 2rem);
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.45);
  border-radius: 1.75rem;
  background: #fff;
  box-shadow: 0 35px 90px rgba(0, 18, 54, 0.36);
  opacity: 0;
  transform: translateY(24px) scale(0.97);
  transition: opacity 0.35s ease, transform 0.35s ease;
}

.home-post-popup.is-visible .home-post-popup__backdrop,
.home-post-popup.is-visible .home-post-popup__dialog {
  opacity: 1;
}

.home-post-popup.is-visible .home-post-popup__dialog {
  transform: translateY(0) scale(1);
}

.home-post-popup__dialog--no-image {
  grid-template-columns: minmax(0, 1fr);
  max-width: 620px;
}

.home-post-popup__close {
  position: absolute;
  z-index: 4;
  top: 1rem;
  right: 1rem;
  display: flex;
  width: 2.75rem;
  height: 2.75rem;
  align-items: center;
  justify-content: center;
  color: #151b2b;
  border: 0;
  border-radius: 9999px;
  background: rgba(255, 255, 255, 0.94);
  box-shadow: 0 6px 20px rgba(21, 27, 43, 0.16);
  cursor: pointer;
  transition: color 0.2s ease, transform 0.2s ease;
}

.home-post-popup__close:hover,
.home-post-popup__close:focus-visible {
  color: #e6007e;
  transform: rotate(6deg) scale(1.06);
}

.home-post-popup__close:focus-visible,
.home-post-popup__button:focus-visible,
.home-post-popup__later:focus-visible {
  outline: 3px solid #ffd124;
  outline-offset: 3px;
}

.home-post-popup__close svg {
  width: 1.5rem;
  height: 1.5rem;
  fill: currentColor;
}

.home-post-popup__image {
  position: relative;
  min-height: 520px;
  overflow: hidden;
  background: #e9f1fc;
}

.home-post-popup__image::after {
  position: absolute;
  inset: 0;
  content: '';
  pointer-events: none;
  background: linear-gradient(to top, rgba(0, 72, 180, 0.32), transparent 55%);
}

.home-post-popup__image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.home-post-popup__badge {
  position: absolute;
  z-index: 2;
  left: 1.5rem;
  bottom: 1.5rem;
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.65rem 0.9rem;
  color: #0048b4;
  border-radius: 9999px;
  background: #fff;
  box-shadow: 0 10px 30px rgba(0, 18, 54, 0.22);
  font-size: 0.875rem;
  font-weight: 800;
  line-height: 1;
}

.home-post-popup__badge svg {
  width: 1.35rem;
  height: 1.35rem;
  fill: #ffd124;
}

.home-post-popup__content {
  position: relative;
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: 4.5rem 3.5rem 3.5rem;
  overflow-y: auto;
  background:
    radial-gradient(circle at 100% 0, rgba(0, 122, 255, 0.14), transparent 36%),
    radial-gradient(circle at 0 100%, rgba(230, 0, 126, 0.1), transparent 34%),
    #fff;
}

.home-post-popup__eyebrow {
  margin: 0 0 0.9rem;
  color: #e6007e;
  font-size: 0.82rem;
  font-weight: 800;
  line-height: 1.4;
  letter-spacing: 0.15em;
  text-transform: uppercase;
}

.home-post-popup__title {
  margin: 0;
  color: #151b2b;
  font-size: clamp(2rem, 3.2vw, 3.25rem);
  font-weight: 800;
  line-height: 1.12;
}

.home-post-popup__excerpt {
  margin: 1.4rem 0 0;
  color: #596277;
  font-size: 1.05rem;
  line-height: 1.75;
}

.home-post-popup__actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 1rem 1.25rem;
  margin-top: 2rem;
}

.home-post-popup__button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.65rem;
  min-height: 3.35rem;
  padding: 0.75rem 1.35rem;
  color: #fff;
  border-radius: 9999px;
  background: linear-gradient(135deg, #0048b4, #007aff);
  box-shadow: 0 12px 28px rgba(0, 72, 180, 0.26);
  font-weight: 700;
  line-height: 1.3;
  text-decoration: none;
  transition: box-shadow 0.2s ease, transform 0.2s ease;
}

.home-post-popup__button:hover {
  color: #fff;
  box-shadow: 0 15px 32px rgba(0, 72, 180, 0.36);
  transform: translateY(-2px);
}

.home-post-popup__button svg {
  width: 1.25rem;
  height: 1.25rem;
  flex: 0 0 auto;
  fill: currentColor;
}

.home-post-popup__later {
  padding: 0.5rem;
  color: #667085;
  border: 0;
  background: transparent;
  font-weight: 600;
  cursor: pointer;
  text-decoration: underline;
  text-underline-offset: 4px;
}

.home-post-popup__later:hover {
  color: #e6007e;
}

@media (max-width: 767px) {
  .home-post-popup {
    align-items: flex-end;
    padding: 0.75rem;
  }

  .home-post-popup__dialog {
    display: block;
    width: 100%;
    max-height: calc(100dvh - 1.5rem);
    overflow-y: auto;
    border-radius: 1.5rem;
  }

  .home-post-popup__image {
    min-height: 0;
    height: min(38vh, 300px);
  }

  .home-post-popup__content {
    display: block;
    padding: 2rem 1.5rem 1.75rem;
    overflow: visible;
  }

  .home-post-popup__title {
    padding-right: 1rem;
  }

  .home-post-popup__excerpt {
    font-size: 1rem;
    line-height: 1.65;
  }

  .home-post-popup__actions {
    align-items: stretch;
    flex-direction: column;
  }

  .home-post-popup__button {
    width: 100%;
  }

  .home-post-popup__later {
    align-self: center;
  }
}

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