/* ============================================================
 * LEM s.r.l. - Eventi e Comunicazione
 * Sito ufficiale - stile editoriale istituzionale
 * Palette: neutri caldi + verde petrolio (#245A52)
 * ============================================================ */

:root {
  /* ---------- Colori base (light editorial) ---------- */
  --bg: #F5F4F0;
  --bg-2: #EEEDE8;
  --bg-3: #E5E4DE;
  --surface: #FFFFFF;
  --surface-2: #EEEDE8;
  --surface-hover: #F0EFEA;
  --border: #D9D8D3;
  --border-strong: #C4C3BD;
  --line: #D9D8D3;

  /* ---------- Accento principale (verde petrolio) ---------- */
  --accent: #245A52;
  --accent-dark: #1A433D;
  --accent-light: #2E6B62;
  --accent-soft: rgba(36, 90, 82, 0.08);
  --accent-soft-strong: rgba(36, 90, 82, 0.14);

  /* ---------- Legacy LEM (mapped to accent) ---------- */
  --lem: #245A52;
  --lem-dark: #1A433D;
  --lem-light: #245A52;
  --lem-burgundy: #245A52;

  /* ---------- Legacy AI (mapped to accent, no purple) ---------- */
  --ai-cyan: #245A52;
  --ai-violet: #245A52;
  --ai-blue: #245A52;

  /* ---------- Testi ---------- */
  --text: #171717;
  --text-2: #686868;
  --text-muted: #686868;
  --muted: #686868;
  --text-dim: #8A8A8A;

  /* ---------- Tipografia ---------- */
  --font-sans: "DM Sans", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  --font-display: "Source Serif 4", Georgia, "Times New Roman", serif;
  --font-mono: ui-monospace, "SF Mono", Consolas, monospace;

  /* ---------- Ombre (sottili, no glow) ---------- */
  --shadow-sm: 0 1px 3px rgba(23, 23, 23, 0.06);
  --shadow: 0 2px 8px rgba(23, 23, 23, 0.08);
  --shadow-lg: 0 4px 16px rgba(23, 23, 23, 0.10);

  --radius-sm: 2px;
  --radius: 2px;
  --radius-lg: 2px;
  --radius-xl: 2px;

  --max-w: 1240px;
  --max-w-narrow: 980px;

  --nav-h: 74px;

  /* Top header wash (mint/teal → page bg) — ecosistema-booking presentazione */
  --header-wash-mint: #E8F0EE;
  --header-wash-radial: radial-gradient(ellipse 80% 60% at 50% 0%, rgba(36, 90, 82, 0.12), transparent 60%);
  --header-wash-linear: linear-gradient(180deg, var(--header-wash-mint) 0%, var(--bg) 55%);
  --header-wash-bg: var(--header-wash-radial), var(--header-wash-linear);
  --header-wash-height: min(520px, 55vh);
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

html, body {
  margin: 0;
  padding: 0;
  font-family: var(--font-sans);
  color: var(--text);
  background-color: var(--bg);
  background-image: var(--header-wash-bg);
  background-repeat: no-repeat;
  background-size: 100% var(--header-wash-height);
  background-position: top center;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  line-height: 1.6;
  font-size: 16px;
}

img { max-width: 100%; height: auto; display: block; }

a {
  color: var(--accent);
  text-decoration: none;
  transition: color 0.2s ease;
}
a:hover { color: var(--accent-dark); }

::selection { background: var(--accent-soft-strong); color: var(--text); }

/* ============================================================
 * NAVIGATION
 * ============================================================ */
.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: var(--surface);
  border-bottom: 1px solid var(--border);
}

.nav {
  max-width: var(--max-w);
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px 24px;
  gap: 24px;
  min-height: var(--nav-h);
}

.nav__brand {
  display: flex;
  align-items: center;
  gap: 12px;
  color: var(--text);
  font-weight: 700;
  line-height: 1;
  flex-shrink: 0;
}

.nav__brand img {
  height: 44px;
  width: auto;
  object-fit: contain;
  image-rendering: -webkit-optimize-contrast;
}

.nav__brand-text {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.nav__brand-name {
  font-family: var(--font-display);
  font-size: 18px;
  font-weight: 700;
  letter-spacing: -0.01em;
  color: var(--text);
}

.nav__brand-tagline {
  font-size: 10px;
  letter-spacing: 2.5px;
  color: var(--text-muted);
  text-transform: uppercase;
  font-weight: 500;
}

.nav__links {
  display: flex;
  gap: 4px;
  align-items: center;
  list-style: none;
  margin: 0;
  padding: 0;
}

.nav__links a {
  color: var(--text-2);
  font-size: 14px;
  font-weight: 500;
  letter-spacing: 0.01em;
  padding: 9px 14px;
  border-radius: var(--radius-sm);
  transition: color 0.2s ease, background 0.2s ease;
  border: 1px solid transparent;
}

.nav__links a:hover {
  color: var(--text);
  background: var(--surface-hover);
}

.nav__links a.active {
  color: var(--surface);
  background: var(--accent);
  border-color: var(--accent);
}

.nav__toggle {
  display: none;
  background: transparent;
  border: 1px solid var(--border-strong);
  border-radius: var(--radius-sm);
  padding: 9px 12px;
  cursor: pointer;
  color: var(--text);
  font-size: 20px;
  line-height: 1;
}

@media (max-width: 960px) {
  .nav__toggle {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 44px;
    min-height: 44px;
    color: #fff;
    background: var(--accent);
    border-color: var(--accent);
  }
  .nav__toggle:hover,
  .nav__toggle:focus-visible {
    color: #fff;
    background: var(--accent-dark);
    border-color: var(--accent-dark);
  }
  .nav { position: relative; }
  .nav__links {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    flex-direction: column;
    align-items: stretch;
    background: var(--surface);
    border-bottom: 1px solid var(--border);
    padding: 20px 24px 28px 24px;
    gap: 14px;
  }
  .nav__links.open { display: flex; }
  .nav__links a {
    padding: 18px 18px;
    min-height: 48px;
    width: 100%;
    font-size: 17px;
    line-height: 1.35;
    border-radius: var(--radius-sm);
  }
  .nav__links a.active {
    color: var(--accent);
    background: transparent;
    border: 2px solid var(--accent);
  }
  .nav__links a.active:hover {
    color: var(--accent-dark);
    background: var(--accent-soft);
    border-color: var(--accent-dark);
  }
  .nav__brand-name { font-size: 16px; }
  .nav__brand img {
    height: 44px;
    width: auto;
  }

  /* Mobile body copy — darker for readability */
  body {
    color: #121212;
  }
  p,
  .hero__subtitle,
  .hero__lead,
  .section__intro,
  .events-spotlight__lead,
  .events-spotlight__phase p,
  .card p,
  .service p,
  .project-card__desc,
  .thesis__item,
  .geo-audit__lead,
  .project-section p {
    color: #1a1a1a;
  }
}

@media (max-width: 640px) {
  .nav__brand-text { display: none; }
}

/* ============================================================
 * TYPOGRAPHY
 * ============================================================ */
h1, h2, h3, h4, h5 {
  font-family: var(--font-display);
  font-weight: 700;
  color: var(--text);
  letter-spacing: -0.02em;
  line-height: 1.15;
  margin: 0 0 14px 0;
}

h1 { font-size: clamp(38px, 6vw, 68px); }
h2 { font-size: clamp(30px, 4.5vw, 46px); }
h3 { font-size: clamp(20px, 2.5vw, 26px); font-weight: 600; }
h4 { font-size: 18px; }

p { color: var(--text-2); margin: 0 0 16px 0; }

strong { color: var(--text); font-weight: 600; }

em {
  font-family: var(--font-display);
  font-style: italic;
  font-weight: 600;
  color: var(--accent);
}

.em--ai {
  font-family: var(--font-display);
  font-style: italic;
  font-weight: 600;
  color: var(--accent);
}

/* ============================================================
 * HERO
 * ============================================================ */
.hero {
  position: relative;
  padding: 90px 24px 100px 24px;
  overflow: hidden;
  background: var(--header-wash-bg);
  border-bottom: 1px solid var(--border);
}

.hero__inner {
  position: relative;
  max-width: var(--max-w);
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1.15fr 1fr;
  gap: 60px;
  align-items: center;
}

.hero__badge {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 8px 16px;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  font-size: 12px;
  letter-spacing: 0.12em;
  color: var(--text-2);
  text-transform: uppercase;
  margin-bottom: 26px;
  font-weight: 600;
  background: var(--surface);
}

.hero__badge::before {
  content: "";
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--accent);
  flex-shrink: 0;
}

.hero__badge--accent {
  color: var(--accent);
  border-color: rgba(36, 90, 82, 0.28);
  background: var(--accent-soft);
}

.hero__title {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: clamp(42px, 6.4vw, 76px);
  line-height: 1.02;
  margin: 0 0 18px 0;
  color: var(--text);
  letter-spacing: -0.035em;
}

.hero__subtitle {
  font-size: clamp(18px, 2vw, 22px);
  color: var(--text-2);
  margin: 0 0 28px 0;
  line-height: 1.5;
  max-width: 600px;
  font-weight: 400;
}

.hero__lead {
  font-size: 16px;
  line-height: 1.7;
  color: var(--text-2);
  margin: 0 0 20px 0;
  max-width: 600px;
}

.hero__tags {
  font-size: 13px;
  letter-spacing: 0.04em;
  color: var(--text-muted);
  margin: 0 0 32px 0;
  max-width: 600px;
}

.hero__cta {
  display: flex;
  gap: 14px;
  flex-wrap: wrap;
}

.hero__figure {
  position: relative;
  display: flex;
  justify-content: center;
  align-items: center;
}

/* Editorial aside (stats grid) */
.glass-card {
  position: relative;
  width: 100%;
  max-width: 460px;
  padding: 32px 30px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: var(--shadow-sm);
  overflow: hidden;
}

.glass-card__logo {
  margin-bottom: 24px;
}
.glass-card__logo img {
  max-width: 240px;
  object-fit: contain;
}

.glass-card__grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 22px 20px;
  margin-top: 22px;
}

.glass-stat {
  border-left: 2px solid var(--accent);
  padding-left: 14px;
}

.glass-stat__value {
  font-family: var(--font-display);
  font-size: 30px;
  font-weight: 700;
  color: var(--text);
  line-height: 1;
  letter-spacing: -0.02em;
}

.glass-stat__label {
  font-size: 11px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--text-muted);
  margin-top: 6px;
  font-weight: 500;
}

@media (max-width: 900px) {
  .hero { padding: 60px 20px 70px 20px; }
  .hero__inner { grid-template-columns: 1fr; gap: 50px; }
  .glass-card { max-width: 100%; padding: 26px 22px; }
}

/* ============================================================
 * HOME INTRO + CONCEPT MAP
 * ============================================================ */
body.home-intro-pending {
  overflow: hidden;
}

body.home-intro-pending #site-header,
body.home-intro-pending .home-main,
body.home-intro-pending #site-footer {
  visibility: hidden;
}

body.home-intro-done #site-header,
body.home-intro-done .home-main,
body.home-intro-done #site-footer {
  visibility: visible;
  animation: home-content-in 0.7s ease forwards;
}

@keyframes home-content-in {
  from { opacity: 0; }
  to { opacity: 1; }
}

.hero-intro {
  position: fixed;
  inset: 0;
  z-index: 500;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--bg);
  transition: opacity 0.45s ease, visibility 0.45s ease;
}

.hero-intro.is-dismissed {
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
}

.hero-intro__content {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 28px;
  padding: 24px;
  text-align: center;
}

.hero-intro__hub {
  width: min(220px, 52vw);
  aspect-ratio: 1;
}

.hero-intro__hub-svg {
  display: block;
  width: 100%;
  height: 100%;
  overflow: visible;
}

.hero-intro__tagline {
  max-width: 520px;
  margin: 0;
  font-family: var(--font-display);
  font-size: clamp(1.15rem, 3.2vw, 1.45rem);
  font-weight: 500;
  line-height: 1.35;
  color: var(--text);
  opacity: 0;
  transform: translateY(14px);
  transition: opacity 0.55s ease, transform 0.55s ease;
}

.hero-intro__tagline em {
  font-style: italic;
  color: var(--accent);
}

.hero-intro__content.is-tagline .hero-intro__tagline {
  opacity: 1;
  transform: translateY(0);
}

.intro-hub {
  opacity: 0;
  transform: scale(0.88);
  transform-origin: center;
  transform-box: fill-box;
  transition: opacity 0.45s ease, transform 0.45s ease;
}

.hero-intro__content.is-active .intro-hub,
.concept-map-stage.is-active .intro-hub,
.concept-hub-mini.is-active .intro-hub {
  opacity: 1;
  transform: scale(1);
}

.intro-waves .intro-wave {
  opacity: 0;
  transform: scale(1);
  transform-origin: center;
  transform-box: fill-box;
}

.hero-intro__content.is-pulsing .intro-waves .intro-wave,
.concept-map-stage.is-pulsing .intro-waves .intro-wave,
.concept-hub-mini.is-pulsing .intro-waves .intro-wave {
  animation: map-wave-pulse 1.6s ease-out infinite;
}

.hero-intro__content.is-pulsing .intro-waves .intro-wave--2,
.concept-map-stage.is-pulsing .intro-waves .intro-wave--2,
.concept-hub-mini.is-pulsing .intro-waves .intro-wave--2 {
  animation-delay: 0.53s;
}

.hero-intro__content.is-pulsing .intro-waves .intro-wave--3,
.concept-map-stage.is-pulsing .intro-waves .intro-wave--3,
.concept-hub-mini.is-pulsing .intro-waves .intro-wave--3 {
  animation-delay: 1.06s;
}

.hero-intro__content.is-tagline .intro-waves .intro-wave,
.hero-intro__content.is-dismissed .intro-waves .intro-wave,
.concept-map-stage.is-revealed .intro-waves .intro-wave {
  animation: none;
  opacity: 0;
}

@keyframes map-wave-pulse {
  0% {
    opacity: 0.5;
    transform: scale(1);
  }
  100% {
    opacity: 0;
    transform: scale(2.4);
  }
}

/* Mappa inline (servizi e pagine interne) */
.concept-map-section {
  padding: 0;
  max-width: none;
  background: var(--bg);
  border-bottom: 1px solid var(--border);
}

.concept-map-stage {
  position: relative;
  width: 100%;
  background: var(--bg);
}

/* Ritaglio intestazione (logo LEM) e claim in fondo al PNG — sostituiti dal footer HTML */
.concept-map-stage__frame {
  position: relative;
  width: 100%;
  overflow: hidden;
  aspect-ratio: 1448 / 720;
  line-height: 0;
}

.concept-map-stage__img {
  position: absolute;
  left: 0;
  top: -20%;
  display: block;
  width: 100%;
  max-width: none;
  height: auto;
  margin: 0;
  opacity: 0;
}

.concept-map-stage.is-revealed .concept-map-stage__img {
  animation: map-img-materialize 1.2s ease forwards;
}

@keyframes map-img-materialize {
  0% {
    opacity: 0;
    filter: blur(8px);
    transform: scale(0.985);
  }
  100% {
    opacity: 1;
    filter: blur(0);
    transform: scale(1);
  }
}

.concept-map-stage__intro {
  position: absolute;
  left: 0;
  top: -20%;
  width: 100%;
  height: auto;
  aspect-ratio: 1448 / 1086;
  pointer-events: none;
  overflow: visible;
  opacity: 1;
  transition: opacity 0.6s ease;
}

.concept-map-stage__intro--mobile {
  display: none;
}

.concept-map-stage.is-revealed .concept-map-stage__intro {
  opacity: 0;
}

.concept-map-stage__footer {
  padding: 20px 24px 28px;
  text-align: center;
  border-top: 1px solid var(--border);
}

.concept-map-stage__claim {
  margin: 0 0 10px;
  font-family: var(--font-display);
  font-size: clamp(1.05rem, 2.4vw, 1.35rem);
  font-weight: 500;
  line-height: 1.35;
  color: var(--text);
}

.concept-map-stage__claim em {
  font-style: italic;
  color: var(--accent);
}

.concept-map-stage__meta {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: 6px 14px;
  margin: 0;
  font-size: clamp(0.78rem, 1.8vw, 0.92rem);
  line-height: 1.5;
  color: var(--text-muted);
}

.concept-map-stage__meta a {
  color: var(--accent);
  text-decoration: none;
}

.concept-map-stage__meta a:hover {
  text-decoration: underline;
}

.concept-map-mobile {
  display: none;
  padding: 0 20px 8px;
}

.concept-map-mobile__claim {
  margin: 0 0 14px;
  padding: 0 4px;
  font-family: var(--font-display);
  font-size: clamp(1.05rem, 4.2vw, 1.25rem);
  font-weight: 500;
  line-height: 1.35;
  text-align: center;
  color: var(--text);
}

.concept-map-mobile__claim em {
  font-style: italic;
  color: var(--accent);
}

.concept-map-mobile__grid {
  display: grid;
  gap: 12px;
}

.concept-map-mobile__zone {
  padding: 14px 12px 12px;
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: 10px;
}

.concept-map-mobile__zone h3 {
  margin: 0 0 8px;
  font-family: var(--font-sans);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--accent);
}

.concept-map-mobile__items {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px 6px;
}

.concept-map-mobile__item {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
  text-align: center;
  color: var(--text);
}

.concept-map-mobile__item span {
  display: block;
  font-size: 10px;
  line-height: 1.25;
  color: var(--text-muted);
  hyphens: auto;
}

.concept-map-mobile__icon {
  flex: 0 0 auto;
  width: 40px;
  height: 40px;
  display: block;
}

.concept-map-mobile__zone--cols-2 .concept-map-mobile__items {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.hero--after-map {
  padding-top: 48px;
}

/* Desktop: respiro sotto la sticky nav, etichette superiori non a filo header */
@media (min-width: 721px) {
  .concept-map-section {
    padding-top: 80px;
  }
}

@media (max-width: 720px) {
  .concept-map-stage__frame {
    aspect-ratio: auto;
    min-height: min(72vw, 320px);
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: visible;
    padding: 28px 20px 12px;
  }

  .concept-map-stage__img {
    display: none;
  }

  .concept-map-stage__intro--desktop {
    display: none;
  }

  .concept-map-stage__intro--mobile {
    display: block;
    position: relative;
    top: auto;
    left: auto;
    width: min(280px, 72vw);
    aspect-ratio: 1;
  }

  .concept-map-stage__footer {
    display: none;
    padding: 12px 18px 20px;
    border-top: none;
  }

  .concept-map-stage__footer .concept-map-stage__claim {
    display: none;
  }

  .concept-map-stage.is-revealed .concept-map-stage__frame {
    display: none;
  }

  .concept-map-stage.is-revealed .concept-map-mobile {
    display: block;
    animation: concept-map-mobile-in 0.5s ease forwards;
  }

  .concept-map-stage.is-revealed .concept-map-mobile__claim {
    animation: concept-map-mobile-in 0.45s ease forwards;
  }

  .concept-map-stage.is-revealed .concept-map-stage__footer {
    display: block;
    animation: concept-map-mobile-in 0.5s ease 0.2s forwards;
    opacity: 0;
  }

  .concept-map-stage.is-revealed .concept-map-mobile__zone {
    animation: concept-map-zone-in 0.45s ease forwards;
    opacity: 0;
    transform: translateY(10px);
  }

  .concept-map-stage.is-revealed .concept-map-mobile__zone:nth-child(1) { animation-delay: 0.08s; }
  .concept-map-stage.is-revealed .concept-map-mobile__zone:nth-child(2) { animation-delay: 0.16s; }
  .concept-map-stage.is-revealed .concept-map-mobile__zone:nth-child(3) { animation-delay: 0.24s; }
  .concept-map-stage.is-revealed .concept-map-mobile__zone:nth-child(4) { animation-delay: 0.32s; }

  .concept-map-stage__meta {
    flex-direction: column;
    gap: 4px;
  }
}

@keyframes concept-map-mobile-in {
  from {
    opacity: 0;
    transform: translateY(10px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes concept-map-zone-in {
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@media (prefers-reduced-motion: reduce) {
  .concept-map-stage__img {
    opacity: 1;
    filter: none;
    transform: none;
    animation: none;
  }

  .concept-map-stage__intro {
    display: none;
  }

  @media (max-width: 720px) {
    .concept-map-stage__frame {
      display: none;
    }

    .concept-map-mobile {
      display: block;
    }

    .concept-map-stage__footer {
      display: block;
    }
  }
}

/* Mappa in card hero */
.glass-card--map {
  padding: 10px;
  max-width: 540px;
}

.glass-card__map {
  display: block;
  width: 100%;
  margin: 0;
  padding: 0;
  border: none;
  background: none;
  cursor: zoom-in;
  border-radius: var(--radius-sm);
  overflow: hidden;
  line-height: 0;
}

.glass-card__map img {
  display: block;
  width: 100%;
  height: auto;
}

.glass-card__map-caption {
  margin: 10px 0 0;
  font-size: 11px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  font-weight: 600;
  color: var(--text-muted);
  text-align: center;
}

.glass-card--map:hover .glass-card__map-caption,
.glass-card--map:focus-within .glass-card__map-caption {
  color: var(--accent);
}

.glass-card__map:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 3px;
}

/* Card dati società (sotto hero) */
.home-stats-section {
  padding-top: 0;
  padding-bottom: 48px;
}

.home-stats-section .glass-card--stats {
  max-width: 520px;
  margin: 0 auto;
}

/* Lightbox mappa */
.map-lightbox {
  position: fixed;
  inset: 0;
  z-index: 600;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
  background: rgba(23, 23, 23, 0.94);
}

.map-lightbox[hidden] {
  display: none;
}

.map-lightbox img {
  display: block;
  max-width: min(1200px, 100%);
  max-height: calc(100vh - 48px);
  width: auto;
  height: auto;
  border-radius: var(--radius-sm);
}

.map-lightbox__close {
  position: absolute;
  top: 16px;
  right: 20px;
  width: 44px;
  height: 44px;
  border: 1px solid rgba(255, 255, 255, 0.25);
  border-radius: var(--radius-sm);
  background: transparent;
  color: #fff;
  font-size: 28px;
  line-height: 1;
  cursor: pointer;
}

.map-lightbox__close:hover {
  background: rgba(255, 255, 255, 0.1);
}

@media (prefers-reduced-motion: reduce) {
  body.home-intro-pending {
    overflow: auto;
  }

  body.home-intro-pending #site-header,
  body.home-intro-pending .home-main,
  body.home-intro-pending #site-footer {
    visibility: visible;
  }

  .hero-intro {
    display: none;
  }
}

/* ============================================================
 * BUTTONS
 * ============================================================ */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 14px 26px;
  border-radius: var(--radius-sm);
  font-family: var(--font-sans);
  font-size: 14px;
  font-weight: 600;
  letter-spacing: 0.01em;
  border: 1px solid transparent;
  cursor: pointer;
  transition: background 0.2s ease, border-color 0.2s ease, color 0.2s ease;
  text-decoration: none;
}

.btn--primary {
  background: var(--accent);
  color: var(--surface);
  border-color: var(--accent);
}
.btn--primary:hover {
  background: var(--accent-dark);
  border-color: var(--accent-dark);
  color: var(--surface);
}

.btn--secondary {
  background: var(--surface);
  color: var(--text);
  border-color: var(--border-strong);
}
.btn--secondary:hover {
  background: var(--surface-hover);
  border-color: var(--accent);
  color: var(--text);
}

.btn--ai {
  background: var(--accent);
  color: var(--surface);
  border-color: var(--accent);
}
.btn--ai:hover {
  background: var(--accent-dark);
  border-color: var(--accent-dark);
  color: var(--surface);
}

.btn--ghost {
  background: transparent;
  color: var(--text-2);
  border-color: var(--border-strong);
}
.btn--ghost:hover {
  color: var(--accent);
  border-color: var(--accent);
  background: var(--accent-soft);
}

/* ============================================================
 * SECTIONS
 * ============================================================ */
.section {
  padding: 100px 24px;
  max-width: var(--max-w);
  margin: 0 auto;
  position: relative;
}

.section--alt {
  background: var(--surface);
  max-width: none;
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
}

.section--alt .section__inner {
  max-width: var(--max-w);
  margin: 0 auto;
}

.section--dark {
  background: var(--surface-2);
  max-width: none;
  padding: 100px 24px;
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
}
.section--dark .section__inner { max-width: var(--max-w); margin: 0 auto; }

.section__header {
  text-align: center;
  margin-bottom: 60px;
  max-width: 780px;
  margin-left: auto;
  margin-right: auto;
}

.section__header--left {
  text-align: left;
  margin-left: 0;
}

.section__eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-family: var(--font-sans);
  font-size: 12px;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--accent);
  font-weight: 600;
  margin-bottom: 16px;
  padding: 6px 12px;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  background: var(--accent-soft);
}

.section__eyebrow--ai {
  color: var(--accent);
  border-color: var(--border);
  background: var(--accent-soft);
}

.section__intro {
  font-size: 18px;
  color: var(--text-2);
  margin: 12px 0 0 0;
  line-height: 1.65;
  max-width: 680px;
}

.section__header .section__intro {
  margin-left: auto;
  margin-right: auto;
}

@media (max-width: 820px) {
  .section, .section--alt, .section--dark { padding: 60px 20px; }
}

/* ============================================================
 * CARDS
 * ============================================================ */
.cards {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 22px;
}

.card {
  position: relative;
  padding: 28px 26px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
  display: flex;
  flex-direction: column;
  overflow: hidden;
}

.card:hover {
  border-color: var(--accent);
  box-shadow: var(--shadow-sm);
}

.card--ai {
  background: var(--surface);
  border: 1px solid var(--border);
}
.card--ai:hover {
  border-color: var(--accent);
  box-shadow: var(--shadow-sm);
}

.card__icon {
  min-width: 52px;
  height: 48px;
  padding: 0 14px;
  border-radius: var(--radius-sm);
  background: var(--accent);
  color: var(--surface);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font-display);
  font-size: 18px;
  font-weight: 700;
  letter-spacing: 0.04em;
  margin-bottom: 16px;
  box-sizing: border-box;
}

.card--ai .card__icon {
  background: var(--accent);
}

/* Illustrazioni stilizzate (icone SVG con alt SEO) */
.visual-icon {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: contain;
}

.card__visual {
  width: 56px;
  height: 56px;
  margin-bottom: 16px;
  flex-shrink: 0;
}

.service__visual {
  width: 52px;
  height: 52px;
  margin-bottom: 14px;
}

.events-spotlight__phase-visual {
  width: 44px;
  height: 44px;
  margin-bottom: 10px;
}

.section-visual {
  max-width: 320px;
  width: 100%;
  margin: 0 auto 28px;
  display: block;
  border-radius: var(--radius);
  border: 1px solid var(--border);
}

/* Mini hub animato (homepage → servizi) */
.concept-hub-mini {
  display: block;
  max-width: 168px;
  width: 100%;
  margin: 0 auto 28px;
  border-radius: 50%;
  border: none;
  overflow: visible;
  text-decoration: none;
  color: inherit;
  cursor: pointer;
  transition: transform 0.25s ease;
}

.concept-hub-mini:hover,
.concept-hub-mini:focus-visible {
  transform: scale(1.04);
  outline: 2px solid var(--accent);
  outline-offset: 4px;
}

.concept-hub-mini__svg {
  display: block;
  width: 100%;
  height: auto;
  vertical-align: top;
}

.project-card__cover .visual-icon--cover {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
}

.card h3 { margin: 0 0 10px 0; font-size: 20px; color: var(--text); }

.card p {
  margin: 0;
  font-size: 14.5px;
  color: var(--text-2);
  line-height: 1.65;
  flex: 1;
}

.card__link {
  margin-top: 18px;
  font-size: 13px;
  letter-spacing: 0.05em;
  font-weight: 600;
  color: var(--accent);
  display: inline-flex;
  align-items: center;
  gap: 6px;
  transition: gap 0.2s ease;
}
.card__link:hover { gap: 10px; color: var(--accent-dark); }

/* ============================================================
 * THESIS BLOCK (concept clou home)
 * ============================================================ */
.thesis {
  position: relative;
  max-width: 1000px;
  margin: 0 auto;
  padding: 50px 44px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
}

.thesis__list {
  display: grid;
  gap: 18px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.thesis__item {
  padding-left: 28px;
  position: relative;
  font-size: 17px;
  line-height: 1.55;
  color: var(--text-2);
}

.thesis__item::before {
  content: "×";
  position: absolute;
  left: 0;
  top: -1px;
  color: var(--text-dim);
  font-size: 20px;
  font-weight: 300;
}

.thesis__item--yes {
  color: var(--text);
  font-weight: 500;
}

.thesis__item--yes::before {
  content: "→";
  color: var(--accent);
  font-weight: 600;
}

.thesis__conclusion {
  margin-top: 30px;
  padding-top: 26px;
  border-top: 1px solid var(--border);
  font-family: var(--font-display);
  font-size: clamp(20px, 2.6vw, 26px);
  font-weight: 500;
  color: var(--text);
  line-height: 1.4;
}

.thesis__conclusion strong { color: var(--accent); font-weight: 600; }

@media (max-width: 700px) {
  .thesis { padding: 32px 24px; }
}

/* ============================================================
 * EVENTS SPOTLIGHT (home — core business)
 * ============================================================ */
.events-spotlight {
  max-width: 1040px;
  margin: 0 auto;
  padding: 48px 44px 40px;
  background: var(--surface);
  border: 2px solid var(--accent);
  border-radius: var(--radius);
  box-shadow: var(--shadow-sm);
}

.events-spotlight__intro {
  max-width: 820px;
  margin-bottom: 28px;
}

.events-spotlight__intro h2 {
  margin: 0 0 16px;
  font-family: var(--font-display);
  font-size: clamp(1.75rem, 3.5vw, 2.35rem);
  font-weight: 600;
  line-height: 1.2;
  color: var(--text);
}

.events-spotlight__intro h2 em {
  font-style: italic;
  color: var(--accent);
}

.events-spotlight__lead {
  margin: 0 0 14px;
  font-size: 18px;
  line-height: 1.65;
  color: var(--text-2);
}

.events-spotlight__note {
  margin: 0;
  font-size: 16px;
  line-height: 1.6;
  color: var(--text);
}

.events-spotlight__note strong {
  color: var(--accent);
  font-weight: 600;
}

.events-spotlight__hub {
  margin: 0 0 28px;
  padding: 16px 20px;
  font-size: 15px;
  line-height: 1.55;
  color: var(--text);
  background: var(--accent-soft);
  border-left: 4px solid var(--accent);
  border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
}

.events-spotlight__hub strong {
  font-weight: 600;
}

.events-spotlight__phases {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 18px;
  margin-bottom: 32px;
}

.events-spotlight__phase {
  padding: 20px 22px;
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
}

.events-spotlight__phase h3 {
  margin: 0 0 8px;
  font-family: var(--font-sans);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--accent);
}

.events-spotlight__phase p {
  margin: 0;
  font-size: 15px;
  line-height: 1.55;
  color: var(--text-2);
}

.events-spotlight__audience {
  padding: 24px 26px;
  margin-bottom: 28px;
  background: var(--accent);
  border-radius: var(--radius-sm);
  color: #fff;
}

.events-spotlight__audience-label {
  margin: 0 0 14px;
  font-family: var(--font-sans);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  opacity: 0.88;
}

.events-spotlight__tags {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.events-spotlight__tags li {
  padding: 8px 14px;
  font-size: 14px;
  font-weight: 600;
  line-height: 1.3;
  color: var(--accent);
  background: #fff;
  border-radius: var(--radius-sm);
}

.events-spotlight__cta {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
}

@media (max-width: 720px) {
  .events-spotlight {
    padding: 32px 22px 28px;
  }

  .events-spotlight__phases {
    grid-template-columns: 1fr;
  }
}

/* ============================================================
 * STATS
 * ============================================================ */
.stats {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
  gap: 22px;
  margin-top: 40px;
}

.stat {
  position: relative;
  padding: 28px 22px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  text-align: center;
  overflow: hidden;
}

.stat::before {
  content: "";
  position: absolute;
  top: 0;
  left: 50%;
  transform: translateX(-50%);
  width: 40px;
  height: 2px;
  background: var(--accent);
}

.stat__value {
  font-family: var(--font-display);
  font-size: clamp(36px, 5vw, 52px);
  font-weight: 700;
  color: var(--accent);
  line-height: 1;
  margin: 0;
  letter-spacing: -0.03em;
}

.stat__label {
  font-family: var(--font-sans);
  font-size: 12px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--text-muted);
  margin: 12px 0 0 0;
  font-weight: 500;
  line-height: 1.4;
}

/* ============================================================
 * PORTFOLIO / GALLERY
 * ============================================================ */
.filters {
  display: flex;
  gap: 8px;
  justify-content: center;
  flex-wrap: wrap;
  margin-bottom: 40px;
}

.filter-btn {
  background: var(--surface);
  border: 1px solid var(--border);
  color: var(--text-2);
  padding: 9px 18px;
  border-radius: var(--radius-sm);
  cursor: pointer;
  font-family: var(--font-sans);
  font-size: 13px;
  font-weight: 500;
  transition: background 0.2s ease, border-color 0.2s ease, color 0.2s ease;
}

.filter-btn:hover {
  color: var(--text);
  border-color: var(--border-strong);
}

.filter-btn.active {
  background: var(--accent);
  border-color: var(--accent);
  color: var(--surface);
}

.portfolio-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 24px;
}

.project-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
  display: flex;
  flex-direction: column;
  text-decoration: none;
  color: inherit;
}

.project-card:hover {
  border-color: var(--accent);
  box-shadow: var(--shadow-sm);
  color: inherit;
}

/* Testatina verde petrolio — altezza minima per il titolo */
.project-card__head,
.project-card__head--cursor,
.project-card__head--evento,
.project-card__head--consulenza,
.project-card__head--turismo {
  background: var(--accent);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 16px 20px;
  box-sizing: border-box;
  aspect-ratio: auto;
  min-height: 0;
}

/* titolo 1 — in testatina */
.project-card__title1 {
  font-family: var(--font-display);
  font-size: clamp(1.15rem, 2vw, 1.4rem);
  font-weight: 600;
  line-height: 1.25;
  letter-spacing: -0.02em;
  color: #fff;
  text-align: center;
  margin: 0;
}

.project-card__body {
  padding: 22px 22px 24px 22px;
  display: flex;
  flex-direction: column;
  flex: 1;
}

/* titolo 2 — sottotitolo / categoria (stesso carattere del vecchio titolo) */
.project-card__title2 {
  font-family: var(--font-display);
  font-size: 19px;
  font-weight: 600;
  line-height: 1.3;
  color: var(--text);
  margin: 0 0 10px 0;
}

/* descrizione */
.project-card__desc {
  font-size: 14px;
  color: var(--text-2);
  margin: 0 0 14px 0;
  flex: 1;
  line-height: 1.6;
}

/* piede — tecnologie / specifiche */
.project-card__foot {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
  font-size: 11px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--text-muted);
  font-weight: 500;
  border-top: 1px solid var(--border);
  padding-top: 12px;
}

/* Legacy aliases (altre pagine che usano ancora cover/meta) */
.project-card__cover {
  aspect-ratio: 16 / 9;
  background: var(--surface-2);
  position: relative;
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
}

.project-card__cover img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.project-card__meta {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
  font-size: 11px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--text-muted);
  font-weight: 500;
  border-top: 1px solid var(--border);
  padding-top: 12px;
}

.project-card > .project-card__body > h3 {
  font-size: 19px;
  margin: 0 0 8px 0;
  color: var(--text);
}

/* ============================================================
 * TIMELINE
 * ============================================================ */
.timeline {
  position: relative;
  max-width: 820px;
  margin: 0 auto;
  padding-left: 28px;
  border-left: 1px solid var(--border);
}

.timeline__item {
  position: relative;
  padding: 0 0 34px 24px;
}

.timeline__item::before {
  content: "";
  position: absolute;
  left: -35px;
  top: 6px;
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background: var(--accent);
  box-shadow: 0 0 0 4px var(--bg), 0 0 0 5px var(--accent);
}

.timeline__date {
  color: var(--accent);
  font-size: 13px;
  letter-spacing: 0.06em;
  font-weight: 600;
  text-transform: uppercase;
  margin-bottom: 6px;
}

.timeline__title {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 20px;
  color: var(--text);
  margin: 0 0 6px 0;
}

.timeline__descr {
  font-size: 15px;
  color: var(--text-2);
  margin: 0;
  line-height: 1.6;
}

/* ============================================================
 * GEO AUDIT & WORKFLOW
 * ============================================================ */
.geo-audit {
  max-width: 980px;
  margin: 0 auto;
}

.geo-audit__lead {
  font-size: 17px;
  line-height: 1.7;
  color: var(--text-2);
  margin: 0 0 20px 0;
}

.geo-audit__lead strong {
  color: var(--text);
}

.geo-flow {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 8px;
  margin-top: 40px;
  position: relative;
}

.geo-flow__step {
  position: relative;
  text-align: center;
  padding: 20px 12px 16px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-sm);
}

.geo-flow__step:not(:last-child)::after {
  content: "→";
  position: absolute;
  right: -14px;
  top: 50%;
  transform: translateY(-50%);
  font-size: 18px;
  font-weight: 700;
  color: var(--accent);
  z-index: 1;
}

.geo-flow__icon {
  width: 44px;
  height: 44px;
  margin: 0 auto 12px;
  border-radius: 50%;
  background: var(--accent);
  color: var(--surface);
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font-display);
  font-size: 15px;
  font-weight: 700;
}

.geo-flow__title {
  font-family: var(--font-display);
  font-size: 15px;
  font-weight: 600;
  color: var(--text);
  margin: 0 0 8px 0;
  line-height: 1.3;
}

.geo-flow__descr {
  font-size: 12.5px;
  color: var(--text-muted);
  margin: 0;
  line-height: 1.5;
}

.geo-flow__note {
  margin-top: 24px;
  padding: 16px 20px;
  border-left: 3px solid var(--accent);
  background: var(--accent-soft);
  border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
  font-size: 14.5px;
  color: var(--text-2);
  line-height: 1.65;
}

.geo-flow__note strong {
  color: var(--text);
}

@media (max-width: 900px) {
  .geo-flow {
    grid-template-columns: 1fr;
    gap: 12px;
    max-width: 420px;
    margin-left: auto;
    margin-right: auto;
  }

  .geo-flow__step:not(:last-child)::after {
    content: "↓";
    right: auto;
    left: 50%;
    top: auto;
    bottom: -18px;
    transform: translateX(-50%);
  }
}

/* ============================================================
 * SKILL BARS
 * ============================================================ */
.skills-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 44px;
}

.skill-group h3 {
  padding-bottom: 12px;
  margin-bottom: 22px;
  border-bottom: 1px solid var(--border);
  display: flex;
  align-items: center;
  gap: 12px;
}

.skill-group h3::before {
  content: "";
  width: 24px;
  height: 24px;
  border-radius: var(--radius-sm);
  background: var(--accent);
  flex-shrink: 0;
}

.skill-group.skill-group--ai h3::before { background: var(--accent); }

.skill { margin-bottom: 16px; }

.skill__label {
  display: flex;
  justify-content: space-between;
  font-size: 14px;
  font-weight: 500;
  color: var(--text);
  margin-bottom: 8px;
}

.skill__label small {
  color: var(--text-muted);
  font-weight: 400;
  font-size: 12px;
}

.skill__bar {
  height: 6px;
  background: var(--surface-2);
  border-radius: var(--radius-sm);
  overflow: hidden;
}

.skill__bar span {
  display: block;
  height: 100%;
  background: var(--accent);
  border-radius: var(--radius-sm);
}

.skill-group--ai .skill__bar span { background: var(--accent); }

/* ============================================================
 * SERVICES
 * ============================================================ */
.services-list {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 24px;
}

.service {
  position: relative;
  padding: 30px 28px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
  overflow: hidden;
}

.service:hover {
  border-color: var(--accent);
  box-shadow: var(--shadow-sm);
}

.service__num {
  font-family: var(--font-mono);
  font-size: 14px;
  color: var(--accent);
  font-weight: 500;
  margin-bottom: 12px;
  letter-spacing: 0.1em;
}

.service h3 { margin-bottom: 10px; font-size: 22px; color: var(--text); }
.service p { color: var(--text-2); font-size: 14.5px; margin: 0 0 12px 0; line-height: 1.65; }
.service ul { margin: 12px 0 0 0; padding-left: 0; list-style: none; }
.service ul li {
  font-size: 14px;
  color: var(--text-2);
  margin-bottom: 6px;
  padding-left: 22px;
  position: relative;
  line-height: 1.5;
}
.service ul li::before {
  content: "";
  position: absolute;
  left: 4px;
  top: 8px;
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--accent);
}

.service__cta {
  margin-top: 16px;
}

/* ============================================================
 * CONTACT
 * ============================================================ */
.contact-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 50px;
  max-width: 1080px;
  margin: 0 auto;
}

.contact-info h3 { margin-bottom: 20px; }

.contact-info dl {
  margin: 0;
  display: grid;
  gap: 20px;
}

.contact-info dt {
  font-size: 11px;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--accent);
  font-weight: 600;
  margin-bottom: 6px;
}

.contact-info dd {
  margin: 0;
  font-size: 16px;
  color: var(--text);
  line-height: 1.55;
}

.contact-info dd a { color: var(--text); border-bottom: 1px dotted var(--accent); }
.contact-info dd a:hover { color: var(--accent); }

.contact-map {
  aspect-ratio: 4 / 3;
  border-radius: var(--radius);
  overflow: hidden;
  border: 1px solid var(--border);
}
.contact-map iframe { width: 100%; height: 100%; border: 0; }

@media (max-width: 820px) {
  .contact-grid { grid-template-columns: 1fr; gap: 40px; }
}

/* ============================================================
 * VIDEO EMBED
 * ============================================================ */
.video-embed {
  position: relative;
  aspect-ratio: 16 / 9;
  background: var(--surface-2);
  border-radius: var(--radius);
  overflow: hidden;
  border: 1px solid var(--border);
  box-shadow: var(--shadow-sm);
}

.video-embed iframe {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  border: 0;
}

/* ============================================================
 * FOOTER
 * ============================================================ */
.site-footer {
  background: var(--surface);
  color: var(--text-2);
  padding: 70px 24px 30px 24px;
  border-top: 1px solid var(--border);
  position: relative;
}

.footer__inner {
  max-width: var(--max-w);
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1.6fr 1fr 1fr 1fr;
  gap: 40px;
}

.footer__brand-block { display: flex; flex-direction: column; }

.footer__brand-block img {
  height: 60px;
  width: auto;
  object-fit: contain;
  margin-bottom: 18px;
}

.footer h4 {
  font-family: var(--font-display);
  font-size: 14px;
  color: var(--text);
  margin: 0 0 16px 0;
  font-weight: 600;
  letter-spacing: 0.05em;
  text-transform: uppercase;
}

.footer p, .footer li {
  font-size: 14px;
  color: var(--text-muted);
  line-height: 1.7;
}

.footer ul { list-style: none; padding: 0; margin: 0; }
.footer ul li { margin-bottom: 8px; }

.footer a {
  color: var(--text-2);
  border-bottom: none;
  transition: color 0.2s;
}
.footer a:hover { color: var(--accent); }

.footer__meta {
  max-width: var(--max-w);
  margin: 50px auto 0 auto;
  padding-top: 24px;
  border-top: 1px solid var(--border);
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 14px;
  font-size: 12px;
  color: var(--text-dim);
  letter-spacing: 0.05em;
}

.footer__meta a {
  color: var(--accent-dark);
  text-decoration: underline;
  text-underline-offset: 2px;
}

.footer__meta a:hover {
  color: var(--text);
}

@media (max-width: 900px) {
  .footer__inner { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 600px) {
  .footer__inner { grid-template-columns: 1fr; gap: 30px; }
}

/* ============================================================
 * CHIPS
 * ============================================================ */
.chips {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin: 14px 0;
}

.chip {
  display: inline-block;
  padding: 6px 14px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  font-size: 12px;
  color: var(--text-2);
  font-weight: 500;
}

.chip--lem {
  background: var(--accent-soft);
  color: var(--accent);
  border-color: var(--border);
}

.chip--ai {
  background: var(--accent-soft);
  color: var(--accent);
  border-color: var(--border);
}

/* ============================================================
 * STRIP (CTA)
 * ============================================================ */
.strip {
  position: relative;
  padding: 70px 24px;
  overflow: hidden;
  background: var(--surface-2);
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
  text-align: center;
}

.strip__inner {
  max-width: 780px;
  margin: 0 auto;
}

.strip h3 {
  color: var(--text);
  font-size: clamp(28px, 4vw, 40px);
  margin: 0 0 14px 0;
  font-weight: 600;
}
.strip p { color: var(--text-2); font-size: 17px; margin: 0 auto 24px auto; }

/* ============================================================
 * CALLOUT
 * ============================================================ */
.callout {
  padding: 24px 28px;
  background: var(--accent-soft);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  margin: 28px 0;
  position: relative;
}
.callout--ai {
  background: var(--accent-soft);
  border: 1px solid var(--border);
}
.callout p { margin: 0; font-size: 15.5px; color: var(--text); line-height: 1.7; }
.callout p + p { margin-top: 12px; }
.callout strong { color: var(--accent); }
.callout--ai strong { color: var(--accent); }

.check-list {
  padding-left: 0;
  margin: 0;
  list-style: none;
}
.check-list li {
  position: relative;
  padding-left: 26px;
  margin-bottom: 10px;
  color: var(--text-2);
  line-height: 1.6;
}
.check-list li::before {
  content: "✓";
  position: absolute;
  left: 0;
  color: var(--accent);
  font-weight: 700;
}

/* ============================================================
 * PROJECT DETAIL PAGE
 * ============================================================ */
.project-hero {
  padding: 90px 24px 60px 24px;
  background: var(--header-wash-bg);
  border-bottom: 1px solid var(--border);
}

.project-hero__inner {
  max-width: var(--max-w);
  margin: 0 auto;
}

.project-hero__breadcrumb {
  font-size: 12px;
  letter-spacing: 0.08em;
  color: var(--text-muted);
  margin-bottom: 22px;
}
.project-hero__breadcrumb a { color: var(--accent); }

.project-hero__title {
  font-family: var(--font-display);
  font-size: clamp(34px, 5.6vw, 58px);
  line-height: 1.05;
  margin: 0 0 16px 0;
  color: var(--text);
  letter-spacing: -0.03em;
  font-weight: 700;
}

.project-hero__lead {
  font-size: clamp(17px, 2vw, 21px);
  color: var(--text-2);
  max-width: 780px;
  margin: 12px 0 26px 0;
  line-height: 1.55;
}

.project-hero__meta {
  display: flex;
  gap: 30px;
  flex-wrap: wrap;
  margin-top: 28px;
  padding-top: 24px;
  border-top: 1px solid var(--border);
}

.project-hero__meta > div { min-width: 170px; }

.project-hero__meta dt {
  font-size: 10px;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--accent);
  font-weight: 700;
  margin-bottom: 6px;
}

.project-hero__meta dd {
  margin: 0;
  font-size: 15px;
  color: var(--text);
}

.project-section {
  padding: 70px 24px;
  max-width: var(--max-w-narrow);
  margin: 0 auto;
}

.project-section h2 { font-size: clamp(26px, 3.5vw, 34px); }
.project-section h3 { color: var(--text); margin-top: 32px; }

.project-section p {
  font-size: 16px;
  line-height: 1.75;
  margin: 0 0 18px 0;
  color: var(--text-2);
}

.project-section ul {
  padding-left: 0;
  margin: 0 0 18px 0;
  list-style: none;
}

.project-section ul li {
  font-size: 16px;
  line-height: 1.7;
  margin-bottom: 10px;
  padding-left: 26px;
  position: relative;
  color: var(--text-2);
}

.project-section ul li::before {
  content: "→";
  position: absolute;
  left: 0;
  color: var(--accent);
  font-weight: 600;
}

.two-col {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 40px;
  align-items: start;
}

@media (max-width: 820px) {
  .two-col { grid-template-columns: 1fr; }
}

/* Staff (chi siamo) */
.staff-management {
  list-style: none;
  margin: 0 auto 28px;
  padding: 0;
  max-width: 820px;
  border: 2px solid var(--accent);
  border-radius: var(--radius);
  background: var(--surface);
  overflow: hidden;
}

.staff-line {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 8px 16px;
  padding: 20px 26px;
  border-bottom: 1px solid var(--border);
}

.staff-line:last-child {
  border-bottom: none;
}

.staff-line__name {
  font-family: var(--font-display);
  font-size: clamp(1.05rem, 2.2vw, 1.25rem);
  font-weight: 600;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--text);
}

.staff-line__role {
  font-size: 15px;
  line-height: 1.5;
  color: var(--accent);
  font-weight: 500;
}

.staff-line__role::before {
  content: "(";
  margin-right: 2px;
  color: var(--text-2);
  font-weight: 400;
}

.staff-line__role::after {
  content: ")";
  margin-left: 2px;
  color: var(--text-2);
  font-weight: 400;
}

.staff-team {
  max-width: 820px;
  margin: 0 auto;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
  background: var(--surface-2);
}

.staff-team__banner {
  padding: 32px 28px;
  text-align: center;
  background: var(--accent);
}

.staff-team__lead {
  margin: 0;
  font-family: var(--font-display);
  font-size: clamp(1.65rem, 4vw, 2.35rem);
  font-weight: 600;
  line-height: 1.15;
  letter-spacing: -0.01em;
  color: #fff;
}

.staff-team__tagline {
  margin: 0;
  padding: 24px 28px 26px;
  font-size: clamp(1.05rem, 2.2vw, 1.2rem);
  line-height: 1.55;
  color: var(--text);
  text-align: center;
  font-weight: 500;
}

.staff-team__areas {
  margin: 0;
  padding: 22px 26px;
  font-size: 15px;
  line-height: 1.6;
  color: var(--text-2);
  text-align: center;
}

@media (max-width: 600px) {
  .staff-line {
    flex-direction: column;
    gap: 6px;
    padding: 18px 20px;
  }
}

.screenshots {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 20px;
  margin: 26px 0;
}

.screenshots img {
  border-radius: var(--radius);
  border: 1px solid var(--border);
  box-shadow: var(--shadow-sm);
}

/* ============================================================
 * COLLABORATORS (logo wall + paginator)
 * ============================================================ */
.collaborators {
  padding-top: 72px;
  padding-bottom: 88px;
  border-top: 1px solid var(--border);
}

.collaborators__carousel {
  max-width: 1080px;
  margin: 0 auto;
}

.collaborators__viewport {
  overflow: hidden;
}

.collaborators__track {
  position: relative;
}

.collaborators__page {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  grid-template-rows: repeat(2, minmax(132px, auto));
  gap: 36px 40px;
  align-items: center;
  justify-items: center;
}

.collaborators__page[hidden] {
  display: none;
}

.collaborators__item {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  min-height: 132px;
  padding: 6px 10px;
}

.collaborators__item img {
  width: auto;
  max-width: 240px;
  max-height: 124px;
  height: auto;
  object-fit: contain;
  mix-blend-mode: multiply;
  filter: grayscale(1) contrast(1.05);
  opacity: 0.9;
  transition: filter 0.25s ease, opacity 0.25s ease;
}

.collaborators__item:hover img,
.collaborators__item:focus-within img {
  filter: grayscale(0.25) contrast(1.08);
  opacity: 1;
}

.collaborators__controls {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 16px;
  margin-top: 36px;
}

.collaborators__nav-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  padding: 0;
  border: 1px solid var(--border-strong);
  border-radius: 999px;
  background: var(--surface);
  color: var(--text);
  font-size: 28px;
  line-height: 1;
  cursor: pointer;
  transition: background 0.2s ease, border-color 0.2s ease, color 0.2s ease;
}

.collaborators__nav-btn:hover:not(:disabled) {
  border-color: var(--accent);
  color: var(--accent);
  background: var(--accent-soft);
}

.collaborators__nav-btn:disabled {
  opacity: 0.35;
  cursor: not-allowed;
}

.collaborators__dots {
  display: flex;
  align-items: center;
  gap: 10px;
}

.collaborators__dot {
  width: 10px;
  height: 10px;
  padding: 0;
  border: none;
  border-radius: 999px;
  background: var(--border-strong);
  cursor: pointer;
  transition: background 0.2s ease, transform 0.2s ease;
}

.collaborators__dot[aria-selected="true"] {
  background: var(--accent);
  transform: scale(1.15);
}

.collaborators__dot:hover {
  background: var(--accent-light);
}

@media (max-width: 720px) {
  .collaborators {
    padding-top: 52px;
    padding-bottom: 64px;
  }

  .collaborators__page {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    grid-template-rows: repeat(2, minmax(114px, auto));
    gap: 28px 20px;
  }

  .collaborators__item {
    min-height: 96px;
    padding: 6px 8px;
  }

  .collaborators__item img {
    max-width: 200px;
    max-height: 104px;
  }

  .collaborators__controls {
    margin-top: 28px;
  }
}

@media (max-width: 420px) {
  .collaborators__page {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 22px 14px;
  }

  .collaborators__item img {
    max-width: 150px;
    max-height: 72px;
  }
}

/* ============================================================
 * UTILITIES
 * ============================================================ */
.text-center { text-align: center; }
.mt-40 { margin-top: 40px; }
.mt-60 { margin-top: 60px; }
.mb-0 { margin-bottom: 0; }
.hidden { display: none !important; }

.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

/* Focus visibility (accessibility) */
:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
  border-radius: var(--radius-sm);
}

/* Reduced motion */
@media (prefers-reduced-motion: reduce) {
  * { animation-duration: 0.01ms !important; transition-duration: 0.01ms !important; }
}

/* ============================================================
 * COOKIE / GDPR BANNER
 * ============================================================ */
.cookie-banner {
  position: fixed;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 10000;
  padding: 16px;
  pointer-events: none;
  animation: cookie-banner-in 0.28s ease-out;
}

.cookie-banner--hide {
  animation: cookie-banner-out 0.26s ease-in forwards;
}

@keyframes cookie-banner-in {
  from { opacity: 0; transform: translateY(12px); }
  to { opacity: 1; transform: translateY(0); }
}

@keyframes cookie-banner-out {
  to { opacity: 0; transform: translateY(16px); }
}

.cookie-banner__panel {
  pointer-events: auto;
  max-width: 920px;
  margin: 0 auto;
  padding: 20px 22px;
  background: var(--surface);
  color: var(--text);
  border: 1px solid var(--border-strong);
  box-shadow: 0 -4px 28px rgba(23, 23, 23, 0.12);
  display: grid;
  gap: 16px;
}

.cookie-banner__title {
  margin: 0 0 6px;
  font-family: var(--font-display);
  font-size: 1.15rem;
  font-weight: 600;
  color: var(--text);
}

.cookie-banner__text {
  margin: 0;
  font-size: 14px;
  line-height: 1.55;
  color: var(--text);
}

.cookie-banner__text a {
  color: var(--accent-dark);
  text-decoration: underline;
  text-underline-offset: 2px;
}

.cookie-banner__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.cookie-banner__btn {
  padding: 11px 18px;
  font-size: 13.5px;
  min-height: 44px;
}

.cookie-banner__prefs {
  border-top: 1px solid var(--border);
  padding-top: 14px;
  display: grid;
  gap: 12px;
}

.cookie-banner__pref {
  display: grid;
  grid-template-columns: 20px 1fr;
  gap: 10px;
  align-items: start;
  font-size: 13.5px;
  line-height: 1.45;
  color: var(--text);
  cursor: pointer;
}

.cookie-banner__pref input {
  margin-top: 3px;
  width: 16px;
  height: 16px;
  accent-color: var(--accent);
}

.cookie-banner__prefs-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

@media (max-width: 640px) {
  .cookie-banner {
    padding: 10px;
  }
  .cookie-banner__panel {
    padding: 16px;
  }
  .cookie-banner__actions {
    flex-direction: column;
  }
  .cookie-banner__btn {
    width: 100%;
  }
}

@media (prefers-reduced-motion: reduce) {
  .cookie-banner,
  .cookie-banner--hide {
    animation: none;
  }
}
