/* LCR Vuokra-auto vs. kilometrikorvaus
 * Värit voi vaihtaa alla olevista muuttujista. */
.lcr-calc {
	--lcr-accent: #D32D2D;
	--lcr-accent-dark: #b02424;
	--lcr-accent-soft: #fdf1f1;
	--lcr-good: #1e8e4e;
	--lcr-good-dark: #17703d;
	--lcr-good-soft: #ecf8f0;
	--lcr-text: #1b1f24;
	--lcr-muted: #6b7280;
	--lcr-border: #e3e5e8;
	--lcr-bg: #ffffff;
	/* Fontti: Elementorin ensisijainen fontti (Roboto), varalla Roboto */
	--lcr-font: var(--e-global-typography-primary-font-family, "Roboto"), "Roboto", Arial, sans-serif;
	--lcr-strong: var(--e-global-typography-primary-font-weight, 600);

	box-sizing: border-box;
	max-width: 640px;
	margin: 0 auto;
	padding: 18px 20px;
	background: var(--lcr-bg);
	color: var(--lcr-text);
	border: 1px solid var(--lcr-border);
	border-top: 4px solid var(--lcr-accent);
	border-radius: 12px;
	font-family: var(--lcr-font);
	font-size: 15px;
	line-height: 1.4;
}
.lcr-calc *, .lcr-calc *::before, .lcr-calc *::after { box-sizing: border-box; }

.lcr-calc .lcr-title { font-family: var(--lcr-font); font-weight: var(--lcr-strong); margin: 0 0 2px; font-size: 1.2rem; line-height: 1.25; color: var(--lcr-text); }
.lcr-calc .lcr-sub { margin: 0 0 14px; color: var(--lcr-muted); font-size: 0.85rem; }

/* Lomake */
.lcr-calc .lcr-form { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin-bottom: 14px; align-items: end; }
.lcr-calc .lcr-field-class { grid-column: 1 / -1; }
.lcr-calc .lcr-field { display: flex; flex-direction: column; gap: 4px; margin: 0; min-width: 0; }
.lcr-calc .lcr-label { font-size: 0.78rem; font-weight: var(--lcr-strong); color: var(--lcr-muted); }
.lcr-calc .lcr-input {
	width: 100%; height: 40px; padding: 6px 10px; margin: 0;
	font-family: var(--lcr-font); font-weight: 400; font-size: 0.95rem; color: var(--lcr-text);
	background: #fff; border: 1px solid var(--lcr-border); border-radius: 8px;
	box-shadow: none; outline: none;
}
.lcr-calc .lcr-input:focus { border-color: var(--lcr-accent); box-shadow: 0 0 0 3px rgba(211, 45, 45, 0.15); }

/* Tulokset */
.lcr-calc .lcr-results { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.lcr-calc .lcr-card {
	padding: 12px 14px; border: 1.5px solid var(--lcr-border); border-radius: 10px;
	transition: border-color .2s, background-color .2s;
}
.lcr-calc .lcr-card.is-best { border-color: var(--lcr-good); background: var(--lcr-good-soft); }
.lcr-calc .lcr-card-head { display: flex; justify-content: space-between; align-items: center; gap: 6px; }
.lcr-calc .lcr-card-title { font-weight: var(--lcr-strong); font-size: 0.9rem; }
.lcr-calc .lcr-badge {
	font-size: 0.68rem; font-weight: var(--lcr-strong); color: #fff; background: var(--lcr-good);
	padding: 2px 8px; border-radius: 999px; white-space: nowrap;
}
.lcr-calc .lcr-badge[hidden] { display: none; }
.lcr-calc .lcr-total { font-size: 1.5rem; font-weight: var(--lcr-strong); margin: 2px 0 6px; font-variant-numeric: tabular-nums; }
.lcr-calc .lcr-card.is-best .lcr-total { color: var(--lcr-good-dark); }
.lcr-calc .lcr-rows { list-style: none; margin: 0; padding: 0; }
.lcr-calc .lcr-rows li {
	display: flex; justify-content: space-between; gap: 8px;
	padding: 3px 0; margin: 0; border-top: 1px solid var(--lcr-border);
	font-size: 0.82rem; font-variant-numeric: tabular-nums;
}
.lcr-calc .lcr-rows li::before { content: none; }
.lcr-calc .lcr-vat { font-size: 0.7em; font-weight: var(--lcr-strong); color: var(--lcr-muted); }
.lcr-calc .lcr-note { margin: 6px 0 0; font-size: 0.72rem; color: var(--lcr-muted); }

/* Johtopäätös */
.lcr-calc .lcr-verdict {
	margin-top: 12px; padding: 10px 14px; border-radius: 8px;
	background: var(--lcr-accent); color: #fff; font-size: 0.95rem; font-weight: 400; text-align: center;
}
.lcr-calc .lcr-verdict strong { font-weight: var(--lcr-strong); }
.lcr-calc .lcr-breakeven { margin: 8px 0 0; text-align: center; font-size: 0.78rem; color: var(--lcr-muted); }
.lcr-calc .lcr-breakeven:empty { display: none; }

@media (max-width: 520px) {
	.lcr-calc { padding: 14px; }
	.lcr-calc .lcr-form { grid-template-columns: 1fr 1fr; }
	.lcr-calc .lcr-field-class { grid-column: 1 / -1; }
}
@media (max-width: 480px) {
	.lcr-calc .lcr-results { grid-template-columns: 1fr; }
}
