/* Overall form styling */
.form {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
    margin-bottom: 0;
}

.form-row {
    display: flex;
    flex-direction: row;
    align-items: center;
    gap: 0.5rem;
}

.field-label {
    font-size: 1rem;
    font-weight: 500;
    font-style: normal;
    white-space: nowrap;
}

.subtext {
    margin-bottom: 0;
}

.submit-button {
    align-self: flex-start;
}
/* ——————————————————————————————————————————————— */

/* Switch input field */
.form-switch {
  position: relative;
  display: inline-block;
  width: 4rem;
  height: 2rem;
}

.form-switch input {
  opacity: 0;
  width: 0;
  height: 0;
}

.form-slider {
  position: absolute;
  cursor: pointer;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background-color: var(--main-lt-gray-color);
  -webkit-transition: .4s;
  transition: .4s;
  box-shadow: var(--input-box-shadow);
}

.form-slider:before {
  position: absolute;
  content: "";
  height: 1.5rem;
  width: 1.5rem;
  left: 0.25rem;
  bottom: 0.25rem;
  background-color: var(--main-bg-color);
  -webkit-transition: .4s;
  transition: .4s;
}

input:checked + .form-slider {
  background-color: var(--main-accent-color);
}

input:focus + .form-slider {
  box-shadow: 0 0 1px var(--main-accent-color);
}

input:checked + .form-slider:before {
  -webkit-transform: translateX(2rem);
  -ms-transform: translateX(2rem);
  transform: translateX(2rem);
}

.form-slider.form-round {
  border-radius: 2rem;
}

.form-slider.form-round:before {
  border-radius: 50%;
}

/* ——————————————————————————————————————————————— */

/* Text input field */
.text-input {
    padding: 0.25rem 0.5rem;
    border-radius: var(--main-border-radius);
    border: 1px solid var(--main-md-gray-color);
    font-size: 1rem;
    font-weight: 300;
    font-style: normal;
    width: 100%;
    box-shadow: var(--input-box-shadow);
}

input[type="date"].text-input {
    -webkit-appearance: none;
    appearance: none;

    background-color: var(--main-bg-color);
    color: inherit;

    padding: 0.25rem 0.5rem;
    min-height: 1.5rem;

    font-family: inherit;
    font-size: 1rem;
}

/* ——————————————————————————————————————————————— */

/* Radio input field */
.radio-input-container {
    display: flex;
    flex-direction: column;
    margin-left: 0.5rem;
}

.radio-input {
    accent-color: var(--main-accent-color);
    box-shadow: var(--input-box-shadow);
}

.radio-label {
    margin-left: 0.25rem;
}
/* ——————————————————————————————————————————————— */

/* Select input field */
.select-input {
    position: relative;
}
.select-input select{
    padding: 0.25rem 0.75rem;
    border-radius: var(--main-border-radius);
    border: 1px solid var(--main-md-gray-color);
    box-shadow: var(--input-box-shadow);
    font-size: 1rem;
    font-weight: 300;
    font-style: normal;
    width: 100%;
    margin-right: 1.5rem;

    appearance: none;
    -webkit-appearance: none;
    -moz-appearance: none;

    background-color: var(--main-bg-color);
    color: var(--main-text-color);
}

.select-input .select-dropdown-icon {
    position: absolute;
    right: 0.75rem;
    top: 50%;
    transform: translateY(-50%);
    pointer-events: none;
    color: var(--main-md-gray-color);
    font-size: 1rem;
    line-height: 1;
}

select:disabled {
    background-color: var(--main-lt-gray-color) !important;
    opacity: 1;
}
/* ——————————————————————————————————————————————— */

/* Multi-select input field */
.form-multiple-select {
    border: 1px solid var(--main-md-gray-color);
    border-radius: var(--main-border-radius);
    background-color: var(--main-bg-color);
    box-shadow: var(--input-box-shadow);
    max-height: 220px; /* Adjust based on your design */
    overflow-y: auto;
    display: flex;
    flex-direction: column;
}

/* Hide the actual checkbox but keep it functional */
.hidden-checkbox {
    position: absolute;
    opacity: 0;
    cursor: pointer;
    height: 0;
    width: 0;
}

/* The clickable row */
.select-option {
    cursor: pointer;
    border-bottom: 1px solid var(--main-lt-gray-color);
    transition: background 0.15s ease;
}

.select-option:last-child {
    border-bottom: none;
}

.option-content {
    display: flex;
    align-items: center;
    padding: 0.6rem 0.75rem;
    color: var(--main-text-color);
    font-size: 0.95rem;
}

/* Hover effect */
.select-option:hover {
    background-color: var(--main-lt-gray-color);
}

/* Style when selected */
.hidden-checkbox:checked + .option-content {
    background-color: rgba(var(--main-accent-rgb), 0.1); /* Subtle tint */
}

.hidden-checkbox:checked + .option-content .option-text {
    font-weight: 500;
}

/* Custom Checkbox visual */
.checkbox-box {
    width: 16px;
    height: 16px;
    border: 1px solid var(--main-md-gray-color);
    border-radius: 3px;
    margin-right: 12px;
    display: inline-block;
    position: relative;
    background: white;
}

.hidden-checkbox:checked + .option-content .checkbox-box {
    background-color: var(--main-accent-color);
    border-color: var(--main-accent-color);
}

/* The Checkmark */
.hidden-checkbox:checked + .option-content .checkbox-box::after {
    content: "";
    position: absolute;
    left: 5px;
    top: 2px;
    width: 4px;
    height: 8px;
    border: solid white;
    border-width: 0 2px 2px 0;
    transform: rotate(45deg);
}

/* ——————————————————————————————————————————————— */
/* Text area input field */
.textarea-input {
    padding: 0.25rem 0.5rem;
    border-radius: var(--main-border-radius);
    border: 1px solid var(--main-md-gray-color);
    box-shadow: var(--input-box-shadow);
    font-size: 1rem;
    font-weight: 300;
    font-style: normal;
    width: 100%;
}
/* ——————————————————————————————————————————————— */

/* ---- input field */
/* ——————————————————————————————————————————————— */


