/* ===== Font Inter (ospitato nel sito, nessuna richiesta a servizi esterni) ===== */
@font-face {
  font-family: "Outfit";
  src: url("assets/fonts/Outfit-600.woff2") format("woff2");
  font-weight: 600;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "Inter";
  src: url("assets/fonts/InterVariable.woff2") format("woff2");
  font-weight: 100 900;
  font-style: normal;
  font-display: swap;
}

/* ===== Variabili: colori presi dal logo Flowbase ===== */
:root {
  --bg: #ffffff;
  --surface: #f4f6f9;
  --line: #e2e7ee;
  --ink: #0f1b2f;        /* testo del logo */
  --text: #2b3850;
  --muted: #5f6574;
  --blue: #1892fe;       /* azzurro del marchio */
  --blue-strong: #0169e9; /* blu del marchio: testi e bottoni */
  --navy: #073695;
  --teal: #59fbc5;       /* verde acqua del marchio */
  --blue-soft: #e6f0fe;
  --gradient: linear-gradient(120deg, #0169e9 0%, #3fe4d1 62%, var(--teal) 100%);
  --radius: 14px;
  --max: 1160px;
  --shadow: 0 1px 2px rgba(15, 28, 48, .04), 0 12px 32px -12px rgba(15, 28, 48, .14);
  --font: "Inter", "Segoe UI", system-ui, -apple-system, "Helvetica Neue", Arial, sans-serif;
}

* { box-sizing: border-box; margin: 0; padding: 0; }

html { scroll-behavior: smooth; scroll-padding-top: 24px; }

body {
  font-family: var(--font);
  background: var(--bg);
  color: var(--text);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

a { color: inherit; text-decoration: none; }
img { display: block; max-width: 100%; height: auto; }

h1, h2, h3, h4 { color: var(--ink); font-weight: 600; letter-spacing: -0.025em; line-height: 1.15; }
h2 { font-size: clamp(1.8rem, 3.4vw, 2.5rem); letter-spacing: -0.03em; }

svg { fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }

.container { width: 100%; max-width: var(--max); margin: 0 auto; padding: 0 24px; }

.eyebrow {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: .78rem;
  font-weight: 500;
  letter-spacing: .12em;
  text-transform: uppercase;
  color: var(--muted);
  margin-bottom: 16px;
}
.eyebrow::before { content: ""; width: 18px; height: 1.5px; background: var(--blue); }
.eyebrow--light { color: rgba(255, 255, 255, .6); }
.eyebrow--light::before { background: var(--teal); }

/* ===== Bottoni ===== */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 14px 26px;
  border-radius: 10px;
  background: var(--blue-strong);
  color: #fff;
  font: 500 1rem var(--font);
  border: 1px solid transparent;
  cursor: pointer;
  transition: background .2s, transform .2s, box-shadow .2s;
}
.btn:hover { background: var(--navy); transform: translateY(-1px); box-shadow: 0 10px 24px -10px var(--navy); }
.btn:disabled { opacity: .6; cursor: wait; transform: none; }
.btn--outline { background: transparent; color: var(--ink); border-color: var(--line); }
.btn--outline:hover { background: var(--surface); box-shadow: none; }
.btn--small { padding: 9px 18px; font-size: .92rem; }
.btn--full { width: 100%; }

/* ===== Navbar ===== */
.nav {
  position: fixed;
  inset: 0 0 auto 0;
  z-index: 100;
  background: rgba(255, 255, 255, .85);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid transparent;
  transition: border-color .3s;
}
.nav.scrolled { border-color: var(--line); }
.nav__inner { display: flex; align-items: center; justify-content: space-between; height: 72px; }
.logo img { height: 30px; width: auto; }
.nav__links { display: flex; align-items: center; gap: 32px; }
.nav__links a:not(.btn) { color: var(--muted); font-weight: 450; transition: color .2s; }
.nav__links a:not(.btn):hover { color: var(--ink); }
.nav__toggle { display: none; background: none; border: none; cursor: pointer; padding: 8px; }
.nav__toggle span { display: block; width: 24px; height: 2px; background: var(--ink); margin: 6px 0; transition: transform .3s; }

/* ===== Hero ===== */
.hero {
  position: relative;
  padding: 150px 0 100px;
  overflow: hidden;
}
/* Griglia da tavola tecnica sullo sfondo */
.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: 48px 48px;
  mask-image: radial-gradient(ellipse 80% 70% at 70% 40%, #000 20%, transparent 75%);
  -webkit-mask-image: radial-gradient(ellipse 80% 70% at 70% 40%, #000 20%, transparent 75%);
  opacity: .7;
  pointer-events: none;
}
.hero__inner {
  position: relative;
  display: grid;
  grid-template-columns: 1.1fr .9fr;
  gap: 64px;
  align-items: center;
}
.hero h1 {
  font-size: clamp(2.4rem, 5vw, 3.9rem);
  font-weight: 600;
  letter-spacing: -0.045em;
  line-height: 1.04;
}
.highlight { color: var(--blue-strong); }
.hero__sub { margin: 24px 0 36px; font-size: 1.15rem; color: var(--muted); max-width: 500px; }
.hero__note { margin-top: 18px; font-size: .88rem; color: var(--muted); }
.hero__cta { display: flex; gap: 12px; flex-wrap: wrap; }

/* Illustrazione archivio */
.hero__visual { position: relative; }
.archive {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 18px;
  box-shadow: 0 40px 80px -30px rgba(6, 49, 143, .28), var(--shadow);
  padding: 22px;
  position: relative;
}
.archive::before {
  content: "";
  position: absolute;
  inset: 0 0 auto 0;
  height: 4px;
  border-radius: 18px 18px 0 0;
  background: var(--gradient);
}
.archive__head { display: flex; justify-content: space-between; align-items: center; font-weight: 500; color: var(--ink); margin-bottom: 16px; }
.pill {
  font-size: .72rem;
  font-weight: 700;
  padding: 3px 10px;
  border-radius: 99px;
  background: var(--blue-soft);
  color: var(--blue-strong);
}
.archive__search {
  display: flex; align-items: center; gap: 10px;
  padding: 12px 14px;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: var(--surface);
  color: var(--ink);
  margin-bottom: 14px;
}
.archive__search svg { width: 18px; height: 18px; color: var(--muted); flex-shrink: 0; }
.caret {
  display: inline-block;
  width: 2px; height: 1.05em;
  margin-left: 2px;
  vertical-align: text-bottom;
  background: var(--blue);
  animation: blink 1s steps(1) infinite;
}
@keyframes blink { 50% { opacity: 0; } }
.archive__list { list-style: none; display: grid; gap: 6px; }
.archive__list li {
  display: flex; align-items: center; gap: 14px;
  padding: 12px;
  border-radius: 10px;
  transition: background .2s;
}
.archive__list li:first-child { background: var(--blue-soft); }
.archive__list svg {
  width: 38px; height: 38px; padding: 8px;
  border-radius: 9px;
  background: #fff;
  border: 1px solid var(--line);
  color: var(--blue-strong);
  flex-shrink: 0;
}
.archive__list strong { display: block; color: var(--ink); font-weight: 500; font-size: .95rem; }
.archive__list small { color: var(--muted); font-size: .82rem; }
.float-badge {
  position: absolute;
  left: -28px; bottom: -22px;
  display: flex; align-items: center; gap: 10px;
  padding: 12px 16px;
  background: var(--ink);
  color: #fff;
  border-radius: 12px;
  font-size: .88rem;
  font-weight: 450;
  box-shadow: var(--shadow);
}
.float-badge svg { width: 18px; height: 18px; color: var(--teal); stroke-width: 2.4; }

/* Badge AI estratti nei documenti dell'archivio */
.ai-tag {
  display: inline-block;
  margin-top: 5px;
  padding: 2px 8px;
  border-radius: 99px;
  background: var(--blue-soft);
  color: var(--blue-strong);
  font-size: .72rem;
  font-weight: 500;
}
.ai-tag--warn { background: #fff3c4; color: #7a5800; }
.ai-tag--ok { background: #e3f6ec; color: #0f7b4f; }

/* ===== Settori ===== */

/* ===== Sezioni ===== */
.section { padding: 110px 0; }
.section--surface { background: var(--surface); }
.section--dark { background: var(--ink); color: #fff; }
.section--dark h2, .section--dark h3 { color: #fff; }
.section__head { max-width: 640px; margin-bottom: 56px; }
.section__sub { margin-top: 16px; color: var(--muted); font-size: 1.08rem; }

/* ===== Card servizi ===== */
.grid { display: grid; gap: 24px; }
.grid--3 { grid-template-columns: repeat(3, 1fr); }
.card {
  position: relative;
  display: flex; flex-direction: column;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 32px;
  overflow: hidden;
  transition: transform .25s, box-shadow .25s;
}
.card::before {
  content: "";
  position: absolute;
  inset: 0 0 auto 0;
  height: 3px;
  background: var(--gradient);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform .35s;
}
.card:hover { transform: translateY(-4px); box-shadow: var(--shadow); }
.card:hover::before { transform: scaleX(1); }
.card__icon {
  width: 48px; height: 48px;
  display: grid; place-items: center;
  border-radius: 12px;
  background: var(--blue-soft);
  color: var(--blue-strong);
  margin-bottom: 22px;
}
.card__icon svg { width: 24px; height: 24px; }
.card h3 { font-size: 1.2rem; margin-bottom: 8px; }
.card p { color: var(--muted); }
.card__list { list-style: none; margin: 22px 0 26px; display: grid; gap: 10px; }
.card__list li { position: relative; padding-left: 24px; font-size: .95rem; }
.card__list li::before, .checks li::before {
  content: "";
  position: absolute;
  left: 2px; top: .38em;
  width: 5px; height: 10px;
  border: solid var(--blue);
  border-width: 0 2px 2px 0;
  transform: rotate(45deg);
}
.card__link { margin-top: auto; font-weight: 500; color: var(--blue-strong); }
.card__link::after { content: " →"; transition: margin .2s; }
.card__link:hover::after { margin-left: 4px; }

/* ===== Dall'archivio al portfolio ===== */
.pipeline {
  list-style: none;
  position: relative;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 32px;
}
/* Linea che collega i tre passaggi, con un punto luminoso che scorre */
.pipeline::before, .pipeline::after {
  content: "";
  position: absolute;
  top: 28px;
  left: calc(16.66% - 8px);
  right: calc(16.66% - 8px);
  height: 2px;
}
.pipeline::before { background: var(--line); }
.pipeline::after {
  background: linear-gradient(90deg, transparent, var(--blue), var(--teal), transparent);
  background-size: 30% 100%;
  background-repeat: no-repeat;
  animation: pipeline-flow 3.2s ease-in-out infinite;
}
@keyframes pipeline-flow {
  from { background-position: -40% 0; }
  to { background-position: 140% 0; }
}
@keyframes pipeline-flow-v {
  from { background-position: 0 -40%; }
  to { background-position: 0 140%; }
}
.pipeline__step { position: relative; z-index: 1; text-align: center; padding: 0 8px; }
.pipeline__icon {
  width: 58px; height: 58px;
  margin: 0 auto 20px;
  display: grid; place-items: center;
  border-radius: 50%;
  background: #fff;
  border: 1px solid var(--line);
  color: var(--blue-strong);
  box-shadow: 0 0 0 8px var(--bg);
}
.pipeline__icon svg { width: 24px; height: 24px; }
.pipeline__num { font-size: .85rem; font-weight: 500; color: var(--blue-strong); }
.pipeline__step h3 { font-size: 1.2rem; margin: 6px 0 8px; }
.pipeline__step p { color: var(--muted); max-width: 300px; margin: 0 auto; }

/* ===== Lavori (casi studio) ===== */
.case {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 20px 20px 26px;
}
.case__img {
  aspect-ratio: 16 / 10;
  border-radius: 10px;
  margin-bottom: 18px;
  background: var(--surface) center / cover no-repeat;
}
.case__tag { font-size: .8rem; color: var(--blue-strong); font-weight: 500; margin-bottom: 6px; }
.case h3 { font-size: 1.15rem; margin-bottom: 8px; }
.case p { color: var(--muted); }
.case__result { margin-top: 12px; color: var(--ink) !important; font-weight: 500; }
.case blockquote { margin-top: 16px; padding-left: 14px; border-left: 2px solid var(--blue); color: var(--text); font-size: .95rem; }
.case cite { display: block; margin-top: 6px; font-style: normal; color: var(--muted); font-size: .85rem; }

/* ===== Metodo ===== */
.steps { list-style: none; display: grid; grid-template-columns: repeat(4, 1fr); gap: 24px; }
.step { position: relative; padding-top: 28px; border-top: 1px solid rgba(255, 255, 255, .15); }
.step::before {
  content: "";
  position: absolute;
  top: -1px; left: 0;
  width: 48px; height: 2px;
  background: var(--gradient);
}
.step__num { font-weight: 500; color: var(--teal); font-size: .9rem; }
.step h3 { font-size: 1.25rem; margin: 10px 0 6px; }
.step p { color: rgba(255, 255, 255, .68); }

/* ===== Visione ===== */
.vision { display: grid; grid-template-columns: 1.2fr .8fr; gap: 80px; align-items: center; }
.vision__text h2 { margin-bottom: 24px; }
.vision__text p:not(.eyebrow) { color: var(--muted); font-size: 1.08rem; margin-bottom: 16px; max-width: 580px; }
.values { list-style: none; display: flex; flex-wrap: wrap; gap: 10px; margin-top: 28px; }
.values li {
  padding: 8px 16px;
  border: 1px solid var(--line);
  border-radius: 99px;
  font-weight: 450;
  font-size: .92rem;
  color: var(--ink);
}
.team { display: grid; gap: 14px; }
.member {
  display: flex; align-items: center; gap: 18px;
  padding: 20px 22px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: #fff;
  transition: box-shadow .25s, transform .25s;
}
.member:hover { box-shadow: var(--shadow); transform: translateX(4px); }
.member__avatar {
  width: 52px; height: 52px;
  flex-shrink: 0;
  display: grid; place-items: center;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--blue-strong), var(--navy));
  color: #fff;
  font-weight: 500;
  letter-spacing: .04em;
}
.member h3 { font-size: 1.05rem; }
.member p { color: var(--muted); font-size: .92rem; }

/* ===== Contatti ===== */
.contact { display: grid; grid-template-columns: .9fr 1.1fr; gap: 72px; align-items: start; }
.checks { list-style: none; display: grid; gap: 12px; margin: 28px 0; }
.checks li { position: relative; padding-left: 26px; color: var(--ink); }
.contact__mail { color: var(--muted); }
.contact__mail a { color: var(--blue-strong); font-weight: 500; }
.form {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 18px;
  padding: 32px;
  box-shadow: var(--shadow);
  display: grid; gap: 18px;
}
.form__row { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; }
.form label { display: grid; gap: 6px; font-weight: 500; font-size: .9rem; color: var(--ink); }
.optional { font-weight: 400; color: var(--muted); }
.form input:not([type="checkbox"]), .form textarea, .form select {
  width: 100%;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 10px;
  padding: 12px 14px;
  color: var(--ink);
  font: 400 1rem var(--font);
  resize: vertical;
  transition: border-color .2s, background .2s;
}
.form input:focus, .form textarea:focus, .form select:focus {
  outline: none;
  border-color: var(--blue);
  background: #fff;
  box-shadow: 0 0 0 3px var(--blue-soft);
}
.form .consent { display: flex; align-items: flex-start; gap: 10px; font-weight: 400; color: var(--muted); }
.consent input { margin-top: 4px; width: 16px; height: 16px; accent-color: var(--blue-strong); flex-shrink: 0; }
.consent a { color: var(--blue-strong); text-decoration: underline; }
.form__status { font-size: .9rem; color: var(--blue-strong); min-height: 1.2em; }

/* ===== Footer ===== */
.footer { border-top: 1px solid var(--line); padding-top: 64px; }
.footer__grid { display: grid; grid-template-columns: repeat(3, auto); justify-content: center; align-items: start; gap: 32px clamp(20px, 6vw, 110px); text-align: left; }
.footer h4 {
  font-weight: 500;
  font-size: .75rem;
  letter-spacing: .14em;
  text-transform: uppercase;
  color: var(--muted);
  margin-bottom: 14px;
}
.footer__grid a { display: block; color: var(--text); margin-bottom: 8px; font-size: .95rem; }
.footer__grid a:hover { color: var(--blue-strong); }
.footer__bottom { margin-top: 48px; padding-top: 24px; padding-bottom: 32px; border-top: 1px solid var(--line); display: flex; align-items: center; justify-content: center; gap: 18px; flex-wrap: wrap; }
.footer__bottom img { height: 28px; width: auto; }
.footer__bottom p { color: var(--muted); font-size: .88rem; }
.footer__bottom a:hover { color: var(--blue-strong); }
.legal + .footer { padding-top: 0; }
.legal + .footer .footer__bottom { margin-top: 0; border-top: 0; }

/* ===== Pagine legali ===== */
.legal { max-width: 780px; margin: 0 auto; padding: 130px 24px 90px; }
.legal h1 { font-size: clamp(2rem, 4vw, 2.6rem); margin-bottom: 10px; }
.legal__updated { color: var(--muted); margin-bottom: 40px; }
.legal h2 { font-size: 1.3rem; margin: 40px 0 12px; }
.legal p, .legal li { color: var(--text); margin-bottom: 12px; }
.legal ul { padding-left: 22px; margin-bottom: 12px; }
.legal a { color: var(--blue-strong); text-decoration: underline; }
/* Segnaposto da completare prima della pubblicazione */
.todo { background: #fff3c4; color: #7a5800; padding: 1px 6px; border-radius: 4px; font-weight: 600; }

/* ===== Luce trasparente che segue il mouse ===== */

/* Riflesso dentro card e riquadri, nel punto in cui si trova il mouse */
.card, .member, .archive { position: relative; isolation: isolate; }
.card::after, .member::after, .archive::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  border-radius: inherit;
  background: radial-gradient(320px circle at var(--mx, 50%) var(--my, 50%), rgba(6, 125, 243, .08), transparent 60%);
  opacity: 0;
  transition: opacity .4s;
  pointer-events: none;
}
.card:hover::after, .member:hover::after, .archive:hover::after { opacity: 1; }

/* ===== Comparsa allo scroll ===== */
.reveal { opacity: 0; transform: translateY(20px); transition: opacity .6s ease, transform .6s ease; }
.reveal.visible { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .reveal { opacity: 1; transform: none; transition: none; }
  .caret, .pipeline::after { animation: none; }
}

/* ===== Responsive ===== */
@media (max-width: 960px) {
  .hero__inner, .vision, .contact { grid-template-columns: 1fr; gap: 56px; }
  .hero { padding: 130px 0 90px; }
  .hero__visual { max-width: 520px; }
  .grid--3 { grid-template-columns: 1fr; }
  .steps { grid-template-columns: repeat(2, 1fr); row-gap: 40px; }
  /* Su schermi stretti la linea della pipeline diventa verticale */
  .pipeline { grid-template-columns: 1fr; gap: 40px; }
  .pipeline::before, .pipeline::after {
    top: 28px; bottom: 28px;
    left: 50%; right: auto;
    width: 2px; height: auto;
    transform: translateX(-1px);
  }
  .pipeline::after {
    background: linear-gradient(180deg, transparent, var(--blue), var(--teal), transparent);
    background-size: 100% 30%;
    animation-name: pipeline-flow-v;
  }
  .pipeline__step { background: var(--bg); padding: 8px; }
}

@media (max-width: 720px) {
  .nav__toggle { display: block; }
  .nav__links {
    position: absolute;
    top: 72px; left: 0; right: 0;
    display: none;
    flex-direction: column;
    align-items: stretch;
    gap: 18px;
    padding: 24px;
    background: #fff;
    border-bottom: 1px solid var(--line);
  }
  .nav__links.open { display: flex; }
  .nav__toggle.open span:first-child { transform: translateY(4px) rotate(45deg); }
  .nav__toggle.open span:last-child { transform: translateY(-4px) rotate(-45deg); }
  .section { padding: 80px 0; }
  .container { padding: 0 16px; }
  .float-badge { left: 12px; bottom: -20px; }
  .steps, .form__row { grid-template-columns: 1fr; }
  .form { padding: 22px; }
    }

/* ===== Hero 3D: solo l'edificio, si scompone con un clic o scorrendo ===== */
.scena { --sh: max(440px, 100svh); position: relative; background: #f3f5f8; height: calc(var(--sh) + 120vh); }
.scena__stage { position: sticky; top: 0; height: var(--sh); overflow: hidden; }
.sr-only { position: absolute; width: 1px; height: 1px; margin: -1px; padding: 0; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0; }
.scena__intro { position: absolute; z-index: 2; left: clamp(24px, 6vw, 160px); top: 50%; transform: translateY(-50%); width: min(440px, 34vw); pointer-events: none; transition: opacity .5s ease; }
.is-open .scena__intro { opacity: 0; visibility: hidden; transition: opacity .5s ease, visibility 0s .5s; }
.scena__logo { display: block; width: clamp(220px, 24vw, 340px); height: auto; margin-bottom: 30px; }
.scena__intro h1 { font-size: clamp(1.9rem, 3.3vw, 3rem); line-height: 1.04; letter-spacing: -0.035em; margin-bottom: 18px; }
.scena__intro p { font-size: clamp(.95rem, 1.25vw, 1.08rem); color: var(--muted); }
.scena__hint { display: flex; align-items: center; gap: 10px; margin-top: 26px; font-weight: 500; color: var(--blue-strong) !important; }
.scena__hint svg { width: 22px; height: 22px; flex: none; animation: fbBob 1.8s ease-in-out infinite; }
@keyframes fbBob { 0%, 100% { transform: translateY(-2px) } 50% { transform: translateY(4px) } }
#fb-canvas { position: absolute; inset: 0; width: 100%; height: 100%; display: block; }

/* i pannelli si ridimensionano con la finestra: tutto in em, la scala arriva da --ps */
.fb-panels { position: absolute; inset: 0; pointer-events: none; font-size: calc(16px * var(--ps, 1)); }
.fb-panel { position: absolute; left: 0; top: 0; width: 17.5em; pointer-events: auto; background: rgba(255, 255, 255, .96); border: 1px solid var(--line); border-radius: 1em; padding: 1.1em 1.25em; box-shadow: 0 .9em 2.1em rgba(15, 28, 48, .10); }
.fb-panel .fb-eye { display: flex; align-items: center; gap: .5em; margin: 0 0 .4em; font-size: .75em; font-weight: 600; letter-spacing: .14em; text-transform: uppercase; color: var(--blue-strong); }
.fb-panel h2 { margin: 0 0 .3em; font-size: 1.2em; line-height: 1.15; }
.fb-panel p { margin: 0 0 .7em; font-size: .85em; line-height: 1.5; color: var(--muted); }
.fb-panel .fb-mep { margin: 0 0 .6em; font-size: .75em; letter-spacing: .04em; }
.fb-panel .fb-mep b { color: var(--ink); }
.fb-panel ul { margin: 0 0 .9em; padding: 0; list-style: none; display: flex; flex-direction: column; gap: .45em; font-size: .82em; font-weight: 500; color: var(--ink); }
.fb-panel li { display: flex; align-items: center; gap: .7em; }
.fb-sw { width: 1.7em; height: .9em; border-radius: .25em; flex: none; }
.fb-dash { color: var(--blue-strong); font-weight: 700; width: 1.7em; text-align: center; flex: none; }
.fb-letter { margin-left: auto; font-size: .9em; font-weight: 700; color: var(--muted); }
.fb-more { font-size: .9em; font-weight: 600; color: var(--blue-strong); }
.fb-more:hover { color: var(--navy); }
.fb-state { font-size: .85em; letter-spacing: .04em; text-transform: none; padding: .15em .65em; border-radius: 999px; background: #fff4d6; color: #8a5a00; border: 1px solid #f2d98a; white-space: nowrap; }
.fb-state--live { background: #e3f8ee; color: #0b6b44; border-color: #a8e6c6; }
.fb-panel--soon { border-style: dashed; }
#fb-leads { position: absolute; left: 0; top: 0; width: 100%; height: 100%; overflow: visible; pointer-events: none; }
@keyframes fbIn { from { opacity: 0 } to { opacity: 1 } }
.fb-in { animation: fbIn .6s .55s both ease-out; }

@media (max-width: 860px) {
  .scena { height: auto; }
  .scena__stage { position: relative; top: 0; height: auto; overflow: visible; }
  #fb-canvas { position: relative; height: max(420px, 100svh); }
  .fb-panels { position: static; display: block; }
  #fb-open { display: flex; flex-direction: column; gap: 14px; padding: 16px; }
  #fb-open[hidden] { display: none; }
  .fb-panel { position: static !important; width: auto !important; }
  #fb-site { padding: 0 16px 24px; }
  #fb-site[hidden] { display: none; }
  #fb-leads { display: none !important; }
}
@media (prefers-reduced-motion: reduce) { .fb-in, .scena__hint svg { animation: none; } }

/* finestra stretta o alta: presentazione sotto l'edificio */
.is-stacked .scena__intro { top: auto; bottom: 0; right: 0; left: 0; width: auto; transform: none; padding: 56px 20px 24px; background: linear-gradient(to top, #f3f5f8 70%, rgba(243,245,248,0)); }
.is-stacked .scena__logo { width: min(240px, 62vw); margin-bottom: 14px; }
.is-stacked .scena__intro h1 { font-size: 1.9rem; margin-bottom: 10px; }
.is-stacked .scena__intro p:not(.scena__hint) { font-size: .9rem; }
.is-stacked .scena__hint { margin-top: 14px; font-size: .9rem; }

@media (max-width: 560px) { .footer__grid a { font-size: .82rem; } .footer h4 { letter-spacing: .08em; } }

/* intestazione dei pannelli: marchio del programma + nome nel carattere del logo */
.fb-head { display: flex; align-items: center; gap: .55em; flex-wrap: wrap; margin-bottom: .55em; }
.fb-mark { width: 2em; height: 2em; object-fit: contain; flex: none; }
.fb-name { font-family: "Outfit", var(--font); font-weight: 600; font-size: 1.4em; letter-spacing: -.02em; color: var(--ink); line-height: 1; }
.fb-head .fb-state { font-size: .72em; }
/* titolo della fase «programmi» */
.fb-title { position: absolute; left: 50%; top: 3.5%; transform: translateX(-50%); width: calc(100% - 2 * (17.5em + 70px)); min-width: 17em; text-align: center; font-size: 1.7em; line-height: 1.1; letter-spacing: -.03em; pointer-events: none; }
.fb-title span { color: var(--blue-strong); }
/* fase «cantiere»: presentazione per i professionisti, impostata come la pagina iniziale */
.scena__pitch { position: absolute; z-index: 2; left: clamp(24px, 6vw, 160px); top: 50%; transform: translateY(-50%); width: min(470px, 36vw); pointer-events: auto; }
.scena__pitch[hidden] { display: none; }
.pitch__tag { font-size: .72rem; font-weight: 600; letter-spacing: .14em; text-transform: uppercase; color: var(--blue-strong); margin-bottom: 12px; }
.scena__pitch h2 { font-size: clamp(1.7rem, 2.9vw, 2.6rem); line-height: 1.06; letter-spacing: -0.03em; margin-bottom: 16px; }
.scena__pitch > p { font-size: clamp(.9rem, 1.1vw, 1rem); color: var(--muted); margin-bottom: 20px; }
.pitch__list { list-style: none; display: grid; gap: 4px; }
.pitch__list a { display: flex; align-items: flex-start; gap: 14px; padding: 10px 12px; margin: 0 -12px; border-radius: 12px; transition: background .2s; }
.pitch__list a:hover { background: rgba(255, 255, 255, .8); }
.pitch__list b { font-size: .78rem; font-weight: 600; color: var(--blue-strong); border: 1.5px solid var(--blue-strong); border-radius: 6px; padding: 1px 7px; flex: none; margin-top: 2px; }
.pitch__list span { font-weight: 600; color: var(--ink); font-size: .95rem; }
.pitch__list small { display: block; font-weight: 400; font-size: .82rem; color: var(--muted); line-height: 1.4; margin-top: 2px; }
@media (max-width: 860px) {
  .fb-title { position: static; transform: none; width: auto; font-size: 1.5em; padding: 4px 4px 14px; }
  .scena__pitch { position: static; transform: none; width: auto; padding: 8px 20px 36px; }
}

/* home: punti di forza e inviti all'azione */
.scena__chips { list-style: none; display: flex; flex-wrap: wrap; gap: 8px; margin-top: 18px; }
.scena__chips li { font-size: .78rem; font-weight: 500; color: var(--blue-strong); background: var(--blue-soft); border: 1px solid #cfe0fb; border-radius: 999px; padding: 4px 12px; }
.scena__cta { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 22px; pointer-events: auto; }
.scena__cta .btn { padding: 12px 22px; font-size: .95rem; }
.is-stacked .scena__chips { display: none; }
.is-stacked .scena__cta { margin-top: 14px; }
.is-stacked .scena__cta .btn { padding: 10px 16px; font-size: .85rem; }
/* fascia finale delle pagine interne */
.cta-band { background: linear-gradient(120deg, #073695 0%, #0169e9 60%, #3fe4d1 140%); color: #fff; padding: 64px 0; text-align: center; }
.cta-band h2 { color: #fff; font-size: clamp(1.5rem, 3vw, 2.1rem); margin-bottom: 12px; }
.cta-band p { color: rgba(255, 255, 255, .85); max-width: 560px; margin: 0 auto 26px; }
.cta-band .btn { background: #fff; color: var(--navy); }
.cta-band .btn:hover { background: var(--blue-soft); }
.note-soon { margin-top: 36px; padding: 22px 26px; border: 1px dashed #bcd6fb; border-radius: var(--radius); background: #fff; color: var(--muted); }
.note-soon a { color: var(--blue-strong); font-weight: 600; }

.pitch__cta { margin-top: 18px; }
.pitch__cta .btn { padding: 12px 22px; font-size: .95rem; }
