/* Reset di base */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

/* Impostazioni generali */
body {
  font-family: 'Roboto', sans-serif;
  line-height: 1.6;
  color: #333;
}

/* Contenitore centrale */
.container {
  width: 90%;
  max-width: 1200px;
  margin: 0 auto;
}

/* -------------- */
/* HEADER         */
/* -------------- */
.site-header {
  background-color: #fff;
  border-bottom: 1px solid #eaeaea;
  position: sticky;
  top: 0;
  z-index: 1000;
}
.header-container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 15px 0;
}
.logo img {
  height: 100px;
}

/* Navigazione */
.main-nav .nav-menu {
  list-style: none;
  display: flex;
  align-items: center;
}
.nav-menu li {
  position: relative;
  margin: 0 20px;
}
.nav-menu a {
  text-decoration: none;
  color: #333;
  font-weight: 700;
  transition: color 0.3s;
}
.nav-menu a:hover {
  color: #e50000;
}

/* Dropdown */
/* Dropdown Modificato */
.dropdown-menu {
  opacity: 0;
  visibility: hidden;
  position: absolute;
  top: calc(100% + 5px);
  left: 50%;
  transform: translateX(-50%) translateY(-10px);
  background-color: #fff;
  list-style: none;
  padding: 8px 0;
  min-width: 200px;
  border-radius: 12px;
  box-shadow: 0 8px 24px rgba(0,0,0,0.12);
  transition: all 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.1);
  z-index: 1000;
  border: 1px solid rgba(0,0,0,0.08);
}

.dropdown-menu li {
  margin: 0;
  position: relative;
  padding: 2px 6px; /* Spostiamo il padding qui dal link */
}

.dropdown-menu a {
  display: block;
  padding: 12px 20px;
  color: #333;
  font-family: 'Roboto', sans-serif;
  font-weight: 700;
  font-size: 0.95em;
  transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
  position: relative;
  border-radius: 8px;
  width: calc(100% - 12px); /* Compensiamo il padding del li */
  margin: 0 auto; /* Centratura orizzontale */
}

.dropdown-menu a:hover {
  background: #e50000 !important;
  color: #fff !important;
  transform: none; /* Rimuoviamo la traslazione */
  padding-left: 24px; /* Effetto slide più pulito */
}

/* Separatori */
.dropdown-menu li:not(:last-child)::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 16px;
  right: 16px;
  height: 1px;
  background-color: rgba(0,0,0,0.05);
}

/* Animazione apertura */
.dropdown.open .dropdown-menu {
  opacity: 1;
  visibility: visible;
  transform: translateX(-50%) translateY(0);
}


/* Base Styles */
:root {
  --ios-blue: #007AFF;
  --ios-gray-1: #F5F5F7;
  --ios-gray-2: #86868B;
  --ios-backdrop: rgba(0,0,0,0.4);
}

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

body {
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell;
}

/* Mostra solo l'header desktop su schermi grandi */
.site-header {
  display: block;
}
.ios-header {
  display: none;
}

/* Mobile: mostra l'header mobile e nascondi quello desktop */
@media (max-width: 1023px) {
  .site-header {
    display: none;
  }
  .ios-header {
    display: block;
  }
}



/* HEADER PER MOBILE*/
/* ============ SOLO MOBILE ============ */
@media (max-width: 1023px) {
  /* Fix layout shift */
  html.nav-open {
    overflow: hidden;
    position: fixed;
    width: 100%;
  }
}

@media (max-width: 1023px) {
  .ios-header .header-container {
    display: flex;
    align-items: center;
    justify-content: space-between;
    width: 100%;
  }
}

  /* Header mobile */
  .ios-header {
    position: fixed;
    top: 0;
    width: 100%;
    height: 100px;
    z-index: 3000;
    background: #ffffff;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 20px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.05);
    transition: transform 0.2s ease-in-out;
  }

  main {
    padding-top: 0; /* Regola di default per schermi grandi */
  }
  
  @media only screen and (max-width: 767px) {
    main {
      padding-top: 60px; /* Valido solo per dispositivi mobile */
    }
  }


/* Classe per nascondere l'header */
.ios-header.hidden {
  transform: translateY(-100%);
}

  /* Logo 100px */
  .ios-header .brand-logo img {
    height: 80px; /* Ridotto per adattarsi all'header */
    width: auto;
    object-fit: contain;
  }

  /* Hamburger icon centrata */
  .hamburger-menu {
    background: none;
    border: none;
    padding: 12px;
    margin: 0;
    margin-left: auto;
    cursor: pointer;
    transform: translateY(2px);
  }

  .hamburger-bar {
    display: block;
    width: 28px;
    height: 2px;
    background: #333;
    margin: 5px 0;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    transform-origin: center;
  }

  /* Animazione X perfetta */
  .hamburger-menu[aria-expanded="true"] .hamburger-bar:nth-child(1) {
    transform: translateY(7px) rotate(45deg) scaleX(0.9);
    background: #e50000;
  }
  .hamburger-menu[aria-expanded="true"] .hamburger-bar:nth-child(2) {
    opacity: 0;
  }
  .hamburger-menu[aria-expanded="true"] .hamburger-bar:nth-child(3) {
    transform: translateY(-7px) rotate(-45deg) scaleX(0.9);
    background: #e50000;
  }

  /* Menu overlay */
  .nav-overlay {
    position: fixed;
    top: 80px;
    right: -100%;
    width: 85%;
    height: calc(100vh + 100px);
    background: #fff;
    transition: transform 0.3s cubic-bezier(0.25, 0.46, 0.45, 0.94);
    padding: 25px 20px;
    overflow-y: auto;
    z-index: 9999;
  }

  .nav-overlay[aria-hidden="false"] {
    transform: translateX(-100%);
  }

  /* Lista navigazione */
  .ios-nav-list {
    padding: 0;
    list-style: none;
  }

  /* Voci menu */
  .nav-link {
    font-weight: bold;
    display: block;
    padding: 16px 20px;
    margin: 8px 0;
    font-size: 17px;
    color: #1D1D1F;
    border-radius: 12px;
    background: rgba(0,0,0,0.03);
    transition: background 0.2s ease;
    text-decoration: none;
    border-bottom: none;
  }

  /* Dropdown */
  .dropdown-summary {
    font-weight: bold;
    position: relative;
    padding: 16px 20px;
    margin: 8px 0;
    background: rgba(0,0,0,0.03);
    border-radius: 12px;
    cursor: pointer;
    list-style: none;
    user-select: none;
    -webkit-user-select: none;
    -moz-user-select: none;
    -ms-user-select: none;
    cursor: pointer; 
  }

  .dropdown-chevron {
    position: absolute;
    right: 20px;
    top: 50%;
    transform: translateY(-50%);
    transition: transform 0.3s ease;
  }

  .ios-dropdown[open] .dropdown-chevron {
    transform: translateY(-50%) rotate(90deg);
    color: #e50000;
  }

  .dropdown-content {
    padding-left: 10px;
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.35s cubic-bezier(0.4, 0, 0.2, 1);
  }

  .ios-dropdown[open] .dropdown-content {
    max-height: 500px;
  }

  .dropdown-link {
    font-weight: bold;
    display: block;
    padding: 14px 20px;
    margin: 4px 0;
    font-size: 15px;
    color: #e50000;
    background: rgba(0,0,0,0.02);
    border-radius: 8px;
    text-decoration: none;
    opacity: 0;
    animation: itemReveal 0.4s ease forwards;
  }


  .dropdown-link:active,
  .dropdown-link:focus {
    background-color: #333; /* oppure il colore che preferisci */
    color: #fff;
  }

  /* Animazione elementi */
  @keyframes itemReveal {
    0% {
      opacity: 0;
      transform: translateX(-10px);
    }
    100% {
      opacity: 1;
      transform: translateX(0);
    }
  }

  /* Active state */
  .nav-link:active,
  .dropdown-summary:active {
    background: #e50000;
    color: white !important;
  }

  /* Nascondi frecce native */
  .dropdown summary::-webkit-details-marker {
    display: none;
  }


@media (min-width: 1024px) {
  .ios-header {
    display: none !important;
  }
}


/* -------------- */
/* HERO SECTION   */
/* -------------- */
.hero {
  position: relative;
  background: url('hero.jpg') no-repeat center center/cover;
  height: 700px;
  display: flex;
  align-items: center;
  justify-content: center;
}
.hero-content {
  text-align: center;
  color: #fff;
  background: rgba(0, 0, 0, 0.4);
  padding: 30px 20px;
  border-radius: 5px;
}
.hero-content h1 {
  font-size: 2.5rem;
  margin-bottom: 20px;
}
.btn {
  background-color: #e50000;
  color: #fff;
  padding: 10px 25px;
  text-decoration: none;
  font-weight: 700;
  border-radius: 5px;
  transition: background-color 0.3s;
}
.btn:hover {
  background-color: #e50000;
}

/* CSS FUNZIONANTE */
.slider-container {
  padding: 2rem;
  max-width: 1200px;
  margin: 0 auto;
}

.slider {
  position: relative;
  overflow: hidden;
  border-radius: 12px;
  box-shadow: 0 4px 15px rgba(0,0,0,0.1);
}

.slider-inner {
  display: flex;
  transition: transform 0.4s cubic-bezier(0.23, 1, 0.32, 1);
}

.slide {
  min-width: 100%;
  position: relative;
  padding: 15px;
  box-sizing: border-box;
}

.slide img {
  width: 100%;
  height: 400px;
  object-fit: contain;
  border-radius: 8px;
  border: 1px solid #eee;
}

.slider-control {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  background: rgba(255,255,255,0.95);
  border: none;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  cursor: pointer;
  font-size: 1.2rem;
  color: #333;
  box-shadow: 0 2px 8px rgba(0,0,0,0.15);
  transition: all 0.3s ease;
  z-index: 10;
}

.slider-control:hover {
  background: #fff;
  transform: translateY(-50%) scale(1.1);
}

.slider-control.prev { left: 20px; }
.slider-control.next { right: 20px; }

@media (max-width: 768px) {
  .slide img {
    height: 300px;
    object-fit: contain;
  }
  
  .slider-control {
    width: 35px;
    height: 35px;
    font-size: 1rem;
  }
}

/* -------------- */
/* SEZIONE INFO   */
/* -------------- */
/* Sfondo per la sezione informativa */
.info {
  /* Applica l'immagine di sfondo */
  background: url('bg-info.jpg') no-repeat center center;
  background-size: cover;
  /* Puoi opzionalmente aggiungere un colore di fallback */
  background-color: #f7f7f7;
}

.info {
  padding: 60px 20px;
  background-color: #ffffff;
}

.info-container {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: 40px;
  max-width: 1200px;
  margin: 0 auto;
}

.info-text {
  flex: 1;
  min-width: 300px;
  max-width: 600px;
  font-size: 1.2rem;
  line-height: 1.8;
  color: #ffffff;
}

.info-title {
  font-size: 2.5rem;   /* Dimensione del titolo */
  font-weight: bold;
  margin-bottom: 20px;
  color: #ffffff;
}

.info-image {
  flex: 1;
  min-width: 300px;
  max-width: 600px;
  object-fit: contain;
}

.info-image img {
  width: 100%;
  height: auto;           /* Mantiene le proporzioni originali */
  object-fit: contain;
  border-radius: 10px;
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
  transition: transform 0.3s ease;
}

.info-image img:hover {
  transform: none;
}





/* -------------- */
/* FOOTER         */
/* -------------- */
/* Footer Section - Versione Più Compatta */
/* -------------- */
/* FOOTER         */
/* -------------- */
:root {
  --footer-bg: #333;
  --footer-text: #fff;
  --footer-border: rgba(255,255,255,0.1);
  --transition-duration: 0.3s;
  --footer-padding-mobile: 2rem 1rem;
  --footer-padding-desktop: 3rem 2rem;
}

/* Footer Base */
footer {
  background-color: var(--footer-bg);
  color: var(--footer-text);
  padding: var(--footer-padding-mobile);
  font-size: 0.9rem;
  position: relative;
  z-index: 0;
}

/* Footer Container (mobile-first) */
.footer-container {
  display: flex;
  flex-direction: column;
  gap: 4rem;
  max-width: 1200px;
  margin: 0 auto;
  padding-bottom: 3rem; /* Spazio per il footer-bottom */
  box-sizing: border-box;
}

/* Sezione Sinistra: Logo e Informazioni */
.footer-left {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  gap: 1rem;
}

.footer-logo {
  height: 40px;
  width: auto;
  transition: transform var(--transition-duration) ease;
}

.footer-logo:hover {
  transform: scale(1.05);
}

/* Sezione Destra: Social Links */
.social-links {
  display: flex;
  justify-content: center;
  gap: 1.5rem;
  flex-wrap: wrap;
}

.social-links a {
  display: inline-block;
  transition: transform var(--transition-duration) ease;
}

.social-links a:hover {
  transform: translateY(-2px);
}

.social-links .linkedin-icon {
  height: auto;
  width: 50px;
  vertical-align: middle;
}

/* Footer Bottom: link Privacy e Cookie Policy */
.footer-bottom {
  text-align: center;
  padding-top: 2rem;
  border-top: 1px solid var(--footer-border);
  margin-top: 2rem;
  z-index: 0;
}

/* Media Query per Desktop */
@media screen and (min-width: 768px) {
  footer {
    padding: var(--footer-padding-desktop);
  }
  .footer-container {
    flex-direction: row;
    justify-content: space-between;
    align-items: flex-start;
    gap: 4rem;
  }
  .footer-left {
    flex-direction: row;
    text-align: left;
    align-items: center;
    flex: 1;
  }
  .social-links {
    justify-content: flex-end;
  }
  .footer-bottom {
    position: absolute;
    bottom: 1rem;
    left: 50%;
    transform: translateX(-50%);
    border-top: none;
    margin-top: 0;
    padding-top: 0;
    width: 100%;
  }
}

/* Ottimizzazione per Mobile Molto Piccoli */
@media screen and (max-width: 480px) {
  .footer-left p {
    font-size: 0.8rem;
  }
  .social-links .linkedin-icon {
    height: 30px;
  }
  .footer-bottom {
    font-size: 0.75rem;
  }
}




/* ----------------------- */
/* SEZIONE SHOP (PRODOTTI) */
/* ----------------------- */
.shop {
  padding: 60px 20px;
  background-color: #fff;
  text-align: center;
}

.shop h1 {
  font-size: 2.5rem;
  margin-bottom: 40px;
  color: #333;
}

/* Griglia dei prodotti */
.products-grid {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 30px;
}

/* SEZIONE DETTAGLIO PRODOTTO */
.product-detail {
  padding: 60px 20px;
  background-color: #fff;
}

/* Raggruppa la descrizione e il pulsante */
.product-details {
  display: flex;
  flex-direction: column;
  flex: 1;  /* Occupa lo spazio rimanente */
}

.product-descriptionsss {
  margin-bottom: 20px;
  white-space: normal;
  overflow-wrap: break-word;
  word-break: break-word;
  hyphens: auto;
  box-sizing: border-box;
}

/* Spinge il pulsante in fondo */
.product-button {
  margin-top: auto;
}

.product-info {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 40px;
  max-width: 1200px;
  margin: 0 auto;
}

.product-image {
  flex: 0 0 400px; /* Forza una larghezza fissa per l'immagine */
}

.product-image img {
  width: 100%;
  max-width: 400px;
  height: auto;
  object-fit: contain;
  border-radius: 10px;
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
}

.product-description {
  flex: 1;
  min-width: 300px;
}



@media (max-width: 768px) {
  .product-info {
    flex-direction: column;
  }
  .product-image {
    flex: none;
    width: 100%;
  }
}


.old-price {
  text-decoration: line-through;
  color: #999;
  font-size: 1.2rem;
}

.new-price {
  color: #e50000;
  font-size: 1.6rem;
  font-weight: bold;
}

/* SEZIONE MODULO DI CONTATTO */
.contact {
  padding: 60px 20px;
  background-color: #f9f9f9;
}

.contact h2 {
  font-size: 2rem;
  margin-bottom: 20px;
}

.form-group {
  margin-bottom: 15px;
}

.form-group label {
  display: block;
  margin-bottom: 5px;
  font-weight: bold; /* Le voci rimangono in grassetto */
}

.form-group input {
  width: 100%;
  padding: 10px;
  border: 1px solid #ccc;
  border-radius: 5px;
  transition: border-color 0.3s ease;
}

.form-group input:focus {
  border-color: #e50000;
  outline: none;
}

/* Pulsante per il prodotto */
.btn-product {
  display: inline-block;
  background-color: #e50000;
  color: #fff;
  padding: 10px 20px;
  text-decoration: none;
  font-weight: bold;
  border-radius: 5px;
  margin-top: 10px;
  transition: background-color 0.3s ease;
}

.btn-product:hover {
  background-color: #e50000;
}

/* Stile per il tasto "Invia Richiesta" */
button[type="submit"],
input[type="submit"] {
  display: inline-block;
  background-color: #e50000; /* Colore principale */
  color: #fff; /* Testo bianco */
  font-size: 1.1rem;
  font-weight: bold;
  padding: 12px 24px;
  border: none; /* Nessun bordo */
  border-radius: 5px; /* Angoli arrotondati */
  cursor: pointer;
  transition: background-color 0.3s ease, transform 0.2s ease;
}

/* Effetto hover: cambia colore e aggiungi un leggero sollevamento */
button[type="submit"]:hover,
input[type="submit"]:hover {
  background-color: #e50000;
  transform: translateY(-2px);
}

/* Se vuoi disabilitare il pulsante e dare un feedback visivo */
button[type="submit"]:disabled,
input[type="submit"]:disabled {
  background-color: #ccc;
  cursor: not-allowed;
}

/* Slider Sezione Informativa */
.info-image {
  position: relative;
  overflow: hidden;
  border-radius: 10px;
  object-fit: contain;
}

.image-slider-container {
  position: relative;
  width: 100%;
  padding-top: 133.33%; /* Proporzione 3:4 (3024x4032) */
}

.image-slider {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
}

.info-slide {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  opacity: 0;
  transition: opacity 1.5s cubic-bezier(0.4, 0, 0.2, 1), transform 1.5s cubic-bezier(0.4, 0, 0.2, 1);
  transform: scale(1.02);
}

.info-slide.active {
  opacity: 1;
  transform: scale(1);
}

.info-slide img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  border-radius: 10px;
}

.brochure-download {
  margin-top: 20px;
  text-align: center;
}

.brochure-download a {
  display: inline-block;
  background-color: #e50000;
  color: #fff;
  padding: 10px 20px;
  text-decoration: none;
  font-weight: bold;
  border-radius: 5px;
  transition: background-color 0.3s ease;
}

.brochure-download a:hover {
  background-color: #c40000;
}

/* Container dei pulsanti di categoria */
.category-buttons {
  display: flex;
  justify-content: center;  /* Centra i pulsanti orizzontalmente */
  gap: 20px;                /* Spazio uniforme tra i pulsanti */
  margin: 30px 0;           /* Spazio verticale sopra e sotto i pulsanti */
}

/* Stili base per i pulsanti */
.category-buttons button {
  background-color: #e50000;
  color: #fff;
  border: none;
  padding: 12px 20px;
  border-radius: 5px;
  font-size: 1.1rem;
  cursor: pointer;
  width: 200px;              /* Larghezza fissa per garantire dimensioni uguali */
  height: 50px;              /* Altezza fissa */
  display: flex;             /* Utilizza Flexbox per centrare il contenuto */
  align-items: center;
  justify-content: center;
  box-sizing: border-box;    /* Includi padding e border nella larghezza/altezza fissa */
  transition: transform 0.3s ease, background-color 0.3s ease;
  
  /* Animazione di entrata: fade in e slide up */
  animation: fadeInUp 0.6s ease-out forwards;
  opacity: 0; /* Inizialmente invisibili */
}

/* Effetto hover: ingrandimento leggero e cambio di colore */
.category-buttons button:hover {
  background-color: #c40000;
  transform: scale(1.05);
}

/* Animazione stagger per ciascun pulsante */
.category-buttons button:nth-child(1) {
  animation-delay: 0.2s;
}
.category-buttons button:nth-child(2) {
  animation-delay: 0.4s;
}
.category-buttons button:nth-child(3) {
  animation-delay: 0.6s;
}

/* Keyframes per l'animazione fadeInUp */
@keyframes fadeInUp {
  0% {
    transform: translateY(20px);
    opacity: 0;
  }
  100% {
    transform: translateY(0);
    opacity: 1;
  }
}



/* Sezioni Prodotti */
.products-section {
  margin: 80px 0;
}

.products-section h2 {
  text-align: center;
  margin-bottom: 30px;
  font-size: 2rem;
  color: #333;
}

/* Griglia prodotti */
.products-grid {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 30px;
}

/* Stile per ogni prodotto */
.product-item {
  background: #f9f9f9;
  padding: 20px;
  border-radius: 10px;
  width: calc(25% - 30px); /* Layout a 4 colonne */
  min-width: 250px;
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
  text-align: left;
  transition: transform 0.3s ease;
  display: flex;           /* Abilita Flexbox */
  flex-direction: column;  /* Dispone i figli in colonna */
}

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

.product-item img {
  width: 100%;
  border-radius: 5px;
  margin-bottom: 15px;
}

.product-item h3 {
  font-size: 1.5rem;
  margin-bottom: 10px;
  color: #333;
}

.product-item p {
  font-size: 1rem;
  color: #666;
}
/* (Inserisci qui anche eventuali altre regole già presenti per header, footer, ecc.) */

/* Sezione Immagine Fissa */
.fixed-image-section {
  position: relative;
  width: 100%;
  height: 350px; /* Altezza del contenitore */
  background-image: url('bg-fisco.jpg'); /* Assicurati che il percorso sia corretto */
  background-size: cover; /* L'immagine copre l'intero contenitore */
  background-position: center; /* Centra l'immagine sia orizzontalmente che verticalmente */
  background-repeat: no-repeat;
}

/* Sezione Immagine Fissa per Prodotti Lavoro */
.fixed-image-section-lavoro {
  position: relative;
  width: 100%;
  height: 350px;
  background-image: url('bg-lavoro.jpg'); /* Immagine per prodotti-lavoro.html */
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
}

/* Sezione Immagine Fissa per Prodotti Diritto */
.fixed-image-section-diritto {
  position: relative;
  width: 100%;
  height: 350px;
  background-image: url('bg-diritto.jpg'); /* Immagine per prodotti-lavoro.html */
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
}

.dropdown > a {
  user-select: none;         /* Standard */
  -webkit-user-select: none; /* Chrome, Safari */
  -moz-user-select: none;    /* Firefox */
  -ms-user-select: none;     /* IE/Edge */
  cursor: pointer;           /* Indica che è cliccabile */
}











