@font-face { font-family: "Oswald"; font-weight: 500; font-display: swap; src: url("fonts/oswald-latin-500-normal.woff2") format("woff2"); }
@font-face { font-family: "Oswald"; font-weight: 700; font-display: swap; src: url("fonts/oswald-latin-700-normal.woff2") format("woff2"); }
@font-face { font-family: "Inter"; font-weight: 400; font-display: swap; src: url("fonts/inter-latin-400-normal.woff2") format("woff2"); }
@font-face { font-family: "Inter"; font-weight: 600; font-display: swap; src: url("fonts/inter-latin-600-normal.woff2") format("woff2"); }
@font-face { font-family: "Inter"; font-weight: 700; font-display: swap; src: url("fonts/inter-latin-700-normal.woff2") format("woff2"); }

:root {
  --bg: #000;
  --surface: #111113;
  --surface-2: #19191c;
  --line: #2a2a2e;
  --red: #d7141a;
  --red-deep: #8f0b0e;
  --text: #f2f2f3;
  --muted: #9b9ba2;
  --fitness: #b9c0c8;
  --kids: #e0a019;
  --frei: #55555c;
  --chrome: linear-gradient(180deg, #ffffff 0%, #d9d9dc 45%, #8d8d93 55%, #e6e6e8 100%);
  --radius: 4px;
  --safe-top: env(safe-area-inset-top, 0px);
  --safe-bottom: env(safe-area-inset-bottom, 0px);
  --tabbar-h: 62px;
}

* { box-sizing: border-box; }
[hidden] { display: none !important; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font: 400 16px/1.55 "Inter", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  min-height: 100vh;
  overscroll-behavior-y: contain;
  -webkit-tap-highlight-color: transparent;
}
body::before {
  content: ""; position: fixed; inset: 0; pointer-events: none; z-index: -1;
  background: radial-gradient(70% 35% at 50% 0%, rgba(215, 20, 26, .18), transparent 70%);
}
img { max-width: 100%; display: block; }
button { font: inherit; }

/* ---------- Kopfzeile: Logo mittig ---------- */
.topbar {
  position: sticky; top: 0; z-index: 20;
  display: grid; grid-template-columns: 1fr auto 1fr; align-items: center;
  padding: calc(6px + var(--safe-top)) 14px 6px;
  background: rgba(0, 0, 0, .86);
  backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--line);
}
.topbar__logo img { width: 52px; height: 52px; border-radius: 50%; }
.topbar__side--right { display: flex; justify-content: flex-end; }

.bell {
  position: relative; width: 40px; height: 40px; border-radius: 50%;
  display: grid; place-items: center; cursor: pointer;
  background: var(--surface-2); border: 1px solid var(--line); color: var(--muted);
}
.bell svg { width: 19px; height: 19px; fill: currentColor; }
.bell__dot { position: absolute; top: 8px; right: 9px; width: 8px; height: 8px; border-radius: 50%; background: var(--line); }
.bell.is-on { color: var(--text); border-color: var(--red-deep); }
.bell.is-on .bell__dot { background: var(--red); box-shadow: 0 0 8px var(--red); }

main { max-width: 680px; margin: 0 auto; padding: 14px 16px calc(var(--tabbar-h) + var(--safe-bottom) + 90px); }
.view { animation: fade .18s ease; }
@keyframes fade { from { opacity: 0; transform: translateY(6px); } }

/* ---------- Tab-Leiste unten ---------- */
.tabbar {
  position: fixed; left: 0; right: 0; bottom: 0; z-index: 30;
  display: grid; grid-template-columns: repeat(7, 1fr);
  padding: 4px 4px var(--safe-bottom);
  background: rgba(8, 8, 9, .94);
  backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px);
  border-top: 1px solid var(--line);
}
.tabbar a {
  position: relative; height: var(--tabbar-h);
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 3px;
  color: var(--muted); text-decoration: none;
  font: 500 10.5px/1 "Oswald", sans-serif; text-transform: uppercase; letter-spacing: .04em;
}
.tabbar svg { width: 22px; height: 22px; fill: currentColor; }
.tabbar a.is-active { color: #fff; }
.tabbar a.is-active svg { fill: var(--red); filter: drop-shadow(0 0 6px rgba(215, 20, 26, .55)); }
.tabbar a.is-active::before {
  content: ""; position: absolute; top: -4px; left: 28%; right: 28%; height: 3px; background: var(--red); transform: skewX(-20deg);
}
.tabbar__badge { position: absolute; top: 8px; left: calc(50% + 8px); width: 8px; height: 8px; border-radius: 50%; background: var(--red); }

/* ---------- Frag uns ---------- */
.ask {
  position: fixed; right: 14px; bottom: calc(var(--tabbar-h) + var(--safe-bottom) + 18px); z-index: 25;
  display: inline-flex; align-items: center; gap: 8px; height: 50px; padding: 0 18px 0 14px;
  border-radius: 25px; background: var(--red); color: #fff; text-decoration: none;
  font: 700 15px/1 "Oswald", sans-serif; text-transform: uppercase; letter-spacing: .07em;
  box-shadow: 0 8px 24px rgba(215, 20, 26, .45), 0 2px 6px rgba(0, 0, 0, .6);
}
.ask svg { width: 22px; height: 22px; fill: currentColor; }
.ask:active { transform: scale(.97); }

/* ---------- Bausteine ---------- */
.cta {
  position: relative; overflow: hidden;
  margin: 4px 0 20px; padding: 20px 18px;
  background: linear-gradient(135deg, #1a0405 0%, var(--surface) 60%);
  border: 1px solid var(--red-deep); border-left: 4px solid var(--red);
  border-radius: var(--radius);
}
.cta h2 { margin: 0 0 6px; font: 700 22px/1.15 "Oswald", sans-serif; text-transform: uppercase; letter-spacing: .03em; }
.cta p { margin: 0 0 14px; color: #c9c9ce; }
.cta ol { margin: 0; padding-left: 20px; color: #c9c9ce; }
.cta ol li { margin: 4px 0; }
.cta--muted { background: var(--surface); border-color: var(--line); border-left-color: var(--muted); }
.ico { width: 18px; height: 18px; fill: currentColor; vertical-align: -3px; }

.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  min-height: 48px; padding: 0 22px; border: 0; border-radius: var(--radius);
  background: var(--red); color: #fff; text-decoration: none; cursor: pointer;
  font: 700 15px/1 "Oswald", sans-serif; text-transform: uppercase; letter-spacing: .08em;
  box-shadow: 0 6px 20px rgba(215, 20, 26, .35);
}
.btn:active { transform: scale(.98); background: #b51015; }
.btn[disabled] { opacity: .6; pointer-events: none; }
.btn--ghost { background: transparent; border: 1px solid var(--line); box-shadow: none; color: var(--text); }

.section-title {
  display: flex; align-items: center; gap: 12px;
  margin: 6px 0 16px; font: 700 26px/1 "Oswald", sans-serif; text-transform: uppercase; letter-spacing: .08em;
}
.section-title span { background: var(--chrome); -webkit-background-clip: text; background-clip: text; color: transparent; }
.section-title::before { content: ""; width: 6px; height: 26px; background: var(--red); transform: skewX(-15deg); }
.section-title::after { content: ""; flex: 1; height: 1px; background: linear-gradient(90deg, var(--line), transparent); }
.sub-title { margin: 26px 0 10px; color: var(--muted); font: 700 14px/1 "Oswald", sans-serif; text-transform: uppercase; letter-spacing: .12em; }

.note { margin: -4px 0 16px; padding: 10px 12px; color: var(--muted); font-size: 13px; border-left: 3px solid var(--line); background: var(--surface); border-radius: var(--radius); }

/* Karten (News/Events) */
.feed { display: grid; gap: 14px; }
.card {
  display: block; width: 100%; text-align: left; cursor: pointer; color: inherit;
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius);
  overflow: hidden; padding: 0;
}
.card:active { transform: scale(.995); }
.card__img { width: 100%; aspect-ratio: 16 / 9; object-fit: cover; background: var(--surface-2); }
.card__body { padding: 14px 16px 16px; }
.card__meta { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; margin-bottom: 6px; color: var(--muted); font-size: 13px; }
.pill {
  font: 700 11px/1 "Oswald", sans-serif; text-transform: uppercase; letter-spacing: .1em;
  padding: 4px 7px; border-radius: 2px; background: var(--surface-2); color: var(--text); border: 1px solid var(--line);
}
.pill--red { background: var(--red); border-color: var(--red); color: #fff; }
.card h3 { margin: 0 0 6px; font: 700 20px/1.2 "Oswald", sans-serif; text-transform: uppercase; letter-spacing: .02em; }
.card p {
  margin: 0; color: #bdbdc3; font-size: 15px;
  display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden;
}
.card--pinned { border-color: var(--red-deep); }

/* Events */
.event { display: grid; grid-template-columns: 64px 1fr; gap: 14px; padding: 14px; align-items: start; }
.event__date { text-align: center; padding: 8px 0; border-radius: var(--radius); background: var(--surface-2); border-top: 3px solid var(--red); }
.event__date b { display: block; font: 700 26px/1 "Oswald", sans-serif; }
.event__date span { display: block; margin-top: 3px; color: var(--muted); font: 700 11px/1 "Oswald", sans-serif; text-transform: uppercase; letter-spacing: .1em; }
.event h3 { margin: 2px 0 4px; }
.event .card__meta { margin: 0; }
.card--past { opacity: .55; }

/* Kurse */
.chips { display: flex; gap: 6px; overflow-x: auto; scrollbar-width: none; margin: 0 -16px; padding: 0 16px; }
.chips::-webkit-scrollbar { display: none; }
.chips--days { margin-bottom: 10px; }
.chips--filter { margin-bottom: 16px; }
.chip {
  flex: none; min-width: 46px; height: 40px; padding: 0 12px; border-radius: var(--radius);
  background: var(--surface); border: 1px solid var(--line); color: var(--muted); cursor: pointer;
  font: 700 14px/1 "Oswald", sans-serif; text-transform: uppercase; letter-spacing: .06em;
}
.chips--days .chip { flex: 1 0 auto; }
.chip.is-active { background: var(--red); border-color: var(--red); color: #fff; }
.chip.is-today:not(.is-active) { border-color: var(--red-deep); color: var(--text); }
.chips--filter .chip { height: 32px; font-size: 12px; display: inline-flex; align-items: center; gap: 6px; }
.chips--filter .chip.is-active { background: var(--surface-2); border-color: var(--text); color: var(--text); }
.dot { display: inline-block; width: 8px; height: 8px; border-radius: 50%; background: var(--red); }
.dot--fitness { background: var(--fitness); } .dot--kids { background: var(--kids); } .dot--frei { background: var(--frei); }

.courses { display: grid; gap: 8px; }
.course {
  display: grid; grid-template-columns: 74px 1fr; gap: 12px; align-items: center;
  padding: 12px 14px; background: var(--surface); border: 1px solid var(--line); border-left: 4px solid var(--red);
  border-radius: var(--radius);
}
.course--fitness { border-left-color: var(--fitness); }
.course--kids { border-left-color: var(--kids); }
.course--frei { border-left-color: var(--frei); background: transparent; }
.course__time { font: 700 17px/1.1 "Oswald", sans-serif; letter-spacing: .02em; }
.course__time small { display: block; color: var(--muted); font: 500 13px/1.2 "Oswald", sans-serif; }
.course__title { font: 700 17px/1.2 "Oswald", sans-serif; text-transform: uppercase; letter-spacing: .02em; }
.course__meta { color: var(--muted); font-size: 13px; margin-top: 2px; }
.course--frei .course__title { color: #c9c9ce; font-weight: 500; }
.course.is-now { box-shadow: 0 0 0 1px var(--red), 0 0 18px rgba(215, 20, 26, .25); }
.live { display: inline-block; margin-left: 8px; padding: 2px 6px; background: var(--red); color: #fff; border-radius: 2px; font: 700 10px/1.4 "Oswald"; letter-spacing: .1em; vertical-align: 2px; }

/* Pläne / Reha */
.doc-group { margin-bottom: 22px; }
.doc {
  display: grid; grid-template-columns: 48px 1fr 20px; gap: 12px; align-items: center; width: 100%;
  padding: 12px 14px; margin-bottom: 8px; text-align: left; cursor: pointer; color: inherit; text-decoration: none;
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius);
}
.doc__icon {
  width: 48px; height: 48px; border-radius: var(--radius); display: grid; place-items: center; overflow: hidden;
  background: var(--surface-2); color: var(--red); font: 700 12px/1 "Oswald", sans-serif; letter-spacing: .08em;
}
.doc__icon img { width: 100%; height: 100%; object-fit: cover; }
.doc__title { font: 700 16px/1.25 "Oswald", sans-serif; text-transform: uppercase; letter-spacing: .02em; }
.doc__desc { color: var(--muted); font-size: 13px; margin-top: 2px; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.doc__arrow { width: 20px; height: 20px; fill: var(--muted); }

/* Info */
.info { display: grid; gap: 12px; }
.info-block { padding: 16px; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); }
.info-block h3 { margin: 0 0 8px; font: 700 18px/1.2 "Oswald", sans-serif; text-transform: uppercase; letter-spacing: .04em; }
.info-block div { color: #d0d0d4; white-space: pre-line; overflow-wrap: anywhere; }
.info-block a:not(.btn) { color: #fff; text-decoration-color: var(--red); text-underline-offset: 3px; }
.info-block .btn { margin-top: 14px; min-height: 42px; font-size: 14px; }

.empty { padding: 32px 16px; text-align: center; color: var(--muted); border: 1px dashed var(--line); border-radius: var(--radius); }
.skeleton { height: 120px; border-radius: var(--radius); background: linear-gradient(90deg, var(--surface) 0%, var(--surface-2) 50%, var(--surface) 100%); background-size: 200% 100%; animation: shimmer 1.2s infinite; }
@keyframes shimmer { to { background-position: -200% 0; } }

/* Detailansicht */
.detail { width: 100%; max-width: 680px; height: 100%; max-height: 100%; margin: 0 auto; padding: 0; border: 0; background: var(--bg); color: var(--text); }
.detail::backdrop { background: rgba(0, 0, 0, .7); }
.detail[open] { animation: slideup .22s ease; }
@keyframes slideup { from { transform: translateY(24px); opacity: 0; } }
.detail__inner { min-height: 100%; padding-bottom: calc(32px + var(--safe-bottom)); }
.detail__close {
  position: fixed; top: calc(12px + var(--safe-top)); right: max(12px, calc(50vw - 328px)); z-index: 2;
  width: 44px; height: 44px; border-radius: 50%; border: 1px solid var(--line);
  background: rgba(0, 0, 0, .75); color: #fff; display: grid; place-items: center; cursor: pointer;
}
.detail__close svg { width: 20px; height: 20px; fill: currentColor; }
.detail img { width: 100%; max-height: 60vh; object-fit: cover; }
.detail img.is-doc { max-height: none; object-fit: contain; }
.detail__body { padding: calc(24px + var(--safe-top)) 18px 0; }
.detail img:not([hidden]) + .detail__body { padding-top: 20px; }
.detail time { color: var(--red); font: 600 13px/1.3 "Inter", sans-serif; text-transform: uppercase; letter-spacing: .08em; }
.detail h2 { margin: 10px 56px 16px 0; font: 700 30px/1.12 "Oswald", sans-serif; text-transform: uppercase; }
.facts { list-style: none; margin: 0 0 18px; padding: 0; display: grid; gap: 6px; }
.facts li { display: flex; gap: 10px; color: #d6d6da; }
.facts b { min-width: 52px; color: var(--muted); font: 700 12px/1.9 "Oswald"; text-transform: uppercase; letter-spacing: .08em; }
.detail__text { color: #d6d6da; font-size: 17px; white-space: pre-line; overflow-wrap: anywhere; }
.detail__text a { color: #fff; text-decoration-color: var(--red); text-underline-offset: 3px; }
.detail .btn { margin-top: 24px; }

.footer { margin-top: 28px; padding-top: 18px; border-top: 1px solid var(--line); color: var(--muted); font-size: 13px; display: flex; flex-wrap: wrap; gap: 8px 16px; justify-content: space-between; }
.footer a { color: var(--muted); }
.footer nav { display: flex; gap: 16px; flex-wrap: wrap; }

.toast {
  position: fixed; left: 50%; bottom: calc(var(--tabbar-h) + var(--safe-bottom) + 80px); transform: translateX(-50%);
  max-width: calc(100% - 32px); padding: 12px 18px; border-radius: var(--radius);
  background: var(--surface-2); border: 1px solid var(--line); border-left: 4px solid var(--red);
  box-shadow: 0 10px 30px rgba(0, 0, 0, .6); z-index: 50; font-size: 15px;
}

/* ---------- Chat ---------- */
body.on-chat .ask { display: none; }
.wa-btn {
  display: flex; align-items: center; gap: 14px; margin: 4px 0 22px; padding: 14px 16px;
  border-radius: var(--radius); background: linear-gradient(135deg, #0f3d22, #0b2416); border: 1px solid #1f7a45;
  color: #fff; text-decoration: none;
}
.wa-btn svg { width: 34px; height: 34px; flex: none; fill: #25d366; }
.wa-btn b { display: block; font: 700 19px/1.1 "Oswald", sans-serif; text-transform: uppercase; letter-spacing: .05em; }
.wa-btn small { color: #a9d8bb; font-size: 13px; }
.wa-btn:active { transform: scale(.99); }

.chat-join { padding: 18px; background: var(--surface); border: 1px solid var(--line); border-left: 4px solid var(--red); border-radius: var(--radius); }
.chat-join h2 { margin: 0 0 6px; font: 700 22px/1.15 "Oswald", sans-serif; text-transform: uppercase; }
.chat-join p { margin: 0 0 12px; color: #c9c9ce; font-size: 14px; }
.chat-join label { display: block; margin: 12px 0 6px; font-weight: 600; font-size: 14px; }
.chat-join label small { color: var(--muted); font-weight: 400; }
.chat-join input[type=text] { width: 100%; height: 48px; padding: 0 12px; border-radius: var(--radius); border: 1px solid var(--line); background: var(--surface-2); color: var(--text); font: inherit; }
.chat-join input:focus { outline: 2px solid var(--red); outline-offset: -1px; }
.chat-join .chk { display: flex; gap: 10px; align-items: center; font-weight: 400; margin: 14px 0 16px; }
.chat-join .chk input { width: 20px; height: 20px; accent-color: var(--red); }
.chat-join .btn { width: 100%; }
.chat-join__err { color: #ff6b70; margin: 10px 0 0 !important; min-height: 1em; }

.chat-me { color: var(--muted); font-size: 13px; margin: -6px 0 12px; }
.chat-me b { color: var(--text); }
.chat-me button { background: none; border: 0; padding: 0; color: var(--muted); text-decoration: underline; cursor: pointer; font-size: 13px; }
.chat-list { display: flex; flex-direction: column; gap: 6px; }
.chat-day { align-self: center; margin: 12px 0 4px; padding: 3px 10px; border-radius: 10px; background: var(--surface-2); color: var(--muted); font: 600 11px/1.4 "Inter"; text-transform: uppercase; letter-spacing: .06em; }
.msg { max-width: 82%; align-self: flex-start; padding: 8px 12px 6px; border-radius: 4px 14px 14px 14px; background: var(--surface-2); border: 1px solid var(--line); }
.msg__name { font: 700 13px/1.3 "Oswald", sans-serif; letter-spacing: .03em; color: #e6e6e8; text-transform: uppercase; }
.msg__body { white-space: pre-wrap; overflow-wrap: anywhere; font-size: 15px; line-height: 1.4; }
.msg__body a { color: #fff; text-decoration-color: var(--red); }
.msg__time { display: block; text-align: right; color: var(--muted); font-size: 11px; margin-top: 2px; }
.msg--mine { align-self: flex-end; border-radius: 14px 4px 14px 14px; background: #3a0809; border-color: var(--red-deep); }
.msg--mine .msg__name { display: none; }
.msg--mine .msg__time { color: #d79a9c; }
.msg--staff { border-color: var(--red); box-shadow: inset 3px 0 0 var(--red); }
.msg--staff .msg__name { color: var(--red); }
.msg--staff .msg__name::after { content: " · Team"; color: var(--muted); }
.msg.is-pending { opacity: .6; }

body.on-chat main { padding-bottom: calc(var(--tabbar-h) + var(--safe-bottom) + 84px); }
.composer {
  position: fixed; left: 0; right: 0; bottom: calc(var(--tabbar-h) + var(--safe-bottom) + 4px); z-index: 26;
  display: flex; gap: 8px; align-items: flex-end; max-width: 680px; margin: 0 auto; padding: 8px 12px;
  background: rgba(0, 0, 0, .92); backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px); border-top: 1px solid var(--line);
}
.composer textarea {
  flex: 1; min-height: 44px; max-height: 130px; padding: 11px 14px; resize: none; border-radius: 22px;
  border: 1px solid var(--line); background: var(--surface-2); color: var(--text); font: 16px/1.35 "Inter", sans-serif;
}
.composer textarea:focus { outline: none; border-color: var(--red-deep); }
.composer button { width: 44px; height: 44px; flex: none; border-radius: 50%; border: 0; background: var(--red); display: grid; place-items: center; cursor: pointer; }
.composer button svg { width: 20px; height: 20px; fill: #fff; }
.composer button[disabled] { opacity: .5; }

.chat-privacy { font-size: 12.5px !important; color: var(--muted) !important; margin: 0 0 14px !important; }
.chat-privacy a, .privacy a { color: #fff; text-decoration-color: var(--red); text-underline-offset: 3px; }
.privacy { margin-top: 12px; border-left: 3px solid var(--line); scroll-margin-top: 84px; }
.privacy dl { margin: 0; }
.privacy dt { margin-top: 12px; font: 700 14px/1.3 "Oswald", sans-serif; text-transform: uppercase; letter-spacing: .05em; color: var(--text); }
.privacy dt:first-child { margin-top: 0; }
.privacy dd { margin: 4px 0 0; color: #c9c9ce; font-size: 14px; line-height: 1.5; }
.privacy__more { margin: 14px 0 0; font-size: 14px; color: #c9c9ce; }

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