.catalog-overview {
    position: relative;
    min-height: 100vh;
    overflow: hidden;
    padding: 180px 0 80px;
    background-image: image-set(
        url('../image/catalog-bg.webp') type('image/webp'),
        url('../image/catalog-bg.png') type('image/png')
    );
    background-position: center;
    background-size: cover;
    background-repeat: no-repeat;
}
.catalog-overview > .container {
    position: relative;
    z-index: 1;
}
.catalog-overview__grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 64px 27px;
}
.catalog-overview__grid .product-card {
    min-width: 0;
    text-align: center;
}
.catalog-overview__grid .product-card__image {
    height: 200px;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 10px;
    margin-bottom: 20px;
    border: 1px solid var(--border);
    border-radius: 20px;
    background: #fff;
}
.catalog-overview__grid .product-card__image picture {
    display: contents;
}
.catalog-overview__grid .product-card__image img {
    max-width: 100%;
    max-height: 178px;
    object-fit: contain;
}
.catalog-overview__grid .product-card .btn {
    width: 100%;
}
.catalog-overview__empty {
    margin: 0;
    font-size: 18px;
    line-height: 1.5;
}

.catalog-page {
    position: relative;
    min-height: 100vh;
    overflow: hidden;
    padding: 0 20px 80px;
    background: #fff;
}
.catalog-page__bg {
    position: absolute;
    inset: 0;
    background-image: image-set(
        url('../image/backgrounds/bg-wood-texture.webp') type('image/webp'),
        url('../image/backgrounds/bg-wood-texture.png') type('image/png')
    );
    background-position: center;
    background-size: cover;
    background-repeat: no-repeat;
}
.catalog-page__container {
    position: relative;
    z-index: 1;
    max-width: 1360px;
    margin: 100px auto 0;
    padding: 80px 0 0;
}
.catalog-page__title {
    margin: 0 0 66px;
    font-size: 39px;
    line-height: 1.35;
    font-weight: 700;
}
.catalog-page__layout {
    display: grid;
    grid-template-columns: 185px minmax(0, 1fr);
    gap: 20px;
    align-items: start;
}
.catalog-page .catalog-sidebar {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 5px;
    padding-top: 0;
}
.catalog-page .catalog-sidebar__link {
    font-size: 16px;
    line-height: 1.38;
    padding: 0 0 6px;
    transition: color .2s ease;
}
.catalog-page .catalog-sidebar__link.active {
    margin-bottom: 3px;
    font-size: 18px;
    font-weight: 500;
    border-color: #e45606;
    color: #e45606;
}
.catalog-page .catalog-sidebar__link:hover {
    color: #e45606;
}
.catalog-page .catalog-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 360px));
    justify-content: space-between;
    column-gap: 42px;
    row-gap: 45px;
}
.catalog-page .product-card {
    min-width: 0;
}
.catalog-page .product-card__image {
	position: relative;
    display: block;
    width: 100%;
    aspect-ratio: 1;
	overflow: hidden;
    border-radius: 20px;
    background: #d9d9d9;
}
.catalog-page .product-card__image-main,
.catalog-page .product-card__image-hover {
	position: absolute;
	inset: 0;
	display: block;
	background-position: center;
	background-size: cover;
	background-repeat: no-repeat;
}
.catalog-page .product-card__image-hover {
	opacity: 0;
	transition: opacity 180ms ease;
}
@media (hover: hover) and (pointer: fine) {
	.catalog-page .product-card__image--has-hover:hover .product-card__image-hover,
	.catalog-page .product-card__image--has-hover:focus-visible .product-card__image-hover {
		opacity: 1;
	}
}
.catalog-page .product-card__title {
    margin: 20px 0 14px;
    font-size: 18px;
    line-height: 1.4;
    min-height: 51px;
    font-weight: 600;
}
.catalog-page .product-card__price {
    margin-bottom: 24px;
    font-size: 18px;
    line-height: 1.4;
}
.catalog-page .product-card__price span {
    color: #e45606;
    font-weight: 500;
}
.catalog-page .product-card__price .price-tax {
    float: right;
}
.catalog-page .product-card__price del {
    color: #919191;
    font-weight: 400;
    margin-left: 20px;
}
.catalog-page .product__quantity {
    height: 40px;
    margin-bottom: 20px;
    display: grid;
    grid-template-columns: 44px 1fr 44px;
    align-items: center;
    border: 1px solid #c9c9c9;
    border-radius: 8px;
    background: #fff;
    overflow: hidden;
}
.catalog-page .product__quantity button {
    height: 100%;
    border: 0;
    background: transparent;
    color: #252525;
    font-size: 22px;
    font-weight: 500;
    cursor: pointer;
}
.catalog-page .product__quantity input {
    min-width: 0;
    height: 100%;
    border: 0;
    text-align: center;
    color: #252525;
    font-size: 18px;
    background: transparent;
}
.catalog-page .product__quantity input:focus {
    outline: none;
}
.catalog-page .product-card__actions {
    display: grid;
    grid-template-columns: minmax(0, 210px) 130px;
    gap: 20px;
}
.catalog-page .button {
    min-height: 50px;
    padding: 12px 18px;
    border: 1px solid transparent;
    border-radius: 12px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    color: #fff;
    background: linear-gradient(79deg, #e25305 0%, #ff8a12 100%);
    box-shadow: 0 0 20px rgba(116, 41, 0, .15);
    font-size: 16px;
    line-height: 1.4;
    font-weight: 600;
    white-space: nowrap;
    cursor: pointer;
}
.catalog-page .button:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 26px rgba(116, 41, 0, .35);
}
.catalog-page .button--small {
    min-height: 36px;
    min-width: 128px;
    padding: 7px 18px;
    box-shadow: 0 0 20px rgba(116, 41, 0, .4);
    font-weight: 500;
}
.catalog-page .button--outline {
    color: #252525;
    background: #fff;
    border-color: #ed670a;
    box-shadow: none;
}

.catalog-page .alert-cart-success {
    max-width: 1360px;
    margin: 0 auto 28px;
    padding: 18px 56px 18px 22px;
    border: 1px solid rgba(228, 86, 6, .22);
    border-radius: 12px;
    position: relative;
    background: #fff;
    color: #252525;
    box-shadow: 0 12px 32px rgba(116, 41, 0, .12);
}
.catalog-page .alert-cart-success__text {
    font-size: 16px;
    line-height: 1.45;
}
.catalog-page .alert-cart-success a {
    color: #e45606;
    font-weight: 600;
    text-decoration: none;
}
.catalog-page .alert-cart-success a:hover {
    text-decoration: underline;
}
.catalog-page .alert-cart-success__close {
    width: 36px;
    height: 36px;
    border: 0;
    border-radius: 50%;
    position: absolute;
    top: 50%;
    right: 14px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    transform: translateY(-50%);
    background: #f7f1ec;
    color: #e45606;
    font-size: 24px;
    line-height: 1;
    cursor: pointer;
}
.catalog-page .alert-cart-success__close:hover {
    background: #e45606;
    color: #fff;
}

.catalog-page__pagination {
    grid-column: 2;
    margin-top: 54px;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 18px;
}
.catalog-page__pagination .pagination {
    margin: 0;
    padding: 0;
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 8px;
    list-style: none;
}
.catalog-page__pagination .pagination > li {
    display: block;
}
.catalog-page__pagination .pagination > li > a,
.catalog-page__pagination .pagination > li > span {
    min-width: 42px;
    height: 42px;
    padding: 0 12px;
    border: 1px solid #ed670a;
    border-radius: 10px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: #fff;
    color: #252525;
    font-size: 16px;
    line-height: 1;
    font-weight: 500;
    text-decoration: none;
    box-shadow: none;
}
.catalog-page__pagination .pagination > li > a:hover,
.catalog-page__pagination .pagination > li.active > span {
    border-color: transparent;
    background: linear-gradient(79deg, #e25305 0%, #ff8a12 100%);
    color: #fff;
    box-shadow: 0 8px 22px rgba(116, 41, 0, .22);
}
.catalog-page__results {
    color: #555;
    font-size: 14px;
    line-height: 1.4;
    text-align: center;
}

@media (max-width: 1240px) {
    .catalog-overview__grid {
        grid-template-columns: repeat(3, minmax(0, 1fr));
        gap: 42px 22px;
    }
    .catalog-page__layout {
        grid-template-columns: 180px minmax(0, 1fr);
        gap: 40px;
    }
    .catalog-page .catalog-grid {
        grid-template-columns: repeat(2, minmax(0, 360px));
        justify-content: start;
    }
}

@media (max-width: 900px) {
    .catalog-overview {
        padding: 148px 0 64px;
    }
    .catalog-overview__grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
    .catalog-overview__grid .product-card__image {
        height: 190px;
    }
    .catalog-page__container {
        padding-top: 48px;
    }
    .catalog-page__title {
        margin-bottom: 34px;
        font-size: 34px;
    }
    .catalog-page__layout {
        display: block;
    }
    .catalog-page .catalog-sidebar {
        flex-direction: row;
        gap: 12px;
        overflow-x: auto;
        margin-bottom: 28px;
        padding-bottom: 8px;
    }
    .catalog-page .catalog-sidebar__link {
        flex: 0 0 auto;
        padding: 8px 12px;
        border: 1px solid #e5e5e5;
        border-radius: 999px;
        background: #fff;
    }
    .catalog-page .catalog-sidebar__link.active {
        margin: 0;
        font-size: 16px;
    }
    .catalog-page .catalog-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 30px 20px;
    }

    .catalog-page__pagination {
        margin-top: 40px;
    }
}

@media (max-width: 640px) {
    .catalog-overview {
        padding: 125px 0 50px;
        background-position: center top;
    }
    .catalog-overview > .container {
        width: calc(100% - 42px);
    }
    .catalog-overview .section-title {
        margin-bottom: 25px;
        font-size: 30px;
        line-height: 1.1;
    }
    .catalog-overview__grid {
        gap: 20px 42px;
    }
    .catalog-overview__grid .product-card__image {
        height: 150px;
        margin-bottom: 15px;
        padding: 7px;
        border-radius: 10px;
    }
    .catalog-overview__grid .product-card__image img {
        max-height: 126px;
    }
    .catalog-overview__grid .product-card .btn {
        width: 100%;
        min-height: 44px;
        padding: 10px 12px;
        border-radius: 7px;
        font-size: 16px;
    }
    .catalog-page {
        padding: 0 14px 56px;
    }
    .catalog-page .button--small {
        min-width: 110px;
    }
    .catalog-page__title {
        font-size: 30px;
    }
    .catalog-page .catalog-grid {
        grid-template-columns: 1fr;
    }
    .catalog-page .product-card__actions {
        grid-template-columns: 1fr;
        gap: 12px;
    }
}

@media (max-width: 420px) {
    .catalog-overview__grid {
        gap: 30px 20px;
    }
}
