/* Scope reset: neutralize theme/Elementor default button & link styles
   bleeding into our popup (this was causing the pink border on hover) */
.eov-wizard,
.eov-wizard *,
.eov-wizard *::before,
.eov-wizard *::after {
    box-sizing: border-box;
}

.eov-wizard a,
.eov-wizard a:hover,
.eov-wizard a:focus,
.eov-wizard a:visited {
    text-decoration: none;
    box-shadow: none;
}

.eov-wizard button,
.eov-wizard input,
.eov-wizard select,
.eov-wizard textarea {
    font-family: inherit;
    -webkit-appearance: none;
    appearance: none;
}

.eov-wizard {
    max-width: 400px;
    margin: 0 auto;
    background: #ffffff;
    border-radius: 16px;
    padding: 28px 26px 26px;
    box-shadow: 0 2px 10px rgba(20, 20, 20, 0.06), 0 0 0 1px rgba(20, 20, 20, 0.04);
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Arial, sans-serif;
    overflow: hidden;
}

.eov-progress {
    width: 100%;
    height: 4px;
    background: #eef0f2;
    border-radius: 2px;
    overflow: hidden;
    margin-bottom: 22px;
}

.eov-progress-fill {
    height: 100%;
    background: linear-gradient(90deg, #1a73e8, #4c94f0);
    border-radius: 2px;
    transition: width 0.45s cubic-bezier(0.4, 0, 0.2, 1);
}

.eov-step {
    display: none;
    text-align: center;
}

.eov-step.active {
    display: block;
    animation: eovSlideIn 0.35s cubic-bezier(0.16, 1, 0.3, 1);
}

@keyframes eovSlideIn {
    from { opacity: 0; transform: translateX(16px); }
    to   { opacity: 1; transform: translateX(0); }
}

@keyframes eovPop {
    0%   { transform: scale(0.9); opacity: 0; }
    60%  { transform: scale(1.04); opacity: 1; }
    100% { transform: scale(1); }
}

.eov-step-icon {
    width: 56px;
    height: 56px;
    margin: 0 auto 14px;
    border-radius: 50%;
    background: linear-gradient(145deg, #eaf1fd, #dce9fc);
    color: #1a73e8;
    display: flex;
    align-items: center;
    justify-content: center;
    animation: eovPop 0.4s ease;
}

.eov-icon-inline {
    vertical-align: -3px;
    display: inline-block;
}

.eov-title {
    font-size: 18px;
    font-weight: 600;
    margin: 0 0 6px;
    color: #1c1e21;
}

.eov-subtitle {
    font-size: 13.5px;
    color: #6b7280;
    margin: 0 0 20px;
    line-height: 1.5;
}

.eov-wizard label {
    display: block;
    text-align: left;
    font-weight: 500;
    font-size: 13px;
    color: #374151;
    margin: 14px 0 6px;
}

.eov-required {
    color: #d93025;
    font-weight: 600;
}

.eov-wizard select,
.eov-wizard input[type="text"],
.eov-wizard input[type="tel"],
.eov-wizard input[type="email"] {
    width: 100%;
    padding: 11px 14px;
    border: 1px solid #dcdfe4;
    border-radius: 10px;
    font-size: 15px;
    background: #fafbfc;
    transition: border-color 0.15s, background 0.15s, box-shadow 0.15s;
}

.eov-wizard select:focus,
.eov-wizard input:focus {
    outline: none;
    border-color: #1a73e8;
    background: #ffffff;
    box-shadow: 0 0 0 3px rgba(26, 115, 232, 0.12);
}

.eov-phone-row {
    display: flex;
    gap: 8px;
}

.eov-country-code {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0 14px;
    border: 1px solid #dcdfe4;
    border-radius: 10px;
    background: #f1f3f5;
    font-size: 15px;
    font-weight: 500;
    color: #374151;
    flex-shrink: 0;
}

.eov-phone-row .eov-mobile-input {
    flex: 1;
}

/* OTP digit boxes */
.eov-otp-boxes {
    display: flex;
    justify-content: center;
    gap: 8px;
    margin: 4px 0 4px;
}

.eov-otp-digit {
    width: 44px;
    height: 52px;
    text-align: center;
    font-size: 22px;
    font-weight: 600;
    border: 1px solid #dcdfe4;
    border-radius: 10px;
    background: #fafbfc;
    transition: border-color 0.15s, background 0.15s, box-shadow 0.15s, transform 0.1s;
}

.eov-otp-digit:focus {
    outline: none;
    border-color: #1a73e8;
    background: #ffffff;
    box-shadow: 0 0 0 3px rgba(26, 115, 232, 0.12);
    transform: translateY(-1px);
}

.eov-otp-digit.eov-shake {
    animation: eovShake 0.35s ease;
    border-color: #d93025;
}

@keyframes eovShake {
    0%, 100% { transform: translateX(0); }
    25%      { transform: translateX(-4px); }
    75%      { transform: translateX(4px); }
}

/* ---------------------------------------------------------------
   Buttons — high specificity + !important on the properties most
   commonly overridden by theme/Elementor global button styles
   (border, background, color, box-shadow on hover/focus/visited)
   --------------------------------------------------------------- */
.eov-wizard button.eov-btn,
.eov-wizard a.eov-btn {
    position: relative !important;
    overflow: hidden !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    gap: 6px !important;
    width: 100% !important;
    margin-top: 20px !important;
    padding: 14px 16px !important;
    border-radius: 12px !important;
    font-size: 15px !important;
    font-weight: 600 !important;
    cursor: pointer !important;
    text-align: center !important;
    text-decoration: none !important;
    box-sizing: border-box !important;
    transition: transform 0.12s ease, box-shadow 0.2s ease, background 0.2s ease !important;
}

.eov-wizard button.eov-btn-primary,
.eov-wizard a.eov-btn-primary {
    background: linear-gradient(135deg, #2382f0, #1a6fe0) !important;
    color: #ffffff !important;
    border: none !important;
    box-shadow: 0 2px 6px rgba(26, 111, 224, 0.28) !important;
}

.eov-wizard button.eov-btn-primary:hover,
.eov-wizard a.eov-btn-primary:hover,
.eov-wizard button.eov-btn-primary:focus,
.eov-wizard a.eov-btn-primary:focus,
.eov-wizard button.eov-btn-primary:visited,
.eov-wizard a.eov-btn-primary:visited {
    background: linear-gradient(135deg, #1d76e6, #1560c9) !important;
    color: #ffffff !important;
    border: none !important;
    box-shadow: 0 6px 16px rgba(26, 111, 224, 0.35) !important;
    transform: translateY(-1px) !important;
}

.eov-wizard button.eov-btn-primary:active,
.eov-wizard a.eov-btn-primary:active {
    transform: translateY(0) scale(0.98) !important;
    box-shadow: 0 2px 6px rgba(26, 111, 224, 0.28) !important;
}

.eov-wizard button.eov-btn-secondary,
.eov-wizard a.eov-btn-secondary {
    background: #f1f3f5 !important;
    color: #1c1e21 !important;
    border: none !important;
    box-shadow: none !important;
}

.eov-wizard button.eov-btn-secondary:hover,
.eov-wizard a.eov-btn-secondary:hover,
.eov-wizard button.eov-btn-secondary:focus,
.eov-wizard a.eov-btn-secondary:focus {
    background: #e5e7eb !important;
    color: #1c1e21 !important;
    border: none !important;
    box-shadow: none !important;
}

.eov-wizard button.eov-btn:disabled {
    cursor: not-allowed !important;
    opacity: 0.85 !important;
    transform: none !important;
}

.eov-ripple {
    position: absolute;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.5);
    transform: scale(0);
    animation: eovRipple 0.5s ease-out;
    pointer-events: none;
}

.eov-btn-secondary .eov-ripple {
    background: rgba(0, 0, 0, 0.08);
}

@keyframes eovRipple {
    to { transform: scale(3); opacity: 0; }
}

.eov-spinner {
    display: none;
    width: 16px;
    height: 16px;
    border: 2px solid rgba(255, 255, 255, 0.4);
    border-top-color: #ffffff;
    border-radius: 50%;
    animation: eovSpin 0.6s linear infinite;
}

.eov-btn.is-loading .eov-btn-label {
    visibility: hidden;
    position: absolute;
}

.eov-btn.is-loading .eov-spinner {
    display: inline-block;
}

@keyframes eovSpin {
    to { transform: rotate(360deg); }
}

.eov-error {
    color: #d93025;
    font-size: 13px;
    margin-top: 10px;
    min-height: 16px;
    text-align: center;
}

.eov-resend-row {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    font-size: 13px;
    color: #6b7280;
    margin-top: 14px;
}

.eov-wizard .eov-resend-otp,
.eov-wizard .eov-edit-mobile,
.eov-wizard .eov-retry {
    color: #1a73e8 !important;
    font-weight: 500 !important;
    text-decoration: none !important;
    border: none !important;
    background: none !important;
}

.eov-wizard .eov-resend-otp:hover,
.eov-wizard .eov-edit-mobile:hover {
    text-decoration: underline !important;
}

.eov-countdown-ring {
    display: none;
    width: 16px;
    height: 16px;
    flex-shrink: 0;
}

.eov-countdown-ring.is-active {
    display: inline-block;
}

.eov-countdown-ring circle {
    fill: none;
    stroke: #d0d5dd;
    stroke-width: 2;
}

.eov-countdown-ring .eov-ring-fill {
    stroke: #1a73e8;
    stroke-dasharray: 44;
    stroke-dashoffset: 0;
    transform: rotate(-90deg);
    transform-origin: center;
    transition: stroke-dashoffset 1s linear;
}

.eov-resend-otp.is-disabled {
    color: #9ca3af !important;
    pointer-events: none;
}

.eov-confirm-success,
.eov-confirm-failed {
    display: none;
}

.eov-step-confirm.active .eov-confirm-success.is-active,
.eov-step-confirm.active .eov-confirm-failed.is-active {
    display: block;
}

.eov-confetti-piece {
    position: absolute;
    width: 7px;
    height: 7px;
    top: 20px;
    left: 50%;
    opacity: 0;
    animation: eovConfetti 0.9s ease-out forwards;
}

@keyframes eovConfetti {
    0%   { opacity: 1; transform: translate(0, 0) rotate(0deg) scale(1); }
    100% { opacity: 0; transform: translate(var(--eov-x), var(--eov-y)) rotate(var(--eov-r)) scale(0.4); }
}

.eov-step-confirm,
.eov-step-final {
    position: relative;
}

.eov-check-circle {
    stroke: #188038;
    stroke-dasharray: 176;
    stroke-dashoffset: 176;
    animation: eovDrawCircle 0.5s ease forwards;
}

.eov-check-mark {
    stroke: #188038;
    stroke-dasharray: 48;
    stroke-dashoffset: 48;
    animation: eovDrawMark 0.35s ease 0.45s forwards;
}

.eov-x-circle {
    stroke: #d93025;
    stroke-dasharray: 176;
    stroke-dashoffset: 176;
    animation: eovDrawCircle 0.5s ease forwards;
}

.eov-x-mark {
    stroke: #d93025;
    stroke-dasharray: 56;
    stroke-dashoffset: 56;
    animation: eovDrawMark 0.35s ease 0.45s forwards;
}

@keyframes eovDrawCircle {
    to { stroke-dashoffset: 0; }
}

@keyframes eovDrawMark {
    to { stroke-dashoffset: 0; }
}

.eov-step-final svg.eov-check-svg,
.eov-step-confirm svg.eov-check-svg,
.eov-step-confirm svg.eov-x-svg {
    display: block;
    margin: 4px auto 16px;
}

.eov-step-final .eov-btn-primary {
    max-width: 260px;
    margin-left: auto;
    margin-right: auto;
}

@media (prefers-color-scheme: dark) {
    .eov-wizard {
        background: #1c1e21;
        box-shadow: 0 2px 10px rgba(0, 0, 0, 0.3), 0 0 0 1px rgba(255, 255, 255, 0.06);
    }
    .eov-title { color: #f3f4f6; }
    .eov-subtitle { color: #9ca3af; }
    .eov-wizard label { color: #d1d5db; }
    .eov-wizard select,
    .eov-wizard input[type="text"],
    .eov-wizard input[type="tel"],
    .eov-wizard input[type="email"],
    .eov-otp-digit {
        background: #2a2d31;
        border-color: #3d4147;
        color: #f3f4f6;
    }
    .eov-country-code {
        background: #2a2d31;
        border-color: #3d4147;
        color: #d1d5db;
    }
    .eov-wizard button.eov-btn-secondary,
    .eov-wizard a.eov-btn-secondary {
        background: #2a2d31 !important;
        color: #f3f4f6 !important;
    }
    .eov-wizard button.eov-btn-secondary:hover,
    .eov-wizard a.eov-btn-secondary:hover {
        background: #3d4147 !important;
    }
    .eov-progress {
        background: #2a2d31;
    }
    .eov-step-icon {
        background: linear-gradient(145deg, rgba(26,115,232,0.18), rgba(26,115,232,0.1));
    }
}
