/* Tanışmalıyız hesaplama araçları – ortak görünüm (temadan bağımsız). */
.tmh {
	--tmh-ink: #1d2b44;
	--tmh-muted: #5d6b82;
	--tmh-line: #d9e0ea;
	--tmh-panel: #f4f7fa;
	--tmh-card: #ffffff;
	--tmh-accent: #0f7b62;
	--tmh-accent-soft: #e3f3ee;
	--tmh-minus: #b4372f;
	--tmh-warn-bg: #fff6e0;
	--tmh-warn: #7a5300;
	--tmh-radius: 10px;
	color: var(--tmh-ink);
	background: var(--tmh-panel);
	border: 1px solid var(--tmh-line);
	border-radius: var(--tmh-radius);
	padding: 20px;
	margin: 1.5em 0;
	font-size: 16px;
	line-height: 1.5;
	font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
	box-sizing: border-box;
}
.tmh *, .tmh *::before, .tmh *::after { box-sizing: border-box; }
.tmh__head { display: flex; flex-wrap: wrap; align-items: baseline; justify-content: space-between; gap: 6px 12px; margin: 0 0 16px; }
.tmh__title { margin: 0; font-size: 1.15em; font-weight: 700; line-height: 1.3; }
.tmh__badge { font-size: 12px; color: var(--tmh-muted); background: var(--tmh-card); border: 1px solid var(--tmh-line); border-radius: 99px; padding: 2px 10px; white-space: nowrap; }
.tmh__grid { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.1fr); gap: 20px; align-items: start; }
.tmh__form { display: grid; gap: 14px; }
.tmh__row2 { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.tmh__field { display: grid; gap: 5px; }
.tmh__field > span { font-size: 14px; font-weight: 600; }
.tmh__field small { color: var(--tmh-muted); font-size: 12.5px; line-height: 1.4; }
.tmh input[type="text"], .tmh input[type="number"], .tmh input[type="date"], .tmh select {
	width: 100%; min-height: 44px; padding: 8px 12px; font: inherit; font-size: 16px; color: var(--tmh-ink);
	background: var(--tmh-card); border: 1px solid #b9c4d3; border-radius: 8px; box-shadow: none; margin: 0;
	font-variant-numeric: tabular-nums;
}
.tmh input:focus, .tmh select:focus { outline: 2px solid var(--tmh-accent); outline-offset: 1px; border-color: var(--tmh-accent); }
.tmh__suffix { position: relative; }
.tmh__suffix input { padding-right: 44px; }
.tmh__suffix em { position: absolute; right: 12px; top: 50%; transform: translateY(-50%); font-style: normal; color: var(--tmh-muted); font-size: 14px; pointer-events: none; }
.tmh__seg { display: flex; flex-wrap: wrap; gap: 6px; }
.tmh__seg label { flex: 1 1 auto; position: relative; }
.tmh__seg input { position: absolute; opacity: 0; inset: 0; margin: 0; cursor: pointer; }
.tmh__seg span { display: block; text-align: center; padding: 10px 12px; border: 1px solid #b9c4d3; border-radius: 8px; background: var(--tmh-card); font-size: 14.5px; font-weight: 600; cursor: pointer; }
.tmh__seg input:checked + span { background: var(--tmh-ink); border-color: var(--tmh-ink); color: #fff; }
.tmh__seg input:focus-visible + span { outline: 2px solid var(--tmh-accent); outline-offset: 2px; }
.tmh__check { display: flex; gap: 8px; align-items: flex-start; font-size: 14.5px; }
.tmh__check input { margin-top: 4px; width: 18px; height: 18px; flex: none; }
.tmh__btn { min-height: 46px; padding: 10px 18px; font: inherit; font-weight: 700; color: #fff; background: var(--tmh-accent); border: 0; border-radius: 8px; cursor: pointer; }
.tmh__btn:hover { filter: brightness(1.08); }
.tmh__btn:focus-visible { outline: 2px solid var(--tmh-ink); outline-offset: 2px; }

/* Sonuç: bordro fişi görünümü */
.tmh__out { background: var(--tmh-card); border: 1px solid var(--tmh-line); border-radius: var(--tmh-radius); padding: 18px 18px 14px; min-height: 120px; }
.tmh__out:empty::before { content: "Bilgileri girin, sonuç burada görünecek."; color: var(--tmh-muted); font-size: 14.5px; }
.tmh__total { display: grid; gap: 2px; padding-bottom: 14px; margin-bottom: 12px; border-bottom: 2px dashed var(--tmh-line); }
.tmh__total span { font-size: 13.5px; color: var(--tmh-muted); font-weight: 600; }
.tmh__total strong { font-size: clamp(26px, 5vw, 34px); line-height: 1.15; color: var(--tmh-accent); font-variant-numeric: tabular-nums; letter-spacing: -0.01em; }
.tmh__total small { color: var(--tmh-muted); font-size: 13px; }
.tmh ul.tmh__lines { list-style: none !important; margin: 0 !important; padding: 0 !important; }
.tmh ul.tmh__lines li { display: flex; align-items: baseline; gap: 8px; padding: 5px 0; font-size: 14.5px; margin: 0 !important; list-style: none !important; }
.tmh ul.tmh__lines li::before { content: none !important; display: none !important; }
.tmh__lines li > span:first-child { flex: 0 1 auto; min-width: 0; }
.tmh__lines li::after { content: ""; order: 1; flex: 1 1 0; min-width: 12px; border-bottom: 1px dotted #b9c4d3; transform: translateY(-4px); }
.tmh__lines li > b { order: 2; flex: 0 0 auto; white-space: nowrap; font-weight: 600; font-variant-numeric: tabular-nums; text-align: right; }
.tmh__lines li.is-minus > b { color: var(--tmh-minus); }
.tmh__lines li.is-sum { border-top: 1px solid var(--tmh-line); margin-top: 4px; padding-top: 8px; }
.tmh__lines li.is-sum > b { font-weight: 800; }
.tmh__note { margin: 12px 0 0; padding: 10px 12px; font-size: 13.5px; background: var(--tmh-warn-bg); color: var(--tmh-warn); border-radius: 8px; }
.tmh__note.is-ok { background: var(--tmh-accent-soft); color: #0b5a48; }
.tmh__table-wrap { overflow-x: auto; margin-top: 14px; -webkit-overflow-scrolling: touch; }
.tmh__table { width: 100%; border-collapse: collapse; font-size: 13.5px; font-variant-numeric: tabular-nums; margin: 0; }
.tmh__table th, .tmh__table td { padding: 6px 8px; border-bottom: 1px solid var(--tmh-line); text-align: right; white-space: nowrap; background: none; }
.tmh__table th:first-child, .tmh__table td:first-child { text-align: left; }
.tmh__table thead th { font-weight: 700; color: var(--tmh-muted); font-size: 12.5px; border-bottom: 2px solid var(--tmh-line); }
.tmh__table tfoot td { font-weight: 800; border-top: 2px solid var(--tmh-line); }
.tmh__foot { margin: 14px 0 0; font-size: 12.5px; color: var(--tmh-muted); }
.tmh__err { color: var(--tmh-minus); font-size: 14px; font-weight: 600; }

@media (max-width: 760px) {
	.tmh { padding: 14px; }
	.tmh__grid { grid-template-columns: minmax(0, 1fr); }
}
@media (max-width: 420px) {
	.tmh__row2 { grid-template-columns: minmax(0, 1fr); }
}
/* Karanlık mod (Manşet teması ve sistem tercihi) */
html[data-theme="dark"] .tmh {
	--tmh-ink: #e6ebf3; --tmh-muted: #a3afc2; --tmh-line: #334055; --tmh-panel: #1a2230; --tmh-card: #222c3c;
	--tmh-accent: #3cc49c; --tmh-accent-soft: #173b33; --tmh-minus: #ff8a80; --tmh-warn-bg: #3a2f14; --tmh-warn: #f3cf7a;
}
html[data-theme="dark"] .tmh input, html[data-theme="dark"] .tmh select { border-color: #48566d; }
html[data-theme="dark"] .tmh__seg input:checked + span { background: var(--tmh-accent); border-color: var(--tmh-accent); color: #0d1a16; }
@media print { .tmh__form { display: none; } .tmh__grid { grid-template-columns: 1fr; } }
.tmh [hidden] { display: none !important; }
.tmh [data-s], .tmh [data-alan] { display: grid; gap: 14px; }
.tmh__loading { margin: 0; color: var(--tmh-muted); font-size: 14.5px; }
.tmh__field .tmh__row2 .tmh__suffix em { font-weight: 700; }
