/* ==========================================================================
   Sicurmas Group — design system
   Palette originale del sito: nero/grafite, bianco, blu #009ee0,
   verde #319d3c, rosso #be0a27 (i tre colori del logo).
   ========================================================================== */

@font-face {
font-family: 'Inter';
font-style: normal;
font-weight: 300 800;
font-display: swap;
src: url(../fonts/inter-latin-ext.woff2) format('woff2');
unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C4, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
@font-face {
font-family: 'Inter';
font-style: normal;
font-weight: 300 800;
font-display: swap;
src: url(../fonts/inter-latin.woff2) format('woff2');
unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
font-family: 'Space Grotesk';
font-style: normal;
font-weight: 400 700;
font-display: swap;
src: url(../fonts/space-grotesk-latin-ext.woff2) format('woff2');
unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C4, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
@font-face {
font-family: 'Space Grotesk';
font-style: normal;
font-weight: 400 700;
font-display: swap;
src: url(../fonts/space-grotesk-latin.woff2) format('woff2');
unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
font-family: 'JetBrains Mono';
font-style: normal;
font-weight: 400 600;
font-display: swap;
src: url(../fonts/jetbrains-mono-latin-ext.woff2) format('woff2');
unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C4, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
@font-face {
font-family: 'JetBrains Mono';
font-style: normal;
font-weight: 400 600;
font-display: swap;
src: url(../fonts/jetbrains-mono-latin.woff2) format('woff2');
unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}


:root {
  --bg: #0b0c0e;
  --bg-2: #111111;
  --surface: #16181b;
  --surface-2: #1d2024;
  --surface-3: #262a2f;
  --line: rgba(255, 255, 255, .08);
  --line-strong: rgba(255, 255, 255, .16);
  --text: #f3f5f7;
  --text-2: #ccd3db;
  --muted: #8f99a5;

  --blue: #009ee0;
  --blue-light: #52cbfd;
  --green: #319d3c;
  --green-light: #57db65;
  --red: #be0a27;
  --red-light: #f0445f;

  --brand-gradient: linear-gradient(90deg, var(--green) 0 33.33%, var(--blue) 33.33% 66.66%, var(--red) 66.66% 100%);
  --glow: radial-gradient(60% 60% at 50% 0%, rgba(0, 158, 224, .18), transparent 70%);

  --font-sans: "Inter", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  --font-display: "Space Grotesk", "Inter", system-ui, sans-serif;
  --font-mono: "JetBrains Mono", ui-monospace, "SFMono-Regular", Menlo, monospace;

  --radius-sm: 8px;
  --radius: 14px;
  --radius-lg: 22px;
  --container: 1240px;
  --gutter: clamp(16px, 4vw, 32px);
  --header-h: 76px;

  --ease-out: cubic-bezier(.16, 1, .3, 1);
  --ease-in-out: cubic-bezier(.65, 0, .35, 1);
  --shadow: 0 1px 0 rgba(255, 255, 255, .04) inset, 0 20px 40px -24px rgba(0, 0, 0, .8);

  color-scheme: dark;
}

/* --------------------------------------------------------------- base */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-padding-top: calc(var(--header-h) + 16px); }
body {
  margin: 0;
  background: var(--bg);
  color: var(--text-2);
  font: 400 1rem/1.7 var(--font-sans);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  overflow-x: hidden;
}
img, video, svg { display: block; max-width: 100%; }
img { height: auto; }
a { color: inherit; text-decoration: none; }
button, input, select, textarea { font: inherit; color: inherit; }
::selection { background: var(--blue); color: #fff; }
:focus-visible { outline: 2px solid var(--blue-light); outline-offset: 3px; border-radius: 4px; }

h1, h2, h3, h4 {
  font-family: var(--font-display);
  color: var(--text);
  line-height: 1.12;
  letter-spacing: -.02em;
  margin: 0 0 .6em;
  font-weight: 600;
  text-wrap: balance;
}
h1 { font-size: clamp(2.4rem, 5.6vw, 4.6rem); letter-spacing: -.035em; }
h2 { font-size: clamp(1.9rem, 3.6vw, 3rem); }
h3 { font-size: clamp(1.2rem, 1.8vw, 1.45rem); letter-spacing: -.01em; }
p { margin: 0 0 1.1em; text-wrap: pretty; }
strong { color: var(--text); font-weight: 600; }
.prose a, .link { color: var(--blue-light); background: linear-gradient(currentColor, currentColor) 0 100% / 0 1px no-repeat; transition: background-size .35s var(--ease-out); }
.prose a:hover, .link:hover { background-size: 100% 1px; }

.skip-link { position: absolute; left: 16px; top: -60px; z-index: 200; background: var(--blue); color: #fff; padding: 10px 16px; border-radius: var(--radius-sm); transition: top .2s; }
.skip-link:focus { top: 12px; }

.container { width: 100%; max-width: calc(var(--container) + var(--gutter) * 2); margin: 0 auto; padding: 0 var(--gutter); }
.visually-hidden { position: absolute !important; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

/* --------------------------------------------------------------- buttons & chips */
.btn {
  --btn-bg: var(--blue);
  position: relative;
  display: inline-flex; align-items: center; gap: .6em;
  padding: .85em 1.4em;
  border-radius: 999px;
  background: var(--btn-bg);
  color: #fff;
  font-weight: 600; font-size: .95rem; letter-spacing: .01em;
  border: 1px solid transparent;
  cursor: pointer;
  overflow: hidden;
  isolation: isolate;
  transition: transform .4s var(--ease-out), box-shadow .4s var(--ease-out), background-color .3s;
}
.btn::before {
  content: ""; position: absolute; inset: 0; z-index: -1;
  background: linear-gradient(120deg, transparent 30%, rgba(255, 255, 255, .28) 50%, transparent 70%);
  transform: translateX(-120%);
  transition: transform .8s var(--ease-out);
}
.btn:hover { transform: translateY(-2px); box-shadow: 0 12px 30px -12px rgba(0, 158, 224, .7); }
.btn:hover::before { transform: translateX(120%); }
.btn .arrow { transition: transform .4s var(--ease-out); }
.btn:hover .arrow { transform: translateX(4px); }
.btn--ghost { --btn-bg: transparent; border-color: var(--line-strong); }
.btn--ghost:hover { border-color: var(--text); box-shadow: none; background: rgba(255, 255, 255, .04); }
.btn--green { --btn-bg: var(--green); }
.btn--green:hover { box-shadow: 0 12px 30px -12px rgba(49, 157, 60, .8); }
.btn--sm { padding: .6em 1.1em; font-size: .875rem; }

.eyebrow {
  display: inline-flex; align-items: center; gap: .65em;
  font: 600 .78rem/1 var(--font-sans);
  text-transform: uppercase; letter-spacing: .16em;
  color: var(--blue-light);
  margin-bottom: 1.1rem;
}
.eyebrow::before { content: ""; width: 26px; height: 3px; border-radius: 3px; background: var(--brand-gradient); }
.chip {
  display: inline-flex; align-items: center; gap: .5em;
  padding: .45em .9em; border-radius: 999px;
  border: 1px solid var(--line-strong);
  background: rgba(255, 255, 255, .04);
  backdrop-filter: blur(8px);
  font-size: .8rem; font-weight: 500; color: var(--text-2);
}
.chip .dot { width: 7px; height: 7px; border-radius: 50%; background: var(--green-light); box-shadow: 0 0 0 0 rgba(87, 219, 101, .6); animation: pulse 2.2s infinite; }
@keyframes pulse { 70% { box-shadow: 0 0 0 9px rgba(87, 219, 101, 0); } 100% { box-shadow: 0 0 0 0 rgba(87, 219, 101, 0); } }

/* --------------------------------------------------------------- header */
.site-header {
  position: fixed; inset: 0 0 auto 0; z-index: 100;
  height: var(--header-h);
  transition: background-color .4s, border-color .4s, height .4s var(--ease-out), transform .5s var(--ease-out);
  border-bottom: 1px solid transparent;
}
.site-header.is-scrolled {
  --header-h: 64px;
  background: rgba(11, 12, 14, .78);
  backdrop-filter: saturate(160%) blur(16px);
  -webkit-backdrop-filter: saturate(160%) blur(16px);
  border-bottom-color: var(--line);
}
.site-header.is-hidden { transform: translateY(-100%); }
.header-inner { height: 100%; display: flex; align-items: center; gap: 28px; }
.brand { display: flex; align-items: center; flex-shrink: 0; }
.brand img { height: 30px; width: auto; transition: height .4s var(--ease-out); }
.is-scrolled .brand img { height: 26px; }

.main-nav { margin-left: auto; }
.main-nav > ul { display: flex; align-items: center; gap: 4px; list-style: none; margin: 0; padding: 0; }
.nav-link {
  position: relative; display: inline-flex; align-items: center; gap: 6px;
  padding: 10px 14px; border-radius: 999px;
  font-size: .92rem; font-weight: 500; color: var(--text-2);
  background: none; border: 0; cursor: pointer;
  transition: color .25s, background-color .25s;
}
.nav-link:hover, .nav-item:focus-within > .nav-link { color: var(--text); background: rgba(255, 255, 255, .06); }
.nav-link[aria-current="page"], .nav-item.is-active > .nav-link { color: var(--text); }
.nav-link[aria-current="page"]::after, .nav-item.is-active > .nav-link::after {
  content: ""; position: absolute; left: 14px; right: 14px; bottom: 4px; height: 2px; border-radius: 2px; background: var(--blue);
}
.nav-link .chev { width: 10px; height: 10px; transition: transform .3s var(--ease-out); }
.nav-item { position: relative; }
.nav-item:hover .chev, .nav-item.is-open .chev { transform: rotate(180deg); }

.mega {
  position: absolute; top: calc(100% + 10px); left: 50%;
  width: min(640px, 90vw);
  padding: 14px;
  background: rgba(22, 24, 27, .96);
  backdrop-filter: blur(18px);
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  box-shadow: 0 30px 60px -20px rgba(0, 0, 0, .9);
  display: grid; grid-template-columns: 1fr 1fr; gap: 2px;
  opacity: 0; visibility: hidden;
  transform: translate(-50%, 8px) scale(.98);
  transform-origin: top center;
  transition: opacity .25s, transform .35s var(--ease-out), visibility 0s .35s;
}
.mega::before { content: ""; position: absolute; inset: -12px 0 auto; height: 12px; }
.nav-item:hover > .mega, .nav-item.is-open > .mega, .nav-item:focus-within > .mega {
  opacity: 1; visibility: visible; transform: translate(-50%, 0) scale(1); transition-delay: 0s;
}
.mega a {
  display: flex; align-items: center; gap: 12px;
  padding: 10px 12px; border-radius: 10px;
  font-size: .9rem; color: var(--text-2);
  transition: background-color .2s, color .2s, transform .3s var(--ease-out);
}
.mega a:hover { background: rgba(255, 255, 255, .06); color: var(--text); transform: translateX(3px); }
.mega .ico .arrow { width: 13px; height: 13px; transition: transform .35s var(--ease-out); }
.mega a:hover .ico .arrow { transform: translateX(2px); }
.mega a[aria-current="page"] { color: var(--blue-light); }
.mega .ico { width: 30px; height: 30px; flex-shrink: 0; display: grid; place-items: center; border-radius: 8px; background: rgba(0, 158, 224, .12); color: var(--blue-light); font-size: .75rem; font-weight: 700; }
.mega--green .ico { background: rgba(49, 157, 60, .14); color: var(--green-light); }
.mega-head { grid-column: 1 / -1; display: flex; justify-content: space-between; align-items: center; padding: 6px 12px 12px; margin-bottom: 4px; border-bottom: 1px solid var(--line); font-size: .78rem; text-transform: uppercase; letter-spacing: .14em; color: var(--muted); }
.mega-head a { padding: 0; font-size: .8rem; text-transform: none; letter-spacing: 0; color: var(--blue-light); }
.mega-head a:hover { transform: none; background: none; }

.header-actions { display: flex; align-items: center; gap: 10px; }
.social { display: flex; gap: 6px; }
.social a { width: 36px; height: 36px; display: grid; place-items: center; border-radius: 50%; color: var(--text-2); border: 1px solid var(--line); transition: color .25s, border-color .25s, transform .3s var(--ease-out), background-color .25s; }
.social a:hover { color: #fff; border-color: var(--blue); background: rgba(0, 158, 224, .14); transform: translateY(-2px); }
.social svg { width: 16px; height: 16px; }

.burger { display: none; width: 44px; height: 44px; border-radius: 50%; border: 1px solid var(--line-strong); background: none; cursor: pointer; position: relative; }
.burger span { position: absolute; left: 13px; right: 13px; height: 2px; border-radius: 2px; background: var(--text); transition: transform .4s var(--ease-out), opacity .2s; }
.burger span:nth-child(1) { top: 16px; } .burger span:nth-child(2) { top: 21px; } .burger span:nth-child(3) { top: 26px; }
.nav-open .burger span:nth-child(1) { transform: translateY(5px) rotate(45deg); }
.nav-open .burger span:nth-child(2) { opacity: 0; }
.nav-open .burger span:nth-child(3) { transform: translateY(-5px) rotate(-45deg); }

/* --------------------------------------------------------------- hero (home) */
.hero {
  position: relative; min-height: 100svh;
  display: flex; align-items: center;
  padding: calc(var(--header-h) + 40px) 0 120px;
  overflow: hidden; isolation: isolate;
}
.hero-media { position: absolute; inset: 0; z-index: -2; }
.hero-media video, .hero-media img { width: 100%; height: 100%; object-fit: cover; }
.hero::before {
  content: ""; position: absolute; inset: 0; z-index: -1;
  background:
    linear-gradient(180deg, rgba(11, 12, 14, .55) 0%, rgba(11, 12, 14, .2) 35%, rgba(11, 12, 14, .85) 85%, var(--bg) 100%),
    linear-gradient(90deg, rgba(11, 12, 14, .94) 0%, rgba(11, 12, 14, .72) 45%, rgba(11, 12, 14, .25) 100%);
}
.hero-grid { position: absolute; inset: 0; z-index: -1; opacity: .35; background-image: linear-gradient(var(--line) 1px, transparent 1px), linear-gradient(90deg, var(--line) 1px, transparent 1px); background-size: 72px 72px; mask-image: radial-gradient(70% 60% at 30% 50%, #000 0%, transparent 75%); }
.hero-content { max-width: 820px; }
.hero h1 { margin-bottom: .45em; }
.hero h1 .accent { background: linear-gradient(90deg, var(--blue-light), var(--green-light)); -webkit-background-clip: text; background-clip: text; color: transparent; }
.hero .lead { font-size: clamp(1.05rem, 1.5vw, 1.25rem); color: var(--text-2); max-width: 620px; margin-bottom: 2.2rem; }
.hero-actions { display: flex; flex-wrap: wrap; gap: 12px; }
.hero-badges { display: flex; flex-wrap: wrap; gap: 28px; align-items: center; margin-top: 56px; padding-top: 28px; border-top: 1px solid var(--line); max-width: 680px; }
.hero-badges .badge { display: flex; align-items: center; gap: 12px; font-size: .85rem; color: var(--muted); line-height: 1.35; }
.hero-badges .badge img { height: 40px; width: auto; }
.hero-badges .badge strong { display: block; color: var(--text); font-size: .95rem; }
.scroll-cue { position: absolute; left: 50%; bottom: 32px; transform: translateX(-50%); display: flex; flex-direction: column; align-items: center; gap: 10px; font-size: .72rem; letter-spacing: .2em; text-transform: uppercase; color: var(--muted); }
.scroll-cue .mouse { width: 22px; height: 34px; border: 1.5px solid var(--line-strong); border-radius: 12px; position: relative; }
.scroll-cue .mouse::after { content: ""; position: absolute; left: 50%; top: 7px; width: 3px; height: 7px; margin-left: -1.5px; border-radius: 2px; background: var(--text); animation: wheel 1.8s var(--ease-in-out) infinite; }
@keyframes wheel { 0% { transform: translateY(0); opacity: 1; } 80% { transform: translateY(10px); opacity: 0; } 100% { opacity: 0; } }

/* home: il video e' l'unico contenuto dell'hero */
.hero--video { min-height: 0; height: 100svh; padding: 0; display: block; background: #000; }
.hero--video::before { background: linear-gradient(180deg, rgba(11, 12, 14, .55) 0%, transparent 18%, transparent 82%, var(--bg) 100%); }
.hero--video .hero-media video { animation: heroIn 1.6s var(--ease-out) both; }
@keyframes heroIn { from { opacity: 0; transform: scale(1.04); } }

/* testo che compare parola per parola */
.split .w { display: inline-block; overflow: hidden; vertical-align: top; padding-bottom: .08em; margin-bottom: -.08em; }
.split .w > span { display: inline-block; transform: translateY(105%); transition: transform 1s var(--ease-out); transition-delay: calc(var(--i) * 70ms + var(--base, 0ms)); }
.split.is-visible .w > span { transform: none; }

/* --------------------------------------------------------------- page hero */
.page-hero {
  position: relative; isolation: isolate; overflow: hidden;
  min-height: min(68vh, 620px);
  display: flex; align-items: flex-end;
  padding: calc(var(--header-h) + 60px) 0 72px;
}
.page-hero__bg { position: absolute; inset: -8% 0; z-index: -2; }
.page-hero__bg img { width: 100%; height: 100%; object-fit: cover; animation: kenburns 22s var(--ease-in-out) infinite alternate; }
@keyframes kenburns { from { transform: scale(1.04); } to { transform: scale(1.14) translate(-1.5%, -1%); } }
.page-hero::before { content: ""; position: absolute; inset: 0; z-index: -1; background: linear-gradient(180deg, rgba(11, 12, 14, .55), rgba(11, 12, 14, .55) 40%, var(--bg) 100%), linear-gradient(90deg, rgba(11, 12, 14, .7), transparent 75%); }
.page-hero--plain { min-height: auto; padding-bottom: 40px; background: var(--glow); }
.page-hero--plain::before { display: none; }
.page-hero h1 { max-width: 900px; margin-bottom: .3em; }
.page-hero .lead { max-width: 680px; font-size: 1.15rem; color: var(--text-2); margin: 0; }

.breadcrumb { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; list-style: none; padding: 0; margin: 0 0 22px; font-size: .85rem; color: var(--muted); }
.breadcrumb li { display: flex; align-items: center; gap: 8px; }
.breadcrumb li + li::before { content: ""; width: 5px; height: 5px; border-top: 1.5px solid currentColor; border-right: 1.5px solid currentColor; transform: rotate(45deg); opacity: .6; }
.breadcrumb a { transition: color .2s; }
.breadcrumb a:hover { color: var(--text); }
.breadcrumb [aria-current] { color: var(--text-2); }

/* --------------------------------------------------------------- sections */
.section { position: relative; padding: clamp(72px, 10vw, 130px) 0; }
.section--alt { background: var(--bg-2); }
.section--surface { background: linear-gradient(180deg, var(--bg-2), var(--bg)); }
.section--tight { padding: clamp(48px, 6vw, 80px) 0; }
.section + .section:not(.section--alt):not(.section--surface)::before { content: ""; position: absolute; top: 0; left: var(--gutter); right: var(--gutter); max-width: var(--container); margin: 0 auto; height: 1px; background: linear-gradient(90deg, transparent, var(--line-strong), transparent); }
.section-head { max-width: 760px; margin-bottom: clamp(40px, 5vw, 64px); }
.section-head--center { margin-inline: auto; text-align: center; }
.section-head--center .eyebrow { justify-content: center; }
.section-head p { font-size: 1.1rem; color: var(--muted); }
.section-head--split { max-width: none; display: flex; flex-wrap: wrap; gap: 24px 60px; align-items: flex-end; justify-content: space-between; }
.section-head--split > div { max-width: 640px; }
.section-head--split p { margin: 0; max-width: 460px; }

/* --------------------------------------------------------------- feature rows */
.feature { display: grid; grid-template-columns: 1fr 1fr; gap: clamp(32px, 6vw, 88px); align-items: center; }
.feature + .feature { margin-top: clamp(72px, 9vw, 120px); }
.feature--reverse .feature__media { order: 2; }
.feature__media { position: relative; }
.feature__media .frame { position: relative; border-radius: var(--radius-lg); overflow: hidden; aspect-ratio: 4 / 3.2; background: var(--surface); box-shadow: var(--shadow); }
.feature__media .frame img { width: 100%; height: 115%; object-fit: cover; will-change: transform; }
.feature__media .frame--contain { aspect-ratio: auto; background: #eef1f4; padding: clamp(20px, 4vw, 48px); }
.feature__media .frame--contain img { height: auto; max-height: 420px; margin: auto; object-fit: contain; }
.feature__media::after { content: ""; position: absolute; width: 46%; height: 46%; right: -18px; bottom: -18px; z-index: -1; border-radius: var(--radius-lg); border: 1px solid var(--line-strong); }
.feature--reverse .feature__media::after { right: auto; left: -18px; }
.feature__media .tag { position: absolute; left: 18px; top: 18px; }
.feature__body h2 { font-size: clamp(1.6rem, 2.8vw, 2.4rem); }
.feature__body .actions { margin-top: 28px; display: flex; gap: 12px; flex-wrap: wrap; }
.feature--text { grid-template-columns: 1fr; max-width: 860px; }

.prose ul, .checklist { list-style: none; padding: 0; margin: 0 0 1.2em; display: grid; gap: 10px; }
.prose ul li, .checklist li { position: relative; padding-left: 32px; }
.prose ul li::before, .checklist li::before {
  content: ""; position: absolute; left: 0; top: .32em; width: 20px; height: 20px; border-radius: 6px;
  background: rgba(0, 158, 224, .14) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20' fill='none' stroke='%2352cbfd' stroke-width='2.4' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m6 10.5 2.6 2.5L14 7.5'/%3E%3C/svg%3E") center / 16px no-repeat;
}
.prose ul.cols { grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 10px 28px; }

/* --------------------------------------------------------------- cards */
.grid { display: grid; gap: clamp(16px, 2vw, 24px); }
.grid--2 { grid-template-columns: repeat(2, 1fr); }
.grid--3 { grid-template-columns: repeat(3, 1fr); }
.grid--4 { grid-template-columns: repeat(4, 1fr); }
.grid--auto { grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); }
.grid--bento { grid-template-columns: repeat(12, 1fr); }
.grid--bento > * { grid-column: span 3; }
.grid--bento > :nth-child(-n + 2) { grid-column: span 6; }
.grid--bento > :nth-child(-n + 2) .card__media { aspect-ratio: 16 / 8; }
.card__media--empty { display: grid; place-items: center; background: radial-gradient(circle at 30% 20%, rgba(0, 158, 224, .25), transparent 60%), var(--surface-2); color: var(--blue-light); }
.card__media--empty svg { width: 46px; height: 46px; opacity: .8; }

.card {
  position: relative; display: flex; flex-direction: column;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  overflow: hidden; isolation: isolate;
  transition: transform .5s var(--ease-out), border-color .4s, box-shadow .5s var(--ease-out);
}
.card::before {
  content: ""; position: absolute; inset: 0; z-index: -1; opacity: 0;
  background: radial-gradient(400px circle at var(--mx, 50%) var(--my, 0%), rgba(0, 158, 224, .14), transparent 45%);
  transition: opacity .4s;
}
.card:hover { transform: translateY(-6px); border-color: var(--line-strong); box-shadow: 0 30px 60px -30px rgba(0, 0, 0, .9); }
.card:hover::before { opacity: 1; }
.card__media { aspect-ratio: 16 / 10; overflow: hidden; background: var(--surface-2); }
.card__media img { width: 100%; height: 100%; object-fit: cover; transition: transform 1.2s var(--ease-out); }
.card:hover .card__media img { transform: scale(1.06); }
.card__body { padding: 24px 24px 26px; display: flex; flex-direction: column; flex: 1; }
.card__body h3 { margin-bottom: .45em; }
.card__body p { color: var(--muted); font-size: .95rem; margin-bottom: 1.2em; }
.card__more { margin-top: auto; display: inline-flex; align-items: center; gap: 8px; font-size: .88rem; font-weight: 600; color: var(--blue-light); }
.card__more .arrow { transition: transform .4s var(--ease-out); }
.card:hover .card__more .arrow { transform: translateX(5px); }
.card--green .card__more { color: var(--green-light); }
.card--green::before { background: radial-gradient(400px circle at var(--mx, 50%) var(--my, 0%), rgba(49, 157, 60, .16), transparent 45%); }
.card--text { padding: 28px; }
.card--text .num { font: 600 .8rem/1 var(--font-sans); letter-spacing: .14em; color: var(--muted); margin-bottom: 26px; display: block; }
.card .stretched::after { content: ""; position: absolute; inset: 0; z-index: 1; }

/* divisioni */
.division { padding: 30px 28px 28px; align-items: flex-start; }
.division__logo { height: 64px; display: flex; align-items: center; margin-bottom: 22px; }
.division__logo img { max-height: 64px; width: auto; max-width: 200px; object-fit: contain; }
.division ul { list-style: none; padding: 0; margin: 0 0 24px; display: grid; gap: 6px; color: var(--muted); font-size: .93rem; }
.division ul li::before { content: "—"; margin-right: 8px; color: var(--line-strong); }
.division .bar { position: absolute; left: 0; right: 0; top: 0; height: 3px; transform: scaleX(0); transform-origin: left; transition: transform .6s var(--ease-out); }
.division:hover .bar { transform: scaleX(1); }

@keyframes cardIn { from { opacity: 0; transform: translateY(18px); } }

/* --------------------------------------------------------------- stats */
.stats { display: grid; grid-template-columns: repeat(4, 1fr); border: 1px solid var(--line); border-radius: var(--radius-lg); overflow: hidden; background: var(--surface); }
.stat { padding: clamp(28px, 4vw, 44px) clamp(20px, 3vw, 34px); position: relative; }
.stat + .stat { border-left: 1px solid var(--line); }
.stat__num { font: 600 clamp(2.4rem, 4.6vw, 3.8rem)/1 var(--font-display); letter-spacing: -.04em; color: var(--text); display: flex; align-items: baseline; gap: 2px; margin-bottom: 12px; font-variant-numeric: tabular-nums; }
.stat__num .plus { color: var(--blue); }
.stat:nth-child(2) .plus { color: var(--green); }
.stat:nth-child(3) .plus { color: var(--red-light); }
.stat__label { color: var(--muted); font-size: .95rem; margin: 0; }

/* --------------------------------------------------------------- gallery */
.gallery { display: grid; grid-template-columns: repeat(4, 1fr); grid-auto-rows: 220px; grid-auto-flow: dense; gap: 14px; }
.gallery figure { position: relative; margin: 0; border-radius: var(--radius); overflow: hidden; background: var(--surface); }
.gallery figure:nth-child(6n + 1) { grid-column: span 2; grid-row: span 2; }
.gallery figure:nth-child(6n + 4) { grid-row: span 2; }
.gallery img { width: 100%; height: 100%; object-fit: cover; transition: transform 1.2s var(--ease-out), filter .6s; }
.gallery figure:hover img { transform: scale(1.07); }
.gallery figcaption { position: absolute; inset: auto 0 0 0; padding: 40px 18px 16px; background: linear-gradient(180deg, transparent, rgba(0, 0, 0, .85)); transform: translateY(30%); opacity: 0; transition: transform .5s var(--ease-out), opacity .4s; }
.gallery figure:hover figcaption, .gallery figure:focus-within figcaption { transform: none; opacity: 1; }
.gallery figcaption strong { display: block; font-family: var(--font-display); font-size: 1.05rem; }
.gallery figcaption span { font-size: .85rem; color: var(--text-2); line-height: 1.45; display: block; }

.icon-btn { width: 46px; height: 46px; display: grid; place-items: center; border-radius: 50%; border: 1px solid var(--line-strong); background: none; cursor: pointer; color: var(--text); transition: background-color .25s, border-color .25s, transform .3s var(--ease-out); }
.icon-btn:hover { background: rgba(255, 255, 255, .06); border-color: var(--text); }
.icon-btn:active { transform: scale(.94); }

/* mosaico uffici: una foto grande e le altre attorno */
.mosaic { display: grid; grid-template-columns: repeat(4, 1fr); grid-auto-rows: 210px; gap: 14px;
  grid-template-areas: "a a b c" "a a d e" "f g h h"; }
.mosaic figure { margin: 0; border-radius: var(--radius); overflow: hidden; background: var(--surface); }
.mosaic figure:nth-child(1) { grid-area: a; } .mosaic figure:nth-child(2) { grid-area: b; }
.mosaic figure:nth-child(3) { grid-area: c; } .mosaic figure:nth-child(4) { grid-area: d; }
.mosaic figure:nth-child(5) { grid-area: e; } .mosaic figure:nth-child(6) { grid-area: f; }
.mosaic figure:nth-child(7) { grid-area: g; } .mosaic figure:nth-child(8) { grid-area: h; }
.mosaic img { width: 100%; height: 100%; object-fit: cover; transition: transform 1.2s var(--ease-out), filter .6s; }
.mosaic figure:hover img { transform: scale(1.06); }

.zoom { display: block; width: 100%; height: 100%; padding: 0; border: 0; background: none; cursor: zoom-in; position: relative; }
.zoom::after { content: ""; position: absolute; right: 12px; top: 12px; width: 34px; height: 34px; border-radius: 50%; background: rgba(11, 12, 14, .6) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='white' stroke-width='2' stroke-linecap='round'%3E%3Cpath d='M15 3h6v6M9 21H3v-6M21 3l-7 7M3 21l7-7'/%3E%3C/svg%3E") center / 15px no-repeat; backdrop-filter: blur(6px); opacity: 0; transform: scale(.8); transition: opacity .3s, transform .4s var(--ease-out); }
.zoom:hover::after, .zoom:focus-visible::after { opacity: 1; transform: none; }

.lightbox { position: fixed; inset: 0; width: 100vw; height: 100vh; max-width: none; max-height: none; margin: 0; padding: 0; border: 0; background: rgba(5, 6, 8, .94); color: var(--text); display: none; place-items: center; }
.lightbox[open] { display: grid; animation: lbIn .35s var(--ease-out); }
.lightbox::backdrop { background: transparent; }
@keyframes lbIn { from { opacity: 0; } }
.lightbox figure { margin: 0; display: flex; flex-direction: column; align-items: center; gap: 14px; max-width: min(92vw, 1400px); }
.lightbox img { max-width: 100%; max-height: 80vh; width: auto; border-radius: var(--radius); box-shadow: 0 40px 80px -30px #000; animation: lbImg .5s var(--ease-out); }
@keyframes lbImg { from { opacity: 0; transform: scale(.96); } }
.lightbox figcaption { font-size: .92rem; color: var(--text-2); text-align: center; min-height: 1.4em; }
.lightbox figcaption .count { color: var(--muted); margin-left: 10px; font-variant-numeric: tabular-nums; }
.lightbox .icon-btn { position: absolute; background: rgba(22, 24, 27, .7); }
.lightbox .lb-close { top: 20px; right: 20px; }
.lightbox .lb-prev { left: 20px; top: 50%; transform: translateY(-50%); }
.lightbox .lb-next { right: 20px; top: 50%; transform: translateY(-50%); }
.lightbox .lb-prev:active, .lightbox .lb-next:active { transform: translateY(-50%) scale(.94); }

/* --------------------------------------------------------------- statement (statua) */
.statement { display: grid; grid-template-columns: 1.05fr 1fr; gap: clamp(32px, 6vw, 90px); align-items: center; }
.statement__media { position: relative; border-radius: var(--radius-lg); overflow: hidden; aspect-ratio: 4 / 5; }
.statement__media img { width: 100%; height: 118%; object-fit: cover; will-change: transform; }
.statement blockquote { margin: 28px 0 0; padding: 22px 26px; border-left: 3px solid var(--blue); background: var(--surface); border-radius: 0 var(--radius) var(--radius) 0; font-family: var(--font-display); font-size: 1.2rem; color: var(--text); line-height: 1.45; }

/* --------------------------------------------------------------- team */
.team { display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; }
.member { position: relative; border-radius: var(--radius-lg); overflow: hidden; background: var(--surface); border: 1px solid var(--line); display: flex; flex-direction: column; }
.member__photo { aspect-ratio: 4 / 4.4; overflow: hidden; }
.member__photo img { width: 100%; height: 100%; object-fit: cover; object-position: top; filter: grayscale(.35); transition: filter .6s, transform 1.2s var(--ease-out); }
.member:hover .member__photo img { filter: none; transform: scale(1.04); }
.member__body { padding: 24px; }
.member__role { color: var(--blue-light); font-size: .85rem; font-weight: 600; letter-spacing: .06em; text-transform: uppercase; margin-bottom: 14px; display: block; }
.member__body p { color: var(--muted); font-size: .95rem; }
.member__body p:last-child { margin: 0; }

/* --------------------------------------------------------------- CTA & form */
.cta { position: relative; border-radius: calc(var(--radius-lg) + 6px); overflow: hidden; isolation: isolate; border: 1px solid var(--line); background: var(--surface); display: grid; grid-template-columns: 1fr 1.1fr; }
.cta__intro { position: relative; padding: clamp(32px, 5vw, 64px); display: flex; flex-direction: column; justify-content: space-between; gap: 32px; overflow: hidden; }
.cta__bg { position: absolute; inset: 0; z-index: -1; background: center / cover no-repeat; opacity: .28; transform: scale(1.08); transition: transform 2.4s var(--ease-out); }
.cta.is-visible .cta__bg { transform: scale(1); }
.cta__intro::after { content: ""; position: absolute; inset: 0; z-index: -1; background: linear-gradient(160deg, rgba(0, 158, 224, .22), rgba(11, 12, 14, .7) 55%); }
.cta__intro h2 { margin-bottom: .4em; }
.contact-list { list-style: none; padding: 0; margin: 0; display: grid; gap: 14px; }
.contact-list li { display: flex; gap: 14px; align-items: flex-start; font-size: .95rem; }
.contact-list .ci { flex-shrink: 0; width: 38px; height: 38px; display: grid; place-items: center; border-radius: 10px; background: rgba(255, 255, 255, .06); border: 1px solid var(--line); color: var(--blue-light); }
.contact-list .ci svg { width: 18px; height: 18px; }
.contact-list small { display: block; color: var(--muted); font-size: .78rem; text-transform: uppercase; letter-spacing: .1em; }
.contact-list a:hover { color: var(--text); }
.cta__form { padding: clamp(32px, 5vw, 64px); border-left: 1px solid var(--line); background: var(--bg-2); }

.form { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.field { display: flex; flex-direction: column; gap: 7px; }
.field--full { grid-column: 1 / -1; }
.field label { font-size: .82rem; font-weight: 500; color: var(--text-2); }
.field input, .field select, .field textarea {
  width: 100%; padding: 13px 15px;
  background: var(--surface); border: 1px solid var(--line-strong); border-radius: 10px;
  transition: border-color .25s, box-shadow .25s, background-color .25s;
}
.field textarea { min-height: 130px; resize: vertical; }
.field select { appearance: none; background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 12 12'%3E%3Cpath d='M2 4l4 4 4-4' fill='none' stroke='%238f99a5' stroke-width='1.6'/%3E%3C/svg%3E"); background-repeat: no-repeat; background-position: right 14px center; background-size: 12px; padding-right: 40px; }
.field input:focus, .field select:focus, .field textarea:focus { outline: none; border-color: var(--blue); box-shadow: 0 0 0 4px rgba(0, 158, 224, .18); background: var(--surface-2); }
.check { grid-column: 1 / -1; display: flex; gap: 12px; align-items: flex-start; font-size: .85rem; color: var(--muted); line-height: 1.5; }
.check input { margin-top: 3px; width: 18px; height: 18px; accent-color: var(--blue); flex-shrink: 0; }
.form .btn { justify-self: start; }
.hp { position: absolute !important; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
.field input[type="file"] { padding: 10px; cursor: pointer; color: var(--muted); }
.field input[type="file"]::file-selector-button { margin-right: 14px; padding: 8px 14px; border: 1px solid var(--line-strong); border-radius: 999px; background: var(--surface-2); color: var(--text); font: 500 .85rem var(--font-sans); cursor: pointer; transition: border-color .25s; }
.field input[type="file"]:hover::file-selector-button { border-color: var(--blue); }
.form .btn[disabled] { opacity: .65; cursor: progress; transform: none; }
.form .btn .spinner { width: 16px; height: 16px; border-radius: 50%; border: 2px solid rgba(255, 255, 255, .35); border-top-color: #fff; animation: spin .8s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }
.form-note.is-error { color: var(--red-light); }
.form-success { grid-column: 1 / -1; text-align: center; padding: 40px 10px; animation: cardIn .8s var(--ease-out) both; }
.form-success .check-circle { width: 64px; height: 64px; margin: 0 auto 20px; border-radius: 50%; display: grid; place-items: center; background: rgba(49, 157, 60, .16); color: var(--green-light); }
.form-success .check-circle svg { width: 30px; height: 30px; stroke-dasharray: 30; stroke-dashoffset: 30; animation: draw .7s .25s var(--ease-out) forwards; }
@keyframes draw { to { stroke-dashoffset: 0; } }
.form-success h3 { margin-bottom: .4em; }
.form-success p { color: var(--muted); margin: 0; }
.form-note { grid-column: 1 / -1; font-size: .85rem; color: var(--green-light); margin: 0; min-height: 1.2em; }

/* --------------------------------------------------------------- footer */
.site-footer { position: relative; background: var(--bg-2); border-top: 1px solid var(--line); padding: 80px 0 36px; font-size: .93rem; }
.site-footer::before { content: ""; position: absolute; top: -1px; left: 0; right: 0; height: 3px; background: var(--brand-gradient); }
.footer-grid { display: grid; grid-template-columns: 1.4fr 1fr 1fr 1fr; gap: 40px; }
.footer-brand img { height: 34px; width: auto; margin-bottom: 20px; }
.footer-brand p { color: var(--muted); max-width: 340px; }
.footer-col h4 { font-family: var(--font-sans); font-size: .78rem; font-weight: 600; text-transform: uppercase; letter-spacing: .14em; color: var(--muted); margin-bottom: 18px; }
.footer-col ul { list-style: none; padding: 0; margin: 0; display: grid; gap: 10px; }
.footer-col a { color: var(--text-2); transition: color .2s; }
.footer-col a:hover { color: var(--blue-light); }
.footer-badges { display: flex; gap: 16px; align-items: center; margin-top: 24px; }
.footer-badges img { height: 46px; width: auto; opacity: .9; }
.footer-bottom { margin-top: 56px; padding-top: 26px; border-top: 1px solid var(--line); display: flex; flex-wrap: wrap; gap: 14px 32px; justify-content: space-between; color: var(--muted); font-size: .8rem; line-height: 1.6; }
.footer-bottom p { margin: 0; max-width: 820px; }
.footer-bottom a { color: var(--text-2); }
.footer-bottom a:hover { color: var(--blue-light); }

.to-top { position: fixed; right: 20px; bottom: 20px; z-index: 90; width: 48px; height: 48px; padding: 0; border-radius: 50%; border: 0; background: rgba(22, 24, 27, .85); backdrop-filter: blur(10px); color: var(--text); display: grid; place-items: center; cursor: pointer; opacity: 0; transform: translateY(16px); pointer-events: none; transition: opacity .3s, transform .4s var(--ease-out), border-color .25s; }
.to-top.is-visible { opacity: 1; transform: none; pointer-events: auto; }
.to-top > svg:not(.ring) { width: 18px; height: 18px; transition: transform .3s var(--ease-out); }
.to-top:hover > svg:not(.ring) { transform: translateY(-2px); }
.to-top .ring { position: absolute; inset: 0; width: 100%; height: 100%; transform: rotate(-90deg); pointer-events: none; }
.to-top .ring circle { fill: none; stroke-width: 2; }
.to-top .ring__track { stroke: var(--line-strong); }
.to-top .ring__bar { stroke: var(--blue); stroke-linecap: round; stroke-dasharray: 100; stroke-dashoffset: calc(100 - 100 * var(--p, 0)); transition: stroke-dashoffset .1s linear; }

/* --------------------------------------------------------------- misc pages */
.info-cards { display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px; margin-bottom: 40px; }
.info-card { padding: 24px; border-radius: var(--radius); background: var(--surface); border: 1px solid var(--line); }
.info-card .ci { width: 42px; height: 42px; border-radius: 12px; display: grid; place-items: center; background: rgba(0, 158, 224, .12); color: var(--blue-light); margin-bottom: 18px; }
.info-card .ci svg { width: 20px; height: 20px; }
.info-card h3 { font-size: 1rem; font-family: var(--font-sans); font-weight: 600; margin-bottom: 6px; }
.info-card p { margin: 0; color: var(--muted); font-size: .93rem; }
.info-card a:hover { color: var(--text); }
.map { border-radius: var(--radius-lg); overflow: hidden; border: 1px solid var(--line); aspect-ratio: 21 / 8; background: var(--surface); }
.map iframe { width: 100%; height: 100%; border: 0; filter: grayscale(1) invert(.92) contrast(.85); }

.sitemap-cols { display: grid; grid-template-columns: repeat(3, 1fr); gap: 32px; }
.sitemap-cols h2 { font-size: 1.2rem; }
.sitemap-cols ul { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; }
.sitemap-cols a { color: var(--text-2); }
.sitemap-cols a:hover { color: var(--blue-light); }

.notfound { min-height: 100svh; display: grid; place-items: center; text-align: center; padding: calc(var(--header-h) + 40px) 0 80px; background: var(--glow); }
.notfound .code { font: 700 clamp(6rem, 22vw, 14rem)/1 var(--font-display); letter-spacing: -.06em; background: linear-gradient(180deg, var(--text), rgba(255, 255, 255, .05)); -webkit-background-clip: text; background-clip: text; color: transparent; margin-bottom: 10px; }

.course-list { display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: 14px; }
.course { display: flex; gap: 16px; align-items: center; padding: 18px 20px; border-radius: var(--radius); background: var(--surface); border: 1px solid var(--line); transition: border-color .3s, transform .4s var(--ease-out); }
.course:hover { border-color: var(--line-strong); transform: translateY(-3px); }
.course .emoji { font-size: 1.5rem; width: 48px; height: 48px; flex-shrink: 0; display: grid; place-items: center; border-radius: 12px; background: var(--surface-2); }
.course strong { display: block; font-size: .98rem; }
.course span { font-size: .85rem; color: var(--muted); }

.logo-strip { display: flex; flex-wrap: wrap; gap: 20px 40px; align-items: center; }
.logo-strip img { max-height: 70px; width: auto; }

/* --------------------------------------------------------------- reveal on scroll */
[data-reveal] { opacity: 0; transition: opacity 1s var(--ease-out), transform 1.1s var(--ease-out), clip-path 1.3s var(--ease-out), filter 1s var(--ease-out); transition-delay: var(--delay, 0ms); will-change: opacity, transform; }
[data-reveal="up"] { transform: translateY(36px); }
[data-reveal="down"] { transform: translateY(-24px); }
[data-reveal="left"] { transform: translateX(-48px); }
[data-reveal="right"] { transform: translateX(48px); }
[data-reveal="zoom"] { transform: scale(.94); }
[data-reveal="blur"] { filter: blur(12px); transform: translateY(16px); }
/* il clip va sui figli: un elemento osservato con clip-path chiuso non risulta mai "intersecante" */
[data-reveal="clip"], [data-reveal="clip-x"] { opacity: 1; }
[data-reveal="clip"] > *, [data-reveal="clip-x"] > * { transition: clip-path 1.4s var(--ease-out), transform 1.6s var(--ease-out); transition-delay: var(--delay, 0ms); }
[data-reveal="clip"] > * { clip-path: inset(100% 0 0 0 round var(--radius-lg)); }
[data-reveal="clip-x"] > * { clip-path: inset(0 100% 0 0 round var(--radius-lg)); }
[data-reveal="clip"].is-visible > *, [data-reveal="clip-x"].is-visible > * { clip-path: inset(0 0 0 0 round var(--radius-lg)); }
[data-reveal].is-visible { opacity: 1; transform: none; filter: none; }
.no-js [data-reveal], .no-js [data-reveal] > * { opacity: 1; transform: none; clip-path: none; filter: none; }

/* --------------------------------------------------------------- responsive */
@media (max-width: 1100px) {
  .social { display: none; }
  .grid--4, .info-cards { grid-template-columns: repeat(2, 1fr); }
  .grid--bento > *, .grid--bento > :nth-child(-n + 2) { grid-column: span 6; }
  .footer-grid { grid-template-columns: 1fr 1fr; }
  .gallery { grid-template-columns: repeat(3, 1fr); }
  .gallery figure:nth-child(6n + 1) { grid-column: span 2; }
}
@media (max-width: 960px) {
  :root { --header-h: 68px; }
  .burger { display: block; }
  .main-nav {
    position: fixed; inset: 0; z-index: -1;
    background: rgba(11, 12, 14, .97); backdrop-filter: blur(20px);
    padding: calc(var(--header-h) + 20px) var(--gutter) 40px;
    overflow-y: auto;
    opacity: 0; visibility: hidden;
    transition: opacity .35s, visibility 0s .35s;
  }
  .nav-open .main-nav { opacity: 1; visibility: visible; transition-delay: 0s; }
  .main-nav > ul { flex-direction: column; align-items: stretch; gap: 0; }
  .main-nav > ul > li { border-bottom: 1px solid var(--line); opacity: 0; transform: translateY(14px); transition: opacity .4s, transform .5s var(--ease-out); transition-delay: calc(var(--i) * 45ms + 80ms); }
  .nav-open .main-nav > ul > li { opacity: 1; transform: none; }
  .nav-link { width: 100%; justify-content: space-between; padding: 18px 4px; font-size: 1.25rem; font-family: var(--font-display); border-radius: 0; }
  .nav-link:hover { background: none; }
  .nav-link[aria-current="page"]::after, .nav-item.is-active > .nav-link::after { display: none; }
  .nav-link .chev { width: 14px; height: 14px; }
  .nav-item:hover .chev { transform: none; }
  .nav-item.is-open .chev { transform: rotate(180deg); }
  .mega {
    position: static; width: auto; transform: none; opacity: 1; visibility: visible;
    grid-template-columns: 1fr; padding: 0 0 14px; background: none; border: 0; box-shadow: none; backdrop-filter: none;
    display: none;
  }
  .nav-item:hover > .mega, .nav-item:focus-within > .mega { transform: none; }
  .nav-item.is-open > .mega { display: grid; }
  .mega-head { display: none; }
  .header-actions .btn { display: none; }
  .feature, .statement, .cta { grid-template-columns: 1fr; }
  .feature--reverse .feature__media { order: 0; }
  .feature__media::after { display: none; }
  .cta__form { border-left: 0; border-top: 1px solid var(--line); }
  .grid--3 { grid-template-columns: repeat(2, 1fr); }
  .team { grid-template-columns: 1fr 1fr; }
  .stats { grid-template-columns: 1fr 1fr; }
  .stat:nth-child(3) { border-left: 0; }
  .stat:nth-child(n + 3) { border-top: 1px solid var(--line); }
  .sitemap-cols { grid-template-columns: 1fr 1fr; }
  .statement__media { aspect-ratio: 4 / 3; }
}
@media (max-width: 640px) {
  .grid--2, .grid--3, .grid--4, .team, .info-cards, .sitemap-cols { grid-template-columns: 1fr; }
  .grid--bento > *, .grid--bento > :nth-child(-n + 2) { grid-column: 1 / -1; }
  .footer-grid { grid-template-columns: 1fr; gap: 32px; }
  .form { grid-template-columns: 1fr; }
  .gallery { grid-template-columns: 1fr 1fr; grid-auto-rows: 160px; gap: 10px; }
  .gallery figure:nth-child(6n + 1) { grid-column: span 2; grid-row: span 1; }
  .gallery figure:nth-child(6n + 4) { grid-row: span 1; }
  .gallery figcaption { opacity: 1; transform: none; padding: 30px 12px 10px; }
  .gallery figcaption span { display: none; }
  .mosaic { grid-template-columns: 1fr 1fr; grid-auto-rows: 150px; grid-template-areas: "a a" "a a" "b c" "d e" "f g" "h h"; gap: 10px; }
  .lightbox .lb-prev, .lightbox .lb-next { top: auto; bottom: 20px; transform: none; }
  .lightbox .lb-prev:active, .lightbox .lb-next:active { transform: scale(.94); }
  .hero-badges { gap: 18px; }
  .page-hero { min-height: 56vh; padding-bottom: 48px; }
  .map { aspect-ratio: 4 / 3; }
  .scroll-cue { display: none; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .01ms !important; animation-iteration-count: 1 !important; transition-duration: .01ms !important; scroll-behavior: auto !important; }
  [data-reveal], [data-reveal] > *, .split .w > span { opacity: 1 !important; transform: none !important; clip-path: none !important; filter: none !important; }
}

.mobile-only { display: none !important; }
@media (max-width: 960px) { .mega .mobile-only { display: flex !important; } }
@media (max-width: 700px) {
  .hero:not(.hero--video)::before { background: linear-gradient(180deg, rgba(11, 12, 14, .7) 0%, rgba(11, 12, 14, .82) 50%, var(--bg) 100%); }
}


/* ==========================================================================
   Effetti "tech": card in 3D, bordi luminosi, pulsanti magnetici
   ========================================================================== */
@property --spin { syntax: "<angle>"; inherits: false; initial-value: 0deg; }
.card {
  transform: perspective(1000px) rotateX(var(--rx, 0deg)) rotateY(var(--ry, 0deg)) translateY(var(--ty, 0px));
  transition: transform .45s var(--ease-out), border-color .4s, box-shadow .5s var(--ease-out);
}
.card:hover { --ty: -6px; transform: perspective(1000px) rotateX(var(--rx, 0deg)) rotateY(var(--ry, 0deg)) translateY(var(--ty)); }
.card::after {
  content: ""; position: absolute; inset: 0; z-index: 2; pointer-events: none; border-radius: inherit; padding: 1px;
  background: conic-gradient(from var(--spin), transparent 0 62%, var(--blue-light) 75%, var(--green-light) 85%, transparent 95%);
  -webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0); -webkit-mask-composite: xor;
  mask: linear-gradient(#000 0 0) content-box exclude, linear-gradient(#000 0 0);
  opacity: 0; transition: opacity .5s;
}
.card:hover::after { opacity: 1; animation: spin 3.2s linear infinite; }
.card--green::after { background: conic-gradient(from var(--spin), transparent 0 62%, var(--green-light) 75%, var(--blue-light) 85%, transparent 95%); }
@keyframes spin { to { --spin: 360deg; } }
.btn.is-magnetic { transition: transform .25s var(--ease-out), box-shadow .4s var(--ease-out), background-color .3s; }
.btn--light { --btn-bg: #fff; color: #0b0c0e; }
.btn--light:hover { box-shadow: 0 14px 34px -12px rgba(255, 255, 255, .45); }

/* titoli decodificati */
[data-decode] .dc { color: var(--blue-light); font-family: var(--font-mono); font-weight: 400; }
.theme-tech .eyebrow { font-family: var(--font-mono); text-transform: none; letter-spacing: .02em; font-weight: 500; font-size: .85rem; }
.theme-tech .eyebrow::before { content: "//"; width: auto; height: auto; background: none; color: var(--muted); }

/* ==========================================================================
   Console dei numeri
   ========================================================================== */
.console { border: 1px solid var(--line-strong); border-radius: var(--radius-lg); background: linear-gradient(180deg, #121417, #0d0f12); overflow: hidden; box-shadow: 0 40px 80px -50px rgba(0, 158, 224, .5); }
.console__bar { display: flex; align-items: center; gap: 16px; padding: 12px 18px; border-bottom: 1px solid var(--line); background: rgba(255, 255, 255, .02); font: 500 .82rem/1 var(--font-mono); color: var(--muted); }
.console__dots { display: inline-flex; gap: 7px; }
.console__dots i { width: 11px; height: 11px; border-radius: 50%; background: var(--green); }
.console__dots i:nth-child(2) { background: var(--blue); }
.console__dots i:nth-child(3) { background: var(--red); }
.console__typed { color: var(--text); }
.console__caret { display: inline-block; width: 8px; height: 1em; margin-left: 2px; vertical-align: -2px; background: var(--blue-light); animation: blink 1s steps(1) infinite; }
@keyframes blink { 50% { opacity: 0; } }
.console__grid { display: grid; grid-template-columns: repeat(4, 1fr); }
.console__cell { position: relative; padding: 28px 26px 22px; }
.console__cell + .console__cell { border-left: 1px solid var(--line); }
.console__key { display: block; font: 400 .78rem/1 var(--font-mono); color: var(--blue-light); margin-bottom: 18px; opacity: .85; }
.console__key::before { content: "> "; color: var(--muted); }
.console .stat__num { margin-bottom: 8px; }
.console__wave { width: 100%; height: 34px; margin-top: 16px; overflow: visible; }
.console__wave path { fill: none; stroke: var(--blue); stroke-width: 1.6; stroke-linecap: round; stroke-dasharray: 1; stroke-dashoffset: 1; opacity: .7; transition: stroke-dashoffset 2.2s var(--ease-out) .3s; }
.console__cell:nth-child(2) .console__wave path { stroke: var(--green); }
.console__cell:nth-child(3) .console__wave path { stroke: var(--red-light); }
.console.is-visible .console__wave path { stroke-dashoffset: 0; }
.console__foot { padding: 10px 18px; border-top: 1px solid var(--line); font: 400 .75rem/1.4 var(--font-mono); color: var(--muted); }

/* ==========================================================================
   Banner di contatto per divisione
   ========================================================================== */
.banner { --c: var(--blue); --c2: var(--blue-light);
  position: relative; isolation: isolate; overflow: hidden;
  display: grid; grid-template-columns: auto 1fr auto; gap: clamp(24px, 4vw, 56px); align-items: center;
  padding: clamp(32px, 5vw, 56px) clamp(28px, 5vw, 64px);
  border-radius: calc(var(--radius-lg) + 6px); border: 1px solid var(--line-strong); background: var(--surface);
}
.banner--green { --c: var(--green); --c2: var(--green-light); }
.banner--red { --c: var(--red); --c2: var(--red-light); }
.banner--brand { --c: var(--blue); --c2: var(--green-light); }
.banner__bg { position: absolute; inset: 0; z-index: -2; background: center / cover no-repeat; opacity: .22; transform: scale(1.08); transition: transform 2.4s var(--ease-out); }
.banner.is-visible .banner__bg { transform: scale(1); }
.banner::before { content: ""; position: absolute; inset: 0; z-index: -1; background: linear-gradient(100deg, rgba(11, 12, 14, .95) 0%, rgba(11, 12, 14, .8) 45%, color-mix(in srgb, var(--c) 35%, transparent) 100%); }
.banner::after { content: ""; position: absolute; left: 0; right: 0; top: 0; height: 3px; background: linear-gradient(90deg, var(--c), var(--c2)); }
.banner--brand::after { background: var(--brand-gradient); }
.banner__glow { position: absolute; z-index: -1; width: 520px; height: 520px; right: -140px; top: -260px; border-radius: 50%; background: radial-gradient(circle, color-mix(in srgb, var(--c2) 45%, transparent), transparent 65%); filter: blur(10px); animation: glow 9s var(--ease-in-out) infinite alternate; }
@keyframes glow { to { transform: translate(-80px, 60px) scale(1.15); } }
.banner__logo { width: clamp(120px, 14vw, 190px); padding: 18px; border-radius: var(--radius); background: rgba(255, 255, 255, .04); border: 1px solid var(--line); }
.banner__logo img { width: 100%; height: auto; max-height: 90px; object-fit: contain; }
.banner__body h2 { font-size: clamp(1.6rem, 3vw, 2.4rem); margin-bottom: .35em; }
.banner__body p { margin: 0; max-width: 560px; color: var(--text-2); }
.banner__body .eyebrow { color: var(--c2); }
.banner__actions { display: flex; flex-direction: column; align-items: flex-start; gap: 16px; }
.banner__phone { display: inline-flex; align-items: center; gap: 10px; font-weight: 500; color: var(--text-2); transition: color .2s; }
.banner__phone:hover { color: var(--text); }
.banner__phone svg { width: 18px; height: 18px; color: var(--c2); }

/* ==========================================================================
   Partner e fornitori
   ========================================================================== */
.partners { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(6, 1fr); gap: 14px; }
.partner { height: 130px; display: grid; place-items: center; padding: 22px; border-radius: var(--radius); background: var(--surface); border: 1px solid var(--line); transition: background-color .45s, border-color .45s, transform .5s var(--ease-out), box-shadow .5s var(--ease-out); }
.partner img { max-height: 58px; max-width: 78%; width: auto; object-fit: contain; filter: brightness(0) invert(1); opacity: .7; transition: filter .45s, opacity .45s, transform .5s var(--ease-out); }
.partner:hover { background: #f4f6f8; border-color: #fff; transform: translateY(-4px); box-shadow: 0 24px 50px -28px rgba(0, 0, 0, .9); }
.partner:hover img { filter: none; opacity: 1; transform: scale(1.05); }
.partner--solid img { filter: grayscale(1) brightness(.9) contrast(1.2); }

/* ==========================================================================
   Informatica: rete che si costruisce scorrendo
   ========================================================================== */
.netbuild { position: relative; height: 420vh; background: radial-gradient(70% 50% at 70% 40%, rgba(0, 158, 224, .1), transparent 70%), var(--bg); }
.netbuild__sticky { position: sticky; top: 0; height: 100vh; display: flex; align-items: center; overflow: hidden; }
.netbuild__grid { display: grid; grid-template-columns: .85fr 1.5fr; gap: clamp(28px, 4vw, 64px); align-items: center; }
.netbuild__text h2 { font-size: clamp(1.7rem, 2.8vw, 2.5rem); }
.netbuild__progress { height: 2px; background: var(--line); border-radius: 2px; margin: 4px 0 18px; overflow: hidden; }
.netbuild__progress span { display: block; height: 100%; background: linear-gradient(90deg, var(--blue), var(--green-light)); transform-origin: left; transform: scaleX(var(--p, 0)); }
.net-steps { list-style: none; margin: 0; padding: 0; display: grid; gap: 2px; }
.net-step { display: grid; grid-template-columns: 36px 1fr; gap: 10px; padding: 10px 12px; border-radius: 12px; opacity: .38; transition: opacity .4s, background-color .4s; }
.net-step.is-done { opacity: .6; }
.net-step.is-current { opacity: 1; background: rgba(0, 158, 224, .08); }
.net-step__num { font: 500 .8rem/1.6 var(--font-mono); color: var(--blue-light); }
.net-step h3 { font-size: 1rem; margin: 0; font-family: var(--font-sans); font-weight: 600; }
.net-step p { margin: 0; font-size: .88rem; color: var(--muted); line-height: 1.5; max-height: 0; overflow: hidden; transition: max-height .5s var(--ease-out), margin .4s; }
.net-step.is-current p { max-height: 6em; margin-top: 4px; }
.net-step__links a { color: var(--blue-light); font-size: .85rem; margin-right: 10px; pointer-events: none; }
.net-step.is-current .net-step__links a { pointer-events: auto; }
.net-step__links a:hover { text-decoration: underline; }
.net-svg { width: 100%; height: auto; max-height: 82vh; overflow: visible; }
.net-node { opacity: 0; transform: translateY(14px) scale(.92); transform-box: fill-box; transform-origin: center; transition: opacity .6s var(--ease-out), transform .7s var(--ease-out); }
.net-node.on { opacity: 1; transform: none; }
.net-node rect { fill: #15181c; stroke: var(--line-strong); stroke-width: 1.2; transition: stroke .4s, fill .4s; }
.net-node.is-current rect { stroke: var(--blue-light); fill: #10202b; filter: drop-shadow(0 0 14px rgba(82, 203, 253, .45)); }
.net-icon { fill: none; stroke: var(--blue-light); stroke-width: 1.7; stroke-linecap: round; stroke-linejoin: round; }
.net-node text { fill: var(--text); font: 500 14px var(--font-sans); }
.net-edge { fill: none; stroke: rgba(82, 203, 253, .55); stroke-width: 1.6; stroke-dasharray: 1; stroke-dashoffset: 1; transition: stroke-dashoffset 1s var(--ease-out); }
.net-edge.on { stroke-dashoffset: 0; }
.net-edge--dashed { stroke-dasharray: .025 .02; stroke-dashoffset: 0; opacity: 0; transition: opacity .8s; }
.net-edge--dashed.on { opacity: 1; animation: dash 6s linear infinite; }
@keyframes dash { to { stroke-dashoffset: -1; } }
.net-packets circle { fill: #9be3ff; }
.net-grid line { stroke: rgba(255, 255, 255, .035); }

/* ==========================================================================
   Informatica: il metodo (pannello fisso + fasi)
   ========================================================================== */
.process__grid { display: grid; grid-template-columns: 1fr 1fr; gap: clamp(32px, 6vw, 90px); }
.process__sticky { position: sticky; top: calc(var(--header-h) + 40px); align-self: start; }
.terminal { border: 1px solid var(--line-strong); border-radius: var(--radius-lg); background: linear-gradient(180deg, #121417, #0d0f12); overflow: hidden; box-shadow: 0 40px 80px -50px rgba(0, 158, 224, .5); }
.terminal__title { font: 500 .82rem/1 var(--font-mono); color: var(--muted); }
.terminal__body { padding: 28px 28px 10px; min-height: 260px; }
.terminal__phase { display: flex; align-items: baseline; gap: 16px; margin-bottom: 20px; }
.terminal__num { font: 600 3.4rem/1 var(--font-display); background: linear-gradient(180deg, var(--blue-light), var(--blue)); -webkit-background-clip: text; background-clip: text; color: transparent; }
.terminal__name { font: 600 1.5rem/1.1 var(--font-display); color: var(--text); }
.terminal__log { margin: 0; font: 400 .88rem/1.9 var(--font-mono); color: var(--text-2); white-space: pre-wrap; min-height: 7.6em; }
.terminal__log .ok { color: var(--green-light); }
.terminal__log .cmd { color: var(--blue-light); }
.process__dots { display: grid; grid-template-columns: repeat(4, 1fr); border-top: 1px solid var(--line); }
.process__dot { position: relative; padding: 14px 12px; font-size: .8rem; color: var(--muted); transition: color .3s; }
.process__dot b { display: block; font: 500 .72rem/1 var(--font-mono); margin-bottom: 4px; }
.process__dot::before { content: ""; position: absolute; left: 0; right: 0; top: -1px; height: 2px; background: var(--blue); transform: scaleX(0); transform-origin: left; transition: transform .6s var(--ease-out); }
.process__dot.is-done::before, .process__dot.is-current::before { transform: none; }
.process__dot.is-current { color: var(--text); }
.process__steps { display: grid; gap: 0; }
.pstep { min-height: 62vh; padding: 40px 0; display: flex; flex-direction: column; justify-content: center; opacity: .3; transition: opacity .5s; }
.pstep.is-current { opacity: 1; }
.pstep__num { font: 500 .85rem/1 var(--font-mono); color: var(--blue-light); margin-bottom: 14px; }
.pstep h3 { font-size: clamp(1.6rem, 2.6vw, 2.2rem); }
.pstep p { color: var(--text-2); font-size: 1.05rem; max-width: 520px; }

/* ==========================================================================
   Chi siamo: storia in orizzontale guidata dallo scorrimento
   ========================================================================== */
.htl { position: relative; background: linear-gradient(180deg, var(--bg), var(--bg-2)); }
.htl__sticky { position: sticky; top: 0; height: 100vh; display: flex; flex-direction: column; justify-content: center; gap: clamp(28px, 5vh, 56px); overflow: hidden; padding-top: var(--header-h); }
.htl__head { display: flex; flex-wrap: wrap; gap: 24px 60px; align-items: flex-end; justify-content: space-between; }
.htl__head h2 { margin: 0; }
.htl__marks { position: relative; list-style: none; margin: 0; padding: 0; display: flex; gap: clamp(20px, 4vw, 54px); }
.htl__line { position: absolute; left: 6px; right: 6px; top: 6px; height: 2px; background: var(--line-strong); border-radius: 2px; }
.htl__fill { position: absolute; inset: 0; background: linear-gradient(90deg, var(--green), var(--blue), var(--red)); transform-origin: left; transform: scaleX(var(--p, 0)); border-radius: 2px; }
.htl__marks li { position: relative; padding-top: 22px; font: 500 .8rem/1 var(--font-mono); color: var(--muted); transition: color .3s; }
.htl__marks li::before { content: ""; position: absolute; left: 0; top: 0; width: 14px; height: 14px; border-radius: 50%; background: var(--bg); border: 2px solid var(--line-strong); transition: border-color .3s, background-color .3s, transform .4s var(--ease-out); }
.htl__marks li.is-done::before { border-color: var(--blue); background: var(--blue); }
.htl__marks li.is-current { color: var(--text); }
.htl__marks li.is-current::before { transform: scale(1.3); box-shadow: 0 0 0 5px rgba(0, 158, 224, .2); }
.htl__viewport { overflow: visible; }
.htl__track { display: flex; gap: clamp(20px, 3vw, 40px); padding: 0 max(var(--gutter), calc((100vw - var(--container)) / 2)); will-change: transform; }
.htl__item { --f: 1; position: relative; flex: 0 0 min(500px, 78vw); padding-top: clamp(40px, 9vh, 90px); opacity: calc(.35 + .65 * var(--f)); transform: scale(calc(.94 + .06 * var(--f))); transform-origin: left bottom; transition: opacity .2s linear; }
.htl__year { position: absolute; left: -6px; top: 0; font: 700 clamp(4.5rem, 11vh, 8rem)/1 var(--font-display); letter-spacing: -.05em; color: transparent; -webkit-text-stroke: 1.5px rgba(255, 255, 255, .14); z-index: 0; user-select: none; }
.htl__card { position: relative; z-index: 1; padding: 28px; border-radius: var(--radius-lg); background: rgba(22, 24, 27, .92); border: 1px solid var(--line); backdrop-filter: blur(6px); }
.htl__visual { display: flex; gap: 18px; align-items: center; height: 64px; margin-bottom: 22px; }
.htl__visual img { max-height: 58px; width: auto; max-width: 46%; object-fit: contain; }
.htl__card time { display: block; font: 500 .8rem/1 var(--font-mono); color: var(--blue-light); margin-bottom: 10px; }
.htl__card h3 { margin-bottom: .45em; }
.htl__card p { margin: 0; color: var(--text-2); font-size: .97rem; }
/* versione verticale: schermi piccoli o movimento ridotto */
.htl--static .htl__sticky { position: static; height: auto; padding: clamp(72px, 10vw, 130px) 0; }
.htl--static .htl__marks { display: none; }
.htl--static .htl__track { flex-direction: column; padding: 0 var(--gutter); max-width: calc(var(--container) + var(--gutter) * 2); margin: 0 auto; transform: none !important; }
.htl--static .htl__item { flex: none; width: 100%; max-width: 720px; opacity: 1; transform: none; }

@media (max-width: 1100px) {
  .partners { grid-template-columns: repeat(4, 1fr); }
  .console__grid { grid-template-columns: 1fr 1fr; }
  .console__cell:nth-child(3) { border-left: 0; }
  .console__cell:nth-child(n + 3) { border-top: 1px solid var(--line); }
}
@media (max-width: 960px) {
  .banner { grid-template-columns: 1fr; }
  .netbuild { height: 480vh; }
  .netbuild__grid { grid-template-columns: 1fr; gap: 10px; }
  .netbuild__diagram { order: -1; }
  .net-svg { width: 100%; height: 46vh; max-height: none; overflow: hidden; }
  .netbuild__diagram { border: 1px solid var(--line); border-radius: var(--radius-lg); background: rgba(255, 255, 255, .015); }
  .netbuild__text h2 { font-size: 1.35rem; margin-bottom: .3em; }
  .netbuild__text .eyebrow { display: none; }
  .net-step { display: none; }
  .net-step.is-current { display: grid; }
  .process__grid { grid-template-columns: 1fr; }
  .process__sticky { position: relative; top: auto; }
  .pstep { min-height: 0; opacity: 1; padding: 28px 0; border-bottom: 1px solid var(--line); }
}
@media (max-width: 640px) {
  .partners { grid-template-columns: repeat(2, 1fr); }
  .partner { height: 100px; padding: 16px; }
  .console__grid { grid-template-columns: 1fr; }
  .console__cell + .console__cell { border-left: 0; border-top: 1px solid var(--line); }
  .terminal__num { font-size: 2.6rem; }
}
@media (prefers-reduced-motion: reduce) {
  .netbuild { height: auto; }
  .netbuild__sticky { position: static; height: auto; padding: 80px 0; }
  .net-node, .net-edge { opacity: 1 !important; transform: none !important; stroke-dashoffset: 0 !important; }
  .net-step { opacity: 1; display: grid; }
  .net-step p { max-height: none; }
  .card { transform: none !important; }
}
@media (max-width: 960px) { .process__sticky { display: none; } }
