/* 与 App 相近：stone 中性色、留白、圆角 */
:root {
  --bg: #fafaf9;
  --surface: #ffffff;
  --text: #1c1917;
  --muted: #78716c;
  --border: #e7e5e4;
  --accent: #1c1917;
  --radius: 1rem;
  --font: ui-sans-serif, system-ui, -apple-system, 'Segoe UI', Roboto,
    'PingFang SC', 'Microsoft YaHei', sans-serif;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

body {
  margin: 0;
  min-height: 100vh;
  font-family: var(--font);
  font-size: 15px;
  line-height: 1.55;
  color: var(--text);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
}

.wrap {
  max-width: 32rem;
  margin: 0 auto;
  padding: 2.5rem 1.25rem 4rem;
}

.hero {
  margin-bottom: 2rem;
}

.eyebrow {
  margin: 0 0 0.35rem;
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--muted);
}

h1 {
  margin: 0 0 0.5rem;
  font-size: 1.875rem;
  font-weight: 600;
  letter-spacing: -0.02em;
}

.lede {
  margin: 0;
  font-size: 0.9rem;
  color: var(--muted);
}

.lede code {
  font-size: 0.8em;
  padding: 0.1em 0.35em;
  border-radius: 0.35rem;
  background: #f5f5f4;
  color: #44403c;
}

.panel {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.25rem;
  box-shadow: 0 1px 2px rgba(28, 25, 23, 0.04);
}

.panel-title {
  margin: 0 0 1rem;
  font-size: 1.05rem;
  font-weight: 600;
  color: var(--text);
}

.admin-section {
  margin-bottom: 1.25rem;
}

.admin-off {
  margin: 0 0 1rem;
  padding: 0.85rem 1rem;
  font-size: 0.85rem;
  color: #92400e;
  background: #fffbeb;
  border: 1px solid #fde68a;
  border-radius: var(--radius);
}

.admin-off code {
  font-size: 0.85em;
  padding: 0.1em 0.3em;
  background: #fef3c7;
  border-radius: 0.3rem;
}

.admin-card {
  margin-bottom: 0.75rem;
}

.admin-heading {
  margin: 0 0 0.35rem;
  font-size: 1.1rem;
  font-weight: 600;
}

.admin-lede {
  margin: 0 0 1rem;
  font-size: 0.85rem;
  color: var(--muted);
  line-height: 1.5;
}

.admin-lede code {
  font-size: 0.8em;
  padding: 0.1em 0.35em;
  border-radius: 0.35rem;
  background: #f5f5f4;
}

.admin-sub {
  margin: 0.25rem 0 0;
  font-size: 0.8rem;
  color: var(--muted);
}

.admin-panel-head {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-start;
  justify-content: space-between;
  gap: 0.75rem;
  margin-bottom: 1.25rem;
  padding-bottom: 1rem;
  border-bottom: 1px solid var(--border);
}

.btn-outline {
  font: inherit;
  font-size: 0.875rem;
  font-weight: 500;
  padding: 0.45rem 0.9rem;
  color: #44403c;
  background: #fff;
  border: 1px solid var(--border);
  border-radius: 0.75rem;
  cursor: pointer;
  flex-shrink: 0;
}

.btn-outline:hover {
  background: #fafaf9;
}

.stack-form {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.upload-form-inner {
  margin: 0;
  padding: 0;
  border: none;
}

.upload-form-inner .upload-hint {
  margin: -0.25rem 0 0.25rem;
  font-size: 0.78rem;
  line-height: 1.45;
  color: var(--muted);
}

.upload-form-inner .upload-hint code {
  font-size: 0.85em;
  padding: 0.08em 0.3em;
  border-radius: 0.3rem;
  background: #f5f5f4;
  color: #44403c;
}

.loading,
.error {
  margin: 0;
  font-size: 0.9rem;
  color: var(--muted);
}

.error {
  color: #b91c1c;
}

.hidden {
  display: none !important;
}

.list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.item {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  padding: 1rem;
  border: 1px solid var(--border);
  border-radius: 0.75rem;
  background: #fafaf9;
}

.item-top {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  justify-content: space-between;
  gap: 0.5rem;
}

.file-line {
  margin: 0;
  font-size: 0.75rem;
  color: var(--muted);
  word-break: break-all;
}

.file-line code {
  font-size: 0.72rem;
  background: #f5f5f4;
  padding: 0.15em 0.35em;
  border-radius: 0.3rem;
}

.item-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.5rem;
}

.btn-del {
  font: inherit;
  font-size: 0.875rem;
  font-weight: 500;
  padding: 0.5rem 1rem;
  color: #991b1b;
  background: #fff;
  border: 1px solid #fecaca;
  border-radius: 0.75rem;
  cursor: pointer;
}

.btn-del:hover {
  background: #fef2f2;
}

.hint-muted {
  display: block;
  margin-top: 0.5rem;
  font-size: 0.8rem;
  color: #a8a29e;
}

.ver {
  font-weight: 600;
  font-size: 1rem;
}

.meta {
  font-size: 0.8rem;
  color: var(--muted);
}

.notes {
  margin: 0;
  font-size: 0.85rem;
  color: #57534e;
}

a.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  align-self: flex-start;
  padding: 0.5rem 1rem;
  font-size: 0.875rem;
  font-weight: 500;
  color: #fff;
  background: var(--accent);
  border-radius: 0.75rem;
  text-decoration: none;
  border: none;
  cursor: pointer;
}

a.btn:hover {
  background: #292524;
}

a.btn:focus-visible {
  outline: 2px solid #1c1917;
  outline-offset: 2px;
}

a.btn.btn-secondary {
  color: #1e3a8a;
  background: #dbeafe;
}

a.btn.btn-secondary:hover {
  background: #bfdbfe;
}

.file-line .file-tag {
  display: inline-block;
  min-width: 2.1rem;
  font-size: 0.62rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  color: #78716c;
  vertical-align: middle;
}

.foot {
  margin-top: 2.5rem;
  padding-top: 1.5rem;
  border-top: 1px solid var(--border);
}

.foot p {
  margin: 0;
  font-size: 0.8rem;
  color: var(--muted);
}

.field {
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
  font-size: 0.875rem;
}

.field .label {
  color: #57534e;
  font-weight: 500;
}

.field input[type='text'],
.field input[type='password'],
.field input[type='date'],
.field input[type='number'],
.field input[type='file'],
.field select,
.field textarea {
  font: inherit;
  padding: 0.5rem 0.65rem;
  border: 1px solid var(--border);
  border-radius: 0.65rem;
  background: #fafaf9;
  color: var(--text);
}

.field input:focus-visible,
.field select:focus-visible,
.field textarea:focus-visible {
  outline: 2px solid #1c1917;
  outline-offset: 1px;
}

.field textarea {
  resize: vertical;
  min-height: 7rem;
}

.report-form {
  margin-top: 1rem;
}

.req {
  color: #b91c1c;
}

.hp-field {
  position: absolute;
  left: -9999px;
  width: 1px;
  height: 1px;
  overflow: hidden;
}

.footer-beian-inline {
  margin-top: 0.65rem !important;
}

.footer-beian-inline a {
  color: var(--muted);
  text-decoration: none;
}

.footer-beian-inline a:hover {
  color: var(--text);
  text-decoration: underline;
}

.btn-submit {
  margin-top: 0.25rem;
  align-self: flex-start;
  padding: 0.55rem 1.1rem;
  font: inherit;
  font-weight: 500;
  font-size: 0.875rem;
  color: #fff;
  background: var(--accent);
  border: none;
  border-radius: 0.75rem;
  cursor: pointer;
}

.btn-submit:hover {
  background: #292524;
}

.btn-submit:disabled {
  opacity: 0.55;
  cursor: not-allowed;
}

.form-msg {
  margin: 0;
  min-height: 1.25em;
  font-size: 0.85rem;
  color: var(--muted);
}

.form-msg.ok {
  color: #15803d;
}

.form-msg.err {
  color: #b91c1c;
}

.item-kind {
  display: inline-block;
  margin-left: 0.35rem;
  padding: 0.12rem 0.45rem;
  font-size: 0.68rem;
  font-weight: 600;
  border-radius: 0.4rem;
  vertical-align: middle;
}

.item-kind--hot {
  color: #166534;
  background: #dcfce7;
  border: 1px solid #bbf7d0;
}

.item-kind--apk {
  color: #1e40af;
  background: #dbeafe;
  border: 1px solid #bfdbfe;
}

.item-kind--both {
  color: #7c2d12;
  background: #ffedd5;
  border: 1px solid #fed7aa;
}

.wrap--legal {
  max-width: 40rem;
}

.legal-doc {
  font-size: 0.9rem;
  line-height: 1.65;
}

.legal-lead {
  margin: 0 0 1rem;
  color: #44403c;
}

.legal-doc p {
  margin: 0 0 0.75rem;
}

.legal-section {
  margin-top: 1.5rem;
  padding-top: 1.25rem;
  border-top: 1px solid var(--border);
}

.legal-section:first-of-type {
  margin-top: 0.5rem;
  padding-top: 0;
  border-top: none;
}

.legal-section h2 {
  margin: 0 0 0.65rem;
  font-size: 1rem;
  font-weight: 600;
}

.legal-section h3 {
  margin: 0.85rem 0 0.45rem;
  font-size: 0.92rem;
  font-weight: 600;
  color: #44403c;
}

.legal-section ul {
  margin: 0 0 0.75rem;
  padding-left: 1.25rem;
}

.legal-section li {
  margin-bottom: 0.35rem;
}

.legal-section a {
  color: #1e40af;
  word-break: break-all;
}

.foot-link {
  color: var(--muted);
  text-decoration: none;
}

.foot-link:hover {
  color: var(--text);
  text-decoration: underline;
}
