/* ═══════════════════════════════════════════════════════════════
   GRIZALUM - ONBOARDING INTELIGENTE
   Estilos para el asistente de configuración inicial
   ═══════════════════════════════════════════════════════════════ */

/* Variables base (modo oscuro) */
:root {
    --wizard-texto-principal: #ffffff;
    --wizard-texto-secundario: rgba(255, 255, 255, 0.8);
    --wizard-texto-terciario: rgba(255, 255, 255, 0.6);
    --wizard-fondo-principal: linear-gradient(135deg, #1a1a2e 0%, #16213e 100%);
    --wizard-fondo-card: rgba(255, 255, 255, 0.05);
    --wizard-fondo-card-hover: rgba(255, 255, 255, 0.08);
    --wizard-fondo-card-seleccionado: rgba(220, 38, 38, 0.2);
    --wizard-borde: rgba(255, 255, 255, 0.1);
    --wizard-borde-seleccionado: #dc2626;
}

/* Modo claro */
body.modo-claro {
    --wizard-texto-principal: #1e293b;
    --wizard-texto-secundario: rgba(30, 41, 59, 0.8);
    --wizard-texto-terciario: rgba(30, 41, 59, 0.6);
    --wizard-fondo-principal: linear-gradient(135deg, #f8fafc 0%, #e2e8f0 100%);
    --wizard-fondo-card: rgba(0, 0, 0, 0.03);
    --wizard-fondo-card-hover: rgba(0, 0, 0, 0.05);
    --wizard-fondo-card-seleccionado: rgba(220, 38, 38, 0.1);
    --wizard-borde: rgba(0, 0, 0, 0.1);
    --wizard-borde-seleccionado: #dc2626;
}

/* Modo neutro */
body.modo-neutro {
    --wizard-texto-principal: #e5e7eb;
    --wizard-texto-secundario: rgba(229, 231, 235, 0.8);
    --wizard-texto-terciario: rgba(229, 231, 235, 0.6);
    --wizard-fondo-principal: linear-gradient(135deg, #374151 0%, #1f2937 100%);
    --wizard-fondo-card: rgba(255, 255, 255, 0.05);
    --wizard-fondo-card-hover: rgba(255, 255, 255, 0.08);
    --wizard-fondo-card-seleccionado: rgba(220, 38, 38, 0.2);
    --wizard-borde: rgba(255, 255, 255, 0.15);
    --wizard-borde-seleccionado: #dc2626;
}

/* Modal principal */
.onboarding-wizard {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.9);
    backdrop-filter: blur(10px);
    z-index: 100000;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
    opacity: 0;
    visibility: hidden;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

.onboarding-wizard.show {
    opacity: 1;
    visibility: visible;
}

.wizard-contenido {
    background: var(--wizard-fondo-principal);
    border-radius: 24px;
    width: 1100px;
    max-width: 95vw;
    max-height: 90vh;
    overflow: hidden;
    box-shadow: 0 40px 100px rgba(0, 0, 0, 0.8);
    transform: scale(0.9) translateY(30px);
    transition: transform 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    border: 1px solid var(--wizard-borde);
    display: flex;
    flex-direction: column;
}

.onboarding-wizard.show .wizard-contenido {
    transform: scale(1) translateY(0);
}

/* Header */
.wizard-header {
    background: linear-gradient(135deg, #dc2626 0%, #b91c1c 100%);
    padding: 32px;
    display: flex;
    align-items: center;
    gap: 20px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.wizard-icono {
    width: 64px;
    height: 64px;
    background: rgba(255, 255, 255, 0.15);
    backdrop-filter: blur(10px);
    border-radius: 16px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 32px;
}

.wizard-header h2 {
    margin: 0;
    font-size: 32px;
    font-weight: 800;
    color: white;
}

.wizard-header p {
    margin: 4px 0 0 0;
    font-size: 16px;
    color: rgba(255, 255, 255, 0.9);
}

/* Barra de progreso */
.wizard-progress {
    padding: 24px 32px;
    background: var(--wizard-fondo-card);
    border-bottom: 1px solid var(--wizard-borde);
}

.progress-bar {
    width: 100%;
    height: 8px;
    background: var(--wizard-borde);
    border-radius: 8px;
    overflow: hidden;
    margin-bottom: 12px;
}

.progress-fill {
    height: 100%;
    background: linear-gradient(90deg, #dc2626 0%, #f87171 100%);
    border-radius: 8px;
    transition: width 0.5s ease;
    box-shadow: 0 0 10px rgba(220, 38, 38, 0.5);
}

.progress-texto {
    text-align: center;
    color: var(--wizard-texto-terciario);
    font-size: 14px;
    font-weight: 600;
}

/* Paso actual */
.wizard-paso {
    padding: 40px;
    flex: 1;
    overflow-y: auto;
}

.wizard-paso::-webkit-scrollbar {
    width: 8px;
}

.wizard-paso::-webkit-scrollbar-track {
    background: var(--wizard-fondo-card);
    border-radius: 10px;
}

.wizard-paso::-webkit-scrollbar-thumb {
    background: rgba(220, 38, 38, 0.6);
    border-radius: 10px;
}

.paso-pregunta {
    font-size: 28px;
    font-weight: 800;
    color: var(--wizard-texto-principal);
    margin: 0 0 12px 0;
    text-align: center;
}

.paso-descripcion {
    font-size: 16px;
    color: var(--wizard-texto-terciario);
    margin: 0 0 40px 0;
    text-align: center;
}

/* Grid de opciones */
.industrias-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
    gap: 16px;
}

.opciones-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
    gap: 16px;
}

/* Cards de industria */
.industria-card {
    background: var(--wizard-fondo-card);
    border: 2px solid var(--wizard-borde);
    border-radius: 16px;
    padding: 24px;
    text-align: center;
    cursor: pointer;
    transition: all 0.3s ease;
}

.industria-card:hover {
    background: var(--wizard-fondo-card-hover);
    transform: translateY(-4px);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.3);
}

.industria-card.seleccionado {
    background: var(--wizard-fondo-card-seleccionado);
    border-color: var(--wizard-borde-seleccionado);
    box-shadow: 0 0 20px rgba(220, 38, 38, 0.4);
}

.industria-icono {
    font-size: 48px;
    margin-bottom: 12px;
}

.industria-nombre {
    font-size: 16px;
    font-weight: 700;
    color: var(--wizard-texto-principal);
    margin-bottom: 4px;
}

.industria-categoria {
    font-size: 12px;
    color: var(--wizard-texto-terciario);
    text-transform: uppercase;
    letter-spacing: 1px;
}

/* Cards de opción */
.opcion-card {
    background: var(--wizard-fondo-card);
    border: 2px solid var(--wizard-borde);
    border-radius: 16px;
    padding: 28px;
    cursor: pointer;
    transition: all 0.3s ease;
    position: relative;
}

.opcion-card:hover {
    background: var(--wizard-fondo-card-hover);
    transform: translateY(-4px);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.3);
}

.opcion-card.seleccionado {
    background: var(--wizard-fondo-card-seleccionado);
    border-color: var(--wizard-borde-seleccionado);
    box-shadow: 0 0 20px rgba(220, 38, 38, 0.4);
}

.opcion-icono {
    font-size: 40px;
    margin-bottom: 16px;
}

.opcion-nombre {
    font-size: 18px;
    font-weight: 700;
    color: var(--wizard-texto-principal);
    margin-bottom: 8px;
}

.opcion-descripcion {
    font-size: 14px;
    color: var(--wizard-texto-terciario);
    line-height: 1.5;
}

.check-mark {
    position: absolute;
    top: 12px;
    right: 12px;
    width: 32px;
    height: 32px;
    background: #10b981;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 18px;
    font-weight: 700;
}

/* Footer */
.wizard-footer {
    padding: 24px 32px;
    background: var(--wizard-fondo-card);
    border-top: 1px solid var(--wizard-borde);
    display: flex;
    justify-content: space-between;
    gap: 16px;
}

.wizard-btn-anterior,
.wizard-btn-siguiente {
    padding: 16px 32px;
    border-radius: 12px;
    font-size: 16px;
    font-weight: 700;
    cursor: pointer;
    border: none;
    transition: all 0.3s ease;
}

.wizard-btn-anterior {
    background: rgba(107, 114, 128, 0.3);
    color: var(--wizard-texto-principal);
}

.wizard-btn-anterior:hover:not(:disabled) {
    background: rgba(107, 114, 128, 0.5);
    transform: translateY(-2px);
}

.wizard-btn-anterior:disabled {
    opacity: 0.3;
    cursor: not-allowed;
}

.wizard-btn-siguiente {
    background: linear-gradient(135deg, #dc2626 0%, #b91c1c 100%);
    color: white;
    box-shadow: 0 4px 15px rgba(220, 38, 38, 0.4);
    flex: 1;
    max-width: 400px;
}

.wizard-btn-siguiente:hover:not(:disabled) {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(220, 38, 38, 0.5);
}

.wizard-btn-siguiente:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

/* Resumen final */
.wizard-resumen {
    text-align: center;
    padding: 60px 40px;
}

.resumen-icono {
    font-size: 80px;
    margin-bottom: 24px;
    animation: celebrar 0.6s ease-out;
}

@keyframes celebrar {
    0%, 100% { transform: scale(1) rotate(0deg); }
    25% { transform: scale(1.2) rotate(-10deg); }
    75% { transform: scale(1.2) rotate(10deg); }
}

.wizard-resumen h2 {
    font-size: 36px;
    font-weight: 800;
    color: var(--wizard-texto-principal);
    margin: 0 0 12px 0;
}

.wizard-resumen > p {
    font-size: 18px;
    color: var(--wizard-texto-terciario);
    margin: 0 0 40px 0;
}

.resumen-modulos {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    gap: 12px;
    margin-bottom: 40px;
}

.modulo-resumen {
    background: var(--wizard-fondo-card);
    border: 1px solid var(--wizard-borde);
    border-radius: 12px;
    padding: 16px;
    display: flex;
    align-items: center;
    gap: 12px;
    font-size: 15px;
    font-weight: 600;
    color: var(--wizard-texto-principal);
}

.modulo-resumen span:first-child {
    font-size: 24px;
}

.resumen-nota {
    background: var(--wizard-fondo-card);
    border-left: 4px solid #f59e0b;
    padding: 16px 20px;
    border-radius: 8px;
    font-size: 14px;
    color: var(--wizard-texto-secundario);
    margin-bottom: 32px;
}

.wizard-btn-finalizar {
    padding: 18px 48px;
    background: linear-gradient(135deg, #10b981 0%, #059669 100%);
    color: white;
    border: none;
    border-radius: 12px;
    font-size: 18px;
    font-weight: 700;
    cursor: pointer;
    box-shadow: 0 4px 15px rgba(16, 185, 129, 0.4);
    transition: all 0.3s ease;
}

.wizard-btn-finalizar:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(16, 185, 129, 0.5);
}

/* Responsive */
@media (max-width: 768px) {
    .wizard-contenido {
        width: 100%;
    }
    
    .industrias-grid,
    .opciones-grid {
        grid-template-columns: 1fr;
    }
    
    .wizard-header {
        padding: 24px;
    }
    
    .wizard-paso {
        padding: 24px;
    }
    
    .paso-pregunta {
        font-size: 22px;
    }
}
/* Input personalizado */
.wizard-input-text {
    width: 100%;
    padding: 16px 20px;
    background: var(--wizard-fondo-card);
    border: 2px solid var(--wizard-borde);
    border-radius: 12px;
    color: var(--wizard-texto-principal);
    font-size: 16px;
    font-weight: 600;
    transition: all 0.3s ease;
}

.wizard-input-text:focus {
    outline: none;
    border-color: #dc2626;
    box-shadow: 0 0 0 4px rgba(220, 38, 38, 0.2);
    background: var(--wizard-fondo-card-hover);
}

.wizard-input-text::placeholder {
    color: var(--wizard-texto-terciario);
}

.input-personalizado {
    animation: slideDown 0.3s ease;
}

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