#calendar {
	display: block !important;
	visibility: visible !important;
	height: auto !important;
	min-height: 400px;
  max-height: none !important; /* <-- try this */
	background: rgb(255, 255, 255);
  }

.calendar-wrapper,
.calendar-section,
.main-content {
  display: block;
  width: 100%;
  height: auto;
  overflow: visible !important;
}

@media (max-width: 768px) {
  #event-filters {
    display: block !important;
  }

  select[name="event-category"] {
    display: none !important;
  }
}

  
  .fc-tooltip {
	position: absolute;
	z-index: 10001;
	background: #000;
	color: #fff;
	padding: 8px 12px;
	border-radius: 5px;
	max-width: 250px;
	font-size: 16px !important;
	box-shadow: 0 0 10px rgba(0,0,0,0.5);
	pointer-events: none;
  }
  
  .fc .fc-day-today {
	background-color: #E90802 !important;
	color: white;
  }
  
  .fc .fc-daygrid-day-number,
  .fc .fc-col-header-cell a {
	color: inherit !important;
	text-decoration: none !important;
	pointer-events: none;
	cursor: default;
  }
  
  .fc-event {
	background-color: #ffffff00 !important;
	color: #000000 !important;
	border: none !important;
  }
  
  .fc-event-title {
	font-size: 16px !important;
	font-weight: bold;
  }
  
  .fc-col-header-cell-cushion {
	font-size: 16px !important;
	font-weight: 600;
  }
  
  .fc-daygrid-day-number {
	font-size: 14px !important;
	color: inherit;
	text-decoration: none !important;
  }
  
  .fc-daygrid-day-number:hover {
	cursor: default;
  }
  
  @media (max-width: 768px) {
	.fc-list-event {
	  font-size: 16px;
	}
  
	.fc .fc-toolbar {
	  flex-direction: column;
	  align-items: flex-start;
	}
  
	.fc .fc-toolbar-title {
	  font-size: 20px;
	  margin-bottom: 10px;
	  font-weight: 700;
	}
  
	.fc .fc-button {
	  font-size: 14px;
	  padding: 6px 10px;
	  background-color: #E90802;
	  border: none;
	  color: white;
	}
  }
  
  .fc-list-event {
	padding: 10px;
	border-bottom: 1px solid #ddd;
  }
  
  .fc-list-event:hover {
	background-color: #f8f8f8;
  }
  
  .fc .fc-button:hover {
	background-color: #a00602;
  }
  
  .fc-theme-standard .fc-list, 
  .fc .fc-list-table {
	background-color: rgba(255, 255, 255, 0);
	color: black;
	font-size: 14px;
  }
  
  .fc-event-title, 
  .fc-list-event-title {
	font-weight: 600;
	color: #000000;
  }
  
  .fc-list-event-time {
	font-style: italic;
	color: #444;
  }
  
  .fc-tooltip-header {
	font-size: 16px;
	font-weight: bold;
	margin-bottom: 6px;
  }
  
  .fc-tooltip-date {
	font-style: italic;
	color: #666;
	margin-bottom: 8px;
  }
  
  .fc-tooltip-desc {
	color: #333;
  }
  
  /* General event style */
  .fc-event {
	border: none !important;
	color: white !important;
	font-weight: bold;
	padding: 2px 6px;
	border-radius: 4px;
  }
  
  /* Department color codes */
  .fc-event.che { background-color: #71b6ff !important;; } /* Blue */
  .fc-event.cece { background-color: #86ce96 !important;; } /* Green */
  .fc-event.cs { background-color: #ad89f0 !important;; } /* Purple */
  .fc-event.ece { background-color: #ffb67b !important;; } /* Orange */
  .fc-event.imse { background-color: #b1b1b1 !important;; } /* Teal */
  .fc-event.me { background-color: #d47c85 !important;; } /* Red */
  .fc-event.pe { background-color: #ffde79; color: #ffffff !important; } /* Yellow */
  .fc-event.performances { background-color: #747474 !important;; } /* Dark */
  .fc-event.deadline { background-color: #6bc2cf !important;; } /* Cyan */
  .fc-event.so { background-color: #8754da !important;; } /* Indigo */
  .fc-event.eoc { background-color: #ff9dcb !important;; } /* Pink */
  
  .modal-overlay {
	position: fixed;
	top: 0;
	left: 0;
	width: 100%;
	height: 100%;
	background: rgba(0,0,0,0.7);
	display: flex;
	align-items: center;
	justify-content: center;
	z-index: 20000;
  }
  
  .modal-content {
	background: #fff;
	color: #000;
	padding: 20px;
	max-width: 500px;
	width: 90%;
	border-radius: 8px;
	position: relative;
	box-shadow: 0 5px 20px rgba(0,0,0,0.3);
	font-family: Arial, sans-serif;
  }
  
  .close-modal {
	position: absolute;
	top: 10px;
	right: 16px;
	font-size: 24px;
	cursor: pointer;
  }
  
  .event-modal {
	display: none;
	position: fixed;
	z-index: 9999;
	left: 0; top: 0;
	width: 100%; height: 100%;
	background-color: rgba(0,0,0,0.6);
	justify-content: center;
	align-items: center;
  }
  
  .event-modal.show {
	display: flex;
  }
  
  .modal-content {
	background-color: #fff;
	padding: 30px;
	border-radius: 8px;
	width: 90%;
	max-width: 600px;
	max-height: 80vh;
	overflow-y: auto;
	box-shadow: 0 0 20px rgba(0,0,0,0.4);
	position: relative;
	animation: fadeIn 0.3s ease-in-out;
  }
  
  .modal-close {
	position: absolute;
	top: 10px;
	right: 15px;
	font-size: 1.5rem;
	cursor: pointer;
	color: #aaa;
  }
  
  .modal-close:hover {
	color: #000;
  }
  
  @keyframes fadeIn {
	from { opacity: 0; transform: translateY(-20px); }
	to { opacity: 1; transform: translateY(0); }
  }
  
#event-filters input[type="radio"] {
  display: none;
}

/* Style for JavaScript-applied active filter */
#event-filters label.active-filter {
  background-color: #E90802 !important;
  color: #fff !important;
  font-weight: bold !important;
}


#event-filters label {
  display: block;
  padding: 10px 14px;
  margin-bottom: 6px;
  background-color: #f2f2f2;
  color: #333;
  border-radius: 5px;
  cursor: pointer;
  font-size: 14px;
  transition: all 0.3s ease;
}

#event-filters input[type="radio"]:checked + label {
  background-color: #E90802;
  color: #fff;
  font-weight: bold;
}

@media (max-width: 768px) {
  #event-filters li {
    margin-bottom: 10px;
    width: 100%;
  }

  #event-filters label {
    display: block;
    width: 100%;
    padding: 12px 16px !important;
    background-color: #f2f2f2;
    color: #333;
    font-size: 10px !important;
    border-radius: 6px;
    text-align: center;
    cursor: pointer;
    transition: all 0.3s ease;
  }

  #event-filters input[type="radio"] {
    display: none !important;
  }

  #event-filters input[type="radio"]:checked + label {
    background-color: #E90802 !important;
    color: #fff !important;
    font-weight: bold !important;
  }

  aside h4 {
    font-size: 8px;
    text-align: center;
    margin-bottom: 1rem;
  }

  aside {
    width: 100% !important;
    margin-bottom: 2rem;
  }
}

#event-filters input[type="radio"] {
  display: none;
}

#event-filters label {
  display: block;
  padding: 10px 14px;
  margin-bottom: 6px;
  background-color: #f2f2f2;
  color: #333;
  border-radius: 5px;
  cursor: pointer;
  font-size: 14px;
  transition: all 0.3s ease;
}

/* 🔴 This controls the active state */
#event-filters label.active-filter {
  background-color: #E90802 !important;
  color: #fff !important;
  font-weight: bold !important;
}

#event-filters label.active-filter {
  background-color: #E90802 !important;
  color: #fff !important;
  font-weight: bold !important;
}

/* Only show mobile dropdown on small screens */
#mobile-filter {
  display: none;
}

@media (max-width: 768px) {
  #mobile-filter {
    display: block;
  }

  #desktop-filter {
    display: none;
  }

  #calendar {
    width: 100% !important;
  }
}

#event-filters input[type="radio"] {
  display: none;
}

#event-filters label {
  display: block;
  padding: 10px 14px;
  margin-bottom: 6px;
  background-color: #f2f2f2;
  color: #333;
  border-radius: 5px;
  cursor: pointer;
  font-size: 14px;
  transition: all 0.3s ease;
}

#event-filters input[type="radio"]:checked + label {
  background-color: #E90802;
  color: #fff;
  font-weight: bold;
}

/* === CATEGORY COLOR LINES (FILTER SIDEBAR) === */
#event-filters label {
  position: relative;
  padding-left: 20px; /* Make space for the color line */
}

#event-filters label::before {
  content: "";
  position: absolute;
  left: 6px;
  top: 50%;
  transform: translateY(-50%);
  width: 6px;
  height: 70%;
  border-radius: 3px;
  background-color: #ccc; /* default fallback color */
}

/* Specific department colors matching calendar events */
#event-filters label.che::before { background-color: #71b6ff; }         /* Blue */
#event-filters label.cece::before { background-color: #86ce96; }        /* Green */
#event-filters label.cs::before { background-color: #ad89f0; }          /* Purple */
#event-filters label.ece::before { background-color: #ffb67b; }         /* Orange */
#event-filters label.imse::before { background-color: #b1b1b1; }        /* Gray */
#event-filters label.me::before { background-color: #d47c85; }          /* Red */
#event-filters label.pe::before { background-color: #ffde79; }          /* Yellow */
#event-filters label.performances::before { background-color: #747474; }/* Dark */
#event-filters label.deadline::before { background-color: #6bc2cf; }    /* Cyan */
#event-filters label.so::before { background-color: #8754da; }          /* Indigo */
#event-filters label.eoc::before { background-color: #ff9dcb; }         /* Pink */
