From f38cf49f255751f772199ab127f9117f7b3ae7d4 Mon Sep 17 00:00:00 2001 From: Julien Calixte Date: Sat, 20 Jun 2026 14:53:41 +0200 Subject: [PATCH] style: force the primary colour to #ff9ff3 across every theme MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit The default (no data-theme) resolves to DaisyUI's dark theme, whose :root:not([data-theme]) selector outranks a custom light theme — so the previous light-only override never reached buttons in dark mode. Force it with an !important :root override that wins regardless of theme. --- src/style.css | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) diff --git a/src/style.css b/src/style.css index 8a66f59..26414c6 100644 --- a/src/style.css +++ b/src/style.css @@ -9,7 +9,16 @@ @plugin "daisyui/theme" { name: "light"; default: true; - --color-primary: #2e86de; + --color-primary: #ff9ff3; +} + +/* DaisyUI's default (no data-theme) resolves to its *dark* theme via + prefers-color-scheme, with a selector (`:root:not([data-theme])`) that outranks + a custom light theme's `:where(:root)` — so overriding only the light theme + never reached the buttons. Force the brand primary across every theme. */ +:root { + --color-primary: #ff9ff3 !important; + --color-primary-content: #3d1f3a !important; } @theme {