/*** General ***/

html, body, #map {
    height: 100%;
    width: 100%;
    -webkit-touch-callout: none;
    -webkit-user-select: none;
    -khtml-user-select: none;
    -moz-user-select: none;
    -ms-user-select: none;
    user-select: none;
}

body {
    padding-top: 80px;
    min-width: 340px; 
}

pre {
    font-size: 1.3em!important;
}

.leaflet-bar button {
   font-size: 12px;
   font-family: unset;
}

.leaflet-popup-tip {
    display:none;
}

.leaflet-popup-content {
    line-height:1;
}

.leaflet-popup-content p {
    margin: 1em 0;
}

.leaflet-touch .leaflet-bar button {
    width: 30px;
    height: 30px;
    line-height: 30px;
}

.easy-button-button .button-state {
    display: block;
    width: 100%;
    height: 100%;
    position: relative;
}

* {
    -webkit-box-sizing: border-box;
    -moz-box-sizing: border-box;
    box-sizing: border-box;
}

@font-face {
  font-family:"Rye";
  src: url("../fonts/Rye-Regular.ttf") format("truetype");
}

/* font awesome hack */
.fa {
    line-height: 30px!important;
}

.noselect {
    -webkit-touch-callout: none;
    -webkit-user-select: none;
    -khtml-user-select: none;
    -moz-user-select: none;
    -ms-user-select: none;
    user-select: none;
}

/*** Navigation ***/

.navbar {
    background: #0cc0df;
    border-width: 0px;
    min-height: 80px;
}

.navbar-brand {
    font-family: 'Barriecito', cursive; 
    font-size: calc(48px + 1vw);
    letter-spacing: 0.2em;
    white-space: nowrap; 
    display: inline-block;
    vertical-align: middle;
    color: #fff!important;
    padding-left: 15px;
    padding-top: 15px;
    padding-bottom: 80px;
    line-height: 1.2;
}

.navbar-default .navbar-brand:hover {
    color: #43f5ec;
    cursor: default;
}

.navbar-toggle {
    background-color: #fff!important;
    position: relative;
    float: right;
    padding: 9px 10px;
    margin-top: 8px;
    margin-right: 7px;
    margin-bottom: 6px;
    background-color: transparent;
    background-image: none;
    border: 2px solid;
    border-radius: 4px;
    border-color: #00000060!important;
}

ul.nav.navbar-nav.navbar-right a {
    color: #fff;
    transition: color 0.4s;
    font-family: inherit; 
    font-size: calc(12px + .3vw);
    margin-right: 10px;
}

.leaflet-control-attribution {
  /* position: absolute !important; */
  bottom: 10px !important;
  right: 10px !important;
  background: rgba(255, 255, 255, 0.8) !important;
  padding: 5px !important;
  font-size: 1.4em;
}

/*** Map Controls ***/

.leaflet-control-zoom {
    margin-top: 30px !important;
    margin-right: 10px !important;
}

/* Track line animation */
.animated-track {
    stroke-dasharray: 6;
    animation: dash 90s linear infinite;
}

/* Moving emoji marker */
.moving-emoji {
    font-size: 24px;
}

@keyframes dash {
    to {
        stroke-dashoffset: -1000;
    }
}

.leaflet-bar button {
    font-size: 12px;
    font-family: unset;
}

.leaflet-touch .leaflet-bar button {
    width: 30px;
    height: 30px;
    line-height: 30px;
}

/*** Popups ***/

.leaflet-popup-tip {
    display: none;
}

.leaflet-popup-content {
    line-height: 1;
}

.leaflet-popup-content p {
    margin: 1em 0;
}

.trailPopupClass .leaflet-popup-content-wrapper {
    padding: 5px;
    text-align: left;
    border-radius: 0px !important;
    width: 300px;
}

.pop_cont_name {
    font-weight: bold;
    font-size: 2em;
    line-height: 2em;
}

.pop_gpx_text {
    font-size: 1.3em;
    text-align: left;
    padding: 5px;
    overflow-y: hidden;
    overflow-x: hidden;
}

.pt_labels {
	font-size: 1.2em;
	font-weight: bold;
	background-color: white;
	padding: 5px;
	border-radius: 3px;
}

.close-btn {
		color: black;
		padding: 5px 10px;
		background: #ccc;
		cursor: hand;
		position: relative;
		right: 10px;
		top: 0;
	}
.close-btn:hover {
		background: #aaa;
}

.custom-div-icon {
    background: transparent;
    border: none;
}

.custom-div-icon i {
    font-size: 16px;
    color: #0099ff;
    text-shadow: 2px 2px 2px rgba(0,0,0,0.5);
    background: rgb(241, 241, 241);
    width: 23px;
    height: 27px;
    line-height: 27px;
    text-align: center;
    border-radius: 10%;
    display: block;
    box-shadow: 0 2px 4px rgba(0,0,0,0.2);
    transition: all 0.3s ease;
}

.custom-div-icon i.pulse {
    animation: pulse 1s ease-in-out;
}

.custom-div-icon i:hover {
    transform: scale(1.2);
    background: #fff;
    box-shadow: 0 4px 8px rgba(0,0,0,0.3);
}

.custom-div-icon .fa-hashtag {
    font-size: 18px;
    line-height: 27px;
}

.custom-div-icon .start-flag, .custom-div-icon .end-flag {
    animation: pulse 2s infinite;
}

.custom-div-icon .end-flag {
    color: #e33737;
}

.custom-div-icon .start-flag {
    color: #02871c;
}

.download-button {
    width: 35px;
    height: 35px;
    line-height: 35px;
    text-align: center;
    background: white;
    color: #0099ff;
    text-decoration: none;
    display: block;
}

.download-button i {
    font-size: 18px;
    margin-top: 8px;
}

.download-button:hover {
    background: #f8f8f8;
    color: #0066cc;
}

/* Marker animations */
.custom-div-icon i.rotate {
    animation: rotate 1s ease-in-out;
}

.custom-div-icon i.gold {
    color: #FFD700; /* Gold color */
    background: #fff;
    box-shadow: 0 2px 4px rgba(255, 215, 0, 0.3);
}

@keyframes rotate {
    0% {
        transform: rotate(0deg);
    }
    100% {
        transform: rotate(900deg);
    }
}

@keyframes bounce {
    0%, 100% {
        transform: translateY(0);
    }
    50% {
        transform: translateY(-5px);
    }
}

@keyframes pulse {
    0% {
        transform: scale(0.5);
    }
    50% {
        transform: scale(1.25);
        background: #fff;
    }
    100% {
        transform: scale(0.5);
    }
}

/* Banner for pre-release */
.release-banner {
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%) rotate(-28deg);
    background: linear-gradient(45deg, #ff6b6b, #ffb7b7, #ff6b6b);
    background-size: 250% 150%;
    animation: gradientMove 3s ease infinite;
    color: white;
    padding: 20px 20px;
    font-size: 2em;
    letter-spacing: 2px;
    font-family: 'Barriecito', cursive;
    z-index: 9999;
    white-space: nowrap;
    display: none; /* Hidden by default */
}

/* Post-release banner */
.post-release-banner {
    position: fixed;
    top: 80px; /* Position under navbar */
    left: 50%;
    transform: translateX(-50%);
    background: linear-gradient(45deg, #15543f, #2ae3a5, #15543f);
    background-size: 150% 150%;
    animation: gradientMove 2s ease infinite;
    color: white;
    padding: 10px 10px;
    font-size: 2em;
    font-family: 'Barriecito', cursive;
    z-index: 9999;
    white-space: nowrap;
    display: none; /* Hidden by default */
    box-shadow: 0 4px 15px rgba(0,0,0,0.2);
    cursor: pointer; /* Add pointer cursor */
}

@keyframes gradientMove {
    0% {
        background-position: 0% 50%;
    }
    50% {
        background-position: 100% 50%;
    }
    100% {
        background-position: 0% 50%;
    }
}

/* Hide animated emoji */
.animated-emoji {
    display: none;
}

/*** Responsive Design ***/

@media screen and (max-width: 480px) {
    body {
        padding-top: 70px;
    }
    
    .navbar {
        min-height: 70px;
    }
    
    .navbar-default .navbar-brand {
        font-size: 2.3em;
        padding-bottom:0px;
    }
    .release-banner {
        font-size: 1.9em!important;
        padding: 10px 10px!important;
        transform: translate(-50%, -50%) rotate(-60deg)!important;
    }
}

@media screen and (max-width: 400px) {
    body {
        padding-top: 60px;
    }
    
    .navbar {
        min-height: 60px;
    }
    
    .navbar-default .navbar-brand {
        font-size: 2.1em;
        padding-bottom: 0px;
    }
}

.gps-instructions-popup {
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    background: white;
    padding: 20px;
    border-radius: 10px;
    box-shadow: 0 4px 8px rgba(0,0,0,0.2);
    z-index: 1000;
    max-width: 90%;
    width: 300px;
    text-align: center;
    display: none;
}

.gps-instructions-popup.active {
    display: block;
}

.gps-instructions-popup p {
    margin: 0 0 15px;
    font-size: 16px;
    line-height: 1.4;
}

.gps-instructions-popup button {
    background: #0cc0df;
    color: white;
    border: none;
    padding: 8px 20px;
    border-radius: 5px;
    cursor: pointer;
    font-size: 14px;
}

.gps-instructions-popup button:hover {
    background: #0aa8c4;
}

.leaflet-control-layers-toggle {
    cursor: pointer;
}

.leaflet-control-layers-toggle:hover,
.leaflet-control-layers-toggle:active,
.leaflet-control-layers-toggle:focus {
    text-decoration: none !important;
    outline: none;
    background-color: white;
}

.leaflet-bar a {
    text-decoration: none !important;
}

.leaflet-bar a:hover,
.leaflet-bar a:active,
.leaflet-bar a:focus {
    text-decoration: none !important;
    outline: none;
}

.leaflet-control-layers-expanded {
    padding: 6px 10px;
    font-size: 14px;
}

.leaflet-control-layers label {
    margin: 0;
    padding: 2px 0;
}

.leaflet-control-layers-selector {
    margin-right: 5px;
}
