/* =====================================================================
   AH STUDIO — STORE STYLES
   Scoped additions only. Reuses css/base.css tokens (--red, --ink,
   --page-bg, --glass-*, --ease) and utility classes (.glass, .glass-strong,
   .wrap, .btn, .btn-primary, .btn-glass) rather than redefining them.

   Per the design contract: no tilt/magnetic/long entrance animation on
   filters, prices, cart or checkout controls — those stay calm and
   functional. Motion here is limited to simple hover/focus feedback.
   ===================================================================== */

/* ---------- Store hero ---------- */
.store-hero{ padding-top:170px; padding-bottom:64px; position:relative; }
.store-hero h1{ font-size:clamp(32px,4.6vw,54px); line-height:1.08; margin:14px 0 16px; }
.store-hero p{ font-size:17px; color:var(--gray); max-width:560px; line-height:1.6; }

/* ---------- Breadcrumbs ---------- */
.store-breadcrumbs{ display:flex; flex-wrap:wrap; gap:6px; font-size:13px; color:var(--gray); margin-bottom:20px; }
.store-breadcrumbs a{ color:var(--gray); }
.store-breadcrumbs a:hover{ color:var(--ink); }
.store-breadcrumbs .sep{ opacity:.5; }
.store-breadcrumbs .current{ color:var(--ink); font-weight:600; }

/* ---------- Category grid / tiles ---------- */
.store-cat-grid{
  display:grid; grid-template-columns:repeat(auto-fill,minmax(180px,1fr)); gap:16px; margin-top:28px;
}
.store-cat-tile{
  border-radius:20px; overflow:hidden; position:relative; aspect-ratio:4/3;
  display:flex; align-items:flex-end; padding:16px;
  border:1px solid var(--glass-border); background:var(--glass-bg);
  transition:border-color .3s var(--ease), transform .3s var(--ease);
}
.store-cat-tile:hover{ border-color:rgba(var(--red-rgb),.35); transform:translateY(-3px); }
.store-cat-tile img{ position:absolute; inset:0; width:100%; height:100%; object-fit:cover; opacity:.55; }
.store-cat-tile span{ position:relative; font-weight:700; font-size:15px; }

/* ---------- Product grid / card ---------- */
.store-product-grid{
  display:grid; grid-template-columns:repeat(auto-fill,minmax(230px,1fr)); gap:20px; margin-top:8px;
}
.store-product-card{
  border-radius:20px; overflow:hidden; border:1px solid var(--glass-border);
  background:var(--glass-bg); display:flex; flex-direction:column;
  transition:border-color .3s var(--ease), transform .3s var(--ease), box-shadow .3s var(--ease);
}
.store-product-card:hover{ border-color:rgba(var(--red-rgb),.3); transform:translateY(-4px); box-shadow:0 16px 34px var(--shadow-color); }
.store-product-card .spc-media{
  position:relative; aspect-ratio:1/1; background:#fff; /* cleaner, less translucent background so products stay legible */
  display:flex; align-items:center; justify-content:center; overflow:hidden;
}
.store-product-card .spc-media img{ width:100%; height:100%; object-fit:contain; }
.store-product-card .spc-badge{
  position:absolute; top:10px; left:10px; font-size:11.5px; font-weight:700; letter-spacing:.02em;
  padding:5px 10px; border-radius:999px; background:var(--red); color:#fff;
}
.store-product-card .spc-badge.spc-badge-outline{ background:rgba(0,0,0,.55); color:#fff; }
.spc-body{ padding:16px; display:flex; flex-direction:column; gap:6px; flex:1; }
.spc-brand{ font-size:12px; color:var(--gray); text-transform:uppercase; letter-spacing:.04em; }
.spc-title{ font-size:14.5px; font-weight:600; line-height:1.35; }
.spc-title a{ color:var(--ink); }
.spc-price-row{ display:flex; align-items:baseline; gap:8px; margin-top:auto; }
.spc-price{ font-size:16px; font-weight:800; font-family:'Inter Tight'; }
.spc-price-was{ font-size:13px; color:var(--gray); text-decoration:line-through; }
.spc-stock{ font-size:12px; font-weight:600; }
.spc-stock.in{ color:#2fae66; }
.spc-stock.low{ color:#e0a52c; }
.spc-stock.out{ color:var(--red); }
.spc-actions{ padding:0 16px 16px; }
.spc-actions .btn{ width:100%; padding:11px 16px; font-size:13.5px; }

/* ---------- Filters / toolbar ---------- */
.store-toolbar{
  display:flex; flex-wrap:wrap; align-items:center; gap:12px; padding:14px 18px; border-radius:18px; margin-bottom:22px;
}
.store-toolbar select, .store-toolbar input[type="text"]{
  background:transparent; border:1px solid var(--glass-border); color:var(--ink);
  padding:10px 14px; border-radius:12px; font-size:14px; font-family:inherit;
}
.store-toolbar select:focus, .store-toolbar input:focus{ outline:2px solid var(--red); outline-offset:1px; }
.store-results-meta{ font-size:13.5px; color:var(--gray); margin:8px 0 18px; }

.store-filter-chips{ display:flex; flex-wrap:wrap; gap:8px; margin-bottom:16px; }
.store-filter-chip{
  display:inline-flex; align-items:center; gap:6px; font-size:12.5px; font-weight:600;
  padding:7px 12px; border-radius:999px; border:1px solid var(--glass-border); background:var(--glass-bg);
}
.store-filter-chip button{ background:none; border:none; color:var(--gray); cursor:pointer; font-size:13px; line-height:1; }

/* Mobile filter drawer: opaque (not see-through) when open, per the same
   fix already applied to the admin mobile sidebar — a blurred drawer over
   a blurred page is unreadable. */
.store-filter-drawer{
  position:fixed; inset:auto 0 0 0; z-index:60; max-height:82vh; overflow-y:auto;
  border-radius:24px 24px 0 0; padding:22px; transform:translateY(100%);
  transition:transform .35s var(--ease); background:var(--page-bg-2); border-top:1px solid var(--glass-border);
}
.store-filter-drawer.open{ transform:translateY(0); }
.store-filter-backdrop{
  position:fixed; inset:0; z-index:55; background:rgba(0,0,0,.5); opacity:0; pointer-events:none; transition:opacity .3s var(--ease);
}
.store-filter-backdrop.open{ opacity:1; pointer-events:auto; }

/* ---------- Empty / loading / error states ---------- */
.store-empty, .store-error{
  text-align:center; padding:60px 20px; color:var(--gray);
}
.store-empty svg, .store-error svg{ width:40px; height:40px; margin:0 auto 14px; opacity:.6; }
.store-skeleton{
  border-radius:20px; background:linear-gradient(90deg, var(--glass-bg) 25%, var(--glass-bg-strong) 37%, var(--glass-bg) 63%);
  background-size:400% 100%; animation:store-shimmer 1.4s ease infinite; aspect-ratio:1/1;
}
@keyframes store-shimmer{ 0%{background-position:100% 0;} 100%{background-position:0 0;} }

/* ---------- Pagination ---------- */
.store-pagination{ display:flex; justify-content:center; gap:8px; margin-top:36px; flex-wrap:wrap; }
.store-pagination button{
  min-width:38px; height:38px; border-radius:11px; border:1px solid var(--glass-border); background:var(--glass-bg);
  color:var(--ink); font-size:14px; cursor:pointer;
}
.store-pagination button.active{ background:linear-gradient(180deg,var(--red-hi),var(--red)); color:#fff; border-color:transparent; }
.store-pagination button:disabled{ opacity:.4; cursor:not-allowed; }

/* ---------- Trust strip ---------- */
.store-trust-strip{ display:flex; flex-wrap:wrap; gap:24px; justify-content:center; padding:22px; border-radius:20px; margin-top:20px; }
.store-trust-item{ display:flex; align-items:center; gap:10px; font-size:13.5px; font-weight:600; color:var(--gray); }
.store-trust-item svg{ width:18px; height:18px; stroke:var(--red); flex-shrink:0; }

/* ---------- Product detail ---------- */
.store-pdp{ padding-top:150px; }
.store-pdp-grid{ display:grid; grid-template-columns:1fr 1fr; gap:48px; align-items:start; }
@media (max-width:860px){ .store-pdp-grid{ grid-template-columns:1fr; gap:28px; } }
.store-gallery-main{ border-radius:22px; overflow:hidden; background:#fff; aspect-ratio:1/1; display:flex; align-items:center; justify-content:center; }
.store-gallery-main img{ width:100%; height:100%; object-fit:contain; }
.store-gallery-thumbs{ display:flex; gap:10px; margin-top:12px; flex-wrap:wrap; }
.store-gallery-thumbs button{
  width:64px; height:64px; border-radius:12px; overflow:hidden; border:1.5px solid transparent; padding:0; background:#fff; cursor:pointer;
}
.store-gallery-thumbs button.active{ border-color:var(--red); }
.store-gallery-thumbs img{ width:100%; height:100%; object-fit:contain; }

.store-pdp-title{ font-size:clamp(24px,3vw,34px); margin-bottom:6px; }
.store-pdp-brand{ color:var(--red); font-weight:600; font-size:13.5px; text-transform:uppercase; letter-spacing:.04em; margin-bottom:14px; }
.store-pdp-price-row{ display:flex; align-items:baseline; gap:12px; margin:14px 0; }
.store-pdp-price{ font-size:30px; font-weight:800; font-family:'Inter Tight'; }
.store-pdp-price-was{ font-size:16px; color:var(--gray); text-decoration:line-through; }

.store-variant-group{ margin:18px 0; }
.store-variant-group label{ display:block; font-size:12.5px; font-weight:700; text-transform:uppercase; letter-spacing:.04em; color:var(--gray); margin-bottom:8px; }
.store-variant-chips{ display:flex; flex-wrap:wrap; gap:8px; }
.store-variant-chip{
  padding:9px 16px; border-radius:12px; border:1.5px solid var(--glass-border); background:var(--glass-bg);
  font-size:13.5px; font-weight:600; cursor:pointer; color:var(--ink);
}
.store-variant-chip.active{ border-color:var(--red); color:var(--red); }
.store-variant-chip:disabled{ opacity:.35; text-decoration:line-through; cursor:not-allowed; }

.store-qty-stepper{ display:inline-flex; align-items:center; border:1px solid var(--glass-border); border-radius:12px; overflow:hidden; }
.store-qty-stepper button{ width:38px; height:40px; background:none; border:none; color:var(--ink); font-size:16px; cursor:pointer; }
.store-qty-stepper input{ width:44px; text-align:center; border:none; background:none; color:var(--ink); font-size:14px; }

.store-pdp-actions{ display:flex; gap:12px; margin-top:22px; flex-wrap:wrap; }
.store-pdp-actions .btn{ flex:1; min-width:160px; }

.store-pdp-meta-list{ margin-top:22px; display:flex; flex-direction:column; gap:8px; font-size:13.5px; color:var(--gray); }
.store-pdp-meta-list strong{ color:var(--ink); }

.store-tabs{ margin-top:56px; }
.store-tabs-nav{ display:flex; gap:6px; border-bottom:1px solid var(--glass-border); flex-wrap:wrap; }
.store-tabs-nav button{
  padding:12px 18px; background:none; border:none; color:var(--gray); font-size:14px; font-weight:600; cursor:pointer;
  border-bottom:2px solid transparent; margin-bottom:-1px;
}
.store-tabs-nav button.active{ color:var(--ink); border-color:var(--red); }
.store-tabs-panel{ padding:26px 4px; line-height:1.7; color:var(--gray); }

/* "Reviewed by AH Studio" editorial block */
.store-review-block{
  display:flex; gap:16px; align-items:flex-start; padding:20px; border-radius:18px; margin-top:24px;
}
.store-review-score{
  flex-shrink:0; width:56px; height:56px; border-radius:16px; background:var(--red-soft); color:var(--red);
  display:flex; align-items:center; justify-content:center; font-weight:800; font-size:18px; font-family:'Inter Tight';
}
.store-review-block h4{ font-size:14.5px; margin-bottom:4px; }
.store-review-block p{ font-size:13.5px; color:var(--gray); line-height:1.6; }
.store-review-block a{ color:var(--red); font-weight:600; font-size:13.5px; }

/* ---------- Cart / checkout: deliberately calm, no reveal/tilt/magnet ---------- */
.store-cart-line{ display:flex; gap:14px; padding:16px 0; border-bottom:1px solid var(--glass-border); align-items:center; }
.store-cart-line img{ width:64px; height:64px; object-fit:contain; background:#fff; border-radius:10px; }
.store-cart-line .scl-title{ font-size:14px; font-weight:600; }
.store-cart-line .scl-meta{ font-size:12.5px; color:var(--gray); }
.store-cart-summary{ padding:20px; border-radius:18px; }
.store-cart-summary-row{ display:flex; justify-content:space-between; font-size:14px; padding:6px 0; }
.store-cart-summary-row.total{ font-weight:800; font-size:17px; border-top:1px solid var(--glass-border); margin-top:8px; padding-top:14px; }

.store-form-field{ margin-bottom:16px; }
.store-form-field label{ display:block; font-size:12.5px; font-weight:700; text-transform:uppercase; letter-spacing:.03em; color:var(--gray); margin-bottom:6px; }
.store-form-field input, .store-form-field select, .store-form-field textarea{
  width:100%; background:var(--page-bg-2); border:1px solid var(--glass-border); color:var(--ink);
  padding:12px 14px; border-radius:12px; font-size:14.5px; font-family:inherit;
}
.store-form-field input:focus, .store-form-field select:focus, .store-form-field textarea:focus{
  outline:2px solid var(--red); outline-offset:1px;
}
.store-form-error{ color:var(--red); font-size:12.5px; margin-top:6px; font-weight:600; }

/* prefers-reduced-motion: kill even the small hover translate above */
@media (prefers-reduced-motion: reduce){
  .store-product-card, .store-cat-tile, .store-filter-drawer{ transition:none !important; }
  .store-product-card:hover, .store-cat-tile:hover{ transform:none !important; }
}
