* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}
html, body {
  height: 100%;
  font-family: sans-serif;
  background-color: #ffffff;
  font-size: 25px;
}

@media (max-width: 768px) {
  html {
    font-size: 14px; /* tablet – všechno textové se zmenší */
  }
}

@media (max-width: 480px) {
  html {
    font-size: 12px; /* mobil – všechny fonty se zmenší proporčně */
  }
}

header {
    position: relative;
    background-image: url("usedimages/roof_upscaled.jpg");
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    height: 50vh;
    width: 100vw;
    color: #ffffff;

    display: flex;
    justify-content: center;
    align-items: center;
    text-align: center;
}

header::before {
    content: "";
    position: absolute;
    top: 0; left: 0;
    width: 100%; height: 100%;
    background-color: rgba(0, 0, 0, 0.4); /* černý filtr 40% průhledný */
    z-index: 1;
}

.headertext > * {
    position: relative;
    z-index: 2; /* aby text byl nad filtrem */
    /*background-color: rgba(0, 0, 0, 0.3); pozadi hlavniho textu mně se libi ale klidně smažu
    padding: 3vh 6vw; větší odsazení kolem textu */
    display: inline-block; /* aby se pozadí přizpůsobilo obsahu */
    border-radius: 8px;
  }

main {
    margin: 5vh clamp(2vw, 10%, 15vw); /* vlevo/vpravo min 2vw, ideálně 10%, max 15vw */
    display: flex;
    flex-direction: column;
}

.textbox {
    max-width: 30vw;
    margin: 5vh 5vw 5vh 5vh;
    display: flex;
    justify-content: center;
    align-items: center;
    text-align: start;

    font-size: 1rem;
}

h1 {
    font-size: 4rem;
    margin: 0; /* odstraní defaultní okraje */
    border-radius: 4px;
}

h2 {
  font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
  font-size: 2rem;
  font-weight: 600;
  color: #2c3e50;
  border-bottom: 2px solid #c18a53;
  padding-bottom: 0.3em;
  margin-top: 1.5em;
  margin-bottom: 1em;
  text-transform: uppercase;
  letter-spacing: 1px;
}
.service h3 {
  width: 25vw;
  font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
  font-size: 1.2rem;              /* menší než h2 */
  font-weight: 500;              /* lehčí než h2 */
  color: #34495e;                /* trochu světlejší než h2 */
  margin-top: 1.2em;
  margin-bottom: 0.8em;
  letter-spacing: 0.5px;
  text-transform: uppercase;
  border-left: 3px solid #c18a53; /* decentní zvýraznění */
  padding-left: 0.7em;

  background-color: #f5f0e6; /* jemné béžové pozadí */
  padding: 0.3em 0.7em;      /* trochu vnitřního odsazení */
}

.tworow {
    display: flex;
    align-items: flex-start;
}

.tworow p {
  font-size: 1rem;
  margin: 1rem 1.8rem;
  width: 50%;
}

p {
  font-size: 1rem;
}
.tworow h3 {
  margin: 0;       /* odstraní přidané mezery */
  padding-left: 1em; /* odsazení textu od levého okraje */
  display: flex;      /* aby se dal text zarovnat */
  align-items: center; /* vertikální zarovnání */
}


.tworow div {
  margin: 2vh 1vw 2vh;
}

#headline span {
    display: inline-block;
    transform: translateY(-10px);
    transition: all 0.3s ease;
}

.titleIMG {
    display: block;
    max-width: 50%;
    height: auto;
    border-radius: 15px; /* zaoblení rohů */
    box-shadow: 0 4px 15px rgba(0,0,0,0.2);
    transition: transform 0.4s ease, box-shadow 0.4s ease, border 0.4s ease;
    margin: 20px auto; /* mezery kolem obrázku */
}

.titleIMG:hover {
    transform: scale(1.05); /* lehké přiblížení */
    box-shadow: 0 8px 25px rgba(0,0,0,0.3);
    border: 3px solid rgba(255, 165, 0, 0.8); /* oranžový rámeček */
}

/*footer*/
footer {
  background-color: #222;
  color: #fff;
  padding: 40px 20px 20px;
  font-family: Arial, sans-serif;
}

.footer-container {
  margin: 0 3vw;
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 30px;
}

.footer-contact, .footer-form {
  margin: 8vh 5vw 0;
  /*flex: 1 1 300px;*/
}

.footer-contact h3,
.footer-form h3 {
  margin-bottom: 15px;
  color: #ffcc00;
}

.footer-contact a {
  color: #ffcc00;
  text-decoration: none;
}
.footer-contact a:hover {
  text-decoration: underline;
}

.footer-form form {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.footer-form input,
.footer-form textarea {
  padding: 10px;
  border: none;
  border-radius: 5px;
  font-size: 14px;
}

.footer-form textarea {
  min-height: 100px;
  resize: vertical;
}

.footer-form button {
  background-color: #ffcc00;
  border: none;
  padding: 12px;
  font-size: 14px;
  cursor: pointer;
  border-radius: 5px;
  font-weight: bold;
}

.footer-form button:hover {
  background-color: #e6b800;
}

.footer-bottom {
  text-align: center;
  padding-top: 20px;
  border-top: 1px solid #444;
  margin-top: 30px;
  font-size: 13px;
  color: #aaa;
}

/* lightbox galerie */
.gallery {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  align-items: center;
  gap: 2vw;
}

.gallery img {
  width: clamp(150px, 18vw, 400px);   /* min 150px, ideálně 18% šířky okna, max 300px */
  height: clamp(150px, 32vh, 400px);  /* min 150px, ideálně 32% výšky okna, max 400px */
  margin: 4vh 1vw 2vh;
  object-fit: cover;
  cursor: pointer;
  border: 2px solid #c18a53;
  border-radius: 6px;
  transition: transform 0.2s;
}

.gallery img:hover {
  transform: scale(1.05);
}

/* Lightbox overlay */
.lightbox {
  position: fixed;
  z-index: 1000;
  left: 0;
  top: 0;
  width: 100%;
  height: 100%;
  background: rgba(0,0,0,0.8);
  display: none;
  align-items: center;
  justify-content: center;
}

.lightbox img {
  max-width: 90%;
  max-height: 90%;
}

.lightbox .close, .lightbox .prev, .lightbox .next {
  position: absolute;
  color: white;
  font-size: 2rem;
  cursor: pointer;
  user-select: none;
  background: rgba(0,0,0,0.3);
  padding: 10px;
  border-radius: 5px;
}

.lightbox .close { top: 20px; right: 20px; }
.lightbox .prev { left: 20px; top: 50%; transform: translateY(-50%); }
.lightbox .next { right: 20px; top: 50%; transform: translateY(-50%); }

.lightbox .prev:hover,
.lightbox .next:hover,
.lightbox .close:hover {
  background: rgba(0,0,0,0.6);
}