:root {
  color-scheme: light;
  --bg: #f8fafc;
  --surface: rgba(255, 255, 255, 0.85);
  --surface-2: #f1f5f9;
  --text: #0f172a;
  --muted: #64748b;
  --line: rgba(226, 232, 240, 0.8);
  --brand: #064e3b;
  --brand-2: #047857;
  --accent: #d97706;
  --blue: #2563eb;
  --red: #dc2626;
  --violet: #7c3aed;
  --radius: 12px;
  --shadow: 0 20px 40px -8px rgba(15, 23, 42, 0.08);
  --glass-border: 1px solid rgba(255, 255, 255, 0.6);
}

* { box-sizing: border-box; }
html, body { min-height: 100%; margin: 0; }
body {
  background: var(--bg);
  color: var(--text);
  font-family: Tajawal, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  letter-spacing: 0;
}
body, input, select, textarea, button { font-family: Tajawal, system-ui, sans-serif; }
html[dir="rtl"] body { text-align: right; }
html[dir="ltr"] body { text-align: left; }
a { color: inherit; text-decoration: none; }
.app-bg {
  position: fixed;
  inset: 0;
  z-index: -1;
  background:
    linear-gradient(180deg, rgba(20,83,45,.06), transparent 360px),
    linear-gradient(90deg, rgba(15,118,110,.08), transparent 55%),
    var(--bg);
}

.auth-shell {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
  background: linear-gradient(135deg, #0f172a 0%, #0f766e 100%);
  position: relative;
  overflow: hidden;
}
.auth-shell::before {
  content: '';
  position: absolute;
  inset: 0;
  background: radial-gradient(circle at top right, rgba(255,255,255,0.1), transparent 60%);
  pointer-events: none;
}
.auth-panel { z-index: 1; width: 100%; display: flex; justify-content: center; }
.auth-card-wrapper { width: min(100%, 460px); display: flex; flex-direction: column; gap: 24px; }
.auth-card-header { text-align: center; color: #fff; }
.auth-card-header img { width: 56px; height: 56px; background: #fff; border-radius: 14px; padding: 10px; margin-bottom: 16px; box-shadow: 0 8px 24px rgba(0,0,0,0.15); }
.auth-card-header h1 { font-size: 28px; font-weight: 900; margin: 0 0 6px; }
.auth-card-header p { font-size: 15px; color: rgba(255,255,255,0.8); margin: 0; }

.auth-card { 
  background: rgba(255,255,255,0.98); 
  backdrop-filter: blur(20px);
  border: 1px solid rgba(255,255,255,0.6); 
  border-radius: 24px; 
  box-shadow: 0 20px 40px rgba(0,0,0,0.2); 
  padding: 40px; 
}
.auth-card h2 { font-weight: 900; margin: 0 0 8px; letter-spacing: -0.02em; }
.auth-subtitle { color: #64748b; font-size: 15px; margin-bottom: 24px; }
.link-muted { color: var(--muted); font-weight: 700; }

.app-shell {
  min-height: 100vh;
  width: 100%;
  max-width: 100vw;
  overflow-x: hidden;
  direction: ltr;
}
html[dir="rtl"] .app-shell { direction: rtl; }
.sidebar {
  direction: inherit;
  position: fixed;
  top: 0;
  bottom: 0;
  inset-inline-start: 0;
  height: 100vh;
  width: 280px;
  z-index: 30;
  overflow: hidden;
  background: #ffffff;
  color: #334155;
  border-inline-end: 1px solid #e2e8f0;
  padding: 20px 16px;
  display: flex;
  flex-direction: column;
  gap: 16px;
  transition: width 0.3s cubic-bezier(0.4, 0, 0.2, 1), transform 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  will-change: width, transform;
  box-shadow: 4px 0 24px rgba(0,0,0,0.02);
}
@media (min-width: 992px) {
  .app-shell.sidebar-collapsed .sidebar { width: 88px; padding-inline: 12px; }
  .app-shell.sidebar-collapsed .brand .d-flex > div,
  .app-shell.sidebar-collapsed .brand .btn-icon,
  .app-shell.sidebar-collapsed .user-card div:last-child,
  .app-shell.sidebar-collapsed .nav-text,
  .app-shell.sidebar-collapsed .toggle-icon { display: none !important; }
  .app-shell.sidebar-collapsed .nav-group summary { justify-content: center; padding: 10px; }
  .app-shell.sidebar-collapsed .nav-group summary > span > i { margin: 0 !important; }
  .app-shell.sidebar-collapsed .nav-group > div { margin: 0; padding-inline-start: 0; border-inline-start: 0; }
  .app-shell.sidebar-collapsed .nav-menu a { justify-content: center; padding: 10px; border: none; }
  .app-shell.sidebar-collapsed .nav-menu a.active { border-radius: 12px; background: #e8f5ef; color: #047857; }
  .app-shell.sidebar-collapsed .nav-menu a i { margin: 0; }
  .app-shell.sidebar-collapsed .user-card { justify-content: center; padding: 10px; border: none; background: transparent; }
  .app-shell.sidebar-collapsed .mini-action { justify-content: center; }
}
@media (max-width: 991px) {
  .app-shell.sidebar-collapsed .sidebar { transform: translateX(-105%); }
  html[dir="rtl"] .app-shell.sidebar-collapsed .sidebar { transform: translateX(105%); }
}
.brand { display: flex; align-items: center; justify-content: space-between; padding: 0 4px 12px; }
.brand > div:first-child { display: flex; align-items: center; gap: 12px; }
.brand img { width: 40px; height: 40px; border-radius: 10px; }
.brand strong { display: block; font-weight: 900; color: #0f172a; font-size: 18px; letter-spacing: -0.5px; }
.brand small, .user-card span, table small { display: block; color: #64748b; font-size: 12px; }
table small { color: var(--muted); }
.user-card { display: flex; align-items: center; gap: 12px; padding: 14px; border: 1px solid #e2e8f0; border-radius: 16px; background: #f8fafc; }
.avatar { width: 42px; height: 42px; border-radius: 12px; display: grid; place-items: center; background: linear-gradient(135deg, #10b981, #047857); color: #fff; font-weight: 900; font-size: 18px; box-shadow: 0 4px 12px rgba(16, 185, 129, 0.2); }
.nav-menu {
  flex: 1;
  min-height: 0;
  display: grid;
  align-content: start;
  gap: 10px;
  overflow-y: auto;
  overflow-x: hidden;
  padding-inline-end: 5px;
  scrollbar-width: thin;
}
.nav-group { padding: 2px 0 10px; border-bottom: 1px solid #edf2f7; }
.nav-group summary {
  min-height: 38px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding: 8px 12px;
  border: 1px solid transparent;
  border-radius: 10px;
  color: #475569;
  font-size: 12px;
  font-weight: 900;
  text-transform: none;
  cursor: pointer;
  list-style: none;
  user-select: none;
  transition: all 0.2s ease;
}
.nav-group summary::-webkit-details-marker { display: none; }
.nav-group summary span { display: inline-flex; align-items: center; gap: 10px; }
.nav-group summary i:first-child { color: var(--brand); font-size: 17px; opacity: 0.92; }
.nav-group summary > i:last-child { transition: transform .18s ease; opacity: 0.5; }
.nav-group summary:hover { background: #f8fafc; border-color: #e2e8f0; }
.nav-group[open] summary { color: #0f172a; background: #f8fafc; border-color: #e2e8f0; }
.nav-group[open] summary > i:last-child { transform: rotate(180deg); opacity: 1; }
.nav-group > div {
  display: grid;
  gap: 4px;
  margin-inline-start: 13px;
  padding-top: 7px;
  padding-inline-start: 7px;
  border-inline-start: 1px solid #edf2f7;
}
.nav-menu a, .mini-action {
  min-height: 40px;
  display: flex;
  align-items: center;
  gap: 12px;
  border: 1px solid transparent;
  border-radius: 10px;
  padding: 9px 12px;
  color: #475569;
  font-weight: 700;
  font-size: 14px;
  transition: all 0.2s ease;
}
.nav-menu a i { width: 22px; text-align: center; color: #94a3b8; font-size: 17px; transition: color 0.2s ease; }
.nav-menu a:hover { background: #f8fafc; border-color: #e2e8f0; color: #0f172a; }
html[dir="rtl"] .nav-menu a:hover { transform: none; }
.nav-menu a:hover i { color: var(--brand); }
.nav-menu a.active { background: #ecfdf5; color: #065f46; border-color: #bbf7d0; border-inline-start: 4px solid #10b981; padding-inline-start: 9px; box-shadow: 0 8px 18px -18px rgba(6, 78, 59, .9); }
html[dir="rtl"] .nav-menu a.active { background: #ecfdf5; border-inline-start: 4px solid #10b981; }
.nav-menu a.active i { color: #10b981; }
.sidebar-footer { margin-top: auto; display: grid; gap: 8px; }
.mini-action { border: 1px solid #e2e8f0; justify-content: center; background: #fff; }
.mini-action:hover { background: #f8fafc; color: #0f172a; }
.mini-action.danger { color: #ef4444; border-color: rgba(239, 68, 68, 0.2); }
.mini-action.danger:hover { background: #fef2f2; color: #dc2626; }
.btn-icon { width: 40px; height: 40px; border: 1px solid #e2e8f0; border-radius: 12px; background: #fff; color: #475569; display: inline-grid; place-items: center; transition: all 0.2s ease; }
.btn-icon:hover { background: #f1f5f9; border-color: #cbd5e1; transform: scale(1.05); color: #0f172a; }
.sidebar .btn-icon { border: none; background: transparent; color: #64748b; }
.sidebar .btn-icon:hover { background: #f1f5f9; color: #0f172a; }

.main {
  margin-inline-start: 280px;
  min-width: 0;
  max-width: 100%;
  overflow-x: hidden;
  direction: inherit;
  transition: margin 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  display: flex;
  flex-direction: column;
  min-height: 100vh;
}
@media (min-width: 992px) {
  .app-shell.sidebar-collapsed .main { margin-inline-start: 88px; }
}
@media (max-width: 991px) {
  .main { margin-inline-start: 0 !important; }
}
.topbar {
  min-height: 82px;
  padding: 16px 32px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  background: rgba(255, 255, 255, 0.6);
  backdrop-filter: blur(24px);
  -webkit-backdrop-filter: blur(24px);
  border-bottom: 1px solid rgba(226, 232, 240, 0.4);
  position: sticky;
  top: 0;
  z-index: 10;
  box-shadow: 0 4px 20px -10px rgba(0,0,0,0.05);
}
.topbar h1 { margin: 0; font-size: 24px; font-weight: 900; color: #0f172a; letter-spacing: -0.5px; }
.topbar p { margin: 3px 0 0; color: #64748b; font-size: 14px; font-weight: 500; }
.top-actions { display: flex; align-items: center; gap: 10px; }
.content { padding: 32px; min-width: 0; max-width: 100%; overflow-x: clip; background: #f1f5f9; min-height: calc(100vh - 82px); }
.btn { border-radius: 12px; font-weight: 800; display: inline-flex; align-items: center; gap: 8px; transition: all 0.2s ease; }
.btn-primary { background: var(--brand); border-color: var(--brand); box-shadow: 0 4px 12px rgba(20, 83, 45, 0.2); }
.btn-primary:hover { background: #0f3f23; border-color: #0f3f23; transform: translateY(-1px); box-shadow: 0 6px 16px rgba(20, 83, 45, 0.3); }
.btn-light-subtle { border: 1px solid var(--line); background: #fff; color: #334155; }
.btn-light-subtle:hover { background: #f8fafc; border-color: #cbd5e1; transform: translateY(-1px); }

.hero-band, .module-intro {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  background: var(--brand);
  color: #fff;
  border-radius: var(--radius);
  padding: 26px;
  margin-bottom: 24px;
  box-shadow: var(--shadow);
}
.hero-band h2, .module-intro h2 { margin: 0 0 8px; font-weight: 900; }
.hero-band p, .module-intro p { margin: 0; color: rgba(255,255,255,.82); max-width: 900px; }
.module-intro .eyebrow, .hero-band .eyebrow { color: #fef08a; }

.kpi-grid { display: grid; grid-template-columns: repeat(6, minmax(0, 1fr)); gap: 14px; margin-bottom: 24px; }
.kpi-grid.executive { grid-template-columns: repeat(5, minmax(0, 1fr)); }
.kpi-grid.compact { grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); }
.metric-card {
  background: #fff;
  border: 1px solid rgba(226, 232, 240, 0.8);
  border-radius: 20px;
  padding: 24px;
  min-height: 140px;
  box-shadow: 0 4px 12px rgba(0,0,0,0.02);
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  position: relative;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}
.metric-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 20px 40px -12px rgba(15,23,42,0.12);
  border-color: rgba(52, 211, 153, 0.3);
}
.metric-card i { font-size: 28px; color: var(--brand); margin-bottom: 12px; display: inline-block; }
.metric-card span { display: block; margin-bottom: 8px; color: #64748b; font-weight: 700; font-size: 13px; text-transform: uppercase; letter-spacing: 0px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.metric-card strong { display: block; font-size: 24px; font-weight: 900; line-height: 1.1; overflow-wrap: anywhere; color: #0f172a; }
.metric-card small { display: block; margin-top: 10px; color: #94a3b8; font-weight: 600; line-height: 1.3; font-size: 12px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.metric-card.blue i { color: var(--blue); } .metric-card.teal i { color: var(--brand-2); } .metric-card.amber i { color: #d97706; } .metric-card.red i { color: var(--red); } .metric-card.violet i { color: var(--violet); }

.grid-2 { display: grid; grid-template-columns: repeat(auto-fit, minmax(400px, 1fr)); gap: 24px; }
.grid-3 { display: grid; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); gap: 24px; }
.grid-2 > .panel:has(.table-responsive), .grid-3 > .panel:has(.table-responsive) { grid-column: 1 / -1; }
.panel, .info-card {
  background: #fff;
  border: 1px solid rgba(226, 232, 240, 0.6);
  border-radius: 20px;
  box-shadow: 0 10px 40px -10px rgba(0,0,0,0.06);
  padding: 28px;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}
.panel:hover, .info-card:hover {
  box-shadow: 0 20px 40px -12px rgba(15,23,42,0.1);
}
.panel + .panel, .module-intro + .panel { margin-top: 24px; }
.panel-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 16px; }
.panel-head h3, .info-card h3, .workflow-column h3, .task-lane h3 { margin: 0; font-size: 17px; font-weight: 900; }
.panel-head p { margin: 3px 0 0; color: var(--muted); }
.chart-box { height: 310px; }
.executive-hero { background: linear-gradient(135deg, #123c2a, #0f766e 58%, #1f2937); }
.hero-band-meta {
  min-width: 220px;
  padding: 18px;
  border: 1px solid rgba(255,255,255,.24);
  border-radius: var(--radius);
  background: rgba(255,255,255,.12);
}
.hero-band-meta span, .hero-band-meta small { display: block; color: rgba(255,255,255,.78); font-weight: 800; }
.hero-band-meta b { display: block; margin: 6px 0; font-size: 28px; font-weight: 900; }
.stack-item.urgent { border-color: #fed7aa; background: #fff7ed; }
.stack-item.urgent.danger { border-color: #fecaca; background: #fef2f2; }
.stack-item.urgent em { color: #9a3412; font-style: normal; font-weight: 900; white-space: nowrap; }
.stack-item.urgent.danger em { color: #991b1b; }

.form-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 20px; }
.form-grid.single { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.form-grid label { display: flex; flex-direction: column; }
.form-grid label span { display: block; font-weight: 800; font-size: 13px; color: #475569; margin-bottom: 8px; text-transform: uppercase; letter-spacing: 0.5px; }
.span-2 { grid-column: 1 / -1; }
.form-control, .form-select {
  border: 1px solid #e2e8f0;
  border-radius: 12px;
  min-height: 48px;
  background: #f8fafc;
  color: #0f172a;
  font-size: 15px;
  font-weight: 500;
  padding: 10px 16px;
  transition: all 0.2s ease;
  box-shadow: inset 0 1px 2px rgba(0,0,0,0.01);
}
.form-control:focus, .form-select:focus {
  background: #fff;
  border-color: #34d399;
  box-shadow: 0 0 0 4px rgba(52, 211, 153, 0.15);
  outline: none;
}
textarea.form-control { min-height: 90px; }
.form-actions { display: flex; gap: 12px; justify-content: flex-end; margin-top: 24px; padding-top: 16px; border-top: 1px solid #f1f5f9; }
.search-form { display: flex; gap: 8px; width: min(100%, 520px); }
.table-filter { width: min(100%, 360px); margin-bottom: 14px; }
.form-page-panel {
  width: min(100%, 980px);
  margin-inline: auto;
}
.form-page-panel .panel-head {
  padding-bottom: 18px;
  margin-bottom: 22px;
  border-bottom: 1px solid #eef2f7;
}
.form-page-panel .form-grid {
  row-gap: 18px;
}

.table-responsive {
  width: 100%;
  max-width: 100%;
  background: #fff;
  border-radius: 12px;
  border: 1px solid rgba(203, 213, 225, 0.9);
  overflow-x: auto;
  box-shadow: 0 8px 20px -18px rgba(15, 23, 42, .35);
}
.panel > .table-responsive {
  margin-inline: -4px;
  width: calc(100% + 8px);
}
.table {
  margin: 0;
  width: 100%;
  min-width: 760px;
  border-collapse: separate;
  border-spacing: 0;
  font-variant-numeric: tabular-nums;
}
.table th {
  color: #475569;
  font-size: 12px;
  font-weight: 900;
  text-transform: none;
  letter-spacing: 0;
  white-space: nowrap;
  padding: 14px 18px;
  border-bottom: 1px solid #dbe4ee;
  background: #f8fafc;
  text-align: start;
}
.table td {
  vertical-align: middle;
  padding: 14px 18px;
  border-bottom: 1px solid #eef2f7;
  transition: background 0.2s ease;
  color: #334155;
  font-weight: 600;
  font-size: 14px;
  line-height: 1.5;
}
.table tbody tr { transition: all 0.2s ease; }
.table tbody tr:nth-child(even) td { background: #fcfdff; }
.table tbody tr:hover td { background: #f0fdf4; }
.table tbody tr:last-child td { border-bottom: none; }
.table th:first-child, .table td:first-child { padding-inline-start: 22px; }
.table th:last-child, .table td:last-child { padding-inline-end: 22px; }
.table td.actions {
  min-width: 168px;
  display: table-cell;
  position: sticky;
  inset-inline-end: 0;
  z-index: 1;
  background: #fff;
  white-space: nowrap;
  text-align: end;
  box-shadow: -12px 0 18px -20px rgba(15, 23, 42, .45);
}
html[dir="rtl"] .table td.actions { box-shadow: 12px 0 18px -20px rgba(15, 23, 42, .45); }
.table tbody tr:nth-child(even) td.actions { background: #fcfdff; }
.table tbody tr:hover td.actions { background: #f0fdf4; }
.table .btn-sm, .table td.actions .btn-sm {
  min-width: 34px;
  min-height: 34px;
  justify-content: center;
  padding: 6px 10px;
  border-radius: 9px;
}
.code-chip, .status-pill {
  display: inline-flex;
  align-items: center;
  min-height: 28px;
  padding: 4px 12px;
  border-radius: 999px;
  background: #f1f5f9;
  color: #475569;
  font-weight: 800;
  font-size: 12px;
  letter-spacing: 0.5px;
}
.status-pill { background: #e8f5ef; color: var(--brand); }
.data-link {
  color: #14532d;
  font-weight: 900;
  text-decoration: none;
  border-bottom: 1px solid rgba(20, 83, 45, .22);
}
.data-link:hover {
  color: #0f766e;
  border-bottom-color: #0f766e;
}
.table td .data-link + small,
.table td b + small { margin-top: 4px; }
.actions { display: inline-flex; gap: 6px; align-items: center; flex-wrap: wrap; }
.table td.actions > a,
.table td.actions > form { margin-inline-start: 5px; }
.actions form { display: inline; }
.empty, .empty-state { text-align: center; color: #94a3b8; padding: 48px 32px; background: #f8fafc; border: 2px dashed #e2e8f0; border-radius: 20px; margin: 16px 0; font-weight: 600; }
.empty-state i { font-size: 56px; color: #cbd5e1; display: block; margin-bottom: 16px; }
.panel, .auth-card { animation: fadeUp 0.5s cubic-bezier(0.16, 1, 0.3, 1) forwards; }
@keyframes fadeUp {
  from { opacity: 0; transform: translateY(12px); }
  to { opacity: 1; transform: translateY(0); }
}

.workflow-board {
  display: grid;
  grid-auto-flow: column;
  grid-auto-columns: minmax(240px, 1fr);
  gap: 12px;
  overflow-x: auto;
  overscroll-behavior-inline: contain;
  padding-bottom: 10px;
  max-width: 100%;
}
html[dir="rtl"] .workflow-board,
html[dir="rtl"] .task-lanes,
html[dir="rtl"] .table-responsive {
  direction: rtl;
}
.workflow-column, .task-lane { background: #eef2f7; border: 1px solid var(--line); border-radius: var(--radius); padding: 12px; min-height: 260px; }
.workflow-column h3, .task-lane h3 { font-size: 14px; color: var(--brand); margin-bottom: 10px; }
.work-card, .task-card {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 12px;
  margin-bottom: 10px;
}
.work-card p, .task-card p { margin: 8px 0; color: #334155; line-height: 1.5; }
.progress { height: 7px; background: #e2e8f0; border-radius: 999px; }
.progress-bar { background: var(--brand-2); }

.stack-list { display: grid; gap: 10px; }
.stack-list.compact { gap: 6px; }
.stack-item { display: flex; justify-content: space-between; gap: 12px; align-items: center; padding: 12px; border: 1px solid var(--line); border-radius: var(--radius); background: #fff; }
.stack-item span, .stack-item small { display: block; color: var(--muted); }
.stack-item.unread { border-color: #86efac; background: #f0fdf4; }

.cards-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 18px; }
.content-type-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 10px;
  margin-bottom: 18px;
}
.content-type-grid a {
  min-height: 58px;
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 12px 14px;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  color: #334155;
  font-weight: 900;
}
.content-type-grid a i { color: var(--brand-2); font-size: 20px; }
.content-type-grid a.active {
  background: #e8f5ef;
  color: var(--brand);
  border-color: #b7e4ca;
}
.info-card-head { display: flex; justify-content: space-between; align-items: center; gap: 10px; margin-bottom: 16px; }
.info-card p { color: var(--muted); line-height: 1.7; }
.info-meta { display: grid; gap: 8px; margin-top: 14px; color: #334155; }
.info-meta span { display: flex; align-items: center; gap: 8px; }
.message-preview { white-space: pre-wrap; background: #f8fafc; border: 1px solid var(--line); border-radius: var(--radius); padding: 12px; max-height: 150px; overflow: auto; color: #334155; }
.info-card.ai i { font-size: 34px; color: var(--brand-2); }
.task-lanes {
  display: grid;
  grid-auto-flow: column;
  grid-auto-columns: minmax(230px, 1fr);
  gap: 14px;
  overflow-x: auto;
  overscroll-behavior-inline: contain;
  max-width: 100%;
}
.mini-progress { display: grid; grid-template-columns: 1fr 82px 40px; gap: 6px; margin-top: 10px; }
.operations-intro {
  background:
    linear-gradient(135deg, rgba(15, 23, 42, .98), rgba(6, 78, 59, .94)),
    linear-gradient(90deg, rgba(217, 119, 6, .18), transparent);
}
.operations-kpis .metric-card { min-height: 132px; }
.operations-board-panel { overflow: hidden; }
.ops-pipeline {
  display: grid;
  grid-auto-flow: column;
  grid-auto-columns: minmax(280px, 1fr);
  gap: 14px;
  overflow-x: auto;
  padding-bottom: 12px;
  overscroll-behavior-inline: contain;
}
html[dir="rtl"] .ops-pipeline { direction: rtl; }
.ops-stage {
  min-height: 360px;
  padding: 12px;
  border: 1px solid #dbe7ef;
  border-radius: 16px;
  background: #f8fafc;
}
.ops-stage header {
  min-height: 42px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 12px;
}
.ops-stage header strong { color: #0f172a; font-size: 14px; font-weight: 900; }
.ops-stage header span {
  min-width: 30px;
  height: 30px;
  display: inline-grid;
  place-items: center;
  border-radius: 999px;
  background: #e8f5ef;
  color: var(--brand);
  font-weight: 900;
}
.ops-card {
  display: grid;
  gap: 10px;
  margin-bottom: 12px;
  padding: 14px;
  border: 1px solid #e2e8f0;
  border-radius: 16px;
  background: #fff;
  box-shadow: 0 8px 20px -16px rgba(15, 23, 42, .3);
}
.ops-card.warning { border-color: #facc15; background: #fffdf2; }
.ops-card.danger { border-color: #fecaca; background: #fff7f7; }
.ops-card-top { display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.ops-card-top b { color: var(--brand); font-weight: 900; }
.ops-card h4 { margin: 0; font-size: 15px; line-height: 1.45; font-weight: 900; color: #0f172a; }
.ops-card p { margin: 0; color: #64748b; font-size: 13px; font-weight: 700; line-height: 1.45; }
.ops-meta { display: grid; grid-template-columns: 1fr; gap: 7px; }
.ops-meta span {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: #475569;
  font-size: 12px;
  font-weight: 800;
}
.ops-meta i { color: var(--brand-2); font-size: 14px; }
.ops-card-action { display: flex; flex-wrap: wrap; gap: 8px; padding-top: 4px; }
.ops-empty {
  display: grid;
  place-items: center;
  min-height: 120px;
  border: 1px dashed #cbd5e1;
  border-radius: 14px;
  color: #94a3b8;
  font-weight: 900;
}
.reports-intro {
  background:
    linear-gradient(135deg, rgba(15, 23, 42, .98), rgba(20, 83, 45, .92)),
    linear-gradient(90deg, rgba(37, 99, 235, .18), rgba(217, 119, 6, .16));
}
.report-filters { margin-bottom: 24px; }
.report-filter-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(210px, 1fr));
  gap: 14px;
}
.report-filter-grid label { display: flex; flex-direction: column; }
.report-filter-grid span {
  margin-bottom: 7px;
  color: #475569;
  font-size: 12px;
  font-weight: 900;
  text-transform: uppercase;
}
.report-filter-actions {
  display: flex;
  justify-content: flex-end;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 16px;
  padding-top: 16px;
  border-top: 1px solid var(--line);
}
.report-nav-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(230px, 1fr));
  gap: 14px;
  margin-bottom: 24px;
}
.report-nav-card {
  min-height: 128px;
  display: grid;
  align-content: space-between;
  gap: 10px;
  padding: 18px;
  border: 1px solid #dbe7ef;
  border-radius: 16px;
  background: #fff;
  color: #0f172a;
  text-decoration: none;
  box-shadow: 0 10px 24px -20px rgba(15, 23, 42, .35);
}
.report-nav-card:hover, .report-nav-card.active {
  border-color: #86efac;
  background: #f0fdf4;
  color: #14532d;
}
.report-nav-card i { color: var(--brand-2); font-size: 24px; }
.report-nav-card b { display: block; font-size: 16px; font-weight: 900; }
.report-nav-card span { color: #64748b; font-size: 13px; font-weight: 700; line-height: 1.5; }
.report-section-grid { display: grid; grid-template-columns: 1fr; gap: 24px; }
.report-card-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 14px;
}
.relationship-card {
  display: grid;
  gap: 12px;
  padding: 16px;
  border: 1px solid #dbe7ef;
  border-radius: 16px;
  background: #fff;
  box-shadow: 0 10px 24px -20px rgba(15, 23, 42, .35);
}
.relationship-card header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
}
.relationship-card h4 {
  margin: 0 0 4px;
  color: #0f172a;
  font-size: 16px;
  font-weight: 900;
}
.relationship-card header span,
.relationship-card p,
.relationship-card small {
  margin: 0;
  color: #64748b;
  font-size: 13px;
  font-weight: 700;
  line-height: 1.55;
}
.relationship-metrics {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 8px;
}
.relationship-metrics span {
  min-height: 58px;
  display: grid;
  align-content: center;
  padding: 8px;
  border-radius: 12px;
  background: #f8fafc;
  color: #64748b;
  font-size: 11px;
  font-weight: 900;
  text-align: center;
}
.relationship-metrics b {
  display: block;
  color: #0f172a;
  font-size: 15px;
  overflow-wrap: anywhere;
}
.report-inline-numbers {
  display: inline-flex;
  align-items: center;
  gap: 3px;
  color: var(--brand);
  font-weight: 900;
}
.report-stack-link {
  color: inherit;
  text-decoration: none;
}
.report-stack-link em,
.stack-item em {
  color: var(--brand);
  font-style: normal;
  font-weight: 900;
  white-space: nowrap;
}
.settings-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; }
.settings-grid div { border: 1px solid var(--line); border-radius: var(--radius); padding: 14px; background: #f8fafc; }
.settings-grid span { color: var(--muted); display: block; font-size: 12px; font-weight: 800; }
.install-error { white-space: pre-wrap; direction: ltr; text-align: left; }
.permission-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}
.permission-grid section {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 14px;
  background: #f8fafc;
}
.permission-grid h4 { margin: 0 0 10px; font-size: 15px; font-weight: 900; color: var(--brand); }
.permission-grid label { display: inline-flex; align-items: center; gap: 6px; margin: 0 12px 8px 0; font-weight: 800; color: #334155; }
html[dir="rtl"] .permission-grid label { margin: 0 0 8px 12px; }

.site-nav {
  width: min(1280px, calc(100% - 40px));
  margin: 18px auto;
  min-height: 68px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  padding: 14px 28px;
  background: rgba(255, 255, 255, 0.88);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border: 1px solid rgba(226, 232, 240, 0.8);
  border-radius: 100px;
  box-shadow: 0 10px 30px -10px rgba(15, 23, 42, 0.08);
  position: sticky;
  top: 18px;
  z-index: 100;
  transition: all 0.3s ease;
}
.site-brand { display: flex; align-items: center; gap: 12px; color: var(--brand); font-weight: 900; font-size: 22px; text-decoration: none; }
.site-brand img { width: 44px; height: 44px; border-radius: 12px; }
.site-nav-links { display: flex; align-items: center; gap: 24px; color: #1e293b; font-weight: 800; font-size: 15px; }
.site-nav-links a { position: relative; padding: 6px 0; color: #334155; text-decoration: none; transition: color 0.25s ease; }
.site-nav-links a:hover, .site-nav-links a.active { color: var(--brand); font-weight: 900; }
.site-nav-links a::after { content: ''; position: absolute; bottom: 0; left: 0; width: 0; height: 2px; background: var(--brand); transition: width 0.25s ease; border-radius: 2px; }
.site-nav-links a:hover::after, .site-nav-links a.active::after { width: 100%; }
.site-actions { display: flex; align-items: center; gap: 10px; }
.site-actions .btn { border-radius: 100px; font-weight: 800; padding: 9px 20px; font-size: 14px; }
.site-actions .btn-portal { border: 1px solid #cbd5e1; background: #f8fafc; color: #334155; display: inline-flex; align-items: center; gap: 6px; }
.site-actions .btn-portal:hover { background: #f1f5f9; border-color: #94a3b8; color: var(--brand); }
.site-actions .btn-lang-switch { display: inline-flex; align-items: center; gap: 6px; }
.site-nav-toggle { display: none; background: #f1f5f9; border: 1px solid #e2e8f0; width: 42px; height: 42px; border-radius: 12px; cursor: pointer; color: #0f172a; font-size: 20px; }

/* Website Mobile Drawer */
.site-mobile-drawer {
  position: fixed;
  top: 0;
  bottom: 0;
  right: 0;
  width: min(85vw, 340px);
  background: #ffffff;
  z-index: 1050;
  box-shadow: -10px 0 30px rgba(15, 23, 42, 0.18);
  transform: translateX(105%);
  transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  display: flex;
  flex-direction: column;
  padding: 24px;
}
html[dir="rtl"] .site-mobile-drawer {
  right: auto;
  left: 0;
  box-shadow: 10px 0 30px rgba(15, 23, 42, 0.18);
  transform: translateX(-105%);
}
.site-mobile-drawer.open {
  transform: translateX(0) !important;
}
.site-mobile-drawer-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-bottom: 20px;
  border-bottom: 1px solid #e2e8f0;
}
.site-mobile-close {
  background: #f8fafc;
  border: 1px solid #e2e8f0;
  border-radius: 10px;
  width: 38px;
  height: 38px;
  display: grid;
  place-items: center;
  cursor: pointer;
}
.site-mobile-nav {
  display: flex;
  flex-direction: column;
  gap: 6px;
  padding: 20px 0;
  flex: 1;
  overflow-y: auto;
}
.site-mobile-nav a {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 14px;
  border-radius: 12px;
  color: #334155;
  font-weight: 800;
  font-size: 15px;
  text-decoration: none;
  transition: all 0.2s ease;
}
.site-mobile-nav a:hover, .site-mobile-nav a.active {
  background: #f0fdf4;
  color: var(--brand);
}
.site-mobile-drawer-footer {
  padding-top: 16px;
  border-top: 1px solid #e2e8f0;
}
.site-mobile-backdrop {
  position: fixed;
  inset: 0;
  background: rgba(15, 23, 42, 0.45);
  backdrop-filter: blur(4px);
  z-index: 1040;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.3s ease;
}
.site-mobile-backdrop.show {
  opacity: 1;
  pointer-events: auto;
}
.site-main { width: min(1280px, calc(100% - 40px)); margin: 0 auto; padding: 0 0 80px; }
.site-hero {
  min-height: 85vh;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 40px;
  align-items: center;
  padding: 60px 0;
  position: relative;
}
.site-hero::before {
  content: '';
  position: absolute;
  top: -10%; left: -10%; right: -10%; bottom: -10%;
  background: radial-gradient(circle at top right, rgba(6,78,59,0.08), transparent 50%),
              radial-gradient(circle at bottom left, rgba(20,83,45,0.08), transparent 50%);
  z-index: -1;
  border-radius: 40px;
}
.site-hero-copy { max-width: 600px; color: #0f172a; }
.site-hero-copy h1 { color: #0f172a; font-size: clamp(42px, 5vw, 64px); line-height: 1.1; margin-bottom: 24px; letter-spacing: -1px; }
.site-hero-copy p { color: #475569; font-size: 20px; line-height: 1.8; margin-bottom: 34px; }
.site-hero-copy .eyebrow { color: var(--brand); font-weight: 900; letter-spacing: 2px; text-transform: uppercase; margin-bottom: 16px; display: inline-block; padding: 8px 16px; background: rgba(6,78,59,0.1); border-radius: 100px; }
.site-hero-actions { display: flex; flex-wrap: wrap; gap: 16px; }
.site-hero-actions .btn { padding: 16px 32px; font-size: 18px; border-radius: 100px; }
.site-hero-panel {
  box-shadow: 0 18px 46px rgba(0,0,0,.18);
}
.site-hero-panel div {
  min-height: 96px;
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: 18px;
  border: 1px solid rgba(255,255,255,.2);
  border-radius: var(--radius);
  background: rgba(255,255,255,.1);
}
.site-hero-panel span { font-size: 46px; font-weight: 900; line-height: 1; color: var(--brand); display: block; margin-bottom: 8px; }
.site-hero-panel small { color: #64748b; font-size: 15px; font-weight: 600; line-height: 1.5; display: block; }
.site-section, .site-page-head { padding: 42px 0; }
.section-title { margin-bottom: 20px; }
.section-title h2, .site-split h2 { font-size: clamp(28px, 4vw, 46px); font-weight: 900; margin: 0; }
.site-card-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 18px; }
.site-card-grid.wide { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.site-card {
  background: var(--surface);
  backdrop-filter: blur(12px);
  border: var(--glass-border);
  border-radius: 16px;
  padding: 26px;
  min-height: 220px;
  box-shadow: 0 12px 30px -10px rgba(15,23,42,.06);
  transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1), box-shadow 0.3s ease;
}
.site-card:hover {
  transform: translateY(-8px);
  box-shadow: 0 24px 48px -12px rgba(15,23,42,.15);
}
.site-card i { font-size: 30px; color: var(--brand-2); }
.site-card h3 { font-size: 20px; font-weight: 900; margin: 18px 0 10px; }
.site-card p { color: #64748b; line-height: 1.7; margin: 0; }
.site-proof-band {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(280px, .6fr);
  gap: 24px;
  align-items: center;
  padding: 28px;
  border-radius: var(--radius);
  background: #10281f;
  color: #fff;
}
.site-proof-band h2 { margin: 0 0 10px; font-size: clamp(28px, 4vw, 44px); font-weight: 900; }
.site-proof-band p { color: rgba(255,255,255,.82); line-height: 1.8; margin: 0; }
.site-proof-list { display: grid; gap: 10px; }
.site-proof-list span { padding: 13px 14px; border: 1px solid rgba(255,255,255,.2); border-radius: var(--radius); background: rgba(255,255,255,.08); font-weight: 900; }
.site-split {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 380px;
  gap: 28px;
  align-items: start;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 28px;
}
.site-list { display: grid; gap: 10px; }
.site-list span {
  padding: 14px 16px;
  background: #f0fdf4;
  color: var(--brand);
  border: 1px solid #bbf7d0;
  border-radius: var(--radius);
  font-weight: 900;
}
.contact-layout { display: grid; grid-template-columns: minmax(0, 1fr) 360px; gap: 20px; align-items: start; }
.site-contact-form { display: grid; gap: 14px; }
.site-contact-form label span { display: block; font-weight: 800; margin-bottom: 6px; }
.contact-card {
  background: var(--brand);
  color: #fff;
  border-radius: var(--radius);
  padding: 24px;
  box-shadow: var(--shadow);
}
.contact-card p { color: rgba(255,255,255,.82); }

/* Interactive Website Animations */
.reveal { opacity: 0; transition: opacity 0.8s ease-out; }
.reveal.active { opacity: 1; }
.reveal-up { opacity: 0; transform: translateY(30px); transition: opacity 0.8s ease-out, transform 0.8s ease-out; }
.reveal-up.active { opacity: 1; transform: translateY(0); }
.reveal-delay-1 { transition-delay: 0.1s; }
.reveal-delay-2 { transition-delay: 0.2s; }
.reveal-delay-3 { transition-delay: 0.3s; }

/* Contact Form Floating Labels */
.floating-label { position: relative; display: flex; flex-direction: column; }
.floating-label input, .floating-label textarea {
  border: 2px solid var(--line);
  background: var(--surface);
  border-radius: var(--radius);
  padding: 24px 16px 8px;
  font-size: 16px;
  color: var(--text);
  transition: border-color 0.3s ease, box-shadow 0.3s ease;
}
.floating-label label {
  position: absolute;
  top: 16px;
  inset-inline-start: 16px;
  color: var(--muted);
  font-size: 16px;
  font-weight: 700;
  pointer-events: none;
  transition: all 0.2s ease;
}
.floating-label input:focus ~ label, .floating-label input:not(:placeholder-shown) ~ label,
.floating-label textarea:focus ~ label, .floating-label textarea:not(:placeholder-shown) ~ label {
  top: 6px;
  font-size: 12px;
  color: var(--brand);
}

/* Service Card Hover Tilt */
.site-card.tilt-hover {
  transform-style: preserve-3d;
  transition: transform 0.5s cubic-bezier(0.4, 0, 0.2, 1), box-shadow 0.5s ease;
}
.site-card.tilt-hover:hover {
  transform: perspective(1000px) rotateX(4deg) rotateY(-4deg) scale3d(1.02, 1.02, 1.02);
  box-shadow: 0 30px 60px -15px rgba(15, 23, 42, 0.2);
}
.site-card.tilt-hover > * {
  transform: translateZ(20px);
}

/* --- Premium Footer & Visuals --- */
.site-footer {
  background: #0f172a url('../images/footer_bg.png') center/cover no-repeat;
  color: #fff;
  padding: 120px 0 0;
  margin-top: 100px;
  position: relative;
}
.site-footer::before {
  content: ''; position: absolute; inset: 0; background: linear-gradient(to top, rgba(15,23,42,1) 10%, rgba(15,23,42,0.6));
}
.site-footer-grid, .footer-bottom { position: relative; z-index: 10; }

.site-cta-banner {
  background: var(--brand);
  border-radius: 32px;
  padding: 60px;
  text-align: center;
  color: #fff;
  max-width: 1000px;
  margin: -160px auto 80px;
  position: relative;
  z-index: 20;
  box-shadow: 0 30px 60px -15px rgba(6,78,59,0.4);
  overflow: hidden;
}
.site-cta-banner::before {
  content: ''; position: absolute; inset: 0; background: url('../images/footer_bg.png') center/cover; opacity: 0.2; mix-blend-mode: overlay;
}
.site-cta-banner h2 { font-size: 38px; font-weight: 900; margin-bottom: 20px; position: relative; z-index: 2; }
.site-cta-banner p { font-size: 20px; color: rgba(255,255,255,0.9); margin-bottom: 30px; position: relative; z-index: 2; }
.site-cta-banner .btn { position: relative; z-index: 2; font-size: 18px; padding: 16px 36px; border-radius: 100px; background: #fff; color: var(--brand); }

/* --- Visual Split Sections --- */
.site-split-visual {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 60px;
  align-items: center;
  padding: 80px 0;
}
.site-split-visual.reversed .split-image { order: 2; }
.site-split-visual.reversed .split-content { order: 1; }
html[dir="rtl"] .site-split-visual.reversed .split-image { order: 1; }
html[dir="rtl"] .site-split-visual.reversed .split-content { order: 2; }

.split-image img {
  width: 100%;
  border-radius: 32px;
  box-shadow: 0 40px 80px -20px rgba(15,23,42,0.15);
  transition: transform 0.5s ease;
}
.split-image:hover img { transform: translateY(-10px); }
.split-content h2 { font-size: 42px; font-weight: 900; margin-bottom: 24px; color: #0f172a; line-height: 1.2; }
.split-content p { font-size: 20px; color: #475569; line-height: 1.8; margin-bottom: 30px; }
.split-features { display: grid; gap: 16px; margin-bottom: 30px; }
.split-features span { display: flex; align-items: center; gap: 12px; font-size: 18px; font-weight: 700; color: #1e293b; }
.split-features i { color: var(--brand); font-size: 22px; background: rgba(6,78,59,0.1); width: 40px; height: 40px; display: flex; align-items: center; justify-content: center; border-radius: 50%; }

.site-footer-grid {
  width: min(1280px, calc(100% - 40px));
  margin: 0 auto;
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1.5fr;
  gap: 40px;
  padding-bottom: 60px;
}
.footer-brand img {
  width: 48px;
  height: 48px;
  border-radius: 12px;
}
.footer-brand p {
  color: #94a3b8;
  margin: 24px 0;
  line-height: 1.8;
  font-size: 16px;
}
.footer-socials { display: flex; gap: 16px; }
.footer-socials a {
  display: flex; align-items: center; justify-content: center;
  width: 44px; height: 44px;
  background: rgba(255,255,255,0.05);
  border-radius: 50%;
  color: #fff;
  transition: all 0.3s;
}
.footer-socials a:hover { background: var(--brand); transform: translateY(-4px); }
.footer-links h3, .footer-contact h3 { font-size: 20px; font-weight: 800; margin-bottom: 24px; color: #fff; }
.footer-links a {
  display: block; color: #94a3b8; margin-bottom: 12px; font-size: 16px; transition: color 0.3s;
}
.footer-links a:hover { color: #fff; padding-inline-start: 8px; }
.footer-contact p {
  display: flex; align-items: center; gap: 12px; color: #94a3b8; margin-bottom: 16px; font-size: 16px;
}
.footer-contact i { color: var(--brand); font-size: 20px; }
.footer-bottom {
  border-top: 1px solid rgba(255,255,255,0.1);
  padding: 24px 0;
  text-align: center;
  color: #64748b;
  font-size: 15px;
}

/* --- Infinite Marquee --- */
.marquee-wrapper {
  overflow: hidden;
  white-space: nowrap;
  padding: 30px 0;
  background: #f8fafc;
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
}
.marquee-content {
  display: inline-block;
  animation: marquee 30s linear infinite;
}
html[dir="rtl"] .marquee-content {
  animation: marquee-rtl 30s linear infinite;
}
.marquee-item {
  display: inline-flex; align-items: center; gap: 12px;
  padding: 0 40px;
}
.module-intro {
  margin-bottom: 24px;
  padding: 32px 40px;
  background: linear-gradient(135deg, #0f172a 0%, #0f766e 100%);
  border-radius: 24px;
  color: #fff;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 24px;
  position: relative;
  overflow: hidden;
  box-shadow: 0 10px 30px -10px rgba(15, 118, 110, 0.3);
}
.module-intro::before {
  content: '';
  position: absolute;
  inset: 0;
  background: radial-gradient(circle at top right, rgba(255,255,255,0.1), transparent 60%);
  pointer-events: none;
}
.module-intro h2 { font-size: 28px; font-weight: 900; margin: 0 0 8px; position: relative; z-index: 1; }
.module-intro p { font-size: 15px; color: rgba(255, 255, 255, 0.85); margin: 0; position: relative; z-index: 1; max-width: 600px; line-height: 1.5; }
.module-intro .eyebrow { display: none; } /* Hide the duplicated eyebrow text */
.marquee-item { font-size: 24px; font-weight: 900; color: #94a3b8; }
.marquee-item i { color: var(--brand); }
@keyframes marquee { 0% { transform: translateX(0); } 100% { transform: translateX(-50%); } }
@keyframes marquee-rtl { 0% { transform: translateX(0); } 100% { transform: translateX(50%); } }

/* --- Interactive Timeline --- */
.timeline {
  max-width: 800px; margin: 40px auto; position: relative;
}
.timeline::before {
  content: ''; position: absolute; top: 0; bottom: 0; left: 50%; width: 2px; background: var(--line);
  transform: translateX(-50%);
}
.timeline-item {
  display: flex; justify-content: flex-end; padding-right: 50%; position: relative; margin-bottom: 40px;
}
.timeline-item:nth-child(even) {
  justify-content: flex-start; padding-right: 0; padding-left: 50%;
}
.timeline-dot {
  position: absolute; right: calc(50% - 10px); top: 10px; width: 20px; height: 20px;
  background: var(--brand); border-radius: 50%; border: 4px solid #fff; box-shadow: 0 0 0 4px rgba(6,78,59,0.1);
  z-index: 2;
}
.timeline-item:nth-child(even) .timeline-dot { right: auto; left: calc(50% - 10px); }
.timeline-content {
  background: var(--surface); padding: 24px; border-radius: 16px; border: var(--glass-border);
  box-shadow: 0 10px 30px -10px rgba(0,0,0,0.05); width: calc(100% - 40px);
}
html[dir="rtl"] .timeline-item { justify-content: flex-start; padding-right: 0; padding-left: 50%; }
html[dir="rtl"] .timeline-item:nth-child(even) { justify-content: flex-end; padding-right: 50%; padding-left: 0; }
html[dir="rtl"] .timeline-dot { left: calc(50% - 10px); right: auto; }
html[dir="rtl"] .timeline-item:nth-child(even) .timeline-dot { right: calc(50% - 10px); left: auto; }

/* --- FAQ Accordion --- */
.faq-container { max-width: 800px; margin: 0 auto; }
.faq-item {
  background: var(--surface); border: var(--glass-border); border-radius: 16px;
  margin-bottom: 16px; overflow: hidden; transition: all 0.3s;
}
.faq-header {
  padding: 24px; cursor: pointer; display: flex; justify-content: space-between; align-items: center;
  font-size: 18px; font-weight: 800; color: var(--text);
}
.faq-header i { transition: transform 0.3s; color: var(--brand); font-size: 24px; }
.faq-content {
  padding: 0 24px; max-height: 0; opacity: 0; overflow: hidden; transition: all 0.4s ease-out;
  color: #475569; line-height: 1.8;
}
.faq-item.open { box-shadow: 0 10px 30px -10px rgba(0,0,0,0.05); border-color: rgba(6,78,59,0.2); }
.faq-item.open .faq-header i { transform: rotate(180deg); }
.faq-item.open .faq-content { padding: 0 24px 24px; max-height: 500px; opacity: 1; }

@media (max-width: 1200px) {
  .kpi-grid, .kpi-grid.executive { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .cards-grid, .site-card-grid, .site-card-grid.wide { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .grid-3 { grid-template-columns: 1fr; }
}
/* --- Internal Page Headers --- */
.site-page-head {
  text-align: center;
  padding: 140px 20px;
  background: #0f172a url('../images/footer_bg.png') center/cover no-repeat;
  color: #fff;
  position: relative;
  margin-bottom: 80px;
  border-bottom-left-radius: 60px;
  border-bottom-right-radius: 60px;
  box-shadow: 0 40px 80px -20px rgba(15,23,42,0.5);
  overflow: hidden;
}
.site-page-head::before {
  content: ''; position: absolute; inset: 0; background: linear-gradient(to top, rgba(15,23,42,1) 5%, rgba(6,78,59,0.7));
}
.site-page-head > * { position: relative; z-index: 2; }
.site-page-head .eyebrow { color: #34d399; margin-bottom: 24px; display: inline-block; background: rgba(52,211,153,0.15); padding: 8px 24px; border-radius: 100px; font-weight: 800; font-size: 16px; letter-spacing: 1px; }
.site-page-head h1 { font-size: 56px; font-weight: 900; margin-bottom: 24px; color: #fff; text-shadow: 0 10px 30px rgba(0,0,0,0.5); }
.site-page-head p { max-width: 700px; margin: 0 auto; font-size: 22px; color: rgba(255,255,255,0.85); line-height: 1.8; }

@media (max-width: 991px) {
  .auth-card { padding: 32px 24px; }
  .auth-panel { min-height: 100vh; }
  .mobile-brand { display: flex; }
  .sidebar {
    position: fixed;
    inset-block: 0;
    width: min(88vw, 320px);
    z-index: 40;
    transform: translateX(-105%);
  }
  .main, html[dir="rtl"] .main { margin-inline-start: 0; margin-inline-end: 0; }
  html[dir="rtl"] .sidebar { transform: translateX(105%); }
  .sidebar.open { transform: translateX(0); }
  .app-shell:not(.mobile-sidebar-open) .sidebar { transform: translateX(-105%); }
  html[dir="rtl"] .app-shell:not(.mobile-sidebar-open) .sidebar { transform: translateX(105%); }
  .app-shell.mobile-sidebar-open .sidebar { transform: translateX(0); }
  .sidebar-backdrop.show { position: fixed; inset: 0; background: rgba(15,23,42,.35); z-index: 30; }
  .topbar { position: static; padding: 14px 18px; }
  .content { padding: 18px; }
  .top-actions .btn-primary span { display: none; }
  .grid-2, .grid-3, .cards-grid, .settings-grid, .permission-grid { grid-template-columns: 1fr; }
  .site-nav {
    width: min(100% - 24px, 1280px);
    margin: 12px auto;
    padding: 10px 18px;
    border-radius: 50px;
  }
  .site-nav-links { display: none; }
  .site-nav-toggle { display: grid; place-items: center; }
  .site-actions .btn-cta { display: none; }
  .site-actions .btn-portal { padding: 8px 14px; font-size: 13px; }
  .site-actions .btn-lang-switch { padding: 8px 12px; font-size: 13px; }
  .site-hero, .site-split, .contact-layout, .site-proof-band { grid-template-columns: 1fr; gap: 30px; }
  .site-hero-panel { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .site-footer-grid { grid-template-columns: 1fr 1fr; gap: 30px; }
  .timeline::before { left: 20px; }
  .timeline-item, .timeline-item:nth-child(even) { justify-content: flex-start; padding: 0 0 0 60px; }
  .timeline-dot, .timeline-item:nth-child(even) .timeline-dot { left: 10px; right: auto; }
  html[dir="rtl"] .timeline::before { left: auto; right: 20px; transform: translateX(50%); }
  html[dir="rtl"] .timeline-item, html[dir="rtl"] .timeline-item:nth-child(even) { padding: 0 60px 0 0; }
  html[dir="rtl"] .timeline-dot, html[dir="rtl"] .timeline-item:nth-child(even) .timeline-dot { right: 10px; left: auto; }
}
@media (max-width: 640px) {
  .auth-card { padding: 24px; }
  .hero-band, .module-intro { align-items: flex-start; flex-direction: column; padding: 20px; }
  .kpi-grid, .kpi-grid.compact { grid-template-columns: 1fr; }
  .form-grid, .form-grid.single { grid-template-columns: 1fr; }
  .span-2 { grid-column: auto; }
  .task-lanes { grid-template-columns: repeat(4, minmax(250px, 1fr)); }
  .login-help { flex-direction: column; }
  .site-main, .site-nav { width: min(100% - 20px, 1180px); }
  .site-brand { font-size: 18px; }
  .site-brand img { width: 36px; height: 36px; }
  .site-card-grid, .site-card-grid.wide { grid-template-columns: 1fr; }
  .site-hero { min-height: auto; padding: 24px 0; }
  .site-hero-panel { grid-template-columns: 1fr; }
  .site-hero-copy h1, .site-page-head h1 { font-size: 30px; }
  .site-hero-copy p { font-size: 16px; line-height: 1.6; }
  .site-hero-actions .btn { width: 100%; text-align: center; }
  .site-split-visual { grid-template-columns: 1fr; gap: 24px; padding: 24px 0; }
  .site-split-visual.reversed .split-image { order: unset; }
  .site-split-visual.reversed .split-content { order: unset; }
  html[dir="rtl"] .site-split-visual.reversed .split-image { order: unset; }
  html[dir="rtl"] .site-split-visual.reversed .split-content { order: unset; }
  .site-actions .btn-portal span { display: none; }
  .site-actions .btn-portal { padding: 8px 10px; }
  
  .site-cta-banner { padding: 32px 16px; margin: -60px 12px 40px; border-radius: 16px; width: calc(100% - 24px); max-width: none; box-sizing: border-box; }
  .site-cta-banner h2 { font-size: 22px; }
  .site-cta-banner p { font-size: 14px; }

  /* Internal Pages Mobile Fixes */
  .site-page-head { padding: 80px 16px 40px; margin-bottom: 30px; border-bottom-left-radius: 24px; border-bottom-right-radius: 24px; }
  .site-page-head h1 { font-size: 28px; margin-bottom: 12px; }
  .site-page-head p { font-size: 15px; }
  
  .split-content h2 { font-size: 24px; }
  .split-content p { font-size: 15px; }
  
  .footer-bottom > div { flex-direction: column; text-align: center; justify-content: center; gap: 12px; }
}

@media (max-width: 768px) {
  .site-page-head { padding: 80px 16px 40px; }
  .site-page-head h1 { font-size: 28px; }
  .site-page-head p { font-size: 16px; }
  .split-content h2 { font-size: 24px; }
  .split-content p { font-size: 15px; }
  .split-features span { font-size: 15px; }
  .site-footer-grid { grid-template-columns: 1fr; gap: 28px; padding-bottom: 30px; }
  .site-footer { padding-top: 100px; margin-top: 60px; }
}
