/**
 * Asim Ali Calculator Suite Styles
 * Primary Color: #11143a (Dark Navy)
 * Accent Color:  #f0b254 (Gold/Amber)
 * Soft Tint:     #ebedff (Lavender Blue)
 * Background:    #f8f5f0 / #ffffff / #f3f3f3
 */

.asim-calc-wrapper {
	font-family: inherit;
	color: #11143a;
	box-sizing: border-box;
	margin: 0 auto;
	width: 100%;
}

.asim-calc-wrapper * {
	box-sizing: border-box;
}

/* Card & Layout Styles */
.asim-calc-card {
	background: #ffffff;
	border: 1px solid #e2e8f0;
	border-radius: 8px;
	overflow: hidden;
	margin-bottom: 20px;
}

.asim-calc-card.shadow {
	box-shadow: 0 4px 15px rgba(0, 0, 0, 0.08);
}

.asim-calc-card-header {
	background-color: #f8fafc;
	border-bottom: 1px solid #e2e8f0;
	padding: 16px 20px;
}

.asim-calc-card-body {
	padding: 24px;
}

.asim-calc-section-title {
	font-size: 1.5rem;
	font-weight: 700;
	color: #11143a;
	margin: 0;
}

.asim-calc-card-title {
	font-size: 1.2rem;
	font-weight: 600;
	color: #11143a;
	margin: 0;
}

/* Grids */
.asim-calc-grid-2col {
	display: grid;
	grid-template-columns: 1fr;
	gap: 24px;
}

@media (min-width: 768px) {
	.asim-calc-grid-2col {
		grid-template-columns: 1fr 1fr;
	}
}

.asim-calc-header-grid {
	display: grid;
	grid-template-columns: 1fr;
	gap: 20px;
	margin-bottom: 24px;
	align-items: center;
}

@media (min-width: 768px) {
	.asim-calc-header-grid {
		grid-template-columns: 1fr 2fr;
	}
}

.asim-calc-location-note {
	font-size: 14px;
	font-weight: 500;
	color: #4a5568;
}

.asim-calc-slider-group {
	display: flex;
	flex-direction: column;
	gap: 8px;
}

@media (min-width: 768px) {
	.asim-calc-slider-group {
		flex-direction: row;
		align-items: center;
		gap: 16px;
	}
	.asim-calc-slider-group .asim-calc-label {
		min-width: 120px;
		margin-bottom: 0;
	}
	.asim-calc-slider-controls {
		flex: 1;
	}
}

/* Form Controls */
.asim-calc-form-group {
	margin-bottom: 18px;
}

.asim-calc-horizontal-group {
	display: flex;
	flex-direction: column;
	gap: 8px;
}

@media (min-width: 768px) {
	.asim-calc-horizontal-group {
		flex-direction: row;
		align-items: center;
		gap: 16px;
	}
	.asim-calc-horizontal-group .asim-calc-form-label {
		width: 35%;
		margin-bottom: 0;
	}
	.asim-calc-horizontal-group .asim-calc-field-wrap {
		width: 65%;
	}
}

.asim-calc-label,
.asim-calc-form-label {
	display: block;
	font-size: 15px;
	font-weight: 600;
	color: #11143a;
	margin-bottom: 6px;
}

.asim-calc-input,
.asim-calc-select {
	width: 100%;
	padding: 10px 14px;
	border: 1px solid #cbd5e1;
	border-radius: 6px;
	font-size: 15px;
	color: #11143a;
	background-color: #ffffff;
	transition: border-color 0.2s, box-shadow 0.2s;
}

.asim-calc-input:focus,
.asim-calc-select:focus {
	border-color: #f0b254;
	outline: none;
	box-shadow: 0 0 0 3px rgba(240, 178, 84, 0.2);
}

.asim-calc-currency-display {
	font-weight: 600;
	background-color: #f8fafc;
	margin-bottom: 8px;
}

/* Range Slider */
.asim-calc-range-slider {
	-webkit-appearance: none;
	width: 100%;
	height: 6px;
	background: #e2e8f0;
	border-radius: 4px;
	outline: none;
	margin: 10px 0;
	padding: 0;
	border: none;
	cursor: pointer;
}

.asim-calc-range-slider::-webkit-slider-thumb {
	-webkit-appearance: none;
	width: 20px;
	height: 20px;
	background: #11143a;
	border: 2px solid #f0b254;
	border-radius: 50%;
	cursor: pointer;
	transition: transform 0.1s;
}

.asim-calc-range-slider::-webkit-slider-thumb:hover {
	transform: scale(1.15);
}

.asim-calc-range-slider::-moz-range-thumb {
	width: 20px;
	height: 20px;
	background: #11143a;
	border: 2px solid #f0b254;
	border-radius: 50%;
	cursor: pointer;
}

/* Input Prefixes and Suffixes */
.asim-calc-input-prefix-wrap,
.asim-calc-input-suffix-wrap {
	position: relative;
	display: flex;
	align-items: center;
	width: 100%;
}

.asim-calc-input-prefix {
	position: absolute;
	left: 12px;
	font-weight: 600;
	color: #64748b;
	pointer-events: none;
}

.asim-calc-input-suffix {
	position: absolute;
	right: 12px;
	font-weight: 600;
	color: #64748b;
	pointer-events: none;
}

.asim-calc-input.asim-calc-has-prefix {
	padding-left: 28px;
}

.asim-calc-input.asim-calc-has-suffix {
	padding-right: 28px;
}

.asim-calc-dual-inputs {
	display: flex;
	align-items: center;
	gap: 10px;
}

.asim-calc-equals-symbol {
	font-size: 1.2rem;
	font-weight: 700;
	color: #64748b;
}

/* Tab Navigation */
.asim-calc-tab-nav {
	display: flex;
	border-bottom: 2px solid #e2e8f0;
	margin-bottom: 24px;
}

.asim-calc-tab-btn {
	flex: 1;
	padding: 12px 20px;
	font-size: 16px;
	font-weight: 600;
	text-align: center;
	color: #64748b;
	background: none;
	border: none;
	border-bottom: 3px solid transparent;
	margin-bottom: -2px;
	cursor: pointer;
	transition: color 0.2s, border-color 0.2s;
}

.asim-calc-tab-btn:hover {
	color: #11143a;
}

.asim-calc-tab-btn.active {
	color: #11143a;
	border-bottom-color: #11143a;
}

/* Highlight Banners */
.asim-calc-popular-banner {
	background-color: #ebedff;
	border-radius: 8px 8px 0 0;
	padding: 24px;
	text-align: center;
	margin-bottom: 0;
}

.asim-calc-popular-title {
	font-size: 14px;
	font-weight: 600;
	color: #11143a;
	margin-bottom: 6px;
}

.asim-calc-popular-rate-wrap {
	display: flex;
	align-items: center;
	justify-content: center;
	gap: 12px;
}

.asim-calc-popular-rate {
	font-size: 3rem;
	font-weight: 700;
	color: #11143a;
	line-height: 1;
}

.asim-calc-popular-badge {
	background-color: #ffffff;
	color: #11143a;
	font-size: 13px;
	font-weight: 600;
	padding: 4px 10px;
	border-radius: 4px;
	box-shadow: 0 1px 3px rgba(0,0,0,0.08);
}

.asim-calc-variable-banner {
	background-color: #ebedff;
	border-radius: 8px 8px 0 0;
	padding: 24px;
	text-align: center;
}

.asim-calc-var-title {
	font-size: 1.3rem;
	font-weight: 700;
	color: #11143a;
	margin: 4px 0;
}

.asim-calc-highlight {
	color: #11143a;
}

/* Rates Table */
.asim-calc-table-responsive {
	width: 100%;
	overflow-x: auto;
	margin-bottom: 24px;
}

.asim-calc-rates-table {
	width: 100%;
	border-collapse: collapse;
	text-align: left;
	font-size: 15px;
}

.asim-calc-rates-table th {
	background-color: #ffffff;
	color: #11143a;
	font-weight: 600;
	padding: 14px 16px;
	border-bottom: 1px solid #e2e8f0;
}

.asim-calc-rates-table td {
	padding: 14px 16px;
	border-bottom: 1px solid #f1f5f9;
}

.asim-calc-rates-table tr:nth-child(even) {
	background-color: #f8fafc;
}

.asim-calc-rates-table tr:nth-child(odd) {
	background-color: #ffffff;
}

/* Buttons */
.asim-calc-btn {
	display: inline-block;
	padding: 12px 28px;
	font-size: 15px;
	font-weight: 700;
	text-align: center;
	border-radius: 4px;
	cursor: pointer;
	text-decoration: none;
	border: 2px solid transparent;
	transition: all 0.2s ease;
}

/* Apply Now Button (matches Next.js HeadBtn) */
.asim-calc-btn-apply,
.asim-calc-wrapper .tab-btn .HeadBtn {
	display: inline-block;
	min-width: 200px;
	padding: 10px 28px;
	font-size: 15px;
	font-weight: 700;
	text-transform: uppercase;
	letter-spacing: 0.5px;
	color: #f0b254;
	background-color: #ffffff;
	border: 2px solid #11143a;
	border-radius: 4px;
	text-decoration: none;
	text-align: center;
	transition: all 0.2s ease;
}

.asim-calc-btn-apply span,
.asim-calc-wrapper .tab-btn .HeadBtn span {
	color: #11143a;
}

.asim-calc-btn-apply:hover,
.asim-calc-wrapper .tab-btn .HeadBtn:hover {
	background-color: #11143a;
	color: #f0b254;
	border-color: #11143a;
}

.asim-calc-btn-apply:hover span,
.asim-calc-wrapper .tab-btn .HeadBtn:hover span {
	color: #ffffff;
}

.asim-calc-btn-primary {
	background-color: #f0b254;
	color: #11143a;
	border: 2px solid #f0b254;
}

.asim-calc-btn-primary span {
	color: #11143a;
	font-weight: 800;
}

.asim-calc-btn-primary:hover {
	background-color: #11143a;
	color: #f0b254;
	border-color: #11143a;
}

.asim-calc-btn-primary:hover span {
	color: #ffffff;
}

.asim-calc-btn-wrap {
	margin-top: 30px;
	display: flex;
	justify-content: center;
	align-items: center;
}

/* Result Blocks */
.asim-calc-results-block {
	background-color: #f8fafc;
	border: 1px solid #e2e8f0;
	border-radius: 6px;
	padding: 20px;
}

.asim-calc-results-title {
	font-size: 1.25rem;
	font-weight: 700;
	color: #11143a;
	border-bottom: 1px solid #e2e8f0;
	padding-bottom: 8px;
	margin-bottom: 14px;
}

.asim-calc-result-row {
	display: flex;
	justify-content: space-between;
	align-items: center;
	padding: 8px 0;
	font-size: 15px;
	border-bottom: 1px dashed #e2e8f0;
}

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

.asim-calc-result-name {
	color: #475569;
	font-weight: 500;
}

.asim-calc-result-val {
	font-weight: 700;
	color: #11143a;
}

.asim-calc-highlight-text {
	color: #f0b254;
	font-size: 1.15rem;
}

/* Reverse Mortgage Button */
.asim-calc-btn-reverse-mortgage,
.asim-calc-wrapper .HeadBtn {
	display: inline-block;
	padding: 10px 28px;
	font-size: 14px;
	font-weight: 700;
	text-transform: uppercase;
	letter-spacing: 0.5px;
	color: #f0b254;
	background-color: #ffffff;
	border: 1px solid #11143a;
	border-radius: 4px;
	cursor: pointer;
	text-decoration: none;
	transition: all 0.2s ease;
}

.asim-calc-btn-reverse-mortgage:hover,
.asim-calc-wrapper .HeadBtn:hover {
	background-color: #11143a;
	color: #f0b254;
	border-color: #11143a;
}

.asim-calc-action-wrap.tb-btn {
	display: flex;
	justify-content: center;
	align-items: center;
	margin-top: 20px;
}

/* Reverse Mortgage Result Box */
.asim-calc-result-card {
	background-color: #ebedff;
	border-radius: 8px;
	padding: 24px;
	text-align: center;
}

.asim-reverse-mortgage-calc .asim-calc-result-card {
	background-color: #ffffff;
	border: 1px solid #11143a;
	border-radius: 6px;
	padding: 28px 24px;
}

.asim-calc-result-label {
	font-size: 14px;
	font-weight: 600;
	color: #11143a;
	margin: 0 0 6px 0;
	text-transform: uppercase;
	letter-spacing: 0.5px;
}

.asim-calc-result-value {
	font-size: 2.25rem;
	font-weight: 700;
	color: #11143a;
	margin: 0;
	line-height: 1.2;
}

/* FTHBI Result Box */
.asim-calc-fthbi-result-box {
	background-color: #ebedff;
	border-radius: 8px;
	padding: 24px;
	margin-top: 16px;
}

.asim-calc-fthbi-result-header {
	font-size: 16px;
	font-weight: 600;
	color: #64748b;
	margin-bottom: 8px;
}

.asim-calc-fthbi-result-value {
	font-size: 2.5rem;
	font-weight: 700;
	color: #11143a;
}

.asim-calc-fthbi-result-value.ineligible {
	color: #c53030;
	font-size: 2rem;
}

.asim-calc-warning-box {
	background-color: #fffaf0;
	border: 1px solid #feebc8;
	border-radius: 6px;
	padding: 16px;
	display: flex;
	align-items: flex-start;
	gap: 12px;
	text-align: left;
}

.asim-calc-warning-icon {
	flex-shrink: 0;
	margin-top: 2px;
}

.asim-calc-warning-msg {
	color: #7b341e;
	font-size: 14px;
	line-height: 1.5;
}

.asim-calc-divider {
	height: 1px;
	background-color: #e2e8f0;
	margin: 16px 0;
}

/* Scenario Cards (Renewal) */
.asim-calc-scenario-grid {
	display: grid;
	grid-template-columns: 1fr;
	gap: 20px;
}

@media (min-width: 768px) {
	.asim-calc-scenario-grid {
		grid-template-columns: 1fr 1fr;
	}
}

.asim-calc-scenario-card {
	background: #f8fafc;
	border: 1px solid #e2e8f0;
}

.asim-calc-scenario-result {
	background: #ffffff;
	border: 1px solid #e2e8f0;
	border-radius: 6px;
	padding: 12px 16px;
	margin-top: 14px;
	display: flex;
	justify-content: space-between;
	align-items: center;
}

.asim-calc-payment-val {
	font-size: 1.25rem;
	font-weight: 700;
	color: #11143a;
}

/* Disclaimer Footer */
.asim-calc-disclaimer-wrap {
	display: flex;
	flex-direction: column;
	gap: 8px;
	font-size: 13px;
	color: #64748b;
	margin-top: 16px;
	padding-top: 16px;
	border-top: 1px solid #e2e8f0;
}

@media (min-width: 768px) {
	.asim-calc-disclaimer-wrap {
		flex-direction: row;
		justify-content: space-between;
	}
	.asim-calc-disclaimer-text {
		max-width: 70%;
		margin: 0;
	}
	.asim-calc-last-update {
		margin: 0;
		text-align: right;
	}
}

/* Spinner */
.asim-calc-spinner {
	display: inline-block;
	width: 24px;
	height: 24px;
	border: 3px solid rgba(17, 20, 58, 0.2);
	border-radius: 50%;
	border-top-color: #11143a;
	animation: asim-spin 0.8s linear infinite;
}

@keyframes asim-spin {
	to {
		transform: rotate(360deg);
	}
}

/* Utility Helpers */
.text-center {
	text-align: center;
}

.w-full {
	width: 100%;
}

.mt-3 { margin-top: 12px; }
.mt-4 { margin-top: 16px; }
.mb-3 { margin-bottom: 12px; }
.mb-4 { margin-bottom: 16px; }
