/* =====================================================================
   AMBIENS — system.css
   Design system "Reality Capture Editorial". Unico foglio di stile del sito.
   Indice: 1 token · 2 base · 3 shell (hud, bar, menu, footer) · 4 componenti
           (sec, runin, row-list, spot-card, filters, cta-block, spec-table,
           reveal) · 5 home
   Regola: dato/label/numero → --mono; frase → --grotesk. I componenti usano
   solo --accent; i tre colori dei verticali vivono nel token e nel menu.
   ===================================================================== */

/* ---------- 1. TOKEN ---------- */
:root {
  --bg: #050505;
  --ink: #f2f2f2;
  --ink-60: rgba(242,242,242,.6);
  --ink-40: rgba(242,242,242,.4);
  --ink-20: rgba(242,242,242,.2);
  --ink-10: rgba(242,242,242,.1);
  --hairline: rgba(242,242,242,.14);
  --surface: #f40ded;
  --system: #ff4715;
  --scan: #00ece6;
  --accent: var(--ink);

  --grotesk: "Geist", system-ui, sans-serif;
  --mono: "Space Mono", monospace;
  --t-display: clamp(64px, 14vw, 240px);
  --t-h1: clamp(40px, 6vw, 96px);
  --t-h2: clamp(32px, 4.5vw, 64px);
  --t-lede: clamp(28px, 3vw, 44px);
  --t-body: 17px;
  --t-label: 10px;

  --frame: 14px;
  --pad-x: clamp(20px, 3.5vw, 56px);
  --s-1: 4px; --s-2: 8px; --s-3: 12px; --s-4: 16px; --s-5: 24px;
  --s-6: 32px; --s-7: 48px; --s-8: 64px; --s-9: 88px; --s-10: 128px; --s-11: 180px;
  --sec-gap: clamp(96px, 14vw, 220px);

  --ease-out-expo: cubic-bezier(.19,1,.22,1);
  --ease-out-quint: cubic-bezier(.23,1,.32,1);
  --d-fast: 200ms; --d: 600ms; --d-slow: 1200ms;
}
@media (min-width: 1280px) { :root { --t-label: 11px; } }
body[data-vertical="surface"] { --accent: var(--surface); }
body[data-vertical="system"]  { --accent: var(--system); }
body[data-vertical="scan"]    { --accent: var(--scan); }

/* ---------- 2. BASE ---------- */
.wrap { max-width: 1440px; width: 100%; margin: 0 auto; padding: 0 var(--pad-x); }
.wrap-narrow { max-width: 65ch; }
.label { font-family: var(--mono); font-size: var(--t-label); letter-spacing: .12em; text-transform: uppercase; color: var(--ink-60); }
.skip-to-content { position: absolute; top: -100%; left: var(--frame); z-index: 300; padding: 12px 16px; min-height: 44px; display: inline-flex; align-items: center;
  font-family: var(--mono); font-size: var(--t-label); letter-spacing: .12em; text-transform: uppercase; color: var(--bg); background: var(--ink); text-decoration: none; transition: top var(--d-fast); }
.skip-to-content:focus { top: var(--frame); }
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0,0,0,0); white-space: nowrap; border: 0; }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; }

* { margin: 0; padding: 0; box-sizing: border-box; }
html:not(.lenis) { scroll-behavior: smooth; }
body {
  background: var(--bg);
  color: var(--ink);
  font-family: var(--grotesk);
  font-weight: 300;
  overflow-x: hidden;
}
::selection { background: var(--ink); color: var(--bg); }

/* Lenis (assets/js/lenis.min.js) — CSS raccomandato dalla libreria */
html.lenis, html.lenis body { height: auto; }
.lenis.lenis-smooth { scroll-behavior: auto !important; }
.lenis.lenis-smooth [data-lenis-prevent] { overscroll-behavior: contain; }
.lenis.lenis-stopped { overflow: hidden; }

/* ============ HUD FRAME ============ */
.hud-corner {
  position: fixed; z-index: 90;
  font-family: var(--mono); font-weight: 700;
  font-size: 20px; line-height: 1;
  color: var(--accent); pointer-events: none; user-select: none;
}
.hud-a { top: var(--frame); left: var(--frame); }
.hud-m { top: var(--frame); right: var(--frame); transform: scaleX(-1); }
.hud-b { bottom: var(--frame); left: var(--frame); }
.hud-s { bottom: var(--frame); right: var(--frame); transform: scaleY(-1); }
.hud-cross {
  position: fixed; z-index: 90; color: var(--ink-60);
  font-family: var(--mono); font-size: 11px;
  pointer-events: none; user-select: none;
}
.hud-cross.c1 { top: var(--frame); left: 25vw; }
.hud-cross.c2 { top: var(--frame); right: 25vw; }
.hud-cross.c3 { bottom: var(--frame); left: 25vw; }
.hud-cross.c4 { bottom: var(--frame); right: 25vw; }

/* top bar */
.bar {
  position: fixed; top: 10px; left: 50%; transform: translateX(-50%);
  z-index: 210;
  display: flex; align-items: center; gap: 40px;
  background: rgba(5,5,5,.72); backdrop-filter: blur(12px);
  padding: 9px 18px;
}
.bar-logo { padding: 11px 0; display: inline-flex; align-items: center; min-height: 44px; }
.bar-logo img { height: 22px; display: block; }
.bar-dots { display: flex; gap: 5px; }
.bar-dots span { width: 4px; height: 4px; display: block; }
.bar-dots .d-surface { background: var(--surface); }
.bar-dots .d-system { background: var(--system); }
.bar-dots .d-scan { background: var(--scan); }
.bar-menu {
  font-family: var(--mono); font-size: 10px; letter-spacing: .12em;
  color: var(--ink); text-decoration: none;
  background: none; border: 0; cursor: pointer; padding: 12px 6px; min-height: 44px;
}
.bar-menu:hover { opacity: .6; }
.bar-right { display: flex; align-items: center; gap: 18px; }
.bar-lang {
  font-family: var(--mono); font-size: 10px; letter-spacing: .12em;
  color: var(--ink-60); text-decoration: none;
  padding: 12px 8px; min-height: 44px; display: inline-flex; align-items: center;
}
.bar-lang:hover { color: var(--ink); }

/* section ruler + margin label */
.sec {
  position: relative;
  border-top: 1px solid var(--hairline);
  padding: clamp(80px, 12vh, 140px) 0;
}
.sec-label {
  position: absolute; top: 10px; left: var(--frame);
  font-family: var(--mono); font-size: 9px; letter-spacing: .14em;
  color: var(--ink-60);
}
.sec-head { text-align: center; margin-bottom: clamp(48px, 8vh, 96px); }
.sec-num {
  display: block;
  font-family: var(--mono); font-size: 13px; letter-spacing: .2em;
  color: var(--ink-60);
  margin-bottom: 8px;
}
.sec-title {
  font-family: var(--grotesk); font-weight: 500;
  font-size: clamp(28px, 4vw, 52px);
  letter-spacing: .04em; text-transform: uppercase;
}

/* ============ HERO (pinned: l'esplosione resta a schermo lungo lo scroll) ============ */
.hero { position: relative; height: 220vh; }
.hero-sticky {
  position: sticky; top: 0;
  height: 100vh; height: 100dvh;
  display: flex; flex-direction: column;
  align-items: center; justify-content: center;
  overflow: hidden;
}
#particle-canvas { position: absolute; inset: 0; width: 100%; height: 100%; }
.hero-inner {
  position: relative; z-index: 2; text-align: center; pointer-events: none;
  will-change: opacity, transform;
}
.hero-title {
  font-family: var(--grotesk); font-weight: 500;
  font-size: clamp(64px, 14vw, 220px);
  letter-spacing: .02em; line-height: .95;
  display: inline-flex;
}
.hero-title .ltr {
  display: inline-block; white-space: pre;
  opacity: 0; filter: blur(20px);
  transform: translateY(.12em) scale(1.18);
}
body.solved .hero-title .ltr {
  opacity: 1; filter: blur(0); transform: none;
  transition: opacity .9s var(--ease-out-expo),
              filter .9s var(--ease-out-expo),
              transform .9s var(--ease-out-expo);
}
.hero-sub {
  font-family: var(--mono);
  font-size: clamp(12px, 1.4vw, 15px); letter-spacing: .1em;
  color: var(--ink-60); margin-top: 24px;
  max-width: 680px; margin-left: auto; margin-right: auto; padding: 0 24px;
}
.hero-verticals {
  display: flex; justify-content: center; gap: clamp(20px, 4.5vw, 56px);
  margin-top: clamp(32px, 6vh, 60px);
  pointer-events: auto;
}
.hero-vertical {
  font-family: var(--mono); font-size: 11px; letter-spacing: .16em;
  color: var(--ink); text-decoration: none;
  display: flex; align-items: center; gap: 8px;
  opacity: .7; transition: opacity .3s;
}
.hero-vertical i { width: 5px; height: 5px; display: block; }
.hero-vertical:hover { opacity: 1; }
.hero-scroll {
  position: absolute; bottom: calc(var(--frame) + 12px); left: 50%; transform: translateX(-50%);
  font-family: var(--mono); font-size: 10px; letter-spacing: .2em;
  color: var(--ink-60); z-index: 2;
  animation: pulse 2.4s ease-in-out infinite;
}
@keyframes pulse { 0%,100% { opacity: .35; } 50% { opacity: .9; } }

/* load-in stagger (sub + verticals) */
.stagger { opacity: 0; filter: blur(14px); transform: translateY(24px); }
body.loaded .stagger {
  opacity: 1; filter: blur(0); transform: none;
  transition: opacity 1.1s var(--ease-out-expo), filter 1.1s var(--ease-out-expo), transform 1.1s var(--ease-out-expo);
}
body.loaded .stagger.s2 { transition-delay: .55s; }
body.loaded .stagger.s3 { transition-delay: .7s; }
body.loaded .stagger.s4 { transition-delay: .85s; }

/* ============ 01 STUDIO ============ */
.ethos { max-width: 1100px; margin: 0 auto; }
.ethos-lede {
  font-family: var(--grotesk); font-weight: 300;
  font-size: clamp(26px, 3.8vw, 48px); line-height: 1.22;
  letter-spacing: -.01em;
}
/* .ethos-body layout (label column + testo) è definito in ".runin-block", sez. 5. HOME */

/* ============ CINE (particle text) ============ */
.cine {
  text-align: center;
  padding: clamp(90px, 18vh, 200px) 20px;
  overflow: hidden;
}
.cine .w1 {
  display: block;
  font-family: var(--grotesk); font-weight: 500;
  font-size: clamp(48px, 11vw, 175px); line-height: .98;
  letter-spacing: -.01em;
}
.cine-pt {
  display: block; width: 100%;
  height: clamp(100px, 16vw, 250px);
  margin-top: clamp(4px, 1vw, 12px);
}

/* ============ SCROLL REVEALS ============ */
/* Senza JS (niente html.js) tutto resta visibile: la classe .reveal da sola non nasconde nulla. */
html.js .reveal:not(.in) { opacity: 0; filter: blur(12px); transform: translateY(30px); }
.reveal.in {
  opacity: 1; filter: blur(0); transform: none;
  transition: opacity 1s var(--ease-out-expo), filter 1s var(--ease-out-expo), transform 1s var(--ease-out-expo);
}

/* ---------- 3. SHELL ---------- */
.bar-dots .dim { opacity: .3; }
.bar-active-dot { width: 6px; height: 6px; background: var(--ink); display: inline-block; }
.bar-active-dot[hidden] { display: none; }
@media (max-width: 480px) { .hud-corner { font-size: 14px; } .hud-a, .hud-m { top: 64px; } .bar { gap: 20px; padding: 8px 14px; } .bar-lang { display: none; } }


.menu { position: fixed; inset: 0; z-index: 200; }
.menu-backdrop { position: absolute; inset: 0; background: rgba(5,5,5,.6); backdrop-filter: blur(6px); }
.menu-panel { position: absolute; top: 76px; left: 50%; transform: translateX(-50%); width: min(560px, calc(100vw - 2*var(--frame)));
  background: rgba(5,5,5,.92); border: 1px solid var(--hairline); padding: var(--s-4); }
.menu-list { list-style: none; margin: 0; padding: 0; }
.menu-list a { position: relative; display: grid; grid-template-columns: 40px 1fr auto; align-items: center; gap: var(--s-4);
  padding: 14px var(--s-4); min-height: 48px; color: var(--ink); text-decoration: none; border-bottom: 1px solid var(--hairline); }
.menu-list a::before { content: ""; position: absolute; inset: 0; background: var(--ink); opacity: 0; transition: opacity var(--d-fast); z-index: -1; }
.menu-list a:hover::before, .menu-list a:focus-visible::before { opacity: .08; }
.menu-list a[data-vertical="surface"]:hover::before { background: var(--surface); opacity: .18; }
.menu-list a[data-vertical="system"]:hover::before  { background: var(--system);  opacity: .18; }
.menu-list a[data-vertical="scan"]:hover::before    { background: var(--scan);    opacity: .18; }
.menu-n { font-family: var(--mono); font-size: var(--t-label); color: var(--ink-60); }
.menu-label { font-family: var(--grotesk); font-weight: 400; font-size: 18px; letter-spacing: .04em; }
.menu-dot { width: 8px; height: 8px; display: block; }
a[data-vertical="surface"] .menu-dot { background: var(--surface); } a[data-vertical="system"] .menu-dot { background: var(--system); } a[data-vertical="scan"] .menu-dot { background: var(--scan); }
.menu-foot { display: flex; justify-content: space-between; flex-wrap: wrap; gap: var(--s-3); padding: var(--s-4); font-family: var(--mono); font-size: var(--t-label); letter-spacing: .12em; color: var(--ink-60); }
.menu-foot a { color: inherit; text-decoration: none; padding: 12px 4px; min-height: 44px; display: inline-flex; align-items: center; } .menu-foot a:hover, .menu-foot a[aria-current="true"] { color: var(--ink); }
.menu-dots { display: block; width: 100%; height: 72px; color: var(--ink-40); }
.menu-close { position: absolute; top: var(--s-3); right: var(--s-3); background: none; border: 0; color: var(--ink-60); font-family: var(--mono); font-size: var(--t-label); letter-spacing: .12em; cursor: pointer; padding: 10px; min-height: 44px; }
html.menu-open { overflow: hidden; }

.site-footer { display: grid; grid-template-columns: repeat(3, 1fr); gap: var(--s-6); padding: var(--s-9) var(--pad-x) var(--s-8); border-top: 1px solid var(--hairline); }
.site-footer h4 { font-family: var(--mono); font-size: var(--t-label); letter-spacing: .12em; color: var(--ink-60); margin: 0 0 var(--s-4); text-align: center; }
.site-footer .f-col a { display: flex; align-items: center; justify-content: center; text-align: center; padding: 14px 0; min-height: 44px; border-top: 1px solid var(--hairline); font-family: var(--mono); font-size: 11px; letter-spacing: .12em; color: var(--ink); text-decoration: none; }
.site-footer .f-col a:hover { color: var(--accent); }
.f-colophon { grid-column: 1 / -1; display: flex; justify-content: space-between; flex-wrap: wrap; gap: var(--s-3); margin-top: var(--s-7); font-family: var(--mono); font-size: 10px; letter-spacing: .1em; color: var(--ink-60); }
.f-colophon a { color: inherit; text-decoration: none; padding: 4px 0; min-height: 44px; display: inline-flex; align-items: center; } .f-colophon a:hover { color: var(--ink); }
@media (max-width: 720px) { .site-footer { grid-template-columns: 1fr; } }

/* ---------- 4. COMPONENTI ---------- */
/* row-list: righe full-bleed, hover tinta --accent (index progetti, foundations, articoli) */
.row-list { list-style: none; margin: 0; padding: 0; border-top: 1px solid var(--hairline); }
.row { position: relative; display: grid; grid-template-columns: minmax(0,1.6fr) minmax(0,1fr) auto auto; gap: var(--s-5); align-items: center;
  padding: var(--s-5) var(--pad-x); border-bottom: 1px solid var(--hairline); color: var(--ink); text-decoration: none; min-height: 44px; }
.row::before { content: ""; position: absolute; inset: 0; background: var(--accent); opacity: 0; transition: opacity var(--d-fast) var(--ease-out-expo); z-index: -1; }
.row:hover::before, .row:focus-visible::before { opacity: .12; }
.row-title { font-family: var(--grotesk); font-weight: 400; font-size: clamp(18px, 1.6vw, 24px); }
.row-meta { font-family: var(--mono); font-size: var(--t-label); letter-spacing: .12em; text-transform: uppercase; color: var(--ink-60); }
.row-arrow { font-family: var(--mono); color: var(--ink-40); transition: transform var(--d-fast) var(--ease-out-expo); }
.row:hover .row-arrow { transform: translateX(6px); color: var(--ink); }
@media (max-width: 720px) { .row { grid-template-columns: 1fr auto auto; } .row-meta.optional { display: none; } }

/* spot-card: immagine B/N → colore in hover */
.spot-card { display: block; color: var(--ink); text-decoration: none; }
.spot-card figure { margin: 0; aspect-ratio: 16/10; overflow: hidden; background: #0b0b0b; }
.spot-card img { width: 100%; height: 100%; object-fit: cover; display: block; filter: grayscale(1); transform: scale(1.02);
  transition: filter var(--d) var(--ease-out-expo), transform var(--d) var(--ease-out-expo); }
.spot-card:hover img, .spot-card:focus-visible img { filter: grayscale(0); transform: scale(1); }
.spot-card .label { display: block; margin: var(--s-3) 0 var(--s-1); }
.spot-card h3 { font-family: var(--grotesk); font-weight: 400; font-size: clamp(18px, 1.5vw, 22px); margin: 0; }

/* filters: tab mono */
.filters { display: flex; flex-wrap: wrap; gap: var(--s-2) var(--s-4); padding: 0 var(--pad-x) var(--s-5); }
.filter { font-family: var(--mono); font-size: var(--t-label); letter-spacing: .12em; text-transform: uppercase; color: var(--ink-60);
  background: none; border: 1px solid transparent; padding: 12px 14px; min-height: 44px; cursor: pointer; }
.filter[aria-pressed="true"] { color: var(--ink); border-color: var(--hairline); }
.filter[data-vertical="surface"][aria-pressed="true"] { color: var(--surface); }
.filter[data-vertical="system"][aria-pressed="true"]  { color: var(--system); }
.filter[data-vertical="scan"][aria-pressed="true"]    { color: var(--scan); }
.filters--sectors .filter { font-size: 10px; padding: 8px 10px; min-height: 44px; }

/* cta-block: statement + bottone (pre-footer) */
.cta-block { position: relative; padding: var(--sec-gap) var(--pad-x); text-align: center; }
.cta-block .cta-line { font-family: var(--grotesk); font-weight: 300; font-size: var(--t-h1); line-height: .95; letter-spacing: -.02em; margin: 0 0 var(--s-5); }
.cta-block .cta-line .soft { color: var(--ink-40); }
.cta-block .cta-sub { font-family: var(--mono); font-size: var(--t-label); letter-spacing: .12em; text-transform: uppercase; color: var(--ink-60); margin: 0 0 var(--s-7); }
.cta-block .cta-btn, .nf-links .cta-btn { display: inline-block; font-family: var(--mono); font-size: 12px; letter-spacing: .12em; padding: 18px 32px; background: var(--ink); color: var(--bg); text-decoration: none; min-height: 44px; }
.cta-block .cta-btn:hover, .nf-links .cta-btn:hover { background: var(--accent); color: var(--bg); }
.cta-direct { margin-top: var(--s-6); display: flex; gap: var(--s-6); justify-content: center; flex-wrap: wrap; }
.cta-direct a { font-family: var(--mono); font-size: 12px; letter-spacing: .08em; color: var(--ink-60); text-decoration: none; padding: 10px 0; min-height: 44px; display: inline-flex; align-items: center; }
.cta-direct a:hover { color: var(--ink); }

/* spec-table: scheda tecnica mono a due colonne */
.spec-table { display: grid; grid-template-columns: max-content 1fr; gap: var(--s-2) var(--s-6); font-family: var(--mono); font-size: 12px; letter-spacing: .04em; }
.spec-table dt { color: var(--ink-60); text-transform: uppercase; font-size: var(--t-label); letter-spacing: .12em; }
.spec-table dd { margin: 0; color: var(--ink); }
@media (max-width: 480px) { .spec-table { grid-template-columns: 1fr; gap: var(--s-1) var(--s-6); } .spec-table dt { margin-top: var(--s-3); } .spec-table dt:first-child { margin-top: 0; } }

/* numbers strip */
.numbers { display: flex; flex-wrap: wrap; gap: var(--s-6) var(--s-9); padding: var(--s-8) var(--pad-x); border-top: 1px solid var(--hairline); border-bottom: 1px solid var(--hairline); }
.numbers b { display: block; font-family: var(--mono); font-weight: 400; font-size: clamp(40px, 5vw, 72px); line-height: 1; color: var(--ink); }
.numbers span { display: block; margin-top: var(--s-2); font-family: var(--mono); font-size: var(--t-label); letter-spacing: .12em; text-transform: uppercase; color: var(--ink-60); }

/* pointcloud host */
.pointcloud-host { position: relative; } .pointcloud-host canvas { display: block; width: 100%; height: 100%; }

/* ---------- 5. HOME ---------- */
.hero-data { position: absolute; bottom: calc(var(--frame) + 52px); left: var(--pad-x); right: var(--pad-x); text-align: center; font-family: var(--mono); font-size: var(--t-label); letter-spacing: .12em; color: var(--ink-60); margin: 0; }
@media (max-width: 720px) { .hero-data { display: none; } }

.sub-label { font-family: var(--mono); font-size: var(--t-label); letter-spacing: .12em; color: var(--ink-60); margin: var(--s-8) var(--pad-x) var(--s-5); }
.spotlight { display: grid; grid-template-columns: repeat(3, 1fr); gap: var(--s-5); padding: 0 var(--pad-x); }
.spotlight .spot-card .label { color: var(--accent); }
@media (max-width: 900px) { .spotlight { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 720px) { .spotlight { display: flex; overflow-x: auto; scroll-snap-type: x mandatory; gap: var(--s-4); padding-bottom: var(--s-3); scroll-padding-inline: var(--pad-x); -webkit-overflow-scrolling: touch; }
  .spotlight .spot-card { flex: 0 0 78vw; scroll-snap-align: start; } }
.index-group { margin-top: var(--s-7); }
.index-head { display: flex; justify-content: space-between; align-items: baseline; padding: 0 var(--pad-x) var(--s-3); margin: 0; }
.index-head a { display: inline-flex; align-items: center; gap: var(--s-3); font-family: var(--grotesk); font-weight: 500; font-size: var(--t-h2); letter-spacing: -.01em; color: var(--ink); text-decoration: none; }
.index-head a:hover { color: var(--accent); }
.index-dot { width: 12px; height: 12px; background: var(--accent); display: inline-block; }
.index-count { font-family: var(--mono); font-size: var(--t-label); letter-spacing: .12em; color: var(--ink-60); }
[data-group][hidden], [data-row][hidden] { display: none; }

.writing-lead { display: grid; grid-template-columns: 1fr 1fr; gap: var(--s-5); padding: 0 var(--pad-x); }
.writing-lead figure canvas { width: 100%; height: 100%; color: var(--ink); }
.writing-ex { margin: var(--s-2) 0 0; font-size: 15px; line-height: 1.5; color: var(--ink-60); }
.writing-all { padding: var(--s-6) var(--pad-x) 0; font-family: var(--mono); font-size: 12px; letter-spacing: .12em; }
.writing-all a { color: var(--ink); text-decoration: none; display: inline-block; padding: 12px 0; min-height: 44px; } .writing-all a:hover { color: var(--accent); }
@media (max-width: 720px) { .writing-lead { grid-template-columns: 1fr; } }

.runin-block { display: grid; grid-template-columns: 96px 1fr; gap: var(--s-5); align-items: start; margin-top: var(--s-6); }
.runin-block .runin { font-family: var(--mono); font-size: var(--t-label); letter-spacing: .12em; color: var(--ink-60); padding-top: .6em; }
.runin-block p { margin: 0 0 var(--s-3); font-size: var(--t-body); line-height: 1.55; color: var(--ink-60); max-width: 65ch; }
.stack-list { margin: var(--s-6) 0 0 calc(96px + var(--s-5)); font-family: var(--mono); font-size: 12px; letter-spacing: .06em; color: var(--ink); line-height: 1.9; }
.clients { padding: var(--s-6) var(--pad-x) 0; font-family: var(--mono); font-size: 12px; letter-spacing: .06em; color: var(--ink-60); line-height: 1.9; }
.clients .label { display: block; margin-bottom: var(--s-2); }
@media (max-width: 720px) { .runin-block { grid-template-columns: 1fr; gap: var(--s-2); } .stack-list { margin-left: 0; } }

/* pre-footer: sfera dotfield prima del CTA block */
.prefooter { height: clamp(240px, 40vw, 520px); color: var(--ink-60); }
.prefooter canvas { width: 100%; height: 100%; }

/* ---------- 6. VERTICALE ---------- */
.v-hero { height: 160vh; }
.v-kicker { position: absolute; top: calc(var(--frame) + 64px); left: 50%; transform: translateX(-50%); color: var(--ink-60); margin: 0; }
.v-title .ltr { color: var(--ink); }
.v-hero .hero-sub { color: var(--accent); }
.v-intro p { font-family: var(--grotesk); font-weight: 300; font-size: var(--t-lede); line-height: 1.15; letter-spacing: -.01em; margin: 0; }
.runin-block > div p { margin: 0 0 var(--s-3); font-size: var(--t-body); line-height: 1.55; color: var(--ink-60); max-width: 65ch; }
.row-num { font-family: var(--mono); font-size: var(--t-label); color: var(--ink-60); margin-right: var(--s-4); vertical-align: middle; }
.row-desc { text-transform: none; letter-spacing: 0; font-family: var(--grotesk); font-size: 14px; color: var(--ink-60); }

.live-block { margin-top: var(--s-8); }
.live-block .label { display: block; margin-bottom: var(--s-3); }
.live-embed { position: relative; aspect-ratio: 16 / 9; background: #0b0b0b; border: 1px solid var(--hairline); }
.live-embed iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }
.live-caption { margin: var(--s-3) 0 0; font-family: var(--mono); font-size: var(--t-label); letter-spacing: .12em; text-transform: uppercase; color: var(--ink-60); }

.samples { margin-top: var(--s-8); }
.samples .sub-label { margin-left: 0; margin-right: 0; }
.samples-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: var(--s-5); }
.sample { margin: 0; }
.sample figcaption { margin-top: var(--s-3); }
.sample h4 { font-family: var(--grotesk); font-weight: 400; font-size: 18px; margin: var(--s-1) 0; }
.sample p { margin: 0; font-size: 14px; color: var(--ink-60); }
@media (max-width: 900px) { .samples-grid { grid-template-columns: 1fr; } }

.row-thumb-inline { display: none; }
.row-thumb-cursor { position: fixed; top: 0; left: 0; width: 220px; aspect-ratio: 16/10; object-fit: cover; pointer-events: none; z-index: 220; filter: grayscale(1); border: 1px solid var(--hairline); will-change: transform; }
.row-thumb-cursor[hidden] { display: none; }
@media (hover: none) { .row-list--thumbs .row { grid-template-columns: minmax(0,1.6fr) minmax(0,1fr) auto auto 72px; }
  .row-thumb-inline { display: block; width: 72px; aspect-ratio: 16/10; object-fit: cover; filter: grayscale(1); } }
@media (hover: none) and (max-width: 720px) { .row-list--thumbs .row { grid-template-columns: 1fr auto auto 72px; } }
@media (max-width: 720px) { .v-hero { height: 130vh; } .v-kicker { top: calc(var(--frame) + 56px); font-size: 9px; } }

/* ---------- 7. PROGETTO ---------- */
.p-main { padding-top: calc(var(--s-8) + 10px + var(--s-6)); }
.p-head { padding-top: var(--s-8); padding-bottom: var(--s-7); }
.p-crumbs { display: block; margin-bottom: var(--s-6); }
.p-crumbs a { color: var(--ink-60); text-decoration: none; display: inline-flex; align-items: center; min-height: 44px; padding: 0 2px; }
.p-crumbs a:hover { color: var(--accent); }
.p-title { font-family: var(--grotesk); font-weight: 300; font-size: var(--t-h1); line-height: .98; letter-spacing: -.02em; margin: 0 0 var(--s-5); max-width: 18ch; }
.p-tagline { font-family: var(--grotesk); font-weight: 300; font-size: var(--t-lede); line-height: 1.2; color: var(--ink-60); margin: 0 0 var(--s-7); max-width: 40ch; }
.spec-table dd a { color: var(--ink); text-decoration: underline; text-underline-offset: .18em; text-decoration-color: var(--ink-60); }
.spec-table dd a:hover { text-decoration-color: var(--accent); }
.p-cover { margin: 0; width: 100%; aspect-ratio: 21 / 9; overflow: hidden; background: #0b0b0b; border-top: 1px solid var(--hairline); border-bottom: 1px solid var(--hairline); }
.p-cover img, .p-cover video { width: 100%; height: 100%; object-fit: cover; display: block; filter: grayscale(1); transition: filter var(--d-slow) var(--ease-out-expo); }
.p-cover.in img, .p-cover.in video { filter: grayscale(0); }
.p-live { margin-top: var(--s-8); } .p-live .label { display: block; margin-bottom: var(--s-3); }

.prose-editorial { margin: var(--s-9) auto; padding: 0 var(--pad-x); counter-reset: h2; font-size: var(--t-body); line-height: 1.6; color: var(--ink-60); }
.prose-editorial > * { max-width: 65ch; }
.prose-editorial h2 { position: relative; font-family: var(--grotesk); font-weight: 400; font-size: var(--t-h2); line-height: 1.05; letter-spacing: -.02em; color: var(--ink); margin: var(--s-9) 0 var(--s-5); counter-increment: h2; }
.prose-editorial h2::before { content: counter(h2, decimal-leading-zero); position: absolute; left: -64px; top: .35em; font-family: var(--mono); font-size: var(--t-label); letter-spacing: .12em; color: var(--ink-60); }
.prose-editorial h3 { font-family: var(--grotesk); font-weight: 500; font-size: 20px; color: var(--ink); margin: var(--s-7) 0 var(--s-3); }
.prose-editorial p { margin: 0 0 var(--s-5); }
.prose-editorial strong { color: var(--ink); font-weight: 500; }
.prose-editorial a { color: var(--ink); text-decoration: underline; text-underline-offset: .18em; text-decoration-color: var(--ink-40); }
.prose-editorial a:hover { text-decoration-color: var(--accent); }
.prose-editorial ul, .prose-editorial ol { padding-left: 1.2em; margin: 0 0 var(--s-5); }
.prose-editorial li { margin-bottom: var(--s-2); }
.prose-editorial li::marker { color: var(--accent); }
.prose-editorial blockquote { margin: var(--s-7) 0; padding-left: var(--s-5); border-left: 2px solid var(--accent); font-size: var(--t-lede); line-height: 1.25; color: var(--ink); font-weight: 300; }
.prose-editorial code { font-family: var(--mono); font-size: .9em; color: var(--ink); overflow-wrap: break-word; word-break: break-word; }
.prose-editorial pre { overflow-x: auto; max-width: 100%; font-family: var(--mono); font-size: 13px; line-height: 1.6; padding: var(--s-4); border: 1px solid var(--hairline); background: #0b0b0b; }
.prose-editorial pre code { font-size: inherit; }
.prose-editorial img { display: block; width: 100%; height: auto; filter: grayscale(1); transition: filter var(--d) var(--ease-out-expo); }
.prose-editorial img:hover { filter: none; }
.prose-editorial p > img:only-child { margin: var(--s-7) 0; }
.prose-editorial .gallery { max-width: none; display: grid; grid-template-columns: repeat(12, 1fr); gap: var(--s-4); margin: var(--s-8) calc(-1 * var(--pad-x)); padding: 0 var(--pad-x); }
.prose-editorial .gallery img { margin: 0; aspect-ratio: 16/10; object-fit: cover; }
.prose-editorial .gallery img:nth-child(5n+1), .prose-editorial .gallery img:nth-child(5n+2) { grid-column: span 6; }
.prose-editorial .gallery img:nth-child(5n+3) { grid-column: span 8; }
.prose-editorial .gallery img:nth-child(5n+4) { grid-column: span 4; }
.prose-editorial .gallery img:nth-child(5n+5) { grid-column: span 12; aspect-ratio: 21/9; }
.prose-editorial .contact-form-wrapper { max-width: 65ch; }
@media (max-width: 900px) { .prose-editorial h2::before { position: static; display: block; margin-bottom: var(--s-2); } .prose-editorial .gallery img { grid-column: span 12 !important; } }

.next-project { grid-template-columns: auto 1fr auto auto; margin-top: var(--s-9); border-top: 1px solid var(--hairline); padding-top: var(--s-7); padding-bottom: var(--s-7); }
.next-title { font-family: var(--grotesk); font-weight: 300; font-size: var(--t-h2); letter-spacing: -.02em; line-height: 1; }
@media (max-width: 720px) { .next-project { grid-template-columns: 1fr auto auto; } .next-project .label { grid-column: 1 / -1; } }

/* ---------- 8. FOUNDATION ---------- */
.f-uses .sec-head { padding: 0 var(--pad-x) var(--s-5); }
.f-uses .sec-title { font-size: var(--t-h2); }

/* ---------- 9. TARGET ---------- */
.t-hero { padding-top: var(--s-8); padding-bottom: var(--s-7); }
.t-hero .label { display: block; margin-bottom: var(--s-5); color: var(--ink-60); }
.t-verticals { display: grid; grid-template-columns: repeat(3, 1fr); border-top: 1px solid var(--hairline); border-bottom: 1px solid var(--hairline); }
.t-vertical { position: relative; padding: var(--s-7) var(--pad-x); border-right: 1px solid var(--hairline); display: flex; flex-direction: column; gap: var(--s-4); }
.t-vertical:last-child { border-right: 0; }
.t-vertical::before { content: ""; position: absolute; inset: 0; background: var(--accent); opacity: 0; transition: opacity var(--d-fast) var(--ease-out-expo); z-index: -1; }
.t-vertical:hover::before { opacity: .1; }
.t-vertical-name { display: inline-flex; align-items: center; gap: var(--s-3); font-family: var(--grotesk); font-weight: 500; font-size: var(--t-h2); letter-spacing: -.01em; color: var(--ink); text-decoration: none; min-height: 44px; }
.t-vertical-name i { width: 12px; height: 12px; background: var(--accent); display: inline-block; }
.t-vertical .label { color: var(--ink-60); }
.t-foundations { list-style: none; margin: 0; padding: 0; }
.t-foundations a { display: block; padding: 10px 0; min-height: 44px; font-family: var(--grotesk); font-size: 16px; color: var(--ink); text-decoration: none; border-top: 1px solid var(--hairline); }
.t-foundations a:hover { color: var(--accent); }
.t-count { margin-top: auto; font-family: var(--mono); font-size: var(--t-label); letter-spacing: .12em; color: var(--ink-60); }
@media (max-width: 900px) { .t-verticals { grid-template-columns: 1fr; } .t-vertical { border-right: 0; border-bottom: 1px solid var(--hairline); } .t-vertical:last-child { border-bottom: 0; } }

/* ---------- 10. BLOG ---------- */
.b-head { padding-top: var(--s-8); padding-bottom: var(--s-7); }
.b-head .label { display: block; margin-bottom: var(--s-5); color: var(--ink-60); }
.b-rss { color: var(--ink-60); text-decoration: none; display: inline-flex; align-items: center; min-height: 44px; padding: 0 4px; }
.b-rss:hover { color: var(--accent); }
.b-empty { position: relative; min-height: 320px; display: grid; place-items: center; border-top: 1px solid var(--hairline); border-bottom: 1px solid var(--hairline); }
.b-empty canvas { position: absolute; inset: 0; width: 100%; height: 100%; color: var(--ink-40); }
.b-empty .label { position: relative; color: var(--ink); }
.b-meta, .b-draft { display: block; margin-bottom: var(--s-4); color: var(--ink-60); }
.b-draft { color: var(--accent); }
.b-more { margin-top: var(--s-9); } .b-more .sec-head { padding: 0 var(--pad-x) var(--s-5); } .b-more .sec-title { font-size: var(--t-h2); }
.writing-lead h2 { font-family: var(--grotesk); font-weight: 400; font-size: clamp(18px, 1.5vw, 22px); margin: 0; }

/* ---------- 11. CONTATTI + 404 ---------- */
.c-head { padding-top: var(--s-8); padding-bottom: var(--s-7); }
.c-head .label { display: block; margin-bottom: var(--s-5); color: var(--ink-60); }
.c-grid { display: grid; grid-template-columns: minmax(0, 2fr) minmax(0, 1fr); gap: var(--s-9); align-items: start; }
.c-topics .sub-label { margin: 0 0 var(--s-4); }
.c-topics .row-list { margin: 0 calc(-1 * var(--pad-x)); }
.c-topic { width: 100%; text-align: left; background: none; border: 0; border-bottom: 1px solid var(--hairline); color: var(--ink); cursor: pointer; font: inherit; }
.c-topic .row-title { display: inline-flex; align-items: center; gap: var(--s-3); font-family: var(--mono); font-size: 14px; letter-spacing: .08em; }
.c-topic[aria-pressed="true"]::before { opacity: .18; }
.c-hint { margin: var(--s-3) 0 0; color: var(--ink-60); }
.c-form { margin: var(--s-8) 0 0; padding: 0; }
.c-form > * { max-width: none; }
.contact-form { display: grid; gap: var(--s-5); margin-top: var(--s-6); }
.form-field { display: grid; gap: var(--s-2); }
.form-label { font-family: var(--mono); font-size: var(--t-label); letter-spacing: .12em; text-transform: uppercase; color: var(--ink-60); }
.form-required { color: var(--accent); }
.form-input { width: 100%; background: transparent; border: 0; border-bottom: 1px solid var(--hairline); color: var(--ink); font-family: var(--grotesk); font-size: var(--t-body); padding: 14px 0; min-height: 44px; border-radius: 0; }
.form-input::placeholder { color: var(--ink-40); }
.form-input:focus { outline: none; border-bottom-color: var(--accent); }
.form-textarea { resize: vertical; min-height: 160px; }
.form-submit { justify-self: start; font-family: var(--mono); font-size: 12px; letter-spacing: .12em; padding: 18px 32px; background: var(--ink); color: var(--bg); border: 0; cursor: pointer; min-height: 44px; }
.form-submit:hover { background: var(--accent); }
.form-status { margin-top: var(--s-4); font-family: var(--mono); font-size: 12px; letter-spacing: .06em; color: var(--ink-60); }
.form-status-success { color: var(--accent); }
.form-status-error { color: #ff6b6b; }
.c-direct .spec-table { grid-template-columns: max-content 1fr; }
.c-direct dd a { color: var(--ink); text-decoration: underline; text-underline-offset: .18em; text-decoration-color: var(--ink-60); display: inline-flex; align-items: center; min-height: 44px; padding: 0; }
.c-direct dd a:hover { text-decoration-color: var(--accent); }
@media (max-width: 900px) { .c-grid { grid-template-columns: 1fr; gap: var(--s-7); } }

.nf { position: relative; min-height: 80vh; display: grid; align-items: center; }
.nf-field { position: absolute; inset: 0; z-index: -1; }
.nf-field canvas { width: 100%; height: 100%; color: var(--ink-40); }
.nf-inner { padding-top: var(--s-8); padding-bottom: var(--s-8); }
.nf-inner .label { display: block; margin-bottom: var(--s-4); color: var(--ink-60); }
.nf-links { margin: var(--s-6) 0; }
.nf-or a { color: var(--accent); text-decoration: none; margin-left: var(--s-3); display: inline-flex; align-items: center; min-height: 44px; padding: 12px 0; }

/* reduced motion */
/* ---------- 12. CONSENT + LEGALE ---------- */
.consent { position: fixed; inset: 0; z-index: 400; display: grid; place-items: end center; padding: var(--frame); background: rgba(5,5,5,.55); backdrop-filter: blur(4px); }
.consent[hidden] { display: none; }
.consent-box { width: min(640px, 100%); background: var(--bg); border: 1px solid var(--hairline); padding: var(--s-6); display: grid; gap: var(--s-4); }
.consent-box .label { color: var(--ink-60); }
.consent-title { font-family: var(--grotesk); font-weight: 400; font-size: clamp(22px, 2.4vw, 30px); letter-spacing: -.01em; margin: 0; }
.consent-text { margin: 0; font-size: 15px; line-height: 1.55; color: var(--ink-60); }
.consent-text a { color: var(--ink); text-decoration: underline; text-underline-offset: .18em; text-decoration-color: var(--ink-60); display: inline-block; padding: 8px 0; }
.consent-panel { display: grid; border-top: 1px solid var(--hairline); }
.consent-panel[hidden] { display: none; }
.consent-row { display: grid; grid-template-columns: 1fr auto; gap: var(--s-5); align-items: center; padding: var(--s-4) 0; border-bottom: 1px solid var(--hairline); cursor: pointer; }
.consent-row strong { display: block; font-family: var(--mono); font-weight: 400; font-size: 12px; letter-spacing: .08em; text-transform: uppercase; color: var(--ink); }
.consent-row span { display: block; margin-top: var(--s-1); font-size: 14px; line-height: 1.5; color: var(--ink-60); }
.consent-always { font-family: var(--mono); font-size: var(--t-label); letter-spacing: .12em; color: var(--ink-60); white-space: nowrap; }
.consent-switch { appearance: none; -webkit-appearance: none; width: 44px; height: 24px; border: 1px solid var(--ink-60); background: transparent; position: relative; cursor: pointer; margin: 0; flex: none; }
.consent-switch::after { content: ""; position: absolute; top: 3px; left: 3px; width: 16px; height: 16px; background: var(--ink-60); transition: transform var(--d-fast) var(--ease-out-expo), background var(--d-fast); }
.consent-switch:checked { border-color: var(--ink); }
.consent-switch:checked::after { transform: translateX(20px); background: var(--accent); }
.consent-switch:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; }
.consent-actions { display: flex; flex-wrap: wrap; gap: var(--s-3); }
.consent-btn { font-family: var(--mono); font-size: 11px; letter-spacing: .12em; padding: 14px 20px; min-height: 44px; background: transparent; color: var(--ink); border: 1px solid var(--hairline); cursor: pointer; }
.consent-btn:hover { border-color: var(--ink); }
.consent-btn--primary { background: var(--ink); color: var(--bg); border-color: var(--ink); }
.consent-btn--primary:hover { background: var(--accent); border-color: var(--accent); color: var(--bg); }
.consent[data-mode="customize"] [data-only="banner"], .consent[data-mode="banner"] [data-only="customize"] { display: none; }
@media (max-width: 480px) { .consent-box { padding: var(--s-5); } .consent-actions .consent-btn { flex: 1 1 100%; } }

.consent-placeholder { position: absolute; inset: 0; display: grid; place-content: center; gap: var(--s-3); text-align: center; padding: var(--s-5); background: #0b0b0b; }
.consent-placeholder p { margin: 0; font-size: 14px; color: var(--ink-60); max-width: 36ch; }
.consent-placeholder .label { color: var(--ink-60); }
.consent-placeholder .consent-btn { justify-self: center; }
iframe[data-consent-src] { visibility: hidden; }

.f-legal { display: inline-flex; flex-wrap: wrap; gap: 0 var(--s-2); align-items: center; }
.f-legal a { color: inherit; text-decoration: none; display: inline-flex; align-items: center; min-height: 44px; }
.f-legal a:hover { color: var(--ink); }

.legal-head { padding-top: var(--s-8); padding-bottom: var(--s-6); }
.legal-head .label { display: block; margin-bottom: var(--s-5); color: var(--ink-60); }
.legal-meta { font-family: var(--mono); font-size: var(--t-label); letter-spacing: .12em; color: var(--ink-60); margin: 0 0 var(--s-5); }
.prose-editorial table { width: 100%; border-collapse: collapse; font-size: 14px; margin: var(--s-5) 0; }
.prose-editorial th, .prose-editorial td { text-align: left; padding: var(--s-3) var(--s-2); border-bottom: 1px solid var(--hairline); vertical-align: top; }
.prose-editorial th { font-family: var(--mono); font-weight: 400; font-size: var(--t-label); letter-spacing: .12em; text-transform: uppercase; color: var(--ink-60); }
.legal-prefs { padding: var(--s-6) var(--pad-x); }
.legal-prefs a { font-family: var(--mono); font-size: 12px; letter-spacing: .12em; color: var(--ink); text-decoration: none; display: inline-flex; align-items: center; min-height: 44px; }
.legal-prefs a:hover { color: var(--accent); }

@media (prefers-reduced-motion: reduce) {
  .consent-switch::after { transition: none !important; }
  .reveal { opacity: 1 !important; filter: none !important; transform: none !important; transition: none !important; }
  .spot-card img, .row::before, .row-arrow { transition: none !important; }
  html { scroll-behavior: auto !important; }
  .stagger, .hero-title .ltr { opacity: 1 !important; filter: none !important; transform: none !important; transition: none !important; }
  .hero-scroll { animation: none !important; }
  .row-thumb-cursor { display: none !important; }
  .p-cover img, .p-cover video { filter: grayscale(0) !important; transition: none !important; }
}
