
/* events.css */

/* Search Section Styles */
.search-section {
  background-color: #ff5c00; /* Primary orange background */
  padding: 20px;
  margin: 0;
  border-radius: 8px;
}

/* Form Styles */

#search-form {
  background-color: white;
  border-radius: 8px;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1); /* Subtle shadow effect */
  padding: 20px;
}

/* Input and Select Fields */
#search-form .form-control,
#search-form .input-group {
  height: 40px; /* Standard height for better usability */
  font-size: 14px;
  border-radius: 6px;
  padding: 5px 10px; /* Padding inside inputs and selects */
  border: 1px solid #ccc; /* Default border for all inputs */
  transition: border-color 0.3s ease, box-shadow 0.3s ease; /* Smooth transition for focus effect */
}

#search-form .row > div {
  padding: 0 10px; /* Adjusted horizontal padding */
}

#search-form .col-md-2 {
  padding: 0; /* Remove column padding for better alignment */
  display: flex;
  flex-direction: column;
}

/* Button Styles */
#search-form .btn {
  position: relative;
  top: -19px; /* Move the button 10px upwards */
  font-size: 16px; /* Button text size */
  font-weight: bold; /* Make text bold */
  color: white; /* White text */
  background-color: #e74c3c; /* Red color for button */
  text-transform: uppercase; /* Uppercase text */
  padding: 7px 10px; /* Adequate padding */
  letter-spacing: 1px; /* Letter spacing for better legibility */
  border: none;
  border-radius: 6px; /* Rounded corners */
  transition: background-color 0.3s ease; /* Smooth transition for hover effect */
  width: 100%; /* Ensure the button takes full width */
  margin-left: 0; /* Remove margin between button and input fields */
}

#search-form .btn:hover {
  background-color: #ff5c00; /* Hover effect with primary color */
}

#search-form .btn:focus {
  outline: none;
  box-shadow: 0 0 5px rgba(213, 3, 47, 0.5); /* Shadow effect on focus */
}

/* Additional Styles for Better Layout */
#search-form .row {
  display: flex;
  justify-content: space-between; /* Ensure fields are spaced evenly */
  margin-bottom: 0px; /* Reduced space between rows */
}

#search-form .col-md-4 {
  flex: 1;
  min-width: 100px; /* Ensure columns have a minimum width */
}

#search-form .form-control,
#search-form select {
  width: 100%; /* Ensure inputs and selects span the entire width of their container */
}

/* Floating Label - Fix for Select Dropdowns */
.floating-label {
  position: relative;
  width: 100%;
  margin-bottom: 20px; /* Ensure there's space for the label */
}

.floating-label label {
  position: absolute;
  top: 50%;
  left: 12px;
  transform: translateY(-50%); /* Center label vertically */
  font-size: 14px;
  color: #666;
  background-color: white;
  padding: 0 5px;
  transition: all 0.3s ease; /* Smooth transition for label */
  pointer-events: none; /* Prevent label from blocking interaction with the field */
}

/* When select is focused or has a value */
.floating-label select:focus + label,
.floating-label select:not(:empty) + label {
  top: -10px;
  left: 10px;
  font-size: 12px;
  color: #ff5c00; /* Highlight color */
  background: white;
  padding: 0 5px;
}

/* Ensure Select Dropdown Has Some Padding */
.floating-label select {
  width: 100%;
  padding: 10px;
  border: 1px solid #ccc;
  border-radius: 6px;
  background: white;
  font-size: 14px;
  transition: border-color 0.3s ease, box-shadow 0.3s ease; /* Focus effect on border and shadow */
}

/* Focus Effect */
.floating-label select:focus {
  border-color: #ff5c00; /* Change border color when focused */
  box-shadow: 0 0 5px rgba(255, 92, 0, 0.5); /* Soft shadow on focus */
  outline: none; /* Remove default outline */
}

/* Responsive Design (for smaller screens) */
@media (max-width: 768px) {
  #search-form .row {
    flex-direction: column; /* Stack form fields on mobile */
  }

  #search-form .col-md-4 {
    margin-bottom: 10px; /* Add margin between stacked fields */
  }

  #search-form .btn {
    width: auto; /* Set button width to auto */
    margin-left: 0; /* Remove margin on mobile */
    padding: 5px 10px; /* Adjust padding for better fit */
    position: relative;
    top: 0; /* Remove upward shift of button on smaller screens */
  }
}

/* Event Tile Design */
.event-tile {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;  /* Prevent content from overflowing */
  width: 100%;  /* Ensure tile doesn't exceed container */
  max-width: 100%;  /* Prevent stretching */
  border: 1px solid #ddd;
  border-radius: 10px;
  padding: 15px;
  transition: box-shadow 0.3s ease-in-out;
  height: auto; /* Allow flexible height */
  background: white;
  overflow: hidden; /* Prevent content overflow */
}

.event-tile:hover {
  box-shadow: 0px 4px 10px rgba(0, 0, 0, 0.2);
}

/* Image Styling */
.event-image img {
  width: 120px; /* Fixed image width */
  height: 120px;
  object-fit: cover; /* Ensures image stays within bounds */
  border-radius: 8px;
}

/* Event Details */
.event-details {
  flex-grow: 1;
  overflow: hidden; /* Prevent text overflow */
}

.event-details p {
  white-space: nowrap; /* Prevents text wrapping */
  overflow: hidden;
  text-overflow: ellipsis; /* Adds '...' if text is too long */
}

/* Action Icon */
.action-icon {
  font-size: 18px;
  cursor: pointer;
}

/* Responsive Fixes */
@media (max-width: 768px) {
  .event-tile {
      flex-direction: column;
      align-items: flex-start;
  }

  .event-image img {
      width: 100%; /* Full width for smaller screens */
      height: auto;
  }
}
