:root {
	font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
	color-scheme: light dark;
	--background: #f5f7fb;
	--surface: #ffffff;
	--surface-subtle: #f8fafc;
	--text: #142033;
	--muted: #667085;
	--border: #e4e9f1;
	--border-strong: #d4dbe7;
	--accent: #2563eb;
	--accent-dark: #1748b8;
	--focus: #93c5fd;
	--success: #047857;
	--danger: #b42318;
	--shadow: 0 22px 65px rgba(28, 46, 78, .09);
}

* { box-sizing: border-box }

html { scroll-behavior: smooth }

body {
	margin: 0;
	min-width: 320px;
	min-height: 100vh;
	color: var(--text);
	background:
		radial-gradient(circle at 10% -10%, rgba(37, 99, 235, .11), transparent 27rem),
		var(--background);
}

button, input, select { font: inherit }
button, select { cursor: pointer }

button:focus-visible, input:focus-visible, select:focus-visible, a:focus-visible, .table-wrap:focus-visible {
	outline: 3px solid var(--focus);
	outline-offset: 2px;
}

main { width: min(1180px, calc(100% - 40px)); margin: 0 auto; padding: 28px 0 64px }

.checker {
	position: relative;
	display: grid;
	grid-template-columns: minmax(0, 1.05fr) minmax(440px, .95fr);
	gap: 56px;
	align-items: center;
	min-height: 360px;
	padding: 52px;
	overflow: hidden;
	color: #fff;
	border-radius: 30px;
	background:
		radial-gradient(circle at 92% 12%, rgba(84, 210, 255, .34), transparent 19rem),
		linear-gradient(132deg, #102a63, #174bb4 58%, #127aa0);
	box-shadow: 0 28px 70px rgba(23, 72, 184, .23);
}

.checker::after {
	content: "";
	position: absolute;
	right: -80px;
	bottom: -120px;
	width: 330px;
	height: 330px;
	border: 1px solid rgba(255, 255, 255, .15);
	border-radius: 50%;
	box-shadow: 0 0 0 48px rgba(255, 255, 255, .035), 0 0 0 96px rgba(255, 255, 255, .025);
	pointer-events: none;
}

.checker-copy, .check-panel { position: relative; z-index: 1 }
.eyebrow { display: block; margin-bottom: 9px; color: var(--accent); font-size: 11px; font-weight: 800; letter-spacing: .15em }
.checker .eyebrow { color: #a9ddff }
h1, h2, p { margin-top: 0 }
h1 { max-width: 580px; margin-bottom: 16px; font-size: clamp(36px, 4.4vw, 54px); line-height: 1.04; letter-spacing: -.045em }
.checker-copy > p { max-width: 540px; margin-bottom: 0; color: rgba(255, 255, 255, .76); font-size: 16px; line-height: 1.55 }
.header-summary { display: grid; grid-template-columns: .85fr 1.35fr 1fr; gap: 8px; max-width: 570px; margin-top: 28px; padding: 8px; border: 1px solid rgba(255, 255, 255, .18); border-radius: 17px; background: rgba(4, 22, 58, .18); backdrop-filter: blur(14px) }
.header-summary > span { display: grid; gap: 3px; min-width: 0; padding: 10px 11px; border-radius: 11px; background: rgba(255, 255, 255, .07) }
.header-summary strong { color: #fff; font-size: clamp(18px, 2vw, 25px); font-variant-numeric: tabular-nums; line-height: 1; letter-spacing: -.025em }
.header-summary small { color: rgba(255, 255, 255, .62); font-size: 9px; font-weight: 800; letter-spacing: .065em; text-transform: uppercase }

.check-panel {
	padding: 24px;
	border: 1px solid rgba(255, 255, 255, .2);
	border-radius: 22px;
	background: rgba(255, 255, 255, .11);
	box-shadow: 0 18px 50px rgba(4, 22, 58, .17);
	backdrop-filter: blur(18px);
}

.tabs { display: inline-grid; grid-template-columns: 1fr 1fr; gap: 4px; margin-bottom: 22px; padding: 4px; border-radius: 12px; background: rgba(4, 22, 58, .2) }
.tabs button { min-width: 104px; padding: 9px 15px; color: rgba(255, 255, 255, .72); font-size: 13px; font-weight: 750; border: 0; border-radius: 9px; background: transparent }
.tabs button[aria-selected="true"] { color: #102a63; background: #fff; box-shadow: 0 5px 16px rgba(4, 22, 58, .18) }
.tabs button:disabled { cursor: wait; opacity: .72 }

#check-form label { display: block; margin-bottom: 8px; font-size: 13px; font-weight: 700 }
.check-row { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 10px }
.check-row input {
	width: 100%;
	min-width: 0;
	height: 52px;
	padding: 0 16px;
	color: #142033;
	border: 1px solid transparent;
	border-radius: 12px;
	background: #fff;
	box-shadow: 0 8px 24px rgba(4, 22, 58, .12);
}
.check-row input::placeholder { color: #98a2b3 }
.primary-button { height: 52px; padding: 0 21px; color: #102a63; font-weight: 800; border: 0; border-radius: 12px; background: #bdeaff; transition: transform .18s ease, background .18s ease }
.primary-button:hover { transform: translateY(-1px); background: #d2f2ff }
.primary-button:disabled { cursor: wait; opacity: .72; transform: none }
#check-hint { display: block; margin-top: 8px; color: rgba(255, 255, 255, .62); font-size: 12px }
.legal-note { position: relative; margin: 17px 0 0; padding: 13px 13px 13px 38px; color: rgba(255, 255, 255, .7); font-size: 11px; line-height: 1.4; border-top: 1px solid rgba(255, 255, 255, .13) }
.legal-note::before { content: "✓"; position: absolute; top: 11px; left: 12px; display: grid; width: 18px; height: 18px; place-items: center; color: #d5f7e7; font-size: 11px; font-weight: 900; border: 1px solid rgba(213, 247, 231, .38); border-radius: 50%; background: rgba(6, 95, 70, .25) }

.check-result { display: flex; gap: 14px; align-items: center; justify-content: space-between; margin-top: 18px; padding: 14px 15px; border: 1px solid rgba(255, 255, 255, .16); border-radius: 13px; background: rgba(4, 22, 58, .22) }
.check-result[hidden] { display: none }
.check-result span { font-size: 14px; font-weight: 750 }
.check-result.found { border-color: rgba(255, 176, 176, .62); background: linear-gradient(100deg, rgba(117, 18, 28, .78), rgba(151, 27, 38, .62)); box-shadow: 0 10px 28px rgba(80, 5, 12, .2) }
.check-result.found #result-text::before { content: "!"; display: inline-grid; width: 20px; height: 20px; margin-right: 9px; place-items: center; color: #8f1722; font-size: 12px; font-weight: 900; border-radius: 50%; background: #ffe3e3 }
.check-result.error span { color: #ffe0dc }
.check-result a { flex: none; padding: 9px 13px; color: #13367e; font-size: 13px; font-weight: 800; text-decoration: none; border-radius: 9px; background: #fff }
.check-result.found a { color: #8f1722 }

.sources { margin-top: 32px; padding: 30px; border: 1px solid var(--border); border-radius: 24px; background: var(--surface); box-shadow: var(--shadow) }
.section-heading { display: flex; align-items: flex-end; justify-content: space-between; gap: 20px; margin-bottom: 24px }
.section-heading h2 { margin-bottom: 0; font-size: 30px; letter-spacing: -.035em }
.source-count { padding: 7px 11px; color: var(--muted); font-size: 12px; font-weight: 700; border: 1px solid var(--border); border-radius: 999px; background: var(--surface-subtle) }

.filters { display: grid; grid-template-columns: minmax(240px, 1fr) 210px; gap: 12px; margin-bottom: 16px }
.filters label > span { display: block; margin-bottom: 7px; color: var(--muted); font-size: 12px; font-weight: 700 }
.filters input, .filters select { width: 100%; height: 44px; color: var(--text); border: 1px solid var(--border-strong); border-radius: 11px; background: var(--surface-subtle) }
.filters input { padding: 0 14px }
.filters select { padding: 0 36px 0 13px }
.filters input::placeholder { color: #98a2b3 }
.filters input:disabled, .filters select:disabled { cursor: wait; opacity: .6 }

.table-wrap { max-height: min(72vh, 760px); overflow: auto; border: 1px solid var(--border); border-radius: 15px; scrollbar-color: var(--border-strong) transparent }
table { width: 100%; min-width: 820px; border-spacing: 0; border-collapse: separate; font-size: 13px }
thead { position: sticky; z-index: 2; top: 0 }
th { padding: 0; text-align: left; border-bottom: 1px solid var(--border-strong); background: var(--surface-subtle) }
th button { display: flex; width: 100%; min-height: 46px; gap: 7px; align-items: center; padding: 0 14px; color: var(--muted); font-size: 11px; font-weight: 800; letter-spacing: .045em; text-align: left; text-transform: uppercase; border: 0; background: transparent }
th button:hover { color: var(--text) }
th span::after { content: "↕"; opacity: .45 }
th[aria-sort="ascending"] span::after { content: "↑"; color: var(--accent); opacity: 1 }
th[aria-sort="descending"] span::after { content: "↓"; color: var(--accent); opacity: 1 }
td { padding: 15px 14px; line-height: 1.45; vertical-align: top; border-bottom: 1px solid var(--border) }
tbody tr:last-child td { border-bottom: 0 }
tbody tr:nth-child(even) { background: color-mix(in srgb, var(--surface-subtle) 65%, transparent) }
tbody tr:hover { background: color-mix(in srgb, var(--accent) 5%, var(--surface)) }
td:first-child { width: 24%; font-weight: 750 }
td:nth-child(2) { width: 48%; color: var(--muted) }
td:nth-child(3) { width: 13%; white-space: nowrap }
td:last-child { width: 15%; font-variant-numeric: tabular-nums; text-align: right; white-space: nowrap }
th:last-child button { justify-content: flex-end; text-align: right }
.state-row td { padding: 42px 18px; color: var(--muted); text-align: center; background: var(--surface) }
noscript { display: block; padding: 16px; color: var(--danger); font-size: 13px; text-align: center }

@media (prefers-color-scheme: dark) {
	:root {
		--background: #0c111b;
		--surface: #121a27;
		--surface-subtle: #172130;
		--text: #edf2fa;
		--muted: #9ca9bb;
		--border: #263246;
		--border-strong: #344158;
		--accent: #70a0ff;
		--accent-dark: #3973e8;
		--focus: #60a5fa;
		--shadow: 0 24px 70px rgba(0, 0, 0, .24);
	}
	body { background: radial-gradient(circle at 10% -10%, rgba(59, 130, 246, .14), transparent 27rem), var(--background) }
}

@media (max-width: 850px) {
	.checker { grid-template-columns: 1fr; gap: 34px; padding: 40px; }
	.checker-copy > p, .header-summary { max-width: none }
}

@media (max-width: 620px) {
	main { width: min(100% - 24px, 1180px); padding: 12px 0 32px }
	.checker { gap: 28px; min-height: 0; padding: 28px 18px 18px; border-radius: 22px }
	h1 { margin-bottom: 12px; font-size: 36px }
	.checker-copy > p { font-size: 14px }
	.header-summary { grid-template-columns: 1fr 1fr; margin-top: 22px }
	.header-summary > span:nth-child(2) { grid-column: 1 / -1; grid-row: 2 }
	.header-summary strong { font-size: 20px }
	.check-panel { padding: 15px; border-radius: 17px }
	.tabs { display: grid; width: 100%; margin-bottom: 18px }
	.tabs button { min-width: 0 }
	.check-row { grid-template-columns: 1fr }
	.primary-button { width: 100% }
	.check-result { align-items: stretch; flex-direction: column }
	.check-result a { text-align: center }
	.sources { margin-top: 16px; padding: 20px 12px 12px; border-radius: 19px }
	.section-heading { margin-inline: 5px }
	.section-heading h2 { font-size: 26px }
	.filters { grid-template-columns: 1fr; margin-inline: 2px }
	.table-wrap { max-height: 68vh; border-radius: 12px }
	table { min-width: 760px }
}

@media (prefers-reduced-motion: reduce) {
	html { scroll-behavior: auto }
	.primary-button { transition: none }
}
