/* ============================================================
   Arquetipos Psicologicos (ap) - Estilos del quiz jungiano
   Namespace: .ap-app
   ============================================================ */

.ap-app {
    --ap-gradiente: linear-gradient(135deg, #8b5cf6 0%, #d946ef 100%);
    --ap-purpura: #8b5cf6;
    --ap-rosa: #d946ef;
    --ap-dorado: #f59e0b;
    --ap-sombra: 0 8px 25px rgba(139,92,246,0.25);
    --ap-radio: 16px;
    --ap-trans: all 0.3s ease;
    font-family: 'Segoe UI', system-ui, -apple-system, sans-serif;
    line-height: 1.6; color: #e2e8f0;
    max-width: 650px; margin: 0 auto;
}
.ap-fase { animation: apFadeIn 0.5s ease; }
@keyframes apFadeIn { from { opacity: 0; transform: translateY(12px); } to { opacity: 1; transform: translateY(0); } }

.ap-header { text-align: center; margin-bottom: 1.5rem; }
.ap-titulo { font-size: 1.5rem; font-weight: 700; background: var(--ap-gradiente); -webkit-background-clip: text; -webkit-text-fill-color: transparent; background-clip: text; }
.ap-subtitulo { opacity: 0.65; font-size: 0.9rem; }

.ap-intro { background: rgba(139,92,246,0.06); border: 1px solid rgba(139,92,246,0.2); border-radius: var(--ap-radio); padding: 1.3rem; margin-bottom: 1.2rem; text-align: center; }
.ap-intro p { opacity: 0.85; margin-bottom: 0.8rem; }
.ap-arquetipos-preview { display: flex; flex-wrap: wrap; gap: 0.4rem; justify-content: center; }
.ap-arquetipos-preview span { background: rgba(139,92,246,0.12); padding: 0.25rem 0.6rem; border-radius: 8px; font-size: 0.78rem; }
.ap-btn-inicio { display: block; width: 100%; background: var(--ap-gradiente); border: none; padding: 1rem; border-radius: 30px; color: white; font-weight: 700; font-size: 1.05rem; cursor: pointer; transition: var(--ap-trans); }
.ap-btn-inicio:hover { transform: translateY(-3px); box-shadow: var(--ap-sombra); }

.ap-ronda-header { margin-bottom: 0.5rem; font-weight: 500; }
.ap-progress-bar { height: 6px; background: rgba(255,255,255,0.08); border-radius: 3px; overflow: hidden; margin-bottom: 1.5rem; }
.ap-progress-fill { height: 100%; background: var(--ap-gradiente); border-radius: 3px; transition: width 0.4s ease; width: 0; }

.ap-pregunta-box { background: rgba(217,70,239,0.08); border: 1px solid rgba(217,70,239,0.2); border-radius: var(--ap-radio); padding: 1.5rem; text-align: center; margin-bottom: 1.2rem; }
.ap-pregunta-texto { font-size: 1.1rem; font-weight: 600; }

.ap-opciones-grid { display: flex; flex-direction: column; gap: 0.6rem; }
.ap-opcion-btn {
    background: rgba(255,255,255,0.04); border: 1px solid rgba(139,92,246,0.18); border-radius: 12px;
    padding: 1rem 1.2rem; cursor: pointer; color: #e2e8f0; text-align: left; transition: var(--ap-trans); font-size: 0.95rem;
}
.ap-opcion-btn:hover:not(:disabled) { border-color: var(--ap-rosa); background: rgba(217,70,239,0.06); transform: translateX(6px); }
.ap-opcion-btn:disabled { cursor: default; opacity: 0.5; }

.ap-resultado-header { text-align: center; margin-bottom: 1.5rem; }
.ap-resultado-titulo { font-size: 1.4rem; font-weight: 700; background: var(--ap-gradiente); -webkit-background-clip: text; -webkit-text-fill-color: transparent; background-clip: text; }

.ap-dom-titulo, .ap-sec-titulo, .ap-barras-titulo { font-size: 0.85rem; font-weight: 600; opacity: 0.7; margin-bottom: 0.5rem; margin-top: 1rem; }
.ap-dom-card { background: rgba(217,70,239,0.1); border: 1px solid rgba(217,70,239,0.3); border-radius: var(--ap-radio); padding: 1.5rem; text-align: center; }
.ap-dom-icon { font-size: 3rem; margin-bottom: 0.5rem; }
.ap-dom-card h3 { font-size: 1.3rem; font-weight: 700; margin-bottom: 0.5rem; }
.ap-dom-card p { opacity: 0.85; line-height: 1.6; }

.ap-sec-card { background: rgba(139,92,246,0.08); border: 1px solid rgba(139,92,246,0.2); border-radius: 12px; padding: 1rem; text-align: center; font-size: 1rem; }
.ap-sec-icon { font-size: 1.5rem; }

.ap-barra-item { display: flex; align-items: center; gap: 0.6rem; margin-bottom: 0.5rem; }
.ap-barra-nombre { width: 120px; font-size: 0.8rem; text-align: right; flex-shrink: 0; }
.ap-barra-track { flex: 1; height: 10px; background: rgba(255,255,255,0.06); border-radius: 5px; overflow: hidden; }
.ap-barra-fill { height: 100%; background: var(--ap-gradiente); border-radius: 5px; transition: width 0.6s ease; }
.ap-barra-val { width: 24px; font-size: 0.8rem; font-weight: 600; text-align: center; }

.ap-recomendacion { background: rgba(255,255,255,0.04); border: 1px solid rgba(139,92,246,0.15); border-radius: var(--ap-radio); padding: 1rem; margin: 1.2rem 0; }
.ap-recomendacion p { opacity: 0.85; line-height: 1.6; }

.ap-btn-reinicio { display: block; width: 100%; background: var(--ap-gradiente); border: none; padding: 0.9rem; border-radius: 30px; color: white; font-weight: 700; font-size: 1rem; cursor: pointer; transition: var(--ap-trans); }
.ap-btn-reinicio:hover { transform: translateY(-3px); }

@media (max-width: 480px) { .ap-barra-nombre { width: 80px; font-size: 0.7rem; } }
@media (prefers-contrast: high) { .ap-opcion-btn { border: 2px solid white; } }
@media (prefers-reduced-motion: reduce) { .ap-fase { animation: none; } }
