@use "mixins/mixins-master" as *;
@use "mixins/flex" as *;
@use "variables" as *;
@use "buttons/buttons" as *;
.thim-sc-events {
	&.absolute-bottom-right {
		position: absolute;
		bottom: 0;
		right: 15px;
		.content-inner {
			.line {
				display: none;
			}
			.title {
				margin-bottom: 12px !important;
			}
			.time-location {
				margin-bottom: 30px !important;
			}
			.author {
				@media (min-width: 1441px) {
					margin-top: 82px;
				}
			}
		}
		.owl-dots {
			position: absolute;
			bottom: 0;
			right: 0;
		}
	}
	&.absolute-bottom-left {
		position: absolute;
		bottom: 0;
		left: 15px;
	}
	.events {
		.time-location {
			font-size: 14px;
			font-weight: 400;
			line-height: 21px;
			margin-bottom: 50px;
			text-transform: uppercase;
			.time {
				margin-right: 19px;
			}
			.location,
			.time {
				i {
					margin-right: 4px;
					font-size: 24px;
					vertical-align: bottom;
				}
			}
			.location {
				text-transform: capitalize;
			}
		}
		.author {
			@include flexbox();
			img {
				width: 60px;
				height: 60px;
				@include rounded(100%);
			}
			.author-contain {
				margin: 5px 0 0 17px;
				.jobTitle {
					font-size: 14px;
					font-weight: 400;
					// font-style: italic;
					// letter-spacing: 0.3px;
					margin: 5px 0 2px 0;
					clear: both;
					display: block;
					line-height: normal;
					color: $thim_font_body_color;
				}
				.name {
					a {
						font-size: 16px;
						// letter-spacing: 0.3px;
						font-weight: 500;
						margin-top: 4px;
					}
				}
			}
		}
	}
	.owl-nav {
		.owl-prev,
		.owl-next {
			position: absolute;
			background: transparent;
			&:hover {
				background: transparent;
				@include transition(0.3s);
			}
		}
		.disabled {
			@include opacity(1);
			color: #d9d9d9 !important;
			cursor: not-allowed;
			&:hover {
				color: #d9d9d9 !important;
			}
		}
	}
}

.events-layer-1 {
	max-width: 725px;
	position: relative;
	border-radius: $thim_border_radius;
	overflow: hidden;
	.sc-title {
		height: 101px;
		line-height: 101px;
		font-size: 36px;
		font-weight: 500;
		letter-spacing: 0.4px;
		text-align: center;
		color: #ffffff;
		text-transform: capitalize;
		width: 259px;
		position: absolute;
		z-index: 2;
		left: 1px;
		top: 1px;
		// border: 1px solid $border-color;
		border-top: 0;
		border-left: 0;
	}
	.owl-stage-outer {
		background: #fff;
		.events {
			.events-before {
				@include flexbox();
				.title-date {
					width: 259px;
					padding-top: 103px;
					.date {
						background: #fff;
						text-align: center;
						padding: 53px 0;
						.date-start {
							font-size: 100px;
							font-weight: bold;
							line-height: 1.25;
							letter-spacing: 2.4px;
							clear: both;
							display: block;
							// padding: 76px 0 38px 0;
						}
						.month-year-start {
							text-transform: uppercase;
							font-size: 16px;
							font-weight: 400;
							letter-spacing: 2px;
						}
					}
				}
				.thumbnail {
					@include calc("width", "100% - 259px");
				}
			}
			.events-after {
				max-height: 146px;
				height: 100%;
				background: #fff;
				position: relative;
				.content {
					padding: 0 75px 0 30px;
					.title {
						padding-top: 30px;
						font-weight: 500;
						a {
							// text-transform: uppercase;
							font-size: 20px;
							line-height: 1.2;
							letter-spacing: 0.4px;
							text-align: left;
						}
					}
					.time-location {
						margin: 0;
						padding-bottom: 30px;
					}
				}
			}
		}
	}
	.owl-nav {
		position: absolute;
		right: 0;
		bottom: 0;
		height: 120px;
		width: 73px;
		// background: #fff;
		.owl-prev,
		.owl-next {
			@include transition(0.3s);
			display: block;
			clear: both;
			width: 73px;
			background: #fff;
			border-radius: 0;
			position: absolute;
			margin: 0;
			padding: 0;
			font-size: 28px;
			line-height: 0.79;
			text-align: center;
			.ion-ios-arrow-right,
			.ion-ios-arrow-left {
				display: block;
				padding-top: 20px;
			}
		}
		.owl-prev {
			bottom: 0;
			right: 0;
			height: 60px;
		}
		.owl-next {
			height: 60px;
			bottom: 59px;
			right: 0;
			border-top: 0 !important;
		}
		.disabled {
			&:hover {
				background-color: #f6f6f6 !important;
			}
		}
	}
}
.thim-sc-event-layer2-row {
	.wpb_column.vc_col-sm-12 {
		min-height: 0;
	}
}

.events-layer-2 {
	bottom: 0;
	right: 15px;
	width: 742px;
	max-width: 100%;

	.owl-stage-outer {
		background: #fff;
		border-radius: $thim_border_radius $thim_border_radius 0 0;
		.events {
			display: flex;
		}
	}

	.events-before {
		.content-inner {
			.title {
				line-height: 1em;
				font-weight: 400;
				margin-bottom: 4px;
				a {
					font-size: 20px;
					line-height: 25px;
					text-transform: uppercase;
				}
			}
			.time-location {
				margin-bottom: 0;
				display: flex;
				flex-direction: row;
				.location {
					text-transform: uppercase;
				}
			}
			.author {
				.name {
					a {
						font-size: 14px;
						letter-spacing: 0.3px;
						text-transform: uppercase;
					}
				}
			}
		}
	}

	.owl-nav {
		width: 120px;
		height: 60px;
		position: absolute;
		bottom: 0;
		left: -120px;
		border-radius: $thim_border_radius 0 0 0;
		.owl-prev,
		.owl-next {
			font-size: 30px;
			color: #d9d9d9;
			line-height: 50px;
			width: 60px;
			text-align: center;
			&:hover {
				background: transparent;
				color: #fff !important;
			}
		}
		.owl-prev {
			left: 4px;
		}
		.owl-next {
			right: 0;
		}
	}
	.owl-dots {
		.owl-dot {
			span {
				background: #f2f2f2;
			}
			&.active {
				span {
					background: $thim_body_primary_color;
				}
			}
		}
	}
	.events-before {
		flex-grow: 1;

		.content-inner {
			padding: 30px;
		}

		.description {
			font-size: 16px;
			font-weight: 400;
			line-height: 1.5;
			margin-bottom: 30px;
		}

		.line {
			width: 46px;
			height: 2px;
			background: rgba(136, 136, 136, 0.2);
			margin: 24px 0;
		}

		.date {
			font-size: 16px;
			font-weight: 500;
			line-height: 1.5;
			margin-bottom: 12px;
			text-transform: uppercase;
		}
	}

	.events-after {
		flex-shrink: 0;
	}
}

.events-layer-3 {
	max-width: 1150px;
	margin: auto;

	.owl-stage-outer {
		// padding-left: 30px;
		// padding-right: 30px;
		// margin-left: -30px;
		// margin-right: -30px;
		// padding-bottom: 30px;
		.events {
			display: block;
			position: relative;
			max-width: 364px;
			min-height: 540px;
			border: 1px solid $border-color;
			border-radius: $thim_border_radius;
			overflow: hidden;
			.events-before {
				display: block;
				opacity: 1;
				@include transition(all 0.5s);
				.thumbnail {
					overflow: hidden;
					.img_thumbnail {
						img {
							height: 100%;
							border-radius: 5px;
						}
						&:before {
							content: "";
							width: 100%;
							height: 194px;
							bottom: 0;
							z-index: 1;
							display: block;
							position: absolute;
							overflow: hidden;
							background: linear-gradient(357.29deg, rgba(0, 0, 0, 0.8) 8.26%, rgba(0, 0, 0, 0) 92.94%);
							@include rounded(5px);
						}
					}
				}
				.content {
					position: absolute;
					top: 0;
					height: 100%;
					z-index: 999;
					width: 100%;
					background: linear-gradient(180deg, rgba(0, 0, 0, 0) 67.61%, rgba(0, 0, 0, 0.8) 100%);
					.date {
						position: absolute;
						right: 16px;
						top: 16px;
						height: 60px;
						width: 60px;
						@include rounded(4px);
						padding: 10px;
						text-align: center;
						.date-start {
							font-size: 20px;
							font-weight: 500;
							line-height: 1.25;
							// letter-spacing: 0.6px;
							color: #ffffff;
							// padding-top: 18px;
						}
						.month-start {
							font-size: 14px;
							line-height: 1.5;
							// letter-spacing: 1.8px;
							color: #ffffff;
							text-transform: uppercase;
							// padding-top: 2px;
							font-weight: 400;
						}
					}

					.content-inner {
						bottom: 0;
						position: absolute;
						padding: 0 30px 0 30px;
						.title {
							font-size: 20px;
							line-height: 1.25;
							margin-bottom: 12px;
							// letter-spacing: 0.4px;
							a {
								color: #fff;
							}
						}
						.author {
							color: #ffffff;
							text-transform: capitalize;
							margin-bottom: 12px;
							font-size: 14px;
							line-height: 1.5;
							font-weight: 400;
							display: flex;
							gap: 12px;
							align-items: center;
							font-weight: 500;
							img {
								width: 32px;
								height: 32px;
								object-fit: cover;
								border-radius: 50%;
							}
						}
						.time-location {
							color: #e2e0db;
							margin-bottom: 30px;
						}
					}
				}
			}
			.events-after {
				width: 100%;
				height: 100%;
				position: absolute;
				top: 0;
				left: 0;
				right: 0;
				bottom: 0;
				display: block;
				opacity: 0;
				padding: 0 27px 0 27px;
				@include rounded(5px);
				background: #fff;
				@include box-shadow(12.9px 15.3px 18px 0 rgba(0, 0, 0, 0.08));
				@include transition(all 0.5s);
				.content-inner {
					.title {
						padding-top: 30px;
						font-size: 20px;
						line-height: 1.25;
						margin-bottom: 12px;
					}
					.time-location {
						&:after {
							content: "";
							display: block;
							position: absolute;
							background: rgba(136, 136, 136, 0.2);
							width: 46px;
							height: 2px;
							margin-top: 24px;
						}
					}
					.description {
						margin-bottom: 49px;
						font-size: 16px;
						font-weight: 400;
						line-height: 1.63;
						// letter-spacing: 0.3px;
						text-align: left;
					}
					.author {
						position: absolute;
						@include flexbox();
						bottom: 49px;
						.name {
							a {
								text-transform: capitalize;
								font-size: 16px;
								// letter-spacing: 0.3px;
								text-align: left;
							}
						}
					}
				}
			}
			&:hover {
				.events-before {
					@include opacity(0);
					@include transition(all 0.5s);
				}
				.events-after {
					@include opacity(1);
					@include transition(all 0.5s);
				}
			}
		}
	}
	.owl-nav {
		.owl-prev,
		.owl-next {
			top: 231px;
			font-size: 24px;
			color: $thim_font_body_color;
			border-radius: 50%;
			border: 1px solid $border-color;
			width: 40px;
			height: 40px;
			text-align: center;
			line-height: 30px;
			&.disabled {
				color: #e8e8e8 !important;
				opacity: 0.5;
			}
		}
		.owl-prev {
			left: -73px;
		}
		.owl-next {
			right: -73px;
		}
		@media (max-width: 880px) {
			display: none;
		}
	}
	.owl-dots {
		margin-top: 30px;
	}
}

$colors-event: #df6c4f #ecd06f #49a942 #00a78e #00bce4;
$index: 1;
.thim-sc-events {
	&.events-layer-3 {
		@for $i from 1 through 30 {
			.owl-item:nth-child(#{$i}) {
				.events .events-before .content .date {
					background: nth($colors-event, $index);
				}
			}
			$index: $index + 1;
			@if ($index > 5) {
				$index: 1;
			}
		}
	}
}

article.sidebar-right {
	.thim-sc-events {
		&.events-layer-3 {
			margin-left: -50px;
			.owl-nav {
				.owl-prev,
				.owl-next {
					left: -85px;
				}
				.owl-next {
					left: auto;
					right: -72px;
				}
			}
		}
	}
}

.thim-events-block {
	.event-wrapper > div {
		border-bottom: 1px solid rgba(238, 238, 238, 0.2);
		&:first-child,
		&:last-child {
			border-bottom: none;
		}
	}
	.sc-title {
		margin-bottom: 60px;
		font-size: 36px;
		line-height: 45px;
		font-weight: 500;
		text-align: left;
		color: #ffffff;
		text-transform: uppercase;
	}
	.main-event {
		float: left;
		width: 65.4%;
		padding-right: 113px;
		position: relative;
		z-index: 9;
		.date-month {
			float: left;
			max-width: 130px;
			text-align: center;
			.date {
				font-size: 100px;
				font-weight: 500;
				line-height: 1.1;
			}
			.month {
				text-transform: uppercase;
				font-size: 14px;
				line-height: 24px;
				font-weight: 500;
			}
		}
		.meta {
			font-size: 16px;
			letter-spacing: normal;
			text-align: left;
			font-weight: 400;
			i {
				margin-right: 7px;
				color: #e2e0db;
				font-size: 18px;
				&.ion-ios-location {
					margin-right: 12px;
				}
			}
			.time {
				margin-bottom: 10px;
			}

			.time,
			.location {
				color: #e2e0db;
				display: flex;
				// font-size: 15px;
				// line-height: 25px;
				// font-weight: 400;
			}
		}
		.description {
			text-align: left;
			color: #e2e0db;
			// font-weight: 400;
			margin-top: 40px;
			// font-size: 15px;
			// line-height: 25px;
		}

		.view-detail {
			margin-top: 30px;
			display: inline-block;
			@include button_typo();
			color: #fff;
			padding: 0 34px;
			border-radius: 30px;
			background-size: 220% 100%;
			@include transition(all 0.4s ease-in-out);
			&:hover {
				background-position: right center;
			}

			i {
				margin-left: 10px;
				margin-right: 0;
				vertical-align: middle;
			}
		}
		.title {
			padding-top: 10px;
			font-size: 24px;
			line-height: 1.5;
			font-weight: 400;
			text-align: left;
			padding-bottom: 15px;
			margin-bottom: 15px;
			border-bottom: 1px solid rgba(238, 238, 238, 0.2);
			a {
				color: white;
				&:hover {
					color: $thim_body_primary_color;
				}
			}
		}
		.content {
			overflow: hidden;
			padding-left: 28px;
		}
	}
	.event-item {
		width: 34.6%;
		margin-bottom: 20px;
		float: right;
		overflow: hidden;
		.date {
			font-weight: 400;
			font-size: 14px;
			line-height: 25px;
			margin-bottom: 10px;
		}
		.title {
			font-size: 24px;
			line-height: 34px;
			font-weight: 400;
			margin-bottom: 20px;
			a {
				color: white;
				&:hover {
					color: $thim_body_primary_color;
				}
			}
		}
	}
	&.layout-4 {
		.main-event {
			.event-detail {
				.date-month {
					padding: 23px 20px;
					max-width: 100%;
					border-radius: $thim_border_radius;
					background: $thim_body_primary_color;
					.date {
						font-size: 36px;
						line-height: 45px !important;
						margin-bottom: 4px;
					}
					.month {
						font-size: 16px;
						font-weight: 400;
						line-height: 24px;
					}
				}
				.content {
					.title {
						margin-bottom: 0;
						padding-bottom: 8px;
						border-bottom: 0;
					}
					.meta {
						display: flex;
						gap: 20px;
						i {
							font-size: 24px;
						}
					}
				}
			}
			.description {
				margin-top: 30px;
				display: inline-block;
			}
		}
		.event-item {
			margin-bottom: 30px;
			.title {
				margin-bottom: 30px;
				font-weight: 500;
			}
			.date {
				margin-bottom: 16px;
				font-size: 16px;
				color: #e2e0db;
			}
		}
	}
}
