/* lostfound 两页共用样式：纯本地、无外部字体 / CDN / 图片 */

* { box-sizing: border-box; }

:root {
  --bg: #f5f6f8;
  --card: #ffffff;
  --ink: #1f2329;
  --muted: #6b7280;
  --line: #e5e7eb;
  --accent: #2f6feb;
  --accent-ink: #ffffff;
  --ok-bg: #eaf6ee;
  --ok-ink: #1a7f43;
  --err-bg: #fdecec;
  --err-ink: #c0392b;
}

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

body {
  background: var(--bg);
  color: var(--ink);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC",
               "Hiragino Sans GB", "Microsoft YaHei", "Helvetica Neue", Arial, sans-serif;
  font-size: 16px;
  line-height: 1.6;
  -webkit-text-size-adjust: 100%;
}

.wrap {
  max-width: 640px;
  margin: 0 auto;
  padding: 20px 16px 48px;
}

h1 {
  font-size: 1.35rem;
  line-height: 1.35;
  font-weight: 700;
  letter-spacing: .3px;
  margin: 4px 0 16px;
}

h2 { font-size: 1.05rem; margin: 0 0 4px; }

.privacy {
  background: #eef2f8;
  border: 1px solid #dbe4f3;
  color: #40506b;
  border-radius: 10px;
  padding: 10px 12px;
  font-size: .85rem;
  line-height: 1.65;
  margin: 0 0 20px;
}

.hint {
  font-size: .8rem;
  color: var(--muted);
  margin: 6px 0 12px;
}

.field { margin: 0 0 18px; min-width: 0; }

label {
  display: block;
  font-size: .9rem;
  font-weight: 600;
  color: #374151;
  margin: 0 0 6px;
}

input[type="text"],
input[type="password"],
select,
textarea {
  width: 100%;
  max-width: 100%;
  font: inherit;
  color: var(--ink);
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: 10px;
  padding: 10px 12px;
  outline: none;
}

input:focus, select:focus, textarea:focus {
  border-color: var(--accent);
  box-shadow: 0 0 0 3px rgba(47, 111, 235, .12);
}

textarea {
  resize: vertical;
  min-height: 120px;
  line-height: 1.6;
}

select:disabled {
  background: #f3f4f6;
  color: #9ca3af;
}

.btn {
  font: inherit;
  font-size: .95rem;
  font-weight: 600;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: var(--card);
  color: var(--ink);
  padding: 10px 16px;
  min-height: 44px;
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
}

.btn:active { transform: translateY(1px); }
.btn:disabled { opacity: .55; cursor: default; }

.btn-primary {
  background: var(--accent);
  border-color: var(--accent);
  color: var(--accent-ink);
}

.btn-ghost { background: var(--card); }

.btn-del {
  color: var(--err-ink);
  border-color: #f0c9c9;
  background: var(--card);
  padding: 6px 12px;
  min-height: 36px;
  font-size: .85rem;
}

.actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin: 6px 0 18px;
}

#add-item { margin-top: 4px; }

.item {
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 12px;
  margin: 0 0 12px;
  min-width: 0;
}

.item-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  margin-bottom: 10px;
}

.item-label {
  font-size: .85rem;
  font-weight: 700;
  color: var(--muted);
}

.field-inline label {
  font-size: .82rem;
  font-weight: 600;
  color: #374151;
  margin-bottom: 4px;
}

.item textarea { min-height: 130px; }

.notice {
  margin: 0 0 12px;
  font-size: .9rem;
  border-radius: 8px;
}

.notice:empty { display: none; }
.notice-ok { background: var(--ok-bg); color: var(--ok-ink); padding: 10px 12px; }
.notice-err { background: var(--err-bg); color: var(--err-ink); padding: 10px 12px; }

.report {
  margin-top: 28px;
  padding-top: 20px;
  border-top: 1px dashed var(--line);
}

.report textarea { min-height: 90px; }

.seg {
  display: inline-flex;
  border: 1px solid var(--line);
  border-radius: 10px;
  overflow: hidden;
}

.seg .btn {
  border: 0;
  border-radius: 0;
  border-right: 1px solid var(--line);
}

.seg .btn:last-child { border-right: 0; }
.seg .btn.is-active { background: var(--accent); color: var(--accent-ink); }

.export {
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 14px;
  margin: 8px 0 0;
  white-space: pre-wrap;
  word-wrap: break-word;
  overflow-wrap: anywhere;
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, "Courier New", monospace;
  font-size: .85rem;
  line-height: 1.65;
  color: #2b3038;
  min-height: 120px;
  max-height: 60vh;
  overflow: auto;
}

.foot { margin-top: 28px; font-size: .85rem; }
.foot a { color: var(--accent); text-decoration: none; }

@media (max-width: 400px) {
  .wrap { padding: 16px 12px 40px; }
  .actions .btn { flex: 1 1 auto; }
}
