.fbm-overlay {
    --fbm-bg: #141414; --fbm-text: #e5e5e5; --fbm-dim: #a0a0a6;
    --fbm-soft: #29292c; --fbm-line: #2b2b2e;
    position: fixed; inset: 0; z-index: 10060;
    display: flex; align-items: center; justify-content: center; padding: 24px;
    background: rgba(0,0,0,.38); backdrop-filter: blur(6px); -webkit-backdrop-filter: blur(6px);
    color: var(--fbm-text); font-family: -apple-system,BlinkMacSystemFont,"Segoe UI",sans-serif;
    opacity: 0; transition: opacity .2s ease;
}
.fbm-overlay[data-theme="light"] {
    --fbm-bg: #fff; --fbm-text: #1c1c1e; --fbm-dim: #74747a;
    --fbm-soft: #f0f0f3; --fbm-line: #eeeef1; background: rgba(22,23,28,.28);
}
.fbm-overlay.is-open { opacity: 1; }
.fbm-overlay * { box-sizing: border-box; }
.fbm-sheet {
    width: 420px; max-width: 100%; max-height: 90dvh; overflow: auto;
    border-radius: 28px; background: var(--fbm-bg); color: var(--fbm-text);
    box-shadow: 0 28px 90px rgba(0,0,0,.22); transform: scale(.96);
    transition: transform .26s cubic-bezier(.32,.72,0,1); overscroll-behavior: contain;
}
.fbm-overlay.is-open .fbm-sheet { transform: none; }
.fbm-sheet:focus { outline: none; }
.fbm-head { display: flex; align-items: center; justify-content: space-between; padding: 16px 16px 0 26px; }
.fbm-brand { font-size: 19px; font-weight: 700; letter-spacing: -1px; }
.fbm-overlay button { font-family: inherit; border: 0; cursor: pointer; -webkit-tap-highlight-color: transparent; }
.fbm-overlay button:focus-visible { outline: 3px solid #007aff; outline-offset: 3px; }
.fbm-overlay button:disabled { cursor: default; opacity: .6; }
.fbm-close { width: 44px; height: 44px; padding: 6px; display: grid; place-items: center; background: transparent; color: var(--fbm-dim); flex: 0 0 auto; }
.fbm-close .fbm-icon { width: 32px; height: 32px; padding: 8px; border-radius: 50%; background: var(--fbm-soft); }
.fbm-icon { display: inline-flex; flex: 0 0 auto; width: 20px; height: 20px; }
.fbm-icon svg { width: 100%; height: 100%; }
.fbm-content { padding: 16px 30px 0; text-align: center; }
.fbm-avatar { position: relative; width: 90px; height: 90px; border-radius: 50%; margin: 0 auto 22px; overflow: hidden; display: grid; place-items: center; background: var(--fbm-soft); font-size: 30px; color: var(--fbm-dim); }
.fbm-avatar img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.fbm-title { font-size: 25px; line-height: 1.2; letter-spacing: -.7px; font-weight: 650; margin: 0 0 8px; overflow-wrap: anywhere; }
.fbm-username { color: var(--fbm-dim); font-size: 15px; overflow-wrap: anywhere; }
.fbm-description { color: var(--fbm-dim); font-size: 15px; line-height: 1.55; margin: 21px auto 25px; max-width: 310px; }
.fbm-error { font-size: 14px; line-height: 1.4; color: #f26969; margin: 0 0 16px; }
.fbm-overlay[data-theme="light"] .fbm-error { color: #b42318; }
.fbm-actions { display: flex; flex-direction: column; gap: 5px; }
.fbm-follow { min-height: 50px; border-radius: 13px; padding: 12px 16px; background: #007aff; color: #fff; font-size: 16px; font-weight: 600; display: flex; align-items: center; justify-content: center; gap: 9px; }
.fbm-follow:hover:not(:disabled) { background: #006fea; }
.fbm-cancel { min-height: 44px; border-radius: 13px; padding: 10px 16px; background: transparent; color: var(--fbm-dim); font-size: 15px; }
.fbm-cancel:hover:not(:disabled) { background: var(--fbm-soft); }
.fbm-attribution { margin-top: 18px; padding: 17px 24px 22px; border-top: 1px solid var(--fbm-line); display: flex; justify-content: center; align-items: center; gap: 8px; color: var(--fbm-dim); font-size: 12px; line-height: 1.4; text-align: center; overflow-wrap: anywhere; }
.fbm-attribution .fbm-icon { width: 19px; height: 19px; padding: 3px; border-radius: 5px; background: var(--fbm-soft); }
.fbm-attribution strong { font-weight: 700; }
.fbm-drag { display: none; }
@media(max-width:767px) {
    .fbm-overlay { align-items: flex-end; padding: 0; }
    .fbm-sheet { width: 100%; max-width: 640px; max-height: 94dvh; border-radius: 26px 26px 0 0; transform: translateY(32px); }
    .fbm-drag { display: flex; height: 25px; justify-content: center; padding-top: 10px; touch-action: none; cursor: grab; }
    .fbm-drag span { width: 38px; height: 5px; border-radius: 4px; background: var(--fbm-dim); opacity: .45; }
    .fbm-head { padding-top: 0; }
    .fbm-content { padding: 10px 24px 0; }
    .fbm-avatar { width: 84px; height: 84px; margin-bottom: 21px; }
    .fbm-title { font-size: 24px; }
    .fbm-description { margin: 19px auto 24px; max-width: 290px; }
    .fbm-follow { min-height: 52px; border-radius: 14px; }
    .fbm-attribution { margin-top: 14px; padding-bottom: calc(24px + env(safe-area-inset-bottom,0px)); }
}
@media(prefers-reduced-motion:reduce) { .fbm-overlay,.fbm-sheet { transition: none; } }
