/**
 * CalculatorSuite Calculators — front-end styles
 * Graphite & Amber · Poppins.
 * All rules scoped under .calcsuite to avoid theme conflicts.
 */
.calcsuite-note{margin:14px 0 0;font-size:12.5px;line-height:1.6;color:var(--cs-muted);text-align:center}
.calcsuite{
	--cs-primary:#EA580C;
	--cs-primary-hover:#C2410C;
	--cs-bg:#F7F6F3;
	--cs-surface:#FFFFFF;
	--cs-text:#1C1917;
	--cs-muted:#78716C;
	--cs-border:#E5E2DC;
	--cs-tint:#FFF1E6;
	--cs-result-fg:#B45309;
	--cs-result-bg:#FEF3C7;
	--cs-shadow:0 4px 12px rgba(28,25,23,.08);
	--cs-mono:"JetBrains Mono",ui-monospace,SFMono-Regular,Menlo,monospace;
	font-family:"Poppins",system-ui,-apple-system,sans-serif;
	color:var(--cs-text);
	width:100%;
	max-width:1140px;
	margin:0 auto;
	box-sizing:border-box;
}
.calcsuite *,
.calcsuite *::before,
.calcsuite *::after{box-sizing:border-box}

.calcsuite-grid{
	display:grid;
	grid-template-columns:1fr 1fr;
	gap:20px;
	align-items:stretch;
}

.calcsuite-panel{
	background:var(--cs-surface);
	border:1px solid var(--cs-border);
	border-radius:16px;
	padding:24px;
}

.calcsuite-panel-title{
	font-size:18px;
	font-weight:600;
	line-height:1.35;
	margin:0 0 4px;
	color:var(--cs-text);
}
.calcsuite-panel-sub{
	font-size:13px;
	color:var(--cs-muted);
	margin:0 0 18px;
}

/* ---------- Fields ---------- */
.calcsuite-field{margin-bottom:16px}
.calcsuite-field label{
	display:block;
	font-size:13.5px;
	font-weight:500;
	margin-bottom:6px;
	color:var(--cs-text);
}
.calcsuite-optional{color:var(--cs-muted);font-weight:400}

.calcsuite-field input[type="number"]{
	width:100% !important;
	max-width:100% !important;
	min-width:0;
	display:block;
	box-sizing:border-box;
	height:46px;
	margin:0;
	padding:0 14px;
	font-family:inherit;
	font-size:15px;
	line-height:46px;
	color:var(--cs-text);
	background:var(--cs-bg);
	border:1px solid var(--cs-border);
	border-radius:10px;
	outline:none;
	transition:border-color .15s, box-shadow .15s;
	-moz-appearance:textfield;
	appearance:textfield;
}
.calcsuite-field input[type="number"]::-webkit-outer-spin-button,
.calcsuite-field input[type="number"]::-webkit-inner-spin-button{
	-webkit-appearance:none;margin:0;
}
.calcsuite-field input:focus{
	border-color:var(--cs-primary);
	box-shadow:0 0 0 3px rgba(234,88,12,.15);
}

.calcsuite-input-group{display:flex;gap:8px;align-items:stretch}
.calcsuite-input-group input[type="number"]{flex:1 1 auto;width:auto !important;min-width:0}
.calcsuite-input-group select{
	flex:0 0 auto;
	width:auto;
	min-width:78px;
	max-width:120px;
	box-sizing:border-box;
	height:46px;
	margin:0;
	padding:0 10px;
	font-family:inherit;
	font-size:14px;
	color:var(--cs-text);
	background:var(--cs-surface);
	border:1px solid var(--cs-border);
	border-radius:10px;
	cursor:pointer;
	outline:none;
	transition:border-color .15s;
}
.calcsuite-input-group select:focus{border-color:var(--cs-primary)}

/* ---------- Buttons ---------- */
.calcsuite-btn{
	width:100%;
	height:50px;
	margin-top:4px;
	font-family:inherit;
	font-size:15px;
	font-weight:600;
	color:#fff;
	background:var(--cs-primary);
	border:none;
	border-radius:12px;
	cursor:pointer;
	transition:background .15s, transform .08s;
}
.calcsuite-btn:hover{background:var(--cs-primary-hover)}
.calcsuite-btn:active{transform:scale(.99)}

.calcsuite-btn-reset{
	width:100%;
	height:42px;
	margin-top:8px;
	font-family:inherit;
	font-size:14px;
	font-weight:500;
	color:var(--cs-muted);
	background:transparent;
	border:1px solid var(--cs-border);
	border-radius:10px;
	cursor:pointer;
	transition:color .15s, border-color .15s;
}
.calcsuite-btn-reset:hover{color:var(--cs-primary);border-color:var(--cs-primary)}

/* ---------- Result panel ---------- */
.calcsuite-panel--result{
	display:flex;
	background:var(--cs-bg);
}
.calcsuite-result{width:100%;display:flex;align-items:center;justify-content:center}

.calcsuite-result-placeholder{text-align:center;color:var(--cs-muted)}
.calcsuite-result-badge{
	display:inline-block;
	font-family:var(--cs-mono);
	font-size:12px;
	font-weight:700;
	color:var(--cs-result-fg);
	background:var(--cs-result-bg);
	border-radius:999px;
	padding:6px 12px;
	margin-bottom:12px;
}
.calcsuite-result-placeholder p{font-size:14px;margin:0;max-width:240px}

.calcsuite-result-output{width:100%}

/* Primary result */
.calcsuite-primary{
	text-align:center;
	padding-bottom:18px;
	margin-bottom:18px;
	border-bottom:1px solid var(--cs-border);
}
.calcsuite-primary .calcsuite-primary-label{
	display:block;
	font-size:13px;
	font-weight:500;
	color:var(--cs-muted);
	margin-bottom:6px;
}
.calcsuite-primary .calcsuite-primary-value{
	font-family:var(--cs-mono);
	font-size:40px;
	font-weight:700;
	line-height:1.1;
	color:var(--cs-text);
	letter-spacing:-.01em;
}
.calcsuite-primary .calcsuite-primary-unit{
	font-size:16px;
	font-weight:500;
	color:var(--cs-muted);
	margin-left:4px;
}

/* Secondary rows */
.calcsuite-rows{list-style:none;margin:0;padding:0}
.calcsuite-rows li{
	display:flex;
	justify-content:space-between;
	align-items:baseline;
	gap:16px;
	padding:8px 0;
}
.calcsuite-rows li + li{border-top:1px solid var(--cs-border)}
.calcsuite-rows .calcsuite-row-label{font-size:14px;color:var(--cs-muted)}
.calcsuite-rows .calcsuite-row-value{
	font-family:var(--cs-mono);
	font-size:15px;
	font-weight:700;
	color:var(--cs-text);
	white-space:nowrap;
}
.calcsuite-rows .calcsuite-row-value.is-cost{color:var(--cs-result-fg)}

/* Formula / working */
.calcsuite-working{
	margin-top:18px;
	background:var(--cs-surface);
	border:1px solid var(--cs-border);
	border-radius:12px;
	padding:14px 16px;
}
.calcsuite-working-title{
	font-size:12px;
	font-weight:600;
	letter-spacing:.06em;
	text-transform:uppercase;
	color:var(--cs-muted);
	margin:0 0 8px;
}
.calcsuite-working code{
	display:block;
	font-family:var(--cs-mono);
	font-size:13px;
	line-height:1.7;
	color:var(--cs-text);
	background:none;
	white-space:normal;
	word-break:break-word;
}

/* Error text */
.calcsuite-error-msg{
	color:#B91C1C;
	font-size:14px;
	text-align:center;
}

/* Disclaimer */
.calcsuite-disclaimer{
	font-size:12px;
	line-height:1.6;
	color:var(--cs-muted);
	margin:16px 4px 0;
	text-align:center;
}

/* Admin-only shortcode error */
.calcsuite-error{
	color:#B91C1C;
	font-family:"Poppins",system-ui,sans-serif;
	padding:12px 16px;
	border:1px solid #FCA5A5;
	border-radius:8px;
	background:#FEF2F2;
}

/* ---------- Responsive ---------- */
@media (max-width:768px){
	.calcsuite-grid{grid-template-columns:1fr}
	.calcsuite-panel--result{min-height:180px}
	.calcsuite-primary .calcsuite-primary-value{font-size:34px}
}
