.be-doctor-shell {
    width: min(1180px, calc(100% - 48px));
    margin: 0 auto;
    padding: 46px 0 88px;
    color: #11151c;
}

body.single-doctor .be-doctor-shell {
    width: min(1400px, calc(100% - 48px));
}

.be-doctor-profile {
    position: relative;
}

.be-doctor-back {
    display: none;
}

.be-doctor-hero {
    display: grid;
    grid-template-columns: 248px minmax(0, 1fr);
    gap: 42px;
    align-items: center;
    min-height: 284px;
    padding: 30px 0 38px;
    border-bottom: 1px solid #dfe6f0;
}

.be-doctor-photo {
    display: grid;
    width: 248px;
    aspect-ratio: 1;
    place-items: center;
    overflow: hidden;
    border: 1px solid #dfe6f0;
    border-radius: 8px;
    background: #eaf1fc;
}

.be-doctor-photo img,
.be-doctor-card-photo img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center top;
}

.be-doctor-photo.has-initials span {
    color: #2f6df6;
    font-size: 64px;
    font-weight: 700;
}

.be-doctor-eyebrow {
    margin: 0 0 12px;
    color: #2f6df6;
    font-size: 13px;
    font-weight: 700;
    letter-spacing: 0;
    text-transform: uppercase;
}

.be-doctor-hero h1,
.be-doctor-directory-header h1 {
    margin: 0;
    font-size: 55px;
    line-height: 1.06;
    letter-spacing: 0;
}

.be-doctor-role {
    margin: 16px 0 0;
    color: #303744;
    font-size: 20px;
    font-weight: 600;
    line-height: 1.45;
}

.be-doctor-location {
    margin: 8px 0 0;
    color: #687382;
    font-size: 16px;
}

.be-doctor-affiliation {
    margin: 18px 0 0;
    color: #687382;
    font-size: 16px;
}

.be-doctor-affiliation a {
    color: #2f6df6;
    font-weight: 700;
    text-underline-offset: 3px;
}

.be-doctor-tabs {
    display: flex;
    gap: 10px;
    overflow-x: auto;
    padding: 18px 0;
    border-bottom: 1px solid #dfe6f0;
    scrollbar-width: none;
}

.be-doctor-tabs::-webkit-scrollbar {
    display: none;
}

.be-doctor-tabs a {
    flex: 0 0 auto;
    padding: 10px 18px;
    border: 1px solid #dfe6f0;
    border-radius: 999px;
    color: #5f6878;
    font-size: 15px;
    font-weight: 700;
    text-decoration: none;
}

.be-doctor-tabs a:first-child {
    border-color: #11151c;
    background: #11151c;
    color: #fff;
}

.be-doctor-layout {
    display: grid;
    grid-template-columns: minmax(0, 820px) 360px;
    gap: 40px;
    justify-content: space-between;
    align-items: start;
    padding-top: 42px;
}

.be-doctor-main {
    min-width: 0;
}

.be-doctor-sidebar {
    position: sticky;
    top: 28px;
    display: grid;
    gap: 22px;
}

.be-doctor-section {
    scroll-margin-top: 24px;
    padding: 0 0 42px;
}

.be-doctor-section + .be-doctor-section {
    padding-top: 42px;
    border-top: 1px solid #dfe6f0;
}

.be-doctor-section-label {
    margin: 0 0 9px !important;
    color: #2f6df6 !important;
    font-size: 12px !important;
    font-weight: 700;
    line-height: 1.4 !important;
    text-transform: uppercase;
}

.be-doctor-section h2 {
    margin: 0 0 20px;
    font-size: 32px;
    line-height: 1.18;
    letter-spacing: 0;
}

.be-doctor-section h3 {
    margin: 0 0 10px;
    font-size: 18px;
    line-height: 1.3;
    letter-spacing: 0;
}

.be-doctor-rich-text,
.be-doctor-preserved-text,
.be-doctor-section p {
    color: #4f5969;
    font-size: 17px;
    line-height: 1.72;
}

.be-doctor-rich-text > :first-child,
.be-doctor-preserved-text > :first-child {
    margin-top: 0;
}

.be-doctor-rich-text > :last-child,
.be-doctor-preserved-text > :last-child {
    margin-bottom: 0;
}

.be-doctor-focus-list {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 12px;
    margin: 0;
    padding: 0;
    list-style: none;
}

.be-doctor-focus-list li {
    position: relative;
    min-height: 52px;
    padding: 14px 16px 14px 42px;
    border: 1px solid #dfe6f0;
    border-radius: 8px;
    color: #303744;
    font-size: 15px;
    font-weight: 600;
    line-height: 1.45;
}

.be-doctor-focus-list li::before {
    position: absolute;
    top: 18px;
    left: 18px;
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: #2f6df6;
    content: "";
}

.be-doctor-credentials {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 32px;
}

.be-doctor-credentials ul {
    margin: 0;
    padding-left: 20px;
}

.be-doctor-credentials li {
    margin: 0 0 10px;
    color: #4f5969;
    font-size: 16px;
    line-height: 1.6;
}

.be-doctor-appointment,
.be-doctor-profile-details {
    padding: 26px;
    border: 1px solid #dfe6f0;
    border-radius: 8px;
    background: #fff;
    box-shadow: 0 18px 44px rgb(38 55 84 / 8%);
}

.be-doctor-appointment-status {
    display: flex;
    align-items: center;
    gap: 10px;
    margin: 0 0 14px;
    color: #11151c;
    font-size: 15px;
    font-weight: 700;
}

.be-doctor-appointment-status span {
    width: 11px;
    height: 11px;
    border-radius: 50%;
    background: #4cc88a;
    box-shadow: 0 0 0 4px #e2f7ec;
}

.be-doctor-appointment h2,
.be-doctor-profile-details h2 {
    margin: 0 0 12px;
    font-size: 22px;
    line-height: 1.25;
}

.be-doctor-appointment > p:not(.be-doctor-appointment-status),
.be-doctor-profile-details p {
    margin: 0;
    color: #687382;
    font-size: 15px;
    line-height: 1.6;
}

.be-doctor-primary-action,
.be-doctor-sticky-action a {
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 52px;
    border-radius: 8px;
    background: #2f6df6;
    color: #fff;
    font-weight: 700;
    text-align: center;
    text-decoration: none;
}

.be-doctor-primary-action {
    margin-top: 22px;
}

.be-doctor-profile-details > div + a,
.be-doctor-profile-details > a {
    display: inline-block;
    margin-top: 18px;
    color: #2f6df6;
    font-weight: 700;
    text-underline-offset: 3px;
}

.be-doctor-profile-details h3 {
    margin: 0 0 5px;
    font-size: 14px;
    text-transform: uppercase;
}

.be-doctor-clinic h3 a,
.be-doctor-card h2 a {
    color: #11141b;
    text-decoration: none;
}

.be-doctor-clinic-list {
    display: grid;
    gap: 16px;
}

.be-doctor-clinic {
    display: grid;
    grid-template-columns: 112px minmax(0, 1fr);
    gap: 20px;
    align-items: center;
    padding: 18px;
    border: 1px solid #dfe6f0;
    border-radius: 8px;
}

.be-doctor-clinic > .be-clinic-thumb {
    display: grid;
    width: 112px;
    height: 96px;
    place-items: center;
    overflow: hidden;
    border-radius: 7px;
    background: #eef3fb;
}

.be-doctor-clinic > .be-clinic-thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.be-doctor-clinic > .be-clinic-thumb.is-logo img {
    width: 84%;
    height: 84%;
    object-fit: contain;
}

.be-doctor-clinic-rating {
    display: flex;
    gap: 9px;
    align-items: center;
    margin: 0 0 6px !important;
    font-size: 14px !important;
    line-height: 1.4 !important;
}

.be-doctor-clinic-rating strong {
    color: #11151c;
}

.be-doctor-clinic-rating span {
    color: #687382;
    text-decoration: underline;
    text-underline-offset: 3px;
}

.be-doctor-clinic h3 {
    margin: 0 0 5px;
    font-size: 20px;
}

.be-doctor-clinic p {
    margin: 0 0 10px;
    font-size: 15px;
    line-height: 1.5;
}

.be-doctor-clinic-type {
    display: inline-flex;
    padding: 6px 10px;
    border-radius: 6px;
    background: #eaf1ff;
    color: #215fdc;
    font-size: 13px;
    font-weight: 700;
}

.be-doctor-sticky-action {
    display: none;
}

.be-doctor-directory-header {
    max-width: 820px;
    margin-bottom: 48px;
}

.be-doctor-directory-header > p:last-of-type {
    margin: 20px 0 0;
    color: #596273;
    font-size: 19px;
    line-height: 1.6;
}

.be-doctor-directory-header nav {
    display: flex;
    gap: 10px;
    margin-top: 28px;
}

.be-doctor-directory-header nav a {
    padding: 10px 16px;
    border: 1px solid #d8e1ee;
    border-radius: 8px;
    color: #303744;
    font-weight: 700;
    text-decoration: none;
}

.be-doctor-directory-header nav a.is-active {
    border-color: #316df4;
    background: #316df4;
    color: #fff;
}

.be-doctor-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 20px;
}

.be-doctor-card {
    min-height: 190px;
    padding: 20px;
    border: 1px solid #dfe5ef;
    border-radius: 8px;
    background: #fff;
}

.be-doctor-card.has-photo {
    display: grid;
    grid-template-columns: 148px minmax(0, 1fr);
    gap: 22px;
}

.be-doctor-card-photo {
    display: block;
    width: 148px;
    height: 148px;
    overflow: hidden;
    border-radius: 8px;
    background: #edf3fc;
}

.be-doctor-card h2 {
    margin: 4px 0 8px;
    font-size: 22px;
    line-height: 1.25;
    letter-spacing: 0;
}

.be-doctor-card-role,
.be-doctor-card-location {
    margin: 0 0 8px;
    color: #697385;
    font-size: 15px;
    line-height: 1.45;
}

.be-doctor-pagination {
    margin-top: 40px;
}

.be-doctor-empty {
    padding: 32px;
    border: 1px solid #dfe5ef;
    border-radius: 8px;
    background: #fff;
}

.be-doctor-empty h2 {
    margin: 0 0 10px;
    font-size: 26px;
}

.be-doctor-empty p {
    margin: 0;
    color: #596273;
    font-size: 17px;
    line-height: 1.6;
}

.be-doctor-pagination .page-numbers {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    padding: 0;
    list-style: none;
}

.be-doctor-pagination a,
.be-doctor-pagination span {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 42px;
    min-height: 42px;
    padding: 0 13px;
    border: 1px solid #d8e1ee;
    border-radius: 8px;
    color: #11141b;
    text-decoration: none;
}

.be-doctor-pagination .current {
    border-color: #316df4;
    background: #316df4;
    color: #fff;
}

@media (max-width: 900px) {
    .be-doctor-layout {
        grid-template-columns: 1fr;
    }

    .be-doctor-sidebar {
        position: static;
        grid-row: auto;
    }

    .be-doctor-grid {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 640px) {
    .be-doctor-shell {
        width: min(100% - 32px, 1180px);
        padding: 0 0 52px;
    }

    body.single-doctor .be-doctor-shell {
        width: 100%;
    }

    .be-doctor-profile {
        padding-bottom: 24px;
    }

    .be-doctor-back {
        position: fixed;
        z-index: 10004;
        top: 7px;
        left: 4px;
        display: grid;
        width: 42px;
        height: 42px;
        margin: 0;
        padding: 0;
        place-items: center;
        border: 1px solid #dfe6f0;
        border-radius: 8px;
        background: #fff;
        color: #11151c;
        font-size: 23px;
        cursor: pointer;
    }

    body.admin-bar .be-doctor-back {
        top: 52px;
    }

    body.single-doctor .be-site-header .be-site-brand {
        min-width: 0;
        max-width: calc(100vw - 240px);
        margin-left: 54px;
        overflow: hidden;
    }

    body.single-doctor .be-site-header .wp-block-site-logo {
        min-width: 0;
        overflow: hidden;
    }

    body.single-doctor .be-site-header .wp-block-site-logo img {
        max-width: min(132px, calc(100vw - 248px));
    }

    .be-doctor-back:focus-visible,
    .be-doctor-tabs a:focus-visible,
    .be-doctor-primary-action:focus-visible,
    .be-doctor-sticky-action a:focus-visible {
        outline: 2px solid #2f6df6;
        outline-offset: 2px;
    }

    .be-doctor-hero {
        grid-template-columns: 132px minmax(0, 1fr);
        gap: 18px;
        min-height: 0;
        padding: 18px 16px 28px;
    }

    .be-doctor-photo {
        width: 132px;
    }

    .be-doctor-photo.has-initials span {
        font-size: 40px;
    }

    .be-doctor-hero h1,
    .be-doctor-directory-header h1 {
        font-size: 32px;
        line-height: 1.08;
    }

    .be-doctor-eyebrow {
        margin-bottom: 8px;
        font-size: 11px;
    }

    .be-doctor-role {
        margin-top: 10px;
        font-size: 16px;
    }

    .be-doctor-location,
    .be-doctor-affiliation {
        font-size: 14px;
    }

    .be-doctor-affiliation {
        margin-top: 10px;
    }

    .be-doctor-tabs {
        padding: 12px 16px;
    }

    .be-doctor-tabs a {
        padding: 8px 14px;
        font-size: 14px;
    }

    .be-doctor-layout {
        gap: 24px;
        padding: 30px 16px 0;
    }

    .be-doctor-sidebar {
        display: contents;
    }

    .be-doctor-appointment {
        grid-row: 1;
    }

    .be-doctor-main {
        grid-row: 2;
    }

    .be-doctor-profile-details {
        grid-row: 3;
    }

    .be-doctor-section {
        padding: 0 0 30px;
    }

    .be-doctor-section + .be-doctor-section {
        padding-top: 30px;
    }

    .be-doctor-section h2 {
        font-size: 27px;
    }

    .be-doctor-focus-list,
    .be-doctor-credentials {
        grid-template-columns: 1fr;
    }

    .be-doctor-credentials {
        gap: 26px;
    }

    .be-doctor-primary-action {
        width: 100%;
    }

    .be-doctor-appointment,
    .be-doctor-profile-details {
        padding: 22px;
    }

    .be-doctor-clinic {
        grid-template-columns: 84px minmax(0, 1fr);
        gap: 14px;
        padding: 14px;
    }

    .be-doctor-clinic > .be-clinic-thumb {
        width: 84px;
        height: 84px;
    }

    .be-doctor-clinic h3 {
        font-size: 18px;
    }

    .be-doctor-clinic-rating {
        align-items: flex-start;
        flex-direction: column;
        gap: 2px;
    }

    .be-doctor-sticky-action {
        position: fixed;
        z-index: 80;
        right: 0;
        bottom: 0;
        left: 0;
        display: block;
        padding: 10px 16px max(10px, env(safe-area-inset-bottom));
        border-top: 1px solid #dfe6f0;
        background: rgb(255 255 255 / 96%);
        opacity: 0;
        pointer-events: none;
        transform: translateY(100%);
        transition: opacity 180ms ease, transform 180ms ease;
    }

    .be-doctor-sticky-action.is-visible {
        opacity: 1;
        pointer-events: auto;
        transform: translateY(0);
    }

    .be-doctor-sticky-action a {
        min-height: 48px;
    }

    .be-doctor-card {
        grid-template-columns: 96px minmax(0, 1fr);
        gap: 16px;
        min-height: 136px;
        padding: 16px;
    }

    .be-doctor-card-photo {
        width: 96px;
        height: 112px;
    }

    .be-doctor-card h2 {
        font-size: 19px;
    }
}

@media (max-width: 420px) {
    body.single-doctor .be-site-header .be-site-brand {
        max-width: calc(100vw - 220px);
        margin-left: 42px;
    }

    body.single-doctor .be-site-header .wp-block-site-logo img {
        max-width: min(96px, calc(100vw - 222px));
    }

    .be-doctor-hero {
        grid-template-columns: 104px minmax(0, 1fr);
        gap: 14px;
    }

    .be-doctor-photo {
        width: 104px;
    }

    .be-doctor-hero h1 {
        font-size: 28px;
    }
}
