/* This Source Code Form is subject to the terms of the Mozilla Public
 * License, v. 2.0. If a copy of the MPL was not distributed with this
 * file, You can obtain one at http://mozilla.org/MPL/2.0/. */

@import url(chrome://calendar/skin/shared/calendar-task-tree.css);

.calendar-task-tree-col-priority > .treecol-icon {
  padding-inline-end: 1px;
}

/* Use on Win7 and up default theme a dark text color when selected focus */
@media (-moz-windows-default-theme) {
  .calendar-task-tree > treechildren::-moz-tree-row(inprogress, selected, focus) {
    border-color: green !important;
  }

  :root[lwt-tree-brighttext] .calendar-task-tree > treechildren::-moz-tree-row(inprogress, selected, focus) {
    border-color: #00bd00 !important;
  }

  .calendar-task-tree > treechildren::-moz-tree-cell-text(inprogress, selected, focus),
  :root[lwt-tree-brighttext] .calendar-task-tree > treechildren::-moz-tree-cell-text(inprogress, selected, focus) {
    color: white !important;
  }

  .calendar-task-tree > treechildren::-moz-tree-row(overdue, selected, focus) {
    border-color: red !important;
  }

  :root[lwt-tree-brighttext] .calendar-task-tree > treechildren::-moz-tree-row(overdue, selected, focus) {
    border-color: #ff7a7a !important;
  }

  .calendar-task-tree > treechildren::-moz-tree-image(overdue, selected, focus),
  .calendar-task-tree > treechildren::-moz-tree-cell-text(overdue, selected, focus),
  :root[lwt-tree-brighttext] .calendar-task-tree > treechildren::-moz-tree-cell-text(overdue, selected, focus) {
    color: white !important;
  }

  @media (-moz-platform: windows-win7) {
    .calendar-task-tree > treechildren::-moz-tree-row(inprogress, selected, focus) {
      background: linear-gradient(rgba(0, 128, 0, .28), rgba(0, 128, 0, .5));
    }

    .calendar-task-tree > treechildren::-moz-tree-row(overdue, selected, focus) {
      background: linear-gradient(rgba(255, 0, 0, .28), rgba(255, 0, 0, .5));
    }
  }

  @media (-moz-platform: windows-win8),
         (-moz-platform: windows-win10) {
    .calendar-task-tree > treechildren::-moz-tree-row(inprogress, selected, focus) {
      background: linear-gradient(rgba(0, 128, 0, .5), rgba(0, 128, 0, .5));
    }

    .calendar-task-tree > treechildren::-moz-tree-row(overdue, selected, focus) {
      background: linear-gradient(rgba(255, 0, 0, .5), rgba(255, 0, 0, .5));
    }
  }
}
