/* =========================================================================
   Karriereportal – Design nach Gestaltungsvorlage Landtechnik Gruber
   ========================================================================= */

/* Hausschrift Muli – lokal vom eigenen Server, keine Google Fonts */
@font-face { font-family: "Muli"; font-style: normal; font-weight: 400; font-display: swap; src: url("fonts/muli-400.woff2") format("woff2"), url("fonts/muli-400.woff") format("woff"); }
@font-face { font-family: "Muli"; font-style: normal; font-weight: 700; font-display: swap; src: url("fonts/muli-700.woff2") format("woff2"), url("fonts/muli-700.woff") format("woff"); }
@font-face { font-family: "Muli"; font-style: normal; font-weight: 800 900; font-display: swap; src: url("fonts/muli-800.woff2") format("woff2"), url("fonts/muli-800.woff") format("woff"); }

:root {
  --brand: #b4c71a;
  --brand-dark: #8a9a10;
  --brand-soft: rgba(180, 199, 26, .14);
  --on-brand: #1d2100;
  --red: #e2000f;
  --ink: #222222;
  --muted: #5f6368;
  --line: #e3e5e8;
  --bg: #f4f5f2;
  --card: #ffffff;
  --focus: #3f4d00;
  --ok: #4b7a0f;  --ok-bg: #eef5dc;
  --err: #c4000d; --err-bg: #fdecec;
  --info-bg: #f1f6d6;
  --hero: linear-gradient(120deg, #3a4504 0%, #556306 55%, #687a0a 100%);
  --shadow: 0 2px 10px rgba(0, 0, 0, .06);
  --shadow-lg: 0 18px 50px rgba(40, 48, 0, .14);
  --radius: 12px;
  --ease: cubic-bezier(.2, .8, .2, 1);
  --font: "Muli", "Mulish", Arial, Verdana, sans-serif;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0; font-family: var(--font); font-size: 17px; line-height: 1.55;
  color: var(--ink); background: var(--bg);
  -webkit-font-smoothing: antialiased;
  display: flex; flex-direction: column; min-height: 100vh;
}
main { flex: 1; }
img, svg { max-width: 100%; }
a { color: var(--red); }
a:hover { text-decoration-thickness: 2px; }

h1, h2 {
  color: var(--red); text-transform: uppercase; font-weight: 900;
  line-height: 1.15; letter-spacing: .01em; hyphens: auto; -webkit-hyphens: auto;
  margin: 0 0 .5em;
}
h1 { font-size: clamp(1.6rem, 4.2vw, 2.4rem); }
h2 { font-size: clamp(1.25rem, 3vw, 1.6rem); }
h3 { font-weight: 800; font-size: 1.1rem; margin: 0 0 .5em; }
p { margin: 0 0 1em; }

:focus-visible { outline: 3px solid var(--focus); outline-offset: 2px; }

.visually-hidden {
  position: absolute !important; width: 1px; height: 1px; padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0;
}
.skip-link { position: absolute; left: 12px; top: -60px; background: var(--card); padding: 8px 14px; z-index: 100; font-weight: 800; }
.skip-link:focus { top: 12px; }

.wrap { max-width: 800px; margin: 0 auto; padding: 0 16px; }
.wrap-wide { max-width: 1200px; margin: 0 auto; padding: 0 16px; }
.muted { color: var(--muted); }
.small { font-size: .88rem; }
.nowrap { white-space: nowrap; }
.mt-0 { margin-top: 0; }
.mb-0 { margin-bottom: 0; }

/* ---------- Kopfzeile / Kopfband / Fußzeile (öffentlich) ---------- */

.site-header { background: #fff; border-bottom: 4px solid var(--brand); }
.site-header .wrap-wide { display: flex; align-items: center; justify-content: space-between; gap: 16px; min-height: 84px; }
.site-header .logo img { height: 54px; width: auto; display: block; }
.header-links { display: flex; gap: 22px; align-items: center; font-weight: 700; font-size: .95rem; }
.header-links a { color: var(--ink); text-decoration: none; }
.header-links a:hover { color: var(--red); }

.hero { background: var(--hero); color: #fff; padding: 46px 0 54px; }
.hero h1 { color: #fff; margin-bottom: .3em; }
.hero p { font-weight: 700; margin: 0; opacity: .95; }

.site-footer { background: #fff; border-top: 1px solid var(--line); margin-top: 56px; padding: 36px 0 24px; font-size: .93rem; }
.footer-cols { display: grid; grid-template-columns: 1fr 1fr; gap: 28px; }
.footer-cols h2 { font-size: .95rem; margin-bottom: .6em; }
.footer-cols p { margin: 0 0 .3em; }
.footer-bottom { border-top: 1px solid var(--line); margin-top: 26px; padding-top: 16px; color: var(--muted); display: flex; flex-wrap: wrap; gap: 6px 14px; }
.footer-bottom a { color: var(--muted); }

/* ---------- Karten, Hinweise, Meldungen ---------- */

.card { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow); padding: 20px; margin: 0 0 20px; }
.card > :last-child { margin-bottom: 0; }
.card-title { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-bottom: 14px; }
.card-title h2, .card-title h3 { margin: 0; }
.card h2 { font-size: 1.05rem; }

.intro { background: var(--card); border-radius: var(--radius); border-left: 6px solid var(--brand); box-shadow: var(--shadow); padding: 20px 22px; margin: 0 0 22px; }
.note { background: var(--brand-soft); border-left: 4px solid var(--brand); border-radius: 0 8px 8px 0; padding: 12px 16px; margin: 0 0 16px; }

.alert { border-radius: 10px; padding: 13px 16px; margin: 0 0 18px; font-weight: 700; display: flex; gap: 10px; align-items: flex-start; }
.alert-success { background: var(--ok-bg); color: var(--ok); }
.alert-error { background: var(--err-bg); color: var(--err); }
.alert-info { background: var(--info-bg); color: #3f4d00; }

/* ---------- Knöpfe ---------- */

.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  min-height: 46px; padding: 11px 22px; border: 2px solid var(--brand); border-radius: 0;
  background: var(--brand); color: var(--on-brand);
  font: inherit; font-weight: 800; font-size: .95rem; text-transform: uppercase; letter-spacing: .04em;
  text-decoration: none; cursor: pointer; line-height: 1.2;
  transition: background .15s, border-color .15s, transform .12s, box-shadow .2s;
}
.btn:hover { background: var(--brand-dark); border-color: var(--brand-dark); color: var(--on-brand); }
.btn:active { transform: translateY(1px); }
.btn[disabled], .btn.is-loading { opacity: .65; cursor: progress; }
.btn-lg { min-height: 58px; padding: 15px 30px; font-size: 1.05rem; }
.btn-block { display: flex; width: 100%; }
.btn-sm { min-height: 36px; padding: 6px 14px; font-size: .8rem; }
.btn-ghost { background: #fff; color: var(--ink); }
.btn-ghost:hover { background: var(--brand-soft); color: var(--ink); border-color: var(--brand); }
.btn-danger { background: var(--err); border-color: var(--err); color: #fff; }
.btn-danger:hover { background: #9e000a; border-color: #9e000a; color: #fff; }
.btn-text { background: none; border: 0; padding: 8px 4px; font: inherit; font-weight: 800; color: var(--muted); cursor: pointer; text-decoration: none; display: inline-flex; align-items: center; gap: 6px; }
.btn-text:hover { color: var(--ink); }
.link-btn { background: none; border: 0; padding: 0; font: inherit; color: var(--red); text-decoration: underline; cursor: pointer; }
.btn .arrow { transition: transform .2s var(--ease); }
.btn:hover .arrow { transform: translateX(4px); }

/* ---------- Formulare ---------- */

label, .label { display: block; font-weight: 700; font-size: .93rem; margin: 0 0 6px; }
.req { color: var(--err); }
.opt-note { font-weight: 400; color: var(--muted); }
input[type=text], input[type=email], input[type=tel], input[type=password], input[type=number], input[type=url], input[type=search], select, textarea {
  width: 100%; min-height: 46px; padding: 10px 13px; font: inherit; font-size: 1rem; color: var(--ink);
  background: #fff; border: 1.5px solid #cfd3d8; border-radius: 6px;
  transition: border-color .15s, box-shadow .15s;
}
textarea { min-height: 120px; resize: vertical; line-height: 1.5; }
input:hover, select:hover, textarea:hover { border-color: #aab0b6; }
input:focus, select:focus, textarea:focus { outline: none; border-color: var(--focus); box-shadow: 0 0 0 3px rgba(63, 77, 0, .2); }
[aria-invalid=true] { border-color: var(--err) !important; background: #fffafa; }
.field { margin: 0 0 18px; }
.field-row { display: grid; grid-template-columns: 1fr 1fr; gap: 0 16px; }
.field-error { color: var(--err); font-size: .88rem; font-weight: 700; margin: 6px 0 0; display: flex; gap: 6px; align-items: center; }
.field-error::before { content: "!"; display: inline-grid; place-items: center; width: 18px; height: 18px; border-radius: 50%; background: var(--err); color: #fff; font-size: .72rem; flex: none; }
.hint { color: var(--muted); font-size: .88rem; margin: 6px 0 0; }

fieldset { border: 0; margin: 0; padding: 0; min-width: 0; }
fieldset.card { padding: 24px; }
fieldset.card > legend { float: left; width: 100%; padding: 0; margin: 0 0 16px; color: var(--red); font-weight: 900; text-transform: uppercase; font-size: 1.15rem; display: flex; align-items: center; gap: 12px; }
fieldset.card > legend + * { clear: both; }
.step { display: inline-grid; place-items: center; flex: none; width: 34px; height: 34px; border-radius: 50%; background: var(--brand); color: var(--on-brand); font-weight: 900; font-size: 1rem; }

.check-line { display: flex; gap: 12px; align-items: flex-start; font-weight: 400; font-size: .95rem; cursor: pointer; }
.check-line input { width: 22px; height: 22px; margin: 1px 0 0; flex: none; accent-color: var(--brand-dark); }

.segmented { display: inline-flex; border: 2px solid var(--brand); }
.segmented label { margin: 0; position: relative; }
.segmented input { position: absolute; opacity: 0; }
.segmented span { display: block; padding: 9px 18px; font-weight: 800; font-size: .9rem; text-transform: uppercase; cursor: pointer; }
.segmented input:checked + span { background: var(--brand); color: var(--on-brand); }
.segmented input:focus-visible + span { outline: 3px solid var(--focus); outline-offset: -3px; }

.switch { display: flex; align-items: center; gap: 12px; font-weight: 700; cursor: pointer; margin: 0 0 14px; }
.switch input { position: absolute; opacity: 0; }
.switch .track { width: 46px; height: 26px; border-radius: 99px; background: #cfd3d8; position: relative; flex: none; transition: background .2s; }
.switch .track::after { content: ""; position: absolute; top: 3px; left: 3px; width: 20px; height: 20px; border-radius: 50%; background: #fff; box-shadow: 0 1px 3px rgba(0,0,0,.25); transition: transform .2s var(--ease); }
.switch input:checked + .track { background: var(--brand-dark); }
.switch input:checked + .track::after { transform: translateX(20px); }
.switch input:focus-visible + .track { outline: 3px solid var(--focus); outline-offset: 2px; }

dl.summary { display: grid; grid-template-columns: minmax(140px, 38%) 1fr; gap: 0; margin: 0; }
dl.summary dt, dl.summary dd { padding: 10px 0; border-bottom: 1px solid var(--line); margin: 0; }
dl.summary dt { color: var(--muted); font-size: .92rem; padding-right: 16px; }
dl.summary dd { font-weight: 700; overflow-wrap: anywhere; }
dl.summary > :nth-last-child(-n+2) { border-bottom: 0; }

/* ---------- Plaketten ---------- */

.badge { display: inline-flex; align-items: center; gap: 6px; padding: 3px 10px; border-radius: 99px; font-size: .74rem; font-weight: 800; text-transform: uppercase; letter-spacing: .04em; white-space: nowrap; line-height: 1.5; }
.badge::before { content: ""; width: 7px; height: 7px; border-radius: 50%; background: currentColor; }
.badge-green { background: var(--ok-bg); color: var(--ok); }
.badge-red { background: var(--err-bg); color: var(--err); }
.badge-orange { background: #fff0dc; color: #9a4a00; }
.badge-gray { background: #eceef0; color: #4a4f55; }
.badge-brand { background: var(--brand-soft); color: #4a5600; }

/* ---------- Erfolgsseite ---------- */

.success-card { text-align: center; padding: 48px 28px; }
.success-icon { width: 96px; height: 96px; border-radius: 50%; background: var(--brand); color: var(--on-brand); display: grid; place-items: center; margin: 0 auto 22px; font-size: 3rem; font-weight: 900; animation: pop .5s var(--ease) both; box-shadow: 0 0 0 12px var(--brand-soft); }
.success-card p { max-width: 520px; margin-left: auto; margin-right: auto; }
@keyframes pop { from { transform: scale(.4); opacity: 0; } to { transform: none; opacity: 1; } }

/* =========================================================================
   FUNNEL (Bewerber)
   ========================================================================= */

.funnel-page { background: radial-gradient(1200px 500px at 50% -120px, rgba(180,199,26,.18), transparent 70%), var(--bg); }
.funnel-page .site-header .wrap-wide { min-height: 72px; }
.funnel-page .site-header .logo img { height: 46px; }

.funnel { max-width: 720px; margin: 0 auto; padding: 28px 16px 40px; }

.job-card { background: var(--card); border-radius: 18px; box-shadow: var(--shadow-lg); overflow: hidden; border: 1px solid var(--line); }
.job-hero { background: var(--hero); color: #fff; padding: 38px 34px 34px; position: relative; overflow: hidden; }
.job-hero::after { content: ""; position: absolute; right: -80px; top: -80px; width: 260px; height: 260px; border-radius: 50%; border: 40px solid rgba(180,199,26,.18); }
.job-eyebrow { display: inline-flex; align-items: center; gap: 8px; font-size: .8rem; font-weight: 800; text-transform: uppercase; letter-spacing: .1em; color: #e6f08a; margin: 0 0 12px; }
.job-eyebrow::before { content: ""; width: 8px; height: 8px; border-radius: 50%; background: var(--brand); box-shadow: 0 0 0 4px rgba(180,199,26,.3); animation: pulse 2.2s infinite; }
@keyframes pulse { 50% { box-shadow: 0 0 0 8px rgba(180,199,26,0); } }
.job-hero h1 { color: #fff; font-size: clamp(1.45rem, 4.6vw, 2.3rem); margin: 0 0 16px; position: relative; z-index: 1; hyphens: manual; -webkit-hyphens: manual; overflow-wrap: break-word; }
.chips { display: flex; flex-wrap: wrap; gap: 8px; margin: 0; padding: 0; list-style: none; position: relative; z-index: 1; }
.chips li { background: rgba(255,255,255,.14); border: 1px solid rgba(255,255,255,.22); padding: 5px 12px; border-radius: 99px; font-size: .86rem; font-weight: 700; }
.job-body { padding: 30px 34px 34px; }
.job-intro { font-size: 1.06rem; margin-bottom: 22px; }
.benefits { list-style: none; padding: 0; margin: 0 0 28px; display: grid; gap: 12px; }
.benefits li { display: flex; gap: 12px; align-items: flex-start; font-weight: 700; }
.benefits li::before { content: "✓"; flex: none; display: grid; place-items: center; width: 26px; height: 26px; border-radius: 50%; background: var(--brand-soft); color: var(--brand-dark); font-weight: 900; font-size: .9rem; }
.job-duration { text-align: center; color: var(--muted); font-size: .9rem; margin: 14px 0 0; }

/* Fortschritt */
.funnel-progress { display: none; align-items: center; gap: 14px; margin: 0 0 18px; }
.progress-track { flex: 1; height: 8px; border-radius: 99px; background: #e2e6d6; overflow: hidden; }
.progress-bar { height: 100%; width: 0; border-radius: inherit; background: linear-gradient(90deg, var(--brand-dark), var(--brand)); transition: width .55s var(--ease); }
.progress-label { font-size: .82rem; font-weight: 800; color: var(--muted); white-space: nowrap; min-width: 92px; text-align: right; }

/* Schritte */
.fstep { background: var(--card); border: 1px solid var(--line); border-radius: 18px; box-shadow: var(--shadow-lg); padding: 34px; margin: 0 0 22px; }
.fstep > legend { float: left; width: 100%; padding: 0; margin: 0 0 6px; }
.fstep > legend + * { clear: both; }
.q-title { display: flex; gap: 14px; align-items: flex-start; color: var(--red); text-transform: uppercase; font-weight: 900; font-size: clamp(1.2rem, 3.4vw, 1.55rem); line-height: 1.2; hyphens: auto; -webkit-hyphens: auto; }
.q-title .step { margin-top: -2px; }
.q-help { color: var(--muted); margin: 6px 0 0 48px; }
.q-body { padding-top: 22px; }

.opt-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px; }
.opt-grid.is-list { grid-template-columns: 1fr; gap: 10px; }
.opt {
  position: relative; display: flex; flex-direction: column; align-items: center; justify-content: center; text-align: center;
  gap: 10px; min-height: 132px; padding: 22px 18px; margin: 0;
  background: #fff; border: 2px solid var(--line); border-radius: 14px; cursor: pointer;
  font-weight: 800; font-size: 1rem; line-height: 1.3;
  transition: border-color .15s, background .15s, transform .18s var(--ease), box-shadow .2s;
  -webkit-tap-highlight-color: transparent;
}
.opt:hover { border-color: var(--brand); transform: translateY(-2px); box-shadow: 0 10px 24px rgba(58, 69, 4, .10); }
.opt input { position: absolute; opacity: 0; pointer-events: none; }
.opt-icon { font-size: 2.2rem; line-height: 1; transition: transform .25s var(--ease); }
.opt:hover .opt-icon { transform: scale(1.1); }
.opt-check { position: absolute; top: 10px; right: 10px; width: 24px; height: 24px; border-radius: 50%; border: 2px solid #cfd3d8; background: #fff; display: grid; place-items: center; transition: all .15s; }
.opt-check::after { content: "✓"; font-size: .8rem; font-weight: 900; color: var(--on-brand); opacity: 0; transform: scale(.5); transition: all .2s var(--ease); }
.opt.is-multi .opt-check { border-radius: 7px; }
.opt.is-checked, .opt:has(input:checked) { border-color: var(--brand); background: var(--brand-soft); }
.opt.is-checked .opt-check, .opt:has(input:checked) .opt-check { background: var(--brand); border-color: var(--brand); }
.opt.is-checked .opt-check::after, .opt:has(input:checked) .opt-check::after { opacity: 1; transform: none; }
.opt:has(input:focus-visible) { outline: 3px solid var(--focus); outline-offset: 2px; }
.opt-grid.is-list .opt { flex-direction: row; justify-content: flex-start; text-align: left; min-height: 64px; padding: 14px 52px 14px 18px; }
.opt-grid.is-list .opt-icon { font-size: 1.6rem; }
.opt-grid.is-list .opt-check { top: 50%; margin-top: -12px; right: 16px; }
.opt.just-picked { animation: picked .35s var(--ease); }
@keyframes picked { 40% { transform: scale(.97); } }

.multi-hint { display: inline-block; font-size: .82rem; font-weight: 800; color: var(--muted); text-transform: uppercase; letter-spacing: .05em; margin: 0 0 12px; }

.dropzone { display: flex; flex-direction: column; align-items: center; gap: 8px; border: 2px dashed #c9cfb4; border-radius: 14px; padding: 34px 20px; text-align: center; background: #fafbf6; cursor: pointer; transition: border-color .15s, background .15s; margin: 0; font-weight: 400; }
.dropzone:hover, .dropzone.is-over { border-color: var(--brand); background: var(--brand-soft); }
.dropzone:has(input:focus-visible) { outline: 3px solid var(--focus); outline-offset: 2px; }
.dropzone input { position: absolute; opacity: 0; width: 1px; height: 1px; }
.dropzone-icon { font-size: 2rem; width: 64px; height: 64px; border-radius: 50%; background: #fff; display: grid; place-items: center; box-shadow: var(--shadow); }
.dropzone strong { font-weight: 800; color: var(--ink); }
.file-chosen { display: none; align-items: center; gap: 12px; padding: 14px 16px; border: 2px solid var(--brand); background: var(--brand-soft); border-radius: 12px; font-weight: 700; margin-top: 12px; }
.file-chosen.is-shown { display: flex; }
.file-chosen .name { flex: 1; overflow-wrap: anywhere; }

.funnel-nav { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-top: 28px; }
.funnel-nav .btn { min-width: 160px; }
.kbd-hint { font-size: .8rem; color: var(--muted); }
.kbd-hint kbd { font-family: inherit; font-weight: 800; border: 1px solid var(--line); border-bottom-width: 2px; border-radius: 4px; padding: 0 5px; background: #fff; }

.funnel-summary { background: #fafbf6; border: 1px solid var(--line); border-radius: 12px; padding: 6px 18px; margin: 6px 0 20px; }
.funnel-summary dt { font-size: .86rem; }
.funnel-summary dd { display: flex; justify-content: space-between; gap: 12px; align-items: baseline; }
.funnel-summary .link-btn { font-size: .85rem; font-weight: 700; flex: none; }
.summary-title { font-size: .82rem; font-weight: 800; text-transform: uppercase; letter-spacing: .06em; color: var(--muted); margin: 8px 0 8px; }

.trust { display: flex; justify-content: center; gap: 18px; flex-wrap: wrap; margin: 18px 0 0; padding: 0; list-style: none; color: var(--muted); font-size: .84rem; font-weight: 700; }
.trust li::before { content: "🔒 "; }
.trust li + li::before { content: "✓ "; color: var(--brand-dark); }

.hp { position: absolute !important; left: -9999px; width: 1px; height: 1px; overflow: hidden; }

/* JS-Modus: immer nur ein Schritt sichtbar */
.js .funnel .fstep, .js .funnel .job-card { display: none; }
.js .funnel .is-active { display: block; animation: stepIn .45s var(--ease) both; }
.js .funnel .is-active.from-back { animation-name: stepBack; }
.js .funnel.is-running .funnel-progress { display: flex; }
.js .funnel .nojs-only { display: none; }
html:not(.js) .js-only { display: none !important; }
@keyframes stepIn { from { opacity: 0; transform: translateX(28px); } to { opacity: 1; transform: none; } }
@keyframes stepBack { from { opacity: 0; transform: translateX(-28px); } to { opacity: 1; transform: none; } }
.fstep.shake { animation: shake .4s; }
@keyframes shake { 20%, 60% { transform: translateX(-6px); } 40%, 80% { transform: translateX(6px); } }

/* Stellenübersicht */
.jobs { display: grid; gap: 16px; }
.job-item { display: flex; align-items: center; gap: 18px; background: var(--card); border: 1px solid var(--line); border-radius: 14px; padding: 22px 24px; text-decoration: none; color: var(--ink); box-shadow: var(--shadow); transition: transform .18s var(--ease), box-shadow .2s, border-color .15s; }
.job-item:hover { transform: translateY(-2px); box-shadow: 0 12px 30px rgba(40,48,0,.12); border-color: var(--brand); }
.job-item h2 { font-size: 1.15rem; margin: 0 0 8px; }
.job-item .chips li { background: var(--brand-soft); border-color: transparent; color: #4a5600; font-size: .8rem; }
.job-item .go { margin-left: auto; flex: none; width: 46px; height: 46px; display: grid; place-items: center; background: var(--brand); color: var(--on-brand); font-weight: 900; font-size: 1.3rem; transition: transform .2s var(--ease); }
.job-item:hover .go { transform: translateX(4px); }
.empty { text-align: center; padding: 40px 20px; color: var(--muted); }
.empty-icon { font-size: 2.6rem; margin-bottom: 10px; }

/* =========================================================================
   INTERNER BEREICH
   ========================================================================= */

.admin { background: var(--bg); }
.admin-header { background: #fff; border-bottom: 4px solid var(--brand); position: sticky; top: 0; z-index: 20; }
.admin-header .wrap-wide { display: flex; align-items: center; gap: 18px; min-height: 66px; }
.admin-header .logo img { height: 42px; display: block; }
.app-title { color: var(--muted); text-transform: uppercase; font-weight: 800; letter-spacing: .1em; font-size: .82rem; border-left: 1px solid var(--line); padding-left: 16px; }
.admin-nav { margin-left: auto; display: flex; align-items: center; gap: 4px; }
.admin-nav a, .admin-nav button { color: var(--ink); text-decoration: none; font: inherit; font-weight: 800; font-size: .92rem; padding: 8px 14px; background: none; border: 0; cursor: pointer; border-radius: 6px; }
.admin-nav a:hover, .admin-nav button:hover { background: #f1f2ee; }
.admin-nav a[aria-current=page] { background: var(--brand-soft); box-shadow: inset 0 -3px 0 var(--brand); border-radius: 6px 6px 0 0; }
.admin-nav .count { display: inline-grid; place-items: center; min-width: 20px; height: 20px; padding: 0 6px; border-radius: 99px; background: var(--red); color: #fff; font-size: .72rem; margin-left: 4px; }
.admin-main { padding: 22px 0 60px; }

.breadcrumbs { color: var(--muted); font-size: .88rem; margin: 0 0 6px; display: flex; flex-wrap: wrap; gap: 6px; }
.breadcrumbs a { color: var(--muted); text-decoration: none; }
.breadcrumbs a:hover { color: var(--ink); text-decoration: underline; }
.breadcrumbs span[aria-hidden] { opacity: .6; }
.page-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 14px; flex-wrap: wrap; margin: 0 0 20px; }
.page-head h1 { margin: 0; font-size: clamp(1.4rem, 3vw, 1.9rem); display: flex; align-items: center; gap: 12px; flex-wrap: wrap; }
.page-head .sub { color: var(--muted); margin: 4px 0 0; }
.actions { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; }

.tabs { display: flex; gap: 4px; border-bottom: 2px solid var(--line); margin: 0 0 22px; overflow-x: auto; scrollbar-width: none; }
.tabs a, .tabs button { padding: 10px 16px; font: inherit; font-weight: 800; font-size: .93rem; color: var(--muted); text-decoration: none; border: 0; background: none; cursor: pointer; border-bottom: 3px solid transparent; margin-bottom: -2px; white-space: nowrap; }
.tabs a:hover, .tabs button:hover { color: var(--ink); }
.tabs [aria-current=page], .tabs [aria-selected=true] { color: var(--ink); border-bottom-color: var(--brand); }
.tabs .count { color: var(--muted); font-weight: 700; }

.stats { display: grid; grid-template-columns: repeat(auto-fit, minmax(190px, 1fr)); gap: 14px; margin: 0 0 22px; }
.stat { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow); padding: 18px 20px; text-decoration: none; color: var(--ink); display: block; transition: border-color .15s, transform .18s var(--ease); }
a.stat:hover { border-color: var(--brand); transform: translateY(-2px); }
.stat-num { font-size: 2.1rem; font-weight: 900; line-height: 1.1; display: block; }
.stat-label { color: var(--muted); font-size: .88rem; font-weight: 700; }
.stat-trend { font-size: .8rem; font-weight: 800; color: var(--ok); }
.stat.is-hot { border-left: 5px solid var(--red); }

.cols { display: grid; gap: 20px; }
@media (min-width: 900px) { .cols { grid-template-columns: 2fr 1fr; align-items: start; } .sticky { position: sticky; top: 90px; } }

.table-wrap { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow); overflow-x: auto; margin: 0 0 20px; }
table { width: 100%; border-collapse: collapse; font-size: .95rem; }
th { text-align: left; background: #f6f7f4; color: var(--muted); font-size: .74rem; text-transform: uppercase; letter-spacing: .06em; font-weight: 800; padding: 11px 14px; border-bottom: 1px solid var(--line); vertical-align: bottom; line-height: 1.35; }
td { padding: 12px 14px; border-bottom: 1px solid var(--line); vertical-align: middle; }
tr:last-child td { border-bottom: 0; }
tbody tr { transition: background .12s; }
tbody tr:hover td { background: var(--brand-soft); }
tr.is-new td:first-child { box-shadow: inset 4px 0 0 var(--red); }
td.num, th.num { text-align: right; font-variant-numeric: tabular-nums; }
.row-link { color: var(--ink); text-decoration: none; font-weight: 800; white-space: nowrap; }
.row-link:hover { color: var(--red); text-decoration: underline; }

.person { display: flex; align-items: center; gap: 12px; }
.avatar { width: 38px; height: 38px; border-radius: 50%; display: grid; place-items: center; background: var(--brand-soft); color: #4a5600; font-weight: 900; font-size: .85rem; flex: none; }
.avatar-lg { width: 64px; height: 64px; font-size: 1.3rem; }
.person small { display: block; color: var(--muted); font-size: .84rem; }

.filters { display: flex; gap: 10px; flex-wrap: wrap; align-items: center; margin: 0 0 16px; }
.pills { display: flex; gap: 6px; flex-wrap: wrap; }
.pill { display: inline-flex; gap: 6px; align-items: center; padding: 6px 13px; border-radius: 99px; background: #fff; border: 1px solid var(--line); color: var(--ink); font-weight: 800; font-size: .85rem; text-decoration: none; }
.pill:hover { border-color: var(--brand); }
.pill[aria-current=true] { background: var(--ink); color: #fff; border-color: var(--ink); }
.pill .n { opacity: .65; font-weight: 700; }
.search { position: relative; margin-left: auto; min-width: 240px; }
.search input { padding-left: 38px; min-height: 40px; border-radius: 99px; }
.search::before { content: "⌕"; position: absolute; left: 14px; top: 50%; transform: translateY(-52%); color: var(--muted); font-size: 1.15rem; }

.funnel-list { display: grid; gap: 14px; }
.funnel-row { display: grid; grid-template-columns: 1fr auto; gap: 16px; align-items: center; background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow); padding: 18px 20px; }
.funnel-row h3 { margin: 0 0 4px; font-size: 1.08rem; display: flex; gap: 10px; align-items: center; flex-wrap: wrap; }
.funnel-row h3 a { color: var(--ink); text-decoration: none; }
.funnel-row h3 a:hover { color: var(--red); }
.funnel-meta { display: flex; gap: 18px; flex-wrap: wrap; color: var(--muted); font-size: .88rem; font-weight: 700; }
.funnel-meta strong { color: var(--ink); }
.funnel-meta .hot { color: var(--red); }
.mini-funnel { display: flex; gap: 3px; align-items: flex-end; height: 34px; }
.mini-funnel span { width: 8px; background: var(--brand); border-radius: 2px 2px 0 0; min-height: 2px; }

/* Bewertung */
.stars { display: inline-flex; gap: 2px; }
.stars button, .stars span { background: none; border: 0; padding: 2px; font-size: 1.35rem; line-height: 1; color: #d5d8cc; cursor: pointer; }
.stars .on { color: #e8a400; }
.stars button:hover { transform: scale(1.15); }
.stars-sm span { font-size: .95rem; padding: 0; cursor: default; }

/* Pipeline */
.board { display: grid; grid-template-columns: repeat(5, minmax(200px, 1fr)); gap: 14px; overflow-x: auto; padding-bottom: 10px; }
.board-col { background: #eaece4; border-radius: 14px; padding: 12px; min-height: 360px; transition: background .15s, box-shadow .15s; }
.board-col.is-over { background: #e1e8c2; box-shadow: inset 0 0 0 2px var(--brand); }
.board-head { display: flex; justify-content: space-between; align-items: center; margin: 2px 4px 12px; }
.board-head .n { font-weight: 800; color: var(--muted); font-size: .85rem; }
.board-cards { display: grid; gap: 10px; min-height: 60px; }
.board-card { background: #fff; border: 1px solid var(--line); border-radius: 10px; padding: 12px 14px; box-shadow: 0 1px 3px rgba(0,0,0,.06); cursor: grab; transition: box-shadow .15s, transform .15s; }
.board-card:hover { box-shadow: 0 8px 20px rgba(0,0,0,.08); }
.board-card.is-dragging { opacity: .45; transform: rotate(1.5deg); }
.board-card a { color: var(--ink); text-decoration: none; font-weight: 800; }
.board-card a:hover { color: var(--red); }
.board-card .meta { font-size: .8rem; color: var(--muted); margin-top: 4px; display: flex; justify-content: space-between; gap: 8px; }
.board-card .tag { display: inline-block; font-size: .75rem; font-weight: 700; background: #f3f4ef; border-radius: 6px; padding: 2px 7px; margin-top: 8px; }

/* Auswertung */
.bars { display: grid; gap: 12px; }
.bar-row { display: grid; grid-template-columns: minmax(110px, 38%) 1fr 64px; gap: 12px; align-items: center; font-size: .92rem; }
.bar-row .lbl { font-weight: 700; overflow-wrap: anywhere; }
.bar-track { height: 12px; border-radius: 99px; background: #eceee6; overflow: hidden; }
.bar-fill { height: 100%; border-radius: inherit; background: linear-gradient(90deg, var(--brand-dark), var(--brand)); }
.bar-row .val { text-align: right; font-weight: 800; font-variant-numeric: tabular-nums; }
.funnel-steps { display: grid; gap: 8px; }
.fs-row { display: grid; grid-template-columns: 130px 1fr; gap: 14px; align-items: center; }
.fs-bar { height: 42px; background: var(--hero); color: #fff; display: flex; align-items: center; justify-content: space-between; padding: 0 14px; font-weight: 800; border-radius: 8px; min-width: 120px; transition: width .6s var(--ease); }
.fs-bar small { font-weight: 700; opacity: .85; }
.colchart { display: flex; align-items: flex-end; gap: 4px; height: 150px; padding-top: 10px; border-bottom: 1px solid var(--line); }
.colchart .c { flex: 1; background: var(--brand); border-radius: 4px 4px 0 0; min-height: 3px; position: relative; }
.colchart .c:hover { background: var(--brand-dark); }
.colchart-axis { display: flex; justify-content: space-between; font-size: .75rem; color: var(--muted); margin-top: 6px; }

/* Verlauf */
.timeline { list-style: none; margin: 0; padding: 0; }
.timeline li { position: relative; padding: 0 0 16px 24px; }
.timeline li::before { content: ""; position: absolute; left: 5px; top: 8px; width: 9px; height: 9px; border-radius: 50%; background: var(--brand); }
.timeline li::after { content: ""; position: absolute; left: 9px; top: 20px; bottom: 0; width: 1px; background: var(--line); }
.timeline li:last-child::after { display: none; }
.timeline li.system::before { background: #c9ccc2; }
.timeline .when { font-size: .8rem; color: var(--muted); }
.timeline .body { white-space: pre-line; overflow-wrap: anywhere; }

.contact-actions { display: grid; grid-template-columns: repeat(auto-fit, minmax(140px, 1fr)); gap: 10px; margin: 16px 0 0; }
.file-link { display: flex; align-items: center; gap: 12px; padding: 12px 14px; border: 1px solid var(--line); border-radius: 10px; text-decoration: none; color: var(--ink); font-weight: 700; }
.file-link:hover { border-color: var(--brand); background: var(--brand-soft); }
.file-link .ico { width: 40px; height: 40px; border-radius: 8px; background: var(--red); color: #fff; display: grid; place-items: center; font-size: .72rem; font-weight: 900; text-transform: uppercase; flex: none; }
.file-link small { display: block; color: var(--muted); font-weight: 400; }
.status-picker { display: grid; gap: 8px; }
.status-picker label { display: flex; align-items: center; gap: 10px; margin: 0; padding: 10px 12px; border: 2px solid var(--line); border-radius: 10px; cursor: pointer; font-weight: 800; transition: border-color .15s, background .15s; }
.status-picker label:hover { border-color: var(--brand); }
.status-picker input { accent-color: var(--brand-dark); width: 18px; height: 18px; margin: 0; }
.status-picker label:has(input:checked) { border-color: var(--brand); background: var(--brand-soft); }
.pager { display: flex; justify-content: space-between; gap: 10px; margin: 0 0 14px; }

/* Funnel-Baukasten */
.builder { display: grid; gap: 12px; margin: 0 0 16px; }
.bstep { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow); transition: box-shadow .2s, border-color .15s, opacity .15s; }
.bstep.is-dragging { opacity: .4; }
.bstep.drop-before { box-shadow: 0 -4px 0 var(--brand), var(--shadow); }
.bstep.drop-after { box-shadow: 0 4px 0 var(--brand), var(--shadow); }
.bstep[open] { border-color: #cfd6a8; }
.bstep > summary { list-style: none; display: flex; align-items: center; gap: 12px; padding: 14px 16px; cursor: pointer; }
.bstep > summary::-webkit-details-marker { display: none; }
.bstep-handle { cursor: grab; color: #a3a8ad; font-size: 1.1rem; letter-spacing: -2px; padding: 4px 2px; user-select: none; }
.bstep-type { width: 34px; height: 34px; border-radius: 8px; background: var(--brand-soft); color: #4a5600; display: grid; place-items: center; font-weight: 900; flex: none; }
.bstep-title { flex: 1; min-width: 0; }
.bstep-title strong { display: block; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.bstep-title small { color: var(--muted); font-size: .8rem; font-weight: 700; }
.bstep-tools { display: flex; gap: 2px; }
.icon-btn { width: 34px; height: 34px; display: grid; place-items: center; border: 0; background: none; border-radius: 8px; cursor: pointer; color: var(--muted); font-size: 1rem; font-weight: 800; }
.icon-btn:hover { background: #f1f2ee; color: var(--ink); }
.icon-btn.danger:hover { background: var(--err-bg); color: var(--err); }
.icon-btn[disabled] { opacity: .3; cursor: default; background: none; }
.bstep-body { padding: 4px 18px 18px; border-top: 1px solid var(--line); }
.bstep-body .field:first-child { margin-top: 14px; }
.opt-edit { display: grid; gap: 8px; margin: 0 0 10px; }
.opt-edit-row { display: grid; grid-template-columns: 56px 1fr 34px; gap: 8px; align-items: center; }
.emoji-btn { min-height: 46px; border: 1.5px solid #cfd3d8; border-radius: 6px; background: #fff; font-size: 1.35rem; cursor: pointer; }
.emoji-btn:hover { border-color: var(--brand); }
.emoji-pop { position: absolute; z-index: 30; width: min(380px, calc(100vw - 16px)); background: #fff; border: 1px solid var(--line); border-radius: 14px; box-shadow: var(--shadow-lg); padding: 12px; }
.emoji-search { min-height: 40px !important; font-size: .95rem !important; }
.emoji-cats { display: flex; gap: 4px; overflow-x: auto; margin: 10px 0 8px; padding-bottom: 4px; scrollbar-width: thin; }
.emoji-cats button { flex: none; border: 1px solid var(--line); background: #f6f7f4; border-radius: 99px; padding: 4px 10px; font: inherit; font-size: .78rem; font-weight: 800; cursor: pointer; white-space: nowrap; }
.emoji-cats button:hover { border-color: var(--brand); }
.emoji-cats button[aria-selected=true] { background: var(--brand-soft); border-color: var(--brand); }
.emoji-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(38px, 1fr)); gap: 2px; max-height: 232px; overflow-y: auto; }
.emoji-grid button { height: 38px; border: 0; background: none; border-radius: 8px; font-size: 1.35rem; cursor: pointer; }
.emoji-grid button:hover, .emoji-grid button:focus-visible { background: var(--brand-soft); }
.emoji-empty { grid-column: 1 / -1; margin: 12px 4px; font-size: .88rem; color: var(--muted); }
.emoji-foot { display: flex; align-items: center; gap: 6px; border-top: 1px solid var(--line); margin-top: 8px; padding-top: 10px; flex-wrap: wrap; }
.emoji-own { width: 56px !important; min-height: 36px !important; text-align: center; font-size: 1.2rem !important; padding: 4px !important; }
.emoji-tip { font-size: .74rem; color: var(--muted); margin: 8px 0 0; }
.add-steps { display: flex; flex-wrap: wrap; gap: 8px; padding: 14px; border: 2px dashed #cfd3d8; border-radius: var(--radius); background: rgba(255,255,255,.5); align-items: center; }
.add-steps .label { margin: 0 6px 0 0; color: var(--muted); }
.fixed-step { display: flex; align-items: center; gap: 12px; padding: 14px 16px; border-radius: var(--radius); background: #eceee7; color: var(--muted); font-weight: 700; font-size: .92rem; margin: 0 0 12px; }
.link-box { display: flex; gap: 8px; align-items: stretch; }
.link-box input { font-size: .88rem; min-height: 40px; }
.link-box input[readonly] { background: #f6f7f4; color: var(--muted); }
.editor-panel[hidden] { display: none; }

.login-box { max-width: 440px; margin: 60px auto; }
.login-box .card { padding: 32px; }

/* App-Leiste (Handy) */
.app-bar { display: none; }

@media (max-width: 760px) {
  body { font-size: 16px; }
  .header-links .hide-sm { display: none; }
  .site-header .logo img { height: 44px; }
  .footer-cols { grid-template-columns: 1fr; }
  .field-row { grid-template-columns: 1fr; }
  .admin-nav { display: none; }
  .admin-header .wrap-wide { min-height: 56px; }
  .admin-header .logo img { height: 36px; }
  .admin { padding-bottom: 76px; }
  .app-bar {
    display: grid; grid-auto-flow: column; grid-auto-columns: 1fr; position: fixed; left: 0; right: 0; bottom: 0; z-index: 40;
    background: #fff; border-top: 1px solid var(--line); box-shadow: 0 -4px 18px rgba(0,0,0,.06);
    padding: 6px 4px calc(6px + env(safe-area-inset-bottom));
  }
  .app-bar a, .app-bar button { display: flex; flex-direction: column; align-items: center; gap: 2px; padding: 6px 2px; font: inherit; font-size: .7rem; font-weight: 800; color: var(--muted); text-decoration: none; background: none; border: 0; border-radius: 10px; }
  .app-bar svg { width: 24px; height: 24px; }
  .app-bar [aria-current=page] { color: var(--ink); background: var(--brand-soft); }
  .app-bar a { position: relative; }
  .app-bar .count { position: absolute; top: 2px; left: 50%; margin-left: 6px; min-width: 18px; height: 18px; padding: 0 5px; border-radius: 99px; background: var(--red); color: #fff; font-size: .68rem; display: grid; place-items: center; }
  .site-footer.admin-footer { display: none; }
  .search { margin-left: 0; min-width: 0; width: 100%; }
  dl.summary { grid-template-columns: 1fr; }
  dl.summary dt { border-bottom: 0; padding-bottom: 0; }
  dl.summary > :nth-last-child(2) { border-bottom: 0; }
  .funnel-row { grid-template-columns: 1fr; }
  .bar-row { grid-template-columns: 1fr 50px; }
  .bar-row .lbl { grid-column: 1 / -1; }
  .fs-row { grid-template-columns: 1fr; gap: 4px; }

  table.table-cards thead { display: none; }
  table.table-cards, table.table-cards tbody, table.table-cards tr, table.table-cards td { display: block; }
  table.table-cards tr { padding: 12px 14px; border-bottom: 1px solid var(--line); position: relative; }
  table.table-cards td { border: 0; padding: 3px 0; }
  table.table-cards td[data-label]:not(:first-child)::before { content: attr(data-label) ": "; color: var(--muted); font-size: .82rem; }
  table.table-cards td.num { text-align: left; }
}

@media (max-width: 560px) {
  .funnel { padding-top: 16px; }
  .fstep { padding: 24px 18px; border-radius: 16px; }
  .job-hero { padding: 30px 22px 26px; }
  .job-body { padding: 24px 22px 26px; }
  .job-body [data-next] { position: sticky; bottom: 12px; z-index: 5; box-shadow: 0 10px 30px rgba(40,48,0,.25); }
  .q-help { margin-left: 0; }
  .opt-grid { grid-template-columns: 1fr; gap: 10px; }
  .opt { flex-direction: row; justify-content: flex-start; text-align: left; min-height: 66px; padding: 14px 52px 14px 16px; }
  .opt-icon { font-size: 1.6rem; }
  .opt-check { top: 50%; margin-top: -12px; right: 14px; }
  .funnel-nav .btn { min-width: 0; flex: 1; }
  .btn-lg { padding: 14px 18px; font-size: 1rem; letter-spacing: .02em; }
  .kbd-hint { display: none; }
  .job-item { padding: 18px; }
  .job-item .go { width: 38px; height: 38px; }
}

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

@media print {
  .site-header, .admin-header, .site-footer, .app-bar, .actions, .tabs, .no-print { display: none !important; }
  body { background: #fff; }
  .card { box-shadow: none; break-inside: avoid; }
}

/* Pipeline: Status per Auswahl (Tastatur & Touch) */
.board-move { display: none; margin-top: 10px; min-height: 34px !important; padding: 4px 8px !important; font-size: .82rem !important; }
.board-card:hover .board-move, .board-card:focus-within .board-move { display: block; }
@media (hover: none) { .board-move { display: block; } .board-card { cursor: default; } }

/* Kurzmeldung */
.toast { position: fixed; left: 50%; bottom: 24px; transform: translate(-50%, 20px); background: var(--ink); color: #fff; padding: 11px 18px; border-radius: 10px; font-weight: 800; font-size: .9rem; box-shadow: var(--shadow-lg); opacity: 0; pointer-events: none; transition: opacity .2s, transform .25s var(--ease); z-index: 60; }
.toast.is-shown { opacity: 1; transform: translate(-50%, 0); }
@media (max-width: 760px) { .toast { bottom: 90px; } }

/* Einstellungen: Mailvorlagen */
textarea.tpl { font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; font-size: .88rem; line-height: 1.55; min-height: 320px; }
.ph-list { display: flex; flex-wrap: wrap; gap: 6px; margin: 8px 0 0; }
.ph-list button { font: inherit; font-size: .8rem; font-weight: 700; padding: 4px 9px; border-radius: 6px; border: 1px solid var(--line); background: #f6f7f4; cursor: pointer; }
.ph-list button:hover { border-color: var(--brand); background: var(--brand-soft); }
.ph-list code { font-family: ui-monospace, Menlo, monospace; color: #4a5600; }
.sender-box { background: #f6f7f4; border: 1px solid var(--line); border-radius: 8px; padding: 10px 12px; font-weight: 700; overflow-wrap: anywhere; }

/* Benutzer: Aktionsmenü je Zeile */
.row-menu { position: relative; display: inline-block; text-align: left; }
.row-menu > summary { list-style: none; cursor: pointer; font-weight: 700; }
.row-menu > summary::-webkit-details-marker { display: none; }
.row-menu[open] > summary { margin-bottom: 8px; }
.row-menu-body { width: 250px; background: #fafbf6; border: 1px solid var(--line); border-radius: 12px; padding: 14px; display: grid; gap: 12px; }
@media (max-width: 760px) { .row-menu-body { width: auto; } }

/* Bewerber manuell anlegen */
.check-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 10px 18px; }
.file-list { display: grid; gap: 10px; }
.person .badge { margin-top: 4px; }
.file-row { display: grid; grid-template-columns: 1fr auto; gap: 12px; align-items: center; }
.remove-check { font-size: .88rem; color: var(--err); font-weight: 700; }
