@media screen and (min-width: 1000px) {
    #main-nav {
        display: block !important;
    }
}

@media screen and (max-width: 999px) {
    .shop-link {
        display: flex;
    }

    .show-nav {
        display: inline-block;
        font-size: 18px;
        padding: 7px 10px;
    }

    #main-nav {
        display: none;
        z-index: 1000;
    }

    .main-nav {
        position: absolute;
        flex-direction: column;
        align-items: flex-start;
        background-color: var(--light-grey);
        top: 65px;
        right: 50px;
        padding: 10px 0;
        margin-top: 0;
        margin-bottom: 0;
        margin-right: 0;
        box-shadow: 1px 1px 3px rgba(0,0,0,.3);
    }

    .main-nav li, .main-nav li:last-of-type {
        display: block;
        margin: 0px;
    }

    .main-nav a {
        padding: 8px 21px !important;
        display: block;
        text-align: left;
    }

}

@media screen and (max-width: 850px) {
    .gallery-long::before, .gallery-long::after {
        width: 30px;
    }

    .rectangle:first-of-type {
        margin-left: -30px;
    }

    .rectangle:last-of-type {
        margin-right: -30px;
    }

    #kontakty .box-content {
        max-width: 400px;
    }

    .contact-peoples {
        flex-direction: column;
        justify-content: flex-start;
        align-items: flex-start;
        max-width: 250px;
        margin: 0 auto;
        padding: 0 !important;
    }

    .contact-peoples div {
        margin-top: 10px;
    }
}

@media screen and (max-width: 780px) {
    .product, .product:nth-of-type(3n) {
        width: calc(50% - 5px);
        margin-right: 10px;
    }

    .product:nth-of-type(2n) {
        margin-right: 0;
    }
}

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

    #variants .variant .variant-name {
        display: block;
        margin-bottom: 5px;
    }

    .gallery-long {
        height: 155px;
    }

    .rectangle {
        height: 140px;
    }

    .inner-rectangle {
        height: 140px;
    }
}

@media screen and (max-width: 650px) {
    .category-headline {
        flex-wrap: wrap;
    }

    #category-nav button {
        display: flex;
    }

    #category-nav {
        width: 100%;
    }

    .category-nav {
        margin: -32px 0 30px 0;
        padding: 12px 10px 10px 10px;
        flex-direction: column;
        background-color: var(--light-grey);
        border-radius: 0 0 2px 2px;
        display: none;
    }

    .category-nav li {
        text-align: center;
        box-sizing: border-box;
        max-width: 250px;
        width: 100%;
        margin: 5px 0;
    }
}

@media screen and (max-width: 630px) {
    .card {
        flex-direction: column !important;
    }

    .card .text {
        margin: 0 !important;
        padding: 30px 5%;
    }

    .card .img {
        height: 50vw;
        max-height: 200px;
    }

    .card .text, .card .img {
        box-sizing: border-box;
        width: 100%;
    }
}

@media screen and (max-width: 540px) {
    #content p{
        text-align: left;
    }

    #description, #images {
        width: 100%;
    }

    #images {
        margin-top: 30px;
    }
}

@media screen and (max-width: 490px) {
    .product-buttons {
        width: calc(100% - 18px);
        left: 9px;
    }

    .product-description {
        padding: 15px 9px 55px 9px;
    }

    .shrnuti-product {
        flex-direction: column;
        align-items: flex-start;
    }

    .shrnuti-product-description {
        justify-content: flex-end;
        box-sizing: border-box;
        width: 100%;
    }

    .shrnuti-product-description div {
        margin-top: 10px;
    }
}

@media screen and (max-width: 460px) {
    #logo img {
        height: 20px;
    }

    #kontakty .box-content{
        max-width: 100%;
    }

    .cart-product-image {
        width: 50px;
        height: 50px;
    }

    .cart-product-description {
        width: calc(100% - 60px);
    }

    .cart-product {
        align-items: center;
    }

    #fakturace table tr {
        display: flex;
        flex-direction: column;
    }

    #fakturace table tr td:nth-of-type(2){
        padding: 0 12px 0 12px;
    }

    #fakturace table tbody:nth-of-type(2) tr:first-of-type td:last-of-type{
        border-top: none;
    }

    #fakturace table td:first-of-type{
        box-sizing: border-box;
        width: 100%;
    }
}

@media screen and (max-width: 430px) {
    .product, .product:nth-of-type(2n), .product:nth-of-type(3n) {
        width: 100%;
        margin-right: 0;
    }

    .product-img {
        padding-top: 80%;
    }

    .product-buttons {
        width: calc(100% - 30px);
        left: 15px;
    }

    .product-description {
        padding: 15px 15px 55px 15px;
    }

    .shrnuti-udaje {
        width: 100%;
    }

    .shrnuti-udaje:nth-of-type(2) {
        margin-top: 30px;
    }

    .shrnuti-doprava {
        flex-direction: column;
        align-items: flex-start;
    }

    .shrnuti-doprava-description {
        margin-top: 10px;
        width: 100%;
        justify-content: space-between;
    }

    .shrnuti-doprava-description div:first-of-type {
        width: auto;
    }
}

@media screen and (max-width: 405px) {
    .contact-address {
        display: flex;
        justify-content: center;
        max-width: 250px !important;
    }

    .contact-address a {
        text-align: left;
    }

    .other-contacts {
        flex-direction: column;
        align-items: center;
    }
}

@media screen and (max-width: 360px) {
    .shop-link {
        display: none;
    }

    .gallery-long {
        height: 125px;
    }

    .rectangle {
        height: 110px;
    }

    .inner-rectangle {
        height: 110px;
    }
}
