/* Swansea Hackspace task plugin — theme-matched styles.
   Sits inside #wikitext (skin: 20150821) — plain, no framework. */

/* ---------- task list ---------- */
.tasks-wrap {
  margin: 0.4em 0 1em;
  font-family: sans-serif;
  font-size: 10pt;
}
.tasks-wrap h3.tasks-group {
  font-size: 1.0em;
  font-weight: bold;
  margin: 1.1em 0 0.3em;
  padding: 0;
}
.tasks-wrap h3.tasks-group .tasks-count {
  font-weight: normal;
  font-size: 0.85em;
  color: #808080;
  margin-left: 0.3em;
}
.tasks-toolbar {
  margin: 0.4em 0 0.6em;
  font-size: 0.9em;
  color: #505050;
}
.tasks-toolbar .tasks-sortbtn {
  font: inherit;
  background: #fff;
  border: 1px solid #ccc;
  border-radius: 3px;
  padding: 2px 9px;
  margin: 0 3px 2px 0;
  cursor: pointer;
  color: #333;
}
.tasks-toolbar .tasks-sortbtn:hover { border-color: #888; }
.tasks-toolbar .tasks-sortbtn.tasks-active {
  background: #333; color: #fff; border-color: #333;
}

/* the tables */
.tasks-table {
  width: 100%;
  border-collapse: collapse;
  margin: 0 0 0.8em;
  line-height: 1.35;
}
.tasks-table th {
  text-align: left;
  font-size: 0.88em;
  color: #606060;
  padding: 4px 8px;
  border-bottom: 2px solid #ddd;
  white-space: nowrap;
  user-select: none;
}
.tasks-table th.sortable { cursor: pointer; }
.tasks-table th.sortable:hover { color: #000; }
.tasks-table th.t-asc:after  { content: " \25B2"; font-size: 0.8em; }
.tasks-table th.t-desc:after { content: " \25BC"; font-size: 0.8em; }
.tasks-table td {
  padding: 5px 8px;
  border-bottom: 1px solid #eee;
  vertical-align: top;
}
.tasks-table tbody tr:hover td { background: #f6f6f6; }
.tasks-table td.t-id { white-space: nowrap; color: #808080; }
.tasks-table td.t-id a { color: #808080; text-decoration: none; }
.tasks-table td.t-title a.tasks-title { font-weight: normal; }
.tasks-table td.t-due, .tasks-table td.t-updated, .tasks-table td.t-pri,
.tasks-table td.t-assignee { white-space: nowrap; }
.tasks-table .t-dash { color: #bbb; }
.tasks-recur { color: #707070; font-size: 0.9em; }
.t-unclaimed { color: #b00; font-style: italic; }

/* status / priority pills */
.tasks-pill {
  display: inline-block;
  border-radius: 9px;
  padding: 1px 8px;
  font-size: 0.85em;
  white-space: nowrap;
}
.tasks-pill.st-new, .tasks-pill.st-done, .tasks-pill.st-cancelled
  { background: #eee; color: #555; }
.tasks-pill.st-inprogress { background: #dcedc8; color: #33691e; }
.tasks-pill.st-onhold, .tasks-pill.st-waiting, .tasks-pill.st-needsdecision
  { background: #fff3cd; color: #7a5d00; }
.tasks-pill.pri-high { background: #f8d7da; color: #842029; }
.tasks-pill.pri-low  { background: #eef; color: #448; }
.tasks-pill.pri-normal { background: none; color: #999; padding: 1px 0; }
.tasks-pill.tasks-overdue, .tasks-tag-overdue {
  background: #b00; color: #fff;
}
.tasks-tag { display: block; font-size: 0.85em; color: #888; margin-top: 1px; }

/* summary (compact) view — stat line, never a second task list */
.tasks-summary {
  margin: 0.5em 0;
  font-size: 0.9em;
}
.tasks-summary .tasks-sum-title {
  font-weight: bold;
  margin-right: 0.5em;
}
.tasks-pill.tasks-sum { background: #eee; color: #555; margin: 0 2px; }
.tasks-pill.tasks-sum.tasks-overdue { background: #b00; color: #fff; }
.tasks-pill.tasks-sum b { font-weight: bold; }

/* notes / errors */
.tasks-note { font-size: 0.9em; color: #707070; font-style: italic; }
.tasks-error {
  border: 1px solid #b00; background: #fff0f0;
  color: #900; padding: 6px 10px; margin: 0.5em 0;
}
.tasks-desc { color: #404040; }

/* future group toggle */
.tasks-future-collapsed { margin: 0.2em 0 0.8em; }
.tasks-future-collapsed a { color: #4a6fb5; }

/* ---------- detail page ---------- */
.tasks-detail { font-family: sans-serif; font-size: 10pt; margin-top: 0.3em; }
.tasks-detail .td-head {
  border-bottom: 2px solid #333;
  padding-bottom: 6px; margin-bottom: 0.5em;
}
.tasks-detail .td-id { color: #909090; }
.tasks-detail h2 { margin: 0; font-size: 1.4em; display: inline; }

/* clickable field boxes */
.td-fields {
  display: flex; flex-wrap: wrap; gap: 8px;
  margin: 0.4em 0 0.9em;
}
.td-field {
  border: 1px solid #ddd; border-radius: 4px;
  background: #fafafa;
  padding: 4px 10px; min-width: 90px;
}
.td-field.td-editable { cursor: pointer; }
.td-field.td-editable:hover { border-color: #888; background: #f0f4fa; }
.td-field.td-editable:hover:after { content: " \270E"; color: #4a6fb5; }
.td-flabel {
  display: block; font-size: 0.78em; color: #909090;
  text-transform: uppercase; letter-spacing: 0.04em;
}
.td-fvalue { display: block; margin-top: 1px; }
.td-sub { color: #a0a0a0; font-size: 0.85em; }
.td-title.td-editable { cursor: pointer; }
.td-title.td-editable:hover { color: #4a6fb5; }
.td-title.td-editable:hover:after { content: " \270E"; font-size: 0.6em; color: #4a6fb5; }
.td-descbox {
  background: #f2f2f2;
  border: 1px solid #e4e4e4; border-radius: 4px;
  padding: 8px 12px; margin: 0.2em 0 1em;
}
.td-descbox.td-editable { cursor: pointer; }
.td-descbox.td-editable:hover { border-color: #bbb; background: #eceff4; }
.td-descbox.td-editable:hover:after { content: " \270E"; color: #4a6fb5; }

/* dependencies block */
.td-deps { list-style: none; margin: 0.2em 0 0.5em; padding: 0; }
.td-deps li {
  border: 1px solid #e4e4e4; border-radius: 4px;
  background: #fafafa;
  margin: 0 0 4px; padding: 4px 10px;
}
.td-depid { color: #909090; }
.td-depdel {
  font: inherit; font-size: 0.95em; line-height: 1;
  background: none; border: 1px solid #ddd; border-radius: 3px;
  color: #a02c2c; cursor: pointer; padding: 1px 6px;
  margin-left: 6px; float: right;
}
.td-depdel:hover { background: #a02c2c; color: #fff; border-color: #a02c2c; }
.td-depadd {
  font: inherit; font-size: 0.9em;
  background: #fff; border: 1px solid #ccc; border-radius: 3px;
  padding: 3px 10px; cursor: pointer; color: #333;
}
.td-depadd:hover { border-color: #888; }
.td-depaddbox .td-deperr { margin-left: 8px; }

/* history expand */
.td-histtoggle {
  font: inherit; font-size: 0.85em;
  background: none; border: 1px solid #ccc; border-radius: 3px;
  padding: 2px 10px; cursor: pointer; color: #555;
}
.td-histtoggle:hover { border-color: #888; }

/* inline editor */
.te-editor { margin-top: 4px; }
.te-input {
  font: inherit; font-size: 0.95em;
  border: 1px solid #bbb; border-radius: 3px;
  padding: 3px 6px; background: #fff;
  max-width: 100%;
}
.te-textarea { width: 96%; font-family: sans-serif; }
.te-reasonwrap { margin-top: 6px; }
.te-rlabel { font-size: 0.85em; color: #606060; }
.te-rnote { font-size: 0.8em; color: #909090; font-style: italic; margin-top: 2px; }
.te-error { color: #b00; font-size: 0.9em; margin-top: 4px; min-height: 1em; }
.te-save { margin: 6px 6px 0 0; }
.te-cancel {
  font: inherit; font-size: 0.9em;
  background: none; border: 1px solid #ccc; border-radius: 3px;
  padding: 4px 10px; margin-top: 6px; cursor: pointer; color: #555;
}
.te-cancel:hover { border-color: #888; }

.td-grid { display: flex; flex-wrap: wrap; gap: 1.2em; }
.td-main { flex: 1 1 420px; min-width: 300px; }
.td-side { flex: 0 0 250px; max-width: 250px; }
.td-side .td-card {
  border: 1px solid #ddd; border-radius: 4px;
  padding: 8px 12px; margin-bottom: 0.9em;
  background: #fafafa;
}
.td-side h3 {
  margin: 0 0 0.4em; font-size: 0.95em; color: #505050;
  border-bottom: 1px solid #ddd; padding-bottom: 3px;
}
.td-side dl { margin: 0; font-size: 0.9em; overflow: hidden; }
.td-side dt {
  float: left; clear: left; width: 82px;
  color: #808080; font-weight: normal; padding: 2px 0;
}
.td-side dd { margin: 0 0 0 90px; padding: 2px 0; }
.td-side .td-history { font-size: 0.85em; color: #777; margin: 0.3em 0 0; }
.td-side .td-history li { margin-bottom: 2px; }
.tasks-detail .td-desc { margin-bottom: 1em; }
.tasks-detail h3 { font-size: 1.05em; margin: 1em 0 0.35em; }

/* forms */
.tasks-form { margin: 0.4em 0 0.9em; }
.tasks-form input[type=text], .tasks-form select, .tasks-form textarea {
  font: inherit; font-size: 0.95em;
  border: 1px solid #bbb; border-radius: 3px;
  padding: 3px 6px; background: #fff;
}
.tasks-form textarea { width: 96%; }
.tasks-btn {
  font: inherit; font-size: 0.9em;
  background: #333; color: #fff; border: none; border-radius: 3px;
  padding: 4px 14px; cursor: pointer;
}
.tasks-btn:hover { background: #555; }
a.tasks-btn { text-decoration: none; display: inline-block; }
.tasks-create { margin: 0.6em 0 0.2em; }
.tasks-btn.tasks-btn-danger { background: #a02c2c; }
.tasks-btn.tasks-btn-danger:hover { background: #c33; }
/* "Assign to me" quick button inside the assignee editor */
.te-me {
  font: inherit; font-size: 0.9em;
  background: #333; color: #fff; border: none; border-radius: 3px;
  padding: 4px 12px; cursor: pointer; margin: 6px 0 0 6px;
}
.te-me:hover { background: #555; }

/* comments */
.tasks-comments { list-style: none; margin: 0.4em 0 0.7em; padding: 0; }
.tasks-comments li {
  border-left: 3px solid #ddd;
  margin: 0 0 0.6em; padding: 2px 0 2px 10px;
}
.tasks-comments .tasks-when { color: #999; font-size: 0.85em; }
.tasks-comments b { font-weight: bold; }

/* create-task form */
.tasks-newform { max-width: 680px; margin-top: 0.3em; }
.tasks-newform h2 { margin-bottom: 0.6em; }
.tasks-frow { margin: 0.6em 0; }
.tasks-frow .td-flabel {
  display: block; margin-bottom: 3px;
  font-size: 0.78em; color: #909090;
  text-transform: uppercase; letter-spacing: 0.04em;
}
.tasks-descedit {
  font: inherit; font-size: 0.95em;
  width: 96%;
  background: #f2f2f2; border: 1px solid #e4e4e4; border-radius: 4px;
  padding: 8px 10px;
}
.tasks-descedit:focus { background: #fff; border-color: #aaa; }
.tasks-newform select[multiple] { vertical-align: top; }
.tasks-cancel {
  font-size: 0.9em; color: #555;
  border: 1px solid #ccc; border-radius: 3px;
  padding: 4px 10px; text-decoration: none; margin-left: 4px;
}
.tasks-cancel:hover { border-color: #888; }

/* deps + archive + admin-perm tables */
.tasks-deptable, .tasks-archive-table, .tasks-permtbl {
  border-collapse: collapse; margin: 0.3em 0 0.9em; font-size: 0.95em;
}
.tasks-deptable th, .tasks-deptable td,
.tasks-archive-table th, .tasks-archive-table td,
.tasks-permtbl th, .tasks-permtbl td {
  border: 1px solid #ddd; padding: 4px 8px; text-align: left;
}
.tasks-deptable th, .tasks-archive-table th, .tasks-permtbl th
  { background: #f4f4f4; }

/* tree view stays a nested list */
.tasks-tree { margin: 0.3em 0 0.8em; }
.tasks-tree li { margin: 3px 0; }

/* print */
@media print {
  .tasks-toolbar { display: none; }
  .tasks-table tbody tr:hover td { background: none; }
}