/*
 * Carbon storefront + isometric homepage board + group modal notes.
 * Loaded last so these rules win over nexus-premium.css.
 */

:root {
  --carbon-bg: 250 19% 6%;
  --carbon-fg: 0 0% 98%;
  --carbon-card: 250 20% 4%;
  --carbon-line: 250 10% 18%;
  --carbon-muted: 250 8% 58%;
  --carbon-iris: 239 84% 67%;
  --carbon-mint: 160 72% 45%;
  --radius: 0.875rem;
}

/* Transparent navbar at the top; glass only after scroll. */
.nexus-theme .sa-header {
  background: transparent !important;
  box-shadow: none !important;
  backdrop-filter: none !important;
  -webkit-backdrop-filter: none !important;
}

.nexus-theme .sa-navbar--pills .max-w-container,
.nexus-theme .sa-navbar--floating-pill .max-w-container {
  background: transparent !important;
  border-color: transparent !important;
  box-shadow: none !important;
  backdrop-filter: none !important;
  -webkit-backdrop-filter: none !important;
}

.nexus-theme .sa-header.is-scrolled .sa-navbar--pills .max-w-container,
.nexus-theme .sa-header.is-scrolled .sa-navbar--floating-pill .max-w-container {
  background: rgba(2, 6, 23, 0.84) !important;
  border-color: rgba(255, 255, 255, 0.1) !important;
  box-shadow: 0 12px 40px rgba(0, 0, 0, 0.4) !important;
  backdrop-filter: blur(18px) saturate(1.4) !important;
  -webkit-backdrop-filter: blur(18px) saturate(1.4) !important;
}

.nexus-theme .sa-navbar-logo-img {
  height: 3.5rem;
  width: auto;
}

.nexus-register-btn {
  gap: 0.4rem;
}

.nexus-register-btn svg {
  flex-shrink: 0;
}

/* Compact nav links — small gap, not stretched empty. */
.nexus-theme .nav-pills {
  gap: 0.35rem;
}

.nexus-theme .nav-pills .sa-navbar-link {
  padding: 0.4rem 0.7rem !important;
}

.nexus-wishlist-btn {
  left: auto !important;
  right: 0.75rem !important;
}

/* Keep zip collage motion; name + price strip under the 1/1 image. */
.hero-collage__card {
  aspect-ratio: auto;
  display: flex;
  flex-direction: column;
  overflow: hidden;
}

.hero-collage__media {
  position: relative;
  aspect-ratio: 1 / 1;
  width: 100%;
  flex: 0 0 auto;
  overflow: hidden;
}

.hero-collage__card img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 1;
}

.hero-collage__fallback {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  padding: 0.625rem;
  background: linear-gradient(to top, rgba(var(--cl-background), 0.92), transparent);
}

.hero-collage__pricebar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.45rem;
  padding: 0.4rem 0.55rem;
  background: #05070e;
  border-top: 1px solid rgba(255, 255, 255, 0.08);
}

.hero-collage__pname {
  flex: 1;
  min-width: 0;
  font-size: 0.68rem;
  font-weight: 700;
  color: #e5e7eb;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.hero-collage__pricebar .hero-collage__price {
  position: static;
  flex-shrink: 0;
  font-size: 0.72rem;
  font-weight: 800;
  color: #e879f9;
}

/* Carbon product cards */
.sa-product-card--carbon {
  --background: 250 19% 6%;
  --foreground: 0 0% 98%;
  --card: 250 20% 4%;
  --border: 250 10% 18%;
  --primary: 239 84% 67%;
  --muted-foreground: 250 8% 58%;
  --radius: 0.875rem;
  background: #05070e !important;
  border: 1px solid rgba(255, 255, 255, 0.14) !important;
  box-shadow: 0 18px 40px rgba(0, 0, 0, 0.45), 0 0 0 1px rgba(0, 0, 0, 0.55);
}

.sa-product-card--carbon:hover {
  transform: none;
  border-color: rgba(255, 255, 255, 0.22) !important;
  box-shadow: 0 22px 48px rgba(0, 0, 0, 0.55);
}

.sa-product-card--carbon .sa-carbon-shine {
  background: radial-gradient(200px circle at var(--mx, 50%) var(--my, 50%), rgba(255, 255, 255, 0.2), transparent 58%);
}

.sa-product-card--carbon.hfx-spotlight::after {
  background: radial-gradient(220px circle at var(--mx, 50%) var(--my, 50%), rgba(255, 255, 255, 0.16), transparent 65%);
  z-index: 21;
}

.sa-product-card--carbon .sa-carbon-media img,
.sa-product-card--carbon .sa-product-card-media img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: inherit;
}

.sa-product-card--carbon .sa-carbon-media,
.sa-product-card--carbon .sa-product-card-media,
.sa-product-card--carbon .sa-product-card-media > div {
  height: 100%;
  width: 100%;
  border-radius: 2rem;
  overflow: hidden;
  clip-path: inset(0 round 2rem);
}

.sa-product-card .sa-product-card-media {
  border-radius: 1.25rem;
  overflow: hidden;
}

.sa-product-card .sa-product-card-media img {
  border-radius: inherit;
}

.sa-carbon-glass {
  background: rgba(8, 10, 18, 0.78);
  border: 1px solid rgba(255, 255, 255, 0.12);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
}

.sa-carbon-versions {
  display: inline-flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 0.05rem;
  padding: 0.38rem 0.7rem 0.42rem;
  border-radius: 0.9rem;
  background: rgba(8, 10, 18, 0.82);
  border: 1px solid rgba(255, 255, 255, 0.12);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  color: hsl(0 0% 98%);
}

.sa-carbon-versions-row {
  display: inline-flex;
  align-items: center;
  gap: 0.3rem;
  color: hsl(239 84% 82%);
}

.sa-carbon-versions-count {
  font-size: 0.78rem;
  font-weight: 800;
  line-height: 1;
  color: #fff;
}

.sa-carbon-versions-label {
  font-size: 0.58rem;
  font-weight: 600;
  letter-spacing: 0.01em;
  color: rgba(226, 232, 240, 0.78);
  padding-left: 1.05rem;
  line-height: 1;
}

.sa-product-card--carbon .sa-carbon-stock {
  display: flex;
  align-items: center;
  gap: 0.375rem;
  margin: 0;
  font-size: 0.68rem;
  font-weight: 600;
  color: #22c55e;
}

.sa-product-card--carbon .sa-carbon-stock::before {
  content: "";
  width: 0.25rem;
  height: 0.25rem;
  border-radius: 9999px;
  background: #22c55e;
}

.sa-product-card--carbon .sa-carbon-stock .text-t-muted,
.sa-product-card--carbon .sa-carbon-stock .text-success,
.sa-product-card--carbon .sa-carbon-stock .text-error {
  color: inherit;
}

.sa-carbon-choose {
  background: hsl(239 84% 67% / 0.18);
  color: #fff;
}

.sa-product-card--carbon:hover .sa-carbon-choose {
  background: hsl(239 84% 67%);
  color: #fff;
}

.sa-variant-list .sa-variant-row {
  width: 100%;
}

.sa-variant-list .sa-variant-row input[type="radio"] {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.sa-variant-list .sa-variant-row[aria-current="page"] {
  cursor: default;
}

.sa-variant-list .sa-variant-dot {
  opacity: 0;
}

.sa-variant-list .sa-variant-row:has(input:checked) {
  border-color: rgba(99, 102, 241, 0.6);
  background: rgba(99, 102, 241, 0.07);
  box-shadow: 0 0 0 1px rgba(99, 102, 241, 0.3);
}

.sa-variant-list .sa-variant-row:has(input:checked) .sa-variant-radio {
  border-color: #818cf8;
}

.sa-variant-list .sa-variant-row:has(input:checked) .sa-variant-dot {
  opacity: 1;
}

/* Group modal notes (admin-editable). */
.gm-note {
  display: flex;
  align-items: flex-start;
  gap: 0.65rem;
  margin-top: 0.75rem;
  padding: 0.75rem 0.85rem;
  border-radius: 0.85rem;
  font-size: 0.78rem;
  line-height: 1.45;
}

.sa-incentives-slot {
  margin-top: 1.85rem;
}

.gm-note-icon {
  width: 1rem;
  height: 1rem;
  flex-shrink: 0;
  margin-top: 0.1rem;
}

.gm-note--warn {
  border: 1px solid rgba(239, 68, 68, 0.35);
  background: rgba(127, 29, 29, 0.18);
  color: #fecaca;
}

.gm-note--warn .gm-note-icon {
  color: #f87171;
}

.gm-note--info {
  border: 1px solid rgba(255, 255, 255, 0.1);
  background: rgba(255, 255, 255, 0.03);
  color: #d1d5db;
}

.gm-note--info .gm-note-icon {
  color: #fbbf24;
}

.sa-spin[hidden] { display: none; }
.sa-spin { position: fixed; inset: 0; z-index: 80; display: grid; place-items: center; }
.sa-spin-backdrop { position: absolute; inset: 0; background: rgba(2, 6, 23, 0.78); }
.sa-spin-modal {
  position: relative;
  width: min(26rem, calc(100vw - 2rem));
  padding: 1.5rem 1.35rem 1.35rem;
  border-radius: 1.4rem;
  border: 1px solid rgba(255, 255, 255, 0.12);
  background: #070910;
  box-shadow: 0 30px 80px rgba(0, 0, 0, 0.55);
  text-align: center;
  color: #fff;
}
.sa-spin-close {
  position: absolute;
  top: 0.6rem;
  right: 0.75rem;
  font-size: 1.4rem;
  color: #94a3b8;
  background: none;
  border: 0;
  cursor: pointer;
}
.sa-spin-kicker {
  font-size: 0.7rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: #c4b5fd;
  margin-bottom: 0.35rem;
}
.sa-spin-modal h2 { font-size: 1.35rem; font-weight: 800; margin: 0 0 0.4rem; }
.sa-spin-sub { font-size: 0.85rem; color: #94a3b8; margin: 0 0 1rem; }
.sa-spin-stage { position: relative; width: 16rem; height: 16rem; margin: 0 auto 1rem; }
.sa-spin-pointer {
  position: absolute;
  top: -0.15rem;
  left: 50%;
  z-index: 2;
  width: 0;
  height: 0;
  border-left: 10px solid transparent;
  border-right: 10px solid transparent;
  border-top: 16px solid #e879f9;
  transform: translateX(-50%);
}
.sa-spin-wheel {
  width: 100%;
  height: 100%;
  border-radius: 50%;
  border: 6px solid #1e1b4b;
  background: conic-gradient(
    #312e81 0 45deg,
    #1e1b4b 45deg 90deg,
    #4c1d95 90deg 135deg,
    #1e1b4b 135deg 180deg,
    #312e81 180deg 225deg,
    #1e1b4b 225deg 270deg,
    #4c1d95 270deg 315deg,
    #1e1b4b 315deg 360deg
  );
  box-shadow: 0 0 0 8px rgba(232, 121, 249, 0.12), 0 18px 40px rgba(0, 0, 0, 0.45);
  position: relative;
  transition: transform 4.2s cubic-bezier(0.12, 0.7, 0.12, 1);
}
.sa-spin-wheel span {
  position: absolute;
  left: 50%;
  top: 18%;
  width: 3rem;
  margin-left: -1.5rem;
  font-size: 0.78rem;
  font-weight: 800;
  transform-origin: 50% 5.35rem;
}
.sa-spin-wheel span:nth-child(1) { transform: rotate(22.5deg); }
.sa-spin-wheel span:nth-child(2) { transform: rotate(67.5deg); }
.sa-spin-wheel span:nth-child(3) { transform: rotate(112.5deg); }
.sa-spin-wheel span:nth-child(4) { transform: rotate(157.5deg); }
.sa-spin-wheel span:nth-child(5) { transform: rotate(202.5deg); }
.sa-spin-wheel span:nth-child(6) { transform: rotate(247.5deg); }
.sa-spin-wheel span:nth-child(7) { transform: rotate(292.5deg); }
.sa-spin-wheel span:nth-child(8) { transform: rotate(337.5deg); }
.sa-spin-go,
.sa-spin-copy {
  width: 100%;
  border: 0;
  border-radius: 999px;
  padding: 0.75rem 1rem;
  font-weight: 700;
  cursor: pointer;
  color: #fff;
  background: linear-gradient(135deg, #38bdf8, #1d4ed8);
}
.sa-spin-go:disabled { opacity: 0.55; cursor: not-allowed; }
.sa-spin-result { margin-top: 1rem; }
.sa-spin-win { margin: 0 0 0.5rem; }
.sa-spin-result code {
  display: block;
  margin: 0 0 0.65rem;
  padding: 0.55rem;
  border-radius: 0.7rem;
  background: #111827;
  border: 1px dashed rgba(232, 121, 249, 0.4);
  letter-spacing: 0.08em;
  font-weight: 700;
  color: #f5d0fe;
}
.sa-spin-hint { margin: 0.65rem 0 0; font-size: 0.75rem; color: #94a3b8; }

.sa-incentives {
  margin-top: 0.7rem;
  padding-top: 0.65rem;
  border-top: 1px solid rgba(255, 255, 255, 0.08);
  text-align: left;
}
.sa-incentives--view {
  margin-top: 0;
  padding-top: 0;
  border-top: 0;
}
.sa-incentives__cashback {
  margin: 0 0 0.45rem;
  font-size: 0.82rem;
  line-height: 1.4;
  color: #86efac;
}
.sa-incentives__cashback strong {
  display: inline;
  color: #4ade80;
  font-weight: 800;
}
.sa-incentives__cashback span {
  display: inline;
  color: inherit;
  margin-left: 0.25rem;
  opacity: 0.9;
}
.sa-incentives__bulk-title {
  margin: 0 0 0.3rem;
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: #fbbf24;
}
.sa-incentives__bulk {
  margin: 0;
  padding: 0;
  list-style: none;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.2rem 0.55rem;
}
.sa-incentives__bulk li {
  display: flex;
  justify-content: space-between;
  gap: 0.4rem;
  font-size: 0.72rem;
  color: #cbd5e1;
}
.sa-incentives__bulk strong { color: #fde68a; font-weight: 700; }
.sa-deal-warn[hidden] { display: none; }
.sa-deal-warn { position: fixed; inset: 0; z-index: 90; display: grid; place-items: center; }
.sa-deal-warn__backdrop { position: absolute; inset: 0; background: rgba(2, 6, 23, 0.78); }
.sa-deal-warn__modal {
  position: relative;
  width: min(26rem, calc(100vw - 2rem));
  padding: 1.35rem 1.25rem 1.2rem;
  border-radius: 1.2rem;
  border: 1px solid rgba(251, 191, 36, 0.35);
  background: #070910;
  color: #fff;
  box-shadow: 0 30px 80px rgba(0, 0, 0, 0.55);
}
.sa-deal-warn__kicker {
  margin: 0 0 0.25rem;
  font-size: 0.68rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: #fbbf24;
}
.sa-deal-warn__modal h2 { margin: 0 0 0.4rem; font-size: 1.2rem; font-weight: 800; }
.sa-deal-warn__lead, .sa-deal-warn__qty { margin: 0 0 0.55rem; font-size: 0.85rem; color: #94a3b8; }
.sa-deal-warn__cashback { margin: 0 0 0.7rem; font-size: 0.88rem; color: #86efac; }
.sa-deal-warn__actions { display: flex; gap: 0.6rem; margin-top: 1rem; }
.sa-deal-warn__cancel, .sa-deal-warn__ok {
  flex: 1;
  border: 0;
  border-radius: 999px;
  padding: 0.7rem 1rem;
  font-weight: 700;
  cursor: pointer;
}
.sa-deal-warn__cancel { background: #1e293b; color: #e2e8f0; }
.sa-deal-warn__ok { background: linear-gradient(135deg, #38bdf8, #1d4ed8); color: #fff; }