diff --git a/app/globals.css b/app/globals.css index 0bc9070b..f23d93b4 100644 --- a/app/globals.css +++ b/app/globals.css @@ -81,18 +81,18 @@ body { } .glass-panel { - background: rgba(255, 255, 255, 0.015); - border: 1px solid rgba(255, 255, 255, 0.05); - box-shadow: var(--panel-shadow); - border-radius: 1.25rem; + background: rgba(255, 255, 255, 0.02); + border: 1px solid rgba(255, 255, 255, 0.06); + box-shadow: var(--shadow-md); + border-radius: var(--radius-panel); } .glass-card { - background: rgba(8, 8, 12, 0.85); + background: color-mix(in srgb, var(--card) 86%, transparent); border: 1px solid rgba(255, 255, 255, 0.05); - box-shadow: var(--shadow-soft); + box-shadow: var(--shadow-lg); backdrop-filter: blur(18px); - border-radius: 1.5rem; + border-radius: var(--radius-card); } .panel-muted { @@ -119,11 +119,11 @@ body { } .lab-hero { - border-radius: 32px; + border-radius: var(--radius-panel); border: 1px solid rgba(255, 255, 255, 0.08); - background: linear-gradient(145deg, rgba(255, 255, 255, 0.04), rgba(0, 0, 0, 0.55)); + background: var(--mk-surface-glow), linear-gradient(145deg, rgba(255, 255, 255, 0.05), rgba(0, 0, 0, 0.55)); padding: 1.75rem; - box-shadow: var(--panel-shadow); + box-shadow: var(--shadow-lg); } .lab-grid { @@ -138,11 +138,11 @@ body { } .context-panel { - border-radius: 28px; + border-radius: var(--radius-panel); border: 1px solid rgba(255, 255, 255, 0.08); - background: rgba(8, 8, 12, 0.7); + background: color-mix(in srgb, var(--mk-bg-panel) 85%, transparent); padding: 1.25rem; - box-shadow: var(--shadow-soft); + box-shadow: var(--shadow-md); } @keyframes mkGradientShift { @@ -173,6 +173,22 @@ body { transform: translate(-50%, 1rem); } +[data-icon], +.icon-base { + width: var(--icon-size); + height: var(--icon-size); + stroke-width: var(--icon-stroke); + flex-shrink: 0; +} + +.icon-sm { + --icon-size: var(--icon-size-sm); +} + +.icon-gap { + gap: var(--icon-gap); +} + .section-heading { font-size: clamp(1.25rem, 2.2vw, 2rem); font-weight: 600; diff --git a/app/theme.css b/app/theme.css index 3984830a..c6f38362 100644 --- a/app/theme.css +++ b/app/theme.css @@ -1,51 +1,65 @@ :root, .theme-dark { color-scheme: dark; - --mk-bg: #020203; - --mk-bg-panel: #08080a; - --mk-bg-panel-muted: #101017; - --mk-bg-card: #12121f; - --mk-border: #252537; - --mk-border-soft: #191927; - --mk-text: #ffffff; - --mk-text-muted: rgba(255, 255, 255, 0.68); + --mk-bg: #06060b; + --mk-bg-surface: #0b0b12; + --mk-bg-panel: #151827; + --mk-bg-panel-muted: #1b1f33; + --mk-bg-card: #111424; + --mk-border: #222536; + --mk-border-strong: #2e3246; + --mk-border-soft: #1a1d2b; + --mk-text: #f7f8fb; + --mk-text-muted: rgba(247, 248, 251, 0.72); --mk-accent: #ff6ec7; --mk-accent-2: #ff3cac; --mk-accent-3: #8b5cf6; - --mk-success: #5ef7b7; - --mk-warning: #ffc857; - --mk-danger: #ff6b6b; - --mk-gradient: linear-gradient(90deg, #ff6ec7, #ff3cac, #8b5cf6); + --mk-success: #6ee7b7; + --mk-warning: #f2cc60; + --mk-danger: #ff7878; + --mk-gradient: linear-gradient(115deg, #ff6ec7, #ff3cac, #8b5cf6); + --mk-surface-glow: linear-gradient(145deg, rgba(255, 255, 255, 0.02), rgba(255, 255, 255, 0)); --background: var(--mk-bg); --foreground: var(--mk-text); --card: var(--mk-bg-card); --card-foreground: var(--mk-text); - --popover: #050508; + --popover: #07070f; --popover-foreground: var(--mk-text); --primary: var(--mk-accent); --primary-foreground: #080208; --secondary: var(--mk-accent-3); - --secondary-foreground: #080208; + --secondary-foreground: #0b0611; --muted: var(--mk-bg-panel-muted); --muted-foreground: var(--mk-text-muted); --accent: var(--mk-accent); - --accent-foreground: #080208; + --accent-foreground: #0c0a14; --destructive: var(--mk-danger); - --destructive-foreground: #050202; + --destructive-foreground: #120102; --border: var(--mk-border); --input: var(--mk-border-soft); --ring: var(--mk-accent-2); - --radius: 28px; - --sidebar: rgba(2, 2, 4, 0.94); - --sidebar-foreground: rgba(255, 255, 255, 0.65); + --radius: 18px; + --radius-control: 14px; + --radius-card: 22px; + --radius-panel: 24px; + --sidebar: rgba(6, 6, 11, 0.95); + --sidebar-foreground: rgba(247, 248, 251, 0.8); --sidebar-primary: rgba(255, 110, 199, 0.12); --sidebar-primary-foreground: #ffffff; - --sidebar-accent: rgba(255, 255, 255, 0.03); + --sidebar-accent: rgba(247, 248, 251, 0.04); --sidebar-accent-foreground: var(--mk-text); - --sidebar-border: rgba(255, 255, 255, 0.08); + --sidebar-border: rgba(255, 255, 255, 0.07); --sidebar-ring: var(--mk-accent); + --shadow-sm: 0 10px 24px -18px rgba(0, 0, 0, 0.58); + --shadow-md: 0 18px 42px -20px rgba(0, 0, 0, 0.6); + --shadow-lg: 0 30px 64px -24px rgba(0, 0, 0, 0.62); + --shadow-focus: 0 0 0 3px rgba(255, 110, 199, 0.28); --shadow-soft: 0 20px 60px rgba(0, 0, 0, 0.55); - --panel-shadow: 0 25px 80px rgba(0, 0, 0, 0.75); + --panel-shadow: 0 26px 70px rgba(0, 0, 0, 0.7); + --icon-size: 20px; + --icon-size-sm: 16px; + --icon-stroke: 1.6; + --icon-gap: 10px; } body.theme-dark { diff --git a/components/discover/AdminDiscoverEditor.tsx b/components/discover/AdminDiscoverEditor.tsx index 1dae8acd..76d74e6c 100644 --- a/components/discover/AdminDiscoverEditor.tsx +++ b/components/discover/AdminDiscoverEditor.tsx @@ -4,7 +4,9 @@ import { useEffect, useMemo, useState } from 'react'; import useSWR from 'swr'; import { Loader2, Plus, RefreshCcw, Save, Trash2 } from 'lucide-react'; import type { DiscoverCommunityHighlight, DiscoverEvent, DiscoverFeed, DiscoverQuestHighlight } from '@mk/api-client'; -import { cn } from '@/lib/utils'; +import { Button } from '@/components/ui/button'; +import { Input } from '@/components/ui/input'; +import { Skeleton } from '@/components/ui/skeleton'; const fetcher = (url: string) => fetch(url).then((response) => { if (!response.ok) { @@ -118,10 +120,31 @@ export function AdminDiscoverEditor() { if (isLoading || !feed) { return ( -
-
- -

Loading Discover feed…

+
+
+
+ +

Loading Discover feed…

+
+
+ {[0, 1, 2, 3].map((item) => ( +
+ + +
+ ))} +
+
+ {[0, 1, 2].map((row) => ( + + ))} +
); @@ -129,7 +152,7 @@ export function AdminDiscoverEditor() { if (error) { return ( -
+

Unable to load Discover feed. Please refresh.

); @@ -137,29 +160,27 @@ export function AdminDiscoverEditor() { return (
-
+
- - + {toast ?

{toast}

: null}
{totals ? ( @@ -294,34 +315,35 @@ type SectionEditorProps = { function SectionEditor({ title, description, items, onAdd, onRemove, render }: SectionEditorProps) { return ( -
+

{title}

{description}

- +
{items.map((item, index) => ( -
+

Entry {index + 1}

- + Remove +
{render(item, index)}
@@ -344,8 +366,8 @@ function InputField({ label, value, onChange }: InputFieldProps) { return (