/* ===== Font self-hosted (nessuna chiamata a terze parti) ===== */
@font-face { font-family: "Fraunces"; src: url(../fonts/fraunces.woff2) format("woff2"); font-weight: 300 700; font-display: swap; }
@font-face { font-family: "Fraunces"; src: url(../fonts/fraunces-italic.woff2) format("woff2"); font-style: italic; font-weight: 300 700; font-display: swap; }
@font-face { font-family: "Manrope"; src: url(../fonts/manrope.woff2) format("woff2"); font-weight: 400 700; font-display: swap; }
@font-face { font-family: "IBM Plex Mono"; src: url(../fonts/plex-mono-400.woff2) format("woff2"); font-weight: 400; font-display: swap; }
@font-face { font-family: "IBM Plex Mono"; src: url(../fonts/plex-mono-500.woff2) format("woff2"); font-weight: 500; font-display: swap; }

:root {
  --ink: #0A1A3F;
  --ink-2: #26365A;
  --muted: #5A6680;
  --paper: #F5F6F8;
  --paper-2: #E8ECF2;
  --white: #FFFFFF;
  --line: rgba(10, 26, 63, .12);
  --accent: #1565D8;
  --accent-2: #3D9BE9;
  --accent-soft: #E1EEFC;
  --ok: #1F9D6B;
  --warn: #E0932B;
  --danger: #D9434A;
  --radius: 22px;
  --sans: "Manrope", system-ui, -apple-system, "Segoe UI", sans-serif;
  --display: "Fraunces", Georgia, "Times New Roman", serif;
  --serif: "Fraunces", Georgia, serif;
  --mono: "IBM Plex Mono", ui-monospace, Menlo, monospace;
  --ease: cubic-bezier(.2, .7, .2, 1);
}

* { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; scroll-padding-top: 100px; }
body { font-family: var(--sans); background: var(--paper); color: var(--ink); line-height: 1.55; -webkit-font-smoothing: antialiased; overflow-x: hidden; }
img { max-width: 100%; display: block; }
a { color: inherit; }
button { font: inherit; cursor: pointer; }

.container { width: min(1200px, 100% - 32px); margin-inline: auto; }

h1, h2, h3 { font-family: var(--display); font-weight: 500; letter-spacing: -0.02em; line-height: 1.08; }
h1 { font-size: clamp(2.6rem, 6vw, 5rem); }
h2 { font-size: clamp(2.1rem, 4.4vw, 3.6rem); }
h3 { font-size: 1.3rem; letter-spacing: -0.015em; line-height: 1.2; }
em { font-family: var(--serif); font-style: italic; font-weight: 400; color: var(--accent); letter-spacing: -0.01em; }

.eyebrow, .kicker, .card-tag, .post-meta, small, .btn, .hero-tag, .role, .contact-list span, label {
  font-family: var(--mono);
}
.kicker { font-size: .78rem; text-transform: uppercase; letter-spacing: .12em; color: var(--accent); margin-bottom: 18px; }
.sub { color: var(--muted); font-size: 1.12rem; max-width: 620px; margin-top: 20px; }
.lead { font-size: 1.2rem; color: var(--ink-2); max-width: 560px; margin-top: 26px; }

/* ===== Buttons ===== */
.btn { display: inline-flex; align-items: center; gap: 8px; padding: 15px 24px; border-radius: 12px; font-size: .8rem; text-transform: uppercase; letter-spacing: .08em; text-decoration: none; border: 1px solid transparent; transition: transform .25s var(--ease), background .25s, box-shadow .25s, color .25s; }
.btn:hover { transform: translateY(-2px); }
.btn-primary { background: var(--ink); color: var(--white); box-shadow: 0 8px 24px -10px rgba(10,26,63,.6); }
.btn-primary:hover { background: var(--accent); box-shadow: 0 12px 30px -10px rgba(21,101,216,.7); }
.btn-ghost { border-color: var(--line); background: var(--white); color: var(--ink); }
.btn-ghost:hover { border-color: var(--ink); }
.btn-sm { padding: 11px 18px; font-size: .72rem; }

/* ===== Nav ===== */
.nav { position: fixed; top: 16px; left: 50%; transform: translateX(-50%); z-index: 50; width: min(1200px, 100% - 32px); display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 10px 10px 10px 18px; border-radius: 18px; background: rgba(245,244,239,.72); backdrop-filter: blur(16px) saturate(1.4); -webkit-backdrop-filter: blur(16px) saturate(1.4); border: 1px solid rgba(255,255,255,.7); box-shadow: 0 10px 40px -20px rgba(10,26,63,.3); transition: box-shadow .3s; }
.nav.scrolled { box-shadow: 0 14px 40px -16px rgba(10,26,63,.35); }
.brand { display: flex; align-items: center; gap: 10px; text-decoration: none; }
.brand-mark { width: 34px; height: 34px; border-radius: 9px; background: var(--ink); color: var(--white); display: grid; place-items: center; font-family: Georgia, serif; font-size: 1.15rem; }
.brand-name { font-weight: 700; letter-spacing: .06em; font-size: .95rem; }
.brand-name span { font-weight: 400; color: var(--muted); margin-left: 2px; }
.nav-links { display: flex; gap: 4px; }
.nav-links a { text-decoration: none; font-size: .92rem; padding: 8px 14px; border-radius: 10px; color: var(--ink-2); transition: background .2s; }
.nav-links a:hover { background: rgba(10,26,63,.06); }
.nav-cta { display: flex; align-items: center; gap: 8px; }
.nav-toggle { display: none; width: 42px; height: 42px; border-radius: 10px; border: 1px solid var(--line); background: var(--white); flex-direction: column; justify-content: center; align-items: center; gap: 5px; }
.nav-toggle span { width: 18px; height: 2px; background: var(--ink); transition: transform .3s; }

/* ===== Hero ===== */
.hero { padding-top: 130px; position: relative; }
.hero::before { content: ""; position: absolute; inset: 0; background-image: linear-gradient(var(--line) 1px, transparent 1px), linear-gradient(90deg, var(--line) 1px, transparent 1px); background-size: 64px 64px; mask-image: radial-gradient(ellipse 70% 60% at 70% 30%, #000 20%, transparent 75%); -webkit-mask-image: radial-gradient(ellipse 70% 60% at 70% 30%, #000 20%, transparent 75%); opacity: .5; pointer-events: none; }
.hero-grid { display: grid; grid-template-columns: 1.1fr .9fr; gap: 48px; align-items: center; position: relative; }
.eyebrow { display: inline-flex; align-items: center; gap: 10px; font-size: .75rem; text-transform: uppercase; letter-spacing: .1em; padding: 8px 14px; border-radius: 999px; background: var(--white); border: 1px solid var(--line); margin-bottom: 28px; }
.dot { width: 8px; height: 8px; border-radius: 50%; background: var(--ok); box-shadow: 0 0 0 0 rgba(31,157,107,.5); animation: ping 2s infinite; }
@keyframes ping { 70% { box-shadow: 0 0 0 10px rgba(31,157,107,0); } 100% { box-shadow: 0 0 0 0 rgba(31,157,107,0); } }
.hero-actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 36px; }
.hero-proof { list-style: none; display: flex; gap: 36px; margin-top: 52px; padding-top: 28px; border-top: 1px solid var(--line); }
.hero-proof strong { display: block; font-size: 2rem; font-weight: 600; letter-spacing: -0.03em; font-variant-numeric: tabular-nums; }
.hero-proof span { font-size: .85rem; color: var(--muted); }

.hero-visual { position: relative; aspect-ratio: 1 / 1.05; border-radius: 28px; overflow: hidden; background: var(--white); border: 1px solid var(--line); box-shadow: 0 40px 80px -40px rgba(10,26,63,.35); }
#dither { width: 100%; height: 100%; display: block; }
.hero-tag { position: absolute; font-size: .72rem; letter-spacing: .04em; padding: 10px 14px; border-radius: 12px; background: rgba(255,255,255,.92); backdrop-filter: blur(8px); border: 1px solid var(--line); box-shadow: 0 10px 30px -14px rgba(10,26,63,.4); display: flex; align-items: center; gap: 8px; animation: float 6s ease-in-out infinite; white-space: nowrap; }
.hero-tag b { color: var(--accent); font-weight: 500; }
.tag-a { top: 7%; left: 6%; }
.tag-b { top: 44%; right: 5%; animation-delay: -2s; }
.tag-b b { color: var(--ok); }
.tag-c { bottom: 14%; left: 8%; animation-delay: -4s; }
.pulse { width: 8px; height: 8px; border-radius: 50%; background: var(--accent); animation: ping 2s infinite; }
@keyframes float { 50% { transform: translateY(-8px); } }
.hero-legend { position: absolute; right: 16px; bottom: 16px; font-family: var(--mono); font-size: .7rem; letter-spacing: .14em; color: var(--white); background: var(--ink); padding: 7px 11px; border-radius: 8px; }

/* Marquee */
.marquee { margin-top: 90px; border-block: 1px solid var(--line); overflow: hidden; padding: 22px 0; background: var(--white); mask-image: linear-gradient(90deg, transparent, #000 10%, #000 90%, transparent); -webkit-mask-image: linear-gradient(90deg, transparent, #000 10%, #000 90%, transparent); }
.marquee-track { display: flex; width: max-content; animation: scroll 40s linear infinite; }
.marquee-track span { font-family: var(--mono); font-size: .9rem; text-transform: uppercase; letter-spacing: .08em; color: var(--ink-2); padding: 0 34px; display: flex; align-items: center; gap: 34px; }
.marquee-track span::after { content: "§"; font-family: Georgia, serif; color: var(--accent); }
@keyframes scroll { to { transform: translateX(-50%); } }

/* ===== Sections ===== */
.section { padding: 130px 0; position: relative; }
.section-alt { background: var(--paper-2); }
.section-head { margin-bottom: 64px; }
.row-head { display: flex; justify-content: space-between; align-items: end; gap: 24px; flex-wrap: wrap; }

/* Stats */
.stats { display: grid; grid-template-columns: repeat(3, 1fr); border-top: 1px solid var(--line); }
.stat { padding: 40px 32px 0 0; }
.stat + .stat { padding-left: 32px; border-left: 1px solid var(--line); }
.ring { position: relative; width: 132px; height: 132px; margin-bottom: 28px; }
.ring svg { width: 100%; height: 100%; transform: rotate(-90deg); }
.ring circle { fill: none; stroke: var(--paper-2); stroke-width: 10; }
.ring .bar { stroke: var(--accent); stroke-linecap: round; stroke-dasharray: 326.7; stroke-dashoffset: 326.7; transition: stroke-dashoffset 1.8s var(--ease); }
/* l'arco è amplificato (x8) per leggibilità visiva delle percentuali piccole */
.ring.in .bar { stroke-dashoffset: calc(326.7 - 326.7 * var(--p) * 8 / 100); }
.ring-full.in .bar { stroke-dashoffset: 0; stroke: var(--ink); }
.ring span { position: absolute; inset: 0; display: flex; align-items: center; justify-content: center; font-size: 1.9rem; font-weight: 600; letter-spacing: -0.03em; }
.stat p { font-size: 1.02rem; color: var(--ink-2); max-width: 320px; }
.stat small { display: block; margin-top: 14px; font-size: .7rem; text-transform: uppercase; letter-spacing: .08em; color: var(--muted); }

/* ===== Bento ===== */
.bento { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }
.card { background: var(--white); border-radius: var(--radius); border: 1px solid var(--line); overflow: hidden; display: flex; flex-direction: column; transition: transform .4s var(--ease), box-shadow .4s; }
.card:hover { transform: translateY(-6px); box-shadow: 0 30px 60px -30px rgba(10,26,63,.35); }
.card-lg { grid-column: span 2; grid-row: span 1; flex-direction: row; }
.card-lg .card-ui { flex: 1.1; }
.card-lg .card-body { flex: 1; align-self: end; }
.card-wide { grid-column: span 2; flex-direction: row-reverse; }
.card-wide .card-ui { flex: .8; }
.card-wide .card-body { flex: 1.2; align-self: center; }
.card-body { padding: 28px; }
.card-tag { font-size: .7rem; text-transform: uppercase; letter-spacing: .1em; color: var(--accent); margin-bottom: 10px; }
.card-body h3 { margin-bottom: 10px; }
.card-body p:not(.card-tag) { color: var(--muted); font-size: .97rem; }
.card-ui { min-height: 200px; margin: 14px 14px 0; border-radius: 14px; background: var(--paper); background-image: radial-gradient(rgba(10,26,63,.12) 1px, transparent 1px); background-size: 14px 14px; padding: 18px; position: relative; display: flex; flex-direction: column; justify-content: center; }
.card-lg .card-ui, .card-wide .card-ui { margin: 14px; }

.ui-bar { display: flex; align-items: center; gap: 6px; font-family: var(--mono); font-size: .68rem; text-transform: uppercase; letter-spacing: .08em; color: var(--muted); margin-bottom: 16px; }
.ui-bar span { width: 8px; height: 8px; border-radius: 50%; background: var(--line); }
.ui-bar b { font-weight: 500; margin-left: 8px; }
.heat { display: grid; grid-template-columns: repeat(5, 1fr); gap: 6px; }
.heat i { aspect-ratio: 1.5; border-radius: 6px; transform: scale(.4); opacity: 0; transition: transform .6s var(--ease), opacity .6s; }
.in .heat i { transform: scale(1); opacity: 1; }
.heat i:nth-child(5n+2) { transition-delay: .05s; } .heat i:nth-child(5n+3) { transition-delay: .1s; } .heat i:nth-child(5n+4) { transition-delay: .15s; } .heat i:nth-child(5n) { transition-delay: .2s; }
.h1 { background: #D6E6FA; } .h2 { background: #93C0F0; } .h3 { background: var(--accent-2); } .h4 { background: var(--ink); }
.heat-legend { display: flex; justify-content: space-between; margin-top: 12px; font-family: var(--mono); font-size: .62rem; color: var(--muted); text-transform: uppercase; letter-spacing: .08em; }

.ui-privacy .row { display: flex; align-items: center; gap: 10px; padding: 8px 10px; background: var(--white); border-radius: 10px; border: 1px solid var(--line); }
.ui-privacy .row + .row { margin-top: 8px; }
.chip { font-family: var(--mono); font-size: .66rem; padding: 4px 8px; border-radius: 6px; white-space: nowrap; }
.chip.ok { background: #DDF4EA; color: var(--ok); }
.chip.ok::before { content: "✓ "; }
.chip.warn { background: #FCEFD9; color: #A0620E; }
.chip.warn::before { content: "● "; }
.line { flex: 1; height: 6px; border-radius: 3px; background: var(--paper-2); position: relative; overflow: hidden; }
.line::after { content: ""; position: absolute; inset: 0; width: 0; background: var(--ok); opacity: .5; transition: width 1.4s var(--ease); }
.in .line::after { width: 100%; }
.line.short::after { background: var(--warn); }
.in .line.short::after { width: 55%; }

.pyr { display: flex; flex-direction: column; align-items: center; gap: 5px; }
.pyr i { font-style: normal; font-family: var(--mono); font-size: .66rem; text-transform: uppercase; letter-spacing: .08em; text-align: center; padding: 8px 0; border-radius: 6px; color: var(--white); transition: transform .5s var(--ease); }
.pyr .p1 { width: 34%; background: var(--danger); }
.pyr .p2 { width: 54%; background: var(--warn); }
.pyr .p3 { width: 74%; background: var(--accent); }
.pyr .p4 { width: 94%; background: var(--ink); }
.card:hover .pyr i { transform: scaleX(1.04); }

.dpo-kpi { display: flex; align-items: baseline; gap: 10px; margin-bottom: 16px; }
.dpo-kpi b { font-size: 2.2rem; letter-spacing: -0.03em; font-weight: 600; }
.dpo-kpi span { font-size: .78rem; color: var(--muted); }
.bars { display: flex; align-items: end; gap: 8px; height: 90px; }
.bars i { flex: 1; height: 0; background: linear-gradient(180deg, var(--accent), var(--accent-2)); border-radius: 6px 6px 2px 2px; transition: height 1.2s var(--ease); }
.in .bars i { height: var(--h); }
.bars i:last-child { background: var(--ink); }

.orbit { position: relative; width: 220px; height: 220px; margin: 0 auto; border-radius: 50%; border: 1px dashed rgba(10,26,63,.25); animation: spin 40s linear infinite; }
.orbit::before { content: ""; position: absolute; inset: 40px; border-radius: 50%; border: 1px dashed rgba(10,26,63,.15); }
.core { position: absolute; inset: 0; margin: auto; width: 64px; height: 64px; border-radius: 18px; background: var(--ink); color: var(--white); display: grid; place-items: center; font-family: Georgia, serif; font-size: 1.8rem; animation: spin 40s linear infinite reverse; }
.sat { position: absolute; font-family: var(--mono); font-size: .64rem; text-transform: uppercase; letter-spacing: .06em; background: var(--white); border: 1px solid var(--line); padding: 6px 9px; border-radius: 8px; animation: spin 40s linear infinite reverse; white-space: nowrap; }
.s1 { top: -12px; left: 50%; margin-left: -24px; } .s2 { right: -40px; top: 46%; } .s3 { bottom: -12px; left: 44%; } .s4 { left: -28px; top: 44%; }
@keyframes spin { to { transform: rotate(360deg); } }

/* ===== Steps ===== */
.steps { list-style: none; display: grid; grid-template-columns: repeat(4, 1fr); gap: 20px; }
.step { background: var(--white); border: 1px solid var(--line); border-radius: var(--radius); padding: 28px; position: relative; }
.step-n { font-family: var(--mono); font-size: .8rem; color: var(--white); background: var(--ink); display: inline-block; padding: 6px 10px; border-radius: 8px; margin-bottom: 40px; transition: background .4s; }
.step.active .step-n { background: var(--accent); }
.step h3 { margin-bottom: 10px; }
.step p { color: var(--muted); font-size: .95rem; }
.steps-line { height: 4px; background: var(--paper-2); border-radius: 2px; margin-top: 28px; overflow: hidden; }
.steps-line span { display: block; height: 100%; width: 0; background: linear-gradient(90deg, var(--accent), var(--accent-2)); border-radius: 2px; transition: width .2s linear; }

/* ===== Digitale (dark) ===== */
.section-dark { background: var(--ink); color: var(--white); overflow: hidden; }
.section-dark::before { content: ""; position: absolute; inset: 0; background-image: radial-gradient(rgba(255,255,255,.09) 1px, transparent 1px); background-size: 18px 18px; mask-image: radial-gradient(ellipse at 80% 50%, #000, transparent 70%); -webkit-mask-image: radial-gradient(ellipse at 80% 50%, #000, transparent 70%); pointer-events: none; }
.section-dark .kicker { color: var(--accent-2); }
.section-dark em { color: var(--accent-2); }
.section-dark .sub { color: rgba(255,255,255,.65); }
.digital-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 64px; align-items: center; position: relative; }
.digital-list { list-style: none; margin-top: 36px; display: grid; gap: 12px; }
.digital-list li { padding: 14px 0 14px 34px; border-bottom: 1px solid rgba(255,255,255,.1); position: relative; color: rgba(255,255,255,.85); }
.digital-list li::before { content: "→"; position: absolute; left: 0; font-family: var(--mono); color: var(--accent-2); }

.classifier { background: rgba(255,255,255,.04); border: 1px solid rgba(255,255,255,.12); border-radius: 24px; padding: 24px; backdrop-filter: blur(6px); box-shadow: 0 40px 80px -40px rgba(0,0,0,.7); }
.clf-head { display: flex; align-items: center; gap: 12px; font-family: var(--mono); font-size: .72rem; text-transform: uppercase; letter-spacing: .1em; color: rgba(255,255,255,.6); padding-bottom: 18px; border-bottom: 1px solid rgba(255,255,255,.1); }
.clf-head b { font-weight: 500; }
.ui-dots { display: flex; gap: 6px; }
.ui-dots i { width: 9px; height: 9px; border-radius: 50%; background: rgba(255,255,255,.2); }
.clf-q { margin: 20px 0 14px; font-size: 1.1rem; }
.clf-options { display: flex; flex-wrap: wrap; gap: 8px; }
.opt { background: transparent; color: var(--white); border: 1px solid rgba(255,255,255,.2); padding: 10px 14px; border-radius: 10px; font-size: .9rem; transition: background .2s, border-color .2s; }
.opt:hover { border-color: rgba(255,255,255,.5); }
.opt[aria-pressed="true"] { background: var(--white); color: var(--ink); border-color: var(--white); }
.clf-result { display: flex; gap: 18px; margin-top: 22px; padding: 20px; border-radius: 16px; background: rgba(255,255,255,.06); min-height: 150px; }
.meter { display: flex; flex-direction: column; gap: 5px; width: 14px; flex-shrink: 0; }
.m { flex: 1; border-radius: 4px; background: rgba(255,255,255,.1); transition: background .4s; }
.clf-level { font-family: var(--mono); font-size: .8rem; text-transform: uppercase; letter-spacing: .1em; color: var(--accent-2); margin-bottom: 8px; }
.clf-desc { color: rgba(255,255,255,.85); font-size: .97rem; }
.clf-result.anim .clf-text { animation: fadeUp .45s var(--ease); }
@keyframes fadeUp { from { opacity: 0; transform: translateY(8px); } }
.clf-note { font-size: .75rem; color: rgba(255,255,255,.4); margin-top: 14px; }

/* ===== Team ===== */
.team { display: grid; grid-template-columns: repeat(4, 1fr); gap: 20px; }
.photo { position: relative; aspect-ratio: 4 / 5; border-radius: 18px; overflow: hidden; background: var(--paper-2); margin-bottom: 18px; border: 1px solid var(--line); }
.photo img, .photo canvas { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.photo canvas { transition: opacity .6s var(--ease); image-rendering: pixelated; }
.photo img { transform: scale(1.06); transition: transform .8s var(--ease); }
.person:hover .photo canvas { opacity: 0; }
.person:hover .photo img { transform: scale(1); }
.person h3 { font-size: 1.15rem; }
.role { font-size: .7rem; text-transform: uppercase; letter-spacing: .08em; color: var(--accent); margin: 6px 0 10px; }
.bio { color: var(--muted); font-size: .92rem; }

/* ===== Posts ===== */
.posts { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }
.post { text-decoration: none; background: var(--white); border: 1px solid var(--line); border-radius: var(--radius); padding: 28px; min-height: 260px; display: flex; flex-direction: column; justify-content: space-between; gap: 20px; transition: transform .35s var(--ease), background .35s, color .35s; }
.post:hover { transform: translateY(-6px); background: var(--ink); color: var(--white); }
.post-meta { font-size: .7rem; letter-spacing: .1em; color: var(--accent); }
.post:hover .post-meta { color: var(--accent-2); }
.post h3 { font-size: 1.35rem; }
.post-more { font-family: var(--mono); font-size: .78rem; }

/* ===== CTA / Form ===== */
.cta-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 64px; align-items: start; }
.contact-list { list-style: none; margin-top: 40px; }
.contact-list li { display: flex; gap: 20px; padding: 16px 0; border-bottom: 1px solid var(--line); }
.contact-list span { font-size: .7rem; letter-spacing: .1em; color: var(--muted); width: 56px; padding-top: 3px; }
.form { background: var(--white); border: 1px solid var(--line); border-radius: 24px; padding: 32px; display: grid; gap: 16px; box-shadow: 0 40px 80px -50px rgba(10,26,63,.4); }
.field { display: grid; gap: 6px; }
.field label { font-size: .7rem; text-transform: uppercase; letter-spacing: .08em; color: var(--muted); }
.field input, .field select, .field textarea { font: inherit; font-size: 1rem; padding: 13px 14px; border-radius: 10px; border: 1px solid var(--line); background: var(--paper); color: var(--ink); transition: border-color .2s, box-shadow .2s; }
.field input:focus, .field select:focus, .field textarea:focus { outline: none; border-color: var(--accent); box-shadow: 0 0 0 4px var(--accent-soft); }
.check { display: flex; gap: 10px; align-items: flex-start; font-family: var(--sans); font-size: .85rem; color: var(--muted); }
.check input { margin-top: 3px; accent-color: var(--accent); }
.form .btn { justify-content: center; }
.form-msg { font-size: .9rem; min-height: 1.2em; }
.form-msg.ok { color: var(--ok); } .form-msg.err { color: var(--danger); }

/* ===== Footer ===== */
.footer { background: var(--ink); color: rgba(255,255,255,.7); padding: 56px 0 40px; }
.footer .brand-mark { background: var(--white); color: var(--ink); }
.footer .brand-name { color: var(--white); }
.footer .brand-name span { color: rgba(255,255,255,.5); }
.footer-grid { display: grid; grid-template-columns: 1fr auto; gap: 28px; align-items: center; }
.footer-grid > div:first-child p { margin-top: 12px; font-size: .9rem; }
.footer-links { display: flex; flex-wrap: wrap; gap: 22px; }
.footer-links a { text-decoration: none; font-size: .9rem; }
.footer-links a:hover { color: var(--white); }
.footer-legal { grid-column: 1 / -1; padding-top: 28px; border-top: 1px solid rgba(255,255,255,.1); font-size: .8rem; color: rgba(255,255,255,.45); }

/* ===== Reveal ===== */
.reveal { opacity: 0; transform: translateY(28px); transition: opacity .9s var(--ease), transform .9s var(--ease); }
.reveal.in { opacity: 1; transform: none; }
.bento .reveal:nth-child(2), .steps .reveal:nth-child(2), .team .reveal:nth-child(2), .posts .reveal:nth-child(2), .stats .reveal:nth-child(2) { transition-delay: .1s; }
.bento .reveal:nth-child(3), .steps .reveal:nth-child(3), .team .reveal:nth-child(3), .posts .reveal:nth-child(3), .stats .reveal:nth-child(3) { transition-delay: .2s; }
.steps .reveal:nth-child(4), .team .reveal:nth-child(4) { transition-delay: .3s; }

/* ===== Responsive ===== */
@media (max-width: 1000px) {
  .hero-grid, .digital-grid, .cta-grid { grid-template-columns: 1fr; }
  .hero-visual { max-width: 560px; width: 100%; margin-inline: auto; }
  .bento { grid-template-columns: 1fr 1fr; }
  .card-lg, .card-wide { grid-column: span 2; }
  .steps, .team { grid-template-columns: 1fr 1fr; }
  .posts { grid-template-columns: 1fr; }
  .post { min-height: 0; }
}
@media (max-width: 820px) {
  .nav-links { display: none; position: absolute; top: calc(100% + 8px); left: 0; right: 0; flex-direction: column; background: var(--white); border: 1px solid var(--line); border-radius: 16px; padding: 10px; box-shadow: 0 20px 40px -20px rgba(10,26,63,.4); }
  .nav.open .nav-links { display: flex; }
  .nav-links a { padding: 14px; }
  .nav-toggle { display: flex; }
  .nav.open .nav-toggle span:first-child { transform: translateY(3.5px) rotate(45deg); }
  .nav.open .nav-toggle span:last-child { transform: translateY(-3.5px) rotate(-45deg); }
}
@media (max-width: 640px) {
  .section { padding: 90px 0; }
  .hero { padding-top: 110px; }
  .nav-cta .btn { display: none; }
  .hero-proof { gap: 20px; }
  .hero-proof strong { font-size: 1.6rem; }
  .hero-proof span { font-size: .75rem; }
  .stats { grid-template-columns: 1fr; }
  .stat, .stat + .stat { padding: 32px 0; border-left: 0; border-bottom: 1px solid var(--line); }
  .bento { grid-template-columns: 1fr; }
  .card-lg, .card-wide { grid-column: auto; flex-direction: column; }
  .card-lg .card-ui, .card-wide .card-ui { margin: 14px 14px 0; }
  .steps, .team { grid-template-columns: 1fr; }
  .team { grid-template-columns: 1fr 1fr; gap: 14px; }
  .bio { display: none; }
  .hero-tag { font-size: .62rem; padding: 8px 10px; }
  .form { padding: 22px; }
  .footer-grid { grid-template-columns: 1fr; }
  .orbit { width: 180px; height: 180px; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; }
  .reveal { opacity: 1; transform: none; }
}

/* =====================================================================
   Legalegovernance 360 — componenti multi-pagina
   ===================================================================== */
h1 em, h2 em { font-weight: 400; }
.brand img { height: 46px; width: auto; }
.brand-text { display: flex; flex-direction: column; line-height: 1.05; }
.brand-text b { font-family: var(--display); font-weight: 600; font-size: 1.02rem; letter-spacing: .01em; }
.brand-text small { font-family: var(--mono); font-size: .6rem; letter-spacing: .14em; text-transform: uppercase; color: var(--muted); margin-top: 3px; }
.footer .brand img { background: var(--white); border-radius: 10px; padding: 4px; height: 52px; }
.footer .brand-text b { color: var(--white); }
.footer .brand-text small { color: rgba(255,255,255,.5); }
.nav-links a.active { background: rgba(10,26,63,.07); color: var(--ink); font-weight: 600; }

/* Dropdown Servizi 360 */
.has-drop { position: relative; }
.drop-btn { display: inline-flex; align-items: center; gap: 6px; background: none; border: 0; font-size: .92rem; padding: 8px 14px; border-radius: 10px; color: var(--ink-2); }
.drop-btn:hover, .has-drop.open .drop-btn { background: rgba(10,26,63,.06); }
.drop-btn.active { font-weight: 600; color: var(--ink); }
.drop-btn svg { transition: transform .25s; }
.has-drop.open .drop-btn svg { transform: rotate(180deg); }
.drop { position: absolute; top: calc(100% + 12px); left: 50%; transform: translate(-50%, 6px); min-width: 270px; background: var(--white); border: 1px solid var(--line); border-radius: 16px; padding: 8px; box-shadow: 0 24px 50px -20px rgba(10,26,63,.35); opacity: 0; visibility: hidden; transition: opacity .2s, transform .2s, visibility .2s; }
.drop::before { content: ""; position: absolute; left: 0; right: 0; top: -14px; height: 14px; }
.has-drop.open .drop { opacity: 1; visibility: visible; transform: translate(-50%, 0); }
@media (hover: hover) and (min-width: 821px) { .has-drop:hover .drop { opacity: 1; visibility: visible; transform: translate(-50%, 0); } .has-drop:hover .drop-btn svg { transform: rotate(180deg); } }
.drop a { display: flex; align-items: center; gap: 12px; padding: 11px 12px; border-radius: 10px; text-decoration: none; font-size: .95rem; color: var(--ink); }
.drop a:hover, .drop a.active { background: var(--accent-soft); }
.drop a span { font-family: var(--mono); font-size: .68rem; color: var(--accent); width: 22px; }

/* Page hero (pagine interne) */
.page-hero { padding: 150px 0 70px; position: relative; overflow: hidden; }
.page-hero::before { content: ""; position: absolute; inset: 0; background-image: linear-gradient(var(--line) 1px, transparent 1px), linear-gradient(90deg, var(--line) 1px, transparent 1px); background-size: 64px 64px; mask-image: radial-gradient(ellipse 60% 80% at 85% 20%, #000 10%, transparent 70%); -webkit-mask-image: radial-gradient(ellipse 60% 80% at 85% 20%, #000 10%, transparent 70%); opacity: .55; pointer-events: none; }
.crumbs { font-family: var(--mono); font-size: .72rem; letter-spacing: .08em; text-transform: uppercase; color: var(--muted); margin-bottom: 26px; display: flex; flex-wrap: wrap; gap: 8px; position: relative; }
.crumbs a { color: var(--accent); text-decoration: none; }
.page-hero h1 { font-size: clamp(2.6rem, 6vw, 4.6rem); max-width: 900px; position: relative; }
.page-hero .subtitle { font-family: var(--display); font-style: italic; font-size: clamp(1.25rem, 2.2vw, 1.6rem); color: var(--accent); margin-top: 16px; max-width: 820px; position: relative; font-weight: 400; }
.hero-mark { position: absolute; right: -2%; top: 90px; font-family: var(--display); font-size: clamp(9rem, 22vw, 20rem); line-height: 1; color: transparent; -webkit-text-stroke: 1.5px rgba(21,101,216,.18); pointer-events: none; user-select: none; }

/* Prose a due colonne */
.prose-wrap { padding: 20px 0 100px; }
.intro { font-size: 1.2rem; color: var(--ink-2); max-width: 860px; display: grid; gap: 18px; padding-bottom: 60px; border-bottom: 1px solid var(--line); }
.block { display: grid; grid-template-columns: 300px 1fr; gap: 48px; padding: 56px 0; border-bottom: 1px solid var(--line); }
.block > h2 { font-size: clamp(1.7rem, 2.6vw, 2.2rem); position: sticky; top: 110px; align-self: start; }
.block-body { display: grid; gap: 16px; font-size: 1.05rem; color: var(--ink-2); max-width: 780px; }
.block-body p strong, .intro strong { color: var(--ink); }
.list { list-style: none; display: grid; gap: 12px; counter-reset: li; }
.list li { counter-increment: li; position: relative; padding: 18px 20px 18px 64px; background: var(--white); border: 1px solid var(--line); border-radius: 16px; transition: border-color .25s, transform .25s var(--ease); }
.list li:hover { border-color: rgba(21,101,216,.4); transform: translateX(4px); }
.list li::before { content: counter(li, decimal-leading-zero); position: absolute; left: 20px; top: 19px; font-family: var(--mono); font-size: .75rem; color: var(--white); background: var(--ink); border-radius: 7px; padding: 3px 6px; }
.list li strong { color: var(--ink); }
.list li a { color: var(--accent); text-decoration: none; border-bottom: 1px solid rgba(21,101,216,.35); }
.list li a:hover { border-color: var(--accent); }
.block-body > p a, .intro a { color: var(--accent); }

/* CTA box */
.cta-box { margin-top: 64px; border-radius: 28px; background: var(--ink); color: var(--white); padding: clamp(32px, 5vw, 64px); position: relative; overflow: hidden; display: grid; grid-template-columns: 1.4fr auto; gap: 32px; align-items: end; }
.cta-box::before { content: ""; position: absolute; inset: 0; background-image: radial-gradient(rgba(255,255,255,.1) 1px, transparent 1px); background-size: 16px 16px; mask-image: radial-gradient(ellipse at 100% 0%, #000, transparent 65%); -webkit-mask-image: radial-gradient(ellipse at 100% 0%, #000, transparent 65%); }
.cta-box > * { position: relative; }
.cta-box h2 { font-size: clamp(1.9rem, 3.4vw, 2.8rem); }
.cta-box p { color: rgba(255,255,255,.75); margin-top: 14px; font-size: 1.05rem; max-width: 640px; }
.cta-box p + p { margin-top: 10px; }
.btn-light { background: var(--white); color: var(--ink); }
.btn-light:hover { background: var(--accent-2); color: var(--white); }
.cta-soft { background: var(--accent-soft); color: var(--ink); }
.cta-soft::before { background-image: radial-gradient(rgba(21,101,216,.18) 1px, transparent 1px); }
.cta-soft p { color: var(--ink-2); }

/* Card cliccabili (Formazione, Live/FAD) */
.link-cards { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; margin-top: 8px; }
.link-cards.two { grid-template-columns: repeat(2, 1fr); }
.lcard { position: relative; display: flex; flex-direction: column; gap: 14px; padding: 30px; background: var(--white); border: 1px solid var(--line); border-radius: 24px; text-decoration: none; color: var(--ink); transition: transform .35s var(--ease), box-shadow .35s, border-color .35s; overflow: hidden; }
.lcard:hover { transform: translateY(-6px); box-shadow: 0 30px 60px -30px rgba(10,26,63,.35); border-color: rgba(21,101,216,.35); }
.lcard-icon { width: 56px; height: 56px; border-radius: 16px; background: var(--accent-soft); color: var(--accent); display: grid; place-items: center; font-family: var(--mono); font-weight: 500; font-size: .95rem; }
.lcard h3 { font-size: 1.6rem; }
.lcard .lcard-sub { font-family: var(--display); font-style: italic; color: var(--accent); font-size: 1.05rem; }
.lcard p { color: var(--muted); font-size: .98rem; }
.lcard .lcard-more { margin-top: auto; padding-top: 10px; font-family: var(--mono); font-size: .75rem; text-transform: uppercase; letter-spacing: .08em; display: inline-flex; align-items: center; gap: 8px; color: var(--ink); }
.lcard .lcard-more::after { content: "→"; transition: transform .25s; }
.lcard:hover .lcard-more::after { transform: translateX(5px); }
.lcard-tag { position: absolute; top: 24px; right: 24px; font-family: var(--mono); font-size: .66rem; letter-spacing: .1em; text-transform: uppercase; padding: 5px 9px; border-radius: 999px; border: 1px solid var(--line); color: var(--muted); }
.lcard h4 { font-family: var(--display); font-size: 1.15rem; font-weight: 500; }

/* Moduli del videocorso */
.modules { list-style: none; display: grid; gap: 12px; }
.modules li { display: grid; grid-template-columns: 120px 1fr; gap: 20px; padding: 22px 24px; background: var(--white); border: 1px solid var(--line); border-radius: 18px; }
.modules .mod-n { font-family: var(--mono); font-size: .72rem; letter-spacing: .1em; text-transform: uppercase; color: var(--accent); padding-top: 4px; }
.modules h3 { font-size: 1.2rem; margin-bottom: 6px; }
.modules p { color: var(--muted); font-size: .97rem; }
.course-facts { display: flex; flex-wrap: wrap; gap: 10px; }
.course-facts span { font-family: var(--mono); font-size: .75rem; padding: 8px 12px; border-radius: 10px; background: var(--white); border: 1px solid var(--line); }

/* Home: manifesto */
.manifesto { display: grid; grid-template-columns: 1fr 1fr; gap: 64px; align-items: start; }
.manifesto-text { display: grid; gap: 20px; font-size: 1.08rem; color: var(--ink-2); }
.claim { padding: 110px 0; background: var(--ink); color: var(--white); position: relative; overflow: hidden; text-align: center; }
.claim::before { content: ""; position: absolute; inset: 0; background-image: radial-gradient(rgba(255,255,255,.1) 1px, transparent 1px); background-size: 18px 18px; mask-image: radial-gradient(ellipse at 50% 50%, #000, transparent 70%); -webkit-mask-image: radial-gradient(ellipse at 50% 50%, #000, transparent 70%); }
.claim blockquote { position: relative; font-family: var(--display); font-size: clamp(2rem, 4.6vw, 3.8rem); line-height: 1.12; letter-spacing: -0.02em; max-width: 1000px; margin: 0 auto; }
.claim blockquote em { color: var(--accent-2); }
.claim .kicker { color: var(--accent-2); position: relative; }

/* Team (home) e badge */
.team-2 { grid-template-columns: repeat(2, 1fr); max-width: 860px; }
.badges { display: flex; flex-wrap: wrap; align-items: center; gap: 14px; margin-top: 22px; }
.badges img { height: 84px; width: auto; background: var(--white); border-radius: 12px; padding: 6px; border: 1px solid var(--line); }
.badge-strip { display: flex; flex-wrap: wrap; justify-content: center; align-items: center; gap: 28px; margin-top: 64px; padding: 28px; border-radius: 22px; background: var(--white); border: 1px solid var(--line); }
.badge-strip img { height: 72px; width: auto; filter: grayscale(1); opacity: .75; transition: filter .3s, opacity .3s; }
.badge-strip img:hover { filter: none; opacity: 1; }
.badge-strip p { width: 100%; text-align: center; font-family: var(--mono); font-size: .7rem; letter-spacing: .12em; text-transform: uppercase; color: var(--muted); }

/* Chi siamo: profili */
.profile { display: grid; grid-template-columns: 360px 1fr; gap: 56px; padding: 64px 0; border-bottom: 1px solid var(--line); align-items: start; }
.profile:last-child { border-bottom: 0; }
.profile-photo { position: sticky; top: 110px; border-radius: 24px; overflow: hidden; aspect-ratio: 4 / 5; border: 1px solid var(--line); box-shadow: 0 40px 70px -40px rgba(10,26,63,.45); }
.profile-photo img { width: 100%; height: 100%; object-fit: cover; }
.profile h2 { font-size: clamp(2rem, 3.6vw, 3rem); }
.profile .role { font-size: .74rem; margin: 10px 0 26px; }
.profile-body { display: grid; gap: 16px; font-size: 1.05rem; color: var(--ink-2); }
.profile-body h3 { font-family: var(--mono); font-size: .76rem; letter-spacing: .12em; text-transform: uppercase; color: var(--accent); margin-top: 18px; font-weight: 500; }
.profile-body h4 { font-family: var(--display); font-size: 1.3rem; font-weight: 500; color: var(--ink); }

/* Form contatti */
.seg { display: inline-flex; padding: 4px; border-radius: 12px; background: var(--paper); border: 1px solid var(--line); gap: 4px; }
.seg label { position: relative; font-family: var(--sans); font-size: .95rem; text-transform: none; letter-spacing: 0; color: var(--ink-2); }
.seg input { position: absolute; opacity: 0; }
.seg span { display: block; padding: 9px 18px; border-radius: 9px; cursor: pointer; transition: background .2s, color .2s; }
.seg input:checked + span { background: var(--ink); color: var(--white); }
.seg input:focus-visible + span { outline: 2px solid var(--accent); outline-offset: 2px; }
.company-fields { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.company-fields[hidden] { display: none; }
.req { color: var(--accent); }
.field fieldset { border: 0; display: grid; gap: 6px; }
.field legend { font-family: var(--mono); font-size: .7rem; text-transform: uppercase; letter-spacing: .08em; color: var(--muted); margin-bottom: 6px; }
.check.invalid { color: var(--danger); }
.check.invalid input { outline: 2px solid var(--danger); outline-offset: 2px; }
.form-note { font-size: .78rem; color: var(--muted); }

/* Policy */
.policy { max-width: 820px; display: grid; gap: 16px; font-size: 1.02rem; color: var(--ink-2); padding-bottom: 100px; }
.policy h2 { font-family: var(--mono); font-size: .8rem; font-weight: 500; letter-spacing: .1em; text-transform: uppercase; color: var(--accent); margin-top: 26px; }
.policy h3 { font-size: 1.2rem; margin-top: 8px; }
.policy ul { padding-left: 22px; display: grid; gap: 8px; }
.policy .updated { margin-top: 20px; font-family: var(--mono); font-size: .8rem; color: var(--muted); }
.policy .note-box { padding: 16px 20px; border-radius: 14px; background: var(--accent-soft); color: var(--ink); }

/* Riquadro News */
.empty-state { padding: 60px; border-radius: 24px; border: 1px dashed rgba(10,26,63,.25); text-align: center; color: var(--muted); }

@media (max-width: 1000px) {
  .block { grid-template-columns: 1fr; gap: 20px; }
  .block > h2 { position: static; }
  .manifesto { grid-template-columns: 1fr; gap: 28px; }
  .profile { grid-template-columns: 1fr; gap: 32px; }
  .profile-photo { position: static; max-width: 420px; }
  .link-cards { grid-template-columns: 1fr; }
  .cta-box { grid-template-columns: 1fr; align-items: start; }
}
@media (max-width: 820px) {
  .nav-links { max-height: calc(100vh - 110px); overflow-y: auto; }
  .has-drop { width: 100%; }
  .drop-btn { width: 100%; justify-content: space-between; padding: 14px; }
  .drop { position: static; transform: none; opacity: 1; visibility: visible; box-shadow: none; border: 0; padding: 0 0 0 8px; min-width: 0; display: none; }
  .has-drop.open .drop { display: block; transform: none; }
  .brand img { height: 40px; }
}
@media (max-width: 640px) {
  .link-cards.two { grid-template-columns: 1fr; }
  .modules li { grid-template-columns: 1fr; gap: 6px; }
  .company-fields { grid-template-columns: 1fr; }
  .team-2 { grid-template-columns: 1fr 1fr; }
  .badges img { height: 64px; }
  .badge-strip img { height: 52px; }
  .page-hero { padding: 120px 0 50px; }
  .list li { padding: 16px 16px 16px 56px; }
  .list li::before { left: 14px; }
  .brand-text small { display: none; }
}

/* Home: card servizi come link */
a.card { text-decoration: none; color: inherit; }
.bento .card-wide { grid-column: span 3; }
.card-more { display: inline-flex; gap: 8px; margin-top: 16px; font-family: var(--mono); font-size: .72rem; letter-spacing: .08em; text-transform: uppercase; color: var(--ink); }
.card-more::after { content: "→"; transition: transform .25s; }
.card:hover .card-more::after { transform: translateX(5px); }
.ui-wb .wb-track { display: grid; gap: 10px; position: relative; padding-left: 6px; }
.ui-wb .wb-track::before { content: ""; position: absolute; left: 12px; top: 10px; bottom: 10px; width: 2px; background: linear-gradient(var(--accent), var(--accent-2)); border-radius: 2px; }
.wb-step { display: grid; grid-template-columns: 14px 1fr auto; gap: 12px; align-items: center; background: var(--white); border: 1px solid var(--line); border-radius: 10px; padding: 8px 10px; position: relative; }
.wb-step i { width: 10px; height: 10px; border-radius: 50%; background: var(--accent); box-shadow: 0 0 0 3px var(--accent-soft); }
.wb-step b { font-size: .78rem; font-weight: 600; }
.wb-step span { font-family: var(--mono); font-size: .62rem; color: var(--muted); }
.ui-doc .doc { position: relative; width: 70%; margin: 0 auto; background: var(--white); border: 1px solid var(--line); border-radius: 8px; padding: 16px 16px 26px; display: grid; gap: 8px; box-shadow: 8px 8px 0 -1px var(--paper-2), 8px 8px 0 0 var(--line); transition: transform .4s var(--ease); }
.card:hover .ui-doc .doc { transform: rotate(-2deg) translateY(-4px); }
.ui-doc .doc b { font-family: var(--display); font-size: .95rem; font-weight: 500; margin-bottom: 4px; }
.ui-doc .doc i { height: 6px; border-radius: 3px; background: var(--paper-2); }
.ui-doc .doc i.s { width: 60%; }
.ui-doc .seal { position: absolute; right: -10px; bottom: -10px; width: 42px; height: 42px; border-radius: 50%; background: var(--accent); color: var(--white); display: grid; place-items: center; font-family: Georgia, serif; font-size: 1.2rem; box-shadow: 0 6px 16px -6px rgba(21,101,216,.7); }
.ui-learn { gap: 14px; }
.learn { display: grid; grid-template-columns: 70px 1fr; align-items: center; gap: 12px; font-family: var(--mono); font-size: .72rem; text-transform: uppercase; letter-spacing: .06em; }
.learn i { height: 10px; border-radius: 5px; background: var(--paper-2); position: relative; overflow: hidden; }
.learn i::after { content: ""; position: absolute; inset: 0; width: 0; background: linear-gradient(90deg, var(--accent), var(--accent-2)); border-radius: 5px; transition: width 1.4s var(--ease); }
.in .learn i::after { width: var(--w); }
a.person { text-decoration: none; color: inherit; display: block; }
.home .hero-legend { font-size: .64rem; }
@media (max-width: 1000px) { .bento .card-wide { grid-column: span 2; } }
@media (max-width: 640px) { .bento .card-wide { grid-column: auto; } }

/* Sezioni con riquadri cliccabili: titolo sopra e riquadri a tutta larghezza */
.block:has(.link-cards) { grid-template-columns: 1fr; gap: 24px; }
.block:has(.link-cards) > h2 { position: static; }
.block:has(.link-cards) .block-body { max-width: none; }
.block:has(.link-cards) .block-body > p, .block:has(.link-cards) .block-body > .list { max-width: 820px; }
