
/* خود مودال به صورت fixed و overlay */
.global-sms-modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.5);
    backdrop-filter: blur(8px);          /* افکت بلور */
    z-index: 9999 !important;
    justify-content: center;
    align-items: center;
}

.global-sms-modal.show {
    display: flex;
}

/* دیالوگ */
.global-sms-modal .modal-dialog {
    justify-content: center;
    max-width: 580px;
    width: 90%;
    margin: 0.75rem auto;
    transition: transform 0.3s ease-out;
}

/* محتوا */
.global-sms-modal .sms-modal-content {
    position: relative;
    display: flex;
    flex-direction: column;
    color: var(--bs-modal-color);
    pointer-events: auto;
    outline: 0;
    animation: modalFadeIn 0.3s ease;
    width: 500px;
    border: none;
    border-radius: 20px;
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.25);
    background: #ffffff;
    overflow: hidden;
    animation: modalFadeIn 0.3s ease;
}

@keyframes modalFadeIn {
    from { opacity: 0; transform: translateY(-20px); }
    to { opacity: 1; transform: translateY(0); }
}

/* هدر */
.global-sms-modal .modal-header {
    background: linear-gradient(135deg, #2c6db4 0%, #1a5276 100%);
    color: white;
    border-bottom: none;
    padding: 1rem 1.5rem;
    align-items: center;
}

.global-sms-modal .modal-title {
    color: #fff;
    font-size: 1.1rem;
    font-weight: 600;
    letter-spacing: -0.3px;
}

.global-sms-modal .modal-header .btn-close {
    opacity: 0.8;
    background: transparent url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16' fill='%23fff'%3e%3cpath d='M.293.293a1 1 0 011.414 0L8 6.586 14.293.293a1 1 0 111.414 1.414L9.414 8l6.293 6.293a1 1 0 01-1.414 1.414L8 9.414l-6.293 6.293a1 1 0 01-1.414-1.414L6.586 8 .293 1.707a1 1 0 010-1.414z'/%3e%3c/svg%3e") center/1em auto no-repeat;
    cursor: pointer;
}

/* بدنه */
.global-sms-modal .sms-modal-body {
    padding: 1.5rem;
    background: #f8fafc;
}

/* انتخاب نوع */
.global-sms-modal .sms-modal__type-selector {
    margin-bottom: 1.2rem;
}

.global-sms-modal .sms-modal__type-selector label.form-label {
    font-size: 0.9rem;
    font-weight: 600;
    color: #334155;
    margin-bottom: 0.5rem;
}

.global-sms-modal .form-check-input:checked {
    background-color: #2c6db4;
    border-color: #2c6db4;
}

/* فیلد تعداد */
.global-sms-modal .sms-modal__qty-input {
    font-size: 1rem;
    padding: 0.6rem 1rem;
    border-radius: 12px;
    border: 1px solid #cbd5e1;
    background: #fff;
    transition: border-color 0.2s, box-shadow 0.2s;
    text-align: center;
    font-family: inherit;
}

.global-sms-modal .sms-modal__qty-input:focus {
    border-color: #2c6db4;
    box-shadow: 0 0 0 3px rgba(44, 109, 180, 0.2);
    outline: none;
}

/* خلاصه قیمت */
.global-sms-modal .sms-modal__summary {
    background: #ffffff;
    border: 1px solid #e2e8f0;
    border-radius: 16px;
    padding: 1rem 1.2rem;
    margin: 1.2rem 0;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.03);
}

.global-sms-modal .sms-modal__summary-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 0.9rem;
    color: #475569;
    margin-bottom: 0.5rem;
}

.global-sms-modal .sms-modal__summary-row.total {
    font-size: 1rem;
    font-weight: 700;
    color: #1e293b;
    border-top: 2px dashed #e2e8f0;
    padding-top: 0.8rem;
    margin-top: 0.8rem;
    margin-bottom: 0;
}

.global-sms-modal .sms-modal__summary-row.total strong {
    color: #10b981;
}
/* پیام موفقیت */
.global-sms-modal .sms-modal__success {
    display: none;
    font-size: 0.85rem;
    color: #15803d;
    background: #e6f7e6;
    border-radius: 10px;
    padding: 0.5rem 1rem;
    margin-top: 0.8rem;
    text-align: center;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
}

/* خطا */
.global-sms-modal .sms-modal__error {
    display: none;
    font-size: 0.85rem;
    color: #dc2626;
    background: #fef2f2;
    border-radius: 10px;
    padding: 0.5rem 1rem;
    margin-top: 0.8rem;
    text-align: center;
}

/* فوتر */
.global-sms-modal .modal-footer {
    border-top: 1px solid #e2e8f0;
    padding: 1rem 1.5rem;
    justify-content: space-between;
}

.global-sms-modal .btn {
    border-radius: 12px;
    font-weight: 500;
    padding: 0.5rem 1.2rem;
    transition: all 0.2s;
    width: auto;
}

.global-sms-modal .btn-pay {
    background: #2c6db4;
    border: none;
    color: white;
}

.global-sms-modal .btn-pay:hover:not(:disabled) {
    background: #1a5276;
    transform: translateY(-1px);
}

.global-sms-modal .btn-pay:disabled {
    opacity: 0.6;
    cursor: not-allowed;
}

.global-sms-modal .btn-secondary {
    background: #f1f5f9;
    color: #475569;
    border: none;
}

.global-sms-modal .btn-secondary:hover {
    background: #e2e8f0;
}

@media (max-width: 576px) {
    .global-sms-modal .modal-dialog {
        margin: 0.5rem;
        max-width: 100%;
    }
}