From 38163210d6369cf5070ad4e3f1521f725d08fd57 Mon Sep 17 00:00:00 2001 From: Nikolay Tatarinov Date: Fri, 6 Feb 2026 18:54:29 +0300 Subject: [PATCH] Enhance UI with new font integration, improved accessibility focus styles, and refined card shadows for light theme. Update main content area background and adjust layout spacing in index template. --- static/css/main.css | 25 ++++++++++- templates/base.html | 7 +-- templates/index.html | 105 +++++++++++++++++++++++-------------------- 3 files changed, 84 insertions(+), 53 deletions(-) diff --git a/static/css/main.css b/static/css/main.css index 258779c..648b5d3 100644 --- a/static/css/main.css +++ b/static/css/main.css @@ -1,6 +1,10 @@ @import "tailwindcss"; @plugin "daisyui"; +@theme { + --font-sans: "DM Sans", ui-sans-serif, system-ui, sans-serif, "Apple Color Emoji", "Segoe UI Emoji", "Segoe UI Symbol", "Noto Color Emoji"; +} + @plugin "daisyui/theme" { name: "light"; default: true; @@ -71,9 +75,28 @@ --noise: 0; } -/* Dark theme: main content area uses base-200 so navbar and cards (base-100) stand out */ +/* Main content area: distinct background so cards (base-100) stand out */ +[data-theme=light] main { + background-color: var(--color-base-200); +} [data-theme=dark] main { background-color: var(--color-base-200); } +/* Accessibility: ensure focus ring is visible on key controls */ +.btn:focus-visible, +.select:focus-within, +label.swap:focus-within { + outline: 2px solid var(--color-primary); + outline-offset: 2px; +} + +/* Light theme: slightly stronger card shadow for depth */ +[data-theme=light] .card.shadow-sm { + box-shadow: 0 1px 3px 0 rgb(0 0 0 / 0.08), 0 1px 2px -1px rgb(0 0 0 / 0.06); +} +[data-theme=light] .card.shadow-sm:hover { + box-shadow: 0 4px 6px -1px rgb(0 0 0 / 0.08), 0 2px 4px -2px rgb(0 0 0 / 0.06); +} + @source "../../templates"; \ No newline at end of file diff --git a/templates/base.html b/templates/base.html index 26a7ccb..90164fe 100644 --- a/templates/base.html +++ b/templates/base.html @@ -5,6 +5,9 @@ {% block title %}SWatcher{% endblock %} + + + {% block imports %} {% endblock %} @@ -13,12 +16,10 @@ -