/**
 * zeropayspos Front-End CloverZERO Application Form Stylesheet · V1.5.0
 * Estética de lujo en cristal oscuro (#080a0a), líneas finas, acento #00f0b5,
 * tipografía serif en títulos, inputs subrayados minimalistas y 100% responsive.
 */

:root {
    --zp-bg-main: #080a0a;
    --zp-bg-card: rgba(14, 18, 22, 0.96);
    --zp-accent: #00f0b5;
    --zp-accent-hover: #00d6a0;
    --zp-accent-glow: rgba(0, 240, 181, 0.25);
    --zp-text-main: #f5f5f5;
    --zp-text-sub: #94a3b8;
    --zp-text-muted: #64748b;
    --zp-border-subtle: rgba(255, 255, 255, 0.12);
    --zp-border-focus: #00f0b5;
    --zp-danger: #ef4444;
}

/* CONTENEDOR PRINCIPAL */
.zp-apply-wrapper {
    max-width: 860px;
    margin: 40px auto;
    padding: 44px 36px;
    background: var(--zp-bg-card);
    border: 1px solid var(--zp-border-subtle);
    border-radius: 20px;
    box-shadow: 0 24px 60px rgba(0, 0, 0, 0.6), 0 0 1px 1px rgba(255, 255, 255, 0.05);
    color: var(--zp-text-main);
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
    box-sizing: border-box;
    position: relative;
    backdrop-filter: blur(16px);
}

.zp-apply-wrapper *, .zp-apply-wrapper *::before, .zp-apply-wrapper *::after {
    box-sizing: border-box;
}

/* ENCABEZADO */
.zp-apply-header {
    text-align: center;
    margin-bottom: 32px;
}

.zp-apply-main-title {
    font-family: "Playfair Display", "Georgia", "Times New Roman", serif;
    font-size: 34px;
    font-weight: 700;
    color: #ffffff;
    margin: 0 0 8px 0;
    letter-spacing: -0.5px;
}

.zp-apply-main-subtitle {
    font-size: 14px;
    color: var(--zp-text-sub);
    margin: 0;
    font-weight: 400;
    letter-spacing: 0.2px;
}

/* STEPPER Y PROGRESS TRACK */
.zp-apply-stepper-box {
    margin-bottom: 36px;
}

.zp-apply-stepper-meta {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 10px;
    font-size: 12px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.08em;
}

.zp-step-indicator {
    color: var(--zp-accent);
}

.zp-percent-indicator {
    color: var(--zp-text-sub);
}

.zp-apply-progress-track {
    width: 100%;
    height: 3px;
    background: rgba(255, 255, 255, 0.08);
    border-radius: 999px;
    overflow: hidden;
    margin-bottom: 22px;
}

.zp-apply-progress-fill {
    height: 100%;
    background: linear-gradient(90deg, #00d6a0, #00f0b5);
    box-shadow: 0 0 12px var(--zp-accent-glow);
    transition: width 250ms ease-in-out;
}

/* TABS NAVEGACIÓN */
.zp-apply-tabs {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 8px;
    border-bottom: 1px solid var(--zp-border-subtle);
    padding-bottom: 14px;
}

.zp-tab-btn {
    background: transparent;
    border: none;
    color: var(--zp-text-muted);
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    padding: 8px 4px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    transition: all 180ms ease;
    border-radius: 6px;
}

.zp-tab-num {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 18px;
    height: 18px;
    border-radius: 50%;
    font-size: 10px;
    background: rgba(255, 255, 255, 0.08);
    color: inherit;
}

.zp-tab-btn.active {
    color: var(--zp-accent);
}

.zp-tab-btn.active .zp-tab-num {
    background: var(--zp-accent);
    color: #080a0a;
    font-weight: 800;
}

.zp-tab-btn.completed {
    color: var(--zp-text-main);
}

.zp-tab-btn.completed .zp-tab-num {
    background: rgba(0, 240, 181, 0.2);
    color: var(--zp-accent);
}

.zp-tab-btn.future {
    opacity: 0.45;
    cursor: not-allowed;
}

/* PANELES DEL WIZARD */
.zp-step-pane {
    display: none;
    opacity: 0;
    transition: opacity 200ms ease;
}

.zp-step-pane.active {
    display: block;
    opacity: 1;
}

.zp-pane-header {
    margin-bottom: 26px;
}

.zp-pane-title {
    font-family: "Playfair Display", "Georgia", serif;
    font-size: 24px;
    color: #ffffff;
    margin: 0 0 6px 0;
    font-weight: 700;
}

.zp-pane-subtitle {
    font-size: 13.5px;
    color: var(--zp-text-sub);
    margin: 0;
}

/* GRID DE CAMPOS */
.zp-fields-grid {
    display: grid;
    grid-template-columns: repeat(12, 1fr);
    gap: 24px 20px;
}

.zp-form-field-wrap {
    display: flex;
    flex-direction: column;
    position: relative;
    transition: all 200ms ease;
}

.zp-field-label {
    font-size: 11.5px !important;
    font-weight: 700 !important;
    color: #ffffff !important;
    text-transform: uppercase !important;
    letter-spacing: 0.08em !important;
    margin-bottom: 8px !important;
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.4) !important;
}

/* INPUTS MINIMALISTAS CON LÍNEA INFERIOR */
.zp-apply-wrapper .zp-field-input,
.zp-apply-wrapper .zp-field-select,
.zp-apply-wrapper .zp-field-textarea,
#inner-wrap .zp-apply-wrapper input[type="text"],
#inner-wrap .zp-apply-wrapper input[type="email"],
#inner-wrap .zp-apply-wrapper input[type="tel"],
#inner-wrap .zp-apply-wrapper textarea,
#inner-wrap .zp-apply-wrapper select,
.zp-field-input,
.zp-field-select,
.zp-field-textarea {
    width: 100% !important;
    background: rgba(255, 255, 255, 0.05) !important;
    border: none !important;
    border-bottom: 1.5px solid rgba(255, 255, 255, 0.28) !important;
    border-radius: 4px 4px 0 0 !important;
    padding: 12px 8px !important;
    color: #ffffff !important;
    -webkit-text-fill-color: #ffffff !important;
    font-size: 14.5px !important;
    font-family: inherit !important;
    outline: none !important;
    transition: border-color 200ms ease, background-color 200ms ease, box-shadow 200ms ease !important;
    box-sizing: border-box !important;
}

/* OVERRIDE AUTOFILL PARA CHROME / SAFARI / EDGE (Evita fondo blanco y texto gris oscuro) */
.zp-apply-wrapper input:-webkit-autofill,
.zp-apply-wrapper input:-webkit-autofill:hover,
.zp-apply-wrapper input:-webkit-autofill:focus,
.zp-apply-wrapper textarea:-webkit-autofill,
.zp-apply-wrapper select:-webkit-autofill {
    -webkit-text-fill-color: #ffffff !important;
    -webkit-box-shadow: 0 0 0px 1000px #0b0f15 inset !important;
    transition: background-color 5000s ease-in-out 0s !important;
    color: #ffffff !important;
}

.zp-field-input:not(:placeholder-shown),
.zp-field-textarea:not(:placeholder-shown) {
    color: #ffffff !important;
    -webkit-text-fill-color: #ffffff !important;
}

.zp-field-input::placeholder,
.zp-field-textarea::placeholder {
    color: rgba(255, 255, 255, 0.4);
    font-size: 13.5px;
}

.zp-field-input:focus,
.zp-field-select:focus,
.zp-field-textarea:focus {
    border-bottom-color: var(--zp-border-focus);
    background: rgba(0, 240, 181, 0.05);
    box-shadow: 0 2px 8px var(--zp-accent-glow);
}

.zp-field-input.zp-input-error,
.zp-field-select.zp-input-error {
    border-bottom-color: var(--zp-danger) !important;
}

.zp-field-select {
    cursor: pointer !important;
    appearance: none !important;
    -webkit-appearance: none !important;
    background-color: #0c1017 !important;
    color: #ffffff !important;
    font-weight: 600 !important;
    background-image: url("data:image/svg+xml;charset=US-ASCII,%3Csvg%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%20width%3D%22292.4%22%20height%3D%22292.4%22%3E%3Cpath%20fill%3D%22%2300f0b5%22%20d%3D%22M287%2069.4a17.6%2017.6%200%200%200-13-5.4H18.4c-5%200-9.3%201.8-12.9%205.4A17.6%2017.6%200%200%200%200%2082.2c0%205%201.8%209.3%205.4%2012.9l128%20127.9c3.6%203.6%207.8%205.4%2012.8%205.4s9.2-1.8%2012.8-5.4L287%2095c3.5-3.5%205.4-7.8%205.4-12.8%200-5-1.9-9.2-5.4-12.8z%22%2F%3E%3C%2Fsvg%3E") !important;
    background-repeat: no-repeat !important;
    background-position: right 10px center !important;
    background-size: 11px !important;
    padding-right: 32px !important;
}

.zp-field-select option {
    background-color: #0b0f15 !important;
    color: #ffffff !important;
    font-size: 14.5px !important;
    padding: 12px 14px !important;
    font-weight: 500 !important;
}

.zp-field-select option[value=""] {
    color: #94a3b8 !important;
    background-color: #0b0f15 !important;
}

.zp-field-select option:checked,
.zp-field-select option:hover {
    background-color: #121c27 !important;
    color: #00f0b5 !important;
    font-weight: 700 !important;
}

.zp-field-help {
    font-size: 11.5px;
    color: var(--zp-text-muted);
    margin: 5px 0 0 0;
}

.zp-field-error {
    font-size: 11px;
    color: var(--zp-danger);
    margin-top: 4px;
    font-weight: 600;
    min-height: 16px;
    display: block;
}

/* PASO 4: REVISIÓN AGRUPADA */
.zp-review-blocks {
    display: flex;
    flex-direction: column;
    gap: 18px;
    margin-bottom: 28px;
}

.zp-review-card {
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid var(--zp-border-subtle);
    border-radius: 12px;
    padding: 20px 24px;
}

.zp-review-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-bottom: 1px solid rgba(255, 255, 255, 0.06);
    padding-bottom: 12px;
    margin-bottom: 14px;
}

.zp-review-title {
    font-size: 12px;
    font-weight: 800;
    color: var(--zp-accent);
    text-transform: uppercase;
    letter-spacing: 0.08em;
    margin: 0;
}

.zp-btn-edit-step {
    background: transparent;
    border: 1px solid rgba(255, 255, 255, 0.15);
    color: var(--zp-text-sub);
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    padding: 4px 12px;
    border-radius: 999px;
    cursor: pointer;
    transition: all 150ms ease;
}

.zp-btn-edit-step:hover {
    color: var(--zp-accent);
    border-color: var(--zp-accent);
    background: rgba(0, 240, 181, 0.05);
}

.zp-review-body {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 12px 20px;
}

.zp-review-row {
    font-size: 13.5px;
    color: var(--zp-text-main);
}

.zp-r-label {
    color: #cbd5e1 !important;
    font-size: 12px;
    font-weight: 600;
    display: block;
    margin-bottom: 2px;
}

.zp-r-val {
    font-weight: 700;
    color: #ffffff !important;
}

/* CHECKBOXES Y CONSENTIMIENTOS */
.zp-consents-box {
    background: rgba(0, 240, 181, 0.02);
    border: 1px solid rgba(0, 240, 181, 0.15);
    border-radius: 12px;
    padding: 18px 22px;
    margin-bottom: 28px;
}

.zp-checkbox-container {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    cursor: pointer;
    font-size: 13px;
    color: #cbd5e1;
    line-height: 1.5;
}

.zp-checkbox-container input[type="checkbox"] {
    position: absolute;
    opacity: 0;
    width: 0;
    height: 0;
}

.zp-checkbox-custom {
    flex-shrink: 0;
    width: 18px;
    height: 18px;
    border: 1.5px solid var(--zp-border-subtle);
    border-radius: 4px;
    background: rgba(255, 255, 255, 0.04);
    margin-top: 1px;
    position: relative;
    transition: all 150ms ease;
}

.zp-checkbox-container input:checked ~ .zp-checkbox-custom {
    background: var(--zp-accent);
    border-color: var(--zp-accent);
}

.zp-checkbox-container input:checked ~ .zp-checkbox-custom::after {
    content: "";
    position: absolute;
    left: 5px;
    top: 2px;
    width: 4px;
    height: 8px;
    border: solid #080a0a;
    border-width: 0 2px 2px 0;
    transform: rotate(45deg);
}

.zp-checkbox-label-text a {
    color: var(--zp-accent);
    text-decoration: underline;
}

/* RETO / PREGUNTA DE SEGURIDAD */
.zp-challenge-box {
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid var(--zp-border-subtle);
    border-radius: 12px;
    padding: 18px 22px;
    margin-bottom: 24px;
}

/* BOTONES DE NAVEGACIÓN Y ACCIÓN */
.zp-pane-actions {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: 36px;
    padding-top: 20px;
    border-top: 1px solid var(--zp-border-subtle);
}

.zp-btn-wizard {
    padding: 14px 32px;
    border-radius: 999px;
    font-size: 13px;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    cursor: pointer;
    transition: all 180ms ease;
    border: none;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    text-decoration: none;
}

.zp-btn-next, .zp-btn-submit {
    background: var(--zp-accent);
    color: #080a0a !important;
    box-shadow: 0 6px 20px var(--zp-accent-glow);
}

.zp-btn-next:hover, .zp-btn-submit:hover {
    background: var(--zp-accent-hover);
    transform: translateY(-1px);
    box-shadow: 0 8px 24px rgba(0, 240, 181, 0.4);
}

.zp-btn-prev {
    background: transparent;
    color: var(--zp-text-sub);
    border: 1px solid var(--zp-border-subtle);
}

.zp-btn-prev:hover {
    color: #ffffff;
    border-color: rgba(255, 255, 255, 0.3);
    background: rgba(255, 255, 255, 0.03);
}

.zp-btn-wizard:disabled {
    opacity: 0.5;
    cursor: not-allowed;
    transform: none !important;
}

/* ALERTA DE ERROR DE ENVÍO */
.zp-form-alert {
    background: rgba(239, 68, 68, 0.1);
    border: 1px solid rgba(239, 68, 68, 0.3);
    color: #fca5a5;
    padding: 12px 18px;
    border-radius: 8px;
    font-size: 13px;
    margin-bottom: 20px;
}

/* PANTALLA DE ÉXITO */
.zp-apply-success-section {
    padding: 40px 20px;
    text-align: center;
}

.zp-success-card {
    max-width: 580px;
    margin: 0 auto;
}

.zp-success-icon-badge {
    width: 68px;
    height: 68px;
    background: rgba(0, 240, 181, 0.15);
    border: 2px solid var(--zp-accent);
    color: var(--zp-accent);
    border-radius: 50%;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 32px;
    margin-bottom: 22px;
    box-shadow: 0 0 24px var(--zp-accent-glow);
}

.zp-success-title {
    font-family: "Playfair Display", "Georgia", serif;
    font-size: 30px;
    color: #ffffff;
    margin: 0 0 10px 0;
}

.zp-success-subtitle {
    font-size: 15px;
    color: var(--zp-text-sub);
    margin: 0 0 28px 0;
    line-height: 1.6;
}

.zp-success-folio-box {
    background: rgba(255, 255, 255, 0.03);
    border: 1px dashed var(--zp-border-focus);
    border-radius: 12px;
    padding: 18px;
    margin-bottom: 32px;
}

.zp-success-folio-label {
    font-size: 11px;
    font-weight: 700;
    color: var(--zp-text-muted);
    letter-spacing: 0.1em;
    display: block;
    margin-bottom: 6px;
}

.zp-success-folio-number {
    font-family: monospace;
    font-size: 26px;
    font-weight: 800;
    color: var(--zp-accent);
    letter-spacing: 1px;
}

.zp-success-actions {
    display: flex;
    flex-direction: column;
    gap: 12px;
    align-items: center;
}

.zp-btn-success-wa {
    background: var(--zp-accent);
    color: #080a0a !important;
    text-decoration: none;
    font-size: 14px;
    font-weight: 800;
    padding: 14px 32px;
    border-radius: 999px;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    box-shadow: 0 6px 20px var(--zp-accent-glow);
}

.zp-btn-new-app {
    background: transparent;
    border: none;
    color: var(--zp-text-sub);
    font-size: 12px;
    cursor: pointer;
    text-decoration: underline;
    margin-top: 6px;
}

/* RESPONSIVE BREAKPOINTS */
@media (max-width: 768px) {
    .zp-apply-wrapper {
        margin: 20px 12px;
        padding: 28px 18px;
        border-radius: 14px;
    }

    .zp-apply-main-title {
        font-size: 26px;
    }

    .zp-apply-tabs {
        grid-template-columns: repeat(2, 1fr);
        gap: 6px;
    }

    .zp-tab-btn {
        justify-content: flex-start;
        padding: 6px 8px;
    }

    .zp-tab-text {
        font-size: 10px;
    }

    .zp-fields-grid {
        grid-template-columns: 1fr !important;
        gap: 18px;
    }

    .zp-form-field-wrap {
        grid-column: span 12 !important;
    }

    .zp-review-body {
        grid-template-columns: 1fr;
    }

    .zp-pane-actions {
        flex-direction: column-reverse;
        gap: 12px;
    }

    .zp-action-left, .zp-action-right {
        width: 100%;
    }

    .zp-btn-wizard {
        width: 100%;
    }
}
