:root {
	--wt-bg: #08111c;
	--wt-rail: #102338;
	--wt-ink: #f8fbff;
	--wt-muted: #b9c8d8;
	--wt-line: rgba(122, 188, 230, 0.28);
	--wt-cyan: #20a4d8;
	--wt-green: #3bc7aa;
	--wt-paper: #f7fbff;
}

.wt-shell .wt-frame-maker {
	width: 100%;
	margin: 0;
}

.wt-shell .wt-hero {
	margin-bottom: 16px;
}

.wt-shell .wt-editor-head,
.wt-shell .wt-guide,
.wt-shell .wt-editor-shell,
.wt-shell .wt-library {
	margin-top: 16px;
}

.wt-shell .wt-library[hidden] + .wt-editor {
	margin-top: 0;
}

.wt-shell .wt-template-card {
	min-height: 100%;
}

.wt-shell .wt-template-warning {
	display: none;
}

.screen-reader-text {
	position: absolute;
	width: 1px;
	height: 1px;
	padding: 0;
	overflow: hidden;
	clip: rect(0, 0, 0, 0);
	white-space: nowrap;
	border: 0;
}

@media (max-width: 780px) {
	.wt-topbar,
	.wt-shell {
		width: calc(100vw - 16px);
	}

	.wt-topbar {
		margin-top: 8px;
		padding: 10px;
	}

	.wt-brand strong {
		font-size: 16px;
	}

	.wt-topbar nav a {
		padding: 8px;
		font-size: 12px;
	}

	.wt-shell {
		margin-top: 14px;
		margin-bottom: 24px;
	}
}

html {
	scroll-behavior: smooth;
}

body {
	min-height: 100vh;
	margin: 0;
	background:
		radial-gradient(circle at 16% 0%, rgba(32, 164, 216, 0.18), transparent 30%),
		linear-gradient(135deg, #07101b 0%, #101b2b 48%, #07101b 100%);
	color: var(--wt-ink);
	font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

.wt-topbar {
	position: sticky;
	top: 0;
	z-index: 30;
	display: flex;
	align-items: center;
	justify-content: space-between;
	width: min(1320px, calc(100vw - 48px));
	margin: 10px auto 0;
	padding: 12px 14px;
	border: 1px solid var(--wt-line);
	border-radius: 8px;
	background: rgba(7, 16, 27, 0.88);
	backdrop-filter: blur(16px);
	box-shadow: 0 18px 38px rgba(0, 0, 0, 0.24);
}

.wt-brand {
	display: inline-flex;
	gap: 10px;
	align-items: center;
	color: var(--wt-ink);
	text-decoration: none;
}

.wt-brand span {
	display: grid;
	place-items: center;
	width: 38px;
	height: 38px;
	border: 1px solid rgba(59, 199, 170, 0.5);
	border-radius: 8px;
	background: linear-gradient(135deg, rgba(32, 164, 216, 0.32), rgba(59, 199, 170, 0.2));
	color: #eafffb;
	font-weight: 900;
}

.wt-brand strong {
	font-size: 19px;
	letter-spacing: 0;
}

.wt-topbar nav {
	display: flex;
	gap: 8px;
}

.wt-topbar nav a {
	padding: 9px 11px;
	border-radius: 8px;
	color: var(--wt-muted);
	font-size: 14px;
	font-weight: 800;
	text-decoration: none;
}

.wt-topbar nav a:hover,
.wt-topbar nav a:focus-visible {
	background: rgba(255, 255, 255, 0.08);
	color: var(--wt-ink);
	outline: none;
}

.wt-shell {
	width: min(1320px, calc(100vw - 48px));
	margin: 34px auto 56px;
}

.wt-frame-maker {
	--wt-ink: #071421;
	--wt-muted: #557086;
	--wt-soft: #eef7fb;
	--wt-line: #d8e6ef;
	--wt-card: #ffffff;
	--wt-panel: #f8fcff;
	--wt-blue: #1497d4;
	--wt-blue-dark: #0b6f9f;
	--wt-mint: #22b8a7;
	--wt-coral: #ff6b6b;
	--wt-shadow: 0 14px 34px rgba(2, 12, 27, 0.18);
	color: var(--wt-ink);
	font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
	width: min(1320px, calc(100vw - 96px));
	max-width: none;
	margin-left: calc(50% - min(1320px, calc(100vw - 96px)) / 2);
	margin-right: calc(50% - min(1320px, calc(100vw - 96px)) / 2);
}

body:has(.wt-frame-maker) .wt-page-header {
	display: none;
}

body:has(.wt-frame-maker) .wt-entry-content {
	max-width: none;
}

.wt-frame-maker *,
.wt-frame-maker *::before,
.wt-frame-maker *::after {
	box-sizing: border-box;
}

.wt-frame-maker [hidden] {
	display: none !important;
}

.wt-hero {
	display: grid;
	grid-template-columns: minmax(0, 1fr) auto;
	gap: 14px;
	align-items: center;
	padding: 14px 16px;
	border: 1px solid rgba(216, 230, 239, 0.9);
	border-radius: 8px;
	background:
		linear-gradient(135deg, rgba(255, 255, 255, 0.98) 0%, rgba(241, 250, 255, 0.96) 56%, rgba(255, 250, 238, 0.96) 100%);
	box-shadow: 0 10px 28px rgba(2, 12, 27, 0.12);
}

.wt-frame-kicker {
	margin: 0 0 6px;
	color: var(--wt-blue-dark);
	font-size: 12px;
	font-weight: 900;
	text-transform: uppercase;
	letter-spacing: 0;
}

.wt-frame-kicker:empty {
	display: none;
}

.wt-hero h2,
.wt-editor h3 {
	margin: 0;
	color: var(--wt-ink);
	font-size: 30px;
	line-height: 1.05;
	letter-spacing: 0;
}

.wt-hero p,
.wt-editor-head p {
	max-width: 680px;
	margin: 6px 0 0;
	color: var(--wt-muted);
	font-size: 14px;
	line-height: 1.45;
}

.wt-hero-note {
	position: relative;
	max-width: 260px;
	padding: 9px 12px 9px 34px;
	border: 1px solid rgba(34, 184, 167, 0.26);
	background: rgba(255, 255, 255, 0.78);
	border-radius: 999px;
	color: #174d4a;
	font-size: 12px;
	font-weight: 850;
	line-height: 1.35;
}

.wt-hero-note::before {
	content: "";
	position: absolute;
	left: 12px;
	top: 50%;
	width: 14px;
	height: 16px;
	transform: translateY(-50%);
	background: var(--wt-mint);
	clip-path: polygon(50% 0, 92% 18%, 84% 74%, 50% 100%, 16% 74%, 8% 18%);
}

.wt-alert,
.wt-template-warning {
	margin: 12px 0;
	padding: 11px 13px;
	border: 1px solid rgba(255, 107, 107, 0.36);
	border-radius: 8px;
	background: #fff2f2;
	color: #7a1f1f;
	font-size: 13px;
	line-height: 1.45;
}

.wt-template-warning {
	border-color: rgba(20, 151, 212, 0.32);
	background: #eef8ff;
	color: #16435e;
}

.wt-toolbar {
	display: grid;
	grid-template-columns: minmax(0, 1fr) minmax(180px, 260px) minmax(150px, 220px);
	gap: 12px;
	align-items: center;
	margin: 18px 0;
}

.wt-filter-group {
	display: flex;
	gap: 8px;
	flex-wrap: wrap;
}

.wt-filter-group button,
.wt-tool-grid button,
.wt-slot-row,
.wt-button,
.wt-file-button {
	min-height: 42px;
	border: 1px solid var(--wt-line);
	border-radius: 8px;
	background: var(--wt-card);
	color: var(--wt-ink);
	font: inherit;
	font-size: 14px;
	font-weight: 850;
	cursor: pointer;
	text-decoration: none;
	transition: transform 120ms ease, border-color 120ms ease, background 120ms ease, color 120ms ease;
}

.wt-filter-group button {
	padding: 0 12px;
}

.wt-filter-group button:hover,
.wt-tool-grid button:hover,
.wt-slot-row:hover,
.wt-button:hover,
.wt-file-button:hover {
	transform: translateY(-1px);
	border-color: rgba(20, 151, 212, 0.55);
}

.wt-filter-group button.is-active {
	border-color: var(--wt-blue);
	background: #eaf7ff;
	color: #07577d;
}

.wt-search input,
.wt-category-filter select,
.wt-tool-panel select,
.wt-tool-panel input[type="text"],
.wt-tool-panel input[type="number"],
.wt-tool-panel input[type="color"],
.wt-tool-panel textarea,
.wt-tool-panel input[type="range"] {
	width: 100%;
	min-height: 42px;
	border: 1px solid var(--wt-line);
	border-radius: 8px;
	background: #fff;
	color: var(--wt-ink);
	padding: 0 12px;
}

.wt-tool-panel textarea {
	min-height: 82px;
	padding: 9px 11px;
	resize: vertical;
}

.wt-tool-panel input[type="color"] {
	padding: 3px;
}

.wt-template-grid {
	display: grid;
	grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
	gap: 16px;
}

.wt-template-card {
	display: grid;
	gap: 12px;
	padding: 12px;
	border: 1px solid rgba(216, 230, 239, 0.92);
	border-radius: 8px;
	background: var(--wt-card);
	box-shadow: 0 10px 26px rgba(2, 12, 27, 0.12);
}

.wt-thumb {
	aspect-ratio: 4 / 5;
	display: grid;
	place-items: center;
	border-radius: 6px;
	overflow: hidden;
	background: #f8fbfd;
}

.wt-thumb img {
	width: 100%;
	height: 100%;
	object-fit: cover;
	display: block;
}

.wt-card-body {
	display: flex;
	justify-content: space-between;
	gap: 12px;
	align-items: start;
}

.wt-card-body h3 {
	margin: 0 0 4px;
	color: var(--wt-ink);
	font-size: 16px;
	line-height: 1.25;
}

.wt-card-body p {
	margin: 0;
	color: var(--wt-muted);
	font-size: 13px;
}

.wt-card-body span {
	flex: 0 0 auto;
	padding: 5px 8px;
	border-radius: 999px;
	background: #fff5d8;
	color: #744a00;
	font-size: 12px;
	font-weight: 900;
}

.wt-button,
.wt-file-button {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	gap: 8px;
	padding: 0 14px;
}

.wt-button-primary {
	border-color: var(--wt-blue);
	background: var(--wt-blue);
	color: #fff;
}

.wt-button-primary:hover {
	background: var(--wt-blue-dark);
	color: #fff;
}

.wt-button-light {
	background: #fff;
}

.wt-editor {
	margin-top: 18px;
}

.wt-editor-head {
	display: flex;
	justify-content: flex-end;
	gap: 16px;
	align-items: end;
	margin-bottom: 14px;
	padding: 10px 12px;
	border: 1px solid rgba(216, 230, 239, 0.9);
	border-radius: 8px;
	background: rgba(255, 255, 255, 0.96);
}

.wt-editor-title-status {
	display: none;
}

.wt-editor h3 {
	font-size: 26px;
}

.wt-editor-actions {
	display: flex;
	gap: 10px;
	flex-wrap: wrap;
}

.wt-editor-actions input,
.wt-file-button input,
.wt-button input {
	position: absolute;
	inline-size: 1px;
	block-size: 1px;
	opacity: 0;
	pointer-events: none;
}

.wt-guide {
	margin: 0 0 14px;
	border: 1px solid rgba(216, 230, 239, 0.94);
	border-radius: 8px;
	background: rgba(255, 255, 255, 0.96);
	box-shadow: 0 10px 28px rgba(2, 12, 27, 0.10);
}

.wt-guide summary {
	min-height: 44px;
	display: flex;
	align-items: center;
	gap: 8px;
	padding: 0 14px;
	color: var(--wt-ink);
	font-weight: 900;
	cursor: pointer;
}

.wt-guide-grid {
	display: grid;
	grid-template-columns: repeat(3, minmax(0, 1fr));
	gap: 10px;
	padding: 0 14px 14px;
}

.wt-guide-grid div {
	padding: 10px;
	border: 1px solid var(--wt-line);
	border-radius: 8px;
	background: #f8fbfd;
}

.wt-guide-visual {
	display: grid;
	place-items: center;
	width: 48px;
	height: 48px;
	margin-bottom: 8px;
	border: 1px solid rgba(31, 162, 212, 0.20);
	border-radius: 8px;
	background: linear-gradient(135deg, #eaf7ff, #fff8e9);
	color: var(--wt-blue-dark);
}

.wt-guide-visual svg {
	display: block;
	width: 34px;
	height: 34px;
}

.wt-guide-visual rect,
.wt-guide-visual path,
.wt-guide-visual circle {
	fill: none;
	stroke: currentColor;
	stroke-width: 3;
	stroke-linecap: round;
	stroke-linejoin: round;
}

.wt-guide-grid strong {
	display: block;
	margin-bottom: 5px;
	color: var(--wt-blue-dark);
	font-size: 13px;
}

.wt-guide-grid p {
	margin: 0;
	color: var(--wt-muted);
	font-size: 13px;
	line-height: 1.45;
}

.wt-guide-close-wrap {
	display: flex;
	justify-content: center;
	padding: 0 14px 14px;
}

.wt-guide-close {
	min-height: 36px;
	border: 1px solid rgba(20, 151, 212, 0.36);
	border-radius: 8px;
	background: #eaf7ff;
	color: var(--wt-blue-dark);
	font: inherit;
	font-size: 13px;
	font-weight: 900;
	padding: 0 14px;
	cursor: pointer;
}

.wt-editor-shell {
	--wt-sticky-top: 12px;
	display: grid;
	grid-template-columns: minmax(680px, 1fr) 300px;
	grid-template-areas:
		"canvas tools"
		"text tools"
		"slots tools";
	gap: 14px;
	align-items: start;
}

.wt-slot-panel,
.wt-text-panel,
.wt-tool-panel,
.wt-canvas-panel {
	border: 1px solid rgba(216, 230, 239, 0.94);
	border-radius: 8px;
	background: rgba(255, 255, 255, 0.98);
	padding: 12px;
	box-shadow: 0 10px 28px rgba(2, 12, 27, 0.12);
}

.wt-slot-panel {
	grid-area: slots;
}

.wt-text-panel {
	grid-area: text;
}

.wt-canvas-panel {
	grid-area: canvas;
	min-width: 0;
	position: sticky;
	top: var(--wt-sticky-top);
	z-index: 2;
}

.wt-preview-zoom-bar {
	display: none;
	justify-content: flex-end;
	gap: 6px;
	margin-bottom: 8px;
}

.wt-preview-zoom-bar button {
	min-height: 34px;
	border: 1px solid var(--wt-line);
	border-radius: 8px;
	background: #fff;
	color: var(--wt-ink);
	font: inherit;
	font-size: 12px;
	font-weight: 850;
	padding: 0 10px;
	cursor: pointer;
}

.wt-preview-zoom-bar button.is-active {
	border-color: var(--wt-blue);
	background: #eaf7ff;
	color: var(--wt-blue-dark);
}

.wt-tool-panel {
	grid-area: tools;
	position: sticky;
	top: var(--wt-sticky-top);
	max-height: calc(100vh - var(--wt-sticky-top) - 12px);
	overflow-y: auto;
	overscroll-behavior: contain;
	z-index: 3;
}

.wt-slot-list {
	display: grid;
	grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
	gap: 8px;
}

.wt-slot-row {
	width: 100%;
	display: grid;
	grid-template-columns: minmax(0, 1fr) auto;
	align-items: center;
	gap: 8px;
	padding: 10px;
	text-align: left;
}

.wt-slot-row span {
	overflow-wrap: anywhere;
}

.wt-slot-row.is-active {
	border-color: var(--wt-blue);
	background: #eff9ff;
	box-shadow: 0 0 0 2px rgba(20, 151, 212, 0.16);
}

.wt-slot-row strong {
	color: var(--wt-blue-dark);
	font-size: 12px;
}

.wt-text-panel-head {
	margin-bottom: 12px;
}

.wt-text-panel h4 {
	margin: 0;
	font-size: 15px;
	color: var(--wt-ink);
}

.wt-text-panel p {
	margin: 5px 0 0;
	color: var(--wt-muted);
	font-size: 13px;
	line-height: 1.45;
}

.wt-text-fields {
	display: grid;
	grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
	gap: 10px;
}

.wt-text-field {
	display: grid;
	gap: 6px;
	color: var(--wt-ink);
	font-size: 13px;
	font-weight: 850;
}

.wt-text-field input,
.wt-text-field textarea {
	width: 100%;
	min-height: 42px;
	border: 1px solid var(--wt-line);
	border-radius: 8px;
	background: #fff;
	color: var(--wt-ink);
	padding: 9px 11px;
	font: inherit;
	font-weight: 600;
}

.wt-text-field textarea {
	min-height: 86px;
	resize: vertical;
}

.wt-drop-zone {
	position: relative;
	display: grid;
	place-items: center;
	min-height: 0;
	border-radius: 8px;
	background: #f7fafc;
	overflow: visible;
	padding: 12px;
}

.wt-drop-zone.is-dragging {
	outline: 3px solid var(--wt-mint);
	outline-offset: 2px;
}

.wt-drop-zone canvas {
	display: block;
	max-width: none;
	width: auto;
	height: auto;
	touch-action: none;
	border-radius: 6px;
	background: #fff;
	box-shadow: 0 8px 22px rgba(2, 12, 27, 0.16);
	cursor: move;
	transform-origin: center center;
	will-change: transform;
}

.wt-drop-zone canvas.is-transforming {
	cursor: grabbing;
}

.wt-inline-text-editor {
	min-width: 0;
	min-height: 0;
	border: 1px dashed rgba(20, 151, 212, 0.94);
	border-radius: 2px;
	background: transparent;
	box-shadow: none;
	line-height: 1.12;
	padding: 0;
	resize: none;
	outline: none;
	overflow: hidden;
	caret-color: #111111;
	text-shadow: none;
	transform-origin: top left;
}

.wt-canvas-loading {
	position: absolute;
	inset: 16px;
	display: grid;
	place-items: center;
	background: rgba(255, 255, 255, 0.84);
	border-radius: 8px;
	color: var(--wt-ink);
	font-weight: 900;
}

.wt-tool-panel {
	display: grid;
	gap: 12px;
}

.wt-tool-section {
	display: grid;
	gap: 10px;
	padding-bottom: 12px;
	border-bottom: 1px solid var(--wt-line);
}

.wt-tool-section:last-child {
	border-bottom: 0;
	padding-bottom: 0;
}

.wt-tool-section h4 {
	margin: 0;
	color: var(--wt-ink);
	font-size: 14px;
}

.wt-tool-section label {
	display: grid;
	gap: 7px;
	color: var(--wt-ink);
	font-size: 13px;
	font-weight: 850;
}

.wt-tool-grid {
	display: grid;
	grid-template-columns: repeat(2, minmax(0, 1fr));
	gap: 8px;
}

.wt-tool-grid button,
.wt-file-button {
	line-height: 1.2;
}

.wt-free-image-controls,
.wt-user-text-controls {
	display: grid;
	gap: 10px;
}

.wt-free-image-controls p {
	margin: 0;
	color: var(--wt-muted);
	font-size: 13px;
	line-height: 1.45;
}

.wt-free-image-controls p:not([data-free-image-status]) {
	display: none;
}

.wt-free-image-controls[hidden],
.wt-user-text-controls[hidden] {
	display: none !important;
}

.wt-free-image-tools .wt-file-button,
.wt-free-image-tools .wt-button,
.wt-user-text-tools .wt-button {
	width: 100%;
}

.wt-user-text-tools button.is-active {
	border-color: var(--wt-blue);
	background: #eaf7ff;
	color: var(--wt-blue-dark);
}

.wt-download {
	width: 100%;
}

.wt-empty {
	padding: 24px;
	border: 1px dashed var(--wt-line);
	border-radius: 8px;
	background: rgba(255, 255, 255, 0.92);
	text-align: center;
	color: var(--wt-muted);
}

.wt-frame-maker button:focus-visible,
.wt-frame-maker input:focus-visible,
.wt-frame-maker select:focus-visible {
	outline: 3px solid rgba(20, 151, 212, 0.42);
	outline-offset: 2px;
}

@media (max-width: 1020px) {
	.wt-guide-grid {
		grid-template-columns: repeat(2, minmax(0, 1fr));
	}

	.wt-editor-shell {
		grid-template-columns: 1fr;
		grid-template-areas:
			"canvas"
			"tools"
			"text"
			"slots";
	}

	.wt-slot-panel {
		order: initial;
	}

	.wt-canvas-panel {
		position: static;
		order: initial;
	}

	.wt-tool-panel {
		position: sticky;
		top: 12px;
		max-height: calc(100vh - 24px);
		overflow-y: auto;
		order: initial;
	}
}

@media (max-width: 780px) {
	.wt-frame-maker {
		width: calc(100vw - 24px);
		margin-left: calc(50% - 50vw + 12px);
		margin-right: calc(50% - 50vw + 12px);
	}

	.wt-toolbar,
	.wt-hero {
		grid-template-columns: 1fr;
	}

	.wt-hero-note {
		max-width: none;
		width: fit-content;
	}

	.wt-editor-head {
		align-items: start;
		flex-direction: column;
	}

	.wt-editor-shell {
		gap: 10px;
	}

	.wt-drop-zone {
		overflow: hidden;
		padding: 8px;
		min-height: 220px;
		touch-action: none;
	}

	.wt-preview-zoom-bar {
		display: flex;
		justify-content: center;
		margin-bottom: 6px;
	}

	.wt-preview-zoom-bar button {
		min-height: 32px;
		font-size: 12px;
		padding-inline: 9px;
	}

	.wt-tool-panel {
		position: sticky;
		top: auto;
		bottom: 0;
		z-index: 40;
		grid-template-columns: repeat(2, minmax(0, 1fr));
		gap: 8px;
		max-height: 38vh;
		padding: 9px;
		-webkit-overflow-scrolling: touch;
		border-radius: 10px 10px 0 0;
		box-shadow: 0 -12px 30px rgba(2, 12, 27, 0.18);
	}

	.wt-tool-section {
		gap: 6px;
		padding-bottom: 0;
		border-bottom: 0;
	}

	.wt-tool-section h4 {
		font-size: 12px;
		line-height: 1.1;
	}

	.wt-tool-section label {
		gap: 4px;
		font-size: 12px;
	}

	.wt-tool-section label span {
		line-height: 1.1;
	}

	.wt-tool-grid {
		gap: 6px;
	}

	.wt-filter-group button,
	.wt-tool-grid button,
	.wt-button,
	.wt-file-button {
		min-height: 36px;
		font-size: 12px;
		padding: 0 8px;
	}

	.wt-tool-panel select,
	.wt-tool-panel input[type="text"],
	.wt-tool-panel input[type="number"],
	.wt-tool-panel input[type="color"],
	.wt-tool-panel textarea,
	.wt-tool-panel input[type="range"] {
		min-height: 36px;
		font-size: 12px;
		padding-inline: 8px;
	}

	.wt-tool-panel textarea {
		min-height: 46px;
		max-height: 58px;
		padding: 6px 8px;
	}

	.wt-free-image-controls,
	.wt-user-text-controls {
		gap: 6px;
	}

	.wt-free-image-controls p {
		display: none;
	}

	.wt-user-text-tools,
	.wt-free-image-tools {
		align-content: start;
	}

	.wt-tool-section.is-expanded {
		grid-column: 1 / -1;
		display: grid;
		grid-template-columns: repeat(2, minmax(0, 1fr));
		align-items: start;
		gap: 6px;
		padding: 7px;
		border: 1px solid rgba(216, 230, 239, 0.92);
		border-radius: 8px;
		background: rgba(248, 252, 255, 0.96);
	}

	.wt-tool-section.is-expanded > h4 {
		grid-column: 1;
		align-self: center;
	}

	.wt-tool-section.is-expanded > .wt-button,
	.wt-tool-section.is-expanded > .wt-file-button {
		grid-column: 2;
	}

	.wt-tool-section.is-expanded .wt-free-image-controls,
	.wt-tool-section.is-expanded .wt-user-text-controls {
		grid-column: 1 / -1;
		display: grid;
		grid-template-columns: repeat(2, minmax(0, 1fr));
		gap: 6px;
	}

	.wt-tool-section.is-expanded .wt-free-image-controls > *,
	.wt-tool-section.is-expanded .wt-user-text-controls > * {
		grid-column: 1 / -1;
	}

	.wt-tool-panel > .wt-tool-section:last-child {
		grid-column: 1 / -1;
		display: grid;
		grid-template-columns: minmax(0, 1fr) minmax(0, 1fr) auto;
		align-items: end;
		gap: 7px;
	}

	.wt-tool-panel > .wt-tool-section:last-child .wt-download {
		min-width: 96px;
	}

	.wt-inline-text-editor {
		border-width: 1px;
	}
}

@media (max-width: 560px) {
	.wt-frame-maker {
		width: calc(100vw - 12px);
		margin-left: calc(50% - 50vw + 6px);
		margin-right: calc(50% - 50vw + 6px);
	}

	.wt-hero h2 {
		font-size: 24px;
	}

	.wt-hero p {
		font-size: 13px;
	}

	.wt-editor h3 {
		font-size: 22px;
	}

	.wt-hero,
	.wt-editor-head,
	.wt-slot-panel,
	.wt-text-panel,
	.wt-tool-panel,
	.wt-canvas-panel {
		padding: 12px;
	}

	.wt-template-grid {
		grid-template-columns: 1fr;
	}

	.wt-guide-grid {
		grid-template-columns: 1fr;
	}

	.wt-filter-group button {
		flex: 1 1 calc(50% - 8px);
	}

	.wt-drop-zone {
		min-height: 260px;
		max-height: none;
	}

	.wt-tool-panel {
		max-height: 42vh;
		padding: 8px;
	}

	.wt-tool-panel > .wt-tool-section:last-child {
		grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
	}

	.wt-tool-panel > .wt-tool-section:last-child .wt-download {
		grid-column: 1 / -1;
	}
}

.wt-shell .wt-frame-maker {
	width: 100%;
	margin: 0;
}

.wt-shell .wt-hero {
	margin-bottom: 16px;
}

.wt-shell .wt-editor-head,
.wt-shell .wt-guide,
.wt-shell .wt-editor-shell,
.wt-shell .wt-library {
	margin-top: 16px;
}

.wt-shell .wt-template-warning {
	display: none;
}

.screen-reader-text {
	position: absolute;
	width: 1px;
	height: 1px;
	padding: 0;
	overflow: hidden;
	clip: rect(0, 0, 0, 0);
	white-space: nowrap;
	border: 0;
}

@media (max-width: 780px) {
	.wt-topbar,
	.wt-shell {
		width: calc(100vw - 16px);
	}

	.wt-topbar {
		margin-top: 8px;
		padding: 10px;
	}

	.wt-brand strong {
		font-size: 16px;
	}

	.wt-topbar nav a {
		padding: 8px;
		font-size: 12px;
	}

	.wt-shell {
		margin-top: 14px;
		margin-bottom: 24px;
	}

	.wt-shell .wt-frame-maker {
		width: 100%;
		margin-left: 0;
		margin-right: 0;
	}
}

body.home-page {
	--home-ink: #101936;
	--home-muted: #66708f;
	--home-purple: #6438f2;
	--home-purple-dark: #4e22dc;
	--home-line: #e9edf7;
	--home-soft: #f7f8ff;
	--home-card: #ffffff;
	--home-content-width: min(1420px, calc(100vw - 88px));
	min-height: 100vh;
	background:
		radial-gradient(circle at 8% 13%, rgba(235, 230, 255, 0.72), transparent 18rem),
		radial-gradient(circle at 94% 8%, rgba(239, 231, 255, 0.85), transparent 20rem),
		linear-gradient(180deg, #ffffff 0%, #fbfcff 42%, #f8faff 100%);
	color: var(--home-ink);
	font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

body.editor-page {
	background:
		radial-gradient(circle at 8% 10%, rgba(235, 230, 255, 0.72), transparent 18rem),
		linear-gradient(180deg, #ffffff 0%, #f6f8ff 100%);
}

.editor-page .tool-stage {
	margin-top: 26px;
}

.editor-page .tool-stage .wt-hero {
	display: none;
}

.site-header {
	position: sticky;
	top: 0;
	z-index: 50;
	display: grid;
	grid-template-columns: auto minmax(0, 1fr) auto;
	gap: 28px;
	align-items: center;
	padding: 18px 38px;
	border-bottom: 1px solid var(--home-line);
	background: rgba(255, 255, 255, 0.92);
	backdrop-filter: blur(18px);
	box-shadow: 0 12px 30px rgba(74, 82, 118, 0.08);
}

.site-logo {
	display: inline-flex;
	align-items: center;
	gap: 12px;
	color: var(--home-ink);
	text-decoration: none;
}

.site-logo-mark {
	display: grid;
	place-items: center;
	width: 48px;
	height: 48px;
	border-radius: 13px;
	overflow: hidden;
	box-shadow: 0 10px 20px rgba(27, 20, 48, 0.18);
}

.site-logo-mark img {
	display: block;
	width: 100%;
	height: 100%;
	object-fit: contain;
}

.site-logo strong {
	color: var(--home-ink);
	font-size: 28px;
	line-height: 1;
	letter-spacing: -0.02em;
}

.site-logo strong span {
	color: var(--home-purple);
}

.site-nav {
	display: flex;
	justify-content: center;
	gap: 38px;
}

.site-nav a,
.signin-link,
.section-heading a,
.site-footer a {
	color: var(--home-ink);
	font-weight: 800;
	text-decoration: none;
}

.site-nav a {
	font-size: 15px;
}

.header-actions {
	display: flex;
	align-items: center;
	gap: 8px;
}

.header-search {
	position: relative;
	display: flex;
	align-items: center;
	width: 250px;
}

.header-search input,
.hero-search input,
.footer-form input {
	width: 100%;
	border: 1px solid var(--home-line);
	background: #ffffff;
	color: var(--home-ink);
	font: inherit;
	outline: none;
}

.header-search input {
	height: 42px;
	padding: 0 42px 0 46px;
	border-radius: 10px;
	box-shadow: 0 8px 18px rgba(93, 101, 133, 0.08);
}

.header-search svg,
.hero-search > svg {
	position: absolute;
	width: 20px;
	height: 20px;
	fill: none;
	stroke: #536386;
	stroke-width: 2.4;
	stroke-linecap: round;
}

.header-search svg {
	left: 16px;
}

.signin-link {
	display: inline-flex;
	align-items: center;
	height: 42px;
	padding: 0 16px;
	border: 1px solid var(--home-line);
	border-radius: 10px;
	background: #ffffff;
	font-size: 14px;
}

.primary-pill {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	min-height: 42px;
	padding: 0 20px;
	border: 0;
	border-radius: 10px;
	background: linear-gradient(135deg, #7048ff, #5428e9);
	color: #ffffff;
	font: inherit;
	font-size: 14px;
	font-weight: 900;
	cursor: pointer;
	box-shadow: 0 12px 22px rgba(100, 56, 242, 0.25);
}

.home-hero {
	position: relative;
	overflow: hidden;
	min-height: 235px;
	padding: 44px 24px 34px;
	text-align: center;
	background:
		radial-gradient(circle at 6% 78%, rgba(255, 255, 255, 0.95) 0 66px, transparent 68px),
		radial-gradient(circle at 91% 42%, rgba(255, 255, 255, 0.92) 0 72px, transparent 74px),
		linear-gradient(135deg, #fbfbff 0%, #f4efff 55%, #fdfcff 100%);
}

.home-hero h1 {
	position: relative;
	max-width: 880px;
	margin: 0 auto 12px;
	color: var(--home-ink);
	font-size: clamp(34px, 5vw, 48px);
	line-height: 1.05;
	letter-spacing: -0.04em;
}

.home-hero p {
	position: relative;
	margin: 0 auto 30px;
	color: #293351;
	font-size: 19px;
	font-weight: 700;
}

.hero-search {
	position: relative;
	z-index: 1;
	display: grid;
	grid-template-columns: 1fr 64px;
	align-items: center;
	width: min(790px, calc(100vw - 44px));
	height: 64px;
	margin: 0 auto;
	border-radius: 12px;
	background: #ffffff;
	box-shadow: 0 15px 32px rgba(96, 88, 138, 0.16);
}

.hero-search > svg {
	left: 22px;
}

.hero-search input {
	height: 64px;
	padding: 0 18px 0 62px;
	border: 0;
	border-radius: 12px 0 0 12px;
	font-size: 16px;
	font-weight: 700;
}

.hero-search button {
	display: grid;
	place-items: center;
	width: 64px;
	height: 64px;
	border: 0;
	border-radius: 0 12px 12px 0;
	background: linear-gradient(135deg, #7048ff, #5428e9);
	cursor: pointer;
}

.hero-search button svg {
	width: 24px;
	height: 24px;
	fill: none;
	stroke: #ffffff;
	stroke-width: 2.4;
	stroke-linecap: round;
}

.hero-spark {
	position: absolute;
	width: 18px;
	height: 18px;
}

.hero-spark::before,
.hero-spark::after {
	content: "";
	position: absolute;
	background: currentColor;
	border-radius: 999px;
}

.hero-spark::before {
	left: 7px;
	top: 0;
	width: 4px;
	height: 18px;
}

.hero-spark::after {
	left: 0;
	top: 7px;
	width: 18px;
	height: 4px;
}

.hero-spark-a {
	left: 15%;
	top: 42px;
	color: #7f58ff;
}

.hero-spark-b {
	right: 16%;
	top: 94px;
	color: #f8b400;
}

.hero-spark-c {
	right: 10%;
	bottom: 54px;
	color: #a88bff;
}

.category-strip {
	display: flex;
	gap: 13px;
	width: var(--home-content-width);
	margin-inline: auto;
	overflow-x: auto;
	padding: 30px 0 18px;
}

.category-strip button {
	flex: 0 0 auto;
	min-height: 49px;
	padding: 0 24px;
	border: 1px solid var(--home-line);
	border-radius: 999px;
	background: #ffffff;
	color: var(--home-ink);
	font: inherit;
	font-size: 14px;
	font-weight: 900;
	cursor: pointer;
	box-shadow: 0 8px 18px rgba(74, 82, 118, 0.08);
}

.category-strip button.is-active {
	border-color: transparent;
	background: linear-gradient(135deg, #7048ff, #5428e9);
	color: #ffffff;
	box-shadow: 0 12px 24px rgba(100, 56, 242, 0.26);
}

.template-catalog {
	width: var(--home-content-width);
	margin: 0 auto;
}

.template-section {
	padding: 20px 20px 22px;
	border: 1px solid var(--home-line);
	border-radius: 14px;
	background: rgba(255, 255, 255, 0.92);
	box-shadow: 0 12px 28px rgba(74, 82, 118, 0.06);
}

.template-section + .template-section {
	margin-top: 22px;
}

.section-heading {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 18px;
	margin-bottom: 18px;
}

.section-heading h2 {
	margin: 0;
	color: var(--home-ink);
	font-size: 26px;
	letter-spacing: -0.02em;
}

.section-heading a {
	color: var(--home-purple);
}

.template-row {
	display: grid;
	grid-template-columns: repeat(4, minmax(0, 1fr));
	gap: 24px;
}

.home-card {
	overflow: hidden;
	border: 1px solid var(--home-line);
	border-radius: 10px;
	background: #ffffff;
	cursor: pointer;
	box-shadow: 0 12px 24px rgba(74, 82, 118, 0.07);
	transition: transform 180ms ease, box-shadow 180ms ease;
}

.home-card:hover,
.home-card:focus-within {
	transform: translateY(-3px);
	box-shadow: 0 18px 30px rgba(74, 82, 118, 0.13);
}

.home-card img {
	display: block;
	width: 100%;
	aspect-ratio: 16 / 9;
	object-fit: cover;
	background: linear-gradient(135deg, var(--card-a, #f5f0ff), var(--card-b, #edf7ff));
	mix-blend-mode: multiply;
}

.home-card div {
	padding: 13px 14px 15px;
}

.home-card h3 {
	margin: 0 0 6px;
	color: var(--home-ink);
	font-size: 15px;
	line-height: 1.2;
}

.home-card p {
	margin: 0;
	color: var(--home-muted);
	font-size: 13px;
	font-weight: 800;
}

.card-rose { --card-a: #ffe1ea; --card-b: #fff4f7; }
.card-sky { --card-a: #d8efff; --card-b: #fff3e0; }
.card-violet { --card-a: #eadfff; --card-b: #fff3fb; }
.card-candy { --card-a: #ffe6f1; --card-b: #dff6ff; }
.card-pink { --card-a: #ffe1ec; --card-b: #fff7fb; }
.card-red { --card-a: #ffd9d9; --card-b: #fff2f2; }
.card-coral { --card-a: #ffc8c8; --card-b: #fff0f0; }
.card-warm { --card-a: #fff0dc; --card-b: #fffaf2; }
.card-leaf { --card-a: #e4f8df; --card-b: #fff6e5; }
.card-linen { --card-a: #fff1d9; --card-b: #f6fff3; }
.card-peach { --card-a: #ffe1d2; --card-b: #fff8eb; }
.card-blue { --card-a: #dff4ff; --card-b: #fff9e4; }
.card-night { --card-a: #dce7ff; --card-b: #eef3ff; }
.card-kawaii { --card-a: #ffe4f0; --card-b: #fff5f9; }
.card-action { --card-a: #ffe4c9; --card-b: #e7efff; }
.card-moon { --card-a: #d8e8ff; --card-b: #fff2d6; }
.card-beach { --card-a: #d6f5ff; --card-b: #fff0cf; }
.card-paris { --card-a: #e4f1ff; --card-b: #fff1df; }
.card-world { --card-a: #dffff7; --card-b: #fff0d5; }
.card-road { --card-a: #e0f5ff; --card-b: #ffe8c9; }
.card-christmas { --card-a: #ffe0df; --card-b: #e2f8e7; }
.card-halloween { --card-a: #eadcff; --card-b: #ffe7c8; }
.card-gold { --card-a: #f5e7c1; --card-b: #f9f9ff; }
.card-valentine { --card-a: #ffe1ec; --card-b: #fff4f7; }

.workflow {
	display: grid;
	grid-template-columns: repeat(3, minmax(0, 1fr));
	gap: 24px;
	width: min(1420px, calc(100vw - 88px));
	margin: 28px auto 0;
	padding: 20px;
	border: 1px solid var(--home-line);
	border-radius: 14px;
	background: #ffffff;
	box-shadow: 0 12px 28px rgba(74, 82, 118, 0.06);
}

.workflow-card {
	position: relative;
	display: grid;
	grid-template-columns: 96px 1fr;
	gap: 18px;
	align-items: center;
	min-height: 108px;
}

.workflow-card > span {
	position: absolute;
	left: 70px;
	top: 4px;
	display: grid;
	place-items: center;
	width: 31px;
	height: 31px;
	border-radius: 999px;
	background: var(--home-purple);
	color: #ffffff;
	font-weight: 900;
}

.workflow-icon {
	display: grid;
	place-items: center;
	width: 82px;
	height: 82px;
	border-radius: 16px;
	background: linear-gradient(135deg, #f2eeff, #faf7ff);
}

.workflow-icon svg {
	width: 48px;
	height: 48px;
	fill: none;
	stroke: var(--home-purple);
	stroke-width: 3;
	stroke-linecap: round;
	stroke-linejoin: round;
}

.workflow h3 {
	margin: 0 0 7px;
	font-size: 18px;
}

.workflow p {
	margin: 0;
	color: var(--home-muted);
	font-weight: 700;
}

.tool-stage {
	width: min(1420px, calc(100vw - 88px));
	margin: 30px auto 0;
	padding: 18px;
	border: 1px solid var(--home-line);
	border-radius: 16px;
	background: #f6f8ff;
}

.tool-stage-head {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 18px;
	padding: 4px 4px 18px;
}

.tool-stage-head p {
	margin: 0 0 4px;
	color: var(--home-purple);
	font-size: 13px;
	font-weight: 900;
	text-transform: uppercase;
}

.tool-stage-head h2 {
	margin: 0;
	font-size: 30px;
	letter-spacing: -0.03em;
}

.tool-stage .wt-frame-maker {
	width: 100%;
	margin: 0;
}

.tool-stage .wt-hero {
	display: none;
}

.site-footer {
	display: grid;
	grid-template-columns: 1.4fr repeat(2, minmax(130px, 0.7fr)) 1.1fr;
	gap: 54px;
	width: min(1420px, calc(100vw - 88px));
	margin: 36px auto 0;
	padding: 34px 28px;
	border-top: 1px solid var(--home-line);
	color: var(--home-ink);
}

.site-footer .site-logo strong {
	font-size: 20px;
}

.site-footer .site-logo-mark {
	width: 38px;
	height: 38px;
	border-radius: 9px;
}

.site-footer p,
.site-footer a {
	margin: 0;
	color: var(--home-muted);
	font-size: 14px;
	font-weight: 700;
	line-height: 1.6;
}

.site-footer h3 {
	margin: 0 0 12px;
	font-size: 15px;
}

.site-footer > div,
.footer-form {
	display: grid;
	align-content: start;
	gap: 9px;
}

.footer-form label {
	display: grid;
	grid-template-columns: 1fr 48px;
	margin-top: 8px;
}

.footer-form input {
	height: 46px;
	padding: 0 14px;
	border-radius: 10px 0 0 10px;
}

.footer-form button {
	display: grid;
	place-items: center;
	border: 0;
	border-radius: 0 10px 10px 0;
	background: var(--home-purple);
	cursor: pointer;
}

.footer-form svg {
	width: 21px;
	height: 21px;
	fill: none;
	stroke: #ffffff;
	stroke-width: 2.4;
	stroke-linecap: round;
	stroke-linejoin: round;
}

.copyright {
	grid-column: 1 / -1;
	text-align: center;
}

.home-page .wt-frame-maker {
	--wt-blue: #6438f2;
	--wt-blue-dark: #4e22dc;
	--wt-mint: #25bfa8;
}

.home-page .wt-editor-head,
.home-page .wt-guide,
.home-page .wt-slot-panel,
.home-page .wt-text-panel,
.home-page .wt-tool-panel,
.home-page .wt-canvas-panel,
.home-page .wt-library {
	border-color: var(--home-line);
	background: #ffffff;
}

.home-page .wt-button-primary,
.home-page .wt-download {
	background: linear-gradient(135deg, #7048ff, #5428e9);
}

@media (max-width: 1120px) {
	.site-header {
		grid-template-columns: auto auto;
	}

	.site-nav {
		display: none;
	}

	.header-actions {
		justify-content: end;
	}

	.template-row {
		grid-template-columns: repeat(2, minmax(0, 1fr));
	}

	.workflow {
		grid-template-columns: 1fr;
	}

	.site-footer {
		grid-template-columns: repeat(2, minmax(0, 1fr));
	}
}

@media (max-width: 760px) {
	.site-header {
		position: static;
		display: grid;
		grid-template-columns: 1fr;
		gap: 14px;
		padding: 14px;
	}

	.site-logo strong {
		font-size: 24px;
	}

	.header-actions {
		display: grid;
		grid-template-columns: 1fr auto;
	}

	.header-search {
		width: 100%;
	}

	.signin-link {
		display: none;
	}

	.home-hero {
		padding: 34px 16px 28px;
	}

	.home-hero p {
		font-size: 15px;
	}

	.hero-search {
		grid-template-columns: 1fr 54px;
		height: 56px;
	}

	.hero-search input,
	.hero-search button {
		height: 56px;
	}

	.hero-search input {
		padding-left: 48px;
		font-size: 13px;
	}

	.hero-search > svg {
		left: 18px;
		width: 18px;
		height: 18px;
	}

	.category-strip {
		width: calc(100vw - 24px);
		padding: 18px 0;
	}

	.template-catalog,
	.workflow,
	.tool-stage,
	.site-footer {
		width: calc(100vw - 24px);
	}

	.template-section {
		padding: 14px;
	}

	.template-row {
		grid-template-columns: 1fr;
		gap: 14px;
	}

	.workflow {
		padding: 14px;
	}

	.workflow-card {
		grid-template-columns: 72px 1fr;
	}

	.workflow-icon {
		width: 62px;
		height: 62px;
	}

	.workflow-card > span {
		left: 50px;
	}

	.tool-stage-head {
		align-items: stretch;
		flex-direction: column;
	}

	.site-footer {
		grid-template-columns: 1fr;
		gap: 24px;
		padding-inline: 4px;
	}
}
