/**
 * ATS custom application form — frontend styles.
 *
 * @package ATS_Job_Board
 */

.ats-cf-container { max-width: 720px; margin: 0 auto; }
.ats-cf-required { color: #d63638; }

/* Fields */
.ats-cf-field { margin: 0 0 16px; }
.ats-cf-field > label { display: block; font-weight: 600; margin-bottom: 4px; }
.ats-cf-input,
.ats-cf-field input[type="text"],
.ats-cf-field input[type="email"],
.ats-cf-field input[type="tel"],
.ats-cf-field input[type="number"],
.ats-cf-field input[type="date"],
.ats-cf-field input[type="password"],
.ats-cf-field textarea,
.ats-cf-field select {
	width: 100%;
	padding: 9px 12px;
	border: 1px solid #c3c4c7;
	border-radius: 4px;
	font-size: 15px;
	box-sizing: border-box;
}
.ats-cf-field textarea { min-height: 110px; }
.ats-cf-field small { color: #666; }
.ats-cf-field.ats-cf-error input,
.ats-cf-field.ats-cf-error textarea,
.ats-cf-field.ats-cf-error select { border-color: #d63638; }
.ats-cf-field input:focus,
.ats-cf-field textarea:focus,
.ats-cf-field select:focus {
	outline: none;
	border-color: var( --ats-color-primary, #2271b1 );
	box-shadow: 0 0 0 1px var( --ats-color-primary, #2271b1 );
}

.ats-cf-group-label { display: block; font-weight: 600; margin-bottom: 6px; }
.ats-cf-option { display: block; margin: 4px 0; font-weight: 400; }
.ats-cf-help { display: inline-block; width: 16px; height: 16px; line-height: 16px; text-align: center; border-radius: 50%; background: #e0e0e0; font-size: 11px; cursor: help; }

.ats-cf-section { margin-bottom: 8px; }
.ats-cf-section-heading { margin: 18px 0 10px; color: var( --ats-color-primary, #2271b1 ); }
.ats-cf-page-title { margin: 0 0 6px; }
.ats-cf-page-desc { color: #555; margin: 0 0 16px; }

/* EDI page */
.ats-cf-edi-notice {
	background: #fbf4e6;
	border: 1px solid #e3c98a;
	border-radius: 4px;
	padding: 12px 14px;
	margin: 0 0 16px;
	font-size: 14px;
}

/* Currently employed / attending toggle */
.ats-cf-present-label { display: inline-flex; align-items: center; gap: 6px; margin-top: 6px; font-size: 14px; font-weight: 400; cursor: pointer; }
.ats-cf-date-display:disabled { opacity: .5; cursor: not-allowed; }

/* Signature */
.ats-cf-signature-canvas { border: 1px solid #c3c4c7; border-radius: 4px; touch-action: none; background: #fff; display: block; }
.ats-cf-signature-controls { margin-top: 6px; }

/* Repeatable */
.ats-cf-repeatable-item {
	border: 1px solid #e0e0e0;
	border-radius: 4px;
	padding: 12px;
	margin: 8px 0;
	background: #fafafa;
}
.ats-cf-subfield { margin-bottom: 10px; }
.ats-cf-subfield label { display: block; font-weight: 600; margin-bottom: 4px; }
.ats-cf-subfield-options { display: block; }
.ats-cf-subfield-options .ats-cf-option { display: block; font-weight: 400; margin: 2px 0; }
.ats-cf-repeatable-actions { text-align: right; }

/* Progress */
.ats-cf-progress { margin: 16px 0 24px; }
.ats-cf-progress-bar { height: 8px; background: #e6e6e6; border-radius: 4px; overflow: hidden; }
.ats-cf-progress-fill { display: block; height: 100%; width: 0; background: var( --ats-color-primary, #2271b1 ); transition: width .25s ease; }
.ats-cf-progress-steps { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 8px; }
.ats-cf-step { font-size: 12px; color: #888; }
.ats-cf-step.is-current { color: var( --ats-color-primary, #2271b1 ); font-weight: 700; }
.ats-cf-step.is-done { color: #2e7d32; }

/* Nav + buttons */
.ats-cf-nav { display: flex; align-items: center; gap: 12px; margin-top: 24px; }
.ats-cf-nav .ats-cf-next,
.ats-cf-nav .ats-cf-submit { margin-left: auto; }
.ats-cf-btn {
	padding: 10px 18px;
	border: 1px solid var( --ats-color-primary, #2271b1 );
	border-radius: 4px;
	background: #fff;
	color: var( --ats-color-primary, #2271b1 );
	font-size: 15px;
	cursor: pointer;
}
.ats-cf-btn-primary {
	background: var( --ats-color-button-bg, #2271b1 );
	color: var( --ats-color-button-text, #fff );
	border-color: var( --ats-color-button-bg, #2271b1 );
}
.ats-cf-btn-primary:hover { background: var( --ats-color-button-hover, #1d4ed8 ); border-color: var( --ats-color-button-hover, #1d4ed8 ); }
.ats-cf-btn[disabled] { opacity: .6; cursor: default; }
.ats-cf-save-status { font-size: 13px; color: #2e7d32; }
.ats-cf-save-status.error { color: #d63638; }

/* Auth gate */
.ats-cf-auth-tabs { display: flex; gap: 8px; margin: 16px 0; }
.ats-cf-tab {
	padding: 8px 16px;
	border: 1px solid var( --ats-color-secondary, #64748b );
	background: var( --ats-color-secondary, #64748b );
	color: var( --ats-color-button-text, #fff );
	border-radius: 4px;
	cursor: pointer;
}
.ats-cf-tab.is-active { background: var( --ats-color-primary, #2271b1 ); color: var( --ats-color-button-text, #fff ); border-color: var( --ats-color-primary, #2271b1 ); }
.ats-cf-auth-msg.error { color: #d63638; margin: 8px 0; }
.ats-cf-success { padding: 24px; background: #edf7ed; border: 1px solid #2e7d32; border-radius: 4px; text-align: center; }
.ats-cf-thankyou { text-align: left; }
.ats-cf-thankyou > :first-child { margin-top: 0; }
.ats-cf-thankyou > :last-child { margin-bottom: 0; }
