/* ============================================
   BASE STYLES
   CSS Variables, Body, Layout, Animations
   ============================================ */

:root {
	--brand-green: #3FAE7C;
	--brand-dark: #232323;
	--brand-bg: #F7F7F5;
	--brand-bg-accent: #e6f7ef;
	--brand-orange: #F08C1A;
	--brand-grey: #aaa;
	--brand-grey-dark: #444;
	--brand-grey-light: #9E9E9E;
}

/* Accessibility */
.skip-link {
	position: absolute;
	left: -999px;
	top: auto;
	width: 1px;
	height: 1px;
	overflow: hidden;
	z-index: 100;
	background: #fff;
	color: var(--brand-green);
	padding: 8px 16px;
	border-radius: 8px;
	transition: left 0.2s;
}

.skip-link:focus {
	left: 16px;
	top: 16px;
	width: auto;
	height: auto;
	outline: 2px solid #3FAE7C;
	box-shadow: 0 2px 8px rgba(63, 174, 124, 0.15);
}

/* Hidden Navigation */
nav[aria-label="Menu chính"] {
	display: none;
}

/* Footer */
footer.site-footer {
	width: 100%;
	text-align: center;
	padding: 1rem 0 0.5rem 0;
	color: var(--brand-grey);
	font-size: 0.95rem;
}

/* Body & Background */
body {
	background: linear-gradient(135deg, var(--brand-bg) 60%, var(--brand-bg-accent) 100%);
	color: var(--brand-dark);
	font-family: 'Noto Sans', 'Segoe UI', Arial, sans-serif;
	margin: 0;
	padding: 0;
	min-height: 100vh;
	display: flex;
	flex-direction: column;
	align-items: center;
	justify-content: flex-start;
	position: relative;
	overflow-x: hidden;
}

.animated-bg {
	position: fixed;
	top: 0;
	left: 0;
	width: 100vw;
	height: 100vh;
	z-index: 0;
	pointer-events: none;
	background: radial-gradient(circle at 80% 20%, #3fae7c22 0%, #fff0 60%),
		radial-gradient(circle at 20% 80%, #3fae7c18 0%, #fff0 70%);
	animation: bgmove 12s linear infinite alternate;
}

@keyframes bgmove {
	0% {
		background-position: 80% 20%, 20% 80%;
	}

	100% {
		background-position: 70% 30%, 30% 70%;
	}
}

/* Main Layout */
main {
	width: 100%;
	display: flex;
	flex-direction: column;
	align-items: center;
}

/* Container */
.container {
	text-align: left;
	padding: 0;
	background: #fff;
	border-radius: 12px;
	box-shadow: 0 1px 3px rgba(0, 0, 0, 0.08);
	width: 100%;
	max-width: 100%;
	box-sizing: border-box;
	margin-top: 1rem;
	margin-bottom: 1rem;
	animation: fadeIn 0.8s cubic-bezier(.4, 0, .2, 1);
	border: 1px solid #f0f0f0;
	overflow: hidden;
}

.container:not(.tournament-detail-header):not(.matches-section):not(.rankings-section):not(.luck-of-the-draw-section) {
	max-width: 33.75rem;
}

@keyframes fadeIn {
	from {
		opacity: 0;
		transform: translateY(32px);
	}

	to {
		opacity: 1;
		transform: none;
	}
}

/* Basic Typography */
a {
	color: #3FAE7C;
	text-decoration: none;
}

a:hover {
	text-decoration: underline;
}

#content h2,
#content h3 {
	font-size: 1.18rem;
}

#content {
	width: 100%;
	box-sizing: border-box;
}

.ul-left {
	text-align: left;
	width: 100%;
	margin: 0 0 18px 0;
	padding-left: 1.2em;
	box-sizing: border-box;
}

.no-bullet {
	list-style-type: none !important;
	padding-left: 0 !important;
	margin-left: 0 !important;
}

#content li {
	margin-bottom: 0.4em;
	font-size: 0.98rem;
	word-break: break-word;
}

/* Empty State */
.empty-state {
	text-align: center;
	padding: 3rem 2rem;
}

.empty-state .construction {
	font-size: 2.5rem;
	margin-bottom: 1rem;
}

.empty-state h2 {
	color: var(--brand-grey-dark);
	font-size: 1.3rem;
	margin-bottom: 0.5rem;
}

.empty-state p {
	color: var(--brand-grey-light);
	font-size: 1rem;
}

.construction {
	font-size: 1.2rem;
	color: var(--brand-orange);
	margin-bottom: 0.75rem;
}

.desc {
	color: var(--brand-grey-dark);
	font-size: 1rem;
	margin-bottom: 1.5rem;
}

.contact {
	font-size: 0.95rem;
	color: var(--brand-grey-light);
}

/* Page Title */
.page-title {
	text-align: center;
	font-size: 1.5rem;
	font-weight: 700;
	color: var(--brand-dark);
	margin-bottom: 2rem;
}

/* Responsive Base Adjustments */
@media (max-width: 600px) {
	.container {
		padding: 12px 4vw 12px 4vw;
		max-width: 100vw;
		border-radius: 0;
		box-shadow: none;
		margin-top: 8px;
		margin-bottom: 8px;
	}

	#content h2,
	#content h3 {
		font-size: 1.05rem;
	}

	#content li {
		font-size: 0.93rem;
	}
	
	.page-title {
		font-size: 1.25rem;
	}
}

@media (min-width: 600px) {
	.container {
		max-width: 540px;
		width: 100%;
	}
}

@media (min-width: 900px) {
	.container {
		max-width: 600px;
		width: 100%;
		padding: 40px 36px 36px 36px;
	}

	.page-title {
		font-size: 1.8rem;
	}

	#content h2,
	#content h3 {
		font-size: 1.35rem;
	}

	#content li {
		font-size: 1.08rem;
	}
}
