:root {
	--bg: #0d1117;
	--surface: #151a21;
	--surface-2: #1a2029;
	--border: #2d333b;
	--track: #21262d;
	--text: #c9d1d9;
	--muted: #8b949e;
	--dim: #484f58;
	--accent: #7ee787;
	--accent-soft: #3fb950;
	--orange: #ffa657;
	--font: "JetBrains Mono", "Fira Code", Consolas, "Courier New", monospace;
}

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

html {
	height: 100%;
}

body {
	min-height: 100vh;
	display: flex;
	align-items: center;
	justify-content: center;
	padding: 24px 20px;
	background:
		radial-gradient(1100px 600px at 50% -10%, rgba(126, 231, 135, 0.05), transparent 60%),
		var(--bg);
	color: var(--text);
	font-family: var(--font);
	font-size: 14px;
	line-height: 1.7;
	-webkit-font-smoothing: antialiased;
}

::selection {
	background: rgba(126, 231, 135, 0.22);
	color: #ffffff;
}

.terminal {
	position: relative;
	width: 100%;
	max-width: 780px;
	height: min(720px, calc(100vh - 48px));
	height: min(720px, calc(100dvh - 48px));
	min-height: 440px;
	display: flex;
	flex-direction: column;
	background: var(--surface);
	border: 1px solid var(--border);
	border-radius: 14px;
	box-shadow: 0 30px 80px -24px rgba(0, 0, 0, 0.65);
	overflow: hidden;
}

.terminal__header {
	flex: none;
	display: flex;
	align-items: center;
	gap: 12px;
	padding: 11px 16px;
	background: var(--surface-2);
	border-bottom: 1px solid var(--border);
}

.dots {
	display: flex;
	gap: 7px;
	flex: none;
}

.dot {
	width: 12px;
	height: 12px;
	border-radius: 50%;
}

.dot--red {
	background: #ff5f57;
}

.dot--yellow {
	background: #febc2e;
}

.dot--green {
	background: #28c840;
}

.terminal__title {
	flex: 1;
	text-align: center;
	font-size: 12px;
	color: var(--muted);
	letter-spacing: 0.03em;
	white-space: nowrap;
	overflow: hidden;
	text-overflow: ellipsis;
}

.header-spacer {
	flex: none;
	width: 50px;
}

.terminal__body {
	flex: 1;
	display: flex;
	flex-direction: column;
	min-height: 0;
}

.log {
	flex: 1;
	overflow-y: auto;
	padding: 20px 24px 6px;
	scrollbar-width: thin;
	scrollbar-color: var(--border) transparent;
}

.log::-webkit-scrollbar {
	width: 10px;
}

.log::-webkit-scrollbar-thumb {
	background: var(--border);
	border-radius: 8px;
	border: 3px solid var(--surface);
}

.log::-webkit-scrollbar-track {
	background: transparent;
}

.line {
	min-height: 1.7em;
	white-space: pre-wrap;
	word-break: break-word;
}

.line--muted {
	color: var(--muted);
}

.line--dim {
	color: var(--dim);
}

.line--accent {
	color: var(--accent);
}

.line--bold {
	font-weight: 700;
}

.line--orange {
	color: var(--orange);
}

.section {
	display: flex;
	align-items: center;
	gap: 14px;
	margin: 22px 0 10px;
	font-size: 11px;
	letter-spacing: 0.18em;
	text-transform: uppercase;
	color: var(--muted);
	user-select: none;
}

.section::before,
.section::after {
	content: "";
	flex: 1;
	height: 1px;
	background: var(--border);
}

a {
	color: var(--accent);
	text-decoration: none;
}

a:hover {
	text-decoration: underline;
	text-underline-offset: 3px;
}

.pre {
	margin: 2px 0 14px;
	white-space: pre-wrap;
	word-break: break-word;
}

.help {
	margin: 2px 0 14px;
}

.help-row {
	display: grid;
	grid-template-columns: 88px 1fr;
	gap: 14px;
	margin: 5px 0;
	font-size: 13px;
}

.help-cmd {
	color: var(--accent);
}

.help-desc {
	color: var(--muted);
}

.skills {
	margin: 2px 0 14px;
}

.skill {
	display: grid;
	grid-template-columns: 130px 1fr 42px;
	gap: 14px;
	align-items: center;
	margin: 11px 0;
	font-size: 13px;
}

.skill__name {
	letter-spacing: 0.02em;
}

.skill__bar {
	display: block;
	height: 4px;
	border-radius: 2px;
	background: var(--track);
	overflow: hidden;
}

.skill__fill {
	display: block;
	height: 100%;
	border-radius: 2px;
	background: var(--accent-soft);
	transform-origin: left;
	animation: grow 0.9s cubic-bezier(0.22, 0.61, 0.36, 1) both;
}

@keyframes grow {
	from {
		transform: scaleX(0);
	}
}

.skill__pct {
	color: var(--muted);
	font-size: 12px;
	text-align: right;
}

.contacts {
	margin: 2px 0 14px;
}

.contact {
	display: grid;
	grid-template-columns: 90px 1fr;
	gap: 14px;
	margin: 7px 0;
	font-size: 13px;
}

.contact__k {
	color: var(--muted);
}

.prompt-line {
	flex: none;
	display: flex;
	align-items: baseline;
	gap: 10px;
	padding: 10px 24px 20px;
}

.prompt {
	flex: none;
	color: var(--accent);
	font-weight: 700;
	white-space: nowrap;
}

.prompt-line input {
	flex: 1;
	min-width: 0;
	background: transparent;
	border: none;
	outline: none;
	padding: 0;
	color: var(--text);
	font: inherit;
	caret-color: var(--accent);
}

.prompt-line input::placeholder {
	color: var(--muted);
	opacity: 0.55;
}

.hidden {
	display: none !important;
}

@media (max-width: 600px) {
	body {
		padding: 12px 10px;
		font-size: 12.5px;
	}

	.terminal {
		border-radius: 12px;
	}

	.log {
		padding: 16px 16px 4px;
	}

	.prompt-line {
		padding: 8px 16px 16px;
	}

	.terminal__title {
		font-size: 11px;
	}

	.skill {
		grid-template-columns: 96px 1fr 38px;
		gap: 10px;
	}

	.contact,
	.help-row {
		grid-template-columns: 74px 1fr;
		gap: 10px;
	}
}

@media (prefers-reduced-motion: reduce) {
	.skill__fill {
		animation: none;
	}
}
