/* ==========================================================================
   码上巡 · 移动端样式
   --------------------------------------------------------------------------
   目录：
     0. 变量 / 基础重置
     1. 手机外壳
     2. 首页
     3. 表单页（导航 / 提示卡 / 分组 / 表单行 / 上传 / 按钮）
     4. 成功页 / 错误页
     5. 后台（登录页 / 列表 / 详情页）
   ========================================================================== */

/* ---------- 0. 变量 / 基础重置 ---------- */
:root {
  --red: #c2201a;
  --red-light: #d9342c;
  --red-badge: #e0392f;
  --blue: #1a6fd4;
  --blue-light: #3b95f2;
  --bg: #eaf3fd;
  --bg-deep: #dceafa;
  --card: #ffffff;
  --text: #333333;
  --text-sub: #6b7683;
  --text-tip: #5b6672;
  --placeholder: #bcc4cd;
  --line: #f0f3f7;
  --radius: 12px;
  --shadow-card: 0 3px 10px rgba(30, 90, 160, .08);
}

*,
*::before,
*::after { box-sizing: border-box; -webkit-tap-highlight-color: transparent; }

html, body { margin: 0; padding: 0; }

body {
  font-family: "PingFang SC", "Microsoft YaHei", "Helvetica Neue", Arial, sans-serif;
  color: var(--text);
  font-size: 15px;
  line-height: 1.6;
  background: #cfdfef;
  -webkit-font-smoothing: antialiased;
}

img { display: block; max-width: 100%; border: 0; }
a { color: inherit; text-decoration: none; }
button, input, select, textarea { font-family: inherit; }
.is-hidden { display: none !important; }


/* ---------- 1. 手机外壳 ---------- */
.phone {
  position: relative;
  width: 100%;
  max-width: 480px;
  min-height: 100vh;
  margin: 0 auto;
  background: var(--bg);
  overflow: hidden;
  box-shadow: 0 0 26px rgba(20, 60, 110, .12);
}

body.page-report .phone {
  background: linear-gradient(180deg, #eaf3fd 0%, #dceafa 60%, #e8f2fc 100%);
}


/* ==========================================================================
   2. 首页
   ========================================================================== */

/* ---- 2.1 顶部红色异形区 ---- */
.hero {
  position: relative;
  padding: 0 0 22px;
}

.hero-bg {
  position: absolute;
  left: 0; right: 0; top: 0;
  height: 330px;
  overflow: hidden;
  z-index: 0;
  pointer-events: none;
}

/* 外层浅蓝，露出左右两翼 */
.hero-bg .shape-blue {
  position: absolute;
  left: -6%; right: -6%; top: -20px;
  height: 310px;
  background: linear-gradient(180deg, #c3dcf7 0%, #dcecfb 100%);
  clip-path: polygon(0 0, 100% 0, 100% 66%, 50% 100%, 0 66%);
}

/* 内层红色，压在上面形成向下的楔形 */
.hero-bg .shape-red {
  position: absolute;
  left: -6%; right: -6%; top: -20px;
  height: 262px;
  background: linear-gradient(180deg, #d9342c 0%, #c2201a 100%);
  clip-path: polygon(0 0, 100% 0, 100% 58%, 50% 100%, 0 58%);
}

.hero-title {
  position: relative;
  z-index: 2;
  margin: 0;
  padding: 14px 0 20px;
  text-align: center;
  color: #fff;
  font-size: 22px;
  font-weight: 800;
  letter-spacing: 5px;
  text-shadow: 0 2px 4px rgba(120, 20, 15, .35);
}

.banner {
  position: relative;
  z-index: 2;
  margin: 0 22px;
  border-radius: 10px;
  overflow: hidden;
  background: #dfe9f3;
  box-shadow: 0 8px 18px rgba(80, 30, 20, .25);
}

.banner img {
  width: 100%;
  height: 156px;
  object-fit: cover;
}

/* ---- 2.2 内容区 ---- */
.body {
  position: relative;
  z-index: 2;
  padding: 0 12px 120px;
}

/* 红色胶囊标签 */
.badge {
  display: block;
  width: max-content;
  max-width: 90%;
  margin: 16px auto 10px;
  padding: 6px 22px;
  border-radius: 8px;
  background: linear-gradient(180deg, #e0392f 0%, #c2201a 100%);
  color: #fff;
  font-size: 16px;
  font-weight: 700;
  letter-spacing: 2px;
  box-shadow: 0 4px 10px rgba(194, 32, 26, .32),
              inset 0 0 0 1px rgba(255, 255, 255, .28);
}

.card {
  background: var(--card);
  border-radius: var(--radius);
  padding: 16px;
  margin-bottom: 14px;
  box-shadow: var(--shadow-card);
}

.intro-text {
  margin: 0;
  font-size: 15px;
  line-height: 1.95;
  text-align: justify;
  color: var(--text);
}

/* ---- 2.3 入口卡片 ---- */
.entry-card {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 18px 16px;
  transition: transform .15s, box-shadow .15s;
}

.entry-card:active {
  transform: scale(.985);
  box-shadow: 0 2px 6px rgba(30, 90, 160, .12);
}

.entry-icon {
  flex: none;
  width: 60px;
  height: 60px;
}

.entry-title {
  font-size: 23px;
  font-weight: 800;
  color: var(--blue);
  letter-spacing: 2px;
}

.entry-sub {
  margin-top: 2px;
  font-size: 14px;
  color: var(--text-sub);
  letter-spacing: 1px;
}

/* ---- 2.4 底部山形装饰 ---- */
.mountains {
  position: absolute;
  left: 0; right: 0; bottom: 0;
  z-index: 1;
  pointer-events: none;
  line-height: 0;
}

.mountains img { width: 100%; }


/* ==========================================================================
   3. 表单页
   ========================================================================== */

/* ---- 3.1 顶部导航 ---- */
.nav {
  position: sticky;
  top: 0;
  z-index: 20;
  display: flex;
  align-items: center;
  justify-content: center;
  height: 48px;
  background: linear-gradient(180deg, #d9342c 0%, #c2201a 100%);
  color: #fff;
  box-shadow: 0 2px 8px rgba(150, 25, 20, .22);
}

.nav-title {
  font-size: 18px;
  font-weight: 700;
  letter-spacing: 3px;
}

.nav-back {
  position: absolute;
  left: 2px; top: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 44px; height: 48px;
}

.nav-back svg { width: 22px; height: 22px; }

/* ---- 3.2 橙色提示卡 ---- */
.notice {
  margin: 12px 12px 0;
  padding: 14px 16px 16px;
  border-radius: var(--radius);
  background: linear-gradient(160deg, #f8d38d 0%, #f0b45c 55%, #e8a747 100%);
  color: #fff;
  box-shadow: 0 6px 16px rgba(200, 140, 40, .28);
}

.notice-badges {
  display: flex;
  justify-content: center;
  gap: 8px;
  margin-bottom: 10px;
}

.notice-badge {
  padding: 3px 14px;
  border-radius: 7px;
  background: linear-gradient(180deg, #f07256 0%, #df4a33 100%);
  font-size: 13px;
  font-weight: 600;
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .38);
}

.notice-org {
  margin: 0 0 10px;
  text-align: center;
  font-size: 17px;
  font-weight: 800;
  letter-spacing: 2px;
  text-shadow: 0 1px 2px rgba(150, 95, 20, .3);
}

.notice-p {
  margin: 0 0 8px;
  font-size: 13px;
  line-height: 1.9;
  text-align: justify;
  text-shadow: 0 1px 1px rgba(150, 95, 20, .22);
}

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

/* ---- 3.3 分组标题 ---- */
.section-title {
  margin: 20px 0 10px;
  text-align: center;
  font-size: 16px;
  font-weight: 700;
  color: var(--blue);
  letter-spacing: 1px;
}

/* ---- 3.4 表单卡片 ---- */
.form-card {
  margin: 0 12px;
  padding: 2px 16px;
  border-radius: 10px;
  background: #fff;
  box-shadow: var(--shadow-card);
}

/* 单选行 */
.radio-row {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 56px;
  padding: 15px 0;
}

.radio {
  position: relative;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 15px;
  color: var(--text);
  cursor: pointer;
  user-select: none;
}

.radio input {
  position: absolute;
  width: 0; height: 0;
  opacity: 0;
  margin: 0;
}

.radio .dot {
  position: relative;
  flex: none;
  width: 19px; height: 19px;
  border: 1px solid #c2c9d2;
  border-radius: 50%;
  background: #fff;
  transition: background .15s, border-color .15s;
}

.radio input:checked + .dot {
  background: var(--blue);
  border-color: var(--blue);
}

.radio input:checked + .dot::after {
  content: "";
  position: absolute;
  left: 6px; top: 2px;
  width: 4px; height: 9px;
  border: solid #fff;
  border-width: 0 2px 2px 0;
  transform: rotate(45deg);
}

/* 输入行 */
.field-group { border-top: 1px solid var(--line); }

.field {
  display: flex;
  align-items: center;
  min-height: 48px;
  border-bottom: 1px solid var(--line);
}

.field:last-child { border-bottom: 0; }

.field-label {
  flex: none;
  width: 110px;
  font-size: 15px;
  color: var(--text);
  white-space: nowrap;
}

.field.required .field-label::before {
  content: "*";
  margin-right: 3px;
  color: var(--blue);
}

.field input,
.field select {
  flex: 1;
  min-width: 0;
  padding: 11px 0;
  border: 0;
  outline: 0;
  background: transparent;
  font-size: 15px;
  color: var(--text);
}

.field input::placeholder { color: var(--placeholder); }

.field select {
  color: var(--placeholder);
  appearance: none;
  -webkit-appearance: none;
  background-image: url("data:image/svg+xml;charset=utf8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 12 8'%3E%3Cpath d='M1 1l5 5 5-5' fill='none' stroke='%23bcc4cd' stroke-width='1.6' stroke-linecap='round'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 2px center;
  background-size: 11px;
  padding-right: 20px;
}

.field select.has-value { color: var(--text); }

/* ---- 3.5 反映内容 ---- */
.textarea-card { padding: 12px 16px 6px; }

.textarea-card textarea {
  display: block;
  width: 100%;
  min-height: 96px;
  padding: 0;
  border: 0;
  outline: 0;
  resize: none;
  background: transparent;
  font-size: 15px;
  line-height: 1.75;
  color: var(--text);
}

.textarea-card textarea::placeholder { color: var(--placeholder); }

.counter {
  padding-bottom: 6px;
  text-align: right;
  font-size: 12px;
  color: #9aa3ad;
}

/* ---- 3.6 上传 ---- */
.upload-card { padding: 14px 16px; }

.upload-box {
  display: flex;
  align-items: center;
  justify-content: center;
  height: 104px;
  border-radius: 8px;
  background: #e9eef5;
  cursor: pointer;
  transition: background .15s;
}

.upload-box:active { background: #e0e7f0; }

.upload-box svg {
  width: 46px;
  height: 36px;
  color: #ffffff;
  filter: drop-shadow(0 1px 2px rgba(120, 140, 165, .45));
}

.upload-list { margin-top: 6px; }

.upload-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding: 7px 0;
  border-top: 1px dashed #eef1f5;
  font-size: 13px;
  color: var(--text-tip);
}

.upload-item .upload-name {
  flex: 1;
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.upload-item .upload-size { flex: none; color: #9aa3ad; }

.upload-tip {
  margin: 10px 16px 0;
  font-size: 13px;
  line-height: 1.85;
  color: var(--text-tip);
  text-align: justify;
}

/* ---- 3.7 提交按钮 ---- */
.btn-submit {
  display: block;
  width: calc(100% - 32px);
  height: 46px;
  margin: 20px auto 34px;
  border: 0;
  border-radius: 23px;
  background: linear-gradient(90deg, var(--blue-light) 0%, var(--blue) 100%);
  color: #fff;
  font-size: 16px;
  font-weight: 700;
  letter-spacing: 4px;
  cursor: pointer;
  box-shadow: 0 7px 16px rgba(26, 111, 212, .34);
  transition: transform .12s, box-shadow .12s, opacity .12s;
}

.btn-submit:active {
  transform: translateY(1px);
  box-shadow: 0 4px 10px rgba(26, 111, 212, .28);
}

.btn-submit:disabled {
  opacity: .62;
  cursor: not-allowed;
  box-shadow: none;
}

/* ---- 3.8 错误提示 ---- */
.errors {
  margin: 12px 12px 0;
  padding: 10px 14px;
  border: 1px solid #ffd9d3;
  border-radius: 10px;
  background: #fff5f3;
  color: #d0442f;
  font-size: 13px;
}

.errors ul { margin: 0; padding-left: 18px; }
.errors li { line-height: 1.9; }


/* ==========================================================================
   4. 成功页 / 错误页 / 后台
   ========================================================================== */
.result-wrap {
  padding: 60px 24px 40px;
  text-align: center;
}

.result-icon {
  width: 76px; height: 76px;
  margin: 0 auto 20px;
  border-radius: 50%;
  background: linear-gradient(180deg, #52c98a 0%, #2fa96b 100%);
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 8px 18px rgba(47, 169, 107, .3);
}

.result-icon svg { width: 38px; height: 38px; }
.result-icon.warn { background: linear-gradient(180deg, #f5a623 0%, #e08c10 100%); box-shadow: 0 8px 18px rgba(224, 140, 16, .3); }

.result-title {
  margin: 0 0 10px;
  font-size: 20px;
  font-weight: 700;
  color: #2b3440;
}

.result-text {
  margin: 0 0 6px;
  font-size: 14px;
  color: var(--text-sub);
  line-height: 1.9;
}

.result-no {
  display: inline-block;
  margin: 14px 0 26px;
  padding: 8px 18px;
  border-radius: 8px;
  background: #eaf3fd;
  color: var(--blue);
  font-size: 14px;
  font-weight: 600;
  letter-spacing: 1px;
}

.btn-plain {
  display: inline-block;
  height: 42px;
  padding: 0 34px;
  border: 0;
  border-radius: 21px;
  background: linear-gradient(90deg, var(--blue-light) 0%, var(--blue) 100%);
  color: #fff;
  font-size: 15px;
  line-height: 42px;
  font-weight: 600;
  box-shadow: 0 6px 14px rgba(26, 111, 212, .3);
}

/* ---- 后台 ---- */
.admin {
  max-width: 1180px;
  margin: 0 auto;
  padding: 22px 18px 60px;
  background: #fff;
  min-height: 100vh;
}

.admin h1 {
  margin: 0 0 4px;
  font-size: 20px;
  color: #22303f;
}

.admin .admin-sub {
  margin: 0 0 18px;
  font-size: 13px;
  color: #8b96a3;
}

.admin .admin-bar {
  display: flex;
  gap: 10px;
  margin-bottom: 14px;
}

.admin .admin-bar a {
  padding: 7px 16px;
  border-radius: 6px;
  background: #eaf3fd;
  color: var(--blue);
  font-size: 13px;
  font-weight: 600;
}

.admin table {
  width: 100%;
  border-collapse: collapse;
  font-size: 13px;
}

.admin th,
.admin td {
  padding: 9px 10px;
  border: 1px solid #e9eef4;
  text-align: left;
  vertical-align: top;
}

.admin th {
  background: #f5f8fc;
  color: #4a5a6b;
  font-weight: 600;
  white-space: nowrap;
}

.admin td.content-cell {
  max-width: 380px;
  white-space: pre-wrap;
  word-break: break-all;
}

.admin tr:nth-child(even) td { background: #fbfcfe; }

.admin .empty {
  padding: 60px 0;
  text-align: center;
  color: #9aa3ad;
  font-size: 14px;
}

.admin .file-link {
  display: inline-block;
  margin: 2px 4px 2px 0;
  color: var(--blue);
  text-decoration: underline;
}

/* ---- 后台：额外样式 ---- */
.admin .admin-file {
  margin-left: 8px;
  color: #a8b1bb;
}

.admin .admin-bar { flex-wrap: wrap; }

.admin .admin-bar a.danger {
  background: #fdecec;
  color: #d0442f;
}

.admin .dim { color: #8b96a3; }
.admin .nowrap { white-space: nowrap; }

.admin td.no-cell a,
.admin a.link-view {
  color: var(--blue);
  text-decoration: underline;
  font-weight: 600;
}

.admin .detail-title {
  margin: 26px 0 10px;
  padding-left: 9px;
  border-left: 3px solid var(--blue);
  font-size: 15px;
  color: #22303f;
}

.admin table.kv {
  width: 100%;
  max-width: 820px;
  border-collapse: collapse;
  font-size: 14px;
}

.admin table.kv th {
  width: 132px;
  padding: 10px 12px;
  background: #f5f8fc;
  border: 1px solid #e9eef4;
  color: #4a5a6b;
  font-weight: 600;
  white-space: nowrap;
  text-align: left;
  vertical-align: top;
}

.admin table.kv td {
  padding: 10px 12px;
  border: 1px solid #e9eef4;
  color: #22303f;
  word-break: break-word;
}

.admin table.files-table {
  width: 100%;
  max-width: 820px;
  border-collapse: collapse;
  font-size: 14px;
}

.admin table.files-table th,
.admin table.files-table td {
  padding: 9px 12px;
  border: 1px solid #e9eef4;
  text-align: left;
  vertical-align: top;
}

.admin table.files-table th {
  background: #f5f8fc;
  color: #4a5a6b;
  font-weight: 600;
  white-space: nowrap;
}

.admin .detail-content {
  max-width: 820px;
  padding: 14px 16px;
  border: 1px solid #e9eef4;
  border-radius: 8px;
  background: #fbfcfe;
  font-size: 14px;
  line-height: 1.9;
  color: #22303f;
  white-space: pre-wrap;
  word-break: break-word;
}

.admin .detail-tip,
.admin .detail-foot {
  max-width: 820px;
  margin: 10px 0 0;
  font-size: 13px;
  line-height: 1.8;
  color: #8b96a3;
}

/* ---- 后台登录页 ---- */
.page-login {
  background: linear-gradient(160deg, #eaf3fd 0%, #f5f8fc 60%, #fff 100%);
}

.login-wrap {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 100vh;
  padding: 24px;
}

.login-card {
  width: 100%;
  max-width: 340px;
  padding: 32px 26px 26px;
  background: #fff;
  border-radius: 14px;
  box-shadow: 0 10px 34px rgba(30, 90, 160, .16);
  text-align: center;
}

.login-icon {
  width: 54px;
  height: 54px;
  margin: 0 auto 14px;
  padding: 13px;
  box-sizing: border-box;
  border-radius: 50%;
  background: linear-gradient(135deg, #3b95f2 0%, #1a6fd4 100%);
  color: #fff;
}

.login-icon svg { width: 100%; height: 100%; }

.login-card h1 {
  margin: 0 0 6px;
  font-size: 19px;
  color: #22303f;
}

.login-card .login-sub {
  margin: 0 0 18px;
  font-size: 13px;
  color: #8b96a3;
}

.login-card .login-error {
  margin: 0 0 14px;
  padding: 9px 12px;
  border-radius: 6px;
  background: #fdecec;
  border: 1px solid #f7c9c9;
  color: #d0442f;
  font-size: 13px;
}

.login-card input[type="password"] {
  width: 100%;
  box-sizing: border-box;
  padding: 12px 14px;
  margin-bottom: 14px;
  border: 1px solid #dde5ee;
  border-radius: 8px;
  font-size: 15px;
  outline: 0;
  background: #fbfcfe;
  color: #22303f;
}

.login-card input[type="password"]:focus {
  border-color: #9cc7f5;
  background: #fff;
}

.login-card button {
  width: 100%;
  padding: 12px 0;
  border: 0;
  border-radius: 8px;
  background: linear-gradient(90deg, #3b95f2 0%, #1a6fd4 100%);
  color: #fff;
  font-size: 15px;
  font-weight: 600;
  letter-spacing: 2px;
  cursor: pointer;
  box-shadow: 0 6px 14px rgba(26, 111, 212, .28);
}

.login-card .login-back {
  display: inline-block;
  margin-top: 18px;
  font-size: 13px;
  color: #8b96a3;
}
