/* ═══════════════════════════════════════════════════════════════════════════
   Nexys Chrome: shared design system
   Tokens live in layouts/master.njk (<style id="theme-styles">). This file
   holds what every component shares: type, icons, section headers, the
   chrome material helpers and the base controls.
   ═══════════════════════════════════════════════════════════════════════════ */

body {
  font-size: 1rem;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
}
h1, h2, h3, h4, h5, h6 { color: var(--text); letter-spacing: -0.01em; }
a { text-underline-offset: 3px; }
img { max-width: 100%; }

/* Icons (snippets/nx-icons.njk) */
.nx-i {
  width: 20px;
  height: 20px;
  flex: none;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.75;
  stroke-linecap: round;
  stroke-linejoin: round;
  vertical-align: -0.2em;
}
.nx-i .nx-a, .nx-a { stroke: var(--accent); }
.nx-i--mono .nx-a { stroke: currentColor; }
.nx-i--sm { width: 16px; height: 16px; }
.nx-i--lg { width: 24px; height: 24px; }
.nx-i--xl { width: 32px; height: 32px; stroke-width: 1.5; }

/* Chrome material helpers */
.nx-chrome-text {
  background: var(--chrome);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  color: var(--text);
}
.nx-metal {
  border: 1px solid transparent;
  background: linear-gradient(var(--surface), var(--surface)) padding-box, var(--chrome-border) border-box;
}
.nx-chrome-tag {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 2px 8px;
  border-radius: var(--r-xs);
  background: var(--chrome-fill);
  color: var(--chrome-ink);
  font-size: 0.75rem;
  font-weight: 600;
  line-height: 1.5;
  white-space: nowrap;
}

/* Primary action sheen: one light reflection crosses the button on hover.
   User-triggered, runs once, transform only. Any primary button can opt in
   by matching this list. */
.pc-btn-primary,
.hero-buttons .btn-primary,
.nx-sheen {
  position: relative;
  overflow: hidden;
  isolation: isolate;
}
.pc-btn-primary::after,
.hero-buttons .btn-primary::after,
.nx-sheen::after {
  content: '';
  position: absolute;
  top: 0;
  bottom: 0;
  left: 0;
  z-index: 1;
  width: 40%;
  background: linear-gradient(100deg, transparent, rgba(255, 255, 255, 0.5), transparent);
  transform: translateX(-140%) skewX(-18deg);
  pointer-events: none;
}
@media (hover: hover) and (prefers-reduced-motion: no-preference) {
  .pc-btn-primary:hover::after,
  .hero-buttons .btn-primary:hover::after,
  .nx-sheen:hover::after {
    transform: translateX(380%) skewX(-18deg);
    transition: transform 520ms var(--ease);
  }
}

/* Section headers: one size ramp for the whole store. The heading takes the
   chrome ramp; the line under it is plain muted copy. */
.section-title,
.section-subtitle,
.component .section-title,
.component .section-subtitle {
  display: block;
  width: 100%;
  margin: 0;
  text-align: center;
}

.section-title h1,
.section-title h2,
.section-title h3,
.section-title h4 {
  margin-bottom: 8px;
  font-size: 1.75rem;
  font-weight: 600;
  line-height: 1.15;
  letter-spacing: -0.02em;
  text-align: center;
  text-wrap: balance;
  background: var(--chrome);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  color: var(--text);
}

.section-subtitle p {
  max-width: 60ch;
  margin: 0 auto 32px;
  color: var(--muted);
  font-size: 1rem;
  font-weight: 400;
  line-height: 1.6;
  text-align: center;
}

@media (min-width: 768px) {
  .section-title h1, .section-title h2, .section-title h3, .section-title h4 { font-size: 2rem; }
}
@media (min-width: 1200px) {
  .section-title h1, .section-title h2, .section-title h3, .section-title h4 { font-size: 2.25rem; }
  .section-subtitle p { margin-bottom: 40px; }
}

}

/* ==========================================================================
   Animated background (ported from fade_web)
   ========================================================================== */

/* Dot trail that follows the cursor */
.dot-background {
  position: fixed;
  inset: 0;
  z-index: -3;
  pointer-events: none;
  background-image: none;
  background-size: 20px 20px;
  opacity: 0;
  mask-image: radial-gradient(150px circle at var(--x, 50%) var(--y, 50%), black 0%, transparent 100%);
  -webkit-mask-image: radial-gradient(150px circle at var(--x, 50%) var(--y, 50%), black 0%, transparent 100%);
  transition: opacity 0.3s ease;
}

/* ==========================================================================
   Customer login modal
   Lives here because the markup is inlined in master.njk — the snippet
   (and its <style> block) was not rendering.
   ========================================================================== */

#customer-login-modal .modal-content {
  background: var(--base);
  border: 1px solid var(--border);
  border-radius: var(--r-md);
  color: var(--text);
}

#customer-login-modal .modal-header {
  border-bottom: 1px solid var(--border);
  padding: 1.25rem 1.5rem;
  align-items: center;
}

#customer-login-modal .modal-title {
  font-size: 1.25rem;
  font-weight: 600;
  color: var(--text);
  -webkit-text-fill-color: currentColor;
}

#customer-login-modal .btn-close {
  filter: invert(1);
  opacity: 0.4;
  transition: opacity 0.15s ease;
}

#customer-login-modal .btn-close:hover {
  opacity: 0.8;
}

#customer-login-modal .modal-body {
  padding: 1.5rem;
}

#customer-login-modal .form-label {
  font-size: 0.8125rem;
  font-weight: 600;
  color: var(--text);
  margin-bottom: 0;
}

#customer-login-modal .form-text {
  font-size: 0.75rem;
  color: var(--muted);
  margin-top: 0.25rem;
}

#customer-login-modal .form-text.text-danger {
  color: var(--danger) !important;
}

#customer-login-modal .form-control {
  background: var(--raised);
  border: 1px solid var(--border);
  border-radius: var(--r-sm);
  color: var(--text);
  font-size: 0.875rem;
  padding: 0.5rem 0.75rem;
  transition: color 0.3s ease, background-color 0.3s ease, border-color 0.3s ease, opacity 0.3s ease, transform 0.3s ease;
}

#customer-login-modal .form-control:focus {
  background: var(--raised);
  border-color: var(--accent);
  box-shadow: 0 0 0 3px var(--ring);
  color: var(--text);
  outline: none;
}

#customer-login-modal .form-control::placeholder {
  color: var(--muted);
}

#customer-login-modal .modal-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  width: 100%;
  padding: 0.5rem 1.25rem;
  border-radius: var(--r-sm);
  background: var(--accent);
  border: 2px solid var(--border-strong);
  color: var(--accent-ink);
  font-size: 0.875rem;
  font-weight: 600;
  cursor: pointer;
  transition: color 0.3s ease, background-color 0.3s ease, border-color 0.3s ease, opacity 0.3s ease, transform 0.3s ease;
  margin-top: 1.25rem;
}

#customer-login-modal .modal-btn:hover:not(:disabled) {
  background: var(--accent);
  box-shadow: var(--shadow-float);
  color: var(--accent-ink);
}

#customer-login-modal .modal-btn:disabled {
  opacity: 0.45;
  cursor: not-allowed;
}

#customer-login-modal .otp-grid {
  display: flex;
  gap: 0.375rem;
  margin-top: 0.75rem;
}

#customer-login-modal .otp-input {
  flex: 1;
  min-width: 0;
  height: 2.75rem;
  text-align: center;
  font-size: 1.125rem;
  font-weight: 600;
  padding: 0;
  -moz-appearance: textfield;
}

#customer-login-modal .otp-input:not(:placeholder-shown) {
  border-color: var(--border-strong);
}

#customer-login-modal .modal-step-label {
  font-size: 0.75rem;
  font-weight: 600;
  color: var(--text);
  opacity: 0.8;
  margin-bottom: 0.375rem;
}

@media (max-width: 400px) {
  #customer-login-modal .modal-body {
    padding: 1rem 1rem;
  }

  #customer-login-modal .otp-grid {
    gap: 0.25rem;
  }

  #customer-login-modal .otp-input {
    height: 2.4rem;
    font-size: 1rem;
  }
}

#customer-login-modal .modal-alt-link {
  display: block;
  margin: 0.5rem auto 0;
  background: none;
  border: none;
  padding: 0;
  font-size: 0.8125rem;
  color: var(--muted);
  cursor: pointer;
  text-decoration: underline;
  text-underline-offset: 2px;
  transition: color 0.2s;
}

#customer-login-modal .modal-alt-link:hover {
  color: var(--text);
}

#customer-login-modal .modal-resend-row {
  margin-top: 0.75rem;
  text-align: center;
  font-size: 0.8125rem;
  color: var(--muted);
}

#customer-login-modal .modal-resend-btn {
  background: none;
  border: none;
  padding: 0;
  font-size: inherit;
  font-weight: 600;
  color: var(--text);
  cursor: pointer;
  text-decoration: underline;
  text-underline-offset: 2px;
  opacity: 1;
  transition: opacity 0.2s;
}

#customer-login-modal .modal-resend-btn:disabled {
  opacity: 0.45;
  pointer-events: none;
}

@keyframes otp-shake {
  0%, 100% { transform: translateX(0); }
  20% { transform: translateX(-6px); }
  40% { transform: translateX(6px); }
  60% { transform: translateX(-4px); }
  80% { transform: translateX(4px); }
}

#customer-login-modal .otp-shake {
  animation: otp-shake 0.45s ease;
}

/* Diagonal line texture */
body::before {
  content: "";
  position: fixed;
  inset: 0;
  z-index: -4;
  background-image: none;
  pointer-events: none;
}
/* ==========================================================================
   Light mode corrections
   The token sweep (rgba(var(--cl-snow)) / rgba(var(--cl-surface))) flips most
   surfaces automatically. These are the spots that were hardcoded to a dark
   look and need an explicit light treatment.
   ========================================================================== */

[data-bs-theme="light"] {
  color-scheme: light;
}

/* Hero — the dark radial reads wrong on a light page. */
[data-bs-theme="light"] .hero-section {
  background: var(--base) !important;
}

/* Clipped-gradient headings: keep them legible (dark ink -> muted) on light. */
[data-bs-theme="light"] .hero-content h1,
[data-bs-theme="light"] .section-title h2,
[data-bs-theme="light"] #customer-login-modal .modal-title {
  background: var(--chrome);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  color: var(--text);
}

/* Diagonal texture — keep it visible on light too, just a touch softer than
   the dark treatment. */
[data-bs-theme="light"] body::before {
  background-image: none;
}

/* Cursor-dot background: dial the accent dots back on a light ground. */
[data-bs-theme="light"] .dot-background { opacity: 0.35 !important; }

/* Big black drop shadows -> soft slate shadows. */
[data-bs-theme="light"] .main-header.is-scrolled { box-shadow: none; }
[data-bs-theme="light"] .nav-mega-panel,
[data-bs-theme="light"] .nav-search-panel,
[data-bs-theme="light"] .nav-lang-menu,
[data-bs-theme="light"] .cart-drawer-panel { box-shadow: var(--shadow-float); }

/* Keep primary buttons readable regardless of accent lightness. */
[data-bs-theme="light"] .btn-primary { --bs-btn-color: var(--base); --bs-btn-hover-color: var(--base); --bs-btn-active-color: var(--base); }

/* Bootstrap form controls on light. */
[data-bs-theme="light"] .form-control,
[data-bs-theme="light"] .form-select {
  background-color: var(--surface);
  border-color: var(--border);
  color: var(--text);
}

/* Choices.js currency dropdown on light. */
[data-bs-theme="light"] .choices__list--dropdown,
[data-bs-theme="light"] .choices__list[aria-expanded] {
  background: var(--surface);
  border-color: var(--border);
  color: var(--text);
}


/* ───────────────────────────────────────────────────────────────────────────
   Glass 3D button (.btn-glass) — secondary buttons.
   - Fake-3D body: soft top highlight, darker bottom lip, accent-tinted outline.
   - Hover: a faint light blooms from the top edge.
   - Pressed: the light gets stronger, the body lightens and the lip flattens.
   Everything is on the button itself / its ::before, so labels never move.
   The `html .btn-glass.btn-glass` prefix out-ranks component-local button CSS.
   ─────────────────────────────────────────────────────────────────────────── */
html .btn-glass.btn-glass {
  --glass-lip: var(--base);
  --glass-hi: var(--border-strong);
  position: relative;
  isolation: isolate;
  overflow: hidden;
  color: var(--text);
  background-color: transparent;
  background-image: none;
  border: 1px solid var(--border-strong);
  box-shadow:
    var(--edge);
  transition: border-color 0.25s ease, box-shadow 0.25s ease, color 0.25s ease, background-image 0.25s ease;
}
html[data-bs-theme="light"] .btn-glass.btn-glass {
  --glass-lip: var(--border-strong);
  --glass-hi: var(--base);
  border-color: var(--border-strong);
}

/* The light that blooms from the top edge */
html .btn-glass.btn-glass::before,
html .btn-glass.btn-glass:hover:not(:disabled)::before,
html .btn-glass.btn-glass:active:not(:disabled)::before {
  content: '';
  position: absolute;
  inset: 0;
  z-index: -1;
  box-sizing: border-box;
  border: 0;
  border-radius: inherit;
  transform: none;
  background:
    none;
  pointer-events: none;
}
html .btn-glass.btn-glass::before { opacity: 0; transition: opacity 0.3s ease; }
html .btn-glass.btn-glass:hover:not(:disabled)::before { opacity: 0.55; }
html .btn-glass.btn-glass:active:not(:disabled)::before { opacity: 1; }

html .btn-glass.btn-glass:hover:not(:disabled) {
  color: var(--text);
  border-color: var(--border-strong);
}
html .btn-glass.btn-glass:active:not(:disabled) {
  color: var(--text);
  border-color: var(--accent);
  background-image: none;
  box-shadow:
    var(--edge), 0 0 0 3px var(--border);
}
html .btn-glass.btn-glass:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; }
html .btn-glass.btn-glass:disabled { opacity: 0.5; cursor: not-allowed; }

@media (prefers-reduced-motion: reduce) {
  html .btn-glass.btn-glass, html .btn-glass.btn-glass::before { transition: none; }
}


/* ───────────── Scroll reveal ─────────────
   One shared reveal for the landing page: sections (and the blocks / cards inside them)
   fade up, with a touch of blur, as they scroll into view. A script in the layout adds
   .rv-on to <html> and .rv to the pieces, so with JS off nothing is ever hidden. */
:root { --rv-dist: 28px; --rv-ease: cubic-bezier(0.22, 1, 0.36, 1); }
html.rv-on .rv {
  opacity: 0;
  transform: translateY(var(--rv-dist));
  filter: blur(6px);
  transition: opacity 0.8s var(--rv-ease), transform 0.9s var(--rv-ease), filter 0.8s var(--rv-ease);
  transition-delay: var(--rv-delay, 0ms);
}
html.rv-on .rv.rv-in { opacity: 1; transform: none; filter: none; }
@media (prefers-reduced-motion: reduce) {
  html.rv-on .rv, html.rv-on .rv.rv-in { opacity: 1; transform: none; filter: none; transition: none; }
}

/* ==========================================================================
   Customer area — minimal. Flat surfaces, hairline borders, one accent.
   Scoped to .customer-area; uses theme variables (dark + light).
   ========================================================================== */

.customer-area { --cx-line: var(--border); --cx-muted: var(--muted); }

/* cards */
.customer-area .card {
  background: var(--surface);
  border: 1px solid var(--cx-line);
  border-radius: var(--r-md);
  box-shadow: none;
  transition: border-color .2s ease;
}
.customer-area a.card { text-decoration: none; color: inherit; }
.customer-area a.card:hover { border-color: var(--border-strong); }
.customer-area .card h3 { font-size: 1rem; font-weight: 600; }
.customer-area .card h4.text-lg, .customer-area .card h5 { font-size: 1rem; font-weight: 600; }
.customer-area .card .small, .customer-area .card small, .customer-area .text-muted { color: var(--cx-muted) !important; }

/* top tabs */
.cx-sidebar { padding: 0 !important; background: transparent !important; border: 0 !important; border-radius: 0 !important; box-shadow: none !important; margin-bottom: .5rem; }
.cx-user { display: none; }
.cx-sidebar .nav {
  flex-direction: row !important; flex-wrap: nowrap; gap: .25rem !important; overflow-x: auto; scrollbar-width: none;
  border-bottom: 1px solid var(--cx-line);
}
.cx-sidebar .nav::-webkit-scrollbar { display: none; }
.cx-sidebar .nav-item { flex: 0 0 auto; }
.cx-sidebar .nav-link {
  display: inline-flex; align-items: center; gap: .5rem; white-space: nowrap; border: 0; border-radius: 0; background: transparent;
  padding: .75rem 1rem; margin-bottom: -1px; font-size: 0.875rem; font-weight: 600; color: var(--cx-muted);
  border-bottom: 2px solid transparent; transition: color .2s ease, border-color .2s ease;
}
.cx-sidebar .nav-link i { font-size: 0.8125rem; opacity: .8; }
.cx-sidebar .nav-link:hover { color: var(--text); }
.cx-sidebar .nav-link.active { color: var(--text); background: transparent; border-bottom-color: var(--accent); }
.cx-sidebar .nav-link.active i { color: var(--accent); opacity: 1; }
.cx-sidebar .cx-logout { margin-left: auto; }
.cx-sidebar .cx-logout .nav-link:hover { color: var(--danger); }

/* headers */
.cx-header { margin: 1.5rem 0 1.25rem; }
.cx-header h1 { font-size: 1.5rem; font-weight: 600; letter-spacing: -.02em; margin: 0 0 0.25rem; color: var(--text); }
.cx-header p { margin: 0; color: var(--cx-muted); font-size: 0.875rem; }

/* stat tiles */
.cx-stat { display: block; height: 100%; }
.cx-stat-icon { display: none; }
.cx-stat-label { display: block; font-size: 0.75rem; font-weight: 600; color: var(--cx-muted); margin-bottom: 0.375rem; }
.cx-stat-value { display: block; font-size: 1.5rem; font-weight: 600; line-height: 1.2; }
.cx-stat-sub { display: block; margin-top: .25rem; font-size: 0.8125rem; color: var(--cx-muted); }
.cx-stat-sub a { color: var(--accent); text-decoration: none; }
.cx-stat-sub a:hover { text-decoration: underline; }

/* status pills */
.cx-pill {
  display: inline-block; padding: 0.125rem 0.5rem; border-radius: var(--r-sm); font-size: 0.75rem; font-weight: 600; text-transform: capitalize; white-space: nowrap;
  color: var(--cx-muted); background: var(--raised);
}
.cx-pill--completed, .cx-pill--closed { color: var(--success); background: var(--success-soft); }
.cx-pill--pending, .cx-pill--confirming, .cx-pill--partial { color: var(--warning); background: var(--warning-soft); }
.cx-pill--open { color: var(--text); background: var(--raised); }
.cx-pill--cancelled, .cx-pill--refunded, .cx-pill--voided, .cx-pill--failed { color: var(--danger); background: var(--danger-soft); }

/* tables */
.customer-area .table { --bs-table-bg: transparent; --bs-table-color: inherit; --bs-table-border-color: var(--cx-line); margin: 0; }
.customer-area .table thead th { font-size: 0.75rem; font-weight: 600; color: var(--cx-muted); border-bottom: 1px solid var(--cx-line); padding: 0.75rem 1rem; white-space: nowrap; }
.customer-area .table tbody td { padding: 0.75rem 1rem; vertical-align: middle; border-color: var(--cx-line); }
.customer-area .table tbody tr:last-child td { border-bottom: 0; }
.customer-area .table a { text-decoration: none; }
.customer-area .table a:hover { text-decoration: underline; }
.customer-area .table .btn-link { font-size: 0.8125rem; padding: .25rem 0.5rem; border: 1px solid var(--cx-line); border-radius: var(--r-sm); color: var(--text); text-decoration: none; }
.customer-area .table .btn-link:hover { border-color: var(--border-strong); color: var(--accent); text-decoration: none; }

/* empty state */
.cx-empty { text-align: center; padding: 2rem 1rem; color: var(--cx-muted); font-size: 0.875rem; }
.cx-empty i { display: block; font-size: 1.5rem; margin-bottom: 0.5rem; opacity: .45; }

/* buttons */
.customer-area .btn { border-radius: var(--r-sm); font-weight: 600; font-size: .875rem; padding: .5rem 1rem; box-shadow: none; transition: background .2s ease, border-color .2s ease, color .2s ease; }
.customer-area .btn-sm { padding: 0.375rem .75rem; font-size: 0.8125rem; }
.customer-area .btn-primary { background: var(--accent); border: 1px solid var(--accent); color: var(--accent-ink); }
.customer-area .btn-primary:hover { filter: brightness(1.1); color: var(--text); }
.customer-area .btn-outline-primary, .customer-area .btn-primary-outline { background: transparent; border: 1px solid var(--cx-line); color: var(--text); }
.customer-area .btn-outline-primary:hover, .customer-area .btn-primary-outline:hover { border-color: var(--accent); color: var(--accent); background: transparent; }
.customer-area .btn-outline-danger { background: transparent; border: 1px solid var(--danger-line); color: var(--danger); }
.customer-area .btn-outline-danger:hover { background: var(--danger); border-color: var(--danger); color: var(--base); }

/* forms */
.customer-area .form-control, .customer-area .form-select, .customer-area .input {
  background: var(--surface); border: 1px solid var(--cx-line); border-radius: var(--r-sm); color: inherit;
}
.customer-area .form-control:focus, .customer-area .form-select:focus, .customer-area .input:focus { border-color: var(--accent); box-shadow: none; outline: 0; background: var(--surface); color: inherit; }
.customer-area .alert { border: 1px solid var(--cx-line); border-radius: var(--r-sm); background: var(--surface); color: inherit; }

/* danger zone */
.cx-danger { display: flex; flex-direction: row; align-items: center; justify-content: space-between; gap: 1rem; flex-wrap: wrap; }
.cx-danger h5 { margin: 0 0 .1rem; font-size: 1rem; }
.cx-danger p { margin: 0; font-size: 0.8125rem; color: var(--cx-muted); }

/* ---- dashboard overview ---- */
.cx-header--row { display: flex; align-items: center; justify-content: space-between; gap: 1rem; flex-wrap: wrap; }
.cx-strip { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); padding: 0; overflow: hidden; }
.cx-strip-item { display: block; padding: 1rem 1.25rem; border-left: 1px solid var(--cx-line); text-decoration: none; color: inherit; margin-left: -1px; }
a.cx-strip-item:hover { background: var(--surface); }
.cx-strip .cx-stat-value { font-size: 1.25rem; }
.cx-stat-label em { font-style: normal; color: var(--text); margin-left: 0.375rem; }
.cx-panel { padding: 1rem 1.25rem; }
.cx-panel-head { display: flex; align-items: center; justify-content: space-between; gap: 1rem; margin-bottom: 0.5rem; }
.cx-panel-head h2 { font-size: 1rem; font-weight: 600; margin: 0; color: var(--text); }
.cx-panel-head a { font-size: 0.8125rem; color: var(--cx-muted); text-decoration: none; }
.cx-panel-head a:hover { color: var(--accent); }
.cx-list { list-style: none; margin: 0; padding: 0; }
.cx-list li + li { border-top: 1px solid var(--cx-line); }
.cx-row { display: flex; align-items: center; gap: 0.75rem; padding: 0.75rem 0; text-decoration: none; color: inherit; }
.cx-list li:last-child .cx-row { padding-bottom: 0.125rem; }
.cx-row-main { flex: 1 1 auto; min-width: 0; display: flex; flex-direction: column; gap: .1rem; }
.cx-row-main strong { font-size: 0.875rem; font-weight: 600; color: var(--text); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.cx-row-main small { font-size: 0.75rem; color: var(--cx-muted); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.cx-row:hover strong { color: var(--accent); }
.cx-chev { color: var(--cx-muted); flex: 0 0 auto; transition: transform .2s ease, color .2s ease; }
.cx-row:hover .cx-chev, .cx-linkcard:hover .cx-chev { color: var(--accent); transform: translateX(3px); }
.cx-thumb { width: 38px; height: 38px; border-radius: var(--r-sm); object-fit: cover; flex: 0 0 auto; background: var(--raised); }
.cx-note { font-size: 0.8125rem; color: var(--cx-muted); margin: 0 0 .75rem; }
.cx-code {
  display: flex; align-items: center; justify-content: space-between; gap: .75rem; width: 100%;
  padding: 0.5rem 0.75rem; border-radius: var(--r-sm); border: 1px dashed var(--border-strong); background: var(--surface);
  color: var(--text); font-size: 0.875rem; font-weight: 600; text-align: left; transition: border-color .2s ease;
}
.cx-code span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; min-width: 0; }
.cx-code em { font-style: normal; font-size: .75rem; color: var(--text); flex: 0 0 auto; }
.cx-code:hover { border-color: var(--border-strong); }
.cx-promo .cx-code span { font-weight: 600; }
.cx-panel .cx-empty { padding: 1.25rem 0 .5rem; text-align: left; }
.cx-panel .cx-empty a { color: var(--accent); text-decoration: none; }
.cx-foot { margin: 1.5rem 0 0; text-align: center; }
.cx-foot button { background: none; border: 0; padding: 0; font-size: 0.75rem; color: var(--cx-muted); }
.cx-foot button:hover { color: var(--danger); text-decoration: underline; }
@media (max-width: 575.98px) {
  .cx-strip { grid-template-columns: 1fr 1fr; }
  .cx-strip-item { border-top: 1px solid var(--cx-line); margin-top: -1px; }
}

/* ---- reseller: enterprise plan ---- */
.cx-enterprise { border-color: var(--border-strong) !important; }
.cx-enterprise-body { display: flex; align-items: center; justify-content: space-between; gap: 1.5rem; flex-wrap: wrap; }
.cx-enterprise h2 { font-size: 1rem; font-weight: 600; margin: 0.5rem 0 0.25rem; color: var(--text); }
.cx-enterprise-actions { display: flex; align-items: center; gap: 1rem; flex-wrap: wrap; }
.cx-enterprise-actions a { font-size: 0.8125rem; color: var(--cx-muted); text-decoration: none; }
.cx-enterprise-actions a:hover { color: var(--accent); }

/* ── Product card ─────────────────────────────────────────────────────────────
   Shared by every product grid (home, category, bundles, related).
   Hierarchy: artwork, name, price, then the two purchase actions.
   Chrome: a metal hairline edge; on hover the edge brightens and a short
   ice-blue reflection runs along the top. Nothing moves or resizes. */
.product-card-reveal,
.product-card-reveal.is-revealed {
  opacity: 1;
  transform: none;
}

.product-card {
  position: relative;
  display: flex !important;
  flex-direction: column;
  width: 100%;
  padding: 0;
  text-align: left;
  border: 1px solid transparent;
  border-radius: var(--r-md);
  overflow: hidden;
  background: linear-gradient(var(--surface), var(--surface)) padding-box, var(--chrome-border) border-box;
  cursor: pointer;
}

.product-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 20%;
  right: 20%;
  z-index: 3;
  height: 1px;
  background: var(--specular);
  opacity: 0;
  transition: opacity var(--t-fast) var(--ease);
  pointer-events: none;
}

@media (hover: hover) {
  .product-card:hover { background: linear-gradient(var(--raised), var(--raised)) padding-box, var(--chrome-border) border-box; }
  .product-card:hover::before { opacity: 1; }
}
.product-card:focus-within::before { opacity: 1; }

/* Highlighted card (product "Custom data": badge / sale / color). The card keeps an
   accent hairline; the badge is a solid accent pill in the image's top-right corner,
   away from the brand logo that sits top-left on every product image. Solid fill +
   a soft shadow so it reads on any image, light or dark. */
.product-card.pc-hl {
  border-color: var(--accent);
  background: var(--surface);
  /* a low, soft glow in the accent around highlighted cards (SALE, MOST POPULAR…) */
  box-shadow: 0 0 0 1px color-mix(in srgb, var(--accent) 22%, transparent), 0 10px 36px -14px color-mix(in srgb, var(--accent) 55%, transparent);
}
[data-bs-theme="light"] .product-card.pc-hl { box-shadow: 0 10px 30px -16px color-mix(in srgb, var(--accent) 60%, transparent); }
.product-card.pc-hl::after { content: none; }

.pc-ribbon,
.pc-ribbon[data-len="r2"] {
  position: absolute;
  top: 12px;
  right: 12px;
  left: auto;
  z-index: 4;
  width: auto;
  height: auto;
  overflow: visible;
  pointer-events: none;
}
.pc-ribbon > span,
.pc-ribbon[data-len="r2"] > span,
html[data-bs-theme="light"] .pc-ribbon > span {
  position: static;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  width: auto;
  padding: 6px 11px;
  transform: none;
  border-radius: var(--r-pill);
  background: var(--accent);
  color: var(--accent-ink);
  box-shadow: var(--edge-accent), 0 4px 14px rgba(0, 0, 0, 0.45), 0 0 0 1px rgba(0, 0, 0, 0.25);
  font-size: 0.75rem;
  font-weight: 600;
  line-height: 1;
  letter-spacing: 0.04em;
  text-align: left;
  white-space: nowrap;
}
.pc-ribbon > span::before {
  content: '';
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: currentColor;
  opacity: 0.55;
}
.pc-ribbon > span br { display: none; }

/* Black Friday pick (metadata "bf", only while the seasonal theme is Black Friday):
   a black tag with a small accent dot, a plain accent hairline, no glow. */
.product-card.pc-bf { border-color: color-mix(in srgb, var(--accent) 55%, var(--border)); box-shadow: none; }
.product-card.pc-bf .pc-ribbon > span {
  background: var(--bf-tag, #0b0b0b);
  color: var(--bf-tag-ink, #ffffff);
  box-shadow: 0 0 0 1px rgba(255, 255, 255, 0.14), 0 4px 14px rgba(0, 0, 0, 0.45);
  letter-spacing: 0.08em;
}
.product-card.pc-bf .pc-ribbon > span::before { background: var(--bf-dot, #ffd23f); opacity: 1; }
.pc-off {
  display: inline-flex; align-items: center;
  margin-left: 6px; padding: 2px 6px;
  border-radius: var(--r-xs);
  background: var(--accent-soft);
  color: var(--accent);
  font-size: 0.6875rem; font-weight: 600; line-height: 1.3;
  font-variant-numeric: tabular-nums;
}

.product-card-link {
  display: flex !important;
  flex-direction: column;
  flex: 1 1 auto;
  color: inherit;
}

.product-image-wrapper {
  position: relative;
  aspect-ratio: var(--product-card-image-aspect-ratio, 16 / 9);
  background-color: var(--raised);
  border-bottom: 1px solid var(--border);
}
.product-image-wrapper::after { content: none; }

.product-image {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: var(--product-image-fit, cover);
  object-position: center;
}

.product-image-secondary {
  position: absolute;
  top: 0;
  left: 0;
  opacity: 0;
  /* Leaving is a calm fade back to the first image. */
  transition: opacity 350ms ease;
}
@media (hover: hover) {
  /* Entering waits a beat so a mouse passing over the card does not flicker the art, then fades slowly. */
  .product-card:hover .product-image-secondary { opacity: 1; transition: opacity 450ms ease 80ms; }
}

.product-img-placeholder {
  width: 100%;
  height: 100%;
  background-color: var(--raised);
  color: var(--muted);
}

.product-info {
  display: flex;
  flex-direction: column;
  flex: 1 1 auto;
  gap: 12px;
  padding: 16px 16px 12px;
  text-align: left;
}

.product-info-top {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 12px;
}

.product-title {
  flex: 1;
  min-width: 0;
  margin-bottom: 0;
  color: var(--text);
  font-size: 1rem;
  font-weight: 600;
  line-height: 1.4;
  text-align: left;
  overflow-wrap: anywhere;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.product-divider { display: none; }

.product-stock {
  flex-shrink: 0;
  padding-top: 3px;
  font-size: 0.75rem;
  font-weight: 400;
  line-height: 1.4;
  white-space: nowrap;
  font-variant-numeric: tabular-nums;
}
.product-stock.stock-in { color: var(--success); }
.product-stock.stock-low { color: var(--warning); }
.product-stock.stock-out { color: var(--danger); }
.product-stock.product-group-count,
.product-stock:not(.stock-in):not(.stock-low):not(.stock-out):not(.product-group-count) { color: var(--muted); }

.stock-unlimited {
  display: inline-flex;
  align-items: center;
}

.product-meta {
  margin-top: auto;
  font-size: 0.875rem;
}

/* "View" hint over the artwork: desktop only, appears with the hover state. */
.pc-view {
  position: absolute;
  right: 12px;
  bottom: 12px;
  z-index: 2;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 12px;
  border-radius: var(--r-sm);
  border: 1px solid var(--border-strong);
  background: var(--surface);
  color: var(--text);
  font-size: 0.75rem;
  font-weight: 600;
  white-space: nowrap;
  pointer-events: none;
  opacity: 0;
  transition: opacity var(--t-fast) var(--ease);
}
.pc-view svg { width: 12px; height: 12px; }
@media (hover: hover) {
  .product-card:hover .pc-view { opacity: 1; }
}

/* Price: the loudest thing on the card after the artwork. */
.price-row {
  display: flex;
  align-items: baseline;
  gap: 8px;
  flex-wrap: wrap;
}

.price-label {
  color: var(--muted);
  font-size: 0.75rem;
  font-weight: 400;
  white-space: nowrap;
}

.product-price-box {
  display: inline-flex;
  padding: 0;
  border: 0;
  background: none;
}

.current-price {
  color: var(--accent);
  font-size: 1.25rem;
  font-weight: 600;
  line-height: 1.2;
  white-space: nowrap;
  font-variant-numeric: tabular-nums;
}

.old-price {
  color: var(--muted);
  font-size: 0.8125rem;
  white-space: nowrap;
  font-variant-numeric: tabular-nums;
}

/* Purchase actions: both always labelled, Buy now is the accent. */
.product-actions {
  display: flex;
  gap: 8px;
  padding: 0 16px 16px;
}

.pc-btn {
  position: relative;
  flex: 1 1 0;
  min-width: 0;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  height: 44px;
  padding: 0 12px;
  border: 1px solid transparent;
  border-radius: var(--r-sm);
  font-size: 0.875rem;
  font-weight: 600;
  line-height: 1;
  white-space: nowrap;
  text-decoration: none !important;
  cursor: pointer;
  transition: background-color var(--t-fast) var(--ease), border-color var(--t-fast) var(--ease), transform var(--t-fast) var(--ease);
}
.pc-btn::before { content: none; }
.pc-btn:active:not(:disabled) { transform: scale(0.98); }
.pc-btn svg { width: 16px; height: 16px; flex-shrink: 0; }
.pc-btn-full { flex-basis: 100%; }

.pc-label {
  display: inline-block;
  max-width: none;
  margin-left: 0;
  opacity: 1;
  overflow: hidden;
  text-overflow: ellipsis;
}
.pc-buy.is-loading { opacity: 0.75; cursor: progress; }

.pc-btn-primary {
  background: var(--accent);
  color: var(--accent-ink);
  box-shadow: var(--edge-accent);
}
.pc-btn-primary:hover:not(:disabled) { background: var(--accent-hover); color: var(--accent-ink); }

.pc-btn-ghost {
  background: var(--raised);
  border-color: var(--border-strong);
  color: var(--text);
  box-shadow: var(--edge);
}
.pc-btn-ghost:hover:not(:disabled) { background: var(--border); color: var(--text); }

.pc-btn:disabled {
  background: var(--surface);
  border-color: var(--border);
  color: var(--muted);
  box-shadow: none;
  cursor: not-allowed;
}

@media (max-width: 400px) {
  .product-actions { flex-wrap: wrap; }
  .pc-btn { flex-basis: 100%; }
}

@media (prefers-reduced-motion: reduce) {
  .pc-btn, .product-card::before, .pc-view, .product-image-secondary { transition: none !important; }
  .pc-btn:active { transform: none !important; }
}

/* ── Page top spacing ─────────────────────────────────────────────────────────
   The navbar floats over the page, so every page's first section starts below it
   (its real height is published as --nav-h) plus a little breathing room. The
   announcement bar already reserves its own space in the flow. */
html body .py-5-nav,
html body .feedback-section,
html body .terms-section,
html body .privacy-section,
html body .refund-section,
html body .cart-section,
html body .pp-section,
html body .pl-page,
html body .ct-page {
  padding-top: calc(var(--nav-h, 80px) + 2.5rem);
}
@media (max-width: 768px) {
  html body .py-5-nav,
  html body .feedback-section,
  html body .terms-section,
  html body .privacy-section,
  html body .refund-section,
  html body .cart-section,
  html body .pp-section,
  html body .pl-page,
  html body .ct-page {
    padding-top: calc(var(--nav-h, 72px) + 1.5rem);
  }
}


/* ── 2026-11-15: sign-in window, two columns ──
   Left: what the account gives you (desktop only). Right: the unchanged login steps. */
#customer-login-modal .lm-dialog { max-width: 860px; }
#customer-login-modal .lm-content { display: grid; grid-template-columns: 1fr; overflow: hidden; }
#customer-login-modal .lm-aside { display: none; }
#customer-login-modal .lm-main { min-width: 0; }
#customer-login-modal .modal-title { font-size: 1.375rem; }
@media (min-width: 768px) {
  #customer-login-modal .lm-content { grid-template-columns: 0.95fr 1.05fr; }
  #customer-login-modal .lm-aside {
    display: flex; flex-direction: column; gap: 14px; padding: 32px 28px;
    background: linear-gradient(180deg, color-mix(in srgb, var(--accent) 10%, var(--raised)) 0%, var(--raised) 60%);
    border-right: 1px solid var(--border);
  }
  #customer-login-modal .lm-main .modal-header, #customer-login-modal .lm-main .modal-body { padding-left: 28px; padding-right: 28px; }
  #customer-login-modal .lm-main .modal-header { padding-top: 28px; }
  #customer-login-modal .lm-main .modal-body { padding-bottom: 28px; }
}
#customer-login-modal .lm-aside-kicker { margin: 0; font-size: 0.8125rem; font-weight: 600; color: var(--accent); }
#customer-login-modal .lm-aside-title { margin: 0 0 6px; font-size: 1.375rem; font-weight: 600; line-height: 1.2; letter-spacing: -0.02em; color: var(--text); }
#customer-login-modal .lm-aside-list { list-style: none; margin: 0; padding: 0; display: grid; gap: 14px; }
#customer-login-modal .lm-aside-list li { display: grid; grid-template-columns: 36px 1fr; gap: 12px; align-items: start; }
#customer-login-modal .lm-aside-list .nx-i { width: 36px; height: 36px; padding: 8px; border-radius: var(--r-sm); background: var(--surface); border: 1px solid var(--border); color: var(--text); }
#customer-login-modal .lm-aside-list strong { display: block; font-size: 0.875rem; font-weight: 600; color: var(--text); }
#customer-login-modal .lm-aside-list span { font-size: 0.8125rem; line-height: 1.45; color: var(--muted); }
#customer-login-modal .lm-aside-note { margin: auto 0 0; padding-top: 14px; border-top: 1px solid var(--border); font-size: 0.8125rem; color: var(--muted); }
