@cascivo/react 0.10.1 → 0.11.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +44 -11
- package/dist/index.d.ts +53 -22
- package/dist/node/react/src/index.js +3 -3
- package/dist/node/react/src/theme.js +37 -24
- package/dist/react/src/index.js +3 -3
- package/dist/react/src/theme.js +37 -24
- package/dist/styles.css +766 -0
- package/package.json +6 -5
- package/readme.body.md +43 -10
package/dist/styles.css
CHANGED
|
@@ -36,6 +36,772 @@
|
|
|
36
36
|
*/
|
|
37
37
|
@layer cascivo.reset, cascivo.base, cascivo.tokens, cascivo.component, cascivo.theme, cascivo.blocks,
|
|
38
38
|
cascivo.override;
|
|
39
|
+
/* packages/tokens/src/index.css */
|
|
40
|
+
/* cascivo Design System — Primitive Tokens */
|
|
41
|
+
/* These are raw values. Never use directly in components. Use semantic tokens. */
|
|
42
|
+
|
|
43
|
+
/* Establish the canonical cascade-layer order before any layered rule. Every
|
|
44
|
+
consumer path imports @cascivo/tokens (directly or via a theme), so this rides
|
|
45
|
+
along first and dedupes by URL. See ./layers.css for the authoritative order. */
|
|
46
|
+
|
|
47
|
+
@layer cascivo.tokens {
|
|
48
|
+
:root {
|
|
49
|
+
/* ── Color Primitives ─────────────────────────────── */
|
|
50
|
+
|
|
51
|
+
/* Gray (near-achromatic, hue ≈ 264) */
|
|
52
|
+
--cascivo-gray-0: oklch(1 0 0);
|
|
53
|
+
--cascivo-gray-50: oklch(0.985 0.002 264);
|
|
54
|
+
--cascivo-gray-100: oklch(0.967 0.003 264);
|
|
55
|
+
--cascivo-gray-200: oklch(0.928 0.006 264);
|
|
56
|
+
--cascivo-gray-300: oklch(0.872 0.008 264);
|
|
57
|
+
--cascivo-gray-400: oklch(0.707 0.015 264);
|
|
58
|
+
--cascivo-gray-500: oklch(0.554 0.018 264);
|
|
59
|
+
--cascivo-gray-600: oklch(0.446 0.018 264);
|
|
60
|
+
--cascivo-gray-700: oklch(0.373 0.015 264);
|
|
61
|
+
--cascivo-gray-800: oklch(0.269 0.01 264);
|
|
62
|
+
--cascivo-gray-900: oklch(0.205 0.007 264);
|
|
63
|
+
--cascivo-gray-950: oklch(0.145 0.005 264);
|
|
64
|
+
|
|
65
|
+
/* Blue / accent (hue ≈ 250) */
|
|
66
|
+
--cascivo-blue-50: oklch(0.97 0.025 250);
|
|
67
|
+
--cascivo-blue-100: oklch(0.932 0.055 250);
|
|
68
|
+
--cascivo-blue-200: oklch(0.882 0.095 250);
|
|
69
|
+
--cascivo-blue-300: oklch(0.808 0.14 250);
|
|
70
|
+
--cascivo-blue-400: oklch(0.707 0.18 250);
|
|
71
|
+
--cascivo-blue-500: oklch(0.623 0.214 250);
|
|
72
|
+
--cascivo-blue-600: oklch(0.546 0.224 250);
|
|
73
|
+
--cascivo-blue-700: oklch(0.452 0.196 250);
|
|
74
|
+
--cascivo-blue-800: oklch(0.373 0.155 250);
|
|
75
|
+
--cascivo-blue-900: oklch(0.29 0.105 250);
|
|
76
|
+
--cascivo-blue-950: oklch(0.205 0.065 250);
|
|
77
|
+
|
|
78
|
+
/* Green (hue ≈ 145) */
|
|
79
|
+
--cascivo-green-50: oklch(0.982 0.018 145);
|
|
80
|
+
--cascivo-green-100: oklch(0.962 0.044 145);
|
|
81
|
+
--cascivo-green-200: oklch(0.925 0.084 145);
|
|
82
|
+
--cascivo-green-400: oklch(0.75 0.15 145);
|
|
83
|
+
--cascivo-green-500: oklch(0.648 0.15 145);
|
|
84
|
+
--cascivo-green-600: oklch(0.548 0.14 145);
|
|
85
|
+
--cascivo-green-700: oklch(0.448 0.12 145);
|
|
86
|
+
--cascivo-green-900: oklch(0.28 0.075 145);
|
|
87
|
+
|
|
88
|
+
/* Red (hue ≈ 22) */
|
|
89
|
+
--cascivo-red-50: oklch(0.971 0.013 22);
|
|
90
|
+
--cascivo-red-100: oklch(0.936 0.032 22);
|
|
91
|
+
--cascivo-red-200: oklch(0.885 0.062 22);
|
|
92
|
+
--cascivo-red-400: oklch(0.72 0.16 22);
|
|
93
|
+
--cascivo-red-500: oklch(0.628 0.188 22);
|
|
94
|
+
--cascivo-red-600: oklch(0.54 0.188 22);
|
|
95
|
+
--cascivo-red-700: oklch(0.448 0.17 22);
|
|
96
|
+
--cascivo-red-900: oklch(0.28 0.1 22);
|
|
97
|
+
|
|
98
|
+
/* Orange (hue ≈ 40) */
|
|
99
|
+
--cascivo-orange-50: oklch(0.98 0.02 75);
|
|
100
|
+
--cascivo-orange-100: oklch(0.96 0.045 75);
|
|
101
|
+
--cascivo-orange-400: oklch(0.82 0.13 60);
|
|
102
|
+
--cascivo-orange-500: oklch(0.768 0.145 55);
|
|
103
|
+
--cascivo-orange-600: oklch(0.68 0.155 50);
|
|
104
|
+
|
|
105
|
+
/* Yellow / amber (hue ≈ 75) */
|
|
106
|
+
--cascivo-yellow-50: oklch(0.987 0.026 95);
|
|
107
|
+
--cascivo-yellow-100: oklch(0.973 0.05 95);
|
|
108
|
+
--cascivo-yellow-400: oklch(0.868 0.145 80);
|
|
109
|
+
--cascivo-yellow-500: oklch(0.768 0.145 75);
|
|
110
|
+
|
|
111
|
+
/* Warm neutrals */
|
|
112
|
+
--cascivo-warm-50: oklch(0.982 0.008 80);
|
|
113
|
+
--cascivo-warm-100: oklch(0.962 0.016 80);
|
|
114
|
+
--cascivo-warm-200: oklch(0.92 0.025 78);
|
|
115
|
+
--cascivo-warm-300: oklch(0.87 0.035 75);
|
|
116
|
+
--cascivo-warm-400: oklch(0.76 0.045 70);
|
|
117
|
+
--cascivo-warm-500: oklch(0.64 0.045 65);
|
|
118
|
+
--cascivo-warm-600: oklch(0.52 0.04 60);
|
|
119
|
+
--cascivo-warm-700: oklch(0.42 0.03 55);
|
|
120
|
+
--cascivo-warm-800: oklch(0.31 0.022 50);
|
|
121
|
+
--cascivo-warm-900: oklch(0.21 0.015 50);
|
|
122
|
+
|
|
123
|
+
/* ── Spacing ──────────────────────────────────────── */
|
|
124
|
+
--cascivo-space-0: 0px;
|
|
125
|
+
--cascivo-space-1: 0.25rem; /* 4px */
|
|
126
|
+
--cascivo-space-2: 0.5rem; /* 8px */
|
|
127
|
+
--cascivo-space-3: 0.75rem; /* 12px */
|
|
128
|
+
--cascivo-space-4: 1rem; /* 16px */
|
|
129
|
+
--cascivo-space-5: 1.25rem; /* 20px */
|
|
130
|
+
--cascivo-space-6: 1.5rem; /* 24px */
|
|
131
|
+
--cascivo-space-8: 2rem; /* 32px */
|
|
132
|
+
--cascivo-space-10: 2.5rem; /* 40px */
|
|
133
|
+
--cascivo-space-12: 3rem; /* 48px */
|
|
134
|
+
--cascivo-space-16: 4rem; /* 64px */
|
|
135
|
+
--cascivo-space-20: 5rem; /* 80px */
|
|
136
|
+
--cascivo-space-24: 6rem; /* 96px */
|
|
137
|
+
|
|
138
|
+
/* ── Typography ───────────────────────────────────── */
|
|
139
|
+
--cascivo-font-sans:
|
|
140
|
+
ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
|
|
141
|
+
--cascivo-font-mono: ui-monospace, SFMono-Regular, 'SF Mono', Menlo, Consolas, monospace;
|
|
142
|
+
/* Display = the headline/brand face a theme may override (terminal, brutalist,
|
|
143
|
+
arcade …). Defaults to the sans stack, so themes that do not override it look
|
|
144
|
+
unchanged. sans/mono remain the body/code defaults. Per-theme overrides live in
|
|
145
|
+
each theme file (declared in all themes to satisfy token parity). */
|
|
146
|
+
--cascivo-font-display: var(--cascivo-font-sans);
|
|
147
|
+
|
|
148
|
+
--cascivo-text-xs: 0.75rem; /* 12px */
|
|
149
|
+
--cascivo-text-sm: 0.875rem; /* 14px */
|
|
150
|
+
--cascivo-text-base: 1rem; /* 16px */
|
|
151
|
+
--cascivo-text-lg: 1.125rem; /* 18px */
|
|
152
|
+
--cascivo-text-xl: 1.25rem; /* 20px */
|
|
153
|
+
--cascivo-text-2xl: 1.5rem; /* 24px */
|
|
154
|
+
--cascivo-text-3xl: 1.875rem; /* 30px */
|
|
155
|
+
--cascivo-text-4xl: 2.25rem; /* 36px */
|
|
156
|
+
|
|
157
|
+
--cascivo-font-normal: 400;
|
|
158
|
+
--cascivo-font-medium: 500;
|
|
159
|
+
--cascivo-font-semibold: 600;
|
|
160
|
+
--cascivo-font-bold: 700;
|
|
161
|
+
|
|
162
|
+
--cascivo-leading-none: 1;
|
|
163
|
+
--cascivo-leading-tight: 1.25;
|
|
164
|
+
--cascivo-leading-snug: 1.375;
|
|
165
|
+
--cascivo-leading-normal: 1.5;
|
|
166
|
+
--cascivo-leading-relaxed: 1.625;
|
|
167
|
+
|
|
168
|
+
--cascivo-tracking-tight: -0.025em;
|
|
169
|
+
--cascivo-tracking-normal: 0em;
|
|
170
|
+
--cascivo-tracking-wide: 0.025em;
|
|
171
|
+
|
|
172
|
+
/* ── Typography roles (semantic) ───────────────────
|
|
173
|
+
Purpose-named type tokens. Each resolves to exactly ONE primitive size
|
|
174
|
+
above, so "what size is a button label?" has exactly one answer:
|
|
175
|
+
--cascivo-text-ui. These tokens carry size only; pair them with the
|
|
176
|
+
recommended weight/leading in docs/cookbooks/derivable-theming.md. */
|
|
177
|
+
--cascivo-text-display: var(--cascivo-text-4xl); /* hero / marketing display */
|
|
178
|
+
--cascivo-text-heading-lg: var(--cascivo-text-3xl); /* page title (h1) */
|
|
179
|
+
--cascivo-text-heading-md: var(--cascivo-text-2xl); /* section heading (h2) */
|
|
180
|
+
--cascivo-text-heading-sm: var(--cascivo-text-xl); /* subsection heading (h3) */
|
|
181
|
+
--cascivo-text-body: var(--cascivo-text-base); /* default body copy */
|
|
182
|
+
--cascivo-text-body-sm: var(--cascivo-text-sm); /* secondary / dense body copy */
|
|
183
|
+
--cascivo-text-ui: var(
|
|
184
|
+
--cascivo-text-sm
|
|
185
|
+
); /* control & button labels (the canonical "ui.default") */
|
|
186
|
+
--cascivo-text-label: var(--cascivo-text-sm); /* form field labels */
|
|
187
|
+
--cascivo-text-caption: var(--cascivo-text-xs); /* captions, helper text, metadata */
|
|
188
|
+
--cascivo-text-code: var(
|
|
189
|
+
--cascivo-text-sm
|
|
190
|
+
); /* inline code / mono (pair with --cascivo-font-mono) */
|
|
191
|
+
|
|
192
|
+
/* ── Border Radius — Primitive ───────────────────── */
|
|
193
|
+
--cascivo-radius-none: 0px;
|
|
194
|
+
--cascivo-radius-sm: 0.25rem; /* 4px */
|
|
195
|
+
--cascivo-radius-md: 0.375rem; /* 6px */
|
|
196
|
+
--cascivo-radius-lg: 0.5rem; /* 8px */
|
|
197
|
+
--cascivo-radius-xl: 0.75rem; /* 12px */
|
|
198
|
+
--cascivo-radius-2xl: 1rem; /* 16px */
|
|
199
|
+
--cascivo-radius-full: 9999px;
|
|
200
|
+
|
|
201
|
+
/* ── Border Radius — Semantic (one-knob; themes retune --cascivo-radius-base only) ── */
|
|
202
|
+
--cascivo-radius-base: 0.375rem; /* 6px controls */
|
|
203
|
+
--cascivo-radius-control: var(--cascivo-radius-base);
|
|
204
|
+
--cascivo-radius-field: var(--cascivo-radius-base);
|
|
205
|
+
--cascivo-radius-item: calc(var(--cascivo-radius-base) * 0.66); /* ~4px menu/list rows */
|
|
206
|
+
--cascivo-radius-surface: calc(var(--cascivo-radius-base) * 1.66); /* ~10px cards */
|
|
207
|
+
--cascivo-radius-overlay: calc(var(--cascivo-radius-base) * 2); /* ~12px modals/popovers */
|
|
208
|
+
--cascivo-radius-indicator: calc(var(--cascivo-radius-base) / 2);
|
|
209
|
+
|
|
210
|
+
/* ── Interaction state opacity (HeroUI layout-token parity; themes may retune) ── */
|
|
211
|
+
--cascivo-disabled-opacity: 0.5;
|
|
212
|
+
--cascivo-hover-opacity: 0.8;
|
|
213
|
+
|
|
214
|
+
/* ── Shadows — rationed: surfaces flat/xs, floating layers get ONE soft shadow ── */
|
|
215
|
+
--cascivo-shadow-xs: 0 1px 2px oklch(0 0 0 / 0.05);
|
|
216
|
+
--cascivo-shadow-sm: 0 1px 3px oklch(0 0 0 / 0.07), 0 1px 2px oklch(0 0 0 / 0.04);
|
|
217
|
+
--cascivo-shadow-md: 0 2px 8px oklch(0 0 0 / 0.07), 0 1px 2px oklch(0 0 0 / 0.04);
|
|
218
|
+
--cascivo-shadow-overlay: 0 4px 32px oklch(0 0 0 / 0.16), 0 0 0 1px oklch(0 0 0 / 0.04);
|
|
219
|
+
/* legacy aliases — keep existing component CSS working */
|
|
220
|
+
--cascivo-shadow-lg: var(--cascivo-shadow-overlay);
|
|
221
|
+
--cascivo-shadow-xl: var(--cascivo-shadow-overlay);
|
|
222
|
+
|
|
223
|
+
/* ── Focus Ring — soft halo (≥3:1 contrast) ──────── */
|
|
224
|
+
--cascivo-ring-width: 3px;
|
|
225
|
+
--cascivo-ring-offset: 0px;
|
|
226
|
+
--cascivo-ring-color: color-mix(
|
|
227
|
+
in oklch,
|
|
228
|
+
var(--cascivo-color-accent, oklch(0.623 0.214 250)) 55%,
|
|
229
|
+
transparent
|
|
230
|
+
);
|
|
231
|
+
|
|
232
|
+
/* ── Primary — semantic defaults (themes override) ── */
|
|
233
|
+
--cascivo-color-primary: oklch(0.205 0 0);
|
|
234
|
+
--cascivo-color-primary-fg: oklch(0.985 0 0);
|
|
235
|
+
--cascivo-color-primary-hover: oklch(0.27 0 0);
|
|
236
|
+
--cascivo-color-primary-active: oklch(0.32 0 0);
|
|
237
|
+
--cascivo-color-active-bg: oklch(0.145 0.005 264 / 6%);
|
|
238
|
+
|
|
239
|
+
/* ── Density Controls ────────────────────────────── */
|
|
240
|
+
/* Button is the height reference — all interactive controls derive from these. */
|
|
241
|
+
/* Coarse pointer: use --cascivo-target-min-coarse (2.75rem/44px) via min-block-size. */
|
|
242
|
+
--cascivo-control-height-sm: 2rem; /* 32px — Button sm */
|
|
243
|
+
--cascivo-control-height-md: 2.5rem; /* 40px — Button md */
|
|
244
|
+
--cascivo-control-height-lg: 3rem; /* 48px — Button lg */
|
|
245
|
+
|
|
246
|
+
/* ── Semantic Borders ────────────────────────────── */
|
|
247
|
+
--cascivo-border-subtle: oklch(0.928 0.006 264);
|
|
248
|
+
--cascivo-border-default: oklch(0.872 0.008 264);
|
|
249
|
+
--cascivo-border-strong: oklch(0.707 0.015 264);
|
|
250
|
+
|
|
251
|
+
/* ── Animation ────────────────────────────────────── */
|
|
252
|
+
--cascivo-ease-in: cubic-bezier(0.4, 0, 1, 1);
|
|
253
|
+
--cascivo-ease-out: cubic-bezier(0, 0, 0.2, 1);
|
|
254
|
+
--cascivo-ease-in-out: cubic-bezier(0.4, 0, 0.2, 1);
|
|
255
|
+
--cascivo-duration-75: 75ms;
|
|
256
|
+
--cascivo-duration-100: 100ms;
|
|
257
|
+
--cascivo-duration-150: 150ms;
|
|
258
|
+
--cascivo-duration-200: 200ms;
|
|
259
|
+
--cascivo-duration-300: 300ms;
|
|
260
|
+
--cascivo-duration-500: 500ms;
|
|
261
|
+
|
|
262
|
+
/* Semantic motion — components reference intent, themes tune character */
|
|
263
|
+
--cascivo-motion-enter: var(--cascivo-duration-200) var(--cascivo-ease-out);
|
|
264
|
+
--cascivo-motion-exit: var(--cascivo-duration-150) var(--cascivo-ease-in);
|
|
265
|
+
--cascivo-motion-emphasis: var(--cascivo-duration-300) var(--cascivo-ease-in-out);
|
|
266
|
+
|
|
267
|
+
/* ── Chart Categorical Color Ramp ───────────────── */
|
|
268
|
+
--cascivo-chart-1: oklch(0.74 0.13 70); /* Okabe-Ito orange #E69F00 */
|
|
269
|
+
--cascivo-chart-2: oklch(0.74 0.11 240); /* Okabe-Ito sky blue #56B4E9 */
|
|
270
|
+
--cascivo-chart-3: oklch(0.66 0.13 165); /* Okabe-Ito bluish green #009E73 */
|
|
271
|
+
--cascivo-chart-4: oklch(0.93 0.16 100); /* Okabe-Ito yellow #F0E442 */
|
|
272
|
+
--cascivo-chart-5: oklch(0.5 0.13 250); /* Okabe-Ito blue #0072B2 */
|
|
273
|
+
--cascivo-chart-6: oklch(0.6 0.16 40); /* Okabe-Ito vermillion #D55E00 */
|
|
274
|
+
--cascivo-chart-7: oklch(0.66 0.12 350); /* Okabe-Ito reddish purple #CC79A7 */
|
|
275
|
+
--cascivo-chart-8: oklch(0.55 0.02 280); /* neutral grey (screen adaptation) */
|
|
276
|
+
--cascivo-chart-grid: var(--cascivo-gray-200);
|
|
277
|
+
--cascivo-chart-axis: var(--cascivo-gray-400);
|
|
278
|
+
/* Opacity of a solid area-chart fill over the surface. Light/warm surfaces are
|
|
279
|
+
near-white, so 0.25 reads as a clean tint; the dark theme raises this so the
|
|
280
|
+
fill keeps its hue instead of muddying into the dark surface. */
|
|
281
|
+
--cascivo-chart-fill-opacity: 0.25;
|
|
282
|
+
|
|
283
|
+
/* ── Code Editor (@cascivo/editor) ──────────────────────────
|
|
284
|
+
Defined once here, not per-theme, to keep theme token parity. Chrome and
|
|
285
|
+
the syntax palette reference theme-overridden semantic/chart tokens, so
|
|
286
|
+
they adapt across light/dark/warm (and every theme) automatically; the
|
|
287
|
+
literal fallbacks keep a theme-less `@cascivo/editor` import readable. */
|
|
288
|
+
|
|
289
|
+
/* Chrome */
|
|
290
|
+
--cascivo-editor-bg: var(--cascivo-color-surface, oklch(0.985 0.002 264));
|
|
291
|
+
--cascivo-editor-fg: var(--cascivo-color-foreground, oklch(0.205 0.005 264));
|
|
292
|
+
--cascivo-editor-gutter-bg: var(--cascivo-color-surface-2, oklch(0.967 0.003 264));
|
|
293
|
+
--cascivo-editor-gutter-fg: var(--cascivo-color-text-muted, oklch(0.55 0.018 264));
|
|
294
|
+
--cascivo-editor-current-line: var(--cascivo-color-active-bg, oklch(0.55 0.02 264 / 8%));
|
|
295
|
+
--cascivo-editor-selection: var(--cascivo-color-accent-muted, oklch(0.882 0.095 250));
|
|
296
|
+
--cascivo-editor-border: var(--cascivo-color-border, oklch(0.928 0.006 264));
|
|
297
|
+
|
|
298
|
+
/* Syntax palette — one token per TokenKind. String/number/type/property (and
|
|
299
|
+
their aliases regexp/attr/boolean) are pinned to text-safe darker values
|
|
300
|
+
instead of the raw chart hues, which are tuned for 3:1 fills and fall below
|
|
301
|
+
WCAG AA 4.5:1 as code text on the light editor surface. Dark-surface themes
|
|
302
|
+
restore the brighter chart hues below (they clear 4.5:1 on a dark bg). */
|
|
303
|
+
--cascivo-editor-syntax-keyword: var(--cascivo-color-accent, oklch(0.52 0.2 250));
|
|
304
|
+
--cascivo-editor-syntax-string: oklch(0.53 0.13 135);
|
|
305
|
+
--cascivo-editor-syntax-number: oklch(0.54 0.15 40);
|
|
306
|
+
--cascivo-editor-syntax-comment: var(--cascivo-color-foreground-muted, oklch(0.55 0.018 264));
|
|
307
|
+
--cascivo-editor-syntax-function: var(--cascivo-chart-5, oklch(0.5 0.16 265));
|
|
308
|
+
--cascivo-editor-syntax-type: oklch(0.54 0.12 350);
|
|
309
|
+
--cascivo-editor-syntax-operator: var(--cascivo-color-foreground-muted, oklch(0.5 0.04 264));
|
|
310
|
+
--cascivo-editor-syntax-punctuation: var(--cascivo-color-text-subtle, oklch(0.446 0.018 264));
|
|
311
|
+
--cascivo-editor-syntax-variable: var(--cascivo-editor-fg);
|
|
312
|
+
--cascivo-editor-syntax-tag: var(--cascivo-color-accent, oklch(0.52 0.2 250));
|
|
313
|
+
--cascivo-editor-syntax-attr: oklch(0.54 0.15 40);
|
|
314
|
+
--cascivo-editor-syntax-regexp: oklch(0.53 0.13 135);
|
|
315
|
+
--cascivo-editor-syntax-boolean: oklch(0.54 0.15 40);
|
|
316
|
+
--cascivo-editor-syntax-property: oklch(0.53 0.12 240);
|
|
317
|
+
|
|
318
|
+
/* ── Brand (apps/logo/OG only — never used in component CSS) ── */
|
|
319
|
+
--cascivo-brand-primary: oklch(
|
|
320
|
+
0.55 0.15 240
|
|
321
|
+
); /* cascade blue — hero, CTA, logo gradient start */
|
|
322
|
+
--cascivo-brand-accent: oklch(0.72 0.13 195); /* flow teal — gradient end, accents */
|
|
323
|
+
--cascivo-brand-ink: oklch(
|
|
324
|
+
0.22 0.03 250
|
|
325
|
+
); /* near-black cool — wordmark, body on brand surface */
|
|
326
|
+
--cascivo-brand-paper: oklch(0.99 0.005 250); /* off-white brand surface */
|
|
327
|
+
--cascivo-brand-gradient-start: oklch(0.55 0.15 240);
|
|
328
|
+
--cascivo-brand-gradient-end: oklch(0.72 0.13 195);
|
|
329
|
+
|
|
330
|
+
/* ── Z-Index ──────────────────────────────────────── */
|
|
331
|
+
--cascivo-z-base: 0;
|
|
332
|
+
--cascivo-z-raised: 10;
|
|
333
|
+
--cascivo-z-dropdown: 100;
|
|
334
|
+
--cascivo-z-overlay: 200;
|
|
335
|
+
--cascivo-z-modal: 300;
|
|
336
|
+
--cascivo-z-toast: 400;
|
|
337
|
+
--cascivo-z-tooltip: 500;
|
|
338
|
+
|
|
339
|
+
/* ── Shell ──────────────────────────────────────────── */
|
|
340
|
+
--cascivo-shell-header-block-size: 3rem;
|
|
341
|
+
--cascivo-shell-panel-inline-size: 20rem;
|
|
342
|
+
--cascivo-shell-aside-inline-size: 18rem;
|
|
343
|
+
|
|
344
|
+
/* ── Breakpoint Scale ────────────────────────────── */
|
|
345
|
+
/* Breakpoints are a lint-guarded constant. Use these exact values in @media/@container; */
|
|
346
|
+
/* do NOT invent off-scale widths. @media/@container CANNOT read these custom properties — */
|
|
347
|
+
/* copy the numeric value. Canonical scale: sm=30rem md=40rem lg=64rem xl=80rem */
|
|
348
|
+
/* Lint: scripts/checks/breakpoint.test.ts — added in v20-t2. */
|
|
349
|
+
--cascivo-screen-sm: 30rem; /* 480px — small phone/narrow viewport */
|
|
350
|
+
--cascivo-screen-md: 40rem; /* 640px — tablet/wide phone (load-bearing: columns/grid/header) */
|
|
351
|
+
--cascivo-screen-lg: 64rem; /* 1024px — desktop (load-bearing: app-shell drawer) */
|
|
352
|
+
--cascivo-screen-xl: 80rem; /* 1280px — wide desktop */
|
|
353
|
+
|
|
354
|
+
/* ── Fluid Typography ────────────────────────────── */
|
|
355
|
+
/* Additive fluid variants — fixed tokens are preserved as the static fallback. */
|
|
356
|
+
/* clamp(min, vw-slope, max) where max = current fixed value so desktop ceiling is frozen. */
|
|
357
|
+
--cascivo-text-2xl-fluid: clamp(1.25rem, 1rem + 1.25vw, 1.5rem); /* 20→24px */
|
|
358
|
+
--cascivo-text-3xl-fluid: clamp(1.5rem, 1.125rem + 1.875vw, 1.875rem); /* 24→30px */
|
|
359
|
+
--cascivo-text-4xl-fluid: clamp(1.875rem, 1.5rem + 1.875vw, 2.25rem); /* 30→36px */
|
|
360
|
+
|
|
361
|
+
/* ── Coarse-pointer touch target ─────────────────── */
|
|
362
|
+
/* Controls should reach this minimum under @media (pointer: coarse) — added in v20-t3. */
|
|
363
|
+
--cascivo-target-min-coarse: 2.75rem; /* 44px — Apple HIG comfortable touch target */
|
|
364
|
+
}
|
|
365
|
+
|
|
366
|
+
/* Dark-surface themes: restore the brighter chart hues for editor syntax, which
|
|
367
|
+
clear WCAG AA 4.5:1 on a dark editor background (the light-theme darkened
|
|
368
|
+
literals above would be too low-contrast there). */
|
|
369
|
+
[data-theme='dark'],
|
|
370
|
+
[data-theme='midnight'],
|
|
371
|
+
[data-theme='terminal'],
|
|
372
|
+
[data-theme='cyberpunk'] {
|
|
373
|
+
--cascivo-editor-syntax-string: var(--cascivo-chart-3);
|
|
374
|
+
--cascivo-editor-syntax-regexp: var(--cascivo-chart-3);
|
|
375
|
+
--cascivo-editor-syntax-number: var(--cascivo-chart-6);
|
|
376
|
+
--cascivo-editor-syntax-attr: var(--cascivo-chart-6);
|
|
377
|
+
--cascivo-editor-syntax-boolean: var(--cascivo-chart-6);
|
|
378
|
+
--cascivo-editor-syntax-type: var(--cascivo-chart-7);
|
|
379
|
+
--cascivo-editor-syntax-property: var(--cascivo-chart-2);
|
|
380
|
+
}
|
|
381
|
+
|
|
382
|
+
/* All cascade motion derives from the duration tokens, so collapsing them
|
|
383
|
+
disables every transition/animation library-wide. Continuous progress
|
|
384
|
+
indicators (Spinner) use literal durations and opt out deliberately. */
|
|
385
|
+
@media (prefers-reduced-motion: reduce) {
|
|
386
|
+
:root {
|
|
387
|
+
--cascivo-duration-75: 0.01ms;
|
|
388
|
+
--cascivo-duration-100: 0.01ms;
|
|
389
|
+
--cascivo-duration-150: 0.01ms;
|
|
390
|
+
--cascivo-duration-200: 0.01ms;
|
|
391
|
+
--cascivo-duration-300: 0.01ms;
|
|
392
|
+
--cascivo-duration-500: 0.01ms;
|
|
393
|
+
}
|
|
394
|
+
}
|
|
395
|
+
}
|
|
396
|
+
|
|
397
|
+
/*
|
|
398
|
+
* CSS @function helpers (--cascivo-step / --cascivo-scale) are NOT imported here.
|
|
399
|
+
* They are a Chrome-133+ progressive-enhancement pilot and are unparseable by
|
|
400
|
+
* current CSS minifiers (lightningcss / Tailwind v4), which choke on `@function`
|
|
401
|
+
* and drop the rule. Every call site ships a static fallback, so omitting them is
|
|
402
|
+
* always correct. Opt in explicitly if your build pipeline supports @function:
|
|
403
|
+
* import '@cascivo/tokens/functions.css'
|
|
404
|
+
*/
|
|
405
|
+
|
|
406
|
+
/* packages/tokens/src/properties.css */
|
|
407
|
+
/* cascivo — @property registrations for themeable color custom properties.
|
|
408
|
+
*
|
|
409
|
+
* Registering the themeable color tokens as typed custom properties (<color>,
|
|
410
|
+
* inherits) buys two things:
|
|
411
|
+
* 1. Smooth interpolation when [data-theme] changes under a transition.
|
|
412
|
+
* 2. A typed substrate for future @container style() palette branching.
|
|
413
|
+
*
|
|
414
|
+
* Only *themeable* color props are registered (the values a theme overrides or
|
|
415
|
+
* that animate), not the whole primitive scale. Registration sets the property
|
|
416
|
+
* type + initial value; theme blocks still override the value as usual.
|
|
417
|
+
*
|
|
418
|
+
* Imported by @cascivo/themes/all.css (and safe to import standalone). @property
|
|
419
|
+
* is a top-level at-rule and intentionally lives outside @layer.
|
|
420
|
+
*/
|
|
421
|
+
|
|
422
|
+
@property --cascivo-color-accent {
|
|
423
|
+
syntax: '<color>';
|
|
424
|
+
inherits: true;
|
|
425
|
+
initial-value: oklch(0.52 0.2 250);
|
|
426
|
+
}
|
|
427
|
+
@property --cascivo-color-accent-hover {
|
|
428
|
+
syntax: '<color>';
|
|
429
|
+
inherits: true;
|
|
430
|
+
initial-value: oklch(0.45 0.2 250);
|
|
431
|
+
}
|
|
432
|
+
@property --cascivo-color-accent-active {
|
|
433
|
+
syntax: '<color>';
|
|
434
|
+
inherits: true;
|
|
435
|
+
initial-value: oklch(0.373 0.155 250);
|
|
436
|
+
}
|
|
437
|
+
@property --cascivo-color-primary {
|
|
438
|
+
syntax: '<color>';
|
|
439
|
+
inherits: true;
|
|
440
|
+
initial-value: oklch(0.205 0 0);
|
|
441
|
+
}
|
|
442
|
+
@property --cascivo-color-primary-hover {
|
|
443
|
+
syntax: '<color>';
|
|
444
|
+
inherits: true;
|
|
445
|
+
initial-value: oklch(0.27 0 0);
|
|
446
|
+
}
|
|
447
|
+
@property --cascivo-color-primary-active {
|
|
448
|
+
syntax: '<color>';
|
|
449
|
+
inherits: true;
|
|
450
|
+
initial-value: oklch(0.32 0 0);
|
|
451
|
+
}
|
|
452
|
+
@property --cascivo-color-secondary {
|
|
453
|
+
syntax: '<color>';
|
|
454
|
+
inherits: true;
|
|
455
|
+
initial-value: oklch(0.92 0.004 264);
|
|
456
|
+
}
|
|
457
|
+
@property --cascivo-color-secondary-hover {
|
|
458
|
+
syntax: '<color>';
|
|
459
|
+
inherits: true;
|
|
460
|
+
initial-value: oklch(0.86 0.006 264);
|
|
461
|
+
}
|
|
462
|
+
@property --cascivo-color-destructive {
|
|
463
|
+
syntax: '<color>';
|
|
464
|
+
inherits: true;
|
|
465
|
+
initial-value: oklch(0.54 0.188 22);
|
|
466
|
+
}
|
|
467
|
+
@property --cascivo-color-destructive-hover {
|
|
468
|
+
syntax: '<color>';
|
|
469
|
+
inherits: true;
|
|
470
|
+
initial-value: oklch(0.448 0.17 22);
|
|
471
|
+
}
|
|
472
|
+
@property --cascivo-color-text-on-accent {
|
|
473
|
+
syntax: '<color>';
|
|
474
|
+
inherits: true;
|
|
475
|
+
initial-value: oklch(1 0 0);
|
|
476
|
+
}
|
|
477
|
+
@property --cascivo-color-text-on-destructive {
|
|
478
|
+
syntax: '<color>';
|
|
479
|
+
inherits: true;
|
|
480
|
+
initial-value: oklch(1 0 0);
|
|
481
|
+
}
|
|
482
|
+
|
|
483
|
+
/* cascivo — Base Layer */
|
|
484
|
+
/* The one rule that activates the shipped font token (#6): applies
|
|
485
|
+
--cascivo-font-sans + a sane line-height/color/background to the document
|
|
486
|
+
root so plain consumer markup (headings, raw text, prose pages) renders in
|
|
487
|
+
the sans stack instead of falling back to the browser serif default.
|
|
488
|
+
|
|
489
|
+
This is NOT a full reset — it is the minimal base every consumer who imports
|
|
490
|
+
a theme should get for free. It lives in @layer cascivo.base, which sits
|
|
491
|
+
BELOW cascivo.theme and cascivo.component, so themes and components (and any
|
|
492
|
+
unlayered consumer CSS) always win.
|
|
493
|
+
|
|
494
|
+
Uses the canonical color tokens (foreground/background). Those are defined by
|
|
495
|
+
the themes, and --cascivo-font-sans by @cascivo/tokens; pair this with a theme
|
|
496
|
+
(or import @cascivo/themes/all). */
|
|
497
|
+
|
|
498
|
+
@layer cascivo.base {
|
|
499
|
+
html {
|
|
500
|
+
font-family: var(--cascivo-font-sans);
|
|
501
|
+
line-height: var(--cascivo-leading-normal, 1.5);
|
|
502
|
+
color: var(--cascivo-color-foreground);
|
|
503
|
+
background-color: var(--cascivo-color-background);
|
|
504
|
+
}
|
|
505
|
+
}
|
|
506
|
+
|
|
507
|
+
/* cascivo — Light Theme */
|
|
508
|
+
/* Minimal/sharp, neutral grays, clean lines */
|
|
509
|
+
|
|
510
|
+
/* Self-imports tokens for standalone use; deduped by URL when combined (see ./all.css). */
|
|
511
|
+
|
|
512
|
+
@layer cascivo.theme {
|
|
513
|
+
[data-theme='light'],
|
|
514
|
+
:root:not([data-theme]) {
|
|
515
|
+
color-scheme: light;
|
|
516
|
+
|
|
517
|
+
/* ── Interaction state (HeroUI parity) ── */
|
|
518
|
+
--cascivo-disabled-opacity: 0.5;
|
|
519
|
+
--cascivo-hover-opacity: 0.8;
|
|
520
|
+
|
|
521
|
+
/* ── Typography ───────────── */
|
|
522
|
+
--cascivo-font-display: var(--cascivo-font-sans);
|
|
523
|
+
|
|
524
|
+
/* ── Surface ──────────────────────────────────────── */
|
|
525
|
+
--cascivo-color-background: oklch(1 0 0);
|
|
526
|
+
--cascivo-color-surface: oklch(0.985 0.002 264);
|
|
527
|
+
--cascivo-color-surface-2: oklch(0.967 0.003 264);
|
|
528
|
+
--cascivo-color-bg: var(--cascivo-color-background);
|
|
529
|
+
--cascivo-color-bg-subtle: var(--cascivo-color-surface);
|
|
530
|
+
--cascivo-color-surface-raised: var(--cascivo-color-surface);
|
|
531
|
+
--cascivo-color-surface-overlay: var(--cascivo-color-background);
|
|
532
|
+
--cascivo-color-border: var(--cascivo-gray-200);
|
|
533
|
+
--cascivo-color-border-strong: var(--cascivo-gray-300);
|
|
534
|
+
--cascivo-border-subtle: oklch(0.928 0.006 264);
|
|
535
|
+
--cascivo-border-default: oklch(0.872 0.008 264);
|
|
536
|
+
--cascivo-border-strong: oklch(0.707 0.015 264);
|
|
537
|
+
|
|
538
|
+
/* ── Text ─────────────────────────────────────────── */
|
|
539
|
+
--cascivo-color-foreground: oklch(0.145 0.005 264);
|
|
540
|
+
/* Darkened 0.554→0.5 so muted text clears WCAG AA 4.5:1 on tinted surfaces
|
|
541
|
+
(surface-2, secondary), not just white. */
|
|
542
|
+
--cascivo-color-foreground-muted: oklch(0.5 0.018 264);
|
|
543
|
+
--cascivo-color-text: var(--cascivo-color-foreground);
|
|
544
|
+
--cascivo-color-text-subtle: var(--cascivo-gray-600);
|
|
545
|
+
/* Was gray-400 (2.6:1 on white — fails). Darkened to clear 4.5:1 on every
|
|
546
|
+
light surface; drives hint/caption text across ~18 components. */
|
|
547
|
+
--cascivo-color-text-muted: oklch(0.5 0.016 264);
|
|
548
|
+
--cascivo-color-text-on-accent: oklch(1 0 0); /* static fallback */
|
|
549
|
+
--cascivo-color-text-on-destructive: oklch(1 0 0); /* static fallback */
|
|
550
|
+
/* Progressive auto-contrast: contrast-color() stored in a custom property
|
|
551
|
+
does not honor the static fallback on unsupported browsers — the var()
|
|
552
|
+
substitution keeps the invalid token and the color inherits foreground.
|
|
553
|
+
Guard the upgrade so only supporting browsers apply it. */
|
|
554
|
+
@supports (color: contrast-color(red)) {
|
|
555
|
+
& {
|
|
556
|
+
--cascivo-color-text-on-accent: contrast-color(var(--cascivo-color-accent));
|
|
557
|
+
--cascivo-color-text-on-destructive: contrast-color(var(--cascivo-color-destructive));
|
|
558
|
+
}
|
|
559
|
+
}
|
|
560
|
+
/* ── Accent (links, focus, info, active tint) ───────── */
|
|
561
|
+
/* L lowered 0.623→0.52 so accent-as-link-text clears WCAG 2.2 AA 4.5:1 on
|
|
562
|
+
white (was 3.55:1). Hover darkened to stay below the new base. */
|
|
563
|
+
--cascivo-color-accent: oklch(0.52 0.2 250);
|
|
564
|
+
--cascivo-color-accent-foreground: oklch(1 0 0);
|
|
565
|
+
--cascivo-color-accent-hover: oklch(0.45 0.2 250); /* static fallback */
|
|
566
|
+
--cascivo-color-accent-hover: oklch(from var(--cascivo-color-accent) 0.45 0.2 h); /* derived */
|
|
567
|
+
--cascivo-color-accent-active: var(--cascivo-blue-800);
|
|
568
|
+
--cascivo-color-accent-subtle: var(--cascivo-blue-50);
|
|
569
|
+
--cascivo-color-accent-muted: var(--cascivo-blue-100);
|
|
570
|
+
|
|
571
|
+
/* ── Primary (filled actions — monochrome, shadcn/Linear style) ── */
|
|
572
|
+
--cascivo-color-primary: oklch(0.205 0 0);
|
|
573
|
+
--cascivo-color-primary-fg: oklch(0.985 0 0);
|
|
574
|
+
--cascivo-color-primary-hover: oklch(0.27 0 0);
|
|
575
|
+
--cascivo-color-primary-active: oklch(0.32 0 0);
|
|
576
|
+
--cascivo-color-active-bg: oklch(0.145 0.005 264 / 6%);
|
|
577
|
+
|
|
578
|
+
/* ── Destructive ──────────────────────────────────── */
|
|
579
|
+
--cascivo-color-destructive: var(--cascivo-red-600);
|
|
580
|
+
--cascivo-color-destructive-hover: var(--cascivo-red-700);
|
|
581
|
+
--cascivo-color-destructive-subtle: var(--cascivo-red-50);
|
|
582
|
+
|
|
583
|
+
/* ── Semantic status colors ───────────────────────── */
|
|
584
|
+
--cascivo-color-error: oklch(0.628 0.188 22);
|
|
585
|
+
--cascivo-color-warning: oklch(0.768 0.145 75);
|
|
586
|
+
--cascivo-color-success: oklch(0.648 0.15 145);
|
|
587
|
+
--cascivo-color-success-subtle: var(--cascivo-green-50);
|
|
588
|
+
--cascivo-color-warning-subtle: var(--cascivo-orange-50);
|
|
589
|
+
--cascivo-color-info: var(--cascivo-blue-600);
|
|
590
|
+
--cascivo-color-info-subtle: var(--cascivo-blue-50);
|
|
591
|
+
/* Foreground-safe variants: darker for text on light backgrounds (WCAG AA ≥4.5:1) */
|
|
592
|
+
--cascivo-color-success-foreground: oklch(0.45 0.14 145);
|
|
593
|
+
--cascivo-color-warning-foreground: oklch(0.5 0.14 75);
|
|
594
|
+
--cascivo-color-destructive-foreground: oklch(0.448 0.17 22);
|
|
595
|
+
--cascivo-color-info-foreground: oklch(0.45 0.19 250); /* ≈6.5:1 on blue-50 */
|
|
596
|
+
|
|
597
|
+
/* ── Radius — one knob; semantic scale derives in tokens ── */
|
|
598
|
+
--cascivo-radius-base: 0.375rem; /* 6px */
|
|
599
|
+
--cascivo-radius-control: var(--cascivo-radius-base);
|
|
600
|
+
--cascivo-radius-surface: calc(var(--cascivo-radius-base) * 1.66);
|
|
601
|
+
--cascivo-radius-indicator: calc(var(--cascivo-radius-base) / 2);
|
|
602
|
+
--cascivo-radius-full: 9999px;
|
|
603
|
+
--cascivo-radius-component: var(--cascivo-radius-base);
|
|
604
|
+
--cascivo-radius-button: var(--cascivo-radius-base);
|
|
605
|
+
--cascivo-radius-input: var(--cascivo-radius-base);
|
|
606
|
+
--cascivo-radius-card: calc(var(--cascivo-radius-base) * 1.66); /* ~10px */
|
|
607
|
+
--cascivo-radius-badge: var(--cascivo-radius-full);
|
|
608
|
+
--cascivo-radius-modal: calc(var(--cascivo-radius-base) * 2); /* ~12px */
|
|
609
|
+
|
|
610
|
+
/* ── Shadows ─────────────────────────────────────── */
|
|
611
|
+
--cascivo-shadow-xs: 0 1px 2px oklch(0 0 0 / 0.05);
|
|
612
|
+
--cascivo-shadow-sm: 0 1px 3px oklch(0 0 0 / 0.07), 0 1px 2px oklch(0 0 0 / 0.04);
|
|
613
|
+
--cascivo-shadow-md: 0 2px 8px oklch(0 0 0 / 0.07), 0 1px 2px oklch(0 0 0 / 0.04);
|
|
614
|
+
--cascivo-shadow-overlay: 0 4px 32px oklch(0 0 0 / 0.16), 0 0 0 1px oklch(0 0 0 / 0.04);
|
|
615
|
+
--cascivo-shadow-lg: var(--cascivo-shadow-overlay);
|
|
616
|
+
|
|
617
|
+
/* ── Focus ring ───────────────────────────────────── */
|
|
618
|
+
--cascivo-ring-width: 2px;
|
|
619
|
+
--cascivo-ring-offset: 0px;
|
|
620
|
+
--cascivo-ring-color: color-mix(in oklch, var(--cascivo-color-accent) 55%, transparent);
|
|
621
|
+
--cascivo-color-focus-ring: var(--cascivo-blue-500);
|
|
622
|
+
--cascivo-focus-ring: 0 0 0 var(--cascivo-ring-width) var(--cascivo-ring-color);
|
|
623
|
+
|
|
624
|
+
/* ── Chart overrides ─────────────────────────────── */
|
|
625
|
+
--cascivo-chart-1: oklch(0.62 0.13 70);
|
|
626
|
+
--cascivo-chart-2: oklch(0.62 0.11 240);
|
|
627
|
+
--cascivo-chart-3: oklch(0.6 0.13 135);
|
|
628
|
+
--cascivo-chart-4: oklch(0.6 0.18 55);
|
|
629
|
+
--cascivo-chart-5: oklch(0.5 0.13 270);
|
|
630
|
+
--cascivo-chart-6: oklch(0.58 0.16 30);
|
|
631
|
+
--cascivo-chart-7: oklch(0.62 0.12 350);
|
|
632
|
+
--cascivo-chart-8: oklch(0.5 0.12 200);
|
|
633
|
+
--cascivo-chart-grid: var(--cascivo-gray-200);
|
|
634
|
+
/* Axis labels are text — gray-400 (2.6:1) fails; match text-muted. */
|
|
635
|
+
--cascivo-chart-axis: oklch(0.5 0.016 264);
|
|
636
|
+
--cascivo-chart-fill-opacity: 0.25;
|
|
637
|
+
|
|
638
|
+
/* ── -content tokens (foreground ≥4.5:1 on paired background) ── */
|
|
639
|
+
--cascivo-color-primary-content: var(--cascivo-color-primary-fg);
|
|
640
|
+
--cascivo-color-accent-content: var(--cascivo-color-text-on-accent);
|
|
641
|
+
--cascivo-color-destructive-content: var(--cascivo-color-text-on-destructive);
|
|
642
|
+
--cascivo-color-info-content: oklch(1 0 0);
|
|
643
|
+
--cascivo-color-success-content: oklch(1 0 0);
|
|
644
|
+
--cascivo-color-warning-content: oklch(0.145 0 0);
|
|
645
|
+
--cascivo-color-error-content: oklch(1 0 0);
|
|
646
|
+
|
|
647
|
+
/* ── Secondary color role ────────────────────────── */
|
|
648
|
+
--cascivo-color-secondary: oklch(0.92 0.004 264);
|
|
649
|
+
--cascivo-color-secondary-content: oklch(0.27 0.01 264);
|
|
650
|
+
--cascivo-color-secondary-hover: oklch(0.86 0.006 264);
|
|
651
|
+
--cascivo-color-secondary-subtle: oklch(0.967 0.002 264);
|
|
652
|
+
}
|
|
653
|
+
}
|
|
654
|
+
|
|
655
|
+
/* cascivo — Dark Theme */
|
|
656
|
+
/* Bold/editorial, high contrast, developer-cool */
|
|
657
|
+
|
|
658
|
+
/* Self-imports tokens for standalone use; deduped by URL when combined (see ./all.css). */
|
|
659
|
+
|
|
660
|
+
@layer cascivo.theme {
|
|
661
|
+
[data-theme='dark'] {
|
|
662
|
+
color-scheme: dark;
|
|
663
|
+
|
|
664
|
+
/* ── Interaction state (HeroUI parity) ── */
|
|
665
|
+
--cascivo-disabled-opacity: 0.5;
|
|
666
|
+
--cascivo-hover-opacity: 0.8;
|
|
667
|
+
|
|
668
|
+
/* ── Typography ───────────── */
|
|
669
|
+
--cascivo-font-display: var(--cascivo-font-sans);
|
|
670
|
+
|
|
671
|
+
/* ── Surface ──────────────────────────────────────── */
|
|
672
|
+
--cascivo-color-background: oklch(0.145 0.005 250);
|
|
673
|
+
--cascivo-color-surface: oklch(0.185 0.007 250);
|
|
674
|
+
--cascivo-color-surface-2: oklch(0.22 0.008 250);
|
|
675
|
+
--cascivo-color-bg: var(--cascivo-color-background);
|
|
676
|
+
--cascivo-color-bg-subtle: var(--cascivo-color-surface);
|
|
677
|
+
--cascivo-color-surface-raised: var(--cascivo-color-surface-2);
|
|
678
|
+
--cascivo-color-surface-overlay: var(--cascivo-color-surface);
|
|
679
|
+
--cascivo-color-border: oklch(1 0 0 / 10%);
|
|
680
|
+
--cascivo-color-border-strong: oklch(1 0 0 / 16%);
|
|
681
|
+
--cascivo-border-subtle: oklch(1 0 0 / 0.06);
|
|
682
|
+
--cascivo-border-default: oklch(1 0 0 / 0.1);
|
|
683
|
+
--cascivo-border-strong: oklch(1 0 0 / 0.2);
|
|
684
|
+
|
|
685
|
+
/* ── Text ─────────────────────────────────────────── */
|
|
686
|
+
--cascivo-color-foreground: oklch(0.985 0.002 264);
|
|
687
|
+
--cascivo-color-foreground-muted: oklch(0.707 0.015 264);
|
|
688
|
+
--cascivo-color-text: var(--cascivo-color-foreground);
|
|
689
|
+
--cascivo-color-text-subtle: var(--cascivo-color-foreground-muted);
|
|
690
|
+
--cascivo-color-text-muted: oklch(0.554 0.018 264);
|
|
691
|
+
--cascivo-color-text-on-accent: oklch(0.145 0.005 250); /* static fallback */
|
|
692
|
+
--cascivo-color-text-on-destructive: oklch(1 0 0); /* static fallback */
|
|
693
|
+
/* Progressive auto-contrast: contrast-color() stored in a custom property
|
|
694
|
+
does not honor the static fallback on unsupported browsers — the var()
|
|
695
|
+
substitution keeps the invalid token and the color inherits foreground.
|
|
696
|
+
Guard the upgrade so only supporting browsers apply it. */
|
|
697
|
+
@supports (color: contrast-color(red)) {
|
|
698
|
+
& {
|
|
699
|
+
--cascivo-color-text-on-accent: contrast-color(var(--cascivo-color-accent));
|
|
700
|
+
--cascivo-color-text-on-destructive: contrast-color(var(--cascivo-color-destructive));
|
|
701
|
+
}
|
|
702
|
+
}
|
|
703
|
+
/* ── Accent ───────────────────────────────────────── */
|
|
704
|
+
--cascivo-color-accent: oklch(0.65 0.2 250);
|
|
705
|
+
--cascivo-color-accent-foreground: oklch(0.145 0.005 250);
|
|
706
|
+
--cascivo-color-accent-hover: oklch(0.707 0.18 250); /* static fallback */
|
|
707
|
+
--cascivo-color-accent-hover: oklch(
|
|
708
|
+
from var(--cascivo-color-accent) 0.707 0.18 h
|
|
709
|
+
); /* derived */
|
|
710
|
+
--cascivo-color-accent-active: oklch(0.808 0.14 250); /* static fallback */
|
|
711
|
+
--cascivo-color-accent-active: oklch(
|
|
712
|
+
from var(--cascivo-color-accent) 0.808 0.14 h
|
|
713
|
+
); /* derived */
|
|
714
|
+
--cascivo-color-accent-subtle: oklch(0.623 0.214 250 / 0.1);
|
|
715
|
+
--cascivo-color-accent-muted: oklch(0.623 0.214 250 / 0.2);
|
|
716
|
+
|
|
717
|
+
/* ── Destructive ──────────────────────────────────── */
|
|
718
|
+
--cascivo-color-destructive: oklch(0.72 0.16 22);
|
|
719
|
+
--cascivo-color-destructive-hover: oklch(0.628 0.188 22); /* static fallback */
|
|
720
|
+
--cascivo-color-destructive-hover: oklch(
|
|
721
|
+
from var(--cascivo-color-destructive) 0.628 0.188 h
|
|
722
|
+
); /* derived */
|
|
723
|
+
--cascivo-color-destructive-subtle: oklch(0.628 0.188 22 / 0.1);
|
|
724
|
+
|
|
725
|
+
/* ── Semantic status colors ───────────────────────── */
|
|
726
|
+
--cascivo-color-error: oklch(0.72 0.16 22);
|
|
727
|
+
--cascivo-color-warning: oklch(0.82 0.13 75);
|
|
728
|
+
--cascivo-color-success: oklch(0.72 0.13 145);
|
|
729
|
+
--cascivo-color-success-subtle: oklch(0.72 0.13 145 / 0.1);
|
|
730
|
+
--cascivo-color-warning-subtle: oklch(0.82 0.13 75 / 0.1);
|
|
731
|
+
--cascivo-color-info: oklch(0.65 0.2 250);
|
|
732
|
+
--cascivo-color-info-subtle: oklch(0.65 0.2 250 / 0.1);
|
|
733
|
+
/* Foreground-safe variants: bright for text on dark backgrounds (WCAG AA ≥4.5:1) */
|
|
734
|
+
--cascivo-color-success-foreground: oklch(0.72 0.13 145);
|
|
735
|
+
--cascivo-color-warning-foreground: oklch(0.82 0.13 75);
|
|
736
|
+
--cascivo-color-destructive-foreground: oklch(0.85 0.12 22);
|
|
737
|
+
--cascivo-color-info-foreground: oklch(0.75 0.16 250);
|
|
738
|
+
|
|
739
|
+
/* ── Primary — inverted monochrome ── */
|
|
740
|
+
--cascivo-color-primary: oklch(0.922 0 0);
|
|
741
|
+
--cascivo-color-primary-fg: oklch(0.205 0 0);
|
|
742
|
+
--cascivo-color-primary-hover: oklch(0.86 0 0);
|
|
743
|
+
--cascivo-color-primary-active: oklch(0.8 0 0);
|
|
744
|
+
--cascivo-color-active-bg: oklch(1 0 0 / 8%);
|
|
745
|
+
|
|
746
|
+
/* ── Radius — one knob; semantic scale derives in tokens ── */
|
|
747
|
+
--cascivo-radius-base: 0.375rem;
|
|
748
|
+
--cascivo-radius-control: var(--cascivo-radius-base);
|
|
749
|
+
--cascivo-radius-surface: calc(var(--cascivo-radius-base) * 1.66);
|
|
750
|
+
--cascivo-radius-indicator: calc(var(--cascivo-radius-base) / 2);
|
|
751
|
+
--cascivo-radius-full: 9999px;
|
|
752
|
+
--cascivo-radius-component: var(--cascivo-radius-base);
|
|
753
|
+
--cascivo-radius-button: var(--cascivo-radius-base);
|
|
754
|
+
--cascivo-radius-input: var(--cascivo-radius-base);
|
|
755
|
+
--cascivo-radius-card: calc(var(--cascivo-radius-base) * 1.66);
|
|
756
|
+
--cascivo-radius-badge: var(--cascivo-radius-full);
|
|
757
|
+
--cascivo-radius-modal: calc(var(--cascivo-radius-base) * 2);
|
|
758
|
+
|
|
759
|
+
/* ── Shadows — dark mode needs more opacity ────────── */
|
|
760
|
+
--cascivo-shadow-xs: none;
|
|
761
|
+
--cascivo-shadow-sm: 0 1px 3px oklch(0 0 0 / 0.4);
|
|
762
|
+
--cascivo-shadow-md: 0 2px 8px oklch(0 0 0 / 0.45);
|
|
763
|
+
--cascivo-shadow-overlay: 0 4px 32px oklch(0 0 0 / 0.6), 0 0 0 1px oklch(1 0 0 / 0.06);
|
|
764
|
+
--cascivo-shadow-lg: var(--cascivo-shadow-overlay);
|
|
765
|
+
|
|
766
|
+
/* ── Focus ring ───────────────────────────────────── */
|
|
767
|
+
--cascivo-ring-width: 2px;
|
|
768
|
+
--cascivo-ring-offset: 0px;
|
|
769
|
+
--cascivo-ring-color: color-mix(in oklch, var(--cascivo-color-accent) 65%, transparent);
|
|
770
|
+
--cascivo-color-focus-ring: oklch(0.65 0.2 250);
|
|
771
|
+
--cascivo-focus-ring: 0 0 0 var(--cascivo-ring-width) var(--cascivo-ring-color);
|
|
772
|
+
|
|
773
|
+
/* ── Chart overrides ─────────────────────────────── */
|
|
774
|
+
--cascivo-chart-1: oklch(0.8 0.13 70);
|
|
775
|
+
--cascivo-chart-2: oklch(0.8 0.11 240);
|
|
776
|
+
--cascivo-chart-3: oklch(0.73 0.13 165);
|
|
777
|
+
--cascivo-chart-4: oklch(0.95 0.15 100);
|
|
778
|
+
--cascivo-chart-5: oklch(0.63 0.12 250);
|
|
779
|
+
--cascivo-chart-6: oklch(0.68 0.15 40);
|
|
780
|
+
--cascivo-chart-7: oklch(0.73 0.11 350);
|
|
781
|
+
--cascivo-chart-8: oklch(0.72 0.08 200);
|
|
782
|
+
--cascivo-chart-grid: oklch(1 0 0 / 0.06);
|
|
783
|
+
--cascivo-chart-axis: oklch(0.707 0.015 264);
|
|
784
|
+
/* Raised from the 0.25 base: a low-opacity fill over the dark surface (L≈0.185)
|
|
785
|
+
desaturates into a muddy neutral, so give area fills more presence on dark. */
|
|
786
|
+
--cascivo-chart-fill-opacity: 0.4;
|
|
787
|
+
|
|
788
|
+
/* ── -content tokens (foreground ≥4.5:1 on paired background) ── */
|
|
789
|
+
--cascivo-color-primary-content: var(--cascivo-color-primary-fg);
|
|
790
|
+
--cascivo-color-accent-content: var(--cascivo-color-text-on-accent);
|
|
791
|
+
--cascivo-color-destructive-content: var(--cascivo-color-text-on-destructive);
|
|
792
|
+
--cascivo-color-info-content: oklch(0.145 0.005 250);
|
|
793
|
+
--cascivo-color-success-content: oklch(0.145 0 0);
|
|
794
|
+
--cascivo-color-warning-content: oklch(0.145 0 0);
|
|
795
|
+
--cascivo-color-error-content: oklch(0.145 0 0);
|
|
796
|
+
|
|
797
|
+
/* ── Secondary color role ────────────────────────── */
|
|
798
|
+
--cascivo-color-secondary: oklch(0.27 0.008 264);
|
|
799
|
+
--cascivo-color-secondary-content: oklch(0.9 0.004 264);
|
|
800
|
+
--cascivo-color-secondary-hover: oklch(0.32 0.01 264);
|
|
801
|
+
--cascivo-color-secondary-subtle: oklch(0.22 0.005 264);
|
|
802
|
+
}
|
|
803
|
+
}
|
|
804
|
+
|
|
39
805
|
@layer cascivo.component{._accordion_9ch4s_2{border:1px solid var(--cascivo-color-border);border-radius:var(--cascivo-radius-surface);flex-direction:column;display:flex;overflow:hidden}._item_9ch4s_10:not(:last-child){border-block-end:1px solid var(--cascivo-color-border)}._heading_9ch4s_16{font-size:inherit;font-weight:inherit;margin:0}._trigger_9ch4s_22{justify-content:space-between;align-items:center;gap:var(--cascivo-space-3);inline-size:100%;padding:var(--cascivo-space-4);font-family:var(--cascivo-font-sans);font-size:var(--cascivo-text-sm);font-weight:var(--cascivo-font-medium);text-align:start;color:var(--cascivo-color-text);cursor:pointer;background:0 0;border:none;display:flex}._trigger_9ch4s_22:hover{background-color:var(--cascivo-color-bg-subtle)}._trigger_9ch4s_22:focus-visible{box-shadow:var(--cascivo-focus-ring);outline:none}._indicator_9ch4s_48{block-size:.75rem;inline-size:.75rem;transition:rotate var(--cascivo-duration-200) var(--cascivo-ease-out);background-color:currentColor;flex-shrink:0;-webkit-mask:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3E%3Cpath fill='none' stroke='black' stroke-width='1.5' stroke-linecap='round' stroke-linejoin='round' d='M4 6l4 4 4-4'/%3E%3C/svg%3E") 50%/contain no-repeat;mask:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3E%3Cpath fill='none' stroke='black' stroke-width='1.5' stroke-linecap='round' stroke-linejoin='round' d='M4 6l4 4 4-4'/%3E%3C/svg%3E") 50%/contain no-repeat}._trigger_9ch4s_22[data-state=open] ._indicator_9ch4s_48{rotate:180deg}._content_9ch4s_62{visibility:hidden;color:var(--cascivo-color-text);transition:grid-template-rows var(--cascivo-duration-200) var(--cascivo-ease-out), visibility var(--cascivo-duration-200) var(--cascivo-ease-out);grid-template-rows:0fr;display:grid}._content_9ch4s_62[data-state=open]{visibility:visible;grid-template-rows:1fr}._contentInner_9ch4s_77{font-family:var(--cascivo-font-sans);font-size:var(--cascivo-text-sm);color:var(--cascivo-color-text-subtle);line-height:var(--cascivo-leading-relaxed);overflow:hidden}._content_9ch4s_62[data-state=open] ._contentInner_9ch4s_77{padding-inline:var(--cascivo-space-4);padding-block-end:var(--cascivo-space-4)}}@media (forced-colors:active){._accordion_9ch4s_2{border:1px solid buttontext}._trigger_9ch4s_22:focus-visible{outline-offset:2px;outline:2px solid highlight}}
|
|
40
806
|
|
|
41
807
|
@layer cascivo.component{._overlay_17irl_2{z-index:var(--cascivo-z-overlay,50);padding:var(--cascivo-space-3);opacity:1;transition:opacity var(--cascivo-motion-enter);background-color:#0006;flex-direction:column;justify-content:flex-end;align-items:center;padding-block-end:calc(var(--cascivo-space-3) + env(safe-area-inset-bottom,0px));display:flex;position:fixed;inset:0}._overlay_17irl_2[data-state=closed]{opacity:0;transition:opacity var(--cascivo-motion-exit)}@starting-style{._overlay_17irl_2[data-state=open]{opacity:0}}._sheet_17irl_28{gap:var(--cascivo-space-2);inline-size:100%;max-inline-size:32rem;transition:translate var(--cascivo-motion-enter);flex-direction:column;display:flex;translate:0}._overlay_17irl_2[data-state=closed] ._sheet_17irl_28{transition:translate var(--cascivo-motion-exit);translate:0 100%}@starting-style{._overlay_17irl_2[data-state=open] ._sheet_17irl_28{translate:0 100%}}._group_17irl_50{background:var(--cascivo-color-surface);border:1px solid var(--cascivo-color-border);border-radius:var(--cascivo-radius-overlay);box-shadow:var(--cascivo-shadow-overlay);flex-direction:column;display:flex;overflow:hidden}._heading_17irl_60{padding:var(--cascivo-space-4) var(--cascivo-space-6);text-align:center;border-block-end:1px solid var(--cascivo-color-border)}._title_17irl_66{font-size:var(--cascivo-text-sm);font-weight:var(--cascivo-font-semibold);color:var(--cascivo-color-text);margin:0}._description_17irl_73{margin:var(--cascivo-space-1) 0 0;font-size:var(--cascivo-text-sm);color:var(--cascivo-color-text-subtle)}._item_17irl_79{min-block-size:3rem;inline-size:100%;padding:var(--cascivo-space-3) var(--cascivo-space-6);font-size:var(--cascivo-text-base);color:var(--cascivo-color-accent);cursor:pointer;transition:background-color var(--cascivo-duration-150) var(--cascivo-ease-out);background:0 0;border:none;justify-content:center;align-items:center;display:flex}._item_17irl_79+._item_17irl_79{border-block-start:1px solid var(--cascivo-color-border)}._item_17irl_79:hover{background-color:var(--cascivo-color-bg-subtle)}._item_17irl_79:focus-visible{box-shadow:var(--cascivo-focus-ring);z-index:1;outline:none;position:relative}._item_17irl_79[aria-disabled=true]{color:var(--cascivo-color-text-muted);cursor:not-allowed}._item_17irl_79[data-destructive]{color:var(--cascivo-color-destructive)}._cancel_17irl_119{font-weight:var(--cascivo-font-semibold);color:var(--cascivo-color-text)}@media (prefers-reduced-motion:reduce){._sheet_17irl_28{transition:none}}}
|