/* ============================================================================
   CART MODAL
   ============================================================================ */

.cart-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.5);
    backdrop-filter: blur(8px);
    z-index: 2000;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
}

.cart-overlay.active {
    opacity: 1;
    visibility: visible;
}

.cart-modal {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    max-width: 450px;
    margin: 0 auto;
    background: #fafafa;
    border-radius: 32px 32px 0 0;
    max-height: 90vh;
    transform: translateY(100%);
    transition: transform 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    z-index: 2001;
    display: flex;
    flex-direction: column;
    box-shadow: 0 -20px 60px rgba(0, 0, 0, 0.3);
}

.cart-overlay.active .cart-modal {
    transform: translateY(0);
}

.cart-handle {
    width: 40px;
    height: 5px;
    background: #d0d0d0;
    border-radius: 3px;
    margin: 12px auto 8px auto;
}

.cart-header {
    padding: 15px 24px 20px 24px;
    background: white;
    border-radius: 32px 32px 0 0;
    flex-shrink: 0;
}

.cart-header-top {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 15px;
}

.cart-title {
    font-size: clamp(22px, 5.5vw, 26px);
    font-weight: 800;
    color: #2c3e50;
    display: flex;
    align-items: center;
    gap: 10px;
}

.cart-title-icon {
    font-size: 28px;
}

.cart-count-badge {
    background: linear-gradient(135deg, #d4a574 0%, #c4956f 100%);
    color: white;
    font-size: 13px;
    font-weight: 700;
    padding: 5px 12px;
    border-radius: 14px;
    min-width: 28px;
    text-align: center;
    box-shadow: 0 4px 12px rgba(212, 165, 116, 0.30);
}

.close-cart {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: #f5f5f5;
    border: none;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.3s ease;
    font-size: 22px;
    color: #666;
}

.close-cart:hover {
    background: #e0e0e0;
    transform: rotate(90deg) scale(1.1);
}

.close-cart:active {
    transform: rotate(90deg) scale(0.95);
}

.promo-banner {
    background: linear-gradient(135deg, #4caf50, #45a049);
    color: white;
    padding: 12px 16px;
    border-radius: 16px;
    display: flex;
    align-items: center;
    gap: 12px;
    font-size: 14px;
    font-weight: 600;
    animation: slideInDown 0.5s ease;
}

.promo-icon {
    font-size: 24px;
}

.promo-text {
    flex: 1;
}

.promo-amount {
    font-size: 16px;
    font-weight: 800;
}

.cart-content {
    flex: 1;
    overflow-y: auto;
    padding: 20px;
    scrollbar-width: thin;
    scrollbar-color: #d4a574 transparent;
}

.cart-content::-webkit-scrollbar {
    width: 6px;
}

.cart-content::-webkit-scrollbar-track {
    background: transparent;
}

.cart-content::-webkit-scrollbar-thumb {
    background: #d4a574;
    border-radius: 3px;
}

.cart-empty {
    text-align: center;
    padding: 80px 20px;
    animation: fadeIn 0.5s ease;
}

.cart-empty-icon {
    font-size: 80px;
    margin-bottom: 20px;
    opacity: 0.4;
    animation: floatCart 3s ease-in-out infinite;
}

.cart-empty-text {
    font-size: 18px;
    color: #999;
    font-weight: 600;
    margin-bottom: 8px;
}

.cart-empty-subtext {
    font-size: 14px;
    color: #bbb;
}

.cart-item {
    background: white;
    border-radius: 20px;
    padding: 16px;
    margin-bottom: 14px;
    display: flex;
    gap: 14px;
    animation: slideInCart 0.4s ease;
    box-shadow: 0 2px 12px rgba(0, 0, 0, 0.06);
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.cart-item:hover {
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.1);
    transform: translateY(-2px);
}

.cart-item::before {
    content: '';
    position: absolute;
    left: 0;
    top: 0;
    bottom: 0;
    width: 4px;
    background: linear-gradient(135deg, #d4a574 0%, #c4956f 100%);
    opacity: 0;
    transition: opacity 0.3s ease;
}

.cart-item:hover::before {
    opacity: 1;
}

.cart-item-image {
    width: 80px;
    height: 80px;
    border-radius: 14px;
    object-fit: cover;
    flex-shrink: 0;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

.cart-item-details {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.cart-item-name {
    font-size: 16px;
    font-weight: 700;
    color: #2c3e50;
    line-height: 1.3;
}

.cart-item-price {
    font-size: 19px;
    font-weight: 800;
    color: #d4a574;
}

.cart-item-controls {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-top: 6px;
}

.quantity-display {
    font-size: 17px;
    font-weight: 700;
    color: #2c3e50;
    min-width: 35px;
    text-align: center;
    background: #f5f5f5;
    padding: 6px 12px;
    border-radius: 10px;
}

.remove-item {
    margin-left: auto;
    background: none;
    border: none;
    color: #ff4757;
    font-size: 22px;
    cursor: pointer;
    padding: 6px;
    transition: all 0.3s ease;
    border-radius: 8px;
}

.remove-item:hover {
    transform: scale(1.2) rotate(20deg);
    background: rgba(255, 71, 87, 0.1);
}

.cart-footer {
    padding: 20px 24px;
    background: white;
    flex-shrink: 0;
    border-top: 1px solid #f0f0f0;
}

.cart-summary {
    margin-bottom: 16px;
}

.summary-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 10px;
    font-size: 15px;
    color: #666;
}

.summary-value {
    font-weight: 700;
    color: #2c3e50;
}

.cart-total {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 16px 0;
    border-top: 2px dashed #e0e0e0;
    margin-bottom: 16px;
}

.cart-total-label {
    font-size: 18px;
    font-weight: 700;
    color: #2c3e50;
}

.cart-total-amount {
    font-size: 28px;
    font-weight: 900;
    background: linear-gradient(135deg, #d4a574 0%, #c4956f 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.checkout-btn {
    width: 100%;
    padding: 18px;
    background: linear-gradient(135deg, #d4a574 0%, #c4956f 100%);
    border: none;
    border-radius: 16px;
    color: white;
    font-size: 18px;
    font-weight: 800;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 8px 24px rgba(212, 165, 116, 0.40);
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
}

.checkout-btn:hover {
    transform: translateY(-3px);
    box-shadow: 0 12px 32px rgba(212, 165, 116, 0.5);
}

.checkout-btn:active {
    transform: translateY(-1px);
}

.checkout-icon {
    font-size: 22px;
}

/* ============================================================================
   BOTTOM NAVIGATION BAR
   ============================================================================ */

.bottom-nav {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(20px);
    border-top: 1px solid rgba(212, 165, 116, 0.2);
    border-top-left-radius: 24px;
    border-top-right-radius: 24px;
    padding: 8px 0 max(8px, env(safe-area-inset-bottom));
    z-index: 1000;
    box-shadow: 0 -10px 40px rgba(107, 68, 35, 0.1);
}

.nav-container {
    max-width: 450px;
    margin: 0 auto;
    display: flex;
    justify-content: space-around;
    align-items: center;
    position: relative;
    padding: 0 10px;
}

.nav-item {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 4px;
    padding: 8px 0;
    cursor: pointer;
    transition: all 0.3s ease;
    text-decoration: none;
    color: inherit;
}

.nav-icon-wrapper {
    position: relative;
    width: 28px;
    height: 28px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.4s ease;
}

.nav-item.active .nav-icon-wrapper {
    transform: translateY(-3px) scale(1.1);
}

.nav-icon {
    transition: all 0.3s ease;
    filter: grayscale(100%);
    opacity: 0.6;
    display: flex;
    align-items: center;
    justify-content: center;
}

.nav-icon svg {
    width: 24px;
    height: 24px;
    stroke-width: 2.5;
}

.nav-item.active .nav-icon {
    filter: grayscale(0%);
    opacity: 1;
}

.nav-item.active .nav-icon svg {
    stroke: #d4a574;
}

.nav-label {
    font-size: clamp(10px, 2.5vw, 12px);
    font-weight: 500;
    color: #999;
    transition: all 0.3s ease;
}

.nav-item.active .nav-label {
    color: #d4a574;
    font-weight: 600;
}

.nav-indicator {
    position: absolute;
    top: -2px;
    left: 50%;
    transform: translateX(-50%) scale(0);
    width: 4px;
    height: 4px;
    background: #d4a574;
    border-radius: 50%;
    transition: transform 0.3s ease;
}

.nav-item.active .nav-indicator {
    transform: translateX(-50%) scale(1);
}

/* FAB */
.nav-item.fab {
    position: relative;
    margin: 0 10px;
}

.fab-button {
    width: 56px;
    height: 56px;
    border-radius: 50%;
    background: linear-gradient(135deg, #d4a574 0%, #c4956f 100%);
    border: none;
    box-shadow: 0 8px 24px rgba(212, 165, 116, 0.40);
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.4s ease;
    margin-top: -28px;
    border: 4px solid rgba(255, 255, 255, 0.95);
}

.fab-button:hover {
    transform: scale(1.1) rotate(90deg);
}

.fab-icon {
    font-size: 28px;
}

.notification-badge {
    position: absolute;
    top: 0;
    right: -2px;
    background: #ff4757;
    color: white;
    font-size: 10px;
    font-weight: 700;
    padding: 2px 5px;
    border-radius: 10px;
    min-width: 18px;
    text-align: center;
    box-shadow: 0 2px 8px rgba(255, 71, 87, 0.4);
    display: none;
}

.notification-badge.show {
    display: flex;
    align-items: center;
    justify-content: center;
}