/**
 * Order
 * 
 * @author NasimNet
 * @package GhafaseBazar
 * @since 6.0
 */

.uk-grid {
    margin-left: 0;
    margin-right: 0;
}

.order-item-content {
	padding: 15px 25px !important;
	background-color: #ffff;
	margin-bottom: 10px;
	border-radius: 5px;
	box-shadow: 1px 1px 3px #ddd;
	position: relative;
	box-sizing: border-box;
}

.order-item-content img {
    border-radius: 50%;
}

.order-item-content h3 {
    font-size: 16px;
    font-weight: bold;
}

/* استایل دکمه‌های افزایش و کاهش */
.item-quantity button.decrement,
.item-quantity button.increment {
    background-color: #4CAF50;
    /* سبز برای افزایش */
    color: white;
    border: none;
    padding: 0;
    cursor: pointer;
    font-size: 16px;
    width: 40px;
    /* هم‌اندازه input */
    height: 40px;
    /* هم‌اندازه input */
    display: inline-flex;
    justify-content: center;
    align-items: center;
    box-sizing: border-box;
    /* برای هماهنگ کردن padding */
}

.item-quantity button.decrement {
    background-color: #f44336;
    /* قرمز برای کاهش */
}

.item-quantity button.increment {
    border-radius: 4px 0 0 4px;
}

/* استایل ورودی تعداد */
.item-quantity input.itemCount {
    width: 50px;
    height: 40px;
    /* هم‌اندازه با دکمه‌ها */
    text-align: center;
    font-size: 16px;
    padding: 0;
    border: 1px solid #ccc;
    border-radius: 0;
    /* بدون گوشه گرد */
    box-sizing: border-box;
    /* برای هماهنگ کردن padding */
    margin: 0 -4px;
    /* چسباندن دکمه‌ها به input */
}

/* تنظیم فاصله و چیدمان افقی */
.item-quantity {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    /* قرار دادن دکمه‌ها در سمت چپ و انتهای باکس */
    width: 100%;
    /* عرض کامل برای تنظیم درست موقعیت */
}

/* حذف دکمه‌های پیش‌فرض برای فیلد عدد */
.item-quantity input[type=number]::-webkit-outer-spin-button,
.item-quantity input[type=number]::-webkit-inner-spin-button {
    -webkit-appearance: none;
    margin: 0;
}

.item-quantity input[type=number] {
    -moz-appearance: textfield;
    /* برای فایرفاکس */
}

.btn.btn-green.add_to_cart {
    margin-right: 20px;
}

.btn.btn-green.add_to_cart i {
    margin: 0;
}

.uk-notification-message {
    font-size: 17px;
}

.uk-notification-message.uk-notification-message-success {
    background-color: rgb(102, 216, 102) !important;
    color: #fff !important;
}

.uk-notification-message.uk-notification-message-danger {
    background-color: rgb(223, 63, 14) !important;
    color: #fff !important;
}

.uk-notification-close {
    color: #fff;
}

.added {
    background-color: #f1f1f1;
}

/* Cart Icon */
.cart-container {
    position: fixed;
    bottom: 10px;
    left: 10px;
    padding: 10px;
    cursor: pointer;
    z-index: 1;
}

.cart-icon-wrapper {
    position: relative;
}

.cart-count {
    position: absolute;
    top: -5px;
    right: -5px;
    background-color: red;
    color: white;
    border-radius: 50%;
    padding: 2px 6px;
}

.cart-icon {
    width: 60px;
    height: 60px;
    background-color: #0eae6b;
    display: flex;
    justify-content: center;
    align-items: center;
}

.cart-icon i {
    font-size: 24px;
    color: #fff;
}

#cart-modal,
#order-completion-modal {
    z-index: 999999;
}

#cart-modal .uk-modal-dialog,
#order-completion-modal .uk-modal-dialog {
    border-radius: 9px;
    overflow: hidden;
}

#cart-modal .uk-modal-title,
#order-completion-modal .uk-modal-title {
    font-size: 18px;
    font-weight: bold;
    margin: 0;
}

@keyframes shake {

    0%,
    100% {
        transform: translateX(0);
    }

    10% {
        transform: translateX(-10px);
    }

    20% {
        transform: translateX(10px);
    }

    30% {
        transform: translateX(-10px);
    }

    40% {
        transform: translateX(10px);
    }

    50% {
        transform: translateX(-10px);
    }

    60% {
        transform: translateX(10px);
    }

    70% {
        transform: translateX(-10px);
    }

    80% {
        transform: translateX(10px);
    }

    90% {
        transform: translateX(-10px);
    }
}

.cart-container.shake {
    animation: shake 0.8s cubic-bezier(0.36, 0.07, 0.19, 0.97);
}

@media (max-width: 768px) {
    #cart-items-table {
        /* display: block;
        overflow-x: auto;
        white-space: nowrap; */
    }

    #cart-items-table thead {
        display: none;
        /* پنهان کردن هدر در موبایل */
    }

    #cart-items-table tbody,
    #cart-items-table tfoot {
        display: inline;
    }

    #cart-items-table tbody tr,
    #cart-items-table tfoot tr {
        display: block;
        margin-bottom: 10px;
    }

    #cart-items-table tbody td,
    #cart-items-table tfoot td {
        display: flex;
        justify-content: space-between;
        padding: 8px 10px;
        border-bottom: 1px solid #ddd;
    }

    #cart-items-table tbody td:before,
    #cart-items-table tfoot td:before {
        content: attr(data-label);
        font-weight: bold;
    }
}