/* Evoconsulting: "Evo Terminal" design, colors from the logo. */

@font-face {
	font-family: "Geist";
	src: url("../fonts/geist.woff2") format("woff2");
	font-weight: 100 900;
	font-style: normal;
	font-display: swap;
}
@font-face {
	font-family: "Geist Mono";
	src: url("../fonts/geist-mono.woff2") format("woff2");
	font-weight: 100 900;
	font-style: normal;
	font-display: swap;
}

:root {
	--bg: #F4F5F4;
	--surface: #FFFFFF;
	--line: #DDE0DD;
	--ink: #26282B;
	--muted: #6D6E71;
	--accent: #78BE46;
	--accent-deep: #3D7F22;
	--accent-soft: #EAF4E2;
	--graphite: #1F2123;
	--graphite-2: #2A2D30;
	--graphite-line: #3A3E42;
	--graphite-ink: #EDEEEF;
	--graphite-muted: #A3A7AC;

	--font: "Geist", ui-sans-serif, system-ui, -apple-system, "Segoe UI", sans-serif;
	--mono: "Geist Mono", ui-monospace, "SFMono-Regular", Menlo, monospace;

	--r-sm: 10px;
	--r-md: 18px;
	--r-pill: 999px;

	--container: 1200px;
	--gutter: clamp(16px, 4vw, 32px);
	--section: clamp(80px, 11vw, 120px);
	--shadow: 0 1px 2px rgba(38, 40, 43, .04), 0 12px 32px -12px rgba(38, 40, 43, .14);
	--ease: cubic-bezier(.2, .7, .2, 1);
	--header-h: 72px;
}

/* ---------- Base ---------- */
*, *::before, *::after { box-sizing: border-box; }
:where(html) { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; scroll-padding-top: calc(var(--header-h) + 16px); }
:where(body) {
	margin: 0;
	background: var(--bg);
	color: var(--ink);
	font-family: var(--font);
	font-size: 17px;
	line-height: 1.6;
	-webkit-font-smoothing: antialiased;
	text-rendering: optimizeLegibility;
}
:where(h1, h2, h3, h4, p, ul, ol, figure, blockquote, dl) { margin: 0; }
:where(ul, ol) { padding: 0; list-style: none; }
:where(img, svg, canvas) { display: block; max-width: 100%; }
:where(img) { height: auto; }
:where(a) { color: inherit; }
:where(button, input, select, textarea) { font: inherit; color: inherit; }
:where(h1, h2, h3) { font-weight: 650; letter-spacing: -.02em; line-height: 1.08; text-wrap: balance; }
:where(p) { text-wrap: pretty; }

:focus-visible { outline: 2px solid var(--accent-deep); outline-offset: 3px; border-radius: 4px; }
.hero :focus-visible, .site-header :focus-visible, .site-footer :focus-visible, .band :focus-visible { outline-color: var(--accent); }

.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0; }
.skip-link { position: absolute; left: 16px; top: -60px; z-index: 100; background: var(--accent); color: var(--ink); padding: 10px 16px; border-radius: var(--r-sm); font-weight: 600; text-decoration: none; transition: top .2s; }
.skip-link:focus { top: 12px; }

.container { width: 100%; max-width: calc(var(--container) + var(--gutter) * 2); margin-inline: auto; padding-inline: var(--gutter); }
.container--narrow { max-width: calc(820px + var(--gutter) * 2); }
.container--text { max-width: calc(720px + var(--gutter) * 2); }
.section { padding-block: var(--section); }
.section__title { font-size: clamp(32px, 4.4vw, 52px); max-width: 18ch; }

.icon { width: 22px; height: 22px; flex: none; }

/* ---------- Buttons ---------- */
.btn {
	display: inline-flex; align-items: center; justify-content: center; gap: 10px;
	min-height: 46px; padding: 0 22px;
	border-radius: var(--r-pill); border: 1px solid transparent;
	font-size: 15px; font-weight: 600; line-height: 1; text-decoration: none; white-space: nowrap;
	cursor: pointer;
	transition: transform .25s var(--ease), background-color .2s, border-color .2s, color .2s, box-shadow .25s;
}
.btn .icon { width: 18px; height: 18px; }
.btn:active { transform: translateY(1px) scale(.98); }
.btn--lg { min-height: 54px; padding: 0 28px; font-size: 16px; }
.btn--block { width: 100%; }
.btn--primary { background: var(--accent); color: var(--ink); }
.btn--primary:hover { background: #86C957; box-shadow: 0 10px 30px -10px rgba(120, 190, 70, .65); transform: translateY(-1px); }
.btn--ghost-dark { color: var(--graphite-ink); border-color: var(--graphite-line); background: transparent; }
.btn--ghost-dark:hover { border-color: var(--accent); color: #fff; }
.btn--outline { color: var(--ink); border-color: var(--ink); background: transparent; }
.btn--outline:hover { background: var(--ink); color: #fff; }

/* ---------- Header ---------- */
.site-header {
	position: fixed; inset: 0 0 auto; z-index: 50;
	height: var(--header-h);
	background: rgba(31, 33, 35, .72);
	-webkit-backdrop-filter: saturate(140%) blur(14px);
	backdrop-filter: saturate(140%) blur(14px);
	border-bottom: 1px solid transparent;
	transition: background-color .3s, border-color .3s, transform .35s var(--ease);
}
.site-header.is-scrolled { background: rgba(31, 33, 35, .9); border-bottom-color: rgba(255, 255, 255, .06); }
.site-header.is-hidden { transform: translateY(-100%); }
.site-header__inner { height: 100%; display: flex; align-items: center; gap: 28px; }
.logo { display: inline-flex; flex: none; border-radius: 6px; }
.logo__img { height: 46px; width: auto; }
.logo__text { color: #fff; font-weight: 650; font-size: 20px; }
.admin-bar .site-header { top: 32px; }
@media (max-width: 782px) { .admin-bar .site-header { top: 46px; } }
.site-nav { display: flex; align-items: center; gap: 28px; margin-left: auto; }
.site-nav ul { display: flex; gap: 4px; }
.site-nav ul a {
	display: block; padding: 8px 12px; border-radius: var(--r-pill);
	color: var(--graphite-muted); font-size: 15px; font-weight: 500; text-decoration: none;
	transition: color .2s, background-color .2s;
}
.site-nav ul a:hover, .site-nav ul a.is-active { color: #fff; background: rgba(255, 255, 255, .07); }
.site-nav__phone { display: inline-flex; align-items: center; gap: 8px; color: var(--graphite-ink); font-size: 15px; font-weight: 500; text-decoration: none; font-variant-numeric: tabular-nums; }
.site-nav__phone .icon { width: 18px; height: 18px; color: var(--accent); }
.site-header__cta { min-height: 42px; padding: 0 18px; font-size: 14px; }
.nav-toggle { display: none; }

@media (max-width: 1080px) {
	.site-nav__phone { display: none; }
}
@media (max-width: 920px) {
	.site-header__inner { gap: 12px; }
	.site-header__cta { margin-left: auto; }
	.nav-toggle {
		display: inline-flex; align-items: center; justify-content: center;
		width: 44px; height: 44px; border-radius: 50%;
		background: transparent; border: 1px solid var(--graphite-line); cursor: pointer;
	}
	.nav-toggle__bars, .nav-toggle__bars::before, .nav-toggle__bars::after { display: block; width: 18px; height: 2px; background: var(--graphite-ink); border-radius: 2px; transition: transform .3s var(--ease), opacity .2s; }
	.nav-toggle__bars { position: relative; }
	.nav-toggle__bars::before, .nav-toggle__bars::after { content: ""; position: absolute; left: 0; }
	.nav-toggle__bars::before { top: -6px; }
	.nav-toggle__bars::after { top: 6px; }
	.nav-open .nav-toggle__bars { background: transparent; }
	.nav-open .nav-toggle__bars::before { transform: translateY(6px) rotate(45deg); }
	.nav-open .nav-toggle__bars::after { transform: translateY(-6px) rotate(-45deg); }

	.site-nav {
		position: fixed; inset: var(--header-h) 0 auto; margin: 0;
		flex-direction: column; align-items: stretch; gap: 16px;
		padding: 16px var(--gutter) 28px;
		background: var(--graphite); border-bottom: 1px solid var(--graphite-line);
		opacity: 0; visibility: hidden; transform: translateY(-8px);
		transition: opacity .25s, transform .3s var(--ease), visibility 0s .3s;
	}
	.nav-open .site-nav { opacity: 1; visibility: visible; transform: none; transition: opacity .25s, transform .3s var(--ease); }
	.site-nav ul { flex-direction: column; }
	.site-nav ul a { padding: 14px 4px; border-radius: 0; font-size: 20px; color: var(--graphite-ink); border-bottom: 1px solid var(--graphite-line); }
	.site-nav__phone { display: inline-flex; padding-top: 8px; }
}
@media (max-width: 480px) {
	.site-header__cta { display: none; }
	.nav-toggle { margin-left: auto; }
}

/* ---------- Hero ---------- */
.hero {
	position: relative; isolation: isolate; overflow: hidden;
	background:
		radial-gradient(60% 70% at 85% 30%, rgba(120, 190, 70, .14), transparent 60%),
		var(--graphite);
	color: var(--graphite-ink);
	padding: calc(var(--header-h) + clamp(40px, 7vw, 96px)) 0 clamp(64px, 8vw, 104px);
	min-height: min(100svh, 880px);
	display: flex; align-items: center;
}
.hero__grid { position: absolute; inset: 0; z-index: -1; width: 100%; height: 100%; }
.hero__inner { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.05fr); gap: clamp(32px, 5vw, 72px); align-items: center; }
.hero__title {
	font-size: clamp(44px, 6.4vw, 84px);
	line-height: 1.02; letter-spacing: -.035em; font-weight: 680;
	color: #fff; max-width: 11ch;
}
.hero__title .ch { display: inline-block; }
.hero__title .ch.is-scrambling { color: var(--accent); font-family: var(--mono); font-weight: 500; }
.hero__lede { margin-top: 24px; max-width: 44ch; font-size: clamp(17px, 1.5vw, 19px); color: var(--graphite-muted); }
.hero__actions { margin-top: 36px; display: flex; flex-wrap: wrap; gap: 12px; }

/* Code editor */
.editor {
	position: relative;
	background: rgba(42, 45, 48, .88);
	border: 1px solid var(--graphite-line);
	border-radius: var(--r-md);
	box-shadow: 0 40px 80px -30px rgba(0, 0, 0, .55), 0 0 0 1px rgba(120, 190, 70, .04);
	overflow: hidden;
	transform: perspective(1400px) rotateY(-6deg) rotateX(2deg);
	transform-origin: left center;
	transition: transform .8s var(--ease);
	will-change: transform;
}
.editor:hover { transform: perspective(1400px) rotateY(-2deg) rotateX(1deg); }
.editor__bar { display: flex; align-items: center; gap: 14px; padding: 12px 16px; border-bottom: 1px solid var(--graphite-line); background: rgba(31, 33, 35, .6); }
.editor__dots { display: inline-flex; gap: 7px; }
.editor__dots i { width: 11px; height: 11px; border-radius: 50%; background: #45494E; }
.editor__dots i:first-child { background: #5B5F64; }
.editor__file { font-family: var(--mono); font-size: 13px; color: var(--graphite-muted); }
.editor__code {
	margin: 0; padding: 20px 22px 8px;
	min-height: 292px;
	font-family: var(--mono); font-size: clamp(12.5px, 1.05vw, 14.5px); line-height: 1.75;
	color: var(--graphite-ink);
	white-space: pre-wrap; word-break: break-word;
	counter-reset: ln;
}
.editor__code code { font: inherit; }
.tok-k { color: var(--accent); }
.tok-s { color: #C9E4B4; }
.tok-c { color: #7E848A; font-style: italic; }
.tok-f { color: #FFFFFF; font-weight: 600; }
.tok-p { color: #8E949A; }
.tok-n { color: #D4D6D9; }
.caret {
	display: inline-block; width: 8px; height: 1.15em; margin-left: 1px;
	vertical-align: text-bottom; background: var(--accent);
	animation: blink 1s steps(2, start) infinite;
}
.editor.is-done .caret { opacity: 0; animation: none; }
@keyframes blink { to { visibility: hidden; } }

.editor__term {
	min-height: 120px;
	padding: 14px 22px 20px;
	border-top: 1px solid var(--graphite-line);
	background: rgba(31, 33, 35, .7);
	font-family: var(--mono); font-size: 13px; line-height: 1.8; color: var(--graphite-muted);
}
.term-line { display: flex; gap: 10px; opacity: 0; transform: translateY(4px); animation: termIn .35s var(--ease) forwards; }
.term-line .ok { color: var(--accent); }
.term-line.is-final { color: #fff; font-weight: 500; }
.term-line.is-final .ok { display: inline-block; animation: pulse 1.6s ease-out 1; }
@keyframes termIn { to { opacity: 1; transform: none; } }
@keyframes pulse { 0% { transform: scale(1); } 30% { transform: scale(1.5); } 100% { transform: scale(1); } }

@media (max-width: 920px) {
	.hero { min-height: 0; }
	.hero__inner { grid-template-columns: 1fr; }
	.editor { transform: none; }
	.editor:hover { transform: none; }
}

/* ---------- Figures ---------- */
.figures { background: var(--surface); border-bottom: 1px solid var(--line); }
.figures__grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); }
.figure { padding: 36px 24px 36px 0; }
.figure + .figure { padding-left: 28px; border-left: 1px solid var(--line); }
.figure__num { font-size: clamp(36px, 4.2vw, 56px); font-weight: 650; letter-spacing: -.035em; line-height: 1; font-variant-numeric: tabular-nums; }
.figure__label { margin-top: 10px; font-size: 15px; color: var(--muted); max-width: 24ch; line-height: 1.45; }
@media (max-width: 860px) {
	.figures__grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
	.figure { padding: 28px 16px 28px 0; }
	.figure + .figure { padding-left: 20px; }
	.figure:nth-child(3) { padding-left: 0; border-left: 0; border-top: 1px solid var(--line); }
	.figure:nth-child(4) { border-top: 1px solid var(--line); }
}

/* ---------- Services bento ---------- */
.services .section__title { margin-bottom: clamp(36px, 5vw, 56px); }
.bento {
	display: grid;
	grid-template-columns: repeat(12, minmax(0, 1fr));
	gap: 16px;
}
.tile {
	--mx: 50%; --my: 50%;
	position: relative; overflow: hidden; isolation: isolate;
	background: var(--surface);
	border: 1px solid var(--line);
	border-radius: var(--r-md);
	padding: clamp(24px, 2.6vw, 34px);
	display: flex; flex-direction: column; gap: 12px;
	transition: transform .4s var(--ease), box-shadow .4s var(--ease), border-color .3s;
}
.tile::after {
	content: ""; position: absolute; inset: 0; z-index: -1; pointer-events: none;
	background: radial-gradient(420px circle at var(--mx) var(--my), rgba(120, 190, 70, .16), transparent 60%);
	opacity: 0; transition: opacity .35s;
}
.tile:hover { transform: translateY(-3px); box-shadow: var(--shadow); border-color: #CDD3CD; }
.tile:hover::after { opacity: 1; }
.tile h3 { font-size: clamp(21px, 1.9vw, 25px); }
.tile p { color: var(--muted); font-size: 16px; max-width: 46ch; }
.tile__icon {
	display: inline-flex; align-items: center; justify-content: center;
	width: 46px; height: 46px; border-radius: 12px;
	background: var(--accent-soft); color: var(--accent-deep);
	margin-bottom: 8px;
}

.tile--hero { grid-column: span 7; grid-row: span 2; min-height: 460px; justify-content: flex-end; background: var(--graphite); border-color: var(--graphite); color: #fff; }
.tile--hero .tile__media { position: absolute; inset: 0; z-index: -2; }
.tile--hero .tile__media img { width: 100%; height: 100%; object-fit: cover; transform: scale(1.04); transition: transform 1.2s var(--ease); }
.tile--hero:hover .tile__media img { transform: scale(1.09); }
.tile--hero .tile__media::after { content: ""; position: absolute; inset: 0; background: linear-gradient(180deg, rgba(31, 33, 35, .15) 0%, rgba(31, 33, 35, .55) 45%, rgba(31, 33, 35, .94) 100%); }
.tile--hero::after { background: radial-gradient(420px circle at var(--mx) var(--my), rgba(120, 190, 70, .22), transparent 60%); }
.tile--hero h3 { font-size: clamp(30px, 3.2vw, 42px); color: #fff; }
.tile--hero p { color: #D2D5D8; font-size: 17px; }
.tile--hero .tile__icon { background: var(--accent); color: var(--ink); }
.tile--hero:hover { border-color: var(--graphite); }

.tile--network, .tile--reverse { grid-column: span 5; }
.tile__hex {
	margin-top: auto; padding-top: 8px;
	font-family: var(--mono); font-size: 12.5px; letter-spacing: .04em; color: #9A9DA1;
	white-space: nowrap; overflow: hidden; text-overflow: clip;
}
.tile__hex .hl { color: var(--accent-deep); font-weight: 600; }

.tile--conception { grid-column: span 5; }
.tile--analytics { grid-column: span 7; flex-direction: row; align-items: flex-end; gap: 28px; }
.tile--analytics > div:first-child { flex: 1 1 60%; display: flex; flex-direction: column; gap: 12px; }
.bars { flex: 1 1 40%; display: flex; align-items: flex-end; gap: 8px; height: 150px; }
.bars span {
	flex: 1; height: 100%; border-radius: 6px 6px 3px 3px;
	background: linear-gradient(180deg, var(--accent) 0%, #A9D68A 100%);
	transform: scaleY(var(--h)); transform-origin: bottom;
	transition: transform 1s var(--ease);
}
.bars span:nth-child(even) { background: linear-gradient(180deg, var(--accent-deep) 0%, #6DAA4A 100%); }
.js .tile--analytics:not(.is-in) .bars span { transform: scaleY(.06); }
.tile--analytics.is-in .bars span:nth-child(2) { transition-delay: .06s; }
.tile--analytics.is-in .bars span:nth-child(3) { transition-delay: .12s; }
.tile--analytics.is-in .bars span:nth-child(4) { transition-delay: .18s; }
.tile--analytics.is-in .bars span:nth-child(5) { transition-delay: .24s; }
.tile--analytics.is-in .bars span:nth-child(6) { transition-delay: .3s; }
.tile--analytics.is-in .bars span:nth-child(7) { transition-delay: .36s; }

.tile--planning { grid-column: span 12; flex-direction: row; align-items: center; gap: clamp(24px, 4vw, 56px); background: var(--accent-soft); border-color: #D6E8C8; }
.tile__planning-text { flex: 1 1 42%; display: flex; flex-direction: column; gap: 12px; }
.tile--planning .tile__icon { background: var(--surface); }
.tile--planning p { color: #4B5A44; }
.plan { flex: 1 1 58%; display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); counter-reset: step; position: relative; }
.plan::before { content: ""; position: absolute; left: 6px; right: 6px; top: 6px; height: 2px; background: #C5DDB2; }
.plan::after {
	content: ""; position: absolute; left: 6px; right: 6px; top: 6px; height: 2px;
	background: var(--accent-deep); transform-origin: left; transform: scaleX(1);
	transition: transform 1.6s var(--ease) .2s;
}
.js .tile--planning:not(.is-in) .plan::after { transform: scaleX(0); }
.plan li { position: relative; padding-top: 30px; padding-right: 12px; font-size: 15px; font-weight: 550; color: var(--ink); }
.plan li::before {
	content: ""; position: absolute; left: 0; top: 0;
	width: 14px; height: 14px; border-radius: 50%;
	background: var(--surface); border: 3px solid var(--accent-deep);
	z-index: 1;
}

@media (max-width: 980px) {
	.tile--hero { grid-column: span 12; grid-row: auto; min-height: 400px; }
	.tile--network, .tile--reverse { grid-column: span 6; }
	.tile--conception { grid-column: span 12; }
	.tile--analytics { grid-column: span 12; }
}
@media (max-width: 680px) {
	.bento { gap: 12px; }
	.tile--network, .tile--reverse { grid-column: span 12; }
	.tile--analytics, .tile--planning { flex-direction: column; align-items: stretch; }
	.bars { height: 110px; }
	.plan { grid-template-columns: 1fr; gap: 18px; }
	.plan::before, .plan::after { left: 6px; right: auto; top: 6px; bottom: 6px; width: 2px; height: auto; }
	.plan::after { transform-origin: top; }
	.js .tile--planning:not(.is-in) .plan::after { transform: scaleY(0); }
	.plan li { padding-top: 0; padding-left: 30px; }
}

/* ---------- Approach ---------- */
.approach { padding-top: 0; }
.approach__grid { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: clamp(40px, 6vw, 88px); align-items: center; }
.approach__media { position: relative; margin-left: calc(-1 * max(var(--gutter), (100vw - var(--container)) / 2)); }
.approach__media img { width: 100%; aspect-ratio: 4 / 3.4; object-fit: cover; border-radius: 0 var(--r-md) var(--r-md) 0; }
.approach__text { display: flex; flex-direction: column; align-items: flex-start; gap: 22px; }
.approach__text > p { color: var(--muted); max-width: 52ch; }
.approach .approach__quote { color: var(--ink); font-size: clamp(19px, 1.7vw, 22px); line-height: 1.5; font-style: italic; padding-left: 20px; border-left: 3px solid var(--accent); }
.checks { display: grid; gap: 10px; }
.checks li { display: flex; align-items: center; gap: 12px; font-weight: 550; }
.checks .icon { width: 26px; height: 26px; padding: 5px; border-radius: 50%; background: var(--accent); color: var(--ink); stroke-width: 2.4; }
@media (max-width: 860px) {
	.approach__grid { grid-template-columns: 1fr; }
	.approach__media { margin-left: calc(-1 * var(--gutter)); margin-right: calc(-1 * var(--gutter)); }
	.approach__media img { border-radius: 0; aspect-ratio: 16 / 11; }
}

/* ---------- Statement band ---------- */
.band {
	position: relative; isolation: isolate; overflow: hidden;
	background: var(--graphite); color: #fff;
	padding-block: clamp(96px, 13vw, 168px);
}
.band::before {
	content: ""; position: absolute; inset: -10% 0; z-index: -2;
	background: var(--band-img) center / cover no-repeat;
	transform: translate3d(0, var(--parallax, 0px), 0) scale(1.08);
	will-change: transform;
}
.band::after { content: ""; position: absolute; inset: 0; z-index: -1; background: linear-gradient(90deg, rgba(31, 33, 35, .95) 0%, rgba(31, 33, 35, .82) 50%, rgba(31, 33, 35, .45) 100%); }
.band__inner { display: grid; gap: 24px; }
.band__title { font-size: clamp(36px, 5.4vw, 68px); max-width: 15ch; letter-spacing: -.035em; line-height: 1.04; }
.band__text { max-width: 56ch; font-size: clamp(17px, 1.5vw, 19px); color: #CFD2D5; }

/* ---------- Case studies ---------- */
.cases { overflow: hidden; }
.cases__head { display: flex; align-items: flex-end; justify-content: space-between; gap: 24px; margin-bottom: clamp(32px, 4vw, 48px); }
.cases__nav { display: flex; gap: 10px; }
.round-btn {
	display: inline-flex; align-items: center; justify-content: center;
	width: 52px; height: 52px; border-radius: 50%;
	border: 1px solid var(--line); background: var(--surface); color: var(--ink); cursor: pointer;
	transition: background-color .2s, color .2s, border-color .2s, transform .2s var(--ease);
}
.round-btn:hover { background: var(--ink); color: #fff; border-color: var(--ink); }
.round-btn:active { transform: scale(.94); }
.round-btn[disabled] { opacity: .4; cursor: default; background: var(--surface); color: var(--ink); border-color: var(--line); }
.cases__track {
	display: flex; gap: 20px;
	overflow-x: auto; scroll-snap-type: x mandatory; scrollbar-width: none;
	padding-inline: max(var(--gutter), calc((100vw - var(--container)) / 2));
	scroll-padding-inline: max(var(--gutter), calc((100vw - var(--container)) / 2));
	padding-bottom: 8px;
	cursor: grab;
}
.cases__track::-webkit-scrollbar { display: none; }
.cases__track.is-dragging { cursor: grabbing; scroll-snap-type: none; }
.cases__track.is-dragging .case { pointer-events: none; }
.case { flex: 0 0 clamp(280px, 38vw, 470px); scroll-snap-align: start; }
.case__img { border-radius: var(--r-md); overflow: hidden; background: var(--graphite); }
.case__img img { width: 100%; aspect-ratio: 4 / 3; object-fit: cover; transition: transform .9s var(--ease), opacity .4s; user-select: none; -webkit-user-drag: none; }
.case:hover .case__img img { transform: scale(1.05); }
.case__title { margin-top: 18px; font-size: clamp(20px, 1.8vw, 24px); max-width: 22ch; letter-spacing: -.015em; }

/* ---------- Team ---------- */
.team { background: var(--surface); border-block: 1px solid var(--line); }
.team__grid { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); gap: clamp(32px, 5vw, 72px); align-items: start; }
.team .section__title { position: sticky; top: calc(var(--header-h) + 32px); }
.team__list { border-top: 1px solid var(--line); }
.member {
	display: grid; grid-template-columns: 48px minmax(0, 1fr); column-gap: 18px; row-gap: 2px; align-items: center;
	padding: 20px 8px; border-bottom: 1px solid var(--line);
	transition: background-color .25s;
}
.member:hover { background: var(--bg); }
.member__name, .member__role { transition: transform .35s var(--ease); }
.member:hover .member__name, .member:hover .member__role { transform: translateX(6px); }
.member__initials {
	grid-row: span 2;
	width: 48px; height: 48px; border-radius: 50%;
	display: inline-flex; align-items: center; justify-content: center;
	background: var(--graphite); color: var(--accent);
	font-family: var(--mono); font-size: 15px; font-weight: 600; letter-spacing: .02em;
	transition: background-color .25s, color .25s;
}
.member:hover .member__initials { background: var(--accent); color: var(--ink); }
.member__name { font-size: 19px; font-weight: 600; letter-spacing: -.01em; }
.member__role { color: var(--muted); font-size: 15px; }
@media (max-width: 860px) {
	.team__grid { grid-template-columns: 1fr; }
	.team .section__title { position: static; }
}

/* ---------- FAQ ---------- */
.faq .section__title { margin-bottom: 36px; }
.faq__list { display: grid; gap: 12px; }
.qa { background: var(--surface); border: 1px solid var(--line); border-radius: var(--r-md); transition: border-color .25s, box-shadow .3s; }
.qa[open] { border-color: #CDD3CD; box-shadow: var(--shadow); }
.qa summary {
	display: flex; align-items: center; justify-content: space-between; gap: 20px;
	padding: 22px 26px; cursor: pointer; list-style: none;
	font-size: clamp(17px, 1.5vw, 19px); font-weight: 600; letter-spacing: -.01em;
	border-radius: var(--r-md);
}
.qa summary::-webkit-details-marker { display: none; }
.qa__icon { position: relative; flex: none; width: 32px; height: 32px; border-radius: 50%; background: var(--bg); transition: background-color .25s, transform .35s var(--ease); }
.qa__icon::before, .qa__icon::after { content: ""; position: absolute; left: 50%; top: 50%; width: 12px; height: 2px; margin: -1px 0 0 -6px; background: var(--ink); border-radius: 2px; transition: transform .35s var(--ease); }
.qa__icon::after { transform: rotate(90deg); }
.qa[open] .qa__icon { background: var(--accent); transform: rotate(180deg); }
.qa[open] .qa__icon::after { transform: rotate(0deg); }
.qa__body { padding: 0 26px 24px; color: var(--muted); max-width: 64ch; }
.qa__body a { color: var(--accent-deep); font-weight: 550; text-underline-offset: 3px; }
.qa[open] .qa__body { animation: qaIn .4s var(--ease); }
.qa__body > * + * { margin-top: 14px; }
.downloads { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 10px; }
.dl {
	display: flex; flex-direction: column; gap: 4px; height: 100%;
	padding: 14px 16px; border-radius: var(--r-sm);
	background: var(--bg); border: 1px solid var(--line);
	text-decoration: none; transition: border-color .2s, background-color .2s, transform .2s var(--ease);
}
.dl:hover { border-color: var(--accent-deep); background: var(--accent-soft); transform: translateY(-2px); }
.qa__body .dl { font-weight: 400; }
.dl__os { color: var(--ink); font-weight: 600; font-size: 15px; }
.dl__file { color: var(--muted); font-family: var(--mono); font-size: 12.5px; word-break: break-all; }
.dl__hint { font-size: 15px; }
.cmd {
	display: flex; align-items: center; justify-content: space-between; gap: 12px;
	padding: 10px 10px 10px 16px; border-radius: var(--r-sm);
	background: var(--graphite); color: var(--graphite-ink);
}
.cmd code { font-family: var(--mono); font-size: 14px; overflow-x: auto; white-space: nowrap; }
.cmd code::before { content: "$ "; color: var(--accent); }
.cmd__copy {
	flex: none; min-height: 34px; padding: 0 14px; border-radius: var(--r-pill);
	border: 1px solid var(--graphite-line); background: transparent; color: var(--graphite-ink);
	font-size: 13px; font-weight: 600; cursor: pointer; transition: border-color .2s, background-color .2s, color .2s;
}
.cmd__copy:hover { border-color: var(--accent); }
.cmd__copy.is-copied { background: var(--accent); border-color: var(--accent); color: var(--ink); }
@media (max-width: 680px) { .downloads { grid-template-columns: 1fr; } }
/* Keep FAQ cards inside the screen: grid/flex children may shrink below their content width. */
.faq__list > *, .qa__body, .cmd code, .downloads > li, .dl { min-width: 0; }
.cmd code { flex: 1 1 auto; }
.qa summary > span { min-width: 0; overflow-wrap: anywhere; }
@media (max-width: 560px) {
	.qa summary { padding: 18px 18px; font-size: 16px; gap: 14px; }
	.qa__body { padding: 0 18px 20px; }
	.cmd { flex-wrap: wrap; padding: 12px 14px; }
	.cmd code { white-space: pre-wrap; word-break: break-all; font-size: 13px; }
	.cmd__copy { width: 100%; }
}@keyframes qaIn { from { opacity: 0; transform: translateY(-6px); } to { opacity: 1; transform: none; } }

/* ---------- Contact ---------- */
.contact { padding-top: 0; }
.contact__grid {
	display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 6fr); gap: clamp(32px, 5vw, 72px);
	background: var(--graphite); color: var(--graphite-ink);
	border-radius: calc(var(--r-md) + 6px);
	padding: clamp(28px, 5vw, 64px);
	position: relative; overflow: hidden; isolation: isolate;
}
.contact__grid::before { content: ""; position: absolute; inset: auto -20% -60% auto; width: 70%; aspect-ratio: 1; z-index: -1; background: radial-gradient(circle, rgba(120, 190, 70, .18), transparent 65%); }
@media (max-width: 720px) {
	.contact .container { padding-inline: 0; }
	.contact__grid { border-radius: 0; }
}
.contact .section__title { color: #fff; }
.contact__text > p { margin-top: 16px; color: var(--graphite-muted); max-width: 40ch; }
.contact__list { margin-top: 36px; display: grid; gap: 20px; }
.contact__list li { display: flex; gap: 14px; align-items: flex-start; color: var(--graphite-muted); font-size: 15px; line-height: 1.5; }
.contact__list .icon { margin-top: 2px; color: var(--accent); }
.contact__list a { color: #fff; font-size: 17px; font-weight: 550; text-decoration: none; }
.contact__list a:hover { color: var(--accent); }

.form { display: grid; gap: 16px; align-content: start; }
.field { display: grid; gap: 8px; }
.field-row { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.field label { font-size: 14px; font-weight: 550; color: var(--graphite-ink); }
.field__opt { color: var(--graphite-muted); font-weight: 400; }
.field input, .field select, .field textarea {
	width: 100%; min-height: 50px; padding: 12px 16px;
	background: var(--graphite-2); color: #fff;
	border: 1px solid var(--graphite-line); border-radius: var(--r-sm);
	font-size: 16px; transition: border-color .2s, box-shadow .2s;
}
.field textarea { resize: vertical; min-height: 110px; }
.field select { appearance: none; background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath d='M1 1l5 5 5-5' fill='none' stroke='%23A3A7AC' stroke-width='1.6'/%3E%3C/svg%3E"); background-repeat: no-repeat; background-position: right 16px center; padding-right: 40px; }
.field input:hover, .field select:hover, .field textarea:hover { border-color: #50555A; }
.field input:focus, .field select:focus, .field textarea:focus { outline: none; border-color: var(--accent); box-shadow: 0 0 0 3px rgba(120, 190, 70, .25); }
.form__hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
.form .btn { margin-top: 8px; }
.form-notice { padding: 14px 16px; border-radius: var(--r-sm); font-size: 15px; font-weight: 500; }
.form-notice--success { background: rgba(120, 190, 70, .16); color: #D8EEC8; border: 1px solid rgba(120, 190, 70, .45); }
.form-notice--error { background: rgba(255, 255, 255, .06); color: #fff; border: 1px solid #6B6F74; }
@media (max-width: 860px) {
	.contact__grid { grid-template-columns: 1fr; }
}
@media (max-width: 520px) {
	.field-row { grid-template-columns: 1fr; }
}

/* ---------- Footer ---------- */
.site-footer { background: var(--graphite); color: var(--graphite-muted); padding-top: clamp(56px, 7vw, 88px); border-top: 1px solid var(--graphite-line); font-size: 15px; }
.site-footer .logo__img { height: 60px; }
.cf-turnstile { min-height: 65px; }
.site-footer__grid { display: grid; grid-template-columns: minmax(0, 1.4fr) repeat(3, minmax(0, 1fr)); gap: 32px; padding-bottom: 48px; }
.site-footer__brand p { margin-top: 16px; max-width: 32ch; }
.site-footer__title { font-size: 15px; font-weight: 600; color: #fff; letter-spacing: 0; margin-bottom: 14px; }
.site-footer ul { display: grid; gap: 10px; }
.site-footer a { text-decoration: none; transition: color .2s; }
.site-footer a:hover { color: #fff; }
.site-footer__contact li { display: flex; gap: 10px; align-items: center; }
.site-footer__contact .icon { width: 18px; height: 18px; color: var(--accent); }
.site-footer__bottom { display: flex; justify-content: space-between; gap: 16px; padding-block: 22px; border-top: 1px solid var(--graphite-line); font-size: 14px; }
@media (max-width: 860px) {
	.site-footer__grid { grid-template-columns: 1fr 1fr; }
	.site-footer__brand { grid-column: 1 / -1; }
}

/* ---------- Generic pages ---------- */
.page-hero { background: var(--graphite); color: #fff; padding: calc(var(--header-h) + 72px) 0 72px; }
.page-hero h1 { font-size: clamp(36px, 5vw, 60px); max-width: 20ch; }
.page-hero--404 { min-height: 70svh; display: flex; align-items: center; }
.page-hero--404 p { margin-top: 18px; color: var(--graphite-muted); }
.mono-line { font-family: var(--mono); color: var(--accent) !important; font-size: 14px; }
.prose > * + * { margin-top: 1.1em; }
.prose a { color: var(--accent-deep); }
.post-row { padding-block: 24px; border-bottom: 1px solid var(--line); }
.post-row h2 { font-size: 24px; }
.post-row p { margin-top: 8px; color: var(--muted); }
.img-fallback { display: block; width: 100%; height: 100%; min-height: 240px; background: linear-gradient(135deg, var(--graphite) 0%, #2F3A2A 100%); }

/* ---------- Reveal (only when JS is present) ---------- */
.js .reveal { opacity: 0; transform: translateY(18px); transition: opacity .7s var(--ease), transform .7s var(--ease); }
.js .reveal.is-in { opacity: 1; transform: none; }
.js .tile.reveal.is-in:hover { transform: translateY(-3px); }
.js .tile.reveal.is-in { transition: opacity .7s var(--ease), transform .4s var(--ease), box-shadow .4s var(--ease), border-color .3s; }

/* ---------- Reduced motion ---------- */
@media (prefers-reduced-motion: reduce) {
	html { scroll-behavior: auto; }
	*, *::before, *::after { animation-duration: .001ms !important; animation-iteration-count: 1 !important; transition-duration: .001ms !important; transition-delay: 0s !important; }
	.js .reveal { opacity: 1; transform: none; }
	.editor, .editor:hover { transform: none; }
	.band::before { transform: none; }
	.caret { animation: none; }
}
