/*
 * TEG-HVAC - the shortcodes, wherever a theme puts them.
 *
 * Everything is scoped under .thv-public so that a theme's own headings, lists
 * and forms are left alone, and every rule inherits the theme's font on
 * purpose: this is the contractor's page, not the plugin's.
 *
 * Amber is the accent, the deep blue-grey is the text, and the clear red is
 * kept for one job only - danger. It marks a C1, a C2 and anything that has
 * run out, and it marks nothing else, so that when it appears it means
 * something.
 */

.thv-public {
	--thv-amber: #e0a800;
	--thv-amber-dark: #b98a00;
	--thv-ink: #2b3a4a;
	--thv-ink-soft: #46586b;
	--thv-cream: #f7f4ee;
	--thv-line: #e3ddd2;
	--thv-muted: #74818f;
	--thv-red: #c0392b;
	--thv-green: #1f6f4a;
	color: var(--thv-ink);
}

.thv-public * { box-sizing: border-box; }

.thv-public h3.thv-h,
.thv-public .thv-h { color: var(--thv-ink); margin: 1.6em 0 .5em; }
.thv-public .thv-h4 { color: var(--thv-ink); margin: 1.4em 0 .4em; font-size: 1.05em; }
.thv-public .thv-hint { display: block; color: var(--thv-muted); font-size: .86em; margin-top: 3px; }
.thv-public .thv-lead { font-size: 1.05em; }
.thv-public .thv-muted { color: var(--thv-muted); }
.thv-public .thv-empty,
.thv-public .thv-closed { background: var(--thv-cream); border-left: 4px solid var(--thv-amber); padding: 12px 16px; border-radius: 0 6px 6px 0; }
.thv-public .thv-bad { color: var(--thv-red); font-weight: 600; }
.thv-public .thv-contact { background: var(--thv-cream); border-radius: 8px; padding: 12px 16px; margin-top: 18px; }

.thv-public .thv-flash { padding: 10px 16px; border-radius: 6px; margin: 0 0 16px; }
.thv-public .thv-flash.thv-ok { background: #e4f1ea; color: var(--thv-green); }
.thv-public .thv-flash.thv-bad { background: #fbe9e7; color: var(--thv-red); }
.thv-public .thv-flash.thv-info { background: var(--thv-cream); color: var(--thv-ink-soft); }

.thv-public .thv-urgent {
	background: #fdf3e0;
	border-left: 4px solid var(--thv-red);
	padding: 12px 16px;
	border-radius: 0 6px 6px 0;
	font-weight: 600;
	display: flex;
	gap: 12px;
	align-items: center;
}

.thv-public .thv-btn {
	display: inline-block;
	background: var(--thv-amber);
	color: var(--thv-ink);
	border: 0;
	border-radius: 6px;
	padding: 10px 22px;
	font: inherit;
	font-weight: 700;
	line-height: 1.3;
	text-decoration: none;
	cursor: pointer;
}

.thv-public .thv-btn:hover,
.thv-public .thv-btn:focus { background: var(--thv-amber-dark); color: #fff; }
.thv-public .thv-btn-small { padding: 5px 14px; font-size: .88em; }
.thv-public .thv-btn-plain { background: transparent; border: 1px solid var(--thv-line); color: var(--thv-ink-soft); }
.thv-public .thv-btn-plain:hover { background: var(--thv-cream); color: var(--thv-ink); }

/* ── the forms ──────────────────────────────────────────────────────── */

.thv-public .thv-pform { margin: 8px 0 0; }
.thv-public .thv-fields { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 4px 20px; }
.thv-public .thv-field { margin: 0 0 14px; }
.thv-public .thv-field label { display: block; font-weight: 600; margin-bottom: 4px; }
.thv-public .thv-field input[type="text"],
.thv-public .thv-field input[type="email"],
.thv-public .thv-field input[type="tel"],
.thv-public .thv-field input[type="date"],
.thv-public .thv-field input[type="number"],
.thv-public .thv-field select,
.thv-public .thv-field textarea {
	width: 100%;
	max-width: 460px;
	padding: 9px 11px;
	border: 1px solid var(--thv-line);
	border-radius: 6px;
	font: inherit;
	background: #fff;
	color: inherit;
}

.thv-public .thv-field input:focus,
.thv-public .thv-field select:focus,
.thv-public .thv-field textarea:focus { outline: 2px solid var(--thv-amber); outline-offset: 1px; }
.thv-public .thv-req { color: var(--thv-red); }
.thv-public .thv-submit { margin: 20px 0 0; }
.thv-public .thv-terms {
	background: var(--thv-cream);
	border-radius: 8px;
	padding: 12px 16px;
	margin: 14px 0;
	font-size: .9em;
	max-height: 220px;
	overflow: auto;
}

/* The honeypot. Hidden from people and from screen readers, left in the DOM. */
.thv-public .thv-hp { position: absolute !important; left: -9999px !important; width: 1px; height: 1px; overflow: hidden; }

/* ── what we do ─────────────────────────────────────────────────────── */

.thv-service-list {
	list-style: none;
	margin: 0;
	padding: 0;
	display: grid;
	grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
	gap: 18px;
}

.thv-service {
	background: #fff;
	border: 1px solid var(--thv-line);
	border-top: 3px solid var(--thv-amber);
	border-radius: 10px;
	padding: 16px 18px;
	margin: 0;
}

.thv-service-name { margin: 0 0 6px; font-size: 1.08em; color: var(--thv-ink); }
.thv-service-text { margin: 0 0 10px; font-size: .95em; }
.thv-service-cta { margin: 0; }

.thv-public .thv-scheme {
	background: var(--thv-cream);
	border-left: 4px solid var(--thv-amber);
	padding: 12px 16px;
	border-radius: 0 6px 6px 0;
	margin-top: 22px;
}

.thv-public .thv-scheme-none { border-left-color: var(--thv-muted); }

/* ── a customer's own page ──────────────────────────────────────────── */

.thv-acc-sec { margin: 0 0 30px; }

.thv-ptable { width: 100%; border-collapse: collapse; margin: 6px 0 12px; }
.thv-ptable th,
.thv-ptable td { text-align: left; padding: 8px 12px 8px 0; border-bottom: 1px solid var(--thv-line); vertical-align: top; }
.thv-ptable thead th { font-size: .8em; text-transform: uppercase; letter-spacing: .06em; color: var(--thv-muted); }
.thv-ptable tbody th { color: var(--thv-muted); font-weight: 600; white-space: nowrap; width: 1%; }
.thv-ptable tr.thv-row-bad td { background: #fbe9e7; }

.thv-public .thv-decide { margin: 0; display: flex; gap: 6px; flex-wrap: wrap; }

.thv-public .thv-due { font-weight: 600; white-space: nowrap; }
.thv-public .thv-due-ok { color: var(--thv-green); }
.thv-public .thv-due-due_soon { color: var(--thv-amber-dark); }
.thv-public .thv-due-expired { color: var(--thv-red); }
.thv-public .thv-due-word { font-size: .82em; text-transform: uppercase; letter-spacing: .05em; color: var(--thv-red); }
.thv-public .thv-due-due_soon + .thv-due-word { color: var(--thv-amber-dark); }

.thv-public .thv-outcome { font-weight: 700; }
.thv-public .thv-outcome-satisfactory { color: var(--thv-green); }
.thv-public .thv-outcome-unsatisfactory { color: var(--thv-red); }

.thv-public .thv-balance { font-weight: 700; font-size: 1.05em; }
.thv-public .thv-balance-clear { color: var(--thv-green); font-weight: 600; }

@media (max-width: 600px) {
	.thv-ptable,
	.thv-ptable thead,
	.thv-ptable tbody,
	.thv-ptable tr { display: block; }
	.thv-ptable thead { display: none; }
	.thv-ptable tr { border-bottom: 2px solid var(--thv-line); padding: 6px 0; }
	.thv-ptable td { border: 0; padding: 3px 0; }
}
