/* ==========================================================================
   BALIDA — shared design tokens
   Loaded by both the login screen and the app so the two cannot drift apart.
   Look: editorial/terminal. Monospace throughout, pure black on white,
   hairline rules, square corners, no shadows.
   ========================================================================== */

/* Bundled typeface: iA Writer Mono S (SIL OFL 1.1, see fonts/OFL.txt).
   Self-hosted because the deployment targets an intranet whose proxy resets
   connections to CDNs, and because the OS mono stack renders differently on
   every machine (Consolas / SF Mono / Liberation Mono). Fallbacks kept for
   the rare case the woff2 fails to load. */
@font-face {
  font-family: "BALIDA Mono";
  src: url("fonts/iAWriterMonoS-Regular.woff2") format("woff2");
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: "BALIDA Mono";
  src: url("fonts/iAWriterMonoS-Bold.woff2") format("woff2");
  font-weight: 700;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: "BALIDA Mono";
  src: url("fonts/iAWriterMonoS-Italic.woff2") format("woff2");
  font-weight: 400;
  font-style: italic;
  font-display: swap;
}

:root {
  color-scheme: light;

  --font-mono: "BALIDA Mono", "SFMono-Regular", Consolas, "Liberation Mono", monospace;

  /* Surfaces */
  --paper: #fff;
  --shade: #f4f4f4;        /* hover fill for neutral controls */
  --shade-strong: #ebebeb; /* active/selected neutral fill */

  /* Ink */
  --ink: #111;
  --ink-medium: #444;
  --ink-soft: #6b6b6b;
  --ink-muted: #767676;    /* 4.54:1 on white — still AA for body text */
  --ink-faint: #b3b3b3;

  /* Rules */
  --rule: #111;            /* structural: frames, control borders */
  --rule-soft: #d4d4d4;    /* internal separators */
  --rule-faint: #e8e8e8;

  /* Motion & focus */
  --speed: 0.12s ease;
  --focus-ring: 2px solid var(--ink);
  --focus-offset: 3px;
}

/* --- Minimal shared reset ------------------------------------------------ */

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  -webkit-text-size-adjust: 100%;
}

body {
  margin: 0;
  font-family: var(--font-mono);
  font-size: 15px;
  line-height: 1.6;
  color: var(--ink);
  background: var(--paper);
  font-synthesis: none;
}

h1,
h2,
h3,
h4 {
  margin: 0;
  font-weight: 600;
  line-height: 1.3;
}

p {
  margin: 0;
}

a {
  color: inherit;
}

button,
input,
select,
textarea {
  font: inherit;
  color: inherit;
}

:focus-visible {
  outline: var(--focus-ring);
  outline-offset: var(--focus-offset);
}

::selection {
  background: var(--ink);
  color: var(--paper);
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}
