/* Reset y configuración base */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background: #f8f9fa;
    min-height: 100vh;
    color: #333;
}

/* Login Page Styles - Diseño Mejorado */
.login-container {
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 100vh;
    padding: 20px;
    background: linear-gradient(135deg, #28a745 0%, #20c997 50%, #17a2b8 100%);
    position: relative;
    overflow: hidden;
}

/* Efectos de fondo animados */
.login-container::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: radial-gradient(circle, rgba(255, 255, 255, 0.1) 0%, transparent 70%);
    animation: float 20s ease-in-out infinite;
}

.login-container::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 100 100"><defs><pattern id="grain" width="100" height="100" patternUnits="userSpaceOnUse"><circle cx="50" cy="50" r="1" fill="rgba(255,255,255,0.1)"/></pattern></defs><rect width="100" height="100" fill="url(%23grain)"/></svg>');
    opacity: 0.3;
}

@keyframes float {
    0%, 100% { transform: translateY(0px) rotate(0deg); }
    33% { transform: translateY(-20px) rotate(120deg); }
    66% { transform: translateY(10px) rotate(240deg); }
}

.login-card {
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(20px);
    border-radius: 25px;
    box-shadow: 0 25px 50px rgba(0, 0, 0, 0.15);
    padding: 50px 40px;
    width: 100%;
    max-width: 450px;
    text-align: center;
    position: relative;
    z-index: 10;
    border: 1px solid rgba(255, 255, 255, 0.2);
    transition: all 0.3s ease;
}

.login-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 35px 70px rgba(0, 0, 0, 0.2);
}

.login-header {
    margin-bottom: 40px;
}

.logo {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 20px;
    margin-bottom: 15px;
}

.logo i {
    font-size: 3rem;
    background: linear-gradient(135deg, #28a745, #20c997);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    filter: drop-shadow(0 2px 4px rgba(40, 167, 69, 0.3));
}

/* Estilos para el logo AGD en el login */
.logo-img {
    width: 60px;
    height: 60px;
    object-fit: contain;
    border-radius: 12px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.15);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.logo-img:hover {
    transform: scale(1.05);
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.2);
}

.logo h1 {
    font-size: 2.2rem;
    background: linear-gradient(135deg, #28a745, #20c997);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    font-weight: 700;
    letter-spacing: -0.5px;
}

.login-header p {
    color: #666;
    font-size: 1.1rem;
    font-weight: 400;
    margin: 0;
}

.alert {
    padding: 18px 20px;
    border-radius: 15px;
    margin-bottom: 25px;
    display: flex;
    align-items: center;
    gap: 12px;
    font-weight: 500;
    border: none;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
    animation: slideInDown 0.5s ease-out;
}

@keyframes slideInDown {
    from {
        opacity: 0;
        transform: translateY(-20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.alert-error {
    background: linear-gradient(135deg, #fff5f5, #fed7d7);
    color: #c53030;
    border-left: 4px solid #e53e3e;
}

.alert-success {
    background: linear-gradient(135deg, #f0fff4, #c6f6d5);
    color: #155724;
    border-left: 4px solid #38a169;
}

.alert-warning {
    background: linear-gradient(135deg, #fffbeb, #fef5e7);
    color: #856404;
    border-left: 4px solid #d69e2e;
}

.login-form {
    text-align: left;
}

.form-group {
    margin-bottom: 25px;
    position: relative;
}

.form-group label {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 10px;
    color: #333;
    font-weight: 600;
    font-size: 0.95rem;
}

.form-group label i {
    color: #28a745;
    font-size: 1.1rem;
}

.form-group input {
    width: 100%;
    padding: 18px 20px;
    border: 2px solid #e9ecef;
    border-radius: 15px;
    font-size: 1rem;
    transition: all 0.3s ease;
    background: rgba(255, 255, 255, 0.8);
    backdrop-filter: blur(10px);
}

.form-group input:focus {
    outline: none;
    border-color: #28a745;
    box-shadow: 0 0 0 4px rgba(40, 167, 69, 0.15);
    background: white;
    transform: translateY(-2px);
}

.form-group input::placeholder {
    color: #999;
    font-weight: 400;
}

/* Footer del login mejorado */
.login-footer {
    margin-top: 30px;
    padding-top: 25px;
    border-top: 1px solid rgba(0, 0, 0, 0.1);
    text-align: center;
}

.login-footer p {
    color: #666;
    font-size: 0.9rem;
    margin: 0;
    font-weight: 400;
}

.developer-credit {
    margin-top: 10px !important;
    color: #888 !important;
    font-size: 0.85rem !important;
    font-style: italic;
}

.developer-credit strong {
    color: #28a745;
    font-weight: 600;
}

/* Enlaces del login mejorados */
.form-actions {
    margin-top: 25px;
    text-align: center;
}

.btn-link {
    color: #28a745;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    font-weight: 600;
    transition: all 0.3s ease;
    font-size: 0.95rem;
    padding: 8px 16px;
    border-radius: 10px;
    background: rgba(40, 167, 69, 0.1);
    border: 1px solid rgba(40, 167, 69, 0.2);
}

.btn-link:hover {
    color: #218838;
    background: rgba(40, 167, 69, 0.15);
    border-color: rgba(40, 167, 69, 0.3);
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(40, 167, 69, 0.2);
}

.btn-link i {
    font-size: 1rem;
    transition: transform 0.3s ease;
}

.btn-link:hover i {
    transform: translateX(2px);
}

/* Responsive para login */
@media (max-width: 768px) {
    .login-container {
        padding: 15px;
    }
    
    .login-card {
        padding: 40px 30px;
        max-width: 100%;
    }
    
    .logo h1 {
        font-size: 1.8rem;
    }
    
    .logo i {
        font-size: 2.5rem;
    }
    
    .form-group input {
        padding: 16px 18px;
    }
    
    .btn-login {
        padding: 16px 25px;
        font-size: 1rem;
    }
}

/* Animación de entrada para el login */
.login-card {
    animation: fadeInUp 0.8s ease-out;
}

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Efecto de partículas flotantes */
.login-container::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-image: 
        radial-gradient(circle at 20% 80%, rgba(255, 255, 255, 0.1) 0%, transparent 50%),
        radial-gradient(circle at 80% 20%, rgba(255, 255, 255, 0.1) 0%, transparent 50%),
        radial-gradient(circle at 40% 40%, rgba(255, 255, 255, 0.05) 0%, transparent 50%);
    animation: particleFloat 15s ease-in-out infinite;
}

@keyframes particleFloat {
    0%, 100% { 
        transform: translateY(0px) rotate(0deg);
        opacity: 0.7;
    }
    50% { 
        transform: translateY(-20px) rotate(180deg);
        opacity: 1;
    }
}

/* Botón de login mejorado */
.btn-login {
    width: 100%;
    padding: 18px 30px;
    border: none;
    border-radius: 15px;
    font-size: 1.1rem;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.3s ease;
    text-decoration: none;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    background: linear-gradient(135deg, #28a745 0%, #20c997 100%);
    color: white;
    box-shadow: 0 8px 25px rgba(40, 167, 69, 0.3);
    position: relative;
    overflow: hidden;
}

.btn-login::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
    transition: left 0.5s;
}

.btn-login:hover {
    transform: translateY(-3px);
    box-shadow: 0 12px 35px rgba(40, 167, 69, 0.4);
    background: linear-gradient(135deg, #218838 0%, #1ea085 100%);
}

.btn-login:hover::before {
    left: 100%;
}

.btn-login:active {
    transform: translateY(-1px);
    box-shadow: 0 6px 20px rgba(40, 167, 69, 0.3);
}

.btn-login i {
    font-size: 1.2rem;
    transition: transform 0.3s ease;
}

.btn-login:hover i {
    transform: translateX(3px);
}

/* Botones generales mejorados */
.btn {
    padding: 15px 30px;
    border: none;
    border-radius: 12px;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    text-decoration: none;
    display: inline-block;
    text-align: center;
}

.btn-primary {
    background: linear-gradient(135deg, #28a745 0%, #20c997 100%);
    color: white;
    box-shadow: 0 6px 20px rgba(40, 167, 69, 0.25);
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 30px rgba(40, 167, 69, 0.35);
    color: white;
}

.btn-secondary {
    background: #6c757d;
    color: white;
}

.btn-secondary:hover {
    background: #5a6268;
    color: white;
}

.btn-danger {
    background: #dc3545;
    color: white;
}

.btn-danger:hover {
    background: #c82333;
    color: white;
}

/* Dashboard Styles */
.dashboard-container {
    display: flex;
    min-height: 100vh;
    background: #f8f9fa;
}

.sidebar {
    width: 280px;
    background: white;
    box-shadow: 2px 0 10px rgba(0, 0, 0, 0.1);
    position: fixed;
    height: 100vh;
    overflow-y: auto;
    z-index: 1000;
}

.sidebar-header {
    padding: 30px 20px;
    border-bottom: 1px solid #e9ecef;
}

.sidebar-header .logo {
    justify-content: flex-start;
}

.sidebar-header .logo h2 {
    font-size: 1.4rem;
    color: #333;
    font-weight: 600;
}

/* Estilos para el logo AGD en el sidebar */
.sidebar-header .logo-img {
    width: 40px;
    height: 40px;
    object-fit: contain;
    border-radius: 8px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
    transition: transform 0.3s ease;
}

.sidebar-header .logo-img:hover {
    transform: scale(1.05);
}

/* Estilos para la gestión de usuarios */
.stats-card-admin {
    background: linear-gradient(135deg, #dc3545, #c82333);
    color: white;
}

.stats-card-user {
    background: linear-gradient(135deg, #007bff, #0056b3);
    color: white;
}

.stats-card-admin .stats-icon,
.stats-card-user .stats-icon {
    background: rgba(255, 255, 255, 0.2);
}

.stats-card-admin .stats-icon i,
.stats-card-user .stats-icon i {
    color: white;
}

/* Estilos para la tabla de usuarios */
#usersTable {
    font-size: 0.9rem;
}

#usersTable th {
    font-weight: 600;
    text-transform: uppercase;
    font-size: 0.8rem;
    letter-spacing: 0.5px;
}

#usersTable td {
    vertical-align: middle;
    padding: 12px 8px;
}

/* Estilos para los badges de rol */
.badge {
    font-size: 0.75rem;
    padding: 6px 10px;
    border-radius: 20px;
}

/* Estilos para los botones de acción */
.btn-group .btn {
    margin: 0 2px;
    border-radius: 6px;
}

.btn-group .btn:hover {
    transform: translateY(-1px);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
}

/* Estilos para los modales */
.modal-header {
    background: linear-gradient(135deg, #667eea, #764ba2);
    color: white;
}

.modal-header .btn-close {
    filter: invert(1);
}

/* Estilos para los formularios */
.form-label {
    font-weight: 600;
    color: #495057;
}

.form-control:focus,
.form-select:focus {
    border-color: #667eea;
    box-shadow: 0 0 0 0.2rem rgba(102, 126, 234, 0.25);
}

/* Responsive para la tabla de usuarios */
@media (max-width: 768px) {
    #usersTable {
        font-size: 0.8rem;
    }
    
    #usersTable th,
    #usersTable td {
        padding: 8px 4px;
    }
    
    .btn-group .btn {
        padding: 4px 8px;
        font-size: 0.75rem;
    }
    
    .badge {
        font-size: 0.7rem;
        padding: 4px 8px;
    }
}

.sidebar-nav {
    padding: 20px 0;
}

.nav-item {
    list-style: none;
}

.nav-item a {
    display: flex;
    align-items: center;
    gap: 15px;
    padding: 15px 25px;
    color: #666;
    text-decoration: none;
    transition: all 0.3s ease;
    border-left: 3px solid transparent;
}

.nav-item a:hover {
    background: #f8f9fa;
    color: #667eea;
    border-left-color: #667eea;
}

.nav-item.active a {
    background: #f8f9fa;
    color: #667eea;
    border-left-color: #667eea;
    font-weight: 600;
}

.nav-item i {
    font-size: 1.2rem;
    width: 20px;
}

.main-content {
    flex: 1;
    margin-left: 280px;
    background: #f8f9fa;
    min-height: 100vh;
}

.header {
    background: white;
    padding: 20px 30px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.header-left h1 {
    font-size: 1.8rem;
    color: #333;
    margin-bottom: 5px;
}

.header-left p {
    color: #666;
    margin: 0;
}

.user-menu {
    position: relative;
    display: flex;
    align-items: center;
    gap: 15px;
    cursor: pointer;
}

.user-info {
    text-align: right;
}

.user-info span {
    display: block;
    font-weight: 600;
    color: #333;
}

.user-info small {
    color: #666;
    font-size: 0.9rem;
}

.user-avatar {
    width: 40px;
    height: 40px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 1.2rem;
}

.dropdown-menu {
    position: absolute;
    top: 100%;
    right: 0;
    background: white;
    border-radius: 10px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
    padding: 10px 0;
    min-width: 200px;
    opacity: 0;
    visibility: hidden;
    transform: translateY(-10px);
    transition: all 0.3s ease;
}

.user-menu:hover .dropdown-menu {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.dropdown-menu a {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 12px 20px;
    color: #666;
    text-decoration: none;
    transition: all 0.3s ease;
}

.dropdown-menu a:hover {
    background: #f8f9fa;
    color: #667eea;
}

.dashboard-content {
    padding: 30px;
}

.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 20px;
    margin-bottom: 30px;
}

.stat-card {
    background: white;
    border-radius: 15px;
    padding: 25px;
    box-shadow: 0 3px 10px rgba(0, 0, 0, 0.08);
    display: flex;
    align-items: center;
    gap: 20px;
    transition: all 0.3s ease;
    border: 2px solid #e9ecef;
    position: relative;
    overflow: hidden;
}

.stat-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 25px rgba(40, 167, 69, 0.15);
    border-color: #28a745;
}

/* Efecto de brillo sutil en hover */
.stat-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(40, 167, 69, 0.05), transparent);
    transition: left 0.5s;
}

.stat-card:hover::before {
    left: 100%;
}

.stat-icon {
    width: 60px;
    height: 60px;
    background: linear-gradient(135deg, rgba(40, 167, 69, 0.1) 0%, rgba(32, 201, 151, 0.1) 100%);
    border: 2px solid #28a745;
    border-radius: 15px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #28a745;
    font-size: 1.5rem;
    transition: all 0.3s ease;
    margin-left: 20px;
}

.stat-card:hover .stat-icon {
    background: linear-gradient(135deg, rgba(40, 167, 69, 0.15) 0%, rgba(32, 201, 151, 0.15) 100%);
    transform: scale(1.05);
}

/* Nuevo diseño para tarjetas de estadísticas */
.stats-card {
    background: white;
    border-radius: 20px;
    padding: 30px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
    transition: all 0.3s ease;
    border: 1px solid #f0f0f0;
    position: relative;
    overflow: hidden;
    display: flex;
    align-items: center;
    gap: 20px;
    min-height: 120px;
}

.stats-card:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 30px rgba(0, 0, 0, 0.12);
}

/* Icono de estadísticas */
.stats-icon {
    width: 60px;
    height: 60px;
    border-radius: 15px;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    transition: all 0.3s ease;
}

.stats-icon i {
    font-size: 1.8rem;
    color: white;
    transition: all 0.3s ease;
}

/* Contenido de estadísticas */
.stats-content {
    flex: 1;
}

.stats-number {
    font-size: 2.2rem;
    font-weight: 700;
    color: #333;
    margin: 0 0 5px 0;
    line-height: 1;
    transition: all 0.3s ease;
}

.stats-label {
    font-size: 0.95rem;
    color: #666;
    margin: 0;
    font-weight: 500;
    transition: all 0.3s ease;
}

/* Variantes de tarjetas de estadísticas */
.stats-card-total .stats-icon {
    background: linear-gradient(135deg, #28a745, #20c997);
}

.stats-card-total:hover .stats-icon {
    transform: scale(1.05);
    box-shadow: 0 4px 15px rgba(40, 167, 69, 0.3);
}

.stats-card-active .stats-icon {
    background: linear-gradient(135deg, #20c997, #17a2b8);
}

.stats-card-active:hover .stats-icon {
    transform: scale(1.05);
    box-shadow: 0 4px 15px rgba(32, 201, 151, 0.3);
}

.stats-card-inactive .stats-icon {
    background: linear-gradient(135deg, #17a2b8, #6f42c1);
}

.stats-card-inactive:hover .stats-icon {
    transform: scale(1.05);
    box-shadow: 0 4px 15px rgba(23, 162, 184, 0.3);
}

/* Efectos hover para números y etiquetas */
.stats-card:hover .stats-number {
    color: #28a745;
}

.stats-card:hover .stats-label {
    color: #333;
}

/* Variantes específicas para facturas */
.stats-card-pending .stats-icon {
    background: linear-gradient(135deg, #ffc107, #fd7e14);
}

.stats-card-pending:hover .stats-icon {
    transform: scale(1.05);
    box-shadow: 0 4px 15px rgba(255, 193, 7, 0.3);
}

.stats-card-paid .stats-icon {
    background: linear-gradient(135deg, #28a745, #20c997);
}

.stats-card-paid:hover .stats-icon {
    transform: scale(1.05);
    box-shadow: 0 4px 15px rgba(40, 167, 69, 0.3);
}

.stats-card-overdue .stats-icon {
    background: linear-gradient(135deg, #dc3545, #e83e8c);
}

.stats-card-overdue:hover .stats-icon {
    transform: scale(1.05);
    box-shadow: 0 4px 15px rgba(220, 53, 69, 0.3);
}

/* Cards clickeables */
.clickable-card {
    cursor: pointer;
    transition: all 0.3s ease;
}

.clickable-card:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 30px rgba(0, 0, 0, 0.15);
}

/* Colores específicos para las estadísticas simplificadas */
.stats-card-due-soon {
    border-left: 4px solid #007bff;
}

.stats-card-due-soon .stats-icon {
    background: linear-gradient(135deg, #007bff, #0056b3);
}

.stats-card-due-soon:hover {
    border-left-color: #0056b3;
    box-shadow: 0 4px 20px rgba(0, 123, 255, 0.2);
}

.stats-card-pending-gestion .stats-icon {
    background: linear-gradient(135deg, #17a2b8, #6f42c1);
}

.stats-card-pending-gestion:hover .stats-icon {
    transform: scale(1.05);
    box-shadow: 0 4px 15px rgba(23, 162, 184, 0.3);
}

/* Estilos para el badge de estado */
.status-badge {
    transition: all 0.3s ease;
    border: 2px solid transparent;
}

.status-badge:hover {
    transform: scale(1.05);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
}

.status-badge.bg-success:hover {
    border-color: #155724;
    background-color: #155724 !important;
}

.status-badge.bg-warning:hover {
    border-color: #856404;
    background-color: #856404 !important;
}

.stat-info h3 {
    font-size: 1.8rem;
    color: #333;
    margin-bottom: 5px;
    font-weight: 600;
}

.stat-info p {
    color: #666;
    margin: 0;
    font-size: 0.9rem;
}

.dashboard-sections {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(400px, 1fr));
    gap: 20px;
}

.section-card {
    background: white;
    border-radius: 15px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.08);
    overflow: hidden;
}

.section-header {
    padding: 20px 25px;
    border-bottom: 1px solid #e9ecef;
    background: #f8f9fa;
}

.section-header h3 {
    color: #333;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 10px;
}

.section-header i {
    color: #28a745;
}

.section-content {
    padding: 25px;
}

.activity-item {
    display: flex;
    align-items: center;
    gap: 15px;
    padding: 15px 0;
    border-bottom: 1px solid #f0f0f0;
}

.activity-item:last-child {
    border-bottom: none;
}

.activity-icon {
    width: 40px;
    height: 40px;
    border-radius: 10px;
    background: #f8f9ff;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #1e7e34;
}

.activity-info p {
    color: #333;
    font-weight: 500;
    margin-bottom: 5px;
}

.activity-info small {
    color: #999;
    font-size: 0.9rem;
}

.task-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 15px 0;
    border-bottom: 1px solid #f0f0f0;
}

.task-item:last-child {
    border-bottom: none;
}

.task-checkbox {
    display: flex;
    align-items: center;
    gap: 10px;
}

.task-checkbox input[type="checkbox"] {
    width: 18px;
    height: 18px;
    accent-color: #1e7e34;
}

.task-checkbox label {
    color: #333;
    cursor: pointer;
}

.task-priority {
    padding: 5px 12px;
    border-radius: 20px;
    font-size: 0.8rem;
    font-weight: 600;
    text-transform: uppercase;
}

.task-priority.high {
    background: #fee;
    color: #c53030;
}

.task-priority.medium {
    background: #fef5e7;
    color: #d69e2e;
}

.task-priority.low {
    background: #f0fff4;
    color: #38a169;
}

/* Responsive Design */
@media (max-width: 768px) {
    .sidebar {
        transform: translateX(-100%);
        transition: transform 0.3s ease;
    }
    
    .sidebar.active {
        transform: translateX(0);
    }
    
    .main-content {
        margin-left: 0;
    }
    
    .stats-grid {
        grid-template-columns: 1fr;
    }
    
    .dashboard-sections {
        grid-template-columns: 1fr;
    }
    
    .header {
        flex-direction: column;
        gap: 15px;
        text-align: center;
    }
    
    .user-menu {
        align-self: center;
    }
}

/* Animaciones */
@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.login-card,
.stat-card,
.section-card {
    animation: fadeIn 0.6s ease-out;
}

/* Estilos para el dashboard simplificado */
.quick-actions {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 1rem;
    margin-top: 1rem;
}

.action-button {
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 1.5rem;
    color: #333;
    text-decoration: none;
    border-radius: 15px;
    transition: all 0.3s ease;
    text-align: center;
    background: white;
    border: 2px solid #e9ecef;
    position: relative;
    overflow: hidden;
}

.action-button:hover {
    transform: translateY(-5px);
    color: #28a745;
    text-decoration: none;
    border-color: #28a745;
    box-shadow: 0 8px 25px rgba(40, 167, 69, 0.15);
}

/* Colores diferenciados para proveedores */
.action-provider {
    border-color: #28a745;
    background: linear-gradient(135deg, rgba(40, 167, 69, 0.05) 0%, rgba(32, 201, 151, 0.05) 100%);
}

.action-provider:hover {
    background: linear-gradient(135deg, rgba(40, 167, 69, 0.1) 0%, rgba(32, 201, 151, 0.1) 100%);
    border-color: #28a745;
    box-shadow: 0 8px 25px rgba(40, 167, 69, 0.2);
}

/* Colores diferenciados para facturas */
.action-invoice {
    border-color: #17a2b8;
    background: linear-gradient(135deg, rgba(32, 201, 151, 0.05) 0%, rgba(23, 162, 184, 0.05) 100%);
}

.action-invoice:hover {
    background: linear-gradient(135deg, rgba(32, 201, 151, 0.1) 0%, rgba(23, 162, 184, 0.1) 100%);
    border-color: #17a2b8;
    box-shadow: 0 8px 25px rgba(32, 201, 151, 0.2);
}

.action-button i {
    font-size: 2.5rem;
    margin-bottom: 0.75rem;
    transition: all 0.3s ease;
}

.action-provider i {
    color: #28a745;
}

.action-invoice i {
    color: #17a2b8;
}

.action-button:hover i {
    transform: scale(1.1);
}

.action-button span {
    font-weight: 600;
    font-size: 1rem;
    transition: all 0.3s ease;
}

/* Efecto de brillo sutil en hover */
.action-button::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.4), transparent);
    transition: left 0.5s;
}

.action-button:hover::before {
    left: 100%;
}

/* Mejorar el espaciado de la grilla */
.quick-actions {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 1.5rem;
    margin-top: 1rem;
}

/* Estilos específicos para tarjetas de estadísticas - ELIMINADOS DUPLICADOS */

.info-item {
    display: flex;
    align-items: flex-start;
    gap: 1rem;
    padding: 1rem 0;
    border-bottom: 1px solid #eee;
}

.info-item:last-child {
    border-bottom: none;
}

.info-icon {
    flex-shrink: 0;
    width: 40px;
    height: 40px;
    background: linear-gradient(135deg, #28a745 0%, #20c997 100%);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
}

.info-content h4 {
    margin-bottom: 0.5rem;
    color: #333;
    font-weight: 600;
}

.info-content p {
    color: #666;
    line-height: 1.5;
    margin: 0;
}

/* Estilos para proveedores */
.provider-card {
    transition: transform 0.2s, box-shadow 0.2s;
    border: none;
    border-radius: 15px;
    box-shadow: 0 5px 15px rgba(0,0,0,0.08);
}

.provider-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 25px rgba(0,0,0,0.15);
}

.provider-info {
    margin-top: 1rem;
}

.provider-info .info-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 0;
    border: none;
    margin-bottom: 0.75rem;
}

.provider-info .info-item:last-child {
    margin-bottom: 0;
}

.provider-info .info-icon {
    width: 32px;
    height: 32px;
    background: #f8f9fa;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #667eea;
    font-size: 0.9rem;
    flex-shrink: 0;
}

.provider-info .info-content {
    flex: 1;
}

.provider-info .info-content small {
    color: #6c757d;
    font-size: 0.75rem;
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.provider-info .info-content strong,
.provider-info .info-content a {
    color: #333;
    font-weight: 600;
    display: block;
    margin-top: 2px;
}

.provider-info .info-content a:hover {
    color: #667eea;
}

/* Estilo duplicado eliminado */

.search-box {
    background: white;
    border-radius: 15px;
    padding: 0.5rem 1rem;
    box-shadow: 0 5px 15px rgba(0,0,0,0.08);
    border: 2px solid #e9ecef;
}

.search-box:focus-within {
    border-color: #667eea;
    box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.1);
}

.btn-floating {
    position: fixed;
    bottom: 30px;
    right: 30px;
    width: 60px;
    height: 60px;
    border-radius: 50%;
    font-size: 24px;
    box-shadow: 0 8px 25px rgba(40, 167, 69, 0.2);
    z-index: 1000;
    background: white;
    border: 2px solid #28a745;
    color: #28a745;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    text-decoration: none;
    font-weight: 600;
}

.btn-floating:hover {
    transform: translateY(-3px);
    box-shadow: 0 12px 30px rgba(40, 167, 69, 0.3);
    background: #28a745;
    color: white;
}

/* Estado vacío */
.empty-state {
    padding: 3rem 1rem;
    text-align: center;
}

.empty-state i {
    color: #dee2e6;
    margin-bottom: 1.5rem;
}

.empty-state h4 {
    color: #6c757d;
    font-weight: 600;
    margin-bottom: 0.5rem;
}

.empty-state p {
    color: #adb5bd;
    font-size: 1.1rem;
    margin-bottom: 2rem;
}

/* Estilos para tarjetas de facturas */
.invoice-card {
    border: 1px solid #e9ecef;
    border-radius: 15px;
    transition: all 0.3s ease;
    box-shadow: 0 2px 10px rgba(0,0,0,0.05);
}

.invoice-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(0,0,0,0.1);
}

.invoice-info {
    font-size: 0.9rem;
}

.invoice-info .row {
    margin-bottom: 0.5rem;
}

.invoice-info strong {
    font-weight: 600;
}

/* Estilos para tabla de facturas */
#invoicesTable {
    font-size: 0.9rem;
}

#invoicesTable th {
    background-color: #f8f9fa;
    border-bottom: 2px solid #dee2e6;
    font-weight: 600;
    color: #495057;
    padding: 12px 8px;
}

#invoicesTable td {
    padding: 12px 8px;
    vertical-align: middle;
    border-bottom: 1px solid #e9ecef;
}

#invoicesTable tbody tr:hover {
    background-color: #f8f9fa;
}

#invoicesTable .badge {
    font-size: 0.75rem;
    padding: 4px 8px;
}

#invoicesTable .btn-group .btn {
    padding: 4px 8px;
    font-size: 0.8rem;
}

/* Estados de gestión */
.badge.bg-danger {
    background-color: #dc3545 !important;
}

.badge.bg-warning {
    background-color: #ffc107 !important;
    color: #212529 !important;
}

.badge.bg-success {
    background-color: #198754 !important;
}

/* Iconos de frecuencia */
.fa-calendar-alt.text-success {
    color: #198754 !important;
}

.fa-file-invoice.text-primary {
    color: #0d6efd !important;
}

/* Timeline para historial */
.timeline {
    position: relative;
    padding-left: 30px;
}

.timeline::before {
    content: '';
    position: absolute;
    left: 15px;
    top: 0;
    bottom: 0;
    width: 2px;
    background: #e9ecef;
}

.timeline-item {
    position: relative;
    margin-bottom: 1.5rem;
}

.timeline-item.latest {
    margin-bottom: 0;
}

.timeline-marker {
    position: absolute;
    left: -22px;
    top: 0;
    width: 30px;
    height: 30px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 0.8rem;
}

.timeline-content {
    background: #f8f9fa;
    padding: 1rem;
    border-radius: 10px;
    border-left: 4px solid #667eea;
}

.timeline-item.latest .timeline-content {
    background: #e3f2fd;
    border-left-color: #2196f3;
}

/* Estilos para modales */
.modal-content {
    border-radius: 15px;
    border: none;
    box-shadow: 0 20px 40px rgba(0,0,0,0.15);
}

.modal-header {
    border-bottom: 1px solid #e9ecef;
    padding: 20px 25px;
    background: #f8f9fa;
    border-radius: 15px 15px 0 0;
}

.modal-title {
    color: #333;
    font-weight: 600;
}

.modal-body {
    padding: 25px;
}

.modal-footer {
    border-top: 1px solid #e9ecef;
    padding: 20px 25px;
    background: #f8f9fa;
    border-radius: 0 0 15px 15px;
}

/* Estilos para menú de acciones personalizado */
.action-menu {
    position: relative;
}

.action-btn {
    border: none;
    background: transparent;
    color: #6c757d;
    padding: 6px 8px;
    border-radius: 6px;
    transition: all 0.2s ease;
}

.action-btn:hover {
    background-color: #f8f9fa;
    color: #495057;
}

.action-menu-items {
    position: absolute;
    top: 100%;
    right: 0;
    background: white;
    border: 1px solid #e9ecef;
    border-radius: 10px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.15);
    padding: 8px 0;
    min-width: 160px;
    z-index: 1000;
    display: none;
    margin-top: 5px;
}

.action-menu-items.show {
    display: block;
    animation: fadeInDown 0.2s ease;
}

.action-item {
    display: block;
    padding: 8px 16px;
    color: #333;
    text-decoration: none;
    font-size: 0.9rem;
    transition: all 0.2s ease;
    border: none;
    background: none;
    width: 100%;
    text-align: left;
}

.action-item:hover {
    background-color: #f8f9fa;
    color: #333;
    text-decoration: none;
}

.action-item.text-danger:hover {
    background-color: #fee;
    color: #dc3545;
}

.action-divider {
    margin: 4px 0;
    border-color: #e9ecef;
    border-width: 1px;
}

@keyframes fadeInDown {
    from {
        opacity: 0;
        transform: translateY(-10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Estilos para dropdowns (mantener compatibilidad) */
.dropdown-toggle::after {
    display: none;
}

.dropdown-menu {
    border-radius: 10px;
    border: 1px solid #e9ecef;
    box-shadow: 0 10px 30px rgba(0,0,0,0.1);
    padding: 8px 0;
    min-width: 160px;
}

.dropdown-item {
    padding: 8px 16px;
    font-size: 0.9rem;
    transition: all 0.2s ease;
}

.dropdown-item:hover {
    background-color: #f8f9fa;
    color: #333;
}

.dropdown-item.text-danger:hover {
    background-color: #fee;
    color: #dc3545;
}

.dropdown-divider {
    margin: 4px 0;
    border-color: #e9ecef;
}

/* Estilos para formularios */
.form-label {
    font-weight: 600;
    color: #333;
    margin-bottom: 8px;
}

.form-control {
    border: 2px solid #e9ecef;
    border-radius: 10px;
    padding: 12px 15px;
    font-size: 1rem;
    transition: all 0.3s ease;
}

.form-control:focus {
    border-color: #667eea;
    box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.1);
    outline: none;
}

.form-select {
    border: 2px solid #e9ecef;
    border-radius: 10px;
    padding: 12px 15px;
    font-size: 1rem;
    transition: all 0.3s ease;
}

.form-select:focus {
    border-color: #667eea;
    box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.1);
    outline: none;
}

/* Estilos para alertas flotantes */
.alert {
    animation: slideInRight 0.3s ease-out;
    border-radius: 10px;
    border: none;
    box-shadow: 0 10px 25px rgba(0,0,0,0.1);
}

@keyframes slideInRight {
    from {
        transform: translateX(100%);
        opacity: 0;
    }
    to {
        transform: translateX(0);
        opacity: 1;
    }
}

/* Responsive adjustments */
@media (max-width: 768px) {
    .sidebar {
        transform: translateX(-100%);
        transition: transform 0.3s ease;
    }
    
    .sidebar.active {
        transform: translateX(0);
    }
    
    .main-content {
        margin-left: 0;
    }
    
    .quick-actions {
        grid-template-columns: 1fr;
    }
    
    .action-button {
        padding: 1rem;
    }
    
    .info-item {
        flex-direction: column;
        text-align: center;
    }
    
    .info-icon {
        align-self: center;
    }
    
    .stats-grid {
        grid-template-columns: 1fr;
    }
    
    .dashboard-sections {
        grid-template-columns: 1fr;
    }
}

/* ===== TEMA BLANCO Y VERDE PARA NOTIFICACIONES ===== */

/* Estilos para notificaciones blancas y verdes */
.alert-floating {
    background: #ffffff !important;
    border: 2px solid #28a745 !important;
    color: #155724 !important;
    box-shadow: 0 4px 15px rgba(40, 167, 69, 0.2) !important;
    border-radius: 12px !important;
}

.alert-floating .btn-close {
    color: #28a745 !important;
}

.alert-floating i {
    color: #28a745 !important;
}

/* Modales con tema blanco y verde */
.modal-content {
    border: 2px solid #28a745 !important;
    border-radius: 15px !important;
}

.modal-header {
    background: linear-gradient(135deg, #ffffff 0%, #f8fff9 100%) !important;
    border-bottom: 2px solid #28a745 !important;
    border-radius: 13px 13px 0 0 !important;
}

.modal-title {
    color: #155724 !important;
}

.modal-title i {
    color: #28a745 !important;
}

.modal-body {
    background: #ffffff !important;
}

.modal-footer {
    background: #f8fff9 !important;
    border-top: 2px solid #28a745 !important;
    border-radius: 0 0 13px 13px !important;
}

/* Botones con tema blanco y bordes de color */
.btn-primary {
    background: white !important;
    border: 2px solid #28a745 !important;
    color: #28a745 !important;
    box-shadow: 0 4px 15px rgba(40, 167, 69, 0.15) !important;
    font-weight: 600 !important;
    transition: all 0.3s ease !important;
}

.btn-primary:hover {
    background: #28a745 !important;
    color: white !important;
    box-shadow: 0 6px 20px rgba(40, 167, 69, 0.3) !important;
    transform: translateY(-2px) !important;
}

.btn-success {
    background: white !important;
    border: 2px solid #28a745 !important;
    color: #28a745 !important;
    box-shadow: 0 4px 15px rgba(40, 167, 69, 0.15) !important;
    font-weight: 600 !important;
    transition: all 0.3s ease !important;
}

.btn-success:hover {
    background: #28a745 !important;
    color: white !important;
    box-shadow: 0 6px 20px rgba(40, 167, 69, 0.3) !important;
    transform: translateY(-2px) !important;
}

.btn-danger {
    background: white !important;
    border: 2px solid #dc3545 !important;
    color: #dc3545 !important;
    box-shadow: 0 4px 15px rgba(220, 53, 69, 0.15) !important;
    font-weight: 600 !important;
    transition: all 0.3s ease !important;
}

.btn-danger:hover {
    background: #dc3545 !important;
    color: white !important;
    box-shadow: 0 6px 20px rgba(220, 53, 69, 0.3) !important;
    transform: translateY(-2px) !important;
}

.btn-warning {
    background: white !important;
    border: 2px solid #ffc107 !important;
    color: #856404 !important;
    box-shadow: 0 4px 15px rgba(255, 193, 7, 0.15) !important;
    font-weight: 600 !important;
    transition: all 0.3s ease !important;
}

.btn-warning:hover {
    background: #ffc107 !important;
    color: #212529 !important;
    box-shadow: 0 6px 20px rgba(255, 193, 7, 0.3) !important;
    transform: translateY(-2px) !important;
}

/* Botones pequeños con tema blanco */
.btn-sm.btn-primary {
    background: white !important;
    border: 1.5px solid #28a745 !important;
    color: #28a745 !important;
    box-shadow: 0 2px 8px rgba(40, 167, 69, 0.15) !important;
    font-weight: 600 !important;
    font-size: 0.875rem !important;
    padding: 0.375rem 0.75rem !important;
    transition: all 0.3s ease !important;
}

.btn-sm.btn-primary:hover {
    background: #28a745 !important;
    color: white !important;
    box-shadow: 0 4px 12px rgba(40, 167, 69, 0.3) !important;
    transform: translateY(-1px) !important;
}

.btn-sm.btn-success {
    background: white !important;
    border: 1.5px solid #28a745 !important;
    color: #28a745 !important;
    box-shadow: 0 2px 8px rgba(40, 167, 69, 0.15) !important;
    font-weight: 600 !important;
    font-size: 0.875rem !important;
    padding: 0.375rem 0.75rem !important;
    transition: all 0.3s ease !important;
}

.btn-sm.btn-success:hover {
    background: #28a745 !important;
    color: white !important;
    box-shadow: 0 4px 12px rgba(40, 167, 69, 0.3) !important;
    transform: translateY(-1px) !important;
}

.btn-sm.btn-warning {
    background: white !important;
    border: 1.5px solid #ffc107 !important;
    color: #856404 !important;
    box-shadow: 0 2px 8px rgba(255, 193, 7, 0.15) !important;
    font-weight: 600 !important;
    font-size: 0.875rem !important;
    padding: 0.375rem 0.75rem !important;
    transition: all 0.3s ease !important;
}

.btn-sm.btn-warning:hover {
    background: #ffc107 !important;
    color: #212529 !important;
    box-shadow: 0 4px 12px rgba(255, 193, 7, 0.3) !important;
    transform: translateY(-1px) !important;
}

.btn-sm.btn-danger {
    background: white !important;
    border: 1.5px solid #dc3545 !important;
    color: #dc3545 !important;
    box-shadow: 0 2px 8px rgba(220, 53, 69, 0.15) !important;
    font-weight: 600 !important;
    font-size: 0.875rem !important;
    padding: 0.375rem 0.75rem !important;
    transition: all 0.3s ease !important;
}

.btn-sm.btn-danger:hover {
    background: #dc3545 !important;
    color: white !important;
    box-shadow: 0 4px 12px rgba(220, 53, 69, 0.3) !important;
    transform: translateY(-1px) !important;
}

/* Alertas con tema blanco y verde */
.alert-info {
    background: #ffffff !important;
    border: 2px solid #17a2b8 !important;
    color: #0c5460 !important;
}

.alert-warning {
    background: #ffffff !important;
    border: 2px solid #ffc107 !important;
    color: #856404 !important;
}

.alert-danger {
    background: #ffffff !important;
    border: 2px solid #dc3545 !important;
    color: #721c24 !important;
}

.alert-success {
    background: #ffffff !important;
    border: 2px solid #28a745 !important;
    color: #155724 !important;
}

/* Badges con tema verde */
.badge.bg-success {
    background: linear-gradient(135deg, #28a745 0%, #20c997 100%) !important;
}

.badge.bg-warning {
    background: linear-gradient(135deg, #ffc107 0%, #e0a800 100%) !important;
    color: #212529 !important;
}

.badge.bg-danger {
    background: linear-gradient(135deg, #dc3545 0%, #c82333 100%) !important;
}

.badge.bg-primary {
    background: linear-gradient(135deg, #28a745 0%, #20c997 100%) !important;
}

.badge.bg-purple {
    background: linear-gradient(135deg, #9c27b0 0%, #7b1fa2 100%) !important;
    color: white !important;
}

/* Formularios con tema verde */
.form-control:focus {
    border-color: #28a745 !important;
    box-shadow: 0 0 0 0.2rem rgba(40, 167, 69, 0.25) !important;
}

.form-select:focus {
    border-color: #28a745 !important;
    box-shadow: 0 0 0 0.2rem rgba(40, 167, 69, 0.25) !important;
}

/* Validación de formularios */
.was-validated .form-control:valid {
    border-color: #28a745 !important;
    background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 8 8'%3e%3cpath fill='%2328a745' d='M2.3 6.73L.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;
}

.was-validated .form-control:invalid {
    border-color: #dc3545 !important;
    background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 12 12' width='12' height='12' fill='none' stroke='%23dc3545'%3e%3ccircle cx='6' cy='6' r='4.5'/%3e%3cpath d='m5.8 4.6 2.4 2.4m0-2.4L5.8 7'/%3e%3c/svg%3e") !important;
}

/* Dropdown menus con tema verde */
.dropdown-menu {
    border: 2px solid #28a745 !important;
    border-radius: 12px !important;
    box-shadow: 0 4px 15px rgba(40, 167, 69, 0.2) !important;
}

.dropdown-item:hover {
    background-color: #f8fff9 !important;
    color: #155724 !important;
}

/* Cards con tema verde */
.card {
    border: 2px solid #e9ecef !important;
    border-radius: 15px !important;
    transition: all 0.3s ease !important;
}

.card:hover {
    border-color: #28a745 !important;
    box-shadow: 0 8px 25px rgba(40, 167, 69, 0.1) !important;
}

/* Input groups con tema verde */
.input-group-text {
    background: linear-gradient(135deg, #28a745 0%, #20c997 100%) !important;
    border: 2px solid #28a745 !important;
    color: white !important;
}

/* Progress bars con tema verde */
.progress-bar {
    background: linear-gradient(135deg, #28a745 0%, #20c997 100%) !important;
}

/* Spinners con tema verde */
.spinner-border.text-primary {
    color: #28a745 !important;
}

/* Links con tema verde */
a {
    color: #28a745 !important;
}

a:hover {
    color: #218838 !important;
}

/* Estilos personalizados para SweetAlert2 */
.swal2-custom-popup {
    border-radius: 15px !important;
    border: 2px solid #28a745 !important;
    box-shadow: 0 10px 30px rgba(40, 167, 69, 0.3) !important;
}

.swal2-custom-confirm {
    background: linear-gradient(135deg, #28a745 0%, #20c997 100%) !important;
    border: none !important;
    border-radius: 8px !important;
    padding: 12px 24px !important;
    font-weight: 600 !important;
    box-shadow: 0 4px 15px rgba(40, 167, 69, 0.3) !important;
    transition: all 0.3s ease !important;
}

.swal2-custom-confirm:hover {
    transform: translateY(-2px) !important;
    box-shadow: 0 6px 20px rgba(40, 167, 69, 0.4) !important;
}

.swal2-custom-cancel {
    background: linear-gradient(135deg, #6c757d 0%, #5a6268 100%) !important;
    border: none !important;
    border-radius: 8px !important;
    padding: 12px 24px !important;
    font-weight: 600 !important;
    box-shadow: 0 4px 15px rgba(108, 117, 125, 0.3) !important;
    transition: all 0.3s ease !important;
}

.swal2-custom-cancel:hover {
    transform: translateY(-2px) !important;
    box-shadow: 0 6px 20px rgba(108, 117, 125, 0.4) !important;
}

/* Animación de entrada para SweetAlert */
.swal2-show {
    animation: swal2-show 0.3s ease-out !important;
}

@keyframes swal2-show {
    0% {
        opacity: 0;
        transform: scale(0.8) translateY(-20px);
    }
    100% {
        opacity: 1;
        transform: scale(1) translateY(0);
    }
}

/* Texto de ayuda con tema verde */
.form-text {
    color: #28a745 !important;
}

/* Invalid feedback con tema verde */
.invalid-feedback {
    color: #dc3545 !important;
}

.valid-feedback {
    color: #28a745 !important;
}

/* Estilos específicos para notificaciones flotantes */
.alert-floating.alert-success {
    background: #ffffff !important;
    border: 2px solid #28a745 !important;
    color: #155724 !important;
}

.alert-floating.alert-danger {
    background: #ffffff !important;
    border: 2px solid #dc3545 !important;
    color: #721c24 !important;
}

.alert-floating.alert-warning {
    background: #ffffff !important;
    border: 2px solid #ffc107 !important;
    color: #856404 !important;
}

.alert-floating.alert-info {
    background: #ffffff !important;
    border: 2px solid #17a2b8 !important;
    color: #0c5460 !important;
}

/* Iconos en notificaciones */
.alert-floating.alert-success i {
    color: #28a745 !important;
}

.alert-floating.alert-danger i {
    color: #dc3545 !important;
}

.alert-floating.alert-warning i {
    color: #ffc107 !important;
}

.alert-floating.alert-info i {
    color: #17a2b8 !important;
}

/* Estilos para tarjetas de estadísticas - ELIMINADOS DUPLICADOS VERDES */

/* Estilos para Sistema de Alertas */
.clickable-card {
    transition: all 0.3s ease;
    border: 2px solid transparent;
}

.clickable-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.15);
    border-color: #28a745;
}

.alert-active {
    background: linear-gradient(135deg, #fff5f5 0%, #ffe6e6 100%);
    border-left: 4px solid #dc3545 !important;
    animation: pulse-alert 2s infinite;
}

@keyframes pulse-alert {
    0% { box-shadow: 0 0 0 0 rgba(220, 53, 69, 0.4); }
    70% { box-shadow: 0 0 0 10px rgba(220, 53, 69, 0); }
    100% { box-shadow: 0 0 0 0 rgba(220, 53, 69, 0); }
}

.stats-card-alert-overdue {
    background: linear-gradient(135deg, #fff 0%, #f8f9fa 100%);
}

.stats-card-alert-due-soon {
    background: linear-gradient(135deg, #fff 0%, #fff3cd 100%);
}

.stats-card-alert-pending {
    background: linear-gradient(135deg, #fff 0%, #d1ecf1 100%);
}

.stats-card-alert-periodic {
    background: linear-gradient(135deg, #fff 0%, #e2e3e5 100%);
}

/* Estilos para modales de alertas */
.swal2-popup {
    border-radius: 15px !important;
}

.swal2-title {
    color: #333 !important;
    font-weight: 600 !important;
}

/* Responsive para alertas */
@media (max-width: 768px) {
    .clickable-card:hover {
        transform: none;
    }
}

/* Estilos para tabla de proveedores */
#providersTable {
    background: #fff;
    border-radius: 12px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    overflow: hidden;
}

#providersTable thead th {
    background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%);
    border: none;
    font-weight: 600;
    color: #495057;
    padding: 1rem;
    text-align: left;
    vertical-align: middle;
}

#providersTable tbody tr {
    transition: all 0.3s ease;
    border-bottom: 1px solid #f1f3f4;
}

#providersTable tbody tr:hover {
    background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%);
    transform: translateY(-1px);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

#providersTable tbody td {
    padding: 1rem;
    vertical-align: middle;
    border: none;
}

.status-toggle-btn {
    transition: all 0.3s ease;
    border-radius: 20px;
    font-weight: 500;
    min-width: 80px;
}

.status-toggle-btn:hover {
    transform: scale(1.05);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.2);
}

.status-toggle-btn.btn-success {
    background: linear-gradient(135deg, #28a745 0%, #20c997 100%);
    border: none;
}

.status-toggle-btn.btn-warning {
    background: linear-gradient(135deg, #ffc107 0%, #fd7e14 100%);
    border: none;
    color: #fff;
}

.btn-group .btn {
    border-radius: 6px;
    margin: 0 2px;
    transition: all 0.3s ease;
}

.btn-group .btn:hover {
    transform: translateY(-1px);
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.15);
}

.company-info strong {
    font-size: 1.1rem;
    font-weight: 600;
}

/* Responsive para tabla */
@media (max-width: 768px) {
    .table-responsive {
        border-radius: 8px;
    }
    
    #providersTable thead th,
    #providersTable tbody td {
        padding: 0.75rem 0.5rem;
        font-size: 0.9rem;
    }
    
    .status-toggle-btn {
        min-width: 70px;
        font-size: 0.8rem;
    }
    
    .btn-group .btn {
        padding: 0.25rem 0.5rem;
    }
}

@media (max-width: 576px) {
    #providersTable thead th,
    #providersTable tbody td {
        padding: 0.5rem 0.25rem;
        font-size: 0.8rem;
    }
    
    .status-toggle-btn {
        min-width: 60px;
        font-size: 0.75rem;
    }
}

/* Estilos para estadísticas de facturas mejoradas */
.stats-card-paid {
    background: linear-gradient(135deg, #fff 0%, #f8f9fa 100%);
    border-left: 4px solid #28a745;
}

.stats-card-periodic {
    background: linear-gradient(135deg, #fff 0%, #f8f9fa 100%);
    border-left: 4px solid #007bff;
}

.stats-card small {
    font-size: 0.75rem;
    font-weight: 500;
    margin-top: 0.25rem;
    display: block;
}

/* Responsive para estadísticas de facturas */
@media (max-width: 1200px) {
    .stats-card {
        margin-bottom: 1rem;
    }
    
    .stats-card small {
        font-size: 0.7rem;
    }
}

@media (max-width: 768px) {
    .stats-card {
        margin-bottom: 0.75rem;
    }
    
    .stats-card small {
        display: none;
    }
}
