/* === Sobrescritura de Botones === */
.btn-primary {
    background-color: var(--bs-primary) !important;
    border-color: var(--bs-primary) !important;
    color: #fff !important;
}
.btn-primary:hover, .btn-primary:focus, .btn-primary:active {
    background-color: #fff !important;
    border-color: var(--bs-primary) !important;
    color: var(--bs-primary) !important;
}

.btn-secondary {
    background-color: var(--bs-secondary) !important;
    border-color: var(--bs-secondary) !important;
    color: #fff !important;
}
.btn-secondary:hover, .btn-secondary:focus, .btn-secondary:active {
    background-color: #fff !important;
    border-color: var(--bs-secondary) !important;
    color: var(--bs-secondary) !important;
}

.btn-success {
    background-color: var(--bs-success) !important;
    border-color: var(--bs-success) !important;
    color: #fff !important;
}
.btn-warning {
    background-color: var(--bs-warning) !important;
    border-color: var(--bs-warning) !important;
    color: #fff !important; /* A solicitud de área de comunicaciones de LaPortada */
}
.btn-danger {
    background-color: var(--bs-danger) !important;
    border-color: var(--bs-danger) !important;
    color: #fff !important;
}
.btn-info {
    background-color: var(--bs-info) !important;
    border-color: var(--bs-info) !important;
    color: #fff !important;
}

/* === Sobrescritura de Textos === */
.text-primary { color: var(--bs-primary) !important; }
.text-secondary { color: var(--bs-secondary) !important; }
.text-success { color: var(--bs-success) !important; }
.text-warning { color: var(--bs-warning) !important; }
.text-danger { color: var(--bs-danger) !important; }
.text-info { color: var(--bs-info) !important; }

/* Alerts -- Estos traen sus propios colores más suaves */
/*
.alert-primary { background-color: var(--bs-primary) !important; color: #fff !important; }
.alert-secondary { background-color: var(--bs-secondary) !important; color: #fff !important; }
.alert-success { background-color: var(--bs-success) !important; color: #fff !important; }
.alert-warning { background-color: var(--bs-warning) !important; color: #212529 !important; }
.alert-danger { background-color: var(--bs-danger) !important; color: #fff !important; }
.alert-info { background-color: var(--bs-info) !important; color: #fff !important; }
*/

/* === Personalización global de colores Bootstrap ===
    Estas reglas se aplican a cualquier elemento con clase bg-*, incluyendo:
    - Cards (header, body, etc.)
    - Badges
    - Botones genéricos si llevan bg-*
    - Etc.
*/
.bg-primary {
    background-color: var(--bs-primary) !important;
    color: #fff !important;
}

.bg-secondary {
    background-color: var(--bs-secondary) !important;
    color: #fff !important;
}

.bg-success {
    background-color: var(--bs-success) !important;
    color: #fff !important;
}

.bg-warning {
    background-color: var(--bs-warning) !important;
    color: #fff !important; /* A solicitud de área de comunicaciones de LaPortada */
}

.bg-danger {
    background-color: var(--bs-danger) !important;
    color: #fff !important;
}

.bg-info {
    background-color: var(--bs-info) !important;
    color: #fff !important;
}

/* Enlaces */
a.text-primary:hover,
a.text-primary:focus {
    color: var(--bs-primary) !important;
}
a.text-secondary:hover,
a.text-secondary:focus {
    color: var(--bs-secondary) !important;
}
a.text-success:hover,
a.text-success:focus {
    color: var(--bs-success) !important;
}
a.text-warning:hover,
a.text-warning:focus {
    color: var(--bs-warning) !important;
}
a.text-danger:hover,
a.text-danger:focus {
    color: var(--bs-danger) !important;
}
a.text-info:hover,
a.text-info:focus {
    color: var(--bs-info) !important;
}

/* Menú lateral colapsable (opción seleccionada) */
.menu-lateral .nav-link.active,
.menu-lateral .nav-item.active > .nav-link {
    background-color: var(--bs-primary) !important;
    color: #fff !important;
}

/* Título de las Tabs */
.nav-tabs .nav-link {
    color: var(--bs-primary) !important;
    border-color: var(--bs-primary) !important;
}
.nav-tabs .nav-link.active {
    background-color: var(--bs-primary) !important;
    color: #fff !important;
    border-color: var(--bs-primary) !important;
}
.nav-tabs .nav-link:hover {
    color: var(--bs-secondary) !important;
    border-color: var(--bs-secondary) !important;
}

/* === Borde de controles inputs del formulario al recibir foco === */
.form-control:focus,
.select2-container--bootstrap5 .select2-selection:focus,
.select2-container--bootstrap5.select2-container--focus .select2-selection {
    border-color: var(--bs-primary) !important;
    box-shadow: 0 0 0 0.25rem rgba(var(--bs-primary-rgb), 0.25) !important;
}
/* === Marco sombreado de controles inputs del formulario al recibir foco === */
.form-control:focus {
    border-color: var(--bs-primary) !important;
    box-shadow: 0 0 0 0.25rem rgba(var(--bs-primary-rgb), 0.25) !important;
}

