/**
 * The Artist Bio editing page.
 *
 * Most artists will fill this in on a phone, standing in the gallery. Big
 * targets, one column, nothing clever.
 */

.kcg-gw-profile {
	max-width: 780px;
	margin: 0 auto;
	font-family: Roboto, "Helvetica Neue", Arial, sans-serif;
	font-size: 16px;
	line-height: 1.6;
	color: #2d3748;
}

.kcg-gw-profile__empty {
	padding: 20px;
	background: #f7fafc;
	border-left: 4px solid #283971;
}

/* ---------------------------------------------------------------------
 * Notices
 * ------------------------------------------------------------------ */

.kcg-gw-profile__notice {
	margin: 0 0 24px;
	padding: 14px 18px;
	border-radius: 6px;
	border-left: 5px solid;
	font-size: 16px;
}

.kcg-gw-profile__notice--good {
	background: #edf7ed;
	border-color: #2e7d32;
	color: #1b4d1e;
}

.kcg-gw-profile__notice--warn {
	background: #fff8e6;
	border-color: #b7791f;
	color: #6b4708;
}

.kcg-gw-profile__notice--bad {
	background: #fdecec;
	border-color: #c53030;
	color: #7a1c1c;
}

/* ---------------------------------------------------------------------
 * Name picker
 * ------------------------------------------------------------------ */

.kcg-gw-profile__picker {
	padding: 22px;
	margin-bottom: 30px;
	background: #f7fafc;
	border: 1px solid #dde3ec;
	border-radius: 8px;
}

.kcg-gw-profile__picker label {
	display: block;
	margin-bottom: 8px;
	font-weight: 600;
	color: #283971;
}

.kcg-gw-profile__pickrow {
	display: flex;
	flex-wrap: wrap;
	gap: 12px;
}

.kcg-gw-profile__pickrow select {
	flex: 1 1 260px;
	min-height: 48px;
	padding: 10px 12px;
	font-size: 16px;
	border: 1px solid #c3cbd9;
	border-radius: 6px;
	background: #ffffff;
	color: #2d3748;
}

/* ---------------------------------------------------------------------
 * Form
 * ------------------------------------------------------------------ */

.kcg-gw-profile__who {
	margin: 0 0 6px;
	font-size: 26px;
	font-weight: 600;
	color: #283971;
}

.kcg-gw-profile__standing {
	display: inline-block;
	margin-left: 10px;
	padding: 4px 12px;
	border-radius: 20px;
	background: #283971;
	color: #ffffff;
	font-size: 12px;
	font-weight: 500;
	letter-spacing: 1.5px;
	text-transform: uppercase;
	vertical-align: middle;
}

.kcg-gw-profile__hint {
	margin: 0 0 22px;
	color: #4a5568;
}

.kcg-gw-profile__set {
	margin: 0 0 28px;
	padding: 22px;
	border: 1px solid #dde3ec;
	border-radius: 8px;
}

.kcg-gw-profile__set legend {
	padding: 0 10px;
	font-size: 19px;
	font-weight: 600;
	color: #283971;
}

.kcg-gw-profile__row {
	margin: 0 0 20px;
}

.kcg-gw-profile__row:last-child {
	margin-bottom: 0;
}

.kcg-gw-profile__row label {
	display: block;
	margin-bottom: 6px;
	font-weight: 600;
	color: #2d3748;
}

.kcg-gw-profile__row--check label {
	font-weight: 400;
}

.kcg-gw-profile__row input[type="text"],
.kcg-gw-profile__row input[type="tel"],
.kcg-gw-profile__row input[type="url"],
.kcg-gw-profile__row input[type="email"],
.kcg-gw-profile__row textarea {
	width: 100%;
	padding: 12px;
	font-family: inherit;
	font-size: 16px;
	line-height: 1.5;
	color: #2d3748;
	background: #ffffff;
	border: 1px solid #c3cbd9;
	border-radius: 6px;
}

.kcg-gw-profile__row input:focus,
.kcg-gw-profile__row textarea:focus,
.kcg-gw-profile__pickrow select:focus {
	outline: 3px solid rgba(40, 57, 113, 0.35);
	outline-offset: 1px;
	border-color: #283971;
}

.kcg-gw-profile__row input[type="file"] {
	width: 100%;
	padding: 12px;
	background: #f7fafc;
	border: 1px dashed #9aa7bd;
	border-radius: 6px;
	font-size: 15px;
}

.kcg-gw-profile__help {
	display: block;
	margin-top: 6px;
	font-size: 14px;
	color: #5a6b82;
}

.kcg-gw-profile__panel {
	padding: 16px 0;
	border-top: 1px solid #eef1f6;
}

.kcg-gw-profile__panel:first-of-type {
	border-top: 0;
	padding-top: 0;
}

/* Honeypot. Off-screen rather than display:none, which some bots check for. */
.kcg-gw-profile__hp {
	position: absolute;
	left: -9999px;
	width: 1px;
	height: 1px;
	overflow: hidden;
}

/* ---------------------------------------------------------------------
 * Photo and work
 * ------------------------------------------------------------------ */

.kcg-gw-profile__photo {
	display: flex;
	gap: 20px;
	align-items: flex-start;
	flex-wrap: wrap;
}

.kcg-gw-profile__thumb {
	width: 120px;
	height: 120px;
	flex: 0 0 120px;
	object-fit: cover;
	border-radius: 50%;
	border: 3px solid #d4b45a;
	background: #eef1f6;
}

.kcg-gw-profile__thumb--none {
	display: block;
}

.kcg-gw-profile__photofields {
	flex: 1 1 300px;
}

.kcg-gw-profile__works {
	list-style: none;
	margin: 0 0 22px;
	padding: 0;
	display: grid;
	gap: 16px;
	grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
}

.kcg-gw-profile__work {
	padding: 14px;
	background: #f7fafc;
	border: 1px solid #dde3ec;
	border-radius: 8px;
}

.kcg-gw-profile__work img {
	display: block;
	width: 100%;
	height: 150px;
	object-fit: cover;
	border-radius: 4px;
	margin-bottom: 10px;
}

.kcg-gw-profile__worktitle span {
	display: block;
	margin-bottom: 4px;
	font-size: 14px;
	font-weight: 600;
}

.kcg-gw-profile__worktitle input {
	width: 100%;
	padding: 9px;
	font-size: 15px;
	border: 1px solid #c3cbd9;
	border-radius: 4px;
}

.kcg-gw-profile__workdrop {
	display: block;
	margin-top: 10px;
	font-size: 14px;
	color: #7a1c1c;
}

/* ---------------------------------------------------------------------
 * Buttons
 * ------------------------------------------------------------------ */

.kcg-gw-profile__btn {
	display: inline-block;
	padding: 13px 28px;
	min-height: 48px;
	background: #283971;
	color: #ffffff;
	border: 2px solid #283971;
	border-radius: 25px;
	font-family: inherit;
	font-size: 16px;
	font-weight: 500;
	cursor: pointer;
}

.kcg-gw-profile__btn:hover,
.kcg-gw-profile__btn:focus {
	background: #1c2a52;
	border-color: #1c2a52;
	color: #ffffff;
}

.kcg-gw-profile__btn--go {
	padding: 15px 42px;
	font-size: 17px;
}

.kcg-gw-profile__actions {
	display: flex;
	flex-wrap: wrap;
	gap: 18px;
	align-items: center;
	padding-top: 6px;
}

.kcg-gw-profile__view {
	color: #283971;
	font-weight: 500;
}

@media (max-width: 600px) {
	.kcg-gw-profile__set {
		padding: 16px;
	}

	.kcg-gw-profile__who {
		font-size: 22px;
	}

	.kcg-gw-profile__standing {
		display: block;
		margin: 8px 0 0;
		width: fit-content;
	}

	.kcg-gw-profile__actions,
	.kcg-gw-profile__pickrow {
		flex-direction: column;
		align-items: stretch;
	}

	.kcg-gw-profile__btn {
		width: 100%;
	}
}

/* ---------------------------------------------------------------------
 * A piece with no photograph on it yet
 * ------------------------------------------------------------------ */

.kcg-gw-profile__work--noimage {
	border-color: #b7791f;
	background: #fffaf0;
}

.kcg-gw-profile__missing {
	display: flex;
	align-items: center;
	justify-content: center;
	height: 150px;
	margin-bottom: 10px;
	border: 1px dashed #b7791f;
	border-radius: 4px;
	background: #fff5e0;
	color: #6b4708;
	font-size: 14px;
	text-align: center;
}

.kcg-gw-profile__workswap {
	display: block;
	margin-top: 10px;
}

.kcg-gw-profile__workswap span {
	display: block;
	margin-bottom: 4px;
	font-size: 14px;
	font-weight: 600;
}

.kcg-gw-profile__workswap input[type="file"] {
	width: 100%;
	padding: 8px;
	font-size: 13px;
	background: #ffffff;
	border: 1px dashed #9aa7bd;
	border-radius: 4px;
}


/* ---------------------------------------------------------------------
 * Positioning a photograph inside its circle
 *
 * The frame here is the same shape as the one on the artist's page and
 * uses the same rules, so what the artist drags into view is literally
 * what gets published. Nothing is cut from the file — only the numbers
 * describing where the picture sits are saved.
 * ------------------------------------------------------------------ */

.kcg-gw-crop {
	flex: 0 0 260px;
	max-width: 100%;
}

.kcg-gw-crop__frame {
	position: relative;
	width: 100%;
	max-width: 260px;
	margin: 0 auto;
	aspect-ratio: 1 / 1;
	overflow: hidden;
	border: 3px solid #d4b45a;
	border-radius: 50%;
	background: #eef1f6;
	cursor: grab;
	/* Keeps a finger drag from scrolling the page underneath it. */
	touch-action: none;
	-webkit-user-select: none;
	user-select: none;
}

.kcg-gw-crop__frame:focus-visible {
	outline: 3px solid #283971;
	outline-offset: 3px;
}

.kcg-gw-crop__frame.is-dragging {
	cursor: grabbing;
}

.kcg-gw-crop__frame img {
	display: block;
	width: 100%;
	height: 100%;
	max-width: none;
	margin: 0;
	border: 0;
	border-radius: 0;
	object-fit: cover;
	object-position: var(--kcg-x, 50%) var(--kcg-y, 50%);
	transform: scale(var(--kcg-zoom, 1));
	transform-origin: var(--kcg-x, 50%) var(--kcg-y, 50%);
	pointer-events: none;
	-webkit-user-drag: none;
}

.kcg-gw-crop__hint {
	margin: 10px 0 6px;
	font-size: 13px;
	line-height: 1.45;
	color: #4a5568;
	text-align: center;
}

.kcg-gw-crop__zoomrow {
	display: flex;
	gap: 10px;
	align-items: center;
	flex-wrap: wrap;
	justify-content: center;
	margin: 0;
}

.kcg-gw-crop__zoomrow label {
	font-size: 14px;
	font-weight: 600;
	color: #2d3748;
}

.kcg-gw-crop__zoom {
	flex: 1 1 110px;
	min-width: 110px;
	/* A range slider is a fiddly target on a phone, so give it room. */
	height: 34px;
}

.kcg-gw-crop__reset {
	min-height: 34px;
	padding: 6px 14px;
	font-size: 14px;
	color: #283971;
	background: #ffffff;
	border: 1px solid #9aa7bd;
	border-radius: 4px;
	cursor: pointer;
}

.kcg-gw-crop__reset:hover {
	background: #eef1f6;
}

@media (max-width: 600px) {
	.kcg-gw-crop {
		flex: 1 1 100%;
	}
}

/* Shown only when the photograph has no slack to slide within the circle. */
.kcg-gw-crop__stuck {
	display: none;
	margin: 0 0 8px;
	padding: 8px 10px;
	font-size: 13px;
	line-height: 1.45;
	color: #6b4708;
	text-align: center;
	background: #fff5e0;
	border: 1px dashed #b7791f;
	border-radius: 4px;
}

.kcg-gw-crop.is-stuck .kcg-gw-crop__stuck {
	display: block;
}

/* ---------------------------------------------------------------------
 * The same circle on the admin side, where a portrait is chosen from the
 * library rather than uploaded.
 * ------------------------------------------------------------------ */

.kcg-gw-crop--admin {
	margin-bottom: 10px;
}

.kcg-gw-crop.is-empty .kcg-gw-crop__frame {
	border-style: dashed;
}

.kcg-gw-crop.is-empty .kcg-gw-crop__frame img,
.kcg-gw-crop.is-empty .kcg-gw-crop__hint,
.kcg-gw-crop.is-empty .kcg-gw-crop__stuck,
.kcg-gw-crop.is-empty .kcg-gw-crop__zoomrow {
	display: none;
}

.kcg-gw-pick {
	display: flex;
	gap: 14px;
	align-items: center;
	flex-wrap: wrap;
}
