/* ==========================================================================
   Mobile Drawer Styles (Main Site)
   ========================================================================== */

.mobile-drawer-overlay {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background-color: rgba(0, 0, 0, 0.5);
    z-index: 9998;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.3s ease, visibility 0.3s ease;
}

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

.mobile-drawer {
    display: none;
    position: fixed;
    top: 0;
    left: -100%;
    right: auto;
    width: 85%;
    max-width: 480px;
    height: 100dvh;
    background-color: var(--bg-primary);
    z-index: 9999;
    border-radius: 0 12px 12px 0;
    box-shadow: 2px 0 10px rgba(0, 0, 0, 0.1);
    flex-direction: column;
    transition: left 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    overflow-y: auto;
}

.mobile-drawer.active {
    left: 0;
    right: auto;
}

.mobile-drawer-header {
    padding: 10px 20px;
    display: flex;
    justify-content: flex-start;
    border-bottom: 1px solid var(--border-color);
}

.drawer-close-btn {
    background: none;
    border: none;
    color: var(--text-secondary);
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 8px 0;
    font-size: 15px;
    font-weight: 500;
}

.drawer-close-btn:hover {
    color: var(--text-primary);
}

.mobile-drawer-content {
    display: flex;
    flex-direction: column;
    flex: 1;
}

.drawer-link {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 10px 20px;
    color: var(--text-primary);
    text-decoration: none;
    font-size: 15px;
    font-weight: 500;
    transition: background-color 0.2s ease;
}

.drawer-link:hover {
    background-color: var(--bg-secondary);
    opacity: 1;
}

.drawer-link svg {
    color: var(--text-secondary);
}

.drawer-divider {
    height: 1px;
    background-color: var(--border-color);
    margin: 16px 24px;
}

.drawer-footer {
    padding: 8px;
    margin-top: auto;
    display: flex;
    align-items: center;
    justify-content: space-between;
    border-top: 1px solid var(--border-color);
}

.drawer-logout-btn {
    padding: 10px 13px;
    border-radius: 8px;
    color: var(--text-secondary);
    background: transparent;
    border: none;
    cursor: pointer;
    transition: background-color 0.3s ease, color 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.drawer-logout-btn:hover {
    color: var(--text-primary);
    background-color: var(--bg-secondary);
}

.drawer-logout-btn svg {
    width: 20px;
    height: 20px;
}

.drawer-profile {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 4px;
    overflow: hidden;
}

.drawer-profile-img {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    object-fit: cover;
    flex-shrink: 0;
}

.drawer-profile-info {
    display: flex;
    flex-direction: column;
    overflow: hidden;
    white-space: nowrap;
}

.drawer-profile-name {
    font-size: var(--font-14, 14px);
    color: var(--text-primary);
    font-weight: 500;
    text-overflow: ellipsis;
    overflow: hidden;
}

.drawer-profile-email {
    font-size: 11px;
    color: var(--text-secondary);
    text-overflow: ellipsis;
    overflow: hidden;
}

/* ==========================================================================
   Responsive Media Queries (Standard Descending: 1024px -> 768px -> 480px -> 360px)
   ========================================================================== */

/* Tablet Landscape */
@media (max-width: 1024px) {
    .mobile-drawer-overlay {
        display: block;
    }

    .mobile-drawer {
        display: flex;
        max-width: 420px;
    }
}

/* Tablet */
@media (max-width: 768px) {
    .mobile-drawer {
        max-width: 380px;
    }
}

/* Mobile */
@media (max-width: 480px) {
    .mobile-drawer {
        width: 88%;
        max-width: 340px;
    }

    .drawer-link {
        padding: 9px 16px;
        font-size: 14.5px;
    }

    .mobile-drawer-header {
        padding: 8px 16px;
    }
}

/* Very Small Mobile */
@media (max-width: 360px) {
    .mobile-drawer {
        width: 92%;
        max-width: 300px;
    }

    .drawer-link {
        padding: 8px 14px;
        font-size: 14px;
    }
}
