/* GRAPHICA Flow site — tokens.css — v1.21 (the corner buttons are the films' size on every screen: 52 px, the films'
   corner gap; Martin 2026-11-19: "the Play is smaller than in the demos") | v1.20 (a phone held sideways: the hero logo 5vh lower, --phone-wide-hero-drop); v1.19 (the heavy row is 5% heavier, the day's floating words 30% smaller; before: v1.18, a phone held sideways: every size follows the screen's height; each scene's words have a size share, --scale-*; before: v1.17, a step's title has its own transparency, solid: --alpha-step-title; before: v1.16, the corner buttons' size and distance from the corner: --corner-button, --corner-inset; before: v1.15, phone: the stream's text 100 px higher, 10; the small logo at the top fades in and out slowly: --header-logo-fade-in / -out, --ease-soft; before: v1.14, phone: the day's text higher, 90; the stream's text has its own lift, -90, 150 px lower; before: v1.13,phone: the logo and its first text sit higher, --phone-hero-lift; the day's text higher, 60, and the stream's text at the same height; before: v1.12,--phone-chaos-lift 30: the day's text sits a little higher, off the screen's edge; before: v1.11, --phone-chaos-lift 0: it no longer covers the logo; before: v1.10, a phone moves some text blocks: --phone-*; before: v1.09, the shore's small print at half: --alpha-shore-fine; before: v1.08, a transparency for every kind of text: --alpha-*; before: v1.07, a size and a colour for every kind of text: --size-*, --color-*)
   Every colour, size and timing the page uses, as named variables, plus the base of the page.
   The site is dark only: GRAPHICA Flow lives on its night ground (the homepage and the interview do the same).
   Portrait layout = (max-aspect-ratio: 21/20), the same threshold as scripts/world-layout.js. */

:root {
  color-scheme: dark;

  /* brand colours (Flow Design Language) */
  --ground: #0b0a09;
  --ground-glass: rgba(21, 19, 16, 0.56);
  --ground-scrim-red: 11; /* the dark patch behind the text (copy.css .scrim): its colour... */
  --ground-scrim-green: 10;
  --ground-scrim-blue: 9;
  --ground-scrim-alpha: 0.74; /* ...how dark its middle is... */
  --ground-scrim-soft-alpha: 0.36; /* ...and its soft part */
  --ink: #f2eee7;
  --ink-2: #bdb6ac;
  --ink-3: #857d73;
  --line: rgba(242, 238, 231, 0.13);
  --line-strong: rgba(242, 238, 231, 0.24);
  --warm: #fec231;
  --pale: #ffe39a;
  --cold: #4bf1e2;
  --warm-ink: #17120a;

  /* the ScrollCraft engine's own tokens, themed */
  --sc-canvas: var(--ground);
  --sc-surface: #15130f;
  --sc-ink: var(--ink);
  --sc-ink-soft: var(--ink-2);
  --sc-accent: var(--warm);
  --sc-accent-ink: var(--warm-ink);
  --sc-font-display: var(--font);
  --sc-font-text: var(--font);
  --sc-font-mono: var(--font);

  /* type: Roboto Flex only; wide and thin against wide and heavy */
  --font: 'Roboto Flex', 'Segoe UI', Arial, sans-serif;
  --stretch-wide: 122%;
  --stretch-wider: 130%;
  --stretch-label: 112%;
  --weight-thin: 200;
  --weight-body: 380;
  --weight-medium: 520;
  --weight-bold: 605; /* the heavy row of every title, 5% heavier than 576 (Martin, 2026-11-16) */
  --track-title: -0.05em;
  --track-label: -0.02em;
  --t-hero: clamp(2.2rem, 1.1rem + 3.4vw, 4.6rem);
  --hero-title-scale: 0.6; /* the hero title stays quieter than the logo above it (Look Studio tunes these two) */
  --hero-lede-scale: 0.92;
  --t-title: clamp(1.75rem, 1rem + 2.2vw, 3.3rem);
  --t-statement: clamp(1.9rem, 0.8rem + 2.4vw, 3.4rem); /* it sits in the left column, beside the galaxy */
  --t-lede: clamp(1rem, 0.93rem + 0.3vw, 1.22rem);
  --t-body: clamp(0.98rem, 0.93rem + 0.2vw, 1.12rem);
  --t-small: clamp(0.84rem, 0.82rem + 0.1vw, 0.92rem);
  --t-fine: 0.8rem;
  --t-label: 0.75rem;
  --leading-title: 1.02;
  --leading-body: 1.55;

  /* every kind of text: its size (× the size above, 1 = as designed) and its colour. Look Studio tunes them
     ("Texts: size and colour"); the hero's two sizes are --hero-title-scale and --hero-lede-scale above */
  --size-title: 1; /* the title of every scene */
  --size-statement: 1; /* the one large sentence beside the galaxy */
  --size-body: 1; /* the text under a title */
  --size-fine: 1; /* the small print */
  --size-label: 1; /* the small capitals: "Примерна система", the sign-off */
  --size-words: 0.7; /* the floating words of the day: 30% smaller (Martin, 2026-11-16; before: 1) */
  --size-sign-name: 1; /* the firm's name under the galaxy */
  --size-steps: 1; /* the six steps of the method */
  --size-points: 1; /* the points beside each example tablet */
  --size-slogan: 1; /* the line on the shore */
  --size-phone: 1; /* the phone number on the shore */
  /* wide screens: how big each scene's whole block of words is (its title, text and small print, and the room it
     takes), 1 = as designed (copy.css --copy-scale; Martin, 2026-11-16: the words crowded the logo) */
  --scale-chaos: 0.8;
  --scale-stream: 0.8;
  --scale-statement: 0.85;
  --scale-signature: 0.85;
  --scale-method: 0.9;
  --scale-shore: 0.75; /* the contact screen (title, line, name, phone, call button): 25% smaller, every screen (Martin, 2026-11-17) */
  --color-hero-title: #f2eee7;
  --color-hero-lede: #bdb6ac;
  --color-title: #f2eee7;
  --color-statement: #f2eee7; /* its heavy part... */
  --color-statement-soft: #bdb6ac; /* ...and its thin part */
  --color-body: #bdb6ac;
  --color-fine: #857d73;
  --color-label: #bdb6ac;
  --color-words: #bdb6ac; /* at rest... */
  --color-words-glint: #f2eee7; /* ...and at the top of a twinkle */
  --color-sign-name: #ffe39a;
  --color-step-title: #f2eee7; /* a step once its node is lit */
  --color-step-body: #bdb6ac;
  --color-points: #bdb6ac; /* a point... */
  --color-points-lit: #f2eee7; /* ...and while it lights its part of the dashboard */
  --color-slogan: #bdb6ac;
  --color-phone: #f2eee7;
  /* how solid each kind of text is, 1 = fully (Look Studio: Transparency); the colours above are mixed with it */
  --alpha-hero-title: 1;
  --alpha-hero-lede: 1;
  --alpha-title: 1;
  --alpha-statement: 1;
  --alpha-body: 1;
  --alpha-fine: 1;
  --alpha-shore-fine: 0.5; /* the small print at the foot of the shore, on top of --alpha-fine */
  --alpha-label: 1;
  --alpha-words: 1;
  --alpha-sign-name: 1;
  --alpha-steps: 1; /* the texts under the six steps' titles */
  --alpha-step-title: 1; /* the six steps' titles: solid, as the bold line of the title above them */
  --alpha-points: 1;
  --alpha-slogan: 1;
  --alpha-phone: 1;

  /* space */
  --gutter: clamp(16px, 5vw, 76px);
  --header-h: clamp(58px, 8vh, 78px);
  --map-h: 76px;
  --radius-pill: 999px;
  /* the round glass buttons in the corners (play / pause bottom right, the full screen's X top right): their size,
     and one distance from both edges of their corner, so they sit square in it */
  --corner-button: 52px; /* the films' Play (showreel/engine/engine.css --reel-button, the demos' --tour-button) */
  --corner-inset: clamp(16px, 2.4vw, 28px); /* the films' --reel-corner */
  /* a phone (the portrait layout) moves some text blocks from their place, in px (Look Studio: "Texts: size and
     colour", Phone): the logo with its first text up, the day's text up, the stream's text down (below 0 = lower
     than its place at the bottom), the large sentence and the signature copy down, the method up */
  --phone-hero-lift: 50;
  --phone-chaos-lift: 90;
  --phone-stream-lift: 10;
  --phone-statement-drop: 60;
  --phone-signature-drop: 60;
  --phone-method-lift: 100;

  /* motion */
  --ease-out: cubic-bezier(0.16, 1, 0.3, 1);
  --fade-quick: 0.32s;
  --fade-slow: 0.6s;
  --ease-soft: cubic-bezier(0.45, 0, 0.55, 1); /* slow at both ends: a fade with no sudden start */
  /* the small logo at the top comes in and leaves this slowly, in seconds (Look Studio: "Everywhere: the thread and the clicks") */
  --header-logo-fade-in: 2.4;
  --header-logo-fade-out: 1.8;
  --reveal: 1.06s; /* a method step or a system part comes in out of a blur over this long */
  --reveal-blur: 10px;
  --reveal-rise: 14px;
  --flash: 1.6s; /* the glow on a step's title when its node lights up */
  --halo-pulse: 2.8s; /* the ripple around the stage map's active stage */

  /* homepage animation values (homepage/flow-config.js overwrites them live) */
  --veil-c: 0.42;
  --veil-e: 0.68;
  --veil-a: 0;
  --logo-w: 20;
  --logo-glow: 0.29;
  --aura-a: 0.19;
  --aura-blur: 0.8;
  --aura-size: 1;
  --aura-run: 3.2s;
  --aura-breath: 6.3s;
  --bg-k: 0;
  --glow-k: 0;
  --logo-delay: 0.3s;
  --logo-time: 2.4s;
  --logo-px: clamp(calc(var(--logo-w) * 10px), calc(var(--logo-w) * 1vw), calc(var(--logo-w) * 19px));
  --lh: calc(var(--logo-px) * 0.12749);
}

@media (max-aspect-ratio: 21/20) {
  :root {
    --map-h: 68px;
    --t-title: clamp(1.6rem, 1.1rem + 2.4vw, 2.4rem);
    --t-statement: clamp(1.9rem, 1.2rem + 3.4vw, 3rem);
  }
}

/* a phone held sideways (wide, but very short): the same picture as on a computer, every size in step with the
   screen's height (the computer's sizes at 900 px, divided by 9 give the vh below). Only the words to read keep a small
   floor, so they stay legible; the titles follow the height exactly */
@media (min-aspect-ratio: 21/20) and (max-height: 520px) {
  :root {
    --t-hero: 8vh;
    --t-title: 5.8vh;
    --t-statement: 6vh;
    --t-lede: max(11px, 2.2vh);
    --t-body: max(11px, 2vh);
    --t-small: max(10px, 1.7vh);
    --t-fine: max(9px, 1.4vh);
    --t-label: max(8.5px, 1.3vh);
    --gutter: clamp(16px, 5vw, 76px);
    --header-h: clamp(28px, 8vh, 78px);
    --map-h: 34px;
    /* the corner buttons keep the films' size here too (Martin 2026-11-19) */
    --logo-px: calc(var(--logo-w) * 1vw);
    /* the hero logo a little lower than the middle (Martin 2026-11-17: "too high on my phone held sideways") */
    --phone-wide-hero-drop: 5vh;
  }
}

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

body {
  margin: 0;
  background: var(--ground);
  color: var(--ink);
  font-family: var(--font);
  font-weight: var(--weight-body);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
}

::selection {
  background: rgba(254, 194, 49, 0.32);
  color: var(--ink);
}

.weight-thin {
  font-weight: var(--weight-thin);
}

.weight-bold {
  font-weight: var(--weight-bold);
}
