
/* ── Page Loading Screen ── */
body.wm-loading * { visibility: hidden !important; }
body.wm-loading #wm-wrap { visibility: visible !important; }

#wm-page-loader {
    position: fixed;
    inset: 0;
    background: #060c14;
    z-index: 99999;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    transition: opacity 0.4s ease;
}
#wm-page-loader.fade-out {
    opacity: 0;
    pointer-events: none;
}
.wm-loader-logo {
    font-size: 18px;
    font-weight: 900;
    color: #fff;
    letter-spacing: 2px;
    margin-bottom: 20px;
}
.wm-loader-bar {
    width: 200px;
    height: 3px;
    background: #1e3a5a;
    border-radius: 2px;
    overflow: hidden;
}
.wm-loader-fill {
    height: 100%;
    background: linear-gradient(90deg, #3b82f6, #60a5fa);
    border-radius: 2px;
    animation: wm-load 1.5s ease-in-out infinite;
}
@keyframes wm-load {
    0%   { width: 0%; margin-left: 0; }
    50%  { width: 70%; margin-left: 15%; }
    100% { width: 0%; margin-left: 100%; }
}
.wm-loader-text {
    margin-top: 12px;
    font-size: 11px;
    color: #3a5a76;
    letter-spacing: 1px;
}
/* =============================================
   عربي رادار — Frontend CSS
   Dark Intelligence Dashboard Aesthetic
   ============================================= */

@import url('https://fonts.googleapis.com/css2?family=Share+Tech+Mono&family=Noto+Kufi+Arabic:wght@300;400;600;700&family=Rajdhani:wght@400;600;700&display=swap');

:root {
  --wm-bg:         #060c14;
  --wm-bg2:        #0d1a2a;
  --wm-bg3:        #111e2e;
  --wm-border:     #1e3a5a;
  --wm-accent:     #00d4ff;
  --wm-accent2:    #0070b4;
  --wm-text:       #c8dff0;
  --wm-text-dim:   #5a7a96;
  --wm-red:        #ef4444;
  --wm-orange:     #f97316;
  --wm-yellow:     #eab308;
  --wm-blue:       #3b82f6;
  --wm-green:      #22c55e;
  --wm-font-mono:  'Share Tech Mono', monospace;
  --wm-font-ar:    'Noto Kufi Arabic', sans-serif;
  --wm-font-hd:    'Rajdhani', sans-serif;
}

* { box-sizing: border-box; margin: 0; padding: 0; }

#wm-root {
  font-family: var(--wm-font-ar);
  background: var(--wm-bg);
  color: var(--wm-text);
  direction: rtl;
  position: relative;
}

/* Header القديم — مخفي في التصميم الجديد */
.wm-header { display: none; }
.wm-layout { display: none; }
.wm-map-wrap { display: none; }
.wm-tabs:not(#wm-tabs-bar) { display: none; }
#wm-tension-bar { display: none; }

/* ── Header ── (kept for compatibility) */
.wm-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 10px 16px;
  background: linear-gradient(135deg, #060c14 0%, #0d1a2a 100%);
  border-bottom: 1px solid var(--wm-border);
  position: relative;
  overflow: hidden;
}
.wm-header::before {
  content: '';
  position: absolute;
  top: 0; left: -100%;
  width: 60%;
  height: 100%;
  background: linear-gradient(90deg, transparent, rgba(0,212,255,0.05), transparent);
  animation: wm-scan 4s linear infinite;
}
@keyframes wm-scan { to { left: 200%; } }

.wm-logo {
  font-family: var(--wm-font-hd);
  font-size: 20px;
  font-weight: 700;
  color: var(--wm-accent);
  letter-spacing: 3px;
  text-transform: uppercase;
}
.wm-logo span { color: #fff; }

.wm-controls {
  display: flex;
  align-items: center;
  gap: 12px;
  font-family: var(--wm-font-mono);
  font-size: 13px;
  color: var(--wm-text-dim);
}
.wm-live-dot {
  width: 8px; height: 8px;
  border-radius: 50%;
  background: var(--wm-green);
  box-shadow: 0 0 8px var(--wm-green);
  animation: wm-pulse 2s ease infinite;
}
@keyframes wm-pulse {
  0%,100% { opacity: 1; }
  50%      { opacity: 0.3; }
}
#wm-refresh {
  background: none;
  border: 1px solid var(--wm-border);
  color: var(--wm-accent);
  width: 30px; height: 30px;
  border-radius: 4px;
  cursor: pointer;
  font-size: 16px;
  transition: all .2s;
}
#wm-refresh:hover { background: var(--wm-accent); color: #000; }
#wm-refresh.spinning { animation: wm-spin 1s linear infinite; }
@keyframes wm-spin { to { transform: rotate(360deg); } }

/* ── Tabs ── */
.wm-tabs {
  display: flex;
  gap: 2px;
  padding: 8px 12px;
  background: var(--wm-bg2);
  border-bottom: 1px solid var(--wm-border);
  overflow-x: auto;
  scrollbar-width: thin;
}
.wm-tab {
  background: transparent;
  border: 1px solid transparent;
  color: var(--wm-text-dim);
  padding: 5px 14px;
  border-radius: 3px;
  cursor: pointer;
  font-size: 13px;
  font-family: var(--wm-font-ar);
  white-space: nowrap;
  transition: all .2s;
}
.wm-tab:hover { color: var(--wm-text); border-color: var(--wm-border); }
.wm-tab.active {
  background: var(--wm-accent2);
  border-color: var(--wm-accent);
  color: #fff;
}

/* ══════════════════════════════════════════════════
   v4.0 — FULLSCREEN MAP + FLOATING SIDEBAR
   مستوحى من world-monitor.com
══════════════════════════════════════════════════ */

#wm-root {
  font-family: var(--wm-font-ar);
  color: var(--wm-text);
  direction: rtl;
  position: relative;
  width: 100%;
  height: 100vh;
  overflow: visible;
  background: var(--wm-bg);
}

/* ── الخريطة fixed تملأ كل الشاشة ── */
#wm-map-fullscreen {
  position: fixed;
  inset: 0;
  width: 100%;
  height: 100%;
  z-index: 10;
}
#wm-map {
  width: 100%;
  height: 100%;
  background: var(--wm-bg);
}

/* Dark map tiles */
.leaflet-tile { filter: brightness(0.65) saturate(0.4) hue-rotate(195deg); }
.leaflet-container { background: #060c14 !important; }

/* ── Topbar — شريط علوي ── */
#wm-topbar {
  position: absolute;
  top: 0;
  left: 420px; /* يبدأ بعد الـ sidebar */
  right: 60px; /* مسافة عن الـ dock */
  z-index: 900;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding: 8px 14px;
  background: rgba(6,12,20,0.85);
  border-bottom: 1px solid rgba(30,58,90,0.5);
  backdrop-filter: blur(10px);
  transition: left .3s;
}
#wm-sidebar.wm-sidebar-closed ~ * #wm-topbar,
body.wm-sb-closed #wm-topbar { left: 0; }

.wm-topbar-logo {
  font-family: var(--wm-font-hd);
  font-size: 16px;
  font-weight: 700;
  color: var(--wm-accent);
  letter-spacing: 2px;
  text-transform: uppercase;
  white-space: nowrap;
  flex-shrink: 0;
}
.wm-topbar-logo span { color: #fff; }

.wm-topbar-center {
  flex: 1;
  display: flex;
  justify-content: center;
  overflow: hidden;
}

/* Tabs في التوبار — مضغوطة */
#wm-tabs-bar {
  display: flex;
  gap: 2px;
  background: rgba(13,26,42,0.6);
  border: 1px solid rgba(30,58,90,0.5);
  border-radius: 5px;
  padding: 2px;
  overflow-x: auto;
  scrollbar-width: none;
}
#wm-tabs-bar::-webkit-scrollbar { display: none; }
#wm-tabs-bar .wm-tab {
  font-size: 11px;
  padding: 3px 10px;
  border-radius: 4px;
  white-space: nowrap;
}

.wm-topbar-right {
  display: flex;
  align-items: center;
  gap: 6px;
  flex-shrink: 0;
  padding-right: 8px;
}
.wm-topbar-count {
  font-family: var(--wm-font-mono);
  font-size: 12px;
  color: var(--wm-accent);
  white-space: nowrap;
  background: rgba(0,212,255,0.08);
  border: 1px solid rgba(0,212,255,0.2);
  border-radius: 4px;
  padding: 3px 8px;
}
.wm-tb-btn {
  background: rgba(13,26,42,0.7);
  border: 1px solid var(--wm-border);
  color: var(--wm-text-dim);
  width: 34px; height: 34px;
  border-radius: 6px;
  cursor: pointer;
  font-size: 16px;
  transition: all .2s;
  backdrop-filter: blur(4px);
  display: flex; align-items: center; justify-content: center;
  position: relative;
}
.wm-tb-btn:hover { background: rgba(0,212,255,0.12); border-color: var(--wm-accent); color: var(--wm-accent); }
.wm-tb-active { border-color: var(--wm-accent) !important; color: var(--wm-accent) !important; background: rgba(0,212,255,0.1) !important; }

/* ── Layer Dock — عمود أيقونات يمين الشاشة ── */
#wm-layer-dock {
  position: absolute;
  right: 0;
  top: 0;
  bottom: 0;
  width: 52px;
  z-index: 900;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 3px;
  background: rgba(6,12,20,0.92);
  border-left: 1px solid var(--wm-border);
  padding: 54px 0 40px; /* أعلى: تحت topbar | أسفل: فوق breaking bar */
  backdrop-filter: blur(10px);
  overflow-y: auto;
  scrollbar-width: none;
  pointer-events: all;
}
#wm-layer-dock::-webkit-scrollbar { display: none; }
.wm-ld-btn {
  width: 38px; height: 38px;
  background: transparent;
  border: 1px solid transparent;
  color: var(--wm-text-dim);
  border-radius: 7px;
  cursor: pointer;
  font-size: 17px;
  transition: all .2s;
  display: flex; align-items: center; justify-content: center;
  flex-shrink: 0;
}
.wm-ld-btn:hover {
  background: rgba(0,212,255,0.1);
  color: var(--wm-text);
  border-color: rgba(30,58,90,0.8);
}
.wm-ld-btn.active {
  background: rgba(0,212,255,0.14);
  border-color: var(--wm-accent);
  color: var(--wm-accent);
}
.wm-ld-sep {
  width: 28px; height: 1px;
  background: var(--wm-border);
  margin: 3px 0;
  flex-shrink: 0;
}

/* ── HUD — DEFCON + عدادات أسفل يمين ── */
#wm-map-hud {
  position: absolute;
  bottom: 40px; /* 32px ارتفاع الشريط + 8px هامش */
  right: 60px;
  z-index: 460; /* فوق الشريط العاجل */
  display: flex;
  align-items: flex-end;
}
.wm-hud-counts {
  display: flex;
  align-items: center;
  gap: 4px;
  background: rgba(6,12,20,0.88);
  border: 1px solid rgba(255,255,255,0.08);
  border-radius: 10px;
  padding: 6px 8px;
  backdrop-filter: blur(10px);
  flex-wrap: nowrap;
}
/* فاصل بين DEFCON والعدادات */
.wm-hud-sep {
  width: 1px;
  height: 38px;
  background: rgba(255,255,255,0.1);
  margin: 0 4px;
  flex-shrink: 0;
}
/* عدادات التهديد */
#wm-map-hud .wm-threat {
  padding: 4px 7px;
  min-width: 40px;
  border-radius: 6px;
  background: rgba(255,255,255,0.04);
  border: 1px solid rgba(255,255,255,0.06);
}
#wm-map-hud .wm-threat span { font-size: 14px; }
#wm-map-hud .wm-threat small { font-size: 9px; }

/* ── Legend — أسفل يسار (مع مراعاة الـ sidebar) ── */
.wm-legend {
  position: absolute;
  bottom: 40px; /* فوق شريط الأخبار العاجلة */
  left: 328px; /* بعد الـ sidebar */
  background: rgba(6,12,20,0.88);
  border: 1px solid var(--wm-border);
  border-radius: 8px;
  padding: 8px 12px;
  z-index: 400;
  font-size: 11px;
  backdrop-filter: blur(8px);
  transition: left .3s;
}
.wm-legend-item {
  display: flex;
  align-items: center;
  gap: 7px;
  margin: 3px 0;
}
.wm-legend-item span {
  width: 10px; height: 10px;
  border-radius: 50%;
  display: inline-block;
  flex-shrink: 0;
}

/* ── SIDEBAR العائم — يسار ── */
#wm-sidebar {
  position: absolute;
  top: 0; left: 0; bottom: 0;
  width: 420px;
  height: 100%;
  z-index: 500;
  background: rgba(6,12,22,0.98);
  border-right: 1px solid rgba(30,58,90,0.7);
  display: flex;
  flex-direction: column;
  backdrop-filter: blur(16px);
  transform: translateX(0);
  transition: transform .3s cubic-bezier(.4,0,.2,1);
  overflow: hidden;
  box-shadow: 6px 0 32px rgba(0,0,0,0.5);
}
#wm-sidebar.wm-sidebar-closed { transform: translateX(-100%); }

/* ══ رأس الـ Sidebar ══ */
.wm-sb-top {
  order: 1;
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 10px 12px 8px;
  border-bottom: 1px solid rgba(30,58,90,0.6);
  background: rgba(5,10,18,0.8);
  gap: 8px;
}
.wm-sb-brand {
  display: flex;
  align-items: center;
  gap: 8px;
  min-width: 0;
}
.wm-sb-brand-dot {
  width: 7px; height: 7px;
  border-radius: 50%;
  background: #22c55e;
  flex-shrink: 0;
  box-shadow: 0 0 6px #22c55e;
  animation: wm-conn-pulse-ok 2s ease-in-out infinite;
}
.wm-sb-brand-title {
  font-size: 13px;
  font-weight: 700;
  color: #e2e8f0;
  letter-spacing: 0.5px;
  font-family: var(--wm-font-hd);
}
.wm-sb-brand-count {
  font-size: 11px;
  color: #475569;
  background: rgba(30,58,90,0.5);
  padding: 2px 7px;
  border-radius: 10px;
  flex-shrink: 0;
}
.wm-sb-top-tools {
  display: flex;
  align-items: center;
  gap: 6px;
  flex-shrink: 0;
}
.wm-sb-close-btn {
  width: 26px; height: 26px;
  background: rgba(239,68,68,0.08);
  border: 1px solid rgba(239,68,68,0.25);
  color: #ef4444;
  border-radius: 6px;
  cursor: pointer;
  font-size: 12px;
  transition: all .2s;
  display: flex; align-items: center; justify-content: center;
  flex-shrink: 0;
}
.wm-sb-close-btn:hover { background: #ef4444; color: #fff; }

/* ══ منطقة المحتوى ══ */
.wm-sb-content {
  order: 2;
  flex: 1;
  min-height: 0;
  overflow: hidden;
  position: relative;
}
.wm-sb-panel {
  position: absolute;
  inset: 0;
  display: none !important;
  flex-direction: column;
  overflow: hidden;
}
.wm-sb-panel.active { display: flex !important; }

/* قائمة الأخبار داخل الـ panel */
.wm-sb-list {
  flex: 1;
  overflow-y: auto;
  scrollbar-width: thin;
  scrollbar-color: #1e3a5a transparent;
}
.wm-sb-list::-webkit-scrollbar { width: 4px; }
.wm-sb-list::-webkit-scrollbar-track { background: transparent; }
.wm-sb-list::-webkit-scrollbar-thumb { background: #1e3a5a; border-radius: 2px; }

/* فلاتر الأخبار */
.wm-sb-filters {
  flex-shrink: 0;
  border-bottom: 1px solid rgba(30,58,90,0.5);
}

/* ══ شريط التبويبات السفلي ══ */
.wm-sb-tabs {
  display: flex;
  flex-shrink: 0;
  background: rgba(5,10,18,0.95);
  border-top: 1px solid rgba(30,58,90,0.6);
  height: 54px;
  overflow-x: auto;
  overflow-y: hidden;
  scrollbar-width: none;
  -ms-overflow-style: none;
  scroll-behavior: smooth;
}
.wm-sb-tabs::-webkit-scrollbar { display: none; }
.wm-sbt {
  flex: 0 0 auto;
  min-width: 58px;
  background: none;
  border: none;
  color: #475569;
  cursor: pointer;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 3px;
  padding: 6px 6px;
  transition: all .2s;
  position: relative;
  font-family: var(--wm-font-ar);
  border-top: 2px solid transparent;
}
.wm-sbt:hover { color: #94a3b8; background: rgba(255,255,255,0.03); }
.wm-sbt.active {
  color: var(--wm-accent);
  border-top-color: var(--wm-accent);
  background: rgba(37,99,235,0.08);
}
.wm-sbt-icon  { font-size: 17px; line-height: 1; }
.wm-sbt-label { font-size: 10px; white-space: nowrap; }
.wm-sbt-badge {
  position: absolute;
  top: 5px; left: 50%;
  transform: translateX(6px);
  background: #ef4444;
  color: #fff;
  font-size: 9px;
  font-weight: 700;
  border-radius: 8px;
  padding: 1px 4px;
  min-width: 14px;
  text-align: center;
  display: none;
}
.wm-sbt-badge:not(:empty) { display: block; }

/* إخفاء العناصر القديمة */
.wm-sb-nav     { display: none; }
.wm-sb-body    { display: none; }
.wm-sb-toprow  { display: none; }
.wm-panel-tabs { display: none; }
.wm-sb-header  { display: contents; }


/* ── Layer dock labels ── */
.wm-ld-label {
  font-size: 9px;
  color: var(--wm-text-dim);
  text-transform: uppercase;
  letter-spacing: 0.5px;
  padding: 2px 0;
  text-align: center;
  width: 100%;
}

/* ── HUD counts — نص واضح ── */
#wm-map-hud .wm-threat {
  min-width: 42px;
  padding: 4px 6px;
}
#wm-map-hud .wm-threat span {
  font-size: 15px;
  font-weight: 700;
}
#wm-map-hud .wm-threat small {
  font-size: 9px;
  display: block;
  margin-top: 1px;
}
#wm-search {
  background: var(--wm-bg);
  border: 1px solid var(--wm-border);
  color: var(--wm-text);
  padding: 4px 10px;
  border-radius: 4px;
  font-size: 12px;
  font-family: var(--wm-font-ar);
  width: 150px;
  direction: rtl;
}
#wm-search:focus { outline: none; border-color: var(--wm-accent); }

.wm-filter-row {
  padding: 8px 12px;
  display: flex;
  gap: 8px;
  border-bottom: 1px solid var(--wm-border);
}
.wm-filter-row select {
  flex: 1;
  background: var(--wm-bg);
  border: 1px solid var(--wm-border);
  color: var(--wm-text);
  padding: 4px 8px;
  border-radius: 4px;
  font-size: 12px;
  font-family: var(--wm-font-ar);
}

#wm-news-list {
  flex: 1;
  overflow-y: auto;
  overflow-x: hidden;
  scrollbar-width: thin;
  scrollbar-color: var(--wm-border) transparent;
  min-height: 0;
}

/* ══ News Item Card — تصميم v3 ══ */
.wm-news-item {
  padding: 10px 14px 10px 10px;
  border-bottom: 1px solid rgba(15,30,50,0.7);
  cursor: pointer;
  transition: background .18s;
  position: relative;
  box-sizing: border-box;
  width: 100%;
  overflow: hidden;
  border-right: 3px solid transparent;
}
.wm-news-item:hover { background: rgba(37,99,235,0.07); }
.wm-news-item.highlighted { background: rgba(0,212,255,0.06); }

/* ── Intel Card (wm-item) ── */
.wm-item {
  padding: 10px 14px 10px 10px;
  border-bottom: 1px solid rgba(30,41,59,0.8);
  border-right: 3px solid #475569;
  cursor: pointer;
  transition: background .15s;
  position: relative;
  box-sizing: border-box;
  width: 100%;
  overflow: hidden;
}
.wm-item:hover { background: rgba(255,255,255,0.03); }
.wm-item:last-child { border-bottom: none; }

/* العنوان — أكبر وأوضح */
.wm-item-title {
  font-size: 13.5px;
  line-height: 1.6;
  color: #e2e8f0;
  margin-bottom: 7px;
  word-break: break-word;
  white-space: normal;
  font-weight: 600;
}

/* الشريط السفلي: مصدر + وقت + شارات */
.wm-item-foot {
  display: flex;
  align-items: center;
  gap: 6px;
  flex-wrap: wrap;
}
.wm-item-src-meta {
  font-size: 10.5px;
  color: #64748b;
  flex-shrink: 0;
  max-width: 45%;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.wm-item-time {
  font-size: 10px;
  color: #475569;
  font-family: var(--wm-font-mono);
  margin-right: auto;
}
.wm-score-badge {
  flex-shrink: 0;
  font-family: var(--wm-font-mono);
  font-size: 10px;
  font-weight: 700;
  padding: 1px 6px;
  border-radius: 4px;
  letter-spacing: 0.3px;
}

/* شارة الخطورة القديمة — للتوافق */
.wm-item-score {
  flex-shrink: 0;
  font-family: var(--wm-font-mono);
  font-size: 10px;
  font-weight: 700;
  padding: 2px 7px;
  border-radius: 20px;
  color: #fff;
}
.wm-item-top {
  display: flex;
  align-items: center;
  gap: 6px;
  margin-bottom: 5px;
}
.wm-item-src {
  flex: 1;
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-size: 11px;
  color: #38bdf8;
  font-weight: 600;
}
.wm-item-meta {
  display: flex;
  align-items: center;
  gap: 5px;
  flex-wrap: wrap;
}
.wm-item-desc {
  font-size: 11px;
  color: var(--wm-text-dim);
  line-height: 1.5;
  margin-top: 5px;
}

/* Loading */
.wm-loading {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 40px 20px;
  gap: 16px;
  color: var(--wm-text-dim);
}
.wm-spinner {
  width: 32px; height: 32px;
  border: 2px solid var(--wm-border);
  border-top-color: var(--wm-accent);
  border-radius: 50%;
  animation: wm-spin 0.8s linear infinite;
}

/* Modal */
.wm-modal {
  position: absolute;
  inset: 0;
  background: rgba(6,12,20,0.85);
  z-index: 2000;
  display: flex;
  align-items: center;
  justify-content: center;
  backdrop-filter: blur(4px);
}
.wm-modal.hidden { display: none; }
.wm-modal-box {
  background: var(--wm-bg2);
  border: 1px solid var(--wm-accent);
  border-radius: 8px;
  padding: 24px;
  max-width: 520px;
  width: 90%;
  position: relative;
  box-shadow: 0 0 40px rgba(0,212,255,0.15);
}
.wm-modal-close {
  position: absolute;
  top: 12px;
  left: 12px;
  background: none;
  border: 1px solid var(--wm-border);
  color: var(--wm-text);
  width: 28px; height: 28px;
  border-radius: 4px;
  cursor: pointer;
  font-size: 14px;
}
.wm-modal-close:hover { background: var(--wm-red); border-color: var(--wm-red); }

#wm-modal-content h3 { font-size: 16px; margin-bottom: 12px; line-height: 1.6; }
#wm-modal-content .wm-modal-meta { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 14px; }
#wm-modal-content p { font-size: 13px; color: var(--wm-text-dim); line-height: 1.7; margin-bottom: 14px; }
#wm-modal-content a.wm-read-more {
  display: inline-block;
  padding: 8px 20px;
  background: var(--wm-accent2);
  border: 1px solid var(--wm-accent);
  color: #fff;
  border-radius: 4px;
  text-decoration: none;
  font-size: 13px;
  transition: background .2s;
}
#wm-modal-content a.wm-read-more:hover { background: var(--wm-accent); color: #000; }

/* Leaflet popup override */
.leaflet-popup-content-wrapper {
  background: var(--wm-bg2) !important;
  border: 1px solid var(--wm-border) !important;
  color: var(--wm-text) !important;
  border-radius: 6px !important;
  box-shadow: 0 4px 20px rgba(0,0,0,0.5) !important;
}
.leaflet-popup-tip { background: var(--wm-bg2) !important; }
.leaflet-popup-content { font-family: var(--wm-font-ar); font-size: 13px; direction: rtl; }

/* ── Admin CSS lives in admin.css but we reuse vars ── */
/* ═══════════════════════════════════════════════
   v1.7 — Breaking News + Tension + USGS/GDELT
   ═══════════════════════════════════════════════ */

/* ── Breaking News Bar ───────────────────────── */
#wm-breaking-bar {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 52px; /* لا يغطي الـ layer-dock (عرضه 52px) */
  z-index: 450;
  display: flex;
  align-items: center;
  background: linear-gradient(90deg, rgba(127,29,29,0.95), rgba(153,27,27,0.95));
  border-top: 1px solid #ef4444;
  padding: 0 12px;
  height: 32px;
  overflow: hidden;
  gap: 10px;
  backdrop-filter: blur(4px);
  animation: wm-pulse-bg 2s ease-in-out infinite;
}
@keyframes wm-pulse-bg {
  0%,100% { background: linear-gradient(90deg,#7f1d1d,#991b1b); }
  50%      { background: linear-gradient(90deg,#991b1b,#b91c1c); }
}
.wm-breaking-label {
  flex-shrink: 0;
  font-size: 11px;
  font-weight: 900;
  color: #fff;
  background: #ef4444;
  padding: 2px 8px;
  border-radius: 4px;
  letter-spacing: .5px;
  text-transform: uppercase;
}
.wm-breaking-ticker { flex: 1; overflow: hidden; position: relative; }
.wm-breaking-track {
  display: flex;
  gap: 40px;
  animation: ticker-scroll 30s linear infinite;
  white-space: nowrap;
}
@keyframes ticker-scroll {
  0%   { transform: translateX(0); }
  100% { transform: translateX(-50%); }
}
.wm-breaking-item {
  font-size: 12px;
  color: #fecaca;
  cursor: pointer;
  flex-shrink: 0;
}
.wm-breaking-item:hover { color: #fff; text-decoration: underline; }
.wm-breaking-dot {
  display: inline-block;
  width: 7px; height: 7px;
  border-radius: 50%;
  margin-left: 6px;
  vertical-align: middle;
}
#wm-breaking-close {
  background: none; border: none; color: #fca5a5;
  cursor: pointer; font-size: 14px; flex-shrink: 0;
  padding: 0 8px;
  margin-left: 4px;
}
#wm-breaking-close:hover { color: #fff; }

/* ── Source Layer Toggles ────────────────────── */
.wm-header-center { display: flex; align-items: center; }
.wm-source-toggles { display: flex; gap: 6px; }
.wm-src-btn {
  background: rgba(255,255,255,0.05);
  border: 1px solid var(--wm-border);
  color: #64748b;
  padding: 4px 10px;
  border-radius: 20px;
  font-size: 11px;
  cursor: pointer;
  transition: all .2s;
  font-family: var(--wm-font-ar);
}
.wm-src-btn.active {
  background: rgba(0,180,255,0.15);
  border-color: var(--wm-accent);
  color: var(--wm-accent);
}
.wm-src-btn:hover { border-color: var(--wm-accent); color: var(--wm-accent); }

/* ── Bell Button ─────────────────────────────── */
#wm-breaking-bell {
  position: relative;
  background: none;
  border: 1px solid var(--wm-border);
  color: var(--wm-text);
  padding: 4px 8px;
  border-radius: 6px;
  cursor: pointer;
  font-size: 15px;
  transition: border-color .2s;
}
#wm-breaking-bell:hover { border-color: #ef4444; }
#wm-bell-badge {
  position: absolute;
  top: -4px; right: -4px;
  background: #ef4444;
  color: #fff;
  font-size: 9px;
  width: 16px; height: 16px;
  border-radius: 50%;
  display: flex;
  align-items: center; justify-content: center;
  font-weight: bold;
}

/* ── Tension Meters Bar ──────────────────────── */
#wm-tension-bar {
  background: var(--wm-bg2);
  border-bottom: 1px solid var(--wm-border);
  padding: 6px 14px;
  display: flex;
  align-items: center;
  gap: 10px;
  overflow-x: auto;
  scrollbar-width: none;
}
#wm-tension-bar::-webkit-scrollbar { display: none; }
.wm-tension-title {
  font-size: 10px;
  color: #64748b;
  white-space: nowrap;
  flex-shrink: 0;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: .5px;
}
.wm-tension-items { display: flex; gap: 12px; align-items: center; }
.wm-tension-item {
  display: flex;
  align-items: center;
  gap: 6px;
  flex-shrink: 0;
}
.wm-tension-label {
  font-size: 10px;
  color: #94a3b8;
  white-space: nowrap;
}
.wm-tension-bar-wrap {
  width: 60px;
  height: 5px;
  background: rgba(255,255,255,0.08);
  border-radius: 99px;
  overflow: hidden;
}
.wm-tension-fill {
  height: 100%;
  border-radius: 99px;
  transition: width 1s ease;
}
.wm-tension-score {
  font-size: 11px;
  font-weight: 700;
  min-width: 28px;
}
.wm-tension-score small {
  font-size: 10px;
  margin-right: 1px;
  opacity: .8;
}

/* ── Breaking News Side Panel ────────────────── */
#wm-breaking-panel {
  position: absolute;
  top: 0; left: 0;
  width: 320px;
  height: 100%;
  background: var(--wm-bg);
  border-left: 1px solid #ef4444;
  z-index: 1000;
  display: flex;
  flex-direction: column;
  box-shadow: 4px 0 20px rgba(0,0,0,0.5);
  transition: transform .3s ease;
}
#wm-breaking-panel.hidden {
  display: none;
}
.wm-breaking-panel-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 12px 16px;
  background: #7f1d1d;
  border-bottom: 1px solid #ef4444;
  color: #fff;
  font-weight: 700;
  font-size: 13px;
  flex-shrink: 0;
}
#wm-breaking-panel-close {
  background: none; border: none; color: #fca5a5;
  cursor: pointer; font-size: 16px;
}
#wm-breaking-panel-list {
  flex: 1;
  overflow-y: auto;
  padding: 8px 0;
}
.wm-breaking-entry {
  display: flex;
  gap: 10px;
  padding: 10px 14px;
  border-bottom: 1px solid var(--wm-border);
  cursor: pointer;
  transition: background .15s;
  align-items: flex-start;
}
.wm-breaking-entry:hover { background: var(--wm-bg2); }
.wm-be-dot {
  width: 10px; height: 10px;
  border-radius: 50%;
  flex-shrink: 0;
  margin-top: 4px;
}
.wm-be-body { flex: 1; direction: rtl; }
.wm-be-score {
  font-size: 10px;
  color: #ef4444;
  font-weight: 700;
  margin-bottom: 3px;
}
.wm-be-title {
  font-size: 12px;
  color: var(--wm-text);
  text-decoration: none;
  line-height: 1.5;
  display: block;
}
.wm-be-title:hover { color: var(--wm-accent); }
.wm-be-meta { font-size: 10px; color: #64748b; margin-top: 4px; }

/* ── News Item Enhancements ──────────────────── */
.wm-item-summary {
  font-size: 11px;
  color: #64748b;
  margin: 3px 0 6px;
  line-height: 1.45;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.wm-trend-badge {
  font-size: 10px;
  padding: 1px 7px;
  border-radius: 10px;
  font-weight: 600;
}
.wm-trend-badge.up   { background: rgba(239,68,68,.15);  color: #ef4444; }
.wm-trend-badge.down { background: rgba(34,197,94,.15);  color: #22c55e; }
.wm-geo-badge {
  font-size: 10px;
  opacity: .6;
}

/* ── Earthquake counter box ──────────────────── */
.wm-threat.white span { color: #e2e8f0; }
.wm-threat.white      { background: rgba(255,255,255,0.05); border: 1px solid rgba(255,255,255,.15); }

/* ── Source filter select ────────────────────── */
#wm-source-filter {
  flex: 1;
  background: var(--wm-bg2);
  border: 1px solid var(--wm-border);
  color: var(--wm-text);
  padding: 5px 8px;
  border-radius: 4px;
  font-size: 12px;
  font-family: var(--wm-font-ar);
}

/* ── Spin animation ──────────────────────────── */
@keyframes spin {
  from { transform: rotate(0deg); }
  to   { transform: rotate(360deg); }
}

/* ── Responsive ──────────────────────────────── */
/* ── Country Filter Bar ──────────────────────── */
#wm-country-bar {
  background: var(--wm-bg2);
  border-bottom: 1px solid var(--wm-border);
  padding: 6px 10px;
  display: flex;
  align-items: center;
  gap: 5px;
  flex-wrap: wrap;
  overflow-x: auto;
  scrollbar-width: none;
}
#wm-country-bar::-webkit-scrollbar { display: none; }
.wm-country-label {
  font-size: 14px;
  flex-shrink: 0;
  opacity: .6;
  margin-left: 4px;
}
.wm-country-btn {
  background: rgba(255,255,255,0.04);
  border: 1px solid var(--wm-border);
  color: #94a3b8;
  padding: 3px 10px;
  border-radius: 20px;
  font-size: 11px;
  cursor: pointer;
  white-space: nowrap;
  transition: all .18s;
  font-family: var(--wm-font-ar);
  display: inline-flex;
  align-items: center;
  gap: 3px;
}
.wm-country-btn:hover {
  border-color: var(--wm-accent);
  color: var(--wm-accent);
  background: rgba(0,180,255,0.08);
}
.wm-country-btn.active {
  background: rgba(0,180,255,0.2);
  border-color: var(--wm-accent);
  color: #fff;
  font-weight: 600;
  box-shadow: 0 0 8px rgba(0,180,255,0.3);
}
.wm-country-clear {
  background: rgba(239,68,68,0.1) !important;
  border-color: #ef4444 !important;
  color: #ef4444 !important;
  font-weight: 600;
}
.wm-country-clear:hover {
  background: rgba(239,68,68,0.2) !important;
}
/* ══════════════════════════════════════════════════
   بطاقة الوضع العالمي
══════════════════════════════════════════════════ */
#wm-status-card {
  background: linear-gradient(135deg, #0f172a 0%, #1e293b 100%);
  border-bottom: 1px solid #334155;
  padding: 10px 14px;
  display: block;
}
/* البطاقة بعد اكتمال البيانات */
#wm-status-card.wm-sc-visible #wm-status-loading { display: none; }
.wm-sc-header {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 8px;
}
.wm-sc-icon { font-size: 22px; flex-shrink: 0; }
.wm-sc-title { font-size: 10px; color: #64748b; text-transform: uppercase; letter-spacing: 1px; }
.wm-sc-level { font-size: 16px; font-weight: 700; line-height: 1.2; }
.wm-sc-stats {
  margin-right: auto;
  display: flex;
  gap: 10px;
  font-size: 12px;
  color: #94a3b8;
}
.wm-sc-stats span { cursor: default; }
.wm-sc-events { display: flex; flex-direction: column; gap: 4px; margin-bottom: 8px; }
.wm-sc-event {
  display: flex;
  align-items: center;
  gap: 7px;
  font-size: 12px;
  color: #cbd5e1;
  background: rgba(255,255,255,0.03);
  padding: 4px 8px;
  border-radius: 5px;
}
.wm-sc-dot {
  width: 7px; height: 7px;
  border-radius: 50%;
  flex-shrink: 0;
}
.wm-sc-badge {
  margin-right: auto;
  font-size: 10px;
  font-weight: 700;
  color: #fff;
  padding: 1px 5px;
  border-radius: 3px;
  flex-shrink: 0;
}
.wm-sc-regions {
  display: flex;
  gap: 6px;
  flex-wrap: wrap;
  margin-bottom: 6px;
}
.wm-sc-region {
  background: rgba(255,255,255,0.06);
  border: 1px solid #334155;
  color: #94a3b8;
  font-size: 11px;
  padding: 2px 8px;
  border-radius: 12px;
}
.wm-sc-region small { color: #f97316; font-weight: 700; margin-right: 2px; }
.wm-sc-footer { font-size: 10px; color: #475569; text-align: left; }
#wm-status-loading {
  display: flex;
  align-items: center;
  gap: 8px;
  color: #64748b;
  font-size: 12px;
  padding: 4px 0;
}
.wm-status-spinner {
  width: 14px; height: 14px;
  border: 2px solid #334155;
  border-top-color: #38bdf8;
  border-radius: 50%;
  animation: wm-spin 0.8s linear infinite;
  flex-shrink: 0;
}

/* ══════════════════════════════════════════════════
   Magnitude Badge
══════════════════════════════════════════════════ */
.wm-mag-badge {
  display: inline-block;
  background: linear-gradient(135deg, #ef4444, #dc2626);
  color: #fff;
  font-size: 10px;
  font-weight: 900;
  padding: 1px 5px;
  border-radius: 4px;
  margin-left: 4px;
  letter-spacing: 0.5px;
  vertical-align: middle;
}

/* ══════════════════════════════════════════════════
   Marker Clustering
══════════════════════════════════════════════════ */
/* ══════════════════════════════════════════════════
   v4.2 — Cluster Redesign — حلقات + توهج
══════════════════════════════════════════════════ */

/* Leaflet icon container */
.wm-cluster-icon {
  overflow: visible !important;
  background: transparent !important;
  border: none !important;
}

/* الدائرة الأساسية مع حلقة نابضة عبر ::before */
.wm-cluster {
  width: 100%; height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  color: #fff;
  font-family: 'Share Tech Mono', monospace;
  font-weight: 700;
  transition: transform .2s, box-shadow .2s;
  position: relative;
  overflow: visible;

  background: radial-gradient(circle at 35% 35%, rgba(255,90,90,0.95), rgba(180,20,20,0.92));
  border: 2px solid rgba(255,130,130,0.45);
  box-shadow: 0 0 14px rgba(239,68,68,0.55), 0 2px 6px rgba(0,0,0,0.4);
}
.wm-cluster::before {
  content: '';
  position: absolute;
  inset: -6px;
  border-radius: 50%;
  border: 2px solid rgba(239,68,68,0.5);
  animation: wm-cluster-pulse 2.4s ease-out infinite;
  pointer-events: none;
}
@keyframes wm-cluster-pulse {
  0%   { transform: scale(1);   opacity: 0.5; }
  70%  { transform: scale(1.6); opacity: 0;   }
  100% { transform: scale(1.6); opacity: 0;   }
}
.wm-cluster:hover {
  transform: scale(1.12);
  box-shadow: 0 0 22px rgba(239,68,68,0.75);
}

/* زلازل — أصفر */
.wm-cluster-eq {
  background: radial-gradient(circle at 35% 35%, rgba(255,215,60,0.95), rgba(180,120,0,0.92));
  border: 2px solid rgba(250,200,60,0.5);
  box-shadow: 0 0 14px rgba(234,179,8,0.55), 0 2px 6px rgba(0,0,0,0.4);
  color: #1a0e00;
}
.wm-cluster-eq::before { border-color: rgba(234,179,8,0.5); }
.wm-cluster-eq:hover { box-shadow: 0 0 22px rgba(234,179,8,0.75); }

/* GDELT — أزرق */
.wm-cluster-gdelt {
  background: radial-gradient(circle at 35% 35%, rgba(100,165,255,0.95), rgba(30,70,190,0.92));
  border: 2px solid rgba(100,160,255,0.5);
  box-shadow: 0 0 14px rgba(59,130,246,0.55), 0 2px 6px rgba(0,0,0,0.4);
  color: #fff;
}
.wm-cluster-gdelt::before { border-color: rgba(59,130,246,0.5); }
.wm-cluster-gdelt:hover { box-shadow: 0 0 22px rgba(59,130,246,0.75); }

/* أحجام */
.wm-cluster-sm { font-size: 11px; }
.wm-cluster-md { font-size: 13px; }
.wm-cluster-lg { font-size: 14px; font-weight: 900; }
.wm-cluster-xl { font-size: 13px; font-weight: 900; letter-spacing: -0.5px; }


/* ══════════════════════════════════════════════════
   تحسينات قائمة الأخبار
══════════════════════════════════════════════════ */
.wm-item[data-type="earthquake"] {
  background: linear-gradient(to left, rgba(234,179,8,0.04) 0%, transparent 100%);
}
.wm-item[data-type="gdelt"] {
  background: linear-gradient(to left, rgba(59,130,246,0.04) 0%, transparent 100%);
}

/* ══════════════════════════════════════════════════
   صفحة الحدث — Event Page Modal
══════════════════════════════════════════════════ */
.wm-event-page { display:flex; flex-direction:column; gap:14px; }

/* Header */
.wm-ep-header {
  padding: 14px 16px;
  background: rgba(255,255,255,0.03);
  border-radius: 8px;
}
.wm-ep-type { font-size:11px; color:#64748b; margin-bottom:6px; text-transform:uppercase; letter-spacing:1px; }
.wm-ep-title { font-size:16px; font-weight:700; color:#f1f5f9; margin:0 0 8px; line-height:1.5; }
.wm-ep-summary { font-size:13px; color:#94a3b8; margin-bottom:8px; line-height:1.6; border-right:2px solid #334155; padding-right:10px; }
.wm-ep-meta { display:flex; flex-wrap:wrap; gap:10px; font-size:11px; color:#64748b; }

/* مؤشر الخطر */
.wm-ep-risk { background:rgba(255,255,255,0.02); border-radius:8px; padding:12px 14px; }
.wm-ep-risk-label { display:flex; justify-content:space-between; margin-bottom:8px; font-size:12px; color:#94a3b8; }
.wm-ep-risk-score { font-size:18px; font-weight:900; }
.wm-risk-bars { display:flex; gap:3px; height:8px; margin-bottom:6px; }
.wm-risk-bar {
  flex:1; border-radius:2px;
  background: rgba(255,255,255,0.08);
  transition: all .3s;
}
.wm-risk-bar.active { opacity:1; }
.wm-ep-risk-desc { font-size:11px; color:#64748b; }

/* Trend */
.wm-ep-trend { display:flex; align-items:center; gap:10px; }
.wm-trend-badge.large { font-size:13px; padding:4px 12px; }

/* Section */
.wm-ep-section-title { font-size:11px; color:#64748b; text-transform:uppercase; letter-spacing:1px; margin-bottom:8px; }

/* Related */
.wm-ep-related { display:flex; flex-direction:column; gap:4px; }
.wm-ep-rel-item {
  display:flex; align-items:center; gap:8px;
  padding:7px 10px; border-radius:6px;
  background:rgba(255,255,255,0.03);
  cursor:pointer; transition:background .15s;
  border:1px solid transparent;
}
.wm-ep-rel-item:hover { background:rgba(255,255,255,0.07); border-color:#334155; }
.wm-ep-rel-dot { width:6px; height:6px; border-radius:50%; flex-shrink:0; }
.wm-ep-rel-title { flex:1; font-size:12px; color:#cbd5e1; line-height:1.4; }
.wm-ep-rel-score { font-size:11px; font-weight:700; flex-shrink:0; }

/* Actions */
.wm-ep-actions { display:flex; gap:8px; flex-wrap:wrap; padding-top:4px; }
.wm-ep-btn-primary {
  flex:1; padding:10px 16px; border-radius:8px;
  background:linear-gradient(135deg,#0ea5e9,#0284c7);
  color:#fff; font-size:13px; font-weight:600;
  text-decoration:none; text-align:center;
  transition:opacity .2s;
}
.wm-ep-btn-primary:hover { opacity:.85; color:#fff; }
.wm-ep-btn-secondary {
  padding:10px 16px; border-radius:8px;
  background:rgba(255,255,255,0.06); border:1px solid #334155;
  color:#94a3b8; font-size:13px; cursor:pointer;
  transition:all .15s;
}
.wm-ep-btn-secondary:hover { background:rgba(255,255,255,0.1); color:#f1f5f9; }

/* Toast */
#wm-toast {
  position:fixed; bottom:24px; left:50%; transform:translateX(-50%) translateY(20px);
  background:#1e293b; color:#f1f5f9; padding:10px 20px;
  border-radius:8px; font-size:13px; opacity:0;
  transition:all .3s; pointer-events:none; z-index:99999;
  border:1px solid #334155;
}
#wm-toast.show { opacity:1; transform:translateX(-50%) translateY(0); }

/* Modal بحجم أكبر لصفحة الحدث */
.wm-modal-box {
  max-height: 85vh;
  overflow-y: auto;
}

/* ══════════════════════════════════════════════════
   إصلاحات الموبايل الشاملة v1.9.1
══════════════════════════════════════════════════ */
@media (max-width: 600px) {
  /* Header */
  .wm-logo span { display: none; }
  .wm-logo::after { content: '🌍 WM'; font-weight: 700; font-size: 13px; }
  #wm-news-count { display: none; }

  /* Source toggles */
  .wm-source-toggles { gap: 4px; }
  .wm-src-btn { padding: 3px 7px; font-size: 10px; }
  .wm-src-btn span { display: none; }

  /* Tabs */
  .wm-tabs { overflow-x: auto; scrollbar-width: none; flex-wrap: nowrap; }
  .wm-tabs::-webkit-scrollbar { display: none; }
  .wm-tab { white-space: nowrap; padding: 6px 10px; font-size: 11px; flex-shrink: 0; }

  /* Tension bar */
  #wm-tension-bar { overflow-x: auto; flex-wrap: nowrap; scrollbar-width: none; }
  #wm-tension-bar::-webkit-scrollbar { display: none; }
  .wm-tension-item { flex-shrink: 0; min-width: 100px; }
  .wm-tension-title { display: none; }

  /* Status card */
  .wm-sc-stats { gap: 6px; font-size: 11px; }
  .wm-sc-title { display: none; }

  /* Map — ارتفاع أفضل على الموبايل */
  .wm-map-wrap { height: 45vh !important; min-height: 260px !important; }

  /* Panel */
  .wm-panel { height: 40vh !important; min-height: 220px !important; }
  .wm-filter-row { flex-wrap: wrap; gap: 4px; }
  .wm-filter-row select { font-size: 11px; padding: 3px 6px; flex: 1; min-width: 80px; }

  /* News items */
  .wm-item { padding: 8px 10px; }
  .wm-item-title { font-size: 12px; }

  /* Modal */
  .wm-modal-box { width: 95vw !important; max-height: 90vh !important; margin: 5vh auto; }
  .wm-ep-title { font-size: 14px; }
  .wm-ep-actions { flex-direction: column; }
  .wm-ep-btn-primary, .wm-ep-btn-secondary { text-align: center; }

  /* Breaking bar */
  #wm-breaking-bar { height: 30px; }
  .wm-breaking-label { font-size: 10px; padding: 2px 6px; }

  /* ── مدمج من بلوكات 600px السابقة ── */
  #wm-brief-panel { right: 10px; bottom: 200px; width: 220px; }
  .wm-bm-container { max-width: 100%; margin: 0; border-radius: 10px; }
  #wm-ais-legend { left: 10px; bottom: 200px; }
}

/* ══════════════════════════════════════════════════
   v2.0 — ميزات تحسين البيانات وتجربة المستخدم
══════════════════════════════════════════════════ */

/* ── فلتر الوقت ──────────────────────────────── */
.wm-time-filter {
  display: flex;
  gap: 4px;
  padding: 6px 10px;
  border-bottom: 1px solid var(--wm-border);
  flex-wrap: wrap;
  background: var(--wm-bg-2);
  position: relative;
}
.wm-tf-btn {
  background: var(--wm-bg-3);
  border: 1px solid var(--wm-border);
  color: var(--wm-text-2);
  border-radius: 12px;
  padding: 3px 10px;
  font-size: 11px;
  cursor: pointer;
  transition: all 0.2s;
  white-space: nowrap;
}
.wm-tf-btn:hover { background: var(--wm-accent); color: #fff; }
.wm-tf-btn.active { background: var(--wm-accent); color: #fff; border-color: var(--wm-accent); }
#wm-auto-refresh-btn.active { background: #16a34a; border-color: #16a34a; color: #fff; animation: wm-pulse 2s infinite; }

/* ── مخطط التوترات ────────────────────────────── */
#wm-trend-chart {
  background: var(--wm-bg-2);
  border-bottom: 1px solid var(--wm-border);
  padding: 10px;
  animation: wm-slide-down 0.2s ease;
}
@keyframes wm-slide-down { from { opacity:0; transform:translateY(-8px); } to { opacity:1; transform:none; } }
.wm-chart-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 12px;
  color: var(--wm-text-2);
  margin-bottom: 8px;
}
.wm-chart-legend { display: flex; gap: 8px; font-size: 11px; }
.wm-cl-high { color: #ef4444; }
.wm-cl-med  { color: #f97316; }
.wm-chart-bars {
  display: flex;
  align-items: flex-end;
  gap: 2px;
  height: 90px;
  padding-bottom: 18px;
  position: relative;
}
.wm-chart-col {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: flex-end;
  height: 90px;
  cursor: pointer;
  position: relative;
}
.wm-chart-col:hover .wm-chart-bar { opacity: 0.8; }
.wm-chart-col.wm-chart-now .wm-chart-bar { outline: 1px solid #60a5fa; }
.wm-chart-bar {
  width: 100%;
  background: #334155;
  border-radius: 2px 2px 0 0;
  position: relative;
  min-height: 2px;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  overflow: hidden;
  transition: height 0.3s ease;
}
.wm-cb-high { background: #ef4444; width: 100%; }
.wm-cb-med  { background: #f97316; width: 100%; }
.wm-chart-label {
  position: absolute;
  bottom: 0;
  font-size: 9px;
  color: var(--wm-text-3);
  white-space: nowrap;
}

/* ── وضع الطوارئ ──────────────────────────────── */
#wm-emergency-banner {
  display: flex;
  align-items: center;
  gap: 10px;
  background: linear-gradient(90deg, #7f1d1d, #991b1b, #7f1d1d);
  background-size: 200% 100%;
  animation: wm-em-pulse 1s ease-in-out infinite;
  color: #fff;
  padding: 10px 16px;
  font-size: 13px;
  font-weight: 600;
  border-bottom: 2px solid #ef4444;
  z-index: 100;
}
@keyframes wm-em-pulse {
  0%, 100% { background-position: 0% 50%; }
  50%       { background-position: 100% 50%; }
}
.wm-em-icon { font-size: 20px; animation: wm-shake 0.5s infinite; }
@keyframes wm-shake {
  0%, 100% { transform: rotate(0); }
  25%       { transform: rotate(-10deg); }
  75%       { transform: rotate(10deg); }
}
.wm-em-text { flex: 1; direction: rtl; }
.wm-em-close {
  background: rgba(255,255,255,0.2);
  border: none; color: #fff;
  border-radius: 50%; width: 22px; height: 22px;
  cursor: pointer; font-size: 12px;
  display: flex; align-items: center; justify-content: center;
}
#wm-root.wm-emergency #wm-map-wrap {
  box-shadow: 0 0 0 3px #ef4444, 0 0 20px rgba(239,68,68,0.4);
}
#wm-root.wm-emergency .wm-header {
  border-bottom: 2px solid #ef4444;
}

/* ── أزرار المشاركة على الأخبار ──────────────── */
.wm-share-btns {
  display: none;
  gap: 4px;
  margin-top: 4px;
}
.wm-item:hover .wm-share-btns { display: flex; }
.wm-share-btn {
  background: var(--wm-bg-3);
  border: 1px solid var(--wm-border);
  border-radius: 4px;
  padding: 2px 6px;
  cursor: pointer;
  color: var(--wm-text-2);
  font-size: 11px;
  transition: all 0.15s;
  display: flex;
  align-items: center;
  gap: 2px;
}
.wm-share-btn:hover { background: #1d4ed8; color: #fff; border-color: #1d4ed8; }

/* ── قائمة التحديث التلقائي ─────────────────── */
.wm-refresh-menu {
  position: absolute;
  bottom: calc(100% + 4px);
  left: auto;
  right: 6px;
  background: #0d1f35;
  border: 1px solid #1e3a5a;
  border-radius: 8px;
  padding: 6px;
  z-index: 500;
  box-shadow: 0 -4px 20px rgba(0,0,0,0.6);
  min-width: 150px;
  display: flex;
  flex-direction: column;
  gap: 3px;
}
.wm-refresh-menu .wm-rm-title {
  font-size: 11px;
  color: var(--wm-text-3);
  padding: 2px 6px 4px;
  border-bottom: 1px solid var(--wm-border);
  margin-bottom: 2px;
}
.wm-refresh-menu button {
  background: none;
  border: none;
  color: var(--wm-text-1);
  text-align: right;
  padding: 5px 8px;
  border-radius: 5px;
  cursor: pointer;
  font-size: 12px;
  transition: background 0.15s;
}
.wm-refresh-menu button:hover { background: var(--wm-accent); color: #fff; }

/* ── Toast ──────────────────────────────────── */
#wm-toast {
  position: fixed;
  bottom: 24px;
  left: 50%;
  transform: translateX(-50%) translateY(60px);
  background: #1e293b;
  color: #e2e8f0;
  padding: 10px 20px;
  border-radius: 8px;
  font-size: 13px;
  z-index: 9999;
  opacity: 0;
  transition: all 0.3s ease;
  pointer-events: none;
  white-space: nowrap;
  border: 1px solid #334155;
}
#wm-toast.wm-toast-show {
  opacity: 1;
  transform: translateX(-50%) translateY(0);
}

/* ══════════════════════════════════════════════════
   v2.1 — Panel Tabs, Bookmarks, Stats, Groups
   (لا يحتوي على أي media queries أو layout overrides)
══════════════════════════════════════════════════ */

/* ── Panel header: تابات فوق + أدوات تحت ──── */
.wm-panel-header {
  padding: 0 !important;
  flex-direction: column !important;
  align-items: stretch !important;
  gap: 0 !important;
}
.wm-panel-tabs {
  display: flex;
  border-bottom: 1px solid var(--wm-border);
}
.wm-ptab {
  flex: 1;
  background: none;
  border: none;
  border-bottom: 2px solid transparent;
  color: var(--wm-text-dim);
  padding: 9px 2px;
  font-size: 12.5px;
  cursor: pointer;
  transition: all .2s;
  font-family: var(--wm-font-ar);
  white-space: nowrap;
  text-align: center;
}
.wm-ptab:hover  { color: var(--wm-text); background: rgba(255,255,255,0.03); }
.wm-ptab.active { color: var(--wm-accent); border-bottom-color: var(--wm-accent); background: rgba(37,99,235,0.08); }
#wm-bookmark-count {
  font-size: 9px;
  background: var(--wm-accent);
  color: #fff;
  border-radius: 8px;
  padding: 0 4px;
  margin: 0 2px;
  vertical-align: middle;
}
.wm-panel-tools {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 6px 10px;
  border-bottom: 1px solid var(--wm-border);
}
.wm-tool-btn {
  background: var(--wm-bg);
  border: 1px solid var(--wm-border);
  border-radius: 6px;
  padding: 3px 8px;
  cursor: pointer;
  font-size: 13px;
  color: var(--wm-text-dim);
  transition: all .2s;
  flex-shrink: 0;
}
.wm-tool-btn:hover  { background: var(--wm-accent); color: #fff; border-color: var(--wm-accent); }
.wm-tool-btn.active { background: #1d4ed8; color: #fff; border-color: #1d4ed8; }
#wm-search { flex: 1; min-width: 0; }

/* ── Bookmark button ─────────────────────────── */
.wm-bookmark-btn {
  background: none;
  border: none;
  cursor: pointer;
  font-size: 12px;
  padding: 0 2px;
  opacity: 0.35;
  transition: opacity .15s, transform .15s;
  line-height: 1;
  flex-shrink: 0;
}
.wm-bookmark-btn:hover { opacity: 1; transform: scale(1.2); }
.wm-bookmark-btn.saved { opacity: 1; }

/* ── Grouped news ────────────────────────────── */
.wm-group { margin-bottom: 3px; }
.wm-group-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 7px 12px;
  background: rgba(255,255,255,0.03);
  cursor: pointer;
  user-select: none;
  border-bottom: 1px solid var(--wm-border);
}
.wm-group-header:hover { background: rgba(255,255,255,0.06); }
.wm-group-name  { font-size: 12px; font-weight: 700; color: var(--wm-text); }
.wm-group-badges { display: flex; gap: 6px; align-items: center; }
.wm-group-count { font-size: 10px; color: var(--wm-text-dim); }
.wm-group-score { font-size: 10px; font-weight: 700; width: 20px; height: 20px; border-radius: 4px; display: flex; align-items: center; justify-content: center; color: #fff; }
.wm-group-items.collapsed { display: none; }
.wm-grp-more { width: 100%; background: none; border: none; border-top: 1px solid var(--wm-border); color: var(--wm-accent); padding: 5px; font-size: 11px; cursor: pointer; text-align: center; }
.wm-grp-more:hover { background: rgba(37,99,235,0.08); }

/* ── Stats page ──────────────────────────────── */
.wm-stats-page { overflow-y: auto; height: 100%; }
.wm-stat-card { background: var(--wm-bg2); border: 1px solid var(--wm-border); border-radius: 8px; padding: 12px; margin-bottom: 8px; }
.wm-stat-title { font-size: 12px; font-weight: 600; color: var(--wm-text-dim); margin-bottom: 10px; padding-bottom: 6px; border-bottom: 1px solid var(--wm-border); }
.wm-dist-grid { display: grid; grid-template-columns: 1fr 1fr 1fr 1fr; gap: 6px; }
.wm-dist-item { border-radius: 6px; padding: 8px 4px; text-align: center; display: flex; flex-direction: column; gap: 3px; }
.wm-dist-item small { font-size: 9px; color: var(--wm-text-dim); }
.wm-region-cloud { display: flex; flex-wrap: wrap; gap: 5px; }
.wm-region-tag { background: rgba(37,99,235,0.1); border: 1px solid rgba(37,99,235,0.25); border-radius: 20px; padding: 2px 9px; color: var(--wm-text); cursor: default; }
.wm-region-tag small { color: var(--wm-accent); margin-right: 3px; }
.wm-stat-row { display: flex; align-items: center; gap: 8px; margin-bottom: 5px; }
.wm-stat-label { font-size: 11px; color: var(--wm-text-dim); width: 100px; flex-shrink: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.wm-stat-bar-wrap { flex: 1; height: 7px; background: var(--wm-bg); border-radius: 4px; overflow: hidden; }
.wm-stat-bar { height: 100%; background: var(--wm-accent); border-radius: 4px; transition: width .5s; }
.wm-stat-val { font-size: 10px; color: var(--wm-text-dim); width: 28px; text-align: right; }
.wm-hourly-bars { display: flex; align-items: flex-end; gap: 2px; height: 50px; }
.wm-hour-bar { flex: 1; background: var(--wm-accent); border-radius: 2px 2px 0 0; opacity: 0.65; min-height: 2px; }
.wm-hour-bar:hover { opacity: 1; }

/* ── Alerts ──────────────────────────────────── */
.wm-alert-form { display: flex; gap: 6px; flex-wrap: wrap; align-items: center; }
.wm-al-input { background: var(--wm-bg); border: 1px solid var(--wm-border); border-radius: 5px; color: var(--wm-text); padding: 5px 8px; font-size: 12px; font-family: var(--wm-font-ar); }
.wm-alert-item { display: flex; align-items: center; justify-content: space-between; padding: 6px 10px; background: var(--wm-bg); border-radius: 6px; margin-bottom: 4px; font-size: 12px; }
.wm-alert-del { background: none; border: none; color: #ef4444; cursor: pointer; font-size: 13px; padding: 0 4px; }

/* ── Context ─────────────────────────────────── */
.wm-context { margin-top: 5px; padding: 5px 8px; background: rgba(37,99,235,0.05); border-radius: 5px; border: 1px solid rgba(37,99,235,0.12); }
.wm-ctx-title { font-size: 10px; color: var(--wm-accent); display: block; margin-bottom: 3px; }
.wm-ctx-item { display: flex; align-items: flex-start; gap: 5px; padding: 2px 0; font-size: 11px; color: var(--wm-text-dim); cursor: pointer; }
.wm-ctx-item:hover { color: var(--wm-text); }
.wm-ctx-score { font-size: 10px; font-weight: 700; width: 18px; height: 18px; border-radius: 3px; display: flex; align-items: center; justify-content: center; color: #fff; flex-shrink: 0; }

/* ══════════════════════════════════════════════════
   v2.2 — Heatmap, Live Stream, Event Page URL
══════════════════════════════════════════════════ */

/* ── Map controls overlay ────────────────────── */
.wm-map-controls {
  position: absolute;
  top: 10px;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  gap: 6px;
  z-index: 500;
  pointer-events: all;
}
.wm-mc-btn {
  background: rgba(6,12,20,0.88);
  border: 1px solid rgba(255,255,255,0.12);
  color: #cbd5e1;
  padding: 5px 12px;
  border-radius: 20px;
  font-size: 12px;
  cursor: pointer;
  transition: all .2s;
  backdrop-filter: blur(6px);
  white-space: nowrap;
}
.wm-mc-btn:hover { background: rgba(37,99,235,0.7); color: #fff; border-color: #3b82f6; }
.wm-mc-btn.active { background: rgba(239,68,68,0.8); color: #fff; border-color: #ef4444; }
#wm-heatmap-toggle.active { background: rgba(249,115,22,0.8); border-color: #f97316; }

/* ── Heatmap circles ─────────────────────────── */
.wm-heat-circle { transition: opacity 0.5s; }

/* ── Live Stream Panel ───────────────────────── */
#wm-live-stream {
  position: absolute;
  bottom: 177px; /* 145px + 32px (ارتفاع breaking bar) */
  right: 260px;  /* بجانب wm-tension-map-legend */
  width: 240px;
  max-height: 300px;
  background: rgba(6,12,20,0.95);
  border: 1px solid rgba(239,68,68,0.4);
  border-radius: 10px;
  z-index: 999;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  backdrop-filter: blur(8px);
  box-shadow: 0 8px 32px rgba(0,0,0,0.6), 0 0 0 1px rgba(239,68,68,0.1);
  animation: wm-slide-up 0.25s ease;
}
@keyframes wm-slide-up { from { opacity:0; transform:translateY(12px); } to { opacity:1; transform:none; } }

.wm-ls-header {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 8px 12px;
  border-bottom: 1px solid rgba(239,68,68,0.2);
  font-size: 12px;
  font-weight: 600;
  color: #f1f5f9;
  flex-shrink: 0;
}
.wm-ls-dot {
  width: 8px; height: 8px;
  border-radius: 50%;
  background: #ef4444;
  box-shadow: 0 0 8px #ef4444;
  animation: wm-pulse 1s ease infinite;
  flex-shrink: 0;
}
.wm-ls-close {
  margin-right: auto;
  background: none;
  border: none;
  color: #64748b;
  cursor: pointer;
  font-size: 14px;
  padding: 0 4px;
  line-height: 1;
}
.wm-ls-close:hover { color: #fff; }

#wm-ls-feed {
  overflow-y: auto;
  flex: 1;
  scrollbar-width: thin;
  scrollbar-color: #334155 transparent;
}
#wm-ls-feed::-webkit-scrollbar { width: 4px; }
#wm-ls-feed::-webkit-scrollbar-thumb { background: #334155; border-radius: 2px; }

.wm-ls-item {
  padding: 8px 12px;
  border-bottom: 1px solid rgba(255,255,255,0.04);
  cursor: pointer;
  transition: background .15s;
}
.wm-ls-item:hover { background: rgba(255,255,255,0.04); }
.wm-ls-item.wm-ls-new {
  animation: wm-flash-in 2s ease;
  background: rgba(239,68,68,0.08);
}
@keyframes wm-flash-in {
  0%   { background: rgba(239,68,68,0.3); transform: translateX(-4px); }
  20%  { background: rgba(239,68,68,0.2); transform: translateX(0); }
  100% { background: transparent; }
}
.wm-ls-top {
  display: flex;
  align-items: center;
  gap: 6px;
  margin-bottom: 4px;
}
.wm-ls-score {
  font-size: 10px;
  font-weight: 700;
  width: 20px; height: 20px;
  border-radius: 4px;
  display: flex; align-items: center; justify-content: center;
  color: #fff;
  flex-shrink: 0;
}
.wm-ls-src  { font-size: 10px; color: #64748b; flex: 1; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.wm-ls-time { font-size: 10px; color: #475569; flex-shrink: 0; }
.wm-ls-title {
  font-size: 11px;
  color: #cbd5e1;
  line-height: 1.4;
  direction: rtl;
  text-align: right;
}

/* ── Event page permalink button ─────────────── */
.wm-ep-permalink {
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  gap: 4px;
}
.wm-ep-permalink:hover { background: #1e3a5f; }


/* ══════════════════════════════════════════════════
   v2.3 — وضع ملء الشاشة (CSS-only، موثوق 100%)
══════════════════════════════════════════════════ */

/* زر ملء الشاشة */
#wm-fullscreen-btn {
  background: none;
  border: 1px solid var(--wm-border);
  color: var(--wm-accent);
  height: 30px;
  padding: 0 10px;
  border-radius: 4px;
  cursor: pointer;
  font-size: 13px;
  font-weight: 600;
  transition: all .2s;
  display: flex; align-items: center;
  white-space: nowrap;
  flex-shrink: 0;
}
#wm-fullscreen-btn:hover { background: var(--wm-accent); color: #000; }

/* ── السماح بالتمرير للوصول للبلوكات ── */
html, body {
  overflow-y: auto !important;
  overflow-x: hidden !important;
}
html.wm-fs-active,
body.wm-fs-active {
  overflow-y: auto !important;
  overflow-x: hidden !important;
}


/* ── #wm-root في وضع ملء الشاشة ── */
#wm-root.wm-fullscreen {
  position: fixed !important;
  inset: 0 !important;           /* top/right/bottom/left = 0 */
  width: 100vw !important;
  height: 100vh !important;
  max-width: none !important;
  max-height: none !important;
  z-index: 999999 !important;
  border-radius: 0 !important;
  border: none !important;
  margin: 0 !important;
  display: flex !important;
  flex-direction: column !important;
  overflow: hidden !important;
}

/* Layout يأخذ باقي المساحة */
#wm-root.wm-fullscreen .wm-layout {
  flex: 1 1 0% !important;
  height: 0 !important;          /* flex child يحتاج height:0 مع flex:1 */
  min-height: 0 !important;
}

#wm-root.wm-fullscreen .wm-map-wrap {
  height: 100% !important;
}

#wm-root.wm-fullscreen .wm-panel {
  width: 370px !important;
  height: 100% !important;
  flex-shrink: 0 !important;
}

/* Header أصغر */
#wm-root.wm-fullscreen .wm-header {
  padding: 5px 14px !important;
  flex-shrink: 0 !important;
}

/* زر الخروج أحمر */
#wm-root.wm-fullscreen #wm-fullscreen-btn {
  background: rgba(239,68,68,0.15) !important;
  border-color: #ef4444 !important;
  color: #ef4444 !important;
}
#wm-root.wm-fullscreen #wm-fullscreen-btn:hover {
  background: #ef4444 !important;
  color: #fff !important;
}

/* إزالة header WordPress وكل ما حوله */
body.wm-fs-active .wm-fullscreen {
  /* كل شيء يختفي ماعدا #wm-root — done by fixed+z-index */
}

/* ══════════════════════════════════════════════════
   v2.3 — Status Ribbon + Blocks System
══════════════════════════════════════════════════ */

/* ── Status Ribbon (بدل البطاقة الكبيرة) ─────── */
/* wm-status-ribbon — moved to blocks section */

/* ── Blocks Grid ─────────────────────────────── */
#wm-blocks {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 12px;
  padding: 16px;
  background: #040810;
  border-top: 2px solid var(--wm-border);
  direction: rtl;
}
@media (max-width: 1100px) { #wm-blocks { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 600px)  { #wm-blocks { grid-template-columns: 1fr; } }

.wm-block {
  background: var(--wm-bg2);
  border: 1px solid var(--wm-border);
  border-radius: 10px;
  overflow: hidden;
  transition: border-color .2s, box-shadow .2s;
}
.wm-block:hover {
  border-color: rgba(37,99,235,0.4);
  box-shadow: 0 4px 20px rgba(37,99,235,0.08);
}

.wm-block-header {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 10px 14px;
  background: rgba(255,255,255,0.02);
  border-bottom: 1px solid var(--wm-border);
}
.wm-block-icon  { font-size: 16px; }
.wm-block-title { font-size: 12px; font-weight: 700; color: var(--wm-text); letter-spacing: .5px; }

.wm-block-body  { padding: 10px; }

/* Block 1: Stats */
.wm-bstat-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 5px 0;
  border-bottom: 1px solid rgba(255,255,255,0.04);
  font-size: 12px;
  color: var(--wm-text-dim);
}
.wm-bstat-row:last-child { border-bottom: none; }
.wm-bstat-row strong { font-size: 15px; font-family: var(--wm-font-mono); }

/* Block 2: Regions */
.wm-bregion-row {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 4px 0;
  font-size: 11px;
}
.wm-br-name { width: 60px; flex-shrink: 0; color: var(--wm-text); }
.wm-br-bar-wrap { flex: 1; height: 6px; background: rgba(255,255,255,0.06); border-radius: 3px; overflow: hidden; }
.wm-br-bar { height: 100%; border-radius: 3px; transition: width .6s ease; }
.wm-br-count { width: 24px; text-align: right; font-family: var(--wm-font-mono); font-size: 11px; flex-shrink: 0; }

/* Block 3: Earthquakes */
.wm-bquake-row {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 5px 0;
  border-bottom: 1px solid rgba(255,255,255,0.04);
}
.wm-bquake-row:last-child { border-bottom: none; }
.wm-bq-mag {
  font-size: 11px; font-weight: 800;
  padding: 3px 6px;
  border-radius: 5px;
  color: #fff;
  flex-shrink: 0;
  font-family: var(--wm-font-mono);
}
.wm-bq-info  { flex: 1; min-width: 0; }
.wm-bq-place { font-size: 11px; color: var(--wm-text); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.wm-bq-date  { font-size: 10px; color: var(--wm-text-dim); margin-top: 1px; }

/* Block 4: Tensions */
.wm-btens-row {
  display: flex;
  align-items: flex-start;
  gap: 8px;
  padding: 6px 0;
  border-bottom: 1px solid rgba(255,255,255,0.04);
  cursor: pointer;
  transition: background .15s;
  border-radius: 4px;
}
.wm-btens-row:hover { background: rgba(255,255,255,0.03); }
.wm-btens-row:last-child { border-bottom: none; }
.wm-bt-score {
  font-size: 11px; font-weight: 800;
  width: 22px; height: 22px;
  border-radius: 4px;
  display: flex; align-items: center; justify-content: center;
  color: #fff;
  flex-shrink: 0;
}
.wm-bt-title {
  font-size: 11px;
  color: var(--wm-text-dim);
  line-height: 1.4;
  direction: rtl;
}
.wm-btens-row:hover .wm-bt-title { color: var(--wm-text); }

/* البلوكات تظهر أسفل الخريطة بالتمرير */
#wm-root ~ #wm-page-wrap {
  position: relative;
  z-index: 20; /* فوق الـ map fixed */
}
#wm-map-spacer {
  height: 100vh;
  pointer-events: none;
}
#wm-page-wrap #wm-blocks {
  display: grid;
  position: relative;
  background: #040810;
}

/* ══════════════════════════════════════════════════
   v2.3.2 — بلوكات الإحصاء الكاملة في الأسفل
══════════════════════════════════════════════════ */

/* البلوك العريض — يأخذ عمودين */
.wm-block-wide {
  grid-column: span 2;
}
@media (max-width: 1100px) {
  .wm-block-wide { grid-column: span 1; }
}

/* توزيع التهديد — أرقام أكبر */
#wm-block-dist .wm-dist-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 10px;
  padding: 4px 0;
}
#wm-block-dist .wm-dist-item {
  border-radius: 8px;
  padding: 14px 8px;
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 5px;
  transition: transform .15s;
}
#wm-block-dist .wm-dist-item:hover { transform: translateY(-2px); }
#wm-block-dist .wm-dist-item small {
  font-size: 10px;
  color: var(--wm-text-dim);
}

/* الـ meta badge في header البلوك */
.wm-block-meta {
  margin-right: auto;
  font-size: 10px;
  color: var(--wm-text-dim);
  background: rgba(255,255,255,0.05);
  padding: 2px 8px;
  border-radius: 10px;
}

/* region cloud أكبر */
#wm-block-regioncloud .wm-region-cloud {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
  min-height: 40px;
}
#wm-block-regioncloud .wm-region-tag {
  background: rgba(37,99,235,0.1);
  border: 1px solid rgba(37,99,235,0.2);
  border-radius: 20px;
  padding: 4px 12px;
  color: var(--wm-text);
  cursor: default;
  transition: all .15s;
  line-height: 1.4;
}
#wm-block-regioncloud .wm-region-tag:hover {
  background: rgba(37,99,235,0.25);
  border-color: rgba(37,99,235,0.5);
}

/* بارات المصادر */
#wm-bd-sources .wm-stat-row {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 7px;
}
#wm-bd-sources .wm-stat-label {
  width: 110px;
  flex-shrink: 0;
  font-size: 11px;
  color: var(--wm-text);
  text-align: right;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
#wm-bd-sources .wm-stat-bar-wrap {
  flex: 1;
  height: 6px;
  background: rgba(255,255,255,0.06);
  border-radius: 3px;
  overflow: hidden;
}
#wm-bd-sources .wm-stat-bar {
  height: 100%;
  background: linear-gradient(90deg, #2563eb, #3b82f6);
  border-radius: 3px;
  transition: width .5s ease;
}
#wm-bd-sources .wm-stat-val {
  width: 28px;
  text-align: left;
  font-size: 11px;
  color: var(--wm-accent);
  font-weight: 700;
}

/* نشاط 24 ساعة */
#wm-bd-activity .wm-hourly-bars {
  display: flex;
  align-items: flex-end;
  gap: 3px;
  height: 70px;
  padding: 4px 0;
}
.wm-hour-col {
  display: flex;
  flex-direction: column;
  align-items: center;
  flex: 1;
}
.wm-hour-bar {
  width: 100%;
  background: linear-gradient(180deg, #3b82f6, #1d4ed8);
  border-radius: 2px 2px 0 0;
  min-height: 2px;
  transition: height .4s ease;
  cursor: default;
}
.wm-hour-bar:hover { background: linear-gradient(180deg, #60a5fa, #3b82f6); }
.wm-hour-label {
  font-size: 8px;
  color: #475569;
  margin-top: 3px;
  white-space: nowrap;
}

/* ── Block الوضع العالمي ──────────────────────── */
.wm-block-status {
  border-top: 3px solid #22c55e;
  transition: border-color .5s;
}
.wm-block-status .wm-block-body {
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.wm-gb-main {
  display: flex;
  align-items: baseline;
  gap: 6px;
  padding: 4px 0;
}
.wm-gb-score {
  font-size: 42px;
  font-weight: 900;
  line-height: 1;
  transition: color .5s;
}
.wm-gb-label {
  font-size: 12px;
  color: var(--wm-text-dim);
}
.wm-gb-details {
  display: flex;
  flex-direction: column;
  gap: 5px;
}
.wm-gb-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 11px;
  color: var(--wm-text-dim);
  padding: 3px 0;
  border-bottom: 1px solid rgba(255,255,255,0.04);
}
.wm-gb-row strong { font-size: 13px; }
.wm-gb-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 5px;
}
.wm-gb-tag {
  background: rgba(255,255,255,0.05);
  border: 1px solid var(--wm-border);
  border-radius: 12px;
  padding: 2px 9px;
  font-size: 10px;
  color: var(--wm-text);
  display: flex;
  align-items: center;
  gap: 4px;
}
.wm-gb-tag small {
  color: var(--wm-accent);
  font-weight: 700;
}

/* ══════════════════════════════════════════════════
   v2.4 — بلوك البث المباشر
══════════════════════════════════════════════════ */

/* البلوك يأخذ كامل العرض */
.wm-block-live {
  grid-column: span 2;   /* عمودان — نفس عرض التوترات */
  border-top: 3px solid #ef4444;
}

/* التوترات أيضاً عمودان ليصطفا في صف واحد */
#wm-block-tensions {
  grid-column: span 2;
}

/* Header البث */
.wm-live-header {
  gap: 10px;
}
.wm-live-now {
  font-size: 11px;
  color: var(--wm-accent);
  background: rgba(37,99,235,0.12);
  border: 1px solid rgba(37,99,235,0.25);
  padding: 2px 10px;
  border-radius: 10px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  max-width: 180px;
}
.wm-live-collapse {
  background: none;
  border: none;
  color: var(--wm-text-dim);
  cursor: pointer;
  font-size: 12px;
  margin-right: auto;
  padding: 2px 6px;
  transition: transform .2s;
}
.wm-live-collapse:hover { color: var(--wm-text); }

/* Body: قنوات + مشغّل جنباً لجنب */
.wm-live-body {
  display: flex;
  gap: 0;
  direction: rtl;
  height: 280px;   /* ارتفاع ثابت معقول */
}

/* قائمة القنوات */
.wm-live-channels {
  display: flex;
  flex-direction: column;
  gap: 3px;
  padding: 10px 8px;
  width: 155px;
  min-width: 155px;
  flex-shrink: 0;
  border-left: 1px solid var(--wm-border);
  background: rgba(0,0,0,0.25);
  overflow-y: auto;
  scrollbar-width: thin;
}
.wm-ch-btn {
  display: flex;
  align-items: center;
  gap: 7px;
  padding: 7px 10px;
  background: none;
  border: 1px solid transparent;
  border-radius: 6px;
  color: var(--wm-text-dim);
  font-size: 12px;
  cursor: pointer;
  text-align: right;
  transition: all .15s;
  white-space: nowrap;
  font-family: var(--wm-font-ar);
}
.wm-ch-btn:hover {
  background: rgba(255,255,255,0.05);
  color: var(--wm-text);
  border-color: var(--wm-border);
}
.wm-ch-btn.active {
  background: rgba(239,68,68,0.12);
  border-color: rgba(239,68,68,0.4);
  color: #fff;
}
.wm-ch-dot {
  width: 7px; height: 7px;
  border-radius: 50%;
  background: #475569;
  flex-shrink: 0;
  transition: background .2s;
}
.wm-ch-btn.active .wm-ch-dot {
  background: #ef4444;
  box-shadow: 0 0 6px #ef4444;
  animation: wm-pulse 1s ease infinite;
}

/* مشغّل الفيديو */
.wm-live-player {
  flex: 1;
  position: relative;
  background: #000;
  height: 100%;
  overflow: hidden;
  cursor: pointer;
}
/* Thumbnail يغطي المشغل كاملاً */
.wm-live-thumb {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  filter: brightness(0.6);
  transition: filter .2s;
}
.wm-live-player:hover .wm-live-thumb { filter: brightness(0.45); }

/* زر التشغيل المركزي */
.wm-live-center {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 8px;
  text-align: center;
  pointer-events: none;
}
.wm-live-play-big {
  width: 64px; height: 64px;
  background: rgba(239,68,68,0.9);
  border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  transition: transform .2s, background .2s;
  pointer-events: all;
  text-decoration: none !important;
  padding-left: 4px;
}
.wm-live-play-big:hover {
  transform: scale(1.1);
  background: #ef4444;
}
.wm-live-ch-label {
  color: #fff;
  font-size: 14px;
  font-weight: 700;
  text-shadow: 0 2px 8px rgba(0,0,0,0.8);
}
.wm-live-hint {
  color: rgba(255,255,255,0.7);
  font-size: 11px;
  text-shadow: 0 1px 4px rgba(0,0,0,0.8);
}

/* شارة LIVE */
.wm-live-badge {
  position: absolute;
  top: 10px;
  left: 12px;
  display: flex;
  align-items: center;
  gap: 5px;
  background: rgba(239,68,68,0.85);
  color: #fff;
  font-size: 11px;
  font-weight: 700;
  padding: 3px 9px;
  border-radius: 4px;
  letter-spacing: 1px;
}


/* ═══════════════════════════════════════════════════════
   🔍 RUMOR TRACKER — تبويب الشائعات
═══════════════════════════════════════════════════════ */

/* الحاوية الرئيسية للشائعات — تملأ الـ panel كاملاً */
#wm-panel-rumors {
  flex: 1;
  min-height: 0;
  flex-direction: column;
  overflow: hidden;
}

/* فلتر الحالة */
#wm-rumors-filter {
    display: flex;
    gap: 6px;
    padding: 8px 10px;
    border-bottom: 1px solid rgba(255,255,255,0.06);
    flex-wrap: wrap;
    flex-shrink: 0;
}
.wm-rf-btn {
    background: rgba(255,255,255,0.04);
    border: 1px solid rgba(255,255,255,0.08);
    color: #94a3b8;
    padding: 4px 10px;
    border-radius: 20px;
    font-size: 11px;
    cursor: pointer;
    transition: all .2s;
    font-family: inherit;
}
.wm-rf-btn:hover { border-color: #475569; color: #e2e8f0; }
.wm-rf-btn.active {
    background: rgba(99,102,241,0.15);
    border-color: #6366f1;
    color: #a5b4fc;
    font-weight: 600;
}

/* قائمة الشائعات */
#wm-rumors-list {
  flex: 1;
  min-height: 0;
  overflow-y: auto;
  overflow-x: hidden;
  padding: 8px 10px;
  scrollbar-width: thin;
  scrollbar-color: var(--wm-border, #1e3a5f) transparent;
}

/* نموذج الإبلاغ الجماعي */
.wm-report-form {
    border-top: 1px solid rgba(255,255,255,0.06);
    flex-shrink: 0;
    max-height: 200px;
    overflow-y: auto;
}
.wm-report-toggle {
    padding: 9px 14px;
    font-size: 12px;
    color: #60a5fa;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 6px;
    transition: background .2s;
}
.wm-report-toggle:hover { background: rgba(96,165,250,0.06); }
.wm-report-submit {
    width: 100%;
    background: linear-gradient(135deg, #1e3a5f, #1e40af);
    border: 1px solid #3b82f6;
    color: #93c5fd;
    padding: 7px;
    border-radius: 6px;
    font-size: 12px;
    cursor: pointer;
    font-family: inherit;
    transition: opacity .2s;
}
.wm-report-submit:hover { opacity: 0.85; }

/* بطاقة الشائعة في الـ panel */
.wm-rumor-item {
    transition: background .2s;
}
.wm-rumor-item:hover {
    background: rgba(255,255,255,0.04) !important;
}

/* ── Rumor Map Popup ───────────────────────────────────── */
.wm-rumor-popup .leaflet-popup-content-wrapper {
    background: #0f172a;
    border: 1px solid #1e3a5a;
    border-radius: 12px;
    box-shadow: 0 8px 32px rgba(0,0,0,0.6), 0 0 0 1px rgba(255,255,255,0.04);
    color: #e2e8f0;
    font-family: 'Tajawal', sans-serif;
    padding: 0;
    overflow: hidden;
}
.wm-rumor-popup .leaflet-popup-tip-container { margin-top: -1px; }
.wm-rumor-popup .leaflet-popup-tip { background: #0f172a; }
.wm-rumor-popup .leaflet-popup-content { margin: 0; width: 290px !important; }
.wm-rumor-popup .leaflet-popup-close-button {
    color: #475569 !important;
    font-size: 18px !important;
    top: 8px !important;
    right: 8px !important;
}

/* ── محتوى الـ popup ── */
.wm-rp-wrap { direction: rtl; padding: 14px 16px 12px; }

.wm-rp-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 10px;
    padding-bottom: 10px;
    border-bottom: 1px solid rgba(255,255,255,0.06);
}
.wm-rp-badge {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    padding: 3px 10px;
    border-radius: 20px;
    font-size: 11px;
    font-weight: 700;
    border: 1px solid;
    letter-spacing: 0.3px;
}
.wm-rp-region {
    font-size: 11px;
    color: #38bdf8;
    white-space: nowrap;
}
.wm-rp-title {
    font-size: 13px;
    font-weight: 600;
    color: #e2e8f0;
    line-height: 1.55;
    margin-bottom: 8px;
    text-align: right;
}
.wm-rp-summary {
    font-size: 11.5px;
    color: #94a3b8;
    line-height: 1.6;
    background: rgba(255,255,255,0.03);
    border-right: 3px solid #334155;
    padding: 6px 10px 6px 6px;
    border-radius: 4px;
    margin-bottom: 8px;
    text-align: right;
}
.wm-rp-divider {
    height: 1px;
    background: rgba(255,255,255,0.06);
    margin: 8px 0;
}
.wm-rp-check-label {
    font-size: 10px;
    color: #475569;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 5px;
}
.wm-rp-claim {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
    background: rgba(167,139,250,0.06);
    padding: 5px 8px;
    border-radius: 6px;
}
.wm-rp-claim-pub { font-size: 11px; color: #94a3b8; }
.wm-rp-claim-rating { font-size: 11px; font-weight: 700; }
.wm-rp-source-link {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    font-size: 11px;
    color: #60a5fa;
    text-decoration: none;
    padding: 4px 10px;
    background: rgba(96,165,250,0.08);
    border-radius: 6px;
    border: 1px solid rgba(96,165,250,0.2);
    transition: background 0.15s;
    margin-top: 4px;
}
.wm-rp-source-link:hover { background: rgba(96,165,250,0.15); }

/* ── Travel Advisory Icon ─────────────────────────────────── */
.wm-travel-icon div {
    color: #3b82f6;
    font-size: 14px;
    text-shadow: 0 0 6px rgba(59,130,246,0.7);
    animation: wm-travel-pulse 2s ease-in-out infinite;
}
@keyframes wm-travel-pulse {
    0%, 100% { opacity: 1; transform: scale(1); }
    50%       { opacity: 0.7; transform: scale(1.2); }
}

/* ═══════════════════════════════════════════════════════
   🌡 TENSION HEATMAP — الخريطة الحرارية الجيوسياسية
   ═══════════════════════════════════════════════════════ */

/* زر طبقة التوترات */
#wm-tension-heatmap-toggle.active {
    background: linear-gradient(135deg, #ef4444, #dc2626);
    color: white;
    box-shadow: 0 0 12px rgba(239,68,68,0.5);
    animation: tensionPulse 2s infinite;
}
@keyframes tensionPulse {
    0%, 100% { box-shadow: 0 0 8px rgba(239,68,68,0.4); }
    50%       { box-shadow: 0 0 18px rgba(239,68,68,0.7); }
}

/* ── بانل التوترات ─────────────────────────────────────── */
#wm-panel-tensions {
    flex-direction: column;
    height: 100%;
    overflow: hidden;
}

.wm-tensions-header {
    padding: 10px 12px 6px;
    border-bottom: 1px solid #1e293b;
}
.wm-tensions-title-row {
    display: flex;
    align-items: center;
    gap: 7px;
    font-size: 13px;
    font-weight: 600;
    color: #e2e8f0;
    margin-bottom: 4px;
}
.wm-tensions-icon { font-size: 16px; }
.wm-tens-map-btn {
    margin-left: auto;
    background: linear-gradient(135deg, #1e3a5f, #1e40af);
    border: 1px solid #3b82f6;
    color: #93c5fd;
    padding: 4px 9px;
    border-radius: 5px;
    font-size: 11px;
    cursor: pointer;
    font-family: inherit;
    transition: all .2s;
    white-space: nowrap;
}
.wm-tens-map-btn:hover, .wm-tens-map-btn.active {
    background: linear-gradient(135deg, #ef4444, #dc2626);
    border-color: #ef4444;
    color: white;
    box-shadow: 0 0 10px rgba(239,68,68,0.4);
}
.wm-tensions-updated {
    font-size: 10px;
    color: #475569;
}

/* فلاتر */
.wm-tensions-filter {
    display: flex;
    gap: 4px;
    padding: 6px 10px;
    border-bottom: 1px solid #1e293b;
    flex-wrap: wrap;
}
.wm-tf-btn {
    background: transparent;
    border: 1px solid #334155;
    color: #94a3b8;
    padding: 3px 8px;
    border-radius: 4px;
    font-size: 11px;
    cursor: pointer;
    font-family: inherit;
    transition: all .15s;
}
.wm-tf-btn:hover { border-color: #64748b; color: #cbd5e1; }
.wm-tf-btn.active {
    background: #1e40af;
    border-color: #3b82f6;
    color: white;
}

/* قائمة التوترات */
.wm-tensions-list {
    flex: 1;
    overflow-y: auto;
    padding: 8px 10px;
    display: flex;
    flex-direction: column;
    gap: 6px;
}
.wm-tensions-loading {
    color: #64748b;
    font-size: 12px;
    padding: 20px;
    text-align: center;
}
.wm-tens-empty {
    color: #475569;
    font-size: 12px;
    padding: 20px;
    text-align: center;
    line-height: 1.6;
}

/* ملخص إجمالي */
.wm-tens-summary {
    background: rgba(255,255,255,0.03);
    border: 1px solid #1e293b;
    border-radius: 8px;
    padding: 10px 12px;
    margin-bottom: 4px;
    display: grid;
    grid-template-columns: 1fr auto;
    grid-template-rows: auto auto auto;
    gap: 4px;
    align-items: center;
}
.wm-tens-sum-label {
    font-size: 10px;
    color: #64748b;
    text-transform: uppercase;
    letter-spacing: .5px;
}
.wm-tens-sum-score {
    font-size: 22px;
    font-weight: 700;
    grid-row: 1 / 3;
    grid-column: 2;
    text-align: right;
}
.wm-tens-sum-score small { font-size: 11px; color: #64748b; }
.wm-tens-sum-bar {
    height: 4px;
    background: #1e293b;
    border-radius: 2px;
    overflow: hidden;
    grid-column: 1;
}
.wm-tens-sum-count {
    font-size: 10px;
    color: #475569;
    grid-column: 1 / 3;
}

/* بطاقة توتر واحدة */
.wm-tens-card {
    border-radius: 7px;
    padding: 9px 11px;
    cursor: pointer;
    transition: transform .15s, box-shadow .15s;
    border: 1px solid rgba(255,255,255,0.04);
}
.wm-tens-card:hover {
    transform: translateX(-2px);
    box-shadow: 0 3px 12px rgba(0,0,0,0.3);
}
.wm-tens-card-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 6px;
}
.wm-tens-label {
    font-size: 12px;
    font-weight: 600;
    color: #e2e8f0;
}
.wm-tens-trend {
    font-size: 11px;
    font-weight: 600;
}
.wm-tens-bar-wrap {
    height: 4px;
    background: rgba(255,255,255,0.07);
    border-radius: 2px;
    overflow: hidden;
    margin-bottom: 6px;
}
.wm-tens-bar-fill {
    height: 100%;
    border-radius: 2px;
    transition: width 0.8s cubic-bezier(.4,0,.2,1);
}
.wm-tens-card-footer {
    display: flex;
    align-items: center;
    gap: 8px;
}
.wm-tens-score {
    font-size: 13px;
    font-weight: 700;
}
.wm-tens-score small { font-size: 10px; color: #64748b; }
.wm-tens-level {
    font-size: 10px;
    background: rgba(255,255,255,0.06);
    padding: 2px 6px;
    border-radius: 3px;
}
.wm-tens-map-hint {
    margin-left: auto;
    font-size: 10px;
    color: #475569;
    opacity: 0;
    transition: opacity .2s;
}
.wm-tens-card:hover .wm-tens-map-hint { opacity: 1; }

/* footer البانل */
.wm-tensions-footer {
    padding: 8px 10px;
    border-top: 1px solid #1e293b;
    display: flex;
    align-items: center;
    justify-content: space-between;
}
.wm-tensions-legend {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
}
.wm-tl-item {
    display: flex;
    align-items: center;
    gap: 4px;
    font-size: 10px;
    color: #64748b;
}
.wm-tl-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    flex-shrink: 0;
}
.wm-tensions-refresh {
    background: transparent;
    border: 1px solid #334155;
    color: #64748b;
    padding: 3px 8px;
    border-radius: 4px;
    font-size: 11px;
    cursor: pointer;
    font-family: inherit;
    transition: all .15s;
}
.wm-tensions-refresh:hover {
    border-color: #64748b;
    color: #94a3b8;
}

/* ── Legend على الخريطة ─────────────────────────────────── */
.wm-tension-map-legend {
    position: absolute;
    bottom: 177px; /* + 32px فوق breaking bar */
    right: 62px;
    background: rgba(10, 18, 35, 0.94);
    border: 1px solid rgba(99,102,241,0.35);
    border-radius: 10px;
    padding: 10px 13px 8px;
    z-index: 999;
    min-width: 185px;
    backdrop-filter: blur(12px);
    pointer-events: auto;
    box-shadow: 0 4px 24px rgba(0,0,0,0.5), inset 0 1px 0 rgba(255,255,255,0.04);
    transition: opacity .3s ease, transform .3s ease;
}
.wm-tml-title {
    font-size: 10px;
    font-weight: 700;
    color: #6366f1;
    margin-bottom: 8px;
    text-transform: uppercase;
    letter-spacing: .8px;
    display: flex;
    align-items: center;
    justify-content: space-between;
}
.wm-tml-close {
    cursor: pointer;
    color: #475569;
    font-size: 12px;
    line-height: 1;
    padding: 0 2px;
    border: none;
    background: none;
    transition: color .2s;
}
.wm-tml-close:hover { color: #e2e8f0; }
.wm-tml-row {
    display: flex;
    align-items: center;
    gap: 7px;
    margin-bottom: 5px;
    padding: 3px 0;
    border-bottom: 1px solid rgba(255,255,255,0.04);
}
.wm-tml-row:last-child { border-bottom: none; margin-bottom: 0; }
.wm-tml-dot {
    width: 7px;
    height: 7px;
    border-radius: 50%;
    flex-shrink: 0;
    box-shadow: 0 0 5px currentColor;
}
.wm-tml-label {
    font-size: 11.5px;
    color: #cbd5e1;
    flex: 1;
    white-space: nowrap;
}
.wm-tml-score {
    font-size: 11px;
    font-weight: 800;
    font-variant-numeric: tabular-nums;
    min-width: 28px;
    text-align: left;
}

/* ── Tooltips / Popups التوترات ─────────────────────────── */
.wm-tens-tooltip {
    font-family: 'Tajawal', sans-serif;
    font-size: 12px;
    line-height: 1.5;
    direction: rtl;
}
.wm-tens-tip .leaflet-tooltip {
    background: rgba(15,23,42,0.95);
    border: 1px solid #334155;
    border-radius: 6px;
    color: #e2e8f0;
    padding: 6px 10px;
}
.wm-tens-popup-wrap .leaflet-popup-content-wrapper {
    background: #1e293b;
    border: 1px solid #334155;
    border-radius: 10px;
    color: #e2e8f0;
    font-family: 'Tajawal', sans-serif;
    direction: rtl;
}
.wm-tens-popup-wrap .leaflet-popup-tip {
    background: #1e293b;
}
.wm-tens-popup { padding: 4px; }
.wm-tens-pop-title {
    font-size: 13px;
    font-weight: 700;
    margin-bottom: 5px;
    color: #f1f5f9;
}
.wm-tens-pop-loc { font-size: 11px; color: #94a3b8; margin-bottom: 4px; }
.wm-tens-pop-score { font-size: 13px; font-weight: 600; margin-bottom: 2px; }
.wm-tens-pop-trend { font-size: 11px; color: #64748b; }

/* نقطة الساخنة المتوهجة */
.wm-tension-hotspot {
    background: transparent !important;
    border: none !important;
}

/* ── التايملاين الزمني ──────────────────────────────────────── */
#wm-timeline-section {
    position: absolute;
    bottom: 32px;  /* فوق breaking bar (ارتفاعه 32px) */
    left: 0;       /* يبدأ من حافة الشاشة اليسرى — مثل breaking bar */
    right: 52px;   /* بجانب الـ dock */
    z-index: 500;
    background: rgba(6,12,22,0.96);
    border-top: 1px solid rgba(30,58,90,0.8);
    backdrop-filter: blur(12px);
    direction: rtl;
    font-family: inherit;
    transform: translateY(calc(100% + 32px)); /* مخفي خلف breaking bar */
    transition: transform .3s cubic-bezier(.4,0,.2,1);
    box-shadow: 0 -4px 24px rgba(0,0,0,0.5);
    pointer-events: none; /* لا تستقبل نقرات عند الإخفاء */
}
/* عندما يكون مفتوحاً — يظهر للأعلى */
#wm-timeline-section.tl-visible {
    transform: translateY(0);
    pointer-events: auto;
}

.wm-tl-header {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 7px 14px;
    background: rgba(5,10,18,0.6);
    border-bottom: 1px solid rgba(30,58,90,0.5);
    flex-wrap: nowrap;
}
.wm-tl-title {
    font-size: 12px;
    font-weight: 700;
    color: #64748b;
    white-space: nowrap;
    margin-left: auto;
}
.wm-tl-filters {
    display: flex;
    gap: 4px;
    flex-wrap: wrap;
}
.wm-tl-btn {
    background: #1e293b;
    border: 1px solid #334155;
    color: #94a3b8;
    padding: 3px 10px;
    border-radius: 4px;
    font-size: 11px;
    cursor: pointer;
    transition: all .15s;
    font-family: inherit;
}
.wm-tl-btn:hover { background: #334155; color: #e2e8f0; }
.wm-tl-btn.active { background: #1d4ed8; border-color: #3b82f6; color: #fff; }
.wm-tl-toggle {
    background: rgba(239,68,68,0.08);
    border: 1px solid rgba(239,68,68,0.25);
    color: #ef4444;
    width: 24px; height: 24px;
    border-radius: 6px;
    font-size: 12px;
    cursor: pointer;
    font-family: inherit;
    display: flex; align-items: center; justify-content: center;
    flex-shrink: 0;
    margin-right: 4px;
    transition: all .2s;
}
.wm-tl-toggle:hover { background: #ef4444; color: #fff; }

#wm-timeline-wrap {
    position: relative;
    overflow: hidden;
    max-height: 180px;
    transition: max-height .3s ease;
}
#wm-timeline-wrap.collapsed { max-height: 0; }

#wm-timeline-track {
    overflow-x: auto;
    overflow-y: hidden;
    padding: 14px 16px 6px;
    scrollbar-width: thin;
    scrollbar-color: #334155 #0f172a;
    cursor: grab;
    user-select: none;
}
#wm-timeline-track:active { cursor: grabbing; }
#wm-timeline-track::-webkit-scrollbar { height: 4px; }
#wm-timeline-track::-webkit-scrollbar-track { background: #0f172a; }
#wm-timeline-track::-webkit-scrollbar-thumb { background: #334155; border-radius: 2px; }

#wm-timeline-inner {
    display: flex;
    align-items: flex-end;
    gap: 0;
    min-width: max-content;
    position: relative;
    padding-bottom: 28px;
}

/* خط الزمن */
#wm-timeline-inner::before {
    content: '';
    position: absolute;
    bottom: 22px;
    left: 0; right: 0;
    height: 2px;
    background: linear-gradient(90deg, transparent, #1e293b 5%, #1e293b 95%, transparent);
}

.wm-tl-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    position: relative;
    min-width: 120px;
    max-width: 150px;
    padding: 0 6px;
    cursor: pointer;
    transition: transform .15s;
}
.wm-tl-item:hover { transform: translateY(-2px); }
.wm-tl-item:hover .wm-tl-card { border-color: #3b82f6; background: #1e3a5f; }

.wm-tl-card {
    background: #1e293b;
    border: 1px solid #334155;
    border-radius: 6px;
    padding: 6px 8px;
    font-size: 10px;
    color: #e2e8f0;
    line-height: 1.4;
    text-align: center;
    width: 100%;
    transition: all .15s;
    margin-bottom: 6px;
    box-shadow: 0 2px 6px rgba(0,0,0,.3);
}
.wm-tl-card-icon { font-size: 14px; margin-bottom: 3px; display: block; }
.wm-tl-card-title {
    font-size: 10px;
    color: #cbd5e1;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    line-height: 1.3;
    margin-bottom: 3px;
    direction: rtl;
}
.wm-tl-card-time { font-size: 9px; color: #64748b; }
.wm-tl-card-cat {
    font-size: 9px;
    padding: 1px 5px;
    border-radius: 3px;
    margin-top: 3px;
    display: inline-block;
}

/* النقطة على الخط الزمني */
.wm-tl-dot {
    width: 10px; height: 10px;
    border-radius: 50%;
    border: 2px solid #0f172a;
    position: absolute;
    bottom: 17px;
    z-index: 2;
    transition: transform .15s;
}
.wm-tl-item:hover .wm-tl-dot { transform: scale(1.4); }

/* التسمية الزمنية */
.wm-tl-time-label {
    position: absolute;
    bottom: 0;
    font-size: 9px;
    color: #475569;
    white-space: nowrap;
}

/* مجموعة التواريخ */
.wm-tl-group-label {
    display: flex;
    flex-direction: column;
    align-items: center;
    min-width: 60px;
    padding: 0 8px;
    position: relative;
}
.wm-tl-group-label::before {
    content: '';
    position: absolute;
    bottom: 22px;
    width: 1px; height: 12px;
    background: #334155;
}
.wm-tl-group-text {
    font-size: 9px;
    color: #475569;
    background: #0f172a;
    padding: 1px 5px;
    border-radius: 3px;
    position: absolute;
    bottom: 0;
    white-space: nowrap;
}

/* شريط التمرير المرئي */
#wm-timeline-scrubber {
    position: relative;
    height: 6px;
    background: #1e293b;
    margin: 0 16px 8px;
    border-radius: 3px;
    cursor: pointer;
}
#wm-timeline-progress {
    height: 100%;
    background: #1d4ed8;
    border-radius: 3px;
    width: 30%;
    transition: width .1s;
}
#wm-timeline-thumb {
    position: absolute;
    top: -4px;
    width: 14px; height: 14px;
    background: #3b82f6;
    border-radius: 50%;
    border: 2px solid #0f172a;
    cursor: grab;
    transition: left .1s;
    left: 0;
}

/* ألوان التصنيفات */
.cat-war     { background: rgba(239,68,68,.2);  color: #ef4444; }
.cat-disaster{ background: rgba(249,115,22,.2); color: #f97316; }
.cat-politics{ background: rgba(168,85,247,.2); color: #a855f7; }
.cat-economy { background: rgba(34,197,94,.2);  color: #22c55e; }
.cat-health  { background: rgba(236,72,153,.2); color: #ec4899; }
.cat-science    { background: rgba(6,182,212,.2);  color: #06b6d4; }
.cat-technology { background: rgba(139,92,246,.2); color: #a78bfa; }
.cat-other   { background: rgba(100,116,139,.2);color: #64748b; }

/* رسالة عدم وجود بيانات */
.wm-tl-empty {
    text-align: center;
    padding: 30px;
    color: #475569;
    font-size: 12px;
    width: 100%;
    min-width: 300px;
}

/* ── DEFCON Widget ──────────────────────────────────────────── */
.wm-defcon-widget {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 2px 10px;
    min-width: 54px;
    cursor: default;
    flex-shrink: 0;
}
.wm-defcon-widget:hover { opacity: 0.85; }

.wm-defcon-label {
    font-size: 8px;
    font-weight: 700;
    letter-spacing: 1.5px;
    color: #64748b;
    text-transform: uppercase;
    margin-bottom: 2px;
}

.wm-defcon-number {
    font-size: 26px;
    font-weight: 900;
    line-height: 1;
    font-family: 'Courier New', monospace;
    margin-bottom: 3px;
    transition: color .4s, text-shadow .4s;
}

/* الألوان حسب المستوى */
.wm-defcon-widget.d1 .wm-defcon-number { color: #ef4444; text-shadow: 0 0 12px #ef444488; }
.wm-defcon-widget.d2 .wm-defcon-number { color: #f97316; text-shadow: 0 0 10px #f9731666; }
.wm-defcon-widget.d3 .wm-defcon-number { color: #eab308; text-shadow: 0 0 8px #eab30844; }
.wm-defcon-widget.d4 .wm-defcon-number { color: #22c55e; text-shadow: none; }
.wm-defcon-widget.d5 .wm-defcon-number { color: #3b82f6; text-shadow: none; }

/* الأشرطة */
.wm-defcon-bars {
    display: flex;
    gap: 2px;
    margin-bottom: 3px;
    flex-direction: row-reverse;
}
.wm-defcon-bars .db {
    width: 6px;
    border-radius: 1px;
    background: #1e293b;
    transition: background .4s, height .4s;
}
.wm-defcon-bars .db[data-level="1"] { height: 10px; }
.wm-defcon-bars .db[data-level="2"] { height: 8px; }
.wm-defcon-bars .db[data-level="3"] { height: 6px; }
.wm-defcon-bars .db[data-level="4"] { height: 5px; }
.wm-defcon-bars .db[data-level="5"] { height: 4px; }

/* تلوين الأشرطة النشطة */
.wm-defcon-widget.d1 .db[data-level="1"]                          { background: #ef4444; }
.wm-defcon-widget.d2 .db[data-level="1"],.wm-defcon-widget.d2 .db[data-level="2"] { background: #f97316; }
.wm-defcon-widget.d3 .db[data-level="1"],.wm-defcon-widget.d3 .db[data-level="2"],.wm-defcon-widget.d3 .db[data-level="3"] { background: #eab308; }
.wm-defcon-widget.d4 .db[data-level="1"],.wm-defcon-widget.d4 .db[data-level="2"],.wm-defcon-widget.d4 .db[data-level="3"],.wm-defcon-widget.d4 .db[data-level="4"] { background: #22c55e; }
.wm-defcon-widget.d5 .db { background: #3b82f6; }

.wm-defcon-name {
    font-size: 8px;
    color: #94a3b8;
    font-weight: 600;
    letter-spacing: .5px;
    white-space: nowrap;
}

/* وميض للمستوى 1 */
.wm-defcon-widget.d1 {
    border-color: #ef4444;
    animation: defcon1-pulse 1.5s ease-in-out infinite;
}
@keyframes defcon1-pulse {
    0%, 100% { box-shadow: 0 0 6px #ef444444; }
    50%       { box-shadow: 0 0 16px #ef4444aa; }
}

/* ── أزرار الخريطة — أيقونة فقط ─────────────────────────────── */
.wm-mc-icon {
    padding: 4px 7px !important;
    font-size: 14px !important;
    min-width: unset !important;
}

/* ── مربعا الحرائق والسفر ─────────────────────────────────────── */
.wm-threat.firecount span { color: #fb923c; }
.wm-threat.firecount { border-color: #78350f44; }
.wm-threat.firecount:hover { border-color: #f97316; }

.wm-threat.travelcount span { color: #38bdf8; }
.wm-threat.travelcount { border-color: #0c4a6e44; }
.wm-threat.travelcount:hover { border-color: #38bdf8; }

/* ── أزرار داخل شريط العدادات ───────────────────────────────── */
.wm-threat-counter .wm-mc-btn.wm-mc-icon {
    position: static !important;
    padding: 5px 8px;
    font-size: 15px;
    border-radius: 6px;
    min-width: 32px;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(30,41,59,0.9);
    border: 1px solid #334155;
}
.wm-threat-counter .wm-mc-btn.wm-mc-icon:hover {
    background: rgba(37,99,235,0.6);
    border-color: #3b82f6;
}
.wm-threat-counter .wm-mc-btn.active {
    background: rgba(239,68,68,0.7) !important;
    border-color: #ef4444 !important;
}
#wm-heatmap-toggle.active { background: rgba(249,115,22,0.7) !important; border-color: #f97316 !important; }

/* فاصل عمودي بين الأزرار والعدادات */
.wm-tc-divider {
    width: 1px;
    background: #334155;
    align-self: stretch;
    margin: 4px 2px;
}

/* ══════════════════════════════════════════════════════════════
   POLYMARKET — أسواق التنبؤ
   ══════════════════════════════════════════════════════════════ */
.wm-poly-header {
    display: flex; align-items: center; justify-content: space-between;
    padding: 8px 12px 2px;
}
.wm-poly-title { font-size: 12px; font-weight: 700; color: #e2e8f0; }
.wm-poly-refresh {
    background: none; border: 1px solid #334155; color: #64748b;
    border-radius: 4px; padding: 2px 7px; cursor: pointer; font-size: 12px;
}
.wm-poly-refresh:hover { color: #94a3b8; border-color: #475569; }
.wm-poly-subtitle { font-size: 10px; color: #475569; padding: 0 12px 6px; }
.wm-poly-filter {
    display: flex; gap: 4px; padding: 0 10px 8px; flex-wrap: wrap;
}
.wm-pf-btn {
    background: #1e293b; border: 1px solid #334155; color: #64748b;
    padding: 2px 9px; border-radius: 4px; font-size: 10px; cursor: pointer;
    font-family: inherit;
}
.wm-pf-btn.active { background: #1d4ed8; border-color: #3b82f6; color: #fff; }

#wm-poly-list { overflow-y: auto; max-height: 340px; padding: 0 8px; }

.wm-poly-card {
    background: #1e293b; border: 1px solid #334155; border-radius: 8px;
    padding: 10px 12px; margin-bottom: 8px; cursor: default;
    transition: border-color .15s;
}
.wm-poly-card:hover { border-color: #475569; }
.wm-poly-card-title {
    font-size: 11px; color: #e2e8f0; line-height: 1.4;
    margin-bottom: 8px; direction: rtl;
}
.wm-poly-bar-wrap {
    display: flex; align-items: center; gap: 8px; margin-bottom: 4px;
}
.wm-poly-bar-bg {
    flex: 1; height: 8px; background: #0f172a; border-radius: 4px;
    overflow: hidden;
}
.wm-poly-bar-fill {
    height: 100%; border-radius: 4px;
    transition: width .4s ease;
}
.wm-poly-pct {
    font-size: 16px; font-weight: 800; min-width: 42px;
    text-align: left; font-family: monospace;
}
.wm-poly-meta {
    display: flex; justify-content: space-between;
    font-size: 9px; color: #475569;
}
.wm-poly-change { font-weight: 600; }
.wm-poly-change.up   { color: #22c55e; }
.wm-poly-change.down { color: #ef4444; }
.wm-poly-change.flat { color: #64748b; }
.wm-poly-vol { color: #475569; }

.wm-poly-footer {
    display: flex; justify-content: space-between; align-items: center;
    padding: 6px 12px 8px; font-size: 9px; color: #475569;
    border-top: 1px solid #1e293b; margin-top: 4px;
}

/* ══════════════════════════════════════════════════════════════
   IODA — انقطاعات الإنترنت
   ══════════════════════════════════════════════════════════════ */
.wm-ioda-header {
    display: flex; align-items: center; justify-content: space-between;
    padding: 8px 12px 2px;
}
.wm-ioda-title { font-size: 12px; font-weight: 700; color: #e2e8f0; }
.wm-ioda-refresh {
    background: none; border: 1px solid #334155; color: #64748b;
    border-radius: 4px; padding: 2px 7px; cursor: pointer; font-size: 12px;
}
.wm-ioda-refresh:hover { color: #94a3b8; }
.wm-ioda-subtitle { font-size: 10px; color: #475569; padding: 0 12px 6px; }
.wm-ioda-filter {
    display: flex; gap: 4px; padding: 0 10px 8px;
}
.wm-if-btn {
    background: #1e293b; border: 1px solid #334155; color: #64748b;
    padding: 2px 9px; border-radius: 4px; font-size: 10px; cursor: pointer;
    font-family: inherit;
}
.wm-if-btn.active { background: #1d4ed8; border-color: #3b82f6; color: #fff; }

#wm-ioda-list { overflow-y: auto; max-height: 340px; padding: 0 8px; }

.wm-ioda-card {
    background: #1e293b; border-radius: 8px; padding: 9px 12px;
    margin-bottom: 7px; border-right: 3px solid transparent;
    transition: border-color .15s;
}
.wm-ioda-card.critical { border-right-color: #ef4444; }
.wm-ioda-card.warning  { border-right-color: #eab308; }
.wm-ioda-card.normal   { border-right-color: #22c55e; }

.wm-ioda-card-top {
    display: flex; justify-content: space-between; align-items: center;
    margin-bottom: 5px;
}
.wm-ioda-country { font-size: 12px; font-weight: 700; color: #e2e8f0; }
.wm-ioda-badge {
    font-size: 9px; padding: 2px 6px; border-radius: 3px; font-weight: 600;
}
.wm-ioda-badge.critical { background: rgba(239,68,68,.2);  color: #ef4444; }
.wm-ioda-badge.warning  { background: rgba(234,179,8,.2);  color: #eab308; }
.wm-ioda-badge.normal   { background: rgba(34,197,94,.2);  color: #22c55e; }

.wm-ioda-bar-row { display: flex; align-items: center; gap: 6px; margin-bottom: 3px; }
.wm-ioda-bar-label { font-size: 9px; color: #64748b; min-width: 28px; text-align: right; }
.wm-ioda-bar-bg {
    flex: 1; height: 5px; background: #0f172a; border-radius: 3px; overflow: hidden;
}
.wm-ioda-bar-fill { height: 100%; border-radius: 3px; transition: width .4s; }
.wm-ioda-bar-pct { font-size: 9px; color: #94a3b8; min-width: 30px; }

.wm-ioda-meta { font-size: 9px; color: #475569; margin-top: 3px; }

.wm-ioda-footer {
    display: flex; justify-content: space-between;
    padding: 6px 12px 8px; font-size: 9px; color: #475569;
    border-top: 1px solid #1e293b; margin-top: 4px;
}

.wm-poly-loading, .wm-ioda-loading {
    text-align: center; padding: 30px; color: #475569; font-size: 12px;
}
.wm-poly-empty, .wm-ioda-empty {
    text-align: center; padding: 24px; color: #475569; font-size: 11px;
}

/* ── بلوكات Polymarket و IODA ────────────────────────────────── */
.wm-block-poly,
.wm-block-ioda {
    grid-column: span 2;
}
.wm-block-footer {
    padding: 5px 12px 8px;
    border-top: 1px solid #1e293b;
}

/* Polymarket block body */
#wm-block-poly-body {
    padding: 6px 8px;
    max-height: 220px;
    overflow-y: auto;
    display: flex;
    flex-direction: column;
    gap: 6px;
}
.wm-bpoly-item {
    background: #0f172a;
    border: 1px solid #1e293b;
    border-radius: 6px;
    padding: 7px 10px;
    transition: border-color .15s;
}
.wm-bpoly-item:hover { border-color: #334155; }
.wm-bpoly-q {
    font-size: 10px; color: #cbd5e1; line-height: 1.4;
    margin-bottom: 5px; direction: ltr; text-align: left;
}
.wm-bpoly-row {
    display: flex; align-items: center; gap: 8px;
}
.wm-bpoly-bar-bg {
    flex: 1; height: 6px; background: #1e293b; border-radius: 3px; overflow: hidden;
}
.wm-bpoly-bar-fill { height: 100%; border-radius: 3px; transition: width .4s; }
.wm-bpoly-pct {
    font-size: 13px; font-weight: 800; min-width: 36px;
    text-align: left; font-family: monospace;
}
.wm-bpoly-sub {
    display: flex; justify-content: space-between;
    font-size: 9px; color: #475569; margin-top: 3px;
}
.wm-bpoly-change.up   { color: #22c55e; }
.wm-bpoly-change.down { color: #ef4444; }
.wm-bpoly-change.flat { color: #64748b; }
.wm-bpoly-loading { color:#475569; font-size:11px; text-align:center; padding:20px; }

/* IODA block body */
#wm-block-ioda-body {
    padding: 6px 8px;
    max-height: 220px;
    overflow-y: auto;
    display: flex;
    flex-direction: column;
    gap: 5px;
}
.wm-bioda-row {
    display: flex; align-items: center; gap: 8px;
    background: #0f172a; border-radius: 5px; padding: 5px 8px;
    border-right: 3px solid transparent;
}
.wm-bioda-row.critical { border-right-color: #ef4444; }
.wm-bioda-row.warning  { border-right-color: #eab308; }
.wm-bioda-row.normal   { border-right-color: #22c55e; }
.wm-bioda-flag  { font-size: 15px; min-width: 22px; }
.wm-bioda-name  { font-size: 11px; font-weight: 600; color: #e2e8f0; min-width: 55px; }
.wm-bioda-bar-bg { flex: 1; height: 5px; background: #1e293b; border-radius: 3px; overflow: hidden; }
.wm-bioda-bar-fill { height: 100%; border-radius: 3px; transition: width .4s; }
.wm-bioda-drop { font-size: 10px; font-weight: 700; min-width: 38px; text-align: left; }
.wm-bioda-badge {
    font-size: 8px; padding: 1px 5px; border-radius: 3px;
    white-space: nowrap; font-weight: 600;
}
.wm-bioda-badge.critical { background:rgba(239,68,68,.2);  color:#ef4444; }
.wm-bioda-badge.warning  { background:rgba(234,179,8,.2);  color:#eab308; }
.wm-bioda-badge.normal   { background:rgba(34,197,94,.2);  color:#22c55e; }
.wm-bioda-loading { color:#475569; font-size:11px; text-align:center; padding:20px; }

/* ── بلوك التقرير الاستخباراتي اليومي ───────────────────────── */
.wm-block-brief {
    grid-column: span 4;
    border-color: #7c3aed !important;
}
.wm-block-brief .wm-block-header {
    background: linear-gradient(90deg, #1e1b4b, #1e293b);
    border-bottom-color: #7c3aed33;
}
.wm-block-brief .wm-block-icon { font-size: 16px; }

#wm-block-brief-body {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 12px;
    padding: 14px;
}
@media (max-width: 700px) {
    #wm-block-brief-body { grid-template-columns: 1fr; }
    .wm-block-brief { grid-column: span 2; }
}

/* الملخص التنفيذي */
.wm-brief-summary {
    grid-column: span 2;
    background: #0f172a;
    border: 1px solid #7c3aed44;
    border-radius: 8px;
    padding: 12px 16px;
}
.wm-brief-summary-label {
    font-size: 9px; color: #7c3aed; font-weight: 700;
    text-transform: uppercase; letter-spacing: 1px; margin-bottom: 5px;
}
.wm-brief-summary-text {
    font-size: 12px; color: #cbd5e1; line-height: 1.7; direction: rtl;
}

/* أبرز الأحداث */
.wm-brief-events { grid-column: span 1; }
.wm-brief-events-title {
    font-size: 10px; color: #94a3b8; font-weight: 700;
    margin-bottom: 8px; direction: rtl;
}
.wm-brief-event {
    display: flex; align-items: flex-start; gap: 8px;
    padding: 7px 0; border-bottom: 1px solid #1e293b; direction: rtl;
}
.wm-brief-event:last-child { border-bottom: none; }
.wm-brief-event-dot {
    width: 8px; height: 8px; border-radius: 50%; margin-top: 4px;
    flex-shrink: 0;
}
.wm-brief-event-dot.high   { background: #ef4444; }
.wm-brief-event-dot.medium { background: #f97316; }
.wm-brief-event-dot.low    { background: #22c55e; }
.wm-brief-event-text {
    font-size: 11px; color: #e2e8f0; line-height: 1.5;
}
.wm-brief-event-analysis {
    font-size: 10px; color: #64748b; margin-top: 2px;
}

/* الاتجاهات والتوقعات */
.wm-brief-right { grid-column: span 1; display: flex; flex-direction: column; gap: 10px; }
.wm-brief-box {
    background: #0f172a; border-radius: 8px; padding: 10px 14px;
    flex: 1;
}
.wm-brief-box-label {
    font-size: 9px; font-weight: 700; letter-spacing: 1px;
    margin-bottom: 5px; text-transform: uppercase;
}
.wm-brief-box-label.trends  { color: #06b6d4; }
.wm-brief-box-label.forecast { color: #a78bfa; }
.wm-brief-box-text {
    font-size: 11px; color: #cbd5e1; line-height: 1.6; direction: rtl;
}

.wm-brief-loading {
    grid-column: span 2; text-align: center;
    color: #475569; font-size: 12px; padding: 20px;
}
.wm-brief-disabled {
    grid-column: span 2; text-align: center;
    color: #475569; font-size: 11px; padding: 16px;
}

/* ── طبقة النزاعات المسلحة ───────────────────────────────── */
.wm-conflict-pulse {
    animation: conflict-pulse 2s ease-in-out infinite;
}
@keyframes conflict-pulse {
    0%   { stroke-opacity: 1; stroke-width: 2px; }
    50%  { stroke-opacity: 0.3; stroke-width: 5px; }
    100% { stroke-opacity: 1; stroke-width: 2px; }
}
#wm-conflict-toggle.active {
    background: rgba(220, 38, 38, 0.25) !important;
    border-color: #dc2626 !important;
    color: #fca5a5 !important;
}

/* ── قنوات OSINT Telegram ────────────────────────────────── */
.wm-item[data-type="telegram_osint"] {
    border-right-color: #818cf8 !important;
    background: linear-gradient(to left, rgba(129,140,248,0.04), transparent 60%);
}
.wm-item[data-type="telegram_osint"] .wm-item-src {
    color: #818cf8;
}
#wm-osint-btn.active {
    border-color: #818cf8;
    color: #a5b4fc;
}
#wm-osint-btn:not(.active) {
    opacity: 0.45;
}

/* ══════════════════════════════════════════════════
   v4.0 — Mobile Responsive
══════════════════════════════════════════════════ */
@media (max-width: 768px) {
  #wm-sidebar {
    width: 100%;
    top: auto;
    bottom: 0;
    height: 55vh;
    border-right: none;
    border-top: 1px solid var(--wm-border);
    transform: translateY(0);
  }
  #wm-sidebar.wm-sidebar-closed {
    transform: translateY(100%);
  }
  #wm-layer-dock {
    right: 8px;
    top: auto;
    bottom: 48px;
    transform: none;
    flex-direction: row;
    border-radius: 8px;
    padding: 5px 8px;
  }
  #wm-topbar { padding: 6px 10px; left: 0 !important; right: 0 !important; }
  .wm-topbar-logo { font-size: 14px; letter-spacing: 1px; }
  .wm-topbar-center { display: none; }
  #wm-map-hud { bottom: 60px; right: 52px; }
  /* إخفاء عناصر desktop غير ضرورية */
  #wm-conn-label { display: none; }
  .wm-topbar-count { display: none; }
  /* sidebar يصبح bottom sheet — المحتوى يبتعد عن bottom nav */
  #wm-sidebar .wm-sb-content { padding-bottom: 0; }
  /* layer dock يرتفع فوق الـ bottom nav */
  #wm-layer-dock { bottom: 64px; }
  /* إخفاء زر toggle القديم — bottom nav تحل محله */
  #wm-sidebar-toggle { display: none; }

  /* ── مدمج من بلوكات 768px السابقة ── */
  .wm-layout { flex-direction: column; height: auto; }
  .wm-panel { width: 100%; border-right: none; border-top: 1px solid var(--wm-border); }
  .wm-threat-counter { display: none; }
  #wm-tension-bar { padding: 4px 8px; }
  .wm-source-toggles { display: none; }
  #wm-breaking-panel { width: 100%; }
  #wm-country-bar { flex-wrap: nowrap; overflow-x: auto; }
}

/* تأكد من أن الـ wm-root يملأ الشاشة كاملة */
#wm-root {
  position: fixed !important;
  inset: 0 !important;
  width: 100vw !important;
  height: 100vh !important;
  z-index: 9999 !important;
  border: none !important;
  border-radius: 0 !important;
}

/* إخفاء عناصر WordPress عند التحميل */
body:has(#wm-root) .site-header,
body:has(#wm-root) .site-footer,
body:has(#wm-root) #masthead,
body:has(#wm-root) #colophon {
  display: none !important;
}
body:has(#wm-root) {
  overflow: hidden !important;
  padding: 0 !important;
  margin: 0 !important;
}

/* ── تعريف .wm-panel (متوافق مع JS القديم) ── */
.wm-panel { display: contents; }
.wm-panel-header { display: contents; }
.wm-panel-header > .wm-panel-tools {
  display: flex;
  gap: 6px;
  padding: 6px 8px;
  border-bottom: 1px solid var(--wm-border);
  background: rgba(6,12,20,0.6);
  flex-shrink: 0;
}
/* عدادات التهديد القديمة — مخفية */
.wm-threat-counter { display: none !important; }

/* ══════════════════════════════════════════════════
   v4.1 — Popup Card Design
══════════════════════════════════════════════════ */

/* Leaflet popup wrapper */
.leaflet-popup-content-wrapper {
  background: transparent !important;
  border: none !important;
  box-shadow: none !important;
  padding: 0 !important;
  border-radius: 0 !important;
}
.leaflet-popup-tip-container { display: none !important; }
.leaflet-popup-content {
  margin: 0 !important;
  width: auto !important;
}

/* البطاقة الرئيسية */
.wm-popup-card {
  width: 280px;
  background: rgba(7,14,24,0.97);
  border: 1px solid rgba(30,58,90,0.8);
  border-radius: 10px;
  overflow: hidden;
  box-shadow: 0 8px 32px rgba(0,0,0,0.6), 0 0 0 1px rgba(0,212,255,0.1);
  direction: rtl;
  font-family: 'Noto Kufi Arabic', sans-serif;
  backdrop-filter: blur(16px);
}

/* شريط اللون العلوي */
.wm-pc-bar {
  height: 3px;
  width: 100%;
}

.wm-pc-body {
  padding: 12px 14px;
}

/* المصدر + الوقت */
.wm-pc-meta {
  display: flex;
  flex-direction: row-reverse;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 8px;
  direction: rtl;
}
.wm-pc-src {
  font-size: 11px;
  color: var(--wm-accent);
  font-family: 'Share Tech Mono', monospace;
  font-weight: 600;
}
.wm-pc-time {
  font-size: 10px;
  color: #475569;
  font-family: 'Share Tech Mono', monospace;
  background: rgba(30,58,90,0.4);
  padding: 1px 6px;
  border-radius: 8px;
}

/* العنوان */
.wm-pc-title {
  font-size: 13px;
  font-weight: 600;
  line-height: 1.6;
  color: #e2e8f0;
  margin-bottom: 8px;
  text-align: right;
  direction: rtl;
}

/* الملخص */
.wm-pc-summary {
  font-size: 11px;
  color: #64748b;
  line-height: 1.5;
  margin-bottom: 8px;
  border-right: 2px solid rgba(0,212,255,0.3);
  padding-right: 8px;
  text-align: right;
  direction: rtl;
}

/* Footer: score + trend + category */
.wm-pc-footer {
  display: flex;
  gap: 6px;
  align-items: center;
  flex-wrap: wrap;
  margin-bottom: 10px;
  direction: rtl;
  justify-content: flex-start;
}
.wm-pc-score {
  font-size: 10px;
  font-family: 'Share Tech Mono', monospace;
  font-weight: 700;
  padding: 2px 8px;
  border-radius: 10px;
  border: 1px solid;
}
.wm-pc-trend {
  font-size: 10px;
  color: #64748b;
  background: rgba(30,58,90,0.5);
  padding: 2px 7px;
  border-radius: 8px;
}
.wm-pc-cat {
  font-size: 10px;
  color: #475569;
  background: rgba(30,58,90,0.3);
  padding: 2px 7px;
  border-radius: 8px;
}

/* زر القراءة */
.wm-pc-link {
  display: block;
  text-align: center;
  background: rgba(0,212,255,0.08);
  border: 1px solid rgba(0,212,255,0.25);
  color: var(--wm-accent);
  font-size: 12px;
  padding: 6px 12px;
  border-radius: 6px;
  text-decoration: none;
  transition: all .2s;
}
.wm-pc-link:hover {
  background: rgba(0,212,255,0.18);
  border-color: var(--wm-accent);
  color: #fff;
}

/* بطاقة الزلازل */
.wm-pc-mag {
  font-family: 'Share Tech Mono', monospace;
  font-size: 42px;
  font-weight: 900;
  line-height: 1;
  margin-bottom: 6px;
  letter-spacing: -1px;
}
.wm-pc-mag-unit {
  font-size: 14px;
  font-weight: 400;
  margin-right: 4px;
  opacity: 0.7;
}

/* ══════════════════════════════════════════════════
   v4.3 — Critical Marker Pulse Animation
══════════════════════════════════════════════════ */

.wm-marker-critical {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
}

/* النقطة المركزية */
.wm-marker-dot {
  border-radius: 50%;
  border: 2px solid rgba(255,255,255,0.7);
  position: relative;
  z-index: 2;
  flex-shrink: 0;
}

/* حلقة النبض */
.wm-pulse-ring {
  position: absolute;
  inset: 0;
  border-radius: 50%;
  border: 2px solid;
  opacity: 0;
  animation: wm-critical-pulse 2s ease-out infinite;
}
.wm-pulse-ring-2 {
  animation-delay: 1s;
}

@keyframes wm-critical-pulse {
  0%   { transform: scale(0.4); opacity: 0.8; }
  80%  { transform: scale(1);   opacity: 0;   }
  100% { transform: scale(1);   opacity: 0;   }
}

/* ══ نظام النبض الموسّع — v4.7.4 ══════════════════ */

/* نبض بطيء — التوترات المتوسطة */
.wm-pulse-slow .wm-pulse-ring {
  animation-duration: 3s;
}
.wm-pulse-slow .wm-pulse-ring-2 {
  animation-delay: 1.5s;
}

/* نبض سريع جداً — طوارئ */
.wm-pulse-fast .wm-pulse-ring {
  animation-duration: 1s;
}
.wm-pulse-fast .wm-pulse-ring-2 {
  animation-delay: 0.5s;
}

/* نبض ثلاثي الحلقات */
.wm-pulse-ring-3 {
  position: absolute;
  inset: 0;
  border-radius: 50%;
  border: 1px solid;
  opacity: 0;
  animation: wm-critical-pulse 2s ease-out infinite;
  animation-delay: 0.65s;
}

/* ══ النقطة المركزية المتوهجة ══ */
.wm-marker-dot-glow {
  border-radius: 50%;
  border: 2px solid rgba(255,255,255,0.8);
  position: relative;
  z-index: 2;
  flex-shrink: 0;
  animation: wm-dot-glow 2s ease-in-out infinite alternate;
}
@keyframes wm-dot-glow {
  0%   { box-shadow: 0 0 4px currentColor, 0 0 8px currentColor; }
  100% { box-shadow: 0 0 10px currentColor, 0 0 20px currentColor, 0 0 30px currentColor44; }
}

/* ══ تأثير رادار دوّار (للزلازل القوية) ══ */
.wm-radar-sweep {
  position: absolute;
  inset: -4px;
  border-radius: 50%;
  border: 2px solid transparent;
  border-top-color: currentColor;
  animation: wm-radar-spin 1.5s linear infinite;
  opacity: 0.6;
}
@keyframes wm-radar-spin {
  to { transform: rotate(360deg); }
}

/* ══ تأثير هالة للمناطق المنهارة اقتصادياً ══ */
.wm-halo-pulse {
  position: absolute;
  inset: -6px;
  border-radius: 50%;
  opacity: 0;
  animation: wm-halo 3s ease-out infinite;
}
@keyframes wm-halo {
  0%   { transform: scale(0.5); opacity: 0.6; }
  70%  { transform: scale(1.8); opacity: 0;   }
  100% { opacity: 0; }
}

/* ══ نبض مزدوج للتهديدات السيبرانية ══ */
.wm-cyber-pulse {
  position: absolute;
  inset: 0;
  border-radius: 50%;
  border: 1px solid #8b5cf6;
  opacity: 0;
  animation: wm-cyber-blink 1.2s steps(1) infinite;
}
@keyframes wm-cyber-blink {
  0%, 49% { opacity: 0.8; transform: scale(1); }
  50%, 100% { opacity: 0; transform: scale(1.5); }
}

/* ══════════════════════════════════════════════════
   v4.4 — Stats Panel inside Sidebar
══════════════════════════════════════════════════ */

.wm-stats-panel {
  flex: 1;
  overflow: hidden;
  min-height: 0;
}
.wm-sp-scroll {
  height: 100%;
  overflow-y: auto;
  scrollbar-width: thin;
  scrollbar-color: var(--wm-border) transparent;
  padding: 8px;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

/* بلوك واحد */
.wm-sp-block {
  background: rgba(13,26,42,0.6);
  border: 1px solid var(--wm-border);
  border-radius: 8px;
  overflow: hidden;
  flex-shrink: 0;
}
.wm-sp-head {
  padding: 8px 12px;
  font-size: 11px;
  font-weight: 700;
  color: var(--wm-accent);
  font-family: var(--wm-font-mono);
  letter-spacing: 0.5px;
  border-bottom: 1px solid rgba(30,58,90,0.5);
  display: flex;
  align-items: center;
  gap: 6px;
}
.wm-sp-badge {
  font-size: 10px;
  font-weight: 700;
  padding: 1px 7px;
  border-radius: 8px;
  background: rgba(34,197,94,0.15);
  border: 1px solid rgba(34,197,94,0.4);
  color: #22c55e;
  margin-right: auto;
}
.wm-sp-badge-sm {
  font-size: 10px;
  color: var(--wm-text-dim);
  font-weight: 400;
  margin-right: auto;
}
.wm-sp-body {
  padding: 8px 12px;
}
.wm-sp-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 4px 0;
  font-size: 11px;
  color: var(--wm-text-dim);
  border-bottom: 1px solid rgba(30,58,90,0.2);
}
.wm-sp-row:last-child { border-bottom: none; }
.wm-sp-row strong { font-family: var(--wm-font-mono); font-size: 12px; }

/* الوضع العالمي */
.wm-sp-status { border-color: rgba(34,197,94,0.3); }
.wm-sp-score-row { display: flex; gap: 12px; align-items: flex-start; margin-bottom: 8px; }
.wm-sp-bigscore {
  font-family: var(--wm-font-mono);
  font-size: 36px;
  font-weight: 900;
  color: var(--wm-green);
  line-height: 1;
  flex-shrink: 0;
  min-width: 48px;
}
.wm-sp-rows { flex: 1; }

/* توزيع التهديد */
.wm-sp-dist {
  display: grid;
  grid-template-columns: 1fr 1fr 1fr 1fr;
  gap: 6px;
  padding: 8px;
}
.wm-sp-dist-item {
  border: 1px solid;
  border-radius: 6px;
  padding: 8px 4px;
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 3px;
}
.wm-sp-dist-item span {
  font-family: var(--wm-font-mono);
  font-size: 20px;
  font-weight: 900;
  line-height: 1;
}
.wm-sp-dist-item small { font-size: 9px; color: var(--wm-text-dim); }

.wm-sp-loading { font-size: 11px; color: var(--wm-text-dim); padding: 8px 12px; }

/* ══════════════════════════════════════════════════
   v4.3.3 — Stats Overlay Panel
══════════════════════════════════════════════════ */

#wm-stats-overlay {
  position: fixed;
  inset: 0;
  z-index: 600;
  background: rgba(4,8,16,0.92);
  backdrop-filter: blur(12px);
  display: flex;
  flex-direction: column;
  overflow: hidden;
  animation: wm-so-in .2s ease-out;
}
@keyframes wm-so-in {
  from { opacity:0; transform: translateY(10px); }
  to   { opacity:1; transform: translateY(0); }
}

.wm-so-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px 20px;
  border-bottom: 1px solid var(--wm-border);
  background: rgba(6,12,20,0.9);
  flex-shrink: 0;
}
.wm-so-title {
  font-family: var(--wm-font-hd);
  font-size: 15px;
  font-weight: 700;
  color: var(--wm-accent);
  letter-spacing: 1px;
}
.wm-so-close {
  background: rgba(239,68,68,0.15);
  border: 1px solid rgba(239,68,68,0.4);
  color: #ef4444;
  width: 30px; height: 30px;
  border-radius: 6px;
  cursor: pointer;
  font-size: 14px;
  display: flex; align-items: center; justify-content: center;
  transition: background .15s;
}
.wm-so-close:hover { background: rgba(239,68,68,0.3); }

.wm-so-grid {
  flex: 1;
  overflow-y: auto;
  padding: 16px;
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  grid-auto-rows: min-content;
  gap: 12px;
  align-content: start;
  scrollbar-width: thin;
  scrollbar-color: var(--wm-border) transparent;
  direction: rtl;
}
@media (max-width: 1100px) { .wm-so-grid { grid-template-columns: repeat(2,1fr); } }
@media (max-width: 600px)  { .wm-so-grid { grid-template-columns: 1fr; } }

/* Stats overlay — بلوكات بحجمها الطبيعي */
.wm-so-grid .wm-block {
  height: auto !important;
  min-height: unset !important;
  overflow: visible !important;
}
.wm-so-grid .wm-block-body {
  height: auto !important;
  max-height: none !important;
  overflow: visible !important;
}
/* البلوكات ذات المحتوى الطويل تأخذ scroll خاص */
.wm-so-grid #wm-block-sources .wm-block-body,
.wm-so-grid #wm-block-tensions .wm-block-body,
.wm-so-grid #wm-block-regions .wm-block-body {
  max-height: 220px;
  overflow-y: auto;
}
.wm-so-grid .wm-block-wide {
  grid-column: span 2;
}
.wm-so-grid .wm-block-live { display: none !important; }
.wm-so-grid .wm-block-brief { display: none !important; }


/* ── Live Overlay ── */
#wm-live-overlay {
  position: fixed;
  inset: 0;
  z-index: 600;
  background: rgba(4,8,16,0.96);
  backdrop-filter: blur(16px);
  display: flex;
  flex-direction: column;
  animation: wm-so-in .2s ease-out;
}
.wm-lo-body {
  flex: 1;
  display: flex;
  gap: 0;
  overflow: hidden;
  min-height: 0;
}

/* قائمة القنوات — عمود يمين */
.wm-lo-channels {
  width: 200px;
  flex-shrink: 0;
  background: rgba(6,12,20,0.9);
  border-left: 1px solid var(--wm-border);
  overflow-y: auto;
  display: flex;
  flex-direction: column;
  padding: 12px 0;
  gap: 2px;
  scrollbar-width: thin;
}
.wm-lo-ch {
  background: transparent;
  border: none;
  color: var(--wm-text-dim);
  padding: 10px 16px;
  text-align: right;
  cursor: pointer;
  font-size: 13px;
  font-family: var(--wm-font-ar);
  transition: background .15s, color .15s;
  display: flex;
  align-items: center;
  gap: 8px;
  border-right: 3px solid transparent;
}
.wm-lo-ch:hover {
  background: rgba(59,130,246,0.1);
  color: var(--wm-text);
}
.wm-lo-ch.active {
  background: rgba(239,68,68,0.12);
  color: #f87171;
  border-right-color: #ef4444;
}

/* مشغّل الفيديو */
.wm-lo-player-wrap {
  flex: 1;
  position: relative;
  background: #000;
}
.wm-lo-player-wrap iframe {
  width: 100%;
  height: 100%;
  border: none;
  display: block;
}
.wm-lo-badge {
  position: absolute;
  top: 16px;
  left: 16px;
  background: rgba(239,68,68,0.9);
  color: #fff;
  font-size: 11px;
  font-weight: 700;
  padding: 3px 10px;
  border-radius: 4px;
  display: flex;
  align-items: center;
  gap: 6px;
  letter-spacing: 1px;
  pointer-events: none;
}

/* زر البث مفعّل */
#wm-live-overlay-toggle.active {
  background: rgba(239,68,68,0.25);
  border-color: rgba(239,68,68,0.6);
  color: #f87171;
}

/* YouTube IFrame API player */
#wm-lo-player {
  width: 100%;
  height: 100%;
}
#wm-lo-player iframe {
  width: 100% !important;
  height: 100% !important;
}

#wm-lo-fallback {
  display: none;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 16px;
  width: 100%; height: 100%;
  color: #94a3b8;
  font-size: 14px;
  background: #040810;
}
#wm-lo-extlink {
  color: #60a5fa;
  font-size: 15px;
  text-decoration: none;
  padding: 10px 20px;
  border: 1px solid #3b82f6;
  border-radius: 8px;
}
#wm-lo-extlink:hover { background: rgba(59,130,246,0.15); }
#wm-lo-iframe { width:100%; height:100%; border:none; display:block; }

/* ══════════════════════════════════════════════════
   v4.6 — Cyber Threat Monitor
══════════════════════════════════════════════════ */

#wm-cyber-overlay {
  position: fixed; inset: 0; z-index: 600;
  background: rgba(4,8,16,0.97);
  display: flex; flex-direction: column;
  direction: rtl; font-family: inherit;
}

.wm-cyber-body {
  flex: 1; display: flex; flex-direction: column;
  overflow: hidden; padding: 0;
}

/* Stats Bar */
.wm-cyber-stats {
  display: grid; grid-template-columns: repeat(4,1fr);
  gap: 1px; background: var(--wm-border);
  border-bottom: 1px solid var(--wm-border);
  flex-shrink: 0;
}
.wm-cstat {
  background: var(--wm-bg2);
  padding: 12px 16px;
  display: flex; flex-direction: column; align-items: center; gap: 4px;
}
.wm-cstat-val {
  font-size: 22px; font-weight: 800; color: #e2e8f0; font-variant-numeric: tabular-nums;
}
.wm-cstat-lbl { font-size: 11px; color: #475569; letter-spacing: .5px; }
.wm-cs-red    { color: #ef4444 !important; }
.wm-cs-orange { color: #f97316 !important; }
.wm-cs-purple { color: #a855f7 !important; }

/* Tabs */
.wm-cyber-tabs {
  display: flex; gap: 0; border-bottom: 1px solid var(--wm-border);
  flex-shrink: 0; background: var(--wm-bg);
}
.wm-ctab {
  flex: 1; padding: 10px; font-size: 12px; font-weight: 600;
  background: transparent; border: none; border-bottom: 2px solid transparent;
  color: #475569; cursor: pointer; transition: all .2s;
}
.wm-ctab.active { color: #60a5fa; border-bottom-color: #3b82f6; background: rgba(59,130,246,.06); }
.wm-ctab:hover:not(.active) { color: #94a3b8; background: rgba(255,255,255,.03); }

/* Panels */
.wm-cyber-panel {
  flex: 1; overflow-y: auto; padding: 12px;
  scrollbar-width: thin; scrollbar-color: var(--wm-border) transparent;
}
.wm-cyber-loading {
  text-align: center; padding: 40px; color: #475569; font-size: 14px;
}

/* IP Row */
.wm-cyber-ip-row {
  display: flex; align-items: center; gap: 10px;
  padding: 8px 12px; border-radius: 6px;
  background: rgba(255,255,255,.03); border: 1px solid var(--wm-border);
  margin-bottom: 6px; transition: border-color .2s;
}
.wm-cyber-ip-row:hover { border-color: rgba(59,130,246,.3); }
.wm-cip-icon  { font-size: 18px; flex-shrink: 0; }
.wm-cip-info  { flex: 1; min-width: 0; }
.wm-cip-addr  { font-size: 12px; font-family: monospace; color: #94a3b8; }
.wm-cip-label { font-size: 13px; font-weight: 600; color: #e2e8f0; }
.wm-cip-country { font-size: 11px; color: #64748b; }
.wm-cip-score {
  font-size: 11px; font-weight: 700; padding: 2px 8px;
  border-radius: 20px; background: rgba(239,68,68,.15); color: #ef4444;
  flex-shrink: 0;
}
.wm-cip-bar-wrap {
  width: 60px; height: 4px; background: rgba(255,255,255,.08);
  border-radius: 2px; flex-shrink: 0; overflow: hidden;
}
.wm-cip-bar { height: 100%; border-radius: 2px; transition: width .5s; }

/* Vuln Row */
.wm-cyber-vuln-row {
  padding: 10px 14px; border-radius: 8px;
  background: rgba(255,255,255,.03); border: 1px solid var(--wm-border);
  margin-bottom: 8px;
}
.wm-cv-header { display: flex; align-items: center; gap: 8px; margin-bottom: 4px; }
.wm-cv-id     { font-size: 12px; font-family: monospace; color: #60a5fa; font-weight: 700; }
.wm-cv-badge  { font-size: 10px; padding: 1px 6px; border-radius: 10px; font-weight: 700; }
.wm-cv-badge.critical { background: rgba(220,38,38,.2); color: #ef4444; }
.wm-cv-badge.high     { background: rgba(249,115,22,.2); color: #f97316; }
.wm-cv-badge.medium   { background: rgba(234,179,8,.2);  color: #eab308; }
.wm-cv-name   { font-size: 13px; font-weight: 600; color: #e2e8f0; margin-bottom: 3px; }
.wm-cv-vendor { font-size: 11px; color: #64748b; }
.wm-cv-desc   { font-size: 12px; color: #94a3b8; margin-top: 4px; }
.wm-cv-date   { font-size: 10px; color: #475569; margin-top: 4px; }

/* News Row */
.wm-cyber-news-row {
  padding: 10px 14px; border-radius: 8px;
  background: rgba(255,255,255,.03); border: 1px solid var(--wm-border);
  margin-bottom: 8px; cursor: pointer; transition: border-color .2s;
}
.wm-cyber-news-row:hover { border-color: rgba(59,130,246,.3); }
.wm-cn-title  { font-size: 13px; font-weight: 600; color: #e2e8f0; margin-bottom: 4px; line-height: 1.5; }
.wm-cn-meta   { display: flex; align-items: center; gap: 8px; }
.wm-cn-source { font-size: 11px; color: #64748b; }
.wm-cn-badge  { font-size: 10px; padding: 1px 7px; border-radius: 10px; }
.wm-cn-date   { font-size: 10px; color: #475569; margin-right: auto; }

/* Map markers */
.wm-cyber-marker { cursor: pointer; }
.wm-cyber-pulse {
  width: 10px; height: 10px; border-radius: 50%;
  position: relative; display: flex; align-items: center; justify-content: center;
}
.wm-cyber-pulse::after {
  content: '';
  position: absolute;
  width: 100%; height: 100%;
  border-radius: 50%;
  animation: wm-cyber-pulse-anim 2s ease-out infinite;
  opacity: .6;
}
@keyframes wm-cyber-pulse-anim {
  0%   { transform: scale(1);   opacity: .6; }
  100% { transform: scale(3);   opacity: 0;  }
}

/* HUD — Cyber Counter */
.wm-threat.cybercount span { color: #a855f7; }
.wm-threat.cybercount:hover { background: rgba(168,85,247,0.15); border-color: rgba(168,85,247,0.4); }
.wm-cyber-hud-alert span { animation: wm-cyber-hud-blink 1.5s ease-in-out infinite; }
@keyframes wm-cyber-hud-blink {
  0%,100% { color: #a855f7; }
  50%      { color: #ef4444; text-shadow: 0 0 8px #ef4444; }
}

/* HUD — Tension Counter */
.wm-threat.tensioncount span { color: #eab308; }
.wm-threat.tensioncount:hover { background: rgba(234,179,8,0.15); border-color: rgba(234,179,8,0.4); }
.wm-tension-hud-alert span { animation: wm-tension-hud-pulse 1.8s ease-in-out infinite; }
@keyframes wm-tension-hud-pulse {
  0%,100% { color: #f97316; }
  50%      { color: #ef4444; text-shadow: 0 0 8px #ef4444aa; }
}
.wm-threat.tensioncount { transition: opacity .3s; }

/* ══════════════════════════════════════════════════
   💹 القسم الاقتصادي — v4.7.0
   ══════════════════════════════════════════════════ */

/* Overlay */
#wm-economy-overlay {
    position: absolute;
    inset: 0;
    z-index: 800;
    background: rgba(5,10,20,0.97);
    display: flex;
    flex-direction: column;
    backdrop-filter: blur(16px);
    overflow: hidden;
}

/* Ticker شريط سريع */
.wm-eco-ticker {
    display: flex;
    align-items: center;
    gap: 0;
    padding: 7px 16px;
    background: rgba(10,18,32,0.9);
    border-bottom: 1px solid #1e3a5a;
    overflow-x: auto;
    scrollbar-width: none;
    flex-shrink: 0;
    flex-wrap: wrap;
    row-gap: 4px;
}
.wm-eco-ticker::-webkit-scrollbar { display: none; }
.wm-eco-tick-item {
    font-size: 12px;
    color: #cbd5e1;
    white-space: nowrap;
    padding: 0 8px;
    font-family: var(--wm-font-ar);
}
.wm-eco-tick-sep { color: #334155; }

/* Refresh button */
.wm-so-refresh {
    background: rgba(37,99,235,0.15);
    border: 1px solid rgba(37,99,235,0.3);
    color: #3b82f6;
    width: 26px; height: 26px;
    border-radius: 5px;
    cursor: pointer;
    font-size: 16px;
    transition: all .2s;
    display: flex; align-items: center; justify-content: center;
}
.wm-so-refresh:hover { background: #3b82f6; color: #fff; }

/* تبويبات */
.wm-eco-tabs {
    display: flex;
    gap: 2px;
    padding: 8px 12px 0;
    background: rgba(8,14,26,0.95);
    border-bottom: 1px solid #1e3a5a;
    flex-shrink: 0;
}
.wm-etab {
    flex: 1;
    background: none;
    border: none;
    border-bottom: 2px solid transparent;
    color: #64748b;
    padding: 8px 4px;
    font-size: 12.5px;
    cursor: pointer;
    transition: all .2s;
    font-family: var(--wm-font-ar);
    white-space: nowrap;
    text-align: center;
}
.wm-etab:hover  { color: #e2e8f0; }
.wm-etab.active { color: #22c55e; border-bottom-color: #22c55e; }

/* Panels */
.wm-eco-panel {
    flex: 1;
    overflow-y: auto;
    padding: 12px;
    scrollbar-width: thin;
    scrollbar-color: #1e3a5a transparent;
    min-height: 0;
}
.wm-eco-body {
    display: flex;
    flex-direction: column;
    flex: 1;
    overflow: hidden;
    min-height: 0;
}
.wm-eco-loading {
    text-align: center;
    color: #475569;
    padding: 40px 20px;
    font-size: 13px;
}

/* Grid البطاقات (سلع + كريبتو) */
.wm-eco-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 10px;
}
.wm-eco-card {
    display: flex;
    align-items: center;
    gap: 10px;
    background: rgba(15,23,42,0.8);
    border: 1px solid #1e3a5a;
    border-radius: 10px;
    padding: 11px 12px;
    transition: border-color .2s, background .2s;
    cursor: default;
}
.wm-eco-card:hover { border-color: #334155; background: rgba(20,30,50,0.9); }
.wm-eco-card-icon {
    width: 38px; height: 38px;
    border-radius: 10px;
    display: flex; align-items: center; justify-content: center;
    font-size: 20px;
    flex-shrink: 0;
}
.wm-eco-card-info { flex: 1; min-width: 0; }
.wm-eco-card-name {
    font-size: 13px;
    font-weight: 600;
    color: #e2e8f0;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}
.wm-eco-card-sub {
    font-size: 10px;
    color: #475569;
    margin-top: 2px;
}
.wm-eco-card-price { text-align: left; }
.wm-eco-card-val {
    font-size: 13px;
    font-weight: 700;
    color: #f1f5f9;
    font-family: var(--wm-font-mono);
    white-space: nowrap;
}
.wm-eco-card-chg {
    font-size: 11px;
    font-weight: 600;
    margin-top: 2px;
    font-family: var(--wm-font-mono);
}

/* قائمة العملات */
.wm-eco-fx-list { display: flex; flex-direction: column; gap: 6px; }
.wm-eco-fx-row {
    display: grid;
    grid-template-columns: 28px 1fr auto;
    grid-template-rows: auto 4px;
    gap: 0 10px;
    align-items: center;
    background: rgba(15,23,42,0.7);
    border: 1px solid #1e3a5a;
    border-radius: 8px;
    padding: 9px 12px 6px;
    transition: border-color .15s;
}
.wm-eco-fx-row:hover { border-color: #334155; }
.wm-eco-fx-flag { font-size: 20px; grid-row: 1; }
.wm-eco-fx-info {
    display: flex; flex-direction: column; gap: 1px;
    grid-row: 1;
}
.wm-eco-fx-code { font-size: 13px; font-weight: 700; color: #e2e8f0; }
.wm-eco-fx-name { font-size: 10px; color: #475569; }
.wm-eco-fx-right {
    display: flex; flex-direction: column; align-items: flex-end; gap: 2px;
    grid-row: 1;
}
.wm-eco-fx-rate  { font-size: 13px; font-weight: 700; color: #f1f5f9; font-family: monospace; }
.wm-eco-fx-status { font-size: 10px; font-weight: 600; }
.wm-eco-fx-bar {
    grid-column: 1 / -1;
    grid-row: 2;
    height: 3px;
    background: #1e3a5a;
    border-radius: 2px;
    margin-top: 5px;
    overflow: hidden;
}

/* بورصات */
.wm-eco-markets-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 10px;
}
.wm-eco-market-card {
    background: rgba(10,18,32,0.9);
    border: 1px solid #1e3a5a;
    border-radius: 10px;
    overflow: hidden;
}
.wm-eco-mkt-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 8px 10px;
    font-size: 12px;
    color: #e2e8f0;
    border-bottom: 1px solid #1e293b;
}

/* HUD — عداد اقتصادي */
.wm-threat.ecocount span { color: #22c55e; }
.wm-threat.ecocount:hover { background: rgba(34,197,94,0.12); border-color: rgba(34,197,94,0.4); }

/* ══════════════════════════════════════════════════
   🌬️ Windy Layer — v4.7.5
   ══════════════════════════════════════════════════ */

/* شريط التحكم العلوي */
.wm-windy-bar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 6px 12px;
    background: rgba(5,10,20,0.97);
    border-bottom: 1px solid #1e3a5a;
    gap: 10px;
    flex-shrink: 0;
    flex-wrap: wrap;
    z-index: 10;
}
.wm-windy-bar-left  { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.wm-windy-bar-right { display: flex; align-items: center; gap: 8px; }

.wm-windy-logo {
    font-size: 14px;
    font-weight: 700;
    color: #38bdf8;
    white-space: nowrap;
    letter-spacing: 0.5px;
}

/* أزرار اختيار الطبقة */
.wm-windy-layers { display: flex; gap: 4px; flex-wrap: wrap; }
.wm-wl-btn {
    background: rgba(15,23,42,0.8);
    border: 1px solid #1e3a5a;
    color: #64748b;
    padding: 4px 10px;
    border-radius: 6px;
    font-size: 11.5px;
    cursor: pointer;
    transition: all .15s;
    font-family: var(--wm-font-ar);
    white-space: nowrap;
}
.wm-wl-btn:hover  { color: #e2e8f0; border-color: #334155; background: rgba(30,58,90,0.5); }
.wm-wl-btn.active {
    color: #38bdf8;
    border-color: #38bdf8;
    background: rgba(56,189,248,0.12);
    font-weight: 600;
}

/* رابط فتح Windy */
.wm-windy-open {
    background: rgba(56,189,248,0.1);
    border: 1px solid rgba(56,189,248,0.3);
    color: #38bdf8;
    width: 26px; height: 26px;
    border-radius: 5px;
    display: flex; align-items: center; justify-content: center;
    font-size: 14px;
    text-decoration: none;
    transition: all .2s;
}
.wm-windy-open:hover { background: #38bdf8; color: #fff; }

/* Spinner تحميل */
.wm-windy-spinner {
    width: 36px; height: 36px;
    border: 3px solid #1e3a5a;
    border-top-color: #38bdf8;
    border-radius: 50%;
    animation: wm-spin 0.8s linear infinite;
}
@keyframes wm-spin { to { transform: rotate(360deg); } }

/* زر Windy في الـ dock */
#wm-windy-toggle.active {
    color: #38bdf8;
    background: rgba(56,189,248,0.15);
    border-color: rgba(56,189,248,0.4);
}

/* ══════════════════════════════════════════════════
   🛢️ طبقة تدفق النفط — v4.7.7
   ══════════════════════════════════════════════════ */

/* خطوط المسار */
.wm-oil-line {
    stroke-linecap: round;
    transition: opacity .3s;
}
.wm-oil-line:hover { opacity: 1 !important; }

/* جسيمات النفط المتحركة */
.wm-oil-particle {
    transition: none !important;
    pointer-events: none;
}

/* لافتة السعر على الخريطة */
.wm-oil-price-tag {
    background: rgba(5,10,20,0.92);
    border: 1px solid;
    border-radius: 8px;
    padding: 5px 12px;
    font-size: 13px;
    font-weight: 700;
    white-space: nowrap;
    font-family: var(--wm-font-ar);
    pointer-events: none;
    box-shadow: 0 2px 12px rgba(0,0,0,0.4);
}

/* زر النفط في الـ dock */
#wm-oilflow-toggle.active {
    color: #f59e0b;
    background: rgba(245,158,11,0.15);
    border-color: rgba(245,158,11,0.4);
}

/* ══════════════════════════════════════════════════
   🎯 رادار الكوارث — v4.8.0
   ══════════════════════════════════════════════════ */

#wm-radar-overlay {
    position: absolute;
    inset: 0;
    z-index: 810;
    background: rgba(5,10,20,0.97);
    display: flex;
    flex-direction: column;
    backdrop-filter: blur(16px);
}

/* شريط الملخص */
.wm-radar-summary {
    display: flex;
    gap: 0;
    padding: 8px 12px;
    background: rgba(10,18,32,0.9);
    border-bottom: 1px solid #1e3a5a;
    flex-shrink: 0;
}
.wm-radar-stat {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 2px;
    padding: 4px 0;
    border-left: 1px solid #1e3a5a;
}
.wm-radar-stat:last-child { border-left: none; }
.wm-radar-stat span { font-size: 20px; font-weight: 700; color: #e2e8f0; font-family: var(--wm-font-mono); }
.wm-radar-stat small { font-size: 10px; color: #475569; }

/* قائمة التنبيهات */
.wm-radar-list {
    flex: 1;
    overflow-y: auto;
    padding: 10px;
    display: flex;
    flex-direction: column;
    gap: 8px;
    scrollbar-width: thin;
    scrollbar-color: #1e3a5a transparent;
}
.wm-radar-empty {
    text-align: center;
    color: #22c55e;
    padding: 40px 20px;
    font-size: 14px;
}

/* بطاقة تنبيه */
.wm-radar-card {
    background: rgba(15,23,42,0.8);
    border: 1px solid #1e3a5a;
    border-radius: 10px;
    padding: 10px 12px;
    cursor: pointer;
    transition: border-color .2s, background .2s;
    position: relative;
    overflow: hidden;
}
.wm-radar-card:hover { background: rgba(20,30,50,0.95); }
.wm-radar-sev-critical { border-color: #ef444440; }
.wm-radar-sev-critical::before {
    content: '';
    position: absolute;
    top: 0; left: 0; right: 0;
    height: 2px;
    background: linear-gradient(90deg, transparent, #ef4444, transparent);
    animation: wm-radar-scanline 2s linear infinite;
}
@keyframes wm-radar-scanline {
    0%   { transform: translateX(-100%); }
    100% { transform: translateX(100%);  }
}
.wm-radar-sev-high     { border-color: #f9731640; }
.wm-radar-sev-med      { border-color: #eab30840; }

.wm-radar-card-top {
    display: flex;
    align-items: flex-start;
    gap: 10px;
}
.wm-radar-card-icon {
    width: 36px; height: 36px;
    border-radius: 8px;
    display: flex; align-items: center; justify-content: center;
    font-size: 18px;
    flex-shrink: 0;
}
.wm-radar-card-main { flex: 1; min-width: 0; }
.wm-radar-card-title {
    font-size: 13px;
    font-weight: 600;
    color: #e2e8f0;
    margin-bottom: 3px;
}
.wm-radar-card-detail { font-size: 11px; color: #64748b; margin-bottom: 3px; }
.wm-radar-card-assets { font-size: 11px; color: #94a3b8; }

/* chips المنشآت في بطاقات الرادار */
.wm-radar-assets-row {
    display: flex;
    flex-wrap: wrap;
    gap: 4px;
    margin-top: 4px;
}
.wm-asset-chip {
    display: inline-flex;
    align-items: center;
    gap: 3px;
    font-size: 10px;
    padding: 2px 6px;
    border-radius: 4px;
    border: 1px solid;
    background: rgba(255,255,255,0.03);
    cursor: default;
    white-space: nowrap;
}
.wm-radar-card-time {
    font-size: 10px;
    color: #334155;
    text-align: left;
    margin-top: 4px;
}
.wm-radar-sev-badge {
    font-size: 16px;
    font-weight: 700;
    padding: 4px 8px;
    border-radius: 6px;
    white-space: nowrap;
    font-family: var(--wm-font-mono);
    flex-shrink: 0;
}
.wm-radar-sev-badge small { font-size: 9px; }

/* تحليل AI */
.wm-radar-ai {
    display: flex;
    align-items: flex-start;
    gap: 6px;
    margin-top: 8px;
    padding: 7px 10px;
    background: rgba(99,102,241,0.08);
    border-right: 3px solid #6366f1;
    border-radius: 0 6px 6px 0;
    font-size: 11.5px;
    color: #cbd5e1;
    line-height: 1.5;
}
.wm-radar-ai > span { flex: 1; }

/* Toast التنبيه */
.wm-radar-toast {
    position: absolute;
    bottom: 160px;
    left: 50%;
    transform: translateX(-50%);
    z-index: 1200;
    background: rgba(5,10,20,0.97);
    border: 1px solid;
    border-radius: 12px;
    padding: 12px 16px;
    display: flex;
    align-items: center;
    gap: 12px;
    min-width: 300px;
    max-width: 450px;
    box-shadow: 0 8px 32px rgba(0,0,0,0.5);
    cursor: pointer;
    animation: wm-toast-in 0.3s ease;
    direction: rtl;
}
@keyframes wm-toast-in {
    from { opacity:0; transform: translateX(-50%) translateY(20px); }
    to   { opacity:1; transform: translateX(-50%) translateY(0); }
}
.wm-radar-toast-icon { font-size: 28px; flex-shrink: 0; }
.wm-radar-toast-body { flex: 1; min-width: 0; }
.wm-radar-toast-title { font-size: 11px; font-weight: 700; margin-bottom: 3px; }
.wm-radar-toast-msg   { font-size: 12px; color: #e2e8f0; }

/* HUD — عداد الرادار ينبض عند وجود حرج */
.wm-threat.radarcount span { color: #ef4444; }
.wm-threat.radarcount.wm-hud-critical {
    animation: wm-hud-blink 1s ease-in-out infinite alternate;
}
@keyframes wm-hud-blink {
    from { background: rgba(239,68,68,0.05); }
    to   { background: rgba(239,68,68,0.2);  border-color: rgba(239,68,68,0.5); }
}

/* زر الرادار في الـ dock */
#wm-radar-toggle.active {
    color: #ef4444;
    background: rgba(239,68,68,0.15);
    border-color: rgba(239,68,68,0.4);
}

/* ══════════════════════════════════════════════════
   ⚛️ المنشآت الاستراتيجية — Strategic Assets
   ══════════════════════════════════════════════════ */

/* زر التفعيل */
#wm-assets-toggle-btn.active {
    color: #a855f7;
    background: rgba(168,85,247,0.15);
    border-color: rgba(168,85,247,0.4);
}

/* لوحة المنشآت الاستراتيجية — يمين مثل المؤشرات الاقتصادية */
#wm-assets-panel {
    position: absolute;
    top: 48px;
    right: 52px;
    bottom: 80px;
    z-index: 820;
    background: rgba(6, 11, 22, 0.97);
    border-left: 1px solid #1e3a5a;
    border-bottom: 1px solid #1e3a5a;
    width: 300px;
    overflow: hidden;
    display: none;
    flex-direction: column;
    box-shadow: -6px 0 24px rgba(0,0,0,0.5);
    backdrop-filter: blur(14px);
    direction: rtl;
}
#wm-assets-panel.visible {
    display: flex;
    animation: wm-assets-slide-in 0.22s ease;
}
@keyframes wm-assets-slide-in {
    from { opacity: 0; transform: translateX(20px); }
    to   { opacity: 1; transform: translateX(0); }
}

.wm-ap-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 12px 16px;
    border-bottom: 1px solid #1e3a5a;
    background: rgba(6,12,20,0.95);
    flex-shrink: 0;
}
.wm-ap-header-title {
    font-size: 14px;
    font-weight: 700;
    color: #a855f7;
    letter-spacing: 0.5px;
    display: flex;
    align-items: center;
    gap: 7px;
}
.wm-ap-header-actions {
    display: flex;
    align-items: center;
    gap: 6px;
}
.wm-ap-close-btn {
    background: rgba(239,68,68,0.15);
    border: 1px solid rgba(239,68,68,0.4);
    color: #ef4444;
    width: 26px;
    height: 26px;
    border-radius: 5px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 13px;
    transition: background 0.15s;
}
.wm-ap-close-btn:hover { background: rgba(239,68,68,0.35); }
.wm-ap-stats-bar {
    display: flex;
    gap: 0;
    border-bottom: 1px solid #1e3a5a;
    flex-shrink: 0;
    background: rgba(8,15,28,0.9);
}
.wm-ap-stat {
    flex: 1;
    padding: 7px 4px;
    text-align: center;
    border-left: 1px solid #1e3a5a;
    cursor: default;
}
.wm-ap-stat:last-child { border-left: none; }
.wm-ap-stat span {
    display: block;
    font-size: 16px;
    font-weight: 700;
    color: #e2e8f0;
    line-height: 1.2;
}
.wm-ap-stat small {
    font-size: 9px;
    color: #475569;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}
.wm-ap-filter-bar {
    display: flex;
    gap: 4px;
    padding: 7px 8px;
    border-bottom: 1px solid #1e3a5a;
    flex-shrink: 0;
    overflow-x: auto;
    scrollbar-width: none;
}
.wm-ap-filter-bar::-webkit-scrollbar { display: none; }
.wm-ap-filter {
    padding: 3px 9px;
    border-radius: 4px;
    border: 1px solid #1e3a5a;
    background: transparent;
    color: #64748b;
    font-size: 10px;
    cursor: pointer;
    white-space: nowrap;
    transition: all 0.15s;
}
.wm-ap-filter:hover { color: #e2e8f0; border-color: #334155; }
.wm-ap-filter.active { background: rgba(168,85,247,0.15); color: #a855f7; border-color: rgba(168,85,247,0.4); }

.wm-ap-list {
    overflow-y: auto;
    flex: 1;
    padding: 6px;
}
.wm-ap-list::-webkit-scrollbar { width: 4px; }
.wm-ap-list::-webkit-scrollbar-thumb { background: #1e3a5a; border-radius: 2px; }

.wm-ap-item {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 7px 9px;
    border-radius: 7px;
    cursor: pointer;
    transition: background 0.15s;
    border: 1px solid transparent;
    margin-bottom: 3px;
}
.wm-ap-item:hover { background: rgba(30,58,90,0.5); }
.wm-ap-item.alert    { border-color: rgba(249,115,22,0.25); background: rgba(249,115,22,0.05); }
.wm-ap-item.critical { border-color: rgba(239,68,68,0.3);   background: rgba(239,68,68,0.07);  }

.wm-ap-icon {
    width: 30px;
    height: 30px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 14px;
    flex-shrink: 0;
}
.wm-ap-name { font-size: 12px; color: #e2e8f0; font-weight: 600; line-height: 1.3; }
.wm-ap-sub  { font-size: 10px; color: #475569; margin-top: 1px; }

.wm-ap-badge {
    font-size: 10px;
    font-weight: 700;
    padding: 2px 6px;
    border-radius: 4px;
    margin-right: auto;
    flex-shrink: 0;
    white-space: nowrap;
}

/* أنيميشن نبض المنشآت المهددة */
@keyframes wm-asset-pulse {
    0%,100% { box-shadow: 0 0 0 2px currentColor, 0 0 8px currentColor; }
    50%      { box-shadow: 0 0 0 6px transparent, 0 0 20px currentColor; }
}
@keyframes wm-ring-expand {
    0%   { transform: scale(1);   opacity: 0.6; }
    100% { transform: scale(1.9); opacity: 0; }
}

/* موبايل */
@media (max-width: 768px) {
    #wm-assets-panel {
        top: 44px;
        right: 0;
        left: 0;
        bottom: 60px;
        width: 100%;
        border-left: none;
        border-top: 1px solid #1e3a5a;
    }
}

/* ══════════════════════════════════════════════════
   🔍 بحث المدن — City Search
   ══════════════════════════════════════════════════ */

.wm-city-search {
    position: relative;
    display: flex;
    align-items: center;
}

#wm-city-input {
    background: rgba(15,23,42,0.9);
    border: 1px solid #1e3a5a;
    color: #e2e8f0;
    padding: 5px 12px;
    border-radius: 8px;
    font-size: 12px;
    width: 180px;
    font-family: var(--wm-font-ar);
    direction: rtl;
    transition: border-color .2s, width .3s;
    outline: none;
}
#wm-city-input:focus {
    border-color: #38bdf8;
    width: 220px;
    background: rgba(10,18,32,0.98);
}
#wm-city-input::placeholder { color: #334155; }

/* قائمة النتائج */
.wm-city-results {
    position: absolute;
    top: calc(100% + 6px);
    right: 0;
    width: 280px;
    background: rgba(8,14,26,0.98);
    border: 1px solid #1e3a5a;
    border-radius: 10px;
    overflow: hidden;
    z-index: 2000;
    box-shadow: 0 8px 32px rgba(0,0,0,0.5);
    display: none;
    direction: rtl;
    backdrop-filter: blur(12px);
}

.wm-city-item {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 9px 12px;
    cursor: pointer;
    border-bottom: 1px solid #0f1e30;
    transition: background .15s;
}
.wm-city-item:last-child { border-bottom: none; }
.wm-city-item:hover { background: rgba(56,189,248,0.08); }

.wm-city-icon { font-size: 16px; flex-shrink: 0; }
.wm-city-info { flex: 1; min-width: 0; }
.wm-city-name { font-size: 12px; font-weight: 600; color: #e2e8f0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.wm-city-type { font-size: 10px; color: #475569; margin-top: 1px; }
.wm-city-coords { font-size: 10px; color: #334155; font-family: var(--wm-font-mono); white-space: nowrap; flex-shrink: 0; }

.wm-city-empty { padding: 12px; text-align: center; color: #475569; font-size: 12px; }

/* Pin الموقع على الخريطة */
.wm-city-pin {
    position: relative;
    width: 28px; height: 28px;
    display: flex; align-items: center; justify-content: center;
}

/* ══════════════════════════════════════════════════
   🟢 مؤشر الاتصال + ⏱️ منذ متى
   ══════════════════════════════════════════════════ */

.wm-conn-label {
    font-size: 10px;
    color: #22c55e;
    font-family: var(--wm-font-ar);
    transition: color .3s;
}

/* النقطة — حالات مختلفة */
.wm-live-dot.wm-conn-ok {
    background: #22c55e;
    box-shadow: 0 0 0 0 rgba(34,197,94,0.4);
    animation: wm-conn-pulse-ok 2s ease-in-out infinite;
}
.wm-live-dot.wm-conn-err {
    background: #ef4444;
    box-shadow: 0 0 6px #ef4444;
    animation: wm-conn-blink 0.8s steps(1) infinite;
}
@keyframes wm-conn-pulse-ok {
    0%,100% { box-shadow: 0 0 0 0 rgba(34,197,94,0.4); }
    50%      { box-shadow: 0 0 0 5px rgba(34,197,94,0); }
}
@keyframes wm-conn-blink {
    0%,49% { opacity: 1; }
    50%,100%{ opacity: 0.3; }
}

/* وقت "منذ متى" في الـ Sidebar */
.wm-item-time {
    color: #475569;
    font-size: 11px;
    transition: color .3s;
}
.wm-item-time[data-timestamp] { cursor: default; }

/* ══════════════════════════════════════════════════
   👁️ Watchlist — قائمة الرصد
   ══════════════════════════════════════════════════ */

#wm-panel-watchlist {
    flex-direction: column;
    height: 100%;
    overflow: hidden;
}

.wm-watch-header {
    padding: 10px 12px 6px;
    border-bottom: 1px solid #1e3a5a;
    flex-shrink: 0;
}
.wm-watch-title   { font-size: 13px; font-weight: 700; color: #e2e8f0; margin-bottom: 3px; }
.wm-watch-subtitle{ font-size: 11px; color: #475569; }

/* حقل الإضافة */
.wm-watch-add {
    display: flex;
    gap: 6px;
    padding: 8px 10px;
    border-bottom: 1px solid #0f1e30;
    flex-shrink: 0;
}
.wm-watch-add input {
    flex: 1;
    background: rgba(15,23,42,0.9);
    border: 1px solid #1e3a5a;
    color: #e2e8f0;
    padding: 6px 10px;
    border-radius: 7px;
    font-size: 12px;
    font-family: var(--wm-font-ar);
    direction: rtl;
    outline: none;
    transition: border-color .2s;
}
.wm-watch-add input:focus { border-color: #f59e0b; }
.wm-watch-add-btn {
    background: rgba(245,158,11,0.15);
    border: 1px solid rgba(245,158,11,0.4);
    color: #f59e0b;
    padding: 6px 12px;
    border-radius: 7px;
    font-size: 12px;
    cursor: pointer;
    font-family: var(--wm-font-ar);
    transition: all .2s;
    white-space: nowrap;
}
.wm-watch-add-btn:hover { background: #f59e0b; color: #0f172a; }

/* الكلمات المرصودة */
.wm-watch-terms {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    padding: 8px 10px;
    border-bottom: 1px solid #0f1e30;
    flex-shrink: 0;
    min-height: 42px;
}
.wm-watch-empty {
    font-size: 11px;
    color: #334155;
    padding: 6px 0;
    width: 100%;
    text-align: center;
}
.wm-watch-tag {
    display: flex;
    align-items: center;
    gap: 4px;
    background: rgba(245,158,11,0.1);
    border: 1px solid rgba(245,158,11,0.3);
    border-radius: 20px;
    padding: 3px 8px 3px 6px;
    font-size: 11.5px;
    color: #fbbf24;
    transition: all .2s;
}
.wm-watch-tag:hover { background: rgba(245,158,11,0.2); }
.wm-watch-term { font-weight: 600; }
.wm-watch-tag-count {
    background: #f59e0b;
    color: #0f172a;
    border-radius: 10px;
    padding: 1px 5px;
    font-size: 10px;
    font-weight: 700;
}
.wm-watch-remove {
    background: none;
    border: none;
    color: #64748b;
    cursor: pointer;
    font-size: 11px;
    padding: 0 2px;
    line-height: 1;
    transition: color .15s;
}
.wm-watch-remove:hover { color: #ef4444; }

/* رأس نتائج الرصد */
.wm-watch-results-header {
    padding: 6px 12px;
    font-size: 11px;
    color: #64748b;
    border-bottom: 1px solid #0f1e30;
    flex-shrink: 0;
    align-items: center;
    justify-content: space-between;
}
.wm-watch-hits-badge {
    background: #f59e0b;
    color: #0f172a;
    border-radius: 10px;
    padding: 1px 7px;
    font-size: 11px;
    font-weight: 700;
}

/* قائمة النتائج */
.wm-watch-results {
    flex: 1;
    overflow-y: auto;
    padding: 6px 8px;
    display: flex;
    flex-direction: column;
    gap: 6px;
    scrollbar-width: thin;
    scrollbar-color: #1e3a5a transparent;
}
.wm-watch-no-hits {
    text-align: center;
    color: #475569;
    font-size: 12px;
    padding: 20px;
}

/* بطاقة خبر مرصود */
.wm-watch-hit {
    background: rgba(15,23,42,0.8);
    border: 1px solid #1e3a5a;
    border-right: 3px solid #f59e0b;
    border-radius: 8px;
    padding: 8px 10px;
    cursor: pointer;
    transition: background .15s;
}
.wm-watch-hit:hover { background: rgba(245,158,11,0.05); }
.wm-watch-hit-top {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 5px;
}
.wm-watch-hit-terms { display: flex; flex-wrap: wrap; gap: 4px; }
.wm-watch-hit-tag {
    font-size: 10px;
    background: rgba(245,158,11,0.1);
    color: #fbbf24;
    border-radius: 4px;
    padding: 1px 5px;
}
.wm-watch-hit-score {
    font-size: 11px;
    font-weight: 700;
    padding: 2px 6px;
    border-radius: 5px;
    flex-shrink: 0;
}
.wm-watch-hit-title {
    font-size: 12px;
    font-weight: 600;
    color: #e2e8f0;
    line-height: 1.4;
    margin-bottom: 4px;
}
.wm-watch-hit-meta {
    display: flex;
    justify-content: space-between;
    font-size: 10px;
    color: #475569;
}
.wm-watch-hit-loc { font-size: 10px; color: #334155; margin-top: 3px; }

/* إبراز الكلمة المطابقة */
mark.wm-watch-highlight {
    background: rgba(245,158,11,0.25);
    color: #fbbf24;
    border-radius: 3px;
    padding: 0 2px;
}

/* إبراز الخبر في الـ Sidebar الرئيسي */
.wm-news-item.wm-watch-match {
    border-right: 3px solid #f59e0b !important;
    background: rgba(245,158,11,0.04) !important;
}
.wm-news-item.wm-watch-match::after {
    content: '👁️';
    position: absolute;
    top: 6px;
    left: 8px;
    font-size: 10px;
    opacity: 0.7;
}

/* ══ بث الأحداث بجانب التوترات ══ */
#wm-block-live {
  transition: opacity .3s;
}
/* ارتفاع متساوٍ مع التوترات */
#wm-block-tensions,
#wm-block-live {
  min-height: 200px;
}
/* المحتوى الداخلي للبث يملأ المساحة */
#wm-live-block-body {
  display: flex;
  flex-direction: column;
  gap: 8px;
}
/* على الشاشات الصغيرة يعودان لعرض كامل */
@media (max-width: 1100px) {
  .wm-block-live,
  #wm-block-tensions { grid-column: span 2; }
}
@media (max-width: 600px) {
  .wm-block-live,
  #wm-block-tensions { grid-column: 1; }
}

/* ══════════════════════════════════════════════════════════
   Brief Panel — التقرير الاستخباراتي (panel عائم)
══════════════════════════════════════════════════════════ */
#wm-brief-panel {
  position: absolute;
  bottom: 177px; /* + 32px فوق breaking bar */
  right: 510px;   /* يسار wm-live-stream (260px + 240px + 10px gap) */
  width: 240px;
  max-height: 280px;
  background: rgba(6,12,20,0.95);
  border: 1px solid rgba(99,102,241,0.4);
  border-radius: 10px;
  z-index: 999;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  backdrop-filter: blur(8px);
  box-shadow: 0 8px 32px rgba(0,0,0,0.6), 0 0 0 1px rgba(99,102,241,0.1);
  animation: wm-slide-up 0.25s ease;
}

.wm-bp-header {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 8px 10px;
  border-bottom: 1px solid rgba(99,102,241,0.2);
  flex-shrink: 0;
}
.wm-bp-icon { font-size: 13px; }
.wm-bp-title {
  font-size: 11px;
  font-weight: 700;
  color: #a5b4fc;
  flex: 1;
}
.wm-bp-date {
  font-size: 10px;
  color: #475569;
  direction: ltr;
}
.wm-bp-close {
  background: none;
  border: none;
  color: #475569;
  cursor: pointer;
  font-size: 13px;
  padding: 0 2px;
  line-height: 1;
  transition: color .2s;
}
.wm-bp-close:hover { color: #fff; }

.wm-bp-preview {
  flex: 1;
  overflow-y: auto;
  padding: 10px;
  scrollbar-width: thin;
  scrollbar-color: #334155 transparent;
}
.wm-bp-preview::-webkit-scrollbar { width: 3px; }
.wm-bp-preview::-webkit-scrollbar-thumb { background: #334155; }

.wm-bp-loading, .wm-bp-empty {
  font-size: 11px;
  color: #475569;
  text-align: center;
  padding: 12px 0;
}

.wm-bp-summary {
  font-size: 11px;
  color: #cbd5e1;
  line-height: 1.6;
  margin-bottom: 8px;
}

.wm-bp-events { display: flex; flex-direction: column; gap: 5px; }
.wm-bp-event {
  display: flex;
  align-items: flex-start;
  gap: 6px;
  font-size: 10px;
  color: #94a3b8;
}
.wm-bp-dot {
  width: 6px; height: 6px;
  border-radius: 50%;
  flex-shrink: 0;
  margin-top: 3px;
}
.wm-bp-ev-text { line-height: 1.4; }

.wm-bp-footer {
  padding: 7px 10px;
  border-top: 1px solid rgba(99,102,241,0.15);
  flex-shrink: 0;
}
.wm-bp-read-btn {
  width: 100%;
  background: rgba(99,102,241,0.15);
  border: 1px solid rgba(99,102,241,0.3);
  color: #a5b4fc;
  font-size: 11px;
  padding: 5px 8px;
  border-radius: 6px;
  cursor: pointer;
  transition: background .2s, border-color .2s;
  font-family: inherit;
}
.wm-bp-read-btn:hover {
  background: rgba(99,102,241,0.3);
  border-color: rgba(99,102,241,0.6);
}

/* ══════════════════════════════════════════════════════════
   Brief Modal — التقرير كاملاً
══════════════════════════════════════════════════════════ */
#wm-brief-modal {
  position: fixed;
  inset: 0;
  z-index: 10000;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
}

.wm-bm-overlay {
  position: absolute;
  inset: 0;
  background: rgba(0,0,0,0.75);
  backdrop-filter: blur(4px);
}

.wm-bm-container {
  position: relative;
  width: 100%;
  max-width: 680px;
  max-height: 85vh;
  background: rgba(6,12,24,0.98);
  border: 1px solid rgba(99,102,241,0.4);
  border-radius: 14px;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  box-shadow: 0 24px 80px rgba(0,0,0,0.8), 0 0 0 1px rgba(99,102,241,0.15);
  animation: wm-slide-up .3s ease;
}

.wm-bm-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px 20px;
  border-bottom: 1px solid rgba(99,102,241,0.2);
  flex-shrink: 0;
  background: rgba(99,102,241,0.06);
}
.wm-bm-title-row {
  display: flex;
  align-items: center;
  gap: 12px;
}
.wm-bm-icon { font-size: 22px; }
.wm-bm-title {
  font-size: 15px;
  font-weight: 700;
  color: #e2e8f0;
}
.wm-bm-subtitle {
  font-size: 11px;
  color: #6366f1;
  margin-top: 2px;
  direction: ltr;
}
.wm-bm-close {
  background: rgba(255,255,255,0.06);
  border: 1px solid rgba(255,255,255,0.1);
  color: #94a3b8;
  width: 30px; height: 30px;
  border-radius: 50%;
  cursor: pointer;
  font-size: 14px;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background .2s, color .2s;
}
.wm-bm-close:hover { background: rgba(239,68,68,0.2); color: #fff; }

.wm-bm-body {
  flex: 1;
  overflow-y: auto;
  padding: 20px;
  scrollbar-width: thin;
  scrollbar-color: #334155 transparent;
}
.wm-bm-body::-webkit-scrollbar { width: 5px; }
.wm-bm-body::-webkit-scrollbar-thumb { background: #334155; border-radius: 3px; }

.wm-bm-section {
  margin-bottom: 20px;
  padding-bottom: 18px;
  border-bottom: 1px solid rgba(255,255,255,0.05);
}
.wm-bm-section:last-child { border-bottom: none; margin-bottom: 0; }

.wm-bm-section-label {
  font-size: 11px;
  font-weight: 700;
  color: #6366f1;
  text-transform: uppercase;
  letter-spacing: .8px;
  margin-bottom: 10px;
}
.wm-bm-section-text {
  font-size: 13px;
  color: #cbd5e1;
  line-height: 1.8;
}

.wm-bm-event {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  margin-bottom: 12px;
}
.wm-bm-dot {
  width: 8px; height: 8px;
  border-radius: 50%;
  flex-shrink: 0;
  margin-top: 5px;
  box-shadow: 0 0 8px currentColor;
}
.wm-bm-ev-title {
  font-size: 13px;
  font-weight: 600;
  color: #e2e8f0;
  margin-bottom: 4px;
}
.wm-bm-ev-analysis {
  font-size: 12px;
  color: #64748b;
  line-height: 1.6;
}

/* Responsive */
/* ══════════════════════════════════════════════════════════
   AIS Layer — الملاحة البحرية
══════════════════════════════════════════════════════════ */
#wm-ais-legend {
  position: absolute;
  bottom: 177px; /* + 32px فوق breaking bar */
  left: 62px;
  background: rgba(6,12,24,0.95);
  border: 1px solid rgba(56,189,248,0.35);
  border-radius: 10px;
  padding: 10px 13px 10px;
  z-index: 999;
  min-width: 175px;
  backdrop-filter: blur(12px);
  box-shadow: 0 4px 24px rgba(0,0,0,0.5);
  animation: wm-slide-up 0.25s ease;
}

.wm-ais-leg-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 11px;
  font-weight: 700;
  color: #38bdf8;
  margin-bottom: 8px;
  text-transform: uppercase;
  letter-spacing: .6px;
}
.wm-ais-leg-close {
  cursor: pointer;
  color: #475569;
  font-size: 12px;
  background: none;
  border: none;
  padding: 0;
  transition: color .2s;
}
.wm-ais-leg-close:hover { color: #fff; }

.wm-ais-leg-total {
  font-size: 12px;
  color: #e2e8f0;
  font-weight: 600;
  margin-bottom: 8px;
  padding-bottom: 7px;
  border-bottom: 1px solid rgba(255,255,255,0.06);
}

.wm-ais-leg-zones { display: flex; flex-direction: column; gap: 5px; margin-bottom: 8px; }
.wm-ais-leg-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 11px;
}
.wm-ais-leg-zone { color: #94a3b8; }
.wm-ais-leg-count {
  color: #38bdf8;
  font-weight: 700;
  background: rgba(56,189,248,0.1);
  padding: 1px 6px;
  border-radius: 10px;
  font-size: 10px;
}

.wm-ais-leg-updated {
  font-size: 9px;
  color: #334155;
  direction: ltr;
  text-align: center;
  margin-top: 4px;
}

/* Popup السفينة */
.wm-ais-popup {
  direction: rtl;
  min-width: 180px;
}
.wm-ais-popup-name {
  font-size: 13px;
  font-weight: 700;
  color: #e2e8f0;
  margin-bottom: 8px;
  padding-bottom: 6px;
  border-bottom: 1px solid rgba(255,255,255,0.08);
  direction: ltr;
  text-align: center;
}
.wm-ais-popup-row {
  display: flex;
  justify-content: space-between;
  font-size: 11px;
  margin-bottom: 4px;
  color: #94a3b8;
}
.wm-ais-popup-row span:last-child { color: #e2e8f0; font-weight: 500; }
.wm-ais-popup-time {
  font-size: 10px;
  color: #475569;
  text-align: center;
  margin-top: 7px;
  padding-top: 5px;
  border-top: 1px solid rgba(255,255,255,0.05);
}

/* Responsive */
/* ══ AIS Legend — فلتر المضايق + أنواع ══ */
.wm-ais-leg-filters {
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
  margin-bottom: 8px;
  padding-bottom: 8px;
  border-bottom: 1px solid rgba(255,255,255,0.06);
}
.wm-ais-leg-filter {
  background: rgba(56,189,248,0.08);
  border: 1px solid rgba(56,189,248,0.2);
  color: #64748b;
  font-size: 9px;
  padding: 2px 6px;
  border-radius: 10px;
  cursor: pointer;
  transition: all .2s;
  font-family: inherit;
  white-space: nowrap;
}
.wm-ais-leg-filter:hover { background: rgba(56,189,248,0.15); color: #94a3b8; }
.wm-ais-leg-filter.active {
  background: rgba(56,189,248,0.25);
  border-color: rgba(56,189,248,0.6);
  color: #38bdf8;
  font-weight: 700;
}
.wm-ais-flt-cnt {
  background: rgba(56,189,248,0.2);
  padding: 0 4px;
  border-radius: 6px;
  font-size: 8px;
}

.wm-ais-leg-types {
  display: flex;
  flex-direction: column;
  gap: 4px;
  margin-bottom: 8px;
  padding-bottom: 6px;
  border-bottom: 1px solid rgba(255,255,255,0.05);
}
.wm-ais-leg-type-row {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 10px;
}
.wm-ais-type-dot {
  width: 8px; height: 8px;
  border-radius: 50%;
  flex-shrink: 0;
  box-shadow: 0 0 4px currentColor;
}
.wm-ais-type-name { color: #94a3b8; flex: 1; }
.wm-ais-type-cnt  { color: #cbd5e1; font-weight: 600; font-size: 10px; }

/* ══ TradingView Widgets ══════════════════════════════════════════ */
#wm-ticker-tape {
    width: 100%;
    height: 46px;
    overflow: hidden;
    flex-shrink: 0;
}
#wm-ticker-tape .tradingview-widget-container,
#wm-ticker-tape .tradingview-widget-container__widget {
    height: 46px !important;
}

.wm-tv-panel {
    width: 100%;
    overflow: hidden;
    flex: 1;
    min-height: 0;
}
.wm-tv-panel[style*="display: none"],
.wm-tv-panel[style*="display:none"] {
    flex: 0 !important;
    height: 0 !important;
    overflow: hidden !important;
}
.wm-tv-panel iframe {
    width: 100% !important;
    height: 100% !important;
    border: none !important;
    display: block;
}
.wm-tv-panel .tradingview-widget-container,
.wm-tv-panel .tradingview-widget-container__widget {
    width: 100% !important;
    height: 100% !important;
}

#wm-economy-overlay .wm-eco-body {
    display: flex;
    flex-direction: column;
    flex: 1;
    min-height: 0;
    overflow: hidden;
}
#wm-economy-overlay .wm-eco-tabs {
    display: flex;
    gap: 0;
    overflow-x: auto;
    scrollbar-width: none;
    flex-shrink: 0;
    padding: 0 8px !important;
}
#wm-economy-overlay .wm-eco-tabs::-webkit-scrollbar { display: none; }
#wm-economy-overlay .wm-etab {
    padding: 8px 12px;
    font-size: 12px;
    border: none;
    background: transparent;
    color: #64748b;
    cursor: pointer;
    border-bottom: 2px solid transparent;
    white-space: nowrap;
    font-family: inherit;
    transition: all .15s;
}
#wm-economy-overlay .wm-etab:hover  { color: #e2e8f0; }
#wm-economy-overlay .wm-etab.active { color: #38bdf8; border-bottom-color: #38bdf8; background: rgba(56,189,248,.06); }

/* Economy overlay sizing */
#wm-economy-overlay {
    display: none;
    flex-direction: column;
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 520px;
    z-index: 1100;
    background: #0f172a;
    border-top: 1px solid #1e293b;
}
@media (min-width: 768px) {
    #wm-economy-overlay {
        left: auto;
        width: 680px;
        height: 540px;
        border-radius: 8px 8px 0 0;
        border: 1px solid #1e293b;
        border-bottom: none;
    }
}

/* =============================================
   Location Intelligence Popup
   ============================================= */

/* السايد بانل الاستخباراتي — يمين كامل الارتفاع */
#wm-loc-popup {
    display: none;
    position: fixed;
    z-index: 99999;
    top: 0;
    right: 0;
    width: 370px;
    height: 100vh;
    background: #060c16;
    border-left: 2px solid #1e3a5a;
    border-radius: 0;
    box-shadow: -6px 0 30px rgba(0,0,0,0.7);
    overflow: hidden;
    font-family: var(--wm-font-ar);
    direction: rtl;
    pointer-events: all;
    animation: wm-panel-in 0.3s ease;
}
#wm-loc-popup.active {
    display: flex;
    flex-direction: column;
}
@keyframes wm-panel-in {
    from { opacity: 0; transform: translateX(100%); }
    to   { opacity: 1; transform: translateX(0); }
}

#wm-loc-overlay {
    display: none;
    position: fixed;
    inset: 0;
    z-index: 99998;
    background: rgba(0,0,0,0.35);
    pointer-events: all;
}
#wm-loc-overlay.active {
    display: block;
}

/* رأس السايد بانل */
#wm-loc-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 14px 16px 12px;
    background: linear-gradient(135deg,#0c1a2e,#060c16);
    border-bottom: 2px solid #1e3a5a;
    flex-shrink: 0;
    direction: rtl;
    position: relative;
}
#wm-loc-title {
    font-size: 15px;
    font-weight: 700;
    color: #e2e8f0;
    direction: rtl;
    display: flex;
    align-items: center;
    gap: 8px;
    flex: 1;
    min-width: 0;
}
#wm-loc-title::before {
    content: none;
}
/* علم وأيقونة الدولة */
.wm-loc-flag {
    font-size: 22px;
    flex-shrink: 0;
}
.wm-loc-country-label {
    display: flex;
    flex-direction: column;
    gap: 1px;
    min-width: 0;
}
.wm-loc-country-name {
    font-size: 15px;
    font-weight: 700;
    color: #e2e8f0;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}
.wm-loc-country-sub {
    font-size: 10px;
    color: #5a7a96;
    font-weight: 400;
}
#wm-loc-close {
    background: transparent;
    border: none;
    color: #5a7a96;
    cursor: pointer;
    font-size: 16px;
    line-height: 1;
    padding: 0 2px;
    transition: color 0.15s;
    flex-shrink: 0;
}
#wm-loc-close:hover { color: #c8dff0; }

/* جسم الـ Popup — قابل للتمرير */
#wm-loc-body {
    overflow-y: auto;
    flex: 1;
    padding: 0;
    direction: rtl;
    scrollbar-width: thin;
    scrollbar-color: #1e3a5a transparent;
}
#wm-loc-body::-webkit-scrollbar { width: 4px; }
#wm-loc-body::-webkit-scrollbar-track { background: transparent; }
#wm-loc-body::-webkit-scrollbar-thumb { background: #1e3a5a; border-radius: 2px; }

/* حالة التحميل */
#wm-loc-loading {
    padding: 24px;
    text-align: center;
    color: #5a7a96;
    font-size: 12px;
}
.wm-loc-spinner {
    width: 22px;
    height: 22px;
    border: 2px solid #1e3a5a;
    border-top-color: #00d4ff;
    border-radius: 50%;
    animation: wm-spin 0.7s linear infinite;
    margin: 0 auto 8px;
}
@keyframes wm-spin { to { transform: rotate(360deg); } }

/* رسالة "لا توجد معلومات" */
#wm-loc-empty {
    padding: 20px;
    text-align: center;
    color: #5a7a96;
    font-size: 12px;
}
#wm-loc-empty .wm-loc-empty-icon {
    font-size: 24px;
    margin-bottom: 6px;
    opacity: 0.5;
}

/* معرض الصور */
#wm-loc-gallery {
    position: relative;
    background: #060c14;
    height: 140px;
    overflow: hidden;
    flex-shrink: 0;
}
#wm-loc-gallery img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    transition: opacity 0.25s;
}
#wm-loc-gallery .wm-loc-no-img {
    display: flex;
    align-items: center;
    justify-content: center;
    height: 100%;
    color: #1e3a5a;
    font-size: 36px;
}
/* أسهم التنقل في الصور */
.wm-loc-gal-btn {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background: rgba(0,0,0,0.55);
    border: none;
    color: #c8dff0;
    cursor: pointer;
    font-size: 16px;
    padding: 4px 8px;
    z-index: 2;
    border-radius: 3px;
    transition: background 0.15s;
    line-height: 1;
}
.wm-loc-gal-btn:hover { background: rgba(0,212,255,0.25); }
.wm-loc-gal-btn.prev { right: 6px; }
.wm-loc-gal-btn.next { left: 6px; }
.wm-loc-gal-counter {
    position: absolute;
    bottom: 5px;
    left: 50%;
    transform: translateX(-50%);
    background: rgba(0,0,0,0.6);
    color: #c8dff0;
    font-size: 10px;
    padding: 1px 6px;
    border-radius: 8px;
    pointer-events: none;
}

/* أقسام المحتوى */
.wm-loc-section {
    padding: 12px 16px;
    border-bottom: 1px solid #111e2e;
}
.wm-loc-section:last-child { border-bottom: none; }
.wm-loc-section-label {
    font-size: 10px;
    font-weight: 700;
    color: #3b82f6;
    text-transform: uppercase;
    letter-spacing: 0.8px;
    margin-bottom: 8px;
    display: flex;
    align-items: center;
    gap: 5px;
    direction: rtl;
}

/* ─── مؤشر عدم الاستقرار الكبير ─── */
.wm-loc-instability {
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 14px 16px;
    background: linear-gradient(135deg, rgba(30,58,90,0.15), rgba(6,12,22,0.9));
    border-bottom: 1px solid #1e3a5a;
}
.wm-loc-instability-score {
    font-size: 32px;
    font-weight: 800;
    line-height: 1;
    min-width: 70px;
    text-align: center;
}
.wm-loc-instability-meta {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 4px;
}
.wm-loc-instability-label {
    font-size: 10px;
    color: #5a7a96;
    font-weight: 600;
    letter-spacing: 0.5px;
}
.wm-loc-instability-trend {
    font-size: 11px;
    font-weight: 700;
    display: flex;
    align-items: center;
    gap: 4px;
}
.wm-loc-instability-bar {
    height: 5px;
    background: rgba(30,58,90,0.3);
    border-radius: 3px;
    overflow: hidden;
    margin-top: 2px;
}
.wm-loc-instability-bar-fill {
    height: 100%;
    border-radius: 3px;
    transition: width 0.5s ease;
}

/* ─── أقسام البيانات الفرعية ─── */
.wm-loc-data-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 6px;
    margin-top: 6px;
}
.wm-loc-data-card {
    background: rgba(15,30,48,0.6);
    border: 1px solid rgba(30,58,90,0.3);
    border-radius: 6px;
    padding: 8px 10px;
    display: flex;
    flex-direction: column;
    gap: 2px;
}
.wm-loc-data-card-icon {
    font-size: 14px;
}
.wm-loc-data-card-label {
    font-size: 9px;
    color: #5a7a96;
}
.wm-loc-data-card-val {
    font-size: 12px;
    font-weight: 700;
    color: #e2e8f0;
}

/* ─── الجدول الزمني ─── */
.wm-loc-timeline {
    padding: 0;
}
.wm-loc-timeline-row {
    display: flex;
    align-items: flex-start;
    gap: 8px;
    padding: 6px 0;
    border-bottom: 1px solid rgba(30,58,90,0.15);
    direction: rtl;
}
.wm-loc-timeline-row:last-child { border-bottom: none; }
.wm-loc-timeline-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    flex-shrink: 0;
    margin-top: 3px;
}
.wm-loc-timeline-content {
    flex: 1;
    min-width: 0;
}
.wm-loc-timeline-title {
    font-size: 11px;
    color: #c8dff0;
    line-height: 1.4;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}
.wm-loc-timeline-time {
    font-size: 9px;
    color: #475569;
    margin-top: 2px;
}

/* ─── قسم الإشارات النشطة ─── */
.wm-loc-signals {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    margin-top: 6px;
}
.wm-loc-signal-badge {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    font-size: 10px;
    padding: 3px 8px;
    border-radius: 12px;
    font-weight: 600;
    border: 1px solid;
}
.wm-loc-signal-badge.green  { color: #22c55e; border-color: #166534; background: rgba(34,197,94,0.08); }
.wm-loc-signal-badge.yellow { color: #eab308; border-color: #854d0e; background: rgba(234,179,8,0.08); }
.wm-loc-signal-badge.red    { color: #ef4444; border-color: #991b1b; background: rgba(239,68,68,0.08); }
.wm-loc-signal-badge.blue   { color: #3b82f6; border-color: #1e40af; background: rgba(59,130,246,0.08); }

/* ─── ملخص AI النصي ─── */
.wm-loc-ai-brief {
    background: rgba(15,30,48,0.5);
    border: 1px solid rgba(30,58,90,0.3);
    border-radius: 6px;
    padding: 10px 12px;
    margin-top: 6px;
}
.wm-loc-summary-text {
    font-size: 11.5px;
    line-height: 1.6;
    color: #a0b8cc;
}

/* أخبار مرتبطة */
.wm-loc-news-item {
    display: flex;
    align-items: flex-start;
    gap: 6px;
    padding: 5px 0;
    border-bottom: 1px solid #0d1a2a;
    cursor: pointer;
    transition: background 0.12s;
    border-radius: 3px;
}
.wm-loc-news-item:last-child { border-bottom: none; }
.wm-loc-news-item:hover { background: rgba(0,212,255,0.04); }
.wm-loc-news-dot {
    width: 6px;
    height: 6px;
    border-radius: 50%;
    flex-shrink: 0;
    margin-top: 4px;
}
.wm-loc-news-info { flex: 1; min-width: 0; }
.wm-loc-news-title {
    font-size: 11px;
    color: #c8dff0;
    line-height: 1.4;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}
.wm-loc-news-meta {
    font-size: 10px;
    color: #5a7a96;
    margin-top: 2px;
}

/* رابط Wikipedia */
.wm-loc-wiki-link {
    display: flex;
    align-items: center;
    gap: 5px;
    font-size: 11px;
    color: #5a7a96;
    text-decoration: none;
    padding: 8px 12px;
    border-top: 1px solid #111e2e;
    transition: color 0.15s;
    flex-shrink: 0;
}
.wm-loc-wiki-link:hover { color: #00d4ff; }
.wm-loc-wiki-link svg { opacity: 0.5; flex-shrink: 0; }

/* مؤشر الكاش */
.wm-loc-cache-badge {
    font-size: 9px;
    color: #2a5a3a;
    background: #0a1f14;
    border: 1px solid #1a4a2a;
    border-radius: 3px;
    padding: 1px 4px;
    margin-right: auto;
}

/* ── Power Profile Donut Chart ────────────────────────── */
.wm-loc-power-profile {
    display: flex;
    gap: 14px;
    align-items: center;
    padding: 4px 0 6px;
}
.wm-loc-donut-wrap {
    width: 82px;
    height: 82px;
    flex-shrink: 0;
}
.wm-loc-donut {
    width: 100%;
    height: 100%;
    overflow: visible;
}
.wm-loc-power-legend {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 6px;
}
.wm-loc-power-row {
    display: flex;
    align-items: center;
    gap: 5px;
    font-size: 11px;
}
.wm-loc-power-dot {
    width: 7px;
    height: 7px;
    border-radius: 50%;
    flex-shrink: 0;
}
.wm-loc-power-name {
    width: 46px;
    color: #8faabb;
    font-size: 10px;
    flex-shrink: 0;
}
.wm-loc-power-bar-wrap {
    flex: 1;
    height: 4px;
    background: #1e3a5a;
    border-radius: 2px;
    overflow: hidden;
}
.wm-loc-power-bar-fill {
    height: 100%;
    border-radius: 2px;
    transition: width 0.5s ease;
}
.wm-loc-power-pct {
    font-size: 10px;
    font-weight: 700;
    width: 30px;
    text-align: left;
    flex-shrink: 0;
}

/* ── Strategic Assets ─────────────────────────────────── */
.wm-loc-assets-grid {
    display: flex;
    flex-wrap: wrap;
    gap: 5px;
    padding: 2px 0;
}
.wm-loc-asset-card {
    display: flex;
    align-items: center;
    gap: 4px;
    background: #0a1827;
    border: 1px solid #1e3a5a;
    border-radius: 4px;
    padding: 4px 8px;
    cursor: default;
    transition: border-color 0.15s;
}
.wm-loc-asset-card:hover { border-color: #2a5a7a; }
.wm-loc-asset-icon { font-size: 11px; }
.wm-loc-asset-label {
    font-size: 10px;
    color: #c8dff0;
    line-height: 1.2;
}
.wm-loc-asset-count {
    background: #1e3a5a;
    color: #00d4ff;
    border-radius: 8px;
    padding: 0 5px;
    font-size: 9px;
    font-weight: 700;
    flex-shrink: 0;
}

/* ── Weekly Movement ──────────────────────────────────── */
.wm-loc-weekly {
    display: flex;
    flex-direction: column;
    gap: 0;
}
.wm-loc-weekly-row {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 11px;
    padding: 6px 0;
    border-bottom: 1px solid #0d1f33;
}
.wm-loc-weekly-row:last-child { border-bottom: none; }
.wm-loc-weekly-label {
    flex: 1;
    color: #8faabb;
}
.wm-loc-weekly-val {
    font-weight: 700;
    color: #e2e8f0;
    min-width: 22px;
    text-align: center;
    font-size: 12px;
}
.wm-loc-weekly-change {
    font-size: 11px;
    font-weight: 700;
    min-width: 48px;
    text-align: left;
}
.wm-loc-weekly-change .up   { color: #ef4444; }
.wm-loc-weekly-change .down { color: #22c55e; }
.wm-loc-weekly-change .flat { color: #eab308; }

/* تكيف للشاشات الصغيرة */
@media (max-width: 600px) {
    #wm-loc-popup {
        width: 100%;
        max-width: 100%;
    }
}
@media (min-width: 601px) and (max-width: 900px) {
    #wm-loc-popup {
        width: 320px;
    }
}

/* =============================================
   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 #ef4444;
    border-radius: 4px;
    padding: 4px 8px;
    font-size: 11px;
    font-weight: 700;
    color: #ef4444;
    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 #eab308;
    border-radius: 4px;
    padding: 2px 6px;
    font-size: 10px;
    color: #eab308;
    display: inline-block;
    margin-bottom: 6px;
}

/* عداد الطائرات في HUD */
.wm-threat.aircraftcount span { color: #00d4ff; }

/* =============================================
   Aircraft Overlay — نافذة تتبع الطائرات
   ============================================= */

#wm-aircraft-overlay {
    display: none;
    position: absolute;
    inset: 0;
    z-index: 800;
    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;
    flex-wrap: wrap;
}
#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: #22c55e;
    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-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;
}
.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-region-sel {
    padding: 3px 7px;
    background: #0d1a2a;
    border: 1px solid #1e3a5a;
    border-radius: 4px;
    color: #c8dff0;
    font-size: 11px;
    cursor: pointer;
}
#wm-ac-search-inp {
    padding: 3px 8px;
    background: #0d1a2a;
    border: 1px solid #1e3a5a;
    border-radius: 4px;
    color: #c8dff0;
    font-size: 11px;
    width: 120px;
    outline: none;
    direction: ltr;
}
#wm-ac-search-inp::placeholder { color: #3a5a76; }
#wm-ac-search-inp:focus { border-color: #00d4ff44; }
.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: #ef4444; 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-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-ac-table-head-row {
    display: flex;
    direction: ltr;
    background: #0a1520;
    border-bottom: 1px solid #1e3a5a;
    flex-shrink: 0;
    width: 100%;
    box-sizing: border-box;
}
#wm-ac-table-head-row span {
    padding: 7px 6px;
    font-size: 10px;
    font-weight: 600;
    color: #3a5a76;
    letter-spacing: 0.5px;
    white-space: nowrap;
    overflow: hidden;
}
#wm-ac-table-head-row .hcall { flex: 1; min-width: 0; }
#wm-ac-table-head-row .htype { width: 44px; flex-shrink: 0; }
#wm-ac-table-head-row .halt  { width: 50px; flex-shrink: 0; }
#wm-ac-table-head-row .hspd  { width: 44px; 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;
    border-bottom: 1px solid #0d1a2a;
    cursor: pointer;
    transition: background 0.1s;
    align-items: center;
    width: 100%;
    box-sizing: border-box;
}
.wm-ac-row:hover     { background: rgba(0,212,255,0.05); }
.wm-ac-row.selected  { background: rgba(0,212,255,0.1); }
.wm-ac-row.emergency { background: rgba(239,68,68,0.08); }

.wm-ac-row .rcall {
    flex: 1;
    min-width: 0;
    padding: 5px 6px;
    font-size: 12px;
    font-weight: 600;
    color: #c8dff0;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}
.wm-ac-row .rtype {
    width: 44px;
    flex-shrink: 0;
    padding: 5px 4px;
    font-size: 10px;
    color: #3a5a76;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}
.wm-ac-row .ralt {
    width: 50px;
    flex-shrink: 0;
    padding: 5px 4px;
    font-size: 11px;
    white-space: nowrap;
}
.wm-ac-row .rspd {
    width: 44px;
    flex-shrink: 0;
    padding: 5px 6px 5px 4px;
    font-size: 11px;
    color: #5a7a96;
    white-space: nowrap;
}
#wm-ac-empty {
    padding: 20px;
    text-align: center;
    color: #3a5a76;
    font-size: 12px;
}
.wm-ac-mil-badge {
    font-size: 8px;
    color: #eab308;
    background: rgba(234,179,8,0.12);
    border: 1px solid #eab30830;
    border-radius: 2px;
    padding: 0 3px;
}
.wm-ac-emg-badge {
    font-size: 8px;
    color: #ef4444;
    background: rgba(239,68,68,0.12);
    border-radius: 2px;
    padding: 0 3px;
    animation: wm-aircraft-blink 0.8s infinite;
}

/* ── شريط الألوان السفلي ── */
#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%,
        #22c55e 15%,
        #3b82f6 35%,
        #f97316 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;
}
#wm-ac-empty {
    display: none;
    padding: 24px;
    text-align: center;
    color: #3a5a76;
    font-size: 12px;
}

/* =============================================
   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:#ef4444; 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: #ef4444;
    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;
  }

  /* ── المحتوى يبدأ تحت 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; }
}

/* ══════════════════════════════════════════════════
   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: #ef4444; }

/* خط زمني */
.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: 44px; height: 44px; font-size: 18px; }
  .wm-tb-btn   { width: 38px; height: 38px; font-size: 16px; }
  .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: #ef4444; 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: #ef4444;
  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: #ef4444; 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:#ef4444;font-size:10px;font-weight:700}
.wm-ioda-status-warning{color:#eab308;font-size:10px;font-weight:700}
.wm-ioda-status-normal{color:#22c55e;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 #ef4444}
.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;
}

/* ══════════════════════════════════════════════════════════════
   WIRE FEED — بث الأحداث الحي
   ══════════════════════════════════════════════════════════════ */

/* Panel wrapper */
.wm-wire-panel {
    flex-direction: column !important;
    padding: 0 !important;
    overflow: hidden;
    background: #060d18;
    position: absolute !important;
    top: 0 !important;
    right: 0 !important;
    bottom: 0 !important;
    left: 0 !important;
    width: auto !important;
    height: auto !important;
    z-index: 2;
}

/* ── شريط التحكم ─────────────────────────────────────────── */
.wm-wire-controls {
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 8px 10px;
    background: #0a1628;
    border-bottom: 1px solid #0f2540;
    flex-shrink: 0;
    direction: rtl;
}

.wm-wire-status {
    display: flex;
    align-items: center;
    gap: 5px;
    flex: 1;
}

/* نبضة الاتصال الحي */
.wm-wire-pulse {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: #22c55e;
    flex-shrink: 0;
    animation: wm-wire-blink 1.8s ease-in-out infinite;
}
.wm-wire-pulse.paused { background: #64748b; animation: none; }
.wm-wire-pulse.error  { background: #ef4444; animation: none; }

@keyframes wm-wire-blink {
    0%, 100% { opacity: 1; box-shadow: 0 0 0 0 rgba(34,197,94,0.6); }
    50%       { opacity: .7; box-shadow: 0 0 0 5px rgba(34,197,94,0); }
}

.wm-wire-status-text {
    font-size: 10px;
    color: #64748b;
    font-family: 'Courier New', monospace;
    letter-spacing: .3px;
}

/* أزرار فلترة المستوى */
.wm-wire-filters {
    display: flex;
    gap: 3px;
}
.wm-wire-filter-btn {
    background: transparent;
    border: 1px solid #1e3a5f;
    color: #64748b;
    font-size: 10px;
    padding: 3px 7px;
    border-radius: 4px;
    cursor: pointer;
    transition: all .15s;
    font-family: inherit;
    white-space: nowrap;
}
.wm-wire-filter-btn:hover { border-color: #3b82f6; color: #93c5fd; }
.wm-wire-filter-btn.active {
    background: #1e3a5f;
    border-color: #3b82f6;
    color: #e2e8f0;
}

/* زر الإيقاف */
.wm-wire-pause-btn {
    background: transparent;
    border: 1px solid #1e3a5f;
    color: #64748b;
    font-size: 12px;
    width: 26px;
    height: 26px;
    border-radius: 5px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all .15s;
    flex-shrink: 0;
}
.wm-wire-pause-btn:hover { border-color: #f97316; color: #fb923c; }

/* ── شريط الملخص ─────────────────────────────────────────── */
.wm-wire-summary {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 5px 10px;
    background: #08111f;
    border-bottom: 1px solid #0f2540;
    flex-shrink: 0;
    direction: rtl;
    font-size: 10px;
}
.wm-ws-sep { color: #1e3a5f; }
.wm-ws-item { font-family: 'Courier New', monospace; font-weight: 700; }
.wm-ws-critical { color: #ef4444; }
.wm-ws-elevated { color: #f97316; }
.wm-ws-total    { color: #64748b; }

/* ── منطقة التدفق ─────────────────────────────────────────── */
.wm-wire-feed {
    flex: 1;
    overflow-y: auto;
    direction: rtl;
    scroll-behavior: smooth;
}
.wm-wire-feed::-webkit-scrollbar { width: 4px; }
.wm-wire-feed::-webkit-scrollbar-track { background: transparent; }
.wm-wire-feed::-webkit-scrollbar-thumb { background: #1e3a5f; border-radius: 2px; }

/* حالة التحميل */
.wm-wire-loading {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 10px;
    padding: 40px;
    color: #334155;
    font-size: 12px;
}
.wm-wire-spinner {
    width: 20px;
    height: 20px;
    border: 2px solid #1e3a5f;
    border-top-color: #3b82f6;
    border-radius: 50%;
    animation: wm-spin .8s linear infinite;
}
@keyframes wm-spin { to { transform: rotate(360deg); } }

/* لا يوجد أحداث */
.wm-wire-empty {
    text-align: center;
    padding: 40px 20px;
    color: #334155;
    font-size: 12px;
}

/* ── بطاقة الحدث الواحد ─────────────────────────────────── */
.wm-wire-item {
    display: flex;
    gap: 0;
    border-bottom: 1px solid #0a1628;
    cursor: pointer;
    transition: background .12s;
    position: relative;
    animation: wm-wire-slide-in .3s ease-out;
    direction: rtl;
}
.wm-wire-item:hover { background: rgba(30,58,90,0.25); }
.wm-wire-item.wm-wire-new { animation: wm-wire-flash .8s ease-out; }

@keyframes wm-wire-slide-in {
    from { opacity: 0; transform: translateY(-6px); }
    to   { opacity: 1; transform: translateY(0); }
}
@keyframes wm-wire-flash {
    0%   { background: rgba(59,130,246,0.18); }
    100% { background: transparent; }
}

/* الخط الجانبي الملوّن (مؤشر المستوى) */
.wm-wire-bar {
    width: 3px;
    flex-shrink: 0;
    border-radius: 0;
}

/* المحتوى */
.wm-wire-body {
    flex: 1;
    padding: 9px 10px 8px 6px;
    min-width: 0;
}

/* السطر الأول: الموقع + المستوى + الوقت */
.wm-wire-meta {
    display: flex;
    align-items: center;
    gap: 5px;
    margin-bottom: 4px;
    flex-wrap: wrap;
}
.wm-wire-location {
    font-size: 9px;
    font-weight: 700;
    color: #94a3b8;
    text-transform: uppercase;
    letter-spacing: .5px;
    font-family: 'Courier New', monospace;
    flex: 1;
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}
.wm-wire-badge {
    font-size: 8px;
    font-weight: 800;
    padding: 1px 5px;
    border-radius: 3px;
    text-transform: uppercase;
    letter-spacing: .5px;
    font-family: 'Courier New', monospace;
    flex-shrink: 0;
}
.wm-wire-badge.CRITICAL  { background: rgba(239,68,68,.18);  color: #ef4444; border: 1px solid rgba(239,68,68,.3); }
.wm-wire-badge.ELEVATED  { background: rgba(249,115,22,.15); color: #f97316; border: 1px solid rgba(249,115,22,.28); }
.wm-wire-badge.MODERATE  { background: rgba(234,179,8,.12);  color: #eab308; border: 1px solid rgba(234,179,8,.25); }
.wm-wire-badge.LOW       { background: rgba(59,130,246,.12); color: #3b82f6; border: 1px solid rgba(59,130,246,.25); }
.wm-wire-badge.MINIMAL   { background: rgba(100,116,139,.1); color: #64748b; border: 1px solid rgba(100,116,139,.2); }

.wm-wire-time {
    font-size: 9px;
    color: #334155;
    font-family: 'Courier New', monospace;
    flex-shrink: 0;
}

/* عنوان الحدث */
.wm-wire-title {
    font-size: 11.5px;
    color: #cbd5e1;
    line-height: 1.45;
    font-weight: 500;
    margin-bottom: 3px;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

/* ملخص */
.wm-wire-summary-text {
    font-size: 10px;
    color: #475569;
    line-height: 1.4;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    margin-bottom: 3px;
}

/* تذييل البطاقة: المصدر + التصنيف */
.wm-wire-footer {
    display: flex;
    align-items: center;
    gap: 5px;
    margin-top: 2px;
}
.wm-wire-source {
    font-size: 9px;
    color: #334155;
    font-family: 'Courier New', monospace;
    flex: 1;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}
.wm-wire-cat {
    font-size: 8px;
    color: #1e3a5f;
    font-family: 'Courier New', monospace;
    text-transform: uppercase;
    letter-spacing: .4px;
}
.wm-wire-geo-icon {
    font-size: 9px;
    color: #22c55e;
    flex-shrink: 0;
}

/* زر "تحميل المزيد" */
.wm-wire-load-more {
    text-align: center;
    padding: 12px;
    border-top: 1px solid #0a1628;
}
.wm-wire-load-more button {
    background: transparent;
    border: 1px solid #1e3a5f;
    color: #3b82f6;
    font-size: 11px;
    padding: 6px 18px;
    border-radius: 5px;
    cursor: pointer;
    font-family: inherit;
    transition: all .15s;
}
.wm-wire-load-more button:hover { background: #1e3a5f; color: #e2e8f0; }

/* إشعار أحداث جديدة (يظهر أعلى التدفق) */
.wm-wire-new-toast {
    position: sticky;
    top: 0;
    z-index: 10;
    background: #1e3a5f;
    color: #93c5fd;
    font-size: 11px;
    text-align: center;
    padding: 6px;
    cursor: pointer;
    transition: opacity .2s;
    border-bottom: 1px solid #3b82f6;
    display: none;
    direction: rtl;
}
.wm-wire-new-toast.visible { display: block; }

/* ══════════════════════════════════════════════════════════════
   🍕 PENTAGON PIZZA INDEX
   ══════════════════════════════════════════════════════════════ */
#wm-block-pizza {
    min-height: 180px;
}
#wm-block-pizza .wm-block-header {
    background: linear-gradient(90deg, rgba(239,68,68,0.05), transparent);
    border-bottom: 1px solid rgba(239,68,68,0.15);
}
#wm-pizza-score {
    font-variant-numeric: tabular-nums;
    text-shadow: 0 0 12px rgba(239,68,68,0.3);
}

/* ══════════════════════════════════════════════════
   🍕 Pizza Index Overlay
══════════════════════════════════════════════════ */
#wm-pizza-overlay {
  position: fixed;
  top: 0; right: 0;
  width: 360px;
  height: 100%;
  z-index: 700;
  background: rgba(4,8,16,0.97);
  backdrop-filter: blur(16px);
  display: flex;
  flex-direction: column;
  border-left: 1px solid rgba(239,68,68,0.2);
  animation: wm-so-in .2s ease-out;
  direction: rtl;
}
@media (max-width: 480px) {
  #wm-pizza-overlay { width: 100%; }
}

/* ══ Market Signals Overlay ════════════════════════════════════ */
#wm-mkt-overlay {
  position: fixed;
  top: 0; right: 0;
  width: 380px;
  height: 100%;
  z-index: 700;
  background: rgba(4,8,16,0.97);
  backdrop-filter: blur(16px);
  display: flex;
  flex-direction: column;
  border-left: 1px solid rgba(16,185,129,0.2);
  animation: wm-so-in .2s ease-out;
  direction: rtl;
  overflow: hidden;
}
@media (max-width: 480px) {
  #wm-mkt-overlay { width: 100%; }
}

/* ══════════════════════════════════════════════════════════════
   📡 SOURCE PICKER — فلتر المصادر
══════════════════════════════════════════════════════════════ */
#wm-src-picker {
    display: none;
    flex-direction: column;
    position: absolute;
    inset: 0;
    background: rgba(4,10,20,0.98);
    z-index: 20;
    direction: rtl;
    backdrop-filter: blur(8px);
    animation: wm-src-in .18s ease-out;
}
@keyframes wm-src-in {
    from { opacity:0; transform: translateY(6px); }
    to   { opacity:1; transform: translateY(0); }
}
#wm-src-picker-list::-webkit-scrollbar { width: 4px; }
#wm-src-picker-list::-webkit-scrollbar-thumb { background: #1e3a5a; border-radius: 2px; }

#wm-src-picker-btn.active {
    background: rgba(59,130,246,0.2) !important;
    color: #3b82f6 !important;
}

/* ══ Country Filter ══ */
.wm-cf-quick {
    font-size: 10px;
    padding: 4px 10px;
    border-radius: 14px;
    border: 1px solid #1e3a5a;
    background: rgba(255,255,255,0.04);
    color: #94a3b8;
    cursor: pointer;
    transition: all .15s;
    white-space: nowrap;
}
.wm-cf-quick.active,
.wm-cf-quick:hover {
    background: rgba(249,115,22,0.18);
    border-color: #f97316;
    color: #fb923c;
}
.wm-cf-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 5px 8px;
    border-radius: 6px;
    cursor: pointer;
    transition: background .1s;
    font-size: 11px;
    color: #94a3b8;
    border: 1px solid transparent;
}
.wm-cf-row:hover  { background: rgba(255,255,255,0.05); }
.wm-cf-row.active { background: rgba(249,115,22,0.12); border-color: rgba(249,115,22,0.3); color: #fb923c; }
.wm-cf-row-name   { display: flex; align-items: center; gap: 6px; }
.wm-cf-row-count  { font-size: 10px; color: #475569; }

/* ══ Auto Refresh Menu ══ */
.wm-ar-opt {
    display: block; width: 100%;
    background: none; border: none;
    color: #94a3b8; text-align: right;
    padding: 5px 8px; border-radius: 5px;
    cursor: pointer; font-size: 11px;
    white-space: nowrap; transition: background .15s;
}
.wm-ar-opt:hover, .wm-ar-opt.active {
    background: rgba(37,99,235,.2); color: #93c5fd;
}

/* ══════════════════════════════════════════════════
   🌾 الأمن الغذائي — Food Security Panel v1.0
   ══════════════════════════════════════════════════ */

/* تاب الأمن الغذائي — لون مميز أخضر زيتوني */
#wm-economy-overlay .wm-etab[data-etab="food"] { color: #86efac; }
#wm-economy-overlay .wm-etab[data-etab="food"]:hover { color: #bbf7d0; }
#wm-economy-overlay .wm-etab[data-etab="food"].active {
    color: #4ade80;
    border-bottom-color: #4ade80;
    background: rgba(74,222,128,.06);
}

/* شبكة السلع الغذائية */
.wm-food-commodities-grid {
    margin-bottom: 10px;
}

/* قائمة أخبار الجوع */
.wm-food-news-list {
    max-height: 220px;
    overflow-y: auto;
    scrollbar-width: thin;
    scrollbar-color: rgba(255,255,255,.1) transparent;
}
.wm-food-news-list::-webkit-scrollbar { width: 4px; }
.wm-food-news-list::-webkit-scrollbar-thumb { background: rgba(255,255,255,.15); border-radius: 2px; }


/* ═══════════════════════════════════════════════════════════════
   🕵️ مختبر التحقق المرئي — Verification Lab
   ═══════════════════════════════════════════════════════════════ */

/* اللوحة الرئيسية */
#wm-verif-panel {
  display: none;
  position: fixed;
  right: 60px;
  top: 60px;
  width: 400px;
  background: rgba(6,12,22,0.98);
  border: 1px solid var(--wm-border);
  border-radius: 10px;
  z-index: 99998;
  flex-direction: column;
  max-height: calc(100vh - 80px);
  overflow: hidden;
  backdrop-filter: blur(20px);
  box-shadow: 0 8px 40px rgba(0,0,0,0.8);
  direction: rtl;
}

/* رأس اللوحة */
.wm-vl-header {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 10px 14px;
  border-bottom: 1px solid var(--wm-border);
  flex-shrink: 0;
}
.wm-vl-header-title {
  font-size: 12px;
  font-weight: 700;
  color: var(--wm-text);
  flex: 1;
}
.wm-vl-close {
  background: none;
  border: none;
  color: var(--wm-text-dim);
  cursor: pointer;
  font-size: 14px;
  padding: 2px 6px;
  border-radius: 4px;
  transition: color .2s;
}
.wm-vl-close:hover { color: var(--wm-red); }

/* جسم اللوحة — قابل للتمرير */
.wm-vl-body {
  flex: 1;
  overflow-y: auto;
  padding: 12px;
  display: flex;
  flex-direction: column;
  gap: 10px;
  scrollbar-width: thin;
  scrollbar-color: var(--wm-border) transparent;
}
.wm-vl-body::-webkit-scrollbar { width: 4px; }
.wm-vl-body::-webkit-scrollbar-thumb { background: var(--wm-border); border-radius: 2px; }

/* منطقة السحب والإفلات */
#wm-vl-dropzone {
  border: 2px dashed var(--wm-border);
  border-radius: 8px;
  padding: 18px 12px;
  text-align: center;
  cursor: pointer;
  transition: all .2s;
  color: var(--wm-text-dim);
  font-size: 12px;
  user-select: none;
}
#wm-vl-dropzone:hover,
#wm-vl-dropzone.wm-vl-drag-over {
  border-color: var(--wm-accent);
  background: rgba(0,212,255,0.05);
  color: var(--wm-accent);
}
.wm-vl-drop-icon { font-size: 28px; margin-bottom: 6px; display: block; }
.wm-vl-drop-hint { font-size: 10px; color: var(--wm-text-dim); margin-top: 4px; }

/* input file مخفي */
#wm-vl-file-input { display: none; }

/* فاصل "أو" */
.wm-vl-or {
  text-align: center;
  font-size: 10px;
  color: var(--wm-text-dim);
  position: relative;
}
.wm-vl-or::before,
.wm-vl-or::after {
  content: '';
  display: inline-block;
  width: 38%;
  height: 1px;
  background: var(--wm-border);
  vertical-align: middle;
  margin: 0 6px;
}

/* حقل الرابط */
.wm-vl-url-row {
  display: flex;
  gap: 6px;
}
#wm-vl-url-input {
  flex: 1;
  background: rgba(13,26,42,0.8);
  border: 1px solid var(--wm-border);
  color: var(--wm-text);
  border-radius: 6px;
  padding: 6px 10px;
  font-size: 11px;
  direction: ltr;
  outline: none;
  transition: border-color .2s;
}
#wm-vl-url-input:focus { border-color: var(--wm-accent); }
#wm-vl-url-input::placeholder { color: var(--wm-text-dim); }

/* أزرار عامة */
.wm-vl-btn {
  background: rgba(0,112,180,0.2);
  border: 1px solid var(--wm-border);
  color: var(--wm-text);
  border-radius: 6px;
  padding: 6px 10px;
  font-size: 11px;
  cursor: pointer;
  white-space: nowrap;
  transition: all .2s;
  font-family: var(--wm-font-ar);
}
.wm-vl-btn:hover {
  background: rgba(0,212,255,0.15);
  border-color: var(--wm-accent);
  color: var(--wm-accent);
}
.wm-vl-btn-danger {
  background: rgba(239,68,68,0.1);
  border-color: rgba(239,68,68,0.3);
  color: var(--wm-red);
}
.wm-vl-btn-danger:hover {
  background: rgba(239,68,68,0.2);
  border-color: var(--wm-red);
}
.wm-vl-btn-primary {
  background: rgba(0,212,255,0.15);
  border-color: var(--wm-accent);
  color: var(--wm-accent);
  font-weight: 700;
}
.wm-vl-btn-primary:hover { background: rgba(0,212,255,0.25); }

/* معاينة الصورة */
#wm-vl-preview { display: none; }
.wm-vl-img-wrap {
  background: #000;
  border-radius: 6px;
  overflow: hidden;
  text-align: center;
  border: 1px solid var(--wm-border);
}
#wm-vl-img {
  max-width: 100%;
  max-height: 180px;
  object-fit: contain;
  display: block;
  margin: 0 auto;
}
#wm-vl-img-name {
  font-size: 9px;
  color: var(--wm-text-dim);
  padding: 4px 8px;
  direction: ltr;
  text-align: center;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

/* صف الأزرار */
#wm-vl-actions {
  display: none;
  gap: 6px;
  flex-wrap: wrap;
}

/* روابط محركات البحث */
.wm-vl-engine-links {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: 4px;
}
.wm-vl-engine-btn {
  display: inline-block;
  background: rgba(0,212,255,0.08);
  border: 1px solid rgba(0,212,255,0.3);
  color: var(--wm-accent);
  border-radius: 5px;
  padding: 6px 14px;
  font-size: 12px;
  font-weight: 600;
  text-decoration: none;
  cursor: pointer;
  transition: all .2s;
  letter-spacing: .3px;
}
.wm-vl-engine-btn:hover {
  background: rgba(0,212,255,0.2);
  border-color: var(--wm-accent);
  color: #fff;
  box-shadow: 0 0 8px rgba(0,212,255,0.25);
}

/* صندوق الإرشاد */
.wm-vl-guide-box {
  background: rgba(13,26,42,0.7);
  border: 1px solid var(--wm-border);
  border-radius: 6px;
  padding: 10px 12px;
  font-size: 11px;
  color: var(--wm-text-dim);
  line-height: 1.8;
}
.wm-vl-guide-box a { color: var(--wm-accent); text-decoration: none; }
.wm-vl-guide-box a:hover { text-decoration: underline; }

#wm-vl-search-guide { display: none; }

/* قسم EXIF */
#wm-vl-exif-section { display: none; }
.wm-vl-section-title {
  font-size: 11px;
  font-weight: 700;
  color: var(--wm-text-dim);
  text-transform: uppercase;
  letter-spacing: .5px;
  margin-bottom: 6px;
  padding-bottom: 4px;
  border-bottom: 1px solid var(--wm-border);
}
#wm-vl-exif-placeholder {
  font-size: 11px;
  color: var(--wm-text-dim);
  text-align: center;
  padding: 10px;
  display: none;
}

/* تنبيه GPS */
.wm-vl-gps-alert {
  background: rgba(239,68,68,0.1);
  border: 1px solid rgba(239,68,68,0.4);
  border-right: 3px solid var(--wm-red);
  border-radius: 6px;
  padding: 8px 10px;
  font-size: 11px;
  color: #fca5a5;
  margin-bottom: 6px;
  line-height: 1.6;
}
.wm-vl-gps-link { color: var(--wm-accent) !important; text-decoration: none; }
.wm-vl-gps-link:hover { text-decoration: underline; }

/* تنبيه تاريخ */
.wm-vl-date-alert {
  background: rgba(234,179,8,0.08);
  border: 1px solid rgba(234,179,8,0.3);
  border-right: 3px solid var(--wm-yellow);
  border-radius: 6px;
  padding: 7px 10px;
  font-size: 11px;
  color: #fde68a;
  margin-bottom: 6px;
}

/* جدول EXIF */
.wm-vl-exif-tbl {
  width: 100%;
  border-collapse: collapse;
  font-size: 10px;
}
.wm-vl-exif-key {
  color: var(--wm-text-dim);
  padding: 3px 6px 3px 10px;
  white-space: nowrap;
  vertical-align: top;
  width: 40%;
  border-bottom: 1px solid rgba(30,58,90,0.4);
}
.wm-vl-exif-val {
  color: var(--wm-text);
  padding: 3px 0 3px 6px;
  direction: ltr;
  word-break: break-all;
  border-bottom: 1px solid rgba(30,58,90,0.4);
}
.wm-vl-exif-tbl tr:last-child .wm-vl-exif-key,
.wm-vl-exif-tbl tr:last-child .wm-vl-exif-val { border-bottom: none; }

/* تذييل المختبر */
.wm-vl-footer {
  padding: 6px 12px;
  border-top: 1px solid var(--wm-border);
  font-size: 9px;
  color: var(--wm-text-dim);
  text-align: center;
  flex-shrink: 0;
}

/* ══════════════════════════════════════════════════════════
   ⚡ Earthquake Overlay v2 — إضافات صفحة الزلازل
   ══════════════════════════════════════════════════════════ */

/* شريط الإحصائيات السريعة */
.wm-eq-stats-strip {
  display: flex;
  gap: 1px;
  background: #0a0f1a;
  border-bottom: 1px solid #1e293b;
  flex-shrink: 0;
}
.wm-eq-sstat {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 6px 4px;
  background: #0d1520;
  gap: 2px;
}
.wm-eq-sstat.wm-eq-sstat-sep {
  border-right: 1px solid #1e293b;
}
.wm-eq-sval {
  font-size: 16px;
  font-weight: 700;
  font-family: var(--wm-font-mono, monospace);
  color: #e2e8f0;
}
.wm-eq-sstat small {
  font-size: 9px;
  color: #475569;
}
.wm-eq-c-red    { color: #ef4444 !important; }
.wm-eq-c-orange { color: #f97316 !important; }
.wm-eq-c-yellow { color: #eab308 !important; }
.wm-eq-c-blue   { color: #60a5fa !important; }
.wm-eq-c-purple { color: #a78bfa !important; }

/* مفتاح الألوان على الخريطة */
.wm-eq-map-legend {
  position: absolute;
  bottom: 8px;
  right: 8px;
  background: rgba(13,17,23,.88);
  border: 1px solid #1e293b;
  border-radius: 7px;
  padding: 6px 10px;
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  z-index: 1000;
  font-size: 10px;
  color: #8b949e;
  direction: rtl;
}
.wm-eq-map-legend span {
  display: flex;
  align-items: center;
  gap: 4px;
}
.wm-eq-ldot {
  display: inline-block;
  width: 8px;
  height: 8px;
  border-radius: 50%;
}

/* بطاقة تفاصيل الزلزال */
.wm-eq-detail-bar {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 8px 14px;
  background: #0d1520;
  border-top: 1px solid #1e293b;
  flex-shrink: 0;
  direction: rtl;
}
.wm-eq-detail-mag {
  font-size: 18px;
  font-weight: 700;
  background: #1f2937;
  border-radius: 7px;
  padding: 6px 10px;
  min-width: 60px;
  text-align: center;
  color: #f0f6fc;
  flex-shrink: 0;
}
.wm-eq-detail-body { flex: 1; min-width: 0; }
.wm-eq-detail-title {
  font-size: 12px;
  font-weight: 500;
  color: #c9d1d9;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.wm-eq-detail-meta { font-size: 10px; color: #6e7681; margin-top: 2px; }
.wm-eq-detail-close {
  background: none;
  border: none;
  color: #6e7681;
  cursor: pointer;
  font-size: 14px;
  padding: 4px;
  flex-shrink: 0;
}

/* شريط تحذير التسونامي */
.wm-eq-tsunami-bar {
  background: #1a0505;
  border-top: 1px solid #7f1d1d;
  padding: 7px 14px;
  font-size: 12px;
  color: #fca5a5;
  direction: rtl;
  flex-shrink: 0;
}

/* شريط المنشآت القريبة */
.wm-eq-assets-bar {
  background: #111827;
  border-top: 1px solid #374151;
  padding: 7px 14px;
  display: flex;
  align-items: center;
  gap: 8px;
  flex-shrink: 0;
  flex-wrap: wrap;
  direction: rtl;
}
.wm-eq-assets-lbl { font-size: 11px; color: #f59e0b; font-weight: 600; flex-shrink: 0; }
.wm-eq-assets-chips { display: flex; gap: 5px; flex-wrap: wrap; }
.wm-eq-asset-chip {
  font-size: 10px;
  padding: 2px 8px;
  border-radius: 4px;
  border: 1px solid #374151;
  color: #c9d1d9;
  background: #1f2937;
  white-space: nowrap;
}

/* تحسين صف الجدول — إضافة badges */
.wm-do-row-tsunami { border-right: 2px solid #0369a1; }
.wm-do-row-assets  { border-right: 2px solid #92400e; }
.wm-do-row-mena    { background: rgba(31,111,235,0.04); }
.wm-do-badge {
  font-size: 9px;
  padding: 1px 5px;
  border-radius: 3px;
  margin-right: 3px;
}
.wm-do-badge-tsunami { background: #0c1a2e; color: #7dd3fc; border: 1px solid #0369a1; }
.wm-do-badge-asset   { background: #1c1107; color: #fcd34d; border: 1px solid #92400e; }
.wm-do-badge-mena    { background: #0f1f0f; color: #86efac; border: 1px solid #166534; }

/* ══════════════════════════════════════════════════════════
   🌪 Disaster Radar Overlay v2 — تحسينات رادار الكوارث
   ══════════════════════════════════════════════════════════ */

/* مؤشر MENA المُركّب */
.wm-radar-mena-bar {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 8px 16px;
  background: #060c18;
  border-bottom: 1px solid #1e293b;
  flex-shrink: 0;
  direction: rtl;
}
.wm-radar-mena-lbl { font-size: 11px; color: #6e7681; min-width: 120px; }
.wm-radar-mena-track {
  flex: 1;
  height: 6px;
  background: #1e293b;
  border-radius: 3px;
  overflow: hidden;
}
.wm-radar-mena-fill {
  height: 100%;
  border-radius: 3px;
  transition: width 1s ease, background .5s ease;
}
.wm-radar-mena-val   { font-size: 11px; color: #6e7681; min-width: 44px; text-align: right; }
.wm-radar-mena-level { font-size: 11px; font-weight: 700; min-width: 80px; }

/* أزرار تبديل نوع الكارثة */
.wm-radar-layer-btns {
  display: flex;
  gap: 5px;
  padding: 8px 12px;
  background: #0a0f1a;
  border-bottom: 1px solid #1e293b;
  flex-wrap: wrap;
  flex-shrink: 0;
  direction: rtl;
}
.wm-radar-lbtn {
  background: #1e293b;
  border: 1px solid #334155;
  color: #94a3b8;
  padding: 4px 10px;
  border-radius: 5px;
  cursor: pointer;
  font-size: 11px;
  transition: all .18s;
  font-family: inherit;
}
.wm-radar-lbtn.active {
  background: #1f4080;
  border-color: #1f6feb;
  color: #fff;
}
.wm-radar-lbtn:hover:not(.active) { background: #334155; }

/* إحصائيات الرادار الموسّعة */
.wm-radar-summary {
  display: flex !important;
  flex-wrap: wrap;
}
#wm-rs-floods .wm-radar-stat-val,
#wm-rs-dust   .wm-radar-stat-val { color: #60a5fa; }

/* قسم السيول */
.wm-radar-floods-section,
.wm-radar-dust-section {
  padding: 10px 14px;
  border-top: 1px solid #1e293b;
  flex-shrink: 0;
}
.wm-radar-section-hdr {
  font-size: 11px;
  font-weight: 600;
  color: #60a5fa;
  margin-bottom: 8px;
  direction: rtl;
}
.wm-radar-floods-list,
.wm-radar-dust-list {
  display: flex;
  flex-direction: column;
  gap: 5px;
}
.wm-radar-flood-item,
.wm-radar-dust-item {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 7px 10px;
  background: #0d1520;
  border-radius: 6px;
  border: 1px solid #1e293b;
  direction: rtl;
  font-size: 11px;
}
.wm-radar-flood-icon { font-size: 16px; flex-shrink: 0; }
.wm-radar-flood-body { flex: 1; }
.wm-radar-flood-name  { font-weight: 500; color: #c9d1d9; }
.wm-radar-flood-level { font-size: 10px; font-weight: 600; }
.wm-radar-flood-bar-wrap {
  width: 60px;
  height: 4px;
  background: #1e293b;
  border-radius: 2px;
  overflow: hidden;
}
.wm-radar-flood-bar {
  height: 100%;
  border-radius: 2px;
  transition: width 1s ease;
}
.wm-radar-flood-val { font-size: 10px; color: #6e7681; min-width: 60px; text-align: left; }

/* بطاقة الكارثة — إضافة أنواع جديدة */
.wm-radar-card.wm-rtype-flood  { border-right-color: #3b82f6 !important; }
.wm-radar-card.wm-rtype-dust   { border-right-color: #d97706 !important; }
.wm-radar-card-hidden          { display: none !important; }

/* ══════════════════════════════════════════════════════════════
   🪟 FLOATING PANELS — بانلات عائمة من الـ dock الأيمن
   نفس أسلوب بانل البيتزا: fixed، يسار الـ dock، كامل الارتفاع
   ══════════════════════════════════════════════════════════════ */

.wm-float-panel {
  position: fixed;
  top: 0;
  right: 52px;           /* يسار الـ dock مباشرة */
  width: 380px;
  height: 100%;
  z-index: 1050;
  background: rgba(4,8,16,0.97);
  backdrop-filter: blur(16px);
  border-left: 1px solid rgba(30,58,90,0.7);
  flex-direction: column;
  direction: rtl;
  animation: wm-fp-in .2s ease-out;
  overflow: hidden;
}

@keyframes wm-fp-in {
  from { opacity: 0; transform: translateX(20px); }
  to   { opacity: 1; transform: translateX(0); }
}

/* رأس البانل */
.wm-fp-header {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 10px 12px;
  border-bottom: 1px solid rgba(30,58,90,0.7);
  flex-shrink: 0;
  background: rgba(6,12,22,0.6);
  flex-wrap: wrap;
}

.wm-fp-icon {
  font-size: 15px;
  flex-shrink: 0;
}

.wm-fp-title {
  font-size: 11px;
  font-weight: 700;
  color: #94a3b8;
  flex: 1;
  white-space: nowrap;
}

.wm-fp-reload,
.wm-fp-close {
  background: transparent;
  border: 1px solid rgba(30,58,90,0.8);
  border-radius: 4px;
  color: #5a7a96;
  font-size: 11px;
  cursor: pointer;
  padding: 2px 6px;
  flex-shrink: 0;
  transition: all .15s;
}
.wm-fp-close { border-color: rgba(239,68,68,0.3); }
.wm-fp-reload:hover { background: rgba(37,99,235,0.2); color: #93c5fd; }
.wm-fp-close:hover  { background: rgba(239,68,68,0.25); color: #fca5a5; }

/* فلاتر داخل الرأس */
.wm-fp-filters {
  display: flex;
  gap: 3px;
  flex-wrap: wrap;
  width: 100%;
  padding-top: 5px;
}
.wm-fp-filters button {
  padding: 2px 7px;
  border-radius: 10px;
  border: 1px solid rgba(30,58,90,0.8);
  background: transparent;
  color: #64748b;
  font-size: 9px;
  cursor: pointer;
  transition: all .15s;
}
.wm-fp-filters button.active {
  background: rgba(30,58,90,0.9);
  color: #94a3b8;
}

/* جسم البانل */
.wm-fp-body {
  flex: 1;
  overflow-y: auto;
  overflow-x: hidden;
  padding: 8px;
  scrollbar-width: thin;
  scrollbar-color: rgba(30,58,90,0.6) transparent;
}
.wm-fp-body::-webkit-scrollbar { width: 4px; }
.wm-fp-body::-webkit-scrollbar-thumb { background: rgba(30,58,90,0.6); border-radius: 2px; }

/* زر الـ dock عند التفعيل */
.wm-ld-btn.wm-float-dock-btn.active {
  color: var(--wm-accent);
  background: rgba(37,99,235,0.15);
}

/* مسرح المحاكاة — أوسع من البانلات الأخرى لاحتواء 3 أعمدة */
#wm-float-simulation {
  width: 620px;
}

/* موبايل: عرض كامل */
@media (max-width: 700px) {
  .wm-float-panel,
  #wm-float-simulation {
    width: 100%;
    right: 0;
  }
}

/* ══════════════════════════════════════════════
   WM Narrative Detector — تصميم محسّن
   ══════════════════════════════════════════════ */

/* Loading & Empty */
.wm-narr-loading {
    padding: 30px;
    text-align: center;
    color: #3a5a76;
    font-size: 12px;
}
.wm-narr-empty, .wm-narr-error {
    padding: 40px 20px;
    text-align: center;
    color: #475569;
    font-size: 13px;
}
.wm-narr-empty span { font-size: 32px; display: block; margin-bottom: 8px; }

/* ملخص سريع */
.wm-narr-summary {
    display: flex;
    gap: 6px;
    padding: 8px;
    border-bottom: 1px solid rgba(255,255,255,0.05);
    margin-bottom: 8px;
}
.wm-narr-sum-item {
    flex: 1;
    text-align: center;
    padding: 6px 4px;
    border-radius: 8px;
    font-size: 11px;
}
.wm-narr-sum-item span { display: block; font-size: 18px; font-weight: 700; line-height: 1.2; }
.wm-narr-sum-item small { color: rgba(255,255,255,0.5); font-size: 10px; }
.wm-narr-sum-red    { background: rgba(239,68,68,0.12);  color: #ef4444; }
.wm-narr-sum-yellow { background: rgba(245,158,11,0.12); color: #f59e0b; }
.wm-narr-sum-green  { background: rgba(34,197,94,0.12);  color: #22c55e; }

/* Card */
.wm-narr-card {
    background: rgba(255,255,255,0.03);
    border: 1px solid rgba(255,255,255,0.06);
    border-radius: 10px;
    margin: 0 8px 8px;
    overflow: hidden;
    transition: border-color .2s;
}
.wm-narr-card:hover { border-color: rgba(255,255,255,0.1); }

/* Card Header */
.wm-narr-card-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 9px 12px;
    cursor: pointer;
    user-select: none;
}
.wm-narr-card-title {
    display: flex;
    align-items: center;
    gap: 7px;
}
.wm-narr-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    flex-shrink: 0;
}
.wm-narr-topic {
    font-size: 12px;
    font-weight: 600;
    color: #e2e8f0;
}
.wm-narr-card-meta {
    display: flex;
    align-items: center;
    gap: 6px;
}
.wm-narr-badge {
    font-size: 10px;
    padding: 2px 7px;
    border-radius: 20px;
    border: 1px solid;
    font-weight: 500;
}
.wm-narr-arrow {
    font-size: 9px;
    color: #475569;
}

/* شريط التقاطع */
.wm-narr-bar-wrap {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 0 12px 8px;
}
.wm-narr-bar-track {
    flex: 1;
    height: 4px;
    background: rgba(255,255,255,0.06);
    border-radius: 2px;
    overflow: hidden;
}
.wm-narr-bar-fill {
    height: 100%;
    border-radius: 2px;
    transition: width .4s ease;
}
.wm-narr-bar-label {
    font-size: 10px;
    color: #64748b;
    white-space: nowrap;
    min-width: 70px;
    text-align: left;
}

/* Body */
.wm-narr-body {
    padding: 0 10px 10px;
    border-top: 1px solid rgba(255,255,255,0.04);
}
.wm-narr-sources-label {
    font-size: 10px;
    color: #475569;
    font-weight: 600;
    padding: 8px 2px 4px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

/* مصدر واحد */
.wm-narr-sources { display: flex; flex-direction: column; gap: 5px; }
.wm-narr-src {
    background: rgba(255,255,255,0.03);
    border-right: 3px solid;
    border-radius: 0 6px 6px 0;
    padding: 6px 8px;
}
.wm-narr-src-top {
    display: flex;
    justify-content: space-between;
    margin-bottom: 3px;
}
.wm-narr-src-group {
    font-size: 10px;
    font-weight: 700;
}
.wm-narr-src-count {
    font-size: 10px;
    color: #475569;
}
.wm-narr-src-title {
    font-size: 11px;
    color: #94a3b8;
    line-height: 1.45;
    text-decoration: none;
    display: block;
    transition: color .15s;
}
.wm-narr-src-title:hover { color: #e2e8f0; }

/* تحليل AI */
.wm-narr-ai {
    margin-top: 8px;
    padding: 8px 10px;
    background: rgba(139,92,246,0.07);
    border: 1px solid rgba(139,92,246,0.18);
    border-radius: 7px;
}
.wm-narr-ai-label {
    font-size: 10px;
    color: #a78bfa;
    font-weight: 700;
    margin-bottom: 4px;
}
.wm-narr-ai-diff {
    font-size: 11px;
    color: #94a3b8;
    line-height: 1.5;
}
.wm-narr-ai-missing {
    font-size: 10px;
    color: #64748b;
    margin-top: 5px;
    padding-top: 5px;
    border-top: 1px solid rgba(139,92,246,0.1);
}

/* ══════════════════════════════════════════════
   WM Predictive Alerts — زر عائم + panel
   ══════════════════════════════════════════════ */

/* الزر العائم */
#wm-pa-btn {
    position: absolute;
    top: 58px;
    right: 60px;
    z-index: 1100;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    border: 2px solid rgba(255,255,255,0.15);
    background: rgba(15, 23, 42, 0.88);
    color: #fff;
    font-size: 18px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 2px;
    backdrop-filter: blur(8px);
    transition: background .2s, transform .15s, box-shadow .2s;
    box-shadow: 0 2px 10px rgba(0,0,0,.4);
}
#wm-pa-btn:hover,
#wm-pa-btn.active {
    background: rgba(239, 68, 68, 0.85);
    transform: scale(1.08);
    box-shadow: 0 4px 16px rgba(239,68,68,.5);
}
#wm-pa-btn.wm-pa-has-alerts {
    animation: wm-pa-pulse 2.5s ease-in-out infinite;
}
@keyframes wm-pa-pulse {
    0%, 100% { box-shadow: 0 2px 10px rgba(239,68,68,.4); }
    50%       { box-shadow: 0 0 0 8px rgba(239,68,68,.15), 0 2px 10px rgba(239,68,68,.4); }
}

/* Badge عدد التنبيهات */
#wm-pa-badge {
    position: absolute;
    top: -5px;
    right: -5px;
    background: #ef4444;
    color: #fff;
    font-size: 10px;
    font-weight: 700;
    min-width: 18px;
    height: 18px;
    border-radius: 9px;
    padding: 0 4px;
    line-height: 18px;
    text-align: center;
    border: 2px solid #0f172a;
}

/* Panel */
#wm-pa-panel {
    position: absolute;
    top: 106px;
    right: 60px;
    z-index: 1099;
    width: 360px;
    max-height: 500px;
    background: rgba(15, 23, 42, 0.95);
    border: 1px solid rgba(255,255,255,0.1);
    border-radius: 14px;
    backdrop-filter: blur(14px);
    box-shadow: 0 8px 32px rgba(0,0,0,.55);
    display: flex;
    flex-direction: column;
    overflow: hidden;
    direction: rtl;
    font-family: inherit;
    transition: opacity .2s, transform .2s;
}
#wm-pa-panel.hidden {
    display: none;
}

/* Header */
.wm-pa-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 12px 14px;
    border-bottom: 1px solid rgba(255,255,255,0.08);
    flex-shrink: 0;
}
.wm-pa-title {
    font-size: 14px;
    font-weight: 700;
    color: #f1f5f9;
}
.wm-pa-sub {
    display: block;
    font-size: 11px;
    color: #94a3b8;
    margin-top: 2px;
}
.wm-pa-close {
    background: none;
    border: none;
    color: #94a3b8;
    font-size: 16px;
    cursor: pointer;
    padding: 2px 6px;
    border-radius: 4px;
    transition: color .2s;
}
.wm-pa-close:hover { color: #f1f5f9; }

/* List */
#wm-pa-list {
    overflow-y: auto;
    flex: 1;
    padding: 8px;
    scrollbar-width: thin;
    scrollbar-color: rgba(255,255,255,.1) transparent;
}

.wm-pa-loading,
.wm-pa-empty {
    text-align: center;
    color: #64748b;
    padding: 30px 16px;
    font-size: 13px;
}

/* Item */
.wm-pa-item {
    background: rgba(255,255,255,0.04);
    border: 1px solid rgba(255,255,255,0.07);
    border-radius: 10px;
    padding: 10px 12px;
    margin-bottom: 8px;
    cursor: pointer;
    transition: background .15s;
}
.wm-pa-item:hover {
    background: rgba(255,255,255,0.08);
}

.wm-pa-item-top {
    display: flex;
    align-items: center;
    gap: 6px;
    flex-wrap: wrap;
    margin-bottom: 6px;
}
.wm-pa-badge-conf {
    font-size: 11px;
    font-weight: 700;
    color: #fff;
    padding: 2px 8px;
    border-radius: 20px;
}
.wm-pa-accel {
    font-size: 11px;
    color: #fb923c;
    font-weight: 600;
}
.wm-pa-cat {
    font-size: 11px;
    color: #94a3b8;
    margin-right: auto;
}
.wm-pa-coords {
    font-size: 11px;
    color: #64748b;
    margin-bottom: 6px;
}

/* Reasons */
.wm-pa-reasons {
    margin: 4px 0 8px 0;
    padding-right: 16px;
    list-style: disc;
}
.wm-pa-reasons li {
    font-size: 12px;
    color: #cbd5e1;
    margin-bottom: 3px;
    line-height: 1.4;
}

/* Top news */
.wm-pa-news-label {
    font-size: 11px;
    color: #64748b;
    margin-bottom: 4px;
    font-weight: 600;
}
.wm-pa-news-item {
    font-size: 11px;
    color: #94a3b8;
    margin-bottom: 3px;
    line-height: 1.4;
}
.wm-pa-ns {
    color: #60a5fa;
    font-weight: 600;
}
.wm-pa-nt { color: #cbd5e1; }

/* Forecast footer */
.wm-pa-forecast {
    font-size: 10px;
    color: #475569;
    margin-top: 8px;
    padding-top: 6px;
    border-top: 1px solid rgba(255,255,255,0.05);
}

/* Mobile */
@media (max-width: 600px) {
    #wm-pa-btn  { right: 60px; top: 58px; }
    #wm-pa-panel {
        width: calc(100vw - 80px);
        right: 60px;
        top: 106px;
        max-height: 60vh;
    }
}


/* ══════════════════════════════════════════════════════════════
   Silence Radar — رادار الصمت
   ══════════════════════════════════════════════════════════════ */

/* Toolbar */
.wm-sr-toolbar {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 8px 12px;
    background: #0a1520;
    border-bottom: 1px solid #1e3a5a;
    flex-shrink: 0;
    direction: rtl;
}
.wm-sr-title {
    font-size: 12px;
    font-weight: 700;
    color: #94a3b8;
}
.wm-sr-subtitle {
    font-size: 10px;
    color: #475569;
    flex: 1;
}
.wm-sr-refresh-btn {
    background: none;
    border: 1px solid #1e3a5a;
    color: #3a5a76;
    border-radius: 6px;
    width: 26px;
    height: 26px;
    cursor: pointer;
    font-size: 13px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s;
}
.wm-sr-refresh-btn:hover {
    border-color: #3b82f6;
    color: #3b82f6;
}

/* List */
.wm-sr-list {
    flex: 1;
    overflow-y: auto;
    padding: 8px;
    direction: rtl;
}

/* Loading & Empty */
.wm-sr-loading {
    padding: 30px;
    text-align: center;
    color: #3a5a76;
    font-size: 12px;
}
.wm-sr-empty {
    padding: 40px 16px;
    text-align: center;
    color: #3a5a76;
    font-size: 12px;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
}
.wm-sr-empty span { font-size: 28px; }

/* Header row */
.wm-sr-header {
    display: flex;
    justify-content: space-between;
    padding: 4px 6px 6px;
    margin-bottom: 4px;
}
.wm-sr-hdr-label {
    font-size: 9px;
    color: #334155;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

/* Card */
.wm-sr-card {
    background: #080f1a;
    border: 1px solid #0d1a2a;
    border-radius: 8px;
    padding: 10px 12px;
    margin-bottom: 6px;
    transition: border-color 0.15s;
}
.wm-sr-card:hover { border-color: #1e3a5a; }

/* Card top row */
.wm-sr-top {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 6px;
}
.wm-sr-topic {
    display: flex;
    align-items: center;
    gap: 6px;
}
.wm-sr-dot {
    width: 7px;
    height: 7px;
    border-radius: 50%;
    flex-shrink: 0;
}
.wm-sr-name {
    font-size: 13px;
    font-weight: 700;
    color: #e2e8f0;
}
.wm-sr-badge {
    font-size: 11px;
    font-weight: 700;
    padding: 2px 8px;
    border-radius: 10px;
    border: 1px solid;
    white-space: nowrap;
}

/* Progress bar */
.wm-sr-bar-track {
    height: 4px;
    background: #1e293b;
    border-radius: 3px;
    overflow: hidden;
    margin-bottom: 6px;
}
.wm-sr-bar-fill {
    height: 100%;
    border-radius: 3px;
    transition: width 0.4s ease;
}

/* Meta row */
.wm-sr-meta {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 10px;
    color: #475569;
}
.wm-sr-last {
    color: #334155;
    font-style: italic;
}

/* ── Silence Radar v1.1 — تحسينات ── */

/* شريط الفلتر */
.wm-sr-filters {
    display: flex;
    gap: 4px;
    padding: 6px 8px;
    background: #060c14;
    border-bottom: 1px solid #0d1a2a;
    flex-shrink: 0;
    direction: rtl;
    flex-wrap: wrap;
}
.wm-sr-fbtn {
    background: #0a1520;
    border: 1px solid #1e3a5a;
    color: #475569;
    border-radius: 12px;
    padding: 3px 10px;
    font-size: 10px;
    cursor: pointer;
    font-family: inherit;
    transition: all 0.15s;
    white-space: nowrap;
}
.wm-sr-fbtn:hover  { border-color: #3b82f6; color: #93c5fd; }
.wm-sr-fbtn.active { border-color: #3b82f6; color: #60a5fa; background: #1e3a5a44; }

/* مقارنة 3 فترات */
.wm-sr-periods {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 4px;
    padding: 6px 4px 4px;
    margin-top: 4px;
    border-top: 1px solid #0d1a2a;
}
.wm-sr-period {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 2px;
    flex: 1;
}
.wm-sr-period-val {
    font-size: 14px;
    font-weight: 700;
    color: #94a3b8;
    line-height: 1;
}
.wm-sr-period-lbl {
    font-size: 8px;
    color: #334155;
    white-space: nowrap;
}
.wm-sr-arrow {
    font-size: 14px;
    font-weight: 700;
    flex-shrink: 0;
}

/* نوع الانخفاض */
.wm-sr-trend {
    font-size: 9px;
    padding: 1px 6px;
    border-radius: 8px;
    font-weight: 600;
    margin-right: 4px;
}
.wm-sr-trend-sudden  { background: #7f1d1d22; color: #ef4444; border: 1px solid #ef444433; }
.wm-sr-trend-gradual { background: #78350f22; color: #f97316; border: 1px solid #f9731633; }

/* آخر ذكر */
.wm-sr-last {
    font-size: 9px;
    color: #334155;
    margin-top: 4px;
    padding-top: 4px;
}

/* ══════════════════════════════════════════════════════════════
   Crisis Graph — شبكة الأزمات
   ══════════════════════════════════════════════════════════════ */

/* panel أعرض للرسم البياني */
.wm-float-panel-wide {
    width: 500px !important;
}

/* منطقة الرسم */
.wm-cg-body {
    padding: 0 !important;
    background: radial-gradient(ellipse at 50% 40%, #071422 0%, #04080f 70%);
    position: relative;
    min-height: 420px;
}

/* Loading & Empty */
.wm-cg-loading,
.wm-cg-empty {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    height: 100%;
    gap: 10px;
    color: #3a5a76;
    font-size: 12px;
}
.wm-cg-empty span { font-size: 28px; }

/* ── فلتر الفترة الزمنية ─────────────────────────────────────── */
.wm-cg-periods {
    display: flex;
    gap: 4px;
    margin-inline-start: auto;
    align-items: center;
}
.wm-cg-pbtn {
    background: rgba(255,255,255,0.06);
    border: 1px solid rgba(255,255,255,0.12);
    color: #94a3b8;
    font-size: 10px;
    font-family: Tajawal, sans-serif;
    padding: 2px 8px;
    border-radius: 4px;
    cursor: pointer;
    transition: background 0.18s, color 0.18s, border-color 0.18s;
    white-space: nowrap;
}
.wm-cg-pbtn:hover {
    background: rgba(59,130,246,0.18);
    border-color: #3b82f6;
    color: #93c5fd;
}
.wm-cg-pbtn.active {
    background: rgba(59,130,246,0.28);
    border-color: #3b82f6;
    color: #bfdbfe;
    font-weight: 700;
}

/* ── شريط معلومات العقدة ─────────────────────────────────────── */
.wm-cg-info {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    background: rgba(4,8,15,0.96);
    border-top: 1px solid rgba(255,255,255,0.1);
    padding: 10px 14px;
    z-index: 10;
    backdrop-filter: blur(8px);
    direction: rtl;
    box-shadow: 0 -4px 20px rgba(0,0,0,0.5);
}
.wm-cg-info-head {
    display: flex;
    align-items: center;
    gap: 7px;
    padding-bottom: 8px;
    margin-bottom: 8px;
    border-bottom: 1px solid rgba(255,255,255,0.07);
    border-inline-start: 3px solid;
    padding-inline-start: 8px;
}
.wm-cg-info-dot {
    width: 9px;
    height: 9px;
    border-radius: 50%;
    flex-shrink: 0;
}
.wm-cg-info-head strong {
    font-size: 13px;
    color: #e2e8f0;
    flex: 1;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}
.wm-cg-info-cat {
    font-size: 10px;
    opacity: 0.85;
    white-space: nowrap;
}
.wm-cg-info-count {
    font-size: 10px;
    color: #64748b;
    white-space: nowrap;
    margin-inline-start: auto;
}

/* ── قائمة الروابط ───────────────────────────────────────────── */
.wm-cg-info-links {
    display: flex;
    flex-direction: column;
    gap: 5px;
    max-height: 110px;
    overflow-y: auto;
    scrollbar-width: thin;
    scrollbar-color: #1e3a5f transparent;
}
.wm-cg-info-link {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 11px;
}
.wm-cg-info-lname {
    width: 90px;
    flex-shrink: 0;
    color: #94a3b8;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    text-align: right;
}
.wm-cg-info-lbar {
    flex: 1;
    height: 4px;
    background: rgba(255,255,255,0.08);
    border-radius: 2px;
    overflow: hidden;
}
.wm-cg-info-lbar > div {
    height: 100%;
    border-radius: 2px;
    opacity: 0.75;
    transition: width 0.35s ease;
}
.wm-cg-info-lw {
    width: 24px;
    text-align: left;
    color: #475569;
    font-size: 10px;
    flex-shrink: 0;
}

/* ── عداد العقد ──────────────────────────────────────────────── */
#wm-cg-count {
    font-size: 10px;
    color: #475569;
    margin-inline-start: auto;
    padding-inline-end: 4px;
}

/* ── مفتاح الألوان (legend) ──────────────────────────────────── */
.wm-cg-legend {
    position: absolute;
    bottom: 8px;
    inset-inline-start: 8px;
    display: flex;
    flex-direction: column;
    gap: 4px;
    z-index: 5;
    pointer-events: none;
}
.wm-cg-litem {
    display: flex;
    align-items: center;
    gap: 5px;
    font-size: 10px;
    color: #94a3b8;
    font-family: Tajawal, sans-serif;
    text-shadow: 0 1px 3px #000;
}
.wm-cg-litem i {
    display: inline-block;
    width: 9px;
    height: 9px;
    border-radius: 50%;
    flex-shrink: 0;
    opacity: 0.85;
    box-shadow: 0 0 5px currentColor;
}

/* ── شريط رأس البانل الواسع ──────────────────────────────────── */
#wm-float-crisis-graph .wm-fp-header {
    flex-wrap: nowrap;
    gap: 4px;
}
#wm-float-crisis-graph .wm-fp-title {
    flex-shrink: 0;
}
