/* RxDesk Next, Apple theme: Design.swift and Style.swift as custom properties. Light and dark are set by RxDeskRoot's
   data-scheme. sRGB components converted exactly (0.62, 0.32, 0 -> #9E5200); system colours are macOS 26's. */
.rx-root {
  --rx-font: -apple-system, BlinkMacSystemFont, "RxInter", "Segoe UI Variable", "Segoe UI", system-ui, sans-serif;
  --rx-font-mono: ui-monospace, "SF Mono", Menlo, Consolas, monospace;

  /* Design.swift metrics */
  --rx-corner: 26px;
  --rx-header: 76px;
  --rx-inset: 18px;
  --rx-gutter: 22px;
  --rx-page-top: 14px;
  --rx-inner-corner: 10px;
  --rx-max-width: 1440px;
  --rx-field-label-width: 92px;
  --rx-min-row-height: 250px;

  /* Motion (Design.swift Motion) */
  --rx-quick: 0.15s; /* @kind other */
  --rx-open: 0.26s; /* @kind other */

  /* Light (Aqua) */
  color-scheme: light;
  --rx-primary-rgb: 0, 0, 0; /* @kind color */
  --rx-label: rgba(0, 0, 0, 0.85);
  --rx-secondary: rgba(0, 0, 0, 0.5);
  --rx-tertiary: rgba(0, 0, 0, 0.26);
  --rx-quaternary: rgba(0, 0, 0, 0.1);
  --rx-separator: rgba(0, 0, 0, 0.1);
  --rx-background: #ffffff;             /* the window / `.background` */
  --rx-background-secondary: #f8f8f8;   /* `.background.secondary`: the comparison box */
  --rx-card-body: #ffffff;              /* Color.cardBody */
  --rx-band: rgba(241, 241, 241, 0.9);  /* .regularMaterial over the wallpaper */
  --rx-bar: rgba(255, 255, 255, 0.86);  /* .bar */
  --rx-card-stroke: rgba(255, 255, 255, 0.55);
  --rx-shadow-resting: 0 5px 28px rgba(0, 0, 0, 0.08);
  --rx-shadow-lifted: 0 10px 44px rgba(0, 0, 0, 0.14);
  --rx-shadow-floating: 0 12px 60px rgba(0, 0, 0, 0.24);
  --rx-shadow-panel: 0 12px 60px rgba(0, 0, 0, 0.18); /* ChatPanel.swift: same in dark */
  --rx-glass: rgba(255, 255, 255, 0.84);
  --rx-glass-stroke: rgba(255, 255, 255, 0.85);
  --rx-glass-shadow: 0 1px 2px rgba(0, 0, 0, 0.06), 0 4px 14px rgba(0, 0, 0, 0.08);
  --rx-alt-row: #f4f5f5;
  --rx-selection: #0064e1;
  --rx-selection-unemphasized: #dcdcdc;
  --rx-control-background: #f5f5f5;     /* controlBackgroundColor mixed with 8% grey (the Chats composer) */

  /* Style.swift */
  --rx-hold-amber: #9e5200;
  --rx-review-blue: #0063cc;
  --rx-alert-red: #b52417;
  --rx-paid-green: #1a7333;
  --rx-received-bubble: #e9e9eb;
  --rx-sent-bubble: var(--rx-blue);
  --rx-accent: var(--rx-blue);

  /* System colours (macOS 26) */
  --rx-blue: #0088ff;
  --rx-green: #34c759;
  --rx-indigo: #6155f5;
  --rx-orange: #ff8d28;
  --rx-teal: #00c3d0;
  --rx-purple: #cb30e0;
  --rx-gray: #8e8e93;
  --rx-cyan: #00c0e8;
  --rx-red: #ff383c;
  --rx-pink: #ff2d55;
  --rx-yellow: #ffcc00;
  --rx-mint: #00c8b3;
  --rx-brown: #ac7f5e;

  font-family: var(--rx-font);
  font-size: 13px;
  line-height: 16px;
  color: var(--rx-label);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
}

.rx-root[data-scheme="dark"] {
  color-scheme: dark;
  --rx-primary-rgb: 255, 255, 255; /* @kind color */
  --rx-label: rgba(255, 255, 255, 0.85);
  --rx-secondary: rgba(255, 255, 255, 0.55);
  --rx-tertiary: rgba(255, 255, 255, 0.25);
  --rx-quaternary: rgba(255, 255, 255, 0.1);
  --rx-separator: rgba(255, 255, 255, 0.1);
  --rx-background: #1e1e1e;
  --rx-background-secondary: #242424;
  --rx-card-body: #1e1e20;
  --rx-band: rgba(35, 35, 35, 0.9);
  --rx-bar: rgba(30, 30, 30, 0.86);
  --rx-card-stroke: rgba(255, 255, 255, 0.09);
  --rx-shadow-resting: 0 5px 28px rgba(0, 0, 0, 0.32);
  --rx-shadow-lifted: 0 10px 44px rgba(0, 0, 0, 0.36);
  --rx-shadow-floating: 0 12px 60px rgba(0, 0, 0, 0.5);
  --rx-glass: rgba(30, 30, 30, 0.72);
  --rx-glass-stroke: rgba(255, 255, 255, 0.14);
  --rx-glass-shadow: 0 1px 2px rgba(0, 0, 0, 0.3), 0 4px 14px rgba(0, 0, 0, 0.3);
  --rx-alt-row: rgba(255, 255, 255, 0.05);
  --rx-selection: #0058d0;
  --rx-selection-unemphasized: #464646;
  --rx-control-background: #262626;

  --rx-hold-amber: #f5bd69;
  --rx-review-blue: #8cc2ff;
  --rx-alert-red: #ff9c96;
  --rx-paid-green: #80db94;
  --rx-received-bubble: #3b3b3d;

  --rx-blue: #0091ff;
  --rx-green: #30d158;
  --rx-indigo: #6d7cff;
  --rx-orange: #ff9230;
  --rx-teal: #00d2e0;
  --rx-purple: #db34f2;
  --rx-gray: #98989d;
  --rx-cyan: #3cd3fe;
  --rx-red: #ff4245;
  --rx-pink: #ff375f;
  --rx-yellow: #ffd600;
  --rx-mint: #00dac3;
  --rx-brown: #b78a66;
}

/* SwiftUI text styles at macOS sizes */
.rx-t-largeTitle { font-size: 26px; line-height: 32px; }
.rx-t-title { font-size: 22px; line-height: 28px; }
.rx-t-title2 { font-size: 17px; line-height: 22px; }
.rx-t-title3 { font-size: 15px; line-height: 20px; }
.rx-t-headline { font-size: 13px; line-height: 16px; font-weight: 700; }
.rx-t-header { font-size: 17px; line-height: 21px; font-weight: 600; }
.rx-t-body { font-size: 13px; line-height: 16px; }
.rx-t-callout { font-size: 12px; line-height: 15px; }
.rx-t-subheadline { font-size: 11px; line-height: 14px; }
.rx-t-footnote { font-size: 10px; line-height: 13px; }
.rx-t-caption { font-size: 10px; line-height: 13px; }
.rx-t-caption2 { font-size: 10px; line-height: 13px; }
