/* Forestisland — Backend */
:root {
  --terra: #B4582F; --terra-deep: #8E3F1F; --terra-50: #FBEFE8;
  --cream: #FBF6EE; --sand: #F3E7D5; --sand-2: #E6D2B5;
  --green: #1F3A2B; --green-2: #2F5A43; --green-50: #E6EFE9;
  --pool: #2FA7A3; --marigold: #E2A23B; --red: #C0392B;
  --ink: #2A231F; --muted: #7A6B60; --line: #EADFCF; --bg: #F7F1E7;
  --r: 16px; --shadow: 0 1px 2px rgba(60, 30, 10, .06), 0 8px 24px -12px rgba(60, 30, 10, .18);
  --ease: cubic-bezier(.2, .8, .2, 1); --spring: cubic-bezier(.34, 1.56, .64, 1);
  --f-d: 'Bitter', Georgia, serif; --f: 'DM Sans', system-ui, sans-serif;
}
* { box-sizing: border-box; }
[hidden] { display: none !important; }
body { margin: 0; font: 400 15px/1.5 var(--f); color: var(--ink); background: var(--bg); -webkit-font-smoothing: antialiased; }
button { font: inherit; cursor: pointer; }
input, select, textarea { font: inherit; color: inherit; }
a { color: var(--terra); }
h1, h2, h3 { font-family: var(--f-d); color: var(--green); letter-spacing: -.02em; }
:focus-visible { outline: 3px solid var(--marigold); outline-offset: 2px; }

/* ---------- Buttons ---------- */
.b { display: inline-flex; align-items: center; justify-content: center; gap: 8px; padding: 10px 16px; border-radius: 12px; border: 1px solid var(--line); background: #fff; color: var(--green); font-weight: 700; font-size: 14px; text-decoration: none; transition: transform .2s var(--spring), background .2s, border-color .2s, box-shadow .2s; white-space: nowrap; }
.b:hover { border-color: var(--sand-2); background: var(--cream); }
.b:active { transform: scale(.97); }
.b--terra { background: var(--terra); border-color: var(--terra); color: #fff; box-shadow: 0 6px 16px -8px rgba(180, 88, 47, .8); }
.b--terra:hover { background: var(--terra-deep); border-color: var(--terra-deep); }
.b--green { background: var(--green); border-color: var(--green); color: #fff; }
.b--green:hover { background: var(--green-2); }
.b--ghost { background: transparent; border-color: transparent; }
.b--ghost:hover { background: rgba(0, 0, 0, .04); }
.b--danger { color: var(--red); }
.b--danger:hover { background: #FCEDEA; border-color: #F2C4BD; }
.b--sm { padding: 6px 11px; font-size: 13px; border-radius: 10px; }
.b--block { width: 100%; }
.b[disabled] { opacity: .5; pointer-events: none; }
.icon-b { width: 34px; height: 34px; border-radius: 10px; border: 1px solid var(--line); background: #fff; display: inline-grid; place-items: center; font-size: 15px; transition: background .2s, transform .2s var(--spring); }
.icon-b:hover { background: var(--cream); }
.icon-b.is-on { background: var(--marigold); border-color: var(--marigold); }

/* ---------- Login ---------- */
.login { min-height: 100vh; display: grid; place-items: center; padding: 20px; background: radial-gradient(ellipse at top, #F6E4CF, var(--bg)); }
.login__card { width: min(420px, 100%); background: #fff; border-radius: 24px; padding: 36px; box-shadow: 0 30px 80px -30px rgba(90, 40, 10, .4); display: flex; flex-direction: column; gap: 12px; animation: up .6s var(--spring); }
.login__logo { width: 180px; margin: 0 auto 8px; }
.login h1 { font-size: 24px; margin: 0; text-align: center; }
.login p { margin: 0 0 8px; color: var(--muted); text-align: center; }
.login__err { color: var(--red) !important; background: #FCEDEA; padding: 8px 12px; border-radius: 10px; }
.login__back { margin-top: 2px; }
@keyframes up { from { opacity: 0; transform: translateY(20px) scale(.98); } }

/* ---------- Formularfelder ---------- */
label, .lbl { display: block; font-weight: 700; font-size: 13px; color: var(--green); }
.help { display: block; font-weight: 400; color: var(--muted); font-size: 12.5px; margin-top: 2px; }
input[type=text], input[type=email], input[type=password], input[type=url], input[type=tel], input[type=number], input:not([type]), select, textarea {
  display: block; width: 100%; margin-top: 6px; padding: 10px 12px; border-radius: 10px; border: 1.5px solid var(--line); background: #fff; font-size: 14.5px; font-weight: 400; transition: border-color .2s, box-shadow .2s;
}
textarea { resize: vertical; min-height: 84px; line-height: 1.55; }
input:focus, select:focus, textarea:focus { outline: none; border-color: var(--terra); box-shadow: 0 0 0 4px rgba(180, 88, 47, .12); }
.field { margin-bottom: 16px; }
.counter { float: right; font-weight: 400; color: var(--muted); font-size: 12px; }
.counter.is-over { color: var(--red); }
.row2 { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.row3 { display: grid; grid-template-columns: 1fr 1fr 1fr; gap: 14px; }

.switch { display: flex; align-items: center; justify-content: space-between; gap: 14px; padding: 14px 16px; border: 1px solid var(--line); border-radius: 14px; background: #fff; cursor: pointer; transition: border-color .2s, background .2s; }
.switch:hover { border-color: var(--sand-2); }
.switch strong { display: block; color: var(--green); font-size: 14.5px; }
.switch span.help { margin: 0; }
.switch input { display: none; }
.switch i { flex: none; position: relative; width: 46px; height: 26px; border-radius: 99px; background: #DCCFBD; transition: background .25s; }
.switch i::after { content: ''; position: absolute; top: 3px; left: 3px; width: 20px; height: 20px; border-radius: 50%; background: #fff; box-shadow: 0 2px 4px rgba(0, 0, 0, .2); transition: transform .3s var(--spring); }
.switch input:checked + i { background: var(--pool); }
.switch input:checked + i::after { transform: translateX(20px); }
.switch:has(input:checked) { border-color: rgba(47, 167, 163, .4); background: #F3FBFA; }

/* ---------- App-Rahmen ---------- */
.app { display: grid; grid-template-columns: 250px 1fr; min-height: 100vh; }
.side { position: sticky; top: 0; height: 100vh; background: var(--green); color: #fff; display: flex; flex-direction: column; padding: 22px 14px; z-index: 20; }
.side__logo img { width: 150px; margin: 4px 10px 26px; }
.side__nav { display: flex; flex-direction: column; gap: 2px; overflow: auto; }
.side__nav a { display: flex; align-items: center; gap: 12px; padding: 10px 12px; border-radius: 12px; color: rgba(255, 255, 255, .78); text-decoration: none; font-weight: 500; transition: background .2s, color .2s, transform .2s var(--spring); }
.side__nav a i { font-style: normal; width: 22px; text-align: center; }
.side__nav a:hover { background: rgba(255, 255, 255, .07); color: #fff; }
.side__nav a.is-active { background: rgba(255, 255, 255, .13); color: #fff; font-weight: 700; box-shadow: inset 3px 0 0 var(--marigold); }
.side__group { margin: 18px 12px 6px; font-size: 11px; letter-spacing: .18em; text-transform: uppercase; color: rgba(255, 255, 255, .45); font-weight: 700; }
.pill { margin-left: auto; min-width: 22px; height: 22px; padding: 0 7px; border-radius: 99px; background: var(--terra); color: #fff; font-size: 12px; font-weight: 700; display: grid; place-items: center; animation: pop .5s var(--spring); }
@keyframes pop { from { transform: scale(0); } }
.side__foot { margin-top: auto; display: flex; flex-direction: column; gap: 6px; padding: 14px 6px 0; border-top: 1px solid rgba(255, 255, 255, .12); }
.side__site { color: var(--marigold); text-decoration: none; font-weight: 700; padding: 6px; }
.side__logout { background: none; border: 0; color: rgba(255, 255, 255, .6); text-align: left; padding: 6px; }
.side__logout:hover { color: #fff; }

.main { min-width: 0; }
.top { position: sticky; top: 0; z-index: 10; display: flex; align-items: center; gap: 14px; padding: 14px 32px; background: rgba(247, 241, 231, .85); backdrop-filter: blur(12px); border-bottom: 1px solid var(--line); min-height: 66px; }
.top__burger { display: none; border: 0; background: none; font-size: 22px; }
.top__crumbs { font-size: 14px; color: var(--muted); display: flex; gap: 8px; align-items: center; min-width: 0; }
.top__crumbs a { color: var(--muted); text-decoration: none; }
.top__crumbs a:hover { color: var(--terra); }
.top__crumbs b { color: var(--green); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.top__actions { margin-left: auto; display: flex; gap: 8px; align-items: center; }
.dirty-dot { display: inline-flex; align-items: center; gap: 6px; font-size: 13px; color: var(--terra); font-weight: 700; }
.dirty-dot::before { content: ''; width: 8px; height: 8px; border-radius: 50%; background: var(--terra); animation: blink 1.4s infinite; }
@keyframes blink { 50% { opacity: .3; } }
.view { padding: 28px 32px 80px; max-width: 1320px; animation: fade .35s var(--ease); }
@keyframes fade { from { opacity: 0; transform: translateY(8px); } }

.vh { display: flex; align-items: flex-end; justify-content: space-between; gap: 16px; margin-bottom: 22px; flex-wrap: wrap; }
.vh h1 { margin: 0; font-size: 30px; }
.vh p { margin: 4px 0 0; color: var(--muted); }
.card { background: #fff; border: 1px solid var(--line); border-radius: var(--r); box-shadow: var(--shadow); }
.card--pad { padding: 22px; }
.card h2 { font-size: 19px; margin: 0 0 4px; }
.card > .help { margin-bottom: 16px; }
.empty-state { text-align: center; padding: 50px 20px; color: var(--muted); }
.empty-state b { display: block; font-size: 40px; margin-bottom: 8px; }
.muted { color: var(--muted); }
.tag { display: inline-flex; align-items: center; gap: 4px; padding: 3px 9px; border-radius: 99px; font-size: 12px; font-weight: 700; background: var(--sand); color: var(--green); }
.tag--live { background: #DDF2EC; color: #1d6a57; }
.tag--draft { background: #EFE7DC; color: var(--muted); }
.tag--case { background: #FBEBC8; color: #7a5413; }
.tag--home { background: var(--terra-50); color: var(--terra-deep); }

/* ---------- Dashboard ---------- */
.hello { display: flex; justify-content: space-between; align-items: center; gap: 20px; padding: 28px; border-radius: 22px; margin-bottom: 22px; color: #fff; overflow: hidden; position: relative;
  background: radial-gradient(circle at 90% 10%, rgba(226, 162, 59, .5), transparent 40%), linear-gradient(120deg, var(--terra), #C87549); }
.hello h1 { color: #fff; margin: 0 0 6px; font-size: 30px; }
.hello p { margin: 0; opacity: .9; }
.hello img { width: 110px; opacity: .25; filter: brightness(10); position: absolute; right: 30px; bottom: -14px; }
.kpis { display: grid; grid-template-columns: repeat(4, 1fr); gap: 14px; margin-bottom: 22px; }
.kpi { padding: 18px 20px; text-decoration: none; color: inherit; transition: transform .25s var(--spring), box-shadow .25s; }
.kpi:hover { transform: translateY(-3px); }
.kpi span { color: var(--muted); font-size: 13px; }
.kpi strong { display: block; font: 800 34px/1.1 var(--f-d); color: var(--green); }
.kpi--hot strong { color: var(--terra); }
.dash { display: grid; grid-template-columns: 1.4fr 1fr; gap: 18px; }
.quick { display: grid; gap: 10px; }
.quick a { display: flex; align-items: center; gap: 14px; padding: 14px; border-radius: 14px; border: 1px solid var(--line); text-decoration: none; color: var(--green); font-weight: 700; transition: background .2s, transform .25s var(--spring); }
.quick a:hover { background: var(--cream); transform: translateX(4px); }
.quick a i { font-style: normal; width: 40px; height: 40px; border-radius: 12px; background: var(--sand); display: grid; place-items: center; font-size: 19px; }
.quick a small { display: block; font-weight: 400; color: var(--muted); }

/* ---------- Listen ---------- */
.list-row { display: flex; align-items: center; gap: 14px; padding: 12px 14px; border-bottom: 1px solid var(--line); text-decoration: none; color: inherit; transition: background .15s; }
.list-row:last-child { border-bottom: 0; }
.list-row:hover { background: #FDFAF5; }
.av { flex: none; width: 40px; height: 40px; border-radius: 12px; display: grid; place-items: center; font-weight: 700; color: #fff; background: var(--terra); font-size: 14px; }
.list-row .grow { flex: 1; min-width: 0; }
.list-row .grow b { display: block; color: var(--green); }
.list-row .grow span { display: block; color: var(--muted); font-size: 13px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }

/* ---------- Anfragen (CRM) ---------- */
.crm { display: grid; grid-template-columns: 380px 1fr; gap: 18px; align-items: start; }
.crm__list { overflow: hidden; position: sticky; top: 90px; max-height: calc(100vh - 110px); display: flex; flex-direction: column; }
.crm__tools { padding: 12px; border-bottom: 1px solid var(--line); display: flex; flex-direction: column; gap: 10px; }
.crm__tools input { margin: 0; }
.seg { display: flex; flex-wrap: wrap; gap: 4px; }
.seg button { border: 1px solid var(--line); background: #fff; padding: 5px 10px; border-radius: 99px; font-size: 12.5px; font-weight: 700; color: var(--muted); transition: all .2s; }
.seg button.is-on { background: var(--green); border-color: var(--green); color: #fff; }
.crm__items { overflow: auto; }
.inq { display: block; padding: 14px 16px; border-bottom: 1px solid var(--line); text-decoration: none; color: inherit; position: relative; transition: background .15s; }
.inq:hover { background: #FDFAF5; }
.inq.is-active { background: var(--terra-50); box-shadow: inset 3px 0 0 var(--terra); }
.inq__top { display: flex; justify-content: space-between; gap: 10px; }
.inq b { color: var(--green); }
.inq time { font-size: 12px; color: var(--muted); white-space: nowrap; }
.inq p { margin: 4px 0 6px; font-size: 13px; color: var(--muted); display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.inq.is-new b::before { content: ''; display: inline-block; width: 8px; height: 8px; border-radius: 50%; background: var(--terra); margin-right: 6px; vertical-align: middle; }
.st { display: inline-block; font-size: 11.5px; font-weight: 700; padding: 3px 9px; border-radius: 99px; }
.st--neu { background: var(--terra-50); color: var(--terra-deep); }
.st--kontakt { background: #E6F0FA; color: #2a5d8f; }
.st--angebot { background: #FBEBC8; color: #7a5413; }
.st--gewonnen { background: #DDF2EC; color: #1d6a57; }
.st--verloren { background: #F1E6E4; color: #8a4a40; }
.st--archiv { background: #EEE; color: #777; }
.crm__detail { padding: 26px; min-height: 400px; }
.crm__head { display: flex; justify-content: space-between; gap: 16px; align-items: flex-start; flex-wrap: wrap; }
.crm__head h2 { font-size: 26px; margin: 0; }
.contact-btns { display: flex; gap: 8px; flex-wrap: wrap; margin: 14px 0 20px; }
.stepper { display: flex; gap: 0; margin: 6px 0 24px; border: 1px solid var(--line); border-radius: 14px; overflow: hidden; flex-wrap: wrap; }
.stepper button { flex: 1; border: 0; border-right: 1px solid var(--line); background: #fff; padding: 11px 8px; font-size: 13px; font-weight: 700; color: var(--muted); transition: background .2s, color .2s; min-width: 90px; }
.stepper button:last-child { border-right: 0; }
.stepper button:hover { background: var(--cream); }
.stepper button.is-on { background: var(--green); color: #fff; }
.stepper button.is-on[data-st=gewonnen] { background: #1d8a6f; }
.stepper button.is-on[data-st=verloren] { background: #8a4a40; }
.msg { background: var(--cream); border: 1px solid var(--line); border-radius: 14px; padding: 18px; white-space: pre-wrap; margin-bottom: 18px; }
.facts-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(170px, 1fr)); gap: 10px; margin-bottom: 20px; }
.facts-grid div { background: #FDFAF5; border: 1px solid var(--line); border-radius: 12px; padding: 10px 12px; }
.facts-grid span { display: block; font-size: 12px; color: var(--muted); }
.facts-grid b { color: var(--green); word-break: break-word; }
.timeline { list-style: none; padding: 0; margin: 14px 0 0; border-left: 2px solid var(--line); }
.timeline li { position: relative; padding: 0 0 14px 18px; }
.timeline li::before { content: ''; position: absolute; left: -6px; top: 5px; width: 10px; height: 10px; border-radius: 50%; background: var(--sand-2); }
.timeline li.note::before { background: var(--terra); }
.timeline time { font-size: 12px; color: var(--muted); display: block; }
.timeline p { margin: 2px 0 0; white-space: pre-wrap; }

/* ---------- Projekte ---------- */
.plist { display: flex; flex-direction: column; }
.prow { display: grid; grid-template-columns: 24px 88px 1fr auto; align-items: center; gap: 14px; padding: 12px 16px; border-bottom: 1px solid var(--line); background: #fff; transition: background .15s, box-shadow .2s; }
.prow:last-child { border-bottom: 0; }
.prow:hover { background: #FDFAF5; }
.prow.is-drag { opacity: .4; }
.prow.is-over { box-shadow: inset 0 3px 0 var(--terra); }
.handle { cursor: grab; color: var(--sand-2); font-size: 18px; user-select: none; text-align: center; }
.handle:hover { color: var(--terra); }
.pthumb { width: 88px; height: 58px; border-radius: 10px; object-fit: cover; background: linear-gradient(140deg, #D98B63, var(--terra)); display: grid; place-items: center; color: #fff; font: 800 12px var(--f-d); text-align: center; padding: 4px; overflow: hidden; }
.prow__main { min-width: 0; text-decoration: none; color: inherit; }
.prow__main b { font-size: 16px; color: var(--green); }
.prow__main .tags { display: flex; gap: 5px; flex-wrap: wrap; margin-top: 5px; }
.prow__acts { display: flex; gap: 6px; align-items: center; }

/* Projekt-Editor */
.editor { display: grid; grid-template-columns: 210px 1fr; gap: 26px; align-items: start; }
.toc { position: sticky; top: 92px; display: flex; flex-direction: column; gap: 2px; }
.toc a { display: flex; align-items: center; gap: 10px; padding: 9px 12px; border-radius: 10px; text-decoration: none; color: var(--muted); font-weight: 500; font-size: 14px; transition: background .2s, color .2s; }
.toc a b { width: 24px; height: 24px; border-radius: 50%; background: #fff; border: 1px solid var(--line); display: grid; place-items: center; font-size: 12px; color: var(--green); flex: none; transition: all .25s; }
.toc a:hover { background: #fff; color: var(--green); }
.toc a.is-done b { background: var(--pool); border-color: var(--pool); color: #fff; }
.toc a.is-cur { color: var(--green); font-weight: 700; background: #fff; }
.step { scroll-margin-top: 90px; margin-bottom: 20px; padding: 26px; }
.step__h { display: flex; gap: 14px; align-items: flex-start; margin-bottom: 18px; }
.step__h > b { flex: none; width: 34px; height: 34px; border-radius: 50%; background: var(--terra); color: #fff; display: grid; place-items: center; font-weight: 700; }
.step__h h2 { margin: 0; font-size: 20px; }
.step__h p { margin: 2px 0 0; color: var(--muted); }
.typecards { display: grid; grid-template-columns: repeat(4, 1fr); gap: 12px; }
.typecard { position: relative; border: 2px solid var(--line); border-radius: 16px; padding: 18px 14px; text-align: center; background: #fff; cursor: pointer; transition: border-color .2s, transform .25s var(--spring), background .2s; }
.typecard:hover { transform: translateY(-3px); border-color: var(--sand-2); }
.typecard input { position: absolute; opacity: 0; }
.typecard i { display: block; font-style: normal; font-size: 32px; margin-bottom: 6px; transition: transform .35s var(--spring); }
.typecard b { color: var(--green); }
.typecard:has(input:checked) { border-color: var(--terra); background: var(--terra-50); }
.typecard:has(input:checked) i { transform: scale(1.15) rotate(-6deg); }
.typecard:has(input:checked)::after { content: '✓'; position: absolute; top: 8px; right: 10px; width: 22px; height: 22px; border-radius: 50%; background: var(--terra); color: #fff; font-size: 12px; display: grid; place-items: center; }
.sugg { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 8px; }
.sugg button { border: 1px dashed var(--sand-2); background: #fff; border-radius: 99px; padding: 4px 10px; font-size: 12.5px; color: var(--muted); transition: all .2s; }
.sugg button:hover { border-color: var(--terra); color: var(--terra); }
.taginput { display: flex; flex-wrap: wrap; gap: 6px; padding: 7px; margin-top: 6px; border: 1.5px solid var(--line); border-radius: 10px; background: #fff; }
.taginput:focus-within { border-color: var(--terra); box-shadow: 0 0 0 4px rgba(180, 88, 47, .12); }
.taginput span { display: inline-flex; align-items: center; gap: 4px; background: var(--sand); color: var(--green); border-radius: 99px; padding: 4px 6px 4px 10px; font-size: 13px; font-weight: 700; }
.taginput span button { border: 0; background: rgba(0, 0, 0, .08); width: 18px; height: 18px; border-radius: 50%; font-size: 12px; line-height: 1; padding: 0; }
.taginput input { border: 0 !important; box-shadow: none !important; margin: 0 !important; padding: 4px !important; flex: 1; min-width: 120px; }
.q { background: #FDFAF5; border: 1px solid var(--line); border-radius: 14px; padding: 16px; margin-bottom: 14px; }
.q label { font-size: 14.5px; }
.q .help { margin-bottom: 4px; }

/* Bild-/Medienfelder */
.imgfield { display: flex; gap: 14px; align-items: center; margin-top: 6px; padding: 10px; border: 1.5px dashed var(--sand-2); border-radius: 14px; background: #FDFAF5; transition: border-color .2s, background .2s; }
.imgfield.is-drop { border-color: var(--terra); background: var(--terra-50); }
.imgfield__prev { width: 130px; height: 88px; border-radius: 10px; object-fit: cover; background: var(--sand); display: grid; place-items: center; color: var(--muted); font-size: 12px; flex: none; text-align: center; }
.imgfield--lg .imgfield__prev { width: 260px; height: 160px; }
.imgfield__acts { display: flex; flex-direction: column; gap: 6px; align-items: flex-start; }
.imgfield__acts small { color: var(--muted); font-size: 12px; font-weight: 400; }
.gal { display: grid; grid-template-columns: repeat(auto-fill, minmax(120px, 1fr)); gap: 10px; margin-top: 8px; }
.gal__item { position: relative; aspect-ratio: 4 / 3; border-radius: 12px; overflow: hidden; background: var(--sand); cursor: grab; }
.gal__item img { width: 100%; height: 100%; object-fit: cover; }
.gal__item button { position: absolute; top: 6px; right: 6px; width: 26px; height: 26px; border-radius: 50%; border: 0; background: rgba(0, 0, 0, .55); color: #fff; opacity: 0; transition: opacity .2s; }
.gal__item:hover button { opacity: 1; }
.gal__item.is-over { outline: 3px solid var(--terra); }
.gal__add { aspect-ratio: 4 / 3; border-radius: 12px; border: 2px dashed var(--sand-2); background: #FDFAF5; display: grid; place-items: center; text-align: center; color: var(--muted); font-size: 13px; font-weight: 700; padding: 8px; transition: all .2s; }
.gal__add:hover, .gal__add.is-drop { border-color: var(--terra); color: var(--terra); background: var(--terra-50); }

/* Linien-Icons */
.si { width: 1.15em; height: 1.15em; fill: none; stroke: currentColor; stroke-width: 1.7; stroke-linecap: round; stroke-linejoin: round; flex: none; vertical-align: -.2em; }
.side__nav a i .si { width: 19px; height: 19px; display: block; margin: 0 auto; }
.empty-state b .si { width: 42px; height: 42px; color: var(--terra); stroke-width: 1.4; margin: 0 auto; display: block; }
.quick a i .si { width: 20px; height: 20px; color: var(--terra); }
.typecard i .si { width: 34px; height: 34px; color: var(--terra); stroke-width: 1.5; margin: 0 auto; display: block; }
.mitem .thumb .si { width: 38px; height: 38px; color: var(--muted); stroke-width: 1.4; }
.card h2 .si { color: var(--terra); }
.icon-b .si { width: 16px; height: 16px; }

/* Icon-Auswahl */
.iconpick { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 6px; }
.iconpick button { width: 40px; height: 40px; border-radius: 10px; border: 1.5px solid var(--line); background: #fff; display: grid; place-items: center; color: var(--green); transition: all .2s; }
.iconpick button:hover { border-color: var(--terra); color: var(--terra); }
.iconpick button.is-on { background: var(--terra); border-color: var(--terra); color: #fff; }
.iconpick svg { width: 20px; height: 20px; fill: none; stroke: currentColor; stroke-width: 1.6; stroke-linecap: round; stroke-linejoin: round; }

/* Liste-Feld (Repeater) */
.rep { display: flex; flex-direction: column; gap: 10px; margin-top: 8px; }
.rep__item { border: 1px solid var(--line); border-radius: 14px; background: #FDFAF5; }
.rep__head { display: flex; align-items: center; gap: 8px; padding: 10px 12px; cursor: pointer; }
.rep__head b { flex: 1; color: var(--green); font-size: 14px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.rep__head .chev { transition: transform .25s; color: var(--muted); }
.rep__item.is-open .chev { transform: rotate(90deg); }
.rep__body { padding: 4px 14px 14px; display: none; }
.rep__item.is-open .rep__body { display: block; }

/* Projekt-Auswahl (Startseite) */
.ppick { display: grid; grid-template-columns: repeat(auto-fill, minmax(170px, 1fr)); gap: 12px; margin-top: 8px; }
.ppick button { position: relative; border: 2px solid var(--line); border-radius: 14px; background: #fff; padding: 8px; text-align: left; transition: border-color .2s, transform .25s var(--spring); }
.ppick button:hover { transform: translateY(-2px); }
.ppick .pthumb { width: 100%; height: 90px; margin-bottom: 8px; }
.ppick b { display: block; font-size: 14px; color: var(--green); padding: 0 4px 4px; }
.ppick button.is-on { border-color: var(--terra); background: var(--terra-50); }
.ppick button i { position: absolute; top: 14px; left: 14px; width: 30px; height: 30px; border-radius: 50%; background: var(--terra); color: #fff; font-style: normal; font-weight: 800; display: grid; place-items: center; box-shadow: 0 4px 10px rgba(0, 0, 0, .25); animation: pop .4s var(--spring); }
.ppick button.is-draft { opacity: .6; }

/* Seiten */
.pages-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 14px; }
.pagecard { display: block; padding: 20px; text-decoration: none; color: inherit; transition: transform .25s var(--spring), border-color .2s; }
.pagecard:hover { transform: translateY(-3px); border-color: var(--sand-2); }
.pagecard b { font: 800 19px var(--f-d); color: var(--green); display: block; }
.pagecard code { font-size: 12.5px; color: var(--muted); }
.pagecard small { display: block; margin-top: 10px; color: var(--muted); }
.group-h { font-size: 12px; letter-spacing: .18em; text-transform: uppercase; color: var(--muted); margin: 24px 0 10px; font-family: var(--f); }
.sec { margin-bottom: 16px; scroll-margin-top: 90px; }
.sec__h { display: flex; align-items: center; gap: 10px; padding: 16px 20px; cursor: pointer; user-select: none; }
.sec__h h2 { flex: 1; margin: 0; font-size: 17px; }
.sec__h .chev { transition: transform .25s; color: var(--muted); }
.sec.is-open .sec__h .chev { transform: rotate(90deg); }
.sec__b { padding: 0 20px 18px; display: none; }
.sec.is-open .sec__b { display: block; }
.sec__b > .help { margin: -4px 0 14px; background: var(--cream); padding: 10px 12px; border-radius: 10px; }

/* Sichtbarkeit von Abschnitten */
.vis { display: inline-flex; align-items: center; gap: 8px; font-size: 12.5px; font-weight: 700; color: var(--green); cursor: pointer; padding: 4px 4px 4px 10px; border-radius: 99px; }
.vis input { display: none; }
.vis i { position: relative; width: 38px; height: 22px; border-radius: 99px; background: #DCCFBD; transition: background .25s; flex: none; }
.vis i::after { content: ''; position: absolute; top: 3px; left: 3px; width: 16px; height: 16px; border-radius: 50%; background: #fff; box-shadow: 0 1px 3px rgba(0, 0, 0, .25); transition: transform .3s var(--spring); }
.vis input:checked + i { background: var(--pool); }
.vis input:checked + i::after { transform: translateX(16px); }
.vis span { min-width: 52px; }
.sec__off { display: none; font-size: 11.5px; font-weight: 700; color: var(--muted); background: #EFE7DC; border-radius: 99px; padding: 3px 9px; }
.sec.is-off { background: #FAF6F0; border-style: dashed; }
.sec.is-off .sec__h h2 { color: var(--muted); }
.sec.is-off .sec__off { display: inline-block; }
.toc a.is-off { opacity: .45; text-decoration: line-through; }

/* Google-Vorschau */
.serp { margin-top: 6px; }
.serp__box { margin-top: 6px; padding: 14px 16px; border-radius: 12px; background: #fff; border: 1px solid var(--line); font-family: Arial, sans-serif; }
.serp__url { font-size: 12.5px; color: #4d5156; }
.serp__title { font-size: 19px; color: #1a0dab; margin: 3px 0; line-height: 1.3; }
.serp__desc { font-size: 13.5px; color: #4d5156; line-height: 1.5; }
.serp__meter { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 8px; }
.serp__meter .m { font-size: 12px; font-weight: 700; padding: 3px 9px; border-radius: 99px; }
.m--ok { background: #DDF2EC; color: #1d6a57; }
.m--warn { background: #FBEBC8; color: #7a5413; }
.m--bad { background: #FCEDEA; color: var(--red); }

/* Sammlungen (Stimmen, FAQ, Logos) */
.coll { display: grid; gap: 12px; }
.coll--grid { grid-template-columns: repeat(auto-fill, minmax(320px, 1fr)); }
.citem { padding: 18px; position: relative; }
.citem__foot { display: flex; align-items: center; gap: 8px; margin-top: 10px; }
.citem__foot .saved { margin-right: auto; font-size: 12.5px; color: var(--muted); transition: color .2s; }
.citem__foot .saved.is-ok { color: #1d8a6f; }
.chk-row { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 6px; }
.chk { display: inline-flex; align-items: center; gap: 6px; padding: 6px 12px; border: 1px solid var(--line); border-radius: 99px; font-size: 13px; font-weight: 500; cursor: pointer; background: #fff; }
.chk:has(input:checked) { background: var(--green-50); border-color: var(--green-2); color: var(--green); font-weight: 700; }
.chk input { accent-color: var(--green); margin: 0; }

/* Mediathek */
.mtools { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; margin-bottom: 16px; }
.mtools input { margin: 0; max-width: 280px; }
.drop { border: 2px dashed var(--sand-2); border-radius: 18px; padding: 26px; text-align: center; color: var(--muted); background: #FDFAF5; margin-bottom: 18px; transition: all .2s; }
.drop b { color: var(--green); }
.drop.is-drop { border-color: var(--terra); background: var(--terra-50); transform: scale(1.01); }
.mgrid { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 12px; }
.mitem { position: relative; border: 2px solid transparent; border-radius: 14px; background: #fff; padding: 0; overflow: hidden; box-shadow: var(--shadow); text-align: left; transition: transform .2s var(--spring), border-color .2s; }
.mitem:hover { transform: translateY(-3px); }
.mitem.is-sel { border-color: var(--terra); }
.mitem.is-sel::after { content: '✓'; position: absolute; top: 8px; right: 8px; width: 26px; height: 26px; border-radius: 50%; background: var(--terra); color: #fff; display: grid; place-items: center; font-weight: 700; }
.mitem .thumb { aspect-ratio: 1; width: 100%; object-fit: cover; background: var(--sand); display: grid; place-items: center; font-size: 34px; }
.mitem span { display: block; padding: 7px 9px; font-size: 12px; color: var(--muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.mdetail { display: grid; grid-template-columns: 1.2fr 1fr; gap: 22px; }
.mdetail__prev { background: var(--sand); border-radius: 14px; display: grid; place-items: center; min-height: 260px; overflow: hidden; }
.mdetail__prev img, .mdetail__prev video { max-width: 100%; max-height: 60vh; }
.kv { font-size: 13px; color: var(--muted); margin: 0 0 14px; }
.kv b { color: var(--ink); font-weight: 500; }
.upl { position: fixed; right: 22px; bottom: 22px; z-index: 60; background: var(--green); color: #fff; padding: 14px 18px; border-radius: 14px; box-shadow: 0 20px 40px -20px rgba(0, 0, 0, .5); min-width: 240px; }
.upl__bar { height: 6px; border-radius: 6px; background: rgba(255, 255, 255, .2); margin-top: 8px; overflow: hidden; }
.upl__bar i { display: block; height: 100%; background: var(--marigold); transition: width .2s; }

/* Einstellungen */
.set-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; align-items: start; }
.codebox { font: 13px/1.6 ui-monospace, Menlo, monospace; background: var(--green); color: #E8F1EC; padding: 14px 16px; border-radius: 12px; overflow: auto; white-space: pre; margin: 8px 0 0; }
.keyrow { display: flex; gap: 8px; align-items: center; margin-top: 6px; }
.keyrow input { margin: 0; font-family: ui-monospace, Menlo, monospace; font-size: 13px; }

/* Dialog */
.dialog { position: fixed; inset: 0; z-index: 70; display: grid; place-items: center; padding: 20px; }
.dialog__bg { position: absolute; inset: 0; background: rgba(31, 22, 16, .5); backdrop-filter: blur(4px); animation: fadeIn .25s; }
.dialog__card { position: relative; width: min(560px, 100%); max-height: calc(100vh - 40px); overflow: auto; background: #fff; border-radius: 20px; padding: 26px; box-shadow: 0 40px 100px -30px rgba(0, 0, 0, .5); animation: up .4s var(--spring); }
.dialog__card.is-wide { width: min(1100px, 100%); }
.dialog__card h2 { margin: 0 0 6px; }
.dialog__acts { display: flex; justify-content: flex-end; gap: 8px; margin-top: 20px; position: sticky; bottom: -26px; background: #fff; padding: 12px 0 0; }
@keyframes fadeIn { from { opacity: 0; } }

.toasts { position: fixed; right: 22px; bottom: 22px; z-index: 90; display: flex; flex-direction: column; gap: 8px; align-items: flex-end; }
.toast { background: var(--green); color: #fff; padding: 12px 18px; border-radius: 12px; box-shadow: 0 16px 30px -14px rgba(0, 0, 0, .5); font-weight: 500; animation: toastIn .45s var(--spring); }
.toast--err { background: var(--red); }
.toast.is-out { opacity: 0; transform: translateY(10px); transition: all .3s; }
@keyframes toastIn { from { opacity: 0; transform: translateY(20px) scale(.95); } }

/* Responsiv */
@media (max-width: 1100px) {
  .crm { grid-template-columns: 1fr; }
  .crm__list { position: static; max-height: 420px; }
  .editor { grid-template-columns: 1fr; }
  .toc { display: none; }
  .dash, .set-grid, .mdetail { grid-template-columns: 1fr; }
}
@media (max-width: 860px) {
  .app { grid-template-columns: 1fr; }
  .side { position: fixed; left: 0; top: 0; width: 260px; transform: translateX(-100%); transition: transform .35s var(--ease); }
  .app.menu-open .side { transform: none; box-shadow: 20px 0 60px rgba(0, 0, 0, .3); }
  .top__burger { display: block; }
  .top, .view { padding-left: 16px; padding-right: 16px; }
  .kpis { grid-template-columns: 1fr 1fr; }
  .typecards { grid-template-columns: 1fr 1fr; }
  .row2, .row3 { grid-template-columns: 1fr; }
  .prow { grid-template-columns: 70px 1fr; }
  .prow .handle { display: none; }
  .prow__acts { grid-column: 1 / -1; }
  .imgfield--lg .imgfield__prev { width: 140px; height: 100px; }
}

/* Online/Offline-Status einer Seite */
.pagestate { display: flex; align-items: center; gap: 14px; margin-bottom: 18px; border-width: 2px; }
.pagestate .switch { flex: 1; border: 0; padding: 0; background: none !important; }
.pagestate.is-off { border-color: #E6D2B5; background: #FBF4EA; }
.pagestate.is-on { border-color: rgba(47, 167, 163, .45); }
.mitem em { position: absolute; left: 8px; top: 8px; font-style: normal; font-size: 11px; font-weight: 700; padding: 3px 8px; border-radius: 99px; }
.mitem em.noalt { background: #FCEDEA; color: var(--red); }
.mitem em.opt { top: auto; bottom: 36px; background: var(--green); color: #fff; }

/* E-Mail-Versand (Einstellungen) */
.check { display: flex; align-items: center; gap: 10px; font-size: 14px; font-weight: 600; margin: 4px 0 2px; cursor: pointer; }
.check input { width: 18px; height: 18px; accent-color: var(--terra); }
.mailstate { display: inline-flex; align-items: center; gap: 6px; font-size: 13px; font-weight: 700; padding: 6px 12px; border-radius: 999px; background: var(--sand); color: var(--muted); margin: 0 0 12px; }
.mailstate.is-ok { background: #E3F1E8; color: #1F6B45; }
.mailstate .si { width: 15px; height: 15px; }
.gal__noalt { position: absolute; left: 6px; bottom: 6px; font-size: 10px; font-weight: 700; padding: 2px 7px; border-radius: 999px; background: var(--terra); color: #fff; }
