/* ==========================================================================
   Kommentare — Messenger-artiger Verlauf auf Basis von Bootstraps Grid
   (col-*/offset-* aus dem bestehenden Markup steuern die Links/Rechts-
   Ausrichtung; dieses Stylesheet kümmert sich nur um Farben, Typografie
   und Formular-Look, ohne die Struktur des Markups anzufassen).
   ========================================================================== */

.comments-area {
  margin-top: 1rem;
}

.comments-title {
  font-family: var(--font-head);
  font-weight: 700;
  font-size: 1.4rem;
  letter-spacing: -0.01em;
  color: var(--color-text);
  margin-bottom: 2rem;
}

/* --- Avatare ------------------------------------------------------------ */

.i-avatar {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  object-fit: cover;
  background: var(--color-hairline);
}

/* Fallback-Farben, falls die Avatar-Bilder (noch) nicht auflösen —
   erkannt am Dateinamen, passend zu den zwei Rollen im Verlauf. */
.i-avatar[src*="raccoon-you"] {
  background: #7a6cf0;
}

.i-avatar[src*="raccoon-me"] {
  background: var(--color-yellow-deep);
}

/* --- Sprechblasen --------------------------------------------------------- */

.comment-list .bg-you,
.comment-list .bg-me {
  padding: 0.9rem 1.15rem;
  font-family: var(--font-body);
  font-size: 1rem;
  line-height: 1.6;
  color: var(--color-text);
}

.comment-list .bg-you {
  background: #f1efe9;
}

.comment-list .bg-me {
  background: var(--color-yellow);
  color: var(--color-ink);
}

@media (prefers-color-scheme: dark) {
  .comment-list .bg-you {
    background: #2a2926;
  }
}

.comment-list .bg-you p,
.comment-list .bg-me p {
  margin: 0.15rem 0 0.5rem;
}

/* Name (verlinkt oder nicht) + Zeitstempel — die Kopfzeile jeder Blase ist
   im Markup einfacher Fließtext, daher wird sie hier als erste Zeile
   typografisch hervorgehoben statt einzeln pro Element. */
.comment-list .bg-you,
.comment-list .bg-me {
  font-family: var(--font-body);
}

.comment-list .url {
  font-family: var(--font-head);
  font-weight: 700;
  font-size: 0.92rem;
  color: var(--color-text);
  text-decoration: none;
}

.comment-list .url:hover {
  text-decoration: underline;
  text-decoration-color: var(--color-yellow-deep);
}

.comment-list .bg-you strong,
.comment-list .bg-me strong {
  font-family: var(--font-head);
  font-weight: 700;
  font-size: 0.92rem;
}

/* --- Permalink & Antworten-Link ------------------------------------------- */

.comment-list a[href^="#c"] {
  font-family: var(--font-head);
  font-size: 0.75rem;
  color: var(--color-muted);
  text-decoration: none;
  margin-right: 0.75rem;
}

.comment-list a[href^="#c"]:hover {
  color: var(--color-text);
}

.comment-reply-link {
  font-family: var(--font-head);
  font-size: 0.75rem;
  font-weight: 600;
  color: var(--color-yellow-deep);
  text-decoration: none;
  border-bottom: 1px solid transparent;
}

.comment-reply-link:hover {
  border-color: var(--color-yellow-deep);
}

/* --- Verschachtelte Antworten --------------------------------------------- */

.comment-list .children {
  margin-top: 1.25rem;
  margin-bottom: 0;
}

.comment-list li.comment {
  margin-bottom: 1.25rem;
}

.comment-list li.comment:last-child,
.comment-list .children li.comment:last-child {
  margin-bottom: 0;
}

/* --- Formular -------------------------------------------------------------- */

.comment-respond {
  margin-top: 1rem;
}

.comment-reply-title {
  font-family: var(--font-head);
  font-weight: 700;
  font-size: 1.3rem;
  letter-spacing: -0.01em;
  color: var(--color-text);
  margin-bottom: 1.25rem;
}

.comment-reply-title small a {
  font-family: var(--font-head);
  font-size: 0.8rem;
  font-weight: 500;
  color: var(--color-muted);
}

.comment-policy {
  background: #f6f5f1;
  border-radius: 12px;
  padding: 1rem 1.25rem;
  font-family: var(--font-body);
  font-size: 0.92rem;
  line-height: 1.6;
  color: var(--color-muted);
  margin-bottom: 1.5rem;
}

@media (prefers-color-scheme: dark) {
  .comment-policy {
    background: #242320;
  }
}

.comment-policy a {
  color: var(--color-yellow-deep);
  text-decoration: none;
  border-bottom: 1px solid var(--color-yellow);
}

.comment-form textarea,
.comment-form input[type="text"],
.comment-form input[type="url"] {
  display: block;
  width: 100%;
  font-family: var(--font-body);
  font-size: 1rem;
  color: var(--color-text);
  background: var(--color-surface);
  border: 1px solid var(--color-hairline);
  border-radius: 12px;
  padding: 0.85rem 1.1rem;
  margin-bottom: 1rem;
  transition: border-color 0.2s ease;
}

.comment-form textarea {
  resize: vertical;
  min-height: 8rem;
}

.comment-form textarea::placeholder,
.comment-form input::placeholder {
  color: var(--color-muted);
}

.comment-form textarea:focus,
.comment-form input[type="text"]:focus,
.comment-form input[type="url"]:focus {
  outline: none;
  border-color: var(--color-yellow-deep);
}

.comment-form-cookies-consent {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-family: var(--font-body);
  font-size: 0.92rem;
  color: var(--color-muted);
  margin-bottom: 1.5rem;
}

.comment-form-cookies-consent input {
  width: auto;
  margin: 0;
}

.form-submit {
  margin: 0;
}

.form-submit button {
  font-family: var(--font-head);
  font-weight: 600;
  font-size: 0.95rem;
  color: #ffffff;
  background: var(--color-ink);
  border: none;
  border-radius: 999px;
  padding: 0.85rem 1.85rem;
  cursor: pointer;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.form-submit button:hover {
  transform: translateY(-2px);
  box-shadow: 0 14px 28px -10px rgba(27, 24, 18, 0.3);
}
