/* ==========================================================================
   ilabs slides - Oberflaeche (Grundlage wie ilabs Write)
   ========================================================================== */
body.slides { --tb-top: 14px; }
.view { position: fixed; inset: 0; }
.view[hidden] { display: none; }

/* ---------- Start (Backstage) im core-Design ---------- */
.topbrand { position: fixed; z-index: 50; top: 18px; left: 26px; display: flex; align-items: baseline; gap: 16px; pointer-events: none; animation: fade-up .8s var(--smooth) both; }
.topclock { font: 500 15px var(--display); letter-spacing: .12em; color: var(--ink-soft); }
.home { --orb: min(54vh, 440px); --ox: 34vw; }
.home .hm-orb { position: absolute; left: calc(var(--ox) - var(--orb) / 2); top: calc(50% - var(--orb) / 2); width: var(--orb); height: var(--orb); }
.home .hm-orb .glyph { width: 30%; }
.hm-orb.intro { animation: hm-in 1.1s var(--spring) both; }
@keyframes hm-in { from { opacity: 0; transform: scale(.5) translateX(-80px); } }

.sc-wrap { --bs: clamp(140px, min(32vh, 26vw), 290px); position: relative; width: min(1180px, calc(100vw - 80px)); max-height: 100%; display: flex; align-items: center; gap: clamp(20px, 4vw, 46px); }
.sc-bub {
  position: relative; flex-shrink: 0; width: var(--bs); height: var(--bs); border-radius: 50%; display: flex; align-items: center; justify-content: center;
  background: radial-gradient(circle at 34% 28%, rgba(255,255,255,.92), rgba(207,230,255,.62) 40%, rgba(111,179,250,.48) 75%, rgba(42,122,224,.62));
  box-shadow: inset -12px -18px 34px rgba(13,52,120,.3), inset 10px 12px 24px rgba(255,255,255,.6), 0 30px 70px rgba(14,42,92,.32), 0 0 90px rgba(64,156,255,.4);
  transform: perspective(1400px) rotateY(12deg); color: var(--blue-700);
}
.sc-bub .orb-ring.r1 { animation: spin 18s linear infinite; }
.sc-bub .orb-ring.r2 { animation: spin 26s linear infinite reverse; }
.sc-bub > svg { width: 40%; height: 40%; filter: drop-shadow(0 6px 14px rgba(13,52,120,.3)); }
.sc-panel { flex: 1; min-width: 0; height: min(680px, calc(100vh - 190px)); display: flex; flex-direction: column; padding: clamp(16px, 2.4vh, 24px); border-radius: 30px; transform: perspective(1400px) rotateY(-11deg) rotateZ(-1deg); transform-origin: 30% 50%; }
.sc-head { display: flex; align-items: center; gap: 14px; padding: 4px 6px 16px; flex-wrap: wrap; }
.sc-head h2 { margin: 0; font: 700 clamp(24px, 4vh, 36px) var(--display); letter-spacing: .03em; }
.sc-head .grow { flex: 1; }
.sc-body { flex: 1; min-height: 0; overflow: auto; padding: 4px 6px 10px; margin: 0 -6px; }

/* Vorlagen */
.tpl-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 18px; }
.tpl { position: relative; border: none; background: none; padding: 0; cursor: pointer; text-align: left; color: var(--ink); animation: card-pop .6s var(--spring) both; }
.tpl:nth-child(2) { animation-delay: .05s; } .tpl:nth-child(3) { animation-delay: .1s; } .tpl:nth-child(4) { animation-delay: .15s; }
.tpl:nth-child(5) { animation-delay: .2s; } .tpl:nth-child(6) { animation-delay: .25s; } .tpl:nth-child(7) { animation-delay: .3s; } .tpl:nth-child(8) { animation-delay: .35s; }
@keyframes card-pop { from { opacity: 0; transform: translateY(24px) scale(.92); } }
.tpl .paper { position: relative; aspect-ratio: 210 / 297; border-radius: 10px; background: #fff; overflow: hidden;
  box-shadow: 0 1px 0 rgba(255,255,255,.9) inset, 0 14px 30px -14px rgba(14,42,92,.45), 0 0 0 1px rgba(140,196,255,.35);
  transition: transform .45s var(--spring), box-shadow .3s; }
.tpl.land .paper { aspect-ratio: 297 / 210; }
.tpl:hover .paper { transform: translateY(-6px) rotate(-1deg); box-shadow: 0 24px 40px -16px rgba(14,42,92,.5), 0 0 0 2px rgba(64,156,255,.55), 0 0 30px rgba(64,156,255,.25); }
.tpl .paper .mini { position: absolute; left: 0; top: 0; transform-origin: 0 0; pointer-events: none; }
.tpl b { display: block; margin: 10px 4px 0; font: 600 14px var(--display); letter-spacing: .06em; text-transform: uppercase; }
.tpl small { display: block; margin: 2px 4px 0; font-size: 12px; color: var(--ink-soft); }
.tpl .plus { position: absolute; inset: 0; display: flex; align-items: center; justify-content: center; color: var(--blue-500); }
.tpl .plus svg { width: 42px; height: 42px; transition: transform .45s var(--spring); }
.tpl:hover .plus svg { transform: rotate(90deg) scale(1.1); }

.seg { position: relative; display: inline-flex; padding: 4px; border-radius: 999px; background: rgba(255,255,255,.55); box-shadow: inset 0 2px 5px rgba(22,52,104,.12); }
.seg button { position: relative; z-index: 1; border: none; background: none; cursor: pointer; padding: 8px 14px; border-radius: 999px; font: 600 13px var(--display); letter-spacing: .04em; color: var(--ink-soft); transition: color .3s; white-space: nowrap; }
.seg button.on { color: #fff; }
.seg .seg-pill { position: absolute; top: 4px; bottom: 4px; left: 0; border-radius: 999px; background: linear-gradient(180deg, #5eadf8, #2f80e4 55%, #1f66cc);
  box-shadow: inset 0 1.5px 0 rgba(255,255,255,.55), 0 6px 16px -4px rgba(31,102,204,.6), 0 0 18px rgba(64,156,255,.35); transition: transform .5s var(--spring), width .5s var(--spring); }

/* Zuletzt */
.recent-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(170px, 1fr)); gap: 20px; }
.rc { position: relative; border: none; background: none; padding: 0; cursor: pointer; text-align: left; color: var(--ink); animation: card-pop .6s var(--spring) both; }
.rc .paper { position: relative; aspect-ratio: 210 / 297; border-radius: 10px; background: #fff; overflow: hidden;
  box-shadow: 0 14px 30px -14px rgba(14,42,92,.45), 0 0 0 1px rgba(140,196,255,.35); transition: transform .45s var(--spring), box-shadow .3s; }
.rc:hover .paper { transform: translateY(-6px); box-shadow: 0 24px 40px -16px rgba(14,42,92,.5), 0 0 0 2px rgba(64,156,255,.55); }
.rc .paper .mini { position: absolute; left: 0; top: 0; transform-origin: 0 0; pointer-events: none; }
.rc b { display: block; margin: 10px 4px 0; font: 600 14px var(--display); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.rc small { display: block; margin: 2px 4px 0; font-size: 12px; color: var(--ink-soft); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.rc .fmt { position: absolute; right: 8px; bottom: 8px; padding: 3px 8px; border-radius: 99px; font: 700 10px var(--display); letter-spacing: .08em; color: #fff; background: linear-gradient(180deg, #5eadf8, #1f66cc); box-shadow: 0 4px 10px rgba(31,102,204,.4); }
.rc .rm { position: absolute; right: 6px; top: 6px; width: 28px; height: 28px; border-radius: 50%; border: none; cursor: pointer; display: flex; align-items: center; justify-content: center; color: var(--ink-soft);
  background: rgba(255,255,255,.92); box-shadow: 0 3px 10px rgba(14,42,92,.2); opacity: 0; transform: scale(.6); transition: opacity .2s, transform .35s var(--spring); }
.rc .rm svg { width: 13px; height: 13px; }
.rc:hover .rm { opacity: 1; transform: none; }
.rc .rm:hover { color: var(--red); }
.empty { text-align: center; padding: 60px 20px; color: var(--ink-soft); animation: fade-up .7s var(--smooth) both; }
.empty .mini-orb { width: 84px; height: 84px; margin: 0 auto 18px; color: #fff; }
.empty .mini-orb svg { width: 34px; height: 34px; }
.empty h3 { margin: 0 0 6px; font: 700 19px var(--display); color: var(--ink); }
.search { display: flex; align-items: center; gap: 8px; height: 44px; padding: 0 16px; border-radius: 999px; background: rgba(255,255,255,.72); box-shadow: inset 0 2px 5px rgba(22,52,104,.1); min-width: 240px; color: var(--ink-faint); }
.search svg { width: 18px; height: 18px; }
.search input { flex: 1; min-width: 0; border: none; outline: none; background: none; font-size: 14.5px; color: var(--ink); }

.drop-hint { position: fixed; inset: 14px; z-index: 6000; border-radius: 30px; display: flex; align-items: center; justify-content: center; flex-direction: column; gap: 14px; pointer-events: none;
  background: rgba(220,236,255,.72); box-shadow: inset 0 0 0 3px rgba(64,156,255,.6), inset 0 0 60px rgba(64,156,255,.35); opacity: 0; transform: scale(1.02); transition: opacity .25s, transform .4s var(--spring);
  font: 600 20px var(--display); letter-spacing: .06em; color: var(--blue-700); }
.drop-hint.on { opacity: 1; transform: none; }
.drop-hint .mini-orb { width: 90px; height: 90px; animation: float-orb 2.4s ease-in-out infinite; }
.drop-hint .mini-orb svg { width: 36px; height: 36px; }
@keyframes float-orb { 50% { transform: translateY(-10px); } }

/* ==========================================================================
   Editor
   ========================================================================== */
#editor { background: linear-gradient(170deg, #eef5ff 0%, #dce9fb 60%, #cfe0f8 100%); }
#editor .bg i { opacity: .7; }

/* Marke + Dokumentname oben links */
.ed-brand { position: fixed; z-index: 120; top: 12px; left: 14px; display: flex; align-items: center; gap: 12px; }
.ed-orb { width: 46px; height: 46px; border: none; padding: 0; cursor: pointer; transition: transform .45s var(--spring); }
.ed-orb .glyph { width: 46%; }
.ed-orb:hover { transform: scale(1.08) rotate(-6deg); }
.ed-orb:active { transform: scale(.94); }
.ed-name { display: flex; flex-direction: column; min-width: 0; }
.ed-name .app { font: 700 15px var(--display); letter-spacing: .01em; white-space: nowrap; }
.ed-name .app em { font-style: normal; color: var(--blue-600); font-weight: 600; }
.ed-title { display: flex; align-items: center; gap: 7px; max-width: 26vw; }
.ed-title input { border: none; outline: none; background: transparent; font: 500 12.5px var(--text); color: var(--ink-soft); padding: 2px 6px; margin-left: -6px; border-radius: 8px; min-width: 40px; width: 100%; text-overflow: ellipsis; transition: background .2s, box-shadow .2s; }
.ed-title input:hover { background: rgba(255,255,255,.5); }
.ed-title input:focus { background: rgba(255,255,255,.9); box-shadow: 0 0 0 2px rgba(58,146,239,.35); color: var(--ink); }
.save-dot { width: 8px; height: 8px; flex-shrink: 0; border-radius: 50%; background: var(--green); box-shadow: 0 0 0 3px rgba(36,168,101,.15); transition: background .3s, box-shadow .3s; }
.save-dot.dirty { background: var(--amber); box-shadow: 0 0 0 3px rgba(224,161,42,.18); }
.save-dot.saving { background: var(--blue-500); animation: pulse 1s ease-in-out infinite; }
@keyframes pulse { 50% { box-shadow: 0 0 0 6px rgba(64,156,255,.15); } }

.ed-me { position: fixed; z-index: 120; top: 9px; right: 132px; display: flex; align-items: center; gap: 8px; }
body:not(.desktop) .ed-me { right: 18px; }
.ed-me .avatar { width: 32px; height: 32px; font-size: 12px; cursor: default; animation: pop-in .6s var(--spring) .4s both; }

/* ---------- Leiste: faellt von oben, klappt in die Breite auf ---------- */
.tb-zone { position: fixed; z-index: 110; top: var(--tb-top); left: 0; right: 0; display: flex; flex-direction: column; align-items: center; gap: 8px; pointer-events: none; transition: transform .6s var(--smooth), opacity .4s; }
body.focus .tb-zone { transform: translateY(-160px); opacity: 0; }
.tb-tabs, .tb-tools { pointer-events: auto; position: relative; display: flex; align-items: center; border-radius: 999px; overflow: hidden; white-space: nowrap;
  background: linear-gradient(170deg, rgba(255,255,255,.78), rgba(236,245,255,.62));
  -webkit-backdrop-filter: blur(18px) saturate(170%); backdrop-filter: blur(18px) saturate(170%);
  box-shadow: inset 0 1.5px 0 rgba(255,255,255,.95), inset 0 -10px 16px -12px rgba(22,52,104,.28), 0 0 0 1px rgba(255,255,255,.7), 0 18px 36px -18px rgba(14,42,92,.45), 0 2px 8px rgba(14,42,92,.08); }
.tb-tabs { padding: 5px; gap: 2px; }
.tb-tab { position: relative; z-index: 1; border: none; background: none; cursor: pointer; padding: 9px 20px; border-radius: 999px; font: 600 14px var(--text); color: var(--ink); transition: color .3s; }
.tb-tab:hover { color: var(--blue-700); }
.tb-tab.on { color: var(--blue-900); font-weight: 700; }
.tb-pill { position: absolute; z-index: 0; top: 5px; bottom: 5px; left: 0; width: 80px; border-radius: 999px; pointer-events: none;
  background: linear-gradient(180deg, rgba(235,246,255,.98), rgba(196,226,255,.92));
  box-shadow: inset 0 1.5px 0 #fff, inset 0 -6px 10px -6px rgba(29,95,194,.45), 0 0 0 1px rgba(140,196,255,.8), 0 6px 18px -4px rgba(64,156,255,.65), 0 0 22px rgba(64,156,255,.45);
  transition: transform .55s var(--spring), width .55s var(--spring); }
.tb-tools { padding: 6px 10px; min-height: 52px; max-width: calc(100vw - 28px); overflow-x: auto; scrollbar-width: none; }
.tb-tools::-webkit-scrollbar { display: none; }
.tb-set { display: flex; align-items: center; gap: 2px; }
.tb-set[hidden] { display: none; }
.tb-sep { width: 1px; height: 26px; margin: 0 6px; flex-shrink: 0; background: linear-gradient(180deg, rgba(70,101,140,0), rgba(70,101,140,.28), rgba(70,101,140,0)); }

.tb-btn { position: relative; flex-shrink: 0; height: 36px; min-width: 35px; padding: 0 8px; border: none; border-radius: 999px; background: none; cursor: pointer; color: var(--ink);
  display: inline-flex; align-items: center; justify-content: center; gap: 6px; font: 600 13px var(--text);
  transition: background .2s, color .2s, transform .3s var(--spring), box-shadow .25s; }
.tb-btn svg { width: 19px; height: 19px; flex-shrink: 0; }
.tb-btn:hover { background: rgba(255,255,255,.85); box-shadow: inset 0 1px 0 #fff, 0 4px 12px -4px rgba(14,42,92,.25); color: var(--blue-700); }
.tb-btn:active { transform: scale(.9); }
.tb-btn.on { color: var(--blue-900); background: linear-gradient(180deg, rgba(235,246,255,.98), rgba(196,226,255,.92));
  box-shadow: inset 0 1px 0 #fff, inset 0 -5px 8px -5px rgba(29,95,194,.45), 0 0 0 1px rgba(140,196,255,.8), 0 0 14px rgba(64,156,255,.4); }
.tb-btn:disabled { opacity: .35; cursor: default; transform: none; background: none; box-shadow: none; }
.tb-btn .lbl { font-size: 12.5px; }
.tb-btn .caret { width: 10px; height: 10px; margin-left: -2px; opacity: .6; }
.tb-btn.split { padding-right: 2px; }
.tb-btn .sw { position: absolute; left: 9px; right: 9px; bottom: 5px; height: 4px; border-radius: 3px; background: currentColor; box-shadow: 0 0 0 1px rgba(255,255,255,.8); }
.tb-btn.has-sw svg { margin-top: -5px; }
.tb-drop { width: 18px; min-width: 18px; padding: 0; margin-left: -4px; }
.tb-drop svg { width: 11px; height: 11px; }

/* Auswahlfelder (Schrift, Absatz) */
.tb-select { position: relative; flex-shrink: 0; height: 36px; display: inline-flex; align-items: center; gap: 6px; padding: 0 10px 0 14px; border: none; border-radius: 999px; cursor: pointer; color: var(--ink);
  background: rgba(255,255,255,.7); box-shadow: inset 0 2px 4px rgba(22,52,104,.1), 0 0 0 1px rgba(255,255,255,.8); font: 500 13.5px var(--text); transition: background .2s, box-shadow .25s; }
.tb-select:hover { background: #fff; box-shadow: inset 0 1px 2px rgba(22,52,104,.06), 0 0 0 1px rgba(140,196,255,.7), 0 0 12px rgba(64,156,255,.2); }
.tb-select span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; text-align: left; }
.tb-select svg { width: 11px; height: 11px; opacity: .55; flex-shrink: 0; transition: transform .35s var(--spring); }
.tb-select.open svg { transform: rotate(180deg); }
.tb-size { display: inline-flex; align-items: center; height: 36px; border-radius: 999px; background: rgba(255,255,255,.7); box-shadow: inset 0 2px 4px rgba(22,52,104,.1), 0 0 0 1px rgba(255,255,255,.8); }
.tb-size button { width: 28px; height: 36px; border: none; background: none; cursor: pointer; color: var(--ink-soft); display: flex; align-items: center; justify-content: center; border-radius: 999px; transition: color .2s, transform .25s var(--spring); }
.tb-size button:hover { color: var(--blue-700); }
.tb-size button:active { transform: scale(.85); }
.tb-size button svg { width: 13px; height: 13px; }
.tb-size input { width: 44px; border: none; outline: none; background: none; text-align: center; font: 600 13.5px var(--text); color: var(--ink); padding: 0; }

/* Ueberlauf-Menue der Leiste */
.more-pop { max-width: min(520px, calc(100vw - 30px)); }
.more-box { display: flex; flex-wrap: wrap; align-items: center; gap: 4px; padding: 2px; }
.more-box .tb-sep { height: 22px; margin: 0 4px; }
@media (max-width: 1560px) { .tb-set[data-set="insert"] .lbl, .tb-set[data-set="layout"] .lbl { display: none; } }
@media (max-width: 1100px) { .tb-tab { padding: 8px 14px; } }

/* Leisten-Animation: Knoepfe bauen sich auf */
.tb-tools .tb-set > *, .tb-tabs > .tb-tab { will-change: transform, opacity; }

/* Auswahlrahmen, Griffe, Hilfslinien */
.overlay { position: absolute; left: 0; top: 0; z-index: 5; pointer-events: none; }
.selbox { position: absolute; left: 0; top: 0; pointer-events: none; transform-origin: 50% 50%; animation: sel-in .3s var(--spring) both; }
@keyframes sel-in { from { opacity: 0; transform: scale(.96); } }
.selbox::before { content: ""; position: absolute; inset: -2px; border-radius: 3px; box-shadow: 0 0 0 1.5px rgba(42,122,224,.95), 0 0 0 5px rgba(64,156,255,.18), 0 0 22px rgba(64,156,255,.3); }
.hdl { position: absolute; width: 14px; height: 14px; margin: -7px 0 0 -7px; border-radius: 50%; pointer-events: auto;
  background: radial-gradient(circle at 35% 30%, #fff, #dcecff); box-shadow: 0 0 0 1.5px #2a7ae0, 0 3px 8px rgba(14,42,92,.3); transition: transform .25s var(--spring); }
.hdl:hover { transform: scale(1.35); }
.hdl[data-h="nw"], .hdl[data-h="se"] { cursor: nwse-resize; } .hdl[data-h="ne"], .hdl[data-h="sw"] { cursor: nesw-resize; }
.hdl[data-h="n"], .hdl[data-h="s"] { cursor: ns-resize; width: 22px; height: 10px; margin: -5px 0 0 -11px; border-radius: 6px; }
.hdl[data-h="e"], .hdl[data-h="w"] { cursor: ew-resize; width: 10px; height: 22px; margin: -11px 0 0 -5px; border-radius: 6px; }
.hdl[data-h="rot"] { cursor: grab; width: 18px; height: 18px; margin: -9px 0 0 -9px; background: radial-gradient(circle at 35% 30%, #8fd0ff, #2a7ae0); box-shadow: 0 0 0 2px #fff, 0 4px 10px rgba(14,42,92,.35), 0 0 14px rgba(64,156,255,.6); }
.hdl[data-h="rot"]::after { content: ""; position: absolute; left: 50%; top: 100%; width: 1.5px; height: 18px; margin-left: -.75px; background: rgba(42,122,224,.8); }
.guide { position: absolute; background: #ff4fa3; box-shadow: 0 0 6px rgba(255,79,163,.7); pointer-events: none; animation: guide-in .25s var(--smooth) both; }
.guide.v { width: 1px; } .guide.h { height: 1px; }
@keyframes guide-in { from { opacity: 0; } }
.size-tip { position: absolute; padding: 4px 10px; border-radius: 99px; font: 600 11px var(--display); letter-spacing: .04em; color: #fff; white-space: nowrap;
  background: linear-gradient(180deg, #3a92ef, #1d5fc2); box-shadow: 0 6px 16px rgba(29,95,194,.45); pointer-events: none; transform: translate(-50%, 0); }
.drop-caret { position: absolute; width: 2.5px; border-radius: 2px; background: #2a7ae0; box-shadow: 0 0 0 3px rgba(64,156,255,.2), 0 0 14px rgba(64,156,255,.9); pointer-events: none; transition: transform .12s var(--smooth), height .12s; animation: caret-blink 1s ease-in-out infinite; }
@keyframes caret-blink { 50% { opacity: .45; } }
.drop-side { position: absolute; border-radius: 8px; background: rgba(64,156,255,.12); box-shadow: inset 0 0 0 1.5px rgba(64,156,255,.5); pointer-events: none; transition: all .18s var(--smooth); }
.ghost { position: fixed; left: 0; top: 0; z-index: 9500; pointer-events: none; border-radius: 6px; transform-origin: 50% 50%;
  box-shadow: 0 30px 60px -20px rgba(14,30,60,.55), 0 0 0 2px rgba(64,156,255,.6), 0 0 36px rgba(64,156,255,.35); will-change: transform; }

/* Kontext-Leiste ueber Bild / Tabelle */
.ctx-bar { position: fixed; z-index: 130; display: flex; align-items: center; gap: 2px; padding: 5px; border-radius: 999px;
  background: linear-gradient(170deg, rgba(255,255,255,.94), rgba(236,245,255,.9));
  box-shadow: inset 0 1.5px 0 #fff, 0 0 0 1px rgba(255,255,255,.8), 0 16px 34px -14px rgba(14,42,92,.5), 0 0 24px rgba(64,156,255,.18);
  animation: ctx-in .45s var(--spring) both; white-space: nowrap; }
@keyframes ctx-in { from { opacity: 0; transform: translateY(10px) scale(.9); } }
.ctx-bar .tb-btn { height: 34px; min-width: 34px; }
.ctx-bar .tb-btn svg { width: 17px; height: 17px; }
.ctx-bar .tb-sep { height: 20px; margin: 0 4px; }
.ctx-bar .tb-btn.danger:hover { color: var(--red); }

/* ---------- Aufklapp-Menues ---------- */
.pop { position: fixed; z-index: 7600; min-width: 180px; max-height: min(70vh, 560px); overflow: auto; padding: 8px; border-radius: 22px;
  background: linear-gradient(165deg, rgba(255,255,255,.97), rgba(236,245,255,.95));
  box-shadow: inset 0 1.5px 0 #fff, 0 0 0 1px rgba(255,255,255,.8), 0 24px 50px -18px rgba(14,42,92,.55), 0 4px 14px rgba(14,42,92,.1);
  transform-origin: var(--ox, 50%) var(--oy, 0%); animation: pop-open .38s var(--spring) both; user-select: none; }
.pop.closing { animation: pop-close .18s ease both; pointer-events: none; }
@keyframes pop-open { from { opacity: 0; transform: scale(.86) translateY(-8px); } }
@keyframes pop-close { to { opacity: 0; transform: scale(.94) translateY(-4px); } }
.pop .opt { display: flex; align-items: center; gap: 10px; width: 100%; border: none; background: none; cursor: pointer; padding: 9px 12px; border-radius: 14px; text-align: left; color: var(--ink); font-size: 13.5px;
  transition: background .15s, transform .25s var(--spring); animation: opt-in .4s var(--smooth) both; }
@keyframes opt-in { from { opacity: 0; transform: translateX(-8px); } }
.pop .opt:hover, .pop .opt.kb { background: linear-gradient(180deg, rgba(235,246,255,1), rgba(210,232,255,.9)); box-shadow: inset 0 1px 0 #fff, 0 0 0 1px rgba(140,196,255,.6); }
.pop .opt.on { color: var(--blue-700); font-weight: 600; }
.pop .opt.on::after { content: ""; margin-left: auto; width: 7px; height: 7px; border-radius: 50%; background: var(--blue-500); box-shadow: 0 0 8px var(--glow); }
.pop .opt svg { width: 17px; height: 17px; flex-shrink: 0; color: var(--blue-600); }
.pop .opt small { margin-left: auto; color: var(--ink-faint); font-size: 11.5px; padding-left: 14px; }
.pop .opt:disabled { opacity: .45; cursor: default; }
.pop hr { border: none; height: 1px; margin: 6px 8px; background: rgba(70,101,140,.14); }
.pop h5 { margin: 6px 10px 6px; font: 700 10.5px var(--display); letter-spacing: .14em; text-transform: uppercase; color: var(--ink-faint); }
.pop .search { height: 38px; min-width: 0; margin: 2px 2px 8px; }
.pop.fonts { width: 290px; }
.pop.fonts .opt { font-size: 15px; padding: 8px 12px; }
.pop.styles { width: 300px; }
.pop.styles .opt { padding: 10px 14px; }

/* Farben */
.colors { width: 268px; padding: 12px; }
.colors .row { display: grid; grid-template-columns: repeat(10, 1fr); gap: 4px; margin-bottom: 4px; }
.colors .sw { width: 100%; aspect-ratio: 1; border: none; border-radius: 7px; cursor: pointer; box-shadow: inset 0 0 0 1px rgba(0,0,0,.08); transition: transform .25s var(--spring), box-shadow .2s; animation: sw-in .35s var(--spring) both; }
@keyframes sw-in { from { opacity: 0; transform: scale(.4); } }
.colors .sw:hover { transform: scale(1.25); box-shadow: inset 0 0 0 1px rgba(0,0,0,.12), 0 4px 10px rgba(14,42,92,.3); z-index: 1; position: relative; }
.colors .sw.on { box-shadow: 0 0 0 2px #fff, 0 0 0 3.5px var(--blue-600); }
.colors .wide { display: flex; gap: 6px; margin-top: 8px; }
.colors .wide button { flex: 1; height: 34px; border: none; border-radius: 12px; cursor: pointer; font: 600 12.5px var(--text); color: var(--ink); background: rgba(255,255,255,.8); box-shadow: var(--bevel-sm); display: flex; align-items: center; justify-content: center; gap: 6px; }
.colors .wide button:hover { background: #fff; color: var(--blue-700); }
.colors .wide svg { width: 16px; height: 16px; color: var(--blue-600); }
.pop.colors { overflow: visible; max-height: none; }
.colors .wide input[type=color] { position: absolute; opacity: 0; width: 0; height: 0; pointer-events: none; }
.colors .none-sw { background: linear-gradient(135deg, #fff 45%, #e25555 46%, #e25555 54%, #fff 55%) !important; }

/* Tabelle einfuegen */
.grid-pick { padding: 14px; }
.grid-pick .cells { display: grid; grid-template-columns: repeat(10, 20px); gap: 3px; }
.grid-pick .cells i { width: 20px; height: 20px; border-radius: 5px; background: rgba(255,255,255,.9); box-shadow: inset 0 0 0 1px #c9daef; transition: background .12s, box-shadow .12s, transform .2s var(--spring); }
.grid-pick .cells i.on { background: linear-gradient(180deg, #8cc4ff, #3a92ef); box-shadow: 0 0 8px rgba(64,156,255,.5); transform: scale(1.06); }
.grid-pick .lbl { margin-top: 10px; text-align: center; font: 600 13px var(--display); letter-spacing: .06em; color: var(--blue-700); }

/* Symbole / Emoji */
.sym-grid { display: grid; grid-template-columns: repeat(10, 34px); gap: 3px; padding: 4px; }
.sym-grid button { width: 34px; height: 34px; border: none; border-radius: 10px; cursor: pointer; background: none; font-size: 17px; color: var(--ink); transition: background .15s, transform .25s var(--spring); }
.sym-grid button:hover { background: #fff; transform: scale(1.25); box-shadow: 0 4px 12px rgba(14,42,92,.2); }
.sym-tabs { display: flex; gap: 4px; padding: 2px 4px 8px; flex-wrap: wrap; }
.sym-tabs button { border: none; border-radius: 99px; padding: 6px 11px; cursor: pointer; font: 600 12px var(--text); color: var(--ink-soft); background: rgba(255,255,255,.6); }
.sym-tabs button.on { color: #fff; background: linear-gradient(180deg, #5eadf8, #2a7ae0); }

/* kleine Formulare in Popovers */
.pform { padding: 12px; width: 300px; }
.pform .field { margin-bottom: 10px; }
.pform .inp { padding: 10px 13px; font-size: 14px; border-radius: 13px; }
.pform .row { display: flex; gap: 8px; }
.pform .row > * { flex: 1; }
.pform .btn-primary { padding: 10px 16px; font-size: 14px; }
.pform .btn-ghost { padding: 10px 14px; font-size: 13px; }
.pform .hint { font-size: 12px; color: var(--ink-faint); margin: -2px 4px 10px; }

/* ---------- Suchen & Ersetzen ---------- */
.find { position: fixed; z-index: 115; right: 18px; top: 130px; width: 360px; padding: 12px; border-radius: 26px; animation: find-in .5s var(--spring) both; }
@keyframes find-in { from { opacity: 0; transform: translateX(40px) scale(.95); } }
.find.closing { animation: find-out .25s ease both; }
@keyframes find-out { to { opacity: 0; transform: translateX(30px) scale(.96); } }
.find .frow { display: flex; align-items: center; gap: 6px; }
.find .frow + .frow { margin-top: 8px; }
.find .inp { flex: 1; padding: 10px 14px; font-size: 14px; border-radius: 999px; }
.find .cnt { min-width: 52px; text-align: center; font: 600 12px var(--display); color: var(--ink-soft); }
.find .tb-btn { height: 34px; min-width: 34px; }
.find .tb-btn svg { width: 16px; height: 16px; }
.find .opts { display: flex; gap: 6px; margin-top: 8px; }
.find .chip { border: none; border-radius: 99px; padding: 6px 12px; cursor: pointer; font: 600 12px var(--text); color: var(--ink-soft); background: rgba(255,255,255,.6); box-shadow: var(--bevel-sm); transition: all .25s; }
.find .chip.on { color: #fff; background: linear-gradient(180deg, #5eadf8, #2a7ae0); }
.find .btn-ghost { padding: 9px 14px; font-size: 13px; }
::highlight(iw-find) { background-color: rgba(255,214,90,.65); }
::highlight(iw-find-cur) { background-color: rgba(255,140,40,.75); color: #000; }

/* ---------- Statusleiste ---------- */
.status { position: fixed; z-index: 110; left: 50%; bottom: 14px; transform: translateX(-50%); display: flex; align-items: center; gap: 14px; padding: 6px 8px 6px 18px; border-radius: 999px;
  background: linear-gradient(170deg, rgba(255,255,255,.8), rgba(236,245,255,.66)); -webkit-backdrop-filter: blur(16px); backdrop-filter: blur(16px);
  box-shadow: inset 0 1.5px 0 #fff, 0 0 0 1px rgba(255,255,255,.7), 0 14px 30px -16px rgba(14,42,92,.45); font: 500 12.5px var(--text); color: var(--ink-soft); white-space: nowrap;
  animation: status-in .8s var(--spring) .9s both; transition: transform .6s var(--smooth), opacity .4s; }
@keyframes status-in { from { opacity: 0; transform: translate(-50%, 40px); } }
body.focus .status { transform: translate(-50%, 90px); opacity: 0; }
.status b { color: var(--ink); font-weight: 600; }
.status .sep { width: 1px; height: 16px; background: rgba(70,101,140,.2); }
.zoom { display: flex; align-items: center; gap: 6px; }
.zoom input[type=range] { -webkit-appearance: none; appearance: none; width: 110px; height: 4px; border-radius: 4px; background: linear-gradient(90deg, #5aa8f7 var(--p, 50%), rgba(70,101,140,.2) var(--p, 50%)); outline: none; }
.zoom input[type=range]::-webkit-slider-thumb { -webkit-appearance: none; width: 16px; height: 16px; border-radius: 50%; cursor: pointer; background: radial-gradient(circle at 35% 30%, #fff, #cfe6ff); box-shadow: 0 0 0 1.5px #2a7ae0, 0 3px 8px rgba(14,42,92,.3); transition: transform .25s var(--spring); }
.zoom input[type=range]::-webkit-slider-thumb:hover { transform: scale(1.25); }
.zoom .tb-btn { height: 30px; min-width: 30px; }
.zoom .tb-btn svg { width: 15px; height: 15px; }
.zoom .z { min-width: 42px; text-align: center; font: 600 12px var(--display); color: var(--ink); border: none; background: none; cursor: pointer; border-radius: 99px; padding: 6px 4px; }
.zoom .z:hover { background: rgba(255,255,255,.8); }

/* Formatierungszeichen */
body.marks .flow p::after, body.marks .flow h1::after, body.marks .flow h2::after, body.marks .flow h3::after, body.marks .flow h4::after, body.marks .flow li::after { content: "¶"; color: #7aa9e0; font-weight: 400; font-style: normal; margin-left: 2px; }
body.marks .flow br::after { content: "↵"; }

/* Sperre (abgemeldet / gesperrt) */
.lock { position: fixed; inset: 0; z-index: 9800; display: flex; align-items: center; justify-content: center; background: rgba(220,234,252,.55); -webkit-backdrop-filter: blur(14px); backdrop-filter: blur(14px); animation: lock-in .5s var(--smooth) both; }
@keyframes lock-in { from { opacity: 0; } }
.lock .lock-card { width: min(430px, calc(100vw - 40px)); padding: 54px 28px 26px; text-align: center; animation: card-in .8s var(--spring) .1s both; }
.lock .mini-orb { width: 92px; height: 92px; margin: -100px auto 18px; }
.lock .mini-orb svg { width: 36px; height: 36px; }
.lock h1 { margin: 0 0 6px; font: 700 22px var(--display); }
.lock p { margin: 0 0 18px; color: var(--ink-soft); font-size: 14px; line-height: 1.5; }
.lock .btn-link { margin-top: 10px; }

/* Ladeanzeige beim Oeffnen */
.loading-veil { position: fixed; inset: 0; z-index: 9000; display: flex; align-items: center; justify-content: center; flex-direction: column; gap: 18px; background: rgba(226,239,255,.6); -webkit-backdrop-filter: blur(10px); backdrop-filter: blur(10px); animation: lock-in .3s both; font: 600 15px var(--display); letter-spacing: .08em; color: var(--blue-700); }
.loading-veil .ring { width: 64px; height: 64px; border-radius: 50%; border: 4px solid rgba(64,156,255,.2); border-top-color: var(--blue-600); animation: spin .9s linear infinite; box-shadow: 0 0 30px rgba(64,156,255,.3); }

/* Format-Kacheln (Speichern unter) */
.fmt-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; }
.fmt { position: relative; border: none; cursor: pointer; padding: 14px 12px 12px; border-radius: 20px; text-align: left; color: var(--ink);
  background: rgba(255,255,255,.7); box-shadow: var(--bevel-sm), 0 8px 18px -12px rgba(14,42,92,.4); transition: transform .35s var(--spring), box-shadow .25s, background .2s; animation: card-pop .5s var(--spring) both; }
.fmt:hover { transform: translateY(-3px); background: #fff; box-shadow: var(--bevel-sm), 0 0 0 2px rgba(64,156,255,.5), 0 14px 24px -12px rgba(14,42,92,.4); }
.fmt:disabled { opacity: .45; cursor: default; transform: none; }
.fmt .ext { display: inline-block; padding: 3px 9px; border-radius: 99px; font: 700 11px var(--display); letter-spacing: .08em; color: #fff; background: linear-gradient(180deg, #5eadf8, #1f66cc); box-shadow: 0 4px 10px rgba(31,102,204,.35); }
.fmt .ext.own { background: linear-gradient(135deg, #36c2ff, #2a7ae0 50%, #6a5cff); }
.fmt b { display: block; margin-top: 8px; font: 600 14px var(--display); letter-spacing: .02em; }
.fmt small { display: block; margin-top: 2px; font-size: 11.5px; color: var(--ink-soft); line-height: 1.35; }

/* Dialog-Formular (Seite einrichten, Eigenschaften) */
.form-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 8px 12px; }
.form-grid .field { margin-bottom: 4px; }
.form-grid .field.full { grid-column: 1 / -1; }
.form-grid .inp { padding: 10px 13px; font-size: 14px; }
.stats { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.stat { padding: 14px 16px; border-radius: 18px; background: rgba(255,255,255,.7); box-shadow: var(--bevel-sm); animation: card-pop .5s var(--spring) both; }
.stat b { display: block; font: 700 24px var(--display); color: var(--blue-700); }
.stat span { font-size: 12.5px; color: var(--ink-soft); }

/* Kontextmenue */
.cmenu { min-width: 220px; }

/* ==========================================================================
   Folien (gleiche Darstellung ueberall)
   ========================================================================== */
.sl { position: relative; overflow: hidden; flex-shrink: 0; transform-origin: 0 0; user-select: none; contain: layout paint; }
.sl-bg, .sl-items { position: absolute; inset: 0; }
.sl .decor { position: absolute; left: 0; top: 0; pointer-events: none; }
.it { position: absolute; transform-origin: 50% 50%; }
.it > .geo { position: absolute; left: 0; top: 0; overflow: visible; pointer-events: none; }
.it.it-line > .geo .hit { pointer-events: stroke; cursor: move; }
.it .tx { position: absolute; inset: 0; display: flex; flex-direction: column; overflow: visible; white-space: pre-wrap; overflow-wrap: break-word; word-wrap: break-word; }
.it .tx.nowrap { white-space: pre; }
.it .tx.vert { writing-mode: vertical-rl; }
.it .tx-in { outline: none; min-height: 1em; }
.it .tx-in p { margin: 0; position: relative; }
.it .tx.bul .tx-in p + p, .it .tx-in p[data-b] + p[data-b] { margin-top: .35em; }
.it .tx-in p[data-lvl] { font-size: .88em; }
.it .tx-in p[data-lvl="1"] { margin-left: 1.3em; } .it .tx-in p[data-lvl="2"] { margin-left: 2.6em; } .it .tx-in p[data-lvl="3"] { margin-left: 3.9em; } .it .tx-in p[data-lvl="4"] { margin-left: 5.2em; }
.it .tx.bul .tx-in p:not([data-b]), .it .tx-in p[data-b]:not([data-b="none"]) { padding-left: 1.15em; }
.it .tx.bul .tx-in p:not([data-b])::before, .it .tx-in p[data-b="disc"]::before { content: "•"; position: absolute; left: .1em; }
.it .tx-in p[data-b="dash"]::before { content: "–"; position: absolute; left: .05em; }
.it .tx-in p[data-b="check"]::before { content: "✓"; position: absolute; left: 0; }
.it .tx-in p[data-b="arrow"]::before { content: "➤"; position: absolute; left: 0; font-size: .8em; top: .15em; }
.it .tx-in p[data-b="square"]::before { content: "■"; position: absolute; left: .05em; font-size: .7em; top: .2em; }
.it .tx-in p[data-b="circle"]::before { content: "○"; position: absolute; left: .05em; }
.it .tx-in { counter-reset: num; }
.it .tx-in p[data-b="num"] { counter-increment: num; padding-left: 1.6em; }
.it .tx-in p[data-b="num"]::before { content: counter(num) "."; position: absolute; left: 0; min-width: 1.3em; }
.it .tx-in a { color: var(--link, #1d63c9); text-decoration: underline; text-underline-offset: 2px; }
.it .tx-in sup, .it .tx-in sub { font-size: .65em; }
.it .prompt { opacity: .45; }
.mode-edit .it.ph .tx.empty { outline: 1.5px dashed rgba(90,130,190,.55); outline-offset: -1px; border-radius: 2px; }
.mode-edit .it.ph.it-image .img-empty { outline: 1.5px dashed rgba(90,130,190,.55); }
.it .img-clip { position: absolute; inset: 0; overflow: hidden; }
.it .img-clip img { display: block; width: 100%; height: 100%; object-fit: fill; user-select: none; -webkit-user-drag: none; }
.it .img-clip.img-empty { display: grid; place-items: center; background: rgba(140,180,230,.12); color: rgba(60,100,160,.8); }
.it .img-clip.img-empty > div { display: flex; flex-direction: column; align-items: center; gap: 8px; font: 600 18px var(--display); }
.it .img-clip.img-empty svg { width: 54px; height: 54px; }
.it .img-line { position: absolute; left: 0; top: 0; pointer-events: none; }
.it .tbl { width: 100%; height: 100%; border-collapse: collapse; table-layout: fixed; }
.it .tbl td { padding: 4.8px 9.6px; vertical-align: top; overflow-wrap: break-word; }
.it .tbl .cell { outline: none; min-height: 1em; white-space: pre-wrap; }
.it .tbl .cell p { margin: 0; }
.it .chart, .it .chart svg { position: absolute; inset: 0; width: 100%; height: 100%; }
.it.locked { pointer-events: none; }
.it.has-link { cursor: pointer; }
.sl-foot { position: absolute; left: 0; bottom: 14px; display: grid; grid-template-columns: 1fr 1fr 1fr; padding: 0 4%; font-size: 10pt; opacity: .65; pointer-events: none; }
.sl-foot span:nth-child(2) { text-align: center; } .sl-foot span:nth-child(3) { text-align: right; }
.sl-scale { position: absolute; left: 0; top: 0; transform-origin: 0 0; pointer-events: none; }

/* ==========================================================================
   Editor-Rahmen
   ========================================================================== */
body.slides { --tb-top: 14px; --top: 128px; --side: 214px; --notes-h: 112px; --pane: 300px; }
#editor { background: linear-gradient(170deg, #eef5ff 0%, #dce9fb 60%, #cfe0f8 100%); }
#editor .bg i { opacity: .7; }
.slide-panel { position: fixed; z-index: 20; left: 14px; top: var(--top); bottom: 64px; width: calc(var(--side) - 24px); border-radius: 26px; display: flex; flex-direction: column; padding: 10px 8px 8px; transition: transform .6s var(--smooth), opacity .4s; }
.slide-list { flex: 1; min-height: 0; overflow-y: auto; overflow-x: hidden; padding: 4px 4px 10px; outline: none; scrollbar-width: thin; }
.slide-list .th { position: relative; display: flex; gap: 6px; align-items: flex-start; padding: 6px 6px 6px 0; margin-bottom: 4px; border-radius: 14px; cursor: pointer; transition: background .2s, margin .25s var(--smooth); }
.slide-list .th .num { width: 18px; flex-shrink: 0; text-align: right; font: 600 11px var(--display); color: var(--ink-faint); padding-top: 3px; }
.slide-list .th .mini { position: relative; flex: 1; border-radius: 6px; overflow: hidden; background: #fff; box-shadow: 0 0 0 1px rgba(140,180,230,.4), 0 6px 14px -8px rgba(14,42,92,.4); transition: box-shadow .25s, transform .35s var(--spring); }
.slide-list .th:hover .mini { transform: translateY(-1px); box-shadow: 0 0 0 1.5px rgba(90,168,247,.6), 0 10px 18px -10px rgba(14,42,92,.45); }
.slide-list .th.cur .mini { box-shadow: 0 0 0 2.5px #2a7ae0, 0 0 16px rgba(64,156,255,.55), 0 10px 18px -10px rgba(14,42,92,.45); }
.slide-list .th.cur .num { color: var(--blue-700); }
.slide-list .th.multi .mini { box-shadow: 0 0 0 2px rgba(42,122,224,.7); }
.slide-list:focus .th.cur .mini { box-shadow: 0 0 0 2.5px #1d5fc2, 0 0 22px rgba(64,156,255,.75); }
.slide-list .th.hidden-slide .mini { opacity: .45; }
.slide-list .th.hidden-slide .num { text-decoration: line-through; }
.slide-list .th .marks { position: absolute; left: 2px; top: 22px; display: flex; flex-direction: column; gap: 3px; }
.slide-list .th .marks i { width: 9px; height: 9px; border-radius: 3px; }
.m-tr { background: linear-gradient(135deg, #5aa8f7, #2a7ae0); } .m-an { background: linear-gradient(135deg, #ffd66b, #e0a12a); } .m-no { background: linear-gradient(135deg, #9fe0bb, #24a865); }
.slide-list .th.dragging { opacity: .25; }
.slide-list .th.gap-before { margin-top: 26px; }
.slide-list.gap-end .th:last-child { margin-bottom: 30px; }
.th-ghost { position: fixed; left: 0; top: 0; z-index: 9500; pointer-events: none; display: flex; gap: 6px; padding: 6px; border-radius: 14px; background: rgba(255,255,255,.6); box-shadow: 0 24px 50px -16px rgba(14,30,60,.5); }
.th-ghost .mini { flex: 1; border-radius: 6px; overflow: hidden; position: relative; box-shadow: 0 0 0 2.5px #2a7ae0; }
.th-ghost .marks { display: none; }
.th-ghost .cnt { position: absolute; right: -8px; top: -8px; min-width: 24px; height: 24px; border-radius: 99px; display: grid; place-items: center; font: 700 12px var(--display); color: #fff; background: linear-gradient(180deg, #5eadf8, #1f66cc); }
.add-slide { height: 40px; border: none; border-radius: 16px; cursor: pointer; display: grid; place-items: center; color: var(--blue-700); background: rgba(255,255,255,.65); box-shadow: var(--bevel-sm); transition: transform .35s var(--spring), background .2s; }
.add-slide:hover { background: #fff; transform: scale(1.03); }
.add-slide:active { transform: scale(.94); }
.add-slide svg { width: 20px; height: 20px; transition: transform .45s var(--spring); }
.add-slide:hover svg { transform: rotate(90deg); }

.stage { position: fixed; left: var(--side); right: 0; top: calc(var(--top) - 10px); bottom: calc(var(--notes-h) + 70px); overflow: auto; outline: none; transition: right .45s var(--smooth), bottom .45s var(--smooth); scrollbar-width: thin; }
body.no-notes .stage { bottom: 60px; }
body.pane-open .stage { right: var(--pane); }
.stage-in { position: relative; }
.canvas { position: absolute; transform-origin: 0 0; box-shadow: 0 0 0 1px rgba(140,180,230,.35), 0 3px 8px rgba(14,42,92,.08), 0 40px 70px -36px rgba(14,42,92,.55); background: #fff; }
.canvas > .sl { position: absolute; left: 0; top: 0; }
.canvas.grid::after { content: ""; position: absolute; inset: 0; pointer-events: none; z-index: 4; background-image: linear-gradient(rgba(64,156,255,.18) 1px, transparent 1px), linear-gradient(90deg, rgba(64,156,255,.18) 1px, transparent 1px); background-size: 3.125% 5.556%; }
body.drawing .stage, body.drawing .canvas .it { cursor: crosshair !important; }
.canvas .it:not(.locked) { cursor: move; }
.canvas .it.editing .tx-in, .canvas .it.editing .cell { cursor: text; user-select: text; }
.canvas .it .tx-in[contenteditable="true"] { caret-color: #1d5fc2; }
.canvas .it.moving { transition: none !important; }
body.dragging-obj { cursor: move; }
.ov { position: absolute; left: 0; top: 0; width: 100%; height: 100%; z-index: 5; pointer-events: none; }
.selbox.thin::before { box-shadow: 0 0 0 1.5px rgba(42,122,224,.85); }
.selbox.group { animation: none; }
.selbox.group::before { box-shadow: 0 0 0 1px rgba(42,122,224,.5); border-radius: 4px; inset: -6px; background: rgba(64,156,255,.04); }
.selbox.still { animation: none; }
.selbox.editing::before { box-shadow: 0 0 0 1.5px rgba(42,122,224,.6), 0 0 0 5px rgba(64,156,255,.12); }
.selbox.line::before { display: none; }
.guide { width: calc(1px * var(--inv, 1)); }
.guide.h { height: calc(1px * var(--inv, 1)); }
.guide.center { background: #ff9f1c; box-shadow: 0 0 6px rgba(255,159,28,.8); }
.marquee { position: absolute; left: 0; top: 0; border-radius: 3px; background: rgba(64,156,255,.1); box-shadow: inset 0 0 0 calc(1px * var(--inv, 1)) rgba(42,122,224,.8); }
.draw-ghost { position: absolute; left: 0; top: 0; border: calc(2px * var(--inv, 1)) dashed rgba(42,122,224,.9); border-radius: 3px; background: rgba(64,156,255,.08); }
.an-badge { position: absolute; left: 0; top: 0; transform-origin: 0 0; min-width: 22px; height: 22px; padding: 0 6px; border-radius: 6px; display: grid; place-items: center; font: 700 12px var(--display); color: #fff; background: linear-gradient(180deg, #ffb84d, #e08a00); box-shadow: 0 3px 8px rgba(120,70,0,.35); }
.trans-prev { position: absolute; left: 0; top: 0; z-index: 6; overflow: hidden; background: #000; }
.trans-prev .tp { position: absolute; left: 0; top: 0; }
body.previewing .ov { visibility: hidden; }

/* Notizen */
.notes { position: fixed; z-index: 20; left: var(--side); right: 14px; bottom: 60px; height: var(--notes-h); border-radius: 22px; padding: 6px 16px 10px; display: flex; flex-direction: column; transition: transform .5s var(--smooth), opacity .35s, right .45s var(--smooth); }
body.pane-open .notes { right: var(--pane); }
body.no-notes .notes { transform: translateY(calc(var(--notes-h) + 80px)); opacity: 0; pointer-events: none; }
.notes-grip { height: 10px; margin: -6px -16px 2px; cursor: ns-resize; position: relative; }
.notes-grip::after { content: ""; position: absolute; left: 50%; top: 4px; width: 40px; height: 4px; margin-left: -20px; border-radius: 4px; background: rgba(70,101,140,.25); }
.notes-text { flex: 1; overflow: auto; outline: none; font-size: 14px; line-height: 1.5; color: var(--ink); white-space: pre-wrap; user-select: text; }
.notes-text p { margin: 0; }
.notes-text:empty::before { content: attr(data-ph); color: var(--ink-faint); }

/* Animationsbereich */
.anim-pane { position: fixed; z-index: 21; right: 14px; top: var(--top); bottom: 60px; width: calc(var(--pane) - 26px); border-radius: 26px; padding: 12px; display: flex; flex-direction: column; gap: 8px; transform: translateX(calc(100% + 30px)); opacity: 0; transition: transform .55s var(--spring), opacity .3s; }
body.pane-open .anim-pane { transform: none; opacity: 1; }
.pane-head { display: flex; align-items: center; gap: 4px; padding: 0 0 0 8px; }
.pane-head b { flex: 1; font: 700 16px var(--display); }
.pane-head .tb-btn { height: 32px; min-width: 32px; }
.pane-head .tb-btn svg { width: 15px; height: 15px; }
.pane-list { flex: 1; overflow: auto; display: flex; flex-direction: column; gap: 4px; }
.pane-empty { margin: auto; display: flex; flex-direction: column; align-items: center; gap: 10px; color: var(--ink-faint); font-size: 13px; }
.pane-empty svg { width: 40px; height: 40px; opacity: .4; }
.an-row { position: relative; display: flex; align-items: center; gap: 6px; padding: 7px 8px; border-radius: 14px; cursor: pointer; background: rgba(255,255,255,.55); box-shadow: var(--bevel-sm); animation: opt-in .4s var(--smooth) both; transition: background .2s, box-shadow .2s, margin .2s; }
.an-row:hover { background: rgba(255,255,255,.85); }
.an-row.tsel { box-shadow: 0 0 0 1.5px rgba(90,168,247,.5); }
.an-row.on { background: #fff; box-shadow: 0 0 0 2px #2a7ae0, 0 0 14px rgba(64,156,255,.35); }
.an-row.playing { background: #fff8e0; box-shadow: 0 0 0 2px #e0a12a; }
.an-row.drag { z-index: 3; opacity: .9; box-shadow: 0 14px 30px -10px rgba(14,42,92,.45); transition: none; }
.an-row.drop-above { margin-top: 18px; }
.an-row .n { width: 16px; text-align: center; font: 700 12px var(--display); color: var(--blue-700); }
.an-row .st { width: 10px; height: 10px; flex-shrink: 0; border-radius: 50%; }
.an-row .st.click { background: #2a7ae0; } .an-row .st.with { background: transparent; box-shadow: inset 0 0 0 2px #2a7ae0; } .an-row .st.after { background: #8cc4ff; border-radius: 2px; }
.anim-ic { width: 18px; height: 18px; flex-shrink: 0; }
.an-row .t { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.an-row .t b { font-size: 12.5px; font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.an-row .t small { font-size: 11px; color: var(--ink-soft); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.an-row .bar { position: absolute; left: 34px; right: 30px; bottom: 3px; height: 3px; border-radius: 3px; background: rgba(70,101,140,.1); }
.an-row .bar i { position: absolute; top: 0; bottom: 0; border-radius: 3px; background: linear-gradient(90deg, #5aa8f7, #2a7ae0); }
.an-row .x { width: 22px; height: 22px; border: none; border-radius: 50%; cursor: pointer; background: none; color: var(--ink-faint); font-size: 16px; line-height: 1; opacity: 0; transition: opacity .2s; }
.an-row:hover .x { opacity: 1; } .an-row .x:hover { color: var(--red); background: rgba(201,69,69,.1); }

/* Statusleiste */
.status .tb-btn { height: 30px; min-width: 30px; } .status .tb-btn svg { width: 15px; height: 15px; }
.st-play { display: inline-flex; align-items: center; gap: 6px; height: 32px; padding: 0 14px 0 10px; border: none; border-radius: 99px; cursor: pointer; font: 600 12.5px var(--text); color: #fff;
  background: linear-gradient(180deg, #5eadf8, #2f80e4 55%, #1f66cc); box-shadow: inset 0 1.5px 0 rgba(255,255,255,.5), 0 6px 14px -4px rgba(31,102,204,.6); transition: transform .3s var(--spring); }
.st-play:hover { transform: scale(1.04); } .st-play:active { transform: scale(.95); }
.st-play svg { width: 14px; height: 14px; fill: currentColor; }

/* Leiste: Ergaenzungen */
.tb-tab.ctx { color: #b06a00; }
.tb-tab.ctx.on { color: #8a4f00; }
.tb-pill.ctx { background: linear-gradient(180deg, rgba(255,247,230,.98), rgba(255,226,170,.92)); box-shadow: inset 0 1.5px 0 #fff, 0 0 0 1px rgba(255,200,110,.8), 0 6px 18px -4px rgba(224,150,40,.55), 0 0 22px rgba(255,190,80,.45); }
.tb-size em { font: 600 11px var(--display); color: var(--ink-faint); padding-right: 10px; font-style: normal; }
.tr-btn { flex-direction: column; gap: 1px; height: 44px; padding: 2px 8px; }
.tr-btn svg { width: 20px; height: 20px; }
.tr-btn .lbl { font-size: 10.5px; line-height: 1; }
.theme-strip { display: flex; gap: 6px; padding: 0 2px; }
.theme-sw { position: relative; width: 66px; height: 38px; border: none; border-radius: 8px; cursor: pointer; overflow: hidden; padding: 0; flex-shrink: 0; box-shadow: 0 0 0 1px rgba(0,0,0,.08), 0 4px 10px -6px rgba(14,42,92,.4); transition: transform .35s var(--spring), box-shadow .25s; }
.theme-sw:hover { transform: translateY(-2px) scale(1.06); }
.theme-sw.on { box-shadow: 0 0 0 2.5px #2a7ae0, 0 0 12px rgba(64,156,255,.5); }
.theme-sw .aa { position: absolute; left: 7px; top: 3px; font-size: 16px; font-weight: 600; }
.theme-sw .bar { position: absolute; left: 7px; right: 7px; bottom: 6px; display: flex; gap: 2px; height: 5px; }
.theme-sw .bar i { flex: 1; border-radius: 2px; }
.shape-ic { width: 22px; height: 18px; }
.pop.shape-pop { width: 330px; max-height: min(70vh, 600px); }
.shape-grid { display: grid; grid-template-columns: repeat(9, 1fr); gap: 2px; padding: 0 2px 6px; }
.shape-grid button { height: 32px; border: none; border-radius: 9px; cursor: pointer; background: none; color: var(--blue-700); display: grid; place-items: center; animation: sw-in .3s var(--spring) both; transition: background .15s, transform .25s var(--spring); }
.shape-grid button:hover { background: #fff; transform: scale(1.18); box-shadow: 0 4px 12px rgba(14,42,92,.18); }
.shape-grid svg { width: 22px; height: 18px; }
.pop.layout-pop { width: 520px; }
.layout-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 10px; padding: 4px; }
.lay { border: none; background: none; cursor: pointer; padding: 0; text-align: center; color: var(--ink); animation: card-pop .45s var(--spring) both; }
.lay .lay-th { position: relative; aspect-ratio: 16 / 9; border-radius: 6px; overflow: hidden; background: #fff; box-shadow: 0 0 0 1px rgba(140,180,230,.45), 0 6px 14px -8px rgba(14,42,92,.4); transition: transform .35s var(--spring), box-shadow .2s; }
.lay:hover .lay-th { transform: translateY(-3px); box-shadow: 0 0 0 2px rgba(64,156,255,.6), 0 12px 20px -10px rgba(14,42,92,.45); }
.lay.on .lay-th { box-shadow: 0 0 0 2.5px #2a7ae0; }
.lay span { display: block; margin-top: 5px; font-size: 11.5px; font-weight: 600; }
.pop.gal-pop { width: 430px; }
.gal { display: grid; grid-template-columns: repeat(4, 1fr); gap: 4px; padding: 0 2px 6px; }
.gal-it { display: flex; flex-direction: column; align-items: center; gap: 4px; padding: 8px 4px; border: none; border-radius: 14px; cursor: pointer; background: none; color: var(--ink); font-size: 11.5px; font-weight: 600; animation: sw-in .3s var(--spring) both; transition: background .15s; }
.gal-it:hover { background: #fff; box-shadow: var(--bevel-sm); }
.gal-it.on { background: rgba(58,146,239,.15); color: var(--blue-700); }
.gal-it svg { width: 26px; height: 26px; }
.fx-add { padding: 4px 10px 2px; font-size: 11.5px; color: var(--ink-faint); }
.var-pop .opt .pal { display: flex; gap: 2px; }
.var-pop .opt .pal i { width: 16px; height: 16px; border-radius: 4px; }
.font-pair span { display: flex; flex-direction: column; align-items: flex-start; }
.font-pair b { font-size: 17px; font-weight: 600; } .font-pair small { margin: 0 !important; padding: 0 !important; font-size: 12.5px !important; color: var(--ink-soft) !important; }
.quick-grid { display: grid; grid-template-columns: repeat(4, 64px); gap: 8px; padding: 6px; }
.quick { height: 40px; border-radius: 9px; cursor: pointer; font: 600 13px var(--text); animation: sw-in .3s var(--spring) both; transition: transform .25s var(--spring); }
.quick:hover { transform: scale(1.1); }
.pop.cmenu .opt.danger { color: var(--red); } .pop.cmenu .opt.danger svg { color: var(--red); }
.range { width: 100%; accent-color: #2a7ae0; }
.chip { border: none; border-radius: 99px; padding: 6px 11px; cursor: pointer; font: 600 12px var(--text); color: var(--ink-soft); background: rgba(255,255,255,.7); box-shadow: var(--bevel-sm); transition: background .2s, color .2s; }
.chip:hover { background: #fff; color: var(--blue-700); }
.slide-links { display: flex; flex-wrap: wrap; gap: 4px; margin: -2px 0 10px; max-height: 120px; overflow: auto; }
.chk { display: flex; align-items: center; gap: 10px; padding: 8px 4px; font-size: 14px; cursor: pointer; }
.chk input { width: 18px; height: 18px; accent-color: #2a7ae0; }
.rows-form { display: flex; flex-direction: column; gap: 4px; min-width: 340px; }
select.inp { appearance: auto; }
.seg-row { display: flex; justify-content: center; margin-bottom: 14px; }

/* Dialoge */
.chart-edit .ce-scroll { max-height: 50vh; overflow: auto; border-radius: 14px; background: rgba(255,255,255,.6); box-shadow: var(--bevel-sm); padding: 6px; }
.ce { border-collapse: separate; border-spacing: 3px; }
.ce th, .ce td { position: relative; }
.ce input { width: 110px; border: none; outline: none; padding: 8px 10px; border-radius: 9px; background: #fff; font: 500 13.5px var(--text); color: var(--ink); box-shadow: inset 0 0 0 1px rgba(140,180,230,.4); }
.ce th input { font-weight: 700; color: var(--blue-700); }
.ce input:focus { box-shadow: 0 0 0 2px rgba(58,146,239,.5); }
.ce-x { position: absolute; right: -4px; top: -4px; width: 18px; height: 18px; border: none; border-radius: 50%; cursor: pointer; font-size: 12px; line-height: 1; color: #fff; background: rgba(201,69,69,.85); opacity: 0; transition: opacity .2s; }
.ce th:hover .ce-x, .ce td:hover .ce-x { opacity: 1; }
.ce-btns { display: flex; gap: 8px; margin-top: 10px; }
.ce-btns .btn-ghost svg { width: 15px; height: 15px; margin-right: 4px; vertical-align: -3px; }
.crop-box { position: relative; max-width: 100%; display: inline-block; margin: 0 auto; user-select: none; }
.crop-box img { display: block; max-width: min(760px, 80vw); max-height: 56vh; }
.crop-dim { position: absolute; inset: 0; background: rgba(10,20,40,.55); pointer-events: none; }
.crop-rect { position: absolute; cursor: move; box-shadow: 0 0 0 2px #fff, 0 0 0 3.5px #2a7ae0; }
.crop-rect i { position: absolute; width: 14px; height: 14px; margin: -7px; border-radius: 50%; background: #fff; box-shadow: 0 0 0 1.5px #2a7ae0; }
.crop-rect i[data-h="nw"] { left: 0; top: 0; cursor: nwse-resize; } .crop-rect i[data-h="ne"] { right: 0; top: 0; cursor: nesw-resize; } .crop-rect i[data-h="sw"] { left: 0; bottom: 0; cursor: nesw-resize; } .crop-rect i[data-h="se"] { right: 0; bottom: 0; cursor: nwse-resize; }
.crop-rect i[data-h="n"] { left: 50%; top: 0; cursor: ns-resize; } .crop-rect i[data-h="s"] { left: 50%; bottom: 0; cursor: ns-resize; } .crop-rect i[data-h="w"] { left: 0; top: 50%; cursor: ew-resize; } .crop-rect i[data-h="e"] { right: 0; top: 50%; cursor: ew-resize; }
.crop-ratios { display: flex; gap: 6px; justify-content: center; margin-top: 12px; }
.modal-body:has(.crop-box) { text-align: center; }
.bg-dlg { display: flex; gap: 20px; align-items: flex-start; }
.bg-prev { position: relative; width: 300px; flex-shrink: 0; aspect-ratio: 16 / 9; border-radius: 10px; overflow: hidden; box-shadow: 0 0 0 1px rgba(140,180,230,.4), 0 14px 30px -14px rgba(14,42,92,.45); }
.bg-opts { flex: 1; }
.bg-opts h5 { margin: 4px 2px 6px; font: 700 10.5px var(--display); letter-spacing: .14em; text-transform: uppercase; color: var(--ink-faint); }
.bg-opts .row { display: grid; grid-template-columns: repeat(8, 1fr); gap: 5px; margin-bottom: 8px; }
.bg-opts .sw { position: relative; aspect-ratio: 1; border: none; border-radius: 8px; cursor: pointer; box-shadow: inset 0 0 0 1px rgba(0,0,0,.08); transition: transform .25s var(--spring); }
.bg-opts .sw:hover { transform: scale(1.15); }
.bg-opts .own-sw { display: grid; place-items: center; background: #fff; color: var(--blue-600); }
.bg-opts .own-sw svg { width: 16px; height: 16px; }
.bg-opts .own-sw input { position: absolute; opacity: 0; width: 0; height: 0; }
.bg-img-row { display: flex; align-items: center; gap: 10px; }
.bg-img-row .btn-ghost svg { width: 16px; height: 16px; margin-right: 6px; vertical-align: -3px; }
@media (max-width: 760px) { .bg-dlg { flex-direction: column; } .bg-prev { width: 100%; } }

/* Start: Designs + Zuletzt */
.slides-grid { grid-template-columns: repeat(auto-fill, minmax(210px, 1fr)) !important; }
.tpl.land .paper, .rc .paper { aspect-ratio: 16 / 9; }
.tpl small .dot { display: inline-block; width: 10px; height: 10px; margin-right: 3px; border-radius: 50%; vertical-align: -1px; }

/* Foliensortierung */
.sorter { position: fixed; z-index: 30; left: 14px; right: 14px; top: var(--top); bottom: 60px; overflow: auto; border-radius: 26px; outline: none; padding: 22px; background: rgba(236,245,255,.82); -webkit-backdrop-filter: blur(16px); backdrop-filter: blur(16px); box-shadow: inset 0 1.5px 0 #fff, 0 20px 40px -20px rgba(14,42,92,.4); animation: lock-in .3s both; }
.sorter-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); gap: 22px; }
.sc { position: relative; cursor: pointer; transition: transform .35s var(--spring), margin .25s; }
.sc .mini { position: relative; border-radius: 8px; overflow: hidden; background: #fff; box-shadow: 0 0 0 1px rgba(140,180,230,.4), 0 12px 24px -14px rgba(14,42,92,.45); transition: box-shadow .25s, transform .35s var(--spring); }
.sc:hover .mini { transform: translateY(-4px); }
.sc.cur .mini { box-shadow: 0 0 0 3px #2a7ae0, 0 0 18px rgba(64,156,255,.5); }
.sc .num { position: absolute; left: 8px; top: 8px; z-index: 2; min-width: 24px; height: 24px; padding: 0 6px; border-radius: 99px; display: grid; place-items: center; font: 700 11px var(--display); color: #fff; background: rgba(29,95,194,.85); }
.sc .tt { display: block; margin: 8px 4px 0; font-size: 12.5px; font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.sc.hidden-slide .mini { opacity: .45; }
.sc.dragging { opacity: .25; }
.sc.gap-before { margin-left: 30px; }
.sc-ghost { position: fixed; left: 0; top: 0; z-index: 9500; pointer-events: none; transform-origin: 0 0; }
body.sorting .slide-panel, body.sorting .stage, body.sorting .notes, body.sorting .anim-pane { visibility: hidden; }

/* ==========================================================================
   Praesentation
   ========================================================================== */
.show-layer { position: fixed; inset: 0; z-index: 9700; background: #000; cursor: default; user-select: none; }
.show-main { position: absolute; inset: 0; overflow: hidden; }
.scr-stage { position: absolute; left: 0; top: 0; transform-origin: 0 0; overflow: hidden; }
.scr-stage > .scr-slide { position: absolute; left: 0; top: 0; }
.scr-ink { position: absolute; left: 0; top: 0; width: 100%; height: 100%; z-index: 20; pointer-events: none; overflow: visible; }
.scr-laser { position: absolute; left: -14px; top: -14px; width: 28px; height: 28px; border-radius: 50%; z-index: 21; pointer-events: none; opacity: 0; background: radial-gradient(circle, #fff 0 18%, #ff2d55 30%, rgba(255,45,85,.45) 55%, rgba(255,45,85,0) 72%); transition: opacity .15s; }
.scr-laser.on { opacity: 1; }
.scr-blank { position: absolute; inset: 0; z-index: 30; opacity: 0; pointer-events: none; transition: opacity .35s; }
.scr-blank.on { opacity: 1; }
.scr-blank.black, .scr-blank.end { background: #000; } .scr-blank.white { background: #fff; }
.scr-blank.end::after { content: "Ende der Präsentation – zum Beenden klicken"; position: absolute; left: 0; right: 0; top: 46%; text-align: center; font: 500 26px var(--display); letter-spacing: .04em; color: rgba(255,255,255,.75); }
.show-layer.pen .show-main, .show-layer.pen .pv-screen { cursor: crosshair; }
.show-layer.laser .show-main, .show-layer.laser .pv-screen { cursor: none; }
.show-ctrl { position: absolute; left: 22px; bottom: 22px; z-index: 40; display: flex; align-items: center; gap: 4px; padding: 6px; border-radius: 99px; background: rgba(20,24,32,.55); -webkit-backdrop-filter: blur(14px); backdrop-filter: blur(14px); box-shadow: 0 0 0 1px rgba(255,255,255,.12); opacity: 0; transform: translateY(14px); transition: opacity .35s, transform .45s var(--spring); }
.show-layer.ui .show-ctrl, .show-ctrl:hover { opacity: 1; transform: none; }
.show-ctrl button, .pv-bar button { width: 36px; height: 36px; border: none; border-radius: 50%; cursor: pointer; display: grid; place-items: center; color: rgba(255,255,255,.85); background: none; transition: background .2s, transform .25s var(--spring); }
.show-ctrl button:hover, .pv-bar button:hover { background: rgba(255,255,255,.14); color: #fff; }
.show-ctrl button:active, .pv-bar button:active { transform: scale(.88); }
.show-ctrl button.on, .pv-bar button.on { background: rgba(90,168,247,.45); color: #fff; }
.show-ctrl svg, .pv-bar svg { width: 18px; height: 18px; }
.show-ctrl [data-a=prev] svg, .pv-bar [data-a=prev] svg { transform: rotate(90deg); }
.show-ctrl [data-a=next] svg, .pv-bar [data-a=next] svg { transform: rotate(-90deg); }
.show-ctrl .sep, .pv-bar .sep { width: 1px; height: 20px; margin: 0 4px; background: rgba(255,255,255,.2); }
.show-ctrl .cnt { padding: 0 8px; font: 600 13px var(--display); color: rgba(255,255,255,.8); min-width: 54px; text-align: center; }
.laser-ic { width: 12px; height: 12px; border-radius: 50%; background: #ff2d55; box-shadow: 0 0 8px #ff2d55; }
.show-grid { position: absolute; inset: 0; z-index: 60; overflow: auto; padding: 50px; background: rgba(8,12,20,.86); -webkit-backdrop-filter: blur(10px); backdrop-filter: blur(10px); animation: lock-in .25s both; }
.sg-in { display: grid; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); gap: 22px; }
.sg-it { position: relative; border: none; background: none; padding: 0; cursor: pointer; color: #fff; text-align: left; animation: card-pop .5s var(--spring) both; }
.sg-it .mini { position: relative; border-radius: 8px; overflow: hidden; background: #fff; box-shadow: 0 16px 30px -14px rgba(0,0,0,.7); transition: transform .35s var(--spring), box-shadow .25s; }
.sg-it:hover .mini { transform: scale(1.04); box-shadow: 0 0 0 3px #5aa8f7, 0 16px 30px -14px rgba(0,0,0,.7); }
.sg-it.cur .mini { box-shadow: 0 0 0 3px #ffd66b; }
.sg-it span { display: block; margin-top: 6px; font: 600 13px var(--display); opacity: .8; }

/* Referentenansicht */
.show-layer.presenter { background: radial-gradient(circle at 20% 0%, #1b2f52, #0b1424 70%); }
.pv { position: absolute; inset: 0; display: flex; flex-direction: column; padding: 16px 20px 20px; gap: 14px; color: #dfe9f7; }
.pv-top { display: flex; align-items: center; gap: 18px; }
.pv-brand { display: flex; align-items: center; gap: 10px; flex: 1; }
.pv-brand .mini-orb { width: 36px; height: 36px; }
.pv-brand .mini-orb .glyph { width: 50%; }
.pv-brand b { font: 600 15px var(--display); letter-spacing: .04em; }
.pv-timer { display: flex; align-items: center; gap: 4px; padding: 4px 6px 4px 16px; border-radius: 99px; background: rgba(255,255,255,.08); }
.pv-timer .t { font: 600 24px var(--display); letter-spacing: .06em; min-width: 80px; }
.pv-timer button { width: 32px; height: 32px; border: none; border-radius: 50%; cursor: pointer; display: grid; place-items: center; color: rgba(255,255,255,.8); background: none; }
.pv-timer button:hover { background: rgba(255,255,255,.12); } .pv-timer button.on { background: rgba(255,214,107,.35); }
.pv-timer svg { width: 16px; height: 16px; }
.pv-clock { font: 500 18px var(--display); letter-spacing: .08em; opacity: .7; }
.pv-aud { display: flex; align-items: center; gap: 8px; font-size: 12.5px; opacity: .75; }
.pv-aud i { width: 8px; height: 8px; border-radius: 50%; background: #e0a12a; } .pv-aud i.ok { background: #36d17c; box-shadow: 0 0 8px #36d17c; }
.pv-end { border: none; border-radius: 99px; padding: 9px 16px; cursor: pointer; font: 600 13px var(--text); color: #fff; background: rgba(229,83,45,.85); }
.pv-end:hover { background: #e5532d; }
.pv-body { flex: 1; min-height: 0; display: flex; gap: 20px; }
.pv-cur { flex: 1.75; min-width: 0; display: flex; flex-direction: column; gap: 10px; }
.pv-screen { position: relative; flex: 1; min-height: 0; overflow: hidden; border-radius: 12px; background: #000; box-shadow: 0 0 0 1px rgba(255,255,255,.1), 0 30px 60px -30px rgba(0,0,0,.8); }
.pv-bar { align-self: center; display: flex; align-items: center; gap: 4px; padding: 6px; border-radius: 99px; background: rgba(255,255,255,.08); }
.pv-bar .cnt { padding: 0 10px; font: 600 15px var(--display); min-width: 70px; text-align: center; }
.pv-side { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 10px; }
.pv-next-h, .pv-notes-h { font: 600 12px var(--display); letter-spacing: .12em; text-transform: uppercase; opacity: .65; display: flex; align-items: center; gap: 6px; }
.pv-notes-h span { flex: 1; }
.pv-notes-h button { border: none; border-radius: 8px; padding: 4px 8px; cursor: pointer; font: 700 12px var(--display); color: #dfe9f7; background: rgba(255,255,255,.1); }
.pv-next { position: relative; width: 100%; border-radius: 10px; overflow: hidden; background: #000; box-shadow: 0 0 0 1px rgba(255,255,255,.1); }
.pv-fin { position: absolute; inset: 0; display: grid; place-items: center; font: 600 18px var(--display); opacity: .5; }
.pv-notes { flex: 1; min-height: 0; overflow: auto; padding: 14px 16px; border-radius: 14px; background: rgba(255,255,255,.06); line-height: 1.5; user-select: text; }
.pv-notes p { margin: 0 0 .5em; } .pv-notes .none { opacity: .45; }

/* Publikumsfenster */
body.audience { background: #000; }
body.audience .aud { position: fixed; inset: 0; overflow: hidden; }
.aud-wait { position: fixed; inset: 0; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 16px; color: rgba(255,255,255,.7); font: 500 16px var(--display); letter-spacing: .06em; transition: opacity .4s; }
.aud-wait .mini-orb { width: 90px; height: 90px; }
body.audience.ready .aud-wait { opacity: 0; pointer-events: none; }
body.audience.bye { opacity: 0; transition: opacity .35s; }

/* ==========================================================================
   Druck / PDF
   ========================================================================== */
.print-box { display: none; }
body.printing .print-box { display: block; position: absolute; left: 0; top: 0; z-index: 99999; background: #fff; }
.print-page { position: relative; overflow: hidden; break-after: page; page-break-after: always; background: #fff; }
.print-page:last-child { break-after: auto; page-break-after: auto; }
.print-slide { position: relative; margin: 56px auto 24px; overflow: hidden; box-shadow: 0 0 0 1px #c8d3e2; }
.print-notes { padding: 0 60px; font: 14px/1.5 "Segoe UI", sans-serif; color: #222; }
.print-notes .pn-h { font: 600 12px "Bahnschrift", "Segoe UI", sans-serif; letter-spacing: .1em; text-transform: uppercase; color: #6a7f9a; margin-bottom: 8px; }
.print-notes p { margin: 0 0 6px; }
body.printing { overflow: visible; }
body.printing > *:not(.print-box):not(.loading-veil) { visibility: hidden !important; }
@media print {
  @page { margin: 0; }
  html, body { height: auto !important; overflow: visible !important; background: #fff !important; }
  body > *:not(.print-box) { display: none !important; }
  .print-box { position: static !important; }
  * { -webkit-print-color-adjust: exact; print-color-adjust: exact; }
}

/* Seitenleisten etwas heller als die Glas-Karten */
.slide-panel.glass, .notes.glass, .anim-pane.glass { background: linear-gradient(170deg, rgba(255,255,255,.72), rgba(234,244,255,.5)); }
