/*                                                                  Options   */

#options {
    left: 100%;
    color: var(--txt-light);
}

#options.opennav {
    transform: translateX(-100%);
}

#options header > span {
    flex: 1;
    text-align: center;
    padding: 12px 0;
    cursor: default;
}

#options header .menuclose {
    border-left: none;
    border-right: var(--border-dark)
}

#options header > span:hover,
#options header > span:active,
#options header > span:focus {
    color: var(--txt-light);
}

nav ul li>a {
    font-size: 1rem;
}

#options li:not(.navbottom li) {
    border-bottom: var(--border-thin-gray);
}

.accordion-body {
    display: grid;
    grid-template-rows: 1fr;
    transition: .4s grid-template-rows ease;
}

.accordion-body.close {
    grid-template-rows: 0fr;
}

.accordion-body > div {
    overflow: hidden;
}

.accordion > div,
.accordion > label {
    display: flex;
    border-bottom: var(--border-thin-gray);
    font-size: 1rem;
    padding: 10px 15px;
    flex-direction: row;
    cursor: pointer;
    align-items: center;
}

.accordion > div {
    padding: 9px 15px
}

.menusection .optionlabel {
    display: flex;
    transform: translateY(-1px);
    border-top: var(--border-accent);
    height: 22px;
    color: var(--accent);
    font-size: .8rem;
    padding: 3px;
    cursor: pointer;
    justify-content: center;
    transition: height .5s, padding .5s;
}

.optionlabel svg{
    position: absolute;
    height: 18px;
    width: 18px;
    stroke: var(--accent);
    right: 10px;
    transition: transform .5s
}

.menusection:has(div.close) .optionlabel svg{
    transform: rotate(-180deg);
}

.accordion div.noclick {
    cursor: default;
}

.optionlabel:has(+.accordion-body.close) {
    padding-top: 8px;
    height: 32px;
}

.accordion ul li > a {
    font-size: 1rem;
    padding: 9px 15px
}

.accordion > label.disabled {
    color: var(--txt-light-disabled);
}

.accordion>label.disabled:hover,
.accordion>label.disabled:active,
.accordion>label.disabled:focus {
    color: var(--txt-light-disabled);
}

.accordion svg {
    margin-right: 21px;
    vertical-align: text-top;
    width: 21px;
    height: 21px;
    stroke: var(--txt-light);
}

.accordion>div:not(.noclick):hover,
.accordion>div:not(.noclick):active,
.accordion>div:not(.noclick):focus,
.accordion>label:hover,
.accordion>label:active,
.accordion>label:focus {
    color: var(--txt-light-focus);
}

.accordion>div:hover > svg,
.accordion>div:active > svg,
.accordion>div:focus > svg {
    stroke: var(--txt-light-focus);
}

.accordion .slider {
    background-color: var(--back-light);
}

.accordion .slider:before {
    background-color: var(--lightgray);
}

.accordion input:checked+.slider {
    background-color: var(--back-light);
}

.accordion input:checked+.slider::before {
    background-color: var(--accent);
}

.numpicker {
    display: flex;
    position: relative;
    align-items: center;
    background: var(--back-light);
    border-radius: 5px;
    margin-right: 10px;
    width: 68px;
    height: 21px
}

.numpicker input {
    position: absolute;
    left: 20px;
    width: 28px;
    height: 21px;
    font-size: 1rem;
    text-align: center;
    border: none;
    background:  var(--back-light);
    color: var(--txt-dark);
    cursor: default;
    pointer-events: none
}

.numpickbtn {
    position: absolute;
    background: none;
    width: 30px;
    height: 24px;
    border: none;
    cursor: pointer;
    border-radius: 5px;
}

button.numpickbtn:focus,
button.numpickbtn:hover {
    background: none;
}

.numpickbtn.left {
    left: 0px;
    text-align: left;
}

.numpickbtn.right {
    right: 0px;
    text-align: right;
}

.numpickbtn svg {
    height: 14px;
    width: 14px;
    margin: 3px;
    stroke-width: 4.5px;
    stroke: var(--txt-dark);
}

.menusection select {
    margin-right: .4em;
    padding: 1px 0;
    border-radius: 5px;
    cursor: pointer;
}

/*                                                                     Banner */
.banner {
    padding: 10px;
    position: fixed;
    background: var(--back-light);
    z-index: 45;
    display: flex;
    flex-direction: column;
    width: 100vw;
    min-width: 300px;
    box-shadow: var(--big-shadow);
    top: 100%;
    transform: translateY(0);
    transition: transform .5s, top .5s;
}

.banner > h2 {
    font-size: 1.1rem;
    text-align: center;
    padding-bottom: 11px;
    border-bottom: var(--border-accent);
}

.banner>div {
    display: flex;
    justify-content: center;
}

.banner > div > div{
    margin: 5px;
    padding: 10px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    text-align: center;
}

.banner > div > div a {
    margin-bottom: 10px
}

/*                                                                      Login */
#loginDialog {
    flex-direction: column;
    align-items: center;
    width: 100%;
}

.banner #loginwrapper {
    position: relative;
    width: 100%;
    max-width: 400px;
    height: 270px;
    padding: 0;
    margin: 0;
    display: block;
    overflow: hidden;
}

#loginwrapper input {
    border: none;
    border-radius: 0;
    border-bottom: var(--border-accent);
    width: 100%;
    padding: 5px 0 5px 10px;
    font-size: .9em;
}

#loginwrapper .fancyinput {
    margin: 5px 5px;
}

#loginwrapper label {
    margin: 5px;
}

#loginwrapper .fancyinput span {
    font-size: .9em;
    left: 14px;
    top: 8.5px;
    background: none;
}

#loginwrapper .fancyinput input:not(:placeholder-shown)+span {
    left: 5px;
    top: -4px;
    font-size: .7rem;
}

#forgotPassLink {
    margin-top: 10px;
    text-decoration: underline;
    cursor: pointer;
}

#registerform i,
#recoverform i {
    font-size: .8rem;
    margin-top: 10px;
}

/*                                                                  Body      */
#mainPane {
    position: absolute;
    top: 0;
    bottom: 0;
    width: 100%;
    min-width: 300px;
    z-index: 0;
    display: flex;
    flex-direction: column;
}

#mapview {
    position: relative;
    flex: auto;
    transition: flex .5s;
}

#listview {
	display: flex;
	flex-direction: column;
    position: relative;
    flex-basis: 0;
    max-height: 0;
    transition: flex-basis .5s, max-height .5s, max-width .5s;
}

#listview.open {
    flex-basis: 50%;
    max-height: 50%;
    box-shadow: var(--small-shadow);
}

.listheader {
	width: 100%;
    min-width: 300px;
	height: 30px;
	display: flex;
	flex-direction: row;
	z-index: 90;
}


.sort {
	display: none;
	flex-grow: 1;
}

.sort svg {
	height: 20px;
}

.sort-btn {
    background: none;
	border: none;
    padding: 6px;
    cursor: pointer;
	width: 100%;
}

.sort-menu {
    position: absolute;
    left: 50%;
    transform: translateX(-50%);
    background: white;
    border: 1px solid #ccc;
    display: none;
    min-width: 160px;
}

.sort-menu button {
    display: block;
    width: 100%;
    padding: 8px;
    border: none;
    background: white;
    text-align: left;
    cursor: pointer;
}


.sort-menu.open {
    display: block;
}



#main {
    position: relative;
    display: flex;
    flex-direction: column;
    justify-content: center;
    flex-wrap: nowrap;
    height: 100%;
    width: calc(100% - 60px);
    min-width: 300px;
    z-index: 25;
    padding: 10px 10px 40px;
    pointer-events: none;
    transition: padding .5s;
}

#mapid .leaflet-popup-content {
    margin: 12px;
}

#notAdmin {
    position: absolute;
    display: none;
    background: var(--back-light);
    color: var(--red);
    font-size: 1.2rem;
    text-align: center;
    width: 100%;
    padding: 10px;
    box-shadow: var(--small-shadow)
}
/*                                                                   Search   */

.searchbar {
    position: absolute;
    display: none;
    flex-direction: row;
    align-items: center;
    height: 40px;
    top: 10px;
    transform: translateX(-250px);
    background: white;
    border: 2px solid rgba(0,0,0,0.2);
    border-radius: 4px;
    pointer-events: all;
    transition: left .5s;
}

.searchbar div {
    flex: 1
}

.searchbar button {
    height: 30px;
    width: 30px;
    border: none;
}

.searchbar button svg {
    height: 25px;
    width: 25px;
    stroke: var(--accent);
}

.searchbar .fancyinput {
    width: 0;
    overflow: hidden;
    padding: 0;
    transition: padding .5s, width .5s;
}

.searchbar .fancyinput.open {
    width: 198px;
    padding: 4px;
}

.searchbar input {
    border: none;
    border-bottom: var(--border-accent);
    width: 198px;
    padding: 5px 0 3px 10px;
    font-size: .9em;
}

/*                                                                   Map      */
#mapid {
    position: absolute;
    top: 0;
    bottom: 0;
    width: 100%;
    min-width: 300px;
    z-index: 0;
}

.leaflet-tooltip.light {
    background-color: transparent;
    padding: 0;
    border: none;
    box-shadow: none;
    font: .75rem Helvetica, Arial, sans-serif;
    text-shadow: -1px -1px 0 #fff, 1px -1px 0 #fff, -1px 1px 0 #fff, 1px 1px 0 #fff;
}

.leaflet-tooltip.markerLabel {
    background-color: var(--back-light);
    padding: 1px;
    border: none;
    font: .75rem Helvetica, Arial, sans-serif;
}

.index {
    font-size: .65rem;
    background-color: #ffffffd9;
    display: grid;
}

.index > span:first-of-type {
    border-bottom: var(--border-gray);
}

.index>div {
    display: flex;
    align-items: center;
}

.index svg {
	stroke-width: 12px;
	height: 10px;
	margin-right: 3px;
}

.indexmarker {
    width: 10px;
    height: 10px;
    border: 2px solid;
    border-radius: 50%;
    margin-right: 3px;
}

.leaflet-control.mapbuttons,
.leaflet-control.index {
    padding: 3px;
}

.leaflet-control.mapbuttons {
    cursor: pointer;
}

.mapbuttons {
    width: 34px;
    height: 34px;
    background-size: 24px 24px;
    background-position: center;
    background-repeat: no-repeat;
    background-color: var(--back-light);
	
}

.mapbuttons:hover {
    background-color: var(--back-light-focus);
}

.addicon svg {
    stroke-width: 10px;
    stroke: #f00;
    fill: none;
}

.servicedicon svg {
    stroke-width: 15px;
    fill: #ffffff80
}

.markericon svg {
    stroke-width: 10px
}

.leaflet-control-container > div {
    transition: transform .5s ease-in-out;
}

/*                                                           Tutorial menu    */

#helpmenu {
	font-size: .75rem;
	position: absolute;
	right: 12px;
	top: 12px;
	padding: 3px;
	max-width: 100%;
    min-width: 150px;
	width: fit-content;
    max-height: 350px;
	border-radius: 4px;
	border: 2px solid rgba(0, 0, 0, .2);
	background-color: var(--back-light);

}

#helpmenu .dialogsection span,
#helpmenu .dialogsection a {
	color: var(--txt-dark);
    display: block;
    width: 100%;
}

#helpmenu .dialogsection a {
    height: 24px;
    border-bottom: none;
    text-align: start;
}

#helpmenu .dialogsection a:hover,
#helpmenu .dialogsection a:active,
#helpmenu .dialogsection a:focus {
    background: var(--back-light);
}

#helpmenu span.helpoption,
#helpmenu div.helpoption,
#helpmenu a.helpoption {
    text-decoration: underline;
    cursor: pointer;
    width: 100%;
    padding: 3px 5px;
}

.helptitle {
    font-size: 1.1em;
    border-bottom: var(--border-accent);
    cursor: default;
}

/*                                                                   Media    */

@media only screen and (min-width: 750px) {

    .searchbar .fancyinput {
        width: 198px;
        padding: 4px;
    }

}

@media only screen and (max-width: 500px) {

    #notAdmin {
        bottom: 0;
    }

}

@media only screen and (min-width: 600px) {

    #mainPane {
        flex-direction: row-reverse;
    }

    #listview {
        max-width: 0;
        height: 100%;
        transition: flex-basis .5s, max-height 0s, max-width .5s;
    }

    #listview.open {
        max-width: 300px;
        max-height: 100%;;
        height: 100%;
    }

    #main.leftpadded {
        padding-left: 310px;
    }
}
