/* ==========================================================================
   People & Drivers Module Styles (ASIModule.Client.People)
   Global rather than scoped: module .razor.css bundles are unreliable in production.
   All colors come from themes.css custom properties.
   ========================================================================== */

.people-module-container {
    display: flex;
    flex-direction: column;
    gap: 1rem;
    padding: 0.5rem 0;
    width: 100%;
}

.people-header {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.people-module-container .table-hover tbody tr:hover {
    background-color: var(--table-hover-bg, var(--bg-tertiary));
}

.people-module-container .badge-driver {
    background-color: var(--bs-success);
    color: var(--text-light);
    font-weight: 500;
}

/* Client-type and person-type badges.
   These use theme custom properties directly rather than Bootstrap's bg-* utilities:
   Bootstrap resolves .bg-info from --bs-info-rgb, which themes.css does not override,
   so .bg-info renders fixed cyan in every theme instead of the theme's info color. */
.people-module-container .badge-client-commercial {
    background-color: var(--bs-info);
    color: var(--text-light);
    font-weight: 500;
}

.people-module-container .badge-client-personal {
    background-color: var(--primary-color);
    color: var(--text-light);
    font-weight: 500;
}

.people-module-container .badge-person-type {
    background-color: var(--bg-tertiary);
    color: var(--text-primary);
    border: 1px solid var(--border-color);
    font-weight: 500;
}

.people-module-container .badge-primary-insured {
    background-color: var(--primary-color);
    color: var(--text-light);
    font-weight: 500;
}

/* Vehicle badge listing a vehicle a driver is assigned to. Rendered as a button so the vehicle's
   read-only details (including all drivers assigned to it) can be opened by clicking it, without
   having to edit the vehicle. */
.people-module-container .badge-assigned-vehicle {
    background-color: var(--bg-tertiary);
    color: var(--text-primary);
    border: 1px solid var(--border-color);
    font-weight: 500;
    cursor: pointer;
}

.people-module-container .badge-assigned-vehicle:hover,
.people-module-container .badge-assigned-vehicle:focus {
    background-color: var(--bg-secondary);
    border-color: var(--primary-color);
    color: var(--primary-color);
}

/* The principal (rated) driver star uses the theme's warning/gold color rather than
   inheriting the badge's --text-primary text color, so it reads as a gold star in every
   theme. Color comes from themes.css (--bs-warning); never hard-coded. */
.people-module-container .badge-assigned-vehicle-star {
    color: var(--bs-warning);
}

.people-module-container .people-filter-bar {
    background-color: var(--bg-secondary);
    border: 1px solid var(--border-color);
}

.people-module-container .input-group-text {
    background-color: var(--bg-primary);
    border-color: var(--border-color);
    color: var(--text-secondary);
}

.people-module-container .people-license-number {
    color: var(--text-primary);
}

.people-module-container .table-primary-subtle {
    background-color: var(--dialog-panel-active-bg, var(--bg-tertiary));
}

.people-module-container .border-dashed {
    border: 2px dashed var(--border-color) !important;
    background-color: var(--bg-secondary);
}

.people-module-container .required-field::after {
    content: " *";
    color: var(--bs-danger);
}
