/* ==========================================================================
   ENERGETIX Ticket-Personalisierung – Stylesheet
   ========================================================================== */

:root {
	--navy-950: #000d26;
	--navy-900: #001741;
	--navy-700: #003579;
	--navy-500: #42618f;
	--navy-200: #c9d5e8;
	--navy-100: #e6ecf6;
	--navy-50: #f3f6fb;
	--red-600: #d00017;
	--red-700: #a80013;
	--red-50: #fdecee;
	--green-600: #0f7a45;
	--green-50: #e8f6ee;
	--amber-600: #a15c00;
	--amber-50: #fff5e5;

	--bg: #f1f4f9;
	--surface: #ffffff;
	--text: #0d1a33;
	--muted: #5a6a85;
	--border: #dbe2ee;
	--focus: 0 0 0 3px rgb(0 53 121 / 0.25);

	--radius-lg: 18px;
	--radius: 12px;
	--radius-sm: 8px;
	--shadow-sm: 0 1px 2px rgb(0 23 65 / 0.06);
	--shadow: 0 1px 2px rgb(0 23 65 / 0.05), 0 10px 30px -10px rgb(0 23 65 / 0.18);
	--shadow-lg: 0 24px 60px -20px rgb(0 23 65 / 0.35);

	--font: "Inter", "Segoe UI", system-ui, -apple-system, "Helvetica Neue", Arial, sans-serif;
	--ease: cubic-bezier(0.2, 0.7, 0.2, 1);

	color-scheme: light;
}

/* ---------- Basis ---------- */

*, *::before, *::after { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; scroll-padding-top: 1.5rem; }

body {
	margin: 0;
	min-height: 100vh;
	display: flex;
	flex-direction: column;
	background: var(--bg);
	color: var(--text);
	font: 400 15px/1.55 var(--font);
	-webkit-font-smoothing: antialiased;
}

img, svg { display: block; max-width: 100%; }
a { color: var(--navy-700); text-underline-offset: 3px; }
a:hover { color: var(--red-600); }
h1, h2, h3 { line-height: 1.2; margin: 0; letter-spacing: -0.01em; }
p { margin: 0 0 0.75em; }
[hidden] { display: none !important; }
::selection { background: var(--navy-900); color: #fff; }
:focus-visible { outline: none; box-shadow: var(--focus); }

.container { width: min(1120px, 100% - 32px); margin-inline: auto; }
.main { flex: 1; padding-block: 28px 48px; display: grid; gap: 20px; align-content: start; }

.icon { width: 18px; height: 18px; flex: none; }

.prose { color: var(--text); }
.prose > :last-child { margin-bottom: 0; }

/* ---------- Kopfbereich ---------- */

.hero {
	position: relative;
	color: #fff;
	background:
		radial-gradient(1200px 400px at 85% -20%, rgb(208 0 23 / 0.35), transparent 60%),
		linear-gradient(135deg, var(--navy-900), var(--navy-700));
	overflow: hidden;
}

.hero--teaser {
	background:
		linear-gradient(90deg, rgb(0 23 65 / 0.94) 0%, rgb(0 23 65 / 0.75) 45%, rgb(0 23 65 / 0.35) 100%),
		var(--teaser) center / cover no-repeat,
		var(--navy-900);
}

.hero::after {
	content: "";
	position: absolute;
	inset: auto 0 0;
	height: 4px;
	background: linear-gradient(90deg, var(--red-600), transparent 70%);
}

.hero__inner {
	display: grid;
	grid-template-columns: auto 1fr auto;
	align-items: center;
	gap: 28px;
	padding-block: 26px 30px;
}

.brand {
	display: block;
	background: #fff;
	border-radius: var(--radius);
	padding: 8px 14px;
	box-shadow: var(--shadow);
}
.brand img { width: 132px; height: auto; }

.hero__eyebrow {
	margin: 0 0 6px;
	font-size: 12px;
	font-weight: 600;
	letter-spacing: 0.12em;
	text-transform: uppercase;
	color: rgb(255 255 255 / 0.72);
}

.hero__title { font-size: clamp(22px, 3.4vw, 34px); font-weight: 700; text-transform: uppercase; }

.hero__meta {
	display: inline-flex;
	align-items: center;
	gap: 8px;
	margin: 10px 0 0;
	padding: 4px 12px 4px 10px;
	border-radius: 999px;
	background: rgb(255 255 255 / 0.12);
	font-size: 14px;
	font-weight: 500;
}

.hero__tools { display: flex; gap: 8px; align-items: center; align-self: start; }

/* ---------- Buttons ---------- */

.btn {
	--btn-bg: var(--surface);
	--btn-fg: var(--navy-900);
	--btn-border: var(--border);
	display: inline-flex;
	align-items: center;
	justify-content: center;
	gap: 8px;
	min-height: 42px;
	padding: 0 18px;
	border: 1px solid var(--btn-border);
	border-radius: 999px;
	background: var(--btn-bg);
	color: var(--btn-fg);
	font: 600 14px/1 var(--font);
	text-decoration: none;
	white-space: nowrap;
	cursor: pointer;
	transition: transform 0.15s var(--ease), background 0.15s, box-shadow 0.15s, border-color 0.15s;
}
.btn:hover { color: var(--btn-fg); border-color: var(--navy-500); }
.btn:active { transform: translateY(1px); }
.btn:disabled { opacity: 0.6; cursor: progress; }

.btn--primary { --btn-bg: var(--navy-900); --btn-fg: #fff; --btn-border: var(--navy-900); box-shadow: 0 6px 16px -6px rgb(0 23 65 / 0.6); }
.btn--primary:hover { --btn-bg: var(--navy-700); --btn-border: var(--navy-700); }
.btn--primary.is-ready { --btn-bg: var(--red-600); --btn-border: var(--red-600); box-shadow: 0 6px 18px -6px rgb(208 0 23 / 0.7); animation: pulse 2.2s infinite; }
.btn--primary.is-ready:hover { --btn-bg: var(--red-700); }
.btn--secondary { --btn-bg: var(--navy-100); --btn-border: transparent; }
.btn--secondary:hover { --btn-bg: var(--navy-200); --btn-border: transparent; }
.btn--ghost { --btn-bg: transparent; --btn-border: transparent; color: var(--muted); }
.btn--ghost:hover { --btn-bg: var(--navy-50); color: var(--navy-900); }
.btn--danger { --btn-bg: var(--red-50); --btn-fg: var(--red-700); --btn-border: transparent; }
.btn--danger:hover { --btn-bg: var(--red-600); --btn-fg: #fff; }
.btn--sm { min-height: 32px; padding: 0 12px; font-size: 13px; }
.btn.is-loading { position: relative; color: transparent; }
.btn.is-loading::after {
	content: "";
	position: absolute;
	width: 18px;
	height: 18px;
	border: 2px solid #fff;
	border-right-color: transparent;
	border-radius: 50%;
	animation: spin 0.7s linear infinite;
}

.icon-btn {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	gap: 6px;
	min-width: 40px;
	height: 40px;
	padding: 0 10px;
	border: 1px solid rgb(255 255 255 / 0.25);
	border-radius: 999px;
	background: rgb(255 255 255 / 0.1);
	color: #fff;
	font: 600 13px/1 var(--font);
	cursor: pointer;
	list-style: none;
	transition: background 0.15s;
}
.icon-btn:hover { background: rgb(255 255 255 / 0.22); color: #fff; }
.icon-btn::-webkit-details-marker { display: none; }
.icon-btn--ghost { border-color: transparent; background: transparent; color: var(--muted); }
.icon-btn--ghost:hover { background: var(--red-50); color: var(--red-600); }

/* ---------- Sprachmenü ---------- */

.langmenu { position: relative; }
.langmenu__list {
	position: absolute;
	right: 0;
	top: calc(100% + 8px);
	z-index: 20;
	min-width: 180px;
	padding: 6px;
	border-radius: var(--radius);
	background: var(--surface);
	box-shadow: var(--shadow-lg);
}
.langmenu__list a {
	display: block;
	padding: 8px 12px;
	border-radius: var(--radius-sm);
	color: var(--text);
	text-decoration: none;
	font-weight: 500;
}
.langmenu__list a:hover, .langmenu__list a.is-active { background: var(--navy-50); color: var(--navy-900); }
.langmenu__list a.is-active { font-weight: 700; }

/* ---------- Karten & Hinweise ---------- */

.card {
	background: var(--surface);
	border: 1px solid var(--border);
	border-radius: var(--radius-lg);
	box-shadow: var(--shadow-sm);
	padding: 24px;
}

.card__title { font-size: 22px; margin-bottom: 12px; }
.card__actions { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 22px; }
.card__icon {
	display: grid;
	place-items: center;
	width: 52px;
	height: 52px;
	margin-bottom: 16px;
	border-radius: 50%;
	background: var(--green-50);
	color: var(--green-600);
}
.card__icon .icon { width: 26px; height: 26px; }
.card--success { border-top: 4px solid var(--green-600); max-width: 760px; }

.alert {
	display: flex;
	gap: 14px;
	align-items: flex-start;
	padding: 16px 18px;
	border-radius: var(--radius);
	border: 1px solid;
	animation: fade-in 0.3s var(--ease);
}
.alert__icon { width: 22px; height: 22px; flex: none; margin-top: 1px; }
.alert__title { display: block; font-weight: 600; }
.alert__text { margin-top: 4px; }
.alert__text a { color: inherit; font-weight: 600; }
.alert--error { background: var(--red-50); border-color: #f6c2c8; color: var(--red-700); }
.alert--success { background: var(--green-50); border-color: #bfe5cf; color: var(--green-600); }
.alert--info { background: var(--navy-50); border-color: var(--navy-200); color: var(--navy-900); }
.alert--warning { background: var(--amber-50); border-color: #f3d39b; color: var(--amber-600); }

/* ---------- Ticketzähler ---------- */

.counters {
	display: grid;
	grid-template-columns: repeat(auto-fit, minmax(170px, 1fr));
	gap: 12px;
}

.counter {
	--progress: 0;
	position: relative;
	display: grid;
	gap: 6px;
	padding: 14px 16px 18px;
	border-radius: var(--radius);
	background: var(--surface);
	border: 1px solid var(--border);
	box-shadow: var(--shadow-sm);
	cursor: help;
	overflow: hidden;
	transition: border-color 0.2s;
}
.counter__label {
	display: flex;
	align-items: center;
	gap: 8px;
	font-size: 13px;
	font-weight: 600;
	color: var(--muted);
}
.counter__label .icon { width: 16px; height: 16px; color: var(--navy-500); }
.counter__value { display: flex; align-items: baseline; gap: 6px; }
.counter__value b { font-size: 28px; line-height: 1; color: var(--navy-900); font-variant-numeric: tabular-nums; }
.counter__value small { color: var(--muted); font-size: 13px; }
.counter__bar { position: absolute; inset: auto 0 0; height: 4px; background: var(--navy-100); }
.counter__bar i {
	display: block;
	height: 100%;
	width: calc(var(--progress) * 100%);
	background: var(--navy-700);
	transition: width 0.35s var(--ease), background 0.2s;
}
.counter.is-done { border-color: #bfe5cf; }
.counter.is-done .counter__bar i { background: var(--green-600); }
.counter.is-done .counter__value b { color: var(--green-600); }
.counter.is-over { border-color: #f6c2c8; }
.counter.is-over .counter__value b { color: var(--red-600); }
.counter--total { background: var(--navy-900); border-color: var(--navy-900); }
.counter--total .counter__label, .counter--total .counter__value small { color: rgb(255 255 255 / 0.7); }
.counter--total .counter__label .icon { color: rgb(255 255 255 / 0.7); }
.counter--total .counter__value b { color: #fff; }
.counter--total .counter__bar { background: rgb(255 255 255 / 0.15); }
.counter--total .counter__bar i { background: #fff; }
.counter--total.is-done .counter__value b { color: #fff; }
.counter--total.is-done .counter__bar i { background: #5fd394; }

/* ---------- Intro ---------- */

.intro { padding: 0; }
.intro__summary {
	display: flex;
	align-items: center;
	gap: 12px;
	padding: 18px 24px;
	font-size: 17px;
	font-weight: 700;
	color: var(--navy-900);
	cursor: pointer;
	list-style: none;
}
.intro__summary::-webkit-details-marker { display: none; }
.intro__summary .icon { color: var(--red-600); width: 22px; height: 22px; }
.intro__summary::after {
	content: "";
	margin-left: auto;
	width: 10px;
	height: 10px;
	border-right: 2px solid var(--muted);
	border-bottom: 2px solid var(--muted);
	transform: rotate(45deg);
	transition: transform 0.2s;
}
.intro[open] .intro__summary::after { transform: rotate(-135deg); }
.intro .prose { padding: 0 24px 22px 58px; color: var(--muted); }

/* ---------- Personen ---------- */

.ticketform { display: grid; gap: 20px; }
.guests { display: grid; gap: 20px; }

.guest { padding: 0; overflow: hidden; scroll-margin-top: 16px; }
.guest.is-entering { animation: slide-in 0.35s var(--ease); }
.guest--error { border-color: #f6c2c8; box-shadow: 0 0 0 3px rgb(208 0 23 / 0.08); }
.guest > .alert { margin: 16px 24px 0; }

.guest__head {
	display: flex;
	align-items: center;
	gap: 12px;
	padding: 14px 16px 14px 24px;
	border-bottom: 1px solid var(--border);
	background: linear-gradient(180deg, var(--navy-50), var(--surface));
}
.guest__badge {
	display: grid;
	place-items: center;
	width: 34px;
	height: 34px;
	border-radius: 50%;
	background: var(--navy-900);
	color: #fff;
}
.guest__badge .icon { width: 16px; height: 16px; }
.guest__title { flex: 1; font-size: 16px; font-weight: 700; color: var(--navy-900); }
.guest__name { font-weight: 500; color: var(--muted); }
.guest__name:not(:empty)::before { content: "· "; }

.guest__body {
	display: grid;
	grid-template-columns: minmax(0, 1.5fr) minmax(0, 0.9fr) minmax(260px, 1fr);
	gap: 0;
}

.step { margin: 0; padding: 22px 24px 24px; border: 0; min-width: 0; }
.step + .step { border-left: 1px solid var(--border); }
.step__title {
	display: flex;
	align-items: center;
	gap: 10px;
	padding: 0;
	margin: 0 0 16px;
	font-size: 13px;
	font-weight: 700;
	letter-spacing: 0.06em;
	text-transform: uppercase;
	color: var(--navy-700);
}
.step__num {
	display: grid;
	place-items: center;
	width: 24px;
	height: 24px;
	border-radius: 50%;
	background: var(--red-600);
	color: #fff;
	font-size: 12px;
	letter-spacing: 0;
}
/* <legend> sitzt sonst auf der Rahmenkante – so liegt sie wie Schritt 3 im Innenabstand */
legend.step__title { float: left; width: 100%; }
legend.step__title + * { clear: both; }
.step.is-invalid .step__title { color: var(--red-600); }
.step.is-invalid .chips { outline: 2px dashed #f6c2c8; outline-offset: 6px; border-radius: var(--radius-sm); }

/* ---------- Formularfelder ---------- */

.fields { display: grid; grid-template-columns: 1fr 1fr; gap: 14px 16px; }
.field { display: grid; gap: 6px; align-content: start; min-width: 0; }
.field--wide { grid-column: 1 / -1; }
.field > label, .field__label { font-size: 13px; font-weight: 600; color: var(--muted); }

input[type="text"], input[type="password"], input[type="date"], input[type="number"], input[type="file"], select, textarea {
	width: 100%;
	min-height: 44px;
	padding: 10px 12px;
	border: 1px solid var(--border);
	border-radius: var(--radius-sm);
	background: var(--surface);
	color: var(--text);
	font: inherit;
	transition: border-color 0.15s, box-shadow 0.15s;
}
textarea { min-height: 120px; resize: vertical; font-family: ui-monospace, "SF Mono", Menlo, Consolas, monospace; font-size: 13px; }
select {
	appearance: none;
	padding-right: 36px;
	background: var(--surface) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%235a6a85' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E") right 10px center / 18px no-repeat;
	cursor: pointer;
}
input:hover, select:hover, textarea:hover { border-color: var(--navy-200); }
input:focus, select:focus, textarea:focus { outline: none; border-color: var(--navy-700); box-shadow: var(--focus); }
input::placeholder { color: #a3afc2; }

.field.is-invalid > label, .field.is-invalid .field__label { color: var(--red-600); }
.field.is-invalid input, .field.is-invalid select { border-color: var(--red-600); background-color: #fffafa; }
.field.is-invalid input:focus, .field.is-invalid select:focus { box-shadow: 0 0 0 3px rgb(208 0 23 / 0.2); }

.segmented {
	display: inline-grid;
	grid-auto-flow: column;
	grid-auto-columns: 1fr;
	padding: 4px;
	border-radius: 999px;
	background: var(--navy-50);
	border: 1px solid var(--border);
	justify-self: start;
	min-width: 220px;
}
.field.is-invalid .segmented { border-color: var(--red-600); }
.segmented__option { position: relative; cursor: pointer; }
.segmented__option input { position: absolute; opacity: 0; inset: 0; cursor: pointer; }
.segmented__option span {
	display: block;
	padding: 8px 18px;
	border-radius: 999px;
	text-align: center;
	font-weight: 600;
	font-size: 14px;
	color: var(--muted);
	transition: background 0.15s, color 0.15s;
}
.segmented__option input:checked + span { background: var(--navy-900); color: #fff; box-shadow: var(--shadow-sm); }
.segmented__option input:focus-visible + span { box-shadow: var(--focus); }

/* ---------- Ticket-Auswahl ---------- */

.chips { display: grid; gap: 10px; }
.chip { position: relative; display: block; cursor: pointer; }
.chip input { position: absolute; opacity: 0; pointer-events: none; }
.chip__body {
	display: flex;
	align-items: center;
	gap: 12px;
	padding: 12px 14px;
	border: 1.5px solid var(--border);
	border-radius: var(--radius);
	background: var(--surface);
	transition: border-color 0.15s, background 0.15s, transform 0.15s var(--ease);
	/* Ticket-Kerben */
	-webkit-mask: radial-gradient(circle 7px at 0 50%, #0000 98%, #000) left / 51% 100% no-repeat,
		radial-gradient(circle 7px at 100% 50%, #0000 98%, #000) right / 51% 100% no-repeat;
	mask: radial-gradient(circle 7px at 0 50%, #0000 98%, #000) left / 51% 100% no-repeat,
		radial-gradient(circle 7px at 100% 50%, #0000 98%, #000) right / 51% 100% no-repeat;
}
.chip__check {
	display: grid;
	place-items: center;
	width: 22px;
	height: 22px;
	flex: none;
	border: 1.5px solid var(--navy-200);
	border-radius: 6px;
	color: transparent;
	transition: background 0.15s, border-color 0.15s;
}
.chip__check .icon { width: 14px; height: 14px; stroke-width: 3; }
.chip__label { font-weight: 600; font-size: 14px; color: var(--text); text-transform: uppercase; letter-spacing: 0.02em; }
.chip:hover .chip__body { border-color: var(--navy-500); }
.chip input:checked + .chip__body { border-color: var(--navy-900); background: var(--navy-900); }
.chip input:checked + .chip__body .chip__check { background: var(--red-600); border-color: var(--red-600); color: #fff; }
.chip input:checked + .chip__body .chip__label { color: #fff; }
.chip input:focus-visible + .chip__body { box-shadow: var(--focus); }
.chip.is-disabled { cursor: not-allowed; }
.chip.is-disabled .chip__body { opacity: 0.45; background: var(--navy-50); border-style: dashed; }
.chip.is-disabled:hover .chip__body { border-color: var(--border); }

/* ---------- Ticket-Vorschau ---------- */

.step--preview { background: var(--navy-50); }

.ticket-preview {
	position: relative;
	width: 100%;
	max-width: 420px;
	margin-inline: auto;
	aspect-ratio: 285 / 166;
	border-radius: 12px;
	/* Hintergrund exakt auf die Karte skalieren – nicht beschneiden */
	background: #fff url("../gfx/bg_sample.png") 0 0 / 100% 100% no-repeat;
	box-shadow: var(--shadow);
	overflow: hidden;
	container-type: inline-size;
	color: var(--navy-900);
	text-align: center;
}

/* "MUSTER" im blauen Band des Hintergrundbilds */
.ticket-preview__sample {
	position: absolute;
	top: 20.5%;
	left: 27%;
	font-weight: 800;
	font-size: 5.4cqw;
	line-height: 1;
	letter-spacing: 0.08em;
	color: #fff;
}

/* Textbereich unterhalb des Bands: Name, Titel, Land untereinander ohne Überlappung */
.ticket-preview__body {
	position: absolute;
	inset: 42% 7% 8%;
	display: flex;
	flex-direction: column;
	align-items: center;
	justify-content: center;
	gap: 1.6cqw;
	padding: 2cqw 3cqw;
	border-radius: 2cqw;
	background: rgb(255 255 255 / 0.82);
}
.ticket-preview__body > span { max-width: 100%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; line-height: 1.15; }
.ticket-preview__name { font-weight: 800; font-size: 6.4cqw; text-transform: uppercase; letter-spacing: 0.01em; }
.ticket-preview__title { font-size: 3.4cqw; color: var(--muted); }
.ticket-preview__country { font-weight: 600; font-size: 4.8cqw; }

/* Gewählte Tickets unter der Vorschau */
.preview-tickets {
	display: flex;
	flex-wrap: wrap;
	justify-content: center;
	gap: 6px;
	margin-top: 14px;
}
.preview-tickets:empty { display: none; }
.preview-tickets i {
	display: inline-flex;
	align-items: center;
	gap: 6px;
	padding: 4px 10px;
	border-radius: 999px;
	background: var(--navy-900);
	color: #fff;
	font: 700 11px/1.3 var(--font);
	letter-spacing: 0.04em;
	text-transform: uppercase;
}
.preview-tickets i::before {
	content: "";
	width: 6px;
	height: 6px;
	border-radius: 50%;
	background: var(--red-600);
}

/* ---------- Aktionsleiste ---------- */

.actionbar {
	position: sticky;
	bottom: 0;
	z-index: 10;
	margin-inline: calc(50% - 50vw);
	padding-block: 12px calc(12px + env(safe-area-inset-bottom));
	background: rgb(255 255 255 / 0.88);
	backdrop-filter: saturate(1.4) blur(12px);
	border-top: 1px solid var(--border);
	box-shadow: 0 -10px 30px -18px rgb(0 23 65 / 0.35);
}
.actionbar__inner { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.actionbar__progress { margin-left: auto; color: var(--muted); font-size: 14px; font-weight: 500; font-variant-numeric: tabular-nums; }

/* ---------- Fußbereich ---------- */

.footer { border-top: 1px solid var(--border); background: var(--surface); color: var(--muted); font-size: 13px; }
.footer__inner { display: flex; justify-content: space-between; gap: 12px; flex-wrap: wrap; padding-block: 16px; }
.footer__muted { opacity: 0.75; }

.debug pre { overflow: auto; font-size: 12px; }

/* ==========================================================================
   Administration
   ========================================================================== */

.adminnav { background: var(--surface); border-bottom: 1px solid var(--border); box-shadow: var(--shadow-sm); position: sticky; top: 0; z-index: 15; }
.adminnav__inner { display: flex; gap: 4px; overflow-x: auto; padding-block: 8px; scrollbar-width: none; }
.adminnav__link {
	display: inline-flex;
	align-items: center;
	gap: 8px;
	padding: 8px 14px;
	border-radius: 999px;
	color: var(--muted);
	font-weight: 600;
	font-size: 14px;
	text-decoration: none;
	white-space: nowrap;
}
.adminnav__link:hover { background: var(--navy-50); color: var(--navy-900); }
.adminnav__link.is-active { background: var(--navy-900); color: #fff; }
.adminnav__link--end { margin-left: auto; }

.page-head { display: flex; align-items: center; justify-content: space-between; gap: 16px; flex-wrap: wrap; }
.page-head h2 { font-size: 24px; color: var(--navy-900); }
.page-head p { margin: 4px 0 0; color: var(--muted); }
.page-head__actions { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; }
.page-head__actions select { width: auto; min-width: 240px; }

.tiles { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 16px; }
.tile {
	display: grid;
	gap: 10px;
	padding: 22px;
	border-radius: var(--radius-lg);
	background: var(--surface);
	border: 1px solid var(--border);
	box-shadow: var(--shadow-sm);
	color: var(--text);
	text-decoration: none;
	transition: transform 0.2s var(--ease), box-shadow 0.2s, border-color 0.2s;
}
.tile:hover { transform: translateY(-3px); box-shadow: var(--shadow); border-color: var(--navy-200); color: var(--text); }
.tile__icon { display: grid; place-items: center; width: 46px; height: 46px; border-radius: 12px; background: var(--navy-100); color: var(--navy-900); }
.tile__icon .icon { width: 22px; height: 22px; }
.tile--accent .tile__icon { background: var(--red-50); color: var(--red-600); }
.tile strong { font-size: 16px; }
.tile span { color: var(--muted); font-size: 14px; }

.table-wrap { overflow-x: auto; border-radius: var(--radius-lg); border: 1px solid var(--border); background: var(--surface); box-shadow: var(--shadow-sm); }
.table { width: 100%; border-collapse: collapse; font-size: 14px; }
.table th, .table td { padding: 12px 14px; text-align: left; border-bottom: 1px solid var(--border); white-space: nowrap; }
.table th { background: var(--navy-50); color: var(--muted); font-size: 12px; font-weight: 700; letter-spacing: 0.05em; text-transform: uppercase; position: sticky; top: 0; }
.table tbody tr:hover td { background: #fafbfe; }
.table tbody tr:last-child td { border-bottom: 0; }
.table .actions { text-align: right; }
.table .actions > * + * { margin-left: 6px; }
.table .empty { text-align: center; color: var(--muted); padding: 40px; white-space: normal; }

.badge { display: inline-flex; align-items: center; gap: 4px; padding: 2px 10px; border-radius: 999px; font-size: 12px; font-weight: 700; }
.badge--yes { background: var(--green-50); color: var(--green-600); }
.badge--no { background: var(--red-50); color: var(--red-700); }
.badge--muted { background: var(--navy-50); color: var(--muted); }

.form-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 16px 20px; }
.form-section + .form-section { margin-top: 24px; padding-top: 24px; border-top: 1px solid var(--border); }
.form-section h3 { font-size: 15px; margin-bottom: 14px; color: var(--navy-900); }
.form-actions { display: flex; gap: 10px; justify-content: space-between; flex-wrap: wrap; margin-top: 24px; }
.hint { color: var(--muted); font-size: 13px; }

.codebox { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; }
.codebox input { flex: 1 1 420px; font-family: ui-monospace, "SF Mono", Menlo, Consolas, monospace; font-size: 13px; background: var(--navy-50); }

.login { max-width: 420px; width: 100%; margin: 24px auto; }
.login h2 { font-size: 22px; margin-bottom: 4px; color: var(--navy-900); }
.login p { color: var(--muted); }
.login form { display: grid; gap: 14px; margin-top: 18px; }

.upload-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(320px, 1fr)); gap: 16px; }
.upload-grid .card { display: grid; gap: 12px; align-content: start; }
.upload-grid h3 { font-size: 16px; color: var(--navy-900); }
.upload-grid form { display: grid; gap: 10px; }

.log { max-height: 360px; overflow: auto; padding: 12px; border-radius: var(--radius-sm); background: var(--navy-950); color: #cfe0ff; font: 12px/1.6 ui-monospace, Menlo, Consolas, monospace; }

/* ==========================================================================
   Responsiv
   ========================================================================== */

@media (max-width: 980px) {
	.guest__body { grid-template-columns: 1fr 1fr; }
	.step--preview { grid-column: 1 / -1; border-left: 0 !important; border-top: 1px solid var(--border); }
	.ticket-preview { max-width: 380px; }
}

@media (max-width: 680px) {
	body { font-size: 15px; }
	.hero__inner { grid-template-columns: 1fr auto; gap: 16px; padding-block: 18px 22px; }
	.brand { grid-column: 1; }
	.brand img { width: 104px; }
	.hero__tools { grid-column: 2; grid-row: 1; }
	.hero__text { grid-column: 1 / -1; }
	.guest__body { grid-template-columns: 1fr; }
	.step + .step { border-left: 0; border-top: 1px solid var(--border); }
	.step, .card { padding: 18px; }
	.guest__head { padding-left: 18px; }
	.fields { grid-template-columns: 1fr; }
	.segmented { width: 100%; }
	.actionbar__inner { gap: 8px; }
	.actionbar__inner .btn { flex: 1 1 auto; }
	.actionbar__inner .btn--ghost { display: none; }
	.actionbar__progress { order: -1; width: 100%; margin: 0; text-align: center; }
	.intro .prose { padding-left: 24px; }
}

/* ---------- Animationen ---------- */

@keyframes spin { to { transform: rotate(360deg); } }
@keyframes fade-in { from { opacity: 0; transform: translateY(-4px); } }
@keyframes slide-in { from { opacity: 0; transform: translateY(12px); } }
@keyframes pulse {
	0%, 100% { box-shadow: 0 6px 18px -6px rgb(208 0 23 / 0.7); }
	50% { box-shadow: 0 6px 26px -2px rgb(208 0 23 / 0.55); }
}

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

@media print {
	.hero, .actionbar, .adminnav, .footer, .counters { display: none; }
	body { background: #fff; }
}
