/**
 * NetGuard SELECT form styles.
 *
 * Scoped under .ng-form-wrapper to avoid clashing with theme styles.
 *
 * @package NetGuard_Cyber
 */

.ng-form-wrapper {
	--ng-primary: #15445d;   /* Falcon West dark blue */
	--ng-hover: #3d96d2;     /* button rollover blue */
	--ng-accent: #d2793d;    /* links / alerts / kicker */
	--ng-error: #d2793d;
	--ng-white: #fcfefe;
	--ng-gray: #434343;      /* muted text */
	--ng-border: #d0d5dd;
	--ng-bg: #f8fafc;
	--ng-text: #080808;
	max-width: 760px;
	margin: 0 auto;
	color: var(--ng-text);
	font-family: "Crimson Text", Georgia, serif;
	font-size: 16px;
	line-height: 1.5;
}

.ng-form-wrapper * {
	box-sizing: border-box;
}

/* Author display rules below (flex on buttons, progress steps, …) would
   otherwise override the UA stylesheet's [hidden] { display: none }. */
.ng-form-wrapper [hidden] {
	display: none !important;
}

.ng-form-wrapper a:not(.ng-btn) {
	color: var(--ng-accent);
}

/* Progress indicator */
.ng-progress {
	display: flex;
	flex-wrap: wrap;
	gap: 4px;
	list-style: none;
	margin: 0 0 28px;
	padding: 0;
	counter-reset: ng-step;
}

.ng-progress-step {
	display: flex;
	align-items: center;
	gap: 6px;
	flex: 1 1 auto;
	min-width: 0;
	font-size: 12px;
	color: var(--ng-gray);
	opacity: 0.7;
}

.ng-progress-num {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 26px;
	height: 26px;
	border-radius: 50%;
	background: #e4e7ec;
	color: var(--ng-gray);
	font-weight: 600;
	flex-shrink: 0;
}

/* The active step indicator is white (the form typically sits on a
   colored page background). */
.ng-progress-step.is-active {
	opacity: 1;
	color: var(--ng-white);
	font-weight: 600;
}

.ng-progress-step.is-active .ng-progress-num {
	background: var(--ng-white);
	color: var(--ng-primary);
	box-shadow: 0 0 0 1px var(--ng-border);
}

.ng-progress-step.is-done {
	opacity: 1;
	color: #12b76a;
}

.ng-progress-step.is-done .ng-progress-num {
	background: #12b76a;
	color: var(--ng-white);
}

.ng-progress-label {
	white-space: nowrap;
	overflow: hidden;
	text-overflow: ellipsis;
}

/* Steps */
.ng-step {
	background: var(--ng-white);
	border: 1px solid var(--ng-border);
	border-radius: 12px;
	padding: 28px;
	box-shadow: 0 1px 3px rgba( 16, 24, 40, 0.06 );
}

/* Persistent context line shown above every step title. Deliberately the
   same size/weight as the field labels, NOT heading-sized. */
.ng-step-kicker {
	margin: 0 0 6px;
	font-size: 16px;
	font-weight: 600;
	color: var(--ng-accent);
}

.ng-step-title {
	margin: 0 0 20px;
	font-family: Raleway, "Helvetica Neue", Arial, sans-serif;
	font-weight: 800;
	font-size: 22px;
	color: var(--ng-primary);
}

.ng-field {
	margin-bottom: 20px;
	border: 0;
	padding: 0;
}

.ng-field > label,
.ng-field > legend {
	display: block;
	font-weight: 600;
	margin-bottom: 6px;
}

.ng-req {
	color: var(--ng-error);
}

.ng-field input[type="text"],
.ng-field input[type="email"],
.ng-field input[type="tel"],
.ng-field input[type="date"],
.ng-field select,
.ng-field textarea {
	width: 100%;
	padding: 10px 12px;
	border: 1px solid var(--ng-border);
	border-radius: 8px;
	font-family: inherit; /* Form controls do not inherit fonts by default. */
	font-size: 16px;
	background: var(--ng-white);
	color: var(--ng-text);
}

.ng-field input:focus,
.ng-field select:focus,
.ng-field textarea:focus {
	outline: none;
	border-color: var(--ng-primary);
	box-shadow: 0 0 0 3px rgba( 21, 68, 93, 0.15 );
}

/* First/last name and city/state/ZIP inputs share one line */
.ng-name-row,
.ng-address-row {
	display: flex;
	gap: 16px;
}

.ng-name-row .ng-field {
	flex: 1 1 0;
}

.ng-address-row .ng-address-city {
	flex: 2 1 0;
}

.ng-address-row .ng-address-state,
.ng-address-row .ng-address-zip {
	flex: 1 1 0;
}

.ng-field-hint {
	font-size: 13px;
	color: var(--ng-gray);
	margin: 6px 0 0;
}

.ng-radio,
.ng-check {
	display: flex;
	align-items: flex-start;
	gap: 10px;
	margin-bottom: 10px;
	font-weight: 400;
	cursor: pointer;
}

.ng-radio input,
.ng-check input {
	margin-top: 3px;
	flex-shrink: 0;
}

.ng-tier {
	border: 1px solid var(--ng-border);
	border-radius: 8px;
	padding: 14px;
	transition: border-color 0.15s;
}

.ng-tier:has( input:checked ) {
	border-color: var(--ng-primary);
	background: rgba( 21, 68, 93, 0.05 );
}

/* Disclosure text blocks */
.ng-disclosure {
	background: var(--ng-bg);
	border: 1px solid var(--ng-border);
	border-radius: 8px;
	padding: 16px 18px;
	margin-bottom: 20px;
	max-height: 320px;
	overflow-y: auto;
	font-size: 14px;
	line-height: 1.6;
}

.ng-disclosure p {
	margin: 0 0 12px;
}

.ng-disclosure h3 {
	margin: 16px 0 8px;
	font-family: Raleway, "Helvetica Neue", Arial, sans-serif;
	font-weight: 800;
	font-size: 15px;
}

/* Signature */
.ng-signature-wrap {
	border: 1px dashed var(--ng-border);
	border-radius: 8px;
	padding: 12px;
	background: var(--ng-white);
}

.ng-signature-canvas {
	width: 100%;
	height: auto;
	touch-action: none;
	background: var(--ng-white);
	border-bottom: 2px solid var(--ng-gray);
	cursor: crosshair;
	display: block;
}

.ng-signature-actions {
	margin-top: 10px;
	text-align: right;
}

/* Errors + notices */
.ng-error {
	display: block;
	color: var(--ng-error);
	font-size: 13px;
	margin-top: 6px;
	min-height: 1em;
}

.ng-inline-notice {
	background: rgba( 210, 121, 61, 0.08 );
	border: 1px solid rgba( 210, 121, 61, 0.45 );
	border-radius: 8px;
	padding: 12px 14px;
	font-size: 14px;
	margin: 12px 0 0;
}

.ng-form-error {
	color: var(--ng-error);
	font-weight: 600;
	margin-top: 14px;
}

.ng-notice {
	background: var(--ng-bg);
	border: 1px solid var(--ng-border);
	border-radius: 8px;
	padding: 18px;
	text-align: center;
}

/* Buttons */
.ng-step-nav {
	display: flex;
	justify-content: space-between;
	gap: 12px;
	margin-top: 24px;
}

.ng-btn {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	background: var(--ng-primary);
	color: var(--ng-white);
	border: none;
	border-radius: 8px;
	padding: 12px 22px;
	font-family: inherit;
	font-size: 16px;
	font-weight: 600;
	cursor: pointer;
	text-decoration: none;
	transition: background 0.15s;
}

.ng-btn:hover {
	background: var(--ng-hover);
	color: var(--ng-white);
}

.ng-btn:disabled {
	opacity: 0.6;
	cursor: not-allowed;
}

.ng-btn.ng-secondary {
	background: var(--ng-white);
	color: var(--ng-primary);
	border: 1px solid var(--ng-border);
}

.ng-btn.ng-secondary:hover {
	background: var(--ng-bg);
	color: var(--ng-primary);
}

.ng-next,
.ng-submit,
.ng-pay-btn,
.ng-contact-btn {
	margin-left: auto;
}

/* Review */
.ng-review-list {
	display: grid;
	grid-template-columns: 40% 60%;
	gap: 0;
	margin: 0 0 20px;
	border: 1px solid var(--ng-border);
	border-radius: 8px;
	overflow: hidden;
}

.ng-review-list dt {
	background: var(--ng-bg);
	padding: 10px 14px;
	font-weight: 600;
	border-bottom: 1px solid var(--ng-border);
}

.ng-review-list dd {
	margin: 0;
	padding: 10px 14px;
	border-bottom: 1px solid var(--ng-border);
	word-break: break-word;
}

.ng-review-signature {
	margin-bottom: 20px;
}

.ng-review-label {
	display: block;
	font-weight: 600;
	margin-bottom: 6px;
}

.ng-review-signature img {
	max-width: 300px;
	border: 1px solid var(--ng-border);
	border-radius: 6px;
	background: var(--ng-white); /* Signature PNGs are transparent for PDF stamping. */
}

/* Payment */
.ng-epay-hosted-field {
	/* Container for an ePay hosted-field iframe. */
	min-height: 44px;
	padding: 4px 8px;
	border: 1px solid var(--ng-border);
	border-radius: 8px;
	background: var(--ng-white);
}

.ng-epay-status {
	font-size: 14px;
	color: var(--ng-accent);
}

.ng-payment-summary {
	background: var(--ng-bg);
	border-radius: 8px;
	padding: 14px 16px;
	margin-bottom: 20px;
}

.ng-payment-row {
	display: flex;
	gap: 16px;
}

.ng-payment-row .ng-field {
	flex: 1;
}

/* Success */
.ng-success {
	text-align: center;
}

.ng-success-icon {
	width: 64px;
	height: 64px;
	margin: 0 auto 16px;
	border-radius: 50%;
	background: #12b76a;
	color: var(--ng-white);
	font-size: 34px;
	line-height: 64px;
}

.ng-success-message {
	font-size: 17px;
	margin-bottom: 20px;
}

/* Responsive */
@media ( max-width: 600px ) {
	.ng-step {
		padding: 20px 16px;
	}

	.ng-progress-label {
		display: none;
	}

	.ng-review-list {
		grid-template-columns: 1fr;
	}

	.ng-payment-row {
		flex-direction: column;
		gap: 0;
	}

	.ng-name-row,
	.ng-address-row {
		flex-direction: column;
		gap: 0;
	}
}
