/* ── فونت ── */
@font-face {
    font-family: 'IRANSansX';
    src: url('https://cdn.jsdelivr.net/gh/rastikerdar/iran-sans-x@latest/dist/IRANSansX-Regular.woff2') format('woff2');
    font-weight: 400;
    font-display: swap;
}
@font-face {
    font-family: 'IRANSansX';
    src: url('https://cdn.jsdelivr.net/gh/rastikerdar/iran-sans-x@latest/dist/IRANSansX-Medium.woff2') format('woff2');
    font-weight: 500;
    font-display: swap;
}

/* ── ریست محلی ── */
.nlsms-wrap *,
.nlsms-wrap *::before,
.nlsms-wrap *::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

/* ── بدنه فرم ── */
.nlsms-wrap {
    font-family: var(--e-global-typography-text-font-family,
                 inherit,
                 'IRANSansX', sans-serif);
    direction: rtl;
    width: 100%;
}

.nlsms-form {
    display: flex;
    align-items: center;
    gap: 10px;
    background: #1c1c1e;
    border-radius: 999px;
    padding: 8px 8px 8px 8px;
    width: 100%;
    max-width: 520px;
}

/* ── اینپوت ── */
.nlsms-input {
    flex: 1;
    background: transparent;
    border: none;
    outline: none;
    color: #b0b0b5;
    font-family: inherit;
    font-size: 15px;
    text-align: right;
    direction: rtl;
    padding: 6px 14px;
    min-width: 0;
}

.nlsms-input::placeholder {
    color: #6e6e73;
    font-family: inherit;
}

/* مقدار وارد‌شده چپ‌چین ماند */
.nlsms-input:not(:placeholder-shown) {
    direction: ltr;
    text-align: left;
}

/* ── دکمه ── */
.nlsms-btn {
    flex-shrink: 0;
    background: #ffffff;
    color: #1c1c1e;
    border: none;
    border-radius: 999px;
    font-family: inherit;
    font-size: 15px;
    font-weight: 500;
    cursor: pointer;
    padding: 10px 28px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    transition: opacity .2s, transform .15s;
    white-space: nowrap;
    line-height: 1;
}

.nlsms-btn:hover  { opacity: .9; }
.nlsms-btn:active { transform: scale(.97); }

.nlsms-btn:disabled {
    opacity: .6;
    cursor: not-allowed;
}

/* ── اسپینر ── */
.nlsms-spinner {
    width: 14px;
    height: 14px;
    border: 2px solid rgba(28,28,30,.3);
    border-top-color: #1c1c1e;
    border-radius: 50%;
    animation: nlsms-spin .7s linear infinite;
    display: none;
}

.nlsms-btn.loading .nlsms-spinner { display: block; }
.nlsms-btn.loading .nlsms-btn-text { display: none; }

@keyframes nlsms-spin {
    to { transform: rotate(360deg); }
}

/* ── پیام ── */
.nlsms-msg {
    margin-top: 12px;
    font-size: 13.5px;
    padding: 10px 16px;
    border-radius: 10px;
    max-width: 520px;
    opacity: 0;
    transform: translateY(-6px);
    transition: opacity .3s ease, transform .3s ease;
    display: none;
    font-family: inherit;
}

.nlsms-msg.show {
    display: block;
    opacity: 1;
    transform: translateY(0);
}

.nlsms-msg.success {
    background: rgba(52, 199, 89, .12);
    color: #2da44e;
    border: 1px solid rgba(52, 199, 89, .25);
}

.nlsms-msg.error {
    background: rgba(255, 59, 48, .10);
    color: #d93025;
    border: 1px solid rgba(255, 59, 48, .22);
}

/* ── ریسپانسیو ── */
@media (max-width: 480px) {
    .nlsms-form {
        padding: 6px 6px 6px 6px;
        gap: 8px;
    }
    .nlsms-btn {
        padding: 9px 20px;
        font-size: 14px;
    }
    .nlsms-input {
        font-size: 14px;
    }
}