/* ============================================================
   Smilora — модалка акцій (ім'я + телефон)
   ============================================================ */

.promo-modal {
    position: fixed;
    inset: 0;
    z-index: 10050;
    display: flex;
    align-items: stretch;
    justify-content: flex-end;
    visibility: hidden;
    pointer-events: none;
}

.promo-modal.promo-modal--visible {
    visibility: visible;
}

.promo-modal.is-open {
    pointer-events: auto;
}

.promo-modal__backdrop {
    position: absolute;
    inset: 0;
    background: rgba(6, 11, 44, 0.72);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    opacity: 0;
    transition: opacity 0.4s ease;
    cursor: pointer;
}

.promo-modal.is-open .promo-modal__backdrop {
    opacity: 1;
}

.promo-modal__dialog {
    position: relative;
    z-index: 1;
    width: min(560px, 100%);
    height: 100%;
    max-height: 100dvh;
    transform: translate3d(105%, 0, 0);
    transition: transform 0.48s cubic-bezier(0.22, 1, 0.36, 1);
}

.promo-modal.is-open .promo-modal__dialog {
    transform: translate3d(0, 0, 0);
}

.promo-modal__panel {
    position: relative;
    height: 100%;
    overflow: auto;
    background: linear-gradient(180deg, #ffffff 0%, #f1f3fe 100%);
    border-radius: 24px 0 0 24px;
    box-shadow: -18px 0 50px rgba(58, 68, 152, 0.22);
    padding: max(60px, env(safe-area-inset-top, 0px)) 28px max(28px, env(safe-area-inset-bottom, 0px));
}

.promo-modal__close {
    position: absolute;
    top: max(14px, env(safe-area-inset-top, 0px));
    right: 14px;
    z-index: 2;
    width: 44px;
    height: 44px;
    border: none;
    border-radius: 12px;
    background: rgba(58, 68, 152, 0.08);
    color: var(--primary--color);
    font-size: 18px;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    transition: background-color 0.2s ease, color 0.2s ease;
}

.promo-modal__close:hover {
    background: var(--primary--color);
    color: #fff;
}

.promo-modal__badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 72px;
    margin-bottom: 16px;
    padding: 7px 14px;
    border-radius: 999px;
    background: var(--lavender--color2);
    color: var(--primary--color);
    font-size: 13px;
    font-weight: 700;
    letter-spacing: 0.3px;
}

.promo-modal__title {
    margin: 0 0 12px;
    font-size: clamp(24px, 3vw, 32px);
    line-height: 1.25;
    font-weight: 700;
    color: var(--black--family--color2);
}

.promo-modal__lead {
    margin: 0 0 24px;
    font-size: 16px;
    line-height: 26px;
    color: var(--text--color);
}

.promo-modal__section-title {
    margin: 0 0 14px;
    font-size: 14px;
    line-height: 20px;
    font-weight: 700;
    letter-spacing: 0.4px;
    text-transform: uppercase;
    color: var(--primary--color);
}

.promo-modal__field {
    margin-bottom: 16px;
}

.promo-modal__field label {
    display: block;
    margin-bottom: 8px;
    font-size: 14px;
    line-height: 20px;
    font-weight: 600;
    color: var(--black--family--color2);
}

.promo-modal__field input {
    width: 100%;
    height: 52px;
    border: 1px solid var(--border--color);
    border-radius: 14px;
    background: #fff;
    padding: 0 16px;
    font-size: 16px;
    line-height: 24px;
    color: var(--text--color);
    transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.promo-modal__field input:focus {
    outline: none;
    border-color: var(--primary--color);
    box-shadow: 0 0 0 3px rgba(58, 68, 152, 0.12);
}

.promo-modal__field input.is-invalid {
    border-color: #dc3545;
}

.promo-modal__error {
    display: none;
    margin-top: 6px;
    font-size: 13px;
    line-height: 18px;
    color: #dc3545;
}

.promo-modal__field input.is-invalid + .promo-modal__error {
    display: block;
}

.promo-modal__submit {
    width: 100%;
    min-height: 54px;
    margin-top: 8px;
    border: none;
    border-radius: 14px;
    background: var(--primary--color);
    color: #fff;
    font-size: 15px;
    line-height: 22px;
    font-weight: 700;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    transition: background-color 0.25s ease, transform 0.2s ease;
    box-shadow: 0 10px 24px rgba(58, 68, 152, 0.24);
}

.promo-modal__submit:hover {
    background: var(--black--family--color2);
}

.promo-modal__submit:active {
    transform: scale(0.98);
}

.promo-modal__submit i {
    font-size: 14px;
}

.promo-modal__msg {
    margin-top: 14px;
    font-size: 14px;
    line-height: 22px;
}

.promo-modal__msg.is-success {
    color: #198754;
}

.promo-modal__msg.is-error {
    color: #dc3545;
}

.promo-modal__note {
    margin-top: 18px;
    font-size: 13px;
    line-height: 20px;
    color: var(--lavender--color3);
}

body.promo-modal-open {
    overflow: hidden;
}

@media (max-width: 767px) {
    .promo-modal__dialog {
        width: 100%;
    }

    .promo-modal__panel {
        border-radius: 0;
        padding-left: 20px;
        padding-right: 20px;
    }
}

@media (prefers-reduced-motion: reduce) {
    .promo-modal__dialog,
    .promo-modal__backdrop {
        transition: none;
    }
}
