.template-row {
	display: grid;
	grid-template-columns: 32px 180px 320px 1fr;
	align-items: center;
	gap: 12px;
	padding: 6px 0;
	border-bottom: 1px solid #eee;
}

.template-name {
	font-weight: 600;
	white-space: nowrap;
}

.template-inputs {
	display: flex;
	gap: 6px;
	flex-wrap: wrap;
}

.template-inputs input {
	width: 90px;
	padding: 4px 6px;
	font-size: 13px;
}

.template-output {
	position: relative;
	white-space: nowrap;
	overflow: hidden;
	text-overflow: ellipsis;
	color: #555;
	cursor: pointer;
	padding: 5px 72px 5px 8px;
	border-radius: 6px;
}

.delete-btn {
	width: 32px;
	height: 32px;
	border: 1px solid #ddd;
	border-radius: 6px;
	background: #fff;
	cursor: pointer;
	font-size: 16px;
	line-height: 1;
}

.delete-btn:hover {
	background: #f7f7f7;
}

.template-output:hover,
.template-output:focus {
	background: #f7f7f7;
	outline: none;
}

.template-output.copied {
	background: #e8f7ee;
	color: #166534;
}

.template-output.copied::after {
	content: "Copied";
	position: absolute;
	right: 8px;
	top: 50%;
	transform: translateY(-50%);
	font-size: 12px;
	font-weight: 600;
}

.template-form {
	display: grid;
	gap: 10px;
	margin-top: 16px;
	padding: 14px;
	border: 1px solid #e5e5e5;
	border-radius: 8px;
	background: #fafafa;
}

.template-form[hidden] {
	display: none;
}

.template-form label {
	display: grid;
	gap: 5px;
	font-weight: 600;
}

.template-form input,
.template-form textarea {
	box-sizing: border-box;
	width: 100%;
	padding: 8px 10px;
	border: 1px solid #d8d8d8;
	border-radius: 6px;
	font: inherit;
}

.template-form textarea {
	min-height: 92px;
	resize: vertical;
}

.form-actions {
	display: flex;
	gap: 8px;
}

.how-to {
	margin-top: 24px;
	padding-top: 16px;
	border-top: 1px solid #eee;
	color: #444;
}

.how-to h2 {
	margin: 0 0 8px;
	font-size: 18px;
}

.how-to ul {
	margin: 0;
	padding-left: 20px;
}

.how-to li {
	margin: 6px 0;
}

.how-to code {
	padding: 1px 4px;
	border-radius: 4px;
	background: #f3f3f3;
}
