:root {
	--bg: #f4f7fb;
	--surface: #ffffff;
	--text: #172033;
	--muted: #5d6b85;
	--line: #dbe2ef;
	--primary: #0f5bd8;
	--primary-strong: #0c49ac;
	--radius: 14px;
	--shadow: 0 12px 30px rgba(23, 32, 51, 0.08);
}

* {
	box-sizing: border-box;
}

html {
	scroll-behavior: smooth;
}

body {
	margin: 0;
	font-family: "Space Grotesk", "Segoe UI", sans-serif;
	color: var(--text);
	background: radial-gradient(circle at top right, #dce8ff 0%, var(--bg) 40%);
	line-height: 1.6;
}

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

.container {
	width: min(1120px, calc(100% - 2rem));
	margin: 0 auto;
}

.section {
	padding: 4.5rem 0 1.5rem;
}

.section h3 {
	margin: 0 0 1.25rem;
	font-size: clamp(1.5rem, 2.8vw, 2rem);
}

.site-header {
	position: sticky;
	top: 0;
	z-index: 999;
	background: rgba(244, 247, 251, 0.9);
	backdrop-filter: blur(8px);
	border-bottom: 1px solid transparent;
	transition: border-color 0.25s ease, box-shadow 0.25s ease;
}

.site-header.scrolled {
	border-bottom-color: var(--line);
	box-shadow: 0 6px 18px rgba(23, 32, 51, 0.06);
}

.navbar {
	display: flex;
	align-items: center;
	justify-content: space-between;
	min-height: 4.25rem;
}

.brand {
	font-weight: 700;
	letter-spacing: 0.01em;
}

.nav-toggle {
	display: inline-flex;
	flex-direction: column;
	gap: 4px;
	background: transparent;
	border: 0;
	padding: 0;
	cursor: pointer;
}

.nav-toggle span {
	display: inline-block;
	width: 22px;
	height: 2px;
	background: var(--text);
	transition: transform 0.2s ease, opacity 0.2s ease;
}

.nav-links {
	list-style: none;
	display: none;
	flex-direction: column;
	position: absolute;
	top: 4.25rem;
	left: 1rem;
	right: 1rem;
	margin: 0;
	padding: 0.75rem;
	background: var(--surface);
	border: 1px solid var(--line);
	border-radius: var(--radius);
	box-shadow: var(--shadow);
}

.nav-links.is-open {
	display: flex;
}

.nav-links a {
	display: block;
	padding: 0.55rem 0.7rem;
	border-radius: 8px;
	color: var(--muted);
	transition: background-color 0.2s ease, color 0.2s ease;
}

.nav-links a:hover,
.nav-links a.active {
	background: #ecf3ff;
	color: var(--primary);
}

.hero {
	padding-top: 5.25rem;
	padding-bottom: 2rem;
}

.hero-kicker {
	display: inline-flex;
	margin: 0;
	color: var(--primary);
	font-weight: 600;
	letter-spacing: 0.05em;
	text-transform: uppercase;
	font-size: 0.8rem;
}

.hero h1 {
	margin: 0.65rem 0 0;
	font-size: clamp(2rem, 6.5vw, 4rem);
	line-height: 1.08;
}

.hero h2 {
	margin: 0.65rem 0 1rem;
	font-weight: 500;
	font-size: clamp(1.05rem, 2.6vw, 1.45rem);
	color: var(--muted);
}

.hero p {
	margin: 0;
	max-width: 62ch;
}

.hero-actions {
	display: flex;
	gap: 0.8rem;
	flex-wrap: wrap;
	margin-top: 1.6rem;
}

.btn {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	padding: 0.7rem 1.15rem;
	border-radius: 10px;
	border: 1px solid transparent;
	font-weight: 600;
	transition: transform 0.2s ease, box-shadow 0.2s ease, background-color 0.2s ease;
}

.btn:hover {
	transform: translateY(-2px);
}

.btn-primary {
	background: var(--primary);
	color: #ffffff;
	box-shadow: 0 10px 20px rgba(15, 91, 216, 0.25);
}

.btn-primary:hover {
	background: var(--primary-strong);
}

.btn-secondary {
	background: transparent;
	border-color: var(--line);
}

.btn-secondary:hover {
	background: #edf2fb;
}

.skills-grid,
.projects-grid,
.contact-grid {
	display: grid;
	gap: 0.95rem;
}

.skill-card,
.project-card,
.timeline-item,
.contact-grid a {
	background: var(--surface);
	border: 1px solid var(--line);
	border-radius: var(--radius);
	box-shadow: 0 6px 14px rgba(23, 32, 51, 0.04);
}

.skill-card,
.project-card,
.timeline-item {
	padding: 1rem;
}

.skill-card h4,
.project-card h4,
.timeline-meta h4 {
	margin: 0 0 0.35rem;
	font-size: 1.05rem;
}

.skill-card p,
.project-card p,
.timeline-meta p,
.timeline-meta span {
	margin: 0;
	color: var(--muted);
}

.timeline {
	position: relative;
	padding-left: 1rem;
}

.timeline::before {
	content: "";
	position: absolute;
	left: 0.2rem;
	top: 0;
	bottom: 0;
	width: 2px;
	background: var(--line);
}

.timeline-item {
	position: relative;
}

.timeline-item::before {
	content: "";
	position: absolute;
	left: -1.35rem;
	top: 1rem;
	width: 10px;
	height: 10px;
	border-radius: 50%;
	background: var(--primary);
}

.timeline-meta {
	margin-bottom: 0.7rem;
}

.timeline-item ul {
	margin: 0;
	padding-left: 1.15rem;
}

.timeline-item li + li {
	margin-top: 0.45rem;
}

.project-card {
	transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.project-card:hover {
	transform: translateY(-4px);
	box-shadow: var(--shadow);
}

.tech-stack {
	margin-top: 0.55rem;
	font-size: 0.95rem;
}

.tech-stack code {
	background: #eef3fb;
	border: 1px solid #d7e1f0;
	border-radius: 6px;
	padding: 0.05rem 0.35rem;
	font-size: 0.86rem;
}

.project-card a {
	display: inline-flex;
	margin-top: 0.9rem;
	font-weight: 600;
	color: var(--primary);
}

.contact-grid a {
	padding: 0.9rem 1rem;
	transition: transform 0.2s ease, border-color 0.2s ease;
}

.contact-grid a:hover {
	transform: translateX(3px);
	border-color: #c6d5ee;
}

.site-footer {
	margin-top: 3.2rem;
	border-top: 1px solid var(--line);
	background: #eff4fc;
}

.footer-content {
	padding: 1.1rem 0;
	display: flex;
	flex-direction: column;
	gap: 0.5rem;
}

.footer-content p {
	margin: 0;
	color: var(--muted);
}

.footer-links {
	display: flex;
	gap: 0.85rem;
	flex-wrap: wrap;
}

.footer-links a {
	color: var(--muted);
}

.footer-links a:hover {
	color: var(--primary);
}

/* Fade-up reveal for sections as they enter viewport. */
.reveal {
	opacity: 0;
	transform: translateY(18px);
	transition: opacity 0.5s ease, transform 0.5s ease;
}

.reveal.show {
	opacity: 1;
	transform: translateY(0);
}

@media (min-width: 720px) {
	.nav-toggle {
		display: none;
	}

	.nav-links {
		position: static;
		display: flex;
		flex-direction: row;
		background: transparent;
		border: 0;
		box-shadow: none;
		padding: 0;
		gap: 0.35rem;
	}

	.skills-grid {
		grid-template-columns: repeat(2, minmax(0, 1fr));
	}

	.projects-grid {
		grid-template-columns: repeat(3, minmax(0, 1fr));
	}

	.contact-grid {
		grid-template-columns: repeat(3, minmax(0, 1fr));
	}

	.footer-content {
		flex-direction: row;
		align-items: center;
		justify-content: space-between;
	}
}

@media (min-width: 980px) {
	.skills-grid {
		grid-template-columns: repeat(3, minmax(0, 1fr));
	}
}
