/* BitHub Studio v2 · design system chiaro con glass, profondità 3D e motion.
   Attivo solo sulle pagine con body.bh2: blog, inglese e pagine non migrate restano invariati. */
@font-face { font-family: "Instrument Serif"; src: url("/assets/fonts/instrument-serif-italic.woff2") format("woff2"); font-weight: 400; font-style: italic; font-display: swap; }
@font-face { font-family: "Instrument Serif"; src: url("/assets/fonts/instrument-serif.woff2") format("woff2"); font-weight: 400; font-style: normal; font-display: swap; }

body.bh2 {
  --bh-bg: #f4f2f9; --bh-bg-2: #ece8f6; --bh-ink: #15102a; --bh-ink-2: #2b2545; --bh-muted: #5f5a76; --bh-faint: #8f8aa6;
  --bh-violet: #6416c8; --bh-violet-2: #8b5cf6; --bh-lilac: #cdbdff; --bh-amber: #f2a93b; --bh-peach: #ffd7b8; --bh-lime: #d9f36a; --bh-sky: #bfe3ff;
  --bh-line: rgba(21,16,42,.09); --bh-line-2: rgba(21,16,42,.16);
  --bh-r: 30px; --bh-r-s: 18px; --bh-ease: cubic-bezier(.16,1,.3,1); --bh-ease-io: cubic-bezier(.77,0,.18,1);
  --bh-pad: max(20px, 4vw); --bh-max: 1320px;
  --bh-shadow: 0 1px 2px rgba(30,20,70,.05), 0 14px 32px -14px rgba(50,30,110,.2), 0 46px 90px -42px rgba(80,40,160,.32);
  --bh-shadow-lg: 0 2px 4px rgba(30,20,70,.05), 0 30px 60px -24px rgba(50,30,110,.28), 0 90px 140px -60px rgba(80,40,160,.4);
  background: transparent; color: var(--bh-ink); font-family: "Inter", system-ui, sans-serif; font-size: 17px; font-weight: 400; line-height: 1.5; -webkit-font-smoothing: antialiased; overflow-x: clip;
}
html:has(> body.bh2) { background: #f4f2f9; }
html:has(> body.bh2.bh-dark) { background: #0b0816; }
body.bh2 main { position: relative; overflow-x: clip; }
.bh-gl { position: fixed; inset: 0; z-index: -1; width: 100vw; height: 100vh; pointer-events: none; }
body.bh2 ::selection { background: var(--bh-violet); color: #fff; }
body.bh2 a { color: inherit; }
body.bh2 img { max-width: 100%; }
.bh-wrap { width: min(var(--bh-max), calc(100% - 2 * var(--bh-pad))); margin-inline: auto; }
.bh-sr { position: absolute !important; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

/* Atmosfera: macchie di colore morbide, griglia sottile e grana, fisse dietro la pagina */
.bh-atmo { position: fixed; inset: 0; z-index: -1; pointer-events: none; overflow: hidden; }
.bh-atmo i { position: absolute; width: 60vmax; aspect-ratio: 1; border-radius: 50%; filter: blur(80px); opacity: .55; animation: bh-drift 26s ease-in-out infinite alternate; }
.bh-atmo i:nth-child(1) { left: -18vmax; top: -22vmax; background: radial-gradient(circle, #d9ccff, transparent 65%); }
.bh-atmo i:nth-child(2) { right: -20vmax; top: 18vh; background: radial-gradient(circle, #ffe0c7, transparent 62%); animation-delay: -9s; }
.bh-atmo i:nth-child(3) { left: 20vw; bottom: -34vmax; background: radial-gradient(circle, #cfe8ff, transparent 62%); animation-delay: -17s; }
.bh-atmo::before { content: ""; position: absolute; inset: 0; background-image: linear-gradient(rgba(21,16,42,.035) 1px, transparent 1px), linear-gradient(90deg, rgba(21,16,42,.035) 1px, transparent 1px); background-size: 72px 72px; -webkit-mask-image: radial-gradient(80% 60% at 50% 30%, #000, transparent 85%); mask-image: radial-gradient(80% 60% at 50% 30%, #000, transparent 85%); }
.bh-atmo::after { content: ""; position: absolute; inset: -50%; opacity: .05; 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='2' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url%28%23n%29'/%3E%3C/svg%3E"); }
@keyframes bh-drift { to { transform: translate(6vmax, 5vmax) scale(1.12); } }

/* Tipografia */
.bh-kick { display: inline-flex; align-items: center; gap: 10px; margin: 0 0 18px; color: var(--bh-muted); font-size: 12px; font-weight: 600; letter-spacing: .2em; text-transform: uppercase; }
.bh-kick::before { content: ""; width: 26px; height: 1.5px; background: currentColor; opacity: .6; }
.bh-kick--dot::before { width: 8px; height: 8px; border-radius: 50%; background: var(--bh-violet); opacity: 1; box-shadow: 0 0 0 5px rgba(100,22,200,.14); }
.bh-h1 { margin: 0; font-size: clamp(56px, 9.2vw, 160px); font-weight: 650; line-height: .9; letter-spacing: -.06em; }
.bh-h2 { margin: 0; font-size: clamp(42px, 5.8vw, 96px); font-weight: 620; line-height: .95; letter-spacing: -.05em; }
.bh-h3 { margin: 0; font-size: clamp(24px, 2.2vw, 34px); font-weight: 620; line-height: 1.05; letter-spacing: -.035em; }
.bh-serif, body.bh2 .bh-h1 em, body.bh2 .bh-h2 em, body.bh2 .bh-h3 em { font-family: "Instrument Serif", Georgia, serif; font-style: italic; font-weight: 400; letter-spacing: -.02em; color: var(--bh-violet); }
.bh-lead { max-width: 560px; margin: 0; color: var(--bh-muted); font-size: clamp(17px, 1.3vw, 20px); line-height: 1.55; }
.bh-grad { background: linear-gradient(100deg, var(--bh-violet) 10%, #b35cf0 45%, var(--bh-amber) 90%); -webkit-background-clip: text; background-clip: text; color: transparent; }

/* Pulsanti */
.bh-btn { position: relative; display: inline-flex; align-items: center; gap: 14px; min-height: 58px; padding: 0 10px 0 26px; border: 0; border-radius: 99px; background: linear-gradient(120deg, #6416c8, #7b3ff0 60%, #5b4bd8); color: #fff !important; font-size: 16px; font-weight: 600; text-decoration: none; cursor: pointer; box-shadow: inset 0 1px 0 rgba(255,255,255,.35), 0 14px 30px -10px rgba(100,22,200,.55); overflow: hidden; isolation: isolate; transition: transform .45s var(--bh-ease), box-shadow .45s; }
.bh-btn::before { content: ""; position: absolute; inset: 0; z-index: -1; background: radial-gradient(120px circle at var(--mx, 50%) var(--my, 50%), rgba(255,255,255,.35), transparent 60%); opacity: 0; transition: opacity .3s; }
.bh-btn:hover::before { opacity: 1; }
.bh-btn i { display: grid; place-items: center; width: 40px; height: 40px; border-radius: 50%; background: #f6d64a; color: #15102a; font-style: normal; transition: transform .45s var(--bh-ease); }
.bh-btn:hover i { transform: rotate(-45deg); }
.bh-btn--ghost { padding: 0 24px; background: rgba(255,255,255,.6); color: var(--bh-ink) !important; box-shadow: inset 0 0 0 1px var(--bh-line-2), 0 10px 24px -14px rgba(50,30,110,.3); backdrop-filter: blur(12px); }
.bh-btn--ghost i { width: auto; height: auto; background: none; }
.bh-link { display: inline-flex; align-items: center; gap: 8px; font-weight: 600; text-decoration: none; background: linear-gradient(currentColor, currentColor) no-repeat 0 100% / 0 1.5px; padding-bottom: 3px; transition: background-size .4s var(--bh-ease); }
.bh-link:hover { background-size: 100% 1.5px; }

/* Glass */
.bh-glass { position: relative; border: 1px solid rgba(255,255,255,.8); border-radius: var(--bh-r); background: linear-gradient(150deg, rgba(255,255,255,.78), rgba(255,255,255,.42)); backdrop-filter: blur(22px) saturate(170%); -webkit-backdrop-filter: blur(22px) saturate(170%); box-shadow: inset 0 1px 0 rgba(255,255,255,.95), inset 0 -1px 0 rgba(100,70,190,.08), var(--bh-shadow); }
.bh-glass::before { content: ""; position: absolute; inset: 0; border-radius: inherit; pointer-events: none; background: radial-gradient(420px circle at var(--gx, 20%) var(--gy, 0%), rgba(255,255,255,.75), transparent 45%); mix-blend-mode: soft-light; opacity: .9; }
.bh-glass--dark { border-color: rgba(255,255,255,.14); background: linear-gradient(150deg, rgba(30,22,60,.82), rgba(21,16,42,.7)); color: #f4f1ff; box-shadow: inset 0 1px 0 rgba(255,255,255,.12), var(--bh-shadow-lg); }
.bh-chip { display: inline-flex; align-items: center; gap: 8px; padding: 9px 16px; border: 1px solid rgba(255,255,255,.85); border-radius: 99px; background: rgba(255,255,255,.7); backdrop-filter: blur(14px); box-shadow: 0 10px 24px -12px rgba(50,30,110,.3); font-size: 14px; font-weight: 600; white-space: nowrap; }
.bh-chip b { width: 8px; height: 8px; border-radius: 50%; background: var(--c, var(--bh-violet)); box-shadow: 0 0 0 4px color-mix(in srgb, var(--c, #6416c8) 18%, transparent); }

/* Motion di base (bh.js aggiunge le classi) */
.bh-js [data-bh-split]:not(.bh-split) { visibility: hidden; }
.bh-split .bh-w { display: inline-block; overflow: hidden; vertical-align: top; padding: 0 .08em .1em 0; margin: 0 -.08em -.1em 0; }
.bh-split .bh-c { display: inline-block; transform: translate3d(0, 110%, 0) rotate(5deg); transition: transform 1.15s var(--bh-ease); transition-delay: calc(var(--i) * var(--st, 38ms) + var(--d, 0ms)); }
.bh-split.in .bh-c { transform: none; }
.bh-js [data-bh-reveal] { transition: opacity 1s var(--bh-ease), transform 1.2s var(--bh-ease), filter 1s; transition-delay: var(--d, 0ms); }
.bh-js [data-bh-reveal="up"] { opacity: 0; transform: translateY(60px); }
.bh-js [data-bh-reveal="blur"] { opacity: 0; filter: blur(14px); transform: scale(1.04); }
.bh-js [data-bh-reveal="tilt"] { opacity: 0; transform: perspective(1000px) rotateX(18deg) translateY(80px) scale(.94); transform-origin: 50% 100%; }
.bh-js [data-bh-reveal].in { opacity: 1; transform: none; filter: none; }
[data-bh-tilt] { transform: perspective(1100px) rotateX(var(--rx, 0deg)) rotateY(var(--ry, 0deg)); transform-style: preserve-3d; transition: transform .6s var(--bh-ease); will-change: transform; }
[data-bh-tilt] .z1 { transform: translateZ(30px); } [data-bh-tilt] .z2 { transform: translateZ(60px); } [data-bh-tilt] .z3 { transform: translateZ(90px); }
[data-bh-magnetic] { transition: transform .5s var(--bh-ease); }
[data-bh-marquee] { overflow: hidden; white-space: nowrap; }
.bh-track { display: inline-flex; will-change: transform; }

/* ---------- HOME ---------- */
/* Hero bloccato: le tre parole guidano la scultura di particelle */
.bh-hero { position: relative; height: 330vh; }
.bh-hero-pin { position: sticky; top: 0; display: grid; grid-template-columns: 1.02fr .98fr; align-items: center; gap: 2vw; height: 100vh; min-height: 640px; padding: 110px var(--bh-pad) 40px; max-width: 1560px; margin: 0 auto; }
.bh-hero-copy { position: relative; z-index: 3; }
.bh-hero .bh-h1 { font-size: clamp(64px, 8.6vw, 150px); line-height: .88; }
.bh-hero .bh-h1 .bh-ln { display: block; transition: color .6s, opacity .6s, transform .8s var(--bh-ease); }
.bh-hero .bh-h1 .bh-ln:not(.on) { color: rgba(21,16,42,.16); }
.bh-hero .bh-h1 .bh-ln.on { transform: translateX(.04em); }
.bh-hero .bh-h1 .bh-ln em { padding-right: .08em; }
.bh-hero-cap { position: relative; height: 3.4em; margin: 26px 0 30px; max-width: 520px; color: var(--bh-ink-2); font-size: clamp(18px, 1.45vw, 22px); line-height: 1.5; }
.bh-hero-cap span { position: absolute; inset: 0; opacity: 0; transform: translateY(16px); transition: opacity .55s, transform .7s var(--bh-ease); }
.bh-hero-cap span.on { opacity: 1; transform: none; }
.bh-hero-cap b { color: var(--bh-violet); font-weight: 650; }
.bh-hero-ctas { display: flex; flex-wrap: wrap; align-items: center; gap: 14px; }
.bh-stage { position: relative; height: min(78vh, 760px); perspective: 1400px; }
.bh-stage-disc { position: absolute; inset: 6% 4%; border-radius: 50%; background: radial-gradient(circle at 35% 30%, rgba(255,255,255,.95), rgba(255,255,255,.35) 45%, rgba(205,189,255,.25) 70%, transparent 72%); box-shadow: inset 0 0 80px rgba(255,255,255,.7), 0 60px 120px -50px rgba(100,22,200,.45); }
.bh-stage-ring { position: absolute; inset: 0; transform-style: preserve-3d; transform: rotateX(72deg) rotateZ(var(--rz, 0deg)); }
.bh-stage-ring::before, .bh-stage-ring::after { content: ""; position: absolute; inset: 4% 0; border: 1.5px solid rgba(100,22,200,.22); border-radius: 50%; }
.bh-stage-ring::after { inset: 14% 10%; border-style: dashed; border-color: rgba(242,169,59,.45); }
.bh-particles { position: absolute; inset: 0; z-index: 2; }
.bh-particles canvas { display: block; width: 100% !important; height: 100% !important; }
.bh-orbit { position: absolute; inset: 0; z-index: 3; transform-style: preserve-3d; pointer-events: none; }
.bh-orbit .bh-chip { position: absolute; left: 50%; top: 50%; transform: translate(-50%, -50%) rotate(var(--a)) translateX(var(--rad, 38vmin)) rotate(calc(-1 * var(--a))) ; animation: bh-orbit 34s linear infinite; animation-delay: var(--dl); }
@keyframes bh-orbit { from { --a: 0deg; } }
.bh-hero-rail { position: absolute; left: var(--bh-pad); bottom: 28px; z-index: 3; display: flex; align-items: center; gap: 14px; color: var(--bh-faint); font-size: 12px; font-weight: 600; letter-spacing: .16em; text-transform: uppercase; }
.bh-hero-rail i { position: relative; width: 120px; height: 2px; border-radius: 2px; background: var(--bh-line-2); overflow: hidden; }
.bh-hero-rail i::after { content: ""; position: absolute; inset: 0; background: var(--bh-violet); transform-origin: 0 50%; transform: scaleX(var(--p, 0)); }

/* Tre punti di partenza: carte 3D a ventaglio che si raddrizzano */
.bh-entry { padding: 18vh 0 12vh; }
.bh-entry-head { display: grid; grid-template-columns: 1fr 1fr; align-items: end; gap: 30px 60px; margin-bottom: 60px; }
.bh-fan { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 26px; perspective: 1600px; }
.bh-fan > a { --f: 0; transform: rotateY(calc((1 - var(--p, 1)) * var(--fy, 0deg))) translateZ(calc((1 - var(--p, 1)) * -160px)) translateY(calc((1 - var(--p, 1)) * var(--fty, 0px))); transition: transform .2s linear; }
.bh-fan > a:nth-child(1) { --fy: 34deg; --fty: 60px; } .bh-fan > a:nth-child(3) { --fy: -34deg; --fty: 60px; }
.bh-door { display: grid; grid-template-rows: auto auto 1fr; gap: 22px; padding: 22px 22px 28px; color: var(--bh-ink); text-decoration: none; }
.bh-door-top { display: flex; justify-content: space-between; align-items: center; color: var(--bh-faint); font-size: 12px; font-weight: 700; letter-spacing: .16em; }
.bh-door-top i { display: grid; place-items: center; width: 44px; height: 44px; border-radius: 50%; background: var(--bh-ink); color: #fff; font-style: normal; transition: transform .5s var(--bh-ease), background .3s; }
.bh-door:hover .bh-door-top i { transform: rotate(-45deg); background: var(--bh-violet); }
.bh-door-view { position: relative; aspect-ratio: 4 / 3.4; border-radius: 20px; overflow: hidden; background: linear-gradient(160deg, #efe9ff, #fff5ec); transform-style: preserve-3d; }
.bh-door h3 { margin: 0 0 8px; font-size: clamp(30px, 2.6vw, 42px); font-weight: 640; line-height: .98; letter-spacing: -.045em; }
.bh-door p { margin: 0; color: var(--bh-muted); line-height: 1.5; }
.bh-door-cta { display: inline-flex; margin-top: 14px; color: var(--bh-violet); font-weight: 650; }
/* anteprime dentro le porte */
.v-sites { position: absolute; inset: -8% -6% auto; display: grid; grid-template-columns: repeat(3, 1fr); align-items: start; gap: 12px; transform: rotateX(16deg) rotateZ(-9deg); }
.v-sites img { width: 100%; aspect-ratio: 3 / 5; object-fit: cover; object-position: top; border-radius: 10px; box-shadow: 0 14px 28px -12px rgba(30,20,70,.4); animation: v-scroll 14s ease-in-out infinite alternate; }
.v-sites img:nth-child(2) { margin-top: 18%; animation-delay: -4s; } .v-sites img:nth-child(3) { animation-delay: -8s; }
@keyframes v-scroll { to { object-position: bottom; } }
.v-shop { display: grid; place-items: center; height: 100%; }
.v-shop-card { position: relative; width: 74%; padding: 14px; border-radius: 18px; background: #fff; box-shadow: var(--bh-shadow); transform: rotate(-4deg); }
.v-shop-card img { display: block; width: 100%; aspect-ratio: 4 / 3; object-fit: contain; animation: v-float 5s ease-in-out infinite alternate; }
@keyframes v-float { to { transform: translateY(-10px) rotate(-3deg); } }
.v-shop-card b { display: block; margin-top: 8px; font-size: 15px; } .v-shop-card small { color: var(--bh-muted); }
.v-shop-tag { position: absolute; right: -16px; top: 18px; padding: 8px 12px; border-radius: 12px; background: var(--bh-ink); color: #fff; font-size: 12px; font-weight: 700; box-shadow: var(--bh-shadow); }
.v-shop-tag.t2 { right: auto; left: -22px; top: auto; bottom: 26px; background: var(--bh-lime); color: var(--bh-ink); }
.v-code { height: 100%; padding: 22px; background: #17112b; color: #cdbdff; font: 500 13px/1.7 ui-monospace, "SF Mono", Menlo, monospace; }
.v-code p { margin: 0; white-space: nowrap; opacity: 0; transform: translateX(-10px); animation: v-type .5s var(--bh-ease) forwards; animation-delay: calc(var(--i) * .22s + .4s); }
.v-code .k { color: #f2a93b; } .v-code .s { color: #d9f36a; } .v-code .c { color: #7d7598; }
.bh-door:not(.in) .v-code p { animation-play-state: paused; }
@keyframes v-type { to { opacity: 1; transform: none; } }
.v-code-node { position: absolute; right: 16px; bottom: 16px; display: grid; gap: 8px; }
.v-code-node span { padding: 7px 11px; border-radius: 10px; background: rgba(255,255,255,.1); border: 1px solid rgba(255,255,255,.18); color: #fff; font: 600 12px Inter, sans-serif; }
.v-code-node span:nth-child(1)::before { content: "● "; color: #6ee7a8; }

/* Manifesto + scomposto 3D */
.bh-layers { position: relative; height: 300vh; }
.bh-layers-pin { position: sticky; top: 0; display: grid; grid-template-columns: .95fr 1.05fr; align-items: center; gap: 4vw; height: 100vh; }
.bh-layers-copy .bh-h2 { margin-bottom: 26px; }
.bh-words { margin: 0; color: var(--bh-ink); font-size: clamp(20px, 1.7vw, 27px); line-height: 1.45; letter-spacing: -.015em; }
.bh-words .mw { color: rgba(21,16,42,.18); transition: color .3s; }
.bh-words .mw.on { color: var(--bh-ink); }
.bh-words strong .mw.on { color: var(--bh-violet); }
.bh-stack3d { position: relative; height: min(76vh, 700px); perspective: 2200px; }
.bh-stack3d-in { position: absolute; left: 64%; top: 60%; width: min(420px, 68%); aspect-ratio: 1.25; transform-style: preserve-3d; transform: translate(-50%, -50%) rotateX(58deg) rotateZ(-38deg); }
.bh-plate { position: absolute; inset: 0; border-radius: 26px; transform-style: preserve-3d; transform: translateZ(calc(var(--z) * (16px + var(--p, 0) * 64px))); transition: transform .15s linear; }
.bh-plate-face { position: absolute; inset: 0; display: grid; grid-template-columns: repeat(6, 1fr); grid-template-rows: repeat(4, 1fr); gap: 10px; padding: 18px; border-radius: inherit; border: 1px solid rgba(255,255,255,.85); background: linear-gradient(140deg, rgba(255,255,255,.82), rgba(255,255,255,.4)); backdrop-filter: blur(10px); box-shadow: inset 0 1px 0 #fff, 0 30px 60px -20px rgba(60,30,130,.35); }
.bh-plate-face i { border-radius: 8px; background: var(--g, rgba(100,22,200,.12)); }
.bh-plate[data-l="0"] .bh-plate-face { background: linear-gradient(140deg, rgba(23,17,43,.92), rgba(43,30,80,.85)); border-color: rgba(255,255,255,.18); }
.bh-plate[data-l="0"] .bh-plate-face i { --g: rgba(205,189,255,.22); }

/* Video: vola lungo la curva e si apre */
.bh-film { position: relative; height: 270vh; }
.bh-film-pin { position: sticky; top: 0; height: 100vh; overflow: hidden; }
.bh-film-head { position: absolute; left: var(--bh-pad); top: 15vh; z-index: 2; max-width: 600px; opacity: clamp(0, calc(1 - var(--e, 0) * 2.2), 1); transform: translateY(calc(var(--e, 0) * -40px)); }

.bh-film-lead { max-width: 440px; margin: 22px 0 0; color: var(--bh-muted); font-size: 18px; line-height: 1.55; }
.bh-film-curve { position: absolute; inset: 0; width: 100%; height: 100%; z-index: 0; overflow: visible; }
.bh-film-curve path { fill: none; stroke: url(#bhcg); stroke-width: 2.5; stroke-linecap: round; stroke-dasharray: 1; stroke-dashoffset: calc(1 - var(--p, 0) * 1.6); }
.bh-film-cap { position: absolute; z-index: 2; display: flex; align-items: center; gap: 12px; padding: 12px 18px 12px 14px; border-radius: 18px; opacity: 0; transform: translate(-50%, -50%) scale(.6); transition: opacity .45s, transform .6s var(--bh-ease); white-space: nowrap; }
.bh-film-cap > b { flex: none; width: 10px; height: 10px; border-radius: 50%; background: var(--c, var(--bh-violet)); box-shadow: 0 0 0 5px color-mix(in srgb, var(--c, var(--bh-violet)) 18%, transparent); }
.bh-film-cap strong { display: block; font-size: 15px; font-weight: 650; letter-spacing: -.01em; }
.bh-film-cap small { display: block; margin-top: 2px; color: var(--bh-muted); font-size: 13px; }
.bh-film-steps { position: absolute; right: var(--bh-pad); bottom: 6vh; z-index: 3; display: flex; gap: 10px; margin: 0; padding: 0; list-style: none; opacity: clamp(0, calc(1 - var(--e, 0) * 3), 1); }
.bh-film-steps li { display: grid; place-items: center; width: 44px; height: 44px; border-radius: 50%; background: rgba(255,255,255,.6); box-shadow: inset 0 0 0 1px var(--bh-line-2); color: var(--bh-muted); font-size: 13px; font-weight: 700; transition: background .4s, color .4s, transform .5s var(--bh-ease); }
.bh-film-steps li.on { background: var(--bh-ink); color: #fff; transform: scale(1.08); }
.bh-film-cap.on { opacity: 1; transform: translate(-50%, -50%) scale(1); }
.bh-film-cap.off { opacity: 0; }
.bh-film-anchor { position: absolute; left: 0; top: 0; z-index: 1; border-radius: 24px; overflow: hidden; background: #17112b; box-shadow: var(--bh-shadow-lg); will-change: transform, width, height; }
.bh-film-anchor video { display: block; width: 100%; height: 100%; object-fit: cover; }
.gl-on .bh-film-anchor video { opacity: 0; }
.gl-on .bh-film-anchor { background: transparent; box-shadow: none; }
.bh-film-play { position: absolute; left: 50%; top: 50%; z-index: 3; display: grid; place-items: center; width: 92px; height: 92px; border: 0; border-radius: 50%; background: rgba(255,255,255,.85); backdrop-filter: blur(10px); box-shadow: var(--bh-shadow); cursor: pointer; transform: translate(-50%, -50%) scale(calc(.6 + var(--e, 0) * .4)); opacity: clamp(0, calc((var(--e, 0) - .55) * 3), 1); transition: background .3s; }
.bh-film-play svg { width: 26px; margin-left: 4px; fill: var(--bh-violet); }
.bh-film-play:hover { background: #fff; }
.bh-film-play.playing { opacity: 0 !important; pointer-events: none; }
.bh-film-sub { position: absolute; right: var(--bh-pad); bottom: 4vh; z-index: 3; opacity: clamp(0, calc((var(--e, 0) - .6) * 3), 1); }

/* Servizi: card WebGL in righe sfalsate */
.bh-svc { padding: 14vh 0 10vh; }
.bh-svc-head { display: flex; flex-wrap: wrap; align-items: end; justify-content: space-between; gap: 24px; margin-bottom: 70px; }
.bh-svc-row { display: grid; grid-template-columns: 1fr 1fr; gap: 4vw; margin-bottom: 9vh; }
.bh-svc-row:nth-child(even) { transform: translateX(6vw); } .bh-svc-row:nth-child(even) .bh-card:first-child { margin-top: 12vh; }
.bh-svc-row:nth-child(odd) .bh-card:last-child { margin-top: 14vh; }
.bh-card { display: block; color: var(--bh-ink); text-decoration: none; }
.bh-card-media { position: relative; aspect-ratio: 4 / 3; border-radius: 26px; overflow: hidden; background: var(--bh-bg-2); }
.bh-card-media img { display: block; width: 100%; height: 100%; object-fit: cover; filter: saturate(.85) brightness(1.08) contrast(.92); transition: transform 1.2s var(--bh-ease), filter .6s; }
.bh-card:hover .bh-card-media img { transform: scale(1.05); filter: none; }
.gl-on .bh-card-media.gl-live img { visibility: hidden; }
.gl-on .bh-card-media.gl-live { background: transparent; }
.bh-card-media::after { content: ""; position: absolute; inset: 0; background: #4b3a8f; mix-blend-mode: lighten; opacity: .55; transition: opacity .6s; pointer-events: none; }
.bh-card:hover .bh-card-media::after { opacity: .1; }
.gl-live.bh-card-media::after { display: none; }
.bh-card-meta { display: grid; grid-template-columns: auto 1fr auto; align-items: baseline; gap: 16px; padding: 20px 4px 0; }
.bh-card-n { color: var(--bh-violet); font: italic 400 28px/1 "Instrument Serif", serif; }
.bh-card-meta h3 { margin: 0; font-size: clamp(26px, 2.4vw, 38px); font-weight: 640; letter-spacing: -.04em; }
.bh-card-meta p { grid-column: 2; margin: 4px 0 0; color: var(--bh-muted); }
.bh-card-meta i { grid-row: 1; grid-column: 3; display: grid; place-items: center; width: 44px; height: 44px; border: 1px solid var(--bh-line-2); border-radius: 50%; font-style: normal; transition: background .3s, color .3s, transform .5s var(--bh-ease); }
.bh-card:hover .bh-card-meta i { background: var(--bh-ink); color: #fff; transform: rotate(-45deg); }

/* Strumenti: tre dispositivi in vetro */
.bh-tools { padding: 14vh 0; }
.bh-tools-grid { display: grid; grid-template-columns: 1.1fr .95fr .95fr; gap: 22px; margin-top: 60px; perspective: 1600px; }
.bh-tool { display: grid; grid-template-rows: 1fr auto; min-height: 520px; padding: 24px; color: var(--bh-ink); text-decoration: none; }
.bh-tool-ui { --uh: clamp(300px, 25vw, 380px); position: relative; display: grid; place-items: center; height: var(--uh); border-radius: 20px; background: linear-gradient(160deg, rgba(239,233,255,.9), rgba(255,245,236,.8)); overflow: hidden; transform-style: preserve-3d; }
.bh-tool h3 { margin: 20px 0 6px; font-size: 26px; font-weight: 640; letter-spacing: -.035em; }
.bh-tool p { margin: 0 0 12px; color: var(--bh-muted); }
.bh-tool-tag { display: inline-block; margin-bottom: 8px; padding: 5px 10px; border-radius: 99px; background: var(--bh-ink); color: #fff; font-size: 11px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; }
.bh-tool-tag.b { background: var(--bh-lime); color: var(--bh-ink); }
.ui-phone { position: absolute; top: 9%; left: 50%; width: calc(var(--uh) * 1.12 * 9 / 18.5); height: calc(var(--uh) * 1.12); margin-left: calc(var(--uh) * -1.12 * 9 / 37); padding: 10px; border-radius: 34px; background: #17112b; box-shadow: var(--bh-shadow-lg); transform: rotate(-5deg) translateZ(40px); }
.ui-phone-in { display: grid; align-content: start; gap: 10px; height: 100%; padding: 18px 12px; border-radius: 25px; background: #fff; overflow: hidden; }
.ui-rings { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px 8px; margin-bottom: 4px; }
.ui-ring { display: grid; justify-items: center; gap: 5px; min-width: 0; }
.ui-ring i { position: relative; display: block; width: 84%; aspect-ratio: 1; }
.ui-ring small { color: var(--bh-muted); font-size: 10.5px; font-weight: 600; white-space: nowrap; }
.ui-ring svg { display: block; width: 100%; height: 100%; transform: rotate(-90deg); }
.ui-ring circle { fill: none; stroke-width: 8; } .ui-ring circle:first-child { stroke: #eee9fb; }
.ui-ring circle:last-child { stroke: var(--c); stroke-linecap: round; stroke-dasharray: 100; stroke-dashoffset: 100; transition: stroke-dashoffset 1.6s var(--bh-ease); transition-delay: var(--d); }
.in .ui-ring circle:last-child { stroke-dashoffset: calc(100 - var(--v)); }
.ui-ring b { position: absolute; inset: 0; display: grid; place-items: center; font-size: 14px; font-weight: 650; }
.ui-row { height: 10px; border-radius: 5px; background: #f0ecfa; } .ui-row.s { width: 60%; }
.ui-map { position: absolute; inset: 0; background: linear-gradient(#f6f3ff 0 0); }
.ui-map svg { position: absolute; inset: 0; width: 100%; height: 100%; }
.ui-map path { fill: none; stroke: #ddd3fa; stroke-width: 10; } .ui-map path.r { stroke: #fff; stroke-width: 16; }
.ui-pin { position: absolute; width: 22px; height: 22px; margin: -22px 0 0 -11px; border-radius: 50% 50% 50% 0; background: var(--bh-violet); transform: rotate(-45deg) translateY(-30px); opacity: 0; transition: transform .6s cubic-bezier(.34,1.56,.64,1), opacity .3s; transition-delay: var(--d); box-shadow: 0 8px 14px rgba(100,22,200,.35); }
.ui-pin::after { content: ""; position: absolute; inset: 6px; border-radius: 50%; background: #fff; }
.in .ui-pin { transform: rotate(-45deg); opacity: 1; }
.ui-map-panel { position: absolute; left: 14px; right: 14px; bottom: 14px; display: flex; justify-content: space-between; align-items: center; padding: 12px 14px; border-radius: 14px; background: rgba(255,255,255,.85); backdrop-filter: blur(8px); font-size: 13px; font-weight: 600; box-shadow: var(--bh-shadow); }
.ui-map-panel b { color: var(--bh-violet); }
.ui-gauge { width: 76%; }
.ui-gauge svg { width: 100%; overflow: visible; }
.ui-gauge .bg { fill: none; stroke: #e9e3fa; stroke-width: 16; stroke-linecap: round; }
.ui-gauge .fg { fill: none; stroke: url(#bhgauge); stroke-width: 16; stroke-linecap: round; stroke-dasharray: 100; stroke-dashoffset: 100; transition: stroke-dashoffset 1.8s var(--bh-ease) .3s; }
.in .ui-gauge .fg { stroke-dashoffset: 28; }
.ui-gauge text { font: 700 34px Inter, sans-serif; fill: var(--bh-ink); text-anchor: middle; }
.ui-gauge text.s { font-size: 11px; font-weight: 600; fill: var(--bh-muted); letter-spacing: .06em; }

/* Metodo: finestre impilate con l'astronauta */
.bh-method { padding: 12vh 0 6vh; }
.bh-method-stack { display: grid; gap: 26px; margin-top: 60px; }
.bh-m { position: sticky; top: calc(96px + var(--i) * 30px); display: grid; grid-template-columns: 1fr 1.1fr; min-height: 62vh; overflow: hidden; padding: 0; transform: scale(var(--s, 1)); transform-origin: 50% 0; }
.bh-m-copy { display: flex; flex-direction: column; justify-content: flex-start; gap: 26px; padding: clamp(28px, 4vw, 56px); }
.bh-m-copy span { color: var(--bh-violet); font: italic 400 44px/1 "Instrument Serif", serif; }
.bh-m-copy h3 { margin: 0 0 18px; font-size: clamp(48px, 5.6vw, 92px); font-weight: 650; line-height: .9; letter-spacing: -.055em; }
.bh-m-copy p { max-width: 460px; margin: 0; color: var(--bh-muted); font-size: 18px; line-height: 1.55; }
.bh-m-media { position: relative; margin: 14px; border-radius: 22px; overflow: hidden; }
.bh-m-media img { width: 100%; height: 100%; object-fit: cover; transform: scale(calc(1.18 - var(--mp, 0) * .18)); transition: transform .2s linear; }
.bh-m-media::after { content: ""; position: absolute; inset: 0; background: linear-gradient(180deg, transparent 50%, rgba(23,17,43,.4)); }

/* Partner */
.bh-partners { padding: 12vh 0; overflow: hidden; }
.bh-logos { margin-top: 50px; display: grid; gap: 16px; }
.bh-logos .bh-track { gap: 16px; padding-right: 16px; }
.bh-logo { display: grid; place-items: center; width: 220px; height: 96px; padding: 18px 26px; border-radius: 22px; }
.bh-logo img { max-width: 100%; max-height: 46px; object-fit: contain; filter: grayscale(1) contrast(1.1); opacity: .78; transition: filter .4s, opacity .4s; }
.bh-logo:hover img { filter: none; opacity: 1; }

/* Contatto finale */
.bh-final { padding: 8vh 0 14vh; }
.bh-final-card { display: grid; grid-template-columns: 1.1fr .9fr; align-items: center; gap: 40px; min-height: 76vh; padding: clamp(32px, 5vw, 80px); overflow: hidden; }
.bh-final-card .bh-h2 { font-size: clamp(54px, 7vw, 124px); margin-bottom: 24px; }
.bh-final-orb { position: relative; height: min(60vh, 560px); }
.bh-final-links { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 30px; }
.bh-final-links a { text-decoration: none; }

@media (max-width: 1000px) {
  .bh-hero { height: 260vh; }
  .bh-hero-pin { grid-template-columns: 1fr; grid-template-rows: auto 1fr; align-items: start; padding-top: 100px; }
  .bh-stage { position: absolute; inset: 40% -10% 0; height: auto; opacity: .9; z-index: 1; }
  .bh-hero-copy { z-index: 3; }
  .bh-entry-head, .bh-layers-pin, .bh-final-card, .bh-m { grid-template-columns: 1fr; }
  .bh-fan, .bh-tools-grid { grid-template-columns: 1fr; }
  .bh-fan > a { transform: none !important; }
  .bh-door { min-height: 460px; }
  .bh-layers { height: auto; } .bh-layers-pin { position: relative; height: auto; padding: 12vh 0; }
  .bh-stack3d { height: 460px; }
  .bh-svc-row { grid-template-columns: 1fr; gap: 50px; transform: none !important; } .bh-svc-row .bh-card { margin-top: 0 !important; }
  .bh-m { position: relative; top: 0; min-height: 0; } .bh-m-media { aspect-ratio: 4 / 3; }
  .bh-final-orb { height: 320px; }
}
@media (max-width: 600px) { .bh-legend small { display: none; } .bh-stack3d-in { width: 62%; left: 62%; } }
@media (prefers-reduced-motion: reduce) {
  .bh-atmo i, .bh-orbit .bh-chip, .v-sites img, .v-shop-card img { animation: none; }
  .bh-split .bh-c, [data-bh-reveal] { transition: none !important; transform: none !important; opacity: 1 !important; filter: none !important; }
  .bh-hero, .bh-layers, .bh-film { height: auto; } .bh-hero-pin, .bh-layers-pin, .bh-film-pin { position: relative; height: auto; min-height: 0; padding-block: 120px 60px; }
  .bh-hero .bh-h1 .bh-ln:not(.on) { color: inherit; }
  .bh-hero-cap { height: auto; } .bh-hero-cap span { position: static; opacity: 1; transform: none; display: block; margin-bottom: 10px; }
  .bh-plate { transform: translateZ(calc(var(--z) * 60px)); }
  .bh-words .mw { color: inherit; }
  .bh-film-pin { height: 80vh; } .bh-film-anchor { position: relative; width: 100% !important; height: 70vh !important; transform: none !important; }
  .bh-film-play, .bh-film-head, .bh-film-sub { opacity: 1 !important; }
  .bh-film-steps { display: none; }
  .bh-m { position: relative; top: 0; }
}

/* ---------- integrazioni home ---------- */
.bh-page { position: relative; }
.bh-stage-ring { animation: bh-ring 60s linear infinite; }
@keyframes bh-ring { from { transform: rotateX(72deg) rotateZ(0deg); } to { transform: rotateX(72deg) rotateZ(360deg); } }
.bh-orbit .bh-chip { animation: none; transform: translate(-50%, -50%); will-change: transform, opacity; }
.bh-hero-lead { margin: 28px 0 34px; }
.bh-hero .bh-h1 .bh-ln { transition: color .7s, transform .9s var(--bh-ease); }
.bh-hero .bh-h1 .bh-ln:not(.on):not(.past) { color: rgba(21,16,42,.14); }
.bh-hero .bh-h1 .bh-ln.past { color: var(--bh-ink); }
.bh-hero .bh-h1 .bh-ln.on { transform: translateX(.05em); }
.bh-hero .bh-h1 .bh-ln em { color: inherit; }
.bh-hero .bh-h1 .bh-ln.on em { color: var(--bh-violet); }
.bh-hud { position: absolute; left: 2%; bottom: 6%; z-index: 5; display: grid; grid-template-columns: auto 1fr; gap: 16px; align-items: start; width: min(380px, 86%); padding: 18px 20px 22px; border-radius: 22px; }
.bh-hud-n { display: flex; align-items: baseline; gap: 4px; font: italic 400 34px/1 "Instrument Serif", serif; color: var(--bh-violet); }
.bh-hud-roll { position: relative; display: inline-block; width: 1.1em; height: 1em; overflow: hidden; }
.bh-hud-roll b { position: absolute; inset: 0; font-weight: 400; transform: translateY(110%); transition: transform .7s var(--bh-ease); }
.bh-hud-roll b.on { transform: none; } .bh-hud-roll b.past { transform: translateY(-110%); }
.bh-hud-n small { color: var(--bh-faint); font-size: 16px; }
.bh-hud-t { position: relative; min-height: 72px; }
.bh-hud-t p { position: absolute; inset: 0; margin: 0; color: var(--bh-ink-2); font-size: 15px; line-height: 1.5; opacity: 0; transform: translateY(10px); transition: opacity .5s, transform .7s var(--bh-ease); }
.bh-hud-t p.on { opacity: 1; transform: none; }
.bh-hud-t b { color: var(--bh-ink); }
.bh-hud-bar { position: absolute; left: 20px; right: 20px; bottom: 10px; height: 2px; border-radius: 2px; background: var(--bh-line); overflow: hidden; }
.bh-hud-bar::after { content: ""; position: absolute; inset: 0; background: linear-gradient(90deg, var(--bh-violet), var(--bh-amber)); transform-origin: 0 50%; transform: scaleX(var(--p, 0)); }
.bh-particles { --pc1: #3f1aa6; --pc2: #9a6bff; --pc3: #f2a93b; }

.v-shop { position: relative; perspective: 900px; }
.v-shop-search { position: absolute; left: 8%; top: 9%; display: flex; align-items: center; gap: 8px; padding: 10px 14px; border-radius: 14px; background: rgba(255,255,255,.92); box-shadow: var(--bh-shadow); font-size: 13px; font-weight: 600; transform: rotate(3deg); }
.v-shop-search span { color: var(--bh-violet); font-size: 16px; } .v-shop-search em { margin-left: 6px; color: var(--bh-faint); font-style: normal; font-weight: 500; }
.v-shop-card { margin-top: 34px; }
.bh-door { transform-style: preserve-3d; }
.bh-door .bh-door-view { box-shadow: inset 0 0 0 1px rgba(255,255,255,.7); }

/* piani dell'architettura */
.f-infra { grid-template-columns: repeat(3, 1fr) !important; grid-template-rows: repeat(2, 1fr) !important; }
.f-infra i { background: linear-gradient(180deg, rgba(205,189,255,.28), rgba(205,189,255,.1)) !important; position: relative; }
.f-infra i::after { content: ""; position: absolute; left: 14%; right: 14%; top: 24%; height: 5px; border-radius: 3px; background: #6ee7a8; box-shadow: 0 14px 0 rgba(255,255,255,.22), 0 28px 0 rgba(255,255,255,.14); }
.f-int { display: block !important; }
.f-int i { position: absolute; width: 16%; aspect-ratio: 1; border-radius: 50%; background: #fff !important; box-shadow: 0 0 0 6px rgba(100,22,200,.12), 0 10px 20px -8px rgba(60,30,130,.4); }
.f-int i::after { content: ""; position: absolute; inset: 30%; border-radius: 50%; background: var(--bh-violet); }
.f-int .n1 { left: 10%; top: 14%; } .f-int .n2 { left: 42%; top: 40%; } .f-int .n2::after { background: var(--bh-amber); } .f-int .n3 { left: 76%; top: 12%; } .f-int .n4 { left: 20%; top: 70%; } .f-int .n5 { left: 70%; top: 66%; }
.f-int svg { position: absolute; inset: 0; width: 100%; height: 100%; z-index: -1; }
.f-int path { fill: none; stroke: rgba(100,22,200,.35); stroke-width: 3; stroke-dasharray: 8 8; animation: bh-dash 1.2s linear infinite; }
@keyframes bh-dash { to { stroke-dashoffset: -16; } }
.f-logic i:nth-child(1) { grid-column: 1 / 4; grid-row: 1 / 3; --g: rgba(100,22,200,.16); }
.f-logic i:nth-child(2) { grid-column: 4 / 7; grid-row: 1 / 2; --g: rgba(242,169,59,.3); }
.f-logic i:nth-child(3) { grid-column: 4 / 6; grid-row: 2 / 3; }
.f-logic i:nth-child(4) { grid-column: 6 / 7; grid-row: 2 / 4; --g: rgba(22,163,122,.22); }
.f-logic i:nth-child(5) { grid-column: 1 / 3; grid-row: 3 / 5; --g: rgba(59,130,246,.18); }
.f-logic i:nth-child(6) { grid-column: 3 / 6; grid-row: 3 / 5; }
.f-logic i:nth-child(7) { grid-column: 6 / 7; grid-row: 4 / 5; --g: rgba(100,22,200,.3); }
.f-ui .u-nav { grid-column: 1 / 7; grid-row: 1; --g: rgba(21,16,42,.85); }
.f-ui .u-hero { grid-column: 1 / 4; grid-row: 2 / 4; --g: linear-gradient(135deg, #6416c8, #9a6bff); }
.f-ui .u-img { grid-column: 4 / 7; grid-row: 2 / 4; --g: linear-gradient(135deg, #ffd7b8, #f2a93b); }
.f-ui .u-t1 { grid-column: 1 / 3; grid-row: 4; } .f-ui .u-t2 { grid-column: 3 / 5; grid-row: 4; }
.f-ui .u-btn { grid-column: 5 / 7; grid-row: 4; --g: #f6d64a; border-radius: 99px !important; }
.f-ui .u-c1, .f-ui .u-c2, .f-ui .u-c3 { display: none; }
.bh-plate-face i { background: var(--g, rgba(100,22,200,.12)); }
.bh-stack3d::after { content: ""; position: absolute; left: 50%; top: 62%; width: 70%; height: 18%; transform: translateX(-50%); border-radius: 50%; background: radial-gradient(closest-side, rgba(60,30,130,.28), transparent); filter: blur(10px); }

/* fascia tipografica */
.bh-band { display: grid; gap: 6px; padding: 8vh 0; transform: rotate(-2.5deg); }
.bh-band [data-bh-marquee] { padding: 6px 0; }
.bh-band span { padding: 0 .28em; font-size: clamp(54px, 8vw, 132px); font-weight: 650; letter-spacing: -.05em; line-height: 1; }
.bh-band i { align-self: center; color: var(--bh-amber); font-size: .4em; font-style: normal; font-size: clamp(22px, 3vw, 44px); }
.bh-band .bh-track { align-items: center; }
.bh-track--out span { color: transparent; -webkit-text-stroke: 1.5px rgba(100,22,200,.5); font-family: "Instrument Serif", serif; font-style: italic; font-weight: 400; letter-spacing: -.02em; }

.bh-tool-links { display: flex; flex-wrap: wrap; gap: 8px 18px; }
.bh-tools-all, .bh-method-more { margin: 40px 0 0; font-size: 17px; }
.bh-tool .bh-link { color: var(--bh-violet); }
.ui-ring small { position: absolute; left: 0; right: 0; bottom: -16px; color: var(--bh-muted); font-size: 9px; font-weight: 700; text-align: center; letter-spacing: .02em; }
.ui-rings { row-gap: 26px; margin-bottom: 14px; }
.bh-m::after { content: ""; position: absolute; inset: 0; border-radius: inherit; background: #ece8f6; opacity: calc(var(--dim, 0) * .55); pointer-events: none; }
.bh-m-media img { transform: scale(calc(1.2 - var(--v, 0) * .2)); }
.bh-m-media::before { content: ""; position: absolute; inset: 0; z-index: 1; background: #4b3a8f; mix-blend-mode: lighten; opacity: .45; pointer-events: none; }
.bh-final-card { isolation: isolate; }
.bh-final-card::after { content: ""; position: absolute; right: -10%; top: -20%; width: 60%; aspect-ratio: 1; border-radius: 50%; z-index: -1; background: radial-gradient(circle, rgba(205,189,255,.7), transparent 65%); }
.bh-final-orb { --pc1: #3a138f; --pc2: #7b3ff0; --pc3: #f2a93b; }

/* senza JS: tutto visibile e impilato */
html:not(.bh-js) .bh-hero, html:not(.bh-js) .bh-layers, html:not(.bh-js) .bh-film { height: auto; }
html:not(.bh-js) .bh-hero-pin, html:not(.bh-js) .bh-layers-pin, html:not(.bh-js) .bh-film-pin { position: relative; height: auto; }
html:not(.bh-js) .bh-film-anchor { position: relative; width: 100%; aspect-ratio: 16 / 9; }
html:not(.bh-js) .bh-film-play, html:not(.bh-js) .bh-film-cap, html:not(.bh-js) .bh-film-curve, html:not(.bh-js) .bh-film-steps { display: none; }
html:not(.bh-js) .bh-hero .bh-h1 .bh-ln { color: inherit; }
.bh-film-anchor.live video { opacity: 1 !important; }
.bh-film-anchor.live { background: #000 !important; }

@media (max-width: 1000px) {
  .bh-hud { left: 0; right: 0; bottom: 3%; width: auto; }
  .bh-hero-lead { font-size: 16px; margin: 18px 0 22px; }
  .bh-hero .bh-h1 { font-size: clamp(54px, 15vw, 96px); }
  .bh-stage { inset: 46% -8% 0; }
  .bh-band span { font-size: 48px; }
  .bh-film-head { top: 12vh; right: var(--bh-pad); }
  .bh-film-cap small, .bh-film-steps { display: none; }
  .bh-film-cap { padding: 9px 14px 9px 12px; }
  .bh-film-lead { font-size: 16px; }
}
@media (max-width: 600px) { .bh-orbit .bh-chip { font-size: 12px; padding: 7px 12px; } .bh-hud { left: 46px; right: 46px; padding: 14px 16px 20px; gap: 12px; } .bh-hud-n { font-size: 28px; } .bh-hud-t p { font-size: 13.5px; } .bh-hero .bh-hero-ctas .bh-btn--ghost { display: none; } .bh-final-card { padding: 28px 22px; } }

/* ---------- variante scura (Chi siamo, Cyber security) ---------- */
body.bh2.bh-dark {
  --bh-bg: #0b0816; --bh-bg-2: #15102a; --bh-ink: #f4f1ff; --bh-ink-2: #d9d3f2; --bh-muted: #a49dc4; --bh-faint: #7a7397;
  --bh-violet: #a78bfa; --bh-line: rgba(255,255,255,.09); --bh-line-2: rgba(255,255,255,.18);
  --bh-shadow: 0 1px 2px rgba(0,0,0,.4), 0 20px 40px -18px rgba(0,0,0,.7), 0 50px 100px -40px rgba(100,22,200,.45);
  --bh-shadow-lg: 0 2px 4px rgba(0,0,0,.4), 0 40px 80px -30px rgba(0,0,0,.8), 0 100px 160px -60px rgba(120,60,240,.5);
  color-scheme: dark;
}
.bh-dark .bh-atmo i:nth-child(1) { background: radial-gradient(circle, rgba(100,22,200,.55), transparent 65%); }
.bh-dark .bh-atmo i:nth-child(2) { background: radial-gradient(circle, rgba(242,169,59,.18), transparent 62%); }
.bh-dark .bh-atmo i:nth-child(3) { background: radial-gradient(circle, rgba(40,120,255,.3), transparent 62%); }
.bh-dark .bh-atmo::before { background-image: linear-gradient(rgba(255,255,255,.04) 1px, transparent 1px), linear-gradient(90deg, rgba(255,255,255,.04) 1px, transparent 1px); }
.bh-dark .bh-atmo::after { opacity: .08; }
.bh-dark .bh-glass { border-color: rgba(255,255,255,.12); background: linear-gradient(150deg, rgba(255,255,255,.09), rgba(255,255,255,.025)); box-shadow: inset 0 1px 0 rgba(255,255,255,.14), inset 0 -1px 0 rgba(0,0,0,.4), var(--bh-shadow); }
.bh-dark .bh-glass::before { background: radial-gradient(420px circle at var(--gx, 20%) var(--gy, 0%), rgba(167,139,250,.22), transparent 50%); mix-blend-mode: screen; }
.bh-dark .bh-chip { border-color: rgba(255,255,255,.14); background: rgba(255,255,255,.07); color: var(--bh-ink); }
.bh-dark .bh-btn--ghost { background: rgba(255,255,255,.06); color: var(--bh-ink) !important; box-shadow: inset 0 0 0 1px var(--bh-line-2); }
.bh-dark .bh-serif, .bh-dark .bh-h1 em, .bh-dark .bh-h2 em, .bh-dark .bh-h3 em { color: #c4b5fd; }
.bh-dark ::selection { background: #c4b5fd; color: #0b0816; }

/* neutralizza gli stili globali dei titoli (testo olografico, sfondi) */
body.bh2 :is(h1, h2, h3) span, body.bh2 :is(h1, h2, h3) em { background: none; -webkit-text-fill-color: currentColor; animation: none; }
body.bh2 h2 { background: none !important; }
body.bh2 .bh-grad { background: linear-gradient(100deg, var(--bh-violet) 10%, #b35cf0 45%, var(--bh-amber) 90%); -webkit-background-clip: text; background-clip: text; -webkit-text-fill-color: transparent; }
.gl-on .bh-film-curve { opacity: 0; }
.bh-legend { position: absolute; left: 0; top: 50%; z-index: 2; display: grid; gap: calc(14px + var(--p, 0) * 34px); margin: 0; padding: 0; list-style: none; transform: translateY(-50%); transition: gap .15s linear; }
.bh-legend li { display: grid; gap: 2px; padding-left: 18px; border-left: 2px solid var(--bh-line-2); opacity: calc(.35 + clamp(0, (var(--p, 0) * 4 - var(--k) * .6), 1) * .65); transition: opacity .3s; }
.bh-legend li:first-child { border-color: var(--bh-violet); }
.bh-legend b { font-size: 17px; font-weight: 650; letter-spacing: -.02em; }
.bh-legend small { color: var(--bh-muted); font-size: 13px; }
.bh-m-copy h3 { margin-top: 8px; }

body.bh2::before, body.bh2::after { content: none !important; display: none !important; }

/* header sulle pagine scure: il menu resta in vetro chiaro, quindi testo scuro */
body.bh-dark .site-nav { color: #15102a; }
body.bh-dark .site-nav a:not(.bottone), body.bh-dark .site-nav .nav-primary-links a { color: #15102a !important; }
.bhs-crumb { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 28px; color: var(--bh-faint); font-size: 13px; }
.bhs-crumb a { color: var(--bh-muted); text-decoration: none !important; } .bhs-crumb a:hover { color: var(--bh-ink); }
/* senza movimento o senza JavaScript: le tre didascalie dell'hero restano tutte leggibili */
@media (prefers-reduced-motion: reduce) {
  .bh-hud-t { min-height: 0; } .bh-hud-t p { position: static; opacity: 1; transform: none; margin: 0 0 8px; }
  .bh-hud-roll, .bh-hud-n small, .bh-hud-bar { display: none; } .bh-hud-n::before { content: "01–03"; }
}
html:not(.bh-js) .bh-hud-t { min-height: 0; }
html:not(.bh-js) .bh-hud-t p { position: static; opacity: 1; transform: none; margin: 0 0 8px; }
html:not(.bh-js) .bh-hud-roll, html:not(.bh-js) .bh-hud-n small, html:not(.bh-js) .bh-hud-bar { display: none; }
html:not(.bh-js) .bh-hud-n::before { content: "01–03"; }
html:not(.bh-js) .bh-film-sub { opacity: 1; }

/* ===== progetti e collaborazioni: tre nastri obliqui di loghi ===== */
.bh-clients { position: relative; padding: 14vh 0 12vh; overflow: hidden; }
.bh-clients-head { display: grid; grid-template-columns: 1fr 1fr; align-items: end; gap: 5vw; }
.bh-clients-head .bh-lead { max-width: 640px; }
.bh-tapes { position: relative; height: clamp(420px, 44vw, 560px); margin-top: 7vh; }
.bh-tape { position: absolute; left: -12%; right: -12%; padding: clamp(16px, 2vw, 26px) 0; overflow: hidden; }
.bh-tape.t0 { top: 6%; z-index: 3; transform: rotate(-6deg); background: rgba(255,255,255,.78); backdrop-filter: blur(16px) saturate(150%); box-shadow: inset 0 0 0 1px rgba(255,255,255,.9), 0 40px 80px -40px rgba(31,18,70,.35); }
.bh-tape.t1 { top: 36%; z-index: 2; transform: rotate(4deg); background: linear-gradient(90deg, #5a12b8, #7b3ff0 50%, #9b6bf5); box-shadow: 0 40px 80px -36px rgba(100,22,200,.55); }
.bh-tape.t2 { top: 64%; z-index: 1; transform: rotate(-2.5deg); background: #15102a; box-shadow: 0 40px 80px -36px rgba(21,16,42,.6); }
.bh-tape-track { display: flex; align-items: center; gap: clamp(44px, 5vw, 76px); width: max-content; margin: 0; padding: 0 32px; list-style: none; will-change: transform; }
.bh-tape-track li { flex: none; display: grid; place-items: center; height: 64px; margin: 0; padding: 0; }
.bh-tape-track li::before { display: none; }
.bh-tape img { display: block; max-width: none; opacity: .78; transition: opacity .3s, transform .5s var(--bh-ease); }
.bh-tape img:hover { opacity: 1; transform: scale(1.08); }
.bh-tape.t1 img, .bh-tape.t2 img { filter: invert(1) brightness(1.6); opacity: .92; }
.bh-clients-note { margin-top: 4vh; color: var(--bh-muted); font-size: 12.5px; }
/* pagina scura: il nastro chiaro diventa vetro scuro, quello scuro diventa chiaro */
.bh-clients.is-dark .bh-tape.t0 { background: rgba(255,255,255,.07); box-shadow: inset 0 0 0 1px rgba(255,255,255,.1), 0 40px 80px -40px rgba(0,0,0,.6); }
.bh-clients.is-dark .bh-tape.t0 img { filter: invert(1) brightness(1.6); }
.bh-clients.is-dark .bh-tape.t2 { background: #f4f2f9; }
.bh-clients.is-dark .bh-tape.t2 img { filter: none; opacity: .85; }
@media (max-width: 1000px) {
  .bh-clients-head { grid-template-columns: 1fr; }
  .bh-tapes { height: 300px; margin-top: 4vh; }
  .bh-tape { padding: 12px 0; } .bh-tape.t1 { top: 37%; } .bh-tape.t2 { top: 68%; }
  .bh-tape-track { gap: 34px; }
  .bh-tape-track li { height: 40px; }
  .bh-tape img { zoom: .66; } .bh-tape img:hover { transform: none; }
  .bh-clients { padding-bottom: 6vh; }
}
@media (prefers-reduced-motion: reduce) {
  .bh-tapes { height: auto; display: grid; gap: 14px; }
  .bh-tape { position: relative; left: 0; right: 0; transform: none !important; }
  .bh-tape-track { flex-wrap: wrap; justify-content: center; width: auto; row-gap: 18px; }
  .bh-tape-track [aria-hidden="true"] { display: none; }
}
html:not(.bh-js) .bh-tapes { height: auto; display: grid; gap: 14px; }
html:not(.bh-js) .bh-tape { position: relative; left: 0; right: 0; transform: none; }
html:not(.bh-js) .bh-tape-track { flex-wrap: wrap; justify-content: center; width: auto; row-gap: 18px; }
body.bhs main .bh-tape-track li { margin: 0; padding: 0; } body.bhs main .bh-tape-track li::before { display: none; }

/* ===== competenze: mosaico compatto, testo dentro l'immagine ===== */
.bh-svc-head { margin-bottom: 46px; }
.bh-svc-grid { display: grid; grid-template-columns: repeat(4, 1fr); grid-auto-rows: clamp(280px, 24vw, 400px); gap: 18px; }
.bh-svc-grid .c1, .bh-svc-grid .c6, .bh-svc-grid .c7, .bh-svc-grid .c8 { grid-column: span 2; }
.bh-svc-grid .bh-card { position: relative; display: block; height: 100%; border-radius: 26px; overflow: hidden; color: var(--bh-ink); text-decoration: none; isolation: isolate; }
.bh-svc-grid .bh-card-media { position: absolute; inset: 0; aspect-ratio: auto; border-radius: 26px; }
.bh-svc-grid .bh-card-media img { filter: saturate(.95) contrast(.98); }
.bh-svc-grid .bh-card-media::after { opacity: .14; }
.bh-svc-grid .bh-card-n { position: absolute; left: 16px; top: 16px; z-index: 2; padding: 6px 12px; border-radius: 99px; background: rgba(255,255,255,.78); backdrop-filter: blur(10px); color: var(--bh-violet); font: italic 400 20px/1 "Instrument Serif", serif; box-shadow: var(--bh-shadow); }
.bh-svc-grid .bh-card-meta { position: absolute; left: 14px; right: 14px; bottom: 14px; z-index: 2; display: grid; grid-template-columns: 1fr auto; align-items: center; gap: 4px 14px; padding: 16px 18px; border-radius: 20px; background: rgba(255,255,255,.76); backdrop-filter: blur(16px) saturate(150%); box-shadow: inset 0 0 0 1px rgba(255,255,255,.7), 0 18px 40px -18px rgba(21,16,42,.45); transform: translateY(0); transition: transform .6s var(--bh-ease), background .4s; }
.bh-svc-grid .bh-card-meta h3 { margin: 0; font-size: clamp(20px, 1.7vw, 28px); font-weight: 650; letter-spacing: -.035em; line-height: 1.08; }
.bh-svc-grid .bh-card-meta p { grid-column: 1; margin: 0; color: var(--bh-ink-2); font-size: 14px; line-height: 1.45; max-height: 0; opacity: 0; overflow: hidden; transition: max-height .6s var(--bh-ease), opacity .4s, margin .4s; }
.bh-svc-grid .bh-card-meta i { grid-column: 2; grid-row: 1 / span 2; display: grid; place-items: center; width: 42px; height: 42px; border-radius: 50%; background: var(--bh-ink); color: #fff; font-style: normal; transition: transform .5s var(--bh-ease), background .3s; }
.bh-svc-grid .bh-card:hover .bh-card-meta, .bh-svc-grid .bh-card:focus-visible .bh-card-meta { background: rgba(255,255,255,.9); }
.bh-svc-grid .bh-card:hover .bh-card-meta p, .bh-svc-grid .bh-card:focus-visible .bh-card-meta p { max-height: 60px; opacity: 1; margin-top: 4px; }
.bh-svc-grid .bh-card:hover .bh-card-meta i { transform: rotate(-45deg); background: var(--bh-violet); }
.bh-svc-grid .c1 .bh-card-meta p, .bh-svc-grid .c6 .bh-card-meta p, .bh-svc-grid .c7 .bh-card-meta p, .bh-svc-grid .c8 .bh-card-meta p { max-height: 60px; opacity: 1; margin-top: 4px; }
@media (max-width: 1000px) {
  .bh-svc-grid { grid-template-columns: 1fr 1fr; grid-auto-rows: 300px; }
  .bh-svc-grid .bh-card { grid-column: span 1 !important; }
  .bh-svc-grid .c1, .bh-svc-grid .c8 { grid-column: span 2 !important; }
  .bh-svc-grid .bh-card-meta p { max-height: 60px; opacity: 1; margin-top: 4px; }
}
@media (max-width: 600px) {
  .bh-svc-grid { grid-template-columns: 1fr; grid-auto-rows: 280px; }
  .bh-svc-grid .bh-card { grid-column: auto !important; }
}
