:root {
	--ink-900: #102417;
	--ink-700: #2f4b3a;
	--ink-500: #54715f;
	--paper: #f8fbf6;
	--card: #ffffff;
	--line: #d7e5d5;
	--mint-100: #e8f8e8;
	--mint-300: #c2eec2;
	--mint-500: #4fa86e;
	--mint-700: #247044;
	--gold-500: #d39b34;
	--berry-500: #b34b5e;
	--sky-500: #3f8bbd;
}

* {
	box-sizing: border-box;
	margin: 0;
	padding: 0;
}

body {
	background: var(--paper);
	color: var(--ink-900);
	font-family: "Outfit", "Segoe UI", sans-serif;
	position: relative;
}

.dashboard-bg {
	position: fixed;
	inset: 0;
	z-index: -1;
	background:
		radial-gradient(45rem 30rem at -5% -10%, rgba(79, 168, 110, 0.18) 0%, transparent 70%),
		radial-gradient(45rem 35rem at 100% 0%, rgba(63, 139, 189, 0.14) 0%, transparent 72%),
		linear-gradient(180deg, #f8fcf7 0%, #eef6ef 100%);
}

.dashboard-wrapper {
	padding: 18px 14px 28px;
}

.dashboard {
	max-width: 1180px;
	margin: 0 auto;
	animation: dashboardReveal 560ms ease both;
}

.hero-card {
	border: 1px solid #cae4cf;
	border-radius: 22px;
	padding: 22px;
	background: linear-gradient(120deg, #f2fbef 0%, #e4f4f7 52%, #f9fff6 100%);
	box-shadow: 0 14px 34px rgba(37, 87, 56, 0.12);
	margin-bottom: 18px;
}

.eyebrow {
	font-family: "Sora", "Segoe UI", sans-serif;
	font-size: 12px;
	letter-spacing: 0.08em;
	text-transform: uppercase;
	color: var(--mint-700);
	margin-bottom: 10px;
}

.hero-card h2 {
	font-family: "Sora", "Segoe UI", sans-serif;
	font-size: clamp(1.4rem, 4.2vw, 2rem);
	line-height: 1.15;
	margin-bottom: 8px;
}

.hero-card #userEmail {
	color: var(--ink-700);
	font-size: 0.98rem;
}

.hero-actions {
	display: grid;
	gap: 10px;
	margin-top: 16px;
}

.btn-ghost {
	text-align: center;
	text-decoration: none;
	font-weight: 700;
	color: var(--ink-900);
	border: 1px solid #bdd8c3;
	border-radius: 12px;
	padding: 11px 14px;
	background: rgba(255, 255, 255, 0.72);
	transition: 0.2s ease;
}

.btn-ghost:hover {
	transform: translateY(-2px);
	border-color: #9acaa7;
	background: #fff;
}

.profile-card {
	background: var(--card);
	border: 1px solid var(--line);
	padding: 18px;
	border-radius: 20px;
	margin-bottom: 18px;
	box-shadow: 0 10px 24px rgba(24, 55, 36, 0.08);
	display: flex;
	flex-direction: column;
	gap: 14px;
}

.college-logo-card {
	display: none;
	justify-content: center;
	align-items: center;
	background: rgba(255, 255, 255, 0.72);
	border: 1px solid var(--line);
	border-radius: 18px;
	padding: 28px 22px;
	min-height: 180px;
	margin: -6px 0 18px;
	box-shadow: 0 8px 18px rgba(24, 55, 36, 0.06);
}

.college-logo-card img {
	display: block;
	width: min(100%, 440px);
	max-width: 100%;
	max-height: 140px;
	object-fit: contain;
	object-position: center;
}

.profile-left {
	display: flex;
	align-items: center;
	gap: 13px;
}

.profile-img {
	width: 70px;
	height: 70px;
	border-radius: 50%;
	object-fit: cover;
	border: 4px solid var(--mint-300);
}

#profileName {
	font-family: "Sora", "Segoe UI", sans-serif;
	margin-bottom: 4px;
}

#profileEmail {
	color: var(--ink-700);
	font-size: 0.92rem;
}

.profile-subtext {
	color: var(--ink-500);
	font-size: 0.9rem;
	margin-top: 4px;
}

.profile-subtext.is-premium {
	color: var(--mint-700);
	font-weight: 700;
}

.stats-grid {
	display: grid;
	grid-template-columns: 1fr;
	gap: 12px;
	margin-bottom: 18px;
}

.stat-card {
	border-radius: 18px;
	padding: 16px;
	border: 1px solid #d5e5d7;
	box-shadow: 0 7px 16px rgba(25, 61, 39, 0.06);
	transition: 0.22s ease;
}

.stat-card:hover {
	transform: translateY(-3px);
}

.stat-label {
	font-size: 0.84rem;
	color: var(--ink-700);
	margin-bottom: 7px;
	text-transform: uppercase;
	letter-spacing: 0.04em;
}

.stat-card h3 {
	font-family: "Sora", "Segoe UI", sans-serif;
	font-size: clamp(1.3rem, 4vw, 1.7rem);
}

.stat-score {
	background: linear-gradient(135deg, #f1fcec 0%, #d8f3d6 100%);
}

.stat-coins {
	background: linear-gradient(135deg, #fff9ea 0%, #ffe7b6 100%);
}

.stat-coins h3 {
	color: #8b6115;
}

.stat-streak {
	background: linear-gradient(135deg, #fff0f2 0%, #ffd9df 100%);
}

.stat-streak h3 {
	color: #8c2d41;
}

.stat-played {
	background: linear-gradient(135deg, #edf7ff 0%, #cde8ff 100%);
}

.stat-played h3 {
	color: #1f5f8a;
}

.dashboard-panels {
	display: grid;
	gap: 14px;
}

.card {
	background: var(--card);
	padding: 18px;
	border-radius: 20px;
	border: 1px solid var(--line);
	box-shadow: 0 10px 22px rgba(25, 61, 39, 0.06);
}

.card h3 {
	font-family: "Sora", "Segoe UI", sans-serif;
	font-size: 1.05rem;
	margin-bottom: 10px;
}

#todayStatus {
	color: var(--ink-700);
	margin-bottom: 14px;
}

.achievements-grid {
	display: grid;
	grid-template-columns: repeat(1, 1fr);
	gap: 10px;
	margin-top: 10px;
}

.achievement-badge {
	background: linear-gradient(145deg, #edf9ec 0%, #d8f1d7 100%);
	border: 1px solid #c6e3c7;
	color: #1c5a35;
	padding: 11px 12px;
	border-radius: 11px;
	text-align: center;
	font-size: 0.83rem;
	font-weight: 600;
	transition: 0.2s ease;
}

.achievement-badge:hover {
	transform: translateY(-2px);
}

.heatmap-grid {
	display: grid;
	grid-template-columns: repeat(10, 1fr);
	gap: 6px;
	margin-top: 10px;
}

.heatmap-cell {
	width: 100%;
	aspect-ratio: 1;
	border-radius: 5px;
	background: #e7eee5;
	border: 1px solid #d5e1d4;
}

.heatmap-active {
	background: var(--mint-500);
	border-color: #3f8f5b;
	box-shadow: 0 0 0 1px rgba(39, 109, 66, 0.2);
}

.btn-primary {
	background: linear-gradient(120deg, var(--mint-700) 0%, #2f8e56 100%);
	color: #fff;
	padding: 11px 14px;
	border-radius: 11px;
	border: none;
	cursor: pointer;
	font-size: 0.95rem;
	font-weight: 700;
	width: 100%;
	transition: 0.22s ease;
}

#editProfileBtn {
	width: auto;
	min-width: 128px;
	align-self: flex-end;
	padding-inline: 16px;
}

.btn-primary:hover {
	transform: translateY(-2px);
	filter: brightness(1.04);
}

.modal {
	display: none;
	position: fixed;
	inset: 0;
	background: rgba(7, 23, 13, 0.52);
	justify-content: center;
	align-items: center;
	z-index: 1000;
	padding: 15px;
}

.modal-content {
	background: #fefefe;
	padding: 22px;
	border-radius: 16px;
	width: 100%;
	max-width: 420px;
	border: 1px solid var(--line);
	box-shadow: 0 14px 34px rgba(9, 26, 16, 0.2);
}

.modal-content h3 {
	font-family: "Sora", "Segoe UI", sans-serif;
	margin-bottom: 14px;
}

.modal-content input {
	width: 100%;
	padding: 11px;
	margin-bottom: 10px;
	border-radius: 10px;
	border: 1px solid #cad9cb;
	font-size: 0.94rem;
	font-family: "Outfit", "Segoe UI", sans-serif;
}

.modal-actions-row {
	margin-top: 15px;
	display: flex;
	gap: 10px;
}

@keyframes dashboardReveal {
	from {
		opacity: 0;
		transform: translateY(8px);
	}
	to {
		opacity: 1;
		transform: translateY(0);
	}
}

@media (min-width: 720px) {
	.dashboard-wrapper {
		padding: 24px 18px 34px;
	}

	.college-logo-card {
		padding: 32px 28px;
		min-height: 200px;
	}

	.college-logo-card img {
		width: min(100%, 520px);
		max-height: 160px;
	}

	.hero-card {
		display: flex;
		justify-content: space-between;
		align-items: center;
		gap: 16px;
	}

	.hero-actions {
		grid-template-columns: repeat(2, minmax(140px, 1fr));
		margin-top: 0;
		min-width: 320px;
	}

	.profile-card {
		flex-direction: row;
		align-items: center;
		justify-content: space-between;
	}

	.profile-img {
		width: 76px;
		height: 76px;
	}

	.stats-grid {
		grid-template-columns: repeat(2, 1fr);
	}

	.achievements-grid {
		grid-template-columns: repeat(2, 1fr);
	}

	.heatmap-grid {
		grid-template-columns: repeat(15, 1fr);
	}
}

@media (min-width: 1080px) {
	.dashboard-wrapper {
		padding: 34px 20px 46px;
	}

	.college-logo-card {
		padding: 36px 32px;
		min-height: 220px;
	}

	.college-logo-card img {
		width: min(100%, 580px);
		max-height: 180px;
	}

	.stats-grid {
		grid-template-columns: repeat(4, 1fr);
	}

	.dashboard-panels {
		grid-template-columns: 1fr 1fr;
	}

	.today-card {
		grid-column: 1 / 2;
	}

	.achievements-card {
		grid-column: 2 / 3;
	}

	.heatmap-card {
		grid-column: 1 / 3;
	}

	.achievements-grid {
		grid-template-columns: repeat(3, 1fr);
	}
}

@media (max-width: 480px) {
	.modal-actions-row {
		flex-direction: column;
	}
}