:root {
	--primary-color: #444;
	--secondary-color: #666;
	--accent-color: #fff;
	--glass-bg: rgba(28, 28, 32, 0.75);
	--glass-border: rgba(55, 55, 60, 0.6);
	--text-light: #ffffff;
	--text-dark: #f0f0f0;
	--text-muted: rgba(230, 235, 240, 0.75);
	--shadow: 0 10px 30px rgba(0, 0, 0, 0.25);
	--border-radius: 16px;
	--card-radius: 12px;
	--highlight-color: #2196F3;
	/* Blue highlight color for search terms */
	--text-color: var(--text-light);
	--text-secondary: var(--text-muted);
	--bg-lighter: rgba(50, 50, 55, 0.5);
	/* Slightly lighter background for containers */
	--card-bg: rgba(32, 32, 36, 0.75);
	--card-shadow: var(--shadow);
	-webkit-tap-highlight-color: transparent;
}

/* Hide URL tooltips on all links */
a[title=""], a:not([title]) {
    pointer-events: auto;
}
a:hover {
    cursor: pointer;
}

* {
	margin: 0;
	padding: 0;
	box-sizing: border-box;
	font-family: 'Poppins', 'Inter', system-ui, -apple-system, sans-serif;
}

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

body {
	background: #121216;
	background-image:
		radial-gradient(circle at top right, rgba(70, 70, 70, 0.15), transparent 70%),
		radial-gradient(circle at bottom left, rgba(90, 90, 90, 0.1), transparent 70%);
	padding: 20px;
	color: var(--text-dark);
	overflow-y: auto;
}

/* Light Theme Body Styles */
body.light-theme {
	background: #f0f2f5;
	background-image:
		radial-gradient(circle at top right, rgba(80, 80, 80, 0.06), transparent 60%),
		radial-gradient(circle at bottom left, rgba(100, 100, 100, 0.06), transparent 60%);
}

::selection {
	background-color: #555;
	color: white;
}

/* Custom scrollbar */
::-webkit-scrollbar {
	width: 12px;
}

::-webkit-scrollbar-track {
	background: rgba(30, 30, 30, 0.8);
}

::-webkit-scrollbar-thumb {
	background: #555;
	border-radius: 6px;
	border: 3px solid rgba(0, 0, 0, 0.2);
}

::-webkit-scrollbar-thumb:hover {
	background: #777;
}

/* Preloader */
.preloader {
	position: fixed;
	top: 0;
	left: 0;
	width: 100%;
	height: 100%;
	background: #0a0a0a;
	display: flex;
	justify-content: center;
	align-items: center;
	z-index: 9999;
	transition: opacity 0.3s ease-out;
}

.preloader.hidden {
	opacity: 0;
	pointer-events: none;
}

.loader {
	width: 80px;
	height: 80px;
	border-radius: 50%;
	position: relative;
}

.loader:before {
	content: "";
	position: absolute;
	top: 0;
	left: 0;
	right: 0;
	bottom: 0;
	border-radius: 50%;
	border: 3px solid transparent;
	border-top-color: #fff;
	border-bottom-color: #555;
	animation: spin 1s linear infinite;
}

@keyframes spin {
	to {
		transform: rotate(360deg);
	}
}

/* Container */
.container {
	max-width: 1200px;
	margin: 0 auto;
	opacity: 0;
	transform: translateY(20px);
	transition: opacity 0.8s ease, transform 0.8s ease;
	min-height: calc(100% - 40px);
	display: flex;
	flex-direction: column;
	width: 100%;
	position: relative;
	margin-top: 0;
	/* Ensure no extra top margin */
}

.container.visible {
	opacity: 1;
	transform: translateY(0);
}

/* Header */
header {
	background: var(--glass-bg);
	backdrop-filter: blur(20px);
	-webkit-backdrop-filter: blur(20px);
	border: 1px solid var(--glass-border);
	padding: 40px;
	border-radius: var(--border-radius);
	margin-bottom: 30px;
	box-shadow: var(--shadow);
	display: flex;
	flex-direction: column;
	align-items: center;
	position: relative;
	overflow: hidden;
}

header:before {
	content: "";
	position: absolute;
	top: -50%;
	left: -50%;
	width: 200%;
	height: 200%;
	background: radial-gradient(circle, rgba(255, 255, 255, 0.03) 0%, rgba(255, 255, 255, 0) 70%);
	pointer-events: none;
}

/* Logo styling with improved centering */
.logo {
	width: 100%;
	text-align: center;
	display: flex;
	flex-direction: column;
	align-items: center;
}

/* Combined h1 styles */
h1,
.logo h1 {
	background: linear-gradient(to right, #fff, #999);
	-webkit-background-clip: text;
	background-clip: text;
	color: transparent;
	font-size: 3rem;
	font-weight: 700;
	letter-spacing: -0.02em;
	margin-bottom: 15px;
	position: relative;
}

/* Logo specific h1 style */
.logo h1 {
	text-align: center;
}

/* Light theme h1 styles */
body.light-theme h1,
body.light-theme .logo h1 {
	background: linear-gradient(to right, #333, #777);
	-webkit-background-clip: text;
	background-clip: text;
}

p,
.logo p {
	color: var(--text-muted);
	line-height: 1.6;
	text-align: center;
	max-width: 700px;
}

/* Logo specific p style */
.logo p {
	margin: 0 auto;
}

/* Search */
.search-container {
	margin: 30px auto;
	width: 100%;
	max-width: 600px;
	position: relative;
	overflow: hidden;
	border-radius: 50px;
	box-shadow: 0 8px 20px rgba(0, 0, 0, 0.15);
}

.search-container::after {
	content: '';
	position: absolute;
	top: -50%;
	left: -50%;
	width: 200%;
	height: 200%;
	background: radial-gradient(circle at var(--x, 50%) var(--y, 50%),
			rgba(255, 255, 255, 0.08) 0%,
			transparent 60%);
	opacity: 0;
	transition: opacity 0.3s;
	pointer-events: none;
	z-index: 1;
}

.search-container:hover::after {
	opacity: 1;
}

.search-input {
	width: 100%;
	background: rgba(30, 30, 35, 0.7);
	backdrop-filter: blur(20px);
	-webkit-backdrop-filter: blur(20px);
	border: 1px solid var(--glass-border);
	border-radius: 50px;
	padding: 18px 25px;
	padding-left: 55px;
	color: var(--text-light);
	font-size: 16px;
	transition: all 0.3s ease;
	box-shadow: var(--shadow);
}

.search-input:focus {
	outline: none;
	border-color: #777;
	box-shadow: 0 0 0 4px rgba(70, 70, 70, 0.3), 0 0 15px rgba(70, 70, 70, 0.4);
}

.search-icon {
	position: absolute;
	left: 18px;
	top: 50%;
	transform: translateY(-50%);
	width: 24px;
	height: 24px;
	opacity: 0.7;
	pointer-events: none;
	z-index: 5;
}

/* Navigation */
.nav-container {
	margin: 30px 0;
	/* Increased from 20px to 30px */
	position: relative;
	width: 100%;
}

.category-nav-wrapper {
	position: relative;
	width: 100%;
	overflow: hidden;
}

.nav-arrow {
	position: absolute;
	top: 50%;
	transform: translateY(-50%);
	width: 40px;
	height: 40px;
	background: rgba(40, 40, 45, 0.8);
	border: none;
	border-radius: 50%;
	display: flex;
	align-items: center;
	justify-content: center;
	cursor: pointer;
	z-index: 5;
	color: #ddd;
	transition: all 0.3s ease;
	box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
}

.nav-arrow:hover {
	background: rgba(60, 60, 65, 0.9);
	color: white;
}

.nav-left {
	left: 0;
}

.nav-right {
	right: 0;
}

/* Hide navigation arrows on desktop */
@media (min-width: 992px) {
	.nav-arrow {
		display: none;
	}
}

.category-nav {
	display: flex;
	flex-wrap: nowrap;
	gap: 18px;
	/* Increased from 12px to 18px */
	padding: 8px 0;
	/* Increased from 5px to 8px */
	transition: transform 0.3s ease;
	-webkit-overflow-scrolling: touch;
	scrollbar-width: none;
	max-width: 100%;
	overflow-x: auto;
}

.category-nav::-webkit-scrollbar {
	display: none;
}

.category-button {
	flex: 0 0 auto;
	white-space: nowrap;
	padding: 12px 20px;
	min-width: 120px;
	justify-content: center;
	text-align: center;
	background: var(--glass-bg);
	backdrop-filter: blur(20px);
	-webkit-backdrop-filter: blur(20px);
	border: 1px solid var(--glass-border);
	border-radius: 50px;
	font-size: 16px;
	cursor: pointer;
	transition: all 0.3s ease;
	color: var(--text-muted);
	display: flex;
	align-items: center;
	justify-content: center;
	margin-right: 2px;
	gap: 8px;
	position: relative;
	overflow: hidden;
}

/* Info tooltip for categories that require extra explanation */
.category-button .info-tooltip {
	position: absolute;
	top: -8px;
	right: -8px;
	background: #2196F3;
	color: white;
	border-radius: 50%;
	width: 18px;
	height: 18px;
	font-size: 12px;
	display: flex;
	align-items: center;
	justify-content: center;
	cursor: help;
	z-index: 5;
	transition: all 0.3s ease;
}

.category-button .info-tooltip:hover {
	transform: scale(1.2);
}

.tooltip-content {
	position: absolute;
	bottom: calc(100% + 15px);
	left: 50%;
	transform: translateX(-50%) scale(0.95);
	background: var(--glass-bg);
	backdrop-filter: blur(20px);
	-webkit-backdrop-filter: blur(20px);
	border: 1px solid var(--glass-border);
	border-radius: 10px;
	padding: 12px 15px;
	width: max-content;
	max-width: 280px;
	color: var(--text-light);
	font-size: 13px;
	box-shadow: 0 10px 25px rgba(0, 0, 0, 0.3);
	opacity: 0;
	pointer-events: none;
	transition: all 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
	z-index: 100;
}

.tooltip-content::after {
	content: "";
	position: absolute;
	top: 100%;
	left: 50%;
	transform: translateX(-50%);
	border-width: 8px;
	border-style: solid;
	border-color: var(--glass-border) transparent transparent transparent;
}

.category-button .info-tooltip:hover+.tooltip-content,
.tooltip-content:hover {
	opacity: 1;
	transform: translateX(-50%) scale(1);
	pointer-events: auto;
}

.category-icon {
	display: flex;
	align-items: center;
	justify-content: center;
	font-size: 20px;
}

.category-icon svg {
	stroke: currentColor;
	transition: stroke 0.3s ease;
}

.category-button:hover .category-icon svg {
	stroke: var(--text-light);
}

.category-button.active .category-icon svg {
	stroke: white;
}

.category-button:hover {
	border-color: #777;
	color: var(--text-light);
	transform: translateY(-3px);
}

.category-button.active {
	background: #333;
	color: white;
	border: none;
	box-shadow: 0 10px 20px rgba(0, 0, 0, 0.4);
}

.subcategory-nav {
	display: flex;
	gap: 15px;
	/* Increased from 10px to 15px */
	margin: 25px 0;
	/* Changed from margin-bottom: 20px to margin: 25px 0 */
	flex-wrap: wrap;
	justify-content: center;
}

.subcategory-button {
	background: transparent;
	border: 1px solid rgba(255, 255, 255, 0.1);
	padding: 8px 16px;
	border-radius: 20px;
	font-size: 14px;
	cursor: pointer;
	transition: all 0.3s ease;
	color: var(--text-muted);
	position: relative;
	overflow: hidden;
}

.subcategory-button:hover {
	border-color: #777;
	color: var(--text-light);
}

.subcategory-button.active {
	background: rgba(80, 80, 80, 0.3);
	border-color: rgba(180, 180, 180, 0.4);
	color: var(--text-light);
}

/* Content section */
.content-section {
	display: none;
	grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
	gap: 35px;
	/* Increased from 25px to 35px */
	margin-top: 30px;
	/* Increased from 20px to 30px */
	flex-grow: 1;
}

.content-section.active {
	display: grid;
}

/* Center align when there's only one card in the category */
.content-section.single-card {
	grid-template-columns: minmax(300px, 400px);
	justify-content: center;
}

/* Cards */
.card {
	background: rgba(32, 32, 36, 0.75);
	border: 1px solid rgba(60, 60, 65, 0.6);
	backdrop-filter: blur(20px);
	-webkit-backdrop-filter: blur(20px);
	border-radius: var(--card-radius);
	overflow: hidden;
	box-shadow: var(--shadow);
	transition: transform 0.3s ease, box-shadow 0.3s ease;
	position: relative;
	display: flex;
	flex-direction: column;
	height: 100%;
	isolation: isolate;
}

.card::before {
	content: "";
	position: absolute;
	inset: 0;
	border-radius: var(--card-radius);
	padding: 1.5px;
	background: linear-gradient(var(--rotate, 0deg),
			rgba(255, 255, 255, 0) 0%,
			rgba(180, 180, 180, 0.5) 50%,
			rgba(255, 255, 255, 0) 100%);
	mask: linear-gradient(#fff 0 0) content-box,
		linear-gradient(#fff 0 0);
	-webkit-mask: linear-gradient(#fff 0 0) content-box,
		linear-gradient(#fff 0 0);
	mask-composite: xor;
	-webkit-mask-composite: xor;
	opacity: 0;
	transition: opacity 0.3s ease;
}

.card::after {
	content: '';
	position: absolute;
	inset: 0;
	border-radius: var(--card-radius);
	background: radial-gradient(circle at var(--x, 50%) var(--y, 50%),
			rgba(255, 255, 255, 0.1) 0%,
			transparent 70%);
	opacity: 0;
	transition: opacity 0.3s ease;
	pointer-events: none;
}

.card:hover::before {
	opacity: 1;
	animation: rotate-border 3s linear infinite;
}

.card:hover::after {
	opacity: 1;
}

@keyframes rotate-border {
	0% {
		--rotate: 0deg;
	}

	100% {
		--rotate: 360deg;
	}
}

.card:hover {
	transform: translateY(-5px);
	box-shadow: 0 15px 30px rgba(0, 0, 0, 0.25);
	border-color: rgba(255, 255, 255, 0.1);
}

.card:hover .card-image:before {
	opacity: 0.7;
}

.card-image {
	height: 180px;
	background-size: cover;
	background-position: center;
	position: relative;
}

.card-image:before {
	content: "";
	position: absolute;
	inset: 0;
	background: linear-gradient(to top, rgba(0, 0, 0, 0.7) 0%, rgba(0, 0, 0, 0) 70%);
	opacity: 0.5;
	transition: opacity 0.3s ease;
}

.card-body {
	padding: 25px;
	position: relative;
	display: flex;
	flex-direction: column;
	flex-grow: 1;
}

.card-title {
	font-size: 20px;
	margin-bottom: 12px;
	color: var(--text-light);
	font-weight: 600;
	display: flex;
	align-items: center;
	gap: 8px;
}

.card-title svg {
	width: 22px;
	height: 22px;
	flex-shrink: 0;
	position: relative;
	top: -1px;
}

.card-text {
	font-size: 15px;
	margin-bottom: 20px;
	line-height: 1.6;
	color: var(--text-muted);
	text-align: left;
	flex-grow: 1;
}

.card-link {
	display: inline-flex;
	align-items: center;
	gap: 8px;
	padding: 10px 20px;
	background: #333;
	color: var(--text-light);
	text-decoration: none;
	border-radius: 30px;
	font-size: 15px;
	font-weight: 500;
	transition: all 0.3s ease;
	position: relative;
	overflow: hidden;
}

.card-link:hover {
	transform: translateY(-2px);
	box-shadow: 0 5px 15px rgba(0, 0, 0, 0.4);
	background: #444;
}

.card-link svg {
	width: 16px;
}

/* Adding source info styling */
.card-source {
    margin-top: 12px;
    margin-bottom: 15px;
    padding: 8px 10px;
    font-size: 12px;
    color: var(--text-muted);
    display: flex;
    align-items: center;
    gap: 6px;
    opacity: 0.85;
    transition: all 0.3s ease;
    background: rgba(40, 40, 45, 0.3);
    border-radius: 8px;
}

.card-source i {
    font-size: 13px;
    color: #777;
}

.card-source .source-link {
    color: inherit; /* Inherits the color from parent instead of blue */
    text-decoration: none;
    transition: all 0.2s ease;
    position: relative;
    font-weight: 500; /* Makes it slightly bolder to distinguish it as a link */
}

.card-source .source-link:hover {
    color: #aaa; /* Light gray hover instead of blue */
    /* text-decoration: underline; */
}

.card-source .source-link:after {
    content: '';
    position: absolute;
    width: 100%;
    height: 1px;
    bottom: -1px;
    left: 0;
    background-color: #aaa; /* Matching the hover color */
    transform: scaleX(0);
    transform-origin: bottom right;
    transition: transform 0.3s;
}

.card-source .source-link:hover:after {
    transform: scaleX(1);
    transform-origin: bottom left;
}

.card:hover .card-source {
    opacity: 1;
    background: rgba(45, 45, 50, 0.4);
}

body.light-theme .card-source {
    color: rgba(70, 70, 70, 0.9);
    background: rgba(230, 230, 230, 0.5);
}

body.light-theme .card-source .source-link {
    color: inherit; /* Inherit from parent */
    font-weight: 500; /* Slightly bolder */
}

body.light-theme .card-source .source-link:hover {
    color: #555; /* Darker hover for light theme */
}

body.light-theme .card-source .source-link {
    color: #2c7ed9;
}

@media (max-width: 768px) {
    .card-source {
        font-size: 11px;
        padding: 6px 8px;
        margin-bottom: 11px;
    }
}

/* Hover effects - made more subtle */
.category-button::after,
.subcategory-button::after,
.card-link::after {
	content: '';
	position: absolute;
	top: -50%;
	left: -50%;
	width: 200%;
	height: 200%;
	background: radial-gradient(circle at var(--x, 50%) var(--y, 50%),
			rgba(255, 255, 255, 0.12) 0%,
			transparent 50%);
	opacity: 0;
	transition: opacity 0.3s;
	pointer-events: none;
	z-index: 1;
}

/* Slightly more subtle highlight proximity effects */
.card.highlight-proximity::before {
	opacity: calc(var(--intensity) * 1);
	background: linear-gradient(var(--rotate, 0deg),
			rgba(255, 255, 255, 0) 0%,
			rgba(255, 255, 255, 0.4) 50%,
			rgba(255, 255, 255, 0) 100%);
}

.card.highlight-proximity::after {
	opacity: calc(var(--intensity) * 0.7);
	filter: blur(8px);
	
	/* Firefox-specific adjustment */
	@-moz-document url-prefix() {
		opacity: calc(var(--intensity) * 0.4); /* Even lower opacity for Firefox */
	}
}

.category-button.highlight-proximity,
.subcategory-button.highlight-proximity {
	border-color: rgba(200, 200, 200, calc(var(--intensity, 0) * 0.6));
	transform: translateY(calc(var(--intensity, 0) * -2px));
	box-shadow: 0 calc(var(--intensity, 0) * 8px) calc(var(--intensity, 0) * 15px) rgba(0, 0, 0, calc(var(--intensity, 0) * 0.4));
}

.category-button.highlight-proximity::after,
.subcategory-button.highlight-proximity::after,
.card-link.highlight-proximity::after,
.search-container.highlight-proximity::after {
	opacity: calc(var(--intensity) * 0.8);
	background: radial-gradient(circle at var(--x, 50%) var(--y, 50%),
			rgba(255, 255, 255, 0.2) 0%,
			rgba(255, 255, 255, 0.04) 30%,
			transparent 60%);
	filter: blur(4px);
}

/* Remove duplicate highlight proximity effect */
.category-button.highlight-proximity::after,
subcategory-button.highlight-proximity::after,
card-link.highlight-proximity::after,
search-container.highlight-proximity::after {
	display: none;
}

/* Footer */
footer {
	text-align: center;
	margin-top: 40px;
	padding: 30px;
	color: var(--text-muted);
	font-size: 14px;
	position: relative;
}

.contact-info {
	display: flex;
	justify-content: center;
	gap: 20px;
	margin-top: 15px;
	flex-wrap: wrap;
}

.contact-link {
	display: inline-flex;
	align-items: center;
	gap: 8px;
	color: #e6ebf0;
	/* Light color for better visibility */
	text-decoration: none;
	padding: 8px 15px;
	border-radius: 50px;
	background: rgba(40, 40, 45, 0.7);
	backdrop-filter: blur(10px);
	-webkit-backdrop-filter: blur(10px);
	border: 1px solid rgba(60, 60, 65, 0.6);
	transition: all 0.3s ease;
}

.contact-link:hover {
	transform: translateY(-3px);
	color: #ffffff;
	border-color: #777;
	box-shadow: 0 8px 20px rgba(0, 0, 0, 0.15);
}

.contact-link i {
	font-size: 16px;
}

/* Light theme styling for contact links */
body.light-theme .contact-link {
	background: rgba(255, 255, 255, 0.6);
	color: #444;
	border-color: rgba(200, 200, 200, 0.6);
}

body.light-theme .contact-link:hover {
	background: rgba(255, 255, 255, 0.8);
	color: #222;
}

.footer-glow {
	position: absolute;
	bottom: 0;
	left: 50%;
	transform: translateX(-50%);
	width: 200px;
	height: 2px;
	background: linear-gradient(to right, transparent, #555, transparent);
	pointer-events: none;
}

/* Responsive styles for contact info */
@media (max-width: 576px) {
	.contact-info {
		flex-direction: column;
		gap: 10px;
		align-items: center;
	}

	.contact-link {
		width: 100%;
		max-width: 250px;
		justify-content: center;
	}
}

/* No results */
.no-results {
	text-align: center;
	padding: 40px 0;
	grid-column: 1 / -1;
}

.no-results h3 {
	color: var(--text-light);
	margin-bottom: 15px;
	font-size: 22px;
}

.no-results p {
	color: var(--text-muted);
}

/* Ghost cards */
.ghost-card {
	background: var(--glass-bg);
	border-radius: var(--card-radius);
	overflow: hidden;
	border: 1px solid var(--glass-border);
	height: 320px;
	position: relative;
	display: flex;
	flex-direction: column;
}

body.light-theme .ghost-card {
	background: rgba(240, 240, 240, 0.5);
}

.ghost-image,
.ghost-title,
.ghost-text {
	position: relative;
	overflow: hidden;
}

.ghost-image {
	height: 180px;
	background: rgba(255, 255, 255, 0.03);
	width: 100%;
}

/* Ghost card body container to match regular card-body */
.ghost-body {
	padding: 25px;
	display: flex;
	flex-direction: column;
	flex-grow: 1;
}

.ghost-title {
	height: 24px;
	width: 70%;
	background: rgba(255, 255, 255, 0.03);
	margin-bottom: 15px;
	border-radius: 4px;
}

.ghost-text {
	height: 16px;
	width: 100%;
	background: rgba(255, 255, 255, 0.03);
	margin-bottom: 10px;
	border-radius: 4px;
}

.ghost-text:nth-child(3) {
	width: 90%;
}

body.light-theme .ghost-image,
body.light-theme .ghost-title,
body.light-theme .ghost-text {
	background: rgba(0, 0, 0, 0.05);
}

.ghost-image:after,
.ghost-title:after,
.ghost-text:after {
	content: "";
	position: absolute;
	top: 0;
	left: 0;
	width: 100%;
	height: 100%;
	background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.05), transparent);
	animation: loading 1.5s infinite;
}

.ghost-title:after {
	animation-delay: 0.2s;
}

.ghost-text:after {
	animation-delay: 0.4s;
}

body.light-theme .ghost-image:after,
body.light-theme .ghost-title:after,
body.light-theme .ghost-text:after {
	background: linear-gradient(90deg, transparent, rgba(0, 0, 0, 0.07), transparent);
}

@media (max-width: 768px) {
	.ghost-body {
		padding: 20px;
	}
}

@keyframes loading {
	0% {
		transform: translateX(-100%);
	}

	100% {
		transform: translateX(100%);
	}
}

/* Highlight effects */
.card.highlight-proximity::before {
	opacity: calc(var(--intensity) * 1);
	background: linear-gradient(var(--rotate, 0deg),
			rgba(255, 255, 255, 0) 0%,
			rgba(255, 255, 255, 0.4) 50%,
			rgba(255, 255, 255, 0) 100%);
}

.card.highlight-proximity::after {
	opacity: calc(var(--intensity) * 0.7);
	filter: blur(8px);
	
	/* Firefox-specific adjustment */
	@-moz-document url-prefix() {
		opacity: calc(var(--intensity) * 0.4); /* Even lower opacity for Firefox */
	}
}


.category-button.highlight-proximity,
.subcategory-button.highlight-proximity {
	border-color: rgba(200, 200, 200, calc(var(--intensity, 0) * 0.6));
	transform: translateY(calc(var(--intensity, 0) * -2px));
	box-shadow: 0 calc(var(--intensity, 0) * 8px) calc(var(--intensity, 0) * 15px) rgba(0, 0, 0, calc(var(--intensity, 0) * 0.4));
}

.category-button.highlight-proximity::after,
subcategory-button.highlight-proximity::after,
card-link.highlight-proximity::after,
search-container.highlight-proximity::after {
	opacity: calc(var(--intensity) * 0.8);
	background: radial-gradient(circle at var(--x, 50%) var(--y, 50%),
			rgba(255, 255, 255, 0.2) 0%,
			rgba(255, 255, 255, 0.04) 30%,
			transparent 60%);
	filter: blur(4px);
}

.search-container.highlight-proximity .search-input {
	border-color: rgba(180, 180, 180, calc(var(--intensity) * 0.6));
	box-shadow: 0 0 0 calc(var(--intensity) * 3px) rgba(100, 100, 100, 0.15),
		0 0 calc(var(--intensity) * 15px) rgba(100, 100, 100, 0.2);
}

/* Random tip modal */
.random-tip-modal {
	position: fixed;
	top: 0;
	left: 0;
	width: 100%;
	height: 100%;
	background: rgba(0, 0, 0, 0.8);
	backdrop-filter: blur(10px);
	-webkit-backdrop-filter: blur(10px);
	z-index: 9999;
	display: flex;
	justify-content: center;
	align-items: center;
	opacity: 0;
	visibility: hidden;
	transition: opacity 0.3s ease, visibility 0.3s ease;
}

/* Add styles for active random tip modal */
.random-tip-modal.active {
	opacity: 1;
	visibility: visible;
}

/* Add styles for modal content with smoother animations */
.random-tip-modal .modal-content {
	background: var(--glass-bg);
	backdrop-filter: blur(20px);
	-webkit-backdrop-filter: blur(20px);
	border: 1px solid var(--glass-border);
	border-radius: var(--card-radius);
	width: 90%;
	max-width: 500px;
	max-height: 90vh;
	overflow-y: auto;
	box-shadow: var(--shadow);
	animation: modal-appear 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
	opacity: 1;
	transform: scale(1);
	transition: opacity 0.3s ease, transform 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

/* Add exit animation for modal content */
.random-tip-modal.closing .modal-content {
	opacity: 0;
	transform: scale(0.85);
}

@keyframes modal-appear {
	from {
		opacity: 0;
		transform: scale(0.8);
	}

	to {
		opacity: 1;
		transform: scale(1);
	}
}

.random-tip-modal .modal-header {
	padding: 20px;
	display: flex;
	justify-content: space-between;
	align-items: center;
	border-bottom: 1px solid var(--glass-border);
}

.random-tip-modal .modal-header h2 {
	margin: 0;
	font-size: 20px;
	display: flex;
	align-items: center;
	gap: 10px;
}

.random-tip-modal .modal-close {
	background: transparent;
	border: none;
	color: var(--text-light);
	font-size: 24px;
	cursor: pointer;
	padding: 5px;
	display: flex;
	align-items: center;
	justify-content: center;
	transition: all 0.3s ease;
}

.random-tip-modal .modal-close:hover {
	color: #ff4b4b;
}

.random-tip-modal .modal-body {
	padding: 20px;
}

.random-tip-modal .card-image {
	height: 200px;
	margin-bottom: 20px;
	border-radius: 8px;
}

.random-tip-modal h3 {
	margin-bottom: 15px;
	color: var(--text-light);
}

.random-tip-modal p {
	margin-bottom: 20px;
	text-align: left;
}

/* Modal source styling */
.modal-source {
	margin-bottom: 20px !important;
	background: rgba(45, 45, 50, 0.5) !important;
	font-size: 13px !important;
}

body.light-theme .modal-source {
	background: rgba(220, 220, 220, 0.7) !important;
}

/* Light Theme */
:root.light-theme,
body.light-theme {
	--primary-color: #555;
	--secondary-color: #777;
	--glass-bg: rgba(255, 255, 255, 0.8);
	--glass-border: rgba(200, 200, 200, 0.7);
	--text-light: #111;
	--text-dark: #333;
	--text-muted: rgba(70, 70, 70, 0.85);
	--shadow: 0 10px 25px rgba(0, 0, 0, 0.06);
}

body.light-theme {
	background: #f0f2f5;
	background-image:
		radial-gradient(circle at top right, rgba(80, 80, 80, 0.06), transparent 60%),
		radial-gradient(circle at bottom left, rgba(100, 100, 100, 0.06), transparent 60%);
}

body.light-theme .card,
body.light-theme .search-input,
body.light-theme .category-button,
body.light-theme .subcategory-button,
body.light-theme .mobile-dropdown-button,
body.light-theme .floating-action-btn,
body.light-theme .preloader {
	background: rgba(255, 255, 255, 0.8);
	color: var(--text-dark);
}

body.light-theme .card {
	border-color: rgba(200, 200, 200, 0.6);
}

body.light-theme .category-button:hover,
body.light-theme .subcategory-button:hover {
	color: var(--primary-color);
}

body.light-theme .category-button.active {
	background: rgba(100, 100, 100, 0.1);
	color: var(--primary-color);
}

body.light-theme .subcategory-button.active {
	background: rgba(100, 100, 100, 0.15);
	border-color: rgba(100, 100, 100, 0.3);
	color: var(--primary-color);
}

body.light-theme .fab-option {
	background: rgba(255, 255, 255, 0.9);
	color: var(--text-dark);
}

body.light-theme .mobile-dropdown-button {
	background: rgba(255, 255, 255, 0.8);
	color: var(--text-dark);
}

body.light-theme .mobile-dropdown-content {
	background: rgba(255, 255, 255, 0.9);
}

body.light-theme .mobile-dropdown-content .category-button {
	border-bottom-color: rgba(200, 200, 200, 0.4);
}

body.light-theme .mobile-dropdown-content .category-button.active {
	background: rgba(100, 100, 100, 0.1);
}

body.light-theme .floating-action-btn {
	background: #fff;
	box-shadow: 0 8px 25px rgba(0, 0, 0, 0.2);
}

body.light-theme .fab-icon {
	color: #333;
}

body.light-theme .preloader {
	background: #f0f2f5;
}

body.light-theme h1 {
	background: linear-gradient(to right, #333, #777);
	-webkit-background-clip: text;
	background-clip: text;
}

body.light-theme .card-title {
	color: #222;
}

body.light-theme .card-link {
	background: #3a3a3a;
	color: white;
}

body.light-theme .card-link:hover {
	background: #555;
}

body.light-theme .ghost-card {
	background: rgba(240, 240, 240, 0.5);
}

body.light-theme .ghost-image,
body.light-theme .ghost-title,
body.light-theme .ghost-text {
	background: rgba(0, 0, 0, 0.05);
}

body.light-theme .ghost-image:after,
body.light-theme .ghost-title:after,
body.light-theme .ghost-text:after {
	background: linear-gradient(90deg, transparent, rgba(0, 0, 0, 0.07), transparent);
}

body.light-theme .nav-arrow {
	background: rgba(255, 255, 255, 0.8);
	color: #333;
}

body.light-theme .nav-arrow:hover {
	background: rgba(240, 240, 240, 0.9);
}

/* Light theme styles for tooltip */
body.light-theme .category-button .info-tooltip {
	background: #1976D2;
}

body.light-theme .tooltip-content {
	color: var(--text-dark);
}

/* Floating Action Button */
.floating-action-btn {
	position: fixed;
	right: 30px;
	bottom: 30px;
	width: 60px;
	height: 60px;
	background: #333;
	border-radius: 50%;
	box-shadow: 0 8px 25px rgba(0, 0, 0, 0.5);
	z-index: 999;
	display: flex;
	justify-content: center;
	align-items: center;
	cursor: pointer;
	transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

.floating-action-btn:hover {
	transform: translateY(-5px);
	box-shadow: 0 12px 30px rgba(0, 0, 0, 0.6);
	background: #444;
}

.fab-icon {
	color: white;
	display: flex;
	align-items: center;
	justify-content: center;
	transition: all 0.4s cubic-bezier(0.68, -0.55, 0.265, 1.55);
}

.fab-options {
	position: absolute;
	bottom: 80px;
	right: 10px;
	width: 220px;
	display: flex;
	flex-direction: column;
	gap: 12px;
	opacity: 0;
	pointer-events: none;
	transform: translateY(15px) scale(0.95);
	transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

.floating-action-btn.active {
	box-shadow: 0 15px 35px rgba(0, 0, 0, 0.6);
}

.floating-action-btn.active .fab-icon {
	transform: rotate(135deg);
}

.floating-action-btn.active .fab-options {
	opacity: 1;
	transform: translateY(0) scale(1);
	pointer-events: all;
}

.fab-option {
	background: var(--glass-bg);
	backdrop-filter: blur(20px);
	-webkit-backdrop-filter: blur(20px);
	border: 1px solid var(--glass-border);
	padding: 14px 18px;
	border-radius: 14px;
	color: var(--text-light);
	display: flex;
	align-items: center;
	gap: 12px;
	cursor: pointer;
	transition: all 0.3s ease;
	box-shadow: 0 8px 20px rgba(0, 0, 0, 0.3);
}

.fab-option:hover {
	transform: translateX(-8px);
	background: rgba(70, 70, 70, 0.6);
}

.fab-option span {
	font-size: 15px;
	font-weight: 500;
}

/* Remove mobile dropdown overlay completely */
.mobile-dropdown-overlay {
	display: none !important;
	/* Hide overlay completely */
}

/* Mobile dropdown wrapper */
.mobile-dropdown-wrapper {
	position: relative;
	width: 100%;
	z-index: 100;
	/* Keep high z-index */
	margin-bottom: 15px;
}

/* Dropdown button */
.mobile-dropdown-button {
	background: var(--glass-bg);
	backdrop-filter: blur(20px);
	-webkit-backdrop-filter: blur(20px);
	border: 1px solid var(--glass-border);
	border-radius: 50px;
	padding: 12px 20px;
	width: 100%;
	color: var(--text-light);
	font-size: 16px;
	cursor: pointer;
	display: flex;
	align-items: center;
	justify-content: space-between;
	position: relative;
	box-shadow: var(--shadow);
	display: none;
	/* Hidden by default on desktop */
	z-index: 102;
	/* Keep high z-index */
	transition: border-color 0.3s ease, transform 0.3s ease, box-shadow 0.3s ease;
}

.mobile-dropdown-button:hover {
	border-color: rgba(180, 180, 180, 0.7);
	transform: translateY(-2px);
	box-shadow: 0 8px 25px rgba(0, 0, 0, 0.25);
}

.mobile-dropdown-button .dropdown-icon {
	display: flex;
	align-items: center;
	justify-content: center;
	transition: transform 0.3s ease;
}

.mobile-dropdown-button.active .dropdown-icon {
	transform: rotate(180deg);
}

/* Ensure dropdown content is above overlay */
.mobile-dropdown-content {
	position: absolute;
	top: calc(100% + 5px);
	left: 0;
	width: 100%;
	background: var(--glass-bg);
	border: 1px solid var(--glass-border);
	border-radius: 15px;
	box-shadow: var(--shadow);
	max-height: 0;
	transition: all 0.3s ease;
	opacity: 0;
	transform: translateY(-10px);
	pointer-events: none;
	z-index: 101;
	/* Keep high z-index */
	overflow: hidden;
}

.mobile-dropdown-content.active {
	max-height: 80vh;
	opacity: 1;
	transform: translateY(0);
	pointer-events: auto;
	overflow-y: auto;
	padding: 5px 0;
}

.mobile-dropdown-content .category-button {
	width: 100%;
	border-radius: 0;
	padding: 15px 20px;
	justify-content: flex-start;
	border: none;
	border-bottom: 1px solid rgba(80, 80, 85, 0.3);
	background: transparent;
	margin: 0;
	transform: none !important;
	opacity: 1 !important;
	transition: background 0.3s ease, color 0.3s ease;
}

.mobile-dropdown-content .category-button:last-child {
	border-bottom: none;
}

.mobile-dropdown-content .category-button:active {
	background-color: rgba(90, 90, 95, 0.3);
}

/* Mobile userscripts tip improvements */
.mobile-userscript-tip {
	border-radius: var(--card-radius);
	background: var(--glass-bg);
	backdrop-filter: blur(15px);
	-webkit-backdrop-filter: blur(15px);
	border: 1px solid var(--glass-border);
	padding: 18px;
	margin-bottom: 25px;
	box-shadow: var(--shadow);
	grid-column: 1 / -1;
	display: flex;
	flex-direction: column;
	gap: 12px;
}

.mobile-userscript-tip h3 {
	display: flex;
	align-items: center;
	gap: 10px;
	font-size: 18px;
	color: var(--text-light);
	margin-bottom: 5px;
}

.mobile-userscript-tip p {
	text-align: left;
	margin-bottom: 10px;
	font-size: 14px;
	line-height: 1.6;
}

.mobile-userscript-tip .script-managers {
	display: flex;
	flex-wrap: wrap;
	gap: 10px;
	margin-top: 5px;
}

.mobile-userscript-tip .manager-button {
	display: flex;
	align-items: center;
	gap: 8px;
	padding: 10px 15px;
	background: rgba(70, 70, 75, 0.4);
	border-radius: 30px;
	text-decoration: none;
	color: var(--text-light);
	font-size: 14px;
	flex: 1 0 auto;
	min-width: 120px;
	transition: all 0.3s ease;
}

.mobile-userscript-tip .manager-button:hover {
	background: rgba(90, 90, 95, 0.6);
	transform: translateY(-3px);
}

.mobile-userscript-tip .manager-button.recommended {
	background: rgba(33, 150, 243, 0.3);
	border: 1px solid rgba(33, 150, 243, 0.5);
}

.mobile-userscript-tip .manager-button.recommended:hover {
	background: rgba(33, 150, 243, 0.4);
}

@media (max-width: 576px) {
	.mobile-userscript-tip {
		padding: 15px;
	}

	.mobile-userscript-tip .script-managers {
		flex-direction: column;
	}

	.mobile-userscript-tip .manager-button {
		width: 100%;
	}
}

/* Responsive Design */
@media (min-width: 992px) {
	.nav-indicators {
		display: none;
	}

	.category-nav {
		overflow-x: visible;
		flex-wrap: wrap;
		justify-content: center;
		padding: 5px 0;
	}

	.category-nav-wrapper {
		overflow: visible;
		display: block;
		/* Always display on desktop */
	}

	.mobile-dropdown-wrapper {
		display: none;
		/* Never show the mobile dropdown on desktop */
	}
}

@media (max-width: 991px) {
	.nav-indicators {
		display: block;
	}

	.category-nav {
		overflow-x: auto;
		scrollbar-width: none;
		-ms-overflow-style: none;
		padding-left: 0;
		padding-right: 0;
		scroll-padding: 0;
		scroll-snap-type: none;
		scroll-behavior: smooth;
	}
}

@media (max-width: 768px) {
	.content-section {
		grid-template-columns: repeat(auto-fill, minmax(100%, 1fr));
	}

	body {
		padding: 15px;
	}

	header {
		padding: 25px 20px;
		border-radius: 12px;
	}

	h1 {
		font-size: 2.2rem;
	}

	.category-nav {
		gap: 10px;
		margin: 25px 0;
	}

	.category-button {
		padding: 10px 18px;
		font-size: 14px;
		border-radius: 25px;
		width: calc(50% - 10px);
		flex: 0 0 calc(50% - 10px);
		justify-content: flex-start;
	}

	.subcategory-button {
		padding: 7px 14px;
		font-size: 13px;
	}

	.card-body {
		padding: 20px;
	}

	.card-title {
		font-size: 18px;
	}

	.nav-container {
		margin: 15px 0;
		position: relative;
	}

	.mobile-dropdown-button {
		display: flex;
		align-items: center;
		width: 100%;
		z-index: 101;
		/* Ensure mobile dropdown button is above overlay */
	}

	.nav-indicators {
		display: none;
	}

	.category-nav-wrapper {
		display: none !important;
		/* Force hide on mobile */
	}

	.mobile-dropdown-wrapper {
		display: block;
		/* Always show on mobile */
		margin-bottom: 20px;
	}

	.mobile-dropdown-content {
		max-height: 0;
		overflow: hidden;
		opacity: 0;
		transform: translateY(-10px);
		transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
	}

	.mobile-dropdown-content.active {
		max-height: 60vh;
		/* Limit height but allow scrolling */
		overflow-y: auto;
		opacity: 1;
		transform: translateY(0);
		pointer-events: auto;
		padding: 5px 0;
	}

	.mobile-dropdown-content {
		width: 100%;
		left: 0;
	}

	.mobile-dropdown-content.active {
		display: block;
	}

	.mobile-dropdown-content .category-nav {
		display: block;
		white-space: normal;
		transform: none;
		padding: 0;
		margin: 0;
	}

	.subcategory-nav {
		margin-top: 20px;
		padding-top: 10px;
		margin-bottom: 15px;
	}

	.fab-options {
		width: 180px;
	}

	.fab-option {
		padding: 12px 16px;
		border-radius: 12px;
	}

	.fab-option span {
		font-size: 14px;
	}
}

@media (max-width: 576px) {
	h1 {
		font-size: 1.8rem;
	}

	p {
		font-size: 14px;
	}

	body {
		padding: 10px;
	}

	header {
		padding: 20px 15px;
		border-radius: 10px;
		margin-bottom: 20px;
	}

	.search-container {
		margin: 20px auto;
	}

	.search-input {
		padding: 14px 20px 14px 45px;
		font-size: 14px;
	}

	.search-icon {
		left: 16px;
		width: 20px;
		height: 20px;
	}

	.floating-action-btn {
		width: 50px;
		height: 50px;
		right: 15px;
		bottom: 15px;
	}

	.subcategory-nav {
		flex-direction: row;
		flex-wrap: nowrap;
		overflow-x: auto;
		padding-bottom: 8px;
		margin-bottom: 15px;
		-webkit-overflow-scrolling: touch;
		scrollbar-width: none;
	}

	.subcategory-nav::-webkit-scrollbar {
		display: none;
	}

	.subcategory-button {
		flex: 0 0 auto;
		white-space: nowrap;
	}

	.card {
		border-radius: 10px;
	}

	.card-image {
		height: 150px;
	}

	.card-title {
		font-size: 16px;
		margin-bottom: 10px;
	}

	.card-text {
		font-size: 14px;
		margin-bottom: 15px;
	}

	.card-link {
		padding: 8px 16px;
		font-size: 14px;
	}
}

@media (max-width: 380px) {
	h1 {
		font-size: 1.6rem;
	}

	.category-button {
		padding: 8px 12px;
		font-size: 12px;
	}

	.subcategory-button {
		padding: 6px 12px;
		font-size: 12px;
	}
}

@media (pointer: coarse) {

	.category-button,
	.subcategory-button,
	.card-link,
	.mobile-dropdown-button,
	.floating-action-btn,
	fab-option {
		min-height: 44px;
	}

	.card-link {
		padding-top: 12px;
		padding-bottom: 12px;
	}

	.floating-action-btn {
		width: 56px;
		height: 56px;
	}
}

@media (max-width: 768px) {
	.particle {
		opacity: 0.1;
	}
}

@keyframes float {
	0% {
		transform: translateY(0px);
	}

	50% {
		transform: translateY(-10px);
	}

	100% {
		transform: translateY(0px);
	}
}

/* Particles */
.particles-container {
	position: fixed;
	top: 0;
	left: 0;
	width: 100%;
	height: 100%;
	z-index: -1;
	opacity: 0.6;
}

.particle {
	position: absolute;
	border-radius: 50%;
	background: #888;
	opacity: 0.15;
	pointer-events: none;
	box-shadow: 0 0 8px 2px rgba(255, 255, 255, 0.05);
	filter: blur(1px);
	animation: float 40s infinite ease-in-out;
}

/* Notice Banner for Userscripts */
.notice-banner {
	grid-column: 1 / -1;
	/* Span all columns */
	background: linear-gradient(135deg, rgba(25, 118, 210, 0.1) 0%, rgba(25, 118, 210, 0.2) 100%);
	border: 1px solid rgba(25, 118, 210, 0.3);
	border-left: 4px solid #1976D2;
	border-radius: 8px;
	padding: 16px 20px;
	margin-bottom: 25px;
	display: flex;
	align-items: flex-start;
	gap: 15px;
	box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
	animation: notice-appear 0.6s cubic-bezier(0.16, 1, 0.3, 1);
}

.notice-banner .notice-icon {
	font-size: 24px;
	color: #1976D2;
	flex-shrink: 0;
	margin-top: 3px;
}

.notice-banner .notice-content {
	flex: 1;
}

.notice-banner h3 {
	margin: 0 0 10px 0;
	color: var(--text-light);
	font-size: 18px;
}

.notice-banner p {
	margin: 0 0 12px 0;
	text-align: left;
	font-size: 14px;
	line-height: 1.5;
}

.notice-banner ul {
	list-style: none;
	padding: 0;
	margin: 0;
	display: flex;
	flex-wrap: wrap;
	gap: 12px;
}

.notice-banner li {
	margin-bottom: 5px;
	position: relative;
}

.notice-banner a {
	display: inline-flex;
	align-items: center;
	gap: 6px;
	background: rgba(25, 118, 210, 0.12);
	color: #2196F3;
	padding: 6px 12px;
	border-radius: 6px;
	text-decoration: none;
	font-size: 14px;
	font-weight: 500;
	transition: all 0.3s ease;
}

.notice-banner a:hover {
	background: rgba(25, 118, 210, 0.25);
	color: #42a5f5;
	transform: translateY(-2px);
}

/* Recommendation badge styling */
.recommended-badge {
	display: inline-block;
	background-color: #2e7d32;
	/* Green color */
	color: white;
	font-size: 11px;
	font-weight: 500;
	padding: 3px 8px;
	border-radius: 4px;
	margin-left: 6px;
	position: relative;
	animation: none;
	/* Remove animation */
}

/* Remove the pulse animation keyframes as they're no longer needed */
@keyframes pulse {
	0% {
		transform: rotate(3deg) scale(1);
	}

	50% {
		transform: rotate(3deg) scale(1.05);
	}

	100% {
		transform: rotate(3deg) scale(1);
	}
}

/* Notice banner styling adjustments */
.notice-banner ul {
	margin-top: 10px;
}

.notice-banner li {
	margin-bottom: 8px;
	display: flex;
	align-items: center;
	flex-wrap: wrap;
}

.notice-banner li a {
	margin-right: 0;
	/* Allow the badge to be positioned right next to the link */
}

/* Animation for notice banner */
@keyframes notice-appear {
	from {
		opacity: 0;
		transform: translateY(-10px);
	}

	to {
		opacity: 1;
		transform: translateY(0);
	}
}

/* Light theme styles for the notice banner */
body.light-theme .notice-banner {
	background: linear-gradient(135deg, rgba(25, 118, 210, 0.05) 0%, rgba(25, 118, 210, 0.15) 100%);
	border: 1px solid rgba(25, 118, 210, 0.2);
	border-left: 4px solid #1976D2;
}

body.light-theme .notice-banner h3 {
	color: #1565C0;
}

body.light-theme .notice-banner a {
	background: rgba(25, 118, 210, 0.1);
	color: #1976D2;
}

body.light-theme .notice-banner a:hover {
	background: rgba(25, 118, 210, 0.2);
}

body.light-theme .recommended-badge {
	background: #2e7d32;
}

/* Responsive styles for the notice banner */
@media (max-width: 768px) {
	.notice-banner {
		flex-direction: column;
		padding: 15px;
	}

	.notice-banner .notice-icon {
		margin-bottom: 10px;
	}

	.notice-banner ul {
		flex-direction: column;
		gap: 8px;
	}

	.notice-banner h3 {
		font-size: 16px;
	}

	.recommended-badge {
		/* Remove absolute positioning and animation */
		position: relative;
		top: auto;
		right: auto;
		left: auto;
		font-size: 10px;
		padding: 2px 6px;
		animation: none;
		transform: none;
	}
}

/* Recommendation badge for the userscripts notice */
.recommendation-badge {
	display: inline-block;
	background: rgba(46, 204, 113, 0.15);
	color: #2ecc71;
	font-size: 11px;
	font-weight: 600;
	padding: 3px 8px;
	border-radius: 4px;
	margin-left: 8px;
	text-transform: uppercase;
	letter-spacing: 0.5px;
	border: 1px solid rgba(46, 204, 113, 0.3);
	vertical-align: middle;
	box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05);
	animation: badge-pulse 2s infinite;
}

/* Subtle pulse animation for the badge */
@keyframes badge-pulse {
	0% {
		box-shadow: 0 0 0 0 rgba(46, 204, 113, 0.2);
	}

	70% {
		box-shadow: 0 0 0 6px rgba(46, 204, 113, 0);
	}

	100% {
		box-shadow: 0 0 0 0 rgba(46, 204, 113, 0);
	}
}

/* Light theme styling for the recommendation badge */
body.light-theme .recommendation-badge {
	background: rgba(46, 204, 113, 0.1);
	color: #27ae60;
	border: 1px solid rgba(46, 204, 113, 0.2);
}

/* Responsive styling for the badge on smaller screens */
@media (max-width: 480px) {
	.recommendation-badge {
		display: block;
		margin: 5px 0 0;
		text-align: center;
		font-size: 10px;
		padding: 2px 6px;
	}
}

/* Remove previous recommended-badge styling (if it exists) */
.recommended-badge {
	display: none;
}

/* Hide tooltip on mobile devices */
@media (max-width: 768px) {

	.category-button .info-tooltip,
	.category-button .tooltip-content {
		display: none !important;
	}

	/* Ensure mobile dropdown button is above overlay */
	.mobile-dropdown-button {
		z-index: 101;
	}

	/* Improve mobile dropdown content styling for better usability */
	.mobile-dropdown-content .category-button {
		padding: 15px 20px;
		margin: 0;
		border-radius: 0;
		transform: none !important;
		box-shadow: none;
		border: none;
		border-bottom: 1px solid var(--glass-border);
	}

	.mobile-dropdown-content .category-button:last-child {
		border-bottom: none;
	}

	.mobile-dropdown-content .category-button:active {
		background-color: rgba(90, 90, 95, 0.3);
	}
}

/* Copyright */
.copyright {
	display: inline-flex;
	align-items: center;
	gap: 8px;
	padding: 8px 15px;
	border-radius: 50px;
	background: rgba(40, 40, 45, 0.7);
	backdrop-filter: blur(10px);
	-webkit-backdrop-filter: blur(10px);
	border: 1px solid rgba(60, 60, 65, 0.6);
	color: #e6ebf0;
	margin-bottom: 0px;
	/* Reduced from 15px to 10px */
	user-select: none;
	/* Make text non-selectable */
	-webkit-user-select: none;
	-moz-user-select: none;
	-ms-user-select: none;
	transition: all 0.3s ease;
}

.copyright:hover {
	transform: translateY(-3px);
	box-shadow: 0 8px 20px rgba(0, 0, 0, 0.15);
}

body.light-theme .copyright {
	background: rgba(255, 255, 255, 0.6);
	color: #444;
	border-color: rgba(200, 200, 200, 0.6);
}

body.light-theme .copyright:hover {
	background: rgba(255, 255, 255, 0.8);
	color: #222;
}

/* No Results Found */
.no-results {
	width: 100%;
	padding: 2.5rem;
	text-align: center;
	background: var(--card-bg);
	border-radius: 12px;
	box-shadow: var(--card-shadow);
	margin: 1rem auto;
	max-width: 600px;
}

.no-results-content {
	display: flex;
	flex-direction: column;
	align-items: center;
	justify-content: center;
}

.search-icon-container {
	position: relative;
	width: 80px;
	height: 80px;
	display: flex;
	align-items: center;
	justify-content: center;
	margin-bottom: 1rem;
	background: var(--bg-lighter);
	border-radius: 50%;
}

.search-icon-container i.fa-magnifying-glass {
	font-size: 2.5rem;
	color: var(--highlight-color);
	opacity: 0.8;
}

.search-icon-container i.fa-question {
	position: absolute;
	font-size: 1.5rem;
	color: var(--text-color);
	top: 15px;
	right: 15px;
}

.animated-question {
	animation: bounce 2s infinite;
}

.no-results h3 {
	margin-bottom: 0.5rem;
	font-size: 1.5rem;
	font-weight: 600;
	color: var(--text-color);
}

.no-results p {
	color: var(--text-secondary);
	margin-bottom: 1.5rem;
}

.highlight-search-term {
	color: var(--highlight-color);
	font-weight: 600;
}

@keyframes bounce {

	0%,
	100% {
		transform: translateY(0);
	}

	50% {
		transform: translateY(-10px);
	}
}

/* Performance optimization styles */
@media (max-width: 768px) {

	/* Reduce animation complexity on mobile */
	.floating-action-btn,
	.fab-options {
		transition: all 0.25s ease-out;
	}

	/* Optimize layout for better rendering */
	.content-container {
		will-change: transform;
	}

	/* Reduce shadow complexity */
	.card,
	.button,
	.fab-icon {
		box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
	}
}

/* Toast notification */
.toast {
	position: fixed;
	bottom: -60px;
	left: 50%;
	transform: translateX(-50%);
	background: rgba(0, 0, 0, 0.7);
	color: white;
	padding: 12px 20px;
	border-radius: 4px;
	z-index: 10000;
	transition: bottom 0.3s ease-out;
}

.toast.show {
	bottom: 60px;
}

/* Optimize particle container */
#particles-container {
	position: fixed;
	top: 0;
	left: 0;
	width: 100%;
	height: 100%;
	z-index: -1;
	will-change: transform;
}

/* Card actions container for buttons and links */
.card-actions {
	display: flex;
	align-items: center;
	gap: 12px;
	margin-top: auto;
}

/* Share button styling */
.share-btn {
	display: flex;
	align-items: center;
	justify-content: center;
	width: 40px;
	height: 40px;
	background: #333;
	color: var(--text-light);
	border: none;
	border-radius: 50%;
	font-size: 15px;
	font-weight: 500;
	transition: all 0.3s ease;
	cursor: pointer;
	position: relative;
	overflow: hidden;
}

.share-btn:hover {
	transform: translateY(-2px);
	box-shadow: 0 5px 15px rgba(0, 0, 0, 0.4);
	background: #444;
}

/* Light theme share button */
body.light-theme .share-btn {
	background: #e0e0e0;
	color: #333;
}

body.light-theme .share-btn:hover {
	background: #d0d0d0;
}

/* Highlighted card animation for deep links */
.highlighted-card {
	animation: highlight-float 4.5s cubic-bezier(0.215, 0.610, 0.355, 1.000) forwards;
	position: relative;
	z-index: 10;
}

@keyframes highlight-float {
	0% {
		transform: translateY(0);
		box-shadow: 0 10px 30px rgba(255, 255, 255, 0.3);
		border-color: rgba(255, 255, 255, 0.6);
	}
	20% {
		transform: translateY(-5px);
		box-shadow: 0 15px 35px rgba(255, 255, 255, 0.4);
	}
	40% {
		transform: translateY(-3px);
		box-shadow: 0 12px 30px rgba(255, 255, 255, 0.2);
	}
	60% {
		transform: translateY(-4px);
		box-shadow: 0 13px 32px rgba(255, 255, 255, 0.3);
	}
	80% {
		transform: translateY(-2px);
		box-shadow: 0 12px 25px rgba(255, 255, 255, 0.15);
		border-color: rgba(200, 200, 200, 0.4);
	}
	100% {
		transform: translateY(0);
		box-shadow: var(--shadow);
		border-color: rgba(60, 60, 65, 0.6);
	}
}

/* Light theme highlighted card */
body.light-theme .highlighted-card {
	animation: highlight-float-light 4.5s cubic-bezier(0.215, 0.610, 0.355, 1.000) forwards;
}

@keyframes highlight-float-light {
	0% {
		transform: translateY(0);
		box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2);
		border-color: rgba(70, 70, 70, 0.6);
	}
	20% {
		transform: translateY(-5px);
		box-shadow: 0 15px 35px rgba(0, 0, 0, 0.15);
	}
	40% {
		transform: translateY(-3px);
		box-shadow: 0 12px 30px rgba(0, 0, 0, 0.1);
	}
	60% {
		transform: translateY(-4px);
		box-shadow: 0 13px 32px rgba(0, 0, 0, 0.12);
	}
	80% {
		transform: translateY(-2px);
		box-shadow: 0 12px 25px rgba(0, 0, 0, 0.08);
		border-color: rgba(120, 120, 120, 0.4);
	}
	100% {
		transform: translateY(0);
		box-shadow: var(--shadow);
		border-color: rgba(200, 200, 200, 0.6);
	}
}

/* Mobile optimizations for card actions */
@media (max-width: 576px) {
	.card-actions {
		gap: 10px;
	}
	
	.share-btn {
		width: 36px;
		height: 36px;
		font-size: 14px;
	}
}