/* --- Global Text Readability & Outline --- */
* {
    -webkit-text-stroke: 1px #000000;
    paint-order: stroke fill;
}

body {
    width: 100vw;
    height: 100vh;
    
    /* ADDED: Dark overlay gradient over the image to boost overall contrast */
    background-image: 
        linear-gradient(rgba(0, 0, 0, 0.45), rgba(0, 0, 0, 0.45)),
        url('https://i.ibb.co/XrRrr85m/The-Menu.png');
    background-size: cover;
    background-repeat: no-repeat;
    background-attachment: fixed;
    background-position: center center;
    
    position: relative;
    margin: 0;
    padding: 10;
    overflow: hidden;
}

body::before {
    content: "";
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    pointer-events: none;
    z-index: 1;
    background-image: repeating-linear-gradient(
        45deg,
        rgba(0, 0, 0, 0.05) 0,
        rgba(0, 0, 0, 0.05) 1px,
        transparent 1px,
        transparent 3px
    );
    opacity: 1;
}

.content-wrapper {
    position: relative;
    width: 100%;
    height: 100%;
}

h1 {
    text-align: left;
    font-family: 'Georgia', serif;
    padding-top: 2vh;
    padding-left: 2vw;
    position: relative; 
    z-index: 3;
}

.main-heading {
    color: #FF6666; /* Primary Red */
    font-size: 3.5em;
    letter-spacing: 4px;
    /* UPDATED: Added black drop-shadow behind the red glow for maximum pop */
    text-shadow: 2px 2px 4px #000000, 0 0 10px rgba(255, 102, 102, 0.7);
    border-bottom: 1px solid rgba(255, 102, 102, 0.5);
    display: inline-block;
    padding-bottom: 5px;
    margin-left: 0;
    margin-right: auto;
    width: fit-content;
}

.sub-heading {
    display: block;
    color: #6699FF; /* Primary Blue */
    font-size: 1.4em;
    letter-spacing: 2px;
    margin-top: 0.5vh;
    /* UPDATED: Added black shadow for crisp edge */
    text-shadow: 1px 1px 3px #000000;
}

/* Tag buttons */
.tag-container {
    padding-left: 2vw;
    margin-top: 1vh;
    display: flex;
    flex-wrap: wrap;
    gap: 0.5vw;
    z-index: 3;
    position: relative;
}

.tag-button {
    font-family: 'Georgia', serif;
    font-size: 0.9em;
    /* UPDATED: Changed opacity from 0.9 to solid 1.0 */
    color: #FFFFFF; 
    /* UPDATED: Slightly darker background for better text contrast */
    background-color: rgba(30, 30, 70, 0.85); 
    padding: 0.5vh 1vw;
    border-radius: 4px;
    border: 1px solid rgba(102, 153, 255, 0.5); 
    cursor: default;
    transition: background-color 0.2s;
    text-shadow: 1px 1px 2px #000000;
}

.tag-button:hover {
    background-color: rgba(150, 50, 50, 0.85);
}

/* About Me List Box */
.about-me-container {
    position: absolute;
    top: 5vh;
    right: 2vw;
    width: auto;
    max-width: 30vw;
    background-color: rgba(20, 20, 20, 0.92); /* UPDATED: Slightly darker for crispness */
    padding: 2vh 2vw;
    border: 2px solid #A9A9A9; 
    box-shadow: 0 0 2vh rgba(0, 0, 0, 0.9), 0 0 10px rgba(169, 169, 169, 0.5);
    z-index: 3;
}

.about-me-list {
    list-style-type: none;
    padding-left: 0;
    margin: 0;
    color: #FFD700; 
    font-family: 'Georgia', serif;
    font-size: 1.3em;
    line-height: 1.6;
    text-align: left;
}

.about-me-item {
    margin-bottom: 1vh;
    /* UPDATED: Added hard black text-shadow behind the gold glow */
    text-shadow: 1px 1px 2px #000000, 0 0 3px rgba(255, 215, 0, 0.5);
}

/* Footer & Links */
.footer-art-wrapper,
.footer-competition-wrapper,
.footer-subtext-wrapper {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.5vh;
}

.footer-links-container {
    position: absolute;
    bottom: 5vh;
    left: 2vw;
    display: flex;
    gap: 1vw;
    align-items: center;
    z-index: 2;
}

.footer-subtext {
    font-family: 'Georgia', serif;
    font-size: 0.8em;
    /* UPDATED: Opaque light blue instead of 70% transparency */
    color: #88BBFF; 
    text-transform: uppercase;
    font-weight: bold;
    text-shadow: 1px 1px 2px #000000;
}

.footer-link {
    /* UPDATED: Solid white color instead of 80% transparency */
    color: #FFFFFF; 
    font-family: 'Georgia', serif;
    font-size: 1.1em;
    text-decoration: none;
    padding: 1vh 1.5vw;
    border: 1px solid #FF6666;
    border-radius: 8px;
    background-color: rgba(10, 10, 40, 0.75); /* UPDATED: Darkened backplate */
    transition: background-color 0.3s, color 0.3s, border-color 0.3s, transform 0.1s;
    text-align: center;
    text-shadow: 1px 1px 2px #000000;
}

.footer-link:hover {
    color: #FFFFFF;
    border-color: #6699FF; 
    background-color: rgba(0, 0, 100, 0.85);
    transform: translateY(-0.2vh);
}

.footer-link:active {
    transform: translateY(0);
    background-color: rgba(0, 0, 150, 0.9);
}

.reference-sheet-link {}

/* =========================================
   Mobile View Adjustments (Screens under 768px)
   ========================================= */
@media screen and (max-width: 768px) {
    
    /* Allow the page to scroll on mobile if content gets too tall */
    body {
        height: auto;
        min-height: 100vh;
        overflow-y: auto; 
        overflow-x: hidden;
    }

    .content-wrapper {
        display: flex;
        flex-direction: column;
    }

    /* Scale down headers */
    h1 {
        padding-right: 2vw; /* Prevent hitting the right edge */
    }

    .main-heading {
        font-size: 2.2em; /* Reduced from 3.5em */
        letter-spacing: 2px;
    }

    .sub-heading {
        font-size: 1.1em; /* Reduced from 1.4em */
        line-height: 1.3;
    }

    /* Move the "WIP" box into the flow of the document so it stops overlapping */
    .about-me-container {
        position: relative;
        top: auto;
        right: auto;
        max-width: 90vw;
        margin: 2vh 2vw;
        display: inline-block;
        align-self: flex-start; /* Keep it aligned nicely */
    }

    .about-me-list {
        display: flex;
        gap: 15px; /* Display W I P horizontally on mobile to save vertical space */
    }

    /* Give tags breathing room when they wrap */
    .tag-container {
        gap: 8px;
        padding-right: 2vw;
    }

    .tag-button {
        padding: 0.8vh 2vw; /* Slightly larger tap targets for mobile */
    }

    /* Fix the footer clipping by removing absolute positioning and stacking items */
    .footer-links-container {
        position: relative;
        bottom: auto;
        left: auto;
        flex-direction: column; /* Stack the buttons vertically */
        align-items: stretch; /* Stretch buttons to match width */
        gap: 2vh;
        padding: 4vh 4vw 6vh 4vw; /* Add bottom padding so it breathes */
        margin-top: 2vh;
    }

    .footer-art-wrapper,
    .footer-competition-wrapper,
    .footer-subtext-wrapper {
        width: 100%;
    }

    .footer-link {
        width: 100%; /* Make buttons span full available width */
        box-sizing: border-box;
        padding: 1.5vh 2vw; /* Thicker buttons for mobile tapping */
    }
}