/* ============================================
   Huynh Trinh Ngoc — Academic Homepage
   ============================================ */

/* ---------- Reset & Base ---------- */
*,
*::before,
*::after {
	margin: 0;
	padding: 0;
	box-sizing: border-box;
}

:root {
	--primary: #1a5276;
	--primary-light: #2980b9;
	--accent: #e74c3c;
	--bg: #fafafa;
	--card-bg: #ffffff;
	--text: #333333;
	--text-light: #666666;
	--border: #e0e0e0;
	--shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
	--radius: 8px;
	--max-width: 960px;
	--font-sans: "Segoe UI", Tahoma, Geneva, Verdana, sans-serif;
	--font-mono: "Consolas", "Courier New", monospace;
}

html {
	scroll-behavior: smooth;
}

body {
	font-family: var(--font-sans);
	background: var(--bg);
	color: var(--text);
	line-height: 1.7;
	font-size: 16px;
}

a {
	color: var(--primary-light);
	text-decoration: none;
	transition: color 0.2s;
}

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

img {
	max-width: 100%;
	height: auto;
}

/* ---------- Navigation ---------- */
.navbar {
	background: var(--primary);
	padding: 0;
	position: sticky;
	top: 0;
	z-index: 1000;
	box-shadow: 0 2px 6px rgba(0, 0, 0, 0.15);
}

.navbar .nav-container {
	max-width: var(--max-width);
	margin: 0 auto;
	display: flex;
	align-items: center;
	justify-content: space-between;
	padding: 0 24px;
}

.navbar .nav-brand {
	color: #fff;
	font-size: 1.15rem;
	font-weight: 700;
	padding: 14px 0;
	text-decoration: none;
}

.navbar .nav-brand:hover {
	color: #fff;
	text-decoration: none;
}

.navbar .nav-links {
	list-style: none;
	display: flex;
	gap: 4px;
}

.navbar .nav-links a {
	color: rgba(255, 255, 255, 0.85);
	padding: 14px 18px;
	display: block;
	font-size: 0.95rem;
	font-weight: 500;
	transition: background 0.2s, color 0.2s;
	border-bottom: 3px solid transparent;
}

.navbar .nav-links a:hover,
.navbar .nav-links a.active {
	background: rgba(255, 255, 255, 0.1);
	color: #fff;
	text-decoration: none;
	border-bottom-color: var(--accent);
}

/* ---------- Main Container ---------- */
.container {
	max-width: var(--max-width);
	margin: 0 auto;
	padding: 40px 24px;
}

/* ---------- Hero / Profile Section ---------- */
.hero {
	display: flex;
	gap: 40px;
	align-items: flex-start;
	margin-bottom: 48px;
	background: var(--card-bg);
	padding: 36px;
	border-radius: var(--radius);
	box-shadow: var(--shadow);
}

.hero-avatar {
	width: 200px;
	height: 200px;
	border-radius: 50%;
	object-fit: cover;
	object-position: center 20%;
	border: 5px solid var(--primary);
	box-shadow: 0 4px 12px rgba(0, 0, 0, 0.12);
}

.hero-info {
	flex: 1;
}

.hero-info h1 {
	font-size: 2rem;
	color: var(--primary);
	margin-bottom: 8px;
}

.hero-info .subtitle {
	font-size: 1.1rem;
	color: var(--text-light);
	margin-bottom: 16px;
}

.hero-info .bio {
	font-size: 1rem;
	color: var(--text);
	margin-bottom: 20px;
	line-height: 1.8;
}

.contact-list {
	display: flex;
	flex-wrap: wrap;
	gap: 12px;
}

.contact-item {
	display: inline-flex;
	align-items: center;
	gap: 8px;
	padding: 8px 16px;
	background: var(--bg);
	border: 1px solid var(--border);
	border-radius: 24px;
	font-size: 0.92rem;
	color: var(--text);
	text-decoration: none;
	transition: all 0.2s ease;
}

.contact-item:hover {
	background: var(--primary);
	color: #fff;
	border-color: var(--primary);
	text-decoration: none;
	transform: translateY(-1px);
	box-shadow: 0 3px 10px rgba(26, 82, 118, 0.2);
}

.contact-item:hover svg {
	color: #fff;
}

.contact-item svg {
	flex-shrink: 0;
	color: var(--primary-light);
	transition: color 0.2s ease;
}

/* ---------- Section ---------- */
.section {
	margin-bottom: 48px;
}

.section-title {
	font-size: 1.5rem;
	color: var(--primary);
	border-bottom: 3px solid var(--primary);
	padding-bottom: 10px;
	margin-bottom: 28px;
}

/* ---------- Cards ---------- */
.card {
	background: var(--card-bg);
	border-radius: var(--radius);
	box-shadow: var(--shadow);
	padding: 24px 28px;
	margin-bottom: 20px;
	transition: box-shadow 0.2s, transform 0.2s;
	border-left: 4px solid var(--primary);
}

.card:hover {
	box-shadow: 0 4px 16px rgba(0, 0, 0, 0.12);
	transform: translateY(-2px);
}

.card .card-title {
	font-size: 1.1rem;
	font-weight: 700;
	color: var(--text);
	margin-bottom: 6px;
}

.card .card-title a {
	color: var(--primary);
}

.card .card-title a:hover {
	color: var(--accent);
}

.card .card-authors {
	font-size: 0.92rem;
	color: var(--text-light);
	margin-bottom: 4px;
}

.card .card-authors .highlight {
	font-weight: 600;
	color: var(--text);
}

.card .card-venue {
	font-size: 0.9rem;
	color: var(--text-light);
	font-style: italic;
	margin-bottom: 8px;
}

.card .card-badges {
	display: flex;
	flex-wrap: wrap;
	gap: 8px;
	margin-top: 8px;
}

.badge {
	display: inline-block;
	font-size: 0.78rem;
	font-weight: 600;
	padding: 3px 10px;
	border-radius: 12px;
	text-transform: uppercase;
	letter-spacing: 0.3px;
}

.badge-year {
	background: #ebf5fb;
	color: var(--primary-light);
}

.badge-journal {
	background: #eafaf1;
	color: #27ae60;
}

.badge-conference {
	background: #fef9e7;
	color: #f39c12;
}

.badge-preprint {
	background: #f4ecf7;
	color: #8e44ad;
}

.badge-ongoing {
	background: #fdedec;
	color: var(--accent);
}

.badge-completed {
	background: #eafaf1;
	color: #27ae60;
}

.badge-unavailable {
	background: #f2f3f4;
	color: #95a5a6;
}

.badge-link a {
	color: var(--primary-light);
	font-size: 0.85rem;
}

/* ---------- Project Cards ---------- */
.project-card {
	background: var(--card-bg);
	border-radius: var(--radius);
	box-shadow: var(--shadow);
	padding: 28px;
	margin-bottom: 20px;
	border-left: 4px solid var(--primary-light);
	transition: box-shadow 0.2s, transform 0.2s;
}

.project-card:hover {
	box-shadow: 0 4px 16px rgba(0, 0, 0, 0.12);
	transform: translateY(-2px);
}

.project-card .project-header {
	display: flex;
	justify-content: space-between;
	align-items: flex-start;
	gap: 16px;
	margin-bottom: 10px;
}

.project-card .project-title {
	font-size: 1.1rem;
	font-weight: 700;
	color: var(--primary);
	flex: 1;
}

.project-card .project-meta {
	font-size: 0.88rem;
	color: var(--text-light);
	margin-bottom: 6px;
}

.project-card .project-description {
	font-size: 0.95rem;
	color: var(--text);
	line-height: 1.7;
	margin-top: 10px;
}

.project-card .project-role {
	font-size: 0.9rem;
	color: var(--text-light);
	margin-top: 4px;
}

.project-card .project-awards {
	margin-top: 12px;
	padding-top: 12px;
	border-top: 1px solid var(--border);
}

.project-card .project-awards li {
	font-size: 0.9rem;
	color: var(--text);
	margin-left: 16px;
	margin-bottom: 4px;
}

/* ---------- Education & Experience Timeline ---------- */
.timeline {
	position: relative;
	padding-left: 28px;
}

.timeline::before {
	content: "";
	position: absolute;
	left: 8px;
	top: 0;
	bottom: 0;
	width: 3px;
	background: var(--primary);
	border-radius: 2px;
}

.timeline-item {
	position: relative;
	margin-bottom: 28px;
	background: var(--card-bg);
	padding: 20px 24px;
	border-radius: var(--radius);
	box-shadow: var(--shadow);
}

.timeline-item::before {
	content: "";
	position: absolute;
	left: -24px;
	top: 24px;
	width: 13px;
	height: 13px;
	background: var(--primary-light);
	border: 3px solid var(--bg);
	border-radius: 50%;
}

.timeline-item .timeline-title {
	font-size: 1.05rem;
	font-weight: 700;
	color: var(--text);
}

.timeline-item .timeline-subtitle {
	font-size: 0.92rem;
	color: var(--primary-light);
	font-weight: 500;
}

.timeline-item .timeline-date {
	font-size: 0.85rem;
	color: var(--text-light);
	margin-top: 2px;
}

.timeline-item .timeline-desc {
	font-size: 0.95rem;
	color: var(--text);
	margin-top: 8px;
	line-height: 1.7;
}

/* ---------- Awards List ---------- */
.awards-list {
	list-style: none;
}

.awards-list li {
	position: relative;
	padding: 14px 20px 14px 40px;
	margin-bottom: 12px;
	background: var(--card-bg);
	border-radius: var(--radius);
	box-shadow: var(--shadow);
	font-size: 0.95rem;
	border-left: 4px solid #f39c12;
}

.awards-list li::before {
	content: "🏆";
	position: absolute;
	left: 14px;
	top: 14px;
}

/* ---------- Publications Page Specific ---------- */
.filter-bar {
	display: flex;
	flex-wrap: wrap;
	gap: 10px;
	margin-bottom: 28px;
}

.filter-btn {
	padding: 8px 18px;
	border: 2px solid var(--border);
	border-radius: 20px;
	background: var(--card-bg);
	font-size: 0.88rem;
	font-weight: 500;
	color: var(--text-light);
	cursor: pointer;
	transition: all 0.2s;
}

.filter-btn:hover,
.filter-btn.active {
	border-color: var(--primary);
	color: var(--primary);
	background: #ebf5fb;
}

/* ---------- Page Header ---------- */
.page-header {
	text-align: center;
	margin-bottom: 40px;
}

.page-header h1 {
	font-size: 2rem;
	color: var(--primary);
	margin-bottom: 8px;
}

.page-header p {
	font-size: 1.05rem;
	color: var(--text-light);
}

/* ---------- Footer ---------- */
.footer {
	text-align: center;
	padding: 28px 24px;
	color: var(--text-light);
	font-size: 0.85rem;
	border-top: 1px solid var(--border);
	margin-top: 40px;
}

/* ---------- Responsive ---------- */
@media (max-width: 768px) {
	.hero {
		flex-direction: column;
		align-items: center;
		text-align: center;
		padding: 28px 20px;
	}

	.hero-info h1 {
		font-size: 1.6rem;
	}

	.contact-list {
		justify-content: center;
	}

	.navbar .nav-container {
		flex-direction: column;
		padding: 0;
	}

	.navbar .nav-brand {
		padding: 12px 0 0;
	}

	.navbar .nav-links {
		width: 100%;
		justify-content: center;
		padding-bottom: 0;
	}

	.navbar .nav-links a {
		padding: 10px 14px;
		font-size: 0.88rem;
	}

	.container {
		padding: 24px 16px;
	}

	.project-card .project-header {
		flex-direction: column;
	}
}
