/* PeptideSaver Peptide Calculator */
.psc-calc {
	--psc-primary: #244739;
	--psc-soft: #D1E3C9;
	--psc-ink: #1f2a24;
	--psc-line: #dfe5df;
	--psc-panel: #f6f8f5;
	--psc-warn: #9a3412;
	box-sizing: border-box;
	max-width: 1080px;
	margin: 0 auto;
	padding: 32px 28px;
	background: #ffffff;
	border: 1px solid var(--psc-line);
	border-radius: 16px;
	box-shadow: 0 6px 24px rgba(36, 71, 57, 0.08);
	color: var(--psc-ink);
	font-family: inherit;
	line-height: 1.4;
}

.psc-calc *,
.psc-calc *::before,
.psc-calc *::after {
	box-sizing: border-box;
}

.psc-calc .psc-top {
	display: grid;
	grid-template-columns: 1fr 1fr;
	gap: 36px;
	align-items: start;
}

.psc-calc .psc-q {
	margin: 0 0 18px;
	font-size: 14px;
	font-weight: 700;
	color: var(--psc-ink);
	text-transform: none;
	letter-spacing: 0;
}

/* Syringe cards */
.psc-calc .psc-syringes {
	display: flex;
	flex-direction: column;
	gap: 14px;
}

.psc-calc button.psc-syringe {
	-webkit-appearance: none;
	appearance: none;
	display: grid;
	grid-template-columns: 90px 1fr;
	align-items: center;
	width: 100%;
	min-height: 82px;
	margin: 0;
	padding: 14px 22px 14px 14px;
	background: #f7f8f7;
	border: 1px solid var(--psc-line);
	border-radius: 6px;
	box-shadow: none;
	color: var(--psc-ink);
	font: inherit;
	text-align: left;
	text-transform: none;
	letter-spacing: 0;
	cursor: pointer;
	transition: background-color 0.15s ease, border-color 0.15s ease;
}

.psc-calc button.psc-syringe:hover {
	background: #eef3ec;
	border-color: #b9ccbf;
	color: var(--psc-ink);
}

.psc-calc button.psc-syringe.is-active {
	background: var(--psc-soft);
	border-color: var(--psc-primary);
	color: var(--psc-ink);
}

.psc-calc .psc-syringe-label {
	font-size: 17px;
	font-weight: 700;
	color: var(--psc-ink);
}

.psc-calc .psc-syringe-img {
	display: flex;
	justify-content: center;
	align-items: center;
}

.psc-calc .psc-syringe-img img {
	display: block;
	width: 100%;
	max-width: 250px;
	height: auto;
	margin: 0;
	border: 0;
	box-shadow: none;
}

/* Right column */
.psc-calc .psc-col-inputs .psc-group + .psc-group {
	margin-top: 26px;
}

.psc-calc .psc-icon {
	margin-bottom: 8px;
	line-height: 0;
}

.psc-calc .psc-vial {
	display: inline-block;
}

.psc-calc .psc-col-inputs .psc-q {
	margin-bottom: 16px;
}

.psc-calc .psc-pills {
	display: flex;
	flex-wrap: wrap;
	gap: 10px;
}

.psc-calc button.psc-pill {
	-webkit-appearance: none;
	appearance: none;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	min-width: 66px;
	height: 38px;
	margin: 0;
	padding: 0 18px;
	background: #ffffff;
	border: 1px solid var(--psc-primary);
	border-radius: 999px;
	box-shadow: none;
	color: var(--psc-primary);
	font: inherit;
	font-size: 14px;
	font-weight: 500;
	line-height: 1;
	text-transform: none;
	letter-spacing: 0;
	white-space: nowrap;
	cursor: pointer;
	transition: background-color 0.15s ease, color 0.15s ease;
}

.psc-calc button.psc-pill:hover {
	background: var(--psc-soft);
	color: var(--psc-primary);
}

.psc-calc button.psc-pill.is-active {
	background: var(--psc-primary);
	border-color: var(--psc-primary);
	color: #ffffff;
}

.psc-calc button.psc-pill:focus-visible,
.psc-calc button.psc-syringe:focus-visible,
.psc-calc .psc-other-input:focus-visible {
	outline: 2px solid var(--psc-primary);
	outline-offset: 2px;
}

/* Other input */
.psc-calc .psc-other {
	display: flex;
	align-items: center;
	gap: 8px;
	margin-top: 12px;
}

.psc-calc .psc-other[hidden] {
	display: none;
}

.psc-calc input.psc-other-input {
	width: 150px;
	height: 38px;
	margin: 0;
	padding: 0 14px;
	background: #ffffff;
	border: 1px solid var(--psc-primary);
	border-radius: 999px;
	box-shadow: none;
	color: var(--psc-ink);
	font: inherit;
	font-size: 14px;
}

.psc-calc .psc-other-unit {
	font-size: 14px;
	font-weight: 600;
	color: var(--psc-primary);
}

/* Result panel */
.psc-calc .psc-result {
	margin-top: 40px;
	padding: 24px 24px 20px;
	background: var(--psc-panel);
	border: 1px solid #e8ece7;
	border-radius: 8px;
}

.psc-calc .psc-banner {
	padding: 14px 20px;
	background: linear-gradient(90deg, var(--psc-primary) 0%, #336650 100%);
	border: 1px solid var(--psc-primary);
	border-radius: 10px;
	box-shadow: 0 4px 14px rgba(36, 71, 57, 0.22);
	text-align: center;
	transition: background 0.2s ease;
}

.psc-calc .psc-banner-text {
	margin: 0;
	color: #ffffff;
	font-size: 21px;
	font-weight: 700;
	line-height: 1.35;
}

.psc-calc .psc-hl {
	color: var(--psc-soft);
	font-size: 1.2em;
	text-decoration: underline;
	text-decoration-thickness: 2px;
	text-underline-offset: 4px;
	white-space: nowrap;
}

.psc-calc.is-over .psc-banner {
	background: var(--psc-warn);
	border-color: var(--psc-warn);
	box-shadow: 0 4px 14px rgba(154, 52, 18, 0.22);
}

.psc-calc.is-over .psc-hl {
	color: #ffffff;
}

.psc-calc.is-empty .psc-banner {
	background: #5d6b63;
	border-color: #5d6b63;
	box-shadow: none;
}

.psc-calc.is-empty .psc-banner-text {
	font-size: 17px;
	font-weight: 600;
}

/* Scale */
.psc-calc .psc-scale {
	max-width: 720px;
	margin: 26px auto 0;
}

.psc-calc .psc-ruler {
	position: relative;
	height: 54px;
	background: #e9ecea;
	border: 1px solid #cfd6d1;
	overflow: hidden;
}

.psc-calc .psc-fill {
	position: absolute;
	top: 0;
	bottom: 0;
	left: 0;
	width: 0;
	background: linear-gradient(90deg, var(--psc-primary) 0%, #3b7a5f 100%);
	transition: width 0.35s ease;
}

.psc-calc.is-over .psc-fill {
	background: var(--psc-warn);
}

.psc-calc .psc-ticks {
	position: absolute;
	inset: 0;
	pointer-events: none;
}

.psc-calc .psc-tick {
	position: absolute;
	top: 0;
	width: 1px;
	height: 14px;
	background: #1f2a24;
	transform: translateX(-0.5px);
}

.psc-calc .psc-tick.is-major {
	width: 2px;
	height: 26px;
	transform: translateX(-1px);
}

.psc-calc .psc-labels {
	position: relative;
	height: 22px;
	margin-top: 6px;
}

.psc-calc .psc-label {
	position: absolute;
	top: 0;
	transform: translateX(-50%);
	font-size: 13px;
	font-weight: 700;
	color: var(--psc-ink);
}

.psc-calc .psc-meta {
	margin: 14px 0 0;
	font-size: 13px;
	text-align: center;
	color: #4a5a51;
}

.psc-calc .psc-meta:empty {
	display: none;
}

.psc-calc .psc-rotate {
	display: none;
	margin: 10px 0 0;
	font-size: 12px;
	text-align: center;
	color: #5d6b63;
}

/* Responsive */
@media (max-width: 900px) {
	.psc-calc .psc-top {
		grid-template-columns: 1fr;
		gap: 30px;
	}
}

@media (max-width: 600px) {
	.psc-calc {
		padding: 22px 16px;
		border-radius: 12px;
	}

	.psc-calc button.psc-syringe {
		grid-template-columns: 64px 1fr;
		padding: 12px 14px 12px 12px;
		min-height: 70px;
	}

	.psc-calc .psc-syringe-label {
		font-size: 15px;
	}

	.psc-calc button.psc-pill {
		min-width: 0;
		height: 36px;
		padding: 0 14px;
		font-size: 13px;
	}

	.psc-calc .psc-result {
		margin-top: 28px;
		padding: 18px 12px 16px;
	}

	.psc-calc .psc-banner {
		padding: 12px 14px;
	}

	.psc-calc .psc-banner-text {
		font-size: 17px;
	}

	.psc-calc .psc-label {
		font-size: 11px;
	}

	.psc-calc .psc-rotate {
		display: block;
	}
}

@media (prefers-reduced-motion: reduce) {
	.psc-calc .psc-fill,
	.psc-calc .psc-banner,
	.psc-calc button.psc-pill,
	.psc-calc button.psc-syringe {
		transition: none;
	}
}
