/* ==========================================================================
   SEOvault AI — Onboarding Wizard Styles
   ========================================================================== */

.seovaultseo-wizard {
	max-width: 720px;
	margin: 24px auto;
	padding: 0 16px;
	box-sizing: border-box;
}

.seovaultseo-wizard * {
	box-sizing: border-box;
}

.seovaultseo-wizard-container {
	background: var(--seovaultseo-card-bg, #FFFFFF);
	border: 1px solid var(--seovaultseo-border, #E5E7EB);
	border-radius: var(--seovaultseo-radius, 8px);
	box-shadow: var(--seovaultseo-shadow, 0 4px 6px -1px rgba(0, 0, 0, 0.05), 0 2px 4px -1px rgba(0, 0, 0, 0.03));
	overflow: hidden;
}

/* Header & Stepper */
.seovaultseo-wizard-header {
	padding: 24px 24px 0;
	background: linear-gradient(135deg, #142e5d 0%, #1e4a7a 60%, #1db569 100%);
	border-bottom: 1px solid var(--seovaultseo-border, #E5E7EB);
}

.seovaultseo-wizard-header .seovaultseo-wizard-step-label {
	color: rgba(255, 255, 255, 0.85);
	font-weight: 500;
}

.seovaultseo-wizard-header .seovaultseo-wizard-step-active .seovaultseo-wizard-step-label {
	color: #fff;
	font-weight: 600;
}

.seovaultseo-wizard-header .seovaultseo-wizard-step-completed .seovaultseo-wizard-step-label {
	color: #d1fae5;
}

.seovaultseo-wizard-header .seovaultseo-wizard-step-number {
	background: rgba(255, 255, 255, 0.9);
	border-color: rgba(255, 255, 255, 0.9);
	color: #142e5d;
}

.seovaultseo-wizard-header .seovaultseo-wizard-step-active .seovaultseo-wizard-step-number {
	background: var(--seovaultseo-primary, #0D9488);
	border-color: #fff;
	color: #fff;
}

.seovaultseo-wizard-header .seovaultseo-wizard-step-completed .seovaultseo-wizard-step-number {
	background: var(--seovaultseo-success, #059669);
	border-color: #fff;
	color: #fff;
}

.seovaultseo-wizard-header .seovaultseo-wizard-step::after {
	background: rgba(255, 255, 255, 0.35);
}

.seovaultseo-wizard-header .seovaultseo-wizard-step-completed::after {
	background: #d1fae5;
}

.seovaultseo-wizard-logo {
	display: block;
	width: 80px;
	height: 80px;
	margin: 0 auto 16px;
}

.seovaultseo-wizard-logo img,
.seovaultseo-wizard-logo svg {
	width: 100%;
	height: 100%;
	object-fit: contain;
}

.seovaultseo-wizard-stepper {
	display: flex;
	justify-content: space-between;
	align-items: flex-start;
	padding: 0 0 24px;
	margin: 0;
}

.seovaultseo-wizard-step {
	flex: 1;
	display: flex;
	flex-direction: column;
	align-items: center;
	gap: 8px;
	position: relative;
	text-align: center;
}

.seovaultseo-wizard-step::after {
	content: '';
	position: absolute;
	top: 16px;
	left: 50%;
	width: 100%;
	height: 2px;
	background: var(--seovaultseo-border, #E5E7EB);
	z-index: 0;
}

.seovaultseo-wizard-step:last-child::after {
	display: none;
}

.seovaultseo-wizard-step-number {
	width: 32px;
	height: 32px;
	border-radius: 50%;
	display: flex;
	align-items: center;
	justify-content: center;
	font-size: 13px;
	font-weight: 600;
	background: var(--seovaultseo-bg, #F8F9FA);
	color: var(--seovaultseo-muted, #6B7280);
	border: 2px solid var(--seovaultseo-border, #E5E7EB);
	position: relative;
	z-index: 1;
}

.seovaultseo-wizard-step-number .dashicons {
	font-size: 18px;
	width: 18px;
	height: 18px;
}

.seovaultseo-wizard-step-label {
	font-size: 11px;
	font-weight: 500;
	color: var(--seovaultseo-muted, #6B7280);
	line-height: 1.2;
	max-width: 80px;
}

.seovaultseo-wizard-step-active .seovaultseo-wizard-step-number {
	background: var(--seovaultseo-primary, #0D9488);
	border-color: var(--seovaultseo-primary, #0D9488);
	color: #fff;
}

.seovaultseo-wizard-step-active .seovaultseo-wizard-step-label {
	color: var(--seovaultseo-primary, #0D9488);
	font-weight: 600;
}

.seovaultseo-wizard-step-completed .seovaultseo-wizard-step-number {
	background: var(--seovaultseo-success, #059669);
	border-color: var(--seovaultseo-success, #059669);
	color: #fff;
}

.seovaultseo-wizard-step-completed .seovaultseo-wizard-step-label {
	color: var(--seovaultseo-success, #059669);
}

.seovaultseo-wizard-step-completed::after {
	background: var(--seovaultseo-success, #059669);
}

/* Body */
.seovaultseo-wizard-body {
	padding: 32px;
	background: var(--seovaultseo-card-bg, #FFFFFF);
}

.seovaultseo-wizard-step-content {
	animation: seovaultseo-wizard-fade-in 0.25s ease-out;
}

.seovaultseo-wizard-step-content h2 {
	margin: 0 0 12px;
	font-size: 22px;
	font-weight: 600;
	color: #1d2327;
}

.seovaultseo-wizard-step-content p {
	margin: 0 0 24px;
	font-size: 14px;
	color: var(--seovaultseo-muted, #6B7280);
	line-height: 1.55;
}

.seovaultseo-wizard-step-content p:last-child {
	margin-bottom: 0;
}

/* Option Cards */
.seovaultseo-wizard-option-cards {
	display: grid;
	grid-template-columns: repeat(2, 1fr);
	gap: 20px;
	margin: 24px 0;
}

.seovaultseo-wizard-option-card {
	position: relative;
	background: var(--seovaultseo-card-bg, #FFFFFF);
	border: 2px solid var(--seovaultseo-border, #E5E7EB);
	border-radius: var(--seovaultseo-radius, 8px);
	padding: 24px;
	cursor: pointer;
	transition: all 0.2s ease;
}

.seovaultseo-wizard-option-card:hover {
	border-color: var(--seovaultseo-primary, #0D9488);
}

.seovaultseo-wizard-option-card input[type="radio"] {
	position: absolute;
	opacity: 0;
	width: 0;
	height: 0;
}

.seovaultseo-wizard-option-card:has(input[type="radio"]:checked),
.seovaultseo-wizard-option-card.seovaultseo-wizard-option-card-selected {
	border-color: var(--seovaultseo-primary, #0D9488);
	background: rgba(13, 148, 136, 0.04);
}

.seovaultseo-wizard-option-card h3 {
	margin: 0 0 8px;
	font-size: 16px;
	font-weight: 600;
	color: #1d2327;
}

.seovaultseo-wizard-option-card p {
	margin: 0;
	font-size: 13px;
	color: var(--seovaultseo-muted, #6B7280);
	line-height: 1.5;
}

/* Form Fields */
.seovaultseo-wizard-field {
	margin-bottom: 20px;
}

.seovaultseo-wizard-field label {
	display: block;
	margin-bottom: 6px;
	font-weight: 500;
	font-size: 13px;
	color: #1d2327;
}

.seovaultseo-wizard-field input[type="text"],
.seovaultseo-wizard-field input[type="url"],
.seovaultseo-wizard-field input[type="email"],
.seovaultseo-wizard-field input[type="number"],
.seovaultseo-wizard-field select,
.seovaultseo-wizard-field textarea {
	width: 100%;
	max-width: 100%;
}

.seovaultseo-wizard-field textarea {
	min-height: 80px;
	resize: vertical;
}

.seovaultseo-wizard-field input[type="text"]:focus,
.seovaultseo-wizard-field input[type="url"]:focus,
.seovaultseo-wizard-field input[type="email"]:focus,
.seovaultseo-wizard-field input[type="number"]:focus,
.seovaultseo-wizard-field select:focus,
.seovaultseo-wizard-field textarea:focus {
	border-color: var(--seovaultseo-primary, #0D9488);
	box-shadow: 0 0 0 1px var(--seovaultseo-primary, #0D9488);
	outline: none;
}

.seovaultseo-wizard-field input[type="radio"]:focus,
.seovaultseo-wizard-field input[type="checkbox"]:focus {
	box-shadow: 0 0 0 2px var(--seovaultseo-primary, #0D9488);
	outline: none;
}

.seovaultseo-wizard-error {
	color: var(--seovaultseo-error, #DC2626);
	font-size: 12px;
	margin-top: 4px;
	min-height: 18px;
}

.seovaultseo-wizard-input-error {
	border-color: var(--seovaultseo-error, #DC2626) !important;
}

/* Footer */
.seovaultseo-wizard-footer {
	display: flex;
	justify-content: space-between;
	align-items: center;
	gap: 16px;
	padding: 20px 32px;
	background: #fafafa;
	border-top: 1px solid var(--seovaultseo-border, #E5E7EB);
}

.seovaultseo-wizard-footer .button {
	min-width: 100px;
}

.seovaultseo-wizard .button:focus,
.seovaultseo-wizard .button-secondary:focus {
	border-color: var(--seovaultseo-primary, #0D9488);
	box-shadow: 0 0 0 1px var(--seovaultseo-primary, #0D9488);
	outline: none;
}

.seovaultseo-wizard .button-primary {
	background: var(--seovaultseo-primary, #0D9488);
	border-color: var(--seovaultseo-primary, #0D9488);
	color: #fff;
}

.seovaultseo-wizard .button-primary:hover {
	background: var(--seovaultseo-primary-hover, #0B7C72);
	border-color: var(--seovaultseo-primary-hover, #0B7C72);
}

.seovaultseo-wizard .button-primary:focus {
	box-shadow: 0 0 0 1px #fff, 0 0 0 3px var(--seovaultseo-primary, #0D9488);
}

.seovaultseo-wizard-nav-form,
.seovaultseo-wizard-footer-actions {
	display: flex;
	gap: 10px;
}

.seovaultseo-wizard-skip-form .button-link {
	color: var(--seovaultseo-muted, #6B7280);
}

.seovaultseo-wizard-skip-link {
	color: var(--seovaultseo-muted, #6B7280);
	text-decoration: none;
}

.seovaultseo-wizard .seovaultseo-wizard-skip-link,
.seovaultseo-wizard .seovaultseo-wizard-skip-step-link {
	padding-right: 12px;
	padding-left: 12px;
}

.seovaultseo-wizard-skip-link:hover {
	color: var(--seovaultseo-error, #DC2626);
}

.seovaultseo-wizard-welcome {
	text-align: center;
}

.seovaultseo-wizard-welcome .seovaultseo-wizard-logo {
	margin: 0 auto 20px;
}

/* Notice / Inline hint */
.seovaultseo-wizard-hint {
	padding: 12px 16px;
	margin-bottom: 24px;
	background: #e6f4ea;
	border-left: 4px solid var(--seovaultseo-success, #059669);
	border-radius: 4px;
	font-size: 13px;
	color: #1d2327;
}

/* Field Group */
.seovaultseo-wizard-field-group {
	display: flex;
	flex-direction: column;
	gap: 0;
}

/* Radio Group (inline radios) */
.seovaultseo-wizard-radio-group {
	display: flex;
	gap: 20px;
	align-items: center;
}

.seovaultseo-wizard-radio-label {
	display: inline-flex;
	align-items: center;
	gap: 6px;
	font-size: 14px;
	font-weight: 400;
	color: #1d2327;
	cursor: pointer;
}

.seovaultseo-wizard-radio-label input[type="radio"] {
	margin: 0;
}

/* Media Upload */
.seovaultseo-wizard-media-upload {
	display: flex;
	align-items: center;
	gap: 12px;
	flex-wrap: wrap;
}

.seovaultseo-wizard-media-preview {
	width: 64px;
	height: 64px;
	border: 1px solid var(--seovaultseo-border, #E5E7EB);
	border-radius: var(--seovaultseo-radius, 8px);
	overflow: hidden;
	display: flex;
	align-items: center;
	justify-content: center;
	background: var(--seovaultseo-bg, #F8F9FA);
	flex-shrink: 0;
}

.seovaultseo-wizard-media-preview img {
	max-width: 100%;
	max-height: 100%;
	object-fit: contain;
}

.seovaultseo-wizard-media-preview:empty {
	display: none;
}

.seovaultseo-wizard-media-button {
	flex-shrink: 0;
}

.seovaultseo-wizard-media-button:focus {
	border-color: var(--seovaultseo-primary, #0D9488);
	box-shadow: 0 0 0 1px var(--seovaultseo-primary, #0D9488);
	outline: none;
}

.seovaultseo-wizard-media-remove {
	color: var(--seovaultseo-muted, #6B7280);
	text-decoration: none;
	font-size: 12px;
}

.seovaultseo-wizard-media-remove:hover {
	color: var(--seovaultseo-error, #DC2626);
}

/* Skip step link (Set up later) */
.seovaultseo-wizard-skip-step-link {
	color: var(--seovaultseo-muted, #6B7280);
	text-decoration: none;
	font-size: 13px;
}

.seovaultseo-wizard-skip-step-link:hover {
	color: var(--seovaultseo-primary, #0D9488);
}

/* Character Counter */
.seovaultseo-wizard-char-counter {
	font-size: 12px;
	color: var(--seovaultseo-muted, #6B7280);
	text-align: right;
	margin-top: 4px;
}

.seovaultseo-wizard-char-counter .seovaultseo-wizard-char-count {
	font-weight: 600;
}

/* Checkbox Group */
.seovaultseo-wizard-checkbox-group {
	display: flex;
	flex-direction: column;
	gap: 12px;
}

.seovaultseo-wizard-checkbox-label {
	display: inline-flex;
	align-items: center;
	gap: 8px;
	font-size: 14px;
	font-weight: 400;
	color: #1d2327;
	cursor: pointer;
}

.seovaultseo-wizard-checkbox-label input[type="checkbox"] {
	margin: 0;
}

/* Field description text */
.seovaultseo-wizard-field .description {
	margin-top: 4px;
	font-size: 12px;
	color: var(--seovaultseo-muted, #6B7280);
}

/* Connect Step — Key Row */
.seovaultseo-wizard-key-row {
	display: flex;
	align-items: center;
	gap: 8px;
}

.seovaultseo-wizard-key-input {
	flex: 1;
	font-family: monospace;
	font-size: 13px;
	background: var(--seovaultseo-bg, #F8F9FA);
}

.seovaultseo-wizard-key-input:focus {
	border-color: var(--seovaultseo-primary, #0D9488);
	box-shadow: 0 0 0 1px var(--seovaultseo-primary, #0D9488);
}

.seovaultseo-copy-key .dashicons {
	font-size: 16px;
	width: 16px;
	height: 16px;
	vertical-align: middle;
	margin-right: 2px;
}

/* Connect Step — REST URL */
.seovaultseo-wizard-rest-url {
	display: block;
	font-size: 12px;
	color: var(--seovaultseo-muted, #6B7280);
	background: var(--seovaultseo-bg, #F8F9FA);
	padding: 8px 12px;
	border-radius: 4px;
	word-break: break-all;
}

/* Connect Step — Feature Teaser */
.seovaultseo-wizard-feature-teaser {
	margin-top: 8px;
	padding: 20px;
	background: var(--seovaultseo-bg, #F8F9FA);
	border: 1px solid var(--seovaultseo-border, #E5E7EB);
	border-radius: var(--seovaultseo-radius, 8px);
}

.seovaultseo-wizard-feature-teaser h3 {
	margin: 0 0 12px;
	font-size: 14px;
	font-weight: 600;
	color: #1d2327;
}

.seovaultseo-wizard-feature-teaser ul {
	margin: 0;
	padding: 0;
	list-style: none;
}

.seovaultseo-wizard-feature-teaser li {
	display: flex;
	align-items: center;
	gap: 10px;
	padding: 6px 0;
	font-size: 13px;
	color: #1d2327;
}

.seovaultseo-wizard-feature-teaser li .dashicons {
	font-size: 18px;
	width: 18px;
	height: 18px;
	color: var(--seovaultseo-primary, #0D9488);
}

/* Connect Step — Actions */
.seovaultseo-wizard-connect-actions {
	display: flex;
	align-items: center;
	gap: 16px;
	margin-top: 24px;
}

.seovaultseo-wizard-connect-now {
	text-decoration: none;
}

/* Finish Step */
.seovaultseo-wizard-finish {
	text-align: center;
}

.seovaultseo-wizard-summary {
	max-width: 400px;
	margin: 24px auto;
	border: 1px solid var(--seovaultseo-border, #E5E7EB);
	border-radius: var(--seovaultseo-radius, 8px);
	overflow: hidden;
}

.seovaultseo-wizard-summary-row {
	display: flex;
	justify-content: space-between;
	align-items: center;
	padding: 12px 20px;
	border-bottom: 1px solid var(--seovaultseo-border, #E5E7EB);
}

.seovaultseo-wizard-summary-row:last-child {
	border-bottom: none;
}

.seovaultseo-wizard-summary-label {
	font-size: 13px;
	font-weight: 500;
	color: var(--seovaultseo-muted, #6B7280);
}

.seovaultseo-wizard-summary-value {
	font-size: 13px;
	font-weight: 600;
	color: #1d2327;
}

.seovaultseo-wizard-finish-connect-link {
	margin-top: 16px;
}

/* Animations */
@keyframes seovaultseo-wizard-fade-in {
	from {
		opacity: 0;
		transform: translateY(6px);
	}
	to {
		opacity: 1;
		transform: translateY(0);
	}
}

/* Responsive */
@media screen and (max-width: 782px) {
	.seovaultseo-wizard {
		margin: 16px auto;
		padding: 0 10px;
	}

	.seovaultseo-wizard-body {
		padding: 24px;
	}

	.seovaultseo-wizard-option-cards {
		grid-template-columns: 1fr;
	}

	.seovaultseo-wizard-footer {
		flex-direction: column;
		align-items: stretch;
		gap: 12px;
	}

	.seovaultseo-wizard-nav-form {
		justify-content: space-between;
	}

	.seovaultseo-wizard-logo {
		width: 64px;
		height: 64px;
	}
}

@media screen and (max-width: 480px) {
	.seovaultseo-wizard-step-label {
		display: none;
	}

	.seovaultseo-wizard-radio-group {
		flex-direction: column;
		align-items: flex-start;
		gap: 10px;
	}

	.seovaultseo-wizard-media-upload {
		flex-direction: column;
		align-items: flex-start;
	}

	.seovaultseo-wizard-connect-actions {
		flex-direction: column;
		align-items: stretch;
		gap: 12px;
	}

	.seovaultseo-wizard-key-row {
		flex-direction: column;
		align-items: stretch;
		gap: 8px;
	}

	.seovaultseo-wizard-summary {
		max-width: 100%;
	}
}
