﻿.input-group > .select2-container--bootstrap {
    width: 60%;
    font-size: 0.375rem;
    flex: 1 1 auto;
}

    .input-group > .select2-container--bootstrap .select2-selection--single {
        height: 100%;
        font-size: 0.3rem;
        line-height: inherit;
        padding: 0.5rem 1rem;
    }

th a {
    text-decoration: none;
    color: inherit;
}

/* Sortable header with flex inline alignment */
th.sortable .header-content {
    display: flex;
    align-items: center; /* vertically center text + icon */
    gap: 4px; /* space between chevron and text */
}

/* Chevron icon */
th.sortable .sort-icon {
    font-size: 0.75rem;
    color: #ccc;
    transition: transform 0.2s ease, color 0.2s ease;
    margin-right: 4px; /* left-aligned */
}

/* Ascending: chevron up */
th.sortable.asc .sort-icon {
    color: #007bff;
    transform: rotate(0deg);
}

/* Descending: chevron down */
th.sortable.desc .sort-icon {
    color: #007bff;
    transform: rotate(180deg);
}

/* Highlight sorted column header + rows */
th.sortable.active,
td.active {
    background-color: #e7f1ff !important;
    font-weight: 600;
}

.column-200 {
    width: 200px;
    min-width: 180px;
    max-width: 200px;
}

.column-700 {
    width: 700px;
    min-width: 600px;
    max-width: 400px;
}

.column-180 {
    width: 180px;
    min-width: 160px;
    max-width: 180px;
}

.column-150 {
    width: 150px;
    min-width: 130px;
    max-width: 150px;
}

.column-250 {
    width: 250px;
    min-width: 230px;
    max-width: 250px;
}

.column-300 {
    width: 300px;
    min-width: 250px;
    max-width: 300px;
}

.column-350 {
    width: 350px;
    min-width: 330px;
    max-width: 350px;
}
.column-400 {
    width: 400px;
    min-width: 450px;
    max-width: 400px;
}

/* Full-row data tables that preserve readable columns on narrow screens. */
.responsive-data-table-wrap {
    width: 100%;
    max-width: 100%;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
}

.responsive-data-table-wrap > .responsive-data-table {
    width: max-content;
    min-width: 100%;
    margin-bottom: 0;
}

.responsive-data-table th,
.responsive-data-table td {
    white-space: nowrap;
}

/* Column classes provide a baseline width; long/localized content may grow. */
.responsive-data-table th[class*="column-"],
.responsive-data-table td[class*="column-"] {
    max-width: none;
}

/* Shared visual standard for interactive ReportController result tables. */
html body table.table.report-standard-table > thead > tr > th {
    background: #4A9340 !important;
    color: #fff !important;
}

.report-standard-table thead th .header-content {
    color: inherit !important;
}

html body table.table.report-standard-table > thead > tr > th.sortable.active {
    background: #327A2C !important;
    font-weight: 600;
}

.report-standard-table:not(.report-preserve-row-colors) td.active {
    background-color: #D8ECD4 !important;
    font-weight: 600;
}

.report-standard-table thead th.sortable.active .sort-icon {
    color: #C7E8C1;
}

/* Compact numeric identifier columns; longer localized headers may still grow. */
.report-standard-table .report-id-column {
    width: 110px;
    min-width: 100px;
}

.report-standard-table:not(.report-preserve-row-colors) tbody > tr:not(.report-totals-row):nth-child(odd) > td:not(.active) {
    background-color: #fff !important;
}

.report-standard-table:not(.report-preserve-row-colors) tbody > tr:not(.report-totals-row):nth-child(even) > td:not(.active) {
    background-color: #E8F5E4 !important;
}

.report-standard-table:not(.report-preserve-row-colors) tbody > tr:not(.report-totals-row):hover > td:not(.active) {
    background-color: #D9EED4 !important;
}

/* Rows for inactive/blocked records (e.g. blocked users); overrides the striping above. */
.report-standard-table:not(.report-preserve-row-colors) tbody > tr.report-row-blocked:not(.report-totals-row) > td:not(.active) {
    background-color: #FDECEC !important;
}

.report-standard-table:not(.report-preserve-row-colors) tbody > tr.report-row-blocked:not(.report-totals-row):hover > td:not(.active) {
    background-color: #F9DCDC !important;
}

.report-standard-table:not(.report-preserve-row-colors) tbody > tr.report-row-blocked > td.active {
    background-color: #F5D0D0 !important;
}

.report-standard-table tbody > tr.report-totals-row > td {
    background-color: #DCEFD8 !important;
    color: #234A20;
    font-weight: 700;
    border-top: 2px solid #5BA94E;
}

/* Report search action, aligned flush with the right edge of its input. */
.input-group.report-search-group > .form-control {
    height: auto;
    min-height: var(--udr-touch-target, 2.5rem);
    align-self: stretch;
}

.btn-report-search {
    background-color: #4A9340;
    border: none;
    color: #fff;
    font-weight: 600;
    border-top-left-radius: 0 !important;
    border-bottom-left-radius: 0 !important;
    border-top-right-radius: 8px !important;
    border-bottom-right-radius: 8px !important;
    box-shadow: 0 2px 6px rgba(0, 0, 0, .15);
    transition: all .2s ease-in-out;
}

/* Keep the rounded outer edge visible when export actions follow Search. */
.btn-report-search + .btn {
    margin-left: .35rem !important;
}

.btn-report-search:hover,
.btn-report-search:focus {
    background-color: #3F7E37;
    color: #fff;
    transform: translateY(-1px);
    box-shadow: 0 3px 8px rgba(0, 0, 0, .25);
}

.btn-report-search:active {
    background-color: #356D30;
    color: #fff;
    transform: translateY(0);
}

.sms-phone-entry.form-control.is-valid {
    background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' width='8' height='8' viewBox='0 0 8 8'%3e%3cpath fill='%2328a745' d='M2.3 6.73.6 4.53c-.4-1.04.46-1.4 1.1-.8l1.1 1.4 3.4-3.8c.6-.63 1.6-.27 1.2.7l-4 4.6c-.43.5-.8.4-1.1.1z'/%3e%3c/svg%3e") !important;
    background-repeat: no-repeat !important;
    background-position: right calc(.375em + .1875rem) center !important;
    background-size: calc(.75em + .375rem) calc(.75em + .375rem) !important;
    padding-right: calc(1.5em + .75rem) !important;
}

.sms-phone-entry.form-control.is-invalid {
    background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' fill='none' stroke='%23dc3545' viewBox='0 0 12 12'%3e%3ccircle cx='6' cy='6' r='4.5'/%3e%3cpath stroke-linejoin='round' d='M5.8 3.6h.4L6 6.5z'/%3e%3ccircle cx='6' cy='8.2' r='.6' fill='%23dc3545' stroke='none'/%3e%3c/svg%3e") !important;
    background-repeat: no-repeat !important;
    background-position: right calc(.375em + .1875rem) center !important;
    background-size: calc(.75em + .375rem) calc(.75em + .375rem) !important;
    padding-right: calc(1.5em + .75rem) !important;
}
