/* Tuno Vaalitieto – julkinen tulospalvelu. Kaikki säännöt rajattu .tunovt-app-elementtiin, jotta teema ja muut lisäosat eivät vaikuta eikä tämä vaikuta niihin. */
.tunovt-app {
	--tv-text: #1d2327;
	--tv-muted: #5c6670;
	--tv-line: #dcdfe3;
	--tv-bg: #ffffff;
	--tv-soft: #f4f6f8;
	--tv-accent: #1f5fa8;
	--tv-up: #0a7a3d;
	--tv-down: #b3261e;
	color: var(--tv-text);
	background: var(--tv-bg);
	font-size: 16px;
	line-height: 1.5;
	max-width: 1100px;
	margin: 1.5em 0;
	box-sizing: border-box;
}
.tunovt-app *, .tunovt-app *::before, .tunovt-app *::after { box-sizing: inherit; }
.tunovt-app a { color: var(--tv-accent); text-decoration: none; }
.tunovt-app a:hover, .tunovt-app a:focus { text-decoration: underline; }
.tunovt-app a:focus-visible, .tunovt-app button:focus-visible, .tunovt-app select:focus-visible, .tunovt-app input:focus-visible { outline: 2px solid var(--tv-accent); outline-offset: 2px; }
.tunovt-app .tunovt-h { font-size: 1.5em; line-height: 1.25; margin: 0.6em 0 0.5em; font-weight: 700; }
.tunovt-app .tunovt-h3 { font-size: 1.15em; margin: 1.6em 0 0.5em; font-weight: 700; }
.tunovt-app .tunovt-h4 { font-size: 1em; margin: 1.2em 0 0.4em; font-weight: 700; }
.tunovt-app .tunovt-nowrap { white-space: nowrap; }
.tunovt-app .tunovt-intro { color: var(--tv-muted); margin: 0 0 1em; }
.tunovt-app .tunovt-note { color: var(--tv-muted); font-size: 0.875em; margin: 0.6em 0; padding: 0.5em 0.75em; background: var(--tv-soft); border-left: 3px solid var(--tv-line); }
.tunovt-app .tunovt-source { color: var(--tv-muted); font-size: 0.8em; margin: 1.2em 0 0; }
.tunovt-app .tunovt-sub { display: block; color: var(--tv-muted); font-size: 0.8em; font-weight: 400; }
.tunovt-app .tunovt-count { color: var(--tv-muted); margin: 0.5em 0; }
.tunovt-app .tunovt-more { display: block; float: none; position: static; margin: 0.8em 0 1.5em; }
.tunovt-app .tunovt-legend-note { color: var(--tv-muted); font-size: 0.8em; margin: -0.5em 0 0.8em; }
.tunovt-app .tunovt-table-wrap + .tunovt-legend-note { margin-top: 0.6em; }
/* Painikkeen ja selitteen väliin yhden rivin väli. */
.tunovt-app .tunovt-more + .tunovt-legend-note { clear: both; margin-top: 1.5em; }
.tunovt-app .tunovt-polls-table td.tunovt-pollster { white-space: nowrap; }
.tunovt-app .tunovt-card { min-width: 0; }
.tunovt-app .tunovt-card-value { white-space: nowrap; font-size: 1.35em; }

/* Välilehdet */
.tunovt-app .tunovt-tabs { display: flex; flex-wrap: wrap; gap: 4px; border-bottom: 2px solid var(--tv-line); margin-bottom: 1em; }
.tunovt-app .tunovt-tab { padding: 0.55em 1em; border-radius: 6px 6px 0 0; color: var(--tv-text); font-weight: 600; margin-bottom: -2px; border-bottom: 2px solid transparent; }
.tunovt-app .tunovt-tab:hover { background: var(--tv-soft); text-decoration: none; }
.tunovt-app .tunovt-tab.is-active { border-bottom-color: var(--tv-accent); color: var(--tv-accent); }

/* Lomake */
.tunovt-app .tunovt-form { display: flex; flex-wrap: wrap; gap: 0.75em; align-items: flex-end; margin: 0 0 1em; }
.tunovt-app .tunovt-field { display: flex; flex-direction: column; gap: 2px; font-size: 0.85em; color: var(--tv-muted); position: relative; }
.tunovt-app .tunovt-field-wide { flex: 1 1 240px; }
.tunovt-app .tunovt-field select, .tunovt-app .tunovt-field input {
	font: inherit; font-size: 1rem; color: var(--tv-text); background: #fff;
	border: 1px solid #b8bec5; border-radius: 6px; padding: 0.45em 0.6em; min-height: 40px; max-width: 100%;
}
.tunovt-app .tunovt-btn { font: inherit; font-size: 0.95rem; display: inline-block; background: #fff; color: var(--tv-accent); border: 1px solid var(--tv-accent); border-radius: 6px; padding: 0.45em 0.9em; cursor: pointer; min-height: 40px; }
.tunovt-app .tunovt-btn:hover { background: var(--tv-soft); text-decoration: none; }
.tunovt-js .tunovt-app .tunovt-js-hide { display: none; }
.tunovt-app .tunovt-suggest { position: absolute; top: 100%; left: 0; right: 0; z-index: 50; background: #fff; border: 1px solid var(--tv-line); border-radius: 6px; box-shadow: 0 6px 18px rgba(0,0,0,.12); display: none; }
.tunovt-app .tunovt-suggest.is-open { display: block; }
.tunovt-app .tunovt-suggest a { display: block; padding: 0.5em 0.75em; color: var(--tv-text); font-size: 1rem; }
.tunovt-app .tunovt-suggest a span { color: var(--tv-muted); font-size: 0.85em; margin-left: 0.4em; }
.tunovt-app .tunovt-suggest a:hover, .tunovt-app .tunovt-suggest a.is-active { background: var(--tv-soft); text-decoration: none; }

/* Kortit */
.tunovt-app .tunovt-cards { display: grid; grid-template-columns: repeat(auto-fit, minmax(135px, 1fr)); gap: 0.6em; margin: 0 0 1.2em; }
.tunovt-app .tunovt-card { border: 1px solid var(--tv-line); border-radius: 8px; padding: 0.75em 1em; display: flex; flex-direction: column; }
.tunovt-app .tunovt-card-label { color: var(--tv-muted); font-size: 0.85em; }
.tunovt-app .tunovt-card-value { font-size: 1.6em; font-weight: 700; font-variant-numeric: tabular-nums; line-height: 1.2; }
.tunovt-app .tunovt-card-sub { color: var(--tv-muted); font-size: 0.75em; }

/* Taulukot */
.tunovt-app .tunovt-table-wrap { overflow-x: auto; -webkit-overflow-scrolling: touch; margin: 0 0 1em; border: 1px solid var(--tv-line); border-radius: 8px; }
.tunovt-app .tunovt-tall { max-height: 560px; overflow-y: auto; }
.tunovt-app .tunovt-table { width: 100%; border-collapse: collapse; font-size: 0.92em; margin: 0; background: #fff; }
.tunovt-app .tunovt-table caption { text-align: left; font-weight: 700; padding: 0.6em 0.75em; caption-side: top; color: var(--tv-text); background: transparent; }
.tunovt-app .tunovt-table th, .tunovt-app .tunovt-table td { padding: 0.45em 0.75em; border-top: 1px solid var(--tv-line); text-align: left; vertical-align: top; }
.tunovt-app .tunovt-table thead th { background: var(--tv-soft); font-size: 0.85em; color: var(--tv-muted); font-weight: 600; white-space: nowrap; position: sticky; top: 0; }
.tunovt-app .tunovt-table tbody th { font-weight: 600; white-space: nowrap; }
.tunovt-app .tunovt-table .num { text-align: right; font-variant-numeric: tabular-nums; white-space: nowrap; }
.tunovt-app .tunovt-sortable thead th { cursor: pointer; user-select: none; }
.tunovt-app .tunovt-sortable thead th[aria-sort="ascending"]::after { content: " ▲"; font-size: 0.75em; }
.tunovt-app .tunovt-sortable thead th[aria-sort="descending"]::after { content: " ▼"; font-size: 0.75em; }
.tunovt-app .tunovt-up { color: var(--tv-up); }
.tunovt-app .tunovt-down { color: var(--tv-down); }
.tunovt-app .tunovt-same, .tunovt-app .tunovt-na { color: var(--tv-muted); }
.tunovt-app .tunovt-outcome { font-size: 0.85em; padding: 1px 8px; border-radius: 10px; background: var(--tv-soft); white-space: nowrap; }
.tunovt-app .tunovt-o-valittu { background: #dcefe3; color: #0b5a2e; }
.tunovt-app .tunovt-o-varalla { background: #fff1cc; color: #6b4e00; }

/* Kuviot */
.tunovt-app .tunovt-grid2 { display: grid; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); gap: 1.5em; margin: 0 0 1em; }
.tunovt-app .tunovt-chart { margin: 0 0 1em; }
.tunovt-app .tunovt-chart figcaption { font-weight: 700; font-size: 0.95em; margin-bottom: 0.5em; }
.tunovt-app .tunovt-bar-row { display: grid; grid-template-columns: 6.5em 1fr 4.5em; align-items: center; gap: 0.5em; margin: 3px 0; font-size: 0.88em; }
.tunovt-app .tunovt-bar-label { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.tunovt-app .tunovt-bar-track { background: var(--tv-soft); border-radius: 3px; height: 14px; overflow: hidden; }
.tunovt-app .tunovt-bar { display: block; height: 100%; background: var(--tv-accent); border-radius: 3px; }
.tunovt-app .tunovt-bar-value { text-align: right; font-variant-numeric: tabular-nums; }
.tunovt-app .tunovt-seat-track { display: flex; height: 34px; border-radius: 6px; overflow: hidden; border: 1px solid var(--tv-line); }
.tunovt-app .tunovt-seat { display: flex; align-items: center; justify-content: center; color: #fff; font-size: 0.72em; font-weight: 600; overflow: hidden; white-space: nowrap; border-right: 1px solid #fff; }
.tunovt-app .tunovt-legend { list-style: none; margin: 0.5em 0 0; padding: 0; display: flex; flex-wrap: wrap; gap: 0.3em 1em; font-size: 0.85em; }
.tunovt-app .tunovt-dot { display: inline-block; width: 10px; height: 10px; border-radius: 2px; margin-right: 6px; vertical-align: baseline; box-shadow: inset 0 0 0 1px rgba(0,0,0,.15); }
.tunovt-app .tunovt-h .tunovt-dot { width: 14px; height: 14px; }
.tunovt-app .tunovt-bar { box-shadow: inset 0 0 0 1px rgba(0,0,0,.12); }
.tunovt-app .tunovt-c0 { background: #1f5fa8; } .tunovt-app .tunovt-c1 { background: #c2410c; } .tunovt-app .tunovt-c2 { background: #0f766e; }
.tunovt-app .tunovt-c3 { background: #7c3aed; } .tunovt-app .tunovt-c4 { background: #a16207; } .tunovt-app .tunovt-c5 { background: #be185d; }
.tunovt-app .tunovt-c6 { background: #4d7c0f; } .tunovt-app .tunovt-c7 { background: #475569; } .tunovt-app .tunovt-c8 { background: #0369a1; } .tunovt-app .tunovt-c9 { background: #9f1239; }
.tunovt-app .tunovt-linechart svg { width: 100%; height: auto; max-height: 300px; display: block; }
.tunovt-app .tunovt-linechart .tunovt-grid { stroke: var(--tv-line); stroke-width: 1; }
.tunovt-app .tunovt-linechart .tunovt-axis { fill: var(--tv-muted); font-size: 11px; }
.tunovt-app .tunovt-linechart .tunovt-line { fill: none; stroke: var(--tv-accent); stroke-width: 2.5; }
.tunovt-app .tunovt-linechart .tunovt-point { fill: var(--tv-accent); }

/* Puolueet ja muut */
.tunovt-app .tunovt-party-list { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 0.6em; }
.tunovt-app .tunovt-party-list li { border: 1px solid var(--tv-line); border-radius: 8px; padding: 0.6em 0.8em; }
.tunovt-app .tunovt-party-chip { font-weight: 700; font-size: 1.05em; }
.tunovt-app .tunovt-details { margin: 0.8em 0; }
.tunovt-app .tunovt-details summary { cursor: pointer; color: var(--tv-accent); font-weight: 600; }
.tunovt-app .tunovt-pager { display: flex; gap: 0.75em; align-items: center; margin: 0.8em 0; }
.tunovt-app .tunovt-back { margin: 0; }
.tunovt-app .tunovt-yearlinks { margin: 0 0 0.5em; }
.tunovt-app.is-loading .tunovt-view, .tunovt-app.is-loading > *:not(.tunovt-tabs) { opacity: 0.55; transition: opacity .15s; }

/* Hallitusvaihtoehdot */
.tunovt-app .tunovt-coal-group { border: 1px solid var(--tv-line); border-radius: 8px; margin: 0 0 0.6em; background: var(--tv-bg); }
.tunovt-app .tunovt-coal-group > summary { cursor: pointer; padding: 0.6em 0.9em; font-weight: 700; display: flex; justify-content: space-between; align-items: baseline; gap: 1em; list-style: none; }
.tunovt-app .tunovt-coal-group > summary::-webkit-details-marker { display: none; }
.tunovt-app .tunovt-coal-group > summary::before { content: "\25B8"; color: var(--tv-muted); margin-right: 0.4em; }
.tunovt-app .tunovt-coal-group[open] > summary::before { content: "\25BE"; }
.tunovt-app .tunovt-coal-group > summary > span:first-child { flex: 1; }
.tunovt-app .tunovt-coal-group > summary .tunovt-sub { display: inline; white-space: nowrap; }
.tunovt-app .tunovt-coal-group[open] > summary { border-bottom: 1px solid var(--tv-line); background: var(--tv-soft); border-radius: 8px 8px 0 0; }
.tunovt-app .tunovt-coal-list { list-style: none; margin: 0; padding: 0; }
.tunovt-app .tunovt-coal { display: grid; grid-template-columns: minmax(0, 3fr) minmax(110px, 1.3fr) 8.5em 6.5em; gap: 0.4em 0.9em; align-items: center; padding: 0.55em 0.9em; border-bottom: 1px solid var(--tv-line); }
.tunovt-app .tunovt-coal:last-child { border-bottom: 0; }
.tunovt-app .tunovt-coal-sub { padding: 0.45em 0.9em 0.3em; font-size: 0.8em; font-weight: 700; text-transform: uppercase; letter-spacing: .04em; color: var(--tv-muted); background: var(--tv-soft); border-bottom: 1px solid var(--tv-line); }
.tunovt-app > .tunovt-coal-list, .tunovt-app .tunovt-view > .tunovt-coal-list { border: 1px solid var(--tv-line); border-radius: 8px; }
.tunovt-app .tunovt-coal-chips { display: flex; flex-wrap: wrap; gap: 4px; }
.tunovt-app .tunovt-chip { display: inline-block; padding: 0.15em 0.55em; border-radius: 999px; font-size: 0.85em; font-weight: 600; white-space: nowrap; box-shadow: inset 0 0 0 1px rgba(0,0,0,.12); }
.tunovt-app .tunovt-chip b { font-weight: 400; opacity: 0.85; }
.tunovt-app .tunovt-coal-bar { position: relative; display: flex; height: 14px; background: var(--tv-soft); border-radius: 3px; overflow: visible; }
.tunovt-app .tunovt-coal-bar span { display: block; height: 100%; border-right: 1px solid #fff; }
.tunovt-app .tunovt-coal-bar span:first-child { border-radius: 3px 0 0 3px; }
.tunovt-app .tunovt-coal-bar i { position: absolute; top: -4px; bottom: -4px; width: 2px; margin-left: -1px; background: var(--tv-text); }
.tunovt-app .tunovt-coal-num { font-variant-numeric: tabular-nums; font-size: 0.9em; line-height: 1.3; }
.tunovt-app .tunovt-coal-num strong { font-size: 1.15em; }
.tunovt-app .tunovt-coal-badges { display: flex; flex-wrap: wrap; gap: 4px; justify-content: flex-end; }

/* Gallup */
.tunovt-app .tunovt-checks { border: 0; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: 0.35em 0.6em; align-items: center; min-width: 0; }
.tunovt-app .tunovt-checks legend { font-size: 0.85em; color: var(--tv-muted); padding: 0; margin-bottom: 0.25em; width: 100%; }
.tunovt-app .tunovt-check { display: inline-flex; align-items: center; gap: 0.35em; font-size: 0.92em; cursor: pointer; min-height: 32px; }
.tunovt-app .tunovt-party-checks { flex-basis: 100%; }
.tunovt-app .tunovt-chipcheck { border: 2px solid var(--tv-c); border-radius: 999px; padding: 0.1em 0.7em 0.1em 0.45em; background: #fff; color: var(--tv-text); font-weight: 600; }
.tunovt-app .tunovt-chipcheck.is-on, .tunovt-app .tunovt-chipcheck:has(input:checked) { background: var(--tv-c); color: var(--tv-t); }
.tunovt-app .tunovt-chipcheck input { accent-color: var(--tv-c); margin: 0; }
.tunovt-app .tunovt-dash { width: 28px; height: 10px; vertical-align: middle; margin-right: 4px; flex: none; }
.tunovt-app .tunovt-gchart-wrap { position: relative; }
.tunovt-app .tunovt-gchart-wrap > svg { width: 100%; height: auto; display: block; touch-action: pan-y; }
.tunovt-app .tunovt-gallup td:first-child, .tunovt-app.tunovt-gallup td:first-child { white-space: nowrap; }
.tunovt-app .tunovt-gchart .tunovt-grid { stroke: var(--tv-line); stroke-width: 1; }
.tunovt-app .tunovt-gchart .tunovt-tick { stroke: var(--tv-muted); stroke-width: 1; }
.tunovt-app .tunovt-gchart .tunovt-axis { fill: var(--tv-muted); font-size: 12px; }
.tunovt-app .tunovt-gline { fill: none; stroke-width: 2.4; stroke-linejoin: round; stroke-linecap: round; }
.tunovt-app .tunovt-gtrend { stroke-width: 3; opacity: .6; stroke-linecap: butt; }
.tunovt-app .tunovt-band { fill: #eef3f9; }
.tunovt-app .tunovt-band.is-alt { fill: #f7f9fb; }
.tunovt-app .tunovt-band-label { fill: var(--tv-muted); font-size: 11px; }
.tunovt-app .tunovt-vline { stroke: #8a939c; stroke-width: 1; stroke-dasharray: 3 3; }
.tunovt-app .tunovt-marker { fill: #fff; stroke-width: 2; }
.tunovt-app .tunovt-cross { stroke: var(--tv-text); stroke-width: 1; opacity: 0.5; pointer-events: none; }
.tunovt-app .tunovt-tip { position: absolute; top: 8px; z-index: 5; background: rgba(255,255,255,.97); border: 1px solid var(--tv-line); border-radius: 6px; box-shadow: 0 2px 10px rgba(0,0,0,.12); padding: 0.4em 0.6em; font-size: 0.8em; line-height: 1.45; pointer-events: none; white-space: nowrap; }
.tunovt-app .tunovt-tip strong { display: block; margin-bottom: 2px; }
.tunovt-app .tunovt-gallup .tunovt-legend li, .tunovt-app.tunovt-gallup .tunovt-legend li { display: inline-flex; align-items: center; }

.tunovt-app .tunovt-daterange { display: inline-flex; flex-wrap: wrap; gap: 0.5em 0.75em; align-items: flex-end; }
.tunovt-app .tunovt-daterange input[type="date"] { font: inherit; font-size: 1rem; padding: 0.4em 0.5em; border: 1px solid var(--tv-line); border-radius: 6px; min-height: 40px; background: #fff; color: var(--tv-text); }

.tunovt-app .tunovt-polls-table .tunovt-period-row th, .tunovt-app .tunovt-polls-table .tunovt-period-row td { background: #eef3f9; font-weight: 600; border-bottom: 2px solid var(--tv-line); }
.tunovt-app .tunovt-polls-table th[scope="row"] { white-space: nowrap; font-weight: 400; }
.tunovt-app .tunovt-polls-table .tunovt-period-row th[scope="row"] { white-space: normal; font-weight: 600; min-width: 11em; }
.tunovt-app .tunovt-polls-table td .tunovt-sub { font-size: 0.78em; }

.tunovt-app .tunovt-poll-more { margin-top: 4px; font-size: 0.85em; white-space: normal; }
.tunovt-app .tunovt-poll-more summary { cursor: pointer; display: inline-block; margin-top: 3px; padding: 2px 9px; border-radius: 999px; background: #e8f0fb; color: var(--tv-accent); font-weight: 600; list-style: none; }
.tunovt-app .tunovt-poll-more summary::-webkit-details-marker { display: none; }
.tunovt-app .tunovt-poll-more[open] summary { background: var(--tv-accent); color: #fff; }
.tunovt-app .tunovt-polls-table tr.tunovt-has-info th[scope="row"] { border-left: 3px solid var(--tv-accent); }
.tunovt-app .tunovt-polls-table tr.is-target th, .tunovt-app .tunovt-polls-table tr.is-target td { background: #fff8e5; }
.tunovt-app .tunovt-info-note { margin: 0.4em 0; padding: 0.45em 0.75em; background: #e8f0fb; border-left: 3px solid var(--tv-accent); font-size: 0.9em; }
.tunovt-app .tunovt-poll-more-body { min-width: 16em; max-width: 34em; padding: 0.4em 0 0.2em; }
.tunovt-app .tunovt-poll-more-body p { margin: 0 0 0.5em; }
.tunovt-app .tunovt-poll-files { margin: 0.3em 0 0 1.2em; padding: 0; }

.tunovt-app .tunovt-sum-row td { font-weight: 700; background: #f1f3f5; border-top: 2px solid var(--tv-line); }
.tunovt-app .tunovt-gallup .tunovt-sum-row td:first-child, .tunovt-app.tunovt-gallup .tunovt-sum-row td:first-child { white-space: normal; min-width: 9em; }

.tunovt-app .tunovt-manual-note { border-left-color: #dba617; background: #fff8e5; color: #4a3b00; }
.tunovt-app .tunovt-own-result { border: 1px solid var(--tv-line); border-radius: 8px; padding: 0.4em 0.9em 0.2em; margin: 0.5em 0 1em; }
.tunovt-app .tunovt-own-result.is-majority { border-left: 4px solid var(--tv-up); }
.tunovt-app .tunovt-own-result.is-minority { border-left: 4px solid var(--tv-down); }
.tunovt-app .tunovt-own-result .tunovt-coal { border-bottom: 0; padding-left: 0; padding-right: 0; }

@media (max-width: 600px) {
	.tunovt-app .tunovt-daterange { display: flex; }
	.tunovt-app .tunovt-daterange .tunovt-field { flex: 1 1 140px; }
	.tunovt-app .tunovt-daterange input[type="date"] { width: 100%; }
	.tunovt-app .tunovt-gchart-wrap { overflow-x: auto; -webkit-overflow-scrolling: touch; }
	.tunovt-app .tunovt-gchart-wrap > svg { min-width: 620px; }
	.tunovt-app .tunovt-checks { gap: 0.3em 0.45em; }
	.tunovt-app .tunovt-tip { font-size: 0.75em; }
	.tunovt-app .tunovt-coal { grid-template-columns: 1fr auto; }
	.tunovt-app .tunovt-coal-chips, .tunovt-app .tunovt-coal-bar { grid-column: 1 / -1; }
	.tunovt-app .tunovt-coal-badges { justify-content: flex-end; }
	.tunovt-app { font-size: 15px; }
	.tunovt-app .tunovt-form { flex-direction: column; align-items: stretch; }
	.tunovt-app .tunovt-field select, .tunovt-app .tunovt-field input { width: 100%; }
	.tunovt-app .tunovt-tab { padding: 0.5em 0.7em; font-size: 0.9em; }
	.tunovt-app .tunovt-card-value { font-size: 1.35em; }
	.tunovt-app .tunovt-bar-row { grid-template-columns: 5em 1fr 4em; }
}

/* Paikka-arvio [tunovt_paikka_arvio] */
.tunovt-app .tunovt-pa-key { border-left: 4px solid var(--tv-accent); background: #f6f8fa; padding: 0.7em 1em; margin: 0 0 1em; border-radius: 0 6px 6px 0; }
.tunovt-app .tunovt-pa-key p { margin: 0 0 0.3em; }
.tunovt-app .tunovt-pa-key .tunovt-pa-sub { margin: 0; color: var(--tv-muted); font-size: 0.9em; }
.tunovt-app .tunovt-pa-form { display: flex; flex-wrap: wrap; gap: 0.6em 1em; align-items: flex-end; }
.tunovt-app .tunovt-pa-adjust { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 0.5em 1em; }
.tunovt-app .tunovt-pa-adj input { width: 5.5em; }
.tunovt-app .tunovt-pa-method li { margin-bottom: 0.4em; }
/* Teksti- ja lause-näkymä: tekstin osa. Yksinään kappaleessa WordPress poistaa <p>-tagin, joten näytetään kappaleena. */
div > .tunovt-pa-inline { display: block; margin: 0 0 1em; }
.tunovt-app .tunovt-pa-now td { font-weight: 700; background: #eef4fb; }
.tunovt-app .tunovt-select-search input { min-width: 12em; }

/* Tietosuojaseloste [tunovt_tietosuoja] */
.tunovt-app.tunovt-privacy { max-width: 820px; }
.tunovt-app.tunovt-privacy h3 { margin: 1.4em 0 0.4em; font-size: 1.1em; }
.tunovt-app.tunovt-privacy li { margin-bottom: 0.3em; }

/* Gallupien vertailu: tuoreimmat mittaukset rinnakkain */
.tunovt-app .tunovt-cmp { margin: 1em 0 1.5em; }
.tunovt-app .tunovt-cmp figcaption { font-weight: 600; margin-bottom: 0.4em; }
.tunovt-app .tunovt-cmp-legend { list-style: none; margin: 0 0 0.8em; padding: 0; display: flex; flex-wrap: wrap; gap: 0.4em 1.2em; font-size: 0.9em; }
.tunovt-app .tunovt-cmp-key { display: inline-block; width: 26px; height: 12px; border-radius: 2px; margin-right: 0.4em; vertical-align: -1px; }
.tunovt-app .tunovt-cmp-row { display: grid; grid-template-columns: 8.5em 1fr; gap: 0.6em; align-items: center; padding: 0.35em 0; border-bottom: 1px solid var(--tv-line); }
.tunovt-app .tunovt-cmp-party { font-weight: 600; font-size: 0.95em; }
.tunovt-app .tunovt-cmp-line { display: grid; grid-template-columns: 6.5em 1fr; gap: 0.4em; align-items: center; margin: 2px 0; }
.tunovt-app .tunovt-cmp-ps { font-size: 0.8em; color: var(--tv-muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.tunovt-app .tunovt-cmp-track { display: flex; align-items: center; gap: 0.4em; min-width: 0; }
.tunovt-app .tunovt-cmp-bar { display: block; height: 16px; border-radius: 2px; min-width: 2px; }
.tunovt-app .tunovt-cmp-val { font-size: 0.85em; font-variant-numeric: tabular-nums; white-space: nowrap; }
@media (max-width: 560px) {
	.tunovt-app .tunovt-cmp-row { grid-template-columns: 1fr; gap: 0.2em; }
	.tunovt-app .tunovt-cmp-line { grid-template-columns: 4.5em 1fr; }
}

/* Ennuste 2: väli ja keskiarvo janalla. */
.tunovt-app .tunovt-p2-chart { margin: 1em 0 1.5em; }
.tunovt-app .tunovt-p2-chart figcaption { font-weight: 600; margin-bottom: 0.4em; }
.tunovt-app .tunovt-p2-row, .tunovt-app .tunovt-p2-axis { display: grid; grid-template-columns: 7em 1fr; gap: 0.6em; align-items: center; }
.tunovt-app .tunovt-p2-row { padding: 0.3em 0; border-bottom: 1px solid var(--tv-line); }
.tunovt-app .tunovt-p2-track { position: relative; height: 22px; margin-right: 6.5em; }
.tunovt-app .tunovt-p2-band { position: absolute; top: 5px; height: 12px; border-radius: 6px; opacity: 0.45; }
.tunovt-app .tunovt-p2-dot { position: absolute; top: 2px; width: 18px; height: 18px; margin-left: -9px; border-radius: 50%; background: #fff; border: 4px solid; box-sizing: border-box; }
.tunovt-app .tunovt-p2-prev { position: absolute; top: 0; height: 22px; width: 2px; margin-left: -1px; background: var(--tv-text); opacity: 0.55; }
.tunovt-app .tunovt-p2-val { position: absolute; top: 2px; margin-left: 0.5em; font-size: 0.85em; white-space: nowrap; font-variant-numeric: tabular-nums; }
.tunovt-app .tunovt-p2-axis > span:last-child { position: relative; height: 1.4em; margin-right: 6.5em; font-size: 0.75em; color: var(--tv-muted); }
.tunovt-app .tunovt-p2-axis i { position: absolute; font-style: normal; white-space: nowrap; transform: translateX(-50%); }
.tunovt-app .tunovt-p2-key-band, .tunovt-app .tunovt-p2-key-dot, .tunovt-app .tunovt-p2-key-prev { display: inline-block; vertical-align: -2px; margin-right: 0.4em; }
.tunovt-app .tunovt-p2-key-band { width: 26px; height: 10px; border-radius: 5px; background: var(--tv-muted); opacity: 0.45; }
.tunovt-app .tunovt-p2-key-dot { width: 12px; height: 12px; border-radius: 50%; border: 3px solid var(--tv-text); box-sizing: border-box; }
.tunovt-app .tunovt-p2-key-prev { width: 2px; height: 14px; background: var(--tv-text); opacity: 0.55; }
@media (max-width: 560px) {
	.tunovt-app .tunovt-p2-row, .tunovt-app .tunovt-p2-axis { grid-template-columns: 3.6em 1fr; gap: 0.4em; }
}

/* Tallennetut ennusteet: paikkojen kehitys. */
.tunovt-app .tunovt-fe-chart { margin: 1em 0 1.5em; }
.tunovt-app .tunovt-fe-chart figcaption { font-weight: 600; margin-bottom: 0.4em; }
.tunovt-app .tunovt-fe-svg { width: 100%; height: auto; display: block; }

/* Gallup: historiatilastot. */
.tunovt-app .tunovt-p2-cols { display: grid; grid-template-columns: 1fr 1fr; gap: 1em; }
.tunovt-app .tunovt-corr td { min-width: 3.2em; }
@media (max-width: 700px) {
	.tunovt-app .tunovt-p2-cols { grid-template-columns: 1fr; }
}
.tunovt-app .tunovt-subtabs { margin-top: 0.4em; font-size: 0.92em; }
.tunovt-app .tunovt-near { margin: 0.4em 0 0; padding-left: 1.2em; font-weight: 400; }
.tunovt-app .tunovt-copy { display: flex; flex-wrap: wrap; gap: 0.5em; align-items: center; margin: 0.6em 0 0.8em; }
.tunovt-app .tunovt-copy .tunovt-btn.is-done { background: var(--tv-soft); }
.tunovt-app .tunovt-copy-url { flex: 1 1 18em; min-width: 0; font: inherit; font-size: 0.85em; padding: 0.4em 0.5em; }
