html {
  font-size: 14px;
}

:root {
  color-scheme: light;
  --s2-theme-accent: #2563eb;
  --s2-theme-accent-strong: #1d4ed8;
  --s2-theme-accent-soft: color-mix(in srgb, var(--s2-theme-accent) 12%, var(--bs-body-bg));
  --s2-theme-accent-border: color-mix(in srgb, var(--s2-theme-accent) 28%, var(--bs-border-color));
}

body {
  background-color: #ffffff;
  color: #212529;
}

@media (min-width: 768px) {
  html {
    font-size: 16px;
  }
}

.btn:focus, .btn:active:focus, .btn-link.nav-link:focus, .form-control:focus, .form-check-input:focus {
  box-shadow: 0 0 0 0.1rem white, 0 0 0 0.25rem #258cfb;
}

html {
  position: relative;
  min-height: 100%;
}

body {
  margin-bottom: 60px;
}

.app-brand {
  display: inline-flex;
  align-items: center;
  gap: .7rem;
  text-decoration: none;
}

.app-brand-logo {
  width: 42px;
  height: 42px;
  object-fit: contain;
  filter: drop-shadow(0 .25rem .45rem rgba(0, 0, 0, .18));
}

.app-brand-text {
  display: inline-flex;
  flex-direction: column;
  line-height: 1.05;
}

.app-brand-title {
  font-size: 1rem;
  font-weight: 700;
  letter-spacing: .18rem;
}

.app-brand-subtitle {
  font-size: .7rem;
  opacity: .88;
}

.app-version-strip {
  display: inline-flex;
  align-items: center;
  gap: .35rem;
  flex-wrap: wrap;
}

.page-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  margin-bottom: 1rem;
}

.s2-client-page {
  display: grid;
  gap: 1rem;
}

.s2-client-page > .page-header {
  background: linear-gradient(135deg, var(--s2-theme-accent) 0%, var(--s2-theme-accent-strong) 100%);
  border-radius: 1.1rem;
  color: #fff;
  box-shadow: 0 .7rem 1.5rem color-mix(in srgb, var(--s2-theme-accent) 25%, transparent);
  margin-bottom: 0;
  padding: 1.1rem 1.25rem;
}

.s2-client-page > .page-header .btn-outline-secondary,
.s2-client-page > .page-header .btn-outline-light {
  border-color: rgba(255, 255, 255, .6);
  color: #fff;
}

.s2-client-page > .page-header .btn-outline-secondary:hover,
.s2-client-page > .page-header .btn-outline-light:hover {
  background: #fff;
  color: var(--s2-theme-accent-strong);
}

.s2-page-title {
  align-items: center;
  background: linear-gradient(135deg, var(--s2-theme-accent) 0%, var(--s2-theme-accent-strong) 100%);
  border-radius: 1.1rem;
  box-shadow: 0 .7rem 1.5rem color-mix(in srgb, var(--s2-theme-accent) 25%, transparent);
  color: #fff;
  display: flex;
  font-size: clamp(1.25rem, 2vw, 1.55rem);
  margin: 0;
  min-height: 4.7rem;
  padding: 1rem 1.25rem;
}

.s2-surface-form,
.s2-client-page > .rtl-wrap {
  background: var(--bs-body-bg);
  border: 1px solid var(--s2-theme-accent-border);
  border-radius: 1rem;
  box-shadow: 0 .5rem 1.25rem rgba(33, 37, 41, .07);
  padding: 1.2rem;
}

.s2-client-page > .rtl-wrap {
  display: grid;
  gap: 1rem;
}

.s2-surface-form > .mb-3 + .row,
.s2-surface-form > .row + .mb-3 {
  margin-top: .25rem;
}

.s2-surface-form .form-label,
.s2-filter-surface .form-label {
  color: var(--bs-secondary-color);
  font-size: .84rem;
  font-weight: 650;
  margin-bottom: .35rem;
}

.s2-surface-form .form-text {
  font-size: .8rem;
  line-height: 1.5;
}

.s2-surface-form > .btn,
.s2-surface-form > a.btn {
  margin-top: .75rem;
}

.s2-filter-surface,
.data-list-filter-panel {
  background: var(--s2-theme-accent-soft);
  border: 1px solid var(--s2-theme-accent-border);
  border-radius: .9rem;
  padding: 1rem;
}

.s2-table-surface,
.table-container {
  border: 1px solid var(--s2-theme-accent-border);
}

.s2-table-shell {
  border: 1px solid var(--bs-border-color);
  border-radius: .9rem;
  overflow: auto;
}

.s2-table-shell .table {
  margin-bottom: 0;
}

.s2-table-shell .table thead th {
  background: var(--s2-theme-accent-soft);
  border-bottom-color: var(--s2-theme-accent-border);
  color: var(--bs-emphasis-color);
  white-space: nowrap;
}

.s2-client-page .card:not(.currency-composition-card):not(.viewer-balance-card):not(.viewer-content-card) {
  border: 1px solid var(--s2-theme-accent-border);
}

.s2-client-page .alert {
  border-radius: .8rem;
}

.card {
  border: none;
  border-radius: 0.75rem;
  box-shadow: 0 0.5rem 1rem rgba(0,0,0,0.08);
}

.card-header {
  background: linear-gradient(135deg, var(--s2-theme-accent) 0%, var(--s2-theme-accent-strong) 100%);
  color: #fff;
  border-top-left-radius: 0.75rem;
  border-top-right-radius: 0.75rem;
}

.navbar.bg-primary {
  background: linear-gradient(115deg, var(--s2-theme-accent) 0%, var(--s2-theme-accent-strong) 100%) !important;
}

.theme-section-header {
  background: linear-gradient(135deg, var(--s2-theme-accent) 0%, var(--s2-theme-accent-strong) 100%) !important;
  color: #fff !important;
}

.table-container {
  background: #fff;
  border-radius: 0.75rem;
  box-shadow: 0 0.5rem 1rem rgba(0,0,0,0.06);
  padding: 1rem;
}

.table {
  margin-bottom: 0;
}

.table thead th {
  background-color: var(--s2-theme-accent-soft);
  border-color: var(--s2-theme-accent-border);
}

.currency-page-actions,
.currency-list-summary,
.currency-display-selector,
.currency-composition-content {
  display: flex;
  align-items: center;
  gap: .75rem;
}

.currency-list-summary {
  justify-content: space-between;
  flex-wrap: wrap;
  margin-bottom: 1rem;
}

.currency-display-selector {
  flex-wrap: wrap;
}

.currency-display-selector .form-select {
  width: auto;
  max-width: min(100%, 22rem);
}

.currency-composition-card {
  margin-top: 1rem;
}

.currency-form-hero {
  background: linear-gradient(135deg, var(--s2-theme-accent) 0%, var(--s2-theme-accent-strong) 100%);
  border-radius: 1.25rem;
  color: #fff;
  padding: 1.5rem;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 1rem;
  box-shadow: 0 .75rem 1.75rem color-mix(in srgb, var(--s2-theme-accent) 28%, transparent);
}

.currency-form-kicker {
  font-size: .84rem;
  opacity: .88;
  margin-bottom: .35rem;
}

.currency-form-subtitle {
  color: rgba(255, 255, 255, .8);
  font-size: .92rem;
}

.currency-form-badge {
  display: inline-flex;
  align-items: center;
  gap: .4rem;
  border: 1px solid rgba(255, 255, 255, .28);
  background: rgba(255, 255, 255, .12);
  border-radius: 999px;
  padding: .4rem .7rem;
  font-size: .82rem;
  white-space: nowrap;
}

.currency-form-card,
.currency-list-card {
  background: var(--bs-body-bg);
  border: 1px solid var(--s2-theme-accent-border);
  border-radius: 1.1rem;
  padding: 1.25rem;
  box-shadow: 0 .55rem 1.35rem rgba(33, 37, 41, .07);
}

.currency-form-section + .currency-form-section {
  border-top: 1px solid var(--bs-border-color);
  margin-top: 1.5rem;
  padding-top: 1.5rem;
}

.currency-form-section-title {
  display: flex;
  align-items: flex-start;
  gap: .7rem;
  margin-bottom: 1rem;
}

.currency-form-section-title > i {
  display: grid;
  place-items: center;
  width: 2.25rem;
  height: 2.25rem;
  flex: 0 0 2.25rem;
  color: var(--s2-theme-accent-strong);
  background: var(--s2-theme-accent-soft);
  border-radius: .7rem;
}

.currency-form-section-title h5 {
  margin: .08rem 0 .15rem;
}

.currency-form-section-title p {
  color: var(--bs-secondary-color);
  font-size: .86rem;
  margin: 0;
}

.currency-form-card .form-text {
  font-size: .8rem;
  line-height: 1.5;
}

.currency-form-actions {
  display: flex;
  flex-wrap: wrap;
  gap: .65rem;
  border-top: 1px solid var(--bs-border-color);
  margin-top: 1.5rem;
  padding-top: 1.25rem;
}

.customer-form-hero {
  background: linear-gradient(135deg, var(--s2-theme-accent) 0%, var(--s2-theme-accent-strong) 100%);
  border-radius: 1.25rem;
  color: #fff;
  padding: 1.5rem;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 1rem;
  box-shadow: 0 .75rem 1.75rem color-mix(in srgb, var(--s2-theme-accent) 28%, transparent);
}

.customer-form-kicker {
  font-size: .84rem;
  opacity: .88;
  margin-bottom: .35rem;
}

.customer-form-subtitle {
  color: rgba(255, 255, 255, .82);
  font-size: .92rem;
}

.customer-form-hero-actions,
.customer-form-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: .65rem;
}

.customer-form-badge {
  display: inline-flex;
  align-items: center;
  gap: .4rem;
  border: 1px solid rgba(255, 255, 255, .28);
  background: rgba(255, 255, 255, .12);
  border-radius: 999px;
  padding: .4rem .7rem;
  font-size: .82rem;
  white-space: nowrap;
}

.customer-profile-form {
  background: var(--bs-body-bg);
  border: 1px solid var(--s2-theme-accent-border);
  border-radius: 1.1rem;
  padding: 1.25rem;
  box-shadow: 0 .55rem 1.35rem rgba(33, 37, 41, .07);
}

.customer-form-section + .customer-form-section {
  border-top: 1px solid var(--bs-border-color);
  margin-top: 1.5rem;
  padding-top: 1.5rem;
}

.customer-form-section-title {
  display: flex;
  align-items: flex-start;
  gap: .7rem;
  margin-bottom: 1rem;
}

.customer-form-section-title > i {
  display: grid;
  place-items: center;
  width: 2.25rem;
  height: 2.25rem;
  flex: 0 0 2.25rem;
  color: var(--s2-theme-accent-strong);
  background: var(--s2-theme-accent-soft);
  border-radius: .7rem;
}

.customer-form-section-title h5 {
  margin: .08rem 0 .15rem;
}

.customer-form-section-title p {
  color: var(--bs-secondary-color);
  font-size: .86rem;
  margin: 0;
}

.customer-form-subsection {
  margin-top: 1.2rem;
  padding: 1rem;
  border: 1px dashed var(--s2-theme-accent-border);
  border-radius: .9rem;
  background: color-mix(in srgb, var(--s2-theme-accent-soft) 42%, var(--bs-body-bg));
}

.customer-form-subsection-title {
  display: flex;
  align-items: center;
  gap: .45rem;
  color: var(--s2-theme-accent-strong);
  font-size: .9rem;
  font-weight: 750;
  margin-bottom: .8rem;
}

.customer-form-subsection-title span {
  color: var(--bs-secondary-color);
  font-size: .75rem;
  font-weight: 500;
}

.customer-profile-form .contact-row,
.customer-profile-form .balance-row {
  margin-inline: 0;
  padding: .7rem;
  border: 1px solid var(--bs-border-color);
  border-radius: .8rem;
  background: var(--bs-tertiary-bg);
}

.customer-profile-form .contact-row + .contact-row,
.customer-profile-form .balance-row + .balance-row {
  margin-top: .55rem;
}

.customer-form-add-button {
  margin-top: .8rem;
}

.customer-form-note {
  display: flex;
  align-items: flex-start;
  gap: .45rem;
  margin-top: .85rem;
  color: var(--bs-secondary-color);
  font-size: .82rem;
}

.customer-form-note i {
  color: var(--s2-theme-accent-strong);
  margin-top: .1rem;
}

.customer-form-readonly-note {
  display: flex;
  align-items: flex-start;
  gap: .7rem;
  margin-top: 1.5rem;
  padding: .9rem 1rem;
  border: 1px solid color-mix(in srgb, var(--bs-warning) 38%, var(--bs-border-color));
  border-radius: .9rem;
  background: color-mix(in srgb, var(--bs-warning-bg-subtle) 70%, var(--bs-body-bg));
}

.customer-form-readonly-note > i {
  color: var(--bs-warning-text-emphasis);
  font-size: 1.1rem;
}

.customer-form-readonly-note strong,
.customer-form-readonly-note span {
  display: block;
}

.customer-form-readonly-note span {
  color: var(--bs-secondary-color);
  font-size: .83rem;
  margin-top: .15rem;
}

.customer-form-actions {
  border-top: 1px solid var(--bs-border-color);
  margin-top: 1.5rem;
  padding-top: 1.25rem;
}

html[data-bs-theme="dark"] .customer-form-subsection {
  background: color-mix(in srgb, var(--s2-theme-accent-soft) 18%, var(--bs-body-bg));
}

html[data-bs-theme="dark"] .customer-profile-form .contact-row,
html[data-bs-theme="dark"] .customer-profile-form .balance-row {
  background: var(--bs-secondary-bg);
}

@media (max-width: 767.98px) {
  #dashboard-content {
    width: 100%;
    max-width: 100%;
    overflow-x: hidden;
  }

  .customer-dashboard-hero {
    width: 100%;
    max-width: 100%;
    overflow: hidden;
  }

  .customer-dashboard-identity,
  .customer-dashboard-actions {
    width: 100%;
    max-width: 100%;
  }

  .customer-dashboard-title,
  .customer-dashboard-subtitle {
    overflow-wrap: anywhere;
  }

  .customer-dashboard-actions .btn {
    flex: 1 1 auto;
    min-width: 8rem;
  }

  .dashboard-stat-card {
    min-height: auto;
  }

  .dashboard-stat-card .card-body {
    padding: .85rem;
  }

  .dashboard-panel .card-header {
    gap: .55rem;
    flex-wrap: wrap;
  }

  .customer-balance-share-actions {
    width: 100%;
    justify-content: flex-start;
  }

  .customer-balance-share-actions .btn {
    flex: 1 1 auto;
  }

  .customer-balance-grid {
    grid-template-columns: 1fr;
  }

  .dashboard-data-table {
    min-width: 42rem;
  }

  .dashboard-mobile-table {
    min-width: 0;
    border-collapse: separate;
    border-spacing: 0 .65rem;
  }

  .dashboard-mobile-table thead {
    display: none;
  }

  .dashboard-mobile-table,
  .dashboard-mobile-table tbody,
  .dashboard-mobile-table tr,
  .dashboard-mobile-table td {
    display: block;
    width: 100%;
  }

  .dashboard-mobile-table tbody tr {
    margin: 0;
    padding: .7rem .8rem;
    border: 1px solid var(--bs-border-color);
    border-radius: .85rem;
    background: var(--bs-tertiary-bg);
    box-shadow: 0 .2rem .65rem rgba(0, 0, 0, .07);
  }

  .dashboard-mobile-table tbody td {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: .75rem;
    padding: .38rem 0;
    border: 0;
    text-align: end;
    overflow-wrap: anywhere;
  }

  #dashboard-content .dashboard-mobile-table tbody td.customer-transaction-description {
    position: relative;
    display: block !important;
    min-height: 2.2rem;
    padding-inline-end: 6rem;
    text-align: end;
    background: transparent !important;
  }

  #dashboard-content .dashboard-mobile-table tbody td.customer-transaction-description::before {
    position: absolute;
    top: .45rem;
    inset-inline-end: 0;
    width: 5.25rem;
    text-align: start;
  }

  #dashboard-content .dashboard-mobile-table .customer-transaction-description-text {
    display: block;
    max-width: none;
    overflow: visible;
    text-overflow: clip;
    white-space: normal;
    overflow-wrap: anywhere;
    word-break: break-word;
    line-height: 1.75;
  }

  #dashboard-content .dashboard-mobile-table .customer-transaction-description .text-muted {
    display: block;
    min-width: 0;
    white-space: normal;
    overflow-wrap: anywhere;
  }

  .dashboard-mobile-table tbody td::before {
    flex: 0 0 6rem;
    color: var(--bs-secondary-color);
    font-size: .76rem;
    font-weight: 700;
    text-align: start;
  }

  .dashboard-mobile-table tbody td:nth-child(1)::before { content: "ردیف"; }
  .dashboard-mobile-table tbody td:nth-child(2)::before { content: "تاریخ"; }
  .dashboard-mobile-table tbody td:nth-child(3)::before { content: "نوع"; }
  .dashboard-mobile-table tbody td:nth-child(4)::before { content: "وضعیت"; }
  .dashboard-mobile-table tbody td:nth-child(5)::before { content: "توضیحات"; }
  .dashboard-mobile-table tbody td:nth-child(6)::before { content: "ارز"; }
  .dashboard-mobile-table tbody td:nth-child(7)::before { content: "مبلغ"; }
  .dashboard-mobile-table tbody td:nth-child(8)::before { content: "مانده"; }
  .dashboard-mobile-table tbody td:nth-child(9)::before { content: "اصلاح"; }

  .dashboard-mobile-table tbody tr td:nth-child(4) > *,
  .dashboard-mobile-table tbody tr td:nth-child(9) > * {
    margin-inline-start: auto;
  }

  .dashboard-mobile-table tbody tr td:last-child {
    padding-top: .65rem;
    border-top: 1px solid color-mix(in srgb, var(--bs-border-color) 60%, transparent);
  }

  .dashboard-mobile-table tbody tr td:last-child::before {
    flex-basis: 6rem;
  }

  #req .dashboard-mobile-table tbody td:nth-child(3)::before { content: "نوع"; }
  #req .dashboard-mobile-table tbody td:nth-child(4)::before { content: "مقدار"; }
  #req .dashboard-mobile-table tbody td:nth-child(5)::before { content: "ارز"; }
  #req .dashboard-mobile-table tbody td:nth-child(6)::before { content: "وضعیت"; }
  #req .dashboard-mobile-table tbody td:nth-child(7)::before { content: "توضیحات"; }
  #req .dashboard-mobile-table tbody td:nth-child(8)::before { content: "اقدامات"; }

  .dashboard-tracking-group {
    overflow: hidden;
  }

  .dashboard-tracking-group > .card-header {
    line-height: 1.7;
    white-space: normal;
    overflow-wrap: anywhere;
  }

  .dashboard-tracking-group > .card-body {
    padding: .45rem !important;
  }

  .currency-table { margin-inline: .3rem; border-radius: 1rem !important; overflow: hidden; }
  .currency-table > .card-header { padding: .72rem .85rem; }
  .currency-table > .card-body { padding: .35rem !important; }
  .currency-table .tracking-list-table { border-collapse: separate; border-spacing: 0 .55rem; }
  .currency-table .tracking-list-table tbody tr.tracking-list-row {
    margin: 0 0 .65rem; padding: .65rem .8rem; border: 1px solid color-mix(in srgb, var(--bs-border-color) 82%, transparent);
    border-radius: .9rem; overflow: hidden; background: var(--bs-tertiary-bg); box-shadow: 0 .2rem .65rem rgba(0, 0, 0, .08);
  }
  .currency-table .tracking-list-table tbody tr.tracking-list-row td {
    gap: 1rem; min-height: 2rem; padding: .42rem .55rem; background: transparent !important; border: 0 !important;
  }
  .currency-table .tracking-list-table tbody tr.tracking-list-row td::before { flex: 0 0 4.6rem; }
  .currency-table .tracking-list-table tbody tr.tracking-list-row td:last-child {
    align-items: center; justify-content: space-between; padding-top: .7rem;
    border-top: 1px solid color-mix(in srgb, var(--bs-border-color) 55%, transparent) !important;
  }
  .currency-table .tracking-list-table tbody tr.tracking-list-row td:last-child .tracking-action-group {
    margin-inline-start: auto;
  }
  .currency-table .tracking-list-table tbody tr.tracking-list-row td:last-child .tracking-completed-actions {
    display: flex; align-items: center; gap: .45rem; margin-inline-start: auto;
  }
  .customer-balance-share-actions { flex-wrap: wrap; justify-content: flex-end; }
  .customer-balance-share-actions .btn { min-width: 2.4rem; }
  .customer-balance-share-toast {
    position: fixed; inset-inline: 1rem; bottom: 1.25rem; z-index: 2000; padding: .7rem 1rem;
    border-radius: .8rem; color: #fff; background: #17324d; text-align: center; opacity: 0;
    transform: translateY(1rem); transition: .2s ease;
  }
  .customer-balance-share-toast.show { opacity: 1; transform: translateY(0); }
  .customer-form-hero {
    align-items: flex-start;
    flex-direction: column;
    padding: 1.1rem;
  }

  .customer-form-hero-actions {
    width: 100%;
  }

  .customer-profile-form {
    padding: 1rem;
  }

  .customer-profile-form .contact-row,
  .customer-profile-form .balance-row {
    padding: .65rem;
  }
}

.wallet-dashboard-hero {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 1.35rem 1.45rem;
  color: #fff;
  border-radius: 1.25rem;
  background: linear-gradient(135deg, var(--s2-theme-accent) 0%, var(--s2-theme-accent-strong) 100%);
  box-shadow: 0 .75rem 1.75rem color-mix(in srgb, var(--s2-theme-accent) 28%, transparent);
}

.wallet-dashboard-identity {
  display: flex;
  align-items: center;
  gap: .9rem;
  min-width: 0;
}

.wallet-dashboard-avatar {
  display: grid;
  place-items: center;
  width: 3.2rem;
  height: 3.2rem;
  flex: 0 0 3.2rem;
  color: var(--s2-theme-accent-strong);
  background: #fff;
  border-radius: 1rem;
  font-size: 1.35rem;
  box-shadow: 0 .4rem 1rem rgba(0, 0, 0, .16);
}

.wallet-dashboard-kicker {
  color: rgba(255, 255, 255, .82);
  font-size: .78rem;
  font-weight: 700;
}

.wallet-dashboard-kicker span {
  margin-inline-start: .3rem;
  padding: .1rem .35rem;
  border-radius: .35rem;
  background: rgba(255, 255, 255, .16);
}

.wallet-dashboard-subtitle {
  color: rgba(255, 255, 255, .82);
  font-size: .9rem;
}

.wallet-dashboard-subtitle span {
  margin-inline: .3rem;
  opacity: .65;
}

.wallet-dashboard-actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  align-items: center;
  gap: .5rem;
}

.wallet-dashboard-actions .btn {
  border-radius: .7rem;
}

.wallet-dashboard-stat {
  position: relative;
  min-height: 8.4rem;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  padding: 1.1rem;
  border: 1px solid var(--bs-border-color);
  border-radius: 1rem;
  background: var(--bs-body-bg);
  box-shadow: 0 .4rem 1.25rem rgba(33, 37, 41, .06);
}

.wallet-dashboard-stat::after {
  content: "";
  position: absolute;
  width: 5rem;
  height: 5rem;
  inset: auto -1.35rem -1.4rem auto;
  border-radius: 50%;
  background: var(--wallet-dashboard-tint);
}

.wallet-dashboard-stat > * {
  position: relative;
  z-index: 1;
}

.wallet-dashboard-stat-balance { --wallet-dashboard-color: #0f766e; --wallet-dashboard-tint: #e6f7f4; }
.wallet-dashboard-stat-transactions { --wallet-dashboard-color: #2563eb; --wallet-dashboard-tint: #eaf1ff; }
.wallet-dashboard-stat-net { --wallet-dashboard-color: #8a4b00; --wallet-dashboard-tint: #fff4df; }

.wallet-dashboard-stat-icon {
  display: grid;
  place-items: center;
  width: 2.25rem;
  height: 2.25rem;
  margin-bottom: .65rem;
  color: var(--wallet-dashboard-color);
  background: var(--wallet-dashboard-tint);
  border-radius: .7rem;
}

.wallet-dashboard-stat-label {
  color: var(--bs-secondary-color);
  font-size: .82rem;
  font-weight: 700;
}

.wallet-dashboard-stat strong {
  margin-top: .3rem;
  color: var(--bs-emphasis-color);
  font-size: 1.35rem;
}

.wallet-dashboard-stat strong small,
.wallet-dashboard-table strong small {
  font-size: .74em;
  font-weight: 700;
}

.wallet-dashboard-stat-note {
  margin-top: .25rem;
  color: var(--bs-secondary-color);
  font-size: .76rem;
}

.wallet-dashboard-panel {
  overflow: hidden;
  border: 1px solid var(--bs-border-color);
  border-radius: 1rem;
  box-shadow: 0 .45rem 1.35rem rgba(33, 37, 41, .06);
}

.wallet-dashboard-panel .card-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: .75rem;
  padding: .9rem 1.05rem;
  color: var(--bs-emphasis-color);
  font-weight: 800;
  background: var(--s2-theme-accent-soft);
  border-bottom-color: var(--s2-theme-accent-border);
}

.wallet-dashboard-panel .card-header span i {
  margin-inline-end: .35rem;
  color: var(--s2-theme-accent-strong);
}

.wallet-dashboard-panel .card-header small {
  color: var(--bs-secondary-color);
  font-size: .76rem;
  font-weight: 600;
}

.wallet-dashboard-panel .card-body {
  padding: 1.05rem;
}

.wallet-dashboard-form-actions,
.wallet-dashboard-filter-actions {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: .65rem;
}

.wallet-dashboard-form-actions span {
  color: var(--bs-secondary-color);
  font-size: .8rem;
}

.wallet-dashboard-pagination-note {
  color: var(--bs-secondary-color);
  font-size: .8rem;
}

.wallet-dashboard-account-list {
  display: grid;
  gap: .55rem;
}

.wallet-dashboard-account-list > div {
  display: grid;
  grid-template-columns: minmax(6.5rem, .75fr) minmax(0, 1.5fr);
  gap: .65rem;
  padding-bottom: .5rem;
  border-bottom: 1px solid var(--bs-border-color-translucent);
}

.wallet-dashboard-account-list > div:last-child {
  padding-bottom: 0;
  border-bottom: 0;
}

.wallet-dashboard-account-list dt {
  color: var(--bs-secondary-color);
  font-size: .82rem;
  font-weight: 700;
}

.wallet-dashboard-account-list dd {
  margin: 0;
  overflow-wrap: anywhere;
  font-size: .9rem;
}

.wallet-dashboard-empty-info {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 9rem;
  flex-direction: column;
  gap: .6rem;
  color: var(--bs-secondary-color);
  text-align: center;
}

.wallet-dashboard-empty-info i {
  color: var(--s2-theme-accent-strong);
  font-size: 1.6rem;
}

.wallet-dashboard-table-header strong {
  font-size: .86rem;
}

.wallet-dashboard-table thead th {
  padding: .72rem .8rem;
  color: var(--bs-secondary-color);
  font-size: .8rem;
  white-space: nowrap;
  background: var(--bs-tertiary-bg);
  border-bottom-color: var(--bs-border-color);
}

.wallet-dashboard-table tbody td {
  padding: .78rem .8rem;
  vertical-align: middle;
}

.wallet-dashboard-table tbody tr:hover {
  background: var(--bs-tertiary-bg);
}

.wallet-dashboard-date {
  min-width: 10.5rem;
  color: var(--bs-secondary-color);
  font-size: .84rem;
}

.wallet-dashboard-type {
  display: inline-flex;
  align-items: center;
  gap: .35rem;
  padding: .25rem .5rem;
  border-radius: .5rem;
  font-size: .82rem;
  font-weight: 700;
}

.wallet-dashboard-type.is-deposit {
  color: #0f6b50;
  background: #e6f7f0;
}

.wallet-dashboard-type.is-withdraw {
  color: #b42318;
  background: #fff0ef;
}

.wallet-dashboard-description {
  max-width: 32rem;
  color: var(--bs-secondary-color);
}

.wallet-dashboard-stat .is-positive,
.wallet-dashboard-table .is-positive { color: #117a53; }

.wallet-dashboard-stat .is-negative,
.wallet-dashboard-table .is-negative { color: #c12c22; }

html[data-bs-theme="dark"] .wallet-dashboard-stat {
  border-color: #34485d;
  background: #202b38;
  box-shadow: 0 .4rem 1.25rem rgba(0, 0, 0, .18);
}

html[data-bs-theme="dark"] .wallet-dashboard-stat-balance { --wallet-dashboard-tint: #163f3a; }
html[data-bs-theme="dark"] .wallet-dashboard-stat-transactions { --wallet-dashboard-tint: #1e3a66; }
html[data-bs-theme="dark"] .wallet-dashboard-stat-net { --wallet-dashboard-tint: #4d3a18; }

html[data-bs-theme="dark"] .wallet-dashboard-panel {
  border-color: #34485d;
  background: #202b38;
  box-shadow: 0 .45rem 1.35rem rgba(0, 0, 0, .18);
}

html[data-bs-theme="dark"] .wallet-dashboard-panel .card-header {
  background: #263646;
  border-bottom-color: #34485d;
}

html[data-bs-theme="dark"] .wallet-dashboard-table thead th,
html[data-bs-theme="dark"] .wallet-dashboard-table tbody tr:hover {
  background: #263646;
}

html[data-bs-theme="dark"] .wallet-dashboard-type.is-deposit {
  color: #90d9bf;
  background: #153d33;
}

html[data-bs-theme="dark"] .wallet-dashboard-type.is-withdraw {
  color: #ffb7b0;
  background: #532725;
}

@media (max-width: 767.98px) {
  .wallet-dashboard-hero {
    align-items: flex-start;
    flex-direction: column;
    padding: 1.1rem;
  }

  .wallet-dashboard-actions {
    justify-content: flex-start;
  }

  .wallet-dashboard-panel .card-header {
    align-items: flex-start;
    flex-direction: column;
  }

  .wallet-dashboard-panel .card-body {
    padding: .85rem;
  }

  .wallet-dashboard-account-list > div {
    grid-template-columns: 1fr;
    gap: .1rem;
  }
}

.currency-list-card {
  padding: 1rem;
}

.currency-market-total {
  display: inline-flex;
  align-items: baseline;
  gap: .45rem;
  background: var(--s2-theme-accent-soft);
  border: 1px solid var(--s2-theme-accent-border);
  border-radius: .75rem;
  padding: .5rem .75rem;
}

.currency-market-total strong {
  color: var(--s2-theme-accent-strong);
}

.currency-table-shell {
  border: 1px solid var(--bs-border-color);
  border-radius: .9rem;
  overflow: hidden;
}

.currency-table-shell thead th {
  background: var(--s2-theme-accent-soft);
  border-bottom-color: var(--s2-theme-accent-border);
  white-space: nowrap;
}

.currency-symbol-chip {
  display: inline-flex;
  align-items: center;
  border-radius: .5rem;
  background: var(--s2-theme-accent-soft);
  color: var(--s2-theme-accent-strong);
  font-weight: 700;
  padding: .28rem .55rem;
  direction: ltr;
}

.currency-composition-content {
  align-items: stretch;
  gap: 1.5rem;
  margin-top: 1rem;
  padding-top: 1rem;
  border-top: 1px solid var(--bs-border-color);
}

.currency-chart-frame {
  position: relative;
  flex: 0 0 13rem;
  height: 13rem;
}

.currency-chart-legend {
  display: flex;
  flex: 1 1 16rem;
  flex-direction: column;
  justify-content: center;
  gap: .45rem;
}

.wallets-index-hero,
.wallets-index-summary,
.wallets-index-stat,
.wallets-currency-panel,
.currency-index-stat {
  border: 1px solid var(--s2-theme-accent-border);
  border-radius: 1rem;
  background: var(--bs-body-bg);
  box-shadow: 0 .55rem 1.35rem rgba(20, 35, 60, .07);
}

.wallets-index-hero {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 1.5rem;
  color: #fff;
  background: linear-gradient(135deg, var(--s2-theme-accent), var(--s2-theme-accent-strong));
}

.wallets-index-hero h2 {
  color: inherit;
}

.wallets-index-kicker,
.wallets-index-subtitle {
  font-size: .86rem;
}

.wallets-index-kicker {
  font-weight: 700;
  opacity: .9;
}

.wallets-index-subtitle {
  color: rgba(255, 255, 255, .82);
}

.wallets-index-hero-actions,
.wallets-index-summary-content,
.wallets-index-actions {
  display: flex;
  align-items: center;
  gap: .5rem;
}

.wallets-index-hero-actions,
.wallets-index-actions {
  flex-wrap: wrap;
}

.wallets-index-stat,
.currency-index-stat {
  display: flex;
  align-items: center;
  gap: .8rem;
  min-height: 5.7rem;
  padding: 1rem;
}

.wallets-index-stat-icon,
.currency-index-stat-icon {
  display: grid;
  width: 2.7rem;
  height: 2.7rem;
  place-items: center;
  border-radius: .8rem;
  font-size: 1.18rem;
}

.wallets-index-stat-icon.is-primary,
.currency-index-stat-icon.is-primary {
  color: #075985;
  background: #e0f2fe;
}

.wallets-index-stat-icon.is-success,
.currency-index-stat-icon.is-success {
  color: #146c43;
  background: #dcfce7;
}

.wallets-index-stat-icon.is-info,
.currency-index-stat-icon.is-info {
  color: #6d28d9;
  background: #f1ebff;
}

.wallets-index-stat span:not(.wallets-index-stat-icon),
.currency-index-stat span:not(.currency-index-stat-icon) {
  display: block;
  color: var(--bs-secondary-color);
  font-size: .83rem;
}

.wallets-index-stat strong,
.currency-index-stat strong {
  display: block;
  margin-top: .1rem;
  color: var(--bs-emphasis-color);
  font-size: 1.4rem;
}

.wallets-index-summary {
  padding: 1.15rem;
}

.wallets-index-summary-heading p {
  color: var(--bs-secondary-color);
  font-size: .88rem;
}

.wallets-index-summary-content {
  justify-content: space-between;
  flex-wrap: wrap;
  margin-top: 1rem;
}

.wallets-currency-panel {
  overflow: hidden;
}

.wallets-currency-panel-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: .9rem 1.05rem;
  border-bottom: 1px solid var(--s2-theme-accent-border);
  background: var(--s2-theme-accent-soft);
}

.wallets-currency-panel-label {
  color: var(--s2-theme-accent-strong);
  font-size: .83rem;
  font-weight: 700;
}

.wallets-currency-panel-total {
  margin-top: .18rem;
  color: var(--bs-emphasis-color);
  font-size: 1.18rem;
  font-weight: 800;
  direction: ltr;
  text-align: right;
}

.wallets-currency-panel-total span {
  color: var(--bs-secondary-color);
  font-size: .78rem;
  font-weight: 600;
}

.wallets-currency-panel-count,
.wallets-index-code {
  display: inline-flex;
  align-items: center;
  border-radius: .55rem;
  font-size: .8rem;
  font-weight: 700;
}

.wallets-currency-panel-count {
  padding: .32rem .55rem;
  color: var(--s2-theme-accent-strong);
  background: var(--bs-body-bg);
}

.wallets-index-table thead th {
  padding-top: .8rem;
  padding-bottom: .8rem;
  color: var(--bs-secondary-color);
  font-size: .82rem;
  white-space: nowrap;
}

.wallets-index-table tbody td {
  padding-top: .9rem;
  padding-bottom: .9rem;
}

.wallets-index-id-col {
  width: 5.5rem;
}

.wallets-index-name-col {
  width: 12rem;
}

.wallets-index-account-col {
  min-width: 18rem;
}

.wallets-index-balance-col {
  width: 11rem;
  text-align: left;
  white-space: nowrap;
}

.wallets-index-actions-col {
  width: 12.25rem;
  min-width: 12.25rem;
  text-align: left;
}

.wallets-index-account-cell {
  color: var(--bs-secondary-color);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.wallets-index-code {
  padding: .2rem .5rem;
  color: var(--s2-theme-accent);
  background: var(--s2-theme-accent-soft);
}

.wallets-index-balance {
  display: inline-flex;
  align-items: baseline;
  gap: .3rem;
  font-family: var(--bs-font-monospace);
  font-size: 1rem;
  font-weight: 800;
}

.wallets-index-balance small {
  color: var(--bs-secondary-color);
  font-family: inherit;
  font-size: .75rem;
}

.wallets-index-balance.is-positive {
  color: #146c43;
}

.wallets-index-balance.is-negative {
  color: #b42318;
}

.wallets-index-actions {
  width: 12.25rem;
  justify-content: flex-end;
  flex-wrap: nowrap;
}

.currency-index-actions-col {
  width: 7rem;
}

.currency-index-actions {
  display: flex;
  justify-content: flex-end;
  gap: .45rem;
}

.currency-index-value {
  font-family: var(--bs-font-monospace);
  font-size: 1.08rem;
  font-weight: 800;
}

.currency-index-value.is-positive {
  color: #146c43;
}

.currency-index-value.is-negative {
  color: #b42318;
}

.currency-index-value.is-zero {
  color: var(--bs-secondary-color);
}

html[data-bs-theme="dark"] .currency-index-value.is-positive {
  color: #8ce5b3;
}

html[data-bs-theme="dark"] .currency-index-value.is-negative {
  color: #ff9d96;
}

html[data-bs-theme="dark"] .wallets-index-stat-icon.is-primary,
html[data-bs-theme="dark"] .currency-index-stat-icon.is-primary {
  color: #8fd3ff;
  background: #183d5c;
}

html[data-bs-theme="dark"] .wallets-index-stat-icon.is-success,
html[data-bs-theme="dark"] .currency-index-stat-icon.is-success {
  color: #8ce5b3;
  background: #1a4734;
}

html[data-bs-theme="dark"] .wallets-index-stat-icon.is-info,
html[data-bs-theme="dark"] .currency-index-stat-icon.is-info {
  color: #c9b4ff;
  background: #3a285e;
}

html[data-bs-theme="dark"] .wallets-currency-panel-header {
  background: #263746;
}

.currency-dashboard-hero {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1.25rem;
  padding: 1.45rem;
  color: #fff;
  border: 1px solid var(--s2-theme-accent-border);
  border-radius: 1.1rem;
  background: linear-gradient(135deg, var(--s2-theme-accent), var(--s2-theme-accent-strong));
  box-shadow: 0 .75rem 1.7rem rgba(20, 35, 60, .15);
}

.currency-dashboard-kicker,
.currency-dashboard-subtitle,
.currency-dashboard-panel-kicker {
  font-size: .84rem;
}

.currency-dashboard-kicker {
  margin-bottom: .35rem;
  font-weight: 700;
  opacity: .9;
}

.currency-dashboard-hero h1 {
  color: inherit;
}

.currency-dashboard-symbol {
  display: inline-flex;
  align-items: center;
  padding: .27rem .58rem;
  color: var(--s2-theme-accent-strong);
  border-radius: .55rem;
  background: #fff;
  font-family: var(--bs-font-monospace);
  font-size: .85rem;
  font-weight: 800;
  direction: ltr;
}

.currency-dashboard-subtitle {
  margin-top: .4rem;
  color: rgba(255, 255, 255, .82);
}

.currency-dashboard-actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: .5rem;
}

.currency-dashboard-rates {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  overflow: hidden;
  border: 1px solid var(--s2-theme-accent-border);
  border-radius: 1rem;
  background: var(--bs-body-bg);
  box-shadow: 0 .45rem 1.2rem rgba(20, 35, 60, .06);
}

.currency-dashboard-rate {
  display: flex;
  flex-direction: column;
  gap: .2rem;
  min-height: 5.7rem;
  padding: 1rem 1.1rem;
}

.currency-dashboard-rate + .currency-dashboard-rate {
  border-inline-start: 1px solid var(--bs-border-color);
}

.currency-dashboard-rate span,
.currency-dashboard-stat > div > span {
  color: var(--bs-secondary-color);
  font-size: .82rem;
}

.currency-dashboard-rate span i {
  margin-left: .25rem;
  color: var(--s2-theme-accent-strong);
}

.currency-dashboard-rate strong {
  color: var(--bs-emphasis-color);
  font-family: var(--bs-font-monospace);
  font-size: 1.06rem;
}

.currency-dashboard-stat,
.currency-dashboard-panel {
  border: 1px solid var(--s2-theme-accent-border);
  border-radius: 1rem;
  background: var(--bs-body-bg);
  box-shadow: 0 .45rem 1.2rem rgba(20, 35, 60, .06);
}

.currency-dashboard-stat {
  display: flex;
  align-items: center;
  gap: .85rem;
  min-height: 7rem;
  padding: 1rem;
}

.currency-dashboard-stat-icon {
  display: grid;
  width: 2.9rem;
  height: 2.9rem;
  flex: 0 0 2.9rem;
  place-items: center;
  border-radius: .85rem;
  font-size: 1.22rem;
}

.currency-dashboard-stat-icon.is-wallet {
  color: #075985;
  background: #e0f2fe;
}

.currency-dashboard-stat-icon.is-customers {
  color: #6d28d9;
  background: #f1ebff;
}

.currency-dashboard-stat-icon.is-net {
  color: #146c43;
  background: #dcfce7;
}

.currency-dashboard-stat strong {
  display: block;
  margin-top: .1rem;
  font-family: var(--bs-font-monospace);
  font-size: 1.32rem;
  font-weight: 800;
}

.currency-dashboard-stat small {
  display: block;
  margin-top: .12rem;
  color: var(--bs-secondary-color);
  font-size: .77rem;
}

.currency-dashboard-stat strong.is-positive,
.currency-dashboard-amount.is-positive {
  color: #146c43;
}

.currency-dashboard-stat strong.is-negative,
.currency-dashboard-amount.is-negative {
  color: #b42318;
}

.currency-dashboard-stat strong.is-zero,
.currency-dashboard-amount.is-zero {
  color: var(--bs-secondary-color);
}

.currency-dashboard-panel {
  overflow: hidden;
}

.currency-dashboard-panel-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 1rem 1.15rem;
  border-bottom: 1px solid var(--s2-theme-accent-border);
  background: var(--s2-theme-accent-soft);
}

.currency-dashboard-panel-kicker {
  color: var(--s2-theme-accent-strong);
  font-weight: 700;
}

.currency-dashboard-panel-kicker i {
  margin-left: .25rem;
}

.currency-dashboard-panel-header h2 {
  margin: .1rem 0 0;
  color: var(--bs-emphasis-color);
  font-size: 1.05rem;
  font-weight: 800;
}

.currency-dashboard-count,
.currency-dashboard-type {
  display: inline-flex;
  align-items: center;
  border-radius: .55rem;
  font-size: .79rem;
  font-weight: 700;
}

.currency-dashboard-count {
  padding: .34rem .58rem;
  color: var(--s2-theme-accent-strong);
  background: var(--bs-body-bg);
}

.currency-dashboard-filter {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr)) auto;
  gap: .8rem;
  align-items: end;
  padding: 1rem 1.15rem;
  border-bottom: 1px solid var(--bs-border-color);
}

.currency-dashboard-filter .form-label {
  margin-bottom: .35rem;
  color: var(--bs-secondary-color);
  font-size: .8rem;
}

.currency-dashboard-filter-actions {
  display: flex;
  gap: .45rem;
}

.currency-dashboard-table thead th {
  padding: .8rem 1.15rem;
  color: var(--bs-secondary-color);
  background: color-mix(in srgb, var(--s2-theme-accent-soft) 58%, var(--bs-body-bg));
  font-size: .8rem;
  white-space: nowrap;
}

.currency-dashboard-table tbody td {
  padding: .85rem 1.15rem;
  vertical-align: middle;
}

.currency-dashboard-amount {
  font-family: var(--bs-font-monospace);
  font-size: 1rem;
  font-weight: 800;
}

.currency-dashboard-type {
  padding: .25rem .5rem;
  color: var(--s2-theme-accent-strong);
  background: var(--s2-theme-accent-soft);
}

.currency-dashboard-description {
  max-width: 25rem;
  overflow: hidden;
  color: var(--bs-secondary-color);
  text-overflow: ellipsis;
  white-space: nowrap;
}

.currency-dashboard-empty {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: .55rem;
  min-height: 7rem;
  padding: 1.5rem;
  color: var(--bs-secondary-color);
  text-align: center;
}

.currency-dashboard-empty i {
  color: var(--s2-theme-accent-strong);
  font-size: 1.3rem;
}

html[data-bs-theme="dark"] .currency-dashboard-stat-icon.is-wallet {
  color: #8fd3ff;
  background: #183d5c;
}

html[data-bs-theme="dark"] .currency-dashboard-stat-icon.is-customers {
  color: #c9b4ff;
  background: #3a285e;
}

html[data-bs-theme="dark"] .currency-dashboard-stat-icon.is-net {
  color: #8ce5b3;
  background: #1a4734;
}

html[data-bs-theme="dark"] .currency-dashboard-stat strong.is-positive,
html[data-bs-theme="dark"] .currency-dashboard-amount.is-positive {
  color: #8ce5b3;
}

html[data-bs-theme="dark"] .currency-dashboard-stat strong.is-negative,
html[data-bs-theme="dark"] .currency-dashboard-amount.is-negative {
  color: #ff9d96;
}

html[data-bs-theme="dark"] .currency-dashboard-panel-header {
  background: #263746;
}

@media (max-width: 991.98px) {
  .currency-dashboard-hero,
  .currency-dashboard-panel-header {
    align-items: flex-start;
    flex-direction: column;
  }

  .currency-dashboard-actions {
    justify-content: flex-start;
  }

  .currency-dashboard-rates {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .currency-dashboard-rate:nth-child(3) {
    border-inline-start: 0;
    border-top: 1px solid var(--bs-border-color);
  }

  .currency-dashboard-rate:nth-child(4) {
    border-top: 1px solid var(--bs-border-color);
  }

  .currency-dashboard-filter {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 575.98px) {
  .currency-dashboard-rates,
  .currency-dashboard-filter {
    grid-template-columns: 1fr;
  }

  .currency-dashboard-rate + .currency-dashboard-rate,
  .currency-dashboard-rate:nth-child(3) {
    border-inline-start: 0;
    border-top: 1px solid var(--bs-border-color);
  }

  .currency-dashboard-filter-actions {
    flex-wrap: wrap;
  }
}

.transactions-hub-hero,
.transactions-hub-section,
.transactions-hub-readonly,
.transactions-hub-context,
.transactions-hub-tip {
  border: 1px solid var(--s2-theme-accent-border);
  border-radius: 1rem;
}

.transactions-hub-hero {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 1.5rem;
  color: #fff;
  background: linear-gradient(135deg, var(--s2-theme-accent), var(--s2-theme-accent-strong));
  box-shadow: 0 .75rem 1.75rem color-mix(in srgb, var(--s2-theme-accent) 28%, transparent);
}

.transactions-hub-hero h1 {
  color: inherit;
  font-size: clamp(1.4rem, 2.5vw, 2rem);
  font-weight: 800;
}

.transactions-hub-hero p {
  color: rgba(255, 255, 255, .82);
}

.transactions-hub-kicker {
  font-size: .84rem;
  font-weight: 700;
  opacity: .9;
}

.transactions-hub-hero-actions,
.transactions-hub-context {
  display: flex;
  align-items: center;
  gap: .55rem;
}

.transactions-hub-hero-actions {
  flex-wrap: wrap;
}

.transactions-hub-readonly,
.transactions-hub-context,
.transactions-hub-tip {
  display: flex;
  align-items: center;
  gap: .75rem;
  padding: .9rem 1rem;
}

.transactions-hub-readonly {
  color: #7a4800;
  border-color: #ffd68a;
  background: #fff7e7;
}

.transactions-hub-readonly-icon {
  display: grid;
  width: 2.45rem;
  height: 2.45rem;
  flex: 0 0 2.45rem;
  place-items: center;
  border-radius: .75rem;
  color: #8a4b00;
  background: #ffe7ba;
}

.transactions-hub-readonly strong {
  display: block;
  margin-bottom: .1rem;
}

.transactions-hub-readonly div {
  font-size: .87rem;
}

.transactions-hub-context {
  justify-content: space-between;
  flex-wrap: wrap;
  color: var(--bs-secondary-color);
  background: var(--s2-theme-accent-soft);
  font-size: .86rem;
}

.transactions-hub-context span {
  display: inline-flex;
  align-items: center;
  gap: .35rem;
}

.transactions-hub-section {
  padding: 1.15rem;
  background: var(--bs-body-bg);
  box-shadow: 0 .55rem 1.35rem rgba(20, 35, 60, .07);
}

.transactions-hub-section-heading {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  margin-bottom: 1rem;
}

.transactions-hub-section-heading p {
  color: var(--bs-secondary-color);
  font-size: .88rem;
}

.transactions-hub-count {
  padding: .3rem .55rem;
  border-radius: .55rem;
  color: var(--s2-theme-accent-strong);
  background: var(--s2-theme-accent-soft);
  font-size: .8rem;
  font-weight: 700;
  white-space: nowrap;
}

.transactions-hub-card {
  --transaction-card-color: var(--s2-theme-accent);
  --transaction-card-tint: var(--s2-theme-accent-soft);
  position: relative;
  display: flex;
  min-height: 15.5rem;
  flex-direction: column;
  gap: .8rem;
  padding: 1rem;
  overflow: hidden;
  border: 1px solid var(--s2-theme-accent-border);
  border-radius: .95rem;
  color: var(--bs-body-color);
  background: linear-gradient(160deg, var(--transaction-card-tint), var(--bs-body-bg) 58%);
  text-decoration: none;
  transition: transform .18s ease, box-shadow .18s ease, border-color .18s ease;
}

.transactions-hub-card::after {
  position: absolute;
  inset: auto -1.15rem -1.2rem auto;
  width: 5.5rem;
  height: 5.5rem;
  border-radius: 50%;
  background: var(--transaction-card-tint);
  content: "";
}

.transactions-hub-card:hover {
  color: inherit;
  border-color: var(--transaction-card-color);
  box-shadow: 0 .75rem 1.5rem color-mix(in srgb, var(--transaction-card-color) 17%, transparent);
  transform: translateY(-3px);
}

.transactions-hub-card.is-buy { --transaction-card-color: #146c43; --transaction-card-tint: #e3f6eb; }
.transactions-hub-card.is-sell { --transaction-card-color: #9a3412; --transaction-card-tint: #fff0e8; }
.transactions-hub-card.is-exchange { --transaction-card-color: #075985; --transaction-card-tint: #e4f4ff; }
.transactions-hub-card.is-transfer { --transaction-card-color: #5b21b6; --transaction-card-tint: #f0ebff; }
.transactions-hub-card.is-request { --transaction-card-color: #8a4b00; --transaction-card-tint: #fff3dc; }

.transactions-hub-card-icon {
  display: grid;
  width: 2.6rem;
  height: 2.6rem;
  place-items: center;
  border-radius: .78rem;
  color: var(--transaction-card-color);
  background: var(--bs-body-bg);
  box-shadow: 0 .25rem .6rem rgba(20, 35, 60, .06);
  font-size: 1.25rem;
}

.transactions-hub-card-body {
  display: flex;
  flex: 1;
  flex-direction: column;
}

.transactions-hub-card-title,
.transactions-hub-card h3 {
  color: var(--bs-emphasis-color);
  font-size: 1.08rem;
  font-weight: 800;
}

.transactions-hub-card-subtitle {
  margin-top: .12rem;
  color: var(--transaction-card-color);
  font-size: .82rem;
  font-weight: 700;
}

.transactions-hub-card-description,
.transactions-hub-card p {
  margin: .55rem 0 0;
  color: var(--bs-secondary-color);
  font-size: .85rem;
  line-height: 1.65;
}

.transactions-hub-card-action {
  position: relative;
  z-index: 1;
  display: inline-flex;
  align-items: center;
  align-self: flex-start;
  gap: .35rem;
  color: var(--transaction-card-color);
  font-size: .83rem;
  font-weight: 800;
}

.transactions-hub-card.is-disabled {
  cursor: not-allowed;
  filter: grayscale(.3);
  opacity: .68;
}

.transactions-hub-tip {
  color: var(--bs-secondary-color);
  background: var(--bs-body-bg);
}

.transactions-hub-tip > .bi {
  display: grid;
  width: 2.35rem;
  height: 2.35rem;
  flex: 0 0 2.35rem;
  place-items: center;
  border-radius: .7rem;
  color: #8a4b00;
  background: #fff3dc;
}

.transactions-hub-tip strong,
.transactions-hub-tip span {
  display: block;
}

.transactions-hub-tip strong {
  margin-bottom: .12rem;
  color: var(--bs-emphasis-color);
}

.transactions-hub-tip span {
  font-size: .86rem;
}

html[data-bs-theme="dark"] .transactions-hub-card.is-buy { --transaction-card-color: #8ce5b3; --transaction-card-tint: #1a4734; }
html[data-bs-theme="dark"] .transactions-hub-card.is-sell { --transaction-card-color: #ffc0a3; --transaction-card-tint: #512b1e; }
html[data-bs-theme="dark"] .transactions-hub-card.is-exchange { --transaction-card-color: #8fd3ff; --transaction-card-tint: #183d5c; }
html[data-bs-theme="dark"] .transactions-hub-card.is-transfer { --transaction-card-color: #c9b4ff; --transaction-card-tint: #3a285e; }
html[data-bs-theme="dark"] .transactions-hub-card.is-request { --transaction-card-color: #ffd188; --transaction-card-tint: #4f3b1b; }

html[data-bs-theme="dark"] .transactions-hub-readonly {
  color: #ffd188;
  border-color: #6c5424;
  background: #3c321e;
}

html[data-bs-theme="dark"] .transactions-hub-readonly-icon,
html[data-bs-theme="dark"] .transactions-hub-tip > .bi {
  color: #ffd188;
  background: #4f3b1b;
}

@media (max-width: 767.98px) {
  .transactions-hub-hero,
  .transactions-hub-section-heading {
    align-items: flex-start;
    flex-direction: column;
  }

  .transactions-hub-hero-actions {
    width: 100%;
  }

  .transactions-hub-hero-actions .btn {
    flex: 1 1 auto;
  }

  .transactions-hub-card {
    min-height: 12.75rem;
  }
}

html[data-bs-theme="dark"] {
  color-scheme: dark;
}

html[data-bs-theme="dark"] body {
  background-color: #212529;
  color: #e9ecef;
}

/* Mobile data tables: keep request/tracking rows readable without horizontal scrolling. */
@media (max-width: 767.98px) {
  .data-list-toolbar {
    width: 100%;
    flex-direction: column;
    align-items: stretch;
  }

  .data-list-toolbar .data-list-filter,
  .data-list-toolbar .dropdown,
  .data-list-toolbar .form-control,
  .data-list-toolbar .form-select,
  .data-list-toolbar .btn {
    width: 100%;
    max-width: none;
  }

  .mobile-stack-table,
  .mobile-stack-table tbody,
  .mobile-stack-table tr,
  .mobile-stack-table td {
    display: block;
    width: 100%;
  }

  .mobile-stack-table thead {
    display: none;
  }

  .mobile-stack-table tbody tr.request-list-row,
  .mobile-stack-table tbody tr.tracking-list-row {
    padding: .65rem .8rem;
    border-bottom: 1px solid var(--bs-border-color);
  }

  .mobile-stack-table tbody tr.request-list-row td,
  .mobile-stack-table tbody tr.tracking-list-row td {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    gap: .75rem;
    padding: .3rem 0;
    border: 0;
    text-align: left;
    overflow-wrap: anywhere;
  }

  .mobile-stack-table tbody tr.request-list-row td::before,
  .mobile-stack-table tbody tr.tracking-list-row td::before {
    content: attr(data-label);
    flex: 0 0 5rem;
    color: var(--bs-secondary-color);
    font-size: .78rem;
    font-weight: 600;
    text-align: right;
  }

  .mobile-stack-table tbody tr.request-list-row td:last-child,
  .mobile-stack-table tbody tr.tracking-list-row td:last-child {
    justify-content: flex-start;
    padding-top: .55rem;
  }

  .mobile-stack-table tbody tr.request-list-row td:last-child::before,
  .mobile-stack-table tbody tr.tracking-list-row td:last-child::before {
    flex-basis: 5rem;
  }

  .mobile-stack-table .btn-group {
    margin-inline-start: auto;
  }
}

html[data-bs-theme="dark"] .table-container {
  background: #1f2328;
  box-shadow: 0 0.5rem 1rem rgba(0,0,0,0.2);
}

html[data-bs-theme="dark"] .s2-surface-form,
html[data-bs-theme="dark"] .s2-client-page > .rtl-wrap {
  box-shadow: 0 .5rem 1.25rem rgba(0, 0, 0, .22);
}

html[data-bs-theme="dark"] .table {
  color: #e9ecef;
}

html[data-bs-theme="dark"] .table thead th {
  background-color: var(--s2-theme-accent-soft);
  color: #e9ecef;
}

html[data-bs-theme="dark"] {
  --s2-theme-accent-soft: color-mix(in srgb, var(--s2-theme-accent) 24%, var(--bs-body-bg));
  --s2-theme-accent-border: color-mix(in srgb, var(--s2-theme-accent) 38%, var(--bs-border-color));
}

.viewer-portal-hero,
.viewer-balance-card,
.viewer-content-card {
  border: 1px solid var(--s2-theme-accent-border);
  box-shadow: 0 .5rem 1.25rem rgba(20, 35, 60, .06);
}

.viewer-portal-hero {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 1.5rem;
  border-radius: 1rem;
  background: linear-gradient(135deg, var(--s2-theme-accent-soft), var(--bs-body-bg) 68%);
}

.viewer-portal-kicker {
  margin-bottom: .35rem;
  color: var(--s2-theme-accent);
  font-size: .82rem;
  font-weight: 700;
}

.viewer-portal-subtitle {
  color: var(--bs-secondary-color);
  font-size: .92rem;
}

.viewer-balance-card {
  border-inline-start: 4px solid var(--s2-theme-accent) !important;
  border-radius: 1rem;
  background: var(--bs-body-bg);
}

.viewer-balance-card .fs-5 {
  font-size: 1.2rem !important;
}

.viewer-currency-symbol,
.viewer-notification-icon {
  display: inline-grid;
  place-items: center;
  background: var(--s2-theme-accent-soft);
  color: var(--s2-theme-accent);
  font-weight: 700;
}

.viewer-currency-symbol {
  min-width: 2.2rem;
  height: 2.2rem;
  padding: .25rem .5rem;
  border-radius: .7rem;
}

.viewer-content-card {
  overflow: hidden;
  border-radius: 1rem;
  background: var(--bs-body-bg);
}

.viewer-content-card .card-header {
  padding: 1rem 1rem 0;
  background: linear-gradient(180deg, var(--s2-theme-accent-soft), transparent);
}

.viewer-portal-tabs {
  padding-bottom: .2rem;
}

.viewer-portal-tabs .nav-link {
  border: 1px solid transparent;
  border-radius: .7rem;
  color: var(--bs-secondary-color);
  font-weight: 600;
}

.viewer-portal-tabs .nav-link:hover {
  border-color: var(--s2-theme-accent-border);
  color: var(--s2-theme-accent);
}

.viewer-portal-tabs .nav-link.active {
  border-color: var(--s2-theme-accent);
  background: var(--s2-theme-accent);
  box-shadow: 0 .3rem .7rem color-mix(in srgb, var(--s2-theme-accent) 25%, transparent);
}

.viewer-filter-panel {
  padding: 1rem;
  border: 1px solid var(--s2-theme-accent-border);
  border-radius: .9rem;
  background: var(--s2-theme-accent-soft);
}

.viewer-filter-panel .form-label {
  margin-bottom: .3rem;
  color: var(--bs-secondary-color);
  font-size: .83rem;
}

.viewer-table-shell {
  overflow: hidden;
  border: 1px solid var(--bs-border-color);
  border-radius: .9rem;
  background: var(--bs-body-bg);
}

.viewer-table-shell thead th {
  border-bottom-width: 1px;
  background: var(--s2-theme-accent-soft);
  color: var(--bs-emphasis-color);
  font-size: .84rem;
  white-space: nowrap;
}

.viewer-table-shell td {
  vertical-align: middle;
}

.viewer-type-chip,
.viewer-readonly-badge {
  display: inline-flex;
  align-items: center;
  gap: .35rem;
  padding: .25rem .55rem;
  border-radius: 999px;
  background: var(--s2-theme-accent-soft);
  color: var(--s2-theme-accent);
  font-size: .8rem;
  font-weight: 600;
}

.viewer-readonly-badge {
  background: var(--bs-tertiary-bg);
  color: var(--bs-secondary-color);
}

.viewer-portal-request-form {
  padding: 1rem;
  border: 1px solid var(--s2-theme-accent-border);
  border-radius: .9rem;
  background: linear-gradient(135deg, var(--s2-theme-accent-soft), var(--bs-body-bg));
}

.viewer-portal-request-form-title {
  display: flex;
  align-items: flex-start;
  gap: .65rem;
  margin-bottom: 1rem;
}

.viewer-portal-request-form-title > i {
  display: grid;
  place-items: center;
  width: 2.3rem;
  height: 2.3rem;
  color: var(--s2-theme-accent);
  background: var(--bs-body-bg);
  border-radius: .7rem;
}

.viewer-portal-request-form-title strong,
.viewer-portal-request-form-title span {
  display: block;
}

.viewer-portal-request-form-title span {
  margin-top: .15rem;
  color: var(--bs-secondary-color);
  font-size: .82rem;
}

.portal-queue-hero {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 1rem;
  padding: 1.35rem 1.45rem;
  border-radius: 1.15rem;
  color: #fff;
  background: linear-gradient(135deg, var(--s2-theme-accent), var(--s2-theme-accent-strong));
  box-shadow: 0 .7rem 1.6rem color-mix(in srgb, var(--s2-theme-accent) 26%, transparent);
}

.portal-queue-kicker,
.portal-queue-hero p {
  color: rgba(255, 255, 255, .82);
}

.portal-queue-kicker {
  margin-bottom: .25rem;
  font-size: .8rem;
  font-weight: 700;
}

.portal-queue-hero-actions,
.portal-queue-filter,
.portal-queue-actions {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: .55rem;
}

.portal-queue-filter {
  padding: .75rem;
  border: 1px solid var(--bs-border-color);
  border-radius: .8rem;
  background: var(--bs-body-bg);
}

.portal-queue-filter .form-select {
  width: min(100%, 15rem);
}

.portal-queue-card {
  overflow: hidden;
  border: 1px solid var(--bs-border-color);
  border-radius: 1rem;
  background: var(--bs-body-bg);
  box-shadow: 0 .45rem 1.2rem rgba(20, 35, 60, .05);
}

.portal-queue-table thead th {
  color: var(--bs-emphasis-color);
  font-size: .81rem;
  white-space: nowrap;
  background: var(--s2-theme-accent-soft);
}

.portal-queue-table td {
  vertical-align: middle;
}

.portal-queue-quote-form {
  display: grid;
  grid-template-columns: minmax(7rem, 1fr) 4.2rem;
  gap: .35rem;
  min-width: 15rem;
}

.portal-queue-quote-form input[name="StaffNote"] {
  grid-column: 1 / -1;
}

.portal-queue-quote-form button {
  grid-column: 1 / -1;
}

.viewer-notification-icon {
  width: 2.4rem;
  height: 2.4rem;
  flex: 0 0 2.4rem;
  border-radius: .75rem;
}

@media (max-width: 575.98px) {
  .viewer-portal-hero {
    align-items: stretch;
    flex-direction: column;
  }

  .viewer-portal-hero .btn {
    flex: 1;
  }

  .viewer-portal-tabs {
    flex-wrap: nowrap;
    overflow-x: auto;
  }

  .portal-queue-hero {
    align-items: flex-start;
    flex-direction: column;
    padding: 1.1rem;
  }
}

@media print {
  .no-print,
  nav,
  header,
  footer {
    display: none !important;
  }

  body {
    -webkit-print-color-adjust: exact;
    print-color-adjust: exact;
  }

  .card {
    box-shadow: none !important;
  }

  thead {
    display: table-header-group;
  }

  tr {
    page-break-inside: avoid;
  }
}

.hero {
  background: linear-gradient(135deg, #e8f0ff 0%, #ffffff 100%);
  border-radius: 1rem;
  padding: 2rem;
  box-shadow: 0 0.75rem 1.5rem rgba(13,110,253,0.08);
}

.quick-link {
  display: block;
  text-decoration: none;
  border-radius: 0.75rem;
  padding: 1.25rem;
  background: #ffffff;
  box-shadow: 0 0.5rem 1rem rgba(0,0,0,0.06);
  transition: transform .15s ease, box-shadow .15s ease;
}

.quick-link:hover {
  transform: translateY(-2px);
  box-shadow: 0 0.75rem 1.5rem rgba(0,0,0,0.08);
}

.home-dashboard-hero,
.home-dashboard-panel,
.home-dashboard-section {
  border: 1px solid var(--s2-theme-accent-border);
  border-radius: 1rem;
  background: var(--bs-body-bg);
  box-shadow: 0 .5rem 1.25rem rgba(20, 35, 60, .06);
}

.customers-index-hero,
.customers-index-filter-panel,
.customers-index-table-panel,
.customers-index-card,
.customers-index-stat {
  border: 1px solid var(--s2-theme-accent-border);
  border-radius: 1rem;
  background: var(--bs-body-bg);
  box-shadow: 0 .5rem 1.25rem rgba(20, 35, 60, .06);
}

.customers-index-hero {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 1.5rem;
  background: linear-gradient(135deg, var(--s2-theme-accent-soft), var(--bs-body-bg) 68%);
}

.customers-index-hero h2 {
  color: var(--bs-emphasis-color);
}

.customers-index-hero p,
.customers-index-filter-heading p {
  color: var(--bs-secondary-color);
}

.customers-index-kicker,
.customers-index-card-label {
  display: flex;
  align-items: center;
  gap: .45rem;
  color: var(--s2-theme-accent);
  font-size: .82rem;
  font-weight: 700;
}

.customers-index-total {
  display: inline-flex;
  align-items: center;
  gap: .25rem;
  margin-inline-start: .35rem;
  padding: .2rem .5rem;
  border-radius: 999px;
  color: var(--s2-theme-accent);
  background: var(--s2-theme-accent-soft);
  font-size: .76rem;
}

.customers-index-hero-actions,
.customers-index-actions,
.customers-index-view-toggle,
.customers-index-filter-heading,
.customers-index-pager-top {
  display: flex;
  align-items: center;
  gap: .5rem;
}

.customers-index-hero-actions,
.customers-index-actions {
  flex-wrap: wrap;
}

.customers-index-stat {
  display: flex;
  align-items: center;
  gap: .8rem;
  min-height: 5.75rem;
  padding: 1rem;
}

.customers-index-stat-icon {
  display: grid;
  width: 2.7rem;
  height: 2.7rem;
  place-items: center;
  border-radius: .8rem;
  background: color-mix(in srgb, currentColor 10%, transparent);
  font-size: 1.2rem;
}

.customers-index-stat span:not(.customers-index-stat-icon) {
  display: block;
  color: var(--bs-secondary-color);
  font-size: .83rem;
}

.customers-index-stat strong {
  display: block;
  margin-top: .1rem;
  color: var(--bs-emphasis-color);
  font-size: 1.45rem;
}

.customers-index-filter-panel {
  padding: 1.15rem;
}

.customers-index-filter-heading {
  justify-content: space-between;
  margin-bottom: 1rem;
}

.customers-index-view-toggle {
  justify-content: flex-end;
  color: var(--bs-secondary-color);
  font-size: .85rem;
}

.customers-index-pager-top {
  justify-content: flex-end;
  margin-bottom: 1rem;
}

.customers-index-table-panel {
  overflow: hidden;
}

.customers-index-table-panel thead th {
  padding-top: .8rem;
  padding-bottom: .8rem;
  color: var(--bs-secondary-color);
  font-size: .82rem;
  white-space: nowrap;
}

.customers-index-table-panel tbody td {
  padding-top: .9rem;
  padding-bottom: .9rem;
}

.customers-index-code {
  display: inline-flex;
  align-items: center;
  padding: .2rem .5rem;
  border-radius: .5rem;
  color: var(--s2-theme-accent);
  background: var(--s2-theme-accent-soft);
  font-size: .8rem;
  font-weight: 700;
  white-space: nowrap;
}

.customers-index-contact-list {
  margin: 0;
  padding: 0;
  list-style: none;
  color: var(--bs-secondary-color);
  font-size: .88rem;
}

.customers-index-contact-list li + li {
  margin-top: .2rem;
}

.customers-index-balance-list {
  display: flex;
  flex-wrap: wrap;
  gap: .35rem;
}

.customers-index-balance-chip {
  display: inline-flex;
  align-items: center;
  gap: .35rem;
  padding: .3rem .5rem;
  border: 1px solid currentColor;
  border-radius: .55rem;
  font-size: .8rem;
  line-height: 1.2;
}

.customers-index-balance-chip.is-positive {
  color: #146c43;
  background: rgba(20, 108, 67, .08);
}

.customers-index-balance-chip.is-negative {
  color: #b42318;
  background: rgba(180, 35, 24, .08);
}

.customers-index-card {
  overflow: hidden;
  transition: transform .18s ease, box-shadow .18s ease;
}

.customers-index-card:hover {
  transform: translateY(-2px);
  box-shadow: 0 .8rem 1.7rem rgba(20, 35, 60, .1);
}

.customers-index-card-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: .75rem;
  padding: .9rem 1rem;
  color: #fff;
  border-bottom-color: transparent;
  background: linear-gradient(135deg, var(--s2-theme-accent), color-mix(in srgb, var(--s2-theme-accent) 78%, #000));
}

.customers-index-card-header .card-title {
  color: inherit;
}

.customers-index-card-header .customers-index-code {
  color: #fff;
  background: rgba(255, 255, 255, .16);
}

.customers-index-dashboard-btn {
  display: inline-flex;
  align-items: center;
  gap: .45rem;
  min-height: 2.35rem;
  padding: .38rem .55rem .38rem .7rem;
  border: 1px solid color-mix(in srgb, var(--s2-theme-accent) 38%, #fff);
  border-radius: .75rem;
  color: var(--s2-theme-accent-strong);
  background: color-mix(in srgb, var(--bs-body-bg) 88%, var(--s2-theme-accent-soft));
  box-shadow: 0 .25rem .65rem color-mix(in srgb, var(--s2-theme-accent) 12%, transparent);
  font-size: .78rem;
  font-weight: 800;
  text-decoration: none;
  white-space: nowrap;
  transition: transform .18s ease, color .18s ease, background .18s ease, box-shadow .18s ease;
}

.customers-index-dashboard-btn:hover,
.customers-index-dashboard-btn:focus-visible {
  color: #fff;
  background: var(--s2-theme-accent);
  box-shadow: 0 .45rem 1rem color-mix(in srgb, var(--s2-theme-accent) 25%, transparent);
  transform: translateY(-1px);
}

.customers-index-dashboard-btn-icon {
  display: grid;
  width: 1.65rem;
  height: 1.65rem;
  place-items: center;
  border-radius: .5rem;
  color: #fff;
  background: var(--s2-theme-accent);
  font-size: .9rem;
}

.customers-index-dashboard-btn-arrow {
  margin-inline-start: .1rem;
  font-size: .8rem;
  opacity: .7;
}

.customers-index-dashboard-btn:hover .customers-index-dashboard-btn-icon,
.customers-index-dashboard-btn:focus-visible .customers-index-dashboard-btn-icon {
  color: var(--s2-theme-accent);
  background: #fff;
}

.customers-index-card-contacts {
  display: grid;
  gap: .3rem;
  color: var(--bs-secondary-color);
  font-size: .88rem;
}

html[data-bs-theme="dark"] .customers-index-balance-chip.is-positive {
  color: #75d6a5;
  background: rgba(117, 214, 165, .12);
}

html[data-bs-theme="dark"] .customers-index-balance-chip.is-negative {
  color: #ff9d96;
  background: rgba(255, 157, 150, .12);
}

@media (max-width: 575.98px) {
  .customers-index-hero,
  .customers-index-filter-heading,
  .customers-index-card-header {
    align-items: flex-start;
    flex-direction: column;
  }

  .customers-index-hero-actions,
  .customers-index-actions {
    width: 100%;
  }

  .customers-index-card-header .customers-index-actions {
    justify-content: stretch;
  }

  .customers-index-card-header .customers-index-dashboard-btn {
    width: 100%;
    justify-content: center;
  }

  .customers-index-hero-actions .btn {
    flex: 1 1 auto;
  }

  .customers-index-view-toggle {
    justify-content: space-between;
  }
}

.home-dashboard-hero {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 1.5rem;
  color: var(--bs-emphasis-color);
  background:
    linear-gradient(135deg, var(--s2-theme-accent-soft), var(--bs-body-bg) 68%);
}

.home-dashboard-hero p,
.home-dashboard-section-header p {
  color: var(--bs-secondary-color);
}

.home-dashboard-kicker {
  color: var(--s2-theme-accent);
  font-size: .82rem;
  font-weight: 700;
  margin-bottom: .35rem;
}

.home-dashboard-role {
  display: inline-flex;
  align-items: center;
  gap: .45rem;
  padding: .5rem .75rem;
  border: 1px solid var(--s2-theme-accent-border);
  border-radius: 999px;
  color: var(--s2-theme-accent);
  background: color-mix(in srgb, var(--s2-theme-accent) 10%, var(--bs-body-bg));
  white-space: nowrap;
}

.home-stat-card {
  display: flex;
  position: relative;
  flex-direction: column;
  min-height: 150px;
  padding: 1.15rem;
  overflow: hidden;
  color: inherit;
  text-decoration: none;
  border: 1px solid var(--bs-border-color);
  border-radius: .9rem;
  background: var(--bs-body-bg);
  box-shadow: 0 .35rem 1rem rgba(20, 35, 60, .05);
  transition: transform .16s ease, box-shadow .16s ease, border-color .16s ease;
}

.home-stat-card:hover {
  color: inherit;
  border-color: var(--s2-theme-accent-border);
  box-shadow: 0 .65rem 1.4rem rgba(20, 35, 60, .1);
  transform: translateY(-2px);
}

.home-stat-icon {
  position: absolute;
  top: .9rem;
  left: 1rem;
  font-size: 1.5rem;
  opacity: .82;
}

.home-stat-label {
  color: var(--bs-secondary-color);
  font-size: .86rem;
}

.home-stat-value {
  margin-top: .6rem;
  font-size: clamp(1.15rem, 2vw, 1.5rem);
}

.home-stat-card small {
  margin-top: auto;
  color: var(--bs-secondary-color);
}

.home-dashboard-section,
.home-dashboard-panel {
  padding: 1.2rem;
}

.home-dashboard-section-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  margin-bottom: 1rem;
}

.home-dashboard-section-header p {
  font-size: .84rem;
}

.home-quick-action,
.home-attention-item {
  display: flex;
  align-items: center;
  gap: .75rem;
  min-height: 76px;
  padding: .8rem .9rem;
  color: inherit;
  text-decoration: none;
  border: 1px solid var(--bs-border-color);
  border-radius: .75rem;
  background: var(--bs-body-bg);
  transition: transform .16s ease, border-color .16s ease, background-color .16s ease;
}

.home-quick-action:hover,
.home-attention-item:hover {
  color: inherit;
  border-color: var(--s2-theme-accent-border);
  background: var(--s2-theme-accent-soft);
  transform: translateY(-1px);
}

.home-quick-action > .bi:first-child {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 2.45rem;
  height: 2.45rem;
  color: var(--bs-emphasis-color);
  border-radius: .65rem;
  background: var(--s2-theme-accent-soft);
  font-size: 1.15rem;
}

.home-quick-action-success > .bi:first-child { color: var(--bs-success); }
.home-quick-action-primary > .bi:first-child { color: var(--bs-primary); }
.home-quick-action-info > .bi:first-child { color: var(--bs-info-text-emphasis); }
.home-quick-action-warning > .bi:first-child { color: var(--bs-warning-text-emphasis); }
.home-quick-action-danger > .bi:first-child { color: var(--bs-danger); }

.home-quick-action span,
.home-attention-item span:not(.home-attention-icon),
.home-activity-item span:last-child {
  display: flex;
  flex: 1;
  flex-direction: column;
  gap: .15rem;
}

.home-quick-action small,
.home-attention-item small,
.home-activity-item small {
  color: var(--bs-secondary-color);
  font-size: .78rem;
}

.home-quick-chevron {
  margin-right: auto;
  color: var(--bs-secondary-color);
}

.home-attention-list,
.home-activity-list {
  display: grid;
  gap: .55rem;
}

.home-attention-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 2.2rem;
  height: 2.2rem;
  border-radius: 50%;
  background: var(--bs-tertiary-bg);
}

.home-empty-state {
  display: flex;
  min-height: 170px;
  align-items: center;
  justify-content: center;
  flex-direction: column;
  gap: .4rem;
  color: var(--bs-secondary-color);
  text-align: center;
}

.home-empty-state .bi {
  color: var(--bs-success);
  font-size: 2rem;
}

.home-activity-item {
  display: flex;
  align-items: flex-start;
  gap: .65rem;
  padding: .5rem 0;
  border-bottom: 1px solid var(--bs-border-color-translucent);
}

.home-activity-item:last-child {
  border-bottom: 0;
}

.home-activity-dot {
  width: .55rem;
  height: .55rem;
  margin-top: .38rem;
  border-radius: 50%;
  background: var(--s2-theme-accent);
}

.home-access-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: .65rem;
}

.home-access-grid a {
  display: flex;
  align-items: center;
  gap: .5rem;
  padding: .75rem;
  color: inherit;
  text-decoration: none;
  border: 1px solid var(--bs-border-color);
  border-radius: .65rem;
}

.home-access-grid a:hover {
  color: var(--s2-theme-accent);
  border-color: var(--s2-theme-accent-border);
}

@media (max-width: 575.98px) {
  .home-dashboard-hero,
  .home-dashboard-section-header {
    align-items: flex-start;
    flex-direction: column;
  }

  .home-access-grid {
    grid-template-columns: 1fr;
  }
}

.form-floating > .form-control-plaintext::placeholder, .form-floating > .form-control::placeholder {
  color: var(--bs-secondary-color);
  text-align: end;
}

.form-floating > .form-control-plaintext:focus::placeholder, .form-floating > .form-control:focus::placeholder {
  text-align: start;
}

/* RTL global support */
html[lang="fa"] {
  direction: rtl;
}

body {
  text-align: right;
}

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

.form-control, .form-select {
  text-align: right;
}

.input-group {
  direction: rtl;
}

/* Dropdown alignment for RTL */
.dropdown-menu {
  right: 0;
  left: auto;
  text-align: right;
}

.reports-dropdown-menu {
  min-width: 18rem;
  max-width: min(92vw, 25rem);
}

.reports-dropdown-menu .dropdown-item {
  display: flex;
  align-items: center;
  min-height: 2.6rem;
  white-space: normal;
  overflow-wrap: anywhere;
  line-height: 1.5;
}

/* Bootstrap utility overrides for RTL when default CSS is LTR */
html[dir="rtl"] .ms-auto { margin-right: auto !important; margin-left: 0 !important; }
html[dir="rtl"] .me-auto { margin-left: auto !important; margin-right: 0 !important; }
html[dir="rtl"] .float-start { float: right !important; }
html[dir="rtl"] .float-end { float: left !important; }

.btn-dashboard {
  font-size: 1.05rem;
  padding: .5rem .9rem;
}

.btn-icon {
  padding: .25rem .5rem;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}
.btn-icon .bi {
  font-size: 1.2rem;
  line-height: 1;
}

.financial-operation-header {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-start;
  justify-content: space-between;
  gap: 1rem;
  padding: 1rem 1.15rem;
  border: 1px solid var(--s2-theme-accent-border);
  border-radius: .9rem;
  background: linear-gradient(135deg, var(--s2-theme-accent-soft), var(--bs-body-bg));
}

.financial-operation-header > :first-child {
  flex: 1 1 22rem;
  min-width: 0;
}

.financial-operation-kicker {
  color: var(--s2-theme-accent-strong);
  font-size: .8rem;
  font-weight: 700;
  margin-bottom: .25rem;
}

.financial-operation-period-status {
  white-space: nowrap;
}

.financial-operation-navigation {
  display: flex;
  flex: 1 0 100%;
  align-items: center;
  gap: .75rem;
  padding-top: .75rem;
  border-top: 1px solid var(--s2-theme-accent-border);
}

.financial-operation-navigation-label {
  color: var(--bs-secondary-color);
  font-size: .8rem;
  font-weight: 700;
  white-space: nowrap;
}

.financial-operation-navigation-links {
  display: flex;
  flex-wrap: wrap;
  gap: .4rem;
}

.financial-operation-navigation-links .btn {
  display: inline-flex;
  align-items: center;
  gap: .3rem;
}

.financial-operation-summary {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: .75rem;
  padding: .85rem 1rem;
  border: 1px solid var(--bs-border-color);
  border-radius: .75rem;
  background: var(--bs-tertiary-bg);
}

.financial-operation-summary > div {
  display: flex;
  flex-direction: column;
  gap: .25rem;
}

.financial-operation-summary span {
  color: var(--bs-secondary-color);
  font-size: .8rem;
}

.financial-operation-summary strong {
  font-variant-numeric: tabular-nums;
}

.financial-operation-actions {
  position: sticky;
  bottom: .75rem;
  z-index: 10;
  display: flex;
  gap: .5rem;
  align-items: center;
  padding: .75rem;
  border: 1px solid var(--bs-border-color);
  border-radius: .75rem;
  background: color-mix(in srgb, var(--bs-body-bg) 92%, transparent);
  box-shadow: 0 .4rem 1rem rgba(0, 0, 0, .12);
}

@media (max-width: 767.98px) {
  .page-header,
  .currency-list-summary {
    align-items: stretch;
    flex-direction: column;
  }

  .currency-page-actions {
    flex-wrap: wrap;
  }

  .currency-display-selector,
  .currency-display-selector .form-select {
    width: 100%;
  }

  .currency-composition-content {
    flex-direction: column;
  }

  .currency-chart-frame {
    align-self: center;
  }

  .financial-operation-header {
    flex-direction: column;
  }

  .financial-operation-navigation {
    align-items: flex-start;
    flex-direction: column;
    gap: .45rem;
    width: 100%;
  }

  .financial-operation-summary {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .financial-operation-actions {
    flex-wrap: wrap;
  }
}

.navbar-nav .nav-link {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: .2rem;
  min-width: 92px;
  height: 56px;
  border-radius: 14px 14px 0 0;
  padding: .35rem 1rem .65rem;
  margin-inline: .15rem;
  margin-top: .3rem;
  margin-bottom: -.4rem;
  font-size: .9rem;
  opacity: .85;
}

@media (max-width: 991.98px) {
  .app-brand-subtitle {
    display: none;
  }

  .app-brand-title {
    letter-spacing: .12rem;
    font-size: .92rem;
  }

  .app-brand-logo {
    width: 36px;
    height: 36px;
  }

  .navbar-collapse {
    padding-top: .75rem;
  }

  .navbar-nav .nav-link {
    flex-direction: row;
    justify-content: flex-start;
    min-width: 0;
    height: auto;
    margin: 0 0 .25rem;
    padding: .7rem .85rem;
    border-radius: .6rem;
  }

  .navbar-nav .nav-link .bi {
    width: 1.35rem;
    text-align: center;
  }

  .navbar-nav .dropdown-menu {
    margin-bottom: .5rem;
    max-width: 100%;
  }
}

.navbar-nav .nav-link .bi {
  font-size: 1.1rem;
}

.navbar-nav .nav-link.active,
.navbar-nav .nav-link.show,
.navbar-nav .nav-item.show > .nav-link {
  background-color: #ffffff;
  color: #0d6efd !important;
  opacity: 1;
  box-shadow: 0 .2rem .45rem rgba(0,0,0,.18);
}

.navbar-nav .nav-link:not(.active):hover {
  background-color: rgba(255,255,255,.14);
  opacity: 1;
}

.nav-date-pill {
  appearance: none;
  cursor: pointer;
}

@media (min-width: 1200px) {
  body.menu-layout-right {
    padding-right: 238px;
  }

  body.menu-layout-right .main-navigation {
    position: fixed;
    inset: 0 0 0 auto;
    width: 222px;
    margin: 0 !important;
    overflow-y: auto;
    z-index: 1030;
  }

  body.menu-layout-right .main-navigation .container-fluid {
    min-height: 100%;
    flex-direction: column;
    align-items: stretch;
    flex-wrap: nowrap;
    padding: 1rem .75rem;
  }

  body.menu-layout-right .main-navigation .navbar-toggler {
    align-self: flex-start;
    margin: .75rem 0;
  }

  body.menu-layout-right .main-navigation .navbar-collapse {
    display: flex !important;
    flex: 1 1 auto;
    flex-direction: column;
    align-items: stretch;
  }

  body.menu-layout-right .main-navigation .navbar-nav {
    flex-direction: column;
    width: 100%;
    margin: 0 !important;
  }

  body.menu-layout-right .main-navigation .navbar-nav .nav-link {
    flex-direction: row;
    justify-content: flex-start;
    min-width: 0;
    height: auto;
    margin: 0 0 .25rem;
    padding: .7rem .85rem;
    border-radius: .6rem;
  }

  body.menu-layout-right .main-navigation .navbar-nav .nav-link .bi {
    width: 1.35rem;
    text-align: center;
  }

  body.menu-layout-right .main-navigation-user-area {
    width: 100%;
    justify-content: space-between;
    margin-top: auto;
  }

  body.menu-layout-right .main-navigation .dropdown-menu {
    max-width: min(85vw, 24rem);
  }
}

.data-list-toolbar {
  display: flex;
  align-items: end;
  flex-wrap: wrap;
  gap: .5rem;
}

.data-list-filter {
  display: flex;
  align-items: center;
  gap: .4rem;
}

.data-list-filter .form-label {
  margin: 0;
  white-space: nowrap;
  font-size: .85rem;
}

.data-list-filter .form-control,
.data-list-filter .form-select {
  min-width: 11rem;
}

.data-list-result {
  color: var(--bs-secondary-color);
  font-size: .85rem;
  white-space: nowrap;
}

.data-list-table thead th {
  position: sticky;
  top: 0;
  z-index: 1;
  background-color: var(--bs-tertiary-bg);
  box-shadow: inset 0 -1px var(--bs-border-color);
}

.s2-customer-selector {
  display: flex;
}

.s2-customer-selector > .form-control {
  min-width: 0;
}

.s2-customer-selector > .dropdown-menu {
  inset: auto 0 auto 0;
  top: 100%;
  max-height: 18rem;
  overflow-y: auto;
}

@media (max-width: 767.98px) {
  .data-list-toolbar {
    width: 100%;
    align-items: stretch;
  }

  .data-list-filter {
    width: 100%;
  }

  .data-list-filter .form-control,
  .data-list-filter .form-select {
    min-width: 0;
    flex: 1;
  }

  .data-list-result {
    width: 100%;
  }
}

html[data-bs-theme="dark"] .navbar-nav .nav-link.active,
html[data-bs-theme="dark"] .navbar-nav .nav-link.show,
html[data-bs-theme="dark"] .navbar-nav .nav-item.show > .nav-link {
  background-color: #f8f9fa;
  color: #0d6efd !important;
}

.s2-sortable-header {
  cursor: pointer;
  user-select: none;
  white-space: nowrap;
}

.s2-sortable-header::after {
  content: "↕";
  display: inline-block;
  margin-inline-start: .35rem;
  color: var(--bs-secondary-color);
  font-size: .8em;
}

.s2-sortable-header[aria-sort="ascending"]::after {
  content: "↑";
  color: var(--s2-theme-accent-strong, var(--bs-primary));
}

.s2-sortable-header[aria-sort="descending"]::after {
  content: "↓";
  color: var(--s2-theme-accent-strong, var(--bs-primary));
}

.s2-sortable-header:focus-visible {
  outline: 2px solid var(--s2-theme-accent, var(--bs-primary));
  outline-offset: -2px;
}

/* Authentication pages intentionally do not use the authenticated navigation shell. */
.auth-page {
  min-height: calc(100vh - 11rem);
  display: grid;
  place-items: center;
  padding: 2rem 0 3rem;
}

.auth-shell {
  width: min(100%, 940px);
  display: grid;
  grid-template-columns: minmax(0, .9fr) minmax(360px, 1.1fr);
  overflow: hidden;
  border: 1px solid var(--s2-theme-accent-border);
  border-radius: 1.5rem;
  background: var(--bs-body-bg);
  box-shadow: 0 1.5rem 3rem color-mix(in srgb, var(--bs-emphasis-color) 12%, transparent);
}

.auth-shell-compact {
  width: min(100%, 820px);
}

.auth-intro {
  padding: clamp(2rem, 5vw, 4.25rem);
  color: #fff;
  background: linear-gradient(145deg, var(--s2-theme-accent), var(--s2-theme-accent-strong));
}

.auth-brand-mark {
  width: 3.5rem;
  height: 3.5rem;
  display: grid;
  place-items: center;
  margin-bottom: 2rem;
  border: 1px solid rgba(255,255,255,.35);
  border-radius: 1rem;
  background: rgba(255,255,255,.16);
  font-size: 1.65rem;
}

.auth-eyebrow {
  display: block;
  margin-bottom: .7rem;
  color: rgba(255,255,255,.78);
  font-size: .82rem;
  font-weight: 700;
  letter-spacing: .03em;
}

.auth-intro h1 {
  margin-bottom: 1rem;
  font-size: clamp(1.7rem, 3vw, 2.35rem);
  font-weight: 800;
}

.auth-intro p {
  max-width: 31rem;
  margin-bottom: 2rem;
  color: rgba(255,255,255,.88);
  line-height: 1.9;
}

.auth-trust-list {
  display: grid;
  gap: .85rem;
  color: rgba(255,255,255,.92);
  font-size: .9rem;
}

.auth-trust-list div {
  display: flex;
  align-items: center;
  gap: .55rem;
}

.auth-trust-list i {
  color: #b8f3d1;
  font-size: 1.1rem;
}

.auth-form-panel {
  padding: clamp(2rem, 5vw, 4.25rem);
  background: var(--bs-body-bg);
}

.auth-form-heading {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
}

.auth-form-heading h2 {
  margin: .25rem 0 0;
  font-size: 1.55rem;
  font-weight: 800;
}

.auth-form-icon {
  width: 3rem;
  height: 3rem;
  display: grid;
  place-items: center;
  flex: 0 0 auto;
  border-radius: .9rem;
  color: var(--s2-theme-accent-strong);
  background: var(--s2-theme-accent-soft);
  font-size: 1.35rem;
}

.auth-form .input-group-text {
  min-width: 3rem;
  justify-content: center;
  color: var(--s2-theme-accent-strong);
  background: var(--s2-theme-accent-soft);
  border-color: var(--s2-theme-accent-border);
}

.auth-form .form-control:focus {
  border-color: var(--s2-theme-accent);
  box-shadow: 0 0 0 .2rem color-mix(in srgb, var(--s2-theme-accent) 18%, transparent);
}

.auth-password-toggle {
  border-color: var(--bs-border-color);
}

.auth-submit {
  min-height: 3.25rem;
  margin-top: .5rem;
  font-weight: 700;
}

.auth-security-note {
  display: flex;
  gap: .55rem;
  margin-top: 1.5rem;
  padding-top: 1rem;
  border-top: 1px solid var(--bs-border-color);
  color: var(--bs-secondary-color);
  font-size: .78rem;
  line-height: 1.8;
}

.auth-security-note i {
  color: var(--s2-theme-accent-strong);
}

.auth-mfa-input {
  letter-spacing: .35em;
  font-variant-numeric: tabular-nums;
}

html[data-bs-theme="dark"] .auth-shell {
  box-shadow: 0 1.5rem 3rem rgba(0,0,0,.32);
}

@media (max-width: 767.98px) {
  .auth-page {
    min-height: auto;
    padding: 1rem 0 2rem;
  }

  .auth-shell {
    grid-template-columns: 1fr;
    border-radius: 1rem;
  }

  .auth-intro,
  .auth-form-panel {
    padding: 1.65rem;
  }

  .auth-intro p {
    margin-bottom: 1.25rem;
  }

  .auth-trust-list {
    gap: .55rem;
  }
}
