.card {
    border-radius: 14px;
}

.card > .card-header:first-child {
    border-top-left-radius: 14px;
    border-top-right-radius: 14px;
}

.card > .card-footer:last-child {
    border-bottom-left-radius: 14px;
    border-bottom-right-radius: 14px;
}

.house-panel,
.dashboard-stat-card,
.dashboard-panel {
    border: 0;
    border-radius: 18px;
    box-shadow: 0 14px 32px rgba(15, 23, 42, 0.08);
}

.table-card {
    position: relative;
}

.house-toolbar {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 0.75rem;
}

.house-toolbar-actions {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.75rem;
}

.cash-book-action-btn,
.cash-book-action-btn:hover,
.cash-book-action-btn:focus,
.cash-book-action-btn:active {
    min-height: 42px;
    padding: 0.7rem 1.15rem;
    border: 0 !important;
    border-radius: 999px;
    color: #fff !important;
    font-weight: 700;
    letter-spacing: 0.01em;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    white-space: nowrap;
    text-decoration: none;
    line-height: 1.2;
    box-shadow: none;
}

.cash-book-print-btn {
    background: linear-gradient(135deg, #b13d2f 0%, #d45545 100%) !important;
    box-shadow: 0 10px 24px rgba(177, 61, 47, 0.2) !important;
}

.cash-book-print-btn:hover,
.cash-book-print-btn:focus {
    color: #fff !important;
    background: linear-gradient(135deg, #9d3226 0%, #c64739 100%) !important;
    box-shadow: 0 12px 28px rgba(177, 61, 47, 0.24) !important;
}

.cash-book-print-btn:disabled,
.cash-book-print-btn.disabled {
    color: #fff;
    background: linear-gradient(135deg, #b13d2f 0%, #d45545 100%) !important;
    box-shadow: 0 10px 24px rgba(177, 61, 47, 0.2) !important;
    opacity: 1;
}

.cash-book-print-btn.is-disabled,
.cash-book-print-btn[aria-disabled="true"] {
    color: #fff;
    background: linear-gradient(135deg, #b13d2f 0%, #d45545 100%) !important;
    box-shadow: 0 10px 24px rgba(177, 61, 47, 0.2) !important;
    opacity: 1;
}

.mobile-card-action-group {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
}

.mobile-card-action {
    border-radius: 999px;
    padding: 0.625rem 1rem;
    font-size: 0.9rem;
    line-height: 1.2;
}

.house-toolbar-copy p {
    margin: 0.2rem 0 0;
    color: #64748b;
    font-size: 0.9rem;
}

.module-stats-row {
    --bs-gutter-y: 1rem;
}

.house-datatable-wrap {
    padding: 1rem 1rem 0.85rem;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
}

.house-datatable-wrap .dataTables_wrapper {
    position: relative;
}

.house-datatable-wrap .dataTables_wrapper .dataTables_processing {
    top: 5.25rem;
    left: 50%;
    width: auto;
    min-width: 220px;
    margin: 0;
    padding: 0.85rem 1rem;
    transform: translateX(-50%);
    border: 1px solid #dbe3ef;
    border-radius: 16px;
    background: rgba(255, 255, 255, 0.96);
    box-shadow: 0 16px 32px rgba(15, 23, 42, 0.12);
}

.house-datatable-wrap .dataTables_wrapper .row {
    --bs-gutter-x: 0.9rem;
    --bs-gutter-y: 0.65rem;
    align-items: center;
}

.house-datatable-wrap .dataTables_wrapper .row:first-child,
.house-datatable-wrap .dataTables_wrapper .row:last-child {
    margin-left: 0;
    margin-right: 0;
}

.house-datatable-wrap .dataTables_wrapper .row:first-child > div,
.house-datatable-wrap .dataTables_wrapper .row:last-child > div {
    padding-left: 0;
    padding-right: 0;
}

.house-datatable-wrap .dataTables_wrapper .dataTables_filter input,
.house-datatable-wrap .dataTables_wrapper .dataTables_length select,
.house-modal-form .form-control,
.house-modal-form .form-select {
    height: 40px;
    min-height: 40px;
    border-radius: 12px;
    border: 1px solid #dbe3ef;
    padding: 0.5rem 0.9rem;
    font-size: 0.9rem;
    line-height: 1.2;
    box-shadow: none;
}

.house-datatable-wrap .dataTables_wrapper .dataTables_length,
.house-datatable-wrap .dataTables_wrapper .dataTables_filter,
.house-datatable-wrap .dataTables_wrapper .dataTables_info,
.house-datatable-wrap .dataTables_wrapper .dataTables_paginate {
    display: flex;
    align-items: center;
    min-height: 40px;
    margin: 0;
}

.house-datatable-wrap .dataTables_wrapper .dataTables_filter input:focus,
.house-datatable-wrap .dataTables_wrapper .dataTables_length select:focus,
.house-modal-form .form-control:focus,
.house-modal-form .form-select:focus {
    border-color: #60a5fa;
    box-shadow: 0 0 0 0.2rem rgba(96, 165, 250, 0.12);
}

.house-datatable-wrap .dataTables_filter label,
.house-datatable-wrap .dataTables_length label {
    display: inline-flex;
    align-items: center;
    gap: 0.6rem;
    color: #475569;
    font-size: 0.85rem;
    font-weight: 500;
    margin: 0;
    white-space: nowrap;
}

.house-datatable-wrap .dataTables_wrapper .dataTables_filter {
    justify-content: flex-end;
}

.house-datatable-wrap .dataTables_wrapper .dataTables_length {
    justify-content: flex-start;
}

.house-datatable-wrap .dataTables_wrapper .dataTables_filter input {
    width: 320px;
    max-width: 100%;
    margin-left: 0;
}

.house-datatable-wrap .dataTables_wrapper .dataTables_length select {
    min-width: 74px;
    padding-right: 2rem;
    margin: 0;
}

.house-datatable-wrap table.dataTable thead th {
    border-bottom: 1px solid #e2e8f0;
    color: #475569;
    font-size: 0.78rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.04em;
    white-space: nowrap;
}

.house-datatable-wrap table.dataTable tbody td {
    vertical-align: middle;
}

.house-datatable-wrap .dataTables_wrapper .dataTables_info {
    color: #64748b;
    font-size: 0.84rem;
    padding-top: 0;
}

.house-datatable-wrap .dataTables_wrapper .dataTables_paginate {
    justify-content: flex-end;
    padding-top: 0;
}

.house-datatable-wrap .dataTables_wrapper .pagination {
    margin: 0;
    gap: 0.35rem;
}

.house-datatable-wrap .dataTables_wrapper .page-link {
    min-width: 36px;
    height: 36px;
    border: 1px solid #dbe3ef;
    border-radius: 10px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0 0.8rem;
    color: #475569;
    box-shadow: none;
}

.house-datatable-wrap .dataTables_wrapper .page-item.active .page-link {
    background-color: #2563eb;
    border-color: #2563eb;
    color: #fff;
}

.house-datatable-wrap .dataTables_wrapper .page-item.disabled .page-link {
    color: #94a3b8;
    background-color: #f8fafc;
    border-color: #e2e8f0;
}

.house-modal-form .form-label {
    margin-bottom: 0.35rem;
    color: #475569;
    font-size: 0.8rem;
    font-weight: 600;
}

.house-modal-form textarea.form-control {
    height: auto;
    min-height: auto;
    padding-top: 0.7rem;
    padding-bottom: 0.7rem;
    line-height: 1.45;
    resize: vertical;
}

.house-modal-form #address {
    min-height: 102px;
}

.house-modal-form #notes {
    min-height: 78px;
}

.house-modal .modal-content {
    display: flex;
    flex-direction: column;
    border: 0;
    border-radius: 20px;
    box-shadow: 0 24px 60px rgba(15, 23, 42, 0.18);
}

.house-modal .house-modal-form {
    display: flex;
    flex: 1 1 auto;
    flex-direction: column;
    min-height: 0;
}

.house-modal .modal-header,
.house-modal .modal-footer {
    padding: 1rem 1.1rem;
}

.house-modal .modal-header {
    background: #f8fafc;
    border-bottom: 1px solid #e2e8f0;
}

.house-modal .modal-body {
    flex: 1 1 auto;
    min-height: 0;
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
    padding: 0.35rem 1.1rem 1.1rem;
    background: #ffffff;
}

.house-modal .modal-footer {
    gap: 0.5rem;
    flex-wrap: wrap;
    background: #fbfdff;
    border-top: 1px solid #e2e8f0;
}

.house-modal .modal-title {
    font-size: 1rem;
    font-weight: 600;
}

.house-modal .btn,
.house-toolbar .btn {
    border-radius: 12px;
    padding: 0.5rem 0.95rem;
    font-size: 0.9rem;
}

.mobile-card-action,
.house-toolbar .btn.mobile-card-action {
    border-radius: 999px;
    padding: 0.625rem 1rem;
    font-size: 0.9rem;
    line-height: 1.2;
}

.house-modal .modal-footer .btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
}

.house-action-btn {
    width: 34px;
    height: 34px;
    border-radius: 999px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0;
}

.house-action-btn i {
    font-size: 0.95rem;
}

.house-modal-loading {
    position: fixed;
    inset: 0;
    z-index: 1080;
    display: none;
    align-items: center;
    justify-content: center;
    background: rgba(255, 255, 255, 0.45);
    backdrop-filter: blur(1px);
}

.house-modal-loading.is-visible {
    display: flex;
}

.house-modal-loading-box {
    min-width: 160px;
    border: 1px solid #e2e8f0;
    border-radius: 16px;
    background: rgba(255, 255, 255, 0.96);
    box-shadow: 0 18px 40px rgba(15, 23, 42, 0.12);
    padding: 1rem 1.1rem;
    text-align: center;
}

@media (max-width: 767.98px) {
    .house-toolbar {
        align-items: stretch;
    }

    .house-toolbar-copy,
    .house-toolbar-actions {
        width: 100%;
    }

    .house-toolbar .master-add-button {
        display: flex !important;
        width: 100%;
        justify-content: center;
    }

    .mobile-card-action-group {
        width: 100%;
    }

    .mobile-card-action {
        display: flex !important;
        width: 100%;
        justify-content: center;
    }

    .transaction-filter-actions {
        flex-direction: column;
    }

    .transaction-filter-actions .transaction-filter-button {
        width: 100%;
        flex: 0 0 100%;
    }

    .house-modal .modal-dialog {
        margin: 0.5rem;
    }

    .house-modal .modal-content {
        max-height: calc(100vh - 1rem);
    }

    .house-modal .modal-body {
        padding-bottom: 1rem;
    }

    .house-modal .table-responsive {
        overflow-x: auto;
    }

    .house-modal .modal-footer {
        position: sticky;
        bottom: 0;
        background: var(--bs-body-bg, #fff);
        border-top: 1px solid var(--bs-border-color, #dee2e6);
        box-shadow: 0 -6px 18px rgba(0, 0, 0, 0.06);
        padding-bottom: calc(0.75rem + env(safe-area-inset-bottom, 0px));
    }

    .house-modal .modal-footer .btn {
        flex: 1 1 100%;
        width: 100%;
    }
}

.house-modal-loading-box .spinner-border {
    width: 1.6rem;
    height: 1.6rem;
    border-width: 0.18em;
}

.house-modal-loading-box p,
.report-loading-box p {
    margin: 0.65rem 0 0;
    color: #475569;
    font-size: 0.86rem;
    font-weight: 500;
}

.expense-toolbar-actions {
    display: flex;
    flex-wrap: wrap;
    align-items: flex-end;
    justify-content: flex-end;
    gap: 0.75rem;
}

.expense-period-filter {
    display: flex;
    flex-wrap: wrap;
    align-items: flex-end;
    gap: 0.75rem;
    padding: 0.75rem 0.9rem;
    border: 1px solid #e2e8f0;
    border-radius: 16px;
    background: #f8fafc;
}

.expense-period-field {
    min-width: 110px;
}

.expense-period-field .form-label {
    margin-bottom: 0.35rem;
    color: #64748b;
    font-size: 0.76rem;
    font-weight: 600;
}

.expense-period-field .form-select {
    min-width: 110px;
    height: 40px;
    border-radius: 12px;
    border: 1px solid #dbe3ef;
    box-shadow: none;
}

.report-panel {
    border-radius: 18px;
}

.report-filter-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 1rem;
    align-items: end;
}

.report-filter-grid .form-label {
    margin-bottom: 0.35rem;
    color: #475569;
    font-size: 0.8rem;
    font-weight: 600;
}

.report-filter-grid .form-control,
.report-filter-grid .form-select {
    height: 40px;
    min-height: 40px;
    border-radius: 12px;
    border: 1px solid #dbe3ef;
    font-size: 0.9rem;
    box-shadow: none;
}

.report-filter-grid .form-control {
    padding: 0.5rem 0.9rem;
}

.report-filter-grid .form-select {
    padding: 0.5rem 2.2rem 0.5rem 0.9rem;
}

.report-filter-grid .form-control:focus,
.report-filter-grid .form-select:focus {
    border-color: #60a5fa;
    box-shadow: 0 0 0 0.2rem rgba(96, 165, 250, 0.12);
}

.report-filter-grid-compact {
    grid-template-columns: repeat(3, minmax(0, 1fr));
}

.report-filter-actions {
    display: flex;
    align-items: end;
    justify-content: flex-start;
    min-height: 40px;
}

.report-summary-breakdown {
    display: grid;
    gap: 0.2rem;
}

.report-summary-breakdown-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.75rem;
}

.report-summary-breakdown-label {
    color: var(--bs-secondary-color, #6c757d);
}

.report-summary-breakdown-value {
    margin-left: auto;
    text-align: right;
    font-weight: 600;
    color: var(--bs-emphasis-color, #212529);
    font-variant-numeric: tabular-nums;
}

.report-view-btn,
.report-print-btn {
    border-radius: 999px;
}

.report-view-btn {
    width: 100%;
    justify-content: center;
}

.report-print-btn {
    padding-inline: 1.15rem;
    box-shadow: 0 12px 24px rgba(220, 53, 69, 0.18);
}

.report-print-btn:disabled {
    box-shadow: none;
}

.report-loading {
    position: absolute;
    inset: 0;
    z-index: 4;
    display: none;
    align-items: center;
    justify-content: center;
    border-radius: 18px;
    background: rgba(255, 255, 255, 0.72);
    backdrop-filter: blur(1px);
}

.report-loading.is-visible {
    display: flex;
}

.report-loading-box {
    min-width: 210px;
    padding: 1rem 1.15rem;
    border: 1px solid #e2e8f0;
    border-radius: 16px;
    background: rgba(255, 255, 255, 0.98);
    color: #0f172a;
    text-align: center;
    box-shadow: 0 18px 42px rgba(15, 23, 42, 0.12);
}

.report-loading-box .spinner-border {
    width: 1.55rem;
    height: 1.55rem;
    border-width: 0.18em;
}

.report-loading-box p {
    margin: 0.65rem 0 0;
    color: #475569;
    font-size: 0.86rem;
    font-weight: 500;
}

.report-print-sheet {
    color: #111827;
}

.report-print-head {
    margin-bottom: 12px;
}

.report-print-title {
    margin: 0 0 6px;
    font-size: 20px;
}

.report-print-meta {
    margin: 0 0 4px;
}

.report-print-meta:last-child {
    margin-bottom: 0;
}

.report-print-col-no {
    width: 42px;
}

.report-print-col-date {
    width: 92px;
}

.report-print-col-category {
    width: 160px;
}

.report-print-col-amount {
    width: 120px;
}

.report-print-col-notes {
    width: 180px;
}

.report-print-cell-center {
    text-align: center;
}

.report-print-cell-money {
    padding: 5px 8px;
}

.report-print-subtext {
    font-size: 11px;
    color: #666;
}

.report-print-footer-note {
    margin-top: 12px;
    font-size: 11px;
    color: #666;
}

.report-money-cell {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.75rem;
    width: 100%;
    min-width: 120px;
}

.report-money-prefix {
    flex: 0 0 auto;
    color: #475569;
    white-space: nowrap;
}

.report-money-value {
    flex: 1 1 auto;
    text-align: right;
    white-space: nowrap;
    font-variant-numeric: tabular-nums;
}

#expenseReportTable td:nth-child(4),
#expenseReportTable th:nth-child(4) {
    min-width: 280px;
}

#expenseReportTable td:nth-child(1),
#expenseReportTable td:nth-child(2),
#expenseReportTable td:nth-child(5),
#expenseReportTable th:nth-child(1),
#expenseReportTable th:nth-child(2),
#expenseReportTable th:nth-child(5) {
    white-space: nowrap;
}

.house-datatable-wrap table.dataTable tfoot th,
.house-datatable-wrap table.dataTable tfoot td {
    border-top: 2px solid #cbd5e1;
    background: #f8fafc;
    color: #0f172a;
    font-weight: 700;
}

.house-datatable-wrap table.dataTable tfoot .report-table-footer th,
.house-datatable-wrap table.dataTable tfoot .report-table-footer td {
    padding-top: 0.9rem;
    padding-bottom: 0.9rem;
}

.pc-sidebar .pc-navbar > .pc-item > .pc-link,
.pc-sidebar .pc-navbar > .pc-item > .pc-link .pc-mtext {
    font-size: 12px;
    line-height: 1.35;
}

.pc-sidebar .pc-navbar > .pc-item .pc-submenu .pc-link,
.pc-sidebar .pc-navbar > .pc-item .pc-submenu .pc-link .pc-mtext {
    font-size: 11px;
    line-height: 1.3;
}

.pc-sidebar .pc-navbar > .pc-item .pc-submenu .pc-item.pc-trigger > .pc-link,
.pc-sidebar .pc-navbar > .pc-item .pc-submenu .pc-item.active > .pc-link {
    font-weight: 700;
}

.pc-sidebar .pc-navbar > .pc-item .pc-submenu .pc-item > .pc-link:after {
    display: none !important;
}

.pc-sidebar .m-header .b-brand img,
.pc-header .m-header .b-brand img {
    display: block;
    width: 156px;
    max-width: 156px;
    height: auto;
}

.dashboard-hero {
    position: relative;
    overflow: hidden;
    border: 0;
    border-radius: 20px;
    background:
        radial-gradient(circle at top right, rgba(255, 255, 255, 0.18), transparent 28%),
        linear-gradient(135deg, #1d4ed8, #2563eb 40%, #0f172a 100%);
    color: #fff;
}

.dashboard-hero::after {
    content: '';
    position: absolute;
    inset: auto -60px -60px auto;
    width: 220px;
    height: 220px;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.08);
}

.dashboard-hero .card-body {
    position: relative;
}

.dashboard-hero-loading {
    position: absolute;
    inset: 0;
    z-index: 5;
    display: none;
    align-items: center;
    justify-content: center;
    border-radius: 20px;
    background: rgba(15, 23, 42, 0.28);
    backdrop-filter: blur(2px);
}

.dashboard-hero-loading.is-visible {
    display: flex;
}

.dashboard-hero-loading-box {
    min-width: 220px;
    padding: 1rem 1.2rem;
    border: 1px solid rgba(255, 255, 255, 0.18);
    border-radius: 18px;
    background: rgba(15, 23, 42, 0.45);
    color: #fff;
    text-align: center;
    box-shadow: 0 18px 42px rgba(15, 23, 42, 0.22);
}

.dashboard-hero .hero-chip {
    display: inline-flex;
    align-items: center;
    gap: 0.45rem;
    border: 1px solid rgba(255, 255, 255, 0.18);
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.08);
    padding: 0.45rem 0.85rem;
    font-size: 0.82rem;
    font-weight: 500;
}

.dashboard-year-filter {
    min-width: 150px;
}

.dashboard-year-filter-hero {
    display: grid;
    grid-template-columns: max-content minmax(140px, 170px);
    align-items: center;
    column-gap: 0.9rem;
    row-gap: 0.35rem;
    margin-left: auto;
    width: auto;
    max-width: none;
}

.dashboard-year-filter-label-wrap {
    display: flex;
    align-items: center;
    justify-content: flex-start;
    min-width: 0;
}

.dashboard-year-filter-input-wrap {
    min-width: 0;
}

.dashboard-year-filter .form-label {
    display: block;
    margin-bottom: 0 !important;
    white-space: nowrap;
    text-align: left;
    font-size: 0.78rem;
    font-weight: 600;
}

.dashboard-year-filter .form-select {
    min-width: 140px;
    width: 170px;
    height: 42px;
    border: 1px solid rgba(255, 255, 255, 0.18);
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.12);
    color: #fff;
    box-shadow: none;
    text-align: center;
    text-align-last: center;
}

.dashboard-year-filter .form-select:focus {
    border-color: rgba(255, 255, 255, 0.45);
    box-shadow: 0 0 0 0.2rem rgba(255, 255, 255, 0.12);
}

.dashboard-year-filter .form-select option {
    color: #0f172a;
}

.dashboard-hero-btn {
    display: inline-flex;
    align-items: center;
    gap: 0.55rem;
    border-radius: 999px;
    padding: 0.72rem 1.2rem;
    font-weight: 600;
    box-shadow: 0 16px 32px rgba(15, 23, 42, 0.12);
}

.dashboard-hero-cta-group {
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem;
}

.dashboard-hero-cta-btn {
    width: 100%;
    justify-content: center;
}

.dashboard-hero-inline-stats {
    display: grid;
    grid-template-columns: repeat(3, minmax(180px, 1fr));
    gap: 0.85rem;
    width: 100%;
    max-width: 100%;
}

.dashboard-hero-inline-stat {
    display: flex;
    flex-direction: column;
    gap: 0.55rem;
    padding: 0.9rem 1rem;
    border: 1px solid rgba(255, 255, 255, 0.14);
    border-radius: 18px;
    background: rgba(255, 255, 255, 0.08);
    backdrop-filter: blur(1px);
}

.dashboard-hero-inline-head {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 0.75rem;
}

.dashboard-hero-inline-stat .label {
    display: block;
    color: rgba(255, 255, 255, 0.72);
    font-size: 0.76rem;
    font-weight: 600;
}

.dashboard-hero-inline-stat .icon {
    flex: 0 0 auto;
    color: rgba(255, 255, 255, 0.2);
    font-size: 2rem;
    line-height: 1;
}

.dashboard-hero-inline-stat .value {
    color: #fff;
    font-size: 1.85rem;
    font-weight: 700;
    line-height: 1.2;
    font-variant-numeric: tabular-nums;
    text-align: right;
    margin-left: auto;
    width: 100%;
}

.dashboard-hero-inline-stat .meta {
    color: rgba(255, 255, 255, 0.72);
    font-size: 0.8rem;
    font-weight: 600;
    text-align: right;
}

.dashboard-hero-inline-stat-outstanding {
    min-height: 100%;
}

@media (max-width: 1399.98px) {
    .dashboard-hero-inline-stats {
        grid-template-columns: repeat(2, minmax(180px, 1fr));
    }

    .dashboard-hero-inline-stat-outstanding {
        grid-column: 1 / -1;
    }
}

.dashboard-hero-stats-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 0.75rem;
}

.dashboard-hero-mini-card {
    height: 100%;
    padding: 0.85rem 0.95rem !important;
}

.dashboard-hero-mini-card-wide {
    grid-column: 1 / -1;
}

.hero-mini-value {
    font-size: clamp(1.15rem, 1rem + 0.8vw, 1.75rem);
    font-weight: 700;
    line-height: 1.15;
}

.hero-mini-label {
    display: inline-flex !important;
    align-items: center;
    gap: 0.35rem;
}

.hero-mini-label i {
    font-size: 0.85rem;
    opacity: 0.8;
    cursor: help;
}

.hero-mini-link {
    color: inherit;
    text-decoration: none !important;
    display: inline-block;
    width: 100%;
}

.hero-mini-link:hover,
.hero-mini-link:focus,
.hero-mini-link:active {
    color: inherit;
    text-decoration: none !important;
}

.hero-mini-money,
.dashboard-money-value {
    display: flex;
    align-items: flex-start;
    justify-content: flex-end;
    min-width: 0;
    width: 100%;
    text-align: right;
}

.hero-mini-money .prefix,
.dashboard-money-value .prefix {
    flex: 0 0 auto;
    font-size: 0.95rem;
    font-weight: 700;
    line-height: 1.35;
}

.hero-mini-money .amount,
.dashboard-money-value .amount {
    min-width: 0;
    overflow-wrap: anywhere;
    word-break: break-word;
    font-variant-numeric: tabular-nums;
    font-size: clamp(1rem, 0.9rem + 0.65vw, 1.7rem);
    font-weight: 700;
    line-height: 1.15;
    width: 100%;
    text-align: right;
}

.hero-mini-money.is-stacked {
    flex-direction: column;
    align-items: stretch;
    gap: 0.15rem;
}

.hero-mini-money.is-stacked .prefix {
    font-size: 0.88rem;
    line-height: 1;
}

.hero-mini-money.is-stacked .amount {
    font-size: clamp(1.15rem, 1rem + 0.75vw, 1.95rem);
}

.dashboard-stat-icon {
    width: 52px;
    height: 52px;
    border-radius: 16px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 1.35rem;
}

.dashboard-soft-primary { background: rgba(37, 99, 235, 0.12); color: #2563eb; }
.dashboard-soft-success { background: rgba(34, 197, 94, 0.12); color: #16a34a; }
.dashboard-soft-warning { background: rgba(245, 158, 11, 0.14); color: #d97706; }
.dashboard-soft-danger { background: rgba(239, 68, 68, 0.12); color: #dc2626; }

.dashboard-count-value {
    font-size: clamp(1.2rem, 1rem + 0.8vw, 1.8rem);
    font-weight: 700;
    line-height: 1.15;
    color: #0f172a;
    font-variant-numeric: tabular-nums;
}

.dashboard-outstanding-box {
    border: 1px solid #fecaca;
    border-radius: 20px;
    background: linear-gradient(135deg, #fff1f2 0%, #ffe4e6 100%);
    padding: 1.15rem 1.2rem;
}

.dashboard-money-value.is-outstanding .amount,
.dashboard-money-value.is-outstanding .prefix {
    color: #b91c1c;
}

.auth-form {
    width: min(100%, 460px);
}

.app-mobile-header-copy {
    min-width: 0;
    display: flex;
    flex-direction: column;
    justify-content: center;
    gap: 0.1rem;
    margin-left: 0.25rem;
}

.app-mobile-header-copy strong {
    display: block;
    color: #0f172a;
    font-size: 0.94rem;
    font-weight: 700;
    line-height: 1.2;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.app-mobile-header-eyebrow,
.app-mobile-menu-eyebrow {
    display: inline-flex;
    align-items: center;
    color: #64748b;
    font-size: 0.68rem;
    font-weight: 700;
    line-height: 1.2;
    letter-spacing: 0.05em;
    text-transform: uppercase;
}

.app-mobile-bottom-nav {
    position: fixed;
    right: 0;
    bottom: 0;
    left: 0;
    z-index: 1035;
    padding: 0.55rem 0.75rem calc(0.55rem + env(safe-area-inset-bottom, 0px));
    background: linear-gradient(180deg, rgba(248, 250, 252, 0) 0%, rgba(248, 250, 252, 0.92) 28%, #f8fafc 100%);
    pointer-events: none;
}

.app-mobile-bottom-nav-inner {
    pointer-events: auto;
    display: grid;
    grid-template-columns: repeat(5, minmax(0, 1fr));
    gap: 0.45rem;
    padding: 0.45rem;
    border: 1px solid rgba(148, 163, 184, 0.16);
    border-radius: 24px;
    background: rgba(255, 255, 255, 0.96);
    box-shadow: 0 18px 45px rgba(15, 23, 42, 0.12);
    backdrop-filter: blur(14px);
}

.app-mobile-bottom-link {
    border: 0;
    background: transparent;
    color: #64748b;
    text-decoration: none;
    min-height: 56px;
    border-radius: 18px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 0.28rem;
    padding: 0.35rem 0.2rem;
    transition: background-color 0.2s ease, color 0.2s ease, transform 0.2s ease;
}

.app-mobile-bottom-link i {
    font-size: 1.1rem;
    line-height: 1;
}

.app-mobile-bottom-link span {
    font-size: 0.69rem;
    font-weight: 700;
    line-height: 1.15;
}

.app-mobile-bottom-link.is-active,
.app-mobile-bottom-link:focus,
.app-mobile-bottom-link:hover {
    color: #1d4ed8;
    background: #eff6ff;
    transform: translateY(-1px);
}

.app-mobile-bottom-link-menu {
    color: #0f172a;
    background: #f8fafc;
}

.app-mobile-menu-sheet {
    height: min(78vh, 640px);
    border-top-left-radius: 24px;
    border-top-right-radius: 24px;
    border: 0;
    box-shadow: 0 -18px 45px rgba(15, 23, 42, 0.14);
}

.app-mobile-menu-sheet .offcanvas-header {
    padding: 1rem 1rem 0.7rem;
    border-bottom: 1px solid #e2e8f0;
}

.app-mobile-menu-sheet .offcanvas-body {
    padding: 1rem 1rem calc(1rem + env(safe-area-inset-bottom, 0px));
    background: #f8fafc;
}

.app-mobile-shortcut-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 0.75rem;
    margin-bottom: 1rem;
}

.app-mobile-shortcut-card {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
    padding: 1rem;
    border: 1px solid #e2e8f0;
    border-radius: 18px;
    background: #fff;
    color: #0f172a;
    text-decoration: none;
    box-shadow: 0 10px 24px rgba(15, 23, 42, 0.05);
}

.app-mobile-shortcut-card i {
    width: 42px;
    height: 42px;
    border-radius: 14px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: #eff6ff;
    color: #1d4ed8;
    font-size: 1.15rem;
}

.app-mobile-shortcut-card span {
    font-size: 0.9rem;
    font-weight: 700;
    line-height: 1.3;
}

.app-mobile-shortcut-card.is-active {
    border-color: #bfdbfe;
    background: linear-gradient(135deg, #eff6ff 0%, #ffffff 100%);
}

.app-mobile-section-title {
    margin: 1rem 0 0.65rem;
    color: #475569;
    font-size: 0.76rem;
    font-weight: 700;
    letter-spacing: 0.04em;
    text-transform: uppercase;
}

.app-mobile-menu-list {
    border: 1px solid #e2e8f0;
    border-radius: 18px;
    overflow: hidden;
    background: #fff;
}

.app-mobile-menu-list .list-group-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.75rem;
    border-color: #eef2f7;
    padding: 0.95rem 1rem;
    color: #0f172a;
    font-weight: 600;
}

.app-mobile-menu-list .list-group-item i {
    color: #94a3b8;
}

.app-mobile-menu-list .list-group-item.active {
    border-color: #dbeafe;
    background: #eff6ff;
    color: #1d4ed8;
}

.app-mobile-section-nav {
    display: none;
}

.app-mobile-section-nav-label {
    color: #64748b;
    font-size: 0.72rem;
    font-weight: 700;
    line-height: 1.2;
    letter-spacing: 0.05em;
    text-transform: uppercase;
    padding: 0 1rem 0.45rem;
}

.app-mobile-section-nav-track {
    display: flex;
    gap: 0.5rem;
    overflow-x: auto;
    overflow-y: hidden;
    padding: 0 1rem 0.65rem;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
}

.app-mobile-section-nav-track::-webkit-scrollbar {
    display: none;
}

.app-mobile-section-pill {
    flex: 0 0 auto;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 38px;
    padding: 0.55rem 0.9rem;
    border: 1px solid #dbe3ef;
    border-radius: 999px;
    background: #fff;
    color: #475569;
    text-decoration: none;
    font-size: 0.8rem;
    font-weight: 700;
    white-space: nowrap;
    box-shadow: 0 8px 18px rgba(15, 23, 42, 0.05);
}

.app-mobile-section-pill.is-active {
    border-color: #bfdbfe;
    background: #eff6ff;
    color: #1d4ed8;
}

.auth-form .card {
    border: 0;
    border-radius: 24px;
    box-shadow: 0 24px 60px rgba(15, 23, 42, 0.16);
}

.auth-form .card-body {
    padding: 2rem;
}

.auth-main.v1#app-login-page {
    overflow: hidden;
    background:
        radial-gradient(circle at top left, rgba(255, 255, 255, 0.18), transparent 28%),
        radial-gradient(circle at right 18%, rgba(255, 255, 255, 0.16), transparent 22%),
        linear-gradient(155deg, #0f172a 0%, #1d4ed8 46%, #2563eb 100%);
}

.auth-main.v1#app-login-page::before,
.auth-main.v1#app-login-page::after {
    content: '';
    position: absolute;
    border-radius: 999px;
    pointer-events: none;
    opacity: 0.28;
}

.auth-main.v1#app-login-page::before {
    top: -72px;
    right: -48px;
    width: 220px;
    height: 220px;
    background: rgba(255, 255, 255, 0.12);
}

.auth-main.v1#app-login-page::after {
    bottom: -86px;
    left: -72px;
    width: 260px;
    height: 260px;
    background: rgba(191, 219, 254, 0.12);
}

.auth-main.v1#app-login-page .auth-wrapper {
    position: relative;
    z-index: 1;
    align-items: center;
    justify-content: center;
    padding: max(1.25rem, env(safe-area-inset-top, 0px)) 1rem max(1rem, env(safe-area-inset-bottom, 0px));
}

.auth-main.v1#app-login-page .auth-form {
    width: 100%;
    max-width: 560px;
    margin-inline: auto;
    display: flex;
    align-items: center;
    justify-content: center;
    flex: 0 1 auto;
}

.app-login-shell {
    width: min(100%, 460px);
    margin-inline: auto;
}

.login-brand {
    width: 118px;
    max-width: 100%;
    height: auto;
}

.login-hero {
    margin-bottom: 1.75rem;
    text-align: center;
}

.login-hero-copy {
    margin-top: 1rem;
}

.login-hero-copy h4 {
    margin-bottom: 0.4rem;
    font-size: 1.35rem;
    font-weight: 600;
}

.login-hero-copy p {
    margin-bottom: 0;
    color: #64748b;
    font-size: 0.92rem;
}

.login-password-group .form-control {
    border-right: 0;
    border-color: #dbe3ef;
    min-height: 46px;
}

.login-password-group .form-control:focus {
    border-right: 0;
    border-color: #60a5fa;
    box-shadow: none;
}

.password-toggle-btn {
    border: 1px solid #dbe3ef;
    border-left: 0;
    background: #fff;
    color: #64748b;
    min-height: 46px;
}

.password-toggle-btn:focus {
    box-shadow: none;
    border-color: #60a5fa;
}

.password-toggle-btn i {
    font-size: 1rem;
}

.auth-form .form-control {
    min-height: 46px;
    border-radius: 14px;
    border-color: #dbe3ef;
    padding-inline: 0.95rem;
}

.auth-form .form-control:focus {
    border-color: #60a5fa;
    box-shadow: 0 0 0 0.2rem rgba(96, 165, 250, 0.12);
}

.auth-form .btn-primary {
    min-height: 46px;
    border-radius: 14px;
    font-weight: 600;
}

.app-login-helptext {
    margin-top: 1rem;
    text-align: center;
    color: #64748b;
    font-size: 0.81rem;
    line-height: 1.5;
}

.generate-ipl-house-copy {
    overflow-wrap: anywhere;
    word-break: break-word;
}

.payment-header-side {
    width: min(100%, 320px);
}

.payment-inline-stat-card {
    border: 1px solid #dbe3ef;
    border-radius: 16px;
    background: #f8fafc;
    padding: 0.9rem 1rem;
}

.payment-inline-stat-card.is-outstanding {
    border-color: #f5c2c7;
    background: linear-gradient(135deg, #fff1f2 0%, #ffe4e6 100%);
    box-shadow: 0 10px 24px rgba(190, 24, 93, 0.08);
}

.payment-inline-stat-card .label {
    display: block;
    color: #64748b;
    font-size: 0.76rem;
    font-weight: 700;
    letter-spacing: 0.01em;
}

.payment-inline-stat-card .value {
    color: #0f172a;
    font-size: 1rem;
    font-weight: 700;
}

.payment-inline-stat-card.is-outstanding .label {
    color: #9f1239;
}

.payment-inline-stat-card.is-outstanding .value {
    color: #881337;
    font-size: 2rem;
    line-height: 1;
}

.payment-inline-stat-main {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
}

.payment-info-card .label {
    display: block;
    color: #64748b;
    font-size: 0.76rem;
    font-weight: 600;
    margin-bottom: 0.25rem;
}

.payment-bill-list {
    display: grid;
    gap: 0.8rem;
}

.payment-bill-card {
    border: 1px solid #dbe3ef;
    border-radius: 16px;
    background: #fff;
    padding: 0.95rem;
}

.payment-bill-head {
    display: flex;
    gap: 0.75rem;
    align-items: flex-start;
}

.payment-bill-check {
    padding-top: 0.15rem;
}

.payment-bill-check .form-check-input {
    width: 1.1rem;
    height: 1.1rem;
}

.payment-bill-body {
    flex: 1 1 auto;
    min-width: 0;
}

.payment-bill-topline {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 0.75rem;
}

.payment-bill-title {
    color: #0f172a;
    font-size: 0.94rem;
    font-weight: 700;
    line-height: 1.4;
}

.payment-bill-meta {
    color: #64748b;
    font-size: 0.8rem;
    line-height: 1.5;
    margin-top: 0.25rem;
}

.payment-bill-amount {
    text-align: right;
    white-space: nowrap;
}

.payment-bill-amount strong {
    display: block;
    color: #0f172a;
    font-size: 0.94rem;
}

.payment-bill-amount span {
    color: #64748b;
    font-size: 0.76rem;
}

.payment-bill-chips {
    display: flex;
    flex-wrap: wrap;
    gap: 0.4rem;
    margin-top: 0.65rem;
}

.payment-bill-chip {
    display: inline-flex;
    align-items: center;
    border-radius: 999px;
    padding: 0.28rem 0.62rem;
    background: #eef4ff;
    color: #1d4ed8;
    font-size: 0.74rem;
    font-weight: 600;
}

.payment-bill-footer {
    display: grid;
    grid-template-columns: 220px 1fr;
    gap: 0.75rem;
    margin-top: 0.85rem;
    padding-top: 0.85rem;
    border-top: 1px dashed #dbe3ef;
}

.payment-bill-footer .form-text {
    margin-top: 0.35rem;
}

.payment-empty-state {
    border: 1px dashed #cbd5e1;
    border-radius: 16px;
    background: #f8fafc;
    padding: 1rem;
    color: #64748b;
    font-size: 0.88rem;
    line-height: 1.55;
}

.payment-info-card .value {
    color: #0f172a;
    font-size: 1rem;
    font-weight: 700;
}

.payment-hint {
    margin-top: 0.75rem;
    color: #64748b;
    font-size: 0.8rem;
}

#paymentTable .payment-date-col {
    white-space: nowrap;
    width: 1%;
}

#paymentTable .payment-amount-col {
    white-space: nowrap;
    width: 1%;
}

@media (max-width: 767.98px) {
    body {
        background: #f8fafc;
    }

    .pc-header {
        top: 0;
        padding-top: env(safe-area-inset-top, 0px);
        background: rgba(255, 255, 255, 0.92);
        backdrop-filter: blur(16px);
    }

    .pc-header .header-wrapper {
        min-height: 64px;
        padding-inline: 0.85rem;
        gap: 0.35rem;
    }

    .pc-header .m-header {
        display: none;
    }

    .app-mobile-section-nav {
        display: block;
        position: sticky;
        top: calc(64px + env(safe-area-inset-top, 0px));
        z-index: 1029;
        padding-top: 0.55rem;
        background: linear-gradient(180deg, rgba(248, 250, 252, 0.98) 0%, rgba(248, 250, 252, 0.94) 100%);
        backdrop-filter: blur(14px);
    }

    .pc-container {
        padding-bottom: 6.5rem;
    }

    .pc-content {
        padding-bottom: 1rem;
    }

    .page-header-wrapper {
        margin-bottom: 1rem !important;
    }

    .page-breadcrumb-wrapper {
        display: none;
    }

    .page-header-card-wrapper .card {
        border-radius: 18px;
        box-shadow: 0 12px 28px rgba(15, 23, 42, 0.08) !important;
    }

    .page-header-card-wrapper .card-body {
        padding: 1rem;
    }

    .page-header-title h4 {
        font-size: 1.1rem;
    }

    .page-header-title p {
        font-size: 0.84rem;
    }

    .payment-header-side {
        width: 100%;
    }

    .payment-bill-footer {
        grid-template-columns: 1fr;
    }

    .payment-bill-head,
    .payment-bill-topline,
    .payment-section-head {
        flex-direction: column;
    }

    .payment-bill-amount {
        text-align: left;
    }

    .auth-form .card-body {
        padding: 1.5rem;
    }

    .auth-main.v1#app-login-page .auth-wrapper {
        min-height: 100dvh;
        padding-top: max(1rem, env(safe-area-inset-top, 0px));
        padding-bottom: max(1rem, env(safe-area-inset-bottom, 0px));
    }

    .app-login-shell {
        width: 100%;
    }

    .auth-form .card {
        border-radius: 22px;
        box-shadow: 0 18px 40px rgba(15, 23, 42, 0.14);
    }

    .auth-main.v1#app-login-page .auth-form .card {
        width: 100%;
        margin-left: 0;
        margin-right: 0;
    }

    .dashboard-year-filter {
        width: 100%;
    }

    .dashboard-year-filter-hero {
        grid-template-columns: 1fr;
        margin-left: 0;
        max-width: 100%;
        width: 100%;
    }

    .dashboard-year-filter-label-wrap,
    .dashboard-year-filter-input-wrap {
        width: 100%;
    }

    .dashboard-year-filter .form-select {
        width: 100%;
    }

    .dashboard-hero-stats-grid {
        grid-template-columns: 1fr;
    }

    .dashboard-hero-mini-card-wide {
        grid-column: auto;
    }

    .dashboard-hero-inline-stats {
        grid-template-columns: repeat(1, minmax(0, 1fr));
        max-width: 100%;
    }

    .dashboard-hero-inline-stat {
        align-items: flex-start;
        flex-direction: column;
        gap: 0.35rem;
    }

    .dashboard-hero-inline-head {
        width: 100%;
    }

    .dashboard-hero-inline-stat .value,
    .dashboard-hero-inline-stat .meta {
        text-align: left;
        margin-left: 0;
    }

    .login-brand {
        width: 104px;
    }

    .module-stats-row {
        --bs-gutter-x: 0.5rem;
        --bs-gutter-y: 0.15rem;
        margin-bottom: 0.25rem !important;
    }

    .house-datatable-wrap {
        padding-left: 0.85rem;
        padding-right: 0.85rem;
        overflow-x: auto;
        overflow-y: hidden;
    }

    .house-datatable-wrap .dataTables_wrapper {
        width: 100%;
    }

    .house-datatable-wrap .dataTables_wrapper .dataTables_processing {
        top: 6.5rem;
        min-width: 200px;
    }

    .house-datatable-wrap .dataTables_wrapper .row {
        --bs-gutter-x: 0.5rem;
    }

    .house-datatable-wrap .dataTables_wrapper .row > div {
        width: 100%;
        max-width: 100%;
        flex: 0 0 100%;
    }

    .house-datatable-wrap .dataTables_wrapper .dataTables_length,
    .house-datatable-wrap .dataTables_wrapper .dataTables_filter,
    .house-datatable-wrap .dataTables_wrapper .dataTables_info,
    .house-datatable-wrap .dataTables_wrapper .dataTables_paginate {
        justify-content: flex-start;
        width: 100%;
        min-height: auto;
    }

    .house-datatable-wrap .dataTables_wrapper .dataTables_filter input {
        width: 100%;
    }

    .house-datatable-wrap .dataTables_wrapper .dataTables_length label,
    .house-datatable-wrap .dataTables_wrapper .dataTables_filter label {
        width: 100%;
        white-space: normal;
        flex-wrap: wrap;
    }

    .house-datatable-wrap .dataTables_wrapper .dataTables_length select {
        min-width: 68px;
    }

    .house-datatable-wrap .dataTables_wrapper .dataTables_info {
        white-space: normal;
    }

    .house-datatable-wrap .dataTables_wrapper .dataTables_paginate {
        overflow-x: auto;
        overflow-y: hidden;
        padding-bottom: 0.2rem;
    }

    .house-datatable-wrap .dataTables_wrapper .pagination {
        flex-wrap: nowrap;
    }

    .house-datatable-wrap .dataTables_wrapper .page-link {
        min-width: 34px;
        height: 34px;
        padding: 0 0.7rem;
    }

    .expense-toolbar-actions {
        width: 100%;
        justify-content: stretch;
    }

    .expense-period-filter {
        width: 100%;
        padding: 0.75rem;
    }

    .expense-period-field {
        flex: 1 1 140px;
        min-width: 0;
    }

    .expense-period-field .form-select {
        width: 100%;
        min-width: 0;
    }

    .report-filter-grid {
        grid-template-columns: 1fr;
        gap: 0.85rem;
    }

    .report-filter-actions {
        min-height: 0;
    }

    .house-datatable-wrap table.dataTable {
        width: max-content !important;
        min-width: 100%;
    }
}

@media (max-width: 420px) {
    .auth-main.v1#app-login-page .auth-wrapper {
        padding-inline: 0.8rem;
    }

    .app-mobile-bottom-nav {
        padding-inline: 0.55rem;
    }

    .app-mobile-bottom-nav-inner {
        gap: 0.25rem;
        padding: 0.35rem;
    }

    .app-mobile-bottom-link span {
        font-size: 0.64rem;
    }

    .app-mobile-shortcut-grid {
        grid-template-columns: 1fr;
    }
}

@media (min-width: 992px) {
    .report-view-btn {
        width: auto;
    }

    .dashboard-hero-cta-btn {
        width: 300px;
    }
}
