@font-face {
  font-family: "Vazirmatn";
  src: url("/static/fonts/vazirmatn/vazirmatn-arabic-400-normal.woff2") format("woff2");
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: "Vazirmatn";
  src: url("/static/fonts/vazirmatn/vazirmatn-arabic-700-normal.woff2") format("woff2");
  font-weight: 700;
  font-style: normal;
  font-display: swap;
}

html,
body {
  overflow-x: hidden;
}

body {
  background: #f5f5f9;
}

.simple-dashboard .layout-navbar {
  min-height: 4.75rem;
}

.simple-dashboard .container-xxl {
  max-width: 1480px;
}

.simple-container {
  padding-top: 2rem !important;
  padding-bottom: 2.5rem !important;
}

[dir="rtl"] body,
[dir="rtl"] input,
[dir="rtl"] select,
[dir="rtl"] textarea,
[dir="rtl"] button {
  font-family: "Vazirmatn", "Public Sans", Tahoma, Arial, sans-serif;
}

input,
select,
textarea {
  min-width: 0;
}

code {
  color: #5a8dee;
}

.simple-brand-logo {
  display: inline-grid;
  place-items: center;
  width: 34px;
  height: 34px;
  border-radius: 0.6rem;
  background: linear-gradient(135deg, #5a8dee, #39da8a);
  color: #fff;
  font-weight: 800;
  box-shadow: 0 0.25rem 0.75rem rgba(90, 141, 238, 0.25);
  overflow: hidden;
}

.simple-brand-logo img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: inherit;
}

.hero-card {
  background:
    linear-gradient(135deg, rgba(90, 141, 238, 0.11), rgba(57, 218, 138, 0.08)),
    #fff;
}

.simple-card {
  border: 0;
  border-radius: 0.85rem;
  box-shadow: 0 0.25rem 1.25rem rgba(67, 89, 113, 0.09);
}

.simple-card > .card-header {
  padding: 1.5rem 1.75rem 0.75rem;
}

.simple-card > .card-body {
  padding: 1.75rem;
}

.hero-card > .card-body {
  padding: 1.85rem 2rem;
}

.hero-card .display-6 {
  color: #516377;
  letter-spacing: 0;
}

.simple-wizard-card > .card-body,
.simple-wizard-body {
  padding: 0 !important;
}

.simple-stepper.bs-stepper {
  border-radius: 0.85rem;
}

.simple-stepper.bs-stepper:not(.vertical) .bs-stepper-header {
  border-bottom: 1px solid #e9ecee;
  padding: 1.75rem 2rem 1.25rem;
  margin-bottom: 0;
  gap: 1.5rem;
  align-items: flex-start;
  overflow-x: auto;
  scrollbar-width: thin;
}

.simple-stepper .bs-stepper-content {
  padding: 2rem;
}

.simple-stepper .step {
  min-width: 13.5rem;
}

.simple-stepper .step-trigger {
  align-items: flex-start;
  gap: 0.85rem;
  padding: 0;
}

.simple-stepper .bs-stepper-circle {
  width: 2.35rem;
  height: 2.35rem;
  line-height: 2.35rem;
  flex: 0 0 2.35rem;
  font-size: 1rem;
  box-shadow: 0 0.25rem 0.75rem rgba(90, 141, 238, 0.2);
}

.simple-stepper .line {
  min-width: 3.5rem;
  margin: 1.1rem 0 0;
}

.wizard-pane {
  padding-top: 0.25rem;
  min-height: 25rem;
}

.wizard-pane .content-header {
  margin-bottom: 2rem !important;
  padding-bottom: 1rem;
  border-bottom: 1px solid #eef0f3;
}

.wizard-pane .content-header h5 {
  font-size: 1.18rem;
  font-weight: 700;
}

.wizard-actions {
  padding-top: 1.25rem;
  border-top: 1px solid #eef0f3;
}

.simple-stepper .bs-stepper-title,
.simple-stepper .bs-stepper-subtitle {
  white-space: normal;
}

.simple-stepper .content-header h5 {
  color: #516377;
}

.simple-form-grid {
  --bs-gutter-x: 1.5rem;
  --bs-gutter-y: 1.75rem;
}

.simple-form-grid .form-label,
.parameter-editor-grid .form-label {
  margin-bottom: 0.65rem;
}

.simple-form-grid .form-control,
.simple-form-grid .form-select,
.parameter-editor-grid .form-control,
.parameter-editor-grid .form-select {
  min-height: 3rem;
}

.parameter-block {
  padding: 1.35rem;
  background: #fff;
}

.parameter-block h6 {
  color: #516377;
  font-weight: 700;
}

.upload-box {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 1.25rem;
  align-items: center;
  padding: 1.5rem;
  border: 1px dashed #5a8dee;
  border-radius: 0.75rem;
  background: rgba(90, 141, 238, 0.06);
}

[dir="rtl"] .upload-box {
  grid-template-columns: auto minmax(0, 1fr);
}

.upload-box input {
  max-width: 28rem;
}

.flow-card {
  display: block;
  overflow: hidden;
  border: 1px solid #e9ecee;
  border-radius: 0.75rem;
  background: #fff;
}

.flow-card img {
  display: block;
  width: 100%;
  height: 280px;
  object-fit: contain;
  padding: 1rem;
}

.empty-state {
  display: grid;
  place-items: center;
  min-height: 16rem;
  text-align: center;
}

.empty-state .avatar.avatar-lg {
  width: 4.25rem;
  height: 4.25rem;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.empty-state .avatar.avatar-lg i {
  font-size: 2rem;
  line-height: 1;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.plot-card {
  min-width: 0;
  overflow: hidden;
  border: 1px solid #e9ecee;
  border-radius: 0.75rem;
  background: #fff;
  padding: 0.5rem;
}

.plot-card .plotly-graph-div,
.plot-card .js-plotly-plot {
  max-width: 100%;
}

.results-metrics-grid .avatar.avatar-sm {
  width: 2rem;
  height: 2rem;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 0.5rem;
}

.results-metrics-grid .avatar.avatar-sm i {
  font-size: 1.1rem;
  line-height: 1;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.help-tip {
  display: inline-grid;
  place-items: center;
  width: 18px;
  height: 18px;
  margin-inline-start: 0.25rem;
  border-radius: 999px;
  background: #e8f1ff;
  border: 1px solid #cfe0ff;
  color: #5a8dee;
  font-size: 11px;
  font-weight: 800;
  cursor: help;
  opacity: 1;
  position: static;
  vertical-align: middle;
}

.floating-tooltip {
  position: fixed;
  z-index: 9999;
  max-width: min(360px, calc(100vw - 24px));
  padding: 0.75rem 0.875rem;
  border: 1px solid rgba(81, 99, 119, 0.12);
  border-radius: 0.75rem;
  background: #fff;
  color: #516377;
  box-shadow: 0 0.75rem 2rem rgba(81, 99, 119, 0.18);
  font-size: 0.8125rem;
  line-height: 1.7;
  pointer-events: none;
}

.table-responsive,
.coefficient-table {
  max-width: 100%;
}

.coefficient-table td,
.coefficient-table th {
  white-space: nowrap;
}

.coefficient-table td:last-child {
  min-width: 28rem;
  white-space: normal;
}

.datatable-shell {
  display: grid;
  gap: 1.25rem;
}

.datatable-toolbar,
.datatable-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
}

.datatable-toolbar {
  padding: 1rem;
  border: 1px solid #e9ecee;
  border-radius: 0.75rem;
  background: #fafbfc;
}

.datatable-search,
.datatable-length {
  display: grid;
  gap: 0.45rem;
  margin: 0;
  color: #516377;
  font-size: 0.85rem;
  font-weight: 600;
}

.datatable-search {
  flex: 1 1 24rem;
}

.datatable-length {
  flex: 0 0 10rem;
}

.datatable-footer {
  padding-top: 0.25rem;
}

.datatable-info {
  color: #677788;
  font-size: 0.875rem;
}

.datatable-pagination {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 0.35rem;
}

.datatable-pagination .btn {
  min-width: 2.25rem;
}

.datatable-empty-row td {
  padding: 2rem !important;
  color: #a8b1bb;
  text-align: center;
}

.sticky-guide {
  position: sticky;
  top: 6rem;
}

.guide-section-card > .card-header {
  padding-bottom: 0.5rem;
}

.guide-section-card > .card-body {
  padding-top: 1rem;
}

.table {
  margin-bottom: 0;
}

.form-label {
  color: #516377;
  font-weight: 600;
}

.form-text {
  color: #a8b1bb;
}

@media (max-width: 991.98px) {
  .sticky-guide {
    position: static;
  }

  .upload-box,
  [dir="rtl"] .upload-box {
    grid-template-columns: 1fr;
  }

  .flow-card img {
    height: 220px;
  }

  .simple-container {
    padding-top: 1.25rem !important;
  }

  .simple-stepper.bs-stepper:not(.vertical) .bs-stepper-header,
  .simple-stepper .bs-stepper-content {
    padding: 1.25rem;
  }

  .datatable-toolbar,
  .datatable-footer {
    align-items: stretch;
    flex-direction: column;
  }

  .datatable-length,
  .datatable-search {
    flex: 1 1 auto;
    width: 100%;
  }

  .datatable-pagination {
    justify-content: center;
  }
}

/* Compact UI pass */
.simple-dashboard .layout-navbar {
  min-height: 4.15rem;
}

.simple-container {
  padding-top: 1.25rem !important;
  padding-bottom: 1.75rem !important;
}

.simple-card {
  border-radius: 0.75rem;
  box-shadow: 0 0.2rem 1rem rgba(67, 89, 113, 0.08);
}

.simple-card > .card-header {
  padding: 1.1rem 1.25rem 0.5rem;
}

.simple-card > .card-body {
  padding: 1.25rem;
}

.hero-card > .card-body {
  padding: 1.25rem 1.4rem;
}

.hero-card .display-6 {
  font-size: 1.85rem;
}

.simple-stepper.bs-stepper:not(.vertical) .bs-stepper-header {
  display: flex;
  flex-wrap: nowrap;
  gap: 0.4rem;
  overflow-x: hidden;
  padding: 1.05rem 1.25rem 0.8rem;
}

.simple-stepper .bs-stepper-content {
  padding: 1.2rem 1.35rem 1.35rem;
}

.simple-stepper .step {
  flex: 1 1 0;
  min-width: 0;
}

.simple-stepper .step-trigger {
  width: 100%;
  gap: 0.6rem;
}

.simple-stepper .bs-stepper-label {
  min-width: 0;
}

.simple-stepper .bs-stepper-title {
  font-size: 0.95rem;
}

.simple-stepper .bs-stepper-subtitle {
  display: -webkit-box;
  overflow: hidden;
  color: #9aa7b4;
  font-size: 0.78rem;
  line-height: 1.5;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
}

.simple-stepper .bs-stepper-circle {
  width: 2rem;
  height: 2rem;
  line-height: 2rem;
  flex: 0 0 2rem;
  font-size: 0.92rem;
}

.simple-stepper .line {
  flex: 0 1 1.5rem;
  min-width: 0.75rem;
  max-width: 1.5rem;
  margin-top: 0.95rem;
}

.wizard-pane {
  min-height: auto;
  padding-top: 0;
}

.wizard-pane .content-header {
  margin-bottom: 1.1rem !important;
  padding-bottom: 0.75rem;
}

.wizard-pane .content-header h5 {
  font-size: 1.05rem;
}

.wizard-actions {
  margin-top: 1.25rem !important;
  padding-top: 0.9rem;
}

.simple-form-grid {
  --bs-gutter-x: 1.05rem;
  --bs-gutter-y: 1.15rem;
}

.simple-form-grid .form-label,
.parameter-editor-grid .form-label {
  margin-bottom: 0.4rem;
}

.simple-form-grid .form-control,
.simple-form-grid .form-select,
.parameter-editor-grid .form-control,
.parameter-editor-grid .form-select {
  min-height: 2.6rem;
}

.parameter-block {
  padding: 1rem;
}

.upload-box {
  gap: 1rem;
  padding: 1rem 1.15rem;
}

.empty-state {
  min-height: 12rem;
}

.results-metrics-grid > .col > .card {
  min-height: 8.25rem;
}

.datatable-toolbar {
  padding: 0.85rem;
}

@media (max-width: 1199.98px) {
  .simple-stepper.bs-stepper:not(.vertical) .bs-stepper-header {
    overflow-x: auto;
  }

  .simple-stepper .step {
    flex-basis: 11rem;
  }
}

@media (max-width: 991.98px) {
  .simple-card > .card-body,
  .hero-card > .card-body,
  .simple-stepper .bs-stepper-content {
    padding: 1rem;
  }

  .simple-stepper.bs-stepper:not(.vertical) .bs-stepper-header {
    padding: 1rem;
  }
}
