/* General  */
body {
    font-family: Arial, sans-serif;
    margin: 0;
    padding: 0;
}

a {
    text-decoration: none;
    color: white;
}

/* Header stuff */
header {
    background-color: #7b35d0;
    color: #fff;
    padding: 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

/* Search Container  */
.search-container {
    margin: 2rem auto;
    width: 80%;
    max-width: 880px;
}

.search-container form {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
}

.search-container input[type="text"] {
    margin-right: 1rem;
    padding: 0.5rem;
    border: 1px solid #ccc;
    border-radius: 4px;
    width: 89%;
}

.search-container button {
    padding: 0.5rem 1rem;
    background-color: #007bff;
    color: #fff;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    margin-top: 1rem;
}

/* Filter Container */
.filter-container {
    margin-top: 1rem;
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: flex-start; 
    gap: 10px; 
    width: 100%;
}

.filter-container label {
    font-size: 0.9rem;
    min-width: 100px; 
    margin-right: 0px; 
}

.filter-container select {
    padding: 0.5rem;
    border: 1px solid #ccc;
    border-radius: 4px;
    width: 150px;
    min-width: 150px; 
}


/* Results Container */
.results-container {
    margin-top: 2rem;
    display: flex;
    flex-wrap: wrap;
    gap: 1rem;
    padding-left: 2rem; 
    padding-bottom: 2rem;
}

.result-item {
    width: calc(33% - 1rem);
    padding: 1rem;
    border: 2px solid #7b35d0;
    border-radius: 8px;
    box-sizing: border-box;
}

.result-item h3 {
    color: #7b35d0;
    font-weight: bold;
    margin-bottom: 0.5rem;
}

.result-item p {
    margin: 0.5rem 0;
}

.meeting-times-label {
    font-weight: bold;
    color: #7b35d0;
    margin-bottom: 5px;
}

.description-container {
    padding: 10px;
    margin-bottom: 10px;
    font-style: italic;
}


/* Modal */
.modal {
    display: none;
    position: fixed;
    z-index: 1;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    overflow: auto;
    background-color: rgba(0, 0, 0, 0.4);
}

.modal-content {
    background-color: #fff;
    margin: 10% auto;
    padding: 20px;
    border: 1px solid #ccc;
    border-radius: 8px;
    width: 60%;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
}

.close {
    color: #aaa;
    float: right;
    font-size: 28px;
    font-weight: bold;
}

.close:hover,
.close:focus {
    color: #333;
    text-decoration: none;
    cursor: pointer;
}

/* Edit button */
.edit-button {
    padding: 6px 12px;
    font-size: 14px;
    background-color: #007bff;
    color: #fff;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    font-family: Arial, sans-serif;
    display: inline-block; 
}

/* delete button */
.delete-button {
    padding: 6px 12px;
    color: #fff;
    background-color: #ff0000;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    font-family: Arial, sans-serif;
    margin-left: 5px; 
}


/* Edit form */
#editForm {
    margin: 2rem auto;
    padding: 20px;
    border: 1px solid #ccc;
    border-radius: 8px;
    font-family: Arial, sans-serif;
    max-width: 850px;
}

#editForm label {
    font-weight: bold;
    margin-bottom: 0.5rem;
    color: #333;
}

#editForm input[type="text"],
#editForm input[type="date"],
#editForm input[type="time"],
#editForm input[type="number"],
#editForm textarea,
#editForm select {
    width: calc(100% - 10px);
    padding: 8px;
    margin-bottom: 1rem;
    border: 1px solid #ccc;
    border-radius: 4px;
    box-sizing: border-box;
    font-family: Arial, sans-serif;
}

#editForm textarea {
    height: 100px;
}

#editForm .meeting-times-container {
    border: 1px solid #ccc;
    border-radius: 4px;
    padding: 10px;
    margin-bottom: 1rem;
    max-height: 200px;
    overflow-y: auto;
}

#editForm .meeting-time-field {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 0.5rem;
}

#editForm .meeting-time-field label {
    width: 80px;
    text-align: right;
}

#editForm .meeting-time-field input[type="text"],
#editForm .meeting-time-field select,
#editForm .meeting-time-field input[type="time"] {
    padding: 8px;
    border: 1px solid #ccc;
    border-radius: 4px;
    font-family: Arial, sans-serif;
    width: 120px;
    height: 40px
}

#editForm .meeting-time-field button[type="button"] {
    padding: 10px 10px;
    background-color: #ff0000;
    color: #fff;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    font-family: Arial, sans-serif;
    margin-top: 0rem;
}


#editForm button[type="submit"] {
    padding: 10px 20px;
    background-color: #00b336;
    color: #fff;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    font-family: Arial, sans-serif;
    margin-top: 1rem;
}

#editForm button[type="button"]{
    padding: 10px 10px;
    background-color: #007bff;
    color: #fff;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    font-family: Arial, sans-serif;
    margin-top: 1rem;
    margin-bottom: 1rem;
}



/* Join button */
.join-button {
    background-color: #00b336;
    border: none;
    color: white;
    padding: 10px 20px;
    text-align: center;
    text-decoration: none;
    display: inline-block;
    font-size: 16px;
    margin: 4px 2px;
    transition-duration: 0.4s;
    cursor: pointer;
    border-radius: 8px;
}


/* Leave button */
.leave-button {
    background-color: #ff0000; 
    border: none;
    color: white;
    padding: 10px 20px;
    text-align: center;
    text-decoration: none;
    display: inline-block;
    font-size: 16px;
    margin: 4px 2px;
    transition-duration: 0.4s;
    cursor: pointer;
    border-radius: 8px;
}

/* Participant list*/
.participant-list {
    border: 2px solid #7b35d0;
    padding: 10px;
    margin-right: 20px;
    flex: 1;
    max-width: 50%;
    overflow-y: auto;
    padding-top: 0;
    margin-bottom: 0.5rem;
    
}
.participant-list ul{
   list-style: none;
   padding-left: 0;
}

/*kick button*/
.kick-button {
    background-color: #ff0000;
    color: white;
    border: none;
    padding: 5px 10px;
    border-radius: 5px;
    cursor: pointer;
    margin-left: 10px; 
}

/* Message form */
#messageForm {
    margin-top: 20px;
    border: 1px solid #ccc;
    padding: 20px;
    background-color: #f9f9f9;
    border-radius: 5px;
}
#messageForm input[type="text"],
#messageForm textarea {
    width: 27.5rem; 
    padding: 8px;
    border: 1px solid #ccc;
    border-radius: 5px;
    resize: none;
   
}

#messageForm h3 {
    margin-bottom: 10px;
}

#messageForm .input-group {
    margin-bottom: 15px;
}

#messageForm label {
    display: block;
    font-weight: bold;
}

#messageForm textarea {
    height: 100px;
}

#messageForm .send-message-button {
    background-color: #00b336;
    color: white;
    padding: 10px 20px;
    border: none;
    border-radius: 5px;
    cursor: pointer;
}


/* Message button */
.message-button {
    background-color: #007bff;
    color: white;
    border: none;
    padding: 5px 10px;
    border-radius: 5px;
    cursor: pointer;
    margin-top: 0.3rem;
}

/* cancel button */
.cancel-button {
    background-color: #ff0000;
    color: white;
    padding: 10px 20px;
    margin-right: 10px;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    
}



/* send button */
.send-button {
    background-color: #00b336;
    color: white;
    padding: 10px 20px;
    border: none;
    border-radius: 5px;
    cursor: pointer;
}

/* Message form modal */
.message-modal {
    display: none;
    position: fixed;
    z-index: 2; /* higher than the studygroup modal */
    left: 50%;
    top: 50%;
    transform: translate(-50%, -50%);
    width: 50%; 
    max-width: 500px; 
    padding: 20px;
    background-color: #ffffff;
    border: 2px solid #7b35d0;
    border-radius: 5px;
}

.message-modal-content {
    margin-bottom: 10px;
}

/* Notification Modal */
#notificationModal {
    display: none;
    position: fixed;
    z-index: 1;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    overflow: auto;
    background-color: rgba(0, 0, 0, 0.4);
}

/* Modal Content */
#notificationModal .modal-content {
    background-color: #fefefe;
    margin: 15% auto;
    padding: 20px;
    border: 1px solid #888;
    width: 80%;
    border-radius: 10px;
    color: black;
    width: 30rem;
    
}

/* Close Button */
#notificationModal .close {
    color: #aaa;
    float: right;
    font-size: 28px;
    font-weight: bold;
}

#notificationModal .close:hover,
#notificationModal .close:focus {
    color: black;
    text-decoration: none;
    cursor: pointer;
}

/* Notification Item */
.notification-item {
    padding: 10px;
    border-bottom: 1px solid #ddd;
    cursor: pointer;
}

.notification-item:hover {
    background-color: #f9f9f9;
}


#notificationBtn {
    float: right;
    padding: 14px 20px;
    margin-right: 20px; 
}

/* Notification Details Modal--------------- */
#notificationDetailsModal {
    display: none;
    position: fixed;
    z-index: 1;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    overflow: auto;
    background-color: rgba(0, 0, 0, 0.4);
}

/* Modal Content */
#notificationDetailsModal .modal-content {
    background-color: #fefefe;
    margin: 15% auto;
    padding: 20px;
    border: 1px solid #888;
    width: 80%;
    max-width: 500px;
    border-radius: 10px;
    color: black;
}

/* Close Button */
#detailsClose {
    color: #aaa;
    float: right;
    font-size: 28px;
    font-weight: bold;
}

#detailsClose:hover,
#detailsClose:focus {
    color: black;
    text-decoration: none;
    cursor: pointer;
}

/* Notification Details */
#detailsSubject {
    margin-top: 0;
    font-size: 24px;
    font-weight: bold;
}

#detailsSender {
    font-size: 16px;
    color: #555;
    margin-bottom: 10px;
}

#detailsBody {
    font-size: 16px;
    line-height: 1.5;
}

