@import url('https://fonts.googleapis.com/css2?family=Cairo:wght@300;400;600;700&display=swap');

:root {
  --pro-blue: #2b82c9;
  --pro-blue-dark: #1e5e91;
  --bg-light: #f4f7f9;
  --text-dark: #333333;
  --white: #ffffff;
  --border-light: #e1e8ed;
}

html,
body {
  direction: rtl;
  font-family: 'Cairo', sans-serif;
  background-color: var(--bg-light);
  color: var(--text-dark);
  min-height: 100vh;
  margin: 0;
  overflow-x: hidden;
}

/* Rebranding: Pro Sys Corporate Style */
.pro-card {
  background: var(--white);
  border: 1px solid var(--border-light);
  border-radius: 8px;
  overflow: hidden;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.05);
  margin-top: 50px;
}

.pro-card-header {
  background-color: var(--pro-blue);
  color: var(--white);
  padding: 15px 20px;
  font-weight: 600;
  text-align: center;
  font-size: 1.25rem;
}

/* Login Page Layout (Two-Column Split) */
.login-split {
  display: flex;
  flex-direction: row-reverse;
  /* For RTL: Image Left, Form Right */
}

.login-left {
  flex: 1;
  background: var(--white);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 40px;
}

.login-right {
  flex: 1.2;
  padding: 40px;
  background: var(--white);
  border-right: 1px solid var(--border-light);
}

.login-logo {
  max-width: 500px;
  height: auto;
}

/* Sidebar Styles (RTL) */
.sidebar-pro {
  width: 260px;
  height: calc(100vh - 60px);
  position: fixed;
  right: 0;
  top: 60px;
  background-color: var(--white);
  border-left: 1px solid var(--border-light);
  z-index: 1000;
  display: flex !important;
  flex-direction: column;
  box-shadow: -2px 0 10px rgba(0, 0, 0, 0.02);
  overflow-y: auto;
  scrollbar-width: thin;
}

.sidebar-nav {
  padding: 20px 0;
  flex-grow: 1;
}

.nav-link-pro {
  display: flex;
  align-items: center;
  padding: 12px 25px;
  color: var(--text-dark) !important;
  text-decoration: none;
  font-weight: 500;
  transition: all 0.2s;
  border-right: 4px solid transparent;
}

.nav-link-pro i {
  margin-left: 15px;
  width: 20px;
  text-align: center;
  color: var(--pro-blue);
}

.nav-link-pro:hover,
.nav-link-pro.active {
  background-color: rgba(43, 130, 201, 0.05);
  color: var(--pro-blue) !important;
  border-right-color: var(--pro-blue);
}

.main-container {
  margin-right: 260px;
  padding: 40px;
  min-height: calc(100vh - 60px);
  background: radial-gradient(circle at top left, rgba(43, 130, 201, 0.05), transparent),
    radial-gradient(circle at bottom right, rgba(43, 130, 201, 0.02), transparent);
  background-color: #f8fbff;
}

/* Navbar Branding (Top utility bar) */
.navbar-pro {
  height: 60px;
  background-color: var(--pro-blue) !important;
  color: var(--white) !important;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
  padding: 0;
  border-bottom: none;
  margin-right: 0;
  width: 100%;
  z-index: 1050;
  transition: none;
}

/* Mobile Toggle */
.mobile-nav-toggle {
  display: none;
  background: none;
  border: none;
  color: white;
  font-size: 1.5rem;
  margin-left: 15px;
  cursor: pointer;
}

.navbar-pro .btn-outline-secondary {
  color: var(--white) !important;
  border-color: rgba(255, 255, 255, 0.5) !important;
}

.navbar-pro .btn-outline-secondary:hover {
  background-color: rgba(255, 255, 255, 0.1) !important;
}

.navbar-pro .text-secondary {
  color: var(--white) !important;
  opacity: 0.9;
}

.navbar-pro .navbar-brand {
  color: var(--white) !important;
  font-weight: 700;
  font-size: 1.5rem;
  letter-spacing: 0.5px;
}

.navbar-pro .nav-link {
  color: rgba(255, 255, 255, 0.9) !important;
  margin: 0 10px;
}

.navbar-pro .nav-link:hover {
  color: var(--white) !important;
}

/* Buttons */
.btn-pro {
  background-color: var(--pro-blue);
  color: var(--white) !important;
  border: none;
  border-radius: 4px;
  padding: 12px 25px;
  font-weight: 600;
  transition: background 0.2s;
}

.btn-pro:hover {
  background-color: var(--pro-blue-dark);
}

/* Form Styling */
.form-group-pro {
  margin-bottom: 20px;
}

.form-label-pro {
  display: block;
  margin-bottom: 8px;
  font-weight: 600;
  color: #555;
  font-size: 0.95rem;
}

.form-control-pro {
  border: 1px solid var(--border-light);
  background: #fafafa;
  padding: 12px 15px;
  border-radius: 4px;
  width: 100%;
  color: var(--text-dark);
}

.form-control-pro:focus {
  border-color: var(--pro-blue);
  outline: none;
  background: var(--white);
  box-shadow: 0 0 0 3px rgba(43, 130, 201, 0.1);
}

/* Glassmorphism for Dashboard */
.glass-card-pro {
  background: rgba(255, 255, 255, 0.7) !important;
  backdrop-filter: blur(12px) saturate(180%);
  -webkit-backdrop-filter: blur(12px) saturate(180%);
  border: 1px solid rgba(255, 255, 255, 0.3) !important;
  border-radius: 12px !important;
  box-shadow: 0 8px 32px 0 rgba(43, 130, 201, 0.1);
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.glass-card-pro:hover {
  background: rgba(255, 255, 255, 0.85) !important;
  transform: translateY(-5px);
  box-shadow: 0 12px 40px 0 rgba(43, 130, 201, 0.2);
}

.pro-stat-card.glass-card-pro {
  border-right: 4px solid var(--pro-blue) !important;
  /* Blue indicator for RTL */
}

.icon-box-pro {
  width: 50px;
  height: 50px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.4rem;
  background: rgba(43, 130, 201, 0.1);
  color: var(--pro-blue);
}

/* Stat Cards */
.pro-stat-card {
  background: var(--white);
  border-radius: 8px;
  padding: 20px;
  border-top: 4px solid var(--pro-blue);
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.04);
  transition: transform 0.2s;
}

.pro-stat-card:hover {
  transform: translateY(-3px);
}

/* Responsive Adjustments */
@media (max-width: 991.98px) {
  .sidebar-pro {
    right: -260px;
    top: 60px;
    height: calc(100vh - 60px);
    transition: right 0.3s;
  }

  .sidebar-pro.show {
    right: 0;
  }

  .navbar-pro,
  .main-container,
  .footer {
    margin-right: 0 !important;
  }

  .mobile-nav-toggle {
    display: block;
  }

  .login-split {
    flex-direction: column-reverse;
    /* Logo on top for small screens */
  }

  .login-left,
  .login-right {
    width: 100% !important;
    padding: 30px !important;
  }

  .login-logo {
    max-width: 200px;
    margin: 0 auto;
  }

  .pro-card {
    margin: 10px;
  }
}

@media (max-width: 575.98px) {
  .main-container {
    padding: 20px 10px;
  }

  .navbar-brand span {
    display: none;
    /* Hide 'Pro Sys' text on tiny screens */
  }
}

/* Rebranding: Pro Sys Corporate Style */
.pro-card {