@charset "UTF-8";

/* Раскладка чекбоксов и радио: список, отступы, кликабельная подпись,
   карточный вид (custom_style__radio_cards). */

.custom_style[class] .wpforms-form .wpforms-field-checkbox ul,
.custom_style[class] .wpforms-form .wpforms-field-gdpr-checkbox ul,
.custom_style[class] .wpforms-form .wpforms-field-radio ul {
    display: flex;
    flex-direction: column;
    gap: 10px;
    margin: 0;
    padding: 0;
    list-style: none;
}

.custom_style[class] .wpforms-form .wpforms-field-checkbox ul li,
.custom_style[class] .wpforms-form .wpforms-field-gdpr-checkbox ul li,
.custom_style[class] .wpforms-form .wpforms-field-radio ul li {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    margin: 0;
    padding: 0;
    list-style: none;
}

.custom_style[class] .wpforms-form .wpforms-field-checkbox ul li::before,
.custom_style[class] .wpforms-form .wpforms-field-gdpr-checkbox ul li::before,
.custom_style[class] .wpforms-form .wpforms-field-radio ul li::before {
    display: none;
}

/* Отступы и радиус рамки плагина. Рамку рисует его ::before, поэтому
   правим именно ::before, а не сам input: у input рамки нет. */
.custom_style[class] .wpforms-form .wpforms-field-checkbox input[type="checkbox"],
.custom_style[class] .wpforms-form .wpforms-field-gdpr-checkbox input[type="checkbox"],
.custom_style[class] .wpforms-form .wpforms-field-radio input[type="radio"] {
    flex-shrink: 0;
    /* margin: 2px 0 0 0; */
    cursor: pointer;
}

.custom_style[class] .wpforms-form .wpforms-field-checkbox input[type="checkbox"]::before,
.custom_style[class] .wpforms-form .wpforms-field-gdpr-checkbox input[type="checkbox"]::before {
    border-radius: 5px;
}

/* Галочку рисует ::after у WPForms. Базовые значения:
   top меньше = выше, left меньше = левее. Правь под себя. */
.custom_style[class] .wpforms-form .wpforms-field-checkbox input[type="checkbox"]:checked::after,
.custom_style[class] .wpforms-form .wpforms-field-gdpr-checkbox input[type="checkbox"]:checked::after {
    top: -1px;
    left: -2px;
    transform: translate(0, 1px) scale(0.5) rotate(-45deg);
}

.custom_style[class] .wpforms-form .wpforms-field-checkbox input[type="checkbox"]:focus-visible,
.custom_style[class] .wpforms-form .wpforms-field-gdpr-checkbox input[type="checkbox"]:focus-visible,
.custom_style[class] .wpforms-form .wpforms-field-radio input[type="radio"]:focus-visible {
    outline: none;
    box-shadow: 0 0 0 3px var(--custom_style__focus_ring);
}

.custom_style[class] .wpforms-form .wpforms-field .wpforms-field-label-inline {
    margin: 0;
    padding: 0;
    font-size: 13px;
    font-weight: 500;
    line-height: 1.45;
    color: var(--custom_style__text);
    cursor: pointer;
}

.custom_style[class] .wpforms-form .wpforms-field .wpforms-field-label-inline a {
    color: var(--custom_style__link);
    text-decoration: underline;
    text-underline-offset: 3px;
}

/* Карточный вид радио */
.custom_style[class] .wpforms-form .wpforms-field-radio.custom_style__radio_cards ul {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
}

.custom_style[class] .wpforms-form .wpforms-field-radio.custom_style__radio_cards ul li {
    align-items: center;
    padding: 11px 14px;
    background-color: var(--custom_style__option_bg);
    border: 1px solid var(--custom_style__option_border);
    border-radius: var(--custom_style__radius_control);
    cursor: pointer;
    transition: border-color 0.15s ease, background-color 0.15s ease;
}

.custom_style[class] .wpforms-form .wpforms-field-radio.custom_style__radio_cards ul li:hover {
    background-color: var(--custom_style__option_bg_hover);
    border-color: var(--custom_style__border_hover);
}

.custom_style[class] .wpforms-form .wpforms-field-radio.custom_style__radio_cards ul li:has(input:checked) {
    background-color: var(--custom_style__error_bg);
    border-color: var(--custom_style__accent);
}

.custom_style[class] .wpforms-form .wpforms-field-radio.custom_style__radio_cards input[type="radio"] {
    margin-top: 0;
}