ui-style-kit-css 2.0.4 → 2.2.0

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.
@@ -1,18 +1,21 @@
1
1
  /* =========================================================
2
- UI Style Kit CSS x Interactive Surface CSS Bridge
2
+ UI Style Kit CSS x Interactive Surface CSS Bridge (Deprecated)
3
3
 
4
- This optional bridge maps shared UI Style Kit semantic roles to
5
- interactive-surface-css tokens and supplies visible state layers.
4
+ This legacy bridge maps shared UI Style Kit semantic roles to
5
+ interactive-surface-css tokens and continues to own visible states.
6
+ New integrations should use interactive-surface-theme.css with
7
+ interactive-surface-css/state-core.css instead.
6
8
  The flow follows scheme tokens -> mode roles -> bridge tokens ->
7
9
  surface behavior, avoiding per-theme and per-preset token maps.
8
10
  ========================================================= */
9
11
 
10
12
  :where([data-ui][data-theme][data-mode]) .interactive-surface {
11
13
  --interactive-surface-border-width: 1px;
14
+ /* Preserve the adapter's opaque paint while semantic surfaces may retain preset alpha. */
12
15
  --interactive-surface-bg: rgb(var(--usk-surface-strong-rgb, var(--usk-surface-rgb, 255 255 255)));
13
- --interactive-surface-fg: rgb(var(--usk-text-rgb));
16
+ --interactive-surface-fg: var(--ui-color-text, rgb(var(--usk-text-rgb)));
14
17
  --interactive-surface-border-color: rgb(var(--usk-border-rgb, 128 128 128) / .72);
15
- --interactive-surface-focus-ring-color: rgb(var(--usk-focus-rgb, var(--usk-primary-rgb, 72 120 255)));
18
+ --interactive-surface-focus-ring-color: var(--ui-focus-color, rgb(var(--usk-focus-rgb, var(--usk-primary-rgb, 72 120 255))));
16
19
  --interactive-surface-radius: .85rem;
17
20
  --interactive-surface-state-layer-color: currentColor;
18
21
  --interactive-surface-state-layer-opacity: 0;
@@ -25,8 +28,8 @@
25
28
  --interactive-surface-light-icon-color-dark: var(--interactive-surface-light-icon-color);
26
29
  --interactive-surface-dark-icon-color-dark: var(--interactive-surface-dark-icon-color);
27
30
  --interactive-surface-accessibility-icon-color-dark: var(--interactive-surface-accessibility-icon-color);
28
- --interactive-surface-variant-primary-bg: rgb(var(--usk-primary-rgb));
29
- --interactive-surface-variant-primary-fg: rgb(var(--usk-primary-text-rgb, var(--usk-bg-rgb, 255 255 255)));
31
+ --interactive-surface-variant-primary-bg: var(--ui-color-primary, rgb(var(--usk-primary-rgb)));
32
+ --interactive-surface-variant-primary-fg: var(--ui-color-on-primary, rgb(var(--usk-primary-text-rgb, var(--usk-bg-rgb, 255 255 255))));
30
33
  --interactive-surface-variant-primary-border-color: rgb(var(--usk-primary-rgb, 72 120 255));
31
34
  --interactive-surface-variant-secondary-bg: rgb(var(--usk-secondary-rgb, var(--usk-surface-soft-rgb, 96 112 128)));
32
35
  --interactive-surface-variant-secondary-fg: rgb(var(--usk-secondary-text-rgb, var(--usk-text-rgb, 18 18 18)));
@@ -35,7 +38,7 @@
35
38
  --interactive-surface-variant-accent-fg: rgb(var(--usk-accent-text-rgb, var(--usk-bg-rgb, 255 255 255)));
36
39
  --interactive-surface-variant-accent-border-color: rgb(var(--usk-accent-rgb, var(--usk-primary-rgb, 72 120 255)));
37
40
  --interactive-surface-variant-subtle-bg: rgb(var(--usk-surface-soft-rgb, var(--usk-surface-rgb, 244 244 244)));
38
- --interactive-surface-variant-subtle-fg: rgb(var(--usk-text-rgb, 18 18 18));
41
+ --interactive-surface-variant-subtle-fg: var(--ui-color-text, rgb(var(--usk-text-rgb, 18 18 18)));
39
42
  --interactive-surface-variant-subtle-border-color: rgb(var(--usk-border-rgb, 128 128 128) / .64);
40
43
  --interactive-surface-variant-warning-bg: rgb(var(--usk-warning-rgb, 255 190 72));
41
44
  --interactive-surface-variant-warning-fg: rgb(var(--usk-warning-text-rgb, var(--usk-bg-rgb, 18 18 18)));
@@ -0,0 +1,115 @@
1
+ /* =========================================================
2
+ UI Style Kit CSS x Interactive Surface CSS Theme Bridge
3
+
4
+ This bridge owns public paint and geometry tokens only.
5
+ Interactive Surface state-core.css remains the sole owner of
6
+ hover, focus, active, disabled, and reduced-motion behavior.
7
+ ========================================================= */
8
+
9
+ :where([data-ui][data-theme][data-mode]) .interactive-surface {
10
+ --interactive-surface-border-width: 1px;
11
+ /* Preserve the adapter's opaque paint while semantic surfaces may retain preset alpha. */
12
+ --interactive-surface-bg: rgb(var(--usk-surface-strong-rgb, var(--usk-surface-rgb, 255 255 255)));
13
+ --interactive-surface-fg: var(--ui-color-text, rgb(var(--usk-text-rgb, 18 18 18)));
14
+ --interactive-surface-border-color: rgb(var(--usk-border-rgb, 128 128 128) / .72);
15
+ --interactive-surface-focus-ring-color: var(--ui-focus-color, rgb(var(--usk-focus-rgb, var(--usk-primary-rgb, 72 120 255))));
16
+ --interactive-surface-radius: .85rem;
17
+ --interactive-surface-light-icon-color: rgb(var(--usk-warning-rgb, var(--usk-accent-rgb, 255 190 72)));
18
+ --interactive-surface-dark-icon-color: rgb(var(--usk-text-rgb, 18 18 18));
19
+ --interactive-surface-accessibility-icon-color: var(--interactive-surface-focus-ring-color);
20
+ --interactive-surface-light-icon-color-dark: var(--interactive-surface-light-icon-color);
21
+ --interactive-surface-dark-icon-color-dark: var(--interactive-surface-dark-icon-color);
22
+ --interactive-surface-accessibility-icon-color-dark: var(--interactive-surface-accessibility-icon-color);
23
+ --interactive-surface-variant-primary-bg: var(--ui-color-primary, rgb(var(--usk-primary-rgb, 72 120 255)));
24
+ --interactive-surface-variant-primary-fg: var(--ui-color-on-primary, rgb(var(--usk-primary-text-rgb, var(--usk-bg-rgb, 255 255 255))));
25
+ --interactive-surface-variant-primary-border-color: rgb(var(--usk-primary-rgb, 72 120 255));
26
+ --interactive-surface-variant-secondary-bg: rgb(var(--usk-secondary-rgb, var(--usk-surface-soft-rgb, 96 112 128)));
27
+ --interactive-surface-variant-secondary-fg: rgb(var(--usk-secondary-text-rgb, var(--usk-text-rgb, 18 18 18)));
28
+ --interactive-surface-variant-secondary-border-color: rgb(var(--usk-secondary-rgb, 96 112 128));
29
+ --interactive-surface-variant-accent-bg: rgb(var(--usk-accent-rgb, var(--usk-primary-rgb, 72 120 255)));
30
+ --interactive-surface-variant-accent-fg: rgb(var(--usk-accent-text-rgb, var(--usk-bg-rgb, 255 255 255)));
31
+ --interactive-surface-variant-accent-border-color: rgb(var(--usk-accent-rgb, var(--usk-primary-rgb, 72 120 255)));
32
+ --interactive-surface-variant-subtle-bg: rgb(var(--usk-surface-soft-rgb, var(--usk-surface-rgb, 244 244 244)));
33
+ --interactive-surface-variant-subtle-fg: var(--ui-color-text, rgb(var(--usk-text-rgb, 18 18 18)));
34
+ --interactive-surface-variant-subtle-border-color: rgb(var(--usk-border-rgb, 128 128 128) / .64);
35
+ --interactive-surface-variant-warning-bg: rgb(var(--usk-warning-rgb, 255 190 72));
36
+ --interactive-surface-variant-warning-fg: rgb(var(--usk-warning-text-rgb, var(--usk-bg-rgb, 18 18 18)));
37
+ --interactive-surface-variant-warning-border-color: rgb(var(--usk-warning-rgb, 255 190 72));
38
+ --interactive-surface-variant-danger-bg: rgb(var(--usk-danger-rgb, 210 72 72));
39
+ --interactive-surface-variant-danger-fg: rgb(var(--usk-danger-text-rgb, 255 255 255));
40
+ --interactive-surface-variant-danger-border-color: rgb(var(--usk-danger-rgb, 210 72 72));
41
+ --interactive-surface-level-1-bg: var(--interactive-surface-variant-subtle-bg);
42
+ --interactive-surface-level-1-border-color: var(--interactive-surface-variant-subtle-border-color);
43
+ --interactive-surface-level-1-shadow: 0 1px 2px rgb(var(--usk-bg-rgb, 0 0 0) / .18);
44
+ --interactive-surface-level-2-bg: var(--interactive-surface-bg);
45
+ --interactive-surface-level-2-border-color: var(--interactive-surface-border-color);
46
+ --interactive-surface-level-2-shadow: 0 8px 20px rgb(var(--usk-bg-rgb, 0 0 0) / .22);
47
+ --interactive-surface-level-3-bg: color-mix(in srgb, var(--interactive-surface-bg) 82%, var(--interactive-surface-variant-primary-bg));
48
+ --interactive-surface-level-3-border-color: color-mix(in srgb, var(--interactive-surface-variant-primary-border-color) 72%, var(--interactive-surface-border-color));
49
+ --interactive-surface-level-3-shadow: 0 14px 34px rgb(var(--usk-bg-rgb, 0 0 0) / .3), 0 0 0 1px color-mix(in srgb, var(--interactive-surface-variant-primary-border-color) 34%, transparent);
50
+ --interactive-surface-level-bg: var(--interactive-surface-level-1-bg);
51
+ --interactive-surface-level-border-color: var(--interactive-surface-level-1-border-color);
52
+ --interactive-surface-level-shadow: var(--interactive-surface-level-1-shadow);
53
+
54
+ box-sizing: border-box;
55
+ border: var(--interactive-surface-border-width) solid var(--interactive-surface-level-border-color, var(--interactive-surface-border-color));
56
+ border-radius: var(--interactive-surface-radius);
57
+ background-color: var(--interactive-surface-level-bg, var(--interactive-surface-bg));
58
+ box-shadow: var(--interactive-surface-level-shadow, none);
59
+ color: var(--interactive-surface-fg);
60
+ }
61
+
62
+ :where([data-ui][data-theme][data-mode]) .interactive-surface[data-surface-variant="primary"] {
63
+ --interactive-surface-bg: var(--interactive-surface-variant-primary-bg);
64
+ --interactive-surface-fg: var(--interactive-surface-variant-primary-fg);
65
+ --interactive-surface-border-color: var(--interactive-surface-variant-primary-border-color);
66
+ }
67
+
68
+ :where([data-ui][data-theme][data-mode]) .interactive-surface[data-surface-variant="secondary"] {
69
+ --interactive-surface-bg: var(--interactive-surface-variant-secondary-bg);
70
+ --interactive-surface-fg: var(--interactive-surface-variant-secondary-fg);
71
+ --interactive-surface-border-color: var(--interactive-surface-variant-secondary-border-color);
72
+ }
73
+
74
+ :where([data-ui][data-theme][data-mode]) .interactive-surface[data-surface-variant="accent"] {
75
+ --interactive-surface-bg: var(--interactive-surface-variant-accent-bg);
76
+ --interactive-surface-fg: var(--interactive-surface-variant-accent-fg);
77
+ --interactive-surface-border-color: var(--interactive-surface-variant-accent-border-color);
78
+ }
79
+
80
+ :where([data-ui][data-theme][data-mode]) .interactive-surface[data-surface-variant="subtle"] {
81
+ --interactive-surface-bg: var(--interactive-surface-variant-subtle-bg);
82
+ --interactive-surface-fg: var(--interactive-surface-variant-subtle-fg);
83
+ --interactive-surface-border-color: var(--interactive-surface-variant-subtle-border-color);
84
+ }
85
+
86
+ :where([data-ui][data-theme][data-mode]) .interactive-surface[data-surface-variant="warning"] {
87
+ --interactive-surface-bg: var(--interactive-surface-variant-warning-bg);
88
+ --interactive-surface-fg: var(--interactive-surface-variant-warning-fg);
89
+ --interactive-surface-border-color: var(--interactive-surface-variant-warning-border-color);
90
+ }
91
+
92
+ :where([data-ui][data-theme][data-mode]) .interactive-surface[data-surface-variant="danger"] {
93
+ --interactive-surface-bg: var(--interactive-surface-variant-danger-bg);
94
+ --interactive-surface-fg: var(--interactive-surface-variant-danger-fg);
95
+ --interactive-surface-border-color: var(--interactive-surface-variant-danger-border-color);
96
+ }
97
+
98
+ /* Level selectors select paint depth without taking ownership of interaction states. */
99
+ :where([data-ui][data-theme][data-mode]) .interactive-surface[data-surface-level="1"] {
100
+ --interactive-surface-level-bg: var(--interactive-surface-level-1-bg);
101
+ --interactive-surface-level-border-color: var(--interactive-surface-level-1-border-color);
102
+ --interactive-surface-level-shadow: var(--interactive-surface-level-1-shadow);
103
+ }
104
+
105
+ :where([data-ui][data-theme][data-mode]) .interactive-surface[data-surface-level="2"] {
106
+ --interactive-surface-level-bg: var(--interactive-surface-level-2-bg);
107
+ --interactive-surface-level-border-color: var(--interactive-surface-level-2-border-color);
108
+ --interactive-surface-level-shadow: var(--interactive-surface-level-2-shadow);
109
+ }
110
+
111
+ :where([data-ui][data-theme][data-mode]) .interactive-surface[data-surface-level="3"] {
112
+ --interactive-surface-level-bg: var(--interactive-surface-level-3-bg);
113
+ --interactive-surface-level-border-color: var(--interactive-surface-level-3-border-color);
114
+ --interactive-surface-level-shadow: var(--interactive-surface-level-3-shadow);
115
+ }
@@ -370,7 +370,7 @@
370
370
  .max-skip-link:focus { transform: translateY(0); }
371
371
 
372
372
  /* Maximalist-specific expressive helpers */
373
- .max-sticker { display: inline-flex; align-items: center; padding: .45rem .8rem; background: var(--max-accent); color: #111; border: 3px solid var(--max-border); border-radius: var(--max-radius-pill); box-shadow: 5px 5px 0 rgb(var(--max-border-rgb) / .8); font-weight: 950; transform: rotate(-2deg); }
373
+ .max-sticker { display: inline-flex; align-items: center; padding: .45rem .8rem; background: var(--max-accent); color: var(--max-on-accent); border: 3px solid var(--max-border); border-radius: var(--max-radius-pill); box-shadow: 5px 5px 0 rgb(var(--max-border-rgb) / .8); font-weight: 950; transform: rotate(-2deg); }
374
374
  .max-callout { padding: var(--max-space-6); background: linear-gradient(135deg, var(--max-primary), var(--max-accent)); color: var(--max-on-primary); border: 3px solid var(--max-border); border-radius: var(--max-radius-xl); box-shadow: 10px 10px 0 rgb(var(--max-border-rgb) / .85); }
375
375
  .max-wiggle:hover { animation: max-wiggle 420ms ease both; }
376
376
  @keyframes max-wiggle { 0%,100% { transform: rotate(0deg); } 25% { transform: rotate(-1.5deg); } 75% { transform: rotate(1.5deg); } }
@@ -34,11 +34,35 @@
34
34
  --usk-native-border-width: 1px;
35
35
  --usk-native-field-gap: .5rem;
36
36
  --usk-native-panel-padding: 1rem;
37
+ --usk-native-control-min-block-size: 2.75rem;
37
38
  --usk-native-control-padding-block: .72rem;
38
39
  --usk-native-control-padding-inline: .95rem;
40
+ --usk-native-subcontrol-padding-block: .55rem;
41
+ --usk-native-subcontrol-padding-inline: .8rem;
42
+ --usk-native-track: color-mix(in srgb, var(--usk-native-border) 50%, transparent);
43
+ --usk-native-track-fill: var(--usk-native-primary);
44
+ --usk-native-thumb: var(--usk-native-surface-strong);
45
+ --usk-native-thumb-border: var(--usk-native-primary);
46
+ --usk-native-indicator: var(--usk-native-primary);
39
47
  --usk-native-shadow: none;
40
48
  --usk-native-shadow-md: var(--usk-native-shadow);
41
49
  --usk-native-focus-ring: 0 0 0 3px rgb(var(--usk-focus-rgb) / .28);
50
+ --usk-motion-duration: 140ms;
51
+ --usk-motion-easing: cubic-bezier(0.2, 0, 0.2, 1);
52
+
53
+ /* Shared semantic values are fully typed so optional companion and third-party consumers can use them directly. */
54
+ --ui-color-bg: rgb(var(--usk-bg-rgb));
55
+ --ui-color-surface: var(--usk-native-surface-strong);
56
+ --ui-color-text: var(--usk-native-text);
57
+ --ui-color-muted: var(--usk-native-text-muted);
58
+ --ui-color-primary: var(--usk-native-primary);
59
+ --ui-color-on-primary: var(--usk-native-on-primary);
60
+ --ui-color-border: var(--usk-native-border);
61
+ --ui-radius-control: var(--usk-native-radius);
62
+ --ui-shadow-control: var(--usk-native-shadow);
63
+ --ui-focus-color: var(--usk-native-focus);
64
+ --ui-motion-duration: var(--usk-motion-duration);
65
+ --ui-motion-easing: var(--usk-motion-easing);
42
66
  }
43
67
 
44
68
  [data-ui][data-theme][data-mode] :where(h1, h2, h3, h4, h5, h6) {
@@ -49,6 +73,12 @@
49
73
  text-wrap: balance;
50
74
  }
51
75
 
76
+ [data-ui][data-theme][data-mode] :where(hgroup) {
77
+ display: grid;
78
+ gap: .35rem;
79
+ margin-block: 0 1rem;
80
+ }
81
+
52
82
  [data-ui][data-theme][data-mode] :where(h1) { font-size: clamp(2rem, 5vw, 3.5rem); }
53
83
  [data-ui][data-theme][data-mode] :where(h2) { font-size: clamp(1.55rem, 3vw, 2.35rem); }
54
84
  [data-ui][data-theme][data-mode] :where(h3) { font-size: clamp(1.25rem, 2vw, 1.65rem); }
@@ -148,6 +178,12 @@
148
178
  font-size: .9rem;
149
179
  }
150
180
 
181
+ [data-ui][data-theme][data-mode] :where(form) {
182
+ display: grid;
183
+ gap: var(--usk-native-field-gap);
184
+ min-inline-size: 0;
185
+ }
186
+
151
187
  [data-ui][data-theme][data-mode] :where(fieldset) {
152
188
  display: grid;
153
189
  gap: .9rem;
@@ -184,7 +220,7 @@
184
220
 
185
221
  [data-ui][data-theme][data-mode] :where(input:not([type="checkbox"]):not([type="radio"]):not([type="range"]):not([type="color"]), textarea, select) {
186
222
  width: 100%;
187
- min-height: 2.75rem;
223
+ min-block-size: var(--usk-native-control-min-block-size);
188
224
  padding: var(--usk-native-control-padding-block) var(--usk-native-control-padding-inline);
189
225
  color: var(--usk-native-text);
190
226
  background: var(--usk-native-control-bg);
@@ -193,6 +229,16 @@
193
229
  font: inherit;
194
230
  }
195
231
 
232
+ [data-ui][data-theme][data-mode] :where(input, textarea, select, button) {
233
+ color-scheme: inherit;
234
+ accent-color: var(--usk-native-primary);
235
+ }
236
+
237
+ [data-ui][data-theme][data-mode] :where(input, textarea)::placeholder {
238
+ color: var(--usk-native-text-muted);
239
+ opacity: .78;
240
+ }
241
+
196
242
  [data-ui][data-theme][data-mode] :where(textarea) {
197
243
  min-height: 7rem;
198
244
  resize: vertical;
@@ -201,7 +247,7 @@
201
247
  [data-ui][data-theme][data-mode] :where(input, textarea, select, button) { font: inherit; }
202
248
 
203
249
  [data-ui][data-theme][data-mode] :where(button:not([class]), input[type="button"]:not([class]), input[type="submit"]:not([class]), input[type="reset"]:not([class])) {
204
- min-height: 2.75rem;
250
+ min-block-size: var(--usk-native-control-min-block-size);
205
251
  padding: .7rem 1rem;
206
252
  color: var(--usk-native-on-primary);
207
253
  background: var(--usk-native-primary);
@@ -218,16 +264,53 @@
218
264
  }
219
265
 
220
266
  [data-ui][data-theme][data-mode] :where(input[type="checkbox"], input[type="radio"]) {
221
- inline-size: 1.1rem;
222
- block-size: 1.1rem;
267
+ inline-size: 1.5rem;
268
+ block-size: 1.5rem;
223
269
  accent-color: var(--usk-native-primary);
224
270
  }
225
271
 
226
272
  [data-ui][data-theme][data-mode] :where(input[type="range"]) {
273
+ -webkit-appearance: none;
274
+ appearance: none;
227
275
  width: 100%;
276
+ min-block-size: 1.5rem;
277
+ background: transparent;
228
278
  accent-color: var(--usk-native-primary);
229
279
  }
230
280
 
281
+ [data-ui][data-theme][data-mode] :where(input[type="range"])::-webkit-slider-runnable-track {
282
+ block-size: .45rem;
283
+ background: var(--usk-native-track);
284
+ border-radius: 999px;
285
+ }
286
+
287
+ [data-ui][data-theme][data-mode] :where(input[type="range"])::-moz-range-track {
288
+ block-size: .45rem;
289
+ background: var(--usk-native-track);
290
+ border-radius: 999px;
291
+ }
292
+
293
+ [data-ui][data-theme][data-mode] :where(input[type="range"])::-webkit-slider-thumb {
294
+ -webkit-appearance: none;
295
+ appearance: none;
296
+ inline-size: 1.2rem;
297
+ block-size: 1.2rem;
298
+ margin-block-start: -.38rem;
299
+ background: var(--usk-native-thumb);
300
+ border: var(--usk-native-border-width) solid var(--usk-native-thumb-border);
301
+ border-radius: 999px;
302
+ box-shadow: var(--usk-native-shadow);
303
+ }
304
+
305
+ [data-ui][data-theme][data-mode] :where(input[type="range"])::-moz-range-thumb {
306
+ inline-size: 1.2rem;
307
+ block-size: 1.2rem;
308
+ background: var(--usk-native-thumb);
309
+ border: var(--usk-native-border-width) solid var(--usk-native-thumb-border);
310
+ border-radius: 999px;
311
+ box-shadow: var(--usk-native-shadow);
312
+ }
313
+
231
314
  [data-ui][data-theme][data-mode] :where(input[type="color"]) {
232
315
  inline-size: 3rem;
233
316
  block-size: 2.4rem;
@@ -237,12 +320,27 @@
237
320
  border-radius: var(--usk-native-radius-sm);
238
321
  }
239
322
 
323
+ [data-ui][data-theme][data-mode] :where(input[type="color"])::-webkit-color-swatch-wrapper {
324
+ padding: 0;
325
+ }
326
+
327
+ [data-ui][data-theme][data-mode] :where(input[type="color"])::-webkit-color-swatch {
328
+ border: 0;
329
+ border-radius: calc(var(--usk-native-radius-sm) / 1.5);
330
+ }
331
+
332
+ [data-ui][data-theme][data-mode] :where(input[type="color"])::-moz-color-swatch {
333
+ border: 0;
334
+ border-radius: calc(var(--usk-native-radius-sm) / 1.5);
335
+ }
336
+
240
337
  [data-ui][data-theme][data-mode] :where(input[type="file"]) { color: var(--usk-native-text-muted); }
241
338
 
242
339
  /* Keep pseudo-elements outside :where() because engines reject them inside selector-list arguments. */
243
- [data-ui][data-theme][data-mode] :where(input[type="file"])::file-selector-button {
340
+ [data-ui][data-theme][data-mode] :where(input[type="file"])::file-selector-button,
341
+ [data-ui][data-theme][data-mode] :where(input[type="file"])::-webkit-file-upload-button {
244
342
  margin-inline-end: .75rem;
245
- padding: .55rem .8rem;
343
+ padding: var(--usk-native-subcontrol-padding-block) var(--usk-native-subcontrol-padding-inline);
246
344
  color: var(--usk-native-on-primary);
247
345
  background: var(--usk-native-primary);
248
346
  border: var(--usk-native-border-width) solid var(--usk-native-primary);
@@ -251,15 +349,63 @@
251
349
  cursor: pointer;
252
350
  }
253
351
 
254
- [data-ui][data-theme][data-mode] :where(input:disabled, textarea:disabled, select:disabled, button:disabled, [aria-disabled="true"]) {
255
- opacity: .55;
352
+ [data-ui][data-theme][data-mode] :where(input[type="file"]:hover)::file-selector-button,
353
+ [data-ui][data-theme][data-mode] :where(input[type="file"]:hover)::-webkit-file-upload-button {
354
+ background: var(--usk-native-primary-hover);
355
+ border-color: var(--usk-native-primary-hover);
356
+ }
357
+
358
+ [data-ui][data-theme][data-mode] :where(input[type="file"]:focus-visible)::file-selector-button,
359
+ [data-ui][data-theme][data-mode] :where(input[type="file"]:focus-visible)::-webkit-file-upload-button {
360
+ box-shadow: var(--usk-native-focus-ring);
361
+ }
362
+
363
+ [data-ui][data-theme][data-mode] :where(input[type="file"]:active)::file-selector-button,
364
+ [data-ui][data-theme][data-mode] :where(input[type="file"]:active)::-webkit-file-upload-button {
365
+ filter: brightness(.96);
366
+ }
367
+
368
+ [data-ui][data-theme][data-mode] :where(input[type="file"]:disabled)::file-selector-button,
369
+ [data-ui][data-theme][data-mode] :where(input[type="file"]:disabled)::-webkit-file-upload-button {
370
+ color: var(--usk-native-text-muted);
371
+ background: var(--usk-native-surface-soft);
372
+ border-color: var(--usk-native-border);
256
373
  cursor: not-allowed;
257
374
  }
258
375
 
259
- [data-ui][data-theme][data-mode] :where(input:invalid, textarea:invalid, select:invalid, [aria-invalid="true"]) {
376
+ [data-ui][data-theme][data-mode] :where(input:read-only, textarea:read-only) {
377
+ background: var(--usk-native-surface-soft);
378
+ }
379
+
380
+ [data-ui][data-theme][data-mode] :where(input:required, textarea:required, select:required) {
381
+ box-shadow: inset .22rem 0 0 var(--usk-native-indicator);
382
+ }
383
+
384
+ [data-ui][data-theme][data-mode] :where(input:user-valid, textarea:user-valid, select:user-valid, .is-valid) {
385
+ border-color: var(--usk-native-success);
386
+ }
387
+
388
+ [data-ui][data-theme][data-mode] :where(input:user-invalid, textarea:user-invalid, select:user-invalid, [aria-invalid="true"], .is-invalid) {
260
389
  border-color: var(--usk-native-danger);
261
390
  }
262
391
 
392
+ [data-ui][data-theme][data-mode] :where(input[type="checkbox"]:indeterminate, input[type="radio"]:indeterminate) {
393
+ accent-color: var(--usk-native-warning);
394
+ }
395
+
396
+ [data-ui][data-theme][data-mode] :where(button:active, input[type="button"]:active, input[type="submit"]:active, input[type="reset"]:active) {
397
+ filter: brightness(.96);
398
+ }
399
+
400
+ [data-ui][data-theme][data-mode] :where(input:disabled, textarea:disabled, select:disabled, button:disabled, [aria-disabled="true"]) {
401
+ color: var(--usk-native-text-muted);
402
+ background: color-mix(in srgb, var(--usk-native-surface-soft) 72%, transparent);
403
+ border-color: var(--usk-native-border);
404
+ box-shadow: none;
405
+ opacity: .55;
406
+ cursor: not-allowed;
407
+ }
408
+
263
409
  [data-ui][data-theme][data-mode] :where(table) {
264
410
  width: 100%;
265
411
  margin: 1rem 0;
@@ -323,6 +469,32 @@
323
469
  accent-color: var(--usk-native-primary);
324
470
  }
325
471
 
472
+ [data-ui][data-theme][data-mode] :where(progress, meter)::-webkit-progress-bar,
473
+ [data-ui][data-theme][data-mode] :where(meter)::-webkit-meter-bar {
474
+ background: var(--usk-native-track);
475
+ border-radius: 999px;
476
+ }
477
+
478
+ [data-ui][data-theme][data-mode] :where(progress)::-webkit-progress-value,
479
+ [data-ui][data-theme][data-mode] :where(meter)::-webkit-meter-optimum-value {
480
+ background: var(--usk-native-track-fill);
481
+ border-radius: inherit;
482
+ }
483
+
484
+ [data-ui][data-theme][data-mode] :where(progress)::-moz-progress-bar,
485
+ [data-ui][data-theme][data-mode] :where(meter)::-moz-meter-bar {
486
+ background: var(--usk-native-track-fill);
487
+ border-radius: 999px;
488
+ }
489
+
490
+ [data-ui][data-theme][data-mode] :where(meter)::-webkit-meter-suboptimum-value {
491
+ background: var(--usk-native-warning);
492
+ }
493
+
494
+ [data-ui][data-theme][data-mode] :where(meter)::-webkit-meter-even-less-good-value {
495
+ background: var(--usk-native-danger);
496
+ }
497
+
326
498
  [data-ui][data-theme][data-mode] :where(main, section, header, footer, nav, article, aside, address) {
327
499
  color: var(--usk-native-text);
328
500
  }
@@ -348,6 +520,8 @@
348
520
 
349
521
  [data-ui][data-theme][data-mode] :where(dd) { margin: .25rem 0 .75rem 1.25rem; }
350
522
  [data-ui][data-theme][data-mode] :where(strong, b) { color: var(--usk-native-text); font-weight: 900; }
523
+ [data-ui][data-theme][data-mode] :where(u) { text-decoration-color: var(--usk-native-primary); text-decoration-thickness: .08em; text-underline-offset: .16em; }
524
+ [data-ui][data-theme][data-mode] :where(bdi, bdo) { color: var(--usk-native-text); unicode-bidi: isolate; }
351
525
  [data-ui][data-theme][data-mode] :where(em, i, cite, var, q) { color: var(--usk-native-text); }
352
526
  [data-ui][data-theme][data-mode] :where(ins) { color: var(--usk-native-text); text-decoration-color: var(--usk-native-success); }
353
527
  [data-ui][data-theme][data-mode] :where(del, s) { color: var(--usk-native-text); text-decoration-color: var(--usk-native-danger); }
@@ -355,6 +529,30 @@
355
529
  [data-ui][data-theme][data-mode] :where(optgroup, option) { color: var(--usk-native-text); background: var(--usk-native-surface); }
356
530
  [data-ui][data-theme][data-mode] :where(time, data, dfn, ruby) { color: var(--usk-native-text); }
357
531
  [data-ui][data-theme][data-mode] :where(search) { display: block; color: var(--usk-native-text); }
532
+ [data-ui][data-theme][data-mode] :where(selectedcontent) { color: var(--usk-native-text); }
533
+ [data-ui][data-theme][data-mode] :where(datalist) { display: none; }
534
+
535
+ [data-ui][data-theme][data-mode] :where(summary, li)::marker {
536
+ color: var(--usk-native-indicator);
537
+ }
538
+
539
+ [data-ui][data-theme][data-mode] :where(input[type="date"], input[type="datetime-local"], input[type="month"], input[type="time"], input[type="week"])::-webkit-calendar-picker-indicator {
540
+ opacity: .78;
541
+ accent-color: var(--usk-native-indicator);
542
+ }
543
+
544
+ [data-ui][data-theme][data-mode] :where(input[type="search"])::-webkit-search-cancel-button {
545
+ accent-color: var(--usk-native-indicator);
546
+ }
547
+
548
+ [data-ui][data-theme][data-mode] :where(input[type="number"])::-webkit-inner-spin-button,
549
+ [data-ui][data-theme][data-mode] :where(input[type="number"])::-webkit-outer-spin-button {
550
+ opacity: .72;
551
+ }
552
+
553
+ [data-ui][data-theme][data-mode] :where(select)::picker-icon {
554
+ color: var(--usk-native-indicator);
555
+ }
358
556
 
359
557
  [data-ui][data-theme][data-mode] :where(:focus-visible) {
360
558
  outline: 3px solid var(--usk-native-focus);
@@ -372,4 +570,24 @@
372
570
  [data-ui][data-theme][data-mode] :where([aria-busy="true"]) { cursor: progress; }
373
571
  [data-ui][data-theme][data-mode] :where([hidden]) { display: none !important; }
374
572
  [data-ui][data-theme][data-mode] ::selection { color: var(--usk-native-on-primary); background: var(--usk-native-primary); }
573
+ [data-ui][data-theme][data-mode] ::-webkit-scrollbar { inline-size: .75rem; block-size: .75rem; }
574
+ [data-ui][data-theme][data-mode] ::-webkit-scrollbar-track { background: var(--usk-native-track); }
575
+ [data-ui][data-theme][data-mode] ::-webkit-scrollbar-thumb { background: var(--usk-native-thumb-border); border-radius: 999px; }
576
+
577
+ @media (prefers-reduced-motion: reduce) {
578
+ [data-ui][data-theme][data-mode] :where(input[type="file"])::file-selector-button,
579
+ [data-ui][data-theme][data-mode] :where(input[type="file"])::-webkit-file-upload-button {
580
+ transition-duration: 1ms !important;
581
+ }
582
+ }
583
+
584
+ @media (forced-colors: active) {
585
+ [data-ui][data-theme][data-mode] :where(input, textarea, select, button, progress, meter) {
586
+ forced-color-adjust: auto;
587
+ }
588
+
589
+ [data-ui][data-theme][data-mode] :where(input:user-invalid, textarea:user-invalid, select:user-invalid, [aria-invalid="true"], .is-invalid) {
590
+ border-color: Mark;
591
+ }
592
+ }
375
593
  }