:root {
  --green: #1f3d2b;
  --green-2: #2f5a40;
  --pink: #f2a0b6;
  --pink-soft: #fbe4ea;
  --cream: #fbf7f1;
  --ink: #1d2420;
  --muted: #6b746e;
  --line: #e6e0d6;
  --ok: #2e7d4f;
  --err: #b3261e;
  --radius: 18px;
}
* { box-sizing: border-box; }
html, body { margin: 0; }
body {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  background: var(--cream);
  color: var(--ink);
  line-height: 1.45;
  -webkit-font-smoothing: antialiased;
}
.wrap { max-width: 460px; margin: 0 auto; padding: 24px 16px 48px; }
.wrap.wide { max-width: 980px; }
h1 { font-size: 26px; line-height: 1.2; margin: 0 0 8px; letter-spacing: -0.01em; }
h2 { font-size: 18px; margin: 0 0 12px; }
p { margin: 0 0 12px; }
.muted { color: var(--muted); }
.small { font-size: 13px; }
.brand { display: flex; align-items: center; gap: 10px; font-weight: 600; margin-bottom: 20px; }
.brand img { width: 36px; height: 36px; border-radius: 10px; }
.panel { background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: 20px; margin-bottom: 16px; }
label { display: block; font-size: 14px; font-weight: 500; margin: 14px 0 6px; }
input[type=text], input[type=tel], input[type=date], input[type=number], input[type=password], input[type=search] {
  width: 100%; font: inherit; font-size: 17px; padding: 12px 14px; border-radius: 12px;
  border: 1px solid var(--line); background: #fff; color: var(--ink); outline: none;
}
input:focus { border-color: var(--green-2); box-shadow: 0 0 0 3px rgba(47, 90, 64, .15); }
.check { display: flex; gap: 10px; align-items: flex-start; font-weight: 400; font-size: 13px; color: var(--muted); }
.check input { margin-top: 3px; width: 18px; height: 18px; accent-color: var(--green); }
button, .btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  font: inherit; font-weight: 600; font-size: 16px; padding: 13px 18px; border-radius: 12px;
  border: 0; cursor: pointer; text-decoration: none; background: var(--green); color: #fff; width: 100%;
}
button:disabled { opacity: .5; cursor: default; }
.btn.secondary, button.secondary { background: #fff; color: var(--green); border: 1px solid var(--line); }
.btn.black { background: #000; }
.btn.pink { background: var(--pink); color: var(--green); }
.row { display: flex; gap: 10px; }
.row > * { flex: 1; }
.error { color: var(--err); font-size: 14px; margin-top: 10px; min-height: 1em; }
.okmsg { color: var(--ok); font-weight: 600; }
.stack > * + * { margin-top: 10px; }

/* Бонусная карта */
.card {
  position: relative; overflow: hidden; border-radius: 22px; padding: 20px; color: #fff;
  background: radial-gradient(120% 120% at 100% 0%, #3d6e51 0%, var(--green) 55%);
  box-shadow: 0 12px 30px rgba(31, 61, 43, .25);
}
.card::after {
  content: "✿"; position: absolute; right: -14px; top: -34px; font-size: 150px; color: rgba(242, 160, 182, .18);
}
.card .top { display: flex; justify-content: space-between; align-items: center; font-size: 14px; }
.card .lbl { color: var(--pink); font-size: 11px; letter-spacing: .08em; text-transform: uppercase; }
.card .bal { font-size: 44px; font-weight: 700; line-height: 1.1; margin: 18px 0 4px; font-variant-numeric: tabular-nums; }
.card .meta { display: flex; gap: 22px; margin-top: 14px; font-size: 15px; }
.qr { background: #fff; border-radius: 16px; padding: 14px; margin-top: 18px; text-align: center; color: var(--ink); }
.qr img { width: 210px; height: 210px; display: block; margin: 0 auto; }
.qr .num { font-family: ui-monospace, Menlo, monospace; letter-spacing: .12em; margin-top: 6px; }

.progress { height: 6px; border-radius: 3px; background: rgba(255,255,255,.2); margin-top: 14px; overflow: hidden; }
.progress i { display: block; height: 100%; background: var(--pink); }

.wallet-btn { height: 52px; border-radius: 12px; font-size: 16px; }
.hist { list-style: none; padding: 0; margin: 0; }
.hist li { display: flex; justify-content: space-between; padding: 10px 0; border-bottom: 1px solid var(--line); font-size: 14px; }
.hist li:last-child { border-bottom: 0; }
.plus { color: var(--ok); font-weight: 600; }
.minus { color: var(--err); font-weight: 600; }
.pre { white-space: pre-line; }
.hidden { display: none !important; }

/* Инструкция «Добавить на главный экран» */
.a2hs { margin-top: 16px; }
.a2hs-head { display: flex; gap: 14px; align-items: center; }
.a2hs-head img { width: 56px; height: 56px; border-radius: 14px; flex: 0 0 auto; box-shadow: 0 4px 12px rgba(31,61,43,.2); }
.a2hs-head h2 { margin: 0 0 2px; }
.a2hs-head p { margin: 0; }
.a2hs .seg { display: flex; gap: 4px; background: var(--cream); border-radius: 12px; padding: 4px; margin-top: 16px; }
.a2hs .seg button { background: transparent; color: var(--muted); padding: 9px; font-size: 15px; border-radius: 9px; }
.a2hs .seg button.on { background: #fff; color: var(--green); box-shadow: 0 1px 3px rgba(0,0,0,.08); }
.howto { list-style: none; padding: 0; margin: 14px 0 0; counter-reset: s; }
.howto li { display: flex; gap: 12px; align-items: flex-start; padding: 10px 0; border-bottom: 1px solid var(--line); font-size: 15px; line-height: 1.4; }
.howto li:last-child { border-bottom: 0; }
.howto .ic { flex: 0 0 34px; height: 34px; border-radius: 10px; background: var(--pink-soft); color: var(--green); display: grid; place-items: center; font-size: 16px; }
.inapp { margin-top: 14px; background: #fff6e5; border: 1px solid #f1dfb5; border-radius: 12px; padding: 12px 14px; font-size: 14px; line-height: 1.45; }
.install { margin-top: 14px; }
