.wsms-otp-shell {
    --wsms-primary: #2563eb;
    --wsms-primary-dark: #1d4ed8;
    --wsms-border: #e5e7eb;
    --wsms-muted: #6b7280;
    --wsms-error: #b91c1c;
    --wsms-success: #15803d;
    box-sizing: border-box;
    width: 100%;
    padding: 24px 12px;
    color: #111827;
    font-family: inherit;
}

.wsms-otp-shell *,
.wsms-otp-shell *::before,
.wsms-otp-shell *::after {
    box-sizing: border-box;
}

.wsms-otp-card {
    position: relative;
    width: 100%;
    max-width: 430px;
    min-height: 420px;
    margin: 0 auto;
    padding: 38px 34px 30px;
    overflow: hidden;
    background: #fff;
    border: 1px solid var(--wsms-border);
    border-radius: 22px;
    box-shadow: 0 20px 50px rgba(17, 24, 39, .09);
}

.wsms-otp-step {
    display: none;
    animation: wsmsOtpFade .22s ease-out;
}

.wsms-otp-step.is-active {
    display: block;
}

.wsms-otp-icon,
.wsms-otp-success-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 64px;
    height: 64px;
    margin: 0 auto 18px;
    color: var(--wsms-primary);
    background: #eff6ff;
    border-radius: 20px;
}

.wsms-otp-icon svg {
    width: 30px;
    height: 30px;
    fill: currentColor;
}

.wsms-otp-success-icon {
    color: var(--wsms-success);
    background: #f0fdf4;
    font-size: 34px;
    font-weight: 700;
}

.wsms-otp-card h2,
.wsms-otp-card h3 {
    margin: 0 0 10px;
    color: #111827;
    font-size: 24px;
    font-weight: 800;
    line-height: 1.45;
    text-align: center;
}

.wsms-otp-card p {
    margin: 0 0 26px;
    color: var(--wsms-muted);
    font-size: 14px;
    line-height: 1.9;
    text-align: center;
}

.wsms-otp-card label:not(.screen-reader-text) {
    display: block;
    margin: 0 0 8px;
    color: #374151;
    font-size: 13px;
    font-weight: 700;
}

.wsms-otp-card input[type="tel"],
.wsms-otp-card input[type="text"]:not(.wsms-otp-website) {
    display: block;
    width: 100%;
    height: 52px;
    margin: 0 0 14px;
    padding: 0 16px;
    color: #111827;
    background: #fff;
    border: 1px solid #d1d5db;
    border-radius: 12px;
    box-shadow: none;
    outline: none;
    font: inherit;
    font-size: 16px;
    text-align: left;
    transition: border-color .18s ease, box-shadow .18s ease;
}

.wsms-otp-card input[type="tel"]:focus,
.wsms-otp-card input[type="text"]:not(.wsms-otp-website):focus {
    border-color: var(--wsms-primary);
    box-shadow: 0 0 0 4px rgba(37, 99, 235, .1);
}

.wsms-otp-card .wsms-otp-code {
    height: 60px;
    font-size: 25px !important;
    font-weight: 800;
    letter-spacing: .55em;
    text-align: center !important;
    text-indent: .55em;
}

.wsms-otp-button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    min-height: 50px;
    padding: 11px 20px;
    color: #fff !important;
    background: var(--wsms-primary);
    border: 0;
    border-radius: 12px;
    box-shadow: none;
    cursor: pointer;
    font: inherit;
    font-size: 15px;
    font-weight: 800;
    line-height: 1.5;
    text-decoration: none !important;
    transition: background .18s ease, transform .18s ease, opacity .18s ease;
}

.wsms-otp-button:hover,
.wsms-otp-button:focus {
    color: #fff !important;
    background: var(--wsms-primary-dark);
}

.wsms-otp-button:active {
    transform: translateY(1px);
}

.wsms-otp-button:disabled,
.wsms-otp-button.is-loading {
    cursor: wait;
    opacity: .65;
}

.wsms-otp-button-secondary {
    color: #374151 !important;
    background: #f3f4f6;
}

.wsms-otp-button-secondary:hover,
.wsms-otp-button-secondary:focus {
    color: #111827 !important;
    background: #e5e7eb;
}

.wsms-otp-message {
    display: none;
    margin-top: 16px;
    padding: 10px 12px;
    border-radius: 10px;
    font-size: 13px;
    line-height: 1.7;
    text-align: center;
}

.wsms-otp-message.is-visible {
    display: block;
}

.wsms-otp-message.is-error {
    color: var(--wsms-error);
    background: #fef2f2;
}

.wsms-otp-message.is-success {
    color: var(--wsms-success);
    background: #f0fdf4;
}

.wsms-otp-back {
    position: absolute;
    top: 22px;
    right: 22px;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 36px;
    padding: 0 0 4px;
    color: #4b5563;
    background: #f3f4f6;
    border: 0;
    border-radius: 50%;
    cursor: pointer;
    font-size: 30px;
    line-height: 1;
}

.wsms-otp-sent-to {
    direction: rtl;
}

.wsms-otp-sent-to b {
    direction: ltr;
    display: inline-block;
    color: #374151;
}

.wsms-otp-resend-row {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: center;
    gap: 8px;
    min-height: 30px;
    margin-top: 18px;
    color: var(--wsms-muted);
    font-size: 13px;
}

.wsms-otp-resend {
    padding: 3px;
    color: var(--wsms-primary);
    background: transparent;
    border: 0;
    cursor: pointer;
    font: inherit;
    font-weight: 700;
}

.wsms-otp-resend:disabled {
    color: #9ca3af;
    cursor: default;
}

.wsms-otp-website {
    position: absolute !important;
    left: -10000px !important;
    width: 1px !important;
    height: 1px !important;
    opacity: 0 !important;
    pointer-events: none !important;
}

.wsms-otp-actions {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 10px;
}

.wsms-otp-logged-in .wsms-otp-card {
    min-height: 0;
    text-align: center;
}

@keyframes wsmsOtpFade {
    from { opacity: 0; transform: translateY(7px); }
    to { opacity: 1; transform: translateY(0); }
}

@media (max-width: 520px) {
    .wsms-otp-shell {
        padding: 14px 8px;
    }

    .wsms-otp-card {
        min-height: 390px;
        padding: 30px 20px 24px;
        border-radius: 17px;
    }

    .wsms-otp-card h2,
    .wsms-otp-card h3 {
        font-size: 21px;
    }
}

@media (prefers-reduced-motion: reduce) {
    .wsms-otp-step,
    .wsms-otp-button,
    .wsms-otp-card input {
        animation: none !important;
        transition: none !important;
    }
}

