html, body {
	width:  100%;
	height: 100%;
	margin: 0px;
	padding: 0px;
	overflow: hidden;            /* key: body never scrolls */
	font-family: Arial, Helvetica, sans-serif;
	background-color: #444;
	color: #FFF;
}
/* ────────────────────────────────────────────────
   Divisions div
───────────────────────────────────────────────── */
div.clsContainer {
	margin: auto;
	padding: 0px;
	width: 100%;
	display: flex;
	flex-direction: column;
	height: 100vh;               /* full viewport height */
	min-height: 100vh;
}
.clsMenu {
	text-align: center;
	flex-shrink: 0;              /* never shrinks */
}
.clsThumbs {
	flex: 1 1 auto;              /* grows to fill remaining space */
	overflow-y: auto;            /* scrollbar appears only here when needed */
	overflow-x: hidden;
	box-sizing: border-box;
}
.clsThumbDiv {
	overflow: hidden;
	display: inline-block;
	margin: 0px;
	padding: 0px;
	color: #CCC;
	background-color: #111;
	text-align: left;
	font-size: 15px;
	width: 16.65%;
}
.clsThumbDiv:hover {
	color: #000;
	background-color: #DFF;
}
.clsThumbDiv:active {
	color: #444;
	background-color: #666;
}
@media screen and (max-width: 2100px) {
	.clsThumbDiv {
		width: 20%;
	}
}
@media screen and (max-width: 1750px) {
	.clsThumbDiv {
		width: 25%;
	}
}
@media screen and (max-width: 1400px) {
	.clsThumbDiv {
		width: 33.3%;
	}
}
@media screen and (max-width: 1050px) {
	.clsThumbDiv {
		width: 50%;
	}
}
@media screen and (max-width: 700px) {
	.clsThumbDiv {
		width: 100%;
	}
}
/* ────────────────────────────────────────────────
   Headings h2
───────────────────────────────────────────────── */
.clsTitle {
	background-color: #5EB5DB;
	color: #0E3331;
	text-align: center;
	padding: 3px;
	margin: auto;
	width: 98%;
	margin: auto;
	flex-shrink: 0;              /* never shrinks */
}
/* ────────────────────────────────────────────────
   Images img
───────────────────────────────────────────────── */
.clsThumb {
	float: left;
	margin: 2px;
	padding: 0px;
	padding-left:  0px;
	padding-right: 2px;
	opacity: 0.85;
}
.clsThumb:hover {
	opacity: 1.0;
}
.clsThumb:active {
	opacity: 0.2;
}
/* ────────────────────────────────────────────────
   Buttons
───────────────────────────────────────────────── */
button {
	background-color: #F7F2ED;
	color: #2b161a;
	padding: 3px 15px; 
	font-size: 16px; 
	text-decoration: none;
	border: 2px solid #000;
	border-radius: 5px;
	display: inline; 
}
button:hover {
	background-color: #5EB5DB;
	color: #0E3331;
	font-weight: bold;
}
button.active {
	background-color: #0E3331;
	color: #5EB5DB;
}
/* ────────────────────────────────────────────────
   Footer
───────────────────────────────────────────────── */
.clsFooter {
	background-color: #3F1E29;
	color: #fff;
	margin: auto;
	padding-bottom: 10px;
	font-size: 14px;
	text-align: center;
	flex-shrink: 0;              /* never shrinks or gets pushed off */
}
.clsFooter a {
	color: #c8F;
	text-decoration: underline;
}
.clsFooter a:visited {
	color: #f8b;
	text-decoration: underline;
}
.clsFooter a:hover {
	background-color: #ff7;
	color: #000;
	text-decoration: underline;
}
/* ────────────────────────────────────────────────
   Image Viewer Modal
───────────────────────────────────────────────── */
.clsImageViewer {
	display: none;
	position: fixed;
	inset: 0;
	background: rgba(0,0,0,0.92);
	z-index: 9999;
	overflow: hidden;
	user-select: none;
	-webkit-user-select: none;
}
.clsImageViewer.active {
	display: flex;
	flex-direction: column;
	justify-content: center;
	align-items: center;
}
.clsViewerContent {
	position: relative;
	width: 100vw;
	height: 100vh;
	overflow: hidden;
	margin: 0;
	padding: 0;
	touch-action: none;
}
.clsViewerImg {
	position: absolute;
	top: 50%;
	left: 50%;
	transform: translate(-50%, -50%) translate(${translateX}px, ${translateY}px) scale(${currentScale});
	/* transform-origin: 50% 50%;  /* optional — can help with zoom math */
	max-width: none;
	max-height: none;      /* ← very important: prevent auto-downscaling that can cause odd overflow */
	width: auto;
	height: auto;
	pointer-events: auto;  /* make sure drag/zoom events still work */
}
.clsViewerImg.hidden {
	opacity: 0;
	visibility: hidden;
	transition: opacity 0.15s ease;
}
.clsViewerImg.off {
	display: none;
}
.clsViewerPDF {
	 width: 100%;
	 height: 98%;
}
.clsViewerPDF.off {
	display: none;
}
.clsClose {
	position: absolute;
	top: 5px;
	right: 10px;
	background: #aaa;
	color: #000;
	padding: 0px 5px 0px 5px;
	font-size: 20px;
	font-weight: bold;
	cursor: pointer;
	z-index: 10000;
}
.clsClose:hover {
	background: #ff7;
	color: #770;
}
.clsCloseImage {
	top: 5px;
	right: 10px;
}
.clsClosePDF {
	top: 20px;
	right: 130px;
}
.clsControls {
	position: absolute;
	bottom: 0px;
	left: 50%;
	transform: translateX(-50%);
	background: #777;
	padding: 5px 5px;
	border-radius: 8px;
	display: flex;
	gap: 10px;
}
.clsControls button {
	background: #aaa;
	color: #000;
	border: none;
	padding: 0px 3px;
	min-width: 25px;
	font-size: 30px;
	font-weight: bold;
	cursor: pointer;
	border-radius: 4px;
}
.clsControls button.off {
	display: none;
}
.clsControls button:hover {
	background: #ff7;
	color: #770;
}
.clsViewerDescr {
	opacity: 0.65;
 	position: absolute;
	top: 0px;
	left: 0px;
	right: 40px;
	padding: 5px 30px;
	text-align: center;
	font-size: 18px;
	color: #000;
	background: #FFF;
	z-index: 2;
}
.clsViewerDescr.off {
	display: none;
}
/* ────────────────────────────────────────────── */


