/**
 * Onboarding: welcome modal and tour styles.
 *
 * @package WPLC
 */

/* Welcome modal overlay */
.wplc-welcome-overlay {
	position: fixed;
	top: 0;
	left: 0;
	right: 0;
	bottom: 0;
	background: rgba(0, 0, 0, 0.5);
	display: flex;
	align-items: center;
	justify-content: center;
	z-index: 100000;
	animation: wplcFadeIn 0.4s ease;
}

@keyframes wplcFadeIn {
	from { opacity: 0; }
	to { opacity: 1; }
}

/* Welcome modal box */
.wplc-welcome-modal {
	background: #fff;
	border-radius: 16px;
	max-width: 520px;
	width: 90%;
	box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.25);
	overflow: hidden;
	animation: wplcModalIn 0.5s cubic-bezier(0.34, 1.56, 0.64, 1);
}

@keyframes wplcModalIn {
	from {
		opacity: 0;
		transform: scale(0.9) translateY(20px);
	}
	to {
		opacity: 1;
		transform: scale(1) translateY(0);
	}
}

/* Welcome header with gradient */
.wplc-welcome-header {
	background: linear-gradient(135deg, #111827 0%, #374151 100%);
	padding: 40px 32px;
	text-align: center;
	position: relative;
}

.wplc-welcome-header::after {
	content: '';
	position: absolute;
	bottom: 0;
	left: 0;
	right: 0;
	height: 60px;
	background: linear-gradient(to top, rgba(255,255,255,0.05), transparent);
	pointer-events: none;
}

.wplc-welcome-icon {
	width: 80px;
	height: 80px;
	margin: 0 auto 20px;
	background: rgba(255, 255, 255, 0.2);
	border-radius: 50%;
	display: flex;
	align-items: center;
	justify-content: center;
	font-size: 40px;
	animation: wplcIconPop 0.6s ease 0.2s both;
}

@keyframes wplcIconPop {
	from {
		opacity: 0;
		transform: scale(0.5);
	}
	to {
		opacity: 1;
		transform: scale(1);
	}
}

.wplc-welcome-title {
	color: #fff;
	font-size: 26px;
	font-weight: 700;
	margin: 0 0 8px;
	letter-spacing: -0.02em;
	animation: wplcSlideUp 0.5s ease 0.15s both;
}

.wplc-welcome-subtitle {
	color: rgba(255, 255, 255, 0.9);
	font-size: 16px;
	margin: 0;
	animation: wplcSlideUp 0.5s ease 0.25s both;
}

@keyframes wplcSlideUp {
	from {
		opacity: 0;
		transform: translateY(12px);
	}
	to {
		opacity: 1;
		transform: translateY(0);
	}
}

/* Welcome body */
.wplc-welcome-body {
	padding: 32px;
}

.wplc-welcome-body p {
	color: #595959;
	font-size: 15px;
	line-height: 1.6;
	margin: 0 0 24px;
}

.wplc-welcome-actions {
	display: flex;
	flex-direction: column;
	gap: 12px;
}

.wplc-welcome-actions .wplc-btn-tour {
	background: #111827;
	border: none;
	color: #fff;
	padding: 14px 24px;
	font-size: 16px;
	font-weight: 600;
	border-radius: 8px;
	cursor: pointer;
	transition: all 0.2s ease;
	box-shadow: 0 4px 6px rgba(17, 24, 39, 0.1);
}

.wplc-welcome-actions .wplc-btn-tour:hover {
	transform: translateY(-2px);
	box-shadow: 0 8px 15px rgba(17, 24, 39, 0.2);
	background: #374151;
	color: #fff;
}

.wplc-welcome-actions .wplc-btn-skip {
	background: #f3f4f6;
	border: 1px solid #e5e7eb;
	color: #4b5563;
	padding: 12px 24px;
	font-size: 14px;
	font-weight: 500;
	border-radius: 8px;
	cursor: pointer;
	transition: all 0.2s ease;
}

.wplc-welcome-actions .wplc-btn-skip:hover {
	background: #e5e7eb;
	color: #111827;
}

/* Tour help button (floating) */
.wplc-tour-help-btn {
	position: fixed;
	bottom: 24px;
	right: 24px;
	width: 48px;
	height: 48px;
	border-radius: 50%;
	background: #111827;
	color: #fff;
	border: none;
	font-size: 20px;
	cursor: pointer;
	box-shadow: 0 4px 14px rgba(17, 24, 39, 0.25);
	z-index: 99999;
	transition: all 0.2s cubic-bezier(0.25, 0.8, 0.25, 1);
	display: flex;
	align-items: center;
	justify-content: center;
}

.wplc-tour-help-btn:hover {
	transform: scale(1.08) translateY(-2px);
	box-shadow: 0 8px 20px rgba(17, 24, 39, 0.35);
	background: #374151;
	color: #fff;
}

/* Built-in tour (no external libraries) */
.wplc-tour-overlay {
	position: fixed;
	inset: 0;
	background: rgba(0, 0, 0, 0.62);
	z-index: 99990;
}

.wplc-tour-popover {
	position: fixed;
	left: 50%;
	bottom: 24px;
	transform: translateX(-50%);
	width: min(560px, calc(100vw - 32px));
	background: #ffffff;
	border: 1px solid rgba(17, 24, 39, 0.08);
	border-radius: 14px;
	box-shadow: 0 24px 60px rgba(0, 0, 0, 0.28);
	padding: 16px 16px 14px;
	z-index: 99995;
	animation: wplcModalIn 0.35s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.wplc-tour-title {
	font-size: 16px;
	font-weight: 800;
	color: #111827;
	margin-bottom: 6px;
	letter-spacing: -0.01em;
}

.wplc-tour-body {
	color: #4b5563;
	font-size: 14px;
	line-height: 1.55;
	margin-bottom: 12px;
}

.wplc-tour-footer {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 12px;
}

.wplc-tour-progress {
	color: #6b7280;
	font-weight: 700;
}

.wplc-tour-buttons {
	display: flex;
	gap: 8px;
}

.wplc-tour-buttons .components-button.is-primary {
	background: #111827;
	border-color: #111827;
	border-radius: 10px;
	font-weight: 800;
}

.wplc-tour-buttons .components-button.is-secondary {
	border-radius: 10px;
	font-weight: 800;
	border-color: #d1d5db;
}

#wplc-checklist-app .driver-popover-prev-btn,
#wplc-checklist-app .driver-popover-next-btn {
	border-radius: 6px;
	font-weight: 600;
	padding: 6px 12px;
	text-shadow: none;
}

#wplc-checklist-app .driver-popover-next-btn {
	background: #111827;
	border: 1px solid #111827;
	color: #ffffff;
}

#wplc-checklist-app .driver-popover-next-btn:hover {
	background: #374151;
	border-color: #374151;
}

#wplc-checklist-app .driver-popover-prev-btn {
	color: #4b5563;
	border-color: #d1d5db;
}

#wplc-checklist-app .driver-popover-prev-btn:hover {
	color: #111827;
	border-color: #9ca3af;
}

#wplc-checklist-app .driver-popover-close-btn {
	color: #9ca3af;
	transition: color 0.2s;
}

#wplc-checklist-app .driver-popover-close-btn:hover {
	color: #111827;
}

#wplc-checklist-app .driver-overlay {
	background: rgba(0, 0, 0, 0.6);
}
