/* Santa's Helper. Copyright C Cliffe 2026. All rights reserved.

   The controls, shared by every screen. One shape means one thing wherever a
   player sees it, so these live here rather than once per page.

   DESIGN.md is binding on all of it, including the rule that saturated colour
   never appears on an inactive control. */

/* ---------------------------------------------------------------- the controls */

.btn {
  font: inherit;
  font-size: var(--t-small);
  color: var(--ink);
  background: var(--night-2);
  border: 1px solid var(--line);
  border-radius: var(--r-control);
  padding: var(--s-2) var(--s-3);
  min-height: 32px;
  cursor: pointer;
  white-space: nowrap;
  transition:
    background var(--dur-hover) var(--ease),
    border-color var(--dur-hover) var(--ease),
    opacity var(--dur-hover) var(--ease);
}
.btn:hover:not(:disabled) { background: var(--night-3); border-color: var(--line-strong); }
.btn:focus-visible { outline: 2px solid var(--lantern); outline-offset: 2px; }
.btn:active:not(:disabled) { background: var(--night-2); }
.btn:disabled { color: var(--ink-3); background: var(--night-1); cursor: default; }

.btn-primary {
  background: var(--lantern);
  border-color: var(--lantern);
  color: var(--on-lantern);
  font-weight: 600;
}
.btn-primary:hover:not(:disabled) { background: var(--lantern-lift); border-color: var(--lantern-lift); }
.btn-primary:active:not(:disabled) { background: var(--lantern-dim); border-color: var(--lantern-dim); }
/* Saturated colour never appears on an inactive control. */
.btn-primary:disabled { background: var(--night-2); border-color: var(--line); color: var(--ink-3); }

.btn[data-loading] { color: var(--ink-3); cursor: progress; }
