.salary-page .result {
  background: #f9fbfd;
  border: 1px solid #e5eaf0;
  border-radius: 10px;
  padding: 14px 16px;
}

.salary-page .result-row {
  display: flex;
  justify-content: space-between;
  margin-bottom: 6px;
  font-size: 0.95rem;
}

.salary-page .section-title {
  font-size: 1.05rem;
}

/* ===== Mobile button visibility fix ===== */
@media (max-width: 768px) {
  .tool-action-wrap {
    display: block !important;
    width: 100%;
    margin-top: 12px;
  }

  .tool-action-wrap .btn {
    width: 100%;
    display: block;
  }
}

.salary-page .tool-action-wrap .btn {
  background: #0d6efd; /* Bootstrap primary */
  color: #fff;
  border-radius: 8px;
}

.salary-page .tool-action-wrap .btn:hover {
  background: #0b5ed7;
}
/* ===== Mobile sticky Calculate button ===== */
@media (max-width: 768px) {
  .mobile-sticky-action {
    position: sticky;
    bottom: 12px;
    z-index: 20;
    background: #fff;
    padding: 10px 0;
  }

  .mobile-sticky-action .btn {
    width: 100%;
    border-radius: 10px;
  }
}

/* ===== FIX mobile clipping of action buttons ===== */
@media (max-width: 768px) {
  .salary-page main,
  .salary-page .tool-panel,
  .salary-page .card {
    height: auto !important;
    max-height: none !important;
    overflow: visible !important;
  }
}

@media (max-width: 768px) {
  .tool-action-wrap {
    position: static !important;
  }
}

.salary-page .table-success th {
  background-color: #d1e7dd;
}

.salary-page .table-success th:last-child {
  font-size: 1.2rem;
}

/* Force right alignment for all amount columns */
.salary-page table td.text-end,
.salary-page table th.text-end {
  text-align: right !important;
}

/* Any table second / fourth column = amount */
.salary-page table td:nth-child(2),
.salary-page table td:nth-child(4),
.salary-page table th:nth-child(2),
.salary-page table th:nth-child(4) {
  text-align: right;
}

.tax-chart-wrap {
  max-width: 420px;
  margin: 0 auto;
}

.tax-chart-wrap canvas {
  max-height: 260px !important;
}

.salary-page table td:last-child,
.salary-page table th:last-child {
  text-align: right;
}

#taxChart {
  max-width: 420px;
  max-height: 260px;
  margin: 20px auto;
  display: block;
}


@media (max-width: 576px) {
  .salary-page table {
    font-size: 0.9rem;
  }

  .salary-page table tr th,
  .salary-page table tr td {
    display: block;
    width: 100%;
  }

  .salary-page table tr td.text-end,
  .salary-page table tr th.text-end {
    text-align: right !important;
  }

  .salary-page table tr {
    border-bottom: 1px solid #e5eaf0;
    padding: 6px 0;
  }

  .salary-page table tr:first-child {
    display: none; /* hide 4-col header row */
  }

  .salary-page table tr.table-success td,
  .salary-page table tr.table-success th {
    font-size: 1rem;
  }
}

.salary-page .table td:last-child {
  text-align: right;
  font-weight: 500;
}

.tax-chart-wrap {
  max-width: 420px;
  height: 260px;
  margin: 0 auto;
}

@media (max-width: 576px) {
  .tax-chart-wrap {
    height: 220px;
  }
}

table, tr, td, th {
  page-break-inside: avoid;
}
