/* Kontaktformular – nutzt die Template-Farben (tu-*) mit Fallbacks */
.tk { --k-bg: var(--tu-bg2, #f3f1ea); --k-surface: var(--tu-surface, #fff); --k-ink: var(--tu-ink, #0f1013); --k-text: var(--tu-text, #34322d); --k-muted: var(--tu-muted, #5f5b53); --k-line: var(--tu-line2, rgba(15,16,19,.24)); --k-accent: var(--tu-accent, #ffc93c); --k-on: var(--tu-on-accent, #0f1013); --k-bad: #c2410c; --k-ok: #1f8a4c; margin: 32px 0; color: var(--k-text); }
[data-theme="dark"] .tk { --k-bad: #fb923c; --k-ok: #4ade80; }
.tk *, .tk *::before, .tk *::after { box-sizing: border-box; }
.tk-card { position: relative; overflow: hidden; padding: clamp(28px, 4vw, 48px); padding-top: clamp(40px, 5vw, 60px); border-radius: 26px; background: var(--k-surface); border: 1px solid var(--tu-line, rgba(15,16,19,.1)); }
.tk-checker { position: absolute; left: 0; right: 0; top: 0; height: 12px; background: repeating-conic-gradient(var(--k-accent) 0 25%, var(--k-ink) 0 50%) 0 0 / 12px 12px; }
.tk-h { margin: 0; font-family: var(--tu-display, inherit); font-size: clamp(28px, 3.2vw, 42px); line-height: 1.05; color: var(--k-ink); }
.tk-lead { margin: 12px 0 0; max-width: 720px; color: var(--k-muted); }
.tk-sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }
.tk-type { display: flex; flex-wrap: wrap; gap: 10px; margin: 26px 0 0; padding: 0; border: 0; }
.tk-pill { position: relative; cursor: pointer; }
.tk-pill input { position: absolute; opacity: 0; inset: 0; cursor: pointer; }
.tk-pill span { display: inline-flex; align-items: center; min-height: 48px; padding: 0 22px; border-radius: 999px; border: 1px solid var(--k-line); background: var(--k-surface); font-weight: 600; transition: background .2s, color .2s, border-color .2s; }
.tk-pill input:checked + span { background: var(--k-ink); color: var(--k-surface); border-color: var(--k-ink); }
.tk-pill input:focus-visible + span { outline: 3px solid var(--k-accent); outline-offset: 2px; }
.tk-grid { margin-top: 24px; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px 20px; }
.tk-field { display: flex; flex-direction: column; gap: 6px; }
.tk-field--full { grid-column: 1 / -1; }
.tk-field label { font-weight: 600; color: var(--k-ink); font-size: 15px; }
.tk-field small { color: var(--k-muted); font-size: 13px; }
.tk input[type=text], .tk input[type=email], .tk input[type=tel], .tk select, .tk textarea { width: 100%; min-height: 50px; padding: 12px 14px; border-radius: 12px; border: 1px solid var(--k-line); background: var(--k-bg); color: var(--k-ink); font: inherit; }
.tk textarea { resize: vertical; min-height: 130px; }
.tk input:focus, .tk select:focus, .tk textarea:focus { outline: 3px solid var(--k-accent); outline-offset: 1px; border-color: var(--k-ink); }
.tk [aria-invalid=true] { border-color: var(--k-bad) !important; }
.tk-err { margin: 2px 0 0; color: var(--k-bad); font-size: 14px; font-weight: 600; }
.tk-hp { position: absolute !important; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
.tk-checks { margin-top: 22px; display: flex; flex-direction: column; gap: 12px; }
.tk-check { display: flex; gap: 12px; align-items: flex-start; flex-wrap: wrap; padding: 14px 16px; border-radius: 14px; background: var(--k-bg); cursor: pointer; font-size: 15px; line-height: 1.5; }
.tk-check input { flex: none; width: 22px; height: 22px; margin: 1px 0 0; accent-color: var(--k-ink); }
.tk-check > span { flex: 1 1 260px; }
.tk-check .tk-err { flex-basis: 100%; }
.tk-check a { color: inherit; text-decoration: underline; }
.tk-actions { margin-top: 24px; display: flex; flex-wrap: wrap; align-items: center; gap: 14px 22px; }
.tk-btn { display: inline-flex; align-items: center; justify-content: center; min-height: 54px; padding: 0 30px; border-radius: 999px; border: 0; background: var(--k-accent); color: var(--k-on); font: inherit; font-weight: 700; font-size: 16px; cursor: pointer; transition: transform .2s; }
.tk-btn:hover { transform: translateY(-2px); }
.tk-btn:disabled { opacity: .6; cursor: wait; }
.tk-note { margin: 0; font-size: 13px; color: var(--k-muted); }
.tk-msg { margin-top: 16px; font-weight: 600; outline: none; }
.tk-msg.is-ok { padding: 18px 20px; border-radius: 14px; background: color-mix(in srgb, var(--k-ok) 14%, transparent); color: var(--k-ink); font-weight: 400; }
.tk-msg.is-warn { color: var(--k-bad); }
.tk-form.is-info .tk-only-reg, .tk-form.is-info .tk-btn-reg, .tk-form.is-info .tk-req-reg, .tk-form.is-reg .tk-btn-info { display: none; }
.tk-form.is-sent .tk-grid, .tk-form.is-sent .tk-checks, .tk-form.is-sent .tk-actions, .tk-form.is-sent .tk-type { display: none; }
/* „Ich bin kein Roboter“ */
.tk-robot { position: relative; display: flex; flex-wrap: wrap; align-items: center; gap: 10px 16px; max-width: 460px; padding: 14px 16px; border-radius: 14px; border: 1px solid var(--k-line); background: var(--k-bg); }
.tk-robot-box { display: flex; align-items: center; gap: 14px; flex: 1 1 auto; cursor: pointer; font-weight: 600; color: var(--k-ink); min-height: 40px; }
.tk-robot-box input { position: absolute; opacity: 0; width: 1px; height: 1px; }
.tk-robot-mark { position: relative; flex: none; width: 30px; height: 30px; border-radius: 8px; border: 2px solid var(--k-ink); background: var(--k-surface); transition: border-color .2s, background .2s; }
.tk-robot-box input:focus-visible + .tk-robot-mark { outline: 3px solid var(--k-accent); outline-offset: 2px; }
.tk-robot[data-state=busy] .tk-robot-mark { border-color: var(--k-accent); border-right-color: transparent; border-radius: 50%; animation: tk-spin .8s linear infinite; }
.tk-robot[data-state=ok] .tk-robot-mark { border-color: var(--k-ok); background: var(--k-ok); }
.tk-robot[data-state=ok] .tk-robot-mark::after { content: ""; position: absolute; left: 8px; top: 3px; width: 8px; height: 15px; border: solid #fff; border-width: 0 3px 3px 0; transform: rotate(45deg); }
.tk-robot[data-state=ok] .tk-robot-box { cursor: default; }
.tk-robot-side { display: flex; align-items: center; gap: 6px; color: var(--k-muted); }
.tk-robot-side small { font-size: 11px; line-height: 1.2; }
.tk-robot[data-state=ok] .tk-robot-side { color: var(--k-ok); }
.tk-robot-status { flex-basis: 100%; font-size: 13px; color: var(--k-muted); }
.tk-robot-status:empty { display: none; }
.tk-robot .tk-err { flex-basis: 100%; }
.tk-robot[data-invalid] { border-color: var(--k-bad); }
@keyframes tk-spin { to { transform: rotate(360deg); } }
@media (prefers-reduced-motion: reduce) { .tk-robot[data-state=busy] .tk-robot-mark { animation-duration: 2.4s; } }
@media (max-width: 640px) { .tk-grid { grid-template-columns: 1fr; } .tk-field--spacer { display: none; } .tk-btn { width: 100%; } }
