/* Featured image header */
#header-image {
    display: flex;
    align-items: center;
    width: 100%;
    margin: auto;
    overflow: hidden;
    position: relative;
    float: left;
}

#header-image img {
    width: 100%; /* Set width to 100% of the parent container */
    height: auto; /* Maintain aspect ratio */
    /* max-height: 400px; Optional: limits the height if desired */
}

/* Search box vertical alignment */
#search-form .search-label,
#search-form .search-box-wrapper {
    margin-top: 10px;
}

#search-form .search-form__actions {
    margin-top: 4px;
    margin-bottom: -5px;
}/* Phone layout only */
@media (max-width: 767px) {

    /* Reduce space around the college logo */
    #app-header {
        padding-top: 12px !important;
        padding-bottom: 12px !important;
    }

    #app-header .header-branding,
    #app-header .logo-customized {
        margin: 0 !important;
        padding: 0 !important;
        height: auto !important;
        min-height: 0 !important;
    }

    #app-header .logo-customized img {
        display: block;
        width: 100% !important;
        max-width: 360px !important;
        height: auto !important;
        margin: 0 auto;
    }

    #app-header #header-menu {
        margin-top: 12px !important;
        margin-bottom: 0 !important;
        padding-top: 0 !important;
        min-height: 0 !important;
    }

    /* Readable alternative to the wide desktop banner */
    #home-page #header-image {
        display: block;
        float: none;
        box-sizing: border-box;
        padding: 18px 16px;
        background: #1d3154;
        color: #ffffff;
        text-align: center;
    }

    #home-page #header-image img {
        display: none;
    }

    #home-page #header-image::before {
        content: "Course Catalog";
        display: block;
        font-family: Georgia, serif;
        font-size: 28px;
        font-weight: bold;
        line-height: 1.2;
    }

    #home-page #header-image::after {
        content: "Select a course for details. Use the page numbers below the listings to see more courses.";
        display: block;
        margin-top: 8px;
        font-size: 15px;
        line-height: 1.5;
    }

    /* Compact search and filter controls */
    #search-form,
    #search-form .search-form-container {
        padding-top: 10px !important;
        padding-bottom: 10px !important;
    }

    #search-form .search-form {
        display: flex;
        flex-direction: column;
        gap: 10px;
    }

    #search-form .search-box-wrapper {
        width: 100% !important;
        margin: 0 !important;
    }

    #search-form .search-form__actions {
        float: none !important;
        margin: 0 !important;
        align-self: flex-end;
    }

    /* Bring courses closer to the top */
    #home-page #main-heading {
        padding-top: 18px !important;
        padding-bottom: 0 !important;
        margin-top: 0 !important;
        margin-bottom: 0 !important;
    }

    #home-page #main-heading h1 {
        font-size: 28px !important;
        line-height: 1.2 !important;
        margin: 0 0 10px !important;
    }

    #home-page #listings {
        padding-top: 10px !important;
    }

    #home-page #listings h2 {
        font-size: 22px !important;
        line-height: 1.3 !important;
        margin: 0 0 16px !important;
    }
}