/**
 * Help to Buy Calculator – calculator-specific styles
 * Ireland Calculators plugin
 *
 * Base layout, typography, inputs, buttons, result cards, and breakdowns
 * are inherited from ic-base.css via the mature shared selector group.
 * Only truly unique Help to Buy rules live here.
 */

/* ------------------------------------------------------------------
 * Advanced settings toggle
 * ------------------------------------------------------------------ */

.ic-helpbuycalc .ic-htb-advanced-toggle {
	cursor: pointer;
	user-select: none;
	display: flex;
	align-items: center;
	justify-content: space-between;
}

.ic-helpbuycalc .ic-htb-chevron {
	transition: transform 0.2s;
	flex-shrink: 0;
}

.ic-helpbuycalc .ic-htb-advanced-open .ic-htb-chevron {
	transform: rotate(180deg);
}

/* ------------------------------------------------------------------
 * Advanced panel
 * ------------------------------------------------------------------ */

.ic-helpbuycalc .ic-htb-advanced {
	padding-top: 0.25rem;
}


/* ------------------------------------------------------------------
 * Advanced settings grid
 * ------------------------------------------------------------------ */

.ic-helpbuycalc .ic-htb-advanced-grid {
	display: grid;
	grid-template-columns: 1fr 1fr;
	gap: 14px;
}

.ic-helpbuycalc .ic-htb-adv-field {
	min-width: 0;
}

.ic-helpbuycalc .ic-htb-adv-field > label {
	display: block;
	min-height: 2.9em;
}

@media (max-width: 820px) {
	.ic-helpbuycalc .ic-htb-advanced-grid {
		grid-template-columns: 1fr;
	}

	.ic-helpbuycalc .ic-htb-adv-field > label {
		min-height: 0;
	}
}

/* ------------------------------------------------------------------
 * Not-eligible state
 * ------------------------------------------------------------------ */

.ic-helpbuycalc .ic-result-primary.ic-htb-result-danger {
	background: #fef2f2;
	border: 1px solid #fecaca;
	box-shadow: inset 0 0 0 1px rgba(220, 38, 38, 0.06);
}

.ic-helpbuycalc .ic-htb-result-danger .ic-result-primary-label {
	color: #991b1b;
	opacity: 0.9;
}

.ic-helpbuycalc .ic-htb-result-danger .ic-result-primary-value {
	color: #dc2626;
}

.ic-helpbuycalc .ic-htb-result-danger .ic-result-primary-note {
	color: #7f1d1d;
	opacity: 0.9;
}

/* ------------------------------------------------------------------
 * Eligibility issue rows
 * ------------------------------------------------------------------ */

.ic-helpbuycalc .ic-htb-issue-row {
	justify-content: flex-start;
	align-items: flex-start;
	gap: 14px;
}

.ic-helpbuycalc .ic-htb-issue-icon {
	color: #dc2626;
	font-weight: 700;
	line-height: 1;
	margin-top: 3px;
	flex: 0 0 auto;
}

.ic-helpbuycalc .ic-htb-issue-text {
	flex: 1 1 auto;
	min-width: 0;
}

/* ------------------------------------------------------------------
 * Note / formula cards
 * ------------------------------------------------------------------ */

.ic-helpbuycalc .ic-formula-card {
	padding: 16px 18px;
}

.ic-helpbuycalc .ic-formula-card p {
	font-size: 14px;
	line-height: 1.65;
	margin: 0;
}

.ic-helpbuycalc .ic-formula-card p + p {
	margin-top: 10px;
}
