.md-header__nav {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  margin-left: 0.4rem;
}

.md-header__nav-link {
  color: var(--md-primary-bg-color);
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  padding: 0 0.4rem;
  opacity: 0.7;
  text-decoration: none;
  transition: opacity 0.2s;
}

.md-header__nav-link:hover {
  opacity: 1;
}

.md-header__annotate-btn {
  background: none;
  border: 1px solid var(--md-primary-bg-color);
  border-radius: 0.2rem;
  cursor: pointer;
  line-height: 1;
}

.md-header__annotate-btn:disabled {
  opacity: 0.4;
  cursor: default;
}

/* Interactions timeline */
.interactions-timeline {
  margin-top: 3rem;
  padding-top: 1rem;
  border-top: 1px solid var(--md-default-fg-color--lightest);
}

.tl-list {
  list-style: none;
  padding: 0;
  margin: 0;
  position: relative;
}

.tl-list::before {
  content: "";
  position: absolute;
  left: 15px;
  top: 0;
  bottom: 0;
  width: 2px;
  background: var(--md-default-fg-color--lightest);
}

.tl-entry {
  position: relative;
  padding: 0.55rem 0.75rem 0.55rem 48px;
  margin-bottom: 0.15rem;
  border-radius: 6px;
}

.tl-entry::before {
  content: "";
  position: absolute;
  left: 7px;
  top: 0.85rem;
  width: 18px;
  height: 18px;
  border-radius: 50%;
  background: var(--md-default-fg-color--lighter);
  border: 2px solid var(--md-default-bg-color);
  box-shadow: 0 0 0 2px var(--md-default-fg-color--lighter);
  z-index: 1;
}

.tl-wm::before {
  background: var(--md-primary-fg-color);
  box-shadow: 0 0 0 2px var(--md-primary-fg-color);
}

.tl-hy::before {
  background: #d97706;
  box-shadow: 0 0 0 2px #d97706;
}

.tl-hy-reply::before {
  background: #fbbf24;
  box-shadow: 0 0 0 2px #fbbf24;
}

.tl-hy-reply {
  background: color-mix(in srgb, #fbbf24 6%, var(--md-default-bg-color));
}

.tl-meta {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  margin-bottom: 0.2rem;
}

.tl-time {
  font-size: 0.78rem;
  color: var(--md-default-fg-color--light);
}

.tl-badge {
  font-size: 0.62rem;
  font-weight: 700;
  padding: 0.1rem 0.3rem;
  border-radius: 3px;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.tl-badge-wm {
  background: color-mix(in srgb, var(--md-primary-fg-color) 12%, transparent);
  color: var(--md-primary-fg-color);
}

.tl-badge-hy {
  background: #fef3c7;
  color: #92400e;
}

.tl-body {
  display: flex;
  gap: 0.5rem;
  align-items: flex-start;
}

.tl-avatar {
  width: 26px;
  height: 26px;
  border-radius: 50%;
  object-fit: cover;
  flex-shrink: 0;
}

.tl-avatar-placeholder {
  width: 26px;
  height: 26px;
  border-radius: 50%;
  background: var(--md-default-fg-color--lightest);
  flex-shrink: 0;
  display: inline-block;
}

.tl-main {
  flex: 1;
  min-width: 0;
}

.tl-author {
  font-weight: 600;
  color: var(--md-default-fg-color);
  text-decoration: none;
}

.tl-wm .tl-author {
  color: var(--md-primary-fg-color);
}

.tl-action {
  color: var(--md-default-fg-color--light);
  font-size: 0.9em;
}

.tl-content {
  margin: 0.3rem 0 0;
  font-size: 0.9em;
  color: var(--md-default-fg-color--light);
  line-height: 1.5;
}

.tl-quote {
  margin: 0.4rem 0;
  padding: 0.3rem 0.6rem;
  background: color-mix(in srgb, #fbbf24 10%, var(--md-default-bg-color));
  border-left: 3px solid #fbbf24;
  font-style: italic;
  font-size: 0.88em;
  color: var(--md-default-fg-color--light);
}

.tl-cross-ref {
  font-size: 0.78rem;
  color: var(--md-default-fg-color--light);
  margin: 0 0 0.25rem;
  display: flex;
  align-items: center;
  gap: 0.25rem;
}

.tl-cross-icon {
  color: #d97706;
}

.tl-cross-link {
  color: #d97706;
  font-weight: 600;
  text-decoration: none;
}

.tl-cross-link:hover {
  text-decoration: underline;
}

@keyframes tl-target-flash {
  from { background: #fef08a; box-shadow: 0 0 0 3px #fbbf24; }
  to   { background: color-mix(in srgb, #fbbf24 8%, var(--md-default-bg-color)); box-shadow: 0 0 0 2px #fbbf24; }
}

.tl-entry:target {
  background: color-mix(in srgb, #fbbf24 8%, var(--md-default-bg-color));
  box-shadow: 0 0 0 2px #fbbf24;
  animation: tl-target-flash 1.4s ease-out;
}

.tl-thread-btn {
  display: inline-block;
  margin-top: 0.35rem;
  background: none;
  border: none;
  padding: 0;
  cursor: pointer;
  font-size: 0.75rem;
  color: var(--md-default-fg-color--light);
  text-decoration: underline dotted;
  text-underline-offset: 2px;
}

.tl-thread-btn:hover { color: var(--md-default-fg-color); }
.tl-thread-btn.is-active { color: #d97706; }

.tl-entry.tl-thread-active {
  background: color-mix(in srgb, var(--md-primary-fg-color) 8%, var(--md-default-bg-color));
  box-shadow: inset 3px 0 0 var(--md-primary-fg-color);
}

.tl-hy.tl-thread-active,
.tl-hy-reply.tl-thread-active {
  background: color-mix(in srgb, #fbbf24 12%, var(--md-default-bg-color));
  box-shadow: inset 3px 0 0 #d97706;
}

/* No interactions prompt */
.no-interactions {
  margin-top: 3rem;
  padding: 1.5rem;
  border: 1px dashed var(--md-default-fg-color--lighter);
  border-radius: 8px;
  background: var(--md-default-fg-color--lightest);
  text-align: center;
}

.no-interactions p {
  margin: 0;
  font-size: 0.9em;
  color: var(--md-default-fg-color--light);
  line-height: 1.6;
}
