/* 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/. */

/* ==== communicator.css ====================================================
   == Styles shared everywhere throughout the Communicator suite.
   ========================================================================== */

@import url("chrome://global/skin/");
@import url("chrome://communicator/content/communicator.css");
@import url("chrome://communicator/skin/brand.css");
@import url("chrome://communicator/skin/button.css");
@import url("chrome://communicator/skin/toolbar.css");

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

#titlebar:not(:-moz-lwtheme) {
  display: none;
}

#titlebar {
  height: 22px;
  -moz-window-dragging: drag;
}

#titlebar-spacer {
  pointer-events: none;
}

/* On OS X, window controls are always at the left side of the window */
#titlebar-buttonbox-container:-moz-locale-dir(ltr) {
  -moz-box-ordinal-group: 0;
  -moz-box-align: start;
}

#titlebar-buttonbox-container:-moz-lwtheme {
  margin-top: 3px;
}

#titlebar-buttonbox {
  -moz-appearance: -moz-window-button-box;
  margin-left: 7px;
}

/* ::::: toolbar-primary ::::: */

.toolbar-primary {
  -moz-binding: url("chrome://communicator/content/bindings/toolbar.xml#grippytoolbar-primary");
}

/* ::::: grippies ::::: */

grippy {
  display: none;
}

/* ::::: autocomplete ::::: */

.autocomplete-history-popup {
  max-height: 285px; /* 15 rows */
}

/* ::::: online/offline icons ::::: */

#offline-status[offline="true"] {
  list-style-image: url("chrome://communicator/skin/icons/offline.png");
}

#offline-status {
  list-style-image: url("chrome://communicator/skin/icons/online.png");
}

/* ::::: spell checker ::::: */

.spell-suggestion {
  font-weight: bold;
}

/* ::::: error messages ::::: */

description.error {
  color: #FF0000;
}

/* ::::: directional button icons ::::: */

.up {
  min-width: 0px;
  list-style-image: url("chrome://global/skin/arrow/arrow-up.gif");
}

.up[disabled="true"] {
  list-style-image: url("chrome://global/skin/arrow/arrow-up-dis.gif");
}

.down {
  min-width: 0px;
  list-style-image: url("chrome://global/skin/arrow/arrow-dn.gif");
}

.down[disabled="true"] {
  list-style-image: url("chrome://global/skin/arrow/arrow-dn-dis.gif");
}

.sidebarTree {
  border: none;
  margin: 0px !important;
}

/* ::::: toolbar print button ::::: */
#print-button {
 list-style-image: url("chrome://communicator/skin/icons/communicatoricons.png");
  -moz-image-region: rect(0 29px 29px 0);
}

#print-button:hover:active,
#print-button[open] {
  -moz-image-region: rect(0 59px 29px 30px);
}

#print-button[disabled="true"] {
  -moz-image-region: rect(0 89px 29px 60px) !important;
}

toolbar[iconsize="small"] > toolbarpaletteitem > #print-button,
toolbar[iconsize="small"] > #print-button {
  list-style-image: url("chrome://communicator/skin/icons/communicatoricons-small.png");
  -moz-image-region: rect(0 19px 19px 0);
}

toolbar[iconsize="small"] > #print-button:hover:active,
toolbar[iconsize="small"] > #print-button[open] {
  -moz-image-region: rect(0 39px 19px 20px);
}

toolbar[iconsize="small"] > #print-button[disabled="true"] {
  -moz-image-region: rect(0 59px 19px 40px) !important;
}

/* ::::: lightweight themes ::::: */

toolbar textbox:-moz-lwtheme:not([focused="true"]) {
  opacity: 0.9;
}

treecols:-moz-lwtheme {
  text-shadow: none;
}

/* ::::: notification bars ::::: */

.messageImage[value="refresh-blocked"] {
  list-style-image: url("chrome://communicator/skin/icons/application.png");
}

.messageImage[value="blocked-plugins"],
.messageImage[value="carbon-failure-plugins"],
.messageImage[value="disabled-plugins"],
.messageImage[value="missing-plugins"],
.messageImage[value="outdated-plugins"],
.messageImage[value="click-to-play-plugins"],
.messageImage[value="plugin-crashed"] {
  list-style-image: url("chrome://mozapps/skin/plugins/pluginGeneric-16.png");
}

.messageImage[value="geolocation"] {
  list-style-image: url("chrome://communicator/skin/icons/geo.png");
}

.messageImage[value="webNotifications"] {
  list-style-image: url("chrome://communicator/skin/icons/notification-16.png");
}

.messageImage[value="indexedDB-permissions-prompt"],
.messageImage[value="indexedDB-quota-prompt"] {
  list-style-image: url("chrome://global/skin/icons/question-16.png");
}

.messageImage[value="addon-install-blocked"],
.messageImage[value="addon-install-cancelled"],
.messageImage[value="addon-install-complete"],
.messageImage[value="addon-install-disabled"],
.messageImage[value="addon-install-failed"],
.messageImage[value="addon-install-started"],
.messageImage[value="lwtheme-install-request"],
.messageImage[value="lwtheme-install-notification"] {
  list-style-image: url("chrome://mozapps/skin/extensions/extensionGeneric-16.png");
}

.messageImage[value="popup-blocked"] {
  list-style-image: url("chrome://navigator/skin/icons/popup-blocked.png");
}

.messageImage[value="blocked-badware-page"] {
  list-style-image: url("chrome://global/skin/icons/blacklist_favicon.png");
}
