/*
# ***** BEGIN LICENSE BLOCK *****
# Version: MPL 1.1/GPL 2.0/LGPL 2.1
#
# The contents of this file are subject to the Mozilla Public License Version
# 1.1 (the "License"); you may not use this file except in compliance with
# the License. You may obtain a copy of the License at
# http://www.mozilla.org/MPL/
#
# Software distributed under the License is distributed on an "AS IS" basis,
# WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
# for the specific language governing rights and limitations under the
# License.
#
# The Original Code is Mozilla Communicator client code, released
# March 31, 1998.
#
# The Initial Developer of the Original Code is
# Netscape Communications Corporation.
# Portions created by the Initial Developer are Copyright (C) 1998-1999
# the Initial Developer. All Rights Reserved.
#
# Contributor(s):
#
# Alternatively, the contents of this file may be used under the terms of
# either the GNU General Public License Version 2 or later (the "GPL"), or
# the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
# in which case the provisions of the GPL or the LGPL are applicable instead
# of those above. If you wish to allow use of your version of this file only
# under the terms of either the GPL or the LGPL, and not to allow others to
# use your version of this file under the terms of the MPL, indicate your
# decision by deleting the provisions above and replace them with the notice
# and other provisions required by the GPL or the LGPL. If you do not delete
# the provisions above, a recipient may use your version of this file under
# the terms of any one of the MPL, the GPL or the LGPL.
#
# ***** END LICENSE BLOCK *****
*/

/* ===== mailWindow1.css ================================================
  == Styles for the main Mail window in the default layout scheme.
  ======================================================================= */

@import url("chrome://messenger/skin/");
@import url("chrome://messenger/skin/primaryToolbar.css");
@import url("chrome://global/skin/toolbar.css");
@import url("chrome://messenger/skin/folderMenus.css");
@import url("chrome://messenger/skin/folderPane.css");
@import url("chrome://messenger/skin/tagColors.css");

@namespace url("http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul");

/* Don't use the listbox appearance as that gives us a blue-grey top border
   that collides with the primary toolbar border */
#threadTree, #folderTree {
  -moz-appearance:  none;
  background-color: -moz-Field;
  color: -moz-FieldText;
  -moz-border-left-colors: ThreeDShadow ThreeDDarkShadow;
  -moz-border-bottom-colors: ThreeDHighlight ThreeDLightShadow;
  -moz-border-right-colors: ThreeDHighlight ThreeDLightShadow;
  border-left: 1px solid;
  border-right: 1px solid;
  border-bottom: 1px solid;
}

#mailContent {
  -moz-appearance: toolbox;
  background-color: -moz-Dialog;
}

#folderUnreadCol,
#folderTotalCol,
#folderSizeCol {
  text-align: right;
}

#folderNameCol [sortDirection="ascending"],
#folderNameCol [sortDirection="descending"] {
  list-style-image: none;
}

/* ::::: thread decoration ::::: */

treechildren::-moz-tree-row(dummy)  {
  background-color:  #F0F0F0;
  margin-bottom: 1px;
  -moz-padding-start: 2px;
}

treechildren::-moz-tree-row(dummy, selected) {
  background-color: -moz-Dialog;
}

treechildren::-moz-tree-row(dummy, selected, focus)  {
  background-color: Highlight;
}

treechildren::-moz-tree-cell-text(dummy) {
  font-weight: bold;
}

treechildren::-moz-tree-cell-text(read) {
  font-weight: normal;
}

treechildren::-moz-tree-cell-text(unread) {
  font-weight: bold;
}

treechildren::-moz-tree-cell-text(imapdeleted) {
  text-decoration: line-through;
}

/* on a collapsed thread, if the top level message is read, but the thread has
 * unread children, underline the text.  4.x mac did this, very slick 
 */
treechildren::-moz-tree-cell-text(container, closed, hasUnread, read) {
  text-decoration: underline;
}

/* ::::: message column icons ::::: */

/* ..... thread column ..... */

treecol.threadColumnHeader {
  list-style-image: url("chrome://messenger/skin/icons/thread-col.png");
  -moz-padding-end: 3px; 
}

/*
treecol.threadColumnHeader[sortDirection="ascending"]  {
  list-style-image: url("chrome://messenger/skin/icons/thread-col-sorta.png");
}

treecol.threadColumnHeader[sortDirection="descending"] {
  list-style-image: url("chrome://messenger/skin/icons/thread-col-sortd.png");
}
*/

treechildren::-moz-tree-image(threadCol, container) {
  list-style-image: url("chrome://messenger/skin/icons/thread.png");
}

treechildren::-moz-tree-image(news, threadCol, watch) {
  list-style-image: url("chrome://messenger/skin/icons/thread-watched.png");
}

treechildren::-moz-tree-image(news, threadCol, ignore) {
  list-style-image: url("chrome://messenger/skin/icons/thread-ignored.png");
}

/* ..... read column ..... */

treecol.readColumnHeader {
  list-style-image: url("chrome://messenger/skin/icons/readcol.png");
  -moz-padding-end: 5px;
  padding-bottom: 5px;
}

treechildren::-moz-tree-image(unreadButtonColHeader) {
  list-style-image: url("chrome://messenger/skin/icons/readmail.png");
}

treechildren::-moz-tree-image(unreadButtonColHeader, dummy) {
  list-style-image: none;
}

treechildren::-moz-tree-image(unreadButtonColHeader, unread) {
  list-style-image: url("chrome://messenger/skin/icons/unreadmail.png");
}

/* ..... attachment column ..... */

treecol.attachmentColumnHeader {
  list-style-image: url("chrome://messenger/skin/icons/attachment-col.png");
  -moz-padding-end: 5px; 
}

treechildren::-moz-tree-image(attachmentCol, attach) {
  list-style-image: url("chrome://messenger/skin/icons/attachment.png");
}

/* ..... flag column ..... */

treecol.flagColumnHeader {
  list-style-image: url("chrome://messenger/skin/icons/flag-col.png");
  -moz-padding-end: 5px; 
}

treechildren::-moz-tree-image(flaggedCol) {
  list-style-image: url("chrome://messenger/skin/icons/readmail.png");
}

treechildren::-moz-tree-image(flaggedCol, dummy) {
  list-style-image: none;
}

treechildren::-moz-tree-image(flaggedCol, flagged) {
  list-style-image: url("chrome://messenger/skin/icons/flag.png");
}

/* ..... junkStatus column ..... */

treecol.junkStatusHeader {
  list-style-image: url("chrome://messenger/skin/icons/junk-col.png");
  -moz-padding-end: 5px; 
}

/* "unknown" now looks like "not junk".  see bug #182386 */
treechildren::-moz-tree-image(junkStatusCol) {
  list-style-image: url("chrome://messenger/skin/icons/readmail.png");
  -moz-padding-start: 0px;
}

treechildren::-moz-tree-image(junkStatusCol, junk) {
  list-style-image: url("chrome://messenger/skin/icons/folder.png");
  -moz-image-region: rect(0 128px 16px 112px);
}

treechildren::-moz-tree-image(junkStatusCol, dummy) {
  list-style-image: none;
}

treechildren::-moz-tree-image(junkStatusCol, notjunk) {
  list-style-image: url("chrome://messenger/skin/icons/readmail.png");
  -moz-padding-start: 0px;
}
/* ..... subject column ..... */

treechildren::-moz-tree-image(subjectCol) {
  -moz-margin-end: 2px;
  list-style-image: url("chrome://messenger/skin/icons/message.png");
  -moz-image-region: rect(0 16px 16px 0);
}

treechildren::-moz-tree-image(subjectCol, dummy) {
  list-style-image: none;
}

treechildren::-moz-tree-image(subjectCol, forwarded) {
  -moz-image-region: rect(0 48px 16px 32px);
}

treechildren::-moz-tree-image(subjectCol, replied) {
  -moz-image-region: rect(0 32px 16px 16px);
}

treechildren::-moz-tree-image(subjectCol, replied, forwarded) {
  -moz-image-region: rect(0 64px 16px 48px);
}

treechildren::-moz-tree-image(subjectCol, new) {
  -moz-image-region: rect(0 96px 16px 80px);
}


/* IMPORTANT: make sure the imap-deleted column always comes after the replied/forwarded style rules.
   This ensures that we show that the message is marked as deleted over status information. */

treechildren::-moz-tree-image(subjectCol, imapdeleted) {
  -moz-image-region: rect(0 80px 16px 64px);
}


#sizeCol,
#unreadCol,
#totalCol {
  text-align: right;
}

/* :::::
   :: Make sure the min height is small so we can
   :: resize the pane vertically -EDV
   ::::: */

#messagepanebox {
  min-height: 10px;
  height: 0px;
}

/* ..... folder pane adjustments ..... */

#folderpane-title {
  padding-left: 12px;
  padding-right: 8px;
}

.folderview-cycler {
  -moz-padding-end: 0px !important;
}

#folderview-cycler-left {
  list-style-image: url("chrome://global/skin/arrow/arrow-lft.gif");
}

#folderview-cycler-right {
  list-style-image: url("chrome://global/skin/arrow/arrow-rit.gif");
}

/* ..... splitter adjustments ..... */

#folderpane_splitter {
  border-right: none;
}

#gray_vertical_splitter,
#threadpane-splitter {
  border: none;
  min-height: 5px;
}

/* ..... tree adjustments ..... */

#accountCentralBox { 
  border: 1px solid ThreeDShadow; 
}

/* ..... message pane adjustments ..... */

#messagepanebox {
  border-top: 1px solid ThreeDShadow;
  border-left: 1px solid ThreeDShadow;
  border-right: 0px;
  border-bottom: 0px;
}

/* ..... status bar adjustments ..... */

#quotaMeter {
  min-width: 4em;
  max-width: 4em;
}
#quotaPanel[alert="warning"] .progress-bar {
  background-color: orange;
  -moz-appearance: none;
}
#quotaPanel[alert="critical"] .progress-bar {
  background-color: red;
  -moz-appearance: none;
}
#quotaLabel {
  text-align: center;
}

/* ..... update notifications ..... */

#checkForUpdates[loading="true"] {
  list-style-image: url("chrome://global/skin/throbber/Throbber-small.gif");
}


#threadTree treechildren::-moz-tree-row(odd) {
  background-image: url("chrome://messenger/skin/icons/row.png");
  background-position: bottom;
  background-repeat: repeat-x;
}
