/* Shop — Ring Sift / spool filters + product wall (Xylem Cookie) */

.page-shop.page-a115-headcode {
  background:
    radial-gradient(ellipse 70% 45% at 0% 0%, rgba(47, 155, 68, 0.1), transparent 55%),
    radial-gradient(ellipse 55% 40% at 100% 5%, rgba(200, 240, 74, 0.1), transparent 48%),
    linear-gradient(180deg, var(--xy-pith) 0%, var(--xy-surface) 100%);
}

.page-a115-headcode .a115-wrap {
  padding-bottom: var(--a115-space-5);
}

.page-a115-headcode .se-mast {
  margin-bottom: var(--a115-space-3);
}

.page-a115-headcode .se-mast h1 {
  font-family: var(--a115-font-display);
  font-weight: 400;
  letter-spacing: 0.02em;
}

.page-a115-headcode .hd-bay {
  display: grid;
  gap: 1.1rem;
  align-items: start;
}

/* Filter sidebar / rack */
.page-a115-headcode .hd-console {
  padding: 1rem;
  background: var(--xy-charcoal);
  color: var(--xy-pith);
  border-radius: var(--xy-radius);
  border: 3px solid var(--xy-charcoal-deep);
  box-shadow: 0 10px 24px rgba(18, 24, 16, 0.12);
  min-width: 0;
  max-width: 100%;
  overflow: hidden;
  box-sizing: border-box;
}

.page-a115-headcode .hd-form {
  display: grid;
  gap: 0.85rem;
}

.page-a115-headcode .sp-rack-top {
  display: flex;
  flex-direction: column;
  align-items: stretch;
  gap: 0.65rem;
  width: 100%;
}

.page-a115-headcode .sp-meter {
  flex: none;
  width: 100%;
  max-width: 100%;
}

.page-a115-headcode .sp-meter-label {
  display: flex;
  justify-content: space-between;
  gap: 0.5rem;
  font-size: 0.72rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.65);
  margin-bottom: 0.35rem;
}

.page-a115-headcode .sp-meter-label strong {
  color: var(--xy-lime);
}

.page-a115-headcode .sp-meter-track {
  height: 10px;
  border-radius: var(--xy-radius-pill);
  background: rgba(255, 255, 255, 0.12);
  border: 2px solid rgba(255, 255, 255, 0.2);
  overflow: hidden;
}

.page-a115-headcode .sp-meter-fill {
  height: 100%;
  width: var(--sp-fill, 20%);
  background: linear-gradient(90deg, var(--xy-sprout), var(--xy-lime));
  border-radius: inherit;
  transition: width 220ms var(--xy-ease);
}

.page-a115-headcode .sp-rack-search {
  display: flex;
  flex-direction: column;
  align-items: stretch;
  width: 100%;
  max-width: 100%;
  border: 2px solid #fff;
  border-radius: var(--xy-radius-sm);
  overflow: hidden;
  background: #fff;
}

.page-a115-headcode .sp-rack-search input {
  flex: none;
  width: 100%;
  min-width: 0;
  min-height: 44px;
  border: 0;
  padding: 0 0.85rem;
  font-family: var(--a115-font-body);
  font-size: 0.95rem;
  color: var(--xy-charcoal);
  background: transparent;
  box-sizing: border-box;
}

.page-a115-headcode .sp-rack-search button {
  border: 0;
  border-top: 2px solid var(--xy-charcoal);
  background: var(--xy-lime);
  color: var(--xy-charcoal-deep);
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  padding: 0.55rem 0.75rem;
  cursor: pointer;
  min-height: 44px;
  width: 100%;
  font-size: 0.72rem;
  line-height: 1.2;
  white-space: normal;
  box-sizing: border-box;
}

.page-a115-headcode .sp-rack-search button:hover,
.page-a115-headcode .sp-rack-search button:focus-visible {
  background: var(--xy-sprout);
  color: #fff;
  outline: none;
}

.page-a115-headcode .sp-rack-sort {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.4rem;
  width: 100%;
  color: rgba(255, 255, 255, 0.72);
  font-size: 0.72rem;
  font-weight: 800;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.page-a115-headcode .sp-rack-sort select {
  flex: 1 1 8rem;
  min-width: 0;
  min-height: 44px;
  max-width: 100%;
  border: 2px solid #fff;
  border-radius: var(--xy-radius-pill);
  background: #fff;
  color: var(--xy-charcoal);
  font-family: var(--a115-font-body);
  font-weight: 700;
  padding: 0.35rem 0.65rem;
  cursor: pointer;
}

.page-a115-headcode .sp-spools {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0.5rem;
}

.page-a115-headcode .sp-spool {
  background: rgba(255, 255, 255, 0.06);
  border: 2px solid rgba(255, 255, 255, 0.14);
  border-radius: var(--xy-radius-sm);
  overflow: hidden;
  transition: border-color 200ms var(--xy-ease), transform 200ms;
}

.page-a115-headcode .sp-spool.is-open {
  border-color: var(--xy-lime);
  transform: translateY(-2px);
}

.page-a115-headcode .sp-spool:nth-child(1).is-open { border-color: var(--xy-sprout); }
.page-a115-headcode .sp-spool:nth-child(2).is-open { border-color: var(--xy-bark); }
.page-a115-headcode .sp-spool:nth-child(3).is-open { border-color: var(--xy-lime); }

.page-a115-headcode .sp-spool-head {
  width: 100%;
  appearance: none;
  border: 0;
  background: transparent;
  color: #fff;
  display: flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.65rem 0.7rem;
  cursor: pointer;
  font-family: var(--a115-font-display);
  font-size: 0.95rem;
  letter-spacing: 0.04em;
  text-align: left;
  min-height: 44px;
}

.page-a115-headcode .sp-spool-head:hover {
  background: rgba(255, 255, 255, 0.08);
}

.page-a115-headcode .sp-spool-head:focus-visible {
  outline: 2px solid var(--xy-lime);
  outline-offset: 2px;
}

.page-a115-headcode .sp-spool-core {
  width: 20px;
  height: 20px;
  border-radius: 50%;
  background:
    radial-gradient(circle at 50% 50%, #fff 30%, transparent 31%),
    conic-gradient(var(--sp-thread, var(--xy-sprout)), var(--xy-lime), var(--sp-thread, var(--xy-sprout)));
  border: 2px solid #fff;
  flex-shrink: 0;
  transition: transform 280ms var(--xy-ease);
}

.page-a115-headcode .sp-spool:nth-child(1) { --sp-thread: var(--xy-sprout); }
.page-a115-headcode .sp-spool:nth-child(2) { --sp-thread: var(--xy-bark); }
.page-a115-headcode .sp-spool:nth-child(3) { --sp-thread: var(--xy-lime); }
.page-a115-headcode .sp-spool:nth-child(4) { --sp-thread: #6a8f5a; }

.page-a115-headcode .sp-spool.is-open .sp-spool-core {
  transform: rotate(200deg);
}

.page-a115-headcode .sp-spool-panel {
  padding: 0 0.7rem 0.75rem;
  color: rgba(255, 255, 255, 0.88);
}

.page-a115-headcode .sp-spool-panel[hidden] {
  display: none !important;
}

.page-a115-headcode .sp-spool.is-open .sp-spool-panel:not([hidden]) {
  display: block;
  animation: a115-sp-unwind 320ms var(--xy-ease) both;
}

@keyframes a115-sp-unwind {
  from { opacity: 0; transform: translateY(-6px); }
  to { opacity: 1; transform: translateY(0); }
}

.page-a115-headcode .sp-check {
  display: flex;
  gap: 0.45rem;
  align-items: flex-start;
  margin: 0.3rem 0;
  font-size: 0.84rem;
  font-weight: 600;
  cursor: pointer;
  min-height: 44px;
}

.page-a115-headcode .sp-check input {
  accent-color: var(--xy-lime);
  margin-top: 0.2rem;
  min-height: auto;
  padding: 0;
}

.page-a115-headcode .sp-note {
  margin: 0 0 0.4rem;
  font-size: 0.78rem;
  color: rgba(255, 255, 255, 0.75);
}

.page-a115-headcode .sp-price-row {
  display: flex;
  gap: 0.4rem;
  margin: 0.35rem 0 0.5rem;
}

.page-a115-headcode .sp-price-row label {
  flex: 1;
  display: flex;
  align-items: center;
  gap: 0.25rem;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.18);
  border-radius: var(--xy-radius-sm);
  padding: 0.35rem 0.45rem;
  font-size: 0.8rem;
}

.page-a115-headcode .sp-price-row input {
  width: 100%;
  min-height: 36px;
  border: 0;
  background: transparent;
  color: #fff;
  font-family: var(--a115-font-body);
  padding: 0;
}

.page-a115-headcode .sp-apply {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 40px;
  padding: 0.45rem 1rem;
  border-radius: var(--xy-radius-pill);
  border: 2px solid #fff;
  background: var(--xy-lime);
  color: var(--xy-charcoal-deep);
  font-family: var(--a115-font-display);
  font-size: 0.9rem;
  letter-spacing: 0.04em;
  cursor: pointer;
  font-weight: 400;
}

.page-a115-headcode .sp-apply:hover,
.page-a115-headcode .sp-apply:focus-visible {
  background: var(--xy-sprout);
  color: #fff;
  outline: 3px solid var(--xy-lime);
  outline-offset: 2px;
}

.page-a115-headcode .sp-clear {
  display: inline-flex;
  align-items: center;
  margin-top: 0.35rem;
  color: var(--xy-lime);
  font-weight: 800;
  text-decoration: none;
  font-size: 0.88rem;
}

.page-a115-headcode .sp-clear:hover {
  color: #fff;
  text-decoration: underline;
}

.page-a115-headcode .xy-filter-toggle {
  display: none;
  width: 100%;
  min-height: 48px;
  border: 3px solid var(--xy-charcoal-deep);
  border-radius: var(--xy-radius-pill);
  background: var(--xy-charcoal);
  color: var(--xy-lime);
  font-family: var(--a115-font-body);
  font-weight: 800;
  letter-spacing: 0.04em;
  cursor: pointer;
  align-items: center;
  justify-content: center;
}

.page-a115-headcode .xy-filter-toggle:focus-visible {
  outline: 3px solid var(--xy-lime);
  outline-offset: 2px;
}

.page-a115-headcode .xy-filter-scrim {
  display: none !important;
}

/* Toolbar + grid */
.page-a115-headcode .sp-toolbar {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: center;
  gap: 0.75rem;
  padding: 0.25rem 0;
  min-width: 0;
  position: relative;
  z-index: 0;
}

.page-a115-headcode .sp-toolbar p {
  margin: 0;
  font-weight: 800;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  font-size: 0.82rem;
  color: var(--xy-mute) !important;
}

.page-a115-headcode .sp-toolbar p strong {
  color: var(--xy-charcoal) !important;
  font-size: 1.05rem;
}

.page-a115-headcode .sp-view {
  display: flex;
  gap: 0.35rem;
}

.page-a115-headcode .sp-view button {
  min-width: 44px;
  min-height: 44px;
  border: 2px solid var(--xy-charcoal);
  border-radius: var(--xy-radius-sm);
  background: #fff;
  color: var(--xy-charcoal);
  font-weight: 800;
  cursor: pointer;
  transition: background 180ms, transform 180ms;
}

.page-a115-headcode .sp-view button.is-active {
  background: var(--xy-lime);
  border-color: var(--xy-charcoal);
}

.page-a115-headcode .sp-view button:hover:not(.is-active) {
  background: var(--xy-pith);
}

.page-a115-headcode .hd-wall {
  display: grid;
  gap: 0.85rem;
  min-width: 0;
  width: 100%;
}

.page-a115-headcode .hd-wall[data-cols="3"] { grid-template-columns: repeat(2, 1fr); }
.page-a115-headcode .hd-wall[data-cols="4"],
.page-a115-headcode .hd-wall[data-cols="5"],
.page-a115-headcode .hd-wall[data-cols="6"] { grid-template-columns: repeat(2, 1fr); }

.page-a115-headcode .hd-card {
  display: grid;
  grid-template-rows: auto 1fr auto auto;
  text-decoration: none;
  color: inherit;
  overflow: hidden;
  background: #fff;
  border: 2px solid var(--xy-charcoal);
  border-radius: var(--xy-radius);
  box-shadow: 4px 4px 0 var(--xy-line);
  transition: transform 180ms var(--xy-ease), box-shadow 180ms;
}

.page-a115-headcode .hd-card:hover {
  transform: translateY(-4px);
  box-shadow: 6px 8px 0 var(--xy-sprout);
}

.page-a115-headcode .hd-card:focus-visible {
  outline: 3px solid var(--xy-lime);
  outline-offset: 3px;
}

.page-a115-headcode .hd-card.is-sold-out {
  opacity: 0.55;
  filter: grayscale(0.25);
}

.page-a115-headcode .hd-code {
  order: -1;
  background: var(--xy-charcoal);
  color: var(--xy-lime);
  font-weight: 800;
  padding: 0.35rem 0.65rem;
  font-size: 0.72rem;
  letter-spacing: 0.04em;
  width: fit-content;
  margin: 0.5rem 0.5rem 0;
  border-radius: var(--xy-radius-sm);
}

.page-a115-headcode .hd-card img {
  width: 100%;
  aspect-ratio: 1;
  object-fit: cover;
  border-bottom: 2px solid var(--xy-line);
}

.page-a115-headcode .hd-card h3 {
  margin: 0.5rem 0.65rem 0;
  font-size: 0.92rem;
  font-weight: 800;
  line-height: 1.25;
  color: var(--xy-charcoal);
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.page-a115-headcode .hd-card strong {
  display: block;
  margin: 0.35rem 0.65rem 0.65rem;
  font-family: var(--a115-font-display);
  font-size: 1.05rem;
  font-weight: 400;
  color: var(--xy-sprout-ink);
}

.page-a115-headcode .sp-empty {
  padding: 2rem 1.25rem;
  text-align: center;
  border: 3px dashed var(--xy-line);
  border-radius: var(--xy-radius);
  background: #fff;
}

.page-a115-headcode .sp-empty p {
  margin: 0 0 1rem;
  color: var(--xy-mute);
  font-weight: 600;
}

.page-a115-headcode .sp-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 48px;
  min-width: 9rem;
  padding: 0.6rem 1.2rem;
  border-radius: var(--xy-radius-pill);
  border: 3px solid var(--xy-charcoal);
  background: var(--xy-sprout);
  color: #fff;
  font-family: var(--a115-font-display);
  font-size: 0.95rem;
  letter-spacing: 0.04em;
  text-decoration: none !important;
  font-weight: 400;
  box-shadow: 0 4px 0 var(--xy-charcoal-deep);
  transition: transform 180ms, background 180ms;
}

.page-a115-headcode .sp-btn:hover,
.page-a115-headcode .sp-btn:focus-visible {
  background: var(--xy-lime);
  color: var(--xy-charcoal-deep);
  transform: translateY(-2px);
  outline: none;
}

.page-a115-headcode .hd-bay .a36-shop-pagination {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
  margin-top: 0.5rem;
  justify-content: center;
}

.page-a115-headcode .a36-page-num,
.page-a115-headcode .a36-page-arrow,
.page-a115-headcode .a36-page-gap {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 44px;
  min-height: 44px;
  padding: 0 0.65rem;
  border: 2px solid var(--xy-line);
  border-radius: var(--xy-radius-sm);
  background: #fff;
  color: var(--xy-charcoal);
  text-decoration: none;
  font-weight: 800;
}

.page-a115-headcode .a36-page-num.is-active {
  background: var(--xy-charcoal);
  color: var(--xy-lime);
  border-color: var(--xy-charcoal);
}

.page-a115-headcode .a36-page-num:hover,
.page-a115-headcode .a36-page-arrow:hover {
  background: var(--xy-pith);
  border-color: var(--xy-sprout);
}

@media (min-width: 900px) {
  .page-a115-headcode .hd-bay {
    grid-template-columns: minmax(240px, 280px) minmax(0, 1fr);
    column-gap: 1.25rem;
    align-items: start;
  }

  .page-a115-headcode .hd-console {
    grid-column: 1;
    grid-row: 1 / span 20;
    position: relative;
    width: auto;
    max-height: none;
    overflow: visible;
  }

  .page-a115-headcode .xy-filter-toggle,
  .page-a115-headcode .xy-filter-scrim {
    display: none !important;
  }

  .page-a115-headcode .sp-spools {
    grid-template-columns: 1fr;
  }

  .page-a115-headcode .sp-toolbar {
    grid-column: 2;
    grid-row: 1;
  }

  .page-a115-headcode .hd-wall,
  .page-a115-headcode .sp-empty {
    grid-column: 2;
    grid-row: auto;
  }

  .page-a115-headcode .a36-shop-pagination {
    grid-column: 2;
  }

  .page-a115-headcode .hd-wall[data-cols="3"] { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .page-a115-headcode .hd-wall[data-cols="4"] { grid-template-columns: repeat(4, minmax(0, 1fr)); }
  .page-a115-headcode .hd-wall[data-cols="5"] { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .page-a115-headcode .hd-wall[data-cols="6"] { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}

@media (min-width: 1100px) {
  .page-a115-headcode .hd-wall[data-cols="5"] { grid-template-columns: repeat(5, minmax(0, 1fr)); }
  .page-a115-headcode .hd-wall[data-cols="6"] { grid-template-columns: repeat(6, minmax(0, 1fr)); }
}

@media (max-width: 899px) {
  .page-a115-headcode .xy-filter-toggle {
    display: inline-flex;
    grid-column: 1 / -1;
  }

  .page-a115-headcode .hd-console {
    position: relative;
    display: none;
    width: 100%;
    max-height: none;
    overflow: visible;
    border-radius: var(--xy-radius);
    grid-column: 1 / -1;
  }

  body.sp-filters-open .page-a115-headcode .hd-console {
    display: block;
  }

  .page-a115-headcode .sp-spools {
    grid-template-columns: 1fr;
  }

  .page-a115-headcode .sp-toolbar,
  .page-a115-headcode .hd-wall,
  .page-a115-headcode .sp-empty,
  .page-a115-headcode .a36-shop-pagination {
    grid-column: 1 / -1;
  }
}

@media (max-width: 640px) {
  .page-a115-headcode .hd-wall,
  .page-a115-headcode .hd-wall[data-cols="3"],
  .page-a115-headcode .hd-wall[data-cols="4"],
  .page-a115-headcode .hd-wall[data-cols="5"],
  .page-a115-headcode .hd-wall[data-cols="6"] {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (prefers-reduced-motion: reduce) {
  .page-a115-headcode .sp-spool-core,
  .page-a115-headcode .sp-meter-fill,
  .page-a115-headcode .hd-console,
  .page-a115-headcode .hd-card {
    transition: none !important;
    animation: none !important;
  }
}
