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

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
    background: #000000;
    min-height: 100vh;
    color: #e0e0e0;
    position: relative;
    overflow-x: hidden;
}

/* Starry background */
body::before {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: 
        radial-gradient(2px 2px at 20px 30px, #fff, transparent),
        radial-gradient(2px 2px at 40px 70px, rgba(255,255,255,0.8), transparent),
        radial-gradient(1px 1px at 90px 40px, #fff, transparent),
        radial-gradient(1px 1px at 130px 80px, rgba(255,255,255,0.6), transparent),
        radial-gradient(2px 2px at 160px 30px, #ddd, transparent),
        radial-gradient(1px 1px at 190px 90px, #fff, transparent),
        radial-gradient(1px 1px at 230px 40px, rgba(255,255,255,0.8), transparent),
        radial-gradient(2px 2px at 270px 70px, #eee, transparent),
        radial-gradient(1px 1px at 310px 20px, #fff, transparent),
        radial-gradient(1px 1px at 350px 60px, rgba(255,255,255,0.7), transparent),
        radial-gradient(1px 1px at 380px 90px, #ddd, transparent),
        radial-gradient(1px 1px at 420px 30px, #fff, transparent),
        radial-gradient(1px 1px at 80px 90px, rgba(255,255,255,0.5), transparent),
        radial-gradient(2px 2px at 120px 20px, #fff, transparent),
        radial-gradient(1px 1px at 200px 50px, rgba(255,255,255,0.8), transparent),
        radial-gradient(1px 1px at 250px 10px, #ddd, transparent),
        radial-gradient(1px 1px at 290px 90px, rgba(255,255,255,0.6), transparent),
        radial-gradient(2px 2px at 340px 15px, #fff, transparent),
        radial-gradient(1px 1px at 390px 45px, rgba(255,255,255,0.7), transparent),
        radial-gradient(1px 1px at 60px 15px, #eee, transparent);
    background-repeat: repeat;
    background-size: 400px 200px;
    pointer-events: none;
    z-index: 1;
}

/* Additional twinkling layer */
body::after {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: 
        radial-gradient(1px 1px at 50px 50px, rgba(66, 165, 245, 0.8), transparent),
        radial-gradient(1px 1px at 150px 120px, rgba(100, 181, 246, 0.6), transparent),
        radial-gradient(1px 1px at 300px 80px, rgba(66, 165, 245, 0.9), transparent),
        radial-gradient(1px 1px at 180px 40px, rgba(100, 181, 246, 0.7), transparent),
        radial-gradient(1px 1px at 220px 140px, rgba(66, 165, 245, 0.5), transparent),
        radial-gradient(1px 1px at 360px 20px, rgba(100, 181, 246, 0.8), transparent);
    background-repeat: repeat;
    background-size: 300px 150px;
    pointer-events: none;
    z-index: 1;
}

#app {
    width: 100%;
    margin: 0;
    min-height: 100vh;
    background: transparent;
    box-shadow: none;
    position: relative;
    z-index: 2;
}

/* Header */
header {
    background: linear-gradient(135deg, #0f3460 0%, #16537e 100%);
    color: white;
    padding: 1rem 2rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-bottom: 1px solid #333;
    width: 100%;
    box-sizing: border-box;
}

.logo {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.shoe-logo {
    width: 2rem;
    height: 2rem;
    filter: drop-shadow(0 0 10px rgba(33, 150, 243, 0.5));
}

.logo h1 {
    font-size: 1.8rem;
    font-weight: 700;
    letter-spacing: 2px;
}

/* Navigation */
nav {
    display: flex;
    gap: 1rem;
}

.nav-btn {
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.2);
    color: white;
    padding: 0.5rem 1rem;
    border-radius: 20px;
    cursor: pointer;
    transition: all 0.3s ease;
}

.nav-btn:hover {
    background: rgba(255, 255, 255, 0.2);
    border-color: rgba(255, 255, 255, 0.3);
}

.nav-btn.active {
    background: rgba(33, 150, 243, 0.8);
    color: white;
    border-color: #2196F3;
}

/* Main Content */
main {
    padding: 2rem;
    min-height: calc(100vh - 120px);
    max-width: 1200px;
    margin: 0 auto;
    width: 100%;
    box-sizing: border-box;
}

.screen {
    animation: fadeIn 0.3s ease;
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(20px); }
    to { opacity: 1; transform: translateY(0); }
}

/* Login Screen */
.login-container {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    min-height: 60vh;
    text-align: center;
}

.logo-large {
    margin-bottom: 3rem;
}

.shoe-logo-large {
    width: 30rem;
    height: 30rem;
    margin-bottom: 1rem;
}

.logo-large h1 {
    font-size: 3rem;
    font-weight: 700;
    letter-spacing: 3px;
    background: linear-gradient(135deg, #64b5f6, #42a5f5);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    margin-bottom: 0.5rem;
}

.logo-large p {
    font-size: 1.2rem;
    color: #b0b0b0;
    margin-bottom: 2rem;
}

/* Home Screen */
.welcome-section {
    margin-bottom: 3rem;
}

.welcome-section h2 {
    font-size: 2rem;
    margin-bottom: 2rem;
    color: #e0e0e0;
}

.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 1.5rem;
    margin-bottom: 2rem;
}

.stat-card {
    background: linear-gradient(135deg, #2a2a2a 0%, #1f1f1f 100%);
    border: 1px solid #333;
    padding: 2rem;
    border-radius: 15px;
    text-align: center;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.3);
}

.stat-card.clickable {
    cursor: pointer;
    transition: all 0.3s ease;
}

.stat-card.clickable:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(66, 165, 245, 0.3);
    border-color: #42a5f5;
}

.stat-card.clickable:active {
    transform: translateY(0);
}

.stat-card h3 {
    font-size: 1.1rem;
    color: #b0b0b0;
    margin-bottom: 1rem;
}

.stat-number {
    font-size: 3rem;
    font-weight: 700;
    color: #42a5f5;
}

/* Loading state for stat numbers */
.stat-number.loading {
    animation: loadingPulse 1.5s infinite;
    opacity: 0.6;
}

@keyframes loadingPulse {
    0% { opacity: 0.4; }
    50% { opacity: 1; }
    100% { opacity: 0.4; }
}

.actions-section {
    display: flex;
    gap: 1rem;
    flex-wrap: wrap;
}

/* Buttons */
.primary-btn, .secondary-btn, .danger-btn {
    padding: 1rem 2rem;
    border: none;
    border-radius: 25px;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.primary-btn {
    background: linear-gradient(135deg, #42a5f5, #1976d2);
    color: white;
    border: 1px solid #1976d2;
}

.primary-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(66, 165, 245, 0.4);
    background: linear-gradient(135deg, #64b5f6, #1976d2);
}

.secondary-btn {
    background: linear-gradient(135deg, #3a3a3a, #2a2a2a);
    color: #e0e0e0;
    border: 1px solid #555;
}

.secondary-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.3);
    background: linear-gradient(135deg, #4a4a4a, #3a3a3a);
}

.danger-btn {
    background: linear-gradient(135deg, #ef5350, #d32f2f);
    color: white;
    border: 1px solid #d32f2f;
}

.danger-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(239, 83, 80, 0.4);
    background: linear-gradient(135deg, #f44336, #d32f2f);
}

/* Leaderboards */
.leaderboard-item {
    background: #2a2a2a;
    border: 1px solid #444;
    border-radius: 15px;
    padding: 1.5rem;
    margin-bottom: 1rem;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.3);
    cursor: pointer;
    transition: all 0.3s ease;
}

.leaderboard-item:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.4);
    border-color: #42a5f5;
}

.leaderboard-item h3 {
    color: #42a5f5;
    margin-bottom: 0.5rem;
}

.leaderboard-item p {
    color: #b0b0b0;
    font-size: 0.9rem;
}

/* Leaderboard Detail */
.leaderboard-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 2rem;
    flex-wrap: wrap;
    gap: 1rem;
}

.leaderboard-header h2 {
    color: #42a5f5;
    font-size: 2rem;
}

.leaderboard-actions {
    display: flex;
    gap: 1rem;
}

.week-selector {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 2rem;
    margin-bottom: 2rem;
}

.week-selector button {
    background: #42a5f5;
    color: white;
    border: none;
    border-radius: 50%;
    width: 40px;
    height: 40px;
    cursor: pointer;
    font-size: 1.2rem;
    transition: all 0.3s ease;
}

.week-selector button:hover {
    background: #1976d2;
}

.week-selector span {
    font-size: 1.2rem;
    font-weight: 600;
    color: #e0e0e0;
}

/* View Selector */
.view-selector {
    display: flex;
    gap: 0.5rem;
    margin-bottom: 1.5rem;
    background: #2a2a2a;
    border: 1px solid #444;
    padding: 0.5rem;
    border-radius: 30px;
    align-self: flex-start;
}

.view-btn {
    background: transparent;
    border: none;
    padding: 0.8rem 1.5rem;
    border-radius: 25px;
    cursor: pointer;
    font-weight: 600;
    transition: all 0.3s ease;
    color: #b0b0b0;
}

.view-btn.active {
    background: #42a5f5;
    color: white;
    box-shadow: 0 2px 8px rgba(66, 165, 245, 0.3);
}

.view-btn:hover:not(.active) {
    background: rgba(66, 165, 245, 0.1);
    color: #42a5f5;
}

.leaderboard-tabs {
    display: flex;
    gap: 1rem;
    margin-bottom: 2rem;
}

.tab-btn {
    background: #2a2a2a;
    border: 1px solid #444;
    color: #b0b0b0;
    padding: 0.8rem 1.5rem;
    border-radius: 25px;
    cursor: pointer;
    font-weight: 600;
    transition: all 0.3s ease;
}

.tab-btn.active {
    background: #42a5f5;
    color: white;
    border-color: #42a5f5;
}

/* Leaderboard Table */
.leaderboard-table {
    width: 100%;
    border-collapse: collapse;
    background: #2a2a2a;
    border: 1px solid #444;
    border-radius: 15px;
    overflow: hidden;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.3);
}

.leaderboard-table th {
    background: linear-gradient(135deg, #42a5f5, #1976d2);
    color: white;
    padding: 1rem;
    text-align: left;
    font-weight: 600;
}

.leaderboard-table td {
    padding: 1rem;
    border-bottom: 1px solid #444;
    color: #e0e0e0;
}

.leaderboard-table tr:hover {
    background: #333;
}

.rank-badge {
    display: inline-block;
    background: linear-gradient(135deg, #ffd700, #ffed4a);
    color: #333;
    padding: 0.3rem 0.8rem;
    border-radius: 15px;
    font-weight: 600;
    font-size: 0.9rem;
}

.rank-badge.first {
    background: linear-gradient(135deg, #ffd700, #ffed4a);
}

.rank-badge.second {
    background: linear-gradient(135deg, #c0c0c0, #e8e8e8);
}

.rank-badge.third {
    background: linear-gradient(135deg, #cd7f32, #daa520);
}

.user-info {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.user-avatar {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    object-fit: cover;
}

.steps-count {
    font-size: 1.2rem;
    font-weight: 600;
    color: #42a5f5;
}

/* Chart */
.chart-container {
    background: #2a2a2a;
    border: 1px solid #444;
    border-radius: 15px;
    padding: 2rem;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.3);
}

.chart-placeholder {
    min-height: 400px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    color: #b0b0b0;
    font-size: 1.2rem;
    text-align: center;
    padding: 2rem;
}

.chart-placeholder p {
    margin: 0.5rem 0;
}

.chart-legend {
    margin-top: 2rem;
    width: 100%;
    max-width: 500px;
}

.legend-item {
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: 0.75rem;
    margin-bottom: 0.5rem;
    background: #333;
    border: 1px solid #444;
    border-radius: 10px;
    font-size: 0.9rem;
    color: #e0e0e0;
}

.legend-color {
    width: 16px;
    height: 16px;
    border-radius: 50%;
    flex-shrink: 0;
}

.legend-total {
    margin-left: auto;
    font-weight: 600;
    color: #42a5f5;
}

/* Profile */
.profile-info {
    text-align: center;
    margin-bottom: 3rem;
}

.profile-picture {
    width: 120px;
    height: 120px;
    border-radius: 50%;
    margin-bottom: 1rem;
    object-fit: cover;
    border: 4px solid #42a5f5;
}

.profile-info h2 {
    color: #42a5f5;
    margin-bottom: 0.5rem;
}

.profile-info p {
    color: #b0b0b0;
    font-size: 1.1rem;
}

.profile-actions {
    display: flex;
    gap: 1rem;
    justify-content: center;
}

/* Modal */
.modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.7);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 1000;
}

.modal-content {
    background: #2a2a2a;
    border: 1px solid #444;
    border-radius: 15px;
    padding: 2rem;
    width: 90%;
    max-width: 400px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.5);
}

.modal-content h3 {
    color: #42a5f5;
    margin-bottom: 1.5rem;
    text-align: center;
}

.modal-content input {
    width: 100%;
    padding: 1rem;
    border: 2px solid #444;
    background: #1a1a1a;
    color: #e0e0e0;
    border-radius: 10px;
    font-size: 1rem;
    margin-bottom: 1.5rem;
    transition: border-color 0.3s ease;
}

.modal-content input:focus {
    outline: none;
    border-color: #42a5f5;
}

.modal-actions {
    display: flex;
    gap: 1rem;
    justify-content: center;
}

/* Loading */
.loading {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(30, 30, 30, 0.9);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 1001;
}

.spinner {
    width: 50px;
    height: 50px;
    border: 4px solid #333;
    border-top: 4px solid #42a5f5;
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* Toast */
.toast {
    position: fixed;
    bottom: 2rem;
    left: 50%;
    transform: translateX(-50%);
    background: #444;
    color: white;
    border: 1px solid #555;
    padding: 1rem 2rem;
    border-radius: 25px;
    z-index: 1002;
    animation: slideUp 0.3s ease;
}

@keyframes slideUp {
    from { transform: translateX(-50%) translateY(100px); opacity: 0; }
    to { transform: translateX(-50%) translateY(0); opacity: 1; }
}

.toast.success {
    background: #4caf50;
}

.toast.error {
    background: #f44336;
}

/* Error Message */
.error-message {
    color: #f44336;
    font-size: 0.9rem;
    margin-top: 1rem;
    text-align: center;
}

/* Empty states */
.empty-state {
    text-align: center;
    padding: 3rem;
    color: #b0b0b0;
}

.empty-state .emoji {
    font-size: 3rem;
    margin-bottom: 1rem;
    display: block;
}

.empty-notifications {
    text-align: center;
    padding: 3rem;
    color: #b0b0b0;
}

/* Responsive */
@media (max-width: 768px) {
    #app {
        box-shadow: none;
    }
    
    /* Mobile header adjustments */
    header {
        padding: 0.75rem 1rem;
    }
    
    .logo h1 {
        display: none; /* Hide "MR STEP" text on mobile */
    }
    
    .shoe-logo {
        font-size: 1.5rem; /* Keep emoji visible but slightly smaller */
    }
    
    /* Mobile navigation */
    nav {
        gap: 0.5rem;
    }
    
    .nav-btn {
        padding: 0.4rem 0.8rem;
        font-size: 0.85rem;
        border-radius: 15px;
        min-width: auto;
        white-space: nowrap;
    }
    
    .notification-badge {
        padding: 0.1rem 0.4rem;
        font-size: 0.6rem;
        margin-left: 0.3rem;
    }
    
    main {
        padding: 1rem;
    }
    
    .logo-large h1 {
        font-size: 2rem;
    }
    
    .stats-grid {
        grid-template-columns: 1fr;
    }
    
    .actions-section {
        flex-direction: column;
    }
    
    .primary-btn, .secondary-btn, .danger-btn {
        width: 100%;
    }
    
    .leaderboard-header {
        flex-direction: column;
        align-items: flex-start;
    }
    
    .leaderboard-actions {
        width: 100%;
        justify-content: space-between;
    }
    
    .profile-actions {
        flex-direction: column;
    }
    
    .modal-content {
        width: 95%;
        padding: 1.5rem;
    }
    
    .modal-actions {
        flex-direction: column;
    }
}

/* Extra small screens (very narrow phones) */
@media (max-width: 480px) {
    header {
        padding: 0.5rem 0.75rem;
    }
    
    nav {
        gap: 0.25rem;
    }
    
    .nav-btn {
        padding: 0.3rem 0.6rem;
        font-size: 0.8rem;
        border-radius: 12px;
    }
    
    .shoe-logo {
        font-size: 1.3rem;
    }
}

/* Notification Badge */
.notification-badge {
    background: #f44336;
    color: white;
    border-radius: 50%;
    padding: 0.2rem 0.5rem;
    font-size: 0.7rem;
    font-weight: 600;
    margin-left: 0.5rem;
    animation: pulse 2s infinite;
}

@keyframes pulse {
    0% { transform: scale(1); }
    50% { transform: scale(1.1); }
    100% { transform: scale(1); }
}

/* Notifications Screen */
.notifications-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 2rem;
}

.notifications-header h2 {
    color: #42a5f5;
}

.notifications-settings {
    margin-bottom: 2rem;
    padding: 1rem;
    background: #2a2a2a;
    border-radius: 8px;
}

.notification-setting {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.notification-setting label {
    font-weight: 500;
    color: #e0e0e0;
}

.secondary-btn.success {
    background: #4caf50;
    color: white;
}

.secondary-btn.error {
    background: #f44336;
    color: white;
}

.notifications-filter {
    display: flex;
    gap: 1rem;
    margin-bottom: 2rem;
}

.filter-btn {
    background: #2a2a2a;
    border: 1px solid #444;
    color: #b0b0b0;
    padding: 0.8rem 1.5rem;
    border-radius: 25px;
    cursor: pointer;
    font-weight: 600;
    transition: all 0.3s ease;
}

.filter-btn.active {
    background: #42a5f5;
    color: white;
    border-color: #42a5f5;
}

.notifications-list {
    max-height: 60vh;
    overflow-y: auto;
}

.notification-item {
    background: #2a2a2a;
    border: 1px solid #444;
    border-radius: 15px;
    padding: 1.5rem;
    margin-bottom: 1rem;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.3);
    cursor: pointer;
    transition: all 0.3s ease;
    position: relative;
}

.notification-item:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.4);
    border-color: #42a5f5;
}

.notification-item.unread {
    border-left: 4px solid #42a5f5;
    background: linear-gradient(135deg, #2a3f5f 0%, #2a2a2a 100%);
}

.notification-item.unread::before {
    content: '';
    position: absolute;
    top: 1rem;
    right: 1rem;
    width: 8px;
    height: 8px;
    background: #42a5f5;
    border-radius: 50%;
}

.notification-content {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.notification-message {
    font-size: 1rem;
    color: #e0e0e0;
    line-height: 1.4;
}

.notification-meta {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 0.8rem;
    color: #b0b0b0;
}

.notification-type {
    background: rgba(66, 165, 245, 0.2);
    color: #64b5f6;
    padding: 0.2rem 0.8rem;
    border-radius: 15px;
    font-weight: 600;
    text-transform: uppercase;
    font-size: 0.7rem;
}

.notification-type.took_lead {
    background: rgba(76, 175, 80, 0.1);
    color: #4caf50;
}

.notification-type.lost_lead {
    background: rgba(244, 67, 54, 0.1);
    color: #f44336;
}

.notification-type.milestone {
    background: rgba(255, 193, 7, 0.1);
    color: #ffc107;
}

.notification-time {
    color: #888;
}

.empty-notifications {
    text-align: center;
    padding: 3rem;
    color: #b0b0b0;
}

.empty-notifications .emoji {
    font-size: 3rem;
    margin-bottom: 1rem;
    display: block;
}

/* Web Push Notification */
.push-notification {
    position: fixed;
    top: 2rem;
    right: 2rem;
    background: #2a2a2a;
    border: 1px solid #444;
    border-radius: 15px;
    padding: 1rem;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.3);
    z-index: 1003;
    max-width: 300px;
    animation: slideInRight 0.3s ease;
}

@keyframes slideInRight {
    from { transform: translateX(100%); opacity: 0; }
    to { transform: translateX(0); opacity: 1; }
}

.push-notification .notification-icon {
    font-size: 1.5rem;
    margin-right: 0.5rem;
}

.push-notification .notification-text {
    font-size: 0.9rem;
    color: #e0e0e0;
}

.push-notification .notification-close {
    position: absolute;
    top: 0.5rem;
    right: 0.5rem;
    background: none;
    border: none;
    font-size: 1rem;
    color: #b0b0b0;
    cursor: pointer;
}

/* Blackout Notice */
.blackout-notice {
    background: linear-gradient(135deg, #ff9800 0%, #f57c00 100%);
    color: white;
    border-radius: 15px;
    padding: 1.5rem;
    margin-bottom: 2rem;
    display: flex;
    align-items: center;
    gap: 1rem;
    box-shadow: 0 4px 15px rgba(255, 152, 0, 0.3);
}

.blackout-icon {
    font-size: 2rem;
    flex-shrink: 0;
}

.blackout-text h3 {
    margin: 0 0 0.5rem 0;
    font-size: 1.2rem;
}

.blackout-text p {
    margin: 0.25rem 0;
    opacity: 0.9;
}

#blackout-countdown {
    font-weight: 600;
    color: #fff3e0;
}

/* Leaderboard Settings */
.settings-section {
    margin-bottom: 2rem;
}

.settings-section h4 {
    color: #42a5f5;
    margin-bottom: 1rem;
    font-size: 1.1rem;
}

.settings-section p {
    color: #b0b0b0;
    margin-bottom: 1rem;
    line-height: 1.4;
}

.checkbox-label {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    margin-bottom: 1rem;
    cursor: pointer;
    font-weight: 500;
    color: #e0e0e0;
}

.checkbox-label input[type="checkbox"] {
    width: 18px;
    height: 18px;
    accent-color: #42a5f5;
}

#blackout-hours-section {
    margin-left: 2rem;
    padding: 1rem;
    background: #333;
    border: 1px solid #444;
    border-radius: 10px;
    border-left: 3px solid #42a5f5;
}

#blackout-hours-section label {
    display: block;
    margin-bottom: 0.5rem;
    font-weight: 500;
    color: #e0e0e0;
}

#blackout-hours-input {
    width: 100%;
    padding: 0.75rem;
    border: 2px solid #444;
    background: #1a1a1a;
    color: #e0e0e0;
    border-radius: 8px;
    font-size: 1rem;
    margin-bottom: 0.5rem;
}

#blackout-hours-input:focus {
    outline: none;
    border-color: #42a5f5;
}

#blackout-hours-section small {
    color: #b0b0b0;
    font-style: italic;
}

/* Masked Step Data */
.steps-masked {
    color: #ff9800;
    font-weight: 700;
    font-family: monospace;
    background: rgba(255, 152, 0, 0.1);
    padding: 0.2rem 0.5rem;
    border-radius: 5px;
}

.user-info.masked {
    opacity: 0.7;
}

.user-info.masked .user-avatar {
    filter: blur(1px);
}

/* Creator Badge */
.creator-badge {
    background: linear-gradient(135deg, #ffd700, #ffed4a);
    color: #333;
    padding: 0.2rem 0.6rem;
    border-radius: 12px;
    font-size: 0.7rem;
    font-weight: 600;
    margin-left: 0.5rem;
    text-transform: uppercase;
}

/* Additional Dark Mode Styles */
.profile-picture {
    border: 4px solid #42a5f5;
}

.checkbox-label {
    color: #e0e0e0;
}

.notification-time {
    color: #888;
}

/* Ensure all text inputs and selects have dark styling */
input[type="text"], 
input[type="number"], 
input[type="email"], 
select, 
textarea {
    background: #1a1a1a !important;
    color: #e0e0e0 !important;
    border: 2px solid #444 !important;
}

input[type="text"]:focus, 
input[type="number"]:focus, 
input[type="email"]:focus, 
select:focus, 
textarea:focus {
    border-color: #42a5f5 !important;
}

/* Dark scrollbars */
::-webkit-scrollbar {
    width: 12px;
}

::-webkit-scrollbar-track {
    background: #2a2a2a;
}

::-webkit-scrollbar-thumb {
    background: #555;
    border-radius: 6px;
}

::-webkit-scrollbar-thumb:hover {
    background: #666;
}

/* Make sure all headings use appropriate colors */
h1, h2, h3, h4, h5, h6 {
    color: #e0e0e0;
}

/* Override any remaining light text */
p, span, div {
    color: inherit;
}

/* Footer or any other white backgrounds */
.white-bg {
    background: #2a2a2a !important;
    color: #e0e0e0 !important;
}

#mark-all-read-btn {
    padding: 0.8rem 1.2rem !important;
    font-size: 0.9rem !important;
    text-transform: none !important;
    letter-spacing: normal !important;
    font-weight: 500 !important;
}

/* Notification styles */
.notification-item {
    background: #1a1a1a;
    border: 1px solid #333;
    border-radius: 12px;
    padding: 1rem;
    margin-bottom: 0.8rem;
    position: relative;
    cursor: pointer;
    transition: all 0.2s ease;
}

.notification-item:hover {
    background: #222;
    border-color: #42a5f5;
}

.notification-item.unread {
    background: linear-gradient(135deg, #1a1a1a 0%, #1e2a3a 100%);
    border-color: #42a5f5;
}

.notification-item.read {
    opacity: 0.7;
}

.notification-content {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.notification-message {
    font-size: 1rem;
    font-weight: 500;
    color: #e0e0e0;
    line-height: 1.4;
}

.notification-meta {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 0.85rem;
    color: #888;
}

.notification-time {
    color: #aaa;
}

.notification-type {
    color: #42a5f5;
    font-weight: 500;
}

.notification-unread-dot {
    position: absolute;
    top: 0.8rem;
    right: 0.8rem;
    width: 8px;
    height: 8px;
    background: #42a5f5;
    border-radius: 50%;
}

.notification-badge {
    background: #f44336;
    color: white;
    border-radius: 10px;
    padding: 2px 6px;
    font-size: 0.7rem;
    font-weight: bold;
    min-width: 16px;
    text-align: center;
    margin-left: 4px;
    display: none;
}

.notifications-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1.5rem;
}

.notifications-filter {
    display: flex;
    gap: 0.5rem;
    margin-bottom: 1rem;
}

.filter-btn {
    padding: 0.5rem 1rem;
    background: #2a2a2a;
    border: 1px solid #444;
    border-radius: 6px;
    color: #ccc;
    cursor: pointer;
    transition: all 0.2s ease;
}

.filter-btn:hover {
    background: #333;
    border-color: #42a5f5;
}

.filter-btn.active {
    background: #42a5f5;
    border-color: #42a5f5;
    color: white;
}

.notifications-list {
    max-height: 60vh;
    overflow-y: auto;
}
/* Leaderboards screen spacing */
#leaderboards-list {
    margin-top: 1.5rem;
}

/* Chart styling */
.chart-wrapper {
    position: relative;
    height: 400px;
    margin: 1rem 0;
    background: #1a1a1a;
    border-radius: 12px;
    padding: 1rem;
}

.blackout-warning {
    background: rgba(255, 152, 0, 0.1);
    color: #ff9800;
    padding: 0.75rem 1rem;
    border-radius: 8px;
    border: 1px solid rgba(255, 152, 0, 0.3);
    margin-bottom: 1rem;
    font-size: 0.9rem;
    text-align: center;
}

/* Ensure chart container has proper styling */
.chart-container {
    background: #2a2a2a;
    border: 1px solid #444;
    border-radius: 15px;
    padding: 1.5rem;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.3);
}

.chart-container h3 {
    color: #42a5f5;
    margin-bottom: 1rem;
    text-align: center;
    font-size: 1.3rem;
}

/* App Loading Screen */
.app-loading {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: #000000;
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 10000;
    transition: opacity 0.5s ease-out;
}

.app-loading.fade-out {
    opacity: 0;
    pointer-events: none;
}

.app-loading-container {
    text-align: center;
    position: relative;
    z-index: 3;
}

.app-loading-logo {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1rem;
}

.app-loading-icon {
    width: 120px;
    height: 120px;
    border-radius: 24px;
    box-shadow: 0 8px 32px rgba(66, 165, 245, 0.3);
    animation: float 3s ease-in-out infinite;
}

.app-loading-tagline {
    color: #e0e0e0;
    font-size: 1.2rem;
    font-weight: 300;
    letter-spacing: 0.5px;
    margin: 0;
    opacity: 0.9;
}

@keyframes float {
    0%, 100% { 
        transform: translateY(0px);
    }
    50% { 
        transform: translateY(-10px);
    }
}
