/* ==========================================================================
   CUSTOM USER PROFILE DESIGN
   ========================================================================== */

/* Scoped to the body class we added */
.custom-user-profile-page {
    background-color: #f3f4f6;
    color: #1f2937;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
}

/* Ensure Elementor template header displays with full styles */
.elementor-template-full-path {
    width: 100%;
}

.elementor {
    width: 100%;
}

/* Allow Elementor sections to use their own styling */
.elementor-section {
    width: 100%;
}

.custom-user-profile-container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 30px;
    width: 100%;
}

/* ==========================================================================
   HEADER CARD
   ========================================================================== */

.user-header-card {
    background: #fff;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
    margin-bottom: 24px;
    position: relative;
}

.user-cover-bg {
    height: 160px;
    background: linear-gradient(135deg, #124574 0%, #0d2e47 100%);
    width: 100%;
}

.user-header-content {
    padding: 0 30px 30px;
    display: flex;
    justify-content: space-between;
    align-items: flex-end;
    position: relative;
    margin-top: -60px; /* Overlap avatar */
    gap: 20px;
    flex-wrap: wrap;
}

.user-identity {
    display: flex;
    gap: 24px;
    align-items: flex-end;
    flex: 1;
    min-width: 300px;
}

.user-avatar-wrapper {
    flex-shrink: 0;
    width: 140px;
    height: 140px;
    border-radius: 50%;
    background: #fff;
    padding: 5px;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
}

.user-avatar,
.user-avatar-placeholder {
    width: 100%;
    height: 100%;
    border-radius: 50%;
    object-fit: cover;
    background: #e5e7eb;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 48px;
    color: #9ca3af;
    font-weight: 600;
}

.user-title-block {
    padding-bottom: 10px;
}

.user-name {
    font-size: 28px;
    font-weight: 700;
    color: #111827;
    margin: 0 0 8px 0;
    line-height: 1.2;
}

.user-rating-summary {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 12px;
}

.stars {
    color: #fbbf24; /* Amber 400 */
    font-size: 16px;
    letter-spacing: 1px;
}

.rating-val {
    font-weight: 700;
    color: #374151;
}

.rating-count {
    color: #6b7280;
    font-size: 14px;
}

.user-meta-badges {
    display: flex;
    gap: 16px;
    flex-wrap: wrap;
}

.meta-badge {
    font-size: 14px;
    color: #4b5563;
    display: flex;
    align-items: center;
    gap: 6px;
}

.meta-badge i {
    color: #9ca3af;
}

/* ==========================================================================
   CONTENT SECTIONS
   ========================================================================== */

/* Cards */
.content-card {
    background: #fff;
    border-radius: 12px;
    padding: 24px;
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.05);
}

.card-heading {
    font-size: 18px;
    font-weight: 600;
    color: #111827;
    margin: 0 0 20px 0;
    padding-bottom: 15px;
    border-bottom: 1px solid #e5e7eb;
}

.card-body {
    font-size: 15px;
    line-height: 1.6;
    color: #4b5563;
}

.text-content {
    font-size: 15px;
    line-height: 1.8;
}

.text-content p {
    margin-bottom: 16px;
}

.text-content p:last-child {
    margin-bottom: 0;
}

/* ==========================================================================
   REVIEWS SECTION
   ========================================================================== */

.reviews-section {
    margin-top: 40px;
    padding: 30px;
    background: #fff;
    border-radius: 12px;
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.05);
}

.reviews-section .section-title {
    font-size: 20px;
    font-weight: 700;
    color: #111827;
    margin: 0 0 24px 0;
    border-bottom: 2px solid #e5e7eb;
    padding-bottom: 15px;
}

.reviews-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(350px, 1fr));
    gap: 20px;
}

.review-card {
    border: 1px solid #e5e7eb;
    border-radius: 8px;
    padding: 20px;
    background: #f9fafb;
    transition: all 0.2s;
}

.review-card:hover {
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
    border-color: #d1d5db;
}

.review-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 15px;
    gap: 12px;
}

.reviewer-info {
    display: flex;
    align-items: center;
    gap: 12px;
    flex: 1;
}

.reviewer-avatar {
    flex-shrink: 0;
}

.reviewer-avatar img {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    display: block;
}

.reviewer-name {
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.reviewer-name strong {
    font-size: 15px;
    color: #111827;
}

.review-date {
    font-size: 13px;
    color: #6b7280;
}

.review-rating {
    flex-shrink: 0;
    color: #fbbf24;
    font-size: 14px;
    letter-spacing: 1px;
}

.review-content {
    color: #4b5563;
    font-size: 14px;
    line-height: 1.6;
}

.review-content p {
    margin: 0;
}

.no-reviews-state {
    text-align: center;
    padding: 40px 20px;
    color: #6b7280;
    font-size: 15px;
}

/* ==========================================================================
   RESPONSIVE
   ========================================================================== */

@media (max-width: 900px) {
    .user-header-content {
        flex-direction: column;
        align-items: center;
        text-align: center;
        margin-top: -50px;
    }

    .user-identity {
        flex-direction: column;
        align-items: center;
        width: 100%;
        min-width: 0;
    }

    .user-title-block {
        display: flex;
        flex-direction: column;
        align-items: center;
    }

    .user-meta-badges {
        justify-content: center;
    }
}

@media (max-width: 600px) {
    .user-cover-bg {
        height: 120px;
    }

    .user-avatar-wrapper {
        width: 100px;
        height: 100px;
    }

    .user-name {
        font-size: 24px;
    }

    .reviews-grid {
        grid-template-columns: 1fr;
    }

    .custom-user-profile-container {
        padding: 15px;
    }
}
