:root {
  --bg: #000000; --surface: rgba(10, 14, 20, 0.9); --surface-inset: rgba(4, 7, 12, 0.94);
  --border: rgba(255, 255, 255, 0.11); --text: #f8fafc; --muted: #94a3b8; --dim: #64748b;
  --emerald: #10b981; --cyan: #00e5ff; --violet: #a78bfa; --amber: #f59e0b; --rose: #f43f5e;
  --font-display: 'Space Grotesk', 'Cairo', system-ui, sans-serif;
  --font-body: 'Inter', 'Cairo', system-ui, sans-serif;
  --font-mono: 'JetBrains Mono', ui-monospace, monospace;
}
html[data-theme="light"] {
  --bg: #f4f7fb; --surface: rgba(255, 255, 255, 0.94); --surface-inset: rgba(241, 245, 249, 0.96);
  --border: rgba(15, 23, 42, 0.12); --text: #0f172a; --muted: #475569; --dim: #64748b;
  --emerald: #059669; --cyan: #0284c7; --violet: #7c3aed; --amber: #d97706; --rose: #e11d48;
}
html[dir="rtl"] { --font-display: 'Cairo', sans-serif; --font-body: 'Cairo', sans-serif; }
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
body { background: var(--bg); color: var(--text); font-family: var(--font-body); line-height: 1.5; min-height: 100vh; overflow-x: hidden; }
.mono { font-family: var(--font-mono); }
.emerald { color: var(--emerald); } .cyan { color: var(--cyan); } .violet { color: var(--violet); } .amber { color: var(--amber); } .rose { color: var(--rose); }
.mt-1 { margin-top: 1.2rem; }
.wrap { width: min(100% - 2rem, 1360px); margin-inline: auto; }
.glass { background: var(--surface); backdrop-filter: blur(14px); border: 1px solid var(--border); border-radius: 16px; }
.topbar { position: sticky; top: 0; z-index: 50; background: rgba(0, 0, 0, 0.88); backdrop-filter: blur(16px); border-bottom: 1px solid var(--border); padding: 0.72rem 0; }
html[data-theme="light"] .topbar { background: rgba(244, 247, 251, 0.92); }
.topbar-inner { display: flex; align-items: center; justify-content: space-between; gap: 0.9rem; flex-wrap: wrap; }
.brand-group h1 { font-family: var(--font-display); font-size: 1.1rem; margin-top: 0.14rem; }
.live-badge { display: inline-flex; align-items: center; gap: 0.45rem; font-size: 0.67rem; letter-spacing: 0.07em; color: var(--emerald); }
.pulse { width: 7px; height: 7px; border-radius: 50%; background: var(--emerald); box-shadow: 0 0 8px var(--emerald); }
.tab-bar { display: flex; gap: 0.4rem; flex-wrap: wrap; }
.tab-btn { background: var(--surface-inset); border: 1px solid var(--border); color: var(--muted); font-family: var(--font-mono); font-size: 0.73rem; padding: 0.46rem 0.82rem; border-radius: 10px; cursor: pointer; }
.tab-btn.active { color: var(--emerald); border-color: var(--emerald); background: rgba(16, 185, 129, 0.14); }
.top-actions { display: flex; gap: 0.42rem; flex-wrap: wrap; align-items: center; }
.pill-btn { background: var(--surface-inset); border: 1px solid var(--border); color: var(--text); font-size: 0.72rem; padding: 0.4rem 0.74rem; border-radius: 999px; text-decoration: none; cursor: pointer; }
.em-btn { border-color: rgba(16, 185, 129, 0.5); color: var(--emerald); }
body.embed-mode .external-only { display: none; }
.main-body { padding: 1.2rem 0 2.5rem; }
.kpi-strip { display: grid; grid-template-columns: repeat(6, 1fr); gap: 0.8rem; margin-bottom: 1.2rem; }
.kpi-card { padding: 0.88rem 1rem; display: flex; flex-direction: column; gap: 0.18rem; }
.kpi-lbl { font-size: 0.63rem; color: var(--muted); letter-spacing: 0.06em; }
.kpi-val { font-size: 1.34rem; font-weight: 700; line-height: 1.15; }
.kpi-sub { font-size: 0.7rem; color: var(--dim); }
.tab-panel { display: none; } .tab-panel.active { display: block; }
.grid-2-wide { display: grid; grid-template-columns: 1.22fr 0.78fr; gap: 1.2rem; }
.grid-2-eq { display: grid; grid-template-columns: 1fr 1fr; gap: 1.2rem; }
.card { padding: 1.15rem 1.25rem; }
.card-head { display: flex; justify-content: space-between; align-items: flex-start; gap: 0.8rem; flex-wrap: wrap; margin-bottom: 0.9rem; }
.eyebrow { display: block; font-size: 0.65rem; letter-spacing: 0.07em; margin-bottom: 0.14rem; }
.card h2 { font-family: var(--font-display); font-size: 1.06rem; }
.chart-wrap { position: relative; width: 100%; } .h-330 { height: 325px; }
.note-strip { margin-top: 0.8rem; padding-top: 0.65rem; border-top: 1px solid var(--border); font-size: 0.72rem; color: var(--muted); display: flex; flex-wrap: wrap; gap: 0.45rem; }
.search-input { background: var(--surface-inset); border: 1px solid var(--border); color: var(--text); border-radius: 9px; padding: 0.44rem 0.72rem; font-size: 0.74rem; outline: none; }
.table-wrap { overflow-x: auto; max-height: 430px; overflow-y: auto; border-radius: 10px; border: 1px solid var(--border); }
.data-table { width: 100%; border-collapse: collapse; font-size: 0.74rem; }
.data-table th, .data-table td { padding: 0.54rem 0.7rem; text-align: left; border-bottom: 1px solid var(--border); white-space: nowrap; }
.data-table th { position: sticky; top: 0; background: var(--bg); color: var(--muted); font-size: 0.68rem; }
.data-table tbody tr:hover { background: rgba(16, 185, 129, 0.07); }
.pill { display: inline-block; padding: 0.15rem 0.45rem; border-radius: 6px; font-weight: 700; font-size: 0.7rem; }
.pill-em { background: rgba(16,185,129,0.2); color: var(--emerald); }
.pill-cy { background: rgba(0,229,255,0.18); color: var(--cyan); }
.pill-am { background: rgba(245,158,11,0.2); color: var(--amber); }
.pill-rs { background: rgba(244,63,94,0.2); color: var(--rose); }
.gallery-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 1rem; }
.gal-card { background: var(--surface-inset); border: 1px solid var(--border); border-radius: 12px; overflow: hidden; }
.gal-card img { width: 100%; display: block; background: #000; }
.gal-cap { padding: 0.6rem 0.85rem; font-size: 0.73rem; color: var(--muted); }
.foot { padding: 1rem 0 1.8rem; border-top: 1px solid var(--border); display: flex; justify-content: space-between; gap: 0.75rem; flex-wrap: wrap; font-size: 0.72rem; color: var(--dim); }
.foot a { color: var(--emerald); text-decoration: none; }
@media (max-width: 1120px) { .kpi-strip { grid-template-columns: repeat(3, 1fr); } .grid-2-wide, .grid-2-eq, .gallery-grid { grid-template-columns: 1fr; } }
@media (max-width: 640px) { .kpi-strip { grid-template-columns: repeat(2, 1fr); } }
