/* Free Utility Tools — Compound Interest Calculator */

/* ── Tool shell ── */
.fut-compound-interest {
	font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
	max-width: 920px;
	margin: 0 auto;
	background: #fff;
	border: 1px solid #e1e5e9;
	border-radius: 12px;
	overflow: hidden;
	box-shadow: 0 2px 12px rgba(0,0,0,.06);
}

/* ── Header ── */
.fut-ci-header {
	padding: 22px 28px 18px;
	background: linear-gradient(135deg, #1a5fa3 0%, #2271b1 100%);
}
.fut-ci-title {
	margin: 0 0 5px;
	font-size: 20px;
	font-weight: 700;
	color: #fff;
}
.fut-ci-desc {
	margin: 0;
	font-size: 13px;
	color: rgba(255,255,255,.82);
}

/* ── Two-column layout ── */
.fut-ci-layout {
	display: flex;
	min-height: 480px;
}
.fut-ci-input-col {
	width: 310px;
	flex-shrink: 0;
	padding: 22px 20px 22px 24px;
	border-right: 1px solid #e1e5e9;
	background: #fafbfc;
	display: flex;
	flex-direction: column;
	gap: 0;
}
.fut-ci-output-col {
	flex: 1;
	padding: 22px 24px;
	overflow: hidden;
	display: flex;
	flex-direction: column;
}
@media (max-width: 680px) {
	.fut-ci-layout { flex-direction: column; }
	.fut-ci-input-col { width: 100%; border-right: none; border-bottom: 1px solid #e1e5e9; }
}

/* ── Sections (input groups) ── */
.fut-ci-section {
	margin-bottom: 16px;
	display: flex;
	flex-direction: column;
	gap: 6px;
}
.fut-ci-label {
	font-size: 11px;
	font-weight: 700;
	text-transform: uppercase;
	letter-spacing: .5px;
	color: #555d66;
}
.fut-ci-optional {
	font-style: normal;
	font-weight: 400;
	text-transform: none;
	color: #9ca3af;
	font-size: 10px;
}

/* ── Currency selector ── */
.fut-ci-curr-select { cursor: pointer; }

/* ── Input base ── */
.fut-ci-input {
	padding: 9px 12px;
	border: 1.5px solid #d0d5dd;
	border-radius: 7px;
	font-size: 15px;
	color: #1d2327;
	background: #fff;
	box-sizing: border-box;
	transition: border-color .15s, box-shadow .15s;
	width: 100%;
}
.fut-ci-input:focus {
	outline: none;
	border-color: #2271b1;
	box-shadow: 0 0 0 3px rgba(34,113,177,.12);
}

/* ── Money input (symbol + number) ── */
.fut-ci-money-row {
	display: flex;
	align-items: center;
	border: 1.5px solid #d0d5dd;
	border-radius: 7px;
	overflow: hidden;
	background: #fff;
	transition: border-color .15s, box-shadow .15s;
}
.fut-ci-money-row:focus-within {
	border-color: #2271b1;
	box-shadow: 0 0 0 3px rgba(34,113,177,.12);
}
.fut-ci-sym {
	padding: 9px 10px 9px 12px;
	font-size: 15px;
	font-weight: 700;
	color: #2271b1;
	background: #f0f6fc;
	border-right: 1px solid #d0d5dd;
	flex-shrink: 0;
}
.fut-ci-money-row .fut-ci-input {
	border: none;
	border-radius: 0;
	box-shadow: none !important;
	padding-left: 10px;
}

/* ── Rate row ── */
.fut-ci-rate-row {
	display: flex;
	align-items: center;
	gap: 8px;
}
.fut-ci-pct {
	font-size: 15px;
	font-weight: 700;
	color: #8a9ab0;
}
.fut-ci-rate-row .fut-ci-input { flex: 1; }
.fut-ci-eff-hint {
	font-size: 11px;
	color: #9ca3af;
}
.fut-ci-eff-live { color: #2271b1; }

/* ── Duration row ── */
.fut-ci-duration-row {
	display: flex;
	align-items: center;
	gap: 7px;
}
.fut-ci-dur-lbl {
	font-size: 13px;
	font-weight: 600;
	color: #8a9ab0;
	white-space: nowrap;
	flex-shrink: 0;
}

/* ── Contribution tabs ── */
.fut-ci-contrib-tabs {
	display: flex;
	border: 1.5px solid #d0d5dd;
	border-radius: 7px;
	overflow: hidden;
}
.fut-ci-ctab {
	flex: 1;
	padding: 7px 0;
	border: none;
	background: #fff;
	font-size: 12px;
	font-weight: 600;
	color: #50575e;
	cursor: pointer;
	transition: background .15s, color .15s;
}
.fut-ci-ctab.active { background: #2271b1; color: #fff; }
.fut-ci-ctab:not(.active):hover { background: #f0f0f1; }

/* ── Contribution fields ── */
.fut-ci-contrib-fields {
	display: flex;
	flex-direction: column;
	gap: 8px;
	margin-top: 2px;
}
.fut-ci-contrib-amount-row {
	display: flex;
	align-items: center;
	gap: 7px;
}
.fut-ci-timing-row {
	display: flex;
	gap: 14px;
}
.fut-ci-radio-lbl {
	display: flex;
	align-items: center;
	gap: 5px;
	font-size: 13px;
	font-weight: 500;
	color: #1d2327;
	cursor: pointer;
}
.fut-ci-radio-lbl input[type="radio"] { accent-color: #2271b1; cursor: pointer; }

/* ── Action buttons ── */
.fut-ci-actions {
	display: flex;
	flex-direction: column;
	gap: 8px;
	margin-top: auto;
	padding-top: 18px;
}
.fut-ci-calc-btn,
.fut-ci-reset-btn {
	width: 100%;
	padding: 11px 0;
	border: none;
	border-radius: 7px;
	font-size: 14px;
	font-weight: 600;
	cursor: pointer;
	transition: background .15s, transform .08s;
}
.fut-ci-calc-btn {
	background: #2271b1;
	color: #fff;
}
.fut-ci-calc-btn:hover  { background: #135e96; }
.fut-ci-calc-btn:active { transform: scale(.98); }
.fut-ci-reset-btn {
	background: #f0f0f1;
	color: #3c434a;
	border: 1px solid #dcdcde;
}
.fut-ci-reset-btn:hover { background: #dcdcde; }

/* ══ OUTPUT COLUMN ══ */

/* Placeholder */
.fut-ci-placeholder {
	flex: 1;
	display: flex;
	flex-direction: column;
	align-items: center;
	justify-content: center;
	gap: 12px;
	color: #c8d8ea;
	text-align: center;
	padding: 40px 20px;
}
.fut-ci-placeholder p {
	margin: 0;
	font-size: 14px;
	color: #9ca3af;
}

/* Result title */
.fut-ci-result-title {
	font-size: 16px;
	font-weight: 700;
	color: #1d2327;
	margin: 0 0 16px;
	padding-bottom: 12px;
	border-bottom: 1px solid #e1e5e9;
}
.fut-ci-title-duration { color: #2271b1; }

/* 6-metric grid */
.fut-ci-metrics {
	display: grid;
	grid-template-columns: 1fr 1fr;
	gap: 10px;
	margin-bottom: 16px;
}
@media (max-width: 480px) {
	.fut-ci-metrics { grid-template-columns: 1fr; }
}
.fut-ci-metric {
	background: #f8f9fa;
	border: 1px solid #e1e5e9;
	border-radius: 9px;
	padding: 12px 14px;
}
.fut-ci-metric-fv  { background: linear-gradient(135deg, #f0fdf4, #dcfce7); border-color: #86efac; }
.fut-ci-metric-int { background: linear-gradient(135deg, #fff7ed, #ffedd5); border-color: #fdba74; }
.fut-ci-met-lbl {
	display: block;
	font-size: 10px;
	font-weight: 700;
	text-transform: uppercase;
	letter-spacing: .4px;
	color: #8a9ab0;
	margin-bottom: 5px;
}
.fut-ci-met-val {
	display: block;
	font-size: 18px;
	font-weight: 800;
	color: #1d2327;
	font-variant-numeric: tabular-nums;
	line-height: 1.2;
}
.fut-ci-metric-fv  .fut-ci-met-val { color: #16a34a; font-size: 22px; }
.fut-ci-metric-int .fut-ci-met-val { color: #ea580c; }

/* Growth bar */
.fut-ci-bar-section {
	margin-bottom: 16px;
}
.fut-ci-bar-track {
	display: flex;
	height: 22px;
	border-radius: 6px;
	overflow: hidden;
	margin-bottom: 8px;
	background: #e5e7eb;
}
.fut-ci-bar-principal-seg {
	background: #2271b1;
	transition: width .5s ease;
	height: 100%;
}
.fut-ci-bar-interest-seg {
	background: #22c55e;
	transition: width .5s ease;
	height: 100%;
}
.fut-ci-bar-legend {
	display: flex;
	gap: 18px;
	font-size: 12px;
	color: #50575e;
}
.fut-ci-leg { display: flex; align-items: center; gap: 5px; }
.fut-ci-leg-dot {
	width: 10px;
	height: 10px;
	border-radius: 2px;
	display: inline-block;
	flex-shrink: 0;
}
.fut-ci-leg strong { color: #1d2327; }

/* Breakdown section */
.fut-ci-breakdown { flex: 1; }
.fut-ci-bk-header {
	display: flex;
	align-items: center;
	justify-content: space-between;
	margin-bottom: 10px;
}
.fut-ci-bk-title {
	font-size: 13px;
	font-weight: 700;
	color: #1d2327;
}
.fut-ci-bk-tabs {
	display: flex;
	border: 1.5px solid #d0d5dd;
	border-radius: 6px;
	overflow: hidden;
}
.fut-ci-bk-tab {
	padding: 5px 14px;
	border: none;
	background: #fff;
	font-size: 12px;
	font-weight: 600;
	color: #50575e;
	cursor: pointer;
	transition: background .15s, color .15s;
}
.fut-ci-bk-tab.active  { background: #2271b1; color: #fff; }
.fut-ci-bk-tab:not(.active):hover { background: #f0f0f1; }

/* Breakdown table */
.fut-ci-table-wrap {
	max-height: 300px;
	overflow-y: auto;
	border: 1px solid #e1e5e9;
	border-radius: 8px;
}
.fut-ci-table {
	width: 100%;
	border-collapse: collapse;
	font-size: 13px;
}
.fut-ci-table thead {
	position: sticky;
	top: 0;
	z-index: 1;
}
.fut-ci-table th {
	padding: 9px 12px;
	background: #1d2327;
	color: #fff;
	font-size: 11px;
	font-weight: 700;
	text-transform: uppercase;
	letter-spacing: .3px;
	text-align: right;
	white-space: nowrap;
}
.fut-ci-table th:first-child { text-align: left; }
.fut-ci-table td {
	padding: 8px 12px;
	text-align: right;
	color: #1d2327;
	font-variant-numeric: tabular-nums;
	border-bottom: 1px solid #f0f0f1;
}
.fut-ci-table td:first-child { text-align: left; font-weight: 600; color: #646970; }
.fut-ci-table tbody tr:last-child td { border-bottom: none; }
.fut-ci-table tbody tr:hover td { background: #f8f9fa; }
.fut-ci-table .fut-ci-row-highlight td {
	background: linear-gradient(135deg, #f0fdf4, #dcfce7) !important;
	font-weight: 700;
	color: #15803d;
}
.fut-ci-table .fut-ci-year-cell { color: #2271b1; font-weight: 700; }
.fut-ci-table .fut-ci-balance-cell { color: #22c55e; font-weight: 800; }
.fut-ci-table .fut-ci-accrued-cell { color: #f59e0b; font-weight: 700; }
