/**
 * Estilos para la pagina End of Day Report
 * DYGO Platform
 */

/* Contenedor principal */
.eod-container {
    width: 100%;
    max-width: 1200px;
    margin: 0 auto;
    padding: 2rem 1rem;
}

/* Header EOD */
.eod-header {
    text-align: center;
    margin-bottom: 2rem;
    padding-bottom: 1.5rem;
    border-bottom: 2px solid var(--gray-200);
}

.eod-header h2 {
    font-size: 2rem;
    color: var(--gray-900);
    margin-bottom: 0.5rem;
}

.current-date {
    font-size: 1.1rem;
    color: var(--gray-600);
    font-weight: 500;
}

/* Seleccion de trafficker */
.trafficker-selection {
    margin-bottom: 2rem;
}

.selection-card {
    background: var(--bg-primary);
    border: 2px solid var(--gray-200);
    border-radius: var(--radius-lg);
    padding: 1.5rem;
}

.selection-card label {
    display: block;
    font-size: 1.1rem;
    font-weight: 600;
    color: var(--gray-700);
    margin-bottom: 0.75rem;
}

.form-select {
    width: 100%;
    padding: 0.875rem 1rem;
    font-size: 1rem;
    border: 2px solid var(--gray-200);
    border-radius: var(--radius-md);
    background: white;
    cursor: pointer;
    transition: border-color var(--transition-base);
}

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

/* Seccion del formulario EOD */
.eod-form-section {
    animation: fadeIn 0.3s ease-out;
}

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

/* Contenedor de reportes de clientes */
.client-reports-container {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

/* Tarjeta de reporte por cliente */
.client-report-card {
    background: var(--bg-primary);
    border: 2px solid var(--gray-200);
    border-radius: var(--radius-lg);
    padding: 1.5rem;
    transition: border-color var(--transition-base), box-shadow var(--transition-base);
}

.client-report-card:hover {
    border-color: var(--primary);
    box-shadow: var(--shadow-md);
}

.client-report-card:focus-within {
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.1);
}

.client-report-card h3 {
    font-size: 1.25rem;
    color: var(--gray-800);
    margin: 0 0 0.5rem 0;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.client-report-card h3 .client-icon {
    font-size: 1.5rem;
}

.client-niche {
    font-size: 0.875rem;
    color: var(--gray-500);
    margin-bottom: 1rem;
    padding-bottom: 0.75rem;
    border-bottom: 1px solid var(--gray-100);
}

.client-report-card textarea {
    width: 100%;
    min-height: 120px;
    padding: 1rem;
    font-size: 0.95rem;
    line-height: 1.6;
    border: 2px solid var(--gray-200);
    border-radius: var(--radius-md);
    resize: vertical;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
    transition: border-color var(--transition-base);
}

.client-report-card textarea:focus {
    outline: none;
    border-color: var(--primary);
}

.client-report-card textarea::placeholder {
    color: var(--gray-400);
}

/* Indicador de caracteres */
.char-counter {
    text-align: right;
    font-size: 0.75rem;
    color: var(--gray-400);
    margin-top: 0.5rem;
}

/* Seccion de guardado */
.save-section {
    margin-top: 2rem;
    padding-top: 1.5rem;
    border-top: 2px solid var(--gray-200);
}

.btn-save {
    width: 100%;
    padding: 1rem 2rem;
    font-size: 1.1rem;
    font-weight: 600;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
}

.btn-save .btn-icon {
    font-size: 1.25rem;
}

.btn-save:disabled {
    background-color: var(--gray-400);
    cursor: not-allowed;
}

/* Alertas */
.alert {
    padding: 1rem 1.25rem;
    border-radius: var(--radius-md);
    margin-bottom: 1.5rem;
    display: flex;
    align-items: center;
    gap: 0.75rem;
    font-size: 0.95rem;
}

.alert-icon {
    font-size: 1.25rem;
    flex-shrink: 0;
}

.alert-warning {
    background-color: #fff8e6;
    border: 1px solid var(--warning);
    color: #92640d;
}

.alert-success {
    background-color: #e6f9ed;
    border: 1px solid var(--success);
    color: #0d6b32;
}

/* Estado vacio */
.empty-state {
    text-align: center;
    padding: 3rem 1.5rem;
    background: var(--bg-secondary);
    border-radius: var(--radius-lg);
    border: 2px dashed var(--gray-300);
}

.empty-icon {
    font-size: 4rem;
    margin-bottom: 1rem;
    opacity: 0.5;
}

.empty-state h3 {
    font-size: 1.25rem;
    color: var(--gray-700);
    margin-bottom: 0.5rem;
}

.empty-state p {
    color: var(--gray-500);
    max-width: 400px;
    margin: 0 auto;
}

/* Estado de carga */
.loading-state {
    text-align: center;
    padding: 3rem;
}

.loading-state .spinner {
    width: 50px;
    height: 50px;
    border: 4px solid var(--gray-200);
    border-top-color: var(--primary);
    border-radius: 50%;
    margin: 0 auto 1rem;
    animation: spin 1s linear infinite;
}

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

.loading-state p {
    color: var(--gray-600);
    font-size: 0.95rem;
}

/* Responsive */
@media (max-width: 640px) {
    .eod-container {
        padding: 1rem;
    }

    .eod-header h2 {
        font-size: 1.5rem;
    }

    .selection-card,
    .client-report-card {
        padding: 1rem;
    }

    .client-report-card h3 {
        font-size: 1.1rem;
    }

    .client-report-card textarea {
        min-height: 100px;
        padding: 0.75rem;
    }
}

/* Animacion de exito */
.success-animation {
    animation: successPulse 0.5s ease-out;
}

@keyframes successPulse {
    0% {
        transform: scale(0.95);
        opacity: 0;
    }
    50% {
        transform: scale(1.02);
    }
    100% {
        transform: scale(1);
        opacity: 1;
    }
}

/* Estilos para textarea con contenido */
.client-report-card textarea.has-content {
    border-color: var(--success);
    background-color: #f8fdf9;
}

/* Tooltip para indicaciones */
.report-hint {
    font-size: 0.8rem;
    color: var(--gray-500);
    margin-top: 0.5rem;
    font-style: italic;
}
