:root {
    /* Primary Brand Colours */
    --color-sand: #EEEDEA;
    --color-ocean: #0070E0;
    --color-mountain: #04304C;

    /* Highlight Brand Colours */
    --color-emerald: #018B76;
    --color-coral: #D74417;

    --color-cobalt: #0F478D;
}

@font-face {
    font-family: 'VolksansRegular';
    src: url('assets/fonts/Volksans/volksans_Regular.otf') format('opentype');
    font-weight: normal;
    font-style: normal;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

* {
  -webkit-tap-highlight-color: transparent;
}

html,
body {
    overflow: hidden;
    overscroll-behavior: none;
}

body {
    background-color: var(--color-mountain);
    color: var(--color-sand);
    height: 100vh;
    width: 100vw;
    font-family: 'VolksansRegular', sans-serif;
    font-size: 16px;
    line-height: 1.3;
}

.container {
    position: relative;
    height: 100%;
    width: 100%;
}

#map {
    position: fixed;
    top: 0;
    bottom: 0;
    left: 340px;
    right: 0;
    width: auto;
    height: auto;
}

#info-box {
    position: relative;
    top: 0px;
    height: 85px;
    width: 100%;
    border-bottom: 1px solid var(--color-sand);
}

.info-box-container {
    position: relative;
    top: 0px;
    display: flex;
    width: calc(100% - 64px);
    height: 35px;
    margin: 0 auto;
    line-height: 1;
}

.info-box-inner {
    position: relative;
    bottom: 0;
    display: flex;
    overflow-y: hidden;
    overflow-x: auto;
    scroll-snap-type: x mandatory;
    scroll-behavior: smooth;
    gap: 0px;
    width: 100%;
    padding-right: calc(100% - 80px);
    scrollbar-width: none;
    -ms-overflow-style: none;
    overscroll-behavior-x: contain;
}

.info-box-inner::-webkit-scrollbar {
    display: none;
}

.info-feature {
    user-select: none;
    display: flex;
    flex: 0 0 auto;
    flex-direction: column;
    align-items: left;
    justify-content: center;
    scroll-snap-align: start;
    width: 80px;
    height: auto;
    white-space: nowrap;
    cursor: pointer;
}

.info-feature:hover h3 {
    opacity: 100%;
}

.info-feature h3 {
    opacity: 40%;
}

.active-category h3 {
    opacity: 100%;
}

.reset-category {
    width: 40px;
}

#info-box-back,
#info-box-forward {
    display: block;
    width: 25px;
    height: 25px;
    border-radius: 50%;
    z-index: 9999;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 12px;
    padding: 5px;
}

#info-box-back:hover,
#info-box-forward:hover {
    color: hsl(0, 0%, 100%);
}

#info-box-back {
    position: absolute;
    bottom: 3px;
    left: 0;
}

#info-box-forward {
    position: absolute;
    bottom: 3px;
    right: 0;
}

.logo-container {
	position: relative;
	display: block;
	height: 50px;
	width: 100%;
    border-bottom: 1px solid var(--color-sand);
}

.logo {
	position: absolute;
	pointer-events: auto;
}

.logo-top-left {
	top: 3px;
	left: 10px;
}

.logo-top-left svg {
    width: auto;
    height: 10px;
    fill: var(--color-sand);
}

.logo-bottom-left {
	bottom: 2px;
	left: 10px;
}

.logo-bottom-left svg {
    width: auto;
    height: 15px;
    fill: var(--color-sand);
}

.logo-bottom-right {
	bottom: 1px;
	right: 10px;
}

.logo-bottom-right a {
	white-space: nowrap;
	text-decoration: none;
}

.logo-bottom-right .presented-by,
.logo-bottom-right svg {
	display: inline-block;
	vertical-align: top;
}

.logo-bottom-right .presented-by {
	font-size: 10px;
	margin-right: 3px;
    line-height: 1;
    color: var(--color-sand);
}

.logo-bottom-right svg {
	height: 15px;
	width: auto;
}

.logo-bottom-right svg * {
    fill: var(--color-sand);
}

.logo a {
    all: unset;
    cursor: pointer;
    display: block;
}

.logo:hover svg {
    opacity: 0.8;
    transform: scale(1.05);
    transition: 0.2s ease;
}

#popup {
    position: fixed;
    top: 0;
    bottom: 0;
    left: 0;
    width: 330px;
    height: auto;
    margin: 5px 0 5px 5px;
    border-radius: 5px;
    border: 1px solid var(--color-sand);
    user-select: none;
}

#popup-container {
    position: absolute;
    top: 85px;
    left: 0;
    right: 0;
    bottom: 0;
    height: auto;
    overflow-y: hidden;
    overflow-x: hidden;
}

.popup-content {
    position: relative;
    width: 100%;
    height: 100%;
    overflow-y: auto;
    overflow-x: hidden;
    scroll-behavior: smooth;
    scrollbar-width: thin;
    scrollbar-color: var(--color-sand) transparent;
    overscroll-behavior-y: contain;
    -webkit-overflow-scrolling: touch;
}

.popup-content::-webkit-scrollbar {
    width: 8px;
}

.popup-content::-webkit-scrollbar-track {
    background: transparent;
}

.popup-content::-webkit-scrollbar-thumb {
    background-color: var(--color-sand);
    border-radius: 4px;
}

.popup-flex-container {
    position: relative;
    display: flex;
    gap: 24px;
    flex-direction: column;
    align-items: flex-start;
    transition: background-color 0.2s ease;
    border-bottom: 1px solid var(--color-sand);
    padding: 20px;
    cursor: pointer;
}

.popup-flex-container:hover {
    background-color: hsla(0, 0%, 100%, 0.1);
}

.popup-flex-container:last-child {
    border-bottom: none;
}

.popup-flex-container.active::before {
    content: "";
    position: absolute;
    left: 0;
    top: 50%;
    transform: translateY(-50%);
    width: 0;
    height: 0;
    border-top: 10px solid transparent;
    border-bottom: 10px solid transparent;
    border-left: 10px solid var(--color-sand);
    z-index: 100;
}

.popup-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: var(--color-emerald);
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px;
    z-index: 10;
}

.popup-overlay i {
    font-size: 24px;
    cursor: pointer;
}

.title-container {
    margin-bottom: 8px;
    font-size: 20px;
    font-weight: 500;
    letter-spacing: -1%;
    line-height: 120%;
}

.title-container * {
    display: inline;
    vertical-align: baseline;
}

.popup-text-container {
    flex: 1;
}

.popup-time-container {
    display: flex;
    align-items: center;
    gap: 16px;
    font-size: 15px;
    font-weight: 500;
    line-height: 100%;
    letter-spacing: -1%;
}

.popup-address-container {
    display: flex;
    align-items: center;
    gap: 16px;
    margin-bottom: 16px;
    font-size: 15px;
    font-weight: 500;
    line-height: 100%;
    letter-spacing: -1%;
}

.popup-description {
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    text-overflow: ellipsis;
    font-size: 14px;
    font-weight: 400;
    line-height: 140%;
    letter-spacing: -1%;
    opacity: 70%;
    margin: 10px 0;
    overflow-wrap: anywhere;
    word-break: break-word;
    min-width: 0;
}

.popup-link {
    width: 100%;
    padding: 5px;
    text-align: center;
    border-radius: 5px;
    background-color: var(--color-sand);
    color: var(--color-cobalt);
    font-size: 13px;
}

.popup-link:hover {
    background-color: hsl(0, 0%, 100%);
}

.popup-map-icon {
    position: relative;
    font-size: 14px;
    margin-right: 10px;
    top: -2px;
    cursor: pointer;
}

.popup-map-icon:hover {
    color: hsl(227, 89%, 80%);
}

.popup-filter-button {
    display: flex;
    align-items: center;   /* vertical centering */
    justify-content: center; /* optional: horizontal centering */
    position: absolute;
    top: 90px;
    right: 12px;
    color: var(--color-sand);
    font-size: 14px;
    padding: 2px 4px;
    border-radius: 5px;
    border: 1px solid var(--color-sand);
    cursor: pointer;
    user-select: none;
    z-index: 10;
    line-height: 1;
}

.popup-filter-button:hover {
    background-color: hsla(0, 0%, 100%, 0.1);
}

.maplibregl-ctrl-bottom-right {
    display: none;
}

h1 {
    font-size: 24px;
    font-weight: 600;
}

h2 {
    font-size: 20px;
    font-weight: 500;
    line-height: 1.2;
}

h3 {
    font-size: 18px;
    font-weight: 500;
}

h4 {
    font-size: 18px;
    font-weight: 600;
}

p {
    font-size: 16px;
    font-weight: 400;
}

@media (max-width: 768px) {
    #map {
        top: 0;
        bottom: 50%;
        left: 0;
        right: 0;
        width: auto;
        height: calc(50% - 10px);
    }

    #popup {
        top: auto;
        bottom: 0;
        left: 0;
        right: 0;
        height: 50%;
        width: auto;
        margin: 0 5px 5px 5px;
        max-width: calc(100% - 10px);
        border-radius: 5px;
    }
}