/* CF7 в .elizar-cf7 — стили один-в-один с оригинальной Tilda-формой блока «Спросить котика».
   Tokens из data-field-* атрибутов оригинала: input bg #ffffff, border #c2c2c2 1px, radius 30,
   height 50 (40 на 320), font 16/600/#70706b, placeholder #70706b 14/400, button bg #00668c
   (hover #408ca9), color #fff, radius 30, width 260/40, font 14/600 + headline-font. */

.elizar-cf7 .wpcf7 {
    color: inherit;
}

.elizar-cf7 .wpcf7-form {
    margin: 0;
    padding: 0;
}

.elizar-cf7 .wpcf7-form p {
    margin: 0;
    padding: 0;
}

.elizar-cf7 .elizar-cf7-row {
    margin-bottom: 20px;
}

.elizar-cf7 .elizar-cf7-row .wpcf7-form-control-wrap {
    display: block;
    width: 100%;
}

/* Input / email — общий стиль */
.elizar-cf7 input[type="text"],
.elizar-cf7 input[type="email"] {
    width: 100%;
    height: 50px;
    padding: 0 20px;
    box-sizing: border-box;
    background-color: #ffffff;
    border: 1px solid #c2c2c2;
    border-radius: 30px;
    font-family: var(--t-text-font, Arial);
    font-size: 16px;
    font-weight: 600;
    color: #70706b;
    line-height: 1.55;
    outline: none;
    appearance: none;
    -webkit-appearance: none;
    transition: border-color .2s ease-in-out;
}

.elizar-cf7 input[type="text"]:focus,
.elizar-cf7 input[type="email"]:focus {
    border-color: #70706b;
}

/* Placeholder в Tilda — это псевдо-label .t-input__vis-ph: тот же шрифт что input, opacity .5. */
.elizar-cf7 input::placeholder {
    color: #70706b;
    font-size: 16px;
    font-weight: 600;
    opacity: 0.5;
}

/* Acceptance (privacy checkbox) — кастомный индикатор как в Tilda (.t-checkbox__indicator):
   20×20 box, border 2px, opacity .6 → 1 при checked, checkmark через ::after. */
.elizar-cf7 .elizar-cf7-row--acceptance {
    margin-bottom: 20px;
}

.elizar-cf7 .wpcf7-list-item {
    margin: 0;
    display: block;
}

.elizar-cf7 .wpcf7-list-item label {
    display: inline-block;
    cursor: pointer;
}

/* Скрываем нативный checkbox, оставляя его кликабельным/доступным */
.elizar-cf7 .wpcf7-list-item input[type="checkbox"] {
    opacity: 0;
    position: absolute;
    z-index: -1;
    pointer-events: none;
    width: 0;
    height: 0;
    margin: 0;
}

.elizar-cf7 .wpcf7-list-item-label {
    color: #70706b;
    font-size: 14px;
    font-weight: 400;
    position: relative;
    display: inline-block;
    padding-left: 30px;
    min-height: 20px;
}

/* Box-индикатор — вертикально центрирован относительно лейбла (top:50%/translateY) */
.elizar-cf7 .wpcf7-list-item-label::before {
    content: '';
    position: absolute;
    left: 0;
    top: 50%;
    transform: translateY(-50%);
    width: 20px;
    height: 20px;
    box-sizing: border-box;
    border: 2px solid #70706b;
    background: transparent;
    opacity: 0.6;
    transition: opacity .2s;
}

/* Галочка — позиционируется относительно центра лейбла; смещение -8px компенсирует
   оригинальный Tilda-offset top:2 внутри 20px-box (центр галочки 4px выше центра box). */
.elizar-cf7 .wpcf7-list-item-label::after {
    content: '';
    position: absolute;
    left: 8px;
    top: 50%;
    margin-top: -6px;
    width: 3px;
    height: 8px;
    box-sizing: content-box;
    border: solid #70706b;
    border-width: 0 2px 2px 0;
    transform: rotate(45deg);
    display: none;
}

.elizar-cf7 .wpcf7-list-item input[type="checkbox"]:checked+.wpcf7-list-item-label::before {
    opacity: 1;
}

.elizar-cf7 .wpcf7-list-item input[type="checkbox"]:checked+.wpcf7-list-item-label::after {
    display: block;
}

/* #allrecords для специфичности — на сайте есть #allrecords a, иначе перекрывает наш цвет. */
#allrecords .elizar-cf7 .wpcf7-list-item-label a,
.elizar-cf7 .wpcf7-list-item-label a {
    color: #70706b;
    text-decoration: none;
    border-bottom: 1px solid #70706b;
    box-shadow: none;
}

/* Submit button */
.elizar-cf7 .elizar-cf7-row--submit {
    text-align: center;
    margin-bottom: 0;
}

.elizar-cf7 input[type="submit"] {
    display: block;
    margin-left: auto;
    margin-right: auto;
    width: 260px;
    height: 40px;
    background-color: #00668c;
    color: #ffffff;
    border: none;
    border-radius: 30px;
    font-family: var(--t-headline-font, Arial);
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    appearance: none;
    -webkit-appearance: none;
    transition: background-color .2s ease-in-out;
}

.elizar-cf7 input[type="submit"]:hover {
    background-color: #408ca9;
}

.elizar-cf7 input[type="submit"]:disabled {
    opacity: .6;
    cursor: not-allowed;
}

/* CF7 service messages — appear below form */
.elizar-cf7 .wpcf7-response-output {
    margin: 16px 0 0;
    padding: 10px 14px;
    border-radius: 8px;
    font-size: 14px;
    color: #70706b;
}

.elizar-cf7 .wpcf7 form.invalid .wpcf7-response-output,
.elizar-cf7 .wpcf7 form.unaccepted .wpcf7-response-output {
    border-color: #de67a4;
    color: #de67a4;
}

.elizar-cf7 .wpcf7 form.sent .wpcf7-response-output {
    border-color: #7db031;
    color: #7db031;
}

/* Inline field errors */
.elizar-cf7 .wpcf7-not-valid-tip {
    color: #de67a4;
    font-size: 13px;
    margin-top: 4px;
    padding-left: 22px;
}

/* Mobile (matches Tilda data-field-*-res-320 tokens) */
@media (max-width: 640px) {

    .elizar-cf7 input[type="text"],
    .elizar-cf7 input[type="email"] {
        height: 40px;
        font-size: 14px;
    }

    .elizar-cf7 input::placeholder {
        font-size: 14px;
    }

    .elizar-cf7 .elizar-cf7-row {
        margin-bottom: 10px;
    }

    .elizar-cf7 input[type="submit"] {
        width: 260px;
        height: 40px;
        font-size: 14px;
    }
}

@media (min-width: 641px) and (max-width: 960px) {
    .elizar-cf7 input[type="submit"] {
        width: 400px;
        height: 63px;
        font-size: 24px;
    }
}
/* Footer nav menu — место Tilda-ссылок 003-007 в футере главной. */
.elizar-footer-menu ul {
    list-style: none;
    margin: 0;
    padding: 0;
    display: flex;
    flex-direction: column;
    gap: 20px;
}
.elizar-footer-menu li { margin: 0; padding: 0; }
.elizar-footer-menu a {
    color: inherit;
    text-decoration: none;
    font-size: 14px;
}
@media (max-width: 640px) {
    .elizar-footer-menu a { font-size: 12px; }
    .elizar-footer-menu ul { gap: 17px; }
}
