.uaefc-card {
	--uaefc-primary: #0a6e5c;
	--uaefc-primary-dark: #084f42;
	--uaefc-bg: #f7faf9;
	--uaefc-border: #e0e6e4;
	--uaefc-text: #1c2b28;
	max-width: 620px;
	margin: 24px auto;
	border: 1px solid var(--uaefc-border);
	border-radius: 12px;
	background: #fff;
	box-shadow: 0 2px 10px rgba(0,0,0,0.05);
	font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Arial, sans-serif;
	color: var(--uaefc-text);
	overflow: hidden;
}

.uaefc-header {
	background: linear-gradient(135deg, var(--uaefc-primary), var(--uaefc-primary-dark));
	color: #fff;
	padding: 18px 22px;
}

.uaefc-header h3 {
	margin: 0 0 4px;
	font-size: 20px;
	font-weight: 700;
	color:  white;
}

.uaefc-subtitle {
	margin: 0;
	font-size: 13px;
	opacity: 0.9;
}

.uaefc-body {
	padding: 20px 22px 24px;
}

.uaefc-field {
	margin-bottom: 14px;
}

.uaefc-field label {
	display: block;
	font-size: 13px;
	font-weight: 600;
	margin-bottom: 5px;
	color: #45554f;
}

.uaefc-input-wrap {
	position: relative;
	display: flex;
	align-items: center;
}

.uaefc-input-wrap input,
.uaefc-input-wrap select {
	width: 100%;
	box-sizing: border-box;
	padding: 10px 12px;
	border: 1px solid var(--uaefc-border);
	border-radius: 8px;
	font-size: 15px;
	background: var(--uaefc-bg);
	color: var(--uaefc-text);
}

.uaefc-input-wrap input:focus,
.uaefc-input-wrap select:focus {
	outline: none;
	border-color: var(--uaefc-primary);
	background: #fff;
}

.uaefc-suffix {
	position: absolute;
	right: 12px;
	font-size: 13px;
	color: #7a8b85;
	pointer-events: none;
}

.uaefc-calc-btn {
	width: 100%;
	padding: 12px;
	margin-top: 6px;
	background: var(--uaefc-primary);
	color: #fff;
	border: none;
	border-radius: 8px;
	font-size: 15px;
	font-weight: 700;
	cursor: pointer;
	transition: background 0.15s ease;
}

.uaefc-calc-btn:hover {
	background: var(--uaefc-primary-dark);
}

.uaefc-results {
	margin-top: 18px;
	padding: 14px 16px;
	background: var(--uaefc-bg);
	border: 1px solid var(--uaefc-border);
	border-radius: 8px;
}

.uaefc-result-row {
	display: flex;
	justify-content: space-between;
	align-items: baseline;
	padding: 7px 0;
	border-bottom: 1px dashed var(--uaefc-border);
	font-size: 14px;
}

.uaefc-result-row:last-child {
	border-bottom: none;
}

.uaefc-result-row[data-row$="_pay"] .uaefc-result-value,
.uaefc-result-row[data-row="gratuity"] .uaefc-result-value,
.uaefc-result-row[data-row="net"] .uaefc-result-value,
.uaefc-result-row[data-row="emi"] .uaefc-result-value,
.uaefc-result-row[data-row="monthly_payment"] .uaefc-result-value,
.uaefc-result-row[data-row="monthly_emi"] .uaefc-result-value,
.uaefc-result-row[data-row="zakat_amount"] .uaefc-result-value,
.uaefc-result-row[data-row="household_estimate"] .uaefc-result-value,
.uaefc-result-row[data-row="leave_pay"] .uaefc-result-value,
.uaefc-result-row[data-row="new_rent"] .uaefc-result-value,
.uaefc-result-row[data-row="total_pay"] .uaefc-result-value {
	font-size: 17px;
	font-weight: 800;
	color: var(--uaefc-primary-dark);
}

.uaefc-result-value {
	font-weight: 600;
}

.uaefc-note {
	margin: 12px 0 0;
	font-size: 12px;
	color: #7a8b85;
	line-height: 1.5;
}

.uaefc-disclaimer {
	margin-top: 14px;
	padding: 10px 12px;
	background: #fdf6e8;
	border: 1px solid #f0ddad;
	border-radius: 8px;
	font-size: 12px;
	line-height: 1.5;
	color: #6b5a2a;
}

.uaefc-disclaimer strong {
	color: #4d3f1a;
}

.uaefc-error {
	color: #b3261e;
	font-size: 13px;
	margin-top: 10px;
}

/* Year / month duration picker */
.uaefc-ym-row {
	display: flex;
	gap: 12px;
}

.uaefc-ym-group {
	flex: 1;
	display: flex;
	align-items: center;
	gap: 8px;
}

.uaefc-ym-group select {
	flex: 1;
	box-sizing: border-box;
	padding: 10px 12px;
	border: 1px solid var(--uaefc-border);
	border-radius: 8px;
	font-size: 15px;
	background: var(--uaefc-bg);
	color: var(--uaefc-text);
}

.uaefc-ym-label {
	font-size: 12px;
	color: #7a8b85;
	white-space: nowrap;
}

input[type="date"] {
	font-family: inherit;
}

/* Amortization charts + schedule */
.uaefc-charts {
	margin-top: 18px;
}

.uaefc-chart-row {
	display: flex;
	flex-wrap: wrap;
	gap: 16px;
	margin-bottom: 18px;
}

.uaefc-chart-box {
	flex: 1 1 220px;
	min-width: 200px;
	height: 240px;
	position: relative;
	box-sizing: border-box;
	display: flex;
	flex-direction: column;
	background: var(--uaefc-bg);
	border: 1px solid var(--uaefc-border);
	border-radius: 8px;
	padding: 12px;
}

.uaefc-chart-box--wide {
	flex: 2 1 300px;
}

.uaefc-chart-box canvas {
	flex: 1 1 auto;
	min-height: 0;
	width: 100% !important;
	height: auto !important;
}

.uaefc-chart-title {
	margin: 0 0 8px;
	font-size: 12px;
	font-weight: 700;
	color: #45554f;
	text-transform: uppercase;
	letter-spacing: 0.03em;
}

.uaefc-simple-chart {
	margin-top: 18px;
}

.uaefc-chart-box--standalone {
	width: 100%;
	height: 240px;
}

.uaefc-schedule-head {
	display: flex;
	align-items: center;
	justify-content: space-between;
	margin-bottom: 8px;
}

.uaefc-toggle-monthly {
	background: none;
	border: 1px solid var(--uaefc-primary);
	color: var(--uaefc-primary);
	border-radius: 6px;
	padding: 6px 12px;
	font-size: 12px;
	font-weight: 700;
	cursor: pointer;
}

.uaefc-toggle-monthly:hover {
	background: var(--uaefc-primary);
	color: #fff;
}

.uaefc-table-scroll {
	max-height: 320px;
	overflow-y: auto;
	border: 1px solid var(--uaefc-border);
	border-radius: 8px;
}

.uaefc-schedule-table {
	width: 100%;
	border-collapse: collapse;
	font-size: 13px;
}

.uaefc-schedule-table thead th {
	position: sticky;
	top: 0;
	background: var(--uaefc-primary-dark);
	color: #fff;
	text-align: left;
	padding: 8px 10px;
	font-weight: 600;
}

.uaefc-schedule-table tbody td {
	padding: 7px 10px;
	border-bottom: 1px solid var(--uaefc-border);
}

.uaefc-schedule-table tbody tr:nth-child(even) {
	background: var(--uaefc-bg);
}

@media (max-width: 480px) {
	.uaefc-body { padding: 16px; }
	.uaefc-header { padding: 16px; }
	.uaefc-ym-row { flex-direction: column; gap: 8px; }
	.uaefc-chart-row { flex-direction: column; }
	.uaefc-schedule-head { flex-direction: column; align-items: flex-start; gap: 8px; }
}
