/* Demo Dashboard styles - uses theme variables from styles.css */
:root {
	--text: #eaf2ff;
	--muted: #c9d7ee;
	--accent: #ff7a59;
	--accent-2: #ff9068;
	--outline: rgba(255,255,255,.16);
}

html, body {
	height: 100%;
}

body {
	margin: 0;
	font-family: Inter, system-ui, -apple-system, Segoe UI, Roboto, Arial, "Noto Sans", "Helvetica Neue", sans-serif;
	color: var(--text);
	background: radial-gradient(1200px 600px at 20% 10%, rgba(255,255,255,0.08), transparent 60%),
		linear-gradient(135deg, #1f3b5b, #2c2e73);
}

.container {
	width: min(1200px, 94%);
	margin: 0 auto;
}

.demo-header {
	background: linear-gradient(90deg, #1882ff, #00b7ff);
	color: #0b1324;
	padding: 14px 0;
	box-shadow: 0 10px 24px rgba(0,0,0,.35);
	position: sticky;
	top: 0;
	z-index: 10;
	border-bottom: 1px solid rgba(255,255,255,.3);
	overflow: hidden;
}

.demo-header .bar {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 12px;
}

.demo-header::after {
	content: "";
	position: absolute;
	inset: 0;
	background: radial-gradient(50% 180% at 120% 10%, rgba(255,255,255,.35), transparent 60%),
		radial-gradient(60% 120% at -20% 50%, rgba(255,255,255,.25), transparent 60%);
	pointer-events: none;
}

.demo-header .title {
	font-size: clamp(18px, 2.4vw, 24px);
	font-weight: 900;
	display: inline-flex;
	align-items: center;
	gap: 10px;
}
.demo-header .title span:first-child {
	font-size: 1.7em;
	filter: drop-shadow(0 6px 18px rgba(0,0,0,.25));
}

.chip-row {
	display: inline-flex;
	gap: 10px;
}

.chip {
	background: rgba(255,255,255,.92);
	color: #0b1324;
	border: 1px solid rgba(0,0,0,.06);
	border-radius: 999px;
	padding: 8px 14px;
	font-weight: 800;
	cursor: pointer;
	text-decoration: none;
	box-shadow: 0 8px 18px rgba(0,0,0,.18);
	transition: transform .12s ease, box-shadow .2s ease, background .2s ease;
}

.chip.secondary {
	background: rgba(255,255,255,.75);
}

.chip:hover {
	transform: translateY(-1px);
	box-shadow: 0 12px 26px rgba(0,0,0,.22);
}

.chip:focus-visible {
	outline: none;
	box-shadow: 0 0 0 3px rgba(255,255,255,.8), 0 10px 24px rgba(0,0,0,.28);
}

.page {
	padding: 22px 0 36px;
}

.exam-grid {
	display: grid;
	grid-template-columns: repeat(auto-fit, minmax(260px, 320px));
	justify-content: center;
	gap: 18px 22px;
}

.exam-card {
	position: relative;
	border: 1px solid transparent;
	background:
		linear-gradient(180deg, rgba(255,255,255,.10), rgba(255,255,255,.04)) padding-box,
		linear-gradient(135deg, rgba(255,255,255,.45), rgba(255,255,255,0) 40%, rgba(255,255,255,.25)) border-box;
	border-radius: 18px;
	box-shadow: 0 12px 28px rgba(0,0,0,.32);
	overflow: hidden;
	transition: transform .12s ease, box-shadow .2s ease;
}

.exam-card:hover {
	transform: translateY(-4px);
	box-shadow: 0 18px 36px rgba(0,0,0,.38);
}

.exam-card::after {
	content: "";
	position: absolute;
	inset: 0;
	background: linear-gradient(100deg, rgba(255,255,255,0) 0%, rgba(255,255,255,.35) 45%, rgba(255,255,255,0) 70%);
	transform: translateX(-120%) rotate(6deg);
	transition: transform .5s ease;
	pointer-events: none;
}

.exam-card:hover::after {
	transform: translateX(120%) rotate(6deg);
}

.exam-logo {
	height: 140px;
	display: grid;
	place-items: center;
	background: radial-gradient(600px 240px at 50% -10%, rgba(255,255,255,.22), transparent 60%);
}
.exam-logo .exam-icon {
	height: 75%;
	aspect-ratio: 1;
	width: auto;
	max-height: 120px;
	max-width: 75%;
	object-fit: cover;
	object-position: center;
	border-radius: 16px;
	box-shadow: 0 8px 20px rgba(0,0,0,.28);
	border: 2px solid rgba(0,0,0,.06);
	image-rendering: -webkit-optimize-contrast;
	image-rendering: crisp-edges;
	backface-visibility: hidden;
	transform: translateZ(0);
	filter: saturate(1.05) contrast(1.05);
	transition: transform .2s ease, filter .2s ease, box-shadow .2s ease;
}
.exam-card:hover .exam-icon { transform: scale(1.04); filter: saturate(1.1) contrast(1.08); box-shadow: 0 12px 26px rgba(0,0,0,.35); }

.exam-logo .badge {
	width: 88px;
	height: 88px;
	border-radius: 24%;
	display: grid;
	place-items: center;
	background: linear-gradient(135deg, #ffffff, #ffe7d2);
	color: #0b1324;
	font-size: 36px;
	font-weight: 900;
	box-shadow: 0 10px 24px rgba(0,0,0,.35);
	border: 2px solid rgba(0,0,0,.06);
	position: relative;
}

.exam-logo .badge::before {
	content: "";
	position: absolute;
	inset: -6px;
	border-radius: 26%;
	background: radial-gradient(closest-side, rgba(255,255,255,.5), transparent 70%);
	z-index: -1;
}

.exam-body {
	padding: 10px 12px 14px;
}

.exam-title {
	margin: 0;
	color: var(--text);
	font-weight: 900;
	font-size: clamp(15px, 1.6vw, 17px);
	line-height: 1.35;
	text-decoration: none;
	display: -webkit-box;
	-webkit-line-clamp: 2;
	-webkit-box-orient: vertical;
	overflow: hidden;
}

.exam-title:hover {
	text-decoration: underline;
}

.subtle {
	color: var(--muted);
	font-weight: 600;
	font-size: 12px;
	margin-top: 4px;
}

@media (max-width: 1100px) {
	.exam-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}
@media (max-width: 780px) {
	.exam-grid { grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); }
}
@media (max-width: 520px) {
	.exam-grid { grid-template-columns: 1fr; }
	.exam-logo { height: 120px; }
	.exam-logo .exam-icon { height: 75%; max-height: 100px; }
}

.test-wrap { margin-bottom: 24px; }
.test-top { display: flex; gap: 12px; align-items: center; justify-content: space-between; margin-bottom: 10px; }
.test-timer, .test-stats {
	display: inline-flex; align-items: center; gap: 10px;
	background: rgba(255,255,255,.06); border: 1px solid var(--outline);
	border-radius: 12px; padding: 8px 12px;
}
.test-card {
	background: rgba(255,255,255,.06); border: 1px solid var(--outline);
	border-radius: 16px; padding: 16px; box-shadow: 0 12px 28px rgba(0,0,0,.32);
}
.test-prompt {
	font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, "Liberation Mono", monospace;
	line-height: 1.8; font-size: clamp(14px, 2.4vw, 17px); min-height: 120px; user-select: none;
}
.test-good { color: #c8ffd4; }
.test-bad { color: #ffd3d3; text-decoration: underline; }
.test-current { background: rgba(255,255,255,.25); color: #0b1324; }
.test-controls { margin-top: 10px; }
.test-row { display: flex; gap: 10px; align-items: center; margin-top: 10px; }
.test-controls textarea {
	width: 100%; min-height: 110px; padding: 12px; border-radius: 12px;
	border: 1px solid var(--outline); background: rgba(255,255,255,.08); color: var(--text);
	resize: vertical; outline: none; transition: box-shadow .2s ease, border-color .2s ease, background .2s ease;
}
.test-controls textarea:focus {
	border-color: rgba(255,255,255,.4); box-shadow: 0 0 0 3px rgba(255,255,255,.14); background: rgba(255,255,255,.12);
}
.test-result { display: none; margin-top: 10px; }
