*,
*::before,
*::after {
  box-sizing: border-box;
}

a {
  color: inherit;
  text-decoration: none;
}

button,
input {
  font: inherit;
}

.skip-link {
  position: absolute;
  left: -999px;
}

.skip-link:focus {
  left: 12px;
  top: 12px;
  z-index: 40;
  background: #111;
  color: #fff;
  padding: 8px 12px;
}

/* Header */
.site-header {
  position: sticky;
  top: 0;
  z-index: 30;
  background: #fff;
}

.header-inner {
  display: flex;
  align-items: center;
  min-height: var(--header-h);
  gap: 12px;
}

.logo {
  flex: 0 0 26%;
  display: flex;
  align-items: center;
}

.logo img {
  display: block;
  width: 60%;
  max-width: 278px;
  height: auto;
}

.nav-wrap {
  flex: 1 1 65%;
  display: flex;
  justify-content: flex-end;
  align-items: center;
}

.nav-desktop {
  display: flex;
  align-items: center;
  gap: 0;
  list-style: none;
  margin: 0;
  padding: 0;
}

.nav-desktop > li {
  position: relative;
}

.nav-desktop a {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: #3a3a3a;
  font-size: 17px;
  font-weight: 600;
  padding: 16px 10px;
  position: relative;
}

.nav-desktop a::after {
  content: "";
  position: absolute;
  left: 10px;
  right: 10px;
  bottom: 10px;
  height: 2px;
  background: var(--orange);
  transform: scaleX(0);
  transition: transform 0.2s ease;
}

.nav-desktop a:hover,
.nav-desktop a[aria-current="page"],
.nav-desktop a.is-active {
  color: #000;
}

.nav-desktop a:hover::after,
.nav-desktop a[aria-current="page"]::after,
.nav-desktop a.is-active::after {
  transform: scaleX(1);
}

.nav-desktop .sub-arrow {
  width: 10px;
  height: 10px;
  display: inline-block;
}

.nav-desktop .sub-menu {
  display: none;
  position: absolute;
  top: 100%;
  left: 0;
  min-width: 180px;
  margin: 0;
  padding: 8px 0;
  list-style: none;
  background: #fff;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.12);
  z-index: 5;
}

.nav-desktop > li:hover > .sub-menu,
.nav-desktop > li:focus-within > .sub-menu {
  display: block;
}

.nav-desktop .sub-menu a {
  display: block;
  padding: 8px 16px;
  font-size: 15px;
  font-weight: 500;
}

.nav-desktop .sub-menu a::after {
  display: none;
}

.nav-toggle {
  display: none;
  background: #f3f3f3;
  border: 0;
  width: 44px;
  height: 40px;
  margin: 0 auto;
  color: #333;
  cursor: pointer;
}

.mobile-panel {
  background: #fff;
  border-top: 1px solid #eee;
}

.mobile-panel ul {
  list-style: none;
  margin: 0;
  padding: 8px 20px 20px;
}

.mobile-panel a {
  display: block;
  padding: 10px 0;
  font-weight: 600;
  color: #3a3a3a;
}

.mobile-panel .sub-menu {
  padding-left: 16px;
}

/* Slider */
.hero-slider {
  position: relative;
  height: 500px;
  overflow: hidden;
  background: #000;
}

.hero-track {
  display: flex;
  height: 100%;
  transition: transform 0.5s ease;
}

.hero-slide {
  position: relative;
  min-width: 100%;
  height: 100%;
}

.hero-slide .slide-bg {
  position: absolute;
  inset: 0;
  background-size: cover;
  background-position: center;
  transform: scale(1);
}

.hero-slide.is-active .slide-bg {
  animation: kenburns 12s ease-out forwards;
}

.hero-slide .slide-overlay {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.5);
}

.hero-slide a {
  position: relative;
  z-index: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  height: 100%;
  text-align: center;
  padding: 0 80px;
}

.slide-copy {
  max-width: 79%;
}

.slide-copy h2 {
  margin: 0 0 28px;
  color: #fff;
  font-family: var(--font);
  font-weight: 600;
  font-size: clamp(26px, 2.6vw, 40px);
  line-height: 1.25;
}

.btn-slide {
  display: inline-block;
  background: var(--orange);
  color: #000;
  font-size: 18px;
  font-weight: 600;
  text-transform: uppercase;
  padding: 12px 22px;
}

.hero-nav {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  z-index: 2;
  width: 44px;
  height: 44px;
  border: 0;
  background: transparent;
  color: #fff;
  cursor: pointer;
  padding: 0;
}

.hero-nav svg {
  width: 22px;
  height: 22px;
  fill: currentColor;
}

.hero-nav.prev {
  left: 18px;
}

.hero-nav.next {
  right: 18px;
}

.hero-dots {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 18px;
  display: flex;
  justify-content: center;
  gap: 8px;
  z-index: 2;
}

.hero-dots button {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  border: 0;
  background: rgba(255, 255, 255, 0.55);
  padding: 0;
  cursor: pointer;
}

.hero-dots button.is-active {
  background: #fff;
}

@keyframes kenburns {
  from {
    transform: scale(1);
  }
  to {
    transform: scale(1.18);
  }
}

/* Intro */
.intro {
  background: var(--bg-soft);
}

.intro-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0;
  align-items: start;
  padding: 0;
}

.intro-copy {
  padding: 2em;
}

.intro-copy h1,
.intro-copy h2,
.intro-copy h4 {
  color: var(--orange);
  font-weight: 600;
  margin: 0 0 12px;
}

.intro-copy h1 {
  font-size: 36px;
  line-height: 1.2;
}

.intro-copy h2 {
  font-size: 24px;
  margin-top: 20px;
}

.intro-copy h4 {
  font-size: 16px;
  margin: 10px 0 4px;
}

.intro-copy p {
  margin: 0 0 14px;
  color: #6b6b6b;
}

.btn-more {
  display: inline-flex;
  flex-direction: row-reverse;
  align-items: center;
  gap: 26px;
  margin-top: 12px;
  padding: 10px 18px;
  background: #fff;
  color: var(--orange);
  border: 1px solid #f1f1f1;
  font-size: 0.9em;
  font-weight: 600;
  text-transform: uppercase;
  animation: floaty 2.4s ease-in-out infinite;
}

.btn-more svg {
  width: 14px;
  height: 14px;
  fill: currentColor;
}

.btn-more:hover {
  background: var(--orange);
  color: #fff;
  border-color: var(--orange);
}

@keyframes floaty {
  0%,
  100% {
    transform: translateY(0);
  }
  50% {
    transform: translateY(-8px);
  }
}

.intro-media {
  padding: 2em 2em 2em 0;
}

.intro-media img,
.intro-media a {
  display: block;
  width: 100%;
}

.intro-thumbs {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
  margin-top: 10px;
}

.intro-thumbs a {
  display: block;
  aspect-ratio: 3 / 2;
  overflow: hidden;
  position: relative;
}

.intro-thumbs img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.8s ease;
}

.intro-thumbs a:hover img,
.gallery a:hover img {
  transform: scale(1.06);
}

.intro-thumbs a::after,
.gallery a::after {
  content: "";
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0);
  transition: background 0.8s ease;
}

.intro-thumbs a:hover::after,
.gallery a:hover::after {
  background: rgba(0, 0, 0, 0.5);
}

/* Services strip */
.svc-wrap {
  background: linear-gradient(180deg, #000 0%, #616161 100%);
  padding: 6em 4em;
}

.svc-wrap h2 {
  margin: 0 0 28px;
  text-align: center;
  color: var(--orange);
  font-size: 22px;
  font-weight: 600;
}

.svc-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 20px;
}

.svc-grid.cols-3 {
  grid-template-columns: repeat(3, 1fr);
}

.svc-grid.cols-3 .svc-card {
  min-height: 420px;
}

.svc-card {
  position: relative;
  min-height: 500px;
  display: flex;
  align-items: flex-end;
  padding: 1em;
  background-size: cover;
  background-position: center;
  border-bottom: 3px solid var(--orange);
  overflow: hidden;
}

.svc-card::before {
  content: "";
  position: absolute;
  inset: 0;
  background: #ff6a0052;
  opacity: 0.49;
  transition: background 1.2s, opacity 1.2s;
}

.svc-card:hover::before {
  background: #0e0e0e;
  opacity: 0.3;
}

.svc-card-inner {
  position: relative;
  z-index: 1;
  width: 100%;
}

.svc-card h3 {
  display: inline-block;
  margin: 0 0 8px;
  max-width: 100%;
  background: #464646;
  color: #fff;
  font-size: 1em;
  font-weight: 500;
  text-transform: uppercase;
  padding: 15px;
  border-left: 3px solid var(--orange);
  line-height: 1.35;
}

.svc-card .svc-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 5px;
  width: 100%;
  background: var(--green);
  color: #fff;
  font-size: 0.9em;
  font-weight: 600;
  text-transform: uppercase;
  padding: 10px 8px;
  line-height: 1.5;
  animation: floaty 2.4s ease-in-out infinite;
}

.svc-card .svc-btn svg {
  width: 14px;
  height: 14px;
  fill: currentColor;
}

.svc-card:hover .svc-btn {
  background: var(--orange);
}

/* CTA palfinger */
.cta-palfinger {
  position: relative;
  background: #7f807f;
  padding: 4%;
  overflow: hidden;
}

.cta-palfinger::before {
  content: "";
  position: absolute;
  inset: 0;
  background: #424242 url("/assets/img/cta-bg.webp") center / cover no-repeat;
  opacity: 0.37;
  filter: saturate(0) blur(4.4px);
}

.cta-palfinger-inner {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: 48.5% 51.5%;
  min-height: 388px;
  align-items: center;
}

.cta-photo {
  min-height: 445px;
  background: url("/assets/img/cta-aperto.webp") center right / cover no-repeat;
}

.cta-copy {
  padding: 3em;
  text-align: center;
  color: #fff;
}

.cta-copy h2 {
  margin: 0 0 10px;
  font-size: 26px;
  font-weight: 600;
  color: #fff;
}

.cta-copy h3 {
  margin: 0 0 22px;
  font-size: 20px;
  font-weight: 600;
  color: #fff;
}

.cta-copy img {
  display: block;
  margin: 0 auto 24px;
  max-width: 280px;
  background: #fff;
  padding: 12px 18px;
}

.btn-wa {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: #f7c600;
  color: #111;
  font-size: 19px;
  font-weight: 500;
  padding: 10px 18px;
}

.btn-wa svg {
  width: 16px;
  height: 16px;
  fill: currentColor;
}

/* Flip boxes */
.flip-section {
  padding: 4% 0;
}

.flip-grid {
  display: grid;
  grid-template-columns: 1fr 1fr 1fr;
  gap: 20px;
}

.flip {
  perspective: 1000px;
  min-height: 280px;
}

.flip-inner {
  position: relative;
  height: 280px;
  transform-style: preserve-3d;
  transition: transform 0.7s ease;
}

.flip:hover .flip-inner,
.flip:focus-within .flip-inner {
  transform: rotateX(180deg);
}

.flip-face {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 24px;
  backface-visibility: hidden;
  -webkit-backface-visibility: hidden;
}

.flip-front.dark {
  background: #333;
}

.flip-front.mid {
  background: #5f5f5f;
}

.flip-front.orange {
  background: var(--orange);
}

.flip-back {
  background: var(--orange);
  transform: rotateX(180deg);
}

.flip-back.dark {
  background: #333;
}

.flip-face svg {
  width: 42px;
  height: 42px;
  fill: #fff;
  margin-bottom: 16px;
}

.flip-face h3 {
  margin: 0 0 8px;
  font-size: 20px;
  font-weight: 600;
}

.flip-front.dark h3,
.flip-front.mid h3 {
  color: var(--orange);
}

.flip-front.orange h3 {
  color: #000;
}

.flip-face p {
  margin: 0;
  color: #fff;
  font-size: 15px;
}

.flip-front.orange p {
  color: #fff;
}

.flip-btn {
  display: inline-block;
  margin-top: 16px;
  padding: 8px 16px;
  border: 2px solid #fff;
  color: #fff;
  font-weight: 500;
}

/* Page title */
.page-title {
  background: var(--bg-title);
}

.page-title .container {
  padding: 14px 0;
}

.page-title h1 {
  margin: 0;
  font-size: 18px;
  font-weight: 600;
  color: #2e2e2e;
}

.page-body {
  padding: 50px 0;
}

/* Contact */
.contact-head {
  text-align: center;
  color: var(--orange);
  font-size: 18px;
  font-weight: 600;
  text-transform: uppercase;
  margin: 0 0 28px;
}

.contact-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
  max-width: 980px;
  margin: 0 auto 48px;
}

.contact-card {
  background: #f3f3f3;
  text-align: center;
  padding: 36px 16px;
  min-height: 210px;
}

.contact-card svg {
  width: 28px;
  height: 28px;
  fill: var(--orange);
}

.contact-card h2 {
  margin: 16px 0 8px;
  color: var(--orange);
  font-size: 16px;
  font-weight: 600;
  text-transform: uppercase;
}

.contact-card h2::after {
  content: "";
  display: block;
  width: 36px;
  height: 2px;
  background: #cfcfcf;
  margin: 8px auto 0;
}

.contact-card p,
.contact-card a {
  color: #333;
  font-weight: 500;
}

/* About */
.about-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 24px;
  align-items: center;
  background: var(--bg-soft);
}

.about-copy {
  padding: 2em;
}

.about-copy h2 {
  margin: 0 0 8px;
  font-family: var(--font-serif);
  font-size: 3em;
  font-weight: 700;
  color: var(--orange);
  text-transform: capitalize;
}

.about-copy p {
  margin: 0 0 14px;
}

.about-photo {
  padding-right: 2em;
}

.about-gallery {
  background: var(--bg-soft);
  padding: 0 2em 2em;
}

.gallery {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 10px;
}

.gallery a {
  position: relative;
  display: block;
  overflow: hidden;
  aspect-ratio: 3 / 2;
}

.gallery img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.8s ease;
}

.gallery.gallery-15 {
  grid-template-columns: repeat(4, 1fr);
}

.split-text {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 40px;
  align-items: center;
}

.split-text img {
  width: 100%;
  max-width: 420px;
  margin-left: auto;
  display: block;
}

.unit-copy p {
  margin: 0 0 14px;
}

.map-embed {
  margin: 24px 0;
  min-height: 380px;
}

.map-embed iframe {
  width: 100%;
  height: 380px;
  border: 0;
}

/* Footer */
.site-footer {
  background: var(--bg-footer);
}

.footer-grid {
  display: grid;
  grid-template-columns: 19.214% 29.26% 24.857% 25%;
  gap: 20px;
  padding: 70px 50px;
  align-items: start;
}

.footer-logo img {
  max-width: 150px;
  display: block;
}

.footer-col h3 {
  margin: 0 0 12px;
  color: var(--orange);
  font-size: 20px;
  font-weight: 600;
}

.footer-list {
  list-style: none;
  margin: 0;
  padding: 0;
}

.footer-list li {
  display: flex;
  gap: 10px;
  align-items: flex-start;
  margin-bottom: 8px;
  font-size: 14px;
  font-weight: 500;
  color: var(--text);
}

.footer-list svg {
  width: 21px;
  height: 21px;
  fill: var(--orange);
  flex: 0 0 21px;
  margin-top: 2px;
}

.footer-sos {
  background: var(--orange);
  color: #fff;
  padding: 15px;
  font-size: 14px;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  text-align: center;
}

.footer-sos svg {
  width: 18px;
  height: 18px;
  fill: #fff;
}

.footer-social {
  display: flex;
  justify-content: center;
  margin-top: 16px;
}

.footer-social a {
  width: 36px;
  height: 36px;
  background: var(--orange);
  color: #fff;
  display: grid;
  place-items: center;
  border-radius: 4px;
}

.footer-social svg {
  width: 18px;
  height: 18px;
  fill: #fff;
}

.footer-bar {
  background: var(--orange);
  color: #fff;
  text-align: center;
  font-size: 14px;
  padding: 20px 50px 10px;
}

.footer-bar a {
  color: #fff;
}

/* WhatsApp float */
.wa-float {
  position: fixed;
  right: 25px;
  bottom: 10px;
  z-index: 40;
}

.wa-float-btn {
  width: 65px;
  height: 65px;
  border-radius: 50%;
  background: var(--green);
  color: #fff;
  display: grid;
  place-items: center;
}

.wa-float-btn:hover {
  background: #036628;
}

.wa-float-btn svg {
  width: 45px;
  height: 45px;
}

/* Lightbox */
.lb {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.92);
  z-index: 100;
  display: none;
  align-items: center;
  justify-content: center;
}

.lb.is-open {
  display: flex;
}

.lb img {
  max-width: min(92vw, 1200px);
  max-height: 86vh;
}

.lb button {
  position: absolute;
  background: transparent;
  border: 0;
  color: #fff;
  font-size: 32px;
  cursor: pointer;
}

.lb .lb-close {
  top: 16px;
  right: 22px;
}

.lb .lb-prev {
  left: 16px;
  top: 50%;
  transform: translateY(-50%);
}

.lb .lb-next {
  right: 16px;
  top: 50%;
  transform: translateY(-50%);
}

@media (max-width: 1024px) {
  .header-inner {
    flex-direction: column;
    min-height: auto;
    padding: 12px 0 8px;
    gap: 8px;
  }

  .nav-desktop {
    display: none;
  }

  .nav-toggle {
    display: block;
  }

  .logo {
    flex: none;
    width: 100%;
    justify-content: center;
  }

  .logo img {
    width: 50%;
  }

  .nav-wrap {
    flex: none;
    width: 100%;
    justify-content: center;
  }

  .intro-grid,
  .about-grid,
  .split-text,
  .cta-palfinger-inner {
    grid-template-columns: 1fr;
  }

  .cta-photo {
    min-height: 220px;
  }

  .svc-grid,
  .svc-grid.cols-3,
  .flip-grid,
  .contact-grid {
    grid-template-columns: 1fr 1fr;
  }

  .footer-grid {
    grid-template-columns: 1fr 1fr;
    padding: 40px 20px;
  }

  .svc-wrap {
    padding: 4em 2em;
  }

  .svc-card {
    min-height: 360px;
    padding-top: 15em;
  }

  .hero-slide a {
    padding: 0 50px;
  }
}

@media (max-width: 767px) {
  .svc-grid,
  .svc-grid.cols-3,
  .flip-grid,
  .contact-grid,
  .gallery,
  .intro-thumbs,
  .footer-grid {
    grid-template-columns: 1fr;
  }

  .intro-copy,
  .intro-media,
  .about-copy,
  .cta-copy,
  .about-photo {
    padding: 2em;
  }

  .svc-wrap {
    padding: 2em;
  }

  .hero-slider {
    height: 460px;
  }

  .cta-palfinger {
    padding: 2em;
  }

  .about-copy h2 {
    font-size: 2.2em;
  }

  .page-body {
    padding: 28px 0;
  }

  .footer-bar {
    padding: 16px 12px;
  }
}
