@import './node_modules/@waca/ca-ui-toolkit/essentials/essentials';

.caHomeTile {
	margin: 1px !important;

	@media only screen and (min-width: 1480px) {
		&:nth-child(3n) {
			margin-right: 0;
		}
	}

	@media only screen and (max-width: 1480px) {
		margin-right: 32px;

		&:nth-child(even) {
			margin-right: 0;
		}
	}

	@media only screen and (max-width: 700px) {
		margin-right: 0px;
	}
}

body.highcontrast div.caHomeTile {
	border: 1px solid;
	@include theming(border-color, ui-background);
}

.caHomeTile .contextMenuButton {
	width: 24px;
	height: 24px;
	@include theming(fill, icon-01);
	padding: 12px;

	&:hover {
		@include theming(background-color, hover-ui);
	}


	* {
		@include highContrast {
			@include theming(fill, ui-background);
		}
	}

	&.contextMenuButton_active {
		.dot-first {
			-webkit-animation: pulse 1s 0.75s infinite;
			-moz-animation:    pulse 1s 0.75s infinite;
			-o-animation:      pulse 1s 0.75s infinite;
			animation:         pulse 1s 0.75s infinite;
		}

		.dot-second {
			-webkit-animation: pulse 1s 1.5s infinite;
			-moz-animation:    pulse 1s 1.5s infinite;
			-o-animation:      pulse 1s 1.5s infinite;
			animation:         pulse 1s 1.5s infinite;
		}

		.dot-third {
			-webkit-animation: pulse 1s infinite;
			-moz-animation:    pulse 1s infinite;
			-o-animation:      pulse 1s infinite;
			animation:         pulse 1s infinite;
		}
	}
}

@-webkit-keyframes pulse {
	0% {
		opacity: 1;
	}
	50% {
		opacity: 0;
	}
	100% {
		opacity: 1;
	}
}

@-moz-keyframes pulse {
	0% {
		opacity: 1;
	}
	50% {
		opacity: 0;
	}
	100% {
		opacity: 1;
	}
}

@-o-keyframes pulse {
	0% {
		opacity: 1;
	}
	50% {
		opacity: 0;
	}
	100% {
		opacity: 1;
	}
}

@keyframes pulse {
	0% {
		opacity: 1;
	}
	50% {
		opacity: 0;
	}
	100% {
		opacity: 1;
	}
}

div.caHomeTile{
	& div.ba-common-tile{
		box-shadow: none !important;
		border: 0px;
		@include theming(border-color, ui-01);
	}

	& div.ba-common-tile__body{
		& div.ba-common-tile__body__label{
			display: block;

			& div.ba-common-truncatedText__text{
				/* Todo: Enforcement of maximum 3-line title text */
			}
		}

		& div.ba-common-tile__body__date{
			line-height: 1.25rem;
			font-size: 14px;
		}
	}

	& div.ba-common-tile:not(.is-selected):hover{
		@include theming(background-color, hover-ui);

		& div.ba-common-tile__footer svg:nth-child(2) {
			@include theming(color, primary2);
		}
	}

	& div.ba-common-tile:not(.is-selected):focus{
		border: 1px solid;
		@include theming(border-color, focus, 1, !important);
		outline: none;
	}

}
@media all and (-ms-high-contrast: none), (-ms-high-contrast: active) {
    div.caHomeTile{
		& div.ba-common-tile__body{
			& div.ba-common-tile__body__label{
				& div.ba-common-truncatedText__text{
					padding-top: 4px;
				}
			}
		}
	}
}