/* ── Kataloga izkārtojums ar sidebar ── */
.catalog-layout {
    display: flex;
    gap: 24px;
    align-items: flex-start;
    margin-top: 16px;
}

.cat-content-area {
    flex: 1;
    min-width: 0;
    display: block;
}

.cat-content-area .popular-product-list {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 20px;
}

/* ── Filtru panelis ── */
.filters-panel {
    position: fixed;
    top: 0;
    right: -320px;
    width: 300px;
    height: 100%;
    background: #fff;
    z-index: 200;
    box-shadow: -2px 0 12px rgba(0,0,0,0.18);
    transition: right 0.3s ease;
    overflow-y: auto;
    padding: 20px;
    box-sizing: border-box;
}

.filters-panel.active {
    right: 0;
}

.filters-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 16px;
}

.close-filters {
    background: none;
    border: none;
    font-size: 29px;
    cursor: pointer;
    line-height: 1;
}

.overlay {
    display: none;
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.45);
    z-index: 199;
}

.overlay.active {
    display: block;
}

.filter-section {
    margin-bottom: 20px;
}

.filter-section h3 {
    margin: 0 0 8px;
    font-size: 18px;
}

.filter-list {
    list-style: none;
    margin: 0;
    padding: 0;
}

.filter-list li {
    margin-bottom: 6px;
}

.checkbox-label {
    display: flex;
    align-items: center;
    gap: 8px;
    cursor: pointer;
    font-size: 17px;
}

.clear-filters {
    width: 100%;
    margin-top: 8px;
    padding: 8px;
    cursor: pointer;
    background: none;
    border: 1px solid #ccc;
    border-radius: 3px;
    font-size: 16px;
}

/* ── Produkta kartītes links ── */
.product-card-link {
    display: block;
    text-decoration: none;
    color: inherit;
    height: 100%;
}

/* Paslēp hover overlay pogas no vecā dizaina */
.catalog-btn {
    display: none !important;
}

/* Kartiņa — flex kolonna lai poga paliek apakšā */
.cat-content-area .popular-product-item {
    display: flex;
    flex-direction: column;
}

.cat-content-area .product-card-link {
    flex: 1;
}

/* Kartīte klikšķināma ar smooth transition */
.popular-product-item:hover,
.popular-product-item-zero:hover {
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.18);
    transform: translateY(-2px);
    transition: box-shadow 0.2s ease, transform 0.2s ease;
    cursor: pointer;
}

.popular-product-item,
.popular-product-item-zero {
    transition: box-shadow 0.2s ease, transform 0.2s ease;
}

/* Materiāla stils kartītē */
.catalog-material {
    margin: 0;
    padding: 4px 14px;
    font-size: 13px;
    color: #555;
    text-align: center;
}
.catalog-material__label {
    font-weight: 600;
    color: #333;
}

/* Cenas stils kartītē */
.popular-product-item .current-price-btn,
.popular-product-item-zero .current-price-btn {
    display: block;
    margin: 0;
    padding: 8px 14px 10px;
    font-size: 19px;
    font-weight: bold;
    color: #ffffff;
    text-decoration: none;
    text-align: center;
}

/* ── Ielikt grozā poga ── */
.card-cart-btn {
    display: block;
    width: 100%;
    padding: 9px 0;
    background-color: #ee3643;
    color: #fff;
    border: none;
    font-family: "Cuprum-Regular", Arial, sans-serif;
    font-size: 18px;
    font-weight: bold;
    cursor: pointer;
    transition: background-color .15s;
    border-radius: 0 0 3px 3px;
}

.card-cart-btn:hover {
    background-color: #ca2c37;
}

.card-cart-btn.added {
    background-color: #63a63e;
}

/* ── Kataloga galvene ── */
.catalog-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 16px 0;
}

/* ── Lappušošana ── */
.pagination {
    display: flex;
    gap: 6px;
    justify-content: center;
    padding: 20px 0;
}

.pagination-btn {
    padding: 6px 12px;
    border: 1px solid #ccc;
    background: #fff;
    cursor: pointer;
    border-radius: 3px;
}

.pagination-btn.active {
    background: #ee3643;
    color: #fff;
    border-color: #ee3643;
}

.pagination-btn.disabled {
    opacity: 0.4;
    cursor: default;
}
