/**
 * Estilos CSS para la interfaz de cliente de Honorarios
 * Versión: 1.6.0
 */

/* Estilos generales */
.honorarios-container {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen-Sans, Ubuntu, Cantarell, 'Helvetica Neue', sans-serif;
    line-height: 1.6;
    color: #374151;
}

/* Tabla de cheques */
.honorarios-table {
    width: 100%;
    border-collapse: collapse;
    background-color: white;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 1px 3px 0 rgba(0, 0, 0, 0.1), 0 1px 2px 0 rgba(0, 0, 0, 0.06);
}

.honorarios-table th {
    background-color: #f9fafb;
    padding: 12px 16px;
    text-align: left;
    font-weight: 600;
    color: #374151;
    border-bottom: 1px solid #e5e7eb;
    font-size: 0.875rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.honorarios-table td {
    padding: 16px;
    border-bottom: 1px solid #e5e7eb;
    vertical-align: middle;
}

.honorarios-table tr:last-child td {
    border-bottom: none;
}

.honorarios-table tr:hover {
    background-color: #f9fafb;
}

/* Estados de cheques */
.estado-badge {
    display: inline-flex;
    align-items: center;
    padding: 4px 12px;
    border-radius: 9999px;
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.estado-en_cartera {
    background-color: #d1fae5;
    color: #065f46;
}

.estado-depositado {
    background-color: #dbeafe;
    color: #1e40af;
}

.estado-retirado {
    background-color: #f3e8ff;
    color: #7c3aed;
}

.estado-rechazado {
    background-color: #fee2e2;
    color: #dc2626;
}

/* Colores de vencimiento */
.vencimiento-normal {
    color: #374151;
}

.vencimiento-proximo {
    color: #ea580c;
    font-weight: 600;
}

.vencimiento-vencido {
    color: #dc2626;
    font-weight: 700;
}

/* Botones de acción */
.btn {
    display: inline-flex;
    align-items: center;
    padding: 8px 16px;
    border-radius: 6px;
    font-size: 0.875rem;
    font-weight: 500;
    text-decoration: none;
    border: none;
    cursor: pointer;
    transition: all 0.2s;
    gap: 6px;
}

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

.btn-primary {
    background-color: #2563eb;
    color: white;
}

.btn-primary:hover {
    background-color: #1d4ed8;
}

.btn-success {
    background-color: #059669;
    color: white;
}

.btn-success:hover {
    background-color: #047857;
}

.btn-warning {
    background-color: #d97706;
    color: white;
}

.btn-warning:hover {
    background-color: #b45309;
}

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

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

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

.btn-secondary:hover {
    background-color: #4b5563;
}

/* Filtros */
.filtros-container {
    background-color: white;
    padding: 24px;
    border-radius: 8px;
    box-shadow: 0 1px 3px 0 rgba(0, 0, 0, 0.1), 0 1px 2px 0 rgba(0, 0, 0, 0.06);
    margin-bottom: 24px;
}

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

.form-group {
    display: flex;
    flex-direction: column;
}

.form-label {
    font-size: 0.875rem;
    font-weight: 500;
    color: #374151;
    margin-bottom: 4px;
}

.form-select,
.form-input {
    padding: 8px 12px;
    border: 1px solid #d1d5db;
    border-radius: 6px;
    font-size: 0.875rem;
    background-color: white;
    transition: border-color 0.2s;
}

.form-select:focus,
.form-input:focus {
    outline: none;
    border-color: #2563eb;
    box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.1);
}

/* Estadísticas */
.estadisticas-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 16px;
    margin-bottom: 24px;
}

.estadistica-card {
    background-color: white;
    padding: 20px;
    border-radius: 8px;
    box-shadow: 0 1px 3px 0 rgba(0, 0, 0, 0.1), 0 1px 2px 0 rgba(0, 0, 0, 0.06);
    text-align: center;
}

.estadistica-valor {
    font-size: 2rem;
    font-weight: 700;
    color: #1f2937;
    margin-bottom: 4px;
}

.estadistica-label {
    font-size: 0.875rem;
    color: #6b7280;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.estadistica-subvalor {
    font-size: 0.75rem;
    color: #9ca3af;
    margin-top: 4px;
}

/* Modales */
.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: rgba(0, 0, 0, 0.5);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 50;
}

.modal-content {
    background-color: white;
    padding: 32px;
    border-radius: 8px;
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.25);
    max-width: 500px;
    width: 90%;
    max-height: 90vh;
    overflow-y: auto;
}

.modal-header {
    margin-bottom: 20px;
}

.modal-title {
    font-size: 1.25rem;
    font-weight: 600;
    color: #1f2937;
    margin: 0;
}

.modal-body {
    margin-bottom: 24px;
}

.modal-footer {
    display: flex;
    justify-content: flex-end;
    gap: 12px;
}

/* Alertas y notificaciones */
.alert {
    padding: 12px 16px;
    border-radius: 6px;
    margin-bottom: 16px;
    border-left: 4px solid;
}

.alert-success {
    background-color: #d1fae5;
    border-color: #10b981;
    color: #065f46;
}

.alert-warning {
    background-color: #fef3c7;
    border-color: #f59e0b;
    color: #92400e;
}

.alert-error {
    background-color: #fee2e2;
    border-color: #ef4444;
    color: #991b1b;
}

.alert-info {
    background-color: #dbeafe;
    border-color: #3b82f6;
    color: #1e40af;
}

/* Responsive */
@media (max-width: 768px) {
    .honorarios-table {
        font-size: 0.875rem;
    }
    
    .honorarios-table th,
    .honorarios-table td {
        padding: 8px 12px;
    }
    
    .filtros-grid {
        grid-template-columns: 1fr;
    }
    
    .estadisticas-grid {
        grid-template-columns: 1fr;
    }
    
    .modal-content {
        margin: 20px;
        padding: 24px;
    }
}

/* Utilidades */
.text-right {
    text-align: right;
}

.text-center {
    text-align: center;
}

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

.font-mono {
    font-family: 'Monaco', 'Menlo', 'Ubuntu Mono', monospace;
}

.hidden {
    display: none !important;
}

.flex {
    display: flex;
}

.items-center {
    align-items: center;
}

.justify-between {
    justify-content: space-between;
}

.space-x-2 > * + * {
    margin-left: 8px;
}

.space-y-4 > * + * {
    margin-top: 16px;
}

/* Iconos */
.icon {
    width: 16px;
    height: 16px;
    display: inline-block;
}

/* Estados de carga */
.loading {
    opacity: 0.6;
    pointer-events: none;
}

.spinner {
    animation: spin 1s linear infinite;
}

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

/* Colores de fondo para estados */
.bg-green-100 { background-color: #d1fae5; }
.bg-blue-100 { background-color: #dbeafe; }
.bg-purple-100 { background-color: #f3e8ff; }
.bg-red-100 { background-color: #fee2e2; }
.bg-orange-100 { background-color: #ffedd5; }
.bg-yellow-100 { background-color: #fef3c7; }

/* Colores de texto para estados */
.text-green-800 { color: #065f46; }
.text-blue-800 { color: #1e40af; }
.text-purple-800 { color: #7c3aed; }
.text-red-800 { color: #991b1b; }
.text-orange-800 { color: #92400e; }
.text-yellow-800 { color: #92400e; }

/* Colores de borde para estados */
.border-green-200 { border-color: #a7f3d0; }
.border-blue-200 { border-color: #bfdbfe; }
.border-purple-200 { border-color: #e9d5ff; }
.border-red-200 { border-color: #fecaca; }
.border-orange-200 { border-color: #fdba74; }
.border-yellow-200 { border-color: #fde68a; }
