/*---Bascet styles---*/

.cart-page{
    padding: 0 20px;
}

.basket-is-empty{
    padding: 40px 40px;
    font-size: 16px;
    background-color: white;
    border-radius: 7px;
}

.container-cart{
    display: flex;
    justify-content: flex-end;
    width: 50%;
}
.container-cart-bsh{
    display: flex;
    justify-content: flex-end;
    width: 50%;
}

.left-cart{
    display: flex;
    gap: 7px;
}

.cart-container-icon-title{
    display: flex;
    align-items: center;
    gap: 15px;
    /*margin: 35px 0 0 0;*/
}
.cart-container-icon-title-item{
    display: flex;
    gap: 15px;
    align-items: center;
    justify-content: center;
    width: 200px;
    background-color: var(--white);
    border-radius: 7px;
    padding: 10px 15px;
    color: var(--black);
}

.cart-container-icon-title img{
    width: 25px;
}
.cart-container-icon-title span{
    font-size: 20px;
}

.cart-container-fun{
    display: flex;
    flex-direction: row;
    background-color: var(--white);
    border-radius: 7px;
    margin: 10px 0 5px 0;

}

.extended-cart-functions{
    display: flex;
    flex-direction: row;
    background-color: var(--white);
    border-radius: 7px;
    /*margin: 0 0 10px 0;*/
    gap: 10px;
    padding-left: 10px;
}

.cart-btn-container{

}



.cart-icon {

    display: flex;
    gap: 5px;

}

.cart-icon__svg {
    fill: #333;
}

.cart-icon__count {
    display: flex;

    background-color: var(--orange-color);
    color: white;
    font-size: 14px;
    font-weight: bold;
    padding: 2px 6px; /* Увеличьте немного padding для длинных чисел */
    border-radius: 7px; /* Закругление для круглого счётчика */

    text-align: center; /* Центрирование текста */
    justify-content: center; /* Горизонтальное выравнивание */
    align-items: center; /* Вертикальное выравнивание */
}

.block__product__add__backet{
    background-color: var(--white);
    border-radius: 7px;
}

.category-page__product-controls {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    padding: 15px;

}

.category-page__quantity-input {
    width: 50px;
    height: 25px;
    text-align: center;
    border: 1px solid #969696;
    border-radius: 7px;
}

.add-to-cart-btn {
    padding: 5px 10px;
    /*background-color: #007bff;*/
    color: #fff;
    border: 1px solid #969696;
    border-radius: 7px;
    cursor: pointer;
}

.add-to-cart-btn:hover {
    transform: scale(1.01);
}

.cart-table-container{
    background-color: var(--white);
}

.cart-table {
    width: 100%;
    border-collapse: collapse;
    margin-top: 20px;
    font-size: 16px;
    /*background-color: var(--white);*/
}

.cart-table th, .cart-table td {
    border-top: 1px solid #ddd;
    padding: 8px;
    text-align: center;
}

.cart-th-background{
    background-color: #f0f0f0;
    border-top-left-radius: 7px;
    border-top-right-radius: 7px;
}

.cart-table th {
    font-weight: normal !important;
    /*font-weight: bold;*/
    border: none;
}

.cart-icon img {
    filter: grayscale(100%); /* Серый цвет по умолчанию */
    transition: filter 0.3s;
}

.cart-icon img.highlighted {
    filter: none; /* Цветная иконка */
}

/*.cart-icon__count {*/
/*    background-color: #ccc; !* Серый цвет по умолчанию *!*/
/*    color: #666; !* Тёмно-серый текст *!*/
/*    transition: background-color 0.3s, color 0.3s;*/
/*}*/

.cart-icon__count.highlighted {
    background-color: var(--orange-color-light); /* Оранжевый фон */
    color: white; /* Белый текст */
}


.cart-item-image img{
    width: 80px;
    height: 80px;
    object-fit: cover;
    border-radius: 5px;
}

.cart-quantity-input{
    width: 60px;
    height: 25px;
    text-align: center;
}

.cart-product-name{
    text-align: center!important;
    padding-left: 10px;
}
.cart-product-name a{
    color: var(--black);
}


.cart-btn-container{
    width: 100%;
    display: flex;
}

.cart-container-btn-auth{
  display: flex;
  justify-content: end;
  width: 100%;
}

.cart-btn-download-pdf{
    display: flex;
    justify-content: center;
    align-items: center;
    margin: 10px 15px;
}
.cart-btn-download-pdf button{
    color: var(--black);
    border: 1px solid var(--gray-4);
    border-radius: 5px;
    cursor: pointer;
}
.btn-download-pdf{
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 5px;
}
.btn-download-pdf img{
    width: 25px;
}

.cart-table-itog{
    height: 50px;
}

.backet-total-amount{
    width: 50px;
}


.discount-input{
    width: 60px;
}

.add-kp-no-price{
    white-space: nowrap;
    display: flex;
    align-items: center;
}

.add-kp-arhiv{
    white-space: nowrap;
}

/* Правый сайт-бар корзины */

/* Контейнер боковой корзины */
.cart-sidebar {
    position: fixed;
    top: 0;
    right: -400px; /* прячем справа */
    width: 300px;
    height: 100vh;
    background: #fff;
    box-shadow: -2px 0 10px rgba(0,0,0,0.1);
    transition: right 0.3s ease;
    z-index: 9999; /* поверх всего */
    display: flex;
    flex-direction: column;
}

/* Когда корзина активна */
.cart-sidebar.open {
    right: 0;
}

/* Шапка корзины */
.cart-sidebar-header {
    padding: 0 15px;
    background-color: #f8f8f8;
    border-bottom: 1px solid #ddd;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.cart-sidebar-header h3{
    color: black;
}
/* Тело корзины */
.cart-sidebar-body {
    color: black;
    padding: 0 15px;
    overflow-y: auto;
    flex-grow: 1;
}

/* Стиль для закрытия */
.close-cart {
    background: none;
    border: none;
    font-size: 24px;
    cursor: pointer;
}
.currency {
    margin-left: 3px;
    white-space: nowrap;
}


.cart-summary{
    position: sticky !important;
    top: 0;
    background-color: white;
    padding: 5px 10px;
    font-weight: bold;
    border-bottom: 1px solid #ddd;
    margin-bottom: 10px;
}

/* Стиль товара */
.cart-item {
    display: flex;
    align-items: center;
    margin-bottom: 15px;
}

.cart-item-image {
    /*width: 50px;*/
    /*height: 50px;*/
    object-fit: cover;
    margin-right: 10px;
}

.cart-item-info {
    flex: 1;
}

.cart-item-info p {
    margin: 0;
    font-size: 14px;
}

.empty-cart {
    text-align: center;
    color: #888;
    font-size: 16px;
    margin-top: 20px;
}

.cart-item-quantity input {
    width: 50px;
}

.remove-cart-item-btn {
    background-color: #979797;
    color: #fff;
    border: none;
    padding: 5px 10px;
    cursor: pointer;
    margin-top: 5px;
}

/* Правый сайт-бар корзины */

/* Контейнер боковой корзины 2 */

.sidebar-cart-item {
    display: flex;
    align-items: flex-start;
    border-bottom: 1px solid #ddd;
    padding: 10px 0;
    gap: 10px;
}

.sidebar-cart-img img {
    width: 50px;
    height: 50px;
    object-fit: contain;
}

.sidebar-cart-info {
    flex: 1;
    font-size: 14px;
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.sidebar-cart-name {
    font-weight: bold;
}

.sidebar-cart-meta {
    display: flex;
    align-items: center;
    gap: 5px;
}

.sidebar-cart-meta input.quantity-input {
    width: 60px;
    padding: 2px 4px;
}

.sidebar-cart-unit {
    font-size: 14px;
    color: #666;
}

.sidebar-cart-price {
    font-size: 14px;
    color: #333;
}

.remove-from-cart-btn {
    align-self: flex-start;
    background-color: #f44336;
    border: none;
    border-radius: 4px;
    font-size: 12px;
    cursor: pointer;
    transition: background-color 0.2s ease;
    padding: 5px 10px;
    color: #fff;

}

/*.remove-from-cart-btn:hover {*/
/*    background-color: #d32f2f;*/
/*}*/

.sidebar-cart-total {
    font-weight: bold;
    text-align: right;
    padding-top: 10px;
}

.nowrap {
    white-space: nowrap;
}


.sidebar-cart-summary {
    position: sticky;
    top: 0;
    background: #fff;
    padding-top: 5px;
    border-bottom: 1px solid #ccc;
    z-index: 10;
}

.sidebar-cart-summary-row {
    display: flex;
    justify-content: space-between;
    font-weight: bold;
    margin-bottom: 5px;
}


/* Контейнер боковой корзины 2 */





/* Выпадающее меню пользователя */
.auth-dropdown-wrapper {
    position: relative;
    display: inline-block;
}

.auth-dropdown {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    min-width: 180px;
    background-color: #fff;
    border: 1px solid #ccc;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
    z-index: 1000;
    flex-direction: column;
    padding: 8px 0;
    border-radius: 8px;
}

.auth-dropdown a,
.auth-dropdown form button {
    display: block;
    padding: 10px 15px;
    text-decoration: none;
    color: #333;
    background: none;
    border: none;
    text-align: left;
    width: 98%;
    font-size: 14px;
    cursor: pointer;
}

.auth-dropdown a:hover,
.auth-dropdown form button:hover {
    background-color: #f5f5f5;
}

/* Показывать при наведении */
.auth-dropdown-wrapper:hover .auth-dropdown {
    display: flex;
}
/* Выпадающее меню пользователя */

.btn-download-pdf-guest{
    font-size: 14px;
    background-color: #5fc943;
    color: black;
    border: 1px solid var(--gray-4);
    border-radius: 5px;
    padding: 5px;
    width: max-content;
}

.btn-download-pdf-guest-auth{
    font-size: 14px;
    background-color: #ffa82d;
    color: black;
    border: 1px solid var(--gray-4);
    border-radius: 5px;
    padding: 5px;
    width: max-content;
}



.btn-download-pdf-user{
    font-size: 14px;
    font-weight: bold;
    background-color: #ffb03f;
    padding: 5px;
}

.btn-download-pdf-guest-img{
    width: 25px;
}









@media (max-width: 1070px) {
    .container-cart-bsh{
        display: none;
        margin: auto 10px;
        width: 70px;
    }
}

@media (max-width: 730px){

}


@media (max-width: 730px) {
    .tbody-c{
        display: flex;
        gap: 15px;
        flex-wrap: wrap;
        margin-bottom: 20px;

    }
    .cart-table{
        background-color: #f6f6f6;
    }
    .cart-th-background{
        display: none;
    }
    .cart-tr-item{
        display: flex;
        flex-direction: column;
        border: 1px solid #bbbbbb;
        background-color: #e1e1e1;
        border-radius: 7px;
        max-width: 200px;
    }
    .cart-table td{
        display: block;
        border: none;
    }
    .cart-item-img{
        width: 100px;
        height: 100px;
    }
    .bta-c{
        display: flex;
        margin-top: 10px;
        background-color: #e1e1e1;
        font-weight: bold;
        border-radius: 7px;
    }

    .cart-container-icon-title-item{
        width: auto;
    }
    .cart-btn-download-pdf{
        margin: 5px 10px;
    }
    .cart-tr-item-number{
        display: none;
    }
}

.clear-cart-btn {
    padding: 5px 10px;
    background: linear-gradient(#f44336,#f44336);
    color: #fff;
    border: none;
    border-radius: 3px;
    cursor: pointer;
    white-space: nowrap;
}

@media (max-width: 500px) {
    .cart-container-icon-title-item{
        padding: 7px 10px;
    }
    .cart-container-icon-title img {
        width: 25px;
    }
    .cart-btn-download-pdf a{
        padding: 5px 8px;
    }
    .category-page__product-controls{
        padding: 10px;
    }

    .cart-container-icon-title span{
        font-size: 16px;
    }

    .cart-tr-item{
        max-width: 150px;
    }
}

@media (max-width: 400px) {
    .btn-download-pdf-guest{
        font-size: 12px;
    }
    .cart-tr-item-none{
        display: none;
    }
}

@media (max-width: 400px) {
    .cart-tr-item{
        max-width: 130px;
    }
    .cart-tr-item-text-fz{
        font-size: 12px;
    }
}
/*---Bascet styles---*/


/*---Кнопка скачать КП как пдф с ком---*/


.btn-download-pdf-s-com{
    display: flex;
    gap: 5px;
    margin: 10px 15px;
}

.btn-download-pdf-ch-company-a{
    display: flex;
    gap: 5px;
    align-items: center;
    background-color: #82c949;
    border-radius: 5px;
    color: black;
    text-decoration: none;
    padding: 5px 10px;
}

.btn-download-ca-com-img{
    width: 25px;
}

.bnt-download-pdf-no-price{
    background-color: #d3d3d3 !important;
    display: flex;
    gap: 5px !important;

}
/*---Кнопка скачать КП как пдф с ком---*/


/*---Кнопка добавить комментарий и комментарий---*/


.show-comment-input{
    margin-left: 5px;
    font-size: 12px;
    padding: 1px;
}
.cart-item-comment{
    font-size: 0.85em;
    color: #555;
}

.comment-input{
    width: 100%;
}

.save-comment-btn{
    font-size: 12px;
    margin-top: 3px;
}

.comment-container{
    display:none;
}

/*---Кнопка добавить комментарий и комментарий---*/






.installment-block {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 14px;
    white-space: nowrap;
}

.installment-block select,
.installment-block input {
    padding: 4px 6px;
    font-size: 14px;
    border: 1px solid #ccc;
    border-radius: 4px;
}

.installment-block input {
    width: 50px !important;
    text-align: right;
}

.installment-block button {
    background: #d3d3d3;
    color: #373737;
    border: none;
    border-radius: 4px;
    padding: 5px 12px;
    cursor: pointer;
    font-size: 14px;
    transition: background 0.2s;
}

.installment-block button:hover {
    background: #999999;
}

#installment-preview {
    display: flex;
    flex-direction: row;
    color: #555;
    font-size: 13px;
    margin-left: 10px;
    gap: 10px;
    font-weight: normal;
}
.installment-preview{

}

.installment-summary{
    display: flex;
    align-items: center;
    flex-direction: row;
    margin-left: 30px;
    gap: 5px !important;
}

.installment-cont-item {
    display: flex;
    flex-direction: row;
    gap: 5px !important;
}


