/* Estilos base */
body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    line-height: 1.6;
    margin: 0;
    padding: 20px;
    background-color: #f5f7fa;
    color: #333;
}

.container {
    max-width: 900px;
    margin: 0 auto;
    background: white;
    padding: 30px;
    border-radius: 8px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
}

h1, h2 {
    color: #2c3e50;
    margin-bottom: 20px;
}

/* Formulario */
.form-group {
    margin-bottom: 20px;
}

label {
    display: block;
    margin-bottom: 8px;
    font-weight: 600;
}

input[type="file"] {
    width: 100%;
    padding: 10px;
    border: 1px solid #ddd;
    border-radius: 4px;
    background: #f9f9f9;
}

textarea {
    width: 100%;
    padding: 10px;
    border: 1px solid #ddd;
    border-radius: 4px;
    min-height: 100px;
    resize: vertical;
}

.btn {
    background: #3498db;
    color: white;
    border: none;
    padding: 12px 20px;
    border-radius: 4px;
    cursor: pointer;
    font-size: 16px;
    transition: background 0.3s;
}

.btn:hover {
    background: #2980b9;
}

/* Resultados */
.results-section {
    margin-top: 30px;
    padding: 20px;
    background: #f9f9f9;
    border-radius: 4px;
}

.answer-box {
    background: white;
    padding: 20px;
    border-radius: 4px;
    margin-bottom: 20px;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
    white-space: pre-line;
}

.references-box {
    background: #e8f4fc;
    padding: 15px;
    border-radius: 4px;
    font-size: 14px;
}

/* Loading */
.loading {
    text-align: center;
    margin: 30px 0;
    display: none;
}

.spinner {
    border: 5px solid #f3f3f3;
    border-top: 5px solid #3498db;
    border-radius: 50%;
    width: 50px;
    height: 50px;
    animation: spin 1s linear infinite;
    margin: 0 auto 20px;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* Historial */
.history-section {
    margin-top: 40px;
    padding: 20px;
    background: #f0f5ff;
    border-radius: 4px;
}

.history-section ul {
    list-style: none;
    padding: 0;
}

.history-section li {
    padding: 10px;
    margin-bottom: 10px;
    background: white;
    border-radius: 4px;
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.1);
    cursor: pointer;
    transition: background 0.2s;
}

.history-section li:hover {
    background: #e6f0ff;
}

.history-section small {
    color: #7f8c8d;
    font-size: 12px;
}

/* Notificaciones */
.notification {
    padding: 10px 15px;
    margin: 10px 0;
    border-radius: 4px;
    font-size: 14px;
    display: none;
}

.notification.info {
    background: #e6f7ff;
    border-left: 3px solid #1890ff;
}

.notification.error {
    background: #fff2f0;
    border-left: 3px solid #ff4d4f;
}

/* Responsive */
@media (max-width: 768px) {
    .container {
        padding: 15px;
    }
    
    .form-group, .results-section, .history-section {
        padding: 15px;
    }
}