:root {
	--kvs-navy: #092f4b;
	--kvs-blue: #0b5c94;
	--kvs-blue-bright: #1379b9;
	--kvs-ink: #17232d;
	--kvs-muted: #65737e;
	--kvs-line: #dfe5e9;
	--kvs-soft: #f4f7f9;
	--kvs-white: #ffffff;
	--kvs-danger: #b42318;
}

.kvs-launcher {
	margin: 0 0 18px;
}

.kvs-open-button.button {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	gap: 9px;
	min-height: 48px;
	padding: 0 22px;
	background: var(--kvs-blue) !important;
	border: 1px solid var(--kvs-blue) !important;
	border-radius: 6px;
	box-shadow: 0 8px 18px rgba(11, 92, 148, 0.16);
	color: var(--kvs-white) !important;
	font-weight: 700;
	line-height: 1.2;
	text-transform: none;
	transition: background 0.2s ease, transform 0.2s ease, box-shadow 0.2s ease;
}

.kvs-open-button.button:hover {
	background: var(--kvs-navy) !important;
	border-color: var(--kvs-navy) !important;
	box-shadow: 0 10px 24px rgba(9, 47, 75, 0.22);
	transform: translateY(-1px);
}

.kvs-button-icon {
	display: grid;
	place-items: center;
	width: 24px;
	height: 24px;
	background: rgba(255, 255, 255, 0.16);
	border-radius: 50%;
	font-size: 14px;
}

.kvs-launch-note {
	margin: 7px 0 0;
	color: var(--kvs-muted);
	font-size: 13px;
}

.kvs-modal[hidden] {
	display: none !important;
}

.kvs-modal {
	position: fixed;
	z-index: 999999;
	inset: 0;
	display: block;
	padding: 0;
}

.kvs-modal-backdrop {
	position: absolute;
	inset: 0;
	background: rgba(7, 22, 32, 0.76);
	backdrop-filter: blur(5px);
}

.kvs-modal-dialog {
	position: relative;
	display: flex;
	flex-direction: column;
	overflow: hidden;
	width: 100vw;
	height: 100vh;
	height: 100dvh;
	max-width: none;
	max-height: none;
	background: var(--kvs-white);
	border-radius: 0;
	box-shadow: none;
	color: var(--kvs-ink);
	animation: kvs-modal-in 0.22s ease-out;
}

@keyframes kvs-modal-in {
	from {
		opacity: 0;
		transform: translateY(12px) scale(0.985);
	}
	to {
		opacity: 1;
		transform: translateY(0) scale(1);
	}
}

.kvs-modal-header {
	display: flex;
	flex: 0 0 auto;
	align-items: center;
	justify-content: space-between;
	box-sizing: border-box;
	gap: 20px;
	min-height: 68px;
	padding: 11px 20px;
	background: linear-gradient(120deg, var(--kvs-navy), #0d527f);
	color: var(--kvs-white);
}

.kvs-modal-header h2 {
	margin: 2px 0 0;
	color: var(--kvs-white) !important;
	font-size: clamp(20px, 2vw, 28px);
	line-height: 1.2;
}

.kvs-eyebrow {
	display: block;
	color: rgba(255, 255, 255, 0.72) !important;
	font-size: 10px;
	font-weight: 700;
	letter-spacing: 0.13em;
	text-transform: uppercase;
}

.kvs-close-button {
	display: grid;
	flex: 0 0 auto;
	place-items: center;
	width: 40px;
	height: 40px;
	padding: 0;
	background: rgba(255, 255, 255, 0.1);
	border: 1px solid rgba(255, 255, 255, 0.2);
	border-radius: 50%;
	color: var(--kvs-white);
	font-size: 28px;
	font-weight: 300;
	line-height: 1;
	cursor: pointer;
}

.kvs-close-button:hover {
	background: rgba(255, 255, 255, 0.2);
}

.kvs-modal-body {
	display: grid;
	flex: 1 1 auto;
	grid-template-columns: minmax(330px, 390px) minmax(0, 1fr);
	min-height: 0;
}

.kvs-preview-column {
	display: flex;
	flex-direction: column;
	box-sizing: border-box;
	min-width: 0;
	min-height: 0;
	overflow: hidden;
	padding: 16px 20px 14px;
	background:
		radial-gradient(circle at 50% 40%, rgba(255, 255, 255, 0.9), rgba(244, 247, 249, 0.7) 54%, rgba(229, 236, 240, 0.85)),
		var(--kvs-soft);
}

.kvs-product-colours {
	margin: 0;
	padding: 0;
	background: transparent;
	border: 0;
	border-radius: 0;
	box-shadow: none;
}

.kvs-product-colours-heading {
	display: block;
	margin-bottom: 12px;
}

.kvs-product-colours-heading > div {
	display: flex;
	flex-wrap: wrap;
	align-items: baseline;
	gap: 5px 12px;
}

.kvs-product-colours-heading strong {
	color: var(--kvs-ink);
	font-size: 14px;
}

.kvs-product-colours-heading span,
.kvs-product-colours-heading small {
	color: var(--kvs-muted);
	font-size: 11px;
	line-height: 1.4;
}

.kvs-product-colours-heading small {
	display: block;
	margin-top: 3px;
}

.kvs-product-colours-heading b {
	color: var(--kvs-blue);
}

.kvs-colour-options {
	display: grid;
	grid-auto-columns: 82px;
	grid-auto-flow: column;
	gap: 8px;
	overflow-x: auto;
	padding: 2px 2px 5px;
	scrollbar-width: thin;
}

.kvs-modal-dialog .kvs-colour-option {
	display: flex;
	flex-direction: column;
	overflow: hidden;
	min-width: 0;
	padding: 0;
	background: #fff !important;
	border: 1px solid #d7e0e5;
	border-radius: 7px;
	color: var(--kvs-ink) !important;
	cursor: pointer;
	transition: border-color 0.18s ease, box-shadow 0.18s ease, transform 0.18s ease;
}

.kvs-modal-dialog .kvs-colour-option:hover,
.kvs-modal-dialog .kvs-colour-option:focus,
.kvs-modal-dialog .kvs-colour-option:focus-visible {
	background: #fff !important;
	border-color: #78a9c8;
	color: var(--kvs-ink) !important;
	box-shadow: 0 3px 10px rgba(11, 92, 148, 0.12);
	outline: none;
	transform: translateY(-1px);
}

.kvs-modal-dialog .kvs-colour-option.is-selected,
.kvs-modal-dialog .kvs-colour-option.is-selected:hover,
.kvs-modal-dialog .kvs-colour-option.is-selected:focus {
	background: #fff !important;
	border-color: var(--kvs-blue);
	color: var(--kvs-ink) !important;
	box-shadow: 0 0 0 2px rgba(11, 92, 148, 0.17);
}

.kvs-colour-thumbnail {
	display: flex;
	align-items: center;
	justify-content: center;
	height: 58px;
	padding: 5px;
	background: #fff;
}

.kvs-colour-thumbnail img {
	display: block;
	width: 100%;
	height: 100%;
	object-fit: contain;
}

.kvs-colour-label {
	overflow: hidden;
	padding: 5px 4px;
	background: #eef2f4 !important;
	color: var(--kvs-ink) !important;
	font-size: 9px;
	font-weight: 700;
	line-height: 1.25;
	text-align: center;
	text-overflow: ellipsis;
	white-space: nowrap;
}

.kvs-modal-dialog .kvs-colour-option.is-selected .kvs-colour-label,
.kvs-modal-dialog .kvs-colour-option.is-selected:hover .kvs-colour-label,
.kvs-modal-dialog .kvs-colour-option.is-selected:focus .kvs-colour-label {
	background: var(--kvs-blue) !important;
	color: #fff !important;
}

.kvs-preview-toolbar {
	display: flex;
	flex: 0 0 auto;
	align-items: center;
	justify-content: space-between;
	gap: 16px;
	margin-bottom: 10px;
}

.kvs-preview-title {
	min-width: 0;
}

.kvs-preview-title strong {
	display: block;
	color: var(--kvs-ink);
	font-size: 14px;
	line-height: 1.3;
}

.kvs-preview-title small {
	display: block;
	margin-top: 2px;
	color: var(--kvs-muted);
	font-size: 10px;
	line-height: 1.35;
}

.kvs-zoom-controls {
	display: flex;
	flex: 0 0 auto;
	align-items: center;
	gap: 5px;
	padding: 4px;
	background: rgba(255, 255, 255, 0.96);
	border: 1px solid #d5dfe5;
	border-radius: 8px;
	box-shadow: 0 5px 16px rgba(26, 57, 76, 0.08);
}

.kvs-zoom-button {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	box-sizing: border-box;
	min-width: 34px;
	height: 34px;
	margin: 0;
	padding: 0 10px;
	background: #fff;
	border: 1px solid transparent;
	border-radius: 5px;
	color: var(--kvs-ink);
	font-family: inherit;
	font-size: 11px;
	font-weight: 700;
	line-height: 1;
	text-transform: none;
	cursor: pointer;
	transition: background 0.16s ease, border-color 0.16s ease, color 0.16s ease;
}

.kvs-zoom-out,
.kvs-zoom-in {
	padding: 0;
	font-size: 20px;
	font-weight: 400;
}

.kvs-zoom-button:hover,
.kvs-zoom-button:focus-visible {
	background: #edf5fa;
	border-color: #bad4e4;
	color: var(--kvs-blue);
	outline: none;
}

.kvs-zoom-button.is-active {
	background: var(--kvs-blue);
	border-color: var(--kvs-blue);
	color: #fff;
}

.kvs-zoom-button:disabled {
	opacity: 0.38;
	cursor: default;
}

.kvs-zoom-level {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 46px;
	color: #40515d;
	font-size: 10px;
	font-weight: 700;
	font-variant-numeric: tabular-nums;
}

.kvs-canvas-shell {
	position: relative;
	display: block;
	flex: 1 1 auto;
	overflow: auto;
	box-sizing: border-box;
	width: 100%;
	min-height: 0;
	padding: 18px;
	background: var(--kvs-white);
	border: 1px solid #d8e0e5;
	border-radius: 10px;
	box-shadow: 0 12px 35px rgba(26, 57, 76, 0.09);
	overscroll-behavior: contain;
	scrollbar-color: #9fb5c3 #eef3f6;
	scrollbar-width: thin;
}

.kvs-canvas-stage {
	display: grid;
	place-items: center;
	box-sizing: border-box;
	min-width: 100%;
	min-height: 100%;
}

.kvs-canvas-shell .canvas-container,
.kvs-canvas-shell .kvs-fabric-container {
	flex: 0 0 auto;
	overflow: visible !important;
	max-width: none !important;
	max-height: none !important;
	margin: 0 !important;
}

.kvs-canvas-shell .kvs-fabric-container canvas {
	display: block !important;
	max-width: none !important;
	max-height: none !important;
	margin: 0 !important;
	object-fit: fill !important;
}

.kvs-loading {
	position: absolute;
	z-index: 5;
	inset: 0;
	display: flex;
	align-items: center;
	justify-content: center;
	gap: 10px;
	background: rgba(255, 255, 255, 0.88);
	color: var(--kvs-muted);
	font-size: 13px;
}

.kvs-loading[hidden] {
	display: none;
}

.kvs-loading span {
	width: 18px;
	height: 18px;
	border: 2px solid #d4e1e9;
	border-top-color: var(--kvs-blue);
	border-radius: 50%;
	animation: kvs-spin 0.75s linear infinite;
}

@keyframes kvs-spin {
	to {
		transform: rotate(360deg);
	}
}

.kvs-preview-help {
	display: flex;
	flex: 0 0 auto;
	align-items: center;
	justify-content: center;
	gap: 8px;
	margin: 9px auto 0;
	color: var(--kvs-muted);
	font-size: 10px;
	text-align: center;
}

.kvs-preview-help > span {
	display: grid;
	flex: 0 0 auto;
	place-items: center;
	width: 24px;
	height: 24px;
	background: #e5eef4;
	border-radius: 50%;
	color: var(--kvs-blue);
	font-weight: 700;
}

.kvs-controls-column {
	overflow-y: auto;
	padding: 20px;
	background: var(--kvs-white);
	border-right: 1px solid var(--kvs-line);
}

.kvs-control-section + .kvs-control-section {
	margin-top: 25px;
	padding-top: 24px;
	border-top: 1px solid var(--kvs-line);
}

.kvs-section-heading {
	display: flex;
	align-items: flex-start;
	gap: 12px;
	margin-bottom: 15px;
}

.kvs-step {
	display: grid;
	flex: 0 0 auto;
	place-items: center;
	width: 28px;
	height: 28px;
	background: #e8f3fa;
	border-radius: 50%;
	color: var(--kvs-blue);
	font-size: 13px;
	font-weight: 800;
}

.kvs-section-heading h3 {
	margin: 0;
	color: var(--kvs-ink);
	font-size: 16px;
	line-height: 1.35;
}

.kvs-section-heading p {
	margin: 2px 0 0;
	color: var(--kvs-muted);
	font-size: 12px;
	line-height: 1.45;
}

.kvs-field {
	display: block;
	margin: 0 0 12px;
}

.kvs-field > span {
	display: block;
	margin: 0 0 5px;
	color: #33434e;
	font-size: 12px;
	font-weight: 700;
}

.kvs-field input,
.kvs-field select,
.kvs-field textarea {
	box-sizing: border-box;
	width: 100%;
	margin: 0;
	padding: 0 11px;
	background: #fff;
	border: 1px solid #cfd9df;
	border-radius: 5px;
	color: var(--kvs-ink);
	font-size: 14px;
}

.kvs-field input,
.kvs-field select {
	height: 42px;
}

.kvs-field textarea {
	display: block;
	min-height: 88px;
	padding-top: 9px;
	padding-bottom: 9px;
	line-height: 1.45;
	resize: vertical;
}

.kvs-field input:focus,
.kvs-field select:focus,
.kvs-field textarea:focus {
	border-color: var(--kvs-blue);
	box-shadow: 0 0 0 2px rgba(11, 92, 148, 0.12);
	outline: none;
}

.kvs-line-count {
	display: block;
	margin-top: 4px;
	color: var(--kvs-muted);
	font-size: 10px;
	text-align: right;
}

.kvs-field-row {
	display: grid;
	grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
	gap: 10px;
	min-width: 0;
}

.kvs-modal-dialog .kvs-field-row > .kvs-field,
.kvs-modal-dialog .kvs-field-row .kvs-font-picker {
	float: none !important;
	box-sizing: border-box !important;
	width: 100% !important;
	min-width: 0 !important;
	max-width: 100% !important;
}

.kvs-modal-dialog .kvs-field-row input.kvs-font-search,
.kvs-modal-dialog .kvs-field-row select.kvs-colour-select {
	display: block !important;
	float: none !important;
	box-sizing: border-box !important;
	width: 100% !important;
	inline-size: 100% !important;
	min-width: 0 !important;
	min-inline-size: 0 !important;
	max-width: 100% !important;
	max-inline-size: 100% !important;
	margin: 0 !important;
}

.kvs-font-picker {
	position: relative;
}

.kvs-font-results {
	position: absolute;
	z-index: 20;
	top: calc(100% + 4px);
	right: 0;
	left: 0;
	overflow-y: auto;
	max-height: 238px;
	padding: 4px;
	background: #fff;
	border: 1px solid #cfd9df;
	border-radius: 5px;
	box-shadow: 0 12px 28px rgba(19, 44, 61, 0.17);
}

.kvs-font-results[hidden] {
	display: none;
}

.kvs-font-results button {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 8px;
	width: 100%;
	min-height: 36px;
	padding: 6px 8px;
	background: transparent;
	border: 0;
	border-radius: 3px;
	color: var(--kvs-ink);
	font-size: 12px;
	text-align: left;
	cursor: pointer;
}

.kvs-font-results button:hover,
.kvs-font-results button:focus,
.kvs-font-results button[aria-selected="true"] {
	background: #edf5fa;
	outline: none;
}

.kvs-font-results button small {
	flex: 0 0 auto;
	padding: 2px 5px;
	background: #f1f4f6;
	border-radius: 8px;
	color: var(--kvs-muted);
	font-size: 8px;
}

.kvs-font-results button[aria-selected="true"] small {
	background: #dcecf6;
	color: var(--kvs-blue);
}

.kvs-font-empty {
	display: block;
	padding: 10px 8px;
	color: var(--kvs-muted);
	font-size: 11px;
	line-height: 1.4;
}

.kvs-live-note {
	display: flex;
	align-items: center;
	gap: 6px;
	margin: -2px 0 0;
	color: #23743b;
	font-size: 10px;
}

.kvs-live-note > span {
	color: #34a853;
	font-size: 7px;
}

.kvs-upload-zone {
	display: flex;
	flex-direction: column;
	align-items: center;
	justify-content: center;
	min-height: 126px;
	padding: 16px;
	background: #f8fafb;
	border: 1.5px dashed #afc2ce;
	border-radius: 8px;
	color: var(--kvs-ink);
	text-align: center;
	cursor: pointer;
	transition: border-color 0.2s, background 0.2s;
}

.kvs-upload-zone:hover {
	background: #f0f7fb;
	border-color: var(--kvs-blue);
}

.kvs-upload-zone input {
	position: absolute;
	overflow: hidden;
	width: 1px;
	height: 1px;
	clip: rect(0, 0, 0, 0);
}

.kvs-upload-icon {
	display: grid;
	place-items: center;
	width: 34px;
	height: 34px;
	margin-bottom: 7px;
	background: #e6f1f7;
	border-radius: 50%;
	color: var(--kvs-blue);
	font-size: 20px;
	font-weight: 700;
}

.kvs-upload-zone strong {
	font-size: 13px;
}

.kvs-upload-zone small {
	margin-top: 3px;
	color: var(--kvs-muted);
	font-size: 10px;
}

.kvs-logo-status {
	overflow: hidden;
	margin-top: 8px;
	padding: 7px 9px;
	background: #ecf7ef;
	border-radius: 4px;
	color: #23743b;
	font-size: 11px;
	text-overflow: ellipsis;
	white-space: nowrap;
}

.kvs-edit-actions {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 12px;
	margin-top: 20px;
	padding-top: 18px;
	border-top: 1px solid var(--kvs-line);
}

.kvs-edit-actions .button,
.kvs-edit-actions .button-link {
	min-height: 36px;
	text-transform: none;
}

.kvs-reset {
	color: var(--kvs-danger) !important;
	font-size: 12px;
}

.kvs-disclaimer {
	margin: 19px 0 0;
	padding: 11px 12px;
	background: #fff8e7;
	border-left: 3px solid #d4a834;
	border-radius: 3px;
	color: #695724;
	font-size: 10px;
	line-height: 1.5;
}

.kvs-modal-footer {
	display: flex;
	flex: 0 0 auto;
	align-items: center;
	justify-content: space-between;
	gap: 20px;
	padding: 14px 22px;
	background: #fbfcfd;
	border-top: 1px solid var(--kvs-line);
}

.kvs-message {
	color: #27713b;
	font-size: 12px;
	line-height: 1.4;
}

.kvs-message.is-error {
	color: var(--kvs-danger);
}

.kvs-footer-actions {
	display: flex;
	flex: 0 0 auto;
	gap: 10px;
}

.kvs-footer-actions .button {
	min-height: 42px;
	padding: 0 17px;
	border-radius: 5px;
	font-weight: 700;
	text-transform: none;
}

.kvs-footer-actions .button.alt {
	background: var(--kvs-blue) !important;
	border-color: var(--kvs-blue) !important;
	color: #fff !important;
}

body.kvs-modal-open {
	overflow: hidden;
}

.kvs-cart-preview {
	display: block;
	width: 120px;
	margin: 9px 0 3px;
}

.kvs-cart-preview img {
	display: block;
	width: 100%;
	height: auto;
	background: #fff;
	border: 1px solid var(--kvs-line);
	border-radius: 4px;
}

@media (max-width: 960px) {
	.kvs-modal-body {
		display: flex;
		flex-direction: column;
		overflow-y: auto;
	}

	.kvs-preview-column {
		order: -1;
		flex: 0 0 auto;
		height: min(56vh, 560px);
		min-height: 360px;
		overflow: hidden;
	}

	.kvs-controls-column {
		overflow: visible;
		border-right: 0;
		border-top: 1px solid var(--kvs-line);
	}
}

@media (max-width: 600px) {
	.kvs-modal-header {
		min-height: 58px;
		padding: 13px 15px;
	}

	.kvs-eyebrow {
		display: none;
	}

	.kvs-modal-header h2 {
		margin: 0;
		font-size: 19px;
	}

	.kvs-close-button {
		width: 36px;
		height: 36px;
	}

	.kvs-preview-column {
		height: 46vh;
		min-height: 310px;
		padding: 10px;
	}

	.kvs-product-colours {
		margin: 0;
		padding: 0;
	}

	.kvs-product-colours-heading {
		display: block;
		margin-bottom: 9px;
	}

	.kvs-product-colours-heading small {
		display: block;
		margin-top: 3px;
	}

	.kvs-colour-options {
		grid-auto-columns: 78px;
	}

	.kvs-colour-thumbnail {
		height: 50px;
	}

	.kvs-preview-toolbar {
		align-items: stretch;
		flex-direction: column;
		gap: 6px;
		margin-bottom: 7px;
	}

	.kvs-preview-title {
		display: none;
	}

	.kvs-zoom-controls {
		justify-content: center;
		width: 100%;
		padding: 3px;
	}

	.kvs-zoom-button {
		flex: 1 1 auto;
		min-width: 31px;
		height: 32px;
		padding: 0 6px;
		font-size: 10px;
	}

	.kvs-zoom-out,
	.kvs-zoom-in {
		flex: 0 0 32px;
		font-size: 18px;
	}

	.kvs-zoom-level {
		flex: 0 0 42px;
		width: 42px;
	}

	.kvs-canvas-shell {
		min-height: 0;
		padding: 10px;
	}

	.kvs-preview-help {
		display: none;
	}

	.kvs-controls-column {
		padding: 18px 15px;
	}

	.kvs-field-row {
		grid-template-columns: 1fr;
		gap: 0;
	}

	.kvs-modal-footer {
		align-items: stretch;
		flex-direction: column;
		gap: 8px;
		padding: 11px 14px;
	}

	.kvs-footer-actions {
		display: grid;
		grid-template-columns: 1fr 1.3fr;
	}

	.kvs-footer-actions .button {
		min-height: 44px;
		padding: 0 8px;
		font-size: 11px;
	}

	.kvs-open-button.button {
		width: 100%;
	}
}

.kvs-sample-upload-busy .single_add_to_cart_button,
.kvs-sample-upload-busy .kumu-tp-allocation-submit,
.kvs-sample-upload-busy button[type='submit'],
.kvs-sample-upload-busy input[type='submit'] {
	opacity: 0.55;
	pointer-events: none;
}

.kvs-launch-note.is-uploading {
	color: var(--kvs-blue);
	font-weight: 600;
}

/* Native product-card launcher (v1.5.4). The hidden launcher keeps the
 * existing studio implementation reusable without loading a product page. */
.kvs-archive-launcher-host[hidden],
.kvs-archive-launcher[hidden] {
	display: none !important;
}

.kumu-loop-virtual-sample.kvs-native-opening,
[data-kvs-native-launch='1'].kvs-native-opening {
	position: relative;
	cursor: progress;
	opacity: 0.82;
}

.kumu-loop-virtual-sample.kvs-native-opening::after,
[data-kvs-native-launch='1'].kvs-native-opening::after {
	content: '';
	display: inline-block;
	width: 12px;
	height: 12px;
	margin-left: 7px;
	vertical-align: -2px;
	border: 2px solid currentColor;
	border-right-color: transparent;
	border-radius: 50%;
	animation: kvs-native-spin .65s linear infinite;
}

@keyframes kvs-native-spin {
	to { transform: rotate(360deg); }
}
