/* =============================================================
   CORTE FERRARI - FOGLIO DI STILE PRINCIPALE
   ============================================================= */

/* --- 1. VARIABILI E PALETTE COLORI --- */
:root {
  --cf-primary: #a04040;      /* Bordeaux caldo - colore principale */
  --cf-primary-dark: #8c3636; /* Bordeaux scuro - hover/stati attivi */
  --cf-accent: #fdd835;       /* Giallo oro - accenti e dettagli */
  
  --cf-text-main: #333333;
  --cf-text-light: #666666;
  --cf-bg-light: #ffffff;
  --cf-bg-soft: #fdfaf5;      /* Sfondo caldo e neutro */
  
  --font-heading: Georgia, 'Times New Roman', serif;
  --font-body: 'Helvetica Neue', Arial, sans-serif;
}

/* --- 2. RESET E BASE --- */
* { box-sizing: border-box; }
body {
  font-family: var(--font-body);
  color: var(--cf-text-main);
  background-color: var(--cf-bg-light);
  line-height: 1.6;
  margin: 0;
  padding: 0;
}
h1, h2, h3, h4 {
  font-family: var(--font-heading);
  color: var(--cf-primary);
  margin-top: 0;
}
a { color: var(--cf-primary); text-decoration: none; transition: color 0.3s; }
a:hover { color: var(--cf-primary-dark); }
img { max-width: 100%; height: auto; }

/* --- 3. BOTTONI --- */
.btn-primary {
  background-color: var(--cf-primary);
  color: #ffffff !important;
  padding: 12px 24px;
  border-radius: 4px;
  text-transform: uppercase;
  font-weight: bold;
  letter-spacing: 1px;
  text-align: center;
  display: inline-block;
  border: none;
  cursor: pointer;
  transition: background-color 0.3s ease;
}
.btn-primary:hover { background-color: var(--cf-primary-dark); }

.btn-secondary {
  background-color: transparent;
  color: #ffffff !important;
  border: 2px solid #ffffff;
  padding: 10px 22px;
  border-radius: 4px;
  text-transform: uppercase;
  font-weight: bold;
  letter-spacing: 1px;
  display: inline-block;
  transition: all 0.3s ease;
}
.btn-secondary:hover { background-color: #ffffff; color: var(--cf-primary) !important; }
.btn-nav { padding: 10px 20px; font-size: 0.85rem; }


/* --- 4. NAVIGAZIONE (MENU) --- */
#main-nav {
  background: transparent;
  padding: 20px 20px;
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  z-index: 1000;
  transition: background-color 0.4s ease, box-shadow 0.4s ease, padding 0.4s ease;
}

/* Quando la pagina scrolla, l'header diventa solido */
#main-nav.scrolled {
  background: #ffffff;
  box-shadow: 0 2px 10px rgba(0,0,0,0.1);
  padding: 10px 20px;
}

/* Logo */
#main-nav .logo {
  color: #ffffff;
  font-family: var(--font-heading);
  font-size: 1.5rem;
  font-weight: bold;
  transition: color 0.4s ease;
}
#main-nav.scrolled .logo {
  color: var(--cf-primary);
}

/* Contenitore del menu */
.nav-container {
  max-width: 1200px;
  margin: 0 auto;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 15px;
}

/* Lista dei link (RIPRISTINATA!) */
.nav-links {
  display: flex;
  list-style: none; /* Toglie i pallini */
  margin: 0;
  padding: 0;
  gap: 20px;
  align-items: center;
}

.nav-links a {
  color: #ffffff;
  font-weight: 500;
  font-size: 0.95rem;
  transition: color 0.4s ease;
}
#main-nav.scrolled .nav-links a {
  color: var(--cf-text-main);
}
#main-nav .nav-links a:hover {
  color: var(--cf-accent);
}
#main-nav.scrolled .nav-links a:hover {
  color: var(--cf-primary);
}

/* Azioni sulla destra */
.nav-actions {
  display: flex;
  gap: 15px;
  align-items: center;
}

/* Selettore lingua */
#main-nav .lang-toggle {
  color: #ffffff;
  background: transparent;
  border: 1px solid rgba(255,255,255,0.5);
  padding: 8px 12px;
  border-radius: 20px;
  font-family: var(--font-body);
  font-size: 0.85rem;
  font-weight: bold;
  cursor: pointer;
  transition: all 0.4s ease;
  display: flex;
  align-items: center;
  gap: 8px;
}
#main-nav.scrolled .lang-toggle {
  color: var(--cf-text-main);
  border-color: #ddd;
}
#main-nav .lang-toggle:hover,
#main-nav.scrolled .lang-toggle:hover {
  border-color: var(--cf-primary);
  color: var(--cf-primary);
}
.lang-toggle i.fa-chevron-down { font-size: 0.6rem; }

/* Bottone Prenota */
#main-nav .btn-nav {
  background-color: transparent;
  border: 2px solid #ffffff;
  color: #ffffff !important;
  padding: 10px 20px;
  font-size: 0.85rem;
  transition: all 0.4s ease;
}
#main-nav .btn-nav:hover {
  background-color: #ffffff;
  color: var(--cf-primary) !important;
}
#main-nav.scrolled .btn-nav {
  background-color: var(--cf-primary);
  border-color: var(--cf-primary);
  color: #ffffff !important;
}
#main-nav.scrolled .btn-nav:hover {
  background-color: var(--cf-primary-dark);
}

/* Dropdown Lingue */
.lang-dropdown { position: relative; display: inline-block; }
.lang-menu {
  display: none;
  position: absolute;
  top: 100%;
  right: 0;
  background: #fff;
  list-style: none;
  padding: 10px 0;
  margin: 0;
  border-radius: 8px;
  box-shadow: 0 4px 15px rgba(0,0,0,0.1);
  min-width: 80px;
  z-index: 1001;
}
/* Ponte invisibile per non far chiudere il menu */
.lang-menu::before {
  content: "";
  position: absolute;
  top: -15px;
  left: 0;
  width: 100%;
  height: 15px;
}
.lang-dropdown:hover .lang-menu { display: block; }
.lang-menu li a {
  display: block;
  padding: 8px 15px;
  color: var(--cf-text-main);
  font-size: 0.85rem;
  font-weight: bold;
  text-align: center;
}
.lang-menu li a:hover { background: #f9f6f0; color: var(--cf-primary); }
.lang-menu li a.active { color: var(--cf-primary); }

/* Hamburger Mobile */
.mobile-menu-toggle {
  display: none;
  background: none;
  border: none;
  font-size: 1.5rem;
  color: #ffffff;
  cursor: pointer;
  padding: 5px;
  transition: color 0.4s ease;
}
#main-nav.scrolled .mobile-menu-toggle { color: var(--cf-primary); }

.mobile-menu {
  display: none;
  position: absolute;
  top: 100%;
  left: 0;
  width: 100%;
  background: #fff;
  box-shadow: 0 4px 10px rgba(0,0,0,0.1);
  padding: 20px;
  z-index: 999;
}
.mobile-menu.is-open { display: block; }
.mobile-links {
  list-style: none;
  padding: 0;
  margin: 0;
  text-align: center;
}
.mobile-links li { margin-bottom: 15px; }
.mobile-links a { font-size: 1.1rem; color: var(--cf-text-main); font-weight: 500; }
.mobile-links a:hover { color: var(--cf-primary); }


/* --- 5. HERO SECTION (Home e Pagine interne) --- */
.hero-section, .page-header {
  background-size: cover;
  background-position: center;
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  padding-top: 140px; /* Spazio per far respirare l'header fisso */
  padding-bottom: 60px;
}
.hero-section { min-height: 80vh; }
.page-header { min-height: 45vh; }

.hero-overlay {
  position: absolute;
  top: 0; left: 0; width: 100%; height: 100%;
  background: linear-gradient(to bottom, rgba(0,0,0,0.6) 0%, rgba(0,0,0,0.3) 50%, rgba(0,0,0,0.1) 100%);
  z-index: 1;
}
.hero-content {
  position: relative;
  z-index: 2;
  text-align: center;
  color: #ffffff;
  padding: 20px;
  max-width: 900px;
}
.hero-content .eyebrow {
  text-transform: uppercase;
  letter-spacing: 3px;
  font-weight: bold;
  font-size: 0.9rem;
}
.hero-content h1 {
  color: #ffffff;
  font-size: 3.5rem;
  margin: 20px 0;
  text-shadow: 2px 2px 4px rgba(0,0,0,0.5);
}
.page-header .hero-content h1 { font-size: 2.8rem; }
.hero-content p {
  font-size: 1.2rem;
  line-height: 1.6;
  margin-bottom: 30px;
  text-shadow: 1px 1px 3px rgba(0,0,0,0.5);
}
.hero-buttons { display: flex; justify-content: center; gap: 15px; flex-wrap: wrap; }


/* --- 6. BOOKING FORM (Stile Premium) --- */
.booking-hero {
  background: #f9f6f0;
  padding: 40px 20px;
  border-top: 1px solid #e8e0d0;
  border-bottom: 1px solid #e8e0d0;
}
.container-booking { max-width: 1100px; margin: 0 auto; }
.booking-header { text-align: center; margin-bottom: 25px; }
.booking-header h2 {
  font-family: var(--font-heading);
  color: var(--cf-primary);
  font-size: 1.8rem;
  margin: 0;
  letter-spacing: 1px;
}
.booking-form {
  display: grid;
  grid-template-columns: 1fr 1fr auto;
  gap: 20px;
  align-items: end;
  background: #ffffff;
  padding: 25px 30px;
  border-radius: 10px;
  box-shadow: 0 8px 25px rgba(0,0,0,0.08);
}
.booking-field { display: flex; flex-direction: column; }
.booking-field label {
  font-size: 0.85rem;
  font-weight: 600;
  color: #555;
  margin-bottom: 8px;
  display: flex;
  align-items: center;
  gap: 6px;
}
.booking-field label i { color: var(--cf-primary); }
.booking-field input {
  padding: 14px 16px;
  border: 1px solid #ddd;
  border-radius: 6px;
  font-size: 1rem;
  font-family: var(--font-body);
  background: #fafafa;
  transition: border-color 0.3s, background 0.3s;
}
.booking-field input:focus {
  outline: none;
  border-color: var(--cf-primary);
  background: #fff;
}
.btn-cta {
  background-color: var(--cf-primary);
  color: #fff;
  border: none;
  padding: 15px 30px;
  font-size: 1rem;
  font-weight: bold;
  text-transform: uppercase;
  letter-spacing: 1px;
  border-radius: 6px;
  cursor: pointer;
  transition: background 0.3s ease, transform 0.2s ease;
  display: inline-flex;
  align-items: center;
  gap: 10px;
  white-space: nowrap;
}
.btn-cta:hover { background-color: var(--cf-primary-dark); transform: translateY(-2px); }
.btn-cta i { transition: transform 0.2s ease; }
.btn-cta:hover i { transform: translateX(4px); }


/* --- 7. SEZIONI GENERALI --- */
.section-padding { padding: 80px 20px; }
.container-narrow { max-width: 900px; margin: 0 auto; }
.container-wide { max-width: 1200px; margin: 0 auto; }
.text-center { text-align: center; }
.section-eyebrow {
  text-transform: uppercase;
  letter-spacing: 3px;
  font-weight: bold;
  font-size: 0.8rem;
  color: var(--cf-primary);
}
.section-subtitle {
  max-width: 700px;
  margin: 0 auto 30px auto;
  color: var(--cf-text-light);
}


/* --- 8. SEZIONE INTRO --- */
.intro-section {
  background-size: cover;
  background-position: center;
  position: relative;
}
.intro-overlay {
  position: absolute;
  top: 0; left: 0; width: 100%; height: 100%;
  background: rgba(253, 250, 245, 0.85); 
  z-index: 1;
}
.intro-content { position: relative; z-index: 2; }
.intro-content p {
  font-size: 1.1rem;
  line-height: 1.8;
  color: var(--cf-text-main);
}


/* --- 9. SEZIONE USP (Punti di Forza) --- */
.usp-section { background-color: var(--cf-bg-light); }
.usp-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 30px;
}
.usp-box {
  text-align: center;
  padding: 30px 20px;
  border: 1px solid #f0f0f0;
  border-radius: 8px;
  background: #fff;
  box-shadow: 0 4px 15px rgba(0,0,0,0.03);
  transition: transform 0.3s ease;
}
.usp-box:hover { transform: translateY(-5px); }
.usp-box h3 { font-size: 1.3rem; margin-bottom: 15px; }
.usp-box p { font-size: 0.95rem; color: var(--cf-text-light); }


/* --- 10. SERVIZI --- */
.services-section { background-color: var(--cf-bg-soft); }
.services-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 30px;
  margin-top: 40px;
}
.service-box {
  background: #fff;
  padding: 30px 20px;
  border-radius: 8px;
  box-shadow: 0 4px 15px rgba(0,0,0,0.05);
  text-align: center;
  transition: transform 0.3s ease;
}
.service-box:hover { transform: translateY(-5px); }
.service-box i { font-size: 2.5rem; color: var(--cf-primary); margin-bottom: 15px; }
.service-box h3 { font-size: 1.1rem; margin-bottom: 10px; }
.service-box p { font-size: 0.9rem; color: var(--cf-text-light); }


/* --- 11. GALLERIA --- */
.gallery-section { background-color: #fff; }
.gallery-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 20px;
  margin: 40px 0;
}
.gallery-item img {
  width: 100%;
  height: 250px;
  object-fit: cover;
  border-radius: 8px;
  box-shadow: 0 4px 15px rgba(0,0,0,0.1);
  transition: transform 0.3s ease;
}
.gallery-item img:hover { transform: scale(1.02); }


/* --- 12. TERRITORIO E MAPPA --- */
.territory-section { background-color: #F4EFE6; }
.google-map {
  width: 100%;
  height: 450px;
  border-radius: 8px;
  overflow: hidden;
  box-shadow: 0 4px 15px rgba(0,0,0,0.1);
  margin-top: 40px;
}
.google-map iframe { width: 100%; height: 100%; border: 0; }


/* --- 13. RECENSIONI --- */
.reviews-section { background-color: var(--cf-bg-soft); }
.reviews-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 30px;
  margin-top: 40px;
}
.review-box {
  background: #fff;
  padding: 30px 20px;
  border-radius: 8px;
  box-shadow: 0 4px 15px rgba(0,0,0,0.05);
  font-style: italic;
  position: relative;
}
.review-box p { font-size: 0.95rem; margin-bottom: 15px; }
.review-author {
  display: block;
  font-weight: bold;
  font-style: normal;
  color: var(--cf-primary);
  font-size: 0.85rem;
}


/* --- 14. CTA FINALE --- */
.cta-section { background-color: var(--cf-primary); color: #fff; }
.cta-section h2 { color: #fff; }
.cta-section p { color: rgba(255,255,255,0.9); margin-bottom: 30px; }
.cta-section .btn-primary { background-color: #fff; color: var(--cf-primary) !important; }
.cta-section .btn-primary:hover { background-color: #f0f0f0; }


/* --- 15. FOOTER --- */
footer { background: #2c2c2c; color: #cccccc; padding: 60px 20px 20px 20px; }
.footer-container {
  max-width: 1200px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 40px;
}
.footer-col h3, .footer-col h4 { color: var(--cf-accent); margin-bottom: 20px; }
.footer-col ul { list-style: none; padding: 0; margin: 0; }
.footer-col ul li { margin-bottom: 10px; }
.footer-col a { color: #cccccc; }
.footer-col a:hover { color: #ffffff; }
.footer-bottom {
  text-align: center;
  margin-top: 50px;
  padding-top: 20px;
  border-top: 1px solid #444;
  font-size: 0.8rem;
}


/* --- 16. TABELLA COMPARATIVA (Pagina Offerte) --- */
.compare-table {
  background: #fff;
  border-radius: 10px;
  box-shadow: 0 8px 25px rgba(0,0,0,0.08);
  overflow: hidden;
  margin-top: 30px;
}
.compare-row {
  display: grid;
  grid-template-columns: 1fr 1fr 1fr;
  border-bottom: 1px solid #eee;
}
.compare-row:last-child { border-bottom: none; }
.compare-cell {
  padding: 18px 20px;
  font-size: 0.95rem;
  color: var(--cf-text-main);
}
.compare-header {
  background: #f9f6f0;
  font-weight: bold;
  text-transform: uppercase;
  font-size: 0.8rem;
  letter-spacing: 1px;
}
.compare-header .highlight { color: var(--cf-primary); }
.compare-cell.highlight {
  background: #fdfaf5;
  font-weight: 600;
  color: var(--cf-primary);
}
.compare-cell.highlight i {
  color: #2e7d32;
  margin-right: 5px;
}


/* --- 17. FLATPICKR (Calendario) --- */
.flatpickr-calendar {
  border-radius: 8px;
  box-shadow: 0 8px 25px rgba(0,0,0,0.15) !important;
  font-family: var(--font-body) !important;
}
.flatpickr-day.selected, 
.flatpickr-day.startRange, 
.flatpickr-day.endRange, 
.flatpickr-day.selected.inRange, 
.flatpickr-day.startRange.inRange, 
.flatpickr-day.endRange.inRange {
  background: var(--cf-primary) !important;
  border-color: var(--cf-primary) !important;
}
.flatpickr-day:hover { background: #f4efE6 !important; border-color: transparent !important; }


/* --- 18. RESPONSIVE (Tablet e Mobile) --- */
@media (max-width: 900px) {
  /* Menu Mobile */
  .nav-links { display: none; } 
  .mobile-menu-toggle { display: block; } 
  .btn-nav { display: none; } 
  
  /* Form Prenotazione */
  .booking-form { grid-template-columns: 1fr 1fr; gap: 15px; }
  .booking-submit { grid-column: 1 / -1; }
  .btn-cta { width: 100%; justify-content: center; }
}

@media (max-width: 768px) {
  .hero-content h1 { font-size: 2.2rem; }
  .page-header .hero-content h1 { font-size: 2rem; }
  .section-padding { padding: 50px 20px; }
  .services-grid, .gallery-grid, .reviews-grid { grid-template-columns: 1fr; }
  
  /* Tabella Comparativa Responsive */
  .compare-row { grid-template-columns: 1fr; border-bottom: 2px solid #eee; }
  .compare-cell { padding: 12px 15px; text-align: left; }
  .compare-header { display: none; }
  .compare-cell.highlight { background: #fdfaf5; }
  .compare-cell::before {
    content: attr(data-label) ": ";
    font-weight: bold;
    color: #555;
    display: block;
    margin-bottom: 5px;
    font-size: 0.8rem;
    text-transform: uppercase;
  }
}

@media (max-width: 600px) {
  .booking-form { grid-template-columns: 1fr; padding: 20px; }
  .booking-header h2 { font-size: 1.4rem; }
}
/* --- 20. PAGINA APPARTAMENTI (Griglia e Card) --- */
.apt-filters {
  margin-bottom: 30px;
}
.filter-label {
  font-weight: 600;
  margin-right: 10px;
  color: var(--cf-text-light);
}
.filter-btn {
  display: inline-block;
  padding: 8px 18px;
  margin: 0 5px;
  background: #fff;
  border: 1px solid #ddd;
  border-radius: 20px;
  color: var(--cf-text-main);
  font-size: 0.9rem;
  transition: all 0.3s;
  cursor: pointer;
}
.filter-btn.active, .filter-btn:hover {
  background: var(--cf-primary);
  color: #fff;
  border-color: var(--cf-primary);
}

.apt-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
  gap: 30px;
}
.apt-card {
  background: #fff;
  border-radius: 10px;
  overflow: hidden;
  box-shadow: 0 4px 15px rgba(0,0,0,0.05);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
  display: flex;
  flex-direction: column;
}
.apt-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 8px 25px rgba(0,0,0,0.1);
}
.apt-card-img {
  height: 220px;
  overflow: hidden;
}
.apt-card-img img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.3s ease;
}
.apt-card:hover .apt-card-img img {
  transform: scale(1.05);
}
.apt-card-content {
  padding: 20px;
  flex-grow: 1;
  display: flex;
  flex-direction: column;
}
.apt-card-content h3 {
  margin: 0 0 10px 0;
  font-size: 1.3rem;
}
.apt-card-meta {
  font-size: 0.9rem;
  color: var(--cf-text-light);
  margin-bottom: 10px;
}
.apt-card-desc {
  font-size: 0.95rem;
  margin-bottom: 15px;
  flex-grow: 1;
}

/* --- 21. PAGINA DI DETTAGLIO (Layout a due colonne) --- */
.apt-detail-layout {
  display: grid;
  grid-template-columns: 2fr 1fr;
  gap: 40px;
}
.apt-gallery {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
  margin-bottom: 30px;
}
.apt-gallery img {
  width: 100%;
  height: 200px;
  object-fit: cover;
  border-radius: 8px;
  box-shadow: 0 2px 8px rgba(0,0,0,0.1);
}
.apt-gallery img:first-child {
  grid-column: 1 / -1;
  height: 300px;
}
.apt-detail-main h2 {
  margin-top: 0;
  margin-bottom: 20px;
}
.apt-detail-main p {
  line-height: 1.8;
}
.apt-detail-sidebar {
  position: sticky;
  top: 120px;
  align-self: start;
}
.apt-info-box {
  background: #f9f6f0;
  padding: 25px;
  border-radius: 8px;
  margin-bottom: 20px;
  border: 1px solid #eee;
}
.apt-info-box h3 {
  font-size: 1.1rem;
  margin-bottom: 15px;
  border-bottom: 1px solid #ddd;
  padding-bottom: 10px;
}
.apt-info-box ul {
  list-style: none;
  padding: 0;
  margin: 0;
}
.apt-info-box ul li {
  margin-bottom: 10px;
  font-size: 0.95rem;
}
.apt-info-box ul li i {
  color: var(--cf-primary);
  margin-right: 8px;
}

/* Responsive */
@media (max-width: 900px) {
  .apt-detail-layout {
    grid-template-columns: 1fr;
  }
  .apt-gallery {
    grid-template-columns: 1fr;
  }
  .apt-gallery img:first-child {
    height: 200px;
  }
  .apt-gallery img {
    height: 150px;
  }
  .apt-detail-sidebar {
    position: static;
  }
}
/* --- GALLERIA NELLA PAGINA DI DETTAGLIO --- */
.apt-gallery {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
  gap: 15px;
  margin-bottom: 30px;
}

.apt-gallery img {
  width: 100%;
  height: 250px;
  object-fit: cover;
  border-radius: 8px;
  box-shadow: 0 4px 10px rgba(0,0,0,0.08);
  transition: transform 0.3s ease;
  cursor: pointer;
}

.apt-gallery img:hover {
  transform: scale(1.03);
}

/* Opzionale: fai in modo che la PRIMA immagine (la copertina) sia più grande */
.apt-gallery img:first-child {
  grid-column: 1 / -1;
  height: 400px;
}
/* --- 22. PAGINA GALLERIA --- */
.gal-filters {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 10px;
  margin-bottom: 40px;
}
.gal-filters .filter-btn {
  background: #fff;
  border: 1px solid #ddd;
  color: var(--cf-text-main);
  padding: 8px 16px;
  border-radius: 20px;
  font-size: 0.9rem;
  cursor: pointer;
  transition: all 0.3s;
  display: flex;
  align-items: center;
  gap: 6px;
}
.gal-filters .filter-btn.active,
.gal-filters .filter-btn:hover {
  background: var(--cf-primary);
  color: #fff;
  border-color: var(--cf-primary);
}
.gal-count {
  background: rgba(0,0,0,0.05);
  padding: 2px 6px;
  border-radius: 10px;
  font-size: 0.75rem;
  font-weight: bold;
}
.gal-filters .filter-btn.active .gal-count {
  background: rgba(255,255,255,0.2);
  color: #fff;
}

/* Griglia Masonry */
.gal-grid {
  column-count: 3;
  column-gap: 20px;
}
@media (max-width: 992px) {
  .gal-grid { column-count: 2; }
}
@media (max-width: 576px) {
  .gal-grid { column-count: 1; }
}

.gal-grid-item {
  display: block;
  break-inside: avoid;
  margin-bottom: 20px;
  border-radius: 8px;
  overflow: hidden;
  box-shadow: 0 4px 15px rgba(0,0,0,0.08);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}
.gal-grid-item:hover {
  transform: translateY(-5px);
  box-shadow: 0 8px 25px rgba(0,0,0,0.15);
}
.gal-grid-item img {
  width: 100%;
  height: auto;
  display: block;
  transition: transform 0.3s ease;
}
.gal-grid-item:hover img {
  transform: scale(1.03);
}
/* --- 23. PAGINA CONTATTI --- */
.cnt-grid {
  display: grid;
  grid-template-columns: 1fr 1.5fr;
  gap: 40px;
  align-items: start;
}
.cnt-card {
  background: #fff;
  padding: 25px;
  border-radius: 8px;
  box-shadow: 0 4px 15px rgba(0,0,0,0.05);
  margin-bottom: 20px;
  border-left: 4px solid var(--cf-primary);
}
.cnt-card h3 {
  font-size: 1.1rem;
  margin-bottom: 10px;
  color: var(--cf-primary);
}
.cnt-card p {
  margin: 0;
  font-size: 1rem;
}
.cnt-card a {
  color: var(--cf-text-main);
  font-weight: 500;
}
.cnt-card a:hover {
  color: var(--cf-primary);
}

/* Form */
.contact-form-wrap {
  background: #fff;
  padding: 30px;
  border-radius: 8px;
  box-shadow: 0 4px 20px rgba(0,0,0,0.08);
}
.contact-form-wrap h3 {
  margin-top: 0;
  margin-bottom: 25px;
  font-size: 1.5rem;
}
.form-group {
  margin-bottom: 20px;
}
.form-group label {
  display: block;
  margin-bottom: 8px;
  font-weight: 600;
  font-size: 0.9rem;
  color: #555;
}
.form-group input[type="text"],
.form-group input[type="email"],
.form-group input[type="tel"],
.form-group textarea {
  width: 100%;
  padding: 12px 15px;
  border: 1px solid #ddd;
  border-radius: 6px;
  font-family: var(--font-body);
  font-size: 1rem;
  background: #fafafa;
  transition: border-color 0.3s;
}
.form-group input:focus,
.form-group textarea:focus {
  outline: none;
  border-color: var(--cf-primary);
  background: #fff;
}
.form-privacy label {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  font-weight: normal;
  font-size: 0.85rem;
  color: #666;
  cursor: pointer;
}
.form-privacy input {
  margin-top: 3px;
}
.alert {
  padding: 15px;
  border-radius: 6px;
  margin-bottom: 20px;
  font-size: 0.95rem;
}
.alert-success {
  background: #e8f5e9;
  color: #2e7d32;
  border: 1px solid #c8e6c9;
}
.alert-error {
  background: #ffebee;
  color: #c62828;
  border: 1px solid #ffcdd2;
}

/* Dati societari */
.cnt-legal-box {
  background: #f9f6f0;
  padding: 30px;
  border-radius: 8px;
  border: 1px solid #eee;
}
.cnt-legal-box h3 {
  font-size: 1.2rem;
  margin-bottom: 15px;
}
.cnt-legal-list {
  list-style: none;
  padding: 0;
  margin: 0;
  font-size: 0.95rem;
  color: #555;
}
.cnt-legal-list li {
  margin-bottom: 8px;
}

@media (max-width: 900px) {
  .cnt-grid {
    grid-template-columns: 1fr;
  }
}
/* --- 24. PAGINE LEGALI --- */
.legal h2 {
  font-size: 1.3rem;
  margin-top: 40px;
  margin-bottom: 15px;
  color: var(--cf-primary);
}
.legal p, .legal ul, .legal ol {
  font-size: 0.95rem;
  line-height: 1.7;
  color: var(--cf-text-main);
  margin-bottom: 15px;
}
.legal ul, .legal ol {
  padding-left: 20px;
}
.legal li {
  margin-bottom: 8px;
}
.legal-meta {
  margin-bottom: 30px;
  color: var(--cf-text-light);
}
/* --- 25. COOKIE BANNER --- */
.cookie-banner {
  display: none; /* Nascosto di default finché JS non controlla il localStorage */
  position: fixed;
  bottom: 20px;
  left: 20px;
  right: 20px;
  background: #fff;
  padding: 20px;
  border-radius: 8px;
  box-shadow: 0 8px 25px rgba(0,0,0,0.15);
  z-index: 9999;
  border-left: 5px solid var(--cf-primary);
  max-width: 1200px;
  margin: 0 auto;
}
.cookie-content {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 20px;
  flex-wrap: wrap;
}
.cookie-content p {
  margin: 0;
  font-size: 0.9rem;
  color: var(--cf-text-main);
  flex: 1;
  min-width: 250px;
}
.cookie-actions {
  display: flex;
  gap: 15px;
  align-items: center;
}
.cookie-link {
  font-size: 0.9rem;
  text-decoration: underline;
  color: var(--cf-text-light);
}
.cookie-link:hover { color: var(--cf-primary); }

/* Su mobile, i bottoni vanno a capo */
@media (max-width: 768px) {
  .cookie-content { flex-direction: column; align-items: flex-start; }
  .cookie-actions { width: 100%; justify-content: flex-end; }
}
/* --- GESTIONE LOGO NEL MENU --- */
.logo {
  display: flex;
  align-items: center;
  height: 100%;
}

.logo img {
  /* ALTEZZA AUMENTATA: da 65px a 90px */
  height: 90px; 
  width: auto;
  transition: height 0.4s ease;
}

/* Di default (header trasparente): mostra il bianco, nascondi il colorato */
.logo .logo-white { display: block; }
.logo .logo-color { display: none; }

/* Quando l'header diventa bianco (scroll): nascondi il bianco, mostra il colorato */
#main-nav.scrolled .logo .logo-white { display: none; }
#main-nav.scrolled .logo .logo-color { display: block; }

/* Quando si scrolla, rimpicciolisci leggermente il logo per compattare l'header */
#main-nav.scrolled .logo img {
  /* ALTEZZA AUMENTATA: da 50px a 70px */
  height: 70px; 
}

/* Per il mobile, rendiamolo un po' più piccolo per non occupare troppo spazio */
@media (max-width: 900px) {
  .logo img {
    height: 60px;
  }
  #main-nav.scrolled .logo img {
    height: 50px;
  }
}
/* --- 26. PULSANTE WHATSAPP FLOTTANTE --- */
.whatsapp-float {
  position: fixed;
  width: 60px;
  height: 60px;
  bottom: 30px;
  right: 30px;
  background-color: #25d366;
  color: #ffffff !important;
  border-radius: 50px;
  text-align: center;
  font-size: 35px;
  box-shadow: 0 4px 15px rgba(37, 211, 102, 0.4);
  z-index: 1000;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.3s ease;
  animation: whatsapp-pulse 2s infinite;
}

.whatsapp-float:hover {
  background-color: #1ebe57;
  transform: scale(1.1);
  box-shadow: 0 6px 20px rgba(37, 211, 102, 0.6);
  color: #ffffff !important;
}

/* Animazione per attirare l'attenzione */
@keyframes whatsapp-pulse {
  0% {
    box-shadow: 0 0 0 0 rgba(37, 211, 102, 0.7);
  }
  70% {
    box-shadow: 0 0 0 15px rgba(37, 211, 102, 0);
  }
  100% {
    box-shadow: 0 0 0 0 rgba(37, 211, 102, 0);
  }
}

/* Adattamento per Mobile (un po' più piccolo e più vicino al bordo) */
@media (max-width: 768px) {
  .whatsapp-float {
    width: 50px;
    height: 50px;
    font-size: 28px;
    bottom: 20px;
    right: 20px;
  }
}