/* Theme App Compatibility Layer */

:root {
  --theme-white: #ffffff;
  --theme-surface: #f6f8f8;
  --theme-line: #d8dfde;
  --theme-green: #4ac481;
  --theme-green-dark: #02836c;
  --theme-teal: #407075;
  --theme-ink-soft: #464c55;
  --theme-ink: #1f2124;
  --theme-blue: #02836c;
  --theme-danger: #dc3545;
  --theme-warning: #f59f00;
  --theme-info: #0aa2c0;
  --theme-success: #2f9e44;
  --theme-muted: #6c757d;
  --theme-radius: 12px;
  --theme-shadow: 0 12px 30px rgba(31, 33, 36, 0.08);
  --theme-shadow-sm: 0 6px 16px rgba(31, 33, 36, 0.05);
}

body {
  min-height: 100%;
  background: #f4f7f6;
  color: var(--theme-ink);
}

.page-wrapper {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

.main-content {
  flex: 1;
  padding: 2rem 0;
}

.container-fluid {
  width: min(1320px, 96vw, calc(100vw - 1.5rem));
  margin-inline: auto;
}

.row {
  display: flex;
  flex-wrap: wrap;
  margin-left: -0.75rem;
  margin-right: -0.75rem;
}

.row > :where([class^='col-'], [class*=' col-']) {
  width: 100%;
  padding-left: 0.75rem;
  padding-right: 0.75rem;
}

.col-12 { width: 100%; }

@media (min-width: 768px) {
  .col-md-3 { width: 25%; }
  .col-md-4 { width: 33.333333%; }
  .col-md-5 { width: 41.666667%; }
  .col-md-6 { width: 50%; }
  .col-md-8 { width: 66.666667%; }
  .col-md-10 { width: 83.333333%; }
}

@media (min-width: 992px) {
  .col-lg-2 { width: 16.666667%; }
  .col-lg-3 { width: 25%; }
  .col-lg-4 { width: 33.333333%; }
  .col-lg-5 { width: 41.666667%; }
  .col-lg-6 { width: 50%; }
  .col-lg-8 { width: 66.666667%; }
  .col-lg-9 { width: 75%; }
  .col-lg-10 { width: 83.333333%; }
  .col-lg-12 { width: 100%; }
}

@media (min-width: 1200px) {
  .col-xl-4 { width: 33.333333%; }
  .col-xl-8 { width: 66.666667%; }
}

.py-5 { padding-top: 3rem; padding-bottom: 3rem; }
.py-4 { padding-top: 1.5rem; padding-bottom: 1.5rem; }
.py-3 { padding-top: 1rem; padding-bottom: 1rem; }
.py-2 { padding-top: 0.5rem; padding-bottom: 0.5rem; }
.px-4 { padding-left: 1.5rem; padding-right: 1.5rem; }
.px-3 { padding-left: 1rem; padding-right: 1rem; }
.px-0 { padding-left: 0; padding-right: 0; }
.p-4 { padding: 1.5rem; }
.p-3 { padding: 1rem; }
.p-2 { padding: 0.5rem; }
.pt-0 { padding-top: 0; }
.mb-0 { margin-bottom: 0; }
.mb-1 { margin-bottom: 0.25rem; }
.mb-2 { margin-bottom: 0.5rem; }
.mb-3 { margin-bottom: 1rem; }
.mb-4 { margin-bottom: 1.5rem; }
.mb-5 { margin-bottom: 3rem; }
.mt-0 { margin-top: 0; }
.mt-2 { margin-top: 0.5rem; }
.mt-3 { margin-top: 1rem; }
.mt-4 { margin-top: 1.5rem; }
.mt-5 { margin-top: 3rem; }
.ms-1 { margin-left: 0.25rem; }
.ms-2 { margin-left: 0.5rem; }
.me-1 { margin-right: 0.25rem; }
.me-2 { margin-right: 0.5rem; }
.g-2 { gap: 0.5rem; }
.g-3 { gap: 1rem; }
.g-4 { gap: 1.5rem; }
.gap-1 { gap: 0.25rem; }
.gap-2 { gap: 0.5rem; }
.gap-3 { gap: 1rem; }
.gap-4 { gap: 1.5rem; }

.row.g-2 {
  column-gap: 0;
  row-gap: 0.5rem;
}

.row.g-3 {
  column-gap: 0;
  row-gap: 0.75rem;
}

.row.g-4 {
  column-gap: 0;
  row-gap: 0.9rem;
}
.w-100 { width: 100%; }
.h-100 { height: 100%; }
.d-none { display: none !important; }
.d-block { display: block !important; }
.d-inline { display: inline !important; }
.d-inline-flex { display: inline-flex !important; }
.d-flex { display: flex !important; }
.flex-column { flex-direction: column !important; }
.flex-wrap { flex-wrap: wrap !important; }
.align-items-center { align-items: center !important; }
.align-items-start { align-items: flex-start !important; }
.justify-content-between { justify-content: space-between !important; }
.justify-content-center { justify-content: center !important; }
.text-center { text-align: center !important; }
.text-end { text-align: right !important; }
.text-muted { color: var(--theme-muted) !important; }
.text-success { color: var(--theme-success) !important; }
.text-danger { color: var(--theme-danger) !important; }
.text-warning { color: var(--theme-warning) !important; }
.text-info { color: var(--theme-info) !important; }
.text-primary { color: var(--theme-blue) !important; }
.text-light { color: #f8f9fa !important; }
.text-white { color: #fff !important; }
.fw-bold { font-weight: 700 !important; }
.fw-semibold { font-weight: 600 !important; }
.small { font-size: 0.875rem; }
.lead { font-size: 1.1rem; color: var(--theme-ink-soft); }
.list-unstyled { list-style: none; padding: 0; margin: 0; }
.min-vh-100 { min-height: 100vh; }
.overflow-auto { overflow: auto; }
.text-decoration-none { text-decoration: none !important; }
.link-inline,
.main-content :where(p, li, td, th, small, .form-text, .form-check-label) a:not([class]) {
  color: var(--theme-blue) !important;
  text-decoration: underline !important;
  text-underline-offset: 2px;
  text-decoration-thickness: 1px;
  font-weight: 600;
}
.link-inline:hover,
.link-inline:focus-visible,
.main-content :where(p, li, td, th, small, .form-text, .form-check-label) a:not([class]):hover,
.main-content :where(p, li, td, th, small, .form-text, .form-check-label) a:not([class]):focus-visible {
  color: #016f5c !important;
  text-decoration-thickness: 2px;
}
.my-3 { margin-top: 1rem; margin-bottom: 1rem; }
.my-4 { margin-top: 1.5rem; margin-bottom: 1.5rem; }
.rounded { border-radius: 10px !important; }
.rounded-circle { border-radius: 999px !important; }
.border { border: 1px solid #d8e3e1 !important; }
.border-secondary { border-color: #bfcdd0 !important; }
.bg-light { background: #f8fbfb !important; }
.bg-secondary { background: #6c757d !important; }
.bg-transparent { background: transparent !important; }
.bg-opacity-10 { --theme-bg-opacity: 0.1; }
.shadow { box-shadow: var(--theme-shadow) !important; }
.img-fluid { max-width: 100%; height: auto; }

@media (min-width: 992px) {
  .d-lg-none { display: none !important; }
  .d-lg-flex { display: flex !important; }
  .text-lg-end { text-align: right !important; }
  .text-lg-start { text-align: left !important; }
  .justify-content-lg-between { justify-content: space-between !important; }
  .align-items-lg-center { align-items: center !important; }
  .flex-lg-row { flex-direction: row !important; }
}

@media (max-width: 991px) {
  .d-lg-none { display: block !important; }
  .d-lg-flex { display: none !important; }
}

@media (min-width: 940px) {
  .main-content .col-lg-2 { width: 16.666667%; }
  .main-content .col-lg-3 { width: 25%; }
  .main-content .col-lg-4 { width: 33.333333%; }
  .main-content .col-lg-5 { width: 41.666667%; }
  .main-content .col-lg-6 { width: 50%; }
  .main-content .col-lg-8 { width: 66.666667%; }
  .main-content .col-lg-9 { width: 75%; }
  .main-content .col-lg-10 { width: 83.333333%; }
  .main-content .col-lg-12 { width: 100%; }
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.4rem;
  min-height: 44px;
  border: 1px solid transparent;
  border-radius: 10px;
  font-size: 0.95rem;
  font-weight: 600;
  padding: 0 1rem;
  cursor: pointer;
}

.btn:hover { filter: brightness(0.98); }

.btn-primary { background: var(--theme-blue); color: #fff; }
.btn-secondary { background: var(--theme-ink-soft); color: #fff; }
.btn-success { background: var(--theme-success); color: #fff; }
.btn-danger { background: var(--theme-danger); color: #fff; }
.btn-warning { background: var(--theme-warning); color: #111; }
.btn-info { background: var(--theme-info); color: #fff; }
.btn-light { background: #fff; color: var(--theme-ink); border-color: var(--theme-line); }
.btn-dark { background: var(--theme-ink); color: #fff; }

.btn-outline-primary { border-color: var(--theme-blue); color: var(--theme-blue); background: transparent; }
.btn-outline-secondary { border-color: #7d8794; color: #59636f; background: transparent; }
.btn-outline-success { border-color: var(--theme-success); color: var(--theme-success); background: transparent; }
.btn-outline-danger { border-color: var(--theme-danger); color: var(--theme-danger); background: transparent; }
.btn-outline-warning { border-color: var(--theme-warning); color: #916200; background: transparent; }
.btn-outline-info { border-color: var(--theme-info); color: var(--theme-info); background: transparent; }
.btn-outline-light { border-color: #dce4e3; color: #fff; background: transparent; }
.btn-link { border: 0; background: transparent; color: var(--theme-blue); min-height: auto; padding: 0; }

.btn-sm { min-height: 34px; padding: 0 0.65rem; font-size: 0.85rem; border-radius: 8px; }
.btn-lg { min-height: 52px; padding: 0 1.35rem; font-size: 1rem; border-radius: 12px; }

.card {
  border: 1px solid #e5eceb;
  border-radius: var(--theme-radius);
  background: #fff;
  box-shadow: var(--theme-shadow-sm);
}

.card-header {
  padding: 0.9rem 1rem;
  border-bottom: 1px solid #ecf1f1;
  background: #fff;
  border-top-left-radius: var(--theme-radius);
  border-top-right-radius: var(--theme-radius);
}

.card-body { padding: 1rem; }

.form-label { display: block; margin-bottom: 0.4rem; font-weight: 600; color: #34404d; }
.form-control,
.form-select,
textarea {
  width: 100%;
  min-height: 44px;
  border: 1px solid #ccd8d6;
  border-radius: 10px;
  background: #fff;
  color: var(--theme-ink);
  padding: 0.55rem 0.75rem;
  font: inherit;
}

textarea.form-control,
textarea { min-height: 110px; }

.form-control:focus,
.form-select:focus,
textarea:focus {
  border-color: #8ac9c0;
  outline: 2px solid rgba(74, 196, 129, 0.14);
}

.form-text { color: #697680; font-size: 0.84rem; margin-top: 0.35rem; }
.input-group { display: flex; align-items: stretch; }
.input-group .input-group-text {
  display: inline-flex;
  align-items: center;
  border: 1px solid #ccd8d6;
  border-right: 0;
  border-radius: 10px 0 0 10px;
  padding: 0 0.7rem;
  background: #f6f9f8;
  color: #5e6d78;
}
.input-group .form-control { border-radius: 0 10px 10px 0; }

.form-floating {
  position: relative;
}

.form-floating > label {
  display: block;
  margin-bottom: 0.35rem;
  font-size: 0.9rem;
  color: #51606d;
}

.form-check {
  display: flex;
  align-items: center;
  gap: 0.45rem;
}

.form-check-input {
  width: 18px;
  height: 18px;
  border: 1px solid #cad6d4;
}

.form-switch .form-check-input {
  width: 36px;
}

.alert {
  position: relative;
  border: 1px solid transparent;
  border-radius: 10px;
  padding: 0.75rem 2.5rem 0.75rem 0.9rem;
  margin-bottom: 1rem;
}

.alert-info { background: #eef8fb; border-color: #b8e4ee; color: #055160; }
.alert-success { background: #eef8f0; border-color: #bde2c3; color: #1e5e2f; }
.alert-warning { background: #fff7e6; border-color: #f2d58b; color: #7a5711; }
.alert-danger,
.alert-error { background: #fff0f2; border-color: #f2b9c0; color: #842029; }
.alert-light { background: #f8fbfb; border-color: #d6e3e1; color: #2f3d4a; }

.alert .btn-close,
.flash-close {
  position: absolute;
  top: 0.45rem;
  right: 0.45rem;
  width: 28px;
  height: 28px;
  border: 0;
  border-radius: 8px;
  background: rgba(31, 33, 36, 0.08);
  color: #2a3440;
  cursor: pointer;
}

.table-responsive {
  width: 100%;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
}

.table {
  width: 100%;
  border-collapse: collapse;
  border-spacing: 0;
  font-size: 0.92rem;
  background: #fff;
}

.table th,
.table td {
  border-bottom: 1px solid #e8efee;
  padding: 0.75rem;
  vertical-align: middle;
}

.main-content .table :is(th, td):not(.text-end):not(.text-start):not(.text-center) {
  text-align: center;
}

.table thead th {
  background: #f5faf9;
  color: #2c3b47;
  font-weight: 700;
  white-space: nowrap;
}

.table-hover tbody tr:hover { background: #f8fcfb; }
.table-light { background: #f5faf9; }
.table-active { background: #ecf7f3; }
.dashboard-shell__main-col .token-row {
  cursor: pointer;
  transition: background-color 0.16s ease, color 0.16s ease;
}
.dashboard-shell__main-col .token-row:hover td {
  background: rgba(2, 131, 108, 0.08);
}
.dashboard-shell__main-col .token-row.table-active td {
  background: rgba(2, 131, 108, 0.2);
  color: #143a33;
  font-weight: 600;
}
.dashboard-shell__main-col .token-row.table-active td:first-child {
  border-left: 4px solid #02836c;
}
.dashboard-shell__main-col .token-row.table-active:hover td {
  background: rgba(2, 131, 108, 0.22);
}
.dashboard-shell__main-col .exchanger-rate-cell {
  transition: background-color 0.16s ease, box-shadow 0.16s ease;
}
.dashboard-shell__main-col .exchanger-rate-cell.is-active {
  background: rgba(2, 131, 108, 0.2) !important;
  box-shadow: inset 0 0 0 2px #02836c;
}
.dashboard-shell__main-col .exchanger-rate-cell.is-active .exchanger-rate-cell__percent,
.dashboard-shell__main-col .exchanger-rate-cell.is-active .exchanger-rate-cell__multiplier,
.dashboard-shell__main-col .exchanger-rate-cell.is-active .exchanger-rate-cell__na-label {
  color: #0f3a33;
  font-weight: 700;
}
.align-middle td,
.align-middle th { vertical-align: middle; }

.badge {
  display: inline-flex;
  align-items: center;
  min-height: 20px;
  border-radius: 999px;
  padding: 0.1rem 0.5rem;
  font-size: 0.75rem;
  font-weight: 600;
}

/* Dark-background badges: force light text */
.badge.bg-dark,
.badge.bg-secondary,
.badge.bg-primary,
.badge.bg-danger {
  color: #fff !important;
}

/* Light/bright badges: keep dark text */
.badge.bg-warning,
.badge.bg-info,
.badge.bg-success,
.badge.bg-light {
  color: #111 !important;
}

.bg-primary { background: var(--theme-blue) !important; }
.bg-success { background: var(--theme-success) !important; }
.bg-danger { background: var(--theme-danger) !important; }
.bg-warning { background: var(--theme-warning) !important; }
.bg-info { background: var(--theme-info) !important; }
.bg-dark { background: var(--theme-ink) !important; }
.bg-light.bg-opacity-10 { background: rgba(248, 251, 251, 0.1) !important; }
.bg-secondary.bg-opacity-10 { background: rgba(108, 117, 125, 0.1) !important; }
.bg-primary.bg-opacity-10 { background: rgba(2, 131, 108, 0.1) !important; }
.bg-success.bg-opacity-10 { background: rgba(47, 158, 68, 0.1) !important; }
.bg-danger.bg-opacity-10 { background: rgba(220, 53, 69, 0.1) !important; }
.bg-warning.bg-opacity-10 { background: rgba(245, 159, 0, 0.1) !important; }
.bg-info.bg-opacity-10 { background: rgba(10, 162, 192, 0.1) !important; }
.bg-dark.bg-opacity-10 { background: rgba(31, 33, 36, 0.1) !important; }

.pagination {
  display: flex;
  gap: 0.35rem;
  list-style: none;
  padding: 0;
  margin: 1rem 0;
}

.nav {
  display: flex;
  gap: 0.25rem;
}

.nav-item {
  list-style: none;
}

.page-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 36px;
  min-height: 36px;
  border: 1px solid #d5e0df;
  border-radius: 8px;
  color: #2e3a45;
  background: #fff;
  padding: 0 0.5rem;
}

.page-item.active .page-link {
  color: #fff;
  border-color: var(--theme-green-dark);
  background: var(--theme-green-dark);
}

.progress {
  width: 100%;
  height: 10px;
  border-radius: 999px;
  background: #e9f1ef;
  overflow: hidden;
}

.progress-bar {
  height: 100%;
  width: 0;
  background: var(--theme-success);
}

.navbar,
.navbar-expand-lg,
.navbar-dark {
  background: transparent !important;
}

.dropdown-menu {
  display: none;
  position: absolute;
  top: calc(100% + 8px);
  right: 0;
  min-width: 220px;
  padding: 0.4rem;
  margin: 0;
  list-style: none;
  border: 1px solid #dce7e5;
  border-radius: 10px;
  background: #fff;
  box-shadow: var(--theme-shadow);
  z-index: 2000;
}

.site-nav-list > li {
  position: relative;
}

.nav-dropdown-toggle {
  border: 0;
  background: transparent;
  font: inherit;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
}

.dropdown.is-open > .dropdown-menu,
.dropdown-menu.is-open {
  display: block;
}

.dropdown-item {
  display: block;
  border-radius: 8px;
  padding: 0.55rem 0.65rem;
  color: #263442;
}

.dropdown-item:hover { background: #f3f8f7; }
.dropdown-divider { height: 1px; margin: 0.4rem 0; background: #e8efee; border: 0; }

.site-header .dropdown {
  position: relative;
}

.dashboard-sidebar-shell {
  position: relative;
}

.deposit-calculator__title {
  margin-bottom: 0.45rem;
}

.deposit-calculator-table {
  font-size: 0.86rem;
}

.deposit-calculator-table td {
  padding: 0.3rem 0.4rem;
  line-height: 1.2;
  border-bottom: 1px solid #e7f0ee;
  vertical-align: middle;
}

.deposit-calculator-table tr:last-child td {
  border-bottom: 0;
}

.deposit-calculator-table td:first-child {
  text-align: left !important;
  color: #60717a;
  width: 58%;
}

.deposit-calculator-table td:last-child {
  text-align: right !important;
  font-variant-numeric: tabular-nums;
  width: 42%;
}

.deposit-calculator-table__summary td {
  background: #f3faf7;
  border-bottom-color: #d4e8e2;
}

.deposit-calculator-table__summary--total td:first-child {
  color: #2f5f57;
}

.deposit-calculator-table__summary--profit td:first-child {
  color: #1f5f45;
}

.mobile-stack {
  display: flex;
  flex-wrap: wrap;
  gap: 0.6rem;
}

.table-deposits .table-deposits__plan-cell {
  background: #f6fbf9;
}

.table-deposits .table-deposits__plan-tag {
  display: inline-flex;
  align-items: center;
  max-width: 100%;
  padding: 0.2rem 0.6rem;
  border: 1px solid rgba(2, 131, 108, 0.28);
  border-radius: 999px;
  background: rgba(2, 131, 108, 0.12);
  color: #016a59;
  font-size: 0.88rem;
  font-weight: 700;
  line-height: 1.35;
  white-space: normal;
  overflow-wrap: anywhere;
}

.table-deposits .table-deposits__progress-cell {
  min-width: 150px;
}

@media (max-width: 767px) {
  .mobile-stack {
    flex-direction: column;
    align-items: stretch;
  }

  .active-deposits-table-wrap {
    overflow-x: visible;
  }

  .active-deposits-table-wrap .table-deposits {
    display: block;
    width: 100%;
    margin: 0;
    background: transparent;
  }

  .active-deposits-table-wrap .table-deposits thead,
  .active-deposits-table-wrap .table-deposits colgroup {
    display: none;
  }

  .active-deposits-table-wrap .table-deposits tbody {
    display: block;
    padding: 0.55rem;
  }

  .active-deposits-table-wrap .table-deposits tbody tr {
    display: block;
    border: 1px solid #e3ecea;
    border-radius: 12px;
    background: #fff;
    box-shadow: var(--theme-shadow-sm);
    margin-bottom: 0.75rem;
    overflow: hidden;
  }

  .active-deposits-table-wrap .table-deposits tbody tr:last-child {
    margin-bottom: 0;
  }

  .active-deposits-table-wrap .table-deposits tbody td {
    display: block;
    width: 100%;
    padding: 0.55rem 0.85rem;
    border-bottom: 1px solid #edf2f1;
    text-align: left !important;
  }

  .active-deposits-table-wrap .table-deposits tbody td:last-child {
    border-bottom: 0;
  }

  .active-deposits-table-wrap .table-deposits tbody td::before {
    content: attr(data-label);
    display: block;
    margin-bottom: 0.25rem;
    color: #5f6f78;
    font-size: 0.72rem;
    font-weight: 700;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    line-height: 1.2;
  }

  .active-deposits-table-wrap .table-deposits .table-deposits__plan-cell {
    background: #f3faf7;
    border-bottom-color: #d7ebe5;
  }

  .active-deposits-table-wrap .table-deposits .table-deposits__plan-cell::before {
    color: #2f5f57;
    font-weight: 800;
  }

  .active-deposits-table-wrap .table-deposits tbody td > * {
    overflow-wrap: anywhere;
  }

  .active-deposits-table-wrap .table-deposits .table-deposits__progress-cell {
    min-width: 0 !important;
  }

  .active-deposits-table-wrap .table-deposits .table-deposits__actions-cell .small {
    display: block;
  }

  .active-deposits-table-wrap .table-deposits .table-deposits__actions-cell form {
    margin: 0;
  }

  .active-deposits-table-wrap .table-deposits .table-deposits__actions-cell .btn {
    width: 100%;
  }

  .active-deposits-table-wrap .table-deposits .active-deposits-empty-row {
    border: 0;
    box-shadow: none;
    background: transparent;
    margin-bottom: 0;
  }

  .active-deposits-table-wrap .table-deposits .active-deposits-empty {
    border-bottom: 0;
    padding: 1rem 0.85rem;
    text-align: center !important;
  }

  .active-deposits-table-wrap .table-deposits .active-deposits-empty::before {
    content: none;
  }
}

@media (max-width: 420px) {
  .deposit-calculator-table {
    font-size: 0.8rem;
  }

  .deposit-calculator-table td {
    padding: 0.26rem 0.34rem;
  }
}

.dashboard-sidebar-backdrop {
  position: fixed;
  inset: 0;
  background: rgba(10, 16, 22, 0.56);
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.22s ease;
  z-index: 1090;
}

.dashboard-sidebar-panel {
  border: 1px solid #dce7e5;
  border-radius: 16px;
  background: #152322;
  color: #f4ffff;
  padding: 0.75rem;
}

.dashboard-sidebar-panel .nav-link {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  border-radius: 10px;
  color: rgba(255, 255, 255, 0.9);
  padding: 0.6rem 0.65rem;
}

.dashboard-sidebar-panel .nav-link:hover,
.dashboard-sidebar-panel .nav-link.active {
  background: rgba(80, 210, 144, 0.18);
  color: #fff;
}

.sidebar-close {
  display: none;
}

@media (min-width: 940px) {
  .dashboard-shell {
    height: 100%;
    min-height: 100%;
  }

  .dashboard-shell__layout {
    display: grid;
    grid-template-columns: 280px minmax(0, 1fr);
    height: 100%;
    min-height: 100%;
    align-items: stretch;
    gap: 1rem;
    margin-left: 0;
    margin-right: 0;
  }

  .dashboard-shell__layout > .dashboard-shell__sidebar-col {
    align-self: stretch;
    display: flex;
  }

  .dashboard-shell__layout > .dashboard-shell__sidebar-col,
  .dashboard-shell__layout > .dashboard-shell__main-col {
    width: auto !important;
    max-width: none !important;
    flex: 0 0 auto !important;
  }

  .dashboard-shell__layout > .dashboard-shell__main-col {
    min-width: 0;
    padding: 1rem;
  }

  .dashboard-shell__main-col .mb-4 {
    margin-bottom: 1rem;
  }

  .dashboard-shell__main-col .row.g-4 {
    column-gap: 0;
    row-gap: 0.9rem;
  }

  .dashboard-shell__main-col .card-header {
    padding: 0.7rem 0.9rem;
  }

  .dashboard-shell__main-col .card-body {
    padding: 0.85rem 0.9rem;
  }

  .dashboard-shell__main-col .table th,
  .dashboard-shell__main-col .table td {
    padding: 0.55rem 0.6rem;
  }

  .dashboard-shell__main-col .form-control,
  .dashboard-shell__main-col .form-select,
  .dashboard-shell__main-col textarea {
    min-height: 40px;
    padding: 0.5rem 0.65rem;
  }

  .dashboard-shell__main-col .btn {
    min-height: 40px;
  }

  .dashboard-shell__sidebar-col .dashboard-sidebar-shell {
    display: flex;
    width: 100%;
    height: 100%;
    min-height: 100%;
  }

  .dashboard-shell__sidebar-col .dashboard-sidebar-panel {
    position: relative;
    top: auto;
    display: flex;
    flex-direction: column;
    width: 100%;
    max-height: none;
    overflow: visible;
    height: 100%;
    min-height: 100%;
  }

  .dashboard-shell__sidebar-col .dashboard-sidebar-panel > .p-3 {
    width: 100%;
  }

  .dashboard-sidebar-backdrop {
    display: none !important;
  }

  .dashboard-sidebar-toggle {
    display: none !important;
  }
}

@media (max-width: 939px) {
  .dashboard-shell__layout {
    margin-left: -0.75rem;
    margin-right: -0.75rem;
  }

  .dashboard-sidebar-backdrop.is-open {
    opacity: 1;
    pointer-events: auto;
  }

  .dashboard-sidebar-panel {
    position: fixed;
    top: 0;
    left: -300px;
    width: 280px;
    height: 100vh;
    overflow-y: auto;
    border-radius: 0;
    z-index: 1100;
    transition: left 0.22s ease;
  }

  .dashboard-sidebar-panel.is-open {
    left: 0;
  }

  .sidebar-close {
    display: inline-flex;
    position: absolute;
    right: 0.75rem;
    top: 0.75rem;
    width: 32px;
    height: 32px;
    border: 0;
    border-radius: 8px;
    background: rgba(255,255,255,0.14);
    color: #fff;
    align-items: center;
    justify-content: center;
  }

  .dashboard-sidebar-toggle {
    display: inline-flex !important;
  }
}

.auth-card {
  max-width: 560px;
  margin: 1.5rem auto;
  border: 1px solid #dce7e5;
  border-radius: 16px;
  background: #fff;
  box-shadow: var(--theme-shadow);
}

.auth-card-header {
  padding: 1rem 1.2rem;
  border-bottom: 1px solid #e8efee;
}

.auth-card-body {
  padding: 1.2rem;
}

.stats-hero,
.page-hero {
  position: relative;
  overflow: hidden;
  border-radius: 16px;
  color: #fff;
  background: linear-gradient(135deg, rgba(2, 131, 108, 0.9), rgba(64, 112, 117, 0.9));
  padding: 2rem 1.2rem;
  margin-bottom: 1.3rem;
}

.custom-page-content {
  border: 1px solid #e0e9e8;
  border-radius: 12px;
  padding: 1.2rem;
  background: #fff;
}

.blog-hero {
  margin-top: 1rem;
  border-radius: 16px;
  background: linear-gradient(120deg, #17353a, #275057);
  color: #fff;
}

.blog-hero .text-muted,
.blog-hero p {
  color: rgba(255, 255, 255, 0.85) !important;
}

.table-scroll-hint.is-scrollable::after {
  content: "Swipe to view more";
  display: block;
  font-size: 0.75rem;
  color: #6c7a84;
  padding-top: 0.35rem;
  text-align: right;
}

.extension-slot,
.extension-widget-slot {
  border: 1px dashed #d0dcda;
  border-radius: 10px;
  background: #f7fbfa;
  padding: 0.5rem;
}

.current-year {
  font-variant-numeric: tabular-nums;
}

.border-0 { border: 0 !important; }
.shadow-sm { box-shadow: var(--theme-shadow-sm) !important; }
.font-monospace { font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", "Courier New", monospace; }
.text-break { word-break: break-word; }
.opacity-75 { opacity: 0.75; }
.display-4 { font-size: 2.1rem; }
.display-6 { font-size: 1.25rem; }
.fs-1 { font-size: 2.2rem; }
.fs-3 { font-size: 1.4rem; }
.fs-4 { font-size: 1.2rem; }
.fs-5 { font-size: 1.06rem; }
.fs-6 { font-size: 0.88rem; }

.nav-tabs {
  display: flex;
  flex-wrap: wrap;
  gap: 0.45rem;
  list-style: none;
  margin: 0 0 1rem;
  padding: 0;
}

.nav-tabs .nav-link {
  border: 1px solid #d5e1df;
  border-radius: 10px;
  padding: 0.45rem 0.75rem;
  color: #32404e;
  background: #fff;
}

.nav-tabs .nav-link.active {
  color: #fff;
  border-color: var(--theme-green-dark);
  background: var(--theme-green-dark);
}

.accordion {
  display: grid;
  gap: 0.7rem;
}

.accordion-item {
  border: 1px solid #dee8e6;
  border-radius: 12px;
  overflow: hidden;
  background: #fff;
}

.accordion-button {
  width: 100%;
  border: 0;
  text-align: left;
  background: #f8fcfb;
  color: #20303e;
  font: inherit;
  font-weight: 600;
  padding: 0.9rem 1rem;
  cursor: pointer;
}

.accordion-button.collapsed {
  background: #fff;
}

.accordion-body {
  padding: 0.95rem 1rem 1.05rem;
}

.accordion-collapse {
  display: none;
}

.accordion-collapse.show {
  display: block;
}

.modal {
  position: fixed;
  inset: 0;
  display: none;
  background: rgba(8, 14, 20, 0.6);
  z-index: 2500;
  padding: 1rem;
  overflow-y: auto;
}

.modal.is-open {
  display: flex;
  align-items: center;
  justify-content: center;
}

.modal-dialog {
  width: min(540px, 96vw);
}

.modal-content {
  border: 1px solid #d8e3e1;
  border-radius: 14px;
  background: #fff;
  box-shadow: var(--theme-shadow);
}

.modal-header,
.modal-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.6rem;
  padding: 0.8rem 1rem;
}

.modal-header {
  border-bottom: 1px solid #e8efee;
}

.modal-body {
  padding: 1rem;
}

.modal-footer {
  border-top: 1px solid #e8efee;
  justify-content: flex-end;
}

body.modal-open {
  overflow: hidden;
}
