/* =========================================
   1. СБРОС И БАЗОВЫЕ НАСТРОЙКИ
   ========================================= */
* {
    box-sizing: border-box;
    -webkit-tap-highlight-color: transparent;
}

body {
    margin: 0;
    padding: 0;
    font-family: 'Montserrat', sans-serif;
    background-color: #f0f2f5; 
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 100vh;
    color: #333;
}

/* =========================================
   2. КОНТЕЙНЕР
   ========================================= */
.container {
    background-color: #fff;
    width: 100%;
    max-width: 420px;
    min-height: 100vh;
    padding: 25px 20px;
    position: relative;
    display: flex;
    flex-direction: column;
    align-items: center;
    box-shadow: 0 20px 40px rgba(0,0,0,0.1); 
    border-radius: 25px;
    margin: 20px auto;
}

/* =========================================
   3. ШАПКА
   ========================================= */
.header {
    margin-bottom: 15px;
    width: 100%;
    display: flex;
    justify-content: center;
}

.logo {
    width: 65px;
    height: auto;
    display: block;
}

/* =========================================
   4. ТЕКСТЫ
   ========================================= */
.content {
    width: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
    padding-bottom: 40px; /* Доп. место внизу контента */
}

h1 {
    color: #d6001c;
    text-align: center;
    font-size: 24px; 
    line-height: 1.2;
    margin: 10px 0 20px 0;
    font-weight: 800;
    letter-spacing: -0.5px;
}

.highlight {
    background-color: #ffcc00;
    color: #000;
    padding: 4px 10px;
    border-radius: 4px;
    display: inline-block;
    transform: rotate(-1.5deg); 
    box-shadow: 2px 3px 0 rgba(0,0,0,0.08);
}

.subtext {
    text-align: center;
    font-size: 15px;
    color: #4a4a4a;
    margin-bottom: 25px;
    line-height: 1.5;
    font-weight: 500;
}

/* =========================================
   5. ВАУЧЕР
   ========================================= */
.voucher-img-placeholder {
    width: 100%;
    display: flex;
    justify-content: center;
    margin-bottom: 25px;
}

.voucher-card {
    background: #fff;
    border: 1px solid #eee;
    box-shadow: 0 10px 20px rgba(0,0,0,0.08);
    border-radius: 12px;
    width: 280px;
    height: 130px;
    display: flex;
    overflow: hidden;
    position: relative;
    transform: rotate(-2deg); 
    transition: transform 0.3s ease;
}

.voucher-card:hover {
    transform: rotate(0deg) scale(1.02);
}

.v-left { 
    flex: 2; 
    display: flex; 
    align-items: center; 
    justify-content: center; 
    flex-direction: column; 
    background: #fff;
    border-right: 2px dashed #ddd;
}

.v-right { 
    flex: 1; 
    background: linear-gradient(135deg, #d6001c, #b30017); 
    color: white; 
    display: flex; 
    align-items: center; 
    justify-content: center; 
    flex-direction: column; 
    font-weight: 800; 
    font-size: 26px;
    line-height: 1;
}
.v-right small { font-size: 12px; font-weight: 500; opacity: 0.9; }

/* =========================================
   6. ФОРМА
   ========================================= */
.lead-form {
    width: 100%;
    padding: 10px;
}

.input-row {
    display: flex;
    gap: 12px;
    margin-bottom: 15px;
}

.input-wrapper {
    width: 100%;
    position: relative;
}

input[type="text"],
input[type="tel"],
input[type="email"] {
    width: 100%;
    padding: 15px;
    border: 2px solid #e1e4e8;
    border-radius: 10px;
    font-size: 16px;
    font-family: 'Montserrat', sans-serif;
    font-weight: 500;
    outline: none;
    transition: all 0.2s;
    background: #f9f9f9;
    color: #333;
}

input:focus {
    border-color: #ffcc00;
    background: #fff;
    box-shadow: 0 0 0 4px rgba(255, 204, 0, 0.15);
}

.error-msg {
    display: none;
    color: #d6001c;
    font-size: 12px;
    font-weight: 700;
    position: absolute;
    bottom: -18px;
    left: 4px;
}

/* =========================================
   7. РАДИО КНОПКИ
   ========================================= */
.radio-group {
    display: flex;
    justify-content: space-between;
    gap: 10px;
    margin: 20px 0 30px 0; /* Большой отступ снизу до кнопки */
}

.radio-container {
    flex: 1;
    text-align: center;
    padding: 12px;
    cursor: pointer;
    font-size: 14px;
    font-weight: 600;
    border-radius: 10px;
    transition: 0.2s;
    position: relative;
    user-select: none;
    background-color: #f0f2f5;
    color: #666;
    border: 2px solid transparent;
}

.radio-container input {
    display: none;
}

.radio-container.active-radio {
    background-color: #fff;
    color: #000;
    border-color: #ffcc00;
    box-shadow: 0 4px 10px rgba(0,0,0,0.05);
}

/* =========================================
   8. КНОПКА (ВАЖНО!)
   ========================================= */
button {
    width: 100%;
    padding: 18px;
    border: none;
    border-radius: 10px;
    font-size: 18px;
    font-weight: 800;
    font-family: 'Montserrat', sans-serif;
    cursor: pointer;
    transition: 0.3s;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    box-shadow: 0 4px 6px rgba(0,0,0,0.1);
    
    /* ГАРАНТИЯ ОБЫЧНОГО ПОВЕДЕНИЯ */
    position: relative !important; 
    margin-top: 20px !important;
    bottom: auto !important;
    left: auto !important;
}

button:disabled {
    background-color: #e0e0e0;
    color: #999;
    cursor: not-allowed;
    box-shadow: none;
}

button.active {
    background-color: #d6001c;
    color: white;
    box-shadow: 0 8px 25px rgba(214, 0, 28, 0.3);
    transform: translateY(-2px);
}

button.active:active {
    transform: translateY(0);
}

/* =========================================
   9. QR СТРАНИЦА
   ========================================= */
.success-container {
    text-align: center;
    background-color: #fff;
}

.success-title {
    color: #d6001c;
    font-size: 26px;
    font-weight: 800;
    margin: 20px 0 30px 0;
}

.qr-wrapper {
    background: white;
    padding: 15px;
    border: 4px solid #ffcc00;
    border-radius: 20px;
    display: inline-block;
    margin-bottom: 30px;
    box-shadow: 0 10px 40px rgba(0,0,0,0.1);
}

.qr-code {
    width: 100%;
    max-width: 220px;
    height: auto;
    display: block;
}

.instruction {
    font-size: 16px;
    line-height: 1.6;
    color: #333;
    max-width: 320px;
    margin: 0 auto;
    background: #f9f9f9;
    padding: 20px;
    border-radius: 12px;
    font-weight: 600;
}

/* =========================================
   10. МОБИЛЬНАЯ АДАПТАЦИЯ
   ========================================= */
@media screen and (max-width: 480px) {
    body {
        background-color: #fff;
        align-items: flex-start;
    }

    .container {
        margin: 0;
        border-radius: 0;
        box-shadow: none;
        max-width: 100%;
        min-height: 100vh;
        padding: 20px 15px 50px 15px; /* Добавил отступ 50px снизу всего сайта */
    }

    h1 {
        font-size: 22px; 
        margin-bottom: 15px;
    }

    .voucher-card {
        width: 100%; 
        max-width: 340px;
    }

    .input-row {
        flex-direction: column;
        gap: 15px;
        margin-bottom: 15px;
    }
    
    /* СТРОГИЙ СБРОС ДЛЯ КНОПКИ НА ТЕЛЕФОНЕ */
    button {
        position: static !important; /* Убирает прилипание */
        margin-top: 40px !important; /* Отступ сверху */
        transform: none !important;
        width: 100% !important;
    }
}