File size: 13,120 Bytes
e73ce34 | 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 308 309 310 311 312 313 314 315 316 317 318 319 320 321 322 323 324 325 326 327 328 329 330 331 332 333 334 335 336 337 338 339 340 341 342 343 344 345 346 347 348 349 350 351 352 353 354 355 356 357 358 359 360 361 362 363 364 365 366 367 368 369 370 371 372 373 374 375 376 377 378 379 380 381 382 383 384 385 386 387 388 389 390 391 392 393 394 395 396 397 398 399 400 401 402 403 404 405 406 407 408 409 410 | /* src/styles/tailwind.css */
@import "tailwindcss";
@import "tw-animate-css";
@plugin "@tailwindcss/typography";
@custom-variant dark (&:where(.dark, .dark *));
/* ===== shadcn/ui CSS Variables (OKLCH) ===== */
:root {
--radius: 0.625rem;
/* Light mode: sky/slate palette */
--background: oklch(0.9688 0.0035 264.54); /* slate-100 */
--foreground: oklch(0.2078 0.0397 265.75); /* slate-900 */
--card: oklch(1 0 0); /* white */
--card-foreground: oklch(0.2078 0.0397 265.75); /* slate-900 */
--popover: oklch(1 0 0); /* white */
--popover-foreground: oklch(0.2078 0.0397 265.75); /* slate-900 */
--primary: oklch(0.5459 0.1522 241.22); /* sky-600 */
--primary-foreground: oklch(1 0 0); /* white */
--secondary: oklch(0.9282 0.0069 264.53); /* slate-200 */
--secondary-foreground: oklch(0.2078 0.0397 265.75); /* slate-900 */
--muted: oklch(0.9282 0.0069 264.53); /* slate-200 */
--muted-foreground: oklch(0.5542 0.0255 264.36); /* slate-500 */
--accent: oklch(0.9282 0.0069 264.53); /* slate-200 */
--accent-foreground: oklch(0.2078 0.0397 265.75); /* slate-900 */
--destructive: oklch(0.5774 0.2157 27.33); /* red-600 */
--border: oklch(0.8694 0.0106 264.53); /* slate-300 */
--input: oklch(0.8694 0.0106 264.53); /* slate-300 */
--ring: oklch(0.5459 0.1522 241.22); /* sky-600 */
--chart-1: oklch(0.6469 0.1651 231.11); /* sky-500 */
--chart-2: oklch(0.5826 0.1556 254.62); /* indigo-500 */
--chart-3: oklch(0.6275 0.1454 292.79); /* purple-500 */
--chart-4: oklch(0.6382 0.1773 25.72); /* orange-500 */
--chart-5: oklch(0.723 0.1907 149.58); /* green-500 */
--sidebar-background: oklch(0.9688 0.0035 264.54); /* slate-100 */
--sidebar-foreground: oklch(0.2078 0.0397 265.75); /* slate-900 */
--sidebar-primary: oklch(0.5459 0.1522 241.22); /* sky-600 */
--sidebar-primary-foreground: oklch(1 0 0); /* white */
--sidebar-accent: oklch(0.9282 0.0069 264.53); /* slate-200 */
--sidebar-accent-foreground: oklch(0.2078 0.0397 265.75); /* slate-900 */
--sidebar-border: oklch(0.8694 0.0106 264.53); /* slate-300 */
--sidebar-ring: oklch(0.5459 0.1522 241.22); /* sky-600 */
}
.dark {
/* Dark mode: sky/slate palette with custom gray-950 background */
--background: oklch(0.16 0.02 250); /* #0f1521 custom gray-950 */
--foreground: oklch(0.9688 0.0035 264.54); /* slate-100 */
--card: oklch(0.2955 0.0301 265.75); /* slate-800 */
--card-foreground: oklch(0.9688 0.0035 264.54); /* slate-100 */
--popover: oklch(0.2955 0.0301 265.75); /* slate-800 */
--popover-foreground: oklch(0.9688 0.0035 264.54); /* slate-100 */
--primary: oklch(0.7461 0.1248 241.02); /* sky-400 */
--primary-foreground: oklch(0.16 0.02 250); /* gray-950 */
--secondary: oklch(0.3937 0.0278 265.75); /* slate-700 */
--secondary-foreground: oklch(0.9688 0.0035 264.54); /* slate-100 */
--muted: oklch(0.3937 0.0278 265.75); /* slate-700 */
--muted-foreground: oklch(0.7041 0.0177 264.53); /* slate-400 */
--accent: oklch(0.3937 0.0278 265.75); /* slate-700 */
--accent-foreground: oklch(0.9688 0.0035 264.54); /* slate-100 */
--destructive: oklch(0.5774 0.2157 27.33); /* red-600 */
--border: oklch(0.3937 0.0278 265.75); /* slate-700 */
--input: oklch(0.3937 0.0278 265.75); /* slate-700 */
--ring: oklch(0.7461 0.1248 241.02); /* sky-400 */
--chart-1: oklch(0.7461 0.1248 241.02); /* sky-400 */
--chart-2: oklch(0.7187 0.1686 254.62); /* indigo-400 */
--chart-3: oklch(0.7141 0.1648 292.79); /* purple-400 */
--chart-4: oklch(0.7483 0.183 55.93); /* amber-400 */
--chart-5: oklch(0.7926 0.1947 149.58); /* green-400 */
--sidebar-background: oklch(0.16 0.02 250); /* custom gray-950 */
--sidebar-foreground: oklch(0.9688 0.0035 264.54); /* slate-100 */
--sidebar-primary: oklch(0.7461 0.1248 241.02); /* sky-400 */
--sidebar-primary-foreground: oklch(0.16 0.02 250); /* gray-950 */
--sidebar-accent: oklch(0.3937 0.0278 265.75); /* slate-700 */
--sidebar-accent-foreground: oklch(0.9688 0.0035 264.54); /* slate-100 */
--sidebar-border: oklch(0.3937 0.0278 265.75); /* slate-700 */
--sidebar-ring: oklch(0.7461 0.1248 241.02); /* sky-400 */
}
/* ===== Map CSS variables to Tailwind utilities via @theme ===== */
@theme inline {
--color-background: var(--background);
--color-foreground: var(--foreground);
--color-card: var(--card);
--color-card-foreground: var(--card-foreground);
--color-popover: var(--popover);
--color-popover-foreground: var(--popover-foreground);
--color-primary: var(--primary);
--color-primary-foreground: var(--primary-foreground);
--color-secondary: var(--secondary);
--color-secondary-foreground: var(--secondary-foreground);
--color-muted: var(--muted);
--color-muted-foreground: var(--muted-foreground);
--color-accent: var(--accent);
--color-accent-foreground: var(--accent-foreground);
--color-destructive: var(--destructive);
--color-border: var(--border);
--color-input: var(--input);
--color-ring: var(--ring);
--color-chart-1: var(--chart-1);
--color-chart-2: var(--chart-2);
--color-chart-3: var(--chart-3);
--color-chart-4: var(--chart-4);
--color-chart-5: var(--chart-5);
--color-sidebar-background: var(--sidebar-background);
--color-sidebar-foreground: var(--sidebar-foreground);
--color-sidebar-primary: var(--sidebar-primary);
--color-sidebar-primary-foreground: var(--sidebar-primary-foreground);
--color-sidebar-accent: var(--sidebar-accent);
--color-sidebar-accent-foreground: var(--sidebar-accent-foreground);
--color-sidebar-border: var(--sidebar-border);
--color-sidebar-ring: var(--sidebar-ring);
--radius-sm: calc(var(--radius) - 4px);
--radius-md: calc(var(--radius) - 2px);
--radius-lg: var(--radius);
--radius-xl: calc(var(--radius) + 4px);
}
@theme {
/* Custom color shades (non-default) */
--color-gray-750: #2b3544;
--color-gray-850: #1a2231;
--color-gray-950: #0f1521; /* Keep: different from v4 default #030712 */
--color-blue-350: #7dabf8;
--color-blue-450: #4f85e6;
--color-blue-550: #3a72d6;
--color-blue-650: #2a5db8;
--color-blue-750: #214a98;
--color-blue-850: #183878;
/* Font stacks */
--font-sans:
"Inter", ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto,
"Helvetica Neue", Arial, "Noto Sans", sans-serif;
--font-mono:
"JetBrains Mono", ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono",
"Courier New", monospace;
/* Custom animations (from old tailwind.config.js) */
--animate-pulse-slow: pulse 3s cubic-bezier(0.4, 0, 0.6, 1) infinite;
--animate-pulse-fast: pulse 1s cubic-bezier(0.4, 0, 0.6, 1) infinite;
--animate-bounce-slow: bounce 2s infinite;
--animate-shimmer: shimmer 2s ease-in-out infinite;
}
/* ===== Base Styles ===== */
@layer base {
/* Preserve v3 border color default */
*,
::after,
::before,
::backdrop,
::file-selector-button {
border-color: var(--border);
}
/* Base element styling */
body {
@apply bg-background text-foreground min-h-screen antialiased;
font-family:
"Inter",
system-ui,
-apple-system,
BlinkMacSystemFont,
"Segoe UI",
Roboto,
sans-serif;
}
h1,
h2,
h3,
h4,
h5,
h6 {
@apply font-semibold text-foreground;
}
/* Links */
a {
@apply text-primary hover:underline decoration-transparent hover:decoration-current underline-offset-4 transition-all duration-200;
}
/* Fixed header clearance — absolute backgrounds fill from container
top (unaffected by padding), content pushed below header */
main > * {
padding-top: 4.5rem; /* 72px: h-14 + pt-2 + breathing room */
}
/* Scoped transition to interactive elements (was global * selector) */
a,
button,
input,
select,
textarea,
[role="button"] {
transition-property:
color, background-color, border-color, outline-color, text-decoration-color, fill, stroke;
transition-duration: 200ms;
transition-timing-function: ease-in-out;
}
}
/* ===== Custom Utilities (survive past Phase 4) ===== */
@utility glass {
background-color: rgb(255 255 255 / 0.7);
backdrop-filter: blur(16px);
border: 1px solid rgb(203 213 225 / 0.5);
&:where(.dark, .dark *) {
background-color: rgb(30 41 59 / 0.7);
backdrop-filter: blur(24px);
border-color: rgb(51 65 85 / 0.5);
}
}
/* Bold glassmorphism -- the primary glass surface */
@utility glass-bold {
background-color: rgb(255 255 255 / 0.1);
backdrop-filter: blur(24px);
-webkit-backdrop-filter: blur(24px);
border: 1px solid rgb(255 255 255 / 0.3);
box-shadow: inset 0 1px 1px 0 rgb(255 255 255 / 0.15);
&:where(.dark, .dark *) {
background-color: rgb(30 41 59 / 0.2);
border-color: rgb(148 163 184 / 0.15);
box-shadow: inset 0 1px 1px 0 rgb(255 255 255 / 0.05);
}
}
/* Mobile-optimized glass (reduced blur for GPU perf) */
@utility glass-mobile {
background-color: rgb(255 255 255 / 0.1);
backdrop-filter: blur(12px);
-webkit-backdrop-filter: blur(12px);
border: 1px solid rgb(255 255 255 / 0.2);
&:where(.dark, .dark *) {
background-color: rgb(30 41 59 / 0.2);
border-color: rgb(148 163 184 / 0.1);
}
}
/* Claymorphism for interactive elements (raised, tactile feel) */
@utility clay-interactive {
border-radius: 16px;
box-shadow:
inset 0 -3px 6px 0 rgb(0 0 0 / 0.06),
inset 0 2px 4px 0 rgb(255 255 255 / 0.4),
0 8px 20px -4px rgb(0 0 0 / 0.12),
0 2px 4px 0 rgb(0 0 0 / 0.04);
&:where(.dark, .dark *) {
box-shadow:
inset 0 -3px 6px 0 rgb(0 0 0 / 0.2),
inset 0 2px 4px 0 rgb(255 255 255 / 0.08),
0 8px 20px -4px rgb(0 0 0 / 0.4),
0 2px 4px 0 rgb(0 0 0 / 0.15);
}
}
/* Claymorphism button shadow (no border-radius — buttons control their own) */
@utility clay-btn {
box-shadow:
inset 0 -3px 6px 0 rgb(0 0 0 / 0.08),
inset 0 2px 3px 0 rgb(255 255 255 / 0.4),
0 6px 16px -4px rgb(0 0 0 / 0.12),
0 2px 4px 0 rgb(0 0 0 / 0.04);
&:where(.dark, .dark *) {
box-shadow:
inset 0 -3px 6px 0 rgb(0 0 0 / 0.2),
inset 0 2px 3px 0 rgb(255 255 255 / 0.08),
0 6px 16px -4px rgb(0 0 0 / 0.35),
0 2px 4px 0 rgb(0 0 0 / 0.15);
}
}
/* Clay button pressed state (inverted shadows for pressed-in appearance) */
@utility clay-pressed {
box-shadow:
inset 0 2px 6px 0 rgb(0 0 0 / 0.1),
inset 0 -1px 2px 0 rgb(255 255 255 / 0.2),
0 2px 4px -2px rgb(0 0 0 / 0.06);
&:where(.dark, .dark *) {
box-shadow:
inset 0 2px 6px 0 rgb(0 0 0 / 0.3),
inset 0 -1px 2px 0 rgb(255 255 255 / 0.04),
0 2px 4px -2px rgb(0 0 0 / 0.2);
}
}
/* Button hover lift with glow (ANIM-02) */
@utility btn-hover-lift {
transition:
transform 200ms ease,
box-shadow 200ms ease;
&:hover {
transform: translateY(-2px);
box-shadow:
0 4px 12px -2px oklch(from var(--primary) l c h / 0.2),
inset 0 -3px 6px 0 rgb(0 0 0 / 0.08),
inset 0 2px 3px 0 rgb(255 255 255 / 0.4),
0 6px 16px -4px rgb(0 0 0 / 0.12);
}
&:where(.dark, .dark *):hover {
box-shadow:
0 4px 12px -2px oklch(from var(--primary) l c h / 0.3),
inset 0 -3px 6px 0 rgb(0 0 0 / 0.2),
inset 0 2px 3px 0 rgb(255 255 255 / 0.08),
0 6px 16px -4px rgb(0 0 0 / 0.35);
}
&:active {
transform: translateY(0) scale(0.97);
transition:
transform 100ms ease,
box-shadow 100ms ease;
}
}
/* Focus ring animation (ANIM-03) */
@utility focus-ring-animate {
outline: 2px solid transparent;
outline-offset: 2px;
transition:
outline-color 200ms ease,
outline-offset 200ms ease;
&:focus-visible {
outline-color: var(--ring);
outline-offset: 3px;
}
}
@utility text-gradient {
color: transparent;
background-clip: text;
background-image: linear-gradient(to right, var(--color-sky-600), var(--color-indigo-600));
&:where(.dark, .dark *) {
background-image: linear-gradient(to right, var(--color-sky-400), var(--color-cyan-400));
}
}
@utility bg-gradient-radial {
background-image: radial-gradient(var(--tw-gradient-stops));
}
@utility transform-style-3d {
transform-style: preserve-3d;
}
@utility scrollbar-hide {
-ms-overflow-style: none;
scrollbar-width: none;
&::-webkit-scrollbar {
display: none;
}
}
/* ===== Theme Toggle Button ===== */
@layer components {
.theme-toggle-button:hover {
--pulse-color: var(--color-sky-500);
animation: subtle-pulse 1.5s cubic-bezier(0.4, 0, 0.6, 1) infinite;
}
.dark .theme-toggle-button:hover {
--pulse-color: var(--color-sky-400);
}
}
/* ===== Keyframes ===== */
@keyframes subtle-pulse {
0%,
100% {
box-shadow: 0 0 0 0 color-mix(in oklch, var(--pulse-color) 30%, transparent);
}
50% {
box-shadow: 0 0 0 5px color-mix(in oklch, var(--pulse-color) 0%, transparent);
}
}
@keyframes shimmer {
0% {
transform: translateX(-100%);
}
100% {
transform: translateX(100%);
}
}
@keyframes mesh-gradient-move {
0% {
background-position: 0% 50%;
}
50% {
background-position: 100% 50%;
}
100% {
background-position: 0% 50%;
}
}
|