/* Add some basic styling for the table */
body {
    font-family: Arial, sans-serif;
    background-color: #f4f4f4;
    margin: 0;
    padding: 20px;
}

table {
    width: 100%;
    border-collapse: collapse;
    margin: 20px 0;
    box-shadow: 0 0 10px rgba(0, 0, 0, 0.1);
}

table,
th,
td {
    border: 1px solid #ccc;
}

th,
td {
    padding: 10px;
    text-align: left;
}

th {
    background-color: #4CAF50;
    color: white;
}

.filter-bar {
    margin-bottom: 20px;
    display: flex;
    justify-content: flex-start;
    align-items: center;
}

.filter-bar select {
    padding: 8px;
    margin-left: 10px;
}



/* Hero Section */
.hero {
    background: linear-gradient(rgba(255, 255, 255, 0.1), rgba(255, 255, 255, 0.92)),
        url('/assets/ride-bg.jpg') no-repeat center center;
    background-size: cover;
    padding: 70px 20px;
    text-align: center;
    border-bottom: 1px solid #ddd;
}

.hero-content h1 {
    font-size: 2.4rem;
    color: #2c3e50;
    margin-bottom: 15px;
}

.hero-content .subtitle {
    font-size: 1.4rem;
    color: #34495e;
    margin-bottom: 10px;
}

.hero-content .description {
    font-size: 1rem;
    color: #000000;
    margin-bottom: 25px;
}

/* CTA Button */
.cta-button {
    display: inline-block;
    background-color: #007bff;
    color: #fff;
    padding: 12px 25px;
    border-radius: 6px;
    text-decoration: none;
    font-weight: 600;
    margin-bottom: 20px;
    transition: background-color 0.3s ease;
}

.cta-button:hover {
    background-color: #0056b3;
}

/* Search Bar in Hero */
.hero-search input {
    padding: 10px 15px;
    font-size: 1rem;
    width: 90%;
    max-width: 400px;
    border: 1px solid #ccc;
    border-radius: 6px;
    margin-top: 10px;
}

/* Responsive Design */
@media (max-width: 600px) {
    .hero-content h1 {
        font-size: 1.8rem;
    }

    .hero-content .subtitle {
        font-size: 1.1rem;
    }

    .hero-content .description {
        font-size: 0.95rem;
    }

    .cta-button {
        padding: 10px 20px;
        font-size: 0.95rem;
    }
}


/* Card-style table rows on small screens */
@media (max-width: 768px) {

    table,
    thead,
    tbody,
    th,
    td,
    tr {
        display: block;
    }

    thead {
        display: none;
    }

    tbody tr {
        margin-bottom: 15px;
        background-color: #fff;
        padding: 15px;
        border-radius: 8px;
        box-shadow: 0 0 6px rgba(0, 0, 0, 0.08);
    }

    tbody tr td {
        padding: 8px 12px;
        border: none;
        position: relative;
        padding-left: 50%;
        font-size: 0.95rem;
    }

    tbody tr td::before {
        position: absolute;
        top: 8px;
        left: 12px;
        width: 45%;
        white-space: nowrap;
        font-weight: bold;
        color: #333;
    }

    tbody tr td:nth-of-type(1)::before {
        content: "Ride Type";
    }

    tbody tr td:nth-of-type(2)::before {
        content: "From";
    }

    tbody tr td:nth-of-type(3)::before {
        content: "To";
    }

    tbody tr td:nth-of-type(4)::before {
        content: "Via";
    }

    tbody tr td:nth-of-type(5)::before {
        content: "Note";
    }

    tbody tr td:nth-of-type(6)::before {
        content: "Time";
    }

    tbody tr td:nth-of-type(7)::before {
        content: "Seats";
    }

    tbody tr td:nth-of-type(8)::before {
        content: "Cost / Seat";
    }

    tbody tr td:nth-of-type(9)::before {
        content: "Contact";
    }

    .reveal-contact {
        margin-top: 8px;
    }

    .reveal-contact button {
        padding: 8px 12px;
        font-size: 0.9rem;
    }
}


@media (max-width: 768px) {
    .filter-bar {
        flex-direction: column;
        align-items: flex-start;
    }

    .filter-bar label,
    .filter-bar select {
        margin: 5px 0;
        width: 50%;
        border: 1px solid #ccc;
        border-radius: 6px;
    }
}


.reveal-contact button {
    padding: 10px 16px;
    font-size: 1rem;
    background-color: #4CAF50;
    color: white;
    border: none;
    border-radius: 6px;
    cursor: pointer;
    transition: background-color 0.3s ease;
}

.reveal-contact button:hover {
    background-color: #388e3c;
}

/* Highlighting for ride types */
.available-ride {
    background-color: #e6f9e6;
    /* Light green */
}

.required-ride {
    background-color: #fff3cd;
    /* Light yellow */
}

.expired {
    opacity: 0.6;
    filter: grayscale(40%);
}

/* UPDATED: Visual indicators for expired rides */
.expired-icon::after {
    content: "\1F552 Expired";
    /* Clock Emoji */
    color: #d9534f;
    font-size: 0.9em;
    font-weight: bold;
    margin-left: 5px;
}

/* Better appearance for mobile cards */
@media (max-width: 768px) {
    tbody tr.expired {
        border-left: 5px solid #d9534f;
    }

    tbody tr.expired td::before {
        color: #d9534f;
    }
}


/* Optional: add tooltip */
.expired[title]::after {
    position: relative;
    cursor: help;
}