/* 前台「申请进度查询」弹层的增强样式。
   不改老 style.css（移植资源，改动风险大），只在其后加载覆盖：
   把查询结果表格从细边框小字的旧样式，换成跟站点一致的黑金卡片式，
   并给申请状态上语义色。仅作用于查询弹层 .layerconts-2，不影响其它。 */

/* 弹层面板：金边描一圈，和 hdDialog 统一 */
.layerconts-2 {
  border: .02rem solid #f0cc4c;
  box-shadow: 0 .12rem .6rem rgba(0, 0, 0, .5);
}

/* 关闭钮加大热区、hover 反馈，别再像个死图标 */
.layerconts-2 .close {
  right: .12rem;
  top: .12rem;
  width: .56rem;
  height: .56rem;
  transition: transform .15s ease, opacity .15s ease;
  opacity: .9;
}
.layerconts-2 .close:hover { transform: scale(1.08) rotate(90deg); opacity: 1; }

/* ===== 结果表格：卡片式，去细边框，行分隔用淡金线 ===== */
.layerconts-2 .con2 table {
  width: 100%;
  border-collapse: separate;
  border-spacing: 0;
  background: rgba(0, 0, 0, .18);
  border-radius: .12rem;
  overflow: hidden;
}
.layerconts-2 .con2 table tr th {
  border: none;
  background: linear-gradient(180deg, rgba(240, 204, 76, .22), rgba(240, 204, 76, .08));
  color: #fee563;
  font-size: .24rem;
  font-weight: 600;
  padding: .18rem .08rem;
  white-space: nowrap;
}
.layerconts-2 .con2 table tr td {
  border: none;
  border-top: .01rem solid rgba(240, 204, 76, .16);
  color: #f5ead1;
  font-size: .24rem;
  padding: .2rem .08rem;
  line-height: 1.5;
  white-space: nowrap;
}
/* 斑马行，看着不糊成一片 */
.layerconts-2 .con2 table tbody tr:nth-child(even) td {
  background: rgba(255, 255, 255, .03);
}
.layerconts-2 .con2 table tbody tr:hover td {
  background: rgba(240, 204, 76, .07);
}

/* 「点击查看」由刺眼纯红改成金色链接，和主题一致 */
.layerconts-2 .con2 table tr td a.look {
  color: #ffd77a;
  text-decoration: underline;
  text-underline-offset: .04rem;
  cursor: pointer;
}
.layerconts-2 .con2 table tr td a.look:hover { color: #fee563; }

/* 申请状态语义色（原来通过绿/拒绝红是内联 <font>，这里统一用 class 更好控） */
.layerconts-2 .con2 .st-pass { color: #7fe0a0; font-weight: 600; }
.layerconts-2 .con2 .st-reject { color: #ff8a8a; font-weight: 600; }
.layerconts-2 .con2 .st-wait { color: #ffcf6b; }

/* 空结果行居中、留白 */
.layerconts-2 .con2 table tbody tr td[colspan] {
  text-align: center;
  color: #cbb98f;
  padding: .4rem .08rem;
  font-size: .24rem;
}

/* 分页金色药丸，和站点一致；当前页高亮 */
.layerconts-2 .pages { margin-top: .28rem; }
.layerconts-2 .pages a {
  display: inline-block;
  min-width: .44rem;
  height: .44rem;
  line-height: .44rem;
  padding: 0 .12rem;
  font-size: .22rem;
  border-radius: .1rem;
  margin: 0 .05rem;
  background: rgba(240, 204, 76, .16);
  color: #fee563;
  border: .01rem solid rgba(240, 204, 76, .35);
  transition: background .15s ease;
}
.layerconts-2 .pages a:hover { background: rgba(240, 204, 76, .32); }

/* =========================================================================
   自建 fixed 遮罩（不再用 layer 承载）——彻底解决"弹层跑到页面底部、
   关闭后残留、被截断"三个问题。layer 会搬移 DOM 再搬回，真机上时序出错就残留；
   自建遮罩天然视口居中、内部可滚动、关闭即隐藏。
   ========================================================================= */

/* 全屏遮罩：固定、盖住整屏、flex 居中面板 */
.hd-query-mask {
  position: fixed;
  inset: 0;
  z-index: 999970;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: .3rem;
  box-sizing: border-box;
  background: rgba(0, 0, 0, .68);
  opacity: 0;
  transition: opacity .2s ease;
}
.hd-query-mask[hidden] { display: none; }
.hd-query-mask.is-open { opacity: 1; }

/* 面板：在遮罩里居中，限高 90vh，纵向 flex，结果区独立滚动。
   覆盖 style.css 原来的 position:relative / top:5% / margin / display:none。 */
.hd-query-mask .layerconts-2 {
  display: flex !important;
  flex-direction: column;
  position: relative;
  top: 0;
  margin: 0;
  width: 6.72rem;
  max-width: 100%;
  max-height: 90vh;
  box-sizing: border-box;
  overflow: hidden;             /* 面板自身不滚，滚动只在 .con2 */
  transform: translateY(.16rem) scale(.98);
  transition: transform .2s ease;
}
.hd-query-mask.is-open .layerconts-2 { transform: none; }

/* logo/标题/查询表单：固定不压缩 */
.hd-query-mask .logox,
.hd-query-mask .tlbox,
.hd-query-mask .con1 { flex: none; }

/* 结果区：唯一滚动容器。flex:1 吃掉剩余高度，超出内部滚，iOS 惯性滚动 */
.hd-query-mask .con2 {
  flex: 1 1 auto;
  min-height: 0;                /* 允许收缩才会出现滚动条 */
  overflow-y: auto;
  overflow-x: hidden;
  -webkit-overflow-scrolling: touch;
  padding: 0 .12rem;
}
.hd-query-mask .con2 table { margin-top: .04rem; }

/* 表头吸顶：滚动时列名常驻 */
.hd-query-mask .con2 table thead th,
.hd-query-mask .con2 table tr:first-child th {
  position: sticky;
  top: 0;
  z-index: 2;
}

/* 分页固定在面板底部、始终可点 */
.hd-query-mask .pages {
  flex: none;
  padding-bottom: .1rem;
}

/* 关闭钮钉在面板右上角，脱离滚动流 */
.hd-query-mask .close {
  position: absolute;
  z-index: 5;
}

/* 窄屏：留更小内边距，结果区高度更充分 */
@media (max-width: 768px) {
  .hd-query-mask { padding: .2rem; }
  .hd-query-mask .layerconts-2 { max-height: 92vh; }
  .hd-query-mask .con2 table tr th,
  .hd-query-mask .con2 table tr td { padding-left: .06rem; padding-right: .06rem; }
}

/* =========================================================================
   查询表单（会员账号输入框 + 选择项目下拉）黑金化，替代原白底黑字，和主题统一。
   仅作用于 .hd-query-mask 内，不影响全站其它 .taninpt 表单。
   原生 select 的展开列表由系统渲染（CSS 改不了），这里只美化「收起态」：
   深色底 + 金边 + 金字 + 自定义金色下拉箭头（隐藏系统默认箭头）。
   ========================================================================= */

/* 输入框与下拉的收起态：统一成深色金边 */
.hd-query-mask .taninpt {
  background: rgba(0, 0, 0, .28);
  border: .01rem solid rgba(240, 204, 76, .5);
  color: #f5ead1;
  border-radius: .1rem;
}
.hd-query-mask .taninpt:focus {
  outline: none;
  border-color: #f0cc4c;
  box-shadow: 0 0 0 .02rem rgba(240, 204, 76, .25);
}
/* 输入框 placeholder 用暗金，别再是黑色 */
.hd-query-mask .taninpt::placeholder { color: #cbb98f; }
.hd-query-mask input.taninpt::-webkit-input-placeholder { color: #cbb98f; }

/* 下拉：去掉系统默认箭头，右侧画一个金色三角，收起态就跟主题一致 */
.hd-query-mask select.taninpt {
  -webkit-appearance: none;
  -moz-appearance: none;
  appearance: none;
  color: #fee563;
  padding-right: .5rem;   /* 给箭头留位 */
  background-image: url("data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' width='14' height='9' viewBox='0 0 14 9'%3E%3Cpath d='M1 1l6 6 6-6' fill='none' stroke='%23f0cc4c' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right .18rem center;
  background-size: .22rem auto;
}
/* 未选择时的占位项（value=""）显示暗金，选了之后是亮金 */
.hd-query-mask select.taninpt:invalid,
.hd-query-mask select.taninpt option[value=""] { color: #cbb98f; }
/* 系统渲染的 option 尽量给个深色底（部分安卓/桌面浏览器生效，iOS 仍系统样式） */
.hd-query-mask select.taninpt option {
  background: #2a0f10;
  color: #f5ead1;
}

/* 标签文字（会员帐号/选择查询项目）用暗金，别是默认色 */
.hd-query-mask .foemzuo { color: #e2cd9c; }
