/* Sovereign CSS Core - PROBAS UK LTD */
:root {
    --gold: #d4af37;
    --bg: #050505;
    --sidebar-bg: rgba(10,10,10,0.98);
    --header-bg: #000;
    --text-main: #ffffff;
    --text-muted: #888888;
    --border-color: rgba(212,175,55,0.1);
    --active-bg: rgba(212,175,55,0.08);
    --alert-red: #e74c3c;
}

[data-theme="light"] {
    --bg: #ffffff;
    --sidebar-bg: #0f172a;
    --header-bg: #ffffff;
    --text-main: #1e293b;
    --text-muted: #64748b;
    --border-color: rgba(0,0,0,0.1);
    --active-bg: rgba(15, 23, 42, 0.1);
}

* { box-sizing: border-box; transition: background 0.3s, color 0.3s; }
body { margin: 0; padding: 0; background: var(--bg); color: var(--text-main); font-family: 'Inter', 'Cairo', sans-serif; display: flex; height: 100vh; overflow: hidden; }

/* Sidebar Architecture */
.sidebar { 
    width: 290px; background: var(--sidebar-bg); border-left: 1px solid var(--border-color);
    display: flex; flex-direction: column; z-index: 2000; flex-shrink: 0;
}

[dir="ltr"] .sidebar { border-left: none; border-right: 1px solid var(--border-color); order: -1; }

.logo-area { padding: 30px 20px; text-align: center; border-bottom: 1px solid var(--border-color); }
.logo-text { color: var(--gold); font-weight: 700; letter-spacing: 3px; font-size: 1.1rem; text-transform: uppercase; }

.nav-scroll { flex-grow: 1; overflow-y: auto; padding: 15px; scrollbar-width: none; }
.nav-scroll::-webkit-scrollbar { display: none; }

.section-label { font-size: 10px; color: var(--gold); text-transform: uppercase; margin: 25px 10px 10px; letter-spacing: 2px; font-weight: 700; opacity: 0.8; }

.nav-item { 
    padding: 10px 15px; font-size: 13px; color: var(--text-muted); cursor: pointer; border-radius: 6px; 
    margin-bottom: 2px; display: flex; align-items: center; gap: 12px;
}
.nav-item:hover, .nav-item.active { background: var(--active-bg); color: var(--gold); }

/* Main Content & Header */
.main-stage { flex-grow: 1; display: flex; flex-direction: column; min-width: 0; position: relative; }

header { 
    height: 70px; background: var(--header-bg); border-bottom: 1px solid var(--border-color);
    display: flex; align-items: center; justify-content: space-between; padding: 0 25px;
    z-index: 1000;
}

.header-left-group { flex: 1; min-width: 0; margin-right: 15px; }

.current-tool-title { 
    color: var(--gold); font-weight: 600; letter-spacing: 2px; font-size: 0.85rem;
    white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}

.status-cluster { display: flex; align-items: center; gap: 18px; flex-shrink: 0; }

.icon-btn { 
    cursor: pointer; font-size: 18px; opacity: 0.7; position: relative; 
    display: flex; align-items: center; justify-content: center;
}
.icon-btn:hover { opacity: 1; transform: scale(1.1); }

.alert-badge {
    position: absolute; top: -2px; right: -2px; width: 7px; height: 7px;
    background: var(--alert-red); border-radius: 50%; box-shadow: 0 0 5px var(--alert-red);
}

.status-indicator { border-right: 1px solid var(--border-color); padding-right: 15px; margin-right: 5px; }
[dir="ltr"] .status-indicator { border-right: none; border-left: 1px solid var(--border-color); padding-left: 15px; }

.status-dot { width: 8px; height: 8px; background: #2ecc71; border-radius: 50%; box-shadow: 0 0 10px #2ecc71; }

.lang-menu {
    position: absolute; top: 65px; background: var(--sidebar-bg);
    border: 1px solid var(--gold); border-radius: 8px; display: none;
    flex-direction: column; min-width: 140px; z-index: 5000; box-shadow: 0 10px 30px rgba(0,0,0,0.5);
}
.lang-menu.active { display: flex; }
[dir="rtl"] .lang-menu { left: 80px; }
[dir="ltr"] .lang-menu { right: 80px; }

.lang-opt { padding: 12px 15px; font-size: 12px; color: #fff; cursor: pointer; text-align: center; }
.lang-opt:hover { background: var(--gold); color: #000; }

#content-viewport { flex-grow: 1; border: none; background: var(--bg); width: 100%; height: 100%; }

@media (max-width: 768px) {
    .sidebar { width: 70px; }
    .logo-text, .section-label, .nav-item span { display: none; }
    .current-tool-title { font-size: 0.7rem; }
}
