/* ==================== SIDEBAR PROFESSIONAL ==================== */

/* Sidebar Container */
.sidebar {
    position: fixed;
    top: 0;
    right: -450px;
    width: 450px;
    height: 100vh;
    z-index: 9999;
    transition: right 0.6s cubic-bezier(0.68, -0.55, 0.265, 1.55);
}

.sidebar.active {
    right: 0;
}

/* Sidebar Overlay */
.sidebar-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.85);
    backdrop-filter: blur(10px);
    opacity: 0;
    visibility: hidden;
    transition: all 0.4s ease;
    z-index: 9998;
}

.sidebar.active .sidebar-overlay {
    opacity: 1;
    visibility: visible;
}

/* Sidebar Content with Professional Background */
.sidebar-content {
    position: relative;
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, 
        #1a0a0f 0%,
        #2d0a1a 25%,
        #1a0a0f 50%,
        #0a0a0a 100%);
    background-size: 200% 200%;
    animation: gradientShift 15s ease infinite;
    box-shadow: -20px 0 60px rgba(201, 162, 39, 0.6),
                -10px 0 30px rgba(212, 175, 55, 0.3);
    padding: 40px 30px;
    display: flex;
    flex-direction: column;
    overflow-y: auto;
    border-left: 3px solid;
    border-image: linear-gradient(180deg, #c9a227, #d4af37, #c9a227) 1;
    position: relative;
}

/* Animated Background Pattern */
.sidebar-content::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-image: 
        radial-gradient(circle at 20% 30%, rgba(201, 162, 39, 0.15) 0%, transparent 50%),
        radial-gradient(circle at 80% 70%, rgba(212, 175, 55, 0.1) 0%, transparent 50%),
        repeating-linear-gradient(45deg, transparent, transparent 40px, rgba(212, 175, 55, 0.02) 40px, rgba(212, 175, 55, 0.02) 80px);
    z-index: 1;
    pointer-events: none;
}

/* Glowing Border Effect */
.sidebar-content::after {
    content: '';
    position: absolute;
    top: -2px;
    right: -2px;
    bottom: -2px;
    left: -2px;
    background: linear-gradient(45deg, 
        #c9a227, #d4af37, #c9a227, #d4af37);
    background-size: 400% 400%;
    border-radius: inherit;
    z-index: -1;
    opacity: 0.6;
    filter: blur(20px);
    animation: borderGlowPulse 4s ease-in-out infinite;
}

@keyframes gradientShift {
    0%, 100% { background-position: 0% 50%; }
    50% { background-position: 100% 50%; }
}

@keyframes borderGlowPulse {
    0%, 100% { opacity: 0.4; }
    50% { opacity: 0.8; }
}

/* All content above background */
.sidebar-content > * {
    position: relative;
    z-index: 2;
}

/* Sidebar Header */
.sidebar-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 50px;
    padding-bottom: 30px;
    border-bottom: 2px solid rgba(212, 175, 55, 0.3);
    animation: slideInRight 0.8s cubic-bezier(0.68, -0.55, 0.265, 1.55) 0.2s both;
}

/* Sidebar Logo */
.sidebar-logo {
    display: flex;
    align-items: center;
    gap: 15px;
}

.sidebar-logo img {
    height: 60px;
    width: auto;
    filter: drop-shadow(0 0 15px rgba(212, 175, 55, 0.6));
    animation: logoFloat 3s ease-in-out infinite;
}

@keyframes logoFloat {
    0%, 100% { transform: translateY(0) rotate(0deg); }
    50% { transform: translateY(-8px) rotate(3deg); }
}

.sidebar-logo-text .logo-ar {
    font-size: 22px;
    font-weight: 900;
    color: #fff;
    text-shadow: 0 0 20px rgba(212, 175, 55, 0.5);
}

.sidebar-logo-text .logo-en {
    font-size: 11px;
    font-weight: 600;
    color: #d4af37;
    letter-spacing: 2px;
}

/* Close Button */
.sidebar-close {
    width: 50px;
    height: 50px;
    background: linear-gradient(135deg, #c9a227, #d4af37);
    border: 2px solid #d4af37;
    border-radius: 50%;
    color: #1a1a1a;
    font-size: 22px;
    cursor: pointer;
    transition: all 0.4s cubic-bezier(0.68, -0.55, 0.265, 1.55);
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 5px 25px rgba(201, 162, 39, 0.6);
}

.sidebar-close:hover {
    transform: rotate(180deg) scale(1.15);
    box-shadow: 0 8px 35px rgba(212, 175, 55, 0.8);
    background: linear-gradient(135deg, #d4af37, #c9a227);
    color: #fff;
}

/* Navigation Links */
.sidebar-nav {
    display: flex;
    flex-direction: column;
    gap: 12px;
    margin-bottom: 50px;
}

.sidebar-link {
    display: flex;
    align-items: center;
    gap: 18px;
    padding: 20px 25px;
    background: linear-gradient(135deg, 
        rgba(201, 162, 39, 0.2), 
        rgba(212, 175, 55, 0.05));
    border: 1px solid rgba(212, 175, 55, 0.2);
    border-radius: 15px;
    color: #fff;
    text-decoration: none;
    font-size: 18px;
    font-weight: 700;
    transition: all 0.4s cubic-bezier(0.68, -0.55, 0.265, 1.55);
    position: relative;
    overflow: hidden;
    animation: slideInRight 0.6s cubic-bezier(0.68, -0.55, 0.265, 1.55) backwards;
}

.sidebar-link:nth-child(1) { animation-delay: 0.3s; }
.sidebar-link:nth-child(2) { animation-delay: 0.4s; }
.sidebar-link:nth-child(3) { animation-delay: 0.5s; }
.sidebar-link:nth-child(4) { animation-delay: 0.6s; }
.sidebar-link:nth-child(5) { animation-delay: 0.7s; }

@keyframes slideInRight {
    from {
        opacity: 0;
        transform: translateX(100px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

/* Shine Effect on Hover */
.sidebar-link::before {
    content: '';
    position: absolute;
    top: 0;
    right: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, 
        transparent, 
        rgba(212, 175, 55, 0.3), 
        transparent);
    transition: right 0.6s ease;
}

.sidebar-link:hover::before {
    right: 100%;
}

.sidebar-link:hover {
    background: linear-gradient(135deg, 
        rgba(201, 162, 39, 0.4), 
        rgba(212, 175, 55, 0.2));
    border-color: #d4af37;
    transform: translateX(-15px) scale(1.05);
    box-shadow: 0 10px 40px rgba(212, 175, 55, 0.4),
                inset 0 0 20px rgba(212, 175, 55, 0.1);
}

.sidebar-link i {
    font-size: 26px;
    color: #d4af37;
    transition: all 0.4s cubic-bezier(0.68, -0.55, 0.265, 1.55);
    text-shadow: 0 0 15px rgba(212, 175, 55, 0.6);
}

.sidebar-link:hover i {
    transform: scale(1.3) rotate(360deg);
    color: #fff;
    filter: drop-shadow(0 0 10px #d4af37);
}

/* Sidebar Info */
.sidebar-info {
    display: flex;
    flex-direction: column;
    gap: 18px;
    padding: 30px 25px;
    background: linear-gradient(135deg, 
        rgba(201, 162, 39, 0.15), 
        rgba(212, 175, 55, 0.08));
    border-radius: 18px;
    border: 1px solid rgba(212, 175, 55, 0.25);
    margin-bottom: 40px;
    animation: fadeInUp 0.8s ease 0.8s both;
    box-shadow: inset 0 0 30px rgba(212, 175, 55, 0.05);
}

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.sidebar-info-item {
    display: flex;
    align-items: center;
    gap: 15px;
    color: #c0c0c0;
    font-size: 15px;
    font-weight: 600;
    transition: all 0.3s ease;
}

.sidebar-info-item:hover {
    color: #fff;
    transform: translateX(-5px);
}

.sidebar-info-item i {
    color: #d4af37;
    font-size: 22px;
    width: 30px;
    text-align: center;
    filter: drop-shadow(0 0 8px rgba(212, 175, 55, 0.5));
}

/* Social Links */
.sidebar-social {
    display: flex;
    gap: 18px;
    justify-content: center;
    animation: fadeInUp 0.8s ease 0.9s both;
}

.sidebar-social a {
    width: 55px;
    height: 55px;
    background: linear-gradient(135deg, 
        rgba(201, 162, 39, 0.3), 
        rgba(212, 175, 55, 0.2));
    border: 2px solid rgba(212, 175, 55, 0.3);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #d4af37;
    font-size: 22px;
    text-decoration: none;
    transition: all 0.5s cubic-bezier(0.68, -0.55, 0.265, 1.55);
    box-shadow: 0 5px 20px rgba(201, 162, 39, 0.3);
}

.sidebar-social a:hover {
    background: linear-gradient(135deg, #c9a227, #d4af37);
    color: #1a1a1a;
    transform: translateY(-12px) rotate(360deg) scale(1.25);
    box-shadow: 0 20px 50px rgba(212, 175, 55, 0.6);
    border-color: #d4af37;
}

/* Scrollbar */
.sidebar-content::-webkit-scrollbar {
    width: 8px;
}

.sidebar-content::-webkit-scrollbar-track {
    background: rgba(0, 0, 0, 0.3);
}

.sidebar-content::-webkit-scrollbar-thumb {
    background: linear-gradient(180deg, #c9a227, #d4af37);
    border-radius: 10px;
}

/* Menu Toggle Button (in navbar) */
.menu-toggle {
    width: 45px;
    height: 45px;
    background: linear-gradient(135deg, #c9a227, #d4af37);
    border: none;
    border-radius: 10px;
    color: #1a1a1a;
    font-size: 20px;
    cursor: pointer;
    transition: all 0.3s;
    display: none;
}

.menu-toggle:hover {
    transform: scale(1.1);
    box-shadow: 0 5px 20px rgba(201, 162, 39, 0.5);
}

/* Mobile Responsive */
@media (max-width: 768px) {
    .sidebar {
        width: 85vw;
        right: -85vw;
    }
    
    .sidebar-content {
        padding: 25px 20px;
    }
    
    .sidebar-link {
        font-size: 16px;
        padding: 16px 20px;
    }
    
    .menu-toggle {
        display: flex;
        align-items: center;
        justify-content: center;
    }
    
    .nav-links {
        display: none !important;
    }
}

@media (max-width: 480px) {
    .sidebar {
        width: 95vw;
        right: -95vw;
    }
}
