/* Shop and category-specific refinements. */
.se-store-shop .se-shop-products ul.products::before,
.se-store-shop .se-shop-products ul.products::after {
  display: none;
}

/* Keep archive card actions on the storefront palette when WooCommerce adds its button rules. */
.se-store-shop .se-product-card .se-add-cart,
.se-store-shop .se-product-card .se-add-cart.button {
  border: 1px solid var(--primary) !important;
  border-radius: 2px !important;
  background: var(--primary) !important;
  color: var(--primary-contrast) !important;
  text-decoration: none !important;
}

.se-store-shop .se-product-card .se-add-cart:hover,
.se-store-shop .se-product-card .se-add-cart:focus {
  border-color: var(--primary-hover) !important;
  background: var(--primary-hover) !important;
  color: var(--primary-contrast) !important;
}

.se-store-shop .se-pagination {
  position: relative;
  z-index: 1;
  gap: 6px;
  margin-top: 36px;
  margin-bottom: 10px;
}

.se-store-shop .se-pagination .page-numbers {
  min-width: 38px;
  height: 38px;
  border: 1px solid var(--border-strong) !important;
  border-radius: 2px;
  background: #fff !important;
  color: var(--text-primary) !important;
  text-decoration: none !important;
}

.se-store-shop .se-pagination .page-numbers.current,
.se-store-shop .se-pagination .page-numbers:hover,
.se-store-shop .se-pagination .page-numbers:focus {
  border-color: var(--primary) !important;
  background: var(--primary) !important;
  color: var(--primary-contrast) !important;
}

/* WooCommerce renders archive pagination as .woocommerce-pagination. */
.se-store-shop .woocommerce-pagination {
  position: relative;
  z-index: 1;
  display: flex;
  justify-content: center;
  width: 100%;
  max-width: 100%;
  margin-top: 36px !important;
  margin-bottom: 10px !important;
}

.se-store-shop .woocommerce-pagination ul.page-numbers {
  display: flex;
  flex-wrap: nowrap;
  justify-content: center;
  max-width: 100%;
  gap: 6px;
  margin: 0 !important;
  padding: 0 !important;
  border: 0 !important;
  background: transparent !important;
  box-shadow: none !important;
  list-style: none;
}

.se-store-shop .woocommerce-pagination li {
  margin: 0 !important;
  padding: 0 !important;
  border: 0 !important;
  background: transparent !important;
  box-shadow: none !important;
}

.se-store-shop .woocommerce-pagination a.page-numbers,
.se-store-shop .woocommerce-pagination span.page-numbers {
  min-width: 38px;
  height: 38px;
  display: inline-flex !important;
  align-items: center;
  justify-content: center;
  border: 1px solid var(--border-strong) !important;
  border-radius: 2px;
  background: #fff !important;
  color: var(--text-primary) !important;
  text-decoration: none !important;
}

.se-store-shop .woocommerce-pagination span.page-numbers.current,
.se-store-shop .woocommerce-pagination a.page-numbers:hover,
.se-store-shop .woocommerce-pagination a.page-numbers:focus {
  border-color: var(--primary) !important;
  background: var(--primary) !important;
  color: var(--primary-contrast) !important;
}

.se-store-shop .woocommerce-pagination span.page-numbers.is-disabled {
  cursor: default;
  opacity: 0.45;
}

@media (max-width: 480px) {
  .se-store-shop .se-shop-products .se-product-grid-4 {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 12px;
  }

  .se-store-shop .se-product-card {
    width: 100%;
    max-width: none;
    min-width: 0;
    margin: 0;
  }
}

@media (max-width: 767px) {
  .se-store-shop .se-shop-layout {
    grid-template-columns: minmax(0, 1fr);
  }

  .se-store-shop .se-shop-sidebar,
  .se-store-shop .se-shop-sidebar > section {
    min-width: 0;
  }

  .se-store-shop .se-shop-products {
    min-width: 0;
  }

  .se-store-shop .se-shop-sidebar > section:first-child ul {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 4px 14px;
  }

  .se-store-shop .se-shop-sidebar > section:first-child li {
    min-width: 0;
  }

  .se-store-shop .se-price-inputs {
    min-width: 0;
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .se-store-shop .se-price-inputs label {
    min-width: 0;
  }

  .se-store-shop .se-price-inputs input {
    max-width: 100%;
    box-sizing: border-box;
  }

  .se-store-shop .woocommerce-pagination {
    min-width: 0;
    box-sizing: border-box;
  }

  .se-store-shop .woocommerce-pagination ul.page-numbers {
    width: 100%;
    min-width: 0;
    box-sizing: border-box;
    gap: 3px;
  }

  .se-store-shop .woocommerce-pagination a.page-numbers,
  .se-store-shop .woocommerce-pagination span.page-numbers {
    min-width: clamp(22px, 7vw, 32px);
    height: 36px;
    padding: 0 3px;
    box-sizing: border-box;
    font-size: 14px;
    white-space: nowrap;
  }

  .se-store-shop .woocommerce-pagination span.page-numbers.dots {
    min-width: 16px;
    padding: 0 2px;
  }

  .se-store-shop .se-shop-toolbar {
    width: 100%;
    box-sizing: border-box;
    align-items: center;
    flex-direction: row;
    justify-content: space-between;
    gap: 8px;
  }

  .se-store-shop .se-shop-toolbar > .woocommerce-ordering {
    align-self: center;
    min-width: 0;
    max-width: 100%;
    margin: 0 0 0 auto;
    float: none;
  }

  .se-store-shop .se-shop-toolbar > .woocommerce-ordering select {
    width: min(160px, 52vw);
    max-width: 100%;
    margin-left: 0;
    box-sizing: border-box;
  }
}

@media (max-width: 260px) {
  .se-store-shop .woocommerce-pagination ul.page-numbers {
    gap: 1px;
  }

  .se-store-shop .woocommerce-pagination a.page-numbers,
  .se-store-shop .woocommerce-pagination span.page-numbers {
    min-width: 18px;
    height: 28px;
    padding: 0 1px;
    font-size: 11px;
  }

  .se-store-shop .woocommerce-pagination span.page-numbers.dots {
    min-width: 12px;
  }
}
