/* PUBG 解封申诉 · 样式
   风格对齐 gift-portal：Layui 骨架 + 青绿主色 + 深青渐变标题栏 */

/* 滚动条出现时预留宽度，避免内容区被挤压后整体左右跳动 */
html {
  scrollbar-gutter: stable;
  background: #eef6f5;
}

::-webkit-scrollbar { width: 12px; height: 12px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb {
  border: 3px solid #eef6f5;
  border-radius: 8px;
  background: #cddbd9;
}
::-webkit-scrollbar-thumb:hover { background: #b3c9c5; }

body {
  margin: 0;
  padding: 28px 0 40px;
  background: #eef6f5;
  font-family: "PingFang SC", "Microsoft YaHei", "Noto Sans SC", system-ui, sans-serif;
  color: #203b3d;
  -webkit-font-smoothing: antialiased;
}

#app { width: min(760px, calc(100% - 32px)); margin: 0 auto; }

#centerdiv {
  overflow: hidden;
  border: 1px solid #d7e6e4;
  border-radius: 16px;
  background: #fff;
  box-shadow: 0 18px 46px rgba(20, 72, 70, .13);
}

/* ---------------- 顶部品牌 ---------------- */

.brand-bar {
  display: flex;
  align-items: center;
  /* 左边不留缩进，让标题与下方卡片左边缘齐平 */
  padding: 22px 0 18px;
}

.brand-text { font-size: 16px; font-weight: 800; letter-spacing: .04em; color: #103035; }

/* ---------------- Tab ---------------- */

.layui-tab-card { border: 0; }

.layui-tab-card > .layui-tab-title {
  display: flex;
  height: 62px;
  padding: 0 14px;
  border: 0;
  background: linear-gradient(110deg, #103035, #176f69);
}

.layui-tab-card > .layui-tab-title li {
  position: relative;
  flex: 1;
  min-width: 0;
  height: 62px;
  padding: 0 12px;
  border: 0;
  color: #c6e4e0;
  font-size: 14px;
  line-height: 62px;
  text-align: center;
  cursor: pointer;
  transition: background .18s, color .18s;
}

.layui-tab-card > .layui-tab-title li:hover { background: rgba(255, 255, 255, .08); color: #fff; }

/* 只剩一个页签时它只是卡片标题，不该有可点击的交互暗示 */
.layui-tab-title li:only-child {
  pointer-events: none;
  cursor: default;
}

.layui-tab-title li:only-child:hover { background: rgba(255, 255, 255, .13); }

.layui-tab-card > .layui-tab-title .layui-this {
  border: 0;
  background: rgba(255, 255, 255, .13);
  color: #fff;
  font-weight: 700;
}

.layui-tab-card > .layui-tab-title li.layui-this::after {
  position: absolute;
  right: 0;
  bottom: 0;
  left: 0;
  height: 3px;
  border: 0;
  border-radius: 0;
  background: #6ee0d0;
  content: "";
}

.layui-tab-content { padding: 30px 42px 38px; overflow-x: hidden !important; }
.layui-tab-item { display: none; min-height: 380px; }
.layui-tab-item.layui-show { display: block; }

/* ---------------- 表单 ---------------- */

/* layui 原生的 label 是 float:left，右侧 input-block 里的块级 input 会被
   float 避让规则整体下压（实测偏移 39px，与 label 高度相等），导致标签和
   输入框错位。这里把 label 改为绝对定位，让 input-block 回到正常块流。 */
.layui-form-item { position: relative; margin-top: 19px; }

.layui-form-label {
  position: absolute;
  top: 0;
  left: 0;
  box-sizing: border-box;
  width: 108px;
  padding: 0 15px 0 0;
  color: #567074;
  font-size: 13px;
  font-weight: 700;
  line-height: 42px;
  text-align: right;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

/* 容器字体度量归零，避免 input 前后的换行空白形成匿名行盒 */
.layui-input-block { margin-left: 108px; font-size: 0; line-height: 0; }

.layui-input, .layui-textarea {
  display: block;
  width: 100%;
  box-sizing: border-box;
  padding-left: 13px;
  border: 1px solid #d4e2e0;
  border-radius: 7px;
  color: #203b3d;
  background: #fff;
  font-family: inherit;
  font-size: 14px;
  line-height: normal;
  outline: none;
  transition: border-color .16s, box-shadow .16s;
}

.layui-input { height: 42px; line-height: 42px; }
.layui-textarea { padding: 10px 13px; line-height: 1.55; resize: vertical; min-height: 76px; }

.layui-input:focus, .layui-textarea:focus {
  border-color: #52afa5 !important;
  box-shadow: 0 0 0 3px rgba(21, 123, 119, .11);
}

.layui-input::placeholder, .layui-textarea::placeholder { color: #a2b0b0; }

.field-hint { margin: 6px 0 0; color: #8ba3a1; font-size: 12px; line-height: 1.5; }

/* 密码框眼睛
   注意：.layui-input-block 内 input 前的换行空白会形成匿名行盒（继承 line-height
   约 39px），把 input 顶下去。这里用 flex 让容器忽略空白文本节点，高度贴合 input。 */

.pwd-field { position: relative; display: flex; align-items: center; }
.pwd-field .layui-input { flex: 1 1 auto; width: 100%; padding-right: 46px; }

.pwd-toggle {
  position: absolute;
  top: 50%;
  right: 0;
  transform: translateY(-50%);
  display: flex;
  width: 42px;
  height: 42px;
  align-items: center;
  justify-content: center;
  padding: 0;
  border: 0;
  background: none;
  color: #8ba3a1;
  cursor: pointer;
  transition: color .16s;
}

.pwd-toggle:hover { color: #157b77; }
.pwd-toggle:focus-visible { border-radius: 7px; outline: 2px solid #52afa5; outline-offset: -3px; }
.pwd-toggle svg { width: 19px; height: 19px; fill: none; stroke: currentColor; stroke-linecap: round; stroke-linejoin: round; stroke-width: 1.7; }
.pwd-toggle .pwd-eye-off { display: none; }
.pwd-toggle.is-off .pwd-eye { display: none; }
.pwd-toggle.is-off .pwd-eye-off { display: block; }

/* 登录方式：三段式切换 */

.seg {
  display: flex;
  gap: 4px;
  padding: 4px;
  border-radius: 10px;
  background: #eef3f2;
}

.seg button {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  min-width: 0;
  height: 40px;
  padding: 0 8px;
  border: 0;
  border-radius: 8px;
  background: transparent;
  color: #6b8588;
  font-family: inherit;
  font-size: 13px;
  font-weight: 600;
  line-height: 1;
  white-space: nowrap;
  cursor: pointer;
  transition: background .16s, color .16s, box-shadow .16s;
}

.seg button svg {
  width: 16px;
  height: 16px;
  flex: none;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.7;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.seg button:hover { color: #2e4b4d; }

.seg button.on {
  background: #fff;
  color: #0f6b66;
  font-weight: 800;
  box-shadow: 0 2px 8px rgba(16, 48, 53, .13);
}

/* ---------------- 按钮 ---------------- */

.layui-btn {
  display: inline-block;
  height: 40px;
  padding: 0 20px;
  border: 0;
  border-radius: 7px;
  background: linear-gradient(100deg, #137b76, #159a8f);
  box-shadow: 0 5px 12px rgba(21, 123, 119, .16);
  color: #fff;
  font-family: inherit;
  font-size: 14px;
  font-weight: 700;
  line-height: 40px;
  text-align: center;
  cursor: pointer;
  transition: transform .18s, box-shadow .18s, filter .18s;
}

.layui-btn:hover { filter: brightness(.96); transform: translateY(-1px); box-shadow: 0 7px 15px rgba(21, 123, 119, .22); }
.layui-btn:disabled { opacity: .55; cursor: not-allowed; transform: none; filter: none; }

.layui-btn-block { display: block; width: 100%; height: 44px; line-height: 44px; }

.layui-btn-primary {
  border: 1px solid #add4ce;
  background: #fff;
  box-shadow: none;
  color: #156b64;
}

.layui-btn-primary:hover { background: #edf9f7; }

.layui-input-block .layui-btn + .layui-btn { margin-left: 8px; }

/* 扫码面板属于「登录方式」的取值区域，与输入框共用同一条左基准线；
   否则卡片会伸到左侧标签下方，和上面的输入框错位。 */
#panel-qr { margin-left: 108px; }

/* ---------------- 结果与提示 ---------------- */

.result, .qr-result { min-height: 24px; margin: 12px 0 0; color: #c0443b; font-size: 14px; line-height: 22px; }
.result.ok { color: #137b76; }

.lower-card {
  margin-top: 30px;
  min-height: 48px;
  border: 1px solid #dceae8;
  border-radius: 10px;
  background: #f8fcfb;
  box-shadow: none;
}

.claim-notice {
  margin: 0;
  padding: 15px 18px;
  border-left: 3px solid #d93025;
  color: #d93025;
  font-size: 13px;
  font-weight: 700;
  line-height: 22px;
}

.claim-notice p { margin: 0 0 6px; }
.claim-notice p:last-child { margin-bottom: 0; }

.notice-neutral { border-left-color: #159a8f; color: #2e4b4d; font-weight: 400; }

/* ---------------- 进度面板（提交页原地展开） ---------------- */

.task-block {
  margin-top: 26px;
  padding-top: 22px;
  border-top: 1px dashed #dceae8;
}

.task-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
  padding-bottom: 14px;
  border-bottom: 1px solid #e6f0ef;
}

.task-no { color: #137b76; font-size: 16px; font-weight: 800; letter-spacing: .02em; }

.badge {
  padding: 4px 12px;
  border: 1px solid #d4e2e0;
  border-radius: 20px;
  background: #f8fcfb;
  color: #567074;
  font-size: 12px;
  font-weight: 700;
}

.badge.checking, .badge.submitting { border-color: #9ec9c3; background: #edf9f7; color: #137b76; }
.badge.submitted { border-color: #8fd6c9; background: #e8f8f4; color: #0f7a68; }
.badge.failed, .badge.rejected { border-color: #f0c0bc; background: #fdf2f1; color: #c0443b; }

.kv { display: grid; grid-template-columns: 96px 1fr; gap: 10px 16px; margin: 20px 0 0; font-size: 14px; }
.kv dt { color: #8ba3a1; font-size: 13px; font-weight: 700; }
.kv dd { margin: 0; color: #203b3d; word-break: break-all; }

.timeline { margin: 22px 0 0; padding: 0 0 0 18px; border-left: 1px solid #dceae8; list-style: none; font-size: 13px; }
.timeline li { position: relative; padding: 0 0 14px; color: #567074; line-height: 1.55; }
.timeline li::before { position: absolute; top: 6px; left: -23px; width: 9px; height: 9px; border: 2px solid #fff; border-radius: 50%; background: #cfe0dd; content: ""; }
.timeline li.hot::before { background: #159a8f; }
.timeline li.bad::before { background: #d93025; }
.timeline time { margin-right: 8px; color: #a2b0b0; font-size: 12px; }

.empty-tip { padding: 60px 0; color: #a2b0b0; font-size: 14px; text-align: center; }

/* ---------------- 扫码（页面内） ---------------- */

.qr-hero {
  padding: 10px 0 22px;
  text-align: center;
}

.qr-hero-icon {
  display: inline-grid;
  place-items: center;
  width: 64px;
  height: 64px;
  border: 1px solid #ece5d8;
  border-radius: 16px;
  background: #faf7f1;
  color: #4a5f60;
}

.qr-hero-icon svg {
  width: 30px;
  height: 30px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.6;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.qr-hero-title { margin: 14px 0 6px; color: #203b3d; font-size: 16px; font-weight: 800; }
.qr-hero-sub { margin: 0; color: #8ba3a1; font-size: 12.5px; line-height: 1.75; }

.qr-stage { margin-bottom: 22px; text-align: center; }

.qr-box {
  display: inline-grid;
  place-items: center;
  padding: 14px;
  border: 1px solid #dceae8;
  border-radius: 12px;
  background: #fff;
}

.qr-box svg { width: 200px; height: 200px; }

.qr-status {
  margin: 12px 0 0;
  color: #2e4b4d;
  font-size: 13px;
  line-height: 1.6;
  text-align: center;
}

.qr-status.error { color: #c0443b; }

/* 结果查询：复用上方卡密，这里只做说明 */

.lookup-tip {
  margin-left: 108px;
  padding: 14px 16px;
  border: 1px solid #dceae8;
  border-radius: 10px;
  background: #f8fcfb;
  color: #567074;
  font-size: 13px;
  line-height: 1.7;
}

@media (max-width: 640px) {
  .lookup-tip { margin-left: 0; }
}

/* 确认位置三步指引 */

.qr-guide {
  padding: 0 0 6px;
  border: 1px solid #e8e4db;
  border-radius: 14px;
  background: #fff;
  box-shadow: 0 2px 10px rgba(20, 72, 70, .04);
  overflow: hidden;
  text-align: left;
}

.qr-guide-head {
  display: flex;
  align-items: center;
  gap: 11px;
  padding: 16px 18px 14px;
  border-bottom: 1px solid #f0ece4;
  background: #fdfcfa;
}

.qr-guide-icon {
  display: grid;
  place-items: center;
  width: 32px;
  height: 32px;
  flex: none;
  border-radius: 9px;
  background: #f6f0e4;
  color: #b08d54;
}

.qr-guide-icon svg {
  width: 17px;
  height: 17px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.7;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.qr-guide-texts { min-width: 0; }
.qr-guide-title { margin: 0 0 2px; color: #203b3d; font-size: 14.5px; font-weight: 800; line-height: 1.35; }
.qr-guide-sub { margin: 0; color: #93a3a2; font-size: 12px; line-height: 1.4; }

.qr-guide-list {
  display: flex;
  flex-direction: column;
  gap: 6px;
  margin: 0;
  padding: 12px;
  list-style: none;
}

.qr-guide-list li {
  display: flex;
  align-items: flex-start;
  gap: 11px;
  padding: 11px 13px;
  border-radius: 10px;
  transition: background .16s;
}

.qr-guide-list li.hl {
  background: #fbf6ec;
  box-shadow: inset 3px 0 0 #e2c288;
}

.qr-num {
  display: grid;
  place-items: center;
  width: 21px;
  height: 21px;
  flex: none;
  margin-top: 1px;
  border: 1px solid #dbe3e1;
  border-radius: 50%;
  background: #fff;
  color: #93a3a2;
  font-size: 11px;
  font-weight: 700;
  line-height: 1;
}

.qr-guide-list li.hl .qr-num {
  border-color: #e2c288;
  background: #fff;
  color: #a8823f;
}

.qr-step { display: flex; flex-direction: column; gap: 3px; min-width: 0; }
.qr-q { color: #8a9b9a; font-size: 12.5px; line-height: 1.45; }
.qr-a { color: #1d3537; font-size: 13.5px; font-weight: 700; line-height: 1.45; }

/* ---------------- 弹窗基础（确认框使用） ---------------- */

.qr-modal {
  position: fixed;
  inset: 0;
  z-index: 9000;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
  background: rgba(8, 30, 30, .55);
}

.qr-modal[hidden] { display: none; }

.qr-head {
  position: relative;
  margin-bottom: 16px;
}

.qr-head strong { color: #103035; font-size: 15px; font-weight: 800; }

.qr-close {
  position: absolute;
  top: -6px;
  right: -6px;
  width: 30px;
  height: 30px;
  border: 0;
  border-radius: 50%;
  background: #f1f7f6;
  color: #6b8a88;
  font-size: 18px;
  line-height: 1;
  cursor: pointer;
  transition: background .16s, color .16s;
}

.qr-close:hover { background: #e2efed; color: #137b76; }

/* Steam 令牌弹窗 */

.token-panel { width: min(380px, 100%); }
.token-panel .confirm-body { margin-bottom: 14px; }

.token-input {
  height: 46px;
  padding: 0 14px;
  border: 1px solid #d4e2e0;
  border-radius: 8px;
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: 18px;
  font-weight: 700;
  letter-spacing: .32em;
  text-align: center;
  text-transform: uppercase;
}

.token-input:focus { border-color: #159a8f; box-shadow: 0 0 0 3px rgba(21, 154, 143, .12); }

.token-input::placeholder {
  color: #b6c4c2;
  font-size: 13px;
  font-weight: 400;
  letter-spacing: 0;
}

.token-panel .result { margin: 10px 0 0; font-size: 12.5px; }

/* ---------------- 提交前确认 ---------------- */

.confirm-panel {
  width: min(460px, 100%);
  padding: 24px 26px 22px;
  border-radius: 14px;
  background: #fff;
  box-shadow: 0 24px 60px rgba(10, 45, 44, .28);
  text-align: left;
}

.confirm-panel .qr-head { margin-bottom: 14px; text-align: left; }
.confirm-panel .qr-head strong { color: #103035; font-size: 17px; }
.confirm-panel .qr-close { top: -2px; right: -4px; }

.confirm-body {
  margin: 0 0 22px;
  color: #44595c;
  font-size: 13.5px;
  line-height: 1.75;
}

.confirm-actions { display: flex; gap: 12px; }

.confirm-actions .layui-btn {
  flex: 1;
  height: 44px;
  line-height: 44px;
  font-size: 14px;
}

.confirm-actions .layui-btn:disabled {
  background: linear-gradient(100deg, #6fa9a4, #7fbcb3);
  box-shadow: none;
  opacity: .75;
  cursor: not-allowed;
  transform: none;
}

/* ---------------- 页脚 ---------------- */

.foot {
  padding: 16px 42px 4px;
  color: #8ba3a1;
  font-size: 12px;
  line-height: 1.7;
  text-align: center;
}

.foot strong { color: #d93025; font-weight: 700; }

/* ---------------- 响应式 ---------------- */

@media (max-width: 640px) {
  body { padding: 14px 0 24px; }
  #app { width: calc(100% - 20px); }
  .brand-bar { padding: 14px 0 0; }
  .layui-tab-card > .layui-tab-title { height: 54px; padding: 0 6px; }
  .layui-tab-card > .layui-tab-title li { height: 54px; font-size: 12.5px; line-height: 54px; padding: 0 4px; }
  .layui-tab-content { padding: 20px 18px 26px; }
  /* 窄屏下标签回到正常流，堆在输入框上方 */
  .layui-form-label { position: static; display: block; width: auto; padding: 0 0 8px; line-height: 1.5; text-align: left; }
  .layui-input-block { margin-left: 0; }
  #panel-qr { margin-left: 0; }
  .kv { grid-template-columns: 1fr; gap: 2px; }
  .kv dd { margin-bottom: 10px; }
  .foot { padding: 14px 18px 0; }
}
