.site-footer {
  background:
    linear-gradient(rgba(9, 41, 56, 0.96), rgba(9, 41, 56, 0.96)),
    url("img/indexsixthbackground.svg") center / cover no-repeat;
  color: #fff;
  padding: 116px 0 44px;
  min-height: min(calc(997 / 1920 * 100vw), 997px);
}

.footer-main {
  display: flex;
  justify-content: space-between;
  align-items: start;
}

.footer-logo {
  display: flex;
  align-items: center;
  flex-wrap: nowrap;
  gap: 16px;
  max-width: 343px;
  white-space: nowrap;
}

.footer-logo-icon {
  flex-shrink: 0;
  width: 3.958vw;
  min-width: 64px;
  max-width: 76px;
  height: auto;
  display: block;
}

.footer-logo-text {
  display: flex;
  flex-direction: column;
  flex-wrap: nowrap;
  gap: 2px;
  white-space: nowrap;
}

.footer-logo-zh {
  display: block;
  font-size: clamp(18px, calc(26 / 1920 * 100vw), 26px);
  font-weight: 500;
  color: #fff;
  white-space: nowrap;
  line-height: 1.3;
  letter-spacing: 0.02em;
}

.footer-logo-en {
  display: block;
  font-size: clamp(10px, calc(13 / 1920 * 100vw), 13px);
  font-weight: 400;
  color: rgba(255, 255, 255, 0.7);
  white-space: nowrap;
  line-height: 1.5;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.footer-contact {
  display: grid;
  gap: 16px;
  margin-top: 36px;
  list-style: none;
  padding: 0;
}

.footer-contact li {
  display: flex;
  align-items: flex-start;
  gap: 16px;
  line-height: 1.5;
}

.footer-contact li img {
  flex-shrink: 0;
  width: 1.875vw;
  min-width: 36px;
  max-width: 36px;
  height: 1.875vw;
  min-height: 36px;
  max-height: 36px;
  display: block;
  object-fit: contain;
}

.footer-contact li span {
  flex: 1;
  min-width: 0;
  color: rgba(255, 255, 255, 0.9);
  word-break: break-word;
}

.footer-form-wrap h2 {
  margin-bottom: 24px;
  color: rgba(255, 255, 255, 0.9);
  line-height: 1.5;
  font-weight: 400;
}

.contact-form {
  display: grid;
  gap: 24px;
  width: 790px;
  max-width: 100%;
}

.contact-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 24px 36px;
  align-items: start;
}

.contact-grid label,
.textarea-field {
  display: block;
}

.select-field {
  margin-top: 0;
  position: relative;
  padding-top: 0;
}

.custom-select {
  position: relative;
  width: 100%;
}

.custom-select-trigger {
  width: 100%;
  height: 48px;
  min-height: 48px;
  padding: 0 24px;
  border-radius: 30px;
  border: 1px solid var(--color-primary);
  background: transparent;
  color: rgba(255, 255, 255, 0.8);
  font-size: 16px;
  text-align: left;
  cursor: pointer;
  position: relative;
}

.custom-select-trigger::after {
  content: "";
  position: absolute;
  right: 24px;
  top: 50%;
  width: 8px;
  height: 8px;
  border-right: 2px solid rgba(255, 255, 255, 0.8);
  border-bottom: 2px solid rgba(255, 255, 255, 0.8);
  transform: translateY(-65%) rotate(45deg);
  transition: transform 0.2s ease;
}

.select-field.is-open .custom-select-trigger::after {
  transform: translateY(-35%) rotate(225deg);
}

.custom-select-menu {
  position: absolute;
  left: 0;
  top: calc(100% + 10px);
  width: 100%;
  margin: 0;
  padding: 8px;
  list-style: none;
  border: 1px solid var(--color-primary);
  border-radius: 12px;
  background: rgba(7, 43, 48, 0.98);
  z-index: 15;
  display: none;
}

.select-field.is-open .custom-select-menu {
  display: block;
}

.custom-select-option {
  padding: 10px 12px;
  border-radius: 8px;
  color: rgba(255, 255, 255, 0.9);
  cursor: pointer;
  line-height: 1.5;
}

.custom-select-option:hover {
  background: rgba(11, 152, 148, 0.22);
}

.contact-form input,
.contact-form select,
.contact-form textarea {
  width: 100%;
  color: #fff;
  border: 1px solid var(--color-primary);
  background: transparent;
}

.contact-form input,
.contact-form select {
  height: 48px;
  min-height: 48px;
  padding: 0 24px;
  border-radius: 30px;
  font-size: 16px;
}

.contact-form textarea {
  height: 144px;
  min-height: 144px;
  padding: 24px;
  border-radius: 12px;
  font-size: 16px;
}

.contact-form input::placeholder,
.contact-form textarea::placeholder {
  color: rgba(255, 255, 255, 0.8);
}

.contact-form select {
  color: rgba(255, 255, 255, 0.8);
  cursor: pointer;
  background-image:
    linear-gradient(45deg, transparent 50%, rgba(255, 255, 255, 0.8) 50%),
    linear-gradient(135deg, rgba(255, 255, 255, 0.8) 50%, transparent 50%);
  background-position:
    calc(100% - 1.719vw) 50%,
    calc(100% - 1.302vw) 50%;
  background-size: 8px 8px, 8px 8px;
  background-repeat: no-repeat;
}

.submit-btn {
  width: 100%;
  height: 86px;
  min-height: 86px;
  border-radius: 77px;
  border: 0;
  background: var(--color-primary);
  color: #fff;
  cursor: pointer;
  transition: transform var(--transition), filter var(--transition);
}

.submit-btn:hover {
  filter: brightness(1.05);
  transform: translateY(-2px);
}

.footer-bottom {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 32px;
  margin-top: 168px;
  padding: 0 0 47px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.6);
  overflow: visible;
}

.footer-nav,
.footer-socials,
.footer-legal {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
}

.footer-nav {
  gap: 86px;
}

.footer-nav a,
.footer-legal a,
.footer-socials a {
  position: relative;
}

.footer-nav a::after,
.footer-legal a::after,
.footer-socials a::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: -0.469vw;
  width: 0;
  height: 2px;
  background: currentColor;
  transition: width var(--transition);
}

.footer-nav a:hover::after,
.footer-legal a:hover::after,
.footer-socials a:hover::after {
  width: 100%;
}

.footer-socials {
  gap: 48px;
  overflow: visible;
}

.footer-socials a,
.footer-social-link {
  position: relative;
  width: 50px;
  min-width: 50px;
  height: 50px;
  min-height: 50px;
  border-radius: 50%;
  border: 0;
  background: var(--color-primary);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: rgba(255, 255, 255, 0.9);
  line-height: 0;
  overflow: visible;
  text-decoration: none;
}

.footer-socials a::after {
  display: none;
}

.footer-socials-wrap {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 12px;
  overflow: visible;
}

.footer-socials a .footer-social-icon,
.footer-social-link > .footer-social-icon {
  display: block;
  width: 40px;
  min-width: 40px;
  min-height: 40px;
  height: auto;
  max-width: 40px;
  max-height: 40px;
  object-fit: contain;
}

.footer-socials a .footer-socials-qr,
.footer-social-link .footer-socials-qr {
  position: absolute;
  left: 50%;
  bottom: calc(100% + 14px);
  transform: translateX(-50%) translateY(8px);
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transition:
    opacity 0.25s ease,
    transform 0.25s ease,
    visibility 0.25s;
  z-index: 20;
  display: block;
  line-height: 0;
}

.footer-socials a:hover .footer-socials-qr,
.footer-socials a:focus-visible .footer-socials-qr,
.footer-social-link:hover .footer-socials-qr,
.footer-social-link:focus-visible .footer-socials-qr {
  opacity: 1;
  visibility: visible;
  transform: translateX(-50%) translateY(0);
}

.footer-social-qr {
  position: relative;
  width: 96px;
  height: 96px;
  background: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 6px;
  border-radius: 8px;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.28);
}

.footer-social-qr::after {
  content: "";
  position: absolute;
  left: 50%;
  bottom: -6px;
  width: 12px;
  height: 12px;
  background: #fff;
  transform: translateX(-50%) rotate(45deg);
  box-shadow: 2px 2px 4px rgba(0, 0, 0, 0.08);
}

.footer-social-qr img {
  position: relative;
  z-index: 1;
  width: 100%;
  height: 100%;
  display: block;
  object-fit: contain;
}

.footer-legal {
  justify-content: space-between;
  gap: 32px;
  padding-top: 36px;
  color: rgba(255, 255, 255, 0.6);
}

.footer-legal > div {
  display: flex;
  align-items: center;
  gap: 48px;
}

@media screen and (max-width: 1200px) {
  .footer-main {
    flex-direction: column;
    gap: 40px;
  }
}

@media screen and (max-width: 768px) {
  .site-footer {
    padding: 56px 0 28px;
    min-height: 0;
  }

  .footer-main {
    flex-direction: column;
    gap: 28px;
  }

  .footer-form-wrap {
    width: 100%;
    max-width: 100%;
  }

  .footer-logo {
    gap: 14px;
    max-width: 100%;
  }

  .footer-logo-icon {
    width: 56px;
    min-width: 56px;
    max-width: 56px;
  }

  .footer-logo-zh {
    font-size: 18px;
  }

  .footer-logo-en {
    font-size: 10px;
  }

  .footer-contact {
    gap: 14px;
    margin-top: 20px;
  }

  .footer-contact li {
    gap: 12px;
  }

  .footer-contact li img {
    width: 32px;
    min-width: 32px;
    max-width: 32px;
    height: 32px;
    min-height: 32px;
    max-height: 32px;
    margin-top: 2px;
  }

  .footer-contact li span {
    padding-top: 4px;
  }

  .footer-form-wrap h2 {
    margin-bottom: 18px;
    white-space: normal;
  }

  .contact-form {
    gap: 18px;
    width: 100%;
  }

  .contact-grid {
    gap: 14px;
    align-items: start;
    grid-template-columns: 1fr;
  }

  .select-field {
    margin-top: 0;
    padding-top: 0;
  }

  .custom-select-trigger {
    height: 48px;
    min-height: 48px;
    padding: 0 18px;
    border-radius: 30px;
  }

  .custom-select-trigger::after {
    right: 18px;
  }

  .contact-form input,
  .contact-form select {
    height: 48px;
    min-height: 48px;
    padding: 0 18px;
    border-radius: 30px;
  }

  .contact-form textarea {
    height: 144px;
    min-height: 144px;
    padding: 18px;
    border-radius: 12px;
  }

  .submit-btn {
    height: 60px;
    min-height: 60px;
    border-radius: 60px;
  }

  .footer-bottom,
  .footer-legal {
    flex-direction: column;
    align-items: flex-start;
    gap: 18px;
  }

  .footer-bottom {
    margin-top: 36px;
    padding: 28px 0;
  }

  .footer-nav {
    gap: 18px 24px;
  }

  .footer-socials {
    gap: 14px;
  }

  .footer-socials a {
    width: 42px;
    height: 42px;
    min-width: 42px;
    min-height: 42px;
  }

  .footer-legal > div {
    gap: 18px;
  }
}
