/* =======================================================
    CSS RESET
    ======================================================= */
    html, body, div, span, h1, h2, h3, h4, h5, h6, p, a, img, footer, header, nav, section, main {
    margin: 0;
    padding: 0;
    border: 0;
    font-size: 100%;
    font: inherit;
    vertical-align: baseline;
}

footer, header, nav, section, main {
    display: block;
}

body {
    line-height: 1;
}

/* =======================================================
    GLOBAL STYLES & DARK MODE THEME
    ======================================================= */

@import url('https://fonts.googleapis.com/css2?family=Montserrat:wght@400;600;700&display=swap');

:root {
    --bg-primary: #1a1a1a;
    --bg-secondary: #2c2c2c;
    --text-primary: #e0e0e0;
    --text-secondary: #aaaaaa;
    --accent-color: #4A90E2;
    --border-color: #444444;
    --error-color: #ff4444;
}

* {
    box-sizing: border-box;
}

body {
    font-family: 'Montserrat', sans-serif;
    line-height: 1.6;
    background-color: var(--bg-primary);
    color: var(--text-primary);
}

.page-wrapper {
    max-width: 1200px;
    margin: 0 auto;
    background-color: var(--bg-primary);
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

h1, h2, h3 {
    color: var(--text-primary);
    margin-bottom: 10px;
    font-weight: 600;
}

h1 {
    font-size: 2.2em;
    padding-bottom: 10px;
    border-bottom: 1px solid var(--border-color);
}

a {
    transition: all 0.3s ease;
}

/* =======================================================
    HEADER & NAVIGATION
    ======================================================= */
header {
    background-color: var(--bg-secondary);
    padding: 10px 20px;
    border-bottom: 1px solid var(--border-color);

    /* === ADDED FOR HAMBURGER === */
    /* This positions the hamburger button on the right */
    display: flex;
    justify-content: flex-end;
    align-items: center;
    min-height: 50px; /* Gives header a consistent height */
    position: relative; /* For z-index stacking */
}

/* === ADDED FOR HAMBURGER BUTTON === */
.hamburger {
    display: flex; /* This makes it visible */
    flex-direction: column;
    justify-content: space-around;
    width: 30px;
    height: 24px;
    background: transparent;
    border: none;
    cursor: pointer;
    padding: 0;
    z-index: 100; /* Ensures it's on top of the nav overlay */
}

.hamburger span {
    width: 30px;
    height: 3px;
    background-color: var(--text-primary);
    border-radius: 5px;
    transition: all 0.3s ease-in-out;
}

/* Hamburger "X" animation */
.hamburger.active span:nth-child(1) {
    transform: rotate(45deg) translate(5px, 5px);
}
.hamburger.active span:nth-child(2) {
    opacity: 0;
}
.hamburger.active span:nth-child(3) {
    transform: rotate(-45deg) translate(7px, -7px);
}

/* === MODIFIED FOR HAMBURGER MENU === */
.nav-links {
    /* These old styles are commented out */
    /* display: flex; */
    /* flex-wrap: wrap; */
    /* justify-content: space-around; */
    /* gap: 10px 5px; */

    /* These are the new styles for the overlay */
    display: none; /* Hidden by default */
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background-color: var(--bg-primary);
    
    flex-direction: column; /* Stack links vertically */
    justify-content: center;
    align-items: center;
    gap: 30px; /* Space out the links */
    z-index: 99; /* Sits behind the hamburger button */
}

/* This class is added by your JS to show the menu */
.nav-links.active {
    display: flex;
}

.nav-links a {
    color: var(--text-primary);
    text-decoration: none;
    padding: 10px 20px; /* More tap-friendly padding */
    font-weight: 600;
    text-align: center;
    transition: background-color 0.3s, color 0.3s, transform 0.2s;
    border-radius: 5px;
    /* width: 48%; */ /* No longer need a fixed width */
    width: auto;
    font-size: 1.5em; /* Make links bigger on the overlay */
}

.nav-links a:hover {
    background-color: var(--accent-color);
    color: #ffffff;
    transform: translateY(-2px);
}

.nav-links a.active {
    background-color: var(--accent-color);
    color: #ffffff;
}

/* =======================================================
    CONTENT SECTIONS
    ======================================================= */
main {
    padding: 15px;
    flex: 1;
}

.content-text {
    color: var(--text-primary);
    font-size: 1.1em;
    line-height: 1.7;
    padding: 15px;
    margin-bottom: 20px;
}

.content-text p {
    margin-bottom: 15px;
}

/* =======================================================
    IMAGE PLACEHOLDERS
    ======================================================= */
.image-placeholder {
    overflow: hidden;
    transition: transform 0.3s ease;
    position: relative; /* === ADDED for responsive iframes === */
}

.image-placeholder:hover {
    transform: scale(1.02);
}

.image-placeholder img {
    width: 100%;
    height: auto; /* This is correct for standalone images */
    display: block; 
}

/* === RULE FOR GRID IMAGES === */
/* This targets ONLY images in the About, Pics, and Gigs grids */
.about-grid .image-placeholder img,
.pics-grid .image-placeholder img,
.gigs-layout .image-placeholder img {
    width: 100%;
    height: 100%;
    object-fit: cover; /* This makes the image fill the square/box */
}

/* === ADDED FOR RESPONSIVE VIDEOS === */
.image-placeholder iframe {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    border: 0;
}


/* =======================================================
    CONTACT INFO BAR
    ======================================================= */
.contact-info {
    background-color: var(--bg-secondary);
    padding: 10px 20px;
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
    align-items: center;
    gap: 10px;
    font-size: 0.9em;
    border-bottom: 1px solid var(--border-color);
}

.contact-info a {
    color: var(--accent-color);
    text-decoration: none;
}

.contact-info a:hover {
    text-decoration: underline;
}

.social-links {
    display: flex;
    gap: 15px;
}

.social-links a {
    color: var(--text-primary);
    font-size: 1.2em;
    transition: color 0.3s;
}

.social-links a:hover {
    color: var(--accent-color);
}

/* =======================================================
    FOOTER
    ======================================================= */
footer {
    background-color: var(--bg-secondary);
    color: var(--text-primary);
    padding: 20px;
    display: flex;
    flex-direction: column;
    gap: 10px;
    margin-top: 40px;
    border-top: 1px solid var(--border-color);
}

.footer-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 10px;
}

.footer-text {
    font-size: 0.9em;
    color: var(--text-secondary);
}

.view-label {
    font-size: 0.8em;
    color: #888;
    text-align: right;
}

/* =======================================================
    CONTACT FORM
    ======================================================= */
.contact-form {
    max-width: 600px; /* This is the default max-width for mobile */
    margin: 0 auto;
    padding: 20px;
    background-color: var(--bg-secondary);
    border-radius: 8px;
}

.form-group {
    margin-bottom: 20px;
}

.form-group label {
    display: block;
    margin-bottom: 5px;
    font-weight: 600;
    color: var(--text-primary);
}

.required::after {
    content: " *";
    color: var(--error-color);
}

.form-group input[type="text"],
.form-group input[type="email"],
.form-group textarea {
    width: 100%;
    padding: 12px;
    border: 1px solid var(--border-color);
    background-color: var(--bg-primary);
    color: var(--text-primary);
    border-radius: 5px;
    font-family: 'Montserrat', sans-serif;
    font-size: 1em;
    transition: border-color 0.3s;
}

.form-group input[type="text"]:focus,
.form-group input[type="email"]:focus,
.form-group textarea:focus {
    outline: none;
    border-color: var(--accent-color);
}

.form-group input[required],
.form-group input[type="email"][required] {
    border-left: 3px solid var(--error-color);
}

.form-group textarea {
    resize: vertical;
    min-height: 120px;
}

.submit-btn {
    background-color: var(--accent-color);
    color: #ffffff;
    padding: 12px 30px;
    border: none;
    border-radius: 5px;
    font-size: 1.1em;
    font-weight: 600;
    cursor: pointer;
    transition: background-color 0.3s, transform 0.2s;
}

.submit-btn:hover {
    background-color: #3a7bc8;
    transform: translateY(-2px);
}

/* =======================================================
    GOOGLE MAP
    ======================================================= */
.map-container {
    width: 100%;
    height: 400px;
    margin: 20px 0;
    border: 1px solid var(--border-color);
    border-radius: 8px;
    overflow: hidden;
}

.map-container iframe {
    width: 100%;
    height: 100%;
    border: 0;
}

/* =======================================================
    HOME LAYOUT (Mobile First)
    ======================================================= */
.home-layout {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.home-left {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.home-pic-large {
    order: 2;
}

.content-text {
    order: 1;
}

.home-pic-small {
    order: 3;
}

.home-right {
    display: none;
}

/* =======================================================
    ABOUT LAYOUT (Mobile: 3-col Grid)
    ======================================================= */
.about-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr); /* Default for phones > 410px */
    gap: 10px;
    margin-top: 20px;
    margin-bottom: 25px;
}

.about-grid .image-placeholder {
    aspect-ratio: 1 / 1; /* This makes them square */
    background-color: var(--bg-secondary);
    border: 1px solid var(--border-color);
    display: flex;
    align-items: center;
    justify-content: center;
}

/* =======================================================
    PICS LAYOUT (Mobile: Stacked)
    ======================================================= */
.pics-grid {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.pics-grid .image-placeholder {
    width: 100%;
    aspect-ratio: 1 / 1; /* Changed from height: 250px */
    background-color: var(--bg-secondary);
    border: 1px solid var(--border-color);
    display: flex;
    align-items: center;
    justify-content: center;
}

/* === ADDED FOR RESPONSIVE VIDEOS === */
.pics-grid .image-placeholder.vid {
    height: auto; /* Override fixed height */
    aspect-ratio: 16 / 9;
}

/* =======================================================
    SONGS LAYOUT (Mobile: Stacked)
    ======================================================= */
.songs-grid {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.songs-grid .image-placeholder {
    width: 100%;
    /* height: 250px; */ /* Replaced with aspect-ratio */
    aspect-ratio: 16 / 9; /* Make video boxes responsive */
    background-color: var(--bg-secondary);
    border: 1px solid var(--border-color);
    display: flex;
    align-items: center;
    justify-content: center;
}

/* =======================================================
    GIGS LAYOUT (Mobile: Stacked)
    ======================================================= */
.gigs-layout {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.gig-pic-large,
.gig-pic-small,
.gig-pic-wide {
    width: 100%;
    height: 250px;
    /* Re-adding template styles for mobile */
    background-color: var(--bg-secondary);
    border: 1px solid var(--border-color);
    display: flex;
    align-items: center;
    justify-content: center;
}

/* =======================================================
    CONTACT LAYOUT (Mobile: Stacked)
    ======================================================= */
.contact-layout {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.contact-image-large {
    /* No mobile-specific styles needed */
}

/* =======================================================
    LAYOUT 1: SMALL MOBILE (410px and less)
    ======================================================= */
@media (max-width: 410px) {
    h1 {
        font-size: 1.8em;
    }
    
    /* .nav-links a { */ /* This rule is no longer needed */
        /* width: 100%; */
    /* } */

    .about-grid {
        grid-template-columns: repeat(2, 1fr); /* 2 columns for small phones */
    }
    
    .view-label::after {
        content: ' | View: Mobile (Small)';
    }
}

/* =======================================================
    LAYOUT 2: TABLET (411px - 1023px)
    ======================================================= */
@media (min-width: 411px) and (max-width: 1023px) {
    .view-label::after {
        content: ' | View: Tablet';
    }

    .contact-form {
        max-width: 800px; 
    }

    .about-grid {
        grid-template-columns: repeat(5, 1fr);
    }
}

/* =======================================================
    LAYOUT 3: PC / COMPUTER (1024px and up)
    ======================================================= */
@media (min-width: 1024px) {
    h1 {
        font-size: 2.5em;
    }

    /* === ADDED FOR HAMBURGER === */
    .hamburger {
        display: none; /* Hide hamburger on PC */
    }

    /* NAVIGATION */
    .nav-links {
        /* === OVERRIDE HAMBURGER STYLES FOR PC === */
        display: flex;
        position: static; /* Reset from fixed */
        width: auto;
        height: auto;
        background-color: transparent;
        flex-direction: row;
        z-index: 1; /* Reset z-index */

        /* === USER'S ORIGINAL PC STYLES === */
        flex-wrap: nowrap;
        justify-content: flex-start;
        gap: 25px;
    }
    
    .nav-links a {
        /* === RESET FONT SIZE FOR PC === */
        font-size: 1em; 

        /* === USER'S ORIGINAL PC STYLES === */
        width: auto;
        padding: 8px 12px;
    }

    /* === MODIFIED FOR HAMBURGER === */
    header {
        /* Reset header styles for PC nav */
        display: block;
        min-height: 0;
    }


    /* HOME LAYOUT */
    .home-layout {
        flex-direction: row;
        gap: 20px;
    }
    
    .home-left {
        flex: 2;
    }
    
    .home-right {
        flex: 1;
        display: block;
    }
    
    .home-pic-large {
        order: 1;
    }
    
    .content-text {
        order: 2;
    }
    
    .home-pic-small {
        order: 3;
    }
    
    .home-logo {
        width: 400px;
    }

    /* ABOUT LAYOUT */
    .about-grid {
        grid-template-columns: repeat(5, 1fr);
        gap: 15px;
    }
    
    .about-grid .image-placeholder {
        aspect-ratio: 1 / 1; 
        background-color: var(--bg-secondary);
        border: 1px solid var(--border-color);
        display: flex;
        align-items: center;
        justify-content: center;
    }

    /* PICS LAYOUT */
    .pics-grid {
        display: grid;
        grid-template-columns: repeat(4, 1fr);
        gap: 15px;
    }
    
    .pics-grid .image-placeholder {
        aspect-ratio: 1 / 1;
        height: auto; /* Override mobile fixed height */
        background-color: var(--bg-secondary);
        border: 1px solid var(--border-color);
        display: flex;
        align-items: center;
        justify-content: center;
    }
    
    .pics-grid .vid {
        grid-column: span 2;
        aspect-ratio: 16 / 9;
    }

    /* SONGS LAYOUT */
    .songs-grid {
        display: grid;
        grid-template-columns: repeat(2, 1fr);
        gap: 20px;
    }
    
    .songs-grid .image-placeholder {
        aspect-ratio: 16 / 9;
        height: auto; /* Override mobile fixed height */
        background-color: var(--bg-secondary);
        border: 1px solid var(--border-color);
        display: flex;
        align-items: center;
        justify-content: center;
    }

    /* GIGS LAYOUT */
    .gigs-layout {
        display: grid;
        grid-template-columns: 1.5fr 1fr;
        gap: 20px;
    }
    
    .gig-col-1 {
        display: flex;
        flex-direction: column;
        gap: 20px;
    }
    
    .gig-col-2 {
        display: flex;
        flex-direction: column;
        gap: 20px;
    }
    
    .gig-pic-large {
        height: 400px;
        background-color: var(--bg-secondary);
        border: 1px solid var(--border-color);
        display: flex;
        align-items: center;
        justify-content: center;
    }
    
    .gig-pic-small {
        height: 180px;
        background-color: var(--bg-secondary);
        border: 1px solid var(--border-color);
        display: flex;
        align-items: center;
        justify-content: center;
    }
    
    .gig-pic-wide {
        height: 180px;
        background-color: var(--bg-secondary);
        border: 1px solid var(--border-color);
        display: flex;
        align-items: center;
        justify-content: center;
    }

    /* CONTACT LAYOUT */
    .contact-layout {
        display: flex; 
        flex-direction: row;
        gap: 30px;
        align-items: flex-start; 
    }
    
    .contact-image-large {
        flex-grow: 1;
        flex-shrink: 1;
        flex-basis: 60%;
    }
    
    .contact-form {
        flex-grow: 1;
        flex-shrink: 1;
        flex-basis: 40%;
        min-width: 400px; 
    }
    
    .view-label::after {
        content: ' | View: PC';
    }
}