/* ============================================
   Footer Section - 精确还原 Figma 设计 (重组后)
   蓝底 + 顶部背景细线装饰 + 联系信息 + Logo/菜单/版权
   ============================================ */

.footer {
  position: relative;
  width: 100%;
  background: var(--color-primary);
  overflow: hidden;
}

/* 装饰: 背景细线图案 (Figma Vector 568:23113, 白 50%, 顶部全宽 1920x451) */
.footer__deco {
  position: absolute;
  top: -40px;
  left: 0;
  width: 100%;
  min-width: 100%;
  height: auto;
  pointer-events: none;
  z-index: 1;
  display: block;
}

.footer__inner {
  position: relative;
  max-width: 1920px;
  margin: 0 auto;
  min-height: 550px;
  padding: 52px 48px 48px 80px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  z-index: 2;
  box-sizing: border-box;
}

/* --- 联系信息行 --- */
.footer__contact {
  display: flex;
  align-items: center;
}

/* 按设计稿绝对间距: tel→email 76px, email→address 36px (1920 基准) */
.footer__contact-item:nth-child(2) {
  margin-left: 76px;
}

.footer__contact-item:nth-child(3) {
  margin-left: 36px;
}

.footer__contact-item {
  display: flex;
  align-items: center;
  gap: 15px;
}

.footer__contact-icon {
  flex-shrink: 0;
  width: clamp(32px, 2.396vw, 46px);
  height: clamp(32px, 2.396vw, 46px);
  border-radius: 50%;
  background: var(--color-white);
  display: flex;
  align-items: center;
  justify-content: center;
}

.footer__contact-icon svg {
  width: 55%;
  height: 55%;
  display: block;
}

.footer__contact-text {
  font-family: var(--font-primary);
  font-size: clamp(0.8125rem, 0.9375vw, 1.125rem);
  font-weight: 400;
  line-height: 1.375;
  color: var(--color-white);
}

.footer__contact-item--address .footer__contact-text {
  max-width: 460px;
}

/* --- 底部行 (Logo + 菜单/版权) --- */
.footer__bottom {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 24px;
}

.footer__logo {
  text-align: center;
  margin-bottom: 30px;
}

.footer__logo img {
  width: clamp(120px, 10.99vw, 211px);
  height: auto;
  display: inline-block;
}

.footer__right {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 8px;
  justify-content: center;
  width: 100%;
  padding-top: 20px;
  border-top: 1px solid rgba(255, 255, 255, 0.2);
}

.footer__linkedin-wrap {
  position: relative;
  display: inline-block;
  margin-right: 16px;
}

.footer__linkedin {
  width: 32px;
  height: auto;
  display: block;
}

.footer__linkedin-qr {
  position: absolute;
  bottom: calc(100% + 5px);
  left: 50%;
  transform: translateX(-50%) translateY(15px);
  width: 80px;
  height: 80px;
  object-fit: contain;
  max-width: none;
  opacity: 0;
  pointer-events: none;
  transition: transform 0.3s ease, opacity 0.3s ease;
}

.footer__linkedin-wrap:hover .footer__linkedin-qr {
  transform: translateX(-50%) translateY(0);
  opacity: 1;
}

.footer__menu {
  display: flex;
  gap: 8px;
}

.footer__menu-col {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.footer__menu-item {
  padding: 8px 16px;
  font-family: var(--font-primary);
  font-size: clamp(0.875rem, 1.0417vw, 1.25rem);
  font-weight: 600;
  line-height: 1.5;
  color: var(--color-white);
  text-decoration: none;
}

/* 版权文字 50% 透明 (按重组后设计稿) */
.footer__copyright {
  font-family: var(--font-primary);
  font-size: clamp(0.875rem, 1.0417vw, 1.25rem);
  font-weight: 400;
  line-height: 1.375;
  color: rgba(255, 255, 255, 0.5);
  margin: 0;
  text-align: right;
}

/* ============================================
   Responsive Footer
   ============================================ */

@media (max-width: 1200px) {
  .footer__inner { padding: 40px 40px 28px; min-height: auto; }
  .footer__contact { gap: 28px; flex-wrap: wrap; }
  .footer__contact-item:nth-child(2),
  .footer__contact-item:nth-child(3) { margin-left: 0; }
}

@media (max-width: 768px) {
  .footer__inner { padding: 40px 20px 28px; }

  /* 移动端隐藏背景水印装饰 */
  .footer__deco { display: none; }

  /* 联系信息: 地址第一行, 电话 + Email 同一行 */
  .footer__contact {
    flex-direction: row;
    flex-wrap: wrap;
    align-items: flex-start;
    gap: 20px;
  }

  .footer__contact-item { width: auto; }

  .footer__contact-item--address {
    order: -1;
    flex: 0 0 100%;
  }

  .footer__contact-item--address .footer__contact-text { max-width: 100%; }

  /* Logo 左右居中, 与联系信息之间留出间距 */
  .footer__bottom {
    flex-direction: column;
    align-items: center;
    gap: 24px;
    margin-top: 48px;
  }

  .footer__right { align-items: center; width: 100%; }
  .footer__linkedin-wrap { display: none; }
  .footer__menu { flex-wrap: wrap; gap: 8px; justify-content: center; }

  /* 移动端隐藏版权行 */
  .footer__copyright { display: none; }
}

@media (max-width: 576px) {
  .footer__inner { padding: 32px 16px 24px; }
  .footer__contact { gap: 16px; }
}

/* 尊重减少动效偏好 */
@media (prefers-reduced-motion: reduce) {
  .footer__menu-item { transition: none; }
}

/* PC端：回滚到 LinkedIn 图标右对齐 Contact Us 的状态 */
@media (min-width: 769px) {
  .footer__logo {
    position: absolute;
    bottom: 48px;
    left: 80px;
    margin-bottom: 0 !important;
    text-align: left !important;
    z-index: 3;
  }

  .footer__logo img {
    display: block !important;
  }

  .footer__bottom {
    margin-top: auto;
    justify-content: flex-end !important;
  }

  .footer__right {
    width: auto !important;
    padding-top: 0 !important;
    border-top: none !important;
    flex-direction: column !important;
    align-items: flex-end !important;
    gap: 8px !important;
  }

  .footer__linkedin-wrap {
    margin-right: 16px !important;
  }

  .footer__menu-col {
    display: contents !important;
  }
}
