/* ==========================================================================
   ACC Construction — Main Stylesheet  v3
   ========================================================================== */

/* --------------------------------------------------------------------------
   Base
   -------------------------------------------------------------------------- */
*, *::before, *::after {
    box-sizing: border-box;
}

body {
    margin: 0;
    padding: 0;
    color: #3e3530;
    font-family: Arial, Helvetica, sans-serif;
}

img {
    max-width: 100%;
    height: auto;
}

h1 { margin: 0; padding-top: 5px; }

/* --------------------------------------------------------------------------
   Header  (desktop — fixed, 157px)
   -------------------------------------------------------------------------- */
#header {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 157px;
    text-align: center;
    background-image: url('../../images/acc_logo_map_sfw_new.png');
    background-size: cover;
    background-position: center;
    border-bottom: 1px solid #0b593c;
    z-index: 1000;
}

#header img {
    left: 10px;
    position: absolute;
    top: 8px;
}

#header p {
    text-align: right;
    margin: 0 20px;
    color: #0a593b;
    background-color: white;
    border: 1px solid #d3ca89;
    border-radius: 16px;
    padding: 3px 12px;
    display: inline-block;
    position: absolute;
    top: 10px;
    right: 10px;
    font-size: 32px;
}

/* --------------------------------------------------------------------------
   Navigation  (desktop)
   -------------------------------------------------------------------------- */
#menu {
    display: inline-block;
    text-align: center;
    width: 100%;
    position: absolute;
    top: 105px;
    right: 10px;
    z-index: 100;
}

#menu ul {
    list-style-type: none;
    margin: 12px;
    float: right;
    padding-left: 0;
}

#menu ul li {
    display: inline-block;
}

#menu ul li a {
    background-color: #ffffff;
    border: 1px solid #636466;
    border-radius: 7px;
    box-shadow: inset 2px 2px 7px #c3c3c5;
    color: #636466;
    cursor: pointer;
    font-family: Arial, Helvetica, sans-serif;
    font-size: 0.95em;
    padding: 3px 9px;
    margin-right: 8px;
    text-align: center;
    text-decoration: none;
    font-weight: bold;
}

#menu ul li a:hover {
    background-color: #f0f0f0;
    color: #0a593b;
    border-color: #0a593b;
}

/* Hamburger button — hidden on desktop */
#menu-toggle {
    display: none;
}

/* --------------------------------------------------------------------------
   Slideshow
   -------------------------------------------------------------------------- */
#slide_wrap {
    margin: 0 auto;
}

#slideshow {
    max-width: 980px;
    min-width: 0;
    margin: 0 auto;
    overflow: hidden;
}

#slideshow img {
    width: 100%;
    height: auto;
    display: block;
}

/* --------------------------------------------------------------------------
   Layout
   -------------------------------------------------------------------------- */
#wrap {
    margin: 157px 20px 60px 20px;
    text-align: center;
}

#content {
    text-align: left;
}

/* --------------------------------------------------------------------------
   Footer
   -------------------------------------------------------------------------- */
#footer {
    color: #003163;
    border-top: 1px solid #000000;
    background-color: white;
    width: 100%;
    clear: both;
    position: fixed;
    bottom: 0;
    left: 0;
    padding: 5px 0;
    text-align: center;
    z-index: 1000;
}

/* --------------------------------------------------------------------------
   Contact page address block
   -------------------------------------------------------------------------- */
#address {
    float: right;
    width: calc(100% - 400px);
}


/* ==========================================================================
   Tablet  (601px – 900px)
   ========================================================================== */
@media only screen and (min-width: 601px) and (max-width: 900px) {
    #header img {
        height: 88px;
    }
    #header p {
        font-size: 23px;
    }
}


/* ==========================================================================
   Mobile  (≤ 600px)
   ========================================================================== */
@media only screen and (max-width: 600px) {

    /* --- Base --- */
    body {
        font-size: 16px;
    }

    h1 { font-size: 1.4em; }
    h2 { font-size: 1.2em; }
    h3 { font-size: 1.1em; }

    /* --- Header: two-row flex layout ---
         Row 1: logo | phone number | hamburger button
         Row 2: nav menu (full width, shown/hidden)
    --- */
    #header {
        position: relative;
        top: auto;
        height: auto;
        padding: 0;
        display: flex;
        flex-wrap: wrap;       /* lets #menu wrap to its own row */
        align-items: center;
        background-size: cover;
    }

    /* Logo — row 1, left */
    #header img {
        position: relative;
        top: auto;
        left: auto;
        height: 48px;
        width: auto;
        flex-shrink: 0;
        margin: 8px 0 8px 10px;
    }

    /* Phone number — row 1, grows to fill space between logo and button */
    #header p {
        position: relative;
        top: auto;
        right: auto;
        font-size: 13px;
        margin: 0 10px;
        padding: 3px 8px;
        border-radius: 10px;
        text-align: left;
        line-height: 1.3;
        flex: 1;               /* take up remaining space */
    }

    /* --- Hamburger button — row 1, right --- */
    #menu-toggle {
        display: block;
        position: relative;    /* in-flow, not absolute */
        top: auto;
        right: auto;
        margin: 8px 10px 8px 0;
        background-color: #fff;
        border: 1px solid #636466;
        border-radius: 6px;
        padding: 6px 10px;
        cursor: pointer;
        font-size: 20px;
        line-height: 1;
        color: #0a593b;
        flex-shrink: 0;
        z-index: 200;
    }

    /* --- Nav menu — row 2, full width, hidden by default --- */
    #menu {
        position: relative;
        top: auto;
        right: auto;
        width: 100%;           /* full row */
        flex-basis: 100%;      /* forces it to its own row */
        text-align: left;
        display: none;
        background-color: #fff;
        border-top: 2px solid #0a593b;
    }

    #menu.open {
        display: block;
    }

    #menu ul {
        float: none;
        margin: 0;
        padding: 8px 0;
        width: 100%;
    }

    #menu ul li {
        display: block;
        text-align: left;
    }

    #menu ul li a {
        display: block;
        padding: 12px 20px;
        margin: 0;
        border: none;
        border-bottom: 1px solid #eee;
        border-radius: 0;
        box-shadow: none;
        font-size: 1.1em;
        color: #0a593b;
        background-color: #fff;
    }

    #menu ul li a:active {
        background-color: #f0f7f0;
    }

    /* --- Layout --- */
    #wrap {
        margin: 0 0 60px 0;
        padding: 0;
    }

    #content {
        padding: 0 12px;
        overflow-x: hidden;
    }

    /* --- Slideshow: hidden on mobile --- */
    #slide_wrap {
        display: none;
    }

    /* --- Contact page --- */
    #address {
        float: none;
        width: 100%;
        margin-top: 20px;
    }

    /* --- Footer --- */
    #footer {
        font-size: 0.85em;
    }
}
