/* =============================================
   Location Snap — ملخص المكان في Popup الخبر
   ============================================= */

.wm-pc-loc-snap {
    border-bottom: 1px solid rgba(0, 212, 255, 0.12);
    background: rgba(0, 20, 40, 0.6);
    border-radius: 6px 6px 0 0;
    overflow: hidden;
}

/* حالة التحميل */
.wm-pc-loc-loading {
    padding: 8px 12px;
    font-size: 10px;
    color: #3a5a76;
    display: flex;
    align-items: center;
    gap: 5px;
}
.wm-pc-loc-dot {
    width: 5px;
    height: 5px;
    border-radius: 50%;
    background: #00d4ff;
    display: inline-block;
    animation: wm-loc-pulse 1.2s ease-in-out infinite;
    flex-shrink: 0;
}
@keyframes wm-loc-pulse {
    0%, 100% { opacity: 0.3; transform: scale(0.8); }
    50%       { opacity: 1;   transform: scale(1.2); }
}

/* المحتوى بعد التحميل */
.wm-pc-loc-inner {
    display: flex;
    gap: 0;
    align-items: stretch;
}
.wm-pc-loc-img {
    width: 70px;
    height: 70px;
    object-fit: cover;
    flex-shrink: 0;
    display: block;
}
.wm-pc-loc-info {
    padding: 7px 10px;
    flex: 1;
    min-width: 0;
    display: flex;
    flex-direction: column;
    justify-content: center;
    gap: 3px;
}
.wm-pc-loc-name {
    font-size: 11px;
    font-weight: 600;
    color: #00d4ff;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}
.wm-pc-loc-text {
    font-size: 10px;
    color: #7a9ab0;
    line-height: 1.5;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

/* =============================================
   Aircraft Layer — طبقة تتبع الطائرات
   ============================================= */

/* أيقونة الطائرة على الخريطة */
.wm-aircraft-icon {
    background: transparent !important;
    border: none !important;
    display: flex;
    align-items: center;
    justify-content: center;
}
.wm-aircraft-svg {
    filter: drop-shadow(0 0 3px rgba(0,0,0,0.8));
    transition: transform 0.3s ease;
}
.wm-aircraft-svg:hover {
    filter: drop-shadow(0 0 6px rgba(0,212,255,0.9));
}

/* طائرات الطوارئ */
.wm-aircraft-emergency .wm-aircraft-svg {
    animation: wm-aircraft-blink 0.6s ease-in-out infinite;
}
@keyframes wm-aircraft-blink {
    0%, 100% { opacity: 1; }
    50%       { opacity: 0.3; }
}

/* Popup الطائرة */
.wm-aircraft-popup {
    direction: rtl;
    font-family: var(--wm-font-ar, sans-serif);
    min-width: 200px;
}
.wm-ap-callsign {
    font-size: 15px;
    font-weight: 700;
    color: #00d4ff;
    margin-bottom: 6px;
    letter-spacing: 1px;
    direction: ltr;
    text-align: center;
}
.wm-ap-type {
    font-size: 10px;
    color: #5a7a96;
    text-align: center;
    margin-bottom: 8px;
    letter-spacing: 0.5px;
}
.wm-ap-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 4px 0;
    border-bottom: 1px solid rgba(30,58,90,0.5);
    font-size: 12px;
}
.wm-ap-row:last-child { border-bottom: none; }
.wm-ap-label { color: #5a7a96; }
.wm-ap-val   { color: #c8dff0; font-weight: 500; direction: ltr; }
.wm-ap-emergency {
    background: rgba(239,68,68,0.15);
    border: 1px solid var(--wm-red);
    border-radius: 4px;
    padding: 4px 8px;
    font-size: 11px;
    font-weight: 700;
    color: var(--wm-red);
    text-align: center;
    margin-bottom: 6px;
    animation: wm-aircraft-blink 0.8s ease-in-out infinite;
}
.wm-ap-mil {
    background: rgba(234,179,8,0.15);
    border: 1px solid var(--wm-yellow);
    border-radius: 4px;
    padding: 2px 6px;
    font-size: 10px;
    color: var(--wm-yellow);
    display: inline-block;
    margin-bottom: 6px;
}

/* عداد الطائرات في HUD */
.wm-threat.aircraftcount span { color: #00d4ff; }

/* =============================================
   Aircraft Overlay — نافذة تتبع الطائرات
   ============================================= */

#wm-aircraft-overlay {
    display: none;
    position: absolute;
    inset: 0;
    /* ⚠️ 950 — يتجاوز #wm-topbar و#wm-layer-dock (z-index:900 كلاهما) عمداً.
       كانا يبقيان مرئيين وقابلين للنقر فوق اللوحة كاملة الشاشة قبل هذا
       الإصلاح (رُصد بقراءة CSS لا اختباراً حياً — تحقّق بعد الرفع) */
    z-index: 950;
    flex-direction: column;
    background: #060c14;
    font-family: var(--wm-font-ar, sans-serif);
    direction: ltr;
}
#wm-aircraft-overlay.active { display: flex; }

/* ── شريط التحكم العلوي ── */
#wm-ac-bar {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 0 12px;
    height: 44px;
    direction: rtl;
    background: #0a1520;
    border-bottom: 1px solid #1e3a5a;
    flex-shrink: 0;
}
#wm-ac-bar-logo {
    font-size: 13px;
    font-weight: 700;
    color: #00d4ff;
    letter-spacing: 0.5px;
    white-space: nowrap;
    display: flex;
    align-items: center;
    gap: 5px;
}
#wm-ac-bar-logo .wm-ac-live-dot {
    width: 7px; height: 7px;
    border-radius: 50%;
    background: var(--wm-green);
    animation: wm-ac-pulse 1.4s ease-in-out infinite;
}
@keyframes wm-ac-pulse {
    0%,100% { opacity:1; transform:scale(1); }
    50%      { opacity:0.4; transform:scale(0.7); }
}
.wm-ac-sep { width:1px; height:22px; background:#1e3a5a; flex-shrink:0; }
#wm-ac-counter { font-size:11px; color:#5a7a96; white-space:nowrap; }
#wm-ac-counter strong { color:#00d4ff; font-size:13px; }
#wm-ac-updated { font-size:10px; color:#3a5a76; }
#wm-ac-region-sel {
    padding: 3px 7px;
    background: #0d1a2a;
    border: 1px solid #1e3a5a;
    border-radius: 4px;
    color: #c8dff0;
    font-size: 11px;
    cursor: pointer;
}
.wm-ac-btn {
    padding: 3px 9px;
    background: transparent;
    border: 1px solid #1e3a5a;
    border-radius: 4px;
    color: #5a7a96;
    font-size: 11px;
    cursor: pointer;
    transition: all 0.15s;
    white-space: nowrap;
}
.wm-ac-btn:hover { border-color:#00d4ff44; color:#c8dff0; }
#wm-ac-close-btn {
    margin-right: auto;
    padding: 3px 10px;
    background: transparent;
    border: 1px solid #2a3a4a;
    border-radius: 4px;
    color: #5a7a96;
    font-size: 14px;
    cursor: pointer;
    transition: color 0.15s;
    line-height: 1;
}
#wm-ac-close-btn:hover { color:var(--wm-red); border-color:#ef444444; }

/* ── المحتوى الرئيسي ── */
#wm-ac-main {
    flex: 1;
    display: flex;
    overflow: hidden;
    min-height: 0;
    direction: ltr;
}

/* ── الخريطة ── */
#wm-ac-map-wrap {
    flex: 1;
    position: relative;
    min-width: 0;
    min-height: 300px;
}
#wm-ac-map { width:100%; height:100%; min-height:300px; }

/* ── السايدبار الأيمن ── */
#wm-ac-sidebar {
    width: 390px;
    min-width: 390px;
    flex-shrink: 0;
    display: flex;
    flex-direction: column;
    background: #080f1a;
    border-left: 1px solid #1e3a5a;
    overflow: hidden;
    position: relative;
}

/* ── شريط الملخص — «ماذا يحدث في الأجواء؟» ── */
#wm-ac-summary {
    display: flex;
    flex-shrink: 0;
    gap: 1px;
    background: #0d1a2a;
    border-bottom: 2px solid #1e3a5a;
}
.wm-ac-sum-item {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 2px;
    padding: 8px 4px;
    background: #060c14;
}
.wm-ac-sum-n { font-size: 18px; font-weight: 700; color: #c8dff0; font-variant-numeric: tabular-nums; }
.wm-ac-sum-mil .wm-ac-sum-n { color: #f59e0b; }
.wm-ac-sum-vip .wm-ac-sum-n { color: #a78bfa; }
.wm-ac-sum-emg .wm-ac-sum-n { color: #ef4444; }
.wm-ac-sum-l { font-size: 9px; color: #3a5a76; letter-spacing: 0.3px; }

/* ── أجواء خالية فجأة ── */
#wm-ac-empty-alert {
    flex-shrink: 0;
    padding: 6px 12px;
    background: rgba(239,68,68,0.12);
    border-bottom: 2px solid #1e3a5a;
    color: #fca5a5;
    font-size: 11px;
    direction: rtl;
    text-align: right;
}

/* ── قسم الفلاتر ── */
#wm-ac-filter-panel {
    flex-shrink: 0;
    background: #060c14;
    border-bottom: 2px solid #1e3a5a;
}
.wm-ac-fp-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 5px 10px;
    border-bottom: 1px solid #0d1a2a;
}
.wm-ac-fp-title {
    font-size: 9px;
    font-weight: 700;
    color: #3a5a76;
    letter-spacing: 0.6px;
}
.wm-ac-fp-reset {
    font-size: 9px;
    padding: 2px 9px;
    background: transparent;
    border: 1px solid #1e3a5a;
    border-radius: 3px;
    color: #3a5a76;
    cursor: pointer;
    font-family: inherit;
}
.wm-ac-fp-reset:hover { color:#c8dff0; border-color:#2a5a7a; }
.wm-ac-fp-fields {
    display: grid;
    grid-template-columns: 1fr 1fr;
}
.wm-ac-fp-field {
    padding: 4px 8px;
    border-bottom: 1px solid #0d1a2a;
    border-right: 1px solid #0d1a2a;
}
.wm-ac-fp-field:nth-child(even) { border-right: none; }
.wm-ac-fp-field label {
    display: block;
    font-size: 9px;
    color: #3a5a76;
    font-weight: 700;
    letter-spacing: 0.5px;
    margin-bottom: 2px;
}
.wm-ac-fp-field input {
    width: 100%;
    box-sizing: border-box;
    background: #0a1520;
    border: 1px solid #1a3050;
    border-radius: 3px;
    color: #c8dff0;
    font-size: 11px;
    padding: 2px 6px;
    outline: none;
    direction: ltr;
    font-family: monospace;
}
.wm-ac-fp-field input::placeholder { color: #253a52; }
.wm-ac-fp-field input:focus { border-color: rgba(0,212,255,0.3); }
.wm-ac-fp-toggles {
    display: flex;
    gap: 5px;
    padding: 6px 8px;
}
.wm-ac-filter-btn {
    padding: 3px 9px;
    background: transparent;
    border: 1px solid #1e3a5a;
    border-radius: 4px;
    color: #5a7a96;
    font-size: 11px;
    cursor: pointer;
    transition: all 0.15s;
    white-space: nowrap;
    font-family: inherit;
}
.wm-ac-filter-btn.on  { background:rgba(0,212,255,0.1); border-color:#00d4ff; color:#00d4ff; }
.wm-ac-filter-btn:hover { border-color:#2a5a7a; color:#c8dff0; }

/* ── بحث متقدّم — مطويّ افتراضياً، البحث الخام ليس أول ما يراه الزائر ── */
#wm-ac-fp-advanced { border-top: 1px solid #0d1a2a; }
#wm-ac-fp-advanced summary {
    padding: 6px 10px;
    font-size: 10px;
    color: #3a5a76;
    cursor: pointer;
    list-style: none;
    user-select: none;
}
#wm-ac-fp-advanced summary::-webkit-details-marker { display: none; }
#wm-ac-fp-advanced summary:hover { color: #5a7a96; }
#wm-ac-fp-advanced[open] summary { color: #00d4ff; border-bottom: 1px solid #0d1a2a; }

/* ── قائمة الطائرات ── */
#wm-ac-table-wrap {
    flex: 1;
    display: flex;
    flex-direction: column;
    overflow: hidden;
    min-height: 0;
}

/* تبويبات */
#wm-ac-tabs, #wm-ac-tabs-vip {
    display: flex;
    border-bottom: 1px solid #1e3a5a;
    flex-shrink: 0;
}
#wm-ac-tabs button, #wm-ac-tabs-vip button {
    flex: 1;
    padding: 6px 4px;
    background: transparent;
    border: none;
    border-bottom: 2px solid transparent;
    color: #475569;
    font-size: 11px;
    cursor: pointer;
    font-family: inherit;
    transition: all 0.15s;
}
#wm-ac-tabs button.active      { background:#0d1f35; border-bottom-color:#3b82f6; color:#c8dff0; font-weight:600; }
#wm-ac-tabs-vip button.active  { background:#0d1f35; border-bottom-color:#f59e0b; color:#f59e0b; font-weight:600; }
#wm-ac-tabs button:not(.active):hover,
#wm-ac-tabs-vip button:not(.active):hover { color:#94a3b8; }

/* رأس الأعمدة */
#wm-ac-cols-head {
    display: flex;
    padding: 5px 8px;
    background: #0a1628;
    border-bottom: 1px solid #1e3a5a;
    flex-shrink: 0;
    direction: ltr;
    gap: 4px;
}
#wm-ac-cols-head span {
    font-size: 9px;
    font-weight: 700;
    color: #3a5a76;
    letter-spacing: 0.5px;
    white-space: nowrap;
    overflow: hidden;
}
#wm-ac-cols-head .hident  { flex: 1; min-width: 0; }
#wm-ac-cols-head .htypeop { width: 108px; flex-shrink: 0; }
#wm-ac-cols-head .halt    { width: 50px;  flex-shrink: 0; }
#wm-ac-cols-head .hspd    { width: 42px;  flex-shrink: 0; }

/* قائمة التمرير */
#wm-ac-table-scroll {
    flex: 1;
    overflow-y: auto;
    overflow-x: hidden;
    scrollbar-width: thin;
    scrollbar-color: #1e3a5a transparent;
}
#wm-ac-table-scroll::-webkit-scrollbar { width: 4px; }
#wm-ac-table-scroll::-webkit-scrollbar-thumb { background:#1e3a5a; border-radius:2px; }

/* صفوف الطائرات */
.wm-ac-row {
    display: flex;
    direction: ltr;
    align-items: center;
    border-bottom: 1px solid #0d1a2a;
    cursor: pointer;
    transition: background 0.1s;
    width: 100%;
    box-sizing: border-box;
    padding: 5px 8px;
    gap: 4px;
}
.wm-ac-row:hover    { background: rgba(0,212,255,0.05); }
.wm-ac-row.selected { background: rgba(0,212,255,0.1); border-right: 2px solid #00d4ff; }
.wm-ac-row.emergency{ background: rgba(239,68,68,0.08); }

/* خلية IDENT — علم + callsign + hex */
.wm-ac-row .rcell-ident {
    flex: 1;
    min-width: 0;
    display: flex;
    align-items: center;
    gap: 5px;
}
.wm-ac-row .rflag { font-size: 15px; line-height: 1; flex-shrink: 0; }
.wm-ac-row .rident-lines { min-width: 0; }
.wm-ac-row .rcall {
    display: block;
    font-size: 12px;
    font-weight: 700;
    color: #c8dff0;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    letter-spacing: 0.3px;
}
.wm-ac-row .rhex {
    display: block;
    font-size: 9px;
    color: #3a5a76;
    font-family: monospace;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    direction: ltr;
}

/* خلية TYPE / OPERATOR */
.wm-ac-row .rcell-type {
    width: 108px;
    flex-shrink: 0;
    min-width: 0;
}
.wm-ac-row .rtype {
    display: block;
    font-size: 11px;
    font-weight: 600;
    color: #7a9ab6;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}
.wm-ac-row .roper {
    display: block;
    font-size: 9px;
    color: #3a5a76;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

/* خلايا الارتفاع والسرعة */
.wm-ac-row .ralt {
    width: 50px;
    flex-shrink: 0;
    font-size: 11px;
    white-space: nowrap;
    text-align: right;
}
.wm-ac-row .rspd {
    width: 42px;
    flex-shrink: 0;
    font-size: 11px;
    color: #5a7a96;
    white-space: nowrap;
    text-align: right;
}

/* شارات MIL / EMG */
.wm-ac-mil-badge {
    font-size: 8px; color:var(--wm-yellow);
    background: rgba(234,179,8,0.12);
    border: 1px solid #eab30830;
    border-radius: 2px; padding: 0 3px;
}
/* درجات ثقة التصنيف العسكري — confirmed أخضر (مطابق worldmonitor)، possible رمادي خفيف */
.wm-ac-mil-badge.confirmed { color:var(--wm-green); background:rgba(34,197,94,0.12); border-color:#22c55e30; }
.wm-ac-mil-badge.possible  { color:#94a3b8; background:rgba(148,163,184,0.10); border-color:#94a3b830; }
.wm-ac-emg-badge {
    font-size: 8px; color:var(--wm-red);
    background: rgba(239,68,68,0.12);
    border-radius: 2px; padding: 0 3px;
    animation: wm-aircraft-blink 0.8s infinite;
}

#wm-ac-empty {
    display: none;
    padding: 24px;
    text-align: center;
    color: #3a5a76;
    font-size: 12px;
}

/* ── بانل تفاصيل الرحلة ── */
#wm-ac-detail-panel {
    display: none;
    flex-direction: column;
    position: absolute;
    top: 0; left: 0; right: 0; bottom: 0;
    background: #060c14;
    z-index: 20;
    overflow-y: auto;
}
#wm-ac-detail-panel.visible { display: flex; }

#wm-ac-dp-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 14px;
    border-bottom: 1px solid #1e3a5a;
    background: #0a1520;
    flex-shrink: 0;
}
#wm-ac-dp-flagcall {
    display: flex;
    align-items: center;
    gap: 10px;
}
#wm-ac-dp-flag { font-size: 28px; line-height: 1; }
#wm-ac-dp-callsign {
    font-size: 20px;
    font-weight: 700;
    color: #e2e8f0;
    direction: ltr;
    letter-spacing: 1.5px;
}
#wm-ac-dp-hex {
    font-size: 10px;
    color: #3a5a76;
    font-family: monospace;
    direction: ltr;
    margin-top: 2px;
}
#wm-ac-dp-history-btn {
    padding: 5px 14px;
    background: transparent;
    border: 1px solid #1e3a5a;
    border-radius: 5px;
    color: #5a7a96;
    font-size: 11px;
    cursor: pointer;
    font-family: inherit;
    white-space: nowrap;
}
#wm-ac-dp-history-btn:hover { border-color:rgba(0,212,255,0.3); color:#c8dff0; }

#wm-ac-dp-stats {
    display: flex;
    background: #080f1a;
    border-bottom: 1px solid #1e3a5a;
    flex-shrink: 0;
}
.wm-ac-dp-stat {
    flex: 1;
    padding: 12px 6px;
    text-align: center;
    border-right: 1px solid #0d1a2a;
}
.wm-ac-dp-stat:last-child { border-right: none; }
.wm-ac-dp-stat span {
    display: block;
    font-size: 14px;
    font-weight: 700;
    color: #00d4ff;
    direction: ltr;
    margin-bottom: 3px;
}
.wm-ac-dp-stat small {
    font-size: 9px;
    color: #3a5a76;
    letter-spacing: 0.5px;
    display: block;
}

#wm-ac-dp-info { padding: 4px 0; }
.wm-ac-dp-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 7px 14px;
    border-bottom: 1px solid #0d1a2a;
    font-size: 11px;
}
.wm-ac-dp-row span:first-child { color: #3a5a76; }
.wm-ac-dp-row span:last-child  { color: #c8dff0; direction: ltr; font-weight: 500; max-width: 55%; text-align: right; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

#wm-ac-dp-close-btn {
    margin: 12px;
    padding: 9px;
    background: rgba(59,130,246,0.12);
    border: 1px solid rgba(59,130,246,0.3);
    border-radius: 6px;
    color: #3b82f6;
    font-size: 12px;
    cursor: pointer;
    font-family: inherit;
    width: calc(100% - 24px);
    transition: background 0.15s;
}
#wm-ac-dp-close-btn:hover { background: rgba(59,130,246,0.22); }

/* ── شريط الألوان السفلي ── */
#wm-ac-legend {
    height: 26px;
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 0 12px;
    background: #0a1520;
    border-top: 1px solid #1e3a5a;
    flex-shrink: 0;
    font-size: 10px;
    color: #3a5a76;
}
.wm-ac-legend-bar {
    flex: 1; height: 8px; border-radius: 4px;
    background: linear-gradient(to right, #94a3b8 0%, var(--wm-green) 15%, #3b82f6 35%, var(--wm-orange) 60%, #e2e8f0 100%);
}
.wm-ac-legend-label { font-size: 9px; white-space: nowrap; }

/* ── Loading ── */
#wm-ac-loading {
    position: absolute;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-direction: column;
    gap: 12px;
    background: #060c14;
    z-index: 10;
}
.wm-ac-spinner-lg {
    width: 36px; height: 36px;
    border: 3px solid #1e3a5a;
    border-top-color: #00d4ff;
    border-radius: 50%;
    animation: wm-spin 0.8s linear infinite;
}

/* =============================================
   Data Overlays — زلازل / حرائق / سفر
   مشترك بين الثلاثة
   ============================================= */
.wm-data-overlay {
    display: none;
    position: absolute;
    top: 0;
    left: 0;
    right: 52px; /* لا تغطي الـ layer dock */
    bottom: 0;
    z-index: 800;
    flex-direction: column;
    background: #060c14;
    font-family: var(--wm-font-ar, sans-serif);
    direction: ltr;
}
.wm-data-overlay.active { display: flex; }

.wm-do-bar {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 0 12px;
    height: 44px;
    background: #0a1520;
    border-bottom: 1px solid #1e3a5a;
    flex-shrink: 0;
    flex-wrap: wrap;
}
.wm-do-logo { font-size:13px; font-weight:700; color:#00d4ff; white-space:nowrap; }
.wm-do-sep  { width:1px; height:22px; background:#1e3a5a; flex-shrink:0; }
.wm-do-counter { font-size:11px; color:#5a7a96; white-space:nowrap; }
.wm-do-counter strong { color:#00d4ff; font-size:13px; }
.wm-do-ts { font-size:10px; color:#3a5a76; }
.wm-do-filter-btn {
    padding:3px 9px; background:transparent; border:1px solid #1e3a5a;
    border-radius:4px; color:#5a7a96; font-size:11px; cursor:pointer; white-space:nowrap;
    transition: all 0.15s;
}
.wm-do-filter-btn.on { background:rgba(0,212,255,0.1); border-color:#00d4ff; color:#00d4ff; }
.wm-do-close {
    margin-right:auto; padding:3px 10px; background:transparent;
    border:1px solid #2a3a4a; border-radius:4px; color:#5a7a96;
    font-size:14px; cursor:pointer; transition:color 0.15s; line-height:1;
}
.wm-do-close:hover { color:var(--wm-red); border-color:#ef444444; }

.wm-do-main {
    flex:1; display:flex; overflow:hidden; min-height:0; direction:ltr;
}
.wm-do-map-wrap {
    flex:1; position:relative; min-width:0; min-height:300px;
}
.wm-do-map-wrap > div:first-child { width:100%; height:100%; }

.wm-do-loading {
    position:absolute; inset:0; display:flex; align-items:center;
    justify-content:center; flex-direction:column; gap:12px;
    background:#060c14; z-index:10;
}

/* جدول جانبي مشترك */
.wm-do-table-wrap {
    width:340px; min-width:340px; flex-shrink:0;
    display:flex; flex-direction:column;
    background:#080f1a; border-right:1px solid #1e3a5a; overflow:hidden;
}
.wm-do-table-head {
    display:flex; background:#0a1520; border-bottom:1px solid #1e3a5a;
    flex-shrink:0; direction:ltr;
}
.wm-do-table-head span {
    padding:7px 6px; font-size:10px; font-weight:600;
    color:#3a5a76; white-space:nowrap; overflow:hidden;
}
.wm-do-table-head .hcall { flex:1; min-width:0; }
.wm-do-table-head .halt  { width:52px; flex-shrink:0; }
.wm-do-table-head .hspd  { width:44px; flex-shrink:0; }
.wm-do-table-head .htype { width:64px; flex-shrink:0; }

.wm-do-table-scroll {
    flex:1; overflow-y:auto; overflow-x:hidden;
    scrollbar-width:thin; scrollbar-color:#1e3a5a transparent;
}
.wm-do-table-scroll::-webkit-scrollbar { width:4px; }
.wm-do-table-scroll::-webkit-scrollbar-thumb { background:#1e3a5a; border-radius:2px; }

.wm-do-row {
    display:flex; direction:ltr; border-bottom:1px solid #0d1a2a;
    cursor:pointer; transition:background 0.1s; align-items:center;
    width:100%; box-sizing:border-box;
}
.wm-do-row:hover    { background:rgba(0,212,255,0.05); }
.wm-do-row.selected { background:rgba(0,212,255,0.1); }
.wm-do-row .rcall { flex:1; min-width:0; padding:5px 6px; font-size:11px; font-weight:600; color:#c8dff0; white-space:nowrap; overflow:hidden; text-overflow:ellipsis; }
.wm-do-row .ralt  { width:52px; flex-shrink:0; padding:5px 4px; font-size:11px; white-space:nowrap; }
.wm-do-row .rspd  { width:44px; flex-shrink:0; padding:5px 4px; font-size:10px; color:#5a7a96; white-space:nowrap; }
.wm-do-row .rtype { width:64px; flex-shrink:0; padding:5px 6px 5px 4px; font-size:10px; color:#5a7a96; white-space:nowrap; overflow:hidden; text-overflow:ellipsis; }

.wm-do-legend {
    height:26px; display:flex; align-items:center; gap:12px; padding:0 12px;
    background:#0a1520; border-top:1px solid #1e3a5a; flex-shrink:0;
    font-size:10px; color:#3a5a76;
}
.wm-do-empty { padding:20px; text-align:center; color:#3a5a76; font-size:12px; }

/* =============================================
   UNHCR Overlay — النزوح القسري
   ============================================= */
.wm-unhcr-card {
    flex: 1;
    padding: 10px 14px;
    background: #080f1a;
    text-align: center;
}
.wm-unhcr-card-val {
    font-size: 20px;
    font-weight: 700;
    color: #00d4ff;
    line-height: 1.2;
    direction: ltr;
}
.wm-unhcr-card-lbl {
    font-size: 10px;
    color: #3a5a76;
    margin-top: 3px;
    white-space: nowrap;
}

/* UNHCR Cards */
.wm-unhcr-card { flex:1; padding:10px 14px; background:#080f1a; text-align:center; }
.wm-unhcr-val  { font-size:20px; font-weight:700; color:#00d4ff; direction:ltr; }
.wm-unhcr-lbl  { font-size:10px; color:#3a5a76; margin-top:3px; white-space:nowrap; }

/* ══════════════════════════════════════════════════
   Mobile Bottom Navigation Bar — v2.6
   يظهر فقط على شاشات ≤ 768px
══════════════════════════════════════════════════ */

#wm-mobile-nav {
  display: none;
}

@media (max-width: 768px) {
  /* ── شريط التنقل السفلي ── */
  #wm-mobile-nav {
    display: flex;
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    z-index: 9000;
    height: 56px;
    background: rgba(5, 10, 18, 0.97);
    border-top: 1px solid rgba(30, 58, 90, 0.7);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    align-items: stretch;
    justify-content: space-around;
  }

  .wm-mn-btn {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 3px;
    background: none;
    border: none;
    border-top: 2px solid transparent;
    color: #475569;
    cursor: pointer;
    transition: color .2s, border-color .2s, background .2s;
    padding: 6px 4px 4px;
    position: relative;
    -webkit-tap-highlight-color: transparent;
  }

  .wm-mn-btn:active {
    background: rgba(255,255,255,0.04);
  }

  .wm-mn-btn.active {
    color: #00d4ff;
    border-top-color: #00d4ff;
  }

  .wm-mn-icon {
    font-size: 18px;
    line-height: 1;
  }

  .wm-mn-label {
    font-size: 9px;
    font-family: var(--wm-font-ar);
    letter-spacing: 0.3px;
    white-space: nowrap;
    font-weight: 600;
  }

  .wm-mn-badge {
    position: absolute;
    top: 4px;
    right: calc(50% - 16px);
    min-width: 16px;
    height: 16px;
    background: var(--wm-red);
    color: #fff;
    font-size: 9px;
    font-weight: 700;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0 3px;
    line-height: 1;
  }

  .wm-mn-badge:empty,
  .wm-mn-badge[data-count="0"] { display: none; }

  /* ── تبويبات التصنيف على الموبايل (بدل #wm-tabs-bar المخفي) ── */
  #wm-mobile-cat-bar {
    display: flex;
    position: fixed;
    top: 45px; /* تحت الـ topbar */
    left: 0;
    right: 0;
    z-index: 390;
    background: rgba(6, 12, 20, 0.95);
    border-bottom: 1px solid rgba(30, 58, 90, 0.5);
    overflow-x: auto;
    scrollbar-width: none;
    -webkit-overflow-scrolling: touch;
    padding: 5px 8px;
    gap: 5px;
    backdrop-filter: blur(8px);
  }

  #wm-mobile-cat-bar::-webkit-scrollbar { display: none; }

  .wm-mcb-btn {
    flex-shrink: 0;
    background: rgba(13, 26, 42, 0.7);
    border: 1px solid rgba(30, 58, 90, 0.6);
    border-radius: 20px;
    color: #64748b;
    font-size: 11px;
    font-family: var(--wm-font-ar);
    padding: 4px 11px;
    cursor: pointer;
    white-space: nowrap;
    transition: all .18s;
    -webkit-tap-highlight-color: transparent;
  }

  .wm-mcb-btn.active {
    background: rgba(0, 212, 255, 0.15);
    border-color: #00d4ff;
    color: #00d4ff;
    font-weight: 600;
  }

  /* ── تعديل الـ topbar ليتسع للموبايل ── */
  #wm-topbar {
    top: 0;
    height: 44px;
    padding: 0 10px !important;
    gap: 8px;
  }

  .wm-topbar-logo {
    font-size: 13px !important;
    letter-spacing: 1px;
  }

  /* ⚠️ فيض حقيقي مُشاهَد حياً (2026-10-06): أزرار .wm-topbar-right (بحث المدن/الإشعارات/
     ⋯/☰...) بعرض إجمالي ~450px داخل عرض شاشة 390px، وflex-shrink:0 على كل زر يمنع
     الانكماش — فيخرج آخر زرَّين (⋯ القائمة الإضافية، ☰ فتح القائمة) تماماً خارج حافة
     الشاشة اليسرى (RTL) بلا أي وسيلة وصول. تمرير أفقي بدل كسر التصميم أو حذف أزرار */
  .wm-topbar-right {
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
    max-width: calc(100vw - 110px); /* هامش للشعار على الطرف الآخر من الصف */
  }
  .wm-topbar-right::-webkit-scrollbar { display: none; }

  /* ── المحتوى يبدأ تحت mobile-cat-bar ── */
  #wm-map-fullscreen {
    top: 0;
    bottom: 56px; /* فوق bottom nav */
  }

  /* الـ sidebar يرتفع فوق bottom nav */
  #wm-sidebar {
    bottom: 56px !important;
  }

  /* إخفاء زر toggle الـ sidebar القديم (الـ bottom nav تحل محله) */
  #wm-sidebar-toggle { display: none; }
}

/* ── داخل ≤ 480px: تصغير إضافي ── */
@media (max-width: 480px) {
  .wm-mn-label { font-size: 8px; }
  .wm-mn-icon  { font-size: 16px; }
  #wm-mobile-nav { height: 52px; }
  #wm-mobile-cat-bar { top: 44px; }
  /* شريط التنقل السفلي يتقلص إلى 52px هنا — بدون هذا التصحيح يبقى #wm-map-fullscreen
     و#wm-sidebar محجوزَين بـ56px الموروثة من@media(768px)، فتظهر فجوة 4px أسفل الخريطة */
  #wm-map-fullscreen { bottom: 52px; }
  #wm-sidebar { bottom: 52px !important; }
}

/* ══════════════════════════════════════════════════
   Timeline v2.6 — تصميم محسّن
══════════════════════════════════════════════════ */
.wm-tl2-controls {
  flex-shrink: 0;
  padding: 8px 10px;
  background: rgba(5,10,18,0.7);
  border-bottom: 1px solid rgba(30,58,90,0.6);
  display: flex;
  flex-direction: column;
  gap: 6px;
  direction: rtl;
}
.wm-tl2-select {
  width: 100%;
  padding: 6px 10px;
  background: rgba(13,26,42,0.8);
  border: 1px solid rgba(30,58,90,0.8);
  border-radius: 6px;
  color: #c8dff0;
  font-size: 11px;
  font-family: var(--wm-font-ar);
  cursor: pointer;
  outline: none;
}
.wm-tl2-select:focus { border-color: var(--wm-accent); }
.wm-tl2-periods {
  display: flex;
  gap: 4px;
}
.wm-tl-period {
  flex: 1;
  padding: 3px 0;
  background: transparent;
  border: 1px solid rgba(30,58,90,0.7);
  border-radius: 4px;
  color: #475569;
  font-size: 10px;
  cursor: pointer;
  transition: all .15s;
  font-family: var(--wm-font-ar);
}
.wm-tl-period:hover { border-color: var(--wm-accent); color: var(--wm-accent); }
.wm-tl-period.active { background: rgba(0,180,255,0.15); border-color: var(--wm-accent); color: #fff; font-weight: 600; }

.wm-tl2-search {
  width: 100%;
  padding: 5px 10px;
  background: rgba(13,26,42,0.6);
  border: 1px solid rgba(30,58,90,0.6);
  border-radius: 6px;
  color: #c8dff0;
  font-size: 11px;
  font-family: var(--wm-font-ar);
  outline: none;
  box-sizing: border-box;
}
.wm-tl2-search:focus { border-color: var(--wm-accent); }
.wm-tl2-search::placeholder { color: #334155; }

.wm-tl2-body {
  flex: 1;
  overflow-y: auto;
  padding: 10px;
  direction: rtl;
  scrollbar-width: thin;
  scrollbar-color: #1e3a5a transparent;
}
.wm-tl2-body::-webkit-scrollbar { width: 3px; }
.wm-tl2-body::-webkit-scrollbar-thumb { background: #1e3a5a; border-radius: 2px; }

/* رأس مع إحصاءات */
.wm-tl2-header {
  margin-bottom: 12px;
  padding-bottom: 10px;
  border-bottom: 1px solid rgba(30,58,90,0.5);
}
.wm-tl2-event-title {
  font-size: 13px;
  font-weight: 700;
  color: #e2e8f0;
  margin-bottom: 6px;
  line-height: 1.4;
}
.wm-tl2-stats {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
}
.wm-tl2-stat {
  font-size: 11px;
  color: #64748b;
  background: rgba(30,58,90,0.3);
  padding: 2px 8px;
  border-radius: 10px;
  border: 1px solid rgba(30,58,90,0.5);
}
.wm-tl2-stat strong { color: #94a3b8; }
.wm-tl2-stat-red strong { color: var(--wm-red); }

/* خط زمني */
.wm-tl2-track {
  position: relative;
}

/* فاصل اليوم */
.wm-tl2-day-sep {
  display: flex;
  align-items: center;
  gap: 8px;
  margin: 12px 0 8px;
}
.wm-tl2-day-sep::before,
.wm-tl2-day-sep::after {
  content: '';
  flex: 1;
  height: 1px;
  background: rgba(30,58,90,0.5);
}
.wm-tl2-day-label {
  font-size: 10px;
  color: #334155;
  background: rgba(6,12,20,1);
  padding: 2px 10px;
  border: 1px solid rgba(30,58,90,0.5);
  border-radius: 10px;
  white-space: nowrap;
}

/* عنصر الحدث */
.wm-tl2-item {
  display: flex;
  gap: 0;
  margin-bottom: 0;
  position: relative;
  padding-right: 18px;
}
/* خط عمودي يصل الأحداث */
.wm-tl2-line {
  position: absolute;
  right: 5px;
  top: 12px;
  bottom: -8px;
  width: 2px;
  border-right: 2px dashed rgba(30,58,90,0.5);
}
.wm-tl2-item-last .wm-tl2-line { display: none; }
.wm-tl2-item-high .wm-tl2-line { border-style: solid; opacity: 0.7; }

/* النقطة */
.wm-tl2-dot {
  position: absolute;
  right: 0;
  top: 10px;
  width: 12px;
  height: 12px;
  border-radius: 50%;
  flex-shrink: 0;
  z-index: 2;
  transition: transform .15s;
}
.wm-tl2-item:hover .wm-tl2-dot { transform: scale(1.3); }

/* بطاقة الحدث */
.wm-tl2-card {
  flex: 1;
  display: block;
  text-decoration: none;
  background: rgba(8,15,26,0.7);
  border: 1px solid rgba(30,58,90,0.5);
  border-radius: 8px;
  padding: 8px 10px;
  margin-bottom: 8px;
  transition: background .15s, border-color .15s, transform .15s;
}
.wm-tl2-card:hover {
  background: rgba(13,26,42,0.9);
  border-color: rgba(59,130,246,0.4);
  transform: translateX(-2px);
}
.wm-tl2-item-high .wm-tl2-card {
  background: rgba(15,10,10,0.8);
  border-color: rgba(239,68,68,0.25);
}
.wm-tl2-card-top {
  display: flex;
  align-items: center;
  gap: 6px;
  margin-bottom: 5px;
  flex-wrap: wrap;
}
.wm-tl2-score {
  font-size: 10px;
  font-weight: 700;
  padding: 1px 7px;
  border-radius: 10px;
  border: 1px solid;
  font-family: var(--wm-font-mono);
}
.wm-tl2-time {
  font-size: 10px;
  color: #475569;
  font-family: var(--wm-font-mono);
}
.wm-tl2-src {
  font-size: 10px;
  color: #38bdf8;
  margin-right: auto;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  max-width: 100px;
}
.wm-tl2-title {
  font-size: 12px;
  color: #cbd5e1;
  line-height: 1.5;
  word-break: break-word;
}
.wm-tl2-summary {
  font-size: 11px;
  color: #475569;
  line-height: 1.4;
  margin-top: 4px;
  border-right: 2px solid rgba(30,58,90,0.6);
  padding-right: 6px;
}

/* حالة فارغة + spinner */
.wm-tl2-empty {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding: 40px 20px;
  color: #334155;
  font-size: 12px;
  text-align: center;
  font-family: var(--wm-font-ar);
}
.wm-tl2-spinner {
  width: 22px; height: 22px;
  border: 2px solid rgba(30,58,90,0.4);
  border-top-color: var(--wm-accent);
  border-radius: 50%;
  animation: wm-spin .8s linear infinite;
}
@keyframes wm-spin { to { transform: rotate(360deg); } }

/* ══════════════════════════════════════════════════
   ACLED — مسارات الضربات كخطوط على الخريطة
══════════════════════════════════════════════════ */
.wm-acled-strike-line {
  stroke-dasharray: 6 4;
  animation: wm-dash-flow 1.5s linear infinite;
}
@keyframes wm-dash-flow {
  to { stroke-dashoffset: -20; }
}
.wm-conflict-pulse {
  animation: wm-conflict-ring 1.8s ease-out infinite;
}
@keyframes wm-conflict-ring {
  0%   { opacity: 1; }
  70%  { opacity: 0.4; }
  100% { opacity: 1; }
}

/* ══════════════════════════════════════════════════
   Tension Map — حدود الدول الملوّنة + خطوط التوتر
══════════════════════════════════════════════════ */
.wm-tension-country-border {
  transition: opacity .3s;
}
.wm-tension-arc-line {
  pointer-events: none;
}
.wm-tension-arc-line path {
  stroke-dasharray: 8 5;
  animation: wm-tension-flow 2s linear infinite;
}
@keyframes wm-tension-flow {
  to { stroke-dashoffset: -26; }
}

/* ══════════════════════════════════════════════════
   Mobile Touch Improvements + Swipe UX — v2.6
══════════════════════════════════════════════════ */

/* منع تحديد النص أثناء السوايب */
#wm-root { -webkit-user-select: none; user-select: none; }
/* السماح بتحديد النص في قائمة الأخبار */
#wm-news-list, .wm-item-title, .wm-tl2-title { -webkit-user-select: text; user-select: text; }

/* تحسين أهداف اللمس — أزرار أكبر على الموبايل */
@media (max-width: 768px) {
  .wm-ld-btn   { width: 40px; height: 40px; font-size: 17px; }
  .wm-tb-btn   { width: 40px; height: 40px; font-size: 17px; }
  .wm-sbt      { min-height: 48px; }
  .wm-item     { min-height: 60px; }
  .wm-tab      { min-height: 36px; padding: 8px 12px; }

  /* مؤشر السوايب — خط دقيق على حافة الـ sidebar */
  #wm-sidebar::before {
    content: '';
    position: absolute;
    left: -3px;
    top: 40%;
    height: 60px;
    width: 4px;
    background: rgba(0,212,255,0.3);
    border-radius: 2px;
    pointer-events: none;
    transition: background .2s;
  }
  #wm-sidebar:not(.wm-sidebar-closed)::before {
    background: rgba(0,212,255,0.5);
  }

  /* Sidebar slide animation محسّنة */
  #wm-sidebar {
    transition: transform .28s cubic-bezier(.4,0,.2,1) !important;
    will-change: transform;
  }
}

/* ══ Watch Alert Toast ══ */
@keyframes wm-toast-in {
  from { opacity:0; transform:translateX(-50%) translateY(-12px) scale(.96); }
  to   { opacity:1; transform:translateX(-50%) translateY(0) scale(1); }
}

/* ══ زر تفعيل الإشعارات في الـ topbar ══ */
#wm-notif-btn {
  background: none;
  border: 1px solid rgba(30,58,90,0.6);
  border-radius: 7px;
  color: #64748b;
  width: 34px; height: 34px;
  cursor: pointer;
  font-size: 15px;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all .2s;
  flex-shrink: 0;
}
#wm-notif-btn:hover  { border-color: var(--wm-accent); color: var(--wm-accent); }
#wm-notif-btn.active { background: rgba(0,212,255,0.12); border-color: var(--wm-accent); color: var(--wm-accent); }
#wm-notif-btn.denied { color: var(--wm-red); border-color: rgba(239,68,68,0.4); }

/* ══ Watchlist — تحسين بصري ══ */
.wm-watch-match {
  background: linear-gradient(to left, rgba(251,191,36,0.08) 0%, transparent 100%) !important;
  border-right-color: #f59e0b !important;
}
.wm-watch-highlight {
  background: rgba(251,191,36,0.3);
  border-radius: 2px;
  padding: 0 2px;
}
.wm-watch-hit {
  padding: 9px 10px;
  border-bottom: 1px solid rgba(30,58,90,0.4);
  cursor: pointer;
  transition: background .15s;
  direction: rtl;
}
.wm-watch-hit:hover { background: rgba(251,191,36,0.06); }
.wm-watch-hit-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 4px;
  gap: 6px;
}
.wm-watch-hit-terms { display: flex; gap: 4px; flex-wrap: wrap; flex: 1; }
.wm-watch-hit-tag {
  font-size: 10px;
  background: rgba(251,191,36,0.15);
  color: #f59e0b;
  border: 1px solid rgba(251,191,36,0.3);
  padding: 1px 7px;
  border-radius: 10px;
  white-space: nowrap;
}
.wm-watch-hit-score {
  font-size: 10px;
  font-weight: 700;
  padding: 1px 7px;
  border-radius: 10px;
  flex-shrink: 0;
}
.wm-watch-hit-title {
  font-size: 12px;
  color: #e2e8f0;
  line-height: 1.5;
  margin-bottom: 4px;
}
.wm-watch-hit-meta {
  display: flex;
  gap: 8px;
  font-size: 10px;
  color: #475569;
}
.wm-watch-hit-loc {
  font-size: 10px;
  color: #475569;
  margin-top: 2px;
}
.wm-watch-mark {
  font-size: 12px;
  margin-right: 4px;
  opacity: 0.8;
}

/* ══════════════════════════════════════════════════
   Advanced Search — بحث متقدم v2.6
══════════════════════════════════════════════════ */
.wm-advsearch-bar {
  display: flex;
  gap: 5px;
  align-items: center;
  padding: 6px 10px;
  border-bottom: 1px solid rgba(30,58,90,0.4);
}
.wm-advsearch-input {
  flex: 1;
  background: rgba(13,26,42,0.7);
  border: 1px solid rgba(30,58,90,0.6);
  border-radius: 6px;
  color: #c8dff0;
  font-size: 12px;
  padding: 5px 10px;
  outline: none;
  font-family: var(--wm-font-ar);
  transition: border-color .15s;
}
.wm-advsearch-input:focus { border-color: var(--wm-accent); }
.wm-advsearch-input::placeholder { color: #334155; }

.wm-advsearch-toggle {
  width: 30px; height: 30px;
  background: rgba(13,26,42,0.6);
  border: 1px solid rgba(30,58,90,0.6);
  border-radius: 6px;
  color: #64748b;
  cursor: pointer;
  font-size: 13px;
  display: flex; align-items: center; justify-content: center;
  transition: all .15s;
  flex-shrink: 0;
}
.wm-advsearch-toggle:hover,
.wm-advsearch-toggle.active { background: rgba(0,180,255,0.12); border-color: var(--wm-accent); color: var(--wm-accent); }

.wm-advsearch-panel {
  background: rgba(5,10,18,0.7);
  border-bottom: 1px solid rgba(30,58,90,0.4);
  padding: 8px 10px;
  direction: rtl;
  animation: wm-slide-down .2s ease;
}
.wm-advsearch-row {
  display: flex;
  gap: 5px;
  margin-bottom: 5px;
}
.wm-advsearch-row:last-child { margin-bottom: 0; }

.wm-advsearch-sel {
  flex: 1;
  background: rgba(13,26,42,0.8);
  border: 1px solid rgba(30,58,90,0.6);
  border-radius: 5px;
  color: #94a3b8;
  font-size: 10px;
  padding: 4px 6px;
  font-family: var(--wm-font-ar);
  cursor: pointer;
  outline: none;
}
.wm-advsearch-sel:focus { border-color: var(--wm-accent); }

.wm-advsearch-clear {
  padding: 4px 10px;
  background: rgba(239,68,68,0.08);
  border: 1px solid rgba(239,68,68,0.25);
  border-radius: 5px;
  color: var(--wm-red);
  font-size: 10px;
  cursor: pointer;
  font-family: var(--wm-font-ar);
  white-space: nowrap;
  transition: all .15s;
  flex-shrink: 0;
}
.wm-advsearch-clear:hover { background: var(--wm-red); color: #fff; }

/* ══════════════════════════════════════════════════════════════
   🕸️ Actor Mapping Panel
   ══════════════════════════════════════════════════════════════ */
#wm-panel-actors {
  flex-direction: column;
  overflow: hidden;
}
#wm-actor-graph-wrap {
  flex: 1;
  overflow: hidden;
  position: relative;
  min-height: 300px;
}
#wm-actor-svg {
  width: 100%;
  display: block;
}
#wm-actor-loading {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  color: #3a5a76;
  font-size: 12px;
}
#wm-actor-legend {
  padding: 6px 12px;
  border-top: 1px solid #1e3a5a;
  font-size: 10px;
  color: #3a5a76;
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
  flex-shrink: 0;
}

/* ══════════════════════════════════════════════════════════════
   ✅ Source Credibility Badges
   ══════════════════════════════════════════════════════════════ */
.wm-cred-badge {
  display: inline-block;
  font-size: 9px;
  padding: 1px 5px;
  border-radius: 8px;
  font-weight: 600;
  margin-right: 3px;
  vertical-align: middle;
  line-height: 1.4;
}
.wm-cred-verified  { background: #dcfce7; color: #15803d; border: 1px solid #15803d33; }
.wm-cred-state     { background: #dbeafe; color: #1d4ed8; border: 1px solid #1d4ed833; }
.wm-cred-unverified{ background: #fef9c3; color: #a16207; border: 1px solid #a1620733; }
.wm-cred-sensational{background: #fee2e2; color: #dc2626; border: 1px solid #dc262633; }
.wm-cred-unknown   { background: #f1f5f9; color: #64748b; border: 1px solid #64748b22; }

/* ══════════════════════════════════════════════════════════════
   📋 Event Intelligence — تعميق صفحة الحدث
   ══════════════════════════════════════════════════════════════ */
.wm-ev-actors {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  padding: 12px 0;
}
.wm-ev-actor-tag {
  background: #0d1a2a;
  border: 1px solid #1e3a5a;
  color: #60a5fa;
  font-size: 11px;
  padding: 3px 10px;
  border-radius: 20px;
  display: flex;
  align-items: center;
  gap: 5px;
}
.wm-ev-actor-tag .wm-ev-actor-mentions {
  background: #1e3a5a;
  color: #94a3b8;
  font-size: 9px;
  padding: 0 4px;
  border-radius: 8px;
}
.wm-ev-source-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 6px 0;
  border-bottom: 1px solid #1e3a5a11;
  font-size: 11px;
}

/* ══ شريط التبويبات السفلي — ثابت في الأسفل ══ */
.wm-sb-tabs-wrap {
  order: 3;
  flex-shrink: 0;
  overflow: hidden;
}
.wm-sb-tabs {
  overflow-x: auto !important;
  overflow-y: hidden !important;
  flex-wrap: nowrap !important;
  scrollbar-width: none !important;
  -ms-overflow-style: none !important;
}
.wm-sb-tabs::-webkit-scrollbar { display: none !important; }
.wm-sbt {
  flex: 0 0 auto !important;
  min-width: 52px !important;
}

/* ══════════════════════════════════════════════════════════════
   📷 WEBCAM PANEL
   ══════════════════════════════════════════════════════════════ */
#wm-webcam-panel {
  right: 52px;          /* يسار الـ dock مباشرة */
  top: 60px;
  width: 360px;
  max-height: calc(100vh - 130px);
  box-shadow: -4px 8px 32px rgba(0,0,0,0.6);
}
#wm-webcam-thumb-wrap {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
}
#wm-webcam-thumb {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  filter: brightness(0.65);
}
#wm-webcam-play-btn:hover {
  transform: scale(1.08);
  transition: transform 0.15s;
}
#wm-webcam-list {
  scrollbar-width: thin;
  scrollbar-color: #1e3a5a transparent;
}
@media (max-width: 600px) {
  #wm-webcam-panel {
    width: calc(100vw - 60px);
    right: 0;
    left: auto;
    border-radius: 10px 0 0 10px;
  }
}

/* ══ World Clock ══ */
#wm-world-clock {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 5px 10px;
  background: rgba(6,12,20,0.85);
  border-top: 1px solid rgba(30,58,90,0.5);
  font-size: 10px;
  direction: ltr;
  flex-wrap: nowrap;
  overflow-x: auto;
  scrollbar-width: none;
}
#wm-world-clock::-webkit-scrollbar { display: none; }
.wm-wc-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1px;
  flex-shrink: 0;
}
.wm-wc-city {
  color: #475569;
  font-size: 9px;
  white-space: nowrap;
  direction: rtl;
}
.wm-wc-time {
  color: #60a5fa;
  font-size: 11px;
  font-weight: 700;
  font-family: monospace;
  letter-spacing: 0.5px;
}
.wm-wc-sep {
  color: #1e3a5a;
  font-size: 14px;
  flex-shrink: 0;
}


/* ══ IODA Overlay ══ */
#wm-ioda-overlay{display:none;position:absolute;inset:0;z-index:800;flex-direction:column;background:#060c14;font-family:var(--wm-font-ar,sans-serif)}
#wm-ioda-overlay.active{display:flex}
#wm-ioda-bar{display:flex;align-items:center;gap:8px;padding:0 12px;height:46px;direction:rtl;background:#0a1520;border-bottom:1px solid #1e3a5a;flex-shrink:0;overflow-x:auto;scrollbar-width:none}
#wm-ioda-bar::-webkit-scrollbar{display:none}
.wm-ioda-logo{display:flex;align-items:center;gap:6px;font-size:13px;font-weight:700;color:#e2e8f0;white-space:nowrap}
#wm-ioda-counter{font-size:11px;color:#64748b;white-space:nowrap}
#wm-ioda-counter strong{color:#3b82f6}
#wm-ioda-main{flex:1;display:flex;flex-direction:row-reverse;overflow:hidden}
#wm-ioda-map-wrap{flex:1;position:relative}
#wm-ioda-map{width:100%;height:100%}
#wm-ioda-table-wrap{width:280px;flex-shrink:0;display:flex;flex-direction:column;border-left:1px solid #1e3a5a;background:#060c14;direction:rtl}
#wm-ioda-table-head{display:flex;padding:6px 10px;font-size:10px;font-weight:700;color:#475569;border-bottom:1px solid #1e3a5a;background:#0a1520}
#wm-ioda-table-scroll{flex:1;overflow-y:auto;scrollbar-width:thin;scrollbar-color:#1e3a5a transparent}
.wm-ioda-row{display:flex;align-items:center;padding:8px 10px;border-bottom:1px solid rgba(30,58,90,0.4);gap:6px;font-size:12px;cursor:pointer;transition:background .15s}
.wm-ioda-row:hover{background:rgba(30,58,90,0.3)}
.ioda-flag{font-size:18px;flex-shrink:0}
.ioda-name{flex:1.5;color:#c8dff0}
.ioda-status{flex:1;text-align:center}
.ioda-drop{flex:0.8;text-align:center;font-weight:700}
.wm-ioda-status-critical{color:var(--wm-red);font-size:10px;font-weight:700}
.wm-ioda-status-warning{color:var(--wm-yellow);font-size:10px;font-weight:700}
.wm-ioda-status-normal{color:var(--wm-green);font-size:10px}
#wm-ioda-legend{display:flex;align-items:center;gap:12px;padding:5px 14px;background:#060c14;border-top:1px solid #1e3a5a;flex-shrink:0;direction:rtl;font-size:10px;color:#475569}

/* ══ IODA Overlay Pulse Animations ══ */
.wm-ioda-pulse-critical {
    animation: ioda-pulse-critical 2s ease-in-out infinite;
}
.wm-ioda-pulse-warning {
    animation: ioda-pulse-warning 3s ease-in-out infinite;
}
@keyframes ioda-pulse-critical {
    0%, 100% { opacity: 0.9; stroke-width: 2.5px; }
    50%       { opacity: 0.5; stroke-width: 1.5px; }
}
@keyframes ioda-pulse-warning {
    0%, 100% { opacity: 0.8; }
    50%       { opacity: 0.4; }
}

/* ══ NASA EONET + DONKI Overlay ══ */
#wm-nasa-overlay{display:none;position:absolute;inset:0;z-index:800;flex-direction:column;background:#060c14;font-family:var(--wm-font-ar,sans-serif)}
#wm-nasa-overlay.active{display:flex}
#wm-nasa-bar{display:flex;align-items:center;gap:8px;padding:0 12px;height:46px;direction:rtl;background:#0a1520;border-bottom:1px solid #1e3a5a;flex-shrink:0;overflow-x:auto;scrollbar-width:none}
#wm-nasa-bar::-webkit-scrollbar{display:none}
.wm-nasa-logo{display:flex;align-items:center;gap:6px;font-size:13px;font-weight:700;color:#e2e8f0;white-space:nowrap}
#wm-nasa-counter{font-size:11px;color:#64748b;white-space:nowrap}
#wm-nasa-counter strong{color:#3b82f6}
#wm-nasa-main{flex:1;display:flex;flex-direction:row-reverse;overflow:hidden}
#wm-nasa-map-wrap{flex:1;position:relative}
#wm-nasa-map{width:100%;height:100%}
#wm-nasa-table-wrap{width:290px;flex-shrink:0;display:flex;flex-direction:column;border-left:1px solid #1e3a5a;background:#060c14;direction:rtl}
#wm-nasa-table-head{display:flex;padding:6px 10px;font-size:10px;font-weight:700;color:#475569;border-bottom:1px solid #1e3a5a;background:#0a1520}
#wm-nasa-table-scroll{flex:1;overflow-y:auto;scrollbar-width:thin;scrollbar-color:#1e3a5a transparent}
.wm-nasa-row{display:flex;align-items:flex-start;padding:8px 10px;border-bottom:1px solid rgba(30,58,90,0.4);gap:7px;font-size:11px;cursor:pointer;transition:background .15s;direction:rtl}
.wm-nasa-row:hover{background:rgba(30,58,90,0.3)}
.wm-nasa-row .nasa-icon{font-size:18px;flex-shrink:0;margin-top:1px}
.wm-nasa-row .nasa-title{flex:2;color:#c8dff0;line-height:1.5;text-align:right}
.wm-nasa-row .nasa-type{flex:0.9;font-size:10px;font-weight:700;text-align:center;padding-top:2px}
.wm-nasa-row .nasa-date{flex:0.7;text-align:center;color:#475569;font-size:10px;padding-top:2px}
#wm-nasa-legend{display:flex;align-items:center;gap:10px;padding:5px 14px;background:#060c14;border-top:1px solid #1e3a5a;flex-shrink:0;direction:rtl;font-size:10px;color:#475569}
/* NASA pulse for severe events */
.wm-nasa-pulse-severe{animation:nasa-sev-pulse 1.5s ease-in-out infinite}
@keyframes nasa-sev-pulse{0%,100%{opacity:1}50%{opacity:0.4}}

/* ══ NeoWs Overlay — الكويكبات القريبة من الأرض ══ */
#wm-neows-overlay{display:none;position:absolute;inset:0;z-index:800;flex-direction:column;background:#060c14;font-family:var(--wm-font-ar,sans-serif)}
#wm-neows-overlay.active{display:flex}
#wm-neows-bar{display:flex;align-items:center;gap:8px;padding:0 12px;height:46px;direction:rtl;background:#0a1520;border-bottom:1px solid #1e3a5a;flex-shrink:0;overflow-x:auto;scrollbar-width:none}
#wm-neows-bar::-webkit-scrollbar{display:none}
.wm-neows-logo{display:flex;align-items:center;gap:6px;font-size:13px;font-weight:700;color:#e2e8f0;white-space:nowrap}
#wm-neows-counter{font-size:11px;color:#64748b;white-space:nowrap}
#wm-neows-main{flex:1;display:flex;flex-direction:row-reverse;overflow:hidden}
/* رسم بياني */
#wm-neows-viz-wrap{flex:1;position:relative;display:flex;flex-direction:column;align-items:center;justify-content:center;background:radial-gradient(ellipse at center,#0d1b2a 0%,#060c14 70%);overflow:hidden}
#wm-neows-viz-title{font-size:11px;color:#475569;position:absolute;top:10px;right:0;left:0;text-align:center}
#wm-neows-canvas{width:100%;height:100%}
#wm-neows-earth-label{position:absolute;bottom:20px;left:50%;transform:translateX(-50%);font-size:22px}
/* جدول */
#wm-neows-table-wrap{width:360px;flex-shrink:0;display:flex;flex-direction:column;border-left:1px solid #1e3a5a;background:#060c14;direction:rtl}
#wm-neows-table-head{display:flex;align-items:center;padding:7px 10px;font-size:10px;font-weight:700;color:#475569;border-bottom:1px solid #1e3a5a;background:#0a1520;direction:rtl}
#wm-neows-scroll{flex:1;overflow-y:auto;scrollbar-width:thin;scrollbar-color:#1e3a5a transparent}
.wm-neo-row{display:flex;align-items:center;padding:8px 10px;border-bottom:1px solid rgba(30,58,90,0.4);gap:5px;font-size:11px;cursor:pointer;transition:background .15s;direction:rtl}
.wm-neo-row:hover{background:rgba(30,58,90,0.3)}
.wm-neo-row.hazardous{border-right:3px solid var(--wm-red)}
.wm-neo-row.hazardous:hover{background:rgba(239,68,68,0.08)}
.neo-name{flex:2;font-weight:600;text-align:right;line-height:1.4}
.neo-name .neo-badge{display:inline-block;font-size:9px;padding:1px 5px;border-radius:8px;font-weight:700;margin-right:4px}
.neo-diam{flex:1;text-align:center;color:#94a3b8}
.neo-dist{flex:1;text-align:center;font-weight:700}
.neo-spd{flex:1;text-align:center;color:#64748b}
.neo-date{flex:0.8;text-align:center;color:#334155;font-size:10px}
#wm-neows-legend{display:flex;align-items:center;gap:12px;padding:5px 14px;background:#060c14;border-top:1px solid #1e3a5a;flex-shrink:0;direction:rtl;font-size:10px;color:#64748b}

/* ══ Country Intelligence Panel — قسم استخباراتي في الـ Location Popup ══ */
.wm-loc-intel {
    background: rgba(30,58,90,0.15);
    border: 1px solid rgba(30,58,90,0.4);
    border-radius: 8px;
    padding: 10px;
    margin-bottom: 8px;
}
.wm-loc-intel-row {
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 5px 0;
    border-bottom: 1px solid rgba(30,58,90,0.2);
    direction: rtl;
}
.wm-loc-intel-row:last-child { border-bottom: none; }
.wm-loc-intel-icon { font-size: 14px; flex-shrink: 0; }
.wm-loc-intel-label { font-size: 11px; color: #64748b; flex: 1; }
.wm-loc-intel-val { font-size: 11px; font-weight: 700; text-align: left; white-space: nowrap; }
.wm-loc-tension-bar {
    height: 4px;
    background: rgba(30,58,90,0.3);
    border-radius: 3px;
    margin: 2px 0 6px;
    overflow: hidden;
}

