/* 南陵人大「建言献策」统一样式 */
* { box-sizing: border-box; margin: 0; padding: 0; }

body {
  font-family: "PingFang SC", "Microsoft YaHei", "Hiragino Sans GB", sans-serif;
  background: #f4f5f7;
  color: #333;
  line-height: 1.6;
}

/* 国徽红 */
:root { --red: #c0272d; }

/* ---------- 群众填写页 / 登录页 ---------- */
body.public {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 16px;
  background: linear-gradient(180deg, #f8f8f8, #eef0f3);
}

.card {
  width: 100%;
  max-width: 560px;
  background: #fff;
  border-radius: 12px;
  padding: 28px 24px;
  box-shadow: 0 4px 20px rgba(0, 0, 0, .06);
}

.card.center { text-align: center; }

.guohui { display: block; width: 64px; height: 64px; margin: 0 auto 8px; }

h1 { font-size: 22px; text-align: center; color: var(--red); }
.sub { text-align: center; color: #888; font-size: 14px; margin: 6px 0 18px; }

label { display: block; font-size: 14px; color: #444; margin: 16px 0 6px; }
.req { color: var(--red); }

input[type="text"], input[type="password"], textarea, select {
  width: 100%;
  border: 1px solid #d9d9d9;
  border-radius: 6px;
  padding: 10px 12px;
  font-size: 15px;
  font-family: inherit;
  background: #fff;
}
input:focus, textarea:focus, select:focus {
  outline: none;
  border-color: var(--red);
  box-shadow: 0 0 0 2px rgba(192, 39, 45, .12);
}
textarea { resize: vertical; }

.hint { font-size: 12px; color: #999; margin-top: 4px; }

button, .btn {
  display: inline-block;
  background: var(--red);
  color: #fff;
  border: none;
  border-radius: 6px;
  padding: 11px 20px;
  font-size: 15px;
  cursor: pointer;
  text-decoration: none;
  font-family: inherit;
}
button:hover, .btn:hover { background: #a31f24; }

.card form button { width: 100%; margin-top: 22px; }

.btn-link {
  display: inline-block;
  margin-top: 18px;
  color: var(--red);
  text-decoration: none;
  font-size: 15px;
}

.foot { text-align: center; color: #aaa; font-size: 12px; margin-top: 18px; }

.check {
  width: 60px; height: 60px; line-height: 60px;
  border-radius: 50%; background: #2e9e4f; color: #fff;
  font-size: 30px; margin: 0 auto 12px;
}

.flash { padding: 10px 12px; border-radius: 6px; margin-bottom: 12px; font-size: 14px; }
.flash.error { background: #fdecea; color: #b71c1c; }
.flash.ok { background: #e8f5e9; color: #1b5e20; }

/* ---------- 后台 ---------- */
body.admin { min-height: 100vh; }

.topbar {
  background: var(--red);
  color: #fff;
  padding: 14px 24px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 10px;
}
.topbar .title { font-size: 17px; font-weight: 600; }
.topbar .actions { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.stats { font-size: 13px; opacity: .95; }

body.admin .btn { background: #fff; color: var(--red); }
body.admin .btn:hover { background: #f3f3f3; }
body.admin .btn-ghost { background: transparent; color: #fff; border: 1px solid rgba(255,255,255,.6); }
body.admin .btn-ghost:hover { background: rgba(255,255,255,.15); }
.btn-small { padding: 5px 12px; font-size: 13px; }

main { padding: 24px; max-width: 1100px; margin: 0 auto; }

.filters { display: flex; gap: 10px; margin-bottom: 18px; flex-wrap: wrap; }
.filters input[type="text"] { flex: 1; min-width: 220px; }
.filters select { width: auto; }

.table { width: 100%; border-collapse: collapse; background: #fff; border-radius: 8px; overflow: hidden; box-shadow: 0 2px 8px rgba(0,0,0,.05); }
.table th, .table td { padding: 12px 14px; text-align: left; border-bottom: 1px solid #eee; font-size: 14px; }
.table th { background: #fafafa; color: #666; font-weight: 600; }
.table tr:hover td { background: #fafafa; }
.ellipsis { max-width: 260px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.empty { text-align: center; color: #999; padding: 30px 0 !important; }

.tag { display: inline-block; padding: 3px 10px; border-radius: 20px; font-size: 12px; }
.tag.pending { background: #fff4e5; color: #b26a00; }
.tag.done { background: #e8f5e9; color: #1b5e20; }

.detail { background: #fff; border-radius: 8px; padding: 20px; box-shadow: 0 2px 8px rgba(0,0,0,.05); margin-bottom: 20px; }
.detail .field { display: flex; padding: 10px 0; border-bottom: 1px solid #f0f0f0; font-size: 14px; }
.detail .field:last-child { border-bottom: none; }
.detail .label { width: 160px; flex-shrink: 0; color: #888; }
.detail .value { color: #333; }
.detail .value.block { white-space: pre-wrap; }

.feedback-form { background: #fff; border-radius: 8px; padding: 20px; box-shadow: 0 2px 8px rgba(0,0,0,.05); }
.feedback-form label { margin-top: 0; margin-bottom: 8px; font-weight: 600; }
.feedback-form textarea { margin-bottom: 12px; }
