/**
 * Talent Pool — frontend application form styles.
 * Scoped under .tp-form-wrap so it never leaks into the host theme.
 */

.tp-form-wrap {
	/* HeyElevate brand palette */
	--tp-primary: #3a31e0;       /* indigo CTA (matches "Join Talent Pool") */
	--tp-primary-dark: #2a22c2;
	--tp-violet: #6d5cf0;         /* progress / accent violet */
	--tp-bg: #ffffff;
	--tp-muted: #6b6b80;
	--tp-border: #e7e6f0;
	--tp-ring: rgba(58, 49, 224, .16);
	--tp-error: #dc2626;
	--tp-radius: 18px;
	--tp-text: #161325;          /* near-black navy headings/text */

	max-width: 760px;
	margin: 0 auto;
	color: var(--tp-text);
	/* Inherit the theme's font so the form blends into HeyElevate. */
	font-family: inherit;
	background: var(--tp-bg);
	border: 1px solid var(--tp-border);
	border-radius: var(--tp-radius);
	box-shadow: 0 18px 50px -22px rgba(22, 19, 37, .35);
	padding: clamp(22px, 4vw, 44px);
	box-sizing: border-box;
}

.tp-form-wrap *,
.tp-form-wrap *::before,
.tp-form-wrap *::after {
	box-sizing: border-box;
}

/* Steps indicator */
.tp-steps {
	display: flex;
	justify-content: space-between;
	list-style: none;
	margin: 0 0 18px;
	padding: 0;
	counter-reset: step;
}

.tp-step {
	display: flex;
	align-items: center;
	gap: 10px;
	flex: 1;
	color: var(--tp-muted);
	font-size: 14px;
	font-weight: 500;
}

.tp-step:not(:last-child)::after {
	content: "";
	flex: 1;
	height: 2px;
	background: var(--tp-border);
	margin: 0 8px;
}

.tp-step-dot {
	width: 30px;
	height: 30px;
	border-radius: 50%;
	display: grid;
	place-items: center;
	background: #f3f4f6;
	color: var(--tp-muted);
	font-weight: 700;
	font-size: 14px;
	flex: 0 0 auto;
	transition: all .25s ease;
}

.tp-step.is-active .tp-step-dot,
.tp-step.is-complete .tp-step-dot {
	background: var(--tp-primary);
	color: #fff;
	box-shadow: 0 0 0 4px var(--tp-ring);
}

.tp-step.is-active .tp-step-label,
.tp-step.is-complete .tp-step-label {
	color: var(--tp-text);
}

.tp-step-label { white-space: nowrap; }

/* Progress bar */
.tp-progress {
	height: 6px;
	background: #f3f4f6;
	border-radius: 999px;
	overflow: hidden;
	margin-bottom: 28px;
}

.tp-progress-bar {
	display: block;
	height: 100%;
	background: linear-gradient(90deg, var(--tp-primary), var(--tp-violet));
	border-radius: 999px;
	transition: width .35s ease;
}

/* Panels */
.tp-panel { display: none; animation: tp-fade .3s ease; }
.tp-panel.is-active { display: block; }

@keyframes tp-fade {
	from { opacity: 0; transform: translateY(6px); }
	to { opacity: 1; transform: translateY(0); }
}

.tp-panel-head { margin-bottom: 22px; }
.tp-panel-head h2 { margin: 0 0 4px; font-size: 20px; font-weight: 700; }
.tp-panel-head p { margin: 0; color: var(--tp-muted); font-size: 14px; }

/* Fields */
.tp-grid {
	display: grid;
	grid-template-columns: 1fr 1fr;
	gap: 18px;
}

.tp-field { display: flex; flex-direction: column; }
.tp-col-2 { grid-column: 1 / -1; }

.tp-field label {
	font-size: 13px;
	font-weight: 600;
	margin-bottom: 6px;
	color: #374151;
}

.tp-req { color: var(--tp-primary); }
.tp-opt { color: var(--tp-muted); font-weight: 400; }

.tp-field input,
.tp-field select,
.tp-field textarea {
	width: 100%;
	padding: 11px 13px;
	border: 1px solid var(--tp-border);
	border-radius: 10px;
	font-size: 15px;
	background: #fff;
	color: var(--tp-text);
	transition: border-color .15s ease, box-shadow .15s ease;
	font-family: inherit;
}

.tp-field textarea { resize: vertical; min-height: 84px; }

.tp-field input:focus,
.tp-field select:focus,
.tp-field textarea:focus {
	outline: none;
	border-color: var(--tp-primary);
	box-shadow: 0 0 0 4px var(--tp-ring);
}

.tp-field.has-error input,
.tp-field.has-error select,
.tp-field.has-error textarea {
	border-color: var(--tp-error);
	box-shadow: 0 0 0 4px rgba(220, 38, 38, .12);
}

.tp-error {
	color: var(--tp-error);
	font-size: 12.5px;
	margin-top: 5px;
	min-height: 0;
	display: none;
}

.tp-field.has-error .tp-error { display: block; }

/* File input */
.tp-file {
	position: relative;
	border: 1.5px dashed var(--tp-border);
	border-radius: 10px;
	padding: 16px;
	text-align: center;
	color: var(--tp-muted);
	cursor: pointer;
	transition: border-color .15s ease, background .15s ease;
}

.tp-file:hover { border-color: var(--tp-primary); background: #fafaff; }
.tp-file input[type="file"] {
	position: absolute;
	inset: 0;
	opacity: 0;
	cursor: pointer;
	width: 100%;
	height: 100%;
}
.tp-file.has-file { border-style: solid; border-color: var(--tp-primary); color: var(--tp-text); background: #f5f5ff; }
.tp-file-text { font-size: 14px; font-weight: 500; }

/* Buttons */
.tp-actions {
	display: flex;
	justify-content: space-between;
	align-items: center;
	margin-top: 28px;
	gap: 12px;
}

.tp-btn {
	appearance: none;
	border: none;
	cursor: pointer;
	font-size: 15px;
	font-weight: 600;
	padding: 13px 28px;
	border-radius: 12px;
	transition: transform .08s ease, background .15s ease, box-shadow .15s ease;
	font-family: inherit;
}

.tp-btn:active { transform: translateY(1px); }

.tp-btn-primary {
	background: var(--tp-primary);
	color: #fff;
	box-shadow: 0 10px 22px -8px var(--tp-primary);
}
.tp-btn-primary:hover { background: var(--tp-primary-dark); }
.tp-btn-primary:disabled { opacity: .65; cursor: not-allowed; }

.tp-btn-ghost {
	background: #f3f4f6;
	color: #374151;
}
.tp-btn-ghost:hover { background: #e5e7eb; }

/* Review step */
.tp-review {
	display: grid;
	gap: 10px;
	margin-bottom: 20px;
}

.tp-review-group {
	border: 1px solid var(--tp-border);
	border-radius: 12px;
	padding: 16px 18px;
}
.tp-review-group h3 {
	margin: 0 0 10px;
	font-size: 13px;
	text-transform: uppercase;
	letter-spacing: .4px;
	color: var(--tp-muted);
}
.tp-review-item {
	display: flex;
	justify-content: space-between;
	gap: 16px;
	padding: 5px 0;
	font-size: 14px;
}
.tp-review-item .tp-review-label { color: var(--tp-muted); }
.tp-review-item .tp-review-value { font-weight: 600; text-align: right; word-break: break-word; }

.tp-consent {
	display: flex;
	gap: 10px;
	align-items: flex-start;
	font-size: 13.5px;
	color: #374151;
	margin-bottom: 6px;
	line-height: 1.5;
}
.tp-consent input { margin-top: 3px; }

/* Messages */
.tp-form-message {
	margin-top: 16px;
	padding: 12px 16px;
	border-radius: 10px;
	font-size: 14px;
	display: none;
}
.tp-form-message.is-error {
	display: block;
	background: #fef2f2;
	color: var(--tp-error);
	border: 1px solid #fecaca;
}

/* Success state */
.tp-success { text-align: center; padding: 30px 10px; }
.tp-success-icon {
	width: 72px;
	height: 72px;
	border-radius: 50%;
	background: #ecfdf5;
	color: #059669;
	display: grid;
	place-items: center;
	font-size: 38px;
	margin: 0 auto 18px;
}
.tp-success h2 { margin: 0 0 8px; font-size: 22px; }
.tp-success p { color: var(--tp-muted); font-size: 15px; margin: 0; }

/* Empty state */
.tp-empty { text-align: center; padding: 30px 10px; color: var(--tp-muted); }
.tp-empty h3 { color: var(--tp-text); margin: 0 0 6px; }

/* Responsive */
@media (max-width: 600px) {
	.tp-grid { grid-template-columns: 1fr; }
	.tp-step-label { display: none; }
	.tp-step:not(:last-child)::after { margin: 0 4px; }
}
