/*! Kiddies Open Air · Ticketseite (Liste + Detail + Ratgeber) · lokale JTL-Integration
 * Nach kiddies-design-system.css (1.1) laden. Alles gekapselt unter .ko-theme.
 * Nutzt ausschließlich --ko-* Tokens. Keine Bootstrap-/NOVA-Klassen überschreiben.
 */

/* ---------- Kopf der Ticketseite ---------- */
.ko-theme .ko-tickets__head { display: grid; grid-template-columns: minmax(0, 1.2fr) minmax(0, 1fr); align-items: end; gap: var(--ko-space-5); padding-top: var(--ko-space-2); }
.ko-theme .ko-tickets__title { min-width: 0; padding-bottom: var(--ko-space-6); overflow-wrap: anywhere; }
.ko-theme .ko-tickets__title:only-child { grid-column: 1 / -1; }
.ko-theme .ko-tickets__event { display: flex; flex-wrap: wrap; align-items: center; gap: var(--ko-space-2); margin: var(--ko-space-2) 0 0; color: var(--ko-blue-ink); font-weight: var(--ko-weight-strong); }
.ko-theme .ko-tickets__event .ko-ui-icon { width: 1.3rem; height: 1.3rem; }
.ko-theme .ko-tickets__legal { padding-block: var(--ko-space-5) var(--ko-space-8); }

/* ---------- Bild (PNG, transparent, 1000×1000) ---------- */
.ko-theme .ko-tmotif { position: relative; overflow: hidden; aspect-ratio: 1; border: var(--ko-border) solid var(--ko-ink); border-radius: var(--ko-radius-soft); background: var(--ko-tmotif-bg, var(--ko-white)); }
.ko-theme .ko-tmotif img { display: block; width: 100%; height: 100%; object-fit: contain; object-position: center; }
.ko-theme .ko-tmotif--wide { aspect-ratio: 16 / 9; } /* Motive halten den Inhalt im mittleren Band (y 22–78 %) */

/* ---------- Preis, Kauf ---------- */
.ko-theme .ko-tprice { margin: 0; font: 400 2.5rem/1 var(--ko-font-display); white-space: nowrap; }
.ko-theme .ko-tprice sup { font-size: .4em; vertical-align: top; }
.ko-theme .ko-tprice--xl { font-size: 4rem; }
.ko-theme .ko-tbuy { display: flex; flex-wrap: wrap; gap: var(--ko-space-3); align-items: stretch; }
.ko-theme .ko-tname-row { position: relative; display: flex; align-items: flex-start; gap: var(--ko-space-3); }

/* ---------- Perforation (Ticket-Look) ---------- */
.ko-theme .ko-tperf { position: relative; }
.ko-theme .ko-tperf i { position: absolute; width: 28px; height: 28px; border-radius: 50%; background: var(--ko-tperf-hole, var(--ko-sand)); border: var(--ko-border-strong) solid var(--ko-ink); }
.ko-theme .ko-tperf--h { height: 28px; margin-top: var(--ko-space-3); }
.ko-theme .ko-tperf--h::before { content: ""; position: absolute; left: 18px; right: 18px; top: 12px; border-top: var(--ko-border-strong) dashed var(--ko-ink); }
.ko-theme .ko-tperf--h i:first-child { left: -17px; top: 0; clip-path: inset(0 0 0 50%); }
.ko-theme .ko-tperf--h i:last-child { right: -17px; top: 0; clip-path: inset(0 50% 0 0); }
.ko-theme .ko-tperf--v { align-self: stretch; margin-block: -22px; }
.ko-theme .ko-tperf--v::before { content: ""; position: absolute; top: 24px; bottom: 24px; left: 50%; border-left: var(--ko-border-strong) dashed var(--ko-ink); }
.ko-theme .ko-tperf--v i:first-child { left: 3px; top: -16px; clip-path: inset(50% 0 0 0); }
.ko-theme .ko-tperf--v i:last-child { left: 3px; bottom: -16px; clip-path: inset(0 0 50% 0); }

/* ---------- Breites Ticket ---------- */
.ko-theme .ko-tstage { position: relative; display: grid; grid-template-columns: 300px 34px minmax(0, 1fr); align-items: center; padding: 22px; margin-bottom: var(--ko-space-7); background: var(--ko-yellow); border: var(--ko-border-strong) solid var(--ko-ink); border-radius: var(--ko-radius); box-shadow: var(--ko-shadow-large); --ko-tmotif-bg: var(--ko-white); }
.ko-theme .ko-tstage__body { display: flex; flex-direction: column; gap: var(--ko-space-4); padding-left: var(--ko-space-3); }
.ko-theme .ko-tstage__name { margin: 0; font: 400 var(--ko-title-md)/1.02 var(--ko-font-display); }

/* ---------- Abreiß-Tickets ---------- */
.ko-theme .ko-tgrid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 30px; align-items: start; }
.ko-theme .ko-tcard { position: relative; display: flex; flex-direction: column; background: var(--ko-white); border: var(--ko-border-strong) solid var(--ko-ink); border-radius: var(--ko-radius); box-shadow: var(--ko-shadow); }
.ko-theme .ko-tcard__img { padding: 14px 14px 0; }
.ko-theme .ko-tcard__img .ko-tmotif { aspect-ratio: 16 / 9; }
.ko-theme .ko-tcard__body { display: flex; flex-direction: column; gap: var(--ko-space-3); padding: 4px 18px 18px; }
.ko-theme .ko-tcard__name { flex: 1; min-height: 2.24em; margin: 0; font: 400 1.35rem/1.12 var(--ko-font-display); display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.ko-theme .ko-tcard .ko-tbuy .ko-quantity { flex: 1; }
.ko-theme .ko-tcard .ko-quantity__input { width: 100%; }
.ko-theme .ko-tcard[data-state="soldout"] .ko-tmotif { filter: grayscale(1); opacity: .5; }

/* ---------- Beschreibung auf Bild und Artikelname ---------- */
.ko-theme button.ko-tmotif { display: block; width: 100%; padding: 0; color: inherit; cursor: pointer; }
.ko-theme .ko-ticket-name-info { display: block; width: 100%; min-height: 44px; margin: 0; padding: 0; border: 0; background: none; color: inherit; font: inherit; text-align: inherit; overflow-wrap: anywhere; cursor: pointer; }
.ko-theme [data-ko-info]:focus-visible { outline: 3px solid var(--ko-blue-ink); outline-offset: 3px; border-radius: 4px; }
.ko-theme .ko-ticket-card[data-ko-info-open] { z-index: 6; }
.ko-theme[data-ko-tickets]:not([data-ko-enhanced]) .ko-ticket-card:has([data-ko-info]:hover, [data-ko-info]:focus) .ko-tinfo__pop[hidden] { display: block; }
.ko-theme .ko-tinfo__pop { position: absolute; z-index: 5; right: -12px; top: calc(100% + 8px); width: 280px; padding: 14px 16px; background: var(--ko-ink); color: #fff; border-radius: var(--ko-radius-soft); box-shadow: var(--ko-shadow); font-size: var(--ko-text-sm); line-height: 1.5; }
.ko-theme .ko-tinfo__pop[hidden] { display: none; }
.ko-theme .ko-tinfo__pop::before { content: ""; position: absolute; right: 22px; top: -8px; border: 8px solid transparent; border-top: 0; border-bottom-color: var(--ko-ink); }
.ko-theme .ko-tinfo__pop[data-ko-placement="above"]::before { top: auto; bottom: -8px; border-bottom: 0; border-top: 8px solid var(--ko-ink); }
.ko-theme .ko-tinfo__pop p { margin: 0; }
.ko-theme .ko-tinfo__pop a { color: #fff; }

/* ---------- Ratgeber ---------- */
.ko-theme .ko-advisor { display: flex; align-items: flex-end; gap: 6px; }
.ko-theme .ko-advisor__figure { display: block; flex: 0 0 92px; width: 92px; height: auto; }
.ko-theme .ko-advisor__bubble { position: relative; max-width: 300px; margin-bottom: 56px; padding: 14px 16px; background: var(--ko-white); border: var(--ko-border-strong) solid var(--ko-ink); border-radius: var(--ko-radius); box-shadow: var(--ko-shadow); }
.ko-theme .ko-advisor__bubble::before { content: ""; position: absolute; left: -15px; bottom: 18px; width: 22px; height: 22px; background: var(--ko-white); border-left: var(--ko-border-strong) solid var(--ko-ink); border-bottom: var(--ko-border-strong) solid var(--ko-ink); transform: rotate(45deg) skew(10deg, 10deg); }
.ko-theme .ko-advisor__bubble p { margin: 0 0 10px; font-size: var(--ko-text-sm); line-height: 1.45; }
.ko-theme .ko-advisor__panel { background: var(--ko-white); border: var(--ko-border-strong) solid var(--ko-ink); border-radius: var(--ko-radius); box-shadow: var(--ko-shadow-large); overflow: hidden; }
.ko-theme .ko-advisor__panel[hidden] { display: none; }
.ko-theme .ko-advisor__head { position: relative; isolation: isolate; display: flex; align-items: center; gap: 10px; padding: 10px 12px 10px 14px; background: var(--ko-sand); border-bottom: var(--ko-border-strong) solid var(--ko-ink); }
.ko-theme .ko-advisor__head::before { content: ""; position: absolute; inset: 0; z-index: -1; background: url("../../images/tickets/papier-struktur-stark.jpg") center / cover; mix-blend-mode: multiply; opacity: .9; pointer-events: none; }
.ko-theme .ko-advisor__head::after { content: ""; position: absolute; inset: 0; z-index: -1; background: radial-gradient(120% 140% at 85% 0%, rgba(203,191,164,.55), transparent 65%); pointer-events: none; }
.ko-theme .ko-advisor__head img { flex: 0 0 44px; width: 44px; height: auto; margin: -6px 0 -10px; }
.ko-theme .ko-advisor__title { flex: 1; min-width: 0; overflow-wrap: anywhere; margin: 0; color: var(--ko-ink); font: 400 1.35rem/1.15 var(--ko-font-display); }
.ko-theme .ko-advisor__body { display: flex; flex-direction: column; gap: var(--ko-space-4); padding: 18px 20px 22px; }
.ko-theme .ko-advisor__body :is([data-ko-advisor-form], [data-ko-advisor-result]) { display: flex; flex-direction: column; gap: var(--ko-space-3); min-width: 0; }
.ko-theme .ko-advisor__body :is(.ko-h3, .ko-small) { margin: 0; overflow-wrap: anywhere; }
.ko-theme .ko-advisor__body .ko-h3 { font: 400 1.6rem/1.15 var(--ko-font-display); }
.ko-theme .ko-advisor__copy { margin: 0; white-space: pre-line; overflow-wrap: anywhere; font: 400 var(--ko-text-sm)/1.5 var(--ko-font-body); }
.ko-theme .ko-advisor__step { margin: 0; font: 400 1rem/1.1 var(--ko-font-display); color: var(--ko-blue-ink); }
.ko-theme .ko-advisor__count { display: flex; justify-content: space-between; align-items: center; gap: var(--ko-space-3); padding-block: 10px; border-bottom: var(--ko-border-hair) solid var(--ko-sand-line); }
.ko-theme .ko-advisor__count strong { display: block; }
.ko-theme .ko-advisor__count span { font-size: var(--ko-text-sm); color: var(--ko-muted); }
.ko-theme .ko-advisor__result { container-type: inline-size; list-style: none; margin: var(--ko-space-1) 0 0; padding: 0; display: grid; gap: var(--ko-space-3); }
.ko-theme .ko-advisor__result li { position: relative; display: grid; grid-template-columns: 3.4rem minmax(0, 1fr) auto; align-items: stretch; padding: 0; background: var(--ko-white); border: var(--ko-border-strong) solid var(--ko-ink); border-radius: var(--ko-radius); box-shadow: 3px 3px 0 var(--ko-ink); }
.ko-theme .ko-advisor__result .n { position: relative; display: grid; place-items: center; padding: .55rem 0 .4rem; border-right: var(--ko-border) dashed var(--ko-ink); background: var(--ko-yellow); border-radius: .3rem 0 0 .4rem; font: 400 1.15rem/1 var(--ko-font-display); }
.ko-theme .ko-advisor__result .n::before,
.ko-theme .ko-advisor__result .n::after { content: ""; position: absolute; right: -9px; width: 16px; height: 16px; border: var(--ko-border) solid var(--ko-ink); border-radius: 50%; background: var(--ko-white); }
.ko-theme .ko-advisor__result .n::before { top: -10px; clip-path: inset(50% 0 0 0); }
.ko-theme .ko-advisor__result .n::after { bottom: -10px; clip-path: inset(0 0 50% 0); }
.ko-theme .ko-advisor__result .name { min-width: 0; height: auto; max-height: none; display: block; overflow: visible; -webkit-line-clamp: unset; overflow-wrap: anywhere; align-self: center; padding: .55rem .6rem .45rem .9rem; font: 400 .98rem/1.15 var(--ko-font-display); }
.ko-theme .ko-advisor__result .price { align-self: center; padding: .55rem .8rem .45rem .4rem; font: 400 1.05rem/1.15 var(--ko-font-display); white-space: nowrap; font-variant-numeric: tabular-nums; }
.ko-theme .ko-advisor__sum { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: baseline; gap: .5rem; margin: 0; padding-top: var(--ko-space-2); border-top: var(--ko-border-strong) solid var(--ko-ink); }
.ko-theme .ko-advisor__sum span { font: 400 1.1rem/1.15 var(--ko-font-display); }
.ko-theme .ko-advisor__sum strong { font: 400 1.8rem/1.15 var(--ko-font-display); font-variant-numeric: tabular-nums; }
.ko-theme .ko-advisor__back { align-self: center; position: relative; isolation: isolate; min-height: 44px; margin-top: var(--ko-space-1); padding: .3rem .5rem; border: 0; background: none; color: var(--ko-blue-ink); font: 400 1.15rem/1.1 var(--ko-font-display); transform: rotate(-2deg); cursor: pointer; text-decoration: none; }
.ko-theme .ko-advisor__back::before { content: "← "; }
.ko-theme .ko-advisor__back::after { content: ""; position: absolute; left: .3rem; right: .1rem; bottom: .1rem; height: .3rem; background: var(--ko-yellow); border-radius: 40% 20% 50% 25%; transform: rotate(-.6deg); z-index: -1; }
.ko-theme .ko-advisor__back:hover::after { height: .55rem; }
.ko-theme .ko-advisor__back:focus-visible { outline: 3px solid var(--ko-blue-ink); outline-offset: 3px; }
.ko-theme .ko-advisor__back:disabled { cursor: default; opacity: .6; }
@container (max-width: 18rem) {
  .ko-theme .ko-advisor__result li { grid-template-columns: 2.8rem minmax(0, 1fr); }
  .ko-theme .ko-advisor__result .n { grid-row: span 2; }
  .ko-theme .ko-advisor__result .price { grid-column: 2; padding: 0 .6rem .55rem .9rem; white-space: normal; overflow-wrap: anywhere; }
}
.ko-theme .ko-advisor__backdrop { position: fixed; inset: 0; z-index: var(--ko-layer-menu); background: color-mix(in srgb, var(--ko-ink) 45%, transparent); }
.ko-theme .ko-advisor__panel--side { position: fixed; z-index: calc(var(--ko-layer-menu) + 1); top: 24px; right: 24px; width: min(420px, calc(100vw - 48px)); max-height: calc(100vh - 48px); overflow: auto; }
.ko-theme .ko-advisor__fab { position: fixed; z-index: var(--ko-layer-header); right: 10px; bottom: 0; display: none; align-items: flex-end; gap: 4px; padding: 0; border: 0; background: none; cursor: pointer; }
.ko-theme .ko-advisor__fab img { width: 64px; height: auto; display: block; }
.ko-theme .ko-advisor__fab span { margin-bottom: 58px; padding: 8px 12px; background: var(--ko-ink); color: var(--ko-yellow); border-radius: 12px 12px 2px 12px; font: 400 .95rem/1 var(--ko-font-display); box-shadow: var(--ko-shadow); }
.ko-theme .ko-advisor__fab:focus-visible { outline: 3px solid var(--ko-white); outline-offset: 2px; box-shadow: 0 0 0 6px var(--ko-ink); }

/* ---------- Produktdetail ---------- */
.ko-theme .ko-tdetail { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.1fr); gap: var(--ko-space-7); align-items: start; padding: 22px; background: var(--ko-yellow); border: var(--ko-border-strong) solid var(--ko-ink); border-radius: var(--ko-radius); box-shadow: var(--ko-shadow-large); --ko-tmotif-bg: var(--ko-white); }
.ko-theme .ko-tdetail__body { display: flex; flex-direction: column; gap: var(--ko-space-4); }
.ko-theme .ko-tdetail__short { margin: 0; padding: var(--ko-space-4); background: var(--ko-white); border: var(--ko-border) solid var(--ko-ink); border-radius: var(--ko-radius-soft); }
.ko-theme .ko-tdetail__meta { margin: 0; font-size: var(--ko-text-sm); }

/* ---------- Smartphone ---------- */
@media (max-width: 767px) {
  .ko-theme .ko-tickets__head { display: block; }
  .ko-theme .ko-tickets__head .ko-advisor { display: none; }
  .ko-theme .ko-advisor__fab { display: flex; }
  .ko-theme .ko-advisor__panel--side { inset: auto 0 0 0; width: auto; max-height: 88vh; border-radius: 18px 18px 0 0; border-bottom: 0; }
  .ko-theme .ko-tstage { grid-template-columns: 1fr; padding: 16px; }
  .ko-theme .ko-tstage .ko-tmotif { max-width: 170px; }
  .ko-theme .ko-tstage .ko-tperf--v { display: none; }
  .ko-theme .ko-tstage__body { padding: var(--ko-space-4) 0 0; }
  .ko-theme .ko-tprice--xl { font-size: 3rem; }
  .ko-theme .ko-tstage .ko-tbuy .ko-button { flex: 1; }
  .ko-theme .ko-tgrid { grid-template-columns: 1fr; gap: 18px; }
  .ko-theme .ko-tcard { display: grid; grid-template-columns: 104px 26px minmax(0, 1fr); }
  .ko-theme .ko-tcard__img { padding: 12px 0 12px 12px; }
  .ko-theme .ko-tcard__img .ko-tmotif { aspect-ratio: 1; }
  .ko-theme .ko-tcard .ko-tperf--h { height: auto; margin: 0; }
  .ko-theme .ko-tcard .ko-tperf--h::before { left: 50%; right: auto; top: 16px; bottom: 16px; border-top: 0; border-left: var(--ko-border-strong) dashed var(--ko-ink); }
  .ko-theme .ko-tcard .ko-tperf--h i:first-child { left: -1px; top: -17px; clip-path: inset(50% 0 0 0); }
  .ko-theme .ko-tcard .ko-tperf--h i:last-child { left: -1px; right: auto; top: auto; bottom: -17px; clip-path: inset(0 0 50% 0); }
  .ko-theme .ko-tcard__body { padding: 12px 12px 12px 0; gap: var(--ko-space-2); }
  .ko-theme .ko-tcard__name { font-size: 1.1rem; min-height: 0; }
  .ko-theme .ko-tcard .ko-tprice { font-size: 1.9rem; }
  .ko-theme .ko-tinfo__pop { right: -6px; width: min(250px, 80vw); }
  .ko-theme .ko-tdetail { grid-template-columns: 1fr; gap: var(--ko-space-5); padding: 16px; }
}

/* ---------- Bewegung ---------- */
@media (prefers-reduced-motion: reduce) {
  .ko-theme .ko-advisor__figure[data-animated], .ko-theme .ko-advisor__fab img[data-animated] { display: none; }
}
.ko-theme[data-motion="off"] .ko-advisor__figure[data-animated] { display: none; }

/* JTL integration: scoped native controls and a modal dialog in the top layer. */
.ko-theme.ko-ticket-page { position: relative; padding-block: 1.5rem 3rem; background-color: var(--koa-content-surface, var(--ko-color-page)); }
/* In the shop, paper belongs to main-wrapper. Retain a fallback for standalone previews. */
.ko-theme.ko-ticket-page::before { content: var(--koa-local-paper-content, ""); position: absolute; inset: 0; pointer-events: none; opacity: .18; background-image: url("../../images/koa-paper-fibers.svg"), radial-gradient(ellipse at 15% 22%, rgba(255,255,255,.42), transparent 56%), radial-gradient(ellipse at 57% 75%, rgba(125,99,49,.19), transparent 68%); background-size: 512px 512px, 100% 100%, 100% 100%; background-repeat: repeat, no-repeat, no-repeat; }
.ko-theme.ko-ticket-page > .ko-container { position: relative; }
.ko-theme.ko-ticket-page [hidden] { display: none !important; }
.ko-theme .ko-tmotif { display: block; color: var(--ko-ink); }
.ko-theme .ko-ticket-image { position: relative; }
.ko-theme .ko-tmotif .first-wrapper { height: 100%; }
.ko-theme .ko-ticket-gallery { min-width: 0; }
.ko-theme .ko-ticket-gallery #gallery { background: var(--ko-white); border: var(--ko-border) solid var(--ko-ink); border-radius: var(--ko-radius-soft); overflow: hidden; }
.ko-theme .ko-ticket-gallery .product-image { object-fit: contain; }
.ko-theme .ko-tname-row h2 a { color: inherit; text-decoration: none; }
.ko-theme .ko-tname-row { min-width: 0; }
.ko-theme .ko-tname-row h2 { min-width: 0; overflow-wrap: anywhere; }
.ko-theme .ko-ticket-native-price .price { font: 400 2.5rem/1.1 var(--ko-font-display); margin: 0; }
.ko-theme .ko-ticket-native-price--large .price { font-size: clamp(2.5rem, 5vw, 4rem); }
.ko-theme .ko-ticket-native-price .vat_info { display: block; font: 400 var(--ko-text-xs)/1.5 var(--ko-font-body); margin-top: .5rem; }
.ko-theme .ko-ticket-status { padding: 1rem; border: var(--ko-border) solid var(--ko-ink); background: var(--ko-sand); border-radius: var(--ko-radius-soft); }
.ko-theme .ko-ticket-no-image { display: grid; place-items: center; min-height: 180px; font: 400 2rem var(--ko-font-display); }
.ko-theme .ko-ticket-text-button { border: 0; background: none; color: var(--ko-blue-ink); text-decoration: underline; min-height: 44px; padding: .5rem; cursor: pointer; }
.ko-theme .ko-ticket-description, .ko-theme .ko-ticket-more { margin-block: 2rem; }
.ko-theme .ko-ticket-description img { max-width: 100%; height: auto; }
.ko-theme.ko-ticket-detail .product-buy { margin: 0; }
.ko-theme.ko-ticket-detail .product-buy button { min-height: 44px; }
.ko-theme.ko-ticket-detail .product-buy .btn-primary { background: var(--ko-yellow); color: var(--ko-ink); border: var(--ko-border-strong) solid var(--ko-ink); box-shadow: var(--ko-shadow); font-family: var(--ko-font-display); }
.ko-theme.ko-ticket-detail .product-buy .input-group { flex-wrap: nowrap; }
.ko-theme.ko-ticket-detail .product-buy .quantity { min-width: 3rem; width: 3rem; text-align: center; }
.ko-theme dialog.ko-advisor__panel { padding: 0; color: var(--ko-ink); margin: 0; left: auto; bottom: auto; max-width: none; max-height: calc(100dvh - 48px); }
.ko-theme dialog.ko-advisor__panel:not([open]) { display: none; }
.ko-theme dialog::backdrop { background: color-mix(in srgb, var(--ko-ink) 45%, transparent); }
.ko-theme .ko-advisor__count label { margin: 0; flex: 1; min-width: 0; }
.ko-theme .ko-advisor__count .ko-quantity { flex-shrink: 0; }
.ko-theme .ko-advisor__count .ko-quantity__input { width: 3rem; }
.ko-theme .ko-advisor__fab { text-decoration: none; padding-bottom: env(safe-area-inset-bottom, 0px); }

.ko-theme .ko-tinfo__pop { width: min(280px, calc(100vw - 3rem)); right: 0; }
.ko-theme .ko-tbuy .ko-quantity { min-width: 0; }
.ko-theme .ko-quantity__button { flex-shrink: 0; min-width: 44px; min-height: 44px; }
/* One ordered grid: spans never reorder products or backfill gaps (keyboard/reading order). */
.ko-theme .ko-ticket-grid { align-items: stretch; row-gap: var(--ko-space-7); }
.ko-theme .ko-ticket-grid > .ko-tstage { margin-bottom: 0; min-width: 0; }
.ko-theme .ko-ticket-card { background: var(--ko-card-bg, var(--ko-white)); color: var(--ko-card-ink, var(--ko-ink)); min-width: 0; }
.ko-theme .ko-ticket-card :is(.ko-tstage__name, .ko-tcard__name, .ko-ticket-native-price, .price, .vat_info, .vat_info a) { color: inherit; }
.ko-theme .ko-ticket-card .ko-ticket-status { color: var(--ko-ink); }
.ko-theme .ko-ticket-card .ko-tinfo__pop { color: #fff; }
.ko-theme .ko-ticket-card .ko-tcard__name { display: block; overflow: visible; -webkit-line-clamp: unset; }
.ko-theme .ko-ticket-card .ko-tcard__body { flex: 1; }
.ko-theme .ko-ticket-card .ko-tcard__body > .ko-tbuy { margin-top: auto; }
.ko-theme .ko-ticket-card .ko-tbuy .ko-quantity { flex: 1 0 140px; }
.ko-theme .ko-ticket-card .ko-quantity__input { flex: 1; min-width: 2.5rem; width: 4rem; }
@media (min-width: 768px) {
  .ko-theme .ko-ticket-grid > .ko-ticket-span-2 { grid-column: span 2; }
  .ko-theme .ko-ticket-grid > .ko-ticket-span-3 { grid-column: 1 / -1; }
  .ko-theme .ko-ticket-grid > .ko-ticket-span-2 { grid-template-columns: minmax(130px, 28%) 34px minmax(0, 1fr); }
  .ko-theme .ko-ticket-span-2 .ko-tstage__name { font-size: clamp(1.5rem, 2.2vw, 2.5rem); }
  .ko-theme .ko-ticket-span-2 .ko-ticket-native-price--large .price { font-size: clamp(2rem, 3vw, 3.25rem); }
}
@media (min-width: 768px) and (max-width: 991px) {
  .ko-theme .ko-ticket-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .ko-theme .ko-ticket-grid > .ko-ticket-span-3 { grid-template-columns: minmax(130px, 28%) 34px minmax(0, 1fr); }
}
@media (max-width: 767px) {
  .ko-theme.ko-ticket-page { padding-bottom: 7rem; }
  .ko-theme .ko-ticket-grid { row-gap: 18px; }
  .ko-theme dialog.ko-advisor__panel { inset: auto 0 0; width: 100%; max-height: 92dvh; border-radius: var(--ko-radius-soft) var(--ko-radius-soft) 0 0; padding-bottom: env(safe-area-inset-bottom, 0px); }
  .ko-theme .ko-advisor__body { padding: 16px; }
  .ko-theme .ko-advisor__count { gap: 8px; }
  .ko-theme .ko-advisor__count strong { font-size: .9rem; }
  .ko-theme .ko-advisor__count .ko-quantity__input { width: 2.4rem; }
  .ko-theme .ko-ticket-native-price .price { font-size: 2rem; }
}

/* Native fragment navigation keeps the title and advisor visible. */
.ko-ticket-page #tickets { scroll-margin-top: 24px; }

/* Kompakte Quertickets: Darstellung separat vom vorhandenen Raster/Farbmodell. */
.ko-theme.ko-ticket-compact { padding-bottom: 1.5rem; }
.ko-theme.ko-ticket-compact > .ko-container { --ko-container: 72rem; }
.ko-theme.ko-ticket-compact .ko-tickets__legal { padding-block: 16px 24px; }
.ko-theme.ko-ticket-compact .ko-ticket-grid { gap: 22px; }

.ko-theme.ko-ticket-compact:has(.ko-ticket-grid > .ko-ticket-span-1:first-child) .ko-tickets__head { grid-template-columns: minmax(0, 1fr); }
.ko-theme.ko-ticket-compact .ko-ticket-card {
  --ko-ticket-motif: clamp(78px, 8vw, 110px);
  --ko-ticket-padding: 12px;
  display: grid; grid-template-columns: var(--ko-ticket-motif) 26px minmax(0, 1fr);
  align-items: center; padding: var(--ko-ticket-padding); container-type: inline-size;
}
.ko-theme.ko-ticket-compact .ko-tstage { --ko-ticket-motif: 170px; --ko-ticket-padding: 14px; }
.ko-theme.ko-ticket-compact .ko-ticket-image { min-width: 0; padding: 0; }
.ko-theme.ko-ticket-compact .ko-tmotif { width: 100%; max-width: none; aspect-ratio: 1; }
.ko-theme.ko-ticket-compact .ko-ticket-no-image { min-height: 0; height: 100%; font-size: 1rem; }
.ko-theme.ko-ticket-compact .ko-tperf--v { display: block; margin-block: calc(-1 * var(--ko-ticket-padding)); }
.ko-theme.ko-ticket-compact .ko-tperf--v i { left: 50%; transform: translateX(-50%); }
.ko-theme.ko-ticket-compact :is(.ko-tstage__body, .ko-tcard__body) { min-width: 0; gap: 6px; padding: 0; }
.ko-theme.ko-ticket-compact :is(.ko-tstage__name, .ko-tcard__name) { flex: 1; min-height: 0; font-size: 1.1rem; line-height: 1.15; }
.ko-theme.ko-ticket-compact .ko-tstage__name { font-size: 1.75rem; }

.ko-theme.ko-ticket-compact .ko-tname-row { gap: 0; }
.ko-theme.ko-ticket-compact .ko-tinfo__pop { overflow-wrap: anywhere; }
.ko-theme.ko-ticket-compact .ko-ticket-native-price .price { font-size: 1.9rem; line-height: 1.15; white-space: normal; overflow-wrap: anywhere; }
.ko-theme.ko-ticket-compact .ko-ticket-native-price--large .price { font-size: 2.8rem; }
.ko-theme.ko-ticket-compact .ko-ticket-native-price .vat_info { margin-top: 2px; }
.ko-theme.ko-ticket-compact .ko-tbuy { gap: 8px; margin: 0; }
.ko-theme.ko-ticket-compact .ko-tbuy .ko-quantity { flex: 1 1 132px; }
.ko-theme.ko-ticket-compact .ko-quantity__input { width: 2.5rem; min-width: 2rem; }
.ko-theme.ko-ticket-compact .ko-tbuy .ko-button { min-width: 44px; min-height: 44px; padding: 6px 8px; flex: 0 0 auto; }
.ko-theme.ko-ticket-compact .ko-ticket-status { padding: 6px; margin: 0; }
/* Text darf bei Zoom wachsen; lange Formulare umbrechen statt über den Rand laufen. */
@container (max-width: 34rem) {
  .ko-theme.ko-ticket-compact .ko-tbuy__label { display: none; }
}
@media (min-width: 768px) and (max-width: 1199px) {
  .ko-theme.ko-ticket-compact .ko-ticket-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 767px) {
  .ko-theme.ko-ticket-compact .ko-ticket-grid { gap: 14px; }
  .ko-theme.ko-ticket-compact .ko-ticket-card { --ko-ticket-motif: 78px; --ko-ticket-padding: 10px; grid-template-columns: 78px 22px minmax(0, 1fr); }
  .ko-theme.ko-ticket-compact .ko-tstage__name { font-size: 1.25rem; }
  .ko-theme.ko-ticket-compact .ko-ticket-native-price .price { font-size: 1.65rem; }
  .ko-theme.ko-ticket-compact .ko-ticket-native-price--large .price { font-size: 1.9rem; }
}

/* Ein fester Einstieg im Dokumentfluss, auch mobil; keine verdeckende FAB. */
.ko-theme.ko-ticket-page:not(.ko-ticket-detail) .ko-tickets__head { align-items: end; }
.ko-theme.ko-ticket-page:not(.ko-ticket-detail) .ko-advisor { align-self: end; justify-self: start; }
.ko-theme.ko-ticket-page:not(.ko-ticket-detail) .ko-advisor__figure { flex-basis: 64px; width: 64px; }
.ko-theme.ko-ticket-page:not(.ko-ticket-detail) .ko-advisor__bubble { margin-bottom: 30px; }
@media (max-width: 767px) {
  .ko-theme.ko-ticket-page:not(.ko-ticket-detail) { padding-bottom: 2rem; }
  .ko-theme.ko-ticket-page:not(.ko-ticket-detail) .ko-tickets__head { display: flex; flex-wrap: wrap; gap: 0 10px; }
  .ko-theme.ko-ticket-page:not(.ko-ticket-detail) .ko-tickets__title { flex: 1 1 110px; padding-bottom: 20px; }
  .ko-theme.ko-ticket-page:not(.ko-ticket-detail) .ko-tickets__title .ko-h2 { font-size: 2rem; }
  .ko-theme.ko-ticket-page:not(.ko-ticket-detail) .ko-tickets__event { font-size: .8125rem; }
  .ko-theme.ko-ticket-page:not(.ko-ticket-detail) .ko-tickets__head .ko-advisor { display: flex; margin-left: auto; max-width: 100%; }
  .ko-theme.ko-ticket-page:not(.ko-ticket-detail) .ko-advisor__figure { flex: 0 0 46px; width: 46px; }
  .ko-theme.ko-ticket-page:not(.ko-ticket-detail) .ko-advisor__bubble { max-width: 160px; margin-bottom: 24px; padding: 8px; }
  .ko-theme.ko-ticket-page:not(.ko-ticket-detail) .ko-advisor__bubble p { font-size: .75rem; }
  .ko-theme.ko-ticket-page:not(.ko-ticket-detail) .ko-advisor__bubble .ko-button { font-size: .875rem; min-height: 44px; padding: 6px; }
}
