/** @format */

.site-footer {
  background: #000;
  color: #fff;
  padding: 4dvh 3vw;
}

/* ================= DESKTOP GRID ================= */
.footer-grid {
  display: grid;
  grid-template-columns: 320px 320px 1fr;
  gap: 6vw;
  max-width: 1600px;
  margin-bottom: 90px;
}

.footer-col {
  border: none;
}

.footer-col h4 {
  font-size: 24px;
  font-weight: 600;
  letter-spacing: -0.62px;
  margin-bottom: 28px;
}

.footer-col ul {
  list-style: none;
  padding: 0;
  margin: 0;
}

.footer-col li {
  margin-bottom: 14px;
}

/* ================= UNDERLINE EFFECT (FIXED) ================= */
.footer-col a {
  position: relative;
  display: inline-block;
  color: #fff;
  text-decoration: none;
  font-size: 16px;
  padding-bottom: 2px;
}

.footer-col a::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: 0;
  width: 100%;
  height: 0.75px;
  background: #fff;
  transform: scaleX(0);
  transform-origin: left;
}

.footer-col a:hover::after {
  animation: underline-in 0.5s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

.footer-col a:not(:hover)::after {
  animation: underline-out 0.5s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

@keyframes underline-in {
  from {
    transform: scaleX(0);
  }
  to {
    transform: scaleX(1);
  }
}

@keyframes underline-out {
  from {
    transform: scaleX(1);
    transform-origin: right;
  }
  to {
    transform: scaleX(0);
    transform-origin: right;
  }
}

/* ================= BOTTOM BAR ================= */
.footer-bottom {
  display: flex;
  flex-direction: column;
  gap: 22px;
  align-items: center;
  text-align: center;
}

.footer-copy {
  font-family: "GucciSansPro-4", sans-serif;
  font-size: 15px;
  font-weight: 100;
}

.book-btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 16px 22px;
  border: 1px solid rgb(255 255 255 / 0.115);
  background: transparent;
  color: #fff;
  font-size: 15px;
  cursor: pointer;
}

.footer-social {
  display: flex;
  gap: 18px;
  flex-wrap: wrap;
  justify-content: center;
}

.footer-social a {
  width: 36px;
  height: 36px;
  border: 1px solid rgb(255 255 255 / 0.115);
  display: flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  font-size: 17px;
}

/* ================= DESKTOP BOTTOM ORDER ================= */
@media (min-width: 901px) {
  .site-footer {
    padding: 4dvh 3vw;
  }
  .footer-bottom {
    display: grid;
    grid-template-columns: 0.45fr auto 1fr;
    align-items: center;
    text-align: left;
  }

  .footer-copy {
    order: 1;
    justify-self: start;
  }

  .book-btn {
    order: 2;
    justify-self: center;
  }

  .footer-social {
    order: 3;
    justify-self: end;
  }
}

/* ================= MOBILE ================= */
@media (max-width: 900px) {
  .site-footer {
    padding: 3.5dvh 8vw;
  }

  .footer-grid {
    grid-template-columns: 1fr;
    gap: 0;
    margin-bottom: 28px;
  }

  .footer-col {
    border: 1px solid rgb(255 255 255 / 0.115);
    padding: 22px 20px 0px 20px;
  }

  .footer-col h4 {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 16px;
    margin-bottom: 0;
    cursor: pointer;
  }

  .footer-col h4:focus,
  .footer-col h4:active {
    outline: none;
  }

  /* arrows ONLY on mobile */
  .footer-col h4 .icon {
    font-size: 18px;
  }

  .footer-col ul {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.4s ease;
    margin-top: 3dvh;
  }
  .footer-col a {
    font-size: 14px;
  }

  .footer-col.active ul {
    max-height: 500px;
  }

  .icon-up {
    display: none;
  }

  .footer-col.active .icon-up {
    display: inline;
  }

  .footer-col.active .icon-down {
    display: none;
  }

  /* mobile bottom order (already correct) */
  .book-btn {
    order: 1;
  }
  .footer-social {
    order: 2;
  }
  .footer-copy {
    font-size: 13px;
    order: 3;
  }
}

/* hide arrows on desktop */
@media (min-width: 901px) {
  .footer-col h4 .icon {
    display: none;
  }
}
