/* Enhanced Features Widget Styles */

/* Base Widget Styles */
.widget {
    background: #fff;
    border-radius: 8px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
    margin-bottom: 20px;
    overflow: hidden;
}

.widget-header {
    padding: 15px 20px;
    border-bottom: 1px solid #eee;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.widget-header h3 {
    margin: 0;
    font-size: 1.1rem;
    font-weight: 600;
    color: #333;
}

.widget-header .view-all {
    font-size: 0.9rem;
    color: #4A90E2;
    text-decoration: none;
}

.widget-header .view-all:hover {
    text-decoration: underline;
}

.widget-content {
    padding: 20px;
}

/* Streak Widget */
.streak-widget {
    text-align: center;
}

.streak-widget .streak-number {
    font-size: 3rem;
    font-weight: bold;
    color: #4A90E2;
    line-height: 1;
}

.streak-widget.streak-fire .streak-number {
    color: #FF6B35;
    text-shadow: 0 0 10px rgba(255, 107, 53, 0.3);
}

.streak-widget.streak-good .streak-number {
    color: #F7931E;
}

.streak-widget.streak-started .streak-number {
    color: #9B59B6;
}

.streak-widget .streak-label {
    font-size: 1rem;
    color: #666;
    margin-top: 5px;
}

.streak-widget .streak-record {
    margin-top: 10px;
    padding: 8px;
    background: #f8f9fa;
    border-radius: 4px;
    font-size: 0.9rem;
    color: #555;
}

.streak-widget .streak-stats {
    margin-top: 10px;
    font-size: 0.85rem;
    color: #777;
}

/* Points Widget */
.points-widget .points-display {
    text-align: center;
    margin-bottom: 20px;
}

.points-widget .points-number {
    font-size: 2.5rem;
    font-weight: bold;
    color: #F7931E;
    display: block;
}

.points-widget .points-label {
    font-size: 0.9rem;
    color: #666;
}

.points-widget .level-progress {
    margin-top: 15px;
}

.points-widget .progress-bar {
    height: 10px;
    background: #e9ecef;
    border-radius: 5px;
    overflow: hidden;
}

.points-widget .progress-fill {
    height: 100%;
    background: linear-gradient(90deg, #4A90E2, #F7931E);
    transition: width 0.3s ease;
}

.points-widget .progress-text {
    text-align: center;
    margin-top: 8px;
    font-size: 0.85rem;
    color: #666;
}

/* Badges Widget */
.badges-widget .badge-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 15px;
}

.badges-widget .badge-item {
    text-align: center;
    padding: 10px;
    border: 1px solid #eee;
    border-radius: 8px;
    transition: all 0.2s ease;
    cursor: pointer;
}

.badges-widget .badge-item:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(0,0,0,0.1);
    border-color: #4A90E2;
}

.badges-widget .badge-icon {
    font-size: 2rem;
    margin-bottom: 5px;
}

.badges-widget .badge-name {
    font-size: 0.85rem;
    font-weight: 600;
    color: #333;
}

.badges-widget .badge-date {
    font-size: 0.75rem;
    color: #999;
    margin-top: 3px;
}

.badges-widget .no-badges {
    text-align: center;
    color: #999;
    padding: 20px;
}

/* Trending Widget */
.trending-widget .trending-list {
    list-style: none;
    padding: 0;
    margin: 0;
}

.trending-widget .trending-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px 0;
    border-bottom: 1px solid #f0f0f0;
}

.trending-widget .trending-item:last-child {
    border-bottom: none;
}

.trending-widget .trending-content a {
    color: #333;
    text-decoration: none;
    font-weight: 500;
}

.trending-widget .trending-content a:hover {
    color: #4A90E2;
}

.trending-widget .trending-type {
    display: inline-block;
    margin-left: 8px;
    padding: 2px 8px;
    background: #f0f0f0;
    border-radius: 10px;
    font-size: 0.75rem;
    color: #666;
}

.trending-widget .trending-stats {
    display: flex;
    gap: 10px;
    font-size: 0.85rem;
    color: #666;
}

.trending-widget .trending-score {
    color: #FF6B35;
    font-weight: 600;
}

/* Leaderboard Widget */
.leaderboard-widget .leaderboard-list {
    list-style: none;
    padding: 0;
    margin: 0;
}

.leaderboard-widget .leaderboard-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 10px;
    border-bottom: 1px solid #f0f0f0;
    transition: background 0.2s ease;
}

.leaderboard-widget .leaderboard-item:hover {
    background: #f8f9fa;
}

.leaderboard-widget .rank {
    font-weight: bold;
    color: #666;
    min-width: 30px;
}

.leaderboard-widget .leaderboard-item.rank-1 .rank {
    color: #FFD700;
    font-size: 1.1rem;
}

.leaderboard-widget .leaderboard-item.rank-2 .rank {
    color: #C0C0C0;
    font-size: 1.05rem;
}

.leaderboard-widget .leaderboard-item.rank-3 .rank {
    color: #CD7F32;
    font-size: 1.05rem;
}

.leaderboard-widget .username {
    flex: 1;
    font-weight: 500;
}

.leaderboard-widget .score {
    font-weight: 600;
    color: #4A90E2;
}

/* Recommendations Widget */
.recommendations-widget .recommendation-list {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.recommendations-widget .recommendation-item {
    border-left: 3px solid #4A90E2;
    padding-left: 12px;
}

.recommendations-widget .recommendation-item a {
    text-decoration: none;
    color: inherit;
}

.recommendations-widget .recommendation-item h4 {
    margin: 0 0 5px 0;
    font-size: 1rem;
    color: #333;
}

.recommendations-widget .recommendation-item p {
    margin: 0;
    font-size: 0.85rem;
    color: #666;
    line-height: 1.4;
}

.recommendations-widget .recommendation-item:hover h4 {
    color: #4A90E2;
}

/* Notifications Widget */
.notifications-widget {
    position: relative;
}

.notifications-widget .notification-badge {
    display: inline-block;
    background: #FF3B30;
    color: white;
    border-radius: 10px;
    padding: 2px 6px;
    font-size: 0.75rem;
    font-weight: bold;
    margin-left: 5px;
}

.notifications-widget .notification-list {
    list-style: none;
    padding: 0;
    margin: 0;
}

.notifications-widget .notification-item {
    padding: 12px;
    border-bottom: 1px solid #f0f0f0;
    cursor: pointer;
    transition: background 0.2s ease;
}

.notifications-widget .notification-item:hover {
    background: #f8f9fa;
}

.notifications-widget .notification-item.unread {
    background: #E8F4FF;
}

.notifications-widget .notification-item.priority-high {
    border-left: 3px solid #FF3B30;
}

.notifications-widget .notification-content {
    display: flex;
    flex-direction: column;
    gap: 5px;
}

.notifications-widget .notification-message {
    font-size: 0.9rem;
    color: #333;
}

.notifications-widget .notification-time {
    font-size: 0.75rem;
    color: #999;
}

.notifications-widget .view-all-notifications {
    display: block;
    text-align: center;
    padding: 10px;
    color: #4A90E2;
    text-decoration: none;
    border-top: 1px solid #eee;
}

/* Activity Summary Widget */
.activity-summary-widget .activity-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 15px;
    margin-bottom: 15px;
}

.activity-summary-widget .activity-stat {
    text-align: center;
    padding: 15px;
    background: #f8f9fa;
    border-radius: 8px;
}

.activity-summary-widget .stat-icon {
    font-size: 2rem;
    margin-bottom: 5px;
}

.activity-summary-widget .stat-value {
    font-size: 1.8rem;
    font-weight: bold;
    color: #4A90E2;
}

.activity-summary-widget .stat-label {
    font-size: 0.85rem;
    color: #666;
    margin-top: 3px;
}

.activity-summary-widget .member-info {
    text-align: center;
    font-size: 0.85rem;
    color: #999;
    padding-top: 10px;
    border-top: 1px solid #eee;
}

/* Responsive Design */
@media (max-width: 768px) {
    .badges-widget .badge-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .activity-summary-widget .activity-grid {
        grid-template-columns: 1fr;
    }
    
    .widget-content {
        padding: 15px;
    }
}

/* Empty States */
.no-badges,
.no-content,
.no-leaderboard,
.no-recommendations,
.no-notifications {
    text-align: center;
    color: #999;
    padding: 30px 20px;
    font-style: italic;
}

/* Animation */
@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(-10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.widget {
    animation: fadeIn 0.3s ease;
}
