kepler-chat/src/app.css

478 lines
15 KiB
CSS

@import 'tailwindcss';
@import '@fontsource-variable/inter';
@import '@fontsource-variable/geist-mono';
@import '@fontsource-variable/fraunces';
@import '@fontsource-variable/inter-tight';
@import '@fontsource-variable/nunito-sans';
@custom-variant dark (&:is(.dark *));
:root {
--background: oklch(0.9754 0.0084 325.6414);
--foreground: oklch(0.3257 0.1161 325.0372);
--card: oklch(0.9754 0.0084 325.6414);
--card-foreground: oklch(0.3257 0.1161 325.0372);
--popover: oklch(1 0 0);
--popover-foreground: oklch(0.3257 0.1161 325.0372);
--primary: oklch(0.5797 0.1194 237.7893);
--heading: oklch(0.5797 0.1194 237.7893);
--primary-foreground: oklch(1 0 0);
--secondary: oklch(0.8696 0.0675 334.8991);
--secondary-foreground: oklch(0.4448 0.1341 324.7991);
--muted: oklch(0.9395 0.026 331.5454);
--muted-foreground: oklch(0.4924 0.1244 324.4523);
--accent: oklch(0.8696 0.0675 334.8991);
--accent-foreground: oklch(0.4448 0.1341 324.7991);
--destructive: oklch(0.5248 0.1368 20.8317);
--destructive-foreground: oklch(1 0 0);
--border: oklch(0.8568 0.0829 328.911);
--input: oklch(0.8517 0.0558 336.6002);
--ring: oklch(0.5916 0.218 0.5844);
--chart-1: oklch(0.6038 0.2363 344.4657);
--chart-2: oklch(0.4445 0.2251 300.6246);
--chart-3: oklch(0.379 0.0438 226.1538);
--chart-4: oklch(0.833 0.1185 88.3461);
--chart-5: oklch(0.7843 0.1256 58.9964);
/* Subtle blue shift for sidebar colors in light mode */
--sidebar: oklch(0.936 0.0288 280); /* Original hue 320.5788 -> 280 (more blue) */
--sidebar-foreground: oklch(0.4948 0.1909 285); /* Original hue 354.5435 -> 285 */
--sidebar-primary: oklch(0.3963 0.0251 270); /* Original hue 285.1962 -> 270 */
--sidebar-primary-foreground: oklch(
0.9668 0.0124 337.5228
); /* No change, keep white/near white */
--sidebar-accent: oklch(0.9789 0.0013 280); /* Original hue 106.4235 -> 280 */
--sidebar-accent-foreground: oklch(0.3963 0.0251 270); /* Original hue 285.1962 -> 270 */
--sidebar-border: oklch(0.9383 0.0026 280); /* Original hue 48.7178 -> 280 */
--sidebar-ring: oklch(0.5916 0.218 0.5844);
--radius: 0.5rem;
--shadow-2xs: 0 1px 3px 0px hsl(0 0% 0% / 0.05);
--shadow-xs: 0 1px 3px 0px hsl(0 0% 0% / 0.05);
--shadow-sm: 0 1px 3px 0px hsl(0 0% 0% / 0.1), 0 1px 2px -1px hsl(0 0% 0% / 0.1);
--shadow: 0 1px 3px 0px hsl(0 0% 0% / 0.1), 0 1px 2px -1px hsl(0 0% 0% / 0.1);
--shadow-md: 0 1px 3px 0px hsl(0 0% 0% / 0.1), 0 2px 4px -1px hsl(0 0% 0% / 0.1);
--shadow-lg: 0 1px 3px 0px hsl(0 0% 0% / 0.1), 0 4px 6px -1px hsl(0 0% 0% / 0.1);
--shadow-xl: 0 1px 3px 0px hsl(0 0% 0% / 0.1), 0 8px 10px -1px hsl(0 0% 0% / 0.1);
--shadow-2xl: 0 1px 3px 0px hsl(0 0% 0% / 0.25);
}
.dark {
--background: oklch(0.2409 0.0201 307.5346);
--foreground: oklch(0.8398 0.0387 309.5391);
--card: oklch(0.2803 0.0232 307.5413);
--card-foreground: oklch(0.8456 0.0302 341.4597);
--popover: oklch(0.1548 0.0132 338.9015);
--popover-foreground: oklch(0.9647 0.0091 341.8035);
--primary: oklch(0.5797 0.1194 237.7893);
--heading: oklch(0.85 0.1194 237.7893);
--primary-foreground: oklch(1 0 0);
--secondary: oklch(0.3137 0.0306 310.061);
--secondary-foreground: oklch(0.8483 0.0382 307.9613);
--muted: oklch(0.3234 0.0419 257.4748);
--muted-foreground: oklch(0.794 0.0372 307.1032);
--accent: oklch(0.3649 0.0508 308.4911);
--accent-foreground: oklch(0.9647 0.0091 341.8035);
--destructive: oklch(0.5248 0.1368 20.8317);
--destructive-foreground: oklch(1 0 0);
--border: oklch(0.3286 0.0154 343.4461);
--input: oklch(0.3387 0.0195 332.8347);
--ring: oklch(0.5797 0.1194 237.7893);
--chart-1: oklch(0.5316 0.1409 355.1999);
--chart-2: oklch(0.5633 0.1912 306.8561);
--chart-3: oklch(0.7227 0.1502 60.5799);
--chart-4: oklch(0.6193 0.2029 312.7422);
--chart-5: oklch(0.6118 0.2093 6.1387);
/* Subtle blue shift for sidebar colors in dark mode */
--sidebar: oklch(0.1693 0.0143 280); /* Original hue 331.0475 -> 260 */
--sidebar-foreground: oklch(0.8607 0.0293 265); /* Original hue 343.6612 -> 265 */
--sidebar-primary: oklch(0.4882 0.2172 250); /* Original hue 264.3763 -> 250 */
--sidebar-primary-foreground: oklch(1 0 0); /* No change, keep white */
--sidebar-accent: oklch(0.2337 0.0261 260); /* Original hue 338.1961 -> 260 */
--sidebar-accent-foreground: oklch(0.9674 0.0013 250); /* Original hue 286.3752 -> 250 */
--sidebar-border: oklch(0 0 0); /* No change, keep black */
--sidebar-ring: oklch(0.5797 0.1194 237.7893);
--radius: 0.5rem;
--shadow-2xs: 0 1px 3px 0px hsl(0 0% 0% / 0.05);
--shadow-xs: 0 1px 3px 0px hsl(0 0% 0% / 0.05);
--shadow-sm: 0 1px 3px 0px hsl(0 0% 0% / 0.1), 0 1px 2px -1px hsl(0 0% 0% / 0.1);
--shadow: 0 1px 3px 0px hsl(0 0% 0% / 0.1), 0 1px 2px -1px hsl(0 0% 0% / 0.1);
--shadow-md: 0 1px 3px 0px hsl(0 0% 0% / 0.1), 0 2px 4px -1px hsl(0 0% 0% / 0.1);
--shadow-lg: 0 1px 3px 0px hsl(0 0% 0% / 0.1), 0 4px 6px -1px hsl(0 0% 0% / 0.1);
--shadow-xl: 0 1px 3px 0px hsl(0 0% 0% / 0.1), 0 8px 10px -1px hsl(0 0% 0% / 0.1);
--shadow-2xl: 0 1px 3px 0px hsl(0 0% 0% / 0.25);
}
@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-heading: var(--heading);
--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-destructive-foreground: var(--destructive-foreground);
--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: var(--sidebar);
--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);
--shadow-2xs: var(--shadow-2xs);
--shadow-xs: var(--shadow-xs);
--shadow-sm: var(--shadow-sm);
--shadow: var(--shadow);
--shadow-md: var(--shadow-md);
--shadow-lg: var(--shadow-lg);
--shadow-xl: var(--shadow-xl);
--shadow-2xl: var(--shadow-2xl);
}
@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-destructive-foreground: var(--destructive-foreground);
--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: var(--sidebar);
--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);
--font-sans:
'Inter Variable', ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI',
Roboto, 'Helvetica Neue', Arial, 'Noto Sans', sans-serif, 'Apple Color Emoji', 'Segoe UI Emoji',
'Segoe UI Symbol', 'Noto Color Emoji';
--font-fake-proxima:
'Nunito Sans Variable', ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI',
Roboto, 'Helvetica Neue', Arial, 'Noto Sans', sans-serif, 'Apple Color Emoji', 'Segoe UI Emoji',
'Segoe UI Symbol', 'Noto Color Emoji';
--font-serif: 'Fraunces Variable', ui-serif, Georgia, Cambria, 'Times New Roman', Times, serif;
--font-mono:
'Geist Mono', ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, 'Liberation Mono',
'Courier New', monospace;
--radius-sm: calc(var(--radius) - 4px);
--radius-md: calc(var(--radius) - 2px);
--radius-lg: var(--radius);
--radius-xl: calc(var(--radius) + 4px);
--shadow-2xs: var(--shadow-2xs);
--shadow-xs: var(--shadow-xs);
--shadow-sm: var(--shadow-sm);
--shadow: var(--shadow);
--shadow-md: var(--shadow-md);
--shadow-lg: var(--shadow-lg);
--shadow-xl: var(--shadow-xl);
--shadow-2xl: var(--shadow-2xl);
}
@layer base {
* {
@apply border-border;
}
body {
@apply bg-background text-foreground;
}
}
/* For components that need horizontal scrolling */
.scrollbar-hide {
-ms-overflow-style: none; /* Internet Explorer and Edge */
scrollbar-width: none; /* Firefox */
}
.scrollbar-hide::-webkit-scrollbar {
display: none; /* Chrome, Safari, and Opera */
}
.animation-delay-0 {
animation-delay: 0s;
}
.animation-delay-100 {
animation-delay: 0.1s;
}
.animation-delay-200 {
animation-delay: 0.2s;
}
@layer components {
/* Modal is from DaisyUI */
.modal {
@apply pointer-events-none invisible fixed inset-0 m-0 grid h-full max-h-none w-full max-w-none items-center justify-items-center bg-transparent p-0 text-[inherit];
overflow-x: hidden;
transition:
translate 0.3s ease-out,
visibility 0.3s allow-discrete,
background-color 0.3s ease-out,
opacity 0.1s ease-out;
overflow-y: hidden;
overscroll-behavior: contain;
z-index: 999;
&::backdrop {
@apply hidden;
}
&.modal-open,
&[open],
&:target {
@apply pointer-events-auto visible opacity-100;
background-color: oklch(0% 0 0/ 0.4);
/* this cause glitch on Chrome */
/* transition:
translate 0.3s ease-out,
background-color 0.3s ease-out,
opacity 0.1s ease-out; */
.modal-box {
translate: 0 0;
scale: 1;
opacity: 1;
}
}
@starting-style {
&.modal-open,
&[open],
&:target {
@apply invisible opacity-0;
}
}
}
.modal-action {
@apply mt-6 flex justify-end gap-2;
}
.modal-toggle {
@apply fixed h-0 w-0 appearance-none opacity-0;
&:checked + .modal {
@apply pointer-events-auto visible opacity-100;
background-color: oklch(0% 0 0/ 0.4);
.modal-box {
translate: 0 0;
scale: 1;
opacity: 1;
}
}
@starting-style {
&:checked + .modal {
@apply invisible opacity-0;
}
}
}
.modal-backdrop {
@apply col-start-1 row-start-1 grid self-stretch justify-self-stretch text-transparent;
z-index: -1;
button {
@apply cursor-pointer;
}
}
.modal-box {
@apply bg-background border-border col-start-1 row-start-1 max-h-screen w-11/12 max-w-[32rem] p-6;
transition:
translate 0.3s ease-out,
scale 0.3s ease-out,
opacity 0.2s ease-out 0.05s,
box-shadow 0.3s ease-out;
border-radius: var(--radius);
scale: 95%;
opacity: 0;
box-shadow: oklch(0% 0 0/ 0.25) 0px 25px 50px -12px;
overflow-y: auto;
overscroll-behavior: contain;
}
.modal-top {
@apply place-items-start;
:where(.modal-box) {
@apply h-auto w-full max-w-none;
max-height: calc(100vh - 5em);
translate: 0 -100%;
scale: 1;
--modal-tl: 0;
--modal-tr: 0;
--modal-bl: var(--radius-box);
--modal-br: var(--radius-box);
}
}
.modal-middle {
@apply place-items-center;
:where(.modal-box) {
@apply h-auto w-11/12 max-w-[32rem];
max-height: calc(100vh - 5em);
translate: 0 2%;
scale: 98%;
--modal-tl: var(--radius-box);
--modal-tr: var(--radius-box);
--modal-bl: var(--radius-box);
--modal-br: var(--radius-box);
}
}
.modal-bottom {
@apply place-items-end;
:where(.modal-box) {
@apply h-auto w-full max-w-none;
max-height: calc(100vh - 5em);
translate: 0 100%;
scale: 1;
--modal-tl: var(--radius-box);
--modal-tr: var(--radius-box);
--modal-bl: 0;
--modal-br: 0;
}
}
.modal-start {
@apply place-items-start;
:where(.modal-box) {
@apply h-screen max-h-none w-auto max-w-none;
translate: -100% 0;
scale: 1;
--modal-tl: 0;
--modal-tr: var(--radius-box);
--modal-bl: 0;
--modal-br: var(--radius-box);
}
}
.modal-end {
@apply place-items-end;
:where(.modal-box) {
@apply h-screen max-h-none w-auto max-w-none;
translate: 100% 0;
scale: 1;
--modal-tl: var(--radius-box);
--modal-tr: 0;
--modal-bl: var(--radius-box);
--modal-br: 0;
}
}
/* Border reflect from t3 */
.button-reflect {
/* Derived from dark primary: oklch(0.5797 0.1194 237.7893) */
--min: oklch(0.5797 0.1194 237.7893 / 0.25) !important; /* Lighter, more transparent */
--max: oklch(0.5797 0.1194 237.7893 / 0.7) !important; /* Slightly more saturated */
--start: #000000d9 !important;
}
.border-reflect {
/* Derived from dark primary: oklch(0.5797 0.1194 237.7893) */
--c: 237.7893 11.94% 57.97%; /* Using the hue, chroma, and lightness from dark primary */
--min: hsl(from var(--primary) h c l / 0.2);
--max: hsl(from var(--primary) h c l / 1);
--gradientBorder-gradient:
linear-gradient(180deg, var(--min), var(--max), var(--min)),
linear-gradient(15deg, var(--min) 50%, var(--max));
--opacity: 1;
--start: rgba(0, 0, 0, 0.85);
position: relative;
}
.boring-dark .border-reflect,
.dark .border-reflect {
/* Derived from dark primary: oklch(0.5797 0.1194 237.7893) */
--gradientBorder-gradient:
linear-gradient(
180deg,
oklch(0.5797 0.1194 237.7893 / 0),
oklch(0.5797 0.1194 237.7893 / 0.74),
oklch(0.5797 0.1194 237.7893 / 0.09)
),
linear-gradient(
15deg,
oklch(0.5797 0.1194 237.7893 / 0.12),
oklch(0.5797 0.1194 237.7893 / 0.74)
);
--start: rgba(0, 0, 0, 0.92);
}
.border-reflect:before {
content: '';
pointer-events: none;
-webkit-user-select: none;
-moz-user-select: none;
-ms-user-select: none;
user-select: none;
position: absolute;
inset: 0;
border-radius: inherit;
padding: var(--gradientBorder-size, 1px);
background: var(--gradientBorder-gradient);
-webkit-mask:
linear-gradient(var(--start), #000) content-box,
linear-gradient(var(--start), #000);
mask:
linear-gradient(var(--start), #000) content-box,
linear-gradient(var(--start), #000);
-webkit-mask-composite: xor;
mask-composite: exclude;
opacity: var(--opacity, 1);
}
}
@utility abs-y-center {
top: 50%;
transform: translateY(-50%);
}
@utility abs-x-center {
left: 50%;
transform: translateX(-50%);
}