.mf-shop-main {
  width: var(--mf-wrap);
  margin: 0 auto;
  padding: 42px 0 88px;
}

.mf-collection-page {
  overflow: clip;
}

.mf-collection-hero {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(280px, 370px);
  align-items: end;
  gap: 38px;
  padding: 42px 0 36px;
  border-bottom: 1px solid var(--mf-border);
}

.mf-collection-hero-copy {
  max-width: 880px;
}

.mf-kicker,
.mf-match-card span,
.mf-filter-head p,
.mf-section-head p {
  margin: 0 0 8px;
  color: var(--mf-gold);
  font-size: 12px;
  font-weight: 850;
  letter-spacing: 0;
  text-transform: uppercase;
}

.mf-collection-hero h1 {
  margin: 0 0 14px;
  color: var(--mf-white);
  font-size: clamp(38px, 4.2vw, 68px);
  line-height: 1.02;
  font-weight: 850;
}

.mf-collection-hero-copy > p:not(.mf-kicker),
.mf-match-card p {
  margin: 0;
  color: var(--mf-muted);
  font-size: 17px;
  line-height: 1.62;
}

.mf-collection-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 20px;
}

.mf-collection-meta span {
  display: inline-flex;
  align-items: center;
  min-height: 32px;
  padding: 0 12px;
  border: 1px solid var(--mf-border);
  color: var(--mf-cream);
  font-size: 13px;
  font-weight: 800;
}

.mf-match-card {
  display: grid;
  gap: 12px;
  padding: 22px;
  border: 1px solid var(--mf-border);
  background: #11100e;
}

.mf-match-card .mf-button {
  width: 100%;
  margin-top: 4px;
}

.mf-shop-layout {
  display: grid;
  grid-template-columns: 286px minmax(0, 1fr);
  gap: 32px;
  padding-top: 30px;
}

.mf-filter-rail {
  align-self: start;
  position: sticky;
  top: 106px;
  display: grid;
  gap: 0;
  max-height: calc(100vh - 126px);
  overflow: auto;
  padding: 20px;
  border: 1px solid var(--mf-border);
  background: #0d0c0b;
}

.mf-filter-head {
  display: flex;
  align-items: start;
  justify-content: space-between;
  gap: 16px;
  padding-bottom: 16px;
}

.mf-filter-head h2 {
  margin: 0;
  color: var(--mf-white);
  font-size: 21px;
  line-height: 1.1;
  font-weight: 850;
}

.mf-filter-backdrop {
  display: none;
}

.mf-filter-head button {
  display: inline-grid;
  place-items: center;
  width: 38px;
  height: 38px;
  border: 1px solid var(--mf-border);
  background: transparent;
  color: var(--mf-white);
}

.mf-filter-head svg,
.mf-sort-toggle svg {
  width: 18px;
  height: 18px;
  fill: none;
  stroke: currentColor;
  stroke-width: 2;
}

.mf-filter-rail details {
  border-top: 1px solid var(--mf-border);
  padding: 15px 0;
}

.mf-filter-rail details:last-of-type {
  border-bottom: 1px solid var(--mf-border);
}

.mf-filter-rail summary {
  cursor: pointer;
  color: var(--mf-white);
  font-size: 13px;
  font-weight: 850;
  list-style: none;
  text-transform: uppercase;
}

.mf-filter-rail summary::-webkit-details-marker {
  display: none;
}

.mf-filter-options {
  display: grid;
  gap: 9px;
  padding-top: 12px;
}

.mf-filter-options a {
  display: grid;
  grid-template-columns: 15px minmax(0, 1fr);
  align-items: center;
  gap: 10px;
  min-height: 28px;
  color: var(--mf-muted);
  font-size: 14px;
  line-height: 1.3;
}

.mf-filter-options a span {
  width: 15px;
  height: 15px;
  border: 1px solid rgba(255, 255, 255, 0.32);
  background: transparent;
}

.mf-filter-options a:hover {
  color: var(--mf-white);
}

.mf-filter-options a:hover span {
  border-color: var(--mf-gold);
  background: var(--mf-gold);
}

.mf-filter-apply {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 42px;
  margin-top: 18px;
  border: 1px solid var(--mf-gold);
  background: var(--mf-gold);
  color: var(--mf-white);
  font-size: 12px;
  font-weight: 850;
  text-transform: uppercase;
}

.mf-product-results {
  min-width: 0;
}

.mf-shop-toolbar {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  align-items: center;
  gap: 18px;
  margin-bottom: 24px;
}

.mf-filter-toggle {
  display: inline-grid;
  place-items: center;
  min-height: 42px;
  padding: 0 16px;
  border: 1px solid var(--mf-border);
  background: transparent;
  color: var(--mf-white);
  font-size: 12px;
  font-weight: 850;
  text-transform: uppercase;
}

.mf-toolbar-count {
  display: grid;
  gap: 2px;
}

.mf-toolbar-count strong {
  color: var(--mf-white);
  font-size: 15px;
  font-weight: 850;
}

.mf-toolbar-count span {
  color: var(--mf-muted);
  font-size: 13px;
}

.mf-sort-control {
  position: relative;
  min-width: 238px;
}

.mf-sort-toggle {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  column-gap: 12px;
  width: 100%;
  min-height: 42px;
  padding: 0 13px;
  border: 1px solid var(--mf-border);
  background: #0d0c0b;
  color: var(--mf-white);
  text-align: left;
}

.mf-sort-toggle span {
  display: block;
  color: var(--mf-muted);
  font-size: 11px;
  font-weight: 800;
  text-transform: uppercase;
}

.mf-sort-toggle strong {
  display: block;
  margin-top: 1px;
  color: var(--mf-white);
  font-size: 13px;
  font-weight: 850;
}

.mf-sort-toggle svg {
  grid-row: 1 / span 2;
  grid-column: 2;
}

.mf-sort-menu {
  position: absolute;
  top: calc(100% + 8px);
  right: 0;
  z-index: 20;
  display: none;
  width: min(310px, calc(100vw - 48px));
  padding: 8px;
  border: 1px solid var(--mf-border);
  background: #11100e;
  box-shadow: var(--mf-shadow);
}

.mf-sort-control.is-open .mf-sort-menu {
  display: grid;
}

.mf-sort-menu a,
.mf-sort-links a {
  display: block;
  padding: 11px 12px;
  color: var(--mf-muted);
  font-size: 13px;
  font-weight: 800;
}

.mf-sort-menu a.is-active,
.mf-sort-menu a:hover,
.mf-sort-links a.is-active,
.mf-sort-links a:hover {
  background: rgba(159, 133, 73, 0.18);
  color: var(--mf-white);
}

.mf-sort-links {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 8px;
  flex-wrap: wrap;
}

.mf-product-grid,
.woocommerce ul.products {
  display: grid !important;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 28px 20px;
  margin: 0 !important;
  padding: 0 !important;
  list-style: none;
}

.woocommerce ul.products::before,
.woocommerce ul.products::after {
  display: none !important;
  content: none !important;
}

.mf-product-card,
.woocommerce ul.products li.product {
  position: relative;
  display: grid;
  grid-template-rows: auto 1fr;
  width: auto !important;
  min-width: 0;
  margin: 0 !important;
  float: none !important;
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: var(--mf-radius);
  background: #0f0e0c;
  overflow: hidden;
  transition: border-color 0.2s ease, transform 0.2s ease;
}

.mf-product-card:hover {
  transform: translateY(-3px);
  border-color: rgba(159, 133, 73, 0.72);
}

.mf-product-media,
.mf-product-image {
  position: relative;
  display: block;
  min-width: 0;
  overflow: hidden;
  background: #181511;
}

.mf-product-media {
  aspect-ratio: 1;
}

.mf-product-image,
.mf-product-image img,
.woocommerce ul.products li.product a img {
  width: 100%;
  height: 100%;
}

.mf-product-image img,
.woocommerce ul.products li.product a img {
  aspect-ratio: 1;
  object-fit: cover;
  margin: 0 !important;
  transition: opacity 0.22s ease, transform 0.35s ease;
}

.mf-product-image-alt {
  position: absolute;
  inset: 0;
  opacity: 0;
}

.mf-product-card:hover .mf-product-image img:first-child {
  transform: scale(1.045);
}

.mf-product-card:hover .mf-product-image-alt {
  opacity: 1;
}

.mf-card-badge,
.mf-card-wishlist {
  position: absolute;
  top: 12px;
  z-index: 2;
}

.mf-card-badge {
  left: 12px;
  display: inline-flex;
  align-items: center;
  min-height: 26px;
  padding: 0 9px;
  background: var(--mf-gold);
  color: #fff;
  font-size: 10px;
  font-weight: 850;
  text-transform: uppercase;
}

.mf-card-wishlist {
  right: 12px;
  display: grid;
  place-items: center;
  width: 36px;
  height: 36px;
  border: 1px solid rgba(255, 255, 255, 0.18);
  border-radius: 999px;
  background: rgba(0, 0, 0, 0.48);
  color: #fff;
  cursor: pointer;
}

.mf-card-wishlist:hover {
  border-color: var(--mf-gold);
  background: var(--mf-gold);
}

.mf-card-wishlist svg {
  width: 18px;
  height: 18px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.8;
}

.mf-product-copy {
  display: grid;
  grid-template-rows: auto auto auto 1fr;
  gap: 9px;
  min-width: 0;
  padding: 15px;
}

.mf-product-title {
  min-height: 42px;
  color: var(--mf-white);
  font-size: 15px;
  line-height: 1.35;
  font-weight: 850;
}

.mf-product-title:hover {
  color: var(--mf-cream);
}

.mf-product-rating {
  display: inline-flex;
  flex-wrap: wrap;
  gap: 6px;
  color: var(--mf-gold);
  font-size: 12px;
  font-weight: 850;
}

.mf-product-rating span:last-child {
  color: var(--mf-muted);
  font-weight: 700;
}

.mf-product-price {
  color: var(--mf-cream);
  font-size: 16px;
  font-weight: 850;
}

.mf-product-price del {
  margin-right: 8px;
  color: var(--mf-muted);
  font-weight: 700;
  opacity: 0.78;
}

.mf-product-price ins {
  text-decoration: none;
}

.mf-product-action {
  align-self: end;
  padding-top: 2px;
}

.mf-product-action .button,
.mf-product-copy .button {
  width: 100%;
  min-height: 39px;
  padding-inline: 12px;
  border-color: var(--mf-white);
  font-size: 12px;
  line-height: 1.1;
  white-space: normal;
  text-align: center;
}

.mf-pagination-wrap {
  margin-top: 34px;
}

.woocommerce nav.woocommerce-pagination ul {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 8px;
  margin: 0;
  padding: 0;
  border: 0;
}

.woocommerce nav.woocommerce-pagination ul li {
  border: 0;
}

.woocommerce nav.woocommerce-pagination ul li a,
.woocommerce nav.woocommerce-pagination ul li span {
  display: grid;
  place-items: center;
  min-width: 40px;
  height: 40px;
  border: 1px solid var(--mf-border);
  background: transparent;
  color: var(--mf-white);
  font-size: 13px;
  font-weight: 850;
}

.woocommerce nav.woocommerce-pagination ul li span.current,
.woocommerce nav.woocommerce-pagination ul li a:hover {
  border-color: var(--mf-gold);
  background: var(--mf-gold);
  color: var(--mf-white);
}

.mf-empty-state {
  margin: 34px auto;
}

.mf-empty-state-small {
  margin: 0;
  padding: 24px;
}

.mf-collection-related {
  padding-top: 68px;
}

.mf-collection-related .mf-section-head {
  margin-bottom: 22px;
}

.mf-collection-related .mf-section-head a {
  color: var(--mf-cream);
  font-size: 13px;
  font-weight: 850;
  text-transform: uppercase;
}

.mf-related-grid {
  grid-template-columns: repeat(4, minmax(0, 1fr));
}

.mf-back-top {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 40px;
  margin-top: 34px;
  padding: 0 16px;
  border: 1px solid var(--mf-border);
  color: var(--mf-white);
  font-size: 12px;
  font-weight: 850;
  text-transform: uppercase;
}

.mf-back-top:hover {
  border-color: var(--mf-gold);
  background: var(--mf-gold);
}

@media (max-width: 1280px) {
  .mf-shop-layout {
    grid-template-columns: 264px minmax(0, 1fr);
    gap: 24px;
  }

  .mf-product-grid,
  .woocommerce ul.products {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}

@media (max-width: 1024px) {
  .mf-collection-hero {
    grid-template-columns: 1fr;
    align-items: start;
  }

  .mf-match-card {
    max-width: 520px;
  }

  .mf-shop-layout {
    grid-template-columns: 1fr;
  }

  .mf-filter-rail {
    position: fixed;
    inset: 0 auto 0 0;
    z-index: 130;
    width: min(386px, 92vw);
    max-height: none;
    transform: translateX(-105%);
    transition: transform 0.22s ease;
  }

  .mf-filter-rail.is-open {
    transform: translateX(0);
  }

  body.mf-lock .mf-filter-backdrop {
    position: fixed;
    inset: 0;
    z-index: 120;
    display: block;
    border: 0;
    background: rgba(0, 0, 0, 0.62);
  }
}

@media (max-width: 760px) {
  .mf-shop-main {
    width: min(100vw - 28px, 680px);
    padding-top: 28px;
  }

  .mf-collection-hero {
    gap: 24px;
    padding: 26px 0 28px;
  }

  .mf-collection-hero h1 {
    font-size: 36px;
  }

  .mf-collection-hero-copy > p:not(.mf-kicker),
  .mf-match-card p {
    font-size: 15px;
  }

  .mf-match-card {
    padding: 18px;
  }

  .mf-shop-toolbar {
    grid-template-columns: 1fr;
    align-items: stretch;
  }

  .mf-filter-toggle,
  .mf-sort-control {
    width: 100%;
    min-width: 0;
  }

  .mf-sort-menu {
    left: 0;
    right: auto;
    width: 100%;
  }

  .mf-product-grid,
  .woocommerce ul.products,
  .mf-related-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 18px 12px;
  }

  .mf-product-copy {
    padding: 12px;
  }

  .mf-product-title {
    min-height: 52px;
    font-size: 13px;
  }

  .mf-product-rating {
    font-size: 11px;
  }

  .mf-product-price {
    font-size: 14px;
  }

  .mf-card-wishlist {
    width: 32px;
    height: 32px;
  }

  .mf-card-badge {
    min-height: 24px;
    font-size: 9px;
  }
}

@media (max-width: 430px) {
  .mf-product-grid,
  .woocommerce ul.products,
  .mf-related-grid {
    grid-template-columns: 1fr;
  }
}
