/* ==========================================================================
   Member Search Shared Styles
   Used by: MemberSearchAllCompanies, MemberSearchCompanyDetails,
            MemberSearchCompanyPeople, MemberSearchPersonDetails,
            MemberSearchMyDirectory
   ========================================================================== */

/* --- Table --- */
.ms-table-container {
    border-radius: 16px;
    overflow: hidden;
}

.ms-table {
    width: 100%;
    border-collapse: collapse;
    border-spacing: 0;
    border: none;
}

.ms-table thead th {
    background-color: rgba(219, 234, 185, 0.3);
    font-family: 'Gotham Medium', 'Gotham', sans-serif;
    font-weight: 350;
    font-size: 18px;
    line-height: 26px;
    color: #434343;
    text-transform: capitalize;
    padding: 32px 24px;
    border: none;
    vertical-align: middle;
    white-space: nowrap;
}

.ms-table tbody td {
    font-family: 'Gotham Book', 'Gotham', sans-serif;
    font-weight: 325;
    font-size: 18px;
    line-height: 26px;
    color: #434343;
    padding: 25px 24px;
    border: none;
    vertical-align: middle;
}

.ms-table tbody tr:nth-of-type(even) {
    background-color: rgba(219, 234, 185, 0.3);
}

.ms-table tbody tr:nth-of-type(odd) {
    background-color: #fff;
}

.ms-table tbody td a {
    color: #296DC1;
    text-decoration: none;
}

.ms-table tbody td a:hover {
    text-decoration: underline;
}

.ms-table-title {
    font-family: 'Gotham Book', 'Gotham', sans-serif;
    font-size: 22px;
    line-height: 30px;
    color: #002569;
    text-transform: capitalize;
    margin-bottom: 24px;
}

.ms-table-info {
    font-family: 'Gotham Book', 'Gotham', sans-serif;
    font-size: 14px;
    color: #707070;
    text-align: right;
    margin: 12px 0;
}

/* --- Sort --- */
.sortable {
    cursor: pointer;
    user-select: none;
}

.sort-icon {
    margin-left: 6px;
    color: #868F98;
    font-size: 14px;
    transition: color 0.2s ease;
}

.sort-icon.fa-angle-up,
.sort-icon.fa-angle-down {
    color: #434343;
}

/* --- Search bar --- */
.ms-search-bar {
    display: flex;
    gap: 32px;
    align-items: stretch;
    width: 100%;
    margin-bottom: 1rem;
}

.ms-search-input-group {
    display: flex;
    align-items: stretch;
    height: 58px;
    width: 49%;
    flex-shrink: 0;
}

.ms-search-field {
    flex: 1;
    display: flex;
    align-items: center;
    gap: 16px;
    border: 2px solid #0053A5;
    border-right: none;
    border-radius: 8px 0 0 8px;
    padding: 8px 16px;
    background: #fff;
}

.ms-search-field .ms-search-icon {
    color: #0053A5;
    font-size: 18px;
    flex-shrink: 0;
}

.ms-search-field input {
    border: none;
    outline: none;
    background: transparent;
    font-family: 'Gotham Book', 'Gotham', sans-serif;
    font-size: 18px;
    line-height: 26px;
    color: #000;
    width: 100%;
}

.ms-search-field input::placeholder {
    color: #000;
}

.ms-search-btn {
    background-color: #0053A5;
    color: #fff;
    border: 2px solid #0053A5;
    border-radius: 0 8px 8px 0;
    padding: 16px 50px;
    font-family: 'Gotham Book', 'Gotham', sans-serif;
    font-size: 18px;
    line-height: 26px;
    cursor: pointer;
    white-space: nowrap;
    display: flex;
    align-items: center;
    justify-content: center;
}

.ms-search-btn:hover {
    background-color: #003d7a;
    border-color: #003d7a;
}

/* --- Dropdowns --- */
.ms-dropdowns {
    display: flex;
    gap: 32px;
    flex: 1;
    align-items: stretch;
}

.ms-select-wrapper {
    flex: 1;
    position: relative;
}

.ms-select {
    width: 100%;
    height: 56px;
    background-color: #F5F5F5;
    border: none;
    border-radius: 8px;
    padding: 16px;
    padding-right: 56px;
    font-family: 'Gotham Book', 'Gotham', sans-serif;
    font-size: 20px;
    line-height: 28px;
    color: #002569;
    appearance: none;
    -webkit-appearance: none;
    -moz-appearance: none;
    cursor: pointer;
    background-image: url("data:image/svg+xml,%3Csvg width='32' height='32' viewBox='0 0 32 32' fill='none' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M16 29.33C23.36 29.33 29.33 23.36 29.33 16S23.36 2.67 16 2.67 2.67 8.64 2.67 16 8.64 29.33 16 29.33z' stroke='%23002569' stroke-width='1.5' stroke-miterlimit='10' stroke-linecap='round' stroke-linejoin='round'/%3E%3Cpath d='M11.44 14.56L16 19.12l4.56-4.56' stroke='%23002569' stroke-width='1.5' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 16px center;
    background-size: 32px 32px;
}

.ms-select:focus {
    outline: 2px solid #0053A5;
    outline-offset: -2px;
}

/* --- Filter sidebar (accordion) --- */
.ms-sidebar {
    padding-right: 1px;
}

.ms-sidebar-title {
    font-family: 'Gotham Medium', 'Gotham', sans-serif;
    font-size: 20px;
    line-height: 28px;
    color: #002569;
    margin-bottom: 16px;
}

.ms-clear-btn {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    background: none;
    border: 2px solid #0053A5;
    border-radius: 8px;
    color: #0053A5;
    font-family: 'Gotham Book', 'Gotham', sans-serif;
    font-size: 14px;
    line-height: 22px;
    padding: 8px 16px;
    cursor: pointer;
    margin-bottom: 20px;
    transition: background-color 0.2s, color 0.2s;
    width: 100%;
    justify-content: center;
}

.ms-clear-btn:hover {
    background-color: #0053A5;
    color: #fff;
}

.ms-filter-section {
    margin-bottom: 12px;
    border: none;
    padding: 0;
}

.ms-filter-section:last-child {
    margin-bottom: 12px;
}

.ms-filter-section > summary {
    background-color: #F5F5F5;
    border-radius: 12px;
    font-family: 'Gotham Book', 'Gotham', sans-serif;
    font-size: 14px;
    line-height: 20px;
    color: #0053A5;
    text-transform: capitalize;
    padding: 14px 16px;
    cursor: pointer;
    list-style: none;
    display: flex;
    align-items: center;
    justify-content: space-between;
    user-select: none;
    transition: background-color 0.25s ease, color 0.25s ease;
}

.ms-filter-section > summary::-webkit-details-marker {
    display: none;
}

.ms-filter-section > summary::after {
    content: '+';
    display: flex;
    align-items: center;
    justify-content: center;
    width: 26px;
    height: 26px;
    min-width: 26px;
    background-color: #0053A5;
    color: #fff;
    border-radius: 50%;
    font-size: 18px;
    font-weight: 300;
    line-height: 1;
    flex-shrink: 0;
    transition: background-color 0.25s ease, color 0.25s ease;
}

.ms-filter-section[open] > summary {
    background-color: #0053A5;
    color: #fff;
    border-radius: 12px;
}

.ms-filter-section[open] > summary::after {
    content: '\2212';
    background-color: #fff;
    color: #0053A5;
}

.ms-filter-group {
    padding: 12px 8px 8px 8px;
    max-height: 280px;
    overflow-y: auto;
}

.ms-filter-group::-webkit-scrollbar {
    width: 4px;
}

.ms-filter-group::-webkit-scrollbar-thumb {
    background-color: #C4C4C4;
    border-radius: 4px;
}

.ms-filter-group .form-check {
    padding: 4px 0 4px 28px;
    margin-bottom: 0;
    min-height: auto;
}

.ms-filter-group .form-check-input {
    width: 18px;
    height: 18px;
    margin-top: 2px;
    margin-left: -28px;
    border: 2px solid #868F98;
    border-radius: 4px;
    cursor: pointer;
}

.ms-filter-group .form-check-input:checked {
    background-color: #0053A5;
    border-color: #0053A5;
}

.ms-filter-group .form-check-input:focus {
    box-shadow: 0 0 0 2px rgba(0, 83, 165, 0.25);
}

.ms-filter-group .form-check-label {
    font-family: 'Gotham Book', 'Gotham', sans-serif;
    font-size: 14px;
    line-height: 22px;
    color: #434343;
    cursor: pointer;
}

.ms-filter-group .toggle-more {
    display: inline-block;
    margin-top: 8px;
    font-family: 'Gotham Book', 'Gotham', sans-serif;
    font-size: 13px;
    color: #0053A5;
    text-decoration: none;
    padding-left: 28px;
}

.ms-filter-group .toggle-more:hover {
    text-decoration: underline;
}

.ms-filter-group .text-muted {
    font-family: 'Gotham Book', 'Gotham', sans-serif;
    font-size: 13px;
    color: #868F98 !important;
    padding-left: 0;
}

/* --- Mobile responsive --- */
@media (max-width: 767.98px) {
    .ms-table-container {
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
    }

    .ms-table {
        min-width: 500px;
    }

    .ms-table thead th {
        font-size: 16px;
        padding: 24px 16px;
    }

    .ms-table tbody td {
        font-size: 16px;
        padding: 24px 16px;
    }

    .ms-table-title {
        font-size: 18px;
        line-height: 26px;
    }

    .ms-sidebar {
        padding-right: 0;
        margin-bottom: 24px;
    }

    .ms-sidebar-title {
        font-size: 18px;
    }

    .ms-filter-section > summary {
        font-size: 13px;
        padding: 12px 14px;
    }

    .ms-filter-section > summary::after {
        width: 22px;
        height: 22px;
        min-width: 22px;
        font-size: 16px;
    }

    .ms-filter-group {
        max-height: 200px;
    }

    .ms-search-bar {
        flex-direction: column;
        gap: 24px;
    }

    .ms-search-input-group {
        width: 100%;
        height: 36px;
    }

    .ms-search-field {
        gap: 8px;
        padding: 8px 16px;
        border-radius: 8px 0 0 8px;
    }

    .ms-search-field .ms-search-icon {
        font-size: 15px;
    }

    .ms-search-field input {
        font-size: 14px;
        line-height: 22px;
    }

    .ms-search-btn {
        padding: 8px 24px;
        font-size: 14px;
        line-height: 22px;
        border-radius: 0 8px 8px 0;
    }

    .ms-dropdowns {
        gap: 15px;
    }

    .ms-select {
        height: 40px;
        font-size: 14px;
        line-height: 22px;
        padding: 8px 16px;
        padding-right: 48px;
        background-size: 24px 24px;
    }
}

/* --- Company detail header --- */
.cd-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    flex-wrap: wrap;
    gap: 16px;
    margin-bottom: 24px;
}

    .cd-header h2 {
        font-family: 'Gotham Medium', 'Gotham', sans-serif;
        font-size: 28px;
        line-height: 36px;
        color: #002569;
        margin-bottom: 4px;
    }

    .cd-header .orgtype {
        font-family: 'Gotham Book', 'Gotham', sans-serif;
        font-size: 16px;
        color: #707070;
    }

.cd-save-btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: none;
    border: 2px solid #0053A5;
    border-radius: 8px;
    color: #0053A5;
    font-family: 'Gotham Book', 'Gotham', sans-serif;
    font-size: 16px;
    line-height: 24px;
    padding: 10px 24px;
    cursor: pointer;
    transition: background-color 0.2s, color 0.2s;
    white-space: nowrap;
}

    .cd-save-btn:hover {
        background-color: #0053A5;
        color: #fff;
    }

/* --- Info card --- */
.cd-info-card {
    border: 1px solid #DBEBB9;
    border-radius: 16px;
    padding: 24px;
    display: flex;
    flex-wrap: wrap;
    gap: 24px;
    margin-bottom: 32px;
    background: #fff;
}

    .cd-info-card .cd-info-col {
        flex: 1;
        min-width: 200px;
    }

    .cd-info-card ul {
        list-style: none;
        padding: 0;
        margin: 0;
    }

    .cd-info-card li {
        display: flex;
        align-items: flex-start;
        gap: 12px;
        font-family: 'Gotham Book', 'Gotham', sans-serif;
        font-size: 16px;
        line-height: 24px;
        color: #434343;
        margin-bottom: 12px;
    }

        .cd-info-card li:last-child {
            margin-bottom: 0;
        }

        .cd-info-card li i {
            color: #707070;
            font-size: 16px;
            margin-top: 4px;
            flex-shrink: 0;
        }

    .cd-info-card a {
        color: #296DC1;
        text-decoration: none;
    }

        .cd-info-card a:hover {
            text-decoration: underline;
        }

/* --- Mobile responsive (widget-specific) --- */
@@media (max-width: 767.98px) {
    .cd-header {
        flex-direction: column;
    }

        .cd-header h2 {
            font-size: 22px;
            line-height: 30px;
        }

    .cd-info-card {
        flex-direction: column;
        gap: 16px;
        padding: 16px;
    }
}
/* --- Page layout (widget-specific) --- */
.md-page-layout {
    display: flex;
    gap: 40px;
    padding-top: 10px;
}

.md-main-col {
    flex: 1;
    min-width: 0;
}

.md-sidebar-col {
    width: 260px;
    flex-shrink: 0;
}

/* --- Mobile responsive (widget-specific) --- */
@@media (max-width: 991.98px) {
    .md-page-layout {
        flex-direction: column;
        gap: 24px;
    }

    .md-sidebar-col {
        width: 100%;
    }
}
.md-sidebar-card {
    border: 1px solid #DBEBB9;
    border-radius: 16px;
    padding: 20px;
    background-color: #fff;
    margin-bottom: 24px;
}

    .md-sidebar-card h5 {
        font-family: 'Gotham Medium', 'Gotham', sans-serif;
        font-size: 18px;
        line-height: 26px;
        color: #002569;
        margin-bottom: 16px;
    }

        .md-sidebar-card h5 i {
            margin-right: 6px;
        }

.md-sidebar-list {
    list-style: none;
    padding: 0;
    margin: 0;
}

    .md-sidebar-list li {
        display: flex;
        align-items: flex-start;
        gap: 10px;
        margin-bottom: 12px;
        font-family: 'Gotham Book', 'Gotham', sans-serif;
        font-size: 14px;
        line-height: 20px;
        color: #434343;
    }

        .md-sidebar-list li:last-child {
            margin-bottom: 0;
        }

        .md-sidebar-list li i {
            color: #707070;
            font-size: 14px;
            margin-top: 3px;
            flex-shrink: 0;
        }

    .md-sidebar-list a {
        color: #296DC1;
        text-decoration: none;
    }

        .md-sidebar-list a:hover {
            text-decoration: underline;
        }

    .md-sidebar-list .si-desc {
        font-size: 13px;
        color: #707070;
    }

    .md-sidebar-list .empty-msg {
        color: #707070;
        font-size: 13px;
    }

        .md-sidebar-list .empty-msg i {
            color: #868F98;
        }

.md-view-all-btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: none;
    border: 2px solid #0053A5;
    border-radius: 8px;
    color: #0053A5;
    font-family: 'Gotham Book', 'Gotham', sans-serif;
    font-size: 14px;
    line-height: 22px;
    padding: 8px 20px;
    cursor: pointer;
    text-decoration: none;
    transition: background-color 0.2s, color 0.2s;
}

    .md-view-all-btn:hover {
        background-color: #0053A5;
        color: #fff;
        text-decoration: none;
    }

/* --- Person detail header --- */
.pd-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    flex-wrap: wrap;
    gap: 16px;
    margin-bottom: 24px;
}

    .pd-header h2 {
        font-family: 'Gotham Medium', 'Gotham', sans-serif;
        font-size: 28px;
        line-height: 36px;
        color: #002569;
        margin-bottom: 4px;
    }

    .pd-header .jobtitle {
        font-family: 'Gotham Book', 'Gotham', sans-serif;
        font-size: 16px;
        color: #707070;
        display: block;
        margin-bottom: 4px;
    }

    .pd-header .org-link {
        font-family: 'Gotham Book', 'Gotham', sans-serif;
        font-size: 18px;
        color: #296DC1;
        text-decoration: none;
    }

        .pd-header .org-link:hover {
            text-decoration: underline;
        }

.pd-save-btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: none;
    border: 2px solid #0053A5;
    border-radius: 8px;
    color: #0053A5;
    font-family: 'Gotham Book', 'Gotham', sans-serif;
    font-size: 16px;
    line-height: 24px;
    padding: 10px 24px;
    cursor: pointer;
    transition: background-color 0.2s, color 0.2s;
    white-space: nowrap;
}

    .pd-save-btn:hover {
        background-color: #0053A5;
        color: #fff;
    }

/* --- Info card --- */
.pd-info-card {
    border: 1px solid #DBEBB9;
    border-radius: 16px;
    padding: 24px;
    display: flex;
    flex-wrap: wrap;
    gap: 24px;
    margin-bottom: 32px;
    background: #fff;
}

    .pd-info-card .pd-info-col {
        flex: 1;
        min-width: 200px;
    }

    .pd-info-card ul {
        list-style: none;
        padding: 0;
        margin: 0;
    }

    .pd-info-card li {
        display: flex;
        align-items: flex-start;
        gap: 12px;
        font-family: 'Gotham Book', 'Gotham', sans-serif;
        font-size: 16px;
        line-height: 24px;
        color: #434343;
        margin-bottom: 12px;
    }

        .pd-info-card li:last-child {
            margin-bottom: 0;
        }

        .pd-info-card li i {
            color: #707070;
            font-size: 16px;
            margin-top: 4px;
            flex-shrink: 0;
        }

    .pd-info-card a {
        color: #296DC1;
        text-decoration: none;
    }

        .pd-info-card a:hover {
            text-decoration: underline;
        }

/* --- Email link --- */
.pd-email-link {
    color: #296DC1;
    text-decoration: underline;
    cursor: pointer;
    background: none;
    border: none;
    padding: 0;
    font-family: 'Gotham Book', 'Gotham', sans-serif;
    font-size: 16px;
}

    .pd-email-link:hover {
        color: #003d7a;
    }

/* --- Mobile responsive (widget-specific) --- */
@@media (max-width: 767.98px) {
    .pd-header {
        flex-direction: column;
    }

        .pd-header h2 {
            font-size: 22px;
            line-height: 30px;
        }

    .pd-info-card {
        flex-direction: column;
        gap: 16px;
        padding: 16px;
    }
}