/* Стиль для загального контейнера рядків форми */
.row {
    display: flex;
    flex-direction: column;
    margin-bottom: 15px;
}

/* Стиль для лейблів */
.row-label {
    font-size: 1rem;
    font-weight: bold;
    margin-bottom: 5px;
    color: #495057;
}

/* Поля вводу */
.form-control, .form-select {
    width: 100%;
    padding: 10px;
    font-size: 1rem;
    color: #495057;
    background-color: #fff;
    border: 1px solid #ced4da;
    border-radius: 4px;
    transition: border-color 0.3s ease, box-shadow 0.3s ease;
}

.form-control:focus, .form-select:focus {
    border-color: #007bff;
    box-shadow: 0 0 0 0.2rem rgba(0, 123, 255, 0.25);
    outline: none;
}

/* Стиль для текстових полів */
textarea.form-control {
    resize: none;
}

/* Стиль для fieldset */
fieldset {
    border: none; /* Прибираємо рамки у fieldset */
    padding: 0;
    margin: 0;
    margin-bottom: 15px; /* Відступ між fieldset */
}

/* Стиль для легенди */
legend {
    font-size: 1.1rem;
    font-weight: bold;
    color: #495057;
    margin-bottom: 10px;
}

/* Стиль для радіокнопок і чекбоксів */
.form-check-input {
    margin-right: 10px;
}

.form-check-label {
    font-size: 1rem;
    color: #495057;
    margin-left: 5px;
}

/* Вирівнювання для радіокнопок і чекбоксів */
.form-control-radio, .form-control-checkbox {
    display: flex;
    align-items: center;
    margin-bottom: 10px;
}

/* Стиль для інпутів типу файл */
input[type="file"] {
    padding: 5px;
}

/* Лейбли при наведенні */
.row-label:hover {
    color: #007bff;
}

/* Адаптивний дизайн */
@media (max-width: 768px),
       (max-width: 820px),
       (max-width: 864px),
       (max-width: 960px),
       (max-width: 1152px) {
    .row {
        flex-direction: row;
        align-items: center;
    }

    .row-label {
        width: 150px;
        margin-right: 10px;
        margin-bottom: 0;
    }

    .form-control,
    .form-select,
    .form-check {
        flex: 1;
    }
}

/* Контейнер для світча */
.form-control-switch {
    display: flex;
    align-items: center;
}

/* Стилізація для самого перемикача (чекбокса) */
.switch-input {
    position: relative;
    width: 40px;
    height: 20px;
    -webkit-appearance: none;
    background-color: #ced4da;
    border-radius: 20px;
    outline: none;
    cursor: pointer;
    transition: background-color 0.3s ease;
}

/* Коли перемикач активний */
.switch-input:checked {
    background-color: #007bff;
}

/* Стилізація для "кола" всередині перемикача */
.switch-input::before {
    content: "";
    position: absolute;
    top: 3px;
    left: 3px;
    width: 14px;
    height: 14px;
    background-color: #fff;
    border-radius: 50%;
    transition: transform 0.3s ease;
}

/* Переміщення кола вправо при активації перемикача */
.switch-input:checked::before {
    transform: translateX(20px);
}

/* Стиль для лейбла біля перемикача */
.switch-label {
    margin-left: 10px;
    font-size: 1rem;
    color: #495057;
}

/* Загальний контейнер для колонок */
.column {
    display: flex;
    flex-direction: column; /* Вертикальне розміщення всіх елементів */
    gap: 20px; /* Відступ між елементами */
    margin-bottom: 20px;
}

/* Стиль для повзунків */
.form-range {
    width: 100%;
    appearance: none; /* Прибираємо стандартний вигляд повзунка */
    height: 5px; /* Висота лінії повзунка */
    background-color: #ced4da; /* Колір лінії повзунка */
    border-radius: 5px; /* Заокруглення країв лінії */
    outline: none;
    transition: background-color 0.3s ease;
}

/* Стиль для ручки повзунка */
.form-range::-webkit-slider-thumb {
    appearance: none;
    width: 15px;
    height: 15px;
    background-color: #007bff; /* Колір ручки повзунка */
    border-radius: 50%; /* Ручка кругла */
    cursor: pointer;
    transition: background-color 0.3s ease;
}

.form-range::-moz-range-thumb {
    width: 15px;
    height: 15px;
    background-color: #007bff;
    border-radius: 50%;
    cursor: pointer;
    transition: background-color 0.3s ease;
}

/* При наведенні на ручку повзунка */
.form-range:hover::-webkit-slider-thumb {
    background-color: #0056b3;
}

.form-range:hover::-moz-range-thumb {
    background-color: #0056b3;
}

/* Стиль для лейблів */
.form-label {
    font-size: 1rem;
    font-weight: bold;
    color: #495057;
    margin-bottom: 5px; /* Відступ між лейблом і повзунком */
}

/* Стиль для контейнера кожного повзунка */
.range {
    display: flex;
    flex-direction: column; /* Вертикальне розміщення лейбла та повзунка */
}

.form-group {
    margin-bottom: 15px;
}

.form-label {
    display: block;
    font-weight: bold;
    margin-bottom: 5px;
}

.form-control {
    width: 100%;
    padding: 10px;
    font-size: 16px;
    border: 1px solid #ced4da;
    border-radius: 4px;
    box-sizing: border-box;
}

.form-control:focus {
    outline: none;
    border-color: #80bdff;
    box-shadow: 0 0 5px rgba(0, 123, 255, 0.25);
}

.fields-row {
    display: flex;
    gap: 15px;
}

.fields-row .form-group {
    flex: 1;
}