/* AIX storefront palette and catalog layout */
:root, :root[data-theme="dark"] {
  --bg: #101114;
  --surface: #1c1e22;
  --surface2: #25282d;
  --surface3: #30343a;
  --border: #373b43;
  --border-strong: #656b76;
  --text: #f7f8fa;
  --text-secondary: #d8dbe1;
  --muted: #aeb4be;
  --accent: #c5f453;
  --accent-hover: #d5ff79;
  --accent2: #c5f453;
  --accent-fg: #15190b;
  --accent-soft: #2c341c;
  --accent-border: #74894a;
  --aix-green: var(--accent);
  --action: #c5f453;
  --action-hover: #d5ff79;
  --action-fg: #15190b;
  --sidebar-bg: #16181b;
  --topbar-bg: #16181b;
  --code-bg: #15171a;
}
:root[data-theme="light"] {
  --bg: #f4f5f7;
  --surface: #fff;
  --surface2: #eef0f3;
  --surface3: #e6e8ec;
  --border: #d5d8df;
  --border-strong: #8d929c;
  --text: #191b20;
  --text-secondary: #3a3f48;
  --muted: #565d69;
  --accent: #405a11;
  --accent-hover: #304609;
  --accent2: #405a11;
  --accent-fg: #fff;
  --accent-soft: #eaf1dc;
  --accent-border: #738849;
  --aix-green: var(--accent);
  --action: #b8ea49;
  --action-hover: #cdff66;
  --action-fg: #15190b;
  --sidebar-bg: #fafbfc;
  --topbar-bg: #fafbfc;
  --code-bg: #eef0f3;
}

body.aix-vivid {
  background: var(--bg) !important;
  color: var(--text) !important;
}
body.aix-vivid :is(.product-card, .purchase-panel, .panel) {
  background: var(--surface) !important;
  border-color: var(--border) !important;
  box-shadow: none !important;
}
body.aix-vivid :is(.sidebar, .topbar, .mobile-nav) {
  background: var(--topbar-bg) !important;
  border-color: var(--border) !important;
  box-shadow: none !important;
}
body.aix-vivid .sidebar .brand-mark,
body.aix-vivid .mobile-brand .header-logo {
  border: 1px solid var(--border-strong) !important;
  box-shadow: none !important;
}
body.aix-vivid :is(.nav-item.active, .mobile-nav .nav-item.active) {
  background: var(--accent-soft) !important;
  color: var(--accent) !important;
  box-shadow: none !important;
}
body.aix-vivid :is(a.button, button):not(.ghost, .theme-toggle, .google-button, .pw-toggle-btn, .preference-toggle, .amount-preset) {
  background: var(--action) !important;
  border-color: var(--accent-border) !important;
  color: var(--action-fg) !important;
  box-shadow: none !important;
}
body.aix-vivid :is(a.button, button):not(.ghost, .theme-toggle, .google-button, .pw-toggle-btn, .preference-toggle, .amount-preset):hover {
  background: var(--action-hover) !important;
}
body.aix-vivid :is(a, button, select, input, summary):focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 3px;
}
body.aix-vivid .sidebar-bottom .status-dot { display: none; }

body.page-discover .hero.aix-catalog-intro {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  gap: 1rem;
  min-height: 0 !important;
  padding: clamp(1.35rem, 3vw, 2.35rem) !important;
  margin-bottom: 1.5rem;
  border: 1px solid var(--border);
  border-radius: 18px;
  background: linear-gradient(125deg, var(--surface2), var(--surface) 72%) !important;
  box-shadow: none !important;
}
body.page-discover .hero.aix-catalog-intro::before,
body.page-discover .hero.aix-catalog-intro::after { display: none; }

body.page-discover .aix-catalog-intro h1 {
  color: var(--text) !important;
  font-size: clamp(1.65rem, 4vw, 3.25rem) !important;
  line-height: 1.1 !important;
  margin: 0 0 .45rem !important;
  letter-spacing: -.045em !important;
  text-shadow: none;
}
body.page-discover .aix-catalog-intro p {
  font-size: .95rem !important;
  line-height: 1.45;
  margin: 0 !important;
}
.aix-catalog-art {
  display: grid;
  place-items: center;
  padding: .5rem;
  border-radius: 16px;
  border: 1px solid var(--border);
  background: var(--surface2);
}
.aix-catalog-art img {
  width: clamp(72px, 10vw, 112px);
  height: auto;
  aspect-ratio: 1;
  border-radius: 50%;
}
#collection { scroll-margin-top: 88px; }
body.page-discover #collection .section-heading {
  margin: 1rem 0 .65rem !important;
}
body.page-discover #collection .section-heading .subtle {
  font-size: .77rem;
  white-space: nowrap;
}
body.page-discover .category-chips {
  flex-wrap: wrap;
  gap: .4rem !important;
  overflow: visible;
  padding: .15rem .15rem .2rem;
  margin: .45rem -.15rem .65rem !important;
}
body.page-discover .category-chip {
  flex: 0 0 auto;
  max-inline-size: 100%;
  min-height: 36px !important;
  padding: .32rem .65rem !important;
  border-radius: 999px;
  font-size: .78rem !important;
  line-height: 1.2;
  gap: .35rem;
  white-space: normal;
  background: var(--surface) !important;
  border: 1px solid var(--border) !important;
  box-shadow: none !important;
  color: var(--text) !important;
}
body.page-discover .category-chip > span { min-inline-size: 0; overflow-wrap: break-word; }
body.page-discover .category-chip.selected {
  background: var(--action) !important;
  border-color: var(--accent-border) !important;
  color: var(--action-fg) !important;
}
body.page-discover .category-chip.selected small { color: inherit !important; }
body.page-discover .category-chip small {
  flex: none;
  font-size: .68rem;
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}
.catalog-filters {
  display: grid;
  grid-template-columns: minmax(140px, 1.6fr) repeat(2, minmax(0, 1fr)) auto;
  gap: .6rem;
  align-items: end;
  padding: .7rem;
  margin: 0 0 .75rem;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 12px;
}
.catalog-filters label {
  display: grid;
  gap: .25rem;
  min-width: 0;
  margin: 0;
  font-size: .75rem;
  color: var(--text-secondary) !important;
}
.catalog-filters :is(input, select, button) { min-height: 42px; width: 100%; margin: 0; }
.catalog-filters :is(input, select) { padding: .42rem .55rem !important; }
.catalog-filters button { padding: .42rem .75rem !important; font-size: .82rem !important; }
body.aix-vivid .catalog-filters :is(select, input) {
  background: var(--bg) !important;
  border-color: var(--border-strong) !important;
  box-shadow: none !important;
}
body.page-discover .product-grid {
  grid-template-columns: repeat(auto-fill, minmax(min(100%, 195px), 1fr)) !important;
  gap: .65rem !important;
}
body.aix-vivid .product-card:hover {
  border-color: var(--accent-border) !important;
  transform: translateY(-2px);
}
body.page-discover .product-card {
  display: flex;
  flex-direction: column;
  min-height: 0;
  border-radius: 13px;
}
body.page-discover .product-card .aix-surface-wash { display: none; }
body.page-discover .product-card-media {
  display: flex;
  justify-content: space-between;
  align-items: center;
  position: relative;
  gap: .4rem;
  padding: .65rem .65rem 0;
}
body.page-discover .product-card .product-art.brand-scene {
  flex: none;
  height: auto !important;
  min-height: 0 !important;
  padding: 0 !important;
}
body.page-discover .product-card .product-art .logo-plinth {
  width: 40px !important;
  min-width: 40px !important;
  height: 40px !important;
  padding: 5px !important;
  border-radius: 8px !important;
}
body.page-discover .product-card .product-art .logo-plinth-wide {
  width: 55px !important;
  min-width: 55px !important;
}
body.page-discover .product-card .custom-cover {
  width: 100%;
  height: 78px !important;
  border-radius: 7px;
}
body.page-discover .product-card-media:has(.custom-cover) .stock {
  position: absolute;
  top: .95rem;
  right: .95rem;
  background: var(--surface) !important;
}
body.aix-vivid .product-card .product-info {
  display: flex;
  flex-direction: column;
  flex: 1;
}
body.page-discover .product-card .product-info { padding: .55rem .65rem .65rem !important; }
body.page-discover .product-card .product-info h3 {
  margin: .2rem 0 .4rem !important;
  min-height: 0 !important;
}
body.page-discover .product-card .stock {
  background: var(--surface2) !important;
  border-color: var(--border) !important;
  color: var(--text-secondary) !important;
  white-space: nowrap;
  font-variant-numeric: tabular-nums;
  line-height: 1.35;
}
body.page-discover .product-card .stock::before { display: none; }
body.page-discover .product-card .product-tags { margin-bottom: .55rem !important; }
body.page-discover .product-card .card-price {
  margin-top: auto;
  padding-top: .4rem !important;
}
body.aix-vivid .product-card .card-price strong { color: var(--text) !important; }
body.aix-vivid .product-card .buy-chip { color: var(--accent) !important; }

.product-facts { margin: 1.15rem 0; }
.product-facts > div {
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  padding: .7rem 0;
  border-bottom: 1px solid var(--border);
}
.product-facts dt { color: var(--muted); }
.product-facts dd { margin: 0; color: var(--text); text-align: end; overflow-wrap: anywhere; }
.purchase-auth { display: grid; gap: .8rem; text-align: center; padding: .25rem 0; }

a.google-button, button.google-button {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: .65rem;
  width: 100%;
  min-height: 46px;
  border: 1px solid var(--border-strong) !important;
  border-radius: 10px;
  padding: .65rem 1rem;
  color: var(--text) !important;
  background: var(--surface2) !important;
  font-size: .95rem;
  font-weight: 650;
  box-shadow: none !important;
}
.google-button:hover { background: var(--surface3) !important; }
.auth-or {
  display: flex;
  align-items: center;
  gap: .7rem;
  margin: 1rem 0;
  color: var(--muted);
  font-size: .8rem;
  text-align: center;
}
.auth-or::before, .auth-or::after { content: ""; background: var(--border); height: 1px; flex: 1; }

@media (max-width: 850px) {
  .catalog-filters { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr) auto; }
  .catalog-filters .catalog-search { grid-column: 1 / -1; }
  .catalog-filters .catalog-search > span {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    overflow: hidden;
    clip-path: inset(50%);
    white-space: nowrap;
  }
}
@media (max-width: 620px) {
  body.page-discover .hero.aix-catalog-intro {
    grid-template-columns: minmax(0, 1fr);
    padding: 1rem !important;
    margin-bottom: .95rem;
  }
  .aix-catalog-art { display: none; }
  body.page-discover .product-grid { grid-template-columns: repeat(2, minmax(0, 1fr)) !important; }
  .catalog-filters input { font-size: 16px; }
}
@media (max-width: 345px) {
  body.page-discover .product-grid { grid-template-columns: minmax(0, 1fr) !important; }
}

/* Keep the original brand art visible and animate the mark beside it. */
body.aix-vivid,
:root[data-theme="light"] body.aix-vivid {
  --motion-rgb: 144, 150, 161;
  --motion-cool: 120, 126, 137;
  --motion-wash: .045;
}
body.aix-vivid .aix-motion-scene { opacity: .3; }
body.aix-vivid .brand-motion {
  display: inline-flex;
  align-items: center;
  gap: 3px;
  margin-inline-start: 4px;
  color: var(--accent);
}
.brand-motion i {
  width: 3px;
  height: 13px;
  border-radius: 2px;
  background: currentColor;
  animation: aix-mark-wave 1.8s ease-in-out infinite;
}
.brand-motion i:nth-child(2) { animation-delay: .18s; }
.brand-motion i:nth-child(3) { animation-delay: .36s; }
@keyframes aix-mark-wave {
  0%, 65%, 100% { transform: scaleY(.35); opacity: .65; }
  30% { transform: scaleY(1); opacity: 1; }
}

body.aix-vivid .auth-card h1.signin-title {
  color: var(--accent) !important;
  letter-spacing: -.04em;
  text-shadow: none;
}
body.aix-vivid .payment-choice .payment-visual {
  display: grid;
  place-items: center;
  width: 62px !important;
  height: 44px !important;
  margin: 0 auto !important;
  border: 0 !important;
  border-radius: 0 !important;
  background: transparent !important;
  box-shadow: none !important;
}
body.aix-vivid .payment-choice .payment-logo {
  width: 30px !important;
  height: 30px !important;
  object-fit: contain;
  filter: none !important;
  border: 0 !important;
  border-radius: 0 !important;
  box-shadow: none !important;
  background: transparent !important;
}
body.aix-vivid .payment-choice:has([value="bybit_auto"]) .payment-logo { width: 56px !important; }
body.aix-vivid .payment-choice {
  background: var(--surface2) !important;
  border-color: var(--border) !important;
  box-shadow: none !important;
}
body.aix-vivid .payment-choice:has(input:checked) {
  background: var(--accent-soft) !important;
  border-color: var(--accent) !important;
}
body.aix-vivid .payment-text strong { color: var(--text) !important; }

.purchase-actions, .cart-lines { display: grid; gap: .8rem; }
.cart-heading { margin-bottom: 1.25rem; }
.cart-layout {
  display: grid;
  grid-template-columns: minmax(0, 1.6fr) minmax(290px, 1fr);
  align-items: start;
  gap: 1rem;
}
.cart-line {
  display: grid;
  grid-template-columns: 46px minmax(0, 1fr);
  align-items: start;
  column-gap: .85rem;
}
.cart-line > img {
  padding: 5px;
  width: 46px;
  height: 46px;
  object-fit: contain;
  border-radius: 10px;
  background: var(--surface2);
}
.cart-line h2 { font-size: 1rem; margin: 0 0 .45rem; overflow-wrap: anywhere; }
.cart-line h2 a { color: var(--text); }
.cart-line-info strong { color: var(--accent); }
.cart-line p.cart-line-error { margin: 0; }
.cart-line-form {
  grid-column: 2;
  display: flex;
  justify-content: flex-start;
  flex-wrap: wrap;
  align-items: center;
  gap: .35rem;
  margin: .85rem 0 0;
}
.cart-line-form button, .cart-line-form input { min-height: 42px; margin: 0; padding: 0 .6rem; }
.cart-line-form input { width: 66px; text-align: center; font-size: 16px; }
.cart-line-form button:disabled { opacity: .5; cursor: default; }
.cart-line-form .cart-remove { color: var(--text-secondary); }
.cart-summary h2 { margin-top: 0; font-size: 1.2rem; }
.cart-summary dl { display: grid; gap: .7rem; }
.cart-summary dl > div {
  display: flex;
  justify-content: space-between;
  gap: .75rem;
  font-size: .95rem;
}
.cart-summary dt { min-width: 0; overflow-wrap: anywhere; }
.cart-summary dd { margin: 0; white-space: nowrap; }
.cart-summary .cart-total {
  border-top: 1px solid var(--border);
  padding-top: 1rem;
  color: var(--accent);
  font-weight: 750;
}
.cart-review, .cart-notice { max-width: 615px; }
.cart-notice ul { padding-inline-start: 1.2rem; margin-bottom: 1.25rem; }
.cart-notice li { padding: .25rem 0; }
@media (max-width: 880px) {
  .cart-layout { grid-template-columns: minmax(0, 1fr); }
}
@media (max-width: 370px) {
  body.aix-vivid .mobile-brand .brand-motion { display: none; }
  .cart-line-form { grid-column: 1 / -1; }
}
@media (prefers-reduced-motion: reduce) {
  .brand-motion i { animation: none; }
}

/* Give monochrome artwork neutral contrast and preserve the file’s original colors. */
body.aix-vivid .product-art .logo-plinth {
  background: transparent !important;
  border-color: transparent !important;
  box-shadow: none !important;
  transform: none;
}
body.aix-vivid .product-art .logo-plinth.logo-plinth-contrast {
  background: #f1f2f3 !important;
  border-color: #e4e6e7 !important;
}
body.aix-vivid .product-art .brand-logo {
  opacity: 1;
  filter: none !important;
  mix-blend-mode: normal;
  transform: none;
}
body.aix-vivid .cart-lines .cart-line { margin: 0 !important; }
body.aix-vivid .cart-summary dl {
  grid-template-columns: minmax(0, 1fr);
  margin: 0 0 1rem;
  padding: 0;
}
body.aix-vivid .cart-summary dt,
body.aix-vivid .cart-summary dd { font-size: inherit; line-height: 1.35; }
body.aix-vivid .cart-summary .cart-total :is(dt, dd) { color: var(--accent); }
body.aix-vivid .amount-preset.selected {
  background: var(--action) !important;
  border-color: var(--accent-border) !important;
  color: var(--action-fg) !important;
}
body.aix-vivid .amount-preset.selected small { color: inherit !important; }
@media (max-width: 460px) {
  .cart-line-form { grid-column: 1 / -1; }
}

@media (max-width: 760px) {
  body.aix-vivid .mobile-nav .nav-item { flex: 1 1 0; }
  body.aix-vivid .mobile-nav .nav-item span { white-space: nowrap; }
}
@media (max-width: 355px) {
  body.aix-vivid .mobile-nav .nav-item { padding-inline: 1px !important; }
  body.aix-vivid .mobile-nav .nav-item span { font-size: 9px; }
  body.aix-vivid .top-actions > .text-link { display: inline-flex !important; }
}
