/**
 * Miko Side Cart, Glowing Animation, Toast Notification & Full Desktop/Mobile Cart UX
 * Cho May Anh - Modern E-Commerce UI
 */

/* ==========================================================================
   1. GLOW & ANIMATION FOR HEADER CART BUTTON
   ========================================================================== */
.miko-cart-btn {
    position: relative;
    cursor: pointer;
    transition: transform 0.25s ease, color 0.25s ease;
}

/* Glowing Aura on Add-To-Cart */
.miko-cart-btn.miko-cart-glowing {
    animation: mikoCartPulse 1.2s cubic-bezier(0.25, 1, 0.5, 1);
}

.miko-cart-btn.miko-cart-glowing .miko-cart-icon {
    animation: mikoIconBounce 0.8s ease;
}

.miko-cart-btn.miko-cart-glowing .miko-cart-count {
    animation: mikoBadgePop 0.8s cubic-bezier(0.34, 1.56, 0.64, 1);
    background: #ff4500 !important;
    box-shadow: 0 0 12px rgba(255, 69, 0, 0.9), 0 0 20px rgba(255, 130, 54, 0.6);
}

@keyframes mikoCartPulse {
    0% {
        transform: scale(1);
        filter: drop-shadow(0 0 0 rgba(255, 130, 54, 0));
    }
    30% {
        transform: scale(1.12);
        filter: drop-shadow(0 0 14px rgba(255, 130, 54, 0.9)) drop-shadow(0 0 25px rgba(255, 180, 0, 0.6));
    }
    60% {
        transform: scale(1.04);
        filter: drop-shadow(0 0 8px rgba(255, 130, 54, 0.6));
    }
    100% {
        transform: scale(1);
        filter: drop-shadow(0 0 0 rgba(255, 130, 54, 0));
    }
}

@keyframes mikoIconBounce {
    0%, 100% { transform: translateY(0) rotate(0deg); }
    25% { transform: translateY(-4px) rotate(-8deg) scale(1.1); }
    50% { transform: translateY(2px) rotate(6deg) scale(1.05); }
    75% { transform: translateY(-2px) rotate(-3deg); }
}

@keyframes mikoBadgePop {
    0% { transform: scale(1); }
    40% { transform: scale(1.45); }
    70% { transform: scale(0.9); }
    100% { transform: scale(1); }
}

/* ==========================================================================
   2. TOAST NOTIFICATION
   ========================================================================== */
#miko-toast-container {
    position: fixed;
    top: 24px;
    right: 24px;
    z-index: 9999999;
    display: flex;
    flex-direction: column;
    gap: 12px;
    pointer-events: none;
    max-width: 400px;
    width: calc(100vw - 48px);
}

.miko-toast-item {
    pointer-events: auto;
    background: #ffffff;
    border-radius: 14px;
    padding: 14px 18px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.15), 0 2px 8px rgba(0, 0, 0, 0.08);
    border-left: 4px solid #2ecc71;
    display: flex;
    align-items: center;
    gap: 14px;
    transform: translateX(120%);
    opacity: 0;
    transition: transform 0.4s cubic-bezier(0.16, 1, 0.3, 1), opacity 0.3s ease;
    position: relative;
    overflow: hidden;
}

.miko-toast-item.miko-toast-visible {
    transform: translateX(0);
    opacity: 1;
}

.miko-toast-item.miko-toast-leaving {
    transform: translateX(120%);
    opacity: 0;
}

.miko-toast-icon {
    width: 36px;
    height: 36px;
    min-width: 36px;
    border-radius: 50%;
    background: #e8f8f0;
    color: #2ecc71;
    display: flex;
    align-items: center;
    justify-content: center;
}

.miko-toast-icon svg {
    width: 20px;
    height: 20px;
    stroke: #2ecc71;
}

.miko-toast-content {
    flex: 1;
    min-width: 0;
}

.miko-toast-title {
    font-size: 14px;
    font-weight: 700;
    color: #1a1a1a;
    margin: 0 0 2px 0;
    line-height: 1.3;
}

.miko-toast-desc {
    font-size: 12px;
    color: #666666;
    margin: 0;
    line-height: 1.4;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.miko-toast-close {
    background: none;
    border: none;
    cursor: pointer;
    color: #999;
    padding: 4px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 18px;
    line-height: 1;
    transition: color 0.2s;
}

.miko-toast-close:hover {
    color: #333;
}

.miko-toast-progress {
    position: absolute;
    bottom: 0;
    left: 0;
    height: 3px;
    background: #2ecc71;
    width: 100%;
    transform-origin: left;
    animation: mikoToastProgress 3.5s linear forwards;
}

@keyframes mikoToastProgress {
    0% { transform: scaleX(1); }
    100% { transform: scaleX(0); }
}

/* ==========================================================================
   3. SIDE CART DRAWER OVERLAY & CONTAINER
   ========================================================================== */
#miko-side-cart-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background: rgba(0, 0, 0, 0.55);
    backdrop-filter: blur(4px);
    -webkit-backdrop-filter: blur(4px);
    z-index: 999998;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.35s ease, visibility 0.35s ease;
}

#miko-side-cart-overlay.miko-active {
    opacity: 1;
    visibility: visible;
}

#miko-side-cart-drawer {
    position: fixed;
    top: 0;
    right: 0;
    width: 420px;
    max-width: 90vw;
    height: 100vh;
    height: 100dvh;
    background: #ffffff;
    z-index: 999999;
    box-shadow: -8px 0 35px rgba(0, 0, 0, 0.22);
    transform: translateX(100%);
    transition: transform 0.4s cubic-bezier(0.16, 1, 0.3, 1);
    display: flex;
    flex-direction: column;
    overflow: hidden;
    font-family: inherit;
    box-sizing: border-box;
}

#miko-side-cart-drawer.miko-open {
    transform: translateX(0);
}

/* ==========================================================================
   4. DRAWER HEADER
   ========================================================================== */
.miko-drawer-header {
    padding: 18px 22px;
    background: var(--color, #004564);
    color: #ffffff;
    display: flex;
    align-items: center;
    justify-content: space-between;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    position: relative;
    z-index: 2;
}

.miko-drawer-title-wrap {
    display: flex;
    align-items: center;
    gap: 10px;
}

.miko-drawer-header-icon {
    display: flex;
    align-items: center;
    justify-content: center;
}

.miko-drawer-header-icon svg {
    stroke: #ffffff;
}

.miko-drawer-title {
    font-size: 16px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    color: #ffffff;
    margin: 0;
}

.miko-drawer-count-badge {
    background: var(--color-second, #FF8236);
    color: #ffffff;
    font-size: 12px;
    font-weight: 700;
    padding: 2px 8px;
    border-radius: 20px;
    margin-left: 4px;
}

.miko-drawer-close-btn {
    background: rgba(255, 255, 255, 0.15);
    border: none;
    color: #ffffff;
    width: 32px;
    height: 32px;
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.2s ease, transform 0.2s ease;
    font-size: 20px;
    line-height: 1;
    padding: 0;
}

.miko-drawer-close-btn:hover {
    background: rgba(255, 255, 255, 0.3);
    transform: rotate(90deg);
}

/* ==========================================================================
   5. DRAWER BODY & CART ITEMS
   ========================================================================== */
.miko-drawer-body {
    flex: 1;
    overflow-y: auto;
    overflow-x: hidden;
    padding: 16px 20px;
    background: #fbfbfb;
    position: relative;
}

.miko-drawer-body::-webkit-scrollbar {
    width: 6px;
}

.miko-drawer-body::-webkit-scrollbar-thumb {
    background: #ddd;
    border-radius: 4px;
}

.miko-cart-items-list {
    display: flex;
    flex-direction: column;
    gap: 14px;
    margin: 0;
    padding: 0;
    list-style: none;
}

.miko-cart-item {
    background: #ffffff;
    border: 1px solid #edf0f5;
    border-radius: 12px;
    padding: 12px;
    display: flex;
    gap: 12px;
    position: relative;
    transition: border-color 0.2s ease, box-shadow 0.2s ease, opacity 0.2s ease;
}

.miko-cart-item:hover {
    border-color: #dbe2ea;
    box-shadow: 0 4px 14px rgba(0, 0, 0, 0.05);
}

.miko-cart-item.miko-item-loading {
    opacity: 0.5;
    pointer-events: none;
}

.miko-cart-item-thumb {
    width: 72px;
    height: 72px;
    min-width: 72px;
    border-radius: 8px;
    overflow: hidden;
    background: #f5f5f5;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 1px solid #f0f0f0;
}

.miko-cart-item-thumb img {
    width: 100%;
    height: 100%;
    object-fit: contain;
}

.miko-cart-item-info {
    flex: 1;
    min-width: 0;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
}

.miko-cart-item-title {
    font-size: 13.5px;
    font-weight: 600;
    line-height: 1.35;
    color: #222222;
    text-decoration: none;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    padding-right: 20px;
    transition: color 0.2s ease;
}

.miko-cart-item-title:hover {
    color: var(--color-second, #FF8236);
}

.miko-cart-item-meta {
    font-size: 11.5px;
    color: #777777;
    margin-top: 2px;
    line-height: 1.3;
}

.miko-cart-item-bottom {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-top: 8px;
}

.miko-cart-item-price {
    font-size: 14px;
    font-weight: 700;
    color: #e53935;
}

/* Quantity selector inside drawer */
.miko-cart-qty-wrap {
    display: inline-flex;
    align-items: center;
    border: 1px solid #dcdfe6;
    border-radius: 6px;
    overflow: hidden;
    background: #fff;
    height: 32px;
}

.miko-qty-btn {
    width: 32px;
    height: 100%;
    background: #f7f8fa;
    border: none;
    font-size: 16px;
    font-weight: 700;
    color: #555;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.15s ease, color 0.15s ease;
    padding: 0;
    user-select: none;
    touch-action: manipulation;
    -webkit-tap-highlight-color: transparent;
}

.miko-qty-btn:hover,
.miko-qty-btn:active {
    background: var(--color-second, #FF8236);
    color: #fff;
}

.miko-qty-input {
    width: 36px;
    height: 100%;
    border: none;
    border-left: 1px solid #dcdfe6;
    border-right: 1px solid #dcdfe6;
    text-align: center;
    font-size: 13px;
    font-weight: 700;
    color: #222;
    padding: 0;
    -moz-appearance: textfield;
}

.miko-qty-input::-webkit-outer-spin-button,
.miko-qty-input::-webkit-inner-spin-button {
    -webkit-appearance: none;
    margin: 0;
}

/* Remove button inside drawer */
.miko-cart-item-remove {
    position: absolute;
    top: 8px;
    right: 8px;
    width: 24px;
    height: 24px;
    border-radius: 50%;
    background: transparent;
    border: none;
    color: #aaa;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 16px;
    line-height: 1;
    transition: background 0.2s, color 0.2s;
    padding: 0;
    touch-action: manipulation;
}

.miko-cart-item-remove:hover {
    background: #ffebee;
    color: #d32f2f;
}

/* Empty cart state */
.miko-drawer-empty {
    text-align: center;
    padding: 50px 20px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    height: 100%;
}

.miko-empty-icon {
    width: 80px;
    height: 80px;
    border-radius: 50%;
    background: #f0f4f8;
    color: #8da2b5;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 16px;
}

.miko-empty-icon svg {
    width: 40px;
    height: 40px;
    stroke: #8da2b5;
}

.miko-empty-title {
    font-size: 16px;
    font-weight: 700;
    color: #333;
    margin: 0 0 6px 0;
}

.miko-empty-desc {
    font-size: 13px;
    color: #777;
    margin: 0 0 20px 0;
    max-width: 240px;
    line-height: 1.4;
}

.miko-empty-shop-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 10px 24px;
    background: var(--color-second, #FF8236);
    color: #fff !important;
    font-size: 14px;
    font-weight: 600;
    border-radius: 8px;
    text-decoration: none !important;
    transition: background 0.25s ease, transform 0.15s ease;
}

.miko-empty-shop-btn:hover {
    background: #e66f25;
    transform: translateY(-2px);
    color: #fff !important;
}

.miko-drawer-footer {
    padding: 18px 22px;
    background: #ffffff;
    border-top: 1px solid #edf0f5;
    box-shadow: 0 -4px 16px rgba(0, 0, 0, 0.04);
}

.miko-drawer-subtotal-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 14px;
}

.miko-drawer-subtotal-label {
    font-size: 14px;
    font-weight: 600;
    color: #555555;
    text-transform: uppercase;
}

.miko-drawer-subtotal-value {
    font-size: 18px;
    font-weight: 800;
    color: #e53935;
}

.miko-drawer-buttons {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.miko-btn-drawer-checkout {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    height: 44px;
    background: var(--color-second, #FF8236);
    color: #ffffff !important;
    font-size: 15px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    border-radius: 8px;
    text-decoration: none !important;
    border: none;
    cursor: pointer;
    transition: background 0.25s ease, transform 0.15s ease, box-shadow 0.25s ease;
    box-shadow: 0 4px 12px rgba(255, 130, 54, 0.35);
}

.miko-btn-drawer-checkout:hover {
    background: #e66f25;
    color: #ffffff !important;
    transform: translateY(-1px);
    box-shadow: 0 6px 16px rgba(255, 130, 54, 0.45);
}

.miko-btn-drawer-cart {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    height: 38px;
    background: #f2f4f8;
    color: var(--color, #004564) !important;
    font-size: 13.5px;
    font-weight: 600;
    border-radius: 8px;
    text-decoration: none !important;
    border: 1px solid #e1e5ee;
    cursor: pointer;
    transition: background 0.2s ease, color 0.2s ease, border-color 0.2s ease;
}

.miko-btn-drawer-cart:hover {
    background: #e8ecf3;
    color: var(--color, #004564) !important;
    border-color: #cbd3e0;
}

/* ==========================================================================
   6. UNIVERSAL QUANTITY STEPPER (CART & PRODUCT PAGES)
   ========================================================================== */
.quantity.miko-stepper-ready {
    display: inline-flex !important;
    align-items: center !important;
    border: 1px solid #dcdfe6 !important;
    border-radius: 8px !important;
    overflow: hidden !important;
    background: #ffffff !important;
    height: 38px !important;
    padding: 0 !important;
    margin: 0 !important;
    box-sizing: border-box !important;
}

.quantity.miko-stepper-ready .miko-qty-stepper-btn {
    width: 36px !important;
    height: 100% !important;
    background: #f5f7fa !important;
    border: none !important;
    color: #444444 !important;
    font-size: 18px !important;
    font-weight: 700 !important;
    cursor: pointer !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    padding: 0 !important;
    margin: 0 !important;
    user-select: none !important;
    touch-action: manipulation !important;
    -webkit-tap-highlight-color: transparent !important;
    transition: background 0.15s ease, color 0.15s ease !important;
}

.quantity.miko-stepper-ready .miko-qty-stepper-btn:hover,
.quantity.miko-stepper-ready .miko-qty-stepper-btn:active {
    background: var(--color-second, #FF8236) !important;
    color: #ffffff !important;
}

.quantity.miko-stepper-ready input.qty {
    width: 44px !important;
    height: 100% !important;
    border: none !important;
    border-left: 1px solid #dcdfe6 !important;
    border-right: 1px solid #dcdfe6 !important;
    text-align: center !important;
    font-size: 14px !important;
    font-weight: 700 !important;
    color: #222222 !important;
    padding: 0 !important;
    margin: 0 !important;
    background: #ffffff !important;
    -moz-appearance: textfield !important;
}

.quantity.miko-stepper-ready input.qty::-webkit-outer-spin-button,
.quantity.miko-stepper-ready input.qty::-webkit-inner-spin-button {
    -webkit-appearance: none !important;
    margin: 0 !important;
}

.woocommerce-cart-form.miko-cart-loading {
    opacity: 0.6;
    pointer-events: none;
    transition: opacity 0.2s ease;
}

/* ==========================================================================
   7. CHECKOUT PROGRESS STEPS BAR (CART & CHECKOUT PAGES)
   ========================================================================== */
.miko-cart-progress-steps {
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 15px auto 30px auto;
    max-width: 760px;
    padding: 16px 24px;
    background: #ffffff;
    border-radius: 14px;
    border: 1px solid #edf0f5;
    box-shadow: 0 2px 12px rgba(0, 0, 0, 0.03);
    grid-column: 1 / -1 !important;
    width: 100% !important;
    box-sizing: border-box;
}

.miko-step-item {
    display: flex;
    align-items: center;
    gap: 10px;
    color: #94a3b8;
    font-size: 14px;
    font-weight: 600;
    transition: color 0.25s ease;
}

.miko-step-icon {
    width: 34px;
    height: 34px;
    border-radius: 50%;
    background: #f1f5f9;
    color: #94a3b8;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.25s ease;
}

.miko-step-item.active {
    color: var(--color, #004564);
    font-weight: 700;
}

.miko-step-item.active .miko-step-icon {
    background: var(--color, #004564);
    color: #ffffff;
    box-shadow: 0 3px 10px rgba(0, 69, 100, 0.25);
}

.miko-step-item.completed {
    color: #10b981;
}

.miko-step-item.completed .miko-step-icon {
    background: #ecfdf5;
    color: #10b981;
}

.miko-step-divider {
    flex: 1;
    height: 2px;
    background: #e2e8f0;
    margin: 0 16px;
    position: relative;
    max-width: 80px;
    border-radius: 2px;
}

.miko-step-divider.active {
    background: #10b981;
}

/* ==========================================================================
   8. WOOCOMMERCE NOTICES & ALERTS
   ========================================================================== */
.woocommerce-notices-wrapper {
    grid-column: 1 / -1 !important;
    width: 100% !important;
}

.woocommerce-message, 
.woocommerce-info, 
.woocommerce-error {
    border-radius: 12px !important;
    padding: 14px 20px 14px 48px !important;
    font-size: 14px !important;
    line-height: 1.5 !important;
    margin-bottom: 24px !important;
    display: block !important;
    position: relative !important;
    border: 1px solid transparent !important;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.04) !important;
    clear: both !important;
}

.woocommerce-message::before,
.woocommerce-info::before,
.woocommerce-error::before {
    position: absolute !important;
    left: 18px !important;
    top: 14px !important;
    margin: 0 !important;
}

.woocommerce-message {
    background: #f0fdf4 !important;
    color: #15803d !important;
    border-color: #bbf7d0 !important;
    border-left: 4px solid #22c55e !important;
}

.woocommerce-message a.button {
    background: #15803d !important;
    color: #ffffff !important;
    border-radius: 6px !important;
    padding: 6px 14px !important;
    font-weight: 600 !important;
    font-size: 13px !important;
    float: right !important;
    margin: -2px 0 0 12px !important;
}

.woocommerce-error {
    background: #fef2f2 !important;
    color: #b91c1c !important;
    border-color: #fecaca !important;
    border-left: 4px solid #ef4444 !important;
}

.woocommerce-info {
    background: #f0f9ff !important;
    color: #0369a1 !important;
    border-color: #bae6fd !important;
    border-left: 4px solid #0ea5e9 !important;
}

/* ==========================================================================
   9. FULL DESKTOP UX/UI FOR CART PAGE (/cart/) (Screen >= 769px)
   ========================================================================== */
@media (min-width: 769px) {
    .woocommerce-cart .woocommerce {
        display: grid !important;
        grid-template-columns: minmax(0, 1fr) 390px !important;
        grid-gap: 32px !important;
        align-items: start !important;
        max-width: 1240px !important;
        margin: 10px auto 40px auto !important;
        padding: 0 15px !important;
        box-sizing: border-box !important;
    }

    .woocommerce-cart .woocommerce-cart-form {
        grid-column: 1 !important;
        width: 100% !important;
        background: #ffffff !important;
        border-radius: 16px !important;
        box-shadow: 0 4px 24px rgba(0, 0, 0, 0.04) !important;
        border: 1px solid #e8edf2 !important;
        overflow: hidden !important;
        padding: 0 !important;
        box-sizing: border-box !important;
    }

    .woocommerce-cart .cart-collaterals {
        grid-column: 2 !important;
        width: 100% !important;
        position: sticky !important;
        top: 90px !important;
    }

    .woocommerce-cart .cart-collaterals .cart_totals {
        width: 100% !important;
        float: none !important;
        background: #ffffff !important;
        border-radius: 16px !important;
        box-shadow: 0 8px 30px rgba(0, 0, 0, 0.05) !important;
        border: 1px solid #e8edf2 !important;
        padding: 24px 26px !important;
        margin: 0 !important;
        box-sizing: border-box !important;
    }

    /* Cart Table on PC */
    .woocommerce-cart .woocommerce-cart-form table.shop_table,
    .woocommerce-cart-form table.shop_table {
        display: table !important;
        border-collapse: collapse !important;
        width: 100% !important;
        table-layout: auto !important;
        border: none !important;
        margin-bottom: 0 !important;
    }

    .woocommerce-cart .woocommerce-cart-form table.shop_table thead,
    .woocommerce-cart-form table.shop_table thead {
        display: table-header-group !important;
        background: #f8fafc !important;
        border-bottom: 1px solid #e2e8f0 !important;
    }

    .woocommerce-cart .woocommerce-cart-form table.shop_table thead tr,
    .woocommerce-cart-form table.shop_table thead tr {
        display: table-row !important;
    }

    .woocommerce-cart .woocommerce-cart-form table.shop_table thead th,
    .woocommerce-cart-form table.shop_table thead th {
        display: table-cell !important;
        background: transparent !important;
        color: #475569 !important;
        font-size: 13px !important;
        font-weight: 700 !important;
        text-transform: uppercase !important;
        letter-spacing: 0.5px !important;
        padding: 16px 20px !important;
        border: none !important;
        text-align: left !important;
    }

    .woocommerce-cart-form table.shop_table thead th.product-quantity,
    .woocommerce-cart-form table.shop_table thead th.product-price,
    .woocommerce-cart-form table.shop_table thead th.product-subtotal {
        text-align: center !important;
    }

    .woocommerce-cart .woocommerce-cart-form table.shop_table tbody,
    .woocommerce-cart-form table.shop_table tbody {
        display: table-row-group !important;
    }

    .woocommerce-cart .woocommerce-cart-form table.shop_table tbody tr,
    .woocommerce-cart-form table.shop_table tbody tr {
        display: table-row !important;
    }

    .woocommerce-cart .woocommerce-cart-form table.shop_table tbody td,
    .woocommerce-cart-form table.shop_table tbody td {
        display: table-cell !important;
        padding: 20px !important;
        border-bottom: 1px solid #f1f5f9 !important;
        vertical-align: middle !important;
        border-top: none !important;
        border-left: none !important;
        border-right: none !important;
        transition: background-color 0.2s ease !important;
    }

    .woocommerce-cart-form table.shop_table tbody tr.cart_item:hover td {
        background-color: #fafcfe !important;
    }

    .woocommerce-cart-form table.shop_table tbody tr:last-child td {
        border-bottom: none !important;
    }

    /* Product Thumbnail on PC */
    .woocommerce-cart-form table.shop_table td.product-thumbnail {
        width: 90px !important;
        min-width: 90px !important;
        padding-right: 0 !important;
    }

    .woocommerce-cart-form table.shop_table td.product-thumbnail img {
        width: 80px !important;
        height: 80px !important;
        object-fit: contain !important;
        border-radius: 10px !important;
        background: #f8fafc !important;
        border: 1px solid #e2e8f0 !important;
        padding: 4px !important;
        transition: transform 0.25s ease, box-shadow 0.25s ease !important;
        display: block !important;
    }

    .woocommerce-cart-form table.shop_table td.product-thumbnail:hover img {
        transform: scale(1.05) !important;
        box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08) !important;
    }

    /* Product Name */
    .woocommerce-cart-form table.shop_table td.product-name {
        padding-left: 16px !important;
    }

    .woocommerce-cart-form table.shop_table td.product-name a {
        font-size: 15px !important;
        font-weight: 600 !important;
        color: #1e293b !important;
        line-height: 1.4 !important;
        text-decoration: none !important;
        transition: color 0.2s ease !important;
        display: -webkit-box !important;
        -webkit-line-clamp: 2 !important;
        -webkit-box-orient: vertical !important;
        overflow: hidden !important;
    }

    .woocommerce-cart-form table.shop_table td.product-name a:hover {
        color: var(--color-second, #FF8236) !important;
    }

    .woocommerce-cart-form table.shop_table td.product-name .variation {
        font-size: 12px !important;
        color: #64748b !important;
        margin-top: 6px !important;
    }

    /* Pricing */
    .woocommerce-cart-form table.shop_table td.product-price {
        font-size: 14.5px !important;
        font-weight: 600 !important;
        color: #64748b !important;
        text-align: center !important;
        white-space: nowrap !important;
    }

    .woocommerce-cart-form table.shop_table td.product-quantity {
        text-align: center !important;
    }

    .woocommerce-cart-form table.shop_table td.product-subtotal {
        font-size: 16.5px !important;
        font-weight: 800 !important;
        color: #e53935 !important;
        text-align: center !important;
        white-space: nowrap !important;
    }

    /* Remove button on PC */
    .woocommerce-cart-form table.shop_table td.product-remove {
        width: 50px !important;
        min-width: 50px !important;
        max-width: 50px !important;
        text-align: center !important;
    }

    .woocommerce-cart-form table.shop_table td.product-remove a.remove {
        width: 32px !important;
        height: 32px !important;
        border-radius: 50% !important;
        background: #f8fafc !important;
        color: #94a3b8 !important;
        display: inline-flex !important;
        align-items: center !important;
        justify-content: center !important;
        font-size: 18px !important;
        line-height: 1 !important;
        text-decoration: none !important;
        transition: all 0.2s ease !important;
        border: 1px solid #e2e8f0 !important;
    }

    .woocommerce-cart-form table.shop_table td.product-remove a.remove:hover {
        background: #fee2e2 !important;
        color: #ef4444 !important;
        border-color: #fecaca !important;
        transform: scale(1.1) !important;
    }

    /* Actions & Coupon row */
    .woocommerce-cart .woocommerce-cart-form table.shop_table tbody tr td.actions,
    .woocommerce-cart-form table.shop_table td.actions {
        display: table-cell !important;
        width: 100% !important;
        padding: 18px 24px !important;
        background: #fafafa !important;
        border-top: 1px solid #edf0f5 !important;
        vertical-align: middle !important;
        box-sizing: border-box !important;
        text-align: left !important;
    }

    .woocommerce-cart-form table.shop_table td.actions::after {
        content: "" !important;
        display: table !important;
        clear: both !important;
    }

    .woocommerce-cart-form table.shop_table td.actions .coupon {
        display: inline-flex !important;
        align-items: center !important;
        gap: 10px !important;
        float: right !important;
    }

    .woocommerce-cart-form table.shop_table td.actions .coupon input.input-text {
        height: 42px !important;
        border-radius: 9px !important;
        border: 1.5px solid #cbd5e1 !important;
        padding: 0 16px !important;
        font-size: 13.5px !important;
        width: 200px !important;
        background: #ffffff !important;
        box-sizing: border-box !important;
        transition: border-color 0.2s ease !important;
    }

    .woocommerce-cart-form table.shop_table td.actions .coupon input.input-text:focus {
        border-color: var(--color, #004564) !important;
        outline: none !important;
    }

    .woocommerce-cart-form table.shop_table td.actions .coupon button.button {
        height: 42px !important;
        padding: 0 20px !important;
        border-radius: 9px !important;
        background: var(--color, #004564) !important;
        color: #ffffff !important;
        font-weight: 700 !important;
        font-size: 13.5px !important;
        border: none !important;
        cursor: pointer !important;
        transition: all 0.25s ease !important;
        box-shadow: 0 2px 8px rgba(0, 69, 100, 0.2) !important;
        white-space: nowrap !important;
    }

    .woocommerce-cart-form table.shop_table td.actions .coupon button.button:hover {
        background: var(--color-second, #FF8236) !important;
        box-shadow: 0 4px 12px rgba(255, 130, 54, 0.3) !important;
        transform: translateY(-1px) !important;
    }

    .woocommerce-cart-form table.shop_table td.actions button[name="update_cart"] {
        display: none !important;
    }

    /* Continue shopping button */
    .miko-continue-shopping-btn {
        display: inline-flex !important;
        align-items: center !important;
        justify-content: center !important;
        gap: 8px !important;
        font-size: 14px !important;
        font-weight: 600 !important;
        color: var(--color, #004564) !important;
        text-decoration: none !important;
        padding: 10px 20px !important;
        border-radius: 9px !important;
        background: #ffffff !important;
        border: 1.5px solid #cbd5e1 !important;
        white-space: nowrap !important;
        width: auto !important;
        min-width: max-content !important;
        max-width: none !important;
        line-height: 1.4 !important;
        box-sizing: border-box !important;
        float: left !important;
        transition: all 0.25s ease !important;
        cursor: pointer !important;
    }

    .miko-continue-shopping-btn span {
        white-space: nowrap !important;
        display: inline-block !important;
        font-size: 14px !important;
        font-weight: 600 !important;
        color: inherit !important;
        width: auto !important;
        flex-shrink: 0 !important;
        line-height: 1.4 !important;
    }

    .miko-continue-shopping-btn svg {
        width: 16px !important;
        height: 16px !important;
        min-width: 16px !important;
        flex-shrink: 0 !important;
        stroke: currentColor !important;
        display: inline-block !important;
        vertical-align: middle !important;
    }

    .miko-continue-shopping-btn:hover {
        background: var(--color, #004564) !important;
        color: #ffffff !important;
        border-color: var(--color, #004564) !important;
        transform: translateY(-1px) !important;
        box-shadow: 0 4px 12px rgba(0, 69, 100, 0.2) !important;
    }

    /* Cart Totals styling */
    .cart-collaterals .cart_totals h2 {
        font-size: 17px !important;
        font-weight: 800 !important;
        color: var(--color, #004564) !important;
        text-transform: uppercase !important;
        letter-spacing: 0.5px !important;
        padding-bottom: 14px !important;
        margin-bottom: 18px !important;
        border-bottom: 2px solid #f1f5f9 !important;
        display: flex !important;
        align-items: center !important;
        gap: 8px !important;
    }

    .cart-collaterals .cart_totals table.shop_table {
        width: 100% !important;
        border: none !important;
        margin-bottom: 18px !important;
    }

    .cart-collaterals .cart_totals table.shop_table tr th {
        font-size: 14px !important;
        color: #64748b !important;
        font-weight: 600 !important;
        padding: 12px 0 !important;
        border: none !important;
        background: transparent !important;
        text-align: left !important;
    }

    .cart-collaterals .cart_totals table.shop_table tr td {
        font-size: 15.5px !important;
        color: #1e293b !important;
        font-weight: 700 !important;
        text-align: right !important;
        padding: 12px 0 !important;
        border: none !important;
    }

    .cart-collaterals .cart_totals table.shop_table tr.order-total th {
        font-size: 15.5px !important;
        font-weight: 800 !important;
        color: #1e293b !important;
        border-top: 2px dashed #cbd5e1 !important;
        padding-top: 16px !important;
    }

    .cart-collaterals .cart_totals table.shop_table tr.order-total td {
        font-size: 22px !important;
        font-weight: 900 !important;
        color: #e53935 !important;
        border-top: 2px dashed #cbd5e1 !important;
        padding-top: 16px !important;
    }

    .cart-collaterals .cart_totals .wc-proceed-to-checkout .checkout-button {
        width: 100% !important;
        height: 52px !important;
        background: linear-gradient(135deg, #FF8236 0%, #ff6200 100%) !important;
        color: #ffffff !important;
        font-size: 16px !important;
        font-weight: 800 !important;
        text-transform: uppercase !important;
        letter-spacing: 0.6px !important;
        border-radius: 10px !important;
        display: flex !important;
        align-items: center !important;
        justify-content: center !important;
        text-decoration: none !important;
        border: none !important;
        box-shadow: 0 6px 20px rgba(255, 130, 54, 0.4) !important;
        transition: all 0.25s ease !important;
    }

    .cart-collaterals .cart_totals .wc-proceed-to-checkout .checkout-button:hover {
        background: linear-gradient(135deg, #ff6200 0%, #e65600 100%) !important;
        transform: translateY(-2px) !important;
        box-shadow: 0 8px 26px rgba(255, 130, 54, 0.55) !important;
    }
}

/* ==========================================================================
   10. TRUST PERKS & PAYMENT METHODS (CART PAGE)
   ========================================================================== */
.miko-cart-trust-box {
    margin-top: 20px;
    padding-top: 18px;
    border-top: 1px solid #f1f5f9;
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.miko-trust-item {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 13px;
    color: #475569;
    line-height: 1.4;
}

.miko-trust-item svg {
    min-width: 18px;
    flex-shrink: 0;
}

.miko-cart-payment-methods {
    margin-top: 16px;
    padding-top: 14px;
    border-top: 1px dashed #e2e8f0;
}

.miko-payment-title {
    display: block;
    font-size: 12px;
    font-weight: 600;
    color: #64748b;
    margin-bottom: 8px;
    text-transform: uppercase;
    letter-spacing: 0.3px;
}

.miko-payment-badges {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
}

.miko-pay-badge {
    display: inline-block;
    padding: 4px 8px;
    background: #f8fafc;
    border: 1px solid #e2e8f0;
    border-radius: 6px;
    font-size: 11px;
    font-weight: 700;
    color: #475569;
    text-transform: uppercase;
    letter-spacing: 0.3px;
}

/* ==========================================================================
   11. EMPTY CART STATE ENHANCEMENT
   ========================================================================== */
.woocommerce-cart .cart-empty {
    grid-column: 1 / -1 !important;
    max-width: 600px !important;
    margin: 40px auto 20px auto !important;
    text-align: center !important;
    background: #ffffff !important;
    border-radius: 16px !important;
    padding: 50px 30px 20px 30px !important;
    border: 1px solid #edf0f5 !important;
    box-shadow: 0 6px 24px rgba(0, 0, 0, 0.04) !important;
    font-size: 16px !important;
    font-weight: 700 !important;
    color: #334155 !important;
}

.woocommerce-cart .return-to-shop {
    grid-column: 1 / -1 !important;
    text-align: center !important;
    margin-bottom: 60px !important;
}

.woocommerce-cart .return-to-shop .button {
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    height: 48px !important;
    padding: 0 32px !important;
    background: var(--color-second, #FF8236) !important;
    color: #ffffff !important;
    font-size: 15px !important;
    font-weight: 700 !important;
    text-transform: uppercase !important;
    letter-spacing: 0.5px !important;
    border-radius: 10px !important;
    text-decoration: none !important;
    box-shadow: 0 4px 14px rgba(255, 130, 54, 0.35) !important;
    transition: all 0.25s ease !important;
}

.woocommerce-cart .return-to-shop .button:hover {
    background: #e66f25 !important;
    transform: translateY(-2px) !important;
    box-shadow: 0 6px 20px rgba(255, 130, 54, 0.45) !important;
}

/* ==========================================================================
   12. CROSS-SELLS / RELATED PRODUCTS (CART PAGE)
   ========================================================================== */
.woocommerce-cart .cross-sells {
    grid-column: 1 / -1 !important;
    width: 100% !important;
    margin-top: 40px !important;
    padding-top: 30px !important;
    border-top: 1px solid #e8edf2 !important;
}

.woocommerce-cart .cross-sells > h2 {
    font-size: 22px !important;
    font-weight: 800 !important;
    color: var(--color, #004564) !important;
    text-transform: uppercase !important;
    margin-bottom: 24px !important;
    position: relative !important;
}

.woocommerce-cart .cross-sells ul.products {
    display: grid !important;
    grid-template-columns: repeat(4, 1fr) !important;
    grid-gap: 20px !important;
}

@media (max-width: 991px) {
    .woocommerce-cart .cross-sells ul.products {
        grid-template-columns: repeat(2, 1fr) !important;
    }
}

/* ==========================================================================
   13. MOBILE UX/UI FOR CART PAGE (/cart/) (Screen <= 768px)
   ========================================================================== */
@media (max-width: 768px) {
    .miko-cart-progress-steps {
        padding: 12px 16px;
        margin: 10px auto 20px auto;
    }

    .miko-step-item {
        font-size: 12px;
        gap: 6px;
    }

    .miko-step-icon {
        width: 28px;
        height: 28px;
    }

    .miko-step-icon svg {
        width: 15px;
        height: 15px;
    }

    .miko-step-divider {
        margin: 0 8px;
        max-width: 40px;
    }

    .woocommerce-cart-form table.shop_table_responsive thead {
        display: none !important;
    }

    .woocommerce-cart-form table.shop_table_responsive tr.cart_item {
        display: grid !important;
        grid-template-columns: 85px 1fr !important;
        grid-gap: 8px 12px !important;
        background: #ffffff !important;
        border: 1px solid #edf0f5 !important;
        border-radius: 14px !important;
        padding: 14px !important;
        margin-bottom: 16px !important;
        position: relative !important;
        box-shadow: 0 4px 14px rgba(0, 0, 0, 0.04) !important;
    }

    .woocommerce-cart-form table.shop_table_responsive tr.cart_item td {
        border: none !important;
        padding: 0 !important;
        text-align: left !important;
    }

    .woocommerce-cart-form table.shop_table_responsive tr.cart_item td:before {
        display: none !important;
    }

    /* Product Remove (Red cross at top-right) */
    .woocommerce-cart-form table.shop_table_responsive tr.cart_item td.product-remove {
        position: absolute !important;
        top: 10px !important;
        right: 10px !important;
        width: auto !important;
        z-index: 2 !important;
    }

    .woocommerce-cart-form table.shop_table_responsive tr.cart_item td.product-remove a.remove {
        width: 28px !important;
        height: 28px !important;
        border-radius: 50% !important;
        background: #fff0f0 !important;
        color: #e53935 !important;
        display: flex !important;
        align-items: center !important;
        justify-content: center !important;
        font-size: 18px !important;
        line-height: 1 !important;
        text-decoration: none !important;
    }

    /* Thumbnail */
    .woocommerce-cart-form table.shop_table_responsive tr.cart_item td.product-thumbnail {
        grid-column: 1 !important;
        grid-row: 1 / span 4 !important;
    }

    .woocommerce-cart-form table.shop_table_responsive tr.cart_item td.product-thumbnail img {
        width: 85px !important;
        height: 85px !important;
        object-fit: contain !important;
        border-radius: 8px !important;
        background: #f7f8fa !important;
        border: 1px solid #f0f0f0 !important;
    }

    /* Name */
    .woocommerce-cart-form table.shop_table_responsive tr.cart_item td.product-name {
        grid-column: 2 !important;
        padding-right: 32px !important;
    }

    .woocommerce-cart-form table.shop_table_responsive tr.cart_item td.product-name a {
        font-size: 14px !important;
        font-weight: 600 !important;
        color: #222222 !important;
        line-height: 1.35 !important;
        display: -webkit-box !important;
        -webkit-line-clamp: 2 !important;
        -webkit-box-orient: vertical !important;
        overflow: hidden !important;
    }

    /* Price */
    .woocommerce-cart-form table.shop_table_responsive tr.cart_item td.product-price {
        grid-column: 2 !important;
        font-size: 14px !important;
        font-weight: 700 !important;
        color: #e53935 !important;
    }

    /* Quantity */
    .woocommerce-cart-form table.shop_table_responsive tr.cart_item td.product-quantity {
        grid-column: 2 !important;
        margin-top: 4px !important;
    }

    .woocommerce-cart-form table.shop_table_responsive tr.cart_item td.product-subtotal {
        display: none !important;
    }

    /* Coupon & Actions */
    .woocommerce-cart-form table.shop_table_responsive tr td.actions {
        display: flex !important;
        flex-direction: column !important;
        gap: 12px !important;
        padding: 16px 0 !important;
    }

    .woocommerce-cart-form table.shop_table_responsive tr td.actions .coupon {
        display: flex !important;
        gap: 8px !important;
        width: 100% !important;
    }

    .woocommerce-cart-form table.shop_table_responsive tr td.actions .coupon input.input-text {
        flex: 1 !important;
        height: 42px !important;
        border-radius: 8px !important;
        border: 1px solid #dcdfe6 !important;
        padding: 0 12px !important;
    }

    .woocommerce-cart-form table.shop_table_responsive tr td.actions .coupon button.button {
        height: 42px !important;
        padding: 0 16px !important;
        border-radius: 8px !important;
        background: var(--color, #004564) !important;
        color: #fff !important;
        font-weight: 600 !important;
    }

    .woocommerce-cart-form table.shop_table_responsive tr td.actions button[name="update_cart"] {
        display: none !important;
    }

    .miko-continue-shopping-btn {
        display: inline-flex !important;
        align-items: center !important;
        justify-content: center !important;
        gap: 8px !important;
        padding: 12px 18px !important;
        font-size: 14px !important;
        font-weight: 600 !important;
        color: var(--color, #004564) !important;
        background: #f1f5f9 !important;
        border-radius: 9px !important;
        text-decoration: none !important;
        border: 1px solid #e2e8f0 !important;
        width: 100% !important;
        box-sizing: border-box !important;
        white-space: nowrap !important;
    }

    .miko-continue-shopping-btn span {
        white-space: nowrap !important;
    }

    /* Cart Totals Box */
    .cart-collaterals .cart_totals {
        border-radius: 14px !important;
        border: 1px solid #edf0f5 !important;
        padding: 18px !important;
        box-shadow: 0 4px 14px rgba(0, 0, 0, 0.04) !important;
    }

    .wc-proceed-to-checkout .checkout-button {
        height: 48px !important;
        display: flex !important;
        align-items: center !important;
        justify-content: center !important;
        font-size: 16px !important;
        font-weight: 700 !important;
        text-transform: uppercase !important;
        border-radius: 10px !important;
        box-shadow: 0 4px 14px rgba(255, 130, 54, 0.4) !important;
    }
}

@media (max-width: 480px) {
    #miko-side-cart-drawer {
        width: 100vw;
        max-width: 100vw;
    }
    
    #miko-toast-container {
        top: 14px;
        right: 14px;
        width: calc(100vw - 28px);
    }
    
    .miko-drawer-header {
        padding: 14px 16px;
    }
    
    .miko-drawer-body {
        padding: 12px 14px;
    }
    
    .miko-drawer-footer {
        padding: 14px 16px;
    }

    .miko-qty-btn {
        width: 36px;
        height: 36px;
    }
}
