/* ============================================================
   Kasirye Labs — Custom Design Upload Card
   ============================================================ */

/* ── Card shell ──────────────────────────────────────────────── */
.kl-design-wrap {
	margin-bottom: 16px;
	border: 1.5px solid #eee;
	border-radius: 10px;
	overflow: hidden;
	font-family: 'Jost', sans-serif;
}

.kl-design-header {
	display: flex;
	align-items: center;
	gap: 8px;
	padding: 12px 14px;
	background: #fafafa;
	border-bottom: 1px solid #f0f0f0;
	font-size: 11px;
	font-weight: 800;
	text-transform: uppercase;
	letter-spacing: 0.7px;
	color: #1a2035;
}

.kl-design-header svg {
	color: #ffbe00;
	flex-shrink: 0;
}

.kl-design-body {
	padding: 14px;
}

/* ── Drop zone ───────────────────────────────────────────────── */
.kl-design-zone {
	border: 2px dashed #ddd;
	border-radius: 8px;
	padding: 22px 16px;
	text-align: center;
	cursor: pointer;
	transition: border-color 0.2s, background 0.2s;
	user-select: none;
}

.kl-design-zone:hover,
.kl-design-zone.kl-drag-over {
	border-color: #ffbe00;
	background: #fff8e1;
}

.kl-design-zone-icon {
	width: 36px;
	height: 36px;
	margin: 0 auto 10px;
	color: #ccc;
	display: block;
}

.kl-design-zone-text {
	font-size: 13px;
	font-weight: 700;
	color: #1a2035;
	margin: 0 0 5px;
}

.kl-design-zone-hint {
	font-size: 11px;
	color: #aaa;
	margin: 0;
}

.kl-design-zone-hint strong {
	color: #ffbe00;
}

/* ── Uploading spinner ───────────────────────────────────────── */
.kl-design-uploading {
	display: none;
	align-items: center;
	gap: 10px;
	padding: 14px 0;
	font-size: 13px;
	color: #888;
}

.kl-design-uploading.kl-active {
	display: flex;
}

.kl-design-spinner {
	width: 18px;
	height: 18px;
	border: 2px solid #e0e0e0;
	border-top-color: #ffbe00;
	border-radius: 50%;
	animation: kl-design-spin 0.65s linear infinite;
	flex-shrink: 0;
}

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

/* ── Preview (after upload) ──────────────────────────────────── */
.kl-design-preview {
	display: none;
	align-items: center;
	gap: 12px;
	padding: 10px 12px;
	border: 1.5px solid #e0e0e0;
	border-radius: 8px;
	background: #fafafa;
}

.kl-design-preview.kl-has-file {
	display: flex;
}

.kl-design-thumb {
	width: 52px;
	height: 52px;
	border-radius: 6px;
	object-fit: cover;
	border: 1px solid #e0e0e0;
	flex-shrink: 0;
	display: none;
}

.kl-design-thumb-icon {
	width: 52px;
	height: 52px;
	border-radius: 6px;
	background: #f0f0f0;
	border: 1px solid #e0e0e0;
	display: none;
	align-items: center;
	justify-content: center;
	flex-shrink: 0;
	color: #888;
}

.kl-design-file-info {
	flex: 1;
	min-width: 0;
}

.kl-design-filename {
	font-size: 13px;
	font-weight: 700;
	color: #1a2035;
	white-space: nowrap;
	overflow: hidden;
	text-overflow: ellipsis;
	display: block;
}

.kl-design-filesize {
	font-size: 11px;
	color: #aaa;
	display: block;
	margin-top: 3px;
}

.kl-design-remove {
	width: 24px;
	height: 24px;
	border-radius: 50%;
	border: none;
	background: #f0f0f0;
	color: #888;
	cursor: pointer;
	display: flex;
	align-items: center;
	justify-content: center;
	font-size: 16px;
	line-height: 1;
	flex-shrink: 0;
	transition: background 0.15s, color 0.15s;
	padding: 0;
}

.kl-design-remove:hover {
	background: #fee2e2;
	color: #e8461e;
}

/* ── Fee note ────────────────────────────────────────────────── */
.kl-design-fee-note {
	display: flex;
	align-items: center;
	gap: 7px;
	margin-top: 10px;
	padding: 8px 12px;
	background: #fff8e1;
	border-radius: 6px;
	font-size: 12px;
	color: #92600a;
}

.kl-design-fee-note svg {
	flex-shrink: 0;
	color: #c8930a;
}

.kl-design-fee-note strong {
	font-weight: 700;
}

/* ── Preview button ──────────────────────────────────────────── */
.kl-design-preview-btn {
	display: inline-flex;
	align-items: center;
	gap: 4px;
	margin-top: 5px;
	padding: 3px 8px;
	border: 1.5px solid #e0e0e0;
	border-radius: 4px;
	background: #fff;
	font-family: 'Jost', sans-serif;
	font-size: 11px;
	font-weight: 700;
	color: #1a2035;
	cursor: pointer;
	transition: border-color 0.15s, background 0.15s;
}

.kl-design-preview-btn:hover {
	border-color: #ffbe00;
	background: #fff8e1;
}

/* ── Full-size preview modal ─────────────────────────────────── */
.kl-design-modal {
	display: none;
	position: fixed;
	inset: 0;
	z-index: 99999;
	align-items: center;
	justify-content: center;
}

.kl-design-modal.kl-open {
	display: flex;
}

.kl-design-modal-backdrop {
	position: absolute;
	inset: 0;
	background: rgba(0, 0, 0, 0.75);
}

.kl-design-modal-box {
	position: relative;
	z-index: 1;
	max-width: 90vw;
	max-height: 88vh;
	background: #fff;
	border-radius: 12px;
	overflow: hidden;
	box-shadow: 0 24px 64px rgba(0, 0, 0, 0.35);
	display: flex;
	align-items: center;
	justify-content: center;
}

.kl-design-modal-img {
	display: block;
	max-width: 88vw;
	max-height: 84vh;
	object-fit: contain;
}

.kl-design-modal-close {
	position: absolute;
	top: 10px;
	right: 10px;
	width: 32px;
	height: 32px;
	border-radius: 50%;
	border: none;
	background: rgba(0, 0, 0, 0.5);
	color: #fff;
	font-size: 18px;
	line-height: 1;
	cursor: pointer;
	display: flex;
	align-items: center;
	justify-content: center;
	z-index: 2;
	transition: background 0.15s;
	padding: 0;
}

.kl-design-modal-close:hover {
	background: rgba(0, 0, 0, 0.8);
}

/* ── Error ───────────────────────────────────────────────────── */
.kl-design-error {
	display: none;
	margin-top: 8px;
	padding: 8px 12px;
	background: #fee2e2;
	border-radius: 6px;
	font-size: 12px;
	color: #c53030;
}

.kl-design-error.kl-active {
	display: block;
}
