:root {
  --brand: #470054; --brand-2: #6b1a7c; --tint: #f4effa; --tint-2: #e9dcf3;
  --ink: #241a2b; --muted: #6c6276; --line: #e4dcea; --bg: #faf7fc; --surface: #fff;
  --ok: #17794a; --ok-bg: #e6f6ee; --bad: #b3261e; --bad-bg: #fdeceb; --warn: #8a5a00; --warn-bg: #fff4d9;
}
* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; background: var(--bg); color: var(--ink); font: 16px/1.5 system-ui, -apple-system, "Segoe UI", Roboto, "PingFang SC", "Microsoft YaHei", sans-serif; }
.top { background: var(--brand); padding: 12px 16px; display: flex; align-items: center; justify-content: space-between; gap: 12px; position: sticky; top: 0; z-index: 5; }
.logo { height: 30px; width: auto; display: block; }
.langs { display: flex; gap: 4px; background: rgba(255,255,255,.14); border-radius: 999px; padding: 3px; }
.langs button { border: 0; background: transparent; color: #fff; font: inherit; font-weight: 700; font-size: 14px; padding: 6px 12px; border-radius: 999px; cursor: pointer; min-height: 36px; }
.langs button.on { background: #fff; color: var(--brand); }
main { max-width: 620px; margin: 0 auto; padding: 16px 16px 32px; }
.foot { text-align: center; color: var(--muted); font-size: 13px; padding: 0 16px 28px; }
h1 { font-size: 22px; line-height: 1.25; margin: 0 0 6px; text-wrap: balance; }
h2 { font-size: 17px; margin: 0 0 10px; display: flex; align-items: center; gap: 10px; }
h2 .n { flex: none; width: 28px; height: 28px; border-radius: 50%; background: var(--brand); color: #fff; display: grid; place-items: center; font-size: 15px; font-weight: 800; }
p { margin: 0 0 10px; }
.muted { color: var(--muted); font-size: 14px; }
.card { background: var(--surface); border: 1px solid var(--line); border-radius: 16px; padding: 16px; margin: 0 0 14px; }
.card.center { text-align: center; padding: 28px 18px; }
.big-ic { font-size: 44px; line-height: 1; margin-bottom: 10px; }
.hello { background: var(--tint); border-color: var(--tint-2); }
.bill { display: flex; flex-wrap: wrap; gap: 6px 14px; font-size: 14px; color: var(--muted); margin-top: 4px; }
.bill b { color: var(--ink); font-variant-numeric: tabular-nums; }
.rule { border: 2px solid var(--brand); background: #fff; }
.rule .main-rule { font-size: 17px; font-weight: 800; color: var(--brand); margin-bottom: 10px; text-wrap: pretty; }
.rule ul { margin: 0; padding-left: 20px; }
.rule li { margin-bottom: 6px; font-size: 15px; }
label.f { display: block; font-weight: 700; margin: 14px 0 6px; }
label.f:first-of-type { margin-top: 0; }
.hint { font-weight: 400; color: var(--muted); font-size: 14px; display: block; margin-top: 2px; }
input[type=text], input[type=date], textarea { width: 100%; font: inherit; color: inherit; background: #fff; border: 1.5px solid #cdc3d6; border-radius: 12px; padding: 12px; min-height: 48px; }
textarea { min-height: 110px; resize: vertical; }
input:focus, textarea:focus { outline: 3px solid var(--tint-2); border-color: var(--brand); }
.count { text-align: right; font-size: 12px; color: var(--muted); margin-top: 3px; font-variant-numeric: tabular-nums; }
.items { display: grid; gap: 8px; }
.item { display: flex; gap: 12px; align-items: flex-start; border: 1.5px solid #cdc3d6; border-radius: 12px; padding: 12px; cursor: pointer; background: #fff; }
.item input { width: 22px; height: 22px; margin: 1px 0 0; flex: none; accent-color: var(--brand); }
.item.on { border-color: var(--brand); background: var(--tint); }
.item .q { color: var(--muted); font-size: 14px; white-space: nowrap; margin-left: auto; }
.chips { display: flex; flex-wrap: wrap; gap: 8px; }
.chip { border: 1.5px solid #cdc3d6; background: #fff; color: var(--ink); border-radius: 999px; padding: 10px 14px; font: inherit; font-weight: 600; cursor: pointer; min-height: 44px; }
.chip.on { background: var(--brand); border-color: var(--brand); color: #fff; }
#slots { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px 10px; }
.slot.wide { grid-column: 1 / -1; border-top: 1px solid var(--line); padding-top: 12px; }
.slot.one .thumbs { grid-template-columns: 1fr; margin-top: 0; }
.slot.one .slot-h { flex-direction: column; align-items: center; text-align: center; gap: 4px; font-size: 13px; line-height: 1.25; margin-top: 6px; }
.slot-h { display: flex; align-items: baseline; gap: 8px; font-weight: 700; }
.slot-h .req { font-size: 12px; font-weight: 800; color: var(--bad); background: var(--bad-bg); border-radius: 999px; padding: 1px 8px; white-space: nowrap; }
.slot-h .opt { font-size: 12px; font-weight: 700; color: var(--muted); background: #f1eef4; border-radius: 999px; padding: 1px 8px; white-space: nowrap; }
.slot-h .done { font-size: 12px; font-weight: 800; color: var(--ok); background: var(--ok-bg); border-radius: 999px; padding: 1px 8px; white-space: nowrap; }
.thumbs { display: grid; grid-template-columns: repeat(auto-fill, minmax(92px, 1fr)); gap: 8px; margin-top: 8px; }
.thumb, .add { position: relative; aspect-ratio: 1; border-radius: 12px; overflow: hidden; background: #f1eef4; }
.thumb img { width: 100%; height: 100%; object-fit: cover; display: block; }
.thumb .x { position: absolute; top: 4px; right: 4px; width: 30px; height: 30px; border: 0; border-radius: 50%; background: rgba(0,0,0,.62); color: #fff; font-size: 16px; line-height: 1; cursor: pointer; }
.thumb.busy::after { content: ""; position: absolute; inset: 0; background: rgba(255,255,255,.7); }
.thumb.busy .spin { position: absolute; inset: 0; margin: auto; z-index: 1; }
.add { border: 2px dashed #b9a9c6; background: var(--tint); display: grid; place-items: center; text-align: center; cursor: pointer; color: var(--brand); font-weight: 700; font-size: 13px; padding: 6px; }
.add span.ic { display: block; font-size: 26px; line-height: 1; margin-bottom: 4px; }
.add input { position: absolute; inset: 0; opacity: 0; cursor: pointer; width: 100%; height: 100%; }
.agree { display: flex; gap: 12px; align-items: flex-start; cursor: pointer; }
.agree input { width: 24px; height: 24px; margin: 2px 0 0; flex: none; accent-color: var(--brand); }
.btn { display: block; width: 100%; border: 0; border-radius: 14px; background: var(--brand); color: #fff; font: inherit; font-weight: 800; font-size: 17px; padding: 15px; cursor: pointer; margin-top: 16px; min-height: 54px; }
.btn:disabled { opacity: .55; cursor: default; }
.err { display: none; color: var(--bad); background: var(--bad-bg); border-radius: 10px; padding: 8px 12px; font-size: 14px; font-weight: 600; margin-top: 8px; }
.err.show { display: block; }
.bad-field { outline: 3px solid #f3b7b3; border-radius: 14px; }
.note { border-radius: 12px; padding: 12px 14px; margin: 0 0 12px; font-size: 15px; }
.note.warn { background: var(--warn-bg); color: #5c3c00; }
.note.bad { background: var(--bad-bg); color: #7c1a14; }
.note.ok { background: var(--ok-bg); color: #0f5132; }
.note b { display: block; margin-bottom: 2px; }
.ref { display: inline-block; font-weight: 800; font-size: 20px; letter-spacing: .5px; background: var(--tint); border-radius: 10px; padding: 6px 14px; margin: 6px 0 12px; font-variant-numeric: tabular-nums; }
.spin { width: 30px; height: 30px; border: 3px solid var(--tint-2); border-top-color: var(--brand); border-radius: 50%; animation: sp 0.8s linear infinite; margin: 0 auto; }
@keyframes sp { to { transform: rotate(360deg); } }
@media (prefers-reduced-motion: reduce) { .spin { animation-duration: 2.4s; } }
