/* Modern, Professional Styles.css with a Sleek Purple Theme */
body {
    font-family: 'Lato', sans-serif;
    margin: 0;
    padding: 0;
    line-height: 1.6;
    background-color: #f9f9f9; /* Light gray background for contrast */
    color: #333;
}

/* Container Layout */
.container {
    max-width: 1100px;
    margin: 0 auto;
    padding: 25px 15px;
}

/* Headers & Text */
h1, h2, h3 {
    color: #6a1b9a; /* Rich purple for headers */
    text-align: center;
    font-weight: bold;
    margin-bottom: 20px; /* Increased spacing for better readability */
}

p {
    font-size: 1rem;
    line-height: 1.6;
    margin-bottom: 20px;
    text-align: left;
    color: #444; /* Slightly darker text for better contrast */
}

/* Navigation Bar */
header {
    text-align: center;
    padding: 15px 0;
    background-color: #ffffff;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1); /* Subtle shadow for depth */
}

nav {
    display: flex;
    justify-content: center;
    flex-wrap: nowrap; /* Prevents wrapping */
    gap: 8px; /* Adjust spacing */
    overflow-x: auto; /* Allows horizontal scrolling if necessary */
    white-space: nowrap; /* Prevents line breaks */
}

nav a {
    color: #6a1b9a; /* Rich purple for links */
    text-decoration: none;
    font-size: 0.9rem; /* Reduced font size slightly to fit on mobile */
    font-weight: bold;
    padding: 3px 6px;
    transition: color 0.3s ease-in-out;
}

nav a:hover {
    color: #9c27b0; /* Lighter purple on hover */
    text-decoration: underline;
}

/* Ensure scrolling works */
html, body {
    overflow-y: auto;
    scroll-behavior: smooth;
}

/* Universal Button Styling */
.button {
    display: inline-flex;
    justify-content: center;
    align-items: center;
    background-color: #6a0dad; /* Purple background */
    color: white;
    padding: 12px 20px;
    text-decoration: none;
    border-radius: 6px; /* Smooth rounded corners */
    font-weight: bold;
    font-size: 1rem;
    text-align: center;
    white-space: nowrap; /* Prevents text from wrapping */
    transition: all 0.3s ease-in-out;
    border: none; /* Removes default button borders */
    cursor: pointer;
    box-shadow: 0px 3px 5px rgba(0, 0, 0, 0.2); /* Adds slight shadow for depth */
}

/* Hover Effect */
.button:hover {
    background-color: #9c27b0; /* Lighter purple hover */
    box-shadow: 0px 4px 8px rgba(0, 0, 0, 0.3);
}

/* Active/Clicked Effect */
.button:active {
    background-color: #4a0072; /* Darker shade when clicked */
    box-shadow: inset 0px 3px 6px rgba(0, 0, 0, 0.3);
}

/* Buttons Section */
.buttons {
    display: flex;
    justify-content: center;
    gap: 12px; /* Ensures even spacing */
    flex-wrap: wrap; /* Prevents weird alignment */
    margin-bottom: 30px; /* Adds space before the image */
}

/* Mobile Fix: Stack Buttons in 2x2 Grid for Specific Sections */
@media (max-width: 600px) {
    .buttons {
        flex-wrap: wrap; /* Enables wrapping */
        justify-content: center;
        gap: 10px; /* Ensures even spacing */
    }

    /* 2x2 Grid Stacking */
    .one-time-donation-buttons,
    .sustaining-member-buttons,
    .membership-plan-buttons,
    .one-time-donor-options {
        display: grid;
        grid-template-columns: repeat(2, 1fr); /* 2 columns */
        gap: 10px; /* Space between buttons */
        justify-content: center;
        align-items: center;
    }
}

/* Desktop Layout - No Changes */
@media (min-width: 601px) {
    .one-time-donation-buttons,
    .sustaining-member-buttons,
    .membership-plan-buttons,
    .one-time-donor-options {
        display: flex; /* Maintains horizontal layout on desktop */
        flex-wrap: wrap;
        justify-content: center;
        gap: 12px;
    }
}

/* ZIP Search Box Styling */
#zip-search {
    text-align: center;
    margin: 20px auto;
    padding: 20px;
    background-color: #ffffff;
    border-radius: 8px;
    box-shadow: 0px 3px 5px rgba(0, 0, 0, 0.2);
    max-width: 500px;
}

/* Style the ZIP input field */
#zipInput {
    padding: 12px;
    width: 80%;
    max-width: 300px;
    border: 2px solid #6a0dad;
    border-radius: 6px;
    font-size: 1rem;
    text-align: center;
    outline: none;
    transition: border-color 0.3s ease-in-out;
}

#zipInput:focus {
    border-color: #9c27b0;
}

/* ZIP Search Button - Matching the Others */
#zip-search button {
    display: inline-flex;
    justify-content: center;
    align-items: center;
    background-color: #6a0dad; /* Purple background */
    color: white;
    padding: 12px 20px;
    text-decoration: none;
    border-radius: 6px;
    font-weight: bold;
    font-size: 1rem;
    text-align: center;
    white-space: nowrap;
    transition: all 0.3s ease-in-out;
    border: none;
    cursor: pointer;
    box-shadow: 0px 3px 5px rgba(0, 0, 0, 0.2); /* Adds slight shadow for depth */
    margin-top: 10px;
}

/* Hover effect */
#zip-search button:hover {
    background-color: #9c27b0;
    box-shadow: 0px 4px 8px rgba(0, 0, 0, 0.3);
}

/* Click effect */
#zip-search button:active {
    background-color: #4a0072;
    box-shadow: inset 0px 3px 6px rgba(0, 0, 0, 0.3);
}

/* ========== Design Contest Popup Styles ========== */
.contest-popup {
    display: none;
    position: fixed;
    bottom: 20px;
    right: 20px;
    width: 350px;
    max-width: 90%;
    background-color: #f8f1ff;
    border: 3px solid #6a1b9a;
    border-radius: 10px;
    padding: 15px;
    box-shadow: 0 5px 15px rgba(0,0,0,0.3);
    z-index: 1000;
    animation: slideIn 0.5s ease-out;
}

.contest-popup.show {
    display: block;
}

@keyframes slideIn {
    from { transform: translateX(100%); }
    to { transform: translateX(0); }
}

.contest-popup-close {
    position: absolute;
    top: 5px;
    right: 10px;
    font-size: 20px;
    cursor: pointer;
    color: #6a1b9a;
}

.contest-popup h3 {
    color: #6a1b9a;
    margin-top: 0;
    font-size: 20px;
}

.contest-popup p {
    font-size: 14px;
    margin-bottom: 10px;
}

.contest-popup .button {
    display: block;
    text-align: center;
    margin-top: 10px;
    padding: 8px;
    font-size: 14px;
}

.design-slideshow-container {
    max-width: 100%;
    margin: 10px auto;
    position: relative;
    overflow: hidden;
}

.design-slideshow {
    display: flex;
    transition: transform 0.5s ease-in-out;
}

.design-slideshow img {
    width: 100%;
    height: auto;
    flex-shrink: 0;
    object-fit: cover;
}

.slideshow-nav {
    display: flex;
    justify-content: space-between;
    margin-top: 5px;
}

.slideshow-btn {
    background: #6a1b9a;
    color: white;
    border: none;
    padding: 5px 10px;
    border-radius: 5px;
    cursor: pointer;
    transition: all 0.3s ease;
}

.slideshow-btn:hover {
    background: #4a125a;
    transform: translateY(-1px);
}

/* Mobile adjustments for popup */
@media (max-width: 480px) {
    .contest-popup {
        width: 90%;
        right: 5%;
        bottom: 10px;
    }
    
    .contest-popup h3 {
        font-size: 18px;
    }
    
    .contest-popup p {
        font-size: 13px;
    }
    
    .design-slideshow-container {
        margin: 8px auto;
    }
    
    .slideshow-btn {
        padding: 4px 8px;
        font-size: 12px;
    }
}