/* ═══════════════════════════════════════════════════════════════════════════
   NCPM Modal - Estilo Yelp
   ═══════════════════════════════════════════════════════════════════════════ */

/* Modal base - oculto por defecto */
.ncpm-modal {
    border: none;
    padding: 0;
    margin: 0;
    position: fixed;
    inset: 0;
    width: 100%;
    height: 100%;
    max-width: 100vw;
    max-height: 100vh;
    background: rgba(0, 0, 0, 0.6);
    z-index: 99999;
}

/* Backdrop nativo transparente (usamos nuestro propio fondo) */
.ncpm-modal::backdrop {
    background: transparent;
}

/* Wrapper centrado */
.ncpm-modal-wrap {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    height: 100%;
    padding: 16px;
    box-sizing: border-box;
}

/* Caja del formulario del modal */
.ncpm-wizard-form {
    display: flex;
    flex-direction: column;
    background: #fff;
    border-radius: 4px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
    position: relative;
    width: 100%;
    max-width: 480px;
    max-height: 480px;
    height: 500px;
    overflow: hidden;
    animation: ncpm-modal-in 0.25s ease-out;
}

@keyframes ncpm-modal-in {
    from {
        opacity: 0;
        transform: scale(0.95) translateY(10px);
    }
    to {
        opacity: 1;
        transform: scale(1) translateY(0);
    }
}

/* Título */
.ncpm-dialog-box .ncpm-h {
    font-size: 1.5rem;
    margin: 0 0 20px;
    font-weight: 700;
    color: var(--ncpro-primary);
    padding-right: 40px;
}

/* Campos */
.ncpm-field {
    margin-bottom: 16px;
}

.ncpm-field label {
    display: block;
    font-size: 14px;
    font-weight: 600;
    margin-bottom: 6px;
    color: #333;
}

.ncpm-field input,
.ncpm-field textarea {
    width: 100%;
    border-radius: 4px;
    border: 1px solid #ccc;
    padding: 10px 12px;
    font-size: 15px;
    font-family: inherit;
    box-sizing: border-box;
    transition: border-color 0.15s ease;
}

.ncpm-field input:focus,
.ncpm-field textarea:focus {
    border-color: var(--ncpro-primary);
    outline: none;
    box-shadow: 0 0 0 2px rgba(211, 35, 35, 0.15);
}

.ncpm-field textarea {
    min-height: 100px;
    resize: vertical;
}

/* Row para campos en línea */
.ncpm-row {
    display: flex;
    gap: 12px;
}

.ncpm-row .ncpm-field {
    flex: 1;
}

/* Botones de acción */
.ncpm-actions {
    display: flex;
    gap: 12px;
    margin-top: 24px;
    justify-content: flex-end;
}

.ncpm-secondary,
.ncpm-primary {
    border-radius: 4px;
    padding: 10px 20px;
    font-size: 15px;
    font-weight: 600;
    cursor: pointer;
    border: none;
    font-family: inherit;
    transition: background 0.15s ease;
}

.ncpm-secondary {
    background: #f5f5f5;
    color: #333;
    border: 1px solid #ccc;
}

.ncpm-secondary:hover {
    background: #e8e8e8;
}

.ncpm-primary {
    background: var(--ncpro-primary);
    color: #fff;
}

.ncpm-primary:hover {
    background: #b81c1c;
}

/* Botón "Enviar mensaje" en la página */
.ncpm-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    background: #fff;
    color: rgba(45,46,47,1);
    border: none;
    border-radius: 4px;
    padding: 12px 18px;
    font-size: 15px;
    font-weight: 600;
    cursor: pointer;
    font-family: inherit;
    transition: background 0.15s ease;
    margin: 0 1rem 1rem;
    width: calc(100% - 2rem);
    border: 1px solid rgba(200,201,202,1);
}

.ncpm-btn:hover {
       background-color: rgba(107, 109, 111, 0.12);
    color: rgba(45, 46, 47, 1);
    box-shadow: none;
}

.ncpm-icon {
    display: inline-flex;
    width: 22px;
    height: 22px;
}

.ncpm-icon svg {
    width: 100%;
    height: 100%;
}

/* Botón cerrar (X) */
.ncpm-close {
    position: absolute;
    top: 12px;
    right: 12px;
    width: 32px;
    height: 32px;
    border-radius: 50%;
    border: none;
    background: #f5f5f5;
    color: #666;
    font-size: 20px;
    line-height: 32px;
    text-align: center;
    cursor: pointer;
    transition: background 0.15s ease, color 0.15s ease;
    padding: 0;
}

.ncpm-close:hover {
    background: #e0e0e0;
    color: #333;
}

/* Mensajes de estado */
.ncpm-ok,
.ncpm-note,
.ncpm-error {
    font-size: 14px;
    margin: 0;
    min-height: 0;
}

.ncpm-ok:empty,
.ncpm-note:empty,
.ncpm-error:empty {
    display: none;
}

.ncpm-ok {
    color: #0a8a0a;
    background: #e8f5e8;
    padding: 10px 12px;
    border-radius: 4px;
    margin-bottom: 12px;
}

.ncpm-error {
    color: #c53030;
    background: #fee;
    padding: 10px 12px;
    border-radius: 4px;
    margin-bottom: 12px;
}

.ncpm-note {
    color: #666;
    font-size: 13px;
}

/* Responsive */
@media (max-width: 540px) {
    .ncpm-dialog-box {
        padding: 20px 16px;
    }
    
    .ncpm-row {
        flex-direction: column;
        gap: 0;
    }
    
    .ncpm-actions {
        flex-direction: column;
    }
    
    .ncpm-secondary,
    .ncpm-primary {
        width: 100%;
    }
}

/* Modal wizard responsive - Estilo bottom sheet igual que nc-review-modal */
@media (max-width: 600px) {
    .ncpm-wizard-wrap {
        padding: 0;
        align-items: flex-end;
    }

    .ncpm-wizard-form {
        width: 100%;
        max-width: 100%;
        max-height: 95vh;
        height: auto;
        border-radius: 6px 6px 0 0;
        animation: ncpm-modal-in-mobile 0.3s ease-out;
    }

    @keyframes ncpm-modal-in-mobile {
        from {
            transform: translateY(100%);
        }
        to {
            transform: translateY(0);
        }
    }

    .ncpm-wizard-body {
        padding: 20px 24px;
        max-height: calc(95vh - 140px);
        overflow-y: auto;
    }

    .ncpm-wizard-actions {
        padding: 16px 24px;
        border-top: 1px solid #e5e7eb;
    }

    .ncpm-wizard-header {
        padding: 14px 20px;
    }

    .ncpm-wizard-title {
        font-size: 20px;
    }
}

/* ═══════════════════════════════════════════════════════════════════════════
   Contact Card (Sidebar)
   ═══════════════════════════════════════════════════════════════════════════ */

.ncpm-contact-card {
    padding: 1rem;
    margin-top: 26px;
    text-align: left;
        border: 1px solid #e2e3e5;
    border-radius: 6px;
    background: #fff;
    font-family: inherit;
    overflow: hidden;
    box-shadow: 0 1px 2px rgba(0, 0, 0, .05);
}

.ncpm-contact-card-header {
    margin-bottom: 12px;
}

.ncpm-contact-card-title {
    font-size: 17px;
    font-weight: 700;
    color: rgb(45, 46, 47);
    margin: 0 0 6px;
}

.ncpm-contact-card-subtitle {
    font-size: 14px;
    color: #6b7280;
    margin: 0 0 16px;
    line-height: 1.4;
}

.ncpm-contact-card svg {
    stroke: rgba(45, 46, 47, 1);
    height: 22px !important;
    width: 22px !important;
    stroke-width: 1.25 !important;
}
.ncpm-contact-card-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    width: 100%;
    padding: 12px 20px;
    border: none;
    border-radius: 4px;
    font-size: 15px;
    font-weight: 600;
    cursor: pointer;
    transition: background 0.15s ease;
    background-color: rgba(0, 0, 0, 0);
    border: 1px solid rgba(200, 201, 202, 1);
    color: rgba(45, 46, 47, 1);
}

.ncpm-contact-card-btn:hover {
    background: rgba(107,109,111,.12);
}

/* ═══════════════════════════════════════════════════════════════════════════
   Wizard Modal
   ═══════════════════════════════════════════════════════════════════════════ */

/* ═══════════════════════════════════════════════════════════════════════════
   Wizard Modal
   ═══════════════════════════════════════════════════════════════════════════ */

.ncpm-wizard-modal {
    background: rgba(0, 0, 0, 0.82);
}

.ncpm-wizard-wrap {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    height: 100%;
    padding: 16px;
    box-sizing: border-box;
    margin-bottom: 0 !important;
}

.ncpm-wizard-body {
    flex: 1;
    overflow-y: auto;
    padding: 24px 32px;
    display: flex;
    flex-direction: column;
    gap: 18px;
    background: #fff;
}

.ncpm-wizard-actions {
    display: flex;
    gap: 12px;
    justify-content: flex-end;
    padding: 16px 32px;
    background: #fff;
    border-top: 1px solid #f3f4f6;
    flex-shrink: 0;
    margin-bottom: 0 !important;
}

/* Header del wizard */
.ncpm-wizard-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 16px 20px;
    background: rgb(240, 240, 240);
    color: rgb(45, 46, 47);
    margin-bottom: 0 !important;
}

.ncpm-wizard-business {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 0 !important;
}

.ncpm-wizard-photo {
    width: 36px;
    height: 36px;
    border-radius: 6px;
    object-fit: cover;
    display: none;
    background: #374151;
}

.ncpm-wizard-photo-placeholder {
    display: flex;
    align-items: center;
    justify-content: center;
    color: #9ca3af;
}

.ncpm-wizard-business-name {
    font-size: 16px;
    font-weight: 600;
    font-family: 'Poppins', sans-serif;
}

.ncpm-wizard-close {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    border: none;
    background: transparent;
    color: rgb(45, 46, 47);
    font-size: 24px;
    line-height: 32px;
    text-align: center;
    cursor: pointer;
    transition: background 0.15s ease;
    padding: 0;
}

.ncpm-wizard-close:hover {
    background: rgba(255, 255, 255, 0.1);
}

/* Barra de progreso */
.ncpm-wizard-progress {
    height: 4px;
    background: #e5e7eb;
    margin-bottom: 0 !important;
}

.ncpm-wizard-progress-bar {
    height: 100%;
    background: rgb(0, 118, 146);
    transition: width 0.25s ease;
}

/* Pasos del wizard */
.ncpm-wizard-step {
    padding: 0;
    margin-bottom: 0 !important;
}

.ncpm-wizard-title {
    font-size: 22px;
    font-weight: 700;
    color: #111827;
    margin: 0 0 8px;
}

.ncpm-wizard-desc {
    font-size: 15px;
    color: #6b7280;
    margin: 0 0 24px;
    line-height: 1.5;
}

.ncpm-wizard-step .ncpm-field {
    margin-bottom: 0;
}

.ncpm-wizard-step .ncpm-field input,
.ncpm-wizard-step .ncpm-field textarea {
    width: 100%;
    border-radius: 8px;
    border: 2px solid #e5e7eb;
    padding: 14px 16px;
    font-size: 16px;
    font-family: inherit;
    box-sizing: border-box;
    transition: border-color 0.15s ease;
}

.ncpm-wizard-step .ncpm-field input:focus,
.ncpm-wizard-step .ncpm-field textarea:focus {
    border-color: var(--ncpro-primary);
    outline: none;
}

.ncpm-wizard-step .ncpm-field textarea {
    min-height: 140px;
    resize: vertical;
}

/* Card de confirmación */
.ncpm-wizard-confirm-card {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 16px;
    background: #f9fafb;
    border: 1px solid #e5e7eb;
    border-radius: 8px;
    margin-bottom: 16px;
    margin-top: 1rem !important;
    margin-bottom: 1.25rem !important;
}

.ncpm-wizard-confirm-photo {
    width: 40px;
    height: 40px;
    border-radius: 8px;
    object-fit: cover;
    background: #e5e7eb;
}

.ncpm-wizard-confirm-name {
    flex: 1;
    font-size: 15px;
    font-weight: 600;
    color: #111827;
}

.ncpm-wizard-confirm-check {
    flex-shrink: 0;
}

.ncpm-wizard-confirm-text {
    font-size: 14px;
    color: #6b7280;
    margin: 0;
    line-height: 1.5;
}

.ncpm-wizard-confirm-list {
    margin-top: 12px;
    padding-top: 12px;
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.ncpm-wizard-confirm-item {
    display: flex;
    align-items: flex-start;
    gap: 8px;
    margin-bottom: 10px !important;
}

.ncpm-wizard-confirm-label {
    min-width: 90px;
    font-size: 14px;
    color: #6b7280;
    font-weight: 700;
}

.ncpm-wizard-confirm-value {
    font-size: 14px;
    color: #6b7280;
    line-height: 1.4;
    word-break: break-word;
}

/* Botones del wizard */
.ncpm-wizard-actions {
    display: flex;
    gap: 12px;
    padding: 0 28px 28px;
    justify-content: flex-end;
}

.ncpm-wizard-actions .ncpm-secondary {
    flex: 0 0 auto;
}


/* Responsive wizard */
@media (max-width: 540px) {
    .ncpm-wizard-step {
        padding: 24px 20px 20px;
    }
    
    .ncpm-wizard-actions {
        padding: 0 20px 20px;
        flex-direction: column;
    }
    
    .ncpm-wizard-actions .ncpm-primary {
        max-width: none;
        order: -1;
    }
}
