/* User Profile Styles - Social Media Enhanced Design */

/* Edit Profile Page - Ensure proper spacing and form text colors */


/* Fix input text color in dark theme - More specific selector, no !important */
[data-mdb-theme="dark"] .edit-profile-page .form-control,
[data-mdb-theme="dark"] .edit-profile-page .form-select {
    color: var(--mdb-text-primary);
}

[data-mdb-theme="dark"] .edit-profile-page .form-control:focus,
[data-mdb-theme="dark"] .edit-profile-page .form-select:focus {
    color: var(--mdb-text-primary);
}

/* Cover Image Container - Connected to profile card */
.profile-cover-container {
    position: relative;
    border-radius: 0.5rem 0.5rem 0 0;
    overflow: hidden;
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
    margin-bottom: 0;
}

.profile-cover-image {
    width: 100%;
    position: relative;
    overflow: hidden;
}

.profile-cover-image img,
.profile-cover-placeholder {
    width: 100%;
    display: block;
}

.profile-cover-placeholder {
    background: linear-gradient(135deg, var(--mdb-primary) 0%, var(--mdb-secondary) 100%);
}

/* Profile Details Card - Connected to cover */
.profile-details-card {
    border-radius: 0 0 0.5rem 0.5rem;
    border-top: none;
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
    margin-top: 0;
}

/* Profile Avatar Section */
.profile-avatar-section {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    min-width: 180px;
}

.profile-avatar-main {
    width: 168px;
    height: 168px;
    border: 5px solid var(--mdb-surface-bg);
    box-shadow: var(--mdb-box-shadow-3);
    background: var(--mdb-surface-bg);
    object-fit: cover;
    display: block;
    margin: 0 auto 1rem auto;
}

.profile-username {
    font-size: 1.75rem;
    font-weight: 600;
    color: var(--mdb-text-primary);
}

/* Profile Details Content */
.profile-details-content {
    display: flex;
    flex-direction: column;
    height: 100%;
    min-height: 200px;
}

/* Social Media Links in Profile Details */
.profile-social-links {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    align-items: center;
    margin-bottom: 1rem;
}

.profile-social-links .btn-floating {
    box-shadow: var(--mdb-box-shadow-2);
    transition: all 0.2s ease;
}

.profile-social-links .btn-floating:hover {
    transform: translateY(-2px);
    box-shadow: var(--mdb-box-shadow-3);
}

/* Profile Actions */
.profile-actions {
    margin-top: auto;
    padding-top: 1rem;
}

/* Group Badges */
.user-group-badges {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    margin-bottom: 1rem;
}

/* Clean User Details Layout */
.user-details-clean {
    display: flex;
    flex-wrap: wrap;
    gap: 1.5rem 2rem;
    margin-bottom: 1rem;
    align-items: center;
}

.user-detail-item {
    display: flex;
    align-items: center;
    color: var(--mdb-text-secondary);
    font-size: 0.95rem;
}

.user-detail-item i {
    width: 20px;
    text-align: center;
}

/* Action Buttons Overlay */
.profile-actions-overlay {
    position: absolute;
    top: 1rem;
    right: 1rem;
    z-index: 10;
}

/* Profile Username - Still used in profile.html */
.profile-username {
    font-size: 1.5rem;
    font-weight: 600;
    color: var(--mdb-text-primary);
    margin-bottom: 0.5rem;
}

.profile-tagline {
    font-size: 0.9rem;
    color: var(--mdb-text-secondary);
    font-style: italic;
    margin-bottom: 1rem;
}

/* Social Links */
.social-links {
    display: flex;
    justify-content: center;
    gap: 0.5rem;
    margin-bottom: 1rem;
}

.btn-floating {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
    box-shadow: var(--mdb-box-shadow-1);
}

.btn-floating:hover {
    transform: translateY(-2px);
    box-shadow: var(--mdb-box-shadow-2);
    opacity: 0.9;
}

/* Profile Sections - Simplified, no nested cards */
.profile-section-title {
    font-size: 1rem;
    font-weight: 600;
    color: var(--mdb-text-primary);
    margin-bottom: 0.75rem;
    padding-bottom: 0.5rem;
    border-bottom: 2px solid var(--mdb-border-color);
    display: flex;
    align-items: center;
}

.profile-section-title i {
    color: var(--mdb-primary);
}

.profile-info-section,
.profile-stats-section,
.profile-connections-section {
    padding: 0.75rem 0;
    border-bottom: 1px solid var(--mdb-border-color);
}

.profile-info-section:first-child {
    padding-top: 0.5rem;
}

.profile-info-section:last-child,
.profile-stats-section:last-child,
.profile-connections-section:last-child {
    border-bottom: none;
    padding-bottom: 0;
}

/* Profile Info Table */
.profile-info-table {
    margin: 0;
    background: transparent;
}

.profile-info-table th {
    color: var(--mdb-text-primary);
    font-weight: 600;
    padding: 0.5rem 0;
    border: none;
    background: transparent;
    width: 40%;
}

.profile-info-table td {
    color: var(--mdb-text-secondary);
    padding: 0.5rem 0;
    border: none;
    background: transparent;
}

.profile-info-table i {
    color: var(--mdb-primary);
    width: 1.25rem;
    text-align: center;
    margin-right: 0.5rem;
}

/* Forum stats removed - legacy style, templates should be updated for MDB5 */

/* Connections Section */
.connections-content {
    padding: 0;
}

.connections-group {
    margin-bottom: 1.5rem;
}

.connections-group:last-child {
    margin-bottom: 0;
}

.connections-title {
    font-size: 0.95rem;
    font-weight: 600;
    color: var(--mdb-text-primary);
    margin-bottom: 0.5rem;
    margin-top: 0.75rem;
    display: flex;
    align-items: center;
}

.connections-title:first-child {
    margin-top: 0;
}

.connections-title i {
    color: var(--mdb-primary);
    margin-right: 0.5rem;
}

.connection-avatars {
    display: flex;
    flex-wrap: wrap;
    gap: 0.25rem;
    margin-bottom: 0.75rem;
}

.connection-avatars:last-child {
    margin-bottom: 0;
}

.connection-avatar {
    border: 2px solid var(--mdb-surface-bg);
    transition: all 0.2s ease;
    box-shadow: var(--mdb-box-shadow-1);
    position: relative;
}

.connection-avatar:hover {
    transform: scale(1.15);
    border-color: var(--mdb-primary);
    box-shadow: var(--mdb-box-shadow-2);
    z-index: 10;
}

/* Enhanced Activity Feed - Social Media Style */
.activity-feed {
    padding: 0;
}

.activity-feed a {
    color: var(--mdb-primary);
    text-decoration: none;
    transition: all 0.2s ease;
    font-weight: 500;
}

.activity-feed a:hover {
    color: var(--mdb-link-hover-color);
    text-decoration: underline;
}

.activity-item {
    display: flex;
    gap: 0.75rem;
    padding: 0.75rem 1rem;
    border-bottom: 1px solid var(--mdb-border-color);
    transition: background-color 0.2s ease;
}

.activity-item:hover {
    background-color: var(--mdb-surface-hover, rgba(0,0,0,0.02));
}

.activity-item:last-child {
    border-bottom: none;
}

.activity-icon {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    background: var(--mdb-primary-light, rgba(var(--mdb-primary-rgb), 0.1));
    color: var(--mdb-primary);
    font-size: 1.1rem;
}

.activity-content {
    flex: 1;
    min-width: 0;
}

.activity-message {
    color: var(--mdb-text-primary);
    font-size: 0.95rem;
    line-height: 1.5;
    margin-bottom: 0.25rem;
}

.activity-message img {
    display: inline-block;
    vertical-align: middle;
    margin: 0 0.25rem;
}

.activity-timestamp {
    color: var(--mdb-text-muted);
    font-size: 0.8rem;
    display: flex;
    align-items: center;
    gap: 0.25rem;
}

.activity-avatar {
    border: 2px solid var(--mdb-border-color);
    flex-shrink: 0;
    transition: transform 0.2s ease;
}

.activity-avatar:hover {
    transform: scale(1.1);
}

/* Stats Section */
.profile-stats-content {
    padding: 0;
}

/* Stats Cards - Social Media Style */
.stat-card {
    text-align: center;
    padding: 0.75rem;
    border-radius: 0.5rem;
    background: var(--mdb-surface, transparent);
    transition: all 0.2s ease;
    border: 1px solid var(--mdb-border-color);
}

.stat-card:hover {
    transform: translateY(-2px);
    box-shadow: var(--mdb-box-shadow-2);
}

.stat-number {
    font-size: 1.75rem;
    font-weight: 700;
    color: var(--mdb-primary);
    line-height: 1;
    margin-bottom: 0.25rem;
}

.stat-label {
    color: var(--mdb-text-secondary);
    font-size: 0.875rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    font-weight: 500;
}

/* Button Enhancements - Removed global overrides */
/* Note: MDB5 handles global button styles - only add profile-specific overrides if truly needed */

/* Edit Profile Page Styles */
.wysiwyg-content {
    min-height: 200px;
    border: 1px solid var(--mdb-border-color);
    border-radius: var(--mdb-border-radius);
    padding: 1rem;
}

/* Edit Profile Page - Profile-specific styles only */
/* MDB 5 Pro handles all form-outline styling automatically */

/* Edit Profile Page - Profile-specific styles only */
/* MDB 5 Pro handles all form styling automatically */

/* Profile Cover/Avatar Edit Styles - Removed, using simple file upload fields now */

/* File Upload Drag and Drop */
/* File upload styles removed - now using MDB5 File Upload plugin */

/* Datepicker styles removed - now using MDB5 Datepicker plugin */

/* Status badge styles moved to style.css - using .status-badge-standard variant */

/* Row alignment - ensure cards align at top */
.profile-row {
    align-items: start;
}

/* Responsive adjustments */
@media (max-width: 768px) {
    .profile-cover-container {
        margin-bottom: 0;
        border-radius: 0.5rem 0.5rem 0 0;
    }
    
    .profile-details-card {
        border-radius: 0 0 0.5rem 0.5rem;
    }
    
    .profile-avatar-section {
        min-width: auto;
        margin-bottom: 1.5rem;
    }
    
    .profile-avatar-main {
        width: 120px;
        height: 120px;
        border-width: 4px;
    }
    
    .profile-username {
        font-size: 1.5rem;
    }
    
    .profile-cover-image img,
    .profile-cover-placeholder {
        height: 250px;
    }
    
    .profile-social-links .btn-floating {
        width: 36px;
        height: 36px;
        font-size: 0.875rem;
    }
    
    .profile-details-content {
        min-height: auto;
    }
    
    .user-details-clean {
        gap: 1rem;
        flex-direction: column;
    }
    
    .user-details-clean {
        gap: 1rem;
        flex-direction: column;
        align-items: flex-start;
    }
    
    .user-detail-item {
        font-size: 0.875rem;
    }
    
    /* Legacy styles removed - templates updated for MDB5 */
    
    .activity-item {
        padding: 0.5rem 0.75rem;
        gap: 0.5rem;
    }
    
    .profile-info-section,
    .profile-stats-section,
    .profile-connections-section {
        padding: 0.75rem 0;
    }
    
    .stat-card {
        padding: 0.5rem;
    }
    
    .stat-number {
        font-size: 1.5rem;
    }
    
    .activity-icon {
        width: 32px;
        height: 32px;
        font-size: 0.9rem;
    }
    
    .user-details-section {
        padding-left: 0;
        padding-top: 5rem;
    }
}

/* Group Badges */
.user-group-badges {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    margin-top: 0.5rem;
}

.group-badge {
    display: inline-flex;
    align-items: center;
    gap: 0.375rem;
    padding: 0.375rem 0.75rem;
    border-radius: 0.375rem;
    font-size: 0.875rem;
    font-weight: 500;
    white-space: nowrap;
}

.group-badge i {
    font-size: 0.875rem;
}

.group-badge.superuser {
    background-color: rgba(220, 53, 69, 0.1);
    color: #dc3545;
    border: 1px solid rgba(220, 53, 69, 0.2);
}

.group-badge.staff {
    background-color: rgba(255, 193, 7, 0.1);
    color: #ffc107;
    border: 1px solid rgba(255, 193, 7, 0.2);
}

.group-badge.regular {
    background-color: rgba(108, 117, 125, 0.1);
    color: #6c757d;
    border: 1px solid rgba(108, 117, 125, 0.2);
}

/* Networks Admined Section - Highlighted in Profile Header */
.networks-admined-section {
    padding: 1rem;
    background: linear-gradient(135deg, rgba(var(--mdb-primary-rgb, 59, 113, 202), 0.05) 0%, rgba(var(--mdb-secondary-rgb, 100, 181, 246), 0.05) 100%);
    border-radius: 0.5rem;
    border: 1px solid rgba(var(--mdb-primary-rgb, 59, 113, 202), 0.15);
}

.networks-admined-section h6 {
    font-size: 1rem;
    margin-bottom: 0.75rem;
}

.networks-admined-avatars {
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem;
}

.network-avatar-link {
    display: inline-block;
    transition: all 0.3s ease;
    position: relative;
}

.network-avatar-link:hover {
    transform: translateY(-4px) scale(1.05);
}

.network-avatar-link img,
.network-avatar-link > div {
    transition: all 0.3s ease;
    box-shadow: var(--mdb-box-shadow-2);
}

.network-avatar-link:hover img,
.network-avatar-link:hover > div {
    box-shadow: var(--mdb-box-shadow-4);
    border-color: var(--mdb-primary);
}

/* Responsive adjustments for networks admined */
@media (max-width: 768px) {
    .networks-admined-section {
        padding: 0.75rem;
    }
    
    .networks-admined-avatars {
        gap: 0.5rem;
    }
    
    .network-avatar-link img,
    .network-avatar-link > div {
        width: 48px;
        height: 48px;
    }
}

