/*! KI-Agent-Pro Consent 1.1.0 */
html.kac-lock, html.kac-lock body { overflow: hidden !important; }

#kac p, .kac-chat-card p, .kac-blocked p { padding: 0; }
#kac ul, #kac dl { padding: 0; }
#kac, #kac *, .kac-float, .kac-chat-launch, .kac-chat-card, .kac-chat-card *, .kac-blocked, .kac-blocked * { box-sizing: border-box; }

#kac { position: fixed; inset: 0; z-index: 2147483000; display: flex; align-items: center; justify-content: center; padding: 16px;
  font-family: inherit; font-size: 16px; line-height: 1.55; color: var(--kac-text, #0E1730); -webkit-font-smoothing: antialiased; }
#kac .kac-backdrop { position: absolute; inset: 0; background: rgba(9, 14, 30, .62); backdrop-filter: blur(3px); -webkit-backdrop-filter: blur(3px);
  opacity: 0; transition: opacity .25s ease; touch-action: none; }
#kac .kac-dialog { position: relative; width: 100%; max-width: 640px; max-height: calc(100vh - 32px); max-height: calc(100dvh - 32px); display: flex; flex-direction: column;
  background: var(--kac-bg, #fff); color: var(--kac-text, #0E1730); border-radius: var(--kac-radius, 16px);
  box-shadow: 0 30px 80px -20px rgba(9, 14, 30, .55), 0 0 0 1px rgba(14, 23, 48, .06);
  opacity: 0; transform: translateY(14px) scale(.985); transition: opacity .28s ease, transform .28s cubic-bezier(.2, .8, .2, 1); outline: none; }
#kac.kac-in .kac-backdrop { opacity: 1; }
#kac.kac-in .kac-dialog { opacity: 1; transform: none; }
#kac.kac-reduce .kac-dialog, #kac.kac-reduce .kac-backdrop { transition: none; }
#kac.kac-layer-prefs .kac-dialog { max-width: 760px; }
#kac .kac-scroll { overflow-y: auto; overscroll-behavior: contain; padding: 34px 38px 26px; -webkit-overflow-scrolling: touch; }

/* Leiste unten, Seite bleibt bedienbar */
#kac.kac-bar { inset: auto 0 0 0; align-items: flex-end; pointer-events: none; }
#kac.kac-bar .kac-backdrop, #kac.kac-corner .kac-backdrop { display: none; }
#kac.kac-bar .kac-dialog { pointer-events: auto; max-height: 85vh; }
#kac.kac-bar:not(.kac-layer-prefs) .kac-dialog { max-width: 1100px; }

/* Kleines Fenster in der Ecke: kein Abdunkeln, Seite bleibt bedienbar */
#kac.kac-corner { inset: auto 20px 20px auto; display: block; width: 384px; max-width: calc(100vw - 40px); padding: 0; font-size: 15px; pointer-events: none; }
#kac.kac-corner.kac-side-left { inset: auto auto 20px 20px; }
#kac.kac-corner.kac-layer-prefs { width: 460px; }
#kac.kac-corner.kac-layer-prefs .kac-dialog { max-height: min(720px, calc(100vh - 40px)); max-height: min(720px, calc(100dvh - 40px)); }
#kac.kac-corner .kac-dialog { max-width: none; pointer-events: auto; max-height: calc(100vh - 40px); max-height: calc(100dvh - 40px);
  box-shadow: 0 18px 48px -14px rgba(9, 14, 30, .42), 0 0 0 1px rgba(14, 23, 48, .09); }
#kac.kac-corner .kac-scroll { padding: 20px 22px 14px; }
#kac.kac-corner .kac-title { margin: 0 0 8px; padding: 0 34px 0 0; font-size: 1.06rem; text-align: left; letter-spacing: 0; }
#kac.kac-corner.kac-layer-prefs .kac-title { font-size: 1.15rem; }
#kac.kac-corner .kac-body p { margin: 0 0 6px; font-size: .86rem; line-height: 1.5; }
#kac.kac-corner .kac-gpc { padding: 8px 10px; font-size: .8rem !important; }
#kac.kac-corner .kac-x { top: 10px; right: 10px; width: 34px; height: 34px; }
#kac.kac-corner .kac-x svg { width: 18px; height: 18px; }
#kac.kac-corner .kac-back { margin: -6px 0 8px -6px; }
#kac.kac-corner .kac-actions { grid-template-columns: 1fr 1fr; gap: 8px; margin: 14px 0 8px; }
#kac.kac-corner .kac-actions-prefs .kac-b-more { grid-column: 1 / -1; }
#kac.kac-corner .kac-btn { min-height: 44px; padding: 10px 12px; border-radius: 10px; font-size: .92rem; }
#kac .kac-foot { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 2px 14px; }
#kac .kac-linkbtn { -webkit-appearance: none; appearance: none; margin: 0; padding: 6px 0; min-height: 32px; border: 0; background: transparent; color: inherit;
  font-weight: 700; font-size: .84rem; line-height: 1.2; font-family: inherit; text-decoration: underline; text-underline-offset: 2px; cursor: pointer; }
#kac .kac-linkbtn:hover { text-decoration-thickness: 2px; }
#kac.kac-corner .kac-links { justify-content: flex-end; gap: 2px 14px; margin: 0; font-size: .8rem; }
#kac.kac-corner .kac-links a { display: inline-block; padding: 6px 0; }
#kac.kac-corner .kac-meta { font-size: .72rem; }
#kac.kac-corner .kac-cats { gap: 8px; margin-top: 12px; }
#kac.kac-corner .kac-cat { padding: 2px 12px 12px; border-radius: 12px; }
#kac.kac-corner .kac-cat-open { font-size: .94rem; min-height: 44px; }
#kac.kac-corner .kac-cat-desc { font-size: .82rem; }
#kac.kac-corner .kac-svc { padding: 10px 12px; }
#kac.kac-corner .kac-dl { grid-template-columns: 1fr; gap: 0; font-size: .78rem; }
#kac.kac-corner .kac-dl dd { margin-bottom: 6px; }
/* Solange das Fenster offen ist, Chat-Knopf ausblenden (gleiche Ecke) */
html.kac-shown .kac-chat-launch, html.kac-shown .kac-chat-card { display: none !important; }

/* Texte */
#kac .kac-title { margin: 0 0 12px; padding: 0 40px 0 0; font-weight: 700; font-size: 1.4rem; line-height: 1.25; font-family: inherit; color: inherit; letter-spacing: -.01em; text-align: center; }
#kac.kac-layer-prefs .kac-title { text-align: left; }
#kac .kac-body p { margin: 0 0 10px; font-size: .95rem; line-height: 1.6; color: inherit; opacity: .86; }
#kac .kac-gpc { padding: 10px 14px; border-radius: 10px; background: rgba(14, 23, 48, .06); opacity: 1 !important; font-size: .88rem !important; }
#kac a { color: var(--kac-link, #C0451F); text-decoration: underline; text-underline-offset: 2px; }
#kac a:hover { text-decoration-thickness: 2px; }

/* Schließen und Zurück */
#kac .kac-x { position: absolute; top: 16px; right: 16px; width: 40px; height: 40px; display: grid; place-items: center; padding: 0; margin: 0;
  border: 0; border-radius: 50%; background: transparent; color: inherit; cursor: pointer; }
#kac .kac-x svg { width: 22px; height: 22px; }
#kac .kac-x:hover { background: rgba(14, 23, 48, .07); }
#kac .kac-back { display: inline-flex; align-items: center; gap: 6px; margin: -8px 0 10px -6px; padding: 6px 10px; border: 0; border-radius: 8px; background: transparent;
  color: inherit; font-weight: 600; font-size: .9rem; line-height: 1; font-family: inherit; cursor: pointer; opacity: .8; }
#kac .kac-back span { font-size: 1.3rem; line-height: .6; }
#kac .kac-back:hover { background: rgba(14, 23, 48, .07); opacity: 1; }

/* Buttons: gleich groß, Ablehnen gleichwertig sichtbar */
#kac .kac-actions { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; margin: 22px 0 14px; }
#kac .kac-btn, .kac-chat-card .kac-btn, .kac-blocked .kac-blocked-load { -webkit-appearance: none; appearance: none; display: inline-flex; align-items: center; justify-content: center;
  min-height: 52px; margin: 0; padding: 12px 18px; border: 1.5px solid transparent; border-radius: 12px; font-weight: 700; font-size: 1rem; line-height: 1.2; font-family: inherit; letter-spacing: 0;
  text-align: center; text-transform: none; cursor: pointer; transition: filter .15s ease, transform .15s ease, background-color .15s ease; box-shadow: none; }
#kac .kac-btn:hover, .kac-chat-card .kac-btn:hover, .kac-blocked .kac-blocked-load:hover { filter: brightness(1.08); }
#kac .kac-btn:active, .kac-chat-card .kac-btn:active { transform: translateY(1px); }
#kac .kac-b-accept, .kac-chat-card .kac-b-accept, .kac-blocked .kac-blocked-load { background: var(--kac-accept, #C0451F); color: var(--kac-accept-text, #fff); }
#kac .kac-b-reject { background: var(--kac-reject, #0E1730); color: var(--kac-reject-text, #fff); }
#kac .kac-b-more, .kac-chat-card .kac-b-more { background: transparent; color: var(--kac-text, #0E1730); border-color: rgba(14, 23, 48, .22); }
#kac .kac-b-more:hover, .kac-chat-card .kac-b-more:hover { background: rgba(14, 23, 48, .05); filter: none; }
#kac.kac-btns-highlight .kac-b-reject, #kac.kac-btns-highlight .kac-b-more { background: rgba(14, 23, 48, .07); color: var(--kac-text, #0E1730); border-color: transparent; }

#kac .kac-links { display: flex; flex-wrap: wrap; justify-content: center; gap: 6px 22px; margin: 4px 0 0; font-size: .86rem; }
#kac .kac-links a { color: inherit; opacity: .9; }
#kac .kac-meta { margin: 0 0 8px; font-size: .78rem; opacity: .65; text-align: center; word-break: break-all; }

/* Fokus sichtbar */
#kac :focus-visible, .kac-float:focus-visible, .kac-chat-launch:focus-visible, .kac-chat-card :focus-visible, .kac-blocked :focus-visible {
  outline: 3px solid var(--kac-accept, #C0451F); outline-offset: 2px; }
#kac .kac-dialog:focus-visible { outline: none; }

/* Einstellungen */
#kac .kac-cats { display: grid; gap: 10px; margin-top: 16px; }
#kac .kac-cat { border: 1px solid rgba(14, 23, 48, .12); border-radius: 14px; padding: 4px 16px 14px; background: rgba(14, 23, 48, .015); }
#kac .kac-cat-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
#kac .kac-cat-open { flex: 1; display: flex; align-items: center; gap: 10px; min-height: 48px; margin: 0 0 0 -6px; padding: 8px 6px; border: 0; background: transparent;
  color: inherit; font-weight: 700; font-size: 1rem; line-height: 1.3; font-family: inherit; text-align: left; cursor: pointer; border-radius: 8px; }
#kac .kac-cat-open svg { width: 20px; height: 20px; flex: none; transition: transform .2s ease; }
#kac .kac-cat-open[aria-expanded="true"] svg { transform: rotate(180deg); }
#kac .kac-cat-count { font-weight: 500; font-size: .82rem; opacity: .6; }
#kac .kac-cat-desc { margin: 0; font-size: .88rem; opacity: .8; }
#kac .kac-svcs { margin-top: 12px; display: grid; gap: 10px; }
#kac .kac-svcs[hidden] { display: none; }
#kac .kac-svc { border-radius: 10px; background: var(--kac-bg, #fff); border: 1px solid rgba(14, 23, 48, .1); padding: 12px 14px; }
#kac .kac-svc-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 8px; }
#kac .kac-svc-name { font-weight: 700; font-size: .95rem; }
#kac .kac-dl { display: grid; grid-template-columns: minmax(120px, 30%) 1fr; gap: 6px 14px; margin: 0; font-size: .82rem; line-height: 1.5; }
#kac .kac-dl dt { margin: 0; font-weight: 600; opacity: .7; }
#kac .kac-dl dd { margin: 0; }

/* Schalter */
#kac .kac-switch { position: relative; display: inline-flex; flex: none; width: 50px; height: 30px; margin: 0; cursor: pointer; }
#kac .kac-switch-sm { width: 44px; height: 26px; }
#kac .kac-switch input { position: absolute; inset: 0; width: 100%; height: 100%; margin: 0; opacity: 0; cursor: pointer; z-index: 1; }
#kac .kac-slider { position: absolute; inset: 0; border-radius: 999px; background: rgba(14, 23, 48, .28); transition: background-color .2s ease; }
#kac .kac-slider::after { content: ""; position: absolute; top: 3px; left: 3px; width: 24px; height: 24px; border-radius: 50%; background: #fff; box-shadow: 0 1px 3px rgba(0, 0, 0, .25); transition: transform .2s ease; }
#kac .kac-switch-sm .kac-slider::after { width: 20px; height: 20px; }
#kac .kac-switch input:checked + .kac-slider { background: var(--kac-accept, #C0451F); }
#kac .kac-switch input:checked + .kac-slider::after { transform: translateX(20px); }
#kac .kac-switch-sm input:checked + .kac-slider::after { transform: translateX(18px); }
#kac .kac-switch input:indeterminate + .kac-slider { background: rgba(192, 69, 31, .5); }
#kac .kac-switch input:indeterminate + .kac-slider::after { transform: translateX(10px); }
#kac .kac-switch input:disabled { cursor: not-allowed; }
#kac .kac-switch input:disabled + .kac-slider { opacity: .55; }
#kac .kac-switch input:focus-visible + .kac-slider { outline: 3px solid var(--kac-accept, #C0451F); outline-offset: 2px; }
#kac .kac-sr, .kac-sr { position: absolute !important; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0; }

/* Schwebender Knopf */
.kac-float { position: fixed; bottom: 18px; z-index: 2147482000; width: 46px; height: 46px; display: grid; place-items: center; padding: 0; margin: 0;
  border: 1px solid rgba(255, 255, 255, .18); border-radius: 50%; background: var(--kac-reject, #0E1730); color: var(--kac-reject-text, #fff);
  box-shadow: 0 10px 26px -8px rgba(9, 14, 30, .6); cursor: pointer; transition: transform .2s ease; }
.kac-float:hover { transform: translateY(-2px); }
.kac-float svg { width: 24px; height: 24px; }
.kac-float-left { left: 18px; }
.kac-float-right { right: 18px; }
.kac-float[hidden] { display: none; }

/* KI-Chat: Startknopf und Hinweis */
.kac-chat-launch { position: fixed; right: 18px; bottom: 18px; z-index: 2147482001; display: inline-flex; align-items: center; gap: 8px; min-height: 52px; margin: 0;
  padding: 0 20px 0 16px; border: 0; border-radius: 999px; background: var(--kac-accept, #C0451F); color: var(--kac-accept-text, #fff);
  font-weight: 700; font-size: .98rem; line-height: 1; font-family: inherit; box-shadow: 0 14px 30px -10px rgba(192, 69, 31, .7); cursor: pointer; }
.kac-chat-launch svg { width: 22px; height: 22px; }
.kac-chat-card { position: fixed; right: 18px; bottom: 82px; z-index: 2147482002; width: min(360px, calc(100vw - 36px)); padding: 20px; border-radius: 16px;
  background: var(--kac-bg, #fff); color: var(--kac-text, #0E1730); font-family: inherit; box-shadow: 0 24px 60px -16px rgba(9, 14, 30, .55), 0 0 0 1px rgba(14, 23, 48, .06); }
.kac-chat-card .kac-chat-title { margin: 0 0 6px; font-weight: 700; font-size: 1.05rem; }
.kac-chat-card .kac-chat-text { margin: 0 0 14px; font-size: .88rem; line-height: 1.55; opacity: .85; }
.kac-chat-card a { color: var(--kac-link, #C0451F); }
.kac-chat-card .kac-chat-actions { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.kac-chat-card .kac-btn { min-height: 46px; font-size: .95rem; }

/* Gesperrte Videos und Karten */
.kac-blocked { position: relative; display: flex; align-items: center; justify-content: center; width: 100%; min-height: 220px; margin: 0 0 1em; padding: 20px;
  overflow: hidden; border-radius: 14px; background: radial-gradient(120% 120% at 20% 0%, #1F2C55 0%, #0E1730 60%); color: #fff; font-family: inherit; text-align: center; }
.kac-blocked-box { max-width: 520px; }
.kac-blocked .kac-blocked-title { margin: 0 0 8px; font-weight: 700; font-size: 1.1rem; color: #fff; }
.kac-blocked .kac-blocked-text { margin: 0 0 14px; font-size: .9rem; line-height: 1.55; color: rgba(255, 255, 255, .86); }
.kac-blocked .kac-blocked-text a { color: #FFB38A; }
.kac-blocked .kac-blocked-actions { margin: 0 0 10px; }
.kac-blocked .kac-blocked-load { min-height: 46px; }
.kac-blocked .kac-blocked-always { display: inline-flex; align-items: center; gap: 8px; font-size: .85rem; color: rgba(255, 255, 255, .86); cursor: pointer; }
.kac-blocked .kac-blocked-always input { width: 18px; height: 18px; margin: 0; accent-color: var(--kac-accept, #C0451F); }

/* Geladene Einbettung, passt sich der Breite an */
.kac-embed { position: relative; width: 100%; margin: 0 0 1em; }
.kac-embed iframe { position: absolute; inset: 0; width: 100% !important; height: 100% !important; border: 0; }

/* Cookie-Liste für die Datenschutzerklärung */
.kac-list-table { width: 100%; margin: 0 0 18px; border-collapse: collapse; font-size: .92em; }
.kac-list-table caption { text-align: left; font-weight: 700; padding: 6px 0; }
.kac-list-table th, .kac-list-table td { padding: 8px 10px; border: 1px solid rgba(0, 0, 0, .12); vertical-align: top; text-align: left; }
.kac-list-table th { width: 30%; font-weight: 600; }

/* Handy */
@media (max-width: 640px) {
  #kac { padding: 10px; align-items: flex-end; }
  #kac .kac-dialog { max-height: calc(100vh - 20px); max-height: calc(100dvh - 20px); border-radius: var(--kac-radius, 16px); }
  #kac .kac-scroll { padding: 24px 20px 18px; }
  #kac .kac-title { font-size: 1.2rem; text-align: left; }
  #kac .kac-body p { font-size: .9rem; }
  #kac .kac-actions { grid-template-columns: 1fr; gap: 10px; margin: 18px 0 12px; }
  #kac .kac-btn { min-height: 50px; }
  #kac .kac-dl { grid-template-columns: 1fr; gap: 2px; }
  #kac .kac-dl dd { margin-bottom: 6px; }
  #kac .kac-links { justify-content: flex-start; }
  #kac .kac-meta { text-align: left; }
  #kac.kac-corner, #kac.kac-corner.kac-side-left, #kac.kac-corner.kac-layer-prefs { inset: auto 10px calc(10px + env(safe-area-inset-bottom, 0px)) 10px; width: auto; max-width: none; }
  #kac.kac-corner .kac-dialog, #kac.kac-corner.kac-layer-prefs .kac-dialog { max-height: calc(100vh - 20px); max-height: calc(100dvh - 20px); }
  #kac.kac-corner .kac-body p { font-size: .84rem; }
  #kac.kac-corner .kac-scroll { padding: 18px 18px 12px; }
  #kac.kac-corner .kac-actions-prefs { grid-template-columns: 1fr; }
  .kac-chat-launch span { display: none; }
  .kac-chat-launch { padding: 0; width: 56px; justify-content: center; }
}
@media (max-height: 520px) and (min-width: 641px) {
  #kac .kac-scroll { padding: 20px 26px 16px; }
  #kac .kac-actions { margin: 14px 0 10px; }
}
@media (prefers-reduced-motion: reduce) {
  #kac .kac-dialog, #kac .kac-backdrop, .kac-float, #kac .kac-slider, #kac .kac-slider::after { transition: none !important; }
}
@media print { #kac, .kac-float, .kac-chat-launch, .kac-chat-card { display: none !important; } }
