/* User Favorites & Highlights Plugin Styles */

/* Favorite Button */
.ufh-favorite-button {
    margin: 20px 0;
    text-align: center;
}

.ufh-favorite-btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 12px 24px;
    background: #fff;
    border: 2px solid #ddd;
    border-radius: 8px;
    cursor: pointer;
    font-size: 16px;
    font-weight: 500;
    transition: all 0.3s ease;
}

.ufh-favorite-btn:hover {
    background: #f8f8f8;
    border-color: #ccc;
    transform: translateY(-2px);
}

.ufh-favorite-btn .ufh-icon {
    font-size: 20px;
    color: #ddd;
    transition: all 0.3s ease;
}

.ufh-favorite-btn.ufh-favorited {
    background: #fff3cd;
    border-color: #ffc107;
}

.ufh-favorite-btn.ufh-favorited .ufh-icon {
    color: #ffc107;
}

.ufh-favorite-btn:disabled {
    opacity: 0.6;
    cursor: not-allowed;
}

/* Highlight Popup */
.ufh-highlight-popup {
    position: absolute;
    background: #333;
    color: #fff;
    padding: 8px;
    border-radius: 8px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.2);
    z-index: 9999;
    animation: fadeInUp 0.2s ease;
}

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

.ufh-popup-btn {
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 8px 16px;
    background: #ffc107;
    color: #333;
    border: none;
    border-radius: 6px;
    cursor: pointer;
    font-size: 14px;
    font-weight: 600;
    transition: all 0.2s ease;
}

.ufh-popup-btn:hover {
    background: #ffca28;
    transform: scale(1.05);
}

.ufh-popup-icon {
    font-size: 16px;
}

/* Profile Page */
.ufh-profile-page {
    max-width: 1200px;
    margin: 40px auto;
    padding: 0 20px;
}

.ufh-profile-container {
    background: #fff;
    border-radius: 12px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
    overflow: hidden;
}

.ufh-profile-header {
    display: flex;
    align-items: center;
    gap: 24px;
    padding: 40px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: #fff;
}

.ufh-profile-avatar img {
    border-radius: 50%;
    border: 4px solid #fff;
}

.ufh-profile-info h1 {
    margin: 0 0 8px 0;
    font-size: 32px;
}

.ufh-profile-email {
    margin: 0;
    opacity: 0.9;
    font-size: 16px;
}

/* Profile Tabs */
.ufh-profile-tabs {
    display: flex;
    border-bottom: 2px solid #f0f0f0;
    background: #fafafa;
}

.ufh-tab {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 20px;
    text-decoration: none;
    color: #666;
    font-weight: 500;
    transition: all 0.3s ease;
    position: relative;
}

.ufh-tab:hover {
    background: #f5f5f5;
    color: #333;
}

.ufh-tab.active {
    color: #667eea;
    background: #fff;
}

.ufh-tab.active::after {
    content: '';
    position: absolute;
    bottom: -2px;
    left: 0;
    right: 0;
    height: 2px;
    background: #667eea;
}

.ufh-tab-icon {
    font-size: 20px;
}

.ufh-tab-count {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 24px;
    height: 24px;
    padding: 0 8px;
    background: #e0e0e0;
    border-radius: 12px;
    font-size: 12px;
    font-weight: 600;
}

.ufh-tab.active .ufh-tab-count {
    background: #667eea;
    color: #fff;
}

/* Profile Content */
.ufh-profile-content {
    padding: 40px;
}

/* Empty State */
.ufh-empty-state {
    text-align: center;
    padding: 80px 20px;
    color: #999;
}

.ufh-empty-icon {
    font-size: 64px;
    display: block;
    margin-bottom: 16px;
    opacity: 0.5;
}

.ufh-empty-state h3 {
    margin: 0 0 8px 0;
    color: #666;
    font-size: 24px;
}

.ufh-empty-state p {
    margin: 0;
    font-size: 16px;
}

/* Favorites List */
.ufh-favorites-list {
    display: grid;
    gap: 24px;
}

.ufh-favorite-item {
    display: flex;
    gap: 20px;
    padding: 20px;
    background: #fafafa;
    border-radius: 8px;
    transition: all 0.3s ease;
}

.ufh-favorite-item:hover {
    background: #f5f5f5;
    box-shadow: 0 4px 12px rgba(0,0,0,0.1);
}

.ufh-favorite-thumbnail {
    flex-shrink: 0;
    width: 150px;
}

.ufh-favorite-thumbnail img {
    width: 100%;
    height: 150px;
    object-fit: cover;
    border-radius: 6px;
}

.ufh-favorite-details {
    flex: 1;
}

.ufh-favorite-title {
    margin: 0 0 12px 0;
    font-size: 20px;
}

.ufh-favorite-title a {
    text-decoration: none;
    color: #333;
    transition: color 0.2s ease;
}

.ufh-favorite-title a:hover {
    color: #667eea;
}

.ufh-favorite-excerpt {
    margin-bottom: 16px;
    color: #666;
    line-height: 1.6;
}

.ufh-favorite-meta {
    display: flex;
    align-items: center;
    gap: 16px;
    font-size: 14px;
}

.ufh-favorite-date {
    color: #999;
}

.ufh-remove-favorite,
.ufh-delete-highlight {
    padding: 6px 12px;
    background: #fff;
    border: 1px solid #ddd;
    border-radius: 4px;
    color: #d32f2f;
    cursor: pointer;
    font-size: 14px;
    transition: all 0.2s ease;
}

.ufh-remove-favorite:hover,
.ufh-delete-highlight:hover {
    background: #d32f2f;
    color: #fff;
    border-color: #d32f2f;
}

/* Highlights List */
.ufh-highlights-list {
    display: grid;
    gap: 20px;
}

.ufh-highlight-item {
    padding: 20px;
    background: #fff9e6;
    border-left: 4px solid #ffc107;
    border-radius: 4px;
    transition: all 0.3s ease;
}

.ufh-highlight-item:hover {
    box-shadow: 0 4px 12px rgba(0,0,0,0.1);
}

.ufh-highlight-text {
    margin-bottom: 16px;
    font-size: 16px;
    line-height: 1.8;
}

.ufh-highlight-text mark {
    background: #ffeb3b;
    padding: 2px 4px;
    border-radius: 2px;
    font-weight: 500;
}

.ufh-highlight-text .ufh-context {
    color: #999;
    font-style: italic;
}

.ufh-highlight-meta {
    display: flex;
    align-items: center;
    gap: 16px;
    flex-wrap: wrap;
    font-size: 14px;
}

.ufh-highlight-source {
    text-decoration: none;
    color: #667eea;
    font-weight: 500;
    transition: color 0.2s ease;
}

.ufh-highlight-source:hover {
    color: #764ba2;
}

.ufh-highlight-date {
    color: #999;
}

/* Notification */
.ufh-notification {
    position: fixed;
    top: 20px;
    right: 20px;
    padding: 16px 24px;
    background: #333;
    color: #fff;
    border-radius: 8px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.3);
    z-index: 10000;
    animation: slideInRight 0.3s ease;
}

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

.ufh-notification.success {
    background: #4caf50;
}

.ufh-notification.error {
    background: #f44336;
}

/* Responsive */
@media (max-width: 768px) {
    .ufh-profile-header {
        flex-direction: column;
        text-align: center;
        padding: 30px 20px;
    }
    
    .ufh-profile-info h1 {
        font-size: 24px;
    }
    
    .ufh-favorite-item {
        flex-direction: column;
    }
    
    .ufh-favorite-thumbnail {
        width: 100%;
    }
    
    .ufh-favorite-thumbnail img {
        width: 100%;
        height: 200px;
    }
    
    .ufh-tab-text {
        display: none;
    }
}
