/* ============================================================
 * shop.css — Shop / all-products page styles
 * Builds on top of tokens.css + main.css.
 * Do NOT duplicate chrome styles already in main.css.
 * ============================================================ */

/* ============================================================
 * Active nav link — Shop page
 * ============================================================ */
.site-nav__link--active {
  color: var(--accent);
  font-weight: var(--w-semi);
}

/* ============================================================
 * Shop page header
 * ============================================================ */
.shop-head {
  padding: 24px var(--gutter) 4px;
  text-align: center;
  max-width: 1180px;
  margin: 0 auto;
}

.shop-head__eyebrow {
  font-size: var(--text-label);
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--accent);
  margin: 0;
}

.shop-head__title {
  font-family: var(--serif);
  font-weight: var(--w-semi);
  font-size: clamp(1.6rem, 1.2rem + 2vw, 2.2rem);
  color: var(--ink);
  margin: 4px 0 0;
  line-height: 1.05;
}

.shop-head__sub {
  font-size: var(--text-body);
  color: var(--sub);
  margin: 6px 0 0;
}

/* ============================================================
 * Toolbar — filter chips + sort
 * ============================================================ */
.shop-toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding: 14px var(--gutter);
  background: var(--bg);
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
  position: sticky;
  top: 52px; /* below the sticky site-nav */
  z-index: 10;
  max-width: 100%;
}

/* ---- Filter chips ---- */
.shop-chips {
  display: flex;
  gap: 8px;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none;
  flex: 1;
  min-width: 0;
}
.shop-chips::-webkit-scrollbar { display: none; }

.shop-chip {
  flex-shrink: 0;
  font-size: var(--text-label);
  letter-spacing: 0.04em;
  padding: 8px 14px;
  border: 1px solid var(--line);
  border-radius: 999px;
  color: var(--ink);
  background: var(--bg);
  cursor: pointer;
  min-height: 36px;
  transition: background var(--dur-fast) var(--ease),
              color var(--dur-fast) var(--ease),
              border-color var(--dur-fast) var(--ease);
}
.shop-chip:hover {
  border-color: var(--ink);
}
.shop-chip--active {
  background: var(--ink);
  color: var(--bg);
  border-color: var(--ink);
}
.shop-chip:focus-visible {
  outline: 2px solid var(--ink);
  outline-offset: 2px;
}

/* ---- Sort select ---- */
.shop-sort {
  flex-shrink: 0;
}
.shop-sort__select {
  font-family: var(--sans);
  font-size: var(--text-label);
  letter-spacing: 0.04em;
  color: var(--sub);
  background: transparent;
  border: none;
  cursor: pointer;
  padding: 0;
  appearance: none;
  -webkit-appearance: none;
  /* Minimal inline chevron via background SVG */
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='10' height='6' viewBox='0 0 10 6'%3E%3Cpath d='M1 1l4 4 4-4' stroke='%23727272' stroke-width='1.2' fill='none' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 0 center;
  padding-right: 14px;
  min-height: 36px;
}
.shop-sort__select:focus-visible {
  outline: 2px solid var(--ink);
  outline-offset: 2px;
}

/* ============================================================
 * Product grid
 * ============================================================ */
.shop-grid-wrap {
  max-width: 1500px;
  margin: 0 auto;
  padding: 20px var(--gutter) clamp(32px, 5vw, 64px);
}

.shop-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: clamp(12px, 2vw, 24px);
  margin: 0;
  padding: 0;
}

@media (min-width: 720px) {
  .shop-grid {
    grid-template-columns: repeat(4, 1fr);
  }
}

/* ============================================================
 * Product card
 * ============================================================ */
.prod-card {
  display: flex;
  flex-direction: column;
}

.prod-card__link {
  display: flex;
  flex-direction: column;
  gap: 5px;
  text-decoration: none;
  color: inherit;
}
.prod-card__link:focus-visible {
  outline: 2px solid var(--ink);
  outline-offset: 2px;
  border-radius: 2px;
}

/* ---- Card image ---- */
.prod-card__media {
  position: relative;
  aspect-ratio: 4 / 5;
  overflow: hidden;
  background: var(--soft);
}

/* Hover swap: second image = on-model shot. Opacity-only (compositor-safe);
   gated to real hover devices so touch never gets a stuck half state. */
.prod-card__hover {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0;
}
@media (hover: hover) and (pointer: fine) {
  .prod-card__hover { transition: opacity 0.28s ease; }
  .prod-card__link:hover .prod-card__hover,
  .prod-card__link:focus-visible .prod-card__hover { opacity: 1; }
}
@media (prefers-reduced-motion: reduce) {
  .prod-card__hover { transition: none; }
}

.prod-card__media img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: contain;   /* ghost/white-bg shots — show full garment on white */
  background: var(--bg);
  display: block;
  transition: transform var(--dur-mid) var(--ease);
}

.prod-card__link:hover .prod-card__media img {
  transform: scale(1.03);
}

/* ---- NEW / FIT VIDEO badge ---- */
.prod-card__badge {
  position: absolute;
  top: 8px;
  left: 8px;
  background: var(--ink);
  color: var(--bg);
  font-size: 0.6rem;
  font-weight: var(--w-semi);
  letter-spacing: 0.08em;
  padding: 4px 8px;
  z-index: 2;
  pointer-events: none;
}

.prod-card__badge--new {
  background: transparent;   /* no box */
  color: #FF1493;            /* hot-pink text, matches the drop accents */
  padding: 0;
}

/* best seller — Apple-style high-voltage emoji, no text (aria-label carries the
   meaning). Count of bolts = the product's "heat" rating. */
.prod-card__badge--bestseller {
  background: transparent;
  padding: 0;
  font-size: 0.9rem;
  line-height: 1;
  letter-spacing: -1px;   /* pull the bolts together */
}

/* ---- Card info ---- */
.prod-card__info {
  display: flex;
  flex-direction: column;
  gap: 2px;
  padding-top: 2px;
}


.prod-card__row {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 2px;
}

/* colourway sits under the style name, muted so the name stays primary */
.prod-card__colour {
  font-family: var(--serif);
  font-size: 0.8125rem;      /* 13px — 2px down from --text-body */
  line-height: 1.2;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--sub);
}

.prod-card__name {
  font-family: var(--serif);
  font-size: 0.875rem;       /* 14px — 2px down from --text-name */
  line-height: 1.15;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--ink);
}

.prod-card__price {
  font-family: var(--serif);
  font-size: 0.8125rem;      /* 13px — 2px down from --text-body */
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--ink);
  flex-shrink: 0;
}

/* ============================================================
 * Hidden / filtered state
 * ============================================================ */
.prod-card[hidden] {
  display: none;
}

/* ============================================================
 * Empty state
 * ============================================================ */
.shop-empty {
  text-align: center;
  font-size: var(--text-body);
  color: var(--sub);
  padding: 48px 0;
  grid-column: 1 / -1;
}

/* ============================================================
 * Reduced motion
 * ============================================================ */
@media (prefers-reduced-motion: reduce) {
  .prod-card__media img,
  .shop-chip {
    transition: none !important;
  }
}
