/* Esto permite que los elementos colapsables respondan a clics en iOS */
.collapse {
    touch-action: manipulation;
    transition: height 0.35s ease;
}

.nombramiento-item.fade-in {
    animation: fadeIn 0.3s ease-in-out;
}


@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(-4px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.toggle-icon {
    transition: transform 0.3s ease;
}

.toggle-icon.rotated {
    transform: rotate(180deg); /* flecha hacia arriba */
}


@keyframes fadeSlideUp {
    from

{
    opacity: 0;
    transform: translateY(30px);
}

to {
    opacity: 1;
    transform: translateY(0);
}

}

.modal.fade .modal-dialog {
    transition: none; /* desactiva la animación default de Bootstrap */
    animation: fadeSlideUp 0.5s ease-out;
}

.highlight-animation {
    animation: flash 1s ease-in-out;
}

@keyframes flash {
    0% {
        background-color: yellow;
    }

    50% {
        background-color: transparent;
    }

    100% {
        background-color: yellow;
    }
}

.truncate-text {
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    display: inline-block;
    max-width: 100%;
}

.fade-out {
    opacity: 0;
    transition: opacity 0.5s ease-out;
}

.fade-in {
    opacity: 1;
    transition: opacity 0.5s ease-in;
}

.nombre-persona-btn {
    font-size: clamp(1.0rem, 2vw, 1.2rem);
    font-weight: normal;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    width: 100%;
    display: inline-block;
}

.avatar-persona {
    width: 40px;
    height: 40px;
    object-fit: cover;
    border-radius: 50%;
    border: 2px solid #dee2e6; /* gris claro */
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.avatar-persona:hover {
    transform: scale(1.1);
    box-shadow: 0 0 8px rgba(0, 123, 255, 0.5); /* un pequeño resplandor azul */
}

.input-small {
    max-width: 200px;
}

.input-medium {
    max-width: 300px;
}

#liveToast {
    position: fixed !important;
    top: 1rem !important; /* o 0 si lo quieres pegado al borde */
    left: 50% !important;
    transform: translateX(-50%) !important;
    z-index: 9999;
}

#toastMessage {
    text-align: center !important;
}

/* --- Checkbox discreto: solo borde y check en color de texto --- */
.form-check-input {
    -webkit-appearance: none;
    appearance: none;
    width: 1.1em;
    height: 1.1em;
    border: 1px solid currentColor;
    border-radius: 0.25rem;
    background: transparent;
    position: relative;
    vertical-align: middle;
    cursor: pointer;
}

    /* Cuando está marcado, mantén el fondo transparente */
    .form-check-input:checked {
        background: transparent;
    }

        /* Dibuja la “tilde” en color de texto */
        .form-check-input:checked::before {
            content: '';
            position: absolute;
            top: 0.18em;
            left: 0.35em;
            width: 0.25em;
            height: 0.6em;
            border: solid currentColor;
            border-width: 0 0.15em 0.15em 0;
            transform: rotate(45deg);
        }

/* Contenedor que aloja la imagen y el contenido */
.error-container {
    position: relative;
    min-height: 100vh;
    overflow: hidden;
    background-color: #1e1e2f;
}

/* Imagen detrás del contenido */
.error-bg-img {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    opacity: 1;
    z-index: 0;
    pointer-events: none;
}

/* Contenido encima de la imagen */
.error-wrapper {
    position: relative;
    z-index: 1;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    color: white;
    text-align: center;
    padding: 4rem 2rem;
    min-height: 100vh;
}

    .error-wrapper h1 {
        font-size: 4rem;
        margin-bottom: 1rem;
    }

    .error-wrapper p {
        font-size: 1.25rem;
        margin-bottom: 1rem;
    }

    .error-wrapper a {
        background-color: transparent;
        border: 1px solid white;
        color: white;
        padding: 0.5rem 1.5rem;
        text-decoration: none;
        border-radius: 5px;
        transition: background 0.3s;
    }

        .error-wrapper a:hover {
            background-color: white;
            color: #512DA8;
        }

.stacktrace {
    background-color: #ffffff22;
    color: #ffe;
    padding: 1rem;
    margin-top: 2rem;
    text-align: left;
    max-width: 800px;
    width: 100%;
    border-radius: 8px;
    overflow-x: auto;
    font-size: 0.9rem;
}

.avatar-persona {
    width: 42px;
    height: 42px;
    object-fit: cover;
    border-radius: 50%;
}


/* Tarjeta suave por fila en móvil */
.persona-row {
    background: var(--bs-body-bg);
    border-radius: .5rem;
}

/* Imagen consistente */
.avatar-persona {
    width: 40px;
    height: 40px;
    object-fit: cover;
    border-radius: 50%;
}

/* Acciones: que quepan y envuelvan en móvil */
@media (max-width: 767.98px) {
    .acciones .btn {
        padding: .25rem .5rem;
        line-height: 1.2;
    }
}

.btn-icon-clean {
    background: transparent !important;
    border: none !important;
    padding: 0 !important;
    margin: 0 !important;
    box-shadow: none !important;
    color: #ccc; /* ajusta según tu tema */
}

    .btn-icon-clean:hover,
    .btn-icon-clean:focus {
        background: transparent !important;
        color: #fff; /* un poco más claro al hover si quieres */
    }

