@import url("https://fonts.googleapis.com/css2?family=IBM+Plex+Sans:wght@400;500;600;700&display=swap");
@import url("https://fonts.googleapis.com/css2?family=Fira+Code:wght@500;900&display=swap");

/* UNO design system — global entry point. Consumers link this one file. */
/* ==========================================================================
   PRIMITIVES — palette. Never referenced directly by components; components
   use the semantic aliases in semantic-light.css / semantic-dark.css.
   ========================================================================== */
:root {
  /* Brand — built outward from #8080FD, the visual average of the logo gradient */
  --uno-brand-50: #f0f0ff;
  --uno-brand-100: #e4e4ff;
  --uno-brand-200: #cdcdfe;
  --uno-brand-300: #b0b0fe;
  --uno-brand-400: #9898fd;
  --uno-brand-500: #8080fd; /* brand colour of record */
  --uno-brand-600: #6a5af0;
  --uno-brand-700: #5340d9;
  --uno-brand-800: #4230ab;
  --uno-brand-900: #372a85;
  --uno-brand-950: #221a55;

  /* Ink — neutrals carry the blue cast of #12121C so greys never look muddy
     next to the brand colour */
  --uno-ink-0: #ffffff;
  --uno-ink-50: #f4f4f8;
  --uno-ink-100: #e4e4ec;
  --uno-ink-200: #c4c4d4;
  --uno-ink-300: #9494ac;
  --uno-ink-400: #6e6e8a;
  --uno-ink-500: #4e4e68;
  --uno-ink-600: #35354a;
  --uno-ink-700: #252533;
  --uno-ink-800: #1a1a26;
  --uno-ink-900: #12121c; /* brand dark of record */
  --uno-ink-950: #0b0b12;

  /* Spectrum — the four corners of the logo. Data-vis, illustration and the
     brand gradient only. Not UI colours. */
  --uno-cyan: #21e5fe;
  --uno-electric: #2321ff;
  --uno-magenta: #e420ff;
  --uno-mist: #e3e4fd;

  /* Status — hue-shifted cool so they belong to this palette rather than
     arriving from a generic stoplight kit */
  --uno-success-500: #1bc47d;
  --uno-success-700: #0e8e58;
  --uno-success-100: #d6f7e8;
  --uno-warning-500: #f5a524;
  --uno-warning-700: #b26a00;
  --uno-warning-100: #fdf0d5;
  --uno-danger-500: #ff4d6a;
  --uno-danger-700: #c41d42;
  --uno-danger-100: #ffe0e6;
  --uno-info-500: #16b8e8;
  --uno-info-700: #0b7da3;
  --uno-info-100: #d4f2fb;

  /* Chart series — ordered so adjacent series never share a hue. Every series
     also needs a dash pattern or marker: no colour-only meaning. */
  --chart-1: #8080fd;
  --chart-2: #21e5fe;
  --chart-3: #e420ff;
  --chart-4: #1bc47d;
  --chart-5: #f5a524;
  --chart-6: #2321ff;
  --chart-7: #9494ac;
}

/*  */

:root {
  --font-display:
    "IBM Plex Sans", system-ui, -apple-system, "Segoe UI", sans-serif;
  --font-sans:
    "IBM Plex Sans", system-ui, -apple-system, "Segoe UI", sans-serif;
  --font-mono: "Fira Code", ui-monospace, monospace;

  /* Scale — 1.25 (major third) above body size, tightened below it */
  --text-2xs: 0.6875rem; /* 11px — dense table meta only */
  --text-xs: 0.75rem; /* 12px */
  --text-sm: 0.875rem; /* 14px — default UI size in the product */
  --text-base: 1rem; /* 16px — default reading size on marketing */
  --text-lg: 1.125rem; /* 18px */
  --text-xl: 1.375rem; /* 22px */
  --text-2xl: 1.75rem; /* 28px */
  --text-3xl: 2.25rem; /* 36px */
  --text-4xl: 3rem; /* 48px */
  --text-5xl: 4rem; /* 64px */
  --text-6xl: 5.25rem; /* 84px — hero only */

  --leading-none: 1; /* @kind font */
  --leading-tight: 1.15; /* @kind font */ /* display sizes, 2xl and up */
  --leading-snug: 1.35; /* @kind font */ /* headings and UI labels */
  --leading-normal: 1.55; /* @kind font */ /* body copy */
  --leading-loose: 1.7; /* @kind font */ /* long-form prose */

  --tracking-tighter: -0.03em; /* @kind font */ /* 4xl and up */
  --tracking-tight: -0.015em; /* @kind font */ /* 2xl–3xl */
  --tracking-normal: 0em; /* @kind font */
  --tracking-wide: 0.01em; /* @kind font */ /* 2xs–xs */

  --weight-regular: 400; /* @kind font */
  --weight-medium: 500; /* @kind font */
  --weight-semibold: 600; /* @kind font */
  --weight-bold: 700; /* @kind font */
}

/* Spacing — 4px base. Product density lives at --space-6; marketing section
   rhythm lives at --space-40. */
:root {
  --space-0: 0;
  --space-1: 0.25rem; /* 4 */
  --space-2: 0.5rem; /* 8 */
  --space-3: 0.75rem; /* 12 */
  --space-4: 1rem; /* 16 */
  --space-5: 1.25rem; /* 20 */
  --space-6: 1.5rem; /* 24 — product section rhythm */
  --space-8: 2rem; /* 32 */
  --space-10: 2.5rem; /* 40 */
  --space-12: 3rem; /* 48 */
  --space-16: 4rem; /* 64 */
  --space-20: 5rem; /* 80 */
  --space-24: 6rem; /* 96 */
  --space-32: 8rem; /* 128 */
  --space-40: 10rem; /* 160 — marketing section rhythm */
}

/* Radii — generous, matching the ratio of the logotype's grid squares.
   Borders live here too: one hairline, one emphasis weight. */
:root {
  --radius-xs: 1px;
  --radius-sm: 2px;
  --radius-md: 3px;
  --radius-lg: 4px;
  --radius-xl: 5px;
  --radius-2xl: 6px;
  --radius-full: 9999px;

  --border-width: 1px;
  --border-width-thick: 2px;
}

/* Motion — one curve for entering, one for leaving, one spring for anything
   the user directly manipulates. Never a fade-up per section on scroll. */
:root {
  --ease-out: cubic-bezier(0.16, 1, 0.3, 1); /* @kind other */
  --ease-in: cubic-bezier(0.7, 0, 0.84, 0); /* @kind other */
  --ease-spring: cubic-bezier(0.34, 1.56, 0.64, 1); /* @kind other */

  --duration-instant: 80ms; /* @kind other */
  --duration-fast: 140ms; /* @kind other */
  --duration-normal: 220ms; /* @kind other */
  --duration-slow: 400ms; /* @kind other */
}

/* Layout containers and stacking order */
:root {
  --container-prose: 68ch; /* @kind spacing */ /* keeps line length under 80 characters */
  --container-app: 1280px; /* @kind spacing */
  --container-site: 1200px; /* @kind spacing */
  --container-wide: 1440px; /* @kind spacing */

  --z-base: 0; /* @kind other */
  --z-raised: 10; /* @kind other */
  --z-sticky: 100; /* @kind other */
  --z-overlay: 200; /* @kind other */
  --z-modal: 300; /* @kind other */
  --z-popover: 400; /* @kind other */
  --z-toast: 500; /* @kind other */
}

/* The brand gradient, in the same diagonal direction as the logo.
   Appears once per view: hero OR primary action, never both. */
:root {
  --gradient-brand: linear-gradient(
    135deg,
    #21e5fe 0%,
    #2321ff 45%,
    #e420ff 100%
  ); /* @kind color */
  --gradient-brand-soft: linear-gradient(
    135deg,
    #21e5fe22 0%,
    #8080fd22 50%,
    #e420ff22 100%
  ); /* @kind color */
}

/* ==========================================================================
   SEMANTIC — LIGHT. What components actually reference.
   ========================================================================== */
:root,
[data-theme="light"] {
  color-scheme: light;

  --bg-page: var(--uno-ink-0);
  --bg-subtle: var(--uno-ink-50);
  --bg-inset: #ededf3;
  --bg-raised: var(--uno-ink-0);
  --bg-overlay: var(--uno-ink-0);
  --bg-scrim: rgba(18, 18, 28, 0.5);
  --bg-brand-subtle: var(--uno-brand-50);

  --border-subtle: var(--uno-ink-100);
  --border-default: #d5d5e0;
  --border-strong: var(--uno-ink-200);
  --border-brand: var(--uno-brand-300);

  --text-primary: var(--uno-ink-900);
  --text-secondary: var(--uno-ink-500);
  --text-tertiary: var(--uno-ink-400);
  --text-disabled: var(--uno-ink-300);
  --text-inverse: var(--uno-ink-0);

  /* #8080FD reaches only 3.27:1 on white, so it cannot carry text or act as a
     solid fill in light mode. The 700 step does both jobs at 6.8:1. The 500
     survives as ring, border, chart series and large display accent. */
  --brand-text: var(--uno-brand-700);
  --brand-solid: var(--uno-brand-700);
  --brand-solid-hover: var(--uno-brand-800);
  --brand-solid-active: var(--uno-brand-900);
  --brand-on-solid: var(--uno-ink-0);
  --brand-accent: var(--uno-brand-500);
  --brand-ring: var(--uno-brand-500);

  --success-bg: var(--uno-success-100);
  --success-fg: var(--uno-success-700);
  --success-border: #8fe3be;
  --warning-bg: var(--uno-warning-100);
  --warning-fg: var(--uno-warning-700);
  --warning-border: #f2ce88;
  --danger-bg: var(--uno-danger-100);
  --danger-fg: var(--uno-danger-700);
  --danger-border: #ffa8b8;
  --info-bg: var(--uno-info-100);
  --info-fg: var(--uno-info-700);
  --info-border: #93ddf2;
}

/* ==========================================================================
   SEMANTIC — DARK. Light and dark are equals here, not a theme and its
   afterthought. Every component is designed in both before it is called done.
   ========================================================================== */
[data-theme="dark"] {
  color-scheme: dark;

  --bg-page: var(--uno-ink-900);
  --bg-subtle: var(--uno-ink-800);
  --bg-inset: var(--uno-ink-950);
  --bg-raised: var(--uno-ink-800);
  --bg-overlay: #22222f;
  --bg-scrim: rgba(5, 5, 10, 0.7);
  --bg-brand-subtle: rgba(128, 128, 253, 0.12);

  --border-subtle: #1f1f2c;
  --border-default: #2a2a3a;
  --border-strong: #3a3a4e;
  --border-brand: rgba(128, 128, 253, 0.5);

  --text-primary: var(--uno-ink-50);
  --text-secondary: #a8a8be;
  --text-tertiary: #7c7c94;
  --text-disabled: #55556b;
  --text-inverse: var(--uno-ink-900);

  /* On dark, #8080FD finally gets to be the button — with a DARK label. White
     on #8080FD is the same failing 3.27:1; ink-950 on it clears 5.6:1. */
  --brand-text: var(--uno-brand-400);
  --brand-solid: var(--uno-brand-500);
  --brand-solid-hover: var(--uno-brand-400);
  --brand-solid-active: var(--uno-brand-300);
  --brand-on-solid: var(--uno-ink-950);
  --brand-accent: var(--uno-brand-500);
  --brand-ring: var(--uno-brand-400);

  --success-bg: rgba(27, 196, 125, 0.15);
  --success-fg: #5be0a6;
  --success-border: rgba(27, 196, 125, 0.4);
  --warning-bg: rgba(245, 165, 36, 0.15);
  --warning-fg: #fbc366;
  --warning-border: rgba(245, 165, 36, 0.4);
  --danger-bg: rgba(255, 77, 106, 0.15);
  --danger-fg: #ff8a9e;
  --danger-border: rgba(255, 77, 106, 0.4);
  --info-bg: rgba(22, 184, 232, 0.15);
  --info-fg: #6bd5f5;
  --info-border: rgba(22, 184, 232, 0.4);

  /* Shadows barely register on a #12121C page. They stay defined so nothing
     breaks, but depth in dark mode comes from --bg-raised and --border-*. */
  --shadow-xs: 0 1px 2px rgba(0, 0, 0, 0.4);
  --shadow-sm: 0 2px 4px rgba(0, 0, 0, 0.45);
  --shadow-md: 0 8px 16px -4px rgba(0, 0, 0, 0.5);
  --shadow-lg: 0 20px 32px -8px rgba(0, 0, 0, 0.55);
  --shadow-xl: 0 32px 64px -16px rgba(0, 0, 0, 0.6);
  --shadow-focus: 0 0 0 3px rgba(128, 128, 253, 0.45);
}

/* data-theme="system" follows the OS. Set it on <html> when you want the OS
   preference to win; otherwise set "light" or "dark" explicitly. */
@media (prefers-color-scheme: dark) {
  [data-theme="system"] {
    color-scheme: dark;

    --bg-page: var(--uno-ink-900);
    --bg-subtle: var(--uno-ink-800);
    --bg-inset: var(--uno-ink-950);
    --bg-raised: var(--uno-ink-800);
    --bg-overlay: #22222f;
    --bg-scrim: rgba(5, 5, 10, 0.7);
    --bg-brand-subtle: rgba(128, 128, 253, 0.12);

    --border-subtle: #1f1f2c;
    --border-default: #2a2a3a;
    --border-strong: #3a3a4e;
    --border-brand: rgba(128, 128, 253, 0.5);

    --text-primary: var(--uno-ink-50);
    --text-secondary: #a8a8be;
    --text-tertiary: #7c7c94;
    --text-disabled: #55556b;
    --text-inverse: var(--uno-ink-900);

    /* On dark, #8080FD finally gets to be the button — with a DARK label. White
     on #8080FD is the same failing 3.27:1; ink-950 on it clears 5.6:1. */
    --brand-text: var(--uno-brand-400);
    --brand-solid: var(--uno-brand-500);
    --brand-solid-hover: var(--uno-brand-400);
    --brand-solid-active: var(--uno-brand-300);
    --brand-on-solid: var(--uno-ink-950);
    --brand-accent: var(--uno-brand-500);
    --brand-ring: var(--uno-brand-400);

    --success-bg: rgba(27, 196, 125, 0.15);
    --success-fg: #5be0a6;
    --success-border: rgba(27, 196, 125, 0.4);
    --warning-bg: rgba(245, 165, 36, 0.15);
    --warning-fg: #fbc366;
    --warning-border: rgba(245, 165, 36, 0.4);
    --danger-bg: rgba(255, 77, 106, 0.15);
    --danger-fg: #ff8a9e;
    --danger-border: rgba(255, 77, 106, 0.4);
    --info-bg: rgba(22, 184, 232, 0.15);
    --info-fg: #6bd5f5;
    --info-border: rgba(22, 184, 232, 0.4);

    /* Shadows barely register on a #12121C page. They stay defined so nothing
     breaks, but depth in dark mode comes from --bg-raised and --border-*. */
    --shadow-xs: 0 1px 2px rgba(0, 0, 0, 0.4);
    --shadow-sm: 0 2px 4px rgba(0, 0, 0, 0.45);
    --shadow-md: 0 8px 16px -4px rgba(0, 0, 0, 0.5);
    --shadow-lg: 0 20px 32px -8px rgba(0, 0, 0, 0.55);
    --shadow-xl: 0 32px 64px -16px rgba(0, 0, 0, 0.6);
    --shadow-focus: 0 0 0 3px rgba(128, 128, 253, 0.45);
  }
}

/* Elevation — tinted with the ink hue rather than pure black, and each level
   changes blur AND spread so the hierarchy reads at a glance.
   (Dark-mode overrides live in semantic-dark.css.) */
:root,
[data-theme="light"] {
  --shadow-xs: 0 1px 2px rgba(18, 18, 28, 0.06);
  --shadow-sm:
    0 2px 4px rgba(18, 18, 28, 0.06), 0 1px 2px rgba(18, 18, 28, 0.04);
  --shadow-md:
    0 8px 16px -4px rgba(18, 18, 28, 0.08), 0 2px 4px rgba(18, 18, 28, 0.04);
  --shadow-lg:
    0 20px 32px -8px rgba(18, 18, 28, 0.12), 0 4px 8px rgba(18, 18, 28, 0.04);
  --shadow-xl: 0 32px 64px -16px rgba(18, 18, 28, 0.18);
  --shadow-focus: 0 0 0 3px rgba(128, 128, 253, 0.35);
}

/* Baseline reset + the two rules every UNO surface relies on */
*,
*::before,
*::after {
  box-sizing: border-box;
}

body {
  margin: 0;
  background: var(--bg-page);
  color: var(--text-primary);
  font-family: var(--font-sans);
  font-size: var(--text-base);
  line-height: var(--leading-normal);
  -webkit-font-smoothing: antialiased;
}

/* Form controls do not inherit type from the page — without this they fall back
   to the browser UI font (Arial/Helvetica) and drop out of the system. */
button,
input,
select,
textarea,
optgroup {
  font-family: inherit;
  font-size: inherit;
  line-height: inherit;
  letter-spacing: inherit;
  color: inherit;
}

/* Code elements default to the browser monospace — pin them to the system mono */
code,
kbd,
samp,
pre,
tt {
  font-family: var(--font-mono);
  font-size: 1em;
}

/* Tabular figures everywhere numbers are compared in a column */
.tabular,
td[data-numeric],
.metric {
  font-variant-numeric: tabular-nums;
  font-family: var(--font-mono);
}

/* Links: sentence case, brand text colour, underline on hover only */
a {
  color: var(--brand-text);
  text-decoration: none;
}
a:hover {
  color: var(--brand-solid-hover);
  text-decoration: underline;
  text-underline-offset: 2px;
}
[data-theme="dark"] a:hover {
  color: var(--uno-brand-300);
}

:where(a, button, input, select, textarea, [tabindex]):focus-visible {
  outline: 2px solid var(--brand-ring);
  outline-offset: 2px;
  border-radius: var(--radius-xs);
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }
}

/* ==========================================================================
   BRAND PATTERN
   The rounded-square grid lifted straight from the logo: 48px tiles separated
   by a hairline gap whose rounded corners open into the logo's four-pointed
   star at every intersection. Same DNA, no logo repetition.

   .uno-grid            the texture, radially faded — hero, empty state,
                        skeleton field (the three sanctioned framed uses)
   .uno-grid--flat      same texture, no fade
   .uno-grid--page      full-viewport backdrop layer for a whole page. Put it
                        on one aria-hidden element as the first child of body:
                        <span class="uno-grid uno-grid--page" aria-hidden="true"></span>
                        It is fixed, pointer-transparent and sits at z-index 0,
                        so page content needs position:relative above it.
   --uno-grid-size      cell size (default 48px; data-grid-scale="sm" 24px,
                        data-grid-scale="lg" 96px on the element or an ancestor)
   Colour is currentColor. Keep it under 8% opacity behind text.
   ========================================================================== */
:root {
  --uno-grid-size: 48px; /* @kind spacing */
  /* One tile: the gap between four rounded squares, drawn as a frame with
     concave corners. Half-thickness per edge so tiled edges add up to 1.5px. */
  --uno-grid-tile: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='48' height='48'%3E%3Cpath fill='%23000' fill-rule='evenodd' d='M0 0h48v48H0Z M9.75 .75H38.25A9 9 0 0 1 47.25 9.75V38.25A9 9 0 0 1 38.25 47.25H9.75A9 9 0 0 1 .75 38.25V9.75A9 9 0 0 1 9.75 .75Z'/%3E%3C/svg%3E"); /* @kind other */
}
.uno-grid {
  background-color: currentColor;
  color: var(--border-subtle);
  -webkit-mask-image:
    var(--uno-grid-tile),
    radial-gradient(ellipse at center, #000 20%, transparent 75%);
  mask-image:
    var(--uno-grid-tile),
    radial-gradient(ellipse at center, #000 20%, transparent 75%);
  -webkit-mask-size:
    var(--uno-grid-size) var(--uno-grid-size),
    100% 100%;
  mask-size:
    var(--uno-grid-size) var(--uno-grid-size),
    100% 100%;
  -webkit-mask-repeat: repeat, no-repeat;
  mask-repeat: repeat, no-repeat;
  -webkit-mask-composite: source-in;
  mask-composite: intersect;
}
.uno-grid--flat {
  -webkit-mask-image: var(--uno-grid-tile);
  mask-image: var(--uno-grid-tile);
  -webkit-mask-size: var(--uno-grid-size) var(--uno-grid-size);
  mask-size: var(--uno-grid-size) var(--uno-grid-size);
  -webkit-mask-repeat: repeat;
  mask-repeat: repeat;
}
.uno-grid--page {
  position: fixed;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  color: color-mix(in srgb, var(--text-primary) 6%, transparent);
  -webkit-mask-image: var(--uno-grid-tile);
  mask-image: var(--uno-grid-tile);
  -webkit-mask-size: var(--uno-grid-size) var(--uno-grid-size);
  mask-size: var(--uno-grid-size) var(--uno-grid-size);
  -webkit-mask-position: 50% 0;
  mask-position: 50% 0;
  -webkit-mask-repeat: repeat;
  mask-repeat: repeat;
}
[data-grid-scale="sm"] {
  --uno-grid-size: 24px;
}
[data-grid-scale="lg"] {
  --uno-grid-size: 96px;
}

/* Display type clipped to the brand gradient. One line per page, at most. */
.uno-gradient-text {
  background: var(--gradient-brand);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

/* Component styles. Imported by the root styles.css. */
/* ===== Button ============================================================ */
.uno-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: var(--space-2);
  font-family: var(--font-sans);
  font-weight: var(--weight-medium);
  border: var(--border-width) solid transparent;
  border-radius: var(--radius-md);
  cursor: pointer;
  text-decoration: none;
  white-space: nowrap;
  position: relative;
  transition:
    background-color var(--duration-fast) var(--ease-out),
    color var(--duration-fast) var(--ease-out),
    border-color var(--duration-fast) var(--ease-out),
    transform var(--duration-instant) var(--ease-out);
}
.uno-btn:active:not(:disabled) {
  transform: translateY(1px);
}
.uno-btn:disabled,
.uno-btn[aria-disabled="true"] {
  cursor: not-allowed;
  opacity: 1;
}
.uno-btn--sm {
  height: 32px;
  padding: 0 var(--space-3);
  font-size: var(--text-xs);
  border-radius: var(--radius-sm);
}
.uno-btn--md {
  height: 40px;
  padding: 0 var(--space-4);
  font-size: var(--text-sm);
}
.uno-btn--lg {
  height: 48px;
  padding: 0 var(--space-6);
  font-size: var(--text-base);
}
.uno-btn--icon.uno-btn--sm {
  width: 32px;
  padding: 0;
}
.uno-btn--icon.uno-btn--md {
  width: 40px;
  padding: 0;
}
.uno-btn--icon.uno-btn--lg {
  width: 48px;
  padding: 0;
}
/* The characteristic inversion: deep violet + white label in light mode,
   bright periwinkle + near-black label in dark mode. */
.uno-btn--primary {
  background: var(--brand-solid);
  color: var(--brand-on-solid);
}
.uno-btn--primary:hover:not(:disabled) {
  background: var(--brand-solid-hover);
}
.uno-btn--primary:active:not(:disabled) {
  background: var(--brand-solid-active);
}
.uno-btn--primary:disabled {
  background: var(--bg-inset);
  color: var(--text-disabled);
}
.uno-btn--secondary {
  background: var(--bg-raised);
  color: var(--text-primary);
  border-color: var(--border-default);
  box-shadow: var(--shadow-xs);
}
.uno-btn--secondary:hover:not(:disabled) {
  background: var(--bg-subtle);
  border-color: var(--border-strong);
}
.uno-btn--secondary:active:not(:disabled) {
  background: var(--bg-inset);
}
.uno-btn--secondary:disabled {
  color: var(--text-disabled);
  border-color: var(--border-subtle);
  box-shadow: none;
}
.uno-btn--ghost {
  background: transparent;
  color: var(--text-secondary);
}
.uno-btn--ghost:hover:not(:disabled) {
  background: var(--bg-subtle);
  color: var(--text-primary);
}
.uno-btn--ghost:active:not(:disabled) {
  background: var(--bg-inset);
}
.uno-btn--ghost:disabled {
  color: var(--text-disabled);
}
.uno-btn--danger {
  background: var(--uno-danger-700);
  color: #fff;
}
.uno-btn--danger:hover:not(:disabled) {
  background: #a81536;
}
.uno-btn--danger:active:not(:disabled) {
  background: #8c0f2c;
}
.uno-btn--danger:disabled {
  background: var(--bg-inset);
  color: var(--text-disabled);
}
[data-theme="dark"] .uno-btn--danger {
  background: var(--uno-danger-500);
  color: var(--uno-ink-950);
}
[data-theme="dark"] .uno-btn--danger:hover:not(:disabled) {
  background: #ff7189;
}
.uno-btn--loading {
  color: transparent !important;
}
.uno-btn__spin {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  color: var(--brand-on-solid);
}
.uno-btn--secondary .uno-btn__spin,
.uno-btn--ghost .uno-btn__spin {
  color: var(--text-primary);
}
.uno-btn--block {
  width: 100%;
}

/* ===== Link ============================================================== */
.uno-link {
  color: var(--brand-text);
  font-weight: var(--weight-medium);
  text-decoration: none;
  border-radius: 2px;
  transition: color var(--duration-fast) var(--ease-out);
}
.uno-link:hover {
  color: var(--brand-solid-hover);
  text-decoration: underline;
  text-underline-offset: 2px;
}
[data-theme="dark"] .uno-link:hover {
  color: var(--uno-brand-300);
}
.uno-link--quiet {
  color: var(--text-secondary);
}
.uno-link--quiet:hover {
  color: var(--text-primary);
  text-decoration: underline;
  text-underline-offset: 2px;
}
.uno-link--inline {
  text-decoration: underline;
  text-underline-offset: 2px;
  text-decoration-thickness: 1px;
  font-weight: inherit;
}

/* ===== Icon ============================================================== */
.uno-icon {
  display: inline-block;
  flex: 0 0 auto;
  vertical-align: -0.145em;
  overflow: visible;
}

/* ===== Avatar ============================================================ */
.uno-avatar {
  display: inline-grid;
  place-items: center;
  overflow: hidden;
  flex: 0 0 auto;
  background: var(--bg-brand-subtle);
  color: var(--brand-text);
  font-family: var(--font-display);
  font-weight: var(--weight-medium);
  letter-spacing: var(--tracking-normal);
  border-radius: var(--radius-full);
  user-select: none;
}
.uno-avatar--square {
  border-radius: var(--radius-sm);
}
.uno-avatar img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}
.uno-avatar--xs {
  width: 20px;
  height: 20px;
  font-size: 9px;
  letter-spacing: -0.02em;
}
.uno-avatar--sm {
  width: 28px;
  height: 28px;
  font-size: var(--text-2xs);
  letter-spacing: -0.02em;
}
.uno-avatar--md {
  width: 36px;
  height: 36px;
  font-size: var(--text-sm);
}
.uno-avatar--lg {
  width: 48px;
  height: 48px;
  font-size: var(--text-base);
}
.uno-avatar--xl {
  width: 64px;
  height: 64px;
  font-size: var(--text-xl);
}
.uno-avatar-group {
  display: flex;
}
.uno-avatar-group > .uno-avatar {
  box-shadow: 0 0 0 2px var(--bg-page);
  margin-left: -8px;
}
.uno-avatar-group > .uno-avatar:first-child {
  margin-left: 0;
}

/* ===== Badge ============================================================= */
.uno-badge {
  display: inline-flex;
  align-items: center;
  gap: var(--space-1);
  height: 20px;
  padding: 0 var(--space-2);
  font-size: var(--text-2xs);
  font-weight: var(--weight-semibold);
  letter-spacing: var(--tracking-wide);
  border-radius: var(--radius-full);
  border: var(--border-width) solid transparent;
}
.uno-badge--neutral {
  background: var(--bg-inset);
  color: var(--text-secondary);
  border-color: var(--border-subtle);
}
.uno-badge--brand {
  background: var(--bg-brand-subtle);
  color: var(--brand-text);
  border-color: var(--border-brand);
}
.uno-badge--success {
  background: var(--success-bg);
  color: var(--success-fg);
  border-color: var(--success-border);
}
.uno-badge--warning {
  background: var(--warning-bg);
  color: var(--warning-fg);
  border-color: var(--warning-border);
}
.uno-badge--danger {
  background: var(--danger-bg);
  color: var(--danger-fg);
  border-color: var(--danger-border);
}
.uno-badge--info {
  background: var(--info-bg);
  color: var(--info-fg);
  border-color: var(--info-border);
}
.uno-badge__dot {
  width: 6px;
  height: 6px;
  border-radius: var(--radius-full);
  background: currentColor;
}
.uno-badge--count {
  min-width: 20px;
  justify-content: center;
  font-family: var(--font-mono);
  font-variant-numeric: tabular-nums;
}

/* ===== Tag =============================================================== */
.uno-tag {
  display: inline-flex;
  align-items: center;
  gap: var(--space-1);
  height: 24px;
  padding: 0 var(--space-2);
  font-size: var(--text-xs);
  font-weight: var(--weight-medium);
  color: var(--text-primary);
  background: var(--bg-subtle);
  border: var(--border-width) solid var(--border-subtle);
  border-radius: var(--radius-xs);
}
.uno-tag--selected {
  background: var(--bg-brand-subtle);
  border-color: var(--border-brand);
  color: var(--brand-text);
}
.uno-tag__remove {
  display: grid;
  place-items: center;
  width: 16px;
  height: 16px;
  margin-right: -2px;
  border: 0;
  padding: 0;
  background: transparent;
  color: var(--text-tertiary);
  border-radius: var(--radius-xs);
  cursor: pointer;
}
.uno-tag__remove:hover {
  background: var(--bg-inset);
  color: var(--text-primary);
}

/* ===== Kbd =============================================================== */
.uno-kbd {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 20px;
  height: 20px;
  padding: 0 5px;
  font-family: var(--font-mono);
  font-size: var(--text-2xs);
  color: var(--text-secondary);
  background: var(--bg-raised);
  border: var(--border-width) solid var(--border-default);
  border-bottom-width: var(--border-width-thick);
  border-radius: var(--radius-xs);
}

/* ===== Spinner =========================================================== */
@keyframes uno-spin {
  to {
    transform: rotate(360deg);
  }
}
.uno-spinner {
  display: inline-block;
  flex: 0 0 auto;
  border-radius: var(--radius-full);
  border: 2px solid currentColor;
  border-top-color: transparent;
  border-right-color: transparent;
  animation: uno-spin 700ms linear infinite;
  opacity: 0.9;
}

/* ===== Skeleton ========================================================== */
@keyframes uno-shimmer {
  0% {
    background-position: 200% 0;
  }
  100% {
    background-position: -200% 0;
  }
}
.uno-skeleton {
  display: block;
  background: linear-gradient(
    90deg,
    var(--bg-inset) 0%,
    var(--bg-subtle) 40%,
    var(--bg-inset) 80%
  );
  background-size: 200% 100%;
  animation: uno-shimmer 1.6s var(--ease-out) infinite;
  border-radius: var(--radius-sm);
}
.uno-skeleton--text {
  height: 0.75em;
  border-radius: var(--radius-xs);
}
.uno-skeleton--circle {
  border-radius: var(--radius-full);
}
/* Skeleton fields can also use the brand grid pattern — see .uno-grid */

/* ===== Divider =========================================================== */
.uno-divider {
  border: 0;
  background: var(--border-subtle);
  flex: 0 0 auto;
}
.uno-divider--h {
  height: 1px;
  width: 100%;
  margin: var(--space-4) 0;
}
.uno-divider--v {
  width: 1px;
  align-self: stretch;
  min-height: 1em;
  margin: 0 var(--space-3);
}
.uno-divider--labelled {
  display: flex;
  align-items: center;
  gap: var(--space-3);
  background: none;
  margin: var(--space-4) 0;
  color: var(--text-tertiary);
  font-size: var(--text-xs);
}
.uno-divider--labelled::before,
.uno-divider--labelled::after {
  content: "";
  flex: 1;
  height: 1px;
  background: var(--border-subtle);
}

/* ===== Field wrapper ===================================================== */
.uno-field {
  display: flex;
  flex-direction: column;
  gap: var(--space-2);
}
.uno-field__label {
  font-size: var(--text-sm);
  font-weight: var(--weight-medium);
  color: var(--text-primary);
  display: flex;
  align-items: center;
  gap: var(--space-2);
}
.uno-field__req {
  color: var(--danger-fg);
  font-weight: var(--weight-regular);
}
.uno-field__optional {
  color: var(--text-tertiary);
  font-weight: var(--weight-regular);
  font-size: var(--text-xs);
}
.uno-field__hint {
  font-size: var(--text-xs);
  color: var(--text-tertiary);
  line-height: var(--leading-snug);
}
.uno-field__error {
  display: flex;
  align-items: flex-start;
  gap: var(--space-1);
  font-size: var(--text-xs);
  color: var(--danger-fg);
  line-height: var(--leading-snug);
}

/* ===== Form section ====================================================== */
.uno-formsection {
  display: grid;
  grid-template-columns: minmax(0, 240px) minmax(0, 1fr);
  gap: var(--space-10);
  padding: var(--space-8) 0;
  border-top: 1px solid var(--border-subtle);
}
.uno-formsection:first-child {
  border-top: 0;
  padding-top: 0;
}
.uno-formsection__title {
  font-family: var(--font-display);
  font-size: var(--text-lg);
  font-weight: var(--weight-medium);
  letter-spacing: var(--tracking-tight);
  margin: 0 0 var(--space-2);
}
.uno-formsection__desc {
  font-size: var(--text-sm);
  color: var(--text-secondary);
  margin: 0;
  max-width: 34ch;
}
.uno-formsection__body {
  display: flex;
  flex-direction: column;
  gap: var(--space-5);
}
@media (max-width: 720px) {
  .uno-formsection {
    grid-template-columns: 1fr;
    gap: var(--space-5);
  }
}

/* ===== Text input / textarea / select shared control =================== */
.uno-control {
  display: flex;
  align-items: center;
  gap: var(--space-2);
  width: 100%;
  background: var(--bg-raised);
  border: var(--border-width) solid var(--border-default);
  border-radius: var(--radius-sm);
  color: var(--text-primary);
  transition:
    border-color var(--duration-fast) var(--ease-out),
    box-shadow var(--duration-fast) var(--ease-out),
    background-color var(--duration-fast) var(--ease-out);
}
.uno-control:hover:not([data-disabled]) {
  border-color: var(--border-strong);
}
.uno-control[data-focus] {
  border-color: var(--brand-accent);
  box-shadow: var(--shadow-focus);
}
.uno-control[data-invalid] {
  border-color: var(--danger-border);
}
.uno-control[data-invalid][data-focus] {
  box-shadow: 0 0 0 3px rgba(255, 77, 106, 0.3);
}
.uno-control[data-disabled] {
  background: var(--bg-inset);
  color: var(--text-disabled);
  cursor: not-allowed;
}
.uno-control--sm {
  height: 32px;
  padding: 0 var(--space-2);
  font-size: var(--text-xs);
}
.uno-control--md {
  height: 40px;
  padding: 0 var(--space-3);
  font-size: var(--text-sm);
}
.uno-control--lg {
  height: 48px;
  padding: 0 var(--space-4);
  font-size: var(--text-base);
}
.uno-control__input {
  flex: 1 1 auto;
  min-width: 0;
  border: 0;
  outline: 0;
  background: transparent;
  color: inherit;
  font: inherit;
  padding: 0;
}
.uno-control__input::placeholder {
  color: var(--text-tertiary);
}
.uno-control__affix {
  color: var(--text-tertiary);
  flex: 0 0 auto;
  display: flex;
  align-items: center;
  font-size: var(--text-xs);
}
.uno-textarea {
  min-height: 96px;
  height: auto;
  padding: var(--space-3);
  align-items: stretch;
}
.uno-textarea .uno-control__input {
  resize: vertical;
  line-height: var(--leading-normal);
}

/* ===== Native select ===================================================== */
.uno-select {
  position: relative;
}
.uno-select select {
  appearance: none;
  flex: 1;
  border: 0;
  outline: 0;
  background: transparent;
  color: inherit;
  font: inherit;
  padding: 0;
  padding-right: var(--space-5);
  cursor: pointer;
}
.uno-select__chev {
  position: absolute;
  right: var(--space-3);
  pointer-events: none;
  color: var(--text-tertiary);
}

/* ===== Combobox ========================================================== */
.uno-combobox {
  position: relative;
}
.uno-combobox__list {
  position: absolute;
  top: calc(100% + 4px);
  left: 0;
  right: 0;
  z-index: var(--z-popover);
  max-height: 220px;
  overflow: auto;
  padding: var(--space-1);
  background: var(--bg-overlay);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-lg);
}
.uno-combobox__opt {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-2);
  padding: var(--space-2) var(--space-2);
  font-size: var(--text-sm);
  border-radius: var(--radius-xs);
  cursor: pointer;
  color: var(--text-primary);
}
.uno-combobox__opt[data-active] {
  background: var(--bg-subtle);
}
.uno-combobox__opt[aria-selected="true"] {
  color: var(--brand-text);
  font-weight: var(--weight-medium);
}
.uno-combobox__empty {
  padding: var(--space-3);
  font-size: var(--text-xs);
  color: var(--text-tertiary);
}

/* ===== Checkbox / Radio ================================================== */
.uno-choice {
  display: flex;
  align-items: flex-start;
  gap: var(--space-3);
  font-size: var(--text-sm);
  color: var(--text-primary);
  cursor: pointer;
}
.uno-choice[data-disabled] {
  color: var(--text-disabled);
  cursor: not-allowed;
}
.uno-choice input {
  position: absolute;
  opacity: 0;
  width: 1px;
  height: 1px;
}
.uno-choice__box {
  flex: 0 0 auto;
  display: grid;
  place-items: center;
  width: 18px;
  height: 18px;
  margin-top: 1px;
  background: var(--bg-raised);
  border: var(--border-width) solid var(--border-strong);
  border-radius: var(--radius-xs);
  color: var(--brand-on-solid);
  transition:
    background-color var(--duration-fast) var(--ease-out),
    border-color var(--duration-fast) var(--ease-out);
}
.uno-choice__box--radio {
  border-radius: var(--radius-full);
}
.uno-choice:hover .uno-choice__box {
  border-color: var(--brand-accent);
}
.uno-choice input:checked + .uno-choice__box,
.uno-choice input:indeterminate + .uno-choice__box {
  background: var(--brand-solid);
  border-color: var(--brand-solid);
}
.uno-choice input:focus-visible + .uno-choice__box {
  box-shadow: var(--shadow-focus);
}
.uno-choice[data-disabled] .uno-choice__box {
  background: var(--bg-inset);
  border-color: var(--border-subtle);
}
.uno-choice__dot {
  width: 7px;
  height: 7px;
  border-radius: var(--radius-full);
  background: var(--brand-on-solid);
}
.uno-choice__text {
  display: flex;
  flex-direction: column;
  gap: 2px;
  line-height: var(--leading-snug);
}
.uno-choice__desc {
  font-size: var(--text-xs);
  color: var(--text-secondary);
}

/* ===== Switch ============================================================ */
.uno-switch {
  display: inline-flex;
  align-items: center;
  gap: var(--space-3);
  cursor: pointer;
  font-size: var(--text-sm);
}
.uno-switch input {
  position: absolute;
  opacity: 0;
  width: 1px;
  height: 1px;
}
.uno-switch__track {
  position: relative;
  flex: 0 0 auto;
  width: 38px;
  height: 22px;
  border-radius: var(--radius-full);
  background: var(--border-strong);
  transition: background-color var(--duration-normal) var(--ease-out);
}
.uno-switch__knob {
  position: absolute;
  top: 3px;
  left: 3px;
  width: 16px;
  height: 16px;
  border-radius: var(--radius-full);
  background: var(--bg-raised);
  box-shadow: var(--shadow-sm);
  transition: transform var(--duration-normal) var(--ease-spring);
}
.uno-switch input:checked + .uno-switch__track {
  background: var(--brand-solid);
}
.uno-switch input:checked + .uno-switch__track .uno-switch__knob {
  transform: translateX(16px);
}
.uno-switch input:focus-visible + .uno-switch__track {
  box-shadow: var(--shadow-focus);
}
.uno-switch[data-disabled] {
  cursor: not-allowed;
  color: var(--text-disabled);
}
.uno-switch[data-disabled] .uno-switch__track {
  background: var(--bg-inset);
}

/* ===== Slider ============================================================ */
.uno-slider {
  display: flex;
  flex-direction: column;
  gap: var(--space-2);
  width: 100%;
}
.uno-slider input[type="range"] {
  appearance: none;
  width: 100%;
  height: 20px;
  background: transparent;
  cursor: pointer;
}
.uno-slider input[type="range"]::-webkit-slider-runnable-track {
  height: 4px;
  border-radius: var(--radius-full);
  background: var(--bg-inset);
}
.uno-slider input[type="range"]::-webkit-slider-thumb {
  appearance: none;
  margin-top: -6px;
  width: 16px;
  height: 16px;
  border-radius: var(--radius-full);
  background: var(--brand-solid);
  border: 2px solid var(--bg-raised);
  box-shadow: var(--shadow-sm);
  transition: transform var(--duration-fast) var(--ease-spring);
}
.uno-slider input[type="range"]:active::-webkit-slider-thumb {
  transform: scale(1.15);
}
.uno-slider input[type="range"]::-moz-range-track {
  height: 4px;
  border-radius: var(--radius-full);
  background: var(--bg-inset);
}
.uno-slider input[type="range"]::-moz-range-thumb {
  width: 16px;
  height: 16px;
  border: 2px solid var(--bg-raised);
  border-radius: var(--radius-full);
  background: var(--brand-solid);
}
.uno-slider__row {
  display: flex;
  justify-content: space-between;
  font-size: var(--text-xs);
  color: var(--text-secondary);
}
.uno-slider__val {
  font-family: var(--font-mono);
  font-variant-numeric: tabular-nums;
  color: var(--text-primary);
}

/* ===== Date picker ======================================================= */
.uno-datepicker {
  position: relative;
}
.uno-cal {
  position: absolute;
  top: calc(100% + 4px);
  left: 0;
  z-index: var(--z-popover);
  width: 268px;
  padding: var(--space-3);
  background: var(--bg-overlay);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-lg);
}
.uno-cal__head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: var(--space-2);
}
.uno-cal__month {
  font-size: var(--text-sm);
  font-weight: var(--weight-medium);
}
.uno-cal__grid {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  gap: 2px;
}
.uno-cal__dow {
  text-align: center;
  font-size: var(--text-2xs);
  color: var(--text-tertiary);
  padding: var(--space-1) 0;
}
.uno-cal__day {
  aspect-ratio: 1;
  display: grid;
  place-items: center;
  font-family: var(--font-mono);
  font-size: var(--text-xs);
  font-variant-numeric: tabular-nums;
  border: 0;
  background: transparent;
  color: var(--text-primary);
  border-radius: var(--radius-xs);
  cursor: pointer;
}
.uno-cal__day:hover {
  background: var(--bg-subtle);
}
.uno-cal__day[data-muted] {
  color: var(--text-disabled);
}
.uno-cal__day[data-today] {
  box-shadow: inset 0 0 0 1px var(--border-brand);
}
.uno-cal__day[aria-selected="true"] {
  background: var(--brand-solid);
  color: var(--brand-on-solid);
}

/* ===== File upload ======================================================= */
.uno-upload {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: var(--space-2);
  padding: var(--space-8) var(--space-6);
  text-align: center;
  border: var(--border-width-thick) dashed var(--border-default);
  border-radius: var(--radius-lg);
  background: var(--bg-subtle);
  color: var(--text-secondary);
  font-size: var(--text-sm);
  cursor: pointer;
  transition:
    border-color var(--duration-fast) var(--ease-out),
    background-color var(--duration-fast) var(--ease-out);
}
.uno-upload:hover,
.uno-upload[data-over] {
  border-color: var(--brand-accent);
  background: var(--bg-brand-subtle);
}
.uno-upload__icon {
  color: var(--brand-accent);
}
.uno-upload__hint {
  font-size: var(--text-xs);
  color: var(--text-tertiary);
}
.uno-upload__files {
  display: flex;
  flex-direction: column;
  gap: var(--space-2);
  margin-top: var(--space-3);
  width: 100%;
}
.uno-upload__file {
  display: flex;
  align-items: center;
  gap: var(--space-2);
  padding: var(--space-2) var(--space-3);
  font-size: var(--text-xs);
  background: var(--bg-raised);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-sm);
  text-align: left;
}
.uno-upload__size {
  margin-left: auto;
  font-family: var(--font-mono);
  color: var(--text-tertiary);
}

/* ===== Top nav (marketing) ============================================== */
.uno-topnav {
  position: sticky;
  top: 0;
  z-index: var(--z-sticky);
  background: color-mix(in srgb, var(--bg-page) 82%, transparent);
  backdrop-filter: blur(12px) saturate(1.4);
  border-bottom: 1px solid var(--border-subtle);
}
.uno-topnav__inner {
  max-width: var(--container-site);
  margin: 0 auto;
  height: 64px;
  display: flex;
  align-items: center;
  gap: var(--space-8);
  padding: 0 var(--space-6);
}
.uno-topnav__links {
  display: flex;
  align-items: center;
  gap: var(--space-6);
  flex: 1;
}
.uno-topnav__link {
  font-size: var(--text-sm);
  font-weight: var(--weight-bold);
  color: var(--text-secondary);
  text-decoration: none;
  transition: color var(--duration-fast) var(--ease-out);
}
.uno-topnav__link:hover {
  color: var(--text-primary);
  text-decoration: none;
}
.uno-topnav__link[aria-current="page"] {
  color: var(--text-primary);
}
.uno-topnav__actions {
  display: flex;
  align-items: center;
  gap: var(--space-3);
}
@media (max-width: 720px) {
  .uno-topnav__links {
    display: none;
  }
}

/* ===== App shell ========================================================= */
.uno-shell {
  display: grid;
  grid-template-columns: var(--uno-sidebar, 248px) minmax(0, 1fr);
  height: 100%;
  min-height: 100vh;
  background: var(--bg-subtle);
}
.uno-shell[data-collapsed] {
  --uno-sidebar: 60px;
}
.uno-shell__side {
  display: flex;
  flex-direction: column;
  gap: var(--space-1);
  padding: var(--space-3);
  background: var(--bg-page);
  border-right: 1px solid var(--border-subtle);
  overflow: hidden;
  transition: width var(--duration-normal) var(--ease-out);
}
.uno-shell__brand {
  display: flex;
  align-items: center;
  gap: var(--space-2);
  height: 40px;
  padding: 0 var(--space-2);
  margin-bottom: var(--space-3);
}
.uno-shell__group {
  margin-top: var(--space-4);
  padding: 0 var(--space-2) var(--space-1);
  font-size: var(--text-2xs);
  font-weight: var(--weight-semibold);
  color: var(--text-tertiary);
  letter-spacing: var(--tracking-wide);
}
.uno-shell__item {
  display: flex;
  align-items: center;
  gap: var(--space-3);
  height: 34px;
  padding: 0 var(--space-2);
  border-radius: var(--radius-sm);
  font-size: var(--text-sm);
  font-weight: var(--weight-semibold);
  color: var(--text-secondary);
  text-decoration: none;
  white-space: nowrap;
  cursor: pointer;
  border: 0;
  background: transparent;
  width: 100%;
  text-align: left;
  transition:
    background-color var(--duration-fast) var(--ease-out),
    color var(--duration-fast) var(--ease-out);
}
.uno-shell__item:hover {
  background: var(--bg-subtle);
  color: var(--text-primary);
  text-decoration: none;
}
.uno-shell__item[aria-current="page"] {
  background: var(--bg-brand-subtle);
  color: var(--brand-text);
}
.uno-shell__count {
  margin-left: auto;
  font-family: var(--font-mono);
  font-size: var(--text-2xs);
  color: var(--text-tertiary);
}
.uno-shell__foot {
  margin-top: auto;
  display: flex;
  flex-direction: column;
  gap: var(--space-1);
}
.uno-shell__main {
  display: flex;
  flex-direction: column;
  min-width: 0;
  overflow: auto;
}
.uno-shell__topbar {
  position: sticky;
  top: 0;
  z-index: var(--z-sticky);
  display: flex;
  align-items: center;
  gap: var(--space-3);
  height: 56px;
  padding: 0 var(--space-6);
  background: var(--bg-page);
  border-bottom: 1px solid var(--border-subtle);
}
.uno-shell__title {
  font-family: var(--font-display);
  font-size: var(--text-base);
  font-weight: var(--weight-medium);
  letter-spacing: var(--tracking-tight);
  margin: 0;
}
.uno-shell__content {
  flex: 1;
  padding: var(--space-6);
  background: var(--bg-subtle);
}

/* ===== Breadcrumb ======================================================== */
.uno-crumbs {
  display: flex;
  align-items: center;
  gap: var(--space-2);
  font-size: var(--text-xs);
  color: var(--text-tertiary);
  min-width: 0;
}
.uno-crumbs a {
  color: var(--text-secondary);
  text-decoration: none;
}
.uno-crumbs a:hover {
  color: var(--text-primary);
  text-decoration: underline;
  text-underline-offset: 2px;
}
.uno-crumbs__current {
  color: var(--text-primary);
  font-weight: var(--weight-medium);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

/* ===== Tabs ============================================================== */
.uno-tabs {
  display: flex;
  gap: var(--space-1);
  border-bottom: 1px solid var(--border-subtle);
}
.uno-tab {
  position: relative;
  display: inline-flex;
  align-items: center;
  gap: var(--space-2);
  height: 38px;
  padding: 0 var(--space-3);
  border: 0;
  background: transparent;
  font-family: var(--font-sans);
  font-size: var(--text-sm);
  font-weight: var(--weight-medium);
  color: var(--text-secondary);
  cursor: pointer;
  transition: color var(--duration-fast) var(--ease-out);
}
.uno-tab:hover {
  color: var(--text-primary);
}
.uno-tab[aria-selected="true"] {
  color: var(--text-primary);
}
.uno-tab[aria-selected="true"]::after {
  content: "";
  position: absolute;
  left: var(--space-2);
  right: var(--space-2);
  bottom: -1px;
  height: 2px;
  border-radius: 2px;
  background: var(--brand-accent);
}
.uno-tab:disabled {
  color: var(--text-disabled);
  cursor: not-allowed;
}
.uno-tabs--pill {
  border-bottom: 0;
  padding: 3px;
  background: var(--bg-inset);
  border-radius: var(--radius-md);
  display: inline-flex;
}
.uno-tabs--pill .uno-tab {
  height: 30px;
  border-radius: var(--radius-sm);
  font-size: var(--text-xs);
}
.uno-tabs--pill .uno-tab[aria-selected="true"] {
  background: var(--bg-raised);
  box-shadow: var(--shadow-xs);
}
.uno-tabs--pill .uno-tab[aria-selected="true"]::after {
  display: none;
}

/* ===== Pagination ======================================================== */
.uno-pager {
  display: flex;
  align-items: center;
  gap: var(--space-2);
  font-size: var(--text-xs);
  color: var(--text-secondary);
}
.uno-pager__page {
  min-width: 30px;
  height: 30px;
  padding: 0 var(--space-2);
  display: grid;
  place-items: center;
  border: 1px solid transparent;
  border-radius: var(--radius-sm);
  background: transparent;
  font-family: var(--font-mono);
  font-size: var(--text-xs);
  color: var(--text-secondary);
  cursor: pointer;
}
.uno-pager__page:hover {
  background: var(--bg-subtle);
  color: var(--text-primary);
}
.uno-pager__page[aria-current="page"] {
  background: var(--bg-brand-subtle);
  border-color: var(--border-brand);
  color: var(--brand-text);
  font-weight: var(--weight-semibold);
}
.uno-pager__gap {
  color: var(--text-disabled);
  padding: 0 2px;
}
.uno-pager__meta {
  margin-right: auto;
  font-family: var(--font-mono);
  color: var(--text-tertiary);
}

/* ===== Command palette =================================================== */
.uno-cmd__scrim {
  position: fixed;
  inset: 0;
  z-index: var(--z-modal);
  background: var(--bg-scrim);
  backdrop-filter: blur(2px);
  display: flex;
  justify-content: center;
  padding-top: 12vh;
}
.uno-cmd {
  width: min(560px, 92vw);
  max-height: 60vh;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  background: var(--bg-overlay);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-xl);
  box-shadow: var(--shadow-xl);
  animation: uno-cmd-in var(--duration-normal) var(--ease-out);
}
@keyframes uno-cmd-in {
  from {
    opacity: 0;
    transform: translateY(-8px) scale(0.985);
  }
  to {
    opacity: 1;
    transform: none;
  }
}
.uno-cmd__field {
  display: flex;
  align-items: center;
  gap: var(--space-3);
  padding: var(--space-4) var(--space-5);
  border-bottom: 1px solid var(--border-subtle);
  color: var(--text-tertiary);
}
.uno-cmd__field input {
  flex: 1;
  border: 0;
  outline: 0;
  background: transparent;
  font: inherit;
  font-size: var(--text-base);
  color: var(--text-primary);
}
.uno-cmd__list {
  overflow: auto;
  padding: var(--space-2);
}
.uno-cmd__group {
  padding: var(--space-2) var(--space-3) var(--space-1);
  font-size: var(--text-2xs);
  font-weight: var(--weight-semibold);
  color: var(--text-tertiary);
  letter-spacing: var(--tracking-wide);
}
.uno-cmd__item {
  display: flex;
  align-items: center;
  gap: var(--space-3);
  padding: var(--space-2) var(--space-3);
  border-radius: var(--radius-sm);
  font-size: var(--text-sm);
  color: var(--text-primary);
  cursor: pointer;
}
.uno-cmd__item[data-active] {
  background: var(--bg-brand-subtle);
  color: var(--brand-text);
}
.uno-cmd__item .uno-kbd {
  margin-left: auto;
}
.uno-cmd__empty {
  padding: var(--space-6);
  text-align: center;
  font-size: var(--text-sm);
  color: var(--text-tertiary);
}

/* ===== Steps ============================================================= */
.uno-steps {
  display: flex;
  align-items: flex-start;
  gap: var(--space-2);
}
.uno-step {
  display: flex;
  align-items: center;
  gap: var(--space-3);
  flex: 1;
  min-width: 0;
}
.uno-step__dot {
  flex: 0 0 auto;
  display: grid;
  place-items: center;
  width: 26px;
  height: 26px;
  border-radius: var(--radius-full);
  border: var(--border-width-thick) solid var(--border-strong);
  background: var(--bg-page);
  color: var(--text-tertiary);
  font-family: var(--font-mono);
  font-size: var(--text-2xs);
}
.uno-step[data-state="current"] .uno-step__dot {
  border-color: var(--brand-accent);
  color: var(--brand-text);
  background: var(--bg-brand-subtle);
}
.uno-step[data-state="done"] .uno-step__dot {
  background: var(--brand-solid);
  border-color: var(--brand-solid);
  color: var(--brand-on-solid);
}
.uno-step__label {
  font-size: var(--text-sm);
  font-weight: var(--weight-medium);
  color: var(--text-tertiary);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.uno-step[data-state="current"] .uno-step__label,
.uno-step[data-state="done"] .uno-step__label {
  color: var(--text-primary);
}
.uno-step__bar {
  flex: 1;
  height: 2px;
  min-width: 16px;
  border-radius: 2px;
  background: var(--border-subtle);
}
.uno-step[data-state="done"] .uno-step__bar {
  background: var(--brand-solid);
}

/* ===== Inline alert ====================================================== */
.uno-alert {
  display: flex;
  gap: var(--space-3);
  padding: var(--space-3) var(--space-4);
  border: 1px solid;
  border-radius: var(--radius-md);
  font-size: var(--text-sm);
  line-height: var(--leading-snug);
}
.uno-alert__icon {
  flex: 0 0 auto;
  margin-top: 1px;
}
.uno-alert__body {
  display: flex;
  flex-direction: column;
  gap: var(--space-1);
  min-width: 0;
  flex: 1;
}
.uno-alert__title {
  font-weight: var(--weight-semibold);
}
.uno-alert__desc {
  color: inherit;
  opacity: 0.88;
}
.uno-alert__actions {
  display: flex;
  gap: var(--space-2);
  margin-top: var(--space-2);
}
.uno-alert--info {
  background: var(--info-bg);
  border-color: var(--info-border);
  color: var(--info-fg);
}
.uno-alert--success {
  background: var(--success-bg);
  border-color: var(--success-border);
  color: var(--success-fg);
}
.uno-alert--warning {
  background: var(--warning-bg);
  border-color: var(--warning-border);
  color: var(--warning-fg);
}
.uno-alert--danger {
  background: var(--danger-bg);
  border-color: var(--danger-border);
  color: var(--danger-fg);
}
.uno-alert--neutral {
  background: var(--bg-subtle);
  border-color: var(--border-subtle);
  color: var(--text-secondary);
}

/* ===== Banner (full-bleed, page level) ================================== */
.uno-banner {
  display: flex;
  align-items: center;
  gap: var(--space-3);
  padding: var(--space-3) var(--space-6);
  font-size: var(--text-sm);
  border-bottom: 1px solid var(--border-subtle);
  background: var(--bg-subtle);
  color: var(--text-primary);
}
.uno-banner--brand {
  background: var(--bg-brand-subtle);
  border-color: var(--border-brand);
  color: var(--brand-text);
}
.uno-banner--warning {
  background: var(--warning-bg);
  border-color: var(--warning-border);
  color: var(--warning-fg);
}
.uno-banner--danger {
  background: var(--danger-bg);
  border-color: var(--danger-border);
  color: var(--danger-fg);
}
.uno-banner__end {
  margin-left: auto;
  display: flex;
  align-items: center;
  gap: var(--space-2);
}

/* ===== Toast ============================================================= */
.uno-toaster {
  position: fixed;
  bottom: var(--space-6);
  right: var(--space-6);
  z-index: var(--z-toast);
  display: flex;
  flex-direction: column;
  gap: var(--space-2);
  width: min(380px, calc(100vw - var(--space-8)));
}
@keyframes uno-toast-in {
  from {
    opacity: 0;
    transform: translateY(8px) scale(0.98);
  }
  to {
    opacity: 1;
    transform: none;
  }
}
.uno-toast {
  display: flex;
  gap: var(--space-3);
  padding: var(--space-3) var(--space-4);
  background: var(--bg-overlay);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-lg);
  font-size: var(--text-sm);
  animation: uno-toast-in var(--duration-normal) var(--ease-out);
}
.uno-toast__icon {
  flex: 0 0 auto;
  margin-top: 1px;
}
.uno-toast--success .uno-toast__icon {
  color: var(--success-fg);
}
.uno-toast--danger .uno-toast__icon {
  color: var(--danger-fg);
}
.uno-toast--warning .uno-toast__icon {
  color: var(--warning-fg);
}
.uno-toast--info .uno-toast__icon {
  color: var(--info-fg);
}
.uno-toast__body {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 2px;
}
.uno-toast__title {
  font-weight: var(--weight-medium);
  color: var(--text-primary);
}
.uno-toast__desc {
  color: var(--text-secondary);
  font-size: var(--text-xs);
  line-height: var(--leading-snug);
}

/* ===== Modal / drawer shared scrim ====================================== */
.uno-scrim {
  position: fixed;
  inset: 0;
  z-index: var(--z-modal);
  background: var(--bg-scrim);
  backdrop-filter: blur(2px);
  display: grid;
  place-items: center;
  padding: var(--space-6);
}
@keyframes uno-modal-in {
  from {
    opacity: 0;
    transform: translateY(10px) scale(0.98);
  }
  to {
    opacity: 1;
    transform: none;
  }
}
.uno-modal {
  width: min(520px, 100%);
  max-height: 86vh;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  background: var(--bg-overlay);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-xl);
  box-shadow: var(--shadow-xl);
  animation: uno-modal-in var(--duration-normal) var(--ease-out);
}
.uno-modal--lg {
  width: min(720px, 100%);
}
.uno-modal__head {
  display: flex;
  align-items: flex-start;
  gap: var(--space-4);
  padding: var(--space-5) var(--space-6) var(--space-3);
}
.uno-modal__title {
  font-family: var(--font-display);
  font-size: var(--text-xl);
  font-weight: var(--weight-medium);
  letter-spacing: var(--tracking-tight);
  margin: 0;
}
.uno-modal__desc {
  font-size: var(--text-sm);
  color: var(--text-secondary);
  margin: var(--space-2) 0 0;
}
.uno-modal__body {
  padding: 0 var(--space-6) var(--space-5);
  overflow: auto;
  font-size: var(--text-sm);
}
.uno-modal__foot {
  display: flex;
  justify-content: flex-end;
  gap: var(--space-2);
  padding: var(--space-4) var(--space-6);
  border-top: 1px solid var(--border-subtle);
  background: var(--bg-subtle);
}
.uno-modal__x {
  margin-left: auto;
}

/* ===== Drawer ============================================================ */
@keyframes uno-drawer-in {
  from {
    transform: translateX(100%);
  }
  to {
    transform: none;
  }
}
.uno-drawer__scrim {
  position: fixed;
  inset: 0;
  z-index: var(--z-modal);
  background: var(--bg-scrim);
  display: flex;
  justify-content: flex-end;
}
.uno-drawer {
  width: min(440px, 92vw);
  height: 100%;
  display: flex;
  flex-direction: column;
  background: var(--bg-overlay);
  border-left: 1px solid var(--border-subtle);
  box-shadow: var(--shadow-xl);
  animation: uno-drawer-in var(--duration-normal) var(--ease-out);
}
.uno-drawer--left {
  animation-name: uno-drawer-in-l;
  border-left: 0;
  border-right: 1px solid var(--border-subtle);
}
@keyframes uno-drawer-in-l {
  from {
    transform: translateX(-100%);
  }
  to {
    transform: none;
  }
}
.uno-drawer__head {
  display: flex;
  align-items: center;
  gap: var(--space-3);
  padding: var(--space-4) var(--space-5);
  border-bottom: 1px solid var(--border-subtle);
}
.uno-drawer__title {
  font-family: var(--font-display);
  font-size: var(--text-lg);
  font-weight: var(--weight-medium);
  letter-spacing: var(--tracking-tight);
  margin: 0;
}
.uno-drawer__body {
  flex: 1;
  overflow: auto;
  padding: var(--space-5);
  font-size: var(--text-sm);
}
.uno-drawer__foot {
  display: flex;
  justify-content: flex-end;
  gap: var(--space-2);
  padding: var(--space-4) var(--space-5);
  border-top: 1px solid var(--border-subtle);
  background: var(--bg-subtle);
}

/* ===== Popover =========================================================== */
.uno-pop {
  position: relative;
  display: inline-flex;
}
@keyframes uno-pop-in {
  from {
    opacity: 0;
    transform: translateY(-4px);
  }
  to {
    opacity: 1;
    transform: none;
  }
}
.uno-pop__panel {
  position: absolute;
  top: calc(100% + 6px);
  z-index: var(--z-popover);
  min-width: 220px;
  padding: var(--space-3);
  background: var(--bg-overlay);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-lg);
  font-size: var(--text-sm);
  animation: uno-pop-in var(--duration-fast) var(--ease-out);
}
.uno-pop__panel[data-align="start"] {
  left: 0;
}
.uno-pop__panel[data-align="end"] {
  right: 0;
}
.uno-pop__item {
  display: flex;
  align-items: center;
  gap: var(--space-3);
  width: 100%;
  padding: var(--space-2);
  border: 0;
  background: transparent;
  font: inherit;
  color: var(--text-primary);
  text-align: left;
  border-radius: var(--radius-xs);
  cursor: pointer;
}
.uno-pop__item:hover {
  background: var(--bg-subtle);
}
.uno-pop__item[data-danger] {
  color: var(--danger-fg);
}

/* ===== Tooltip =========================================================== */
.uno-tip {
  position: relative;
  display: inline-flex;
}
.uno-tip__bubble {
  position: absolute;
  bottom: calc(100% + 6px);
  left: 50%;
  transform: translateX(-50%);
  z-index: var(--z-popover);
  max-width: 240px;
  padding: var(--space-2) var(--space-3);
  background: var(--uno-ink-900);
  color: var(--uno-ink-50);
  font-size: var(--text-xs);
  line-height: var(--leading-snug);
  border-radius: var(--radius-sm);
  box-shadow: var(--shadow-md);
  white-space: normal;
  pointer-events: none;
  opacity: 0;
  transition: opacity var(--duration-fast) var(--ease-out);
}
[data-theme="dark"] .uno-tip__bubble {
  background: var(--uno-ink-700);
  color: var(--uno-ink-50);
  border: 1px solid var(--border-strong);
}
.uno-tip[data-open] .uno-tip__bubble {
  opacity: 1;
}

/* ===== Empty / error state ============================================== */
.uno-state {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  gap: var(--space-3);
  padding: var(--space-16) var(--space-6);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg);
  background: var(--bg-raised);
  overflow: hidden;
}
.uno-state__field {
  position: absolute;
  inset: 0;
  pointer-events: none;
  opacity: 0.55;
}
.uno-state__icon {
  position: relative;
  display: grid;
  place-items: center;
  width: 44px;
  height: 44px;
  border-radius: var(--radius-md);
  background: var(--bg-brand-subtle);
  color: var(--brand-text);
}
.uno-state--error .uno-state__icon {
  background: var(--danger-bg);
  color: var(--danger-fg);
}
.uno-state__title {
  position: relative;
  font-family: var(--font-display);
  font-size: var(--text-lg);
  font-weight: var(--weight-medium);
  letter-spacing: var(--tracking-tight);
  margin: 0;
}
.uno-state__desc {
  position: relative;
  font-size: var(--text-sm);
  color: var(--text-secondary);
  margin: 0;
  max-width: 44ch;
}
.uno-state__actions {
  position: relative;
  display: flex;
  gap: var(--space-2);
  margin-top: var(--space-2);
}
.uno-state__code {
  position: relative;
  font-family: var(--font-mono);
  font-size: var(--text-2xs);
  color: var(--text-tertiary);
}

/* ===== Card ============================================================== */
.uno-card {
  display: flex;
  flex-direction: column;
  background: var(--bg-raised);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg);
  overflow: hidden;
}
.uno-card--flat {
  border-radius: var(--radius-lg);
  box-shadow: none;
}
.uno-card--raised {
  box-shadow: var(--shadow-md);
  border-color: transparent;
}
.uno-card--feature {
  border-radius: var(--radius-xl);
}
.uno-card--inset {
  background: var(--bg-subtle);
  border-style: dashed;
}
.uno-card--interactive {
  cursor: pointer;
  transition:
    border-color var(--duration-fast) var(--ease-out),
    box-shadow var(--duration-fast) var(--ease-out),
    transform var(--duration-fast) var(--ease-out);
}
.uno-card--interactive:hover {
  border-color: var(--border-strong);
  box-shadow: var(--shadow-md);
}
.uno-card--interactive:active {
  transform: translateY(1px);
}
.uno-card__head {
  display: flex;
  align-items: flex-start;
  gap: var(--space-3);
  padding: var(--space-4) var(--space-5);
  border-bottom: 1px solid var(--border-subtle);
}
.uno-card__title {
  font-family: var(--font-display);
  font-size: var(--text-base);
  font-weight: var(--weight-medium);
  letter-spacing: var(--tracking-tight);
  margin: 0;
}
.uno-card__sub {
  font-size: var(--text-xs);
  color: var(--text-secondary);
  margin: 2px 0 0;
}
.uno-card__end {
  margin-left: auto;
  display: flex;
  align-items: center;
  gap: var(--space-2);
}
.uno-card__body {
  padding: var(--space-5);
  font-size: var(--text-sm);
  color: var(--text-secondary);
  flex: 1;
}
.uno-card__body--tight {
  padding: 0;
}
.uno-card__foot {
  padding: var(--space-3) var(--space-5);
  border-top: 1px solid var(--border-subtle);
  background: var(--bg-subtle);
  font-size: var(--text-xs);
  color: var(--text-tertiary);
  display: flex;
  align-items: center;
  gap: var(--space-3);
}

/* ===== Stat / metric tile ============================================== */
.uno-stat {
  display: flex;
  flex-direction: column;
  gap: var(--space-1);
  padding: var(--space-4) var(--space-5);
  background: var(--bg-raised);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg);
}
.uno-stat__label {
  display: flex;
  align-items: center;
  gap: var(--space-2);
  font-size: var(--text-xs);
  color: var(--text-secondary);
}
.uno-stat__value {
  font-family: var(--font-mono);
  font-variant-numeric: tabular-nums;
  font-size: var(--text-2xl);
  font-weight: var(--weight-medium);
  letter-spacing: var(--tracking-tight);
  color: var(--text-primary);
  line-height: var(--leading-tight);
}
.uno-stat__unit {
  font-size: var(--text-base);
  color: var(--text-tertiary);
  margin-left: 2px;
}
.uno-stat__delta {
  display: flex;
  align-items: center;
  gap: 3px;
  font-size: var(--text-xs);
  font-family: var(--font-mono);
  font-variant-numeric: tabular-nums;
}
.uno-stat__delta[data-dir="up"] {
  color: var(--success-fg);
}
.uno-stat__delta[data-dir="down"] {
  color: var(--danger-fg);
}
.uno-stat__delta[data-dir="flat"] {
  color: var(--text-tertiary);
}
.uno-stat__spark {
  margin-top: var(--space-2);
}

/* ===== Table ============================================================ */
.uno-table-wrap {
  overflow: auto;
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg);
  background: var(--bg-raised);
}
.uno-table {
  width: 100%;
  border-collapse: separate;
  border-spacing: 0;
  font-size: var(--text-sm);
}
.uno-table th {
  position: sticky;
  top: 0;
  z-index: 1;
  text-align: left;
  padding: var(--space-2) var(--space-4);
  height: 38px;
  background: var(--bg-subtle);
  border-bottom: 1px solid var(--border-subtle);
  font-size: var(--text-xs);
  font-weight: var(--weight-semibold);
  color: var(--text-secondary);
  white-space: nowrap;
}
.uno-table th[data-sortable] {
  cursor: pointer;
  user-select: none;
}
.uno-table th[data-sortable]:hover {
  color: var(--text-primary);
}
.uno-table th[data-numeric],
.uno-table td[data-numeric] {
  text-align: right;
}
.uno-table td {
  padding: var(--space-3) var(--space-4);
  border-bottom: 1px solid var(--border-subtle);
  color: var(--text-primary);
  vertical-align: middle;
}
.uno-table tbody tr:last-child td {
  border-bottom: 0;
}
.uno-table tbody tr:hover td {
  background: var(--bg-subtle);
}
.uno-table tbody tr[data-selected] td {
  background: var(--bg-brand-subtle);
}
.uno-table__sort {
  display: inline-flex;
  align-items: center;
  gap: 4px;
}
.uno-table__resize {
  position: absolute;
  top: 0;
  right: 0;
  bottom: 0;
  width: 5px;
  cursor: col-resize;
}
.uno-table--dense td {
  padding: var(--space-2) var(--space-3);
  font-size: var(--text-xs);
}
.uno-table--dense th {
  height: 32px;
  padding: var(--space-1) var(--space-3);
}

/* ===== Data grid (density where density is the point) ================== */
.uno-grid-table {
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  overflow: auto;
  background: var(--bg-raised);
  font-size: var(--text-xs);
}
.uno-grid-table table {
  width: 100%;
  border-collapse: separate;
  border-spacing: 0;
}
.uno-grid-table th {
  position: sticky;
  top: 0;
  z-index: 1;
  height: 30px;
  padding: 0 var(--space-2);
  background: var(--bg-inset);
  border-bottom: 1px solid var(--border-default);
  border-right: 1px solid var(--border-subtle);
  text-align: left;
  font-size: var(--text-2xs);
  font-weight: var(--weight-semibold);
  color: var(--text-secondary);
  white-space: nowrap;
}
.uno-grid-table td {
  height: 28px;
  padding: 0 var(--space-2);
  border-bottom: 1px solid var(--border-subtle);
  border-right: 1px solid var(--border-subtle);
  font-family: var(--font-mono);
  font-variant-numeric: tabular-nums;
  color: var(--text-primary);
  white-space: nowrap;
}
.uno-grid-table td[data-text] {
  font-family: var(--font-sans);
}
.uno-grid-table tr:hover td {
  background: var(--bg-subtle);
}
.uno-grid-table td[data-pinned],
.uno-grid-table th[data-pinned] {
  position: sticky;
  left: 0;
  z-index: 2;
  background: var(--bg-raised);
  border-right: 1px solid var(--border-default);
}
.uno-grid-table th[data-pinned] {
  background: var(--bg-inset);
  z-index: 3;
}

/* ===== Filter bar ======================================================= */
.uno-filterbar {
  display: flex;
  align-items: center;
  gap: var(--space-2);
  flex-wrap: wrap;
  padding: var(--space-2);
  background: var(--bg-raised);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
}
.uno-filterbar__spacer {
  flex: 1;
}
.uno-filterbar__count {
  font-family: var(--font-mono);
  font-size: var(--text-xs);
  color: var(--text-tertiary);
  padding: 0 var(--space-2);
}

/* ===== Segmented control =============================================== */
.uno-seg {
  display: inline-flex;
  padding: 3px;
  gap: 2px;
  background: var(--bg-inset);
  border-radius: var(--radius-md);
}
.uno-seg__btn {
  display: inline-flex;
  align-items: center;
  gap: var(--space-2);
  height: 28px;
  padding: 0 var(--space-3);
  border: 0;
  background: transparent;
  border-radius: var(--radius-sm);
  font-family: var(--font-sans);
  font-size: var(--text-xs);
  font-weight: var(--weight-medium);
  color: var(--text-secondary);
  cursor: pointer;
  transition:
    background-color var(--duration-fast) var(--ease-out),
    color var(--duration-fast) var(--ease-out);
}
.uno-seg__btn:hover {
  color: var(--text-primary);
}
.uno-seg__btn[aria-pressed="true"] {
  background: var(--bg-raised);
  color: var(--text-primary);
  box-shadow: var(--shadow-xs);
}

/* ===== Progress ========================================================= */
.uno-progress {
  display: flex;
  flex-direction: column;
  gap: var(--space-2);
}
.uno-progress__row {
  display: flex;
  justify-content: space-between;
  font-size: var(--text-xs);
  color: var(--text-secondary);
}
.uno-progress__val {
  font-family: var(--font-mono);
  font-variant-numeric: tabular-nums;
  color: var(--text-primary);
}
.uno-progress__track {
  height: 6px;
  border-radius: var(--radius-full);
  background: var(--bg-inset);
  overflow: hidden;
}
.uno-progress__fill {
  height: 100%;
  border-radius: var(--radius-full);
  background: var(--brand-solid);
  transition: width var(--duration-slow) var(--ease-out);
}
.uno-progress__fill[data-tone="success"] {
  background: var(--uno-success-500);
}
.uno-progress__fill[data-tone="warning"] {
  background: var(--uno-warning-500);
}
.uno-progress__fill[data-tone="danger"] {
  background: var(--uno-danger-500);
}
@keyframes uno-indet {
  0% {
    transform: translateX(-100%);
  }
  100% {
    transform: translateX(300%);
  }
}
.uno-progress__fill--indeterminate {
  width: 33% !important;
  animation: uno-indet 1.4s var(--ease-out) infinite;
}

/* ===== Chart wrappers =================================================== */
.uno-chart {
  display: flex;
  flex-direction: column;
  gap: var(--space-3);
}
.uno-chart__plot {
  position: relative;
  width: 100%;
}
.uno-chart__legend {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-4);
  font-size: var(--text-xs);
  color: var(--text-secondary);
}
.uno-chart__key {
  display: inline-flex;
  align-items: center;
  gap: var(--space-2);
}
.uno-chart__swatch {
  width: 14px;
  height: 0;
  border-top-width: 2px;
  border-top-style: solid;
  flex: 0 0 auto;
}
.uno-chart__swatch--block {
  width: 10px;
  height: 10px;
  border-radius: 2px;
  border: 0;
}
.uno-chart__axis {
  font-family: var(--font-mono);
  font-size: var(--text-2xs);
  fill: var(--text-tertiary);
}
.uno-chart__gridline {
  stroke: var(--border-subtle);
  stroke-width: 1;
}
.uno-chart__donut-label {
  font-family: var(--font-mono);
  font-variant-numeric: tabular-nums;
  fill: var(--text-primary);
}
