From a607faec9adfb04545da93491709b1ecb21404e5 Mon Sep 17 00:00:00 2001
From: Daniel Kraus
Date: Mon, 15 Jun 2026 21:18:11 +0200
Subject: [PATCH] Update banner for small screens.
---
assets/scss/hugo_cookie_consent/style.scss | 26 ++++++++++++++++++-
.../_partials/hugo_cookie_consent/banner.html | 2 +-
2 files changed, 26 insertions(+), 2 deletions(-)
diff --git a/assets/scss/hugo_cookie_consent/style.scss b/assets/scss/hugo_cookie_consent/style.scss
index 8c31f5b..8c0fd9c 100644
--- a/assets/scss/hugo_cookie_consent/style.scss
+++ b/assets/scss/hugo_cookie_consent/style.scss
@@ -16,6 +16,12 @@
gap: 1rem;
z-index: 9999;
transition: opacity 0.5s ease;
+
+ @media (max-width: 420px) {
+ flex-direction: column;
+ align-items: stretch;
+ gap: 0.75rem;
+ }
}
#cookie-banner.fade-out {
@@ -23,7 +29,25 @@
pointer-events: none;
}
-#cookie-banner p { margin: 0; font-size: 14px; flex: 1; }
+#cookie-banner p {
+ margin: 0;
+ font-size: 14px;
+ flex: 1;
+}
+
+#cookie-banner .cookie-buttons {
+ display: flex;
+ gap: 0.5rem;
+ flex-shrink: 0;
+
+ @media (max-width: 420px) {
+ width: 100%;
+
+ button {
+ flex: 1;
+ }
+ }
+}
#cookie-banner button {
margin: 0.1rem 0;
diff --git a/layouts/_partials/hugo_cookie_consent/banner.html b/layouts/_partials/hugo_cookie_consent/banner.html
index d7e0996..b33816e 100644
--- a/layouts/_partials/hugo_cookie_consent/banner.html
+++ b/layouts/_partials/hugo_cookie_consent/banner.html
@@ -8,7 +8,7 @@
{{ i18n "cookie_more_info" }}
-
+