/* ===================================================================
   FILE        : footer.css
   PROJECT     : Lexvora Consulting
   PURPOSE     : Shared footer styling for every page.
   =================================================================== */

/* Shared footer */
.footer {
  position: relative;
  overflow: hidden;
  background:
    radial-gradient(circle at 78% 48%, rgba(210,161,95,.07), transparent 28%),
    linear-gradient(rgba(5,17,29,.97), rgba(4,15,26,.99)),
    url("../images/dark-pattern.svg");
  color: #fff;
  padding: clamp(48px, 5vw, 76px) clamp(24px, 5vw, 72px) 0;
  isolation: isolate;
}

.footer::before {
  content: "";
  position: absolute;
  inset: 0 0 auto;
  height: 1px;
  background: linear-gradient(90deg, transparent, var(--gold-light), transparent);
  opacity: .7;
  pointer-events: none;
}

.footer-grid {
  position: relative;
  z-index: 1;
  width: min(100%, 1700px);
  margin: 0 auto;
  display: grid;
  grid-template-columns: minmax(230px, 1.35fr) minmax(145px, .78fr) minmax(180px, .95fr) minmax(165px, .82fr) minmax(335px, 1.55fr);
  align-items: start;
  gap: clamp(24px, 2.45vw, 46px);
}

.footer-section {
  min-width: 0;
}

.footer-grid > .footer-section:not(:first-child) {
  border-left: 1px solid rgba(210,161,95,.28);
  padding-left: clamp(18px, 1.7vw, 30px);
}

.footer-brand img {
  display: block;
  width: clamp(155px, 13vw, 220px);
  max-width: 100%;
  height: auto;
  margin: 0 0 22px;
}

.footer h2 {
  color: var(--gold-light);
  font-size: 14px;
  line-height: 1.2;
  text-transform: uppercase;
  letter-spacing: .16em;
  margin: 0 0 26px;
}

.footer h2::after {
  content: "";
  display: block;
  width: 48px;
  height: 1px;
  margin-top: 12px;
  background: linear-gradient(90deg, var(--gold-light), transparent);
}

.footer p,
.footer a {
  color: #d2dce3;
  font-size: 14px;
  line-height: 1.68;
}

.footer-brand p {
  max-width: 360px;
  margin: 0;
}

.footer-links a {
  display: block;
  width: fit-content;
  margin-bottom: 12px;
  text-decoration: none;
  transition: color .22s ease, transform .22s ease;
}

.footer-links a:hover,
.footer-links a:focus-visible {
  color: #f1c873;
  transform: translateX(4px);
}

.footer a:focus-visible {
  outline: 2px solid #f1c873;
  outline-offset: 4px;
}

.socials {
  display: flex;
  gap: 10px;
  margin-top: 22px;
}

.socials span,
.socials a {
  width: 38px;
  height: 38px;
  border: 1px solid rgba(210,161,95,.75);
  color: #e8b862;
  display: grid;
  place-items: center;
  flex: 0 0 38px;
  font-size: 14px;
  font-weight: 700;
  text-decoration: none;
  border-radius: 7px;
  background: rgba(255,255,255,.015);
  transition: color .22s ease, background .22s ease, border-color .22s ease, transform .22s ease;
}

.socials a:hover,
.socials a:focus-visible {
  background: linear-gradient(135deg, var(--gold), var(--gold-light));
  border-color: #edc575;
  color: #071421;
  transform: translateY(-2px);
}

.footer-contact h2 {
  margin-bottom: 18px;
}

.footer-office {
  display: block;
  margin: 0 0 12px;
  padding: 17px 18px 14px;
  color: #071421;
  font-style: normal;
  border: 1px solid rgba(255,225,154,.88);
  border-radius: 12px;
  background:
    linear-gradient(115deg, rgba(255,255,255,.26), transparent 32%),
    linear-gradient(145deg, #f7d98e 0%, #f0c66e 42%, #e6ad47 100%);
  box-shadow:
    0 13px 28px rgba(0,0,0,.2),
    0 0 22px rgba(226,173,71,.13),
    inset 0 1px 0 rgba(255,255,255,.55);
}

.footer .footer-office--regional {
  border-color: rgba(224,210,171,.88);
  background:
    linear-gradient(115deg, rgba(255,255,255,.28), transparent 34%),
    linear-gradient(145deg, #ded6bf 0%, #c8ba94 48%, #ac996c 100%);
  box-shadow:
    0 13px 28px rgba(0,0,0,.2),
    0 0 20px rgba(190,170,118,.12),
    inset 0 1px 0 rgba(255,255,255,.58);
}

.office-heading {
  display: grid;
  grid-template-columns: 34px minmax(0, 1fr);
  gap: 12px;
  align-items: start;
}

.office-icon {
  display: block;
  width: 32px;
  height: 32px;
  padding: 6px;
  border: 1px solid rgba(7,20,33,.66);
  border-radius: 8px;
  object-fit: contain;
}

.footer-office h3 {
  margin: 1px 0 6px;
  color: #071421;
  font-size: 13px;
  line-height: 1.3;
  letter-spacing: .065em;
  text-transform: uppercase;
}

.footer .footer-office p,
.footer .footer-office a {
  color: #071421;
  font-size: 12.5px;
  line-height: 1.52;
}

.footer .footer-office p {
  margin: 0;
}

.office-phone {
  display: flex;
  align-items: center;
  gap: 9px;
  margin-top: 12px;
  padding-top: 10px;
  border-top: 1px solid rgba(7,20,33,.35);
  font-weight: 700;
  text-decoration: none;
}

.office-phone:hover,
.office-phone:focus-visible {
  color: #000 !important;
}

.office-phone img {
  display: block;
  width: 32px;
  height: 32px;
  flex: 0 0 32px;
  padding: 6px;
  border: 1px solid rgba(7,20,33,.66);
  border-radius: 8px;
  object-fit: contain;
}

.footer-direct-contact {
  display: grid;
  gap: 8px;
  margin-top: 16px;
}

.footer-direct-contact a {
  display: flex;
  align-items: center;
  gap: 10px;
  width: fit-content;
  text-decoration: none;
  overflow-wrap: anywhere;
  transition: color .22s ease;
}

.footer-direct-contact a img {
  display: block;
  width: 32px;
  height: 32px;
  flex: 0 0 32px;
  padding: 6px;
  border: 1px solid rgba(210,161,95,.7);
  border-radius: 8px;
  object-fit: contain;
}

.footer-direct-contact a:hover,
.footer-direct-contact a:focus-visible {
  color: #f1c873;
}

.footer-bottom {
  position: relative;
  z-index: 1;
  width: min(100%, 1700px);
  margin: clamp(38px, 4vw, 58px) auto 0;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  color: #cfd8df;
  font-size: 13px;
  border-top: 1px solid rgba(210,161,95,.72);
  padding: 22px 0 24px;
}

.footer-menu {
  display: flex;
  align-items: center;
  gap: 8px;
}

.footer-menu a {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 36px;
  padding: 7px 17px;
  color: #d9e0e5;
  text-decoration: none;
  border: 1px solid rgba(207,216,223,.28);
  border-radius: 999px;
  transition: color .22s ease, background .22s ease, border-color .22s ease, box-shadow .22s ease, transform .22s ease;
}

.footer-menu a:hover,
.footer-menu a:focus-visible,
.footer-menu a[aria-current="page"] {
  color: #071421;
  background: linear-gradient(135deg, #f1f3f4 0%, #c8ced2 52%, #aeb6bd 100%);
  border-color: #e7eaec;
  box-shadow: 0 8px 18px rgba(0,0,0,.2), inset 0 1px 0 rgba(255,255,255,.78);
  transform: translateY(-1px);
}

.footer-menu a:focus-visible {
  outline: 2px solid #f1c873;
  outline-offset: 3px;
}

.footer.footer-js .footer-section {
  opacity: 0;
  transform: translateY(12px);
}

.footer.footer-js.footer-visible .footer-section {
  opacity: 1;
  transform: none;
  transition: opacity .55s ease, transform .55s ease;
}

.footer.footer-js.footer-visible .footer-section:nth-child(2) { transition-delay: .06s; }
.footer.footer-js.footer-visible .footer-section:nth-child(3) { transition-delay: .12s; }
.footer.footer-js.footer-visible .footer-section:nth-child(4) { transition-delay: .18s; }
.footer.footer-js.footer-visible .footer-section:nth-child(5) { transition-delay: .24s; }

@media (prefers-reduced-motion: reduce) {
  .footer.footer-js .footer-section {
    opacity: 1;
    transform: none;
    transition: none;
  }
}

@media (max-width: 1180px) {
  .footer-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 38px 32px;
  }

  .footer-brand,
  .footer-contact {
    grid-column: 1 / -1;
  }

  .footer-grid > .footer-section:not(:first-child) {
    padding-left: 24px;
  }

  .footer-brand {
    display: grid;
    grid-template-columns: auto minmax(260px, 1fr) auto;
    align-items: end;
    gap: 28px;
  }

  .footer-brand img,
  .footer-brand p,
  .socials {
    margin: 0;
  }

  .footer-contact {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 12px;
  }

  .footer-contact h2,
  .footer-direct-contact {
    grid-column: 1 / -1;
  }
}

@media (max-width: 768px) {
  .footer {
    padding-inline: 22px;
  }

  .footer-grid {
    grid-template-columns: 1fr;
    gap: 34px;
  }

  .footer-brand,
  .footer-contact {
    grid-column: auto;
    display: block;
  }

  .footer-brand img {
    margin-bottom: 20px;
  }

  .footer-brand p {
    margin-bottom: 20px;
  }

  .footer-grid > .footer-section:not(:first-child) {
    border-left: 0;
    border-top: 1px solid rgba(210,161,95,.22);
    padding: 28px 0 0;
  }

  .footer-direct-contact {
    display: grid;
  }

  .footer-bottom {
    align-items: flex-start;
    flex-direction: column;
  }

  .footer-menu {
    flex-wrap: wrap;
  }
}
