/* ==========================================================================
   Author's custom styles
   ========================================================================== */

/* --------------------
   Variabili globali
-------------------- */

:root {
  --primary: #39529F;
  --secondary: #E94C2E;
  --dark: #1b1b1b;
  --light: #f7f7f7;
  --white: #ffffff;
  --text-dark: #4A5565;
  --text-light: #ffffff;
}

/* --------------------
   Reset base
-------------------- */

* {
  box-sizing: border-box;
}

/* FONT GLOBALE */
body {
  margin: 0;
  font-family: 'Archivo', Arial, Helvetica, sans-serif;
  color: var(--text-dark);
  background: #fff;
  font-size: 15px;
}

html {
  scroll-behavior: smooth;
}

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

a {
  text-decoration: none;
}
/* Dropdown container */
.dropdown {
  position: relative;
  display: inline-block;
}

/* Menu nascosto */
.dropdown-menu {
  position: absolute;
  top: 100%;
  left: 0;
  background: #fff;
  border-radius: 8px;
  padding: 10px 0;
  min-width: 200px;
  box-shadow: 0 10px 25px rgba(0,0,0,0.1);

  opacity: 0;
  visibility: hidden;
  transition: 0.3s;
}

/* Link dropdown */
.dropdown-menu a {
  display: block;
  padding: 10px 20px;
  color: #333;
  font-size:1em;
}

.dropdown-menu a:hover {
  background: #f5f5f5;
}

/* Hover attiva */
.dropdown:hover .dropdown-menu {
  opacity: 1;
  visibility: visible;
}
.dropdown {
  position: relative;
  z-index: 999999;
}

.dropdown > a {
  position: relative;
  z-index: 999999;
  pointer-events: auto !important;
}

/* --------------------
   Utility
-------------------- */

.container {
  width: 90%;
  margin: 0 auto;
}

section {
  padding: 80px 0;
}

.center {
  text-align: center;
}

/* --------------------
   Bottoni
-------------------- */

.btn {
  display: inline-block;
  background: var(--secondary);
  color: white;
  padding: 14px 28px;
  border-radius: 8px;
  font-weight: 400;
  transition: .3s;
  border:1px solid white;
}
.card .btn{
  position:absolute;
  bottom:40px;
  left:30px;
}

.realizzazioni .btn{
  margin-top:40px;
  display: inline-block;
  background: white;
  border: 1px solid var(--primary);
  color: var(--primary);
  padding: 18px 28px;
  border-radius: 8px;
  font-weight: bold;
  transition: .3s;
}

.realizzazioni .btn:hover{
  background: var(--primary);
  color:white;
}

.btn:hover {
  background: var(--light);
  color: var(--secondary);
  box-shadow: 0 10px 25px rgba(0,0,0,0.4);
  border: 1px solid var(--secondary);
}

/* --------------------
   Header
-------------------- */

.header {
  position: sticky;
  top: 0;
  z-index: 999;
  background: white;
}

.header .container {
  display: flex;
  justify-content: space-between;
  align-items: center;
  min-height: 80px;
  width:95%;
}

/* contenitore logo */
.logo {
  display: flex;
  align-items: center;
}

/* immagine logo */
.logo img {
  height: 50px;   /* 👈 regola qui la dimensione */
  width: auto;
}

.nav {
  display: flex;
  gap: 25px;
}

.nav a {
  color: #364153;
  font-weight: 300;
}
.nav {
  position: relative;
  z-index: 99999;
}

.nav a {
  position: relative;
  z-index: 100000;
  pointer-events: auto;
}

.nav .reverse_menu{
  font-weight: 300;
  color: var(--secondary);
}

.nav a:hover {
  color: var(--secondary);
}
.nav .reverse_menu:hover{
  color: #364153;
}
/* =========================================
   MENU - ALLINEAMENTO CROSS-PLATFORM
========================================= */

.nav {
  display: flex;
  align-items: center;
}

.nav > a,
.nav .dropdown > a {
  display: flex;
  align-items: center;
  line-height: 1;
}

/* Freccia del menu Incentivi */
.nav .dropdown > a::after {
  content: "";
  width: 0;
  height: 0;
  margin-left: 6px;
  border-left: 4px solid transparent;
  border-right: 4px solid transparent;
  border-top: 5px solid currentColor;
}
/* --------------------
   Hero
-------------------- */

/* =========================================
   HERO - KEN BURNS + DISSOLVENZA
===================================== */

.hero {
  position: relative;
  height: 80vh;
  overflow: hidden;
  display: flex;
  align-items: center;
}

/* -----------------------------------------
   SLIDE
----------------------------------------- */

.hero-slide {
  position: absolute;
  inset: 0;

  width: 100%;
  height: 100%;

  opacity: 0;

  z-index: 0;

  overflow: hidden;

  transition: opacity 1.2s ease-in-out;
}

/* -----------------------------------------
   IMMAGINE DENTRO LA SLIDE
----------------------------------------- */

.hero-slide img {
  position: absolute;
  inset: -5%;

  width: 110%;
  height: 110%;

  max-width: none;

  object-fit: cover;

  transform: scale(1);

  transform-origin: center center;
}

/* -----------------------------------------
   SLIDE ATTIVA
----------------------------------------- */

.hero-slide.active {
  opacity: 1;
}

/* -----------------------------------------
   KEN BURNS
----------------------------------------- */

@keyframes kenBurns {

  0% {
    transform: scale(1);
  }

  100% {
    transform: scale(1.10);
  }

}

/* -----------------------------------------
   OVERLAY
----------------------------------------- */

.hero .overlay {
  position: absolute;
  inset: 0;
  z-index: 2;
}

/* -----------------------------------------
   CONTENUTO
----------------------------------------- */

.hero-content {
  position: relative;
  z-index: 3;
}

/* titolo */
.hero h1 {
  font-size:4em;
  line-height: 1.2;
  text-shadow: 2px 2px 6px rgba(0, 0, 0, 0.7);
  color: white;
  width:50%;
}

/* paragrafo */
.hero p {
  font-size:1.6em;
  margin-top: 20px;
  text-shadow: 2px 2px 6px rgba(0, 0, 0, 0.9);
  color: white;
  width:50%;
}

/* --------------------
   Sponsor
-------------------- */

.sponsor {
  padding: 20px 50px;
  border-bottom: 1px solid var(--secondary);
}

.sponsor-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 20px;
  flex-wrap: wrap;
  text-align: center;
}

/* contenitore orizzontale */
.sponsor-item {
  display: flex;
  align-items: center; /* 👈 QUESTO CENTRA VERTICALMENTE */
  gap: 15px;
}

/* immagine a sinistra */
.sponsor-item img {
  height: 45px;
  width: auto;
  max-width:100%;
  flex-shrink: 0;
}

/* blocco testo */
.sponsor-text {
  display: flex;
  flex-direction: column;
  justify-content: center;
  font-size:1em;
}

/* riga principale */
.sponsor-text span {
  font-weight: bold;
  line-height: 1.2;
  font-size:1.1em;
}

/* seconda riga */
.sponsor-text small {
  color: #666;
  line-height: 1.2;
  font-size:0.8em;
}

/* --------------------
   Servizi
-------------------- */

.servizi {
  background: #fff;
}

.servizi h1 {
  text-align: center;
  margin-bottom: 50px;
  font-size:2.1em;
  color:#101828;
}

.grid {
  display: grid;
  gap: 25px;
}

.servizi .grid {
  grid-template-columns: repeat(4, 1fr);
}/* griglia servizi */
.servizi-grid {
  margin-top: 40px;
}

/* card servizio */
.servizio-card {
  text-align: left;
  padding: 30px 20px;
  background: #fff;
  border-radius: 8px;
  transition: 0.3s;
}

/* icona sopra */
.servizio-card img {
  height: 60px;
  margin-bottom: 15px;
}

/* titolo */
.servizio-card h3 {
  margin-bottom: 10px;
  font-size:1.2em;
}

/* descrizione */
.servizio-card p {
  color: #fff;
  line-height: 1.6;
  font-size:0.9em;

}

/* hover leggero */
.servizio-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 10px 25px rgba(0,0,0,0.1);
}

/* card base */
.card {
  position:relative;
  padding: 30px;
  border-radius: 8px;
  color: white;
  transition: .3s;
  line-height: 1.6;
}
.incentivi .card p{
  margin-bottom:100px;
}

/* 1, 3, 5... blu */
.card:nth-child(odd) {
  background: var(--primary); /* blu */
}

/* 2, 4, 6... arancione */
.card:nth-child(even) {
  background: var(--secondary); /* arancione */
}

.card:hover {
  transform: translateY(-5px);
}

/* --------------------
   Incentivi
-------------------- */

.incentivi {
  background: var(--primary);
  color: white;
}

.incentivi h2 {
  text-align: center;
  margin-bottom: 40px;
  font-size:2.1em;
}

.incentivi .grid {
  grid-template-columns: repeat(2, 1fr);
}

.incentivi .card {
  background: white;
  color: #333;
}

.incentivi .card h3{
  font-size:2em;
}

.incentivi .card p{
  font-size:1.3em;
  line-height:2em;
  height:55%;
}

/* --------------------
   Chi siamo
-------------------- */

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

.chi-siamo h2 {
  margin-bottom: 20px;
  font-size: 2em;
  color:#101828;
  line-height:2.8em;
}
.chi-siamo p {
  font-size: 1.5em;
  line-height:2em;
}

.chi-siamo img {
  border-radius: 10px;
}

/* --------------------
   Realizzazioni
-------------------- */

.realizzazioni {
  background: var(--light);
}

.realizzazioni h2 {
  color: #101828;
  font-size: 2.2em;
  text-align: center;
  margin-bottom: 20px;
}

.realizzazioni h3 {
  text-align: center;
  font-weight: 100;
  margin-bottom: 40px;
}

.gallery {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 5%;
}

.gallery img {
  width: 100%;
  height: 80%;
  aspect-ratio: 363/256;
  object-fit: cover;
  transition: .3s;
}

.real-card {
  background: white;
  border-radius: 20px;
  overflow: hidden;
  transition: 0.3s;
}

.real-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 10px 25px rgba(0,0,0,0.1);
}

.real-title {
  padding: 3%;
  font-size: 1em;
  font-weight: 700;
  color: var(--primary);
}

.real-title:hover {
  color: var(--secondary);
}

/* --------------------
   Partner
-------------------- */

.partner {
  background: white;
}

.partner h3 {
  text-align: center;
  margin-top:0;
  margin-bottom: 40px;
  font-size:1em;
}

.logos {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 50px;
  align-items: center;
}

.logos img {
  max-width: 30%;
  height: auto;

  display: block;
  margin: 0 auto;

  filter: grayscale(100%);
  opacity: .8;
  transition: .3s;
}

.logos img:hover {
  filter: grayscale(0);
  opacity: 1;
}

/* --------------------
   Contatti
-------------------- */

.contatti {
  background: var(--light);
}

.contatti h2 {
  text-align: center;
  margin-bottom: 20px;
  font-size: 2.2em;
  color: var(--secondary);
}
.contatti h3 {
  text-align: center;
  margin-bottom: 40px;
  font-size: 1em;
  font-weight: 100;
}

.contatti form {
  max-width: 60%;
  margin: auto;
  background-color: white;
  padding: 3%;
}

.contatti .grid {
  grid-template-columns: repeat(2, 1fr);
  margin-bottom: 20px;
}
.contatti label{
  font-weight: 500;
  font-family: 'Archivo', Arial, Helvetica, sans-serif;
}
.contatti input[type="text"],.contatti input[type="email"],
.contatti textarea {
  width: 100%;
  padding: 15px;
  border: 1px solid #ddd;
  border-radius: 4px;
  margin-top:10px;
  font-family: 'Archivo', Arial, Helvetica, sans-serif;
}
.contatti button[type="submit"]{
  width:100%;
  margin-top:2%;
  border:1px solid white;
  padding: 18px 28px;
  border-radius: 8px;
}
.contatti button[type="submit"]:hover{
  width:100%;
  margin-top:2%;
  border:1px solid var(--secondary);
  padding: 18px 28px;
  border-radius: 8px;
}

.contatti textarea {
  min-height: 180px;
  margin-bottom: 20px;
}
.contatti .titolo-contatti-realizzazione {
  line-height: 1.15;
  font-weight: 700;
  color: var(--dark);
  text-align: center;
  margin-bottom: 20px;
  font-size: 2.2em;
}
/* --------------------
   Footer
-------------------- */

/* FOOTER BASE */
.footer {
  background: #1f1f1f;
  color: #fff;
  padding: 20px 0 20px;
}

/* GRID 3 COLONNE */
.footer-grid {
  display: grid;
  width:90%;
  margin-left:5%;
  grid-template-columns: repeat(3, 1fr);
  gap: 50px;
}

/* OGNI COLONNA CENTRATA */
.footer-col {
  display: flex;
  flex-direction: column;
  align-items: flex-start;   /* centra orizzontalmente */
  text-align: left;    /* centra testo */
}

/* LOGO */
.footer-logo {
  height: 50px;
  margin-bottom: 50px;
}

/* TESTI */
.footer p {
  color: #99A1AF;
  font-size:0.8em;
  line-height: 1.5em;
  margin-top: 0;
  margin-bottom: 8px;
}

/* LINK */
.footer a {
  display: block;
  color: #99A1AF;
  text-decoration: none;
  margin-bottom: 8px;
  transition: 0.2s;
  line-height: 1.5em;
  font-size:0.8em;
}

.footer a:hover {
  color: #fff;
  transform: translateY(-2px);
}

/* contenitore social */
.socials {
  display: flex;
  gap: 15px;
  margin-top: 15px;
  justify-content: center; /* oppure flex-start se vuoi sinistra */
  align-items: center;
}

/* icone */
.socials img {
  width: 28px;
  height: 28px;
  transition: 0.3s;
  filter: brightness(0) invert(1); /* se footer scuro */
}

/* hover */
.socials img:hover {
  transform: scale(1.1);
}

/* BOTTOM */
.footer-bottom {
  display: flex;
  width:90%;
  margin-left:5%;
  justify-content: space-between; /* sinistra + destra */
  align-items: center;

  border-top: 1px solid var(--secondary);
  margin-top: 10px;
  padding-top: 20px;

  color: #888;
}

/* reset margini paragrafi */
.footer-bottom p {
  margin: 0;
}

/* HERO INCENTIVI */
.hero-incentivi {
  position: relative;
  height: 60vh;
  background: url('../img/Contotermico3.0copertina.jpg') center/cover;
  display: flex;
  align-items: center;
  justify-content: center;
}

.hero-center {
  text-align: center;
  color: white;
}

.badge {
  background: white;
  color: var(--secondary);
  padding: 8px 16px;
  font-size:3em;
  border-radius: 100px;
  border:5px solid var(--primary);
  font-weight: bold;
  display: inline-block;
  margin-bottom: 10px;
}
.hero-incentivi h1{
  text-shadow: 0 0 25px rgba(0,0,0,100);
  font-weight:700;
  font-size:2.2em;
}
.hero-incentivi a{
  margin-top:5%;
}

/* INTRO */
.grid-2 {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 30px;
}

.box {
  background: #F9FAFB;
  padding: 30px;
  border-radius: 10px;
}
.box h3{
  font-size:1.8em;
  color: var(--primary);
}
.box p{
  line-height: 1.8em;
  font-size:1em;
}

/* NOVITA */
/* CONTENITORE */
.novita {
  background: #f3f4f6;
  padding:10px;
}

.novita-box {
  padding: 40px;
  border-radius: 10px;
}

/* TITOLO */
.novita h2 {
  text-align: center;
  color: var(--secondary);
  margin-bottom: 40px;
  font-size: 2.5em;
}

/* GRID */
.novita-grid {
  display: grid;
  grid-template-columns: 1.2fr 1fr;
  gap: 40px;
  align-items: center;
}

/* LISTA */
.novita-list {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

/* ITEM */
.novita-item {
  display: flex;
  gap: 15px;
  align-items: flex-start;
}

/* ICONA */
.novita-item .icon img{
  height: 1.6em;
  width: 1.6em;
  display: flex;
  align-items: center;
  justify-content: center;
}

/* TESTO */
.novita-item h4 {
  margin: 0;
  font-size: 1.6em;
  color: #101828;
  font-weight: 700;
}

.novita-item p {
  margin: 5px 0 0;
  font-size: 1em;
  line-height: 2em;
  color: #555;
}

/* IMMAGINE */
.novita-img img {
  width: 100%;
  border-radius: 15px;
  object-fit: cover;
}

.novita-slider {
  position: relative;
  overflow: hidden;
}

.novita-slider .novita-slide {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;

  opacity: 0;
  transition: opacity 1s ease-in-out;
}

.novita-slider .novita-slide.active {
  opacity: 1;
}

/* Mantiene l'altezza della prima immagine */
.novita-slider .novita-slide:first-child {
  position: relative;
}

/* STEPS */
.steps {
  background: var(--primary);
  color: white;
  text-align: center;
}
.steps h2{
  font-size:2.4em;
}
.steps h3 {
  font-size: 1.3em;
  font-weight:500;
}
.steps p{
  font-size:0.8em;
  font-weight:100;
  width:70%;
  margin-left:15%;
}
.steps-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  margin-top: 40px;
  gap: 20px;
}

.step span {
  display: inline-block;
  background: var(--secondary);
  width: 2.5em;
  height: 2.5em;
  border-radius: 50%;
  line-height: 2.5em;
  margin-bottom: 10px;
  font-weight: bold;
  font-size: 1.5em;
}

/* ACCESSO */
.grid-3 {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 25px;
  background-color: #f5f7fa;
}

.card-light {
  background: white;
  padding: 25px;
  box-shadow: 0 0 10px 1px RGBA(0,0,0,0.1);
  text-align: left;
}

/* HEADER SEZIONI (ICONA + TITOLO) */
.section-header {
  text-align: center;
  margin-bottom: 40px;
}

.section-header img {
  width: 40px;
  margin-bottom: 10px;
}

.section-header h2 {
  color: var(--secondary);
  margin: 0;
}

/* GRID FIX */
.accesso-grid,
.interventi-grid {
  margin-top: 20px;
  padding:20px;
}

/* INTERVENTI PIÙ FEDELI */
.card-outline {
  border: 2px solid #dbe3ef;
  padding: 25px;
  border-radius: 10px;
  background: white;
}

.card-outline.red {
  border-color: var(--secondary);
}

/* TITOLI CARD */
.card-outline h4,
.card-light h4 {
  margin-top: 0;
}

/* CARD ACCESSO */
.accesso-card {
  transition: 0.3s;
}

/* ICONA SOPRA */
.accesso-card img {
  width: 40px;
  margin-bottom: 15px;
}

/* TITOLO */
.accesso-card h4 {
  margin: 0 0 10px;
  font-size:1.5em;
  color:#101828;
}

/* TESTO */
.accesso-card p {
  margin: 0;
  font-size: 1em;
  line-height: 2em;
  color: #555;
}

/* HOVER LEGGERO */
.accesso-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 10px 25px rgba(0,0,0,0.08);
}

/* CARD INTERVENTI */
.intervento-card {
  background: white;
  padding: 25px;
  border-radius: 10px;
  transition: 0.3s;
}

/* ICONA */
.intervento-card img {
  width: 40px;
  margin-bottom: 15px;
}

/* TITOLO */
.intervento-card h4 {
  margin: 0 0 10px;
  font-size:1.3em;
  color: #101828;

}

/* TESTO */
.intervento-card p {
  font-size: 0.9em;
  color: #555;
  line-height:2em;
  margin: 0 0 0.4em;
}

/* HOVER */
.intervento-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 10px 25px rgba(0,0,0,0.08);
}

/* ======================================================
   BONUS CASA & ECOBONUS
====================================================== */

/* HERO */

.hero-bonus{
  position:relative;
  height:420px;
  background:url("../img/BonusCasa-e-Ecobonus-copertina-bagno.jpg") center center/cover no-repeat;
  display:flex;
  justify-content:center;
  align-items:center;
}

.hero-bonus::before{
  content:"";
  position:absolute;
  inset:0;
  background:rgba(0,0,0,.25);
}

.hero-bonus .hero-center{
  position:relative;
  z-index:2;
  text-align:center;
  color:#000;
}

.hero-bonus h1{
  font-size:3.2em;
  color:var(--secondary);
  margin-bottom:20px;
  text-transform:uppercase;
  text-shadow: 2px 2px 6px rgba(0, 0, 0, 0.7);
}

.hero-bonus p{
  width:70%;
  margin:0 auto 35px;
  font-size:1.2em;
  line-height:1.8em;
}

/*==================================================
BONUS CASA / ECOBONUS
==================================================*/

.bonus-info{
  padding:70px 0;
}

.bonus-grid{
  width:80%;
  display:grid;
  grid-template-columns:1fr 1fr;
  gap:28px;
}

.bonus-grid>div{

  background:#F7F8FC;

  border-radius:12px;

  padding:35px;

}

.bonus-grid h2{

  color:var(--primary);

  font-size:2em;

  margin:0 0 30px;

}

.bonus-grid p{

  margin:0 0 16px;

  line-height:1.8;

  color:#5B6475;

}

.bonus-grid strong{

  color:#263247;

  font-weight:700;

}
/*==================================================
CHI PUO' ACCEDERE
==================================================*/

.requisiti{

  padding:0 0 90px 0;

}

.requisiti h2{

  text-align:center;

  color:var(--secondary);

  font-size:2.6em;

  margin-bottom:55px;

}

.requisiti-card{

  width:58%;

  margin:auto;

  background:#F7F8FC;

  border-radius:14px;

  padding:42px;

}

.requisiti-card>p{

  color:#60697B;

  line-height:1.8;

  margin-bottom:35px;

}

.requisiti-card h3{

  margin:0 0 30px;

  color:#1E2432;

  font-size:1.7em;

}

.requisiti-card ul{

  list-style:none;

  padding:0;

  margin:0;

}

.requisiti-card li{

  display:flex;

  align-items:flex-start;

  gap:18px;

  margin-bottom:28px;

}

.requisiti-card li img {
  width: 22px;
  height: 22px;

  min-width: 22px;
  min-height: 22px;

  max-width: 22px;
  max-height: 22px;

  object-fit: contain;

  display: block;

  margin-top: 4px;

  flex-shrink: 0;
}

.requisiti-card li strong{

  display:block;

  color:#1E2432;

  margin-bottom:4px;

  font-size:1.05em;

}

.requisiti-card li span{

  display:block;

  color:#70798A;

  line-height:1.7;

  font-size:.95em;

}

.requisiti-note{

  margin-top:40px;

  background:var(--primary);

  border-radius:10px;

  color:#fff;

  padding:22px 25px;

  line-height:1.8;

}

.requisiti-note strong{

  color:#fff;

}

.realizzazioni-section {
  padding: 80px 20px;
}

/* GRID SOLO REALIZZAZIONI */
.realizzazioni-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 18px;
}

/* CARD SOLO DI QUESTA SEZIONE */
.realizzazioni-item {
  display: block;
  text-decoration: none;
  overflow: hidden;
}

/* 🔥 QUADRATO PERFETTO CON RIEMPIMENTO */
.realizzazioni-item img {
  aspect-ratio: 1 / 1;
  width:100%;        /* puoi aumentare o diminuire */
  object-fit: cover;    /* 🔥 TAGLIA L'IMMAGINE */
  display: block;
  transition: 0.3s ease;
}

/* hover zoom leggero */
.realizzazioni-item:hover img {
  transform: scale(1.05);
}

/* ========================= */
/* FILTRI REALIZZAZIONI */
/* ========================= */

.realizzazioni-section .filters {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 10px;
  margin-bottom: 40px;
}

/* singolo bottone filtro */
.realizzazioni-section .filter {
  background: transparent;
  border: 1px solid #ddd;
  padding: 8px 18px;
  border-radius: 999px;
  font-size: 14px;
  cursor: pointer;
  transition: 0.3s ease;
  color: #333;
}

/* hover */
.realizzazioni-section .filter:hover {
  background: #f3f3f3;
  border-color: #ccc;
}

/* stato attivo */
.realizzazioni-section .filter.active {
  background: #e94e1b; /* colore brand */
  border-color: #e94e1b;
  color: #fff;
}

/* piccolo effetto click */
.realizzazioni-section .filter:active {
  transform: scale(0.96);
}

/* ========================= */
/* TITOLI REALIZZAZIONI */
/* ========================= */

.realizzazioni-section .title {
  text-align: center;
  font-size: 38px;
  font-weight: 700;
  color: #e94e1b; /* colore brand */
  margin-bottom: 10px;
  line-height: 1.2;
}

.realizzazioni-section .subtitle {
  text-align: center;
  font-size: 16px;
  color: #666;
  margin-bottom: 40px;
  font-weight: 400;
}

.realizzazioni-section .container {
  max-width: 1400px;
  margin: 0 auto;
  padding: 0 20px;
}

@media (max-width: 992px) {
  .realizzazioni-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 600px) {
  .realizzazioni-grid {
    grid-template-columns: 1fr;
  }
}

/* RESPONSIVE */
@media (max-width: 768px) {
  .section-header img {
    width: 32px;
  }
}

.project-hero {
  width: 90%;
  margin-bottom: 40px;
  margin-left:5%;
}

.project-hero img {
  width: 100%;
  height: 520px;
  object-fit: cover;
  display: block;
  border-radius: 6px;
}

.project-text {
  width:90%;

  margin: 5% auto 60px auto;
  text-align: left;
}

.project-text h1 {
  font-size: 34px;
  font-weight: 700;
  margin-bottom: 10px;
  color: #1f3f8a;
}

.project-text h3 {
  font-size: 16px;
  font-weight: 500;
  color: #666;
  margin-bottom: 20px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.project-text p {
  font-size: 15px;
  line-height: 1.7;
  color: #444;
}

/* GALLERY A GRIGLIA (come screenshot) */
.project-gallery {
  width:90%;
  aspect-ratio: 1 / 1;
  margin: 0 auto 80px auto;
  display: grid;
  grid-template-columns: repeat(14, 1fr);
  gap: 12px;
}

.g {
  overflow: hidden;
  border-radius: 6px;
}

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

/* layout identico screenshot */

.g1 {
  grid-column: 1 / 4;
  grid-row: 1 / 4;
}

.g2 {
  grid-column: 4 / 10;
  grid-row: 1 / 10;
}

.g3 {
  grid-column: 10 / 15;
  grid-row: 1 / 4;
}

.g4 {
  grid-column: 1 / 4;
  grid-row: 4 / 9;
}

.g5 {
  grid-column: 10 / 15;
  grid-row: 4 / 10;
}

.g6 {
  grid-column: 1 / 4;
  grid-row: 9 / 14;
}

.g7 {
  grid-column: 4 / 10;
  grid-row: 10 / 14;
}

.g8 {
  grid-column: 10 / 15;
  grid-row: 10 / 14;
}

/* immagine gallery */
.gallery-item img {
  width: 100%;
  height: 220px;
  object-fit: cover;
  border-radius: 6px;
}



/* VIDEO */

.project-video {
  width: 800px;
  height: 450px;
  margin: 60px auto;

  display: flex;
  justify-content: center;
  align-items: center;
}

.project-video video {
  width: 800px;
  height: 450px;
  object-fit: contain;
  display: block;
}

@media (max-width: 840px) {

  .project-video {
    width: 100%;
    height: auto;
  }

  .project-video video {
    width: 100%;
    height: auto;
    aspect-ratio: 16 / 9;
    object-fit: contain;
  }

}

/* =========================================
   PROJECT - SCROLL REVEAL
========================================= */

/* Stato iniziale degli elementi */

.project-hero,
.project-text,
.project-gallery .g,
.project-video {
  opacity: 0;
  transform: translateY(40px);
  transition:
    opacity 0.8s ease,
    transform 0.8s ease;
}


/* Stato visibile */

.project-hero.reveal,
.project-text.reveal,
.project-gallery .g.reveal,
.project-video.reveal {
  opacity: 1;
  transform: translateY(0);
}


/* =========================================
   HERO
========================================= */

.project-hero {
  transition-duration: 1s;
}


/* =========================================
   TESTO
========================================= */

.project-text {
  transition-duration: 0.9s;
}


/* =========================================
   GALLERY
========================================= */

.project-gallery .g {
  transition-duration: 0.8s;
}


/* Effetto progressivo sulle immagini */

.project-gallery .g:nth-child(1) {
  transition-delay: 0.05s;
}

.project-gallery .g:nth-child(2) {
  transition-delay: 0.15s;
}

.project-gallery .g:nth-child(3) {
  transition-delay: 0.25s;
}

.project-gallery .g:nth-child(4) {
  transition-delay: 0.35s;
}

.project-gallery .g:nth-child(5) {
  transition-delay: 0.45s;
}

.project-gallery .g:nth-child(6) {
  transition-delay: 0.55s;
}

.project-gallery .g:nth-child(7) {
  transition-delay: 0.65s;
}

.project-gallery .g:nth-child(8) {
  transition-delay: 0.75s;
}


/* =========================================
   VIDEO
========================================= */

.project-video {
  transition-duration: 0.9s;
}


/* =========================================
   ACCESSIBILITÀ
========================================= */

@media (prefers-reduced-motion: reduce) {

  .project-hero,
  .project-text,
  .project-gallery .g,
  .project-video {
    opacity: 1;
    transform: none;
    transition: none;
  }

}



/* CTA */
.cta {
  background: var(--primary);
  color: white;
  padding:50px;
}
.cta h2{
  font-size:1.8em;
  margin-bottom:30px;
}
.cta p{
  font-weight: 100;
  color:#DBEAFE;
  font-size:1.2em;
  margin-bottom:40px;
}
/* RESPONSIVE */
@media (max-width: 768px) {
  .grid-2,
  .grid-3,
  .steps-grid {
    grid-template-columns: 1fr;
  }

  .hero-incentivi {
    height: 50vh;
  }
}

/* ======================================================
   RESPONSIVE BONUS
====================================================== */

@media (max-width:768px){

  .hero-bonus{

    height:300px;

  }

  .hero-bonus h1{

    font-size:2.2em;

  }

  .hero-bonus p{

    width:100%;
    font-size:1em;

  }

  .bonus-grid{

    grid-template-columns:1fr;
    gap:40px;

  }





  .requisiti-card{

    padding:25px;
    width:90%;
  }

}

/* DESKTOP 3 COLONNE */
@media (min-width: 768px) {
  .footer-grid {
    grid-template-columns: repeat(3, 1fr);
  }
}

/* --------------------
   Responsive Mobile
-------------------- */

@media (max-width: 768px) {

  /* FONT GLOBALE */
  body {
    font-size: 14px;
  }

  .hero {
    min-height: 60vh;
  }

  .hero h1 {
    font-size: 2rem;
    width:100%;
  }
  .hero p {
    width:100%;
  }
  .contatti form {
    max-width: 90%;
    font-family: 'Archivo', Arial, Helvetica, sans-serif;
  }

  .servizi .grid,
  .incentivi .grid,
  .gallery,
  .contatti .grid,
  .logos,
  .footer-grid,
  .two-col{
    grid-template-columns: 1fr;
  }
  .footer-col:first-child {
    flex-direction: row;
    gap:5%;
  }
  .footer-logo {
    margin-bottom: 0;
    position: absolute;
    right:5%;
  }
  .footer-col p{
    width:50%;
  }

  .footer-grid {
    gap: 20px;
  }

  /* BOTTOM */
  .footer-bottom {
    display: block;
    width:80%;
    margin-left:10%;
    justify-content: center; /* sinistra + destra */
    align-items: center;

  }

  /* reset margini paragrafi */
  .footer-bottom p {
    margin: 10px;
    text-align: center;
  }

  section {
    padding: 50px 0;
  }

  /* IMMAGINE */
  .novita-img img {
    display:none;
  }
  /* GRID */
  .novita-grid {
    grid-template-columns: 1fr;
  }
  .novita-box {
    padding: 5px;
  }
  .novita-item {
    padding:15px;
    box-shadow: 0 5px 15px rgba(0,0,0,0.1);
    border-radius: 10px;
  }
  /* ICONA */
  /* Icona check - dimensione sempre fissa */
  .novita-item .icon {
    width: 28px;
    height: 28px;

    min-width: 28px;
    min-height: 28px;

    max-width: 28px;
    max-height: 28px;

    display: flex;
    align-items: flex-start;
    justify-content: center;

    flex-shrink: 0;
  }

  .novita-item .icon img {
    width: 22px;
    height: 22px;

    object-fit: contain;
    display: block;
  }
  /* TESTO */
  .novita-item h4 {
    font-size: 1.4em;
  }

  .novita-item p {
    font-size: 0.9em;
    line-height: 2em;
    color: #555;
  }

  .intervento-card h4, .intervento-card p, .accesso-grid h4, .accesso-grid p{
    text-align: center;
  }
  .intervento-card, .accesso-card{
    text-align: center;
  }
  .intervento-card img, .accesso-card img{
    display: block;
    margin-left: auto;
    margin-right: auto;
  }

  /* HAMBURGER */
  .menu-toggle {
    display: flex;
    flex-direction: column;
    justify-content: center;
    gap: 6px;
    cursor: pointer;
    width: 30px;
    height: 25px;
  }

  /* linee */
  .menu-toggle span {
    display: block;
    height: 3px;
    width: 100%;
    background: #364153;
    border-radius: 2px;
    transition: all 0.3s ease;
  }

  /* quando clicchi */
  .menu-toggle.active span:nth-child(1) {
    transform: translateY(9px) rotate(45deg);
  }

  .menu-toggle.active span:nth-child(2) {
    opacity: 0;
  }

  .menu-toggle.active span:nth-child(3) {
    transform: translateY(-9px) rotate(-45deg);
  }

  /* NASCONDO NAV DI DEFAULT */
  .nav {
    position: absolute;
    top: 80px;
    left: 0;
    width: 100%;
    background: white;

    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;

    padding: 30px 0;
    gap: 25px;

    text-align: center;

    opacity: 0;
    visibility: hidden;
    transform: translateY(-10px);
    transition: 0.3s;
  }

  /* NAV ATTIVO */
  .nav.active {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);

  }
  .nav a {
    font-size: 1.3em;
    display: block;
    width: 100%;
    text-align: center;
  }

  /* DROPDOWN MOBILE */
  .dropdown {
    display: flex;
    flex-direction: column;
    align-items: center;
  }
  /* DROPDOWN MOBILE */
  .dropdown-menu {
    max-height: 200px;
    overflow: hidden;
    transition: max-height 0.3s ease;
  }

  /* quando attivo */
  .dropdown.active .dropdown-menu {
    max-height: 400px; /* abbastanza per contenere le voci */
  }

}

