:root { --bg: #f6f3ec; --card: #fff; --ink: #1d2733; --muted: #5c6675; --line: #e7e1d4; --accent: #e8590c; --tint: #fff4e6; --ok: #2b8a3e; --bad: #c92a2a; }
* { box-sizing: border-box; }
body { margin: 0; background: var(--bg); color: var(--ink); font-family: -apple-system, "Helvetica Neue", Arial, sans-serif; -webkit-font-smoothing: antialiased; }
a { color: inherit; }
.bar { display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 14px 24px; }
.brand { font-weight: 800; font-size: 22px; text-decoration: none; display: flex; align-items: center; gap: 8px; }
.coin { display: inline-flex; width: 34px; height: 34px; border-radius: 50%; background: var(--accent); color: #fff; align-items: center; justify-content: center; font-size: 20px; }
.bar nav { display: flex; align-items: center; gap: 14px; font-weight: 600; }
.page { max-width: 960px; margin: 0 auto; padding: 8px 24px 64px; }
h1 { font-size: 36px; margin: 12px 0 18px; }
h2 { font-size: 22px; margin: 0 0 10px; }
.lead { font-size: 20px; line-height: 1.5; color: var(--muted); }
.small { font-size: 14px; color: var(--muted); }
.center { text-align: center; }
.card { background: var(--card); border-radius: 24px; padding: 22px 26px; margin: 0 0 20px; box-shadow: 0 1px 0 var(--line), 0 8px 22px rgba(29,39,51,.06); }
.card.narrow { max-width: 560px; margin: 24px auto; }
.hero { text-align: center; padding: 40px 0; }
.hero h1 { font-size: 48px; }
.choices { display: flex; flex-wrap: wrap; gap: 14px; justify-content: center; margin-top: 26px; }
.btn { display: inline-block; font: inherit; font-weight: 800; font-size: 17px; padding: 12px 22px; border-radius: 999px; border: 3px solid var(--accent); background: var(--accent); color: #fff; cursor: pointer; text-decoration: none; }
.btn:hover { filter: brightness(1.05); transform: translateY(-1px); }
.btn.big { font-size: 20px; padding: 16px 28px; }
.btn.ghost { background: transparent; color: var(--accent); }
.btn[disabled] { opacity: .5; cursor: default; }
.link { font: inherit; background: none; border: 0; color: var(--muted); cursor: pointer; text-decoration: underline; padding: 0; }
.link.danger { color: var(--bad); }
form.inline { display: inline; }
label { display: flex; flex-direction: column; gap: 6px; font-weight: 700; font-size: 15px; margin: 0 0 14px; }
label.check { flex-direction: row; align-items: center; gap: 10px; }
input, select { font: inherit; font-weight: 400; padding: 10px 12px; border: 2px solid var(--line); border-radius: 12px; background: #fff; color: var(--ink); }
input:focus, select:focus { outline: none; border-color: var(--accent); }
.grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 0 18px; align-items: end; }
.grid .btn, .grid fieldset { grid-column: 1 / -1; justify-self: start; }
fieldset { border: 0; padding: 0; margin: 0 0 14px; }
legend { font-weight: 700; font-size: 15px; margin-bottom: 6px; }
.avatars { display: flex; flex-wrap: wrap; gap: 6px; }
.av { margin: 0; }
.av input { position: absolute; opacity: 0; }
.av span { display: inline-flex; width: 52px; height: 52px; align-items: center; justify-content: center; font-size: 30px; border-radius: 14px; border: 3px solid var(--line); cursor: pointer; }
.av input:checked + span { border-color: var(--accent); background: var(--tint); }
.av input:focus-visible + span { outline: 3px solid var(--ink); }
details summary { cursor: pointer; font-weight: 800; color: var(--accent); margin: 10px 0; }
.kids { display: flex; flex-wrap: wrap; gap: 14px; margin-bottom: 10px; }
.kid { display: flex; flex-direction: column; align-items: center; gap: 4px; padding: 16px 20px; min-width: 150px; border-radius: 20px; border: 3px solid var(--line); text-decoration: none; }
.kid:hover { border-color: var(--accent); }
.avatar { font-size: 40px; line-height: 1; }
.avatar.huge { font-size: 110px; }
.kname { font-size: 22px; font-weight: 800; }
.rows { list-style: none; padding: 0; margin: 0 0 14px; }
.rows li { display: flex; justify-content: space-between; align-items: center; gap: 12px; padding: 10px 0; border-bottom: 1px solid var(--line); }
.tag { font-size: 12px; font-weight: 800; background: var(--tint); color: var(--accent); padding: 2px 8px; border-radius: 999px; }
.code-box { background: var(--tint); border-radius: 18px; padding: 14px 18px; margin: 10px 0; }
.code { font-family: ui-monospace, Menlo, monospace; font-size: 40px; font-weight: 800; letter-spacing: 4px; margin: 6px 0; }
.codein { font-family: ui-monospace, Menlo, monospace; font-size: 28px; letter-spacing: 3px; text-transform: uppercase; }
.alert { background: #fff5f5; color: var(--bad); border-radius: 14px; padding: 12px 16px; font-weight: 700; }
.ok { background: #ebfbee; color: var(--ok); border-radius: 14px; padding: 12px 16px; font-weight: 700; }
.msg { min-height: 1.4em; font-weight: 700; color: var(--bad); }
.msg.good { color: var(--ok); }
.kidside h1 { font-size: 44px; }
.pick { display: flex; flex-wrap: wrap; gap: 26px; justify-content: center; margin-top: 30px; }
.pick-kid { font: inherit; display: flex; flex-direction: column; align-items: center; gap: 10px; width: 240px; padding: 30px 20px; border-radius: 30px; border: 5px solid var(--line); background: #fff; cursor: pointer; }
.pick-kid:hover { border-color: var(--accent); transform: translateY(-4px); }
.pick-kid .avatar { font-size: 110px; }
.pick-kid .kname { font-size: 34px; }
.hello { text-align: center; padding: 30px 0; }
@media (max-width: 600px) { .page { padding: 8px 16px 48px; } h1 { font-size: 30px; } .hero h1 { font-size: 36px; } }
.jar-line { font-weight: 800; color: var(--accent); }
.jar-big { font-size: 40px; font-weight: 800; color: var(--accent); margin: 4px 0; }
.ledger { width: 100%; border-collapse: collapse; margin-top: 10px; font-size: 15px; }
.ledger th, .ledger td { text-align: left; padding: 8px 6px; border-bottom: 1px solid var(--line); }
.ledger td:nth-child(3), .ledger td:nth-child(4), .ledger th:nth-child(3), .ledger th:nth-child(4) { text-align: right; white-space: nowrap; }
.goal-row { display: flex; justify-content: space-between; align-items: center; gap: 12px; padding: 10px 0; border-bottom: 1px solid var(--line); font-weight: 700; }
