/* Loaded only by the German Whatnot buyer page on narrow viewports. */
.whatnot-purchase-hero > .wrap {
  position: relative;
  padding-top: 56px;
}
.whatnot-purchase-hero .page-heading,
.whatnot-purchase-hero .page-heading > div,
.whatnot-purchase-hero .intro {
  position: static;
}
.whatnot-purchase-hero .whatnot-guide {
  position: absolute;
  top: 6px;
  left: 0;
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  max-width: 100%;
  font-size: 15px;
  line-height: 1.3;
  font-weight: 600;
  color: #e2e8f0;
  text-underline-offset: 3px;
}

/* In short landscapes, leave room for both the guide and an informed consent decision. */
@media (orientation: landscape) and (min-width: 500px) and (max-width: 900px) and (max-height: 480px) {
  body:has(.whatnot-purchase-hero) {
    --whatnot-landscape-panel-width: clamp(340px, 60vw, 416px);
  }
  body:has(.whatnot-purchase-hero) .analytics-consent:not([hidden]) {
    inset: auto 8px 8px auto;
    width: var(--whatnot-landscape-panel-width);
    max-width: none;
    max-height: calc(100dvh - 16px);
    display: grid;
    grid-template-rows: auto minmax(0, 1fr) auto auto;
    gap: 5px;
    padding: 11px 14px;
    font-size: 1rem;
    line-height: 1.35;
  }
  body:has(.whatnot-purchase-hero) .analytics-consent h2,
  body:has(.whatnot-purchase-hero) .analytics-consent p,
  body:has(.whatnot-purchase-hero) .analytics-consent-actions {
    margin: 0;
  }
  body:has(.whatnot-purchase-hero) .analytics-consent p {
    overflow-y: auto;
    overscroll-behavior-y: contain;
  }
  body:has(.whatnot-purchase-hero) .analytics-consent-actions {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 8px;
  }
  body:has(.whatnot-purchase-hero) .analytics-consent-actions button {
    min-height: 44px;
  }
  .whatnot-purchase-hero .whatnot-guide {
    max-width: calc(100vw - var(--whatnot-landscape-panel-width) - 52px);
  }
}
