/* 宇爱畅享 yuai 主题 — 公共布局（顶栏 / 底栏 / 留资 / 悬浮） */

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  overflow-x: clip;
}

body {
  margin: 0;
  overflow-x: clip;
  max-width: 100%;
  font-family: "PingFang SC", "Microsoft YaHei", Arial, sans-serif;
  background: var(--ivory);
  color: #17130e;
  line-height: 1.75;
}

a {
  text-decoration: none;
  color: inherit;
}

img {
  max-width: 100%;
  height: auto;
}

.container {
  width: min(1180px, 92%);
  margin: auto;
}

/* ========== Header（产品页标准） ========== */
.header {
  position: sticky;
  top: 0;
  z-index: 99;
  background: rgba(26, 22, 16, 0.9);
  backdrop-filter: blur(18px);
  border-bottom: 1px solid rgba(212, 175, 55, 0.2);
}

.nav {
  height: 78px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
}

.logo {
  display: flex;
  align-items: center;
  gap: 12px;
  min-width: 0;
  flex-shrink: 1;
}

.logo img {
  height: 56px;
  width: auto;
  display: block;
  object-fit: contain;
  flex-shrink: 0;
}

.company-name {
  font-size: 16px;
  color: #f8e8a4;
  font-weight: 900;
  letter-spacing: 0.5px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.links {
  display: flex;
  gap: 24px;
  align-items: center;
  font-size: 15px;
  flex-shrink: 0;
}

/* 显式指定颜色：layui.css 在 head 末尾加载，会覆盖 inherit */
.header .links a {
  color: #efe6c8;
  opacity: 0.88;
  white-space: nowrap;
  transition: color 0.2s ease, opacity 0.2s ease;
}

.header .links a:hover,
.header .links a.active {
  color: var(--champagne);
  opacity: 1;
}

.nav-phone {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: var(--champagne) !important;
  font-weight: 900;
  opacity: 1 !important;
  letter-spacing: 0.2px;
}

.nav-phone svg {
  width: 18px;
  height: 18px;
  flex-shrink: 0;
  fill: currentColor;
}

.header .links a.nav-phone:hover {
  color: var(--gold) !important;
}

.nav-toggle {
  display: none;
  flex-direction: column;
  justify-content: center;
  gap: 5px;
  width: 44px;
  height: 44px;
  padding: 10px;
  margin: 0;
  border: 1px solid rgba(212, 175, 55, 0.35);
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.06);
  cursor: pointer;
  flex-shrink: 0;
}

.nav-toggle-bar {
  display: block;
  width: 100%;
  height: 2px;
  background: var(--champagne);
  border-radius: 2px;
  transition: transform 0.2s ease, opacity 0.2s ease;
}

.header.nav-open .nav-toggle-bar:nth-child(1) {
  transform: translateY(7px) rotate(45deg);
}

.header.nav-open .nav-toggle-bar:nth-child(2) {
  opacity: 0;
}

.header.nav-open .nav-toggle-bar:nth-child(3) {
  transform: translateY(-7px) rotate(-45deg);
}

/* ========== Footer（2 列紧凑，参考首图） ========== */
.footer-compact {
  background: var(--night);
  color: #d8ceb5;
  padding: 48px 0 0;
  border-top: 1px solid rgba(212, 175, 55, 0.18);
}

.footer-compact-inner {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 40px;
  align-items: center;
  padding-bottom: 40px;
}

.footer-brand-block {
  display: flex;
  align-items: center;
  gap: 20px;
}

.footer-brand-block .logo img {
  height: 56px;
  width: auto;
  max-width: 180px;
  object-fit: contain;
}

.footer-info {
  display: grid;
  gap: 8px;
  font-size: 14px;
  color: #ece4cb;
  line-height: 1.7;
}

.footer-info strong {
  color: inherit;
  font-weight: 700;
}

.footer-qr-block {
  text-align: center;
  min-width: 160px;
}

.footer-qr-title {
  color: var(--champagne);
  font-size: 15px;
  font-weight: 900;
  margin: 0 0 12px;
}

.footer-qr {
  width: 132px;
  height: 132px;
  margin: 0 auto 10px;
  padding: 8px;
  background: #fff;
  border-radius: 14px;
  display: grid;
  place-items: center;
}

.footer-qr img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  border-radius: 8px;
}

.footer-qr-desc {
  margin: 0;
  font-size: 13px;
  color: #d8ceb5;
}

.footer-bottom {
  border-top: 1px solid rgba(232, 210, 144, 0.12);
  padding: 18px 0 22px;
  display: flex;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
  font-size: 12px;
  color: #afa386;
}

.footer-bottom a {
  color: #afa386;
}

/* ========== 留资表单（案例页 #consult 标准） ========== */
.section-consult {
  padding: 76px 0;
}

.cta-lead {
  position: relative;
  border-radius: 36px;
  overflow: hidden;
  background: linear-gradient(
      90deg,
      rgba(26, 22, 16, 0.94),
      rgba(26, 22, 16, 0.72)
    ),
    url("../images/cta-bg.jpg") center / cover no-repeat;
  color: #fff;
  padding: 64px;
  box-shadow: var(--shadow);
}

.cta-lead h2 {
  font-size: clamp(30px, 4vw, 50px);
  line-height: 1.2;
  margin: 0 0 12px;
  color: #fff;
}

.cta-lead p {
  margin: 0 0 28px;
  color: #f0e7c8;
  font-size: 16px;
  max-width: 760px;
  white-space: normal;
}

.form-lead {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr)) auto;
  gap: 12px;
  align-items: center;
}

.form-lead input,
.form-lead select {
  height: 46px;
  border: 1px solid rgba(232, 210, 144, 0.22);
  background: rgba(255, 255, 255, 0.95);
  border-radius: 999px;
  padding: 0 16px;
  font-size: 14px;
  outline: none;
  width: 100%;
  font-family: inherit;
}

.form-lead input:focus,
.form-lead select:focus {
  border-color: var(--gold);
  box-shadow: 0 0 0 4px rgba(212, 175, 55, 0.12);
}

.btn-gold {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 12px 22px;
  height: 46px;
  border: none;
  border-radius: 999px;
  font-weight: 900;
  font-size: 14px;
  cursor: pointer;
  background: linear-gradient(135deg, var(--gold), var(--gold2));
  color: #17130e;
  box-shadow: 0 14px 35px rgba(212, 175, 55, 0.23);
  white-space: nowrap;
  font-family: inherit;
  transition: transform 0.2s ease;
}

.btn-gold:hover {
  transform: translateY(-2px);
}

/* ========== 悬浮栏（产品页 4 钮） ========== */
.float-mask {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.24);
  z-index: 94;
  display: none;
}

.float-mask.show {
  display: block;
}

.floating-tools {
  position: fixed;
  right: 22px;
  bottom: 88px;
  z-index: 90;
  display: grid;
  gap: 10px;
}

.float-btn {
  width: 62px;
  height: 62px;
  border-radius: 16px;
  border: 1px solid rgba(232, 210, 144, 0.38);
  background: linear-gradient(
    180deg,
    rgba(55, 44, 24, 0.96),
    rgba(26, 22, 16, 0.96)
  );
  color: #f8e8a4;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 4px;
  cursor: pointer;
  box-shadow: 0 14px 34px rgba(0, 0, 0, 0.28);
  font-size: 12px;
  font-weight: 800;
  line-height: 1.05;
  transition: 0.25s ease;
  font-family: inherit;
}

.float-btn:hover {
  transform: translateY(-3px);
  border-color: rgba(212, 175, 55, 0.75);
  color: #fff;
}

.float-btn .ico {
  font-size: 19px;
  line-height: 1;
}

.float-pop {
  position: fixed;
  right: 96px;
  bottom: 92px;
  width: 310px;
  background: rgba(26, 22, 16, 0.98);
  border: 1px solid rgba(232, 210, 144, 0.24);
  border-radius: 22px;
  box-shadow: 0 26px 70px rgba(0, 0, 0, 0.42);
  padding: 20px;
  z-index: 95;
  color: #f8e8a4;
  display: none;
}

.float-pop.show {
  display: block;
}

.float-pop-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  margin-bottom: 14px;
}

.float-pop-head strong {
  font-size: 18px;
}

.float-close {
  width: 30px;
  height: 30px;
  border-radius: 10px;
  border: 1px solid rgba(232, 210, 144, 0.25);
  background: rgba(255, 255, 255, 0.05);
  color: #f8e8a4;
  cursor: pointer;
  font-size: 18px;
  line-height: 1;
}

.float-phone-list {
  display: grid;
  gap: 10px;
}

.float-phone-list a {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 10px;
  padding: 13px 14px;
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(232, 210, 144, 0.16);
  color: #fff;
  font-weight: 850;
}

.float-phone-list a span {
  color: #d8ceb5;
  font-size: 13px;
  font-weight: 700;
}

.float-qr-wrap {
  text-align: center;
}

.float-qr-wrap img {
  width: 118px;
  height: 118px;
  padding: 10px;
  border-radius: 16px;
  background: #f8f8fa;
  object-fit: contain;
}

.float-pop-note {
  margin-top: 12px;
  color: #afa386;
  font-size: 12px;
  line-height: 1.7;
}

/* ========== 响应式 ========== */
@media (max-width: 960px) {
  .nav-toggle {
    display: flex;
  }

  .links {
    display: none;
    position: fixed;
    top: 78px;
    left: 0;
    right: 0;
    flex-direction: column;
    align-items: stretch;
    gap: 0;
    padding: 8px 16px 20px;
    background: rgba(26, 22, 16, 0.98);
    backdrop-filter: blur(18px);
    border-bottom: 1px solid rgba(212, 175, 55, 0.2);
    max-height: calc(100vh - 78px);
    overflow-y: auto;
    z-index: 98;
  }

  .header.nav-open .links {
    display: flex;
  }

  .header .links a {
    padding: 14px 4px;
    border-bottom: 1px solid rgba(212, 175, 55, 0.12);
    white-space: normal;
  }

  .header .links a:last-child {
    border-bottom: none;
  }

  .nav-phone {
    margin-top: 6px;
    padding-top: 16px !important;
    border-top: 1px solid rgba(212, 175, 55, 0.2);
  }

  .company-name {
    display: none;
  }

  .footer-compact-inner {
    grid-template-columns: 1fr;
    text-align: center;
  }

  .footer-brand-block {
    flex-direction: column;
  }

  .form-lead {
    grid-template-columns: 1fr;
  }

  .floating-tools {
    right: 12px;
    bottom: 72px;
    gap: 8px;
  }

  .container {
    width: calc(100% - 32px);
    max-width: 100%;
    margin-left: auto;
    margin-right: auto;
    padding-left: 16px;
    padding-right: 16px;
    box-sizing: border-box;
  }

  .float-btn {
    width: 56px;
    height: 56px;
    font-size: 11px;
  }

  .float-pop {
    left: 16px;
    right: 16px;
    bottom: 86px;
    width: auto;
  }
}

@media (max-width: 640px) {
  .nav {
    height: 62px;
  }

  .logo img {
    height: 40px;
  }

  .section-consult {
    padding: 56px 0;
  }

  .cta-lead {
    padding: 38px 22px;
    border-radius: 24px;
  }

  .cta-lead p {
    white-space: normal;
  }
}
