/* ============================================================
   ACCRA NO.1 JEWELRY & ACCESSORIES — Storefront design system
   Warm ivory "paper" canvas, near-black ink text, antique brass
   as the one signature accent (same family as the admin panel,
   so the brand feels continuous from showroom floor to till).
   Signature: the faceted gem-cut corner, carried over from admin,
   used on product cards and the hero frame.
   ============================================================ */

@import url('https://fonts.googleapis.com/css2?family=Fraunces:opsz,wght@9..144,400;9..144,500;9..144,600;9..144,700&family=Inter:wght@400;500;600;700&family=JetBrains+Mono:wght@400;500;600&display=swap');

:root {
  --paper:        #FBF8F3;
  --surface:      #FFFFFF;
  --surface-alt:  #F3EEE4;
  --ink:          #1C1A17;
  --ink-soft:     #4A453D;
  --muted:        #8A8275;

  --brass:        #B08A3E;
  --brass-bright: #D6AE64;
  --brass-deep:   #8A6A2D;
  --brass-10:     rgba(176, 138, 62, 0.10);
  --brass-18:     rgba(176, 138, 62, 0.18);

  --sage:         #5C7A5E;
  --sage-bg:      rgba(92, 122, 94, 0.12);
  --brick:        #A15A3F;
  --brick-bg:     rgba(161, 90, 63, 0.12);

  --line:         rgba(28, 26, 23, 0.10);
  --shadow-soft:  0 1px 2px rgba(28,26,23,0.04), 0 10px 28px rgba(28,26,23,0.06);
  --shadow-lift:  0 6px 16px rgba(28,26,23,0.08), 0 22px 44px rgba(28,26,23,0.10);

  --font-display: 'Fraunces', Georgia, serif;
  --font-body: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
  --font-mono: 'JetBrains Mono', ui-monospace, monospace;

  --ease: cubic-bezier(0.22, 1, 0.36, 1);
  --container: 1240px;
}

* { box-sizing: border-box; }
html { -webkit-font-smoothing: antialiased; scroll-behavior: smooth; }
body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--font-body);
  font-size: 15px;
  line-height: 1.6;
}
a { color: inherit; text-decoration: none; }
ul { list-style: none; margin: 0; padding: 0; }
button { font-family: inherit; cursor: pointer; }
img { max-width: 100%; display: block; }
h1, h2, h3, h4 { font-family: var(--font-display); margin: 0; letter-spacing: -0.01em; color: var(--ink); }
.mono { font-family: var(--font-mono); }
.site-container { max-width: var(--container); margin: 0 auto; padding: 0 32px; }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: 0.001ms !important; transition-duration: 0.001ms !important; }
}

/* ---------- Faceted signature corner (carried over from the admin panel) ---------- */
.facet {
  clip-path: polygon(0 22px, 22px 0, 100% 0, 100% 100%, 0 100%);
  position: relative;
}
.facet::before {
  content: '';
  position: absolute;
  top: 0; left: 0;
  width: 22px; height: 22px;
  background: linear-gradient(135deg, var(--brass-bright), var(--brass));
  clip-path: polygon(0 0, 100% 0, 0 100%);
}

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  padding: 13px 26px; border-radius: 999px; font-size: 13.5px; font-weight: 600;
  letter-spacing: 0.01em; border: 1.5px solid transparent;
  transition: transform 0.2s var(--ease), box-shadow 0.2s var(--ease), background 0.2s var(--ease), border-color 0.2s var(--ease);
}
.btn:active { transform: scale(0.97); }
.btn-primary { background: var(--ink); color: var(--paper); }
.btn-primary:hover { background: #000; transform: translateY(-2px); box-shadow: var(--shadow-lift); }
.btn-brass { background: linear-gradient(160deg, var(--brass-bright), var(--brass) 70%); color: #201804; box-shadow: 0 2px 0 var(--brass-deep); }
.btn-brass:hover { transform: translateY(-2px); box-shadow: 0 2px 0 var(--brass-deep), 0 10px 24px var(--brass-18); }
.btn-outline { border-color: var(--ink); color: var(--ink); background: transparent; }
.btn-outline:hover { background: var(--ink); color: var(--paper); }
.btn-outline-light { border-color: rgba(255,255,255,0.5); color: #fff; background: transparent; }
.btn-outline-light:hover { background: #fff; color: var(--ink); border-color: #fff; }
.btn-sm { padding: 9px 18px; font-size: 12.5px; }

/* ---------- Announcement bar ---------- */
.announce-bar {
  background: var(--ink); color: var(--paper);
  text-align: center; font-size: 12.5px; letter-spacing: 0.03em;
  padding: 9px 20px;
}
.announce-bar strong { color: var(--brass-bright); }
.announce-bar.sale-banner { background: var(--brick); font-weight: 700; letter-spacing: 0.01em; }

/* ---------- Sale merchandising (shared across cards, cart, checkout, product page) ---------- */
.sale-tag {
  display: inline-block; background: var(--brick); color: #fff; font-size: 10.5px; font-weight: 800;
  letter-spacing: 0.04em; text-transform: uppercase; padding: 2px 7px; border-radius: 5px; vertical-align: middle;
}
.was-price { color: var(--muted); font-weight: 400; margin-right: 6px; }
/* Sale tag sits at the opposite corner from the stock/wholesale tag, since both can show at once. */
.product-card .p-tag.sale { left: auto; right: 12px; background: var(--brick); color: #fff; }

/* ---------- Site header / nav ---------- */
.site-header {
  background: var(--paper);
  border-bottom: 1px solid var(--line);
  position: sticky; top: 0; z-index: 40;
}
.nav-row { display: flex; align-items: center; justify-content: space-between; padding: 18px 0; gap: 24px; position: relative; }
.brand-mark { display: flex; align-items: center; gap: 12px; }
.brand-mark .mark {
  width: 34px; height: 34px; flex-shrink: 0;
  background: linear-gradient(135deg, var(--brass-bright), var(--brass-deep));
  clip-path: polygon(15% 0, 100% 0, 100% 85%, 85% 100%, 0 100%, 0 15%);
}
.brand-mark .wordmark { font-family: var(--font-display); font-size: 20px; font-weight: 600; line-height: 1; white-space: nowrap; }
.brand-mark .wordmark small { display: block; font-family: var(--font-body); font-size: 10.5px; font-weight: 500; letter-spacing: 0.12em; text-transform: uppercase; color: var(--muted); margin-top: 3px; }

.nav-links { display: flex; align-items: center; gap: 30px; }
.nav-links a { font-size: 13.5px; font-weight: 500; color: var(--ink-soft); position: relative; padding: 4px 0; }
.nav-links a:hover { color: var(--ink); }
.nav-links a::after {
  content: ''; position: absolute; left: 0; right: 0; bottom: -2px; height: 1.5px;
  background: var(--brass); transform: scaleX(0); transform-origin: left; transition: transform 0.25s var(--ease);
}
.nav-links a:hover::after { transform: scaleX(1); }

.nav-icons { display: flex; align-items: center; gap: 8px; }
.nav-icon-btn {
  width: 40px; height: 40px; border-radius: 50%; display: flex; align-items: center; justify-content: center;
  color: var(--ink); position: relative; transition: background 0.16s var(--ease);
}
.nav-icon-btn:hover { background: var(--surface-alt); }
.nav-icon-btn .cart-badge {
  position: absolute; top: 2px; right: 2px; min-width: 16px; height: 16px; border-radius: 20px;
  background: var(--brass-deep); color: #fff; font-size: 10px; font-weight: 700;
  display: flex; align-items: center; justify-content: center; padding: 0 3px;
}
.mobile-toggle { display: none; }

/* ---------- Hero ---------- */
.hero { padding: 70px 0 90px; overflow: hidden; }
.hero-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 60px; align-items: center; }
.hero-eyebrow { display: inline-flex; align-items: center; gap: 8px; font-size: 12px; font-weight: 600; letter-spacing: 0.08em; text-transform: uppercase; color: var(--brass-deep); margin-bottom: 18px; }
.hero-eyebrow::before { content: ''; width: 18px; height: 1.5px; background: var(--brass); }
.hero h1 { font-size: 52px; line-height: 1.08; font-weight: 500; margin-bottom: 22px; }
.hero h1 em { font-style: italic; color: var(--brass-deep); }
.hero p.lede { font-size: 16px; color: var(--ink-soft); max-width: 460px; margin-bottom: 32px; }
.hero-actions { display: flex; gap: 14px; margin-bottom: 40px; }
.hero-trust { display: flex; gap: 28px; }
.hero-trust div { font-size: 12px; color: var(--muted); }
.hero-trust strong { display: block; font-family: var(--font-display); font-size: 20px; color: var(--ink); font-weight: 600; }

.hero-visual { position: relative; aspect-ratio: 1/1; }
.hero-visual .frame {
  position: absolute; inset: 0; border-radius: 28px;
  background: linear-gradient(155deg, var(--surface-alt), var(--paper));
  border: 1px solid var(--line);
  overflow: hidden;
}
.hero-visual .frame .hero-photo {
  width: 100%; height: 100%; object-fit: cover;
  animation: heroFadeIn 0.8s var(--ease);
}
.hero-visual .frame .hero-placeholder-art { width: 62%; height: 62%; margin: auto; position: absolute; inset: 0; }
@keyframes heroFadeIn { from { opacity: 0; transform: scale(1.03); } to { opacity: 1; transform: scale(1); } }
.hero-visual .facet-badge {
  position: absolute; bottom: 24px; left: 24px; background: var(--surface);
  border-radius: 16px; padding: 16px 20px; box-shadow: var(--shadow-lift); max-width: 220px;
}
.hero-visual .facet-badge .t1 { font-size: 11px; color: var(--muted); margin-bottom: 2px; }
.hero-visual .facet-badge .t2 { font-family: var(--font-display); font-size: 16px; font-weight: 600; }

/* ---------- Section scaffolding ---------- */
.section { padding: 70px 0; }
.section-alt { background: var(--surface-alt); }
.section-head { display: flex; align-items: flex-end; justify-content: space-between; margin-bottom: 40px; gap: 20px; flex-wrap: wrap; }
.section-head .eyebrow { font-size: 12px; font-weight: 600; letter-spacing: 0.08em; text-transform: uppercase; color: var(--brass-deep); margin-bottom: 10px; }
.section-head h2 { font-size: 32px; font-weight: 500; }
.section-head p { color: var(--ink-soft); margin-top: 8px; max-width: 480px; }

/* ---------- Category tiles ---------- */
.category-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 20px; }
.category-tile {
  position: relative; border-radius: 20px; overflow: hidden; aspect-ratio: 3/4;
  background: linear-gradient(155deg, #E9E1D0, var(--surface-alt));
  transition: transform 0.3s var(--ease), box-shadow 0.3s var(--ease);
}
.category-tile:hover { transform: translateY(-6px); box-shadow: var(--shadow-lift); }
.category-tile .cat-img { position: absolute; inset: 0; background-size: cover; background-position: center; }
.category-tile .cat-overlay {
  position: absolute; left: 0; right: 0; bottom: 0; padding: 20px;
  background: linear-gradient(0deg, rgba(28,26,23,0.68), transparent 70%);
  color: #fff;
}
.category-tile .cat-name { font-family: var(--font-display); font-size: 19px; font-weight: 600; }
.category-tile .cat-count { font-size: 11.5px; opacity: 0.8; margin-top: 2px; }

/* ---------- Product cards ---------- */
.product-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 24px; }
.product-card { position: relative; }
.product-card .p-frame {
  aspect-ratio: 1/1.1; border-radius: 16px; overflow: hidden; margin-bottom: 16px; position: relative;
  background: var(--surface-alt);
}
.product-card .p-frame img { width: 100%; height: 100%; object-fit: cover; transition: transform 0.5s var(--ease); }
.product-card:hover .p-frame img { transform: scale(1.06); }
.product-card .p-tag {
  position: absolute; top: 12px; left: 12px; font-size: 10.5px; font-weight: 700; letter-spacing: 0.05em; text-transform: uppercase;
  padding: 5px 10px; border-radius: 20px; background: var(--surface); color: var(--brass-deep);
}
.product-card .p-tag.low { background: var(--brick); color: #fff; }
.product-card .p-cat { font-size: 11.5px; color: var(--muted); text-transform: uppercase; letter-spacing: 0.05em; margin-bottom: 4px; }
.product-card .p-name { font-size: 15px; font-weight: 600; margin-bottom: 6px; }
.product-card .p-price { font-family: var(--font-mono); font-size: 14.5px; font-weight: 600; }
.product-card .p-price .strike { text-decoration: line-through; color: var(--muted); font-weight: 400; margin-right: 8px; font-size: 13px; }
.product-card .quick-add {
  position: absolute; bottom: 16px; left: 12px; right: 12px;
  background: var(--ink); color: var(--paper); text-align: center; padding: 11px; border-radius: 30px;
  font-size: 12.5px; font-weight: 600; opacity: 0; transform: translateY(8px);
  transition: opacity 0.22s var(--ease), transform 0.22s var(--ease);
}
.product-card:hover .quick-add { opacity: 1; transform: translateY(0); }

/* ---------- Value props ---------- */
.value-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 28px; }
.value-item { text-align: left; }
.value-item .v-icon {
  width: 46px; height: 46px; border-radius: 12px; background: var(--brass-10); color: var(--brass-deep);
  display: flex; align-items: center; justify-content: center; margin-bottom: 16px;
}
.value-item .v-icon svg { width: 22px; height: 22px; }
.value-item h4 { font-size: 15.5px; font-weight: 600; margin-bottom: 6px; }
.value-item p { font-size: 13px; color: var(--ink-soft); margin: 0; }

/* ---------- Wholesale banner ---------- */
.wholesale-banner {
  background: var(--ink); color: var(--paper); border-radius: 28px; padding: 56px; position: relative; overflow: hidden;
}
.wholesale-banner .wb-grid { display: grid; grid-template-columns: 1.3fr 1fr; gap: 40px; align-items: center; position: relative; z-index: 1; }
.wholesale-banner h2 { color: #fff; font-size: 30px; margin-bottom: 14px; }
.wholesale-banner p { color: rgba(255,255,255,0.72); font-size: 14.5px; max-width: 440px; margin-bottom: 24px; }
.wholesale-banner .wb-stats { display: flex; gap: 30px; }
.wholesale-banner .wb-stats div { text-align: center; padding: 20px; border-radius: 16px; background: rgba(255,255,255,0.06); flex: 1; }
.wholesale-banner .wb-stats strong { display: block; font-family: var(--font-display); font-size: 24px; color: var(--brass-bright); }
.wholesale-banner .wb-stats span { font-size: 11px; color: rgba(255,255,255,0.6); }
.wholesale-banner .gem-decor {
  position: absolute; top: -60px; right: -60px; width: 260px; height: 260px;
  background: linear-gradient(135deg, rgba(214,174,100,0.16), transparent 70%);
  clip-path: polygon(50% 0, 100% 38%, 82% 100%, 18% 100%, 0 38%);
}

/* ---------- Footer ---------- */
.site-footer { background: var(--ink); color: rgba(255,255,255,0.68); padding: 60px 0 28px; margin-top: 40px; }
.footer-grid { display: grid; grid-template-columns: 1.6fr 1fr 1fr 1fr; gap: 40px; margin-bottom: 40px; }
.footer-brand .wordmark { color: #fff; font-family: var(--font-display); font-size: 20px; font-weight: 600; margin-bottom: 12px; }
.footer-brand p { font-size: 13px; max-width: 280px; line-height: 1.6; }
.footer-col h5 { color: #fff; font-size: 12.5px; font-weight: 600; text-transform: uppercase; letter-spacing: 0.06em; margin-bottom: 16px; }
.footer-col a { display: block; font-size: 13.5px; margin-bottom: 11px; color: rgba(255,255,255,0.68); transition: color 0.16s var(--ease); }
.footer-col a:hover { color: var(--brass-bright); }
.footer-bottom { border-top: 1px solid rgba(255,255,255,0.12); padding-top: 24px; display: flex; justify-content: space-between; align-items: center; font-size: 12px; flex-wrap: wrap; gap: 12px; }
.payment-badges { display: flex; gap: 8px; }
.payment-badges span { border: 1px solid rgba(255,255,255,0.2); border-radius: 6px; padding: 4px 10px; font-size: 11px; }

/* ---------- Scroll reveal ---------- */
[data-reveal] { opacity: 0; transform: translateY(18px); transition: opacity 0.6s var(--ease), transform 0.6s var(--ease); }
[data-reveal].is-visible { opacity: 1; transform: translateY(0); }

/* ---------- Breadcrumb ---------- */
.breadcrumb { font-size: 12.5px; color: var(--muted); margin-bottom: 18px; }
.breadcrumb a { color: var(--muted); }
.breadcrumb a:hover { color: var(--ink); }
.breadcrumb span { margin: 0 6px; }

/* ---------- Shop layout ---------- */
.shop-layout { display: grid; grid-template-columns: 240px 1fr; gap: 40px; align-items: start; }
.shop-filters { position: sticky; top: 96px; }
.filter-block { margin-bottom: 30px; }
.filter-block h5 { font-size: 12px; font-weight: 700; text-transform: uppercase; letter-spacing: 0.06em; color: var(--ink); margin-bottom: 14px; }
.filter-list a { display: flex; justify-content: space-between; padding: 8px 0; font-size: 13.5px; color: var(--ink-soft); border-bottom: 1px solid var(--line); }
.filter-list a:hover { color: var(--brass-deep); }
.filter-list a.active { color: var(--brass-deep); font-weight: 600; }
.filter-list a span { color: var(--muted); font-size: 12px; }
.filter-search input {
  width: 100%; padding: 10px 14px; border-radius: 10px; border: 1.5px solid var(--line);
  background: var(--surface); font-size: 13.5px; font-family: inherit; outline: none;
}
.filter-search input:focus { border-color: var(--brass); }

.shop-toolbar { display: flex; align-items: center; justify-content: space-between; margin-bottom: 26px; flex-wrap: wrap; gap: 12px; }
.shop-toolbar .result-count { font-size: 13px; color: var(--muted); }
.shop-toolbar select {
  padding: 9px 14px; border-radius: 10px; border: 1.5px solid var(--line); background: var(--surface);
  font-size: 13px; font-family: inherit; color: var(--ink);
}
.active-filter-chip {
  display: inline-flex; align-items: center; gap: 8px; background: var(--surface-alt); border-radius: 20px;
  padding: 6px 8px 6px 14px; font-size: 12.5px; margin-bottom: 20px;
}
.active-filter-chip a { width: 18px; height: 18px; border-radius: 50%; background: var(--ink); color: var(--paper); display: flex; align-items: center; justify-content: center; font-size: 11px; }

.empty-state { text-align: center; padding: 80px 20px; color: var(--muted); }
.empty-state h3 { color: var(--ink); margin-bottom: 8px; font-size: 18px; }

.pagination { display: flex; justify-content: center; gap: 8px; margin-top: 48px; }
.pagination a, .pagination span {
  width: 38px; height: 38px; border-radius: 10px; display: flex; align-items: center; justify-content: center;
  font-size: 13px; font-weight: 600; border: 1.5px solid var(--line); color: var(--ink-soft);
}
.pagination a:hover { border-color: var(--brass); color: var(--brass-deep); }
.pagination .current { background: var(--ink); color: var(--paper); border-color: var(--ink); }

@media (max-width: 900px) {
  .shop-layout { grid-template-columns: 1fr; }
  .shop-filters { position: static; }
}

/* ---------- Flash banner (storefront) ---------- */
.site-flash {
  display: flex; align-items: center; justify-content: space-between; gap: 14px;
  padding: 14px 20px; border-radius: 12px; font-size: 13.5px; margin-bottom: 24px;
}
.site-flash.success { background: var(--sage-bg); color: var(--sage); }
.site-flash.error { background: var(--brick-bg); color: var(--brick); }
.site-flash a { font-weight: 700; text-decoration: underline; }

/* ---------- Product detail ---------- */
.product-detail { display: grid; grid-template-columns: 1fr 1fr; gap: 56px; align-items: flex-start; }
.pd-gallery .pd-main { aspect-ratio: 1/1; border-radius: 20px; overflow: hidden; background: var(--surface-alt); margin-bottom: 14px; }
.pd-gallery .pd-main img { width: 100%; height: 100%; object-fit: cover; }
.pd-thumbs { display: flex; gap: 10px; }
.pd-thumbs button { width: 68px; height: 68px; border-radius: 10px; overflow: hidden; border: 1.5px solid var(--line); padding: 0; background: var(--surface-alt); }
.pd-thumbs button.active { border-color: var(--brass); }
.pd-thumbs img { width: 100%; height: 100%; object-fit: cover; }

.pd-info .pd-cat { font-size: 12px; text-transform: uppercase; letter-spacing: 0.06em; color: var(--brass-deep); font-weight: 600; margin-bottom: 10px; }
.pd-info h1 { font-size: 32px; font-weight: 500; margin-bottom: 12px; }
.pd-price-row { display: flex; align-items: baseline; gap: 14px; margin-bottom: 18px; }
.pd-price-row .pd-price { font-family: var(--font-mono); font-size: 24px; font-weight: 600; }
.pd-wholesale-note { display: inline-flex; align-items: center; gap: 8px; background: var(--surface-alt); border-radius: 10px; padding: 10px 14px; font-size: 12.5px; color: var(--ink-soft); margin-bottom: 24px; }
.pd-wholesale-note strong { color: var(--brass-deep); font-family: var(--font-mono); }
.pd-desc { font-size: 14px; color: var(--ink-soft); line-height: 1.7; margin-bottom: 28px; }
.pd-meta-row { display: flex; gap: 24px; font-size: 12.5px; color: var(--muted); margin-bottom: 28px; padding-bottom: 24px; border-bottom: 1px solid var(--line); }
.pd-meta-row strong { color: var(--ink); display: block; font-size: 13px; margin-bottom: 2px; }

.variant-picker { margin-bottom: 24px; }
.variant-picker h5 { font-size: 12.5px; font-weight: 600; margin-bottom: 12px; }

.variant-options { display: flex; flex-wrap: wrap; gap: 12px; }
.variant-option {
  display: flex; flex-direction: column; align-items: center; gap: 8px;
  width: 84px; padding: 10px 8px 12px; border-radius: 14px; border: 1.5px solid var(--line);
  font-size: 12px; font-weight: 500; text-align: center;
  cursor: pointer; transition: border-color 0.16s var(--ease), background 0.16s var(--ease), transform 0.16s var(--ease);
}
.variant-option:hover { border-color: var(--brass); transform: translateY(-2px); }
.variant-option.selected { border-color: var(--ink); background: var(--surface-alt); }
.variant-option.selected .vo-swatch { box-shadow: 0 0 0 2px var(--ink); }
.variant-option.disabled { opacity: 0.4; cursor: not-allowed; }
.variant-option.disabled .vo-label { text-decoration: line-through; }
.vo-swatch { width: 56px; height: 56px; border-radius: 10px; overflow: hidden; background: var(--surface-alt); flex-shrink: 0; }
.vo-swatch img { width: 100%; height: 100%; object-fit: cover; }
.vo-swatch-empty { width: 100%; height: 100%; display: flex; align-items: center; justify-content: center; color: var(--muted); font-size: 18px; font-family: var(--font-display); }
.vo-label { line-height: 1.3; }
.vo-price { font-size: 11px; color: var(--brass-deep); font-weight: 700; }
.vo-soldout { font-size: 10px; color: var(--brick); font-weight: 600; }

.pd-add-row { display: flex; gap: 12px; align-items: flex-end; margin-bottom: 16px; }
.pd-qty-stepper { display: flex; align-items: center; border: 1.5px solid var(--line); border-radius: 10px; overflow: hidden; }
.pd-qty-stepper button { width: 40px; height: 46px; font-size: 16px; background: var(--surface); }
.pd-qty-stepper button:hover { background: var(--surface-alt); }
.pd-qty-stepper input {
  width: 52px; height: 46px; border: none; border-left: 1px solid var(--line); border-right: 1px solid var(--line);
  text-align: center; font-family: var(--font-mono); font-size: 14px; outline: none; background: var(--surface);
  -moz-appearance: textfield;
}
.pd-qty-stepper input:focus { background: var(--surface-alt); }
.pd-qty-stepper input::-webkit-outer-spin-button, .pd-qty-stepper input::-webkit-inner-spin-button { -webkit-appearance: none; margin: 0; }
.pd-stock-note { font-size: 12.5px; margin-bottom: 20px; }
.pd-stock-note.low { color: var(--brick); }
.pd-stock-note.ok { color: var(--sage); }

@media (max-width: 900px) {
  .product-detail { grid-template-columns: 1fr; gap: 30px; }
}

/* ---------- Cart ---------- */
.cart-layout { display: grid; grid-template-columns: 1fr 360px; gap: 40px; align-items: start; }
.cart-table-wrap { background: var(--surface); border: 1px solid var(--line); border-radius: 18px; overflow: hidden; }
.cart-row { display: grid; grid-template-columns: 64px 1fr auto auto auto; gap: 16px; align-items: center; padding: 18px 22px; border-bottom: 1px solid var(--line); }
.cart-row:last-child { border-bottom: none; }
.cart-row .cr-thumb { width: 64px; height: 64px; border-radius: 10px; object-fit: cover; background: var(--surface-alt); }
.cart-row .cr-name { font-weight: 600; font-size: 14px; margin-bottom: 2px; }
.cart-row .cr-sub { font-size: 12px; color: var(--muted); }
.cart-row .cr-price { font-family: var(--font-mono); font-size: 13.5px; }
.cart-row .cr-qty-form { display: flex; align-items: center; border: 1.5px solid var(--line); border-radius: 8px; overflow: hidden; }
.cart-row .cr-qty-form button { width: 30px; height: 34px; background: var(--surface); font-size: 14px; }
.cart-row .cr-qty-form input { width: 36px; height: 34px; border: none; text-align: center; font-family: var(--font-mono); font-size: 13px; }
.cart-row .cr-remove { color: var(--brick); font-size: 12px; font-weight: 600; }
.cart-row .cr-total { font-family: var(--font-mono); font-weight: 600; font-size: 14px; }

.tier-banner { border-radius: 16px; padding: 18px 20px; margin-bottom: 20px; font-size: 13.5px; }
.tier-banner.retail { background: var(--surface-alt); color: var(--ink-soft); }
.tier-banner.wholesale { background: var(--ink); color: var(--paper); }
.tier-banner.wholesale strong { color: var(--brass-bright); }
.moq-progress { height: 8px; border-radius: 20px; background: rgba(0,0,0,0.08); overflow: hidden; margin-top: 10px; }
.tier-banner.wholesale .moq-progress { background: rgba(255,255,255,0.15); }
.moq-progress-bar { height: 100%; background: var(--brass); border-radius: 20px; transition: width 0.4s var(--ease); }

.cart-summary { background: var(--surface); border: 1px solid var(--line); border-radius: 18px; padding: 24px; position: sticky; top: 96px; }
.cart-summary h3 { font-size: 16px; margin-bottom: 18px; }
.summary-row { display: flex; justify-content: space-between; font-size: 13.5px; margin-bottom: 10px; color: var(--ink-soft); }
.summary-row.total { font-size: 17px; font-weight: 700; color: var(--ink); margin-top: 14px; padding-top: 14px; border-top: 1px dashed var(--line); }
.summary-note { font-size: 12px; color: var(--muted); margin-top: 12px; }
.summary-note.warn { color: var(--brick); }

/* ---------- Checkout ---------- */
.checkout-grid { display: grid; grid-template-columns: 1.3fr 1fr; gap: 44px; align-items: start; }
.checkout-block { background: var(--surface); border: 1px solid var(--line); border-radius: 18px; padding: 26px; margin-bottom: 22px; }
.checkout-block h3 { font-size: 15.5px; margin-bottom: 18px; }
.co-field { margin-bottom: 16px; }
.co-field label { display: block; font-size: 12.5px; font-weight: 600; margin-bottom: 7px; }
.co-field input, .co-field textarea, .co-field select {
  width: 100%; padding: 12px 14px; border-radius: 10px; border: 1.5px solid var(--line);
  background: var(--surface); font-size: 14px; font-family: inherit; color: var(--ink); outline: none;
}
.co-field input:focus, .co-field textarea:focus { border-color: var(--brass); }
.co-grid-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.fulfillment-option, .payment-option {
  display: flex; align-items: flex-start; gap: 12px; border: 1.5px solid var(--line); border-radius: 12px;
  padding: 16px; margin-bottom: 12px; cursor: pointer;
}
.fulfillment-option:has(input:checked), .payment-option:has(input:checked),
.fulfillment-option.selected, .payment-option.selected { border-color: var(--ink); background: var(--surface-alt); }
.fulfillment-option input, .payment-option input { margin-top: 3px; accent-color: var(--ink); }
.fulfillment-option strong, .payment-option strong { display: block; font-size: 13.5px; margin-bottom: 2px; }
.fulfillment-option span, .payment-option span { font-size: 12px; color: var(--muted); }
.account-required-box { background: var(--surface-alt); border-radius: 16px; padding: 24px; text-align: center; }
.account-required-box h4 { font-size: 16px; margin-bottom: 8px; }
.account-required-box p { font-size: 13px; color: var(--ink-soft); margin-bottom: 18px; }

/* ---------- Order confirmation / status ---------- */
.confirm-shell { max-width: 520px; margin: 0 auto; text-align: center; }
.confirm-shell .c-icon { width: 64px; height: 64px; border-radius: 50%; margin: 0 auto 20px; display: flex; align-items: center; justify-content: center; }
.confirm-shell .c-icon.success { background: var(--sage-bg); color: var(--sage); }
.confirm-shell .c-icon.pending { background: var(--brass-10); color: var(--brass-deep); }
.confirm-shell .c-icon.error { background: var(--brick-bg); color: var(--brick); }
.confirm-shell h1 { font-size: 26px; margin-bottom: 10px; }
.confirm-shell p { color: var(--ink-soft); margin-bottom: 24px; }
.confirm-order-box { background: var(--surface); border: 1px solid var(--line); border-radius: 16px; padding: 24px; text-align: left; margin-bottom: 24px; }
.confirm-order-box .co-line { display: flex; justify-content: space-between; font-size: 13.5px; padding: 8px 0; border-bottom: 1px solid var(--line); }
.confirm-order-box .co-line:last-child { border-bottom: none; }

@media (max-width: 900px) {
  .cart-layout, .checkout-grid { grid-template-columns: 1fr; }
  .cart-row { grid-template-columns: 48px 1fr; grid-template-areas: "thumb name" "thumb price" "qty qty" "total remove"; }
}

/* ---------- Support tickets ---------- */
.ticket-category-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(140px, 1fr)); gap: 10px; margin-bottom: 4px; }
.ticket-category-option {
  border: 1.5px solid var(--line); border-radius: 12px; padding: 14px 12px; text-align: center;
  font-size: 12.5px; font-weight: 600; cursor: pointer; transition: border-color 0.16s var(--ease), background 0.16s var(--ease);
}
.ticket-category-option:hover { border-color: var(--brass); }
.ticket-category-option.selected { border-color: var(--ink); background: var(--surface-alt); }
.ticket-category-option input { display: none; }

.voice-recorder { border: 1.5px dashed var(--line); border-radius: 14px; padding: 18px; text-align: center; background: var(--surface-alt); }
.voice-recorder .rec-controls { display: flex; align-items: center; justify-content: center; gap: 14px; }
.rec-btn {
  width: 52px; height: 52px; border-radius: 50%; background: var(--brick); color: #fff;
  display: flex; align-items: center; justify-content: center; box-shadow: 0 4px 14px rgba(161,90,63,0.35);
}
.rec-btn.recording { animation: recPulse 1.2s infinite; }
@keyframes recPulse { 0%, 100% { box-shadow: 0 0 0 0 rgba(161,90,63,0.5); } 50% { box-shadow: 0 0 0 12px rgba(161,90,63,0); } }
.rec-status { font-size: 12.5px; color: var(--muted); margin-top: 10px; }
.rec-preview { margin-top: 14px; }
.rec-preview audio { width: 100%; }
.rec-clear { font-size: 12px; color: var(--brick); font-weight: 600; margin-top: 8px; }
.upload-alt { font-size: 12px; color: var(--muted); margin-top: 12px; }
.upload-alt label { color: var(--brass-deep); font-weight: 600; cursor: pointer; text-decoration: underline; }

.ticket-thread { display: flex; flex-direction: column; gap: 16px; margin-bottom: 24px; }
.ticket-message { max-width: 78%; }
.ticket-message.customer { align-self: flex-start; }
.ticket-message.admin { align-self: flex-end; }
.ticket-message .tm-bubble { border-radius: 14px; padding: 14px 16px; font-size: 13.5px; line-height: 1.6; }
.ticket-message.customer .tm-bubble { background: var(--surface); border: 1px solid var(--line); border-top-left-radius: 4px; }
.ticket-message.admin .tm-bubble { background: var(--ink); color: var(--paper); border-top-right-radius: 4px; }
.ticket-message .tm-meta { font-size: 11px; color: var(--muted); margin-bottom: 5px; display: flex; gap: 8px; }
.ticket-message.admin .tm-meta { justify-content: flex-end; }
.ticket-attachment-audio audio { width: 260px; max-width: 100%; margin-top: 8px; }
.ticket-attachment-image { margin-top: 8px; }
.ticket-attachment-image img { width: 140px; border-radius: 10px; border: 1px solid var(--line); }

.ticket-list-row { display: flex; align-items: center; justify-content: space-between; padding: 16px 20px; border-bottom: 1px solid var(--line); gap: 12px; }
.ticket-list-row:last-child { border-bottom: none; }
.ticket-list-row .tl-subject { font-weight: 600; font-size: 13.5px; }
.ticket-list-row .tl-meta { font-size: 12px; color: var(--muted); margin-top: 3px; }

/* ---------- Responsive ---------- */
@media (max-width: 1080px) {
  .category-grid { grid-template-columns: repeat(2, 1fr); }
  .product-grid { grid-template-columns: repeat(2, 1fr); }
  .value-grid { grid-template-columns: repeat(2, 1fr); }
  .footer-grid { grid-template-columns: 1fr 1fr; }
  .hero-grid { grid-template-columns: 1fr; }
  .hero-visual { max-width: 480px; }
  .wholesale-banner .wb-grid { grid-template-columns: 1fr; }
}
@media (max-width: 720px) {
  .nav-links, .hero-trust { display: none; }
  .mobile-toggle { display: flex; }
  .nav-links.mobile-open {
    display: flex; flex-direction: column; position: absolute; top: 100%; left: 0; right: 0;
    background: var(--surface); border-bottom: 1px solid var(--line); padding: 16px 32px; gap: 16px; box-shadow: var(--shadow-soft);
  }
  .hero h1 { font-size: 36px; }
  .category-grid, .product-grid, .value-grid { grid-template-columns: repeat(2, 1fr); gap: 14px; }
  .footer-grid { grid-template-columns: 1fr; }
  .wholesale-banner { padding: 32px; }
  .wholesale-banner .wb-stats { flex-direction: column; }
}