/* ============================================
   页脚样式表 footer.css
   功能：网站页脚（友情链接/导航/版权）+ 返回顶部 + 移动端底部导航
   写法：手机优先——每个模块先写移动端基础样式，
        紧跟其后的 min-width 媒体查询写桌面端增强（合写式，不开单独目录）
   断点全站统一：768 / 992 / 1200 / 1400
   ============================================ */


/* ---------- 1. 移动端页面底部偏移 ---------- */
/* 手机端底部导航 ax-btmnav 是 fixed 固定定位（高 3.5rem），
   给 body 底部留出同等空间，避免页脚内容被遮挡 */
body {
  padding-bottom: 3.5rem;
}

/* ≥768px：底部不再有固定导航，复位偏移 */
@media (min-width: 768px) {
  body { padding-bottom: 0; }
}

/* ---------- 2. 网站页脚（移动端整体隐藏，≥768px 显示） ---------- */
.site-footer {
  display: none;                         /* 移动端隐藏 */
  background-color: var(--footer-bg);
  line-height: var(--footer-line-height);
}

/* ≥768px：显示完整网站页脚 */
@media (min-width: 768px) {
  .site-footer { display: block; }
}

/* ---------- 3. 友情链接区 ---------- */
.links-section {
  display: flex;
  align-items: center;
  line-height: var(--line-height-5);
  border-bottom: 1px solid #ccc;
}

/* 左侧"友情链接 LINK"标题：不被右侧挤小 */
.link-header {
  display: flex;
  align-items: baseline;
  gap: 8px;                              /* "友情链接"与"LINK"的间距 */
  flex-shrink: 0;
}

.link-header .big {
  font-size: 1.5rem;
  font-weight: 500;
  color: var(--text-dark);
}

.link-header .small {
  font-size: 0.85rem;
  color: var(--text-secondary);
  text-transform: uppercase;             /* LINK 大写 */
}

/* 右侧说明文字：margin-left:auto 推到最右 */
.links-description {
  margin-left: auto;
  max-width: 70%;                        /* 防止太长挤掉左侧标题 */
  text-align: left;
  word-break: break-word;
  font-size: var(--font-size-14);
  line-height: var(--footer-line-height);
}

/* 第二排外部链接：水平居中排列 */
.external-links {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 20px;                             /* 链接之间的距离 */
  font-size: var(--font-size-14);
}

.external-links a:hover {
  color: var(--color-primary-dark);
}

/* ---------- 4. 页脚网站导航（暗红底白字横条） ---------- */
.site-footer .container .navigation-section {
  display: flex;
  justify-content: center;
  align-items: center;
  background-color: var(--color-primary-dark);
  color: var(--text-light);
  font-size: var(--font-size-14);
}

.navigation-section a:hover {
  color: var(--color-secondary-hover);   /* 悬停变黄 */
}

/* ---------- 5. 版权信息区（带浅色 Logo 背景图） ---------- */
.footer-section.copyright-section {
  background: url(/images/icon/logoy.png) no-repeat 5% 45%;
  font-size: var(--font-size-14);
}

.footer-section.copyright-section a:hover {
  color: var(--color-primary-light);
  text-decoration: underline;
  text-underline-offset: 3px;
}

/* 版权三行：居中排列 + 底部分隔线 */
.maintenance-info,
.recordation-info,
.copyright-info {
  display: flex;
  justify-content: center;
  align-items: center;
  border-bottom: 1px solid #ccc;
}

/* 前两行收窄居中 */
.maintenance-info,
.recordation-info {
  width: 75%;
  margin: 0 auto;
}

.maintenance-info {
  gap: 16px;
}

/* 蓝色版本号小标签 */
.version-link {
  padding: 0.25rem 0.5rem;
  line-height: 1;
  color: var(--info-version);
  background: rgba(0, 102, 204, 0.1);
  border-radius: 4px;
}


/* ---------- 6. 返回顶部按钮（桌面端使用，随页脚一起显示） ---------- */
#back-to-top {
  position: fixed;
  bottom: 30px;
  right: 30px;
  z-index: 999;
  cursor: pointer;
  opacity: 0;                            /* 默认透明隐藏 */
  pointer-events: none;                  /* 隐藏时不可点击 */
  transition: opacity 0.3s ease;
}

/* JS 滚动超过 300px 后加 .show 显示 */
#back-to-top.show {
  opacity: 1;
  pointer-events: auto;
}

#back-to-top img {
  width: 60px;
  height: 60px;
  background-color: var(--color-bg-light);
  border: 1px solid #ccc;
  box-shadow: 0 0 5px rgba(0, 0, 0, 0.3);
  transition: all 0.3s ease;
}


/* ---------- 7. 移动端底部固定导航（移动端显示，≥768px 隐藏） ---------- */
.ax-btmnav {
  position: fixed;
  left: 0;
  bottom: 0;
  width: 100%;
  height: 3.5rem;
  z-index: 610;
  display: block;
  box-sizing: border-box;
  text-align: center;
  background: linear-gradient(to right, #f03535, #ce0f0f);  /* 红色渐变底 */
}

.ax-btmnav a {
  display: flex;
  flex-direction: column;                /* 图标在上、文字在下 */
  justify-content: center;
  align-items: center;
  min-height: 2.4rem;
  color: var(--text-light);
}

/* 底部导航横向五等分 */
.ax-row {
  display: flex;
  flex-wrap: nowrap;
  flex-direction: row;
  width: 100%;
  box-sizing: border-box;
}

.ax-col {
  display: block;
  flex: auto;
  position: relative;
}

/* 图标 */
.ax-btmnav .ax-figure {
  display: block;
  position: relative;
  width: 1.75rem;
  height: 1.2rem;
  margin: 0.8rem auto 0;
  line-height: 1rem;
  font-size: var(--font-size-18);
  text-align: center;
  background-repeat: no-repeat;
  background-position: center;
  background-size: 1.75rem;
}

/* 图标下方文字 */
.ax-btmnav .ax-text {
  display: block;
  width: 3.75rem;
  margin-top: 0.2rem;
  line-height: 1.2;
  font-size: var(--font-size-14);
  white-space: nowrap;
  text-overflow: ellipsis;
  overflow: hidden;
}

/* ≥768px：隐藏移动端底部固定导航 */
@media (min-width: 768px) {
  .ax-btmnav { display: none; }
}
