diff --git a/docs/requirements.txt b/docs/requirements.txt
index 2a891db004..c47d196730 100644
--- a/docs/requirements.txt
+++ b/docs/requirements.txt
@@ -1 +1 @@
-sphinx<7
+sphinx<9
diff --git a/docs/source/_themes/metrics/layout.html b/docs/source/_themes/metrics/layout.html
index ab56388451..d1239319b0 100644
--- a/docs/source/_themes/metrics/layout.html
+++ b/docs/source/_themes/metrics/layout.html
@@ -19,7 +19,9 @@
{%- for cssfile in css_files %}
{%- endfor %}
+ {%- for style in styles -%}
+ {%- endfor -%}
{%- if favicon %}
{%- endif %}