/* Улучшенное оформление модального окна заявки и модалки успешной отправки */

/* Затемнение фона с лёгким блюром */
.modal-backdrop.show {
    background-color: rgba(20, 20, 20, 0.55);
    backdrop-filter: blur(3px);
}

/* Плавное появление окна (масштаб + сдвиг вместо стандартного bootstrap-сдвига) */
.become-customer-modal.fade .modal-dialog,
.successfulRequest-modal.fade .modal-dialog {
    transform: scale(0.92) translateY(24px);
    transition: transform 0.3s ease, opacity 0.3s ease;
}
.become-customer-modal.show .modal-dialog,
.successfulRequest-modal.show .modal-dialog {
    transform: scale(1) translateY(0);
}

/* Карточка модалки */
.modal-content {
    border: none;
    border-radius: 24px;
    box-shadow: 0 30px 80px rgba(0, 0, 0, 0.18);
    overflow: hidden;
}
.modal-content::before {
    content: "";
    display: block;
    height: 6px;
    background: linear-gradient(90deg, var(--green) 0%, #0d6efd 100%);
}
.modal-content .btn-close {
    top: 20px;
    right: 20px;
    width: 36px;
    height: 36px;
    background-color: #f1f3f5;
    background-size: 12px;
    border-radius: 50%;
    opacity: 1;
    transition: background-color 0.2s ease;
}
.modal-content .btn-close:hover {
    background-color: #e9ecef;
}

/* Окно заявки */
.become-customer-modal .modal-dialog {
    max-width: 560px;
}
.become-customer-modal .modal-content {
    padding: 0;
}
.become-customer-modal .modal-header {
    flex-direction: column;
    align-items: center;
    text-align: center;
    padding: 44px 40px 8px;
}
.become-customer-modal .modal-title {
    font-size: 2.8rem;
}
.become-customer-modal .modal-title::before {
    content: "💬";
    display: block;
    font-size: 3.6rem;
    margin-bottom: 14px;
}
.become-customer-modal .modal-title::after {
    content: "Ответим в течение рабочего дня";
    display: block;
    font-weight: 400;
    font-size: 1.5rem;
    line-height: 2rem;
    color: #6c757d;
    margin-top: 10px;
}
.become-customer-modal .modal-body {
    padding: 10px 40px 40px;
}

/* Поля формы */
.modal-body .form-control {
    border: 1.5px solid #e9ecef;
    border-radius: 12px;
    padding: 1.2rem 1.4rem 1.2rem 4.6rem;
    font-size: 1.6rem;
    background-color: #f8f9fa;
    background-repeat: no-repeat;
    background-position: 1.5rem center;
    background-size: 20px 20px;
    transition: border-color 0.2s ease, background-color 0.2s ease, box-shadow 0.2s ease;
}
.modal-body .form-control:focus {
    border-color: var(--green);
    background-color: #ffffff;
    box-shadow: 0 0 0 4px rgba(132, 189, 0, 0.14);
}
.modal-body textarea.form-control {
    padding-top: 1.4rem;
    background-position: 1.5rem 1.6rem;
    min-height: 120px;
    border-bottom: 1.5px solid #e9ecef;
}

.modal-body input[name="name"] {
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23adb5bd' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M20 21v-2a4 4 0 0 0-4-4H8a4 4 0 0 0-4 4v2'/%3E%3Ccircle cx='12' cy='7' r='4'/%3E%3C/svg%3E");
}
.modal-body input[name="company"] {
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23adb5bd' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Crect x='2' y='8' width='20' height='13' rx='2'/%3E%3Cpath d='M8 8V6a2 2 0 0 1 2-2h4a2 2 0 0 1 2 2v2'/%3E%3C/svg%3E");
}
.modal-body input[name="phone"] {
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23adb5bd' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M6.6 10.8c1.4 2.8 3.8 5.1 6.6 6.6l2.2-2.2c.3-.3.7-.4 1-.2 1.1.4 2.3.6 3.6.6.6 0 1 .4 1 1V20c0 .6-.4 1-1 1C11.6 21 3 12.4 3 2c0-.6.4-1 1-1h3.4c.6 0 1 .4 1 1 0 1.3.2 2.5.6 3.6.1.4 0 .8-.2 1L6.6 10.8z'/%3E%3C/svg%3E");
}
.modal-body input[name="email"] {
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23adb5bd' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Crect x='3' y='5' width='18' height='14' rx='2'/%3E%3Cpath d='M3 7l9 6 9-6'/%3E%3C/svg%3E");
}
.modal-body textarea[name="description"] {
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23adb5bd' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M4 4h16a2 2 0 0 1 2 2v9a2 2 0 0 1-2 2H8l-4 4V6a2 2 0 0 1 2-2z'/%3E%3C/svg%3E");
}

/* Согласие на обработку данных */
.become-customer-modal .form-check {
    display: grid;
    grid-template-columns: auto 1fr;
    column-gap: 10px;
    row-gap: 0.6rem;
    align-items: start;
    background: #f8f9fa;
    border-radius: 12px;
    padding: 1.4rem 1.6rem;
}
.become-customer-modal .form-check-input {
    grid-column: 1;
    grid-row: 1;
    width: 1.8rem;
    height: 1.8rem;
    margin: 0.2rem 0 0;
    float: none;
}
.become-customer-modal .form-check-label {
    grid-column: 2;
    grid-row: 1;
}
.become-customer-modal .form-check .invalid-feedback {
    grid-column: 1 / -1;
    grid-row: 2;
    margin: 0;
}
.become-customer-modal .form-check-label {
    font-size: 1.4rem;
    line-height: 1.9rem;
    color: #495057;
}
.become-customer-modal .form-check-input:checked {
    background-color: #0d6efd;
    border-color: #0d6efd;
}
.become-customer-modal .form-check-label a {
    color: #0d6efd;
    text-decoration: underline;
}

/* Кнопка отправки */
.become-customer-modal .modal-form button[type="submit"] {
    border-radius: 999px;
    padding: 1.4rem 2rem;
    font-weight: 600;
    letter-spacing: 0.03rem;
    box-shadow: 0 12px 24px rgba(132, 189, 0, 0.35);
    transition: transform 0.2s ease, box-shadow 0.2s ease, opacity 0.2s ease;
}
.become-customer-modal .modal-form button[type="submit"]:hover:not(:disabled) {
    transform: translateY(-2px);
    box-shadow: 0 16px 30px rgba(132, 189, 0, 0.45);
}
.become-customer-modal .modal-form button[type="submit"]:disabled {
    opacity: 0.5;
    box-shadow: none;
    cursor: not-allowed;
}

.become-customer-modal .modal-form_info p {
    text-align: center;
    color: #adb5bd;
    font-size: 1.3rem;
}

/* Модалка успешной отправки */
.successfulRequest-modal-content {
    padding: 60px 40px 70px;
}

@media (max-width: 576px) {
    .become-customer-modal .modal-header {
        padding: 36px 24px 8px;
    }
    .become-customer-modal .modal-body {
        padding: 10px 24px 32px;
    }
}
