/* Tappkarte – eine Karte pro Bildschirm, für das Handy gebaut. --shop kommt vom Laden. */
:root {
  --bg: #eef0ea;
  --paper: #fbfbf7;
  --ink: #1f2620;
  --muted: #616a5f;
  --line: #d3d8cc;
  --gold: #d9a441;
  --gold-ink: #3a2a07;
  --ok: #2f7a45;
  --display: "Young Serif", Georgia, serif;
  --body: "Figtree", "Segoe UI", sans-serif;
  color-scheme: light;
}
@media (prefers-color-scheme: dark) {
  :root { --bg: #131712; --paper: #1d221b; --ink: #e8ece3; --muted: #9da696; --line: #343c31; --ok: #5cb877; color-scheme: dark; }
}
* { box-sizing: border-box; }
html, body { margin: 0; }
body {
  min-height: 100vh;
  background: var(--bg);
  color: var(--ink);
  font: 17px/1.5 var(--body);
  padding: max(20px, env(safe-area-inset-top)) max(16px, env(safe-area-inset-right)) max(24px, env(safe-area-inset-bottom)) max(16px, env(safe-area-inset-left));
}
.wrap { max-width: 440px; margin: 0 auto; display: grid; gap: 18px; }

.card {
  background: var(--shop);
  color: #fff;
  border-radius: 22px;
  padding: 22px 20px 20px;
  display: grid;
  gap: 20px;
  box-shadow: 0 18px 40px -22px rgba(0, 0, 0, .55);
}
.card-head { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; }
.card h1 { font: 400 26px/1.15 var(--display); margin: 0; text-wrap: balance; }
.count { font-weight: 700; font-size: 15px; opacity: .85; font-variant-numeric: tabular-nums; white-space: nowrap; }
.count span { font-size: 26px; }

.slots { list-style: none; margin: 0; padding: 14px; display: grid; grid-template-columns: repeat(5, 1fr); gap: 10px; background: rgba(0, 0, 0, .18); border-radius: 16px; }
.slot { aspect-ratio: 1; border-radius: 50%; border: 2px dashed rgba(255, 255, 255, .4); display: grid; place-items: center; font-size: 13px; color: rgba(255, 255, 255, .55); }
.slot.on { border: 0; background: var(--gold); }
.slot svg { width: 60%; height: 60%; fill: none; stroke: var(--gold-ink); stroke-width: 3; stroke-linecap: round; stroke-linejoin: round; }
.slot.new { animation: pop .6s cubic-bezier(.2, .9, .3, 1.4); }
@keyframes pop { from { transform: scale(.2) rotate(-25deg); opacity: 0; } }

.status { margin: 0; font-size: 16px; }
.status.full { background: var(--gold); color: var(--gold-ink); padding: 12px 14px; border-radius: 12px; }

.toast { padding: 12px 16px; border-radius: 14px; font-weight: 500; background: var(--paper); border: 1px solid var(--line); animation: drop .4s ease-out; }
.toast.ok { border-color: var(--ok); color: var(--ok); }
.toast.gold { background: var(--gold); border-color: var(--gold); color: var(--gold-ink); }
@keyframes drop { from { transform: translateY(-10px); opacity: 0; } }

.hint, .notice p { color: var(--muted); margin: 0; }
.notice { background: var(--paper); border: 1px solid var(--line); border-radius: 18px; padding: 22px; display: grid; gap: 8px; }
.notice h1 { font: 400 24px/1.2 var(--display); margin: 0; }
.brand { text-align: center; font: 400 15px var(--display); color: var(--muted); letter-spacing: .02em; }

.notice-bar { margin: 0; padding: 12px 16px; border-radius: 14px; background: var(--paper); border: 1px solid var(--line); border-left: 4px solid var(--shop); }

.redeem { display: grid; gap: 6px; background: rgba(0, 0, 0, .18); border-radius: 12px; padding: 12px; }
.redeem label { font-size: 13px; opacity: .85; }
.redeem-row { display: flex; gap: 8px; }
.redeem input { flex: 1; min-width: 0; font: 700 20px var(--body); letter-spacing: .3em; text-align: center; padding: 10px; border-radius: 10px; border: 0; background: #fff; color: #1f2620; }
.redeem button, .form button { font: 700 16px var(--body); border: 0; border-radius: 10px; padding: 10px 18px; background: var(--gold); color: var(--gold-ink); cursor: pointer; }
input:focus-visible, button:focus-visible, a:focus-visible { outline: 3px solid var(--gold); outline-offset: 2px; }

/* Laden-Ansicht */
.shop-top h1 { font: 400 26px/1.15 var(--display); margin: 0; }
.shop-top p { margin: 2px 0 0; color: var(--muted); font-size: 14px; }
.panel { background: var(--paper); border: 1px solid var(--line); border-radius: 18px; padding: 18px; display: grid; gap: 12px; }
.panel h2 { margin: 0; font-size: 13px; letter-spacing: .08em; text-transform: uppercase; color: var(--muted); }
.stats { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px; }
.stat { border-top: 3px solid var(--shop); padding-top: 6px; }
.stat b { display: block; font-size: 28px; font-variant-numeric: tabular-nums; line-height: 1.1; }
.stat span { font-size: 14px; color: var(--muted); }
.pin-show { font: 700 34px var(--body); letter-spacing: .25em; font-variant-numeric: tabular-nums; }
.form { display: grid; gap: 8px; }
.form textarea { font: 16px/1.4 var(--body); padding: 10px 12px; border-radius: 10px; border: 1px solid var(--line); background: var(--bg); color: var(--ink); resize: vertical; min-height: 70px; }
.form .row { display: flex; gap: 8px; flex-wrap: wrap; }
.form button.light { background: transparent; color: var(--ink); border: 1px solid var(--line); font-weight: 500; }
.feed { margin: 0; padding: 0; list-style: none; display: grid; gap: 6px; font-size: 15px; }
.feed li { display: flex; justify-content: space-between; gap: 10px; border-bottom: 1px solid var(--line); padding-bottom: 6px; }
.feed time { color: var(--muted); font-variant-numeric: tabular-nums; white-space: nowrap; }
.saved { color: var(--ok); font-weight: 500; margin: 0; }

/* Test-Seite */
.dev { background: var(--paper); border: 1px dashed var(--muted); border-radius: 18px; padding: 20px; display: grid; gap: 14px; }
.dev h1 { font: 400 22px var(--display); margin: 0; }
.dev ul { margin: 0; padding: 0; list-style: none; display: grid; gap: 10px; }
.dev li { display: flex; justify-content: space-between; align-items: center; gap: 10px; flex-wrap: wrap; }
.btn { display: inline-block; text-decoration: none; background: var(--shop); color: #fff; padding: 10px 16px; border-radius: 12px; font-weight: 700; }
.btn.light { background: transparent; color: var(--ink); border: 1px solid var(--line); font-weight: 500; }
.small { font-size: 14px; color: var(--muted); }

@media (prefers-reduced-motion: reduce) { * { animation: none !important; } }
