﻿.product-image-wrapper {
    position: relative;
    display: inline-block;
    overflow: hidden;
}

    .product-image-wrapper .ribbon {
        position: absolute;
        top: 12px;
        left: -35px;
        width: 140px;
        text-align: center;
        background: linear-gradient(135deg, #dc3545, #b02a37);
        color: white;
        font-weight: bold;
        font-size: 0.8rem;
        transform: rotate(-45deg);
        padding: 5px 0;
        box-shadow: 0 2px 4px rgba(0,0,0,0.3);
        z-index: 10;
        border-top: 1px solid rgba(255,255,255,0.2);
        border-bottom: 1px solid rgba(0,0,0,0.2);
        pointer-events: none;
    }

/* Цены в карточке */
.price-container {
    line-height: 1.2;
}

@media (max-width: 991.98px) {
    /* Колонки с изображением, характеристиками и ценой */
    .container-fluid .row > .col-sm-4 {
        width: 100%;
        max-width: 100%;
        margin-bottom: 1rem;
    }

    /* Изображение товара */
    .product-image-wrapper {
        text-align: center;
    }

        .product-image-wrapper img {
            max-width: 80%;
            height: auto;
            margin: 0 auto;
        }

    .img-list-hor {
        display: flex;
        flex-wrap: wrap;
        justify-content: center;
        gap: 0.5rem;
    }

        .img-list-hor a.item {
            display: inline-block;
            width: 60px;
            height: 60px;
        }

            .img-list-hor a.item img {
                width: 100%;
                height: auto;
            }

    .card.shadow-container {
        width: 100%;
    }

    .d-flex.justify-content-center.align-items-center.mt-3 {
        justify-content: center !important;
    }

    .col-sm-4 .mt-5, /* родитель блока с Barcode */
    .col-sm-4 .mt-5 .col-12 {
        text-align: center;
    }

    .modal-dialog {
        max-width: 95%;
        margin: 1.75rem auto;
    }

    /* Таблицы ингредиентов */
    table.table {
        font-size: 0.9rem;
    }

        table.table td,
        table.table th {
            word-break: break-word;
        }

    /* Таблицы с подингами */
    .table-primary td {
        padding: 0.4rem 0.5rem;
    }

    /* Адаптив вкладок */
    .nav-tabs .nav-item {
        flex: 1 1 auto;
        text-align: center;
    }

    .nav-tabs .nav-link {
        font-size: 0.9rem;
        padding: 0.5rem;
    }

    .tab-content {
        font-size: 0.9rem;
    }
}

