.timetable-header {
    text-transform: uppercase;
}

.timetable-table {
    width: 100%;
    border-collapse: collapse; /* Keeps borders distinct */
    border-spacing: 0;
    border-radius: 10px; /* Rounded corners */
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1); /* Adds a subtle shadow for depth */
    overflow: hidden;
    table-layout: fixed; /* Ensures columns have a consistent width */
}

.timetable-table th, .timetable-table td {
    padding: 10px; /* Generous padding for improved readability */
    text-align: center;
    transition: background-color 0.3s ease; /* Smooth background transition */
}

.timetable-table th {
    background: #06477e; /* Gradient background for header */
    color: #fff;
    font-weight: bold;
    text-transform: uppercase;
    font-size: 1.1em;
}

.timetable-table tbody tr:nth-child(even) {
    background-color: #f8f9fa; /* Light grey background for alternating rows */
}

.timetable-table tbody tr:hover {
    background-color: #e8f4f8; /* Change background color on hover */
    box-shadow: 0 0 10px rgba(0, 0, 0, 0.10); /* Adds subtle shadow on hover */
    transition: transform 0.3s ease, box-shadow 0.3s ease; /* Smooth hover animation */
}

.timetable-table td {
    border-bottom: 1px solid #ddd; /* Light border for separation */
    vertical-align: middle; /* Aligns text nicely */
    color: #06477d;
}

.timetable-table a {
    text-decoration: none;
    color: #fff; /* Consistent with the gradient colours */
    background-color: #06477d;
    border-radius: 999px;
    padding: 5px 15px;
    font-weight: bold;
    transition: color 0.3s ease, transform 0.3s ease; /* Transition for link hover */
}

.timetable-table a:hover {
    color: #e63946; /* Red highlight for link hover effect */
    transform: scale(1.05); /* Slight increase in size for focus */
}

/* Accordion Header Styling */
.timetable-accordion h3.accordion-header {
    background-color: #06477d; /* Header background colour */
    color: #fff;
    margin: 10px 0; 
    padding: 10px;
    cursor: pointer;
    border-radius: 5px;
    transition: background-color 0.3s ease, transform 0.3s ease; /* Smooth hover animation */
}


.timetable-accordion h3.accordion-header:hover {
    background-color: #06477d;
    transform: none;
}

/* Accordion Content Styling */
.timetable-accordion .accordion-content {
    padding: 20px;
    background-color: #f1f5f9;
    border: 1px solid #d3d3d3; /* Border to distinguish content */
    margin-top: 0px;
    border-radius: 5px;
    display: none; /* Accordion content hidden by default */
    transition: all 0.4s ease; /* Smooth animation */
}

.timetable-accordion .accordion-item.active .accordion-content {
    display: block; /* Show accordion content when active */
}

/* Section Headings for Accordion */
.timetable-accordion h4 {
    color: #06477e;
    text-transform: uppercase;
    font-size: 1.2em;
    border-bottom: 2px solid #009fe3;
    margin-bottom: 10px;
    margin-top: 0;
}

.timetable-accordion h5 {
    color: #009fe3;
    font-size: 1.2em;
    margin-top: 20px;
    margin-bottom: 10px;
}

/* General transition effects for smooth experience */
.timetable-table td, .timetable-table th {
    transition: all 0.3s ease-in-out;
}

/* Responsive Styling for Mobile Devices */
@media (max-width: 768px) {
    .timetable-table, .timetable-table thead, .timetable-table tbody, .timetable-table th, .timetable-table td, .timetable-table tr {
        display: block; /* Makes the table behave like blocks */
    }

    .timetable-table thead {
        display: none; /* Hide the table headers */
    }

    .timetable-table tr {
        margin-bottom: 20px; /* Add space between each "card" */
        box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1); /* Card-like shadow for each row */
        border: 1px solid #ddd;
        border-radius: 10px;
        padding: 15px;
    }

    .timetable-table td {
        display: flex;
        justify-content: space-between;
        align-items: center;
        padding: 10px;
        border: none; /* Remove individual cell borders */
        position: relative;
        text-align: right;
    }

    .timetable-table td::before {
        content: attr(data-label);
        font-weight: bold;
        color: #06477e;
        flex-basis: 50%;
        text-align: left;
        padding-right: 10px;
    }

    /* Improved Accordion Header for Mobile */
    .accordion-header {
        font-size: 1.3em;
        padding: 15px 20px;
    }

    .accordion-content {
        padding: 20px;
        margin: 0;
        border-radius: 0;
        box-shadow: none;
    }
}

/* Button Styles */
.filter-actions {
    margin-bottom: 15px;
}

#toggle-past-activities {
    background-color: #009fe3;
    color: #fff;
    border: none;
    padding: 10px 20px;
    border-radius: 5px;
    cursor: pointer;
    transition: background-color 0.3s ease, transform 0.3s ease;
}

#toggle-past-activities:hover {
    background-color: #06477e;
    transform: translateY(-2px);
}