/* Shared country and biography UI, independent of portrait/layout overrides. */
.ebm-page .ebm-flag-img,
.ebm-profile .ebm-flag-img {
    display: inline-block !important;
    width: 20px !important;
    height: 15px !important;
    max-width: none;
    object-fit: contain;
    vertical-align: -2px;
    margin: 0 5px 0 0;
}
.ebm-page .ebm-bio-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 5px;
    min-height: 32px;
    padding: 4px 9px;
    border: 1px solid #b8c8d8;
    border-radius: 5px;
    background: #f4f8fc;
    color: #173b60;
    font: 600 12px/1.3 system-ui, sans-serif;
    cursor: pointer;
    white-space: nowrap;
}
.ebm-page .ebm-bio-btn:hover { background: #e6eff8; border-color: #173b60; }
.ebm-page .ebm-bio-btn:focus-visible,
.ebm-bio-modal-close:focus-visible { outline: 3px solid #3b82b4; outline-offset: 3px; }
.ebm-page .ebm-bio-letter { display: none; }
.ebm-page .ebm-bio-btn .ebm-bio-icon { display: block; width: 16px; height: 16px; flex: 0 0 16px; }
.ebm-page .ebm-bio-btn .ebm-bio-text { display: inline; }
.ebm-row-links { align-items: center; gap: 8px; }
dialog.ebm-bio-modal {
    position: fixed;
    inset: 0;
    box-sizing: border-box;
    width: min(640px, calc(100% - 32px));
    max-width: calc(100% - 32px);
    max-height: calc(100dvh - 48px);
    margin: auto;
    padding: 0;
    border: 1px solid #d4dce5;
    border-radius: 12px;
    background: #fff;
    color: #253346;
    box-shadow: 0 16px 64px rgb(10 28 48 / 28%);
    overflow: auto;
    overscroll-behavior: contain;
}
dialog.ebm-bio-modal:not([open]) { display: none; }
dialog.ebm-bio-modal::backdrop { background: rgb(12 24 40 / 55%); }
.ebm-bio-modal-card { position: relative; padding: 32px; }
.ebm-bio-modal-close {
    position: absolute;
    top: 8px;
    right: 8px;
    display: grid;
    place-items: center;
    width: 44px;
    height: 44px;
    padding: 0;
    border: 0;
    border-radius: 6px;
    background: transparent;
    color: #445468;
    font: 28px/1 system-ui, sans-serif;
    cursor: pointer;
}
.ebm-bio-modal-close:hover { background: #edf2f7; }
.ebm-bio-modal-eyebrow { margin: 0 48px 10px 0; color: #526b86; font: 600 12px/1.4 system-ui, sans-serif; }
.ebm-bio-modal-name { margin: 0 24px 20px 0; color: #173b60; font: 600 22px/1.4 system-ui, sans-serif; }
.ebm-bio-modal-text { font: 15px/1.75 system-ui, sans-serif; overflow-wrap: anywhere; }
.ebm-bio-modal-text p { margin: 0 0 1em; }
.ebm-bio-modal-text p:last-child { margin-bottom: 0; }
@media (max-width: 600px) {
    .ebm-bio-modal-card { padding: 26px 22px; }
    .ebm-bio-modal-name { font-size: 19px; }
    .ebm-page .ebm-bio-btn { min-height: 40px; padding-inline: 11px; }
}
