/* controls.css — the control vocabulary the views share: buttons, the
   segmented control, keyboard hints, notes, tags, pills and empty states.
   Sizes: 36 px controls for a mouse, 44 px for a finger. */

/* ── Buttons ── */
.button, a.button { align-items: center; background: var(--signal); border: 1px solid var(--signal); border-radius: var(--radius-lg); color: var(--signal-ink); cursor: pointer; display: inline-flex; font: 600 13px var(--display); gap: 8px; justify-content: center; min-height: var(--control-h); padding: 0 14px; text-decoration: none; transition: background var(--dur-fast), border-color var(--dur-fast); }
.button:hover, a.button:hover { background: var(--signal-soft); border-color: var(--signal-soft); }
button.secondary { align-items: center; background: var(--raised); border: 1px solid var(--line); border-radius: var(--radius-lg); color: var(--ink); display: inline-flex; font: 600 13px var(--display); gap: 8px; justify-content: center; min-height: var(--control-h); padding: 0 14px; transition: border-color var(--dur-fast); }
button.secondary:hover { border-color: var(--signal); }
button.link { background: transparent; border: 0; color: var(--ink); font: inherit; min-height: 0; padding: 0; text-decoration: underline; text-underline-offset: 2px; }
button.link:hover { color: var(--signal); }
.button:disabled, button.secondary:disabled { cursor: not-allowed; opacity: .45; }

/* ── Segmented control: one choice from a few, drawn as one box. ── */
.segmented { border: 1px solid var(--line); border-radius: 6px; display: inline-flex; overflow: hidden; }
.segmented button { background: var(--raised); border: 0; border-radius: 0; color: var(--muted); cursor: pointer; font: 600 12px var(--display); min-height: 30px; padding: 0 12px; transition: background var(--dur-fast), color var(--dur-fast); white-space: nowrap; }
.segmented button + button { border-left: 1px solid var(--line); }
.segmented button:hover { color: var(--ink); }
.segmented button.active { background: var(--signal-tint); color: var(--ink); }
.segmented button:disabled { cursor: default; opacity: .45; }
.segmented button:focus-visible { outline-offset: -2px; }

/* ── Keyboard hint ── */
kbd, .kbd-hint { background: var(--raised); border: 1px solid var(--line); border-radius: var(--radius); color: var(--muted); display: inline-block; font: 600 11px/1.4 var(--mono); padding: 1px 6px; vertical-align: middle; }
.search-btn-kbd { margin-left: 2px; }

/* ── Note: a message in the flow with a 3 px state-coloured edge. Replaces
   the stale, override and first-run banners. ── */
.note { background: var(--panel); border: 1px solid var(--line); border-left: 3px solid var(--muted); border-radius: var(--radius); color: var(--ink); font: 13px/1.5 var(--display); margin: 0 0 var(--s-4); padding: 10px 14px; }
.note[hidden] { display: none; }
.note-signal { border-left-color: var(--signal); }
.note-green { border-left-color: var(--green); }
.note-amber { border-left-color: var(--amber); }
.note-ember { border-left-color: var(--ember); }
.note-blue { border-left-color: var(--blue); }
.note-row { align-items: center; display: flex; flex-wrap: wrap; gap: 8px 14px; }
.note-body { flex: 1 1 200px; min-width: 0; }
.note-title { font-weight: 600; }
.note-detail { color: var(--muted); font-size: 12px; margin-top: 2px; }
.note-detail strong { color: var(--ink); font-weight: 600; }
.note-dismiss { margin: -6px -8px -6px auto; }
.note-row > button.secondary { flex: none; }

/* ── Tags and pills ── */
.tag { border: 1px solid var(--line); border-radius: var(--radius); color: var(--muted); display: inline-block; font: 500 11px var(--display); letter-spacing: .04em; padding: 3px 7px; text-transform: uppercase; }
.pill { align-items: center; border: 1px solid var(--line); border-radius: var(--radius-pill); color: var(--muted); display: inline-flex; font: 600 11px var(--display); gap: 5px; padding: 3px 10px; white-space: nowrap; }
.pill-green { background: var(--green-tint); border-color: color-mix(in srgb, var(--green) 30%, transparent); color: var(--green); }
.pill-amber { background: var(--amber-tint); border-color: color-mix(in srgb, var(--amber) 30%, transparent); color: var(--amber); }
.pill-ember { background: var(--ember-tint); border-color: color-mix(in srgb, var(--ember) 30%, transparent); color: var(--ember); }
.pill-blue { background: var(--blue-tint); border-color: color-mix(in srgb, var(--blue) 30%, transparent); color: var(--blue); }
.pill-signal { background: var(--signal-tint); border-color: color-mix(in srgb, var(--signal) 30%, transparent); color: var(--signal); }

/* ── Empty state ── */
.empty { border: 1px dashed var(--line); border-radius: var(--radius-lg); color: var(--dim); font: 13px var(--display); padding: var(--s-7) var(--s-4); text-align: center; }

/* Small controls still meet the 24 px target; a finger gets 44 px. */
@media (pointer: coarse) {
  .button, button.secondary { min-height: var(--touch); }
  .segmented button { min-height: var(--touch); min-width: var(--touch); }
  .note-dismiss { margin-top: -10px; margin-bottom: -10px; }
}
