﻿/* =============================================================================
   APACKS Sidebar CSS - Versiunea Finală Real Device Optimized
   Unifică toate stilurile și elimină conflictele
   ============================================================================= */

:root {
    /* Brand Colors */
    --brand-black: #000000;
    --brand-white: #ffffff;
    --brand-red: #C10206;
    --brand-gray: #333333;
    --brand-light-gray: #f8f9fa;
    /* Sidebar Dimensions - Fixed pentru consistency */
    --sidebar-width-mobile: 100vw;
    --sidebar-width-desktop: 360px;
    --cart-sidebar-width: 400px;
    /* Animation - Optimizat pentru real devices */
    --animation-speed: 50ms;
    --animation-easing: cubic-bezier(0.25, 0.46, 0.45, 0.94);
    /* Typography - Font stacks pentru better loading */
    --font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
    --font-size-base: 16px;
    --font-size-small: 14px;
    --font-size-tiny: 12px;
    /* Spacing - Fixed values pentru consistency */
    --spacing-xs: 4px;
    --spacing-sm: 8px;
    --spacing-md: 16px;
    --spacing-lg: 24px;
    --spacing-xl: 32px;
    /* Touch Target Size - Real device optimized */
    --touch-target: 44px;
    --touch-target-large: 56px;
}

/* =============================================================================
   REAL DEVICE FIXES - Force hardware acceleration
   ============================================================================= */

.sidebar,
.overlay-sidebar,
.nav-link,
.btn {
    -webkit-transform: translateZ(0);
    transform: translateZ(0);
    -webkit-backface-visibility: hidden;
    backface-visibility: hidden;
    will-change: transform;
}

/* iOS Safari specific fixes */
@supports (-webkit-touch-callout: none) {
    .sidebar {
        -webkit-overflow-scrolling: touch;
        height: 100vh;
        height: -webkit-fill-available;
    }

    .nav-link,
    .btn {
        -webkit-tap-highlight-color: transparent;
        -webkit-touch-callout: none;
        -webkit-user-select: none;
        user-select: none;
    }
}

/* =============================================================================
   OVERLAY - Background semi-transparent
   ============================================================================= */

.overlay-sidebar {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background: rgba(1, 10, 16, 0.8);
    backdrop-filter: blur(2px);
    -webkit-backdrop-filter: blur(2px);
    z-index: 9998;
    opacity: 0;
    visibility: hidden;
    transition: all var(--animation-speed) var(--animation-easing);
    /* Force GPU layer */
    -webkit-transform: translateZ(0);
    transform: translateZ(0);
}

    .overlay-sidebar.active {
        opacity: 1;
        visibility: visible;
    }

/* =============================================================================
   SIDEBAR BASE - Optimizat pentru Real Devices
   ============================================================================= */

.sidebar {
    position: fixed;
    top: 0;
    height: 100vh;
    height: -webkit-fill-available; /* iOS fix */
    background: var(--brand-white);
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.25);
    z-index: 9999;
    transition: transform var(--animation-speed) var(--animation-easing);
    overflow-y: auto;
    overflow-x: hidden;
    font-family: var(--font-family);
    font-size: var(--font-size-base);
    line-height: 1.5;
    /* Critical pentru real devices */
    -webkit-overflow-scrolling: touch;
    overscroll-behavior: contain;
    /* Better text rendering */
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

    /* Sidebar Navigation (stânga) */
    .sidebar:not(.right-sidebar) {
        left: 0;
        width: 100vw;
        max-width: 100vw;
        transform: translateX(-100%);
        -webkit-transform: translateX(-100%);
    }

    /* Sidebar Cart (dreapta) */
    .sidebar.right-sidebar {
        right: 0;
        width: 100vw;
        max-width: 100vw;
        transform: translateX(100%);
        -webkit-transform: translateX(100%);
    }

    /* Stare activă - Hardware accelerated */
    .sidebar.active {
        transform: translateX(0);
        -webkit-transform: translateX(0);
    }

/* =============================================================================
   NAVIGATION SIDEBAR - Optimizat pentru conversie
   ============================================================================= */

.nav-sidebar {
    background: linear-gradient(180deg, var(--brand-black) 0%, #1a1a1a 100%);
    color: var(--brand-white);
    display: flex;
    flex-direction: column;
}

/* Header Navigation Sidebar */
.sidebar-header {
    background: var(--brand-black);
    padding: 20px 16px; /* Fixed values pentru consistency */
    border-bottom: 2px solid var(--brand-red);
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    flex-shrink: 0;
    min-height: 80px; /* Prevent layout shift */
}

.sidebar-logo h2 {
    color: var(--brand-white);
    font-size: 24px; /* Redus pentru real devices */
    font-weight: 700;
    margin: 0;
    letter-spacing: -0.3px;
    font-family: 'Black Ops One', var(--font-family);
    text-rendering: optimizeLegibility;
}

.tagline {
    color: var(--brand-white);
    font-size: 11px; /* Redus pentru real devices */
    font-weight: 500;
    display: block;
    margin-top: 4px;
    line-height: 1.3;
    font-family: 'Inter', var(--font-family);
}

/* Close Button - Touch optimized */
.nav-sidebar .btn-close-sidebar {
    background: none;
    border: none;
    color: var(--brand-white);
    font-size: 26px; /* Redus pentru real devices */
    width: var(--touch-target);
    height: var(--touch-target);
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    border-radius: 4px;
    transition: all 0.2s ease;
    font-weight: 300;
    /* Touch optimization */
    -webkit-tap-highlight-color: transparent;
    touch-action: manipulation;
}

    .nav-sidebar .btn-close-sidebar:hover,
    .nav-sidebar .btn-close-sidebar:active {
        background: var(--brand-red);
        transform: scale(1.05);
    }

/* Banner Urgent - Real device optimized */
.urgent-banner {
    background: #C10206 !important;
    color: #ffffff !important;
    padding: 12px 16px !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    gap: 8px !important;
    font-weight: 600 !important;
    font-size: 13px !important;
    width: 100% !important;
    /* ELIMINĂ margin-top: 80px - nu mai e necesar */
}

@keyframes urgentPulse {
    0%, 100% {
        background: var(--brand-red);
    }

    50% {
        background: #aa0205;
    }
}

.offer-icon {
    font-size: 16px; /* Optimizat pentru real devices */
    animation: bounce 1.5s infinite;
    display: inline-block;
}

@keyframes bounce {
    0%, 20%, 50%, 80%, 100% {
        transform: translateY(0);
        -webkit-transform: translateY(0);
    }

    40% {
        transform: translateY(-3px);
        -webkit-transform: translateY(-3px);
    }

    60% {
        transform: translateY(-1px);
        -webkit-transform: translateY(-1px);
    }
}

.offer-text {
    font-size: 13px;
    font-weight: 600;
    text-align: center;
    line-height: 1.2;
}

/* Conținut Principal Sidebar */
.sidebar-content {
    padding: 16px; /* Fixed value */
    flex: 1;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    overflow-y: auto;
    overflow-x: hidden;
    /* Smooth scrolling pentru real devices */
    -webkit-overflow-scrolling: touch;
    overscroll-behavior: contain;
}

/* =============================================================================
   NAVIGATION SECTION - Real device optimized
   ============================================================================= */

.navigation-section {
    margin-bottom: 24px; /* Fixed value */
    flex: 1;
}

/* IMPORTANT: Stiluri pentru .navigation-title (versiunea ta actuală) */
.navigation-title {
    color: var(--brand-white);
    font-size: 16px; /* Redus pentru real devices */
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.8px; /* Redus pentru real devices */
    padding: 16px 0 8px 0;
    margin-bottom: 8px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.2);
    text-align: left;
    font-family: 'Teko', var(--font-family);
    position: relative;
    text-rendering: optimizeLegibility;
}

    .navigation-title::after {
        content: '';
        position: absolute;
        bottom: -1px;
        left: 0;
        width: 40px; /* Redus pentru proporție */
        height: 2px;
        background: var(--brand-red);
        border-radius: 1px;
    }

/* Navigation Links - Optimizat pentru real devices */
.nav-link {
    display: flex;
    align-items: center;
    padding: 10px 0; /* Fixed values */
    min-height: var(--touch-target-large);
    text-decoration: none;
    color: var(--brand-white);
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    transition: all 0.2s ease;
    position: relative;
    gap: 10px; /* Fixed value */
    /* Touch optimization */
    -webkit-tap-highlight-color: transparent;
    touch-action: manipulation;
    cursor: pointer;
}

    .nav-link:hover,
    .nav-link:active {
        background-color: rgba(255, 255, 255, 0.08);
        padding-left: 6px;
        transform: translateX(2px);
        -webkit-transform: translateX(2px);
        color: var(--brand-white);
    }

    .nav-link.active {
        background-color: var(--brand-red);
        border-radius: 8px;
        border-bottom: 1px solid var(--brand-red);
        margin: 2px 0;
        padding-left: 6px;
        box-shadow: 0 2px 8px rgba(193, 2, 6, 0.3);
    }

/* Icon Navigation */
.nav-icon {
    font-size: 16px; /* Optimizat pentru proporție */
    width: 26px;
    flex-shrink: 0;
    text-align: center;
    align-self: center;
    line-height: 1;
}

/* Content Navigation */
.nav-content {
    flex: 1;
    display: flex;
    flex-direction: column;
    justify-content: center;
    gap: 1px;
}

/* Text Principal */
.nav-text {
    font-size: 15px; /* Optimizat pentru lizibilitate */
    font-weight: 600;
    line-height: 1.2;
    margin: 0;
    color: var(--brand-white);
    text-rendering: optimizeLegibility;
}

/* Subtitle */
.nav-subtitle {
    font-size: 11px; /* Redus pentru real devices */
    color: rgba(255, 255, 255, 0.7);
    line-height: 1.2;
    margin: 0;
    text-rendering: optimizeLegibility;
}

/* Active states */
.nav-link.active .nav-text {
    font-weight: 700;
    color: var(--brand-white);
}

.nav-link.active .nav-subtitle {
    color: rgba(255, 255, 255, 0.9);
}

/* Touch feedback pentru real devices */
.nav-link:active {
    background-color: rgba(255, 255, 255, 0.15);
    transform: scale(0.98);
    -webkit-transform: scale(0.98);
}

/* =============================================================================
   BADGES - Optimizate pentru real devices
   ============================================================================= */

.nav-badge {
    position: absolute;
    right: 6px;
    top: 50%;
    transform: translateY(-50%);
    -webkit-transform: translateY(-50%);
    padding: 2px 5px; /* Redus pentru real devices */
    border-radius: 4px;
    font-size: 9px; /* Redus pentru proporție */
    font-weight: 700;
    text-transform: uppercase;
    z-index: 1;
    letter-spacing: 0.2px;
    line-height: 1.2;
}

    /* Badge Colors - High contrast pentru real devices */
    .nav-badge.tutorial {
        background: #2563eb;
        color: white;
    }

    .nav-badge.popular {
        background: #fbbf24;
        color: #000;
        animation: badgePulse 2s infinite;
    }

    .nav-badge.offer {
        background: var(--brand-red);
        color: white;
        animation: badgePulse 2s infinite;
    }

    .nav-badge.clients {
        background: #10b981;
        color: white;
    }

@keyframes badgePulse {
    0%, 100% {
        transform: translateY(-50%) scale(1);
        -webkit-transform: translateY(-50%) scale(1);
        opacity: 1;
    }

    50% {
        transform: translateY(-50%) scale(1.03);
        -webkit-transform: translateY(-50%) scale(1.03);
        opacity: 0.9;
    }
}

/* =============================================================================
   CONVERSION SECTION - Optimizată pentru real devices
   ============================================================================= */

.conversion-section {
    margin-top: auto;
    padding-top: 20px; /* Fixed value */
}

/* Special Offer Sidebar - Design consistent cu buy-card-buyAtf */
.special-offer-sidebar {
    position: relative;
    background: linear-gradient(135deg, #1a1a1a 0%, #2a2a2a 100%);
    padding: 14px; /* Fixed value */
    border-radius: 12px;
    margin-bottom: 18px;
    text-align: center;
    box-shadow: 0 6px 24px rgba(193, 2, 6, 0.4);
    overflow: hidden;
    border: 2px solid rgba(255, 255, 255, 0.1);
    /* Better performance pe real devices */
    will-change: transform;
    -webkit-transform: translateZ(0);
    transform: translateZ(0);
}

    .special-offer-sidebar::before {
        content: '';
        position: absolute;
        top: 0;
        left: 0;
        right: 0;
        height: 2px;
        background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.5), transparent);
        animation: shimmer 3s infinite;
    }

@keyframes shimmer {
    0% {
        transform: translateX(-100%);
        -webkit-transform: translateX(-100%);
    }

    100% {
        transform: translateX(100%);
        -webkit-transform: translateX(100%);
    }
}

/* Badge Discount - Real device optimized */
.badge-sidebar {
    position: absolute;
    top: 6px;
    right: 6px;
    color: white;
    padding: 3px 6px;
    border-radius: 16px;
    font-family: 'Teko', var(--font-family);
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.8);
    z-index: 10;
    border: 1px solid rgba(255, 255, 255, 0.3);
    min-width: 36px;
    text-align: center;
    line-height: 1;
}

.badge-discount-sidebar {
    background: radial-gradient(ellipse at center, #ff6b35 0%, var(--brand-red) 40%, #8b0000 70%, #2d0000 100%);
    box-shadow: 0 0 20px rgba(255, 107, 53, 0.8), 0 0 40px rgba(193, 2, 6, 0.4);
    animation: pulse-red-sidebar 2.5s infinite ease-in-out;
}

@keyframes pulse-red-sidebar {
    0%, 100% {
        transform: scale(1);
        -webkit-transform: scale(1);
        box-shadow: 0 0 20px rgba(255, 107, 53, 0.8), 0 0 40px rgba(193, 2, 6, 0.4);
    }

    50% {
        transform: scale(1.03);
        -webkit-transform: scale(1.03);
        box-shadow: 0 0 25px rgba(255, 107, 53, 0.8), 0 0 50px rgba(193, 2, 6, 0.6);
    }
}

/* Offer Header */
.offer-header-sidebar {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    margin-bottom: 8px;
}

.offer-title {
    font-size: 12px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    color: var(--brand-white);
    text-rendering: optimizeLegibility;
}

/* Product Title */
.offer-product-title {
    font-size: 15px; /* Redus pentru real devices */
    font-weight: 600;
    margin-bottom: 8px;
    font-family: "Teko", var(--font-family);
    color: var(--brand-white) !important;
    line-height: 1.1;
    text-rendering: optimizeLegibility;
}

/* Pricing Details */
.pricing-details-sidebar {
    display: flex;
    justify-content: center;
    align-items: baseline;
    gap: 8px;
    flex-wrap: wrap;
    margin-bottom: 12px;
}

.price-old-sidebar {
    color: #9ca3af;
    font-size: 15px;
    font-weight: 400;
    text-decoration: line-through 2px;
    text-decoration-color: #ff4500;
    line-height: 1;
}

.price-new-sidebar {
    color: var(--brand-white);
    font-size: 18px;
    font-weight: 700;
    font-family: 'Teko', var(--font-family);
    letter-spacing: 0.5px;
    line-height: 1;
}

.price-unit-sidebar {
    color: #e5e7eb;
    font-size: 10px;
    font-weight: 400;
    line-height: 1;
}

/* CTA Button - Real device optimized */
.offer-btn-sidebar {
    width: 100%;
    background: linear-gradient(135deg, var(--brand-red) 0%, #aa0205 100%);
    color: var(--brand-white) !important;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.3px;
    animation: ctaPulseSidebar 3s ease-in-out infinite;
    box-shadow: 0 3px 12px rgba(193, 2, 6, 0.4);
    border: none;
    font-family: 'Teko', var(--font-family);
    font-size: 15px !important;
    padding: 9px 12px;
    margin-bottom: 0;
    border-radius: 8px;
    /* Touch optimization */
    -webkit-tap-highlight-color: transparent;
    touch-action: manipulation;
    text-rendering: optimizeLegibility;
}

    .offer-btn-sidebar:hover,
    .offer-btn-sidebar:active {
        background: linear-gradient(135deg, #aa0205 0%, var(--brand-red) 100%);
        transform: translateY(-1px) scale(0.98);
        -webkit-transform: translateY(-1px) scale(0.98);
        box-shadow: 0 6px 20px rgba(193, 2, 6, 0.5);
        color: var(--brand-white) !important;
    }

@keyframes ctaPulseSidebar {
    0%, 100% {
        transform: scale(1);
        -webkit-transform: scale(1);
        box-shadow: 0 3px 12px rgba(193, 2, 6, 0.4);
    }

    50% {
        transform: scale(1.01);
        -webkit-transform: scale(1.01);
        box-shadow: 0 6px 20px rgba(193, 2, 6, 0.6);
    }
}

/* =============================================================================
   TRUST SIGNALS - Real device optimized
   ============================================================================= */



.trust-item {
    display: flex;
    align-items: center;
    padding: 3px 0;
    font-size: 10px; /* Redus pentru real devices */
    color: var(--brand-white);
    line-height: 1.3;
}

    .trust-item:not(:last-child) {
        margin-bottom: 3px;
    }

.trust-icon {
    width: 12px;
    font-size: 10px;
    flex-shrink: 0;
    margin-right: 5px;
    line-height: 1;
}

.trust-text {
    text-rendering: optimizeLegibility;
}

/* =============================================================================
   QUICK CONTACT - Real device optimized
   ============================================================================= */

.quick-contact {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

/* =============================================================================
   BUTTONS - Optimizate pentru real devices
   ============================================================================= */

.btn {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 5px;
    padding: 8px 12px;
    border-radius: 8px;
    font-size: 11px; /* Redus pentru real devices */
    font-weight: 600;
    text-transform: uppercase;
    text-decoration: none;
    cursor: pointer;
    border: none;
    transition: all 0.2s ease;
    min-height: var(--touch-target);
    letter-spacing: 0.3px;
    /* Touch optimization */
    -webkit-tap-highlight-color: transparent;
    touch-action: manipulation;
    text-rendering: optimizeLegibility;
}

    .btn:hover,
    .btn:active {
        transform: translateY(-1px) scale(0.98);
        -webkit-transform: translateY(-1px) scale(0.98);
    }

/* Button WhatsApp */
.btn-whatsapp {
    background: #25d366;
    color: white;
    box-shadow: 0 2px 8px rgba(37, 211, 102, 0.3);
}

    .btn-whatsapp:hover,
    .btn-whatsapp:active {
        background: #20ba5a;
        color: white;
        box-shadow: 0 4px 12px rgba(37, 211, 102, 0.4);
    }

/* Button Phone */
.btn-phone {
    background: transparent;
    color: var(--brand-white);
    border: 2px solid var(--brand-white);
}

    .btn-phone:hover,
    .btn-phone:active {
        background: var(--brand-white);
        color: var(--brand-black);
        box-shadow: 0 2px 8px rgba(255, 255, 255, 0.3);
    }

/* =============================================================================
   CART SIDEBAR - Păstrezi stilurile existente pentru coș
   ============================================================================= */

.right-sidebar {
    background: var(--brand-white);
    color: var(--brand-black);
}

.cart-content-wrapper {
    display: flex;
    flex-direction: column;
    height: 100%;
    padding: var(--spacing-lg);
}

.cart-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: var(--spacing-lg);
    border-bottom: 1px solid #eee;
    padding-bottom: var(--spacing-md);
    flex-shrink: 0;
}

.cart-header-title {
    font-size: 1.1rem; /* Redus pentru real devices */
    font-weight: 600;
    margin: 0;
    color: var(--brand-black);
}

.right-sidebar .btn-close-sidebar {
    background: none;
    border: none;
    color: var(--brand-gray);
    font-size: 22px; /* Redus pentru real devices */
    width: var(--touch-target);
    height: var(--touch-target);
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    border-radius: 4px;
    transition: all 0.2s ease;
    -webkit-tap-highlight-color: transparent;
    touch-action: manipulation;
}

    .right-sidebar .btn-close-sidebar:hover {
        background: var(--brand-light-gray);
        color: var(--brand-red);
    }

.cart-items-container {
    flex: 1;
    overflow-y: auto;
    margin-bottom: var(--spacing-md);
    -webkit-overflow-scrolling: touch;
}

.cart-shipping-progress {
    margin: var(--spacing-lg) 0;
    padding: var(--spacing-md);
    background: var(--brand-light-gray);
    border-radius: 8px;
    flex-shrink: 0;
}

.progress-text-content {
    display: flex;
    align-items: center;
    margin-bottom: var(--spacing-sm);
    font-size: 11px; /* Redus pentru real devices */
    gap: var(--spacing-sm);
}

.progress-track {
    height: 6px;
    background: #e9ecef;
    border-radius: 3px;
    overflow: hidden;
}

.progress-fill {
    height: 100%;
    background: var(--brand-red);
    transition: width 0.3s ease;
    width: 0%;
}

.cart-footer {
    border-top: 1px solid #eee;
    padding-top: var(--spacing-md);
    flex-shrink: 0;
}

.cart-subtotal {
    display: flex;
    justify-content: space-between;
    margin-bottom: var(--spacing-md);
    font-weight: 600;
    font-size: 15px; /* Redus pentru real devices */
}

.checkout-button {
    display: block;
    width: 100%;
    padding: 12px;
    background: var(--brand-red);
    color: white;
    text-align: center;
    text-decoration: none;
    border-radius: 8px;
    font-weight: 600;
    font-size: 14px; /* Redus pentru real devices */
    transition: all 0.2s ease;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    -webkit-tap-highlight-color: transparent;
    touch-action: manipulation;
}

    .checkout-button:hover {
        background: #a00205;
        transform: translateY(-1px);
        color: white;
    }

/* =============================================================================
   RESPONSIVE OPTIMIZATIONS pentru Real Devices
   ============================================================================= */

/* iPhone SE & similar */
@media (max-width: 375px) {
    .sidebar-logo h2 {
        font-size: 20px;
    }

    .tagline {
        font-size: 10px;
    }

    .navigation-title {
        font-size: 14px;
    }

    .nav-text {
        font-size: 14px;
    }

    .nav-subtitle {
        font-size: 10px;
    }

    .special-offer-sidebar {
        padding: 12px;
    }

    .offer-product-title {
        font-size: 14px;
    }

    .price-new-sidebar {
        font-size: 16px;
    }

    .price-old-sidebar {
        font-size: 14px;
    }

    .offer-btn-sidebar {
        font-size: 13px !important;
        padding: 8px 10px;
    }

    .trust-item {
        font-size: 9px;
    }

    .btn {
        font-size: 10px;
        padding: 7px 10px;
    }
}

/* Very small devices */
@media (max-width: 320px) {
    .sidebar-content {
        padding: 12px;
    }

    .sidebar-header {
        padding: 16px 12px;
    }

    .nav-link {
        padding: 8px 0;
        min-height: 44px;
    }

    .special-offer-sidebar {
        padding: 10px;
    }

    .pricing-details-sidebar {
        gap: 6px;
        margin-bottom: 10px;
    }
}

/* Landscape orientation */
@media (max-height: 500px) and (orientation: landscape) {
    .sidebar-content {
        padding: 8px 16px;
    }

    .navigation-section {
        margin-bottom: 16px;
    }

    .special-offer-sidebar {
        padding: 10px;
        margin-bottom: 14px;
    }

    .trust-signals {
        padding: 8px;
        margin-bottom: 10px;
    }

    .nav-link {
        min-height: 40px;
        padding: 6px 0;
    }
}

/* Reduce animation complexity pe devices cu performanță scăzută */
@media (max-width: 480px) {
    .urgent-banner,
    .offer-icon,
    .badge-discount-sidebar,
    .offer-btn-sidebar {
        animation-duration: 3s;
    }
}

/* Disable animations pe conexiuni lente */
@media (prefers-reduced-motion: reduce) {
    .sidebar,
    .overlay-sidebar,
    .nav-link,
    .btn,
    .urgent-banner,
    .offer-icon,
    .badge-discount-sidebar,
    .offer-btn-sidebar {
        animation: none !important;
        transition: none !important;
    }
}

/* =============================================================================
   SCROLLBAR - Real device optimized
   ============================================================================= */

.sidebar::-webkit-scrollbar {
    width: 3px;
}

.sidebar::-webkit-scrollbar-track {
    background: #1a1a1a;
}

.sidebar::-webkit-scrollbar-thumb {
    background: var(--brand-red);
    border-radius: 2px;
}

    .sidebar::-webkit-scrollbar-thumb:hover {
        background: #aa0205;
    }

/* Firefox scrollbar */
.sidebar {
    scrollbar-width: thin;
    scrollbar-color: var(--brand-red) #1a1a1a;
}

/* =============================================================================
   ACCESSIBILITY & PERFORMANCE
   ============================================================================= */

/* Focus states */
.nav-link:focus,
.btn:focus,
.btn-close-sidebar:focus {
    outline: 2px solid #4A90E2;
    outline-offset: 2px;
}

/* Ensure proper touch behavior */
.nav-link,
.btn {
    -webkit-user-select: none;
    -moz-user-select: none;
    -ms-user-select: none;
    user-select: none;
}

/* Force repaint pentru better rendering */
.sidebar.active {
    -webkit-transform: translateX(0) translateZ(0);
    transform: translateX(0) translateZ(0);
}


/* BLOCARE COMPLETĂ PENTRU HOMEPAGE CÂND SIDEBAR-UL ESTE DESCHIS */
body.sidebar-open,
html.sidebar-open {
    overflow: hidden !important;
    height: 100vh !important;
    width: 100vw !important;
}

body.no-scroll {
    position: fixed !important;
    top: 0 !important;
    left: 0 !important;
    right: 0 !important;
    width: 100% !important;
    overflow: hidden !important;
    -webkit-overflow-scrolling: touch !important;
}

/* Blochează toate elementele din homepage să nu mai răspundă */
body.sidebar-open .homepage {
    pointer-events: none !important;
    user-select: none !important;
    -webkit-user-select: none !important;
    -moz-user-select: none !important;
    -ms-user-select: none !important;
    touch-action: none !important;
    -webkit-touch-callout: none !important;
}

    /* Blochează scroll-ul pe toate containerele din homepage */
    body.sidebar-open .homepage * {
        overflow: hidden !important;
        -webkit-overflow-scrolling: auto !important;
    }

/* Permite doar sidebar-urile și overlay-urile să funcționeze */
body.sidebar-open .sidebar,
body.sidebar-open .search-overlay {
    pointer-events: auto !important;
    user-select: auto !important;
    -webkit-user-select: auto !important;
    touch-action: auto !important;
}

/* Permite scroll doar în zonele specifice din sidebar-uri */
body.sidebar-open .sidebar-content,
body.sidebar-open .cart-items-container,
body.sidebar-open .search-body {
    overflow-y: auto !important;
    -webkit-overflow-scrolling: touch !important;
    pointer-events: auto !important;
}

/* iOS Safari fix suplimentar */
@supports (-webkit-touch-callout: none) {
    body.sidebar-open {
        position: fixed !important;
        overflow: hidden !important;
    }
}

/* Android WebView fix */
@media screen and (max-device-width: 767px) {
    body.sidebar-open {
        position: fixed !important;
        width: 100% !important;
        height: 100% !important;
        overflow: hidden !important;
    }
}


/* EXTRA PROTECTION - BLOCHEAZĂ ORICE INTERACȚIUNE CU HOMEPAGE-UL */
body.sidebar-open .homepage,
body.sidebar-open main,
body.sidebar-open .content,
body.sidebar-open .hero-section,
body.sidebar-open .products-section {
    pointer-events: none !important;
    user-select: none !important;
    -webkit-user-select: none !important;
    -moz-user-select: none !important;
    touch-action: none !important;
    -webkit-touch-callout: none !important;
}

/* Permite doar header-ul să rămână funcțional pentru închiderea sidebar-ului */
body.sidebar-open .hero-header,
body.sidebar-open .header-wrapper {
    pointer-events: auto !important;
}

/* ============================================= */
/* FIX SCROLL COS LATERAL */
/* ============================================= */

/* Permite scroll pe containerul de produse (Standard View) */
#cosLateral .cart-items-container {
    overflow-y: auto !important;
    -webkit-overflow-scrolling: touch !important;
    touch-action: pan-y !important; /* Permite gesturi verticale */
    pointer-events: auto !important;
}

/* Permite scroll pe containerul de checkout (Checkout View) */
#cosLateral .checkout-scroll-container {
    overflow-y: auto !important;
    -webkit-overflow-scrolling: touch !important;
    touch-action: pan-y !important;
    pointer-events: auto !important;
}

/* Asigură că wrapper-ul principal nu blochează evenimentele */
#cosLateral .cart-content-wrapper {
    pointer-events: auto !important;
    height: 100% !important; /* Asigură înălțimea completă */
}

/* Când sidebar-ul e activ, forțăm pointer-events */
#cosLateral.active {
    pointer-events: auto !important;
}