/* ==========================================================================
   AI4Viaevum — main stylesheet
   Dark hero + light content. System font stack, zero external assets.
   ========================================================================== */

:root {
	--ink:        #0b1220;
	--ink-2:      #101c33;
	--ink-3:      #16233f;
	--paper:      #f6f8fc;
	--card:       #ffffff;
	--line:       #e3e9f2;
	--text:       #1f2a3d;
	--muted:      #5b6b84;
	--muted-dark: #9fb0c9;
	--accent:     #22d3ee;
	--accent-2:   #34d399;
	--accent-ink: #0e7490;
	--radius:     16px;
	--shadow:     0 10px 30px rgba(11, 18, 32, .08);
	--shadow-lg:  0 20px 50px rgba(11, 18, 32, .14);
	--font: -apple-system, BlinkMacSystemFont, "Segoe UI", "Helvetica Neue", Arial,
	        "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", sans-serif;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
	margin: 0;
	font-family: var(--font);
	color: var(--text);
	background: var(--paper);
	line-height: 1.65;
	-webkit-font-smoothing: antialiased;
}

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

a { color: var(--accent-ink); }

.container {
	width: min(1140px, 92vw);
	margin: 0 auto;
}

section[id], footer[id] { scroll-margin-top: 84px; }

/* ---------------------------------------------------------------- header */

.site-header {
	position: fixed;
	inset: 0 0 auto 0;
	z-index: 100;
	transition: background .3s ease, box-shadow .3s ease;
	background: linear-gradient(180deg, rgba(11,18,32,.72), rgba(11,18,32,0));
}
.site-header.scrolled {
	background: rgba(11, 18, 32, .92);
	backdrop-filter: blur(12px);
	box-shadow: 0 6px 24px rgba(0, 0, 0, .25);
}

.nav-wrap {
	display: flex;
	align-items: center;
	justify-content: space-between;
	padding: 14px 0;
}

.brand {
	display: inline-flex;
	align-items: center;
	gap: 10px;
	text-decoration: none;
}
.brand-mark {
	display: inline-grid;
	place-items: center;
	width: 38px; height: 38px;
	border-radius: 11px;
	font-weight: 800;
	font-size: 14px;
	letter-spacing: .5px;
	color: var(--ink);
	background: linear-gradient(135deg, var(--accent), var(--accent-2));
	box-shadow: 0 4px 14px rgba(34, 211, 238, .35);
}
.brand-name {
	font-weight: 700;
	font-size: 18px;
	letter-spacing: .3px;
	color: #fff;
}

.site-nav { display: flex; align-items: center; gap: 26px; }
.site-nav a {
	color: #dbe5f3;
	text-decoration: none;
	font-size: 15px;
	font-weight: 500;
	opacity: .9;
	transition: opacity .2s, color .2s;
}
.site-nav a:hover { opacity: 1; color: var(--accent); }
.site-nav .nav-cta {
	padding: 8px 18px;
	border: 1px solid rgba(34, 211, 238, .55);
	border-radius: 999px;
	color: var(--accent);
}
.site-nav .nav-cta:hover { background: rgba(34, 211, 238, .12); }

.nav-toggle {
	display: none;
	flex-direction: column;
	gap: 5px;
	background: none;
	border: 0;
	padding: 8px;
	cursor: pointer;
}
.nav-toggle span {
	width: 24px; height: 2px;
	background: #fff;
	border-radius: 2px;
	transition: transform .25s, opacity .25s;
}

/* ------------------------------------------------------------------ hero */

.hero, .member-hero, .page-hero {
	position: relative;
	overflow: hidden;
	color: #eaf2ff;
	background: radial-gradient(1200px 600px at 78% -10%, #1c3d5a 0%, var(--ink-2) 45%, var(--ink) 100%);
}

.hero-bg { position: absolute; inset: 0; pointer-events: none; }
.hero-bg::before {
	content: "";
	position: absolute; inset: 0;
	background-image:
		linear-gradient(rgba(148, 178, 220, .07) 1px, transparent 1px),
		linear-gradient(90deg, rgba(148, 178, 220, .07) 1px, transparent 1px);
	background-size: 56px 56px;
	mask-image: radial-gradient(ellipse 90% 70% at 50% 30%, #000 30%, transparent 75%);
}
.hero-bg::after {
	content: "";
	position: absolute;
	width: 520px; height: 520px;
	right: -140px; top: -120px;
	border-radius: 50%;
	background: radial-gradient(circle, rgba(34, 211, 238, .20), transparent 65%);
	filter: blur(10px);
}

.hero-inner {
	position: relative;
	padding: 168px 0 96px;
	max-width: 1140px;
}

.hero-badge {
	display: inline-block;
	padding: 7px 16px;
	border-radius: 999px;
	border: 1px solid rgba(34, 211, 238, .4);
	background: rgba(34, 211, 238, .08);
	color: var(--accent);
	font-size: 13.5px;
	font-weight: 600;
	letter-spacing: .6px;
	text-transform: uppercase;
}

.hero h1 {
	margin: 22px 0 18px;
	font-size: clamp(38px, 6vw, 64px);
	line-height: 1.08;
	font-weight: 800;
	letter-spacing: -.5px;
}
.grad {
	background: linear-gradient(92deg, var(--accent) 10%, var(--accent-2) 90%);
	-webkit-background-clip: text;
	background-clip: text;
	color: transparent;
}

.hero-sub {
	max-width: 680px;
	margin: 0 0 34px;
	font-size: clamp(16px, 2vw, 19px);
	color: var(--muted-dark);
}

.hero-cta { display: flex; flex-wrap: wrap; gap: 14px; }

.btn {
	display: inline-block;
	padding: 13px 28px;
	border-radius: 999px;
	font-weight: 600;
	font-size: 15px;
	text-decoration: none;
	transition: transform .18s ease, box-shadow .18s ease, background .18s ease;
}
.btn:active { transform: translateY(1px); }
.btn-primary {
	color: var(--ink);
	background: linear-gradient(135deg, var(--accent), var(--accent-2));
	box-shadow: 0 8px 24px rgba(34, 211, 238, .30);
}
.btn-primary:hover { box-shadow: 0 12px 32px rgba(34, 211, 238, .45); transform: translateY(-2px); }
.btn-ghost {
	color: #eaf2ff;
	border: 1px solid rgba(219, 229, 243, .35);
}
.btn-ghost:hover { background: rgba(255, 255, 255, .08); transform: translateY(-2px); }

.hero-stats {
	display: flex;
	flex-wrap: wrap;
	gap: clamp(24px, 5vw, 64px);
	margin-top: 64px;
	padding-top: 34px;
	border-top: 1px solid rgba(148, 178, 220, .18);
}
.stat strong {
	display: block;
	font-size: clamp(26px, 3.4vw, 38px);
	font-weight: 800;
	color: #fff;
}
.stat span { color: var(--muted-dark); font-size: 14px; }

/* -------------------------------------------------------------- sections */

.section { padding: 92px 0; }
.section-alt { background: #eef2f9; }
.section-dark {
	background: linear-gradient(180deg, var(--ink) 0%, var(--ink-2) 100%);
	color: #dbe5f3;
}

.section-head { max-width: 720px; margin-bottom: 52px; }
.section-head h2 {
	margin: 10px 0 12px;
	font-size: clamp(28px, 4vw, 40px);
	font-weight: 800;
	letter-spacing: -.4px;
	line-height: 1.15;
	color: var(--ink);
}
.section-dark .section-head h2 { color: #fff; }
.section-head p { margin: 0; color: var(--muted); font-size: 16.5px; }
.section-dark .section-head p { color: var(--muted-dark); }

.kicker {
	display: inline-block;
	font-size: 13px;
	font-weight: 700;
	letter-spacing: 1.6px;
	text-transform: uppercase;
	color: var(--accent-ink);
}
.section-dark .kicker { color: var(--accent); }

/* ----------------------------------------------------------------- about */

.about-grid {
	display: grid;
	grid-template-columns: 1.05fr .95fr;
	gap: 56px;
	align-items: start;
}
.about-text p { font-size: 17px; margin: 0 0 18px; color: #34435c; }

.pillars { display: grid; gap: 18px; }
.pillar {
	background: var(--card);
	border: 1px solid var(--line);
	border-radius: var(--radius);
	padding: 24px 26px;
	box-shadow: var(--shadow);
	transition: transform .2s ease, box-shadow .2s ease;
}
.pillar:hover { transform: translateY(-4px); box-shadow: var(--shadow-lg); }
.pillar h3 { margin: 0 0 8px; font-size: 18px; color: var(--ink); }
.pillar p { margin: 0; color: var(--muted); font-size: 15px; }

/* ---------------------------------------------------------- achievements */

.ach-grid {
	display: grid;
	grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
	gap: 20px;
}
.ach-card {
	background: rgba(255, 255, 255, .045);
	border: 1px solid rgba(148, 178, 220, .16);
	border-radius: var(--radius);
	padding: 26px 26px 24px;
	transition: transform .2s ease, border-color .2s ease, background .2s ease;
}
.ach-card:hover {
	transform: translateY(-4px);
	border-color: rgba(34, 211, 238, .45);
	background: rgba(34, 211, 238, .06);
}
.ach-rank {
	display: inline-block;
	padding: 5px 12px;
	border-radius: 999px;
	font-size: 12.5px;
	font-weight: 700;
	letter-spacing: .4px;
	color: var(--ink);
	background: linear-gradient(135deg, var(--accent), var(--accent-2));
	margin-bottom: 14px;
}
.ach-ongoing .ach-rank {
	color: var(--accent);
	background: rgba(34, 211, 238, .12);
	border: 1px solid rgba(34, 211, 238, .4);
}
.ach-card h3 { margin: 0 0 10px; font-size: 17.5px; line-height: 1.4; color: #fff; }
.ach-card p { margin: 0; font-size: 14.5px; color: var(--muted-dark); }

/* -------------------------------------------------------------- projects */

.proj-group { margin-bottom: 56px; }
.proj-group:last-child { margin-bottom: 0; }
.proj-group-title {
	font-size: 15px;
	font-weight: 700;
	letter-spacing: 1.2px;
	text-transform: uppercase;
	color: var(--accent-ink);
	margin: 0 0 20px;
	padding-bottom: 12px;
	border-bottom: 2px solid var(--line);
}

.proj-grid {
	display: grid;
	grid-template-columns: repeat(auto-fill, minmax(330px, 1fr));
	gap: 20px;
}
.proj-card {
	background: var(--card);
	border: 1px solid var(--line);
	border-radius: var(--radius);
	padding: 28px;
	box-shadow: var(--shadow);
	transition: transform .2s ease, box-shadow .2s ease;
}
.proj-card:hover { transform: translateY(-4px); box-shadow: var(--shadow-lg); }
.proj-head { display: flex; align-items: center; gap: 12px; }
.proj-head h4 { margin: 0; font-size: 21px; color: var(--ink); }
.proj-flag {
	padding: 3px 10px;
	border-radius: 999px;
	font-size: 11.5px;
	font-weight: 700;
	letter-spacing: .5px;
	text-transform: uppercase;
	color: var(--accent-ink);
	background: rgba(34, 211, 238, .14);
}
.proj-sub { margin: 6px 0 12px; font-size: 14px; font-weight: 600; color: var(--accent-ink); }
.proj-card > p:not(.proj-sub) { margin: 0 0 16px; font-size: 15px; color: var(--muted); }

.tags { display: flex; flex-wrap: wrap; gap: 8px; }
.tags span {
	padding: 4px 11px;
	border-radius: 999px;
	font-size: 12.5px;
	color: #40506a;
	background: #eef2f9;
	border: 1px solid var(--line);
}

/* ------------------------------------------------------------------ team */

.team-group { margin-bottom: 56px; }
.team-group:last-child { margin-bottom: 0; }
.team-group-head { margin-bottom: 22px; }
.team-group-head h3 { margin: 0 0 4px; font-size: 22px; color: var(--ink); }
.team-group-head p { margin: 0; color: var(--muted); font-size: 14.5px; }

.member-grid {
	display: grid;
	grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
	gap: 18px;
}
.member-card {
	display: flex;
	flex-direction: column;
	align-items: flex-start;
	gap: 4px;
	background: var(--card);
	border: 1px solid var(--line);
	border-radius: var(--radius);
	padding: 24px 22px;
	text-decoration: none;
	color: var(--text);
	box-shadow: var(--shadow);
	transition: transform .2s ease, box-shadow .2s ease, border-color .2s ease;
}
.member-card:hover {
	transform: translateY(-4px);
	box-shadow: var(--shadow-lg);
	border-color: rgba(34, 211, 238, .5);
}

.monogram {
	display: inline-grid;
	place-items: center;
	width: 56px; height: 56px;
	border-radius: 16px;
	font-weight: 800;
	font-size: 20px;
	letter-spacing: .5px;
	color: #fff;
	background: linear-gradient(135deg,
		hsl(var(--h, 200), 72%, 55%),
		hsl(calc(var(--h, 200) + 42), 70%, 42%));
	margin-bottom: 12px;
}
.monogram-xl {
	width: 108px; height: 108px;
	border-radius: 28px;
	font-size: 40px;
	margin-bottom: 0;
	box-shadow: 0 14px 34px rgba(0, 0, 0, .35);
}

.member-name { font-size: 17px; font-weight: 700; color: var(--ink); }
.member-role { font-size: 13.5px; font-weight: 600; color: var(--accent-ink); }
.member-aff { font-size: 13px; color: var(--muted); line-height: 1.45; }

/* ------------------------------------------------------- member profile */

.member-hero { padding: 148px 0 64px; }
.member-hero .container { position: relative; }
.back-link {
	display: inline-block;
	margin-bottom: 34px;
	color: var(--muted-dark);
	text-decoration: none;
	font-size: 14px;
}
.back-link:hover { color: var(--accent); }

.member-hero-inner {
	display: flex;
	align-items: center;
	gap: 36px;
}
.member-photo img { width: 108px; height: 108px; object-fit: cover; border-radius: 28px; }
.member-hero-text h1 {
	margin: 0 0 6px;
	font-size: clamp(30px, 4.6vw, 44px);
	font-weight: 800;
	letter-spacing: -.4px;
	color: #fff;
}
.member-hero-role { margin: 0 0 16px; font-size: 18px; color: var(--accent); font-weight: 600; }

.member-chips {
	display: flex;
	flex-wrap: wrap;
	gap: 10px;
	margin-bottom: 22px;
}
.chip {
	padding: 6px 14px;
	border-radius: 999px;
	font-size: 13px;
	color: #d5e1f2;
	background: rgba(255, 255, 255, .07);
	border: 1px solid rgba(148, 178, 220, .25);
}
.chip-accent {
	color: var(--accent);
	border-color: rgba(34, 211, 238, .45);
	background: rgba(34, 211, 238, .08);
}

.member-bio { max-width: 760px; font-size: 17px; }
.member-bio p { margin: 0 0 16px; }
.member-more { margin-top: 34px; font-weight: 600; }

/* ------------------------------------------------------------ page shell */

.page-hero { padding: 148px 0 64px; }
.page-hero .container { position: relative; }
.page-hero h1 {
	margin: 0 0 10px;
	font-size: clamp(30px, 4.6vw, 44px);
	font-weight: 800;
	letter-spacing: -.4px;
	color: #fff;
}
.page-hero p { margin: 0; color: var(--muted-dark); font-size: 17px; max-width: 640px; }

.content-flow { max-width: 820px; }
.content-card {
	background: var(--card);
	border: 1px solid var(--line);
	border-radius: var(--radius);
	padding: 26px 28px;
	margin-bottom: 20px;
	box-shadow: var(--shadow);
}
.content-card h2 { margin: 0 0 8px; font-size: 21px; }
.content-card h2 a { color: var(--ink); text-decoration: none; }
.content-card h2 a:hover { color: var(--accent-ink); }
.content-body { color: var(--muted); }

/* ---------------------------------------------------------------- footer */

.site-footer {
	background: var(--ink);
	color: var(--muted-dark);
	padding: 72px 0 30px;
}
.footer-grid {
	display: grid;
	grid-template-columns: 1.4fr 1fr 1.2fr;
	gap: 44px;
	padding-bottom: 44px;
	border-bottom: 1px solid rgba(148, 178, 220, .14);
}
.footer-tag { margin: 16px 0 0; font-size: 14.5px; max-width: 380px; }
.footer-col h4 {
	margin: 0 0 16px;
	font-size: 14px;
	font-weight: 700;
	letter-spacing: 1.2px;
	text-transform: uppercase;
	color: #fff;
}
.footer-col ul { margin: 0; padding: 0; list-style: none; }
.footer-col li { margin-bottom: 12px; font-size: 14.5px; }
.footer-col a { color: var(--accent); text-decoration: none; }
.footer-col a:hover { text-decoration: underline; }
.footer-bottom {
	display: flex;
	flex-wrap: wrap;
	justify-content: space-between;
	gap: 8px;
	padding-top: 26px;
	font-size: 13px;
	color: #7588a5;
}

/* ------------------------------------------------------------- animation */

.reveal { opacity: 0; transform: translateY(22px); transition: opacity .6s ease, transform .6s ease; }
.reveal.visible { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) {
	.reveal { opacity: 1; transform: none; transition: none; }
	html { scroll-behavior: auto; }
}

/* ------------------------------------------------------------- responsive */

@media (max-width: 900px) {
	.about-grid { grid-template-columns: 1fr; gap: 36px; }
	.footer-grid { grid-template-columns: 1fr 1fr; }
	.member-hero-inner { flex-direction: column; align-items: flex-start; gap: 22px; }
}

@media (max-width: 720px) {
	.section { padding: 64px 0; }
	.hero-inner { padding: 132px 0 72px; }

	.nav-toggle { display: flex; }
	.site-nav {
		position: absolute;
		top: 100%; left: 0; right: 0;
		flex-direction: column;
		align-items: stretch;
		gap: 0;
		background: rgba(11, 18, 32, .97);
		backdrop-filter: blur(12px);
		border-bottom: 1px solid rgba(148, 178, 220, .2);
		max-height: 0;
		overflow: hidden;
		transition: max-height .3s ease;
	}
	.site-nav.open { max-height: 320px; }
	.site-nav a { padding: 14px 5vw; border-top: 1px solid rgba(148, 178, 220, .12); }
	.site-nav .nav-cta { border-radius: 0; border-left: 0; border-right: 0; }

	.footer-grid { grid-template-columns: 1fr; gap: 30px; }
	.footer-bottom { flex-direction: column; }
}
