:root {
    --bg-color: #f4f9f9;
    --card-bg: #ffffff;
    --primary-teal: #1B8387;
    --primary-gradient: linear-gradient(135deg, #64d8cb, #1B8387);
    --text-main: #2c3e50;
    --text-muted: #7f8c8d;
    --shadow: 0 10px 30px rgba(0, 0, 0, 0.05);
}

.dark-mode {
    --bg-color: #121212;
    --card-bg: #1e1e1e;
    --text-main: #e0e0e0;
    --text-muted: #b0b0b0;
    --shadow: 0 10px 40px rgba(0, 0, 0, 0.4);
}

* { 
    margin: 0; 
    padding: 0; 
    box-sizing: border-box; 
    font-family: 'Poppins', sans-serif; 
}

body {
    background-color: var(--bg-color);
    color: var(--text-main);
    transition: all 0.3s ease;
    padding: 40px 20px;
}

.container {
    display: flex;
    justify-content: center;
    align-items: flex-start;
    gap: 30px;
    max-width: 1200px;
    margin: 0 auto;
}

.main-content { 
    flex: 2; 
}

.sidebar { 
    flex: 1; 
    margin-top: 70px; 
} 

.header-wrapper {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 25px;
}

.logo-section p { 
    font-size: 12px; 
    color: var(--text-muted); 
}

.btn-back {
    background: var(--card-bg);
    border: 1.5px solid var(--primary-teal);
    color: var(--primary-teal);
    padding: 8px 18px;
    border-radius: 10px;
    cursor: pointer;
    font-weight: 600;
    transition: 0.3s;
    display: flex;
    align-items: center;
    gap: 8px;
}

.btn-back:hover {
    background: var(--primary-teal);
    color: white;
}

/* Cards */
.card {
    background: var(--card-bg);
    border-radius: 20px;
    padding: 25px;
    box-shadow: var(--shadow);
    margin-bottom: 20px;
}

.profile-card {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.profile-info { 
    display: flex; 
    align-items: center; 
    gap: 20px; 
}

.avatar { 
    width: 70px; 
    height: 70px; 
    background: #eee; 
    border-radius: 50%; 
    display: flex; 
    align-items: center; 
    justify-content: center; 
    font-size: 35px;
}

.btn-edit {
    background: var(--primary-gradient);
    border: none;
    color: white;
    padding: 10px 20px;
    border-radius: 12px;
    font-weight: 600;
    cursor: pointer;
}

.stats-grid { 
    display: grid; 
    grid-template-columns: repeat(3, 1fr); 
    gap: 15px; 
    margin-top: 15px; 
}

.stat-item { 
    text-align: center; 
}
.stat-value { 
    font-size: 1.5rem; 
    font-weight: 700; 
    color: var(--primary-teal); 
    display: block; 
}

.progress-bar { 
    background: #eee; 
    height: 12px; 
    border-radius: 10px; 
    overflow: hidden; 
    margin-top: 10px; 
}

.progress-fill {
    width: 0%; 
    height: 100%; 
    background: var(--primary-gradient); 
    transition: width 1.5s ease-out; 
}

.setting-item { 
    display: flex; 
    justify-content: space-between; 
    align-items: center; 
    padding: 15px 0; 
    border-bottom: 1px solid rgba(0,0,0,0.05); }

.switch { 
    width: 40px; 
    height: 20px; 
    position: relative; 
    display: inline-block; 
}

.switch input { 
    display: none; 
}

.slider {
    position: absolute; 
    cursor: pointer; 
    top: 0; 
    left: 0; 
    right: 0; 
    bottom: 0; 
    background: #ccc; 
    border-radius: 20px; 
    transition: 0.4s; 
}

.slider:before {
     position: absolute; 
     content: ""; 
     height: 14px; 
     width: 14px; 
     left: 3px; 
     bottom: 3px; 
     background: white; 
     border-radius: 50%; transition: 0.4s; 
}

input:checked + .slider { 
    background: var(--primary-teal); 
}

input:checked + .slider:before { 
    transform: translateX(20px); 
}

.btn-logout { 
    width: 100%; 
    margin-top: 20px; 
    padding: 12px; 
    background: #ffeded; 
    color: #e74c3c; 
    border: none; 
    border-radius: 12px; 
    font-weight: 600; 
    cursor: pointer; 
}

@media (max-width: 850px) { 
    .container { 
        flex-direction: column; 
    } 
    .sidebar { 
        margin-top: 0; 
    }
}