html.whop-modal-open { overflow: hidden; }
#whop-modal { position: fixed; inset: 0; z-index: 2147483000; display: flex; align-items: center; justify-content: center; }
.whop-modal__backdrop { position: absolute; inset: 0; background: rgba(0, 0, 0, .55); }
.whop-modal__panel { position: relative; width: min(560px, calc(100vw - 32px)); max-height: calc(100vh - 32px); overflow: auto; background: #fff; border-radius: 16px; padding: 48px 20px 20px; box-shadow: 0 20px 60px rgba(0, 0, 0, .3); }
.whop-modal__close { position: absolute; top: 10px; right: 12px; width: 36px; height: 36px; border: 0; background: transparent; font-size: 28px; line-height: 1; cursor: pointer; color: #111; }
.whop-modal__loading, .whop-modal__error { padding: 40px 0; text-align: center; font: 14px/1.4 system-ui, sans-serif; color: #555; }
.whop-unavailable { opacity: .5; cursor: not-allowed !important; }
@media (max-width: 600px) { #whop-modal { align-items: flex-end; } .whop-modal__panel { width: 100vw; max-height: 92vh; border-radius: 16px 16px 0 0; } }

/* search page */
.whop-search__form { display: flex; gap: 8px; margin: 8px 0 16px; }
.whop-search__input { flex: 1; min-width: 0; padding: 12px 14px; border: 1px solid #ccc; border-radius: 8px; font: inherit; }
.whop-search__btn { padding: 12px 20px; border: 0; border-radius: 999px; background: #000; color: #fff; font: inherit; cursor: pointer; }
.whop-search__count { color: #666; margin: 0 0 12px; }
.whop-search__results { list-style: none; padding: 0; margin: 0; display: grid; gap: 12px; }
.whop-search__item a { display: flex; gap: 14px; align-items: center; text-decoration: none; color: inherit; padding: 10px; border: 1px solid #eee; border-radius: 10px; }
.whop-search__item img, .whop-search__noimg { width: 64px; height: 64px; object-fit: cover; border-radius: 6px; background: #f2f2f2; flex: none; }
.whop-search__item small { display: block; text-transform: uppercase; letter-spacing: .05em; color: #888; font-size: 11px; }
.whop-search__item strong { display: block; }
.whop-search__item span span { display: block; color: #666; font-size: 13px; }

/* header cart drawer (whop-shop.js) */
html.dg-cart-open { overflow: hidden; }
.dg-cart { position: fixed; inset: 0; z-index: 2147482000; pointer-events: none; }
.dg-cart.is-open { pointer-events: auto; }
.dg-cart__backdrop { position: absolute; inset: 0; background: rgba(0, 0, 0, .45); opacity: 0; transition: opacity .25s ease; }
.dg-cart.is-open .dg-cart__backdrop { opacity: 1; }
.dg-cart__panel { position: absolute; top: 0; right: 0; bottom: 0; width: min(420px, 100vw); display: flex; flex-direction: column; background: #fff; color: #000; box-shadow: -10px 0 40px rgba(0, 0, 0, .15); transform: translateX(100%); transition: transform .3s ease; font-family: Onest, system-ui, -apple-system, "Segoe UI", sans-serif; }
.dg-cart.is-open .dg-cart__panel { transform: none; }
.dg-cart__head { display: flex; align-items: center; justify-content: space-between; padding: 18px 20px; border-bottom: 1px solid #e6e6e6; }
.dg-cart__heading { margin: 0; font-size: 20px; font-weight: 500; }
.dg-cart__close { width: 36px; height: 36px; margin-right: -8px; border: 0; background: transparent; font-size: 30px; line-height: 1; cursor: pointer; color: #000; }
.dg-cart__body { flex: 1; display: flex; flex-direction: column; min-height: 0; }
.dg-cart__lines { list-style: none; margin: 0; padding: 8px 20px; overflow: auto; flex: 1; }
.dg-cart__line { display: flex; gap: 14px; align-items: flex-start; padding: 14px 0; border-bottom: 1px solid #eee; }
.dg-cart__img { width: 72px; height: 72px; flex: none; object-fit: contain; background: #f6f6f6; border-radius: 10px; }
.dg-cart__info { flex: 1; min-width: 0; }
.dg-cart__title { margin: 0 0 4px; font-size: 15px; font-weight: 600; line-height: 1.25; }
.dg-cart__meta { margin: 0 0 8px; font-size: 13px; line-height: 1.3; color: #555; }
.dg-cart__remove { padding: 0; border: 0; background: none; font: inherit; font-size: 13px; color: #000; text-decoration: underline; cursor: pointer; }
.dg-cart__price { display: flex; flex-direction: column; align-items: flex-end; gap: 2px; font-size: 15px; white-space: nowrap; }
.dg-cart__price s { font-size: 13px; color: #777; }
.dg-cart__foot { padding: 16px 20px calc(20px + env(safe-area-inset-bottom)); border-top: 1px solid #e6e6e6; }
.dg-cart__row { display: flex; justify-content: space-between; margin: 0 0 8px; font-size: 15px; }
.dg-cart__btn { display: flex; align-items: center; justify-content: center; width: 100%; min-height: 56px; margin-top: 12px; border-radius: 999px; background: #000; color: #fff !important; font-size: 17px; font-weight: 600; text-decoration: none; }
.dg-cart__empty { padding: 40px 20px; text-align: center; font-size: 16px; }
.dg-cart__empty p { margin: 0 0 8px; }
