/* Stránka */
:root {
  --bg-color: white;
  --text-color: black;
}

#logo {
  width: 10rem;
}

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
  list-style-type: none;
}
html,
body {
  display: flex;
  flex-direction: column;
  scrollbar-width: none;
  scroll-behavior: smooth;
  height: 100%;
  width: 100%;
  font-family: sans-serif;
  background-color: var(--bg-color);
  color: var(--text-color);
}
.innerDiv {
  display: flex;
  flex-direction: column;
  gap: 2rem; /* Tímto si pevně určíte velikost mezery mezi textem a formulářem */
  max-width: 600px; /* Aby se formulář neroztáhl přes celou obrazovku */
}
h1 {
font-size: clamp(2rem, 5vw, 3rem);
  margin-bottom: 0.5em;
}

p {
font-size: clamp(1rem, 2.5vw, 1.5rem);
}

a {
  color: inherit;
  text-decoration: none;
  transition: 0.2s;
}

p a {
  text-decoration: underline;
  color: inherit;
}

a:hover {
  font-weight: bold;
}

/* navigace */

nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1.5em;
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  background: var(--bg-color);
  z-index: 12;
}

nav img {
  height: 30px !important;
  cursor: pointer;
}

nav ul {
  display: flex;
  gap: 1.5em;
  list-style: none;
}
nav li {
  cursor: pointer;
}

/* Navigace telefon */
#LinksMobile {
  display: none;
}
#exit {
  display: none;
  position: fixed;
  z-index: 14;
  right: 24px;
  top: 24px;
  cursor: pointer;
}

#menu {
  display: none;
}

/* main */
main,
section {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: space-evenly;

  flex-wrap: wrap;
}

main {
  text-align: center;
}

main img,
section img {
  max-width: 45%;

  height: auto;
}

/* Sekce */
section ul {
  list-style: none;
  max-width: 500px;
}

.card-container {
  position: relative;
  height: 80%;
  width: 50%;
}

iframe {
  width: 100%;
  height: 100%;
  border-radius: 1rem;
  border: 0;
}

.card {
  position: absolute;
  width: 100%;
  height: 100%;
  border-radius: 1rem;
  background-size: cover;
  background-position: center;
  transition: all 0.5s ease-in-out;
  box-shadow: 0 10px 20px rgba(0, 0, 0, 0.2);
  top: 50px;
  left: 50px;
  opacity: 0;
  z-index: 0;
}

.card:nth-last-child(1) {
  top: 0;
  left: 0;
  opacity: 1;
  z-index: 10;
}

.card:nth-last-child(2) {
  top: 50px;
  left: 50px;
  opacity: 0.5;
  z-index: 9;
  cursor: pointer;
}

.card:nth-last-child(1) iframe {
  scrollbar-width: none;
  scroll-behavior: smooth;
}

.card:nth-last-child(2) iframe {
  pointer-events: none;
}

/* Sekce kontakt */
#popis {
  resize: none;
}

#kontakt,
#projekty {
  justify-content: space-around;
}

/* Formulář */

input:focus,
textarea:focus {
  outline: 1px solid var(--text-color);
}
form button {
  border: none;
}
form {
  display: flex;
  flex-direction: column;

  gap: 1em;
}

form input,
form textarea {
  width: 100%;
  background-color: var(--input);
  color: var(--text-color);
  outline: none;
  border: 1px solid var(--text-color);
  padding: 1em;
  font-size: 1rem;
}

form ul {
  display: flex;
  gap: 1em;
}
form li {
  flex: 1;
}
form button {
  background-color: var(--text-color);
  width: 100%;
  color: var(--bg-color);
  padding: 1em;
}
form button:hover {
  cursor: pointer;
  background-color: var(--bg-color);
  color: var(--text-color);
}

/* Telefon */
@media (max-width: 1058px) {
  /* stránka */
  .card-container{
      width: 80%;

  }
  /* navigace */
  #Links {
    display: none;
  }
  #menu {
    display: block !important;
  }
  nav ul {
    display: none;
    top: 0;
    left: 0;
    position: fixed;
    flex-direction: column;
    z-index: 13;
    gap: 3em;
    font-weight: bold;
    font-size: 1em;
    width: 100vw;
    height: 100vh;
    background-color: var(--bg-color);
    justify-content: center;
    align-items: center;
  }

  /* Sekce */
  main,
  section {
    flex-direction: row;
    text-align: center;
    padding: 2em;
    justify-content: center;
  }
  /* Sekce galerie */
  #container {
    width: 100% !important;
    height: 50%;
  }

  /* formulář */
  form ul {
    flex-direction: column;
  }

  /* patička */
  footer {
    flex-direction: column;
    align-items: center;
    gap: 2em;
  }
  #socials {
    margin: auto !important;
  }
  footer p {
    text-align: center;

    margin-left: 0px !important;
  }

  #projekty {
    flex-direction: row;
    margin-bottom: 10rem;
  }

  .card-container {
    width: 100% !important;
    margin-right: 3rem;
  }
}

/* patička */
#projekty{
      gap: 7rem;

}
footer {
  display: flex;
  align-items: center;
  width: 100%;
  padding: 1.5em;
}

footer p {
  font-size: 1em;
}
footer ul {
  margin-left: auto;
}
#socials {
  margin-left: auto;
  display: flex;
  align-items: center;
  gap: 0.5rem;
}
@media (prefers-color-scheme: dark) {
  form input,
  form textarea {
    border: none;
  }
  nav img,
  nav svg {
    filter: invert(1);
    -webkit-filter: invert(1);
  }
  nav,
  footer {
    background-color: rgb(20, 20, 20);
  }

  :root {
    --bg-color: rgb(30, 30, 30);
    --text-color: white;
    --input: rgb(50, 50, 50);
  }
}
#path2 {
  stroke-dasharray: 430;
  stroke-dashoffset: 800;

  animation: x 0.6s linear;
  animation-fill-mode: forwards;
}

#path3 {
  stroke-dasharray: 430;
  stroke-dashoffset: 800;

  animation: x 0.6s linear;
  animation-fill-mode: forwards;
  animation-delay: 0.3s;
}

@keyframes x {
  from {
    stroke-dasharray: 430;
  }
  to {
    stroke-dasharray: 400;
  }
}

#path2 {
  stroke-dasharray: 430;
  stroke-dashoffset: 800;

  animation: x 0.3s linear;
  animation-fill-mode: forwards;
}

#path3 {
  stroke-dasharray: 430;
  stroke-dashoffset: 800;

  animation: x 0.3s linear;
  animation-fill-mode: forwards;
  animation-delay: 0.1s;
}

@keyframes x {
  from {
    stroke-dasharray: 430;
  }
  to {
    stroke-dasharray: 400;
  }
}
