/* ============================================
   Light Theme Sidebar Inside Main Content
   ============================================ */

.content-with-sidebar {
    display: flex;
    gap: 24px;
    max-width: 1200px;
    margin: 0 auto;
    width: 100%;
}

.sidebar-nav {
    width: 220px;
    flex-shrink: 0;
    position: sticky;
    top: 80px;
    align-self: flex-start;
    max-height: calc(100vh - 100px);
    display: flex;
    flex-direction: column;
    background: #ffffff;
    border: 1px solid #e8eaed;
    border-radius: 12px;
    box-shadow: 0 2px 16px rgba(0, 0, 0, 0.04);
    overflow: hidden;
}

.sidebar-nav-inner {
    display: flex;
    flex-direction: column;
    gap: 3px;
    padding: 16px 10px;
    overflow-y: auto;
    height: 100%;
    scrollbar-width: thin;
    scrollbar-color: #d0d0d8 transparent;
}

.sidebar-nav-inner::-webkit-scrollbar { width: 4px; }
.sidebar-nav-inner::-webkit-scrollbar-track { background: transparent; }
.sidebar-nav-inner::-webkit-scrollbar-thumb { background: #d0d0d8; border-radius: 10px; }

.sidebar-close-btn { display: none; }

.main-content {
    flex: 1;
    min-width: 0;
}

.sidebar-nav-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 11px 14px;
    border-radius: 10px;
    position: relative;
    cursor: pointer;
    transition: all 0.2s ease;
    color: #4a4a5a;
    text-decoration: none;
    background: transparent;
    white-space: nowrap;
    font-family: 'Inter', sans-serif;
    flex-shrink: 0;
    font-weight: 500;
}
.sidebar-nav-item:hover { background: #f0f1f4; color: #1a1a2e; }

/* --- Active State --- */
.sidebar-nav-item.active {
    background: #e6f9ef;
    color: #1a1a2e;
    font-weight: 600;
}
.sidebar-nav-item.active::before {
    content: '';
    position: absolute;
    left: 4px;
    top: 50%;
    transform: translateY(-50%);
    width: 3px;
    height: 22px;
    background: linear-gradient(180deg, #009933, #00802b);
    border-radius: 3px;
}

/* --- Special Offer --- */
.sidebar-nav-item.special {
    background: linear-gradient(135deg, #e6f9ef, #cceed9);
    border: 1px solid #a3e0bb;
    color: #009933;
    font-weight: 600;
}
.sidebar-nav-item.special:hover { background: linear-gradient(135deg, #cceed9, #a3e0bb); border-color: #70d494; }
.sidebar-nav-item.special .sidebar-nav-label { color: #009933; font-weight: 600; }

.sidebar-nav-icon { width: 20px; height: 20px; flex-shrink: 0; transition: transform 0.2s ease; stroke-width: 2; }
.sidebar-nav-item:hover .sidebar-nav-icon { transform: scale(1.1); }

.sidebar-nav-label { font-family: 'Inter', sans-serif; font-size: 0.82rem; font-weight: 500; letter-spacing: 0.01em; }

.sidebar-nav-badge {
    position: absolute; top: 6px; right: 10px;
    background: #dc2626; color: #ffffff;
    font-size: 0.6rem; font-weight: 700;
    min-width: 18px; height: 18px; border-radius: 9px;
    display: flex; align-items: center; justify-content: center;
    padding: 0 6px; font-family: 'Inter', sans-serif;
}

.sidebar-nav-divider { width: 70%; height: 1px; background: #e8eaed; margin: 8px auto; border-radius: 1px; flex-shrink: 0; }

.sidebar-overlay { display: none; position: fixed; top: 0; left: 0; width: 100%; height: 100%; background: rgba(0,0,0,0.5); z-index: 1998; opacity: 0; transition: opacity 0.3s ease; }
.sidebar-overlay.active { display: block; opacity: 1; }

/* ============ MOBILE ============ */
@media (max-width: 1024px) {
    .content-with-sidebar {
        flex-direction: column;
        gap: 0;
    }
    
    .sidebar-nav {
        position: fixed; 
        left: -280px; 
        top: 0; 
        bottom: 0;
        width: 260px; 
        z-index: 1999;
        display: flex !important; 
        flex-direction: column;
        background: #ffffff; 
        border-right: 1px solid #e8eaed;
        border-radius: 0;
        box-shadow: 8px 0 40px rgba(0,0,0,0.15);
        transition: left 0.35s cubic-bezier(0.4,0,0.2,1);
        max-height: 100vh;
    }
    
    .sidebar-nav.open { left: 0; }
    .sidebar-nav-inner { height: 100%; padding-top: 70px; padding-bottom: 100px; overflow-y: auto; }
    
    .sidebar-close-btn {
        position: absolute; top: 16px; right: 16px;
        width: 36px; height: 36px; border-radius: 50%;
        background: #f0f1f4; border: 1px solid #e8eaed;
        color: #4a4a5a; font-size: 1.2rem; cursor: pointer;
        display: flex; align-items: center; justify-content: center;
        z-index: 2000; transition: all 0.25s;
    }
    .sidebar-close-btn:hover { background: #e8eaed; color: #1a1a2e; }
}

/* ============ DESKTOP RESPONSIVE ============ */
@media (min-width: 1025px) and (max-width: 1399px) {
    .sidebar-nav { width: 200px; }
    .sidebar-nav-item { padding: 10px 12px; gap: 10px; }
    .sidebar-nav-label { font-size: 0.78rem; }
    .sidebar-nav-icon { width: 18px; height: 18px; }
    .content-with-sidebar { max-width: 1100px; }
}

@media (min-width: 1400px) {
    .sidebar-nav { width: 240px; }
    .sidebar-nav-inner { padding: 20px 12px; }
    .sidebar-nav-item { padding: 13px 16px; gap: 14px; border-radius: 12px; }
    .sidebar-nav-label { font-size: 0.88rem; }
    .sidebar-nav-icon { width: 22px; height: 22px; }
    .content-with-sidebar { max-width: 1300px; }
}