/* Application shell. The red wordmark and the original Lightning scene share one renderer. */
html { scroll-padding-top: 24px; }
body {
  position: relative;
  isolation: isolate;
  padding: max(20px, env(safe-area-inset-top)) max(32px, env(safe-area-inset-right)) max(28px, env(safe-area-inset-bottom)) max(32px, env(safe-area-inset-left));
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  font-size: 16px; line-height: 1.6;
}
h1, h2, .brand { font-family: 'Bricolage Grotesque', system-ui, sans-serif; }
h1 { font-weight: 700; line-height: 1.12; letter-spacing: -.035em; }
button, a, input, textarea, summary { -webkit-tap-highlight-color: transparent; }
/* Footer bleibt unten, auch wenn die Seite kurz ist */
body { display: flex; flex-direction: column; }
body > .site-top, body > main, body > .site-footer { width: 100%; }
main:not(.fill) { margin-bottom: 32px; }
::selection { background: #8B1118; color: #fff; }
#ambient-background {
  position: relative; isolation: isolate; overflow: hidden;
  width: min(640px, 100%); height: 140px; margin: 12px auto 0;
}
#ambient-background, #ambient-background * { pointer-events: none !important; }
.shader-frame { position: absolute; left: -100px; right: -100px; height: 480px; top: 50%; transform: translateY(-50%); }
#ambient-background::after {
  content: ''; position: absolute; inset: 0; pointer-events: none;
  background: radial-gradient(ellipse at center, transparent 25%, var(--paper) 75%);
}
.site-top, body:has(main.wide) .site-top {
  position: relative;
  max-width: 1160px; min-height: 66px; margin: 0 auto;
  display: flex; align-items: center; justify-content: space-between; gap: 24px;
  padding-bottom: 20px; border-bottom: 1px solid rgba(255, 255, 255, .12);
}
.brand { gap: 4px; font-size: 26px; line-height: 1; min-height: 44px; flex-shrink: 0; }
.brand::before { flex-shrink: 0; width: 10px; height: 10px; background: #FF2D3A; box-shadow: 0 0 14px #FF2D3A66; }
.brand-mark { position: relative; display: block; width: 160px; height: 40px; overflow: hidden; }
/* Text vor dem Laden der Animation: gleiche Grösse und Lage wie das animierte Wortzeichen.
   Keine Container-Query auf .brand-mark: die isoliert das Canvas, dann greift mix-blend-mode nicht mehr (Kasten ums Logo). */
.brand-label { position: absolute; inset: 0; display: flex; align-items: center; padding: 5.6px 0 0 4px; font-size: 38.4px; }
.brand-mark canvas { display: block; width: 100%; height: 100%; opacity: 0; mix-blend-mode: screen; }
.brand-mark[data-ready="true"] canvas { opacity: 1; }
/* Rote Animation: Farbfilter #reaction-red aus index.html, für den Blitz und die Wortzeichen (Bildkopien, sie erben den Filter des iframes nicht).
   !important, weil die Komponente dem iframe selbst einen (neutralen) Filter setzt. */
.shader-frame iframe, .brand-mark canvas { filter: url(#reaction-red) !important; }
.brand-mark[data-ready="true"] .brand-label { visibility: hidden; }
.site-top .brand { font-size: 32px; font-weight: 800; color: var(--ink); } /* oben als Text mit rotem Punkt */
.brand-small { font-size: 19px; gap: 3px; }
.brand-small::before { width: 7px; height: 7px; }
.brand-small .brand-mark { width: 116px; height: 30px; }
.brand-small .brand-label { padding: 4.2px 0 0 2.9px; font-size: 27.8px; }
.site-nav {
  display: none; position: absolute; top: calc(100% + 8px); right: 0; z-index: 30;
  width: min(320px, 100%); max-height: calc(100dvh - 160px); overflow-y: auto;
  flex-direction: column; align-items: stretch; gap: 3px; padding: 8px;
  border: 1px solid #383838; border-radius: 16px;
  background: #141414; box-shadow: 0 20px 48px #000D;
}
.site-nav.is-open { display: flex; }
.desktop-nav { display: flex; align-items: center; gap: 4px; padding: 5px; border: 1px solid var(--line); border-radius: 14px; background: #0E0E0E; }
.desktop-nav a { display: flex; align-items: center; justify-content: center; gap: 9px; min-height: 46px; padding: 10px 14px; border-radius: 9px; color: var(--muted); font-size: 14px; font-weight: 600; text-decoration: none; white-space: nowrap; }
.desktop-nav a:hover { color: var(--ink); background: #1C1C1C; }
.desktop-nav a[aria-current] { background: var(--rec-soft); color: #FF8A91; }
.site-nav a { display: flex; align-items: center; gap: 12px; min-height: 44px; text-decoration: none; padding: 9px 16px; border-radius: 9px; color: var(--muted); font-size: 14px; font-weight: 600; }
.site-nav .ui-icon { display: none; }
.site-nav a:hover { color: var(--ink); background: #1C1C1C; }
.site-nav a[aria-current] { background: var(--rec-soft); color: #FF8A91; }
.site-nav .mobile-menu-item { display: none; }
.site-nav #app-install-help, .site-nav .menu-legal-start, .site-nav a[href="/datenschutz"], .site-nav #menu-feedback { display: flex; }
.site-nav .ui-icon { display: block; }
.site-nav button { display: flex; align-items: center; gap: 12px; width: 100%; min-height: 44px; padding: 9px 16px; border: 0; border-radius: 9px; background: transparent; color: var(--muted); font-size: 14px; font-weight: 600; text-align: left; }
.site-nav button:hover { color: var(--ink); background: #1C1C1C; }
.header-actions { display: flex; gap: 8px; }
button.icon-button {
  width: 44px; height: 44px; padding: 11px; display: grid; place-items: center;
  border: 1px solid var(--line); background: rgba(14, 14, 14, .9); color: var(--muted); border-radius: 12px;
}
button.icon-button:hover { border-color: var(--rec); color: var(--ink); background: var(--rec-soft); }
.icon-button svg, .feedback-btn svg, .form-heading svg {
  width: 20px; height: 20px; fill: none; stroke: currentColor; stroke-width: 1.7; stroke-linecap: round; stroke-linejoin: round;
}
.ui-icon { width: 20px; height: 20px; flex: 0 0 20px; fill: none; stroke: currentColor; stroke-width: 1.7; stroke-linecap: round; stroke-linejoin: round; }
.menu-line { transform-origin: 12px 12px; transition: transform .18s ease; }
[aria-expanded="true"] .menu-line:first-child { transform: rotate(45deg) translateY(4px); }
[aria-expanded="true"] .menu-line:last-child { transform: rotate(-45deg) translateY(-4px); }
button.menu-toggle[aria-expanded="true"] { background: #202020; color: var(--ink); }
button.menu-toggle { display: grid; }
main { margin: 40px auto 0; gap: 18px; }
main:not(.home):not(.owner-page):not(.record-page):not(.legal-page):not(.fill):not(.wide):not(.collection-page) {
  max-width: 640px; padding: 32px; margin-top: 40px;
  border: 1px solid var(--line); border-radius: 20px; background: #0A0A0A;
}
main.home, main.owner-page, main.record-page:not(.fill), main.legal-page { max-width: 1160px; margin-top: 0; gap: 0; padding-bottom: 0; }
.legal-list { margin: 0; padding-left: 20px; display: flex; flex-direction: column; gap: 10px; color: var(--muted); }
.legal-list li::marker { color: var(--rec); }
main.wide { margin-top: 32px; }
main.fill { margin-top: 0; }
main.fill .create-layout { display: flex; flex-direction: column; height: 100%; padding: 0; gap: 0; }
main.fill .create-content { max-width: none; width: 100%; height: 100%; }
main.fill .scene-slot { display: none; }
/* Die Leiste bleibt unter dem Video; nur die fliegenden Emojis werden exportiert. */
.emoji-controls { flex: 0 0 auto; display: grid; gap: 6px; justify-items: center; }
.emoji-controls p { font-size: 12px; text-align: center; }
.emoji-buttons { display: flex; justify-content: center; gap: 12px; }
.emoji-buttons button {
  display: grid; place-items: center; width: 56px; height: 52px; padding: 8px;
  border: 1px solid #363636; border-radius: 16px; background: #181818;
  touch-action: manipulation; transition: background .15s, border-color .15s, transform .12s;
}
.emoji-buttons button:hover:enabled { background: #292929; border-color: #666; }
.emoji-buttons button:active:enabled { transform: scale(.9); background: var(--rec-soft); border-color: var(--rec); }
.emoji-buttons img { display: block; pointer-events: none; }
#emoji-layer { position: absolute; inset: 0; overflow: hidden; pointer-events: none; border-radius: 14px; }
#emoji-layer img { position: absolute; top: 0; left: 0; width: var(--emoji-size); height: var(--emoji-size); will-change: transform, opacity; }
main:focus { outline: none; }
.create-layout { display: grid; grid-template-columns: 1fr 1fr; grid-template-areas: 'content scene'; gap: 48px; padding: 48px 0 56px; }
.create-content { grid-area: content; }
.scene-slot { grid-area: scene; position: relative; isolation: isolate; overflow: hidden; min-height: 420px; }
.scene-slot > #ambient-background { position: absolute; inset: 0; height: 100%; width: 100%; margin: 0; }
.scene-slot .shader-frame { height: calc(100% + 120px); left: -150px; right: -150px; }
.create-content { min-width: 0; max-width: 520px; }
.hero h1 { font-size: clamp(40px, 4.4vw, 62px); line-height: 1.06; font-weight: 700; letter-spacing: -.045em; margin: 0; text-wrap: initial; }
.hero h1 span { color: var(--rec-dark); }
.form.card { margin-top: 28px; padding: 24px; gap: 10px; border-color: #323232; }
.card {
  background: var(--surface); border-color: var(--line); border-radius: 16px;
  box-shadow: none;
}
.form-heading { display: flex; align-items: center; gap: 12px; margin-bottom: 14px; }
.form-heading h2 { color: var(--ink); font-size: 21px; line-height: 1.3; font-weight: 600; margin: 0; letter-spacing: -.025em; }
.form-heading p { font-size: 13px; margin-top: 2px; }
.form-symbol { display: grid; place-items: center; width: 44px; height: 44px; flex: 0 0 44px; border: 1px solid #4E2024; border-radius: 12px; color: var(--rec-dark); background: #230D10; }
.form label { font-size: 13px; color: #D4D4D4; font-weight: 600; }
input, textarea { background: #080808; border-color: #3A3A3A; }
input::placeholder, textarea::placeholder { color: #8C8C8C; opacity: 1; }
input, textarea, button, .btn { border-radius: 12px; min-width: 0; }
input, textarea, select { font-size: 16px; }
button, .btn { min-height: 48px; touch-action: manipulation; font-size: 15px; font-weight: 600; line-height: 1.4; }
button:active:not(:disabled), .btn:active { filter: brightness(.88); }
input[aria-invalid="true"] { border-color: var(--rec-dark); }
video { max-width: 100%; }
button, .btn { transition: background .15s, border-color .15s, color .15s; }
button.secondary, .btn.secondary { background: #171717; }
button.secondary:hover, .btn.secondary:hover { background: #222222; border-color: #555555; }
#url { padding: 16px 14px; font-size: 16px; line-height: 1.4; min-height: 56px; }
#url-hint { font-size: 12px; margin-top: 0; }
/* Eingabefeld und Button nebeneinander, wie beim „Teilen“-Link */
.url-row { display: flex; gap: 10px; align-items: stretch; }
.url-row #url { flex: 1 1 auto; min-width: 0; }
#go { width: auto; flex: none; display: flex; align-items: center; justify-content: center; gap: 9px; min-height: 56px; padding: 10px 16px; font-size: 15px; white-space: nowrap; }
#go .ui-icon { width: 20px; height: 20px; flex-basis: 20px; }
/* beide Texte liegen übereinander, damit sich die Breite beim Laden nicht ändert */
.go-label { display: grid; }
.go-label > span { grid-area: 1 / 1; text-align: center; }
.go-label > span + span, #go[aria-busy="true"] .go-label > span:first-child { visibility: hidden; }
#go[aria-busy="true"] .go-label > span + span { visibility: visible; }
#go[aria-busy="true"] { opacity: .85; }
#go[aria-busy="true"] .ui-icon { animation: go-spin .8s linear infinite; }
@keyframes go-spin { to { transform: rotate(360deg); } }
.privacy-note { display: flex; align-items: flex-start; gap: 10px; font-size: 12px; line-height: 1.65; color: var(--muted); }
.privacy-note .ui-icon { width: 16px; height: 16px; flex-basis: 16px; margin-top: 2px; }
.create-content > .privacy-note { margin: 16px 4px 0; max-width: 46ch; }
#err { margin-top: 14px; color: #FFE1E3; border-color: #A32630; background: #2A0E11; }
.scene-caption { position: absolute; bottom: 42px; left: 0; right: 0; text-align: center; color: #E6E6E6; font-size: 20px; font-weight: 600; letter-spacing: -.025em; }
.scene-caption span { display: block; margin-top: 6px; color: var(--muted); font-size: 13px; font-weight: 400; letter-spacing: 0; }
.how-section { padding: 32px 0 40px; border-top: 1px solid var(--line); }
.how-section h2, .section-heading h2 { font-size: 23px; font-weight: 600; letter-spacing: -.03em; margin: 0; }
.steps { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 32px; margin-top: 24px; }
.steps li { position: relative; grid-template-columns: 32px 1fr; gap: 5px 14px; }
.steps li::before { width: 32px; height: 32px; border-radius: 10px; font-size: 12px; border: 1px solid #383838; background: #171717; color: #D4D4D4; font-weight: 600; }
.steps strong { font-size: 15px; font-weight: 600; }
.steps span { font-size: 14px; line-height: 1.65; max-width: 30ch; }
.collection { border-top: 1px solid var(--line); padding-top: 32px; }
.section-heading { display: flex; align-items: baseline; justify-content: space-between; gap: 12px; margin-bottom: 18px; }
.section-heading > span { color: var(--muted); }
.mine { padding: 22px 24px; }
.mine > strong { font-size: 13px; font-weight: 500; color: var(--muted); }
.mine-info { gap: 3px; }
.mine-summary { display: flex; align-items: center; gap: 14px; flex: 1; min-width: 0; }
.mine-info .small { color: var(--muted); font-size: 12px; }
.mine p { font-size: 15px; }
.empty-action { font-size: 14px; text-decoration: none; width: fit-content; padding: 6px 0; }
.empty-action:hover { text-decoration: underline; }
.empty-action span { padding-left: 6px; }
.mine-item .btn { display: flex; align-items: center; justify-content: space-between; gap: 12px; min-height: 44px; }
.mine-item .btn .ui-icon { width: 16px; height: 16px; flex-basis: 16px; }
.page-heading { display: grid; gap: 12px; margin-bottom: 6px; }
.page-heading h1 { margin: 0; font-size: 36px; }
.page-heading > p { font-size: 15px; line-height: 1.65; }
.share-panel { display: flex; flex-direction: column; gap: 14px; padding: 20px; }
.share-panel h2 { margin: 0; font-size: 20px; font-weight: 600; letter-spacing: -.025em; }
.share { background: #080808; border: 1px solid #353535; border-radius: 10px; padding: 12px; gap: 10px; }
.share > .ui-icon { color: var(--muted); width: 16px; height: 16px; flex-basis: 16px; }
.share span { color: #D6D6D6; min-width: 0; font-size: 13px; user-select: all; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.share-row { display: flex; gap: 10px; align-items: stretch; }
.share-row .share { flex: 1 1 auto; min-width: 0; }
.share-row button { width: auto; flex: none; display: flex; align-items: center; justify-content: center; gap: 9px; padding: 10px 16px; min-height: 48px; white-space: nowrap; }
.share-row #qr-btn { padding-inline: 13px; }
.share-label { display: grid; }
.share-label > span { grid-area: 1 / 1; text-align: center; }
.share-label > span + span, #share.copied .share-label > span:first-child { visibility: hidden; }
#share.copied .share-label > span + span { visibility: visible; }
#share.copied .ui-icon { animation: share-pop .3s ease-out; }
@keyframes share-pop { from { transform: scale(.4); } 60% { transform: scale(1.2); } to { transform: scale(1); } }
.share-help { font-size: 12px; line-height: 1.6; }
#qr { max-width: 300px; align-self: center; width: 100%; }
#qr-btn[aria-expanded="true"] { border-color: var(--rec-dark); color: var(--rec-dark); }
summary { cursor: pointer; }
details > summary { padding: 3px 0; }
details[open] > summary { padding-bottom: 8px; }
.greet-edit > summary { list-style: none; display: flex; align-items: center; gap: 12px; padding: 0; min-height: 44px; font-size: 14px; font-weight: 600; }
.greet-edit > summary::-webkit-details-marker { display: none; }
.greet-edit > summary > .ui-icon { color: var(--muted); }
.greet-edit > summary small { display: block; margin-top: 2px; color: var(--muted); font-size: 12px; font-weight: 400; }
.greet-edit > summary::after { content: ''; width: 8px; height: 8px; flex: 0 0 8px; margin: 0 4px 4px auto; border-right: 1.5px solid var(--muted); border-bottom: 1.5px solid var(--muted); transform: rotate(45deg); }
.greet-edit[open] > summary::after { transform: rotate(225deg); margin-bottom: -4px; }
.greet-edit[open] > summary { padding-bottom: 0; }
.greet-edit .content { border-top: 1px solid var(--line); padding-top: 18px; margin-top: 18px; }
.greet-edit label { font-size: 14px; }
.greet-edit #greet-msg:empty, #state:empty { display: none; }
.owner-page #status { margin-top: 8px; background: transparent; border-style: dashed; color: var(--muted); font-size: 14px; line-height: 1.6; padding: 18px; }
#counts { font-size: 13px; font-variant-numeric: tabular-nums; }
.owner-page #del-link, .owner-page > #del-link, .own-page > #del-own { border-color: transparent; font-size: 13px; margin-top: 4px; }
.reaction { border-top: 1px solid var(--line); padding-top: 18px; }
.reaction > p:first-child { display: flex; align-items: baseline; justify-content: space-between; flex-wrap: wrap; gap: 4px 12px; }
.reaction > p .small { font-size: 12px; }
.reaction .row { display: grid; grid-template-columns: minmax(0, 1fr) auto; }
.reaction .row > * { padding: 12px 16px; }
#intro { display: flex; flex-direction: column; gap: 24px; }
.greeting { gap: 12px; }
.greeting-title { display: flex; align-items: center; gap: 10px; font-size: 14px; font-weight: 600; }
.greeting-title .ui-icon { color: var(--muted); width: 18px; height: 18px; flex-basis: 18px; }
.greet-text { font-size: 16px; padding: 14px; border-radius: 12px 12px 12px 3px; }
.greeting > .small { font-size: 12px; }
.facts { list-style: none; padding: 0; gap: 0; }
.facts li { display: grid; grid-template-columns: 20px minmax(0, 1fr); gap: 14px; padding: 18px 0; border-bottom: 1px solid var(--line); }
.facts li:last-child { border-bottom: 0; padding-bottom: 0; }
.facts .ui-icon { margin-top: 3px; color: #BBBBBB; }
.facts strong { display: block; margin-bottom: 5px; color: var(--ink); font-size: 14px; font-weight: 600; }
.facts p { font-size: 14px; line-height: 1.7; }
.facts .video-fact { border: 1px solid var(--line); border-radius: 12px; padding: 14px; margin-bottom: 4px; background: var(--surface); align-items: center; }
.video-fact .ui-icon { color: var(--rec-dark); margin: 0; }
.video-fact p { color: #D4D4D4; }
.consent-note { font-size: 12px; line-height: 1.7; }
.consent-note a { color: #D4D4D4; text-underline-offset: 3px; }
#allow { min-height: 54px; }
.timer .rec::before { background: #FF3B3B; }
body:has(main.fill) { padding-top: max(16px, env(safe-area-inset-top)); }
body:has(main.fill) main { padding-bottom: 0; }
.site-footer { max-width: 1160px; margin: auto auto 0; display: flex; justify-content: space-between; align-items: center; gap: 24px; padding: 20px 0 0; border-top: 1px solid var(--line); }
body:has(main.fill) .site-footer, body:has(main.wide) .site-footer { display: none; }
main:not(.fill):not(.wide) { padding-bottom: 30px; }
.feedback-btn { position: static; display: flex; align-items: center; gap: 8px; border-radius: 10px; background: transparent !important; border-color: var(--line) !important; box-shadow: none; min-height: 44px; font-size: 13px; }
.feedback-btn svg { width: 16px; height: 16px; }
dialog { padding: 26px; border: 1px solid #444444; background: #0E0E0E; box-shadow: 0 30px 100px #000A; max-height: calc(100dvh - 32px); overflow-y: auto; }
dialog::backdrop { background: rgba(0, 0, 0, .8); backdrop-filter: blur(6px); }
.skip-link { position: fixed; left: 20px; top: -100px; z-index: 20; padding: 12px 18px; border-radius: 8px; background: var(--rec); color: var(--button-ink); clip-path: inset(50%); }
.skip-link:focus { top: 12px; clip-path: none; }
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; border: 0; }
@media (min-width: 1440px) { .create-layout { padding-top: 56px; padding-bottom: 64px; } }
@media (max-width: 960px) {
  body { padding-inline: 24px; }
  .create-layout { gap: 28px; grid-template-columns: 1.2fr 1fr; }
  .site-top { gap: 18px; }
  /* schmaler Desktop (761–960 px): Navigation ohne Symbole, sonst ragt der Menü-Knopf mit Zählern über den Rand */
  .desktop-nav a { padding-inline: 10px; }
  .desktop-nav .ui-icon { display: none; }
  .hero h1 { font-size: 44px; }
  .steps { gap: 20px; }
}
@media (max-width: 760px) {
  body { padding: max(14px, env(safe-area-inset-top)) max(20px, env(safe-area-inset-right)) max(20px, env(safe-area-inset-bottom)) max(20px, env(safe-area-inset-left)); }
  .site-top { position: relative; min-height: 58px; padding-bottom: 14px; gap: 12px; }
  .site-top .brand { font-size: 28px; }
  .header-actions { display: flex; }
  button.menu-toggle { display: grid; }
  .desktop-nav { display: none; }
  .site-nav { left: 0; right: 0; width: auto; }
  .site-nav.is-open { display: flex; flex-direction: column; align-items: stretch; }
  .site-nav a { padding: 14px 12px; min-height: 50px; font-size: 14px; }
  .site-nav .ui-icon { display: block; }
  #ambient-background { height: 108px; margin-top: 0; }
  .shader-frame { left: -70px; right: -70px; height: 420px; }
  main.home, main.owner-page, main.record-page, main.legal-page { max-width: 520px; }
  .create-layout { grid-template-columns: minmax(0, 1fr); grid-template-areas: 'scene' 'content'; gap: 0; padding: 32px 0 32px; }
  .scene-slot { min-height: 0; height: 0; overflow: visible; }
  .scene-slot .shader-frame { height: 460px; left: -70px; right: -70px; }
  .create-content { max-width: 520px; width: 100%; margin: auto; }
  .hero h1 { font-size: clamp(34px, 10.2vw, 48px); max-width: 430px; letter-spacing: -.04em; }
  .form.card { margin-top: 24px; padding: 20px; border-radius: 18px; }
  .form-heading h2 { font-size: 20px; }
  .scene-caption { display: none; }
  .how-section { padding: 28px 0 32px; }
  .how-section h2, .section-heading h2 { font-size: 23px; }
  .steps { grid-template-columns: 1fr; gap: 24px; margin-top: 24px; }
  .steps li { gap: 4px 14px; }
  .steps li:not(:last-child)::after { content: ''; position: absolute; top: 42px; bottom: -14px; left: 15px; width: 1px; background: var(--line); }
  .steps span { max-width: 42ch; }
  .section-heading { align-items: flex-start; flex-direction: column; gap: 5px; }
  .section-heading > span { font-size: 12px; }
  .collection { padding-top: 28px; }
  .mine { padding: 18px; gap: 14px; }
  .mine-item { flex-direction: column; align-items: stretch; gap: 12px; padding-top: 16px; }
  .mine-item > span, .mine-info { flex-basis: auto; }
  .mine-item .btn { width: 100%; margin: 0; padding: 12px; font-size: 13px; }
  main:not(.home):not(.owner-page):not(.record-page):not(.legal-page):not(.fill):not(.wide):not(.collection-page) { max-width: 520px; margin-top: 30px; padding: 0 0 28px; border: 0; border-radius: 0; background: transparent; gap: 20px; }
  main:not(.home) h1 { font-size: 32px; }
  .page-heading { gap: 12px; }
  .page-heading h1 { max-width: 17ch; }
  .share-panel { padding: 18px; }
  .greet-edit { padding: 16px; }
  .greet-edit > summary { gap: 10px; }
  .reaction video { max-height: 72dvh; }
  .comment { font-size: 14px; }
  dialog { padding: 22px; }
  #fb { margin: auto auto max(16px, env(safe-area-inset-bottom)); border-radius: 20px; }
  #fb p { font-size: 14px; }
  .site-footer { max-width: 520px; display: grid; grid-template-columns: 1fr auto; gap: 8px 16px; padding-top: 20px; }
  .site-footer .brand { justify-self: start; }
  .site-footer .feedback-btn { grid-column: 2; grid-row: 1; font-size: 12px; padding: 10px 12px; }
  .row { flex-wrap: wrap; }
  .row > * { flex: 1 1 140px; white-space: normal; }
  .ranges > * { flex-basis: 80px; }
  .grid, .grid.landscape { grid-template-columns: minmax(0, 1fr); }
  .tiles { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .replay-item { flex-wrap: wrap; }
  .replay-item button { margin-left: auto; }
  .bar-row { grid-template-columns: 60px minmax(0, 1fr) 50px; font-size: 12px; }
  main:not(.fill) { margin-bottom: 12px; }
  body:has(main.fill) { padding-inline: max(12px, env(safe-area-inset-left)) max(12px, env(safe-area-inset-right)); padding-bottom: max(12px, env(safe-area-inset-bottom)); }
}
@media (max-width: 480px) {
  /* kein Platz für „Link kopiert“ reservieren; der Button wächst nur kurz beim Kopieren */
  .share-label > span + span, #share.copied .share-label > span:first-child { display: none; }
  #share.copied .share-label > span + span { display: inline; }
}
@media (max-width: 360px) {
  body { padding-inline: max(16px, env(safe-area-inset-left)) max(16px, env(safe-area-inset-right)); }
  .create-layout { padding-top: 28px; }
  .form.card { padding: 16px; }
  .hero h1 { font-size: 34px; }
  .share-panel { padding: 16px; }
  .share-row { gap: 8px; }
  .share-row button { padding-inline: 10px; font-size: 13px; gap: 7px; }
  .share-row button .ui-icon { width: 18px; height: 18px; flex-basis: 18px; }
  .share { padding: 10px; gap: 8px; }
  .greet-edit > summary { font-size: 13px; }
  #allow { font-size: 14px; padding-inline: 10px; }
}
@media (max-width: 760px) and (max-height: 700px) {
  /* Use min-height so it centers natively, but allows scroll if keyboard opens */
  body { min-height: 100dvh; padding-top: max(8px, env(safe-area-inset-top)); padding-bottom: max(12px, env(safe-area-inset-bottom)); }
  main { flex: 1; display: flex; flex-direction: column; }
  .create-layout { flex: 0 0 auto; min-height: calc(100dvh - 60px); display: flex; flex-direction: column; justify-content: center; padding: 0; }
  .create-content { display: flex; flex-direction: column; justify-content: center; flex: 1; }
  .site-footer { display: none !important; }
  main:not(.fill):not(.wide) { padding-bottom: 0; margin-bottom: 0; }
  
  /* Startseite specific */
  .hero h1 { font-size: 28px; }
  .form.card { margin-top: 10px; padding: 14px; }
  .form-heading h2 { font-size: 18px; }
  input, textarea, button, .btn { padding: 10px 14px; }
  .site-top { min-height: 40px; padding-bottom: 0; margin-bottom: 0; }
  
  /* Aufnehmen Ansicht specific */
  #intro { gap: 8px; }
  .page-heading { gap: 4px; margin-bottom: 0; }
  .page-heading h1 { font-size: 24px; }
  .page-heading p { font-size: 13px; }
  .greeting { gap: 6px; }
  .greet-text { font-size: 13px; padding: 10px; }
  
  /* Convert facts list to inline text to save massive amounts of vertical space */
  .facts li { grid-template-columns: 18px minmax(0, 1fr); gap: 10px; padding: 8px 0; border-bottom: 1px solid var(--line); align-items: start; }
  .facts li:last-child { border-bottom: none; }
  .facts li div { display: inline; }
  .facts strong { display: inline; font-size: 13px; margin: 0 4px 0 0; }
  .facts p { display: inline; font-size: 13px; margin: 0; color: var(--muted); }
  .facts .video-fact { padding: 8px 12px; margin-bottom: 4px; align-items: center; }
  .consent-note { font-size: 11px; margin-top: -2px; }
}

/* Handy + alle Seiten ausser der Startseite: Blitz-Streifen unsichtbar, läuft aber weiter (liefert die Frames fürs Logo in Header/Footer) */
@media (max-width: 760px) {
  #ambient-background, .scene-slot > #ambient-background { position: fixed; top: 0; left: 0; width: 100%; height: 124px; margin: 0; opacity: 0; z-index: -1; }
}
body:not(:has(main.home)):not(:has(main.owner-page)):not(:has(main.record-page:not(.fill))):not(:has(main.legal-page)) #ambient-background { position: fixed; top: 0; left: 0; width: 100%; height: 140px; margin: 0; opacity: 0; z-index: -1; }

/* Persistent app chrome; recording keeps its dedicated, uncluttered viewport. */
.app-screen { display: flex; flex-direction: column; gap: 18px; min-width: 0; }
main.home > .app-screen, main.owner-page > .app-screen, main.record-page > .app-screen, main.legal-page > .app-screen { gap: 0; }
main.fill > .app-screen { flex: 1; height: 100%; min-height: 0; gap: 16px; }
.app-title, .app-back, .bottom-nav { display: none; }
.collection-page { width: 100%; max-width: 1160px !important; }
.collection-heading { display: flex; align-items: center; justify-content: space-between; gap: 16px; }
.collection-heading h1 { margin-top: 4px; }
.collection-add { display: grid; place-items: center; width: 48px; height: 48px; border-radius: 14px; background: var(--rec); color: white; flex-shrink: 0; }
.desktop-add-label { display: none; }
.collection-list { display: grid; grid-template-columns: minmax(0, 1fr); min-width: 0; gap: 12px; }
.collection-row { display: flex; align-items: center; min-width: 0; max-width: 100%; min-height: 88px; gap: 14px; padding: 18px 16px; border: 1px solid var(--line); border-radius: 16px; background: #101010; text-decoration: none; color: var(--ink); }
.collection-preview, .mine-item .collection-preview { position: relative; display: grid; place-items: center; width: 72px; height: 96px; flex: 0 0 72px; overflow: hidden; border: 1px solid var(--line); border-radius: 10px; background: #231014; color: #FF737B; }
.collection-preview img { position: absolute; inset: 0; display: block; width: 100%; height: 100%; object-fit: cover; }
.collection-info { display: flex; flex-direction: column; min-width: 0; flex: 1; gap: 5px; }
.collection-info strong { display: block; max-width: 100%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: 15px; }
.collection-info span { color: var(--muted); font-size: 13px; }
.collection-row > .ui-icon { color: var(--muted); width: 18px; }
.collection-row:active { background: #1D1D1D; }
.empty-state { text-align: center; display: grid; justify-items: center; gap: 14px; padding: 48px 20px; }
.empty-state h2 { margin: 4px 0 0; }
.empty-state p { max-width: 30ch; }
.empty-state .btn { max-width: 280px; margin-top: 12px; }
.empty-icon { width: 68px; height: 68px; border: 1px solid #382023; border-radius: 22px; display: grid; place-items: center; color: #FF737B; background: #180C0E; }
.empty-icon .ui-icon { width: 28px; height: 28px; }
.screen-loading { padding: 60px 0; display: flex; align-items: center; justify-content: center; gap: 12px; color: var(--muted); }
.loading-dot { width: 10px; height: 10px; background: var(--rec); border-radius: 50%; }
.skeleton-row { height: 134px; border-radius: 16px; border: 1px solid var(--line); background: #121212; }
.connection-note { position: sticky; top: max(10px, env(safe-area-inset-top)); z-index: 25; margin: 12px auto; padding: 10px 14px; max-width: 540px; background: #2A1710; color: #FFD7B7; border: 1px solid #684129; border-radius: 12px; font-size: 13px; }
.update-note { position: fixed; z-index: 25; left: 50%; bottom: 24px; transform: translateX(-50%); display: flex; align-items: center; gap: 16px; padding: 12px 16px; border-radius: 14px; background: #202020; box-shadow: 0 4px 30px #0008; font-size: 13px; width: max-content; max-width: calc(100% - 32px); }
.update-note button { width: auto; min-height: 44px; padding: 8px 12px; font-size: 13px; }
.app-sheet { width: min(480px, calc(100% - 32px)); border-radius: 24px; }
.sheet-heading { display: flex; align-items: center; gap: 16px; justify-content: space-between; }
.sheet-heading h2 { margin: 0; }
.sheet-heading .icon-button { flex-shrink: 0; }
.app-sheet section { display: grid; gap: 12px; margin: 24px 0; }
.app-sheet p { font-size: 14px; }
.sheet-actions { display: grid; gap: 10px; margin-top: 24px; }
.sheet-links { display: flex; flex-wrap: wrap; gap: 16px; margin-top: 24px; font-size: 13px; }
.reaction { scroll-margin-top: 84px; }
.new-count { display: inline-block; margin-left: 6px; padding: 2px 8px; border-radius: 7px; background: #321014; color: #FF939A; font-size: 12px; font-weight: 650; }
@media (min-width: 761px) {
  .collection-heading { padding-bottom: 24px; border-bottom: 1px solid var(--line); }
  .collection-heading h1 { font-size: 36px; }
  .collection-add { display: flex; align-items: center; justify-content: center; gap: 10px; width: auto; padding: 0 18px; font-size: 14px; font-weight: 600; text-decoration: none; }
  .desktop-add-label { display: inline; }
  .collection-row { padding: 20px; gap: 18px; transition: border-color .15s, background .15s; }
  .collection-row:hover { border-color: #595959; background: #171717; }
  .collection-preview { width: 112px; height: 84px; flex-basis: 112px; }
  .collection-info strong { font-size: 16px; }
  .collection-info span { font-size: 14px; }
  .collection-list:has(.empty-state) { grid-template-columns: minmax(0, 1fr); }
  .collection-list .empty-state { padding: 70px 20px; }
}
@media (min-width: 1000px) { .collection-list { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 18px; } }
@media (max-width: 760px) {
  html { scroll-padding-bottom: calc(90px + env(safe-area-inset-bottom)); }
  body:not(:has(main.fill)):not([data-screen="admin"]) { padding-bottom: calc(90px + env(safe-area-inset-bottom)); overscroll-behavior-y: none; }
  .site-top { position: sticky; top: 0; z-index: 20; background: rgba(0,0,0,.94); backdrop-filter: blur(16px); padding-top: 8px; padding-bottom: 12px; min-height: 60px; }
  .site-nav { max-height: calc(100dvh - 160px); overflow-y: auto; }
  .site-nav .mobile-menu-item { display: flex; }
  .site-nav button { align-items: center; gap: 12px; width: 100%; min-height: 50px; padding: 14px 12px; border: 0; border-radius: 9px; background: transparent; color: var(--muted); font-size: 14px; font-weight: 600; text-align: left; }
  .site-nav button:hover { color: var(--ink); background: #1C1C1C; }
  .site-nav .menu-legal-start { border-top: 1px solid var(--line); border-radius: 0; margin-top: 4px; padding-top: 18px; }
  .header-actions { margin-left: auto; gap: 6px; }
  .app-back { display: grid; flex-shrink: 0; }
  .bottom-nav { position: fixed; z-index: 20; left: 0; right: 0; bottom: 0; display: grid; grid-template-columns: repeat(3, 1fr); gap: 4px; padding: 8px max(12px, env(safe-area-inset-right)) max(8px, env(safe-area-inset-bottom)) max(12px, env(safe-area-inset-left)); border-top: 1px solid #292929; background: rgba(12,12,12,.96); backdrop-filter: blur(20px); }
  .bottom-nav a { display: flex; min-height: 52px; align-items: center; justify-content: center; flex-direction: column; gap: 4px; color: #A8A8A8; text-decoration: none; font-size: 11px; font-weight: 550; border-radius: 12px; -webkit-tap-highlight-color: transparent; }
  .bottom-nav a .ui-icon { width: 23px; height: 23px; }
  .bottom-nav a[aria-current] { color: #FF717A; background: #231013; }
  .bottom-nav a:active { background: #252525; }
  body:has(main.fill) .bottom-nav, body[data-screen="admin"] .bottom-nav { display: none; }
  body:has(main.fill) .site-top { display: none; }
  .keyboard-open .bottom-nav { visibility: hidden; pointer-events: none; }
  .collection-page { margin-top: 24px !important; }
  .collection-heading h1 { font-size: 28px !important; }
  .update-note { bottom: calc(88px + env(safe-area-inset-bottom)); }
  .app-sheet { margin: auto auto max(12px, env(safe-area-inset-bottom)); max-height: calc(100dvh - 32px); padding: 22px; }
  .app-sheet:has(textarea:focus), #fb:has(textarea:focus) { margin-bottom: max(12px, env(safe-area-inset-bottom)); }
  .hero h1 { font-size: clamp(30px, 8.5vw, 38px); }
  .create-layout { padding-top: 28px; }
  main:not(.fill) { min-height: auto; }
  .site-footer { display: none; }
  .app-screen { min-height: 0; }
  input, textarea { font-size: 16px; }
  button, .btn, summary { min-height: 48px; }
  button:active:not(:disabled), .btn:active { filter: brightness(.85); }
  main.fill .app-screen { min-height: 0; }
}
@media (max-width: 760px) and (max-height: 700px) {
  main:not(.fill) .create-layout { min-height: auto; padding: 24px 0; }
  main:not(.fill) .create-content { flex: none; }
  .site-top { min-height: 60px; }
}

/* Lightning-Szene ist durch den Ozean-Hintergrund (reaction-ocean.js) ersetzt. */
#ambient-background, .scene-slot { display: none !important; }
/* Abdunklung über dem Ozean, damit Text lesbar bleibt (liegt über dem Canvas, unter dem Inhalt). */
body::before { content: ''; position: fixed; inset: 0; z-index: -1; pointer-events: none;
  background: linear-gradient(180deg, rgba(0,0,0,.55), rgba(0,0,0,.35) 45%, rgba(0,0,0,.6)); }
/* Vollbild aus dem Menü: nur Meer, Logo, Enten und Hai (die Canvases liegen direkt im body) */
body > #ocean-real { position: fixed; left: max(14px, env(safe-area-inset-left)); bottom: max(10px, env(safe-area-inset-bottom)); z-index: -1; pointer-events: none; font-size: 12px; line-height: 1.3; font-variant-numeric: tabular-nums; color: rgba(255, 255, 255, 0.82); text-shadow: 0 1px 3px rgba(0, 0, 0, 0.75); max-width: calc(100vw - 28px); }
@media (max-width: 760px) { body > #ocean-real { bottom: calc(74px + env(safe-area-inset-bottom)); } } /* über der unteren Navigation */
body > #ocean-real::before { content: "● reaction · "; } /* ohne sichtbaren Footer (Handy, Vollbild-Seiten) fehlt das Logo davor */
.site-footer #ocean-real { flex: 1 1 320px; min-width: 0; grid-column: 1 / -1; text-wrap: balance; font-size: 12px; line-height: 1.4; font-variant-numeric: tabular-nums; color: var(--muted); } /* im Footer direkt hinter dem Logo; grid-column: im schmalen Footer eine eigene Zeile */
html.ocean-only body > :not(canvas) { opacity: 0 !important; pointer-events: none !important; }
html.ocean-only body { cursor: pointer; }
/* «Menü aus»: dieselbe leere Oberfläche, ohne Browser-Vollbild; zurück über den kleinen Knopf unten rechts */
html.menu-off body > :not(canvas):not(#menu-back) { opacity: 0 !important; pointer-events: none !important; }
#menu-back { display: none; }
html.menu-off #menu-back { display: grid; place-items: center; position: fixed; right: max(14px, env(safe-area-inset-right)); bottom: max(14px, env(safe-area-inset-bottom)); z-index: 50;
  width: 40px; height: 40px; padding: 0; border: 1px solid rgba(255,255,255,.25); border-radius: 50%; background: rgba(20,20,24,.35); color: #fff;
  opacity: .35; cursor: pointer; transition: opacity .2s; -webkit-backdrop-filter: blur(8px); backdrop-filter: blur(8px); }
html.menu-off #menu-back:hover, html.menu-off #menu-back:focus-visible { opacity: 1; }
#menu-back .ui-icon { width: 20px; height: 20px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; }

/* Glas-Look (Apple-Material): Blur + Sättigung, helle Oberkante, tiefer Schatten. Größere Flächen = dicker. */
.card, .desktop-nav, .site-nav, dialog, .bottom-nav {
  background: rgba(20, 20, 24, .38);
  -webkit-backdrop-filter: blur(24px) saturate(180%); backdrop-filter: blur(24px) saturate(180%);
  border: 1px solid rgba(255, 255, 255, .14); border-top-color: rgba(255, 255, 255, .3);
  box-shadow: 0 8px 32px rgba(0, 0, 0, .35), inset 0 1px 0 rgba(255, 255, 255, .12);
}
.card { border-radius: 22px; }
.desktop-nav { background: rgba(20, 20, 24, .3); backdrop-filter: blur(16px) saturate(180%); -webkit-backdrop-filter: blur(16px) saturate(180%); }
.site-nav, dialog { background: rgba(20, 20, 24, .55); backdrop-filter: blur(32px) saturate(180%); -webkit-backdrop-filter: blur(32px) saturate(180%); box-shadow: 0 20px 60px rgba(0, 0, 0, .5), inset 0 1px 0 rgba(255, 255, 255, .15); }
.bottom-nav { border-width: 1px 0 0; }
.card input, .card textarea, .card button.secondary, .card .btn.secondary { background: rgba(255, 255, 255, .08); border-color: rgba(255, 255, 255, .16); }
.card .tile { background: rgba(255, 255, 255, .06); }
.site-nav a:hover, .site-nav button:hover, .desktop-nav a:hover { background: rgba(255, 255, 255, .1); }
.card, .desktop-nav a, button, .btn { transition: background .2s, transform .12s ease-out; }
button:active, .btn:active { transform: scale(.97); }
@media (prefers-reduced-transparency: reduce), (prefers-contrast: more) {
  .card, .desktop-nav, .site-nav, dialog, .bottom-nav { background: #121214; backdrop-filter: none; -webkit-backdrop-filter: none; border-color: #4a4a4a; }
}

/* Glas auch für alle übrigen Boxen */
main:not(.home):not(.owner-page):not(.record-page):not(.legal-page):not(.fill):not(.wide):not(.collection-page),
.collection-row, .facts .video-fact, button.icon-button, .greet-text, .skeleton-row, .legal-page .card {
  background: rgba(20, 20, 24, .38);
  -webkit-backdrop-filter: blur(24px) saturate(180%); backdrop-filter: blur(24px) saturate(180%);
  border: 1px solid rgba(255, 255, 255, .14); border-top-color: rgba(255, 255, 255, .3);
  box-shadow: 0 8px 32px rgba(0, 0, 0, .35), inset 0 1px 0 rgba(255, 255, 255, .12);
}
main:not(.home):not(.owner-page):not(.record-page):not(.legal-page):not(.fill):not(.wide):not(.collection-page) { border-radius: 24px; }
.collection-row, .facts .video-fact { border-radius: 18px; }
.collection-row:hover { background: rgba(255, 255, 255, .12); }
select, .tile, .admin-link { background: rgba(255, 255, 255, .08); border-color: rgba(255, 255, 255, .16); }
.greet-text, .badge, .site-nav a[aria-current], .desktop-nav a[aria-current] { background: rgba(229, 9, 20, .28); }

/* Lesbarkeit: hellere Zweitfarbe, weicher Textschatten, etwas dunklerer Verlauf */
:root { --muted: #DADADF; }
body { text-shadow: 0 1px 10px rgba(0, 0, 0, .55); }
input, textarea, button, select, video { text-shadow: none; }
body::before { background: linear-gradient(180deg, rgba(0,0,0,.6), rgba(0,0,0,.48) 45%, rgba(0,0,0,.68)); }

/* Mobile Kopfzeile: Glas statt schwarzem Balken */
@media (max-width: 760px) {
  .site-top { border-radius: 0 0 18px 18px; padding-inline: 12px; background: rgba(20, 20, 24, .3); -webkit-backdrop-filter: blur(20px) saturate(180%); backdrop-filter: blur(20px) saturate(180%); border-bottom: 1px solid rgba(255, 255, 255, .14); }
}
/* Menü: dichteres Glas, helle Schrift */
.site-nav { background: rgba(14, 14, 18, .78); -webkit-backdrop-filter: blur(40px) saturate(180%); backdrop-filter: blur(40px) saturate(180%); }
.site-nav a, .site-nav button { color: #F2F2F5; text-shadow: none; }
.site-nav a:hover, .site-nav button:hover { color: #fff; background: rgba(255, 255, 255, .14); }
.site-nav a[aria-current] { color: #fff; background: rgba(229, 9, 20, .45); }
.site-nav .menu-legal-start { border-top-color: rgba(255, 255, 255, .18); }

/* Menü oben rechts: nicht transparent */
.site-nav { background: #141418; -webkit-backdrop-filter: none; backdrop-filter: none; }

/* "So funktioniert's": jeder Schritt als Glas-Box */
.steps li {
  padding: 18px; border-radius: 20px;
  background: rgba(20, 20, 24, .38);
  -webkit-backdrop-filter: blur(24px) saturate(180%); backdrop-filter: blur(24px) saturate(180%);
  border: 1px solid rgba(255, 255, 255, .14); border-top-color: rgba(255, 255, 255, .3);
  box-shadow: 0 8px 32px rgba(0, 0, 0, .35), inset 0 1px 0 rgba(255, 255, 255, .12);
}
.steps li::before { background: rgba(255, 255, 255, .1); border-color: rgba(255, 255, 255, .2); color: #fff; }
.steps li::after { display: none !important; }
.steps span { max-width: none; }
@media (prefers-reduced-transparency: reduce), (prefers-contrast: more) {
  .steps li { background: #121214; backdrop-filter: none; -webkit-backdrop-filter: none; border-color: #4a4a4a; }
}

/* Aufnahme-Seite: Deine Aufnahme / Wer sie sieht / Gut zu wissen als Glas-Boxen */
.facts { gap: 10px; }
.facts li {
  padding: 16px; border-radius: 18px; border-bottom: 1px solid rgba(255, 255, 255, .14);
  background: rgba(20, 20, 24, .38);
  -webkit-backdrop-filter: blur(24px) saturate(180%); backdrop-filter: blur(24px) saturate(180%);
  border: 1px solid rgba(255, 255, 255, .14); border-top-color: rgba(255, 255, 255, .3);
  box-shadow: 0 8px 32px rgba(0, 0, 0, .35), inset 0 1px 0 rgba(255, 255, 255, .12);
}
.facts li:last-child { padding-bottom: 16px; }
.facts .ui-icon { color: #E6E6EA; }
.facts p { color: #E4E4E8; }
@media (prefers-reduced-transparency: reduce), (prefers-contrast: more) {
  .facts li { background: #121214; backdrop-filter: none; -webkit-backdrop-filter: none; border-color: #4a4a4a; }
}

/* Fehler "Ohne Kamera und Mikrofon …": rot blinkend, damit er auffällt */
#state.state-error {
  padding: 14px 16px; border-radius: 16px; font-size: 15px; font-weight: 600; line-height: 1.5; color: #fff;
  background: rgba(229, 9, 20, .35); border: 1px solid #FF4D57;
  -webkit-backdrop-filter: blur(24px) saturate(180%); backdrop-filter: blur(24px) saturate(180%);
  animation: state-error-blink 1s ease-in-out infinite;
}
@keyframes state-error-blink {
  0%, 100% { box-shadow: 0 0 0 0 rgba(255, 77, 87, 0); background-color: rgba(229, 9, 20, .3); }
  50% { box-shadow: 0 0 24px 4px rgba(255, 77, 87, .75); background-color: rgba(229, 9, 20, .6); }
}

/* So funktioniert's: unter dem Formular; Desktop immer offen als drei Karten, mobil ausklappbar */
.how-details > summary { list-style: none; display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.how-details > summary::-webkit-details-marker { display: none; }
.how-details > summary h2 { margin: 0; }
.how-details > summary::after {
  content: ''; flex: none; width: 32px; height: 32px; border-radius: 50%;
  background: rgba(255, 255, 255, .08) center / 12px no-repeat url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 12 12' fill='none' stroke='%23fff' stroke-width='1.8' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M2.5 4.5 6 8l3.5-3.5'/%3E%3C/svg%3E");
  border: 1px solid rgba(255, 255, 255, .16); transition: transform .25s;
}
.how-details[open] > summary::after { transform: rotate(180deg); }
.how-details > summary:focus-visible { outline: 2px solid var(--rec); outline-offset: 6px; border-radius: 12px; }
@media (min-width: 761px) {
  .how-section { padding: 48px 0 64px; }
  .how-details > summary { cursor: default; margin-bottom: 28px; }
  .how-details > summary::after { display: none; }
  .steps { gap: 20px; margin-top: 0; }
  .steps li {
    padding: 26px 24px 28px; grid-template-columns: 1fr; gap: 6px; border-radius: 24px; align-content: start;
    background: linear-gradient(180deg, rgba(255, 255, 255, .07), rgba(255, 255, 255, .025));
  }
  .steps li::before { grid-row: auto; width: 36px; height: 36px; margin-bottom: 14px; font-size: 15px; background: var(--rec-soft); border-color: rgba(229, 9, 20, .45); }
  .steps strong { font-size: 18px; letter-spacing: -.02em; }
  .steps span { font-size: 15px; line-height: 1.55; }
}
@media (max-width: 760px) { .how-details > summary { cursor: pointer; } }
.how-section h2 { color: #fff; }
@media (max-width: 760px) {
  .how-section { border-top: 0; padding-top: 8px; }
  .how-details > summary {
    padding: 14px 14px 14px 18px; border-radius: 18px; background: rgba(20, 20, 24, .38);
    -webkit-backdrop-filter: blur(24px) saturate(180%); backdrop-filter: blur(24px) saturate(180%);
    border: 1px solid rgba(255, 255, 255, .14); border-top-color: rgba(255, 255, 255, .3);
    box-shadow: 0 8px 32px rgba(0, 0, 0, .35), inset 0 1px 0 rgba(255, 255, 255, .12);
  }
  .how-details > summary h2 { font-size: 17px; }
  .how-details[open] > .steps { margin-top: 12px; }
}

/* Header bleibt beim Scrollen stehen (auch Desktop) */
.site-top, body:has(main.wide) .site-top { position: sticky; top: 0; z-index: 20; background: rgba(0, 0, 0, .72); -webkit-backdrop-filter: blur(16px); backdrop-filter: blur(16px); }
/* Smartphone: Startseite passt ohne Scrollen, solange "So funktioniert's" eingeklappt ist */
@media (max-width: 760px) {
  main.home .create-layout { padding: 12px 0 0; }
  main.home .how-section { padding: 12px 0 0; }
  main.home .privacy-note { margin-top: 10px; }
}
@media (max-width: 760px) {
  body:not(:has(main.fill)) main.home.home { padding-bottom: 0; }
  body:not(:has(main.fill)):not([data-screen="admin"]):has(main.home) { padding-bottom: calc(72px + env(safe-area-inset-bottom)); }
}
/* Header immer ganz oben (kein Body-Abstand darüber), auch Desktop */
body:not(:has(main.fill)) { padding-top: 0; }
body > .site-top { top: 0; padding-top: max(14px, env(safe-area-inset-top)); margin-bottom: 8px; }
/* Desktop-Kopfzeile: gleicher Glas-Look wie auf dem Smartphone (abgerundete Unterkante, heller Rand) */
@media (min-width: 761px) {
  body > .site-top {
    border-radius: 0 0 18px 18px; padding-inline: 20px;
    background: rgba(20, 20, 24, .38); -webkit-backdrop-filter: blur(24px) saturate(180%); backdrop-filter: blur(24px) saturate(180%);
    border: 1px solid rgba(255, 255, 255, .14); border-top: 0;
    box-shadow: 0 8px 32px rgba(0, 0, 0, .35), inset 0 -1px 0 rgba(255, 255, 255, .08);
  }
}
@media (min-width: 761px) and ((prefers-reduced-transparency: reduce) or (prefers-contrast: more)) {
  body > .site-top { background: #121214; -webkit-backdrop-filter: none; backdrop-filter: none; border-color: #4a4a4a; }
}

/* Smartphone: Video in der Aufnahme nutzt die volle Bildschirmbreite */
@media (max-width: 760px) {
  main.fill .stage { margin-inline: calc(50% - 50vw); width: 100vw; }
  main.fill .frame video, main.fill #still, main.fill #emoji-layer { border-radius: 0; }
}
/* Smartphone: Timer und Emoji-Leiste liegen über dem Video, damit es die ganze Höhe und damit die volle Breite bekommt */
@media (max-width: 760px) {
  main.fill .create-content { position: relative; }
  main.fill .timer, main.fill .emoji-controls { position: absolute; left: 0; right: 0; z-index: 3; padding: 10px 14px; }
  main.fill .timer { top: 0; background: linear-gradient(rgba(0, 0, 0, .65), transparent); }
  main.fill .emoji-controls { bottom: 0; padding-bottom: 14px; background: linear-gradient(transparent, rgba(0, 0, 0, .65)); }
  main.fill .emoji-controls .small { display: none; }
  /* Vor dem Start und in der Pause steht unten «Video starten»/«Weiter»: Emoji-Leiste dann im Fluss darüber,
     nicht über dem Knopf (sonst fängt sie die Fingertipps ab) und nicht über dem Video */
  main.fill .create-content:has(> #start:not([hidden])) .emoji-controls { position: static; }
}
@media (max-width: 760px) {
  body:has(main.fill) { padding-top: 0; padding-bottom: 0; padding-inline: 0; }
}

.count-badge { display: inline-block; vertical-align: middle; margin-left: 6px; min-width: 28px; padding: 2px 9px; border-radius: 999px; background: var(--rec-soft); border: 1px solid rgba(229, 9, 20, .45); color: #FF8A91; font-size: .5em; font-weight: 700; letter-spacing: 0; text-align: center; line-height: 1.5; }
.nav-count { display: inline-block; margin-left: 6px; min-width: 20px; padding: 0 6px; border-radius: 999px; background: var(--rec-soft); border: 1px solid rgba(229, 9, 20, .45); color: #FF8A91; font-size: 11px; font-weight: 700; line-height: 18px; text-align: center; text-shadow: none; }
.nav-count { white-space: nowrap; }
/* Untere Leiste: Pille über dem Symbol statt im Text, damit lange Namen nicht umbrechen */
.bottom-nav a { position: relative; }
.bottom-nav .nav-count { position: absolute; top: 4px; left: calc(50% + 6px); margin: 0; min-width: 18px; padding: 0 5px; font-size: 10px; line-height: 16px; }

/* Smartphone: Admin-Tabs als Raster (2 Spalten) statt seitlich zu wischen */
@media (max-width: 760px) {
  .tabs { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); overflow: visible; }
  .tabs button { width: 100%; min-height: 48px; padding: 10px 8px; white-space: normal; }
  .tabs button:last-child:nth-child(odd) { grid-column: 1 / -1; }
}

/* Formular nur mit Eingabefeld und darunter den Plattformen (kein Titel, Icon, Label), auf allen Bildschirmen gleich */
.form .form-heading { display: none; }
.form label[for="url"] { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
.form #url {
  padding-left: 44px;
  background: no-repeat 14px center / 18px url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23999' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M10 13a5 5 0 0 0 7 0l3-3a5 5 0 0 0-7-7l-1 1'/%3E%3Cpath d='M14 11a5 5 0 0 0-7 0l-3 3a5 5 0 0 0 7 7l1-1'/%3E%3C/svg%3E");
}
/* „Link erstellen“: nur Pfeil bzw. Spinner, damit das Eingabefeld genug Platz behält (Text bleibt für Screenreader) */
.url-row { gap: 8px; }
#go { width: 56px; padding: 0; position: relative; }
#go .go-label { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
/* Roter Punkt im Header auf halber Höhe des «r» (x-Höhe), nicht auf der Mitte der Wortmarke */
.site-top .brand::before { transform: translateY(1.5px); }
