/* =========================
   RESET
========================= */
* {
	margin: 0;
	padding: 0;
	box-sizing: border-box;
}

html,
body {
	overflow-x: hidden;
	scroll-behavior: smooth;
}

/* =========================
   COLOR SYSTEM (KASAYAM THEME)
========================= */
:root {
	--primary: #fb8524;
	--secondary: #f97316;
	--accent: #fbbf24;

	--bg: #fff7ed;
	--glass: rgba(255, 247, 237, 0.7);

	--text-dark: #3b1d00;
	--text-light: #7c2d12;

	--border: #fed7aa;

	--gradient-start: #fb8524;
	--gradient-mid: #f97316;
	--gradient-end: #ea580c;
}

/* =========================
   BODY
========================= */
body {
	font-family: 'Poppins', sans-serif;
	background: var(--bg);
	color: var(--text-dark);
	line-height: 1.6;
}

/* =========================
   TEXT
========================= */
h1 {
	font-size: clamp(24px, 5vw, 42px);
	margin-bottom: 10px;
}

h2 {
	font-size: clamp(20px, 4vw, 30px);
}

h3 {
	margin-bottom: 12px;
}

p {
	font-size: clamp(14px, 2.5vw, 18px);
}

/* =========================
   CONTAINER
========================= */
.container {
	width: 90%;
	max-width: 1150px;
	margin: auto;
}

/* =========================
   NAVBAR
========================= */
.navbar {
	position: sticky;
	top: 0;
	width: 100%;
	background: white;
	z-index: 1000;
	padding: 15px 0;
	transition: all 0.4s ease;
	box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);
}

.navbar-scrolled {
	background: rgba(255, 255, 255, 0.95);
	backdrop-filter: blur(10px);
	padding: 10px 0;
	box-shadow: 0 4px 20px rgba(249, 115, 22, 0.15);
}

.nav-container {
	display: flex;
	align-items: center;
	justify-content: space-between;
	position: relative;
}

.logo {
	color: var(--primary);
	font-weight: bold;
}

/* =========================
   MENU TOGGLE
========================= */
.menu-toggle {
	display: none;
	font-size: 26px;
	color: var(--primary);
	cursor: pointer;
}

/* =========================
   NAV LINKS
========================= */
.nav-links {
	display: flex;
	list-style: none;
	gap: 25px;
}

.nav-links a {
	color: var(--primary);
	text-decoration: none;
	position: relative;
	font-weight: 500;
	transition: 0.3s;
}

.nav-links a::after {
	content: '';
	position: absolute;
	width: 0%;
	height: 2px;
	background: var(--primary);
	left: 0;
	bottom: -4px;
	transition: 0.3s;
}

.nav-links a:hover {
	color: var(--primary);
}

.nav-links a:hover::after {
	width: 100%;
}

/* =========================
   HERO
========================= */
.hero {
	min-height: 70vh;
	display: flex;
	align-items: center;
	text-align: center;
	padding: 60px 20px;

	background:
		linear-gradient(rgba(251, 133, 36, 0.85), rgba(249, 115, 22, 0.85)),
		url('https://images.unsplash.com/photo-1504711434969-e33886168f5c');

	background-size: cover;
	background-position: center;
	color: white;
}

/* =========================
   SECTION
========================= */
.section {
	padding: 80px 0;
}

.section h2 {
	margin-bottom: 25px;
	color: var(--primary);
}

/* =========================
   LIGHT SECTION
========================= */
.light {
	background: linear-gradient(to right, #fff7ed, #ffedd5);
}

/* =========================
   CARD GRID
========================= */
.card-grid {
	display: grid;
	grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
	gap: 25px;
}

/* =========================
   CARD
========================= */
.card {
	background: rgba(255, 237, 213, 0.6);
	backdrop-filter: blur(12px);
	border-radius: 15px;
	padding: 25px;
	border: 1px solid var(--border);
	transition: 0.3s;
}

.card:hover {
	transform: translateY(-6px);
	box-shadow: 0 20px 40px rgba(251, 133, 36, 0.2);
}

/* =========================
   GALLERY
========================= */
.gallery-grid {
	display: grid;
	grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
	gap: 15px;
}

.gallery-grid img {
	width: 100%;
	border-radius: 12px;
	transition: 0.3s;
}

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

/* =========================
   LIST
========================= */
.list {
	list-style: none;
}

.list li {
	margin-bottom: 10px;
	padding-left: 10px;
	border-left: 3px solid var(--accent);
}

/* =========================
   ICONS (SVG PLACEHOLDERS)
========================= */
.icon {
	width: 18px;
	height: 18px;
	vertical-align: middle;
	display: inline-block;
	stroke-linecap: round;
	stroke-linejoin: round;
}

.icon-lg {
	width: 24px;
	height: 24px;
}

/* =========================
   TABLE
========================= */
.table-container {
	overflow-x: auto;
}

table {
	width: 100%;
	border-collapse: collapse;
	background: white;
	border-radius: 10px;
	overflow: hidden;
}

table th {
	background: var(--secondary);
	color: white;
}

table th,
table td {
	padding: 12px;
	border: 1px solid var(--border);
}

/* =========================
   FOOTER
========================= */
footer {
	text-align: center;
	padding: 25px;
	background: linear-gradient(to right, #fb8524, #ea580c);
	color: white;
}

/* =========================
   ANIMATION
========================= */
.fade-in {
	opacity: 0;
	transform: translateY(40px);
	transition: all 0.8s ease;
}

.fade-in.show {
	opacity: 1;
	transform: translateY(0);
}

/* =========================
   BUTTONS
========================= */
.btn {
	display: inline-block;
	padding: 12px 25px;
	border: none;
	border-radius: 8px;
	text-decoration: none;
	font-weight: 600;
	transition: 0.3s;
}

.btn-primary {
	background: var(--secondary);
	color: white;
}

.btn-primary:hover {
	background: #ea580c;
	transform: translateY(-2px);
}

.btn-outline {
	border: 2px solid white;
	color: white;
}

.btn-outline:hover {
	background: white;
	color: var(--primary);
}

/* =========================
   MOBILE
========================= */
@media (max-width: 768px) {
	.menu-toggle {
		display: block;
		position: absolute;
		right: 15px;
		top: 50%;
		transform: translateY(-50%);
	}

	.nav-links {
		position: absolute;
		top: 60px;
		right: 0;
		width: 100%;
		background: white;
		flex-direction: column;
		align-items: center;
		display: none;
		padding: 20px 0;
		gap: 0px;
		box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
		border-top: 1px solid var(--border);
	}

	.nav-links.active {
		display: flex;
	}

	.nav-links li {
		margin: 6px 0;
	}

	.nav-links a {
		color: var(--primary);
		font-size: 18px;
	}

	.nav-links a:hover {
		color: var(--primary);
	}

	.section {
		padding: 50px 0;
	}

	.container {
		width: 92%;
	}
}

/* =========================
   PDF POPUP
========================= */
.popup-overlay {
	position: fixed;
	top: 0;
	left: 0;
	width: 100%;
	height: 100%;
	background: rgba(0, 0, 0, 0.6);
	display: flex;
	justify-content: center;
	align-items: center;
	z-index: 2000;
}

.popup-box {
	background: #fff7ed;
	padding: 30px;
	border-radius: 12px;
	text-align: center;
	max-width: 400px;
	width: 90%;
	position: relative;
	border: 2px solid var(--accent);
	animation: popupFade 0.4s ease;
}

.popup-box h2 {
	margin-bottom: 15px;
	color: var(--primary);
}

.popup-box p {
	margin-bottom: 20px;
}

.close-btn {
	position: absolute;
	top: 10px;
	right: 15px;
	font-size: 20px;
	cursor: pointer;
}

.close-btn:hover {
	color: #ea580c;
}

@keyframes popupFade {
	from {
		opacity: 0;
		transform: scale(0.8);
	}
	to {
		opacity: 1;
		transform: scale(1);
	}
}

.carousel {
	position: relative;
	width: 100%;
	margin: 0;
	overflow: visible;
}

.carousel-viewport {
	overflow: hidden;
	width: 100%;
	padding: 30px 0;
}

.carousel-track {
	display: flex;
	align-items: center;
	transition: transform 0.5s ease;
	will-change: transform;
}

.slide {
	height: 400px;
	width: auto;
	max-width: 85vw;
	object-fit: contain;
	margin: 0 15px;
	border-radius: 12px;
	flex-shrink: 0;

	/* In-active State */
	opacity: 0.5;
	filter: blur(1px);
	transform: scale(0.9);
	transition: all 0.5s cubic-bezier(0.25, 0.46, 0.45, 0.94);
	will-change: transform, opacity;
}

.slide.active {
	opacity: 1;
	filter: blur(0);
	transform: scale(1.05); /* Slight pop */
	z-index: 2;
}

/* ARROWS */
.nav {
	position: absolute;
	top: 50%;
	transform: translateY(-50%);
	background: #f97316;
	color: white;
	border: none;
	padding: 10px;
	cursor: pointer;
	border-radius: 50%;
	font-size: 18px;
	z-index: 10;
	box-shadow: 0 4px 12px rgba(249, 115, 22, 0.3);
	display: flex;
	align-items: center;
	justify-content: center;
}

.nav.left {
	left: 10px;
}

.nav.right {
	right: 10px;
}

.nav:hover {
	background: #ea580c;
}

/* CAROUSEL MOBILE */
@media (max-width: 768px) {
	.slide {
		min-width: 70vw;
		width: 70vw;
	}
}

@media (max-width: 480px) {
	.slide {
		min-width: 80vw;
		width: 80vw;
	}

	.nav {
		padding: 8px 12px;
		font-size: 14px;
	}
}

/* =========================
   PDF VIEWER DIALOG
========================= */
.pdf-viewer-overlay {
	position: fixed;
	top: 0;
	left: 0;
	width: 100%;
	height: 100%;
	background: rgba(0, 0, 0, 0.7);
	display: none;
	justify-content: center;
	align-items: center;
	z-index: 3000;
	cursor: pointer;
}

.pdf-viewer-dialog {
	background: #4a4a4a;
	border-radius: 12px;
	width: 85vw;
	height: 85vh;
	overflow: hidden;
	border: 2px solid var(--accent);
	animation: popupFade 0.4s ease;
	cursor: default;
}

.pdf-viewer-dialog iframe {
	width: 100%;
	height: 100%;
	border: none;
	display: block;
}

.pdf-close-btn {
	position: absolute;
	top: calc(50% - 42.5vh - 30px);
	left: 50%;
	transform: translateX(-50%);
	background: #f97316;
	color: white;
	border: none;
	font-size: 18px;
	width: 44px;
	height: 44px;
	border-radius: 50%;
	cursor: pointer;
	z-index: 3001;
	display: flex;
	align-items: center;
	justify-content: center;
	box-shadow: 0 4px 15px rgba(0, 0, 0, 0.4);
	transition: background 0.2s;
}

.pdf-close-btn:hover {
	background: #ea580c;
}

/* PDF VIEWER RESPONSIVE */
@media (max-width: 768px) {
	.pdf-viewer-dialog {
		width: 95vw;
		height: 90vh;
		border-radius: 8px;
	}

	.pdf-close-btn {
		top: calc(50% - 45vh - 30px);
	}
}

@media (max-width: 480px) {
	.pdf-viewer-dialog {
		width: 100vw;
		height: 100vh;
		border-radius: 0;
		border: none;
	}

	.pdf-close-btn {
		top: 8px;
		width: 36px;
		height: 36px;
		font-size: 14px;
	}
}
