/* styles.css */
html,
body {
    height: 100%;
    width: 100%;
    margin: 0;
    padding: 0;
    overflow: hidden;
    /* Prevent scrolling */
    font-family: 'Roboto', sans-serif;
}

/* Header */
header {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 60px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 20px;
    box-sizing: border-box;
    z-index: 100;
    /* Above map */
    background: rgba(255, 255, 255, 0.9);
    /* Slight transparency */
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.logo-container img {
    height: 40px;
    /* Adjust based on SVG aspect ratio */
    display: block;
}

.hamburger-btn {
    background: none;
    border: none;
    cursor: pointer;
    font-size: 24px;
    color: #333;
}

/* Navigation Overlay */
.nav-overlay {
    position: fixed;
    top: 0;
    right: -100%;
    /* Hidden off-screen */
    width: 250px;
    height: 100%;
    background: #fff;
    box-shadow: -2px 0 5px rgba(0, 0, 0, 0.2);
    transition: right 0.3s ease;
    z-index: 200;
    /* Above header */
    padding-top: 60px;
}

.nav-overlay.open {
    right: 0;
}

.nav-overlay ul {
    list-style: none;
    padding: 0;
    margin: 0;
}

.nav-overlay li {
    border-bottom: 1px solid #eee;
}

.nav-overlay a {
    display: block;
    padding: 15px 20px;
    text-decoration: none;
    color: #333;
    font-weight: bold;
}

.nav-overlay a:hover {
    background-color: #f9f9f9;
}

.close-nav-btn {
    position: absolute;
    top: 15px;
    right: 20px;
    background: none;
    border: none;
    font-size: 24px;
    cursor: pointer;
}

/* Modal */
.modal-backdrop {
    display: none;
    /* Hidden by default */
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    z-index: 300;
    align-items: center;
    justify-content: center;
}

.modal-backdrop.visible {
    display: flex;
}

.modal-content {
    background: #fff;
    padding: 20px;
    border-radius: 8px;
    position: relative;
    max-width: 80%;
    /* 80% width as requested */
    width: 80%;
    max-height: 90%;
    overflow: auto;
    text-align: center;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
}

.modal-content h2,
.modal-content h3 {
    font-size: 2.5rem;
    /* Significantly larger title */
    margin-top: 10px;
    margin-bottom: 20px;
}

/* Legend Specific: Force 80% height and larger content */
.modal-content.legend-content {
    height: 80%;
    /* User requested 80% strictly */
    display: flex;
    flex-direction: column;
    align-items: center;
    overflow: auto;
    /* Allow scrolling if image is huge */
}

.modal-content.legend-content img {
    height: 100%;
    /* Fill the 80% height */
    width: auto;
    /* Maintain aspect ratio */
    min-width: 800px;
    /* Force it to be "big" (300% logic) to ensure readability */
    object-fit: contain;
    margin: 0 auto;
    /* Ensure centering */
}

/* About Text Specific */
.modal-content.text-content {
    /* max-width removed to allow global 80% */
    text-align: left;
}

.modal-close-btn {
    position: absolute;
    top: 10px;
    right: 15px;
    font-size: 24px;
    cursor: pointer;
    background: none;
    border: none;
    font-weight: bold;
    z-index: 10;
}

.modal-content img {
    max-width: 100%;
    height: auto;
    display: block;
    margin-top: 20px;
}

/* Map Container */
#map {
    position: absolute;
    top: 60px;
    /* Below header */
    bottom: 0;
    left: 0;
    right: 0;
    width: 100%;
    height: calc(100% - 60px);
    /* Explicit height calculation as fallback */
}

/* Content Page (About) */
.page-content {
    margin-top: 80px;
    /* Below header */
    padding: 20px;
    max-width: 800px;
    margin-left: auto;
    margin-right: auto;
}