/* Общие стили попапа */
.form.popup {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 1000;
    display: none;
}

.popup-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.7);
    backdrop-filter: blur(3px);
}

.popup-container {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 90%;
    max-width: 500px;
    background: #fff;
    border-radius: 0; /* Убрано закругление */
    box-shadow: 0 20px 40px rgba(0,0,0,0.2);
    animation: popupFadeIn 0.3s ease;
}

@keyframes popupFadeIn {
    from {
        opacity: 0;
        transform: translate(-50%, -45%);
    }
    to {
        opacity: 1;
        transform: translate(-50%, -50%);
    }
}

.popup-content {
    padding: 25px;
}

/* Хедер формы – зелёный фон, белый текст */
.form-header {
    position: relative;
    text-align: center;
    margin-bottom: 25px;
    padding: 20px 30px 20px 30px;
    background: #4CAF50;
    margin: -25px -25px 25px -25px; /* чтобы фон уходил за padding попапа */
    border-radius: 0;
}

.form-header i {
    font-size: 48px;
    color: #fff;
    margin-bottom: 15px;
    display: inline-block;
}

.form-header .title {
    font-size: 24px;
    font-weight: 600;
    color: #fff;
    margin-bottom: 8px;
}

.form-header p {
    font-size: 14px;
    color: #fff; /* Белый текст */
    line-height: 1.4;
}

.popup-close {
    position: absolute;
    top: 15px;
    right: 15px;
    background: none;
    border: none;
    font-size: 28px;
    cursor: pointer;
    color: #fff;
    transition: color 0.2s;
    width: 32px;
    height: 32px;
    line-height: 1;
    padding: 0;
}

.popup-close:hover {
    color: #ddd;
}

/* Тело формы */
.form-body {
    margin-bottom: 20px;
}

.row {
    margin-bottom: 18px;
}

.form-group label {
    display: block;
    margin-bottom: 6px;
    font-weight: 500;
    color: #333;
}

.star {
    color: #e74c3c;
    margin-left: 4px; /* увеличен отступ от текста */
}

.input {
    position: relative;
}

.input input,
.input textarea,
.input select {
    width: 100%;
    padding: 12px 15px;
    border: 1px solid #ddd;
    border-radius: 0; /* убрано закругление */
    font-size: 14px;
    transition: all 0.2s;
    box-sizing: border-box;
}

.input input:focus {
    border-color: #4CAF50;
    outline: none;
    box-shadow: 0 0 0 2px rgba(76, 175, 80, 0.2);
}

.input.error input {
    border-color: #e74c3c;
    background: #fff5f5;
}

/* Чекбокс обработки */
.processing-block {
    margin-top: 15px;
}

.processing-block .input {
    display: flex;
    align-items: center;
    gap: 10px;
}

.processing-block input[type="checkbox"] {
    width: 18px;
    height: 18px;
    margin: 0;
    cursor: pointer;
}

.processing-block label {
    margin: 0;
    font-size: 13px;
    color: #555;
    cursor: pointer;
    font-weight: normal;
}

/* Футер формы */
.form-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 15px;
    border-top: 1px solid #eee;
    padding-top: 20px;
}

.required-fileds {
    font-size: 12px;
    color: #888;
}

.btn {
    display: inline-block;
    padding: 12px 25px;
    border-radius: 0; /* убрано закругление */
    font-weight: 600;
    text-align: center;
    cursor: pointer;
    transition: 0.2s;
    border: none;
    font-size: 14px;
}

.btn-green {
    background: #4CAF50;
    color: #fff;
    box-shadow: 0 2px 6px rgba(76, 175, 80, 0.3);
}

.btn-green:hover {
    background: #45a049;
    transform: translateY(-2px);
}

.btn-lg {
    padding: 12px 30px;
    font-size: 16px;
}

/* Кнопка открытия попапа (оставлена без закруглений) */
.callback-open-btn.btn-green {
    font-weight: 400;
    width: 100%;
    font-size: 12px;
    line-height: 17.16px;
    letter-spacing: 0.36px;
    text-align: center;
    text-transform: uppercase;
    padding: 6px 16px 7px 16px;
    border-radius: 15px;
    color: #5BAA00;
    border: 2px solid #5BAA00;
    background: transparent;
    cursor: pointer;
    transition: all 0.2s ease;
    box-shadow: unset;
}

/* .callback-open-btn.btn-green:hover {
    background: #5BAA00;
    color: #fff;
} */

/* Попап успеха */
.form.popup.success .form-header i {
    color: #fff;
}

.form.popup.success .form-footer {
    border-top: none;
    justify-content: center;
}

/* Убираем скролл у body при открытом попапе */
body.no-scroll {
    overflow: hidden;
    padding-right: 15px;
}

/* Адаптивность */
@media (max-width: 600px) {
    .popup-content {
        padding: 20px;
    }
    .form-header {
        margin: -20px -20px 20px -20px;
    }
    .form-header .title {
        font-size: 20px;
    }
    .form-footer {
        flex-direction: column;
    }
    .btn-lg {
        width: 100%;
    }
}