/* Style sheet for Blackwood Players Web Site
   Layout breakdown: Header, Menu, Info, Events, Footer
   Containing blocks: container1 - the Menu and Info blocks. */

/* ==========================================
   1. BASE & ROOT ELEMENT STYLES
   ========================================== */
body {
    display: grid;
    grid-template-areas: 
        'header'
        'menu' 
        'info'
        'events'
        'footer';
    grid-auto-flow: column;
    background-color: #FFFFD0;
    color: black;
    font-family: Arial, Helvetica, sans-serif;
}

/* ==========================================
   2. MAJOR LAYOUT STRUCTURAL BLOCKS
   ========================================== */
#Header {
    display: block;
    text-align: center;
    color: yellow;
    background-image: url("actors.png"), url("sylvia-group.png");
    background-color: lightblue;
    background-size: contain;
    background-repeat: no-repeat;
    background-position: left, right;
    font-family: 'Brush Script MT', cursive;
    grid-area: header;
}

#Header h1 {
    font-size: 2em;
}

#Menu {
    font-family: sans-serif;
    text-align: center;
    grid-area: menu;
    margin: 0;
}

#Menu ul {
    list-style-type: none;
    font-size: 1em;
    margin: 0;
    padding: 0;
    overflow: hidden;
}

.Info {
    display: block;
    font-size: clamp(0.85rem, 1.2vw, 1.1rem); 
    overflow: auto; 
    padding-block: 10px;
    margin-inline: 10px;
    grid-area: info;
}

.Info ul {
    list-style-type: none;
    margin: 0;
    padding: 0;
}

.Info p {
    padding-inline: 15px;
}

#Events {
    display: block;
    width: clamp(300px, 25vw, 600px);
    height: 750px;
    grid-area: events;
    position: relative;
    overflow: auto;
    margin-inline: auto;
}

#Footer {
    color: yellow;
    background-color: green;
    background-position: left;
    background-image: url("blackwood_park.png");
    background-size: cover;
    font-size: 1.2em;
    font-family: 'Brush Script MT', cursive;
    padding-inline: 25px;
    z-index: 1;
    grid-area: footer;
}

iframe {
    border-style: hidden;
    height: 750px;
    padding-top: 5px;
    padding-right: 5px;
}

/* ==========================================
   3. UI COMPONENTS & CARD GRID SYSTEMS
   ========================================== */
.menu-btn {
    grid-column: 1 / span 2;
    justify-self: center; 
    align-self: center;   
    color: #F22;
    background-color: rgba(150, 255, 150, 0.8);
    text-align: center;
    border: 1px solid #F88;
    border-radius: 5px;
    padding: 5px;
    font-size: 1.3em;
    font-weight: bold;
}

.popup-menu {
    background-color: rgba(150, 255, 150, 0.8);
    text-align: center;
    border: 1px solid #F88;
    border-radius: 5px;
    padding: 5px;
    margin: auto;
    font-size: 1.3em;
    line-height: 1.6;
}

.popup-menu a { text-decoration: none; }
.popup-menu a:link, .popup-menu a:visited { color: black; }
.popup-menu a:hover { color: red; text-decoration: underline; }
.popup-menu a:focus { color: yellow; }

/* Utility */
.centered {
    text-align: center;
}

/* Grid Cards Configurations */
.c2x2, .Cards2, .Cards3, .Cards4, .Cards5, .Media2 {
    display: grid;
    align-items: center;
    align-content: center;
    gap: 15px;
    padding-block: 10px;
    font-size: clamp(0.85rem, 2vw, 1.1rem);
}

.c2x2, .Cards2, .Media2 {
    grid-template-columns: repeat(2, 1fr);
}

.Cards2 {
    grid-template-rows: fit-content(300px);
    place-items: center;
}

.Cards3 { grid-template-columns: repeat(3, 1fr); place-items: center; }
.Cards4 { grid-template-columns: repeat(4, 1fr); place-items: center; }
.Cards5 { grid-template-columns: repeat(5, 1fr); }
.Media2 { place-items: center; }

/* Image bounds inside layouts (Fixed with commas) */
.c2x2 img, .Cards2 img, .Cards3 img, .Cards4 img, .Cards5 img, .Media2 img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.video {
    width: min(100%, 520px);
    aspect-ratio: 4 / 3;
    padding-bottom: 50px;
}

/* Articles and Cards */
article, .Card { display: block; }
article { margin-inline: 15px; text-align: center; }
article.Card, article.Card p, article.Card a { list-style-type: none; text-align: center; }

article.Card img {
    display: block;
    margin-inline: auto;
    width: 90%;
}

.Card, .Card h3, .Card p { padding-inline: 10px; }
.Card img { display: block; margin-inline: auto; align-self: center; }
.Cards4 {
    margin-top: 2rem; /* Replaces the empty &nbsp; spacer section */
    align-items: stretch; /* Keeps grid items flush with each other */
}

.Cards4 figure {
    margin: 0;
    display: flex;
    flex-direction: column;
}

.Cards4 figure img {
    flex: 1; /* Lets the image fill remaining height above the caption */
    min-height: 0;
}

@media (min-width: 901px) {
    .span-2-rows {
        grid-row-end: span 2;
    }
}

/* Responsive adjustments for tablets and phones */
@media (max-width: 900px) {
    .Cards4, .Cards5 {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 650px) {
    .c2x2, .Cards2, .Cards3, .Cards4, .Cards5, .Media2 {
        grid-template-columns: 1fr;
    }
}/* Shared Buttons */
.close, .more, .bookings {
    text-align: center;
    border: 1px solid #F88;
    border-radius: 5px;
    padding: 15px;
    margin: auto;
    font-size: 1.3em;
    font-weight: bold;
}

.close, .bookings { color: #F22; background-color: rgba(150, 255, 150, 0.8); }
.more { color: #FDF; background-color: rgba(100, 150, 150, 0.8); } /* Fixed decimal syntax bug */

.close:hover, .more:hover, .bookings:hover {
    color: rgba(170, 255, 170, 0.8);
    background-color: #F22;
}

/* Native Dialog Element Styling */
dialog {
    position: fixed;
    max-height: 95%;
    width: 75%;
    z-index: 2;
    background-color: #446644;
    color: #FFFFA0;
    overflow-y: auto; 
}

dialog img { max-width: 50%; margin-inline: auto; text-align: center; }
.dialog p { font-size: 0.8em; }
dialog a:link { color: white; }
dialog a:visited { color: yellow; }
dialog a:hover { color: red; }

/* Dynamic List Block */
.List5 {
    display: grid;
    grid-template-columns: auto;
    grid-template-rows: 1fr 1fr 1fr;
    overflow-y: auto; 
    gap: 10px;
    padding-block: 10px;
}

/* Review Containers & Mechanics */
.reviews {
    display: block;
    text-align: center;
    margin-inline: auto;
    max-width: 75%;
}

.review {
    color: #FDF;
    background-color: rgba(100, 150, 150, 0.8);
    padding: 5px;
    width: 120px;
    height: 2em;
    font-size: 0.8em;
}

.review:hover, .review_flex:hover {
    color: rgba(170, 255, 170, 0.8);
    background-color: #F22;
}

.reviews_flex {
    display: flex;
    flex-direction: column;
    text-align: center;
    margin-inline: auto;
    max-width: 95%;
}

.review_flex {
    color: #FDF;
    background-color: rgba(100, 150, 150, 0.8);
    padding: 5px;
    margin: 10px;
    width: 210px;
    height: 1.75em;
}

.reviews_grid2, .reviews_grid3 {
    display: grid;
    grid-template-columns: auto;
    overflow-y: auto;
    padding: 10px;
}
.reviews_grid2 { grid-template-rows: auto auto; }
.reviews_grid3 { grid-template-rows: auto auto auto; }

/* First Nations Acknowledgment Grid */
.firstNationsGrid {
    display: grid;
    grid-template-rows: auto auto;
    grid-template-columns: auto;
    max-width: 90%;
    row-gap: 7px;
    align-items: start;
    align-content: start;
    margin-inline: auto;
    background-color: rgba(173, 216, 230, 0.6);
    box-shadow: 10px 10px lightblue;
}

.firstNationsGrid img { max-height: 40px; margin-block: auto; margin-inline: auto; }
.firstNationsGrid p {
    font-size: 0.9em;
    font-family: 'Brush Script MT', cursive;
    color: red;
    text-align: center;
    margin-top: 0;
    margin-inline: auto;
}

.firstnations { font-size: 1em; }
.copyr { font-size: 0.85em; }

/* ==========================================
   4. UTILITY HELPER CLASSES (Colours/Fonts)
   ========================================== */
.centered { text-align: center; margin-inline: auto; }
.centeredblack { text-align: center; margin-inline: auto; color: white; background-color: black; }
.black { color: white; background-color: black; }
.black a:link, .black a:visited { color: yellow; }
.black a:hover { color: red; }
.lightblue { color: black; background-color: lightblue; }
.red { color: red; }
.redblack { color: red; background-color: black; }
.yellow { color: yellow; }
.yellowblack { background-color: yellow; color: black; }
.blackyellow { background-color: black; color: yellow; }
.yellowgreen { background-color: green; color: yellow; }
.orange { background-color: orange; color: black; }
.plain { list-style-type: none; }

.yellowbrown {
    background-color: #3B2822AA;
    color: yellow;
    box-shadow: 10px 10px #2A1711CC;
    border-radius: 25px;
}

/* Typographic Helpers */
.bold { font-weight: bold; }
.italic { font-style: italic; }
.bolditalic { font-style: italic; font-weight: bold; }
.boldcentered { text-align: center; font-weight: bold; }
.italiccentered { text-align: center; font-style: italic; }
.italicboldcentered { text-align: center; font-weight: bold; font-style: italic; }


/* ==========================================
   5. UNIFIED MEDIA BREAKPOINTS (Smallest to Largest)
   ========================================== */

/* Upwards from small tablet UI */
@media screen and (min-width: 600px) {
    #Header { color: red; }
}

/* Upwards from Portrait Tablets / Large Phones */
@media screen and (min-width: 768px) {
    .List5 {
        grid-template-columns: 1fr 1fr 1fr 1fr;
        grid-template-rows: auto;
    }
}

/* Upwards from Landscape Tablets */
@media screen and (min-width: 800px) {
    .firstNationsGrid {
        grid-template-columns: 130px auto;
        max-width: 60%;
        column-gap: 7px;
    }
}

/* Upwards from Small Desktop Layouts */
@media screen and (min-width: 950px) {
    body {
        grid-template-areas: 
            'header header'
            'menu menu'
            'info events'
            'footer footer';
        grid-auto-flow: row;
    }
}

/* Upwards from Standard Desktops */
@media screen and (min-width: 1010px) {
    .review {
        width: 120px;
        height: 1.8em;
        padding: 15px;
        font-size: 1em;
    }
    .reviews_flex {
        flex-direction: row;
    }
    .reviews_grid2 {
        grid-template-columns: auto auto;
        grid-template-rows: auto;
    }
    .reviews_grid3 {
        grid-template-columns: auto auto auto;
        grid-template-rows: auto;
    }
}
