/* ========================
   THEME VARIABLES
======================== */
:root {
	/* Light theme colors */
	--bg-color: #ffffff;
	--text-color: #333333;
	--nav-bg: #ffffff;
	--footer-bg: #1e90ff;
	--accent: #007BFF;
	--feature-bg: #f5f5f5;
	--table-header-bg: #f4f4f4;
	--border-color: #ccc;
}

[data-theme="dark"] {
	/* Dark theme colors */
	--bg-color: #0f1620;
	--text-color: #e6eef8;
	--nav-bg: #1a1a1a;
	--footer-bg: #0d0d0d;
	--accent: #ffdd57;
	--feature-bg: #1e293b;
	--table-header-bg: #334155;
	--border-color: #444;
	--hero-gradient: linear-gradient(135deg, #0f1620, #1e293b);
}

/* ========================
   RESET & BASE
======================== */
* {
	margin: 0;
	padding: 0;
	box-sizing: border-box;
}

body {
	font-family: 'Segoe UI', sans-serif;
	line-height: 1.6;
	background-color: var(--bg-color);
	color: var(--text-color);
}

a {
	text-decoration: none;
	color: inherit;
}

section {
	padding: 60px 20px;
	text-align: center;
}

h1,
h2 {
	margin-bottom: 20px;
}

/* ========================
   NAVBAR
======================== */
.navbar {
	position: fixed;
	top: 0;
	width: 100%;
	background: var(--nav-bg);
	color: var(--text-color);
	box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
	display: flex;
	justify-content: space-between;
	align-items: center;
	padding: 20px 40px;
	z-index: 1000;
}

.logo {
	display: flex;
	align-items: center;
	font-weight: bold;
	font-size: 1.5rem;
	color: var(--text-color);
}

.logo-img {
	height: 40px;
	margin-right: 10px;
}

.nav-links {
	display: flex;
	list-style: none;
	gap: 20px;
}

.nav-links a {
	transition: color 0.3s;
}

.nav-links a:hover {
	color: var(--accent);
}

.hamburger {
	display: none;
	font-size: 24px;
	cursor: pointer;
}

#theme-toggle {
	background: none;
	border: none;
	font-size: 1.2rem;
	cursor: pointer;
	color: var(--text-color);
	margin-left: 10px;
}

.right-controls {
	display: flex;
	align-items: center;
	gap: 15px;
	/* Adds space between hamburger and theme toggle */
}

/* Update the hamburger media query to reflect the change */
@media (max-width: 768px) {
	.nav-links {
		display: flex;
		flex-direction: column;
		width: 100%;
		position: absolute;
		top: 60px;
		/* Adjust based on your navbar height */
		right: 0;
		/* Changed from 'left: 0' to align to the right */
		background-color: var(--nav-bg);
		padding: 1rem 0;
		border-top: 1px solid var(--border-color);
		text-align: center;
		max-height: 0;
		overflow: hidden;
		transition: max-height 0.3s ease-in-out, padding 0.3s ease-in-out;
	}

	.nav-links.active {
		max-height: 500px;
		/* Expand the menu smoothly */
		padding: 1rem 0;
	}

	.hamburger {
		display: block;
	}
}

/* ========================
   HERO
======================== */
.hero {
	height: 100vh;
	/*background: linear-gradient(135deg, #007BFF, #00C6FF);*/
	background: var(--hero-gradient, linear-gradient(135deg, #007BFF, #00C6FF));
	color: white;
	display: flex;
	flex-direction: column;
	justify-content: center;
	align-items: center;
	padding-top: 80px;
}

.hero h1 {
	font-size: 3rem;
}

.hero .cta {
	margin-top: 20px;
	padding: 12px 25px;
	background: white;
	color: #007BFF;
	border-radius: 5px;
	font-weight: bold;
}

/* ========================
   FEATURES
======================== */
.feature-grid {
	display: grid;
	grid-template-columns: repeat(auto-fit, minmax(120px, 1fr));
	gap: 20px;
	margin-top: 30px;
}

.feature {
	background: var(--feature-bg);
	padding: 20px;
	border-radius: 10px;
}

/* ========================
   FORMS (if used)
======================== */
form {
	max-width: 500px;
	margin: 0 auto;
	display: flex;
	flex-direction: column;
	gap: 15px;
}

input,
textarea {
	padding: 12px;
	border: 1px solid var(--border-color);
	border-radius: 5px;
	font-size: 1rem;
}

button {
	padding: 12px;
	background: var(--accent);
	color: white;
	border: none;
	font-size: 1rem;
	border-radius: 5px;
	cursor: pointer;
}

/* ========================
   RESPONSIVE NAV
======================== */
@media (max-width: 768px) {
	.nav-links {
		position: absolute;
		top: 70px;
		right: 0;
		flex-direction: column;
		background: var(--nav-bg);
		width: 200px;
		display: none;
		box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
	}

	.nav-links.active {
		display: flex;
	}

	.hamburger {
		display: block;
	}
}

/* ========================
   GALLERY
======================== */
.gallery {
	padding: 4rem 2rem;
	background-color: var(--bg-color);
	color: var(--text-color);
	text-align: center;
}

.gallery h2 {
	font-size: 2.5rem;
	margin-bottom: 2rem;
}

.gallery-grid {
	display: grid;
	grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
	gap: 1.5rem;
	max-width: 1200px;
	margin: 0 auto;
}

.gallery-grid img {
	width: 272.5px;
	height: 215px;
	border-radius: 10px;
	object-fit: cover;
	box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
	transition: transform 0.3s ease;
	cursor: pointer;
}

.gallery-grid img:hover {
	transform: scale(1.05);
	box-shadow: 0 6px 15px rgba(0, 0, 0, 0.2);
}

/* Lightbox */
.lightbox {
	display: none;
	position: fixed;
	z-index: 2000;
	left: 0;
	top: 0;
	width: 100vw;
	height: 100vh;
	background-color: rgba(0, 0, 0, 0.8);
	justify-content: center;
	align-items: center;
}

.lightbox-img {
	max-width: 90%;
	max-height: 80%;
	border-radius: 10px;
	box-shadow: 0 4px 20px rgba(0, 0, 0, 0.5);
}

.close {
	position: fixed;
	top: 20px;
	right: 30px;
	font-size: 3rem;
	color: white;
	cursor: pointer;
	user-select: none;
}

/* ========================
   FOOTER
======================== */
.footer {
	background-color: var(--footer-bg);
	color: var(--text-color);
	padding: 1rem .5rem;
	text-align: center;
}

.footer .container {
	max-width: 1200px;
	margin: 0 auto;
}

/* ========================
   CLOCK-IN TABLE
======================== */
#clockin-table {
	width: 100%;
	border-collapse: collapse;
	margin-top: 1rem;
}

#clockin-table th,
#clockin-table td {
	padding: 8px 12px;
	border: 1px solid var(--border-color);
	text-align: left;
}

#clockin-table th {
	background-color: var(--table-header-bg);
	color: var(--text-color);
}

#search {
	padding: 8px;
	margin-bottom: 1rem;
	border-radius: 5px;
	border: 1px solid var(--border-color);
}

/* ========================
   LOGO ANIMATIONS
======================== */
@keyframes pulse {

	0%,
	100% {
		transform: scale(1);
	}

	50% {
		transform: scale(1.25);
	}
}

@keyframes shake {

	0%,
	100% {
		transform: translate(0, 0) rotate(0deg);
	}

	15% {
		transform: translate(4px, 2px) rotate(2deg);
	}

	30% {
		transform: translate(-4px, 3px) rotate(-2deg);
	}

	45% {
		transform: translate(3px, -2px) rotate(1.5deg);
	}

	60% {
		transform: translate(-3px, 2px) rotate(-1.5deg);
	}

	75% {
		transform: translate(2px, -3px) rotate(1deg);
	}

	90% {
		transform: translate(-2px, 2px) rotate(-1deg);
	}
}

.logo-wrapper:hover {
	animation: shake 5s infinite;
}

.logo-wrapper:hover .hero-logo {
	animation: pulse 10s infinite ease-in-out;
}

.hero-logo {
	width: 150px;
	height: auto;
	display: block;
	margin: 0 auto;
	animation: pulse 7s infinite ease-in-out;
}