.products-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
    gap: 2rem;
    padding: 20px!important;
    margin: 0 auto!important;
    max-width: 1100px;
}
.product-title{
    margin-bottom: 0px!important;
    line-height: 0.5!important;
}
.product-card {
    background: #fff;
    padding: 15px!important;
    border-radius: 8px;
    -webkit-box-shadow: 1px 0px 16px 0px rgba(34, 60, 80, 0.79);
    -moz-box-shadow: 1px 0px 16px 0px rgba(34, 60, 80, 0.79);
    box-shadow: 1px 0px 16px 0px rgba(34, 60, 80, 0.79);
}

.product-thumbnail img {
    width: 100%;
    height: auto;
    border-radius: 5px;
}

/* Страница товара */
.product-single {
    max-width: 1200px;
    margin: 0 auto!important;
    padding: 2rem!important;
}

.product-thumbnail img {
    width: 100%;
    height: auto;
    border-radius: 8px;
}

.product-meta {
    background: #f8f9fa;
    padding: 1rem!important;
    margin: 2rem 0!important;
    border-radius: 5px;
}

/* Галерея */
.product-gallery {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 1rem;
    margin: 2rem 0!important;
}

/* Связанные товары */
.related-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 1rem;
}

.product-view-btn {
    display: inline-block;
    padding: 12px 30px!important;
    margin-top: 15px!important;
    font-weight: 600!important;
    text-decoration: none;
    color: #fff !important;
    background: linear-gradient(45deg, #6B46C1, #d142e1);
    border-radius: 30px;
    transition: all 0.3s ease;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
    border: none;
    cursor: pointer;
    text-align: center;
}

.product-view-btn:hover {
    background: linear-gradient(45deg, #553C9A, #3182CE);
    transform: translateY(-2px);
    box-shadow: 0 6px 12px rgba(0, 0, 0, 0.15);
}

/* Для правильного позиционирования в карточке */
.product-flex-item {
    display: flex;
    flex-direction: column;
}
.p-price {
    margin-top: auto!important; /* Прижимает кнопку к низу карточки */
    align-self: flex-end; /* Выравнивание по правому краю */
}
.product-view-btn {
    align-self: flex-end; /* Выравнивание по правому краю */
}





/* Новые стили для карточки товара   -----------------------------------*/

/* Основной контейнер */
.single-product-container {
    max-width: 1200px;
    margin: 0 auto!important;
    padding: 40px 20px!important;
}

.product-grid > div{
    border-radius:20px;
    -webkit-box-shadow: 0px 0px 20px 0px rgba(34, 60, 80, 0.44);
-moz-box-shadow: 0px 0px 20px 0px rgba(34, 60, 80, 0.44);
box-shadow: 0px 0px 20px 0px rgba(34, 60, 80, 0.44);
}

.product-grid {
    display: flex;
    gap: 50px;
}

/* Левая колонка (60%) */
.product-left {
    flex: 0 1 60%;
    padding:20px!important;
}

/* Правая колонка (40%) */
.product-right {
    flex: 0 1 40%;
    position: sticky;
    top: 100px;
    align-self: flex-start;
    overflow: hidden; /* Обрезает выходящие части */
}

.product-main-image img {
    width: 100%;
    height: auto;
}

.price-box {
    background: #f8f9fa;
    padding: 25px!important;
    border-radius: 12px;
    margin-top: 30px!important;
}

.product-price {
    font-size: 36px;
    color: #2d3748;
    font-weight: 700;
    margin-bottom: 20px!important;
}


.product-meta {
    margin-top: 30px!important;
    padding: 20px!important;
    border: 1px solid #e2e8f0;
}

.meta-item {
    margin-bottom: 12px!important;
    font-size: 14px;
}

.meta-item span {
    font-weight: 600;
    color: #4a5568;
}

/* Адаптивность */
@media (max-width: 1024px) {
    .product-grid {
        flex-direction: column-reverse;
        gap: 30px;
    }

    .product-right {
        position: static;
    }

    .price-box {
        margin-top: 20px!important;
    }
}


@media (max-width: 768px) {
    .product-gallery,
    .related-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    .product-view-btn {
        width: 100%; /* Полная ширина на мобильных */
        padding: 10px 20px;
    }
    .products-grid{
        grid-template-columns: 49% 49%;
        gap: 5px;
        padding: 10px !important;
    }
    .product-card{
        padding: 5px !important;
        -webkit-box-shadow: 1px 0px 5px 0px rgba(34, 60, 80, 0.79);
        -moz-box-shadow: 1px 0px 5px 0px rgba(34, 60, 80, 0.79);
        box-shadow: 1px 0px 5px 0px rgba(34, 60, 80, 0.79);
    }
    .p-price {
        margin-top: 1px;
        align-self: flex-start;
    }
    .product-card.product-flex-item a{
        font-size: 0.7em;
    }
    .product-card.product-flex-item h4{
        margin-top: auto;
    }
    
}




