/* ============================================================
           GLOBAL RESET & SHARED VARIABLES
        ============================================================ */
:root {
    --fb-blue: #0866FF;
    --fb-dark: #0056D8;
    --fb-dark-blue: #1558b0;
    --fb-bg: #F0F2F5;
    --fb-card: #FFFFFF;
    --fb-text: #050505;
    --fb-sub: #65676B;
    --fb-error: #DC3545;
    --input-bg: #F5F6F7;
    --radius: 16px;
    --success-green: #31A24C;
    --green: #34C759;
    --red: #FF3B30;
    --text-main: #050505;
    --text-sub: #65676B;
    --error: #DC3545;
    --success: #36A420;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    -webkit-tap-highlight-color: transparent;
    outline: none;
}

body {
    transition: opacity ease-in 0.2s;
    overflow-x: hidden;
}

body[unresolved] {
    opacity: 0;
    display: block;
    overflow: hidden;
    position: relative;
}

body,
button,
input,
textarea,
select,
h1,
h2,
h3,
p,
span,
div,
a,
li,
ul {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif !important;
}

/* Body defaults, overridden per step */
body {
    color: var(--fb-text);
    min-height: 100vh;
    width: 100%;
}

/* ============================================================
           STEP VISIBILITY MANAGEMENT
        ============================================================ */
.quiz-step {
    display: none;
}

.quiz-step.active {
    display: block;
}

/* Body style per step */
body[data-step="1"],
body[data-step="2"] {
    background: radial-gradient(circle at 50% 0%, #E7F3FF 0%, #F0F2F5 60%);
    display: flex;
    align-items: center;
    justify-content: center;
    overflow-y: auto;
    padding: 20px 0;
}

body[data-step="3"] {
    background: radial-gradient(circle at 50% 0%, #E7F3FF 0%, #F0F2F5 60%);
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 10px;
}

body[data-step="4"] {
    background: var(--fb-bg);
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 15px;
}

/* ============================================================
           SHARED KEYFRAME ANIMATIONS
        ============================================================ */
@keyframes slideUp {
    from {
        transform: translateY(30px);
        opacity: 0;
    }

    to {
        transform: translateY(0);
        opacity: 1;
    }
}

@keyframes fadeIn {
    to {
        opacity: 1;
    }
}

@keyframes fadeInLogo {
    0% {
        opacity: 0;
    }

    100% {
        opacity: 1;
    }
}

@keyframes sheen {
    0% {
        left: -100%;
    }

    100% {
        left: 200%;
    }
}

@keyframes shake {

    10%,
    90% {
        transform: translate3d(-1px, 0, 0);
    }

    20%,
    80% {
        transform: translate3d(2px, 0, 0);
    }

    30%,
    50%,
    70% {
        transform: translate3d(-4px, 0, 0);
    }

    40%,
    60% {
        transform: translate3d(4px, 0, 0);
    }
}

@keyframes spin {
    100% {
        transform: rotate(360deg);
    }
}

@keyframes rotate {
    100% {
        transform: rotate(360deg);
    }
}

@keyframes stroke {
    100% {
        stroke-dashoffset: 0;
    }
}

@keyframes pulse {
    50% {
        opacity: 0.4;
    }
}

@keyframes drawLineLoop {
    0% {
        stroke-dashoffset: 100;
    }

    40% {
        stroke-dashoffset: 0;
    }

    70% {
        stroke-dashoffset: 0;
    }

    100% {
        stroke-dashoffset: -100;
    }
}

@keyframes pulseShield {

    0%,
    100% {
        transform: scale(1);
    }

    50% {
        transform: scale(1.15);
    }
}

@keyframes rotateCoin {
    0% {
        transform: rotateY(0deg);
    }

    100% {
        transform: rotateY(360deg);
    }
}

/* ============================================================
           STEP 1 — index1.php styles
        ============================================================ */
#step1 .wrapper {
    position: relative;
    z-index: 10;
    width: 100%;
    max-width: 420px;
    padding: 20px;
    padding-bottom: calc(20px + env(safe-area-inset-bottom));
    display: flex;
    flex-direction: column;
    align-items: center;
    margin: auto;
}

#step1 .logo-container {
    width: 120px;
    height: 120px;
    display: flex;
    justify-content: center;
    align-items: center;
    margin-bottom: 10px;
    transform: translateZ(0);
    animation: fadeInLogo 0.8s ease-out both;
}

#step1 dotlottie-wc {
    width: 110px !important;
    height: 110px !important;
}

#step1 .main-card {
    background: var(--fb-card);
    border-radius: var(--radius);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
    padding: 30px 24px;
    width: 100%;
    text-align: center;
    position: relative;
    overflow: hidden;
    opacity: 0;
    animation: slideUp 0.5s ease-out 0.2s forwards;
}

#step1 h1 {
    font-size: 21px;
    font-weight: 800;
    line-height: 1.3;
    margin-bottom: 10px;
    letter-spacing: -0.3px;
}

#step1 .subtitle {
    font-size: 15px;
    color: var(--fb-sub);
    line-height: 1.5;
    margin-bottom: 25px;
}

#step1 .feature-list {
    display: flex;
    flex-direction: column;
    gap: 12px;
    margin-bottom: 30px;
    text-align: left;
}

#step1 .feature-item {
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 12px;
    background: #F7F8FA;
    border-radius: 12px;
    border: 1px solid #E4E6EB;
    opacity: 0;
    animation: fadeIn 0.4s ease-out forwards;
}

#step1 .feature-item:nth-child(1) {
    animation-delay: 0.3s;
}

#step1 .feature-item:nth-child(2) {
    animation-delay: 0.4s;
}

#step1 .feature-item:nth-child(3) {
    animation-delay: 0.5s;
}

#step1 .icon-wrap {
    width: 40px;
    height: 40px;
    background: #EDF5FF;
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    color: var(--fb-blue);
}

#step1 .anim-chart path {
    stroke-dasharray: 100;
    stroke-dashoffset: 100;
    animation: drawLineLoop 3s ease-in-out infinite;
}

#step1 .anim-shield {
    animation: pulseShield 2s infinite ease-in-out;
    transform-origin: center;
}

#step1 .anim-coin {
    animation: rotateCoin 3s linear infinite;
    transform-origin: center;
}

#step1 .feature-text {
    font-size: 15px;
    font-weight: 600;
}

#step1 .btn-cta {
    width: 100%;
    padding: 15px;
    background: var(--fb-blue);
    color: white;
    font-size: 16px;
    font-weight: 700;
    border: none;
    border-radius: 10px;
    cursor: pointer;
    position: relative;
    overflow: hidden;
    box-shadow: 0 4px 10px rgba(8, 102, 255, 0.25);
    transition: transform 0.1s;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

#step1 .btn-cta:active {
    transform: scale(0.97);
    background: var(--fb-dark);
}

#step1 .btn-cta::after {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 50%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.3), transparent);
    transform: skewX(-20deg);
    animation: sheen 4s infinite 2s;
}

#step1 .btn-cta.is-loading {
    pointer-events: none;
    background: var(--fb-dark);
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 10px;
}

#step1 .trust-badge {
    margin-top: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    font-size: 11px;
    color: var(--fb-sub);
    opacity: 0;
    animation: fadeIn 0.5s ease 1s forwards;
}

#step1 .trust-dot {
    width: 6px;
    height: 6px;
    background: #31A24C;
    border-radius: 50%;
}

#step1 .modal-backdrop {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.6);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 999;
    opacity: 0;
    visibility: hidden;
    transition: 0.2s;
}

#step1 .modal-backdrop.active {
    opacity: 1;
    visibility: visible;
}

#step1 .app-modal {
    background: #fff;
    width: 85%;
    max-width: 300px;
    border-radius: 16px;
    padding: 30px 24px;
    text-align: center;
    transform: scale(0.9);
    transition: 0.2s cubic-bezier(0.34, 1.56, 0.64, 1);
}

#step1 .modal-backdrop.active .app-modal {
    transform: scale(1);
}

#step1 .checkmark-circle {
    stroke-dasharray: 166;
    stroke-dashoffset: 166;
    stroke-width: 2;
    stroke-miterlimit: 10;
    stroke: #31A24C;
    fill: none;
    animation: stroke 0.6s cubic-bezier(0.65, 0, 0.45, 1) forwards;
}

#step1 .checkmark-check {
    transform-origin: 50% 50%;
    stroke-dasharray: 48;
    stroke-dashoffset: 48;
    animation: stroke 0.3s cubic-bezier(0.65, 0, 0.45, 1) 0.5s forwards;
}

#step1 .modal-icon {
    width: 60px;
    height: 60px;
    margin: 0 auto 15px;
    display: block;
}

#step1 .modal-title {
    font-size: 19px;
    font-weight: 800;
    margin-bottom: 5px;
    color: #1c1e21;
}

#step1 .modal-desc {
    font-size: 14px;
    color: var(--fb-sub);
}

/* ============================================================
           STEP 2 — index2.php styles
        ============================================================ */
#step2 .wrapper {
    position: relative;
    z-index: 10;
    width: 100%;
    max-width: 420px;
    padding: 20px;
    padding-bottom: calc(20px + env(safe-area-inset-bottom));
    display: flex;
    flex-direction: column;
    align-items: center;
    margin: auto;
}

#step2 .main-card {
    background: var(--fb-card);
    border-radius: var(--radius);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.08);
    padding: 30px 24px;
    width: 100%;
    text-align: center;
    position: relative;
    overflow: hidden;
    opacity: 0;
    animation: slideUp 0.5s cubic-bezier(0.175, 0.885, 0.32, 1.275) 0.1s forwards;
    transform: translateZ(0);
}

#step2 .ai-badge {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 6px 12px;
    margin-bottom: 20px;
    background: linear-gradient(135deg, #E7F3FF 0%, #FFFFFF 100%);
    border: 1px solid rgba(8, 102, 255, 0.15);
    border-radius: 20px;
    font-size: 13px;
    font-weight: 600;
    color: var(--fb-blue);
    box-shadow: 0 2px 8px rgba(8, 102, 255, 0.1);
}

#step2 h1 {
    font-size: 21px;
    font-weight: 800;
    line-height: 1.3;
    margin-bottom: 12px;
    letter-spacing: -0.3px;
    color: #1c1e21;
}

#step2 .subtitle {
    font-size: 15px;
    color: var(--fb-sub);
    line-height: 1.5;
    margin-bottom: 25px;
}

#step2 .form-group {
    display: flex;
    flex-direction: column;
    gap: 14px;
    margin-bottom: 25px;
    width: 100%;
}

#step2 .fb-input {
    width: 100%;
    padding: 16px;
    font-size: 16px;
    color: #1c1e21;
    background: var(--input-bg);
    border: 1px solid #CCD0D5;
    border-radius: 10px;
    transition: all 0.2s ease;
}

#step2 .fb-input:focus {
    background: #fff;
    border-color: var(--fb-blue);
    box-shadow: 0 0 0 2px rgba(8, 102, 255, 0.2);
}

#step2 .fb-input.error {
    border-color: var(--fb-error);
    background: #FFF5F5;
    animation: shake 0.4s cubic-bezier(.36, .07, .19, .97) both;
}

#step2 .btn-calc {
    width: 100%;
    padding: 16px;
    background: var(--fb-blue);
    color: white;
    font-size: 16px;
    font-weight: 700;
    border: none;
    border-radius: 10px;
    cursor: pointer;
    position: relative;
    overflow: hidden;
    box-shadow: 0 4px 12px rgba(8, 102, 255, 0.25);
    transition: transform 0.1s;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

#step2 .btn-calc:active {
    transform: scale(0.97);
    background: #0056D8;
}

#step2 .btn-calc::after {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 50%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.3), transparent);
    transform: skewX(-20deg);
    animation: sheen 4s infinite 2s;
}

#step2 .btn-calc.is-loading {
    pointer-events: none;
    background: #0056D8;
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 10px;
}

#step2 .footer-trust {
    margin-top: 25px;
    padding-top: 20px;
    border-top: 1px solid #E4E6EB;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 12px;
}

#step2 .trust-text {
    font-size: 12px;
    color: #8D949E;
    font-weight: 500;
}

#step2 .logos-row {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 20px;
    opacity: 1;
}

#step2 .logos-row img {
    display: block;
    width: auto;
    object-fit: contain;
}

#step2 .iconlogos1 {
    height: 16px;
}

#step2 .iconlogos2 {
    height: 28px;
}

#step2 .iconlogos3 {
    height: 28px;
}

#step2 .iconlogos4 {
    height: 32px;
}

#step2 .modal-backdrop {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.6);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 999;
    opacity: 0;
    visibility: hidden;
    transition: 0.2s;
}

#step2 .modal-backdrop.active {
    opacity: 1;
    visibility: visible;
}

#step2 .app-modal {
    background: #fff;
    width: 85%;
    max-width: 300px;
    border-radius: 16px;
    padding: 24px;
    text-align: center;
    transform: scale(0.9);
    transition: 0.2s cubic-bezier(0.34, 1.56, 0.64, 1);
}

#step2 .modal-backdrop.active .app-modal {
    transform: scale(1);
}

#step2 .modal-spinner {
    animation: rotate 1s linear infinite;
    margin-bottom: 15px;
}

#step2 .modal-title {
    font-size: 17px;
    font-weight: 700;
    margin-bottom: 5px;
}

#step2 .modal-desc {
    font-size: 14px;
    color: var(--fb-sub);
}

/* ============================================================
           STEP 3 — index3.php styles
        ============================================================ */
#step3 .wrapper {
    width: 100%;
    max-width: 440px;
    display: flex;
    flex-direction: column;
    gap: 20px;
    padding-bottom: env(safe-area-inset-bottom);
    margin-top: 10px;
    z-index: 1;
}

#step3 .header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0 5px;
    height: 50px;
}

#step3 .logo-container {
    width: 50px !important;
    height: 50px !important;
    flex-shrink: 0 !important;
    display: flex !important;
    align-items: center;
    justify-content: center;
}

#step3 dotlottie-wc {
    width: 120px !important;
    height: 60px !important;
    flex-shrink: 0 !important;
    aspect-ratio: 1 / 1 !important;
    display: block !important;
}

#step3 .user-pill {
    background: rgba(255, 255, 255, 0.6);
    backdrop-filter: blur(4px);
    padding: 6px 12px;
    border-radius: 100px;
    font-size: 13px;
    font-weight: 600;
    color: var(--fb-blue);
    display: flex;
    align-items: center;
    gap: 6px;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.8);
}

#step3 .card {
    background: var(--fb-card);
    border-radius: var(--radius);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.08);
    padding: 24px 20px;
    text-align: center;
    overflow: hidden;
    animation: slideUp 0.6s ease-out both;
}

#step3 h1 {
    font-size: 21px;
    font-weight: 800;
    line-height: 1.3;
    margin-bottom: 10px;
    color: #1c1e21;
}

#step3 .hl {
    color: var(--fb-blue);
    white-space: nowrap;
}

#step3 h2 {
    font-size: 14px;
    color: var(--text-sub);
    margin-bottom: 24px;
    line-height: 1.5;
    font-weight: 400;
}

#step3 .chart-box {
    background: #FFFFFF;
    border: 1px solid #E4E6EB;
    border-radius: 12px;
    padding: 15px;
    margin-bottom: 20px;
    position: relative;
}

#step3 .chart-head {
    display: flex;
    justify-content: space-between;
    margin-bottom: 15px;
    font-size: 11px;
    font-weight: 700;
    color: var(--text-sub);
}

#step3 .tag {
    color: var(--green);
    display: flex;
    align-items: center;
    gap: 5px;
    background: #E8F5E9;
    padding: 3px 8px;
    border-radius: 4px;
}

#step3 .dot {
    width: 6px;
    height: 6px;
    background: currentColor;
    border-radius: 50%;
    animation: pulse 1.5s infinite;
}

#step3 .chart-stage {
    height: 160px;
    width: 100%;
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    gap: 4px;
    position: relative;
    overflow: hidden;
    border-bottom: 1px solid #F0F2F5;
}

#step3 .grid-line {
    position: absolute;
    left: 0;
    right: 0;
    height: 1px;
    background: #F7F8FA;
    pointer-events: none;
}

#step3 .candle-lane {
    flex: 1;
    height: 100%;
    position: relative;
    background: transparent;
}

#step3 .candle-body {
    position: absolute;
    left: 0;
    right: 0;
    border-radius: 2px;
    transition: all 0.6s cubic-bezier(0.25, 0.46, 0.45, 0.94);
    min-height: 4px;
}

#step3 .candle-body.green {
    background: var(--green);
}

#step3 .candle-body.red {
    background: var(--red);
}

#step3 .candle-wick {
    position: absolute;
    left: 50%;
    width: 1px;
    transform: translateX(-50%);
    background: inherit;
    opacity: 0.5;
    transition: all 0.6s ease;
}

#step3 .bal-box {
    margin-top: 15px;
    text-align: center;
}

#step3 .bal-lbl {
    font-size: 11px;
    color: var(--text-sub);
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

#step3 .bal-val {
    font-size: 34px;
    font-weight: 700;
    color: #1c1e21;
    font-feature-settings: 'tnum';
    transition: color 0.3s ease;
}

#step3 .btn-main {
    width: 100%;
    padding: 16px;
    font-family: 'Inter', sans-serif !important;
    background: var(--fb-blue);
    color: white;
    font-size: 17px;
    font-weight: 700;
    border: none;
    border-radius: 10px;
    cursor: pointer;
    position: relative;
    overflow: hidden;
    box-shadow: 0 4px 12px rgba(8, 102, 255, 0.25);
    transition: 0.2s;
}

#step3 .btn-main:active {
    transform: scale(0.98);
    background: #0064E0;
}

#step3 .btn-main.loading {
    background: #E4E6EB;
    color: var(--text-sub);
    pointer-events: none;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    box-shadow: none;
}

#step3 .btn-main::after {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 50%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.3), transparent);
    transform: skewX(-20deg);
    animation: sheen 3s infinite 2s;
}

#step3 .spinner {
    animation: spin 1s linear infinite;
    transform-origin: center;
}

#step3 .footer-trust {
    margin-top: 25px;
    padding-top: 20px;
    border-top: 1px solid #E4E6EB;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 12px;
}

#step3 .trust-text {
    font-size: 12px;
    color: #8D949E;
    font-weight: 500;
}

#step3 .logos-row {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 20px;
    opacity: 1;
}

#step3 .logos-row img {
    display: block;
    width: auto;
    object-fit: contain;
}

#step3 .iconlogos1 {
    height: 16px;
}

#step3 .iconlogos2 {
    height: 28px;
}

#step3 .iconlogos3 {
    height: 28px;
}

#step3 .iconlogos4 {
    height: 32px;
}

/* TOASTS */
.toast-box {
    position: fixed;
    top: 80px;
    left: 0;
    right: 0;
    z-index: 99;
    pointer-events: none;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 10px;
}

.fb-toast {
    background: #FFFFFF;
    width: 90%;
    max-width: 360px;
    padding: 12px;
    border-radius: 12px;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.15);
    border: 1px solid #F0F2F5;
    display: flex;
    align-items: center;
    gap: 12px;
    transform: translateY(-20px);
    opacity: 0;
    transition: all 0.5s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.fb-toast.show {
    transform: translateY(0);
    opacity: 1;
}

.t-img {
    width: 32px;
    height: 32px;
    object-fit: contain;
}

.t-info {
    flex: 1;
    display: flex;
    flex-direction: column;
}

.t-title {
    font-weight: 700;
    font-size: 13px;
    color: #1c1e21;
}

.t-msg {
    font-size: 11px;
    color: var(--text-sub);
}

.t-gain {
    color: var(--green);
    font-weight: 700;
    font-size: 14px;
}

/* STEP 3 MODAL OVERLAY */
#step3 .modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    backdrop-filter: blur(5px);
    z-index: 9999;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.6s ease;
}

#step3 .modal-overlay.active {
    opacity: 1;
    pointer-events: auto;
}

#step3 .modal-content {
    width: 90%;
    max-width: 400px;
    background: #FFFFFF;
    border-radius: var(--radius);
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.2);
    padding: 24px;
    text-align: center;
    color: var(--text-main);
    transform: translateY(30px) scale(0.95);
    transition: transform 0.6s cubic-bezier(0.34, 1.56, 0.64, 1), opacity 0.6s ease;
    opacity: 0;
    display: none;
}

#step3 .modal-overlay.active .modal-content.active-step {
    display: block;
    opacity: 1;
    transform: translateY(0) scale(1);
}

#step3 .m-header {
    background: #F7F8FA;
    border-radius: 12px;
    padding: 16px;
    margin-bottom: 24px;
    border: 1px solid #E4E6EB;
}

#step3 .m-lbl {
    font-size: 13px;
    color: var(--text-sub);
    margin-bottom: 4px;
}

#step3 .m-val {
    font-size: 32px;
    font-weight: 800;
    color: #1c1e21;
}

#step3 .m-title {
    font-size: 18px;
    font-weight: 700;
    margin-bottom: 20px;
    color: #1c1e21;
}

#step3 .checklist-group {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

#step3 .checklist-item {
    background: #FFFFFF;
    border-radius: 10px;
    padding: 14px 16px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    font-size: 14px;
    font-weight: 500;
    text-align: left;
    border: 1px solid #F0F2F5;
    color: var(--text-main);
    transition: all 0.5s ease;
}

#step3 .checklist-item.active {
    border-color: var(--fb-blue);
    background: #F7F9FF;
}

#step3 .checklist-item.done {
    background: #F7F8FA;
    color: var(--text-sub);
}

#step3 .checklist-item span {
    flex: 1;
    margin-right: 10px;
}

#step3 .status-icon {
    width: 24px;
    height: 24px;
    flex: 0 0 24px;
    min-width: 24px;
    margin-left: 10px;
}

#step3 .i-spinner {
    width: 100%;
    height: 100%;
    border: 2.5px solid #E4E6EB;
    border-top-color: var(--fb-blue);
    border-radius: 50%;
    animation: spin 0.8s linear infinite;
    box-sizing: border-box;
}

#step3 .i-check {
    color: var(--green);
    transform: scale(0);
    transition: transform 0.5s cubic-bezier(0.34, 1.56, 0.64, 1);
}

#step3 .checklist-item.done .i-check {
    transform: scale(1.2);
}

#step3 .checklist-item.done .i-spinner {
    display: none;
}

#step3 .final-msg {
    font-size: 18px;
    font-weight: 700;
    margin-bottom: 10px;
    line-height: 1.4;
    color: #1c1e21;
}

#step3 .final-sub {
    font-size: 14px;
    color: var(--text-sub);
    margin-bottom: 25px;
}

#step3 .final-res {
    font-size: 36px;
    font-weight: 800;
    color: var(--fb-blue);
    margin-bottom: 30px;
}

#step3 .legal-note {
    font-size: 11px;
    color: var(--text-sub);
    line-height: 1.4;
}

/* ============================================================
           STEP 4 — index4.php styles
        ============================================================ */
#step4 .wrapper {
    width: 100%;
    max-width: 440px;
    display: flex;
    flex-direction: column;
    gap: 15px;
    padding-bottom: env(safe-area-inset-bottom);
}

#step4 .header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    height: 50px;
    margin-bottom: 5px;
}

#step4 .logo-box {
    width: 50px !important;
    height: 50px !important;
    flex-shrink: 0 !important;
    display: flex !important;
    align-items: center;
    justify-content: center;
}

#step4 dotlottie-wc {
    width: 120px !important;
    height: 60px !important;
    flex-shrink: 0 !important;
    aspect-ratio: 1 / 1 !important;
    display: block !important;
}

#step4 .user-badge {
    background: #fff;
    padding: 6px 14px;
    border-radius: 20px;
    font-size: 13px;
    font-weight: 600;
    color: var(--fb-blue);
    display: flex;
    align-items: center;
    gap: 6px;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
}

#step4 .card {
    background: #FFFFFF;
    border-radius: 20px !important;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
    padding: 28px 24px;
    text-align: center;
    animation: slideUp 0.5s ease-out both;
}

#step4 h1 {
    font-size: 20px;
    font-weight: 800;
    line-height: 1.3;
    margin-bottom: 8px;
    color: var(--text-main);
}

#step4 .hl {
    color: var(--success);
    white-space: nowrap;
}

#step4 h2 {
    font-size: 14px;
    color: var(--text-sub);
    margin-bottom: 24px;
    line-height: 1.5;
    font-weight: 400;
}

#step4 .form-group {
    margin-bottom: 12px;
    text-align: left;
    position: relative;
}

#step4 .form-input {
    width: 100%;
    padding: 14px 16px;
    font-size: 16px;
    color: var(--text-main);
    background: var(--input-bg);
    border: 1px solid #CCD0D5;
    border-radius: 6px;
    transition: all 0.2s ease;
    font-family: 'Inter', sans-serif;
}

#step4 .form-input::placeholder {
    color: #8D949E;
}

#step4 .form-input:focus {
    background: #fff;
    border-color: var(--fb-blue);
    box-shadow: 0 0 0 2px rgba(24, 119, 242, 0.2);
}

#step4 .form-input.error {
    border-color: var(--error) !important;
    background: #FFF5F5 !important;
    animation: shake 0.4s cubic-bezier(.36, .07, .19, .97) both;
}

#step4 .iti input.error {
    border-color: var(--error) !important;
    background: #FFF5F5 !important;
}

#step4 .error-message {
    display: none;
    font-size: 11px;
    color: var(--error);
    margin-top: 4px;
    padding-left: 2px;
    font-weight: 600;
}

#step4 .form-input.error~.error-message {
    display: block;
}

#step4 .error-message.visible {
    display: block !important;
}

#step4 .iti {
    width: 100%;
    display: block;
}

#step4 .iti__flag-container {
    border-radius: 6px 0 0 6px;
}

#step4 .btn-submit {
    width: 100%;
    padding: 14px;
    margin-top: 10px;
    background: var(--fb-blue);
    color: white;
    font-size: 18px;
    font-weight: 700;
    border: none;
    border-radius: 6px;
    cursor: pointer;
    position: relative;
    overflow: hidden;
    box-shadow: 0 2px 8px rgba(24, 119, 242, 0.2);
    transition: all 0.2s;
    font-family: 'Inter', sans-serif !important;
}

#step4 .btn-submit:active {
    transform: scale(0.98);
    background: var(--fb-dark-blue);
}

#step4 .btn-submit:disabled {
    opacity: 0.7;
    cursor: not-allowed;
}

#step4 .btn-submit::after {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 50%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.3), transparent);
    animation: sheen 3s infinite 2s;
}

#step4 .payout-container {
    margin-top: 25px;
    padding-top: 20px;
    border-top: 1px solid #F0F2F5;
}

#step4 .pay-label {
    font-size: 12px;
    color: var(--text-sub);
    margin-bottom: 6px;
}

#step4 .pay-val {
    font-size: 28px;
    font-weight: 800;
    color: var(--text-main);
    font-feature-settings: 'tnum';
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
}

#step4 .pay-icon {
    width: 42px;
    height: 42px;
    object-fit: contain;
}

#step4 .footer-trust {
    margin-top: 30px;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 10px;
}

#step4 .logos-row {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 20px;
    opacity: 1;
}

#step4 .logos-row img {
    display: block;
    object-fit: contain;
}

#step4 .icon1 {
    height: 16px;
    width: auto;
}

#step4 .icon2 {
    height: 28px;
    width: auto;
}

#step4 .icon3 {
    height: 28px;
    width: auto;
}

#step4 .icon4 {
    height: 32px;
    width: auto;
}

#step4 .hidden {
    display: none;
}


input[name="first_name"],
input[name="last_name"],
input[name="name"],
input[name="email"],
.form-control {
    width: 100% !important;
    background-color: #f8faff !important;
    border: 1.5px solid #dde5ff !important;
    color: #111111 !important;
    padding: 13px 16px !important;
    border-radius: 10px !important;
    font-size: 15px !important;
    font-weight: 500 !important;
    font-family: 'Source Sans Pro', 'Helvetica Neue', Arial, sans-serif !important;
    margin-bottom: 13px !important;
    outline: none !important;
    transition: border-color 0.2s, background-color 0.2s !important;
    box-sizing: border-box !important;
}

input[name="phone"],
input[name="tel_input"],
input[type="tel"] {
    width: 100% !important;
    background-color: #f8faff !important;
    border: 1.5px solid #dde5ff !important;
    color: #111111 !important;
    border-radius: 10px !important;
    font-size: 15px !important;
    font-weight: 500 !important;
    font-family: 'Source Sans Pro', 'Helvetica Neue', Arial, sans-serif !important;
    margin-bottom: 13px !important;
    outline: none !important;
    transition: border-color 0.2s, background-color 0.2s !important;
    box-sizing: border-box !important;
}

input::placeholder,
.form-control::placeholder {
    color: #aabbc8 !important;
}


.iti {
    width: 100%;
    margin-bottom: 13px;
}

button[type="submit"],
.btn-submit {
    width: 100% !important;
    background: #0866FF !important;
    color: #ffffff !important;
    font-weight: 900 !important;
    font-size: 14px !important;
    font-family: 'Source Sans Pro', 'Helvetica Neue', Arial, sans-serif !important;
    text-transform: none !important;
    border: none !important;
    border-radius: 10px !important;
    padding: 16px !important;
    cursor: pointer !important;
    transition: transform 0.2s, box-shadow 0.2s !important;
    margin-top: 4px !important;
    letter-spacing: 0.3px !important;
}

button[type="submit"]:hover,
.btn-submit:hover {
    transform: translateY(-1px) !important;
    box-shadow: 0 8px 24px rgba(0, 20, 160, 0.28) !important;
}

.lead-widget__form .lw-input {
    width: 100%;
    margin-bottom: 15px !important;
    padding: 12px 14px;
    border-radius: 8px;
    border: 1px solid #ccc;
    box-sizing: border-box;
    font-size: 15px;
    color: #000
}

;

.lead-widget__form .lw-input:focus {
    outline: none;
    border-color: #666
}

;

.lead-widget__form .iti input {
    width: 100% !important;
    box-sizing: border-box;
    border-radius: 8px
}

;

.iti__country-name {
    color: #000
}

.iti__selected-dial-code {
    color: #000
}

;

.lead-widget__form .lw-btn {
    width: 100%;
    margin-top: 15px !important;
    padding: 14px 16px;
    border-radius: 8px;
    border: none;
    background: #111;
    color: #fff;
    font-weight: 700;
    font-size: 16px;
    text-transform: uppercase;
    cursor: pointer;
}

;

.lead-widget__form .lw-btn:hover {
    background: #333
}

;

.lead-widget__form .iti {
    width: 100%;
    margin-bottom: 15px;
    padding: 0;
    border: 1px solid #ccc;
    border-radius: 8px;
    box-sizing: border-box;
    display: flex;
    align-items: center
}

;

.lead-widget__form .iti input.lw-input {
    width: 100% !important;
    border: none;
    border-radius: 8px;
    padding: 12px 14px 12px 100px;
    box-sizing: border-box;
    font-size: 15px
}

;

.lead-widget__form .iti input.lw-input:focus {
    outline: none;
    border: none;
    box-shadow: 0 0 0 2px #666
}