/* The salary pages (salarii.php, P2 in docs/plan-salarii.md). Mobile first; the tables scroll inside their box. */

.sal-page { text-align: left; font-size: 17px; line-height: 1.6; color: #333; }
.sal-page h2 { margin: 30px 0 10px; font-size: 22px; line-height: 1.3; }
.sal-page h3 { margin: 0 0 6px; font-size: 16px; font-weight: 600; color: #444; }
.sal-h1-link { font-size: 15px; font-weight: 400; margin-left: 8px; white-space: nowrap; }
.sal-lead { margin: 0 0 6px; font-size: 21px; line-height: 1.4; color: #222; }
.sal-lead b { font-size: inherit; }
.sal-lead .sal-net { font-size: 19px; }
.sal-meta { margin: 0 0 10px; font-size: 16px; color: #444; }
.sal-source { margin: 0 0 8px; color: #666; font-size: 15px; }
.sal-note { margin: 6px 0 0; color: #666; font-size: 15px; }
.sal-tip { position: fixed; z-index: 1000; max-width: 300px; padding: 8px 11px; background: #111; color: #fff; font-size: 14px; line-height: 1.45; border-radius: 6px; box-shadow: 0 4px 16px rgba(0,0,0,.3); pointer-events: none; }
.sal-net { color: #15803d; font-weight: normal; white-space: nowrap; }
.sal-section { margin-top: 10px; }
.sal-cor { margin: 0 0 8px; color: #444; font-size: 16px; }
.sal-links { margin: 6px 0 0; line-height: 1.9; }
.sal-jobs-link { margin-left: 6px; font-size: 13px; white-space: nowrap; }
.sal-report p { margin: 8px 0; }
.sal-report .sal-table td.pos { color: #15803d; }
.sal-report .sal-table td.neg { color: #b91c1c; }
.sal-footer { margin: 28px 0 0; padding-top: 12px; border-top: 1px solid #eee; color: #777; font-size: 14px; }

/* tables */
.sal-table-wrap { overflow-x: auto; -webkit-overflow-scrolling: touch; margin: 6px 0 4px; }
.sal-table { width: 100%; border-collapse: collapse; font-size: 16px; }
.sal-table th, .sal-table td { padding: 7px 8px; border-bottom: 1px solid #eee; text-align: left; vertical-align: top; }
.sal-table th { font-size: 14px; color: #666; font-weight: 600; background: #f6f7f9; white-space: nowrap; }
.sal-table th.num, .sal-table td.num { text-align: right; white-space: nowrap; }
.sal-table td.num small { display: block; font-size: 12px; }
.sal-sortable th { cursor: pointer; user-select: none; }
.sal-sortable th.asc::after { content: " \25B2"; font-size: 10px; }
.sal-sortable th.desc::after { content: " \25BC"; font-size: 10px; }
.sal-details { margin: 6px 0 0; }
.sal-details summary { cursor: pointer; color: #0d51aa; font-size: 15px; }

/* the map */
.sal-map-box { margin: 8px 0 12px; }
.sal-map { display: block; width: 100%; height: auto; aspect-ratio: 1000 / 711; }
.sal-map path { stroke: #fff; stroke-width: 1.5; transition: fill .15s; }
.sal-map a:hover path, .sal-map a:focus path { fill: #f59e0b !important; }
.sal-map a { outline: none; }
.sal-map-label { font: 700 26px/1 Arial, sans-serif; fill: #111; paint-order: stroke; stroke: #fff; stroke-width: 5px; }
.sal-toggle { display: flex; gap: 6px; margin: 0 0 8px; }
.sal-toggle button { padding: 6px 12px; border: 1px solid #0d51aa; background: #fff; color: #0d51aa; border-radius: 4px; font-size: 14px; cursor: pointer; }
.sal-toggle button.on { background: #0d51aa; color: #fff; }
.sal-legend { display: flex; flex-wrap: wrap; gap: 6px 14px; margin: 6px 0 0; font-size: 14px; color: #555; }
.sal-legend[hidden] { display: none; }
.sal-legend i { display: inline-block; width: 14px; height: 14px; margin-right: 5px; vertical-align: -2px; border: 1px solid #ddd; }

/* charts: the SVG draws the geometry at a fixed height, the numbers sit in HTML under it */
.sal-chart { margin: 8px 0 0; }
.sal-bars { display: block; width: 100%; height: 150px; }
.sal-bars rect { fill: #0d51aa; }
.sal-bars rect.sal-bar-hit { fill: transparent; }
.sal-bar-labels { display: grid; gap: 4px; margin-top: 6px; font-size: 12px; line-height: 1.35; text-align: center; }
.sal-bars rect[data-tip] { cursor: default; }
.sal-bar-label { min-width: 0; overflow-wrap: anywhere; }
.sal-bar-label span { display: block; }
.sal-bar-label .sal-net { white-space: normal; }
.sal-bar-n { font-weight: 700; font-size: 14px; color: #111; }
.sal-bar-band { color: #333; }
.sal-series { display: grid; gap: 18px; margin-top: 8px; }
.sal-series-chart { min-width: 0; }
.sal-line { display: block; width: 100%; height: 120px; background: #f6f7f9; border-radius: 4px; }
.sal-series-ends, .sal-series-range { display: flex; justify-content: space-between; margin: 0; font-size: 13px; color: #555; }
.sal-series-ends { margin-bottom: 4px; }
.sal-series-range { margin-top: 4px; color: #888; }

/* the county page's jobs */
/* the job list spans the white box edge to edge, like the lists elsewhere: cancel the box's side padding */
.sal-jobs .container_list_jobs { margin: 8px -30px 0; box-shadow: none; border-top: 1px solid #e0e0e0; }
.sal-jobs .al-box { margin-left: -30px; margin-right: -30px; }
@media (max-width: 990px) {
	.sal-jobs .container_list_jobs, .sal-jobs .al-box { margin-left: -20px; margin-right: -20px; }
}
.sal-all-jobs { margin: 12px 0 0; font-size: 16px; }

@media (max-width: 699px) {
	.sal-table th, .sal-table td { padding: 6px 5px; }
}
@media (min-width: 700px) {
	.sal-page h2 { font-size: 24px; }
	.sal-lead { font-size: 23px; }
	.sal-series { grid-template-columns: 1fr 1fr; }
	.sal-bar-labels { font-size: 14px; }
}
