/*! HXAI console theme · AGPL-3.0-or-later · /_hxai-ui/console.css */

/* The two palettes are the only place to change the brand colors. Keep
   foreground/background pairs together. User-selected presets continue to
   override the relevant tokens on body via the application's own stylesheet. */
:root {
  color-scheme: light;
  --background: #f6f2e9;
  --foreground: #25211c;
  --card: #fffcf6;
  --popover: #fffcf6;
  --primary-foreground: #fff9ef;
  --secondary: #eae4d7;
  --secondary-foreground: #473d32;
  --muted: #eee8dc;
  --muted-foreground: #665b4e;
  --accent: #ede4d4;
  --accent-foreground: #3d3128;
  --border: #dcd3c2;
  --input: #938171;
  --destructive: #9e302b;
  --destructive-foreground: #fff9ef;
  --success: #35634c;
  --success-foreground: #f7fff4;
  --warning: #8a591a;
  --warning-foreground: #fff9ef;
  --info: #385d69;
  --info-foreground: #f3fcff;
  --neutral: #ded7cc;
  --neutral-foreground: #494036;
  --chart-4: #645676;
  --chart-5: #456775;
  --sidebar: #eee9de;
  --sidebar-accent: #ebe0d3;
  --sidebar-accent-foreground: #752f24;
  --sidebar-border: #d9cfbf;
  --skeleton-base: #eee8dc;
  --skeleton-highlight: #f8f3e8;
  --hxai-brand-coral: #923e30;
  --hxai-brand-jade: #34685a;
  --hxai-brand-gold: #94631e;
  --hxai-depth: #2f22120b;
  --hxai-lift: #2f221224;
}

:root.dark {
  color-scheme: dark;
  --background: #1b1916;
  --foreground: #f1eadd;
  --card: #24211d;
  --popover: #29251f;
  --primary-foreground: #2d1b15;
  --secondary: #373027;
  --secondary-foreground: #ecdecc;
  --muted: #302b24;
  --muted-foreground: #c0b3a2;
  --accent: #392f25;
  --accent-foreground: #f2e4d4;
  --border: #484035;
  --input: #877b6a;
  --destructive: #ef968e;
  --destructive-foreground: #2e1513;
  --success: #9bc8ae;
  --success-foreground: #17261c;
  --warning: #e5bb77;
  --warning-foreground: #2b2011;
  --info: #9bbdc8;
  --info-foreground: #17242a;
  --neutral: #494035;
  --neutral-foreground: #eee3d6;
  --chart-4: #b7a3cd;
  --chart-5: #a0c0cc;
  --sidebar: #1f1d19;
  --sidebar-accent: #362a23;
  --sidebar-accent-foreground: #f3ab93;
  --sidebar-border: #453c31;
  --skeleton-base: #2f2922;
  --skeleton-highlight: #3b332a;
  --hxai-brand-coral: #eea28c;
  --hxai-brand-jade: #91b9aa;
  --hxai-brand-gold: #d9b678;
  --hxai-depth: #08060538;
  --hxai-lift: #0806058a;
}

:root {
  --primary: var(--hxai-brand-coral);
  --ring: var(--hxai-brand-coral);
  --chart-1: var(--hxai-brand-coral);
  --chart-2: var(--hxai-brand-jade);
  --chart-3: var(--hxai-brand-gold);
  --card-foreground: var(--foreground);
  --popover-foreground: var(--foreground);
  --sidebar-foreground: var(--foreground);
  --sidebar-primary: var(--primary);
  --sidebar-primary-foreground: var(--primary-foreground);
  --sidebar-ring: var(--ring);
  --overview-accent-1: var(--chart-1);
  --overview-accent-2: var(--chart-2);
  --overview-accent-3: var(--chart-3);
  --hxai-thread: linear-gradient(
    90deg, var(--hxai-brand-coral) 0 33.333%,
    var(--hxai-brand-jade) 33.333% 66.667%, var(--hxai-brand-gold) 66.667% 100%
  );
}

body { accent-color: var(--primary); }

.hxai-console > header {
  background: var(--card);
  box-shadow: inset 0 -1px 0 var(--border);
}

.hxai-console .hxai-section-heading {
  padding-block-end: 0.7rem;
  border-color: var(--border);
}

.hxai-console .hxai-section-heading h1,
.hxai-catalog-hero h1 {
  font-weight: 680;
  letter-spacing: -0.035em;
}

.hxai-console [data-slot='sidebar-header'] {
  border-block-end: 1px solid var(--sidebar-border);
  background: var(--hxai-thread) left bottom / 3.25rem 1px no-repeat;
}

.hxai-console [data-slot='sidebar-menu-button'][data-active='true'] {
  box-shadow: inset 2px 0 0 var(--sidebar-primary);
  font-weight: 630;
}

.hxai-console [data-slot='sidebar-group-label'] {
  color: var(--muted-foreground);
  letter-spacing: 0.035em;
}

.hxai-console :is([data-slot='card'], [data-slot='table-container']) {
  box-shadow: 0 1px 2px var(--hxai-depth);
}

.hxai-console [data-slot='card-title'] { letter-spacing: -0.018em; }

.hxai-console [data-slot='table-header'] { background: var(--muted); }

.hxai-console :is([data-slot='table-head'], [data-slot='table-cell']) {
  font-variant-numeric: tabular-nums;
}

.hxai-console [data-slot='table-row'][data-state='selected'] { background: var(--accent); }

:is(.hxai-console, .hxai-auth)
  :is([data-slot='input'], [data-slot='select-trigger'], [data-slot='textarea']) {
  background-color: var(--card);
  border-color: var(--input);
}

:is(.hxai-console, .hxai-auth) [aria-invalid='true'] { border-color: var(--destructive); }

:is(.hxai-console, .hxai-auth, .hxai-catalog-hero)
  :is(input, textarea):not(:disabled)::placeholder {
  color: var(--muted-foreground);
  opacity: 1;
}

[data-slot='tabs-trigger'][data-state='active'] {
  text-decoration: underline;
  text-decoration-color: var(--primary);
  text-decoration-thickness: 2px;
  text-underline-offset: 0.35em;
}

:is([data-slot='popover-content'], [data-slot='dropdown-menu-content'],
    [data-slot='select-content'], [data-slot='dialog-content'], [data-slot='sheet-content']) {
  box-shadow: 0 8px 24px var(--hxai-lift);
}

[data-sonner-toaster] {
  --normal-bg: var(--popover);
  --normal-border: var(--border);
  --normal-text: var(--popover-foreground);
  --success-bg: color-mix(in srgb, var(--success) 9%, var(--popover));
  --success-text: var(--success);
  --warning-bg: color-mix(in srgb, var(--warning) 9%, var(--popover));
  --warning-text: var(--warning);
  --error-bg: color-mix(in srgb, var(--destructive) 9%, var(--popover));
  --error-text: var(--destructive);
  --info-bg: color-mix(in srgb, var(--info) 9%, var(--popover));
  --info-text: var(--info);
}

.hxai-auth { background: var(--background); }

.hxai-auth-brand {
  isolation: isolate;
  background: #201c17;
  color: #f8ecdb;
  --ring: #eea28c;
}

.hxai-auth-brand::after {
  content: '';
  position: absolute;
  inset: auto 0 0;
  block-size: 2px;
  background: linear-gradient(90deg, #e9a38c 0 33.333%, #8db6a5 33.333% 66.667%, #d9b678 66.667% 100%);
  pointer-events: none;
}

.hxai-auth-stage { background: var(--background); }
.hxai-auth-form h2 { letter-spacing: -0.035em; }
.hxai-auth-label { color: #cdbfac; }
.hxai-auth-art > svg { display: none; }

.hxai-catalog-hero {
  background: var(--hxai-thread) left 1.5rem top / min(8rem, 48%) 2px no-repeat, var(--card);
  box-shadow: 0 1px 2px var(--hxai-depth);
}

.hxai-wordmark, .hxai-attribution { text-underline-offset: 0.25em; }

:is(.hxai-console, .hxai-auth, [data-slot='dialog-content'], [data-slot='sheet-content'])
  :is(a, button, input, textarea, [tabindex]):focus-visible {
  outline: 2px solid var(--ring);
  outline-offset: 2px;
}

@media (min-width: 56rem) {
  .hxai-auth-brand {
    background:
      radial-gradient(ellipse at 48% 48%, #4b3a2b 0%, transparent 70%),
      #201c17;
  }

  .hxai-auth-brand::after {
    inset: 0 0 0 auto;
    inline-size: 2px;
    block-size: auto;
    background: linear-gradient(#e9a38c 0 33.333%, #8db6a5 33.333% 66.667%, #d9b678 66.667% 100%);
  }

  .hxai-auth-art {
    grid-template-columns: minmax(0, 1fr);
    inline-size: 100%;
  }

  .hxai-auth-art::before {
    content: '';
    inline-size: min(76%, 20rem, 45vh);
    aspect-ratio: 1;
    display: block;
    background: url('/_hxai-product/hxai-mark.20261128s.svg') center / contain no-repeat;
  }
}

@media (forced-colors: active) {
  .hxai-auth-brand { background: Canvas; color: CanvasText; }
  .hxai-console [data-slot='sidebar-menu-button'][data-active='true'] {
    border-inline-start: 2px solid Highlight;
  }
  :is(.hxai-console, .hxai-auth) :focus-visible { outline-color: Highlight; }
}
