/* Global Utility Classes */


.nav-tabs .nav-link {
    font-size: 15px;
    padding: 9px;
}

.custom-text-truncate {
    text-overflow: ellipsis;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
    min-height: 48px;
    line-height: 1.5;
}

/* Age Slider Styles */
#slider-range, #slider-range-tablet, #slider-range-desktop, #slider-range-fallback {
    margin: 15px 10px 10px;
    height: 6px;
    border: none !important;
    background: #e2e8f0 !important;
    border-radius: 10px;
}
.ui-slider-range {
    background: var(--theme-primary, #6096B4) !important;
    border-radius: 10px;
}
.ui-slider-handle {
    height: 18px !important;
    width: 18px !important;
    top: -6px !important;
    background: #fff !important;
    border: 2px solid var(--theme-primary, #6096B4) !important;
    border-radius: 50% !important;
    cursor: pointer !important;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
    transition: transform 0.2s, box-shadow 0.2s;
    outline: none !important;
}
.ui-slider-handle:hover, .ui-slider-handle.ui-state-active {
    transform: scale(1.1);
    box-shadow: 0 3px 8px rgba(0,0,0,0.2);
}

.slider-container-box {
    background: #fff;
    padding: 10px 12px;
    border-radius: 5px;
    border: 1px solid #ced4da;
    box-shadow: none;
}

.age-display {
    font-size: 0.85rem;
    font-weight: 600 !important;
    color: #6c757d !important;
    margin-bottom: 5px;
    text-align: center;
    background: transparent !important;
    border: none !important;
    display: block;
    width: 100%;
}

/* Age Slider Container */
.age-slider-container {
    background: #fff;
    padding: 15px 15px 20px;
    border-radius: 10px;
    border: 1px solid rgba(255,255,255,0.2);
}

.age-slider-display span {
    font-size: 0.9rem;
    font-weight: 700;
    color: #fff;
    background: var(--theme-primary, #6096B4);
    padding: 4px 12px;
    border-radius: 20px;
    display: inline-block;
}

/* noUISlider Custom Styling */
.noUi-target {
    background: #e2e8f0;
    border: none;
    border-radius: 8px;
    box-shadow: none;
    height: 8px;
}

.noUi-connect {
    background: var(--theme-primary, #6096B4);
    border-radius: 8px;
}

/* Theme Button Styles */
.btn-theme {
    background-color: var(--bs-primary, #6096B4) !important;
    border-color: var(--bs-primary, #6096B4) !important;
    color: #fff !important;
    border-radius: 10px !important;
    padding: 10px 24px !important;
    font-weight: 600 !important;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1) !important;
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06) !important;
}

.btn-theme:hover {
    background-color: #4a7a96 !important; /* Slightly darker shade */
    border-color: #4a7a96 !important;
    transform: translateY(-2px) !important;
    box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05) !important;
}

.btn-theme:active {
    transform: translateY(0) !important;
}

.btn-theme-outline {
    background-color: #6096b4bd !important;
    border: 2px solid #fff !important;
    color: #fff !important;
    border-radius: 10px !important;
    padding: 9px 23px !important;
    font-weight: 600 !important;
    transition: all 0.3s ease !important;
}

.btn-theme-outline:hover {
    background-color: var(--bs-primary, #6096B4) !important;
    color: #fff !important;
    transform: translateY(-2px) !important;
}

.noUi-horizontal .noUi-handle {
    width: 22px;
    height: 22px;
    top: -8px;
    border-radius: 50%;
    background: #fff;
    border: 3px solid var(--theme-primary, #6096B4);
    box-shadow: 0 2px 6px rgba(0,0,0,0.15);
    cursor: grab;
}

.noUi-horizontal .noUi-handle:active {
    cursor: grabbing;
}

.noUi-horizontal .noUi-handle::before,
.noUi-horizontal .noUi-handle::after {
    display: none;
}

.noUi-handle:hover {
    transform: scale(1.1);
}


.tab-content {
    background-color: #fff;
    border: solid 1px #e1e1e1;
    border-bottom-right-radius: 10px;
    border-bottom-left-radius: 10px;
    border-top: none;
}

/* Modern CV Design System */
:root {
    --card-bg: #fff;
    --card-shadow: 0 4px 20px -2px rgba(0, 0, 0, 0.08);
    --card-hover-shadow: 0 12px 30px -4px rgba(0, 0, 0, 0.12);
    --theme-dark: #0f172a;
    --theme-primary: #6096B4;
    --text-muted: #64748b;
    --text-main: #1e293b;
    --accent-gold: #f59e0b;
}

/* Profiles Section & Titles */
.profiles-section {
    background-color: #f8fafc;
    border-top: 1px solid rgba(0,0,0,0.05);
}

.section-title-wrapper {
    position: relative;
    max-width: 600px;
    margin: 0 auto;
}

.section-title {
    font-weight: 900;
    color: var(--theme-dark);
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 15px;
    margin-bottom: 0.5rem;
}

.title-icon {
    color: var(--theme-primary);
    font-size: 1.8rem;
    background: white;
    width: 60px;
    height: 60px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 20px;
    box-shadow: 0 10px 20px -5px rgba(96, 150, 180, 0.2);
}

.title-underline {
    width: 80px;
    height: 4px;
    background: var(--theme-primary);
    margin: 0.5rem auto 0;
    border-radius: 2px;
}

/* CV Grid Layout */
.cv-flex-main {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 24px;
    padding: 10px 0;
    width: 100%;
}

.cv-main-box {
    width: 100%;
    margin-bottom: 1rem;
}

.cv-box {
    background: var(--card-bg);
    border: 1px solid rgba(226, 232, 240, 0.8);
    border-radius: 1.5rem;
    box-shadow: var(--card-shadow);
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
    padding: 1.5rem;
    display: flex;
    flex-direction: column;
    text-align: right;
    height: 100%;
}

.cv-box:hover {
    transform: translateY(-8px);
    box-shadow: var(--card-hover-shadow);
    border-color: var(--theme-primary);
}

/* Avatar Styling */
.avatar-section {
    display: flex;
    justify-content: center;
    margin-bottom: 1rem;
}

.avatar-wrapper {
    position: relative;
    width: 100px;
    height: 100px;
}

.avatar-wrapper img {
    width: 100px !important;
    height: 100px !important;
    border-radius: 30% !important;
    object-fit: cover;
    border: 3px solid #fff;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
    transition: transform 0.3s ease;
}

.verified-badge {
    position: absolute;
    bottom: -5px;
    right: -5px;
    background: #fff;
    border-radius: 50%;
    width: 24px;
    height: 24px;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.2);
    z-index: 2;
}

.verified-badge i {
    color: #3b82f6;
    font-size: 16px;
}

/* Job Title */
.job-title-link {
    text-decoration: none !important;
    display: block;
    margin-bottom: 0.75rem;
}

.job-title-text {
    color: var(--theme-dark);
    font-size: 1.1rem;
    font-weight: 800;
    line-height: 1.4;
    margin: 0;
    transition: color 0.2s;
}

/* Info Grid */
.info-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 0.5rem;
    margin-bottom: 1rem;
}

.info-item {
    background: #f8fafc;
    padding: 0.4rem 0.6rem;
    border-radius: 0.75rem;
    display: flex;
    align-items: center;
    gap: 0.4rem;
    font-size: 0.8rem;
    color: var(--text-muted);
    border: 1px solid transparent;
    transition: all 0.2s;
}

.info-item i {
    color: var(--theme-primary);
    width: 14px;
    text-align: center;
}

/* Summary Box */
.summary-box {
    background: #f1f5f9;
    padding: 0.75rem;
    border-radius: 1rem;
    margin-bottom: 0.75rem;
}

/* Footer Section */
.card-footer-info {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
    border-top: 1px solid #f1f5f9;
    padding-top: 0.75rem;
    margin-top: auto;
}

.location-chip {
    background: var(--theme-primary);
    color: white;
    padding: 0.4rem 0.75rem;
    border-radius: 50px;
    font-size: 0.75rem;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.4rem;
    font-weight: 600;
}

.stats-container {
    display: flex;
    justify-content: center;
    gap: 1rem;
    font-size: 0.75rem;
    color: var(--text-muted);
}

.stat-item {
    display: flex;
    align-items: center;
    gap: 0.3rem;
}

/* More Info Toggle */
.btn-more-info {
    background: var(--bs-purpul);
    color: white !important;
    border: none;
    padding: 0.5rem 1.25rem;
    border-radius: 50px;
    font-size: 0.8rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s;
    margin-top: 0.75rem;
    align-self: center;
}

.btn-more-info:hover {
    background: #1e293b;
    transform: scale(1.05);
}

/* Expanded View */
.hide {
    display: none;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.showDetailes {
    display: block !important;
    opacity: 1;
}

.contents-box {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(80px, 1fr));
    gap: 8px;
    background: #f8fafc;
    padding: 10px;
    border-radius: 12px;
    border: 1px solid #e2e8f0;
}

.contents-box p {
    margin: 0;
    font-size: 0.8rem;
    color: var(--text-main);
    text-align: center;
}

.contents-box .answer i {
    margin-left: 4px;
    color: var(--theme-primary);
}

/* Featured Badge */
.badge-featured {
    position: absolute;
    top: 10px;
    left: 15px;
    background: linear-gradient(135deg, #f59e0b, #d97706);
    color: white;
    padding: 2px 10px;
    border-radius: 50px;
    font-size: 0.65rem;
    font-weight: 700;
    box-shadow: 0 4px 10px rgba(245, 158, 11, 0.3);
    z-index: 10;
}

/* Header & Search Form */
header {
    background: linear-gradient(rgba(15, 23, 42, 0.8), rgba(15, 23, 42, 0.9)), url('/static/img/hero-bg.jpg') center/cover no-repeat;
    min-height: 60vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 100px 20px 60px;
    color: white;
    text-align: center;
}

header h1 {
    font-size: 3.5rem;
    font-weight: 900;
    margin-bottom: 1.5rem;
    background: linear-gradient(135deg, #fff 0%, #6096B4 100%);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
}

.main-search-form {
    background: rgba(255, 255, 255, 0.05);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 2rem;
    padding: 1.5rem;
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.5);
    margin: 0 auto;
    max-width: 700px;
}

.search-row .input-group {
    background: white;
    padding: 0.5rem;
    border-radius: 1.5rem;
    display: flex;
    gap: 8px;
}

.search-input {
    border: none !important;
    padding: 0.75rem 1.5rem !important;
    font-size: 1rem !important;
    flex-grow: 1;
}

/* Advanced Search Toggle */
.advanced-search-toggle {
    background: #f1f5f9;
    border: none;
    color: var(--theme-dark);
    padding: 0.5rem 1rem;
    border-radius: 1rem;
    font-size: 0.9rem;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    transition: all 0.2s;
    white-space: nowrap;
}

.advanced-search-toggle:hover {
    background: #e2e8f0;
    color: var(--theme-primary);
}

.advanced-search-toggle i {
    color: var(--theme-primary);
}

.search-button {
    background: var(--theme-primary) !important;
    border: none !important;
    color: white !important;
    border-radius: 1rem !important;
    padding: 0.75rem 2rem !important;
    font-weight: bold;
}

/* Distinctive Members Scroll */
.scrollable-cards {
    display: flex;
    overflow-x: auto;
    gap: 0px;
    padding: 20px 15px;
    background-color: #f8f9fa;
    border-radius: 20px;
    box-shadow: inset 0 0 10px rgba(0, 0, 0, 0.05);
    scrollbar-width: none;
    -ms-overflow-style: none;
    margin-bottom: 20px;
    position: relative;
    -webkit-overflow-scrolling: touch;
}

.scrollable-cards::-webkit-scrollbar {
    display: none;
}

.user-card {
    flex: 0 0 auto;
    width: 80px;
    background: white;
    border-radius: 12px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    overflow: hidden;
    border: 1px solid rgba(0,0,0,0.03);
    scroll-snap-align: center;
}

.user-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 15px rgba(0, 0, 0, 0.12);
    border-color: var(--theme-primary);
}

.card-link {
    text-decoration: none;
    color: inherit;
    display: block;
}

.card-image {
    display: flex;
    justify-content: center;
    padding: 10px 5px 5px;
}

.profile-img {
    width: 55px;
    height: 55px;
    border-radius: 30%;
    object-fit: cover;
    border: 2px solid white;
    box-shadow: 0 2px 6px rgba(0,0,0,0.1);
}

.card-details {
    padding: 0 5px 10px;
}

.job-title {
    font-size: 9px !important;
    line-height: 1.3;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    height: 24px;
    margin: 0 !important;
    text-align: center;
}

/* Highlight for distinctive border in scroll */
.border-prim {
    border: 3px solid var(--accent-gold) !important;
    box-shadow: 0 0 10px rgba(245, 158, 11, 0.3);
}

/* Scroll Animation Indicator */
@keyframes fadeInOut {
    0%, 100% { opacity: 0.3; transform: translate(0, -50%); }
    50% { opacity: 1; transform: translate(-10px, -50%); }
}

.scroll-indicator {
    pointer-events: none;
    animation: fadeInOut 2s infinite ease-in-out;
}

/* Mobile Specific Tweaks (1 per row, SUPER COMPACT) */
@media (max-width: 576px) {
    .cv-flex-main {
        grid-template-columns: 1fr;
        gap: 15px;
        padding: 5px;
    }
    .cv-box {
        padding: 12px;
        border-radius: 1.25rem;
    }
    .cv-content {
        display: grid;
        grid-template-columns: 1fr 85px;
        gap: 12px;
        align-items: center;
        text-align: right;
    }
    .avatar-section {
        grid-column: 2;
        grid-row: 1 / span 2;
        margin-bottom: 0;
    }
    .job-title-link {
        grid-column: 1;
        grid-row: 1;
        margin-bottom: 4px;
    }
    .info-grid {
        grid-column: 1;
        grid-row: 2;
        display: grid;
        grid-template-columns: 1fr 1fr;
        gap: 6px;
        margin-bottom: 0;
    }
    .avatar-wrapper {
        width: 80px;
        height: 80px;
    }
    .avatar-wrapper img {
        width: 80px !important;
        height: 80px !important;
    }
    .job-title-text {
        font-size: 1rem;
    }
    .info-item {
        padding: 3px 6px;
        font-size: 0.7rem;
        background: #f8fafc;
        border: 1px solid rgba(0,0,0,0.03);
    }
    .summary-box {
        margin-top: 10px;
        padding: 8px;
        font-size: 0.8rem;
        background: #f1f5f9;
        margin-bottom: 8px;
    }
    .custom-text-truncate {
        -webkit-line-clamp: 2;
        line-clamp: 2;
        min-height: auto;
    }
    .card-footer-info {
        flex-direction: row;
        justify-content: space-between;
        align-items: center;
        padding-top: 10px;
        border-top: 1px solid #f1f5f9;
        margin-top: 0px;
    }
    .location-chip {
        font-size: 0.7rem;
        padding: 4px 10px;
        margin-bottom: 0;
    }
    .stats-container {
        gap: 10px;
        font-size: 0.7rem;
        margin-top: 0;
    }
    .btn-more-info {
        width: 100%;
        margin-top: 10px;
        padding: 8px;
        font-size: 0.85rem;
    }
    .badge-featured {
        top: 8px;
        left: 10px;
        font-size: 0.55rem;
    }
}

/* Animations */
@keyframes fadeInUp {
    from { opacity: 0; transform: translateY(20px); }
    to { opacity: 1; transform: translateY(0); }
}

.animate-up {
    animation: fadeInUp 0.6s ease-out forwards;
}

/* Responsive */
@media (max-width: 768px) {
    header h1 { font-size: 1.5rem; }
    .search-row .input-group { flex-direction: column; background: transparent; padding: 0; }
    .search-input, .search-button { width: 100% !important; margin-bottom: 10px; border-radius: 1rem !important; }
}

/* --- Added Slider Styles --- */
.slider-wrapper {
    position: relative;
}
.slider-btn {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: white;
    box-shadow: 0 4px 10px rgba(0,0,0,0.1);
    border: none;
    color: var(--theme-primary);
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    z-index: 20;
    transition: all 0.2s;
}
.slider-btn:hover {
    background: var(--theme-primary);
    color: white;
    transform: translateY(-50%) scale(1.1);
}
.prev-btn {
    right: -10px; /* Right overlap for RTL start */
}
.next-btn {
    left: -10px; /* Left overlap for RTL end */
}
.scrollable-cards {
    scroll-snap-type: x proximity;
    overscroll-behavior-x: contain;
}
.user-card {
    scroll-snap-align: start;
}

/* Social Media Icon Styling */
.social-links-grid {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    justify-content: center;
    padding: 15px;
}

.social-link-item {
    width: 45px;
    height: 45px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 12px;
    font-size: 1.25rem;
    color: #fff;
    text-decoration: none !important;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
    background-color: #f1f5f9;
    color: #64748b;
}

.social-link-item:hover {
    transform: translateY(-3px) scale(1.1);
    box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
}

.social-link-item.instagram:hover { background: radial-gradient(circle at 30% 107%, #fdf497 0%, #fdf497 5%, #fd5949 45%, #d6249f 60%, #285AEB 90%); color: white; }
.social-link-item.snapchat:hover { background-color: #FFFC00; color: #000; text-shadow: none; }
.social-link-item.tiktok:hover { background-color: #000000; color: white; border: 1px solid #ff0050; box-shadow: 2px 2px #00f2ea, -2px -2px #ff0050; }
.social-link-item.facebook:hover { background-color: #1877F2; color: white; }
.social-link-item.linkedin:hover { background-color: #0A66C2; color: white; }
.social-link-item.whatsapp:hover { background-color: #25D366; color: white; }
.social-link-item.twitter:hover, .social-link-item.x-twitter:hover { background-color: #000000; color: white; }
.social-link-item.youtube:hover { background-color: #FF0000; color: white; }
.social-link-item.website:hover { background-color: var(--theme-primary, #6096B4); color: white; }
.social-link-item.email:hover { background-color: #ea4335; color: white; }
.social-link-item.phone:hover { background-color: #34a853; color: white; }
.social-link-item.telegram:hover { background-color: #0088cc; color: white; }
