/* Hyvor-like dark UI (MVP) */
.hen-talk {
  margin-top: 2rem;
  margin-bottom: 4.5rem;
  padding: 0;
  border: 0;
  border-radius: 16px;
  background: transparent;
  color: #e5e7eb;
  overflow: visible;
}

/* Inner wrapper keeps rounded clipping without cutting dropdowns. */
.hen-talk__inner {
  border-radius: 16px;
  background: #111213;
  overflow: hidden;
  padding-bottom: 50px;
}

/* Ensure HTML `hidden` always wins (our styles use flex/grid). */
.hen-talk [hidden] {
  display: none !important;
}

.hen-talk__reactions {
  padding: 1.25rem 1.25rem 0.75rem;
}
.hen-talk__reactionsTitle {
  text-align: center;
  color: #cbd5e1;
  font-weight: 600;
  margin-bottom: 0.75rem;
}
.hen-talk__reactionRow {
  display: flex;
  gap: 1.1rem;
  justify-content: center;
  flex-wrap: wrap;
}
.hen-talk__reaction {
  display: grid;
  grid-template-columns: 18px auto;
  grid-template-rows: auto auto;
  column-gap: 0.45rem;
  row-gap: 0.1rem;
  align-items: center;
  padding: 0.25rem 0.4rem;
  border: 0;
  background: transparent;
  color: #e5e7eb;
  cursor: pointer;
}
.hen-talk__reactionEmoji {
  grid-row: 1 / span 2;
  font-size: 1.05rem;
}
.hen-talk__reactionCount {
  font-weight: 700;
  font-size: 0.95rem;
  line-height: 1;
}
.hen-talk__reactionLabel {
  grid-column: 2;
  font-size: 0.75rem;
  color: #9ca3af;
  text-transform: lowercase;
}
.hen-talk__reaction.is-active .hen-talk__reactionCount { color: #ffffff; }
.hen-talk__reaction:hover .hen-talk__reactionLabel { color: #d1d5db; }

.hen-talk__header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 1rem 1.25rem 0.75rem;
}

.hen-talk__headerLeft {
  display: flex;
  align-items: baseline;
  gap: 0.9rem;
}

.hen-talk__title {
  margin: 0;
  font-size: 1.25rem;
  font-weight: 700;
  letter-spacing: 0.2px;
}

.hen-talk__online {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  color: #9ca3af;
  font-size: 0.85rem;
  text-transform: uppercase;
  letter-spacing: 0.8px;
}
.hen-talk__dot {
  width: 7px;
  height: 7px;
  border-radius: 999px;
  background: #22c55e;
  box-shadow: 0 0 0 3px rgba(34,197,94,0.14);
}

.hen-talk__login {
  color: #d1d5db;
  font-size: 0.85rem;
  text-transform: uppercase;
  letter-spacing: 0.8px;
  text-decoration: none;
}
.hen-talk__login:hover { color: #ffffff; }

.hen-talk__composer {
  padding: 0.5rem 1.25rem 0.75rem;
}

.hen-talk__row {
  display: flex;
  gap: 0.75rem;
  margin-top: 0.75rem;
}

.hen-talk__replying {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  padding: 0.5rem 0.75rem;
  border: 1px solid rgba(255,255,255,0.10);
  border-radius: 12px;
  background: rgba(255,255,255,0.03);
  color: #cbd5e1;
  margin-bottom: 0.65rem;
}

.hen-talk__thread {
  display: flex;
  flex-direction: column;
  gap: 0.9rem;
}
.hen-talk__thread[data-ht-depth="2"],
.hen-talk__thread[data-ht-depth="3"] {
  margin-left: 1.25rem;
  padding-left: 0.9rem;
  border-left: 1px solid rgba(255,255,255,0.08);
}

.hen-talk__hp {
  position: absolute !important;
  left: -9999px !important;
  width: 1px !important;
  height: 1px !important;
  opacity: 0 !important;
}

.hen-talk__input,
.hen-talk__textarea {
  width: 100%;
  border: 1px solid rgba(255,255,255,0.08);
  border-radius: 14px;
  padding: 0.9rem 1rem;
  font-size: 1rem;
  background: rgba(255,255,255,0.06);
  color: #e5e7eb;
}
.hen-talk__input::placeholder,
.hen-talk__textarea::placeholder {
  color: rgba(229,231,235,0.6);
}
.hen-talk__textarea {
  resize: vertical;
  min-height: 90px;
}

.hen-talk__toolbar {
  display: flex;
  align-items: center;
  gap: 0.35rem;
  margin-top: 0.6rem;
}
.hen-talk__tool {
  border: 0;
  background: transparent;
  color: #cbd5e1;
  padding: 0.25rem 0.35rem;
  border-radius: 8px;
  cursor: pointer;
  font-size: 0.95rem;
}
.hen-talk__tool:hover {
  background: rgba(255,255,255,0.06);
  color: #ffffff;
}
.hen-talk__toolbarSpacer { flex: 1; }

.hen-talk__button {
  border: 0;
  border-radius: 999px;
  padding: 0.55rem 1.1rem;
  font-weight: 700;
  background: #0b0c0d;
  color: #fff;
  cursor: pointer;
}
.hen-talk__button:hover { background: #000000; }

.hen-talk__status {
  font-size: 0.95rem;
  color: #9ca3af;
}
.hen-talk__status[data-type="error"] { color: #ef4444; }
.hen-talk__status[data-type="success"] { color: #34d399; }

.hen-talk__footerBar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0.4rem 1.25rem 0.9rem;
  color: #9ca3af;
}
.hen-talk__sort {
  position: relative;
}
.hen-talk__sortButton {
  border: 0;
  background: transparent;
  color: #cbd5e1;
  cursor: pointer;
  padding: 0.25rem 0;
  font-size: 0.9rem;
}
.hen-talk__sortButton:hover { color: #ffffff; }
.hen-talk__sortMenu {
  position: absolute;
  top: 28px;
  left: 0;
  z-index: 20;
  min-width: 160px;
  padding: 0.35rem;
  border: 1px solid rgba(255,255,255,0.10);
  border-radius: 12px;
  background: #0b0c0d;
  box-shadow: 0 14px 40px rgba(0,0,0,0.55);
}
.hen-talk__sortMenu.is-up {
  top: auto;
  bottom: 28px;
}
.hen-talk__sortItem {
  width: 100%;
  text-align: left;
  border: 0;
  background: transparent;
  color: #e5e7eb;
  padding: 0.55rem 0.6rem;
  border-radius: 10px;
  cursor: pointer;
}
.hen-talk__sortItem:hover {
  background: rgba(255,255,255,0.06);
}

.hen-talk__searchWrap {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
}
.hen-talk__searchInput {
  width: min(320px, 48vw);
  border: 1px solid rgba(255,255,255,0.10);
  border-radius: 999px;
  padding: 0.45rem 0.8rem;
  background: rgba(255,255,255,0.06);
  color: #e5e7eb;
}
.hen-talk__searchInput::placeholder { color: rgba(229,231,235,0.55); }

.hen-talk__search { opacity: 0.9; }

.hen-talk__emojiPanel {
  position: absolute;
  z-index: 30;
  width: min(720px, 92vw);
  max-height: 320px;
  overflow: auto;
  margin-top: 8px;
  padding: 0.75rem;
  border: 1px solid rgba(255,255,255,0.12);
  border-radius: 14px;
  background: #0b0c0d;
  box-shadow: 0 14px 40px rgba(0,0,0,0.55);
}
.hen-talk__emojiTop {
  display: flex;
  gap: 0.6rem;
  align-items: center;
  margin-bottom: 0.65rem;
}
.hen-talk__emojiSearch {
  flex: 1;
  border: 1px solid rgba(255,255,255,0.10);
  border-radius: 999px;
  padding: 0.45rem 0.8rem;
  background: rgba(255,255,255,0.06);
  color: #e5e7eb;
}
.hen-talk__emojiSearch::placeholder { color: rgba(229,231,235,0.55); }
.hen-talk__emojiTabs {
  display: flex;
  gap: 0.25rem;
  flex-wrap: wrap;
  margin-bottom: 0.5rem;
}
.hen-talk__emojiTab {
  border: 0;
  background: rgba(255,255,255,0.06);
  color: #cbd5e1;
  padding: 0.25rem 0.45rem;
  border-radius: 10px;
  cursor: pointer;
}
.hen-talk__emojiTab.is-active { background: rgba(255,255,255,0.12); color: #fff; }
.hen-talk__emojiGrid {
  display: grid;
  grid-template-columns: repeat(14, 1fr);
  gap: 0.25rem;
}
@media (max-width: 720px) {
  .hen-talk__emojiGrid { grid-template-columns: repeat(10, 1fr); }
}
.hen-talk__emojiBtn {
  border: 0;
  background: transparent;
  cursor: pointer;
  padding: 0.25rem;
  border-radius: 10px;
  font-size: 1.1rem;
  line-height: 1;
}
.hen-talk__emojiBtn:hover { background: rgba(255,255,255,0.08); }

.hen-talk__list {
  display: flex;
  flex-direction: column;
  gap: 0.9rem;
  padding: 0 1.25rem 1.75rem;
}

.hen-talk__empty {
  color: #9ca3af;
  padding: 0.75rem;
  border: 1px dashed rgba(255,255,255,0.16);
  border-radius: 14px;
}

.hen-talk__comment {
  padding: 0.85rem 0.95rem;
  border: 1px solid rgba(255,255,255,0.08);
  border-radius: 14px;
  background: rgba(255,255,255,0.03);
}

.hen-talk__commentHead {
  display: flex;
  justify-content: space-between;
  gap: 0.75rem;
  margin-bottom: 0.35rem;
}

.hen-talk__commentMeta {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
}

.hen-talk__commentAction {
  border: 0;
  background: transparent;
  color: #cbd5e1;
  cursor: pointer;
  padding: 0.15rem 0.25rem;
  border-radius: 8px;
  font-size: 0.85rem;
}
.hen-talk__commentAction:hover {
  background: rgba(255,255,255,0.06);
  color: #ffffff;
}
.hen-talk__commentAction--danger { color: #fca5a5; }
.hen-talk__commentAction--danger:hover { color: #fecaca; }

.hen-talk__editForm {
  margin-top: 0.6rem;
}

.hen-talk__votes {
  display: flex;
  gap: 0.6rem;
  margin-top: 0.55rem;
}
.hen-talk__voteBtn {
  border: 1px solid rgba(255,255,255,0.10);
  background: rgba(255,255,255,0.03);
  color: #cbd5e1;
  border-radius: 999px;
  padding: 0.25rem 0.55rem;
  cursor: pointer;
  font-size: 0.9rem;
}
.hen-talk__voteBtn:hover {
  background: rgba(255,255,255,0.06);
  color: #ffffff;
}
.hen-talk__voteBtn.is-active {
  border-color: rgba(147,197,253,0.55);
  background: rgba(147,197,253,0.12);
  color: #ffffff;
}

.hen-talk__author {
  font-weight: 700;
  color: #f9fafb;
}

.hen-talk__time {
  color: #9ca3af;
  font-size: 0.9rem;
}

.hen-talk__content {
  white-space: pre-wrap;
  line-height: 1.5;
}

.hen-talk__content a {
  color: #93c5fd;
  text-decoration: underline;
}
.hen-talk__content blockquote {
  margin: 0.65rem 0;
  padding-left: 0.85rem;
  border-left: 3px solid rgba(255,255,255,0.18);
  color: #cbd5e1;
}

