/**
 * Copyright ( C ) 2012 eXo Platform SAS.
 *
 * This is free software; you can redistribute it and/or modify it
 * under the terms of the GNU Lesser General Public License as
 * published by the Free Software Foundation; either version 2.1 of
 * the License, or (at your option) any later version.
 *
 * This software is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 * Lesser General Public License for more details.
 *
 * You should have received a copy of the GNU Lesser General Public
 * License along with this software; if not, write to the Free
 * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
 * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
 */

@import "../../../variables.less"; 
@import "../../../mixins.less";
// -------------------------
.calendarPortlet  {
	.calendarPortletData {
		a {

			color: @textColor;
		}
		.currentDateContainer {
			overflow: hidden;//hack ie8 click on arrow icon
		}
		.uiContentBox {
			padding: 15px;
		}
		.title  .actionIcon {
			line-height: 14px;
			padding: 1px;
			margin: 0;
		}
		.taskTitle {
			background-color: @primaryBackgroundLight;
		}
		.eventsList {
			li {
				.border-radius(@borderRadiusSmall + 1);
				border: 1px solid transparent;
				margin: 0 0 10px 0;
				> div {
					padding: 0 4px 0 0;
					.border-radius(4px 3px 3px 4px);
				}
				.itemColor {
					.border-radius(@borderRadiusSmall 0 0 @borderRadiusSmall);
					background-color: @primaryBackground;
					padding: 4px 4px 4px 8px;

				}

				&.pastEvent {
					.opacity(45);
					.itemColor {
						background-color: @primaryBackgroundHover;
							a,.time span {color: @baseColorLight;}
					}

				}
				&:hover {
					border: 1px solid @borderColor;
				}

				&:last-child {
					margin-bottom: 0;
				}
			}
			.eventSummary {
				width: 50%;
				.text-overflow;
				white-space: normal;
				max-height: 40px;
			}
			.time {
				width: 50%;
				 text-align: right;
				font-size: @baseFontSize - 1;
			}

		}

		.tasksList {
			li {
				padding: 0 0 0 20px;
				margin: 0 0 5px 0;
				cursor: pointer;
				max-height: 40px;
				.text-overflow;
				white-space: normal;
				position: relative;
			}
			a {
				color: @textColor;
			}
			.taskCompleted {
				text-decoration:line-through;
			}
			.taskCompleted:before {
				color: @primaryColor;
			    border-bottom: 2px solid @primaryColor;
			    border-left: 2px solid @primaryColor;
			    content: "";
			    height: 3px;
			    left: 4px;
			    position: absolute;
			    top: 4px;
			    transform: skew(45deg, -49deg);
			    width: 6px;
			}
			.taskNotCompleted:before {
				background: @borderColor ;
			    border-radius: 3px;
			    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.17) inset;
			    content: "";
			    height: 12px;
			    left: 0;
			    position: absolute;
			    top: 4px;
			    width: 12px;
			}
			.taskLateNotCompleted:before {
				content: "\e772";
				color: @warningColor;
			    display: inline-block;
			    font-family: "PLF-FONT-ICONS";
			    font-size: 12px;
			    font-style: normal;
			    font-variant: normal;
			    font-weight: normal;
			    line-height: 1;
			    position: relative;
			    text-transform: none;
			    top: 1px;
			    margin-right: 5px;
			}
			.taskLateNotCompleted {
				padding-left: 0px;
			}

		}
		.settingsContainerPage {
			margin:0px 10px 10px 10px ;
		}
		.settingsLink.actionIcon.pull-right {
			margin-right: 8px;
			margin-top: -32px;
			.uiIconSetting.uiIconLightGray {
				margin-top: -12px;
			}
		}
		.actionIcon.nextDate.pull-right {
			margin-right: 60px;
		}
	}

}

#SpaceHomePortlets {
	.calendarPortlet {
		.calendarPortletData {
			.actionIcon.prevDate.pull-left {
				margin-left: 20px;
			}
			.actionIcon.nextDate.pull-right {
				margin-right: 30px;
			}
		}
	}
}

.calendarName {
	.border-radius(@borderRadiusSmall);
	color: @baseBackground;
	display: inline-block;
	font-size: @baseFontSize - 2;
	padding: 0px 10px;
	margin: 0 5px 5px 0;
	  max-width: 92%;
   .text-overflow;
}

.asparagus {
    background-color: #909958;
}

.munsell_blue {
    background-color: #319AB3;
}

.navy_blue {
    background-color: #4273C8;
}

.purple {
    background-color: #774EA9;
}

.red {
    background-color: #FF5933;
}

.brown {
    background-color: #BB8E62;
}

.laurel_green {
    background-color: #BED67E;
}

.sky_blue {
    background-color: #4DBED9;
}

.blue_gray {
    background-color: #8EB0EA;
}

.light_purple {
    background-color: #BC99E7;
}

.hot_pink {
    background-color: #F97575;
}

.light_brown {
    background-color: #C5B294;
}

.moss_green {
    background-color: #98CC81;
}

.powder_blue {
    background-color: #9EE4F5;
}

.light_blue {
    background-color: #B3CFFF;
}

.pink {
    background-color: #FFC8F0;
}

.orange {
    background-color: #FDB519;
}

.gray {
    background-color: #A39594;
}

.green {
    background-color: #89D4B3;
}

.baby_blue {
    background-color: #B2E2FF;
}

.light_gray {
    background-color: #CDCDCD;
}
.beige {
    background-color: #FFE1BE;
}

.yellow {
    background-color: #FFE347;
}

.plum_purple, .plum {
    background-color: #CEA6AC;
}

/*setting calendar */
.settingsCalContainer {
	.DisplayedCalendarContainer {
		.calendarName {
			padding: 0 4px;
			margin: 0 5px 4px 0;
			span {
				display: inline-block;
				height: 20px;
				max-width: 92%;
				 vertical-align: middle;
				.text-overflow;
			}
		}
		.uiIconDel { // Changing background-image to font-icon
			//.square(14px);
			//background: url("@{images-path}/platform/portlets/homepage/calendar/del.png") no-repeat 2px center;
			cursor:pointer;
		  	color: white;
		  	font-size: 10px;
		  	height: 14px;
		  	vertical-align: middle;
		  	&:before {
			  	content: "\e76d";
			}
		}
	}
	.uiBox  .uiContentBox {
		padding: 15px;
	}
	.PLFcalendarSearchKey {
		width: 100%;
		color: @baseColorLight;
	}
	.settingValidationButton  {
		text-align: right;
		margin: 5px 0 0 0;
		.btn {
			font-size: @baseFontSize - 2;
			padding: 1px 8px;
		}
	}

	.calendarItems {
		margin: 0 -15px;
		.calendarItem {
			padding: 0px 15px;
			height: 24px;
			line-height: 24px;
			a {
				color: @textColor;
			}
			.addButton {
				display: none;
			}
			&:hover {
				background: @primaryBackgroundHover;
				& .addButton {
					display: block;
				}

			}
			.uiIconAdd{
				.square(14px);
				background: url("@{images-path}/platform/portlets/homepage/calendar/add.png") no-repeat 2px 2px; 
			}
			.calName {
				height: 20px;
				.text-overflow;
				display: block;
			}
			.colorBox {
				.square(12px);
				display: block;
				margin: 6px 5px 0 0;
				.border-radius(@borderRadiusSmall);
			}
		}
	}
	.NonDisplayedCalendar {
		max-height: 350px;
		overflow-y: auto;
	}

}
