:root {
  --bg: #0a0812;
  --glass: rgba(22, 18, 38, .62);
  --glass2: rgba(36, 30, 62, .6);
  --line: rgba(255, 255, 255, .09);
  --line2: rgba(255, 255, 255, .17);
  --text: #f3f0fc;
  --muted: #a7a0c2;
  --violet: #8b5cf6;
  --cyan: #22d3ee;
  --pink: #ec4899;
  --gold: #f59e0b;
  --good: #22c55e;
  --bad: #f87171;
  --brand: linear-gradient(120deg, #22d3ee, #8b5cf6 50%, #ec4899);
  --display: "Segoe UI Variable Display", "SF Pro Display", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  --ease: cubic-bezier(.2, .8, .2, 1);
  --r: 20px;
}
* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0; min-height: 100vh; background: var(--bg); color: var(--text);
  font: 15.5px/1.55 system-ui, -apple-system, "Segoe UI Variable Text", "Segoe UI", Roboto, sans-serif;
  -webkit-font-smoothing: antialiased; overflow-x: hidden;
}
button { font: inherit; color: inherit; cursor: pointer; }
input { font: inherit; color: inherit; }
.hidden { display: none !important; }
.muted { color: var(--muted); }
.grow { flex: 1; min-width: 0; }
::selection { background: rgba(139, 92, 246, .45); }

/* Hintergrund */
.aurora { position: fixed; inset: -20%; z-index: 0; filter: blur(90px) saturate(140%); opacity: .5; pointer-events: none; }
.aurora i { position: absolute; border-radius: 50%; mix-blend-mode: screen; animation: drift 28s var(--ease) infinite alternate; }
.aurora .a1 { width: 55vmax; height: 55vmax; left: -8%; top: -12%; background: radial-gradient(circle, #6d28d9 0%, transparent 65%); }
.aurora .a2 { width: 45vmax; height: 45vmax; right: -6%; top: 0; background: radial-gradient(circle, #0e7490 0%, transparent 65%); animation-duration: 34s; animation-delay: -9s; }
.aurora .a3 { width: 50vmax; height: 50vmax; left: 30%; bottom: -30%; background: radial-gradient(circle, #be185d 0%, transparent 65%); animation-duration: 40s; animation-delay: -15s; opacity: .7; }
@keyframes drift { to { transform: translate(4%, 6%) scale(1.12) rotate(8deg); } }
@media (prefers-reduced-motion: reduce) { .aurora i { animation: none; } html { scroll-behavior: auto; } }

.glass { background: var(--glass); border: 1px solid var(--line); backdrop-filter: blur(18px) saturate(140%); -webkit-backdrop-filter: blur(18px) saturate(140%); }

.testbar {
  position: relative; z-index: 3; text-align: center; padding: 8px 16px; font-size: 13.5px;
  background: repeating-linear-gradient(-45deg, rgba(245, 158, 11, .2) 0 14px, rgba(245, 158, 11, .12) 14px 28px);
  border-bottom: 1px solid rgba(245, 158, 11, .35); color: #fde68a;
}

/* Kopfzeile */
.top {
  position: sticky; top: 0; z-index: 5; display: flex; align-items: center; justify-content: space-between;
  padding: 14px max(16px, calc((100vw - 1180px) / 2)); background: rgba(10, 8, 18, .6);
  backdrop-filter: blur(16px); -webkit-backdrop-filter: blur(16px); border-bottom: 1px solid var(--line);
}
.brand { display: flex; align-items: center; gap: 10px; color: var(--text); text-decoration: none; font: 600 19px var(--display); }
.brand img { width: 34px; height: 34px; border-radius: 10px; box-shadow: 0 6px 20px rgba(139, 92, 246, .45); }
.brand b { font-weight: 800; }
.me {
  display: flex; align-items: center; gap: 9px; padding: 6px 14px 6px 6px; border-radius: 99px;
  background: var(--glass2); border: 1px solid var(--line2); font-weight: 600; transition: border-color .2s, transform .2s var(--ease);
}
.me:hover { border-color: rgba(139, 92, 246, .7); transform: translateY(-1px); }
.me .ph, .me img { width: 28px; height: 28px; border-radius: 8px; display: grid; place-items: center; background: rgba(255, 255, 255, .08); image-rendering: pixelated; font-size: 15px; }

.wrap { position: relative; z-index: 1; max-width: 1180px; margin: 0 auto; padding: 0 16px 60px; }

/* Hero */
.hero { text-align: center; padding: 64px 0 34px; animation: up .7s var(--ease) both; }
.hero h1 { font: 800 clamp(34px, 6vw, 60px)/1.05 var(--display); letter-spacing: -.02em; margin: 0 0 14px; }
.grad { background: var(--brand); -webkit-background-clip: text; background-clip: text; color: transparent; }
.hero p { color: var(--muted); font-size: 18px; margin: 0 auto 26px; max-width: 560px; }
.hero-row { display: flex; gap: 12px; justify-content: center; flex-wrap: wrap; }
.ip {
  display: inline-flex; align-items: center; gap: 10px; padding: 11px 12px 11px 18px; border-radius: 99px;
  background: var(--glass2); border: 1px solid var(--line2); font-weight: 700; font-size: 16px; letter-spacing: .01em;
  transition: border-color .2s, transform .2s var(--ease);
}
.ip:hover { border-color: rgba(34, 211, 238, .7); transform: translateY(-2px); }
.ip .dot { width: 9px; height: 9px; border-radius: 50%; background: var(--good); box-shadow: 0 0 0 4px rgba(34, 197, 94, .2); animation: pulse 2s infinite; }
.ip small { color: var(--muted); font-weight: 500; font-size: 13px; }
.ip .copy { font-size: 12.5px; padding: 5px 11px; border-radius: 99px; background: var(--brand); color: #fff; }
@keyframes pulse { 50% { box-shadow: 0 0 0 7px rgba(34, 197, 94, 0); } }

.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px; padding: 12px 20px; border-radius: 14px;
  border: 1px solid var(--line2); background: var(--glass2); font-weight: 700; text-decoration: none; color: var(--text);
  transition: transform .2s var(--ease), box-shadow .2s, opacity .2s, border-color .2s;
}
.btn:hover { transform: translateY(-2px); }
.btn:active { transform: translateY(0) scale(.98); }
.btn:disabled { opacity: .5; pointer-events: none; }
.btn.primary { background: var(--brand); background-size: 160% 100%; border: 0; color: #fff; box-shadow: 0 10px 30px rgba(139, 92, 246, .38); transition: background-position .5s, transform .2s var(--ease), box-shadow .2s; }
.btn.primary:hover { background-position: 100% 0; box-shadow: 0 14px 38px rgba(236, 72, 153, .38); }
.btn.ghost { background: transparent; }
.btn.wide { width: 100%; }

/* Zuletzt gekauft */
.recent { display: flex; align-items: center; gap: 14px; margin: 0 0 26px; padding: 10px 14px; border-radius: 16px; background: rgba(255, 255, 255, .03); border: 1px solid var(--line); overflow: hidden; }
.rl { font-size: 12px; font-weight: 800; text-transform: uppercase; letter-spacing: .08em; color: var(--muted); white-space: nowrap; }
.recent-list { display: flex; gap: 10px; overflow-x: auto; scrollbar-width: none; }
.recent-list::-webkit-scrollbar { display: none; }
.rc { display: flex; align-items: center; gap: 8px; padding: 5px 12px 5px 5px; border-radius: 12px; background: var(--glass2); white-space: nowrap; font-size: 13.5px; animation: up .5s var(--ease) both; }
.rc img { width: 26px; height: 26px; border-radius: 7px; image-rendering: pixelated; }
.rc small { color: var(--muted); }

/* Kategorien */
.cats { position: sticky; top: 66px; z-index: 4; display: flex; gap: 8px; padding: 10px 16px; margin: 0 -16px 8px; background: linear-gradient(rgba(10, 8, 18, .82), rgba(10, 8, 18, .55)); backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px); overflow-x: auto; scrollbar-width: none; }
.cats::-webkit-scrollbar { display: none; }
.cats button {
  white-space: nowrap; padding: 9px 16px; border-radius: 99px; border: 1px solid var(--line2); background: rgba(16, 13, 28, .8);
  backdrop-filter: blur(12px); font-weight: 600; color: var(--muted); transition: all .2s var(--ease);
}
.cats button:hover { color: var(--text); }
.cats button.on { color: #fff; background: var(--brand); border-color: transparent; box-shadow: 0 6px 22px rgba(139, 92, 246, .35); }

/* Produkte */
.grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(255px, 1fr)); gap: 18px; }
.loading { color: var(--muted); padding: 40px; text-align: center; grid-column: 1 / -1; }
.card {
  position: relative; display: flex; flex-direction: column; padding: 20px; border-radius: var(--r);
  background: var(--glass); border: 1px solid var(--line); backdrop-filter: blur(16px); -webkit-backdrop-filter: blur(16px);
  transition: transform .3s var(--ease), border-color .3s, box-shadow .3s; animation: up .55s var(--ease) both;
}
.card:hover { transform: translateY(-5px); border-color: var(--line2); box-shadow: 0 24px 60px rgba(0, 0, 0, .45), 0 0 0 1px rgba(139, 92, 246, .25); }
.card .badge { position: absolute; top: 16px; right: 16px; font-size: 11.5px; font-weight: 800; padding: 4px 10px; border-radius: 99px; background: var(--brand); color: #fff; letter-spacing: .02em; }
.ico {
  width: 64px; height: 64px; flex: none; border-radius: 18px; display: grid; place-items: center; font-size: 32px; margin-bottom: 16px;
  background: var(--c); box-shadow: 0 12px 30px var(--glow), inset 0 1px 0 rgba(255, 255, 255, .35); position: relative; overflow: hidden;
}
.ico::after { content: ""; position: absolute; inset: 0; background: linear-gradient(120deg, transparent 35%, rgba(255, 255, 255, .35) 50%, transparent 65%); transform: translateX(-100%); }
.card:hover .ico::after { animation: shine .9s var(--ease); }
@keyframes shine { to { transform: translateX(100%); } }
.c-gold { --c: linear-gradient(135deg, #fbbf24, #f97316); --glow: rgba(249, 115, 22, .35); }
.c-violet { --c: linear-gradient(135deg, #8b5cf6, #d946ef); --glow: rgba(168, 85, 247, .4); }
.c-bronze { --c: linear-gradient(135deg, #e0913a, #92400e); --glow: rgba(224, 145, 58, .35); }
.c-cyan { --c: linear-gradient(135deg, #22d3ee, #3b82f6); --glow: rgba(34, 211, 238, .35); }
.c-pink { --c: linear-gradient(135deg, #ec4899, #8b5cf6); --glow: rgba(236, 72, 153, .4); }
.c-green { --c: linear-gradient(135deg, #34d399, #059669); --glow: rgba(16, 185, 129, .35); }
.c-rainbow { --c: linear-gradient(135deg, #22d3ee, #8b5cf6, #ec4899); --glow: rgba(139, 92, 246, .45); }
.card h3 { font: 700 19px var(--display); margin: 0 0 6px; }
.card p { margin: 0 0 12px; color: var(--muted); font-size: 14px; }
.perks { list-style: none; padding: 0; margin: 0 0 16px; display: grid; gap: 5px; font-size: 13.5px; }
.perks li { display: flex; gap: 8px; }
.perks li::before { content: "✓"; color: var(--cyan); font-weight: 800; }
.card .foot2 { margin-top: auto; display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.price { font: 800 22px var(--display); }
.price s { display: block; color: var(--muted); font-size: 13px; font-weight: 500; }
.card .btn { padding: 10px 18px; }

.info { display: grid; grid-template-columns: repeat(auto-fit, minmax(230px, 1fr)); gap: 14px; margin-top: 46px; }
.info div { padding: 18px; border-radius: 16px; background: rgba(255, 255, 255, .03); border: 1px solid var(--line); display: grid; gap: 4px; }
.info span { color: var(--muted); font-size: 14px; }

.foot { position: relative; z-index: 1; display: flex; flex-wrap: wrap; gap: 6px 20px; justify-content: center; padding: 26px 16px 34px; border-top: 1px solid var(--line); color: var(--muted); font-size: 13px; text-align: center; }

/* Fenster */
.modal { position: fixed; inset: 0; z-index: 20; display: grid; place-items: center; padding: 16px; background: rgba(5, 4, 10, .66); backdrop-filter: blur(6px); animation: fade .25s both; }
.box { position: relative; width: min(470px, 100%); max-height: calc(100vh - 32px); overflow-y: auto; padding: 26px; border-radius: 24px; box-shadow: 0 30px 90px rgba(0, 0, 0, .6); animation: pop .35s var(--ease) both; }
.box h2 { font: 700 22px var(--display); margin: 0 0 6px; }
.box .x { position: absolute; top: 14px; right: 14px; width: 34px; height: 34px; border-radius: 10px; border: 0; background: rgba(255, 255, 255, .06); color: var(--muted); }
.box .x:hover { color: var(--text); background: rgba(255, 255, 255, .12); }
.box label { display: grid; gap: 6px; font-size: 13px; font-weight: 600; color: var(--muted); }
.row { display: flex; gap: 12px; align-items: flex-end; margin-top: 14px; }
.namefield { display: flex; align-items: center; gap: 10px; padding: 8px; border-radius: 14px; background: rgba(0, 0, 0, .3); border: 1px solid var(--line2); margin-top: 14px; transition: border-color .2s; }
.namefield:focus-within { border-color: rgba(139, 92, 246, .8); }
.namefield.ok { border-color: rgba(34, 197, 94, .7); }
.namefield.small { margin-top: 0; padding: 6px; }
.namefield input { flex: 1; min-width: 0; border: 0; outline: 0; background: transparent; font-size: 17px; font-weight: 600; color: var(--text); }
.head { width: 40px; height: 40px; border-radius: 10px; image-rendering: pixelated; background: #2a2440; }
.namefield.small .head { width: 32px; height: 32px; }
.msg { min-height: 22px; font-size: 13.5px; margin: 8px 0 10px; }
.msg.bad { color: var(--bad); } .msg.good { color: #86efac; }

.steps { display: flex; gap: 6px; list-style: none; padding: 0; margin: 0 40px 20px 0; counter-reset: s; }
.steps li { flex: 1; font-size: 12px; font-weight: 700; color: var(--muted); padding-top: 8px; border-top: 3px solid rgba(255, 255, 255, .1); transition: all .3s; }
.steps li.on { color: var(--text); border-color: var(--violet); }
.steps li.done { border-color: var(--cyan); }
.step { display: none; animation: up .35s var(--ease) both; }
.step.on { display: block; }
.sum { display: flex; gap: 16px; align-items: center; }
.sum .ico { margin: 0; width: 58px; height: 58px; font-size: 28px; }
.sum p { margin: 2px 0 0; font-size: 14px; }
.buy .perks { margin: 14px 0 0; }
.qty { display: flex; align-items: center; border-radius: 14px; background: rgba(0, 0, 0, .3); border: 1px solid var(--line2); height: 46px; }
.qty button { width: 40px; height: 100%; border: 0; background: none; font-size: 20px; }
.qty span { min-width: 28px; text-align: center; font-weight: 800; color: var(--text); font-size: 16px; }
.methods { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin: 14px 0; }
.methods button { display: flex; align-items: center; gap: 10px; padding: 14px; border-radius: 14px; background: rgba(0, 0, 0, .28); border: 1.5px solid var(--line2); font-weight: 650; text-align: left; transition: all .2s var(--ease); }
.methods button span { font-size: 22px; }
.methods button:hover { border-color: rgba(255, 255, 255, .3); }
.methods button.on { border-color: var(--violet); background: rgba(139, 92, 246, .14); box-shadow: 0 0 0 3px rgba(139, 92, 246, .2); }
.total { display: flex; justify-content: space-between; align-items: baseline; padding: 14px 0; border-top: 1px solid var(--line); }
.total b { font: 800 26px var(--display); }
.testnote { font-size: 13px; color: #fde68a; background: rgba(245, 158, 11, .1); border: 1px solid rgba(245, 158, 11, .3); padding: 10px 12px; border-radius: 12px; margin: 0 0 4px; }

.proc { display: grid; justify-items: center; gap: 10px; padding: 34px 0 20px; text-align: center; }
.spin { width: 54px; height: 54px; border-radius: 50%; border: 4px solid rgba(255, 255, 255, .1); border-top-color: var(--cyan); border-right-color: var(--violet); animation: spin .8s linear infinite; margin-bottom: 8px; }
@keyframes spin { to { transform: rotate(360deg); } }
.done { text-align: center; padding-top: 6px; }
.check { width: 74px; height: 74px; margin: 0 auto 14px; border-radius: 50%; display: grid; place-items: center; font-size: 38px; font-weight: 900; color: #fff; background: linear-gradient(135deg, #22c55e, #10b981); box-shadow: 0 14px 40px rgba(34, 197, 94, .45); animation: pop .5s var(--ease) both; }
.check.warn { background: linear-gradient(135deg, #f59e0b, #f97316); box-shadow: 0 14px 40px rgba(245, 158, 11, .4); }
.receipt { text-align: left; margin: 16px 0; padding: 14px 16px; border-radius: 14px; background: rgba(0, 0, 0, .28); border: 1px solid var(--line); font-size: 14px; display: grid; gap: 6px; }
.receipt div { display: flex; justify-content: space-between; gap: 10px; }
.receipt span { color: var(--muted); }

.toast { position: fixed; left: 50%; bottom: 24px; z-index: 30; transform: translateX(-50%); padding: 12px 18px; border-radius: 14px; background: rgba(30, 26, 50, .95); border: 1px solid var(--line2); font-weight: 600; box-shadow: 0 16px 40px rgba(0, 0, 0, .5); animation: up .3s var(--ease) both; }
#confetti { position: fixed; inset: 0; z-index: 40; pointer-events: none; width: 100%; height: 100%; }

@keyframes up { from { opacity: 0; transform: translateY(14px); } }
@keyframes fade { from { opacity: 0; } }
@keyframes pop { from { opacity: 0; transform: scale(.92); } }

@media (max-width: 560px) {
  .hero { padding: 40px 0 26px; }
  .hero p { font-size: 16px; }
  .cats { top: 62px; }
  .brand span { font-size: 17px; }
  .box { padding: 22px 18px; }
  .row { flex-wrap: wrap; }
  .methods { grid-template-columns: 1fr; }
  .recent { flex-direction: column; align-items: flex-start; gap: 8px; }
}

/* v3: Warenkorb, Ziel, Top-Unterstuetzer */
.top-r { display: flex; align-items: center; gap: 8px; }
.pill { display: inline-flex; align-items: center; gap: 6px; height: 40px; padding: 0 14px; border-radius: 99px; background: var(--glass2); border: 1px solid var(--line2); color: var(--text); text-decoration: none; font-weight: 600; font-size: 14px; transition: border-color .2s, transform .2s var(--ease); }
.pill:hover { border-color: rgba(139, 92, 246, .7); transform: translateY(-1px); }
.cartbtn { position: relative; font-size: 17px; padding: 0 13px; }
.cnt { position: absolute; top: -6px; right: -6px; min-width: 20px; height: 20px; padding: 0 5px; border-radius: 99px; background: var(--pink); color: #fff; font-size: 11.5px; font-weight: 800; display: grid; place-items: center; box-shadow: 0 0 0 2px var(--bg); }
.cartbtn.bump { animation: bump .45s var(--ease); }
@keyframes bump { 30% { transform: scale(1.18) rotate(-6deg); } 60% { transform: scale(.95); } }
.community { display: grid; grid-template-columns: 1.4fr 1fr; gap: 14px; margin: 0 0 22px; animation: up .6s var(--ease) both; }
.community.one { grid-template-columns: 1fr; }
.goal, .topsup { padding: 16px 18px; border-radius: 18px; }
.g-head { display: flex; justify-content: space-between; gap: 10px; margin-bottom: 10px; }
.g-head span { font-weight: 800; color: var(--cyan); }
.bar { height: 12px; border-radius: 99px; background: rgba(255, 255, 255, .08); overflow: hidden; margin-bottom: 8px; }
.bar i { display: block; height: 100%; width: 0; border-radius: inherit; background: var(--brand); box-shadow: 0 0 20px rgba(139, 92, 246, .6); transition: width 1.2s var(--ease); }
.topsup ol { list-style: none; margin: 10px 0 0; padding: 0; display: grid; gap: 7px; }
.topsup li { display: flex; align-items: center; gap: 9px; font-size: 14.5px; }
.topsup img { width: 24px; height: 24px; border-radius: 6px; image-rendering: pixelated; }
.medal { font-size: 18px; width: 22px; text-align: center; }
.acts { display: flex; gap: 8px; }
.btn.icon { padding: 10px 12px; }
.ico.sm { width: 44px; height: 44px; font-size: 21px; border-radius: 13px; margin: 0; }
.cartlist { display: grid; gap: 8px; margin: 14px 0 6px; max-height: 300px; overflow-y: auto; }
.cl { display: flex; align-items: center; gap: 12px; padding: 10px; border-radius: 14px; background: rgba(0, 0, 0, .25); border: 1px solid var(--line); animation: up .3s var(--ease) both; }
.cl b { display: block; font-size: 14.5px; }
.cl small { font-size: 12.5px; }
.cl .qty { height: 34px; border-radius: 10px; }
.cl .qty button { width: 30px; font-size: 17px; }
.rm { width: 30px; height: 30px; border-radius: 9px; border: 0; background: rgba(255, 255, 255, .06); color: var(--muted); flex: none; }
.rm:hover { color: var(--bad); background: rgba(248, 113, 113, .12); }
.empty { text-align: center; color: var(--muted); padding: 30px 0 10px; }
.lbl { margin-top: 14px; }
.giftchk { display: flex !important; grid-auto-flow: column; align-items: center; gap: 10px; padding: 12px 14px; margin: 4px 0 2px; border-radius: 14px; background: linear-gradient(120deg, rgba(236, 72, 153, .12), rgba(139, 92, 246, .12)); border: 1px solid rgba(236, 72, 153, .35); color: var(--text) !important; font-size: 14.5px !important; cursor: pointer; }
.giftchk input { width: 18px; height: 18px; accent-color: #ec4899; }
input.plain { width: 100%; padding: 12px 14px; border-radius: 14px; background: rgba(0, 0, 0, .3); border: 1px solid var(--line2); color: var(--text); font-weight: 600; outline: 0; }
input.plain:focus { border-color: rgba(139, 92, 246, .8); }
#codeBox { margin: 4px 0 14px; }
.mt8 { margin-top: 8px; }
.small { font-size: 13.5px; margin: 0; }
.receipt .sum { border-top: 1px solid var(--line); padding-top: 8px; margin-top: 2px; }
body.noscroll { overflow: hidden; }
.spin.sm { width: 22px; height: 22px; border-width: 3px; margin: 0 auto 10px; }
.foot { flex-direction: column; align-items: center; }
.foot-links { display: flex; flex-wrap: wrap; gap: 6px 18px; justify-content: center; margin-bottom: 4px; }
.foot-links a { color: var(--text); text-decoration: none; opacity: .8; }
.foot-links a:hover { opacity: 1; color: var(--cyan); }
@media (max-width: 760px) { .community { grid-template-columns: 1fr; } }
@media (max-width: 560px) {
  .hide-sm { display: none; }
  .me span:last-child { max-width: 90px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
  .brand span { display: none; }
  .acts .btn.primary { padding: 10px 14px; }
}
