/**
 * WB Survey Frontend Styles
 *
 * Production-ready, theme-agnostic survey styles with mobile-first responsive design.
 *
 * @package Buddypress_Polls
 * @since 4.6.0
 */

/* ==========================================================================
   CSS Custom Properties (Theme Customization)
   ========================================================================== */

:root {
	/* Primary Colors */
	--wbsurvey-primary: #2271b1;
	--wbsurvey-primary-hover: #135e96;
	--wbsurvey-primary-light: #e8f4fc;

	/* Status Colors */
	--wbsurvey-success: #46b450;
	--wbsurvey-success-light: #d4edda;
	--wbsurvey-error: #dc3232;
	--wbsurvey-error-light: #fef2f2;
	--wbsurvey-warning: #f0b849;
	--wbsurvey-warning-light: #fff3cd;
	--wbsurvey-info: #4c9ed9;
	--wbsurvey-info-light: #cce5ff;

	/* Text Colors */
	--wbsurvey-text: #1e1e1e;
	--wbsurvey-text-light: #666;
	--wbsurvey-text-muted: #999;

	/* Border & Background */
	--wbsurvey-border: #ddd;
	--wbsurvey-border-light: #e0e0e0;
	--wbsurvey-bg: #f9f9f9;
	--wbsurvey-bg-light: #f0f0f0;
	--wbsurvey-bg-white: #fff;
	--wbsurvey-white: #fff;

	/* Layout */
	--wbsurvey-radius: 8px;
	--wbsurvey-radius-sm: 4px;
	--wbsurvey-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
	--wbsurvey-shadow-lg: 0 4px 16px rgba(0, 0, 0, 0.15);

	/* Transitions */
	--wbsurvey-transition: all 0.2s ease;
	--wbsurvey-transition-fast: all 0.15s ease;

	/* Spacing */
	--wbsurvey-spacing-xs: 8px;
	--wbsurvey-spacing-sm: 12px;
	--wbsurvey-spacing-md: 16px;
	--wbsurvey-spacing-lg: 24px;
	--wbsurvey-spacing-xl: 32px;

	/* Typography */
	--wbsurvey-font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen-Sans, Ubuntu, Cantarell, "Helvetica Neue", sans-serif;
	--wbsurvey-font-size-sm: 14px;
	--wbsurvey-font-size-base: 16px;
	--wbsurvey-font-size-lg: 18px;
	--wbsurvey-font-size-xl: 22px;
	--wbsurvey-font-size-xxl: 28px;
	--wbsurvey-line-height: 1.6;
}

/* Dark theme support - Theme Variables with Fallbacks */
html.dark-mode,
body.dark-scheme {
	--wbsurvey-text: var(--reign-site-headings-color, var(--global-title-color, #e4e4e4));
	--wbsurvey-text-light: var(--reign-site-alternate-text-color, var(--global-font-color, #b4b4b4));
	--wbsurvey-text-muted: var(--reign-site-alternate-text-color, var(--color-meta, #888888));
	--wbsurvey-border: var(--reign-site-border-color, var(--global-border-color, rgba(255, 255, 255, 0.1)));
	--wbsurvey-border-light: var(--reign-site-border-color, var(--global-border-color, rgba(255, 255, 255, 0.15)));
	--wbsurvey-bg: var(--reign-site-sections-bg-color, var(--color-theme-white-box, #2d2d2d));
	--wbsurvey-bg-light: var(--reign-site-secondary-bg-color, var(--global-body-lightcolor, #3d3d3d));
	--wbsurvey-bg-white: var(--reign-site-sections-bg-color, var(--color-theme-white-box, #1a1a1a));

	--wbsurvey-success-light: var(--reign-site-secondary-bg-color, var(--color-theme-white-box, #1e3a1e));
	--wbsurvey-error-light: var(--reign-site-secondary-bg-color, var(--color-theme-white-box, #3a1e1e));
	--wbsurvey-warning-light: var(--reign-site-secondary-bg-color, var(--color-theme-white-box, #3a3a1e));
	--wbsurvey-info-light: var(--reign-site-secondary-bg-color, var(--color-theme-white-box, #1e2a3a));
	--wbsurvey-primary-light: var(--reign-site-secondary-bg-color, var(--color-theme-white-box, #1e2a3a));
}

/* System preference fallback */
/* @media (prefers-color-scheme: dark) {
	:root {
		--wbsurvey-text: #e0e0e0;
		--wbsurvey-text-light: #aaa;
		--wbsurvey-border: #444;
		--wbsurvey-bg: #2a2a2a;
		--wbsurvey-bg-white: #1a1a1a;
		--wbsurvey-white: #1a1a1a;
	}
} */

/* ==========================================================================
   Base Container
   ========================================================================== */

.wbsurvey-container {
	max-width: 720px;
	margin: 0 auto;
	padding: var(--wbsurvey-spacing-lg);
	font-family: var(--wbsurvey-font-family);
	font-size: var(--wbsurvey-font-size-base);
	line-height: var(--wbsurvey-line-height);
	color: var(--wbsurvey-text);
}

/* ==========================================================================
   Header Section
   ========================================================================== */

.wbsurvey-header {
	text-align: center;
	margin-bottom: var(--wbsurvey-spacing-xl);
	animation: wbsurvey-fadeIn 0.4s ease;
}

.wbsurvey-title {
	font-size: var(--wbsurvey-font-size-xxl);
	font-weight: 600;
	color: var(--wbsurvey-text);
	margin: 0 0 var(--wbsurvey-spacing-md) 0;
	line-height: 1.3;
}

.wbsurvey-description {
	color: var(--wbsurvey-text-light);
	font-size: var(--wbsurvey-font-size-base);
	line-height: var(--wbsurvey-line-height);
	margin: 0;
}

.wbsurvey-description p:last-child {
	margin-bottom: 0;
}

/* ==========================================================================
   Start Screen
   ========================================================================== */

.wbsurvey-start-screen {
	text-align: center;
	padding: var(--wbsurvey-spacing-xl) var(--wbsurvey-spacing-lg);
	background: var(--wbsurvey-bg-white);
	border-radius: var(--wbsurvey-radius);
	box-shadow: var(--wbsurvey-shadow);
	animation: wbsurvey-fadeIn 0.4s ease;
}

.wbsurvey-meta {
	margin-bottom: var(--wbsurvey-spacing-lg);
}

.wbsurvey-question-count {
	display: inline-block;
	padding: var(--wbsurvey-spacing-xs) var(--wbsurvey-spacing-md);
	background: var(--wbsurvey-bg);
	border-radius: 20px;
	color: var(--wbsurvey-text-light);
	font-size: var(--wbsurvey-font-size-sm);
	font-weight: 500;
}

/* ==========================================================================
   Buttons
   ========================================================================== */

.wbsurvey-btn {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	gap: var(--wbsurvey-spacing-xs);
	padding: var(--wbsurvey-spacing-sm) var(--wbsurvey-spacing-lg);
	font-size: var(--wbsurvey-font-size-base);
	font-weight: 500;
	border: none;
	border-radius: var(--wbsurvey-radius);
	cursor: pointer;
	transition: var(--wbsurvey-transition);
	text-decoration: none;
	line-height: 1.4;
	min-height: 44px; /* Touch target size for mobile */
}

.wbsurvey-btn:focus {
	outline: 2px solid var(--wbsurvey-primary);
	outline-offset: 2px;
}

.wbsurvey-btn-primary {
	background: var(--wbsurvey-primary);
	color: var(--wbsurvey-white);
}

.wbsurvey-btn-primary:hover,
.wbsurvey-btn-primary:focus {
	background: var(--wbsurvey-primary-hover);
	color: var(--wbsurvey-white);
	transform: translateY(-1px);
	box-shadow: 0 4px 12px rgba(34, 113, 177, 0.3);
}

.wbsurvey-btn-secondary {
	background: var(--wbsurvey-bg);
	color: var(--wbsurvey-text);
	border: 1px solid var(--wbsurvey-border);
}

.wbsurvey-btn-secondary:hover,
.wbsurvey-btn-secondary:focus {
	background: var(--wbsurvey-bg-light);
	border-color: var(--wbsurvey-text-light);
}

.wbsurvey-btn:disabled,
.wbsurvey-btn-loading {
	opacity: 0.6;
	cursor: not-allowed;
	pointer-events: none;
}

.wbsurvey-btn-loading {
	position: relative;
}

.wbsurvey-btn-loading::after {
	content: "";
	width: 16px;
	height: 16px;
	border: 2px solid transparent;
	border-top-color: currentColor;
	border-radius: 50%;
	animation: wbsurvey-spin 0.8s linear infinite;
}

/* ==========================================================================
   Survey Form
   ========================================================================== */

.wbsurvey-form {
	background: var(--wbsurvey-bg-white);
	border-radius: var(--wbsurvey-radius);
	box-shadow: var(--wbsurvey-shadow);
	padding: var(--wbsurvey-spacing-xl);
	animation: wbsurvey-fadeIn 0.4s ease;
}

/* ==========================================================================
   Progress Bar
   ========================================================================== */

.wbsurvey-progress {
	margin-bottom: var(--wbsurvey-spacing-xl);
}

.wbsurvey-progress-bar {
	height: 8px;
	background: var(--wbsurvey-bg);
	border-radius: var(--wbsurvey-radius-sm);
	overflow: hidden;
	margin-bottom: var(--wbsurvey-spacing-sm);
	position: relative;
}

.wbsurvey-progress-fill {
	height: 100%;
	background: linear-gradient(90deg, var(--wbsurvey-primary), var(--wbsurvey-info));
	border-radius: var(--wbsurvey-radius-sm);
	transition: width 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

.wbsurvey-progress-text {
	display: flex;
	justify-content: space-between;
	align-items: center;
	font-size: var(--wbsurvey-font-size-sm);
	color: var(--wbsurvey-text-light);
	font-weight: 500;
}

/* ==========================================================================
   Question Container
   ========================================================================== */

.wbsurvey-question-container {
	min-height: 200px;
	position: relative;
}

.wbsurvey-question-container.wbsurvey-loading-state {
	opacity: 0.5;
	pointer-events: none;
}

/* ==========================================================================
   Question
   ========================================================================== */

.wbsurvey-question {
	animation: wbsurvey-slideIn 0.3s ease;
}

.wbsurvey-question-header {
	margin-bottom: var(--wbsurvey-spacing-sm);
}

.wbsurvey-question-number {
	display: inline-block;
	padding: 4px var(--wbsurvey-spacing-sm);
	background: var(--wbsurvey-primary);
	color: var(--wbsurvey-white);
	border-radius: var(--wbsurvey-radius-sm);
	font-size: 12px;
	font-weight: 600;
	text-transform: uppercase;
	letter-spacing: 0.5px;
}

.wbsurvey-question-title {
	font-size: var(--wbsurvey-font-size-xl);
	font-weight: 600;
	color: var(--wbsurvey-text);
	margin: var(--wbsurvey-spacing-md) 0;
	line-height: 1.4;
}

.wbsurvey-question-description {
	color: var(--wbsurvey-text-light);
	margin-bottom: var(--wbsurvey-spacing-lg);
	line-height: var(--wbsurvey-line-height);
}

.wbsurvey-question-required {
	color: var(--wbsurvey-error);
	margin-left: 4px;
}

/* ==========================================================================
   Answers
   ========================================================================== */

.wbsurvey-answers {
	display: flex;
	flex-direction: column;
	gap: var(--wbsurvey-spacing-sm);
}

.wbsurvey-answer {
	display: flex;
	align-items: center;
	gap: var(--wbsurvey-spacing-md);
	padding: var(--wbsurvey-spacing-md) var(--wbsurvey-spacing-lg);
	background: var(--wbsurvey-bg);
	border: 2px solid transparent;
	border-radius: var(--wbsurvey-radius);
	cursor: pointer;
	transition: var(--wbsurvey-transition);
	position: relative;
	min-height: 56px; /* Touch target size */
}

.wbsurvey-answer:hover {
	background: var(--wbsurvey-bg-light);
	border-color: var(--wbsurvey-border);
	transform: translateX(4px);
}

.wbsurvey-answer:focus-within {
	outline: 2px solid var(--wbsurvey-primary);
	outline-offset: 2px;
}

.wbsurvey-answer-selected {
	background: var(--wbsurvey-primary-light);
	border-color: var(--wbsurvey-primary);
}

.wbsurvey-answer-selected:hover {
	background: var(--wbsurvey-primary-light);
	border-color: var(--wbsurvey-primary);
}

.wbsurvey-answer-input {
	position: absolute;
	opacity: 0;
	width: 0;
	height: 0;
	margin: 0;
	padding: 0;
}

.wbsurvey-answer-text {
	flex: 1;
	font-size: var(--wbsurvey-font-size-base);
	color: var(--wbsurvey-text);
	line-height: 1.5;
}

.wbsurvey-answer-check {
	width: 24px;
	height: 24px;
	border: 2px solid var(--wbsurvey-border);
	border-radius: 50%;
	display: flex;
	align-items: center;
	justify-content: center;
	transition: var(--wbsurvey-transition);
	flex-shrink: 0;
	background: var(--wbsurvey-bg-white);
}

.wbsurvey-answer-selected .wbsurvey-answer-check {
	background: var(--wbsurvey-primary);
	border-color: var(--wbsurvey-primary);
}

.wbsurvey-answer-selected .wbsurvey-answer-check::after {
	content: "";
	width: 8px;
	height: 8px;
	background: var(--wbsurvey-bg-white);
	border-radius: 50%;
}

/* Checkbox style for multi-select */
.wbsurvey-answer input[type="checkbox"] ~ .wbsurvey-answer-check {
	border-radius: var(--wbsurvey-radius-sm);
}

.wbsurvey-answer input[type="checkbox"]:checked ~ .wbsurvey-answer-check::after {
	content: "\2713";
	font-size: 14px;
	font-weight: bold;
	color: var(--wbsurvey-white);
	background: none;
	width: auto;
	height: auto;
}

/* Answer with image */
.wbsurvey-answer-with-image {
	flex-direction: column;
	text-align: center;
	padding: var(--wbsurvey-spacing-lg);
}

.wbsurvey-answer-with-image .wbsurvey-answer-image {
	width: 100%;
	margin-bottom: var(--wbsurvey-spacing-sm);
}

.wbsurvey-answer-with-image .wbsurvey-answer-image img {
	max-width: 100%;
	height: auto;
	border-radius: var(--wbsurvey-radius-sm);
	display: block;
}

.wbsurvey-answer-with-image .wbsurvey-answer-check {
	position: absolute;
	top: var(--wbsurvey-spacing-sm);
	right: var(--wbsurvey-spacing-sm);
	box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
}

/* Text input answers */
.wbsurvey-text-answer {
	width: 100%;
	padding: var(--wbsurvey-spacing-sm) var(--wbsurvey-spacing-md);
	border: 2px solid var(--wbsurvey-border);
	border-radius: var(--wbsurvey-radius);
	font-size: var(--wbsurvey-font-size-base);
	font-family: inherit;
	color: var(--wbsurvey-text);
	background: var(--wbsurvey-bg-white);
	transition: var(--wbsurvey-transition);
	min-height: 44px;
}

.wbsurvey-text-answer:focus {
	outline: none;
	border-color: var(--wbsurvey-primary);
	box-shadow: 0 0 0 3px rgba(34, 113, 177, 0.1);
}

.wbsurvey-text-answer::placeholder {
	color: var(--wbsurvey-text-muted);
}

textarea.wbsurvey-text-answer {
	resize: vertical;
	min-height: 100px;
	line-height: var(--wbsurvey-line-height);
}

/* ==========================================================================
   Navigation
   ========================================================================== */

.wbsurvey-navigation {
	display: flex;
	justify-content: space-between;
	align-items: center;
	margin-top: var(--wbsurvey-spacing-xl);
	padding-top: var(--wbsurvey-spacing-lg);
	border-top: 1px solid var(--wbsurvey-border);
	gap: var(--wbsurvey-spacing-sm);
}

.wbsurvey-navigation .wbsurvey-btn {
	flex: 1;
	max-width: 200px;
}

.wbsurvey-navigation .wbsurvey-btn .dashicons {
	font-size: 18px;
	width: 18px;
	height: 18px;
	line-height: 18px;
}

/* ==========================================================================
   Error & Success Messages
   ========================================================================== */

.wbsurvey-error-message {
	background: var(--wbsurvey-error-light);
	color: var(--wbsurvey-error);
	padding: var(--wbsurvey-spacing-sm) var(--wbsurvey-spacing-md);
	border-radius: var(--wbsurvey-radius);
	border-left: 4px solid var(--wbsurvey-error);
	margin-top: var(--wbsurvey-spacing-md);
	font-size: var(--wbsurvey-font-size-sm);
	animation: wbsurvey-shake 0.4s ease;
}

.wbsurvey-success-message {
	background: var(--wbsurvey-success-light);
	color: var(--wbsurvey-success);
	padding: var(--wbsurvey-spacing-sm) var(--wbsurvey-spacing-md);
	border-radius: var(--wbsurvey-radius);
	border-left: 4px solid var(--wbsurvey-success);
	margin-top: var(--wbsurvey-spacing-md);
	font-size: var(--wbsurvey-font-size-sm);
}

/* ==========================================================================
   Loading States
   ========================================================================== */

.wbsurvey-loading {
	display: flex;
	align-items: center;
	justify-content: center;
	gap: var(--wbsurvey-spacing-sm);
	padding: var(--wbsurvey-spacing-xl);
	color: var(--wbsurvey-text-light);
}

.wbsurvey-spinner {
	width: 24px;
	height: 24px;
	border: 3px solid var(--wbsurvey-border);
	border-top-color: var(--wbsurvey-primary);
	border-radius: 50%;
	animation: wbsurvey-spin 0.8s linear infinite;
}

/* ==========================================================================
   Thank You Screen
   ========================================================================== */

.wbsurvey-thankyou-screen {
	text-align: center;
	padding: var(--wbsurvey-spacing-xl) var(--wbsurvey-spacing-lg);
	background: var(--wbsurvey-bg-white);
	border-radius: var(--wbsurvey-radius);
	box-shadow: var(--wbsurvey-shadow);
	animation: wbsurvey-fadeIn 0.5s ease;
	min-height: 200px;
}

.wbsurvey-thankyou {
	animation: wbsurvey-zoomIn 0.5s ease;
}

.wbsurvey-thankyou-icon {
	margin-bottom: var(--wbsurvey-spacing-lg);
}

.wbsurvey-thankyou-icon .dashicons {
	font-size: 64px;
	width: 64px;
	height: 64px;
	color: var(--wbsurvey-success);
	animation: wbsurvey-bounce 0.6s ease;
}

.wbsurvey-thankyou-title {
	font-size: var(--wbsurvey-font-size-xxl);
	font-weight: 600;
	color: var(--wbsurvey-text);
	margin: 0 0 var(--wbsurvey-spacing-md) 0;
}

.wbsurvey-thankyou-message {
	color: var(--wbsurvey-text-light);
	font-size: var(--wbsurvey-font-size-base);
	line-height: var(--wbsurvey-line-height);
	max-width: 500px;
	margin: 0 auto;
}

.wbsurvey-thankyou-message p:last-child {
	margin-bottom: 0;
}

/* ==========================================================================
   Results Summary
   ========================================================================== */

.wbsurvey-results-summary {
	margin-top: var(--wbsurvey-spacing-xl);
	padding-top: var(--wbsurvey-spacing-xl);
	border-top: 1px solid var(--wbsurvey-border);
	text-align: left;
	max-width: 500px;
	margin-left: auto;
	margin-right: auto;
}

.wbsurvey-results-summary h3 {
	font-size: var(--wbsurvey-font-size-lg);
	font-weight: 600;
	color: var(--wbsurvey-text);
	margin: 0 0 var(--wbsurvey-spacing-md) 0;
	text-align: center;
}

.wbsurvey-results-list {
	display: flex;
	flex-direction: column;
	gap: var(--wbsurvey-spacing-md);
}

.wbsurvey-result-item {
	background: var(--wbsurvey-bg);
	padding: var(--wbsurvey-spacing-md);
	border-radius: var(--wbsurvey-radius);
	border-left: 3px solid var(--wbsurvey-primary);
}

.wbsurvey-result-question {
	font-weight: 500;
	color: var(--wbsurvey-text);
	margin-bottom: var(--wbsurvey-spacing-xs);
	font-size: var(--wbsurvey-font-size-sm);
}

.wbsurvey-result-answer {
	color: var(--wbsurvey-primary);
	font-size: var(--wbsurvey-font-size-base);
	font-weight: 500;
}

/* ==========================================================================
   Redirect Notice
   ========================================================================== */

.wbsurvey-redirect-notice {
	margin-top: var(--wbsurvey-spacing-lg);
	padding-top: var(--wbsurvey-spacing-lg);
	border-top: 1px solid var(--wbsurvey-border);
	color: var(--wbsurvey-text-light);
	font-size: var(--wbsurvey-font-size-sm);
}

.wbsurvey-redirect-notice p {
	margin: 0 0 var(--wbsurvey-spacing-sm) 0;
}

.wbsurvey-redirect-link {
	color: var(--wbsurvey-primary);
	text-decoration: underline;
	transition: var(--wbsurvey-transition);
}

.wbsurvey-redirect-link:hover,
.wbsurvey-redirect-link:focus {
	color: var(--wbsurvey-primary-hover);
}

/* ==========================================================================
   Already Completed
   ========================================================================== */

.wbsurvey-already-completed {
	text-align: center;
	padding: var(--wbsurvey-spacing-xl) var(--wbsurvey-spacing-lg);
	background: var(--wbsurvey-bg-white);
	border-radius: var(--wbsurvey-radius);
	box-shadow: var(--wbsurvey-shadow);
	animation: wbsurvey-fadeIn 0.4s ease;
	min-height: 200px;
	display: flex;
	flex-direction: column;
	align-items: center;
	justify-content: center;
}

.wbsurvey-already-completed .wbsurvey-completed-icon {
	margin-bottom: var(--wbsurvey-spacing-lg);
}

.wbsurvey-already-completed .wbsurvey-completed-icon .dashicons {
	font-size: 64px;
	width: 64px;
	height: 64px;
	color: var(--wbsurvey-info);
}

.wbsurvey-already-completed h3 {
	font-size: var(--wbsurvey-font-size-xl);
	margin: 0 0 var(--wbsurvey-spacing-sm) 0;
	color: var(--wbsurvey-text);
}

.wbsurvey-already-completed p {
	color: var(--wbsurvey-text-light);
	margin: 0;
	line-height: var(--wbsurvey-line-height);
}

/* ==========================================================================
   Access Denied / Login Prompt
   ========================================================================== */

.wbsurvey-access-denied {
	text-align: center;
	padding: var(--wbsurvey-spacing-xl) var(--wbsurvey-spacing-lg);
	background: var(--wbsurvey-bg-white);
	border-radius: var(--wbsurvey-radius);
	box-shadow: var(--wbsurvey-shadow);
	animation: wbsurvey-fadeIn 0.4s ease;
}

.wbsurvey-login-prompt p,
.wbsurvey-password-form p {
	margin-bottom: var(--wbsurvey-spacing-lg);
	color: var(--wbsurvey-text-light);
	line-height: var(--wbsurvey-line-height);
}

.wbsurvey-password-form {
	max-width: 400px;
	margin: 0 auto;
}

.wbsurvey-password-form label {
	display: block;
	margin-bottom: var(--wbsurvey-spacing-xs);
	font-weight: 500;
	text-align: left;
}

.wbsurvey-password-form input[type="password"] {
	width: 100%;
	padding: var(--wbsurvey-spacing-sm) var(--wbsurvey-spacing-md);
	border: 2px solid var(--wbsurvey-border);
	border-radius: var(--wbsurvey-radius);
	font-size: var(--wbsurvey-font-size-base);
	transition: var(--wbsurvey-transition);
	min-height: 44px;
}

.wbsurvey-password-form input[type="password"]:focus {
	outline: none;
	border-color: var(--wbsurvey-primary);
	box-shadow: 0 0 0 3px rgba(34, 113, 177, 0.1);
}

/* ==========================================================================
   Email Capture Screen (Lead Gate)
   ========================================================================== */

.wbsurvey-email-screen {
	text-align: center;
	padding: var(--wbsurvey-spacing-xl) var(--wbsurvey-spacing-lg);
	background: var(--wbsurvey-bg-white);
	border-radius: var(--wbsurvey-radius);
	box-shadow: var(--wbsurvey-shadow);
	animation: wbsurvey-fadeIn 0.4s ease;
}

.wbsurvey-email-form {
	max-width: 400px;
	margin: 0 auto;
	animation: wbsurvey-fadeIn 0.3s ease;
}

.wbsurvey-email-title {
	font-size: var(--wbsurvey-font-size-xl);
	font-weight: 600;
	color: var(--wbsurvey-text);
	margin: 0 0 var(--wbsurvey-spacing-sm) 0;
}

.wbsurvey-email-subtitle {
	color: var(--wbsurvey-text-light);
	font-size: var(--wbsurvey-font-size-base);
	margin: 0 0 var(--wbsurvey-spacing-lg) 0;
	line-height: 1.5;
}

.wbsurvey-email-field {
	margin-bottom: var(--wbsurvey-spacing-lg);
	text-align: left;
}

.wbsurvey-email-input {
	width: 100%;
	padding: var(--wbsurvey-spacing-sm) var(--wbsurvey-spacing-md);
	font-size: var(--wbsurvey-font-size-base);
	border: 2px solid var(--wbsurvey-border);
	border-radius: var(--wbsurvey-radius);
	background: var(--wbsurvey-bg-white);
	color: var(--wbsurvey-text);
	transition: var(--wbsurvey-transition);
	box-sizing: border-box;
	min-height: 44px;
}

.wbsurvey-email-input:focus {
	outline: none;
	border-color: var(--wbsurvey-primary);
	box-shadow: 0 0 0 3px rgba(34, 113, 177, 0.1);
}

.wbsurvey-email-input::placeholder {
	color: var(--wbsurvey-text-muted);
}

.wbsurvey-gdpr-field {
	margin-bottom: var(--wbsurvey-spacing-lg);
	text-align: left;
}

.wbsurvey-gdpr-label {
	display: flex;
	align-items: flex-start;
	gap: var(--wbsurvey-spacing-sm);
	cursor: pointer;
	font-size: var(--wbsurvey-font-size-sm);
	line-height: 1.5;
	color: var(--wbsurvey-text-light);
}

.wbsurvey-gdpr-checkbox {
	width: 18px;
	height: 18px;
	margin-top: 2px;
	flex-shrink: 0;
	cursor: pointer;
	accent-color: var(--wbsurvey-primary);
}

.wbsurvey-gdpr-text {
	flex: 1;
}

.wbsurvey-gdpr-text a {
	color: var(--wbsurvey-primary);
	text-decoration: underline;
}

.wbsurvey-gdpr-text a:hover,
.wbsurvey-gdpr-text a:focus {
	color: var(--wbsurvey-primary-hover);
}

.wbsurvey-email-error {
	background: var(--wbsurvey-error-light);
	color: var(--wbsurvey-error);
	padding: var(--wbsurvey-spacing-sm) var(--wbsurvey-spacing-md);
	border-radius: var(--wbsurvey-radius);
	border-left: 4px solid var(--wbsurvey-error);
	margin-bottom: var(--wbsurvey-spacing-md);
	font-size: var(--wbsurvey-font-size-sm);
	text-align: left;
}

.wbsurvey-email-submit-btn {
	width: 100%;
	justify-content: center;
}

/* ==========================================================================
   Error State
   ========================================================================== */

.wbsurvey-error {
	color: var(--wbsurvey-error);
	padding: var(--wbsurvey-spacing-lg);
	text-align: center;
	background: var(--wbsurvey-error-light);
	border-radius: var(--wbsurvey-radius);
	border: 1px solid var(--wbsurvey-error);
}

/* ==========================================================================
   Animations
   ========================================================================== */

@keyframes wbsurvey-spin {
	to {
		transform: rotate(360deg);
	}
}

@keyframes wbsurvey-fadeIn {
	from {
		opacity: 0;
		transform: translateY(10px);
	}
	to {
		opacity: 1;
		transform: translateY(0);
	}
}

@keyframes wbsurvey-slideIn {
	from {
		opacity: 0;
		transform: translateX(-20px);
	}
	to {
		opacity: 1;
		transform: translateX(0);
	}
}

@keyframes wbsurvey-zoomIn {
	from {
		opacity: 0;
		transform: scale(0.9);
	}
	to {
		opacity: 1;
		transform: scale(1);
	}
}

@keyframes wbsurvey-bounce {
	0%, 20%, 50%, 80%, 100% {
		transform: translateY(0);
	}
	40% {
		transform: translateY(-10px);
	}
	60% {
		transform: translateY(-5px);
	}
}

@keyframes wbsurvey-shake {
	0%, 100% {
		transform: translateX(0);
	}
	10%, 30%, 50%, 70%, 90% {
		transform: translateX(-5px);
	}
	20%, 40%, 60%, 80% {
		transform: translateX(5px);
	}
}

.wbsurvey-shake {
	animation: wbsurvey-shake 0.5s ease;
}

/* ==========================================================================
   Responsive Design - Mobile First
   ========================================================================== */

/* Small devices (landscape phones, 480px and up) */
@media screen and (max-width: 480px) {
	:root {
		--wbsurvey-spacing-xl: 24px;
		--wbsurvey-spacing-lg: 16px;
		--wbsurvey-font-size-xxl: 24px;
		--wbsurvey-font-size-xl: 20px;
	}

	.wbsurvey-container {
		padding: var(--wbsurvey-spacing-md);
	}

	.wbsurvey-form {
		padding: var(--wbsurvey-spacing-lg);
	}

	.wbsurvey-answer {
		padding: var(--wbsurvey-spacing-sm) var(--wbsurvey-spacing-md);
	}

	.wbsurvey-btn {
		padding: var(--wbsurvey-spacing-sm) var(--wbsurvey-spacing-md);
		font-size: var(--wbsurvey-font-size-sm);
	}
}

/* Medium devices (tablets, 768px and down) */
@media screen and (max-width: 768px) {
	.wbsurvey-navigation {
		flex-direction: column;
		gap: var(--wbsurvey-spacing-sm);
	}

	.wbsurvey-navigation .wbsurvey-btn {
		width: 100%;
		max-width: 100%;
		justify-content: center;
	}

	.wbsurvey-poll-analytics-content {
		grid-template-columns: 1fr;
	}
}

/* ==========================================================================
   Print Styles
   ========================================================================== */

@media print {
	.wbsurvey-container {
		max-width: 100%;
		padding: 0;
	}

	.wbsurvey-start-screen,
	.wbsurvey-form,
	.wbsurvey-thankyou-screen {
		box-shadow: none;
		border: 1px solid #ddd;
	}

	.wbsurvey-navigation,
	.wbsurvey-btn {
		display: none;
	}

	.wbsurvey-progress-bar {
		display: none;
	}
}

/* ==========================================================================
   High Contrast Mode Support
   ========================================================================== */

@media (prefers-contrast: high) {
	.wbsurvey-answer {
		border-width: 3px;
	}

	.wbsurvey-btn {
		border: 2px solid currentColor;
	}
}

/* ==========================================================================
   Reduced Motion Support
   ========================================================================== */

/* ========================================
 * Text Input Question Types
 * ======================================== */
.wbsurvey-text-input {
	width: 100%;
	padding: 12px 16px;
	border: 2px solid var(--survey-border, #e0e0e0);
	border-radius: 8px;
	font-size: 15px;
	font-family: inherit;
	line-height: 1.5;
	background: var(--survey-surface, #fff);
	color: var(--survey-text, #1d2327);
	transition: border-color 0.2s, box-shadow 0.2s;
	box-sizing: border-box;
	resize: vertical;
}

.wbsurvey-text-input:focus {
	outline: none;
	border-color: var(--survey-primary, #4caf50);
	box-shadow: 0 0 0 3px rgba(76, 175, 80, 0.15);
}

.wbsurvey-text-input::placeholder {
	color: var(--survey-text-muted, #757575);
}

/* ========================================
 * Rating (Stars) Question Type
 * ======================================== */
.wbsurvey-rating {
	display: flex;
	flex-direction: row-reverse;
	justify-content: flex-end;
	gap: 4px;
	padding: 8px 0;
}

.wbsurvey-rating-input {
	position: absolute;
	opacity: 0;
	width: 0;
	height: 0;
}

.wbsurvey-rating-label {
	font-size: 36px;
	color: #dcdcde;
	cursor: pointer;
	transition: color 0.15s, transform 0.15s;
	line-height: 1;
}

.wbsurvey-rating-label:hover,
.wbsurvey-rating-label:hover ~ .wbsurvey-rating-label {
	color: #ffc107;
	transform: scale(1.1);
}

.wbsurvey-rating-input:checked ~ .wbsurvey-rating-label {
	color: #ffc107;
}

/* ========================================
 * Yes/No Question Type
 * ======================================== */
.wbsurvey-yesno {
	display: flex;
	gap: 12px;
}

.wbsurvey-yesno-option {
	flex: 1;
	cursor: pointer;
}

.wbsurvey-yesno-option input {
	position: absolute;
	opacity: 0;
	width: 0;
	height: 0;
}

.wbsurvey-yesno-label {
	display: flex;
	align-items: center;
	justify-content: center;
	padding: 16px 24px;
	border: 2px solid var(--survey-border, #e0e0e0);
	border-radius: 10px;
	font-size: 16px;
	font-weight: 600;
	text-align: center;
	transition: all 0.2s;
	background: var(--survey-surface, #fff);
}

.wbsurvey-yesno-label:hover {
	border-color: var(--survey-primary, #4caf50);
	background: rgba(76, 175, 80, 0.04);
}

.wbsurvey-yesno-option input:checked + .wbsurvey-yesno-label--yes {
	border-color: #00a32a;
	background: #e6f7eb;
	color: #00a32a;
}

.wbsurvey-yesno-option input:checked + .wbsurvey-yesno-label--no {
	border-color: #d63638;
	background: #fde8e8;
	color: #d63638;
}

@media (prefers-reduced-motion: reduce) {
	*,
	*::before,
	*::after {
		animation-duration: 0.01ms !important;
		animation-iteration-count: 1 !important;
		transition-duration: 0.01ms !important;
	}
}

/* ==========================================================================
   Rating & Yes/No in Survey Context
   ========================================================================== */

.wbsurvey-question .wbpoll-rating-form {
	padding: 20px 0;
}
.wbsurvey-question .wbpoll-rating-stars {
	gap: 8px;
}
.wbsurvey-question .wbpoll-rating-star svg {
	width: 40px;
	height: 40px;
}
.wbsurvey-question .wbpoll-yesno-buttons {
	gap: 24px;
	padding: 20px 0;
}
.wbsurvey-question .wbpoll-yesno-btn {
	padding: 24px 40px;
	min-width: 140px;
}
.wbsurvey-question .wbpoll-yesno-btn svg {
	width: 36px;
	height: 36px;
}
