/* ----- 
    global stylesheet -----           */

html {
    scroll-behavior: smooth;
}

body {
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    margin: 0;
    padding: 0;
    background: #fff;
    color: #000;
    /*font-family: "Andale Mono", courier, monospace;*/
    font-family: 'Courier New', Courier, monospace;
    font-size: 1.25rem;
}

article {
    width: 100%;
    margin: 1rem auto;
}

#content    {
    padding: 0 2rem 2rem 2rem;
    
}

.show   {
    display: block;
}

.hide, .sr-only   {
    display: none;
}

/* ----- 
    header & footer styles -----           */


header#site-header {
    width: 100%;
    height: 60px;
    border-bottom: 2px solid #fff;
    background: url('/assets/images/vhs-bands.gif') 0 0 repeat;
    background-size: contain;
    position: relative; /* allow absolutely-positioned hamburger inside header */
}

header#site-header nav {
    display: flex;
    justify-content: center;
    align-items: center;
    flex: 1;
    width: 100%;
}

header#site-header ul {
    display: flex;
    justify-content: space-around;
    text-align: center;
    margin: 0;
    padding: 0;
}

header#site-header li {
    list-style: none;
}

header#site-header a {
    display: block;
    margin: 30px 5px 0 5px;
    padding: 0;
    text-decoration: none;
    color: #fff;
    text-transform: uppercase;
    font-size: 1.25rem;
    font-weight: bold;
    cursor: pointer;    
}

header#site-header a:hover {
    text-decoration: underline;
}

header#site-header a.active {
    margin-top: 42px;
    text-decoration: line-through;
}

header#site-header a.active:hover {
    text-decoration: none;
}

header#site-header li.logo a {
    width: 68px;
    height: 60px;
    margin-top: 0;
    padding: 0;
    background-image: image-set('/assets/images/header-icon-face.gif' 1x, '/assets/images/header-icon-face@2x.gif' 2x);
    background-position: 50% 0;
    background-repeat: no-repeat;
    text-indent: -9999px;
}

footer#site-footer  {
    margin-top: auto;
    text-align: center;
    background: #000;
    color: #fff;
    font-size: .75rem;
}


/* ----- 
    pagination styles -----           */


.pagination {
    display: flex;
    flex-direction: row;
    justify-content: center;
    clear: both;
}

.pagination a   {
    display: block;
    margin: 1rem;
    padding: .5rem 1rem;
    background: #666;
    color: #efefef;
    text-decoration: none;
    font-size: 1rem;
    font-weight: bold;
    text-transform: uppercase;
}

.pagination a:hover {
    background: #ccc;
    color: #000;
}

.pagination a:visited {
    color: #efefef;
}

/* ----- 
    gallery styles -----           */

.gallery ul {
    display: flex;
    flex-wrap: wrap;
    margin: 0;
    padding: 0;
    list-style: none;
  }
  
.gallery li {
    margin: 0;
    padding: 0;
    /* height: 40vh; */
    flex-grow: 1;
}

.gallery li:last-child {
    flex-grow: 10;
}

.gallery img {
    max-height: 100%;
    min-width: 100%;
    object-fit: contain;
    vertical-align: bottom;
}

.inline_gallery {
    width: 100%; 
}

.inline_gallery figure {
    display: inline-block;
    margin: 0;
}

@media (max-aspect-ratio: 1/1) {
    .gallery li {
      height: 30vh;
    }
}

@media (max-height: 480px) {
    .gallery li {
        height: 80vh;
    }
}

@media (max-aspect-ratio: 1/1) and (max-width: 480px) {
    .gallery ul {
      flex-direction: row;
    }
  
    .gallery li {
      height: auto;
      width: 50%;
    }
  
    .gallery img {
      width: 100%;
      max-height: 75vh;
      min-width: 0;
    }
}

/* Mobile navigation (hamburger) - mobile only, not shown on homepage via PHP */
.menu-toggle { display: none; }
.mobile-menu { display: none; }

/* Prefer aria-hidden for controlling visibility: honor aria-hidden on the menu so
    it's hidden by default (server-side) and only shown when JS sets aria-hidden="false" */
.mobile-menu[aria-hidden="true"] { display: none !important; }
.mobile-menu[aria-hidden="false"] { display: flex !important; }

@media (max-width: 768px) {
    /* hide desktop nav and show hamburger */
    header#site-header nav.menu { display: none; }

    .menu-toggle {
        display: flex;
        position: absolute;
        left: 12px;
        top: 12px;
        width: 44px;
        height: 44px;
        padding: 6px;
        border: 0;
        background: transparent;
        cursor: pointer;
        align-items: center;
        justify-content: center;
        flex-direction: column;
        gap: 6px;
        z-index: 1100; /* sit above header background */
    }

    .menu-toggle .bar {
        display: block;
        width: 22px;
        height: 2px;
        background: #fff;
        margin: 0;
        transition: transform 0.2s ease, opacity 0.2s ease;
        transform-origin: center;
    }

    /* open state: morph into an X using aria-expanded on the button */
    /* open state: make bars overlap perfectly at center to form an X */
    .menu-toggle[aria-expanded="true"] .bar {
        position: absolute;
        top: 50%;
        left: 50%;
        width: 22px;
        height: 2px;
        transform-origin: center;
    }
    .menu-toggle[aria-expanded="true"] .bar:nth-child(1) {
        transform: translate(-50%, -50%) rotate(45deg);
    }
    .menu-toggle[aria-expanded="true"] .bar:nth-child(2) {
        opacity: 0;
        transform: translate(-50%, -50%) scaleX(0);
    }
    .menu-toggle[aria-expanded="true"] .bar:nth-child(3) {
        transform: translate(-50%, -50%) rotate(-45deg);
    }

    /* mobile-only centered logo */
    .mobile-logo { display: block; position: absolute; left: 50%; bottom: 0; transform: translateX(-50%); width: 68px; height: 60px; text-indent: -9999px; background-image: image-set('/assets/images/header-icon-face.gif' 1x, '/assets/images/header-icon-face@2x.gif' 2x); background-position: 50% 0; background-repeat: no-repeat; z-index: 1100; border: 0; padding: 0; cursor: pointer; }
    
    /* increase mobile menu item type by 25% */
    .mobile-menu a { font-size: 1.25em; }

    .mobile-menu {
        display: none;
        position: absolute;
        top: 60px;
        left: 0;
        right: 0;
        background: #111;
        color: #fff;
        z-index: 999;
        padding: 0.25rem 0 1rem; /* reduce top padding to pull first item up */
        box-shadow: 0 6px 18px rgba(0,0,0,0.5);
        flex-direction: column;
    }

    .mobile-menu.open {
        display: flex;
    }

    .mobile-menu ul { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; }
    .mobile-menu li { margin: 0; }
    .mobile-menu li.text-link a { display: block; padding: .5rem 1rem; color: #fff; text-decoration: none; text-transform: uppercase; font-weight: bold; }
    .mobile-menu li:first-child a { padding-top: .25rem; }
    .mobile-menu li.text-link a:hover { background: rgba(255,255,255,0.03); }
    .mobile-logo {background-color: transparent; }
}

@media (min-width: 767px) {
    .mobile-logo{
        display: none;
    }
    header#site-header {
        a {
            margin: 20px 5px 0 5px;
            padding: .5rem 1rem;
            font-size: 1.5rem;
        }

        a.active {
            margin-top: 30px;
        }
    }

    article {
        width: 80%;
        margin: 2rem auto;
    }
    #content    {
        padding: 1rem 2rem 2rem 2rem;
    }
}

