/* ============================================
   Custom Styles for Nito
   ============================================ */

/* Pagination Loader */
.pagination-loader {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(0, 0, 0, 0.7);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 99999;
  backdrop-filter: blur(2px);
}

.pagination-loader-content {
  background: var(--bs-body-bg, #fff);
  padding: 2rem;
  border-radius: 0.5rem;
  box-shadow: 0 0.5rem 1rem rgba(0, 0, 0, 0.15);
  text-align: center;
}

.pagination-loader-spinner {
  width: 3rem;
  height: 3rem;
  border: 4px solid var(--bs-border-color, #dee2e6);
  border-top-color: var(--bs-primary, #0d6efd);
  border-radius: 50%;
  animation: spin 1s linear infinite;
  margin: 0 auto 1rem;
}

@keyframes spin {
  to { transform: rotate(360deg); }
}

.pagination-loader-text {
  color: var(--bs-body-color, #212529);
  font-size: 1rem;
  margin: 0;
}

[data-theme="dark"] .pagination-loader-content {
  background: #1a1a1a;
  color: #fff;
}

[data-theme="dark"] .pagination-loader-text {
  color: #fff;
}

/* Catalog grid images - fixed height with cover */
#properties-grid .catalog-image-wrapper {
  height: 200px !important;
  overflow: hidden !important;
  position: relative;
  margin: 0 !important;
  padding: 0 !important;
  display: block !important;
  line-height: 0;
  border-radius: 10px 10px 0px 0px;
}

#properties-grid .catalog-grid-image {
  width: 100% !important;
  height: 200px !important;
  min-height: 200px !important;
  max-height: 200px !important;
  object-fit: cover !important;
  object-position: center;
  display: block !important;
  margin: 0 !important;
  padding: 0 !important;
  line-height: 0;
  border-radius: 10px 10px 0px 0px;
}

/* Remove any default spacing from card-img-top */
#properties-grid .card-img-top {
  margin: 0 !important;
  padding: 0 !important;
  border-radius: 10px 10px 0px 0px;
  height: 200px !important;
  min-height: 200px !important;
  max-height: 200px !important;
  line-height: 0;
}

#properties-grid .card-img-hover {
  margin: 0 !important;
  padding: 0 !important;
  height: 200px !important;
  min-height: 200px !important;
  max-height: 200px !important;
  line-height: 0;
}

/* Ensure no gap between image and card body */
#properties-grid .card .catalog-image-wrapper + .card-body {
  margin-top: 0 !important;
  padding-top: 1rem;
}

/* Dark theme card body text color */
[data-theme="dark"] .card-body p,
[data-theme="dark"] .card-body div,
[data-theme="dark"] .card-body span {
  color: #dddddd;
}

/* Category tabs in sidebar - dark mode */
[data-theme="dark"] .nav-tabs .nav-link.filter-category {
  background-color: transparent !important;
  border-color: transparent;
  color: rgba(255, 255, 255, 0.6);
}

[data-theme="dark"] .nav-tabs .nav-link.filter-category.active {
  background-color: rgba(255, 255, 255, 0.1) !important;
  border-color: rgba(255, 255, 255, 0.2);
  color: #ffffff;
}

/* Dashboard dark mode styles */
[data-theme="dark"] .card-nav-link {
  color: #ffffff !important;
  border-top-color: rgba(255, 255, 255, 0.1) !important;
}

[data-theme="dark"] .card-nav-link:hover {
  color: #ffffff !important;
  opacity: 0.8;
}

[data-theme="dark"] .card-nav-link.active {
  color: #ffffff !important;
}

[data-theme="dark"] .card-nav-link:first-child {
  border-top: none !important;
}

/* Dark mode styles for tables */
[data-theme="dark"] .table {
  color: #ffffff !important;
}

/* Sticky Filters Sidebar on Desktop */
@media (min-width: 992px) {
  /* Ensure row container allows sticky positioning */
  .container-fluid .row.g-0 {
    align-items: flex-start;
  }
  
  /* Filters sidebar sticky positioning */
  aside.col-lg-4.col-xl-3 {
    position: sticky;
    top: 20px;
    align-self: flex-start;
    max-height: calc(100vh - 40px);
    overflow-y: auto;
    overflow-x: hidden;
    z-index: 10;
  }
  
  /* Smooth scroll for sidebar */
  aside.col-lg-4.col-xl-3 {
    scrollbar-width: thin;
    scrollbar-color: rgba(0, 0, 0, 0.2) transparent;
  }
  
  aside.col-lg-4.col-xl-3::-webkit-scrollbar {
    width: 6px;
  }
  
  aside.col-lg-4.col-xl-3::-webkit-scrollbar-track {
    background: transparent;
  }
  
  aside.col-lg-4.col-xl-3::-webkit-scrollbar-thumb {
    background-color: rgba(0, 0, 0, 0.2);
    border-radius: 3px;
  }
  
  aside.col-lg-4.col-xl-3::-webkit-scrollbar-thumb:hover {
    background-color: rgba(0, 0, 0, 0.3);
  }
}

/* Dark mode scrollbar for sidebar */
[data-theme="dark"] aside.col-lg-4.col-xl-3::-webkit-scrollbar-thumb {
  background-color: rgba(255, 255, 255, 0.2);
}

[data-theme="dark"] aside.col-lg-4.col-xl-3::-webkit-scrollbar-thumb:hover {
  background-color: rgba(255, 255, 255, 0.3);
}

/* Override the default table th color in dark mode */
[data-theme="dark"] .table:not(.table-dark) thead:not(.thead-dark) th,
[data-theme="dark"] .table:not(.table-dark) tbody th {
  color: #ffffff !important;
}

[data-theme="dark"] .table thead th {
  color: #ffffff !important;
  border-color: rgba(255, 255, 255, 0.2) !important;
}

[data-theme="dark"] .table th {
  color: #ffffff !important;
}

[data-theme="dark"] .table td {
  color: #ffffff !important;
  border-color: rgba(255, 255, 255, 0.1) !important;
}

[data-theme="dark"] .table-hover tbody tr:hover {
  color: #ffffff !important;
  background-color: rgba(255, 255, 255, 0.05) !important;
}

[data-theme="dark"] .table-hover tbody tr:hover td {
  color: #ffffff !important;
}

/* Dark mode styles for form labels */
[data-theme="dark"] .form-label {
  color: #ffffff !important;
}

/* Dark mode styles for card borders */
[data-theme="dark"] .card.border {
  border-color: #3a3a3a !important;
}

/* Statistics empty message - dark mode */
[data-theme="dark"] .statistics-empty-message {
  color: #0085BD !important;
}

/* Statistics properties title - dark mode */
[data-theme="dark"] .statistics-properties-title {
  color: #0085BD !important;
}

/* Bulk approve button - dark mode */
[data-theme="dark"] #bulk-approve-btn.btn-success {
  background-color: #198754 !important;
  border-color: #198754 !important;
  color: #ffffff !important;
}

[data-theme="dark"] #bulk-approve-btn.btn-success:hover:not(:disabled) {
  background-color: #157347 !important;
  border-color: #146c43 !important;
  color: #ffffff !important;
}

[data-theme="dark"] #bulk-approve-btn.btn-success:disabled {
  background-color: rgba(25, 135, 84, 0.3) !important;
  border-color: rgba(25, 135, 84, 0.3) !important;
  color: rgba(255, 255, 255, 0.5) !important;
  opacity: 1 !important;
}

[data-theme="dark"] #bulk-approve-btn.btn-secondary:disabled {
  background-color: rgba(108, 117, 125, 0.3) !important;
  border-color: rgba(108, 117, 125, 0.3) !important;
  color: rgba(255, 255, 255, 0.5) !important;
  opacity: 1 !important;
}

[data-theme="dark"] #selected-count.badge {
  background-color: rgba(255, 255, 255, 0.2) !important;
  color: #ffffff !important;
}

/* Back to top button - dark mode */
[data-theme="dark"] .btn-scroll-top {
  background-color: rgba(255, 255, 255, 0.15) !important;
  color: #ffffff !important;
  border: 1px solid rgba(255, 255, 255, 0.2) !important;
  box-shadow: 0 0.25rem 0.75rem -0.375rem rgba(0, 0, 0, 0.3), 0 0.5rem 1rem rgba(0, 0, 0, 0.2) !important;
}

[data-theme="dark"] .btn-scroll-top:hover {
  background-color: rgba(255, 255, 255, 0.25) !important;
  color: #ffffff !important;
  border-color: rgba(255, 255, 255, 0.3) !important;
}

[data-theme="dark"] .btn-scroll-top .btn-scroll-top-tooltip {
  color: #ffffff !important;
  background-color: rgba(0, 0, 0, 0.8) !important;
  padding: 0.25rem 0.5rem !important;
  border-radius: 0.25rem !important;
}

/* Alert styles - dark mode */
[data-theme="dark"] .alert-info {
  background-color: rgba(13, 110, 253, 0.15) !important;
  border-color: rgba(13, 110, 253, 0.3) !important;
  color: #ffffff !important;
}

[data-theme="dark"] .alert-info h6 {
  color: #ffffff !important;
}

[data-theme="dark"] .alert-info p {
  color: #ffffff !important;
}

[data-theme="dark"] .alert-info strong {
  color: #ffffff !important;
}

[data-theme="dark"] .alert-info * {
  color: #ffffff !important;
}

[data-theme="dark"] .alert-warning {
  background-color: rgba(255, 193, 7, 0.15) !important;
  border-color: rgba(255, 193, 7, 0.3) !important;
  color: #ffe69c !important;
}

[data-theme="dark"] .alert-warning i {
  color: #ffc107 !important;
}

/* Header Search Box Styles */
#header-search-form {
  position: relative;
}

#header-search-form .input-group {
  position: relative;
}

#header-search-form .input-group-text {
  pointer-events: none;
  border-radius: 15px 0 0 15px;
}

#header-search-input {
  border-radius: 15px !important;
  height: 45px !important;
  font-size: 15px !important;
  padding-top: 0.6rem !important;
  padding-bottom: 0.6rem !important;
}

#header-search-input:focus {
  border-color: var(--bs-primary);
  box-shadow: none !important;
}

#header-search-form-mobile .input-group-text {
  pointer-events: none;
  border-radius: 15px 0 0 15px;
}

#header-search-input-mobile {
  border-radius: 15px !important;
}

#header-search-input-mobile:focus {
  border-color: var(--bs-primary);
  box-shadow: none !important;
}

/* Mobile Search Box Below Header */
#mobile-search-form-below-header {
  position: relative;
}

#mobile-search-form-below-header .input-group {
  position: relative;
}

#mobile-search-form-below-header .input-group-text {
  pointer-events: none;
  border-radius: 15px 0 0 15px;
}

#mobile-search-input-below-header {
  border-radius: 15px !important;
  height: 45px !important;
  font-size: 15px !important;
  padding-top: 0.6rem !important;
  padding-bottom: 0.6rem !important;
}

#mobile-search-input-below-header:focus {
  border-color: var(--bs-primary);
  box-shadow: none !important;
}

/* Dark mode for mobile search box below header */
[data-theme="dark"] .mobile-search-below-header {
  background-color: #1a1a1a !important;
  border-bottom-color: rgba(255, 255, 255, 0.1) !important;
}

/* Mobile header with search */
.mobile-header-with-search {
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

[data-theme="dark"] .mobile-header-with-search {
  background-color: #1a1a1a !important;
  border-bottom-color: rgba(255, 255, 255, 0.1) !important;
}

/* Mobile search box - stick to header */
@media (max-width: 991.98px) {
  .mobile-header-with-search {
    position: fixed !important;
    top: 0 !important;
    left: 0 !important;
    right: 0 !important;
  }
  
  /* Mobile menu bar at bottom */
  .mobile-menu-bar {
    position: fixed !important;
    bottom: 0 !important;
    left: 0 !important;
    right: 0 !important;
  }
  
  /* Let JavaScript handle padding-top for all pages */
  /* CSS padding-top removed to prevent conflicts with existing mt-5/pt-5 classes */
  
  /* For container-fluid with mt-5, ensure no extra padding */
  .container-fluid.mt-5 {
    padding-top: 0 !important;
  }
  
  /* For container-fluid with pt-5, ensure no extra padding */
  .container-fluid.pt-5 {
    padding-top: 0 !important;
  }
  
  /* For section.container with mt-5 or pt-5, ensure no extra padding */
  section.container.mt-5,
  section.container.pt-5 {
    padding-top: 0 !important;
  }
  
  /* If mobile header exists (home page), let JavaScript handle padding */
  body:has(.mobile-header-with-search) .container-fluid {
    padding-top: 0 !important; /* Let JavaScript handle it */
  }
  
  /* Dark mode for mobile menu bar */
  [data-theme="dark"] .mobile-menu-bar {
    background-color: #1a1a1a !important;
    border-top-color: rgba(255, 255, 255, 0.1) !important;
  }
  
  /* Mobile menu bar buttons - no border, custom colors */
  .mobile-menu-bar .btn {
    border: none !important;
    box-shadow: none !important;
    background: transparent !important;
  }
  
  /* Mobile menu bar icons - light theme */
  .mobile-menu-bar .btn i,
  .mobile-menu-bar .btn svg {
    color: #0076ac !important;
  }
  
  /* Mobile menu bar icons - dark theme */
  [data-theme="dark"] .mobile-menu-bar .btn i,
  [data-theme="dark"] .mobile-menu-bar .btn svg {
    color: #dddddd !important;
  }
  
  /* Mobile menu bar text labels - light theme */
  .mobile-menu-bar .btn .small {
    color: #0076ac !important;
    margin-top: 0.2rem;
  }
  
  /* Mobile menu bar text labels - dark theme */
  [data-theme="dark"] .mobile-menu-bar .btn .small {
    color: #dddddd !important;
  }
  
  /* Mobile menu bar primary button (Add Property) - light theme */
  .mobile-menu-bar .btn-primary {
    background-color: #0076ac !important;
    border-color: #0076ac !important;
  }
  
  .mobile-menu-bar .btn-primary i,
  .mobile-menu-bar .btn-primary svg {
    color: #ffffff !important;
  }
  
  .mobile-menu-bar .btn-primary .small {
    color: #ffffff !important;
  }
  
  /* Mobile menu bar primary button (Add Property) - dark theme */
  [data-theme="dark"] .mobile-menu-bar .btn-primary {
    background-color: #0076ac !important;
    border-color: #0076ac !important;
  }
  
  [data-theme="dark"] .mobile-menu-bar .btn-primary i,
  [data-theme="dark"] .mobile-menu-bar .btn-primary svg {
    color: #ffffff !important;
  }
  
  [data-theme="dark"] .mobile-menu-bar .btn-primary .small {
    color: #ffffff !important;
  }
  
  /* Mobile menu bar danger button (Logout) - light theme */
  .mobile-menu-bar .btn-outline-danger .small {
    color: #dc3545 !important;
  }
  
  /* Mobile menu bar danger button (Logout) - dark theme */
  [data-theme="dark"] .mobile-menu-bar .btn-outline-danger .small {
    color: #dddddd !important;
  }
}

/* Remove all orange shadows and hover shadows from buttons */
.btn,
.btn-primary,
.btn-secondary,
.btn-success,
.btn-danger,
.btn-warning,
.btn-info,
.btn-light,
.btn-dark,
.btn-outline-primary,
.btn-outline-secondary,
.btn-outline-success,
.btn-outline-danger,
.btn-outline-warning,
.btn-outline-info,
.btn-outline-light,
.btn-outline-dark,
.btn-link,
.btn-light-primary,
.btn-translucent-primary,
.btn-accent,
.btn-icon {
  box-shadow: none !important;
}

.btn:hover,
.btn:focus,
.btn:active,
.btn.active,
.btn.show,
.btn-primary:hover,
.btn-primary:focus,
.btn-primary:active,
.btn-primary.active,
.btn-primary.show,
.btn-secondary:hover,
.btn-secondary:focus,
.btn-secondary:active,
.btn-secondary.active,
.btn-secondary.show,
.btn-success:hover,
.btn-success:focus,
.btn-success:active,
.btn-success.active,
.btn-success.show,
.btn-danger:hover,
.btn-danger:focus,
.btn-danger:active,
.btn-danger.active,
.btn-danger.show,
.btn-warning:hover,
.btn-warning:focus,
.btn-warning:active,
.btn-warning.active,
.btn-warning.show,
.btn-info:hover,
.btn-info:focus,
.btn-info:active,
.btn-info.active,
.btn-info.show,
.btn-light:hover,
.btn-light:focus,
.btn-light:active,
.btn-light.active,
.btn-dark:hover,
.btn-dark:focus,
.btn-dark:active,
.btn-dark.active,
.btn-dark.show,
.btn-outline-primary:hover,
.btn-outline-primary:focus,
.btn-outline-primary:active,
.btn-outline-primary.active,
.btn-outline-primary.show,
.btn-outline-secondary:hover,
.btn-outline-secondary:focus,
.btn-outline-secondary:active,
.btn-outline-secondary.active,
.btn-outline-secondary.show,
.btn-outline-success:hover,
.btn-outline-success:focus,
.btn-outline-success:active,
.btn-outline-success.active,
.btn-outline-success.show,
.btn-outline-danger:hover,
.btn-outline-danger:focus,
.btn-outline-danger:active,
.btn-outline-danger.active,
.btn-outline-danger.show,
.btn-outline-warning:hover,
.btn-outline-warning:focus,
.btn-outline-warning:active,
.btn-outline-warning.active,
.btn-outline-warning.show,
.btn-outline-info:hover,
.btn-outline-info:focus,
.btn-outline-info:active,
.btn-outline-info.active,
.btn-outline-info.show,
.btn-outline-light:hover,
.btn-outline-light:focus,
.btn-outline-light:active,
.btn-outline-light.active,
.btn-outline-light.show,
.btn-outline-dark:hover,
.btn-outline-dark:focus,
.btn-outline-dark:active,
.btn-outline-dark.active,
.btn-outline-dark.show,
.btn-link:hover,
.btn-link:focus,
.btn-link:active,
.btn-link.active,
.btn-light-primary:hover,
.btn-light-primary:focus,
.btn-light-primary:active,
.btn-light-primary.active,
.btn-light-primary.shadow-sm:hover,
.btn-light-primary.shadow-sm:focus,
.btn-light-primary.shadow-sm:active,
.btn-light-primary.shadow-sm.active,
.btn-translucent-primary:hover,
.btn-translucent-primary:focus,
.btn-translucent-primary:active,
.btn-translucent-primary.active,
.btn-accent:hover,
.btn-accent:focus,
.btn-accent:active,
.btn-accent.active,
.btn-icon:hover,
.btn-icon:focus,
.btn-icon:active,
.btn-icon.active,
.btn.shadow-sm:hover,
.btn-icon.shadow-sm:hover {
  box-shadow: none !important;
}

/* Remove focus shadows from form controls */
.form-control:focus,
.form-select:focus,
.input-group-text:focus,
.form-control:focus-visible,
.form-select:focus-visible {
  box-shadow: none !important;
}

/* Remove orange shadows from focus states (buttons and form controls only) */
button:focus,
a:focus,
.btn:focus,
.form-control:focus,
.form-select:focus,
.input-group-text:focus {
  box-shadow: none !important;
}

/* Remove orange shadows from active states (buttons only) */
button:active,
a:active,
.btn:active {
  box-shadow: none !important;
}

/* Dark mode styles for header dashboard and logout buttons */
[data-theme="dark"] .btn.text-primary,
[data-theme="dark"] a.btn.text-primary {
  color: #ffffff !important;
}

[data-theme="dark"] .btn.text-primary i,
[data-theme="dark"] a.btn.text-primary i {
  color: #ffffff !important;
}

[data-theme="dark"] .btn.btn-link[title="خروج"],
[data-theme="dark"] button.btn.btn-link[title="خروج"] {
  color: #ffffff !important;
}

[data-theme="dark"] .btn.btn-link[title="خروج"] i,
[data-theme="dark"] button.btn.btn-link[title="خروج"] i {
  color: #ffffff !important;
}

/* Dashboard recent properties images - mobile responsive */
@media (max-width: 767.98px) {
  .card-horizontal .card-img-top {
    width: 100% !important;
    height: 200px !important;
    min-width: 100% !important;
    min-height: 200px !important;
    max-width: 100% !important;
    max-height: 200px !important;
  }
  
  .card-horizontal .card-img-top img {
    width: 100% !important;
    height: 100% !important;
    object-fit: cover !important;
    object-position: center !important;
  }
  
  .card-horizontal {
    flex-direction: column !important;
  }
}


/* ============================================
   Select2 Custom Styles for Nito Theme
   Match form-control and form-select styles exactly
   ============================================ */

/* Select2 Container - Match form-select */
.select2-container--bootstrap-5 {
  width: 100% !important;
}

/* Add spacing between Select2 dropdowns when they are siblings */
.select2-container--bootstrap-5 + .select2-container--bootstrap-5 {
  margin-top: 0.5rem;
}

/* Add spacing for Select2 inside div containers with mt-2 class */
.mt-2 .select2-container--bootstrap-5 {
  margin-top: 0.5rem;
}

/* Ensure spacing between city and district selects */
#filter-city.select2-hidden-accessible ~ div .select2-container--bootstrap-5 {
  margin-top: 0.5rem;
}

/* Selection - Match form-control/form-select exactly */
.select2-container--bootstrap-5 .select2-selection {
  display: block;
  width: 100%;
  padding: 0.575rem 1.125rem;
  font-weight: 400;
  line-height: 1.5;
  color: #454056;
  background-color: #fff;
  background-clip: padding-box;
  border: 1px solid #d5d2dc;
  border-radius: 0.5rem;
  box-shadow: inset 0 1px 2px rgba(0, 0, 0, 0);
  transition: background-color 0.15s ease-in-out, border-color 0.15s ease-in-out, box-shadow 0.15s ease-in-out;
  min-height: calc(1.5em + 1.15rem + 2px);
}

.select2-container--bootstrap-5 .select2-selection:hover {
  border-color: #d5d2dc;
}

.select2-container--bootstrap-5.select2-container--focus .select2-selection,
.select2-container--bootstrap-5.select2-container--open .select2-selection {
  color: #454056;
  background-color: #fff;
  border-color: #766df4;
  outline: 0;
  box-shadow: 0 0 0 0.2rem rgba(118, 109, 244, 0.25);
}

/* Selection Rendered - Match form-control padding and line-height */
.select2-container--bootstrap-5 .select2-selection--single .select2-selection__rendered {
  color: #454056;
  line-height: 1.5;
  padding-right: 1.125rem;
  padding-left: 2.5rem; /* فاصله بیشتر برای فلش در سمت چپ */
  text-align: right;
  display: block;
  width: 100%;
}

.select2-container--bootstrap-5 .select2-selection--single .select2-selection__arrow {
  height: calc(1.5em + 1.15rem + 2px);
  left: 1.125rem; /* فلش در سمت چپ */
  right: auto;
  top: 0;
  width: 20px;
}

.select2-container--bootstrap-5 .select2-selection--single .select2-selection__arrow b {
  border-color: #454056 transparent transparent transparent;
  border-width: 5px 4px 0 4px;
  margin-top: -2px;
  margin-right: 0;
}

/* Clear Button */
.select2-container--bootstrap-5 .select2-selection__clear {
  color: #454056;
  opacity: 0.6;
  margin-right: 0.5rem;
  margin-left: 0;
  cursor: pointer;
  float: right;
  font-size: 1.2em;
  line-height: 1;
  position: relative;
  z-index: 1;
}

.select2-container--bootstrap-5 .select2-selection__clear:hover {
  opacity: 1;
  color: #dc3545;
}

/* Dropdown - Match Bootstrap dropdown style */
.select2-dropdown {
  background-color: #fff;
  border: 1px solid #d5d2dc;
  border-radius: 0.5rem;
  box-shadow: 0 0.5rem 1rem rgba(0, 0, 0, 0.15);
  margin-top: 4px;
  z-index: 9999;
}

/* Search Field - Match form-control */
.select2-search--dropdown .select2-search__field {
  display: block;
  width: calc(100% - 8px);
  padding: 0.575rem 1.125rem;
  font-weight: 400;
  line-height: 1.5;
  color: #454056;
  background-color: #fff;
  background-clip: padding-box;
  border: 1px solid #d5d2dc;
  border-radius: 0.5rem;
  margin: 4px;
  text-align: right;
  box-shadow: inset 0 1px 2px rgba(0, 0, 0, 0);
  transition: background-color 0.15s ease-in-out, border-color 0.15s ease-in-out, box-shadow 0.15s ease-in-out;
}

.select2-search--dropdown .select2-search__field:focus {
  color: #454056;
  background-color: #fff;
  border-color: #766df4;
  outline: 0;
  box-shadow: 0 0 0 0.2rem rgba(118, 109, 244, 0.25);
}

/* Results */
.select2-results__option {
  color: #454056;
  padding: 0.575rem 1.125rem;
  text-align: right;
  cursor: pointer;
  line-height: 1.5;
}

.select2-results__option--highlighted,
.select2-results__option[aria-selected="true"] {
  background-color: #766df4;
  color: #fff;
}

.select2-results__option[aria-selected="false"]:hover {
  background-color: rgba(118, 109, 244, 0.1);
  color: #454056;
}

/* Loading */
.select2-results__option--loading {
  color: #454056;
  text-align: center;
  padding: 0.575rem 1.125rem;
}

/* No Results */
.select2-results__option--empty {
  color: #9691a4;
  text-align: center;
  padding: 0.575rem 1.125rem;
}

/* RTL Support */
.select2-container--bootstrap-5 {
  direction: rtl;
}

/* Dark Mode - Match dark-mode.css styles */
[data-theme="dark"] .select2-container--bootstrap-5 .select2-selection {
  background-color: #2d2d2d;
  border-color: #3a3a3a;
  color: #e8e8e8;
}

[data-theme="dark"] .select2-container--bootstrap-5 .select2-selection--single .select2-selection__rendered {
  color: #e8e8e8;
}

[data-theme="dark"] .select2-container--bootstrap-5 .select2-selection--single .select2-selection__arrow b {
  border-color: #e8e8e8 transparent transparent transparent;
}

[data-theme="dark"] .select2-container--bootstrap-5.select2-container--focus .select2-selection,
[data-theme="dark"] .select2-container--bootstrap-5.select2-container--open .select2-selection {
  background-color: #2d2d2d;
  border-color: #0085BD;
  color: #ffffff;
  box-shadow: 0 0 0 0.2rem rgba(0, 133, 189, 0.25);
}

[data-theme="dark"] .select2-container--bootstrap-5 .select2-selection__clear {
  color: #e8e8e8;
}

[data-theme="dark"] .select2-dropdown {
  background-color: #2d2d2d;
  border-color: #3a3a3a;
}

[data-theme="dark"] .select2-search--dropdown .select2-search__field {
  background-color: #2d2d2d;
  border-color: #3a3a3a;
  color: #e8e8e8;
}

[data-theme="dark"] .select2-search--dropdown .select2-search__field:focus {
  background-color: #2d2d2d;
  border-color: #0085BD;
  color: #ffffff;
  box-shadow: 0 0 0 0.2rem rgba(0, 133, 189, 0.25);
}

[data-theme="dark"] .select2-results__option {
  color: #e8e8e8;
}

[data-theme="dark"] .select2-results__option[aria-selected="false"]:hover {
  background-color: rgba(118, 109, 244, 0.2);
  color: #e8e8e8;
}

/* Responsive */
@media (max-width: 768px) {
  .select2-container--bootstrap-5 .select2-selection {
    padding: 0.425rem 1rem;
    font-size: 0.875rem;
  }
  
  .select2-container--bootstrap-5 .select2-selection--single .select2-selection__rendered {
    padding-right: 1rem;
    padding-left: 2rem; /* فاصله برای فلش در سمت چپ */
  }
  
  .select2-container--bootstrap-5 .select2-selection--single .select2-selection__arrow {
    left: 1rem; /* فلش در سمت چپ */
    right: auto;
  }
}

/* Arrow position for RTL - فلش در سمت چپ */
.select2-container--bootstrap-5 .select2-selection--single .select2-selection__arrow {
  left: 1.125rem !important;
  right: auto !important;
}
