/* PAS Analyzer - Estilos */

.pas-container {
    max-width: 1200px;
    margin: 30px auto;
    font-family: 'Segoe UI', Roboto, sans-serif;
    padding: 0 20px;
}

.pas-panel {
    background: white;
    border: 1px solid #e5e7eb;
    border-radius: 12px;
    padding: 40px;
    margin-bottom: 30px;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
}

.pas-panel h2 {
    color: #616c9b;
    font-size: 1.6em;
    font-weight: 700;
    margin-bottom: 10px;
    border-bottom: 2px solid #616c9b;
    padding-bottom: 15px;
}

.pas-subtitle {
    color: #6b7280;
    font-size: 0.95em;
    margin-bottom: 25px;
}

.pas-panel h3 {
    color: #616c9b;
    font-size: 1.3em;
    font-weight: 700;
    margin-bottom: 20px;
    border-bottom: 1px solid #e5e7eb;
    padding-bottom: 10px;
}

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

.pas-label {
    display: block;
    font-weight: 600;
    margin-bottom: 10px;
    color: white;
    background: #616c9b;
    padding: 12px 20px;
    border-radius: 8px;
    width: fit-content;
    font-size: 0.95em;
}

.pas-textarea {
    width: 100%;
    padding: 14px 18px;
    background: #f9fafb;
    border: 2px solid #e5e7eb;
    border-radius: 8px;
    color: #1f2937;
    font-family: inherit;
    font-size: 0.95em;
    line-height: 1.6;
    margin-top: 10px;
    resize: vertical;
    transition: all 0.3s ease;
    box-sizing: border-box;
}

.pas-textarea:focus {
    outline: none;
    border-color: #616c9b;
    box-shadow: 0 0 15px rgba(97, 108, 155, 0.2);
    background: white;
}

.pas-textarea::placeholder {
    color: #9ca3af;
}

/* Botones */
.pas-btn {
    padding: 14px 32px;
    border: 2px solid #616c9b;
    background: #616c9b;
    color: white;
    border-radius: 8px;
    font-weight: 700;
    font-size: 0.95em;
    cursor: pointer;
    transition: all 0.3s ease;
    display: inline-block;
}

.pas-btn:hover {
    background: #4a5578;
    transform: translateY(-2px);
    box-shadow: 0 8px 20px rgba(97, 108, 155, 0.3);
}

.pas-btn:active {
    transform: translateY(0);
}

.pas-btn-large {
    width: 100%;
    padding: 18px;
    font-size: 1.05em;
}

/* Estados */
.pas-loading {
    background: rgba(59, 130, 246, 0.1);
    border: 1px solid #3b82f6;
    border-left: 4px solid #3b82f6;
    color: #1e40af;
    padding: 20px;
    border-radius: 8px;
    margin-bottom: 25px;
    display: flex;
    align-items: center;
    gap: 10px;
    font-weight: 500;
}

.pas-spinner {
    width: 20px;
    height: 20px;
    border: 3px solid rgba(97, 108, 155, 0.2);
    border-top-color: #616c9b;
    border-radius: 50%;
    animation: pas-spin 0.6s linear infinite;
}

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

.pas-error {
    background: rgba(239, 68, 68, 0.1);
    border: 1px solid #ef4444;
    border-left: 4px solid #ef4444;
    color: #991b1b;
    padding: 18px;
    border-radius: 8px;
    margin-bottom: 25px;
    font-weight: 500;
}

/* Resultados */
.pas-results-panel {
    background: white;
}

.pas-query-title {
    color: #6b7280;
    font-size: 0.95em;
    margin-bottom: 20px;
    padding: 15px;
    background: #f9fafb;
    border-radius: 8px;
    border-left: 4px solid #616c9b;
}

.pas-informe-section {
    background: #f9fafb;
    padding: 25px;
    border-radius: 10px;
    margin-bottom: 30px;
    border-left: 4px solid #616c9b;
    font-family: 'Courier New', monospace;
    font-size: 0.9em;
    line-height: 1.8;
    color: #1f2937;
    white-space: pre-wrap;
    word-wrap: break-word;
    max-height: 600px;
    overflow-y: auto;
}

/* Grupo de botones */
.pas-button-group {
    display: flex;
    gap: 12px;
    flex-wrap: wrap;
    justify-content: center;
    margin-top: 30px;
}

.pas-button-group .pas-btn {
    flex: 1;
    min-width: 150px;
}

/* Responsive */
@media (max-width: 768px) {
    .pas-container {
        margin: 20px auto;
        padding: 0 10px;
    }
    
    .pas-panel {
        padding: 20px;
    }
    
    .pas-panel h2 {
        font-size: 1.3em;
    }
    
    .pas-label {
        font-size: 0.9em;
        padding: 10px 15px;
    }
    
    .pas-textarea {
        font-size: 16px; /* Previene zoom en iOS */
    }
    
    .pas-btn {
        padding: 12px 24px;
        font-size: 0.9em;
    }
    
    .pas-btn-large {
        padding: 16px;
    }
    
    .pas-button-group {
        flex-direction: column;
    }
    
    .pas-button-group .pas-btn {
        width: 100%;
    }
    
    .pas-informe-section {
        font-size: 0.85em;
        padding: 15px;
        max-height: 400px;
    }
}

/* Dark mode support */
@media (prefers-color-scheme: dark) {
    .pas-panel {
        background: #1f2937;
        border-color: #374151;
    }
    
    .pas-panel h2,
    .pas-panel h3 {
        color: #93c5fd;
    }
    
    .pas-textarea {
        background: #111827;
        border-color: #374151;
        color: #f3f4f6;
    }
    
    .pas-textarea:focus {
        border-color: #93c5fd;
        background: #1f2937;
    }
    
    .pas-informe-section {
        background: #111827;
        border-left-color: #93c5fd;
        color: #e5e7eb;
    }
    
    .pas-query-title {
        background: #111827;
        color: #d1d5db;
        border-left-color: #93c5fd;
    }
}
