/* LEDTEK-Merch (routes/99-merch.js): kleiner Shop – Hero mit Lumi, Kacheln für Hoodie/T-Shirt, Aufdruck und Größe, Produktkarten, drei Schritte.
   Jacek 25.10.2026: „mache dir mal mehr Mühe … Hey, du hast noch keinen LEDTEK-Pulli … bestell dich reich“. Kräftiges Lila + Türkis (CI),
   große Schrift, Handy zuerst (nichts abgeschnitten, Ziele ≥ 44 px), ohne JavaScript bedienbar (Radio/Checkbox in den Kacheln). */

.merch-page { --m-sun: #ffd23f; --m-deep: #24123d; --m-r: 22px; }

/* ---------- Hero ---------- */
.m-hero { position: relative; overflow: hidden; color: #fff;
  background: radial-gradient(120% 90% at 85% 10%, rgba(47, 211, 187, .28) 0%, rgba(47, 211, 187, 0) 55%),
              radial-gradient(90% 80% at 0% 100%, rgba(255, 210, 63, .14) 0%, rgba(255, 210, 63, 0) 60%),
              linear-gradient(140deg, #9152d2 0%, #6a35a3 45%, #2a1745 100%); }
.m-hero::after { content: ""; position: absolute; inset: auto -10% -60px -10%; height: 120px; background: var(--paper, #fff); transform: rotate(-2.2deg); }
.m-hero-in { position: relative; z-index: 1; display: flow-root; padding-top: clamp(28px, 5vw, 64px); padding-bottom: clamp(70px, 9vw, 110px); }
.m-kicker { display: inline-block; margin: 0 0 14px; padding: 6px 12px; border-radius: 999px; background: rgba(255, 255, 255, .14); font-weight: 800; font-size: .8rem;
  letter-spacing: .12em; text-transform: uppercase; }
.m-title { margin: 0 0 14px; font-size: clamp(2.2rem, 1.2rem + 4.6vw, 4.2rem); line-height: 1.02; font-weight: 900; letter-spacing: -.02em; color: #fff; }
.m-hl { color: var(--teal, #2fd3bb); }
/* LEDTEK-Logo in der Überschrift: Versalhöhe (0,7 em), Seitenverhältnis 283,5 : 23, schmaler als die Spalte */
.m-logo { display: inline-block; width: 8.6em; max-width: 100%; height: auto; vertical-align: baseline; }
.m-lead { margin: 0 0 18px; max-width: 36rem; font-size: clamp(1.05rem, .95rem + .5vw, 1.3rem); line-height: 1.5; color: rgba(255, 255, 255, .92); }
.m-badges { display: flex; flex-wrap: wrap; gap: 8px; margin: 0 0 22px; padding: 0; list-style: none; }
.m-badges li { padding: 7px 12px; border-radius: 999px; border: 1.5px solid rgba(255, 255, 255, .45); font-weight: 700; font-size: .9rem; }
.m-badges li:first-child { background: var(--m-sun); border-color: var(--m-sun); color: #1d1b22; }
/* Lumi freigestellt (Jacek: „Banner mit Lumi zu groß … Lumi freistellen sieht gut aus“): am Handy klein rechts oben, der Text fließt drumherum;
   ab 880 px eigene Spalte mit Türkis-Schein, Bodenschatten, Sticker und Sprechblase */
.m-hero-art { position: relative; float: right; width: clamp(104px, 31vw, 170px); margin: 0 -4px 8px 10px; }
.m-hero-art::before { content: ""; position: absolute; inset: -14% -12% -6%; z-index: -1; border-radius: 50%;
  background: radial-gradient(closest-side, rgba(47, 211, 187, .5), rgba(47, 211, 187, 0)); }
.m-lumi { display: block; width: 100%; height: auto; filter: drop-shadow(0 10px 10px rgba(20, 8, 40, .45)); }
.m-sticker, .m-bubble { display: none; }
.m-sticker { position: absolute; top: -4%; right: -2%; place-items: center; width: 28%; aspect-ratio: 1; border-radius: 50%;
  background: var(--m-sun); color: #1d1b22; font-weight: 900; font-size: clamp(.95rem, .7rem + 1vw, 1.2rem); text-transform: uppercase; transform: rotate(-14deg);
  box-shadow: 0 8px 22px rgba(0, 0, 0, .25); }
.m-bubble { position: absolute; left: 50%; bottom: 1%; transform: translateX(-50%); white-space: nowrap; padding: 10px 16px; border-radius: 18px; background: #fff;
  color: var(--lila-deep, #52267D); font-weight: 900; font-size: clamp(.95rem, .8rem + .45vw, 1.15rem); box-shadow: 0 10px 26px rgba(0, 0, 0, .22); }
/* Spitze nach oben zu Lumi (Jacek 26.10.2026: „‚Nimm mich mit‘ ist im Text“ – Blase hängt unter Lumi in seiner Spalte, nie über dem Fließtext) */
.m-bubble::after { content: ""; position: absolute; left: calc(50% - 8px); top: -12px; border: 8px solid transparent; border-bottom: 12px solid #fff; border-top: 0; }
@media (min-width: 880px) {
  .m-hero-in { display: grid; grid-template-columns: 1.15fr .85fr; gap: 28px; align-items: center; }
  .m-hero-copy { grid-column: 1; grid-row: 1; }
  .m-hero-art { grid-column: 2; grid-row: 1; float: none; justify-self: center; width: min(100%, 420px); margin: 0; padding: 6% 2% 17%; container-type: inline-size; }
  .m-hero-art::after { content: ""; position: absolute; left: 18%; right: 14%; bottom: 15%; height: 9%; z-index: -1; border-radius: 50%;
    background: radial-gradient(closest-side, rgba(10, 0, 30, .5), rgba(10, 0, 30, 0)); }
  .m-lumi { filter: drop-shadow(0 22px 24px rgba(20, 8, 40, .5)); }
  .m-sticker { display: grid; }
  .m-bubble { display: block; }
}
/* schmale Lumi-Spalte (z. B. im Merch-Overlay bei mittlerer Breite): Blase weg statt gequetscht */
@container (max-width: 300px) { .m-hero-art .m-bubble { display: none; } }
@media (prefers-reduced-motion: no-preference) and (min-width: 880px) {
  .m-lumi { animation: m-float 4.5s ease-in-out infinite; }
  @keyframes m-float { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-8px); } }
}

/* ---------- Buttons ---------- */
.m-btn { display: inline-flex; align-items: center; justify-content: center; min-height: 52px; padding: 0 26px; border: 0; border-radius: 999px; cursor: pointer;
  background: var(--teal, #2fd3bb); color: #0d2a26; font: 800 1.05rem/1 var(--font); text-decoration: none; box-shadow: 0 8px 20px rgba(47, 211, 187, .35);
  transition: background-color .2s, box-shadow .2s, transform .2s; }
.m-btn:hover { background: var(--teal-2, #5fe0cc); box-shadow: 0 10px 26px rgba(47, 211, 187, .45); }
.m-btn:focus-visible { outline: 3px solid var(--m-sun); outline-offset: 3px; }
.m-btn-hero { min-width: 200px; }
.m-btn-ghost { background: transparent; color: var(--lila, #8145BD); box-shadow: inset 0 0 0 2px var(--lila, #8145BD); }
.m-btn-ghost:hover { background: var(--lila-tint, #F2ECFA); box-shadow: inset 0 0 0 2px var(--lila, #8145BD); }

/* ---------- Schritte ---------- */
.m-main { position: relative; z-index: 2; margin-top: clamp(-56px, -4vw, -24px); padding-top: 0; }
.m-shop { display: grid; gap: 22px; max-width: 980px; margin: 0 auto; }
.m-step { padding: clamp(18px, 3vw, 30px); border-radius: var(--m-r); background: #fff; border: 1px solid var(--line, #E4E0E9); box-shadow: 0 12px 32px rgba(40, 18, 70, .08); }
.m-step.has-error { border-color: var(--bad, #B42318); }
.m-step-t { display: flex; align-items: center; gap: 12px; margin: 0 0 4px; font-size: clamp(1.35rem, 1.1rem + 1vw, 1.8rem); font-weight: 900; color: var(--ink, #16131D); }
.m-num { display: grid; place-items: center; flex: none; width: 40px; height: 40px; border-radius: 50%; background: var(--grad-lila, #8145BD); color: #fff; font-size: 1.1rem; }
.m-sub { margin: 0 0 18px 52px; color: var(--ink-2, #544E62); }
.m-h { margin: 22px 0 10px; padding: 0; font-weight: 800; font-size: 1.05rem; color: var(--ink, #16131D); }
fieldset.m-tiles, fieldset.m-cards, fieldset.m-chips { border: 0; margin: 0; padding: 0; min-width: 0; }
.m-wear-opts > fieldset { margin-top: 22px; }
.m-wear-opts .m-h { margin: 0 0 10px; }

/* Kacheln: verstecktes Eingabefeld, die Karte zeigt den Zustand */
.m-tiles { display: grid; gap: 12px; }
.m-tiles-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.m-tiles-2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.m-cards { display: grid; gap: 12px; grid-template-columns: repeat(2, minmax(0, 1fr)); }
@media (min-width: 720px) { .m-cards { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
/* zweispaltig (Handy): eine übrige Karte über die ganze Breite statt allein in einer halben Zeile */
@media (max-width: 719.98px) { .m-cards > label.m-tile:last-of-type:nth-of-type(odd) { grid-column: 1 / -1; } }
.m-tile { position: relative; display: block; cursor: pointer; }
.m-in { position: absolute; opacity: 0; width: 1px; height: 1px; pointer-events: none; }
.m-tile-in { position: relative; display: flex; flex-direction: column; align-items: center; gap: 4px; height: 100%; padding: 14px 10px 16px; border-radius: 18px;
  background: var(--stone, #F4F2EF); border: 2px solid transparent; text-align: center; transition: border-color .2s, background-color .2s, box-shadow .2s; }
.m-tile:hover .m-tile-in { border-color: var(--lila-soft, #E7DCF6); background: var(--lila-tint, #F2ECFA); }
.m-tile-art { display: block; width: 100%; max-width: 150px; aspect-ratio: 1; }
.m-art { display: block; width: 100%; height: 100%; }
.m-cut { object-fit: contain; filter: drop-shadow(0 6px 8px rgba(20, 8, 40, .3)); }
.m-tile-t { font-weight: 900; font-size: 1.05rem; color: var(--ink, #16131D); }
.m-tile-s { font-size: .88rem; line-height: 1.35; color: var(--ink-2, #544E62); }
.m-tick { position: absolute; top: 10px; right: 10px; width: 28px; height: 28px; opacity: 0; transform: scale(.6); transition: opacity .2s, transform .2s; }
.m-tick circle { fill: var(--teal, #2fd3bb); } .m-tick path { stroke: #0d2a26; }
.m-in:checked + .m-tile-in { border-color: var(--teal, #2fd3bb); background: var(--teal-tint, #DFF7F2); box-shadow: 0 8px 22px rgba(47, 211, 187, .25); }
.m-in:checked + .m-tile-in .m-tick { opacity: 1; transform: scale(1); }
.m-in:focus-visible + .m-tile-in { outline: 3px solid var(--lila, #8145BD); outline-offset: 2px; }
.is-print .m-tile-art { max-width: 130px; border-radius: 14px; background: #ece9f1; }
/* Aufdruck und Größe erst, wenn Hoodie oder T-Shirt gewählt ist (ohne :has() immer sichtbar) */
@supports selector(:has(*)) {
  .m-wear-opts { display: none; }
  .m-step:has(.is-cloth .m-in:checked) .m-wear-opts { display: block; }
}

/* Größen als Chips */
.m-chips { display: flex; flex-wrap: wrap; gap: 8px; }
.m-chips legend { width: 100%; }
/* Vergriffene Größen (Bestand, Jacek 12.11.2026: „wenn alle, dann alle“): data-out an der Größe nennt 'hoodie-weiss' (in dieser Aufschrift
   vergriffen) bzw. 'hoodie' (in allen Aufschriften). Ohne JavaScript; der Server prüft beim Absenden noch einmal. */
.m-step:has(input[name$="main"][value="hoodie"]:checked):has(input[name$="print"][value="weiss"]:checked) .m-chip[data-out~="hoodie-weiss"],
.m-step:has(input[name$="main"][value="hoodie"]:checked):has(input[name$="print"][value="schwarz"]:checked) .m-chip[data-out~="hoodie-schwarz"],
.m-step:has(input[name$="main"][value="hoodie"]:checked) .m-chip[data-out~="hoodie"],
.m-step:has(input[name$="main"][value="tshirt"]:checked):has(input[name$="print"][value="weiss"]:checked) .m-chip[data-out~="tshirt-weiss"],
.m-step:has(input[name$="main"][value="tshirt"]:checked):has(input[name$="print"][value="schwarz"]:checked) .m-chip[data-out~="tshirt-schwarz"],
.m-step:has(input[name$="main"][value="tshirt"]:checked) .m-chip[data-out~="tshirt"] { pointer-events: none; cursor: not-allowed; }
.m-step:has(input[name$="main"][value="hoodie"]:checked):has(input[name$="print"][value="weiss"]:checked) .m-chip[data-out~="hoodie-weiss"] span,
.m-step:has(input[name$="main"][value="hoodie"]:checked):has(input[name$="print"][value="schwarz"]:checked) .m-chip[data-out~="hoodie-schwarz"] span,
.m-step:has(input[name$="main"][value="hoodie"]:checked) .m-chip[data-out~="hoodie"] span,
.m-step:has(input[name$="main"][value="tshirt"]:checked):has(input[name$="print"][value="weiss"]:checked) .m-chip[data-out~="tshirt-weiss"] span,
.m-step:has(input[name$="main"][value="tshirt"]:checked):has(input[name$="print"][value="schwarz"]:checked) .m-chip[data-out~="tshirt-schwarz"] span,
.m-step:has(input[name$="main"][value="tshirt"]:checked) .m-chip[data-out~="tshirt"] span { opacity: .42; text-decoration: line-through; border-style: dashed; }
.m-size-note { flex-basis: 100%; margin: 4px 0 0; font-size: .86rem; line-height: 1.45; color: var(--ink-2, #544E62); }   /* Größe ohne Gewähr (Jacek 12.11.2026) */
.m-chip { position: relative; cursor: pointer; }
.m-chip span { display: grid; place-items: center; min-width: 56px; min-height: 48px; padding: 0 14px; border-radius: 14px; border: 2px solid var(--line-2, #CFC9D8);
  background: #fff; font-weight: 800; color: var(--ink, #16131D); transition: background-color .2s, border-color .2s, color .2s; }
.m-chip:hover span { border-color: var(--lila, #8145BD); }
.m-chip .m-in:checked + span { background: var(--lila, #8145BD); border-color: var(--lila, #8145BD); color: #fff; }
.m-chip .m-in:focus-visible + span { outline: 3px solid var(--teal, #2fd3bb); outline-offset: 2px; }

/* Schritt 3: Geschlecht als Chips (bestimmt den Schnitt), dann Vorname, Name, E-Mail, Messe-Code */
fieldset.m-gender { margin-bottom: 20px; }
.m-gender .help { flex-basis: 100%; margin: 2px 0 0; }
.m-gender.has-error .m-chip span { border-color: var(--bad, #B42318); }
/* Schritt 3 */
.m-code input { font-family: ui-monospace, Consolas, monospace; font-weight: 700; letter-spacing: .14em; text-transform: uppercase; font-size: 1.15rem; }
.m-submit { display: flex; align-items: center; gap: 16px; margin-top: 18px; padding: 16px; border-radius: 18px; background: var(--lila-tint, #F2ECFA); }
.m-submit-lumi { width: 84px; height: auto; flex: none; filter: drop-shadow(0 6px 8px rgba(20, 8, 40, .35)); }
.m-btn-go { min-width: 220px; font-size: 1.15rem; }
/* Schritt 1 der Merch-Seite: erst der Messe-Code – danach stehen Name und Preis fest (Jacek 13.11.2026) */
.m-coderow { display: flex; flex-wrap: wrap; gap: 12px; align-items: flex-start; }
.m-coderow .field { flex: 1 1 240px; max-width: 420px; margin: 0; }
.m-codebtn { margin-top: 30px; }
.m-ticketbox { padding: 14px 18px; border-radius: 16px; background: var(--teal-tint, #DFF7F2); }
.m-ticketbox.is-fee { background: var(--lila-tint, #F2ECFA); }
.m-ticketbox-t { margin: 0 0 4px; font-size: 1.15rem; font-weight: 900; color: var(--ink, #16131D); overflow-wrap: anywhere; }
.m-ticketbox-p { margin: 0 0 8px; }
.m-ticketbox-a { font-size: .9rem; }
.m-forline { margin: 16px 0 0; font-weight: 800; overflow-wrap: anywhere; }
.m-forline small { display: block; margin-top: 2px; font-weight: 400; color: var(--ink-2, #544E62); }
@media (max-width: 560px) { .m-codebtn { margin-top: 0; width: 100%; } }
/* Merch-Schritt in der Ticketbestellung (pages/tickets.js merchPage): je Ticket eine Karte, Feldnamen m<n>_main, m<n>_print … –
   deshalb oben die Auswahl nach dem Namensende ([name$="main"]) und hier die Vorschau je Karte statt je Formular */
.tk-merch-shop { display: grid; gap: 22px; }
.tk-merch-shop .m-step-t { flex-wrap: wrap; font-size: clamp(1.1rem, 1rem + .6vw, 1.4rem); }
.tk-merch-shop .m-step:has(.is-main .m-in[value="tshirt"]:checked) .pv-tshirt { display: block; }
.tk-merch-shop .m-step:has(.is-main .m-in[value="tshirt"]:checked) .pv-hoodie { display: none; }
.tk-m-price { margin-left: auto; padding: 4px 12px; border-radius: 999px; font-size: .82rem; font-weight: 700; background: var(--teal-tint, #DFF7F2); color: #0A6E62; white-space: nowrap; }
.tk-m-price.is-fee { background: var(--lila-tint, #F2ECFA); color: var(--lila-deep, #52267D); }
.tk-m-none { display: inline-block; margin-top: 12px; }
.tk-m-end .check { margin-bottom: 14px; }
.tk-m-end .btn-ghost { margin-top: 10px; }
@supports selector(:has(*)) {
  .tk-m-more { display: none; }
  .m-step:has(.is-main .m-in:checked) .tk-m-more { display: block; }
}
/* Prüfseite vor der Zahlung der Schutzgebühr */
.m-pay { margin: 0 0 14px; display: grid; gap: 8px; }
.m-pay > div { display: grid; grid-template-columns: minmax(96px, 30%) 1fr; gap: 10px; padding: 10px 14px; border-radius: 12px; background: var(--stone, #F4F2EF); }
.m-pay dt { font-weight: 700; color: var(--ink-2, #544E62); }
.m-pay dd { margin: 0; overflow-wrap: anywhere; }
.m-pay .m-pay-sum { background: var(--lila-tint, #F2ECFA); grid-template-columns: 1fr auto; align-items: center; }
.m-pay .m-pay-sum dd { font-weight: 900; font-size: 1.25rem; }
.m-pay-btns { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; }
.m-fine { margin: 8px 0 0; font-size: .85rem; color: var(--ink-2, #544E62); }

/* Bestätigung */
.m-done { display: flex; align-items: center; gap: 22px; max-width: 760px; margin: 0 auto; padding: clamp(20px, 4vw, 34px); border-radius: var(--m-r);
  background: linear-gradient(140deg, var(--teal-tint, #DFF7F2), var(--lila-tint, #F2ECFA)); border: 2px solid var(--teal, #2fd3bb); }
.m-done-lumi { width: 150px; height: auto; flex: none; filter: drop-shadow(0 10px 12px rgba(20, 8, 40, .35)); }
.m-done-t { margin: 0 0 8px; font-size: clamp(1.5rem, 1.2rem + 1.2vw, 2.1rem); font-weight: 900; }
.m-done-links { display: flex; flex-wrap: wrap; gap: 10px; margin: 16px 0 0; }

/* Handy */
@media (max-width: 640px) {
  /* Hoodie, T-Shirt, Rucksack auch am Handy nebeneinander – gleichwertige Wahl */
  .m-tiles-3 { gap: 8px; }
  .m-tiles-3 .m-tile-in { padding: 10px 6px 12px; }
  .m-tiles-3 .m-tile-t { font-size: .98rem; }
  .m-tiles-3 .m-tile-s { font-size: .76rem; }
  .m-tiles-3 .m-tick { top: 6px; right: 6px; width: 24px; height: 24px; }
  .m-sub { margin-left: 0; }
  .m-tile-s { font-size: .82rem; }
  .m-submit { flex-direction: column; text-align: center; }
  .m-btn-go { width: 100%; min-width: 0; }
  .m-done { flex-direction: column; text-align: center; }
  .m-done-links { justify-content: center; }
}

/* Aufdruck-Vorschau zeigt das gewählte Teil (Hoodie oder T-Shirt) */
.pv-tshirt { display: none; }
.m-shop:has(.is-main .m-in[value="tshirt"]:checked) .pv-tshirt { display: block; }
.m-shop:has(.is-main .m-in[value="tshirt"]:checked) .pv-hoodie { display: none; }
.pv-hoodie, .pv-tshirt { width: 100%; height: 100%; }

/* Eingebettet als Overlay über der 3D-Halle (/merch?embed=1): ohne Kopf, Fuß und Sprunglink der Website; oben Platz für das X des Overlays */
.merch-embed .site-header, .merch-embed .site-footer, .merch-embed .skip { display: none; }
.merch-embed .m-hero-in { padding-top: clamp(52px, 6vw, 64px); }
