body {
    padding: 0;
    margin: 0;
    font: 1em sans-serif;
    font-family: 'Gill Sans', 'Gill Sans MT', Calibri, 'Trebuchet MS', sans-serif;
}

#mapid {
    height: 100vh;
}

.leaflet-control-time.leaflet-control {
    display: flex;
    justify-content: space-evenly;
    flex-direction: row;
    
    margin-right: auto;
    padding: 10px 20px;
    border-radius: 10px;

    width: 90%;
    background-color: rgba(240, 240, 240, 0.95);
}



#exposure-gradient-container {
    display: none;
    background-color: white;
    padding: 0 10px 5px;
    margin-top: 0;
    float: none;
}

#exposure-gradient {
    height: 20px;
    background-image: linear-gradient(to right,
            rgb(0 0 255 / 0.5),
            rgb(0 255 0 / 0.5),
            rgb(255 0 0 / 0.5));
    display: flex;
}

#exposure-gradient>div {
    flex: 1;
    border: 1px solid white;
    text-align: center;
    font-weight: bold;
}


select{
    margin-left: 10px;
    border-radius: 5px;
    padding: 5px;
    background-color: rgba(225, 224, 224, 0.9);
    border: none;
    color: #00000080;
}
select:focus{
    border: none;
    outline: none;
}




.sun-exposure-control{
    display: flex;
    align-items: baseline;
    margin-top: 10px;
    padding: 2px;
    color: #000000;
    
}

#time-display {
    position: absolute;
    top: 10px;
    left: 10px;
    right: auto;
    margin: 0;
    background-color: rgba(240, 240, 240, 0.95);
    padding: 10px;
    border-radius: 10px;
    font-weight: bold;
    font-family: sans-serif;
    z-index: 1000;
}

.route-controls {
    position: absolute;
    display: flex;
    flex-direction: column;
    top: 2%;
    right: 1%;
    background: rgba(240, 240, 240, 0.95);
    padding: 20px;
    border-radius: 10px;
    font-family: sans-serif;
    z-index: 1000;
    width: 280px;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.15);
}

.route-controls input,
.route-controls button {
    width: 100%;
    margin-bottom: 2px;
    margin-top: 9px;
    padding: 12px 7px;
    box-sizing: border-box;
    border-radius: 5px;
    background-color: rgba(225, 224, 224, 0.9);
    border: none;
}

.route-controls label {
    font-size: 0.9em;
    user-select: none;
    margin-bottom: 10px;
}

.legend {
    position: absolute;
    bottom: 4.5%;
    left: 87%;
    background: rgba(240, 240, 240, 0.95);
    padding: 10px;
    border-radius: 10px;
    font-family: sans-serif;
    z-index: 1000;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.15);
}

.leaflet-control-time.leaflet-control button {
    background-color: transparent;
    border: none;
    cursor: pointer;
    margin: 0 0px;
    padding: 7px 8px;
    border-radius: 5px;
}

.leaflet-control-time.leaflet-control button:hover {
    background-color: rgba(108, 108, 108, 0.15);

}

.legend .swatch {
    display: inline-block;
    width: 14px;
    height: 14px;
    margin-right: 6px;
    vertical-align: middle;
}

#sporky-gif {
    position: absolute;
    bottom: 10px;
    /* slightly above legend */
    left: 10px;
    z-index: 1001;
    image-rendering: pixelated;
}

#sporky-gif img {
    width: 80%;
    image-rendering: pixelated;
    height: auto;
}

#route-btn {
    background-color: #1976d2;
    color: rgb(240, 240, 240);
    border: none;
    cursor: pointer;
    padding: 12px 6px;
    font-weight: bold;
    border-radius: 20px;
}

/* Custom modal popup styles */
.sporky-modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.6);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 2000;
    padding: 1rem;
    box-sizing: border-box;
}



.sporky-modal-content {
    background-color: #1e1e2f;
    border-radius: 12px;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.4);
    padding: 1.5rem 2rem;
    max-width: 400px;
    width: 100%;
    color: #e0e0e0;
    animation: modalShow 0.3s ease forwards;
    transform-origin: center;
}

@keyframes modalShow {
    0% {
        opacity: 0;
        transform: scale(0.8);
    }
    100% {
        opacity: 1;
        transform: scale(1);
    }
}

.sporky-modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-weight: 700;
    font-size: 1.25rem;
    color: #fff;
    margin-bottom: 1rem;
}

.close-btn {
    background-color: #2c2c44;
    border: none;
    color: #ccc;
    font-weight: bold;
    font-size: 1.2rem;
    width: 32px;
    height: 32px;
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    justify-content: center;
    align-items: center;
    transition: background-color 0.3s ease, color 0.3s ease;
    line-height: 1;
    padding: 0;
}

.close-btn:hover {
    background-color: #4a90e2;
    color: #fff;
}

.sporky-modal-body {
    font-size: 1rem;
    line-height: 1.5;
    color: #e0e0e0;
    margin-bottom: 1.5rem;
    word-wrap: break-word;
}

.sporky-modal-footer {
    text-align: center;
}

.sporky-modal-footer button {
    background-color: #4a90e2;
    color: #fff;
    border: none;
    padding: 0.6rem 2rem;
    font-size: 1rem;
    font-weight: 600;
    border-radius: 9999px;
    cursor: pointer;
    transition: background-color 0.3s ease;
    user-select: none;
}

.sporky-modal-footer button:hover {
    background-color: #357abd;
}

@media (max-width: 480px) {
    .sporky-modal-content {
        max-width: 90%;
        padding: 1rem 1.25rem;
    }

    .sporky-modal-header {
        font-size: 1.1rem;
    }

    .sporky-modal-body {
        font-size: 0.95rem;
    }

    .sporky-modal-footer button {
        width: 100%;
        padding: 0.75rem 0;
    }
}

/* Filter container in bottom-right */
#filter-container {
  position: absolute;
  bottom: 20px;
  right: 20px;
  z-index: 3000;
}

/* Filter toggle button */
#filter-toggle {
  background: #1976d2;
  color: #fff;
  border: none;
  padding: 8px 14px;
  border-radius: 6px;
  cursor: pointer;
  font-size: 14px;
  font-weight: bold;
  box-shadow: 0 2px 6px rgba(0,0,0,0.3);
  transition: background 0.3s;
}

#filter-toggle:hover {
  background: #125a9c;
}

/* Filter panel */
#filter-panel {
  margin-top: 8px;
  background: #fff;
  border: 1px solid #ccc;
  border-radius: 8px;
  padding: 10px;
  display: none;
  box-shadow: 0 2px 10px rgba(0,0,0,0.2);
}

#filter-panel label {
  display: block;
  margin: 5px 0;
  font-size: 14px;
  color: #333;
}