/* ==========================================================================
   Skill Lab — stile
   Carta, inchiostro, blu reagente. Linee sottili al posto dei box.
   ========================================================================== */

:root {
  --paper: #EEEAE0;
  --paper-2: #E3DED0;
  --paper-3: #F7F5EF;
  --ink: #0F0F0E;
  --ink-2: #1B1B19;
  --ink-3: #2A2926;
  --muted: #6F6B62;
  --muted-ink: #9D998E;
  --blue: #2E2BFF;
  --blue-soft: #8F8DFF;
  --verm: #FF4B1F;
  --ochre: #E3B23C;
  --forest: #1F3D2C;
  --glass: #BFD8D2;
  --line: rgba(15, 15, 14, .16);
  --line-ink: rgba(238, 234, 224, .16);

  --f-display: 'Anybody', 'Arial Narrow', system-ui, sans-serif;
  --f-serif: 'Newsreader', Georgia, 'Times New Roman', serif;
  --f-mono: 'Martian Mono', ui-monospace, 'Cascadia Mono', Consolas, monospace;

  --pad: clamp(16px, 3.4vw, 52px);
  --gut: clamp(12px, 1.6vw, 24px);
  --nav-h: 64px;
  --ease: cubic-bezier(.16, .84, .24, 1);
  --ease-io: cubic-bezier(.76, 0, .24, 1);
}

/* ---------- Base ---------- */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; scroll-padding-top: 20px; }
body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--f-serif);
  font-size: clamp(17px, 1.12vw, 19px);
  line-height: 1.45;
  font-optical-sizing: auto;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}
img, svg { display: block; }
a { color: inherit; }
button { font: inherit; color: inherit; background: none; border: 0; padding: 0; cursor: pointer; }
input { font: inherit; }
::selection { background: var(--blue); color: var(--paper); }
:focus-visible { outline: 2px solid var(--blue); outline-offset: 3px; }
[data-theme="ink"] :focus-visible, [data-theme="blue"] :focus-visible { outline-color: var(--paper); }

.mono {
  font-family: var(--f-mono);
  font-size: .64rem;
  font-weight: 400;
  font-stretch: 87.5%;
  letter-spacing: .05em;
  line-height: 1.5;
  text-transform: uppercase;
}
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.skip { position: fixed; left: 8px; top: -80px; z-index: 300; background: var(--ink); color: var(--paper); padding: 12px 14px; text-decoration: none; }
.skip:focus { top: 8px; }

/* Temi di sezione */
[data-theme] { --bg: var(--paper); --fg: var(--ink); --mut: var(--muted); --ln: var(--line); background: var(--bg); color: var(--fg); }
[data-theme="paper2"] { --bg: var(--paper-2); }
[data-theme="ink"] { --bg: var(--ink); --fg: var(--paper); --mut: var(--muted-ink); --ln: var(--line-ink); }
[data-theme="blue"] { --bg: var(--blue); --fg: var(--paper); --mut: rgba(238, 234, 224, .72); --ln: rgba(238, 234, 224, .3); }
[data-theme="ochre"] { --bg: var(--ochre); --mut: rgba(15, 15, 14, .62); --ln: rgba(15, 15, 14, .22); }
[data-theme="verm"] { --bg: var(--verm); --mut: rgba(15, 15, 14, .62); --ln: rgba(15, 15, 14, .22); }
[data-theme="glass"] { --bg: var(--glass); --mut: rgba(15, 15, 14, .6); --ln: rgba(15, 15, 14, .2); }

.manifesto, .lens, .bench, .exp, .who, .kit, .method, .formula, .contact, .legal {
  position: relative;
  padding: clamp(44px, 5.5vw, 88px) var(--pad);
}

/* Testata di sezione: numero romano, titolo, figura */
.sec-head {
  position: relative;
  display: grid;
  grid-template-columns: 1fr 2fr 1fr;
  align-items: baseline;
  gap: 12px;
  border-top: 1px solid var(--ln);
  padding-top: 12px;
  margin: 0 0 clamp(20px, 2.6vw, 40px);
}
.sec-head span:nth-child(2) { text-align: center; }
.sec-head span:last-child { text-align: right; color: var(--mut); }
.sec-head::before, .sec-head::after {
  content: "";
  position: absolute;
  top: -6px;
  width: 11px; height: 11px;
  background:
    linear-gradient(currentColor, currentColor) center / 1px 100% no-repeat,
    linear-gradient(currentColor, currentColor) center / 100% 1px no-repeat;
}
.sec-head::before { left: -5px; }
.sec-head::after { right: -5px; }

/* Titoli */
.h2 {
  margin: 0;
  font-family: var(--f-display);
  font-weight: 760;
  font-stretch: 70%;
  font-size: clamp(2.1rem, 4.6vw, 4.6rem);
  line-height: .96;
  letter-spacing: -.025em;
  text-transform: uppercase;
}
.h2 em, .contact__title em {
  font-family: var(--f-serif);
  font-style: italic;
  font-weight: 300;
  font-stretch: 100%;
  text-transform: none;
  letter-spacing: -.03em;
}
.lead { font-size: clamp(1.1rem, 1.5vw, 1.4rem); line-height: 1.35; margin: 0; max-width: 34ch; }

.split-intro {
  display: grid;
  grid-template-columns: repeat(12, 1fr);
  gap: var(--gut);
  align-items: end;
  margin-bottom: clamp(20px, 2.6vw, 36px);
}
.split-intro .h2 { grid-column: 1 / 9; }
.split-intro .lead { grid-column: 9 / 13; }

/* Pulsanti: rettangoli a filo, niente pillole */
.btn-line {
  position: relative;
  display: inline-flex;
  align-items: center;
  gap: 16px;
  padding: 18px 24px;
  border: 1px solid currentColor;
  font-family: var(--f-display);
  font-weight: 650;
  font-stretch: 120%;
  font-size: .82rem;
  letter-spacing: .03em;
  text-transform: uppercase;
  text-decoration: none;
  overflow: hidden;
  isolation: isolate;
  transition: color .45s var(--ease);
}
.btn-line::before {
  content: "";
  position: absolute; inset: 0;
  background: var(--fg, var(--ink));
  transform: translateY(101%);
  transition: transform .5s var(--ease);
  z-index: -1;
}
.btn-line:hover { color: var(--bg, var(--paper)); }
.btn-line:hover::before { transform: none; }
.btn-line .arr { display: inline-block; transition: transform .5s var(--ease); font-family: var(--f-serif); font-size: 1.3em; line-height: 0; }
.btn-line:hover .arr { transform: translateX(5px); }

.btn-text {
  position: relative;
  text-decoration: none;
  padding-bottom: 4px;
  background: linear-gradient(currentColor, currentColor) 0 100% / 100% 1px no-repeat;
  transition: background-size .5s var(--ease);
}
.btn-text:hover { background-size: 0 1px; background-position: 100% 100%; }

/* ---------- Grana della carta ---------- */
.grain {
  position: fixed; inset: 0;
  z-index: 90;
  pointer-events: none;
  opacity: .085;
  mix-blend-mode: multiply;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='180' height='180'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.85' numOctaves='3' stitchTiles='stitch'/%3E%3CfeColorMatrix values='0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 0'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
}

/* ---------- Caricamento ---------- */
.loader {
  position: fixed; inset: 0;
  z-index: 200;
  display: grid;
  grid-template-rows: auto 1fr auto auto;
  padding: var(--pad);
  background: var(--ink);
  color: var(--paper);
  transition: transform 1s var(--ease-io);
}
html:not(.js) .loader { display: none; }
.is-loaded .loader { transform: translateY(-100%); }
.is-done .loader { visibility: hidden; }
.loader__top, .loader__bottom { display: flex; justify-content: space-between; }
.loader__num {
  align-self: end;
  font-family: var(--f-display);
  font-weight: 800;
  font-size: clamp(6rem, 24vw, 24rem);
  line-height: .78;
  letter-spacing: -.04em;
  font-variation-settings: 'wdth' var(--lw, 50), 'wght' 800;
}
.loader__bar { height: 1px; margin: 18px 0 12px; background: rgba(238, 234, 224, .18); }
.loader__bar i { display: block; height: 100%; background: var(--paper); transform-origin: left; transform: scaleX(var(--p, 0)); }

/* ---------- Cursore ---------- */
.cursor {
  position: fixed; left: 0; top: 0;
  z-index: 250;
  pointer-events: none;
  color: #fff;
  mix-blend-mode: difference;
  display: none;
  will-change: transform;
}
.has-cursor .cursor { display: block; }
.has-cursor, .has-cursor a, .has-cursor button, .has-cursor [data-lens] { cursor: none; }
.has-cursor input, .has-cursor textarea { cursor: auto; }
.cursor__cross {
  position: absolute; left: -11px; top: -11px;
  width: 23px; height: 23px;
  background:
    linear-gradient(currentColor, currentColor) center / 1px 100% no-repeat,
    linear-gradient(currentColor, currentColor) center / 100% 1px no-repeat;
  transition: transform .4s var(--ease);
}
.cursor__ring {
  position: absolute; left: -26px; top: -26px;
  width: 52px; height: 52px;
  border: 1px solid currentColor;
  border-radius: 50%;
  opacity: 0;
  transform: scale(.4);
  transition: opacity .3s, transform .5s var(--ease);
}
.cursor.is-hover .cursor__ring { opacity: 1; transform: scale(1); }
.cursor.is-hover .cursor__cross { transform: rotate(45deg) scale(.7); }
.cursor.is-down .cursor__ring { transform: scale(.7); }
.cursor__coord, .cursor__label {
  position: absolute;
  left: 18px;
  font: 400 9px/1 var(--f-mono);
  letter-spacing: .06em;
  white-space: nowrap;
  text-transform: uppercase;
}
.cursor__coord { top: 14px; opacity: .75; }
.cursor__label { top: -22px; opacity: 0; transform: translateY(4px); transition: opacity .25s, transform .35s var(--ease); }
.cursor.has-label .cursor__label { opacity: 1; transform: none; }

/* ---------- Navigazione ---------- */
.nav {
  position: fixed; top: 0; left: 0; right: 0;
  z-index: 60;
  height: var(--nav-h);
  display: flex;
  align-items: center;
  gap: 24px;
  padding: 0 var(--pad);
  color: var(--nav-fg, var(--ink));
  transition: color .4s, transform .6s var(--ease);
}
.nav[data-on="ink"], .nav[data-on="blue"], .menu-open .nav { --nav-fg: var(--paper); }
.nav.is-hidden { transform: translateY(-110%); }
/* fondo del menu quando si scorre: niente testi che ci passano sotto */
.nav { isolation: isolate; --nav-bgc: var(--paper); --nav-ln: var(--line); }
.nav::before { content: ""; position: absolute; inset: 0; z-index: -1; background: var(--nav-bgc); border-bottom: 1px solid var(--nav-ln); opacity: 0; transition: opacity .35s, background .35s; -webkit-backdrop-filter: blur(10px); backdrop-filter: blur(10px); }
.nav.is-scrolled::before, .menu-open .nav::before { opacity: .96; }
.menu-open .nav::before { background: var(--ink); }
.nav[data-on="paper2"] { --nav-bgc: var(--paper-2); }
.nav[data-on="ink"] { --nav-bgc: var(--ink); --nav-ln: var(--line-ink); }
.nav[data-on="blue"] { --nav-bgc: var(--blue); --nav-ln: rgba(238, 234, 224, .3); }
.nav[data-on="ochre"] { --nav-bgc: var(--ochre); }
.nav[data-on="verm"] { --nav-bgc: var(--verm); }
.nav[data-on="glass"] { --nav-bgc: var(--glass); }
.nav__logo { display: flex; align-items: baseline; gap: .12em; font-size: 1.2rem; line-height: 1; text-decoration: none; }
.logo-skill { font-family: var(--f-display); font-weight: 800; font-stretch: 135%; letter-spacing: -.02em; text-transform: uppercase; transition: font-stretch .5s var(--ease); }
.nav__logo:hover .logo-skill { font-stretch: 70%; }
.logo-lab { font-family: var(--f-serif); font-style: italic; font-weight: 400; font-size: 1.15em; }
.nav__status { display: flex; align-items: center; gap: 10px; margin: 0 auto 0 28px; opacity: .8; }
.nav__clock::before { content: "·"; margin: 0 8px; }
.pulse { width: 7px; height: 7px; border-radius: 50%; background: var(--verm); animation: pulse 2.2s infinite; }
@keyframes pulse { 0% { box-shadow: 0 0 0 0 rgba(255, 75, 31, .55); } 70% { box-shadow: 0 0 0 9px rgba(255, 75, 31, 0); } 100% { box-shadow: 0 0 0 0 rgba(255, 75, 31, 0); } }
.nav__links { display: flex; align-items: center; gap: 26px; }
.nav__links a { position: relative; text-decoration: none; }
.nav__links a:not(.nav__cta)::after {
  content: ""; position: absolute; left: 0; right: 0; bottom: -5px; height: 1px;
  background: currentColor; transform: scaleX(0); transform-origin: right;
  transition: transform .45s var(--ease);
}
.nav__links a:hover::after { transform: scaleX(1); transform-origin: left; }
.nav__links sup { font-size: .8em; margin-right: 5px; opacity: .55; }
.nav__cta { border: 1px solid currentColor; padding: 10px 13px; transition: background .3s, color .3s; }
.nav__cta:hover { background: var(--nav-fg, var(--ink)); color: var(--blue); }
.nav__toggle { display: none; margin-left: auto; border: 1px solid currentColor; padding: 10px 14px; }

.menu {
  position: fixed; inset: 0;
  z-index: 55;
  display: flex; flex-direction: column; justify-content: space-between;
  padding: calc(var(--nav-h) + 20px) var(--pad) var(--pad);
  background: var(--ink); color: var(--paper);
  clip-path: inset(0 0 100% 0);
  visibility: hidden;
  transition: clip-path .7s var(--ease-io), visibility 0s .7s;
}
.menu.is-open { clip-path: inset(0); visibility: visible; transition: clip-path .7s var(--ease-io), visibility 0s; }
.menu a {
  display: flex; align-items: baseline; gap: 14px;
  padding: 6px 0;
  border-bottom: 1px solid var(--line-ink);
  font-family: var(--f-display); font-weight: 760; font-stretch: 78%;
  font-size: clamp(2rem, 9vw, 4.4rem); line-height: 1.02;
  text-transform: uppercase; text-decoration: none;
}
.menu a .mono { width: 2.6em; color: var(--verm); }
.menu__foot { color: var(--muted-ink); margin: 20px 0 0; }

/* ==========================================================================
   HERO
   ========================================================================== */
.hero {
  position: relative;
  min-height: min(94svh, 960px);
  display: flex; flex-direction: column;
  padding: calc(var(--nav-h) + 12px) var(--pad) var(--pad);
  overflow: hidden;
}
.hero__guides {
  position: absolute; inset: 0 var(--pad);
  border-right: 1px solid var(--line);
  background: repeating-linear-gradient(90deg, var(--line) 0 1px, transparent 1px calc(100% / 12));
  opacity: .55;
  pointer-events: none;
}
.hero__meta { position: relative; display: flex; justify-content: space-between; gap: 16px; border-top: 1px solid var(--line); padding-top: 10px; }
.hero__title { position: relative; margin: auto 0 0; padding-top: 56px; font-weight: 400; }
.hero__pre, .hero__post {
  display: block;
  font-family: var(--f-serif);
  font-style: italic;
  font-weight: 300;
  font-size: clamp(1.45rem, 3vw, 3.2rem);
  line-height: 1.02;
  letter-spacing: -.025em;
}
.hero__post { margin-top: .12em; }
.kinetic-wrap { position: relative; display: inline-block; margin-top: 40px; font-size: 18vw; }
.kinetic {
  display: flex;
  font-family: var(--f-display);
  text-transform: uppercase;
  line-height: .8;
  white-space: nowrap;
  overflow: hidden;
  padding: .02em 0 .01em;
}
.k-letter {
  display: inline-block;
  font-variation-settings: 'wdth' 100, 'wght' 700;
  will-change: font-variation-settings;
}
.js .k-letter { transform: translateY(105%); transition: transform 1.15s var(--ease); transition-delay: calc(var(--i) * 45ms + .15s); }
.is-loaded .k-letter { transform: none; }
.k-space { width: .16em; }
.k-word { display: inline-flex; white-space: nowrap; }
@media (max-width: 600px) {
  .kinetic-wrap { display: block; }
  .kinetic { flex-wrap: wrap; line-height: .82; }
  .k-space { flex-basis: 100%; height: 0; width: 0; }
}
.measure {
  position: absolute; left: 0; width: 100%; bottom: 100%;
  min-width: 220px;
  height: 13px; margin-bottom: 12px;
  display: flex; align-items: center; justify-content: center;
  border-inline: 1px solid currentColor;
}
.measure::before { content: ""; position: absolute; left: 0; right: 0; top: 50%; height: 1px; background: currentColor; }
.measure__label { position: relative; padding: 0 10px; background: var(--bg, var(--paper)); white-space: nowrap; }
.measure__label b { font-weight: 600; color: var(--blue); }
[data-theme="blue"] .measure__label b, [data-theme="verm"] .measure__label b { color: inherit; text-decoration: underline; }
.kinetic { touch-action: pan-y; cursor: grab; user-select: none; -webkit-user-select: none; }
.is-pulling .kinetic { cursor: grabbing; }
.measure__pull { color: var(--mut); }
@media (hover: none) { .measure__pull { display: none; } }

.rotator { display: inline-grid; vertical-align: bottom; overflow: hidden; padding-bottom: .14em; margin-bottom: -.14em; color: var(--blue); }
.rotator > span { grid-area: 1 / 1; white-space: nowrap; }
.js .rotator > span { transform: translateY(140%); transition: transform .9s var(--ease); }
.js .rotator > span.is-on { transform: none; }
.js .rotator > span.is-out { transform: translateY(-140%); }
html:not(.js) .rotator > span:not(:first-child) { display: none; }

.hero__foot {
  position: relative;
  display: grid;
  grid-template-columns: repeat(12, 1fr);
  gap: var(--gut);
  align-items: end;
  margin-top: clamp(28px, 5vw, 64px);
}
.hero__lead { grid-column: 1 / 6; margin: 0; max-width: 30ch; font-size: clamp(1.1rem, 1.5vw, 1.4rem); line-height: 1.3; }
.hero__actions { grid-column: 7 / 12; display: flex; flex-wrap: wrap; align-items: center; gap: 18px 30px; }
.hero__scroll { grid-column: 12 / 13; justify-self: end; display: flex; flex-direction: column; align-items: center; gap: 10px; margin: 0; }
.hero__scroll-line { width: 1px; height: 54px; background: var(--line); position: relative; overflow: hidden; }
.hero__scroll-line::after { content: ""; position: absolute; left: 0; top: 0; width: 1px; height: 40%; background: var(--ink); animation: drip 1.8s var(--ease-io) infinite; }
@keyframes drip { from { transform: translateY(-100%); } to { transform: translateY(260%); } }

/* ==========================================================================
   TICKER
   ========================================================================== */
.ticker { position: relative; overflow: hidden; padding: clamp(16px, 2.2vw, 28px) 0; }
.ticker__track { display: flex; width: max-content; will-change: transform; }
.ticker__group {
  display: flex; align-items: center;
  gap: clamp(18px, 2.4vw, 40px);
  padding-right: clamp(18px, 2.4vw, 40px);
  font-size: clamp(2.4rem, 6.4vw, 6.4rem);
  line-height: 1;
  white-space: nowrap;
}
.t-wide { font-family: var(--f-display); font-weight: 820; font-stretch: 150%; text-transform: uppercase; letter-spacing: -.02em; }
.t-narrow { font-family: var(--f-display); font-weight: 300; font-stretch: 50%; text-transform: uppercase; }
.t-serif { font-family: var(--f-serif); font-style: italic; font-weight: 300; letter-spacing: -.02em; }
.t-mark { width: .4em; height: .4em; flex: none; fill: none; stroke: var(--verm); stroke-width: 1.6; }

/* ==========================================================================
   I. MANIFESTO
   ========================================================================== */
.manifesto__body { display: grid; grid-template-columns: repeat(12, 1fr); gap: var(--gut); }
.manifesto__text {
  grid-column: 1 / 10;
  margin: 0;
  font-size: clamp(1.45rem, 2.7vw, 2.7rem);
  font-weight: 350;
  line-height: 1.08;
  letter-spacing: -.018em;
}
.manifesto__text em { font-style: italic; }
.mw { color: rgba(15, 15, 14, .16); transition: color .5s; }
.mw.on { color: var(--ink); }
.manifesto__text em .mw.on { color: var(--blue); }
.note { grid-column: 10 / 13; align-self: end; border-top: 1px solid var(--line); padding-top: 14px; font-size: 1.02rem; }
.note p { margin: 10px 0 0; }
.note__label { color: var(--verm); }
.note__arrow { width: 120px; height: 60px; margin-top: 16px; fill: none; stroke: var(--blue); stroke-width: 1.4; transform: scaleX(-1); }
.note__arrow path { stroke-dasharray: 260; stroke-dashoffset: 260; transition: stroke-dashoffset 1.6s var(--ease) .3s; }
.note.is-in .note__arrow path { stroke-dashoffset: 0; }

.figures { display: grid; grid-template-columns: repeat(3, 1fr); margin: clamp(28px, 3.6vw, 56px) 0 0; border-top: 1px solid var(--line); }
.figures > div { padding: 16px 0 0 18px; border-left: 1px solid var(--line); }
.figures > div:first-child { border-left: 0; padding-left: 0; }
.figures dt {
  font-family: var(--f-display);
  font-weight: 800;
  font-size: clamp(2.8rem, 6vw, 6rem);
  line-height: .82;
  letter-spacing: -.04em;
  font-variation-settings: 'wdth' var(--fw, 60), 'wght' 800;
  transition: font-variation-settings .8s var(--ease);
}
.figures > div:hover dt { --fw: 140; }
.figures dt small { font-size: .38em; vertical-align: top; letter-spacing: 0; }
.figures dd { margin: 12px 0 0; color: var(--muted); }

/* ==========================================================================
   II. LENTE — caos / ordine
   ========================================================================== */
.lens__stage {
  position: relative;
  width: min(100%, calc(66vh * 16 / 9));
  margin-inline: auto;
  aspect-ratio: 16 / 9;
  overflow: hidden;
  container-type: inline-size;
  border: 1px solid var(--line);
  background:
    radial-gradient(circle at 20% 30%, rgba(0, 0, 0, .04), transparent 60%),
    #D6D0BF;
  touch-action: pan-y;
  user-select: none;
  -webkit-user-select: none;
  --x: 50%; --y: 50%; --r: 0px;
}
.lens__chaos, .lens__order { position: absolute; inset: 0; font-size: 1cqw; }
.lens__order {
  background: var(--paper-3);
  clip-path: circle(var(--r) at var(--x) var(--y));
}
.lens__stage.is-full .lens__order { clip-path: circle(150% at var(--x) var(--y)); transition: clip-path 1s var(--ease-io); }
.lens__ring {
  position: absolute; left: 0; top: 0;
  width: calc(var(--r) * 2); height: calc(var(--r) * 2);
  transform: translate(calc(var(--x) - var(--r)), calc(var(--y) - var(--r)));
  border: 1px solid var(--ink);
  border-radius: 50%;
  pointer-events: none;
}
.lens__ring::before {
  content: ""; position: absolute; inset: -9px; border-radius: 50%;
  background: repeating-conic-gradient(var(--ink) 0 .5deg, transparent .5deg 7.5deg);
  -webkit-mask: radial-gradient(closest-side, transparent calc(100% - 7px), #000 calc(100% - 7px));
          mask: radial-gradient(closest-side, transparent calc(100% - 7px), #000 calc(100% - 7px));
}
.lens__ring span { position: absolute; left: 50%; top: 100%; margin-top: 16px; transform: translateX(-50%); background: var(--ink); color: var(--paper); padding: 4px 7px; white-space: nowrap; }
.lens__stage.is-full .lens__ring { opacity: 0; transition: opacity .3s; }
.lens__tag { position: absolute; z-index: 3; top: 12px; left: 12px; padding: 5px 8px; background: var(--ink); color: var(--paper); pointer-events: none; }
.lens__tag--after { left: auto; right: 12px; background: var(--blue); }
.lens__stage.is-full .lens__tag--before { opacity: 0; }
.lens__hint { width: min(100%, calc(66vh * 16 / 9)); margin-inline: auto !important; display: flex; justify-content: space-between; gap: 16px; flex-wrap: wrap; margin: 14px 0 0; color: var(--muted); }
.lens__hint button { text-transform: inherit; letter-spacing: inherit; color: var(--ink); background: linear-gradient(currentColor, currentColor) 0 100% / 100% 1px no-repeat; padding-bottom: 3px; }

/* Prima: il caos */
.cx { position: absolute; margin: 0; }
.cx-xls { left: 3.5%; top: 7%; width: 46%; background: #fff; border: 1px solid #bdb7a6; box-shadow: 0 .5em 1.4em rgba(0, 0, 0, .14); transform: rotate(-1.6deg); }
.cx-xls__bar { display: flex; align-items: center; gap: .45em; padding: .5em .7em; background: #2F7D4F; color: #fff; font: .78em/1 var(--f-mono); }
.cx-xls__bar i { width: .6em; height: .6em; border-radius: 50%; background: rgba(255, 255, 255, .45); }
.cx-xls__bar span { margin-left: .5em; white-space: nowrap; }
.cx-xls table { width: 100%; border-collapse: collapse; table-layout: fixed; font: .8em/1.15 Arial, Helvetica, sans-serif; color: #333; }
.cx-xls th { width: 2em; background: #EFEFEF; color: #8a8a8a; font-weight: 400; }
.cx-xls tr:first-child th:not(:first-child) { width: auto; }
.cx-xls td, .cx-xls th { border: 1px solid #D6D6D6; padding: .4em .5em; height: 2.1em; white-space: nowrap; overflow: hidden; text-overflow: clip; }
.cx-xls .y { background: #FFF2A0; }
.cx-xls .r { color: #C81E1E; font-weight: 700; }
.cx-chat { left: 56%; top: 6%; width: 34%; display: flex; flex-direction: column; gap: .55em; transform: rotate(1.4deg); }
.b { align-self: flex-start; max-width: 86%; margin: 0; padding: .55em .85em .4em; background: #fff; border-radius: .2em .9em .9em .9em; font: 1.05em/1.3 system-ui, 'Segoe UI', sans-serif; color: #222; box-shadow: 0 .2em .6em rgba(0, 0, 0, .09); }
.b time { display: block; margin-top: .15em; text-align: right; font-size: .7em; color: #999; }
.b--me { align-self: flex-end; background: #DCF5C9; border-radius: .9em .2em .9em .9em; }
.cx-postit { left: 37%; top: 57%; width: 15%; aspect-ratio: 1; padding: 1em; background: #FFE45C; color: #222; transform: rotate(5deg); font: 700 1.3em/1.1 'Segoe Print', 'Bradley Hand', 'Comic Sans MS', cursive; box-shadow: .3em .5em 1em rgba(0, 0, 0, .15); }
.cx-postit small { display: block; margin-top: .6em; font-size: .62em; font-weight: 400; }
.cx-mail { left: 60%; top: 66%; width: 29%; display: flex; justify-content: space-between; gap: 1em; padding: .9em 1.1em; background: #fff; border-left: .3em solid #E5402A; font: 1.05em system-ui, 'Segoe UI', sans-serif; transform: rotate(-1deg); box-shadow: 0 .3em .9em rgba(0, 0, 0, .1); }
.cx-mail span { color: #E5402A; font-weight: 700; white-space: nowrap; }
.cx-folders { left: 5%; top: 73%; display: flex; gap: 1.6em; }
.cx-folders span { position: relative; width: 6.4em; padding-top: 3.4em; text-align: center; font: .85em/1.2 system-ui, sans-serif; color: #333; }
.cx-folders span::before { content: ""; position: absolute; top: 0; left: 50%; width: 4.4em; height: 3.1em; margin-left: -2.2em; background: #E8C266; border-radius: .2em; box-shadow: inset 0 .55em 0 #D4AA48; }
.cx-stain { left: 45%; top: 13%; width: 10%; aspect-ratio: 1; border-radius: 50%; border: .55em solid rgba(110, 66, 28, .2); transform: scale(1, .93) rotate(20deg); }
.cx-scrawl { left: 63%; top: 43%; font: italic 300 2.4em/.95 var(--f-serif); color: #3A2A20; transform: rotate(-6deg); }

/* Dopo: l'ordine */
.ox {
  position: absolute; inset: 5% 4%;
  display: grid; grid-template-columns: 14% 1fr;
  background: #fff;
  border: 1px solid #D9D4C7;
  box-shadow: 0 1em 3em rgba(15, 15, 14, .12);
  font-family: var(--f-display); font-stretch: 92%;
  color: var(--ink);
}
.ox small { display: block; font: .68em/1.3 var(--f-mono); text-transform: uppercase; letter-spacing: .04em; color: var(--muted); }
.ox-side { display: flex; flex-direction: column; gap: 1em; padding: 1.5em 1.3em; background: var(--ink); color: var(--paper); font-size: .95em; }
.ox-side b { margin-bottom: 1em; font-weight: 800; font-stretch: 130%; text-transform: uppercase; }
.ox-side b i { font-family: var(--f-serif); font-weight: 300; text-transform: none; }
.ox-side span { opacity: .55; }
.ox-side .on { opacity: 1; border-left: 2px solid var(--blue); padding-left: .6em; margin-left: -.8em; }
.ox-main { display: flex; flex-direction: column; gap: 1.4em; padding: 1.6em 2em; min-width: 0; }
.ox-head { display: flex; justify-content: space-between; align-items: flex-end; }
.ox-head h4 { margin: .15em 0 0; font: italic 300 2.5em/1 var(--f-serif); letter-spacing: -.02em; }
.ox-btn { display: inline-block; padding: .65em 1.1em; background: var(--blue); color: #fff; font-size: .9em; font-weight: 650; }
.ox-kpis { display: grid; grid-template-columns: repeat(4, 1fr); border-top: 1px solid var(--line); border-left: 1px solid var(--line); }
.ox-kpis div { padding: .8em 1em; border-right: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.ox-kpis b { display: block; margin-top: .1em; font-size: 2.5em; line-height: 1; font-weight: 750; font-stretch: 115%; }
.ox-kpis .v { color: var(--verm); }
.ox-row { flex: 1; min-height: 0; display: grid; grid-template-columns: 1.35fr 1fr; gap: 1.4em; }
.ox-chart, .ox-list { display: flex; flex-direction: column; padding: 1em; border: 1px solid var(--line); min-height: 0; }
.ox-bars { flex: 1; display: flex; align-items: flex-end; gap: .55em; margin-top: .8em; border-bottom: 1px solid var(--ink); min-height: 4em; }
.ox-bars i { flex: 1; height: var(--h); background: #D4D3FF; }
.ox-bars .now { background: var(--blue); }
.ox-list { gap: .55em; }
.ox-list p { display: flex; justify-content: space-between; gap: .6em; margin: 0; padding-bottom: .45em; border-bottom: 1px solid var(--line); font-size: 1.05em; }
.ox-list em { font: normal .72em var(--f-mono); color: var(--verm); white-space: nowrap; }
.ox-btn--full { margin-top: auto; text-align: center; }

@container (max-width: 640px) {
  .lens__chaos, .lens__order { font-size: 2.35cqw; }
  .cx-xls { left: 4%; top: 4%; width: 84%; }
  .cx-chat { left: 26%; top: 37%; width: 70%; }
  .cx-postit { left: 5%; top: 58%; width: 34%; }
  .cx-mail { left: 40%; top: 83%; width: 56%; }
  .cx-folders, .cx-scrawl { display: none; }
  .cx-stain { left: 66%; top: 26%; width: 26%; }
  .ox { inset: 3%; grid-template-columns: 1fr; }
  .ox-side { display: none; }
  .ox-main { padding: 1.2em; gap: 1em; }
  .ox-kpis { grid-template-columns: 1fr 1fr; }
  .ox-row { grid-template-columns: 1fr; }
  .ox-chart { min-height: 9em; }
}
@media (max-width: 640px) { .lens__stage { aspect-ratio: 3 / 4; } }

/* ==========================================================================
   III. ESPERIMENTI
   ========================================================================== */
.exp__list { list-style: none; margin: 0; padding: 0; border-top: 1px solid var(--ln); }
.exp__row {
  --c: var(--paper);
  position: relative;
  width: 100%;
  display: grid;
  grid-template-columns: 4rem 1fr auto 3rem;
  align-items: center;
  gap: var(--gut);
  padding: clamp(10px, 1.2vw, 18px) 0;
  border-bottom: 1px solid var(--ln);
  text-align: left;
  transition: opacity .45s var(--ease);
}
.exp__row::after {
  content: ""; position: absolute; left: 0; right: 0; bottom: -1px; height: 1px;
  background: var(--c); transform: scaleX(0); transform-origin: left;
  transition: transform .7s var(--ease);
}
.exp__list:hover .exp__row:not(:hover) { opacity: .32; }
.exp__row:hover::after, .exp__row:focus-visible::after { transform: scaleX(1); }
.exp__n { color: var(--muted-ink); }
.exp__title {
  font-family: var(--f-display);
  font-size: clamp(1.45rem, 2.9vw, 3rem);
  line-height: .98;
  text-transform: uppercase;
  letter-spacing: -.01em;
  font-variation-settings: 'wdth' 55, 'wght' 420;
  transition: font-variation-settings .7s var(--ease), color .4s;
}
.exp__row:hover .exp__title, .exp__row:focus-visible .exp__title { font-variation-settings: 'wdth' 88, 'wght' 760; color: var(--c); }
.exp__field { color: var(--muted-ink); text-align: right; }
.exp__go { justify-self: end; font-family: var(--f-display); font-weight: 200; font-size: 2.2rem; line-height: 1; transition: transform .6s var(--ease), color .4s; }
.exp__row:hover .exp__go { transform: rotate(90deg); color: var(--c); }
.exp__more { display: grid; grid-template-columns: 12rem 1fr; gap: var(--gut); max-width: 64em; margin: 26px 0 0; color: var(--muted-ink); font-size: 1.12rem; }
.exp__more .mono { padding-top: .45em; }
.exp__more a { color: var(--paper); font-style: italic; }

.exp__preview {
  position: fixed; left: 0; top: 0;
  z-index: 30;
  width: clamp(240px, 22vw, 340px);
  aspect-ratio: 4 / 5;
  pointer-events: none;
  opacity: 0;
  transition: opacity .35s var(--ease);
  will-change: transform;
}
.exp__preview.is-on { opacity: 1; }
.plate {
  position: absolute; inset: 0;
  display: flex; flex-direction: column; justify-content: space-between; gap: 10px;
  padding: 16px;
  background: var(--c); color: var(--cf);
  clip-path: inset(100% 0 0 0);
  transition: clip-path .65s var(--ease-io);
}
.plate.is-on { clip-path: inset(0 0 0 0); }
.plate.is-gone { clip-path: inset(0 0 100% 0); }
.plate__top { display: flex; justify-content: space-between; }
.plate__sym { font-family: var(--f-display); font-weight: 800; font-stretch: 125%; font-size: 6.4rem; line-height: .78; letter-spacing: -.03em; }
.plate__motif { width: 100%; height: auto; overflow: visible; fill: none; stroke: currentColor; stroke-width: 1.4; }
.plate__cap { margin: 0; font: italic 300 1.15rem/1.15 var(--f-serif); }

/* Animazioni dei motivi */
.m-cell { opacity: .15; animation: mcell 2.4s var(--ease) infinite; animation-delay: calc(var(--d) * 120ms); fill: currentColor; stroke: none; }
@keyframes mcell { 0%, 15% { opacity: .15; } 35%, 80% { opacity: 1; } 100% { opacity: .15; } }
.m-draw { stroke-dasharray: 400; stroke-dashoffset: 400; animation: mdraw 3s var(--ease) infinite; }
@keyframes mdraw { 0% { stroke-dashoffset: 400; } 60%, 85% { stroke-dashoffset: 0; } 100% { stroke-dashoffset: -400; } }
.m-blink { animation: mblink 1.4s steps(2) infinite; }
@keyframes mblink { 50% { opacity: 0; } }
.m-slide { animation: mslide 3s var(--ease) infinite; animation-delay: calc(var(--d) * 200ms); }
@keyframes mslide { 0% { transform: translateX(-12px); opacity: 0; } 25%, 85% { transform: none; opacity: 1; } 100% { opacity: 0; } }

/* ---------- Fascicolo (dialog) ---------- */
.dossier {
  position: fixed; inset: 0;
  width: 100%; height: 100%;
  max-width: none; max-height: none;
  margin: 0; padding: 0; border: 0;
  background: var(--paper); color: var(--ink);
  overflow: auto; overscroll-behavior: contain;
}
.dossier::backdrop { background: rgba(15, 15, 14, .55); }
.dossier[open] { animation: dossier-in .85s var(--ease-io) both; }
.dossier.is-closing { animation: dossier-out .55s var(--ease-io) both; }
@keyframes dossier-in { from { clip-path: inset(100% 0 0 0); } to { clip-path: inset(0); } }
@keyframes dossier-out { from { clip-path: inset(0); } to { clip-path: inset(0 0 100% 0); } }
.dossier__bar {
  position: sticky; top: 0; z-index: 3;
  display: flex; justify-content: space-between; align-items: center; gap: 16px;
  padding: 12px var(--pad);
  background: var(--paper);
  border-bottom: 1px solid var(--line);
}
.dossier__bar .muted { color: var(--muted); }
.dossier__close { flex: none; border: 1px solid currentColor; padding: 9px 13px; white-space: nowrap; }
.dossier__close:hover { background: var(--ink); color: var(--paper); }
.dossier__body { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); min-height: calc(100% - 52px); }
.dossier__text { display: flex; flex-direction: column; gap: 22px; padding: clamp(24px, 4vw, 56px) var(--pad); border-right: 1px solid var(--line); }
.dossier__sym { font-family: var(--f-display); font-weight: 820; font-stretch: 125%; font-size: clamp(3.2rem, 5.6vw, 5.6rem); line-height: .78; letter-spacing: -.04em; color: var(--ct); margin: 0; }
.dossier__title { margin: 0; font-family: var(--f-display); font-weight: 760; font-stretch: 70%; font-size: clamp(1.8rem, 3vw, 3rem); line-height: .92; text-transform: uppercase; letter-spacing: -.02em; }
.dossier__client { margin: 0; font-style: italic; color: var(--muted); font-size: 1.15rem; }
.dossier__dl { display: grid; gap: 16px; margin: 0; }
.dossier__dl dt { color: var(--verm); }
.dossier__dl dd { margin: 4px 0 0; font-size: 1.12rem; }
.dossier__tags { display: flex; flex-wrap: wrap; gap: 6px; margin: 0; padding: 0; list-style: none; }
.dossier__tags li { border: 1px solid var(--line); padding: 6px 8px; }
.dossier__nav { display: flex; justify-content: space-between; gap: 12px; margin-top: auto; padding-top: 16px; border-top: 1px solid var(--line); }
.dossier__nav button { text-align: left; }
.dossier__nav button:last-child { text-align: right; }
.dossier__nav button:hover { color: var(--blue); }
.dossier__demo { position: relative; display: flex; flex-direction: column; gap: 16px; padding: clamp(18px, 3vw, 44px); background: var(--c); color: var(--cf); }
.demo-label { display: flex; justify-content: space-between; gap: 12px; }
.demo {
  flex: 1;
  padding: clamp(16px, 2.4vw, 30px);
  background: var(--paper-3); color: var(--ink);
  border: 1px solid var(--ink);
  box-shadow: 10px 10px 0 var(--ink);
  font-family: var(--f-display); font-stretch: 95%;
  min-width: 0;
}
.demo .mono { font-family: var(--f-mono); }

/* Componenti comuni delle demo */
.d-head { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; flex-wrap: wrap; padding-bottom: 10px; margin-bottom: 16px; border-bottom: 1px solid var(--line); }
.d-title { font-weight: 720; font-stretch: 88%; font-size: 1.35rem; text-transform: uppercase; letter-spacing: -.01em; }
.d-muted { color: var(--muted); }
.d-btn {
  display: inline-flex; align-items: center; gap: 10px;
  padding: 12px 16px;
  background: var(--ink); color: var(--paper);
  border: 1px solid var(--ink);
  font-family: var(--f-display); font-weight: 650; font-stretch: 112%;
  font-size: .76rem; letter-spacing: .03em; text-transform: uppercase;
  transition: background .25s, color .25s, border-color .25s;
}
.d-btn:hover { background: var(--blue); border-color: var(--blue); }
.d-btn--ghost { background: transparent; color: var(--ink); }
.d-btn--ghost:hover { color: var(--paper); }
.d-btn[disabled] { opacity: .4; pointer-events: none; }
.d-num { font-weight: 800; font-stretch: 118%; letter-spacing: -.02em; }
.d-row { display: flex; flex-wrap: wrap; align-items: center; gap: 10px 16px; }
.flash { animation: flash .6s ease-out; }
@keyframes flash { from { background: var(--ochre); } }
@keyframes rowin { from { opacity: 0; transform: translateY(8px); } }

/* Range in stile strumento */
.range { -webkit-appearance: none; appearance: none; width: 100%; height: 22px; background: transparent; }
.range::-webkit-slider-runnable-track { height: 1px; background: var(--ink); }
.range::-moz-range-track { height: 1px; background: var(--ink); }
.range::-webkit-slider-thumb { -webkit-appearance: none; width: 14px; height: 22px; margin-top: -11px; background: var(--blue); border: 0; }
.range::-moz-range-thumb { width: 14px; height: 22px; background: var(--blue); border: 0; border-radius: 0; }

/* Demo 01 — eventi */
.ev-grid { display: grid; grid-template-columns: minmax(7.5em, 1.2fr) repeat(3, 1fr); border-top: 1px solid var(--line); border-left: 1px solid var(--line); }
.ev-grid > * { padding: 10px; border-right: 1px solid var(--line); border-bottom: 1px solid var(--line); min-width: 0; }
.ev-grid .mono { color: var(--muted); }
.ev-hotel { font-weight: 650; font-size: .95rem; display: flex; flex-direction: column; justify-content: center; }
.ev-cell { display: flex; flex-direction: column; gap: 6px; text-align: left; transition: background .2s; }
.ev-cell:hover { background: rgba(46, 43, 255, .07); }
.ev-cell b { font-weight: 800; font-stretch: 115%; font-size: 1.35rem; line-height: 1; }
.ev-bar { height: 4px; background: var(--line); }
.ev-bar i { display: block; height: 100%; width: var(--p); background: var(--blue); transition: width .45s var(--ease), background .3s; }
.ev-cell.is-full .ev-bar i { background: var(--verm); }
.ev-foot { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; margin-top: 16px; }
.ev-stat { padding: 12px; border: 1px solid var(--line); display: flex; flex-direction: column; gap: 6px; }
.ev-stat .d-num { font-size: 2rem; line-height: 1; }
.ev-stat .d-btn { align-self: flex-start; margin-top: 4px; }

/* Demo 02 — scadenze */
.sc-ctrl { display: grid; gap: 4px; }
.sc-ctrl label { display: flex; justify-content: space-between; }
.sc-ctrl b { color: var(--blue); }
.sc-list { list-style: none; margin: 12px 0 0; padding: 0; border-top: 1px solid var(--line); max-height: 290px; overflow: auto; }
.sc-list li { display: grid; grid-template-columns: 1fr 3.6em 4.8em; align-items: center; gap: 8px; padding: 9px 0; border-bottom: 1px solid var(--line); animation: rowin .35s var(--ease) both; }
.sc-name { font-weight: 600; }
.sc-days { text-align: right; }
.sc-urgent { color: var(--verm); }
.sc-list li.sc-empty { display: block; }
.sc-empty { padding: 16px 0; color: var(--muted); font-family: var(--f-serif); font-style: italic; }
.sc-foot { display: flex; justify-content: space-between; align-items: center; gap: 12px; flex-wrap: wrap; margin-top: 14px; }
.sc-mail { margin-top: 16px; padding: 14px 16px; background: #fff; border: 1px solid var(--ink); font-family: var(--f-serif); font-stretch: 100%; animation: rowin .45s var(--ease) both; }
.sc-mail header { display: grid; gap: 2px; padding-bottom: 8px; margin-bottom: 8px; border-bottom: 1px solid var(--line); }
.sc-mail p { margin: 0 0 6px; }
.sc-mail ul { margin: 0; padding-left: 1.1em; }

/* Demo 03 — chiusura del mese */
.ms-file { display: flex; align-items: center; gap: 14px; padding: 12px; border: 1px dashed var(--muted); }
.ms-pdf { width: 38px; height: 46px; display: grid; place-items: center; background: var(--verm); color: var(--paper); font: 700 .6rem var(--f-mono); clip-path: polygon(0 0, 72% 0, 100% 22%, 100% 100%, 0 100%); }
.ms-file .grow { flex: 1; min-width: 0; }
.ms-table { width: 100%; table-layout: fixed; border-collapse: collapse; margin-top: 12px; font-size: .9rem; font-stretch: 92%; }
.ms-table td:first-child { width: 3.6em; }
.ms-table td:last-child { width: 7.2em; }
.ms-table td { padding: 7px 6px 7px 0; border-bottom: 1px solid var(--line); vertical-align: top; }
.ms-row { animation: rowin .35s var(--ease) both; }
.ms-amt { font-family: var(--f-mono); font-size: .74rem; text-align: right; white-space: nowrap; }
.ms-pos { color: #18794A; }
.ms-cat { font-family: var(--f-mono); font-size: .6rem; text-transform: uppercase; letter-spacing: .04em; color: var(--blue); overflow-wrap: anywhere; }
.ms-row.is-dup { background: rgba(255, 75, 31, .1); }
.ms-row.is-dup .ms-cat { color: var(--verm); }
.ms-sum { display: grid; grid-template-columns: repeat(3, 1fr); margin-top: 14px; border: 1px solid var(--line); }
.ms-sum > div { padding: 10px 12px; border-right: 1px solid var(--line); display: flex; flex-direction: column; gap: 4px; }
.ms-sum > div:last-child { border-right: 0; }
.ms-sum .d-num { font-size: 1.35rem; }
.ms-done { margin: 14px 0 0; font-family: var(--f-serif); font-style: italic; font-size: 1.15rem; animation: rowin .5s var(--ease) both; }
.caret::after { content: "▍"; margin-left: 1px; animation: mblink 1s steps(2) infinite; }

/* Demo 04 — trainer */
.tr-wrap { display: grid; grid-template-columns: minmax(250px, 300px) 1fr; gap: 22px; align-items: start; }
.tr-phone { border: 9px solid var(--ink); border-radius: 30px; background: #fff; padding: 18px 14px 14px; min-height: 470px; display: flex; flex-direction: column; }
.tr-phone header { display: flex; justify-content: space-between; align-items: baseline; padding-bottom: 8px; border-bottom: 1px solid var(--line); }
.tr-app { font-weight: 800; font-stretch: 130%; text-transform: uppercase; }
.tr-day { margin: 10px 0 4px; font-family: var(--f-serif); font-style: italic; font-size: 1.3rem; font-stretch: 100%; }
.tr-ex { padding: 9px 0; border-bottom: 1px solid var(--line); }
.tr-ex-top { display: flex; justify-content: space-between; align-items: center; gap: 8px; }
.tr-name { font-weight: 650; font-size: .92rem; }
.tr-kg { display: flex; align-items: center; gap: 6px; }
.tr-kg button { width: 24px; height: 24px; border: 1px solid var(--ink); font-size: .9rem; line-height: 1; }
.tr-kg button:hover { background: var(--ink); color: var(--paper); }
.tr-kg b { min-width: 4.4em; text-align: center; font-family: var(--f-mono); font-size: .7rem; }
.tr-sets { display: flex; gap: 5px; margin-top: 7px; }
.tr-set { width: 30px; height: 26px; border: 1px solid var(--ink); font: .58rem var(--f-mono); display: grid; place-items: center; transition: background .2s, color .2s; }
.tr-set.is-done { background: var(--ink); color: var(--paper); }
.tr-prog { margin-top: auto; padding-top: 12px; }
.tr-prog-bar { height: 5px; background: var(--line); margin-top: 6px; }
.tr-prog-bar i { display: block; height: 100%; width: var(--p); background: var(--blue); transition: width .4s var(--ease); }
.tr-chart { border: 1px solid var(--line); padding: 14px; }
.tr-chart svg { width: 100%; max-width: 520px; height: auto; overflow: visible; }
.tr-chart .grid { stroke: var(--line); }
.tr-chart polyline { fill: none; stroke: var(--ink); stroke-width: 2; }
.tr-chart circle { fill: var(--paper-3); stroke: var(--ink); stroke-width: 1.5; }
.tr-chart circle.now { fill: var(--verm); stroke: var(--verm); }
.tr-chart text { font: 10px var(--f-mono); fill: var(--muted); }
.tr-note { margin: 12px 0 0; font-family: var(--f-serif); font-style: italic; font-stretch: 100%; }

/* Demo 05 — porcini */
.pc-wrap { display: grid; grid-template-columns: 1fr minmax(200px, 15em); gap: 18px; }
.pc-grid { display: grid; grid-template-columns: repeat(16, 1fr); gap: 2px; align-content: start; }
.pc-cell { aspect-ratio: 1; background: var(--cc, #ECE7DA); transition: background .45s; position: relative; }
.pc-cell:hover, .pc-cell.is-sel { outline: 2px solid var(--ink); outline-offset: -1px; z-index: 1; }
.pc-panel { display: flex; flex-direction: column; gap: 12px; }
.pc-idx { font-size: 3.4rem; line-height: .85; }
.pc-factors { display: grid; gap: 6px; }
.pc-f { display: grid; grid-template-columns: 8.2em 1fr; align-items: center; gap: 8px; }
.pc-f i { display: block; height: 4px; background: var(--line); position: relative; }
.pc-f i::after { content: ""; position: absolute; inset: 0; width: var(--p); background: var(--forest); transition: width .4s var(--ease); }
.pc-legend { display: flex; align-items: center; gap: 8px; margin-top: 10px; }
.pc-legend i { flex: 1; height: 6px; background: linear-gradient(90deg, #ECE7DA, #E3B23C, #1F3D2C); }
.pc-warn { margin: 0; font-family: var(--f-serif); font-style: italic; font-stretch: 100%; font-size: .95rem; color: var(--muted); }

/* Demo 06 — siti */
.st-browser { border: 1px solid var(--ink); background: #fff; }
.st-url { display: flex; align-items: center; gap: 10px; padding: 8px 12px; border-bottom: 1px solid var(--ink); background: var(--paper-2); }
.st-url span { flex: 1; padding: 4px 10px; background: #fff; border: 1px solid var(--line); }
.st-site { padding: 22px; display: grid; gap: 16px; }
.st-brand { display: flex; justify-content: space-between; align-items: baseline; }
.st-brand b { font-family: var(--f-serif); font-style: italic; font-weight: 400; font-size: 1.5rem; font-stretch: 100%; }
.st-steps { display: flex; gap: 6px; }
.st-steps i { width: 28px; height: 3px; background: var(--line); }
.st-steps i.on { background: var(--ink); }
.st-q { margin: 0; font-weight: 700; font-stretch: 85%; font-size: 1.6rem; line-height: 1.05; text-transform: uppercase; }
.st-opts { display: flex; flex-wrap: wrap; gap: 8px; }
.st-opt { padding: 12px 16px; border: 1px solid var(--ink); font-weight: 550; transition: background .2s, color .2s; }
.st-opt:hover { background: var(--ink); color: var(--paper); }
.st-msg { justify-self: start; max-width: 32em; padding: 12px 14px 8px; background: #DCF5C9; border-radius: 2px 14px 14px 14px; font-family: system-ui, 'Segoe UI', sans-serif; font-stretch: 100%; animation: rowin .45s var(--ease) both; }
.st-msg small { display: block; text-align: right; color: #789; font-size: .7rem; margin-top: 4px; }

/* ==========================================================================
   IV. PER CHI — la frase da completare
   ========================================================================== */
.who__kicker { margin: 0 0 22px; color: var(--muted); }
.who__sentence { font-size: clamp(1.65rem, 3.7vw, 3.8rem); font-weight: 300; line-height: 1.06; letter-spacing: -.022em; max-width: 15.5em; }
.who__line { margin: 0; }
.slot {
  display: inline;
  text-align: left;
  font: inherit;
  font-family: var(--f-display);
  font-weight: 720;
  font-stretch: 76%;
  letter-spacing: -.025em;
  color: var(--blue);
  background: linear-gradient(currentColor, currentColor) 0 96% / 100% .06em no-repeat;
  -webkit-box-decoration-break: clone;
          box-decoration-break: clone;
  cursor: pointer;
  transition: color .3s;
}
.slot:hover { color: var(--verm); }
.slot--pain { font-family: var(--f-serif); font-style: italic; font-weight: 400; font-stretch: 100%; letter-spacing: -.02em; color: var(--ink); background: repeating-linear-gradient(90deg, currentColor 0 .14em, transparent .14em .28em) 0 96% / 100% .05em no-repeat; }
.who__answer { display: grid; grid-template-columns: 12rem 1fr; gap: var(--gut); margin-top: clamp(22px, 2.8vw, 40px); padding-top: 16px; border-top: 1px solid var(--line); }
.who__answer .mono { color: var(--verm); padding-top: .55em; }
.who__answer p { margin: 0; max-width: 30ch; font-size: clamp(1.35rem, 2.3vw, 2.1rem); line-height: 1.18; font-style: italic; transition: opacity .3s; }
.who__answer p.is-swap { opacity: 0; }
.who__controls { display: flex; align-items: center; flex-wrap: wrap; gap: 14px 18px; margin-top: 28px; }
.who__controls button { width: 46px; height: 46px; display: grid; place-items: center; border: 1px solid var(--ink); font-size: 1rem; transition: background .25s, color .25s; }
.who__controls button:hover { background: var(--ink); color: var(--paper); }
.who__other { margin-left: auto; }

/* ==========================================================================
   V. SCHEDA TECNICA
   ========================================================================== */
.spec { margin: 0; border-top: 1px solid var(--ln); }
.spec__row {
  display: grid;
  grid-template-columns: 14rem 1fr 15rem;
  align-items: center;
  gap: var(--gut);
  padding: 14px 0;
  border-bottom: 1px solid var(--ln);
  transition: background .35s, padding .5s var(--ease);
}
.spec__row:hover { background: var(--ink-2); padding-inline: 14px; }
.spec__row dt { color: var(--muted-ink); transition: color .3s; }
.spec__row:hover dt { color: var(--verm); }
.spec__row dd { margin: 0; font-size: clamp(1.05rem, 1.35vw, 1.3rem); line-height: 1.25; }
.spec__live { justify-self: end; display: inline-flex; align-items: center; gap: 10px; color: var(--paper); }
.otp { font-family: var(--f-display); font-weight: 700; font-stretch: 118%; font-size: 1.45rem; letter-spacing: .05em; }
.otp__ring { width: 20px; height: 20px; transform: rotate(-90deg); }
.otp__ring circle { fill: none; stroke: var(--paper); stroke-width: 2; stroke-dasharray: 50.27; animation: otp 30s linear infinite; animation-delay: var(--otp-delay, 0s); }
@keyframes otp { from { stroke-dashoffset: 0; } to { stroke-dashoffset: 50.27; } }
.signal { display: inline-flex; align-items: flex-end; gap: 2px; height: 14px; }
.signal i { width: 3px; background: var(--paper); transition: opacity .3s; }
.signal i:nth-child(1) { height: 25%; } .signal i:nth-child(2) { height: 50%; } .signal i:nth-child(3) { height: 75%; } .signal i:nth-child(4) { height: 100%; }
.signal.is-off i { opacity: .18; }
.flow { gap: 8px; }
.flow__line { position: relative; display: inline-block; width: 64px; height: 1px; background: var(--line-ink); }
.flow__line b { position: absolute; top: -2px; left: 0; width: 5px; height: 5px; background: var(--verm); animation: flow 1.8s var(--ease-io) infinite; }
@keyframes flow { from { left: 0; } to { left: calc(100% - 5px); } }
.flat { width: 80px; height: 16px; }
.flat path { fill: none; stroke: var(--paper); stroke-width: 1.4; }

/* ==========================================================================
   VI. METODO
   ========================================================================== */
.method__title { margin-bottom: clamp(22px, 3vw, 44px); }
.method__grid { display: grid; grid-template-columns: 5fr 7fr; gap: var(--gut); }
.method__sticky { position: sticky; top: 22vh; display: flex; flex-direction: column; gap: 12px; }
.method__num {
  font-family: var(--f-display);
  font-size: clamp(5.5rem, 13vw, 12rem);
  line-height: .76;
  letter-spacing: -.045em;
  color: var(--blue);
  font-variation-settings: 'wdth' 60, 'wght' 800;
  transition: font-variation-settings .7s var(--ease);
}
.method__num.is-wide { font-variation-settings: 'wdth' 150, 'wght' 300; transition-duration: .25s; }
.method__wrap { position: relative; padding-left: 76px; }
.method__svg { position: absolute; left: 0; top: 0; width: 56px; height: 100%; overflow: visible; }
.method__track { fill: none; stroke: var(--line); stroke-width: 1.4; }
.method__path { fill: none; stroke: var(--blue); stroke-width: 2.4; }
.method__node { fill: var(--paper); stroke: var(--ink); stroke-width: 1.4; transition: fill .4s, stroke .4s; }
.method__node.on { fill: var(--blue); stroke: var(--blue); }
.method__steps { list-style: none; margin: 0; padding: 0; }
.method__steps li { padding: clamp(18px, 3.6vh, 36px) 0; border-bottom: 1px solid var(--line); opacity: .3; transition: opacity .6s var(--ease); }
.method__steps li:first-child { padding-top: 0; }
.method__steps li.on { opacity: 1; }
.method__steps .mono { color: var(--verm); }
.method__steps h3 { margin: .25em 0 .3em; font-family: var(--f-display); font-weight: 760; font-stretch: 72%; font-size: clamp(1.6rem, 2.8vw, 2.7rem); line-height: .95; text-transform: uppercase; letter-spacing: -.02em; }
.method__steps p { margin: 0; max-width: 34ch; font-size: clamp(1.1rem, 1.5vw, 1.35rem); }

/* ==========================================================================
   VII. FORMULA
   ========================================================================== */
.formula__lab { display: grid; grid-template-columns: 1fr 1fr; gap: var(--gut); }
.ptable-wrap { display: flex; flex-direction: column; gap: 12px; }
.ptable { display: grid; grid-template-columns: repeat(6, 1fr); gap: 1px; background: var(--ln); border: 1px solid var(--ln); }
.el {
  position: relative;
  display: grid; grid-template-rows: auto 1fr auto;
  aspect-ratio: 1 / 1;
  padding: 10px;
  background: var(--ink);
  text-align: left;
  transition: background .35s, color .35s;
}
.el::after { content: ""; position: absolute; left: 0; top: 0; right: 0; height: 3px; background: var(--g); transition: height .35s var(--ease); }
.el__n { font: .6rem var(--f-mono); color: var(--muted-ink); }
.el__s {
  align-self: center;
  font-family: var(--f-display);
  font-size: clamp(1.4rem, 2.3vw, 2.3rem);
  line-height: 1;
  letter-spacing: -.02em;
  font-variation-settings: 'wdth' 85, 'wght' 700;
  transition: font-variation-settings .5s var(--ease);
}
.el__name { font: .56rem/1.25 var(--f-mono); text-transform: uppercase; letter-spacing: .04em; color: var(--muted-ink); }
.el:hover .el__s { font-variation-settings: 'wdth' 145, 'wght' 860; }
.el[aria-pressed="true"] { background: var(--g); color: var(--gf); }
.el[aria-pressed="true"]::after { height: 0; }
.el[aria-pressed="true"] .el__n, .el[aria-pressed="true"] .el__name { color: var(--gf); }
.ptable-legend { display: flex; flex-wrap: wrap; gap: 8px 18px; color: var(--muted-ink); }
.ptable-legend span { display: inline-flex; align-items: center; gap: 7px; }
.ptable-legend i { width: 10px; height: 10px; background: var(--g); }
.molecule {
  position: relative;
  min-height: 320px;
  border: 1px solid var(--ln);
  background: radial-gradient(var(--line-ink) 1px, transparent 1.2px) 0 0 / 22px 22px;
  overflow: hidden;
  touch-action: pan-y;
}
.molecule__svg { position: absolute; inset: 0; width: 100%; height: 100%; }
.molecule__empty { position: absolute; inset: 0; display: grid; place-content: center; gap: 10px; margin: 0; text-align: center; font: italic 300 1.7rem/1.1 var(--f-serif); color: var(--muted-ink); pointer-events: none; transition: opacity .4s; }
.molecule__empty .mono { font-style: normal; }
.molecule__empty.is-hidden { opacity: 0; }
.molecule__corner { position: absolute; top: 10px; left: 12px; color: var(--muted-ink); }
.bond { stroke: var(--paper); stroke-opacity: .55; stroke-width: 1.5; }
.atom { cursor: grab; touch-action: none; }
.atom:active { cursor: grabbing; }
.atom__body { stroke: var(--paper); stroke-width: 0; }
.atom__orbit { fill: none; stroke: var(--paper); stroke-opacity: .28; stroke-width: 1; }
.atom__e { fill: var(--paper); }
.atom__spin { animation: spin var(--sp, 6s) linear infinite; transform-box: view-box; }
@keyframes spin { to { transform: rotate(360deg); } }
.atom__sym { font-family: var(--f-display); font-weight: 760; font-stretch: 110%; text-anchor: middle; dominant-baseline: central; pointer-events: none; }
.atom__n { font-family: var(--f-mono); font-size: 8px; text-anchor: middle; pointer-events: none; }
.atom__pop { animation: pop .6s var(--ease) both; transform-box: fill-box; transform-origin: center; }
@keyframes pop { from { transform: scale(0); } }
.formula__out { display: grid; grid-template-columns: 1fr 2fr auto; align-items: end; gap: var(--gut); margin-top: var(--gut); padding-top: 18px; border-top: 1px solid var(--ln); }
.formula__out .mono { color: var(--muted-ink); }
.formula__code { margin: .2em 0 0; font-family: var(--f-display); font-weight: 800; font-stretch: 118%; font-size: clamp(1.6rem, 2.6vw, 2.4rem); line-height: 1; letter-spacing: -.02em; word-break: break-word; }
.formula__name { margin: .4em 0 0; max-width: 38ch; font-size: clamp(1.1rem, 1.6vw, 1.5rem); line-height: 1.25; }
.formula__cta { display: flex; flex-direction: column; align-items: flex-start; gap: 14px; }

/* ==========================================================================
   VIII. CONTATTI
   ========================================================================== */
.contact { padding-bottom: var(--pad); overflow: hidden; }
.contact__title { margin: 0; font-family: var(--f-display); font-weight: 800; font-stretch: 78%; font-size: clamp(2.2rem, 5.6vw, 5.8rem); line-height: .86; letter-spacing: -.035em; text-transform: uppercase; }
.contact__title em { display: block; }
.contact__links { display: flex; flex-wrap: wrap; align-items: baseline; gap: 14px 30px; margin-top: clamp(18px, 2.6vw, 32px); }
.contact__mail {
  font: italic 300 clamp(1.5rem, 3vw, 2.9rem)/1.05 var(--f-serif);
  letter-spacing: -.02em;
  text-decoration: none;
  background: linear-gradient(currentColor, currentColor) 0 100% / 100% 1px no-repeat;
  padding-bottom: .06em;
  transition: background-size .6s var(--ease);
  word-break: break-all;
}
.contact__mail:hover { background-size: 0 1px; background-position: 100% 100%; }
.contact__note { flex-basis: 100%; margin: 0; color: var(--mut); }
.physics {
  position: relative;
  height: clamp(220px, 34vh, 340px);
  margin-top: clamp(14px, 2vw, 28px);
  display: flex; align-items: flex-end; justify-content: center; flex-wrap: wrap;
  gap: .04em;
  border-bottom: 1px solid var(--ln);
  overflow: hidden;
  font-size: clamp(50px, 8.6vw, 132px);
  user-select: none; -webkit-user-select: none;
}
.ph { font-family: var(--f-display); font-weight: 820; font-stretch: 115%; line-height: .8; text-transform: uppercase; color: var(--paper); white-space: nowrap; }
.ph--tile { align-self: flex-end; padding: .3em .32em .26em; font-size: .3em; font-stretch: 100%; line-height: 1; color: var(--blue); background: var(--paper); text-transform: none; }
.physics.is-live .ph { position: absolute; left: 0; top: 0; cursor: grab; touch-action: none; will-change: transform; }
.physics.is-live .ph:active { cursor: grabbing; }
.physics__hint { margin: 8px 0 0; text-align: right; color: var(--mut); }
.contact__foot { display: flex; justify-content: space-between; flex-wrap: wrap; gap: 12px 20px; margin-top: 28px; padding-top: 14px; border-top: 1px solid var(--ln); }
.contact__foot a { text-decoration: none; }

/* ==========================================================================
   PAGINE DEDICATE
   ========================================================================== */
.page-head { position: relative; min-height: 70svh; display: flex; flex-direction: column; padding: calc(var(--nav-h) + 12px) var(--pad) var(--pad); overflow: hidden; }
.page-head__back { position: relative; z-index: 3; align-self: flex-start; margin-top: 22px; padding: 6px 0; text-decoration: none; background: linear-gradient(currentColor, currentColor) 0 100% / 0 1px no-repeat; transition: background-size .45s var(--ease); }
.page-head__back:hover { background-size: 100% 1px; }
.page-head__title { position: relative; margin: auto 0 0; padding-top: 36px; font-weight: 400; }
.page-head__title .kinetic-wrap { margin-top: 0; }
.page-head__foot { position: relative; display: flex; justify-content: space-between; align-items: flex-end; gap: 24px; margin-top: clamp(22px, 4vw, 48px); }
.page-head__foot .hero__lead { max-width: 32ch; }
.page-head .hero__scroll-line::after { background: currentColor; }
.page-head--badge .page-head__title { max-width: 64%; }

.next-room { padding: clamp(30px, 4vw, 60px) var(--pad); border-top: 1px solid var(--ln); overflow: hidden; }
.next-room a { display: grid; grid-template-columns: 1fr auto; align-items: end; gap: 10px 24px; text-decoration: none; }
.next-room .mono { grid-column: 1 / -1; color: var(--mut); }
.next-room__name {
  font-family: var(--f-display);
  font-size: clamp(2.2rem, 6vw, 6rem);
  line-height: .84;
  letter-spacing: -.03em;
  text-transform: uppercase;
  white-space: nowrap;
  font-variation-settings: 'wdth' 52, 'wght' 300;
  transition: font-variation-settings .9s var(--ease), color .4s;
}
.next-room a:hover .next-room__name, .next-room a:focus-visible .next-room__name { font-variation-settings: 'wdth' 100, 'wght' 860; color: var(--c); }
.next-room__arr { font-family: var(--f-serif); font-size: clamp(2.2rem, 5vw, 5rem); line-height: .8; transition: transform .7s var(--ease); }
.next-room a:hover .next-room__arr { transform: translateX(12px) rotate(-45deg); }

/* ---------- Tesserino appeso ---------- */
.badge-rig { position: absolute; top: 0; right: clamp(24px, 11vw, 190px); z-index: 2; width: clamp(160px, 13vw, 210px); transform-origin: 50% 0; touch-action: none; }
.badge-rig__cord { position: relative; display: block; width: 18px; height: clamp(78px, 13vh, 140px); margin: 0 auto; background: var(--ink); overflow: hidden; }
.badge-rig__cord::before { content: "SKILL LAB · SKILL LAB · SKILL LAB · SKILL LAB · SKILL LAB"; position: absolute; left: 50%; top: 4px; transform: translateX(-50%); writing-mode: vertical-rl; font: 600 8px/1 var(--f-mono); letter-spacing: .25em; color: var(--paper); white-space: nowrap; }
.badge {
  position: relative;
  display: grid; gap: 10px;
  margin-top: -4px;
  padding: 24px 16px 16px;
  background: var(--paper-3); color: var(--ink);
  border: 1px solid var(--ink);
  box-shadow: 9px 11px 0 rgba(15, 15, 14, .85);
  transform: perspective(700px) rotateY(var(--ry, 0deg));
  user-select: none; -webkit-user-select: none;
  cursor: grab;
  overflow: hidden;
}
.is-held .badge { cursor: grabbing; }
.badge__clip { position: absolute; top: 7px; left: 50%; width: 34px; height: 8px; margin-left: -17px; border-radius: 4px; background: var(--ink); }
.badge__top { display: flex; justify-content: space-between; padding: 6px 0 8px; border-bottom: 1px solid var(--line); }
.badge__photo { position: relative; aspect-ratio: 1 / 1; display: grid; place-items: center; overflow: hidden; background: var(--blue); color: var(--paper); }
.badge__photo span { font-family: var(--f-display); font-weight: 850; font-stretch: 150%; font-size: clamp(3rem, 5vw, 5.4rem); line-height: .8; }
.badge__photo img { width: 100%; height: 100%; object-fit: cover; filter: grayscale(1) contrast(1.1); }
.badge__name { font-family: var(--f-display); font-weight: 780; font-stretch: 80%; font-size: clamp(1.25rem, 1.7vw, 1.75rem); line-height: .9; text-transform: uppercase; }
.badge__role { color: var(--muted); }
.badge__row { display: flex; justify-content: space-between; gap: 8px; padding-top: 8px; border-top: 1px solid var(--line); }
.badge__row b { color: var(--verm); font-weight: 600; text-align: right; }
.badge__bar { height: 28px; background: repeating-linear-gradient(90deg, var(--ink) 0 2px, transparent 2px 4px, var(--ink) 4px 5px, transparent 5px 8px, var(--ink) 8px 11px, transparent 11px 12px, var(--ink) 12px 13px, transparent 13px 17px); }
.badge__holo { position: absolute; inset: 0; pointer-events: none; mix-blend-mode: multiply; background: linear-gradient(115deg, transparent 30%, rgba(46, 43, 255, .2) 42%, rgba(255, 75, 31, .2) 50%, rgba(227, 178, 60, .24) 58%, transparent 70%) var(--holo, 50%) 0 / 260% 100% no-repeat; }

/* ---------- Il banco delle provette ---------- */
.bench { overflow: hidden; }
.bench__rack { position: relative; display: grid; grid-template-columns: repeat(4, 1fr); gap: var(--gut); padding-top: 34px; }
.bench__rack::before { content: ""; position: absolute; left: 0; right: 0; top: 34px; height: 12px; border-block: 1px solid var(--ln); background: repeating-linear-gradient(90deg, var(--line-ink) 0 1px, transparent 1px 24px); }
.tube { position: relative; display: flex; flex-direction: column; align-items: center; text-decoration: none; color: inherit; }
.tube__num { position: absolute; top: -26px; left: 0; color: var(--muted-ink); }
.tube__svg { width: clamp(54px, 4.4vw, 80px); height: auto; overflow: visible; transform-origin: 50% 4%; will-change: transform; }
.tube__glass { fill: none; stroke: var(--paper); stroke-width: 2.2; stroke-linecap: round; stroke-linejoin: round; }
.tube__shine { fill: none; stroke: #fff; stroke-opacity: .2; stroke-width: 4; stroke-linecap: round; }
.tube__liquid { fill: var(--c); }
.tube__foam { fill: none; stroke: #fff; stroke-opacity: .5; stroke-width: 1.4; }
.tube__bubbles circle { fill: rgba(255, 255, 255, .6); }
.tube__ticks line { stroke: var(--paper); stroke-opacity: .45; stroke-width: 1; }
.tube__ticks text { font: 7px var(--f-mono); fill: var(--paper); fill-opacity: .5; text-anchor: end; }
.tube__label { display: flex; flex-direction: column; align-items: center; gap: 6px; max-width: 16rem; margin-top: 14px; text-align: center; }
.tube__name { font-family: var(--f-display); font-size: clamp(1.1rem, 1.6vw, 1.6rem); line-height: .95; text-transform: uppercase; font-variation-settings: 'wdth' 70, 'wght' 700; transition: font-variation-settings .6s var(--ease), color .3s; }
.tube:hover .tube__name, .tube:focus-visible .tube__name { font-variation-settings: 'wdth' 122, 'wght' 860; color: var(--c); }
.tube__teaser { font-style: italic; font-size: .98rem; line-height: 1.25; }
.tube__list { color: var(--muted-ink); }

/* ---------- Inondazione tra le pagine ---------- */
html.flood-in::after { content: ""; position: fixed; inset: 0; z-index: 240; pointer-events: none; background: var(--flood, #0F0F0E); clip-path: circle(150vmax at 50% 50%); }
html.flood-go::after { clip-path: circle(0px at 50% 0%); transition: clip-path .95s var(--ease-io); }
.flood { position: fixed; inset: 0; z-index: 240; pointer-events: none; visibility: hidden; background: var(--fc, #0F0F0E); clip-path: circle(0px at var(--fx, 50%) var(--fy, 50%)); }
.flood.is-on { visibility: visible; clip-path: circle(150vmax at var(--fx, 50%) var(--fy, 50%)); transition: clip-path .68s var(--ease-io); }

/* ---------- Strumenti: caos e suono ---------- */
.nav__tools { display: flex; align-items: center; gap: 6px; }
.tool { display: inline-flex; align-items: center; gap: 7px; padding: 9px 10px; border: 1px solid transparent; text-transform: inherit; letter-spacing: inherit; transition: border-color .3s; }
.tool:hover, .tool[aria-pressed="true"] { border-color: currentColor; }
.tool__dot { width: 8px; height: 8px; border: 1px solid currentColor; border-radius: 50%; transition: background .3s, border-color .3s; }
.tool[aria-pressed="true"] .tool__dot { background: var(--verm); border-color: var(--verm); }
.tool b { font-weight: 600; }
.tool[data-sound-toggle][aria-pressed="true"] b { color: var(--verm); }
.menu__tools { display: flex; gap: 10px; margin-top: 20px; }
.menu__tools .tool { border-color: var(--line-ink); }
.nav__links a[aria-current="page"]:not(.nav__cta)::after { transform: scaleX(1); }
.menu a[aria-current="page"] { color: var(--verm); }

.chaos-banner { position: fixed; left: var(--pad); bottom: var(--pad); z-index: 70; display: flex; align-items: center; flex-wrap: wrap; gap: 12px; max-width: calc(100vw - 2 * var(--pad)); padding: 12px 14px; background: #FFE45C; color: #1a1a1a; box-shadow: 6px 6px 0 var(--ink); rotate: -2deg; animation: wobble 2.4s ease-in-out infinite; }
.chaos-banner[hidden] { display: none; }
.chaos-banner button { border: 1px solid currentColor; padding: 8px 10px; text-transform: inherit; letter-spacing: inherit; }
.chaos-banner button:hover { background: #1a1a1a; color: #FFE45C; }
@keyframes wobble { 50% { rotate: 1.5deg; } }
.chaos-mark { background: #FFE45C !important; color: #1a1a1a !important; box-shadow: .35em .45em 0 rgba(15, 15, 14, .2); }
html.is-chaos main p, html.is-chaos .lead { font-family: 'Comic Sans MS', 'Segoe Print', 'Bradley Hand', cursive !important; }
html.is-chaos .grain { opacity: .22; }
html.is-chaos .cursor__coord::after { content: " · ???"; }

/* ---------- Buretta: quanto hai letto ---------- */
.burette { position: fixed; right: 14px; top: 50%; z-index: 65; display: flex; flex-direction: column; align-items: center; gap: 8px; transform: translateY(-50%); color: #fff; mix-blend-mode: difference; pointer-events: none; font: 400 9px/1 var(--f-mono); letter-spacing: .06em; text-transform: uppercase; }
.burette__glass { position: relative; width: 8px; height: 30vh; overflow: hidden; border: 1px solid currentColor; border-top: 0; border-radius: 0 0 5px 5px; }
.burette__glass::after { content: ""; position: absolute; inset: 0; background: repeating-linear-gradient(180deg, transparent 0 calc(10% - 1px), currentColor calc(10% - 1px) 10%) right / 3px 100% no-repeat; }
.burette__fill { position: absolute; inset: 0; background: currentColor; opacity: .85; transform-origin: bottom; transform: scaleY(0); }
.burette__val::after { content: " ml"; }

/* ---------- Privacy ---------- */
.legal__body { display: grid; grid-template-columns: 12rem minmax(0, 44em); gap: var(--gut); }
.legal__body h2 { margin: 0; padding-top: 4px; font-family: var(--f-display); font-weight: 720; font-stretch: 85%; font-size: 1.05rem; line-height: 1.2; text-transform: uppercase; }
.legal__body section { display: contents; }
.legal__body .legal__text { padding-bottom: 22px; margin-bottom: 4px; border-bottom: 1px solid var(--line); }
.legal__body p, .legal__body li { margin: 0 0 10px; font-size: 1.05rem; line-height: 1.5; }
.legal__body ul { margin: 0; padding-left: 1.1em; }
.legal__body a { color: var(--blue); }
.legal__date { color: var(--muted); margin: 0 0 22px; }

/* ---------- Comparse allo scroll ---------- */
.js [data-reveal] { opacity: 0; transform: translateY(26px); transition: opacity 1s var(--ease), transform 1s var(--ease); }
.js [data-reveal].is-in { opacity: 1; transform: none; }
.w { display: inline-block; overflow: hidden; vertical-align: top; padding: .2em .14em .24em .08em; margin: -.2em -.14em -.24em -.08em; }
.w__i { display: inline-block; }
.js [data-split] .w__i { transform: translateY(112%); transition: transform 1.05s var(--ease); transition-delay: calc(var(--i) * 55ms); }
.js [data-split].is-in .w__i { transform: none; }

/* ==========================================================================
   RESPONSIVE
   ========================================================================== */
@media (max-width: 1320px) {
  .nav__status { display: none; }
  .nav__links { margin-left: auto; }
}
@media (max-width: 960px) {
  .nav__tools { display: none; }
  .burette { display: none; }
}
@media (max-width: 1100px) {
  .spec__row { grid-template-columns: 11rem 1fr; }
  .spec__live { grid-column: 2; justify-self: start; }
  .formula__lab { grid-template-columns: 1fr; }
  .ptable { grid-template-columns: repeat(6, 1fr); }
  .molecule { min-height: 320px; }
  .dossier__body { grid-template-columns: minmax(0, 1fr); }
  .dossier__text { border-right: 0; border-bottom: 1px solid var(--line); }
  .hide-m { display: none; }
}
@media (max-width: 760px) {
  :root { --nav-h: 58px; }
  .nav__links { display: none; }
  .nav__toggle { display: inline-flex; }
  .hide-s { display: none; }
  .sec-head { grid-template-columns: auto 1fr auto; }
  .split-intro { grid-template-columns: 1fr; }
  .split-intro .h2, .split-intro .lead { grid-column: 1 / -1; }
  .hero__title { padding-top: 40px; }
  .hero__foot { display: flex; flex-direction: column; align-items: flex-start; gap: 26px; }
  .hero__scroll { display: none; }
  .manifesto__body { display: block; }
  .note { margin-top: 36px; max-width: 26em; }
  .figures { grid-template-columns: 1fr; }
  .figures > div, .figures > div:first-child { border-left: 0; border-top: 1px solid var(--line); padding: 14px 0 22px; }
  .figures { border-top: 0; }
  .exp__row { grid-template-columns: 2.2rem 1fr 1.6rem; gap: 10px; }
  .exp__field { display: none; }
  .exp__go { font-size: 1.6rem; }
  .exp__more { grid-template-columns: 1fr; gap: 8px; }
  .who__answer { grid-template-columns: 1fr; gap: 8px; }
  .who__other { margin-left: 0; flex-basis: 100%; }
  .legal__body { grid-template-columns: 1fr; gap: 6px; }
  .legal__body .legal__text { margin-bottom: 14px; }
  .spec__row { grid-template-columns: 1fr; gap: 8px; }
  .spec__live { grid-column: auto; }
  .method__grid { grid-template-columns: 1fr; }
  .method__aside { display: none; }
  .method__wrap { padding-left: 52px; }
  .method__svg { width: 40px; }
  .formula__out { grid-template-columns: 1fr; }
  .ptable { grid-template-columns: repeat(4, 1fr); }
  .molecule { min-height: 340px; }
  .ev-foot, .ms-sum { grid-template-columns: 1fr; }
  .ms-sum > div { border-right: 0; border-bottom: 1px solid var(--line); }
  .pc-wrap { grid-template-columns: 1fr; }
  .tr-wrap { grid-template-columns: 1fr; }
  .tr-phone { max-width: 320px; }
  .demo { box-shadow: 6px 6px 0 var(--ink); }
  .dossier__bar .muted { display: none; }
  .bench__rack { grid-template-columns: repeat(4, 1fr); gap: 4px; }
  .tube__svg { width: 50px; }
  .tube__list, .tube__teaser, .tube__num { display: none; }
  .tube__name { font-size: .86rem; font-variation-settings: 'wdth' 58, 'wght' 720; }
  .tube:hover .tube__name { font-variation-settings: 'wdth' 58, 'wght' 860; }
  .page-head--badge .page-head__title { max-width: 100%; }
  .badge-rig { width: 134px; right: 16px; top: var(--nav-h); }
  .badge__top span:last-child { display: none; }
  .badge-rig__cord { height: 70px; width: 14px; }
  .badge { padding: 18px 10px 10px; gap: 6px; box-shadow: 5px 6px 0 rgba(15, 15, 14, .85); }
  .badge__photo span { font-size: 3.6rem; }
  .badge__name { font-size: 1.25rem; }
  .badge__row, .badge__bar, .badge__role { display: none; }
  .next-room__arr { display: none; }
  .measure__pull { display: none; }
  .page-head__foot { flex-direction: column; align-items: flex-start; }
  .hero, .page-head { min-height: 0; }
  .hero .hero__title, .page-head__title { margin-top: 0; padding-top: 64px; }
}
@media (max-width: 520px) {
  .ev-grid { grid-template-columns: 5.6em repeat(3, 1fr); font-size: .9rem; }
  .ev-grid > * { padding: 7px 6px; }
  .ev-cell b { font-size: 1.05rem; font-stretch: 72%; }
  .ev-hotel { font-size: .82rem; }
  .dossier__bar { padding-inline: 16px; }
  .el { padding: 7px; }
  .el__name { font-size: .5rem; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .001ms !important; animation-iteration-count: 1 !important; transition-duration: .001ms !important; transition-delay: 0s !important; }
  .mw { color: var(--ink); }
}
