.catalog-section {
    padding: 60px 0 80px 0;
    background: #F5F1F0;
    min-height: calc(100vh - 400px);
}

.container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 20px;
}

.catalog-filters {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    margin-bottom: 40px;
    justify-content: center;
}

.filter-btn {
    background: #FFFFFF;
    border: 1px solid #626262;
    color: #000000;
    padding: 10px 24px;
    border-radius: 6px;
    font-family: 'Academy', serif;
    font-size: 1rem;
    cursor: pointer;
    transition: background 0.3s, color 0.3s;
}

.filter-btn:hover,
.filter-btn.active {
    background: #00C040;
    border-color: #00C040;
    color: #FFFFFF;
}

.catalog-card-price {
    font-family: 'Academy', serif;
    font-size: 1.1rem;
    font-weight: 500;
    color: #000;
    margin-bottom: 10px;
}

.product-modal__price {
    font-family: 'Academy', serif;
    font-size: 1.15rem;
    font-weight: 500;
    color: #00C040;
    margin: 0 0 12px;
}

.catalog-card-category {
    display: inline-block;
    font-family: 'Academy', serif;
    font-size: 0.85rem;
    color: #00C040;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    margin-bottom: 8px;
}

.catalog-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
    gap: 32px;
}

.catalog-card {
    background: #FFFFFF;
    border: 1px solid #626262;
    border-radius: 8px;
    overflow: hidden;
    transition: transform 0.3s, box-shadow 0.3s;
    cursor: pointer;
}

.catalog-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.15);
}

.catalog-card-img {
    width: 100%;
    height: 260px;
    object-fit: cover;
}

.catalog-card-content {
    padding: 20px;
}

.catalog-card-title {
    font-family: 'Academy', serif;
    font-size: 1.8rem;
    font-weight: 500;
    color: #000000;
    margin-bottom: 12px;
}

.catalog-card-desc {
    font-family: 'Academy', serif;
    font-size: 1rem;
    color: #626262;
    line-height: 1.4;
    margin-bottom: 20px;
}

.catalog-card-btn {
    background: #00C040;
    color: #FFFFFF;
    border: none;
    padding: 10px 20px;
    border-radius: 6px;
    font-family: 'Academy', serif;
    font-size: 1rem;
    cursor: pointer;
    transition: background 0.3s;
}

.catalog-card-btn:hover {
    background: #009933;
}

.loading {
    text-align: center;
    padding: 60px;
    font-family: 'Academy', serif;
    font-size: 1.5rem;
    color: #626262;
}

.empty {
    text-align: center;
    padding: 60px;
    font-family: 'Academy', serif;
    font-size: 1.5rem;
    color: #626262;
}

/* Модальное окно товара */
.product-modal {
    display: none;
    position: fixed;
    inset: 0;
    z-index: 1000;
    align-items: center;
    justify-content: center;
    padding: 20px;
}

.product-modal.active {
    display: flex;
}

.product-modal__overlay {
    position: absolute;
    inset: 0;
    background: rgba(0, 0, 0, 0.65);
}

.product-modal__box {
    position: relative;
    background: #fff;
    border-radius: 12px;
    max-width: 900px;
    width: 100%;
    max-height: 90vh;
    overflow: hidden;
    display: flex;
    flex-direction: row;
    box-shadow: 0 12px 40px rgba(0, 0, 0, 0.25);
    z-index: 1;
}

.product-modal__close {
    position: absolute;
    top: 12px;
    right: 12px;
    width: 40px;
    height: 40px;
    border: none;
    background: rgba(255, 255, 255, 0.95);
    border-radius: 50%;
    font-size: 1.6rem;
    line-height: 1;
    cursor: pointer;
    z-index: 2;
    color: #333;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
}

.product-modal__close:hover {
    background: #fff;
}

.product-modal__image-wrap {
    flex: 1.2;
    min-height: 320px;
    max-height: 90vh;
    background: #f5f5f5;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 24px;
}

.product-modal__img {
    max-width: 100%;
    max-height: 70vh;
    width: auto;
    height: auto;
    object-fit: contain;
    border-radius: 4px;
}

.product-modal__info {
    flex: 1;
    padding: 32px 28px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    overflow-y: auto;
}

.product-modal__category {
    font-family: 'Academy', serif;
    font-size: 0.85rem;
    color: #00C040;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    margin-bottom: 8px;
}

.product-modal__title {
    font-family: 'Academy', serif;
    font-size: 2rem;
    font-weight: 500;
    margin: 0 0 16px;
    color: #000;
    line-height: 1.2;
}

.product-modal__desc {
    font-family: 'Academy', serif;
    font-size: 1.05rem;
    color: #626262;
    line-height: 1.5;
    margin: 0 0 24px;
}

.product-modal__btn {
    align-self: flex-start;
}

@media (max-width: 768px) {
    .catalog-grid {
        grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
        gap: 20px;
    }

    .catalog-card-title {
        font-size: 1.4rem;
    }

    .product-modal__box {
        flex-direction: column;
        max-height: 95vh;
        overflow-y: auto;
    }

    .product-modal__image-wrap {
        min-height: 240px;
        max-height: 50vh;
        padding: 16px;
    }

    .product-modal__img {
        max-height: 45vh;
    }

    .product-modal__info {
        padding: 20px;
    }

    .product-modal__title {
        font-size: 1.5rem;
    }
}