/* =========================================================
   Edilmarche - Landing Page
   Layer custom sopra Bootstrap 5 (locale)
   ========================================================= */

:root {
  --red: #E2231A;
  --red-dark: #B71C13;
  --ink: #1A1A1A;
  --graphite: #3F3F42;
  --mist: #F6F5F3;
  --line: #E7E5E1;
  scroll-behavior: smooth;
}

html {
  overflow-x: hidden;
}

body {
  font-family: 'Inter', sans-serif;
  color: var(--ink);
  overflow-x: hidden;
  padding-top: 84px; /* spazio per header fixed */
}

/* La CTA sticky mobile è fixed: lascia spazio in fondo per non coprire il footer */
@media (max-width: 1199.98px) {
  body { padding-bottom: 56px; }
}

/* Le ancore non devono finire sotto l'header fixed */
main section[id] { scroll-margin-top: 90px; }

h1, h2, h3, h4, .navbar-brand, .cta-btn, .quick-btn, .badge-pill, .eyebrow {
  font-family: 'Manrope', sans-serif;
}

h3 {
  font-weight: 700;
  font-size: 1.25rem;
}

::selection {
  background: var(--red);
  color: #fff;
}

.bg-mist { background: var(--mist); }
.bg-ink { background: var(--ink); }
.text-graphite { color: var(--graphite); }
#showroom .text-graphite { color: rgba(255, 255, 255, 0.75); }

/* ---------- Skip link ---------- */
.skip-link {
  position: absolute;
  left: -999px;
  top: 0;
  background: var(--red);
  color: #fff;
  padding: 0.75rem 1.25rem;
  z-index: 1100;
  font-weight: 600;
  border-radius: 0 0 8px 0;
}
.skip-link:focus {
  left: 0;
}

/* ---------- Header / Nav ---------- */
.site-header {
  background: rgba(26, 26, 26, 0.92);
  backdrop-filter: blur(6px);
  transition: background 0.3s ease, box-shadow 0.3s ease;
  z-index: 1030;
}
.site-header.is-scrolled {
  background: rgba(255, 255, 255, 0.95);
  box-shadow: 0 1px 24px rgba(0, 0, 0, 0.08);
}

.navbar { padding: 1rem 0; transition: padding 0.3s ease; }
.site-header.is-scrolled .navbar { padding: 0.4rem 0; }

.logo-box {
  background: #fff;
  border-radius: 0.65rem;
  padding: 0.5rem 0.85rem;
  display: inline-flex;
  align-items: center;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.12);
  transition: padding 0.3s ease;
}
.logo-box img { height: 36px; width: auto; display: block; transition: height 0.3s ease; }
.site-header.is-scrolled .logo-box { padding: 0.3rem 0.6rem; box-shadow: none; }
.site-header.is-scrolled .logo-box img { height: 22px; }

/* Schermi molto stretti: logo ridotto, così l'header resta su una riga (84px) */
@media (max-width: 400px) {
  .logo-box { padding: 0.4rem 0.6rem; }
  .logo-box img { height: 28px; }
}

@media (min-width: 1200px) {
  .navbar-collapse {
    flex-grow: 1;
  }
}

.nav-center {
  margin-top: 0;
}
.nav-link {
  position: relative;
  font-weight: 600;
  font-size: 0.92rem;
  padding: 0.5rem 0.9rem !important;
  color: #fff;
  transition: color 0.25s ease;
      text-transform: uppercase;
}

/* Da 1200px la barra è orizzontale: spaziature più strette per farci stare
   menu + telefono + CTA senza mandare i pulsanti fuori schermo. */
@media (min-width: 1200px) and (max-width: 1399.98px) {
  .nav-link { font-size: 0.82rem; padding: 0.5rem 0.55rem !important; }
  .site-header.is-scrolled .nav-link { font-size: 0.78rem; }
  .quick-btn { font-size: 0.78rem; padding: 0.5rem 0.8rem; }
  .nav-actions .cta-btn--sm { padding: 0.55rem 1rem; font-size: 0.78rem; }
  .logo-box img { height: 30px; }
}

/* Menu a tendina (sotto 1200px): voci più comode da toccare */
@media (max-width: 1199.98px) {
  .navbar-collapse { max-height: calc(100vh - 140px); overflow-y: auto; }
  .nav-link { padding: 0.7rem 0 !important; font-size: 1rem; }
  .site-header.is-scrolled .nav-link { font-size: 1rem; }
}

.nav-link:focus, .nav-link:hover {
    color: #868686;
}

.site-header.is-scrolled .nav-link {
  color: var(--ink);
  font-size: 0.85rem;
}
.site-header.is-scrolled .nav-link:hover {
    color: #868686;
}
.nav-link.active {
  color: var(--red) !important;
}
.navbar-toggler {
  border: none;
  box-shadow: none !important;
}
.navbar-toggler-icon {
  filter: invert(1) grayscale(1) brightness(2);
}
.site-header.is-scrolled .navbar-toggler-icon {
  filter: none;
}

.nav-actions { flex-shrink: 0; }

.quick-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  font-size: 0.85rem;
  font-weight: 700;
  padding: 0.55rem 1rem;
  border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, 0.3);
  color: #fff;
  transition: all 0.25s ease;
  white-space: nowrap;
  text-decoration: none;
}
.site-header.is-scrolled .quick-btn {
  border-color: var(--line);
  color: var(--ink);
}
.quick-btn svg { width: 16px; height: 16px; flex-shrink: 0; }
.quick-btn:hover {
  border-color: var(--red);
  color: var(--red) !important;
}

/* ---------- Sticky mobile CTA ---------- */
.mobile-sticky-cta {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  z-index: 1020;
  display: grid;
  grid-template-columns: 1fr;
  background: var(--line);
  border-top: 1px solid var(--line);
  box-shadow: 0 -4px 20px rgba(0, 0, 0, 0.08);
}
.mobile-sticky-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  background: #fff;
  padding: 0.9rem;
  font-family: 'Manrope', sans-serif;
  font-weight: 700;
  font-size: 0.9rem;
  color: var(--ink);
}
.mobile-sticky-btn svg { width: 16px; height: 16px; }

/* ---------- WhatsApp floating button ---------- */
.whatsapp-float {
  position: fixed;
  right: 1.25rem;
  bottom: 1.5rem;
  z-index: 1040;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  height: 56px;
  width: 56px;
  border-radius: 999px;
  background: #25D366;
  color: #fff;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.22);
  overflow: hidden;
  text-decoration: none;
  transition: width 0.3s ease, box-shadow 0.25s ease;
}
.whatsapp-float svg { width: 26px; height: 26px; flex-shrink: 0; }
.whatsapp-float-label {
  white-space: nowrap;
  max-width: 0;
  opacity: 0;
  overflow: hidden;
  margin-left: 0;
  font-weight: 700;
  font-family: 'Manrope', sans-serif;
  font-size: 0.9rem;
  transition: max-width 0.3s ease, opacity 0.25s ease, margin-left 0.3s ease;
}
.whatsapp-float:hover {
  width: auto;
  padding: 0 1.25rem 0 1.1rem;
  justify-content: flex-start;
  box-shadow: 0 10px 28px rgba(0, 0, 0, 0.3);
}
.whatsapp-float:hover .whatsapp-float-label {
  max-width: 120px;
  opacity: 1;
  margin-left: 0.6rem;
}
@media (max-width: 1199.98px) {
  .whatsapp-float { bottom: 5.25rem; }
}

/* ---------- Buttons ---------- */
.cta-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  background: var(--red);
  color: #fff;
  font-weight: 700;
  font-size: 0.95rem;
  padding: 0.9rem 1.75rem;
  border-radius: 999px;
  border: none;
  transition: transform 0.25s ease, background 0.25s ease;
  box-shadow: none;
  text-decoration: none;
}
.cta-btn:hover {
  background: var(--red-dark);
  color: #fff;
  transform: translateY(-2px);
  box-shadow: none;
}
.cta-btn--sm {
  padding: 0.6rem 1.3rem;
  font-size: 0.85rem;
  box-shadow: none;
}
.cta-btn--ghost {
  background: transparent;
  color: #fff;
  border: 1.5px solid rgba(255, 255, 255, 0.6);
  box-shadow: none;
}
.cta-btn--ghost:hover {
  background: rgba(255, 255, 255, 0.12);
  border-color: #fff;
  color: #fff;
  transform: translateY(-2px);
}
.cta-btn--white {
  background: #fff;
  color: var(--ink);
  box-shadow: none;
}
.cta-btn--white:hover {
  background: #E7E5E1;
  color: var(--ink);
  transform: translateY(-2px);
}
.cta-btn--ghost-dark {
  background: transparent;
  color: #fff;
  border: 1.5px solid rgba(255, 255, 255, 0.4);
  box-shadow: none;
}
.cta-btn--ghost-dark:hover {
  border-color: #fff;
  color: #fff;
  transform: translateY(-2px);
}
.cta-btn.cta-btn--ghost-dark:hover {
background: transparent;border: 1.5px solid rgba(255, 255, 255, 0.4);
	cursor: default;
}
.cta-btn.cta-btn--white:hover{
	cursor: default;
}
.link-underline {
  position: relative;
  font-weight: 600;
  color: var(--red);
  padding-bottom: 2px;
  background-image: linear-gradient(var(--red), var(--red));
  background-size: 0% 1.5px;
  background-repeat: no-repeat;
  background-position: left bottom;
  transition: background-size 0.3s ease;
  text-decoration: none;
}
.link-underline:hover {
  background-size: 100% 1.5px;
  color: var(--red);
}

/* ---------- Layout helpers ---------- */
.section-pad {
  padding-top: clamp(4rem, 8vw, 7rem);
  padding-bottom: clamp(4rem, 8vw, 7rem);
}

.eyebrow {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  font-weight: 700;
  font-size: 0.8rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--red);
  margin-bottom: 0;
}
.eyebrow::before {
  content: "";
  width: 28px;
  height: 2px;
  background: var(--red);
  display: inline-block;
}
.text-white-eyebrow { color: rgba(255, 255, 255, 0.9); }
.text-white-eyebrow::before { background: #fff; }

.section-title {
  font-family: 'Manrope', sans-serif;
  font-weight: 800;
  letter-spacing: -0.01em;
  font-size: clamp(1.8rem, 3.2vw, 3rem);
  line-height: 1.15;
  color: var(--ink);
}

.badge-pill {
  display: inline-flex;
  align-items: center;
  font-weight: 700;
  font-size: 0.75rem;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  padding: 0.45rem 0.9rem;
  border-radius: 999px;
  background: rgba(226, 35, 26, 0.08);
  color: var(--red);
  border: 1px solid rgba(226, 35, 26, 0.2);
}
.badge-pill--light {
  background: rgba(255, 255, 255, 0.12);
  color: #fff;
  border-color: rgba(255, 255, 255, 0.25);
}

/* ---------- Hero ---------- */
.hero-section {
  position: relative;
  height: 92vh;
  min-height: 560px;
  overflow: hidden;
  background: var(--ink);
  margin-top: -84px; /* compensa il padding-top del body sotto l'header fixed */
}
/* svh: evita il "salto" quando su mobile compare/scompare la barra del browser */
@supports (height: 100svh) {
  .hero-section { height: 92svh; }
}
/* Viewport bassi (telefono in orizzontale): testo più compatto per non uscire */
@media (max-height: 520px) and (max-width: 991.98px) {
  .hero-section { min-height: 480px; }
  .hero-title { font-size: 1.5rem; }
  .hero-subtitle { display: none; }
  .hero-cta { margin-top: 1.25rem; }
}
.hero-carousel,
.hero-carousel .carousel-inner,
.hero-carousel .carousel-item,
.kenburns-wrap {
  position: absolute;
  inset: 0;
  height: 100%;
  width: 100%;
}
.kenburns-wrap { overflow: hidden; }
.kenburns-wrap img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  animation: kenburns 18s ease-in-out infinite alternate;
}
.carousel-item:nth-child(2) .kenburns-wrap img { animation-delay: -6s; }
.carousel-item:nth-child(3) .kenburns-wrap img { animation-delay: -12s; }

@keyframes kenburns {
  0% { transform: scale(1) translate(0, 0); }
  100% { transform: scale(1.15) translate(-1.5%, -1.5%); }
}

.hero-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(to top, rgba(0,0,0,0.82) 0%, rgba(0,0,0,0.45) 45%, rgba(0,0,0,0.25) 100%);
  z-index: 1;
}

.hero-content {
  position: absolute;
  inset: 0;
  z-index: 2;
  display: flex;
  align-items: flex-end;
  padding-bottom: clamp(2.5rem, 6vw, 5rem);
  border-bottom: 18px solid var(--red);
}
.hero-text { max-width: 640px; 
  margin-left: clamp(0.5rem, 8vw, 4rem);
  margin-right: clamp(0.5rem, 8vw, 4rem);
 }
.hero-title {
  font-family: 'Manrope', sans-serif;
  font-weight: 800;
  color: #fff;
  font-size: clamp(1.7rem, 5vw, 3.2rem);
  line-height: 1.08;
  letter-spacing: -0.01em;
  margin-top: 1rem;
}
.hero-subtitle {
  color: rgba(255, 255, 255, 0.9);
  font-size: clamp(0.8rem, 1.3vw, 1.0rem);
  line-height: 1.6;
  margin-top: 1.25rem;
  max-width: 34rem;
}
.hero-cta { margin-top: 2.25rem; }

.hero-carousel .carousel-control-prev,
.hero-carousel .carousel-control-next {
  z-index: 3;
  width: 3.5rem;
  opacity: 1;
}
.hero-arrow {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 46px;
  height: 46px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.12);
  border: 1px solid rgba(255, 255, 255, 0.35);
  color: #fff;
  font-size: 1.6rem;
  line-height: 1;
  transition: background 0.25s ease;
}
.hero-carousel .carousel-control-prev:hover .hero-arrow,
.hero-carousel .carousel-control-next:hover .hero-arrow {
  background: rgba(255, 255, 255, 0.25);
}

/* ---------- Chi Siamo ---------- */
.chi-siamo-watermark {
  position: absolute;
  top: -3.5rem;
  left: -1rem;
  font-family: 'Manrope', sans-serif;
  font-weight: 800;
  font-size: clamp(8rem, 16vw, 13rem);
  line-height: 1;
  color: var(--mist);
  z-index: 0;
  user-select: none;
  pointer-events: none;
}
@media (max-width: 575.98px) {
  /* Su mobile il "68" usciva dal viewport: lo riporto dentro la colonna */
  .chi-siamo-watermark { left: 0; top: -2.5rem; font-size: 7rem; }
}
.chi-siamo-figure {
  position: relative;
}
.chi-siamo-figure img {
  width: 100%;
  aspect-ratio: 4 / 5;
  object-fit: cover;
  border-radius: 1.25rem;
}
.about-carousel {
  border-radius: 1.25rem;
  overflow: hidden;
}
.about-carousel .carousel-inner,
.about-carousel .carousel-item {
  aspect-ratio: 4 / 5;
}
.about-carousel .carousel-item img {
  width: 100%;
  height: 100%;
  aspect-ratio: auto;
  object-fit: cover;
  border-radius: 0;
}
.about-carousel .carousel-indicators {
  margin-bottom: 0.75rem;
  z-index: 3;
}
.about-carousel .carousel-indicators [data-bs-target] {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  border: none;
  background-color: rgba(255, 255, 255, 0.55);
  opacity: 1;
  /* area di tocco più ampia del pallino visibile */
  box-sizing: content-box;
  border-top: 14px solid transparent;
  border-bottom: 14px solid transparent;
  background-clip: content-box;
  margin-left: 8px;
  margin-right: 8px;
}
.about-carousel .carousel-indicators .active {
  background-color: #fff;
}
.chi-siamo-timeline {
  gap: 2rem;
}
.chi-siamo-timeline li {
  position: relative;
  padding-left: 1.4rem;
  min-width: 140px;
  border-left: 2px solid var(--line);
}
.chi-siamo-timeline .dot {
  position: absolute;
  left: -6px;
  top: 0.2rem;
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: var(--red);
}
.chi-siamo-timeline strong {
  display: block;
  font-family: 'Manrope', sans-serif;
  font-weight: 800;
  color: var(--ink);
}
.chi-siamo-timeline small {
  display: block;
  color: var(--graphite);
  margin-top: 0.2rem;
  font-size: 0.82rem;
  line-height: 1.4;
}

/* ---------- Service cards ---------- */
.service-card {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 1.25rem;
  padding: 2.25rem;
  display: flex;
  flex-direction: column;
  transition: transform 0.35s ease, box-shadow 0.35s ease, border-color 0.35s ease;
}
.service-card .link-underline {
  margin-top: auto;
  padding-top: 1rem;
}
.service-card:hover {
  transform: translateY(-6px);
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.08);
  border-color: transparent;
}
.service-icon {
  width: 64px;
  height: 64px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 1rem;
  background: rgba(226, 35, 26, 0.08);
  color: var(--red);
  transition: background 0.35s ease, color 0.35s ease, transform 0.35s ease;
}
.service-icon svg { width: 30px; height: 30px; }
.service-card:hover .service-icon {
  background: var(--red);
  color: #fff;
  transform: scale(1.05) rotate(-4deg);
}

/* ---------- Showroom tiles ---------- */
.showroom-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  grid-auto-rows: 220px;
  gap: 1.25rem;
}
.tile--big { grid-column: span 2; grid-row: span 2; }
@media (max-width: 991px) {
  .showroom-grid { grid-template-columns: repeat(2, 1fr); }
  .tile--big { grid-column: span 2; grid-row: span 1; aspect-ratio: 16/9; height: auto; }
}
@media (max-width: 575px) {
  .showroom-grid { grid-template-columns: 1fr; }
  .tile--big { grid-column: span 1; }
}

.tile {
  position: relative;
  display: block;
  overflow: hidden;
  border-radius: 1.25rem;
  isolation: isolate;
  text-decoration: none;
}
.tile img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.6s ease;
}
.tile:hover img { transform: scale(1.07); }
.tile-overlay {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  padding: 1.5rem;
  background: linear-gradient(to top, rgba(0,0,0,0.85) 0%, rgba(0,0,0,0.15) 55%, rgba(0,0,0,0) 100%);
}
.tile-title {
  font-family: 'Manrope', sans-serif;
  font-weight: 700;
  font-size: 1.1rem;
  color: #fff;
}
.tile-desc {
  margin-top: 0.5rem;
  font-size: 0.85rem;
  line-height: 1.5;
  color: rgba(255, 255, 255, 0.82);
  max-height: 0;
  opacity: 0;
  overflow: hidden;
  transition: max-height 0.4s ease, opacity 0.4s ease;
}
.tile:hover .tile-desc,
.tile:focus-within .tile-desc {
  max-height: 140px;
  opacity: 1;
}
/* Su touch non esiste l'hover: le descrizioni sarebbero sempre invisibili */
@media (hover: none) {
  .tile-desc { max-height: 200px; opacity: 1; }
  .tile-overlay { background: linear-gradient(to top, rgba(0,0,0,0.9) 0%, rgba(0,0,0,0.35) 65%, rgba(0,0,0,0.05) 100%); }
}

/* ---------- Brand grid ---------- */
.brand-grid {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(190px, 1fr));
  gap: 1rem;
}
@media (max-width: 767px) {
  .brand-grid { grid-template-columns: repeat(2, 1fr); gap: 0.75rem; }
  .cta-btn {
        font-size: 0.75rem;}
}
.brand-tile {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 110px;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 0.9rem;
  padding: 1.25rem;
  transition: transform 0.35s ease, box-shadow 0.35s ease;
}
.brand-tile img {
  /* solo vincoli massimi: il rapporto d'aspetto dei loghi va preservato */
  max-width: min(140px, 100%);
  max-height: 48px;
  width: auto;
  height: auto;
  object-fit: contain;
  filter: grayscale(1);
  opacity: 0.55;
  transition: filter 0.35s ease, opacity 0.35s ease;
}
/* Loghi a sviluppo verticale/quadrato: serve più altezza, non più larghezza */
.brand-tile--square img {
  max-width: min(90px, 100%);
  max-height: 76px;
}
.brand-tile:hover {
  transform: translateY(-3px);
  box-shadow: 0 12px 24px rgba(0, 0, 0, 0.06);
}
.brand-tile:hover img {
  filter: grayscale(0);
  opacity: 1;
}
/* Su touch l'hover non arriva mai: i loghi resterebbero sempre slavati */
@media (hover: none) {
  .brand-tile img { filter: none; opacity: 1; }
}

/* ---------- Pagina interna: intestazione ---------- */
.page-hero {
  position: relative;
  background: var(--ink);
  color: #fff;
  padding: clamp(3rem, 7vw, 5.5rem) 0 clamp(3rem, 7vw, 5rem);
  border-bottom: 10px solid var(--red);
  overflow: hidden;
}
.page-hero::after {
  content: "";
  position: absolute;
  inset: 0;
  background: radial-gradient(circle at 85% 20%, rgba(226, 35, 26, 0.18), transparent 55%);
  pointer-events: none;
}
.page-hero > .container-xl { position: relative; z-index: 1; }
.page-hero .section-title { color: #fff; }
.page-hero p { color: rgba(255, 255, 255, 0.78); }

.breadcrumb-nav {
  font-size: 0.82rem;
  color: rgba(255, 255, 255, 0.6);
  margin-bottom: 1.25rem;
}
.breadcrumb-nav a { color: rgba(255, 255, 255, 0.85); text-decoration: none; }
.breadcrumb-nav a:hover { color: #fff; text-decoration: underline; }
.breadcrumb-nav span { margin: 0 0.4rem; }

/* ---------- Schede marchio (pagina marchi) ---------- */
.brand-cards {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
  gap: 1.25rem;
}
@media (max-width: 575.98px) {
  .brand-cards { grid-template-columns: 1fr; }
}
.brand-card {
  display: flex;
  flex-direction: column;
  height: 100%;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 1.1rem;
  padding: 1.5rem;
  text-decoration: none;
  color: inherit;
  transition: transform 0.35s ease, box-shadow 0.35s ease, border-color 0.35s ease;
}
.brand-card:hover,
.brand-card:focus-visible {
  transform: translateY(-5px);
  box-shadow: 0 18px 36px rgba(0, 0, 0, 0.09);
  border-color: transparent;
  color: inherit;
}
.brand-card-logo {
  display: flex;
  align-items: center;
  justify-content: center;
  height: 88px;
  margin-bottom: 1.25rem;
  border-bottom: 1px solid var(--line);
  padding-bottom: 1.25rem;
}
.brand-card-logo img {
  max-width: 155px;
  max-height: 54px;
  width: auto;
  height: auto;
  object-fit: contain;
}
.brand-card--square .brand-card-logo img { max-height: 84px; max-width: 110px; }
/* Scheda senza sito ufficiale: niente effetto "cliccabile" */
.brand-card--static:hover { transform: none; box-shadow: none; border-color: var(--line); }
.brand-card h3 {
  font-size: 1.05rem;
  margin: 0;
}
.brand-card p {
  margin: 0.5rem 0 0;
  font-size: 0.88rem;
  line-height: 1.55;
  color: var(--graphite);
}
.brand-card-link {
  margin-top: auto;
  padding-top: 1.1rem;
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  font-family: 'Manrope', sans-serif;
  font-weight: 700;
  font-size: 0.82rem;
  color: var(--red);
}
.brand-card-link svg { width: 14px; height: 14px; transition: transform 0.25s ease; }
.brand-card:hover .brand-card-link svg { transform: translate(2px, -2px); }

/* ---------- Novità box ---------- */
.novita-box {
  border-radius: 1.5rem;
  overflow: hidden;
  background: linear-gradient(135deg, #2A2A2A, #1A1A1A);
  padding: 2.5rem;
}
@media (min-width: 768px) {
  .novita-box { padding: 3.5rem; }
}
.novita-copy {
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
}
@media (min-width: 768px) {
  .novita-copy {
    flex-direction: row;
    align-items: center;
    justify-content: space-between;
    gap: 2.5rem;
  }
}
.novita-copy-text {
  max-width: 34rem;
}
.novita-copy-actions {
  flex-shrink: 0;
}
.novita-brand {
  font-family: 'Manrope', sans-serif;
  font-weight: 800;
  font-size: clamp(1.8rem, 3vw, 2.5rem);
  color: #fff;
  letter-spacing: -0.01em;
  margin-top: 1.5rem;
  margin-bottom: 0;
}
.novita-text {
  color: rgba(255, 255, 255, 0.8);
  font-size: 1.05rem;
  line-height: 1.6;
  margin-top: 1rem;
  max-width: 32rem;
}

.novita-mosaic {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 0.6rem;
  margin-top: 2.5rem;
}
@media (min-width: 576px) {
  .novita-mosaic { grid-template-columns: repeat(3, 1fr); gap: 0.75rem; }
}
@media (min-width: 992px) {
  .novita-mosaic { grid-template-columns: repeat(5, 1fr); }
}
.novita-mosaic-item.gallery-item {
  display: block;
  width: 100%;
  aspect-ratio: 4 / 3;
  height: auto;
  border-radius: 0.7rem;
}
.novita-mosaic-item.gallery-item img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

/* ---------- Gallery / Lightbox ---------- */
.gallery-filters {
  display: flex;
  flex-wrap: wrap;
  gap: 0.6rem;
}
/* Su mobile i filtri occupavano 5 righe: diventano una barra scorrevole */
@media (max-width: 767.98px) {
  .gallery-filters {
    flex-wrap: nowrap;
    overflow-x: auto;
    scroll-snap-type: x proximity;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
    padding-bottom: 0.25rem;
    /* bleed fino al bordo: deve combaciare col padding del .container-xl (12px)
       altrimenti si crea scroll orizzontale sulla pagina */
    margin-inline: -12px;
    padding-inline: 12px;
  }
  .gallery-filters::-webkit-scrollbar { display: none; }
  .filter-btn { flex: 0 0 auto; scroll-snap-align: start; }
}
.filter-btn {
  font-family: 'Manrope', sans-serif;
  font-weight: 700;
  font-size: 0.85rem;
  padding: 0.55rem 1.1rem;
  border-radius: 999px;
  border: 1px solid var(--line);
  background: #fff;
  color: var(--graphite);
  transition: all 0.25s ease;
}
.filter-btn:hover {
  border-color: var(--red);
  color: var(--red);
}
.filter-btn.active {
  background: var(--red);
  border-color: var(--red);
  color: #fff;
}
.gallery-col.is-hidden {
  display: none;
}

.gallery-item {
  position: relative;
  display: block;
  width: 100%;
  aspect-ratio: 4 / 3;
  overflow: hidden;
  border-radius: 1rem;
  cursor: zoom-in;
  border: none;
  padding: 0;
  background: none;
}
.gallery-item img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.5s ease;
}
.gallery-item:hover img { transform: scale(1.08); }
.gallery-item::after {
  content: "";
  position: absolute;
  inset: 0;
  background: rgba(0,0,0,0);
  transition: background 0.3s ease;
}
.gallery-item:hover::after { background: rgba(0,0,0,0.15); }

.lightbox-modal .modal-content {
  background: rgba(10, 10, 10, 0.97);
  border: none;
  border-radius: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 100vh;
}
.lightbox-body {
  display: flex;
  flex-direction: column;
  align-items: center;
  max-width: 90vw;
}
.lightbox-body img {
  max-width: min(90vw, 1100px);
  max-height: 78vh;
  object-fit: contain;
  border-radius: 0.5rem;
}
.lightbox-caption {
  color: rgba(255, 255, 255, 0.8);
  margin-top: 1rem;
  font-size: 0.9rem;
  max-width: 600px;
  text-align: center;
}
.lightbox-close {
  position: absolute;
  top: 1.5rem;
  right: 1.5rem;
  z-index: 5;
  filter: invert(1) grayscale(1) brightness(2);
  opacity: 0.9;
}
.lightbox-nav {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  z-index: 5;
  background: rgba(255,255,255,0.08);
  color: #fff;
  border: 1px solid rgba(255,255,255,0.2);
  border-radius: 999px;
  width: 46px;
  height: 46px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.5rem;
  line-height: 1;
  cursor: pointer;
  transition: background 0.25s ease;
}
.lightbox-nav:hover { background: rgba(255,255,255,0.2); }
.lightbox-prev { left: 1rem; }
.lightbox-next { right: 1rem; }
@media (min-width: 768px) {
  .lightbox-prev { left: 2rem; }
  .lightbox-next { right: 2rem; }
}

/* ---------- Form ---------- */
.form-label {
  font-family: 'Manrope', sans-serif;
  font-weight: 600;
  font-size: 0.85rem;
}
.form-control {
  border: 1px solid var(--line);
  border-radius: 0.7rem;
  padding: 0.75rem 1rem;
  background: var(--mist);
}
.form-control:focus {
  border-color: var(--red);
  background: #fff;
  /* niente alone sfumato: contorno netto, resta leggibile chi naviga da tastiera */
  box-shadow: none;
  outline: 2px solid var(--red);
  outline-offset: 1px;
}
.form-check-input {
  margin-top: 0.25rem;
  accent-color: var(--red);
}
.form-check-input:focus {
  border-color: var(--red);
  box-shadow: none;
  outline: 2px solid var(--red);
  outline-offset: 1px;
}
.form-check-label {
  font-size: 0.85rem;
  color: var(--graphite);
}
.form-check-label a.privacy {
  color: var(--red);
  font-weight: 600;
}
.form-check-label a.privacy:hover {
  color: var(--red-dark);
}
.invalid-feedback {
  font-size: 0.78rem;
}

/* il widget reCAPTCHA è largo 304px fissi: lo riduciamo sugli schermi stretti */
@media (max-width: 400px) {
  .g-recaptcha { transform: scale(0.85); transform-origin: 0 0; height: 66px; }
}

.contact-form {
  background: #fff;
  border-radius: 1.25rem;
  padding: 2rem;
  box-shadow: 0 2px 30px rgba(0, 0, 0, 0.06);
}
@media (min-width: 768px) { .contact-form { padding: 2.5rem; } }

.contact-card {
  background: #fff;
  border-radius: 1.25rem;
  padding: 2rem;
  box-shadow: 0 2px 30px rgba(0, 0, 0, 0.06);
}
@media (min-width: 768px) { .contact-card { padding: 2.5rem; } }
.contact-card h3 { margin-bottom: 0; }
.contact-list {
  list-style: none;
  padding: 0;
  margin: 1.5rem 0 0;
  display: flex;
  flex-direction: column;
  gap: 1rem;
  color: var(--graphite);
}
.contact-list li {
  display: flex;
  align-items: flex-start;
  gap: 0.75rem;
}
.contact-list svg {
  width: 20px;
  height: 20px;
  flex-shrink: 0;
  margin-top: 0.15rem;
  color: var(--red);
}
.contact-list a {
  color: var(--graphite);
  text-decoration: none;
}
.contact-list a:hover { color: var(--red); }

.map-frame {
  border-radius: 1.25rem;
  overflow: hidden;
  aspect-ratio: 16/9;
}
.map-frame iframe {
  width: 100%;
  height: 100%;
  border: 0;
}

/* ---------- Footer ---------- */
.site-footer {
  background: var(--ink);
  color: rgba(255, 255, 255, 0.55);
  padding: 2rem 0;
  font-size: 0.8rem;
  line-height: 1.6;

  a{
    color: #fff;
  }
}
.site-footer .credits {
  margin-top: 0.75rem;
  font-size: 0.75rem;
}

/* ---------- Effetti in ingresso (WOW.js + animate.css) ---------- */
@media (prefers-reduced-motion: reduce) {
  .wow { visibility: visible; }
  .animate__animated { animation: none !important; }
  .kenburns-wrap img { animation: none; }
  * { scroll-behavior: auto !important; }
}


.credits_link{
 color: #38B5E6 !important;
 font-weight: 700;
 font-family: sans-serif;
}

.credits_link:hover{
 color: #fff !important;
}

 .credits_link:before{
  content: "";
  vertical-align: middle;
  width:16px;
  height: 16px;
  display: inline-block;
  margin-right: 5px;
  margin-left: 5px;
  background-image: url(https://www.clion.it/favicon-96x96.png);
  background-repeat: no-repeat;
  -webkit-background-size: contain;
  background-size: contain;
  background-position: center center;

  transition: all 450ms ease;
 }

  .credits_link:hover:before{
   transform: rotateZ(360deg) rotateY(360deg);
  }