/* ============================================================
   Форма заказа: цена, кнопка, альтернативные каналы связи.
   Подключается после инлайновых стилей forma.html.
   ============================================================ */

/* Карточка формы была с фиксированной высотой 540px — новый блок «задать
   вопрос» вылезал за её пределы. Высота теперь по содержимому. */
.form-container {
    height: auto !important;
    min-height: 540px;
    padding: 24px !important;
}

/* ---------- Цена видна до заполнения формы ---------- */
.price-box {
    display: flex;
    flex-wrap: wrap;
    align-items: baseline;
    justify-content: space-between;
    gap: 8px;
    margin: 0 0 18px;
    padding: 14px 16px;
    border: 1px solid #d7e3f4;
    border-radius: 10px;
    background: #f3f8ff;
}

.price-box__rate { font-size: 15px; color: #445; }
.price-box__rate b { font-size: 20px; color: #0c5adb; }
.price-box__total { font-size: 17px; color: #04000b; white-space: nowrap; }
.price-box__total b { color: #0c5adb; }

/* ---------- Кнопка отправки: активна всегда ---------- */
#orderForm button[type="submit"] {
    display: block;
    width: 100%;
    height: 54px;
    margin-top: 6px;
    border: none;
    border-radius: 10px;
    background: #0c5adb;
    color: #fff;
    font-size: 18px;
    font-weight: 700;
    font-family: inherit;
    cursor: pointer;
    transition: background .2s ease, transform .2s ease;
}

#orderForm button[type="submit"]:hover { background: #0a4cba; transform: translateY(-2px); }
#orderForm button[type="submit"]:disabled { background: #7fa5e6; cursor: wait; transform: none; }

.order-note {
    margin: 10px 0 0;
    font-size: 13px;
    line-height: 1.5;
    color: #6b7280;
    text-align: center;
}

/* ---------- «Задать вопрос» рядом с заказом ---------- */
.order-ask {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: center;
    gap: 10px;
    margin-top: 16px;
    padding-top: 16px;
    border-top: 1px solid #e6e6e6;
    font-size: 14px;
    color: #6b7280;
}

.order-ask a {
    display: inline-flex;
    align-items: center;
    padding: 9px 16px;
    border-radius: 22px;
    font-weight: 600;
    text-decoration: none;
    transition: transform .2s ease, box-shadow .2s ease;
}

.order-ask a:hover { transform: translateY(-2px); box-shadow: 0 4px 12px rgba(0, 0, 0, .12); }
.order-ask__tg { background: #229ED9; color: #fff !important; }
.order-ask__mail { background: #fff; color: #0c5adb !important; border: 2px solid rgba(12, 90, 219, .25); }

/* ---------- Подтверждение заявки ---------- */
.success {
    display: none;
    margin-top: 4px;
    padding: 22px 20px;
    border: 1px solid #b7e2c4;
    border-radius: 12px;
    background: #f2fbf5;
    color: #14532d !important;
    font-size: 15px !important;
    line-height: 1.6;
    text-align: left;
}

.success h3 { margin: 0 0 10px; font-size: 20px; color: #14532d; }
.success p { margin: 0 0 10px; color: #14532d; }
.success p:last-child { margin-bottom: 0; }
.success a { color: #0c5adb; font-weight: 600; }

/* ---------- Мобильная вёрстка ---------- */
@media (max-width: 768px) {
    /* картинка занимала весь первый экран и отодвигала форму — меняем местами */
    .container { flex-direction: column-reverse !important; }
    .image-container { margin-top: 20px; }
    .form-container { margin-top: 0 !important; }
}

@media (max-width: 767px) {
    .price-box { flex-direction: column; align-items: flex-start; }
    .order-ask { flex-direction: column; align-items: stretch; text-align: center; }
    .order-ask a { justify-content: center; }
    /* плавающая кнопка Telegram не должна лежать на полях формы */
    .tg-float { bottom: 20px; right: 12px; }
}
