/* Ascensiona Client Framework
 * Reusable managed-site design system.
 * Semantic tokens are deliberately generic so each client build can be re-skinned
 * without changing template structure.
 */

@theme {
	--color-primary: #244f46;
	--color-primary-50: #f2f7f4;
	--color-primary-100: #dfece6;
	--color-primary-500: #3f786b;
	--color-primary-600: #2f655a;
	--color-primary-700: #244f46;
	--color-primary-900: #17352f;

	--color-secondary: #5c625e;
	--color-secondary-50: #fafaf7;
	--color-secondary-100: #f3f1ea;
	--color-secondary-200: #e6e1d5;
	--color-secondary-300: #d5ccbd;
	--color-secondary-500: #7c817d;
	--color-secondary-600: #5c625e;
	--color-secondary-700: #424945;
	--color-secondary-900: #202622;

	--color-accent: #bf7656;
	--color-accent-soft: #f5e7df;
	--color-neutral: #202622;
	--color-background: #fbfaf6;
	--color-surface: #ffffff;
	--color-line: #e4dfd4;

	--font-sans: "Public Sans", ui-sans-serif, system-ui, sans-serif;
	--font-serif: "Fraunces", Georgia, serif;
	--font-mono: ui-monospace, "SF Mono", Menlo, monospace;

	--text-sm: 0.875rem;
	--text-base: 1rem;
	--text-lg: 1.125rem;
	--text-xl: 1.25rem;
	--text-2xl: 1.5rem;
	--text-3xl: 1.875rem;
	--text-4xl: 2.5rem;
	--text-5xl: 3.75rem;

	--radius-sm: 0.5rem;
	--radius-md: 1rem;
	--radius-lg: 1.5rem;
	--radius-xl: 2rem;
}

@layer base {
	:root {
		--font-sans: "Public Sans", ui-sans-serif, system-ui, sans-serif;
		--font-serif: "Fraunces", Georgia, serif;
		--acf-page: #fbfaf6;
		--acf-surface: #ffffff;
		--acf-ink: #202622;
		--acf-muted: #66706b;
		--acf-primary: #244f46;
		--acf-primary-deep: #17352f;
		--acf-accent: #bf7656;
		--acf-line: #e4dfd4;
		--acf-radius: 24px;
		--acf-shadow: 0 24px 70px rgba(32,38,34,.10);
		--acf-max: 1180px;
	}

	html { scroll-behavior: smooth; }
	body {
		margin: 0;
		background: var(--acf-page);
		color: var(--acf-ink);
		font-family: var(--font-sans);
		text-rendering: optimizeLegibility;
		-webkit-font-smoothing: antialiased;
	}
	a { color: inherit; }
	img { max-width: 100%; height: auto; }
	::selection { background: #dfece6; color: #17352f; }
	:focus-visible { outline: 3px solid var(--acf-accent); outline-offset: 3px; }
}

@layer components {
	.acf-shell {
		width: min(calc(100% - 40px), var(--acf-max));
		margin-inline: auto;
	}
	.acf-section { padding-block: clamp(64px, 8vw, 112px); }
	.acf-eyebrow {
		display: inline-flex;
		align-items: center;
		gap: .5rem;
		font-size: .76rem;
		line-height: 1;
		font-weight: 800;
		letter-spacing: .14em;
		text-transform: uppercase;
		color: var(--acf-primary);
	}
	.acf-eyebrow::before {
		content: "";
		width: 28px;
		height: 2px;
		background: currentColor;
		border-radius: 999px;
	}
	.acf-display {
		font-family: var(--font-serif);
		font-weight: 550;
		letter-spacing: -.035em;
		line-height: .98;
	}
	.acf-lead {
		color: var(--acf-muted);
		font-size: clamp(1.05rem, 1.5vw, 1.22rem);
		line-height: 1.72;
	}
	.acf-button {
		display: inline-flex;
		align-items: center;
		justify-content: center;
		gap: .55rem;
		min-height: 50px;
		padding: .82rem 1.15rem;
		border-radius: 999px;
		font-weight: 800;
		text-decoration: none;
		transition: transform .18s ease, box-shadow .18s ease, background .18s ease;
	}
	.acf-button:hover { transform: translateY(-2px); }
	.acf-button--primary {
		background: var(--acf-primary);
		color: #fff;
		box-shadow: 0 12px 28px rgba(36,79,70,.18);
	}
	.acf-button--primary:hover { background: var(--acf-primary-deep); }
	.acf-button--ghost {
		border: 1px solid var(--acf-line);
		background: rgba(255,255,255,.72);
		color: var(--acf-ink);
	}
	.acf-card {
		background: var(--acf-surface);
		border: 1px solid var(--acf-line);
		border-radius: var(--acf-radius);
		box-shadow: 0 10px 34px rgba(32,38,34,.055);
	}
	.acf-skip {
		position: fixed;
		left: 16px;
		top: 16px;
		z-index: 9999;
		transform: translateY(-160%);
		background: #fff;
		color: #111;
		padding: 10px 14px;
		border-radius: 8px;
		box-shadow: var(--acf-shadow);
		font-weight: 800;
	}
	.acf-skip:focus { transform: translateY(0); }

	.acf-header {
		position: sticky;
		top: 0;
		z-index: 100;
		background: color-mix(in srgb, var(--acf-page) 90%, transparent);
		backdrop-filter: blur(16px);
		border-bottom: 1px solid color-mix(in srgb, var(--acf-line) 72%, transparent);
	}
	.acf-header__inner {
		min-height: 78px;
		display: flex;
		align-items: center;
		justify-content: space-between;
		gap: 24px;
	}
	.acf-brand {
		display: inline-flex;
		align-items: center;
		gap: 10px;
		text-decoration: none;
		font-weight: 850;
		letter-spacing: -.02em;
	}
	.acf-brand__mark {
		width: 34px;
		height: 34px;
		border-radius: 50%;
		display: grid;
		place-items: center;
		background: var(--acf-primary);
		color: #fff;
		font-family: var(--font-serif);
		font-size: 1.15rem;
	}
	.acf-nav ul {
		display: flex;
		align-items: center;
		gap: 6px;
		list-style: none;
		margin: 0;
		padding: 0;
	}
	.acf-nav a {
		display: inline-flex;
		padding: 10px 12px;
		border-radius: 999px;
		text-decoration: none;
		font-weight: 700;
		font-size: .92rem;
		color: #39423d;
	}
	.acf-nav a:hover,
	.acf-nav .current-menu-item > a { background: #fff; color: var(--acf-primary); }
	.acf-menu-button {
		display: none;
		border: 1px solid var(--acf-line);
		background: #fff;
		border-radius: 999px;
		width: 44px;
		height: 44px;
		align-items: center;
		justify-content: center;
		cursor: pointer;
	}

	.acf-hero {
		position: relative;
		overflow: clip;
		padding: clamp(72px, 10vw, 142px) 0 clamp(58px, 8vw, 110px);
	}
	.acf-hero::before {
		content: "";
		position: absolute;
		inset: 0;
		background:
			radial-gradient(circle at 88% 14%, rgba(191,118,86,.15), transparent 26%),
			radial-gradient(circle at 9% 80%, rgba(36,79,70,.12), transparent 26%);
		pointer-events: none;
	}
	.acf-hero__grid {
		position: relative;
		display: grid;
		grid-template-columns: minmax(0,1.08fr) minmax(320px,.92fr);
		gap: clamp(34px, 6vw, 82px);
		align-items: center;
	}
	.acf-hero__copy h1 {
		margin: 18px 0 20px;
		font-size: clamp(3.2rem, 7vw, 6.8rem);
		max-width: 10ch;
	}
	.acf-hero__actions {
		display: flex;
		gap: 10px;
		flex-wrap: wrap;
		margin-top: 28px;
	}
	.acf-hero__panel {
		min-height: 520px;
		position: relative;
		border-radius: 38px 38px 120px 38px;
		background: linear-gradient(145deg, #dfece6, #f5e7df 65%, #fff);
		box-shadow: var(--acf-shadow);
		overflow: hidden;
	}
	.acf-hero__panel::before,
	.acf-hero__panel::after {
		content: "";
		position: absolute;
		border-radius: 50%;
	}
	.acf-hero__panel::before {
		width: 330px;
		height: 330px;
		background: rgba(36,79,70,.22);
		right: -90px;
		top: -50px;
	}
	.acf-hero__panel::after {
		width: 220px;
		height: 220px;
		background: rgba(191,118,86,.18);
		left: 34px;
		bottom: 34px;
	}
	.acf-hero__panel-card {
		position: absolute;
		inset: auto 28px 28px 28px;
		z-index: 2;
		padding: 22px;
		background: rgba(255,255,255,.86);
		backdrop-filter: blur(14px);
		border: 1px solid rgba(255,255,255,.8);
		border-radius: 22px;
	}
	.acf-hero__panel-card strong {
		display: block;
		font-family: var(--font-serif);
		font-size: 1.65rem;
		line-height: 1.05;
	}
	.acf-hero__panel-card span {
		display: block;
		color: var(--acf-muted);
		margin-top: 8px;
		line-height: 1.5;
	}

	.acf-footer {
		margin-top: 72px;
		background: #18211d;
		color: #eef4f0;
	}
	.acf-footer__grid {
		display: grid;
		grid-template-columns: 1.2fr .8fr .8fr;
		gap: 42px;
		padding-block: 58px 38px;
	}
	.acf-footer p,
	.acf-footer a { color: #c9d2cd; }
	.acf-footer a:hover { color: #fff; }
	.acf-footer__meta {
		border-top: 1px solid rgba(255,255,255,.10);
		padding-block: 20px 28px;
		color: #aab7b0;
		font-size: .88rem;
	}
	.acf-footer__links {
		list-style: none;
		margin: 12px 0 0;
		padding: 0;
		display: grid;
		gap: 8px;
	}
	.acf-footer__links a { text-decoration: none; }
	.acf-hero__image {
		position: absolute;
		inset: 0;
		width: 100%;
		height: 100%;
		object-fit: cover;
	}
	.acf-hero__image + .acf-hero__panel-card {
		box-shadow: 0 12px 34px rgba(32,38,34,.12);
	}
	.acf-page-hero {
		padding: clamp(64px, 8vw, 108px) 0 42px;
		background: linear-gradient(180deg, rgba(223,236,230,.48), rgba(251,250,246,0));
	}
	.acf-page-hero h1 {
		margin: 16px 0 14px;
		font-size: clamp(2.9rem, 6vw, 5.6rem);
		max-width: 13ch;
	}
	.acf-page-hero .acf-lead { max-width: 720px; }
	.acf-page-media {
		margin-top: 10px;
		border-radius: 30px;
		overflow: hidden;
		box-shadow: var(--acf-shadow);
	}
	.acf-page-media img {
		display: block;
		width: 100%;
		max-height: 680px;
		object-fit: cover;
	}
	.acf-content {
		font-size: 1.06rem;
		line-height: 1.78;
	}
	.acf-content--narrow { max-width: 860px; }
	.acf-content > *:first-child { margin-top: 0; }
	.acf-content h2,
	.acf-content h3,
	.acf-content h4 {
		font-family: var(--font-serif);
		letter-spacing: -.02em;
		color: var(--acf-ink);
	}
	.acf-content a { color: var(--acf-primary); text-decoration-thickness: 1px; text-underline-offset: 3px; }
	.acf-article-shell { max-width: 860px; }
	.acf-post-nav {
		display: grid;
		grid-template-columns: 1fr 1fr;
		gap: 18px;
		padding-bottom: 40px;
	}
	.acf-post-nav div:last-child { text-align: right; }
	.acf-post-nav a { color: var(--acf-primary); font-weight: 750; text-decoration: none; }
	.acf-card-grid {
		display: grid;
		grid-template-columns: repeat(3, minmax(0,1fr));
		gap: 20px;
	}
	.acf-post-card { overflow: hidden; }
	.acf-post-card__media { display: block; aspect-ratio: 16 / 10; overflow: hidden; }
	.acf-post-card__media img { width: 100%; height: 100%; object-fit: cover; transition: transform .35s ease; }
	.acf-post-card:hover .acf-post-card__media img { transform: scale(1.025); }
	.acf-post-card__body { padding: 22px; }
	.acf-post-card__body > span { color: var(--acf-muted); font-size: .78rem; font-weight: 800; text-transform: uppercase; letter-spacing: .08em; }
	.acf-post-card h2 { font-family: var(--font-serif); font-size: 1.7rem; line-height: 1.12; margin: 10px 0; }
	.acf-post-card h2 a { text-decoration: none; }
	.acf-post-card p { color: var(--acf-muted); line-height: 1.65; }
	.acf-text-link { color: var(--acf-primary); font-weight: 800; text-decoration: none; }
	.acf-pagination { margin-top: 32px; }
	.acf-pagination .nav-links { display: flex; gap: 8px; flex-wrap: wrap; }
	.acf-pagination a,
	.acf-pagination span {
		display: inline-flex;
		min-width: 42px;
		height: 42px;
		align-items: center;
		justify-content: center;
		border: 1px solid var(--acf-line);
		border-radius: 999px;
		text-decoration: none;
	}
	.acf-empty-state,
	.acf-not-found__inner {
		max-width: 760px;
		padding: clamp(28px, 5vw, 54px);
	}
	.acf-not-found { min-height: 62vh; display: grid; place-items: center; }
	.acf-not-found__inner h1 { font-size: clamp(3rem, 7vw, 6.2rem); margin: 16px 0; max-width: 10ch; }
	.acf-search-box { margin-top: 28px; }
	.search-form { display: flex; gap: 8px; max-width: 560px; }
	.search-field {
		min-height: 48px;
		flex: 1;
		border: 1px solid var(--acf-line);
		border-radius: 999px;
		padding: 0 16px;
		background: #fff;
	}
	.search-submit {
		min-height: 48px;
		border: 0;
		border-radius: 999px;
		padding: 0 18px;
		background: var(--acf-primary);
		color: #fff;
		font-weight: 800;
	}

	@media (max-width: 860px) {
		.acf-shell { width: min(calc(100% - 28px), var(--acf-max)); }
		.acf-menu-button { display: inline-flex; }
		.acf-nav {
			display: none;
			position: absolute;
			left: 14px;
			right: 14px;
			top: calc(100% + 8px);
			background: #fff;
			border: 1px solid var(--acf-line);
			border-radius: 20px;
			padding: 10px;
			box-shadow: var(--acf-shadow);
		}
		.acf-nav.is-open { display: block; }
		.acf-header__cta { display: none; }
		.acf-nav ul { display: grid; gap: 2px; }
		.acf-nav a { display: flex; padding: 12px 14px; }
		.acf-hero__grid,
		.acf-footer__grid,
		.acf-card-grid { grid-template-columns: 1fr; }
		.acf-hero__copy h1 { max-width: 12ch; }
		.acf-hero__panel { min-height: 390px; }
		.acf-post-nav { grid-template-columns: 1fr; }
		.acf-post-nav div:last-child { text-align: left; }
	}
}

@keyframes acf-rise {
	from { opacity: 0; transform: translateY(14px); }
	to { opacity: 1; transform: translateY(0); }
}

@media (prefers-reduced-motion: no-preference) {
	.acf-reveal { animation: acf-rise .65s both; }
	.acf-reveal--2 { animation-delay: .12s; }
	.acf-reveal--3 { animation-delay: .22s; }
}