/* BADGES PARA GARANTIAS */
.badge {
    display: inline-block;
    padding: 0.25em 0.7em;
    font-size: 0.85em;
    font-weight: 600;
    border-radius: 0.7em;
    line-height: 1;
    vertical-align: middle;
    white-space: nowrap;
    margin-right: 0.2em;
}
.badge-warning {
    background: rgba(255, 193, 7, 0.15);
    color: #ffaa00;
}
.badge-success {
    background: rgba(40, 167, 69, 0.15);
    color: #00b894;
}
.badge-secondary {
    background: rgba(99, 110, 114, 0.15);
    color: #636e72;
}
.badge-prioridad_alta {
    background: rgba(255, 0, 102, 0.15);
    color: #ff0066;
}
.badge-prioridad_media {
    background: rgba(255, 193, 7, 0.15);
    color: #ffaa00;
}
.badge-prioridad_baja {
    background: rgba(0, 217, 255, 0.15);
    color: #00d9ff;
}
/**
 * ============================================================================
 * MÓDULO DE FINANZAS - ESTILOS ADICIONALES
 * ============================================================================
 */

/* Cuadre de Caja */
.cuadre-caja {
    background: linear-gradient(135deg, rgba(0, 217, 255, 0.1), rgba(255, 0, 255, 0.05));
    border: 2px solid var(--border-color);
    border-radius: 10px;
    padding: 0.75rem;
    margin-bottom: 1rem;
    box-shadow: 0 4px 20px rgba(0, 217, 255, 0.15);
}

.cuadre-caja h2 {
    font-size: 1rem;
    margin-bottom: 0.6rem;
    display: flex;
    align-items: center;
    gap: 0.4rem;
}

/* Hacer stats-grid más compacto en finanzas */
.cuadre-caja .stats-grid {
    gap: 0.75rem;
    margin-bottom: 0;
}

.cuadre-caja .stat-card {
    padding: 0.75rem;
    gap: 0.75rem;
    border-radius: 10px;
}

.cuadre-caja .stat-icon {
    width: 40px;
    height: 40px;
    font-size: 1.3rem;
    border-radius: 8px;
}

.cuadre-caja .stat-label {
    font-size: 0.75rem;
    margin-bottom: 0.2rem;
}

.cuadre-caja .stat-value {
    font-size: 1.3rem;
}

/* Stats específicos para finanzas */
.stat-card.income {
    border-left: 3px solid var(--success);
}

.stat-card.income .stat-icon {
    background: linear-gradient(135deg, rgba(0, 255, 136, 0.2), rgba(0, 255, 136, 0.05));
    color: var(--success);
}

.stat-card.expense {
    border-left: 3px solid var(--danger);
}

.stat-card.expense .stat-icon {
    background: linear-gradient(135deg, rgba(255, 0, 102, 0.2), rgba(255, 0, 102, 0.05));
    color: var(--danger);
}

.stat-card.balance {
    border-left: 3px solid var(--primary);
}

.stat-card.balance .stat-icon {
    background: linear-gradient(135deg, rgba(0, 217, 255, 0.2), rgba(0, 217, 255, 0.05));
    color: var(--primary);
}

/* ===== DESGLOSE DE PAGOS ===== */
.payment-breakdown {
    margin-top: 0.75rem;
    padding-top: 0.75rem;
    border-top: 1px solid var(--border-color);
}

.payment-breakdown h3 {
    font-size: 0.85rem;
    color: var(--text-secondary);
    margin-bottom: 0.5rem;
    display: flex;
    align-items: center;
    gap: 6px;
}

.payment-methods-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
    gap: 8px;
}

.payment-method-card {
    background: linear-gradient(135deg, rgba(0, 217, 255, 0.05), rgba(255, 0, 255, 0.05));
    border: 1px solid var(--border-color);
    border-radius: 8px;
    padding: 8px;
    display: flex;
    align-items: center;
    gap: 8px;
    transition: all 0.3s ease;
}

.payment-method-card:hover {
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(0, 217, 255, 0.2);
    border-color: var(--primary);
}

.payment-icon {
    width: 32px;
    height: 32px;
    background: linear-gradient(135deg, var(--primary), #00a8cc);
    border-radius: 6px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 16px;
    color: var(--text-primary);
    flex-shrink: 0;
}

.payment-info {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 2px;
    min-width: 0;
}

.payment-label {
    font-size: 10px;
    color: var(--text-secondary);
    text-transform: uppercase;
    font-weight: 600;
    letter-spacing: 0.3px;
}

.payment-value {
    font-size: 15px;
    font-weight: 700;
    color: var(--success);
}

/* Tabs Navigation */
.tabs-nav {
    display: flex;
    gap: 1rem;
    margin-bottom: 2rem;
    border-bottom: 2px solid var(--border-color);
}

.tab-btn {
    background: none;
    border: none;
    color: var(--text-secondary);
    padding: 1rem 2rem;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s;
    border-bottom: 3px solid transparent;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.tab-btn:hover {
    color: var(--primary);
}

.tab-btn.active {
    color: var(--primary);
    border-bottom-color: var(--primary);
}

/* Tab Content */
.tab-content {
    display: none;
}

.tab-content.active {
    display: block;
}

/* Report Controls */
.report-controls {
    background: var(--bg-card);
    border: 2px solid var(--border-color);
    border-radius: 12px;
    padding: 2rem;
    margin-bottom: 2rem;
}

.report-controls h3 {
    margin-bottom: 1.5rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.form-row {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 1rem;
    align-items: end;
}

.form-group label {
    display: block;
    margin-bottom: 0.5rem;
    font-weight: 600;
    color: var(--text-secondary);
}

.form-group select,
.form-group input[type="date"] {
    width: 100%;
    padding: 0.75rem;
    background: rgba(0, 0, 0, 0.3);
    border: 1px solid var(--border-color);
    border-radius: 8px;
    color: var(--text-light);
    font-family: inherit;
}

/* Report Result */
.report-result {
    animation: fadeIn 0.5s;
}

.report-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 2rem;
}

.report-header h3 {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.report-summary {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 1.5rem;
    margin-bottom: 3rem;
}

.summary-card {
    background: var(--bg-card);
    border: 2px solid var(--border-color);
    border-radius: 12px;
    padding: 2rem;
}

.summary-card h4 {
    font-size: 1.1rem;
    margin-bottom: 1rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    color: var(--text-secondary);
}

.summary-card .amount {
    font-size: 2.5rem;
    font-weight: 800;
    margin-bottom: 1.5rem;
}

.summary-card.income .amount {
    color: var(--success);
}

.summary-card.expense .amount {
    color: var(--danger);
}

.summary-card.balance .amount {
    color: var(--primary);
}

.breakdown {
    border-top: 1px solid var(--border-color);
    padding-top: 1rem;
}

.breakdown-item {
    display: flex;
    justify-content: space-between;
    padding: 0.5rem 0;
    color: var(--text-secondary);
}

.breakdown-item span:last-child {
    font-weight: 600;
    color: var(--text-light);
}

/* Report Tables */
.report-tables {
    display: grid;
    gap: 2rem;
}

.report-table-section {
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    border-radius: 12px;
}

/* Scrollbar personalizado para tablas de reporte */
.report-table-section::-webkit-scrollbar {
    height: 8px;
}

.report-table-section::-webkit-scrollbar-track {
    background: rgba(0, 0, 0, 0.2);
    border-radius: 4px;
}

.report-table-section::-webkit-scrollbar-thumb {
    background: var(--primary);
    border-radius: 4px;
}

.report-table-section::-webkit-scrollbar-thumb:hover {
    background: var(--secondary);
}

.report-table-section h4 {
    margin-bottom: 1rem;
    color: var(--primary);
}

.report-table {
    width: 100%;
    background: var(--bg-card);
    border-collapse: collapse;
    border-radius: 8px;
    overflow: hidden;
    min-width: 600px;
}

.report-table thead {
    background: rgba(0, 217, 255, 0.1);
}

.report-table th,
.report-table td {
    padding: 1rem;
    text-align: left;
    border-bottom: 1px solid var(--border-color);
}

.report-table th {
    font-weight: 600;
    color: var(--primary);
}

.report-table tbody tr:hover {
    background: rgba(0, 217, 255, 0.05);
}

/* Print Styles */
@media print {
    body {
        background: white;
        color: black;
    }
    
    .admin-header,
    .tabs-nav,
    .report-controls,
    .report-filters,
    .btn-secondary {
        display: none !important;
    }
    
    .report-result {
        display: block !important;
    }
}

/* ===== FILTROS DE REPORTE ===== */
.report-filters {
    background: linear-gradient(135deg, rgba(0, 217, 255, 0.05), rgba(255, 0, 255, 0.03));
    border: 2px solid var(--border-color);
    border-radius: 16px;
    padding: 2rem;
    margin: 2rem 0;
    animation: fadeIn 0.4s ease;
}

.filters-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1.5rem;
    padding-bottom: 1rem;
    border-bottom: 2px solid var(--border-color);
}

.filters-header h3 {
    font-size: 1.3rem;
    color: var(--primary);
    display: flex;
    align-items: center;
    gap: 0.5rem;
    margin: 0;
}

.filters-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 1.5rem;
}

.filter-group {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: 10px;
    padding: 1.2rem;
    transition: all 0.3s ease;
}

.filter-group:hover {
    border-color: var(--primary);
    box-shadow: 0 4px 15px rgba(0, 217, 255, 0.15);
}

.filter-group h4 {
    font-size: 0.95rem;
    color: var(--text-secondary);
    margin: 0 0 1rem 0;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-weight: 600;
}

.filter-checkboxes {
    display: flex;
    flex-direction: column;
    gap: 0.8rem;
}

.filter-checkbox {
    display: flex;
    align-items: center;
    gap: 0.6rem;
    cursor: pointer;
    padding: 0.4rem;
    border-radius: 6px;
    transition: all 0.2s ease;
    user-select: none;
}

.filter-checkbox:hover {
    background: rgba(0, 217, 255, 0.05);
}

.filter-checkbox input[type="checkbox"] {
    width: 18px;
    height: 18px;
    cursor: pointer;
    accent-color: var(--primary);
}

.filter-checkbox span {
    font-size: 0.9rem;
    color: var(--text-light);
}

.filter-select-wrapper,
.filter-search-wrapper {
    width: 100%;
}

.filter-select,
.filter-search {
    width: 100%;
    background: rgba(10, 10, 20, 0.5);
    border: 2px solid var(--border-color);
    border-radius: 8px;
    padding: 0.7rem;
    color: var(--text-light);
    font-size: 0.9rem;
    font-family: 'Montserrat', sans-serif;
    transition: all 0.3s ease;
}

.filter-select:focus,
.filter-search:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 10px rgba(0, 217, 255, 0.3);
}

.filter-range {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    width: 100%;
}

.filter-range span {
    color: var(--text-secondary);
    font-weight: 600;
    flex-shrink: 0;
}

.filter-input-sm {
    flex: 1;
    min-width: 0;
    max-width: calc(50% - 1rem);
    background: rgba(10, 10, 20, 0.5);
    border: 2px solid var(--border-color);
    border-radius: 8px;
    padding: 0.6rem;
    color: var(--text-light);
    font-size: 0.85rem;
    font-family: 'Montserrat', sans-serif;
    transition: all 0.3s ease;
}

.filter-input-sm:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 10px rgba(0, 217, 255, 0.3);
}

.btn-sm {
    padding: 0.5rem 1rem;
    font-size: 0.85rem;
}

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

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

@keyframes spin {
    from {
        transform: rotate(0deg);
    }
    to {
        transform: rotate(360deg);
    }
}

/* ===== PAGINACIÓN ===== */
.pagination-container {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 15px;
    margin-top: 20px;
    padding: 15px;
}

.pagination-btn {
    background: linear-gradient(135deg, var(--primary), #00a8cc);
    color: var(--text-primary);
    border: none;
    padding: 10px 20px;
    border-radius: 8px;
    cursor: pointer;
    font-weight: 600;
    font-size: 14px;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    gap: 8px;
}

.pagination-btn:hover:not(:disabled) {
    background: linear-gradient(135deg, #00a8cc, var(--primary));
    transform: translateY(-2px);
    box-shadow: 0 8px 20px rgba(0, 217, 255, 0.3);
}

.pagination-btn:disabled {
    background: linear-gradient(135deg, #444, #555);
    cursor: not-allowed;
    opacity: 0.5;
}

.pagination-info {
    color: var(--text-secondary);
    font-size: 14px;
    font-weight: 500;
    padding: 0 15px;
    white-space: nowrap;
}

/* ===== MODALES ===== */
.modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(10, 10, 15, 0.95);
    backdrop-filter: blur(10px);
    z-index: 1000;
    align-items: center;
    justify-content: center;
}

.modal.show {
    display: flex;
}

.modal-content {
    background: linear-gradient(135deg, rgba(22, 22, 42, 0.98), rgba(26, 26, 50, 0.98));
    border: 2px solid var(--border-color);
    border-radius: 20px;
    max-width: 700px;
    width: 90%;
    max-height: 90vh;
    overflow-y: auto;
    box-shadow: 0 0 60px rgba(0, 217, 255, 0.3);
    animation: modalSlideUp 0.4s ease;
    position: relative;
}

.modal-header {
    padding: 2rem;
    border-bottom: 2px solid var(--border-color);
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: linear-gradient(135deg, rgba(0, 217, 255, 0.1), rgba(255, 0, 255, 0.05));
}

.modal-header h2 {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--primary);
    margin: 0;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.close-btn {
    background: rgba(255, 0, 102, 0.2);
    border: 2px solid rgba(255, 0, 255, 0.3);
    color: var(--accent);
    width: 40px;
    height: 40px;
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    line-height: 1;
    transition: all 0.3s ease;
    font-family: Arial, sans-serif;
}

.close-btn:hover {
    background: rgba(255, 0, 102, 0.4);
    transform: rotate(90deg);
    box-shadow: 0 0 20px rgba(255, 0, 255, 0.6);
}

/* Form Styles dentro de modales */
.modal-content form {
    padding: 2rem;
}

.modal-content .form-group {
    margin-bottom: 1.5rem;
}

.modal-content .form-group label {
    display: block;
    margin-bottom: 0.5rem;
    font-weight: 600;
    color: var(--text-light);
    font-size: 0.9rem;
}

.modal-content input[type="text"],
.modal-content input[type="number"],
.modal-content input[type="date"],
.modal-content select,
.modal-content textarea {
    width: 100%;
    padding: 0.875rem;
    background: rgba(10, 10, 20, 0.6);
    border: 2px solid var(--border-color);
    border-radius: 10px;
    color: var(--text-light);
    font-size: 0.95rem;
    font-family: inherit;
    transition: all 0.3s ease;
}

/* Mejorar visibilidad del icono del calendario */
.modal-content input[type="date"]::-webkit-calendar-picker-indicator {
    filter: invert(1) brightness(1.5);
    cursor: pointer;
    opacity: 0.9;
}

.modal-content input[type="date"]::-webkit-calendar-picker-indicator:hover {
    opacity: 1;
    filter: invert(1) brightness(2);
}

.modal-content input:focus,
.modal-content select:focus,
.modal-content textarea:focus {
    outline: none;
    border-color: var(--primary);
    background: rgba(10, 10, 20, 0.8);
    box-shadow: 0 0 15px rgba(0, 217, 255, 0.3);
}

.modal-content input::placeholder,
.modal-content textarea::placeholder {
    color: var(--text-secondary);
}

.modal-content select {
    cursor: pointer;
}

.modal-content textarea {
    resize: vertical;
    min-height: 80px;
}

/* Form Actions */
.form-actions {
    display: flex;
    gap: 1rem;
    justify-content: flex-end;
    margin-top: 2rem;
    padding-top: 1.5rem;
    border-top: 2px solid var(--border-color);
}

.form-actions .btn-primary,
.form-actions .btn-secondary {
    padding: 0.875rem 2rem;
    border-radius: 10px;
    font-weight: 600;
    font-size: 0.95rem;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    border: 2px solid;
}

.form-actions .btn-primary {
    background: linear-gradient(135deg, var(--primary), var(--accent));
    border-color: var(--primary);
    color: var(--text-light);
}

.form-actions .btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(0, 217, 255, 0.4);
}

.form-actions .btn-secondary {
    background: rgba(255, 255, 255, 0.05);
    border-color: var(--border-color);
    color: var(--text-light);
}

.form-actions .btn-secondary:hover {
    background: rgba(255, 255, 255, 0.1);
    border-color: var(--text-secondary);
}

/* ===== BOTONES DE ACCIÓN ===== */
.action-buttons {
    display: flex;
    gap: 0.5rem;
}


/* Unifica tamaño y estilo de todos los botones de acción de garantías */
.btn-action {
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid var(--border-color);
    color: var(--primary);
    padding: 0.5rem 0.8rem;
    border-radius: 6px;
    cursor: pointer;
    font-size: 0.9rem;
    min-width: 38px;
    min-height: 38px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
}

.btn-edit {
    color: var(--primary);
}

.btn-delete {
    color: var(--danger);
}

.btn-success {
    color: #fff;
}

.btn-warning {
    color: #fff;
}

.btn-secondary {
    color: #fff;
}

.btn-edit:hover {
    background: rgba(0, 217, 255, 0.2);
    border-color: var(--primary);
    box-shadow: 0 0 15px rgba(0, 217, 255, 0.4);
}

.btn-delete {
    color: var(--danger);
}

.btn-delete:hover {
    background: rgba(255, 0, 102, 0.2);
    border-color: var(--danger);
    box-shadow: 0 0 15px rgba(255, 0, 102, 0.4);
}

/* Responsivo - Tablet */
@media (max-width: 1024px) {
    /* Cuadre de Caja - Tablet */
    .cuadre-caja .stats-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 0.75rem;
    }
    
    /* Payment Methods Grid - Tablet */
    .payment-methods-grid {
        grid-template-columns: repeat(3, 1fr);
        gap: 0.75rem;
    }
    
    /* Reportes - Tablet */
    .report-summary {
        grid-template-columns: repeat(2, 1fr);
    }
    
    /* Filtros - Tablet */
    .filters-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    
    /* Tablas - Scroll horizontal en tablet */
    .table-container {
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
        border-radius: 12px;
        box-shadow: inset 0 0 0 1px var(--border-color);
    }
    
    .products-table {
        min-width: 900px;
    }
    
    .report-table-section {
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
    }
    
    .report-table {
        min-width: 700px;
    }
}

/* Responsivo - Móvil */
@media (max-width: 768px) {
    /* Cuadre de Caja - Móvil */
    .cuadre-caja {
        padding: 1rem;
    }
    
    .cuadre-caja .stats-grid {
        grid-template-columns: 1fr;
        gap: 0.75rem;
    }
    
    .cuadre-caja .stat-card {
        padding: 1rem;
    }
    
    .cuadre-caja .stat-value {
        font-size: 1.5rem;
    }
    
    /* Payment Methods Grid - Móvil */
    .payment-methods-grid {
        grid-template-columns: 1fr;
        gap: 0.5rem;
    }
    
    .payment-method-card {
        padding: 0.75rem;
    }
    
    /* Form Row - Móvil */
    .form-row {
        grid-template-columns: 1fr;
    }
    
    /* Report Summary - Móvil */
    .report-summary {
        grid-template-columns: 1fr;
    }
    
    .summary-card {
        padding: 1.25rem;
    }
    
    .summary-card .amount {
        font-size: 1.8rem;
    }
    
    /* Filtros - Móvil */
    .filters-grid {
        grid-template-columns: 1fr;
    }
    
    .report-filters {
        padding: 1rem;
    }
    
    /* Layout de generar reportes en móvil */
    .report-controls > div[style*="grid-template-columns"] {
        grid-template-columns: 1fr !important;
    }
    
    .report-controls {
        padding: 1rem;
    }
    
    /* Tabs Navigation - Móvil */
    .tabs-nav {
        flex-wrap: nowrap;
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
        gap: 0.5rem;
        padding: 0.5rem;
        scrollbar-width: thin;
    }
    
    .tabs-nav::-webkit-scrollbar {
        height: 4px;
    }
    
    .tabs-nav::-webkit-scrollbar-track {
        background: rgba(0, 0, 0, 0.2);
    }
    
    .tabs-nav::-webkit-scrollbar-thumb {
        background: var(--primary);
        border-radius: 4px;
    }
    
    .tab-btn {
        padding: 0.75rem 1rem;
        font-size: 0.85rem;
        white-space: nowrap;
        flex-shrink: 0;
    }
    
    /* Tablas - Móvil */
    .products-table {
        min-width: 800px;
        font-size: 0.8em;
    }
    
    .products-table th,
    .products-table td {
        padding: 0.6rem 0.75rem;
    }
    
    .table-container {
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
        border-radius: 8px;
        margin: 0 -1rem;
        padding: 0 1rem;
    }
    
    .report-table {
        min-width: 600px;
        font-size: 0.85em;
    }
    
    /* Modales - Móvil */
    .modal-content {
        width: 95%;
        max-height: 95vh;
        margin: 1rem;
    }
    
    .modal-header {
        padding: 1rem;
    }
    
    .modal-content form {
        padding: 1rem;
    }
    
    /* Report Header - Móvil */
    .report-header {
        flex-direction: column;
        gap: 1rem;
        align-items: flex-start;
    }
    
    .report-header > div {
        width: 100%;
    }
    
    .report-header button {
        width: 100%;
    }
}

/* Responsivo - Móvil Pequeño */
@media (max-width: 480px) {
    /* Cuadre de Caja - Móvil pequeño */
    .cuadre-caja {
        padding: 0.75rem;
    }
    
    .cuadre-caja h2 {
        font-size: 0.95rem;
    }
    
    .cuadre-caja .stat-value {
        font-size: 1.3rem;
    }
    
    .cuadre-caja .stat-label {
        font-size: 0.7rem;
    }
    
    /* Tabs - Móvil pequeño */
    .tab-btn {
        padding: 0.6rem 0.85rem;
        font-size: 0.8rem;
    }
    
    .tab-btn i {
        font-size: 0.9rem;
    }
    
    /* Summary Cards - Móvil pequeño */
    .summary-card {
        padding: 1rem;
    }
    
    .summary-card .amount {
        font-size: 1.5rem;
    }
    
    .summary-card h4 {
        font-size: 0.95rem;
    }
    
    /* Actions Bar - Móvil pequeño */
    .actions-bar {
        flex-direction: column;
        gap: 0.75rem;
    }
    
    .actions-bar .search-box {
        width: 100%;
    }
}

/* ===== NOTIFICACIONES ===== */
.notification {
    position: fixed;
    top: 20px;
    right: 20px;
    background: linear-gradient(135deg, rgba(22, 22, 42, 0.98), rgba(26, 26, 50, 0.98));
    border: 2px solid var(--border-color);
    border-radius: 12px;
    padding: 1rem 1.5rem;
    min-width: 300px;
    max-width: 400px;
    box-shadow: 0 8px 30px rgba(0, 0, 0, 0.5);
    transform: translateX(500px);
    opacity: 0;
    transition: all 0.4s ease;
    z-index: 2000;
    color: var(--text-light);
    font-weight: 500;
}

.notification.show {
    transform: translateX(0);
    opacity: 1;
}

.notification.success {
    border-color: var(--success);
    box-shadow: 0 8px 30px rgba(0, 255, 136, 0.3);
}

.notification.error {
    border-color: var(--danger);
    box-shadow: 0 8px 30px rgba(255, 0, 102, 0.3);
}

.notification.warning {
    border-color: var(--warning);
    box-shadow: 0 8px 30px rgba(255, 170, 0, 0.3);
}
/* ============================================================================
   CALENDARIO VISUAL
   ============================================================================ */

.mini-calendar-container {
    display: grid;
    grid-template-columns: 350px 1fr;
    gap: 1.5rem;
    margin-bottom: 1.5rem;
    background: var(--card-bg);
    border: 1px solid var(--border-color);
    border-radius: 12px;
    padding: 1.5rem;
}

.mini-calendar {
    background: rgba(0, 217, 255, 0.05);
    border: 1px solid var(--border-color);
    border-radius: 10px;
    padding: 1rem;
}

.calendar-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1rem;
    padding-bottom: 0.75rem;
    border-bottom: 1px solid var(--border-color);
}

.calendar-month-year {
    font-weight: 600;
    font-size: 1.1rem;
    color: var(--primary);
}

.calendar-nav {
    background: transparent;
    border: 1px solid var(--border-color);
    color: var(--text-light);
    width: 32px;
    height: 32px;
    border-radius: 6px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
}

.calendar-nav:hover {
    background: var(--primary);
    border-color: var(--primary);
    color: var(--bg-dark);
}

.calendar-weekdays {
    display: grid;
    grid-template-columns: repeat(7, 1fr);
    gap: 4px;
    margin-bottom: 0.5rem;
    font-size: 0.75rem;
    font-weight: 600;
    color: var(--text-muted);
    text-align: center;
}

.calendar-days {
    display: grid;
    grid-template-columns: repeat(7, 1fr);
    gap: 4px;
}

.calendar-day {
    aspect-ratio: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 6px;
    font-size: 0.85rem;
    cursor: pointer;
    transition: all 0.2s ease;
    border: 1px solid transparent;
    color: var(--text-light);
}

.calendar-day:hover:not(.disabled):not(.other-month) {
    background: rgba(0, 217, 255, 0.2);
    border-color: var(--primary);
}

.calendar-day.selected {
    background: var(--primary);
    color: var(--bg-dark);
    font-weight: 700;
    border-color: var(--primary);
}

.calendar-day.today {
    border: 2px solid var(--success);
    color: var(--success);
    font-weight: 600;
}

.calendar-day.other-month {
    color: var(--text-muted);
    opacity: 0.3;
}

.calendar-day.disabled {
    cursor: not-allowed;
    opacity: 0.3;
}

.calendar-footer {
    display: flex;
    gap: 0.5rem;
    margin-top: 1rem;
    padding-top: 0.75rem;
    border-top: 1px solid var(--border-color);
}

.btn-calendar-action {
    flex: 1;
    padding: 0.5rem;
    background: transparent;
    border: 1px solid var(--border-color);
    border-radius: 6px;
    color: var(--text-light);
    font-size: 0.85rem;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.4rem;
}

.btn-calendar-action:hover {
    background: var(--primary);
    border-color: var(--primary);
    color: var(--bg-dark);
}

.selected-dates-info {
    display: flex;
    flex-direction: column;
    justify-content: center;
    gap: 1rem;
}

.selected-date-item {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 1rem;
    background: rgba(0, 217, 255, 0.05);
    border: 1px solid var(--border-color);
    border-radius: 8px;
}

.selected-date-item i {
    font-size: 1.5rem;
    color: var(--primary);
}

.selected-date-item span {
    color: var(--text-muted);
    font-size: 0.9rem;
}

.selected-date-item strong {
    color: var(--text-light);
    font-size: 1.1rem;
    margin-left: auto;
}

/* Responsivo - Calendario */
@media (max-width: 1024px) {
    .mini-calendar-container {
        grid-template-columns: 1fr;
    }
    
    .calendar-days {
        gap: 6px;
    }
    
    .calendar-day {
        font-size: 0.9rem;
    }
}

@media (max-width: 768px) {
    .mini-calendar-container {
        grid-template-columns: 1fr;
        padding: 1rem;
    }
    
    .mini-calendar {
        padding: 0.75rem;
    }
    
    .calendar-days {
        gap: 4px;
    }
    
    .calendar-day {
        font-size: 0.8rem;
    }
}