/* * Sidebar Component Styles
 * Dosya: /public/assets/css/core/sidebar.css
 */

.sidebar-content {
    width: 100%;
    overflow: visible; 
}

/* --- KULLANICI KARTI --- */
.user-card {
    background: var(--bg-surface);
    border: 1px solid var(--border-subtle);
    border-radius: var(--radius-md);
    margin-bottom: 1.5rem;
    overflow: hidden;
}

.user-card-body {
    padding: 0.75rem;
    text-align: center;
}

.user-avatar-wrapper {
    position: relative;
    display: inline-block;
    margin-bottom: 1rem;
}

.user-avatar-lg {
    width: 80px;
    height: 80px;
    border-radius: 50%;
    object-fit: cover;
    border: 3px solid var(--bg-surface);
    box-shadow: var(--shadow-sm);
    background-color: var(--bg-border);
}

.admin-badge {
    position: absolute;
    bottom: 0;
    right: 0;
    background: var(--primary);
    color: white;
    width: 24px;
    height: 24px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.75rem;
    border: 2px solid var(--bg-surface);
}

.user-name {
    font-size: 1.1rem;
    font-weight: 700;
    margin: 0 0 0.25rem 0;
    color: var(--text-main);
}

.user-handle {
    font-size: 0.9rem;
    color: var(--text-muted);
    margin-bottom: 1.25rem;
}

/* --- PUAN KUTUSU --- */
.user-stats-box {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem; 
    width: 100%;
    background: var(--bg-body); 
    border: 1px solid var(--border-subtle);
    border-radius: var(--radius-sm);
    padding: 0.75rem 1rem;
    margin-bottom: 1rem;
}

.stat-value {
    font-size: 1.1rem;
    font-weight: 800;
    color: var(--primary);
    line-height: 1;
}

.stat-label {
    font-size: 0.85rem;
    font-weight: 600;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

/* --- BUTONLAR --- */
.sidebar-actions {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
    width: 100%;
}

.btn-sidebar-primary,
.btn-sidebar-secondary {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    width: 100%;
    padding: 0.75rem;
    border-radius: var(--radius-sm);
    font-weight: 600;
    font-size: 0.9rem;
    text-decoration: none;
    transition: all 0.2s ease;
}

.btn-sidebar-primary {
    background: var(--primary);
    color: white;
    border: 1px solid transparent;
}
.btn-sidebar-primary:hover {
    background: var(--primary-hover);
    transform: translateY(-1px);
}

.btn-sidebar-secondary {
    background: var(--bg-surface);
    color: var(--text-main);
    border: 1px solid var(--border-subtle);
}
.btn-sidebar-secondary:hover {
    background: var(--bg-body);
    border-color: var(--border-focus);
}

/* --- MİSAFİR --- */
.guest-welcome {
    text-align: center;
}
.guest-icon {
    width: 56px; height: 56px;
    background: var(--primary-soft);
    color: var(--primary);
    border-radius: 50%;
    display: flex; align-items: center; justify-content: center;
    font-size: 1.5rem;
    margin: 0 auto 1rem;
}
.guest-title { font-size: 1.1rem; font-weight: 700; margin-bottom: 0.5rem; color: var(--text-main); }
.guest-desc { font-size: 0.9rem; color: var(--text-muted); margin-bottom: 1.5rem; line-height: 1.4; }

/* --- İSTATİSTİKLER KARTI --- */
.stats-card {
    background: var(--bg-surface);
    border: 1px solid var(--border-subtle);
    border-radius: var(--radius-md);
    margin-bottom: 1.5rem;
    overflow: hidden;
}

.stats-header {
    padding: 1rem;
    border-bottom: 1px solid var(--border-subtle);
    background: var(--bg-surface-hover);
}

.stats-title {
    font-size: 0.9rem;
    font-weight: 700;
    margin: 0;
    color: var(--text-main);
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.stats-list { display: flex; flex-direction: column; }

.stats-row {
    display: flex;
    justify-content: space-between;
    padding: 0.8rem 1rem;
    border-bottom: 1px solid var(--border-subtle);
    font-size: 0.9rem;
}
.stats-row:last-child { border-bottom: none; }

.stats-row-label { color: var(--text-muted); }
.stats-row-value { font-weight: 700; color: var(--text-main); }

/* --- FOOTER LINKS --- */
.sidebar-footer { text-align: center; padding: 0 0.5rem; }
.footer-links { margin-bottom: 0.5rem; font-size: 0.8rem; color: var(--text-muted); display: flex; justify-content: center; flex-wrap: wrap; gap: 0.5rem;}
.footer-links a { text-decoration: none; color: inherit; transition: color 0.2s; }
.footer-links a:hover { color: var(--primary); }
.footer-copy { display: block; font-size: 0.75rem; color: var(--text-dim); }

/* --- MOBILE SIDEBAR (OFF-CANVAS DRAWER) --- */
@media (max-width: 991px) {
    .app-sidebar {
        display: block !important;
        position: fixed;
        top: 0;
        left: 0;
        width: 85%; 
        max-width: 320px;
        height: 100vh;
        height: 100dvh;
        background: var(--bg-surface);
        z-index: 1050; 
        transform: translateX(-100%);
        transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1);
        overflow-y: auto;
        border-right: 1px solid var(--border-subtle);
        box-shadow: none;
    }

    .app-sidebar.active {
        transform: translateX(0);
        box-shadow: 5px 0 15px rgba(0,0,0,0.1);
    }

    .sidebar-overlay {
        position: fixed;
        top: 0;
        left: 0;
        width: 100%;
        height: 100%;
        background: rgba(0, 0, 0, 0.4);
        z-index: 1040;
        opacity: 0;
        visibility: hidden;
        transition: opacity 0.3s ease, visibility 0.3s ease;
        backdrop-filter: blur(4px);
        -webkit-backdrop-filter: blur(4px);
    }

    .sidebar-overlay.active {
        opacity: 1;
        visibility: visible;
    }
    
    .sidebar-content {
        padding: 1.5rem;
    }
}

/* --- DESKTOP STICKY SIDEBAR (YENİ EKLENDİ) --- */
@media (min-width: 992px) {
    .app-sidebar {
        position: -webkit-sticky;
        position: sticky;
        top: 90px; /* Header (70px) + 20px */
        z-index: 90;
        
        align-self: start; 
        
        /* SCROLL İPTALİ: İçerik ne kadarsa o kadar yer kaplasın */
        height: auto; 
        max-height: none; 
        overflow: visible; 
    }
}

    /* Webkit (Chrome/Safari) Scrollbar Stili */
    .app-sidebar::-webkit-scrollbar {
        width: 4px;
    }
    .app-sidebar::-webkit-scrollbar-track {
        background: transparent;
    }
    .app-sidebar::-webkit-scrollbar-thumb {
        background-color: var(--border-subtle);
        border-radius: 4px;
    }
}