/* ========================================
   PROFILE PAGE RESPONSIVE FIX - COMPLETE
   ======================================== */

/* === MOBILE VIEW (Up to 767px) === */
@media (max-width: 767px) {
    /* Banner - Better height */
    .bg-cover.overlay {
        min-height: 300px !important;
        height: 300px !important;
    }
    
    /* Profile Image - Larger and centered */
    .mentor-profile-img {
        width: 160px !important;
        height: 160px !important;
        margin: -80px auto 25px !important;
        display: block !important;
        float: none !important;
        border: 6px solid #fff !important;
        box-shadow: 0 6px 25px rgba(0,0,0,0.18) !important;
        position: relative !important;
        z-index: 100 !important;
        background-size: cover !important;
        background-position: center !important;
        border-radius: 50% !important;
    }
    
    /* Verified Badge */
    .verified-pbadge {
        position: absolute !important;
        bottom: 8px !important;
        right: 8px !important;
    }
    
    .verified-pbadge img {
        width: 38px !important;
    }
    
    /* Profile Section - Force center layout */
    .col-md-8 {
        width: 100% !important;
        padding: 0 15px !important;
        margin-bottom: 30px !important;
    }
    
    .col-md-8 > .d-flex {
        display: flex !important;
        flex-direction: column !important;
        align-items: center !important;
        text-align: center !important;
    }
    
    .col-md-8 .mr-3 {
        margin-right: 0 !important;
        margin-bottom: 0 !important;
        width: 100% !important;
    }
    
    /* Profile Info - Center everything */
    .col-md-8 .media-body {
        text-align: center !important;
        padding: 0 20px !important;
        width: 100% !important;
        margin-top: 0 !important;
    }
    
    .col-md-8 .media-body.pt-3 {
        padding-top: 0 !important;
    }
    
    /* Typography - Better sizes */
    .col-md-8 .media-body h2,
    .col-md-8 h2.text-dark {
        font-size: 24px !important;
        line-height: 1.4 !important;
        margin-bottom: 10px !important;
        font-weight: 700 !important;
    }
    
    .col-md-8 .media-body p,
    .col-md-8 .font-weight-light {
        font-size: 16px !important;
        line-height: 1.6 !important;
        margin-bottom: 8px !important;
    }
    
    .col-md-8 .fs-14 {
        font-size: 14px !important;
    }
    
    /* Social Icons - Center and space */
    .social-icon2 {
        display: flex !important;
        justify-content: center !important;
        align-items: center !important;
        margin: 20px auto 15px !important;
        padding: 0 !important;
        list-style: none !important;
    }
    
    .social-icon2 li {
        margin: 0 12px !important;
        display: inline-block !important;
    }
    
    .social-icon2 .bi {
        font-size: 24px !important;
    }
    
    /* Container adjustments */
    section.p-0.mb-5 .container {
        padding: 0 !important;
        max-width: 100% !important;
    }
    
    /* Tab Navigation */
    .tab-card-header {
        overflow-x: auto !important;
        -webkit-overflow-scrolling: touch !important;
    }
    
    .nav-tabs {
        display: flex !important;
        flex-wrap: nowrap !important;
        border-bottom: 2px solid #dee2e6 !important;
    }
    
    .nav-tabs .nav-link {
        font-size: 15px !important;
        padding: 14px 20px !important;
        white-space: nowrap !important;
    }
    
    /* Tab Content */
    .tab-content {
        padding: 25px 15px !important;
    }
    
    .mt-5 {
        margin-top: 25px !important;
    }
    
    /* Right Sidebar Card */
    .col-md-6 {
        padding: 0 15px !important;
        margin-bottom: 25px !important;
    }
    
    .right-overview,
    .ml-md-5 {
        margin-left: 0 !important;
        margin-top: 30px !important;
    }
    
    .sidebar-item {
        padding: 25px 20px !important;
        border-radius: 12px !important;
    }
    
    /* Booking Availability List */
   
    
    /* Form Elements */
    .form-group {
        margin-bottom: 20px !important;
    }
    
    .form-control {
        font-size: 15px !important;
        padding: 13px 16px !important;
        height: auto !important;
        border-radius: 8px !important;
    }
    
    label {
        font-size: 14px !important;
        font-weight: 600 !important;
        margin-bottom: 8px !important;
    }
    
    /* Buttons */
    .btn {
        font-size: 15px !important;
        padding: 13px 22px !important;
        border-radius: 8px !important;
        font-weight: 600 !important;
    }
    
    .btn.w-100 {
        width: 100% !important;
    }
    
    /* Experience/Education Cards */
    .sidebar-info {
        padding-left: 0 !important;
        margin-bottom: 30px !important;
    }
    
    .sidebar-item.shadow-lg {
        margin-bottom: 20px !important;
        padding: 18px !important;
    }
    
    .sidebar-icon {
        width: 50px !important;
        height: 50px !important;
        display: flex !important;
        align-items: center !important;
        justify-content: center !important;
        font-size: 22px !important;
    }
}

/* === TABLET VIEW (768px - 991px) === */
@media (min-width: 768px) and (max-width: 991px) {
    .bg-cover.overlay {
        min-height: 320px !important;
    }
    
    .mentor-profile-img {
        width: 170px !important;
        height: 170px !important;
        margin: -85px auto 30px !important;
        display: block !important;
        float: none !important;
        border: 6px solid #fff !important;
    }
    
    .d-flex.justify-content-between {
        flex-direction: column !important;
        align-items: center !important;
    }
    
    .media-body {
        text-align: center !important;
        padding: 0 25px !important;
        margin-top: 20px !important;
    }
    
    .media-body h2 {
        font-size: 26px !important;
    }
    
    .social-icon2 {
        justify-content: center !important;
        margin: 20px 0 !important;
    }
}

/* === DESKTOP VIEW (992px and up) === */
@media (min-width: 992px) {
    .bg-cover.overlay {
        min-height: 380px !important;
    }
    
    .mentor-profile-img {
        width: 190px !important;
        height: 190px !important;
        margin-top: -95px !important;
        border: 7px solid #fff !important;
        box-shadow: 0 8px 30px rgba(0,0,0,0.15) !important;
    }
    
    .media-body {
        padding-left: 25px !important;
    }
    
    .media-body h2 {
        font-size: 32px !important;
        font-weight: 700 !important;
    }
    
    .social-icon2 li {
        margin: 0 10px !important;
    }
    
    .right-overview {
        position: sticky;
        top: 20px;
    }
}

/* === RTL (ARABIC) SPECIFIC FIXES === */
[dir="rtl"] .mentor-profile-img,
html[dir="rtl"] .mentor-profile-img {
    float: none !important;
    margin-left: auto !important;
    margin-right: auto !important;
}

[dir="rtl"] .media-body,
html[dir="rtl"] .media-body {
    text-align: center !important;
    padding-right: 20px !important;
    padding-left: 20px !important;
}

[dir="rtl"] .list-group-item,
html[dir="rtl"] .list-group-item {
    text-align: right !important;
    direction: rtl !important;
}



[dir="rtl"] .mr-3,
html[dir="rtl"] .mr-3 {
    margin-right: auto !important;
    margin-left: auto !important;
}

[dir="rtl"] .ml-md-5,
html[dir="rtl"] .ml-md-5 {
    margin-left: 0 !important;
    margin-right: 0 !important;
}

[dir="rtl"] .sidebar-icon,
html[dir="rtl"] .sidebar-icon {
    margin-right: 0 !important;
    margin-left: 15px !important;
}

/* === EXTRA SMALL MOBILE (Up to 575px) === */
@media (max-width: 575px) {
    .bg-cover.overlay {
        min-height: 250px !important;
        height: 250px !important;
    }
    
    .mentor-profile-img {
        width: 140px !important;
        height: 140px !important;
        margin: -70px auto 20px !important;
        border-width: 5px !important;
    }
    
    .verified-pbadge img {
        width: 32px !important;
    }
    
    .media-body h2 {
        font-size: 20px !important;
    }
    
    .media-body p,
    .font-weight-light {
        font-size: 14px !important;
    }
    
    .social-icon2 .bi {
        font-size: 20px !important;
    }
    
    .social-icon2 li {
        margin: 0 8px !important;
    }
}

/* === GENERAL ENHANCEMENTS === */
.mentor-profile-img,
.btn,
.nav-link,
.social-icon2 a {
    transition: all 0.3s ease !important;
}

.social-icon2 a:hover {
    transform: translateY(-3px);
    opacity: 0.8;
}

.shadow-lg {
    box-shadow: 0 0.5rem 1.5rem rgba(0, 0, 0, 0.12) !important;
}

.br-10 {
    border-radius: 12px !important;
}

/* Ensure proper z-index stacking */
section.p-0.mb-5 {
    position: relative !important;
    z-index: 1 !important;
}

.mentor-profile-img {
    position: relative !important;
    z-index: 100 !important;
}
/* === FIX WHITE SPACE ON MOBILE === */
@media (max-width: 767px) {
    /* Remove container padding */
    section.p-0 .container-fluid,
    section.p-0 .container {
        padding-left: 0 !important;
        padding-right: 0 !important;
        margin-left: 0 !important;
        margin-right: 0 !important;
        max-width: 100% !important;
        width: 100% !important;
    }
    .list-group-item {
        display: flex !important;
        flex-direction: row !important;
        justify-content: space-between !important;
        align-items: center !important;
        padding: 16px !important;
        font-size: 15px !important;
    }
    
    .list-group-item > span,
    .list-group-item > label {
        flex: 1 !important;
        margin: 0 !important;
    }
    
    .list-group-item input[type="checkbox"],
    .list-group-item .form-check-input {
        margin: 0 !important;
        flex-shrink: 0 !important;
    }
    /* Full width for banner row */
    section.p-0 .row {
        margin-left: 0 !important;
        margin-right: 0 !important;
    }
    
    /* Full width for banner column */
    section.p-0 .col-md-12 {
        padding-left: 0 !important;
        padding-right: 0 !important;
    }
    
    /* Ensure banner is full width */
    .bg-cover.overlay {
        width: 100% !important;
        margin-left: 0 !important;
        margin-right: 0 !important;
    }
    
    /* Keep content section with padding */
    section.p-0 .container:not(.container-fluid) {
        padding-left: 15px !important;
        padding-right: 15px !important;
    }
}
 /* ---------------------------- */
 /* === ICON ON TOP FOR MOBILE === */
@media (max-width: 767px) {
    /* Stack icon on top */
    .sidebar-item .d-flex:not(.list-group-item) {
        flex-direction: column !important;
        align-items: center !important;
        text-align: center !important;
    }
    
    /* Icon styling - centered on top */
    .sidebar-icon {
        width: 60px !important;
        height: 60px !important;
        margin: 0 0 20px 0 !important;
        display: flex !important;
        align-items: center !important;
        justify-content: center !important;
        font-size: 28px !important;
        border-radius: 12px !important;
    }
    
    /* Content below icon - centered */
    .sidebar-item .d-flex > div:last-child {
        text-align: center !important;
        width: 100% !important;
    }
    
    /* Title styling */
    .sidebar-item h5,
    .sidebar-item .font-weight-bold {
        font-size: 18px !important;
        margin-bottom: 12px !important;
        line-height: 1.4 !important;
    }
    
    /* Description text */
    .sidebar-item p,
    .sidebar-item .text-muted {
        font-size: 14px !important;
        line-height: 1.7 !important;
        margin-bottom: 8px !important;
    }
    
    /* Better card spacing */
    .sidebar-item.shadow-lg {
        margin-bottom: 20px !important;
        padding: 25px 20px !important;
        border-radius: 16px !important;
    }
}

/* === RTL ICON FIX FOR MOBILE === */
@media (max-width: 767px) {
    [dir="rtl"] .sidebar-icon,
    html[dir="rtl"] .sidebar-icon {
        margin: 0 0 20px 0 !important;
    }
    
    [dir="rtl"] .sidebar-item .d-flex:not(.list-group-item),
    html[dir="rtl"] .sidebar-item .d-flex:not(.list-group-item) {
        flex-direction: column !important;
    }
}
/* === AVAILABILITY LIST - RTL/LTR FIX === */
.list-group-item {
    display: flex !important;
    flex-direction: row !important;
    justify-content: space-between !important;
    align-items: center !important;
}

[dir="rtl"] .list-group-item,
html[dir="rtl"] .list-group-item {
    text-align: right !important;
    direction: rtl !important;
}

[dir="ltr"] .list-group-item,
html[dir="ltr"] .list-group-item {
    text-align: left !important;
    direction: ltr !important;
}


