/* ================================ */
/* ===== Category Products CSS ===== */
/* ================================ */

/* Force the product grid to be in 4 columns */
.category-products-section .product-grid {
    display: grid !important;
    grid-template-columns: repeat(5, 1fr); /* 5 columns */
    column-gap: 20px; /* Horizontal gap */
    row-gap: 15px; /* Vertical spacing */
    align-items: stretch;
    padding: 0; /* Remove padding */
    margin: 0; /* Remove margin */
}

/* Make product cards slightly smaller */
.category-products-section .product-card {
    background: #fff;
    border-radius: 8px;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
    overflow: hidden;
    text-align: center;
    padding: 5px; /* Smaller padding */
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    height: 100%;
    max-width: 100%; /* Ensure cards are uniform */
    margin: 0; /* Remove margin */
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.category-products-section .product-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 8px 16px rgba(0, 0, 0, 0.2);
}

/* Force the image and layout to behave as intended */
.category-products-section .product-grid .product-card img {
    max-width: 100%;
    height: auto;
    max-height: 150px; /* Consistent image height */
    object-fit: contain; /* Fit images without distortion */
}

/* Styling the product title */
.category-products-section .product-title {
    font-size: 14px;
    font-weight: 500;
    margin: 10px 0;
}

/* Styling the price */
.category-products-section .product-price {
    font-size: 16px;
    font-weight: bold;
    color: #000;
}

/* Button for "Megtekintés" */
.category-products-section .product-button {
    background-color: #fff;
    color: #000000;
    padding: 8px 10px;
    text-decoration: none;
    border-radius: 5px;
    border: 1px solid #000;
    margin-top: 10px;
    font-weight: 500;
    transition: all 0.5s ease;
}

.category-products-section .product-button:hover {
    background-color: #f0f0f0;
    border-color: #333; 
    color: #333;
}

/* Responsive: 2 columns on tablet screens */
@media (max-width: 1024px) {
    .category-products-section .product-grid {
        grid-template-columns: repeat(2, 1fr); /* 2-column grid */
    }
}

/* Responsive: 2 columns on mobile screens */
@media (max-width: 768px) {
    .category-products-section .section-title {
        font-size: 18px;
    }

    .category-products-section .product-grid {
        grid-template-columns: repeat(2, 1fr); /* 2-column grid on mobile */
    }
}

/* Small Mobile Devices */
@media (max-width: 480px) {
    .category-products-section .product-title {
        font-size: 12px;
    }

    .category-products-section .shop-now-button {
        padding: 8px 16px;
    }
}

/* Wrapper stays centered */
.category-products-section .load-more-wrap{
  text-align:center;
  margin-top:40px;
}

/* Button style to match the black CTA */
.category-products-section .load-more-btn{
  display:inline-block;
  background:#000;
  color:#fff;
  border:0;
  border-radius:8px;          /* adjust to 6–10px if your theme uses a different radius */
  padding:12px 22px;
  font-weight:600;
  line-height:1.1;
  cursor:pointer;
  box-shadow:0 2px 8px rgba(0,0,0,.15);
  transition:background .2s ease, transform .08s ease, box-shadow .2s ease;
}
.category-products-section .load-more-btn:hover{
  background:#111;
  box-shadow:0 4px 14px rgba(0,0,0,.2);
}
.category-products-section .load-more-btn:active{
  transform:translateY(1px);
}
.category-products-section .load-more-btn:disabled{
  opacity:.6;
  cursor:not-allowed;
}

/* Optional: make newly loaded cards fade in */
.category-products-section .product-card{
  animation:fadeIn .25s ease;
}
@keyframes fadeIn{
  from{opacity:0; transform:translateY(6px)}
  to{opacity:1; transform:none}
}