:root {
  --b1: #f5ac17;
  --b2: #dc6c12;
  --grad: linear-gradient(135deg, #f7b52a 0%, #ec8a14 55%, #dc6c12 100%);
  --bg: #0e0b09;
  --surface: #181310;
  --surface-2: #221b16;
  --surface-3: #2d241d;
  --line: rgba(255, 236, 220, 0.09);
  --text: #f8f1ea;
  --muted: #a9998c;
  --danger: #ff5a4e;
  --radius: 22px;
  --top-h: 56px;
  --tab-h: 68px;
  --safe-t: env(safe-area-inset-top, 0px);
  --safe-b: env(safe-area-inset-bottom, 0px);
  color-scheme: dark;
}

* { box-sizing: border-box; -webkit-tap-highlight-color: transparent; }
html, body { margin: 0; height: 100%; background: var(--bg); color: var(--text); }
body {
  font: 15px/1.45 -apple-system, BlinkMacSystemFont, "SF Pro Text", "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  -webkit-font-smoothing: antialiased;
  overscroll-behavior-y: none;
}
a { color: inherit; text-decoration: none; }
button { font: inherit; color: inherit; background: none; border: 0; padding: 0; cursor: pointer; }
input, textarea { font: inherit; color: var(--text); }
img, video { display: block; max-width: 100%; }
.hidden { display: none !important; }
.muted { color: var(--muted); }
.grad-text { background: var(--grad); -webkit-background-clip: text; background-clip: text; color: transparent; }
svg.i { width: 26px; height: 26px; flex: none; }
svg.i.sm { width: 20px; height: 20px; }
svg.i.lg { width: 30px; height: 30px; }

/* ---------- Grundgerüst ---------- */
#app { min-height: 100%; }
#topbar {
  position: sticky; top: 0; z-index: 30;
  height: calc(var(--top-h) + var(--safe-t)); padding: var(--safe-t) 14px 0;
  display: flex; align-items: center; gap: 12px;
  background: rgba(14, 11, 9, 0.82);
  backdrop-filter: saturate(160%) blur(18px); -webkit-backdrop-filter: saturate(160%) blur(18px);
  border-bottom: 1px solid var(--line);
}
#topbar .title { font-weight: 800; font-size: 19px; letter-spacing: -0.01em; flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
#topbar .wordmark { height: 26px; width: auto; }
#topbar .spacer { flex: 1; }
.icon-btn { width: 40px; height: 40px; display: grid; place-items: center; border-radius: 50%; position: relative; }
.icon-btn:active { background: var(--surface-2); }
.badge {
  position: absolute; top: 4px; right: 3px; min-width: 18px; height: 18px; padding: 0 5px;
  border-radius: 9px; background: var(--grad); color: #1a0f05; font-size: 11px; font-weight: 800;
  display: grid; place-items: center; border: 2px solid var(--bg);
}

#view { padding-bottom: calc(var(--tab-h) + var(--safe-b) + 18px); min-height: 60vh; }

#tabbar {
  position: fixed; z-index: 40; left: 12px; right: 12px;
  bottom: calc(10px + var(--safe-b)); height: var(--tab-h);
  max-width: 520px; margin: 0 auto;
  display: grid; grid-template-columns: repeat(5, 1fr); align-items: center;
  background: rgba(30, 24, 19, 0.86);
  backdrop-filter: saturate(170%) blur(22px); -webkit-backdrop-filter: saturate(170%) blur(22px);
  border: 1px solid var(--line); border-radius: 26px;
  box-shadow: 0 12px 40px rgba(0, 0, 0, 0.45);
}
#tabbar a, #tabbar button { height: 100%; display: grid; place-items: center; position: relative; color: var(--muted); transition: color .15s; }
#tabbar .active { color: var(--text); }
#tabbar .active::after {
  content: ""; position: absolute; bottom: 9px; width: 5px; height: 5px; border-radius: 50%; background: var(--b1);
}
#tabbar .create-btn span {
  width: 50px; height: 40px; border-radius: 15px; display: grid; place-items: center;
  background: var(--grad); color: #1d1006; box-shadow: 0 6px 18px rgba(236, 138, 20, 0.35);
}
#tabbar .me-avatar { width: 28px; height: 28px; }
#tabbar .active .me-avatar { box-shadow: 0 0 0 2px var(--bg), 0 0 0 3.5px var(--b1); }
body.reels-mode #tabbar { background: rgba(10, 8, 6, 0.75); }
body.no-chrome #tabbar, body.no-chrome #topbar { display: none; }

/* ---------- Avatare & Story-Ringe ---------- */
.avatar {
  width: 36px; height: 36px; border-radius: 50%; object-fit: cover; flex: none;
  background: var(--surface-3); display: grid; place-items: center; overflow: hidden;
  font-weight: 800; color: #1d1006; background-image: var(--grad); font-size: 14px; text-transform: uppercase;
}
img.avatar { background: var(--surface-3); }
.ring { padding: 2.5px; border-radius: 50%; background: var(--grad); display: inline-grid; flex: none; }
.ring.seen { background: var(--surface-3); }
.ring > .avatar, .ring > img { border: 2.5px solid var(--bg); }
.ring.none { background: transparent; padding: 0; }
.ring.none > .avatar { border: 0; }

/* ---------- Stories-Leiste ---------- */
.stories { display: flex; gap: 14px; overflow-x: auto; padding: 14px 14px 10px; scrollbar-width: none; }
.stories::-webkit-scrollbar { display: none; }
.story-chip { display: flex; flex-direction: column; align-items: center; gap: 6px; width: 72px; flex: none; position: relative; }
.story-chip .avatar { width: 64px; height: 64px; font-size: 22px; }
.story-chip .label { font-size: 12px; max-width: 74px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; color: var(--muted); }
.story-chip.unseen .label { color: var(--text); }
.story-chip .add {
  position: absolute; right: 2px; top: 46px; width: 24px; height: 24px; border-radius: 50%;
  background: var(--grad); color: #1d1006; display: grid; place-items: center; border: 3px solid var(--bg);
}

/* ---------- Beitragskarte ---------- */
.feed { display: flex; flex-direction: column; gap: 14px; padding: 4px 10px 0; max-width: 560px; margin: 0 auto; }
.post { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; }
.post-head { display: flex; align-items: center; gap: 10px; padding: 10px 8px 10px 12px; }
.post-head .who { flex: 1; min-width: 0; line-height: 1.2; }
.post-head .who b { font-weight: 700; font-size: 14.5px; }
.post-head .who small { display: block; color: var(--muted); font-size: 12px; }
.post-head .follow-inline { color: var(--b1); font-weight: 700; font-size: 14px; padding: 6px 8px; }
.media { position: relative; background: #000; overflow: hidden; user-select: none; -webkit-user-select: none; }
.media img, .media video { width: 100%; height: 100%; object-fit: cover; }
.media .mute-pill, .reel .mute-pill {
  position: absolute; right: 10px; bottom: 10px; width: 30px; height: 30px; border-radius: 50%;
  background: rgba(0, 0, 0, 0.55); display: grid; place-items: center; color: #fff;
}
.media .reel-tag {
  position: absolute; left: 10px; top: 10px; padding: 4px 9px 4px 6px; border-radius: 999px; font-size: 12px; font-weight: 700;
  background: rgba(0, 0, 0, 0.5); display: flex; align-items: center; gap: 4px; color: #fff;
}
.burst { position: absolute; left: 50%; top: 50%; width: 110px; height: 110px; margin: -55px 0 0 -55px; pointer-events: none; color: var(--b1);
  filter: drop-shadow(0 6px 22px rgba(0, 0, 0, 0.45)); animation: burst .9s ease forwards; }
.burst svg { width: 100%; height: 100%; }
@keyframes burst { 0% { transform: scale(0); opacity: 0; } 15% { transform: scale(1.2); opacity: 1; } 30% { transform: scale(.95); } 45% { transform: scale(1); } 80% { opacity: 1; } 100% { transform: scale(1.1) translateY(-20px); opacity: 0; } }
.post-actions { display: flex; align-items: center; gap: 4px; padding: 6px 6px 0; }
.post-actions .act { display: flex; align-items: center; gap: 5px; padding: 6px; border-radius: 12px; font-weight: 600; font-size: 14px; }
.post-actions .act:active { transform: scale(.9); }
.post-actions .grow { flex: 1; }
.act.on { color: var(--b1); }
.act.pop svg { animation: pop .35s ease; }
@keyframes pop { 40% { transform: scale(1.3); } }
.post-body { padding: 4px 14px 14px; font-size: 14.5px; }
.post-body .caption { white-space: pre-wrap; word-wrap: break-word; }
.post-body .caption b { font-weight: 700; margin-right: 6px; }
.caption .mention { color: var(--b1); font-weight: 600; }
.caption .tag { color: #f7c869; }
.post-body .more-comments { color: var(--muted); margin-top: 6px; display: block; }
.post-body .likes-line { font-weight: 700; margin-bottom: 4px; }

/* ---------- Hinweise / leere Zustände ---------- */
.empty { text-align: center; padding: 56px 28px; color: var(--muted); }
.empty .big { width: 76px; height: 76px; margin: 0 auto 16px; border-radius: 26px; display: grid; place-items: center; background: var(--surface-2); color: var(--b1); }
.empty h3 { color: var(--text); margin: 0 0 6px; font-size: 19px; }
.banner { margin: 6px 10px 2px; padding: 14px 16px; border-radius: var(--radius); background: linear-gradient(135deg, rgba(245, 172, 23, .16), rgba(220, 108, 18, .1)); border: 1px solid rgba(245, 172, 23, .25); max-width: 540px; }
@media (min-width: 580px) { .banner { margin-left: auto; margin-right: auto; } }
.banner b { display: block; margin-bottom: 2px; }
.suggest { display: flex; gap: 10px; overflow-x: auto; padding: 12px 10px 4px; scrollbar-width: none; }
.suggest::-webkit-scrollbar { display: none; }
.suggest-card { flex: none; width: 140px; padding: 14px 10px; border-radius: 18px; background: var(--surface); border: 1px solid var(--line); text-align: center; display: flex; flex-direction: column; align-items: center; gap: 6px; }
.suggest-card .avatar { width: 60px; height: 60px; font-size: 22px; }
.suggest-card .n { font-weight: 700; font-size: 13.5px; max-width: 120px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.spinner { width: 28px; height: 28px; margin: 28px auto; border-radius: 50%; border: 3px solid var(--surface-3); border-top-color: var(--b1); animation: spin .8s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }
.sentinel { height: 1px; }

/* ---------- Buttons & Formulare ---------- */
.btn { height: 40px; padding: 0 18px; border-radius: 13px; font-weight: 700; font-size: 14.5px; display: inline-flex; align-items: center; justify-content: center; gap: 6px; background: var(--surface-3); color: var(--text); }
.btn:active { transform: scale(.97); }
.btn.primary { background: var(--grad); color: #1d1006; }
.btn.block { width: 100%; height: 48px; font-size: 16px; border-radius: 15px; }
.btn.sm { height: 32px; padding: 0 14px; font-size: 13.5px; border-radius: 10px; }
.btn[disabled] { opacity: .5; pointer-events: none; }
.btn.danger { color: var(--danger); }
.field { display: block; margin-bottom: 12px; }
.field span { display: block; font-size: 13px; color: var(--muted); margin: 0 0 6px 4px; }
.input { width: 100%; height: 50px; padding: 0 16px; border-radius: 15px; border: 1px solid var(--line); background: var(--surface-2); outline: none; font-size: 16px; }
textarea.input { height: auto; min-height: 96px; padding: 13px 16px; resize: none; line-height: 1.45; }
.input:focus { border-color: rgba(245, 172, 23, .6); box-shadow: 0 0 0 3px rgba(245, 172, 23, .14); }
.form-error { color: var(--danger); font-size: 14px; min-height: 20px; margin: 4px 4px 10px; }

/* ---------- Anmeldung ---------- */
.auth { min-height: 100vh; min-height: 100dvh; display: flex; flex-direction: column; justify-content: center; padding: calc(30px + var(--safe-t)) 24px calc(30px + var(--safe-b)); max-width: 440px; margin: 0 auto;
  background: radial-gradient(120% 60% at 50% -10%, rgba(245, 172, 23, .18), transparent 60%); }
.auth .logo { width: 220px; margin: 0 auto 10px; }
.auth .tagline { text-align: center; color: var(--muted); margin: 0 0 30px; }
.seg { display: grid; grid-template-columns: 1fr 1fr; background: var(--surface-2); padding: 4px; border-radius: 15px; margin-bottom: 18px; }
.seg button { height: 40px; border-radius: 11px; font-weight: 700; color: var(--muted); }
.seg button.on { background: var(--surface-3); color: var(--text); }
.legal { text-align: center; font-size: 12px; color: var(--muted); margin-top: 18px; }

/* ---------- Profil ---------- */
.profile { max-width: 600px; margin: 0 auto; }
.p-head { display: flex; align-items: center; gap: 20px; padding: 18px 18px 8px; }
.p-head .avatar { width: 88px; height: 88px; font-size: 34px; }
.p-stats { flex: 1; display: grid; grid-template-columns: repeat(3, 1fr); text-align: center; }
.p-stats b { display: block; font-size: 18px; font-weight: 800; }
.p-stats span { font-size: 12.5px; color: var(--muted); }
.p-info { padding: 4px 18px 0; }
.p-info .name { font-weight: 800; font-size: 16px; }
.p-info .bio { white-space: pre-wrap; margin-top: 2px; }
.p-info .follows-you { font-size: 12px; color: var(--muted); background: var(--surface-2); padding: 2px 8px; border-radius: 6px; display: inline-block; margin-top: 4px; }
.p-actions { display: flex; gap: 8px; padding: 14px 18px; }
.p-actions .btn { flex: 1; }
.tabs { display: grid; grid-auto-flow: column; grid-auto-columns: 1fr; border-bottom: 1px solid var(--line); position: sticky; top: calc(var(--top-h) + var(--safe-t)); background: var(--bg); z-index: 5; }
.tabs button { height: 46px; display: grid; place-items: center; color: var(--muted); position: relative; }
.tabs button.on { color: var(--text); }
.tabs button.on::after { content: ""; position: absolute; bottom: -1px; left: 30%; right: 30%; height: 3px; border-radius: 3px; background: var(--grad); }

/* ---------- Raster ---------- */
.grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 2px; }
.grid .tile { position: relative; aspect-ratio: 1; background: var(--surface-2); overflow: hidden; }
.grid.tall .tile { aspect-ratio: 9 / 16; }
.grid .tile img { width: 100%; height: 100%; object-fit: cover; }
.grid .tile .ic { position: absolute; top: 6px; right: 6px; color: #fff; filter: drop-shadow(0 1px 3px rgba(0, 0, 0, .7)); }
.grid .tile .views { position: absolute; left: 6px; bottom: 6px; display: flex; align-items: center; gap: 3px; color: #fff; font-size: 12.5px; font-weight: 700; text-shadow: 0 1px 3px rgba(0,0,0,.7); }
.explore-grid { grid-auto-flow: dense; }
.explore-grid .tile:nth-child(10n + 3) { grid-row: span 2; aspect-ratio: auto; }
.tile .noimg { width: 100%; height: 100%; display: grid; place-items: center; color: var(--muted); background: linear-gradient(160deg, var(--surface-3), var(--surface)); }

/* ---------- Suche ---------- */
.search { flex: 1; position: relative; display: block; }
.search input { width: 100%; height: 40px; border-radius: 13px; border: 0; background: var(--surface-2); padding: 0 14px 0 40px; outline: none; font-size: 16px; }
.search svg { position: absolute; left: 11px; top: 10px; color: var(--muted); }
.list { padding: 6px 0; }
.row { display: flex; align-items: center; gap: 12px; padding: 9px 16px; }
.row .avatar { width: 46px; height: 46px; font-size: 18px; }
.row .grow { flex: 1; min-width: 0; line-height: 1.25; }
.row .grow b { font-weight: 700; display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.row .grow small { color: var(--muted); font-size: 13.5px; }
.row .thumb { width: 46px; height: 46px; border-radius: 10px; object-fit: cover; background: var(--surface-2); }
.row.unread { background: rgba(245, 172, 23, .06); }
.section-title { font-weight: 800; font-size: 16px; padding: 14px 16px 4px; }

/* ---------- Reels ---------- */
body.reels-mode { background: #000; }
.reels { position: fixed; inset: 0; overflow-y: scroll; scroll-snap-type: y mandatory; background: #000; scrollbar-width: none; overscroll-behavior: contain; }
.reels::-webkit-scrollbar { display: none; }
.reel { position: relative; height: 100vh; height: 100dvh; scroll-snap-align: start; scroll-snap-stop: always; overflow: hidden; background: #000; }
.reel video { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.reel.contain video { object-fit: contain; }
.reel .shade { position: absolute; inset: 0; pointer-events: none; background: linear-gradient(to bottom, rgba(0,0,0,.35) 0%, transparent 18%, transparent 55%, rgba(0,0,0,.65) 100%); }
.reel .rail { position: absolute; right: 8px; bottom: calc(var(--tab-h) + var(--safe-b) + 34px); display: flex; flex-direction: column; align-items: center; gap: 16px; color: #fff; }
.reel .rail button { display: flex; flex-direction: column; align-items: center; gap: 3px; font-size: 12.5px; font-weight: 700; text-shadow: 0 1px 4px rgba(0, 0, 0, .6); }
.reel .rail svg { filter: drop-shadow(0 1px 4px rgba(0, 0, 0, .5)); }
.reel .rail .on { color: var(--b1); }
.reel .info { position: absolute; left: 14px; right: 78px; bottom: calc(var(--tab-h) + var(--safe-b) + 34px); color: #fff; text-shadow: 0 1px 4px rgba(0, 0, 0, .6); }
.reel .info .u { display: flex; align-items: center; gap: 10px; font-weight: 700; margin-bottom: 8px; }
.reel .info .u .avatar { width: 34px; height: 34px; border: 1.5px solid #fff; }
.reel .info .u .btn { height: 28px; padding: 0 12px; font-size: 13px; background: transparent; border: 1.5px solid rgba(255,255,255,.85); border-radius: 9px; text-shadow: none; }
.reel .info .cap { font-size: 14px; max-height: 3.9em; overflow: hidden; white-space: pre-wrap; }
.reel .info .cap.open { max-height: 40vh; overflow-y: auto; }
.reel .mute-pill { top: calc(var(--safe-t) + 66px); bottom: auto; right: 14px; width: 36px; height: 36px; }
.reel .play-ind { position: absolute; left: 50%; top: 50%; width: 76px; height: 76px; margin: -38px 0 0 -38px; border-radius: 50%; background: rgba(0,0,0,.45); color: #fff; display: grid; place-items: center; pointer-events: none; opacity: 0; transition: opacity .2s; }
.reel.paused .play-ind { opacity: 1; }
.reel .progress { position: absolute; left: 0; right: 0; bottom: calc(var(--tab-h) + var(--safe-b) + 14px); height: 2px; background: rgba(255,255,255,.2); margin: 0 14px; border-radius: 2px; overflow: hidden; }
.reel .progress i { display: block; height: 100%; width: 0; background: var(--grad); }
.reels-top { position: fixed; z-index: 20; top: 0; left: 0; right: 0; padding: calc(var(--safe-t) + 8px) 12px 0; display: flex; align-items: center; color: #fff; pointer-events: none; }
.reels-top > * { pointer-events: auto; }
.reels-top .title { font-weight: 800; font-size: 21px; flex: 1; text-shadow: 0 1px 6px rgba(0,0,0,.5); padding-left: 4px; }

/* ---------- Overlays: Sheets, Story, Composer ---------- */
.scrim { position: fixed; inset: 0; z-index: 60; background: rgba(0, 0, 0, .55); animation: fade .2s ease; }
@keyframes fade { from { opacity: 0; } }
.sheet {
  position: fixed; z-index: 61; left: 0; right: 0; bottom: 0; max-width: 600px; margin: 0 auto;
  background: var(--surface); border-radius: 26px 26px 0 0; border-top: 1px solid var(--line);
  padding: 8px 0 calc(12px + var(--safe-b)); animation: up .26s cubic-bezier(.2,.9,.3,1);
  max-height: 88vh; display: flex; flex-direction: column;
}
@keyframes up { from { transform: translateY(100%); } }
.sheet .grab { width: 40px; height: 5px; border-radius: 3px; background: var(--surface-3); margin: 2px auto 8px; flex: none; }
.sheet h4 { margin: 0; text-align: center; font-size: 16px; padding: 4px 0 10px; border-bottom: 1px solid var(--line); flex: none; }
.sheet .scroll { overflow-y: auto; flex: 1; min-height: 120px; }
.sheet .opt { display: flex; align-items: center; gap: 14px; width: 100%; padding: 15px 22px; font-size: 16px; font-weight: 600; text-align: left; }
.sheet .opt:active { background: var(--surface-2); }
.sheet .opt.danger { color: var(--danger); }
.sheet .opt small { display: block; font-weight: 400; color: var(--muted); font-size: 13px; }
.sheet .opt .oi { width: 42px; height: 42px; border-radius: 14px; background: var(--surface-2); display: grid; place-items: center; color: var(--b1); }
.comments.sheet { height: 78vh; }
.comment { display: flex; gap: 11px; padding: 10px 16px; }
.comment .avatar { width: 34px; height: 34px; }
.comment .c-body { flex: 1; min-width: 0; font-size: 14.5px; }
.comment .c-body b { font-weight: 700; margin-right: 6px; }
.comment .c-body .t { white-space: pre-wrap; word-wrap: break-word; }
.comment .c-meta { font-size: 12px; color: var(--muted); margin-top: 3px; display: flex; gap: 12px; }
.composer-row { display: flex; gap: 10px; align-items: center; padding: 10px 14px 0; border-top: 1px solid var(--line); flex: none; }
.composer-row .input { height: 44px; border-radius: 22px; }
.composer-row .send { color: var(--b1); font-weight: 800; padding: 0 6px; }

.fullscreen { position: fixed; inset: 0; z-index: 70; background: var(--bg); display: flex; flex-direction: column; animation: fade .2s; }
.fs-top { height: calc(var(--top-h) + var(--safe-t)); padding: var(--safe-t) 10px 0; display: flex; align-items: center; gap: 8px; border-bottom: 1px solid var(--line); flex: none; }
.fs-top .title { flex: 1; font-weight: 800; font-size: 17px; }
.fs-body { flex: 1; overflow-y: auto; padding: 16px; padding-bottom: calc(16px + var(--safe-b)); }
.compose-preview { border-radius: var(--radius); overflow: hidden; background: #000; max-height: 56vh; display: grid; place-items: center; margin-bottom: 14px; }
.compose-preview img, .compose-preview video { max-height: 56vh; width: auto; max-width: 100%; }
.progressbar { height: 6px; border-radius: 3px; background: var(--surface-3); overflow: hidden; margin: 12px 0 4px; }
.progressbar i { display: block; height: 100%; width: 0; background: var(--grad); transition: width .15s; }

.story-viewer { position: fixed; inset: 0; z-index: 80; background: #000; color: #fff; touch-action: none; animation: fade .2s; }
.story-viewer .stage { position: absolute; inset: 0; display: grid; place-items: center; }
.story-viewer .stage img, .story-viewer .stage video { width: 100%; height: 100%; object-fit: contain; }
.story-viewer .bars { position: absolute; top: calc(var(--safe-t) + 8px); left: 8px; right: 8px; display: flex; gap: 4px; z-index: 2; }
.story-viewer .bars span { flex: 1; height: 3px; border-radius: 2px; background: rgba(255,255,255,.3); overflow: hidden; }
.story-viewer .bars i { display: block; height: 100%; width: 0; background: #fff; }
.story-viewer .s-head { position: absolute; top: calc(var(--safe-t) + 20px); left: 12px; right: 6px; display: flex; align-items: center; gap: 10px; z-index: 2; text-shadow: 0 1px 4px rgba(0,0,0,.6); }
.story-viewer .s-head .avatar { width: 34px; height: 34px; }
.story-viewer .s-head .grow { flex: 1; font-weight: 700; font-size: 14.5px; }
.story-viewer .s-head small { font-weight: 400; opacity: .75; margin-left: 6px; }
.story-viewer .s-foot { position: absolute; bottom: calc(var(--safe-b) + 18px); left: 16px; right: 16px; display: flex; align-items: center; gap: 10px; z-index: 2; }
.story-viewer .s-foot .views { display: flex; align-items: center; gap: 6px; font-weight: 600; flex: 1; }

.toast { position: fixed; z-index: 100; left: 50%; bottom: calc(var(--tab-h) + var(--safe-b) + 28px); transform: translateX(-50%); background: #f8f1ea; color: #1a120c; padding: 11px 18px; border-radius: 14px; font-weight: 600; font-size: 14px; box-shadow: 0 10px 30px rgba(0,0,0,.4); animation: up .25s ease; max-width: calc(100vw - 40px); text-align: center; }

.edit-avatar { display: flex; flex-direction: column; align-items: center; gap: 10px; margin: 6px 0 22px; }
.edit-avatar .avatar { width: 96px; height: 96px; font-size: 36px; }
.edit-avatar button { color: var(--b1); font-weight: 700; }
.counter { text-align: right; font-size: 12px; color: var(--muted); margin: -8px 4px 10px; }
.settings-group { margin-top: 26px; padding-top: 18px; border-top: 1px solid var(--line); }
.settings-group h5 { margin: 0 0 12px 4px; font-size: 13px; text-transform: uppercase; letter-spacing: .06em; color: var(--muted); }

@media (min-width: 700px) {
  .feed { padding-top: 10px; }
  .reel { max-width: 480px; margin: 0 auto; }
}

/* ---------- Verifizierungs-Häkchen ---------- */
.vbadge { display: inline-flex; vertical-align: -0.16em; margin-left: 4px; cursor: pointer; line-height: 0; }
.vbadge svg { display: block; overflow: visible; }
#topbar .title .vbadge { vertical-align: -0.12em; }
.p-info .name .vbadge { vertical-align: -0.18em; }
.official-line { font-size: 12.5px; font-weight: 700; margin-top: 2px; background: linear-gradient(135deg, #ffe7a3, #d9a33a); -webkit-background-clip: text; background-clip: text; color: transparent; }
.reel .info .vbadge { filter: drop-shadow(0 1px 3px rgba(0,0,0,.5)); }

/* ---------- Verwaltung ---------- */
.admin { max-width: 640px; margin: 0 auto; padding-top: 12px; }
.stat-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; padding: 0 14px; }
.stat-grid > div { background: var(--surface); border: 1px solid var(--line); border-radius: 18px; padding: 13px 15px; display: flex; flex-direction: column; }
.stat-grid b { font-size: 24px; font-weight: 800; line-height: 1.1; }
.stat-grid span { font-weight: 600; font-size: 14px; }
.stat-grid small { color: var(--muted); font-size: 12px; margin-top: 2px; }
.stat-grid .alert { border-color: rgba(255, 90, 78, .45); background: rgba(255, 90, 78, .08); }
.chips { display: flex; gap: 8px; padding: 8px 14px 2px; overflow-x: auto; scrollbar-width: none; }
.chips button { flex: none; height: 32px; padding: 0 14px; border-radius: 16px; background: var(--surface-2); color: var(--muted); font-weight: 600; font-size: 13.5px; }
.chips button.on { background: var(--text); color: var(--bg); }
.admin-row { width: 100%; text-align: left; }
.admin-row:active { background: var(--surface-2); }
.admin-row .grow small { display: block; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.pill { display: inline-block; font-size: 11px; font-weight: 700; padding: 2px 7px; border-radius: 6px; background: var(--surface-3); color: var(--text); vertical-align: 0.1em; }
.pill.danger { background: rgba(255, 90, 78, .16); color: var(--danger); }
.reports { padding: 8px 14px; display: flex; flex-direction: column; gap: 10px; }
.report { display: flex; gap: 12px; background: var(--surface); border: 1px solid var(--line); border-radius: 18px; padding: 12px; }
.report img, .report .noimg { width: 72px; height: 72px; border-radius: 12px; object-fit: cover; flex: none; display: grid; place-items: center; background: var(--surface-2); }
.report .grow { flex: 1; min-width: 0; }
.report .reasons { display: flex; flex-wrap: wrap; gap: 5px; margin: 6px 0; }
.report .cap { font-size: 13px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.r-actions { display: flex; gap: 6px; margin-top: 8px; flex-wrap: wrap; }

/* =========================================================
   Version 3: Animationen, eigene Symbole, Nachrichten, Kamera
   ========================================================= */
body.no-scroll { overflow: hidden; }
.view-enter { animation: viewIn .32s cubic-bezier(.2,.8,.2,1); }
@keyframes viewIn { from { opacity: 0; transform: translateY(10px); } }

/* Platzhalter */
.sk { background: linear-gradient(100deg, var(--surface-2) 30%, var(--surface-3) 50%, var(--surface-2) 70%); background-size: 300% 100%; animation: shimmer 1.3s ease-in-out infinite; }
@keyframes shimmer { from { background-position: 100% 0; } to { background-position: 0 0; } }
.story-chip .sk + .sk { margin-top: 2px; }

/* Ziehen zum Aktualisieren */
.ptr { position: fixed; z-index: 35; left: 50%; top: calc(var(--top-h) + var(--safe-t) - 30px); width: 40px; height: 40px; border-radius: 50%;
  background: var(--surface-2); border: 1px solid var(--line); display: grid; place-items: center; opacity: 0; transform: translate(-50%, 0);
  box-shadow: 0 8px 24px rgba(0,0,0,.4); pointer-events: none; transition: opacity .2s; }
.ptr img { width: 24px; height: 24px; }
.ptr.ready { border-color: rgba(245,172,23,.6); }
.ptr.spin img { animation: spin .7s linear infinite; }
.ptr.spin { transition: transform .25s ease, opacity .2s; }

/* Flammen-Burst & Funken */
.burst { width: 120px; height: 120px; margin: -60px 0 0 -60px; }
.burst > svg { width: 100%; height: 100%; }
.burst .sparks { position: absolute; left: 50%; top: 55%; }
.burst .sparks i { position: absolute; width: var(--s); height: var(--s); margin: calc(var(--s) / -2); border-radius: 50%; background: #ffd36b;
  box-shadow: 0 0 8px #f5ac17; animation: spark .75s ease-out forwards; }
@keyframes spark { 0% { transform: rotate(var(--a)) translateY(0) scale(1); opacity: 1; } 100% { transform: rotate(var(--a)) translateY(calc(var(--d) * -1)) scale(.2); opacity: 0; } }
.act.pop svg, .c-like.pop svg { animation: flamePop .45s cubic-bezier(.3,1.6,.5,1); }
@keyframes flamePop { 0% { transform: scale(1); } 35% { transform: scale(1.4) rotate(-8deg); } 65% { transform: scale(.92) rotate(4deg); } 100% { transform: scale(1); } }
.act.drop svg { animation: pinDrop .45s cubic-bezier(.3,1.5,.5,1); }
@keyframes pinDrop { 0% { transform: translateY(-9px) rotate(-18deg); } 60% { transform: translateY(2px) rotate(4deg); } 100% { transform: none; } }
.bump { display: inline-block; animation: bump .35s ease; }
@keyframes bump { 40% { transform: translateY(-4px) scale(1.15); } }
.act.on svg { filter: drop-shadow(0 2px 6px rgba(236,138,20,.35)); }

/* Konfetti beim Folgen */
.confetti { position: fixed; z-index: 120; pointer-events: none; }
.confetti i { position: absolute; width: 6px; height: 6px; border-radius: 2px; animation: conf .7s cubic-bezier(.2,.7,.3,1) forwards; }
@keyframes conf { 0% { transform: rotate(var(--a)) translateY(0); opacity: 1; } 100% { transform: rotate(var(--a)) translateY(calc(var(--d) * -1)) rotate(180deg); opacity: 0; } }
.btn.morph, .follow-inline.morph { animation: morph .45s cubic-bezier(.3,1.5,.5,1); }
@keyframes morph { 0% { transform: scale(1); } 30% { transform: scale(.88); } 70% { transform: scale(1.06); } 100% { transform: scale(1); } }
.btn svg.sm, .follow-inline svg.sm { width: 17px; height: 17px; }
.follow-inline { display: inline-flex; align-items: center; gap: 3px; transition: color .2s; }
.follow-inline.done { color: var(--muted); }

/* Navigation */
#tabbar .active svg, #tabbar .active .me-avatar { animation: tabPop .4s cubic-bezier(.3,1.6,.5,1); }
@keyframes tabPop { 0% { transform: scale(.8); } 60% { transform: scale(1.12); } 100% { transform: scale(1); } }
#tabbar a:active svg, #tabbar button:active span { transform: scale(.88); transition: transform .1s; }
.badge.pop-in { animation: tabPop .4s cubic-bezier(.3,1.6,.5,1); }

/* Kommentare */
.comment { align-items: flex-start; }
.comment.arrive { animation: arrive .35s cubic-bezier(.2,.9,.3,1.2); }
.comment.leaving { animation: leave .25s ease forwards; }
@keyframes arrive { from { opacity: 0; transform: translateY(10px) scale(.98); } }
@keyframes leave { to { opacity: 0; transform: translateX(30px); } }
.c-meta button { color: var(--muted); font-weight: 600; }
.c-like { display: flex; flex-direction: column; align-items: center; gap: 1px; color: var(--muted); font-size: 11px; padding: 4px 2px; min-width: 28px; }
.c-like.on { color: var(--b1); }

/* Gemeldet */
.report-done { text-align: center; padding: 14px 26px 22px; }
.report-done h3 { margin: 12px 0 6px; }
.report-done p { margin: 0; }
.ok-circle { width: 72px; height: 72px; margin: 4px auto 0; border-radius: 50%; background: var(--grad); color: #1d1006; display: grid; place-items: center; animation: tabPop .5s cubic-bezier(.3,1.6,.5,1); }
.ok-circle svg { stroke-width: 2.6; stroke-dasharray: 30; stroke-dashoffset: 30; animation: draw .45s .2s ease forwards; }
@keyframes draw { to { stroke-dashoffset: 0; } }

/* Teilen */
.share-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 14px 6px; padding: 14px 12px; max-height: 42vh; overflow-y: auto; }
.pick { display: flex; flex-direction: column; align-items: center; gap: 6px; }
.pick-av { position: relative; display: inline-grid; border-radius: 50%; transition: transform .2s; }
.pick-av i { position: absolute; right: -2px; bottom: -2px; width: 24px; height: 24px; border-radius: 50%; background: var(--grad); color: #1d1006; display: grid; place-items: center;
  border: 2.5px solid var(--surface); transform: scale(0); transition: transform .25s cubic-bezier(.3,1.6,.5,1); }
.pick.on .pick-av { transform: scale(.92); }
.pick.on .pick-av i { transform: scale(1); }
.pick .pn { font-size: 12px; max-width: 76px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.share-send { padding: 6px 14px 10px; display: flex; flex-direction: column; gap: 8px; animation: up .25s ease; }
.share-row { display: flex; gap: 16px; padding: 10px 18px 4px; border-top: 1px solid var(--line); }
.share-row button { display: flex; flex-direction: column; align-items: center; gap: 6px; font-size: 12px; color: var(--muted); }
.share-row span { width: 50px; height: 50px; border-radius: 50%; background: var(--surface-2); display: grid; place-items: center; color: var(--text); }

/* Hashtag */
.tag-head { display: flex; align-items: center; gap: 16px; padding: 18px; }
.tag-ic { width: 76px; height: 76px; border-radius: 50%; display: grid; place-items: center; background: var(--grad); color: #1d1006; }
.tag-head b { display: block; font-size: 20px; font-weight: 800; }
.caption a.tag, .t a.tag, .bubble a.tag, .cap a.tag { color: #f7c869; font-weight: 600; }

/* Nachrichten */
.inbox .row { animation: viewIn .35s both; }
.inbox .row.unread b, .inbox .row.unread small { color: var(--text); font-weight: 700; }
.inbox .dot { width: 10px; height: 10px; border-radius: 50%; background: var(--grad); flex: none; }
body.chat-mode #tabbar { display: none; }
body.chat-mode #view { padding-bottom: calc(80px + var(--safe-b)); }
.chat-who { display: flex; align-items: center; gap: 10px; flex: 1; min-width: 0; }
.chat-who .avatar { width: 34px; height: 34px; }
.chat-who span { line-height: 1.15; min-width: 0; }
.chat-who b { display: block; font-size: 15px; }
.chat-who small { color: var(--muted); font-size: 12px; }
.chat { max-width: 640px; margin: 0 auto; padding: 12px 12px 6px; }
.msgs { display: flex; flex-direction: column; gap: 3px; }
.msg { display: flex; flex-direction: column; align-items: flex-start; max-width: 78%; }
.msg.mine { align-self: flex-end; align-items: flex-end; }
.msg.arrive { animation: msgIn .35s cubic-bezier(.2,.9,.3,1.3); }
@keyframes msgIn { from { opacity: 0; transform: translateY(12px) scale(.9); } }
.bubble { padding: 9px 14px; border-radius: 20px; background: var(--surface-2); white-space: pre-wrap; word-wrap: break-word; font-size: 15px; }
.msg.mine .bubble { background: var(--grad); color: #1d1006; }
.msg.mine .bubble a { color: #1d1006; text-decoration: underline; }
.bubble.big-emoji { background: none !important; font-size: 40px; padding: 0 4px; line-height: 1.1; }
.msg-time { text-align: center; font-size: 12px; color: var(--muted); margin: 14px 0 6px; }
.seen { align-self: flex-end; font-size: 11.5px; color: var(--muted); margin: 2px 6px 0; animation: viewIn .3s; }
.msg-card { display: block; width: 220px; border-radius: 18px; overflow: hidden; background: var(--surface-2); border: 1px solid var(--line); margin-bottom: 3px; }
.msg-card.muted { padding: 12px 14px; font-size: 13px; }
.msg-card img { width: 100%; aspect-ratio: 4 / 5; object-fit: cover; }
.mc-head { display: flex; align-items: center; gap: 7px; padding: 8px 10px; font-size: 13px; }
.mc-cap { display: block; padding: 8px 10px; font-size: 12.5px; color: var(--muted); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.story-ref { display: flex; flex-direction: column; gap: 4px; margin-bottom: 3px; }
.msg.mine .story-ref { align-items: flex-end; }
.story-ref small { font-size: 11.5px; color: var(--muted); }
.story-ref img { width: 96px; aspect-ratio: 9 / 16; object-fit: cover; border-radius: 12px; border: 2px solid var(--surface-3); }
.chat-hello { display: flex; flex-direction: column; align-items: center; gap: 4px; padding: 40px 0 20px; text-align: center; }
.chat-hello b { font-size: 18px; margin-top: 8px; }
.chat-hello .btn { margin-top: 10px; }
.chat-bar { position: fixed; z-index: 40; left: 10px; right: 10px; bottom: calc(10px + var(--safe-b)); max-width: 620px; margin: 0 auto; display: flex; align-items: center; gap: 8px;
  background: rgba(30, 24, 19, .92); backdrop-filter: blur(20px); -webkit-backdrop-filter: blur(20px); border: 1px solid var(--line); border-radius: 26px; padding: 6px 6px 6px 18px; }
.chat-bar input { flex: 1; min-width: 0; background: none; border: 0; outline: none; height: 40px; font-size: 16px; }
.send-btn { width: 40px; height: 40px; border-radius: 50%; background: var(--surface-3); color: var(--muted); display: grid; place-items: center; transition: all .2s; }
.chat-bar.has-text .send-btn { background: var(--grad); color: #1d1006; transform: rotate(0) scale(1.05); }
.send-btn svg { stroke-width: 2.6; }

/* Reels-Extras */
.reel .info .meta-line { display: flex; align-items: center; gap: 4px; font-size: 12.5px; opacity: .85; margin-top: 6px; }
.reel .info .meta-line svg { width: 14px; height: 14px; fill: currentColor; }
.speed-pill { position: absolute; top: calc(var(--safe-t) + 66px); left: 50%; transform: translate(-50%, -10px); padding: 6px 14px; border-radius: 999px; background: rgba(0,0,0,.55); color: #fff;
  font-weight: 800; display: flex; align-items: center; gap: 2px; opacity: 0; transition: all .2s; pointer-events: none; }
.speed-pill svg { width: 14px; height: 14px; }
.reel.fast .speed-pill { opacity: 1; transform: translate(-50%, 0); }
.grid .tile .views svg { width: 14px; height: 14px; fill: currentColor; }

/* Story-Antworten */
.story-viewer .s-foot { left: 12px; right: 12px; }
.story-viewer .s-foot .views { color: #fff; font-weight: 600; display: flex; align-items: center; gap: 6px; flex: 1; }
.s-reply { width: 100%; display: flex; flex-direction: column; gap: 10px; }
.reacts { display: flex; justify-content: space-around; transition: opacity .2s, transform .2s; }
.reacts button { font-size: 28px; transition: transform .15s; }
.reacts button:active { transform: scale(1.35); }
.story-viewer:not(.typing) .reacts { opacity: 0; transform: translateY(10px); pointer-events: none; }
.reply-row { display: flex; align-items: center; gap: 8px; border: 1.5px solid rgba(255,255,255,.6); border-radius: 26px; padding: 4px 4px 4px 16px; background: rgba(0,0,0,.25); }
.reply-row input { flex: 1; min-width: 0; height: 38px; border: 0; background: none; outline: none; color: #fff; font-size: 16px; }
.reply-row input::placeholder { color: rgba(255,255,255,.75); }
.reply-row button { width: 38px; height: 38px; border-radius: 50%; display: grid; place-items: center; color: #fff; }
.story-viewer.typing .stage { filter: brightness(.55); transition: filter .2s; }
.fly-emoji { position: fixed; z-index: 130; font-size: 42px; pointer-events: none; transform: translate(-50%, 0); animation: fly 1.1s cubic-bezier(.2,.7,.3,1) forwards; }
@keyframes fly { 0% { transform: translate(-50%, 0) scale(.6); opacity: 1; } 100% { transform: translate(-50%, -55vh) scale(1.8) rotate(-12deg); opacity: 0; } }

/* Kamera */
.camera { position: fixed; inset: 0; z-index: 85; background: #000; color: #fff; touch-action: none; animation: camIn .3s cubic-bezier(.2,.8,.2,1); user-select: none; -webkit-user-select: none; }
@keyframes camIn { from { opacity: 0; transform: scale(1.04); } }
.cam-stage { position: absolute; inset: 0; overflow: hidden; }
.cam-live { width: 100%; height: 100%; object-fit: cover; }
.cam-live.mirror, .ed-video.mirror { transform: scaleX(-1); }
.cam-flash { position: absolute; inset: 0; background: #fff; opacity: 0; pointer-events: none; }
.cam-flash.go { animation: camFlash .35s ease-out; }
@keyframes camFlash { 0% { opacity: .9; } 100% { opacity: 0; } }
.cam-top { position: absolute; z-index: 3; top: 0; left: 0; right: 0; padding: calc(var(--safe-t) + 10px) 12px 0; display: flex; gap: 8px; align-items: center; }
.cam-top .grow { flex: 1; }
.cam-btn { width: 44px; height: 44px; border-radius: 50%; background: rgba(0,0,0,.35); display: grid; place-items: center; backdrop-filter: blur(8px); -webkit-backdrop-filter: blur(8px); }
.cam-btn.on { background: #ffd36b; color: #111; }
.cam-bottom { position: absolute; z-index: 3; left: 0; right: 0; bottom: calc(var(--safe-b) + 46px); display: flex; align-items: center; justify-content: space-around; padding: 0 20px; }
.cam-side { width: 50px; height: 50px; border-radius: 16px; background: rgba(255,255,255,.16); display: grid; place-items: center; backdrop-filter: blur(8px); -webkit-backdrop-filter: blur(8px); }
.cam-side.spin svg { animation: spinOnce .45s ease; }
@keyframes spinOnce { to { transform: rotate(180deg); } }
.shutter { position: relative; width: 88px; height: 88px; display: grid; place-items: center; touch-action: none; }
.shutter svg { position: absolute; inset: 0; transform: rotate(-90deg); }
.shutter circle { fill: none; stroke-width: 6; }
.shutter .track { stroke: rgba(255,255,255,.9); }
.shutter .prog { stroke: url(#xg-brand); stroke-dasharray: 251.3; stroke-dashoffset: 251.3; stroke-linecap: round; }
.shutter .core { width: 66px; height: 66px; border-radius: 50%; background: #fff; transition: transform .2s, background .2s, border-radius .2s; }
.shutter.down .core { transform: scale(.88); }
.camera.recording .shutter { transform: scale(1.15); transition: transform .2s; }
.camera.recording .shutter .track { stroke: rgba(255,255,255,.35); }
.camera.recording .shutter .core { background: #ff4a3d; transform: scale(.55); border-radius: 18px; }
.camera.recording .cam-side, .camera.recording .cam-hint, .camera.recording .cam-top { opacity: 0; pointer-events: none; }
.cam-hint { position: absolute; z-index: 3; left: 0; right: 0; bottom: calc(var(--safe-b) + 16px); text-align: center; font-size: 13px; opacity: .8; transition: opacity .2s; }
.rec-time { position: absolute; z-index: 3; top: calc(var(--safe-t) + 18px); left: 50%; transform: translateX(-50%); display: flex; align-items: center; gap: 7px; padding: 6px 12px; border-radius: 999px; background: rgba(0,0,0,.45); font-weight: 700; font-variant-numeric: tabular-nums; }
.rec-time i { width: 9px; height: 9px; border-radius: 50%; background: #ff4a3d; animation: blink 1s infinite; }
@keyframes blink { 50% { opacity: .2; } }
.cam-msg { position: absolute; z-index: 4; inset: 0; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 12px; padding: 30px; text-align: center; background: #0e0b09; }
.cam-msg p { color: var(--muted); max-width: 300px; margin: 0 0 6px; }
.cam-msg .btn { min-width: 220px; }
.cam-msg > div { width: 76px; height: 76px; border-radius: 26px; background: var(--surface-2); color: var(--b1); display: grid; place-items: center; }

/* Story-Editor */
.story-editor { position: absolute; inset: 0; z-index: 5; background: #000; display: grid; place-items: center; animation: fade .2s; }
.ed-stage { position: relative; aspect-ratio: 9 / 16; width: min(100vw, calc(100dvh * 9 / 16)); max-height: 100dvh; overflow: hidden; border-radius: 0; }
@media (min-aspect-ratio: 9/17) { .ed-stage { border-radius: 18px; } }
.ed-canvas, .ed-video { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: contain; background: #000; }
.ed-texts { position: absolute; inset: 0; }
.ed-text { position: absolute; width: max-content; transform: translate(-50%, -50%); font-weight: 800; font-size: calc(min(100vw, 100dvh * 9 / 16) * 0.075); line-height: 1.2; text-align: center; white-space: pre-wrap;
  max-width: 90%; padding: .1em .35em; border-radius: .3em; text-shadow: 0 2px 8px rgba(0,0,0,.45); touch-action: none; cursor: grab; transition: transform .15s, opacity .15s; }
.ed-text.pill { text-shadow: none; }
.ed-text.doomed { transform: translate(-50%, -50%) scale(.6); opacity: .5; }
.ed-trash { position: absolute; left: 50%; bottom: 26px; width: 54px; height: 54px; margin-left: -27px; border-radius: 50%; border: 2px solid #fff; display: grid; place-items: center;
  background: rgba(0,0,0,.4); opacity: 0; transform: scale(.7); transition: all .2s; pointer-events: none; }
.story-editor.dragging .ed-trash { opacity: 1; transform: scale(1); }
.ed-trash.hot { background: #ff4a3d; border-color: #ff4a3d; transform: scale(1.2) !important; }
.story-editor.dragging .cam-top, .story-editor.dragging .ed-bottom, .story-editor.dragging .filter-row { opacity: 0; pointer-events: none; }
.story-editor .cam-top, .ed-bottom, .filter-row { transition: opacity .2s; }
.ed-bottom { position: absolute; left: 0; right: 0; bottom: calc(var(--safe-b) + 18px); padding: 0 16px; display: flex; flex-direction: column; align-items: flex-end; gap: 10px; z-index: 3; }
.ed-bottom .progressbar { width: 100%; margin: 0; }
.share-story { height: 46px; padding: 0 8px 0 6px; border-radius: 23px; gap: 8px; box-shadow: 0 8px 26px rgba(0,0,0,.4); }
.share-story .avatar { border: 2px solid #1d1006; }
.share-story svg.i { width: 30px; height: 30px; padding: 6px; border-radius: 50%; background: #1d1006; color: #f5ac17; stroke-width: 2.6; transform: rotate(90deg); }
.filter-row { position: absolute; z-index: 3; left: 0; right: 0; bottom: calc(var(--safe-b) + 80px); display: flex; gap: 10px; overflow-x: auto; padding: 0 16px; scrollbar-width: none; animation: up .25s ease; }
.filter-row::-webkit-scrollbar { display: none; }
.filter-row button { flex: none; display: flex; flex-direction: column; align-items: center; gap: 4px; font-size: 11.5px; font-weight: 600; text-shadow: 0 1px 3px rgba(0,0,0,.8); }
.filter-row canvas { width: 54px; height: 96px; border-radius: 12px; border: 2.5px solid transparent; transition: transform .2s, border-color .2s; }
.filter-row button.on canvas { border-color: #f5ac17; transform: scale(1.06); }
.text-entry { position: absolute; inset: 0; z-index: 10; background: rgba(0,0,0,.6); display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 18px; padding: 20px; animation: fade .15s; }
.te-colors { position: absolute; top: calc(var(--safe-t) + 14px); left: 12px; right: 12px; display: flex; gap: 10px; justify-content: center; align-items: center; }
.te-colors button { width: 28px; height: 28px; border-radius: 50%; border: 2.5px solid #fff; }
.te-style { background: rgba(255,255,255,.2) !important; color: #fff; font-weight: 800; width: 34px !important; height: 34px !important; }
.te-input { min-width: 60px; max-width: 90%; font-size: 30px; font-weight: 800; text-align: center; outline: none; padding: .1em .35em; border-radius: .3em; white-space: pre-wrap; text-shadow: 0 2px 8px rgba(0,0,0,.4); caret-color: #f5ac17; }
.te-done { position: absolute; top: calc(var(--safe-t) + 60px); right: 14px; }
.story-editor:has(.text-entry) .cam-top, .story-editor:has(.text-entry) .filter-row, .story-editor:has(.text-entry) .ed-bottom { opacity: 0; pointer-events: none; }
