body {
    margin: 0;
    font-family: Arial, Helvetica, sans-serif;
    background-color: white;
    color: black;
    display: flex;
    flex-direction: column;
    height: 100vh; /* XXX: This will work for now, but may not play nicely when some non-map pages need to scroll! */
}

/* Header */

#main-header {
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    align-items: center;
    padding: 1rem 0;
    top: 0;
    z-index: 100;
}

#header-nav {
    display: flex;
    flex-direction: row;
    gap: 1rem;
}

#header-nav a {
    text-decoration: none;
    color: #333;
    font-weight: bold;
    padding: 0.5rem 0.75rem;
    border-radius: 2px;
    transition: background-color 0.2s, color 0.2s;
}

#header-nav a:hover {
    background-color: DodgerBlue;
    color: white;
}

/* General map */

main {
    flex: 1 1 auto; /* Fill available vertical space. */
    display: flex;
    flex-direction: column;
    min-height: 0;
}

#map {
    flex: 1; /* Fill available vertical space. */
    min-height: 0;
}

/* Marker */

img.mastr-unit-marker {
    filter: hue-rotate(120deg);
}

img.color-black-to-red {
    filter: invert(23%) sepia(100%) saturate(500%) hue-rotate(0deg) brightness(95%) contrast(105%);
}

img.color-black-to-blue {
    filter: invert(28%) sepia(94%) saturate(500%) hue-rotate(180deg) brightness(90%) contrast(90%);
}

/* Pop-Up */

.unit-popup header {
    margin-bottom: 1em;
    font-weight: bold;
}

.unit-popup-body {
    display: flex;
    flex-direction: column;
    gap: 1em;
}

/* Legend */
.info.legend {
    background: white;
    padding: 8px 12px;
    border-radius: 8px;
    box-shadow: 0 0 6px rgba(0,0,0,0.2);
    font: 14px/16px Arial, Helvetica, sans-serif;
}

.info.legend h4 {
    margin: 0 0 6px;
    font-weight: bold;
}

.info.legend div {
    display: flex;
    align-items: center;
    margin-bottom: 4px;
}

.info.legend img {
    margin-right: 6px;
    vertical-align: middle;
}


/* text-content (used in all expect map) */

#text-content {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 1rem;
}
