* {
	font-family: "Inter", sans-serif;
	-webkit-font-smoothing: antialiased;
	-moz-osx-font-smoothing: grayscale;
	font-optical-sizing: auto;
	font-style: normal;
}

body {
	overflow-x: hidden;
	/* Prevent horizontal scrollbar */
}

/* Ensure the app container takes full height without creating scrollbars */
#app {
	height: 100%;
	overflow: hidden;
}

/* Main content area should be scrollable */
main {
	height: calc(100% - 106px);
	/* Adjust based on header height */
	overflow-y: auto;
	overflow-x: hidden;
}

/* Custom scrollbar for main content */
main::-webkit-scrollbar {
	width: 6px;
}

main::-webkit-scrollbar-track {
	background: rgba(255, 255, 255, 0.05);
	border-radius: 3px;
}

main::-webkit-scrollbar-thumb {
	background: rgba(255, 255, 255, 0.2);
	border-radius: 3px;
}

main::-webkit-scrollbar-thumb:hover {
	background: rgba(255, 255, 255, 0.3);
}

.tvos-card {
	transition: all 0.2s cubic-bezier(0.25, 0.46, 0.45, 0.94);
	border-radius: 16px;
	background: linear-gradient(145deg, #1C1C1E, #2C2C2E);
	border: 1px solid rgba(255, 255, 255, 0.1);
}

.tvos-card:focus {
	outline: none;
	animation: tvos-focus 0.2s cubic-bezier(0.25, 0.46, 0.45, 0.94) forwards;
}

.tvos-card:not(:focus) {
	animation: tvos-unfocus 0.2s cubic-bezier(0.25, 0.46, 0.45, 0.94) forwards;
}

.tvos-card:active {
	animation: tvos-press 0.1s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

.tvos-button {
	background: rgba(0, 122, 255, 0.15);
	border: 1px solid rgba(0, 122, 255, 0.3);
	backdrop-filter: blur(20px);
	transition: all 0.2s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

.tvos-button:hover {
	background: rgba(0, 122, 255, 0.25);
	border-color: rgba(0, 122, 255, 0.5);
}

.tvos-button:focus {
	outline: none;
	background: rgba(0, 122, 255, 0.3);
	box-shadow: 0 0 20px rgba(0, 122, 255, 0.4);
}

.tvos-input {
	background: rgba(28, 28, 30, 0.8);
	border: 1px solid rgba(255, 255, 255, 0.1);
	backdrop-filter: blur(20px);
	transition: all 0.2s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

.tvos-input:focus {
	outline: none;
	border-color: rgba(0, 122, 255, 0.5);
	box-shadow: 0 0 20px rgba(0, 122, 255, 0.2);
}

.tvos-modal {
	backdrop-filter: blur(20px);
	background: rgba(0, 0, 0, 0.7);
}

.tvos-modal-content {
	background: linear-gradient(145deg, #1C1C1E, #2C2C2E);
	backdrop-filter: blur(40px);
	max-height: 90%;
	overflow: auto;
}

#tvGuideModal .tvos-modal-content, #tvAssistantModal .tvos-modal-content {
	max-height: 100%;
}

.tvos-square-button {
	width: 44px;
	height: 44px;
	display: flex;
	align-items: center;
	justify-content: center;
	border-radius: 12px;
	background: rgba(28, 28, 30, 0.8);
	border: 1px solid rgba(255, 255, 255, 0.1);
	transition: all 0.2s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

.tvos-square-button:hover {
	background: rgba(44, 44, 46, 0.8);
}

.tvos-square-button:focus {
	outline: none;
	background: rgba(44, 44, 46, 0.9);
	box-shadow: 0 0 20px rgba(0, 122, 255, 0.4);
}

.tvos-search-back-button {
	height: 48px;
	width: 48px;
	display: flex;
	align-items: center;
	justify-content: center;
	border-radius: 12px;
	background: rgba(28, 28, 30, 0.8);
	border: 1px solid rgba(255, 255, 255, 0.1);
	transition: all 0.2s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

.tvos-search-back-button:hover {
	background: rgba(44, 44, 46, 0.8);
}

.tvos-search-back-button:focus {
	outline: none;
	background: rgba(44, 44, 46, 0.9);
	box-shadow: 0 0 20px rgba(0, 122, 255, 0.4);
}

.guide-container {
	/* Remove fixed height and overflow to prevent double scrollbars */
	/* height: calc(100vh - 12rem) !important; */
	/* overflow-y: auto; */
	scroll-behavior: smooth;
	overflow: auto;
    height: 100%;
}

.guide-container::-webkit-scrollbar {
	width: 6px;
}

.guide-container::-webkit-scrollbar-track {
	background: rgba(255, 255, 255, 0.05);
	border-radius: 3px;
}

.guide-container::-webkit-scrollbar-thumb {
	background: rgba(255, 255, 255, 0.2);
	border-radius: 3px;
}

.guide-container::-webkit-scrollbar-thumb:hover {
	background: rgba(255, 255, 255, 0.3);
}

.provider-logo {
	background: linear-gradient(135deg, #007AFF, #5856D6);
	box-shadow: 0 4px 20px rgba(0, 122, 255, 0.3);
}

.channel-logo {
	width: 48px;
	height: 48px;
	background: linear-gradient(135deg, #2C2C2E, #3A3A3C);
	border: 1px solid rgba(255, 255, 255, 0.1);
	border-radius: 8px;
	display: flex;
	align-items: center;
	justify-content: center;
	font-size: 0.875rem;
	font-weight: bold;
	flex-shrink: 0;
	overflow: hidden;
}

.channel-logo img {
	width: 100%;
	height: 100%;
	object-fit: contain;
	padding: 6px;
	border: none;
	border-radius: 0;
}

.loading-shimmer {
	background: linear-gradient(90deg,
			rgba(255, 255, 255, 0.05) 25%,
			rgba(255, 255, 255, 0.1) 50%,
			rgba(255, 255, 255, 0.05) 75%);
	background-size: 200% 100%;
	animation: shimmer 1.5s infinite;
}

@keyframes shimmer {
	0% {
		background-position: -200% 0;
	}

	100% {
		background-position: 200% 0;
	}
}

.glass-effect {
	background: rgba(28, 28, 30, 0.8);
	backdrop-filter: blur(20px);
	border: 1px solid rgba(255, 255, 255, 0.1);
}

#videoPlayer:hover #videoControls {
	opacity: 1;
}

#video::-webkit-media-controls {
	opacity: 0;
	transition: opacity 0.3s;
}

#videoPlayer:hover #video::-webkit-media-controls {
	opacity: 1;
}

.cursor-none {
	cursor: none;
}

#videoPlayer:hover .cursor-none {
	cursor: default;
}

/* Mobile touch optimizations */
@media (hover: none) {
	#videoPlayer:hover #videoControls {
		opacity: 0;
	}

	#videoPlayer:hover .cursor-none {
		cursor: none;
	}
}

/* Video Controls Styling */
.tvos-control-button {
	width: 44px;
	height: 44px;
	display: flex;
	align-items: center;
	justify-content: center;
	border-radius: 12px;
	background: rgba(28, 28, 30, 0.6);
	border: 1px solid rgba(255, 255, 255, 0.1);
	transition: all 0.2s cubic-bezier(0.25, 0.46, 0.45, 0.94);
	color: white;
}

.tvos-control-button:hover {
	background: rgba(44, 44, 46, 0.8);
	transform: scale(1.05);
}

.tvos-control-button:active {
	transform: scale(0.95);
}

.tvos-slider {
	-webkit-appearance: none;
	appearance: none;
	height: 4px;
	background: rgba(255, 255, 255, 0.2);
	border-radius: 2px;
	outline: none;
	position: relative;
}

.tvos-slider::-webkit-slider-track {
	height: 4px;
	background: rgba(255, 255, 255, 0.2);
	border-radius: 2px;
}

.tvos-slider::-webkit-slider-thumb {
	-webkit-appearance: none;
	appearance: none;
	width: 16px;
	height: 16px;
	background: #007AFF;
	border-radius: 50%;
	cursor: pointer;
	transition: all 0.2s ease;
}

.tvos-slider::-webkit-slider-thumb:hover {
	transform: scale(1.2);
	box-shadow: 0 0 10px rgba(0, 122, 255, 0.5);
}

/* Firefox slider styling */
.tvos-slider::-moz-range-track {
	height: 4px;
	background: rgba(255, 255, 255, 0.2);
	border-radius: 2px;
	border: none;
}

.tvos-slider::-moz-range-thumb {
	width: 16px;
	height: 16px;
	background: #007AFF;
	border-radius: 50%;
	border: none;
	cursor: pointer;
}

.tvos-slider::-moz-range-progress {
	height: 4px;
	background: #007AFF;
	border-radius: 2px;
}

.live-indicator {
	background: rgba(255, 59, 48, 0.15);
	border: 1px solid rgba(255, 59, 48, 0.3);
	backdrop-filter: blur(20px);
	padding: 8px 16px;
	border-radius: 20px;
	transition: all 0.2s cubic-bezier(0.25, 0.46, 0.45, 0.94);
	color: #FF3B30;
}

.live-indicator.view-live {
	background: rgba(0, 122, 255, 0.15);
	border-color: rgba(0, 122, 255, 0.3);
	color: #007AFF;
}

.live-indicator:hover {
	transform: scale(1.05);
}

.live-dot {
	width: 8px;
	height: 8px;
	background: #FF3B30;
	border-radius: 50%;
	animation: live-pulse 2s infinite;
}

.live-indicator.view-live .live-dot {
	background: #007AFF;
	animation: none;
}

@keyframes live-pulse {

	0%,
	100% {
		opacity: 1;
	}

	50% {
		opacity: 0.3;
	}
}

/* Mobile Controls */
@media (max-width: 768px) {
	#videoControls {
		top: 4px;
		left: 4px;
		right: 4px;
		flex-direction: row;
		gap: 0;
	}

	#videoBottomControls {
		bottom: 4px;
		left: 4px;
		right: 4px;
	}

	#nowPlaying {
		padding: 12px 16px;
		flex: 1;
		margin-right: 8px;
		min-width: 0;
	}

	#nowPlaying .flex {
		gap: 12px;
	}

	#currentChannelLogo {
		width: 40px;
		height: 40px;
		font-size: 16px;
		flex-shrink: 0;
	}

	#currentChannelName {
		font-size: 18px;
		line-height: 1.3;
		font-weight: 600;
		overflow: hidden;
		text-overflow: ellipsis;
		white-space: nowrap;
	}

	#nowPlaying p:first-child {
		font-size: 12px;
		margin-bottom: 4px;
		opacity: 0.8;
	}

	.tvos-control-button {
		width: 40px;
		height: 40px;
	}

	#closePlayerBtn {
		width: 44px;
		height: 44px;
		flex-shrink: 0;
		margin: 0;
		position: static;
	}

	#volumeContainer {
		display: none !important;
	}

	.live-indicator {
		padding: 8px 14px;
		font-size: 13px;
	}

	.live-dot {
		width: 8px;
		height: 8px;
	}
}

@media (max-width: 480px) {
	#videoControls {
		top: 2px;
		left: 2px;
		right: 2px;
	}

	#videoBottomControls {
		bottom: 2px;
		left: 2px;
		right: 2px;
	}

	#nowPlaying {
		padding: 10px 14px;
		border-radius: 14px;
		margin-right: 6px;
	}

	#nowPlaying .flex {
		gap: 10px;
	}

	#currentChannelLogo {
		width: 36px;
		height: 36px;
		font-size: 14px;
	}

	#currentChannelName {
		font-size: 16px;
		line-height: 1.2;
		max-width: calc(100vw - 140px);
	}

	#nowPlaying p:first-child {
		font-size: 11px;
		margin-bottom: 3px;
	}

	#closePlayerBtn {
		width: 40px;
		height: 40px;
	}

	#closePlayerBtn i {
		font-size: 16px;
	}

	.glass-effect {
		backdrop-filter: blur(15px);
	}

	.tvos-control-button {
		width: 36px;
		height: 36px;
	}

	.live-indicator {
		padding: 6px 10px;
		font-size: 12px;
	}

	.live-dot {
		width: 6px;
		height: 6px;
	}
}

/* Control visibility */
#videoPlayer:hover #videoControls,
#videoPlayer:hover #videoBottomControls {
	opacity: 1;
}

/* Mobile touch optimizations */
@media (hover: none) {

	#videoPlayer:hover #videoControls,
	#videoPlayer:hover #videoBottomControls {
		opacity: 0;
	}
}

.cursor-none {
	cursor: none;
}

#videoPlayer:hover .cursor-none {
	cursor: default;
}

.touch-none {
	touch-action: none;
}

.touch-manipulation {
	touch-action: manipulation;
}

/* Add circular button style */
.tvos-circle-button {
	width: 56px;
	height: 56px;
	display: flex;
	align-items: center;
	justify-content: center;
	border-radius: 50%;
	background: rgba(0, 122, 255, 0.15);
	border: 1px solid rgba(0, 122, 255, 0.3);
	backdrop-filter: blur(20px);
	transition: all 0.2s cubic-bezier(0.25, 0.46, 0.45, 0.94);
	color: #007AFF;
}

.tvos-circle-button:hover {
	background: rgba(0, 122, 255, 0.25);
	border-color: rgba(0, 122, 255, 0.5);
	transform: scale(1.05);
}

.tvos-circle-button:focus {
	outline: none;
	background: rgba(0, 122, 255, 0.3);
	box-shadow: 0 0 20px rgba(0, 122, 255, 0.4);
}

/* Mobile header responsiveness */
@media (max-width: 768px) {
	header {
		padding: 16px 20px;
	}

	header h1 {
		font-size: 2.5rem;
	}

	.tvos-circle-button {
		width: 44px;
		height: 44px;
	}

	.tvos-circle-button i {
		font-size: 16px;
	}

	#providerView header h2 {
		font-size: 1.5rem;
		line-height: 1.2;
	}

	#providerView header p {
		font-size: 0.875rem;
	}
}

@media (max-width: 480px) {
	header {
		padding: 12px 16px;
	}

	header h1 {
		font-size: 2rem;
	}

	.tvos-circle-button {
		width: 40px;
		height: 40px;
	}

	.tvos-circle-button i {
		font-size: 14px;
	}

	#providerView header h2 {
		font-size: 1.25rem;
	}

	#providerView header p {
		font-size: 0.75rem;
	}

	.tvos-square-button {
		width: 36px;
		height: 36px;
	}
}

#guideProvidersContainer::-webkit-scrollbar {
	width: 6px;
}

#guideProvidersContainer::-webkit-scrollbar-track {
	background: rgba(255, 255, 255, 0.05);
	border-radius: 3px;
}

#guideProvidersContainer::-webkit-scrollbar-thumb {
	background: rgba(255, 255, 255, 0.2);
	border-radius: 3px;
}

#guideProvidersContainer::-webkit-scrollbar-thumb:hover {
	background: rgba(255, 255, 255, 0.3);
}

/* iOS-style Toast Notifications */
.animate-toast-slide-down {
	backdrop-filter: blur(20px);
	-webkit-backdrop-filter: blur(20px);
	border: 1px solid rgba(255, 255, 255, 0.1);
}

/* Toast notification hover effect for better interactivity */
.animate-toast-slide-down:hover {
	transform: translateX(-50%) scale(1.02);
	transition: transform 0.2s ease-out;
}

/* Responsive toast notifications */
@media (max-width: 768px) {
	.animate-toast-slide-down {
		max-width: calc(100vw - 32px);
		left: 50%;
		transform: translateX(-50%);
	}
}

@media (max-width: 480px) {
	.animate-toast-slide-down {
		max-width: calc(100vw - 24px);
		padding: 12px 16px;
		border-radius: 16px;
	}

	.animate-toast-slide-down .flex {
		gap: 12px;
	}

	.animate-toast-slide-down span {
		font-size: 14px;
	}
}

/* Provider view program guide scrollbar */
#providerView .flex-1::-webkit-scrollbar {
	width: 6px;
}

#providerView .flex-1::-webkit-scrollbar-track {
	background: rgba(255, 255, 255, 0.05);
	border-radius: 3px;
}

#providerView .flex-1::-webkit-scrollbar-thumb {
	background: rgba(255, 255, 255, 0.2);
	border-radius: 3px;
}

#providerView .flex-1::-webkit-scrollbar-thumb:hover {
	background: rgba(255, 255, 255, 0.3);
}

/* Drag and Drop Styles */
.draggable-favorite {
	transition: all 0.2s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

.draggable-favorite.dragging {
	opacity: 0.7;
	transform: scale(1.02);
	z-index: 1000;
}

.drag-handle {
	opacity: 0;
	transition: opacity 0.2s ease;
}

.draggable-favorite:hover .drag-handle,
.draggable-favorite:focus .drag-handle {
	opacity: 1;
}

.drag-handle:hover {
	cursor: grab;
	color: #007AFF !important;
}

.drag-handle:active {
	cursor: grabbing;
}

.drag-placeholder {
	margin: 0;
	animation: drag-placeholder-pulse 1s ease-in-out infinite alternate;
}

@keyframes drag-placeholder-pulse {
	0% {
		border-color: rgba(0, 122, 255, 0.3);
		background-color: rgba(0, 122, 255, 0.05);
	}

	100% {
		border-color: rgba(0, 122, 255, 0.6);
		background-color: rgba(0, 122, 255, 0.15);
	}
}

/* Touch feedback for mobile drag */
.draggable-favorite.touch-dragging {
	opacity: 0.8;
	transform: scale(1.05);
	z-index: 1000;
	position: relative;
	box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
}

/* Improve touch targets on mobile */
@media (max-width: 768px) {
	.drag-handle {
		opacity: 1;
		width: 32px;
		height: 32px;
		margin-right: 8px;
	}

	.draggable-favorite .drag-handle i {
		font-size: 16px;
	}
}

@media (max-width: 480px) {
	.drag-handle {
		width: 28px;
		height: 28px;
		margin-right: 6px;
	}

	.draggable-favorite .drag-handle i {
		font-size: 14px;
	}
}

/* Prevent text selection during drag */
.draggable-favorite * {
	user-select: none;
	-webkit-user-select: none;
	-moz-user-select: none;
	-ms-user-select: none;
}

/* Smooth transitions for reordering */
.draggable-favorite:not(.dragging):not(.touch-dragging) {
	transition: transform 0.3s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

/* EPG Mini-Guide Styles */
.epg-mini-guide-row {
	display: flex;
	gap: 4px;
	overflow-x: auto;
	overflow-y: hidden;
	padding: 4px 0;
	scroll-behavior: smooth;
	-webkit-overflow-scrolling: touch;
	margin-top: 8px;
	position: relative;
	min-height: 64px;
}

/* Hide scrollbar for the mini-guide row, but keep it scrollable */
.epg-mini-guide-row::-webkit-scrollbar {
	height: 3px;
}

.epg-mini-guide-row::-webkit-scrollbar-track {
	background: rgba(255, 255, 255, 0.05);
	border-radius: 2px;
}

.epg-mini-guide-row::-webkit-scrollbar-thumb {
	background: rgba(255, 255, 255, 0.2);
	border-radius: 2px;
}

.epg-mini-guide-row::-webkit-scrollbar-thumb:hover {
	background: rgba(255, 255, 255, 0.3);
}

.epg-program-card {
	height: 100%;
	border-right: 1px solid rgba(255, 255, 255, 0.1);
	padding: 6px 8px;
	background: linear-gradient(145deg, rgba(28, 28, 30, 0.8), rgba(44, 44, 46, 0.8));
	backdrop-filter: blur(10px);
	transition: all 0.2s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

.epg-program-card:hover {
	background: linear-gradient(145deg, rgba(44, 44, 46, 0.9), rgba(60, 60, 64, 0.9));
	transform: translateY(-1px);
	box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
}

.epg-program-card.current-program {
	background: linear-gradient(145deg, rgba(0, 122, 255, 0.15), rgba(0, 122, 255, 0.25));
	border-right-color: rgba(0, 122, 255, 0.3);
	box-shadow: 0 0 20px rgba(0, 122, 255, 0.1);
}

.epg-program-card.current-program:hover {
	background: linear-gradient(145deg, rgba(0, 122, 255, 0.2), rgba(0, 122, 255, 0.3));
	box-shadow: 0 4px 15px rgba(0, 122, 255, 0.2);
}

.epg-program-card.epg-gap {
	background: linear-gradient(145deg, rgba(28, 28, 30, 0.3), rgba(44, 44, 46, 0.3));
	border-right-color: rgba(255, 255, 255, 0.05);
	backdrop-filter: blur(5px);
}

.epg-program-card.epg-message {
	display: flex;
	align-items: center;
	justify-content: center;
	color: rgba(255, 255, 255, 0.5);
	font-style: italic;
	background-image: repeating-linear-gradient(45deg,
			rgba(44, 44, 46, 0.4) 0px,
			rgba(44, 44, 46, 0.4) 1px,
			rgba(28, 28, 30, 0.4) 1px,
			rgba(28, 28, 30, 0.4) 10px);
	backdrop-filter: blur(5px);
}

#emergencyBroadcastModal {
	z-index: 99999999999999;
}

.epg-program-content {
	height: 100%;
	display: flex;
	flex-direction: column;
	justify-content: space-between;
}

.epg-program-title {
	font-size: 0.75rem;
	font-weight: 600;
	line-height: 1.1;
	margin: 0;
	overflow: hidden;
	text-overflow: ellipsis;
	display: -webkit-box;
	-webkit-line-clamp: 2;
	-webkit-box-orient: vertical;
	max-height: 2.2em;
	white-space: normal;
	color: rgba(255, 255, 255, 0.95);
	flex: 1;
}

.epg-program-time {
	font-size: 0.625rem;
	font-weight: 500;
	margin: 2px 0;
	opacity: 0.8;
	line-height: 1;
	color: rgba(255, 255, 255, 0.8);
}

.epg-program-description {
	font-size: 0.625rem;
	line-height: 1.2;
	opacity: 0.7;
	margin-top: 2px;
	overflow: hidden;
	text-overflow: ellipsis;
	display: -webkit-box;
	-webkit-line-clamp: 1;
	-webkit-box-orient: vertical;
	max-height: 1.2em;
	color: rgba(255, 255, 255, 0.7);
}

.live-pulse-dot {
	min-width: 6px;
	min-height: 6px;
	width: 6px;
	height: 6px;
	flex: 0 0 6px;
	border-radius: 50%;
	animation: live-pulse 2s infinite;
	margin-left: 4px;
	margin-top: 2px;
	box-shadow: 0 0 8px rgba(0, 122, 255, 0.5);
	transform-origin: center;
}

#liveIndicator .live-pulse-dot {
	background: #FF3B30;
}

#liveIndicator .live-pulse-dot.vod-pulse {
	background: #007AFF;
}

@keyframes live-pulse {
	0% {
		transform: scale(1);
		opacity: 1;
	}

	50% {
		transform: scale(0.8);
		opacity: 0.5;
	}

	100% {
		transform: scale(1);
		opacity: 1;
	}
}

/* Update the title container to properly handle the dot */
.epg-program-content>div:first-child {
	display: flex;
	align-items: flex-start;
	gap: 4px;
	min-height: 8px;
	/* Ensure minimum height for dot */
}

/* Channel card styling */
.tvos-card {
	background: rgba(28, 28, 30, 0.6);
	backdrop-filter: blur(10px);
	border: 1px solid rgba(255, 255, 255, 0.1);
}

.channel-logo {
	width: 48px;
	height: 48px;
	background: linear-gradient(135deg, #2C2C2E, #3A3A3C);
	border: 1px solid rgba(255, 255, 255, 0.1);
	border-radius: 8px;
	display: flex;
	align-items: center;
	justify-content: center;
	font-size: 0.875rem;
	font-weight: bold;
	flex-shrink: 0;
	overflow: hidden;
}

.channel-logo img {
	width: 100%;
	height: 100%;
	object-fit: contain;
	padding: 6px;
	border: none;
	border-radius: 0;
}

/* Mobile responsive adjustments */
@media (max-width: 768px) {
	.epg-program-card {
		height: 56px;
		padding: 6px 8px;
		min-width: 90px !important;
	}

	.epg-program-title {
		font-size: 0.7rem;
		-webkit-line-clamp: 1;
		max-height: 1.1em;
	}

	.epg-program-time,
	.epg-program-duration,
	.epg-program-description {
		font-size: 0.6rem;
	}

	.live-pulse-dot {
		width: 5px;
		height: 5px;
		margin-left: 4px;
	}

	.channel-logo {
		width: 40px;
		height: 40px;
		font-size: 0.75rem;
		padding: 0;
		/* Remove padding from container */
	}

	.epg-mini-guide-row {
		min-height: 56px;
		gap: 3px;
	}
}

@media (max-width: 480px) {
	.epg-program-card {
		height: 48px;
		padding: 4px 6px;
		min-width: 80px !important;
	}

	.epg-program-title {
		font-size: 0.65rem;
	}

	.epg-program-time,
	.epg-program-duration,
	.epg-program-description {
		font-size: 0.55rem;
	}

	.epg-mini-guide-row {
		gap: 2px;
		padding: 4px 0;
		min-height: 48px;
	}

	.channel-logo {
		width: 36px;
		height: 36px;
		font-size: 0.7rem;
		padding: 0;
		/* Remove padding from container */
	}
}

.epg-program-item {
	display: inline-block;
	/* Align items in a row */
	vertical-align: top;
	transition: transform 0.15s ease-out, box-shadow 0.15s ease-out;
	/* Ensure consistent height if titles wrap differently */
	min-height: 50px;
	display: flex;
	flex-direction: column;
	justify-content: space-between;
}

.epg-program-item:hover {
	transform: translateY(-2px) scale(1.02);
	box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
}

.text-xxs {
	font-size: 0.625rem;
	/* 10px */
	line-height: 0.875rem;
	/* 14px */
}

/* Helper for truncating to 2 lines */
.truncate-2-lines {
	display: -webkit-box;
	-webkit-line-clamp: 2;
	-webkit-box-orient: vertical;
	overflow: hidden;
	text-overflow: ellipsis;
	max-height: calc(0.875rem * 2);
	/* line-height * 2 */
}

/* Custom scrollbar for EPG Modal description */
.custom-scrollbar::-webkit-scrollbar {
	width: 5px;
}

.custom-scrollbar::-webkit-scrollbar-track {
	background: rgba(255, 255, 255, 0.05);
	border-radius: 10px;
}

.custom-scrollbar::-webkit-scrollbar-thumb {
	background: rgba(255, 255, 255, 0.25);
	border-radius: 10px;
}

.custom-scrollbar::-webkit-scrollbar-thumb:hover {
	background: rgba(255, 255, 255, 0.4);
}

.custom-scrollbar {
	scrollbar-width: thin;
	/* Firefox */
	scrollbar-color: rgba(255, 255, 255, 0.25) rgba(255, 255, 255, 0.05);
	/* Firefox */
}

@keyframes slide-in-right {
	0% {
		transform: translateX(100%);
	}

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

@keyframes slide-out-right {
	0% {
		transform: translateX(0);
	}

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

.slide-in {
	animation: slide-in-right 0.3s cubic-bezier(0.25, 0.46, 0.45, 0.94) forwards;
}

.slide-out {
	animation: slide-out-right 0.3s cubic-bezier(0.25, 0.46, 0.45, 0.94) forwards;
}

/* TV Guide Grid Layout - Updated */
.tv-guide-grid-container {
	display: flex;
    width: 100%;
    position: relative;
    overflow: auto;
    contain: content;
}

.tv-guide-channel-info-column {
	position: sticky;
	left: 0;
	z-index: 5;
	width: 200px;
	flex-shrink: 0;
	background: rgba(28, 28, 30, 0.8);
	backdrop-filter: blur(20px);
	border-right: 1px solid rgba(255, 255, 255, 0.1);
	contain: layout style paint; /* Strict containment for performance */
}

.tv-guide-timeline-header-placeholder {
	height: 40px;
	background: rgba(28, 28, 30, 0.9);
	border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.tv-guide-scrollable-epg {
	flex-grow: 1;
	overflow-x: auto;
	overflow-y: hidden;
	scroll-snap-type: x mandatory;
	-webkit-overflow-scrolling: touch;
	background: rgba(28, 28, 30, 0.9);
	scrollbar-width: none;
	/* Firefox */
	-ms-overflow-style: none;
	/* IE and Edge */
}

.tv-guide-scrollable-epg::-webkit-scrollbar {
	display: none;
	/* Chrome, Safari and Opera */
}

.tv-guide-timeline {
	height: 40px;
	position: sticky;
	top: 0;
	z-index: 4;
	display: flex;
	align-items: center;
	background: rgba(28, 28, 30, 0.9);
	border-bottom: 1px solid rgba(255, 255, 255, 0.1);
	width: fit-content;
	min-width: 100%;
}

.tv-guide-program-rows {
	background: rgba(28, 28, 30, 0.4);
	width: fit-content;
	min-width: 100%;
	contain: layout style paint; /* Strict containment for performance */
}

.timeline-hour {
	flex-shrink: 0;
	width: 120px;
	/* 30 minutes = 120px */
	height: 100%;
	padding: 0 8px;
	font-size: 0.75rem;
	color: rgba(255, 255, 255, 0.7);
	display: flex;
	align-items: center;
	position: relative;
	scroll-snap-align: start;
}

.timeline-hour::after {
	content: '';
	position: absolute;
	right: 0;
	top: 8px;
	bottom: 8px;
	width: 1px;
	background: rgba(255, 255, 255, 0.1);
}

.channel-info-cell {
	padding: 8px;
	display: flex;
	align-items: center;
	gap: 12px;
	border-bottom: 1px solid rgba(255, 255, 255, 0.05);
	cursor: pointer;
	transition: background-color 0.2s ease;
	animation: none !important;
	will-change: transform; /* Hardware acceleration hint */
	transform: translateZ(0); /* Force GPU acceleration */
}

.channel-info-cell:hover {
	background: rgba(255, 255, 255, 0.05);
}

.channel-program-row {
	display: flex;
	border-bottom: 1px solid rgba(255, 255, 255, 0.05);
	background: rgba(28, 28, 30, 0.4);
}

.epg-program-card-wrapper {
	flex-shrink: 0;
	height: 100%;
	scroll-snap-align: start;
	cursor: pointer;
}

.epg-program-card {
	height: 100%;
	border-right: 1px solid rgba(255, 255, 255, 0.1);
	padding: 6px 8px;
	background: linear-gradient(145deg, rgba(28, 28, 30, 0.8), rgba(44, 44, 46, 0.8));
	backdrop-filter: blur(10px);
	transition: all 0.2s cubic-bezier(0.25, 0.46, 0.45, 0.94);
	contain: content;
	will-change: opacity, transform;
}

.epg-program-card:hover {
	background: linear-gradient(145deg, rgba(44, 44, 46, 0.9), rgba(60, 60, 64, 0.9));
	transform: translateY(-1px);
	box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
}

.epg-program-card.current-program {
	background: linear-gradient(145deg, rgba(0, 122, 255, 0.15), rgba(0, 122, 255, 0.25));
	border-right-color: rgba(0, 122, 255, 0.3);
	box-shadow: 0 0 20px rgba(0, 122, 255, 0.1);
}

.epg-program-card.current-program:hover {
	background: linear-gradient(145deg, rgba(0, 122, 255, 0.2), rgba(0, 122, 255, 0.3));
	box-shadow: 0 4px 15px rgba(0, 122, 255, 0.2);
}

.epg-program-card.epg-gap {
	background: linear-gradient(145deg, rgba(28, 28, 30, 0.3), rgba(44, 44, 46, 0.3));
	border-right-color: rgba(255, 255, 255, 0.05);
	backdrop-filter: blur(5px);
}

.epg-program-card.epg-message {
	display: flex;
	align-items: center;
	justify-content: center;
	color: rgba(255, 255, 255, 0.5);
	font-style: italic;
	background-image: repeating-linear-gradient(45deg,
			rgba(44, 44, 46, 0.4) 0px,
			rgba(44, 44, 46, 0.4) 1px,
			rgba(28, 28, 30, 0.4) 1px,
			rgba(28, 28, 30, 0.4) 10px);
	backdrop-filter: blur(5px);
}

.full-width-message {
	width: 100% !important;
}

/* Mobile Responsive Updates */
@media (max-width: 768px) {
	.tv-guide-channel-info-column {
		width: 150px;
	}

	.channel-info-cell {
		padding: 6px;
		gap: 8px;
	}

	/*.timeline-hour {
        width: 180px;
    }*/

	.epg-program-card {
		padding: 4px 6px;
	}
}

@media (max-width: 480px) {
	.channel-info-cell {
		padding: 4px;
		gap: 6px;
	}

	/*.timeline-hour {
        width: 150px;
        font-size: 0.65rem;
    }*/

	.epg-program-card {
		padding: 3px 4px;
	}
}

/* Remove any duplicate channel-logo styles from other sections */
.channel-info-cell .channel-logo,
.epg-modal-channel-logo {
	/* Only override specific properties if needed */
	width: 48px;
	height: 48px;
}

/* Mobile responsive adjustments */
@media (max-width: 768px) {
	.channel-logo {
		width: 40px;
		height: 40px;
		font-size: 0.75rem;
		padding: 0;
		/* Remove padding from container */
	}

	.channel-logo img {
		padding: 4px;
	}
}

@media (max-width: 480px) {
	.channel-logo {
		width: 36px;
		height: 36px;
		font-size: 0.7rem;
		padding: 0;
		/* Remove padding from container */
	}

	.channel-logo img {
		padding: 3px;
	}
}

/* Lockscreen Styles */
#lockscreen {
	background: linear-gradient(180deg, rgba(0,0,0,0.7) 0%, rgba(0,0,0,0.5) 100%);
	z-index: 10000;
	transition: opacity 0.5s ease-in-out;
    user-select: none;
    -webkit-user-select: none;
    -moz-user-select: none;
    -ms-user-select: none;
}

#lockscreen .text-tvos-text-secondary {
	color: rgba(255, 255, 255, 0.7);
}

/* Time display styling */
.time-display-container {
	position: relative;
	margin-bottom: 0.5rem;
}

#lockTime {
	text-shadow: 0 2px 15px rgba(0, 0, 0, 0.4);
	letter-spacing: 0.05em;
	line-height: 1;
	position: relative;
	transition: all 0.3s ease;
}

/* Animation for time updates */
@keyframes time-pulse {
	0% {
		opacity: 1;
		transform: scale(1);
	}

	50% {
		opacity: 0.9;
		transform: scale(1.02);
	}

	100% {
		opacity: 1;
		transform: scale(1);
	}
}

.time-update {
	animation: time-pulse 0.5s ease;
}

#lockTime::after {
	content: '';
	display: block;
	width: 100%;
	height: 2px;
	background: linear-gradient(90deg, rgba(255, 255, 255, 0) 0%, rgba(255, 255, 255, 0.3) 50%, rgba(255, 255, 255, 0) 100%);
	position: absolute;
	bottom: -10px;
	left: 0;
	border-radius: 2px;
}

#lockDate {
	text-shadow: 0 2px 10px rgba(0, 0, 0, 0.3);
	letter-spacing: 0.05em;
	opacity: 0.8;
}

/* AM/PM indicator styling */
#ampmIndicator {
	height: 4rem;
	text-shadow: 0 2px 8px rgba(0, 0, 0, 0.3);
	margin-bottom: 1rem;
	position: relative;
	margin-left: 1rem;
	opacity: 0.7;
	font-size: 1.5rem;
	margin-top: 0.5rem;
	transition: all 0.3s ease;
}

.ampm-top,
.ampm-bottom {
	line-height: 1;
	letter-spacing: 0;
	font-weight: 300;
	padding-left: 3px;
	transition: all 0.3s ease;
	position: relative;
}

.active-period {
	opacity: 1;
	font-weight: 400;
	text-shadow: 0 0 10px rgba(255, 255, 255, 0.4);
}

.am-active {
	color: rgba(255, 255, 255, 0.95);
	opacity: 0.85;
}

.pm-active {
	color: rgba(255, 255, 255, 0.95);
	opacity: 0.85;
}

/* Add a subtle vertical separator between time and AM/PM */
#ampmIndicator::before {
	content: '';
	display: block;
	width: 1px;
	height: 60%;
	background: linear-gradient(to bottom, rgba(255, 255, 255, 0) 0%, rgba(255, 255, 255, 0.4) 50%, rgba(255, 255, 255, 0) 100%);
	position: absolute;
	left: -8px;
	top: 20%;
}

@media (max-width: 768px) {
	#lockTime {
		font-size: 5rem;
	}

	#ampmIndicator {
		height: 3rem;
		font-size: 1.2rem;
		margin-top: 0.3rem;
	}

	#ampmIndicator::before {
		height: 50%;
		left: -6px;
	}

	#lockTime::after {
		bottom: -8px;
		height: 1px;
	}
}

@media (max-width: 480px) {
	#lockTime {
		font-size: 3.5rem;
	}

	#ampmIndicator {
		height: 2.2rem;
		font-size: 1rem;
		margin-top: 0.2rem;
	}

	#ampmIndicator::before {
		height: 40%;
		left: -5px;
	}

	#lockTime::after {
		bottom: -6px;
		height: 1px;
	}
}

/* Slide to unlock */
#slideTrack {
	background: rgba(255, 255, 255, 0.1);
	transition: all 0.3s ease;
}

#slideThumb {
	transition: all 0.3s cubic-bezier(0.25, 0.46, 0.45, 0.94);
	color: #007AFF;
	background: rgba(255, 255, 255, 0.8);
	backdrop-filter: blur(10px);
	-webkit-backdrop-filter: blur(10px);
}

#slideText {
	transition: opacity 0.3s ease;
}

#slideThumb:active {
	animation: none;
	transform: scale(0.95);
}

/* Weather widget styles */
#weatherWidget {
    text-shadow: 0 1px 4px rgba(0, 0, 0, 0.1);
    margin-top: 1rem;
    transition: all 0.3s ease;
}

#weatherIcon {
    color: white;
    transform: translateZ(0);
    will-change: transform;
    animation: float 3s ease-in-out infinite;
    font-size: 1.5rem;
    margin-right: 0.5rem;
}

#weatherTemp {
    text-shadow: 0 1px 6px rgba(0, 0, 0, 0.2);
    font-size: 1.25rem;
}

#weatherDesc,
#weatherHiLow,
#weatherFeelsLike {
    text-shadow: 0 1px 3px rgba(0, 0, 0, 0.15);
    font-size: 0.875rem;
    color: rgba(255, 255, 255, 0.8);
}

#requestLocationBtn {
    background: rgba(0, 122, 255, 0.15);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    transition: all 0.2s ease;
    padding: 0.5rem 1rem;
    font-size: 0.875rem;
}

#requestLocationBtn:hover {
    background: rgba(0, 122, 255, 0.25);
    transform: translateY(-1px);
}

#requestLocationBtn:active {
    transform: translateY(0);
}

/* Weather widget responsive styles */
@media (max-width: 768px) {
    #weatherWidget {
        margin-top: 0.75rem;
    }
    
    #weatherIcon {
        width: 2rem !important;
        height: 2rem !important;
        font-size: 1.25rem !important;
    }
    
    #weatherTemp {
        font-size: 1.125rem !important;
    }
    
    #weatherDesc {
        font-size: 0.75rem !important;
    }
    
    #weatherHiLow,
    #weatherFeelsLike {
        font-size: 0.7rem !important;
    }
}

@media (max-width: 480px) {
    #weatherWidget {
        margin-top: 0.5rem;
    }
    
    #weatherIcon {
        width: 1.75rem !important;
        height: 1.75rem !important;
        font-size: 1rem !important;
    }
    
    #weatherTemp {
        font-size: 1rem !important;
    }
    
    #weatherDesc {
        font-size: 0.7rem !important;
    }
    
    #weatherHiLow,
    #weatherFeelsLike {
        font-size: 0.65rem !important;
    }
}

/* Add floating animation for weather icon */
@keyframes float {
    0% {
        transform: translateY(0);
    }
    50% {
        transform: translateY(-5px);
    }
    100% {
        transform: translateY(0);
    }
}

/* Unlock transition */
.unlock-transition {
	animation: unlock-slide 0.8s cubic-bezier(0.19, 1, 0.22, 1) forwards;
}

@keyframes unlock-slide {
	0% {
		transform: translateY(0);
		opacity: 1;
	}

	100% {
		transform: translateY(-100%);
		opacity: 0;
	}
}

/* Responsive styles for lockscreen */
@media (max-width: 768px) {
	#lockTime {
		font-size: 5rem;
	}

	#lockDate {
		font-size: 1.5rem;
	}

	#slideTrack {
		height: 3.5rem;
	}

	#slideThumb {
		width: 3.5rem;
	}

	#slideText {
		font-size: 1.2rem;
	}
}

@media (max-width: 480px) {
	#lockTime {
		font-size: 3.5rem;
	}

	#lockDate {
		font-size: 1.25rem;
	}

	#slideTrack {
		height: 3rem;
	}

	#slideThumb {
		width: 3rem;
	}

	#slideText {
		font-size: 1rem;
	}

	#weatherTemp {
		font-size: 2.5rem;
	}
}

.loading-shimmer {
	background: linear-gradient(90deg,
			rgba(255, 255, 255, 0.05) 25%,
			rgba(255, 255, 255, 0.1) 50%,
			rgba(255, 255, 255, 0.05) 75%);
	background-size: 200% 100%;
	animation: shimmer 1.5s infinite;
}

@keyframes shimmer {
	0% {
		background-position: -200% 0;
	}

	100% {
		background-position: 200% 0;
	}
}

.epg-program-card-wrapper.loading-state {
	min-width: 360px;
	width: 360px;
}

.epg-program-card-wrapper.loading-state .epg-program-card {
	background: rgba(255, 255, 255, 0.05);
	height: 100%;
	display: flex;
	align-items: center;
	padding: 0.75rem;
}

/* Placeholder styles for IntersectionObserver implementation */
.channel-info-placeholder,
.program-row-placeholder {
	min-height: 72px;
	position: relative;
}

/* Remove animation when appending channel elements to improve performance */
.channel-info-cell,
.channel-program-row {
	animation: none !important;
	will-change: transform; /* Hardware acceleration hint */
	transform: translateZ(0); /* Force GPU acceleration */
}

/* Optimize rendering performance */
.tv-guide-grid-container {
	contain: content; /* Optimization hint for browsers */
}

.tv-guide-channel-info-column,
.tv-guide-program-rows {
	contain: layout style paint; /* Strict containment for performance */
}

/* Optimize EPG rendering */
.epg-program-card {
	contain: content;
	will-change: opacity, transform;
}

/* Loading styles for placeholder rows */
.channel-info-placeholder:empty,
.program-row-placeholder:empty {
	background: linear-gradient(90deg, 
		rgba(44, 44, 46, 0.3) 0%, 
		rgba(44, 44, 46, 0.5) 50%, 
		rgba(44, 44, 46, 0.3) 100%);
	background-size: 200% 100%;
	animation: loading-shimmer 1.5s infinite;
	border-radius: 0.75rem;
	margin: 0.25rem;
}

@keyframes loading-shimmer {
	0% {
		background-position: 200% 0;
	}
	100% {
		background-position: -200% 0;
	}
}

/* Search highlight styles */
.search-highlight {
    background-color: rgba(255, 255, 0, 0.3); /* Yellow highlight */
    color: #FFFFFF; /* Ensure text remains white or primary color */
    border-radius: 3px;
    padding: 0 2px;
}

.channel-name-highlight {
    background-color: rgba(0, 122, 255, 0.3); /* Blue highlight for channel names */
    color: #FFFFFF;
    border-radius: 3px;
    padding: 0 2px;
}

.program-card-highlighted {
    border: 2px solid rgba(255, 255, 0, 0.7) !important; /* Yellow border for the whole card */
    box-shadow: 0 0 15px rgba(255, 255, 0, 0.4) !important; /* Yellow glow */
}

.program-card-highlighted .epg-program-title .search-highlight {
    background-color: rgba(255, 255, 0, 0.5); /* Slightly stronger highlight for title within highlighted card */
}

/* Floating TV Assistant Button */
.tvos-floating-button {
    box-shadow: 0 10px 25px rgba(0, 122, 255, 0.5);
    transition: all 0.3s cubic-bezier(0.25, 0.46, 0.45, 0.94);
    transform-origin: center;
}

.tvos-floating-button:hover {
    transform: scale(1.1);
    box-shadow: 0 15px 35px rgba(0, 122, 255, 0.6);
}

.tvos-floating-button:active {
    transform: scale(0.95);
}

#tvAssistantModal {
	z-index: 9999;
}

/* Mobile responsiveness for floating button */
@media (max-width: 768px) {
    .tvos-floating-button {
        width: 56px !important;
        height: 56px !important;
    }
    
    .tvos-floating-button i {
        font-size: 1.5rem !important;
    }
}

@media (max-width: 480px) {
    .tvos-floating-button {
        width: 48px !important;
        height: 48px !important;
    }
    
    .tvos-floating-button i {
        font-size: 1.2rem !important;
    }
}

/* CRT TV Animation Effects */
#crtTvOverlay {
    background-color: black;
    overflow: hidden;
}

#crtTvLine {
    height: 2px;
    top: 50%;
    transform: translateY(-50%);
    will-change: height, opacity;
}

/* CRT TV Turn On Animation */
@keyframes crtTvTurnOn {
    0% {
        height: 2px;
        opacity: 0.9;
    }
    10% {
        height: 2px;
        opacity: 1;
    }
    25% {
        height: 5vh;
        opacity: 1;
    }
    50% {
        height: 30vh;
        opacity: 0.8;
    }
    75% {
        height: 80vh;
        opacity: 0.7;
    }
    90% {
        height: 100vh;
        opacity: 0.3;
    }
    100% {
        height: 100vh;
        opacity: 0;
    }
}

.crt-turn-on {
    animation: crtTvTurnOn 0.6s cubic-bezier(0.23, 1, 0.32, 1) forwards;
}

/* CRT TV Turn Off Animation */
@keyframes crtTvTurnOff {
    0% {
        height: 100vh;
        opacity: 0;
    }
    10% {
        height: 100vh;
        opacity: 0.3;
    }
    25% {
        height: 80vh;
        opacity: 0.7;
    }
    50% {
        height: 30vh;
        opacity: 0.8;
    }
    75% {
        height: 5vh;
        opacity: 1;
    }
    90% {
        height: 2px;
        opacity: 1;
    }
    100% {
        height: 2px;
        opacity: 0;
    }
}

.crt-turn-off {
    animation: crtTvTurnOff 0.6s cubic-bezier(0.23, 1, 0.32, 1) forwards;
}

/* Add noise effect to simulate CRT static */
@keyframes crtNoise {
    0%, 100% { background-position: 0 0; }
    10% { background-position: -5% -10%; }
    20% { background-position: -15% 5%; }
    30% { background-position: 7% -25%; }
    40% { background-position: 20% 25%; }
    50% { background-position: -25% 10%; }
    60% { background-position: 15% 5%; }
    70% { background-position: 0% 15%; }
    80% { background-position: 25% 35%; }
    90% { background-position: -10% 10%; }
}

.crt-noise::before {
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-image: url('data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAGQAAABkCAYAAABw4pVUAAAACXBIWXMAAAsTAAALEwEAmpwYAAAFHGlUWHRYTUw6Y29tLmFkb2JlLnhtcAAAAAAAPD94cGFja2V0IGJlZ2luPSLvu78iIGlkPSJXNU0wTXBDZWhpSHpyZVN6TlRjemtjOWQiPz4gPHg6eG1wbWV0YSB4bWxuczp4PSJhZG9iZTpuczptZXRhLyIgeDp4bXB0az0iQWRvYmUgWE1QIENvcmUgNS42LWMxNDUgNzkuMTYzNDk5LCAyMDE4LzA4LzEzLTE2OjQwOjIyICAgICAgICAiPiA8cmRmOlJERiB4bWxuczpyZGY9Imh0dHA6Ly93d3cudzMub3JnLzE5OTkvMDIvMjItcmRmLXN5bnRheC1ucyMiPiA8cmRmOkRlc2NyaXB0aW9uIHJkZjphYm91dD0iIiB4bWxuczp4bXA9Imh0dHA6Ly9ucy5hZG9iZS5jb20veGFwLzEuMC8iIHhtbG5zOmRjPSJodHRwOi8vcHVybC5vcmcvZGMvZWxlbWVudH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C8bnMgXMx4wbCZhNRYhYXlTpHRXKrJh4jUXA/xZO0m6vTT2IHY97iOZxSCRdkjc1gO9PH6QHoXhZJ1PvHIRCTlgbXoibTnYD4JaU/rvLzYlbjXJxxKIq8dCcdN5+xfuFZDrxvVeKF0Kln1Tt8lTumuB3j1Wn7OOUPe2qV8yNXEvF9yK+wte6BuyoFg1mkhKw3VcQ7tZeQ1w64G9VlqgxewPpLlVHPuDdlfnJEzGCQ9UYNpFLdCTOx+UGF1SvVcUwOu76SN5AQ+AhA86FppzNYRkoxNi1Gsr9K2U18+7VSsqo0DESEZDYqgvZO5ff1E76W3+Vc/O+H1anXHZBNVzPEoO/jqtbsV++xV5KBnFRpzz+Ak9BF+CUmE+ej/j5C+Ce/fFmtBuJwOBwOh8PhcDgcDofD4XA4HA6Hw+FwOBwOh8PhcDgcDoejQvE/uDWVj4QN8nYAAAAASUVORK5CYII=');
    background-size: 100px 100px;
    opacity: 0.12;
    pointer-events: none;
    animation: crtNoise 1s steps(2) infinite;
}

/* Apps Menu Full Screen Styling */
#appsMenu {
    transition: transform 0.3s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

#appsMenu.opening {
    animation: appsMenuSlideUp 0.3s cubic-bezier(0.25, 0.46, 0.45, 0.94) forwards;
}

#appsMenu.closing {
    animation: appsMenuSlideDown 0.3s cubic-bezier(0.25, 0.46, 0.45, 0.94) forwards;
}

@keyframes appsMenuSlideUp {
    0% {
        transform: translateY(100%);
        opacity: 0;
    }
    100% {
        transform: translateY(0);
        opacity: 1;
    }
}

@keyframes appsMenuSlideDown {
    0% {
        transform: translateY(0);
        opacity: 1;
    }
    100% {
        transform: translateY(100%);
        opacity: 0;
    }
}

#appsMenu .glass-effect {
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
}

.app-icon-btn {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 0.75rem;
    padding: 1.25rem;
    border-radius: 1rem;
    transition: all 0.2s ease;
    cursor: pointer;
    background: transparent;
    border: none;
}

.app-icon-btn i {
	font-size: 30px;
}

.app-icon-btn:hover {
    background: rgba(255, 255, 255, 0.05);
    transform: translateY(-2px);
}

.app-icon-btn:active {
    transform: translateY(0);
}

.app-icon-btn .w-16 {
    transition: transform 0.2s ease;
}

.app-icon-btn:hover .w-16 {
    transform: scale(1.1);
}

.app-icon-btn span {
    font-size: 0.875rem;
    font-weight: 500;
    text-align: center;
    transition: color 0.2s ease;
}

/* Responsive adjustments for app icons */
@media (max-width: 480px) {
    #appsList {
        gap: 1.5rem !important;
        grid-template-columns: repeat(2, 1fr) !important;
    }
    
    .app-icon-btn {
        padding: 1.5rem;
        gap: 0.75rem;
    }
    
    .app-icon-btn .w-16 {
        width: 4rem !important;
        height: 4rem !important;
    }
    
    .app-icon-btn span {
        font-size: 0.875rem;
    }
}

@media (min-width: 481px) and (max-width: 640px) {
    #appsList {
        gap: 1rem !important;
        grid-template-columns: repeat(3, 1fr) !important;
    }
    
    .app-icon-btn {
        padding: 1rem;
        gap: 0.5rem;
    }
    
    .app-icon-btn .w-16 {
        width: 3.5rem !important;
        height: 3.5rem !important;
    }
    
    .app-icon-btn span {
        font-size: 0.75rem;
    }
}

@media (min-width: 641px) and (max-width: 768px) {
    #appsList {
        grid-template-columns: repeat(4, 1fr) !important;
    }
}

#appNavBar {
	padding-left: 0.25rem;
    padding-right: 0.25rem;
}

/* Remove old slide-to-unlock styles */
/* Swipe Up Indicator */
#swipeUpIndicator {
    transition: all 0.3s ease;
    opacity: 0.8;
    cursor: pointer;
}

#swipeUpIndicator i {
    display: block;
    animation: float-up 2s ease-in-out infinite;
}

#swipeText {
    transition: opacity 0.3s ease;
}

@keyframes float-up {
    0%, 100% {
        transform: translateY(0);
        opacity: 0.6;
    }
    50% {
        transform: translateY(-5px);
        opacity: 1;
    }
}

/* Unlock transition - updated for swipe up */
.unlock-transition {
    animation: unlock-slide-up 0.8s cubic-bezier(0.19, 1, 0.22, 1) forwards;
    will-change: transform, opacity;
}

@keyframes unlock-slide-up {
    0% {
        transform: translateY(0);
        opacity: 1;
    }
    100% {
        transform: translateY(-100%);
        opacity: 0;
    }
}

/* Responsive styles for swipe indicator */
@media (max-width: 768px) {
    #swipeUpIndicator {
        padding: 0.75rem;
    }
    
    #swipeUpIndicator i {
        font-size: 1rem;
    }
    
    #swipeText {
        font-size: 0.75rem;
    }
}

@media (max-width: 480px) {
    #swipeUpIndicator {
        padding: 0.5rem;
    }
    
    #swipeUpIndicator i {
        font-size: 0.875rem;
    }
    
    #swipeText {
        font-size: 0.7rem;
    }
}

/* Video Annotations */
#videoAnnotations {
    transition: opacity 0.3s ease-in-out;
}

#videoAnnotations, #annotationsTimeline {
	bottom: calc(132px + 50px);
}

.annotation {
	animation: fadeIn 0.3s ease-in-out;
    margin: 0 auto;
    background: rgba(0, 0, 0, 0.75);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.1);
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
    padding: 10px;
    border-radius: 12px;
}

.annotation.hidden {
    display: none;
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Video Annotations - Updated Styles */
#videoAnnotations {
    transition: opacity 0.3s ease-in-out;
    bottom: calc(132px + 50px);
    display: flex;
    justify-content: center;
}

.annotation {
    animation: fadeIn 0.3s ease-in-out;
    max-width: 80%;
    background: rgba(0, 0, 0, 0.65);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.15);
    box-shadow: 0 8px 16px rgba(0, 0, 0, 0.15);
    padding: 12px 16px;
    border-radius: 16px;
    transform-origin: center bottom;
    display: flex;
    flex-direction: column;
}

.annotation-content {
    margin-bottom: 8px;
    font-size: 0.95rem;
    line-height: 1.4;
    letter-spacing: 0.01em;
}

.annotation-actions {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: 4px;
}

.annotation-actions button {
    background: none;
    border: none;
    color: rgba(255, 255, 255, 0.7);
    padding: 4px 8px;
    cursor: pointer;
    font-size: 12px;
    transition: color 0.2s ease;
}

.annotation-actions button:hover {
    color: rgba(255, 255, 255, 1);
}

.annotation-actions button.toggle-timeline {
    display: flex;
    align-items: center;
}

.annotation-actions button.toggle-timeline i {
    margin-right: 4px;
}

.annotation.hidden {
    display: none;
}

/* Annotations Timeline */
#annotationsTimeline {
    background: rgba(0, 0, 0, 0.75);
    backdrop-filter: blur(15px);
    border: 1px solid rgba(255, 255, 255, 0.1);
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.2);
}

.timeline-marker {
    display: flex;
    align-items: center;
    padding: 8px 12px;
    margin-bottom: 6px;
    border-radius: 10px;
    background: rgba(255, 255, 255, 0.05);
    cursor: pointer;
    transition: background 0.2s ease, transform 0.1s ease;
}

.timeline-marker:hover {
    background: rgba(255, 255, 255, 0.1);
}

.timeline-marker.active {
    background: rgba(0, 122, 255, 0.2);
    border-left: 3px solid #007AFF;
}

.timeline-marker-time {
    font-family: monospace;
    font-size: 0.8rem;
    color: rgba(255, 255, 255, 0.7);
    padding: 2px 6px;
    background: rgba(0, 0, 0, 0.3);
    border-radius: 4px;
    margin-right: 12px;
    min-width: 50px;
    text-align: center;
}

.timeline-marker-text {
    font-size: 0.85rem;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    flex: 1;
}

/* Timeline show/hide animation */
@keyframes slideUpTimeline {
    from {
        transform: translateY(20px);
        opacity: 0;
    }
    to {
        transform: translateY(0);
        opacity: 1;
    }
}

.show-timeline {
    display: block !important;
    animation: slideUpTimeline 0.3s forwards;
}

/* Responsive styles for annotations */
@media (max-width: 768px) {
    .annotation {
        max-width: 90%;
        padding: 10px 14px;
    }
    
    .annotation-content {
        font-size: 0.9rem;
    }
    
    .annotation-actions button {
        font-size: 11px;
        padding: 3px 6px;
    }
    
    .timeline-marker {
        padding: 6px 10px;
    }
    
    .timeline-marker-time {
        font-size: 0.75rem;
        min-width: 45px;
    }
    
    .timeline-marker-text {
        font-size: 0.8rem;
    }
}

@media (max-width: 480px) {
    .annotation {
        max-width: 95%;
        padding: 8px 12px;
    }
    
    .annotation-content {
        font-size: 0.85rem;
    }
    
    .annotation-actions button {
        font-size: 10px;
        padding: 3px 5px;
    }
    
    .timeline-marker {
        padding: 5px 8px;
        margin-bottom: 4px;
    }
    
    .timeline-marker-time {
        font-size: 0.7rem;
        min-width: 40px;
        margin-right: 8px;
    }
    
    .timeline-marker-text {
        font-size: 0.75rem;
    }
}

/* Video progress bar for VOD content */
#vodProgressContainer {
    width: 100%;
    margin-bottom: 12px;
}

#progressBarContainer {
    position: relative;
    background: rgba(255, 255, 255, 0.1);
    overflow: hidden;
    cursor: pointer;
    border-radius: 999px;
    transition: height 0.2s ease;
}

#progressBar {
    transition: width 0.1s linear;
}

#progressBar:hover {
    background-color: #32ade1;
}

/* Remove hover height change */

#vodProgressContainer .text-xs {
    font-size: 0.7rem;
    opacity: 0.8;
    margin-top: 4px;
}

/* Progress bar responsive styles */
@media (max-width: 768px) {
    #vodProgressContainer {
        margin-bottom: 8px;
    }
    
    #vodProgressContainer .text-xs {
        font-size: 0.65rem;
    }
}

@media (max-width: 480px) {
    #vodProgressContainer {
        margin-bottom: 6px;
    }
    
    #vodProgressContainer .text-xs {
        font-size: 0.6rem;
    }
}

/* Loading spinner for video buffering */
.loading-spinner {
    border: 3px solid rgba(255, 255, 255, 0.2);
    border-radius: 50%;
    border-top: 3px solid #007AFF;
    animation: spinner-rotate 1s linear infinite;
    transform-origin: center;
}

@keyframes spinner-rotate {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}



@media (max-width: 480px) {
    .annotation {
        max-width: 95%;
        padding: 8px 12px;
    }
    
    .annotation-content {
        font-size: 0.85rem;
    }
    
    .annotation-actions button {
        font-size: 10px;
        padding: 3px 5px;
    }
    
    .timeline-marker {
        padding: 5px 8px;
        margin-bottom: 4px;
    }
    
    .timeline-marker-time {
        font-size: 0.7rem;
        min-width: 40px;
        margin-right: 8px;
    }
    
    .timeline-marker-text {
        font-size: 0.75rem;
    }
    

}

/* Improve annotation button touch targets */
.annotation-actions button {
    padding: 4px 12px;
    min-height: 36px;
    position: relative;
}

/* Add active state for touch interaction */
.annotation-actions button:active,
.timeline-marker:active,
#closeAnnotationsTimelineBtn:active {
    transform: scale(0.95);
    opacity: 0.9;
}

/* Larger touch targets on mobile */
@media (max-width: 768px) {
    .annotation-actions button {
        padding: 6px 14px;
        min-height: 40px;
    }
    
    .timeline-marker {
        padding: 10px 12px;
    }
}

/* Ensure proper hit area for close button */
#closeAnnotationsTimelineBtn {
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
}

@media (max-width: 480px) {
    #closeAnnotationsTimelineBtn {
        width: 36px;
        height: 36px;
    }
}

/* ===== Status Bar adjustments for content overlap ===== */
.statusbar-visible #app {
    padding-top: 62px;
}

#statusBar {
    transform: translateY(-100%);
    transition: transform 0.3s ease;
}
.statusbar-visible #statusBar {
    transform: translateY(0);
}

.statusbar-visible #providerView,
.statusbar-visible #tvGuideModal,
.statusbar-visible #tvAssistantModal,
.statusbar-visible #searchModal,
.statusbar-visible #editProviderModal,
.statusbar-visible #providerModal {
    top: 62px;
}

/* Smooth slide of content when status bar shows/hides */
#app {
    transition: padding-top 0.3s ease;
}
#providerView,
#tvGuideModal,
#tvAssistantModal,
#searchModal,
#editProviderModal,
#providerModal {
    transition: top 0.3s ease;
}