/* ===========================
   Overlay
=========================== */

.kern-popup-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, .6);
    display: none;
    justify-content: center;
    align-items: center;
    z-index: 99999;
    padding: 20px;
}

.kern-popup-overlay.active {
    display: flex;
}

/* ===========================
   Popup
=========================== */

.kern-popup {
    background: #fff;
    width: 500px;
    max-width: 620px;
    border-radius: 12px;
    position: relative;
    padding: 24px;
    max-height: 90vh;
    overflow-y: auto;
    animation: kernPopup .25s ease;
}

@keyframes kernPopup {

    from {
        opacity: 0;
        transform: scale(.95);
    }

    to {
        opacity: 1;
        transform: scale(1);
    }

}

/* ===========================
   Close
=========================== */

.kern-popup .kern-popup-close {
    position: absolute;
    right: 16px;
    top: 16px;
    width: 36px;
    height: 36px;
    border: none;
    cursor: pointer;
    line-height: 1;
    background: transparent !important;
    color: #777777 !important;
    padding: 0px 20px !important;
    display: flex !important;
    font-size: 34px !important;
}

/* ===========================
   Steps
=========================== */

.kern-step {
    display: none;
}

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

/* ===========================
   Headings
=========================== */

.kern-step h2 {
    margin: 0 0 24px;
    font-size: 22px;
    font-weight: 500;
    color: #54B1E3;
    letter-spacing:0 !important;
    margin-bottom: 4px !important;
}

/* ===========================
   Paragraphs
=========================== */

.kern-content p {
    margin-bottom: 18px;
    line-height: 20px;
    color: #777777;
    font-size:16px;
    font-weight: 300;
    font-family: ubuntu;
}

/* ===========================
   Progress
=========================== */

.kern-progress-wrapper {
    margin-bottom: 30px;
}

.progress-wrapper{
    display: flex;
    gap: 5px;
    align-items: center;
    padding-top:20px;
}

.kern-progress {
    flex: 1;
    height: 8px;
    background: #eee;
    border-radius: 50px;
    overflow: hidden;
}

.kern-progress-bar {
    height: 100%;
    background: #54B1E3;
    width: 0;
    transition: .3s;
}

.kern-progress-wrapper span {
    font-weight: 600;
    min-width: 40px;
}

/* ===========================
   Fields
=========================== */

.kern-field {
    display: flex;
    flex-direction: column;
    gap: 16px;
    margin-bottom: 28px;
}

.kern-field label {
    font-weight: 600;
    line-height: 1.6;
    color: #222;
}

.kern-field input,.kern-field textarea {
    width: 100%;
    border: 1px solid #ddd;
    border-radius: 8px;
    padding: 14px 16px;
    font-size: 16px;
    outline: none;
    transition: .2s;
    font-family: inherit;
}

.kern-field input {
    height: 50px;
}

.kern-field textarea {
    resize: vertical;
    min-height: 140px;
}

.kern-field input:focus,.kern-field textarea:focus {
    border-color: #C8A45D;
}

/* ===========================
   Error
=========================== */

.kern-error {
    border-color: #e53935 !important;
}

/* ===========================
   Buttons
=========================== */

.kern-next,
.kern-submit,
.kern-prev {
    cursor: pointer;
    border: none;
    transition: .2s;
    font-size: 20px;
    border-radius: 5px;
}

.kern-step .kern-submit.sc_button_hover_slide_left,
.kern-step .kern-next.sc_button_hover_slide_left {
    margin-top: 32px;
    width: 100%;
    height: 56px;
    background:#C5A983 !important;
    background-color: #C5A983 !important;
    color: #fff;
}

.kern-step .kern-next:hover,
.kern-step .kern-submit:hover {
    opacity: .9;
}

.kern-prev {
    background: none;
    color: #555;
    padding: 0;
    font-size: 16px;
}

/* ===========================
   Success
=========================== */

.kern-success {
    text-align: center;
    line-height: 1.9;
    padding: 40px 10px;
}

.kern-success p {
    margin-bottom: 16px;
}

/* ===========================
   Scrollbar
=========================== */

.kern-popup::-webkit-scrollbar {
    width: 8px;
}

.kern-popup::-webkit-scrollbar-thumb {
    background: #ccc;
    border-radius: 50px;
}

/* ===========================
   Mobile
=========================== */

@media(max-width:768px) {
    .kern-popup {
        width: 100%;
        max-width: 100%;
        max-height: 95vh;
        border-radius: 10px;
        padding: 20px;
    }

    .kern-step h2 {
        font-size: 28px;
    }

    .kern-next,
    .kern-submit {
        font-size: 18px;
        height: 52px;
    }

}

@media(max-width:480px) {
    .kern-popup {
        padding: 18px;
    }

    .kern-step h2 {
        font-size: 24px;
    }

    .kern-field label {
        font-size: 15px;
    }

    .kern-field input,
    .kern-field textarea {
        font-size: 15px;
    }

}

.kern-error {
    border: 1px solid #d93025 !important;
}

.kern-error-message {
    margin-top: 8px;
    color: #d93025;
    font-size: 14px;
    line-height: 1.4;
}

.kern-form-error {
    display: none;
    margin-top: 20px;
    margin-bottom: 20px;
    padding: 12px 15px;
    border-radius: 5px;
    background: #fdeaea;
    border: 1px solid #e74c3c;
    color: #b71c1c;
}

.kern-form-error.show {
    display: block;
}