/**
 * Member portal: denser spacing and typography across all logged-in pages.
 * Scoped under .portal-layout-compact (main app shell).
 */

.portal-layout-compact .page-container {
  padding-top: 0.5rem;
  padding-bottom: 0.75rem;
}

@media (min-width: 992px) {
  .portal-layout-compact .page-container {
    padding-top: 0.625rem;
  }
}

.portal-layout-compact .page-title-head {
  margin-bottom: 0.5rem !important;
}

.portal-layout-compact .page-title-head h4 {
  font-size: 1rem;
  line-height: 1.3;
}

.portal-layout-compact .page-title-head .fs-18 {
  font-size: 1rem !important;
}

.portal-layout-compact .breadcrumb {
  margin-top: 0.25rem !important;
  margin-bottom: 0 !important;
  font-size: 0.8125rem;
  padding: 0.25rem 0;
}

.portal-layout-compact .card {
  margin-bottom: 0.5rem;
}

.portal-layout-compact .card-header {
  padding: 0.45rem 0.65rem;
  min-height: 0;
}

.portal-layout-compact .card-header .header-title,
.portal-layout-compact .card-header h4.header-title {
  font-size: 0.9375rem;
  margin-bottom: 0;
}

.portal-layout-compact .card-body:not(.p-0) {
  padding: 0.55rem 0.65rem;
}

.portal-layout-compact .alert {
  margin-bottom: 0.5rem;
  padding: 0.45rem 0.65rem;
  font-size: 0.875rem;
}

.portal-layout-compact .alert .alert-heading {
  font-size: 0.9375rem;
  margin-bottom: 0.25rem;
}

.portal-layout-compact .table {
  font-size: 0.8125rem;
}

.portal-layout-compact .table th,
.portal-layout-compact .table td {
  padding: 0.35rem 0.45rem;
}

.portal-layout-compact .table thead th {
  font-size: 0.75rem;
  text-transform: none;
}

/* My Documents: fit all columns in the card without horizontal scroll */
.portal-layout-compact .portal-documents-table {
  table-layout: fixed;
}

.portal-layout-compact .portal-documents-table th,
.portal-layout-compact .portal-documents-table td {
  white-space: normal;
  overflow-wrap: anywhere;
  vertical-align: middle;
}

.portal-layout-compact .portal-documents-col-name {
  width: 52%;
}

.portal-layout-compact .portal-documents-col-date {
  width: 33%;
}

.portal-layout-compact .portal-documents-col-action {
  width: 15%;
}

.portal-layout-compact .form-label {
  margin-bottom: 0.2rem;
  font-size: 0.8125rem;
}

.portal-layout-compact .form-control,
.portal-layout-compact .form-select {
  padding: 0.35rem 0.5rem;
  font-size: 0.875rem;
}

.portal-layout-compact h5.text-primary {
  font-size: 0.9375rem !important;
  margin-bottom: 0.45rem !important;
}

.portal-layout-compact .card-body > h5:not(.header-title) {
  font-size: 0.9375rem;
  margin-bottom: 0.5rem;
}

.portal-layout-compact hr {
  margin: 0.55rem 0;
}

.portal-layout-compact .footer .row {
  font-size: 0.8125rem;
}

.portal-layout-compact .footer {
  padding-top: 0.5rem !important;
  padding-bottom: 0.5rem !important;
}

/* Common Bootstrap spacing blocks on portal pages */
.portal-layout-compact .row.mb-4 {
  margin-bottom: 0.65rem !important;
}

.portal-layout-compact .row.mb-3 {
  margin-bottom: 0.45rem !important;
}

.portal-layout-compact .mb-4 {
  margin-bottom: 0.65rem !important;
}

.portal-layout-compact .mb-3 {
  margin-bottom: 0.45rem !important;
}

.portal-layout-compact .my-4 {
  margin-top: 0.65rem !important;
  margin-bottom: 0.65rem !important;
}

.portal-layout-compact .my-3 {
  margin-top: 0.45rem !important;
  margin-bottom: 0.45rem !important;
}

.portal-layout-compact .mt-4 {
  margin-top: 0.65rem !important;
}

.portal-layout-compact .py-4 {
  padding-top: 0.65rem !important;
  padding-bottom: 0.65rem !important;
}

.portal-layout-compact .py-3 {
  padding-top: 0.45rem !important;
  padding-bottom: 0.45rem !important;
}

.portal-layout-compact .btn-sm {
  padding: 0.2rem 0.45rem;
  font-size: 0.8125rem;
}

/**
 * Standalone auth pages (login / forced change password)
 */
.portal-auth-compact .auth-full-page-content {
  padding: 1rem 1.25rem !important;
}

@media (min-width: 768px) {
  .portal-auth-compact .auth-full-page-content {
    padding: 1.25rem 1.5rem !important;
  }
}

.portal-auth-compact .auth-full-bg {
  padding-top: 1rem !important;
  padding-left: 1rem !important;
  padding-right: 1rem !important;
  padding-bottom: 1rem !important;
}

.portal-auth-compact .auth-full-bg .p-4 {
  padding: 0.75rem !important;
}

.portal-auth-compact .auth-logo img {
  height: 42px !important;
}

.portal-auth-compact h5.text-primary {
  font-size: 1rem;
}

.portal-auth-compact .mb-4.mb-md-5 {
  margin-bottom: 0.75rem !important;
}

.portal-auth-compact .mt-4 {
  margin-top: 0.75rem !important;
}

.portal-auth-compact .form-label {
  font-size: 0.8125rem;
  margin-bottom: 0.2rem;
}

.portal-auth-compact .form-control {
  padding: 0.35rem 0.5rem;
  font-size: 0.875rem;
}

.portal-auth-compact .alert {
  padding: 0.45rem 0.6rem;
  margin-bottom: 0.5rem;
  font-size: 0.875rem;
}
