/* ACT Score Calculator - front-end styling, matching the app preview design */

.act-calc {
	--act-bg: #faf9f6;
	--act-fg: #0d0d24;
	--act-border: #e3e3ee;
	--act-card: #ffffff;
	--act-primary: #3733e0;
	--act-primary-foreground: #ffffff;
	--act-secondary: #f0f0f7;
	--act-muted-fg: #6f6f7d;
	--act-radius: 1rem;

	max-width: 640px;
	margin: 0 auto;
	padding: 32px 20px 48px;
	font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
	background: var(--act-bg);
	color: var(--act-fg);
	box-sizing: border-box;
}

.act-calc *,
.act-calc *::before,
.act-calc *::after {
	box-sizing: inherit;
}

/* Header */
.act-calc__header {
	display: flex;
	align-items: flex-start;
	justify-content: space-between;
	gap: 12px;
	margin-bottom: 28px;
}

.act-calc__title {
	font-size: 26px;
	font-weight: 800;
	letter-spacing: -0.01em;
	margin: 0 0 4px;
	color: var(--act-fg);
}

.act-calc__subtitle {
	font-size: 14px;
	color: var(--act-muted-fg);
	margin: 0;
}

.act-calc__reset-icon {
	flex-shrink: 0;
	width: 40px;
	height: 40px;
	display: flex;
	align-items: center;
	justify-content: center;
	border-radius: 999px;
	border: none;
	background: transparent;
	color: var(--act-muted-fg);
	cursor: pointer;
	transition: background-color 0.15s ease, color 0.15s ease;
}

.act-calc__reset-icon:hover {
	background: var(--act-secondary);
	color: var(--act-fg);
}

/* Text-glyph icons (avoids inline SVG, which some WP security/sanitizing
   setups strip from shortcode output) */
.act-calc__icon {
	display: inline-block;
	line-height: 1;
	font-size: 18px;
	font-weight: 600;
	font-style: normal;
	speak: none;
}

.act-calc__icon--lg {
	font-size: 30px;
}

/* Hero results card */
.act-calc__hero {
	position: relative;
	overflow: hidden;
	border-radius: 2rem;
	background: linear-gradient(135deg, #4744ea, #2f2ad1);
	color: var(--act-primary-foreground);
	box-shadow: 0 20px 40px -8px rgba(55, 51, 224, 0.3);
	min-height: 160px;
	display: flex;
	align-items: center;
	justify-content: center;
	padding: 32px;
	margin-bottom: 28px;
	transition: all 0.4s ease;
}

.act-calc__hero-empty,
.act-calc__hero-results {
	display: flex;
	flex-direction: column;
	align-items: center;
	text-align: center;
	width: 100%;
	position: relative;
	z-index: 1;
	animation: act-fade-in 0.35s ease;
}

.act-calc__hero-icon {
	width: 64px;
	height: 64px;
	border-radius: 999px;
	background: rgba(255, 255, 255, 0.12);
	display: flex;
	align-items: center;
	justify-content: center;
	margin-bottom: 16px;
	opacity: 0.9;
}

.act-calc__hero-empty p {
	font-weight: 500;
	font-size: 16px;
	max-width: 250px;
	line-height: 1.4;
	color: rgba(255, 255, 255, 0.85);
	margin: 0;
}

.act-calc__hero-label {
	font-size: 13px;
	font-weight: 600;
	letter-spacing: 0.04em;
	text-transform: uppercase;
	color: rgba(255, 255, 255, 0.8);
	margin-bottom: 8px;
}

.act-calc__hero-composite {
	font-size: 72px;
	font-weight: 900;
	letter-spacing: -0.03em;
	line-height: 1;
}

.act-calc__hero-percentile {
	margin-top: 20px;
	display: flex;
	flex-direction: column;
	align-items: center;
}

.act-calc__hero-percentile-label {
	font-size: 11px;
	font-weight: 600;
	letter-spacing: 0.08em;
	text-transform: uppercase;
	color: rgba(255, 255, 255, 0.7);
	margin-bottom: 4px;
}

.act-calc__hero-percentile-value {
	font-size: 22px;
	font-weight: 700;
}

@keyframes act-fade-in {
	from {
		opacity: 0;
		transform: translateY(6px);
	}
	to {
		opacity: 1;
		transform: translateY(0);
	}
}

/* Section / curve blocks */
.act-calc__block {
	margin-bottom: 24px;
}

.act-calc__block-header {
	display: flex;
	align-items: center;
	justify-content: space-between;
	padding: 0 4px;
	margin-bottom: 10px;
}

.act-calc__block-header h3 {
	font-size: 17px;
	font-weight: 700;
	margin: 0;
}

.act-calc__block-hint {
	font-size: 11px;
	font-weight: 600;
	color: var(--act-muted-fg);
	letter-spacing: 0.04em;
}

/* Section rows */
.act-calc__sections {
	display: flex;
	flex-direction: column;
	gap: 12px;
}

.act-calc__row {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	justify-content: space-between;
	gap: 16px;
	padding: 16px;
	background: var(--act-card);
	border: 1px solid var(--act-border);
	border-radius: 1rem;
	box-shadow: 0 2px 8px rgba(20, 20, 50, 0.03);
	transition: box-shadow 0.15s ease;
}

.act-calc__row:hover {
	box-shadow: 0 4px 14px rgba(20, 20, 50, 0.06);
}

.act-calc__row-label {
	display: flex;
	flex-direction: column;
}

.act-calc__row-name {
	font-size: 13px;
	font-weight: 700;
	letter-spacing: 0.03em;
	text-transform: uppercase;
}

.act-calc__row-max {
	font-size: 12px;
	color: var(--act-muted-fg);
	margin-top: 2px;
}

.act-calc__row-controls {
	display: flex;
	align-items: center;
	gap: 16px;
	margin-left: auto;
}

.act-calc__stepper {
	display: flex;
	align-items: center;
	gap: 2px;
	background: var(--act-secondary);
	border-radius: 0.85rem;
	padding: 4px;
}

.act-calc__step {
	width: 36px;
	height: 36px;
	display: flex;
	align-items: center;
	justify-content: center;
	border-radius: 0.65rem;
	border: none;
	background: transparent;
	color: var(--act-fg);
	cursor: pointer;
	transition: background-color 0.15s ease;
}

.act-calc__step:hover {
	background: var(--act-card);
}

.act-calc__step:disabled {
	opacity: 0.3;
	cursor: default;
	background: transparent;
}

.act-calc__input {
	width: 52px;
	height: 36px;
	text-align: center;
	font-weight: 700;
	font-size: 16px;
	background: transparent;
	border: none;
	color: var(--act-fg);
	-moz-appearance: textfield;
}

.act-calc__input:focus {
	outline: none;
}

.act-calc__input::-webkit-outer-spin-button,
.act-calc__input::-webkit-inner-spin-button {
	-webkit-appearance: none;
	margin: 0;
}

.act-calc__row-scaled {
	width: 48px;
	display: flex;
	flex-direction: column;
	align-items: center;
	flex-shrink: 0;
}

.act-calc__row-scaled-value {
	font-size: 22px;
	font-weight: 900;
	color: var(--act-primary);
	line-height: 1;
}

.act-calc__row-scaled-caption {
	font-size: 9px;
	font-weight: 600;
	letter-spacing: 0.06em;
	text-transform: uppercase;
	color: var(--act-muted-fg);
	margin-top: 3px;
}

.act-calc__row-scaled--empty .act-calc__row-scaled-value {
	color: var(--act-muted-fg);
	opacity: 0.4;
}

/* Curve profile buttons */
.act-calc__curves {
	display: flex;
	flex-direction: column;
	gap: 8px;
}

@media (min-width: 560px) {
	.act-calc__curves {
		flex-direction: row;
	}
}

.act-calc__curve {
	flex: 1;
	display: flex;
	flex-direction: column;
	align-items: flex-start;
	text-align: left;
	padding: 14px 16px;
	border-radius: 1rem;
	border: 1px solid var(--act-border);
	background: var(--act-card);
	cursor: pointer;
	transition: border-color 0.15s ease, background-color 0.15s ease, box-shadow 0.15s ease;
}

.act-calc__curve:hover {
	border-color: rgba(55, 51, 224, 0.4);
	background: var(--act-secondary);
}

.act-calc__curve--active {
	border-color: var(--act-primary);
	background: rgba(55, 51, 224, 0.05);
	box-shadow: 0 0 0 1px var(--act-primary);
}

.act-calc__curve-label {
	font-size: 13px;
	font-weight: 700;
	color: var(--act-fg);
}

.act-calc__curve--active .act-calc__curve-label {
	color: var(--act-primary);
}

.act-calc__curve-desc {
	font-size: 12px;
	color: var(--act-muted-fg);
	margin-top: 4px;
	line-height: 1.35;
}

/* Disclaimer */
.act-calc__disclaimer {
	margin-top: 8px;
	padding-top: 20px;
	border-top: 1px solid var(--act-border);
	font-size: 12px;
	line-height: 1.6;
	color: var(--act-muted-fg);
}

.act-calc__disclaimer strong {
	color: var(--act-fg);
}

@media (max-width: 420px) {
	.act-calc__row {
		flex-direction: column;
		align-items: stretch;
	}

	.act-calc__row-controls {
		margin-left: 0;
		justify-content: space-between;
		width: 100%;
	}
}
