/* Ad-only styles: never requested on the landing, catalog home or review pages. */
body.has-top-ad .topbar {
  top: var(--top-ad-height, 118px);
}

.header-ad {
  position: relative;
  z-index: 31;
  background: #0b0b0c;
  border-bottom: 1px solid rgba(255, 255, 255, .13);
  padding: 18px 42px 10px;
  width: 100%;
  box-sizing: border-box;
}

.header-ad-label {
  position: absolute;
  top: 5px;
  left: 12px;
  font: 10px/1.2 Arial, sans-serif;
  letter-spacing: .08em;
  text-transform: uppercase;
  color: #929292;
}

.header-ad-close {
  position: absolute;
  top: 7px;
  right: 10px;
  z-index: 2;
  display: grid;
  place-items: center;
  width: 29px;
  height: 29px;
  padding: 0;
  border: 1px solid rgba(255, 255, 255, .22);
  border-radius: 50%;
  background: #28282c;
  color: #fff;
  font-size: 15px;
  line-height: 1;
  cursor: pointer;
}

.header-ad-close:hover,
.header-ad-close:focus-visible {
  background: #b52929;
}

.header-ad-viewport {
  position: relative;
  width: min(728px, 100%);
  height: 90px;
  margin: 0 auto;
  overflow: hidden;
}

.header-ad-creative {
  position: absolute;
  top: 0;
  left: 50%;
  width: 728px;
  height: 90px;
  transform: translateX(-50%) scale(1);
  transform-origin: center top;
}

#floating-ad-overlay {
  position: fixed;
  inset: 0;
  z-index: 999999;
  display: flex;
  justify-content: center;
  align-items: center;
  background: rgba(0, 0, 0, .45);
  opacity: 1;
  visibility: visible;
  transition: opacity .35s ease, visibility .35s ease;
}

#floating-ad-overlay.hide {
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
}

.floating-ad-box {
  position: relative;
  width: 300px;
  max-width: 92vw;
  overflow: hidden;
  border-radius: 14px;
  background: #fff;
  box-shadow: 0 15px 50px rgba(0, 0, 0, .25);
  animation: popupAnimation .35s ease;
}

@keyframes popupAnimation {
  from { transform: translateY(15px) scale(.92); opacity: 0; }
  to { transform: translateY(0) scale(1); opacity: 1; }
}

.floating-ad-close {
  position: absolute;
  top: 8px;
  right: 8px;
  z-index: 2;
  width: 32px;
  height: 32px;
  padding: 0;
  border: 0;
  border-radius: 50%;
  display: flex;
  justify-content: center;
  align-items: center;
  background: rgba(0, 0, 0, .75);
  color: #fff;
  font-size: 18px;
  cursor: pointer;
  transition: .25s;
}

.floating-ad-close:hover {
  transform: scale(1.08);
  background: #e53935;
}

.floating-ad-content {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 300px;
  height: 250px;
  background: #fff;
}

.floating-ad-content img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

@media (max-width: 480px) {
  .header-ad { padding: 19px 40px 8px; }
  .floating-ad-content { width: 100%; aspect-ratio: 300 / 250; height: auto; }
}
