diff --git a/src/app.css b/src/app.css index 9a9605f..bde1bde 100644 --- a/src/app.css +++ b/src/app.css @@ -87,3 +87,212 @@ body { .auth-link-btn:hover { color: #ea580c; text-decoration: underline; } .auth-inline-msg { margin-top: 12px; } .hint { margin: 6px 0 0; color: #64748b; font-size: 12px; } + +/* ===== Admin Shell + Shared UI ===== */ +.admin-shell-root { + background: + radial-gradient(circle at 92% 8%, rgba(253, 98, 22, 0.08), transparent 30%), + radial-gradient(circle at 12% 100%, rgba(10, 29, 55, 0.08), transparent 36%), + #f8f9fd; +} + +.admin-main section.rounded-xl.border.border-gray-200.bg-white.shadow-sm { + border-color: #e2e8f0 !important; + box-shadow: 0 12px 28px -20px rgba(10, 29, 55, 0.34) !important; + border-radius: 14px !important; +} + +.admin-main table.w-full { + border-collapse: separate; + border-spacing: 0; +} + +.admin-main table.w-full thead th { + background: #0a1d37; + color: rgba(255,255,255,0.85); + font-size: 11px; + text-transform: uppercase; + letter-spacing: 0.08em; + font-weight: 700; + padding: 11px 14px; + border-bottom: none; + text-align: left; + white-space: nowrap; +} + +.admin-main table.w-full tbody td { + color: #0f172a; + font-size: 13px; + padding: 12px 14px; + border-bottom: 1px solid #eef2f7; + vertical-align: middle; +} + +.admin-main table.w-full tbody tr:last-child td { + border-bottom: 0; +} + +.admin-main table.w-full tbody tr:hover td { + background: #fcfdff; +} + +.admin-main input[type='text'], +.admin-main input[type='search'], +.admin-main input[type='number'], +.admin-main input[type='email'], +.admin-main input[type='url'], +.admin-main input[type='password'], +.admin-main select, +.admin-main textarea { + border: 1px solid #cbd5e1; + border-radius: 7px; + background: #fff; + color: #0f172a; + transition: border-color 160ms, box-shadow 160ms; +} + +.admin-main input:focus, +.admin-main select:focus, +.admin-main textarea:focus { + border-color: rgba(10, 29, 55, 0.45) !important; + box-shadow: 0 0 0 3px rgba(10, 29, 55, 0.08); + outline: none; +} + +.notice { + margin: 0; + color: #64748b; + font-size: 13px; + line-height: 1.5; + padding: 14px 16px; +} + +.list-header { + display: flex; + align-items: center; + justify-content: space-between; + gap: 12px; + margin-bottom: 14px; +} + +.list-header h2 { + margin: 0; + font-size: 18px; + font-weight: 800; + color: #0a1d37; +} + +.list-item { + border: 1px solid #e2e8f0; + border-radius: 8px; + background: #fff; + padding: 14px; +} + +.list-item h3 { + margin: 0 0 10px; + font-size: 14px; + font-weight: 800; + color: #0a1d37; +} + +.admin-segmented { + display: inline-flex; + align-items: center; + gap: 6px; + margin: 0 0 16px; + padding: 4px; + border-radius: 8px; + border: 1px solid #e2e8f0; + background: #fff; +} + +.admin-segment { + border: 0; + background: transparent; + color: #475569; + font-size: 13px; + font-weight: 700; + line-height: 1; + padding: 7px 12px; + border-radius: 6px; + cursor: pointer; + transition: all 140ms ease; +} + +.admin-segment:hover { + background: #f8fafc; + color: #0f172a; +} + +.admin-segment.active { + background: rgba(10, 29, 55, 0.10); + color: #0a1d37; +} + +.admin-segment:disabled { + opacity: 0.45; + cursor: not-allowed; +} + +.admin-pagination { + display: flex; + align-items: center; + justify-content: flex-end; + gap: 12px; + padding: 12px 14px; + border-top: 1px solid #e2e8f0; + color: #64748b; + font-size: 12px; + font-weight: 700; +} + +.admin-link-tabs { + display: inline-flex; + align-items: center; + gap: 6px; + margin: 0 0 14px; + padding: 3px; + border: 1px solid #e2e8f0; + border-radius: 8px; + background: #fff; +} + +.admin-link-tabs a { + border-radius: 6px; + padding: 7px 12px; + text-decoration: none; + font-size: 13px; + font-weight: 700; + color: #64748b; +} + +.admin-link-tabs a[aria-current='page'] { + background: rgba(10, 29, 55, 0.10); + color: #0a1d37; +} + +.preview-tabs { + display: flex; + flex-wrap: wrap; + gap: 8px; +} + +.preview-tabs button { + border: 1px solid #e2e8f0; + border-radius: 999px; + background: #fff; + color: #475569; + font-size: 12px; + font-weight: 700; + padding: 6px 11px; + cursor: pointer; +} + +@media (max-width: 1023px) { + .admin-main table.w-full thead th, + .admin-main table.w-full tbody td { + font-size: 12px; + padding: 10px 11px; + } +} diff --git a/src/components/AdminShell.tsx b/src/components/AdminShell.tsx index b082db1..20c48da 100644 --- a/src/components/AdminShell.tsx +++ b/src/components/AdminShell.tsx @@ -173,8 +173,8 @@ export default function AdminShell(props: { children: JSX.Element }) { return (
-
-
+
+
{checkedSession() ? ( -
+
setSidebarOpen(false)} /> -
+
setSidebarOpen(false)} onLogout={onLogout} />
-
+
) : ( -
-