/* Tagtraum Jobs. Mobil zuerst, Systemschrift, keine externen Ressourcen. */
.tj-app, .tj-app * { box-sizing: border-box; }
.tj-body { margin: 0; background: #fff; color-scheme: light; }
.tj-app {
  --rot: #9F1D19;
  --rot-dunkel: #7F1713; /* Standardwerte, PHP setzt sie passend zur Hauptfarbe */
  --rot-hell: #F6EBEA;
  --papier: #fff;
  --weiss: #fff;
  --weiss-90: rgba(255, 255, 255, .9);
  --weiss-14: rgba(255, 255, 255, .14);
  --weiss-30: rgba(255, 255, 255, .3);
  --tinte: #1A1A1A;
  --grau: #595959;
  --linie: #E2E2E2;
  min-height: 100vh;
  min-height: 100dvh;
  color-scheme: light;
  display: flex;
  flex-direction: column;
  background: var(--papier);
  color: var(--tinte);
  font-family: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  font-size: 1.0625rem;
  line-height: 1.5;
  -webkit-text-size-adjust: 100%;
}
.tj-app button, .tj-app input { font-family: inherit; }
.tj-app :focus-visible { outline: 3px solid var(--tinte); outline-offset: 3px; box-shadow: 0 0 0 6px var(--weiss); }
.tj-app [tabindex="-1"]:focus { outline: none; box-shadow: none; }

.tj-header { padding: 14px 20px; display: flex; align-items: center; max-width: 720px; width: 100%; margin: 0 auto; }
.tj-header { gap: 14px; }
.tj-brand { display: flex; flex-direction: column; min-width: 0; }
.tj-brand-name { font-size: 1.35rem; font-weight: 800; letter-spacing: -0.01em; line-height: 1.1; color: var(--tinte); }
.tj-brand-sub { margin: 2px 0 0; font-size: .95rem; font-weight: 600; color: var(--grau); line-height: 1.2; }
.tj-brand-sub[hidden] { display: none; }
.tj-app.is-start .tj-brand-sub { color: var(--weiss-90); }
.tj-header-title { margin: 2px 0 0; font-size: .95rem; font-weight: 700; line-height: 1.2; color: var(--rot); }
.tj-header-title[hidden] { display: none; }
.tj-logo { flex: none; width: 44px; height: 44px; object-fit: contain; display: block; }

.tj-main { flex: 1; width: 100%; max-width: 720px; margin: 0 auto; padding: 8px 20px 40px; }
.tj-app.is-start .tj-h1 { margin-top: 18px; }
.tj-h1 { font-size: clamp(1.7rem, 7.5vw, 3rem); line-height: 1.08; letter-spacing: -0.02em; font-weight: 800; margin: 0 0 6px; color: var(--rot); text-wrap: balance; overflow-wrap: anywhere; hyphens: auto; }
.tj-h2 { font-size: clamp(1.5rem, 5.5vw, 2.1rem); line-height: 1.15; letter-spacing: -0.015em; font-weight: 800; margin: 12px 0 18px; text-wrap: balance; overflow-wrap: anywhere; hyphens: auto; }
.tj-ort { display: inline-block; margin: 8px 0 12px; padding: 4px 12px; font-weight: 700; font-size: .85rem; line-height: 1.3; background: var(--tinte); color: var(--weiss); border-radius: 12px; }
.tj-role { margin: 0 0 18px; font-size: 1.3rem; line-height: 1.2; font-weight: 800; color: var(--tinte); }
.tj-facts { margin: -8px 0 16px; font-weight: 700; color: var(--grau); }
.tj-sub, .tj-lead { font-size: 1.1rem; color: var(--grau); margin: 0 0 22px; }
.tj-lead { color: var(--tinte); font-size: 1.25rem; }
.tj-hint { color: var(--grau); margin: -8px 0 16px; }

/* Start */
.tj-photo-wrap { position: relative; margin: 0 -20px 18px; background: var(--rot); padding: 20px; }
.tj-photo { display: block; width: 100%; height: auto; aspect-ratio: 1352 / 943; object-fit: cover; border-radius: 16px; background: var(--rot-dunkel); }
.tj-chips { list-style: none; margin: 0 0 22px; padding: 0; display: grid; grid-template-columns: minmax(0, 1fr); gap: 10px; }
@media (min-width: 480px) { .tj-chips { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
.tj-chip { display: flex; align-items: center; justify-content: flex-start; gap: 8px; width: 100%; height: 100%; min-height: 56px; padding: 8px 16px; border-radius: 16px; background: var(--weiss); color: var(--tinte); border: 2px solid var(--tinte); font: inherit; font-weight: 700; line-height: 1.2; cursor: pointer; text-align: left; transition: transform .12s ease, background-color .12s ease; }
.tj-chip:hover { background: var(--rot-hell); }
.tj-chip:active { transform: translateY(1px); }
.tj-chip span:last-child { overflow-wrap: anywhere; }
.tj-chip-arrow { color: var(--rot); font-weight: 800; }

.tj-actions { display: grid; gap: 12px; margin: 8px 0 20px; }
.tj-phone { color: var(--grau); margin: 0; }
.tj-phone a, .tj-footer a, .tj-consent a { color: var(--rot); font-weight: 600; }

.tj-btn { appearance: none; cursor: pointer; min-height: 56px; padding: 12px 26px; border-radius: 14px; border: 2px solid var(--rot); font-weight: 800; font-size: 1.1rem; transition: transform .12s ease, background-color .12s ease; }
.tj-btn-primary { background: var(--rot); color: var(--weiss); }
.tj-btn-primary:hover { background: var(--rot-dunkel); }
.tj-btn-ghost { background: transparent; color: var(--rot); }
.tj-btn-ghost:hover { background: var(--rot-hell); }
.tj-btn { display: inline-flex; align-items: center; justify-content: center; text-align: center; text-decoration: none; }
/* Motiv B: Zahlen statt Teamfoto, die vier Punkte als große Felder */
.tj-v-b .tj-photo-wrap { display: none; }
.tj-v-b .tj-chips { grid-template-columns: minmax(0, 1fr); }
@media (min-width: 480px) { .tj-v-b .tj-chips { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
.tj-v-b .tj-chip { min-height: 72px; font-size: 1.2rem; }
.tj-v-b .tj-chip-arrow { font-size: 1.4rem; }
.tj-v-c .tj-h1 { text-transform: none; }
.tj-cta-top { margin: 0 0 20px; }
.tj-link { appearance: none; background: none; border: 0; min-height: 48px; padding: 0 8px; color: var(--rot); font-weight: 700; font-size: 1.05rem; text-decoration: underline; cursor: pointer; }
.tj-btn-wide { grid-column: 1 / -1; min-height: 62px; font-size: 1.2rem; }
.tj-btn:active { transform: translateY(1px); }
.tj-btn[disabled] { opacity: .6; cursor: progress; }

.tj-back { appearance: none; background: none; border: 0; padding: 0 12px 0 0; min-height: 48px; color: var(--grau); font-weight: 600; font-size: 1rem; cursor: pointer; display: inline-flex; align-items: center; gap: 6px; }
.tj-back:hover { color: var(--rot); }

/* Karten */
.tj-kicker { margin: 0; color: var(--grau); font-size: .95rem; min-height: 1.4em; }
.tj-card { background: var(--weiss); border: 2px solid var(--tinte); border-radius: 22px; padding: 22px 20px; box-shadow: 6px 6px 0 var(--rot); margin: 8px 6px 28px 0; }
.tj-card .tj-h2 { margin-top: 0; color: var(--rot); }
.tj-list { list-style: none; margin: 0; padding: 0; }
.tj-list li { position: relative; padding: 10px 0 10px 30px; border-top: 1px solid var(--linie); }
.tj-list li:first-child { border-top: 0; }
.tj-list li::before { content: ""; position: absolute; left: 4px; top: 1.05em; width: 12px; height: 12px; border-radius: 50%; background: var(--rot); }

/* Dauer-Knopf auf den Infoseiten: bleibt am unteren Rand erreichbar */
.tj-cards .tj-actions-single { position: sticky; bottom: 0; margin: 0 -20px; padding: 12px 20px calc(12px + env(safe-area-inset-bottom)); background: linear-gradient(to bottom, rgba(255,255,255,0), var(--papier) 28%); }

/* Startseite: roter Hintergrund wie die Anzeigen */
.tj-app { transition: background-color .2s ease; }
.tj-app.is-start { background: var(--rot); color: var(--weiss); }
.tj-app.is-start .tj-logo { background: var(--weiss); border-radius: 50%; padding: 6px; }
.tj-app.is-start .tj-brand-name, .tj-app.is-start .tj-h1, .tj-app.is-start .tj-role { color: var(--weiss); }
.tj-app.is-start .tj-facts, .tj-app.is-start .tj-sub, .tj-app.is-start .tj-phone { color: var(--weiss-90); }
.tj-app.is-start .tj-phone a, .tj-app.is-start .tj-footer a { color: var(--weiss); }
.tj-app.is-start .tj-photo-wrap { background: transparent; padding: 0; margin: 0 0 18px; }
.tj-app.is-start .tj-photo { border: 8px solid var(--weiss); border-radius: 26px; background: var(--weiss); }
.tj-app.is-start .tj-btn-primary { background: var(--weiss); color: var(--rot); border-color: var(--weiss); }
.tj-app.is-start .tj-btn-primary:hover { background: var(--rot-hell); }
.tj-app.is-start .tj-btn-ghost { color: var(--weiss); border-color: var(--weiss); }
.tj-app.is-start .tj-btn-ghost:hover { background: var(--weiss-14); }
.tj-app.is-start .tj-footer { border-top-color: var(--weiss-30); }
.tj-app.is-start :focus-visible { outline-color: var(--weiss); box-shadow: 0 0 0 6px var(--rot); }

/* Fortschritt */
.tj-progress { margin: 4px 0 8px; }
.tj-progress-label { margin: 0 0 6px; font-weight: 700; color: var(--grau); font-size: .95rem; }
.tj-bar { height: 10px; background: var(--linie); border-radius: 999px; overflow: hidden; }
.tj-bar-fill { display: block; height: 100%; background: var(--rot); border-radius: 999px; transform-origin: left; transition: transform .3s ease; }

/* Antworten */
.tj-options { display: grid; gap: 12px; margin-bottom: 20px; }
.tj-option { appearance: none; cursor: pointer; display: flex; align-items: center; gap: 14px; width: 100%; min-height: 60px; padding: 12px 18px; text-align: left; background: var(--weiss); color: var(--tinte); border: 2px solid var(--tinte); border-radius: 16px; font-weight: 700; font-size: 1.1rem; transition: background-color .12s ease, transform .12s ease; }
.tj-option:hover { background: var(--rot-hell); }
.tj-option:active { transform: translateY(1px); }
.tj-option-mark { flex: none; width: 24px; height: 24px; border: 2px solid var(--tinte); border-radius: 50%; background: var(--weiss); }
.tj-option[aria-pressed] .tj-option-mark { border-radius: 7px; }
.tj-option.is-on { background: var(--rot); color: var(--weiss); border-color: var(--rot); }
.tj-option.is-on .tj-option-mark { background: var(--weiss); border-color: var(--weiss); box-shadow: inset 0 0 0 5px var(--rot); }

/* Formular */
.tj-form { display: grid; gap: 16px; }
.tj-field label { display: block; font-weight: 700; margin-bottom: 6px; }
.tj-input { width: 100%; min-height: 54px; padding: 10px 14px; background: var(--weiss); color: var(--tinte); border: 2px solid var(--tinte); border-radius: 12px; font-size: 1.1rem; }
.tj-select { appearance: auto; }
.tj-textarea { min-height: 120px; resize: vertical; line-height: 1.4; }
.tj-count { margin: 4px 0 0; color: var(--grau); font-size: .9rem; text-align: right; }
.tj-optional { font-weight: 400; color: var(--grau); }
.tj-input[aria-invalid="true"] { border-color: var(--rot); background: var(--rot-hell); }
.tj-error { margin: 6px 0 0; color: var(--rot-dunkel); font-weight: 600; min-height: 0; }
.tj-error:empty { display: none; }
.tj-form-error { margin: 0; padding: 12px 14px; background: var(--rot-hell); border: 2px solid var(--rot); border-radius: 8px; font-weight: 600; }
.tj-form-error:empty { display: none; }
.tj-consent-row { display: flex; gap: 12px; align-items: flex-start; }
.tj-consent-row input { flex: none; width: 28px; height: 28px; margin: 2px 0 0; accent-color: var(--rot); }
.tj-consent-row label { font-weight: 400; margin: 0; padding-top: 2px; }
.tj-hp { position: absolute; left: -10000px; top: auto; width: 1px; height: 1px; overflow: hidden; }

/* Fertig */
.tj-steps { text-align: left; margin: 0 0 22px; padding: 0; list-style: none; counter-reset: s; }
.tj-steps li { counter-increment: s; position: relative; padding: 12px 0 12px 48px; border-top: 1px solid var(--linie); }
.tj-steps li:first-child { border-top: 0; }
.tj-steps li::before { content: counter(s); position: absolute; left: 0; top: 10px; width: 32px; height: 32px; border-radius: 50%; background: var(--rot); color: var(--weiss); font-weight: 800; display: flex; align-items: center; justify-content: center; }
.tj-share { margin-top: 28px; padding-top: 20px; border-top: 1px solid var(--linie); display: grid; gap: 12px; }
.tj-share-text { margin: 0; font-weight: 700; }
.tj-done { text-align: center; padding-top: 24px; }
.tj-done-mark { width: 88px; height: 88px; margin: 0 auto 8px; border-radius: 50%; background: var(--rot); color: var(--weiss); font-size: 3rem; line-height: 88px; font-weight: 800; }
.tj-confetti { position: fixed; inset: 0; width: 100vw; height: 100vh; pointer-events: none; z-index: 9999; }

.tj-footer { display: flex; gap: 20px; justify-content: center; padding: 22px 20px 30px; border-top: 1px solid var(--linie); font-size: .95rem; }
.tj-footer a { display: inline-flex; align-items: center; min-height: 48px; color: var(--grau); }
.tj-noscript { padding: 14px; background: var(--rot-hell); border: 2px solid var(--rot); border-radius: 8px; }

/* Shortcode im Theme: kein Vollbild erzwingen */
.tj-embed .tj-app { min-height: 0; }

@media (max-width: 400px) {
  .tj-actions-start { grid-template-columns: 1fr; }
}

@media (min-width: 720px) {
  .tj-header { padding-top: 22px; }
  .tj-main { padding-bottom: 60px; }
  .tj-photo-wrap { margin: 0 0 22px; border-radius: 28px; padding: 28px; overflow: hidden; }
  .tj-app.is-start .tj-photo-wrap { padding: 0; border-radius: 0; overflow: visible; }
  .tj-actions { grid-template-columns: 1fr 1fr; }
  .tj-actions-single { grid-template-columns: 1fr; }
  .tj-actions-start { grid-template-columns: 1fr 1fr; }
  .tj-cards .tj-actions-single { margin: 0; padding-left: 0; padding-right: 0; }
  .tj-options { grid-template-columns: 1fr 1fr; }
  .tj-card { padding: 30px 32px; }
}

@media (prefers-reduced-motion: reduce) {
  .tj-app *, .tj-app *::before, .tj-app *::after { transition: none !important; animation: none !important; }
  .tj-confetti { display: none; }
}
.tj-sr { position: absolute; width: 1px; height: 1px; margin: -1px; padding: 0; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0; }
