/**
 * Modern Mentors Section
 * Discover the world's top mentors showcase
 */

/* ========================================================================
   Mentors Section Base
   ======================================================================== */

.mentors-section-modern {
    padding: 8rem 0;
    background: linear-gradient(180deg, #f9fafb 0%, #ffffff 50%, #f9fafb 100%);
    position: relative;
    overflow: hidden;
}

/* ========================================================================
   Section Header
   ======================================================================== */

.mentors-header {
    max-width: 900px;
    margin: 0 auto 5rem;
    position: relative;
    z-index: 5;
}

.mentors-header-top {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 1rem;
    flex-wrap: wrap;
    gap: 1rem;
}

.mentors-title-group {
    flex: 1;
}

.mentors-view-all {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.75rem 1.5rem;
    background: white;
    color: #4F46E5;
    border: 2px solid #e5e7eb;
    border-radius: 12px;
    font-weight: 600;
    font-size: 0.9375rem;
    transition: all 0.3s ease;
    text-decoration: none;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.04);
}

.mentors-view-all:hover {
    background: #4F46E5;
    color: white;
    border-color: #4F46E5;
    transform: translateY(-2px);
    box-shadow: 0 8px 20px rgba(79, 70, 229, 0.3);
    text-decoration: none;
}

.mentors-view-all i {
    transition: transform 0.3s ease;
}

.mentors-view-all:hover i {
    transform: translateX(4px);
}

/* ========================================================================
   Mentor Cards Grid
   ======================================================================== */

.mentors-grid-modern {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 2.5rem;
    position: relative;
    z-index: 5;
    margin-top: 0.5rem;
}

/* Ensure consistent card heights */
.mentors-grid-modern > * {
    height: 100%;
}

/* ========================================================================
   Mentor Card
   ======================================================================== */

.mentor-card-modern {
    background: #ffffff;
    border-radius: 24px;
    overflow: hidden;
    position: relative;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
    border: 2px solid #F3F4F6;
    cursor: pointer;
    display: flex;
    flex-direction: column;
    height: 100%;
}

.mentor-card-modern::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 5px;
    background: linear-gradient(90deg, #4F46E5 0%, #7C3AED 50%, #EC4899 100%);
    transform: scaleX(0);
    transform-origin: left;
    transition: transform 0.5s cubic-bezier(0.4, 0, 0.2, 1);
    z-index: 10;
}

.mentor-card-modern:hover {
    transform: translateY(-8px);
    box-shadow: 0 24px 48px rgba(0, 0, 0, 0.14);
    border-color: #E0E7FF;
}

.mentor-card-modern:hover::before {
    transform: scaleX(1);
}

/* ========================================================================
   Mentor Card Header
   ======================================================================== */

.mentor-card-header {
    position: relative;
    padding: 2.5rem 2rem 0;
    background: linear-gradient(135deg, #FAFBFC 0%, #F5F7FA 100%);
    border-bottom: 1px solid #F0F2F5;
}

.mentor-status-badge {
    position: absolute;
    top: 1.25rem;
    right: 1.25rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.5rem 1rem;
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(8px);
    border-radius: 20px;
    font-size: 0.8125rem;
    font-weight: 600;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
    z-index: 5;
    border: 1px solid rgba(255, 255, 255, 0.3);
}

.mentor-status-badge.online {
    color: #059669 !important;
    background: rgba(209, 250, 229, 0.95);
}

.mentor-status-badge.offline {
    color: #6B7280 !important;
    background: rgba(249, 250, 251, 0.95);
}

.mentor-status-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: currentColor;
    animation: pulse-dot 2s ease-in-out infinite;
}

@keyframes pulse-dot {
    0%, 100% {
        opacity: 1;
        transform: scale(1);
        box-shadow: 0 0 0 0 currentColor;
    }
    50% {
        opacity: 0.8;
        transform: scale(1.1);
        box-shadow: 0 0 0 4px rgba(255, 255, 255, 0.3);
    }
}

/* ========================================================================
   Mentor Avatar
   ======================================================================== */

.mentor-avatar-wrapper {
    position: relative;
    width: 140px;
    height: 140px;
    margin: 0 auto;
}

.mentor-avatar-ring {
    position: absolute;
    top: -8px;
    left: -8px;
    right: -8px;
    bottom: -8px;
    border-radius: 50%;
    background: linear-gradient(135deg, #4F46E5, #7C3AED, #EC4899);
    padding: 4px;
    animation: rotate-ring 8s linear infinite;
}

@keyframes rotate-ring {
    from {
        transform: rotate(0deg);
    }
    to {
        transform: rotate(360deg);
    }
}

.mentor-card-modern:hover .mentor-avatar-ring {
    animation-duration: 3s;
}

.mentor-avatar-main {
    position: relative;
    width: 100%;
    height: 100%;
    border-radius: 50%;
    overflow: hidden;
    background: white;
    padding: 4px;
    z-index: 2;
}

.mentor-avatar-image {
    width: 100%;
    height: 100%;
    border-radius: 50%;
    object-fit: cover;
    transition: transform 0.4s ease;
}

.mentor-card-modern:hover .mentor-avatar-image {
    transform: scale(1.1);
}

/* ========================================================================
   Rating Badge
   ======================================================================== */

.mentor-rating-badge {
    position: absolute;
    bottom: -14px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    align-items: center;
    gap: 0.375rem;
    padding: 0.5rem 1rem;
    background: linear-gradient(135deg, #FBBF24 0%, #F59E0B 100%);
    color: #ffffff !important;
    border-radius: 20px;
    font-size: 0.875rem;
    font-weight: 700;
    box-shadow: 0 6px 20px rgba(245, 158, 11, 0.4);
    z-index: 5;
    border: 2px solid #ffffff;
    letter-spacing: -0.01em;
}

.mentor-rating-badge i {
    font-size: 0.9375rem;
    color: #ffffff;
}

/* ========================================================================
   Mentor Card Body
   ======================================================================== */

.mentor-card-body {
    padding: 2rem 2rem 1.5rem;
    text-align: center;
    flex: 1;
    display: flex;
    flex-direction: column;
    background: #ffffff;
}

.mentor-name {
    font-size: 1.375rem;
    font-weight: 700;
    color: #111827 !important;
    margin-bottom: 0.5rem;
    line-height: 1.3;
    transition: color 0.3s ease;
    letter-spacing: -0.02em;
}

.mentor-card-modern:hover .mentor-name {
    color: #4F46E5 !important;
}

.mentor-title {
    font-size: 0.9375rem;
    color: #6B7280 !important;
    margin-bottom: 1.5rem;
    line-height: 1.5;
    font-weight: 500;
    min-height: 2.8rem;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

/* ========================================================================
   Mentor Stats
   ======================================================================== */

.mentor-stats {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 2rem;
    padding: 1.25rem 0;
    border-top: 2px solid #F3F4F6;
    border-bottom: 2px solid #F3F4F6;
    margin-bottom: 1.5rem;
    background: linear-gradient(180deg, #FAFBFC 0%, #ffffff 100%);
    border-radius: 12px;
}

.mentor-stat-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.375rem;
}

.mentor-stat-value {
    font-size: 1.375rem;
    font-weight: 700;
    color: #111827 !important;
    line-height: 1;
    letter-spacing: -0.02em;
}

.mentor-stat-label {
    font-size: 0.75rem;
    color: #9CA3AF !important;
    text-transform: uppercase;
    letter-spacing: 0.075em;
    font-weight: 600;
}

/* ========================================================================
   Mentor Categories/Skills
   ======================================================================== */

.mentor-categories {
    display: flex;
    flex-wrap: wrap;
    gap: 0.625rem;
    justify-content: center;
    margin-bottom: auto;
    padding-bottom: 1rem;
}

.mentor-category-tag {
    padding: 0.5rem 1rem;
    background: linear-gradient(135deg, #F9FAFB 0%, #F3F4F6 100%);
    color: #4B5563 !important;
    border: 1px solid #E5E7EB;
    border-radius: 20px;
    font-size: 0.8125rem;
    font-weight: 600;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    letter-spacing: 0.01em;
}

.mentor-card-modern:hover .mentor-category-tag {
    background: linear-gradient(135deg, #EEF2FF 0%, #E0E7FF 100%);
    color: #4F46E5 !important;
    border-color: #C7D2FE;
    transform: translateY(-2px);
}

/* ========================================================================
   Mentor Card Footer
   ======================================================================== */

.mentor-card-footer {
    padding: 0 2rem 2rem;
    display: flex;
    gap: 0.875rem;
    background: #ffffff;
    border-top: 1px solid #F3F4F6;
    padding-top: 1.5rem;
}

.mentor-btn {
    flex: 1;
    padding: 0.875rem 1.5rem;
    border-radius: 12px;
    font-weight: 600;
    font-size: 0.9375rem;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    border: none;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.625rem;
    text-decoration: none;
    letter-spacing: -0.01em;
}

.mentor-btn i {
    font-size: 1rem;
    transition: transform 0.3s ease;
}

.mentor-btn-primary {
    background: linear-gradient(135deg, #4F46E5 0%, #7C3AED 100%);
    color: #ffffff !important;
    box-shadow: 0 4px 16px rgba(79, 70, 229, 0.3);
    border: 2px solid transparent;
}

.mentor-btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 24px rgba(79, 70, 229, 0.4);
    color: #ffffff !important;
    text-decoration: none;
}

.mentor-btn-primary:hover i {
    transform: translateX(3px);
}

.mentor-btn-secondary {
    background: #ffffff;
    color: #4F46E5 !important;
    border: 2px solid #E5E7EB;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.04);
    flex: 0 0 auto;
    min-width: 52px;
}

.mentor-btn-secondary:hover {
    background: #F9FAFB;
    border-color: #4F46E5;
    color: #4F46E5 !important;
    text-decoration: none;
    box-shadow: 0 4px 12px rgba(79, 70, 229, 0.2);
}

.mentor-btn-secondary:hover i {
    transform: scale(1.1);
}

/* ========================================================================
   Verified Badge
   ======================================================================== */

.mentor-verified {
    display: inline-flex;
    align-items: center;
    gap: 0.375rem;
    color: #059669 !important;
    font-size: 0.875rem;
    font-weight: 600;
    margin-bottom: 0.625rem;
    background: linear-gradient(135deg, #D1FAE5 0%, #A7F3D0 100%);
    padding: 0.375rem 0.875rem;
    border-radius: 20px;
    border: 1px solid #6EE7B7;
}

.mentor-verified i {
    font-size: 1rem;
    color: #059669;
}

/* ========================================================================
   Background Decoration
   ======================================================================== */

.mentors-bg-decoration {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    pointer-events: none;
    z-index: 1;
    overflow: hidden;
}

.mentors-decoration-shape {
    position: absolute;
    opacity: 0.3;
}

.mentors-shape-1 {
    width: 500px;
    height: 500px;
    background: radial-gradient(circle, rgba(79, 70, 229, 0.1) 0%, transparent 70%);
    border-radius: 50%;
    top: -150px;
    right: -150px;
    animation: float-shape 25s ease-in-out infinite;
}

.mentors-shape-2 {
    width: 400px;
    height: 400px;
    background: radial-gradient(circle, rgba(236, 72, 153, 0.08) 0%, transparent 70%);
    border-radius: 50%;
    bottom: -100px;
    left: -100px;
    animation: float-shape 20s ease-in-out infinite 5s;
}

@keyframes float-shape {
    0%, 100% {
        transform: translate(0, 0) rotate(0deg);
    }
    33% {
        transform: translate(30px, -30px) rotate(120deg);
    }
    66% {
        transform: translate(-20px, 20px) rotate(240deg);
    }
}

/* ========================================================================
   Empty State
   ======================================================================== */

.mentors-empty-state {
    text-align: center;
    padding: 5rem 2rem;
    color: #9ca3af;
}

.mentors-empty-state i {
    font-size: 4rem;
    margin-bottom: 1.5rem;
    opacity: 0.5;
}

.mentors-empty-state h3 {
    font-size: 1.5rem;
    color: #6b7280;
    margin-bottom: 0.5rem;
}

.mentors-empty-state p {
    font-size: 1rem;
}

/* ========================================================================
   Mobile Responsiveness
   ======================================================================== */

@media (max-width: 1200px) {
    .mentors-grid-modern {
        grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
        gap: 2rem;
    }
}

@media (max-width: 991px) {
    .mentors-section-modern {
        padding: 5rem 0;
    }
    
    .mentors-header {
        margin-bottom: 3.5rem;
    }
    
    .mentors-grid-modern {
        grid-template-columns: repeat(auto-fill, minmax(270px, 1fr));
        gap: 2rem;
    }
    
    .mentor-card-header {
        padding: 2rem 1.75rem 0;
    }
    
    .mentor-avatar-wrapper {
        width: 120px;
        height: 120px;
    }
    
    .mentor-card-body {
        padding: 1.75rem 1.75rem 1.25rem;
    }
    
    .mentor-card-footer {
        padding: 1.25rem 1.75rem 1.75rem;
    }
}

@media (max-width: 768px) {
    .mentors-section-modern {
        padding: 4rem 0;
    }
    
    .mentors-header-top {
        flex-direction: column;
        align-items: stretch;
    }
    
    .mentors-view-all {
        width: 100%;
        justify-content: center;
    }
    
    .mentors-grid-modern {
        grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
        gap: 1.75rem;
    }
    
    .mentor-status-badge {
        top: 1rem;
        right: 1rem;
        padding: 0.4375rem 0.875rem;
        font-size: 0.75rem;
    }
    
    .mentor-avatar-wrapper {
        width: 110px;
        height: 110px;
    }
    
    .mentor-name {
        font-size: 1.25rem;
    }
    
    .mentor-title {
        font-size: 0.875rem;
        min-height: 2.625rem;
    }
    
    .mentor-stats {
        gap: 1.25rem;
        padding: 1rem 0;
    }
    
    .mentor-stat-value {
        font-size: 1.25rem;
    }
    
    .mentor-category-tag {
        padding: 0.4375rem 0.875rem;
        font-size: 0.75rem;
    }
}

@media (max-width: 576px) {
    .mentors-section-modern {
        padding: 3rem 0;
    }
    
    .mentors-header {
        margin-bottom: 2.5rem;
    }
    
    .mentors-grid-modern {
        grid-template-columns: 1fr;
        gap: 2rem;
        max-width: 420px;
        margin: 0 auto;
    }
    
    .mentor-card-modern {
        border-radius: 20px;
    }
    
    .mentor-card-header {
        padding: 1.75rem 1.5rem 0;
    }
    
    .mentor-status-badge {
        top: 1rem;
        right: 1rem;
        padding: 0.375rem 0.75rem;
    }
    
    .mentor-avatar-wrapper {
        width: 100px;
        height: 100px;
    }
    
    .mentor-rating-badge {
        padding: 0.4375rem 0.875rem;
        font-size: 0.8125rem;
        bottom: -12px;
    }
    
    .mentor-card-body {
        padding: 1.5rem 1.5rem 1.25rem;
    }
    
    .mentor-name {
        font-size: 1.125rem;
    }
    
    .mentor-title {
        font-size: 0.8125rem;
        min-height: 2.4rem;
        margin-bottom: 1.25rem;
    }
    
    .mentor-stats {
        gap: 1rem;
        padding: 1rem 0;
    }
    
    .mentor-stat-value {
        font-size: 1.125rem;
    }
    
    .mentor-stat-label {
        font-size: 0.6875rem;
    }
    
    .mentor-categories {
        gap: 0.5rem;
    }
    
    .mentor-category-tag {
        padding: 0.375rem 0.75rem;
        font-size: 0.6875rem;
    }
    
    .mentor-card-footer {
        padding: 1.25rem 1.5rem 1.5rem;
        gap: 0.75rem;
    }
    
    .mentor-btn {
        padding: 0.75rem 1.25rem;
        font-size: 0.875rem;
    }
    
    .mentor-btn-secondary {
        min-width: 48px;
    }
}

/* ========================================================================
   Owl Carousel Overrides (for existing carousel)
   ======================================================================== */

.mentors-carousel-modern .owl-nav {
    position: absolute;
    top: -80px;
    right: 0;
    display: flex;
    gap: 0.5rem;
}

.mentors-carousel-modern .owl-nav button {
    width: 48px;
    height: 48px;
    background: white !important;
    color: #4F46E5 !important;
    border: 2px solid #e5e7eb !important;
    border-radius: 12px !important;
    display: flex !important;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
    font-size: 1.25rem !important;
}

.mentors-carousel-modern .owl-nav button:hover {
    background: #4F46E5 !important;
    color: white !important;
    border-color: #4F46E5 !important;
    transform: translateY(-2px);
}

.mentors-carousel-modern .owl-nav button.disabled {
    opacity: 0.4;
    cursor: not-allowed;
}

.mentors-carousel-modern .owl-dots {
    display: flex;
    justify-content: center;
    gap: 0.5rem;
    margin-top: 2rem;
}

.mentors-carousel-modern .owl-dot {
    width: 12px;
    height: 12px;
    background: #d1d5db !important;
    border-radius: 50%;
    transition: all 0.3s ease;
}

.mentors-carousel-modern .owl-dot.active {
    background: #4F46E5 !important;
    width: 32px;
    border-radius: 6px;
}

/* ========================================================================
   Accessibility
   ======================================================================== */

.mentor-card-modern:focus {
    outline: 3px solid rgba(79, 70, 229, 0.5);
    outline-offset: 2px;
}

.mentor-card-modern:focus:not(:focus-visible) {
    outline: none;
}

@media (prefers-reduced-motion: reduce) {
    .mentor-card-modern,
    .mentor-avatar-image,
    .mentor-avatar-ring,
    .mentor-status-dot,
    .mentors-decoration-shape {
        transition: none;
        animation: none;
    }
    
    .mentor-card-modern:hover {
        transform: none;
    }
}

/* ========================================================================
   Loading State
   ======================================================================== */

.mentor-card-modern.loading {
    pointer-events: none;
}

.mentor-card-modern.loading .mentor-avatar-image {
    animation: pulse-loading 1.5s ease-in-out infinite;
}

@keyframes pulse-loading {
    0%, 100% {
        opacity: 1;
    }
    50% {
        opacity: 0.4;
    }
}

/* ========================================================================
   Print Styles
   ======================================================================== */

@media print {
    .mentors-section-modern {
        padding: 2rem 0;
    }
    
    .mentor-card-modern {
        box-shadow: none;
        border: 1px solid #e5e7eb;
        page-break-inside: avoid;
    }
    
    .mentor-btn,
    .mentors-view-all,
    .mentors-bg-decoration {
        display: none;
    }
}
