* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Lexend', sans-serif;
    background: #F5F1E8;
    color: #1E1E1E;
    overflow-x: hidden;
}

::-webkit-scrollbar {
    width: 6px;
}
::-webkit-scrollbar-track {
    background: #e4dfd4;
}
::-webkit-scrollbar-thumb {
    background: #26648e;
    border-radius: 10px;
}

/* ========== SIDEBAR ========== */
.logo-area {
    margin-bottom: 1rem;
    padding-left: 0.5rem;
    text-align: center;
}
.logo-area h1 {
    font-size: 1.8rem;
    font-weight: 600;
    background: linear-gradient(135deg, #26648e 0%, #3f8f3f 100%);
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
    letter-spacing: -0.5px;
}
.logo-area p {
    font-size: 0.75rem;
    color: #6b6a69;
    margin-top: 4px;
}
.sidebar-logo {
    max-width: 150px;
    height: auto;
    display: block;
    margin: 0 auto;
}

.nav-menu {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}
.nav-item {
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: 0.9rem 1rem;
    border-radius: 14px;
    font-weight: 500;
    font-size: 1rem;
    color: #2c3e42;
    transition: all 0.2s;
    cursor: pointer;
}
.nav-item i {
    width: 28px;
    font-size: 1.3rem;
    color: #26648e;
}
.nav-item span {
    flex: 1;
}
.nav-item:hover {
    background: rgba(38,100,142,0.08);
}
.nav-item.active {
    background: rgba(38,100,142,0.12);
    color: #26648e;
    font-weight: 600;
    border-left: 3px solid #26648e;
}
.nav-item.active i {
    color: #26648e;
}

.user-footer {
    margin-top: auto;
    padding-top: 2rem;
    border-top: 1px solid rgba(0,0,0,0.05);
}
.user-card {
    display: flex;
    align-items: center;
    gap: 12px;
    background: #F5F1E8;
    padding: 12px;
    border-radius: 24px;
}
.user-avatar {
    width: 44px;
    height: 44px;
    background: #26648e;
    border-radius: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-weight: bold;
    font-size: 1.2rem;
    box-shadow: 0 2px 6px rgba(0,0,0,0.1);
}
.user-info {
    flex: 1;
}
.user-info .name {
    font-weight: 600;
    font-size: 0.9rem;
}
.user-info .username {
    font-size: 0.7rem;
    color: #5b6e6b;
}
.logout-btn {
    background: none;
    border: none;
    font-size: 1.2rem;
    color: #9e8b6e;
    cursor: pointer;
    transition: 0.2s;
}
.logout-btn:hover {
    color: #c23b22;
}

.main-content {
    margin-left: 280px;
    min-height: 100vh;
    padding: 2rem 2.5rem;
    background: #FCF9F4;
}

.page-header {
    margin-bottom: 2rem;
}
.page-header h2 {
    font-size: 1.8rem;
    font-weight: 600;
    color: #1e2a32;
    letter-spacing: -0.3px;
}
.page-header p {
    color: #5f6c6b;
    margin-top: 6px;
}

.card {
    background: white;
    border-radius: 28px;
    padding: 1.5rem;
    box-shadow: 0 6px 14px rgba(0,0,0,0.02), 0 1px 2px rgba(0,0,0,0.05);
    border: 1px solid rgba(38,100,142,0.1);
    transition: all 0.2s;
}

.skill-badge {
    background: #26648e10;
    color: #26648e;
    padding: 4px 12px;
    border-radius: 40px;
    font-size: 0.7rem;
    font-weight: 500;
}

.btn-primary {
    background: #26648e;
    color: white;
    border: none;
    padding: 10px 20px;
    border-radius: 40px;
    font-weight: 500;
    transition: 0.2s;
    cursor: pointer;
    font-family: 'Lexend', sans-serif;
}
.btn-primary:hover {
    background: #1d4f72;
    transform: translateY(-1px);
}

.btn-outline {
    background: transparent;
    border: 1px solid #26648e;
    color: #26648e;
    padding: 8px 18px;
    border-radius: 40px;
    cursor: pointer;
    font-family: 'Lexend', sans-serif;
}
.btn-outline:hover {
    background: rgba(38,100,142,0.05);
}

.btn-secondary {
    background: #e0e0e0;
    color: #555;
    border: none;
    padding: 10px 20px;
    border-radius: 40px;
    font-weight: 500;
    cursor: pointer;
}

/* Login form */
.login-container {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(145deg, #eef2e9 0%, #f7f3ea 100%);
}
.login-box {
    background: white;
    border-radius: 48px;
    padding: 2.5rem;
    width: 420px;
    max-width: 90%;
    box-shadow: 0 25px 45px rgba(0,0,0,0.1);
    border: 1px solid rgba(38,100,142,0.2);
}
.login-box h2 {
    color: #26648e;
    margin-bottom: 0.5rem;
}
.input-group {
    margin-bottom: 1.2rem;
}
.input-group label {
    font-size: 0.8rem;
    font-weight: 500;
    color: #3f554f;
}
.input-group input, .input-group textarea {
    width: 100%;
    padding: 12px 16px;
    border: 1px solid #ddd8cd;
    border-radius: 60px;
    margin-top: 5px;
    font-size: 1rem;
    background: #fefef9;
    font-family: 'Lexend', sans-serif;
}
.input-group textarea {
    border-radius: 20px;
    resize: vertical;
}
.error-msg {
    color: #c84c2e;
    font-size: 0.8rem;
    margin-top: 5px;
}

/* Users grid */
.users-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 1.5rem;
    margin-top: 1rem;
}
.user-card-compact {
    background: white;
    border-radius: 24px;
    padding: 1rem;
    display: flex;
    align-items: center;
    gap: 1rem;
    box-shadow: 0 2px 8px rgba(0,0,0,0.02);
    border: 1px solid #ece3d8;
}
.user-avatar-sm {
    width: 52px;
    height: 52px;
    background: #26648e;
    border-radius: 60px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-weight: bold;
    font-size: 1.2rem;
}
.credit-badge {
    background: #3f8f3f20;
    color: #3f8f3f;
    border-radius: 20px;
    padding: 2px 8px;
    font-size: 0.7rem;
    font-weight: 600;
}

.loading-spinner {
    text-align: center;
    padding: 3rem;
    color: #26648e;
}

/* Profile page */
.profile-header {
    display: flex;
    gap: 2rem;
    align-items: center;
    margin-bottom: 2rem;
    flex-wrap: wrap;
}
.profile-avatar-large {
    width: 100px;
    height: 100px;
    background: #26648e;
    border-radius: 60px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-weight: bold;
    font-size: 2.5rem;
    position: relative;
}
.profile-avatar-large img {
    width: 100%;
    height: 100%;
    border-radius: 60px;
    object-fit: cover;
}
.avatar-edit-btn {
    position: absolute;
    bottom: 0;
    right: 0;
    background: #26648e;
    border-radius: 30px;
    padding: 6px;
    cursor: pointer;
    font-size: 0.8rem;
}
.profile-info h2 {
    font-size: 1.8rem;
    margin-bottom: 0.25rem;
}
.verified-badge {
    color: #26648e;
    margin-left: 8px;
    font-size: 1rem;
}
.profile-stats {
    display: flex;
    gap: 2rem;
    margin: 1rem 0;
}
.stat-item {
    text-align: center;
}
.stat-value {
    font-size: 1.5rem;
    font-weight: 700;
    color: #26648e;
}
.stat-label {
    font-size: 0.7rem;
    color: #6c757d;
}

.profile-details {
    margin-top: 1.5rem;
}
.detail-row {
    display: flex;
    padding: 12px 0;
    border-bottom: 1px solid #ece3d8;
}
.detail-label {
    width: 140px;
    font-weight: 500;
    color: #26648e;
}
.detail-value {
    flex: 1;
    color: #1e2a32;
}
.detail-value input, .detail-value textarea {
    width: 100%;
    padding: 8px 12px;
    border: 1px solid #ddd8cd;
    border-radius: 12px;
    font-family: 'Lexend', sans-serif;
}
.edit-mode .detail-value {
    background: #fef9ef;
}
.profile-actions {
    display: flex;
    gap: 1rem;
    margin-top: 2rem;
}

/* Modal */
.modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0,0,0,0.5);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 2000;
}
.modal-content {
    background: white;
    padding: 2rem;
    border-radius: 28px;
    width: 400px;
    max-width: 90%;
}
.modal-close {
    float: right;
    font-size: 1.5rem;
    cursor: pointer;
}

/* Responsive */
@media (max-width: 860px) {
    .sidebar {
        width: 240px;
    }
    .main-content {
        margin-left: 240px;
        padding: 1.5rem;
    }
}
@media (max-width: 680px) {
    .sidebar {
        transform: translateX(-100%);
        z-index: 1100;
    }
    .sidebar.open-mobile {
        transform: translateX(0);
    }
    .main-content {
        margin-left: 0;
    }
    .menu-toggle {
        display: block;
        position: fixed;
        top: 1rem;
        left: 1rem;
        z-index: 1200;
        background: #26648e;
        color: white;
        padding: 8px 12px;
        border-radius: 40px;
        cursor: pointer;
    }
    .profile-header {
        flex-direction: column;
        text-align: center;
    }
    .profile-stats {
        justify-content: center;
    }
    .detail-row {
        flex-direction: column;
    }
    .detail-label {
        width: auto;
        margin-bottom: 5px;
    }
}
.menu-toggle {
    display: none;
}



 .modal-overlay {
        position: fixed;
        top: 0;
        left: 0;
        width: 100%;
        height: 100%;
        background: rgba(0, 0, 0, 0);
        display: flex;
        align-items: flex-end;
        justify-content: center;
        z-index: 2000;
        transition: background 0.3s ease;
    }
    
    .modal-overlay.active {
        background: rgba(0, 0, 0, 0.5);
    }
    
    /* Bottom Sheet - alulról feljövő panel */
    .modal-bottom-sheet {
        background: white;
        width: 100%;
        max-width: 500px;
        border-radius: 28px 28px 0 0;
        padding: 20px 24px 32px 24px;
        transform: translateY(100%);
        transition: transform 0.3s cubic-bezier(0.2, 0.9, 0.4, 1.1);
        box-shadow: 0 -5px 20px rgba(0, 0, 0, 0.1);
    }
    
    .modal-overlay.active .modal-bottom-sheet {
        transform: translateY(0);
    }
    
    /* Húzható jelzőcsík */
    .modal-handle {
        width: 40px;
        height: 4px;
        background: #ddd;
        border-radius: 4px;
        margin: 0 auto 20px auto;
    }
    
    /* Gombok stílusa */
    .modal-btn {
        width: 100%;
        padding: 14px 20px;
        border-radius: 60px;
        font-weight: 600;
        font-size: 1rem;
        cursor: pointer;
        transition: all 0.2s ease;
        border: none;
        font-family: 'Lexend', sans-serif;
    }
    
    .modal-btn-primary {
        background: #26648e;
        color: white;
    }
    
    .modal-btn-primary:hover {
        background: #1d4f72;
        transform: scale(1.02);
    }
    
    .modal-btn-primary:active {
        transform: scale(0.98);
    }
    
    .modal-btn-secondary {
        background: #f5f5f5;
        color: #26648e;
        border: 1px solid #e0e0e0;
    }
    
    .modal-btn-secondary:hover {
        background: #eeeeee;
        transform: scale(1.02);
    }
    
    .modal-btn-secondary:active {
        transform: scale(0.98);
    }
    
    .modal-btn-text {
        background: none;
        border: none;
        color: #999;
        cursor: pointer;
        padding: 12px;
        font-size: 0.85rem;
        transition: color 0.2s;
    }
    
    .modal-btn-text:hover {
        color: #666;
    }
    
    /* Mobil optimalizáció */
    @media (max-width: 600px) {
        .modal-bottom-sheet {
            border-radius: 24px 24px 0 0;
            padding: 16px 20px 28px 20px;
        }
        
        .modal-btn {
            padding: 12px 16px;
        }
    }
    
    /* Desktopon középen is megjelenhet */
    @media (min-width: 768px) {
        .modal-overlay {
            align-items: center;
        }
        
        .modal-bottom-sheet {
            border-radius: 28px;
            transform: translateY(30px);
            opacity: 0;
            transition: transform 0.3s cubic-bezier(0.2, 0.9, 0.4, 1.1), opacity 0.2s ease;
        }
        
        .modal-overlay.active .modal-bottom-sheet {
            transform: translateY(0);
            opacity: 1;
        }
        
        .modal-handle {
            display: none;
        }
    }