:root {
	--primary: #0056d2;
	--accent: #007bff;
	--success: #28a745;
	--danger: #dc3545;
	--bg: #f8f9fb;
	--card-bg: #ffffff;
	--text-dark: #1c1c1c;
	--text-light: #666;
	--border: #e0e0e0;
	--radius: 12px;
	--shadow: 0 6px 18px rgba(0, 0, 0, 0.08);
}

/* Film Title Heading */
#film-title-heading {
	font-size: 2rem;
	font-weight: 800;
	text-align: center;
	margin: 20px 0;
	background: linear-gradient(90deg, #7b1e3a, #d32f2f, #f06292);
	-webkit-background-clip: text;
	-webkit-text-fill-color: transparent;
	letter-spacing: 1px;
	text-transform: uppercase;
	position: relative;
	animation: fadeInUp 0.6s ease;
}

/* underline accent */
#film-title-heading::after {
	content: "";
	display: block;
	margin: 8px auto 0;
	width: 60px;
	height: 4px;
	border-radius: 2px;
	background: linear-gradient(90deg, #7b1e3a, #d32f2f);
	box-shadow: 0 2px 6px rgba(0, 0, 0, 0.2);
}

/* subtle animation */
@keyframes fadeInUp {
	from {
		opacity: 0;
		transform: translateY(20px);
	}

	to {
		opacity: 1;
		transform: translateY(0);
	}
}

#copyJSON,
#copyHTML,
#clearCities {
	width: auto !important;
	min-width: 120px;
	display: inline-block;
	margin: 0.3rem;
}

#copyJSON,
#copyHTML {
	margin: 0.3rem;
}

#copyJSON:disabled,
#copyHTML:disabled {
	opacity: 0.5;
	cursor: not-allowed;
}

/* Smooth transitions */
body,
.container,
input,
button {
	transition: background 0.3s, color 0.3s, border 0.3s;
}

/* Dark theme */
body.dark-theme {
	--bg: #121212;
	--card-bg: #1e1e1e;
	--text-dark: #f1f1f1;
	--text-light: #aaa;
	--border: #333;
	--primary: #90caf9;
	--accent: #42a5f5;
}

* {
	box-sizing: border-box;
	margin: 0;
	padding: 0;
	font-family: "Segoe UI", Roboto, sans-serif;
}

body {
	background: var(--bg);
	color: var(--text-dark);
	padding: 0.6rem;
	overflow-x: hidden;
}

/* Container */
.container {
	max-width: 1200px;
	margin: auto;
	padding: 2rem;
	background: var(--card-bg);
	border-radius: var(--radius);
	box-shadow: var(--shadow);
}

/* Headings */
h2,
h3 {
	text-align: center;
	font-weight: 600;
	color: var(--primary);
	margin-bottom: 1.2rem;
}

/* Labels */
label {
	font-weight: 500;
	display: block;
	margin: 1rem 0 0.4rem;
}

/* Inputs */
input[type="text"],
input[type="date"],
input[list] {
	width: 100%;
	padding: 0.75rem 1rem;
	font-size: 1rem;
	border: 1px solid var(--border);
	border-radius: var(--radius);
	margin-bottom: 1rem;
	transition: 0.3s border-color, box-shadow;
	background: #fff;
}

input:focus {
	border-color: var(--accent);
	outline: none;
	box-shadow: 0 0 0 4px rgba(0, 123, 255, 0.1);
}

/* Search box fix for mobile zoom */
#searchBox,
#searchBox input,
input[type="text"],
input[type="search"] {
	font-size: 16px;
	/* prevent mobile zoom */
}

#searchBox input {
	padding: 10px 14px;
	border-radius: 8px;
	border: 1px solid #ccc;
	width: 100%;
	box-sizing: border-box;
}

/* ✅ Common button styling */
button {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	gap: 4px;
	padding: 6px 10px;
	font-size: 14px;
	line-height: 1;
	border: 1px solid #ccc;
	border-radius: 6px;
	background: #f9f9f9;
	color: #333;
	cursor: pointer;
	white-space: nowrap;
	max-width: fit-content;
}

/* Hover / active effects */
button:hover {
	background: #e9e9e9;
	border-color: #999;
}

button:active {
	background: #ddd;
}

/* ❌ Special for clear (×) small buttons inside input */
.input-clear button {
	padding: 2px 6px;
	font-size: 16px;
	line-height: 1;
	background: transparent;
	border: none;
	color: #666;
	cursor: pointer;
	position: absolute;
	right: 8px;
	top: 50%;
	transform: translateY(-50%);
}

.input-clear button:hover {
	color: #000;
	background: transparent;
}

/* Error Message */
.error-msg {
	margin-top: 0.4rem;
	font-size: 0.9rem;
	color: var(--danger);
	display: none;
}

/* Tags */
.city-tag {
	display: inline-block;
	background: maroon;
	/* 🔴 maroon color */
	color: #fff;
	padding: 0.35rem 0.8rem;
	border-radius: var(--radius);
	margin: 0.25rem;
	cursor: pointer;
	font-size: 0.9rem;
	transition: background 0.2s;
}

.city-tag:hover {
	background: #b22222;
	/* thoda lighter maroon hover effect */
}

#toggleBtn,
#clearCities,
#copyJSON {
	background: maroon;
	/* default background */
	color: #fff;
	/* white text */
	border: none;
	padding: 0.5rem 1.2rem;
	margin: 0.3rem;
	border-radius: 8px;
	/* smooth rounded */
	font-size: 0.95rem;
	font-weight: 500;
	cursor: pointer;
	transition: all 0.2s ease-in-out;
	display: inline-flex;
	align-items: center;
	gap: 6px;
	/* emoji/text spacing */
	box-shadow: 0 2px 6px rgba(0, 0, 0, 0.15);
}

/* Hover Effect */
#toggleBtn:hover,
#clearCities:hover,
#copyJSON:hover {
	background: #a30000;
	/* darker maroon on hover */
	transform: translateY(-2px);
	/* slight lift */
	box-shadow: 0 4px 10px rgba(0, 0, 0, 0.25);
}

/* Active/Click Effect */
#toggleBtn:active,
#clearCities:active,
#copyJSON:active {
	transform: translateY(0);
	/* press down */
	box-shadow: 0 2px 5px rgba(0, 0, 0, 0.2);
}

/* Specific colors if you want distinction */
#toggleBtn {
	background: #007bff;
}

/* blue */
#toggleBtn:hover {
	background: #0056b3;
}

#clearCities {
	background: #dc3545;
}

/* red */
#clearCities:hover {
	background: #a71d2a;
}

#copyJSON {
	background: #28a745;
}

/* green */
#copyJSON:hover {
	background: #1e7e34;
}

/* Default cities */
.default-city {
	background: #e8f0fe;
	color: var(--primary);
	padding: 0.5rem 1rem;
	border-radius: var(--radius);
	margin: 0.25rem;
	cursor: pointer;
	transition: all 0.2s;
}

.default-city.selected {
	background: var(--primary);
	color: #fff;
}

.default-city:hover {
	background: #d0e2ff;
}

/* Table */
table {
	width: 100%;
	border-collapse: collapse;
	margin: 1rem 0;
	table-layout: auto;
	font-size: 0.95rem;
}

th,
td {
	border: 1px solid #ddd;
	padding: 0.6rem;
	text-align: center;
	word-break: keep-all;
	overflow-wrap: normal;
	/* default behaviour */
	white-space: normal;
}

th {
	background: var(--primary);
	color: #fff;
	font-weight: 600;
}

tr:nth-child(even) {
	background: #f9f9f9;
}

tr:hover {
	background: #eef6ff;
}

.low-occ {
	background: #d6f5e9;
}

.mid-occ {
	background: #fffbcf;
}

.high-occ {
	background: #ffe5e5;
}

/* Stylish Sticky Heading */
#dataHeading {
	position: sticky;
	top: 0;
	background: linear-gradient(90deg, #7b1e3a, #d32f2f, #f06292);
	color: #fff;
	font-size: clamp(1rem, 3vw, 1.25rem);
	/* Auto adjust font size */
	font-weight: 700;
	text-align: center;
	letter-spacing: 0.5px;
	padding: clamp(0.6rem, 2vw, 0.9rem) clamp(0.8rem, 2vw, 1rem) clamp(0.8rem, 2vw, 1.2rem);

	/* Responsive padding */
	.scroll-btn {
		position: fixed;
		bottom: clamp(12px, 3vw, 18px);
		/* adjusts bottom gap */
		right: clamp(12px, 3vw, 18px);
		/* adjusts right gap */
		width: clamp(32px, 7vw, 42px);
		/* auto width based on screen */
		height: clamp(32px, 7vw, 42px);
		/* auto height based on screen */
		background: linear-gradient(135deg, #ff4b2b, #ff416c);
		color: #fff;
		font-size: clamp(1rem, 3vw, 1.3rem);
		/* auto font size */
		font-weight: bold;
		border: none;
		border-radius: 8px;
		cursor: pointer;
		display: flex;
		align-items: center;
		justify-content: center;
		box-shadow: 0 4px 12px rgba(255, 65, 108, 0.4);
		transition: transform 0.25s ease, box-shadow 0.3s ease, background 0.3s ease;
		z-index: 9999;
	}

	.scroll-btn:hover {
		transform: translateY(-2px) scale(1.05);
		background: linear-gradient(135deg, #ff416c, #ff4b2b);
		box-shadow: 0 6px 16px rgba(255, 65, 108, 0.5);
	}

	z-index: 10;
	border: none;
	border-radius: 10px 10px 0 0;
	box-shadow: 0 3px 10px rgba(0, 0, 0, 0.15);
	animation: fadeInDown 0.6s ease;
}

/* Load animation */
@keyframes fadeInDown {
	from {
		opacity: 0;
		transform: translateY(-10px);
	}

	to {
		opacity: 1;
		transform: translateY(0);
	}
}

/* Credit line inside heading */
#dataHeading .credit {
	display: block;
	font-size: 0.8rem;
	font-weight: 400;
	margin-top: 4px;
	color: #ffeaea;
}

/* Link style */
#dataHeading .credit a {
	color: #fff;
	font-weight: 500;
	text-decoration: underline;
}

#dataHeading .credit a:hover {
	text-decoration: none;
	opacity: 0.9;
}

#eventCode {
	font-size: 16px;
	padding: 10px 14px;
	border-radius: 8px;
	border: 1px solid #ccc;
	width: 100%;
	box-sizing: border-box;
}

/* JSON Output */
#outputJSON {
	background: #1e1e1e;
	color: #d4d4d4;
	padding: 0.8rem;
	border-radius: var(--radius);
	box-shadow: var(--shadow);
	overflow-x: auto;
	font-family: "Courier New", monospace;
	max-height: 400px;
	white-space: pre-wrap;
}

/* Loader */
.spinner {
	width: 32px;
	height: 32px;
	border: 4px solid #f3f3f3;
	border-top: 4px solid var(--accent);
	border-radius: 50%;
	animation: spin 1s linear infinite;
	margin: 2rem auto;
}

@keyframes spin {
	to {
		transform: rotate(360deg);
	}
}

/* Toasts */
@keyframes fadeIn {
	from {
		opacity: 0;
		transform: translateY(20px);
	}

	to {
		opacity: 1;
		transform: translateY(0);
	}
}

@keyframes fadeOut {
	from {
		opacity: 1;
	}

	to {
		opacity: 0;
		transform: translateY(20px);
	}
}

#toastContainer div {
	animation: fadeIn 0.3s ease, fadeOut 4s forwards;
}

/* Responsive */
@media (max-width: 992px) {

	table,
	th,
	td {
		font-size: 0.85rem;
		padding: 0.4rem;
	}
}

@media (max-width: 768px) {
	body {
		padding: 0.3rem;
	}

	.container {
		padding: 1rem;
	}

	h2 {
		font-size: 1.4rem;
	}

	input,
	button {
		font-size: 0.9rem;
	}

	table,
	th,
	td {
		font-size: 0.75rem;
		padding: 0.3rem;
	}
}

@media (max-width: 576px) {
	body {
		padding: 0.15rem;
	}

	.container {
		padding: 0.05rem;
	}

	table,
	th,
	td {
		font-size: 0.5rem;
		padding: 0.15rem;
	}
}

/* 🎬 Movie list wrapper (default: Desktop) */
#movieList {
	display: grid;
	grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
	/* Desktop: 5-6 cards */
	gap: 16px;
	margin-top: 15px;
}

/* 🎟️ Card wrapper */
#movieList div {
	background: #fff;
	border-radius: 10px;
	overflow: hidden;
	box-shadow: 0 3px 8px rgba(0, 0, 0, 0.1);
	transition: transform 0.2s;
	display: flex;
	flex-direction: column;
	height: 100%;
}

#movieList div:hover {
	transform: translateY(-3px);
}

/* 🔗 Anchor full-block */
#movieList div a {
	display: flex;
	flex-direction: column;
	height: 100%;
	text-decoration: none !important;
	/* underline hatao */
	color: inherit;
}

/* 🖼️ Poster */
#movieList img {
	width: 100%;
	height: 220px;
	/* Desktop poster height */
	object-fit: cover;
	flex-shrink: 0;
}

/* 📋 Text block (sab devices pe) */
#movieList div>a>div {
	padding: 10px;
	min-height: 55px;
	/* title+date ke liye equal block */
	display: flex;
	flex-direction: column;
	justify-content: center;
	flex-grow: 1;
}

/* 🎬 Title */
#movieList strong {
	font-size: 0.9rem;
	font-weight: 600;
	color: var(--primary);
	line-height: 1.2;
	margin-bottom: 2px;
	text-decoration: none !important;
	overflow: hidden;
	text-overflow: ellipsis;
	white-space: nowrap;
	/* single line truncate */
}

/* 📅 Date */
#movieList small {
	font-size: 0.75rem;
	color: #666;
	text-decoration: none !important;
}

/* 📱 Tablet view */
@media (max-width: 991px) {
	#movieList {
		grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
		/* 3-4 cards */
		gap: 12px;
	}

	#movieList img {
		height: 180px;
	}

	#movieList strong {
		font-size: 0.85rem;
	}
}

/* 📱 Mobile view */
@media (max-width: 576px) {
	#movieList {
		grid-template-columns: repeat(3, 1fr);
		/* 3 cards ek row me */
		gap: 8px;
	}

	#movieList img {
		height: 130px;
	}

	#movieList div>a>div {
		min-height: 50px;
		padding: 6px;
	}

	#movieList strong {
		font-size: 0.75rem;
	}

	#movieList small {
		font-size: 0.65rem;
	}
}

.nav-left {
	display: flex;
	align-items: center;
	gap: 10px;
	/* space between icon and title */
}

/* 🌈 Modern Stylish Navbar (same as before) */
.navbar {
	display: flex;
	transition: opacity 0.3s ease, transform 0.3s ease;
	justify-content: space-between;
	align-items: center;
	padding: 0.85rem 1.8rem;
	backdrop-filter: blur(14px);
	background: linear-gradient(135deg, #7b1e3a 0%, #d32f2f 50%, #ff6f61 100%);
	border-bottom: 1px solid rgba(255, 255, 255, 0.15);
	position: relative;
	/* ✅ make it normal by default */
	top: 0;
	z-index: 999;
	box-shadow: 0 6px 16px rgba(0, 0, 0, 0.3);
	border-radius: 0 0 16px 16px;
}

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


.brand-name {
	margin: 0;
	/* removes default span/text spacing issue */
	line-height: 1;
	/* keeps it vertically centered */
	font-weight: 800;
	font-size: clamp(1rem, 3vw, 1.5rem);
	/* Auto-adjusts based on screen width */
	letter-spacing: 1px;
	text-transform: uppercase;
	background: linear-gradient(90deg, #fff, #ffeaea);
	-webkit-background-clip: text;
	-webkit-text-fill-color: transparent;
	text-shadow: 0 0 6px rgba(255, 255, 255, 0.3);
	white-space: nowrap;
}

.menu-btn {
	display: flex;
	/* keeps svg centered */
	align-items: center;
	justify-content: center;
	background: transparent;
	border: none;
	cursor: pointer;
	display: none;
	color: white;
	transition: transform 0.2s ease, color 0.3s;
}

.menu-btn:hover {
	transform: scale(1.15);
	color: #ffd1d1;
}

.nav-links {
	display: flex;
	gap: 2rem;
	transition: all 0.3s ease-in-out;
}

.nav-links a {
	position: relative;
	color: #fff;
	font-weight: 500;
	font-size: 1rem;
	text-decoration: none;
	letter-spacing: 0.3px;
}

.nav-links a::after {
	content: "";
	position: absolute;
	bottom: -5px;
	left: 0;
	width: 0%;
	height: 2px;
	background: #ffeaea;
	border-radius: 10px;
	transition: width 0.3s ease-in-out;
}

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

/* 📤 Share Button */
.share-btn {
	background: linear-gradient(135deg, #ffffff, #ffeaea);
	color: #7b1e3a;
	font-weight: 600;
	padding: 8px 18px;
	border-radius: 30px;
	border: none;
	cursor: pointer;
	box-shadow: 0 4px 12px rgba(0, 0, 0, 0.25);
	transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.share-btn:hover {
	transform: translateY(-3px) scale(1.03);
	box-shadow: 0 6px 16px rgba(0, 0, 0, 0.35);
}

/* 📱 Mobile Dropdown Style */
@media (max-width: 768px) {
	.menu-btn {
		display: inline-flex;
	}

	.nav-links {
		display: flex;
		flex-direction: column;
		position: absolute;
		top: 100%;
		left: 0;
		right: 0;
		background: #fff;
		padding: 1rem;
		box-shadow: 0 6px 16px rgba(0, 0, 0, 0.2);
		border-radius: 0 0 16px 16px;
		transform: translateY(-20px);
		opacity: 0;
		pointer-events: none;
		transition: all 0.3s ease-in-out;
	}

	.nav-links.show {
		transform: translateY(0);
		opacity: 1;
		pointer-events: auto;
	}

	.nav-links a {
		color: #333;
		font-size: 1.1rem;
		padding: 10px 0;
		border-bottom: 1px solid #eee;
	}

	.nav-links a:last-child {
		border-bottom: none;
	}
}

@keyframes dropdownFade {
	from {
		opacity: 0;
		transform: translateY(-8px);
	}

	to {
		opacity: 1;
		transform: translateY(0);
	}
}

/* 📍 Square Scroll Button */
/* 🌟 Floating Square Scroll Button */
.scroll-btn {
	position: fixed;
	bottom: clamp(12px, 3vw, 18px);
	/* adjusts bottom gap */
	right: clamp(12px, 3vw, 18px);
	/* adjusts right gap */
	width: clamp(32px, 7vw, 42px);
	/* auto width based on screen */
	height: clamp(32px, 7vw, 42px);
	/* auto height based on screen */
	background: linear-gradient(135deg, #ff4b2b, #ff416c);
	color: #fff;
	font-size: clamp(1rem, 3vw, 1.3rem);
	/* auto font size */
	font-weight: bold;
	border: none;
	border-radius: 8px;
	cursor: pointer;
	display: flex;
	align-items: center;
	justify-content: center;
	box-shadow: 0 4px 12px rgba(255, 65, 108, 0.4);
	transition: transform 0.25s ease, box-shadow 0.3s ease, background 0.3s ease;
	z-index: 9999;
}

.scroll-btn:hover {
	transform: translateY(-2px) scale(1.05);
	background: linear-gradient(135deg, #ff416c, #ff4b2b);
	box-shadow: 0 6px 16px rgba(255, 65, 108, 0.5);
}
#timeFilters {
  display: grid;
  grid-template-columns: auto repeat(4, 1fr); /* heading + 4 pills */
  align-items: center;
  gap: 12px;
  margin-top: 8px;
  font-size: 14px;
  max-width: 900px;
  margin-left: auto;
  margin-right: auto;
}

#timeFilters .timeFilterHeading {
  font-weight: bold;
  white-space: nowrap;
}

#timeFilters label {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  background: #f5f5f5;
  padding: 8px 12px;
  border-radius: 20px;
  cursor: pointer;
  height: 44px;       /* same height for all */
  box-sizing: border-box;
  white-space: nowrap;
}

#timeFilters input[type="checkbox"] {
  accent-color: #007bff;
}

/* 📱 Mobile: 2 pills per row */
@media (max-width: 767px) {
  #timeFilters {
    grid-template-columns: 1fr 1fr;
  }
  #timeFilters .timeFilterHeading {
    grid-column: span 2;   /* heading full width */
    margin-bottom: 4px;
  }
}

/* 📱 Smallest mobile: 1 pill per row */
@media (max-width: 350px) {
  #timeFilters {
    grid-template-columns: 1fr;
  }
  #timeFilters .timeFilterHeading {
    grid-column: span 1;
  }
}











/* 🔤 Import custom font */
@font-face {
  font-family: 'ProjectK';
  src: url('/ProjectK.ttf') format('truetype');
  font-weight: normal;
  font-style: normal;
}

/* 💧 Apply gradient text watermark */
table {
  position: relative;
  overflow: hidden;
}

table::after {
  content: "BOXOFFICE24.PAGES.DEV";
  position: absolute;
  top: 30%; /* distance from top in pixels */
  left: 50%;
  transform: translate(-50%, -50%) rotate(-10deg);
  z-index: 0;

  font-family: 'ProjectK', 'Poppins', 'Segoe UI', sans-serif;
  font-weight: 400;
  font-size: 1.3rem;
  letter-spacing: 0.13rem;
  text-transform: uppercase;

  /* works perfectly with html2canvas */
  background: none;
  color: rgba(255, 60, 0, 0.25);
  text-shadow:
    2px 2px 3px rgba(255, 80, 0, 0.2),
    -1px -1px 1px rgba(255, 200, 150, 0.1);
	
  opacity: 0.6;
  white-space: nowrap;
  pointer-events: none;
  user-select: none;
}


/* Base styling */
#saveImageBtn {
  display: none;
  position: relative;
  padding: 10px 25px;
  font-size: 14px;
  font-weight: 450;
  color: #fff;
  border: none;
  border-radius: 8px;
  cursor: pointer;
  overflow: hidden;
  transition: all 0.3s ease;
  z-index: 1;
  box-shadow:
    inset 2px 2px 2px rgba(255,255,255,0.4),
    7px 7px 20px rgba(0,0,0,0.15),
    4px 4px 5px rgba(0,0,0,0.1);
}

/* 🌈 Gradient from Button 9 */
#saveImageBtn::after {
  position: absolute;
  content: "";
  z-index: -1;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: linear-gradient(315deg, #1fd1f9 0%, #b621fe 74%);
  transition: all 0.4s ease;
}

/* ✨ Shimmer sweep from Button 11 */
#saveImageBtn::before {
  position: absolute;
  content: "";
  top: -180px;
  left: 0;
  width: 30px;
  height: 100%;
  background: #fff;
  opacity: 0;
  animation: shinyBtnSweep 3s ease-in-out infinite;
  transform: rotate(45deg);
  z-index: 2;
}

@keyframes shinyBtnSweep {
  0% { transform: scale(0) rotate(45deg); opacity: 0; }
  80% { transform: scale(0) rotate(45deg); opacity: 0.5; }
  81% { transform: scale(4) rotate(45deg); opacity: 1; }
  100% { transform: scale(50) rotate(45deg); opacity: 0; }
}

/* 💫 Hover & active glow from Button 9 */
#saveImageBtn:hover {
  background: transparent;
  color: #fff;
  box-shadow:
    4px 4px 6px rgba(255,255,255,0.5),
    -4px -4px 6px rgba(116,125,136,0.2),
    inset -4px -4px 6px rgba(255,255,255,0.5),
    inset 4px 4px 6px rgba(116,125,136,0.3);
}

#saveImageBtn:hover::after {
  transform: scale(1.5) rotate(180deg);
}

#saveImageBtn:active {
  transform: scale(0.98);
  box-shadow:
    inset 2px 2px 4px rgba(255,255,255,0.3),
    inset -2px -2px 4px rgba(0,0,0,0.2);
}
