/* /accuracy: the public benchmark page. Scoped to .acc; chart colours validated with the dataviz palette checks
   (precision indigo / recall teal pass lightness, CVD and 3:1 contrast on white; status colours carry a text label). */
.acc {
	--acc-ink: #1d1d2b;
	--acc-muted: #5f6170;
	--acc-line: #e7e8ef;
	--acc-soft: #f5f6fb;
	--acc-surface: #fff;
	--acc-navy: #1e1d85;
	--acc-precision: #4a48c9;
	--acc-recall: #0b9aa6;
	--acc-good: #0ca30c;
	--acc-bad: #d03b3b;
	--acc-blank: #c9cbd6;
	--acc-radius: 16px;
	color: var(--acc-ink);
	background: var(--acc-surface);
	/* tooltips near the edge must never widen the page */
	overflow-x: clip;
}

/* ---- hero ---- */
.acc-hero {
	position: relative;
	overflow: hidden;
	color: #fff;
	background:
		radial-gradient(circle at 85% 15%, rgba(14, 198, 213, .35), transparent 45%),
		radial-gradient(circle at 10% 90%, rgba(98, 96, 230, .45), transparent 50%),
		linear-gradient(135deg, #17166b 0%, #1e1d85 45%, #2a2aa6 100%);
	padding: 24px 0 120px;
}
.acc-hero::after {
	content: "";
	position: absolute;
	inset: 0;
	background-image: radial-gradient(rgba(255, 255, 255, .12) 1px, transparent 1px);
	background-size: 22px 22px;
	mask-image: linear-gradient(180deg, #000 0%, transparent 85%);
	pointer-events: none;
}
.acc-hero .container { position: relative; z-index: 1; }
.acc-hero .breadcrumb { background: transparent; padding: 0; }
.acc-hero .breadcrumb-item, .acc-hero .breadcrumb-item a, .acc-hero .breadcrumb-item::before { color: rgba(255, 255, 255, .75) !important; }
.acc-eyebrow {
	display: inline-flex;
	align-items: center;
	gap: 8px;
	font-size: 13px;
	font-weight: 600;
	letter-spacing: .08em;
	text-transform: uppercase;
	color: #8ff0f7;
	margin: 48px 0 12px;
}
.acc-hero h1 {
	color: #fff;
	font-size: clamp(30px, 5vw, 52px);
	line-height: 1.12;
	font-weight: 600;
	max-width: 820px;
	margin-bottom: 16px;
}
.acc-lead { font-size: clamp(16px, 2vw, 19px); line-height: 1.6; max-width: 720px; color: rgba(255, 255, 255, .86); margin-bottom: 24px; }
.acc-badges { display: flex; flex-wrap: wrap; gap: 8px; }
.acc-badge {
	display: inline-flex;
	align-items: center;
	gap: 8px;
	padding: 7px 14px;
	border-radius: 999px;
	background: rgba(255, 255, 255, .12);
	border: 1px solid rgba(255, 255, 255, .2);
	font-size: 14px;
	color: #fff;
	backdrop-filter: blur(4px);
}
.acc-badge i { color: #8ff0f7; }

.acc-sample {
	background: rgba(255, 255, 255, .1);
	border: 1px solid rgba(255, 255, 255, .22);
	border-radius: var(--acc-radius);
	padding: 22px;
	backdrop-filter: blur(6px);
	transform: rotate(1.5deg);
	box-shadow: 0 30px 60px -30px rgba(0, 0, 0, .5);
}
.acc-sample-label { font-size: 12px; font-weight: 600; letter-spacing: .08em; text-transform: uppercase; color: #8ff0f7; margin-bottom: 8px; }
.acc-sample-title { font-size: 15px; font-style: italic; color: rgba(255, 255, 255, .9); margin-bottom: 14px; line-height: 1.5; }
.acc-chip { display: inline-flex; align-items: center; gap: 6px; margin: 0 6px 8px 0; padding: 5px 12px; border-radius: 999px; font-size: 13px; font-weight: 500; background: #fff; color: var(--acc-ink); }
.acc-chip::before { content: "\2713"; font-weight: 700; color: var(--acc-good); }
.acc-chip.type { background: #e8e8fb; }
.acc-chip.strategy { background: #e2f6f8; }
.acc-chip.signal { background: #fff6e0; }
.acc-chip.count { background: #eef0f4; }

/* ---- headline tiles ---- */
.acc-tiles { margin-top: -88px; position: relative; z-index: 2; }
.acc-tile {
	height: 100%;
	background: var(--acc-surface);
	border-radius: var(--acc-radius);
	box-shadow: 0 18px 40px -18px rgba(23, 22, 107, .35), 0 2px 6px rgba(23, 22, 107, .06);
	padding: 24px;
	display: flex;
	flex-direction: column;
	gap: 12px;
	transition: transform .2s ease, box-shadow .2s ease;
}
.acc-tile:hover { transform: translateY(-3px); box-shadow: 0 24px 48px -18px rgba(23, 22, 107, .45), 0 2px 6px rgba(23, 22, 107, .08); }
.acc-tile-head { display: flex; align-items: center; gap: 16px; }
.acc-tile-title { font-size: 15px; font-weight: 600; color: var(--acc-muted); margin: 0; }
.acc-tile-sub { font-size: 15px; line-height: 1.55; color: var(--acc-ink); margin: 0; }
.acc-tile-foot { font-size: 13px; color: var(--acc-muted); margin: auto 0 0; padding-top: 12px; border-top: 1px solid var(--acc-line); }

.acc-gauge { position: relative; width: 96px; height: 96px; flex: 0 0 96px; }
.acc-gauge svg { width: 100%; height: 100%; transform: rotate(-90deg); }
.acc-gauge .track { stroke: var(--acc-soft); }
.acc-gauge .value { stroke-linecap: round; transition: stroke-dasharray 1s ease; }
.acc-gauge-label {
	position: absolute;
	inset: 0;
	display: flex;
	align-items: center;
	justify-content: center;
	font-size: 26px;
	font-weight: 700;
	color: var(--acc-ink);
	letter-spacing: -.02em;
}
.acc-gauge-label small { font-size: 14px; font-weight: 600; margin-left: 1px; }

/* ---- section scaffolding ---- */
.acc-section { padding: 64px 0 0; }
.acc-section:last-of-type { padding-bottom: 72px; }
.acc-kicker { font-size: 13px; font-weight: 600; letter-spacing: .08em; text-transform: uppercase; color: var(--acc-recall); margin-bottom: 8px; }
.acc-h2 { font-size: clamp(24px, 3.2vw, 34px); font-weight: 600; color: var(--acc-ink); line-height: 1.2; margin-bottom: 12px; }
.acc-intro { font-size: 17px; line-height: 1.65; color: var(--acc-muted); max-width: 760px; margin-bottom: 32px; }
.acc-card {
	height: 100%;
	background: var(--acc-surface);
	border: 1px solid var(--acc-line);
	border-radius: var(--acc-radius);
	padding: 24px;
}
.acc-card-auto { height: auto; }
.acc-card h3 { font-size: 20px; font-weight: 600; color: var(--acc-ink); margin-bottom: 6px; }
.acc-card-note { font-size: 14px; color: var(--acc-muted); margin-bottom: 20px; line-height: 1.55; }

/* ---- live strip ---- */
.acc-live { background: var(--acc-soft); border-radius: var(--acc-radius); padding: 28px 24px; }
.acc-live-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(130px, 1fr)); gap: 24px 20px; }
.acc-live-icon { display: inline-flex; align-items: center; justify-content: center; width: 36px; height: 36px; border-radius: 10px; background: #fff; color: var(--acc-precision); font-size: 15px; margin-bottom: 10px; box-shadow: 0 2px 6px rgba(23, 22, 107, .08); }
.acc-live-num { font-size: 30px; font-weight: 700; letter-spacing: -.02em; color: var(--acc-navy); line-height: 1.1; }
.acc-live-label { font-size: 14px; color: var(--acc-muted); margin-top: 4px; }
.acc-pulse { display: inline-block; width: 8px; height: 8px; border-radius: 50%; background: var(--acc-good); box-shadow: 0 0 0 0 rgba(12, 163, 12, .5); animation: acc-pulse 2s infinite; margin-right: 6px; vertical-align: middle; }
@keyframes acc-pulse { 70% { box-shadow: 0 0 0 8px rgba(12, 163, 12, 0); } 100% { box-shadow: 0 0 0 0 rgba(12, 163, 12, 0); } }

/* ---- icon arrays (precision / recall explainer) ---- */
.acc-dots { display: grid; grid-template-columns: repeat(10, 1fr); gap: 5px; max-width: 220px; margin: 16px 0; }
.acc-dots span { aspect-ratio: 1; border-radius: 50%; background: var(--acc-blank); }
.acc-dots.found span.on { background: var(--acc-recall); }
.acc-dots.confirmed span.on { background: var(--acc-precision); }
.acc-dots span.off { background: transparent; box-shadow: inset 0 0 0 1.5px var(--acc-blank); }
.acc-big { font-size: 44px; font-weight: 700; letter-spacing: -.03em; line-height: 1; }
.acc-big.found { color: var(--acc-recall); }
.acc-big.confirmed { color: var(--acc-precision); }

/* ---- legends ---- */
.acc-legend { display: flex; flex-wrap: wrap; gap: 16px; font-size: 13px; color: var(--acc-muted); margin-bottom: 16px; }
.acc-legend span { display: inline-flex; align-items: center; gap: 6px; }
.acc-legend i { display: inline-block; width: 12px; height: 12px; border-radius: 3px; }
.acc-legend .precision { background: var(--acc-precision); }
.acc-legend .recall { background: var(--acc-recall); }
.acc-legend .good { background: var(--acc-good); }
.acc-legend .blank { background: var(--acc-blank); }
.acc-legend .bad { background: var(--acc-bad); }

/* ---- bar rows (paired precision/recall, or a single accuracy bar) ---- */
.acc-rows { display: flex; flex-direction: column; gap: 14px; }
.acc-row { display: grid; grid-template-columns: minmax(110px, 34%) 1fr; gap: 12px; align-items: center; }
.acc-row-label { font-size: 14px; font-weight: 500; color: var(--acc-ink); line-height: 1.3; }
.acc-row-label small { display: block; font-size: 12px; font-weight: 400; color: var(--acc-muted); }
.acc-bars { display: flex; flex-direction: column; gap: 4px; }
.acc-bar { position: relative; display: flex; align-items: center; gap: 8px; outline: none; }
.acc-bar-track { flex: 1; height: 10px; background: var(--acc-soft); border-radius: 4px; overflow: hidden; }
.acc-bar-fill { display: block; height: 100%; border-radius: 0 4px 4px 0; }
.acc-bar-fill.precision { background: var(--acc-precision); }
.acc-bar-fill.recall { background: var(--acc-recall); }
.acc-bar-value { flex: 0 0 40px; font-size: 13px; font-weight: 600; color: var(--acc-ink); text-align: right; font-variant-numeric: tabular-nums; }

@media (min-width: 992px) {
	.acc-rows-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 14px 48px; }
}
.acc-pipeline { list-style: none; counter-reset: step; padding: 0; margin: 0; }
.acc-pipeline li { counter-increment: step; position: relative; padding: 0 0 16px 44px; font-size: 14px; color: var(--acc-muted); line-height: 1.55; }
.acc-pipeline li:last-child { padding-bottom: 0; }
.acc-pipeline li::before { content: counter(step); position: absolute; left: 0; top: 0; width: 28px; height: 28px; border-radius: 50%; background: #e2f6f8; color: var(--acc-recall); font-weight: 700; font-size: 13px; display: flex; align-items: center; justify-content: center; }
.acc-pipeline li:not(:last-child)::after { content: ""; position: absolute; left: 13.5px; top: 32px; bottom: 4px; border-left: 1px dashed var(--acc-blank); }
.acc-pipeline b { display: block; color: var(--acc-ink); font-weight: 600; }

.acc-callout { margin: 24px 0 0; padding: 14px 16px; border-radius: 12px; background: var(--acc-soft); font-size: 14px; line-height: 1.55; color: var(--acc-muted); }
.acc-callout b { color: var(--acc-ink); }

/* hover / focus tooltip shared by bars, stacked segments and trend columns */
.acc-tip { position: relative; cursor: default; }
.acc-tip::after {
	content: attr(data-tip);
	position: absolute;
	left: 50%;
	bottom: calc(100% + 8px);
	transform: translate(-50%, 4px);
	width: max-content;
	padding: 8px 10px;
	border-radius: 8px;
	background: #1d1d2b;
	color: #fff;
	font-size: 12px;
	line-height: 1.45;
	font-weight: 500;
	white-space: normal;
	text-align: left;
	max-width: min(240px, 80vw);
	display: none;
	pointer-events: none;
	z-index: 5;
}
/* display, not opacity: a hidden tooltip still counts toward the page's scroll width */
.acc-tip:hover::after, .acc-tip:focus-visible::after { display: block; transform: translate(-50%, 0); }
.acc-tip:focus-visible { outline: 2px solid var(--acc-precision); outline-offset: 2px; border-radius: 4px; }
.acc-bar:hover .acc-bar-track, .acc-bar:focus-visible .acc-bar-track { box-shadow: 0 0 0 2px rgba(74, 72, 201, .18); }

/* ---- stacked right / blank / wrong ---- */
.acc-stack { display: flex; gap: 2px; height: 14px; border-radius: 4px; }
.acc-stack > span { display: block; height: 100%; min-width: 3px; }
.acc-stack > span:first-child { border-radius: 4px 0 0 4px; }
.acc-stack > span:last-child { border-radius: 0 4px 4px 0; }
.acc-stack .good { background: var(--acc-good); }
.acc-stack .blank { background: var(--acc-blank); }
.acc-stack .bad { background: var(--acc-bad); }
.acc-stack-meta { display: flex; flex-wrap: wrap; gap: 4px 14px; font-size: 12px; color: var(--acc-muted); margin-top: 6px; }
.acc-stack-meta b { color: var(--acc-ink); font-weight: 600; }

/* ---- trend chart: SVG lines with HTML labels and CSS crosshair columns ---- */
.acc-trend { position: relative; height: 280px; margin: 8px 0 0 36px; }
.acc-trend svg { position: absolute; inset: 0; width: 100%; height: 100%; overflow: visible; }
.acc-trend .grid line { stroke: var(--acc-line); stroke-width: 1; vector-effect: non-scaling-stroke; }
.acc-trend .series { fill: none; stroke-width: 2; stroke-linejoin: round; stroke-linecap: round; vector-effect: non-scaling-stroke; }
.acc-trend .series.precision { stroke: var(--acc-precision); }
.acc-trend .series.recall { stroke: var(--acc-recall); }
.acc-ytick { position: absolute; left: -36px; transform: translateY(-50%); font-size: 12px; color: var(--acc-muted); font-variant-numeric: tabular-nums; }
.acc-point { position: absolute; width: 10px; height: 10px; margin: -5px 0 0 -5px; border-radius: 50%; border: 2px solid #fff; pointer-events: none; }
.acc-point.precision { background: var(--acc-precision); }
.acc-point.recall { background: var(--acc-recall); }
.acc-endlabel { position: absolute; right: 0; transform: translate(0, -135%); font-size: 12px; font-weight: 600; white-space: nowrap; background: rgba(255, 255, 255, .9); padding: 0 2px; }
.acc-endlabel.precision { color: var(--acc-precision); }
.acc-endlabel.recall { color: var(--acc-recall); }
.acc-endlabel.below { transform: translate(0, 35%); }
.acc-col { position: absolute; top: 0; bottom: 0; transform: translateX(-50%); }
.acc-col::before { content: ""; position: absolute; left: 50%; top: 0; bottom: 0; border-left: 1px dashed transparent; }
.acc-col:hover::before, .acc-col:focus-visible::before { border-left-color: #9a9cab; }
.acc-col.acc-tip::after { bottom: auto; top: -8px; transform: translate(-50%, -100%); }
.acc-col.acc-tip:hover::after, .acc-col.acc-tip:focus-visible::after { transform: translate(-50%, -100%); }
.acc-col:first-of-type.acc-tip::after { left: 0; transform: translate(0, -100%); }
.acc-col:last-of-type.acc-tip::after { left: auto; right: 0; transform: translate(0, -100%); }
.acc-xaxis { position: relative; height: 24px; margin: 8px 0 0 36px; font-size: 12px; color: var(--acc-muted); }
.acc-xaxis span { position: absolute; transform: translateX(-50%); white-space: nowrap; }
.acc-axis-caption { font-size: 13px; color: var(--acc-muted); margin: 6px 0 0 36px; }

/* ---- weaknesses, method, FAQ ---- */
.acc-flag { display: flex; gap: 16px; align-items: flex-start; }
.acc-flag-icon { flex: 0 0 44px; height: 44px; border-radius: 12px; display: flex; align-items: center; justify-content: center; font-size: 18px; background: #fdecec; color: var(--acc-bad); }
.acc-flag-icon.info { background: #e9f8f9; color: var(--acc-recall); }
.acc-flag h3 { font-size: 17px; margin-bottom: 4px; }
.acc-flag p { font-size: 15px; color: var(--acc-muted); margin: 0; line-height: 1.6; }
.acc-step-num { width: 40px; height: 40px; border-radius: 50%; background: var(--acc-navy); color: #fff; display: flex; align-items: center; justify-content: center; font-weight: 700; margin-bottom: 16px; }
.acc-rules { list-style: none; padding: 0; margin: 0; }
.acc-rules li { padding: 10px 0 10px 28px; position: relative; border-bottom: 1px solid var(--acc-line); font-size: 15px; }
.acc-rules li:last-child { border-bottom: 0; }
.acc-rules li::before { content: "\2192"; position: absolute; left: 4px; color: var(--acc-recall); font-weight: 700; }
.acc-faq details { border-bottom: 1px solid var(--acc-line); }
.acc-faq summary { list-style: none; cursor: pointer; padding: 18px 40px 18px 0; position: relative; font-size: 17px; font-weight: 500; color: var(--acc-ink); }
.acc-faq summary::-webkit-details-marker { display: none; }
.acc-faq summary::after { content: "+"; position: absolute; right: 8px; top: 50%; transform: translateY(-50%); font-size: 24px; font-weight: 300; color: var(--acc-precision); transition: transform .2s ease; }
.acc-faq details[open] summary::after { transform: translateY(-50%) rotate(45deg); }
.acc-faq details p { color: var(--acc-muted); font-size: 15px; line-height: 1.65; padding-bottom: 18px; margin: 0; max-width: 760px; }
.acc-table-toggle { margin-top: 20px; font-size: 14px; }
.acc-table-toggle summary { cursor: pointer; color: var(--acc-precision); font-weight: 500; }
.acc-table-toggle table { margin-top: 12px; font-size: 13px; font-variant-numeric: tabular-nums; }
.acc-cta {
	border-radius: var(--acc-radius);
	padding: 40px 32px;
	color: #fff;
	background: radial-gradient(circle at 90% 10%, rgba(14, 198, 213, .4), transparent 50%), linear-gradient(135deg, #17166b, #2a2aa6);
}
.acc-cta h2 { color: #fff; font-size: clamp(22px, 3vw, 30px); font-weight: 600; margin-bottom: 8px; }
.acc-cta p { color: rgba(255, 255, 255, .85); margin-bottom: 20px; font-size: 16px; }
.acc-cta .btn-light { color: var(--acc-navy); font-weight: 600; }
.acc-cta .btn-outline-light { font-weight: 600; }

@media (max-width: 575.98px) {
	.acc-hero { padding-bottom: 100px; }
	.acc-eyebrow { margin-top: 28px; }
	.acc-row { grid-template-columns: 1fr; gap: 6px; }
	.acc-trend { height: 220px; }
	.acc-card, .acc-tile { padding: 20px; }
	.acc-cta { padding: 32px 20px; }
}
@media (prefers-reduced-motion: reduce) {
	.acc-tile, .acc-gauge .value { transition: none; }
	.acc-pulse { animation: none; }
}
