/*
Theme Name: Nordic Store
Theme URI: http://example.com/nordic-store
Author: Your Name
Author URI: http://example.com
Description: A minimalist, Tailwind-based WooCommerce theme.
Version: 1.0
License: GNU General Public License v2 or later
License URI: http://www.gnu.org/licenses/gpl-2.0.html
Text Domain: nordic-store
Tags: e-commerce, woocommerce, minimalist
*/

/* Admin bar fix */
body.admin-bar nav {
  top: 32px;
}

@media screen and (max-width: 782px) {
  body.admin-bar nav {
    top: 46px;
  }
}

/* WooCommerce Product Grid - Force Custom Layout */
.woocommerce ul.products {
  list-style: none !important;
  padding: 0 !important;
  margin: 0 !important;
  display: grid !important;
  grid-template-columns: repeat(4, 1fr) !important;
  gap: 2rem !important;
  width: 100% !important;
}

@media (max-width: 1024px) {
  .woocommerce ul.products {
    grid-template-columns: repeat(2, 1fr) !important;
  }
}

@media (max-width: 640px) {
  .woocommerce ul.products {
    grid-template-columns: 1fr !important;
  }
}

.woocommerce ul.products li.product {
  margin: 0 !important;
  padding: 0 !important;
  list-style: none !important;
  width: 100% !important;
  float: none !important;
  clear: none !important;
}

/* Ensure first item starts at grid position 1 */
.woocommerce ul.products li.product:first-child {
  grid-column-start: 1 !important;
}

/* Hide WooCommerce default styling - keep only our custom card */
.woocommerce ul.products li.product .woocommerce-loop-product__link,
.woocommerce ul.products li.product .woocommerce-loop-category__title,
.woocommerce ul.products li.product > a img,
.woocommerce ul.products li.product .price,
.woocommerce ul.products li.product .star-rating,
.woocommerce ul.products li.product > .button {
  display: none !important;
}

/* Show only our product-card */
.woocommerce ul.products li.product .product-card {
  display: block !important;
}

/* Remove WooCommerce default button styles */
.woocommerce .button {
  background: none !important;
  border: none !important;
}

/* WooCommerce Sale Badge */
.woocommerce span.onsale {
  background-color: #f59e0b;
  min-height: 32px;
  min-width: 32px;
  line-height: 32px;
  font-weight: 700;
}

/* Line clamp utility */
.line-clamp-2 {
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

/* Fix any WooCommerce clearfix issues */
.woocommerce::after,
.woocommerce ul.products::after {
  content: none !important;
  display: none !important;
}
