/* Global Styles */
* {
	margin: 0;
	padding: 0;
	box-sizing: border-box;
	font-family: 'Roboto', sans-serif;
}

body {
	background-color: #f9f9f9;
}

/* Navbar Styles */
.navbar {
	display: flex;
	justify-content: space-between;
	align-items: center;
	padding: 0 20px;
	height: 56px;
	background-color: white;
	position: fixed;
	top: 0;
	left: 0;
	right: 0;
	z-index: 100;
	border-bottom: 1px solid #e5e5e5;
}

.logo-section {
	display: flex;
	align-items: center;
	gap: 10px;
}

.menu-icon {
	margin-right: 25px;
	cursor: pointer;
}

.youtube-logo {
	display: flex;
	align-items: center;
	color: #000;
	text-decoration: none;
}

.youtube-logo img {
	height: 80px;
}

.search-section {
	display: flex;
	align-items: center;
	flex: 0 1 728px;
	margin: 0 40px;
}

.search-bar {
	display: flex;
	flex: 1;
}

.search-input {
	flex: 1;
	border: 1px solid #ccc;
	border-radius: 10px 0 0 10px;
	padding: 10px 15px;
	font-size: 16px;
	height: 40px;
	width: 100%;
}

.search-button {
	border: 1px solid #ccc;
	background-color: #f8f8f8;
	border-radius: 0 10px 10px 0;
	cursor: pointer;
	height: 40px;
	width: 64px;
	display: flex;
	justify-content: center;
	align-items: center;
}

.voice-search {
	display: flex;
	justify-content: center;
	align-items: center;
	height: 40px;
	width: 40px;
	border-radius: 50%;
	background-color: #f8f8f8;
	margin-left: 10px;
	cursor: pointer;
}

.icons-section {
	display: flex;
	align-items: center;
}

.icon {
	display: flex;
	align-items: center;
	margin-left: 25px;
	cursor: pointer;
}

.create-button {
	display: flex;
	align-items: center;
	justify-content: center;
	height: 40px;
	padding: 0 16px;
	background-color: rgba(0, 0, 0, 0.8);
	color: white;
	border: none;
	border-radius: 20px;
	cursor: pointer;
	font-size: 14px;
	font-weight: 500;
	transition: background-color 0.3s ease;
}

.create-button:hover {
	background-color: rgba(0, 0, 0, 0.15);
}

.create-button .material-icons {
	margin-right: 8px;
	font-size: 20px;
}

.profile-icon {
	height: 32px;
	width: 32px;
	border-radius: 50%;
	background-color: #AAA;
	margin-left: 25px;
	cursor: pointer;
	display: flex;
	justify-content: center;
	align-items: center;
	color: white;
	font-weight: bold;
}

/* Sidebar Styles */
.sidebar {
	position: fixed;
	top: 56px;
	left: 0;
	height: calc(100vh - 56px);
	width: 240px;
	background-color: white;
	overflow-y: auto;
	z-index: 99;
	padding: 12px 0;
}

.sidebar::-webkit-scrollbar {
	width: 8px;
}

.sidebar::-webkit-scrollbar-track {
	background: transparent;
}

.sidebar::-webkit-scrollbar-thumb {
	background: #aaa;
	border-radius: 10px;
}

.sidebar-section {
	padding: 8px 0;
	border-bottom: 1px solid #e5e5e5;
}

.sidebar-item {
	display: flex;
	align-items: center;
	padding: 10px 24px;
	cursor: pointer;
	color: #030303;
	text-decoration: none;
	border-radius: 10px;
	transition: background-color 0.2s ease-in-out;
}

.sidebar-item:hover {
	background-color: rgba(0, 0, 0, 0.1);
}

.sidebar-item.active {
	background-color: rgba(0, 0, 0, 0.15);
	font-weight: 500;
}

.sidebar-icon {
	margin-right: 24px;
}

.sidebar-text {
	font-size: 14px;
}

.sidebar-header {
	padding: 8px 24px;
	font-size: 14px;
	color: #606060;
	font-weight: 500;
	text-transform: uppercase;
}

.sidebar-subscription {
	display: flex;
	align-items: center;
	padding: 10px 24px;
	gap: 10px;
}

.subscription-icon {
	width: 24px;
	height: 24px;
	border-radius: 50%;
	margin-right: 24px;
	overflow: hidden;
}

.sidebar-subscription img {
	width: 24px;
	height: 24px;
	border-radius: 50%;
	margin-right: 10px;
	object-fit: cover;
}

/* Categories Styles */
.categories {
	display: flex;
	overflow-x: auto;
	white-space: nowrap;
	background-color: white;
	padding: 12px 24px;
	margin-top: 56px;
	margin-left: 240px;
	border-top: 1px solid #e5e5e5;
	border-bottom: 1px solid #e5e5e5;
}

.categories::-webkit-scrollbar {
	display: none;
}

.category {
	margin-right: 12px;
	padding: 8px 12px;
	background-color: #f2f2f2;
	border-radius: 16px;
	font-size: 14px;
	cursor: pointer;
	transition: background-color 0.3s;
}

.category:hover {
	background-color: #e0e0e0;
}

.category.active {
	background-color: #030303;
	color: white;
}

/* Videos Section */
.videos-container {
	display: flex;
	flex-direction: column;
	padding: 24px;
	overflow-y: auto;
	height: calc(100vh - 166px);
	margin-left: 240px;
}

.videos-grid {
	display: flex;
	flex-wrap: wrap;
	gap: 16px;
}

.video-card {
	width: calc(25% - 16px);
	margin-bottom: 40px;
	cursor: pointer;
}

@media (max-width: 1650px) {
	.video-card {
		width: calc(33.33% - 16px);
	}
}

@media (max-width: 1350px) {
	.video-card {
		width: calc(50% - 16px);
	}
}

@media (max-width: 1000px) {
	.video-card {
		width: 100%;
	}
}

.thumbnail {
	width: 100%;
	height: 0;
	padding-bottom: 56.25%;
	/* 16:9 Aspect Ratio */
	background-color: #000;
	position: relative;
	border-radius: 8px;
	overflow: hidden;
}

.thumbnail img {
	position: absolute;
	top: 0;
	left: 0;
	width: 100%;
	height: 100%;
	object-fit: cover;
	transition: transform 0.3s ease;
}

.thumbnail::after {
	content: '';
	position: absolute;
	top: 0;
	left: 0;
	width: 100%;
	height: 100%;
	background: linear-gradient(to bottom, rgba(0, 0, 0, 0) 0%, rgba(0, 0, 0, 0.5) 100%);
	opacity: 0;
	transition: opacity 0.3s ease;
}

.thumbnail:hover img {
	transform: scale(1.1);
}

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

.video-duration {
	position: absolute;
	bottom: 8px;
	right: 8px;
	background-color: rgba(0, 0, 0, 0.8);
	color: white;
	padding: 3px 4px;
	border-radius: 2px;
	font-size: 12px;
}

.video-info {
	display: flex;
	margin-top: 12px;
}

.channel-icon {
	width: 36px;
	height: 36px;
	border-radius: 50%;
	background-color: #ccc;
	margin-right: 12px;
	overflow: hidden;
}

.channel-icon img {
	width: 100%;
	height: 100%;
	object-fit: cover;
}

.video-details {
	flex: 1;
}

.video-title {
	font-weight: 500;
	font-size: 14px;
	line-height: 20px;
	margin-bottom: 6px;
	display: -webkit-box;
	-webkit-line-clamp: 2;
	-webkit-box-orient: vertical;
	overflow: hidden;
}

.channel-name {
	font-size: 12px;
	color: #606060;
	margin-bottom: 4px;
	text-decoration: none;
}

.channel-name:hover {
	color: #000;
}

.video-metadata {
	font-size: 12px;
	color: #606060;
}

/* Footer Styles */
.footer {
	background-color: white;
	padding: 20px 24px;
	border-top: 1px solid #e5e5e5;
}

.categories-footer {
	display: flex;
	flex-wrap: wrap;
	gap: 12px;
	margin-bottom: 12px;
}

.footer-category {
	font-size: 13px;
	color: #606060;
	text-decoration: none;
	transition: color 0.3s ease;
}

.footer-category:hover {
	color: #000;
}

.copyright {
	font-size: 12px;
	color: #909090;
	margin-top: 8px;
}

/* Responsive adjustments */
@media (max-width: 768px) {
	.footer {
		margin-left: 0;
		padding: 16px;
	}

	.categories-footer {
		flex-direction: column;
		align-items: center;
	}
}

/* Icons */
.material-icons {
	font-size: 24px;
}

/* Sidebar collapsed state */
.sidebar-collapsed .sidebar {
	width: 72px;
}

.sidebar-collapsed .sidebar-text {
	display: none;
}

.sidebar-collapsed .subscription-icon {
	margin-right: 0;
}

.sidebar-collapsed .sidebar-item,
.sidebar-collapsed .sidebar-subscription {
	padding: 16px 0;
	justify-content: center;
}

.sidebar-collapsed .sidebar-header,
.sidebar-collapsed .sidebar-section:not(:first-child) {
	display: none;
}

.sidebar-collapsed .categories,
.sidebar-collapsed .videos-container,
.sidebar-collapsed .footer {
	margin-left: 72px;
}

/* Hide Sidebar on Small Screens */
@media (max-width: 768px) {
	.sidebar {
		display: none;
	}

	.categories {
		margin-left: 0;
	}

	.videos-container {
		margin-left: 0;
	}
}

/* Bottom Navigation Bar for Mobile */
.bottom-nav {
	display: none;
	position: fixed;
	bottom: 0;
	left: 0;
	right: 0;
	height: 56px;
	background-color: white;
	border-top: 1px solid #e5e5e5;
	justify-content: space-around;
	align-items: center;
	z-index: 100;
}

/* Show Bottom Nav Only on Mobile */
@media (max-width: 768px) {
	.bottom-nav {
		display: flex;
		/* Show the bottom nav on mobile */
	}
}

/* Bottom Nav Icons */
.bottom-nav-item {
	display: flex;
	flex-direction: column;
	align-items: center;
	justify-content: center;
	cursor: pointer;
	color: #606060;
	font-size: 12px;
}

.bottom-nav-item:hover {
	color: #000;
}

.bottom-nav-item .material-icons {
	font-size: 24px;
	margin-bottom: 2px;
}
