/**
 * Basketball Freak UI Improvements
 *
 * Improves:
 * - Header branding and typography
 * - Mobile footer navigation readability
 * - Global whitespace and visual hierarchy
 * - Responsive design at key breakpoints
 */

/* ========================================
   1. HEADER IMPROVEMENTS
   ======================================== */

/* Site title/branding enhancement */
.site-title,
.site-title a,
.logo-text,
.header-title {
	font-weight: 700;
	letter-spacing: -0.5px;
	line-height: 1.2;
}

.site-title {
	font-size: 32px;
	margin: 12px 0 6px 0;
	color: #000;
}

.site-title a {
	text-decoration: none;
	transition: opacity 0.3s ease;
}

.site-title a:hover {
	opacity: 0.8;
}

/* Tagline/description improvements */
.site-description,
.tagline {
	font-size: 14px;
	font-weight: 500;
	color: #555;
	margin: 4px 0 0 0;
	letter-spacing: 0.3px;
	line-height: 1.5;
}

/* Header layout improvements */
.site-header,
.header-area,
header[role="banner"] {
	padding: 16px 0;
	margin: 0;
}

/* Improve header icon area spacing */
.header-logo-area,
.logo-area,
.site-branding {
	display: flex;
	align-items: center;
	justify-content: center;
	gap: 16px;
	margin-bottom: 12px;
}

/* Fix header icon list if present */
.header-icon-list,
.header-icons,
.icon-list {
	display: flex;
	justify-content: center;
	gap: 12px;
	margin: 0;
	padding: 0;
	flex-wrap: wrap;
}

.header-icon-list li,
.header-icons li,
.icon-list li {
	list-style: none;
	margin: 0;
}

.header-icon-list a,
.header-icons a,
.icon-list a {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 40px;
	height: 40px;
	font-size: 18px;
	transition: all 0.3s ease;
}

/* ========================================
   2. MOBILE FOOTER / BOTTOM NAV FIXES
   ======================================== */

/* Fix mobile footer navigation overlay/crowding */
.mobile-footer-nav,
.mobile-footer-menu,
.footer-nav-mobile,
.mobile-menu-bar,
.mobile-nav-fixed,
.navi-mobile,
.footer-mobile-nav {
	position: fixed;
	bottom: 0;
	left: 0;
	right: 0;
	display: flex;
	align-items: center;
	justify-content: space-around;
	background: #fff;
	border-top: 1px solid #e0e0e0;
	z-index: 999;
	height: auto;
	min-height: 56px;
	padding: 8px 0;
	box-shadow: 0 -2px 8px rgba(0, 0, 0, 0.08);
}

/* Fix footer menu items */
.mobile-footer-nav a,
.mobile-footer-menu a,
.footer-nav-mobile a,
.mobile-menu-bar a,
.mobile-nav-fixed a,
.navi-mobile a,
.footer-mobile-nav a {
	display: flex;
	flex-direction: column;
	align-items: center;
	justify-content: center;
	gap: 4px;
	padding: 8px 12px;
	color: #333;
	text-decoration: none;
	font-size: 12px;
	font-weight: 500;
	line-height: 1.3;
	white-space: nowrap;
	transition: all 0.3s ease;
	text-align: center;
	flex: 1;
	max-width: 80px;
}

/* Icon in footer nav */
.mobile-footer-nav a::before,
.mobile-footer-menu a::before,
.footer-nav-mobile a::before,
.mobile-menu-bar a::before,
.mobile-nav-fixed a::before,
.navi-mobile a::before,
.footer-mobile-nav a::before {
	display: block;
	font-size: 20px;
	content: attr(data-icon);
	line-height: 1;
}

/* Hide problematic star icons if they exist */
.mobile-footer-nav .icon-star,
.mobile-footer-menu .icon-star,
.footer-nav-mobile .icon-star,
.star-icon {
	display: none;
}

/* Active/hover state for mobile nav */
.mobile-footer-nav a:hover,
.mobile-footer-menu a:hover,
.footer-nav-mobile a:hover,
.mobile-nav-fixed a:hover,
.navi-mobile a:hover,
.footer-mobile-nav a:hover,
.mobile-footer-nav a.active,
.mobile-footer-menu a.active {
	color: #d32f2f;
	background-color: #f5f5f5;
}

/* Prevent text overlap in footer */
.mobile-footer-nav,
.mobile-footer-menu,
.footer-nav-mobile {
	overflow-x: auto;
}

.mobile-footer-nav a,
.mobile-footer-menu a,
.footer-nav-mobile a {
	overflow: hidden;
	text-overflow: ellipsis;
}

/* Mobile view bottom margin (to account for fixed footer) */
body.mobile-footer-visible,
body.has-mobile-nav {
	padding-bottom: 70px;
}

/* ========================================
   3. GLOBAL VISUAL CLEANUP
   ======================================== */

/* Improve main content spacing */
.site-content,
.content-area,
.main {
	margin: 24px auto;
}

/* Card and article spacing */
article,
.post,
.card,
.entry {
	margin-bottom: 32px;
	padding: 0;
}

/* Section spacing improvements */
section {
	margin: 32px 0;
	padding: 16px 0;
}

/* Heading hierarchy improvements */
h1, .h1 {
	font-size: 32px;
	font-weight: 700;
	line-height: 1.25;
	margin-bottom: 16px;
}

h2, .h2 {
	font-size: 24px;
	font-weight: 700;
	line-height: 1.33;
	margin-bottom: 12px;
	margin-top: 20px;
}

h3, .h3 {
	font-size: 20px;
	font-weight: 600;
	line-height: 1.4;
	margin-bottom: 10px;
	margin-top: 16px;
}

h4, .h4 {
	font-size: 16px;
	font-weight: 600;
	line-height: 1.5;
	margin-bottom: 8px;
}

h5, .h5,
h6, .h6 {
	font-size: 14px;
	font-weight: 600;
	line-height: 1.5;
	margin-bottom: 6px;
}

/* Body text readability */
body {
	line-height: 1.6;
	color: #333;
}

p {
	margin-bottom: 12px;
	line-height: 1.7;
}

/* Button improvements */
button,
.button,
.btn,
a.button,
a.btn,
input[type="button"],
input[type="submit"] {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	gap: 8px;
	padding: 12px 24px;
	font-size: 14px;
	font-weight: 600;
	line-height: 1;
	border: none;
	border-radius: 4px;
	cursor: pointer;
	transition: all 0.3s ease;
	text-decoration: none;
}

button:hover,
.button:hover,
.btn:hover,
a.button:hover,
a.btn:hover {
	transform: translateY(-2px);
	box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

button:active,
.button:active,
.btn:active {
	transform: translateY(0);
}

/* Primary button styling */
button.primary,
.button.primary,
.btn.primary,
.primary-btn,
a.button.primary {
	background-color: #d32f2f;
	color: #fff;
}

button.primary:hover,
.button.primary:hover,
.btn.primary:hover {
	background-color: #b71c1c;
}

/* Secondary button styling */
button.secondary,
.button.secondary,
.btn.secondary {
	background-color: #f5f5f5;
	color: #333;
	border: 1px solid #d0d0d0;
}

button.secondary:hover,
.button.secondary:hover,
.btn.secondary:hover {
	background-color: #efefef;
	border-color: #999;
}

/* Form improvements */
input[type="text"],
input[type="email"],
input[type="search"],
textarea,
select {
	padding: 10px 12px;
	font-size: 14px;
	line-height: 1.5;
	border: 1px solid #d0d0d0;
	border-radius: 4px;
	transition: border-color 0.3s ease;
}

input[type="text"]:focus,
input[type="email"]:focus,
input[type="search"]:focus,
textarea:focus,
select:focus {
	outline: none;
	border-color: #d32f2f;
	box-shadow: 0 0 0 3px rgba(211, 47, 47, 0.1);
}

/* List improvements */
ul, ol {
	margin-bottom: 16px;
	margin-left: 24px;
}

li {
	margin-bottom: 6px;
	line-height: 1.6;
}

/* ========================================
   4. RESPONSIVE DESIGN FIXES
   ======================================== */

/* Extra small devices (320px) */
@media (max-width: 340px) {
	.site-title {
		font-size: 24px;
	}

	.site-description {
		font-size: 12px;
	}

	.mobile-footer-nav a,
	.mobile-footer-menu a {
		max-width: 70px;
		padding: 6px 8px;
		font-size: 11px;
	}

	h1, .h1 {
		font-size: 24px;
	}

	h2, .h2 {
		font-size: 20px;
	}

	h3, .h3 {
		font-size: 16px;
	}
}

/* Small devices (375px) */
@media (max-width: 480px) {
	.site-title {
		font-size: 28px;
	}

	.mobile-footer-nav a,
	.mobile-footer-menu a {
		max-width: 75px;
		font-size: 11px;
	}

	.site-content,
	.content-area {
		margin: 16px;
	}

	h1, .h1 {
		font-size: 28px;
	}

	h2, .h2 {
		font-size: 22px;
	}

	button,
	.button,
	.btn {
		padding: 10px 20px;
		font-size: 13px;
	}
}

/* Medium devices (768px) */
@media (min-width: 768px) {
	.site-header,
	.header-area {
		padding: 20px 0;
	}

	.site-title {
		font-size: 36px;
		margin-bottom: 8px;
	}

	.site-description {
		font-size: 15px;
	}

	/* Hide mobile footer on tablet and up */
	.mobile-footer-nav,
	.mobile-footer-menu,
	.footer-nav-mobile,
	.mobile-menu-bar {
		display: none !important;
	}

	/* Remove bottom padding for desktop */
	body.mobile-footer-visible,
	body.has-mobile-nav {
		padding-bottom: 0;
	}

	.site-content,
	.content-area {
		margin: 32px auto;
	}
}

/* Large devices (1024px) */
@media (min-width: 1024px) {
	.site-title {
		font-size: 40px;
	}

	h1, .h1 {
		font-size: 36px;
	}

	h2, .h2 {
		font-size: 28px;
	}

	section {
		margin: 40px 0;
		padding: 24px 0;
	}
}

/* ========================================
   5. 404 PAGE FIXES
   ======================================== */

.error404 .mobile-footer-nav,
.error404 .mobile-footer-menu,
.error404 .footer-nav-mobile {
	position: relative;
	display: flex;
	border-top: 1px solid #e0e0e0;
	gap: 8px;
	flex-wrap: wrap;
	justify-content: center;
	margin-top: 24px;
	padding: 16px;
}

.error404 .mobile-footer-nav a,
.error404 .mobile-footer-menu a {
	margin: 4px;
	flex: 0 1 auto;
	max-width: none;
}

/* ========================================
   6. UTILITY CLASSES
   ======================================== */

.sr-only {
	position: absolute;
	width: 1px;
	height: 1px;
	padding: 0;
	margin: -1px;
	overflow: hidden;
	clip: rect(0, 0, 0, 0);
	white-space: nowrap;
	border-width: 0;
}

.visually-hidden {
	clip: rect(0 0 0 0);
	clip-path: inset(50%);
	height: 1px;
	overflow: hidden;
	position: absolute;
	white-space: nowrap;
	width: 1px;
}

/* Skip links for accessibility */
a.skip-link {
	position: absolute;
	left: -9999px;
	z-index: 999;
}

a.skip-link:focus {
	left: 0;
	top: 0;
	padding: 8px 16px;
	background-color: #000;
	color: #fff;
	text-decoration: none;
	z-index: 9999;
}

/* ========================================
   7. ACCESSIBILITY & CONTRAST
   ======================================== */

/* Ensure sufficient color contrast */
a {
	color: #d32f2f;
}

a:visited {
	color: #b71c1c;
}

a:hover,
a:focus {
	color: #7d1f1f;
	text-decoration: underline;
}

/* Focus visible for keyboard navigation */
button:focus-visible,
a:focus-visible,
input:focus-visible {
	outline: 3px solid #d32f2f;
	outline-offset: 2px;
}
