.exampyq-exam {
	width: 100%;
}
.exampyq-exam__bar {
	display: flex;
	justify-content: space-between;
	align-items: center;
	gap: 16px;
	padding: 16px 20px;
	border: 1px solid var(--exampyq-border);
	border-radius: 12px;
	background: #fff;
	margin-bottom: 16px;
}
.exampyq-exam__bar h1 {
	margin: 0;
	font-size: 1.25rem;
}
.exampyq-exam__tools {
	display: flex;
	align-items: center;
	gap: 12px;
	flex-wrap: wrap;
}
.exampyq-lang {
	display: flex;
	align-items: center;
	gap: 8px;
	margin: 0;
	font-size: 13px;
}
.exampyq-exam select,
.exampyq-lang select {
	height: 36px;
	width: auto;
	min-width: 72px;
	padding: 0 10px;
	border: 1px solid var(--exampyq-border);
	border-radius: 6px;
	background: #fff;
}
.exampyq-timer {
	font-variant-numeric: tabular-nums;
	font-weight: 650;
	margin: 0;
	min-width: 72px;
}
.exampyq-exam__grid {
	display: flex;
	flex-direction: column;
	gap: 16px;
	width: 100%;
}
.exampyq-exam__main,
.exampyq-exam__nav {
	border: 1px solid var(--exampyq-border);
	border-radius: 12px;
	padding: 20px 24px;
	background: #fff;
	width: 100%;
	box-sizing: border-box;
	min-width: 0;
}
.exampyq-exam__actions {
	display: flex;
	flex-wrap: wrap;
	gap: 8px;
	margin-top: 20px;
}
.exampyq-exam__actions [hidden] {
	display: none !important;
}
.exampyq-qgrid {
	display: flex;
	flex-wrap: wrap;
	gap: 8px;
}
.exampyq-qgrid button {
	flex: 0 0 auto;
	width: 36px;
	height: 36px;
	min-width: 36px;
	min-height: 36px;
	box-sizing: border-box;
	border: 1px solid #c5d0d6;
	background: #f4f6f8;
	cursor: pointer;
	border-radius: 4px;
}
.exampyq-qgrid button.is-answered {
	background: #d1fae5;
	border-color: #059669;
}
.exampyq-qgrid button.is-marked,
.exampyq-legend .is-marked {
	background: #fde68a;
	border-color: #d97706;
}
.exampyq-qgrid button.is-answered_marked {
	background: linear-gradient(135deg, #d1fae5 50%, #fde68a 50%);
}
.exampyq-qgrid button.is-current {
	outline: 2px solid var(--exampyq-accent);
}
.exampyq-options {
	display: grid;
	gap: 10px;
	margin-top: 12px;
}
.exampyq-option {
	display: flex;
	align-items: center;
	gap: 12px;
	width: 100%;
	min-height: 44px;
	padding: 12px 14px;
	margin: 0;
	border: 1px solid var(--exampyq-border);
	border-radius: 8px;
	cursor: pointer;
	background: #fff;
	text-align: left;
	font: inherit;
	color: inherit;
}
.exampyq-option:hover {
	border-color: var(--exampyq-accent);
}
.exampyq-option.is-on {
	border-color: var(--exampyq-accent);
	background: color-mix(in srgb, var(--exampyq-accent) 10%, #fff);
}
.exampyq-option span {
	line-height: 1.4;
}
.exampyq-fib {
	display: flex;
	flex-direction: column;
	align-items: flex-start;
	gap: 8px;
	margin-top: 12px;
}
.exampyq-fib input {
	width: 100%;
	max-width: 420px;
	height: 36px;
	padding: 0 12px;
	border: 1px solid var(--exampyq-border);
	border-radius: 6px;
}
.exampyq-legend {
	list-style: none;
	padding: 12px 0 0;
	margin: 0;
	font-size: 13px;
}
.exampyq-legend span {
	display: inline-block;
	width: 12px;
	height: 12px;
	margin-right: 6px;
	border: 1px solid #c5d0d6;
	background: #f4f6f8;
}
.exampyq-legend .is-answered {
	background: #d1fae5;
}
#exampyq-calc-toggle.is-active {
	background: var(--exampyq-accent);
	color: #fff;
}
.exampyq-calc {
	position: fixed;
	right: 16px;
	bottom: 16px;
	width: 268px;
	background: #fff;
	border-radius: 20px;
	box-shadow: 0 24px 48px -12px rgba(15, 23, 42, 0.28), 0 4px 12px rgba(15, 23, 42, 0.08);
	z-index: 30;
	overflow: hidden;
	visibility: hidden;
	opacity: 0;
	transform-origin: bottom right;
	transform: translateY(18px) scale(0.9);
	pointer-events: none;
	transition: opacity 0.18s ease, transform 0.18s ease;
}
.exampyq-calc.is-visible {
	visibility: visible;
}
.exampyq-calc.is-open {
	opacity: 1;
	transform: translateY(0) scale(1);
	pointer-events: auto;
	transition: opacity 0.28s cubic-bezier(0.34, 1.56, 0.64, 1), transform 0.28s cubic-bezier(0.34, 1.56, 0.64, 1);
}
.exampyq-calc__head {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 8px;
	padding: 12px 10px 12px 16px;
	background: linear-gradient(135deg, var(--exampyq-accent), var(--exampyq-accent-hover));
	color: #fff;
}
.exampyq-calc__title {
	display: flex;
	align-items: center;
	gap: 8px;
	font-size: 14px;
	font-weight: 650;
	letter-spacing: 0.01em;
}
.exampyq-calc__title .dashicons {
	font-size: 16px;
	width: 16px;
	height: 16px;
}
.exampyq-calc__close {
	width: 26px;
	height: 26px;
	border: none;
	border-radius: 50%;
	background: rgba(255, 255, 255, 0.18);
	color: #fff;
	font-size: 18px;
	line-height: 1;
	cursor: pointer;
	display: flex;
	align-items: center;
	justify-content: center;
	transition: background 0.15s ease, transform 0.2s ease;
}
.exampyq-calc__close:hover {
	background: rgba(255, 255, 255, 0.32);
	transform: rotate(90deg);
}
.exampyq-calc__screen {
	padding: 20px 18px 12px;
	background: #f8fafc;
	border-bottom: 1px solid var(--exampyq-border);
}
.exampyq-calc__out {
	font-family: ui-monospace, 'SFMono-Regular', Menlo, Consolas, 'Liberation Mono', monospace;
	font-size: 30px;
	font-weight: 650;
	text-align: right;
	color: #0f172a;
	overflow-x: auto;
	white-space: nowrap;
	scrollbar-width: none;
}
.exampyq-calc__out::-webkit-scrollbar {
	display: none;
}
.exampyq-calc-keys {
	display: grid;
	grid-template-columns: repeat(4, 1fr);
	gap: 8px;
	padding: 14px;
}
.exampyq-calc-key {
	height: 46px;
	border: none;
	border-radius: 12px;
	background: #eef2f6;
	color: #0f172a;
	font-size: 15px;
	font-weight: 650;
	cursor: pointer;
	transition: background 0.12s ease, transform 0.08s ease;
}
.exampyq-calc-key:hover {
	background: #e2e8f0;
}
.exampyq-calc-key:active {
	transform: scale(0.92);
}
.exampyq-calc-key.is-op {
	background: color-mix(in srgb, var(--exampyq-accent) 12%, #fff);
	color: var(--exampyq-accent);
}
.exampyq-calc-key.is-op:hover {
	background: color-mix(in srgb, var(--exampyq-accent) 22%, #fff);
}
.exampyq-calc-key.is-op-clear {
	color: #b42318;
	background: color-mix(in srgb, #b42318 8%, #fff);
}
.exampyq-calc-key.is-op-clear:hover {
	background: color-mix(in srgb, #b42318 16%, #fff);
}
.exampyq-calc-key.is-op-equals {
	background: var(--exampyq-accent);
	color: #fff;
}
.exampyq-calc-key.is-op-equals:hover {
	background: var(--exampyq-accent-hover);
}
@media (max-width: 768px) {
	.exampyq-exam__bar {
		flex-direction: column;
		align-items: flex-start;
	}
	.exampyq-calc {
		right: 12px;
		bottom: 12px;
		left: 12px;
		width: auto;
	}
}
@media (prefers-reduced-motion: reduce) {
	.exampyq-qgrid button,
	.exampyq-calc,
	.exampyq-calc-key,
	.exampyq-calc__close {
		transition: none;
	}
}
