/* ==========================================================
   FYNBIZ · FYN.chat — Kundenseite
   Mobile-first: die Einstiegsseite ist eine einzige Funktion,
   deshalb keine Navigation, keine Nebenwege.
   ========================================================== */

.einstieg {
  min-height: 100vh;
  display: flex; flex-direction: column; align-items: center;
  padding: 28px 20px calc(28px + env(safe-area-inset-bottom));
  gap: 26px;
}

.einstieg-kopf { width: 100%; max-width: 440px; display: flex; justify-content: center; }

.einstieg-karte {
  width: 100%; max-width: 440px;
  margin-top: auto;
  display: flex; flex-direction: column;
}

.einstieg-titel {
  font-size: 1.5rem; font-weight: 500; line-height: 1.25;
  letter-spacing: -0.01em; margin-bottom: 10px;
}

.einstieg-text {
  font-size: 0.95rem; line-height: 1.6;
  color: var(--c-text-readable); margin-bottom: 24px;
}
.einstieg-text strong { color: var(--c-text-hi); font-weight: 600; overflow-wrap: anywhere; }

.session-badge { margin-bottom: 14px; }

.label-optional {
  text-transform: none; letter-spacing: 0;
  color: var(--c-text-low); font-weight: 400;
}

.einstieg-trust {
  margin-top: 22px; padding-top: 20px;
  border-top: 1px solid var(--surface-border);
}

.einstieg-fuss {
  width: 100%; max-width: 440px; margin-top: auto;
  font-size: 0.76rem; line-height: 1.6; color: var(--c-text-low);
  text-align: center;
}
.einstieg-fuss a { color: var(--c-text-mid); text-decoration: underline; }
.einstieg-fuss a:hover { color: var(--c-bright); }

/* ── OTP-Feld ── */
.otp-input {
  font-family: var(--font-brand);
  font-size: 1.7rem; font-weight: 600;
  text-align: center; letter-spacing: 0.5em;
  padding-left: 0.5em; /* kompensiert das letter-spacing hinter der letzten Ziffer */
  min-height: 62px;
  font-variant-numeric: tabular-nums;
}
.otp-input::placeholder { letter-spacing: 0.35em; color: var(--c-text-low); }

.otp-aktionen {
  display: flex; justify-content: space-between; gap: 8px;
  margin-top: 14px; flex-wrap: wrap;
}
.otp-aktionen .btn-ghost { font-size: 0.85rem; padding: 8px 10px; }

/* ── Chat-Raum ── */

/* Platzhalter im Kopf: enthält je nach Zustand das FYNBIZ-Zeichen, das Foto
   des Beraters oder seine Initialen. Feste Größe, damit der Kopf beim Wechsel
   nicht springt. */
.kopf-avatar {
  width: 40px; height: 40px; flex-shrink: 0;
  display: flex; align-items: center; justify-content: center;
}
.kopf-avatar .kopf-marke { width: 26px; height: 26px; opacity: 0.75; }
.kopf-avatar .avatar { width: 40px; height: 40px; font-size: 0.86rem; }

.host-foto {
  width: 40px; height: 40px; border-radius: 50%;
  object-fit: cover; object-position: center top;
  border: 1px solid var(--surface-border-hi);
}

.btn-abmelden-klein {
  width: 40px; height: 40px;
  background: transparent; border-color: var(--surface-border);
  color: var(--c-text-mid);
}
.btn-abmelden-klein:hover { color: var(--c-text-hi); background: var(--surface-2); }
.btn-abmelden-klein svg { width: 17px; height: 17px; }

/* Auf schmalen Displays hat die Kopfzeile drei Elemente + Logo — die Restzeit-
   Pille tritt zurück, Titel und Abmelden bleiben. */
@media (max-width: 430px) {
  .chat-kopf .brand > img { height: 16px; }
  .chat-kopf .pill { padding: 4px 8px; font-size: 0.7rem; }
}

.session-ende-hinweis {
  align-self: center; text-align: center;
  max-width: 420px; margin: 18px 0 8px; padding: 16px 20px;
  background: var(--surface); border: 1px solid var(--surface-border);
  border-radius: var(--radius-md);
  font-size: 0.88rem; line-height: 1.6; color: var(--c-text-mid);
}

.warte-hinweis {
  align-self: center; text-align: center;
  max-width: 440px; margin: 8px 0 18px; padding: 18px 20px;
  background: rgba(47,224,201,0.06);
  border: 1px solid var(--c-bright-dim); border-radius: var(--radius-md);
  font-size: 0.9rem; line-height: 1.6; color: var(--c-text-readable);
}
.warte-hinweis strong { color: var(--c-text-hi); font-weight: 600; }

.verbindung-weg {
  position: fixed; top: 0; left: 0; right: 0; z-index: 150;
  padding: 9px 16px; text-align: center;
  font-size: 0.82rem; font-weight: 500;
  background: var(--c-warning); color: #2a1a00;
}

@media (max-width: 560px) {
  .einstieg { padding: 20px 16px calc(20px + env(safe-area-inset-bottom)); gap: 20px; }
  .einstieg-titel { font-size: 1.32rem; }
  .otp-input { font-size: 1.45rem; min-height: 58px; }
}

/* Auf sehr niedrigen Viewports (Tastatur offen) nicht künstlich strecken */
@media (max-height: 620px) {
  .einstieg-karte { margin-top: 0; }
  .einstieg-fuss  { margin-top: 20px; }
}
