@font-face {
  font-family: "KuaiLe";
  src: url("../fonts/zcool-kuaile-chinese-simplified-400-normal.woff2") format("woff2");
  font-weight: 400;
  font-style: normal;
  font-display: swap;
  unicode-range: U+3000-303F, U+3400-4DBF, U+4E00-9FFF, U+FF00-FFEF;
}

@font-face {
  font-family: "Nunito";
  src: url("../fonts/nunito-latin-700-normal.woff2") format("woff2");
  font-weight: 700;
  font-style: normal;
  font-display: swap;
}

* { box-sizing: border-box; }

body {
  margin: 0;
  color: #3a3128;
  font-family: "Nunito", "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei UI", sans-serif;
  background:
    radial-gradient(700px 280px at 0% 0%, #ffe4ec, transparent 60%),
    #f4efe6;
}

button, input, textarea, select { font: inherit; color: inherit; }

h1, h3, summary, .solid {
  font-family: "KuaiLe", "PingFang SC", "Microsoft YaHei", sans-serif;
  font-weight: 400;
}

.bar {
  position: sticky;
  top: 0;
  z-index: 5;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding: 12px 16px;
  padding-top: calc(12px + env(safe-area-inset-top));
  background: rgba(244, 239, 230, 0.92);
  backdrop-filter: blur(12px);
}

.bar a, .bar button {
  color: #3a3128;
  text-decoration: none;
  background: transparent;
  border: 0;
  cursor: pointer;
}

main {
  width: min(760px, calc(100% - 24px));
  margin: 0 auto 40px;
  padding-bottom: calc(20px + env(safe-area-inset-bottom));
}

.sheet, details {
  margin-top: 14px;
  padding: 16px;
  border-radius: 24px;
  background: #fffdf9;
  box-shadow: 0 12px 28px rgba(90, 60, 30, 0.06);
}

details summary {
  cursor: pointer;
  font-size: 22px;
}

details > :not(summary) { margin-top: 12px; }

h1 { margin: 0 0 8px; font-size: 32px; }

label, .file-add {
  display: grid;
  gap: 6px;
  margin-top: 12px;
  font-size: 14px;
  font-weight: 800;
}

input, textarea, select {
  width: 100%;
  border: 0;
  border-radius: 14px;
  padding: 12px;
  background: #f6f1ea;
}

textarea { resize: vertical; }

.solid, .ghost, .mini {
  border: 0;
  border-radius: 999px;
  cursor: pointer;
}

.solid {
  margin-top: 14px;
  padding: 12px 18px;
  background: #3a3128;
  color: #fff;
}

.ghost, .mini {
  padding: 10px 14px;
  background: #fff3e4;
}

.hint, .msg { color: #8d7d70; }

.upload-row, .prize-row, .gallery-row, .msg-item {
  display: flex;
  gap: 10px;
  align-items: center;
  margin-top: 12px;
}

.upload-row img, .gallery-row img {
  width: 72px;
  height: 72px;
  object-fit: contain;
  border-radius: 16px;
  background: #fff6ee;
}

.audio-row {
  display: grid;
  gap: 10px;
  margin-top: 12px;
}

.audio-row audio {
  width: 100%;
  border-radius: 14px;
}

.audio-tools {
  display: grid;
  gap: 8px;
}

.prize-row input[type="text"] { flex: 1; }

.prize-row input[type="color"], .color-list input[type="color"] {
  width: 52px;
  height: 42px;
  padding: 4px;
  background: #fff;
}

.gallery-row { align-items: flex-start; }

.gallery-row .grow { flex: 1; display: grid; gap: 8px; }

.gallery-row .tools, .prize-row .tools { display: flex; gap: 6px; }

.checks { display: flex; gap: 16px; margin: 14px 0; }

.checks label { margin: 0; font-weight: 700; display: flex; align-items: center; gap: 6px; }

.msg-item {
  justify-content: space-between;
  padding: 10px 12px;
  border-radius: 16px;
  background: #f6f1ea;
}

.msg-item p { margin: 4px 0 0; }

.savebar {
  position: sticky;
  bottom: calc(8px + env(safe-area-inset-bottom));
  margin-top: 16px;
  padding: 12px;
  border-radius: 22px;
  background: rgba(255, 253, 249, 0.96);
  box-shadow: 0 10px 24px rgba(70, 45, 20, 0.12);
}

.savebar .solid { width: 100%; margin-top: 0; }

.file-add input { margin-top: 6px; }

@media (min-width: 720px) {
  .prize-row input[type="text"] { max-width: none; }
}
