/*
 |--------------------------------------------------------------
 | Project custom styles
 |--------------------------------------------------------------
 */

:root {
  --app-primary: #0d6efd;
  --app-bg: #f6f8fb;
  --sidebar-link: #334155;
  --bs-font-sans-serif: 'Yekan', system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  --bs-body-font-family: 'Yekan', system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
}

html, body {
  scroll-behavior: smooth;
}

body {
  font-family: 'Yekan', system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  background: var(--app-bg);
}

/* Ensure form controls inherit font */
button, input, optgroup, select, textarea {
  font-family: inherit;
}

/* Font Awesome v4/v5-style compatibility
   Allows using icons as: <i class="fa fa-xxx"></i>
   Prefer FA5 Free; fall back to FA6 Free if present locally */

 

/* Layout helpers */
.min-h-main {
  min-height: calc(100vh - 6rem);
}

/* Cards (auth and common) */
.auth-card {
  border: 1px solid rgba(0, 0, 0, 0.05);
}

.brand-avatar {
  width: 56px;
  height: 56px;
  object-fit: cover;
}

/* Consistent tiny avatar size for tables/lists */
.avatar-34 {
  width: 34px;
  height: 34px;
  object-fit: cover;
}

/* Admin shell & sidebar */
.admin-shell {
  min-height: 100vh;
}

.sidebar {
  width: 260px;
  flex: 0 0 260px; /* prevent collapsing in flex container on desktop */
}

.sidebar .nav-link {
  color: var(--sidebar-link);
  transition: padding .12s ease, background-color .12s ease, color .12s ease;
}

.sidebar .nav-link.active {
  background-color: var(--app-primary);
  color: #fff;
}

/* Increase padding for active sidebar items (blue background area) */
#adminSidebar .nav-link.active {
  padding-right: .75rem !important;
  padding-left: .75rem !important;
}
#adminSidebar .nav-link.active:hover,
#adminSidebar .nav-link.active:focus {
  padding-right: .75rem !important;
  padding-left: .75rem !important;
}

#adminSidebar .nav-link {
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
}

#adminSidebar .nav-link i {
  margin-left: 0.5rem;
  margin-right: 0;
}

#adminSidebar #settingsSubmenu .nav-link {
  justify-content: center;
}

.school-form-fields .form-label {
  display: block;
  text-align: center;
}

.school-form-fields .form-control,
.school-form-fields .form-select {
  text-align: center;
}

.school-form-fields .form-check {
  display: flex;
  justify-content: center;
}

.school-form-fields .invalid-feedback {
  text-align: center;
}

.centered-field-group label,
.centered-field-group .form-label {
  display: block;
  text-align: center;
}

.centered-field-group .form-control,
.centered-field-group .form-select {
  text-align: center;
}

.centered-field-group .form-text,
.centered-field-group .invalid-feedback {
  text-align: center;
}

.centered-field-group select option {
  text-align: center;
}

.centered-field-group .form-check {
  display: flex;
  justify-content: center;
}

.centered-field-group .phone-input {
  direction: ltr;
  text-align: center;
}

.centered-field-group .phone-input-row {
  justify-content: center;
}

.centered-field-group .payment-sms-field textarea {
  text-align: right;
}

.centered-field-group .filter-actions {
  display: flex;
  justify-content: center;
  gap: 0.5rem;
  flex-wrap: wrap;
}

/* Tenant admin panel: center all form fields */
.admin-shell main label:not(.form-check-label):not(.btn),
.admin-shell main .form-label {
  display: block;
  text-align: center;
  width: 100%;
}

.admin-shell main .form-control,
.admin-shell main .form-select,
.admin-shell main textarea,
.admin-shell main input[type="text"],
.admin-shell main input[type="email"],
.admin-shell main input[type="number"],
.admin-shell main input[type="password"],
.admin-shell main input[type="tel"],
.admin-shell main input[type="search"],
.admin-shell main input[type="url"],
.admin-shell main input[type="date"],
.admin-shell main input[type="datetime-local"],
.admin-shell main input[type="time"],
.admin-shell main select {
  text-align: center !important;
}

.admin-shell main select option {
  text-align: center;
}

.admin-shell main .form-check:not(.form-switch) {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 0.35rem;
}

.admin-shell main .form-switch {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 0.5rem;
}

.admin-shell main .input-group .form-control,
.admin-shell main .input-group .form-select {
  text-align: center !important;
}

.admin-shell main .form-text,
.admin-shell main .invalid-feedback {
  text-align: center;
}

.admin-shell main .form-floating {
  text-align: center;
}

.admin-shell main .form-floating > label {
  text-align: center;
  width: 100%;
}

.admin-shell main .form-floating > .form-control,
.admin-shell main .form-floating > .form-select {
  text-align: center !important;
}

/* Global: center all alerts and notifications */
.alert,
.fv-form-summary,
.auth-alert,
.toast,
.toast-body {
  text-align: center !important;
}

.alert ul,
.alert ol {
  text-align: center;
  list-style-position: inside;
  padding-right: 0;
  margin-bottom: 0;
}

.alert.alert-dismissible {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  align-items: center;
}

.fv-form-summary,
.auth-alert {
  justify-content: center;
  align-items: center;
}

.auth-alert {
  flex-direction: column;
}

.toast .d-flex {
  justify-content: center;
}

.toast-container {
  left: 50% !important;
  right: auto !important;
  transform: translateX(-50%);
}

/* Hover padding for sidebar links (keep base px-0 in markup; add slight space on hover) */
#adminSidebar .nav-link:hover,
#adminSidebar .nav-link:focus {
  padding-right: .5rem !important;
  padding-left: .5rem !important;
}

@media (max-width: 991.98px) {
  .sidebar {
    position: fixed;
    top: 56px; /* navbar height */
    bottom: 0;
    z-index: 1030;
    transform: translateX(100%);
    transition: transform .2s ease-in-out;
    background: #fff;
  }
  .sidebar.show {
    transform: translateX(0);
  }
}

/* Example utility overrides */
.text-primary {
  color: var(--app-primary) !important;
}

/* Action buttons: unified styling */
.action-buttons {
  display: inline-flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  align-items: center;
}

/* Admin tables center alignment */
.admin-table {
  margin: 0 auto;
  text-align: center;
}

.admin-table th,
.admin-table td {
  text-align: center;
}

.admin-table th.text-start,
.admin-table td.text-start,
.admin-table th.text-end,
.admin-table td.text-end {
  text-align: inherit;
}
.action-buttons form {
  margin: 0;
}
.action-btn {
  --bs-btn-padding-y: 0.25rem;
  --bs-btn-padding-x: 0.65rem;
  --bs-btn-font-size: 0.85rem;
  line-height: 1.2;
  border-radius: 0.375rem;
  color: #212529 !important; /* black text by default */
}
.action-btn:hover,
.action-btn:focus {
  color: #fff !important; /* force white text on hover/focus */
}

/* Breadcrumb RTL separator */
.breadcrumb-item + .breadcrumb-item::before {
  float: right;
  padding-left: 10px;
}


