.form-group {
    min-height: 88px;
}

.form-group .form-control {
    margin-bottom: 6px;
}

.form-group:last-child {
    margin-bottom: 0;
}

.form-row {
    display: flex;
    gap: 14px;
}

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

.submit-button {
    margin-top: 32px;
}

.form-group label {
    font-size: 14px;
    color: var(--text-secondary);
    margin-bottom: 4px;
    font-weight: 400;
    line-height: 16px;
    letter-spacing: 0;
}

.label-row {
    display: flex;
    align-items: center;
}

.form-control {
    height: 40px;
    padding: 8px 12px;
    border: 1px solid var(--border-soft);
    border-radius: 4px;
    font-size: 14px;
    color: var(--text-primary);
    background-color: var(--surface-elevated-contrasting);
    font-family: inherit;
    transition: border-color 0.2s;
}

/* Bootstrap's .form-control:focus re-declares color, background and box-shadow with its own
   light-mode defaults. Restate ours so nothing leaks through in dark mode. */
.form-control:focus {
    border-color: var(--brand-primary-sharp);
    background-color: var(--surface-elevated-contrasting);
    color: var(--text-primary);
    caret-color: var(--text-primary);
    box-shadow: 0 0 0 2px color-mix(in srgb, var(--brand-primary-sharp) 30%, transparent);
    outline: none;
}

.form-control::placeholder {
    color: var(--text-tertiary);
    opacity: 1;
}

.form-control:disabled {
    background-color: var(--state-disabled-soft);
    color: var(--state-disabled-balanced);
}

/* Chrome paints autofilled fields with its own background and text color and ignores
   background-color. A large inset shadow is the only way to cover it. */
.form-control:-webkit-autofill,
.form-control:-webkit-autofill:hover,
.form-control:-webkit-autofill:focus {
    -webkit-text-fill-color: var(--text-primary);
    caret-color: var(--text-primary);
    box-shadow: 0 0 0 1000px var(--surface-elevated-contrasting) inset;
}

.form-control:-webkit-autofill:focus {
    box-shadow: 0 0 0 1000px var(--surface-elevated-contrasting) inset,
                0 0 0 2px color-mix(in srgb, var(--brand-primary-sharp) 30%, transparent);
}

.required-marker {
    color: var(--situation-error-sharp);
    margin-left: 3px;
    vertical-align: middle;
}

.input-validation-error,
.form-control.input-validation-error {
    border-color: var(--situation-error-sharp);
    box-shadow: 0 0 0 2px var(--situation-error-soft);
}