/* General Colors */
.bg-p {
	background: #343a40;
}

body {
	background: ghostwhite;
}

/* Divider styles for flex containers */
.divider:after,
.divider:before {
	content: "";
	flex: 1;
	height: 1px;
	background: #eee;
}

/* Custom height utility */
.h-custom {
	height: calc(100% - 73px);
}

@media (max-width: 450px) {
	.h-custom {
		height: 100%;
	}
}

/* Sidebar Responsive */
@media only screen and (max-width: 600px) {
	.sidebar {
		display: none;
		width: 80% !important;
		background: #e2e2e2;
		height: 100vh;
		position: fixed;
		padding-top: 20px;
		top: 0;
		left: 0;
		z-index: 1050;
		box-shadow: 2px 0 10px rgba(0, 0, 0, 0.3);
	}

	.content {
		margin-left: 0% !important;
	}
}

/* Sidebar styles */
.sidebar {
	width: 18%;
	background-color: white;
	height: 100%;
	position: fixed;
	top: 0;
	margin-top: 55px;
	padding: 45px 20px 0 18px;
	overflow-y: auto;
}

.sidebar a {
	display: block;
	width: 100%;
	padding: 10px 25px;
	text-decoration: none;
	color: black;
}

.sidebar a:hover,
.sidebar a.active {
	background: #343a40;
	color: white;
	border-radius: 8px;
	padding: 8px 12px;
	display: block;
}

.sidebar .CrossBtn {
	position: absolute;
	top: 0;
	right: 35px;
	font-size: 36px;
	cursor: pointer;
}

/* Content Area */
.content {
	margin-left: 20%;
	margin-right: 2%;
	margin-top: 75px;
	margin-bottom: 2%;
	padding-bottom: 5%;
	background-color: white;
	overflow-y: auto;
	position: relative;
	z-index: 1;
}

@media (max-width: 768px) {
	.content {
		margin-left: 0;
		margin-top: 100px;
	}
}

/* Card and Table Styling */
.card {
	background: #343a40;
	color: white;
	border-radius: 8px;
	padding: 8px 12px;
}

thead {
	background: #343a40;
	color: white;
}

/* Image Preview and Thumbnails */
.img-thumbnail {
	border: 2px solid #ddd;
	border-radius: 5px;
	transition: transform 0.2s;
}

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

#preview {
	padding: 10px;
}

/* Image Gallery */
.image-gallery {
	display: flex;
	flex-wrap: wrap;
	gap: 15px;
	max-height: 400px;
	/* Fixed height for scrolling */
	overflow-y: auto;
	/* Enables vertical scroll */
	overflow-x: hidden;
	padding: 10px;
	border: 1px solid #ccc;
	border-radius: 8px;
	background: #f8f8f8;
	scroll-behavior: smooth;
	max-height: 800px;
}


/* Image Card */
.image-card {
	position: relative;
	width: 120px;
	height: 100px;
	overflow: hidden;
	border-radius: 8px;
	box-shadow: 0 2px 6px rgba(0, 0, 0, 0.1);
}

/* Image inside card */
.image-card img {
	width: 100%;
	height: 100%;
	object-fit: cover;
	display: block;
	border-radius: 8px;
}

/* Delete Button */
.delete-button {
	position: absolute;
	top: 5px;
	right: 5px;
	background-color: #dc3545;
	color: white;
	border: none;
	border-radius: 50%;
	width: 30px;
	height: 30px;
	display: flex;
	justify-content: center;
	align-items: center;
	cursor: pointer;
	transition: background-color 0.2s;
}

.delete-button:hover {
	background-color: #343a40;
}

.delete-button i {
	color: white;
}

.row {
	display: flex;
	align-items: stretch;
}

.col-md-8,
.col-md-4 {
	display: flex;
	flex-direction: column;
}

#toast {
	visibility: hidden;
	min-width: 120px;
	background-color: #333;
	color: #fff;
	text-align: center;
	border-radius: 4px;
	padding: 10px;
	position: fixed;
	bottom: 30px;
	left: 50%;
	transform: translateX(-50%);
	z-index: 1000;
	opacity: 0;
	transition: opacity 0.5s ease-in-out;
}

#toast.show {
	visibility: visible;
	opacity: 1;
}

td a {
	text-decoration: none;
	color: inherit;
}