:root {
    --primary: #007bff;
    --primary-dark: #0056b3;
    --secondary: #28a745;
    --accent: #ffcc00;
    --light: #f8f9fa;
    --dark: #343a40;
    --gray: #6c757d;
    --light-gray: #e9ecef;
    --border-radius: 8px;
    --box-shadow: 0 4px 12px rgba(0,0,0,0.1);
    --transition: all 0.3s ease;
}

* {
    margin: 0;
    padding: 0;
}

body {
    font-family: 'Roboto', sans-serif;
    line-height: 1.6;
    background-color: #f9f9f9;
    color: #333;
    display: flex;
    flex-direction: column;
    min-height: 100vh;
    scroll-behavior: smooth;
}





main {
    flex: 1;
    padding: 1.5rem;
    max-width: 1200px;
    margin: 0 auto;
    width: 100%;
}

h1 {
    color: var(--dark);
    margin-bottom: 1.5rem;
    font-weight: 700;
    text-align: center;
    font-size: 2rem;
}

form {
    background: #fff;
    border-radius: var(--border-radius);
    box-shadow: var(--box-shadow);
    padding: 2rem;
    margin: 0 auto;
    max-width: 800px;
}

.form-group {
    margin-bottom: 1.5rem;
}

label {
    display: block;
    margin-bottom: 0.5rem;
    font-weight: 600;
    color: var(--dark);
}

input[type="text"],
input[type="file"],
select {
    width: 100%;
    padding: 0.75rem;
    border: 1px solid var(--light-gray);
    border-radius: var(--border-radius);
    font-family: inherit;
    font-size: 1rem;
    transition: var(--transition);
}

input[type="text"]:focus,
input[type="file"]:focus,
select:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(0,123,255,0.1);
}

button[type="button"],
button[type="submit"] {
    background: var(--primary);
    color: white;
    border: none;
    padding: 0.75rem 1.5rem;
    border-radius: var(--border-radius);
    cursor: pointer;
    font-weight: 600;
    font-size: 1rem;
    transition: var(--transition);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
}

button[type="button"]:hover,
button[type="submit"]:hover {
    background: var(--primary-dark);
    transform: translateY(-2px);
}

button[type="submit"] {
    background: var(--secondary);
    width: 100%;
    margin-top: 1rem;
}

button[type="submit"]:hover {
    background: #218838;
}

.instructions {
    color: var(--gray);
    font-size: 0.9rem;
    margin: 1rem 0;
    font-style: italic;
}

#container {
    display: grid;
    grid-template-columns: 1fr 2fr;
    gap: 1.5rem;
    margin: 2rem 0;
}

#picture {
    border: 1px solid var(--light-gray);
    border-radius: var(--border-radius);
    background: var(--light);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    min-height: 300px;
    overflow: hidden;
    position: relative;
}

#picture img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

#picture::before {
    content: "Preview of image will appear here";
    position: absolute;
    color: var(--gray);
    font-size: 0.9rem;
    text-align: center;
    padding: 1rem;
}

#picture.has-image::before {
    display: none;
}

/* Replace all existing #map rules with this single block to avoid conflicts */
#map {
    height: 400px; /* Fixed height */
    width: 100%;   /* Full width */
    border-radius: var(--border-radius); /* Rounded corners */
    border: 1px solid var(--light-gray); /* Light border */
    background-color: var(--light);      /* Fallback if map fails to load */
}
    

.error-message {
    color: #dc3545;
    font-size: 0.85rem;
    margin-top: 0.25rem;
    display: none;
}

.error-message.show {
    display: block;
}

#location-message {
    margin: 1rem 0;
    font-weight: 600;
}

footer {
    background: var(--dark);
    color: white;
    text-align: center;
    padding: 1rem;
    margin-top: auto;
}

footer p {
    margin: 0;
    font-size: 0.9rem;
}

#visit-count {
    font-weight: 700;
}



/* Loading spinner */
.loading-spinner {
    border: 5px solid #f3f3f3;
    border-top: 5px solid #4CAF50;
    border-radius: 50%;
    width: 50px;
    height: 50px;
    animation: spin 1s linear infinite;
    margin: 20px auto;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* Responsive styles */
@media (max-width: 768px) {
    header {
        position: static;
        flex-direction: column;
        height: auto;
        padding: 10px;
    }

    .header-left {
        width: 100%;
        justify-content: space-between;
    }
    
    header img.logo {
        max-width: 80px;
    }
    
    .logo-divider {
        display: none;
    }
    
    nav ul {
        flex-wrap: wrap;
        justify-content: center;
        gap: 0.75rem;
        padding: 0.5rem 0;
    }
    
    nav ul li a {
        font-size: 0.85rem;
        padding: 0.5rem;
    }
    
    #container {
        grid-template-columns: 1fr;
    }
    
    #picture {
        min-height: 200px;
    }
    
    form {
        padding: 1.5rem;
    }
}

@media (max-width: 480px) {
    h1 {
        font-size: 1.5rem;
    }
    
    .header-left {
        flex-direction: column;
        gap: 0.5rem;
    }
    
    nav ul {
        gap: 0.5rem;
    }
    
    nav ul li a {
        font-size: 0.8rem;
    }
    
    form {
        padding: 1.25rem;
    }
    
    button[type="button"],
    button[type="submit"] {
        width: 100%;
    }
    
    #picture {
        min-height: 150px;
    }
}

/* Email field styling */
#user-email {
    width: 100%;
    padding: 10px;
    border: 1px solid #ccc;
    border-radius: 4px;
    font-size: 16px;
}

.help-text {
    font-size: 12px;
    color: #666;
    margin-top: 5px;
}

#email-error {
    color: #dc3545;
    font-size: 14px;
    margin-top: 5px;
}

/* Main Content Styles */
.about-section {
    background-color: white;
    padding: 30px;
    border-radius: var(--border-radius);
    box-shadow: var(--box-shadow);
    margin-bottom: 30px;
}

.mission-highlight {
    background-color: rgba(0, 123, 255, 0.1);
    padding: 20px;
    border-left: 4px solid var(--primary);
    margin: 20px 0;
    border-radius: 0 var(--border-radius) var(--border-radius) 0;
}

.mission-highlight p {
    margin: 0;
    font-size: 1.1rem;
    font-weight: 500;
}

ul {
    padding-left: 20px;
}

li {
    margin-bottom: 10px;
    font-size: 1.1rem;
}

.cta-button {
    display: inline-block;
    padding: 12px 24px;
    background-color: var(--primary);
    color: white;
    border: none;
    border-radius: var(--border-radius);
    font-size: 1.1rem;
    cursor: pointer;
    margin: 20px 0;
    transition: var(--transition);
    text-decoration: none;
    text-align: center;
}

.cta-button:hover {
    background-color: var(--primary-dark);
    transform: translateY(-2px);
    box-shadow: 0 6px 12px rgba(0,0,0,0.15);
}

.cta-button i {
    margin-right: 8px;
}

.team-section {
    margin-top: 40px;
}

.team-grid {
    display: flex;
    flex-wrap: wrap;
    gap: 30px;
    justify-content: center;
    margin-top: 20px;
}

.team-member {
    background-color: white;
    border-radius: var(--border-radius);
    box-shadow: var(--box-shadow);
    padding: 20px;
    text-align: center;
    max-width: 250px;
    transition: var(--transition);
}

.team-member:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 16px rgba(0,0,0,0.15);
}

.team-member img {
    width: 150px;
    height: 150px;
    border-radius: 50%;
    object-fit: cover;
    margin-bottom: 15px;
    border: 3px solid var(--accent);
}

.team-member h3 {
    color: var(--primary);
    margin: 10px 0 5px;
}

.team-member p {
    color: var(--dark);
    font-size: 0.9rem;
    margin: 0;
}

/* Location Search Group Styles */
.location-search-group label {
    margin-bottom: 0.5rem;
    display: block;
}

.search-container {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    width: 100%;
}

#search-box {
    flex: 1;
    min-width: 0; /* Prevent flex item from overflowing */
}

.search-or {
    color: var(--gray);
    font-size: 0.9rem;
    white-space: nowrap;
}

#find-location {
    white-space: nowrap;
    padding: 0.75rem 1rem;
}

/* Responsive adjustments */
@media (max-width: 480px) {
    .search-container {
        flex-direction: column;
        align-items: stretch;
    }
    
    .search-or {
        text-align: center;
        margin: 0.5rem 0;
    }
    
    #find-location {
        width: 100%;
    }
    
    .team-grid {
        flex-direction: column;
        align-items: center;
    }
    
    .team-member {
        max-width: 100%;
    }
}

/* Standardized Header Styles to match index.css */

/* Header Styles */
header {
    background: var(--primary);
    color: #fff;
    padding: 1rem 2rem;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
    position: static;
    top: 0;
    z-index: 1000;
}

.header-left {
    max-width: 1200px;
    margin: 0 auto;
    display: flex;
    justify-content: flex-start;
    align-items: center;
    flex-wrap: wrap;
    gap: 1rem;
}

.branding {
    display: flex;
    align-items: center;
    gap: 1rem;
}

header h4 {
    font-size: 1.5rem;
    font-weight: 700;
    margin: 0;
}

.logo {
    height: 40px;
    width: auto;
    transition: var(--transition);
    cursor: pointer;
}

.logo:hover {
    transform: scale(1.05);
    opacity: 0.9;
}

nav ul {
    display: flex;
    list-style: none;
    gap: 1.5rem;
    padding: 0;
    margin: 0;
}

nav a {
    color: #fff;
    text-decoration: none;
    font-weight: 500;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.5rem 0;
    position: relative;
    transition: var(--transition);
}

nav a:hover {
    color: var(--accent);
}

nav a::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 0;
    height: 2px;
    background: var(--accent);
    transition: var(--transition);
}

nav a:hover::after {
    width: 100%;
}

.logo-divider {
    height: 30px;
    width: 2px;
    background: rgba(255,255,255,0.5);
}

/* Responsive header styles */
@media (max-width: 768px) {
    header {
        position: static;
        flex-direction: column;
        height: auto;
        padding: 10px;
    }

    .header-left {
        width: 100%;
        justify-content: space-between;
    }
    
    header img.logo {
        max-width: 80px;
    }
    
    .logo-divider {
        display: none;
    }
    
    nav ul {
        flex-wrap: wrap;
        justify-content: center;
        gap: 0.75rem;
        padding: 0.5rem 0;
    }
    
    nav ul li a {
        font-size: 0.85rem;
        padding: 0.5rem;
    }
}

@media (max-width: 480px) {
    h1 {
        font-size: 1.5rem;
    }
    
    .header-left {
        flex-direction: column;
        gap: 0.5rem;
    }
    
    nav ul {
        gap: 0.5rem;
    }
    
    nav ul li a {
        font-size: 0.8rem;
    }
}