/* ================================================
   FLOATING SIDEBAR NAVIGATION
   ================================================ */

.sidebar-nav {
    position: fixed;
    left: 24px;
    top: 50%;
    transform: translateY(-50%);
    z-index: 1000;
    background: rgba(255, 255, 255, 0.95);
    border-radius: 24px;
    padding: 16px 12px;
    box-shadow: 0 8px 32px rgba(232, 165, 208, 0.3),
                0 0 0 1px rgba(232, 165, 208, 0.1);
    backdrop-filter: blur(20px);
    transition: all 0.3s ease;
}

.sidebar-logo {
    padding-bottom: 16px;
    margin-bottom: 16px;
    border-bottom: 2px solid #F5F5F5;
}

.sidebar-items {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.sidebar-item {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 48px;
    height: 48px;
    border-radius: 16px;
    color: #666;
    text-decoration: none;
    transition: all 0.3s ease;
    background: transparent;
}

.sidebar-item svg {
    width: 24px;
    height: 24px;
    transition: all 0.3s ease;
}

.sidebar-item:hover {
    background: linear-gradient(135deg, #FFF5F3 0%, #F8E8F5 100%);
    color: #E8A5D0;
    transform: scale(1.05);
}

.sidebar-item:active {
    transform: scale(0.95);
}

/* Special button (Free Lesson) */
.sidebar-item-special {
    background: linear-gradient(135deg, #FFB4A8 0%, #E8A5D0 100%);
    color: white;
    margin-top: 8px;
    box-shadow: 0 4px 16px rgba(232, 165, 208, 0.3);
}

.sidebar-item-special:hover {
    background: linear-gradient(135deg, #FFA898 0%, #D895C0 100%);
    transform: scale(1.1);
    box-shadow: 0 6px 20px rgba(232, 165, 208, 0.4);
}

/* Tooltip on hover */
.sidebar-item::after {
    content: attr(title);
    position: absolute;
    left: calc(100% + 16px);
    background: #1A1A1A;
    color: white;
    padding: 8px 12px;
    border-radius: 8px;
    font-size: 14px;
    font-weight: 500;
    white-space: nowrap;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.3s ease;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
}

.sidebar-item::before {
    content: '';
    position: absolute;
    left: calc(100% + 8px);
    border: 4px solid transparent;
    border-right-color: #1A1A1A;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.3s ease;
}

.sidebar-item:hover::after,
.sidebar-item:hover::before {
    opacity: 1;
}

/* Animation on page load */
@keyframes slideInFromLeft {
    from {
        opacity: 0;
        transform: translateY(-50%) translateX(-100px);
    }
    to {
        opacity: 1;
        transform: translateY(-50%) translateX(0);
    }
}

.sidebar-nav {
    animation: slideInFromLeft 0.6s ease-out;
}

/* ================================================
   MOBILE RESPONSIVE
   ================================================ */

@media (max-width: 768px) {
    .sidebar-nav {
        left: 50%;
        top: auto;
        bottom: 50px;
        transform: translateX(-50%) scale(1.2);
        display: flex;
        flex-direction: row;
        align-items: center;
        padding: 8px 10px;
        border-radius: 24px;
        width: auto;
        max-width: calc(100vw - 24px);
    }

    .sidebar-logo {
        padding: 0;
        margin: 0;
        border: none;
    }

    .sidebar-items {
        display: flex;
        flex-direction: row;
        gap: 3px;
        flex-wrap: nowrap;
    }

    .sidebar-item {
        width: 36px;
        height: 36px;
        border-radius: 12px;
    }

    .sidebar-item svg {
        width: 17px;
        height: 17px;
    }

    /* Hide tooltips on mobile */
    .sidebar-item::after,
    .sidebar-item::before {
        display: none;
    }

    /* Adjust animation for bottom position */
    @keyframes slideInFromBottom {
        from {
            opacity: 0;
            transform: translateX(-50%) translateY(100px);
        }
        to {
            opacity: 1;
            transform: translateX(-50%) translateY(0);
        }
    }

    .sidebar-nav {
        animation: slideInFromBottom 0.6s ease-out;
    }

    .sidebar-item-special {
        margin-top: 0;
        margin-left: 6px;
    }
}

@media (max-width: 480px) {
    .sidebar-nav {
        bottom: 40px;
        padding: 6px 8px;
        border-radius: 20px;
        transform: translateX(-50%) scale(1.15);
    }

    .sidebar-item {
        width: 34px;
        height: 34px;
        border-radius: 10px;
    }

    .sidebar-item svg {
        width: 15px;
        height: 15px;
    }

    .sidebar-items {
        gap: 2px;
    }

    .sidebar-logo {
        margin-right: 0;
        padding-right: 0;
    }
}

/* Ensure sidebar is above other content but below popups */
.sidebar-nav {
    z-index: 1000;
}

/* Add smooth scrolling for anchor links */
html {
    scroll-behavior: smooth;
}

/* Prevent content from being hidden behind sidebar on mobile */
@media (max-width: 768px) {
    body {
        padding-bottom: 120px;
    }
}
