feat: dark/light theming system + design tokens (OMC design system port)

- Restructure design tokens into :root/.dark raw vars mapped via @theme inline
- Add light/dark/system theming: useTheme hook + FOUC guard + ThemeToggle
- Keep iamcavalli palette (primary #1A463C, accent #DEF168) and Geist fonts
- Derive brand-consistent dark palette (verde-nero bg, lightened primary)
- Add scrollbar utilities (.no-scrollbar/.thin-scrollbar)
- Install tailwindcss-animate, register via @plugin (Tailwind v4)
- Mount ThemeToggle in admin sidebar footer

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
This commit is contained in:
2026-07-03 08:08:56 +01:00
parent add2176a6b
commit 43cb7e7469
7 changed files with 340 additions and 44 deletions
+7 -2
View File
@@ -14,6 +14,7 @@ import {
Zap,
FileText,
} from "lucide-react";
import ThemeToggle from "@/components/ThemeToggle";
const NAV_ITEMS = [
{ href: "/admin", label: "Dashboard", icon: LayoutDashboard, exact: true },
@@ -60,8 +61,12 @@ export function AdminSidebar() {
})}
</nav>
{/* Logout */}
<div className="px-3 py-4 border-t border-white/10">
{/* Theme + Logout */}
<div className="px-3 py-4 border-t border-white/10 flex flex-col gap-2">
<div className="flex items-center justify-between px-3">
<span className="text-xs text-white/50">Tema</span>
<ThemeToggle />
</div>
<button
onClick={() => signOut({ callbackUrl: "/admin/login" })}
className="flex items-center gap-3 px-3 py-2 w-full rounded-md text-sm text-white/65 hover:text-white hover:bg-white/10 transition-colors"