#eventsTableBody > tr > td > input {
  text-align: center;
}

.event-name-content {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
}

.event-name-content .action-btn {
  width: 100%;
  height: 32px;
  justify-content: flex-start;
}

/* Events Container */
.events-container {
  margin: 4px 4px;
  padding: 4px;
  background-color: #2563eb;
  border-radius: 8px;
}

/* Header */
.events-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  border-bottom: 1px solid #e9ecef;
}

.events-header h3 {
  margin: 0;
  font-size: 1.1rem;
  color: white;
}

.header-buttons {
  display: flex;
  gap: 4px;
}

/* Content Area */
.events-content {
  display: flex;
  flex-direction: column;
  height: calc(100% - 40px); /* Adjust based on header height */
}

/* Table Container */
.events-table-container {
  flex: 1;
  overflow: hidden;
}

/* Table */
.events-table {
  width: 100%;
  border-collapse: collapse;
  table-layout: fixed;
  font-size: 0.8em;
}

/* Table Head */
.events-table thead {
  position: sticky;
  top: 0;
  z-index: 10;
}

.events-table th {
  padding: 5px 0px;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.8);
  background-color: rgba(0, 0, 0, 0.2);
  border: none;
}

/* Table Body */
.events-table tbody {
  display: block;
  overflow-y: auto;
  max-height: calc(100vh - 300px); /* Adjust based on your layout */
}

.events-table tr {
  display: table;
  width: 100%;
  table-layout: fixed;
}

.events-table tbody tr:nth-child(odd) {
  background-color: rgba(255, 255, 255, 0.2);
}

.events-table th,
.events-table td {
  border: 1px solid #e9ecef;
}

.events-table td {
  vertical-align: middle;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.time-adjustment {
  display: flex;
}

.events-table .event-name-content {
  display: flex;
}

.events-table .event-actions-container {
  display: flex;
}

.events-table .group-dropdown {
  flex: 1;
}

/* Column Widths */
.events-table .event-name {
  width: 20%;
}

.events-table .event-time {
  width: 13%;
}

.events-table .event-conditions {
  width: 54%;
}

/* Prayer Dropdown */
.events-table .prayer-dropdown {
  width: 100%;
  cursor: pointer;
}

.events-table .prayer-dropdown:disabled {
  opacity: 0.6;
  cursor: not-allowed;
}

.events-table .prayer-dropdown option {
  background-color: #2c3e50;
  color: white;
}

/* Input Fields */
.event-input {
  width: 100%;
}

.time-adjustment select,
.time-adjustment input {
  font-size: 0.8em;
}

.time-adjustment select {
  min-width: 2.7rem; 
}

.time-adjustment .fraction-input {
  min-width: 2.5rem;
}

.time-adjustment .duration-input {
  min-width: 2.5rem;
}

/* Action Buttons */
.action-btn {
  background: none;
  border: none;
  cursor: pointer;
  border-radius: 3px;
  transition: all 0.2s;
  font-size: 1em;   
}

.action-btn:hover {
  background-color: rgba(255, 255, 255, 0.1);
  color: white;
}

.action-btn.delete:hover {
  background-color: rgba(255, 107, 107, 0.2);
}

/* Save button styles */
.action-btn.save {
  transition: transform 0.2s;
}

.action-btn.save:active {
  transform: scale(0.9);
}

/* Pulsing animation for save button when in edit mode */
@keyframes pulse {
    0% { color: #16a34a; }
    50% { color: #fff; }
    100% { color: #16a34a; }
}

.editing .action-btn.save {
  animation: pulse 2s infinite;
  color: #4CAF50; /* Green color for save button when editing */
}

/* Add Event Button */
.add-event-btn {
  width: 100%;
  background-color: #2563eb;
  border: none;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  font-size: 0.9em;
  color: white;
  transition: all 0.2s ease;
  margin: 0 0 1px 0;
}

/* Save Settings Button */
.save-settings-btn {
  background: none;
  border: none;
  cursor: pointer;
  color: rgba(255, 255, 255, 0.7);
  border-radius: 4px;
  transition: all 0.2s;
  display: flex;
  align-items: center;
  justify-content: center;
}

.save-settings-btn:hover {
  background-color: rgba(255, 255, 255, 0.1);
  color: white;
}

/* Scrollbar */
.events-table-container::-webkit-scrollbar {
  width: 6px;
  height: 6px;
}

.events-table-container::-webkit-scrollbar-track {
  background: rgba(0, 0, 0, 0.1);
  border-radius: 3px;
}

.events-table-container::-webkit-scrollbar-thumb {
  background: rgba(255, 255, 255, 0.2);
  border-radius: 3px;
}

.events-table-container::-webkit-scrollbar-thumb:hover {
  background: rgba(255, 255, 255, 0.3);
}

/* Editable Row */
.editing {
  background-color: rgba(255, 255, 255, 0.05) !important;
}