.detail-header {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  align-items: flex-start;
  margin-bottom: 16px;
}

.status-pill {
  background: #111;
  color: #f3c300;
  padding: 8px 12px;
  border-radius: 999px;
  font-weight: 700;
  white-space: nowrap;
}

.detail-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px 24px;
}

.content-stack {
  display: grid;
  gap: 18px;
  flex: 1;
}

.thread-list {
  display: grid;
  gap: 12px;
  margin-bottom: 18px;
}

.thread-item {
  border: 1px solid #e5e5e5;
  border-radius: 12px;
  padding: 14px;
  background: #fff;
}

.thread-item.user {
  background: #fafafa;
}

.thread-item.technician,
.thread-item.admin {
  background: #fffdf5;
}

.thread-item.internal {
  background: #f8f6ff;
  border-color: #d9d1ff;
}

.thread-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  font-size: 0.92rem;
  margin-bottom: 8px;
  color: #555;
}

.thread-body {
  line-height: 1.5;
}

.stack-form {
  margin-top: 16px;
}

.attachment-list,
.history-list {
  margin: 10px 0 0 18px;
}

.alert-success {
  background: #ecfdf3;
  color: #067647;
  border: 1px solid #abefc6;
  padding: 12px;
  border-radius: 8px;
  margin-bottom: 16px;
}

@media (max-width: 900px) {
  .detail-grid {
    grid-template-columns: 1fr;
  }

  .detail-header {
    flex-direction: column;
  }
}
