/* Geheimfrequenz – Kokolores
 * Bewusst immer dunkel: Schwarz/Weiß wie das Logo, rot nur für "Aufnahme". */
:root {
  color-scheme: dark;
  --bg: #050506;
  --card: #0f0f11;
  --card-2: #16161a;
  --text: #f5f5f7;
  --muted: #8d8d97;
  --line: #24242a;
  --accent: #ffffff;
  --accent-ink: #050506;
  --ok: #22c55e;
  --danger: #ff3b3b;
  --radius: 20px;
}

* { box-sizing: border-box; }
html, body { margin: 0; }
[hidden] { display: none !important; }

body {
  background:
    radial-gradient(1200px 600px at 50% -10%, rgba(255,255,255,.07), transparent 60%),
    var(--bg);
  background-attachment: fixed;
  color: var(--text);
  font: 16px/1.5 system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", sans-serif;
  -webkit-font-smoothing: antialiased;
}

.wrap {
  max-width: 560px;
  min-height: 100vh;
  margin: 0 auto;
  padding: max(36px, env(safe-area-inset-top)) 16px max(24px, env(safe-area-inset-bottom));
  display: flex;
  flex-direction: column;
  gap: 22px;
}

/* Kopf */
.brand { text-align: center; }
.logo-link { display: inline-block; }
.logo {
  display: block;
  width: min(260px, 70vw);
  height: auto;
  margin: 0 auto;
  filter: drop-shadow(0 0 28px rgba(255,255,255,.12));
}
.brand h1 {
  margin: 26px 0 6px;
  font-size: clamp(26px, 7vw, 34px);
  font-weight: 800;
  letter-spacing: .14em;
  text-transform: uppercase;
}
.brand p { margin: 0; color: var(--muted); }
.brand .claim { color: var(--text); font-weight: 600; }

/* Frequenz-Linie unter der Überschrift */
.wave { display: flex; justify-content: center; gap: 4px; height: 18px; margin: 14px 0 0; align-items: center; }
.wave i { display: block; width: 3px; border-radius: 2px; background: var(--text); opacity: .7; animation: eq 1.2s ease-in-out infinite; }
.wave i:nth-child(1){height:6px;animation-delay:-.9s}
.wave i:nth-child(2){height:14px;animation-delay:-.6s}
.wave i:nth-child(3){height:9px;animation-delay:-.3s}
.wave i:nth-child(4){height:18px;animation-delay:-.75s}
.wave i:nth-child(5){height:11px;animation-delay:-.15s}
.wave i:nth-child(6){height:15px;animation-delay:-.45s}
.wave i:nth-child(7){height:7px;animation-delay:-1.05s}
@keyframes eq { 50% { transform: scaleY(.35); } }
@media (prefers-reduced-motion: reduce) { .wave i, .card { animation: none !important; } }

/* Karten */
.card {
  background: linear-gradient(180deg, var(--card-2), var(--card));
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 20px;
  display: flex; flex-direction: column; gap: 16px;
  animation: in .25s ease-out;
}
@keyframes in { from { opacity: 0; transform: translateY(6px); } }
.center { text-align: center; align-items: stretch; }
h2 { margin: 0; font-size: 21px; letter-spacing: -.01em; }

/* Tabs */
.tabs {
  display: grid; grid-template-columns: repeat(3, 1fr); gap: 4px;
  background: #000; border: 1px solid var(--line); border-radius: 13px; padding: 4px;
}
.tab {
  border: 0; background: transparent; color: var(--muted);
  font: inherit; font-weight: 600; padding: 9px; border-radius: 9px; cursor: pointer;
  letter-spacing: .04em;
}
.tab[aria-selected="true"] { background: var(--text); color: var(--accent-ink); }

/* Felder */
textarea, select, .linkbox input {
  font: inherit; color: inherit;
  background: #000; border: 1px solid var(--line); border-radius: 14px;
}
textarea { width: 100%; min-height: 190px; resize: vertical; padding: 14px; }
select { padding: 8px 12px; }
textarea:focus, select:focus, .linkbox input:focus { outline: 2px solid var(--text); outline-offset: 1px; }
::placeholder { color: #5c5c66; }

/* Rekorder */
.recorder {
  display: flex; flex-direction: column; align-items: center; gap: 14px;
  padding: 22px 16px; border: 1.5px dashed var(--line); border-radius: 16px;
}
.timer { font-size: 34px; font-weight: 700; font-variant-numeric: tabular-nums; }
audio, video { width: 100%; border-radius: 12px; }
video { background: #000; max-height: 380px; }
.filepick { margin: 10px 0 0; text-align: center; font-size: 14px; color: var(--muted); }
.filepick label { color: var(--text); font-weight: 600; cursor: pointer; text-decoration: underline; text-underline-offset: 3px; }
.filepick input { position: absolute; width: 1px; height: 1px; opacity: 0; pointer-events: none; }

/* Buttons */
.btn {
  appearance: none; cursor: pointer; text-decoration: none;
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  font: inherit; font-weight: 600;
  padding: 12px 18px; border-radius: 999px;
  background: transparent; color: var(--text); border: 1px solid #3a3a42;
  transition: transform .08s, opacity .2s, background .2s;
}
.btn:hover { background: rgba(255,255,255,.05); }
.btn:active { transform: scale(.98); }
.btn:disabled { opacity: .5; cursor: default; }
.btn.primary {
  width: 100%; padding: 15px;
  background: var(--accent); border-color: var(--accent); color: var(--accent-ink);
  text-transform: uppercase; letter-spacing: .08em; font-weight: 800;
}
.btn.primary:hover { background: #e9e9ec; }
.btn .dot { width: 10px; height: 10px; border-radius: 50%; background: var(--danger); }
.btn.recording { border-color: var(--danger); color: var(--danger); }
.btn.recording .dot { animation: pulse 1s infinite; }
@keyframes pulse { 50% { opacity: .2; } }

/* Sonstiges */
.row { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.meta { margin: 0; color: var(--muted); font-size: 14px; }
.meta:empty { display: none; }
.err { margin: 0; color: var(--danger); font-size: 14px; }
.err:empty { display: none; }
.note { margin: 0; color: var(--muted); font-size: 13px; }
.progress { height: 4px; background: var(--line); border-radius: 99px; overflow: hidden; }
.bar { height: 100%; width: 0; background: var(--text); transition: width .2s; }

.linkbox { display: flex; gap: 8px; }
.linkbox input { flex: 1; min-width: 0; padding: 10px 14px; font-size: 14px; }

.icon-big {
  width: 64px; height: 64px; border-radius: 50%; margin: 0 auto;
  display: grid; place-items: center; background: #000; border: 1px solid var(--line); color: var(--text);
}
.icon-big.ok { color: var(--ok); border-color: rgba(34,197,94,.35); }

.msg-text {
  margin: 0; padding: 16px; border-radius: 14px; background: #000; border: 1px solid var(--line);
  white-space: pre-wrap; overflow-wrap: anywhere; max-height: 60vh; overflow: auto;
  font: inherit;
}
#content { display: flex; flex-direction: column; gap: 12px; }
.burned { margin: 0; font-size: 14px; color: var(--muted); text-align: center; }

footer { margin-top: auto; text-align: center; font-size: 12px; color: var(--muted); letter-spacing: .06em; }
