/* ════════════════════════════════════════════════════════════════════════════
   FINGERPRINT — أنماط الموديول (Gate Modals + My Devices Card)
   ────────────────────────────────────────────────────────────────────────────
   مستقل بالكامل — لا يلمس main.css ولا أي class من الواجهة الحالية.
   يعمل مع كل الثيمات (dark/light/blue/pink) عبر متغيّرات CSS الأصلية.
   الإزالة: احذف هذا الملف + سطر <link> في index.html.
   ════════════════════════════════════════════════════════════════════════════ */

/* ── جذر النافذة (overlay فوق كل شيء، فوق الـ bottom-nav) ── */
.fp-gate-root{
  position:fixed;
  inset:0;
  z-index: 9999;
  display:none;
  align-items:center;
  justify-content:center;
  pointer-events:none;
}
.fp-gate-root.is-open{ display:flex; pointer-events:auto; }

.fp-gate-backdrop{
  position:absolute;
  inset:0;
  background: rgba(0,0,0,0.62);
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
  animation: fpFadeIn .18s ease both;
}

.fp-gate-modal{
  position:relative;
  width: min(440px, 92vw);
  max-height: 92vh;
  overflow-y:auto;
  border-radius: 18px;
  background: var(--bg-card, #0e1726);
  color: var(--text-primary, #fff);
  box-shadow: 0 24px 60px rgba(0,0,0,.45), 0 6px 18px rgba(0,0,0,.25);
  border: 1px solid var(--border-color, rgba(255,255,255,.08));
  animation: fpPopIn .22s cubic-bezier(.16,1,.3,1) both;
  direction: rtl;
}

.fp-gate-card{
  padding: 26px 22px 22px;
  text-align: center;
}
.fp-gate-card-compact{ padding: 22px 18px 18px; }

.fp-gate-illust{
  width: 78px; height: 78px;
  margin: 0 auto 14px;
  border-radius: 50%;
  display:flex; align-items:center; justify-content:center;
  font-size: 2rem;
}
.fp-illust-shield{ background: rgba(0,180,216,.12); color: var(--primary, #00b4d8); }
.fp-illust-hour  { background: rgba(245,158,11,.14); color: #f59e0b; }
.fp-illust-info  { background: rgba(148,163,184,.14); color: #94a3b8; }
.fp-illust-stop  { background: rgba(239,68,68,.14);  color: #ef4444; }

.fp-gate-title{
  font-size: 1.15rem;
  font-weight: 800;
  margin: 0 0 8px;
  line-height: 1.4;
}
.fp-gate-desc{
  color: var(--text-secondary, #94a3b8);
  line-height: 1.75;
  font-size: .94rem;
  margin: 0 0 8px;
}
.fp-gate-desc.fp-gate-sub{
  color: var(--text-muted, #64748b);
  font-size: .85rem;
}

.fp-gate-actions{
  display:flex;
  flex-direction: column;
  gap: 9px;
  margin-top: 18px;
}
.fp-gate-extra{
  margin-top: 10px;
  display:flex;
  flex-direction: column;
  gap: 9px;
}
.fp-gate-extra:empty{ display:none; }
.fp-gate-foot{
  margin-top: 16px;
  padding-top: 12px;
  border-top: 1px solid var(--border-color, rgba(255,255,255,.06));
}

/* ── أزرار النافذة ── */
.fp-btn{
  display:inline-flex; align-items:center; justify-content:center; gap: 8px;
  padding: 13px 16px;
  border-radius: 12px;
  border: 1px solid transparent;
  font-family: inherit;
  font-size: .94rem;
  font-weight: 700;
  cursor: pointer;
  text-decoration: none;
  transition: transform .12s ease, background .15s ease, border-color .15s ease, opacity .15s ease;
  line-height: 1;
}
.fp-btn:active{ transform: translateY(1px); }
.fp-btn:disabled{ opacity: .65; cursor: progress; }

.fp-btn-primary{
  background: var(--primary, #00b4d8);
  color: #fff;
}
.fp-btn-primary:hover{ background: var(--primary, #00b4d8); filter: brightness(1.08); }

.fp-btn-ghost{
  background: transparent;
  color: var(--text-primary, #e2e8f0);
  border-color: var(--border-color, rgba(255,255,255,.14));
}
.fp-btn-ghost:hover{
  background: var(--bg-input, rgba(255,255,255,.04));
}

/* ── My Devices Card (داخل صفحة profile) ── */
.fp-mydev-host{ margin: 12px 0 18px; }
.fp-mydev-card{
  border-radius: 14px;
  background: var(--bg-card, #0e1726);
  border: 1px solid var(--border-color, rgba(255,255,255,.08));
  padding: 16px 14px 12px;
  direction: rtl;
}
.fp-mydev-head{
  display:flex; align-items:center; gap: 8px;
  margin-bottom: 10px;
}
.fp-mydev-head i{
  color: var(--primary, #00b4d8);
  font-size: 1.1rem;
}
.fp-mydev-head h4{
  margin: 0;
  font-size: 1rem;
  font-weight: 800;
}
.fp-mydev-row{
  display:flex; align-items:center; justify-content: space-between;
  padding: 8px 0;
  border-bottom: 1px dashed var(--border-color, rgba(255,255,255,.06));
  font-size: .92rem;
}
.fp-mydev-row:last-of-type{ border-bottom: none; }
.fp-mydev-sub{ font-size: .85rem; color: var(--text-muted, #64748b); }
.fp-mydev-label{ color: var(--text-secondary, #94a3b8); }

.fp-status{
  display:inline-flex; align-items:center;
  padding: 4px 10px;
  border-radius: 999px;
  font-weight: 700;
  font-size: .82rem;
}
.fp-status small{ opacity: .75; margin-right: 5px; font-weight: 500; }
.fp-status-ok  { background: rgba(34,197,94,.12);  color: #22c55e; }
.fp-status-wait{ background: rgba(245,158,11,.14); color: #f59e0b; }
.fp-status-bad { background: rgba(239,68,68,.12);  color: #ef4444; }

.fp-mydev-actions{
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
  margin-top: 12px;
}
.fp-mydev-actions .fp-btn{ font-size: .82rem; padding: 10px 8px; }
.fp-mydev-actions .fp-btn:last-child{ grid-column: 1 / -1; }

.fp-mydev-note{
  margin-top: 10px;
  font-size: .76rem;
  color: var(--text-muted, #64748b);
  text-align: center;
  line-height: 1.6;
}

/* ── animations ── */
@keyframes fpFadeIn {
  from { opacity: 0; }
  to   { opacity: 1; }
}
@keyframes fpPopIn {
  from { opacity: 0; transform: translateY(8px) scale(.97); }
  to   { opacity: 1; transform: translateY(0) scale(1); }
}

/* ── responsive ── */
@media (max-width: 380px){
  .fp-gate-card{ padding: 22px 16px 18px; }
  .fp-gate-title{ font-size: 1.05rem; }
  .fp-mydev-actions{ grid-template-columns: 1fr; }
  .fp-mydev-actions .fp-btn:last-child{ grid-column: auto; }
}
