/* المكالمات */
.call { position: fixed; inset: 0; z-index: 90; color: #fff; display: grid; place-items: center;
  background: radial-gradient(circle at 50% 30%, rgba(229,38,58,.55), #0a0a0d 65%); }
#remoteVideo { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; opacity: 0; pointer-events: none; }
.call.rvideo #remoteVideo { opacity: 1; }
.call-info { position: relative; text-align: center; display: grid; justify-items: center; gap: 6px; }
.call-info h2 { font-family: var(--display); font-size: 30px; margin: 16px 0 0; }
.call-info p { margin: 0; opacity: .85; font-variant-numeric: tabular-nums; }
#callAvatar .av { box-shadow: 0 0 0 8px rgba(255,255,255,.08), 0 0 0 18px rgba(229,38,58,.12), 0 0 60px var(--red-glow); }
.call.rvideo .call-info { position: absolute; top: calc(20px + env(safe-area-inset-top)); text-shadow: 0 1px 4px rgba(0,0,0,.6); }
.call.rvideo #callAvatar { display: none; }
.call.rvideo .call-info h2 { font-size: 20px; margin: 0; }
#localVideo { position: absolute; top: calc(16px + env(safe-area-inset-top)); left: 16px; width: 110px; aspect-ratio: 3 / 4; object-fit: cover; border-radius: 16px; border: 1px solid var(--edge-hi); box-shadow: var(--depth); display: none; background: #000; z-index: 2; }
#localVideo.mirror { transform: scaleX(-1); }
.call.lvideo #localVideo { display: block; }
/* الكاميرا الخلفية بس تبين لما الكاميرا شغّالة */
#btnFlip { display: none; }
.call.lvideo #btnFlip { display: grid; }
.call-actions { position: absolute; z-index: 3; bottom: calc(32px + env(safe-area-inset-bottom)); display: flex; gap: 14px; padding: 14px 22px; border-radius: 999px; background: rgba(255,255,255,.06); border: 1px solid var(--edge); backdrop-filter: blur(16px); -webkit-backdrop-filter: blur(16px); }
.round { width: 60px; height: 60px; border-radius: 50%; display: grid; place-items: center; color: #fff; background: linear-gradient(180deg, rgba(255,255,255,.22), rgba(255,255,255,.08)); border: 1px solid var(--edge); box-shadow: var(--depth-sm); }
.round.off { background: #fff; color: #111; }
.round.danger { background: linear-gradient(180deg, var(--red-hi), var(--red) 50%, var(--red-deep)); box-shadow: inset 0 1px 0 rgba(255,255,255,.4), 0 10px 24px -8px var(--red-glow); }
.round.danger svg { transform: rotate(135deg); }
.round.ok { background: linear-gradient(180deg, #4BE3A0, #1E9E62); }
.incoming { position: fixed; z-index: 95; top: calc(14px + env(safe-area-inset-top)); inset-inline: 0; margin: auto; width: min(420px, 100% - 24px); padding: 12px 14px; display: flex; align-items: center; gap: 12px; border-radius: 24px; animation: pop .2s ease-out; }
.in-text { flex: 1; display: grid; min-width: 0; }
.in-text small { color: var(--muted); }
.incoming .round { width: 48px; height: 48px; }
.incoming .round.ok svg { animation: shake 1s infinite; }
@keyframes shake { 0%, 50%, 100% { transform: rotate(0); } 10%, 30% { transform: rotate(-14deg); } 20%, 40% { transform: rotate(14deg); } }
.round.on { background: linear-gradient(180deg, #fff, #d9d9e0); color: #111; }
