/*
 * Mithaq Standards (ميثاق للمواصفات) — Landlord / Admin / Tenant branding
 * Royal Blue: #001669 | Gold: #B59E63 | Dark Gray: #333333
 */

@font-face {
  font-family: "Lexend Deca";
  src: url("../fonts/mithaq/LexendDeca-VariableFont_wght.ttf") format("truetype");
  font-weight: 100 900;
  font-style: normal;
  font-display: swap;
}

:root {
  --mithaq-royal-blue: #001669;
  --mithaq-gold: #b59e63;
  --mithaq-dark-gray: #333333;
  --mithaq-light-gray: #cccccc;
  --mithaq-font-en: "Lexend Deca", system-ui, sans-serif;
  --mithaq-font-ar: "Readex Pro", "Lexend Deca", system-ui, sans-serif;
}

body,
.page-wrapper,
.topbar,
.left-sidebar,
h1, h2, h3, h4, h5, h6,
.btn,
.form-control {
  font-family: var(--mithaq-font-en) !important;
}

html[lang="ar"] body,
html[dir="rtl"] body {
  font-family: var(--mithaq-font-ar) !important;
}

/* ── Logo — white header zone so blue logo stays visible ── */
.topbar .navbar-header,
#topnav-logo-container {
  width: 220px;
  max-width: 220px;
  min-width: 220px;
  min-height: 84px;
  height: 84px;
  flex-shrink: 0;
  overflow: visible;
  display: flex;
  align-items: center;
  justify-content: center;
  box-sizing: border-box;
  background: #ffffff !important;
  border-right: 1px solid #e8ecf2 !important;
  border-bottom: none !important;
  margin-top: 0 !important;
  line-height: normal !important;
  padding: 0 !important;
}

.topbar .navbar-header .navbar-brand img.logo-large,
#topnav-logo-container .navbar-brand img.logo-large {
  display: none;
  max-width: 204px !important;
  max-height: 72px !important;
  width: auto !important;
  height: auto !important;
  object-fit: contain !important;
  object-position: center center !important;
  filter: contrast(1.08) saturate(1.08) !important;
  image-rendering: auto;
  transform: translateZ(0);
  backface-visibility: hidden;
  vertical-align: middle;
}

.topbar .navbar-header .navbar-brand img.logo-small,
#topnav-logo-container .navbar-brand img.logo-small {
  display: none;
  max-width: 50px !important;
  max-height: 50px !important;
  width: auto !important;
  height: auto !important;
  object-fit: contain !important;
  filter: contrast(1.08) saturate(1.08) !important;
  image-rendering: auto;
  transform: translateZ(0);
  vertical-align: middle;
}

/* Full sidebar — show large logo */
.fix-sidebar:not(.mini-sidebar) #topnav-logo-container .logo-large,
.fix-sidebar:not(.mini-sidebar) .topbar .navbar-header .navbar-brand img.logo-large {
  display: inline-block !important;
}

.fix-sidebar:not(.mini-sidebar) #topnav-logo-container .logo-small,
.fix-sidebar:not(.mini-sidebar) .topbar .navbar-header .navbar-brand img.logo-small {
  display: none !important;
}

/* Mini sidebar — show compact logo */
.fix-sidebar.mini-sidebar #topnav-logo-container .logo-large,
.fix-sidebar.mini-sidebar .topbar .navbar-header .navbar-brand img.logo-large {
  display: none !important;
}

.fix-sidebar.mini-sidebar #topnav-logo-container .logo-small,
.fix-sidebar.mini-sidebar .topbar .navbar-header .navbar-brand img.logo-small {
  display: inline-block !important;
}

/* Tenant — keep topbar flush left; logo column aligns with sidebar */
html:not(.app-admin).fix-header.fix-sidebar:not(.mini-sidebar) .topbar {
  margin-left: 0 !important;
  width: 100% !important;
}

html:not(.app-admin).fix-header.fix-sidebar.mini-sidebar .topbar {
  margin-left: 0 !important;
  width: 100% !important;
}

/* Landlord — wider logo column (matches sidebar) */
html.app-admin .topbar .navbar-header,
html.app-admin #topnav-logo-container,
html.app-admin .mithaq-sidebar.left-sidebar {
  width: 240px !important;
  max-width: 240px !important;
}

html.app-admin .topbar .navbar-header .navbar-brand img.logo-large,
html.app-admin #topnav-logo-container .navbar-brand img.logo-large {
  max-width: 218px !important;
  max-height: 72px !important;
}

@media (min-width: 1024px) {
  html.app-admin .page-wrapper.mithaq-app,
  html.app-admin .page-wrapper {
    margin-left: 250px !important;
  }

  html.app-admin.settings .page-wrapper.mithaq-app,
  html.app-admin.settings .page-wrapper {
    margin-left: 270px !important;
  }
}

@media (min-width: 1024px) {
  html:not(.app-admin) .mithaq-app .page-wrapper {
    margin-left: 220px !important;
  }
}

@media (min-width: 768px) {
  html:not(.app-admin) .navbar-header,
  html:not(.app-admin) #topnav-logo-container {
    width: 220px !important;
    max-width: 220px !important;
    min-width: 220px !important;
  }

  html.app-admin .navbar-header {
    width: 240px !important;
    flex-shrink: 0;
  }
}

.topbar .navbar-header .sidenav-menu-item.logo {
  width: 100%;
  height: 100%;
  margin: 0 !important;
  padding: 0 !important;
  display: flex;
  align-items: center;
  justify-content: center;
}

.topbar .navbar-header .navbar-brand {
  width: 100%;
  max-width: 100%;
  height: 100%;
  margin: 0 !important;
  padding: 6px 8px !important;
  display: flex;
  align-items: center;
  justify-content: center;
  line-height: 1 !important;
}

.topbar .top-navbar {
  min-height: 84px !important;
  align-items: stretch !important;
}

.topbar .top-navbar .navbar-header {
  line-height: normal !important;
  padding: 0 !important;
  align-self: stretch;
}

html.app-admin.fix-header .page-wrapper {
  padding-top: 84px !important;
}

.fix-header .page-wrapper {
  padding-top: 84px !important;
}

/* Auth / login pages */
.auth-logo img,
.login-logo img {
  max-width: 420px !important;
  max-height: 120px !important;
  width: auto !important;
  height: auto !important;
}

/* Settings / upload preview (not topbar) */
.card-body img.logo-large,
.modal-body img.logo-large {
  max-width: 280px !important;
  max-height: 80px !important;
}

.sidenav-menu-item.logo {
  padding: 10px 12px !important;
}

/* Primary accent */
.btn-info,
.btn-info.disabled,
.btn-info:disabled {
  background-color: var(--mithaq-royal-blue);
  border-color: var(--mithaq-royal-blue);
}

.btn-info:hover,
.btn-info:focus,
.btn-info:active,
.btn-info.active,
.show > .btn-info.dropdown-toggle {
  background-color: #001a7a;
  border-color: #001a7a;
}

.btn-outline-info {
  color: var(--mithaq-royal-blue);
  border-color: var(--mithaq-royal-blue);
}

.btn-outline-info:hover,
.btn-outline-info:focus,
.btn-outline-info:active {
  background-color: var(--mithaq-royal-blue);
  border-color: var(--mithaq-royal-blue);
}

html body .bg-info {
  background-color: var(--mithaq-royal-blue) !important;
}

.text-info {
  color: var(--mithaq-royal-blue) !important;
}

a,
a:hover,
a:focus {
  color: var(--mithaq-royal-blue);
}

/* Tenant CRM sidebar (light theme) */
.left-sidebar:not(.mithaq-sidebar) .sidebar-nav ul li a.active,
.left-sidebar:not(.mithaq-sidebar) .sidebar-nav ul li a:hover,
.left-sidebar:not(.mithaq-sidebar) .sidebar-nav > ul > li.active > a,
.left-sidebar:not(.mithaq-sidebar) .sidebar-nav > ul > li.active > a i {
  color: var(--mithaq-royal-blue) !important;
}

.left-sidebar:not(.mithaq-sidebar) .sidebar-nav > ul > li > a.active {
  border-left: 3px solid var(--mithaq-gold);
}

.topbar {
  border-bottom: 2px solid var(--mithaq-gold);
}

.card.bg-info,
.panel-top-stats .bg-info {
  background: linear-gradient(135deg, var(--mithaq-royal-blue) 0%, #002080 100%) !important;
}

.card .card-footer a,
.stats-icon {
  color: var(--mithaq-gold) !important;
}

.progress-bar {
  background-color: var(--mithaq-royal-blue);
}

.page-item.active .page-link {
  background-color: var(--mithaq-royal-blue);
  border-color: var(--mithaq-royal-blue);
}

.page-link {
  color: var(--mithaq-royal-blue);
}

.form-control:focus,
.custom-select:focus {
  border-color: var(--mithaq-gold);
  box-shadow: 0 0 0 0.2rem rgba(181, 158, 99, 0.25);
}

/* ── Dashboard / Home ── */
.saas-home.mithaq-dashboard,
.container-fluid.mithaq-dashboard {
  background: linear-gradient(180deg, #f4f6fb 0%, #eef1f8 40%, #f8f9fc 100%);
  min-height: calc(100vh - 120px);
  padding-top: 10px;
  padding-bottom: 40px;
}

.mithaq-home-hero {
  border-radius: 20px;
  overflow: hidden;
  box-shadow: 0 12px 40px rgba(0, 22, 105, 0.12);
  background: linear-gradient(135deg, var(--mithaq-royal-blue) 0%, #001a8f 55%, #0025b8 100%);
  position: relative;
}

.mithaq-home-hero::before {
  content: "";
  position: absolute;
  top: 0;
  right: 0;
  width: 280px;
  height: 280px;
  background: radial-gradient(circle, rgba(181, 158, 99, 0.18) 0%, transparent 70%);
  pointer-events: none;
}

.mithaq-home-hero::after {
  content: "";
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  height: 3px;
  background: linear-gradient(90deg, transparent, var(--mithaq-gold), transparent);
}

.mithaq-home-hero__inner {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  padding: 32px 36px;
  position: relative;
  z-index: 1;
}

.mithaq-home-hero__badge {
  display: inline-block;
  padding: 4px 14px;
  border-radius: 20px;
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--mithaq-gold);
  background: rgba(181, 158, 99, 0.15);
  border: 1px solid rgba(181, 158, 99, 0.35);
  margin-bottom: 12px;
}

.mithaq-home-hero__title {
  color: #fff;
  font-size: 1.75rem;
  font-weight: 700;
  margin: 0 0 6px;
  line-height: 1.3;
}

.mithaq-home-hero__subtitle {
  color: rgba(255, 255, 255, 0.75);
  font-size: 14px;
  margin: 0 0 16px;
}

.mithaq-home-hero__metrics {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
}

.mithaq-home-hero__metric {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 8px 16px;
  border-radius: 10px;
  font-size: 13px;
  font-weight: 500;
  color: #fff;
  background: rgba(255, 255, 255, 0.1);
  border: 1px solid rgba(255, 255, 255, 0.15);
}

.mithaq-home-hero__metric i {
  color: var(--mithaq-gold);
  font-size: 16px;
}

.mithaq-home-hero__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.mithaq-home-hero__btn {
  padding: 10px 20px;
  border-radius: 10px;
  font-size: 13px;
  font-weight: 600;
  color: var(--mithaq-royal-blue) !important;
  background: #fff !important;
  border: none !important;
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.1);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.mithaq-home-hero__btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(0, 0, 0, 0.15);
  color: var(--mithaq-royal-blue) !important;
}

.mithaq-home-hero__btn--outline {
  color: #fff !important;
  background: transparent !important;
  border: 1px solid rgba(255, 255, 255, 0.4) !important;
  box-shadow: none;
}

.mithaq-home-hero__btn--outline:hover {
  background: rgba(255, 255, 255, 0.12) !important;
  color: #fff !important;
}

/* Stat cards */
.mithaq-stat-row {
  margin-top: 0;
}

.mithaq-stat-card {
  border: none !important;
  border-radius: 16px !important;
  box-shadow: 0 4px 20px rgba(0, 22, 105, 0.06) !important;
  transition: transform 0.25s ease, box-shadow 0.25s ease;
  overflow: hidden;
  position: relative;
}

.mithaq-stat-card::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 4px;
}

.mithaq-stat-card--success::before { background: #28a745; }
.mithaq-stat-card--info::before { background: var(--mithaq-royal-blue); }
.mithaq-stat-card--primary::before { background: #5c6bc0; }
.mithaq-stat-card--gold::before { background: var(--mithaq-gold); }

.mithaq-stat-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 12px 32px rgba(0, 22, 105, 0.12) !important;
}

.mithaq-stat-card .card-body {
  padding: 22px 24px !important;
}

.mithaq-stat-card__icon {
  width: 52px;
  height: 52px;
  border-radius: 14px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.mithaq-stat-card__icon i {
  font-size: 22px;
  color: #fff;
}

.mithaq-stat-card__icon--success { background: linear-gradient(135deg, #28a745, #20c997); }
.mithaq-stat-card__icon--info { background: linear-gradient(135deg, var(--mithaq-royal-blue), #0033cc); }
.mithaq-stat-card__icon--primary { background: linear-gradient(135deg, #5c6bc0, #7986cb); }
.mithaq-stat-card__icon--gold { background: linear-gradient(135deg, var(--mithaq-gold), #d4b87a); }

.mithaq-stat-card__label {
  font-size: 12px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: #8892a4;
  margin: 0 0 4px;
}

.mithaq-stat-card__value {
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--mithaq-dark-gray);
}

/* Chart & panel cards */
.mithaq-chart-row {
  margin-bottom: 10px;
}

.mithaq-dashboard-card {
  border: none !important;
  border-radius: 16px !important;
  box-shadow: 0 4px 24px rgba(0, 22, 105, 0.07) !important;
  margin-bottom: 24px;
  overflow: hidden;
}

.mithaq-dashboard-card__header {
  border-bottom: 1px solid #eef1f6;
  padding-bottom: 16px;
}

.mithaq-dashboard-card__title {
  font-size: 1.1rem !important;
  font-weight: 700 !important;
  color: var(--mithaq-royal-blue) !important;
  position: relative;
  padding-left: 14px;
}

.mithaq-dashboard-card__title::before {
  content: "";
  position: absolute;
  left: 0;
  top: 50%;
  transform: translateY(-50%);
  width: 4px;
  height: 20px;
  border-radius: 2px;
  background: var(--mithaq-gold);
}

.mithaq-dashboard-card .label-success {
  background: var(--mithaq-royal-blue) !important;
}

.mithaq-dashboard-card .ct-charts {
  min-height: 280px;
}

.mithaq-dashboard-card h2.font-light {
  color: var(--mithaq-royal-blue);
  font-weight: 700 !important;
}

/* Tenant CRM home widgets */
.mithaq-dashboard #js-trigger-home-admin-wrapper .card,
.mithaq-dashboard #js-trigger-home-team-wrapper .card,
.mithaq-dashboard #js-trigger-home-client-wrapper .card {
  border: none !important;
  border-radius: 14px !important;
  box-shadow: 0 4px 18px rgba(0, 22, 105, 0.06) !important;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
  overflow: hidden;
}

.mithaq-dashboard #js-trigger-home-admin-wrapper .col-lg-3:hover .card,
.mithaq-dashboard #js-trigger-home-admin-wrapper .col-md-6:hover .card {
  transform: translateY(-3px);
  box-shadow: 0 10px 28px rgba(0, 22, 105, 0.1) !important;
}

.mithaq-dashboard #js-trigger-home-admin-wrapper .card h2 {
  color: var(--mithaq-royal-blue);
  font-weight: 700;
}

.mithaq-dashboard #js-trigger-home-admin-wrapper .progress-bar.bg-success {
  background: linear-gradient(90deg, var(--mithaq-royal-blue), var(--mithaq-gold)) !important;
}

.mithaq-dashboard #js-trigger-home-admin-wrapper .text-success {
  color: var(--mithaq-gold) !important;
}

@media (max-width: 768px) {
  .mithaq-home-hero__inner {
    padding: 24px 20px;
  }

  .mithaq-home-hero__title {
    font-size: 1.35rem;
  }

  .mithaq-home-hero__actions {
    width: 100%;
  }

  .mithaq-home-hero__btn {
    flex: 1 1 auto;
    text-align: center;
  }

  .saas-home.mithaq-dashboard {
    padding-left: 15px !important;
    padding-right: 15px !important;
  }
}

html[dir="rtl"] .mithaq-dashboard-card__title {
  padding-left: 0;
  padding-right: 14px;
}

html[dir="rtl"] .mithaq-dashboard-card__title::before {
  left: auto;
  right: 0;
}

.mithaq-client-quick-links {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.mithaq-client-quick-links__item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 14px;
  border-radius: 12px;
  border: 1px solid #e2e8f0;
  background: #fff;
  color: var(--mithaq-royal-blue);
  font-weight: 600;
  text-decoration: none !important;
  transition: border-color 0.2s, box-shadow 0.2s;
}

.mithaq-client-quick-links__item:hover {
  border-color: var(--mithaq-gold);
  box-shadow: 0 4px 14px rgba(0, 22, 105, 0.08);
  color: var(--mithaq-royal-blue);
}

.mithaq-client-quick-links__item i {
  font-size: 18px;
  color: var(--mithaq-gold);
}

.mithaq-client-inspections code {
  font-size: 11px;
}

/* ── Landlord sidebar (mithaq-sidenav) ── */
/* Mini sidebar — logo column shrinks */
.mini-sidebar .topbar .navbar-header,
.mini-sidebar #topnav-logo-container,
html.app-admin.mini-sidebar .mithaq-sidebar.left-sidebar {
  width: 75px !important;
  max-width: 75px !important;
  min-width: 75px !important;
}

.mini-sidebar .topbar .navbar-header .navbar-brand img.logo-small,
.mini-sidebar #topnav-logo-container .navbar-brand img.logo-small {
  max-width: 48px !important;
  max-height: 48px !important;
}

html.app-admin .mithaq-sidebar.left-sidebar {
  background: transparent;
  border-right: none;
  box-shadow: 4px 0 28px rgba(0, 22, 105, 0.18);
  padding-top: 80px;
}

html.app-admin .mithaq-sidebar .scroll-sidebar {
  background: linear-gradient(185deg, #000d3d 0%, var(--mithaq-royal-blue) 45%, #001246 100%);
}

html.app-admin .mithaq-sidebar .sidebar-nav.mithaq-sidenav {
  background: transparent;
  padding: 12px 0 28px;
}

html.app-admin .mithaq-sidebar .mithaq-sidenav > ul > li {
  margin: 0;
  list-style: none;
}

html.app-admin .mithaq-sidebar .mithaq-sidenav > ul > li.sidenav-menu-item {
  margin-bottom: 2px;
}

html.app-admin .mithaq-sidebar .mithaq-sidenav > ul > li > a {
  color: rgba(255, 255, 255, 0.78) !important;
  margin: 2px 10px;
  padding: 11px 12px 11px 14px !important;
  border-radius: 10px;
  border-left: 3px solid transparent !important;
  font-weight: 500;
  font-size: 13.5px;
  transition: background 0.2s ease, color 0.2s ease, border-color 0.2s ease;
}

html.app-admin .mithaq-sidebar .mithaq-sidenav > ul > li > a i {
  color: rgba(255, 255, 255, 0.5) !important;
  width: 36px;
  font-size: 18px;
  text-align: center;
  transition: color 0.2s ease;
}

html.app-admin .mithaq-sidebar .mithaq-sidenav > ul > li > a .hide-menu {
  vertical-align: middle;
}

.mithaq-nav-item-label {
  display: inline-flex;
  flex-direction: column;
  align-items: flex-start;
  justify-content: center;
  gap: 1px;
  vertical-align: middle;
  line-height: 1.15;
  max-width: calc(100% - 44px);
}

.mithaq-nav-item-label__main {
  font-size: 13.5px;
  font-weight: 600;
  letter-spacing: 0.02em;
  color: inherit;
  white-space: nowrap;
}

.mithaq-nav-item-label__sub {
  font-size: 10px;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: rgba(181, 158, 99, 0.82);
  white-space: nowrap;
}

.mithaq-app .left-sidebar .mithaq-inspection-sidenav > a .mithaq-nav-item-label__sub {
  color: rgba(0, 22, 105, 0.55);
}

.mithaq-app .left-sidebar .mithaq-inspection-sidenav.active > a .mithaq-nav-item-label__sub,
.mithaq-app .left-sidebar .mithaq-inspection-sidenav > a:hover .mithaq-nav-item-label__sub {
  color: var(--mithaq-gold);
}

.mithaq-app .left-sidebar .mithaq-inspection-sidenav > a i.ti-clipboard {
  color: var(--mithaq-royal-blue) !important;
  opacity: 0.85;
}

.mithaq-app .left-sidebar .mithaq-inspection-sidenav.active > a i.ti-clipboard,
.mithaq-app .left-sidebar .mithaq-inspection-sidenav > a:hover i.ti-clipboard {
  color: var(--mithaq-gold) !important;
  opacity: 1;
}

html.app-admin .mithaq-sidebar .mithaq-sidenav > ul > li.mithaq-inspection-sidenav.active > a .mithaq-nav-item-label__sub,
html.app-admin .mithaq-sidebar .mithaq-sidenav > ul > li.mithaq-inspection-sidenav > a:hover .mithaq-nav-item-label__sub {
  color: var(--mithaq-gold);
}

html.app-admin .mithaq-sidebar .mithaq-sidenav > ul > li.mithaq-inspection-sidenav > a i.ti-clipboard {
  color: rgba(181, 158, 99, 0.72) !important;
}

html.app-admin .mithaq-sidebar .mithaq-sidenav > ul > li.mithaq-inspection-sidenav.active > a i.ti-clipboard,
html.app-admin .mithaq-sidebar .mithaq-sidenav > ul > li.mithaq-inspection-sidenav > a:hover i.ti-clipboard {
  color: var(--mithaq-gold) !important;
}

html.app-admin .mithaq-sidebar .mithaq-sidenav > ul > li > a:hover {
  background: rgba(255, 255, 255, 0.09) !important;
  color: #fff !important;
}

html.app-admin .mithaq-sidebar .mithaq-sidenav > ul > li > a:hover i {
  color: var(--mithaq-gold) !important;
}

html.app-admin .mithaq-sidebar .mithaq-sidenav > ul > li.active > a,
html.app-admin .mithaq-sidebar .mithaq-sidenav > ul > li.active > a:hover {
  background: linear-gradient(90deg, rgba(181, 158, 99, 0.28) 0%, rgba(255, 255, 255, 0.07) 100%) !important;
  border-left-color: var(--mithaq-gold) !important;
  color: #fff !important;
  font-weight: 600;
}

html.app-admin .mithaq-sidebar .mithaq-sidenav > ul > li.active > a i {
  color: var(--mithaq-gold) !important;
}

html.app-admin .mithaq-sidebar .mithaq-nav-label {
  padding: 16px 22px 6px;
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: rgba(181, 158, 99, 0.75);
  pointer-events: none;
  user-select: none;
}

html.app-admin .mithaq-sidebar .mithaq-nav-divider {
  height: 1px;
  margin: 10px 18px;
  padding: 0;
  background: linear-gradient(90deg, transparent, rgba(181, 158, 99, 0.35), transparent);
  pointer-events: none;
}

/* Submenu (Payments) */
html.app-admin .mithaq-sidebar .mithaq-sidenav li > a.has-arrow::after {
  border-color: rgba(255, 255, 255, 0.45);
}

html.app-admin .mithaq-sidebar .mithaq-sidenav li.active > a.has-arrow::after,
html.app-admin .mithaq-sidebar .mithaq-sidenav li > a.has-arrow[aria-expanded="true"]::after {
  border-color: var(--mithaq-gold);
}

html.app-admin .mithaq-sidebar .mithaq-sidenav ul li ul {
  padding: 4px 0 6px !important;
  margin: 2px 10px 8px;
  background: rgba(0, 0, 0, 0.2);
  border-radius: 8px;
  border-left: 2px solid rgba(181, 158, 99, 0.25);
}

html.app-admin .mithaq-sidebar .mithaq-sidenav ul li ul li a {
  color: rgba(255, 255, 255, 0.62) !important;
  padding: 8px 14px 8px 18px !important;
  font-size: 13px;
  border-radius: 6px;
  margin: 1px 6px;
}

html.app-admin .mithaq-sidebar .mithaq-sidenav ul li ul li a:hover,
html.app-admin .mithaq-sidebar .mithaq-sidenav ul li ul li a.active {
  color: #fff !important;
  background: rgba(181, 158, 99, 0.22) !important;
  font-weight: 500;
}

html.app-admin .mithaq-sidebar .mithaq-sidenav ul li ul li.sidenav-submenu.active > a {
  color: #fff !important;
  background: rgba(181, 158, 99, 0.28) !important;
}

/* Scrollbar */
html.app-admin .mithaq-sidebar .scroll-sidebar.ps .ps__scrollbar-y-rail {
  opacity: 0.4;
}

html.app-admin .mithaq-sidebar .scroll-sidebar.ps .ps__thumb-y {
  background: rgba(181, 158, 99, 0.5);
}

/* RTL */
html[dir="rtl"].app-admin .mithaq-sidebar .mithaq-sidenav > ul > li > a {
  border-left: none !important;
  border-right: 3px solid transparent !important;
}

html[dir="rtl"].app-admin .mithaq-sidebar .mithaq-sidenav > ul > li.active > a {
  border-right-color: var(--mithaq-gold) !important;
}

html[dir="rtl"].app-admin .mithaq-sidebar .mithaq-sidenav ul li ul {
  border-left: none;
  border-right: 2px solid rgba(181, 158, 99, 0.25);
}

@media (max-width: 767px) {
  html.app-admin .mithaq-sidebar .sidenav-menu-item {
    border-bottom-color: rgba(255, 255, 255, 0.08) !important;
  }
}

/* ══════════════════════════════════════════════════════════
   Mithaq App UI — all admin & CRM pages (.mithaq-app)
   ══════════════════════════════════════════════════════════ */

.mithaq-app {
  background: linear-gradient(180deg, #f4f6fb 0%, #eef1f8 45%, #f8f9fc 100%) !important;
}

/* Topbar */
html.app-admin .topbar {
  box-shadow: 0 2px 16px rgba(0, 22, 105, 0.08);
}

/* logo zone stays white — see logo rules above */

html.app-admin .topbar .navbar-light .navbar-nav .nav-item > a.nav-link {
  color: #5a6478 !important;
}

html.app-admin .topbar .navbar-light .navbar-nav .nav-item > a.nav-link:hover {
  color: var(--mithaq-royal-blue) !important;
}

/* Page header / breadcrumbs */
.mithaq-app .page-titles {
  background: #fff;
  border-radius: 16px;
  padding: 18px 24px !important;
  margin-bottom: 24px !important;
  box-shadow: 0 4px 20px rgba(0, 22, 105, 0.06);
  border-left: 4px solid var(--mithaq-gold);
  align-items: center;
}

.mithaq-app .page-titles h3,
.mithaq-app .text-themecolor {
  color: var(--mithaq-royal-blue) !important;
  font-weight: 700 !important;
  font-size: 1.35rem;
}

.mithaq-app .page-titles .breadcrumb {
  margin-top: 4px;
}

.mithaq-app .page-titles .breadcrumb li a {
  color: #6b7a90;
}

.mithaq-app .page-titles .breadcrumb .breadcrumb-item.active,
.mithaq-app .page-titles .breadcrumb .active-bread-crumb {
  color: var(--mithaq-royal-blue) !important;
  font-weight: 600;
}

/* Cards */
.mithaq-app .card {
  border: none !important;
  border-radius: 16px !important;
  box-shadow: 0 4px 24px rgba(0, 22, 105, 0.07) !important;
  margin-bottom: 24px;
  overflow: hidden;
}

.mithaq-app .card .card-title {
  color: var(--mithaq-royal-blue);
  font-weight: 700;
}

.mithaq-app .card .card-subtitle {
  color: #8892a4;
}

.mithaq-app .card-header {
  background: #fff;
  border-bottom: 1px solid #eef1f6;
  padding: 16px 20px;
}

/* Tables */
.mithaq-app .list-table-wrapper table thead th {
  background: #f4f6fb !important;
  color: var(--mithaq-royal-blue) !important;
  font-weight: 600 !important;
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  border-bottom: 2px solid rgba(181, 158, 99, 0.35) !important;
  border-top: none !important;
  padding: 14px 12px !important;
  white-space: nowrap;
}

.mithaq-app .list-table-wrapper table thead th a {
  color: var(--mithaq-royal-blue) !important;
}

.mithaq-app .list-table-wrapper table tbody td {
  padding: 12px !important;
  vertical-align: middle !important;
  border-color: #eef1f6 !important;
  color: #4a5568;
}

.mithaq-app .table-hover tbody tr:hover {
  background-color: rgba(0, 22, 105, 0.04) !important;
}

.mithaq-app .table tr:last-child td {
  border-bottom: 1px solid #eef1f6;
}

/* List page actions */
.mithaq-app #list-page-actions .header-search {
  border-radius: 10px;
  border: 1px solid #e2e8f0;
  background: #f8f9fc;
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.mithaq-app #list-page-actions .header-search:focus-within {
  border-color: var(--mithaq-gold);
  box-shadow: 0 0 0 3px rgba(181, 158, 99, 0.15);
  background: #fff;
}

.mithaq-app #list-page-actions .header-search input {
  background: transparent;
  border: none;
}

.mithaq-app .btn-page-actions {
  border-radius: 10px !important;
  border: 1px solid #e2e8f0 !important;
  background: #fff !important;
  color: var(--mithaq-royal-blue) !important;
  transition: all 0.2s ease;
}

.mithaq-app .btn-page-actions:hover {
  background: var(--mithaq-royal-blue) !important;
  border-color: var(--mithaq-royal-blue) !important;
  color: #fff !important;
}

.mithaq-app .btn-add-circle {
  border-radius: 50% !important;
  box-shadow: 0 4px 14px rgba(0, 22, 105, 0.2);
}

/* Buttons */
.mithaq-app .btn-primary,
.mithaq-app .btn-info {
  background-color: var(--mithaq-royal-blue) !important;
  border-color: var(--mithaq-royal-blue) !important;
  border-radius: 8px;
}

.mithaq-app .btn-primary:hover,
.mithaq-app .btn-info:hover {
  background-color: #001a7a !important;
  border-color: #001a7a !important;
}

.mithaq-app .btn-success {
  border-radius: 8px;
}

.mithaq-app .btn-danger.btn-add-circle,
.mithaq-app .btn-danger.edit-add-modal-button {
  background: linear-gradient(135deg, var(--mithaq-royal-blue), #0025b8) !important;
  border-color: var(--mithaq-royal-blue) !important;
}

/* Labels & badges */
.mithaq-app .label-info,
.mithaq-app .badge-info {
  background-color: var(--mithaq-royal-blue) !important;
}

.mithaq-app .label-success,
.mithaq-app .badge-success {
  background-color: #1a7f4b !important;
}

.mithaq-app .label-rounded {
  border-radius: 20px;
  padding: 4px 10px;
}

/* Forms */
.mithaq-app .form-control,
.mithaq-app .custom-select {
  border-radius: 8px;
  border-color: #dde3ec;
  min-height: 38px;
}

.mithaq-app .form-control:focus,
.mithaq-app .custom-select:focus {
  border-color: var(--mithaq-gold);
  box-shadow: 0 0 0 0.2rem rgba(181, 158, 99, 0.2);
}

.mithaq-app .form-group label,
.mithaq-app label.col-form-label {
  font-weight: 600;
  color: #4a5568;
  font-size: 13px;
}

.mithaq-app .input-group-text {
  border-radius: 8px;
  border-color: #dde3ec;
  background: #f4f6fb;
}

/* Modals (rendered at body level) */
html.app-admin .modal-content,
body.loggedin .modal-content {
  border: none;
  border-radius: 16px;
  box-shadow: 0 20px 60px rgba(0, 22, 105, 0.18);
  overflow: hidden;
}

html.app-admin .modal-header,
body.loggedin .modal-header {
  background: linear-gradient(135deg, var(--mithaq-royal-blue), #002080);
  border-bottom: 2px solid var(--mithaq-gold);
  padding: 16px 20px;
}

html.app-admin .modal-header .modal-title,
body.loggedin .modal-header .modal-title {
  color: #fff !important;
  font-weight: 700;
}

html.app-admin .modal-header .close,
html.app-admin .modal-header button.close,
body.loggedin .modal-header .close,
body.loggedin .modal-header button.close {
  color: #fff !important;
  opacity: 0.85;
  text-shadow: none;
}

html.app-admin .modal-footer,
body.loggedin .modal-footer {
  background: #f8f9fc;
  border-top: 1px solid #eef1f6;
  padding: 14px 20px;
}

/* Side panels (filters) — also at body level */
html.app-admin .side-panel .x-top-header,
body.loggedin .side-panel .x-top-header {
  background: linear-gradient(135deg, var(--mithaq-royal-blue), #002080);
  border-bottom: 2px solid var(--mithaq-gold);
}

html.app-admin .side-panel .x-top-header h3,
body.loggedin .side-panel .x-top-header h3 {
  color: #fff !important;
  font-weight: 700;
}

/* Settings / frontend inner menu */
.mithaq-app.has_left_inner_menu .left-inner-menu.mithaq-inner-menu {
  top: 80px;
  background: linear-gradient(180deg, #fff 0%, #f4f6fb 100%);
  border-right: 1px solid #e2e8f0;
  box-shadow: 4px 0 20px rgba(0, 22, 105, 0.05);
  padding: 24px 16px;
}

.mithaq-app .mithaq-inner-menu .inner-menu-item,
.mithaq-app .mithaq-inner-menu ul li > a {
  border-radius: 8px;
  padding: 10px 14px !important;
  font-size: 13.5px;
  font-weight: 500;
  color: #5a6478 !important;
  transition: all 0.2s ease;
}

.mithaq-app .mithaq-inner-menu .inner-menu-item:hover,
.mithaq-app .mithaq-inner-menu ul li > a:hover {
  background: rgba(0, 22, 105, 0.06) !important;
  color: var(--mithaq-royal-blue) !important;
}

.mithaq-app .mithaq-inner-menu a.inner-menu-item.active,
.mithaq-app .mithaq-inner-menu ul.inner-menu li a.active,
.mithaq-app .mithaq-inner-menu ul li a.active {
  background: linear-gradient(90deg, rgba(0, 22, 105, 0.1), rgba(181, 158, 99, 0.12)) !important;
  color: var(--mithaq-royal-blue) !important;
  font-weight: 600;
  border-left: 3px solid var(--mithaq-gold);
}

/* Pagination */
.mithaq-app .pagination .page-link {
  border-radius: 8px !important;
  margin: 0 3px;
  border-color: #e2e8f0;
}

.mithaq-app .pagination .page-item.active .page-link {
  background: var(--mithaq-royal-blue);
  border-color: var(--mithaq-royal-blue);
}

/* Tabs */
.mithaq-app .nav-tabs .nav-link {
  border-radius: 8px 8px 0 0;
  color: #6b7a90;
  font-weight: 500;
}

.mithaq-app .nav-tabs .nav-link.active {
  color: var(--mithaq-royal-blue) !important;
  border-bottom: 2px solid var(--mithaq-gold);
  font-weight: 600;
}

/* Alerts */
.mithaq-app .alert-info {
  background: rgba(0, 22, 105, 0.08);
  border-color: rgba(0, 22, 105, 0.15);
  color: var(--mithaq-royal-blue);
  border-radius: 10px;
}

/* Empty states */
.mithaq-app .empty-placeholder,
.mithaq-app .x-empty-tab {
  border-radius: 12px;
  background: #f8f9fc;
}

/* Tenant CRM — light sidebar polish */
html:not(.app-admin) .mithaq-app .left-sidebar:not(.mithaq-sidebar) {
  background: #fff;
  border-right: 1px solid #e8ecf2;
  box-shadow: 2px 0 16px rgba(0, 22, 105, 0.05);
  padding-top: 84px !important;
  width: 220px !important;
}

html:not(.app-admin) .mithaq-app .left-sidebar:not(.mithaq-sidebar) .sidebar-nav {
  background: #fff;
}

html:not(.app-admin) .mithaq-app .left-sidebar:not(.mithaq-sidebar) .sidebar-nav > ul > li > a {
  margin: 2px 8px;
  border-radius: 10px;
  border-left: 3px solid transparent;
}

html:not(.app-admin) .mithaq-app .left-sidebar:not(.mithaq-sidebar) .sidebar-nav > ul > li.active > a {
  background: rgba(0, 22, 105, 0.07) !important;
  border-left-color: var(--mithaq-gold) !important;
  font-weight: 600;
}

html:not(.app-admin) .mithaq-app .left-sidebar:not(.mithaq-sidebar) .sidebar-nav > ul > li > a:hover {
  background: rgba(0, 22, 105, 0.04);
}

/* RTL */
html[dir="rtl"] .mithaq-app .page-titles {
  border-left: none;
  border-right: 4px solid var(--mithaq-gold);
}

html[dir="rtl"] .mithaq-app .mithaq-inner-menu .inner-menu-item.active,
html[dir="rtl"] .mithaq-app .mithaq-inner-menu ul li a.active {
  border-left: none;
  border-right: 3px solid var(--mithaq-gold);
}

@media (max-width: 768px) {
  .mithaq-app .page-titles {
    padding: 14px 16px !important;
    border-radius: 12px;
  }

  .mithaq-app .page-titles h3 {
    font-size: 1.15rem;
  }

  .mithaq-app .container-fluid {
    padding-left: 15px;
    padding-right: 15px;
  }
}

/* ── Inspection Process — SAAC-style workflow UI ── */
.mithaq-process-page {
  padding-bottom: 2rem;
}

.mithaq-process-page__crumbs {
  margin-bottom: 0.5rem !important;
}

.mithaq-process-page__crumbs.page-titles {
  margin-bottom: 1rem !important;
}

.mithaq-process-header {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-start;
  justify-content: space-between;
  gap: 1rem;
  margin-bottom: 1.25rem;
}

.mithaq-process-header__eyebrow {
  margin: 0 0 0.35rem;
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--mithaq-gold);
}

.mithaq-process-header__title {
  margin: 0;
  font-size: 1.65rem;
  font-weight: 700;
  color: var(--mithaq-royal-blue);
  line-height: 1.3;
}

.mithaq-process-header__meta {
  margin: 0.5rem 0 0;
  color: #6b7a90;
  font-size: 0.9rem;
}

.mithaq-process-header__dot {
  margin: 0 0.4rem;
}

.mithaq-process-header__status {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.mithaq-process-badge {
  display: inline-flex;
  align-items: center;
  padding: 0.4rem 0.85rem;
  border-radius: 999px;
  font-size: 0.78rem;
  font-weight: 700;
}

.mithaq-process-badge.is-success {
  background: rgba(40, 167, 69, 0.12);
  color: #1a7f4b;
  border: 1px solid rgba(40, 167, 69, 0.35);
}

.mithaq-process-badge.is-active {
  background: rgba(0, 22, 105, 0.08);
  color: var(--mithaq-royal-blue);
  border: 1px solid rgba(0, 22, 105, 0.15);
}

.mithaq-process-badge.is-step {
  background: rgba(181, 158, 99, 0.15);
  color: #7a6535;
  border: 1px solid rgba(181, 158, 99, 0.35);
}

.mithaq-process-alert {
  border-radius: 12px;
  border: none;
  box-shadow: 0 4px 14px rgba(0, 22, 105, 0.08);
}

.mithaq-process-rail-card {
  border: none;
  border-radius: 16px;
  box-shadow: 0 8px 28px rgba(0, 22, 105, 0.08);
  overflow: hidden;
}

.mithaq-process-rail-card .card-body {
  padding: 1.5rem 1.25rem 1.25rem;
}

.mithaq-process-rail__track {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  list-style: none;
  margin: 0;
  padding: 0;
  gap: 0;
  position: relative;
}

.mithaq-process-rail__step {
  flex: 1 1 0;
  min-width: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  position: relative;
  z-index: 1;
}

.mithaq-process-rail__step:not(:last-child)::after {
  content: '';
  position: absolute;
  top: 22px;
  left: calc(50% + 24px);
  width: calc(100% - 48px);
  height: 3px;
  background: #e4e9f2;
  z-index: -1;
}

html[dir='rtl'] .mithaq-process-rail__step:not(:last-child)::after {
  left: auto;
  right: calc(50% + 24px);
}

.mithaq-process-rail__step.is-done:not(:last-child)::after {
  background: linear-gradient(90deg, #28a745, #3ecf6e);
}

.mithaq-process-rail__node {
  width: 46px;
  height: 46px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  background: #fff;
  border: 3px solid #dce3ef;
  color: #9aa8bc;
  font-size: 1rem;
  transition: all 0.2s ease;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.06);
}

.mithaq-process-rail__num {
  font-size: 0.95rem;
  font-weight: 800;
  line-height: 1;
}

.mithaq-process-rail__step.is-active .mithaq-process-rail__node {
  border-color: var(--mithaq-royal-blue);
  background: var(--mithaq-royal-blue);
  color: #fff;
  transform: scale(1.06);
  box-shadow: 0 8px 20px rgba(0, 22, 105, 0.25);
}

.mithaq-process-rail__step.is-active .mithaq-process-rail__num {
  color: #fff;
}

.mithaq-process-rail__step.is-done .mithaq-process-rail__node {
  border-color: #28a745;
  background: #28a745;
  color: #fff;
}

.mithaq-process-rail__label {
  display: block;
  margin-top: 0.65rem;
  padding: 0 0.2rem;
  font-size: 0.68rem;
  line-height: 1.3;
  color: #7a879c;
  font-weight: 600;
  max-width: 92px;
  margin-left: auto;
  margin-right: auto;
  word-wrap: break-word;
}

.mithaq-process-rail__step.is-active .mithaq-process-rail__label {
  color: var(--mithaq-royal-blue);
  font-weight: 700;
}

.mithaq-process-panel__header-row {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-start;
  justify-content: space-between;
  gap: 0.75rem;
}

.mithaq-process-panel__nav-back,
.mithaq-process-panel__nav-forward {
  margin: 0;
}

.mithaq-process-rail__hit {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.35rem;
  background: none;
  border: 0;
  padding: 0;
  margin: 0;
  width: 100%;
  text-align: center;
}

.mithaq-process-rail__step.is-clickable .mithaq-process-rail__hit {
  cursor: pointer;
}

.mithaq-process-rail__step.is-clickable .mithaq-process-rail__hit:hover .mithaq-process-rail__node {
  transform: scale(1.06);
  box-shadow: 0 4px 14px rgba(0, 22, 105, 0.18);
}

.mithaq-process-sidebar__step-form {
  margin: 0;
  width: 100%;
}

.mithaq-process-sidebar__step-btn {
  display: flex;
  align-items: flex-start;
  gap: 0.5rem;
  width: 100%;
  padding: 0;
  border: 0;
  background: none;
  text-align: inherit;
  color: inherit;
}

.mithaq-process-sidebar__item.is-clickable .mithaq-process-sidebar__step-btn {
  cursor: pointer;
}

.mithaq-process-sidebar__item.is-clickable .mithaq-process-sidebar__step-btn:hover .mithaq-process-sidebar__text {
  color: var(--mithaq-royal-blue);
  text-decoration: underline;
}

.mithaq-process-rail__step.is-done .mithaq-process-rail__label {
  color: #1a7f4b;
}

.mithaq-process-layout__main {
  order: 1;
}

.mithaq-process-layout__side {
  order: 2;
}

html[dir='rtl'] .mithaq-process-layout__main {
  order: 2;
}

html[dir='rtl'] .mithaq-process-layout__side {
  order: 1;
}

.mithaq-process-panel {
  background: #fff;
  border-radius: 16px;
  box-shadow: 0 10px 32px rgba(0, 22, 105, 0.08);
  overflow: hidden;
  border: 1px solid rgba(0, 22, 105, 0.06);
}

.mithaq-process-panel__header {
  padding: 1.25rem 1.5rem;
  background: linear-gradient(135deg, var(--mithaq-royal-blue) 0%, #0a2d8a 55%, #123f9e 100%);
  color: #fff;
  border-bottom: 4px solid var(--mithaq-gold);
}

.mithaq-process-panel__step {
  display: inline-block;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  opacity: 0.85;
  margin-bottom: 0.25rem;
}

.mithaq-process-panel__title {
  margin: 0;
  font-size: 1.35rem;
  font-weight: 700;
  color: #fff;
}

.mithaq-process-panel__hint {
  margin: 0.75rem 0 0;
  font-size: 0.85rem;
  opacity: 0.9;
}

.mithaq-process-panel__body {
  padding: 1.5rem;
  background: #f7f9fc;
}

.mithaq-process-form .form-group label {
  font-weight: 600;
  color: var(--mithaq-royal-blue);
  font-size: 0.88rem;
}

.mithaq-process-form .form-control {
  border-radius: 10px;
  border: 1px solid #d7dee8;
  min-height: 42px;
  background: #fff;
  box-shadow: inset 0 1px 2px rgba(0, 22, 105, 0.03);
}

.mithaq-process-form .form-control:focus {
  border-color: var(--mithaq-gold);
  box-shadow: 0 0 0 3px rgba(181, 158, 99, 0.2);
}

.mithaq-process-form .btn-info,
.mithaq-process-form .btn-success {
  border-radius: 10px;
  padding: 0.65rem 1.35rem;
  font-weight: 700;
  box-shadow: 0 6px 16px rgba(0, 22, 105, 0.15);
}

.mithaq-process-form .btn-info {
  background: var(--mithaq-royal-blue);
  border-color: var(--mithaq-royal-blue);
}

.mithaq-process-form .btn-info:hover {
  background: #00124f;
  border-color: #00124f;
}

.mithaq-process-form .alert {
  border-radius: 12px;
  border: none;
}

.mithaq-process-complete-icon {
  width: 72px;
  height: 72px;
  margin: 0 auto 1rem;
  border-radius: 50%;
  background: rgba(40, 167, 69, 0.12);
  color: #28a745;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 2rem;
}

.mithaq-process-sidebar__card {
  background: #fff;
  border-radius: 14px;
  border: 1px solid #e8edf4;
  box-shadow: 0 6px 20px rgba(0, 22, 105, 0.06);
  padding: 1rem 1rem 0.75rem;
  margin-bottom: 1rem;
}

.mithaq-process-sidebar__card--info {
  background: linear-gradient(180deg, #fff 0%, #f8fafc 100%);
}

.mithaq-process-sidebar__title {
  margin: 0 0 0.85rem;
  font-size: 0.95rem;
  font-weight: 700;
  color: var(--mithaq-royal-blue);
  padding-bottom: 0.65rem;
  border-bottom: 2px solid rgba(181, 158, 99, 0.35);
}

.mithaq-process-sidebar__list {
  list-style: none;
  margin: 0;
  padding: 0;
}

.mithaq-process-sidebar__item {
  display: flex;
  align-items: center;
  gap: 0.65rem;
  padding: 0.65rem 0.5rem;
  border-radius: 10px;
  margin-bottom: 0.25rem;
  color: #8a96a8;
  font-size: 0.84rem;
}

.mithaq-process-sidebar__item.is-done {
  color: var(--mithaq-royal-blue);
  font-weight: 600;
}

.mithaq-process-sidebar__item.is-active {
  background: rgba(0, 22, 105, 0.06);
  color: var(--mithaq-royal-blue);
  font-weight: 700;
}

.mithaq-process-sidebar__check {
  width: 26px;
  height: 26px;
  border-radius: 50%;
  border: 2px solid #d5dde8;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  font-size: 0.7rem;
}

.mithaq-process-sidebar__item.is-done .mithaq-process-sidebar__check {
  background: #28a745;
  border-color: #28a745;
  color: #fff;
}

.mithaq-process-sidebar__item.is-active .mithaq-process-sidebar__check {
  background: var(--mithaq-royal-blue);
  border-color: var(--mithaq-royal-blue);
  color: #fff;
}

.mithaq-process-sidebar__meta {
  margin: 0 0 0.75rem;
}

.mithaq-process-sidebar__meta dt {
  font-size: 0.72rem;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: #8a96a8;
  margin-bottom: 0.15rem;
}

.mithaq-process-sidebar__meta dd {
  margin: 0 0 0.65rem;
  font-size: 0.88rem;
  color: #334155;
  font-weight: 600;
}

.mithaq-process-sidebar__requirements {
  padding-top: 0.75rem;
  border-top: 1px solid #edf1f6;
  font-size: 0.82rem;
  color: #5c6b7f;
}

.mithaq-process-sidebar__requirements p {
  margin: 0.35rem 0 0;
}

.mithaq-process-sidebar__action {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  width: 100%;
  padding: 0.75rem 1rem;
  margin-bottom: 0.65rem;
  border-radius: 12px;
  background: var(--mithaq-royal-blue);
  color: #fff !important;
  font-weight: 700;
  font-size: 0.85rem;
  text-decoration: none !important;
  box-shadow: 0 6px 16px rgba(0, 22, 105, 0.18);
  transition: transform 0.15s ease, box-shadow 0.15s ease;
}

.mithaq-process-sidebar__action:hover {
  transform: translateY(-1px);
  box-shadow: 0 8px 20px rgba(0, 22, 105, 0.22);
  color: #fff !important;
}

.mithaq-process-sidebar__action--secondary {
  background: #fff;
  color: var(--mithaq-royal-blue) !important;
  border: 2px solid var(--mithaq-royal-blue);
  box-shadow: none;
}

.mithaq-process-sidebar__action--secondary:hover {
  background: rgba(0, 22, 105, 0.04);
  color: var(--mithaq-royal-blue) !important;
}

@media (max-width: 991px) {
  .mithaq-process-rail__label {
    font-size: 0.62rem;
  }

  .mithaq-process-rail__node {
    width: 38px;
    height: 38px;
    font-size: 0.85rem;
  }

  .mithaq-process-rail__step:not(:last-child)::after {
    top: 18px;
    left: calc(50% + 20px);
    width: calc(100% - 40px);
  }

  html[dir='rtl'] .mithaq-process-rail__step:not(:last-child)::after {
    right: calc(50% + 20px);
  }
}

@media (max-width: 767px) {
  .mithaq-process-rail__track {
    overflow-x: auto;
    justify-content: flex-start;
    padding-bottom: 0.5rem;
  }

  .mithaq-process-rail__step {
    flex: 0 0 88px;
  }

  .mithaq-process-rail__step:not(:last-child)::after {
    width: 40px;
    left: calc(50% + 20px);
  }

  .mithaq-process-header__title {
    font-size: 1.35rem;
  }
}

.mithaq-process-summary__label {
  display: block;
  font-size: 0.72rem;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: #8a96a8;
  margin-bottom: 0.2rem;
}

.mithaq-process-summary__block {
  margin-top: 0.75rem;
  padding-top: 0.75rem;
  border-top: 1px solid #e8edf4;
}

.mithaq-process-summary__block p {
  margin: 0.35rem 0 0;
  color: #4a5568;
}

.mithaq-process-file-list {
  list-style: none;
  margin: 0.5rem 0 0;
  padding: 0;
}

.mithaq-process-file-list li {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.55rem 0.75rem;
  margin-bottom: 0.35rem;
  background: #fff;
  border: 1px solid #e2e8f0;
  border-radius: 10px;
}

.mithaq-process-file-list li i {
  color: var(--mithaq-gold);
}

.mithaq-process-upload {
  position: relative;
  padding: 1.25rem;
  border: 2px dashed #c8d2e0;
  border-radius: 12px;
  background: #fff;
  text-align: center;
}

.mithaq-process-upload > i {
  display: block;
  font-size: 1.5rem;
  color: var(--mithaq-royal-blue);
  margin-bottom: 0.5rem;
}

.mithaq-process-upload input[type='file'] {
  border: none;
  background: transparent;
  box-shadow: none;
  padding: 0;
}

.mithaq-process-form__actions {
  margin-top: 1rem;
  padding-top: 1rem;
  border-top: 1px solid #e8edf4;
}

.mithaq-process-table thead th {
  background: #f4f7fb;
  color: var(--mithaq-royal-blue);
  font-weight: 700;
  border: none;
  font-size: 0.82rem;
  text-transform: uppercase;
  letter-spacing: 0.03em;
}

.mithaq-process-table tbody td {
  vertical-align: middle;
  border-color: #edf1f6;
}

.mithaq-process-table tbody tr:hover {
  background: rgba(0, 22, 105, 0.03);
}

.mithaq-pre-forms-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 1rem;
}

.mithaq-pre-form-card {
  position: relative;
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
  padding: 1rem 1rem 0.85rem 3rem;
  border: 2px solid #dce3ef;
  border-radius: 14px;
  background: #fff;
  cursor: pointer;
  transition: all 0.2s ease;
  margin: 0;
}

.mithaq-pre-form-card:hover {
  border-color: rgba(0, 22, 105, 0.25);
  box-shadow: 0 8px 20px rgba(0, 22, 105, 0.08);
}

.mithaq-pre-form-card.is-selected {
  border-color: var(--mithaq-royal-blue);
  background: linear-gradient(180deg, rgba(0, 22, 105, 0.04) 0%, #fff 100%);
  box-shadow: 0 8px 22px rgba(0, 22, 105, 0.12);
}

.mithaq-pre-form-card input[type='checkbox'] {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}

.mithaq-pre-form-card__check {
  position: absolute;
  top: 1rem;
  left: 1rem;
  width: 22px;
  height: 22px;
  border-radius: 6px;
  border: 2px solid #c5cedd;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: transparent;
  font-size: 0.7rem;
  background: #fff;
}

html[dir='rtl'] .mithaq-pre-form-card {
  padding: 1rem 3rem 0.85rem 1rem;
}

html[dir='rtl'] .mithaq-pre-form-card__check {
  left: auto;
  right: 1rem;
}

.mithaq-pre-form-card.is-selected .mithaq-pre-form-card__check {
  background: var(--mithaq-royal-blue);
  border-color: var(--mithaq-royal-blue);
  color: #fff;
}

.mithaq-pre-form-card__code {
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--mithaq-gold);
}

.mithaq-pre-form-card__name {
  font-size: 0.95rem;
  font-weight: 700;
  color: var(--mithaq-royal-blue);
  line-height: 1.35;
}

.mithaq-pre-form-card__download {
  margin-top: 0.35rem;
  font-size: 0.8rem;
  font-weight: 600;
  color: #5c6b7f !important;
  text-decoration: none !important;
}

.mithaq-pre-form-card__download:hover {
  color: var(--mithaq-royal-blue) !important;
}

.mithaq-pre-forms-placeholder {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  padding: 1.25rem 1rem;
  border: 2px dashed #dce3ef;
  border-radius: 14px;
  color: #5c6b7f;
  font-size: 0.9rem;
  background: #f8fafc;
}

.mithaq-pre-forms-inline {
  display: flex;
  flex-direction: column;
  gap: 1.25rem;
}

.mithaq-pre-form-inline {
  border: 2px solid #dce3ef;
  border-radius: 14px;
  background: #fff;
  overflow: hidden;
}

.mithaq-pre-form-inline__header {
  padding: 1rem 1.15rem;
  background: linear-gradient(180deg, rgba(0, 22, 105, 0.05) 0%, #fff 100%);
  border-bottom: 1px solid #e8edf5;
}

.mithaq-pre-form-inline__code {
  display: inline-block;
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--mithaq-gold);
  margin-bottom: 0.2rem;
}

.mithaq-pre-form-inline__title {
  margin: 0;
  font-size: 1rem;
  font-weight: 700;
  color: var(--mithaq-royal-blue);
}

.mithaq-pre-form-inline__table-wrap {
  overflow-x: auto;
}

.mithaq-pre-form-inline__table {
  width: 100%;
  margin: 0;
  border-collapse: collapse;
}

.mithaq-pre-form-inline__table th,
.mithaq-pre-form-inline__table td {
  padding: 0.75rem 1rem;
  border-bottom: 1px solid #eef2f7;
  vertical-align: middle;
}

.mithaq-pre-form-inline__table th {
  font-size: 0.78rem;
  text-transform: uppercase;
  letter-spacing: 0.03em;
  color: #5c6b7f;
  background: #f8fafc;
}

.mithaq-pre-form-inline__table .col-check {
  width: 52px;
  text-align: center;
}

.mithaq-pre-form-inline__row-check {
  display: inline-flex;
  margin: 0;
  cursor: pointer;
}

.mithaq-pre-form-inline__row-check input {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}

.mithaq-pre-form-inline__row-check span {
  width: 22px;
  height: 22px;
  border-radius: 6px;
  border: 2px solid #c5cedd;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: transparent;
  font-size: 0.7rem;
  background: #fff;
}

.mithaq-pre-form-inline__row-check input:checked + span {
  background: var(--mithaq-royal-blue);
  border-color: var(--mithaq-royal-blue);
  color: #fff;
}

.mithaq-pre-form-summary-list {
  list-style: none;
  margin: 0.5rem 0 0;
  padding: 0;
}

.mithaq-pre-form-summary-list__item {
  padding: 0.75rem 0;
  border-bottom: 1px solid #eef2f7;
}

.mithaq-pre-form-summary-list__item:last-child {
  border-bottom: 0;
}

.mithaq-pre-form-summary-list__header {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  flex-wrap: wrap;
  color: var(--mithaq-royal-blue);
}

.mithaq-pre-form-summary-list__items {
  margin: 0.5rem 0 0 1.75rem;
  padding: 0;
  color: #4a5568;
  font-size: 0.9rem;
}

.mithaq-pre-form-summary-list__items li {
  margin-bottom: 0.25rem;
}

.mithaq-pre-form-doc__body {
  padding: 1rem 1.15rem 1.15rem;
}

.mithaq-pre-form-doc__p {
  margin: 0 0 1rem;
  color: #2d3748;
  line-height: 1.55;
  font-size: 0.92rem;
}

.mithaq-pre-form-doc__decision {
  margin: 0 0 1rem;
  padding: 0.85rem 1rem;
  border: 1px solid #e8edf5;
  border-radius: 10px;
  background: #f8fafc;
  color: #2d3748;
  line-height: 1.8;
}

.mithaq-pre-form-doc__box {
  display: inline-block;
  width: 16px;
  height: 16px;
  border: 2px solid #9aa8bc;
  border-radius: 3px;
  vertical-align: middle;
  margin: 0 0.15rem;
}

.mithaq-pre-form-doc__table-wrap {
  overflow-x: auto;
  margin-bottom: 0.5rem;
}

.mithaq-pre-form-doc__table {
  width: 100%;
  border-collapse: collapse;
  border: 1px solid #dce3ef;
}

.mithaq-pre-form-doc__table th,
.mithaq-pre-form-doc__table td {
  border: 1px solid #dce3ef;
  padding: 0.65rem 0.75rem;
  vertical-align: middle;
  font-size: 0.9rem;
}

.mithaq-pre-form-doc__table th {
  background: #f0f4fa;
  color: var(--mithaq-royal-blue);
  font-weight: 700;
  text-transform: none;
}

.mithaq-pre-form-doc__table tr.is-field .is-label {
  font-weight: 600;
  color: #4a5568;
  white-space: nowrap;
  width: 180px;
}

.mithaq-pre-form-doc__line {
  display: block;
  min-height: 1.35rem;
  border-bottom: 1px solid #c5cedd;
}

.mithaq-pre-form-doc__table tr.is-item.is-selected {
  background: rgba(0, 22, 105, 0.04);
}

.mithaq-pre-form-doc__mark {
  display: inline-flex;
  width: 22px;
  height: 22px;
  border-radius: 6px;
  border: 2px solid #c5cedd;
  align-items: center;
  justify-content: center;
  color: transparent;
  font-size: 0.7rem;
}

.mithaq-pre-form-doc__mark.is-checked {
  background: var(--mithaq-royal-blue);
  border-color: var(--mithaq-royal-blue);
  color: #fff;
}

.mithaq-pre-form-doc.has-item-comments .mithaq-pre-form-doc__table .col-comment {
  min-width: 180px;
  width: 28%;
}

.mithaq-pre-form-doc__item-comment-input {
  font-size: 0.82rem;
  padding: 0.35rem 0.5rem;
  height: auto;
}

.mithaq-pre-form-doc__item-comment {
  display: block;
  font-size: 0.85rem;
  color: #4a5568;
  white-space: pre-wrap;
}

.mithaq-pre-form-doc__table tr.is-section td {
  background: #e8edf5;
  font-weight: 700;
  color: var(--mithaq-royal-blue);
  text-transform: uppercase;
  font-size: 0.82rem;
  letter-spacing: 0.03em;
}

.mithaq-equipment-checklist-panel[hidden] {
  display: none !important;
}

.mithaq-checklist-setup {
  padding: 1rem 1.15rem;
  border: 1px solid #e2e8f0;
  border-radius: 10px;
  background: #f8fafc;
}

.mithaq-process-file-list li {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  flex-wrap: wrap;
}

/* legacy inspection helpers (create page, etc.) */
.mithaq-inspection-steps {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  list-style: none;
  padding: 0;
  margin: 0;
}

.mithaq-inspection-steps__item {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 8px 14px;
  border-radius: 10px;
  background: #f4f6fb;
  border: 1px solid #e2e8f0;
  font-size: 12px;
  color: #6b7a90;
}

.mithaq-inspection-steps__item.is-active {
  background: linear-gradient(90deg, rgba(0, 22, 105, 0.1), rgba(181, 158, 99, 0.15));
  border-color: var(--mithaq-gold);
  color: var(--mithaq-royal-blue);
  font-weight: 600;
}

.mithaq-inspection-steps__item.is-done {
  background: rgba(40, 167, 69, 0.1);
  border-color: #28a745;
  color: #1a7f4b;
}

.mithaq-inspection-steps__num {
  width: 24px;
  height: 24px;
  border-radius: 50%;
  background: #fff;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 11px;
}

.mithaq-inspection-steps__item.is-active .mithaq-inspection-steps__num {
  background: var(--mithaq-royal-blue);
  color: #fff;
}

.mithaq-inspection-workflow .card-title {
  color: var(--mithaq-royal-blue);
  font-weight: 700;
}

.mithaq-inspection-create-steps {
  padding-right: 1.25rem;
  margin: 0;
}

.mithaq-inspection-create-steps li {
  margin-bottom: 0.5rem;
  color: #555;
}

.mithaq-inspection-done-list {
  list-style: none;
  padding: 0;
  margin: 0;
}

.mithaq-inspection-done-list li {
  padding: 0.5rem 0 0.5rem 1.5rem;
  position: relative;
  border-bottom: 1px solid #eee;
  color: #888;
}

.mithaq-inspection-done-list li::before {
  content: '○';
  position: absolute;
  right: 0;
  color: #ccc;
}

.mithaq-inspection-done-list li.is-done {
  color: var(--mithaq-royal-blue);
  font-weight: 600;
}

.mithaq-inspection-done-list li.is-done::before {
  content: '✓';
  color: #28a745;
}

.mithaq-inspection-done-list li.is-active {
  color: #17a2b8;
  font-weight: 700;
}

.mithaq-inspection-return-banner .alert {
  border-radius: 0;
  border: none;
  border-bottom: 2px solid var(--mithaq-royal-blue);
}

/* ── Tenant CRM login (mithaq.localhost/login) ── */
.logged-out .mithaq-auth {
  min-height: 100vh;
  position: relative;
  z-index: 10;
}

.logged-out .mithaq-auth__layout {
  display: flex;
  min-height: 100vh;
}

.logged-out .mithaq-auth__brand {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 48px;
  background: linear-gradient(145deg, #000d3d 0%, var(--mithaq-royal-blue) 50%, #0025b8 100%);
  position: relative;
  overflow: hidden;
}

.logged-out .mithaq-auth__brand::before {
  content: "";
  position: absolute;
  top: -80px;
  right: -80px;
  width: 320px;
  height: 320px;
  background: radial-gradient(circle, rgba(181, 158, 99, 0.2) 0%, transparent 70%);
  pointer-events: none;
}

.logged-out .mithaq-auth__brand::after {
  content: "";
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  height: 4px;
  background: linear-gradient(90deg, transparent, var(--mithaq-gold), transparent);
}

.logged-out .mithaq-auth__brand-inner {
  position: relative;
  z-index: 1;
  max-width: 420px;
  text-align: center;
}

.logged-out .mithaq-auth__brand-title {
  color: #fff;
  font-size: 2rem;
  font-weight: 700;
  margin-bottom: 16px;
  line-height: 1.3;
}

.logged-out .mithaq-auth__brand-tagline {
  color: rgba(255, 255, 255, 0.8);
  font-size: 1.05rem;
  line-height: 1.7;
  margin: 0;
}

.logged-out .mithaq-auth__panel {
  width: 480px;
  max-width: 100%;
  flex-shrink: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 40px 32px;
  background: #f4f6fb;
}

.logged-out .mithaq-auth__logo {
  padding: 0 0 24px !important;
  margin: 0 !important;
}

.logged-out .mithaq-auth__logo img {
  max-width: 280px !important;
  max-height: 90px !important;
}

.logged-out .mithaq-auth .login-box.mithaq-auth__box {
  width: 100% !important;
  max-width: 400px;
  margin: 0 !important;
  padding: 32px 28px !important;
  border-radius: 16px !important;
  border: none !important;
  box-shadow: 0 12px 40px rgba(0, 22, 105, 0.1) !important;
}

.logged-out .mithaq-auth__title {
  color: var(--mithaq-royal-blue) !important;
  font-weight: 700 !important;
  font-size: 1.35rem !important;
}

.logged-out .mithaq-auth__subtitle {
  font-size: 14px;
  color: #6b7a90 !important;
}

.logged-out .mithaq-auth .form-control {
  border-radius: 10px;
  min-height: 44px;
  border-color: #dde3ec;
  padding: 10px 14px;
}

.logged-out .mithaq-auth .form-control:focus {
  border-color: var(--mithaq-gold);
  box-shadow: 0 0 0 3px rgba(181, 158, 99, 0.2);
}

.logged-out .mithaq-auth__submit {
  border-radius: 10px !important;
  min-height: 48px;
  font-weight: 600;
  background: linear-gradient(135deg, var(--mithaq-royal-blue), #0025b8) !important;
  border: none !important;
  box-shadow: 0 4px 16px rgba(0, 22, 105, 0.25);
}

.logged-out .mithaq-auth__submit:hover {
  background: linear-gradient(135deg, #001a7a, var(--mithaq-royal-blue)) !important;
}

.logged-out .mithaq-auth a.text-info {
  color: var(--mithaq-royal-blue) !important;
  font-weight: 600;
}

/* Hide default stock login background when using mithaq-auth */
.logged-out .mithaq-auth ~ .login-background,
.logged-out #main-wrapper:has(.mithaq-auth) .login-background {
  display: none !important;
}

@media (max-width: 900px) {
  .logged-out .mithaq-auth__layout {
    flex-direction: column;
  }

  .logged-out .mithaq-auth__brand {
    padding: 32px 24px;
    min-height: auto;
  }

  .logged-out .mithaq-auth__brand-title {
    font-size: 1.5rem;
  }

  .logged-out .mithaq-auth__panel {
    width: 100%;
    flex: 1;
    padding: 24px 20px 40px;
  }
}

/* Pre-Inspection sub-wizard (SAAC-style) */
.mithaq-pre-wizard {
  --mithaq-saac-green: #2d9f6f;
  --mithaq-saac-green-dark: #248a5f;
  --mithaq-saac-green-soft: rgba(45, 159, 111, 0.12);
}

.mithaq-pre-wizard__layout {
  align-items: flex-start;
}

.mithaq-pre-wizard__panel-card {
  background: #fff;
  border: 1px solid #e8edf4;
  border-radius: 16px;
  padding: 1.35rem 1.5rem 1.5rem;
  box-shadow: 0 8px 24px rgba(0, 22, 105, 0.06);
  min-height: 420px;
}

.mithaq-pre-wizard__panel-head {
  margin-bottom: 1.25rem;
  padding-bottom: 1rem;
  border-bottom: 1px solid #eef2f7;
}

.mithaq-pre-wizard__panel-eyebrow {
  display: block;
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  color: var(--mithaq-saac-green);
  margin-bottom: 0.35rem;
}

.mithaq-pre-wizard__panel-title {
  margin: 0;
  font-size: 1.2rem;
  font-weight: 700;
  color: #1f2937;
  line-height: 1.4;
}

.mithaq-pre-wizard__form-body .mithaq-pre-form-doc__body {
  padding: 0;
}

.mithaq-pre-wizard__footer {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 0.75rem;
  margin-top: 1.5rem;
  padding-top: 1.25rem;
  border-top: 1px solid #eef2f7;
}

.mithaq-pre-wizard__next {
  background: var(--mithaq-saac-green);
  border-color: var(--mithaq-saac-green);
  border-radius: 10px;
  font-weight: 700;
  padding: 0.6rem 1.25rem;
}

.mithaq-pre-wizard__next:hover {
  background: var(--mithaq-saac-green-dark);
  border-color: var(--mithaq-saac-green-dark);
}

.mithaq-pre-wizard__prev {
  border-radius: 10px;
  font-weight: 600;
}

.mithaq-pre-wizard__nav {
  background: #fff;
  border: 1px solid #e8edf4;
  border-radius: 16px;
  padding: 1rem;
  box-shadow: 0 8px 24px rgba(0, 22, 105, 0.06);
  position: sticky;
  top: 1rem;
}

.mithaq-pre-wizard__nav-title {
  margin: 0 0 0.85rem;
  font-size: 0.95rem;
  font-weight: 700;
  color: var(--mithaq-royal-blue);
  padding-bottom: 0.65rem;
  border-bottom: 2px solid rgba(45, 159, 111, 0.25);
}

.mithaq-pre-wizard__nav-list {
  list-style: none;
  margin: 0;
  padding: 0;
}

.mithaq-pre-wizard__nav-item {
  display: flex;
  align-items: flex-start;
  gap: 0.65rem;
  padding: 0.7rem 0.55rem;
  border-radius: 10px;
  margin-bottom: 0.2rem;
  cursor: pointer;
  color: #8a96a8;
  font-size: 0.84rem;
  line-height: 1.35;
  transition: background 0.15s ease, color 0.15s ease;
}

.mithaq-pre-wizard__nav-item:hover {
  background: #f8fafc;
}

.mithaq-pre-wizard__nav-item.is-active {
  background: var(--mithaq-saac-green-soft);
  color: #1f2937;
  font-weight: 700;
}

.mithaq-pre-wizard__nav-item.is-done {
  color: var(--mithaq-saac-green-dark);
  font-weight: 600;
}

.mithaq-pre-wizard__nav-icon {
  width: 26px;
  height: 26px;
  border-radius: 50%;
  border: 2px solid #d5dde8;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  font-size: 0.72rem;
  font-weight: 700;
  color: #8a96a8;
  background: #fff;
}

.mithaq-pre-wizard__nav-check {
  display: none;
  font-size: 0.65rem;
}

.mithaq-pre-wizard__nav-item.is-done .mithaq-pre-wizard__nav-icon,
.mithaq-pre-wizard__nav-item.is-active.is-done .mithaq-pre-wizard__nav-icon {
  background: var(--mithaq-saac-green);
  border-color: var(--mithaq-saac-green);
  color: #fff;
}

.mithaq-pre-wizard__nav-item.is-done .mithaq-pre-wizard__nav-num {
  display: none;
}

.mithaq-pre-wizard__nav-item.is-done .mithaq-pre-wizard__nav-check {
  display: inline;
}

.mithaq-pre-wizard__nav-item.is-active .mithaq-pre-wizard__nav-icon {
  border-color: var(--mithaq-saac-green);
  color: var(--mithaq-saac-green);
}

.mithaq-pre-wizard__comment label {
  font-weight: 600;
  color: #4a5568;
  font-size: 0.88rem;
}

.mithaq-pre-wizard__comment-display {
  padding: 0.85rem 1rem;
  border-radius: 10px;
  background: #f8fafc;
  border: 1px solid #e8edf4;
}

.mithaq-pre-wizard__comment-display strong {
  display: block;
  margin-bottom: 0.35rem;
  color: var(--mithaq-royal-blue);
  font-size: 0.88rem;
}

.mithaq-pre-wizard__comment-display p {
  margin: 0;
  color: #4a5568;
  font-size: 0.9rem;
  line-height: 1.5;
}

html[dir='rtl'] .mithaq-pre-wizard__footer {
  justify-content: flex-start;
}

@media (max-width: 991px) {
  .mithaq-pre-wizard__nav {
    position: static;
    margin-bottom: 1rem;
  }

  .mithaq-pre-wizard__panel-card {
    min-height: auto;
  }
}

.mithaq-tech-review__status-bar {
  display: flex;
  align-items: flex-start;
  gap: 0.75rem;
  padding: 1rem 1.15rem;
  border-radius: 12px;
  border: 1px solid #e8edf4;
}

.mithaq-tech-review__status-bar i {
  font-size: 1.35rem;
  margin-top: 0.1rem;
}

.mithaq-tech-review__status-bar strong {
  display: block;
  font-size: 1rem;
  margin-bottom: 0.2rem;
}

.mithaq-tech-review__status-bar span {
  font-size: 0.86rem;
  color: #5c6b7f;
}

.mithaq-tech-review__status-bar.is-pending {
  background: #fffbeb;
  border-color: #fde68a;
  color: #92400e;
}

.mithaq-tech-review__status-bar.is-approved {
  background: #ecfdf5;
  border-color: #a7f3d0;
  color: #065f46;
}

.mithaq-tech-review__status-bar.is-rejected {
  background: #fef2f2;
  border-color: #fecaca;
  color: #991b1b;
}

.mithaq-tech-review__pdf-frame {
  border: 1px solid #dce3ef;
  border-radius: 12px;
  overflow: hidden;
  background: #f8fafc;
  min-height: 520px;
}

.mithaq-tech-review__pdf-frame iframe {
  width: 100%;
  height: 72vh;
  min-height: 520px;
  border: 0;
  background: #fff;
}

.mithaq-tech-review__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
}

.mithaq-tech-review__pdf-toolbar {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.mithaq-delivery-card {
  border: 1px solid #dce3ef;
  border-radius: 16px;
  background: linear-gradient(135deg, #f8fafc 0%, #ffffff 55%, #f3f6fb 100%);
  overflow: hidden;
  box-shadow: 0 10px 28px rgba(0, 22, 105, 0.06);
}

.mithaq-delivery-card__header {
  display: flex;
  align-items: flex-start;
  gap: 1rem;
  padding: 1.15rem 1.35rem;
  border-bottom: 1px solid #e8edf4;
  background: rgba(255, 255, 255, 0.72);
}

.mithaq-delivery-card__icon {
  flex-shrink: 0;
  width: 44px;
  height: 44px;
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: linear-gradient(145deg, var(--mithaq-royal-blue), #0a2d8f);
  color: #fff;
  font-size: 1.15rem;
  box-shadow: 0 6px 16px rgba(0, 22, 105, 0.22);
}

.mithaq-delivery-card__title {
  margin: 0 0 0.25rem;
  font-size: 1.02rem;
  font-weight: 700;
  color: var(--mithaq-royal-blue);
  line-height: 1.3;
}

.mithaq-delivery-card__hint {
  margin: 0;
  font-size: 0.84rem;
  color: #5c6b7f;
  line-height: 1.45;
}

.mithaq-delivery-card__badge {
  margin-left: auto;
  flex-shrink: 0;
  align-self: center;
  padding: 0.35rem 0.7rem;
  border-radius: 999px;
  background: #eef2ff;
  border: 1px solid #c7d2fe;
  color: var(--mithaq-royal-blue);
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.02em;
}

.mithaq-delivery-card__actions {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0.85rem;
  padding: 1rem 1.15rem 1.15rem;
}

.mithaq-delivery-card__action {
  margin: 0;
  min-width: 0;
}

.mithaq-delivery-btn {
  display: flex;
  align-items: center;
  gap: 0.85rem;
  width: 100%;
  min-height: 78px;
  padding: 0.9rem 1rem;
  border-radius: 14px;
  border: 1px solid transparent;
  text-align: left;
  text-decoration: none !important;
  transition: transform 0.18s ease, box-shadow 0.18s ease, border-color 0.18s ease, background 0.18s ease;
  cursor: pointer;
  background: #fff;
  font: inherit;
  appearance: none;
  -webkit-appearance: none;
}

.mithaq-delivery-btn:hover,
.mithaq-delivery-btn:focus {
  transform: translateY(-2px);
  text-decoration: none !important;
  outline: none;
}

.mithaq-delivery-btn__icon {
  flex-shrink: 0;
  width: 42px;
  height: 42px;
  border-radius: 11px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.1rem;
}

.mithaq-delivery-btn__text {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 0.15rem;
}

.mithaq-delivery-btn__text strong {
  display: block;
  font-size: 0.92rem;
  font-weight: 700;
  line-height: 1.25;
}

.mithaq-delivery-btn__text small {
  display: block;
  font-size: 0.76rem;
  line-height: 1.35;
  opacity: 0.88;
}

.mithaq-delivery-btn__arrow {
  flex-shrink: 0;
  width: 28px;
  height: 28px;
  border-radius: 999px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.72rem;
  opacity: 0;
  transform: translateX(-4px);
  transition: opacity 0.18s ease, transform 0.18s ease;
}

.mithaq-delivery-btn:hover .mithaq-delivery-btn__arrow,
.mithaq-delivery-btn:focus .mithaq-delivery-btn__arrow {
  opacity: 1;
  transform: translateX(0);
}

.mithaq-delivery-btn.is-email {
  border-color: #bfdbfe;
  box-shadow: 0 4px 14px rgba(37, 99, 235, 0.08);
  color: #1e3a8a;
}

.mithaq-delivery-btn.is-email .mithaq-delivery-btn__icon {
  background: #eff6ff;
  color: #2563eb;
}

.mithaq-delivery-btn.is-email .mithaq-delivery-btn__text small {
  color: #475569;
}

.mithaq-delivery-btn.is-email .mithaq-delivery-btn__arrow {
  background: #dbeafe;
  color: #1d4ed8;
}

.mithaq-delivery-btn.is-email:hover,
.mithaq-delivery-btn.is-email:focus {
  border-color: #93c5fd;
  box-shadow: 0 10px 22px rgba(37, 99, 235, 0.14);
  background: #f8fbff;
}

.mithaq-delivery-btn.is-whatsapp {
  border-color: #bbf7d0;
  box-shadow: 0 4px 14px rgba(22, 163, 74, 0.08);
  color: #14532d;
}

.mithaq-delivery-btn.is-whatsapp .mithaq-delivery-btn__icon {
  background: #ecfdf5;
  color: #16a34a;
}

.mithaq-delivery-btn.is-whatsapp .mithaq-delivery-btn__text small {
  color: #475569;
}

.mithaq-delivery-btn.is-whatsapp .mithaq-delivery-btn__arrow {
  background: #dcfce7;
  color: #15803d;
}

.mithaq-delivery-btn.is-whatsapp:hover,
.mithaq-delivery-btn.is-whatsapp:focus {
  border-color: #86efac;
  box-shadow: 0 10px 22px rgba(22, 163, 74, 0.14);
  background: #f6fff9;
}

.mithaq-delivery-btn.is-disabled {
  border-color: #e2e8f0;
  background: #f8fafc;
  color: #94a3b8;
  cursor: not-allowed;
  box-shadow: none;
  transform: none;
}

.mithaq-delivery-btn.is-disabled .mithaq-delivery-btn__icon {
  background: #eef2f7;
  color: #94a3b8;
}

.mithaq-delivery-btn.is-disabled .mithaq-delivery-btn__text small {
  color: #94a3b8;
}

@media (max-width: 767px) {
  .mithaq-delivery-card__header {
    flex-wrap: wrap;
  }

  .mithaq-delivery-card__badge {
    margin-left: 0;
  }

  .mithaq-delivery-card__actions {
    grid-template-columns: 1fr;
  }
}

.mithaq-final-report__section {
  margin-bottom: 1.5rem;
  padding-bottom: 1.25rem;
  border-bottom: 1px solid #eef2f7;
}

.mithaq-final-report__section-title {
  margin: 0 0 1rem;
  padding: 0.5rem 0.75rem;
  background: var(--mithaq-royal-blue);
  color: #fff;
  font-size: 0.88rem;
  font-weight: 700;
  border-radius: 8px;
}

.mithaq-final-report__checklist th {
  background: #f0f4fa;
  color: var(--mithaq-royal-blue);
  font-size: 0.82rem;
}

.mithaq-final-report__checklist tr.is-section td {
  background: #e8edf5;
  font-weight: 700;
  color: var(--mithaq-royal-blue);
}

.mithaq-final-report__photos-title {
  margin: 0 0 0.5rem;
  font-size: 0.9rem;
  font-weight: 700;
  color: var(--mithaq-royal-blue);
}

.mithaq-final-report__photo-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(140px, 1fr));
  gap: 0.75rem;
}

.mithaq-final-report__photo-card {
  position: relative;
  margin: 0;
  padding: 0.5rem;
  border: 1px solid #dce3ef;
  border-radius: 10px;
  background: #fff;
}

.mithaq-final-report__photo-card img {
  display: block;
  width: 100%;
  height: 110px;
  object-fit: cover;
  border-radius: 8px;
}

.mithaq-final-report__photo-card figcaption {
  margin-top: 0.35rem;
  font-size: 0.72rem;
  color: #64748b;
  word-break: break-all;
}

.mithaq-final-report__photo-delete {
  position: absolute;
  top: 0.55rem;
  right: 0.55rem;
  margin: 0;
}

.mithaq-final-report__photo-upload .input-group {
  max-width: 520px;
}
