/* Ecotone Tasks — custom overrides (client feedback, Franziska Schreiner).
   Linked from index.html. Re-apply after any frontend rebuild. */

/* === Cap preview/cover image height so one image can't fill the screen === */
.attachments img,
.task-detail img,
img.attachment-image {
    max-height: 300px !important;
    width: auto !important;
    object-fit: contain !important;
}
.kanban .task img {
    max-height: 130px !important;
    object-fit: cover !important;
}

/* === Fade / grey-out completed tasks (confirmed class: .task.done / .done) === */
.task.done,
.tasks .task.done {
    opacity: 0.5 !important;
    filter: grayscale(60%) !important;
}
.task.done .tasktext,
.task.done a {
    text-decoration: line-through !important;
    color: #909090 !important;
}
.kanban .task.done {
    opacity: 0.55 !important;
}

/* === Franziska: attachments newest-first (she has tasks with 20+ attachments) === */
/* Vikunja renders attachments oldest-first inside .attachments > .files;
   reverse the flex order so the newest upload is at the top. */
.attachments .files {
    display: flex !important;
    flex-direction: column-reverse !important;
}
