/*
 * Fractal Network store: the few pieces Tebex's own stylesheet used to provide (popup and toast placement,
 * the close button), plus the custom store's extras. Colours come from the theme's variables.
 */

/* popups: a dimmed layer over the page, the box in the middle */
.popup { position: fixed; inset: 0; z-index: 60; display: flex; overflow-y: auto; transition: opacity .18s; }
.popup[hidden] { display: none; }
.popup-scroll-cont { display: flex; align-items: center; justify-content: center; min-height: 100%; width: 100%; padding: 16px; }
.popup-content { position: relative; width: 100%; max-width: 460px; animation: pop-in .18s ease-out; }
.popup-content.basket-popup-content { max-width: 560px; }
.popup-content.detail-pop { max-width: 760px; padding: 0; }
@keyframes pop-in { from { transform: translateY(14px); opacity: 0; } }
.popup-close { position: absolute; display: grid; place-items: center; cursor: pointer; }
.popup-close svg { width: 14px; height: 14px; color: var(--color-muted); }
.popup-close:hover svg { color: var(--color-ink); }
body.popup-open { overflow: hidden; }

/* toasts, bottom right */
.toaster { position: fixed; z-index: 70; display: flex; flex-direction: column; gap: 10px; pointer-events: none; }
.toast { pointer-events: auto; display: flex; align-items: center; gap: 10px; color: var(--color-ink); animation: pop-in .2s ease-out; }
.toast .toast-text { flex: 1; min-width: 0; }
.toast-close { width: 28px; height: 28px; display: grid; place-items: center; cursor: pointer; }
.toast-close svg { width: 12px; height: 12px; color: var(--color-muted); }

/* the basket's code fields (coupon, gift card, creator code) */
.basket-codes { display: grid; gap: 8px; padding: 12px 24px 0; }
.basket-codes form { display: flex; gap: 8px; }
.basket-codes .input { height: 42px; font-size: 14px; flex: 1; min-width: 0; }
.basket-codes .applied { display: flex; align-items: center; justify-content: space-between; gap: 8px; font-size: 13px; color: var(--color-muted); }
.basket-codes .applied b { color: var(--color-ink); font-weight: 600; }
.basket .basket-item img.thumb { width: 44px; height: 44px; object-fit: contain; }
.basket-checkout .total { display: flex; align-items: baseline; justify-content: space-between; margin-bottom: 14px; }
.basket-checkout .total span { color: var(--color-muted); font-size: 13px; }

/* busy state on buttons and the basket while Tebex answers */
.is-busy { opacity: .6; pointer-events: none; }
.btn[disabled] { opacity: .5; pointer-events: none; }

/* a loading shimmer for cards */
.skeleton { min-height: 160px; background: linear-gradient(90deg, transparent, #ffffff08, transparent) var(--color-surface); background-size: 200% 100%; animation: shimmer 1.4s infinite; }
@keyframes shimmer { to { background-position: -200% 0; } }

/* the thank-you page */
.thanks-head { width: 120px; height: auto; margin: 0 auto; image-rendering: pixelated; }
