/* Design tokens: color, scale, space, shape, motion, layers. Typefaces live in typography.css. */

:root {
  /* Color, by role */
  --c-bg: #f2f3ee;          /* ground: cool stone white */
  --c-surface: #fbfbf8;     /* forms, cards */
  --c-fg: #101a13;          /* ink: green-black */
  --c-muted: #525d55;       /* secondary text, 6.6:1 on ground */
  --c-line: rgb(16 26 19 / 0.14);
  --c-line-strong: rgb(16 26 19 / 0.32);
  --c-accent: #2e9c40;      /* brand green: thread, nodes, fills, newsletter field */
  --c-accent-ink: #1f7a2f;  /* green for small text on ground (5.2:1) */
  --c-deep: #0d2214;        /* footer, carousel */
  --c-on-deep: #eef1ec;
  --c-on-deep-muted: #a7b6aa;
  --c-thread: var(--c-accent);

  /* Type scale (families in typography.css) */
  --t-mega: clamp(3.4rem, 0.4rem + 13.2vw, 17rem);
  --t-xl: clamp(2.5rem, 1.15rem + 4.1vw, 6rem);
  --t-l: clamp(1.75rem, 1.2rem + 1.9vw, 3.25rem);
  --t-m: clamp(1.25rem, 1.05rem + 0.65vw, 1.75rem);
  --t-body: clamp(1rem, 0.96rem + 0.15vw, 1.125rem);
  --t-s: 0.875rem;
  --t-xs: 0.8125rem;

  /* Space and grid */
  --u: clamp(0.5rem, 0.36rem + 0.6vw, 1rem);
  --gutter: clamp(1rem, 0.55rem + 1.5vw, 2.25rem);
  --margin: clamp(1.5rem, 0.4rem + 3.3vw, 4.5rem);
  --header-h: 4.5rem;
  --topbar-h: 2.5rem;
  --header-total: calc(var(--header-h) + var(--topbar-h));

  /* Shape: rounded, to echo the circles of the logo and the thread. Three levels:
     s = fields and small blocks, m = images and cards (sheets), pill = buttons and tags */
  --radius-s: 0.5rem;
  --radius-m: clamp(0.75rem, 0.5rem + 0.6vw, 1.25rem);
  --radius-pill: 999px;
  --radius: var(--radius-s);

  /* Motion */
  --ease-out: cubic-bezier(0.16, 1, 0.3, 1);
  --ease-soft: cubic-bezier(0.215, 0.61, 0.355, 1);

  /* Layers */
  --z-thread: 2;
  --z-header: 50;
  --z-menu: 60;
}

@media (max-width: 767px) {
  :root { --header-h: 4rem; --topbar-h: 2rem; --margin: 1.5rem; --gutter: 1rem; }
}
