/* ===== 扫一扫加好友 / 我的二维码名片 样式 ===== */

/* ---- 我的二维码名片（个人中心 - 账号设置） ---- */
.qrcode-card {
    display: inline-flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
    padding: 18px 24px;
    border: 1px solid #e2e8f0;
    border-radius: 12px;
    background: #fff;
}
.qrcode-img img { display: block; image-rendering: pixelated; }
.qrcode-nick { font-size: 16px; font-weight: 600; color: #2d3748; }
.qrcode-hint { font-size: 13px; color: #a0aec0; }

/* ---- 扫一扫浮层（好友页） ---- */
.fs-overlay {
    position: fixed;
    inset: 0;
    z-index: 4000;
    display: none;
    align-items: center;
    justify-content: center;
    background: rgba(0, 0, 0, .45);
}
.fs-overlay.show { display: flex; }
.fs-dialog {
    width: 340px;
    max-width: 92vw;
    background: #fff;
    border-radius: 14px;
    padding: 16px 18px 18px;
    box-shadow: 0 8px 30px rgba(0, 0, 0, .25);
}
.fs-head {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 16px;
    font-weight: 600;
    color: #2d3748;
    margin-bottom: 12px;
}
.fs-close {
    border: none;
    background: none;
    font-size: 22px;
    color: #a0aec0;
    cursor: pointer;
    line-height: 1;
}
.fs-close:hover { color: #4a5568; }
.fs-scan-region {
    width: 100%;
    min-height: 240px;
    border-radius: 10px;
    overflow: hidden;
    background: #1a202c;
}
.fs-scan-region video { width: 100%; }
.fs-fallback {
    padding: 28px 12px;
    text-align: center;
    font-size: 14px;
    color: #718096;
    line-height: 1.7;
}
.fs-status {
    margin-top: 10px;
    text-align: center;
    font-size: 13px;
    color: #a0aec0;
}
.fs-manual { display: flex; gap: 8px; margin-top: 12px; }
.fs-manual input {
    flex: 1;
    padding: 8px 12px;
    border: 1px solid #e2e8f0;
    border-radius: 8px;
    font-size: 14px;
}
.fs-manual button {
    padding: 8px 16px;
    background: #5a67d8;
    color: #fff;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    font-size: 14px;
    white-space: nowrap;
}
.fs-manual button:hover { background: #4c51bf; }

/* 轻提示（与 call-toast 同款） */
.fs-toast {
    position: fixed;
    top: 18px;
    left: 50%;
    transform: translateX(-50%);
    z-index: 5000;
    max-width: 80vw;
    padding: 10px 18px;
    border-radius: 8px;
    background: rgba(0, 0, 0, .78);
    color: #fff;
    font-size: 14px;
    opacity: 0;
    pointer-events: none;
    transition: opacity .2s;
}
.fs-toast.show { opacity: 1; }

/* 扫描线动画（微信/支付宝式）：绿色横线在识别区里上下游走。
 * 注意：该元素在摄像头启动后才由 JS 补进识别区（Html5Qrcode 初始化会清空容器），别依赖初始 DOM */
.fs-scan-region { position: relative; }
.fs-scan-line {
    position: absolute; left: 6%; right: 6%; top: 8%; height: 3px; z-index: 5;
    background: linear-gradient(90deg, transparent, #4ade80 20%, #22c55e 50%, #4ade80 80%, transparent);
    box-shadow: 0 0 12px 2px rgba(34,197,94,.85);
    border-radius: 2px; pointer-events: none;
    animation: fsScanWave 1.8s ease-in-out infinite;
}
@keyframes fsScanWave {
    0%, 100% { top: 8%; }
    50% { top: 90%; }
}
