I have looked into your problem in detail and have tested your code by running it myself. Your guess was right, it was a small mistake that you were missing.
The real problem is a misunderstanding of the path between your server.py and index.html. Your server is treating the source folder as its 'home' (root directory).
Your problem is in this line of your base.html (or index.html) file
<link rel="stylesheet" href="static/styles.css">
When the browser requests this file, the server looks for it at source/static/styles.css, which is the wrong path
Solution
To fix this, you just need to remove static/ because both your index.html and styles.css files are in the same folder (source)
The correct line is
<link rel="stylesheet" href="styles.css">
I have run your code with this change and it is working perfectly
Here is a screenshot of the running code