@media screen and (max-width: 1420px) {

    #subpages a {
        font-size: 30px;
    }

    #content {
        background-size: contain;
        background-repeat: no-repeat;
        background-position: center;
    }
}

@media screen and (max-width: 1320px) {

    #content h1 {
        font-family: var(--title-font), serif;
        font-size: 9em;
        text-align: center;
        color: #e5b12088;
        margin-bottom: 10px;
        margin-top: 0;
        padding-top: 100px;
    }

    #content h2 {
        font-family: var(--title-font), serif;
        font-size: 6em;
        text-align: center;
        color: #e5b12088;
        margin-top: 0;
    }

}

@media screen and (max-width: 1100px) {

    #content h1 {
        padding-top: 50px;
    }

    #content {
        width: 100%;
        height: calc(100vh - 70px);
        top: 70px;
    }

    #subpages {
        top: auto;
        padding: 0;
        width: 100%;
        font-size: larger;
        font-family: var(--normal-font), serif;
        height: auto;
    }

    #subpages a {
        position: relative;
        top: 0;
        transition: top ease 0.5s;
        width: calc(20% - 20px);
        padding: 10px;
        display: flex;
        margin: 0;
        text-align: center;
        cursor: pointer;
        text-decoration: none;
        height: 80px;
    }

    #subpages a:hover {
        top: -10px;
    }

    #subpages-conainer {
        width: 100%;
        display: flex;
    }
}

@media screen and (max-width: 960px), (pointer: coarse) and (orientation: portrait) {

    #indexa {
        flex-direction: column;
    }

    #tools, #put {
        width: 100%;
    }

    .group {
        flex-direction: column;
    }

    .group #kalender {
        width: calc(100% - 10px);
    }

    .group #kalenderdisplay {
        width: calc(100% - 10px);
    }

    #group2 {
        margin-top: 50px;
        display: flex;
        flex-direction: column-reverse;
    }

    #entschuldigen form {
        margin-top: 10px;
        margin-bottom: 30px;
    }

    #entschuldigen select, #entschuldigen input {
        height: 60px;
        font-size: 25px;
        width: 30%;
    }

    #aufgaben {
        align-items: center;
    }

    #aufgabena {
        margin-bottom: 40px;
        background-color: var(--hellgelb);
    }


}

@media screen and (max-width: 850px) {
    #content {
        background-position: top !important;
    }

    #datacontainer {
        flex-direction: column;
    }

    #entwicklerkontakt {
        position: relative;
    }
}

@media screen and (max-width: 820px) {
    #nutzerverwaltung, #websitebearbeiten {
        display: none !important;
    }

    #posts {
        width: 100% !important;
    }
}

@media screen and (max-width: 770px) {
    nav {
        background-color: var(--gelb);
        padding: 10px 0;
        display: flex;
        width: 100%;
        height: 50px;
    }

    nav p {
        font-family: var(--normal-font), serif;
        font-size: 20px;
        margin: 0;
        padding: 8px 0;
        width: 100%;
        text-align: center;
    }


    nav button {
        height: 40px;
        margin: 0 10px;
        padding: 0 10px;
        border-radius: 15px;
        background-color: var(--hellgelb);
        transition: 0.2s background-color ease-in-out;
        cursor: pointer;
        font-size: 20px;
        font-family: var(--normal-font), serif;
    }

    nav button:hover {
        background-color: var(--hellblau);
    }

    #content {
        background-size: contain;
        background-repeat: no-repeat;
        background-position: center;
    }

    #subpages a {
        font-size: 20px;
    }
}

@media screen and (max-width: 700px) {

    #startnews {
        height: 100px;
    }

    #diesv {
        padding-top: 0 !important;
        padding-bottom: 40vw;
    }

}

@media screen and (max-width: 650px) or (pointer: coarse), (orientation: portrait) {
    #adminindex {
        flex-direction: column;
    }

    #protokoll {
        width: 100%;
    }

    #admintoolsa {
        width: 100%;
    }

    body {
        height: auto !important;
    }

    #aufgabenverwaltung {
        height: 30vh;
    }

    #aufgabenverwaltung form {
        height: calc(100% - 90px);
        width: calc(100% - 40px);
        margin: 20px;
    }

    #aufgabenverwaltung input, #aufgabenverwaltung select {
        height: 40px;
        font-size: 25px;
        width: 60%;
        margin-bottom: 10px;
    }

    #aufgabenverwaltung input[type="date"] {
        height: 40px;
        width: 40%;
    }

    #wocheneltern {
        height: 20vh;
    }

    #wocheneltern button, #admintools button {
        height: 8vh;
        font-size: 25px;
    }

    #admintools {
        height: 30vh;
    }

    #popoprotokoll {
        height: 50vh;
    }

}

@media screen and (max-width: 580px) {
    #largekalender {
        display: none !important;
    }

    #smallkalender {
        display: block;
    }
}

@media screen and (max-width: 570px) {

    #content h1 {
        font-family: var(--title-font), serif;
        font-size: 6em;
        text-align: center;
        color: #e5b12088;
        margin-bottom: 10px;
        margin-top: 0;
    }

    #content h2 {
        font-family: var(--title-font), serif;
        font-size: 4em;
        text-align: center;
        color: #e5b12088;
        margin-top: 0;
    }

}

@media screen and (max-width: 500px) {

    .flipbox {
        width: calc(100% - 80px) !important;
        padding: 40px !important;
    }

    .row {
        flex-direction: column !important;
        height: 400vw !important;
    }

    #kalender {
        width: 100%;
    }

}

@media screen and (max-width: 400px) {

    #largetitel {
        display: none !important;
    }

    #smalltitel {
        display: inline !important;
    }

    #diesv p {
        display: none !important;
    }

    #content h1 {
        font-size: 4em;
        padding-top: 100px;
    }

    #content h2 {
        font-size: 3em;
        margin-top: 0;
    }

}

@media (pointer: coarse) and (orientation: portrait) {

    nav {
        /*height: 140px;*/
        justify-content: space-between;
    }

    nav button {
        /*height: 100px;*/
    }

    nav p {
        width: 60%;
    }


    #content {
        height: calc(100vh - 471px);
        /*top: 160px;*/
        background-position: top;
    }

    #content h1 {
        padding-top: 0;
        margin-top: 40px;
    }

    #startnews {
        width: 100%;
        background-color: #952d4472;
        height: 10vh;
        margin: 0;
        align-content: center;
        z-index: 1;
        bottom: 0;
        top: auto;
    }

    #startnews button {
        --blur-radius: 3px;
        padding: 8px 50px;
        transition: 0.2s padding ease-in-out;
        background: none;
        border: none;
        cursor: pointer;
        font-family: var(--normal-font), serif;
        /*font-size: 50px;*/
        font-size: 1.5em;
        color: var(--rot);
        text-shadow: #000 2px 2px var(--blur-radius), #000 -2px -2px var(--blur-radius), #000 2px -2px var(--blur-radius), #000 -2px 2px var(--blur-radius);
    }

    .dropdown {
        width: calc(20% - 43px);
    }

    .dropdown button {
        width: 100%;
    }


    .dropdown-content {
        min-width: 200px;
    }

    #startnews button:hover {
        padding-left: 35px;
    }

    #subpages {
        width: 100%;
        bottom: 0;
    }

    #subpages a {
        padding: 0;
        width: 100%;
        line-height: 70px;
        display: block;
        margin-top: 10px;
        text-align: center;
        cursor: pointer;
        color: black;
        text-decoration: none;
        height: auto;
    }

    #subpages a:visited {
        color: black;
        text-decoration: none;
    }

    #subpages-conainer {
        height: 100%;
        align-items: center;
        flex-direction: column;
    }

    #diesv {
        height: 80vw;
    }

    .flipbox {
        width: calc(100% - 80px) !important;
        padding: 40px !important;
    }

    .row {
        flex-direction: column !important;
        height: 400vw !important;
    }

    .login input {
        height: auto;
    }

    #text {
        padding: 20px;
        font-size: 40px;
    }

    #datacontainer {
        flex-direction: column;
    }

}

@media (pointer: coarse) and (orientation: landscape) {

    #startnews {
        width: calc(100% - 40px);
        bottom: 0 !important;
    }

    #content {
        width: calc(85% - 20px);
    }

    #content h1 {
        font-size: 6em;
    }

    #content h2 {
        font-size: 4em;
    }

    #subpages {
        background-color: var(--hellgelb);
        position: absolute;
        width: 15%;
        right: 0;
        top: 71px;
        bottom: 0 !important;
        padding-right: 20px;
        font-size: 20px;
        font-family: var(--normal-font), serif;
        height: calc(100vh - 71px);
        align-items: center;
        display: block;
        justify-items: right;
    }

    #subpages-conainer {
        display: block;
    }

    #subpages a {
        padding-bottom: 10px !important;
        width: 100%;
        display: block;
        margin-top: 10px;
        text-align: right;
        text-decoration: none;
    }

    #subpages a:visited {
        color: black;
        text-decoration: none;
    }

    #entwicklerkontakt {
        position: relative;
    }

}










@media screen and (max-height: 400px) {
    #content h1, #content h2 {
        padding-top: 5vh !important;
    }
}

@media screen and (pointer: fine) and (max-height: 540px) {
    #content h1, #content h2 {
        font-size: 100px;
        padding-top: 20vh !important;
    }

    #content h2 {
        width: calc(55% - 20px) !important;
        padding: 10px;
        text-align: left;
    }

    #content h1 {
        width: calc(45% - 20px) !important;
        padding: 10px;
        text-align: right;
    }

    #content {
        display: flex;
    }

    #subpages {
        top: auto;
        bottom: 5vh;
    }

    #subpages a {
        padding-bottom: 30px !important;
    }

}

@media screen and (max-height: 560px) {
    #subpages {
        align-items: normal;
    }

}

@media screen and (max-height: 620px) {

    #content h1 {
        margin-top: 0;
        padding-top: 20px !important;
    }
}

@media screen and (max-height: 630px) {
    #subpages a {
        font-size: 20px;
        padding-top: 0;
        height: 10vh;
    }
}

@media screen and (max-height: 725px) {

    #startnews {
        bottom: 80px;
        top: auto;
    }

    #content h1 {
        font-family: var(--title-font), serif;
        text-align: center;
        color: #e5b12088;
        margin-bottom: 10px;
        margin-top: 0;
        padding-top: 100px;
    }

    #content h2 {
        font-family: var(--title-font), serif;
        text-align: center;
        color: #e5b12088;
        margin-top: 0;
    }

}