:root {
	--gg-navy: #1b365d;
	--gg-navy-2: #12243f;
	--gg-gold: #c9a227;
	--gg-gold-2: #e8c96a;
	--gg-cream: #f6f1e8;
	--gg-paper: #fffdf8;
	--gg-ink: #1c1914;
	--gg-muted: #6b6458;
	--gg-line: #e6ddcf;
	--gg-ok: #2f6f4e;
	--gg-warn: #9a4b12;
	--gg-err: #8f2d2d;
	--gg-shadow: 0 18px 50px rgba(27, 54, 93, 0.08);
}

.gg-body {
	margin: 0;
	background: var(--gg-cream);
	color: var(--gg-ink);
	font-family: "DM Sans", system-ui, sans-serif;
	min-height: 100vh;
}

.gg-body a {
	color: var(--gg-navy);
}

.gg-kicker {
	margin: 0 0 6px;
	letter-spacing: 0.14em;
	text-transform: uppercase;
	font-size: 11px;
	color: var(--gg-gold);
	font-weight: 700;
}

h1, h2, h3 {
	font-family: Fraunces, Georgia, serif;
	color: var(--gg-navy);
	font-weight: 600;
	letter-spacing: -0.02em;
}

.gg-mark {
	width: 42px;
	height: 42px;
	border-radius: 12px;
	background: linear-gradient(160deg, var(--gg-navy), var(--gg-navy-2));
	color: var(--gg-gold-2);
	display: inline-flex;
	align-items: center;
	justify-content: center;
	font-family: Fraunces, serif;
	font-weight: 700;
	flex-shrink: 0;
}

.gg-btn {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	border: 0;
	border-radius: 999px;
	padding: 10px 18px;
	font: inherit;
	font-weight: 600;
	cursor: pointer;
	background: #efe8db;
	color: var(--gg-navy);
	text-decoration: none;
}

.gg-btn.gg-btn--primary {
	background: var(--gg-navy);
	color: #fff;
}

.gg-btn--ghost {
	background: transparent;
	border: 1px solid var(--gg-line);
}

.gg-btn--small {
	padding: 6px 12px;
	font-size: 13px;
}

.gg-input {
	width: 100%;
	border: 1px solid var(--gg-line);
	background: #fff;
	border-radius: 12px;
	padding: 12px 14px;
	font: inherit;
	color: inherit;
	box-sizing: border-box;
}

.gg-input:focus {
	outline: 2px solid rgba(27, 54, 93, 0.25);
	border-color: var(--gg-navy);
}

.gg-input--code {
	letter-spacing: 0.4em;
	font-size: 22px;
	text-align: center;
	font-weight: 700;
}

.gg-form {
	display: grid;
	gap: 16px;
}

.gg-form label,
.gg-form-inline label,
.gg-reject label {
	display: grid;
	gap: 6px;
	font-size: 14px;
	font-weight: 600;
}

.gg-form small,
.gg-muted {
	color: var(--gg-muted);
	font-weight: 400;
	font-size: 13px;
}

.gg-grid-2 {
	display: grid;
	grid-template-columns: 1fr 1fr;
	gap: 12px;
}

.gg-lead {
	color: var(--gg-muted);
	line-height: 1.55;
}

.gg-links {
	display: flex;
	gap: 16px;
	flex-wrap: wrap;
	margin-top: 20px;
}

.gg-flash {
	padding: 12px 14px;
	border-radius: 12px;
	margin-bottom: 16px;
}

.gg-flash--success { background: #e7f4ec; color: var(--gg-ok); }
.gg-flash--error { background: #f8eaea; color: var(--gg-err); }
.gg-flash--info { background: #eef3f8; color: var(--gg-navy); }

.gg-auth {
	min-height: 100vh;
	display: grid;
	place-items: center;
	padding: 32px 16px;
}

.gg-auth__panel {
	width: min(460px, 100%);
	background: var(--gg-paper);
	border: 1px solid var(--gg-line);
	border-radius: 28px;
	padding: 36px;
	box-shadow: var(--gg-shadow);
}

.gg-auth__brand {
	display: flex;
	gap: 14px;
	align-items: center;
	margin-bottom: 28px;
}

.gg-auth__brand h1 {
	margin: 0;
	font-size: 22px;
}

.gg-auth__foot {
	color: var(--gg-muted);
	font-size: 13px;
}

.gg-app {
	display: grid;
	grid-template-columns: 260px 1fr;
	min-height: 100vh;
}

.gg-sidebar {
	background: var(--gg-navy-2);
	color: #efe8db;
	padding: 24px 18px;
	display: flex;
	flex-direction: column;
	gap: 24px;
}

.gg-body .gg-sidebar a {
	color: #efe8db;
	text-decoration: none;
}

.gg-sidebar__brand {
	display: flex;
	gap: 12px;
	align-items: center;
}

.gg-sidebar__brand small {
	display: block;
	opacity: 0.7;
	font-size: 12px;
}

.gg-nav {
	display: grid;
	gap: 4px;
}

.gg-nav a {
	padding: 10px 12px;
	border-radius: 10px;
}

.gg-nav a:hover {
	background: rgba(255, 255, 255, 0.08);
}

.gg-nav__label {
	margin: 16px 12px 4px;
	font-size: 11px;
	letter-spacing: 0.12em;
	text-transform: uppercase;
	opacity: 0.55;
}

.gg-badge {
	background: var(--gg-gold);
	color: var(--gg-navy-2);
	border-radius: 999px;
	padding: 0 7px;
	font-size: 11px;
	margin-left: 6px;
	font-weight: 700;
}

.gg-sidebar__user {
	margin-top: auto;
	display: flex;
	gap: 10px;
	align-items: center;
}

.gg-avatar {
	width: 36px;
	height: 36px;
	border-radius: 50%;
	background: var(--gg-gold);
	color: var(--gg-navy-2);
	display: grid;
	place-items: center;
	font-size: 12px;
	font-weight: 700;
}

.gg-main {
	min-width: 0;
}

.gg-top {
	display: flex;
	align-items: center;
	justify-content: flex-end;
	gap: 12px;
	padding: 16px 28px;
	border-bottom: 1px solid var(--gg-line);
	background: rgba(255, 253, 248, 0.8);
}

.gg-content {
	padding: 28px;
	max-width: 980px;
}

.gg-content:has(.gg-members-layout) {
	max-width: 1140px;
}

.gg-members-layout {
	display: grid;
	grid-template-columns: minmax(0, 1.15fr) minmax(280px, 0.9fr);
	gap: 28px;
	align-items: start;
}

.gg-members-layout .gg-section {
	margin-top: 0;
}

.gg-members-layout .gg-section + .gg-section {
	margin-top: 28px;
}

.gg-members-layout__side {
	position: sticky;
	top: 16px;
}

.gg-members-layout__side .gg-section h2 {
	margin-top: 0;
}

.gg-members-layout .gg-user-search-input {
	max-width: none;
}

.gg-pagehead {
	display: flex;
	justify-content: space-between;
	align-items: flex-start;
	gap: 16px;
	margin-bottom: 24px;
}

.gg-pagehead h1 {
	margin: 0 0 6px;
}

.gg-stats {
	display: grid;
	grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
	gap: 12px;
	margin-bottom: 28px;
}

.gg-stat {
	background: var(--gg-paper);
	border: 1px solid var(--gg-line);
	border-radius: 18px;
	padding: 16px 18px;
}

.gg-stat span {
	display: block;
	font-family: Fraunces, serif;
	font-size: 28px;
	color: var(--gg-navy);
}

.gg-section {
	margin: 32px 0;
}

.gg-section__head {
	display: flex;
	justify-content: space-between;
	align-items: center;
	gap: 12px;
	margin-bottom: 12px;
}

.gg-section__head h2 {
	margin: 0;
}

.gg-cards {
	display: grid;
	grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
	gap: 14px;
}

.gg-card {
	display: block;
	background: var(--gg-paper);
	border: 1px solid var(--gg-line);
	border-radius: 20px;
	padding: 18px;
	text-decoration: none;
	color: inherit;
	box-shadow: var(--gg-shadow);
}

.gg-card.is-unlocked {
	border-color: #b7d4c2;
	background: #f3faf5;
}

.gg-card--leader {
	display: grid;
	gap: 10px;
}

.gg-card__actions {
	display: flex;
	flex-wrap: wrap;
	gap: 8px;
	margin-top: 6px;
}

.gg-card--leader .gg-invite {
	margin: 0;
}

.gg-card__meta,
.gg-points {
	display: flex;
	gap: 10px;
	color: var(--gg-muted);
	font-size: 13px;
}

.gg-points {
	font-size: 22px;
	font-family: Fraunces, serif;
	color: var(--gg-navy);
}

.gg-table-wrap {
	overflow: auto;
	background: var(--gg-paper);
	border: 1px solid var(--gg-line);
	border-radius: 18px;
}

.gg-table {
	width: 100%;
	border-collapse: collapse;
}

.gg-table th,
.gg-table td {
	text-align: left;
	padding: 12px 14px;
	border-bottom: 1px solid var(--gg-line);
	vertical-align: top;
}

.gg-table tr.is-me {
	background: #f3ead2;
}

.gg-pill {
	display: inline-block;
	border-radius: 999px;
	padding: 3px 10px;
	font-size: 12px;
	background: #efe8db;
	color: var(--gg-navy);
}

.gg-pill--pending { background: #f3ead2; color: var(--gg-warn); }
.gg-pill--approved { background: #e7f4ec; color: var(--gg-ok); }
.gg-pill--rejected { background: #f8eaea; color: var(--gg-err); }
.gg-pill--warn { background: #f3ead2; color: var(--gg-warn); }
.gg-pill--open { background: #eef3f8; }
.gg-pill--closed { background: #f8eaea; color: var(--gg-err); }

.gg-empty {
	text-align: center;
	padding: 48px 16px;
	background: var(--gg-paper);
	border-radius: 24px;
	border: 1px dashed var(--gg-line);
}

.gg-tabs {
	display: flex;
	flex-wrap: wrap;
	gap: 8px;
	margin-bottom: 24px;
}

.gg-tabs a {
	padding: 8px 12px;
	border-radius: 999px;
	background: #efe8db;
	text-decoration: none;
	font-size: 14px;
	font-weight: 600;
}

.gg-tabs a.is-active {
	background: var(--gg-navy);
	color: #fff;
}

.gg-crumb {
	color: var(--gg-muted);
	font-size: 13px;
}

.gg-prose {
	line-height: 1.65;
	margin-bottom: 20px;
}

.gg-callout {
	padding: 14px 16px;
	border-radius: 14px;
	background: #eef3f8;
	margin-bottom: 16px;
}

.gg-callout--success { background: #e7f4ec; }
.gg-callout--warn { background: #f8efe6; }
.gg-callout--error { background: #f8e8e8; color: #7a1f1f; }

.gg-answer-readonly {
	background: #fff;
	border: 1px solid var(--gg-line);
	border-radius: 14px;
	padding: 14px;
	margin-bottom: 16px;
}

.gg-review {
	background: var(--gg-paper);
	border: 1px solid var(--gg-line);
	border-radius: 18px;
	padding: 16px;
	margin-bottom: 14px;
}

.gg-review header {
	display: flex;
	justify-content: space-between;
	flex-wrap: wrap;
	gap: 8px;
	align-items: center;
	margin-bottom: 10px;
}

.gg-review__actions {
	display: grid;
	gap: 12px;
	margin-top: 12px;
}

.gg-list {
	list-style: none;
	padding: 0;
	margin: 0;
	display: grid;
	gap: 8px;
}

.gg-list a,
.gg-list li {
	display: flex;
	justify-content: space-between;
	gap: 12px;
	background: var(--gg-paper);
	border: 1px solid var(--gg-line);
	border-radius: 14px;
	padding: 12px 14px;
	text-decoration: none;
	color: inherit;
}

.gg-list--messages .is-unread a {
	border-color: var(--gg-gold);
	background: #fbf6e8;
}

.gg-fieldset {
	border: 1px solid var(--gg-line);
	border-radius: 14px;
	padding: 14px;
}

.gg-radio,
.gg-check {
	display: flex !important;
	flex-direction: row;
	align-items: center;
	gap: 8px;
	font-weight: 500 !important;
	margin: 6px 0;
}

.gg-assignees {
	margin-top: 10px;
	display: grid;
	gap: 4px;
}

.gg-form--narrow {
	max-width: 480px;
}

.gg-form--inline-grid {
	grid-template-columns: 140px 1fr 1fr auto;
	align-items: end;
}

.gg-form-inline {
	display: flex;
	gap: 8px;
	margin: 12px 0;
}

.gg-user-search-input {
	width: 100%;
	max-width: 420px;
	margin: 12px 0;
}

.gg-reward-mini {
	list-style: none;
	padding: 0;
	margin: 12px 0;
	font-size: 13px;
}

.gg-reward-mini li {
	display: flex;
	gap: 8px;
	opacity: 0.55;
}

.gg-reward-mini .is-unlocked {
	opacity: 1;
	color: var(--gg-ok);
}

.gg-menu-btn {
	display: none;
	background: none;
	border: 0;
	font-size: 22px;
	margin-right: auto;
}

.gg-top__profile {
	display: inline-flex;
	align-items: center;
	gap: 10px;
	padding: 4px 12px 4px 4px;
	border-radius: 999px;
	font-weight: 600;
	text-decoration: none;
	color: var(--gg-navy);
}

.gg-top__profile:hover {
	background: rgba(27, 54, 93, 0.06);
}

.gg-top__profile .gg-avatar {
	width: 32px;
	height: 32px;
	font-size: 11px;
	flex-shrink: 0;
}

.gg-top__points {
	display: inline-flex;
	align-items: baseline;
	gap: 3px;
	padding: 2px 8px;
	border-radius: 999px;
	background: #efe8db;
	color: var(--gg-navy);
	font-family: Fraunces, Georgia, serif;
	font-size: 15px;
	font-weight: 600;
	line-height: 1.2;
	white-space: nowrap;
}

.gg-top__points span {
	font-family: "DM Sans", system-ui, sans-serif;
	font-size: 11px;
	font-weight: 700;
	letter-spacing: 0.04em;
	text-transform: uppercase;
	color: var(--gg-gold);
}

.gg-top__profile-name {
	max-width: 200px;
	overflow: hidden;
	text-overflow: ellipsis;
	white-space: nowrap;
}

@media (max-width: 860px) {
	.gg-app {
		grid-template-columns: 1fr;
	}
	.gg-sidebar {
		display: none;
		position: absolute;
		inset: 0 auto 0 0;
		width: 260px;
		z-index: 20;
	}
	.gg-app.is-nav .gg-sidebar {
		display: flex;
	}
	.gg-menu-btn {
		display: inline-block;
	}
	.gg-grid-2,
	.gg-form--inline-grid {
		grid-template-columns: 1fr;
	}
	.gg-content {
		padding: 18px;
	}
	.gg-members-layout {
		grid-template-columns: 1fr;
	}
	.gg-members-layout__side {
		order: -1;
		position: static;
	}
}

.gg-invite {
	display: flex;
	gap: 8px;
	align-items: center;
	margin: 12px 0;
}

.gg-invite .gg-input {
	flex: 1;
}

.gg-pill--manager {
	background: #e8eef6;
	color: var(--gg-navy);
}

.gg-pagehead__actions {
	display: flex;
	gap: 8px;
	flex-wrap: wrap;
	align-items: center;
}

.gg-btn--danger {
	background: #f8eaea;
	color: var(--gg-err);
}

.gg-danger-form {
	margin-top: 28px;
	padding-top: 20px;
	border-top: 1px solid var(--gg-line);
}

.gg-task-group {
	border-top: 1px solid var(--gg-line);
	padding: 12px 0 4px;
}

.gg-task-group:first-of-type {
	border-top: 0;
	padding-top: 4px;
}

.gg-task-group__opts {
	margin: 8px 0 0 28px;
}

.gg-link-fields {
	display: grid;
	gap: 12px;
}

.gg-attachment-list {
	list-style: none;
	margin: 0 0 16px;
	padding: 0;
	display: grid;
	gap: 8px;
}

.gg-attachment {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 12px;
	flex-wrap: wrap;
	background: var(--gg-paper);
	border: 1px solid var(--gg-line);
	border-radius: 14px;
	padding: 10px 14px;
}

.gg-attachment a {
	color: var(--gg-navy);
	font-weight: 600;
	word-break: break-all;
}

.gg-attachment small,
.gg-attachment .gg-muted {
	color: var(--gg-muted);
}

.gg-attachment--edit {
	display: flex;
}

.gg-attachment--edit .gg-check {
	margin: 0;
	flex-shrink: 0;
}

.gg-task-cards {
	display: grid;
	grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
	gap: 16px;
}

.gg-task-card {
	background: var(--gg-paper);
	border: 1px solid var(--gg-line);
	border-radius: 20px;
	padding: 18px;
	box-shadow: var(--gg-shadow);
	display: grid;
	gap: 10px;
}

.gg-task-card__head {
	display: flex;
	justify-content: space-between;
	gap: 12px;
	align-items: flex-start;
}

.gg-task-card__head h3 {
	margin: 0;
	font-size: 22px;
}

.gg-task-card__head h3 a {
	text-decoration: none;
}

.gg-task-card__excerpt {
	margin: 0;
	color: var(--gg-muted);
	font-size: 14px;
	line-height: 1.5;
}

.gg-task-card__files {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: 8px;
}

.gg-task-thumb {
	width: 64px;
	height: 64px;
	border-radius: 12px;
	overflow: hidden;
	border: 1px solid var(--gg-line);
	background: #efe8db;
	display: grid;
	place-items: center;
	text-decoration: none;
	font-weight: 700;
	color: var(--gg-navy);
}

.gg-task-thumb img {
	width: 100%;
	height: 100%;
	object-fit: cover;
	display: block;
}

.gg-task-thumb--more {
	font-size: 14px;
}

.gg-task-card__meta {
	display: flex;
	flex-wrap: wrap;
	gap: 8px 14px;
	color: var(--gg-muted);
	font-size: 13px;
}

.gg-attach-grid {
	display: grid;
	grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
	gap: 12px;
	margin-bottom: 14px;
}

.gg-attach-tile {
	display: block;
	background: var(--gg-paper);
	border: 1px solid var(--gg-line);
	border-radius: 16px;
	overflow: hidden;
	text-decoration: none;
	box-shadow: var(--gg-shadow);
}

.gg-attach-tile img {
	display: block;
	width: 100%;
	height: 140px;
	object-fit: cover;
	background: #efe8db;
}

.gg-attach-tile__name {
	display: block;
	padding: 8px 10px;
	font-size: 12px;
	font-weight: 600;
	color: var(--gg-navy);
	word-break: break-word;
}

.gg-submit-form {
	background: var(--gg-paper);
	border: 1px solid var(--gg-line);
	border-radius: 20px;
	padding: 18px;
	box-shadow: var(--gg-shadow);
}

@media (max-width: 640px) {
	.gg-task-cards,
	.gg-attach-grid {
		grid-template-columns: 1fr;
	}
}

body.gg-modal-open {
	overflow: hidden;
}

.gg-modal {
	position: fixed;
	inset: 0;
	z-index: 80;
	display: grid;
	place-items: center;
	padding: 20px;
}

.gg-modal[hidden] {
	display: none;
}

.gg-modal__backdrop {
	position: absolute;
	inset: 0;
	background: rgba(18, 36, 63, 0.45);
}

.gg-modal__panel {
	position: relative;
	width: min(440px, 100%);
	background: var(--gg-paper);
	border: 1px solid var(--gg-line);
	border-radius: 24px;
	padding: 28px 24px 22px;
	box-shadow: var(--gg-shadow);
	display: grid;
	gap: 12px;
}

.gg-modal__title {
	margin: 0;
	font-size: 22px;
}

.gg-modal__body {
	margin: 0;
	color: var(--gg-muted);
	line-height: 1.5;
	font-weight: 400;
}

.gg-modal__actions {
	display: flex;
	flex-wrap: wrap;
	justify-content: flex-end;
	gap: 10px;
	margin-top: 8px;
}

.gg-modal [hidden] {
	display: none !important;
}
