:root {
	/* Light mode (default) */
	--bg: #f9fafb;
	--bg-secondary: #f3f4f6;
	--card: #ffffff;
	--text-primary: #111827;
	--text-secondary: #6b7280;
	--text-muted: #9ca3af;
	--accent: #6366f1;
	--accent-2: #ec4899;
	--accent-3: #14b8a6;
	--border: #e5e7eb;
	--border-light: #f3f4f6;
	--shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
	--shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
	--shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1);
	--shadow-xl: 0 20px 25px -5px rgba(0, 0, 0, 0.1);
	--glass: rgba(255, 255, 255, 0.8);
}

/* Dark mode */
[data-theme="dark"] {
	--bg: #0f1724;
	--bg-secondary: #0b1220;
	--card: #0b1220;
	--text-primary: rgba(255, 255, 255, 0.95);
	--text-secondary: rgba(255, 255, 255, 0.75);
	--text-muted: rgba(255, 255, 255, 0.60);
	--accent: #7c5cff;
	--accent-2: #00c2a8;
	--accent-3: #00c2a8;
	--border: rgba(255, 255, 255, 0.08);
	--border-light: rgba(255, 255, 255, 0.03);
	--shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.3);
	--shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.4);
	--shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.5);
	--shadow-xl: 0 20px 25px -5px rgba(0, 0, 0, 0.6);
	--glass: rgba(255, 255, 255, 0.03);
}

[data-theme="dark"] body::before {
	background-image: linear-gradient(-105deg, rgb(100 0 255 / 84%), #000000);
	opacity: 0.95;
}

/* Apply requested card gradient in dark mode */
[data-theme="dark"] .card {
	background: linear-gradient(268deg, rgb(141 86 255 / 80%), #140d1a);
	border: 1px solid rgba(255, 255, 255, 0.04);
	box-shadow: 0 12px 30px rgba(20, 10, 20, 0.5);
	color: var(--text-primary);
	/* keep rounded corners and subtle blur for contrast */
	backdrop-filter: blur(4px);
}

[data-theme="dark"] .card h3,
[data-theme="dark"] .card p {
	color: var(--text-primary);
}

* {
	box-sizing: border-box
}

html,
body {
	height: 100%;
	scroll-behavior: smooth
}

body {
	margin: 0;
	font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', 'Roboto', 'Oxygen', 'Ubuntu', 'Cantarell', sans-serif;
	background: var(--bg);
	color: var(--text-primary);
	-webkit-font-smoothing: antialiased;
	-webkit-tap-highlight-color: transparent;
	touch-action: manipulation;
	line-height: 1.6
}

.wrap {
	max-width: 1100px;
	margin: 0 auto;
	padding: 0 20px
}

.topbar {
	backdrop-filter: blur(9px);
	background: rgb(0 104 247 / 38%);
	border-bottom: 1px solid var(--border);
	position: sticky;
	top: 0;
	z-index: 1000;
	box-shadow: var(--shadow-sm)
}

.topbar-inner {
	display: flex;
	align-items: center;
	justify-content: space-between;
	padding: 16px 0;
	flex-wrap: wrap;
	gap: 12px
}

.brand {
	color: var(--accent);
	font-weight: 700;
	text-decoration: none;
	font-size: 20px;
	letter-spacing: -0.5px;
	font-family: 'Poppins', -apple-system, BlinkMacSystemFont, 'Segoe UI', 'Roboto', sans-serif;
}

.nav {
	display: flex;
	gap: 8px;
	align-items: center;
	flex-wrap: wrap
}

.nav a {
	color: var(--text-secondary);
	text-decoration: none;
	padding: 10px 16px;
	border-radius: 8px;
	transition: all 200ms ease;
	min-height: 44px;
	display: flex;
	align-items: center;
	font-weight: 500;
	font-size: 14px
}

.nav a:hover,
.nav a:focus {
	background: var(--bg-secondary);
	color: var(--accent);
	outline: none
}

.menu-toggle {
	display: none;
	background: var(--bg-secondary);
	border: 1px solid var(--border);
	color: var(--text-secondary);
	padding: 8px 12px;
	border-radius: 8px;
	cursor: pointer;
	font-size: 20px;
	min-height: 44px;
	min-width: 44px;
	transition: all 200ms ease
}

.menu-toggle:hover,
.menu-toggle:focus {
	background: var(--bg);
	color: var(--accent);
	outline: none
}

.btn-whatsapp {
	background: linear-gradient(135deg, #25D366, #128C7E);
	color: white;
	border: none;
	padding: 10px 20px;
	border-radius: 8px;
	font-weight: 600;
	min-height: 44px;
	font-size: 14px;
	transition: all 200ms ease;
	box-shadow: var(--shadow-md)
}

.btn-whatsapp:hover {
	transform: translateY(-2px);
	box-shadow: 0 10px 20px rgba(37, 211, 102, 0.25)
}

.actions .btn {
	white-space: nowrap
}

.hero {
	padding: 80px 0;
	background: linear-gradient(135deg, #72ade8 0%, #f3f4f6 100%);
}

.hero-inner {
	display: grid;
	grid-template-columns: 1fr 360px;
	gap: 48px;
	align-items: center
}

.hero-copy h1 {
	margin: 0;
	font-size: clamp(32px, 5vw, 52px);
	line-height: 1.2;
	color: var(--text-primary);
	font-weight: 700;
	letter-spacing: -1px
}

.lede {
	margin-top: 16px;
	color: var(--text-secondary);
	max-width: 54ch;
	font-size: 16px
}

.hero-ctas {
	margin-top: 24px;
	display: flex;
	gap: 12px;
	align-items: center
}

.btn {
	display: inline-block;
	padding: 12px 24px;
	border-radius: 10px;
	border: 0;
	cursor: pointer;
	font-size: 14px;
	font-weight: 600;
	min-height: 44px;
	transition: all 200ms ease;
	text-decoration: none;
	letter-spacing: 0.3px
}

.btn:hover,
.btn:focus {
	outline: none;
	transform: translateY(-2px)
}

.btn-primary {
	background: linear-gradient(135deg, var(--accent), #4f46e5);
	color: white;
	box-shadow: var(--shadow-md)
}

.btn-primary:hover {
	box-shadow: 0 12px 24px rgba(99, 102, 241, 0.3)
}

.btn-ghost {
	background: transparent;
	border: 2px solid var(--border);
	color: var(--text-secondary);
	font-weight: 600
}

.btn-ghost:hover {
	background: var(--bg-secondary);
	border-color: var(--accent);
	color: var(--accent)
}

.mock-code {
	background: #f5f5f5;
	padding: 20px;
	border-radius: 12px;
	color: #1a1a1a;
	overflow: auto;
	border: 1px solid var(--border);
	font-family: 'Monaco', 'Menlo', 'Ubuntu Mono', monospace;
	font-size: 13px;
	line-height: 1.5
}

.section {
	padding: 60px 0
}

.section.alt {
	background: var(--bg-secondary)
}

.section.small {
	padding: 40px 0
}

.section-head h2 {
	margin: 0;
	font-size: 32px;
	color: var(--text-primary);
	font-weight: 700;
	letter-spacing: -0.5px
}

.muted {
	color: var(--text-secondary)
}

.course-controls {
	display: flex;
	gap: 12px;
	align-items: center;
	margin: 24px 0
}

.course-controls input[type=search],
.course-controls select {
	padding: 12px 16px;
	border-radius: 10px;
	border: 1px solid var(--border);
	background: var(--bg);
	color: var(--text-primary);
	min-height: 44px;
	font-size: 14px;
	transition: all 200ms ease
}

.course-controls input[type=search]:focus,
.course-controls select:focus {
	outline: none;
	border-color: var(--accent);
	box-shadow: 0 0 0 3px rgba(99, 102, 241, 0.1)
}

.grid {
	display: grid;
	grid-template-columns: repeat(3, 1fr);
	gap: 16px;
	margin-top: 6px
}

.card {
	background: var(--card);
	padding: 20px;
	border-radius: 12px;
	border: 1px solid var(--border);
	box-shadow: var(--shadow-sm);
	transition: all 200ms ease
}

.card:hover {
	box-shadow: var(--shadow-lg);
	border-color: var(--accent-3);
	transform: translateY(-4px)
}

.card h3 {
	margin: 0 0 8px 0;
	color: var(--text-primary);
	font-weight: 600
}

.card p {
	margin: 0 0 12px 0;
	color: var(--text-secondary);
	font-size: 14px
}

.meta {
	display: flex;
	gap: 8px;
	align-items: center;
	font-size: 13px;
	color: var(--text-muted)
}

.label {
	background: var(--bg-secondary);
	color: var(--accent);
	padding: 6px 10px;
	border-radius: 8px;
	font-weight: 500;
	font-size: 12px
}

.card .cta {
	display: flex;
	justify-content: space-between;
	align-items: center;
	margin-top: 16px
}

.features {
	padding: 20px 0
}

.feature-grid {
	display: grid;
	grid-template-columns: repeat(3, 1fr);
	gap: 16px;
	margin-top: 12px
}

.feature {
	background: var(--card);
	padding: 24px;
	border-radius: 12px;
	border: 1px solid var(--border);
	transition: all 200ms ease
}

.feature:hover {
	box-shadow: var(--shadow-lg);
	border-color: var(--accent)
}

.faq {
	display: flex;
	flex-direction: column;
	gap: 8px;
	margin-top: 12px
}

.faq-item {
	background: var(--card);
	border-radius: 10px;
	padding: 16px;
	text-align: left;
	border: 1px solid var(--border);
	cursor: pointer;
	color: var(--text-primary);
	position: relative;
	transition: all 200ms ease
}

.faq-item:hover {
	border-color: var(--accent);
	box-shadow: var(--shadow-sm)
}

.faq-item .q {
	display: block;
	font-weight: 600;
	color: var(--text-primary)
}

.faq-item .a {
	display: block;
	margin-top: 12px;
	color: var(--text-secondary);
	max-height: 0;
	overflow: hidden;
	transition: max-height 0.28s ease, opacity 0.28s ease;
	opacity: 0
}

.faq-item.open .a {
	max-height: 220px;
	opacity: 1
}

.contact-form {
	display: grid;
	grid-template-columns: 1fr 1fr;
	gap: 16px;
	margin-top: 24px
}

.contact-form input,
.contact-form textarea {
	padding: 12px 16px;
	border-radius: 10px;
	border: 1px solid var(--border);
	background: var(--bg);
	color: var(--text-primary);
	font-size: 14px;
	font-family: inherit;
	min-height: 44px;
	transition: all 200ms ease
}

.contact-form textarea {
	min-height: 120px;
	resize: vertical;
	font-family: inherit
}

.contact-form input:focus,
.contact-form textarea:focus {
	outline: none;
	border-color: var(--accent);
	box-shadow: 0 0 0 3px rgba(99, 102, 241, 0.1)
}

.contact-form .form-actions {
	grid-column: 1/-1
}

.footer {
	padding: 32px 0;
	color: var(--text-muted);
	border-top: 1px solid var(--border);
	background: var(--bg-secondary)
}

@media (max-width:900px) {
	.hero-inner {
		grid-template-columns: 1fr
	}

	.grid {
		grid-template-columns: repeat(2, 1fr)
	}

	.feature-grid {
		grid-template-columns: repeat(2, 1fr)
	}

	.contact-form {
		grid-template-columns: 1fr
	}

	.actions {
		flex-wrap: wrap;
		gap: 8px
	}

	.pricing-grid {
		flex-direction: column
	}

	.section-head h2 {
		font-size: 28px
	}
}

@media (max-width:768px) {
	.wrap {
		padding: 0 16px
	}

	.hero {
		padding: 48px 0
	}

	.hero-copy h1 {
		font-size: clamp(24px, 5vw, 36px)
	}

	.hero-ctas {
		flex-wrap: wrap
	}

	.section {
		padding: 40px 0
	}

	.course-controls {
		flex-direction: column;
		align-items: stretch
	}

	.course-controls input[type=search],
	.course-controls select {
		width: 100%
	}

	.actions {
		display: none;
		position: absolute;
		top: 60px;
		right: 0;
		background: var(--card);
		border: 1px solid var(--border);
		border-radius: 8px;
		padding: 12px;
		min-width: 200px;
		flex-direction: column;
		gap: 8px;
		z-index: 999
	}

	.nav.active~.actions {
		display: flex
	}

	.menu-toggle {
		display: inline-block
	}
}

@media (max-width:600px) {
	.grid {
		grid-template-columns: 1fr
	}

	.wrap {
		padding: 0 14px
	}

	.topbar-inner {
		padding: 12px 0
	}

	.brand {
		font-size: 16px
	}

	.nav {
		display: none;
		position: absolute;
		top: 56px;
		left: 0;
		right: 0;
		flex-direction: column;
		background: var(--card);
		border-bottom: 1px solid rgba(255, 255, 255, 0.02);
		padding: 12px;
		gap: 0
	}

	.nav.active {
		display: flex
	}

	.nav a {
		padding: 12px;
		text-align: left
	}

	.section {
		padding: 24px 0
	}

	.hero {
		padding: 24px 0
	}

	.hero-copy h1 {
		font-size: clamp(20px, 3vw, 28px);
		margin-bottom: 12px
	}

	.lede {
		font-size: 14px
	}

	.hero-ctas {
		flex-direction: column;
		align-items: stretch;
		gap: 8px
	}

	.btn {
		padding: 14px 16px;
		width: 100%;
		text-align: center
	}

	.feature-grid {
		grid-template-columns: 1fr;
		gap: 12px
	}

	.contact-form {
		grid-template-columns: 1fr;
		gap: 10px
	}

	.pricing-card {
		max-width: 100%
	}

	.faq-item .a {
		max-height: 300px;
		font-size: 13px
	}

	.feedback-head {
		flex-direction: column;
		align-items: flex-start
	}

	.stars {
		transform: scale(1);
		gap: 4px
	}

	.star {
		padding: 4px 6px;
		font-size: 16px
	}
}

/* AI Tutor chat styles */
.ai-tutor {
	position: fixed;
	right: 18px;
	bottom: 18px;
	width: 360px;
	max-width: calc(100% - 36px);
	height: 520px;
	background: var(--card);
	border-radius: 12px;
	box-shadow: var(--shadow-xl);
	display: flex;
	flex-direction: column;
	z-index: 10010;
	overflow: hidden;
	border: 1px solid var(--border)
}

.ai-tutor[aria-hidden="true"] {
	display: none
}

.ai-header {
	display: flex;
	justify-content: space-between;
	align-items: center;
	padding: 16px;
	border-bottom: 1px solid var(--border);
	font-weight: 700;
	background: linear-gradient(135deg, var(--accent), #4f46e5);
	color: white
}

.ai-messages {
	flex: 1;
	padding: 16px;
	overflow: auto;
	background: var(--bg)
}

.ai-messages .msg {
	margin-bottom: 12px;
	display: block
}

.ai-messages .msg.user {
	text-align: right
}

.ai-messages .bubble {
	display: inline-block;
	padding: 10px 14px;
	border-radius: 10px;
	max-width: 86%;
	font-size: 14px
}

.ai-messages .bubble.user {
	background: linear-gradient(135deg, var(--accent), #4f46e5);
	color: white
}

.ai-messages .bubble.ai {
	background: var(--bg-secondary);
	color: var(--text-primary)
}

.ai-form {
	display: flex;
	gap: 8px;
	padding: 12px;
	border-top: 1px solid var(--border)
}

.ai-form input {
	flex: 1;
	padding: 10px 14px;
	border-radius: 8px;
	border: 1px solid var(--border);
	background: var(--bg);
	color: var(--text-primary);
	font-size: 14px
}

.ai-form input:focus {
	outline: none;
	border-color: var(--accent)
}

@media (max-width:480px) {
	.ai-tutor {
		right: 10px;
		left: 10px;
		width: auto;
		height: 60vh
	}
}

/* Pricing section styles */
.pricing-grid {
	display: flex;
	gap: 16px;
	margin-top: 24px
}

.pricing-card {
	max-width: 420px;
	text-align: left;
	background: var(--card);
	padding: 28px;
	border-radius: 12px;
	border: 1px solid var(--border);
	transition: all 200ms ease
}

.pricing-card:hover {
	border-color: var(--accent);
	box-shadow: var(--shadow-lg);
	transform: translateY(-4px)
}

.pricing-card .price {
	font-size: 32px;
	margin: 12px 0;
	color: var(--accent);
	font-weight: 700
}

.pricing-card .period {
	font-size: 14px;
	color: var(--text-secondary);
	margin-left: 6px
}

.pricing-card .benefits {
	margin: 16px 0;
	padding-left: 0;
	list-style: none
}

.pricing-card .benefits li {
	padding: 8px 0;
	color: var(--text-secondary);
	display: flex;
	align-items: center
}

.pricing-card .benefits li:before {
	content: '✓';
	color: var(--accent-3);
	font-weight: 700;
	margin-right: 10px;
	font-size: 16px
}

.pricing-card .cta-row {
	display: flex;
	gap: 10px;
	align-items: center;
	margin-top: 20px
}

/* subscription badge in header */
.sub-badge {
	background: linear-gradient(135deg, var(--accent-3), var(--accent));
	color: white;
	padding: 6px 12px;
	border-radius: 8px;
	font-weight: 600;
	font-size: 12px
}

@media (max-width:800px) {
	.pricing-grid {
		flex-direction: column
	}
}

/* Dimmer overlay used by Brighten/Darken controls */
#dimmer {
	position: fixed;
	inset: 0;
	pointer-events: none;
	background: rgba(0, 0, 0, 0.0);
	transition: background-color 320ms ease, opacity 320ms ease;
	opacity: 0;
	z-index: 9000;
}

/* small ghost button for header controls */
.btn-ghost {
	padding: 8px 10px
}

.actions .btn-ghost {
	margin-right: 8px
}

/* reduced motion accessibility */
@media (prefers-reduced-motion:reduce) {
	#dimmer {
		transition: none
	}
}

/* Feedback / rating styles */
.stars {
	display: inline-flex;
	gap: 6px
}

.star {
	background: var(--bg);
	border: 1px solid var(--border);
	color: var(--text-muted);
	padding: 8px 10px;
	border-radius: 8px;
	cursor: pointer;
	font-size: 16px;
	transition: all 200ms ease
}

.star:hover {
	border-color: var(--accent);
	color: var(--accent)
}

.star.active {
	background: linear-gradient(135deg, var(--accent), var(--accent-2));
	color: white;
	border-color: transparent
}

.feedback-head {
	display: flex;
	align-items: center;
	justify-content: space-between
}

.feedback-list {
	margin-top: 16px;
	display: flex;
	flex-direction: column;
	gap: 12px
}

.feedback-item {
	background: var(--bg-secondary);
	padding: 14px;
	border-radius: 10px;
	border: 1px solid var(--border)
}

.feedback-item .meta {
	font-size: 13px;
	color: var(--text-muted);
	margin-bottom: 8px
}

/* Avatar styles */
.avatar-img {
	width: 40px;
	height: 40px;
	border-radius: 50%;
	object-fit: cover;
	display: inline-block;
	border: 2px solid var(--accent)
}

.avatar-fallback {
	display: inline-block
}

@media (max-width:900px) {
	.stars {
		transform: scale(0.95)
	}
}

/* RTL specific tweaks */
[dir="rtl"] {
	direction: rtl;
}

[dir="rtl"] .hero-copy {
	text-align: right
}

[dir="rtl"] .nav {
	direction: rtl
}

[dir="rtl"] .nav a {
	text-align: right
}

[dir="rtl"] .topbar-inner {
	direction: ltr
}

[dir="rtl"] .feedback-head {
	direction: rtl;
	flex-direction: column;
	align-items: flex-end;
}

/* Discount Wheel Styles */
.wheel-modal {
	position: fixed;
	top: 0;
	left: 0;
	width: 100%;
	height: 100%;
	z-index: 2000;
	display: flex;
	align-items: center;
	justify-content: center;
	opacity: 0;
	pointer-events: none;
	transition: opacity 300ms ease;
}

.wheel-modal[aria-hidden="false"] {
	opacity: 1;
	pointer-events: auto;
}

.wheel-overlay {
	position: absolute;
	top: 0;
	left: 0;
	width: 100%;
	height: 100%;
	background: rgba(0, 0, 0, 0.5);
	z-index: -1;
}

.wheel-content {
	background: var(--card);
	border: 1px solid var(--border);
	border-radius: 16px;
	padding: 40px;
	max-width: 500px;
	width: 90%;
	position: relative;
	box-shadow: var(--shadow-xl)
}

.wheel-close {
	position: absolute;
	top: 16px;
	right: 16px;
	background: transparent;
	border: none;
	color: var(--text-secondary);
	font-size: 28px;
	cursor: pointer;
	padding: 0;
	width: 40px;
	height: 40px;
	display: flex;
	align-items: center;
	justify-content: center;
	border-radius: 8px;
	transition: all 200ms ease;
}

.wheel-close:hover {
	background: var(--bg-secondary);
	color: var(--accent)
}

.wheel-container {
	position: relative;
	display: flex;
	justify-content: center;
	align-items: center;
	margin: 20px 0;
}

.discount-wheel {
	filter: drop-shadow(0 10px 30px rgba(0, 0, 0, 0.15))
}

.wheel-pointer {
	position: absolute;
	top: -12px;
	left: 50%;
	transform: translateX(-50%);
	width: 0;
	height: 0;
	border-left: 12px solid transparent;
	border-right: 12px solid transparent;
	border-top: 20px solid var(--accent);
	z-index: 10;
}

#spinBtn {
	font-weight: 700;
	font-size: 16px;
	letter-spacing: 1px;
	transition: all 200ms ease;
	background: linear-gradient(135deg, var(--accent), #4f46e5);
	color: white;
	border: none;
	padding: 12px 24px;
	border-radius: 10px;
	cursor: pointer;
	min-height: 44px
}

#spinBtn:hover {
	transform: scale(1.05);
	box-shadow: 0 8px 24px rgba(99, 102, 241, 0.3)
}

#spinBtn:disabled {
	opacity: 0.6;
	cursor: not-allowed;
	transform: scale(1)
}

#wheelResult {
	animation: slideUp 300ms ease
}

@keyframes slideUp {
	from {
		opacity: 0;
		transform: translateY(20px);
	}

	to {
		opacity: 1;
		transform: translateY(0);
	}
}

@keyframes stickerFly {
	0% {
		opacity: 1;
		transform: translate(0, 0) rotate(0deg) scale(1);
	}

	100% {
		opacity: 0;
		transform: translate(var(--tx), var(--ty)) rotate(360deg) scale(0.3);
	}
}

.sticker {
	position: fixed;
	pointer-events: none;
	z-index: 2001;
}

/* WhatsApp modal tweaks reuse wheel modal styles */
.wheel-content input,
.wheel-content textarea {
	background: var(--bg);
	color: var(--text-primary);
	border: 1px solid var(--border);
	border-radius: 8px;
}

@media (max-width: 600px) {
	.wheel-content {
		padding: 24px;
	}

	.discount-wheel {
		width: 250px !important;
		height: 250px !important;
	}
}

/* Game modal styles */
.game-modal {
	position: fixed;
	inset: 0;
	display: none;
	align-items: center;
	justify-content: center;
	z-index: 1200;
}

.game-modal[aria-hidden="false"] {
	display: flex;
}

.game-overlay {
	position: absolute;
	inset: 0;
	background: rgba(0, 0, 0, 0.5);
}

.game-content {
	position: relative;
	z-index: 2;
	background: var(--card);
	color: var(--text-primary);
	padding: 28px;
	width: 520px;
	max-width: calc(100% - 40px);
	border-radius: 12px;
	box-shadow: var(--shadow-xl);
	border: 1px solid var(--border)
}

.game-close {
	position: absolute;
	right: 16px;
	top: 16px;
	background: transparent;
	border: none;
	font-size: 20px;
	cursor: pointer;
	color: var(--text-secondary);
	transition: all 200ms ease;
	padding: 8px;
	border-radius: 8px
}

.game-close:hover {
	background: var(--bg-secondary);
	color: var(--accent)
}

.game-question {
	font-size: 18px;
	font-weight: 600;
	color: var(--text-primary);
	margin-bottom: 16px
}

.game-options {
	display: flex;
	flex-direction: column;
	gap: 10px
}

.game-options .game-opt {
	text-align: left;
	padding: 14px 16px;
	border-radius: 10px;
	border: 1px solid var(--border);
	background: var(--bg);
	color: var(--text-primary);
	cursor: pointer;
	transition: all 200ms ease;
	font-weight: 500
}

.game-options .game-opt:hover {
	border-color: var(--accent);
	background: var(--bg-secondary)
}

.game-options .game-opt.active {
	background: linear-gradient(135deg, var(--accent), #4f46e5);
	color: white;
	border-color: transparent;
	font-weight: 600
}

.game-options .game-opt.incorrect {
	background: rgba(239, 68, 68, 0.1);
	color: #dc2626;
	border-color: #dc2626
}

.game-options .game-opt:focus {
	outline: none;
	box-shadow: 0 0 0 3px rgba(99, 102, 241, 0.1)
}

.game-result {
	font-weight: 700;
	color: var(--text-primary);
	margin-top: 12px
}

/* Level assessment overlay */
.level-overlay {
	position: fixed;
	inset: 0;
	display: none;
	align-items: center;
	justify-content: center;
	background: rgba(0, 0, 0, 0.5);
	z-index: 11000;
}

.level-overlay[aria-hidden="false"] {
	display: flex;
}

.level-overlay-inner {
	width: 90%;
	max-width: 820px;
	padding: 28px;
	text-align: center;
	color: var(--text-primary);
	background: var(--card);
	border-radius: 12px;
	border: 1px solid var(--border);
	box-shadow: var(--shadow-xl)
}

.level-message {
	font-size: 20px;
	font-weight: 700;
	margin-bottom: 24px;
	color: var(--text-primary)
}

.level-bar {
	height: 16px;
	background: var(--bg-secondary);
	border-radius: 999px;
	overflow: hidden;
	width: 100%;
	margin: 0 auto;
	border: 1px solid var(--border)
}

.level-bar-fill {
	height: 100%;
	width: 0%;
	background: linear-gradient(90deg, #f59e0b, #ef4444);
	transition: width 2.5s ease;
}

.level-percent {
	margin-top: 12px;
	font-weight: 700;
	color: var(--accent);
	font-size: 16px
}

@media (max-width:600px) {
	.level-overlay-inner {
		padding: 12px;
	}

	.level-message {
		font-size: 16px;
	}
}

/* Play Now button (stylish orange) */
#playNowBtn {
	background: linear-gradient(135deg, #f59e0b, #ef4444);
	color: white;
	border: none;
	box-shadow: 0 8px 24px rgba(245, 158, 11, 0.2);
	font-weight: 700;
	padding: 12px 28px;
	border-radius: 10px;
	cursor: pointer;
	font-size: 16px;
	min-height: 44px;
	transition: all 200ms ease
}

#playNowBtn:hover {
	transform: translateY(-2px);
	box-shadow: 0 12px 30px rgba(239, 68, 68, 0.3)
}

/* --- Visual polish additions --- */

/* soft decorative background blobs */
body::before {
	content: '';
	position: fixed;
	inset: 0;
	z-index: -1;
	pointer-events: none;
	background-image: radial-gradient(circle at 10% 20%, rgba(99, 102, 241, 0.06) 0%, transparent 18%),
		radial-gradient(circle at 90% 80%, rgba(236, 72, 153, 0.04) 0%, transparent 16%);
	opacity: 1;
	transition: opacity 400ms ease;
}

/* gentle hero entrance */
.hero-inner {
	animation: cl-fade-up 700ms cubic-bezier(.2, .9, .3, 1) both;
}

@keyframes cl-fade-up {
	from {
		opacity: 0;
		transform: translateY(10px);
	}

	to {
		opacity: 1;
		transform: translateY(0);
	}
}

/* subtle text glow for hero headline */
.hero-copy h1 {
	text-shadow: 0 6px 20px rgba(99, 102, 241, 0.06);
}

/* glassy cards + improved hover */
.card {
	background: linear-gradient(180deg, rgba(255, 255, 255, 0.8), var(--card));
	backdrop-filter: blur(6px);
	border: 1px solid rgba(255, 255, 255, 0.06);
}

.card:hover {
	transform: translateY(-6px) scale(1.01);
	box-shadow: 0 18px 40px rgba(2, 6, 23, 0.12);
}

/* improved primary button with soft glow */
.btn-primary {
	position: relative;
	overflow: visible;
}

.btn-primary:after {
	content: '';
	position: absolute;
	left: 50%;
	top: 50%;
	transform: translate(-50%, -50%);
	width: 260%;
	height: 260%;
	background: radial-gradient(closest-side, rgba(99, 102, 241, 0.08), transparent 40%);
	opacity: 0;
	transition: opacity 220ms ease, transform 220ms ease;
	pointer-events: none;
	border-radius: 50%;
}

.btn-primary:hover:after {
	opacity: 1;
	transform: translate(-50%, -50%) scale(1.02);
}

/* smaller subtle animations for interactive affordances */
.nav a {
	transition: transform 160ms ease, background-color 160ms ease;
}

.nav a:hover {
	transform: translateY(-2px);
}

/* reduce motion respects user prefs */
@media (prefers-reduced-motion:reduce) {
	.hero-inner {
		animation: none
	}

	.card,
	.btn-primary {
		transition: none
	}
}

/* Mobile / touch-specific "hover" behavior styles */
@media (hover: none) and (pointer: coarse),
(max-width: 600px) {
	.card {
		touch-action: manipulation;
	}

	.card.touch-hover {
		transform: translateY(-6px) scale(1.01);
		box-shadow: 0 18px 40px rgba(2, 6, 23, 0.18);
		border-color: rgba(255, 255, 255, 0.04);
	}

	/* ensure buttons remain tappable inside cards */
	.card.touch-hover .btn {
		transform: none
	}
}

/* --- Page-away styles: apply when user leaves the tab/window --- */
/* Adds a subtle blur/gray effect and suppresses hover transforms while away */
body.away {
	transition: filter 300ms ease, opacity 300ms ease;
}

body.away .card,
body.away .hero,
body.away .feature,
body.away .pricing-card,
body.away .feature-grid,
body.away .grid,
body.away .ai-tutor {
	filter: blur(3px) grayscale(0.25) saturate(0.9);
	opacity: 0.75;
	transition: filter 300ms ease, opacity 300ms ease;
}

/* Disable hover/transform motion while away to avoid flicker */
body.away .card:hover,
body.away .btn:hover,
body.away .nav a:hover {
	transform: none !important;
}

/* Away banner (visible while away) */
#awayBanner {
	position: fixed;
	right: 16px;
	top: 16px;
	z-index: 12050;
	background: rgba(15, 23, 36, 0.85);
	color: white;
	padding: 8px 12px;
	border-radius: 10px;
	font-weight: 700;
	font-size: 13px;
	backdrop-filter: blur(6px);
	box-shadow: 0 8px 20px rgba(2, 6, 23, 0.6);
}