/*
 * Palomares Abogados — design tokens.
 * Source of truth for the brandbook (/brandbook). Change values here, nowhere else.
 * Fonts are self-hosted (no Google Fonts request → no visitor IP sent to third parties).
 */

@font-face {
  font-family: "Spectral";
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url("/assets/spectral-latin-400-82f8bc22.woff2") format("woff2");
}

@font-face {
  font-family: "Spectral";
  font-style: italic;
  font-weight: 400;
  font-display: swap;
  src: url("/assets/spectral-latin-400-italic-6841867a.woff2") format("woff2");
}

@font-face {
  font-family: "Spectral";
  font-style: normal;
  font-weight: 600;
  font-display: swap;
  src: url("/assets/spectral-latin-600-555b4b83.woff2") format("woff2");
}

@font-face {
  font-family: "Cabin";
  font-style: normal;
  font-weight: 400 700;
  font-display: swap;
  src: url("/assets/cabin-latin-98b5fabe.woff2") format("woff2");
}

@font-face {
  font-family: "Cabin";
  font-style: italic;
  font-weight: 400 700;
  font-display: swap;
  src: url("/assets/cabin-latin-italic-f80da7b3.woff2") format("woff2");
}

:root {
  /* Brand gold — ONLY brand: logo, thin rules, active marks, text on dark (6.76:1 on --night).
     Never for actions or small text on light backgrounds (2.55:1 on white). */
  --gold-brand: #c09f34;
  --gold-web: #aa8b00;     /* website accent, kept for reference; not used in the platform */

  /* Primary (decided 2026-11-19): Pizarra. Every action and interactive state. */
  --primary: #334155;      /* white text 10.4:1, on paper 9.8:1 */
  --primary-hover: #243041;
  --primary-wash: #eaedf1; /* selected rows, secondary hover, soft highlights (primary text 8.8:1) */
  --primary-link: #334155;
  --primary-contrast: #fff;

  /* Neutrals: warm, paper-like */
  --ink: #212121;          /* body text (16.1:1) */
  --ink-soft: #6b6760;     /* secondary text (5.62:1) */
  --paper: #faf8f3;        /* app background */
  --surface: #ffffff;      /* cards, tables, forms */
  --line: #e6e1d6;         /* borders, dividers */
  --night: #1c1b19;        /* dark surfaces: header, sidebar */

  /* Semantic (all ≥ 4.5:1 on their wash and on white) */
  --success: #2f6b3a;  --success-wash: #eaf3ec;
  --danger: #a8322b;   --danger-wash: #fbecea;
  --warning: #8a5300;  --warning-wash: #fbf2e2;
  --info: #2b5a80;     --info-wash: #eaf1f7;
  --special: #5b3f86;  --special-wash: #f0ebf7; /* rectified invoices (7.2:1) */

  /* Typography */
  --font-title: "Spectral", Georgia, "Times New Roman", serif;
  --font-body: "Cabin", system-ui, -apple-system, "Segoe UI", sans-serif;
  --font-numeric: "Cabin", system-ui, sans-serif; /* use with tabular-nums for amounts */

  --text-xs: 0.8125rem;
  --text-sm: 0.875rem;
  --text-base: 1rem;
  --text-lg: 1.125rem;
  --text-xl: clamp(1.375rem, 1.2rem + 0.6vw, 1.625rem);
  --text-2xl: clamp(1.75rem, 1.4rem + 1.2vw, 2.25rem);
  --text-display: clamp(2.5rem, 1.8rem + 3vw, 4rem);

  --leading-tight: 1.15;
  --leading-body: 1.55;
  --tracking-caps: 0.14em; /* for small uppercase labels, as on the website */

  /* Space (4px base) */
  --space-1: 0.25rem;
  --space-2: 0.5rem;
  --space-3: 0.75rem;
  --space-4: 1rem;
  --space-6: 1.5rem;
  --space-8: 2rem;
  --space-12: 3rem;
  --space-16: 4rem;

  /* Shape & depth: sober, almost square — a law firm, not a startup */
  --radius-sm: 2px;
  --radius-md: 4px;
  --shadow-card: 0 1px 0 rgba(33, 33, 33, 0.04), 0 8px 24px -12px rgba(33, 33, 33, 0.18);
  --focus-ring: 0 0 0 3px var(--paper), 0 0 0 5px var(--primary);

  /* Motion */
  --duration-fast: 120ms;
  --duration-normal: 220ms;
  --ease-out: cubic-bezier(0.16, 1, 0.3, 1);
}
