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

/* Core */
calendar-category-box:not([categories]) {
  display: none;
}

.calendar-category-box-gradient {
    width: 7px;
    background-image: -moz-linear-gradient(top, rgba(255, 255, 255, 0.38), transparent) !important;
    border-left: 1px solid rgba(255, 255, 255, 0.38);
}

.calendar-item-image {
    list-style-image: url(chrome://calendar/skin/day-box-item-image.png);
    padding-top: 2px;
    padding-bottom: 2px;
    -moz-margin-end: 4px;
    display: none;
}

.calendar-item-image[itemType="todo"] {
    -moz-image-region: rect(0px 11px 11px 0px);
    display: -moz-box;
}

.calendar-item-image[itemType="todo"][progress="completed"] {
    -moz-image-region: rect(0px 22px 11px 11px);
}

/* Multiday view */

/* Margin that allows event creation by click and drag when the time slot is
   full of events. On the right side in normal view ... */
.multiday-column-box-stack > .multiday-column-top-box[orient="horizontal"] {
    -moz-margin-end: 5px;
}
/* ... and on bottom in rotate view. */
.multiday-column-box-stack > .multiday-column-top-box[orient="vertical"] {
    margin-bottom: 5px;
}

/* .. and on the right side in the header container in normal view */
calendar-header-container:not([rotated]) {
    padding-right: 6px;
    padding-left: 1px;
}
/* ... and on the bottom in rotated view. */
calendar-header-container[rotated] {
    padding-top: 1px;
    padding-bottom: 5px;
}

calendar-event-column {
    background-color: #FFFFFF;
}

window[systemcolors] calendar-event-column {
    background-color: -moz-Field;
}

calendar-event-column[orient="horizontal"] {
    border-top: 1px solid #D2D2D2;
}

window[systemcolors] calendar-event-column[orient="horizontal"] {
    border-top: 1px solid ThreeDShadow;
}

calendar-event-column[orient="vertical"] {
    border-left: 1px solid #D2D2D2;
}

window[systemcolors] calendar-event-column[orient="vertical"] {
    border-left: 1px solid ThreeDShadow;
}

calendar-event-column[orient="horizontal"][relation="today"] {
    border-top: 1px solid #67ACD8;
    border-bottom: 1px solid #67ACD8;
    margin-bottom: -1px;
    position: relative;
}

window[systemcolors] calendar-event-column[orient="horizontal"][relation="today"] {
    border-top: 1px solid Highlight;
    border-bottom: 1px solid Highlight;
}

calendar-event-column[orient="vertical"][relation="today"] {
    border-left: 1px solid #67ACD8;
    border-right: 1px solid #67ACD8;
    -moz-margin-end: -1px;
    position: relative;
}

window[systemcolors] calendar-event-column[orient="vertical"][relation="today"] {
    border-left: 1px solid Highlight;
    border-right: 1px solid Highlight;
}

calendar-header-container {
    background-color: #FFFFFF;
    border-left: 1px solid #D2D2D2;
}

window[systemcolors] calendar-header-container {
    background-color: -moz-Field;
    border-left: 1px solid ThreeDShadow;
}

calendar-header-container[rotated] {
    max-width: 150px;
}

calendar-header-container[weekend="true"],
.calendar-event-column-linebox[weekend="true"] {
    background-color: #F7FFE3;
}

.calendar-event-column-linebox[off-time="true"] {
    background-color: #F3F3F3;
}

.calendar-event-column-linebox[off-time="true"][weekend="true"] {
    background-color: #EAF7CA;
}

calendar-header-container[relation="today"],
.calendar-event-column-linebox[relation="today"],
calendar-day-label[orient][relation="today"] {
    background-color: #E1F0FD;
}

window[systemcolors] calendar-header-container[relation="today"],
window[systemcolors] .calendar-event-column-linebox[relation="today"],
window[systemcolors] calendar-day-label[orient][relation="today"] {
    background-color: -moz-Field;
}

window[systemcolors] calendar-header-container[weekend="true"],
window[systemcolors] .calendar-event-column-linebox[weekend="true"],
window[systemcolors] .calendar-event-column-linebox[off-time="true"] {
    background-color: rgba(0, 0, 0, .1);
}

calendar-header-container[relation="today"] {
    border-left: 1px solid #7FB9EE;
    border-right: 1px solid #7FB9EE;
    -moz-margin-end: -1px;
    position: relative;
}

window[systemcolors] calendar-header-container[relation="today"] {
    border-left: 1px solid Highlight;
    border-right: 1px solid Highlight;
}

calendar-header-container[relation="today"][rotated="true"] {
    border-top: 1px solid #7FB9EE;
    border-bottom: 1px solid #7FB9EE !important;
    border-right: 1px solid #D2D2D2;
    margin-top: -1px;
    position: relative;
}

window[systemcolors] calendar-header-container[relation="today"][rotated="true"] {
    border-top: 1px solid Highlight;
    border-bottom: 1px solid Highlight !important;
    border-right: 1px solid ThreeDShadow;
}

calendar-header-container[selected="true"],
.calendar-event-column-linebox[selected="true"] {
    background-color: #FFFCD8;
}

calendar-header-container[weekend="true"][relation="today"],
.calendar-event-column-linebox[weekend="true"][relation="today"] {
    background-color: #E1F0FD;
}

.calendar-event-column-linebox[off-time="true"][relation="today"] {
    background-color: #D7E8F8;
}

window[systemcolors] calendar-header-container[selected="true"],
window[systemcolors] .calendar-event-column-linebox[selected="true"],
window[systemcolors] calendar-header-container[weekend="true"][relation="today"],
window[systemcolors] .calendar-event-column-linebox[weekend="true"][relation="today"],
window[systemcolors] .calendar-event-column-linebox[off-time="true"][relation="today"],
window[systemcolors] calendar-header-container[weekend="true"][selected="true"],
window[systemcolors] .calendar-event-column-linebox[weekend="true"][selected="true"],
window[systemcolors] .calendar-event-column-linebox[off-time="true"][selected="true"] {
    background-color: ButtonFace;
}

.multiday-view-header-day-box[orient="vertical"] .calendar-event-column-header {
    border-bottom: 1px solid #D2D2D2;
    min-width: 100px;
}

window[systemcolors] .multiday-view-header-day-box[orient="vertical"] .calendar-event-column-header {
    border-bottom: 1px solid ThreeDShadow;
}

calendar-header-container[weekend="true"][selected="true"],
.calendar-event-column-linebox[weekend="true"][selected="true"] {
    background-color: #FFFCD8;
}

.calendar-event-column-linebox[off-time="true"][selected="true"] {
    background-color: #F2EDB2;
}

.calendar-event-column-linebox[orient="horizontal"] {
    border-right: 1px solid #D2D2D2;
}

window[systemcolors] .calendar-event-column-linebox[orient="horizontal"] {
    border-right: 1px solid ThreeDShadow;
}

.calendar-event-column-linebox[orient="vertical"] {
    border-bottom: 1px solid #D2D2D2;
}

window[systemcolors] .calendar-event-column-linebox[orient="vertical"] {
    border-bottom: 1px solid ThreeDShadow;
}

.calendar-event-column-linebox[orient="horizontal"][relation="today"]:last-child {
    border-right: 1px solid #67ACD8;
}

window[systemcolors] .calendar-event-column-linebox[orient="horizontal"][relation="today"]:last-child {
    border-right: 1px solid Highlight;
}

.calendar-event-column-linebox[orient="vertical"][relation="today"]:last-child {
    border-bottom: 1px solid #67ACD8;
}

window[systemcolors] .calendar-event-column-linebox[orient="vertical"][relation="today"]:last-child {
    border-bottom: 1px solid Highlight;
}

/* Make sure we extend the bold line separating scrollable and non-scrollable
   areas over the timebar. */
.multiday-view-header-time-spacer[orient="horizontal"] {
    border-bottom: 2px solid #D2D2D2;
    border-right: 2px solid #D2D2D2;
    -moz-border-right-colors: #FFFFFF #D2D2D2;
}

window[systemcolors] .multiday-view-header-time-spacer[orient="horizontal"] {
    border-bottom: 2px solid ThreeDShadow;
    border-right: 2px solid ThreeDShadow;
    -moz-border-right-colors: -moz-Field ThreeDShadow;
}

.multiday-view-header-time-spacer[orient="vertical"] {
    border-right: 2px solid #D2D2D2;
    -moz-border-right-colors: #D2D2D2 #D2D2D2;
}

window[systemcolors] .multiday-view-header-time-spacer[orient="vertical"] {
    border-right: 2px solid ThreeDShadow;
    -moz-border-right-colors: -moz-Field ThreeDShadow;
}

.multiday-view-label-box[orient="horizontal"] > .multiday-view-label-time-spacer {
    border-right: 2px solid #D2D2D2;
    -moz-border-right-colors: #FFFFFF #D2D2D2;
}

window[systemcolors] .multiday-view-label-box[orient="horizontal"] > .multiday-view-label-time-spacer {
    border-right: 2px solid ThreeDShadow;
    -moz-border-right-colors: -moz-Field ThreeDShadow;
}

.multiday-view-header-day-box[orient="horizontal"] {
    border-right: 1px solid #D2D2D2;
    border-bottom: 2px solid #D2D2D2;
    overflow-x: hidden;
    overflow-y: auto;
    max-height: 120px;
}

window[systemcolors] .multiday-view-header-day-box[orient="horizontal"] {
    border-right: 1px solid ThreeDShadow;
    border-bottom: 2px solid ThreeDShadow;
}

.multiday-view-header-day-box[orient="horizontal"][todaylastinview="true"] {
    border-right: 1px solid #67ACD8;
}

window[systemcolors] .multiday-view-header-day-box[orient="horizontal"][todaylastinview="true"] {
    border-right: 1px solid Highlight;
}

/* Make sure the box for day-labels appears to end before the scrollbar. */
.multiday-view-label-day-box[orient="horizontal"] {
    border-top: 1px solid #D2D2D2;
    border-right: 1px solid #D2D2D2;
}

window[systemcolors] .multiday-view-label-day-box[orient="horizontal"] {
    border-top: 1px solid ThreeDShadow;
    border-right: 1px solid ThreeDShadow;
}

.multiday-view-label-day-box[orient="vertical"] {
    border-top: 1px solid #D2D2D2;
}

window[systemcolors] .multiday-view-label-day-box[orient="vertical"] {
    border-top: 1px solid ThreeDShadow;
}

.multiday-view-header-day-box[orient="vertical"] {
    border-top: 1px solid #D2D2D2;
    border-right: 2px solid #D2D2D2;
}

window[systemcolors] .multiday-view-header-day-box[orient="vertical"] {
    border-top: 1px solid ThreeDShadow;
    border-right: 2px solid ThreeDShadow;
}

/* Make sure to have a border between the edge of the views and the scrollbar. */
.multiday-view-day-box {
    border-right: 1px solid #D2D2D2;
    border-bottom: 1px solid #D2D2D2;
}

window[systemcolors] .multiday-view-day-box {
    border-right: 1px solid ThreeDShadow;
    border-bottom: 1px solid ThreeDShadow;
}

.fgdragbox {
    -moz-box-orient: inherit;
    display: none;
}

.fgdragbox[dragging="true"] {
    display: -moz-box;
    background-image: -moz-linear-gradient(top, #fe4b22, #feb822);
    border: 5px #ffffff;
    opacity: 0.5;
}

window[systemcolors] .fgdragbox[dragging="true"] {
    background-image: -moz-linear-gradient(top, Highlight, Highlight);
    border: 5px -moz-Field;
}

.fgdragcontainer {
    -moz-box-orient: inherit;
    display: none;
}

.fgdragcontainer[dragging="true"] {
    display: -moz-box;
  /* This is a workaround for a stack bug and display: hidden in underlying
   * elements -- the display: hidden bits get misrendered as being on top.
   * Setting an opacity here forces a view to be created for this element, too.
   */
    opacity: 0.9999;
}

.fgdragbox-label {
    font-weight: bold;
    text-align: center;
    overflow: hidden;
}

window[systemcolors] .fgdragbox-label {
	color: GrayText;
}

.timeIndicator[orient="vertical"] {
    min-width: 1px;
    -moz-margin-start: -1px;
    -moz-margin-end: -1px;
    border-top: 2px solid red;
    opacity: 0.7;
}

.timeIndicator[orient="horizontal"] {
    min-height: 1px;
    margin-top: -1px;
    margin-bottom: -1px;
    border-left: 2px solid red;
    opacity: 0.7;
}

.timeIndicator-timeBar {
    background-color: red;
    position: absolute;
    border-radius: 2px;
}

.timeIndicator-timeBar[orient="vertical"] {
    margin-top: -1px;
    height: 4px;
    width: 8px;
    right: 0px;
}

.timeIndicator-timeBar[orient="horizontal"] {
    margin-left: -1px;
    height: 8px;
    width: 4px;
    bottom: 0px;
}

.calendar-event-box-container {
    padding: 0;
    overflow: hidden;
    margin: 1px;
}

.calendar-event-box-container[categories] {
    -moz-margin-end: 0px;
}

.calendar-event-details {
    -moz-padding-start: 2px;
    overflow: hidden;
}

.calendar-event-details-core {
    width: 0px;
    margin: 0px;
    overflow: hidden;
}

.calendar-event-name-textbox {
    background: transparent !important;
    color: inherit;
}

calendar-event-box {
    border: 1px solid transparent;
}

calendar-month-day-box-item[selected="true"] .calendar-color-box,
calendar-event-box[selected="true"] .calendar-color-box,
calendar-editable-item[selected="true"] .calendar-color-box {
    color: #000000 !important;
    background-color: #FDF5A0 !important;
    box-shadow: 1px 2px 5px rgba(30, 20, 0, 0.6);
}


/* RTL styles for the main box and children */
.multiday-view-main-box {
    direction: ltr;
}

.multiday-view-label-day-box:-moz-locale-dir(rtl) {
    direction: rtl;
}

/* headers horizontal, times vertical */
.multiday-view-label-box[orient="horizontal"] {
    height: 10px;
}

.multiday-view-header-box[orient="horizontal"] {
    min-height: 30px;
}

.multiday-view-label-box[orient="horizontal"] > .multiday-view-label-time-spacer,
.multiday-view-header-box[orient="horizontal"] > .multiday-view-header-time-spacer,
calendar-time-bar[orient="vertical"] {
    width: 10ex; /* space for "11:00 AM" */
}

/* headers vertical, times horizonal */
.view-label-box[orient="vertical"] {
    width: 30px;
}

.view-header-box[orient="vertical"] {
    width: 40px;
}

.multiday-view-label-box[orient="vertical"] > .multiday-view-label-time-spacer,
.multiday-view-header-box[orient="vertical"] > .multiday-view-header-time-spacer {
    height: 40px;
}

calendar-time-bar[orient="horizontal"] {
    height: 40px;
}

/** Start time bar **/

.calendar-time-bar-label {
    font-size: 1em;
}

.calendar-time-bar-box-odd,
.calendar-time-bar-box-even {
    color: #6A6969;
    background-color: #FFFFFF;
    text-align: right;
    overflow: hidden;
}

window[systemcolors] .calendar-time-bar-box-odd,
window[systemcolors] .calendar-time-bar-box-even {
    color: GrayText;
    background-color: -moz-Field;
}

.calendar-time-bar-box-odd[off-time="true"] ,
.calendar-time-bar-box-even[off-time="true"] {
    background-color: #F0F0F0;
    border-right: 2px solid #D2D2D2;
    -moz-border-right-colors:  #FFFFFF #D2D2D2;
}

window[systemcolors] .calendar-time-bar-box-odd[off-time="true"] ,
window[systemcolors] .calendar-time-bar-box-even[off-time="true"] {
    background-color: rgba(0, 0, 0, .1);
    border-right: 2px solid ThreeDShadow;
    -moz-border-right-colors: -moz-Field ThreeDShadow;
}

.calendar-time-bar-box-odd[orient="horizontal"],
.calendar-time-bar-box-even[orient="horizontal"] {
    border-right: 1px solid #D2D2D2;
    border-top: 1px solid #D2D2D2;
    -moz-border-right-colors: none;
    height: 40px; /* the same as the calendar-time-bar element */
}

window[systemcolors] .calendar-time-bar-box-odd[orient="horizontal"],
window[systemcolors] .calendar-time-bar-box-even[orient="horizontal"] {
    border-right: 1px solid ThreeDShadow;
    border-top: 1px solid ThreeDShadow;
    -moz-border-right-colors: none;
}

.calendar-time-bar-box-odd[orient="vertical"],
.calendar-time-bar-box-even[orient="vertical"] {
    border-bottom: 1px  transparent !important;
    border-right: 2px solid #D2D2D2;
    -moz-border-right-colors:  #FFFFFF #D2D2D2;
    width: 10ex; /* the same as the calendar-time-bar element */
}

window[systemcolors] .calendar-time-bar-box-odd[orient="vertical"],
window[systemcolors] .calendar-time-bar-box-even[orient="vertical"] {
    border-right: 2px solid ThreeDShadow;
    -moz-border-right-colors: -moz-Field ThreeDShadow;
}

/** End time bar **/

calendar-multiday-view {
    background-color: #FFFFFF;
    padding: 0px;
}

window[systemcolors] calendar-multiday-view {
    background-color: -moz-Field;
}

calendar-multiday-view[hidden="true"] {
    display: none;
}

calendar-day-label {
    color: #000000;
    background-color: white;
    background-image: -moz-linear-gradient(top, #fafafa, #eeeeee);
    border-left: 1px solid #D2D2D2;
    border-bottom: 1px solid #D2D2D2;
}

window[systemcolors] calendar-day-label {
    color: WindowText;
    background-color: -moz-Field;
    background-image: -moz-linear-gradient(transparent, transparent 48%, rgba(0, 0, 0, 0.02) 52%, rgba(0, 0, 0, 0.1));
    border-left: 1px solid ThreeDShadow;
    border-bottom: 1px solid ThreeDShadow;
}

calendar-day-label[selected="true"] {
    background-color: #FFFABC !important;
}

window[systemcolors] calendar-day-label[selected="true"] {
    color: HighlightText;
    background-color: Highlight !important;
}

calendar-day-label[orient="vertical"] {
    background-image: none !important;
    min-width: 100px;
}

calendar-day-label[orient="vertical"][relation="today"],
calendar-day-label[orient="vertical"][relation="today1day"] {
    background-color: #D2E3F3;
}

window[systemcolors] calendar-day-label[orient="vertical"][relation="today"],
window[systemcolors] calendar-day-label[orient="vertical"][relation="today1day"] {
    background-color: ButtonFace;
}

calendar-day-label[relation="today"],
calendar-day-label[relation="today1day"] {
    border: 1px solid #67ACD8;
    -moz-margin-end: -1px;
    margin-top: -1px;
    position: relative;
}

window[systemcolors] calendar-day-label[relation="today"],
window[systemcolors] calendar-day-label[relation="today1day"] {
    background-color: ButtonFace;
    border: 1px solid Highlight;
}

.calendar-day-label-name {
    text-align: center;
}

.calendar-day-label-name[relation="today"],
.calendar-day-label-name[relation="today1day"] {
    font-weight: bold;
}

/* Month View */
calendar-month-view,
calendar-multiweek-view {
    padding: 0px 2px 2px;
}

.calendar-month-view-grid-column {
    min-width: 1px;
    width: 1px;
}

.calendar-month-view-grid-row {
    min-height: 1px;
    height: 1px;
    border-right: 1px solid #D2D2D2;
}

window[systemcolors] .calendar-month-view-grid-row {
    border-right: 1px solid ThreeDShadow;
}

calendar-month-day-box {
    border:none !important;
    border-left: 1px solid #D2D2D2 !important;
    border-bottom: 1px solid #D2D2D2 !important;
}

window[systemcolors] calendar-month-day-box {
    border-left: 1px solid ThreeDShadow !important;
    border-bottom: 1px solid ThreeDShadow !important;
}

.calendar-month-day-box-items-box {
    overflow-y: auto;
    overflow-x: hidden;
}

.calendar-month-day-box-current-month {
    background-color: #FFFFFF;
}

window[systemcolors] .calendar-month-day-box-current-month {
    background-color: -moz-Field;
}

.calendar-month-day-box-current-month .calendar-month-day-box-date-label {
    background-color: #F7F7F7;
}

window[systemcolors] .calendar-month-day-box-current-month .calendar-month-day-box-date-label {
    background-color: -moz-Field;
}

.calendar-month-day-box-day-off {
    background-color: #F7FFE3;
}

window[systemcolors] .calendar-month-day-box-day-off {
    background-color: rgba(0, 0, 0, .1);
}

.calendar-month-day-box-day-off .calendar-month-day-box-date-label {
    background-color: #EAF7CA;
}

window[systemcolors] .calendar-month-day-box-day-off .calendar-month-day-box-date-label {
    background-color: rgba(0, 0, 0, .1);
}

.calendar-month-day-box-other-month {
    background-color: #F3F3F3;
}

window[systemcolors] .calendar-month-day-box-other-month {
    background-color: ButtonFace;
}

.calendar-month-day-box-other-month .calendar-month-day-box-date-label {
    background-color: #E8E8E8;
}

window[systemcolors] .calendar-month-day-box-other-month .calendar-month-day-box-date-label {
    color: GrayText;
    background-color: ButtonFace;
}

.calendar-month-day-box-other-month.calendar-month-day-box-day-off {
    background-color: #E8E8E8;
}

window[systemcolors] .calendar-month-day-box-other-month.calendar-month-day-box-day-off {
    background-color: ButtonFace;
}

.calendar-month-day-box-other-month.calendar-month-day-box-day-off .calendar-month-day-box-date-label {
    background-color: #DDDDDD;
}

window[systemcolors] .calendar-month-day-box-other-month.calendar-month-day-box-day-off .calendar-month-day-box-date-label {
    color: GrayText;
    background-color: ButtonFace;
}

.calendar-month-day-box-current-month[relation="today"],
.calendar-month-day-box-day-off[relation="today"],
.calendar-month-day-box-other-month[relation="today"] {
    background-color: #E1F0FD;
    border: 1px solid #7FB9EE !important;
    -moz-margin-end: -1px !important;
    margin-top: -1px !important;
    position: relative;
}

window[systemcolors] .calendar-month-day-box-current-month[relation="today"],
window[systemcolors] .calendar-month-day-box-day-off[relation="today"],
window[systemcolors] .calendar-month-day-box-other-month[relation="today"] {
    background-color: -moz-Field;
    border: 1px solid Highlight !important;
}

.calendar-month-day-box-date-label[relation="today"] {
    background-color: #D2E3F3;
    font-weight: bold;
}

window[systemcolors] .calendar-month-day-box-date-label[relation="today"] {
    color: Highlight;
}

.calendar-month-day-box-current-month[selected="true"],
.calendar-month-day-box-day-off[selected="true"],
.calendar-month-day-box-other-month[selected="true"] {
    background-color: #FFFCD8;
}

window[systemcolors] .calendar-month-day-box-current-month[selected="true"] {
    background-color: -moz-Field;
}

window[systemcolors] .calendar-month-day-box-day-off[selected="true"] {
    background-color: rgba(0, 0, 0, .1);
}

window[systemcolors] .calendar-month-day-box-other-month[selected="true"] {
    background-color: ThreeDLightShadow;
}

.calendar-month-day-box-date-label[selected="true"] {
    background-color: #F2EDB2;
}

window[systemcolors] .calendar-month-day-box-date-label[selected="true"] {
    color: HighlightText;
    background-color: Highlight;
}

.calendar-month-day-box-date-label[relation="today"][selected="true"] {
    background-color: #D2E3F3;
}

window[systemcolors] .calendar-month-day-box-date-label[relation="today"][selected="true"] {
    color: HighlightText;
    background-color: Highlight;
}

.calendar-month-day-box-date-label {
    color: #616163;
    font-size: 0.9em;
    text-align: right;
    margin: 0px;
    padding-top: 1px;
    -moz-padding-end: 2px;
    padding-bottom: 1px;
}

window[systemcolors] .calendar-month-day-box-date-label {
    color: WindowText;
    background-image: -moz-linear-gradient(rgba(0, 0, 0, .05), rgba(0, 0, 0, .05));
}

calendar-month-day-box-item {
    margin: 1px;
    padding: 1px 1px;
}

.calendar-color-box {
    /* This rule should be adopted if the alarm image size is changed */
    min-height: 13px;
    background-image: -moz-linear-gradient(top, rgba(255, 255, 255, 0.25), rgba(255, 255, 255, 0.01) 50%, rgba(0, 0, 0, 0.05));
    border: 1px solid transparent;
    border-radius: 2px;
}

calendar-month-day-box calendar-month-day-box-item[allday="true"] .calendar-color-box {
    border-color: rgba(0, 0, 0, 0.5);
    box-shadow: inset -1px -1px 0 rgba(255, 255, 255, 0.7), inset 1px 1px 0 rgba(255, 255, 255, 0.7);
}

.calendar-month-day-box-item-label {
    padding: 0px;
    margin: 0px;
}

.calendar-month-day-box-item-label[time="true"] {
    -moz-margin-end: 4px;
}

.labeldaybox-container {
    border-right: 1px solid #D2D2D2;
    border-top: 1px solid #D2D2D2;
}

window[systemcolors] .labeldaybox-container {
    border-right: 1px solid ThreeDShadow;
    border-top: 1px solid ThreeDShadow;
}

.dropshadow {
    height: 1.2em;
    margin: 1px;
    padding: 0px 1px;
    background-color: #FFA47D;
    box-shadow: 1px 1px 3px rgba(68, 35, 0, 0.7) inset;
}

window[systemcolors] .dropshadow {
    background-color: Highlight !important;
}

calendar-event-gripbar {
    -moz-box-align: center;
    -moz-box-pack: center;
    min-height: 4px;
    min-width: 4px;
    overflow: hidden;
}

calendar-event-gripbar[parentorient="vertical"][whichside="start"] {
    cursor: n-resize;
}

calendar-event-gripbar[parentorient="vertical"][whichside="end"] {
    cursor: s-resize;
}

calendar-event-gripbar[parentorient="horizontal"][whichside="start"] {
    cursor: w-resize;
}

calendar-event-gripbar[parentorient="horizontal"][whichside="end"] {
    cursor: e-resize;
}

calendar-event-box[orient="vertical"] .calendar-event-box-grippy-top {
    list-style-image: url("chrome://calendar/skin/event-grippy-top.png");
    visibility: hidden;
}

calendar-event-box[orient="vertical"] .calendar-event-box-grippy-bottom {
    list-style-image: url("chrome://calendar/skin/event-grippy-bottom.png");
    visibility: hidden;
}

calendar-event-box[orient="horizontal"] .calendar-event-box-grippy-top {
    list-style-image: url("chrome://calendar/skin/event-grippy-left.png");
    visibility: hidden;
}

calendar-event-box[orient="horizontal"] .calendar-event-box-grippy-bottom {
    list-style-image: url("chrome://calendar/skin/event-grippy-right.png");
    visibility: hidden;
}

calendar-event-box[gripBars="start"]:not([readonly="true"]):hover .calendar-event-box-grippy-top,
calendar-event-box[gripBars="end"]:not([readonly="true"]):hover .calendar-event-box-grippy-bottom,
calendar-event-box[gripBars="both"]:not([readonly="true"]):hover .calendar-event-box-grippy-top,
calendar-event-box[gripBars="both"]:not([readonly="true"]):hover .calendar-event-box-grippy-bottom {
    visibility: visible;
}

/* tooltips */
vbox.tooltipBox {
    max-width: 40em;
}

column.tooltipValueColumn {
    max-width: 35em; /* tooltipBox max-width minus space for label */
}

label.tooltipHeaderLabel {
    font-weight: bold;
    text-align: right;
    margin-top: 0;
    margin-bottom: 0;
    -moz-margin-start: 0;
    -moz-margin-end: 1em; /* 1em space before value */
}

description.tooltipHeaderDescription {
    font-weight: normal;
    text-align: left;
    margin: 0pt;
}

separator.tooltipBodySeparator {
    height: 1ex; /* 1ex space above body text, below last header. */
}

description.tooltipBody {
    font-weight: normal;
    white-space: pre-wrap;
    margin: 0pt;
}

#calendar-view-context-menu[type="event"] .todo-only,
#calendar-view-context-menu[type="todo"] .event-only,
#calendar-view-context-menu[type="mixed"] .event-only,
#calendar-view-context-menu[type="mixed"] .todo-only,
#calendar-item-context-menu[type="event"] .todo-only,
#calendar-item-context-menu[type="todo"] .event-only,
#calendar-item-context-menu[type="mixed"] .event-only,
#calendar-item-context-menu[type="mixed"] .todo-only {
    display: none;
}

.attendance-menu[itemType="single"] > menupopup > *[scope="all-occurrences"] {
    display: none;
}

.calendar-context-heading-label {
    font-weight: bold;
}

calendar-event-box,
calendar-editable-item,
calendar-month-day-box-item {
    opacity: 0.99;
    /* Do not change next line, since it would break item selection */
    -moz-user-focus: normal;
}

calendar-event-box[invitation-status="NEEDS-ACTION"],
calendar-editable-item[invitation-status="NEEDS-ACTION"],
calendar-month-day-box-item[invitation-status="NEEDS-ACTION"] {
    border: 2px dotted black;
    opacity: 0.6;
}

calendar-event-box[invitation-status="TENTATIVE"],
calendar-editable-item[invitation-status="TENTATIVE"],
calendar-month-day-box-item[invitation-status="TENTATIVE"],
calendar-event-box[status="TENTATIVE"],
calendar-editable-item[status="TENTATIVE"],
calendar-month-day-box-item[status="TENTATIVE"],
agenda-richlist-item[status="TENTATIVE"] {
    opacity: 0.6;
}

calendar-event-box[invitation-status="DECLINED"],
calendar-editable-item[invitation-status="DECLINED"],
calendar-month-day-box-item[invitation-status="DECLINED"],
calendar-event-box[status="CANCELLED"],
calendar-editable-item[status="CANCELLED"],
calendar-month-day-box-item[status="CANCELLED"],
agenda-richlist-item[status="CANCELLED"] {
    opacity: 0.5;
}

calendar-month-day-box-item[status="CANCELLED"] .calendar-color-box,
calendar-event-box[status="CANCELLED"] .calendar-color-box,
calendar-editable-item[status="CANCELLED"] .calendar-color-box,
agenda-richlist-item[status="CANCELLED"] .agenda-container-box {
    text-decoration: line-through;
}

/* Navigation controls for the views */
#view-deck {
    border: solid ThreeDShadow;
}

#view-tabs .tabs-left,
#view-tabs .tabs-right {
    border-bottom: 1px solid ThreeDShadow;
	-moz-border-bottom-colors: none;
}

tab[calview] {
    -moz-appearance: none;
    border-top-left-radius: 4px;
    border-top-right-radius: 4px; 
    margin-top: 0px;
    -moz-user-focus: normal;  
}

tab[calview][selected="true"],
tab[calview][selected="true"]:hover {
    margin-bottom: 0px;
    border-bottom: none;
}

tab[calview] > .tab-middle {
    text-align: center;
}

.view-header {
    font-weight: normal;
    font-size: 14px;
    color: ButtonText;
}

.view-header[type="end"] {
    text-align: right;
    -moz-margin-end: 6px;
}

.navigation-inner-box {
    -moz-padding-start: 6px;
    -moz-padding-end: 6px;
    padding-bottom: 1px;
}

.navigation-bottombox {
    min-height: 4px;
    max-height: 4px;
}

.view-navigation-button {
    -moz-user-focus: normal;
    -moz-appearance: toolbarbutton;
    min-width: 22px;
}

.today-navigation-button {
    -moz-user-focus: normal;
    -moz-appearance: toolbarbutton;
    -moz-margin-start: 2px;
    -moz-margin-end: 2px;
    color: ButtonText;
    font-size: 14px;
}

.view-navigation-button > .toolbarbutton-text {
    display: none;
}

.today-navigation-button > .toolbarbutton-icon {
    display: none;
}
