/* Raúl Balanzá: portfolio tokens. Dark-first: the brand lives on ink. */
:root {
  /* brand pair: the only colours the R is ever printed in (plus pure black and white) */
  --ink: #191918;
  --paper: #D2D1C9;
  --paper-light: #ECEBE4;

  /* surfaces (dark) */
  --bg: var(--ink);
  --fg: var(--paper);
  --muted: #8C8B84;
  --line: #34332F;
  --raise: #201F1D;

  /* type */
  --f-display: "Balanza", "Schibsted Grotesk", "Helvetica Neue", Arial, sans-serif;
  --f-body: "Schibsted Grotesk", "Helvetica Neue", Arial, sans-serif;
  --f-mono: "Martian Mono", ui-monospace, "SF Mono", Menlo, monospace;
  --step--1: 0.75rem;  /* mono labels */
  --step-0: 1rem;      /* body */
  --step-1: 1.25rem;   /* lead */
  --step-2: 1.75rem;   /* h2, Balanza Regular */
  --step-3: 2.75rem;   /* h1, Balanza Bold */
  --step-4: clamp(3rem, 9vw, 6.5rem); /* the name on the home page */

  /* the grid: one stroke (18 units) is the base spacing unit */
  --u: 18px;
  --radius-tile: 22.5%;
  --radius: 4px;
  color-scheme: dark;
}
@media (prefers-color-scheme: light) {
  :root:not([data-theme="dark"]) {
    --bg: var(--paper-light); --fg: var(--ink); --muted: #6A6964; --line: #D3D2CA; --raise: #E3E2DA;
    color-scheme: light;
  }
}
:root[data-theme="light"] {
  --bg: var(--paper-light); --fg: var(--ink); --muted: #6A6964; --line: #D3D2CA; --raise: #E3E2DA;
  color-scheme: light;
}
:root[data-theme="dark"] {
  --bg: var(--ink); --fg: var(--paper); --muted: #8C8B84; --line: #34332F; --raise: #201F1D;
  color-scheme: dark;
}

/* the prompt cursor: same colour as the text, it only blinks */
@keyframes blink { 50% { opacity: 0; } }
.cursor { animation: blink 1.06s steps(1) infinite; }
@media (prefers-reduced-motion: reduce) { .cursor { animation: none; } }
