/* ============================================================
   Figmooo Store — components the template has no equivalent for.
   style.css is the template's own build, unmodified (same accent
   #8358FF, same jacarta neutrals). topup.css is generated.
   In production this file becomes an @layer components block in
   src/css/style.css and compiles with the rest (dev doc §8.4).
   ============================================================ */

:root {
  --fs-accent: #8358ff;
  --fs-accent-dark: #7444ff;
  --fs-ink: #131740;
  --fs-line: #e7e8ec;
  --fs-line-dark: #363a5d;
}

/* --- badges ------------------------------------------------------ */
.badge {
  display: inline-flex;
  align-items: center;
  border-radius: 0.375rem;
  padding: 0.28rem 0.55rem;
  font-family: "CalSans-SemiBold", sans-serif;
  font-size: 0.625rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  line-height: 1;
  color: #fff;
  white-space: nowrap;
  z-index: 1;
}
.badge-new { background: #10b981; }
.badge-best { background: var(--fs-accent); }
.badge-limited { background: var(--fs-ink); }
.badge-preorder { background: #428af8; }
.badge-mto { background: #ef4444; }
.badge-sale { background: #fa6d1e; }
.dark .badge-limited { background: #fff; color: var(--fs-ink); }

/* --- stock indicator --------------------------------------------- */
.stock {
  display: inline-flex;
  align-items: center;
  font-size: 0.75rem;
  font-weight: 500;
  color: #5a5d79;
  white-space: nowrap;
}
.dark .stock { color: #a1a2b3; }
.stock::before {
  content: "";
  width: 0.5rem;
  height: 0.5rem;
  border-radius: 50%;
  margin-right: 0.4rem;
  background: currentColor;
}
.stock-in { color: #10b981; }
.stock-low { color: #fa6d1e; }
.stock-pre { color: #428af8; }
.stock-mto { color: #ef4444; }
.stock-out { color: #a1a2b3; }
.dark .stock-in { color: #34d399; }

/* --- price ------------------------------------------------------- */
.price-old { text-decoration: line-through; }

/* --- rating ------------------------------------------------------ */
.stars svg + svg { margin-left: 1px; }

/* --- "powered by" chip ------------------------------------------- */
.powered {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  border-radius: 999px;
  padding: 0.3rem 0.7rem 0.3rem 0.4rem;
  background: rgba(131, 88, 255, 0.1);
  color: var(--fs-accent-dark);
  font-family: "CalSans-SemiBold", sans-serif;
  font-size: 0.75rem;
  white-space: nowrap;
}
.powered::before {
  content: "";
  width: 1.1rem;
  height: 1.1rem;
  border-radius: 0.35rem;
  background: var(--fs-accent) url("../img/brand/figmooo-mark.svg") center / cover;
}
.dark .powered { background: rgba(131, 88, 255, 0.22); color: #c9b8ff; }

/* --- quantity stepper -------------------------------------------- */
.qty {
  display: inline-flex;
  align-items: center;
  border: 1px solid var(--fs-line);
  border-radius: 999px;
  overflow: hidden;
  background: #fff;
}
.dark .qty { border-color: var(--fs-line-dark); background: #363a5d; }
.qty-btn {
  width: 2.5rem;
  height: 2.5rem;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: var(--fs-ink);
  transition: 0.15s;
}
.dark .qty-btn { color: #fff; }
.qty-btn:hover { background: var(--fs-accent); color: #fff; }
.qty-input {
  width: 3rem;
  height: 2.5rem;
  border: 0;
  padding: 0;
  text-align: center;
  font-weight: 600;
  color: var(--fs-ink);
  background: transparent;
  -moz-appearance: textfield;
  appearance: textfield;
}
.qty-input:focus { outline: 0; box-shadow: none; --tw-ring-shadow: 0 0 #0000; }
.qty-input::-webkit-outer-spin-button,
.qty-input::-webkit-inner-spin-button { -webkit-appearance: none; margin: 0; }
.dark .qty-input { color: #fff; }
.qty.qty-sm .qty-btn, .qty.qty-sm .qty-input { height: 2rem; }
.qty.qty-sm .qty-btn { width: 2rem; }
.qty.qty-sm .qty-input { width: 2.25rem; font-size: 0.875rem; }

/* --- variant pills / gallery thumbs ------------------------------ */
.swatch.is-active { border-color: var(--fs-accent); background: rgba(131, 88, 255, 0.08); color: var(--fs-accent-dark); }
.dark .swatch.is-active { color: #c9b8ff; }
.thumb { transition: 0.15s; }
.thumb.is-active { border-color: var(--fs-accent); }
.gallery-main { transition: opacity 0.2s; }

/* --- filter chips (home) ----------------------------------------- */
.filter-chip.chip-active { background: var(--fs-accent) !important; border-color: transparent; color: #fff !important; }
.dark .filter-chip.chip-active { background: var(--fs-accent) !important; }
.js-age-chip.chip-active { background: var(--fs-accent); border-color: transparent; color: #fff; }

/* --- cart count -------------------------------------------------- */
.count-badge {
  position: absolute;
  top: -0.3rem;
  right: -0.3rem;
  min-width: 1.1rem;
  height: 1.1rem;
  padding: 0 0.3rem;
  border-radius: 999px;
  background: var(--fs-accent);
  color: #fff;
  font-size: 0.625rem;
  font-weight: 700;
  line-height: 1.1rem;
  text-align: center;
  border: 2px solid #fff;
  box-sizing: content-box;
  transition: transform 0.2s;
}
.dark .count-badge { border-color: #0d102d; }
.count-badge.is-empty { display: none; }
.count-badge.bump { transform: scale(1.35); }

/* --- mini-cart drawer (a Bootstrap modal pinned to the right) ---- */
.cart-drawer .modal-dialog.cart-drawer-panel {
  position: fixed;
  top: 0;
  right: 0;
  bottom: 0;
  margin: 0;
  width: 100%;
  max-width: 26rem;
  height: 100%;
  transform: translateX(100%);
  transition: transform 0.3s ease;
}
.cart-drawer.show .modal-dialog.cart-drawer-panel { transform: translateX(0); }
.cart-drawer .modal-content { margin: 0; height: 100%; border-radius: 0; }
.cart-drawer .modal-body { flex: 1 1 auto; }

/* --- toast ------------------------------------------------------- */
.toast {
  position: fixed;
  left: 50%;
  bottom: 1.5rem;
  z-index: 70;
  transform: translate(-50%, 1rem);
  opacity: 0;
  pointer-events: none;
  background: var(--fs-ink);
  color: #fff;
  padding: 0.7rem 1.1rem;
  border-radius: 999px;
  font-size: 0.875rem;
  box-shadow: 0 10px 30px rgba(13, 16, 45, 0.25);
  transition: 0.25s;
  white-space: nowrap;
}
.toast.is-on { opacity: 1; transform: translate(-50%, 0); pointer-events: auto; }
.toast a { color: #c9b8ff; margin-left: 0.6rem; font-weight: 600; }

/* --- utilities the template build lacks --------------------------- */
.font-normal { font-weight: 400; }

/* --- misc -------------------------------------------------------- */
.mono { font-family: "SFMono-Regular", ui-monospace, Menlo, Consolas, monospace; font-size: 0.8em; }
.hero-art { filter: drop-shadow(0 24px 40px rgba(83, 52, 200, 0.25)); }
.is-hidden { display: none !important; }
.sticky-summary { position: sticky; top: 7rem; }
.js-product-card.is-hidden { display: none !important; }
.no-scrollbar::-webkit-scrollbar { display: none; }
.list-row .badge { margin-left: 0.5rem; }

/* v0.6 — skeleton cards shown while the API loads */
.skeleton-card { min-height: 1px; }
.skeleton { background: linear-gradient(90deg, #f1f0f7 25%, #e6e4f2 50%, #f1f0f7 75%); background-size: 200% 100%; animation: shimmer 1.2s ease-in-out infinite; }
.dark .skeleton, [data-scheme="dark"] .skeleton { background: linear-gradient(90deg, #363a5e 25%, #42466b 50%, #363a5e 75%); background-size: 200% 100%; }
@keyframes shimmer { 0% { background-position: 200% 0; } 100% { background-position: -200% 0; } }
.js-nav-chevron svg { transition: transform .2s; }
.js-nav-chevron[aria-expanded="true"] svg { transform: rotate(180deg); }

/* account button when signed in */
.js-account-btn.is-signed-in { border-color: #8358ff; }
.js-account-btn.is-signed-in svg { fill: #8358ff; }
