/* ArgTools pages (loaded after styles.css and site.css) */

.stat {
	background: #fff;
	border: 1px solid #dee2e6;
	border-radius: .5rem;
	padding: .75rem 1rem;
}
.stat-value { font-size: 1.6rem; font-weight: 600; line-height: 1.1; }
.stat-label { font-size: .8rem; color: #6c757d; }
.stat-warn { border-color: #f0ad4e; background: #fff8ec; }

pre.snippet {
	background: #f6f8fa;
	border: 1px solid #e5e7eb;
	border-radius: .35rem;
	padding: .5rem .75rem;
	font-size: .8rem;
	max-height: 14rem;
	overflow: auto;
	white-space: pre-wrap;
}

details.blob > summary { cursor: pointer; list-style: none; }
details.blob > summary::-webkit-details-marker { display: none; }
details.blob > summary::before { content: "\25B8"; color: #6c757d; margin-right: .25rem; }
details.blob[open] > summary::before { content: "\25BE"; }

.diff-wrap { overflow-x: auto; max-height: 70vh; overflow-y: auto; border: 1px solid #e5e7eb; border-radius: .35rem; }
table.diff {
	width: 100%;
	border-collapse: collapse;
	table-layout: fixed;
	font-family: SFMono-Regular, Consolas, "Liberation Mono", Menlo, monospace;
	font-size: .78rem;
	background: #fff;
}
table.diff col.ln { width: 3.2rem; }
table.diff thead th { position: sticky; top: 0; background: #f1f3f5; font-family: system-ui, sans-serif; font-weight: 600; padding: .3rem .5rem; z-index: 1; }
table.diff td { padding: 0 .5rem; white-space: pre-wrap; word-break: break-word; vertical-align: top; }
table.diff td.ln { color: #9aa0a6; text-align: right; user-select: none; background: #fafafa; border-right: 1px solid #eee; }
table.diff td.del { background: #ffebe9; }
table.diff td.add { background: #e6ffec; }
table.diff td.empty { background: #f6f8fa; }
table.diff tr.fold td { background: #f1f8ff; color: #57606a; text-align: center; font-family: system-ui, sans-serif; padding: .2rem; }

.option-row { padding: .45rem 0; border-bottom: 1px solid #f1f3f5; }
.option-row:last-child { border-bottom: 0; }
.choice-help { margin-top: .2rem; }
.ruleset-toc a { white-space: nowrap; }
.sticky-save { position: sticky; bottom: 0; background: var(--ca-bg, #f0f2f5); border-top: 1px solid #dee2e6; z-index: 5; }

/* ---- in-app help: <help topic="..."/> question marks and the help pages ---- */
.help-link { color: #0d6efd; opacity: .7; text-decoration: none; font-size: .9em; margin-left: .3rem; vertical-align: baseline; font-weight: normal; }
.help-link:hover, .help-link:focus { opacity: 1; }
h1 .help-link, .h1 .help-link, .h3 .help-link, .h4 .help-link { font-size: .6em; vertical-align: middle; }
.help-nav-heading { font-weight: 600; text-transform: uppercase; font-size: .72rem; letter-spacing: .04em; color: #6c757d; margin-bottom: .25rem; }
.help-nav li a { display: block; padding: .15rem .5rem; border-left: 2px solid transparent; text-decoration: none; }
.help-nav li a:hover { background: #f1f3f5; }
.help-nav li a.active { border-left-color: #0d6efd; font-weight: 600; background: #e7f1ff; }
.help-body { max-width: 48rem; line-height: 1.6; }
.help-body h2 { font-size: 1.15rem; margin-top: 1.5rem; }
.help-body h3 { font-size: 1rem; margin-top: 1.25rem; }
.help-body code { background: #f6f8fa; padding: .05rem .25rem; border-radius: .2rem; }
.help-body li { margin-bottom: .25rem; }

/* rulesets made of sub-rulesets */
.ruleset-parts { display: flex; flex-wrap: wrap; gap: .25rem .5rem; }
.ruleset-part { background: #f1f3f5; border-radius: .25rem; padding: .05rem .45rem; }
.ruleset-part.is-none { color: #6c757d; background: transparent; border: 1px dashed #ced4da; }
.run-steps li { padding: .1rem 0; }
.run-steps li.is-off { color: #6c757d; }

/* ---- dashboard and visual pass (Phase 5) ---- */
:root {
	--dr-accent: #257de0;        /* the one data hue: blue, validated against the white surface */
	--dr-accent-track: #d7e6f8;  /* a lighter step of the same blue, for meter tracks */
	--dr-border: #e3e7ec;
	--dr-radius: .6rem;
}
h1.h3, .h3 { letter-spacing: -.01em; }
.card { border-color: var(--dr-border); border-radius: var(--dr-radius); }
.card-title.h6 { font-weight: 600; margin-bottom: .75rem; }
.stat { border-color: var(--dr-border); border-radius: var(--dr-radius); }
.stat-label { text-transform: none; font-size: .8rem; }
.stat-value { font-size: 1.75rem; }

.meter { height: 8px; background: var(--dr-accent-track); border-radius: 4px; overflow: hidden; min-width: 4rem; }
.meter-fill { height: 100%; background: var(--dr-accent); border-radius: 4px; min-width: 2px; }
.meter-list th, .meter-list td { border: 0; padding: .2rem .4rem; vertical-align: middle; }
.meter-list th { white-space: nowrap; }
.meter-list tr:hover { background: #f6f8fb; }

.dash-search { min-width: min(28rem, 100%); }
.dash-action { text-decoration: none; color: inherit; transition: border-color .15s, box-shadow .15s; }
.dash-action:hover, .dash-action:focus-visible { border-color: var(--ca-accent, #e94560); box-shadow: 0 2px 8px rgba(233, 69, 96, .12); }
.dash-action-icon { color: var(--ca-accent, #e94560); margin-top: .2rem; }

.activity li { padding: .35rem 0; font-size: .92rem; border-bottom: 1px solid #f1f3f5; display: flex; flex-wrap: wrap; align-items: baseline; gap: .35rem; }
.activity li:last-child { border-bottom: 0; }
.activity-meta { margin-left: auto; white-space: nowrap; }
.activity a { text-decoration: none; }
.activity a:hover { text-decoration: underline; }
.meter-list a { text-decoration: none; }
.review-list li { padding: .2rem 0; }

/* empty states and tables across the app */
.alert-secondary { background: #f6f8fb; border-color: var(--dr-border); color: #495057; }
.table > :not(caption) > * > th { font-weight: 600; }
.table thead th { font-size: .82rem; color: #495057; border-bottom-width: 1px; }
.list-group-item { border-color: var(--dr-border); }
.list-group { border-radius: var(--dr-radius); }
.breadcrumb { margin-bottom: .25rem; }
