@keyframes article-scroll-animation {
    0%, 100% {
        transform: scale(0.7);
    }
    50% {
        transform: scale(1);
    }
}
@keyframes gallery-scroll-animation {
    0%, 100% {
        transform: scale(0.85);
    }
    50% {
        transform: scale(1);
    }
}
@keyframes loadingIcon {
    0% {
        transform: rotate(0deg);
    }
    100% {
        transform: rotate(360deg);
    }
}
.loading {
    display: flex;
    justify-content: center;
    align-items: center;
    flex-direction: column;
    font-size: 1.5rem;
    width: 100%;
}
.loading i {
    font-size: 5rem;
    color: var(--color2);
}

main section {
    width: 100%;
    height: -moz-max-content;
    height: max-content;
    margin: 2rem auto;
    padding: 5rem 2rem;
    background-color: rgba(0, 0, 0, 0.6);
    color: var(--color2);
}
main section h2 {
    font-size: 2.2rem;
    margin-bottom: 1rem;
    text-align: center;
}
main section p {
    font-size: 1.5rem;
    margin: 1rem 0;
    text-align: center;
}
main section article {
    width: 100%;
    max-width: 1200px;
    min-height: 300px;
    margin: 2rem auto;
    display: flex;
    flex-direction: column;
    position: relative;
    text-align: center;
}

main section article.prehledObchodu {
    max-width: none;
}

@media screen and (prefers-reduced-motion: no-preference) {
    main section article {
      animation: article-scroll-animation linear;
      animation-timeline: view();
    }
}
main section article::after {
    z-index: 999;
    font-size: clamp(2rem, 2.5rem + 1vw, 4rem);
    position: absolute;
    top: 1rem;
    right: 1rem;
}
main section article.private::after {
    content: "🔒";
}
main section article.spanish::after {
    content: "";
    background-image: url("https://motejzik.eu/images/icon.png");
    background-size: contain;
    background-repeat: no-repeat;
    background-position: center;
    width: 5rem;
    height: 5rem;
}
main section article.inprogress::before {
    content: "🚧";
    top: 1rem;
    left: 1rem;
    right: inherit;
}
main section article.place h3::before {
    content: "#Moje oblíbené místo";
    color: #62b670;
}
main section article.food h3::before {
    content: "#Moje oblíbené jídlo";
    color: #b6ae62;
}
main section article.activity h3::before {
    content: "#Moje oblíbená aktivita";
    color: #62a2b6;
}
main section article .text-container, main section article .img-container {
    flex: 1;
}
main section article h3 {
    font-size: clamp(16px, 2rem + 1vw, 1.7rem);
    margin: 1rem 0;
}
main section article h3::before {
    display: block;
    margin-right: 0.5rem;
    font-size: 1.8rem;
    font-weight: bold;
}
main section article p {
    font-size: clamp(13px, 1.5rem + 1vw, 1.3rem);
    margin: 1rem 0;
    font-style: italic;
}
main section article .img-container {
    position: absolute;
    width: 100%;
    height: 100%;
    top: 0;
    left: 0;
  
    padding: 0;
    border-width: 0;
    border-image-source: linear-gradient(-45deg, rgba(0, 0, 0, 0.5) 0%, rgba(0, 0, 0, 0.85) 100%);
    border-image-slice: fill 1;
    border-style: solid;
}
main section article .img-container img {
    display: block;
    width: 100%;
    height: 100%;
    -o-object-fit: cover;
       object-fit: cover;
    position: relative;
    z-index: -1;
    box-shadow: 0 0 1rem #000;
}
main section article .text-container {
    display: flex;
    flex-direction: column;
    justify-content: center;
    padding: 1rem 2rem;
    position: relative;
    text-align: center;
}
main section ul {
    display: flex;
    align-items: center;
    justify-content: center;
    flex-direction: column;
    gap: 1rem;
    width: -moz-fit-content;
    width: fit-content;
    max-width: 100%;
    margin: 2rem auto;
}
main section ul li {
    width: 100%;
    list-style: none;
    font-size: 1.5rem;
    padding: 1rem 2rem;
    background-color: var(--color150);
    border-radius: 0.5rem;
}
main section .gallery {
    max-width: 700px;
    margin: 2rem auto;
}
@media screen and (prefers-reduced-motion: no-preference) {
    main section .gallery {
      animation: gallery-scroll-animation linear;
      animation-timeline: view();
    }
}
.img-wrapper {
    position: relative;
    max-height: 500px;
    overflow: hidden;
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 999;
}
.img-wrapper img {
    display: block;
    width: 100%;
    height: 100%;
    -o-object-fit: cover;
       object-fit: cover;
}
main section .gallery .img-wrapper {
    overflow: hidden;
    border-radius: 0.5rem;
    box-shadow: 0 0 1rem #000;
    height: 5rem;
    opacity: 0.7;
    scale: 0.9;
    cursor: pointer;
    margin-block: 1rem;
}
main section .gallery .img-wrapper.active {
    height: -moz-fit-content;
    height: fit-content;
    opacity: 1;
    scale: 1;
    cursor: default;
}
main section .gallery .img-wrapper.active img {
    height: auto;
}

main section .gallery img {
    width: 100%;
    height: 100%;
    -o-object-fit: cover;
       object-fit: cover;
    border-radius: 0.5rem;
    
    transition: all 0.5s ease-in-out;
    cursor: pointer;
}
.img-wrapper::after, .imgContainer::after {
    content: attr(data-author);
    display: block;
    font-size: 1rem;
    color: var(--color2);
    position: absolute;
    bottom: 0;
    right: 0;
    background-color: rgba(0, 0, 0, 0.5);
    padding: 0.5rem;
    border-top-left-radius: 0.5rem;
}


/*
@media (width > 600px) {
    main section h2 {
      font-size: 3.5rem;
    }
    main section a:nth-of-type(even) article {
      flex-direction: row-reverse;
    }
    main section a:nth-of-type(even) article .img-container {
      border-image-source: linear-gradient(45deg, rgba(0, 0, 0, 0.5) 0%, rgba(0, 0, 0, 0.85) 100%);
    }
    main section article {
      flex-direction: row;
    }
    main section article .text-container {
      display: flex;
      flex-direction: column;
      justify-content: center;
      padding: 1rem 2rem;
      position: relative;
      text-align: center;
    }
    main section article.pravidlaCasovani {
      flex-direction: column;
    }
}
*/