/* Template A1IT */

/*--------------------------------------------------------
    Text styles
--------------------------------------------------------*/
    
    html {
        --primary: #303543;
        /* REPLACE:COLOR_1 */
        --accent: #27B4E0;
        /* REPLACE:COLOR_2 */
        --text: #545454;
        overflow-x: hidden;
        font-size: 17px;
        font-family: 'Roboto', sans-serif;
    }
    
    body {
        font-family: inherit !important;
        font-size: inherit !important;
        /* Properties !important'd to prevent the MMS pages with body styles from overwriting them */
        color: var(--text);
    }
    
    p {
        margin-bottom: .75em;
    }
    /*--------------------------------------------------------
    Headings
--------------------------------------------------------*/
    
    h1,
    h2,
    h3,
    h4,
    h5,
    h6 {
        margin: 0 0 .75em;
        padding: 0px;
        font-family: 'Montserrat', sans-serif;
        text-transform: capitalize;
    }
    
    h1 {
        font-size: 35px;
    }
    
    h2 {
        font-size: 33px;
    }
    
    h3 {
        font-size: 30px;
    }
    
    h4 {
        font-size: 27px;
    }
    
    h5 {
        font-size: 24px;
    }
    
    h6 {
        font-size: 20px;
    }
    /*--------------------------------------------------------
LINKS
--------------------------------------------------------*/
    
    a {
        color: var(--accent);
        transition: filter .125s ease-in-out
    }
    
    a:is(:focus, :hover) {
        color: var(--accent);
    }
    
    main a:not(nav a):not(.carousel a):is(:hover, :focus) {
        filter: brightness(.8);
    }
    /*--------------------------------------------------------
    Objects
--------------------------------------------------------*/
    
    .offscreen {
        /* This class allows an element to be read by a screenreader without appearing in the viewport  */
        position: absolute;
        left: -666vw;
    }
    
    .row_background {
        background-color: var(--primary);
        color: #fff;
    }
    
    .row_background *:not(input) {
        color: #fff;
    }
    
    .row_background input {
        color: var(--text);
    }
    /*  Wrappers
    *.wrapper acts as a more symantic stand in for <container><row><col-md-12></col-md-12></row></container> in sections of this build that don't require stacking columns 
 */
    
    .wrapper {
        margin-right: auto;
        margin-left: auto;
        max-width: 100%;
        position: relative;
        height: inherit;
        padding-left: 15px;
        padding-right: 15px;
    }
    
    .full-width {
        /* Make an element span the width of the viewport */
        --side-margin: calc((100vw - var(--page-width) + 13px) / -2);
        /* 13px to compensate for width of scrollbar */
        position: relative;
        left: var(--side-margin);
        right: var(--side-margin);
        width: calc(100vw + 13px);
    }
    
    #gm-canvas .full-width {
        left: unset;
        right: unset;
        width: unset;
    }
    
    @media (min-width:992px) {
         :root {
            --page-width: 970px;
        }
        .wrapper {
            width: 970px;
        }
    }
    
    @media (min-width:1200px) {
         :root {
            --page-width: 1170px;
        }
        .wrapper {
            width: 1170px;
        }
    }
    
    @media (max-width: 990px) {
        .container,
        .wrapper {
            /* Extra wiggle room at a breakpoint that needs it  */
            width: 100%;
        }
        .full-width {
            --side-margin: unset;
            left: unset;
            right: unset;
            width: unset;
        }
    }
    
    .row_background {
        color: white;
        position: relative;
        padding-top: 2rem;
        padding-bottom: 2rem;
    }
    
    .row_background::before {
        content: '';
        position: absolute;
        top: 0;
        bottom: 0;
        left: -666vw;
        right: -666vw;
        display: block;
        background-color: var(--primary);
    }
    
    .row_background *:not(input) {
        color: white;
    }
    
    @media (max-width: 767px) {
        .row_background {
            padding-top: 1rem;
            padding-bottom: 1rem;
        }
    }
    /*--------------------------------------------------------
                HEADER
--------------------------------------------------------*/
    
    #header-top {
        position: relative;
        display: flex;
        justify-content: flex-end;
        align-items: center;
    }
    
    #header-top::before,
    header::before,
    footer::before {
        content: '';
        position: absolute;
        left: -666vw;
        right: -666vw;
        top: 0;
        bottom: 0;
        background: var(--primary);
        z-index: -1;
    }
    
    @media (max-width: 767px) {
        #header-top {
            display: none;
        }
    }
    
    header::before {
        opacity: .9;
    }
    
    #header-top a {
        color: white;
    }
    /* --- Search ---  */
    
    .searchbox {
        outline: 1px solid white;
        max-width: 100%;
        position: relative;
        width: 230px;
        height: 2em;
        transition: outline .25s ease-in-out;
        overflow: hidden;
        margin: .5em 2ch;
    }
    
    .searchbox:focus-within {
        outline: 2px solid var(--accent);
    }
    
    .search-input {
        border: none;
        padding: .5em 1ch;
        position: absolute;
        top: 0;
        left: 0;
        right: 0;
        bottom: 0;
    }
    
    .search-input:focus {
        outline: none;
    }
    
    .search-button {
        position: absolute;
        right: 0;
        top: 0;
        bottom: 0;
        border: 0;
        width: 2em;
        background-image: url(../images/search-icon.png);
        background-repeat: no-repeat;
        background-position: center;
        background-color: var(--primary);
    }
    
    header.wrapper {
        position: sticky;
        top: 0;
        z-index: 10;
        padding-top: .5rem;
        padding-bottom: .5rem;
        display: flex;
        justify-content: space-between;
        align-items: center;
        font-size: 16px;
        /* Font-size included because some pages of the MMS try to override the body's font-size */
    }
    /*--------------------------------------------------------
            Desktop Navigation
--------------------------------------------------------*/
    
    #nav_menu {
        position: relative;
        z-index: 1;
        padding: 0;
    }
    
    #nav_menu>ul {
        display: flex;
        justify-content: space-between;
        flex-wrap: wrap;
        width: 100%;
    }
    
    #nav_menu>ul::before,
    #nav_menu>ul::after {
        content: none;
    }
    
    #nav_menu>ul>li>a {
        color: white;
        transition: background .125s ease-in-out;
    }
    
    #nav_menu .nav .open>a,
    #nav_menu .nav .open>a:focus,
    #nav_menu .nav .open>a:hover,
    #nav_menu .nav>li>a:focus,
    #nav_menu .nav>li>a:hover {
        text-decoration: none;
        background-color: #eee;
        background: var(--accent);
    }
    
    #nav_menu .caret {
        margin-left: .5ch;
    }
    
    #nav_menu .dropdown-menu {
        /* Dropdown menu  */
        /* background: var(--primary); */
        font-size: inherit;
        padding: .75em 0;
        min-width: 20ch;
    }
    
    #nav_menu>ul ul a {
        /* Dropdown menu links */
    }
    
    @media (max-width: 990px) {
        #nav_menu ul>li>a {
            padding: 10px 5px;
        }
        #nav_menu ul>li>.home-link {
            /* Verbose selector needed to override BS defaults */
            display: none;
        }
    }
    /*--------------------------------------------------------
    Mobile navigation
    --------------------------------------------------------*/
    
    button.mobileMenuTrigger {
        display: none;
        background: transparent;
        color: var(--primary);
        border: none;
    }
    
    @media (max-width: 767px) {
        header nav {
            display: none;
        }
        header .mobileMenuTrigger {
            display: block;
        }
    }
    
    #mobileMenuWrapper {
        position: fixed;
        background: white;
        top: 0;
        bottom: 0;
        z-index: 50;
        overflow-y: auto;
        overflow-x: hidden;
        left: -120%;
        width: 300px;
        box-shadow: 0 3px 14px -2px rgba(0, 0, 0, 0.4);
        transition: left .125s ease-in-out;
    }
    
    #mobileMenuWrapper.open {
        left: 0;
    }
    
    #mobileMenuWrapper ul {
        list-style-type: none;
        margin: 0;
        padding: 0;
    }
    
    #mobileMenuWrapper li {
        display: block;
        margin-bottom: .7rem;
    }
    
    #mobileMenuWrapper a {
        background-color: transparent;
        text-decoration: none;
        color: var(--text);
    }
    
    #mobileMenuWrapper .mDropdown {
        display: none;
        padding-top: .7rem;
    }
    
    #mobileMenuWrapper .mDropdown.open {
        display: block;
    }
    
    #mobileMenuWrapper .mDropdown a {
        color: #333;
    }
    
    #triggerClose {
        font-size: 22px;
        cursor: pointer;
        text-align: right;
    }
    
    #mobileMenuWrapper #mobile-menu {
        overflow: auto;
        padding: 1rem;
    }
    
    #mobile-search .searchbox {
        outline: 1px solid var(--primary);
        margin: 0;
    }
    /*--------------------------------------------------------
    Log In modal
--------------------------------------------------------*/
    /* Login modal */
    
    .modal-open #login-modal {
        display: flex;
    }
    
    .modal-dialog {
        max-width: 100%;
        font-size: 16px;
        margin: auto;
        width: 300px;
    }
    
    .modal-content {
        margin-top: 20px;
        border-radius: 0;
    }
    
    .modal-header,
    .modal-body {
        padding: .5rem 1rem;
    }
    
    .modal-header .close {
        opacity: 1;
        z-index: 1;
        position: relative;
    }
    
    .modal h2 {
        font-size: 24px;
    }
    
    .modal-header,
    .modal-body {
        padding: 1em 2ch;
    }
    
    .modal input[name="Username"],
    .modal input[name="Password"] {
        width: 100%;
        padding-left: .25em;
        padding-right: .25em;
        margin-bottom: 0.5em;
        height: 2em;
        border: 1px solid rgba(68, 68, 68, .5);
    }
    
    .modal a {
        display: block;
        margin-bottom: .5em;
    }
    /*--------------------------------------------------------
    Main
--------------------------------------------------------*/
    
    #subpage-main,
    #mms-main {
        padding-top: 3rem;
        min-height: calc(100vh - (101px + 50px + 141px + 3rem));
    }
    
    main .row+.row {
        margin-top: 3rem;
    }
    
    @media (max-width: 990px) {
        #subpage-main,
        #mms-main {
            padding-top: 2rem;
        }
        main .row+.row {
            margin-top: 2rem;
        }
    }
    
    @media (max-width: 767px) {
        #subpage-main,
        #mms-main {
            min-height: calc(100vh - (120px + 52px + 157px));
            padding-top: 1rem;
        }
        main [class*="col-"]+[class*="col-"] {
            margin-top: 1rem;
        }
    }
    /* Slideshows defaults */
    
    .carousel {
        font-size: 20px;
    }
    
    .carousel-indicators {
        z-index: 5;
    }
    /* Homepage slideshows */
    
    #slide-row .carousel-indicators {
        top: 1rem;
        right: 1rem;
        left: unset;
        bottom: unset;
        text-align: right;
        margin: unset;
    }
    
    #secondary-slide-row .carousel-indicators {
        top: unset;
        bottom: 1rem;
        left: 1rem;
        right: unset;
        text-align: left;
        margin: unset;
    }
    
    #slide-row .carousel-indicators li,
    #secondary-slide-row .carousel-indicators li {
        border-color: var(--primary);
        background: white;
    }
    
    #slide-row .carousel-indicators li.active,
    #secondary-slide-row .carousel-indicators li.active {
        background: var(--accent);
    }
    
    #secondary-slide-row .item {
        opacity: 0;
        transition: .125s opacity ease-in-out;
    }
    
    #secondary-slide-row .item.active {
        display: flex;
        flex-direction: row;
        justify-content: space-between;
        opacity: 1;
    }
    
    #slide-row img {
        width: 100%;
        max-height: 75vh;
        object-fit: cover;
        object-position: center;
    }
    
    #secondary-slide-row img {
        width: calc(50% - 15px);
    }
    
    #slide-row .carousel-caption,
    #secondary-slide-row .carousel-caption {
        position: absolute;
        z-index: 2;
        color: #fff;
        left: 0;
        bottom: 0;
        right: 0;
        top: auto;
        width: 100%;
        text-align: left;
        text-shadow: none;
        margin: auto;
        padding: 0 15px;
        /* Style needed to overwrite BS defaults */
    }
    
    #secondary-slide-row .carousel-caption {
        position: relative;
    }
    
    #slide-row .caption-wrapper {
        position: relative;
        padding: 1.25rem 0 2rem;
    }
    
    #secondary-slide-row .caption-wrapper {
        padding: 1rem 30px;
        padding-right: 0;
    }
    
    #slide-row .caption-wrapper::before {
        content: '';
        position: absolute;
        background: var(--primary);
        top: 0;
        bottom: 0;
        left: -666vw;
        right: -666vw;
        z-index: -1;
        opacity: .8;
    }
    
    #slide-row .caption-text {
        font-size: 30px;
        /* font-weight: bold; */
        line-height: 1.2;
        text-transform: capitalize;
        font-family: 'Montserrat', sans-serif;
        margin-bottom: .5rem;
    }
    
    #secondary-slide-row .caption-text {
        font-size: 24px;
        font-family: 'Montserrat', sans-serif;
        text-transform: capitalize;
        line-height: 1.1;
        margin-bottom: .5rem;
    }
    
    #slide-row .alt-text {
        margin-bottom: 0;
        font-size: 1.1rem;
        line-height: 1.4;
    }
    
    #secondary-slide-row .alt-text {
        margin-bottom: 0;
        font-size: 18px;
    }
    
    #slide-row .carousel-control.left,
    #slide-row .carousel-control.right,
    #secondary-slide-row .carousel-control.left,
    #secondary-slide-row .carousel-control.right {
        display: none;
    }
    
    @media (min-width: 1171px) {
        #slide-row .carousel-caption {
            width: 1170px;
        }
    }
    
    @media (max-width: 1200px) {
        #slide-row .carousel-caption {
            width: 960px;
            max-width: 100%;
        }
    }
    
    @media (max-width: 990px) {
        #slide-row .carousel-caption {
            position: relative;
        }
        #slide-row .carousel-caption::before {
            opacity: 1;
        }
        #slide-row .caption-wrapper::before {
            opacity: 1;
        }
        #slide-row .caption-text {
            font-size: 22px;
        }
        #slide-row .alt-text {
            font-size: 1rem;
        }
        #secondary-slide-row .carousel-indicators {
            bottom: unset;
        }
        #secondary-slide-row .item.active {
            flex-direction: column;
        }
        #secondary-slide-row .carousel-caption,
        #secondary-slide-row img {
            width: 750px;
            max-width: 100%;
            margin: 0 auto;
            padding: 0;
        }
        #secondary-slide-row .caption-wrapper {
            padding-left: 0;
        }
    }
    /* #feeds-row */
    
    #feeds-row:not(.gm-editing)>div {
        display: grid;
        grid-template-columns: repeat(2, 1fr);
        gap: 1rem 15px;
    }
    
    #feeds-row h2 {
        grid-column: 1 / -1;
        margin-bottom: calc(.75em - 1rem);
    }
    
    .events-item,
    .news-item {
        border: 1px solid #E0E0E0;
        padding: .7rem;
        min-height: 15rem;
    }
    
    .news-item {
        min-height: 31rem;
    }
    
    .events-item>*:not(:last-child),
    .news-item>*:not(:last-child) {
        margin-bottom: .5rem;
    }
    
    .events-item img,
    .news-item img {
        width: 100%;
    }
    
    .events-item time,
    .news-item time {
        display: block;
        font-size: 30px;
        font-family: 'Montserrat', sans-serif;
        color: var(--accent);
    }
    
    .events-item h3,
    .news-item h3 {
        font-family: inherit;
        font-size: 20px;
        font-weight: bold;
        opacity: .9;
    }
    
    .events-item a,
    .news-item a {
        color: inherit;
        /* text-decoration: underline; */
    }
    /*--------------------------------------------------------
FOOTER
--------------------------------------------------------*/
    
    footer {
        margin-top: 3rem;
        padding: 2rem 0;
        color: white;
    }
    
    @media (max-width: 990px) {
        footer {
            margin-top: 2rem;
        }
    }
    
    @media (max-width: 767px) {
        footer {
            margin-top: 1rem;
        }
    }
    
    .social-list {
        padding: 0;
        list-style: none;
        display: flex;
        gap: 1ch;
    }
    
    footer svg {
        width: 30px;
        height: 30px;
        /* margin-right: 5px; */
    }
    /*--------------------------------------------------------
MMS 
--------------------------------------------------------*/
    /* MMS Member Icons Menu */
    
    @media (min-width: 1200px) {
        .nav-tabs li.dropdown {
            width: 190px;
        }
    }
    
    @media (min-width: 990px) and (max-width: 1200px) {
        .nav-tabs li.dropdown {
            width: 155px;
        }
    }
    
    @media (min-width: 767px) and (max-width: 990px) {
        .nav-tabs li.dropdown {
            width: 120px;
        }
    }