:root {
	--bg-deep: #070b16;
	--bg-mid: #0f172a;
	--bg-panel: rgba(15, 23, 42, 0.62);
	--bg-card: rgba(17, 24, 39, 0.72);
	--border-soft: rgba(148, 163, 184, 0.14);
	--border-strong: rgba(56, 189, 248, 0.38);
	--accent: #38bdf8;
	--accent-2: #22d3ee;
	--accent-3: #a78bfa;
	--text: #f8fafc;
	--text-muted: rgba(226, 232, 240, 0.72);
	--text-dim: rgba(148, 163, 184, 0.9);
	--shadow-card: 0 24px 60px -28px rgba(14, 165, 233, 0.55);
	--shadow-hover: 0 32px 70px -24px rgba(34, 211, 238, 0.65);
	--radius-lg: 28px;
	--radius-md: 20px;
	--radius-sm: 14px;
	--nav-h: 68px;
	--container: min(1140px, 92vw);
	--carousel-gap: 18px;
	--ease: cubic-bezier(0.22, 0.61, 0.36, 1);
	--font: -apple-system, BlinkMacSystemFont, 'SF Pro Display', 'PingFang SC',
		'Hiragino Sans GB', 'Segoe UI', sans-serif;
}

*,
*::before,
*::after {
	box-sizing: border-box;
	margin: 0;
	padding: 0;
}

html {
	scroll-behavior: smooth;
	scroll-padding-top: calc(var(--nav-h) + 16px);
}

@media (prefers-reduced-motion: reduce) {
	html {
		scroll-behavior: auto;
	}

	*,
	*::before,
	*::after {
		animation-duration: 0.01ms !important;
		animation-iteration-count: 1 !important;
		transition-duration: 0.01ms !important;
	}
}

body {
	font-family: var(--font);
	color: var(--text);
	background: var(--bg-deep);
	min-height: 100vh;
	display: flex;
	flex-direction: column;
	line-height: 1.6;
	-webkit-font-smoothing: antialiased;
}

a {
	color: inherit;
	text-decoration: none;
}

img {
	display: block;
	max-width: 100%;
}

button {
	font: inherit;
}

.container {
	width: var(--container);
	margin: 0 auto;
}

/* ---------- ambient background ---------- */
.page-bg {
	position: fixed;
	inset: 0;
	z-index: -1;
	overflow: hidden;
	pointer-events: none;
	background:
		radial-gradient(ellipse 90% 55% at 50% -8%, rgba(56, 189, 248, 0.1), transparent 58%),
		linear-gradient(180deg, #0a1020 0%, #0d1528 45%, #101a30 100%);
}

.page-bg__orb {
	display: none;
}

.page-bg__grid {
	position: absolute;
	inset: 0;
	opacity: 0.35;
	background-image:
		linear-gradient(rgba(148, 163, 184, 0.035) 1px, transparent 1px),
		linear-gradient(90deg, rgba(148, 163, 184, 0.035) 1px, transparent 1px);
	background-size: 72px 72px;
	mask-image: radial-gradient(ellipse 75% 55% at 50% 20%, black 10%, transparent 78%);
	-webkit-mask-image: radial-gradient(ellipse 75% 55% at 50% 20%, black 10%, transparent 78%);
}

/* ---------- sticky nav ---------- */
.site-nav {
	position: sticky;
	top: 0;
	z-index: 100;
	height: var(--nav-h);
	border-bottom: 1px solid transparent;
	background: transparent;
	backdrop-filter: blur(0);
	-webkit-backdrop-filter: blur(0);
	transition: background 0.3s ease, border-color 0.3s ease, backdrop-filter 0.3s ease;
}

.site-nav.is-scrolled {
	background: rgba(7, 11, 22, 0.72);
	border-bottom-color: var(--border-soft);
	backdrop-filter: blur(18px) saturate(1.2);
	-webkit-backdrop-filter: blur(18px) saturate(1.2);
}

.site-nav__inner {
	height: 100%;
	display: flex;
	align-items: center;
	gap: 20px;
}

.site-nav__brand {
	display: inline-flex;
	align-items: center;
	gap: 10px;
	font-weight: 700;
	letter-spacing: 0.02em;
	flex-shrink: 0;
}

.site-nav__brand img {
	width: 36px;
	height: 36px;
	border-radius: 10px;
	box-shadow: 0 8px 18px -8px rgba(56, 189, 248, 0.6);
}

.site-nav__links {
	display: flex;
	align-items: center;
	gap: 6px;
	margin-left: auto;
}

.site-nav__links a {
	padding: 8px 14px;
	border-radius: 999px;
	font-size: 0.92rem;
	color: var(--text-muted);
	transition: color 0.2s ease, background 0.2s ease;
}

.site-nav__links a:hover {
	color: var(--text);
	background: rgba(148, 163, 184, 0.12);
}

.site-nav__cta {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	padding: 9px 18px;
	border-radius: 999px;
	font-size: 0.88rem;
	font-weight: 600;
	color: #0f172a;
	background: linear-gradient(135deg, var(--accent), var(--accent-2));
	box-shadow: 0 10px 24px -12px rgba(34, 211, 238, 0.85);
	transition: transform 0.2s ease, box-shadow 0.2s ease;
	flex-shrink: 0;
}

.site-nav__cta:hover {
	transform: translateY(-1px);
	box-shadow: 0 14px 28px -12px rgba(56, 189, 248, 0.9);
}

/* ---------- hero ---------- */
.hero {
	position: relative;
	padding: 48px 0 88px;
	text-align: center;
}

.hero__content {
	display: flex;
	flex-direction: column;
	align-items: center;
	gap: 28px;
}

.hero__logo img {
	width: clamp(140px, 20vw, 200px);
	height: auto;
	filter: drop-shadow(0 18px 36px rgba(14, 165, 233, 0.45));
	transition: transform 0.55s var(--ease);
}

.hero__logo:hover img {
	transform: translateY(-8px) scale(1.04);
}

.hero__text {
	max-width: 680px;
}

.hero h1 {
	font-size: clamp(2.6rem, 7vw, 4.2rem);
	font-weight: 800;
	letter-spacing: 0.02em;
	line-height: 1.1;
	margin-bottom: 12px;
	background: linear-gradient(120deg, #f8fafc 0%, #bae6fd 50%, #c4b5fd 100%);
	background-clip: text;
	-webkit-background-clip: text;
	color: transparent;
}

.hero__accent {
	color: var(--accent);
	-webkit-text-fill-color: var(--accent);
}

.hero__tagline {
	font-size: clamp(1.15rem, 2.8vw, 1.45rem);
	font-weight: 600;
	color: var(--text);
	margin-bottom: 12px;
}

.hero__desc {
	font-size: clamp(0.95rem, 2vw, 1.05rem);
	color: var(--text-muted);
	max-width: 520px;
	margin: 0 auto 28px;
	line-height: 1.7;
}

.hero__actions {
	display: flex;
	flex-wrap: wrap;
	justify-content: center;
	gap: 12px;
}

.cta-button {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	padding: 13px 28px;
	font-size: 0.95rem;
	font-weight: 600;
	color: #0f172a;
	background: linear-gradient(135deg, var(--accent) 0%, var(--accent-2) 100%);
	border-radius: 999px;
	box-shadow: 0 14px 30px -12px rgba(34, 211, 238, 0.8);
	transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.cta-button:hover {
	transform: translateY(-3px);
	box-shadow: 0 18px 34px -12px rgba(56, 189, 248, 0.85);
}

.cta-button--ghost {
	background: rgba(148, 163, 184, 0.08);
	color: var(--text);
	border: 1px solid rgba(148, 163, 184, 0.28);
	box-shadow: none;
	backdrop-filter: blur(8px);
}

.cta-button--ghost:hover {
	border-color: rgba(148, 163, 184, 0.55);
	background: rgba(148, 163, 184, 0.14);
	transform: translateY(-3px);
}

/* ---------- sections shared ---------- */
main {
	flex: 1;
}

.section-header {
	text-align: center;
	margin-bottom: 44px;
}

.section-kicker {
	display: inline-block;
	margin-bottom: 12px;
	font-size: 0.78rem;
	font-weight: 700;
	letter-spacing: 0.16em;
	text-transform: uppercase;
	color: var(--accent);
}

.section-header h2,
.services h2,
.downloads h2,
.projects h2 {
	font-size: clamp(1.9rem, 4.5vw, 2.7rem);
	font-weight: 750;
	letter-spacing: 0.01em;
	margin-bottom: 14px;
	background: linear-gradient(120deg, #e0f2fe, #ddd6fe);
	background-clip: text;
	-webkit-background-clip: text;
	color: transparent;
}

.section-hint {
	margin: 0 auto;
	max-width: 560px;
	text-align: center;
	color: var(--text-muted);
	line-height: 1.65;
	font-size: 0.98rem;
}

/* ---------- services ---------- */
.services {
	padding: 72px 0 40px;
}

.service-grid {
	display: grid;
	grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
	gap: 18px;
}

.service-card {
	position: relative;
	display: flex;
	flex-direction: column;
	gap: 8px;
	padding: 26px 24px 28px;
	background: var(--bg-card);
	border: 1px solid var(--border-soft);
	border-radius: var(--radius-md);
	box-shadow: var(--shadow-card);
	backdrop-filter: blur(16px);
	-webkit-backdrop-filter: blur(16px);
	transition: transform 0.28s var(--ease), border-color 0.28s ease, box-shadow 0.28s ease;
	overflow: hidden;
}

.service-card::before {
	content: '';
	position: absolute;
	inset: 0;
	background: linear-gradient(135deg, rgba(56, 189, 248, 0.08), transparent 55%);
	opacity: 0;
	transition: opacity 0.28s ease;
	pointer-events: none;
}

.service-card:hover {
	transform: translateY(-6px);
	border-color: var(--border-strong);
	box-shadow: var(--shadow-hover);
}

.service-card:hover::before {
	opacity: 1;
}

.service-card h3 {
	font-size: 1.12rem;
	font-weight: 650;
}

.service-card p {
	font-size: 0.92rem;
	color: var(--text-muted);
	line-height: 1.55;
	flex: 1;
}

.service-card__arrow {
	align-self: flex-end;
	margin-top: 12px;
	font-size: 1.1rem;
	color: var(--accent);
	opacity: 0.55;
	transition: transform 0.25s ease, opacity 0.25s ease;
}

.service-card:hover .service-card__arrow {
	opacity: 1;
	transform: translateX(4px);
}

/* ---------- downloads ---------- */
.downloads {
	padding: 64px 0 40px;
}

.download-grid {
	display: grid;
	grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
	gap: 18px;
}

.download-card {
	position: relative;
	display: flex;
	flex-direction: column;
	gap: 10px;
	padding: 28px 24px;
	border-radius: var(--radius-md);
	background:
		linear-gradient(160deg, rgba(56, 189, 248, 0.1), rgba(15, 23, 42, 0.7) 55%),
		var(--bg-card);
	border: 1px solid rgba(56, 189, 248, 0.2);
	box-shadow: var(--shadow-card);
	backdrop-filter: blur(16px);
	transition: transform 0.28s var(--ease), border-color 0.28s ease, box-shadow 0.28s ease;
}

.download-card:hover {
	transform: translateY(-6px);
	border-color: rgba(56, 189, 248, 0.5);
	box-shadow: var(--shadow-hover);
}

.download-card__badge {
	align-self: flex-start;
	padding: 4px 10px;
	border-radius: 999px;
	font-size: 0.7rem;
	font-weight: 700;
	letter-spacing: 0.1em;
	color: #0f172a;
	background: linear-gradient(135deg, var(--accent), var(--accent-2));
}

.download-card h3 {
	font-size: 1.15rem;
	font-weight: 650;
}

.download-card p {
	font-size: 0.9rem;
	color: var(--text-muted);
	line-height: 1.55;
	flex: 1;
}

.download-card__cta {
	display: inline-flex;
	align-items: center;
	gap: 6px;
	margin-top: 8px;
	font-size: 0.88rem;
	font-weight: 600;
	color: var(--accent);
}

.download-card__cta::after {
	content: '↓';
	transition: transform 0.2s ease;
}

.download-card:hover .download-card__cta::after {
	transform: translateY(2px);
}

/* ---------- projects ---------- */
.projects {
	padding: 72px 0 100px;
}

.project-grid {
	display: grid;
	grid-template-columns: 1fr;
	gap: 28px;
}

.project-card {
	position: relative;
	padding: 28px;
	background: rgba(15, 23, 42, 0.7);
	border-radius: var(--radius-lg);
	border: 1px solid var(--border-soft);
	box-shadow: 0 28px 60px -32px rgba(59, 130, 246, 0.55);
	backdrop-filter: blur(18px);
	-webkit-backdrop-filter: blur(18px);
	transition: transform 0.3s var(--ease), border-color 0.3s ease, box-shadow 0.3s ease;
	overflow: hidden;
}

.project-card::after {
	content: '';
	position: absolute;
	inset: 0;
	border-radius: inherit;
	pointer-events: none;
	background: linear-gradient(180deg, rgba(56, 189, 248, 0.04), transparent 30%);
	opacity: 0;
	transition: opacity 0.3s ease;
}

.project-card:hover {
	transform: translateY(-6px);
	border-color: rgba(56, 189, 248, 0.35);
	box-shadow: 0 34px 70px -28px rgba(56, 189, 248, 0.55);
}

.project-card:hover::after {
	opacity: 1;
}

.project-card--featured {
	border-color: rgba(56, 189, 248, 0.22);
	background:
		linear-gradient(165deg, rgba(56, 189, 248, 0.07), transparent 40%),
		rgba(15, 23, 42, 0.74);
}

.project-body {
	position: relative;
	z-index: 1;
}

/* carousel — multi peek by default; featured can use single mode */
.project-gallery {
	--carousel-visible: 2.2;
	--carousel-item-width: calc(
		(100% - (var(--carousel-gap) * (var(--carousel-visible) - 1))) / var(--carousel-visible)
	);
	position: relative;
	margin: 0 auto 28px;
	width: 100%;
	outline: none;
}

.project-carousel__viewport {
	position: relative;
	overflow: hidden;
	border-radius: 22px;
	border: 1px solid rgba(56, 189, 248, 0.18);
	background: rgba(7, 11, 22, 0.45);
	box-shadow: inset 0 0 0 1px rgba(15, 23, 42, 0.35);
}

.project-carousel__track {
	display: flex;
	gap: var(--carousel-gap);
	padding: 0 calc((100% - var(--carousel-item-width)) / 2);
	will-change: transform;
	transition: transform 0.6s var(--ease);
}

.project-carousel__item {
	flex: 0 0 var(--carousel-item-width);
	position: relative;
	display: flex;
	align-items: center;
	justify-content: center;
	height: clamp(220px, 36vw, 340px);
	padding: 16px;
	margin: 0;
	border-radius: 22px;
	background: radial-gradient(circle at center, rgba(30, 41, 59, 0.7), rgba(15, 23, 42, 0.95));
	transition: transform 0.45s ease, opacity 0.45s ease, filter 0.45s ease;
	transform-origin: center;
	transform: scale(0.84);
	opacity: 0.5;
	filter: saturate(0.8);
	pointer-events: none;
}

.project-carousel__item img {
	max-width: 100%;
	max-height: 100%;
	width: auto;
	height: auto;
	object-fit: contain;
	border-radius: 16px;
}

.project-carousel__item.is-active {
	transform: scale(1);
	opacity: 1;
	filter: saturate(1);
	z-index: 2;
	pointer-events: auto;
}

.project-carousel__item.is-prev,
.project-carousel__item.is-next {
	transform: scale(0.92);
	opacity: 0.8;
	filter: saturate(0.92);
	z-index: 1;
}

.project-carousel__item.is-active::after {
	content: '';
	position: absolute;
	inset: 0;
	border-radius: inherit;
	box-shadow: inset 0 0 0 1px rgba(148, 163, 184, 0.28);
	pointer-events: none;
}

/* single-slide mode for vertical watch screenshots */
.project-gallery--single .project-carousel__track {
	gap: 0;
	padding: 0;
}

.project-gallery--single .project-carousel__item {
	flex: 0 0 100%;
	height: clamp(280px, 48vw, 420px);
	padding: 20px 16px;
	border-radius: 0;
	background: radial-gradient(circle at center, rgba(30, 41, 59, 0.55), rgba(7, 11, 22, 0.85));
	transform: none;
	opacity: 1;
	filter: none;
	pointer-events: auto;
}

.project-gallery--single .project-carousel__item.is-active,
.project-gallery--single .project-carousel__item.is-prev,
.project-gallery--single .project-carousel__item.is-next {
	transform: none;
	opacity: 1;
	filter: none;
}

.project-gallery--single .project-carousel__item.is-active::after {
	display: none;
}

.project-gallery--single .project-carousel__item img {
	max-width: min(100%, 220px);
	border-radius: 18px;
	box-shadow: 0 16px 36px -12px rgba(0, 0, 0, 0.55);
}

.project-carousel__control {
	position: absolute;
	top: 50%;
	transform: translateY(-50%);
	width: 40px;
	height: 40px;
	border-radius: 50%;
	border: 1px solid rgba(148, 163, 184, 0.35);
	background: rgba(7, 11, 22, 0.7);
	color: rgba(226, 232, 240, 0.92);
	font-size: 1.55rem;
	line-height: 1;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	cursor: pointer;
	backdrop-filter: blur(8px);
	transition: transform 0.2s ease, background 0.2s ease, border-color 0.2s ease;
	z-index: 3;
}

.project-carousel__control:hover {
	transform: translateY(-50%) scale(1.06);
	background: rgba(56, 189, 248, 0.32);
	border-color: rgba(56, 189, 248, 0.6);
}

.project-carousel__control:focus-visible {
	outline: 3px solid rgba(125, 211, 252, 0.8);
	outline-offset: 2px;
}

.project-carousel__control--prev {
	left: 10px;
}

.project-carousel__control--next {
	right: 10px;
}

.project-carousel__dots {
	display: flex;
	justify-content: center;
	flex-wrap: wrap;
	gap: 8px;
	margin-top: 14px;
}

.project-carousel__dot {
	width: 8px;
	height: 8px;
	border-radius: 50%;
	border: none;
	background: rgba(148, 163, 184, 0.35);
	cursor: pointer;
	transition: transform 0.25s ease, background 0.25s ease, width 0.25s ease;
}

.project-carousel__dot:focus-visible {
	outline: 2px solid rgba(148, 163, 184, 0.9);
	outline-offset: 3px;
}

.project-carousel__dot.is-active {
	width: 22px;
	border-radius: 999px;
	background: rgba(56, 189, 248, 0.9);
}

/* project heading / body */
.project-heading {
	display: flex;
	align-items: center;
	gap: 16px;
	margin-bottom: 16px;
}

.project-heading__logo img {
	width: clamp(56px, 10vw, 80px);
	height: auto;
	border-radius: 16px;
	filter: drop-shadow(0 12px 22px rgba(34, 211, 238, 0.22));
}

.project-heading__text {
	display: flex;
	flex-direction: column;
	align-items: flex-start;
	gap: 8px;
	min-width: 0;
}

.project-badge {
	display: inline-flex;
	align-items: center;
	padding: 5px 12px;
	font-size: 0.72rem;
	font-weight: 700;
	letter-spacing: 0.08em;
	text-transform: uppercase;
	color: rgba(226, 232, 240, 0.9);
	background: linear-gradient(135deg, rgba(56, 189, 248, 0.2), rgba(167, 139, 250, 0.22));
	border: 1px solid rgba(148, 163, 184, 0.18);
	border-radius: 999px;
}

.project-heading__title {
	margin: 0;
	font-size: clamp(1.35rem, 2.6vw, 1.7rem);
	font-weight: 700;
}

.project-card p {
	color: var(--text-muted);
	line-height: 1.7;
	margin-bottom: 20px;
	font-size: 0.98rem;
}

.project-meta {
	list-style: none;
	display: grid;
	gap: 10px;
	margin-bottom: 22px;
	padding: 14px 16px;
	border-radius: var(--radius-sm);
	background: rgba(7, 11, 22, 0.4);
	border: 1px solid rgba(148, 163, 184, 0.1);
}

.project-meta li {
	display: grid;
	grid-template-columns: 88px 1fr;
	gap: 10px;
	align-items: start;
	font-size: 0.9rem;
}

.project-meta strong {
	font-weight: 600;
	color: var(--text);
}

.project-meta span {
	color: var(--text-muted);
}

.project-actions {
	display: flex;
	flex-wrap: wrap;
	gap: 10px;
}

.project-link {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	padding: 10px 18px;
	font-size: 0.88rem;
	font-weight: 600;
	border-radius: 999px;
	background: linear-gradient(135deg, rgba(56, 189, 248, 0.92), rgba(45, 212, 191, 0.88));
	box-shadow: 0 12px 26px -14px rgba(45, 212, 191, 0.85);
	color: #0f172a;
	transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.project-link:hover {
	transform: translateY(-2px);
	box-shadow: 0 16px 30px -14px rgba(34, 211, 238, 0.8);
}

.project-link--ghost {
	background: transparent;
	color: var(--text);
	border: 1px solid rgba(148, 163, 184, 0.32);
	box-shadow: none;
}

.project-link--ghost:hover {
	border-color: rgba(148, 163, 184, 0.6);
	background: rgba(148, 163, 184, 0.1);
}

/* ---------- footer ---------- */
.site-footer {
	padding: 36px 0 48px;
	border-top: 1px solid var(--border-soft);
	background: rgba(7, 11, 22, 0.55);
	backdrop-filter: blur(12px);
}

.site-footer__inner {
	display: flex;
	flex-direction: column;
	align-items: center;
	gap: 10px;
	text-align: center;
}

.site-footer__brand {
	display: inline-flex;
	align-items: center;
	gap: 10px;
	font-weight: 650;
	color: var(--text);
}

.site-footer__brand img {
	width: 28px;
	height: 28px;
	border-radius: 8px;
}

.site-footer a {
	font-size: 0.88rem;
	color: var(--text-dim);
	transition: color 0.2s ease;
}

.site-footer a:hover {
	color: #e0f2fe;
}

/* ---------- responsive ---------- */
@media (min-width: 900px) {
	.project-card--featured {
		display: grid;
		grid-template-columns: minmax(240px, 0.9fr) 1.1fr;
		gap: 28px;
		align-items: center;
	}

	.project-card--featured .project-gallery {
		margin-bottom: 0;
	}

	.project-card--featured .project-gallery--single .project-carousel__item {
		height: clamp(300px, 38vw, 400px);
	}
}

@media (max-width: 720px) {
	.site-nav__links {
		display: none;
	}

	.hero {
		padding: 28px 0 64px;
	}

	.hero__actions {
		gap: 10px;
	}

	.cta-button {
		padding: 12px 20px;
		font-size: 0.9rem;
	}

	.services {
		padding-top: 48px;
	}

	.projects {
		padding-bottom: 72px;
	}

	.project-gallery {
		--carousel-visible: 1.3;
		--carousel-gap: 12px;
	}

	.project-carousel__item {
		height: clamp(200px, 68vw, 280px);
	}

	.project-gallery--single .project-carousel__item {
		height: clamp(260px, 72vw, 340px);
		padding: 16px 12px;
	}

	.project-gallery--single .project-carousel__item img {
		max-width: min(100%, 180px);
	}

	.project-carousel__control {
		width: 34px;
		height: 34px;
		font-size: 1.3rem;
	}

	.project-card {
		padding: 20px 18px 24px;
	}

	.project-meta li {
		grid-template-columns: 1fr;
		gap: 2px;
	}

	.project-heading {
		gap: 12px;
	}

	.service-card,
	.download-card {
		padding: 22px 20px;
	}
}

@media (max-width: 420px) {
	.hero__actions {
		flex-direction: column;
		width: 100%;
	}

	.cta-button {
		width: 100%;
	}
}
