@font-face {
    font-family: 'pirates';
    src: url('fonts/pirates.ttf');
}

* {
    box-sizing: border-box;
}

::-webkit-scrollbar {
    width: 12px;
    height: 12px;
}

::-webkit-scrollbar-thumb {
    background-color: rgb(74, 129, 202);
    border-radius: 6px;
}

::-webkit-scrollbar-track {
    background-color: #f1f1f1;
    border-radius: 6px;
}

::-webkit-scrollbar-thumb:hover {
    background-color: rgb(50, 100, 180);
}


html {
    scrollbar-color: rgb(74, 129, 202) #f1f1f1;
    scrollbar-width: thin;
}

body {
    font-family: 'pirates', Arial, Helvetica, sans-serif;
    display: flex;
    flex-direction: column;
    align-items: center;
    margin: 0;
    justify-content: center;
    height: 100vh;
    color: white;
    font-size: 20px;
    background-color: black;
    background-image: url(img/background.jpg);
    background-size: cover;
    background-position: center;
    background-size: cover;
}

.game-title {
    font-size: 64px;
    margin: 0;
    letter-spacing: 2px;
    text-shadow: 5px 8px 4px rgba(0, 0, 0, 0.9);
    text-align: center;
}

canvas {
    background-color: black;
    display: block;
}

.fullscreen {
    width: 100vw;
    height: 100vh;
}

.canvas-overlay {
    position: relative;
}

.sound-icon {
    width: 45px;
    height: 45px;
    position: absolute;
    top: 6px;
    right: 80px;
    cursor: pointer;
}

.fullscreen-icon {
    width: 50px;
    height: 50px;
    position: absolute;
    top: 5px;
    right: 5px;
    cursor: pointer;
}

.move-container {
    position: absolute;
    bottom: 8px;
    padding: 0 0 0 30px;
    width: 210px;
    height: 70px;
    display: none;
    justify-content: space-between;
    align-items: center;
}

.move-btn {
    display: flex;
    justify-content: center;
    align-items: center;
    width: 65px;
    height: 65px;
    background-color: unset;
    border-radius: 50%;
    cursor: pointer;
}

.move-btn:active {
    scale: 1.1;
    filter: sepia();
}

.move-btn-icon {
    width: 65px;
    height: 65px;
}

.attack-btn {
    display: flex;
    justify-content: center;
    align-items: center;
    width: 60px;
    height: 60px;
    background-color: rgba(255, 0, 0, 0.1);
    border: solid 2px rgba(255, 0, 0, 0.5);
    border-radius: 50%;
    cursor: pointer;
}

.attack-btn:active {
    scale: 1.1;
    filter: sepia();
}

.attack-btn-icon {
    width: 60px;
    height: 60px;
}

.action-container {
    position: absolute;
    bottom: 8px;
    right: 0;
    width: 300px;
    padding: 0 30px 0 0;
    height: 70px;
    display: none;
    justify-content: space-between;
    align-items: center;
}

.startscreen {
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    position: absolute;
    width: 850px;
    height: 650px;
    background-image: url(img/9_intro_outro_screens/start/ship-background.gif);
    background-position: center;
    background-size: cover;
    overflow: hidden;
    border-radius: 10px;
}

.startscreen-title {
    color: rgba(16, 152, 247, 0.8);
    font-size: 50px;
    font-weight: 700;
    margin: 0 0 150px 0;
    animation: shimmer 2s infinite alternate, pulse 2s infinite ease-in-out;
}

.start-game-btn {
    color: black;
    width: 250px;
    height: 80px;
    font-size: 25px;
    border-radius: 20px;
    display: flex;
    justify-content: center;
    align-items: center;
    transition: all ease-in-out 100ms;
    cursor: pointer;
    background-color: rgba(16, 152, 247, 0.8);
    animation: glowingShadow 3s infinite alternate, pulse 2s infinite ease-in-out;
}

.start-game-btn:hover {
    scale: 1.2;
}

.character-images-container {
    position: absolute;
    scale: 1.5;
    bottom: 30px;
    left: 110px;
    width: 130px;
    height: 100px;
    display: flex;
    justify-content: center;
    padding-right: 50px;
    align-items: center;
    transition: all ease-in-out 100ms;
}

.change-character-position {
    z-index: 1;
    bottom: 250px;
    left: 360px;
    scale: 2.0;
}

.controls-info-btn {
    position: absolute;
    display: flex;
    align-items: center;
    gap: 15px;
    bottom: 50px;
    text-shadow: 0 0 10px #fff;
    cursor: pointer;
    transition: all ease-in-out 100ms;
    animation: pulse 2s infinite ease-in-out;
}

.controls-info-btn:hover {
    scale: 1.2;
}

.controls-info-container {
    color: black;
    position: absolute;
    flex-direction: column;
    width: 700px;
    height: 350px;
    background-color: rgba(74, 129, 202, 0.8);
    display: flex;
    justify-content: center;
    align-items: center;
    transform: translateY(100vh);
    transition: all ease-in-out 100ms;
    border-radius: 20px;
    box-shadow: 0 0 20px #fff
}

.controls-box {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 25px;
    width: 700px;
    height: 500px;
}

.arrows-box {
    color: black;
    display: flex;
    justify-content: space-between;
    align-items: center;
    width: 200px;
    height: 200px;
    border-radius: 10px;
    padding: 10px;
}

.keyboard-icon {
    height: 50px;
    width: 50px;
}

.arraw-info {
    display: flex;
    flex-direction: column;
    align-items: center;
    animation: pulse 2s infinite ease-in-out;
}

.keyboard-icon-space {
    height: 70px;
    width: 150px;
}

.action-box {
    color: black;
    display: flex;
    flex-direction: column;
    gap: 10px;
    width: 250px;
    height: 200px;
    border-radius: 10px;
    padding: 10px;
}

.action-info {
    display: flex;
    align-items: center;
    gap: 10px;
    animation: pulse 2s infinite ease-in-out;
}


.impressum-btn {
    position: absolute;
    bottom: 20px;
    right: 40px;
    cursor: pointer;
    transition: all ease-in-out 100ms;
    z-index: 1;
}

.impressum-btn:hover {
    scale: 1.1;
    text-shadow: 0 0 10px #fff;
}

.impressum-info-container {
    color: black;
    position: absolute;
    flex-direction: column;
    width: 100%;
    height: 100%;
    background-color: rgba(74, 129, 202, 0.8);
    display: flex;
    justify-content: center;
    align-items: center;
    transform: translateY(110%);
    transition: all ease-in-out 100ms;
    border-radius: 20px;
    box-shadow: 0 0 20px #fff;
    overflow: hidden;
    overflow-y: auto;
    padding: 50px 100px;
}

.impressum-headline {
    padding-top: 100px;
}

.d-none {
    display: none;
}

.show-hide-box {
    transform: translateY(0);
}

.endscreen {
    display: none;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    position: absolute;
    width: 850px;
    height: 650px;
    background-image: url(img/sunset.gif);
    background-position: center;
    background-size: cover;
    border-radius: 10px;
}

.d-flex {
    display: flex;
}

.toStartScreenBtn {
    width: 80px;
    height: 80px;
    transition: all ease-in-out 100ms;
    cursor: pointer;
}

.toStartScreenBtn:hover {
    scale: 1.2;
}

.toStartScreenBtn:active {
    scale: 0.9;
}

.endscreen-title {
    font-size: 90px;
    margin: 0;
    animation: pulse 2s infinite ease-in-out;
}

.reset-button {
    font-family: 'pirates';
    display: inline-block;
    padding: 14px 30px;
    font-size: 18px;
    font-weight: bold;
    color: white;
    background-color: rgba(16, 152, 247, 0.8);
    border: 2px solid rgba(16, 152, 247, 1);
    border-radius: 50px;
    text-transform: uppercase;
    cursor: pointer;
    transition: all 0.3s ease-in-out;
    box-shadow: 0 6px 15px rgba(16, 152, 247, 0.5);
    text-align: center;
}

.reset-button:hover {
    background-color: rgba(16, 152, 247, 1);
    color: #f1f1f1;
    transform: scale(1.05);
    box-shadow: 0 8px 20px rgba(16, 152, 247, 0.7);
}

.reset-button:active {
    transform: scale(0.98);
    box-shadow: 0 4px 10px rgba(16, 152, 247, 0.4);
}

.turn-screen {
    position: absolute;
    width: 100vw;
    height: 100vh;
    display: flex;
    justify-content: center;
    align-items: center;
    background-image: url(img/background.jpg);
    background-position: center;
    background-size: cover;
    z-index: 1;
}


@keyframes wippen {

    0%,
    100% {
        transform: translateY(0);
    }

    50% {
        transform: translateY(-4px);
    }
}


@keyframes shimmer {
    0% {
        text-shadow: 0 0 10px #fff, 0 0 20px #ff8c00, 0 0 30px #ff8c00, 0 0 40px #ff4500, 0 0 50px #ff4500, 0 0 60px #ff4500;
    }

    50% {
        text-shadow: 0 0 20px #fff, 0 0 30px #ff8c00, 0 0 40px #ff8c00, 0 0 50px #ff4500, 0 0 60px #ff4500, 0 0 70px #ff4500;
    }

    100% {
        text-shadow: 0 0 10px #fff, 0 0 20px #ff8c00, 0 0 30px #ff8c00, 0 0 40px #ff4500, 0 0 50px #ff4500, 0 0 60px #ff4500;
    }
}


@keyframes glowingShadow {
    0% {
        box-shadow: 0 0 10px #fff, 0 0 20px #ff8c00, 0 0 30px #ff8c00, 0 0 40px #ff4500;
    }

    50% {
        box-shadow: 0 0 20px #fff, 0 0 30px #ff8c00, 0 0 40px #ff8c00, 0 0 50px #ff4500;
    }

    100% {
        box-shadow: 0 0 10px #fff, 0 0 20px #ff8c00, 0 0 30px #ff8c00, 0 0 40px #ff4500;
    }
}


@keyframes pulse {
    0% {
        transform: scale(1);
    }

    50% {
        transform: scale(1.1);
    }

    100% {
        transform: scale(1);
    }
}


@media only screen and (max-width: 720px) {
    canvas {
        width: 100%;
    }
}

@media only screen and (max-height: 480px) {
    canvas {
        height: 100vh;
    }
}

@media (pointer:coarse) {
    .move-container {
        display: flex;
    }

    .action-container {
        display: flex;
    }
}

@media(max-width: 1000px) {

    .game-title {
        display: none;
    }

    .startscreen {
        width: 100vw;
        height: 100vh;
    }

    .endscreen {
        width: 100vw;
        height: 100vh;
    }

    .startscreen-title {
        margin: 0 0 20px 0;
    }

    .start-game-btn {
        width: 230px;
        height: 70px;
    }

    .controls-info-btn {
        bottom: 25px;
        text-shadow: 0 0 10px black;
        z-index: 1;
    }

    .controls-box {
        padding: 0 25px 60px 25px;
    }

    .impressum-headline {
        padding-top: 250px;
    }

}


@media(max-height:500px) {
    .game-title {
        display: none;
    }
}


@media(max-width: 800px) {
    canvas {
        width: 100vw;
        height: 100vh;
        max-height: 650px;
    }
}


@media (min-width: 600px) and (min-height: 300px) {
    .turn-screen {
        display: none;
    }


}

@media(max-width: 720px) {
    .startscreen {
        width: 100vw;
        height: 100vh;
    }

    .fullscreen-icon {
        display: none;
    }
}