/*
 * The button tokens for the website's brand -- savantrealms.com, account, backoffice, status.
 *
 * GENERATED by 00_tools/build_brand.py from brand/brand.yaml (`button:`). Do not edit by hand:
 * the next build overwrites it, and `build_brand.py --check` fails CI before that.
 *
 * The button package's one stylesheet reads only --sr-button-*. The console gets the same names
 * from brand/tokens.css, mapped onto its own semantic tokens; this file maps them onto the
 * website's, which are designs/_site/site-tokens.css's -- a hand-kept copy of the website's
 * palette that brand.yaml does not hold. Only the names are taken here, never a value, so this
 * file stays right when that palette changes.
 *
 * The selector is `:root, [data-theme]`, not `:root` alone. A custom property whose value is a
 * var() is resolved where it is declared and then inherited as a value, so a map declared on
 * :root only would carry :root's theme into a subtree that sets its own data-theme. Declaring it
 * again on every themed element makes a light panel inside a dark page resolve light.
 *
 * These names are public API: renaming one is a breaking change to the package and to every
 * service that links this file.
 */

:root,
[data-theme] {
  /* --- geometry: the same in both brands ----------------------------------------------- */
  --sr-button-height-sm: 28px;
  --sr-button-height-md: 36px;
  --sr-button-height-lg: 44px;
  --sr-button-pad-sm: 10px;
  --sr-button-pad-md: 14px;
  --sr-button-pad-lg: 20px;
  --sr-button-text-sm: 13px;
  --sr-button-text-md: 14px;
  --sr-button-text-lg: 15px;
  --sr-button-icon-sm: 14px;
  --sr-button-icon-md: 16px;
  --sr-button-icon-lg: 18px;
  --sr-button-gap-sm: 6px;
  --sr-button-gap-md: 8px;
  --sr-button-gap-lg: 8px;
  --sr-button-weight: 700;
  --sr-button-border-width: 1px;
  --sr-button-radius-pill: 999px;
  --sr-button-focus-width: 2px;
  --sr-button-focus-offset: 2px;
  --sr-button-target-min: 24px;
  --sr-button-target-coarse: 44px;

  /* --- roles: this brand's mapping ----------------------------------------------------- */
  --sr-button-font: var(--sr-site-font-body);
  --sr-button-radius: var(--sr-site-radius-sm);
  --sr-button-focus: var(--sr-site-cyan);
  --sr-button-primary-bg: var(--sr-site-cyan);
  --sr-button-primary-fg: var(--sr-site-surface);
  --sr-button-primary-bg-hover: color-mix(in srgb, var(--sr-button-primary-bg) 85%, var(--sr-site-text));
  --sr-button-primary-bg-active: color-mix(in srgb, var(--sr-button-primary-bg) 72%, var(--sr-site-text));
  --sr-button-secondary-bg: var(--sr-site-surface);
  --sr-button-secondary-fg: var(--sr-site-text);
  --sr-button-secondary-border: var(--sr-site-border-strong);
  --sr-button-secondary-border-hover: var(--sr-site-cyan);
  --sr-button-secondary-bg-hover: var(--sr-site-surface2);
  --sr-button-secondary-bg-active: var(--sr-site-surface3);
  --sr-button-tertiary-fg: var(--sr-site-text-ui);
  --sr-button-tertiary-bg-hover: var(--sr-site-surface2);
  --sr-button-tertiary-bg-active: var(--sr-site-surface3);
  --sr-button-danger-bg: var(--sr-site-danger);
  --sr-button-danger-fg: var(--sr-site-surface);
  --sr-button-danger-bg-hover: color-mix(in srgb, var(--sr-button-danger-bg) 85%, var(--sr-site-text));
  --sr-button-danger-bg-active: color-mix(in srgb, var(--sr-button-danger-bg) 72%, var(--sr-site-text));
  --sr-button-link-fg: color-mix(in srgb, var(--sr-site-cyan) 80%, var(--sr-site-text));
  --sr-button-link-fg-hover: var(--sr-site-text);
  --sr-button-tone-danger-fg: var(--sr-site-danger);
  --sr-button-tone-danger-border: color-mix(in srgb, var(--sr-site-danger) 60%, var(--sr-site-border));
  --sr-button-pressed-bg: var(--sr-site-surface3);
  --sr-button-pressed-fg: var(--sr-site-text);
  --sr-button-pressed-border: var(--sr-site-cyan);
  --sr-button-disabled-bg: var(--sr-site-surface2);
  --sr-button-disabled-fg: var(--sr-site-text-sub);
  --sr-button-disabled-border: var(--sr-site-border);
}
