/* SGC Mailfach – Erstellt von SpieleGamer */
:root {
  --bg: #08080d; --bg2: #0f0f17; --panel: #13131c; --panel2: #1a1a26; --hover: rgba(255, 255, 255, .055); --line: rgba(255, 255, 255, .075);
  --text: #f1f1f7; --muted: #a3a3b8; --faint: #6e6e86;
  --accent: #ff3366; --accent2: #8b5cf6; --accent-soft: rgba(255, 51, 102, .14);
  --grad: linear-gradient(135deg, #ff3366 0%, #ff5e7e 40%, #8b5cf6 100%);
  --glass: rgba(19, 19, 28, .72);
  --ok: #22c55e; --warn: #f59e0b; --err: #ef4444; --star: #fbbf24;
  --radius: 16px; --shadow: 0 24px 60px -12px rgba(0, 0, 0, .6), 0 0 0 1px rgba(255, 255, 255, .04);
  --shadow-sm: 0 4px 14px -4px rgba(0, 0, 0, .5);
  --row-pad: 12px;
  --sat: env(safe-area-inset-top, 0px); --sab: env(safe-area-inset-bottom, 0px);
  font-family: "Segoe UI Variable Text", "Segoe UI", Inter, system-ui, -apple-system, "SF Pro Text", Roboto, Helvetica, Arial, sans-serif;
  color-scheme: dark;
}
[data-theme="light"] {
  --bg: #f3f3f8; --bg2: #fbfbfe; --panel: #ffffff; --panel2: #f5f5fa; --hover: rgba(20, 20, 60, .05); --line: rgba(20, 20, 60, .09);
  --text: #14141c; --muted: #5a5a70; --faint: #8a8aa0; --accent-soft: rgba(255, 51, 102, .1);
  --glass: rgba(255, 255, 255, .75);
  --shadow: 0 24px 60px -16px rgba(30, 30, 70, .22), 0 0 0 1px rgba(20, 20, 60, .05);
  --shadow-sm: 0 4px 14px -6px rgba(30, 30, 70, .2);
  color-scheme: light;
}
[data-density="compact"] { --row-pad: 6px; }
* { box-sizing: border-box; }
html, body, #root { margin: 0; height: 100%; background: var(--bg); color: var(--text); }
body { font-size: 14.5px; line-height: 1.45; -webkit-font-smoothing: antialiased; overflow: hidden; }
button, input, select, textarea { font: inherit; color: inherit; }
a { color: var(--accent); }
.hidden { display: none !important; }

/* Boot */
.boot { position: fixed; inset: 0; display: grid; place-content: center; justify-items: center; gap: 22px; background: var(--bg); z-index: 100; transition: opacity .3s; }
.boot img { filter: drop-shadow(0 0 22px rgba(255, 45, 85, .5)); animation: pulse 1.6s ease-in-out infinite; }
.boot-bar { width: 140px; height: 3px; border-radius: 3px; background: var(--line); overflow: hidden; }
.boot-bar i { display: block; width: 40%; height: 100%; background: var(--accent); animation: load 1s ease-in-out infinite; }
@keyframes load { 0% { transform: translateX(-100%); } 100% { transform: translateX(250%); } }
@keyframes pulse { 50% { transform: scale(1.06); } }
.boot.out { opacity: 0; pointer-events: none; }

/* Buttons */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; height: 38px; padding: 0 16px; border-radius: 11px; border: 1px solid var(--line); background: var(--panel2); cursor: pointer; font-weight: 600; white-space: nowrap; transition: background .15s, border-color .15s, transform .05s; }
.btn:hover { background: var(--hover); }
.btn:active { transform: translateY(1px); }
.btn.primary { background: linear-gradient(135deg, var(--accent), var(--accent2)); border-color: transparent; color: #fff; box-shadow: 0 6px 20px rgba(255, 45, 85, .3); }
.btn.primary:hover { filter: brightness(1.08); }
.btn.danger { color: var(--err); }
.btn.danger.solid { background: var(--err); color: #fff; border-color: transparent; }
.btn.ghost { background: transparent; border-color: transparent; }
.btn.sm { height: 32px; padding: 0 11px; font-size: 13px; border-radius: 9px; }
.btn[disabled] { opacity: .55; pointer-events: none; }
.ib { width: 36px; height: 36px; display: inline-grid; place-items: center; border-radius: 10px; border: 0; background: transparent; cursor: pointer; color: var(--muted); flex: none; }
.ib:hover { background: var(--hover); color: var(--text); }
.ib.on { color: var(--accent); }
.ib svg, .btn svg { width: 19px; height: 19px; flex: none; }
.ib.star.on { color: var(--star); }

/* Formulare */
.field { display: grid; gap: 6px; margin-bottom: 14px; }
.field > span { font-size: 12.5px; font-weight: 600; color: var(--muted); }
.input, .field input, .field select, .field textarea { width: 100%; height: 42px; padding: 0 13px; border-radius: 11px; border: 1px solid var(--line); background: var(--bg2); outline: none; transition: border-color .15s, box-shadow .15s; }
.field textarea { height: auto; min-height: 90px; padding: 10px 13px; resize: vertical; }
.input:focus, .field input:focus, .field select:focus, .field textarea:focus { border-color: var(--accent); box-shadow: 0 0 0 3px var(--accent-soft); }
.row { display: flex; gap: 10px; align-items: center; }
.row > .grow { flex: 1; min-width: 0; }
.grid2 { display: grid; grid-template-columns: 1fr 130px; gap: 10px; }
.check { display: flex; gap: 10px; align-items: center; cursor: pointer; user-select: none; }
.check input { width: 18px; height: 18px; accent-color: var(--accent); }
.hint { font-size: 12.5px; color: var(--muted); }
.err-box { background: rgba(239, 68, 68, .12); border: 1px solid rgba(239, 68, 68, .35); color: #fca5a5; padding: 10px 13px; border-radius: 11px; font-size: 13.5px; margin-bottom: 14px; }
[data-theme="light"] .err-box { color: #b91c1c; }
.ok-box { background: rgba(34, 197, 94, .12); border: 1px solid rgba(34, 197, 94, .35); padding: 10px 13px; border-radius: 11px; font-size: 13.5px; margin-bottom: 14px; }
.switch { position: relative; width: 42px; height: 24px; flex: none; }
.switch input { opacity: 0; width: 0; height: 0; }
.switch i { position: absolute; inset: 0; border-radius: 24px; background: var(--line); transition: .2s; cursor: pointer; }
.switch i::after { content: ""; position: absolute; left: 3px; top: 3px; width: 18px; height: 18px; border-radius: 50%; background: #fff; transition: .2s; }
.switch input:checked + i { background: var(--accent); }
.switch input:checked + i::after { transform: translateX(18px); }

/* Login */
.auth { height: 100%; overflow: auto; display: grid; place-items: center; padding: 30px 16px; background:
  radial-gradient(900px 500px at 15% 10%, rgba(255, 45, 85, .18), transparent 60%),
  radial-gradient(700px 500px at 90% 90%, rgba(193, 18, 31, .18), transparent 60%), var(--bg); }
.auth-card { width: min(420px, 100%); background: var(--panel); border: 1px solid var(--line); border-radius: 22px; padding: 34px 30px 26px; box-shadow: var(--shadow); }
.auth-logo { display: flex; align-items: center; gap: 14px; margin-bottom: 26px; }
.auth-logo img { width: 54px; height: 54px; filter: drop-shadow(0 0 14px rgba(255, 45, 85, .45)); }
.auth-logo h1 { margin: 0; font-size: 23px; letter-spacing: -.3px; }
.auth-logo p { margin: 2px 0 0; color: var(--muted); font-size: 13px; }
.auth-foot { margin-top: 18px; text-align: center; font-size: 12.5px; color: var(--faint); }
.auth-foot a { color: var(--muted); }

/* Layout */
.app { height: 100%; display: grid; grid-template-columns: 264px minmax(330px, 420px) 1fr; grid-template-rows: minmax(0, 1fr); padding-top: var(--sat); }
.app.reader-off { grid-template-columns: 264px 1fr; }
.app.reader-off .reader { display: none; }
.side { background: var(--bg2); border-right: 1px solid var(--line); display: flex; flex-direction: column; min-height: 0; }
.brand { display: flex; align-items: center; gap: 11px; padding: 16px 16px 10px; }
.brand img { width: 34px; height: 34px; filter: drop-shadow(0 0 10px rgba(255, 45, 85, .45)); }
.brand b { font-size: 16.5px; letter-spacing: -.2px; }
.brand small { display: block; font-size: 11px; color: var(--faint); font-weight: 500; }
.compose-btn { margin: 8px 14px 12px; height: 46px; border-radius: 14px; font-size: 15px; }
.nav { flex: 1; overflow: auto; padding: 0 8px 12px; }
.nav-sec { margin-top: 6px; }
.nav-head { display: flex; align-items: center; gap: 8px; padding: 9px 10px 5px; font-size: 11.5px; font-weight: 700; text-transform: uppercase; letter-spacing: .6px; color: var(--faint); cursor: pointer; user-select: none; }
.nav-head .dot { width: 9px; height: 9px; border-radius: 50%; flex: none; }
.nav-head .t { flex: 1; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; text-transform: none; letter-spacing: 0; font-size: 12.5px; color: var(--muted); }
.nav-head .warn { color: var(--warn); }
.nav-head .chev { transition: transform .15s; width: 14px; height: 14px; }
.nav-sec.closed .chev { transform: rotate(-90deg); }
.nav-sec.closed .nav-items { display: none; }
.nav-item { display: flex; align-items: center; gap: 11px; padding: 8px 11px; border-radius: 10px; cursor: pointer; color: var(--muted); font-weight: 500; user-select: none; }
.nav-item:hover { background: var(--hover); color: var(--text); }
.nav-item.active { background: var(--accent-soft); color: var(--text); }
.nav-item.active svg { color: var(--accent); }
.nav-item svg { width: 18px; height: 18px; flex: none; }
.nav-item .n { flex: 1; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.nav-item .c { font-size: 12px; font-weight: 700; color: var(--text); }
.nav-item.active .c, .nav-item .c.hot { color: var(--accent); }
.nav-item.dragover { outline: 2px dashed var(--accent); }
.side-foot { border-top: 1px solid var(--line); padding: 8px; display: flex; gap: 4px; align-items: center; }
.side-foot .me { flex: 1; display: flex; align-items: center; gap: 9px; padding: 6px 8px; border-radius: 10px; cursor: pointer; min-width: 0; }
.side-foot .me:hover { background: var(--hover); }
.side-foot .me span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-weight: 600; }

/* Liste */
.list { display: flex; flex-direction: column; min-height: 0; border-right: 1px solid var(--line); background: var(--panel); }
.list-top { padding: 12px 12px 8px; display: grid; gap: 9px; border-bottom: 1px solid var(--line); }
.list-title { display: flex; align-items: center; gap: 8px; }
.list-title h2 { margin: 0; font-size: 18px; flex: 1; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; letter-spacing: -.2px; }
.list-title .menu-btn { display: none; }
.search { position: relative; }
.search svg { position: absolute; left: 12px; top: 50%; transform: translateY(-50%); width: 17px; height: 17px; color: var(--faint); }
.search input { padding-left: 38px; height: 40px; }
.chips { display: flex; gap: 6px; overflow-x: auto; scrollbar-width: none; }
.chip { height: 29px; padding: 0 12px; border-radius: 20px; border: 1px solid var(--line); background: transparent; cursor: pointer; font-size: 12.5px; font-weight: 600; color: var(--muted); white-space: nowrap; }
.chip.on { background: var(--accent-soft); border-color: var(--accent); color: var(--text); }
.bulk { display: flex; align-items: center; gap: 2px; padding: 4px 8px; border-bottom: 1px solid var(--line); background: var(--panel2); }
.bulk .cnt { font-weight: 700; padding: 0 8px; flex: 1; font-size: 13px; }
.msgs { flex: 1; overflow: auto; overscroll-behavior: contain; }
.msg { position: relative; display: grid; grid-template-columns: 38px 1fr; gap: 11px; padding: var(--row-pad) 12px var(--row-pad) 14px; border-bottom: 1px solid var(--line); cursor: pointer; user-select: none; }
.msg:hover { background: var(--hover); }
.msg.active { background: var(--accent-soft); }
.msg.unread::before { content: ""; position: absolute; left: 4px; top: 50%; width: 6px; height: 6px; border-radius: 50%; background: var(--accent); transform: translateY(-50%); }
.msg.sel { background: rgba(255, 45, 85, .2); }
.av { width: 38px; height: 38px; border-radius: 50%; display: grid; place-items: center; font-weight: 700; font-size: 14px; color: #fff; flex: none; position: relative; }
.av .tick { position: absolute; inset: 0; border-radius: 50%; background: var(--accent); display: none; place-items: center; }
.msg.sel .av .tick { display: grid; }
.msg-main { min-width: 0; }
.msg-l1 { display: flex; align-items: baseline; gap: 8px; }
.msg-from { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; color: var(--muted); }
.msg.unread .msg-from, .msg.unread .msg-subj { color: var(--text); font-weight: 700; }
.msg-date { font-size: 12px; color: var(--faint); white-space: nowrap; }
.msg.unread .msg-date { color: var(--accent); font-weight: 600; }
.msg-subj { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; color: var(--muted); }
.msg-snip { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; color: var(--faint); font-size: 13px; min-height: 18px; }
.msg-icons { display: inline-flex; gap: 4px; align-items: center; color: var(--faint); }
.msg-icons svg { width: 14px; height: 14px; }
.msg-icons .s { color: var(--star); }
.msg-acc { display: inline-block; width: 8px; height: 8px; border-radius: 50%; margin-right: 6px; vertical-align: middle; }
.msg-quick { position: absolute; right: 8px; top: 50%; transform: translateY(-50%); display: none; gap: 2px; background: var(--panel2); border: 1px solid var(--line); border-radius: 11px; padding: 2px; box-shadow: var(--shadow); }
.msg-quick .ib { width: 32px; height: 32px; }
@media (hover: hover) { .msg:hover .msg-quick { display: flex; } }
.day { padding: 10px 14px 6px; font-size: 11.5px; font-weight: 700; text-transform: uppercase; letter-spacing: .6px; color: var(--faint); background: var(--panel); position: sticky; top: 0; z-index: 1; }
.empty { padding: 60px 24px; text-align: center; color: var(--faint); }
.empty svg { width: 54px; height: 54px; opacity: .5; margin-bottom: 8px; }
.empty b { display: block; color: var(--muted); font-size: 16px; margin-bottom: 4px; }
.more { display: block; margin: 14px auto 22px; }
.skel { padding: 14px; border-bottom: 1px solid var(--line); }
.skel i { display: block; height: 11px; border-radius: 6px; background: linear-gradient(90deg, var(--line), var(--hover), var(--line)); background-size: 200% 100%; animation: sh 1.2s linear infinite; margin: 6px 0; }
@keyframes sh { to { background-position: -200% 0; } }
.pull { text-align: center; font-size: 12px; color: var(--faint); height: 0; overflow: hidden; transition: height .15s; }

/* Leser */
.reader { display: flex; flex-direction: column; min-width: 0; min-height: 0; background: var(--bg); }
.reader-bar { display: flex; align-items: center; gap: 2px; padding: 8px 10px; border-bottom: 1px solid var(--line); background: var(--panel); flex-wrap: wrap; }
.reader-bar .sp { flex: 1; }
.reader-bar .back { display: none; }
.reader-body { flex: 1; overflow: auto; padding: 22px 26px 40px; }
.r-subj { font-size: 22px; font-weight: 750; margin: 0 0 16px; letter-spacing: -.3px; word-break: break-word; }
.r-head { display: flex; gap: 13px; align-items: flex-start; margin-bottom: 14px; }
.r-head .av { width: 44px; height: 44px; font-size: 16px; }
.r-who { flex: 1; min-width: 0; }
.r-who b { font-size: 15px; }
.r-who .addr { color: var(--muted); font-size: 13px; word-break: break-all; }
.r-who .to { color: var(--faint); font-size: 12.5px; margin-top: 2px; word-break: break-word; }
.r-date { color: var(--faint); font-size: 12.5px; white-space: nowrap; }
.banner { display: flex; align-items: center; gap: 10px; padding: 9px 13px; border-radius: 12px; background: var(--panel2); border: 1px solid var(--line); margin-bottom: 14px; font-size: 13px; color: var(--muted); flex-wrap: wrap; }
.banner .grow { flex: 1; }
.mail-frame { width: 100%; border: 0; border-radius: 12px; background: #fff; min-height: 120px; display: block; }
.mail-text { white-space: pre-wrap; word-break: break-word; background: var(--panel); border: 1px solid var(--line); border-radius: 12px; padding: 16px 18px; font-size: 14px; }
.atts { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 16px; }
.att { display: flex; align-items: center; gap: 10px; padding: 10px 12px; border: 1px solid var(--line); background: var(--panel); border-radius: 12px; max-width: 280px; text-decoration: none; color: var(--text); cursor: pointer; }
.att:hover { border-color: var(--accent); }
.att .ext { width: 38px; height: 38px; border-radius: 9px; background: var(--accent-soft); color: var(--accent); display: grid; place-items: center; font-size: 11px; font-weight: 800; flex: none; text-transform: uppercase; overflow: hidden; }
.att .ext img { width: 100%; height: 100%; object-fit: cover; }
.att .nm { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-weight: 600; font-size: 13px; }
.att small { color: var(--faint); font-size: 12px; }
.reply-row { display: flex; gap: 10px; margin-top: 22px; flex-wrap: wrap; }
.reader-empty { flex: 1; display: grid; place-content: center; text-align: center; color: var(--faint); gap: 10px; padding: 30px; }
.reader-empty img { width: 92px; height: 92px; margin: 0 auto; opacity: .85; filter: drop-shadow(0 0 22px rgba(255, 45, 85, .35)); }
.reader-empty b { color: var(--muted); font-size: 17px; }

/* Verfassen */
.compose { position: fixed; right: 24px; bottom: 0; width: min(640px, calc(100vw - 32px)); height: min(640px, calc(100vh - 60px)); background: var(--panel); border: 1px solid var(--line); border-bottom: 0; border-radius: 16px 16px 0 0; box-shadow: var(--shadow); display: flex; flex-direction: column; z-index: 40; animation: up .2s ease-out; }
.compose.max { right: 50%; transform: translateX(50%); width: min(1000px, calc(100vw - 32px)); height: calc(100vh - 40px); }
.compose.min { height: 48px; overflow: hidden; }
@keyframes up { from { transform: translateY(30px); opacity: 0; } }
.compose.max { animation: none; }
.c-head { display: flex; align-items: center; gap: 4px; padding: 6px 8px 6px 16px; background: var(--panel2); border-radius: 16px 16px 0 0; border-bottom: 1px solid var(--line); cursor: pointer; }
.c-head b { flex: 1; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.c-fields { padding: 4px 14px 0; }
.c-line { display: flex; align-items: center; gap: 8px; border-bottom: 1px solid var(--line); min-height: 42px; flex-wrap: wrap; padding: 3px 0; position: relative; }
.c-line > label { color: var(--faint); font-size: 13px; width: 46px; flex: none; }
.c-line select, .c-line > input { flex: 1; border: 0; background: transparent; outline: none; height: 34px; min-width: 120px; }
.c-line select option { background: var(--panel); }
.c-line .tog { font-size: 12.5px; color: var(--muted); cursor: pointer; background: none; border: 0; padding: 4px 6px; }
.rcpt { flex: 1; display: flex; flex-wrap: wrap; gap: 5px; align-items: center; min-width: 0; }
.rcpt input { flex: 1; min-width: 140px; border: 0; background: transparent; outline: none; height: 32px; }
.pill { display: inline-flex; align-items: center; gap: 5px; height: 27px; padding: 0 5px 0 10px; border-radius: 20px; background: var(--hover); font-size: 13px; max-width: 100%; }
.pill.bad { background: rgba(239, 68, 68, .2); color: #fca5a5; }
.pill span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.pill button { border: 0; background: none; cursor: pointer; color: var(--muted); padding: 0 3px; font-size: 15px; line-height: 1; }
.suggest { position: absolute; left: 46px; right: 0; top: 100%; background: var(--panel2); border: 1px solid var(--line); border-radius: 12px; box-shadow: var(--shadow); z-index: 5; overflow: hidden; }
.suggest div { padding: 8px 12px; cursor: pointer; }
.suggest div.on, .suggest div:hover { background: var(--accent-soft); }
.suggest small { color: var(--faint); margin-left: 6px; }
.toolbar { display: flex; gap: 2px; padding: 6px 10px; border-bottom: 1px solid var(--line); flex-wrap: wrap; }
.toolbar .ib { width: 32px; height: 32px; }
.editor { flex: 1; overflow: auto; padding: 14px 16px; outline: none; font-size: 14.5px; line-height: 1.55; word-break: break-word; }
.editor:empty::before { content: attr(data-ph); color: var(--faint); }
.editor blockquote { margin: 10px 0 0; padding-left: 12px; border-left: 3px solid var(--line); color: var(--muted); }
.editor img { max-width: 100%; }
.c-atts { display: flex; flex-wrap: wrap; gap: 6px; padding: 0 14px 8px; }
.c-atts .pill { background: var(--panel2); border: 1px solid var(--line); }
.c-foot { display: flex; align-items: center; gap: 8px; padding: 10px 12px calc(10px + var(--sab)); border-top: 1px solid var(--line); flex-wrap: wrap; }
.c-foot .sp { flex: 1; }
.c-drop { position: absolute; inset: 0; background: rgba(255, 45, 85, .12); border: 2px dashed var(--accent); border-radius: 16px 16px 0 0; display: grid; place-items: center; font-weight: 700; pointer-events: none; z-index: 3; }

/* Dialoge */
.overlay { position: fixed; inset: 0; background: rgba(5, 5, 10, .6); backdrop-filter: blur(4px); z-index: 60; display: grid; place-items: center; padding: 16px; animation: fade .15s; }
@keyframes fade { from { opacity: 0; } }
.dialog { width: min(560px, 100%); max-height: calc(100vh - 32px); background: var(--panel); border: 1px solid var(--line); border-radius: 20px; box-shadow: var(--shadow); display: flex; flex-direction: column; overflow: hidden; }
.dialog.wide { width: min(880px, 100%); height: min(720px, calc(100vh - 32px)); }
.d-head { display: flex; align-items: center; gap: 10px; padding: 16px 16px 12px 22px; border-bottom: 1px solid var(--line); }
.d-head h3 { margin: 0; font-size: 18px; flex: 1; }
.d-body { padding: 18px 22px; overflow: auto; flex: 1; }
.d-foot { display: flex; justify-content: flex-end; gap: 10px; padding: 12px 22px 18px; border-top: 1px solid var(--line); flex-wrap: wrap; }
.tabs-wrap { display: grid; grid-template-columns: 228px 1fr; flex: 1; min-height: 0; }
.tabs { border-right: 1px solid var(--line); padding: 10px 8px; display: flex; flex-direction: column; gap: 2px; background: var(--bg2); overflow: auto; }
.tabs .nav-item { padding: 9px 12px; }
.tab-body { overflow: auto; padding: 20px 24px 30px; }
.tab-body h4 { margin: 0 0 14px; font-size: 16px; }
.card { border: 1px solid var(--line); background: var(--panel2); border-radius: 14px; padding: 14px 16px; margin-bottom: 12px; }
.acc-card { display: flex; gap: 12px; align-items: center; }
.acc-card .dot { width: 12px; height: 12px; border-radius: 50%; flex: none; }
.acc-card .grow { min-width: 0; }
.acc-card b { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.acc-card small { color: var(--faint); display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.tbl { width: 100%; border-collapse: collapse; font-size: 13.5px; }
.tbl th { text-align: left; color: var(--faint); font-weight: 600; font-size: 12px; padding: 6px 8px; border-bottom: 1px solid var(--line); }
.tbl td { padding: 9px 8px; border-bottom: 1px solid var(--line); vertical-align: middle; }
.badge { display: inline-block; padding: 2px 8px; border-radius: 20px; font-size: 11.5px; font-weight: 700; background: var(--accent-soft); color: var(--accent); }
.badge.gray { background: var(--hover); color: var(--muted); }
.colors { display: flex; gap: 8px; flex-wrap: wrap; }
.colors button { width: 28px; height: 28px; border-radius: 50%; border: 2px solid transparent; cursor: pointer; }
.colors button.on { border-color: var(--text); }
.steps { display: flex; gap: 6px; margin-bottom: 16px; }
.steps i { flex: 1; height: 4px; border-radius: 4px; background: var(--line); }
.steps i.on { background: var(--accent); }
.provider-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(118px, 1fr)); gap: 8px; margin-bottom: 14px; }
.provider-grid button { height: 44px; border-radius: 11px; border: 1px solid var(--line); background: var(--panel2); cursor: pointer; font-weight: 600; font-size: 13px; }
.provider-grid button:hover { border-color: var(--accent); }
details.adv summary { cursor: pointer; color: var(--muted); font-weight: 600; margin: 4px 0 12px; }

/* Toasts / Menüs */
.toasts { position: fixed; left: 50%; bottom: calc(22px + var(--sab)); transform: translateX(-50%); display: grid; gap: 8px; z-index: 90; width: min(440px, calc(100vw - 32px)); }
.toast { display: flex; align-items: center; gap: 10px; background: var(--panel2); border: 1px solid var(--line); border-radius: 13px; padding: 11px 14px; box-shadow: var(--shadow); animation: up .2s; font-weight: 500; }
.toast.err { border-color: rgba(239, 68, 68, .5); }
.toast .grow { flex: 1; }
.toast button { background: none; border: 0; color: var(--accent); font-weight: 700; cursor: pointer; }
.menu { position: fixed; background: var(--panel2); border: 1px solid var(--line); border-radius: 13px; box-shadow: var(--shadow); padding: 5px; z-index: 80; min-width: 200px; max-height: 60vh; overflow: auto; animation: fade .1s; }
.menu div { padding: 8px 12px; border-radius: 9px; cursor: pointer; display: flex; gap: 10px; align-items: center; white-space: nowrap; }
.menu div:hover { background: var(--hover); }
.menu div svg { width: 17px; height: 17px; color: var(--muted); }
.menu hr { border: 0; border-top: 1px solid var(--line); margin: 4px 0; }
.menu .lbl { font-size: 11.5px; color: var(--faint); cursor: default; padding: 6px 12px 3px; }
.menu .lbl:hover { background: none; }
.fab { display: none; position: fixed; right: 18px; bottom: calc(18px + var(--sab)); width: 58px; height: 58px; border-radius: 18px; z-index: 30; padding: 0; }
.fab svg { width: 24px; height: 24px; }
.scrim { display: none; }
.netbar { position: fixed; top: var(--sat); left: 0; right: 0; height: 3px; z-index: 95; overflow: hidden; pointer-events: none; }
.netbar i { display: block; height: 100%; width: 30%; background: var(--accent); animation: load 1s ease-in-out infinite; }
.offline { position: fixed; top: calc(8px + var(--sat)); left: 50%; transform: translateX(-50%); z-index: 96; background: var(--warn); color: #111; padding: 5px 14px; border-radius: 20px; font-weight: 700; font-size: 12.5px; }

/* ================================================================ Modernes Design (v1.1) */
::selection { background: rgba(255, 51, 102, .35); }
* { scrollbar-width: thin; scrollbar-color: rgba(128, 128, 160, .35) transparent; }
::-webkit-scrollbar { width: 10px; height: 10px; }
::-webkit-scrollbar-thumb { background: rgba(128, 128, 160, .3); border-radius: 10px; border: 3px solid transparent; background-clip: padding-box; }
::-webkit-scrollbar-thumb:hover { background-color: rgba(128, 128, 160, .5); }
::-webkit-scrollbar-track { background: transparent; }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }

body { background:
  radial-gradient(1200px 700px at -10% -20%, rgba(255, 51, 102, .10), transparent 60%),
  radial-gradient(1000px 700px at 110% 120%, rgba(139, 92, 246, .10), transparent 60%), var(--bg); }
#root { background: transparent; }

/* Buttons */
.btn { height: 40px; border-radius: 12px; border-color: var(--line); background: var(--panel2); letter-spacing: -.1px; transition: background .18s, border-color .18s, transform .08s, box-shadow .18s, filter .18s; }
.btn:hover { border-color: rgba(255, 255, 255, .14); }
[data-theme="light"] .btn:hover { border-color: rgba(20, 20, 60, .18); }
.btn.primary { background: var(--grad); background-size: 140% 140%; background-position: 0 0; box-shadow: 0 8px 24px -6px rgba(255, 51, 102, .55), inset 0 1px 0 rgba(255, 255, 255, .2); }
.btn.primary:hover { filter: brightness(1.07) saturate(1.08); background-position: 100% 100%; box-shadow: 0 12px 30px -6px rgba(255, 51, 102, .6), inset 0 1px 0 rgba(255, 255, 255, .25); }
.btn.sm { height: 32px; border-radius: 10px; }
.btn.sm svg { width: 16px; height: 16px; }
.ib { border-radius: 11px; transition: background .15s, color .15s; }

/* Felder */
.input, .field input, .field select, .field textarea { height: 44px; border-radius: 12px; background: var(--bg2); border-color: var(--line); }
.input:hover, .field input:hover, .field select:hover, .field textarea:hover { border-color: rgba(128, 128, 160, .35); }
.field > span { font-size: 12.5px; letter-spacing: .1px; }

/* Login */
.auth { position: relative; overflow: auto; background:
  radial-gradient(800px 520px at 12% 8%, rgba(255, 51, 102, .30), transparent 62%),
  radial-gradient(760px 560px at 92% 92%, rgba(139, 92, 246, .30), transparent 62%),
  radial-gradient(500px 400px at 70% 10%, rgba(255, 140, 90, .12), transparent 60%), var(--bg); }
.auth::before { content: ""; position: fixed; inset: 0; pointer-events: none; opacity: .35;
  background-image: linear-gradient(rgba(255, 255, 255, .035) 1px, transparent 1px), linear-gradient(90deg, rgba(255, 255, 255, .035) 1px, transparent 1px);
  background-size: 44px 44px; mask-image: radial-gradient(ellipse at center, #000 30%, transparent 75%); -webkit-mask-image: radial-gradient(ellipse at center, #000 30%, transparent 75%); }
.auth-card { position: relative; width: min(430px, 100%); background: var(--glass); backdrop-filter: blur(22px) saturate(1.3); -webkit-backdrop-filter: blur(22px) saturate(1.3); border: 1px solid rgba(255, 255, 255, .09); border-radius: 26px; padding: 36px 32px 26px; box-shadow: var(--shadow); animation: pop .35s cubic-bezier(.2, .9, .3, 1.2); }
[data-theme="light"] .auth-card { border-color: rgba(20, 20, 60, .08); }
.auth-logo { margin-bottom: 22px; }
.auth-logo img { width: 56px; height: 56px; }
.auth-logo h1 { font-size: 24px; font-weight: 800; background: var(--grad); -webkit-background-clip: text; background-clip: text; color: transparent; }
.auth-title { margin: 0 0 18px; font-size: 18px; font-weight: 700; letter-spacing: -.2px; }
@keyframes pop { from { opacity: 0; transform: translateY(14px) scale(.97); } }

/* Seitenleiste */
.app { gap: 0; }
.side { background: var(--glass); backdrop-filter: blur(18px); -webkit-backdrop-filter: blur(18px); border-right: 1px solid var(--line); }
.brand { padding: 18px 18px 12px; }
.brand b { font-weight: 800; letter-spacing: -.3px; }
.compose-btn { margin: 6px 14px 14px; height: 48px; border-radius: 16px; font-size: 15px; }
.nav { padding: 0 10px 12px; }
.nav-head { padding: 12px 10px 6px; }
.nav-head .t { font-weight: 650; }
.nav-head .shared { display: inline-grid; place-items: center; color: var(--accent2); }
.nav-head .shared svg { width: 14px; height: 14px; }
.nav-item { position: relative; padding: 8px 12px; border-radius: 12px; margin: 1px 0; transition: background .15s, color .15s; }
.nav-item.active { background: linear-gradient(90deg, rgba(255, 51, 102, .18), rgba(139, 92, 246, .08)); color: var(--text); font-weight: 600; }
.nav-item.active::before { content: ""; position: absolute; left: 0; top: 8px; bottom: 8px; width: 3px; border-radius: 3px; background: var(--grad); }
.nav-item .c { min-width: 22px; height: 20px; padding: 0 7px; border-radius: 10px; display: inline-grid; place-items: center; font-size: 11.5px; background: var(--hover); }
.nav-item .c.hot, .nav-item.active .c { background: var(--accent); color: #fff; }
.side-foot { padding: 10px; }
.side-foot .me { border-radius: 12px; }

/* Liste */
.list { background: color-mix(in srgb, var(--panel) 88%, transparent); }
.list-top { padding: 14px 14px 10px; gap: 10px; }
.list-title h2 { font-size: 20px; font-weight: 800; letter-spacing: -.4px; }
.search input { height: 42px; border-radius: 14px; background: var(--bg2); }
.chip { height: 30px; border-radius: 999px; transition: background .15s, border-color .15s, color .15s; }
.chip:hover { color: var(--text); border-color: rgba(128, 128, 160, .4); }
.chip.on { background: var(--grad); border-color: transparent; color: #fff; box-shadow: 0 4px 14px -4px rgba(255, 51, 102, .5); }
.msgs { padding: 4px 6px; }
.msg { margin: 2px 0; border-bottom: 0; border-radius: 14px; padding: var(--row-pad) 12px var(--row-pad) 16px; transition: background .12s; }
.msg.active { background: linear-gradient(90deg, rgba(255, 51, 102, .16), rgba(139, 92, 246, .07)); box-shadow: inset 0 0 0 1px rgba(255, 51, 102, .25); }
.msg.unread::before { left: 5px; width: 7px; height: 7px; background: var(--grad); box-shadow: 0 0 10px rgba(255, 51, 102, .7); }
.msg.sel { background: rgba(255, 51, 102, .18); }
.av { box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .12); }
.day { background: transparent; backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px); padding: 12px 12px 6px; border-radius: 10px; }
.msg-quick { border-radius: 12px; background: var(--glass); backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px); }

/* Leser */
.reader { background: transparent; }
.reader-bar { background: var(--glass); backdrop-filter: blur(16px); -webkit-backdrop-filter: blur(16px); padding: 8px 12px; }
.reader-body { padding: 26px 30px 44px; }
.r-subj { font-size: 24px; font-weight: 800; letter-spacing: -.5px; }
.mail-frame { border-radius: 16px; box-shadow: var(--shadow-sm); }
.mail-text { border-radius: 16px; }
.att { border-radius: 14px; transition: border-color .15s, transform .1s; }
.att:hover { transform: translateY(-1px); }
.reader-empty img { width: 100px; height: 100px; }

/* Verfassen */
.compose { border-radius: 20px 20px 0 0; background: var(--panel); }
.c-head { border-radius: 20px 20px 0 0; }

/* Dialoge */
.overlay { background: rgba(4, 4, 10, .55); backdrop-filter: blur(8px) saturate(1.2); -webkit-backdrop-filter: blur(8px) saturate(1.2); }
.dialog { border-radius: 24px; border-color: rgba(255, 255, 255, .08); animation: pop .22s cubic-bezier(.2, .9, .3, 1.15); }
[data-theme="light"] .dialog { border-color: rgba(20, 20, 60, .08); }
.d-head { padding: 18px 18px 14px 24px; }
.d-head h3 { font-weight: 800; letter-spacing: -.3px; }
.d-body { padding: 20px 24px; }
.d-foot { padding: 14px 24px 20px; }
.tabs { background: transparent; padding: 12px 10px; }
.tab-body { padding: 22px 26px 32px; }
.tab-body h4 { font-size: 17px; font-weight: 800; letter-spacing: -.3px; }
.card { border-radius: 16px; background: var(--panel2); border-color: var(--line); }
.badge { display: inline-flex; align-items: center; gap: 4px; padding: 2px 9px; }
.badge svg { width: 12px; height: 12px; }
.menu { border-radius: 14px; background: var(--glass); backdrop-filter: blur(18px) saturate(1.3); -webkit-backdrop-filter: blur(18px) saturate(1.3); padding: 6px; }
.menu div { border-radius: 10px; }
.toast { border-radius: 14px; background: var(--glass); backdrop-filter: blur(16px); -webkit-backdrop-filter: blur(16px); }
.switch input:checked + i { background: var(--grad); }
.fab { border-radius: 20px; }

/* Admin: Benutzer-Karten + Freigaben */
.grid-2c { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.users { display: grid; gap: 10px; }
.user-card { display: flex; gap: 14px; align-items: flex-start; padding: 14px 16px; border: 1px solid var(--line); border-radius: 16px; background: var(--panel2); transition: border-color .15s, transform .1s; }
.user-card:hover { border-color: rgba(255, 51, 102, .35); }
.user-card .av { width: 42px; height: 42px; }
.user-card .grow { flex: 1; min-width: 0; }
.uc-top { display: flex; align-items: center; gap: 6px; flex-wrap: wrap; }
.uc-top b { font-size: 15px; overflow: hidden; text-overflow: ellipsis; }
.uc-meta { display: flex; flex-wrap: wrap; gap: 6px 14px; margin-top: 6px; font-size: 12.5px; color: var(--muted); }
.uc-meta span { display: inline-flex; align-items: center; gap: 5px; }
.uc-meta svg { width: 14px; height: 14px; color: var(--faint); }
.uc-chips { display: flex; flex-wrap: wrap; gap: 5px; margin-top: 8px; }
.mini-chip { font-size: 11.5px; padding: 2px 9px; border-radius: 999px; background: rgba(139, 92, 246, .14); color: var(--text); border: 1px solid rgba(139, 92, 246, .25); }
.user-card { flex-wrap: wrap; }
.uc-actions { flex-wrap: wrap; justify-content: flex-end; }
.uc-mb-wrap { flex-basis: 100%; padding-left: 56px; }
@media (max-width: 860px) { .uc-mb-wrap { padding-left: 0; } }
.uc-mb { margin-top: 2px; border: 1px solid var(--line); border-radius: 12px; background: var(--bg2); }
.uc-mb summary { cursor: pointer; padding: 8px 12px; font-size: 13px; font-weight: 600; color: var(--muted); user-select: none; font-family: "Inter", "Segoe UI Emoji", "Apple Color Emoji", sans-serif; }
.uc-mb[open] summary { border-bottom: 1px solid var(--line); color: var(--text); }
.uc-mb > div:not(.hint) { padding: 6px 10px; }
.uc-mb > .hint { padding: 0 12px 10px; }
.uc-mb-h { font-size: 11px; font-weight: 700; text-transform: uppercase; letter-spacing: .5px; color: var(--faint); margin: 4px 2px 6px; }
.uc-mb-row { display: flex; align-items: center; gap: 10px; padding: 7px 4px; border-radius: 10px; }
.uc-mb-row:hover { background: var(--hover); }
.uc-mb-row .grow { min-width: 0; }
.uc-mb-row b { display: block; font-size: 13.5px; font-weight: 600; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.uc-mb-row small { display: block; font-size: 12px; color: var(--faint); }
.uc-mb-ico { width: 30px; height: 30px; flex: none; display: inline-grid; place-items: center; font-size: 16px; border-radius: 8px; background: var(--hover); }
.uc-mb-ico.has-brand { background: #fff; padding: 4px; }
.uc-mb-empty { margin-top: 8px; }
.uc-actions { display: flex; gap: 4px; align-items: center; flex: none; }
.access { border: 1px solid var(--line); border-radius: 16px; padding: 12px; background: var(--bg2); max-height: 340px; overflow: auto; }
.access-tools { display: flex; align-items: center; gap: 6px; margin-bottom: 6px; }
.access-tools .grow { flex: 1; }
.access-owner { font-size: 11.5px; font-weight: 700; text-transform: uppercase; letter-spacing: .6px; color: var(--faint); margin: 10px 2px 8px; }
.access-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 8px; }
.access-item { position: relative; display: flex; align-items: center; gap: 10px; padding: 10px 12px; border-radius: 13px; border: 1px solid var(--line); background: var(--panel2); cursor: pointer; user-select: none; transition: border-color .15s, background .15s; }
.access-item:hover { border-color: rgba(128, 128, 160, .4); }
.access-item input, .field .access-item input { position: absolute; opacity: 0; pointer-events: none; width: 1px; height: 1px; padding: 0; border: 0; left: 0; top: 0; }
.access { overflow-x: hidden; }
.access-item .dot { width: 10px; height: 10px; border-radius: 50%; flex: none; }
.access-item .grow { flex: 1; min-width: 0; }
.access-item b { display: block; font-size: 13px; font-weight: 600; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.access-item small { display: block; font-size: 11.5px; color: var(--faint); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.access-item .tick { width: 20px; height: 20px; border-radius: 7px; border: 1.5px solid rgba(128, 128, 160, .5); display: grid; place-items: center; flex: none; transition: .15s; }
.access-item .tick svg { width: 13px; height: 13px; color: #fff; opacity: 0; stroke-width: 3; }
.access-item.on { border-color: rgba(255, 51, 102, .55); background: linear-gradient(90deg, rgba(255, 51, 102, .12), rgba(139, 92, 246, .06)); }
.access-item.on .tick { background: var(--grad); border-color: transparent; }
.access-item.on .tick svg { opacity: 1; }
.access-item:has(input:focus-visible) { outline: 2px solid var(--accent); outline-offset: 2px; }
.cred { display: grid; gap: 8px; }
.cred div { display: grid; grid-template-columns: 110px 1fr; align-items: center; gap: 10px; padding: 10px 12px; border: 1px solid var(--line); border-radius: 12px; background: var(--bg2); }
.cred span { font-size: 12.5px; color: var(--muted); font-weight: 600; }
.cred code { font-family: ui-monospace, "Cascadia Code", Consolas, monospace; font-size: 13.5px; word-break: break-all; user-select: all; }

/* Übersicht v1.2: Seitenleiste, Liste, Leser */
.nav-head .head-c { min-width: 22px; height: 20px; padding: 0 7px; border-radius: 10px; display: inline-grid; place-items: center; font-size: 11.5px; font-weight: 700; background: var(--accent); color: #fff; letter-spacing: 0; }
.nav-item.more-folders { color: var(--faint); font-size: 13px; }
.nav-item.more-folders svg { width: 16px; height: 16px; }
.list-title h2 { white-space: normal; }
.list-sub { display: block; font-size: 12.5px; font-weight: 500; color: var(--faint); letter-spacing: 0; margin-top: 2px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.msg { grid-template-columns: 40px 1fr; }
.msg.unread { background: linear-gradient(90deg, color-mix(in srgb, var(--acc) 9%, transparent), transparent 70%); }
.msg.unread::before { left: 0; top: 10px; bottom: 10px; width: 3px; height: auto; border-radius: 3px; transform: none; background: var(--acc); box-shadow: none; }
.msg-from { font-size: 14px; }
.msg-l2 { display: flex; align-items: center; gap: 8px; min-width: 0; margin-top: 1px; }
.msg-l2 .msg-subj { flex: 1; min-width: 0; }
.msg:not(.unread) .msg-subj { color: var(--muted); }
.msg.unread .msg-subj { font-weight: 650; }
.msg-snip { margin-top: 1px; min-height: 0; }
.msg-snip:empty { display: none; }
.msg-meta { margin-top: 5px; display: flex; gap: 6px; }
.acc-chip { display: inline-flex; align-items: center; gap: 6px; max-width: 100%; height: 22px; padding: 0 9px 0 7px; border-radius: 999px; font-size: 11.5px; font-weight: 600; color: var(--text);
  background: color-mix(in srgb, var(--c, var(--accent)) 16%, transparent); border: 1px solid color-mix(in srgb, var(--c, var(--accent)) 35%, transparent); overflow: hidden; white-space: nowrap; text-overflow: ellipsis; }
.acc-chip i { width: 7px; height: 7px; border-radius: 50%; background: var(--c, var(--accent)); flex: none; }
.day { display: flex; align-items: baseline; gap: 8px; }
.day small { font-size: 11px; font-weight: 600; letter-spacing: 0; text-transform: none; color: var(--faint); opacity: .8; }
.r-top { display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: 10px; }
.r-card { padding: 14px 16px; border: 1px solid var(--line); border-radius: 16px; background: var(--panel); }
.r-who .addr { display: block; }
.r-who .to .lbl { display: inline-block; min-width: 26px; font-weight: 700; color: var(--muted); margin-right: 6px; font-size: 11.5px; text-transform: uppercase; letter-spacing: .4px; }

/* E-Mail bestätigen */
.badge.ok { background: rgba(34, 197, 94, .15); color: #4ade80; }
[data-theme="light"] .badge.ok { color: #15803d; }
.badge.warn { background: rgba(245, 158, 11, .15); color: #fbbf24; }
[data-theme="light"] .badge.warn { color: #b45309; }
.uc-email { display: flex; align-items: center; gap: 6px; margin-top: 4px; font-size: 13px; color: var(--muted); flex-wrap: wrap; min-width: 0; }
.uc-email svg { width: 14px; height: 14px; color: var(--faint); }
.uc-email > span:first-of-type { overflow: hidden; text-overflow: ellipsis; }
.email-card { margin: 4px 0 12px; }
.verify-box { margin-top: 14px; padding: 14px; border-radius: 14px; border: 1px dashed rgba(245, 158, 11, .5); background: rgba(245, 158, 11, .07); }
.code-inp { letter-spacing: 6px; font-weight: 700; font-size: 18px !important; text-align: center; }
.field > span.row { display: flex; gap: 8px; align-items: center; }
.forgot { font-size: 12.5px; font-weight: 600; text-decoration: none; }
.forgot:hover { text-decoration: underline; }

/* ================================================================ v1.3 – noch moderner */
@font-face { font-family: "Inter"; font-style: normal; font-weight: 100 900; font-display: swap; src: url("fonts/inter-latin.woff2") format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+2074, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }
@font-face { font-family: "Inter"; font-style: normal; font-weight: 100 900; font-display: swap; src: url("fonts/inter-latin-ext.woff2") format("woff2");
  unicode-range: U+0100-02AF, U+0304, U+0308, U+0329, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF; }
:root { font-family: "Inter", "Segoe UI Variable Text", "Segoe UI", system-ui, -apple-system, Roboto, Arial, sans-serif; font-feature-settings: "cv11", "ss01", "ss03"; }
body { letter-spacing: -.006em; }
h1, h2, h3, h4, .brand b, .list-title h2, .r-subj { letter-spacing: -.025em; }

/* Lebendiger Hintergrund (Aurora) */
body::before { content: ""; position: fixed; inset: -20%; z-index: -1; pointer-events: none;
  background:
    radial-gradient(38% 32% at 18% 22%, rgba(255, 51, 102, .16), transparent 70%),
    radial-gradient(34% 30% at 82% 78%, rgba(139, 92, 246, .16), transparent 70%),
    radial-gradient(28% 26% at 70% 18%, rgba(56, 189, 248, .08), transparent 70%);
  filter: blur(20px); animation: aurora 28s ease-in-out infinite alternate; }
@keyframes aurora { 0% { transform: translate3d(0, 0, 0) rotate(0deg); } 50% { transform: translate3d(3%, -2%, 0) rotate(4deg); } 100% { transform: translate3d(-3%, 2%, 0) rotate(-3deg); } }
html { background:
  radial-gradient(1200px 700px at -10% -20%, rgba(255, 51, 102, .10), transparent 60%),
  radial-gradient(1000px 700px at 110% 120%, rgba(139, 92, 246, .10), transparent 60%), var(--bg); background-attachment: fixed; }
body, #root, .app { background: transparent; }

/* Avatare */
.av { box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .18), 0 4px 12px -4px rgba(0, 0, 0, .45); text-shadow: 0 1px 2px rgba(0, 0, 0, .25); letter-spacing: 0; }

/* Suche mit Tastenhinweis */
.search kbd { position: absolute; right: 10px; top: 50%; transform: translateY(-50%); font: 600 11px/1 "Inter", sans-serif; color: var(--faint); border: 1px solid var(--line); border-radius: 6px; padding: 4px 7px; background: var(--panel2); pointer-events: none; }
.search input:focus ~ kbd { opacity: 0; }

/* Schreiben-Button mit Glanz */
.compose-btn { position: relative; overflow: hidden; }
.compose-btn::after { content: ""; position: absolute; inset: 0; background: linear-gradient(110deg, transparent 30%, rgba(255, 255, 255, .35) 50%, transparent 70%); transform: translateX(-120%); transition: transform .7s ease; }
.compose-btn:hover::after { transform: translateX(120%); }

/* Tages-Überschriften als Pillen */
.day { padding: 14px 8px 6px; }
.day span { display: inline-block; padding: 3px 10px; border-radius: 999px; background: var(--hover); color: var(--muted); }

/* Leser */
.reader-body > * { max-width: 880px; margin-left: auto; margin-right: auto; }
.reader-body .mail-frame { max-width: 880px; }
.reader-empty img { animation: floaty 5s ease-in-out infinite; }
@keyframes floaty { 50% { transform: translateY(-8px); } }

/* Desktop: schwebende Paneele */
@media (min-width: 861px) {
  .app { gap: 10px; padding: calc(10px + var(--sat)) 10px 10px; }
  .side, .list, .reader { border: 1px solid var(--line); border-radius: 22px; overflow: hidden; box-shadow: var(--shadow-sm); }
  .side { background: var(--glass); }
  .list { background: var(--glass); backdrop-filter: blur(18px); -webkit-backdrop-filter: blur(18px); border-right: 1px solid var(--line); }
  .reader { background: color-mix(in srgb, var(--panel) 70%, transparent); backdrop-filter: blur(18px); -webkit-backdrop-filter: blur(18px); }
  .reader-bar { margin: 10px 12px 0; border: 1px solid var(--line); border-radius: 16px; padding: 5px 8px; gap: 2px; background: var(--panel2); }
  .reader-bar .ib { width: 38px; height: 38px; }
  .msg { transition: background .14s, transform .14s, box-shadow .14s; }
  .msg:hover { transform: translateX(2px); }
  .msg.active { box-shadow: inset 0 0 0 1px rgba(255, 51, 102, .3), 0 6px 18px -8px rgba(255, 51, 102, .35); }
  .nav-head:hover .t { color: var(--text); }
}
[data-theme="light"] body::before { opacity: .7; }
[data-theme="light"] .day span { background: rgba(20, 20, 60, .05); }

/* ================================================================ v1.5 – Feinschliff */
/* Postfach-Abzeichen in der Seitenleiste */
.nav-head { text-transform: none; letter-spacing: 0; padding: 12px 8px 6px; }
.acc-badge { width: 22px; height: 22px; border-radius: 7px; display: inline-grid; place-items: center; flex: none; font-size: 11.5px; font-weight: 800; color: #fff;
  background: linear-gradient(135deg, var(--c), color-mix(in srgb, var(--c) 55%, #000)); box-shadow: 0 3px 10px -3px color-mix(in srgb, var(--c) 70%, transparent); }
.nav-head .t { font-size: 13px; color: var(--text); opacity: .85; }
.nav-sec { border-radius: 16px; padding: 2px 4px 4px; margin-top: 6px; transition: background .15s; }
.nav-sec:hover { background: color-mix(in srgb, var(--hover) 60%, transparent); }
.nav-sec.closed { padding-bottom: 2px; }

/* Schnell antworten */
.quick-reply { display: flex; align-items: center; gap: 12px; margin-top: 22px; padding: 10px 10px 10px 12px; border: 1px solid var(--line); border-radius: 18px; background: var(--panel2); cursor: text; transition: border-color .15s, box-shadow .15s; }
.quick-reply:hover { border-color: rgba(255, 51, 102, .45); box-shadow: 0 0 0 4px var(--accent-soft); }
.quick-reply .av { width: 34px; height: 34px; font-size: 13px; }
.qr-ph { flex: 1; color: var(--faint); }
.qr-send { width: 38px; height: 38px; border-radius: 12px; display: grid; place-items: center; color: #fff; background: var(--grad); box-shadow: 0 6px 16px -6px rgba(255, 51, 102, .6); }
.qr-send svg { width: 18px; height: 18px; }
.reply-row { margin-top: 12px; }
.reply-row .btn { background: transparent; }

/* Schreiben-Fenster */
.compose { border-radius: 22px 22px 0 0; border-color: rgba(255, 255, 255, .09); background: color-mix(in srgb, var(--panel) 92%, transparent); backdrop-filter: blur(22px) saturate(1.2); -webkit-backdrop-filter: blur(22px) saturate(1.2);
  box-shadow: 0 30px 80px -20px rgba(0, 0, 0, .7), 0 0 0 1px rgba(255, 255, 255, .04); }
.c-head { position: relative; border-radius: 22px 22px 0 0; padding: 10px 8px 10px 18px; background: transparent; }
.c-head::after { content: ""; position: absolute; left: 0; right: 0; bottom: -1px; height: 2px; background: var(--grad); opacity: .8; }
.c-head b { font-size: 15px; font-weight: 750; }
.c-fields { padding: 6px 16px 0; }
.c-line { border-bottom-color: var(--line); min-height: 46px; }
.c-line > label { font-weight: 600; font-size: 13px; text-transform: none; letter-spacing: 0; width: 92px; color: var(--muted); white-space: nowrap; font-family: "Inter", "Segoe UI Emoji", "Apple Color Emoji", "Noto Color Emoji", sans-serif; }
.suggest { left: 92px; }
.c-line .subj-emo { width: 34px; height: 34px; }
.pill { background: color-mix(in srgb, var(--accent) 14%, var(--hover)); border: 1px solid color-mix(in srgb, var(--accent) 25%, transparent); }
.toolbar { margin: 8px 12px 0; border: 1px solid var(--line); border-radius: 14px; padding: 4px; background: var(--panel2); gap: 0; width: fit-content; max-width: calc(100% - 24px); }
.editor { padding: 16px 18px; font-size: 15px; }
.c-foot { padding: 12px 14px calc(12px + var(--sab)); }
.c-foot .btn.primary { height: 44px; padding: 0 22px; border-radius: 14px; font-size: 15px; }
.suggest { border-radius: 14px; background: var(--glass); backdrop-filter: blur(16px); -webkit-backdrop-filter: blur(16px); }

/* Einstellungen */
.dialog.wide { height: min(760px, calc(100vh - 32px)); }
.tabs .nav-item { border-radius: 12px; }
.tabs .nav-item svg { padding: 6px; width: 30px; height: 30px; border-radius: 9px; background: var(--hover); }
.tabs .nav-item.active svg { background: var(--grad); color: #fff; }
.card { transition: border-color .15s; }
.card:hover { border-color: rgba(128, 128, 160, .3); }

/* Toasts mit Symbol */
.toast { padding: 10px 12px; }
.t-ico { width: 24px; height: 24px; border-radius: 50%; display: grid; place-items: center; flex: none; font-weight: 800; font-size: 13px; color: #fff; background: var(--ok); }
.toast.err .t-ico { background: var(--err); }

/* Liste: Avatare etwas größer, Hover-Aktionen schöner */
.msg .av { width: 40px; height: 40px; }
.msg-quick { border-radius: 14px; padding: 3px; }

/* Firmen-Logos im Avatar */
.av { overflow: hidden; }
.av .av-logo { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: contain; padding: 18%; background: #fff; border-radius: 50%; opacity: 0; transition: opacity .2s; }
.av.has-logo .av-logo { opacity: 1; }
.av.has-logo { box-shadow: inset 0 0 0 1px rgba(0, 0, 0, .08), 0 4px 12px -4px rgba(0, 0, 0, .45); }
.av.has-logo .av-txt { visibility: hidden; }
.av .tick { z-index: 2; }

/* Neue E-Mail (Schreiben) v1.6 */
.compose { width: min(720px, calc(100vw - 32px)); height: min(700px, calc(100vh - 60px)); }
.rc-pill { padding-left: 3px; height: 30px; gap: 6px; }
.rc-pill .av { width: 24px; height: 24px; font-size: 10px; box-shadow: none; }
.from-dot { width: 26px; height: 26px; border-radius: 8px; font-size: 12px; }
.c-line select { font-weight: 600; }
.suggest { padding: 6px; max-height: 340px; overflow: auto; }
.suggest .sg-head { font-size: 11px; font-weight: 700; text-transform: uppercase; letter-spacing: .5px; color: var(--faint); padding: 4px 8px 6px; cursor: default; }
.suggest .sg-row { display: flex; align-items: center; gap: 10px; padding: 7px 8px; border-radius: 10px; }
.suggest .sg-row .av { width: 32px; height: 32px; font-size: 12px; }
.suggest .sg-txt { min-width: 0; display: flex; flex-direction: column; }
.suggest .sg-txt b { font-weight: 600; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.suggest .sg-txt small { margin: 0; color: var(--faint); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.c-atts { gap: 8px; padding: 4px 14px 10px; }
.att-card { display: inline-flex; align-items: center; gap: 9px; padding: 6px 6px 6px 7px; border: 1px solid var(--line); border-radius: 12px; background: var(--panel2); max-width: 260px; }
.att-card.off { opacity: .45; }
.att-card .ext { width: 32px; height: 32px; border-radius: 8px; display: grid; place-items: center; font-size: 10px; font-weight: 800; text-transform: uppercase; color: var(--accent); background: var(--accent-soft); flex: none; }
.att-card .att-txt { min-width: 0; display: flex; flex-direction: column; }
.att-card .att-txt b { font-size: 12.5px; font-weight: 600; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.att-card .att-txt small { font-size: 11px; color: var(--faint); }
.att-card button { border: 0; background: var(--hover); width: 24px; height: 24px; border-radius: 8px; cursor: pointer; color: var(--muted); flex: none; }
.c-stats { font-size: 12px; }
.editor h3 { font-size: 18px; margin: 10px 0 6px; }
.menu.color-menu { display: grid; grid-template-columns: repeat(5, 30px); gap: 6px; min-width: 0; padding: 10px; }
.menu .swatch { width: 30px; height: 30px; border-radius: 50%; border: 2px solid rgba(255, 255, 255, .25); cursor: pointer; }
.menu .swatch:hover { transform: scale(1.12); }
.menu.emoji-menu { display: block; min-width: 0; width: 326px; padding: 8px; overflow: hidden; }
.menu.emoji-menu div { padding: 0; border-radius: 0; cursor: default; white-space: normal; }
.menu.emoji-menu div:hover { background: none; }
.menu.emoji-menu .emo-tabs { display: flex; gap: 4px; padding-bottom: 6px; margin-bottom: 6px; border-bottom: 1px solid var(--line); }
.menu .emo-tab { flex: 1; height: 34px; border: 0; border-radius: 10px; background: transparent; font-size: 18px; cursor: pointer; font-family: "Segoe UI Emoji", "Apple Color Emoji", "Noto Color Emoji", sans-serif; }
.menu .emo-tab:hover { background: var(--hover); }
.menu .emo-tab.on { background: var(--accent-soft); box-shadow: inset 0 -2px 0 var(--accent); }
.menu.emoji-menu .emo-grid { display: grid; grid-template-columns: repeat(8, 36px); gap: 2px; max-height: 190px; overflow-y: auto; overflow-x: hidden; }
.menu.emoji-menu .emo-hint { display: block; font-size: 11px; color: var(--faint); text-align: center; margin-top: 6px; }
.c-head b, .editor:empty::before, .c-line input::placeholder { font-family: "Inter", "Segoe UI Emoji", "Apple Color Emoji", "Noto Color Emoji", sans-serif; }
.menu .emo { width: 36px; height: 36px; border: 0; background: transparent; border-radius: 9px; font-size: 20px; cursor: pointer; font-family: "Segoe UI Emoji", "Apple Color Emoji", "Noto Color Emoji", sans-serif; }
.menu .emo:hover { background: var(--hover); }

/* Meldung bei neuer E-Mail */
.toast.toast-mail { align-items: center; border-color: rgba(255, 51, 102, .35); animation: mailIn .35s cubic-bezier(.2, .9, .3, 1.2); }
.nm-toast { display: flex; gap: 11px; align-items: center; min-width: 0; }
.nm-toast .av { width: 40px; height: 40px; }
.nm-txt { display: flex; flex-direction: column; min-width: 0; }
.nm-txt small { display: flex; align-items: center; gap: 6px; font-size: 11.5px; color: var(--faint); }
.nm-txt small .acc-chip { height: 18px; font-size: 10.5px; }
.nm-txt b, .nm-txt > span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.nm-txt > span { color: var(--muted); font-size: 13px; }
@keyframes mailIn { from { opacity: 0; transform: translateY(16px) scale(.96); } }

/* Feste Grußformel */
.editor .sgc-lock { position: relative; margin: 14px 0 6px; padding: 10px 12px 10px 14px; border-left: 3px solid; border-image: var(--grad) 1; background: color-mix(in srgb, var(--accent) 6%, transparent); border-radius: 0 10px 10px 0; user-select: none; cursor: default; }
.editor .sgc-lock::after { content: "🔒 fest"; position: absolute; top: 6px; right: 8px; font-size: 10.5px; color: var(--faint); }
.editor .sgc-lock a { color: inherit; }
.sig-card .sig-preview { margin: 10px 0 8px; padding: 10px 14px; border-left: 3px solid var(--accent); background: var(--bg2); border-radius: 0 10px 10px 0; font-size: 13.5px; }

/* Geräte-Code */
.pair-card .pair-code { margin: 12px auto; text-align: center; font: 800 36px/1.1 ui-monospace, "Cascadia Code", Consolas, monospace; letter-spacing: 6px; padding: 14px 10px; border-radius: 16px; border: 2px dashed rgba(255, 51, 102, .5); background: linear-gradient(135deg, rgba(255, 51, 102, .1), rgba(139, 92, 246, .08)); user-select: all; }
.pair-left { font-size: 12.5px; color: var(--muted); align-self: center; }
.pair-steps { margin: 6px 0 12px; padding-left: 20px; font-size: 13.5px; color: var(--muted); }
.pair-steps li { margin: 4px 0; }
.pair-input { text-align: center; font: 700 26px ui-monospace, "Cascadia Code", Consolas, monospace !important; letter-spacing: 4px; text-transform: uppercase; height: 56px !important; }
.pair-login-btn { width: 100%; height: 44px; margin-top: 12px; }

/* Gruppen */
.nav-gwrap { margin-top: 8px; border-radius: 16px; background: color-mix(in srgb, var(--hover) 45%, transparent); padding: 3px; }
.nav-group { display: flex; align-items: center; gap: 9px; padding: 8px 6px 8px 10px; border-radius: 13px; cursor: pointer; font-weight: 700; user-select: none; }
.nav-group:hover { background: var(--hover); }
.nav-group.active { background: linear-gradient(90deg, rgba(255, 51, 102, .18), rgba(139, 92, 246, .08)); }
.nav-group .g-ico { font-size: 17px; width: 24px; text-align: center; font-family: "Segoe UI Emoji", "Apple Color Emoji", "Noto Color Emoji", sans-serif; }
.nav-group .n { flex: 1; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.nav-group .g-cnt { font-size: 11px; color: var(--faint); font-weight: 600; }
.nav-group .c { min-width: 22px; height: 20px; padding: 0 7px; border-radius: 10px; display: inline-grid; place-items: center; font-size: 11.5px; background: var(--accent); color: #fff; }
.nav-group .g-tog { border: 0; background: transparent; color: var(--faint); width: 26px; height: 26px; border-radius: 8px; display: grid; place-items: center; cursor: pointer; }
.nav-group .g-tog:hover { background: var(--hover); color: var(--text); }
.nav-group .g-tog svg { width: 15px; height: 15px; transition: transform .15s; }
.nav-group.closed .g-tog svg { transform: rotate(-90deg); }
.nav-gbody { padding-left: 6px; }
.nav-gbody .nav-sec { margin-top: 2px; }
.nav-label { margin: 14px 10px 4px; font-size: 11px; font-weight: 700; text-transform: uppercase; letter-spacing: .6px; color: var(--faint); }
.groups-list { display: grid; gap: 6px; }
.preset-row { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; margin: 4px 0 10px; }
/* Echte Anbieter-Logos */
.brand-img { width: 100%; height: 100%; object-fit: contain; display: block; }
.nav-group .g-ico.has-brand, .title-ico.has-brand, .g-ico-in.has-brand, .chip-ico.has-brand, .prov-ico.has-brand { background: #fff; border-radius: 7px; padding: 3px; box-shadow: 0 2px 8px -3px rgba(0, 0, 0, .4); }
.nav-group .g-ico { height: 24px; display: inline-grid; place-items: center; }
.title-g { display: inline-flex; align-items: center; gap: 9px; }
.title-ico { width: 30px; height: 30px; display: inline-grid; place-items: center; font-size: 22px; flex: none; }
.title-ico.has-brand { border-radius: 9px; padding: 4px; }
.g-icon-btn { display: grid; place-items: center; padding: 0; }
.g-ico-in { width: 28px; height: 28px; display: inline-grid; place-items: center; }
.brand-chip { display: inline-flex; align-items: center; gap: 6px; padding-left: 5px; }
.chip-ico { width: 20px; height: 20px; display: inline-grid; place-items: center; font-size: 13px; }
.chip-ico.has-brand { padding: 2px; border-radius: 6px; }
.provider-grid { grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); }
.provider-grid .prov-btn span:last-child { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.provider-grid .prov-btn { display: flex; align-items: center; gap: 10px; justify-content: flex-start; padding: 0 12px; height: 50px; text-align: left; }
.prov-ico { width: 30px; height: 30px; flex: none; display: inline-grid; place-items: center; font-size: 18px; }
.prov-ico.has-brand { padding: 4px; border-radius: 8px; }
.preset-row .chip { font-family: "Inter", "Segoe UI Emoji", "Apple Color Emoji", sans-serif; }
.group-row { display: flex; align-items: center; gap: 10px; padding: 8px 10px; border: 1px solid var(--line); border-radius: 12px; background: var(--bg2); }
.group-row .grow { min-width: 0; }
.group-row small { display: block; color: var(--faint); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.g-icon-btn { width: 36px; height: 36px; border-radius: 10px; border: 1px solid var(--line); background: var(--panel2); font-size: 18px; cursor: pointer; font-family: "Segoe UI Emoji", "Apple Color Emoji", "Noto Color Emoji", sans-serif; }
.g-sel { width: auto !important; max-width: 170px; height: 32px !important; font-size: 12.5px; padding: 0 8px !important; }
/* Anbieter-Hilfe beim Hinzufügen */
.prov-help { border: 1px solid rgba(139, 92, 246, .35); background: rgba(139, 92, 246, .08); border-radius: 14px; padding: 12px 14px; }
.prov-text { font-size: 13px; color: var(--muted); margin-bottom: 10px; line-height: 1.5; }
.prov-links { display: flex; flex-wrap: wrap; gap: 8px; }
.prov-links .btn { text-decoration: none; color: var(--text); }
.provider-grid button { font-family: "Inter", "Segoe UI Emoji", "Apple Color Emoji", sans-serif; }

.ib.dim { opacity: .45; }
.update-card .btn { flex: none; }
.upd-bar { height: 8px; border-radius: 8px; background: var(--hover); overflow: hidden; margin-top: 8px; }
.upd-bar i { display: block; height: 100%; width: 0; background: var(--grad); transition: width .3s; }

/* Passwort-Auge */
.pw-wrap { position: relative; display: block; width: 100%; }
.pw-wrap > input { padding-right: 46px !important; width: 100%; }
.pw-wrap > .eye { position: absolute; right: 4px; top: 50%; transform: translateY(-50%); width: 36px; height: 36px; }
.pw-wrap > .eye svg { width: 18px; height: 18px; }
.eye-inline { width: 30px; height: 30px; }
.eye-inline svg { width: 17px; height: 17px; }
.access-field.flash .access { animation: flash 1.4s ease-out; }
@keyframes flash { 0%, 40% { box-shadow: 0 0 0 3px rgba(255, 51, 102, .55); } 100% { box-shadow: 0 0 0 0 rgba(255, 51, 102, 0); } }

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

/* Mobil */
@media (max-width: 1100px) {
  .app { grid-template-columns: 240px minmax(300px, 360px) 1fr; }
}
@media (max-width: 860px) {
  body { font-size: 15px; }
  .app, .app.reader-off { grid-template-columns: 1fr; }
  .side { position: fixed; top: 0; bottom: 0; left: 0; width: min(300px, 85vw); z-index: 50; transform: translateX(-105%); transition: transform .22s ease; padding-top: var(--sat); }
  .app.nav-open .side { transform: none; box-shadow: var(--shadow); }
  .app.nav-open .scrim { display: block; position: fixed; inset: 0; background: rgba(0, 0, 0, .5); z-index: 45; }
  .list-title .menu-btn { display: inline-grid; }
  .list { border-right: 0; }
  .reader { position: fixed; inset: 0; z-index: 35; transform: translateX(100%); transition: transform .22s ease; padding-top: var(--sat); }
  .app.show-reader .reader { transform: none; display: flex; }
  .app.reader-off .reader { display: flex; }
  .reader-bar .back { display: inline-grid; }
  .reader-body { padding: 16px 14px calc(40px + var(--sab)); }
  .r-head { flex-wrap: wrap; }
  .r-date { flex-basis: 100%; padding-left: 57px; margin-top: -8px; }
  .r-subj { font-size: 19px; }
  .fab { display: grid; }
  .compose, .compose.max { inset: 0; right: 0; width: 100%; height: 100%; border-radius: 0; transform: none; padding-top: var(--sat); }
  .c-head { border-radius: 0; }
  .tabs-wrap { grid-template-columns: 1fr; grid-template-rows: auto 1fr; }
  .tabs { flex-direction: row; overflow-x: auto; border-right: 0; border-bottom: 1px solid var(--line); }
  .tabs .nav-item { white-space: nowrap; }
  .dialog.wide { height: calc(100vh - 32px); }
  .msg-quick { display: none !important; }
  .grid2 { grid-template-columns: 1fr 100px; }
  .side { background: var(--panel); }
  .reader { background: var(--bg); }
  .reader-bar { background: var(--panel); }
  .grid-2c { grid-template-columns: 1fr; gap: 0; }
  .user-card { flex-wrap: wrap; }
  .uc-actions { width: 100%; justify-content: flex-end; }
  .access-grid { grid-template-columns: 1fr; }
  .cred div { grid-template-columns: 1fr; gap: 2px; }
  .auth-card { padding: 30px 22px 22px; }
}
/* Handy-Feinschliff (v1.10.0-4): Dialoge als Vollbild-Sheet, nichts abgeschnitten */
@media (max-width: 860px) {
  /* Dialoge: von unten, volle Breite, Safe-Area */
  .overlay { padding: 0; place-items: end stretch; }
  .dialog { width: 100%; max-height: calc(100dvh - var(--sat) - 12px); border-radius: 22px 22px 0 0; border-left: 0; border-right: 0; border-bottom: 0; animation: sheet .24s cubic-bezier(.2, .9, .3, 1); }
  .dialog.wide { height: calc(100dvh - var(--sat) - 12px); max-height: none; }
  .dialog::before { content: ""; display: block; width: 40px; height: 4px; border-radius: 4px; background: var(--line); margin: 8px auto 0; flex: none; }
  .d-head { padding: 8px 10px 10px 18px; }
  .d-head h3 { font-size: 18px; }
  .d-body { padding: 14px 16px calc(18px + var(--sab)); }
  .d-foot { padding-bottom: calc(12px + var(--sab)); }
  /* Einstellungs-Reiter als kompakte Pillen */
  .tabs { padding: 8px 12px; gap: 6px; scrollbar-width: none; flex: none; }
  .tabs::-webkit-scrollbar { display: none; }
  .tabs .nav-item { padding: 6px 12px 6px 6px; border-radius: 999px; border: 1px solid var(--line); font-size: 13.5px; gap: 7px; flex: none; }
  .tabs .nav-item::before { display: none; }
  .tabs .nav-item svg { width: 26px; height: 26px; padding: 5px; border-radius: 50%; }
  .tabs .nav-item.active { border-color: transparent; background: var(--accent-soft); }
  .tab-body { padding: 16px 14px calc(30px + var(--sab)); }
  .card { padding: 12px 14px; }
  /* Postfach-Karten: Name oben, Knöpfe darunter */
  .acc-card { flex-wrap: wrap; row-gap: 10px; }
  .acc-card .grow { flex: 1 1 calc(100% - 30px); }
  .acc-card .g-sel { flex: 1 1 100%; width: 100%; max-width: none; order: 5; }
  .group-row { flex-wrap: wrap; }
  /* Admin: Benutzer-Karten */
  .user-card { padding: 12px; gap: 10px 12px; }
  .uc-actions { justify-content: flex-start; gap: 6px; }
  .uc-actions .btn { flex: 1 1 auto; justify-content: center; }
  .uc-mb-wrap { padding-left: 0; }
  .uc-mb-row small { white-space: normal; }
  .tab-body .row:has(> h4) { flex-wrap: wrap; gap: 8px; }
  /* Postfach hinzufügen */
  .provider-grid { grid-template-columns: 1fr 1fr; }
  .provider-grid .prov-btn { padding: 0 10px; gap: 8px; font-size: 13px; }
  /* Neue E-Mail */
  .c-fields { padding: 4px 14px 0; }
  .c-line { gap: 6px; min-height: 48px; }
  .c-line > label { width: auto; min-width: 62px; font-size: 12.5px; }
  .c-line select { min-width: 0; width: 0; text-overflow: ellipsis; }
  .c-line .rcpt { flex: 1 1 0; }
  .c-line .rcpt input { min-width: 90px; }
  .toolbar { flex-wrap: nowrap; overflow-x: auto; scrollbar-width: none; width: auto; max-width: none; margin: 8px 10px 0; }
  .toolbar::-webkit-scrollbar { display: none; }
  .toolbar .ib { flex: none; width: 38px; height: 38px; }
  .editor { padding: 14px; }
  .c-foot { gap: 6px; }
  .c-foot .btn.primary { flex: 1; justify-content: center; }
  .c-head .ib[title*="Vollbild"], .c-head .ib[title*="Maximieren"], .c-head .ib[title*="Minimieren"] { display: none; }
  /* Liste & Lesen */
  .msg { padding-right: 10px; }
  .reader-bar { overflow-x: auto; scrollbar-width: none; }
  .reader-bar::-webkit-scrollbar { display: none; }
  .reply-row .btn { flex: 1; justify-content: center; }
  .r-body img, .r-body table { max-width: 100% !important; height: auto; }
  input, select, textarea { font-size: 16px; } /* verhindert Zoom auf dem iPhone */
}
@keyframes sheet { from { transform: translateY(40px); opacity: 0; } to { transform: none; opacity: 1; } }

/* Offline / Postausgang (v1.10.0-5) */
.list-status { display: flex; gap: 6px; flex-wrap: wrap; }
.list-status:not(:has(.status-pill:not(.hidden))) { display: none; }
.status-pill { display: inline-flex; align-items: center; gap: 7px; height: 26px; padding: 0 11px; border-radius: 999px; font-size: 12px; font-weight: 600; border: 1px solid var(--line); background: var(--panel2); color: var(--muted); font-family: inherit; }
.status-pill.off { color: #fbbf24; border-color: rgba(251, 191, 36, .35); background: rgba(251, 191, 36, .08); }
.status-pill.off i { width: 7px; height: 7px; border-radius: 50%; background: #fbbf24; box-shadow: 0 0 0 3px rgba(251, 191, 36, .2); }
.status-pill.out { cursor: pointer; color: var(--text); border-color: rgba(255, 51, 102, .35); background: var(--accent-soft); }
.status-pill.hidden { display: none; }

/* Handy: Leiste oben in der geöffneten E-Mail */
@media (max-width: 860px) {
  .reader-bar.rb-mobile { position: sticky; top: 0; z-index: 3; margin: 0; border: 0; border-bottom: 1px solid var(--line); border-radius: 0; padding: 6px 6px 6px 4px; gap: 0; flex-wrap: nowrap; overflow: visible;
    background: color-mix(in srgb, var(--panel) 88%, transparent); backdrop-filter: blur(18px) saturate(1.3); -webkit-backdrop-filter: blur(18px) saturate(1.3); min-height: 54px; }
  .rb-mobile .rb-back { display: inline-flex; align-items: center; gap: 4px; height: 42px; padding: 0 10px 0 6px; border: 0; background: transparent; color: var(--accent); font: 600 16px/1 inherit; font-family: inherit; cursor: pointer; border-radius: 12px; min-width: 0; max-width: 42vw; }
  .rb-mobile .rb-back svg { width: 24px; height: 24px; flex: none; }
  .rb-mobile .rb-back span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
  .rb-mobile .rb-back:active { background: var(--hover); }
  .rb-mobile .rb-pos { display: inline-flex; gap: 0; margin-left: 2px; }
  .rb-mobile .rb-pos .ib { width: 36px; height: 40px; }
  .rb-mobile .rb-up svg { transform: rotate(180deg); }
  .rb-mobile .ib.dis { opacity: .3; pointer-events: none; }
  .rb-mobile .ib { width: 42px; height: 42px; border-radius: 12px; color: var(--text); }
  .rb-mobile .ib svg { width: 21px; height: 21px; }
  .rb-mobile .ib:active { background: var(--hover); }
  .rb-mobile .rb-del { color: #ff6b81; }
  .rb-mobile .ib.star.on { color: var(--star); }
  .rb-mobile .sp { flex: 1; }
  .reader .reader-body { padding-top: 14px; }
  .r-subj { font-size: 21px; line-height: 1.25; margin: 6px 0 12px; }
  .r-top { gap: 6px; }
  .r-card { padding: 12px; }
}
@media print {
  .side, .list, .reader-bar, .reply-row, .fab, .toasts { display: none !important; }
  .app { display: block; }
  body { overflow: visible; }
  .reader-body { overflow: visible; }
}

/* Postfach-Profilbilder (Logo der eigenen Domain oder des Anbieters) */
.acc-badge { position: relative; overflow: hidden; }
.acc-badge .ab-img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: contain; padding: 14%; background: #fff; box-sizing: border-box; }
.acc-badge.has-img { background: #fff; box-shadow: inset 0 0 0 1px rgba(0, 0, 0, .08), 0 3px 10px -3px rgba(0, 0, 0, .45), 0 0 0 2px color-mix(in srgb, var(--c) 55%, transparent); }
.acc-badge.has-img .ab-txt { visibility: hidden; }
.acc-badge.card-badge { width: 34px; height: 34px; border-radius: 10px; font-size: 15px; }
.acc-badge.uc-mb-badge { width: 28px; height: 28px; border-radius: 8px; font-size: 13px; }
.acc-chip i { position: relative; overflow: hidden; }
.acc-chip i.has-img { width: 15px; height: 15px; background: #fff; box-shadow: 0 0 0 1.5px var(--c, var(--accent)); margin-left: -3px; }
.acc-chip i .ab-img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: contain; padding: 1.5px; box-sizing: border-box; }
/* ================= Werkzeuge (Team, Sicherheit, Später senden/erinnern, KI, Newsletter, Anhänge) ================= */
.nav-tools { margin: 6px 0 4px; }
.nav-tools .tools-h { display: flex; align-items: center; justify-content: space-between; cursor: pointer; user-select: none; }
.nav-tools .tools-h svg { width: 14px; height: 14px; transition: transform .2s; }
.nav-tools.closed .tools-h svg { transform: rotate(-90deg); }
.nav-item.tool { padding-top: 6px; padding-bottom: 6px; }
.tool-ico { width: 18px; text-align: center; font-size: 14.5px; flex: none; font-family: "Segoe UI Emoji", "Apple Color Emoji", "Noto Color Emoji", sans-serif; }

.tag-chip { display: inline-flex; align-items: center; gap: 4px; height: 21px; padding: 0 8px; border-radius: 999px; font-size: 11px; font-weight: 600; color: var(--muted);
  background: var(--hover); border: 1px solid var(--line); white-space: nowrap; max-width: 220px; overflow: hidden; text-overflow: ellipsis; }
.tag-chip.st-in_arbeit { color: #60a5fa; border-color: rgba(96, 165, 250, .35); background: rgba(96, 165, 250, .1); }
.tag-chip.st-offen { color: #fbbf24; border-color: rgba(251, 191, 36, .35); background: rgba(251, 191, 36, .1); }
.tag-chip.st-warten { color: #c084fc; border-color: rgba(192, 132, 252, .35); background: rgba(192, 132, 252, .1); }
.tag-chip.st-erledigt { color: #4ade80; border-color: rgba(74, 222, 128, .35); background: rgba(74, 222, 128, .1); }
.tag-chip.late { color: #f87171; border-color: rgba(248, 113, 113, .4); background: rgba(248, 113, 113, .1); }
.tag-chip.alias { color: #2dd4bf; border-color: rgba(45, 212, 191, .35); background: rgba(45, 212, 191, .08); }
.msg-meta { flex-wrap: wrap; }

/* Absender-Check */
.sec-box { border-radius: 14px; border: 1px solid var(--line); background: var(--panel2); margin: 0 0 14px; font-size: 13px; overflow: hidden; }
.sec-box summary { display: flex; align-items: center; gap: 10px; padding: 9px 13px; cursor: pointer; list-style: none; flex-wrap: wrap; }
.sec-box summary::-webkit-details-marker { display: none; }
.sec-box summary::after { content: '▾'; margin-left: auto; color: var(--faint); transition: transform .2s; }
.sec-box[open] summary::after { transform: rotate(180deg); }
.sec-box .sec-dom { color: var(--faint); font-size: 12px; }
.sec-box .sec-geo { color: var(--muted); font-size: 12px; }
.sec-box ul { list-style: none; margin: 0; padding: 2px 13px 8px; display: grid; gap: 6px; }
.sec-box li { display: flex; gap: 9px; align-items: flex-start; color: var(--muted); line-height: 1.4; }
.sec-box li i { flex: none; width: 18px; height: 18px; border-radius: 50%; display: grid; place-items: center; font-style: normal; font-weight: 800; font-size: 11px; background: var(--hover); }
.sec-box li.k-good i { background: rgba(34, 197, 94, .18); color: #4ade80; }
.sec-box li.k-bad i { background: rgba(239, 68, 68, .2); color: #f87171; }
.sec-box li.k-bad { color: var(--text); }
.sec-box li.k-warn i { background: rgba(245, 158, 11, .2); color: #fbbf24; }
.sec-box .sec-ip { padding: 0 13px 8px 40px; color: var(--faint); font-size: 12px; }
.sec-box .sec-ip code { font-size: 11.5px; }
.sec-box .sec-foot { padding: 7px 13px 9px; border-top: 1px solid var(--line); color: var(--faint); font-size: 11.5px; }
.sec-box.lvl-ok { border-color: rgba(34, 197, 94, .28); }
.sec-box.lvl-warn { border-color: rgba(245, 158, 11, .35); background: color-mix(in srgb, var(--panel2) 92%, #f59e0b); }
.sec-box.lvl-bad { border-color: rgba(239, 68, 68, .55); background: color-mix(in srgb, var(--panel2) 86%, #ef4444); box-shadow: 0 0 0 3px rgba(239, 68, 68, .12); }
.warn-banner { border-color: rgba(239, 68, 68, .45); color: #fca5a5; background: rgba(239, 68, 68, .1); }
[data-theme="light"] .warn-banner { color: #b91c1c; }
.pres-banner { border-color: rgba(96, 165, 250, .45); background: rgba(96, 165, 250, .1); color: var(--text); }
.pres-dot { width: 9px; height: 9px; border-radius: 50%; background: #60a5fa; box-shadow: 0 0 0 0 rgba(96, 165, 250, .7); animation: presPulse 1.4s infinite; flex: none; }
@keyframes presPulse { 70% { box-shadow: 0 0 0 8px rgba(96, 165, 250, 0); } 100% { box-shadow: 0 0 0 0 rgba(96, 165, 250, 0); } }
.c-pres { margin: 6px 10px 2px; padding: 8px 12px; border-radius: 10px; background: rgba(245, 158, 11, .14); border: 1px solid rgba(245, 158, 11, .4); font-size: 13px; font-weight: 600; }

/* Team-Bereich */
.team-box:empty { display: none; }
.team-box { margin: 18px 0 6px; border: 1px dashed rgba(139, 92, 246, .45); background: color-mix(in srgb, var(--panel2) 90%, #8b5cf6); border-radius: 16px; padding: 12px 14px; }
.tb-head { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.tb-head small { color: var(--faint); }
.tb-head .sp { flex: 1; }
.tb-assigned { font-weight: 700; }
.tb-assigned.st-in_arbeit { border-color: rgba(96, 165, 250, .5); }
.tb-assigned.st-erledigt { border-color: rgba(74, 222, 128, .5); }
.tb-notes { display: grid; gap: 10px; margin-top: 12px; }
.tb-note { display: flex; gap: 10px; align-items: flex-start; }
.tb-note .av { width: 30px; height: 30px; font-size: 11px; flex: none; }
.tb-meta { font-size: 12px; color: var(--faint); }
.tb-meta b { color: var(--text); }
.tb-text { white-space: pre-wrap; word-break: break-word; font-size: 13.5px; margin-top: 2px; }
.tb-add { display: flex; gap: 8px; margin-top: 12px; align-items: flex-end; }
.tb-add textarea { flex: 1; min-height: 42px; max-height: 160px; resize: vertical; padding: 9px 12px; border-radius: 12px; border: 1px solid var(--line); background: var(--bg2); outline: none; }
.tb-add textarea:focus { border-color: #8b5cf6; box-shadow: 0 0 0 3px rgba(139, 92, 246, .18); }
.tb-add .btn svg { width: 15px; height: 15px; }

/* KI */
.ai-card { border-radius: 16px; padding: 12px 14px; margin: 0 0 14px; background: linear-gradient(135deg, rgba(139, 92, 246, .14), rgba(255, 51, 102, .1)); border: 1px solid rgba(139, 92, 246, .38); }
.ai-card.err { border-color: rgba(239, 68, 68, .4); background: rgba(239, 68, 68, .08); }
.ai-head { display: flex; align-items: center; gap: 8px; margin-bottom: 6px; }
.ai-head small { color: var(--faint); }
.ai-head .sp { flex: 1; }
.ai-text { white-space: pre-wrap; line-height: 1.55; font-size: 14px; }
.reader-bar .ai-btn { color: #a78bfa; }
.tool-loading { display: flex; align-items: center; gap: 10px; color: var(--muted); padding: 14px 2px; font-size: 13.5px; }
.spin { width: 18px; height: 18px; border-radius: 50%; border: 2.5px solid var(--line); border-top-color: var(--accent); animation: spin .8s linear infinite; flex: none; }
@keyframes spin { to { transform: rotate(360deg); } }

/* Zeitpunkt wählen */
.when-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 8px; }
.when-btn { display: grid; gap: 2px; text-align: left; padding: 10px 12px; border-radius: 12px; border: 1px solid var(--line); background: var(--panel2); cursor: pointer; transition: border-color .15s, transform .1s; }
.when-btn:hover { border-color: var(--accent); }
.when-btn:active { transform: scale(.98); }
.when-btn small { color: var(--faint); font-size: 11.5px; }
.compose .btn.primary.has-fu::after { content: '⏳'; margin-left: 4px; }

/* Werkzeug-Fenster */
.tool-dialog { width: min(860px, calc(100vw - 32px)); }
.tool-body { max-height: min(70vh, 720px); overflow: auto; }
.tool-h { margin: 16px 0 8px; font-size: 13px; color: var(--muted); text-transform: uppercase; letter-spacing: .4px; }
.tool-row { display: flex; align-items: center; gap: 10px; padding: 9px 10px; border-radius: 12px; border: 1px solid var(--line); background: var(--panel2); margin-bottom: 7px; cursor: default; }
.tool-row[onclick], .tool-row:has(> .grow) { cursor: pointer; }
.tool-row:hover { border-color: rgba(128, 128, 160, .35); }
.tool-row .grow { flex: 1; min-width: 0; }
.tool-row b { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.tool-row small { display: block; color: var(--faint); font-size: 12px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.tool-row.err { border-color: rgba(239, 68, 68, .45); }
.tool-row.blocked { opacity: .6; }
.tool-row.gone { opacity: .35; pointer-events: none; text-decoration: line-through; }
.tool-row .btn.sm { flex: none; }
.tool-done { margin-top: 14px; }
.tool-done summary { cursor: pointer; color: var(--muted); font-weight: 600; margin-bottom: 8px; }
.tool-filters { display: flex; gap: 10px; align-items: center; margin-bottom: 10px; flex-wrap: wrap; }
.tool-filters .search { flex: 1; min-width: 200px; }
.mini-sel { height: 32px; border-radius: 9px; border: 1px solid var(--line); background: var(--bg2); padding: 0 8px; font-size: 12.5px; flex: none; }
.att-row .ext { width: 40px; height: 40px; border-radius: 10px; display: grid; place-items: center; font-size: 10.5px; font-weight: 800; text-transform: uppercase; background: var(--hover); color: var(--muted); flex: none; }
.att-row .ext.k-img { background: rgba(45, 212, 191, .15); color: #2dd4bf; }
.att-row .ext.k-pdf { background: rgba(239, 68, 68, .15); color: #f87171; }
.att-row .ext.k-doc { background: rgba(96, 165, 250, .15); color: #60a5fa; }
.att-row .ext.k-zip { background: rgba(251, 191, 36, .15); color: #fbbf24; }
.att-row a.ib { display: inline-grid; place-items: center; }
.nl-row .av { width: 36px; height: 36px; flex: none; }
.nl-status { display: block; font-size: 12px; font-weight: 700; color: #4ade80; }
.nl-status:empty { display: none; }
.empty.small { padding: 26px 12px; font-size: 26px; }
.empty.small b { font-size: 14px; margin-top: 4px; }
.row-form { display: flex; gap: 8px; margin: 10px 0; flex-wrap: wrap; }
.row-form input, .row-form select { flex: 1 1 180px; height: 40px; padding: 0 12px; border-radius: 11px; border: 1px solid var(--line); background: var(--bg2); outline: none; min-width: 0; }
.row-form input:focus, .row-form select:focus { border-color: var(--accent); }
.row-form.wrap input[placeholder^="https"] { flex-basis: 100%; }
.al-list { margin-top: 10px; }
.card > b { display: block; font-size: 14.5px; margin-bottom: 4px; }

@media (max-width: 860px) {
  .tool-row { flex-wrap: wrap; }
  .tool-row .grow { flex: 1 1 calc(100% - 60px); }
  .tb-add { flex-direction: column; align-items: stretch; }
  .when-grid { grid-template-columns: 1fr 1fr; }
}
.banner > svg { width: 18px; height: 18px; flex: none; }

/* ================= Werkzeuge Teil 2 ================= */
.who-link { cursor: pointer; border-bottom: 1px dashed transparent; }
.who-link:hover { border-bottom-color: currentColor; }
.nav-head .vac { font-size: 13px; }
.ticket-badge { background: rgba(45, 212, 191, .14); color: #2dd4bf; }
.tag-chip.ticket { color: #2dd4bf; border-color: rgba(45, 212, 191, .35); background: rgba(45, 212, 191, .08); font-variant-numeric: tabular-nums; }
.btn.ok { border-color: rgba(34, 197, 94, .45); color: #4ade80; }
.btn.ok:hover { background: rgba(34, 197, 94, .12); }
.tpl-editor { min-height: 140px; max-height: 320px; overflow: auto; border: 1px solid var(--line); border-radius: 12px; padding: 10px 12px; background: var(--bg2); outline: none; }
.tpl-editor:focus { border-color: var(--accent); }

/* Einladung */
.inv-card { display: flex; gap: 14px; align-items: flex-start; border-radius: 16px; padding: 14px; margin: 0 0 14px; border: 1px solid rgba(96, 165, 250, .4); background: color-mix(in srgb, var(--panel2) 88%, #3b82f6); }
.inv-ico { width: 54px; flex: none; border-radius: 12px; overflow: hidden; text-align: center; background: var(--bg2); border: 1px solid var(--line); }
.inv-ico small { display: block; background: #ef4444; color: #fff; font-size: 11px; font-weight: 700; text-transform: uppercase; padding: 2px 0; }
.inv-ico b { display: block; font-size: 22px; padding: 4px 0 6px; }
.inv-title { font-weight: 700; font-size: 15px; }
.inv-when { color: var(--text); margin-top: 2px; }
.inv-sub { color: var(--muted); font-size: 13px; margin-top: 2px; }
.inv-actions { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; margin-top: 10px; }
.inv-status { font-weight: 700; font-size: 13px; }

/* Kundenkarte */
.cc-head { display: flex; align-items: center; gap: 12px; margin-bottom: 14px; flex-wrap: wrap; }
.cc-head .av { width: 46px; height: 46px; font-size: 16px; }
.cc-head b { display: block; font-size: 17px; }
.cc-head small { color: var(--faint); }
.cc-dir { font-size: 16px; flex: none; }
.stat-tiles { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 10px; margin: 4px 0 16px; }
.stat-tile { border: 1px solid var(--line); background: var(--panel2); border-radius: 14px; padding: 12px 14px; display: grid; gap: 2px; }
.stat-tile small { color: var(--faint); font-size: 12px; }
.stat-tile b { font-size: 26px; line-height: 1.15; font-variant-numeric: tabular-nums; }
.stat-tile b.sm { font-size: 18px; }

/* Statistik-Diagramme: ein Wert pro Diagramm, dünne Balken, ruhige Achsen */
.tool-body { position: relative; }
.chart { border: 1px solid var(--line); background: var(--panel2); border-radius: 14px; padding: 12px 14px 8px; margin-bottom: 12px; }
.chart-head { display: flex; align-items: baseline; justify-content: space-between; gap: 10px; margin-bottom: 8px; }
.chart-head small { color: var(--faint); font-size: 12px; }
.bars { display: flex; align-items: flex-end; gap: 2px; height: 120px; border-bottom: 1px solid var(--line); }
.bars.hours { height: 70px; }
.bar-hit { flex: 1; height: 100%; display: flex; align-items: flex-end; cursor: default; min-width: 0; }
.bar-hit i { display: block; width: 100%; max-width: 18px; margin: 0 auto; border-radius: 4px 4px 0 0; background: var(--accent); }
.bars.b-out .bar-hit i { background: #8b5cf6; }
.bar-hit:hover i { filter: brightness(1.25); }
.chart-axis { display: flex; justify-content: space-between; color: var(--faint); font-size: 11px; margin-top: 4px; }
.chart-tip { position: absolute; transform: translateX(-50%); background: var(--text); color: var(--bg); font-size: 12px; font-weight: 600; padding: 4px 8px; border-radius: 8px; pointer-events: none; white-space: nowrap; z-index: 5; }
.sender-row { display: grid; grid-template-columns: minmax(120px, 34%) 1fr 40px; align-items: center; gap: 10px; padding: 5px 4px; cursor: pointer; border-radius: 8px; font-size: 13px; }
.sender-row:hover { background: var(--hover); }
.sr-name { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.sr-bar { height: 8px; border-radius: 4px; background: var(--hover); overflow: hidden; }
.sr-bar i { display: block; height: 100%; border-radius: 4px; background: var(--accent); }
.sender-row b { text-align: right; font-variant-numeric: tabular-nums; }
.stat-table { width: 100%; border-collapse: collapse; font-size: 13px; }
.stat-table th { text-align: left; color: var(--faint); font-weight: 600; padding: 6px 8px; border-bottom: 1px solid var(--line); }
.stat-table td { padding: 7px 8px; border-bottom: 1px solid var(--line); font-variant-numeric: tabular-nums; }

/* Rechnungen */
.inv-month { border: 1px solid var(--line); border-radius: 14px; padding: 8px 12px; margin-bottom: 8px; background: var(--panel2); }
.inv-month summary { display: flex; align-items: center; gap: 6px; cursor: pointer; list-style: none; padding: 4px 0; }
.inv-month summary::-webkit-details-marker { display: none; }
.inv-month summary .sp { flex: 1; }
.inv-month[open] summary { margin-bottom: 6px; }

/* Upload-Fortschritt, Umzug */
.up-toast { display: grid; gap: 6px; min-width: 220px; }
.up-bar { display: block; height: 6px; border-radius: 3px; background: var(--hover); overflow: hidden; }
.up-bar i { display: block; height: 100%; width: 0; background: var(--grad); transition: width .3s; }
.up-bar.big { height: 8px; margin: 8px 0 4px; }
.mig-status { margin-top: 14px; padding: 12px; border-radius: 12px; background: var(--bg2); border: 1px solid var(--line); display: grid; gap: 4px; }
.mig-status small { color: var(--faint); }
.mig-status .btn { justify-self: start; margin-top: 6px; }

/* Regel-Dialog */
.rule-sec { border: 1px solid var(--line); border-radius: 14px; padding: 12px; margin-bottom: 12px; background: var(--panel2); }
.rule-sec > b { display: block; font-size: 12px; letter-spacing: .5px; color: var(--accent); }
.rule-sec input:not([type=checkbox]) { width: 100%; height: 40px; padding: 0 12px; border-radius: 11px; border: 1px solid var(--line); background: var(--bg2); outline: none; margin-bottom: 6px; }
.rule-sec input:not([type=checkbox]):focus { border-color: var(--accent); }
.rule-flags { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
@media (max-width: 860px) { .rule-flags { grid-template-columns: 1fr; } .sender-row { grid-template-columns: 1fr 60px 34px; } }
/* ---------- Teil 3: Zwei-Faktor, Tracking-Schutz, Sofort-Benachrichtigung ---------- */
.otp-input { text-align: center; font: 700 28px ui-monospace, "Cascadia Code", Consolas, monospace !important; letter-spacing: 6px; height: 58px !important; }
.otp-shield { display: grid; place-items: center; width: 64px; height: 64px; margin: 0 auto 10px; border-radius: 20px; background: var(--accent-soft); color: var(--accent); }
.otp-shield svg { width: 32px; height: 32px; }
.twofa-ico { flex: none; display: grid; place-items: center; width: 42px; height: 42px; border-radius: 13px; background: rgba(245, 158, 11, .14); color: var(--warn); }
.twofa-ico.on { background: rgba(34, 197, 94, .14); color: var(--ok); }
.twofa-ico svg { width: 22px; height: 22px; }
.twofa-card .row, .shield-card .row, .live-card .row { gap: 12px; align-items: center; }
.twofa-card > .hint { margin: 10px 0 12px; }
.backup-codes { display: grid; grid-template-columns: repeat(2, 1fr); gap: 8px; }
.backup-codes code { display: block; text-align: center; padding: 9px 6px; border-radius: 10px; background: var(--panel); border: 1px solid var(--line); font: 600 15px ui-monospace, Consolas, monospace; letter-spacing: 1px; }
.twofa-setup .qr-wrap { display: flex; gap: 16px; align-items: center; margin: 6px 0 14px; flex-wrap: wrap; }
.qr-box { width: 176px; height: 176px; flex: none; background: #fff; border-radius: 14px; padding: 6px; }
.qr-box svg { width: 100%; height: 100%; display: block; }
.qr-side { flex: 1; min-width: 180px; display: grid; gap: 8px; }
.secret-key { display: block; padding: 9px 10px; border-radius: 10px; background: var(--panel); border: 1px solid var(--line); font: 600 14px ui-monospace, Consolas, monospace; letter-spacing: 1px; word-break: break-all; user-select: all; }
.shield-stats { display: flex; gap: 18px; flex-wrap: wrap; margin-top: 14px; padding-top: 12px; border-top: 1px solid var(--line); }
.shield-stats > div { display: grid; gap: 2px; }
.shield-stats b { font-size: 22px; line-height: 1.1; }
.shield-stats span { font-size: 12px; color: var(--muted); }
.shield-top { display: flex; gap: 6px; flex-wrap: wrap; margin-top: 4px; }
.shield-top .chip { font-size: 12px; padding: 3px 9px; }
.shield-banner { background: rgba(34, 197, 94, .08); border-color: rgba(34, 197, 94, .28); }
.shield-banner > svg { color: var(--ok); }
.shield-banner b { color: var(--text); }
@media (max-width: 560px) { .qr-box { width: 150px; height: 150px; margin: 0 auto; } .backup-codes code { font-size: 14px; } }
.live-card > .row { flex-wrap: wrap; }
.live-card > .row > .grow { min-width: 170px; }
@media (max-width: 560px) { .live-card > .row > .btn { width: 100%; } }
