from pathlib import Path

path = Path(r'd:\kreuzberg\pipeline_claim\styles.css')
text = path.read_text(encoding='utf-8', errors='replace')

if '.doc-open-file' not in text:
    text += '''

.doc-open-file {
  margin-left: 8px;
  background: #0f3a63;
  border: 1px solid #0f3a63;
  color: #ffffff;
  font-size: 0.82rem;
  padding: 6px 10px;
  border-radius: 8px;
  text-decoration: none;
}

.doc-open-file:hover {
  background: #0c2f51;
}
'''
    path.write_text(text, encoding='utf-8')
    print('added doc-open-file styles')
else:
    print('doc-open-file styles already present')
