/* ============================================
   VERIFACK - Navbar Active/Hover Gold Effect
   ============================================ */

/* Navbar links - hover state (gold color) */
.navbar-dark .nav-link:hover {
    color: #e0b816 !important;
}

/* Navbar links - active/current page (gold color) */
.navbar-dark .nav-link.active,
.navbar-dark .nav-item.active .nav-link,
.navbar .nav-link[aria-current="page"] {
    color: #e0b816 !important;
}

/* Dropdown toggle hover */
.navbar-dark .dropdown-toggle:hover {
    color: #e0b816 !important;
}

/* ============================================
   TRANSICIONES Y EFECTOS PROFESIONALES
   ============================================ */

/* NOTA: Se eliminó el selector universal (*) para evitar efectos duplicados
   Las transiciones ahora se aplican solo a elementos específicos donde se necesitan */

/* Transiciones básicas para elementos comunes del tema */
body, [data-bs-theme] {
    transition: background-color 0.3s ease, color 0.3s ease;
}

/* Animaciones de entrada para contenido principal */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

@keyframes slideInRight {
    from {
        opacity: 0;
        transform: translateX(30px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

@keyframes pulse {
    0%, 100% { transform: scale(1); }
    50% { transform: scale(1.05); }
}

/* Animación inicial del contenido */
main {
    animation: fadeIn 0.4s ease-out;
}

/* Animaciones para tarjetas */
.card {
    animation: fadeInUp 0.5s ease-out both;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

/* Cards del dashboard con delay escalonado */
.col-xl-3:nth-child(1) .card { animation-delay: 0.05s; }
.col-xl-3:nth-child(2) .card { animation-delay: 0.1s; }
.col-xl-3:nth-child(3) .card { animation-delay: 0.15s; }
.col-xl-3:nth-child(4) .card { animation-delay: 0.2s; }

.card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.15) !important;
}

/* Efecto hover en filas de tabla */
.table tbody tr {
    transition: background-color 0.2s ease, transform 0.2s ease;
}

.table tbody tr:hover {
    transform: scale(1.01);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

/* Botones con efectos mejorados */
.btn {
    position: relative;
    overflow: hidden;
    transition: all 0.3s ease;
}

.btn::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 0;
    height: 0;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.3);
    transform: translate(-50%, -50%);
    transition: width 0.6s, height 0.6s;
}

.btn:hover::before {
    width: 300px;
    height: 300px;
}

.btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.2);
}

.btn:active {
    transform: translateY(0);
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.2);
}

/* Efecto para iconos en botones */
.btn i {
    transition: transform 0.3s ease;
    display: inline-block;
}

.btn:hover i {
    transform: scale(1.2);
}

/* Enlaces de navegación */
.nav-link {
    position: relative;
    transition: all 0.3s ease;
}

.nav-link::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 50%;
    width: 0;
    height: 2px;
    background: currentColor;
    transition: width 0.3s ease, left 0.3s ease;
}

.nav-link:hover::after {
    width: 80%;
    left: 10%;
}

.nav-link:hover {
    transform: translateY(-2px);
}

/* Dropdown con animación suave */
.dropdown-menu {
    animation: fadeInUp 0.2s ease-out both;
    border: none;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.15);
}

.dropdown-item {
    transition: all 0.2s ease;
}

.dropdown-item:hover {
    transform: translateX(5px);
    padding-left: calc(1rem + 5px);
}

/* Alertas con animación */
.alert {
    animation: slideInRight 0.4s ease-out both;
    border-left: 4px solid;
}

.alert-dismissible .btn-close {
    transition: transform 0.3s ease, opacity 0.3s ease;
}

.alert-dismissible .btn-close:hover {
    transform: rotate(90deg) scale(1.2);
}

/* Badges animados */
.badge {
    transition: all 0.3s ease;
    display: inline-block;
}

.badge:hover {
    transform: scale(1.1);
}

/* Estadísticas del dashboard - solo transición de color */
.card .h3, .card .h5 {
    transition: color 0.3s ease;
}

/* Iconos grandes con efecto */
.bi[style*="font-size: 2.5rem"] {
    transition: transform 0.5s ease, opacity 0.5s ease;
}

.card:hover .bi[style*="font-size: 2.5rem"] {
    transform: rotate(10deg) scale(1.1);
    opacity: 0.5 !important;
}

/* Input focus con efecto */
.form-control:focus,
.form-select:focus {
    transform: scale(1.02);
    box-shadow: 0 0 0 0.25rem rgba(13, 110, 253, 0.25);
}

/* Modal con animación */
.modal.fade .modal-dialog {
    transition: transform 0.3s ease-out;
    transform: scale(0.8);
}

.modal.show .modal-dialog {
    transform: scale(1);
}

/* Paginación mejorada */
.pagination .page-link {
    transition: all 0.3s ease;
}

.pagination .page-link:hover {
    transform: translateY(-3px);
    box-shadow: 0 5px 10px rgba(0, 0, 0, 0.15);
}

/* Navbar con sombra dinámica */
.navbar {
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    transition: box-shadow 0.3s ease;
}

/* Brand logo con efecto */
.navbar-brand {
    transition: transform 0.3s ease;
}

.navbar-brand:hover {
    transform: scale(1.05);
}

.navbar-brand img {
    transition: transform 0.3s ease;
}

.navbar-brand:hover img {
    transform: rotate(-5deg);
}

/* Toggle de tema mejorado */
.theme-toggle {
    transition: all 0.3s ease;
}

.theme-toggle:hover {
    transform: rotate(20deg) scale(1.1);
}

.theme-toggle i {
    transition: opacity 0.3s ease, transform 0.3s ease;
}

/* Tablas responsivas */
.table-responsive {
    animation: fadeIn 0.5s ease-out both;
}

/* Breadcrumbs con efecto */
.breadcrumb-item {
    transition: transform 0.2s ease;
}

.breadcrumb-item:hover {
    transform: translateX(3px);
}

/* Profile photo en dropdown */
.nav-link img {
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.nav-link:hover img {
    transform: scale(1.1);
    box-shadow: 0 0 10px rgba(255, 255, 255, 0.5);
}

/* Loading animation para procesamiento */
@keyframes spin {
    to { transform: rotate(360deg); }
}

.bi-arrow-repeat {
    animation: spin 1s linear infinite;
}

/* Efecto para elementos interactivos */
[data-bs-toggle="collapse"] {
    transition: all 0.3s ease;
}

[data-bs-toggle="collapse"]:hover {
    transform: translateX(5px);
}

/* Smooth scroll */
html {
    scroll-behavior: smooth;
}

/* Animación de entrada escalonada para listas */
.table tbody tr:nth-child(1) { animation-delay: 0.05s; }
.table tbody tr:nth-child(2) { animation-delay: 0.1s; }
.table tbody tr:nth-child(3) { animation-delay: 0.15s; }
.table tbody tr:nth-child(4) { animation-delay: 0.2s; }
.table tbody tr:nth-child(5) { animation-delay: 0.25s; }


/* Progress bars animados */
.progress-bar {
    transition: width 0.6s ease;
}

/* Toast notifications (si se usan) */
.toast {
    animation: slideInRight 0.5s ease-out both;
}

/* Lista de elementos con efecto hover */
.list-group-item {
    transition: all 0.3s ease;
}

.list-group-item:hover {
    transform: translateX(5px);
    box-shadow: 0 3px 10px rgba(0, 0, 0, 0.1);
}

/* Tooltips mejorados (si se usan) */
.tooltip {
    animation: fadeIn 0.2s ease-out both;
}

/* Efecto de carga para imágenes */
img {
    transition: opacity 0.3s ease, transform 0.3s ease;
}

img:hover {
    transform: scale(1.05);
}

/* Links con underline animado */
a:not(.btn):not(.nav-link):not(.dropdown-item) {
    position: relative;
    text-decoration: none;
}

a:not(.btn):not(.nav-link):not(.dropdown-item)::after {
    content: '';
    position: absolute;
    bottom: -2px;
    left: 0;
    width: 0;
    height: 2px;
    background: currentColor;
    transition: width 0.3s ease;
}

a:not(.btn):not(.nav-link):not(.dropdown-item):hover::after {
    width: 100%;
}

/* Checkbox y radio con efecto */
.form-check-input {
    transition: all 0.3s ease;
}

.form-check-input:hover {
    transform: scale(1.1);
}

/* Mejora de accesibilidad: reducir animaciones si el usuario lo prefiere */
@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
}
