/*
  Type system for the new rsla.io, picked by Rahul on 2026-10-19.
  Bricolage Grotesque: headlines and big numbers. Inter: everything people read or tap.
  Load ../../public/fonts/bricolage-grotesque.css and ../../public/fonts/inter.css before this file. They define the fonts and,
  after each, a metric-matched fallback ("Bricolage Grotesque Fallback", "Inter Fallback": Arial sized to the font) that the stacks
  below list next, so text paints at once and the swap to the real font does not move a line.

  Each role has a phone size (at 375 px wide) and a desktop size (from 1280 px), fluid in between.
  One role goes below its phone size: under 379 px wide "Be your town’s" no longer fits one line at 50 px, so the hero headline
  (.t-hero) follows the width there (49 px at 375, 47 at 360, 40 at 320) and stays on two lines. Rahul, 2026-10-22.
  Specimen of every role: the Type tab of docs/style-guide/index.html, built from this file.
*/

:root {
  --font-display: "Bricolage Grotesque", "Bricolage Grotesque Fallback", ui-sans-serif, system-ui, sans-serif;
  --font-text: "Inter", "Inter Fallback", ui-sans-serif, system-ui, sans-serif;
}

html { font-family: var(--font-text); }

/* Bricolage Grotesque */
.t-hero      { font-family: var(--font-display); font-size: clamp(3.125rem, 1.934rem + 5.083vw, 6rem); font-weight: 700; line-height: 1; letter-spacing: -0.02em; }        /* 50 to 96, 40 to 49 under 379 px wide */
@media (max-width: 378.98px) { .t-hero { font-size: clamp(2.5rem, 16.11vw - 0.7125rem, 3.125rem); } }  /* the widest the line "Be your town’s" can be is 0.1611 px of font per px of screen less 10.8 (measured in WebKit and Chromium); this is 0.6 px under that, so two lines hold down to 320 px */
.t-h1       { font-family: var(--font-display); font-size: clamp(2.25rem, 1.732rem + 2.21vw, 3.5rem); font-weight: 700; line-height: 1.05; letter-spacing: -0.02em; }      /* 36 to 56 */
.t-h2        { font-family: var(--font-display); font-size: clamp(1.875rem, 1.564rem + 1.326vw, 2.625rem); font-weight: 700; line-height: 1.1; letter-spacing: -0.01em; }  /* 30 to 42 */
.t-h3        { font-family: var(--font-display); font-size: clamp(1.5rem, 1.293rem + 0.884vw, 2rem); font-weight: 600; line-height: 1.15; }                                 /* 24 to 32 */
.t-stat      { font-family: var(--font-display); font-size: clamp(2.75rem, 2.232rem + 2.21vw, 4rem); font-weight: 700; line-height: 1; letter-spacing: -0.02em; font-variant-numeric: tabular-nums; } /* 44 to 64 */
.t-hero-stat { font-family: var(--font-display); font-size: clamp(1.25rem, 1.146rem + 0.442vw, 1.5rem); font-weight: 700; line-height: 1.2; letter-spacing: -0.01em; }      /* 20 to 24 */
.t-logo      { font-family: var(--font-display); font-size: 1.25rem; font-weight: 700; letter-spacing: -0.01em; }                                                          /* 20 */

/* Inter */
.t-h4        { font-family: var(--font-text); font-size: clamp(1.25rem, 1.146rem + 0.442vw, 1.5rem); font-weight: 600; line-height: 1.3; letter-spacing: -0.015em; }       /* 20 to 24 */
.t-lead      { font-family: var(--font-text); font-size: clamp(1.1875rem, 1.11rem + 0.331vw, 1.375rem); font-weight: 500; line-height: 1.45; letter-spacing: -0.015em; }   /* 19 to 22 */
.t-body      { font-family: var(--font-text); font-size: clamp(1.0625rem, 1.037rem + 0.11vw, 1.125rem); font-weight: 400; line-height: 1.6; letter-spacing: -0.01em; }     /* 17 to 18 */
.t-small     { font-family: var(--font-text); font-size: 0.9375rem; font-weight: 400; line-height: 1.5; }                                                                    /* 15 */
.t-caption   { font-family: var(--font-text); font-size: 0.8125rem; font-weight: 500; line-height: 1.4; }                                                                    /* 13, the floor */
.t-nav       { font-family: var(--font-text); font-size: 1rem; font-weight: 500; line-height: 1; }                                                                           /* 16 */
.t-nav-lg    { font-size: 1.125rem; }                                                                                                                                         /* 18, phone menu */
.t-button    { font-family: var(--font-text); font-size: 1.0625rem; font-weight: 600; line-height: 1; }                                                                      /* 17 */
.t-button-lg { font-size: 1.125rem; }                                                                                                                                         /* 18, hero */
.t-label     { font-family: var(--font-text); font-size: 0.9375rem; font-weight: 500; line-height: 1.4; }                                                                    /* 15 */
.t-input     { font-family: var(--font-text); font-size: 1.0625rem; font-weight: 400; line-height: 1.4; }                                                                    /* 17, never under 16 */
.t-input::placeholder { color: #6e6e73; opacity: 1; }  /* 5.1:1 on white; still lighter than typed text. Placeholders only show a format, never replace the label */
.t-num       { font-variant-numeric: tabular-nums; font-weight: 500; }

.measure     { max-width: 66ch; }

/* Selected text takes the site's blue on every page, light or dark (a browser's default highlight belongs to no palette) */
::selection { background-color: rgb(37 99 235 / 0.3); color: inherit; }
