@import "../../scss/vars";
$--border-hover-color: #89cbfa;
:global {
	.z-view-form-panel + .z-view-form-panel {
		margin-top: 15px;
	}
	.z-age-tab {
		padding: 0 20px;
		.ant-tabs-bar {
			margin: 0;
		}
	}
	.ant-upload-list-item-list-type-picture-card > div {
		height: 100%;
	}
	.z-form-control-placeholder {
		border: 1px solid $border-color-split;
		border-radius: 4px;
		text-align: center;
		height: 38px;
		line-height: 38px;
		color: $--gray;
	}
	.z-add-formitem-btn {
		padding: 15px 0 !important;
		margin-top: 20px;
		cursor: pointer;
		user-select: none;
		color: #333333;
		&:hover {
			color: #2f6baa;
		}
		&:active {
			background-color: #f2f2f2;
		}
	}
	.z-address-btn {
		cursor: pointer;
	}
	.z-fieldKey-lock {
		cursor: pointer;
		&:hover {
			color: #1a71c6;
		}
	}
	.z-live-form-item-clone {
		padding: 36px 10px 0 !important;
		position: absolute !important;
		border: 1px dashed $--border-hover-color;
		z-index: 9999;
		background-color: rgba(255, 255, 255, 0.6);
		.z-live-tool {
			display: flex;
		}

		.ant-form-item-children,
		.ant-input-number {
			display: inline-block;
		}
		.ant-calendar-picker,
		.ant-form-item-children,
		.ant-input-number,
		.ant-select {
			width: 100%;
		}
	}
	.z-live-form {
		[class*="ant-col-"] {
			padding: 36px 10px 0;
			border-width: 1px;
			border-style: dashed;
			border-color: #dedede;
			&:hover {
				border-color: $--border-hover-color;
				.z-live-tool {
					display: flex;
				}
			}
			&.gu-transit {
				border-color: rgba(0, 0, 0, 1);
				background-color: rgba(0, 0, 0, 0.1);
			}
			// &.z-ex-moved {
			// 	border-color: #e74c3c;
			// }
		}

		// .z-view-form-panel {
		// 	border-width: 1px;
		// 	border-style: dashed;
		// 	border-color: transparent;
		// 	// &:hover {
		// 	// 	border-color: $--border-hover-color;
		// 	// }
		// }
		.ant-form-item {
			margin-bottom: 10px;
		}
	}
	.z-live-tool {
		display: none;
		justify-content: space-between;
		position: absolute;
		top: 0;
		left: 0;
		width: 100%;
		z-index: 9;
		[data-handle] {
			cursor: move;
		}
	}
	$--item-default: 26px;
	$--item-sm: 20px;
	.z-live-tool-item {
		border-bottom: 1px dashed $--border-hover-color;
		height: $--item-default;
		width: $--item-default;
		text-align: center;
		line-height: $--item-default;
		cursor: pointer;
		display: inline-block;
		color: darken($--border-hover-color, 20%);
		&:hover {
			background-color: lighten($--border-hover-color, 20%);
		}
		&.all-border {
			border: 1px dashed $--border-hover-color;
		}
		&.left-item {
			border-right: 1px dashed $--border-hover-color;
		}
		&.right-item {
			border-left: 1px dashed $--border-hover-color;
		}

		&.small {
			font-size: 12px;
			width: $--item-sm;
			height: $--item-sm;
			line-height: $--item-sm;
		}
		$--delete-color: #f48cc5;
		&.delete {
			border-color: $--delete-color;
			color: darken($--delete-color, 20%);
			&:hover {
				background-color: lighten($--delete-color, 20%);
			}
		}
		$--remove-color: #83ced8;
		&.move {
			border-color: $--remove-color;
			color: darken($--remove-color, 20%);
			&:hover {
				background-color: lighten($--remove-color, 20%);
			}
		}
		$--tag-color: #debc58;
		&.tag {
			border-color: $--tag-color;
			color: darken($--tag-color, 20%);
			&:hover {
				background-color: lighten($--tag-color, 20%);
			}
		}
	}
	.z-liveform-upload-wrapper {
		display: block;
		border: 1px solid $border-color-base;
		border-radius: 4px;
		padding: 15px;
	}
	.z-liveform-upload {
		// .ant-upload-list.ant-upload-list-picture-card {
		// 	float: left;
		// }
		.ant-upload-list.ant-upload-list-picture-card .ant-upload-list-item-private {
			img {
				display: none;
			}
			&::before {
				content: "查看";
				display: block;
				position: absolute;
				top: 50%;
				left: 50%;
				transform: translate(-50%, -50%);
				z-index: 1;
			}
		}
		.ant-upload-list.ant-upload-list-picture-card .ant-upload-list-item-undetermined {
			border-color: $--orange;
		}
		.ant-upload-list.ant-upload-list-picture-card .ant-upload-list-item-done {
			border-color: $--green;
		}
		.ant-upload.ant-upload-select-picture {
			display: block;
		}
		.ant-upload-list.ant-upload-list-picture .ant-upload-list-item-undetermined {
			// border-color: #4BAFF0;
			&::before {
				font-size: 12px;
				display: block;
				color: $--orange;
				position: absolute;
				top: 50%;
				right: 30px;
				transform: translate(0, -50%);
				content: "待上传";
			}
		}
		$--done-w: 30px;
		$--done-color: $--green;
		.ant-upload-list.ant-upload-list-picture .ant-upload-list-item-done {
			&::before {
				display: block;
				border-radius: $--done-w / 2;
				width: $--done-w;
				text-align: center;
				line-height: $--done-w;
				height: $--done-w;
				// background-color: lighten($--done-color, 60%);
				color: $--done-color;
				position: absolute;
				top: 50%;
				right: 30px;
				transform: translate(0, -50%);
				content: "✔";
			}
		}
	}
	.z-liveform-upload-btn {
		display: flex;
		align-items: center;
		justify-content: center;
		height: 38px;
		border: 1px solid $border-color-base;
		border-radius: 4px;
		transition: all 0.25s ease;
		&:hover {
			border-color: $--blue;
			cursor: pointer;
		}
	}
	.z-group-insert {
		transform: rotate(-45deg);
	}

	.z-linkage-tab {
		background-color: white;
		.ant-tabs-bar {
			margin: 0;
		}
	}
	.z-linkage-line {
		border-width: 0 1px 1px;
		border-style: dashed;
		border-color: $--gray;
		height: 140px;
		text-align: left;
		padding: 6px 10px;
	}
	.z-linkage-remark {
		.ant-tag {
			margin-bottom: 5px;
		}
	}
	.z-linkage-config {
		.ant-select-selection-selected-value {
			.ant-tag {
				margin-top: 1px;
				font-size: 12px;
				height: 18px;
				line-height: 18px;
				overflow: hidden;
			}
		}
	}
	.z-link-configured {
		.ant-col {
			border-bottom: 1px solid $border-color-split;
			padding-top: 10px;
			padding-bottom: 10px;
		}
		.ant-tag {
			margin-bottom: 5px;
		}
	}
	.z-select-input {
		[class*="col-"] {
			padding: 0 !important;
			margin: 0;
			& > * {
				width: 100% !important;
			}
		}
		[class*="col-"]:not(:first-child) > * {
			border-top-left-radius: 0;
			border-bottom-left-radius: 0;
			.ant-select-selection {
				border-top-left-radius: 0;
				border-bottom-left-radius: 0;
			}
		}
		[class*="col-"]:not(:last-child) > * {
			border-top-right-radius: 0;
			border-bottom-right-radius: 0;
			.ant-select-selection {
				border-top-right-radius: 0;
				border-bottom-right-radius: 0;
			}
		}
		.hasvalue {
			border-color: $border-color-base;
		}
	}
}
