﻿:root {
    --bg-dark: #090b0d;
    --bg-darker: #050608;
    --gold-luxury: #cea277;
    --gold-bright: #e0b687;
    --gold-glow: rgba(206, 162, 119, 0.35);
    --text-light: #f6f5f5;
    --text-muted: #a0a5aa;
    --border-color: rgba(206, 162, 119, 0.18);
    --border-glow: rgba(206, 162, 119, 0.35);
    --card-bg: #121518;
    --card-glass: rgba(18, 21, 24, 0.72);
    --bubble-radius: 28px;
    --bubble-radius-sm: 18px;
    --pill-radius: 999px;
    --success-color: #4caf50;
    --danger-color: #ff5757;
    --shadow-bubble: 0 8px 32px rgba(0, 0, 0, 0.45), 0 2px 8px rgba(0, 0, 0, 0.3), inset 0 1px 0 rgba(255, 255, 255, 0.04);
    --shadow-bubble-hover: 0 14px 44px rgba(0, 0, 0, 0.55), 0 4px 12px rgba(206, 162, 119, 0.12), inset 0 1px 0 rgba(255, 255, 255, 0.06);
    --shadow-gold-glow: 0 0 24px rgba(206, 162, 119, 0.25), 0 0 48px rgba(206, 162, 119, 0.12);
    --transition-bubble: cubic-bezier(0.34, 1.56, 0.64, 1);
    --transition-smooth: cubic-bezier(0.4, 0, 0.2, 1);
}

.cart-page-wrapper {
    background: radial-gradient(circle at 0% 0%, rgba(206, 162, 119, 0.06) 0%, transparent 45%), radial-gradient(circle at 100% 100%, rgba(206, 162, 119, 0.04) 0%, transparent 45%), var(--bg-dark);
    color: var(--text-light);
    direction: rtl;
    text-align: right;
    border-radius: 32px;
    position: relative;
    overflow: hidden;
    contain: layout style;
}

    .cart-page-wrapper::before {
        content: "";
        position: absolute;
        inset: 0;
        background: radial-gradient(circle at 20% 80%, rgba(206, 162, 119, 0.05), transparent 30%), radial-gradient(circle at 80% 20%, rgba(206, 162, 119, 0.04), transparent 30%);
        pointer-events: none;
        z-index: 0;
    }

    .cart-page-wrapper > * {
        position: relative;
        z-index: 1;
    }

.cart-title-main {
    font-size: clamp(1.4rem, 2.2vw, 1.85rem);
    color: var(--text-light);
    font-weight: 800;
    letter-spacing: -0.5px;
    margin-bottom: 2rem;
    padding-bottom: 1.25rem;
    position: relative;
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

    .cart-title-main::after {
        content: "";
        position: absolute;
        bottom: 0;
        right: 0;
        left: 0;
        height: 1px;
        background: linear-gradient(90deg, transparent, var(--border-glow), transparent);
    }

    .cart-title-main .title-bubble {
        width: 44px;
        height: 44px;
        border-radius: var(--pill-radius);
        background: linear-gradient(135deg, var(--gold-luxury), var(--gold-bright));
        display: inline-flex;
        align-items: center;
        justify-content: center;
        color: #000;
        font-size: 1.2rem;
        box-shadow: var(--shadow-gold-glow);
        animation: floatBubble 3s ease-in-out infinite;
    }

@keyframes floatBubble {
    0%, 100% {
        transform: translateY(0);
    }

    50% {
        transform: translateY(-4px);
    }
}

.table-luxury-container,
.summary-panel-luxury,
.cart-empty-bubble {
    background: var(--card-glass);
    backdrop-filter: blur(24px) saturate(140%);
    -webkit-backdrop-filter: blur(24px) saturate(140%);
    border: 1px solid var(--border-color);
    border-radius: var(--bubble-radius);
    padding: 1.75rem;
    box-shadow: var(--shadow-bubble);
    position: relative;
    transition: box-shadow 0.4s var(--transition-smooth), transform 0.4s var(--transition-bubble);
}

    .table-luxury-container::before,
    .summary-panel-luxury::before {
        content: "";
        position: absolute;
        inset: 0;
        border-radius: inherit;
        padding: 1px;
        background: linear-gradient(135deg, rgba(206, 162, 119, 0.4), transparent 40%, transparent 60%, rgba(206, 162, 119, 0.15));
        -webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0);
        -webkit-mask-composite: xor;
        mask-composite: exclude;
        pointer-events: none;
        opacity: 0.7;
    }

.table-luxury {
    width: 100%;
    border-collapse: collapse;
    color: var(--text-light);
}

    .table-luxury th {
        color: var(--text-muted);
        font-weight: 500;
        font-size: 0.9rem;
        padding-bottom: 1.25rem;
        border-bottom: 1px solid var(--border-color);
        letter-spacing: 0.3px;
    }

    .table-luxury td {
        padding: 1.5rem 0;
        border-bottom: 1px solid rgba(206, 162, 119, 0.08);
        vertical-align: middle;
    }

    .table-luxury tbody tr {
        transition: background 0.3s var(--transition-smooth);
    }

        .table-luxury tbody tr:hover {
            background: rgba(206, 162, 119, 0.03);
        }

        .table-luxury tbody tr:last-child td {
            border-bottom: none;
        }

.product-img-wrapper {
    width: 90px;
    height: 110px;
    object-fit: cover;
    border-radius: 20px;
    border: 1px solid rgba(206, 162, 119, 0.25);
    box-shadow: 0 4px 14px rgba(0, 0, 0, 0.4), inset 0 1px 0 rgba(255, 255, 255, 0.06);
    transition: transform 0.3s var(--transition-bubble), box-shadow 0.3s var(--transition-smooth);
    background: var(--bg-darker);
}

    .product-img-wrapper:hover {
        transform: scale(1.05) rotate(-1deg);
        box-shadow: 0 8px 24px rgba(0, 0, 0, 0.5), var(--shadow-gold-glow);
    }

.qty-controls-luxury {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    background: linear-gradient(180deg, #1c2024, #16191c);
    border: 1px solid rgba(206, 162, 119, 0.25);
    border-radius: var(--pill-radius);
    padding: 5px 6px;
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.04), 0 2px 8px rgba(0, 0, 0, 0.3);
}

.qty-btn-luxury {
    background: linear-gradient(135deg, rgba(206, 162, 119, 0.12), rgba(206, 162, 119, 0.04));
    border: 1px solid rgba(206, 162, 119, 0.2);
    color: var(--gold-bright);
    font-size: 1.1rem;
    font-weight: 700;
    width: 32px;
    height: 32px;
    border-radius: var(--pill-radius);
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    transition: all 0.25s var(--transition-bubble);
}

    .qty-btn-luxury:hover {
        background: linear-gradient(135deg, var(--gold-luxury), var(--gold-bright));
        color: #000;
        transform: scale(1.12);
        box-shadow: var(--shadow-gold-glow);
    }

    .qty-btn-luxury:active {
        transform: scale(0.92);
    }

    .qty-btn-luxury:focus-visible {
        outline: 2px solid var(--gold-luxury);
        outline-offset: 2px;
    }

.qty-value-luxury {
    color: var(--text-light);
    font-weight: 700;
    min-width: 32px;
    text-align: center;
    font-size: 1rem;
    font-variant-numeric: tabular-nums;
}

.btn-remove-flat {
    background: rgba(255, 87, 87, 0.06);
    border: 1px solid rgba(255, 87, 87, 0.18);
    color: var(--text-muted);
    font-size: 0.95rem;
    width: 36px;
    height: 36px;
    border-radius: var(--pill-radius);
    cursor: pointer;
    transition: all 0.25s var(--transition-bubble);
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

    .btn-remove-flat:hover {
        background: rgba(255, 87, 87, 0.15);
        color: var(--danger-color);
        transform: scale(1.1) rotate(90deg);
        box-shadow: 0 0 16px rgba(255, 87, 87, 0.25);
    }

    .btn-remove-flat:focus-visible {
        outline: 2px solid var(--danger-color);
        outline-offset: 2px;
    }

.summary-panel-luxury {
    position: sticky;
    top: 1.5rem;
    padding: 2rem;
}

.summary-item-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1.1rem;
    font-size: 0.97rem;
}

    .summary-item-row .label {
        color: var(--text-muted);
    }

    .summary-item-row .value {
        color: var(--text-light);
        font-weight: 600;
        font-variant-numeric: tabular-nums;
    }

    .summary-item-row.discount-active .value {
        color: var(--success-color);
    }

.summary-total-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: 1.75rem;
    padding-top: 1.5rem;
    border-top: 1px dashed var(--border-color);
}

    .summary-total-row .total-label {
        font-size: 1.05rem;
        font-weight: 700;
    }

    .summary-total-row .total-price {
        font-size: clamp(1.2rem, 2vw, 1.5rem);
        color: var(--gold-luxury);
        font-weight: 800;
        font-variant-numeric: tabular-nums;
        text-shadow: 0 0 18px rgba(206, 162, 119, 0.4);
    }

.btn-checkout-luxury {
    display: block;
    width: 100%;
    background: linear-gradient(135deg, var(--gold-luxury), var(--gold-bright));
    color: #000 !important;
    text-align: center;
    padding: 1.05rem 1.5rem;
    border-radius: var(--pill-radius);
    font-weight: 800;
    font-size: 1.05rem;
    text-decoration: none;
    margin-top: 1.75rem;
    border: none;
    box-shadow: 0 6px 20px rgba(206, 162, 119, 0.3), inset 0 1px 0 rgba(255, 255, 255, 0.3);
    transition: all 0.3s var(--transition-bubble);
    position: relative;
    overflow: hidden;
}

    .btn-checkout-luxury::after {
        content: "";
        position: absolute;
        top: 0;
        left: -100%;
        width: 100%;
        height: 100%;
        background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.35), transparent);
        transition: left 0.6s var(--transition-smooth);
    }

    .btn-checkout-luxury:hover {
        transform: translateY(-2px);
        box-shadow: 0 10px 28px rgba(206, 162, 119, 0.45), var(--shadow-gold-glow), inset 0 1px 0 rgba(255, 255, 255, 0.4);
    }

        .btn-checkout-luxury:hover::after {
            left: 100%;
        }

    .btn-checkout-luxury:active {
        transform: translateY(0);
    }

    .btn-checkout-luxury:focus-visible {
        outline: 2px solid var(--text-light);
        outline-offset: 3px;
    }

.coupon-input-group {
    display: flex;
    border: 1px solid var(--border-color);
    border-radius: var(--pill-radius);
    overflow: hidden;
    background: linear-gradient(180deg, #1c2024, #16191c);
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.03);
    transition: border-color 0.3s var(--transition-smooth), box-shadow 0.3s var(--transition-smooth);
}

    .coupon-input-group:focus-within {
        border-color: var(--gold-luxury);
        box-shadow: 0 0 0 3px rgba(206, 162, 119, 0.15);
    }

    .coupon-input-group input {
        background: none;
        border: none;
        color: var(--text-light);
        padding: 0.7rem 1.1rem;
        flex-grow: 1;
        outline: none;
        font-size: 0.92rem;
        min-width: 0;
    }

        .coupon-input-group input::placeholder {
            color: rgba(160, 165, 170, 0.7);
        }

    .coupon-input-group button {
        background: linear-gradient(135deg, rgba(206, 162, 119, 0.18), rgba(206, 162, 119, 0.08));
        border: none;
        color: var(--gold-bright);
        padding: 0 1.4rem;
        font-weight: 700;
        cursor: pointer;
        border-right: 1px solid var(--border-color);
        transition: all 0.25s var(--transition-smooth);
        white-space: nowrap;
    }

        .coupon-input-group button:hover {
            background: linear-gradient(135deg, var(--gold-luxury), var(--gold-bright));
            color: #000;
        }

.cart-empty-bubble {
    text-align: center;
    padding: 4rem 1.5rem;
}

    .cart-empty-bubble .empty-icon-bubble {
        width: 110px;
        height: 110px;
        border-radius: var(--pill-radius);
        background: linear-gradient(135deg, rgba(206, 162, 119, 0.15), rgba(206, 162, 119, 0.04));
        border: 1px solid var(--border-glow);
        display: inline-flex;
        align-items: center;
        justify-content: center;
        font-size: 3rem;
        color: var(--gold-luxury);
        margin-bottom: 1.5rem;
        box-shadow: var(--shadow-gold-glow), inset 0 1px 0 rgba(255, 255, 255, 0.06);
        animation: floatBubble 4s ease-in-out infinite;
    }

.badge-unavailable {
    background: rgba(255, 87, 87, 0.15);
    color: var(--danger-color);
    border: 1px solid rgba(255, 87, 87, 0.3);
    padding: 0.25rem 0.75rem;
    border-radius: var(--pill-radius);
    font-size: 0.72rem;
    font-weight: 600;
    display: inline-block;
    margin-top: 0.5rem;
}

.color-swatch-bubble {
    width: 14px;
    height: 14px;
    border-radius: var(--pill-radius);
    display: inline-block;
    border: 1px solid rgba(255, 255, 255, 0.2);
    box-shadow: 0 0 0 2px rgba(0, 0, 0, 0.3), inset 0 1px 0 rgba(255, 255, 255, 0.2);
}

.cart-row-loading {
    position: relative;
    overflow: hidden;
}

    .cart-row-loading::after {
        content: "";
        position: absolute;
        inset: 0;
        background: linear-gradient(90deg, transparent, rgba(206, 162, 119, 0.06), transparent);
        animation: shimmer 1.4s infinite;
    }

@keyframes shimmer {
    0% {
        transform: translateX(-100%);
    }

    100% {
        transform: translateX(100%);
    }
}

.cart-toast {
    position: fixed;
    top: 1.5rem;
    left: 50%;
    display: flex;
    align-items: center;
    gap: 0.85rem;
    background: linear-gradient(135deg, rgba(18, 21, 24, 0.96), rgba(12, 14, 17, 0.96));
    backdrop-filter: blur(28px) saturate(160%);
    -webkit-backdrop-filter: blur(28px) saturate(160%);
    border: 1px solid var(--border-glow);
    border-radius: var(--pill-radius);
    padding: 1rem 1.2rem 1rem 1.2rem;
    color: var(--text-light);
    font-size: 1rem;
    font-weight: 600;
    box-shadow: 0 16px 48px rgba(0, 0, 0, 0.6), 0 4px 12px rgba(0, 0, 0, 0.4), var(--shadow-gold-glow), inset 0 1px 0 rgba(255, 255, 255, 0.08);
    z-index: 2147483647;
    max-width: calc(100vw - 2rem);
    width: max-content;
    opacity: 0;
    visibility: hidden;
    transform: translateX(-50%) translateY(-120px);
    transition: transform 0.5s var(--transition-bubble), opacity 0.4s var(--transition-smooth), visibility 0s linear 0.4s;
}

    .cart-toast.show {
        opacity: 1;
        visibility: visible;
        transform: translateX(-50%) translateY(0);
        transition: transform 0.5s var(--transition-bubble), opacity 0.4s var(--transition-smooth), visibility 0s linear 0s;
    }

    .cart-toast .toast-icon-bubble {
        flex-shrink: 0;
        width: 38px;
        height: 38px;
        border-radius: var(--pill-radius);
        display: inline-flex;
        align-items: center;
        justify-content: center;
        font-size: 1.1rem;
        background: linear-gradient(135deg, rgba(206, 162, 119, 0.2), rgba(206, 162, 119, 0.05));
        border: 1px solid var(--border-glow);
        color: var(--gold-bright);
    }

    .cart-toast.success .toast-icon-bubble {
        background: linear-gradient(135deg, rgba(76, 175, 80, 0.2), rgba(76, 175, 80, 0.05));
        border-color: rgba(76, 175, 80, 0.4);
        color: var(--success-color);
    }

    .cart-toast.error .toast-icon-bubble {
        background: linear-gradient(135deg, rgba(255, 87, 87, 0.2), rgba(255, 87, 87, 0.05));
        border-color: rgba(255, 87, 87, 0.4);
        color: var(--danger-color);
    }

    .cart-toast.error {
        border-color: rgba(255, 87, 87, 0.4);
    }

    .cart-toast.success {
        border-color: rgba(76, 175, 80, 0.4);
    }

    .cart-toast .toast-close {
        background: none;
        border: none;
        color: var(--text-muted);
        font-size: 1rem;
        cursor: pointer;
        padding: 0.25rem 0.4rem;
        margin-right: 0.25rem;
        border-radius: var(--pill-radius);
        transition: all 0.2s var(--transition-smooth);
        line-height: 1;
    }

        .cart-toast .toast-close:hover {
            color: var(--text-light);
            background: rgba(255, 255, 255, 0.08);
        }

.seo-link {
    color: var(--gold-luxury);
    text-decoration: none;
    transition: color 0.2s var(--transition-smooth);
    border-bottom: 1px dashed transparent;
}

    .seo-link:hover {
        color: var(--gold-bright);
        border-bottom-color: var(--gold-luxury);
    }

@media (max-width: 991.98px) {
    .table-luxury thead {
        display: none;
    }

    .table-luxury tr {
        display: block;
        border-bottom: 1px solid var(--border-color);
        padding: 1.5rem 0;
        position: relative;
        border-radius: var(--bubble-radius-sm);
        margin-bottom: 1rem;
        background: rgba(255, 255, 255, 0.015);
    }

    .table-luxury td {
        display: block;
        padding: 0.5rem 0;
        border: none;
        text-align: right !important;
    }

        .table-luxury td:first-child {
            padding-left: 2rem;
        }

    .qty-container-mobile {
        display: flex;
        align-items: center;
        justify-content: space-between;
        margin-top: 1rem;
    }

    .remove-wrapper-mobile {
        position: absolute;
        left: 0;
        top: 1.5rem;
    }

    .summary-panel-luxury {
        position: static;
        margin-top: 1rem;
    }

    .cart-toast {
        top: 1rem;
        left: 0.75rem;
        right: 0.75rem;
        width: auto;
        max-width: none;
        font-size: 0.9rem;
        padding: 0.85rem 1rem;
        gap: 0.7rem;
        transform: translateY(-120px);
    }

        .cart-toast.show {
            transform: translateY(0);
        }

        .cart-toast .toast-icon-bubble {
            width: 32px;
            height: 32px;
            font-size: 0.95rem;
        }

        .cart-toast .toast-message {
            flex: 1;
            min-width: 0;
            line-height: 1.4;
        }
}

@media (max-width: 575.98px) {
    .cart-page-wrapper {
        padding: 1rem !important;
    }

    .table-luxury-container,
    .summary-panel-luxury {
        padding: 1.25rem;
    }

    .product-img-wrapper {
        width: 72px;
        height: 92px;
    }

    .cart-title-main {
        font-size: 1.3rem;
    }

    .cart-empty-bubble {
        padding: 3rem 1rem;
    }

        .cart-empty-bubble .empty-icon-bubble {
            width: 90px;
            height: 90px;
            font-size: 2.4rem;
        }
}

@supports (padding: max(0px)) {
    .cart-page-wrapper {
        padding-left: max(1rem, env(safe-area-inset-left));
        padding-right: max(1rem, env(safe-area-inset-right));
    }

    .cart-toast {
        top: max(1.5rem, env(safe-area-inset-top));
    }

    @media (max-width: 991.98px) {
        .cart-toast {
            top: max(1rem, env(safe-area-inset-top));
            left: max(0.75rem, env(safe-area-inset-left));
            right: max(0.75rem, env(safe-area-inset-right));
        }
    }
}

@media (prefers-reduced-motion: reduce) {
    *, *::before, *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
}
