:root {
    --main: #0288d1;
    --secondary: #12a0ed;
    --secondary-hover: #56b5e8;
    --dark: #0d76af;
    --standard-green: #18bb5c;
}

* {
    font-family: Roboto, Arial;
}

body {
    -ms-overflow-style: none;
    scrollbar-width: none;
    overflow-x: hidden;
}

body::-webkit-scrollbar {
    display: none;
}

body:has(> .editingInputContainer.show) {
    height: 100vh;
    overflow: hidden;
    max-height: 100vh;
}

h1 {
    letter-spacing: -.6px;
}

input#timeSelect,
input#endTimeSelect {
    position: relative;
    text-align: center;
    font-size: 30px;
    padding: 15px 30px;
    margin-left: 15px;
    margin-right: 15px;

    outline: none;
}

input#timeSelect:focus,
input#endTimeSelect:focus {
    box-shadow: 1px 3px 5px black;
}

input#datumSelect {
    outline: none;
    width: 160px;
    height: 50px;
    font-size: 20px;

}

input#datumSelect:focus {
    box-shadow: 1px 3px 5px black;
}

#horsePickDisplay {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(20%, max-content));
    width: 70%;
    max-width: 430px;

    justify-content: center;
    margin: auto;

    margin-bottom: 10px;
    gap: 5px;

}

#horsePickDisplay>p {
    margin: 0;
    margin-bottom: 10px;
    font-size: 16px;
    line-height: 19px;
}

.horseElement {
    padding: 5px 10px;
    font-size: 20px;
    border-radius: 5px;

    transition: border .15s, box-shadow .15s;
    cursor: pointer;

    overflow: hidden;
    height: fit-content;

    text-overflow: ellipsis;
    white-space: nowrap;
    overflow: hidden;
    max-width: 100%;
}

.horseElement:not(.selected) {

    border: 1px solid black;
    box-shadow: none;
}

.horseElement.selected {
    border: 1px solid var(--secondary);
    box-shadow: .7px 1.5px 3px var(--secondary);
    background-color: var(--secondary);
    color: white;
}

.header {
    position: relative;
    height: clamp(50px, 5.5vw, 90px);
    background-color: var(--main);
    top: 0;
}

.header>h1 {
    font-weight: 500;
    font-size: clamp(.7rem, 5vw, 2.5rem);
    margin: 0;


    position: relative;
    top: 50%;
    left: clamp(40px, 6vw, 60px);
    color: white;
    transform: translateY(-50%);
    inline-size: 70%;
    white-space: nowrap;
}

.userContainer {
    position: relative;
    width: 100%;
    height: 100px;
    left: 0;
    grid-area: 'user';
    grid-column-start: 1;
    grid-column-end: 3;
}

.userHeadline {
    margin-left: clamp(5px, 2vw, 45px);
    font-size: clamp(.2rem, 5vw, 2rem);
    max-width: 60vw;

    position: relative;
    top: 50px;
    transform: translateY(-100%);
    color: rgba(0, 0, 0, .8);
    /*color: var(--dark);*/
}

p#err {
    position: absolute;
    top: 50%;
    left: 50vw;
    transform: translate(-50%, 0%);

    background-color: white;
    color: red;
    padding: 15px 25px;
    border: 1px solid red;
    box-shadow: .7px 1.5px 3px red;
    z-index: 10;

    opacity: 0;
    transition-delay: 1s;
    transition: opacity .6s;

    text-align: center;
    font-size: 22px;
    line-height: 26px;
}

.button {
    color: var(--secondary);
    padding: 16px 16px;
    padding-top: 32px;
    text-align: center;
    text-decoration: none;
    font-size: clamp(.8rem, 1.8vw, 16px);

    transition: color 0.25s, background-color .25s, box-shadow .15s;
    cursor: pointer;

    margin-top: 50px;
    margin-bottom: 20px;
    box-shadow: 0 5px 7.5px rgba(19, 161, 238, .8);
    background-color: white;
    border: none;
    border-radius: 2px;

    width: min(300px, 30vw);
    max-width: 300px;

    position: relative;
    display: flex;

    justify-content: center;
    align-items: center;

    overflow: hidden;
    font-family: Roboto, Arial;
    text-transform: uppercase;
    text-decoration: none;

    white-space: pre-wrap;
    height: 100px;
}

.button:hover {
    background-color: var(--secondary);
    color: white;
}

.button:active {
    box-shadow: 0 0 0 0;
}

.button#addTermin {
    position: absolute;
    margin: 0;
    right: 20px;
    top: 50px;
    transform: translateY(-50%);
    height: 50px;
}

.button#addTermin>ion-icon {
    position: absolute;
    top: 0;
    left: clamp(5px, 3%, 10px);
    width: 10%;
    height: 100%;
}

.button#addHorse,
.button#addHorseDrop {
    position: relative;
    width: 50px;
    height: 50px;

    margin: auto;
    margin-top: -40px;
    top: 60px;
    border-radius: 25px;
    box-shadow: 2px 5px 7.5px rgba(19, 161, 238, .9);
    padding: 0;
    font-size: 30px;

    pointer-events: all;
}

.button#addHorse:active,
.button#addHorseDrop:active {
    box-shadow: 0 0 0;
}

#cover {
    position: absolute;
    width: 100%;
    height: 80px;

    bottom: 0;
    transform: translateY(100%);
    background-color: white;
}

.button#signOut,
.button#signIn {
    position: absolute;
    box-shadow: 1px 3px 5px rgba(0, 0, 0, .9);
    background-color: rgb(222, 16, 16);
    color: white;

    top: 5px;
    right: 10px;

    margin: 0;
    padding: 0;

    width: 25%;
    height: clamp(38px, 4.4vw, 75px);
    max-height: 75px;
    max-width: 250px;
}

.button#signOut:hover {
    background-color: rgb(154, 20, 20);
}

.button#signIn {
    background-color: rgb(21, 178, 21);
}

.button#signIn:hover {
    background-color: rgb(16, 125, 16);
}

.editingInput>.button {
    height: 60px;
    min-width: 200px;
    padding: 0;
    margin: 20px auto 40px auto;

    color: var(--main);
}

.editingInput>.button:hover {
    background-color: var(--main);
    color: white;
}

.editingInput p#horseSelectText {
    width: 80%;
    margin: auto;
}

.horseContainer {
    width: calc(100% - 13px);
    height: fit-content;
    min-width: 200px;
    grid-area: 'pferd';
    border: 2px solid var(--secondary);
    box-shadow: 3px 3px 10px rgba(19, 161, 238, .8);
    background-color: white;
    overflow: hidden;
    transition: height .3s;
}

.horseContainer>.dropActivator {
    width: 100%;
    height: 80px;
    background-color: white;
    transition: background-color .4s;
}

/*.horseContainer>ul::before {
    position: relative;
    width: 100%;
    content: 'Ihre Pferde:';
    font-size: clamp(1.5rem,2vw,2.2rem);
    left: -60px;
    padding: 5px;
}*/

.horseContainer>ul {
    width: 100%;
    list-style: none;
    top: 0;
    margin: 0;
    left: -40px;
    text-indent: 60px;
}

.horseContainer>ul>li {
    position: relative;
    width: 100%;
    height: 60px;
    /*padding: 20px 0 30px 0;*/

    background-image: url("./res/ferd.png");
    background-size: 40px 40px;
    background-repeat: no-repeat;
    background-position: 5px 10px;

    line-height: 60px;
    font-size: 1.3rem;
    color: rgba(0, 0, 0, .75);
    transition: background-color .2s;
    line-break: anywhere;
    overflow: hidden;

    border-bottom: 2px solid black;
}

.horseContainer>ul>li>ion-icon {
    position: absolute;
    width: 25px;
    height: 25px;

    border-radius: 12px;
    padding: 3px;

    right: 10px;
    top: 30px;
    transform: translateY(-50%);
    transition: background-color .12s;
    color: rgb(232, 29, 29);

}

.horseName {
    display: block;
    width: calc(100% - 40px);
    text-overflow: ellipsis;
    overflow: hidden;
    white-space: nowrap;
}

.horseContainer>ul>li>ion-icon:hover {
    color: rgb(152, 18, 18);
    cursor: pointer;
}

.dropActivator>ion-icon {
    display: none;
}

.horseContainer>ul {
    position: relative;
    top: -80px;
}

.dhx_cal_container {
    width: 100px;
    grid-area: 'kalender';
}

.dhx_cal_container {
    position: relative;
    width: 100%;
    height: calc(100vh - clamp(50px, 5.5vw, 90px) - 100px) !important;
    grid-column-start: 2;
    grid-column-end: 3; 
    overflow-y: scroll;
    overflow-x: hidden;
}

.dhx_cal_navline {
    position: sticky;
}

/*.dhx_cal_data {
    pointer-events: none;
}*/

.dhx_cal_event {
    pointer-events: all;
    font-size: max(12px, .7vw);
    overflow: hidden;
    cursor: pointer;
}

.dhx_title,
.dhx_body {
    transition: background-color .2s, opacity .2s;
}

.dhx_cal_event:hover>.dhx_title,
.dhx_cal_event:hover>.dhx_body {
    /*background-color: var(--secondary) !important;*/
    opacity: .75 !important;
}

.dhx_event_resize {
    display: none !important;
}

.dhx_cal_container+.dataCoverElement {
    background-color: green;
    width: 100%;
    height: 100%;
    z-index: 1;
}

.screen#mainContent {
    position: relative;
    width: 100%;
    display: grid;
    grid-template-columns: 15vw auto;
    gap: 5px;
    padding: 5px;
    column-count: 2;
}

.dhx_cal_date {
    left: 5vw !important;
}

.editingInputContainer {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;

    background-color: rgba(0, 0, 0, 0);
    z-index: 5;

    transition: background-color .3s;
    overflow-y: scroll;
    backdrop-filter: blur(3px);
    -webkit-backdrop-filter: blur(3px);



}
@supports (-moz-appearance: none) {
    .editingInputContainer {
        backdrop-filter: blur(0px);
    }
}

.editingInputContainer.show {
    background-color: rgba(0, 0, 0, .8);
}

.editingInput {
    position: absolute;
    z-index: 10;
    width: 50%;
    height: max(fit-content, max(450px, 50%));

    min-width: 450px;
    min-height: max(max-content, 500px);

    top: 10%;
    left: 50%;

    background-color: white;
    box-shadow: 2px 2px 1px 1px rgba(0, 0, 0, 11);
    border-radius: 2px;
    transition: transform .4s ease-out;

    text-align: center;
    display: flex;

    flex-direction: column;
}

.editingInput h1 {
    position: relative;
    margin-top: 25px;
    margin-left: 25px;
    margin-bottom: 10px;

    font-size: 45px;
    inline-size: 85%;
    text-align: left;

    font-family: Roboto, Arial;

}

.editingInput h2 {
    position: relative;
    margin-top: 5px;
    margin-bottom: 0px;
    margin-left: 10%;

    font-weight: 500;
    font-family: Roboto, Arial;
    inline-size: 80%;
    text-align: left;

}

.editingInput select {
    position: relative;
    width: max(80%, min(420px, 70%));
    max-width: 750px;
    height: clamp(55px, 4vw, 65px);

    margin-bottom: 10px;
    text-align: center;
    font-size: clamp(25px, 3vw, 30px);

    border-radius: 0px;
    border: none;
    background-color: rgba(0, 0, 0, .03);
    border-bottom: 3px solid rgba(0, 0, 0, .8);

    /*color: var(--dark);*/
    color: rgba(0, 0, 0, .8);
}

select#hallenSelect {
    margin-bottom: 0;
}

select#pferdeSelect {
    margin-top: 40px;
}

.editingInput {
    /*color: var(--dark);*/
    color: rgba(0, 0, 0, .8);
}

.editingInput>.innerEditContainer>p {
    color: rgba(0, 0, 0, .8);
    width: 60%;
    margin: auto;
    margin-top: 15px;
}

.editingInput>img {
    max-width: 800px;
    margin: 0 auto 0 auto;
}

.editingInput#eventInput {
    padding-bottom: 20px;
}

.editingInput#eventInput p {
    min-width: fit-content;
    text-align: center;
    font-size: 25px;
    max-width: 250px;
    padding: 10px;
    margin: 0;
}

.editingInput input#extraInfoInput {
    width: max(73%, min(420px, 70%));
    padding: 10px;
    font-size: clamp(20px, 3vw, 25px);
    margin-top: 15px;
}

.editingInput#addNewHorseInput p,
.editingInput#addHorseInput p {
    margin-bottom: 30px;
}

.editingInput .terminDisplayMiddle {
    background-color: lightgray;
    color: black;
    padding: 8px 3px 8px 3px !important;
    font-size: 28px !important;
}

.editingInput .terminDisplayLabel {
    text-align: right !important;
    background-color: lightgray;
}

.editingInput .terminDisplayText {
    display: table-cell;
    text-align: left !important;
    background-color: lightgray;
}

.editingInput .terminDisplayMiddle:nth-child(2n-1),
.editingInput .terminDisplayLabel:nth-child(2n),
.editingInput .terminDisplayText:nth-child(2n) {
    background-color: #999;
}

.deleteBtnContainer {
    display: flex;
    width: 420px;
    margin: auto;
}

.button#deleteTermin,
.button#deleteSingleTermin {
    box-shadow: 1px 3px 5px rgba(0, 0, 0, .9);
    background-color: rgb(222, 16, 16);
    color: white;

    margin: 30px auto 30px auto;
    ;
    padding: 5px;

    width: 40%;
    height: clamp(50px, 4.4vw, 75px);
    max-height: 75px;
    max-width: 250px;
}

.button#deleteTermin:hover,
.button#deleteSingleTermin:hover {
    background-color: white;
    color: red;
    border: 1px solid red;
}

.button#deleteTermin:active,
.button#deleteSingleTermin:active {
    box-shadow: none;
}

.deleteButtonDisp {
    display: flex;
    width: 70%;
    margin: auto;
    justify-content: space-evenly;
}

.button#deleteTerminCancel,
.button#deleteTerminFinal,
.button#deleteHorseCancel,
.button#deleteHorseFinal {
    width: 10vw;
    height: 10vw;
    max-width: 130px;
    max-height: 130px;
    min-width: 80px;
    min-height: 80px;

    margin-bottom: 60px;
    text-align: center;

    border-radius: 50%;
    color: white;
}

.button#deleteTerminCancel ion-icon,
.button#deleteTerminFinal ion-icon,
.button#deleteHorseCancel ion-icon,
.button#deleteHorseFinal ion-icon {
    width: 100%;
    height: 100%;
    position: absolute;
    top: 0;
    left: 0;

    transition: background-color .3s, box-shadow .2s, border .3s;
}

.button#deleteTerminCancel,
.button#deleteHorseCancel {
    background-color: red;
    box-shadow: 0 5px 7.5px rgba(222, 59, 59, 0.647);
}

.button#deleteTerminCancel:hover,
.button#deleteHorseCancel:hover {
    background-color: white;
    border: 1px solid red;
    color: red;
}

.button#deleteTerminCancel:active,
.button#deleteHorseCancel:active {
    box-shadow: none;
}

.button#deleteTerminFinal,
.button#deleteHorseFinal {
    background-color: rgb(22, 196, 25);
    box-shadow: 0 5px 7.5px rgba(64, 245, 67, 0.603);
}

.button#deleteTerminFinal:hover,
.button#deleteHorseFinal:hover {
    background-color: white;
    border: 1px solid rgb(22, 196, 25);
    color: rgb(22, 196, 25);
}

.button#deleteTerminFinal:active,
.button#deleteHorseFinal:active {
    box-shadow: none;
}



.propertyDisplay {
    display: grid;
    position: relative;
    width: max-content;
    max-width: 472px;

    grid-template-columns: auto min-content auto;
    justify-content: space-evenly;

    margin: 0 auto 30px auto;

    box-shadow: 5px 5px 7.5px #484141;
    border: 1px solid #6c6363;
    border-radius: 10px;

    overflow: hidden;
    background-color: gray;
}

.propertyDisplay ion-icon {
    position: absolute;
    top: 5px;
    right: 5px;
    width: 30px;
    height: 30px;
    color: #eee;

    cursor: pointer;
    transition: scale .2s, opacity .2s;
}

.propertyDisplay ion-icon:hover {
    scale: 1.15;
}

.innerEditContainer>#newHorseNameInput {
    width: 60%;
    height: 40px;
    outline: none;
    font-size: 25px;
    text-indent: 10px;
    margin-top: 40px;
}

.closeEdit {
    position: absolute;
    right: 0;
    top: 0;

    width: 60px;
    height: 60px;

    opacity: .7;
    color: gray;

    transition: color .2s ease-out, opacity .2s;
}

.closeEdit:hover {
    opacity: 1;
    color: var(--main);
    cursor: pointer;
}

.editingInputContainer:not(.show)>.editingInput {
    transform: translate(-50%, -150%) scale(0);
}


.editingInputContainer.show>.editingInput {
    transform: translate(-50%, -00%) scale(1);
    transition: transform .4s ease-out;
}

.screen#userContent {
    width: 100%;
    height: 100%;
    position: relative;
}

.screen#userContent img {
    width: 30vw;
    margin: 40px;
}

.screen#userContent h1 {
    margin: 0 auto auto 40px;
}

.button#deleteUser {
    position: absolute;
    top: 2vw;
    right: calc(35vw - 40px);
    transform: translateX(50%);
    padding: 0;
    background-color: red;
    color: white;
    box-shadow: 3px 5px 7.5px red;
}

.button#deleteUser:hover {
    color: red;
    background-color: white;
    border: 1px solid red;
}

.button#deleteUser:active {
    box-shadow: none;
}

.loadscreen#userContent {
    position: absolute;
    right: 0;
    top: 0;
    transform: translate(-50%);
    width: 50px;
    height: 110px;
    border-radius: 50px;
}

.loadscreen#userContent:hover {
    cursor: pointer;
    color: var(--main);
}

.calendarUI {
    display: grid;
    position: relative;
    width: 90vw;

    grid-template-columns: repeat(7, calc(90vw / 7));
    margin: auto;
    margin-top: 20px;

}

.calendarUI h2 {
    position: relative;
    font-size: clamp(14px, 3.7vw, 45px);
    top: 30vw;

    text-align: center;
    margin-bottom: 5px;
    margin-top: 0;
}

.calendarUI p {
    position: relative;
    top: 30vw;
    height: 7vw;

    font-size: clamp(14px, 4vw, 45px);
    font-family: "Times New Roman", Times, serif;

    transition: background-color .1s, font-size .12s;
    background-color: #ededed;
    border: 2px solid rgb(103, 103, 103);
    cursor: pointer;

    margin: 0;
    text-align: center;

    padding: 1.8vw;
    padding-top: 4vw;
}

.calendarUI img {
    position: absolute;
    z-index: 0;
    width: 120vw;
    left: -11vw;
}

.calendarUI p:hover {
    background-color: white;
}

.button#backToCalendar {
    border-radius: 0;
    border-color: var(--main) !important;
    box-shadow: none;
    border: 1px solid var(--main);

    width: min-content;
    height: min-content;
    padding: 8px 5px 5.5px 5px;
    margin: 0;
    display: block;

    color: var(--main);
    white-space: nowrap;
    text-decoration: none;
    font-weight: 500;
    border: 1px solid #0288d1;
    font-size: inherit;
    display: none;


    position: absolute;
    top: 14px;
    left: min(calc(20vw + 16px + 60px), calc(50px + 16px + 60px)) !important;
    z-index: 3;

}

#backToCalendar:hover {
    background-color: #edf8ff;
}

#backToCalendar:focus-within {
    background-color: var(--main);
    color: white;
}

.dhx_cal_tab.month {
    /*width: min-content;
    left: min(calc(20vw + 16px + 60px),calc(50px + 16px + 60px)) !important;
    border-left-style: none;
    padding-left: 5px;
    padding-right: 5px;
    
    min-width: min-content;
    max-width: max-content;*/

    display: none;
}

.dhx_cal_tab.week {
    width: 20vw;
    left: min(calc(20vw + 16px), calc(50px + 16px)) !important;
    min-width: min-content;
    max-width: max-content;

    padding-left: 5px;
    padding-right: 5px;
}

.dhx_cal_tab.day {
    width: min(20vw, 50px);
    min-width: min-content;
}

.dhx_cal_today_button {
    width: min-content;
    right: clamp(38px, 4vw, 80px);
}

.dhx_cal_prev_button {
    right: clamp(85px, 8vw, 130px);
}

.dhx_cal_next_button {
    right: 2vw;
}

.hallenContainer {
    display: none;
}

@media screen and (max-width:1330px) {
    .screen#mainContent {
        grid-template-columns: 200px auto;
    }
}

@media screen and (max-width:1000px) {
    .editingInput h1 {
        text-align: center;
    }
}

@media screen and (max-width:820px) {
    .dhx_cal_date {
        top: -10px !important;
    }
}

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

    .button#backToCalendar {
        display: block;
    }

    .dhx_cal_date {
        top: 14px !important;
    }

    .screen#mainContent {
        grid-template-columns: auto;
    }

    .horseContainer {
        grid-column-start: 1;
        grid-column-end: 3;

        margin-bottom: 15px;
        display: none;
    }

    .hallenContainer {
        grid-column-start: 1;
        grid-column-end: 3;

        height: 80px;
        display: block;
    }

    .hallenContainer>.slider {
        background-color: rgb(255, 255, 255);
        width: 70vw;
        height: 50px;
        margin: auto;
        margin-top: 10px;

        display: grid;
        grid-template-columns: repeat(3, auto);
        gap: 5px;
        padding: 5px;

        border-radius: 50px;
    }

    .slider>.halle {
        background-color: var(--secondary);
        text-align: center;
        white-space: nowrap;
        vertical-align: middle;
        opacity: 1;

        transition: opacity .25s;
        cursor: pointer;
        color: white;

        box-shadow: none;
    }

    .slider>.halle:not(.selected):hover {
        opacity: .9;
    }

    .slider>.halle.selected:hover {
        cursor: auto;
    }

    .slider>.halle:not(.selected) {
        opacity: .6;
    }

    .slider>.halle:nth-child(1) {
        border-radius: 40px 0 0 40px;
        background-color: #0288d1;
    }

    .slider>.halle:nth-child(2) {
        background-color: #18bb5c;
    }

    .slider>.halle:nth-last-child(1) {
        border-radius: 0 40px 40px 0;
        background-color: #f49b26;
    }

    .slider p {
        pointer-events: none;
    }

    li:nth-child(1) {
        border-top: 2px solid black;
    }

    .dhx_cal_container {
        grid-column-start: 1;
        grid-column-end: 3;
    }

    .scrollContainer {
        grid-column-start: 1;
        grid-column-end: 3;
        height: calc(100vh - clamp(50px, 5.5vw, 90px) - 100px - 150px);
        background-color: white;

    }

    .dropActivator>ion-icon {
        display: block;
        width: 100%;
        height: 100%;
        color: black;
        transition: transform .4s;
        cursor: pointer;
    }

    .horseContainer.open>.dropActivator>ion-icon {
        transform: rotate(-180deg);
    }

    .horseContainer:not(.open) {
        height: 80px;
        z-index: 1;
    }

    .horseContainer.open {
        transition: max-height .5s;
        height: fit-content;
    }

    .horseContainer>.dropActivator:hover {
        background-color: rgba(21, 173, 223, 0.35);
    }

    .horseContainer>ul {
        top: 0;
        text-indent: 90px;
    }

    .horseContainer>ul>li {
        width: 100%;
        height: 80px;
        /*padding: 20px 0 30px 0;*/
        background-size: 60px 60px;
        background-repeat: no-repeat;
        background-position: 5px 10px;

        line-height: 80px;
        font-size: 24px;
    }

    .horseContainer>ul>li>ion-icon {
        top: 40px;
        width: 40px;
        height: 40px;
    }

    .button#addHorse {
        margin-top: 20px;
        margin-bottom: 20px;
        top: 0;

        width: 80px;
        height: 80px;
        border-radius: 40px;
        font-size: 50px;
    }
}

@media screen and (max-width:650px) {
    .dhx_cal_date {
        top: -10px !important;
    }
}