/* ===========================
   Grundlayout
=========================== */
body {
  margin: 0;
  font-family: system-ui, sans-serif;
  background: #f2f4f8;
  height: 100vh;
  width: 100vw;
  overflow: hidden; /* kein Body-Scroll */
}

.splash-container {
  width: 100vw;
  height: 100vh;
  background: white;
  display: flex;
  flex-direction: column;
  margin: 0;
  overflow: hidden; /* nichts läuft raus */
}

/* ===========================
   Header
=========================== */
.splash-header {
  background: url("../Bilder/splashbild.jpg") center/cover no-repeat;
  color: white;
  text-align: center;
  font-size: 22px;
  font-weight: bold;
  position: relative;
  height: 200px;     /* etwas kleiner */
  display: flex;
  justify-content: center;
  align-items: center;
  border-bottom: 2px solid #00c6ff;
  flex-shrink: 0;
}

.splash-header::after {
  content: "";
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.25);
  z-index: 0;
}

.splash-header h1 {
  position: relative;
  z-index: 1;
}

/* ===========================
   Chat-Fenster
=========================== */
.chat-window {
  flex: 1 1 auto;   /* füllt den Platz zwischen Header & Input */
  min-height: 0;    /* wichtig, damit Input sichtbar bleibt */
  padding: 10px;
  overflow-y: auto;
  display: flex;
  flex-direction: column;
  gap: 10px;
  background: #eef3f8;
}

/* ===========================
   Eingabebereich unten
=========================== */
.chat-input {
  display: flex;
  border-top: 1px solid #ddd;
  padding: 12px;
  background: #fff;
  flex-shrink: 0;   /* bleibt sichtbar */
  height: 70px;     /* etwas kleiner, aber sichtbar */
  align-items: center;
}

.chat-input input {
  flex: 1;
  padding: 14px;
  border: 1px solid #ccc;
  border-radius: 12px;
  outline: none;
  font-size: 15px;
}

.chat-input button {
  margin-left: 10px;
  padding: 14px 20px;
  background: #007bff;
  border: none;
  color: white;
  border-radius: 12px;
  cursor: pointer;
  font-weight: bold;
  font-size: 15px;
  transition: background 0.2s;
}

.chat-input button:hover {
  background: #005fcc;
}

/* ===========================
   Nachrichten-Blasen
=========================== */
.bubble {
  display: inline-block;
  padding: 12px 16px;
  border-radius: 20px;
  margin: 6px 0;
  max-width: 70%;
  word-wrap: break-word;
  font-size: 15px;
  line-height: 1.4;
  position: relative;
  animation: pop 0.3s ease-out;
}

.bubble.me {
  background: linear-gradient(135deg, #007aff, #00c6ff);
  color: white;
  align-self: flex-end;
  margin-left: auto;
}

.bubble.other {
  background: linear-gradient(135deg, #ff5f6d, #ffc371);
  color: white;
  align-self: flex-start;
  margin-right: auto;
}

/* ===========================
   Systemmeldungen (Absperrband)
=========================== */
.bubble.system {
  display: block;
  background: repeating-linear-gradient(
    45deg,
    #ffcccc,
    #ffcccc 12px,
    white 12px,
    white 24px
  );
  color: #b30000;
  border: 2px solid red;
  border-radius: 12px;
  padding: 14px 18px;
  margin: 15px auto;
  max-width: 80%;
  text-align: center;
  font-size: 15px;
  font-weight: bold;
  align-self: center !important;  /* erzwingt Zentrierung */
  box-shadow: 0 2px 6px rgba(0,0,0,0.1); /* leichte Tiefe */
}

/* ===========================
   Animation
=========================== */
@keyframes pop {
  from { transform: scale(0.8); opacity: 0.3; }
  to   { transform: scale(1); opacity: 1; }
}

/* ===========================
   Zurück-Pfeil (rechts oben)
=========================== */
.back-link {
  position: absolute;
  top: 12px;
  right: 12px;
  font-size: 20px;
  color: white;
  text-decoration: none;
  z-index: 2;
  background: rgba(0,0,0,0.3);
  padding: 6px 10px;
  border-radius: 50%;
  transition: background 0.2s;
}

.back-link:hover {
  background: rgba(0,0,0,0.5);
}

/* ===========================
   Footer
=========================== */
.splash-footer {
  flex-shrink: 0;
  padding: 8px;
  font-size: 0.8em;
  text-align: center;
  color: #93a4c8;
  background: #f2f4f8;
  border-top: 1px solid #ddd;
}