:root {
	color-scheme: dark;
	--bg: #070a11;
	--panel: rgba(12, 18, 30, 0.78);
	--text: #f8fbff;
	--muted: rgba(248, 251, 255, 0.72);
	--soft: rgba(248, 251, 255, 0.56);
	--blue: #12aee8;
	--gold: #f3ad3f;
	--line: rgba(255, 255, 255, 0.14);
	--radius: 8px;
	--container: min(1060px, calc(100% - 48px));
	--nav-h: 76px;
}

*,
*::before,
*::after {
	box-sizing: border-box;
}

html,
body {
	width: 100%;
	min-height: 100%;
	overflow-x: hidden;
}

html {
	scroll-padding-top: calc(var(--nav-h) + 18px);
}

body {
	margin: 0;
	padding-top: var(--nav-h);
	font-family: "Plus Jakarta Sans", ui-sans-serif, system-ui, -apple-system, "Segoe UI", Arial, sans-serif;
	color: var(--text);
	background:
		linear-gradient(145deg, rgba(18, 174, 232, 0.12), transparent 34%),
		linear-gradient(225deg, rgba(243, 173, 63, 0.1), transparent 38%),
		linear-gradient(180deg, #05070d 0%, var(--bg) 46%, #0a0f19 100%);
	-webkit-font-smoothing: antialiased;
	text-rendering: optimizeLegibility;
}

body::before {
	content: "";
	position: fixed;
	inset: 0;
	z-index: -1;
	pointer-events: none;
	background-image:
		linear-gradient(rgba(255, 255, 255, 0.028) 1px, transparent 1px),
		linear-gradient(90deg, rgba(255, 255, 255, 0.028) 1px, transparent 1px);
	background-size: 84px 84px;
	mask-image: linear-gradient(180deg, rgba(0, 0, 0, 0.62), transparent 72%);
}

a {
	color: inherit;
	text-decoration: none;
}

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

.container {
	width: var(--container);
	margin: 0 auto;
}

.legal-nav {
	position: fixed;
	top: 0;
	left: 50%;
	transform: translateX(-50%);
	z-index: 80;
	width: var(--container);
	min-height: var(--nav-h);
	margin: 0 auto;
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 16px;
	border-bottom: 1px solid var(--line);
	background: rgba(7, 10, 17, 0.82);
	backdrop-filter: blur(18px);
	box-shadow: 0 18px 56px rgba(0, 0, 0, 0.22);
}

.brand {
	display: inline-flex;
	align-items: center;
}

.brand__plate {
	width: 154px;
	height: 42px;
	padding: 7px 10px;
	border-radius: var(--radius);
	background: rgba(255, 255, 255, 0.96);
	display: inline-flex;
	align-items: center;
	justify-content: center;
	box-shadow: 0 12px 34px rgba(0, 0, 0, 0.28);
}

.brand img {
	width: 100%;
	height: 100%;
	object-fit: contain;
}

.legal-nav nav {
	display: flex;
	align-items: center;
	gap: 20px;
	color: rgba(248, 251, 255, 0.74);
	font-size: 0.78rem;
	font-weight: 800;
	text-transform: uppercase;
}

.legal-nav nav a {
	min-height: 44px;
	display: inline-flex;
	align-items: center;
	border-bottom: 1px solid transparent;
}

.legal-nav nav a:hover {
	color: var(--text);
	border-color: var(--gold);
}

.legal-hero {
	position: relative;
	padding: 74px 0 30px;
	overflow: hidden;
}

.legal-hero::before {
	content: "";
	position: absolute;
	inset: 20px -14%;
	z-index: -1;
	background:
		radial-gradient(ellipse at 20% 48%, rgba(18, 174, 232, 0.22), transparent 48%),
		radial-gradient(ellipse at 78% 60%, rgba(243, 173, 63, 0.16), transparent 48%);
	filter: blur(28px);
	transform: skewX(-12deg);
}

.eyebrow {
	display: inline-flex;
	align-items: center;
	gap: 10px;
	color: var(--gold);
	font-size: 0.78rem;
	font-weight: 800;
	text-transform: uppercase;
}

.eyebrow::before {
	content: "";
	width: 30px;
	height: 1px;
	background: linear-gradient(90deg, var(--blue), var(--gold));
}

h1,
h2 {
	font-family: "Cormorant Garamond", Georgia, serif;
	letter-spacing: 0;
}

h1 {
	margin: 12px 0 0;
	max-width: 880px;
	font-size: clamp(3rem, 8vw, 6rem);
	line-height: 0.94;
}

.legal-hero p {
	margin: 18px 0 0;
	max-width: 720px;
	color: var(--muted);
	font-size: 1.04rem;
	line-height: 1.7;
}

.legal-updated {
	margin-top: 18px;
	display: inline-flex;
	border: 1px solid rgba(243, 173, 63, 0.24);
	border-radius: var(--radius);
	background: rgba(243, 173, 63, 0.1);
	color: #ffe0a3;
	padding: 9px 11px;
	font-size: 0.82rem;
	font-weight: 800;
}

.legal-layout {
	display: grid;
	grid-template-columns: 220px minmax(0, 1fr);
	gap: 24px;
	align-items: start;
	padding: 24px 0 84px;
}

.legal-toc {
	position: sticky;
	top: calc(var(--nav-h) + 18px);
	display: grid;
	gap: 8px;
	border: 1px solid var(--line);
	border-radius: var(--radius);
	background: rgba(255, 255, 255, 0.06);
	padding: 14px;
}

.legal-toc a {
	color: var(--muted);
	font-size: 0.84rem;
	font-weight: 800;
	line-height: 1.45;
}

.legal-toc a:hover {
	color: var(--gold);
}

.legal-card {
	border: 1px solid rgba(255, 255, 255, 0.15);
	border-radius: var(--radius);
	background: linear-gradient(180deg, rgba(255, 255, 255, 0.1), rgba(255, 255, 255, 0.055));
	box-shadow: 0 24px 70px rgba(0, 0, 0, 0.32);
	backdrop-filter: blur(18px);
	padding: clamp(20px, 4vw, 34px);
}

.legal-card section + section {
	margin-top: 28px;
	padding-top: 26px;
	border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.legal-card h2 {
	margin: 0;
	font-size: clamp(2rem, 4vw, 3rem);
	line-height: 1;
}

.legal-card p,
.legal-card li {
	color: var(--muted);
	line-height: 1.72;
}

.legal-card p {
	margin: 12px 0 0;
}

.legal-card ul {
	display: grid;
	gap: 8px;
	margin: 14px 0 0;
	padding-left: 20px;
}

.notice-box {
	margin-top: 14px;
	border: 1px solid rgba(18, 174, 232, 0.24);
	border-radius: var(--radius);
	background: rgba(18, 174, 232, 0.08);
	padding: 14px;
	color: var(--muted);
	line-height: 1.7;
}

@media (max-width: 820px) {
	:root {
		--container: min(100% - 28px, 720px);
	}

	.legal-layout {
		grid-template-columns: 1fr;
	}

	.legal-toc {
		position: relative;
		top: auto;
	}
}

@media (max-width: 560px) {
	:root {
		--container: min(100% - 20px, 520px);
		--nav-h: 66px;
	}

	.legal-nav {
		min-height: var(--nav-h);
	}

	.brand__plate {
		width: 128px;
		height: 40px;
	}

	.legal-nav nav {
		gap: 12px;
		font-size: 0.72rem;
	}

	.legal-nav nav a:nth-child(2) {
		display: none;
	}

	.legal-hero {
		padding-top: 46px;
	}
}

/* Full-bleed header polish */
.legal-nav {
	left: 0;
	right: 0;
	transform: none;
	width: 100%;
	padding-inline: max(24px, calc((100vw - 1060px) / 2));
}

@media (max-width: 560px) {
	.legal-nav {
		padding-inline: 10px;
	}
}
