:root {
  --bg: #06080f;
  --bg-elevated: #0c101a;
  --panel: #111827;
  --panel-hover: #161f2e;
  --border: rgba(148, 163, 184, 0.12);
  --border-strong: rgba(148, 163, 184, 0.22);
  --text: #f1f5f9;
  --muted: #94a3b8;
  --accent: #38bdf8;
  --accent-hover: #7dd3fc;
  --accent-rgb: 56, 189, 248;
  --accent-hover-rgb: 125, 211, 252;
  --accent2-rgb: 96, 165, 250;
  --accent-dim: rgba(var(--accent-rgb), 0.15);
  --accent2: #34d399;
  --accent-warm: #f472b6;
  --danger: #fb7185;
  --radius: 12px;
  --radius-lg: 16px;
  --shadow: 0 1px 0 rgba(255, 255, 255, 0.04) inset, 0 12px 40px rgba(0, 0, 0, 0.35);
  --shadow-card: 0 0 0 1px var(--border), 0 20px 50px -20px rgba(0, 0, 0, 0.5);
  --font: "Plus Jakarta Sans", ui-sans-serif, system-ui, -apple-system, Segoe UI, Roboto, Helvetica, Arial, sans-serif;
  --font-mono: "JetBrains Mono", ui-monospace, monospace;
  /* Scrollbars — used by Firefox (scrollbar-color) + WebKit below */
  --scrollbar-size: 9px;
  --scrollbar-track: rgba(255, 255, 255, 0.045);
  --scrollbar-thumb: rgba(148, 163, 184, 0.32);
  --scrollbar-thumb-hover: rgba(var(--accent-rgb), 0.55);
}

* { box-sizing: border-box; }

html {
  font-family: var(--font);
}

body {
  margin: 0;
  font-family: var(--font);
  background: var(--bg);
  color: var(--text);
  line-height: 1.55;
  min-height: 100vh;
  -webkit-font-smoothing: antialiased;
}

/* Themed scrollbars — Firefox + Chrome/Safari/Edge (inherits --accent-rgb per page theme) */
* {
  scrollbar-width: thin;
  scrollbar-color: var(--scrollbar-thumb) var(--scrollbar-track);
}

*::-webkit-scrollbar {
  width: var(--scrollbar-size);
  height: var(--scrollbar-size);
}

*::-webkit-scrollbar-track {
  background: var(--scrollbar-track);
  border-radius: 999px;
}

*::-webkit-scrollbar-thumb {
  border-radius: 999px;
  border: 2px solid transparent;
  background-image: linear-gradient(
    180deg,
    rgba(var(--accent-rgb), 0.45) 0%,
    rgba(var(--accent2-rgb), 0.34) 100%
  );
  background-clip: padding-box;
  min-height: 36px;
}

*::-webkit-scrollbar-thumb:hover {
  background-image: linear-gradient(
    180deg,
    rgba(var(--accent-rgb), 0.68) 0%,
    rgba(var(--accent2-rgb), 0.5) 100%
  );
}

*::-webkit-scrollbar-corner {
  background: transparent;
}

button,
input,
textarea,
select,
optgroup {
  font-family: inherit;
}

body.store {
  display: flex;
  flex-direction: column;
  min-height: 100vh;
  /* Animate.css — https://animate.style/ */
  --animate-duration: 0.65s;
  background:
    radial-gradient(ellipse 120% 80% at 50% -30%, rgba(var(--accent-rgb), 0.12), transparent 55%),
    radial-gradient(ellipse 80% 50% at 100% 0%, rgba(244, 114, 182, 0.06), transparent 45%),
    var(--bg);
}

/* ——— Storefront dark theme (#0a0c0f + sky/blue accents) ——— */
body.store.store--classic {
  --bg: #0a0c0f;
  --bg-elevated: #12161c;
  --panel: #12161c;
  --panel-hover: #181e27;
  --border: rgba(255, 255, 255, 0.08);
  --border-strong: rgba(255, 255, 255, 0.12);
  --text: #f1f5f9;
  --muted: #94a3b8;
  --accent: #38bdf8;
  --accent-hover: #7dd3fc;
  --accent-rgb: 56, 189, 248;
  --accent-hover-rgb: 125, 211, 252;
  --accent2-rgb: 96, 165, 250;
  --accent2: #60a5fa;
  --accent3: #22d3ee;
  --accent-soft: #bae6fd;
  --accent-dim: rgba(var(--accent-rgb), 0.12);
  --shadow: 0 1px 0 rgba(255, 255, 255, 0.04) inset;
  --shadow-card: 0 0 0 1px rgba(255, 255, 255, 0.06), 0 16px 48px -28px rgba(0, 0, 0, 0.65);
  --scrollbar-track: rgba(0, 0, 0, 0.3);
  --scrollbar-thumb: rgba(148, 163, 184, 0.3);
  background: var(--bg);
}

body.store.store--classic::before {
  opacity: 0.35;
  background-size: 28px 28px;
}

body.store.store--classic.storefront-home {
  background:
    radial-gradient(ellipse 100% 60% at 50% -20%, rgba(var(--accent-rgb), 0.07), transparent 50%),
    radial-gradient(ellipse 60% 40% at 100% 10%, rgba(var(--accent2-rgb), 0.05), transparent 45%),
    #0a0c0f;
}

body.store.store--classic .top {
  background: rgba(10, 12, 15, 0.92);
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
  box-shadow: none;
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
}

body.store.store--classic .top::after {
  display: none;
}

body.store.store--classic .brand__name {
  font-weight: 700;
  font-size: 1.05rem;
  letter-spacing: -0.02em;
  color: var(--text);
  line-height: 1.2;
  max-width: min(46vw, 16rem);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

body.store.store--classic .brand__text {
  color: var(--text);
}

body.store.store--classic .brand--with-logo {
  gap: 0.65rem;
}

body.store.store--classic .brand__logo {
  display: block;
  flex-shrink: 0;
  max-height: 2.15rem;
  width: auto;
  object-fit: contain;
}

body.store.store--classic .brand__mark {
  background: linear-gradient(135deg, var(--accent), var(--accent2));
  box-shadow: 0 0 18px rgba(var(--accent-rgb), 0.35);
}

.top__inner--classic {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  flex-wrap: wrap;
}

.nav--text {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.25rem 1.25rem;
  justify-content: center;
  flex: 1;
}

.nav--icons {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.35rem;
  justify-content: center;
  flex: 1;
}

.nav__text {
  font-size: 0.9375rem;
  font-weight: 500;
  color: var(--muted);
  text-decoration: none;
  padding: 0.35rem 0;
  border-bottom: 2px solid transparent;
  transition:
    color 0.15s ease,
    border-color 0.15s ease;
}

.nav__text:hover {
  color: var(--text);
}

.nav__text.is-active {
  color: #f8fafc;
  border-bottom-color: var(--accent);
}

.nav__icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  text-decoration: none;
  transition:
    color 0.15s ease,
    background 0.15s ease;
}

.nav__icon i {
  font-size: 1.05rem;
}

.top__actions {
  display: flex;
  align-items: center;
  gap: 0.5rem 0.75rem;
  flex-shrink: 0;
}

.btn--login {
  padding: 0.45rem 1.15rem;
  border-radius: 10px;
  font-weight: 700;
  font-size: 0.9rem;
  background: var(--accent) !important;
  color: #0f172a !important;
  border: none !important;
  text-decoration: none;
  box-shadow: 0 2px 14px rgba(var(--accent-rgb), 0.22);
}

.btn--login:hover {
  background: var(--accent-hover) !important;
  color: #0f172a !important;
}

body.store.store--classic .top__action-icon {
  width: 2.5rem;
  height: 2.5rem;
  padding: 0;
  border-radius: 10px;
  color: #94a3b8;
}

body.store.store--classic .top__action-icon:hover {
  color: #f1f5f9;
  background: rgba(255, 255, 255, 0.08);
}

body.store.store--classic .nav__icon.is-active {
  color: var(--accent);
  background: rgba(var(--accent-rgb), 0.12);
  box-shadow: 0 0 0 1px rgba(var(--accent-rgb), 0.25);
}

body.store.store--classic .nav__link--staff:hover {
  color: var(--accent-hover);
  background: rgba(var(--accent-rgb), 0.1);
}

.linkish--text {
  background: none;
  border: none;
  font: inherit;
  font-size: 0.875rem;
  font-weight: 500;
  color: var(--muted);
  cursor: pointer;
  padding: 0.35rem 0.5rem;
}

.linkish--text:hover {
  color: var(--text);
}

.top__avatar-link {
  display: flex;
  border-radius: 999px;
  overflow: hidden;
  border: 2px solid var(--border-strong);
}

/* Home: storefront hero — catalog context, trust strip, primary CTAs */
.store-hero-spotlight {
  position: relative;
  overflow: hidden;
  padding: clamp(3rem, 8vw, 5rem) 1.25rem clamp(2.5rem, 5vw, 4rem);
  margin: 0;
  text-align: center;
  background: #0a0c0f;
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
}

.store-hero-spotlight__bg {
  pointer-events: none;
  position: absolute;
  inset: 0;
  background:
    radial-gradient(ellipse 90% 55% at 50% -15%, rgba(var(--accent-rgb), 0.1), transparent 52%),
    radial-gradient(ellipse 50% 35% at 100% 20%, rgba(var(--accent2-rgb), 0.06), transparent 50%),
    linear-gradient(180deg, rgba(255, 255, 255, 0.03) 0%, transparent 42%),
    repeating-linear-gradient(
      -12deg,
      transparent,
      transparent 40px,
      rgba(255, 255, 255, 0.015) 40px,
      rgba(255, 255, 255, 0.015) 41px
    );
}

.store-hero-spotlight__inner {
  position: relative;
  z-index: 1;
  max-width: 46rem;
  margin: 0 auto;
}

.store-hero-spotlight__badge {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  margin: 0 0 1.35rem;
  padding: 0.4rem 1rem 0.45rem;
  font-size: 0.8125rem;
  font-weight: 500;
  color: #94a3b8;
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.04);
}

.store-hero-spotlight__badge-dot {
  width: 0.5rem;
  height: 0.5rem;
  border-radius: 50%;
  flex-shrink: 0;
  background: var(--accent2);
  box-shadow: 0 0 12px rgba(var(--accent-rgb), 0.55);
}

.store-hero-spotlight__title {
  margin: 0 0 1.25rem;
  font-size: clamp(2.15rem, 5.5vw, 3.15rem);
  font-weight: 700;
  letter-spacing: -0.035em;
  line-height: 1.12;
}

.store-hero-spotlight__title-line {
  display: block;
}

.store-hero-spotlight__title-line--light {
  color: #f8fafc;
}

.store-hero-spotlight__title-line--accent {
  margin-top: 0.15rem;
  background: linear-gradient(100deg, var(--accent) 0%, var(--accent2) 50%, var(--accent3) 100%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.store-hero-spotlight__desc {
  margin: 0 auto 1.5rem;
  max-width: 38rem;
  font-size: 1.02rem;
  line-height: 1.65;
  color: #94a3b8;
}

.store-hero-spotlight__highlights {
  list-style: none;
  margin: 0 auto 1.75rem;
  padding: 0;
  max-width: 40rem;
  display: grid;
  grid-template-columns: 1fr;
  gap: 0.65rem;
}

@media (min-width: 640px) {
  .store-hero-spotlight__highlights {
    grid-template-columns: repeat(3, 1fr);
    gap: 0.75rem;
  }
}

.store-hero-spotlight__highlights li {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.5rem;
  padding: 0.85rem 0.65rem;
  border-radius: var(--radius);
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid rgba(255, 255, 255, 0.07);
  transition:
    border-color 0.15s ease,
    background 0.15s ease;
}

.store-hero-spotlight__highlights li:hover {
  background: rgba(255, 255, 255, 0.05);
  border-color: rgba(var(--accent-rgb), 0.22);
}

.store-hero-spotlight__hi-icon {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 2.25rem;
  height: 2.25rem;
  border-radius: 10px;
  background: rgba(var(--accent-rgb), 0.1);
  color: var(--accent);
  font-size: 1rem;
}

.store-hero-spotlight__hi-body {
  display: flex;
  flex-direction: column;
  gap: 0.15rem;
  text-align: center;
}

.store-hero-spotlight__hi-title {
  font-size: 0.875rem;
  font-weight: 700;
  color: #e2e8f0;
  letter-spacing: -0.02em;
}

.store-hero-spotlight__hi-sub {
  font-size: 0.75rem;
  font-weight: 500;
  color: #64748b;
  line-height: 1.35;
}

.store-hero-spotlight__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem 1rem;
  justify-content: center;
  align-items: center;
}

.store-hero-spotlight__btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 0.7rem 1.5rem;
  border-radius: 10px;
  font-size: 0.95rem;
  font-weight: 700;
  text-decoration: none;
  transition:
    transform 0.12s ease,
    box-shadow 0.15s ease,
    background 0.15s ease,
    border-color 0.15s ease;
}

.store-hero-spotlight__btn:active {
  transform: translateY(1px);
}

.store-hero-spotlight__btn--primary {
  gap: 0.55rem;
  background: var(--accent);
  color: #0f172a !important;
  border: none;
  box-shadow: 0 4px 20px rgba(var(--accent-rgb), 0.28);
}

.store-hero-spotlight__btn--primary i {
  font-size: 1rem;
  opacity: 0.95;
}

.store-hero-spotlight__btn--primary:hover {
  background: var(--accent-hover);
  color: #0f172a !important;
  box-shadow: 0 6px 24px rgba(var(--accent-rgb), 0.38);
}

.store-hero-spotlight__btn--discord {
  background: rgba(15, 23, 42, 0.85);
  color: #f1f5f9 !important;
  border: 1px solid rgba(148, 163, 184, 0.35);
  font-weight: 600;
}

.store-hero-spotlight__btn--discord:hover {
  background: rgba(30, 41, 59, 0.95);
  border-color: rgba(148, 163, 184, 0.5);
  color: #ffffff !important;
}

.store-hero-spotlight__btn--discord i {
  font-size: 1.15rem;
}

/* Staff dashboard: store aggregates */
body.staff .staff-dash-stats {
  margin-bottom: 1.75rem;
}

body.staff .staff-dash-stats__wrap {
  padding: clamp(1.35rem, 3vw, 1.75rem);
  background: linear-gradient(165deg, rgba(18, 22, 28, 0.92) 0%, rgba(10, 12, 15, 0.98) 100%);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-card);
}

body.staff .staff-dash-stats__head {
  margin: 0 0 1.35rem;
  max-width: 42rem;
}

body.staff .staff-dash-stats__title {
  margin: 0 0 0.4rem;
  font-size: clamp(1.05rem, 2vw, 1.2rem);
  font-weight: 700;
  letter-spacing: -0.03em;
  color: var(--text);
}

body.staff .staff-dash-stats__sub {
  margin: 0;
  font-size: 0.9rem;
  line-height: 1.5;
}

body.staff .staff-dash-stats__grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0.85rem;
}

@media (min-width: 640px) {
  body.staff .staff-dash-stats__grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 1rem;
  }
}

@media (min-width: 1024px) {
  body.staff .staff-dash-stats__grid {
    grid-template-columns: repeat(6, minmax(0, 1fr));
    gap: 1rem;
  }
}

body.staff .staff-dash-stat-card {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 0.65rem;
  padding: 1rem 0.95rem;
  border-radius: var(--radius);
  border: 1px solid rgba(255, 255, 255, 0.07);
  background: rgba(0, 0, 0, 0.22);
  min-height: 100%;
  transition:
    border-color 0.15s ease,
    background 0.15s ease;
}

body.staff .staff-dash-stat-card:hover {
  border-color: rgba(var(--accent-rgb), 0.22);
  background: rgba(var(--accent-rgb), 0.06);
}

body.staff .staff-dash-stat-card--accent {
  border-color: rgba(var(--accent-rgb), 0.2);
  background: linear-gradient(145deg, rgba(var(--accent-rgb), 0.1) 0%, rgba(0, 0, 0, 0.2) 100%);
}

body.staff .staff-dash-stat-card--accent:hover {
  border-color: rgba(var(--accent-rgb), 0.35);
}

body.staff .staff-dash-stat-card__icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 2.35rem;
  height: 2.35rem;
  border-radius: 10px;
  font-size: 1rem;
  color: var(--accent);
  background: rgba(var(--accent-rgb), 0.12);
  border: 1px solid rgba(var(--accent-rgb), 0.2);
}

body.staff .staff-dash-stat-card__body {
  display: flex;
  flex-direction: column;
  gap: 0.15rem;
  min-width: 0;
  width: 100%;
}

body.staff .staff-dash-stat-card__value {
  font-family: var(--font-mono);
  font-size: clamp(1.35rem, 3.2vw, 1.75rem);
  font-weight: 700;
  letter-spacing: -0.03em;
  line-height: 1.15;
  color: var(--text);
  word-break: break-word;
}

body.staff .staff-dash-stat-card__value--money {
  font-size: clamp(1.05rem, 2.4vw, 1.35rem);
  line-height: 1.25;
}

body.staff .staff-dash-stat-card__label {
  font-size: 0.8125rem;
  font-weight: 700;
  letter-spacing: 0.02em;
  color: var(--text);
}

body.staff .staff-dash-stat-card__hint {
  font-size: 0.7rem;
  font-weight: 500;
  line-height: 1.35;
  color: var(--muted);
}

.staff-trend {
  display: inline-flex;
  align-items: center;
  gap: 0.25rem;
  font-weight: 600;
  font-size: 0.72rem;
}

.staff-trend--up { color: #86efac; }
.staff-trend--down { color: #fca5a5; }
.staff-trend--flat { color: var(--muted); }

.staff-trend i { font-size: 0.65rem; }

.staff-dash-widgets {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 380px), 1fr));
  gap: 1.5rem;
  margin-top: 1.5rem;
}

.staff-dash-widgets .staff-card {
  margin-bottom: 0;
}

/* Storefront home: layout */
body.storefront-home .store-home {
  display: flex;
  flex-direction: column;
}

body.storefront-home .store-hero-spotlight {
  padding-bottom: clamp(3.75rem, 9vw, 6rem);
  border-bottom: none;
}

body.store.store--classic .nav__cart-count {
  background: linear-gradient(135deg, var(--accent), var(--accent3));
  color: #0f172a;
  box-shadow: 0 1px 6px rgba(0, 0, 0, 0.35);
}

body.store.store--classic .btn:hover {
  background: rgba(255, 255, 255, 0.08);
  border-color: var(--border-strong);
  color: var(--text);
}

body.store.store--classic .btn-primary {
  background: linear-gradient(135deg, var(--accent) 0%, var(--accent3) 100%);
  border-color: rgba(var(--accent-rgb), 0.5);
  color: #0f172a;
  box-shadow: 0 2px 16px rgba(var(--accent-rgb), 0.22);
}

body.store.store--classic .btn-primary:hover {
  background: linear-gradient(135deg, var(--accent-hover) 0%, var(--accent) 100%);
  border-color: rgba(var(--accent-hover-rgb), 0.55);
  color: #0f172a;
}

body.store.store--classic .btn-ghost {
  border-color: var(--border-strong);
  color: var(--text);
}

body.store.store--classic .btn-ghost:hover {
  background: rgba(255, 255, 255, 0.06);
  border-color: rgba(255, 255, 255, 0.14);
}

body.store.store--classic .foot {
  background: #06080a;
  border-top: 1px solid rgba(255, 255, 255, 0.08);
}

body.store.store--classic .catalog-card__category {
  color: var(--accent);
}

body.store.store--classic .catalog-sidebar {
  background: rgba(18, 22, 28, 0.95);
  border-color: var(--border);
}

body.store.store--classic .catalog-sidebar__btn {
  background: rgba(255, 255, 255, 0.04);
  border-color: var(--border);
  color: var(--text);
}

body.store.store--classic .catalog-sidebar__btn:hover {
  background: rgba(255, 255, 255, 0.08);
}

body.store.store--classic .catalog-sidebar__btn.is-active {
  border-color: rgba(var(--accent-rgb), 0.45);
  background: rgba(var(--accent-rgb), 0.1);
}

body.store.store--classic .catalog-card {
  background: linear-gradient(165deg, rgba(18, 22, 28, 0.98) 0%, rgba(10, 12, 15, 0.99) 100%);
}

body.store.store--classic .catalog-card:hover {
  border-color: rgba(var(--accent-rgb), 0.3);
  box-shadow:
    0 0 0 1px rgba(var(--accent-rgb), 0.12),
    0 24px 48px -28px rgba(0, 0, 0, 0.75);
}

body.store.store--classic .catalog-card__media {
  background: #0a0e14;
}

body.store.store--classic .catalog-search__input {
  background: rgba(255, 255, 255, 0.06) !important;
  border: 1px solid var(--border-strong) !important;
  color: var(--text) !important;
}

body.store.store--classic .catalog-search__icon {
  color: var(--muted);
}

body.store.store--classic .product-detail__placeholder {
  background: linear-gradient(145deg, #1a2330 0%, #0d1118 100%);
}

body.store.store--classic .releases-card {
  border: 1px solid var(--border);
  background: var(--panel);
}

body.store.store--classic .releases-card__badge {
  background: rgba(var(--accent-rgb), 0.15);
  color: var(--accent);
}

body.store.store--classic .releases-download-link {
  color: var(--accent);
}

body.store.store--classic .releases-download-link:hover {
  color: var(--accent-soft);
}

body.store.store--classic .product-detail__category {
  color: var(--accent);
}

body.store.store--classic .catalog-chip {
  background: rgba(255, 255, 255, 0.04);
  border-color: var(--border);
  color: var(--muted);
}

body.store.store--classic .catalog-chip:hover {
  color: var(--text);
  border-color: var(--border-strong);
}

body.store.store--classic .catalog-chip.is-active {
  color: #f8fafc;
  border-color: rgba(var(--accent-rgb), 0.45);
  background: rgba(var(--accent-rgb), 0.12);
}

body.store.store--classic .catalog-card__badge.digital-badge {
  color: var(--accent-soft);
  border-color: rgba(var(--accent-rgb), 0.38);
  background: rgba(10, 12, 15, 0.88);
}

body.store.store--classic .catalog-card__badge.owned-badge {
  background: rgba(10, 12, 15, 0.88);
}

body.store.store--classic .empty-state {
  background: rgba(255, 255, 255, 0.03);
  border-color: var(--border);
}

body.store.store--classic .account-tabs__tab:hover {
  background: rgba(255, 255, 255, 0.06);
}

body.store.store--classic .account-tabs__tab.is-active {
  box-shadow: 0 -2px 0 var(--accent) inset;
}

@media (max-width: 720px) {
  .nav--text,
  .nav--icons {
    order: 3;
    width: 100%;
    justify-content: flex-start;
    padding-top: 0.65rem;
    border-top: 1px solid var(--border);
  }

  .top__inner--classic {
    align-items: flex-start;
  }
}

/* Shared with staff layout — used with Animate.css entrance classes */
.store-animate-delay-1 {
  --animate-delay: 0.12s;
}

.store-animate-delay-2 {
  --animate-delay: 0.22s;
}

.store-animate-delay-3 {
  --animate-delay: 0.34s;
}

body.store .main {
  flex: 1;
  padding: 2rem 0 4rem;
  position: relative;
  z-index: 1;
}

body.storefront-home .main {
  padding-top: 0;
}

body.storefront-home {
  background:
    radial-gradient(ellipse 110% 75% at 50% -28%, rgba(99, 102, 241, 0.16), transparent 52%),
    radial-gradient(ellipse 55% 42% at 100% 12%, rgba(45, 212, 191, 0.09), transparent 48%),
    radial-gradient(ellipse 45% 38% at 0% 25%, rgba(167, 139, 250, 0.07), transparent 42%),
    var(--bg);
}

body.storefront-home::before {
  opacity: 0.5;
}

body.store::before {
  content: "";
  position: fixed;
  inset: 0;
  background-image: radial-gradient(rgba(148, 163, 184, 0.06) 1px, transparent 1px);
  background-size: 28px 28px;
  pointer-events: none;
  z-index: 0;
  mask-image: linear-gradient(180deg, rgba(0, 0, 0, 0.5) 0%, black 35%, black 100%);
}

.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

a {
  color: var(--accent);
  text-decoration: none;
  transition: color 0.15s ease;
}

a:hover {
  color: #7dd3fc;
}

.wrap {
  max-width: var(--wrap-max, 1120px);
  margin: 0 auto;
  padding: 0 1.25rem;
}

/* Wider content on customer storefront (shop, product, cart, account, checkout) */
body.store {
  --wrap-max: min(92vw, 1440px);
}

body.store .wrap {
  padding-left: clamp(1rem, 4vw, 2.25rem);
  padding-right: clamp(1rem, 4vw, 2.25rem);
}

/* ——— Store header ——— */
body.store .top {
  position: sticky;
  top: 0;
  z-index: 50;
  border-bottom: 1px solid var(--border);
  background: rgba(6, 8, 15, 0.78);
  backdrop-filter: blur(14px) saturate(1.2);
  -webkit-backdrop-filter: blur(14px) saturate(1.2);
  box-shadow: 0 1px 0 rgba(255, 255, 255, 0.04);
}

body.store .top::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: -1px;
  height: 1px;
  background: linear-gradient(90deg, transparent 0%, rgba(var(--accent-rgb), 0.25) 50%, transparent 100%);
  pointer-events: none;
}

body.store .top__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 64px;
  gap: 1rem;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 0.65rem;
  font-weight: 700;
  font-size: 1.125rem;
  letter-spacing: -0.02em;
  color: var(--text);
}

.brand:hover {
  color: var(--text);
  text-decoration: none;
}

.brand__mark {
  width: 10px;
  height: 10px;
  border-radius: 3px;
  background: linear-gradient(135deg, var(--accent), var(--accent-warm));
  box-shadow: 0 0 20px rgba(var(--accent-rgb), 0.45);
}

.brand__text {
  font-family: var(--font);
  font-size: 0.95rem;
  font-weight: 600;
}

.nav {
  display: flex;
  flex-wrap: wrap;
  gap: 0.25rem 0.5rem;
  align-items: center;
  justify-content: flex-end;
}

.nav__link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.45rem;
  padding: 0.45rem 0.85rem;
  border-radius: 999px;
  color: var(--muted);
  font-size: 0.9375rem;
  font-weight: 500;
  transition: background 0.15s ease, color 0.15s ease;
}

.nav__link i {
  font-size: 0.95em;
  opacity: 0.88;
  width: 1.1em;
  text-align: center;
}

body.store .nav--icons-only .nav__link {
  width: 2.5rem;
  height: 2.5rem;
  padding: 0;
  border-radius: 10px;
}

body.store .nav--icons-only .nav__link i {
  width: auto;
  font-size: 1.05rem;
}

.nav__link:hover {
  color: var(--text);
  background: rgba(148, 163, 184, 0.08);
  text-decoration: none;
}

.nav__link:hover i {
  opacity: 1;
}

body.store .nav--icons-only .nav__link--cart {
  position: relative;
  overflow: visible;
}

.nav__cart-count {
  position: absolute;
  top: -0.15rem;
  right: -0.15rem;
  min-width: 1.125rem;
  height: 1.125rem;
  padding: 0 0.3rem;
  border-radius: 999px;
  font-size: 0.625rem;
  font-weight: 700;
  line-height: 1.125rem;
  text-align: center;
  background: linear-gradient(135deg, #6366f1, #4f46e5);
  color: #fff;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.4);
  pointer-events: none;
}

.nav__link--staff {
  color: var(--accent2);
}

.nav__link--staff:hover {
  color: #6ee7b7;
  background: rgba(52, 211, 153, 0.1);
}

.nav__logout {
  display: inline;
  margin: 0;
  padding: 0;
}

body.store .nav__logout .linkish--icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.45rem;
}

body.store .nav__logout .linkish--icon i {
  font-size: 0.95em;
  opacity: 0.88;
  width: 1.1em;
  text-align: center;
}

body.store .nav--icons-only .nav__logout .linkish--icon {
  width: 2.5rem;
  height: 2.5rem;
  padding: 0 !important;
  border-radius: 10px;
}

body.store .nav--icons-only .nav__logout .linkish--icon i {
  width: auto;
  font-size: 1.05rem;
}

body.store .nav__logout .linkish--icon:hover i {
  opacity: 1;
}

.btn--header {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 0.45rem 1rem;
  font-size: 0.875rem;
  font-weight: 600;
}

.btn--header i {
  font-size: 0.95em;
  opacity: 0.95;
}

body.store .nav--icons-only .btn--header.btn--icon-only {
  width: 2.5rem;
  height: 2.5rem;
  padding: 0;
  border-radius: 10px;
}

body.store .nav--icons-only .btn--header.btn--icon-only i {
  font-size: 1.05rem;
}

body.store .nav--icons-only .nav__link--avatar {
  padding: 0;
  border-radius: 50%;
  overflow: hidden;
  border: 1px solid var(--border-strong);
  box-shadow: 0 0 0 1px rgba(0, 0, 0, 0.25);
}

body.store .nav--icons-only .nav__link--avatar:hover {
  border-color: rgba(var(--accent-rgb), 0.45);
  box-shadow: 0 0 0 1px rgba(var(--accent-rgb), 0.2);
}

body.store .nav__avatar {
  width: 2.5rem;
  height: 2.5rem;
  object-fit: cover;
  display: block;
  vertical-align: middle;
}

/* ——— Typography ——— */
h1 {
  font-size: clamp(1.65rem, 3vw, 2rem);
  font-weight: 700;
  letter-spacing: -0.03em;
  margin: 0 0 0.75rem;
  line-height: 1.2;
}

h2 {
  font-size: 1.15rem;
  font-weight: 600;
  letter-spacing: -0.02em;
  margin: 0 0 0.65rem;
}

.muted {
  color: var(--muted);
}

.small {
  font-size: 0.8125rem;
}

.eyebrow {
  display: block;
  font-family: var(--font-mono);
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 0.5rem;
}

.page-lead {
  font-size: 1.05rem;
  color: var(--muted);
  max-width: 42ch;
  margin: 0 0 2rem;
}

/* ——— Footer ——— */
body.store .foot {
  border-top: 1px solid var(--border);
  padding: 2.25rem 0;
  margin-top: auto;
  background: linear-gradient(180deg, transparent, rgba(0, 0, 0, 0.25));
}

.foot__inner {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.foot__note {
  margin: 0;
  max-width: 60ch;
}

.foot__copy {
  margin: 0;
  opacity: 0.85;
}

.foot__credit {
  margin: 0;
  opacity: 0.75;
}

.foot__credit-link {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  color: var(--muted);
  text-decoration: none;
  font-weight: 500;
  transition: color 0.15s ease;
}

.foot__credit-link:hover {
  color: var(--accent);
}

.foot__credit-logo {
  height: 1.35rem;
  width: auto;
  display: block;
  flex-shrink: 0;
  object-fit: contain;
}

.foot__credit-link:hover .foot__credit-logo {
  opacity: 0.95;
}

/* ——— Grids & cards ——— */
.grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
  gap: 1.25rem;
}

.card {
  background: linear-gradient(165deg, var(--panel) 0%, var(--bg-elevated) 100%);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 0;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  box-shadow: var(--shadow-card);
  transition: transform 0.2s ease, border-color 0.2s ease, box-shadow 0.2s ease;
}

.card:hover {
  transform: translateY(-3px);
  border-color: var(--border-strong);
  box-shadow:
    0 0 0 1px rgba(var(--accent-rgb), 0.12),
    0 24px 56px -24px rgba(0, 0, 0, 0.6);
}

.card__img-wrap {
  position: relative;
  overflow: hidden;
  background: #0a0e18;
}

.card__img {
  width: 100%;
  aspect-ratio: 4/3;
  object-fit: cover;
  display: block;
  transition: transform 0.35s ease;
}

.card:hover .card__img {
  transform: scale(1.04);
}

.card__body {
  padding: 1.1rem 1.15rem 1.2rem;
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
  flex: 1;
}

.card__title {
  font-size: 1.05rem;
  font-weight: 600;
  margin: 0;
  letter-spacing: -0.02em;
  line-height: 1.3;
}

.card__actions {
  margin-top: auto;
  padding-top: 0.85rem;
}

.card__actions--split {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  align-items: center;
}

.card__actions--split .btn .fa-download {
  margin-right: 0.35rem;
}

.card__actions--stack {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.card__actions--stack .btn--block {
  width: 100%;
}

.price {
  font-family: var(--font-mono);
  color: var(--accent2);
  font-weight: 600;
  font-size: 0.95rem;
  letter-spacing: -0.02em;
}

.price--lg {
  font-size: 1.35rem;
}

/* ——— Buttons ——— */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.4rem;
  padding: 0.55rem 1.1rem;
  border-radius: 10px;
  border: 1px solid var(--border-strong);
  background: var(--panel-hover);
  color: var(--text);
  cursor: pointer;
  font: inherit;
  font-weight: 500;
  font-size: 0.9375rem;
  transition: background 0.15s ease, border-color 0.15s ease, transform 0.1s ease;
}

.btn:hover {
  background: #1a2436;
  border-color: rgba(148, 163, 184, 0.28);
}

.btn:active {
  transform: translateY(1px);
}

.btn-primary {
  background: linear-gradient(135deg, #0ea5e9 0%, #0284c7 100%);
  border-color: rgba(14, 165, 233, 0.5);
  color: #f0f9ff;
  font-weight: 600;
  box-shadow: 0 2px 12px rgba(14, 165, 233, 0.25);
}

.btn-primary:hover {
  background: linear-gradient(135deg, #38bdf8 0%, #0ea5e9 100%);
  filter: none;
  border-color: rgba(var(--accent-hover-rgb), 0.45);
}

.btn-ghost {
  background: transparent;
  border-color: var(--border);
}

.btn-ghost:hover {
  background: rgba(148, 163, 184, 0.06);
}

.btn--sm {
  padding: 0.35rem 0.75rem;
  font-size: 0.8125rem;
}

.btn--lg {
  padding: 0.65rem 1.35rem;
  font-size: 1rem;
}

.btn--block {
  width: 100%;
  justify-content: center;
}

.btn--hero-secondary {
  border-color: var(--border-strong);
  color: var(--text);
}

/* ——— Tables ——— */
.table-wrap {
  overflow-x: auto;
  border-radius: var(--radius-lg);
  border: 1px solid var(--border);
  background: var(--panel);
  box-shadow: var(--shadow);
}

table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.9375rem;
}

th,
td {
  border-bottom: 1px solid var(--border);
  padding: 0.85rem 1rem;
  text-align: left;
}

tbody tr:last-child td {
  border-bottom: none;
}

th {
  color: var(--muted);
  font-weight: 600;
  font-size: 0.8125rem;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  background: rgba(0, 0, 0, 0.2);
}

tbody tr:hover td {
  background: rgba(var(--accent-rgb), 0.03);
}

/* ——— Forms ——— */
input:not([type="checkbox"]):not([type="radio"]),
textarea,
select {
  width: 100%;
  max-width: 420px;
  padding: 0.55rem 0.75rem;
  border-radius: 10px;
  border: 1px solid var(--border-strong);
  background: var(--bg);
  color: var(--text);
  font: inherit;
  transition: border-color 0.15s ease, box-shadow 0.15s ease;
}

input[type="checkbox"],
input[type="radio"] {
  width: 1.125rem;
  height: 1.125rem;
  max-width: none;
  margin: 0;
  padding: 0;
  border: none;
  border-radius: 4px;
  background: transparent;
  cursor: pointer;
  vertical-align: middle;
  accent-color: rgb(var(--accent-rgb));
  flex-shrink: 0;
}

input[type="radio"] {
  border-radius: 50%;
}

input:focus,
textarea:focus,
select:focus {
  outline: none;
  border-color: rgba(var(--accent-rgb), 0.45);
  box-shadow: 0 0 0 3px var(--accent-dim);
}

input[type="checkbox"]:focus,
input[type="radio"]:focus {
  outline: none;
  box-shadow: none;
}

input[type="checkbox"]:focus-visible,
input[type="radio"]:focus-visible {
  outline: 2px solid rgba(var(--accent-rgb), 0.65);
  outline-offset: 2px;
}

label {
  display: block;
  margin: 0.85rem 0 0.35rem;
  color: var(--muted);
  font-size: 0.8125rem;
  font-weight: 500;
}

.form-actions {
  margin-top: 1.1rem;
  display: flex;
  flex-wrap: wrap;
  gap: 0.65rem;
  align-items: center;
}

.inline {
  display: inline;
}

.linkish {
  background: none;
  border: none;
  color: var(--muted);
  cursor: pointer;
  font: inherit;
  padding: 0.45rem 0.85rem;
  border-radius: 999px;
  transition: color 0.15s ease, background 0.15s ease;
}

.linkish:hover {
  color: var(--text);
  background: rgba(148, 163, 184, 0.08);
  text-decoration: none;
}

.linkish.full {
  display: block;
  width: 100%;
  text-align: left;
  padding: 0.45rem 0;
  border-radius: 8px;
}

.input--narrow {
  max-width: 5rem !important;
}

.pill {
  display: inline-flex;
  align-items: center;
  padding: 0.2rem 0.65rem;
  border-radius: 999px;
  border: 1px solid var(--border-strong);
  font-size: 0.8125rem;
  font-weight: 500;
  color: var(--muted);
  background: rgba(0, 0, 0, 0.25);
}

.pill--ok {
  color: var(--accent2);
  border-color: rgba(52, 211, 153, 0.35);
  background: rgba(52, 211, 153, 0.08);
}

.pill--staff {
  color: var(--accent);
  border-color: rgba(var(--accent-rgb), 0.35);
  background: rgba(var(--accent-rgb), 0.1);
  font-family: var(--font-mono);
  font-size: 0.7rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.pill--owner {
  color: #fde68a;
  border-color: rgba(251, 191, 36, 0.45);
  background: rgba(251, 191, 36, 0.12);
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.02em;
  text-transform: none;
  font-family: var(--font);
}

/* ——— Storefront (home + product) ——— */
.landing-hero {
  position: relative;
  padding: clamp(2.75rem, 7vw, 4.5rem) 0 clamp(2rem, 4vw, 3rem);
  margin-bottom: 0;
  overflow: hidden;
}

.landing-hero__glow {
  position: absolute;
  inset: -45% -25% auto -25%;
  height: 130%;
  background:
    radial-gradient(ellipse 65% 50% at 50% 0%, rgba(129, 140, 248, 0.2), transparent 58%),
    radial-gradient(ellipse 45% 38% at 15% 25%, rgba(45, 212, 191, 0.1), transparent 50%),
    radial-gradient(ellipse 40% 35% at 92% 18%, rgba(192, 132, 252, 0.09), transparent 48%);
  pointer-events: none;
}

.landing-hero__inner {
  position: relative;
  z-index: 1;
  text-align: center;
  max-width: 44rem;
  margin: 0 auto;
}

.landing-trust {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  margin: 0 0 1.25rem;
  padding: 0.4rem 0.95rem;
  font-size: 0.8125rem;
  font-weight: 500;
  color: var(--muted);
  border: 1px solid var(--border);
  border-radius: 999px;
  background: rgba(15, 23, 42, 0.45);
  backdrop-filter: blur(8px);
}

.landing-trust__dot {
  width: 0.45rem;
  height: 0.45rem;
  border-radius: 50%;
  background: linear-gradient(135deg, #38bdf8, #22d3ee);
  box-shadow: 0 0 12px rgba(var(--accent-rgb), 0.5);
}

.landing-hero__title {
  margin: 0 0 1.1rem;
  font-size: clamp(1.95rem, 5vw, 2.85rem);
  font-weight: 700;
  letter-spacing: -0.04em;
  line-height: 1.08;
}

.landing-hero__title-line {
  display: block;
}

.landing-hero__title-line--accent {
  margin-top: 0.2rem;
  background: linear-gradient(105deg, #a5b4fc 0%, #7dd3fc 42%, #38bdf8 95%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.landing-hero__lead {
  margin: 0 auto 1.85rem;
  font-size: 1.0625rem;
  color: var(--muted);
  line-height: 1.65;
  max-width: 42ch;
}

.landing-hero__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  justify-content: center;
  align-items: center;
}

.landing-stats {
  position: relative;
  padding: 0 0 2.5rem;
}

.landing-stats__inner {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1rem;
  padding: 1.35rem 1.5rem;
  border-radius: var(--radius-lg);
  border: 1px solid var(--border);
  background: linear-gradient(165deg, rgba(17, 24, 39, 0.65) 0%, rgba(6, 8, 15, 0.85) 100%);
  box-shadow: var(--shadow-card);
}

@media (max-width: 720px) {
  .landing-stats__inner {
    grid-template-columns: 1fr;
    text-align: center;
  }

  .landing-stat--soft {
    align-items: center;
  }
}

.landing-stat {
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
  padding: 0.35rem 0.5rem;
}

.landing-stat--soft {
  border-left: 1px solid var(--border);
  padding-left: 1.25rem;
}

@media (max-width: 720px) {
  .landing-stat--soft {
    border-left: 0;
    border-top: 1px solid var(--border);
    padding-left: 0.5rem;
    padding-top: 1rem;
  }
}

.landing-stat__value {
  font-family: var(--font-mono);
  font-size: clamp(1.65rem, 4vw, 2.1rem);
  font-weight: 600;
  letter-spacing: -0.03em;
  line-height: 1.1;
  color: var(--text);
}

.landing-stat__label {
  font-size: 0.8125rem;
  font-weight: 600;
  letter-spacing: 0.02em;
  color: var(--muted);
}

.landing-stat__hint {
  font-size: 0.75rem;
  color: var(--muted);
  opacity: 0.85;
}

.landing-stat__icon {
  font-size: 1.35rem;
  color: #a5b4fc;
  margin-bottom: 0.15rem;
}

.landing-features {
  padding: 0.5rem 0 2.25rem;
}

.landing-features__head {
  text-align: center;
  max-width: 36rem;
  margin: 0 auto 2rem;
}

.landing-features__title {
  margin: 0 0 0.5rem;
  font-size: clamp(1.35rem, 3vw, 1.65rem);
  font-weight: 700;
  letter-spacing: -0.03em;
}

.landing-features__sub {
  margin: 0;
  font-size: 0.9375rem;
  line-height: 1.55;
}

.landing-feature-grid {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
  gap: 1.1rem;
}

.landing-feature-card {
  padding: 1.25rem 1.3rem;
  border-radius: var(--radius-lg);
  border: 1px solid var(--border);
  background: linear-gradient(155deg, rgba(17, 24, 39, 0.55) 0%, rgba(6, 8, 15, 0.92) 100%);
  box-shadow: var(--shadow-card);
  transition: border-color 0.2s ease, transform 0.2s ease;
}

.landing-feature-card:hover {
  transform: translateY(-3px);
  border-color: rgba(165, 180, 252, 0.22);
}

.landing-feature-card__icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 2.5rem;
  height: 2.5rem;
  margin-bottom: 0.85rem;
  border-radius: 12px;
  font-size: 1.1rem;
  color: #c7d2fe;
  background: rgba(99, 102, 241, 0.12);
  border: 1px solid rgba(129, 140, 248, 0.25);
}

.landing-feature-card__title {
  margin: 0 0 0.45rem;
  font-size: 1rem;
  font-weight: 600;
  letter-spacing: -0.02em;
}

.landing-feature-card__text {
  margin: 0;
  font-size: 0.875rem;
  line-height: 1.55;
}

.landing-cta {
  margin: 2rem 0 0;
  padding: clamp(2rem, 5vw, 2.75rem) 0;
}

.landing-cta__inner {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 1.5rem;
  padding: clamp(1.5rem, 4vw, 2rem) clamp(1.25rem, 4vw, 2rem);
  border-radius: var(--radius-lg);
  border: 1px solid rgba(129, 140, 248, 0.2);
  background:
    linear-gradient(125deg, rgba(79, 70, 229, 0.12) 0%, rgba(15, 23, 42, 0.6) 45%, rgba(6, 8, 15, 0.95) 100%);
  box-shadow: 0 24px 60px -32px rgba(0, 0, 0, 0.55);
}

.landing-cta__title {
  margin: 0 0 0.35rem;
  font-size: clamp(1.2rem, 2.5vw, 1.45rem);
  font-weight: 700;
  letter-spacing: -0.03em;
}

.landing-cta__sub {
  margin: 0;
  font-size: 0.9375rem;
  max-width: 38ch;
}

.landing-cta__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
}

body.storefront-home .catalog-section {
  padding-top: clamp(2.5rem, 5vw, 3.75rem);
  padding-bottom: clamp(2.5rem, 4vw, 4rem);
  margin-top: 0.25rem;
}

body.storefront-home .catalog-card:hover {
  border-color: rgba(165, 180, 252, 0.28);
  box-shadow:
    0 0 0 1px rgba(129, 140, 248, 0.12),
    0 24px 48px -28px rgba(0, 0, 0, 0.65);
}

/* Home: stagger feature + catalog cards (Animate.css --animate-delay) */
body.storefront-home .landing-feature-grid .landing-feature-card:nth-child(1) {
  --animate-delay: 0s;
}

body.storefront-home .landing-feature-grid .landing-feature-card:nth-child(2) {
  --animate-delay: 0.06s;
}

body.storefront-home .landing-feature-grid .landing-feature-card:nth-child(3) {
  --animate-delay: 0.12s;
}

body.storefront-home .landing-feature-grid .landing-feature-card:nth-child(4) {
  --animate-delay: 0.18s;
}

body.storefront-home .landing-feature-grid .landing-feature-card:nth-child(5) {
  --animate-delay: 0.24s;
}

body.storefront-home .landing-feature-grid .landing-feature-card:nth-child(6) {
  --animate-delay: 0.3s;
}

body.storefront-home .catalog-grid > li:nth-child(1) .catalog-card {
  --animate-delay: 0s;
}

body.storefront-home .catalog-grid > li:nth-child(2) .catalog-card {
  --animate-delay: 0.05s;
}

body.storefront-home .catalog-grid > li:nth-child(3) .catalog-card {
  --animate-delay: 0.1s;
}

body.storefront-home .catalog-grid > li:nth-child(4) .catalog-card {
  --animate-delay: 0.15s;
}

body.storefront-home .catalog-grid > li:nth-child(5) .catalog-card {
  --animate-delay: 0.2s;
}

body.storefront-home .catalog-grid > li:nth-child(6) .catalog-card {
  --animate-delay: 0.25s;
}

body.storefront-home .catalog-grid > li:nth-child(7) .catalog-card {
  --animate-delay: 0.3s;
}

body.storefront-home .catalog-grid > li:nth-child(8) .catalog-card {
  --animate-delay: 0.35s;
}

body.storefront-home .catalog-grid > li:nth-child(9) .catalog-card {
  --animate-delay: 0.4s;
}

body.storefront-home .catalog-grid > li:nth-child(10) .catalog-card {
  --animate-delay: 0.45s;
}

body.storefront-home .catalog-grid > li:nth-child(11) .catalog-card {
  --animate-delay: 0.5s;
}

body.storefront-home .catalog-grid > li:nth-child(12) .catalog-card {
  --animate-delay: 0.55s;
}

body.storefront-home .catalog-grid > li:nth-child(n + 13) .catalog-card {
  --animate-delay: 0.58s;
}

.catalog-section {
  padding: 2.5rem 0 1rem;
}

.catalog-section__head {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  justify-content: space-between;
  gap: 1rem;
  margin-bottom: 1.75rem;
  padding-bottom: 1rem;
  border-bottom: 1px solid var(--border);
}

.catalog-section__title {
  font-size: 1.35rem;
  font-weight: 700;
  letter-spacing: -0.03em;
  margin: 0 0 0.35rem;
}

.catalog-section__sub {
  margin: 0;
  font-size: 0.9375rem;
}

.catalog-grid {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 1.35rem;
}

body.storefront-home .catalog-grid {
  grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
  gap: 1.5rem;
}

.catalog-card {
  position: relative;
  display: flex;
  flex-direction: column;
  height: 100%;
  border-radius: var(--radius-lg);
  border: 1px solid var(--border);
  background: linear-gradient(165deg, rgba(17, 24, 39, 0.95) 0%, rgba(6, 8, 15, 0.98) 100%);
  box-shadow: var(--shadow-card);
  overflow: hidden;
  transition: transform 0.22s ease, border-color 0.22s ease, box-shadow 0.22s ease;
}

.catalog-card:hover {
  transform: translateY(-4px);
  border-color: rgba(var(--accent-rgb), 0.22);
  box-shadow:
    0 0 0 1px rgba(var(--accent-rgb), 0.1),
    0 24px 48px -28px rgba(0, 0, 0, 0.65);
}

.catalog-card__link {
  position: absolute;
  inset: 0;
  z-index: 2;
  border-radius: inherit;
}

.catalog-card__link:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
}

.catalog-card__media {
  position: relative;
  aspect-ratio: 4/3;
  background: #0a0e18;
  overflow: hidden;
}

.catalog-card__media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: transform 0.4s ease;
}

.catalog-card:hover .catalog-card__media img {
  transform: scale(1.05);
}

.catalog-card__placeholder {
  width: 100%;
  height: 100%;
  background:
    linear-gradient(145deg, #1a2332 0%, #0d1118 50%, #131c2a 100%);
  background-image:
    linear-gradient(145deg, rgba(var(--accent-rgb), 0.06) 0%, transparent 45%),
    repeating-linear-gradient(
      -12deg,
      transparent,
      transparent 8px,
      rgba(148, 163, 184, 0.04) 8px,
      rgba(148, 163, 184, 0.04) 9px
    );
}

.catalog-card__body {
  position: relative;
  z-index: 1;
  padding: 1.15rem 1.2rem 1.25rem;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  flex: 1;
}

.catalog-card__title {
  font-size: 1.0625rem;
  font-weight: 600;
  letter-spacing: -0.02em;
  line-height: 1.35;
  margin: 0;
  color: var(--text);
}

.catalog-card__meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  margin-top: auto;
}

.catalog-card__price {
  font-family: var(--font-mono);
  font-size: 0.95rem;
  font-weight: 600;
  color: var(--accent2);
}

.catalog-card__cta {
  font-size: 0.8125rem;
  font-weight: 600;
  color: var(--accent);
  z-index: 1;
  pointer-events: none;
}

.empty-state--catalog {
  text-align: left;
}

.breadcrumb {
  padding: 1rem 0 0;
}

.breadcrumb__list {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.35rem 0.5rem;
  list-style: none;
  margin: 0;
  padding: 0;
  font-size: 0.875rem;
}

.breadcrumb a {
  color: var(--muted);
  font-weight: 500;
}

.breadcrumb a:hover {
  color: var(--accent);
}

.breadcrumb__sep {
  color: var(--muted);
  opacity: 0.5;
  user-select: none;
}

.breadcrumb__current {
  color: var(--text);
  font-weight: 600;
  max-width: min(100%, 40ch);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

/* ——— Cart ——— */
.cart-hero {
  padding: 0.25rem 0 1.75rem;
}

.cart-hero__title {
  font-size: clamp(1.65rem, 3.5vw, 2.1rem);
  font-weight: 700;
  letter-spacing: -0.03em;
  margin: 0 0 0.5rem;
}

.cart-hero__lead {
  margin: 0;
  font-size: 1.05rem;
  max-width: 42ch;
}

.cart-notice {
  margin-bottom: 1.25rem;
}

.cart-notice p {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  margin: 0;
  padding: 0.75rem 1rem;
  font-size: 0.92rem;
  border-radius: 10px;
  color: #86efac;
  background: rgba(34, 197, 94, 0.08);
  border: 1px solid rgba(34, 197, 94, 0.25);
}

.cart-empty {
  padding: 2rem 0 3rem;
}

.cart-empty__card {
  max-width: 26rem;
  margin: 0 auto;
  text-align: center;
  padding: 2.75rem 1.75rem;
  border-radius: var(--radius-lg);
  border: 1px solid var(--border);
  background: linear-gradient(165deg, rgba(17, 24, 39, 0.9) 0%, rgba(6, 8, 15, 0.95) 100%);
  box-shadow: var(--shadow-card);
}

.cart-empty__icon {
  width: 4rem;
  height: 4rem;
  margin: 0 auto 1.25rem;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  background: rgba(var(--accent-rgb), 0.08);
  border: 1px solid rgba(var(--accent-rgb), 0.2);
  color: var(--accent);
  font-size: 1.35rem;
}

.cart-empty__title {
  font-size: 1.25rem;
  font-weight: 700;
  margin: 0 0 0.5rem;
  letter-spacing: -0.02em;
}

.cart-empty__text {
  margin: 0 0 1.5rem;
  line-height: 1.55;
}

.cart-layout {
  display: grid;
  gap: 1.75rem;
  align-items: start;
  padding-bottom: 3rem;
}

@media (min-width: 960px) {
  .cart-layout {
    grid-template-columns: 1fr minmax(300px, 400px);
    gap: 2.25rem;
  }
}

@media (min-width: 1200px) {
  .cart-layout {
    gap: 2.75rem;
  }
}

.cart-layout__main {
  min-width: 0;
}

.cart-lines {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.cart-line {
  position: relative;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 1rem 1.25rem;
  padding: 1.2rem 1.25rem;
  padding-top: 3rem;
  border-radius: var(--radius-lg);
  border: 1px solid var(--border);
  background: linear-gradient(165deg, rgba(17, 24, 39, 0.95) 0%, rgba(6, 8, 15, 0.98) 100%);
  box-shadow: var(--shadow-card);
}

@media (min-width: 640px) {
  .cart-line {
    padding: 1.2rem 1.35rem;
    padding-top: 1.2rem;
  }
}

.cart-line__media {
  flex: 0 0 5.5rem;
  width: 5.5rem;
  border-radius: 10px;
  overflow: hidden;
  border: 1px solid var(--border);
  background: #0a0e18;
  aspect-ratio: 4/3;
}

.cart-line__media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.cart-line__placeholder {
  width: 100%;
  height: 100%;
  min-height: 4.5rem;
  background: linear-gradient(145deg, #1a2332 0%, #0d1118 100%);
}

.cart-line__info {
  flex: 1 1 12rem;
  min-width: 0;
}

.cart-line__title {
  display: block;
  font-size: 1.0625rem;
  font-weight: 600;
  color: var(--text);
  letter-spacing: -0.02em;
  line-height: 1.35;
  text-decoration: none;
}

.cart-line__title:hover {
  color: var(--accent);
}

.cart-line__unit {
  margin: 0.35rem 0 0;
}

.cart-line__qty {
  flex: 1 1 auto;
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
  min-width: 4.5rem;
}

@media (min-width: 640px) {
  .cart-line__qty {
    flex: 0 0 5.5rem;
  }
}

.cart-line__qty-label {
  margin: 0;
  font-size: 0.7rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--muted);
}

.cart-line__input {
  width: 100%;
  max-width: 5rem;
  padding: 0.5rem 0.55rem;
  border-radius: 10px;
  border: 1px solid var(--border-strong);
  background: var(--bg);
  color: var(--text);
  font: inherit;
  font-weight: 600;
  text-align: center;
}

.cart-line__input:focus {
  outline: none;
  border-color: rgba(var(--accent-rgb), 0.45);
  box-shadow: 0 0 0 3px var(--accent-dim);
}

.cart-line__line {
  flex: 0 0 auto;
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 0.15rem;
  min-width: 5rem;
}

@media (max-width: 639px) {
  .cart-line__line {
    flex: 1 1 100%;
    flex-direction: row;
    justify-content: space-between;
    align-items: center;
    padding-top: 0.5rem;
    border-top: 1px solid var(--border);
    margin-left: 0;
  }
}

.cart-line__price {
  font-size: 1.05rem;
}

.cart-line__actions {
  position: absolute;
  top: 0.85rem;
  right: 0.85rem;
}

@media (min-width: 640px) {
  .cart-line__actions {
    position: static;
    flex: 0 0 auto;
  }
}

.cart-line__remove {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 2.35rem;
  height: 2.35rem;
  padding: 0;
  border: 1px solid var(--border);
  border-radius: 10px;
  background: rgba(251, 113, 133, 0.06);
  color: var(--muted);
  cursor: pointer;
  transition: background 0.15s ease, color 0.15s ease, border-color 0.15s ease;
}

.cart-line__remove:hover {
  color: #fda4af;
  background: rgba(251, 113, 133, 0.12);
  border-color: rgba(251, 113, 133, 0.35);
}

.cart-remove-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.cart-toolbar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 1rem;
  margin-top: 1.35rem;
  padding-top: 1.25rem;
  border-top: 1px solid var(--border);
}

.cart-toolbar__hint {
  margin: 0;
  flex: 1 1 12rem;
}

.cart-summary__inner {
  position: sticky;
  top: 5.5rem;
  padding: 1.5rem 1.55rem;
  border-radius: var(--radius-lg);
  border: 1px solid var(--border);
  background: linear-gradient(165deg, rgba(17, 24, 39, 0.98) 0%, rgba(6, 8, 15, 1) 100%);
  box-shadow: var(--shadow-card);
}

.cart-summary__title {
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--muted);
  margin: 0 0 1.15rem;
  padding-bottom: 0.85rem;
  border-bottom: 1px solid var(--border);
}

.cart-summary__row {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 1rem;
  margin-bottom: 0.35rem;
}

.cart-summary__amount {
  font-size: 1.35rem;
}

.cart-summary__note {
  margin: 0.75rem 0 1.35rem;
  line-height: 1.45;
}

.cart-summary__checkout {
  margin-bottom: 1rem;
}

.cart-summary__continue {
  display: block;
  text-align: center;
  font-size: 0.9375rem;
  font-weight: 500;
  color: var(--muted);
}

.cart-summary__continue:hover {
  color: var(--accent);
}

.product-page {
  padding-top: 0.5rem;
}

.product-detail--pro {
  display: grid;
  grid-template-columns: 1fr;
  gap: 2rem;
  align-items: start;
}

@media (min-width: 900px) {
  .product-detail--pro {
    grid-template-columns: minmax(0, 1.05fr) minmax(0, 0.95fr);
    gap: 3rem;
    align-items: stretch;
  }
}

.product-detail--pro .product-detail__media {
  border-radius: var(--radius-lg);
  overflow: hidden;
  border: 1px solid var(--border);
  background: var(--panel);
  box-shadow: var(--shadow-card);
  aspect-ratio: 4/3;
}

.product-detail--pro .product-detail__media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.product-detail__placeholder {
  width: 100%;
  height: 100%;
  min-height: 240px;
  background: linear-gradient(145deg, #1a2332 0%, #0d1118 100%);
}

.product-detail__panel {
  display: flex;
  flex-direction: column;
  padding: 0.25rem 0;
}

@media (min-width: 900px) {
  .product-detail__panel {
    padding: 0.5rem 0;
    position: sticky;
    top: 5.5rem;
  }
}

.product-detail__header {
  margin-bottom: 1.25rem;
}

.product-detail__name {
  font-size: clamp(1.5rem, 3vw, 1.85rem);
  font-weight: 700;
  letter-spacing: -0.03em;
  line-height: 1.2;
  margin: 0 0 0.65rem;
}

.product-detail__price {
  font-family: var(--font-mono);
  font-size: 1.5rem;
  font-weight: 600;
  color: var(--accent2);
  margin: 0;
}

.product-detail__desc {
  margin: 0 0 1.25rem;
  color: var(--muted);
  line-height: 1.65;
  font-size: 0.975rem;
}

.product-detail__buy {
  padding-top: 0.25rem;
}

.badge.badge--owned {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.75rem 1.25rem;
  font-size: 1rem;
  font-weight: 600;
  letter-spacing: 0.02em;
  border-radius: 10px;
  color: #86efac;
  background: rgba(34, 197, 94, 0.1);
  border: 1px solid rgba(34, 197, 94, 0.3);
  width: 100%;
  justify-content: center;
}

.product-detail__hint {
  margin: 0.75rem 0 0;
  text-align: center;
}

.product-form--inline {
  display: flex;
  flex-direction: column;
  gap: 0.85rem;
}

@media (min-width: 480px) {
  .product-form--inline {
    flex-direction: row;
    flex-wrap: wrap;
    align-items: stretch;
  }

  .product-form--inline .product-form__qty {
    flex: 0 0 auto;
    margin: 0;
  }

  .product-form--inline .product-form__qty input {
    width: 4.5rem;
    max-width: none;
  }

  .product-form--inline .btn--block {
    flex: 1;
    min-width: 12rem;
  }
}

.product-form__qty {
  margin: 0;
}

.product-form__qty input {
  max-width: 5rem;
}

.back-link--product {
  margin-top: 2rem;
  margin-bottom: 0;
}

/* ——— Store sections (other pages) ——— */
.store-hero {
  margin-bottom: 2.25rem;
  padding-bottom: 0.5rem;
}

.empty-state {
  text-align: center;
  padding: 3rem 1.5rem;
  border: 1px dashed var(--border-strong);
  border-radius: var(--radius-lg);
  background: rgba(17, 24, 39, 0.5);
}

.empty-state p {
  margin: 0;
}

.product-detail__oos,
.product-detail__cta {
  margin-top: 1rem;
}

.back-link {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  margin-top: 2.5rem;
  font-size: 0.9375rem;
  font-weight: 500;
  color: var(--muted);
}

.back-link:hover {
  color: var(--accent);
}

.checkout-layout {
  display: grid;
  gap: 1.5rem;
}

@media (min-width: 900px) {
  .checkout-layout {
    grid-template-columns: 1fr 320px;
    align-items: start;
  }
}

.summary-card {
  border-radius: var(--radius-lg);
  border: 1px solid var(--border);
  background: linear-gradient(165deg, var(--panel) 0%, var(--bg-elevated) 100%);
  padding: 1.25rem 1.35rem;
  box-shadow: var(--shadow-card);
}

.summary-card__row {
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  padding: 0.45rem 0;
  font-size: 0.9375rem;
}

.summary-card__row--total {
  margin-top: 0.5rem;
  padding-top: 0.85rem;
  border-top: 1px solid var(--border);
  font-size: 1.1rem;
  font-weight: 700;
}

.summary-card__row--total .price {
  font-size: 1.15rem;
}

.summary-card__fineprint {
  margin: 1rem 0 0;
}

.promo-form {
  display: flex;
  flex-wrap: wrap;
  gap: 0.65rem;
  align-items: flex-end;
  margin: 0;
}

.promo-form label {
  margin: 0;
  flex: 1;
  min-width: 160px;
}

.promo-form .btn {
  flex-shrink: 0;
}

.table-wrap--below-hero {
  margin-bottom: 1.5rem;
}

.checkout-discount-line {
  margin-top: 1rem;
}

.checkout-error {
  margin: 0 0 1.25rem;
  padding: 0.85rem 1rem;
  border-radius: var(--radius);
  border: 1px solid rgba(251, 113, 133, 0.45);
  background: rgba(251, 113, 133, 0.08);
  color: #fecdd3;
  font-size: 0.9375rem;
}

.checkout-stripe-note {
  margin: 0.75rem 0 0;
  max-width: 42ch;
}

.checkout-place {
  margin-top: 1.5rem;
}

.btn--place-order {
  width: 100%;
  max-width: 280px;
  padding: 0.75rem 1rem;
}

.back-link--spaced {
  margin-top: 1.5rem;
}

.price--discount {
  color: var(--accent2);
}

.promo-code {
  color: var(--accent2);
  font-family: var(--font-mono);
  font-size: 0.9em;
}

.account-card {
  max-width: 520px;
  border-radius: var(--radius-lg);
  border: 1px solid var(--border);
  background: var(--panel);
  padding: 1.5rem 1.6rem;
  box-shadow: var(--shadow-card);
}

.account-card__links {
  display: flex;
  flex-wrap: wrap;
  gap: 0.65rem;
  margin-top: 1.25rem;
}

.account-card__title {
  margin: 0 0 0.5rem;
  font-size: 1.05rem;
}

.account-card__email {
  margin: 0;
}

/* ——— Account (tabbed) ——— */
body.store .account-shell {
  margin-top: 0.5rem;
}

body.store .account-tabs {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem;
  margin-bottom: 1.75rem;
  padding-bottom: 0;
  border-bottom: 1px solid var(--border);
}

body.store .account-tabs__tab {
  padding: 0.65rem 1rem;
  margin-bottom: -1px;
  border-radius: var(--radius) var(--radius) 0 0;
  color: var(--muted);
  font-weight: 600;
  font-size: 0.9375rem;
  border: 1px solid transparent;
  border-bottom: none;
  transition: background 0.15s ease, color 0.15s ease;
}

body.store .account-tabs__tab:hover {
  color: var(--text);
  background: rgba(148, 163, 184, 0.06);
  text-decoration: none;
}

body.store .account-tabs__tab.is-active {
  color: var(--text);
  background: var(--panel);
  border-color: var(--border);
  border-bottom: 1px solid var(--panel);
  margin-bottom: -1px;
  box-shadow: 0 -1px 0 var(--accent) inset;
}

body.store .account-panel__intro {
  margin: 0 0 1.25rem;
}

body.store .account-library-grid {
  margin-top: 0.25rem;
  grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
  gap: 1.35rem;
}

body.store .account-empty {
  text-align: left;
  max-width: min(100%, 62ch);
}

body.store .account-empty .btn {
  margin-top: 1rem;
}

.settings-grid {
  display: grid;
  gap: 1.25rem;
}

@media (min-width: 720px) {
  .settings-grid {
    grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  }
}

@media (min-width: 1100px) {
  body.store .settings-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 1.35rem;
  }
}

.settings-card {
  border-radius: var(--radius-lg);
  border: 1px solid var(--border);
  background: linear-gradient(165deg, var(--panel) 0%, var(--bg-elevated) 100%);
  padding: 1.35rem 1.45rem;
  box-shadow: var(--shadow-card);
}

.settings-card__title {
  font-size: 1rem;
  margin: 0 0 1rem;
  padding-bottom: 0.65rem;
  border-bottom: 1px solid var(--border);
}

.settings-card__line {
  margin: 0 0 0.65rem;
  display: flex;
  flex-direction: column;
  gap: 0.15rem;
}

.settings-card__line .muted {
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.settings-card__note {
  margin: 1rem 0 0;
}

.settings-card .account-card__links {
  margin-top: 0;
}

.order-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem 1.5rem;
  align-items: center;
  margin-bottom: 1.5rem;
}

.order-awaiting-note {
  margin: 0 0 1.25rem;
  max-width: 48ch;
}

/* ——— Staff (storefront classic theme + sticky sidebar) ——— */
body.staff {
  display: flex;
  align-items: flex-start;
  min-height: 100vh;
  --animate-duration: 0.65s;
  /* Match body.store.store--classic */
  --bg: #0a0c0f;
  --bg-elevated: #12161c;
  --panel: #12161c;
  --panel-hover: #181e27;
  --border: rgba(255, 255, 255, 0.08);
  --border-strong: rgba(255, 255, 255, 0.12);
  --text: #f1f5f9;
  --muted: #94a3b8;
  --accent: #38bdf8;
  --accent-hover: #7dd3fc;
  --accent-rgb: 56, 189, 248;
  --accent-hover-rgb: 125, 211, 252;
  --accent2-rgb: 96, 165, 250;
  --accent2: #60a5fa;
  --accent3: #22d3ee;
  --accent-soft: #bae6fd;
  --accent-dim: rgba(var(--accent-rgb), 0.12);
  --shadow: 0 1px 0 rgba(255, 255, 255, 0.04) inset;
  --shadow-card: 0 0 0 1px rgba(255, 255, 255, 0.06), 0 16px 48px -28px rgba(0, 0, 0, 0.65);
  --scrollbar-track: rgba(0, 0, 0, 0.35);
  --scrollbar-thumb: rgba(148, 163, 184, 0.3);
  background:
    radial-gradient(ellipse 100% 60% at 50% -20%, rgba(var(--accent-rgb), 0.07), transparent 50%),
    radial-gradient(ellipse 60% 40% at 100% 10%, rgba(var(--accent2-rgb), 0.05), transparent 45%),
    #0a0c0f;
}

body.staff::before {
  content: "";
  position: fixed;
  inset: 0;
  background-image: radial-gradient(rgba(148, 163, 184, 0.05) 1px, transparent 1px);
  background-size: 28px 28px;
  pointer-events: none;
  z-index: 0;
  opacity: 0.35;
  mask-image: linear-gradient(180deg, rgba(0, 0, 0, 0.45) 0%, black 40%, black 100%);
}

.sidebar {
  position: sticky;
  top: 0;
  align-self: flex-start;
  z-index: 35;
  width: 260px;
  flex-shrink: 0;
  height: 100vh;
  max-height: 100vh;
  overflow-x: hidden;
  overflow-y: auto;
  overscroll-behavior: contain;
  display: flex;
  flex-direction: column;
  padding: 0.75rem 0 0;
  background: rgba(10, 12, 15, 0.94);
  border-right: 1px solid rgba(255, 255, 255, 0.08);
  backdrop-filter: blur(14px) saturate(1.1);
  -webkit-backdrop-filter: blur(14px) saturate(1.1);
  box-shadow: 4px 0 32px rgba(0, 0, 0, 0.4);
  --scrollbar-size: 6px;
  transition: width 0.2s ease;
}

.sidebar__head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-right: 0.65rem;
}

.sidebar__toggle {
  flex-shrink: 0;
  width: 30px;
  height: 30px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 8px;
  border: 1px solid transparent;
  background: none;
  color: var(--muted);
  font-size: 0.8rem;
  cursor: pointer;
  transition: background 0.15s ease, color 0.15s ease, transform 0.2s ease;
}

.sidebar__toggle:hover {
  background: rgba(148, 163, 184, 0.1);
  color: var(--text);
}

body.staff[data-sidebar-collapsed] .sidebar__toggle i {
  transform: rotate(180deg);
}

body.staff[data-sidebar-collapsed] .sidebar {
  width: 60px;
}

body.staff[data-sidebar-collapsed] .sidebar__brand-name,
body.staff[data-sidebar-collapsed] .sidebar__brand-logo,
body.staff[data-sidebar-collapsed] .sidebar__section-label,
body.staff[data-sidebar-collapsed] .sidebar__nav .sidebar__link span,
body.staff[data-sidebar-collapsed] .sidebar__foot .sidebar__link span,
body.staff[data-sidebar-collapsed] .sidebar__foot .sidebar__linkish span {
  display: none;
}

body.staff[data-sidebar-collapsed] .sidebar__head {
  justify-content: center;
  padding-right: 0;
}

body.staff[data-sidebar-collapsed] .sidebar__brand {
  justify-content: center;
  margin: 0 0.35rem 0.5rem;
  padding: 0.5rem;
}

body.staff[data-sidebar-collapsed] .sidebar__nav .sidebar__link {
  justify-content: center;
  padding: 0.55rem;
}

body.staff[data-sidebar-collapsed] .sidebar__nav .sidebar__link i {
  font-size: 1.1em;
}

body.staff[data-sidebar-collapsed] .sidebar__foot .sidebar__link,
body.staff[data-sidebar-collapsed] .sidebar__foot .sidebar__linkish {
  justify-content: center;
  padding: 0.55rem !important;
}

.sidebar__overlay {
  display: none;
}

.staff-bar__hamburger {
  display: none;
}

@media (max-width: 768px) {
  body.staff[data-sidebar-collapsed] .sidebar,
  .sidebar {
    position: fixed;
    top: 0;
    left: 0;
    width: 260px !important;
    height: 100vh;
    transform: translateX(-100%);
    transition: transform 0.25s ease;
    z-index: 100;
  }

  body.staff[data-sidebar-collapsed] .sidebar__brand-name,
  body.staff[data-sidebar-collapsed] .sidebar__brand-logo,
  body.staff[data-sidebar-collapsed] .sidebar__section-label,
  body.staff[data-sidebar-collapsed] .sidebar__nav .sidebar__link span,
  body.staff[data-sidebar-collapsed] .sidebar__foot .sidebar__link span,
  body.staff[data-sidebar-collapsed] .sidebar__foot .sidebar__linkish span {
    display: inline;
  }

  body.staff[data-sidebar-collapsed] .sidebar__head {
    justify-content: space-between;
    padding-right: 0.65rem;
  }

  body.staff[data-sidebar-collapsed] .sidebar__brand {
    justify-content: flex-start;
    margin: 0 0.75rem 0.75rem;
    padding: 0.65rem 0.85rem;
  }

  body.staff[data-sidebar-collapsed] .sidebar__nav .sidebar__link {
    justify-content: flex-start;
    padding: 0.5rem 0.75rem;
  }

  body.staff[data-sidebar-collapsed] .sidebar__foot .sidebar__link,
  body.staff[data-sidebar-collapsed] .sidebar__foot .sidebar__linkish {
    justify-content: flex-start;
    padding: 0.5rem 0.75rem !important;
  }

  body.staff-sidebar-open .sidebar {
    transform: translateX(0);
  }

  .sidebar__overlay {
    display: block;
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.5);
    backdrop-filter: blur(4px);
    z-index: 99;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.25s ease;
  }

  body.staff-sidebar-open .sidebar__overlay {
    opacity: 1;
    pointer-events: auto;
  }

  .sidebar__toggle {
    display: none;
  }

  .staff-bar__hamburger {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 36px;
    border-radius: 8px;
    border: 1px solid var(--border);
    background: none;
    color: var(--muted);
    font-size: 1rem;
    cursor: pointer;
    flex-shrink: 0;
    transition: background 0.15s ease, color 0.15s ease;
  }

  .staff-bar__hamburger:hover {
    background: rgba(255, 255, 255, 0.06);
    color: var(--text);
  }
}

.sidebar__brand {
  display: flex;
  align-items: center;
  gap: 0.65rem;
  margin: 0 0.75rem 0.75rem;
  padding: 0.65rem 0.85rem;
  border-radius: var(--radius-lg);
  border: 1px solid transparent;
  font-weight: 700;
  font-size: 1.02rem;
  letter-spacing: -0.02em;
  color: var(--text);
  text-decoration: none;
  transition: background 0.15s ease, border-color 0.15s ease;
}

.sidebar__brand:hover {
  background: rgba(148, 163, 184, 0.06);
  border-color: var(--border);
  color: var(--text);
  text-decoration: none;
}

.sidebar__brand--with-logo {
  padding: 0.55rem 0.85rem;
  gap: 0.6rem;
}

.sidebar__brand-name {
  min-width: 0;
  flex: 1;
  font-family: var(--font);
  font-size: 0.98rem;
  font-weight: 700;
  letter-spacing: -0.02em;
  line-height: 1.25;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.sidebar__brand-logo {
  display: block;
  flex-shrink: 0;
  max-height: 2.15rem;
  width: auto;
  max-width: min(45%, 7.5rem);
  object-fit: contain;
}

.sidebar__brand-mark {
  width: 10px;
  height: 10px;
  border-radius: 3px;
  flex-shrink: 0;
  background: linear-gradient(135deg, var(--accent), var(--accent2));
  box-shadow: 0 0 18px rgba(var(--accent-rgb), 0.35);
}

.sidebar__brand-text {
  font-family: var(--font);
  font-size: 0.98rem;
  font-weight: 700;
  letter-spacing: -0.02em;
}

.sidebar__section-label {
  margin: 0.65rem 0.75rem 0.4rem;
  padding: 0;
  font-size: 0.62rem;
  font-weight: 700;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--muted);
  opacity: 0.75;
  list-style: none;
}

.sidebar__section-label:first-child {
  margin-top: 0.15rem;
}

.sidebar__nav {
  display: flex;
  flex-direction: column;
  padding: 0.35rem 0.65rem;
  flex: 1;
  gap: 0.15rem;
}

.sidebar__nav .sidebar__link {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  padding: 0.5rem 0.75rem;
  border-radius: 10px;
  color: var(--muted);
  font-weight: 500;
  font-size: 0.9rem;
  border: 1px solid transparent;
  transition: background 0.15s ease, color 0.15s ease, border-color 0.15s ease;
}

.sidebar__nav .sidebar__link i {
  width: 1.25em;
  text-align: center;
  opacity: 0.88;
  font-size: 0.95em;
}

.sidebar__nav .sidebar__link:hover {
  background: rgba(148, 163, 184, 0.07);
  color: var(--text);
  text-decoration: none;
}

.sidebar__nav .sidebar__link:hover i {
  opacity: 1;
}

.sidebar__nav .sidebar__link.is-active {
  background: rgba(var(--accent-rgb), 0.09);
  border-color: rgba(var(--accent-rgb), 0.22);
  color: var(--text);
}

.sidebar__nav .sidebar__link.is-active i {
  color: var(--accent);
  opacity: 1;
}

.sidebar__foot {
  position: relative;
  z-index: 1;
  padding: 0.75rem 0.85rem 1rem;
  margin-top: auto;
  border-top: 1px solid var(--border);
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
  background: linear-gradient(180deg, transparent, rgba(0, 0, 0, 0.15));
}

.sidebar__foot .sidebar__link {
  padding: 0.5rem 0.75rem;
  border-radius: 10px;
}

.sidebar__link--store {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  color: var(--muted);
  font-weight: 500;
  font-size: 0.9rem;
}

.sidebar__link--store:hover {
  background: rgba(var(--accent-rgb), 0.1);
  color: var(--accent);
  text-decoration: none;
}

.sidebar__linkish {
  display: flex;
  align-items: center;
  gap: 0.55rem;
  width: 100%;
  text-align: left;
  padding: 0.5rem 0.75rem !important;
  border-radius: 10px;
}

.sidebar__linkish i {
  width: 1.25em;
  text-align: center;
  opacity: 0.85;
}

.sidebar__linkish:hover i {
  opacity: 1;
}

.staff-main {
  position: relative;
  z-index: 1;
  flex: 1;
  display: flex;
  flex-direction: column;
  min-width: 0;
}

.staff-bar {
  position: sticky;
  top: 0;
  z-index: 40;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  flex-wrap: wrap;
  min-height: 60px;
  padding: 0.65rem 1.25rem;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
  background: rgba(10, 12, 15, 0.92);
  backdrop-filter: blur(12px) saturate(1.15);
  -webkit-backdrop-filter: blur(12px) saturate(1.15);
  box-shadow: none;
}

.staff-bar::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: -1px;
  height: 1px;
  background: linear-gradient(90deg, transparent 0%, rgba(var(--accent-rgb), 0.28) 50%, transparent 100%);
  pointer-events: none;
}

.staff-bar__title {
  display: flex;
  flex-direction: column;
  gap: 0.15rem;
  min-width: 0;
}

.staff-bar__eyebrow {
  font-family: var(--font-mono);
  font-size: 0.65rem;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--muted);
}

.staff-bar__page-name {
  font-size: 1.05rem;
  font-weight: 700;
  letter-spacing: -0.03em;
  color: var(--text);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.staff-bar__actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.75rem;
}

.staff-bar__store-btn span {
  display: inline;
}

@media (max-width: 520px) {
  .staff-bar__store-btn span {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
  }
}

.staff-bar__user {
  display: flex;
  align-items: center;
  gap: 0.55rem;
}

.staff-bar__avatar {
  width: 36px;
  height: 36px;
  border-radius: 10px;
  object-fit: cover;
  border: 1px solid var(--border-strong);
  box-shadow: 0 2px 12px rgba(0, 0, 0, 0.35);
}

.staff-bar__username {
  font-size: 0.875rem;
  font-weight: 500;
  color: var(--muted);
  max-width: 10rem;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

@media (max-width: 640px) {
  .staff-bar__username {
    display: none;
  }
}

.staff-bar__left {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  min-width: 0;
  flex: 1;
}

.staff-breadcrumb {
  display: none;
}

@media (min-width: 769px) {
  .staff-breadcrumb {
    display: block;
    margin-left: 1rem;
    padding-left: 1rem;
    border-left: 1px solid var(--border);
  }

  .staff-breadcrumb ol {
    display: flex;
    align-items: center;
    gap: 0;
    list-style: none;
    margin: 0;
    padding: 0;
    font-size: 0.8rem;
    color: var(--muted);
  }

  .staff-breadcrumb li + li::before {
    content: "/";
    margin: 0 0.45rem;
    opacity: 0.5;
  }

  .staff-breadcrumb a {
    color: var(--muted);
    text-decoration: none;
    transition: color 0.15s ease;
  }

  .staff-breadcrumb a:hover {
    color: var(--accent);
  }

  .staff-breadcrumb li[aria-current] {
    color: var(--text);
    font-weight: 500;
  }
}

/* Toast notifications */
.staff-toast-container {
  position: fixed;
  top: 1rem;
  right: 1rem;
  z-index: 200;
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  max-width: min(400px, calc(100vw - 2rem));
}

.staff-toast {
  display: flex;
  align-items: center;
  gap: 0.65rem;
  padding: 0.75rem 1rem;
  border-radius: 10px;
  border: 1px solid var(--border);
  background: rgba(18, 22, 28, 0.95);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.5);
  color: var(--text);
  font-size: 0.875rem;
  font-weight: 500;
  animation: staffToastIn 0.3s ease forwards;
  transition: opacity 0.3s ease, transform 0.3s ease;
}

@keyframes staffToastIn {
  from { opacity: 0; transform: translateX(100%); }
  to { opacity: 1; transform: translateX(0); }
}

.staff-toast__icon {
  flex-shrink: 0;
  font-size: 1.1rem;
}

.staff-toast--success .staff-toast__icon { color: #86efac; }
.staff-toast--error .staff-toast__icon { color: #fca5a5; }
.staff-toast--info .staff-toast__icon { color: #7dd3fc; }

.staff-toast--success { border-color: rgba(34, 197, 94, 0.3); }
.staff-toast--error { border-color: rgba(248, 113, 113, 0.3); }
.staff-toast--info { border-color: rgba(var(--accent-rgb), 0.3); }

.staff-toast__message {
  flex: 1;
  min-width: 0;
}

.staff-toast__close {
  flex-shrink: 0;
  width: 24px;
  height: 24px;
  display: flex;
  align-items: center;
  justify-content: center;
  border: none;
  background: none;
  color: var(--muted);
  font-size: 1.15rem;
  cursor: pointer;
  border-radius: 6px;
  transition: background 0.15s ease, color 0.15s ease;
}

.staff-toast__close:hover {
  background: rgba(255, 255, 255, 0.08);
  color: var(--text);
}

.staff-content {
  position: relative;
  z-index: 1;
  flex: 1;
  width: 100%;
  max-width: 1320px;
  margin: 0 auto;
  padding: 1.5rem 1.25rem 2.5rem;
}

.staff-content--app {
  padding: 1.65rem clamp(1rem, 3vw, 1.75rem) 3rem;
}

.staff-page-head {
  margin: 0 0 1.75rem;
}

.staff-page-head__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  align-items: center;
  margin-top: 0.75rem;
}

.staff-page-head__title {
  font-size: clamp(1.5rem, 3vw, 1.85rem);
  font-weight: 700;
  letter-spacing: -0.035em;
  line-height: 1.15;
  margin: 0 0 0.5rem;
}

.staff-page-head__lead {
  margin: 0;
  font-size: 0.95rem;
  max-width: 52ch;
  line-height: 1.55;
}

.staff-page-head--split {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-start;
  justify-content: space-between;
  gap: 1rem 1.5rem;
}

.staff-page-head--split .staff-page-head__intro {
  flex: 1 1 18rem;
  min-width: 0;
}

.staff-page-head__toolbar {
  flex-shrink: 0;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.5rem;
  padding-top: 0.15rem;
}

/* Create-product modal (staff products + product edit) */
.staff-modal {
  padding: 0;
  margin: auto;
  border: none;
  background: transparent;
  max-width: min(44rem, calc(100vw - 1.5rem));
  width: 100%;
  /* UA dialog stylesheet sets color to CanvasText (often black); force staff theme */
  color: var(--text);
  max-height: min(92vh, 100vh);
}

.staff-modal--create-product {
  max-width: min(48rem, calc(100vw - 1.5rem));
}

.staff-modal::backdrop {
  background: rgba(0, 0, 0, 0.62);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
}

.staff-modal__panel {
  border-radius: var(--radius-lg);
  border: 1px solid var(--border);
  background: var(--bg-elevated);
  box-shadow: var(--shadow-card), 0 0 0 1px rgba(255, 255, 255, 0.04) inset;
  overflow: hidden;
}

.staff-modal__panel--stacked {
  display: flex;
  flex-direction: column;
  max-height: min(88vh, 52rem);
  min-height: 0;
}

/* Form sits between header and footer; must shrink so inner .staff-modal__scroll can scroll */
.staff-modal__panel--stacked > form.staff-product-form--modal {
  flex: 1 1 auto;
  min-height: 0;
  display: flex;
  flex-direction: column;
  overflow: hidden;
}

.staff-modal__head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 0.75rem 1rem;
  padding: 1rem 1.15rem 0.95rem;
  border-bottom: 1px solid var(--border);
  flex-shrink: 0;
  background: linear-gradient(180deg, rgba(var(--accent-rgb), 0.06) 0%, transparent 100%);
}

.staff-modal__head-text {
  min-width: 0;
  flex: 1;
}

.staff-modal__title {
  margin: 0 0 0.35rem;
  font-size: 1.15rem;
  font-weight: 700;
  letter-spacing: -0.03em;
  line-height: 1.25;
  color: var(--text);
}

.staff-modal__subtitle {
  margin: 0;
  font-size: 0.8125rem;
  line-height: 1.45;
  color: var(--muted);
  max-width: 42ch;
}

.staff-modal__close {
  flex-shrink: 0;
  margin-top: -0.15rem;
}

.staff-modal__scroll {
  flex: 1 1 auto;
  min-height: 0;
  overflow-y: auto;
  overflow-x: hidden;
  padding: 1rem 1.15rem;
  -webkit-overflow-scrolling: touch;
}

.staff-product-form--modal .staff-modal__scroll {
  padding-bottom: 0.25rem;
}

.staff-modal__section {
  margin: 0 0 1.25rem;
  padding: 0 0 1.15rem;
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
}

.staff-modal__section:last-of-type {
  margin-bottom: 0;
  padding-bottom: 0;
  border-bottom: none;
}

.staff-modal__section--compact {
  padding-bottom: 0;
  margin-bottom: 0;
}

.staff-modal__section-label {
  margin: 0 0 0.65rem;
  font-size: 0.65rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--muted);
  opacity: 0.9;
}

.staff-product-form--modal.staff-form > label {
  margin-bottom: 0.85rem;
}

.staff-product-form--modal .staff-form-row {
  margin-bottom: 0.85rem;
}

.staff-modal__foot {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: flex-end;
  gap: 0.5rem 0.75rem;
  padding: 0.85rem 1.15rem;
  border-top: 1px solid var(--border);
  flex-shrink: 0;
  background: rgba(0, 0, 0, 0.28);
}

.staff-modal__foot .btn-primary {
  min-width: 10rem;
}

.staff-confirm-dialog {
  max-width: 28rem;
}

.staff-confirm-dialog .staff-modal__panel {
  padding: 1.25rem 1.5rem;
}

.staff-confirm-dialog .staff-modal__foot {
  justify-content: flex-end;
}

.staff-tabs {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin: 0 0 1.5rem;
  padding: 0;
  list-style: none;
}

.staff-tabs__tab {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  padding: 0.45rem 0.9rem;
  border-radius: 999px;
  font-size: 0.875rem;
  font-weight: 600;
  color: var(--muted);
  border: 1px solid var(--border);
  background: rgba(0, 0, 0, 0.2);
  text-decoration: none;
  cursor: default;
}

.staff-tabs__tab.is-active {
  color: var(--text);
  border-color: rgba(var(--accent-rgb), 0.38);
  background: rgba(var(--accent-rgb), 0.1);
  box-shadow: 0 0 0 1px rgba(var(--accent-rgb), 0.12);
}

.staff-tabs__tab:hover:not(.is-active) {
  color: var(--text);
  background: rgba(255, 255, 255, 0.04);
  text-decoration: none;
}

.staff-tab-panel {
  display: none;
}

.staff-tab-panel.is-active {
  display: block;
}

.staff-integration-lead {
  margin: 0 0 1.25rem;
  max-width: 62ch;
}

.staff-integration-banner {
  margin: 0 0 1.25rem;
  padding: 0.75rem 1rem;
  border-radius: var(--radius);
  border: 1px solid rgba(var(--accent-rgb), 0.28);
  background: rgba(var(--accent-rgb), 0.08);
  max-width: 72ch;
}

.staff-integration-hint {
  margin: -0.35rem 0 1rem;
}

.staff-integration-status {
  margin: 0 0 1.5rem;
  padding: 0;
  display: grid;
  gap: 1rem;
}

.staff-integration-status > div {
  margin: 0;
  padding: 0.85rem 1rem;
  border-radius: var(--radius);
  border: 1px solid var(--border);
  background: rgba(0, 0, 0, 0.2);
}

.staff-integration-status dt {
  margin: 0 0 0.35rem;
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--muted);
}

.staff-integration-status dd {
  margin: 0;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.5rem 0.75rem;
  font-size: 0.9rem;
  line-height: 1.45;
}

.staff-pill {
  display: inline-flex;
  align-items: center;
  padding: 0.2rem 0.55rem;
  border-radius: 6px;
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.02em;
  text-transform: uppercase;
}

.staff-pill--ok {
  color: #86efac;
  background: rgba(34, 197, 94, 0.12);
  border: 1px solid rgba(34, 197, 94, 0.35);
}

.staff-pill--warn {
  color: #fcd34d;
  background: rgba(245, 158, 11, 0.1);
  border: 1px solid rgba(245, 158, 11, 0.35);
}

.staff-section-title {
  font-size: 1rem;
  font-weight: 600;
  letter-spacing: -0.02em;
  margin: 0 0 1rem;
  padding-bottom: 0.65rem;
  border-bottom: 1px solid var(--border);
  color: var(--text);
}

.staff-card {
  margin-bottom: 1.75rem;
  padding: 1.35rem 1.5rem;
  border-radius: var(--radius-lg);
  border: 1px solid rgba(255, 255, 255, 0.07);
  background: linear-gradient(165deg, rgba(18, 22, 28, 0.94) 0%, rgba(10, 12, 15, 0.98) 100%);
  box-shadow: 0 0 0 1px rgba(255, 255, 255, 0.04), 0 8px 32px -12px rgba(0, 0, 0, 0.5);
  transition: border-color 0.15s ease;
}

.staff-card:last-child {
  margin-bottom: 0;
}

.staff-card .staff-section-title {
  margin-top: 0;
}

.staff-stack {
  display: flex;
  flex-direction: column;
  gap: 1.75rem;
}

.staff-back {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  margin-top: 1.25rem;
  font-size: 0.9rem;
  font-weight: 500;
}

body.staff .table-wrap {
  margin-top: 0.5rem;
  border: 1px solid rgba(255, 255, 255, 0.07);
  background: rgba(8, 10, 14, 0.65);
  box-shadow: 0 0 0 1px rgba(255, 255, 255, 0.04), 0 8px 32px -12px rgba(0, 0, 0, 0.5);
  -webkit-overflow-scrolling: touch;
}

body.staff .staff-mb {
  margin-bottom: 1.75rem;
}

body.staff tbody tr:hover td {
  background: rgba(var(--accent-rgb), 0.07);
}

body.staff .staff-table-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.5rem;
  white-space: nowrap;
}

body.staff .staff-btn-danger {
  color: #f87171;
}

body.staff .staff-inline-form {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.5rem;
}

body.staff .staff-inline-form select {
  max-width: 11rem;
}

body.staff .staff-link-edit {
  font-weight: 600;
}

.staff-code-cell {
  font-size: 0.75rem;
  word-break: break-all;
}

.staff-code-inline {
  font-family: var(--font-mono);
  font-size: 0.85em;
  padding: 0.1em 0.35em;
  border-radius: 6px;
  background: rgba(0, 0, 0, 0.35);
  border: 1px solid var(--border);
}

body.staff .btn-primary {
  background: linear-gradient(135deg, var(--accent) 0%, var(--accent3) 100%);
  border-color: rgba(var(--accent-rgb), 0.5);
  color: #0f172a;
  box-shadow: 0 2px 16px rgba(var(--accent-rgb), 0.22);
}

body.staff .btn-primary:hover {
  background: linear-gradient(135deg, var(--accent-hover) 0%, var(--accent) 100%);
  border-color: rgba(var(--accent-hover-rgb), 0.55);
  color: #0f172a;
}

body.staff .btn-ghost {
  border-color: var(--border-strong);
  color: var(--text);
}

body.staff .btn-ghost:hover {
  background: rgba(255, 255, 255, 0.06);
  border-color: rgba(255, 255, 255, 0.14);
}

.stats {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
  gap: 1rem;
}

body.staff .stat {
  position: relative;
  padding: 1.15rem 1.2rem;
  border-radius: var(--radius-lg);
  border: 1px solid rgba(255, 255, 255, 0.08);
  background: linear-gradient(155deg, rgba(18, 22, 28, 0.9) 0%, rgba(10, 12, 15, 0.96) 100%);
  box-shadow: var(--shadow-card);
  overflow: hidden;
}

body.staff .stat::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 2px;
  background: linear-gradient(90deg, rgba(var(--accent-rgb), 0.45), rgba(var(--accent2-rgb), 0.4));
  opacity: 0.9;
}

body.staff .stat b {
  font-family: var(--font-mono);
  font-size: 1.65rem;
  font-weight: 600;
  letter-spacing: -0.03em;
  display: block;
  margin-bottom: 0.25rem;
  background: linear-gradient(105deg, #f8fafc 0%, var(--accent-soft) 45%, var(--accent) 100%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

body.staff .stat .muted {
  font-size: 0.8125rem;
  font-weight: 500;
}

@media (max-width: 900px) {
  body.staff {
    flex-direction: column;
    align-items: stretch;
  }

  .sidebar {
    position: sticky;
    top: 0;
    z-index: 50;
    width: 100%;
    height: auto;
    max-height: none;
    flex-direction: row;
    flex-wrap: wrap;
    align-items: center;
    padding: 0.65rem 0.75rem 0;
    border-right: none;
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.35);
  }

  .sidebar__brand {
    margin: 0 0.5rem 0.5rem 0;
  }

  .sidebar__nav {
    flex-direction: row;
    flex-wrap: wrap;
    flex: 1;
    min-width: 0;
    padding: 0 0 0.5rem;
    gap: 0.2rem;
  }

  .sidebar__nav .sidebar__link span {
    display: none;
  }

  .sidebar__nav .sidebar__link {
    justify-content: center;
    padding: 0.5rem 0.65rem;
  }

  .sidebar__foot {
    flex-direction: row;
    flex-wrap: wrap;
    align-items: center;
    width: 100%;
    margin-top: 0;
    padding: 0.5rem 0.75rem 0.75rem;
    border-top: 1px solid var(--border);
    gap: 0.5rem;
    justify-content: flex-end;
  }

  .sidebar__foot .sidebar__link--store span {
    display: none;
  }

  .sidebar__linkish span {
    display: none;
  }
}

/* ——— Storefront catalog: left sidebar categories + grid ——— */
.catalog-layout {
  display: grid;
  grid-template-columns: minmax(13.5rem, 17.5rem) minmax(0, 1fr);
  gap: 1.75rem 2rem;
  align-items: start;
  width: 100%;
}

.catalog-sidebar {
  position: sticky;
  top: 1rem;
  z-index: 2;
  padding: 1rem 1rem 1.15rem;
  border-radius: var(--radius-lg);
  border: 1px solid var(--border);
  background: linear-gradient(180deg, rgba(17, 24, 39, 0.95) 0%, rgba(6, 8, 15, 0.98) 100%);
  box-shadow: var(--shadow-card);
  align-self: start;
}

.catalog-sidebar__title {
  margin: 0 0 0.9rem;
  font-size: 0.8125rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--text);
}

.catalog-sidebar__nav {
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
}

.catalog-sidebar__btn {
  display: flex;
  width: 100%;
  align-items: center;
  justify-content: flex-start;
  text-align: left;
  padding: 0.6rem 0.8rem;
  border-radius: 10px;
  border: 1px solid rgba(51, 65, 85, 0.55);
  background: rgba(15, 23, 42, 0.55);
  color: var(--text);
  font-size: 0.9rem;
  font-weight: 600;
  font-family: inherit;
  line-height: 1.3;
  cursor: pointer;
  transition:
    background 0.15s ease,
    color 0.15s ease,
    border-color 0.15s ease,
    box-shadow 0.15s ease;
}

.catalog-sidebar__btn:hover {
  border-color: var(--border-strong);
  background: rgba(30, 41, 59, 0.65);
}

.catalog-sidebar__btn.is-active {
  color: var(--text);
  border-color: rgba(129, 140, 248, 0.55);
  background: rgba(99, 102, 241, 0.2);
  box-shadow:
    0 0 0 1px rgba(129, 140, 248, 0.15),
    inset 0 1px 0 rgba(255, 255, 255, 0.04);
}

.catalog-sidebar__btn-label {
  display: block;
  width: 100%;
}

.catalog-main {
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 1.25rem;
}

.catalog-main__search {
  flex: 0 0 auto;
}

@media (max-width: 767px) {
  .catalog-layout {
    grid-template-columns: 1fr;
    gap: 1.35rem;
  }

  .catalog-sidebar {
    position: static;
    z-index: auto;
  }
}

/* Legacy toolbar (if used elsewhere) */
.catalog-toolbar {
  display: flex;
  flex-direction: column;
  gap: 1rem;
  margin-bottom: 1.5rem;
}

@media (min-width: 720px) {
  .catalog-toolbar {
    flex-direction: row;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
  }
}

.catalog-search {
  position: relative;
  flex: 1;
  min-width: min(100%, 18rem);
}

.catalog-search__icon {
  position: absolute;
  left: 0.85rem;
  top: 50%;
  transform: translateY(-50%);
  color: var(--muted);
  font-size: 0.9rem;
  pointer-events: none;
}

.catalog-search__input {
  width: 100%;
  padding: 0.55rem 0.85rem 0.55rem 2.35rem !important;
  max-width: none !important;
  border-radius: 999px;
  background: rgba(15, 23, 42, 0.65) !important;
}

.catalog-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
  align-items: center;
}

.catalog-chip {
  padding: 0.35rem 0.85rem;
  border-radius: 999px;
  border: 1px solid var(--border);
  background: rgba(15, 23, 42, 0.5);
  color: var(--muted);
  font-size: 0.8125rem;
  font-weight: 600;
  font-family: inherit;
  cursor: pointer;
  transition: background 0.15s ease, color 0.15s ease, border-color 0.15s ease;
}

.catalog-chip:hover {
  color: var(--text);
  border-color: var(--border-strong);
}

.catalog-chip.is-active {
  color: var(--text);
  border-color: rgba(129, 140, 248, 0.45);
  background: rgba(99, 102, 241, 0.12);
}

.catalog-card__badge.digital-badge {
  position: absolute;
  bottom: 0.65rem;
  left: 0.65rem;
  z-index: 3;
  padding: 0.25rem 0.55rem;
  font-size: 0.7rem;
  font-weight: 600;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  border-radius: 8px;
  color: #a5f3fc;
  background: rgba(6, 8, 15, 0.82);
  border: 1px solid rgba(var(--accent-rgb), 0.35);
  pointer-events: none;
}

.catalog-card__badge.owned-badge {
  position: absolute;
  bottom: 0.65rem;
  right: 0.65rem;
  z-index: 3;
  padding: 0.25rem 0.55rem;
  font-size: 0.7rem;
  font-weight: 600;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  border-radius: 8px;
  color: #86efac;
  background: rgba(6, 8, 15, 0.82);
  border: 1px solid rgba(34, 197, 94, 0.35);
  pointer-events: none;
}

.catalog-card__category {
  margin: 0 0 0.35rem;
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: #a5b4fc;
}

.product-detail__category {
  margin: 0 0 0.35rem;
  font-size: 0.8125rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: #a5b4fc;
}

.product-detail__digital {
  margin: 0.5rem 0 0;
}

.product-detail__digital i {
  margin-right: 0.35rem;
  color: var(--accent2);
}

.product-detail__releases {
  margin: 0.65rem 0 0;
}

.product-detail__releases-link {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  font-size: 0.875rem;
  font-weight: 600;
  color: var(--accent);
  text-decoration: none;
}

.product-detail__releases-link:hover {
  color: #7dd3fc;
}

.product-detail__releases-link i {
  opacity: 0.9;
}

/* Product releases page */
.releases-page {
  max-width: 52rem;
  margin: 0 auto;
}

.releases-hero {
  margin-bottom: 2rem;
  padding-bottom: 1.5rem;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.releases-hero__title {
  margin: 0.35rem 0 0.5rem;
  font-size: clamp(1.5rem, 3vw, 2rem);
  line-height: 1.2;
}

.releases-hero__lead {
  margin: 0 0 1rem;
  max-width: 40rem;
  line-height: 1.5;
}

.releases-hero__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.65rem;
}

.releases-timeline {
  list-style: none;
  margin: 0;
  padding: 0 0 0 1.25rem;
  border-left: 2px solid rgba(99, 102, 241, 0.35);
}

.releases-timeline__item {
  position: relative;
  padding-bottom: 1.75rem;
}

.releases-timeline__item:last-child {
  padding-bottom: 0;
}

.releases-timeline__marker {
  position: absolute;
  left: calc(-1.25rem - 6px);
  top: 0.35rem;
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: var(--accent);
  box-shadow: 0 0 0 3px rgba(99, 102, 241, 0.25);
}

.releases-card {
  padding: 1rem 1.15rem;
  border-radius: var(--radius);
  border: 1px solid rgba(255, 255, 255, 0.08);
  background: rgba(0, 0, 0, 0.2);
}

.releases-card__head {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  justify-content: space-between;
  gap: 0.5rem 1rem;
  margin-bottom: 0.5rem;
}

.releases-card__version {
  margin: 0;
  font-size: 1.15rem;
  display: inline-flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.releases-card__badge {
  display: inline-block;
  padding: 0.15rem 0.45rem;
  font-size: 0.6875rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  border-radius: 999px;
  background: rgba(99, 102, 241, 0.35);
  color: #e0e7ff;
}

.releases-card__date {
  font-variant-numeric: tabular-nums;
}

.releases-card__notes {
  margin: 0 0 0.65rem;
  font-size: 0.9375rem;
  line-height: 1.55;
}

.releases-card__meta {
  margin: 0;
}

.releases-download-list {
  list-style: none;
  margin: 0.75rem 0 0;
  padding: 0;
}

.releases-download-list li {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 0.5rem 0.75rem;
  margin: 0 0 0.5rem;
}

.releases-download-list li:last-child {
  margin-bottom: 0;
}

.releases-download-link {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  font-size: 0.875rem;
  font-weight: 600;
  color: var(--accent);
  text-decoration: none;
}

.releases-download-link:hover {
  color: #7dd3fc;
}

.releases-card--legacy {
  margin-top: 1.5rem;
  padding: 1.15rem 1.25rem;
}

.releases-legacy__hint {
  margin: 0 0 0.75rem;
}

.order-downloads-footnote {
  margin: 1rem 0 0;
  max-width: 40rem;
}

.account-download-list {
  list-style: none;
  margin: 0 0 0.75rem;
  padding: 0;
}

.account-download-list li {
  margin: 0 0 0.35rem;
}

.account-download-link {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  font-size: 0.875rem;
  font-weight: 600;
  color: var(--accent);
}

.account-download-link:hover {
  color: #7dd3fc;
}

.account-version-block {
  margin: 0 0 1rem;
  padding-bottom: 0.75rem;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.account-version-block:last-child {
  border-bottom: none;
  margin-bottom: 0;
  padding-bottom: 0;
}

.account-version-label {
  margin: 0 0 0.35rem;
  font-size: 0.8125rem;
  font-weight: 700;
  letter-spacing: 0.02em;
  text-transform: uppercase;
  color: var(--muted);
}

.account-version-notes {
  margin: 0 0 0.5rem;
  font-size: 0.8125rem;
}

.order-downloads-cell {
  vertical-align: top;
  min-width: 8rem;
}

.order-download-list {
  list-style: none;
  margin: 0;
  padding: 0;
}

.order-download-list li {
  margin: 0 0 0.35rem;
}

.order-download-list li:last-child {
  margin-bottom: 0;
}

.order-downloads-versioned {
  display: flex;
  flex-direction: column;
  gap: 0.65rem;
}

.order-version-block {
  padding-bottom: 0.5rem;
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
}

.order-version-block:last-child {
  border-bottom: none;
  padding-bottom: 0;
}

.order-version-label {
  margin: 0 0 0.35rem;
}

/* ——— Staff catalog + uploads ——— */
.staff-catalog-page {
  width: 100%;
  max-width: 100%;
}

.staff-catalog-page .staff-card {
  width: 100%;
}

.staff-form-row {
  display: grid;
  gap: 1rem;
  grid-template-columns: 1fr 1fr;
}

.staff-form-row--grow {
  grid-column: 1 / -1;
}

.staff-upload-target select {
  width: 100%;
  max-width: 28rem;
  margin-bottom: 0.75rem;
  padding: 0.5rem 0.65rem;
  border-radius: var(--radius);
  border: 1px solid rgba(255, 255, 255, 0.12);
  background: rgba(0, 0, 0, 0.25);
  color: var(--text);
}

.staff-version-form {
  margin-bottom: 0;
}

.staff-version-card {
  margin: 1rem 0 0;
  padding: 1rem;
  border-radius: var(--radius);
  border: 1px solid rgba(255, 255, 255, 0.08);
  background: rgba(0, 0, 0, 0.15);
}

.staff-version-card__title {
  margin: 0 0 0.35rem;
  font-size: 1rem;
}

.staff-version-card__notes {
  margin: 0 0 0.75rem;
}

@media (max-width: 520px) {
  .staff-form-row {
    grid-template-columns: 1fr;
  }
}

.staff-file-drop input[type="file"] {
  width: 100%;
  max-width: none;
  padding: 0.65rem;
  border-style: dashed;
  border-radius: var(--radius);
  background: rgba(0, 0, 0, 0.2);
  cursor: pointer;
}

.staff-file-drop__label {
  display: block;
  margin-bottom: 0.4rem;
  font-weight: 600;
  font-size: 0.875rem;
  color: var(--text);
}

.staff-product-grid {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
  gap: 1rem;
}

.staff-product-card {
  display: flex;
  flex-direction: column;
  height: 100%;
  border-radius: var(--radius-lg);
  border: 1px solid rgba(255, 255, 255, 0.08);
  background: linear-gradient(165deg, rgba(18, 22, 28, 0.92) 0%, rgba(10, 12, 15, 0.98) 100%);
  overflow: hidden;
  box-shadow: var(--shadow-card);
}

.staff-product-card__media {
  aspect-ratio: 16/10;
  background: #0a0e18;
  overflow: hidden;
}

.staff-product-card__media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.staff-product-card__placeholder {
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--muted);
  font-size: 1.75rem;
  background: linear-gradient(145deg, #1a2332 0%, #0d1118 100%);
}

.staff-product-card__body {
  padding: 1rem 1.1rem 1.15rem;
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  flex: 1;
}

.staff-product-card__title {
  margin: 0;
  font-size: 1rem;
  font-weight: 600;
  letter-spacing: -0.02em;
  line-height: 1.3;
}

.staff-product-card__meta {
  margin: 0;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.4rem;
}

.staff-product-card__price {
  font-family: var(--font-mono);
  font-weight: 600;
  color: var(--accent2);
}

.staff-product-grid .staff-pill {
  display: inline-block;
  padding: 0.15rem 0.45rem;
  border-radius: 6px;
  font-size: 0.7rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: var(--accent);
  border: 1px solid rgba(var(--accent-rgb), 0.3);
  background: rgba(var(--accent-rgb), 0.1);
}

.staff-product-card__flags {
  margin: 0;
  line-height: 1.45;
}

.staff-product-card__warn {
  color: #fb923c;
}

.staff-product-card__edit {
  margin-top: auto;
  align-self: flex-start;
}

.staff-product-card__actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.5rem;
  margin-top: auto;
  padding-top: 0.75rem;
}

.staff-product-card__actions form {
  margin: 0;
}

.staff-catalog-empty {
  margin: 0;
}

.staff-file-list {
  list-style: none;
  margin: 0;
  padding: 0;
}

.staff-file-list__row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.65rem;
  padding: 0.55rem 0;
  border-bottom: 1px solid var(--border);
}

.staff-file-list__row:last-child {
  border-bottom: none;
}

.staff-file-list__name {
  flex: 1;
  min-width: 0;
  font-size: 0.875rem;
  font-weight: 500;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.staff-file-list__del {
  margin: 0;
}

/* ——— Staff audit log ——— */
.staff-audit-head {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  justify-content: space-between;
  gap: 1.25rem 2rem;
  margin-bottom: 1.5rem;
}

.staff-audit-head__intro {
  flex: 1;
  min-width: min(100%, 22rem);
}

.staff-audit-head__stat {
  flex-shrink: 0;
  padding: 0.85rem 1.15rem;
  border-radius: var(--radius-lg);
  border: 1px solid rgba(255, 255, 255, 0.1);
  background: linear-gradient(145deg, rgba(var(--accent-rgb), 0.08) 0%, rgba(10, 12, 15, 0.9) 100%);
  box-shadow: var(--shadow-card);
  text-align: right;
}

.staff-audit-head__stat-value {
  display: block;
  font-family: var(--font-mono);
  font-size: 1.75rem;
  font-weight: 700;
  letter-spacing: -0.03em;
  line-height: 1.1;
  color: var(--text);
}

.staff-audit-head__stat-label {
  display: block;
  margin-top: 0.2rem;
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--muted);
}

.staff-audit-toolbar {
  margin-bottom: 1.25rem;
  padding: 1rem 1.15rem;
}

.staff-audit-filters {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  gap: 0.85rem 1rem;
}

.staff-audit-field {
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
  min-width: 12rem;
  flex: 1 1 12rem;
}

.staff-audit-field--narrow {
  flex: 0 0 auto;
  min-width: 6.5rem;
}

.staff-audit-field__label {
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--muted);
}

.staff-audit-field input,
.staff-audit-field select {
  width: 100%;
  padding: 0.5rem 0.65rem;
  border-radius: var(--radius);
  border: 1px solid rgba(255, 255, 255, 0.12);
  background: rgba(0, 0, 0, 0.25);
  color: var(--text);
  font: inherit;
  font-size: 0.9rem;
}

.staff-audit-field input:focus,
.staff-audit-field select:focus {
  outline: none;
  border-color: rgba(var(--accent-rgb), 0.45);
  box-shadow: 0 0 0 2px rgba(var(--accent-rgb), 0.12);
}

.staff-audit-filters__actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.5rem;
  margin-left: auto;
}

.staff-audit-meta {
  margin: 0 0 0.85rem;
  font-size: 0.875rem;
}

.staff-audit-empty {
  text-align: center;
  padding: 2.5rem 1.5rem;
}

.staff-audit-empty__icon {
  font-size: 2.25rem;
  color: var(--muted);
  margin-bottom: 0.75rem;
  opacity: 0.85;
}

.staff-audit-empty__title {
  margin: 0 0 0.5rem;
  font-size: 1.15rem;
  font-weight: 700;
  letter-spacing: -0.02em;
}

.staff-audit-empty__text {
  margin: 0 auto;
  max-width: 40ch;
  font-size: 0.95rem;
  line-height: 1.55;
}

.staff-audit-table-wrap {
  border-radius: var(--radius-lg);
  border: 1px solid rgba(255, 255, 255, 0.08);
  background: rgba(0, 0, 0, 0.15);
  overflow: auto;
  -webkit-overflow-scrolling: touch;
}

.staff-audit-table {
  width: 100%;
  min-width: 920px;
  border-collapse: collapse;
  font-size: 0.875rem;
}

.staff-audit-table thead th {
  position: sticky;
  top: 0;
  z-index: 2;
  padding: 0.65rem 0.75rem;
  text-align: left;
  font-size: 0.65rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--muted);
  background: rgba(10, 12, 15, 0.96);
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
  white-space: nowrap;
}

.staff-audit-table tbody td {
  padding: 0.65rem 0.75rem;
  vertical-align: top;
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
}

.staff-audit-table tbody tr:last-child td {
  border-bottom: none;
}

.staff-audit-col--when {
  width: 8.5rem;
}

.staff-audit-col--ip {
  width: 7.5rem;
}

.staff-audit-col--details {
  min-width: 9rem;
}

.staff-audit-time {
  display: flex;
  flex-direction: column;
  gap: 0.15rem;
  line-height: 1.25;
}

.staff-audit-time__date {
  font-weight: 600;
  color: var(--text);
}

.staff-audit-time__clock {
  font-family: var(--font-mono);
  font-size: 0.75rem;
  color: var(--muted);
}

.staff-audit-actor {
  display: flex;
  align-items: center;
  gap: 0.55rem;
  min-width: 0;
}

.staff-audit-actor__avatar {
  width: 32px;
  height: 32px;
  border-radius: 9px;
  object-fit: cover;
  border: 1px solid rgba(255, 255, 255, 0.1);
  flex-shrink: 0;
}

.staff-audit-actor__meta {
  display: flex;
  flex-direction: column;
  gap: 0.1rem;
  min-width: 0;
}

.staff-audit-actor__name {
  font-weight: 600;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.staff-audit-actor__id {
  font-size: 0.75rem;
}

.staff-audit-system {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  color: var(--muted);
  font-weight: 500;
}

.staff-audit-action {
  display: inline-flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 0.2rem 0.35rem;
  max-width: 16rem;
}

.staff-audit-action__ns {
  display: inline-block;
  padding: 0.12rem 0.45rem;
  border-radius: 6px;
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.02em;
  text-transform: uppercase;
  color: var(--accent);
  background: rgba(var(--accent-rgb), 0.12);
  border: 1px solid rgba(var(--accent-rgb), 0.22);
}

.staff-audit-action__verb {
  font-family: var(--font-mono);
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--text);
  word-break: break-word;
}

.staff-audit-action__sep {
  color: var(--muted);
  font-weight: 700;
}

.staff-audit-action__mono {
  font-family: var(--font-mono);
  font-size: 0.8rem;
  font-weight: 600;
  word-break: break-word;
}

.staff-audit-entity {
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
  align-items: flex-start;
}

.staff-audit-entity__type {
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--muted);
}

.staff-audit-entity__id {
  font-family: var(--font-mono);
  font-size: 0.75rem;
  padding: 0.15rem 0.4rem;
  border-radius: 6px;
  background: rgba(0, 0, 0, 0.35);
  border: 1px solid rgba(255, 255, 255, 0.08);
  word-break: break-all;
}

.staff-audit-ip {
  font-family: var(--font-mono);
  font-size: 0.75rem;
  display: inline-block;
  max-width: 100%;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.staff-audit-details {
  max-width: 22rem;
}

.staff-audit-details summary {
  cursor: pointer;
  font-size: 0.75rem;
  font-weight: 600;
  color: var(--accent);
  list-style: none;
}

.staff-audit-details summary::-webkit-details-marker {
  display: none;
}

.staff-audit-details summary::before {
  content: "▸ ";
  display: inline-block;
  transition: transform 0.12s ease;
}

.staff-audit-details[open] summary::before {
  transform: rotate(90deg);
}

.staff-audit-details__pre {
  margin: 0.5rem 0 0;
  padding: 0.65rem 0.75rem;
  max-height: 14rem;
  overflow: auto;
  border-radius: var(--radius);
  font-family: var(--font-mono);
  font-size: 0.7rem;
  line-height: 1.45;
  color: var(--muted);
  background: rgba(0, 0, 0, 0.45);
  border: 1px solid rgba(255, 255, 255, 0.08);
  white-space: pre-wrap;
  word-break: break-word;
}

.staff-audit-pagination {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: 0.75rem 1.25rem;
  margin-top: 1.5rem;
  padding-top: 0.25rem;
}

.staff-audit-pagination__status {
  font-size: 0.875rem;
}

.staff-audit-pagination__dead {
  opacity: 0.4;
  pointer-events: none;
  cursor: default;
}

/* ——— Staff UI: tables, forms, badges (shared) ——— */
body.staff table.staff-table {
  font-size: 0.875rem;
}

body.staff table.staff-table th {
  white-space: nowrap;
  font-size: 0.7rem;
  letter-spacing: 0.08em;
}

body.staff table.staff-table td {
  vertical-align: middle;
}

body.staff table.staff-table tbody tr:hover td {
  background: rgba(var(--accent-rgb), 0.06);
}

.staff-table__col-num {
  text-align: right;
  width: 1%;
}

.staff-table__num {
  font-family: var(--font-mono);
  font-weight: 600;
  text-align: right;
  white-space: nowrap;
}

.staff-table__muted {
  color: var(--muted);
  font-size: 0.8125rem;
}

.staff-table__id {
  font-family: var(--font-mono);
  font-size: 0.8125rem;
}

.staff-table__select {
  min-width: 10.5rem;
  max-width: 14rem;
  font-size: 0.8125rem;
  padding: 0.4rem 0.55rem;
}

.staff-inline-form--table {
  flex-wrap: nowrap;
  gap: 0.5rem;
  align-items: center;
}

@media (max-width: 900px) {
  .staff-inline-form--table {
    flex-wrap: wrap;
  }
}

.staff-badge {
  display: inline-flex;
  align-items: center;
  padding: 0.2rem 0.5rem;
  border-radius: 6px;
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  border: 1px solid transparent;
  line-height: 1.2;
}

.staff-badge--success {
  color: #86efac;
  background: rgba(34, 197, 94, 0.12);
  border-color: rgba(34, 197, 94, 0.35);
}

.staff-badge--info {
  color: #7dd3fc;
  background: rgba(var(--accent-rgb), 0.12);
  border-color: rgba(var(--accent-rgb), 0.28);
}

.staff-badge--warning {
  color: #fcd34d;
  background: rgba(245, 158, 11, 0.12);
  border-color: rgba(245, 158, 11, 0.35);
}

.staff-badge--danger {
  color: #fca5a5;
  background: rgba(248, 113, 113, 0.12);
  border-color: rgba(248, 113, 113, 0.35);
}

.staff-badge--owner {
  color: #fde68a;
  background: rgba(251, 191, 36, 0.14);
  border-color: rgba(251, 191, 36, 0.4);
}

.staff-badge--accent {
  color: var(--accent);
  background: rgba(var(--accent-rgb), 0.12);
  border-color: rgba(var(--accent-rgb), 0.35);
}

.staff-badge--neutral {
  color: var(--muted);
  background: rgba(148, 163, 184, 0.08);
  border-color: rgba(148, 163, 184, 0.22);
}

.staff-table--access .staff-table__actions {
  vertical-align: middle;
  min-width: 12rem;
}

.staff-access-row-form {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.5rem;
}

.staff-access-row-form__role select {
  min-width: 10.5rem;
}

body.staff .staff-form {
  display: flex;
  flex-direction: column;
  gap: 0;
}

body.staff .staff-form > label {
  margin: 0 0 1.1rem;
}

/* Checkbox / radio: tight label + control (global input width:100% does not apply — see Forms) */
body.staff .staff-checkbox-row,
body.staff .staff-form label:has(> input[type="checkbox"]),
body.staff .staff-form label:has(> input[type="radio"]) {
  display: flex;
  flex-direction: row;
  align-items: flex-start;
  gap: 0.65rem;
  max-width: min(100%, 42rem);
  cursor: pointer;
  color: var(--text);
  font-size: 0.875rem;
  line-height: 1.45;
  font-weight: 500;
}

body.staff .staff-form > label:has(> input[type="checkbox"]),
body.staff .staff-form > label:has(> input[type="radio"]) {
  margin-bottom: 1rem;
}

body.staff .staff-checkbox-row input[type="checkbox"],
body.staff .staff-form label:has(> input[type="checkbox"]) > input,
body.staff .staff-form label:has(> input[type="radio"]) > input {
  margin-top: 0.2rem;
}

body.staff .staff-form > .staff-section-title,
body.staff .staff-form > h2.staff-section-title {
  margin: 1.5rem 0 1rem;
}

body.staff .staff-form > .staff-section-title:first-child,
body.staff .staff-form > h2.staff-section-title:first-child {
  margin-top: 0;
}

body.staff .staff-form input:not([type="checkbox"]):not([type="radio"]),
body.staff .staff-form textarea,
body.staff .staff-form select {
  max-width: none;
  width: 100%;
}

body.staff .staff-form .form-actions {
  margin-top: 0.25rem;
}

.staff-form--inline-narrow label {
  max-width: 16rem;
}

.staff-subsection-title {
  margin: 1.75rem 0 0.85rem;
  font-size: 0.95rem;
  font-weight: 700;
  letter-spacing: -0.02em;
  color: var(--text);
}

.staff-subsection-title:first-child {
  margin-top: 0;
}

/* Filter bar for list pages */
.staff-filter-bar {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  gap: 0.75rem;
  margin-bottom: 1rem;
  padding: 1rem 1.25rem;
  border-radius: var(--radius-lg);
  border: 1px solid rgba(255, 255, 255, 0.06);
  background: rgba(12, 14, 18, 0.7);
}

.staff-filter-bar label {
  display: flex;
  flex-direction: column;
  gap: 0.3rem;
  font-size: 0.75rem;
  font-weight: 600;
  color: var(--muted);
  text-transform: uppercase;
  letter-spacing: 0.06em;
}

.staff-filter-bar input,
.staff-filter-bar select {
  min-width: 8rem;
  max-width: 14rem;
  font-size: 0.8125rem;
}

.staff-filter-bar .btn {
  align-self: flex-end;
}

.staff-filter-bar__search {
  flex: 1 1 12rem;
  min-width: 8rem;
}

.staff-filter-bar__search input {
  max-width: none;
  width: 100%;
}

/* Pagination */
.staff-pagination {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  margin-top: 1.25rem;
  font-size: 0.85rem;
}

.staff-pagination__info {
  color: var(--muted);
  font-size: 0.8125rem;
}

.staff-pagination a,
.staff-pagination span.staff-pagination__current {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 2rem;
  height: 2rem;
  padding: 0 0.5rem;
  border-radius: 8px;
  border: 1px solid var(--border);
  color: var(--muted);
  font-weight: 500;
  font-size: 0.8125rem;
  text-decoration: none;
  transition: background 0.15s ease, color 0.15s ease, border-color 0.15s ease;
}

.staff-pagination a:hover {
  background: rgba(var(--accent-rgb), 0.1);
  color: var(--accent);
  border-color: rgba(var(--accent-rgb), 0.3);
}

.staff-pagination span.staff-pagination__current {
  background: rgba(var(--accent-rgb), 0.12);
  color: var(--accent);
  border-color: rgba(var(--accent-rgb), 0.35);
}

.staff-pagination__disabled {
  opacity: 0.4;
  pointer-events: none;
}

/* Bulk action bar */
.staff-bulk-bar {
  display: none;
  align-items: center;
  gap: 0.75rem;
  padding: 0.65rem 1rem;
  margin-bottom: 0.75rem;
  border-radius: var(--radius-lg);
  border: 1px solid rgba(var(--accent-rgb), 0.25);
  background: rgba(var(--accent-rgb), 0.06);
  font-size: 0.85rem;
  color: var(--text);
}

.staff-bulk-bar.is-visible {
  display: flex;
}

.staff-bulk-bar__count {
  font-weight: 600;
  color: var(--accent);
}

.staff-bulk-bar select {
  max-width: 12rem;
  font-size: 0.8125rem;
}

.staff-empty {
  text-align: center;
  padding: 3rem 1.5rem;
}

.staff-empty--compact {
  padding: 1.25rem 1rem;
  text-align: left;
}

.staff-empty__icon {
  font-size: 2.5rem;
  color: var(--muted);
  margin-bottom: 0.85rem;
  opacity: 0.7;
  opacity: 0.85;
}

.staff-empty__title {
  margin: 0 0 0.35rem;
  font-weight: 700;
  font-size: 1.05rem;
}

.staff-empty__text {
  margin: 0;
  max-width: 40ch;
  margin-left: auto;
  margin-right: auto;
  line-height: 1.55;
}

.staff-empty-inline {
  margin: 0;
}

.staff-link-back {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  font-weight: 600;
  color: var(--accent);
  text-decoration: none;
}

.staff-link-back:hover {
  text-decoration: underline;
}

.staff-back .staff-link-back {
  font-size: 0.95rem;
}

body.staff .staff-back {
  margin-top: 2rem;
}

/* Order detail + customer detail layout */
.staff-order-grid,
.staff-detail-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 1.5rem;
}

.staff-order-grid .staff-card,
.staff-detail-grid .staff-card {
  margin-bottom: 0;
}

@media (min-width: 960px) {
  .staff-order-grid,
  .staff-detail-grid {
    grid-template-columns: 1fr 1fr;
  }
}

/* Definition list for payment/customer info */
.staff-dl {
  margin: 0.5rem 0 0;
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
}

.staff-dl > div {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 1rem;
  padding: 0.35rem 0;
  border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

.staff-dl > div:last-child {
  border-bottom: none;
}

.staff-dl dt {
  font-size: 0.85rem;
  color: var(--muted);
  font-weight: 500;
}

.staff-dl dd {
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--text);
  text-align: right;
  word-break: break-all;
}

.staff-dl__total {
  border-bottom: none !important;
  padding-top: 0.5rem;
}

.staff-dl__total dt,
.staff-dl__total dd {
  font-size: 1rem;
  font-weight: 700;
}

.staff-card--danger {
  border-color: rgba(248, 113, 113, 0.2);
}

.btn-danger {
  background: rgba(248, 113, 113, 0.12);
  border: 1px solid rgba(248, 113, 113, 0.35);
  color: #fca5a5;
}

.btn-danger:hover {
  background: rgba(248, 113, 113, 0.2);
  border-color: rgba(248, 113, 113, 0.5);
  color: #fecaca;
}

/* Customer detail header */
.staff-customer-header {
  display: flex;
  align-items: center;
  gap: 1.25rem;
  margin-bottom: 1.5rem;
}

.staff-customer-header__avatar {
  width: 64px;
  height: 64px;
  border-radius: 16px;
  border: 2px solid rgba(255, 255, 255, 0.1);
}

.staff-customer-header__info {
  flex: 1;
  min-width: 0;
}

.staff-customer-header__name {
  font-size: 1.25rem;
  font-weight: 700;
  margin: 0 0 0.25rem;
}

.staff-customer-header__meta {
  font-size: 0.85rem;
  color: var(--muted);
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem 1rem;
}

.staff-customer-stats {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(120px, 1fr));
  gap: 1rem;
  margin-bottom: 1.5rem;
}

.staff-customer-stat {
  padding: 1rem;
  border-radius: var(--radius-lg);
  border: 1px solid rgba(255, 255, 255, 0.07);
  background: rgba(12, 14, 18, 0.6);
  text-align: center;
}

.staff-customer-stat__value {
  display: block;
  font-family: var(--font-mono);
  font-size: 1.35rem;
  font-weight: 700;
  color: var(--text);
}

.staff-customer-stat__label {
  display: block;
  font-size: 0.75rem;
  color: var(--muted);
  margin-top: 0.25rem;
}

body.staff .staff-page-head__lead {
  max-width: 62ch;
}

/* Minimal page for View::httpError (no store header — works before DB is available) */
body.store.http-error {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0;
  background: var(--bg);
}

.http-error__main {
  max-width: 28rem;
  padding: 2rem 1.25rem;
  text-align: center;
}

.http-error__code {
  opacity: 0.65;
  margin-bottom: 0.35rem;
}

.http-error__title {
  margin: 0 0 0.75rem;
  font-size: 1.35rem;
  letter-spacing: -0.02em;
}

.http-error__body {
  margin: 0 0 1.25rem;
  color: var(--muted);
  line-height: 1.55;
  text-align: left;
}

.http-error__body a {
  color: var(--accent);
  font-weight: 600;
  text-decoration: none;
}

.http-error__body a:hover {
  text-decoration: underline;
}

.http-error__actions {
  margin: 0;
}

.http-error__sub {
  margin: 0.75rem 0 0;
}

body.staff .staff-danger-zone__note {
  margin: 0;
  line-height: 1.5;
}

body.staff .staff-danger-zone__note--spaced {
  margin-top: 0.75rem;
}

body.staff .staff-homepage-highlight {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-start;
  gap: 0.75rem 1rem;
  margin-bottom: 1rem;
  padding: 0.75rem 1rem;
  border-radius: var(--radius-md, 10px);
  border: 1px solid rgba(255, 255, 255, 0.08);
  background: rgba(0, 0, 0, 0.2);
}

body.staff .staff-homepage-highlight__num {
  flex: 0 0 auto;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 1.75rem;
  height: 1.75rem;
  margin-top: 0.15rem;
  border-radius: 999px;
  font-size: 0.8rem;
  font-weight: 700;
  background: rgba(var(--accent-rgb), 0.2);
  color: var(--accent);
}

body.staff .staff-homepage-highlight__fields {
  flex: 1 1 16rem;
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  min-width: 0;
}

body.staff .staff-homepage-highlight__fields label {
  margin: 0;
}
