/* General styles for the website */
* {
    box-sizing: border-box;
}

body {
    font-family: 'Trebuchet MS';
    font-size: 16px;
    margin: 0;
    padding: 20px 0;
    background-size: cover;
    background-position: center top;
    background-repeat: no-repeat;
    background-attachment: fixed; /* Keep the background fixed while scrolling */
}


/* Styling for the header */
header {
    text-align: center;
    margin-top: 2%;
}

.text-header {
    font-family: 'Anton', sans-serif;
    font-color: white;
    font-size: clamp(22px, 2.5vw, 48px);
}

#main {
    background-image: url('graphic/1.png');
}

#about {
    background-image: url('graphic/b2.png');
}

#donate {
    background-image: url('graphic/bigpage.png');
    background-color: #c25656;
}

#zines {
    background-image: url('graphic/b2.png');
    margin: 0;
    padding: 0;
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 100vh;
}

#intake {
    background-image: url('graphic/b2.png');
}


#d {
    width: 30%;
    position: left top;
    margin-top: 0;
    margin-left: 18%;
}

.navbar {
            width: 100%;
            height: 26vh;
            background-color: #b20000;
            display: flex;
            justify-content: center;
            align-items: center;
            padding: 10px;
        }

.head-img {
    max-width: 100%; /* Ensures the image doesn’t exceed the navbar’s width */
    max-height: 100%; /* Ensures the image doesn’t exceed the navbar’s height */
    height: auto; /* Maintain aspect ratio */
    /*object-fit: contain; /* Ensures the image scales properly */
}

.nav-buttons {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); /* Flexible columns */
    gap: 5px; /* Minimal spacing */
    width: 100vw; /* Full screen width */
    padding: 5px;
    margin-top: 50px;
    justify-content: stretch; /* Centers images if they don’t fill a full row */
    align-items: center;
}

.nav-buttons a {
    display: block;
    position: relative;
    overflow: hidden;
    height: 40vh;
    width: 100%;
}

.nav-buttons img {
    display: block;
    object-fit: scale-down;
    /*width: auto;*/
    height: 100%;
    transition: opacity 0.3s ease-in-out;
}

.image-wrapper .hover-img {
    opacity: 0;
}

.image-wrapper:hover .hover-img {
    opacity: 1;
}

.image-wrapper:hover .normal-img {
    opacity: 0;
}

/* Media query for smaller screens */
@media (max-width: 768px) {
    .nav-buttons {
        grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); /* 2 per row */
    }
}


/* /* Image wrapper to hold both images */
.image-wrapper {
    position: relative;
    display: block;
    text-align: center;
    height: 100%;
    width: auto;
}

/* Default (normal) image */
.normal-img {
    display: block;
    width: 100%;
    height: auto;
}

/* Hover image (hidden by default) */
.hover-img {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: auto;
    opacity: 0;
    transition: opacity 1s ease;
}

/* When hovering over the wrapper, fade the hover image in */
.image-wrapper:hover .hover-img {
    opacity: 1; /* Make hover image fully visible */
}

/* When hovering, fade the normal image out */
.image-wrapper:hover .normal-img {
    opacity: 1; /* Make normal image invisible */
}

.back-button {
    position: fixed; /* Change from absolute to fixed for it to stay in the same position while scrolling */
    top: 10px;
    left: 10px;
    width: 160px;
    z-index: 100; /* Ensure it appears above other elements */
    transition: transform 0.2s ease-in-out; /* Smooth scaling effect */
}

.back-button img {
    width: 100%;
    height: 100%;
    z-index: 10;
    object-fit: contain;
}

.back-button:hover {
    transform: scale(1.1);
    filter: invert(1);/* Increases size by 20% when hovered */
}


/* Section styles */
section {
    margin: 20px;
    border-radius: 5px;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
}

/* Footer styles */

footer {
    width: 100%;
    background-color: #b20000;
    color: white;
    text-align: center;
    padding: 8px;
    position: fixed;
    bottom: 0;
    left: 0;
    height: 6%;
    overflow: hidden;
    transition: height 0.5s ease; /* Smooth unrolling effect */
}

#contact-info {
    opacity: 0;
    transition: opacity 0.5s ease;
}

footer.open {
    height: 20%;
}

footer.open #contact-info {
    opacity: 1;
}

.box {
    text-align: center;
    color: white;
    background-color: rgba(0, 0, 0, 0.7); /* Slightly darker background */
    padding: 20px;
    margin: 20px auto; /* Add margin for spacing between boxes */
    width: 60%; /* Adjust width to make it more readable */
    max-width: 70vw; /* Optional: prevent it from getting too wide */
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2); /* Add a subtle shadow for a cleaner look */
}

@media (max-width: 768px) {
    .box {
        width: 90%; /* Increase width for smaller screens */
    }
}

.badbox {
    text-align: center;
    color: white;
    background-color: rgba(0, 0, 0, 0.7);
    padding: 20px;
    width: 40%; /* 80% of the left half of the screen */
    max-width: 600px; /* Optional: prevent it from getting too wide */
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
    position: absolute;
    left: 5%; /* Center it within the left half (10% + 40% = centered) */
    top: 40%;
    transform: translateY(-50%); /* Vertically center the box */
}

.container {
    max-width: 80%;
    width: 100%;
    padding: 20px;
    margin: 0 auto;
}

.info-box {
    background: rgba(0, 0, 0, 0.7); /* Semi-transparent black */
    color: white;
    padding: 20px;
    text-align: center;
    margin-bottom: 40px;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.5);
}

.zine-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 20px;
}

.zine-button {
    display: block;
    font-family: Trebuchet MS;
    text-decoration: none;
    color: white;
    text-align: center;
    border: 1px solid black;
    background: rgba(0, 0, 0, 0.5);
    overflow: hidden;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.3);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.zine-button:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 16px rgba(0, 0, 0, 0.5);
}

.zine-button img {
    width: 100%;
    height: 300px;
    object-fit: cover;
}

.zine-button p {
    font-size: 24px;
    padding: 10px;
    background: rgba(0, 0, 0, 0.8);
}
