/* ========== Reset & základní nastavení ========== */
html {
  scroll-behavior: smooth;
  outline: none;
  caret-color: transparent;
  cursor: cell;
}

body {
  margin: 0;
  font-family: 'Open Sans', Arial, sans-serif;
  background-color: #fff5dc;
  color: #123c7c;
  font-size: 18px;
  line-height: 1.5;
}

.no-scroll {
  overflow: hidden;
}

header, main, footer {
  position: relative;
}

/* ========== Background Images ========== */
.background-images {
  position: fixed;
  top: 0; left: 0;
  width: 100%; height: 100%;
  z-index: 0;
  overflow: hidden;
  pointer-events: none;
}

.background-images img {
  position: absolute;
  opacity: 0.15;
  width: 300px; height: 300px;
  object-fit: cover;
  transition: transform 0.3s ease;
}

.background-images img:nth-child(1) {
  top: 10%; left: 5%;
  transform: rotate(10deg);
}

.background-images img:nth-child(2) {
  top: 50%; left: 20%;
  transform: rotate(-15deg);
}

.background-images img:nth-child(3) {
  top: 70%; left: 60%;
  transform: rotate(25deg);
}

.background-images img:nth-child(4) {
  top: 30%; left: 80%;
  transform: rotate(-30deg);
}

.background-images img:nth-child(5) {
  top: 80%; left: 40%;
  transform: rotate(5deg);
}

/* ========== Header ========== */
header {
  background-color: transparent;
  display: flex;
  justify-content: center;
  align-items: center;
  padding: 1.5em 1em;
  z-index: 10;
}

/* Navigation */
nav {
  position: relative;
}

nav ul {
  list-style: none;
  display: flex;
  align-items: center;
  gap: 1.5em;
  margin: 0;
  padding: 0;
  font-size: 1.5em;
}

nav ul li a {
  text-decoration: none;
  color: #123c7c;
  font-weight: 700;
  transition: color 0.3s ease;
}

nav ul li a:hover,
nav ul li a:focus {
  color: #ff7b00;
}

/* Hamburger menu */
.hamburger {
  display: none;
  font-size: 2.2em;
  cursor: pointer;
  z-index: 10001;
}

.close {
  display: none;
  position: absolute;
  top: 1em;
  right: 1em;
  background-color: #fff5dc;
  padding: 0.2em 0.5em;
  border: 2px solid #ff7b00;
  border-radius: 50%;
  font-size: 2em;
  cursor: pointer;
  z-index: 10001;
}

/* ========== Hero Section ========== */
.hero {
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  min-height: 80vh;
  text-align: center;
  padding: 1em;
  z-index: 5;
}

.hero img {
  width: 40%;
  aspect-ratio: 1/1;
  object-fit: cover;
  display: block;
  margin: 0 auto;
  border-radius: 0;
  transition: transform 0.3s ease;
}

.cta-button {
  background-color: #ff7b00;
  color: white;
  border: none;
  padding: 0.6em 1.4em;
  font-weight: 700;
  cursor: pointer;
  border-radius: 30px;
  margin-top: 1em;
  font-size: 1.1em;
  box-shadow: 0 0 20px rgba(255, 123, 0, 0.6);
  transition: background-color 0.3s ease;
}

.cta-button:hover,
.cta-button:focus {
  background-color: #e66a00;
}

/* ========== Termíny Section (karty) ========== */
.terminy {
  padding: 2em 1em;
  text-align: center;
  max-width: 1200px;
  margin: 0 auto;
}

.terminy h2 {
  font-size: 3.5em;
  text-align: left;
  padding-left: 16%;
  margin-bottom: 1em;
  color: #123c7c;
  font-weight: 700;
  user-select: none;
}

.terminy .cards {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 1rem;
  margin-top: 2rem;
}

.card {
  background: rgba(255, 255, 255, 0.05);
  border: 2px solid rgba(255, 255, 255, 0.1);
  border-radius: 1rem;
  padding: 1rem 1.5rem;
  color: white;
  text-align: center;
  min-width: 180px;
  max-width: 220px;
  transition: all 0.5s ease;
  cursor: pointer;
  user-select: none;
}

.card h3 {
  font-size: 2.5rem;
  color: #ff7b00;
  margin-bottom: 0.5rem;
}

.card p {
  margin: 0.5rem 0;
  color: #333;
  font-size: 1rem;
}

/* Zvýraznění aktivní karty */
.card.active {
  box-shadow: 0 0 20px rgba(255, 123, 0, 0.6);
  border-color: #ff7b00;
  transform: scale(1.05);
  background-color: #fff5e6;
  color: #123c7c;
}

.card:hover:not(.active) {
  transform: translateY(-8px);
  box-shadow: 0 12px 25px rgba(255, 123, 0, 0.3);
  background-color: #fff5e6;
  color: #123c7c;
}

/* ========== O nás Section ========== */
.onas {
  padding: 2em 1em;
  background-color: transparent;
  max-width: 1200px;
  margin: 0 auto;
}

.onas-content {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: 2em;
}

.onas-text {
  flex: 1 1 300px;
}

.onas-text h2 {
  font-size: 3.5em;
  margin-bottom: 0.5em;
  color: #123c7c;
  text-align: center;
}

.onas-text p {
  max-width: 700px;
  font-weight: 700;
  padding-left: 50px;
}

.onas-img {
  flex: 1 1 300px;
  text-align: center;
  padding-top: 60px;
}

.onas-img img {
  max-width: 30%;
  height: auto;
  object-fit: cover;
  border-radius: 100px;
  box-shadow: 0 0 20px rgba(255, 123, 0, 0.6);
  transition: transform 0.3s ease;
}

.onas-img img:hover {
  transform: scale(1.05);
}

/* ========== Galerie Section ========== */
.galerie {
  padding: 2em 1em;
  background-color: transparent;
  text-align: center;
  max-width: 1200px;
  margin: 0 auto;
}

.gallery-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  background-position: center;
  background-repeat: no-repeat;
  background-size: contain;
  background-color: rgba(0,0,0,0.8);
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.3s ease;
  z-index: 10000;
  cursor: pointer;
}

.gallery-overlay.active {
  opacity: 1;
  visibility: visible;
}


.galerie h2 {
  font-size: 3.5em;
  margin-bottom: 1em;
  color: #123c7c;
}

.gallery-grid {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 1em;
}

.gallery-item {
  position: relative;
  width: 100%;
  padding-top: 100%; /* čtvercové položky */
  overflow: hidden;
  cursor: pointer;
  border-radius: 5px;
  box-shadow: 0 0 10px rgba(0,0,0,0.3);
  transition: transform 0.3s ease;
}

.gallery-item img {
  position: absolute;
  top: 0; left: 0;
  width: 100%; height: 100%;
  object-fit: cover;
  transition: transform 0.3s ease;
  border-radius: 5px;
}

.gallery-item:hover img {
  transform: scale(1.1);
}

.gallery-item.active {
  position: fixed;
  top: 50%; left: 50%;
  width: 80vw; height: 80vw;
  max-width: 90vh; max-height: 90vh;
  transform: translate(-50%, -50%) scale(1);
  z-index: 1000;
  background: white;
  border-radius: 10px;
  box-shadow: 0 0 50px rgba(0,0,0,0.8);
}

.gallery-item.active img {
  object-fit: contain;
  width: 100%; height: 100%;
  border-radius: 10px;
  transform: scale(1);
}

.gallery-overlay {
  display: none;
  position: fixed;
  top: 0; left: 0;
  width: 100%; height: 100%;
  backdrop-filter: blur(10px);
  background: rgba(0,0,0,0.5);
  z-index: 900;
}

.gallery-overlay.active {
  display: block;
}

/* ========== Footer ========== */
footer {
  background-color: transparent;
  padding: 2em 1em;
  font-size: 1.2em;
  color: #123c7c;
  max-width: 1000px;
  margin: 0 auto;
  text-align: center;
}

.footer-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 2em;
}

.footer-grid > div {
  text-align: center;
}

.footer-logo {
  max-width: 250px;
  height: auto;
}

.credits {
  font-size: 1.2em;
  color: #ff7b00;
  text-align: center;
}

.footer-links ul {
  list-style: none;
  padding: 0;
  margin: 0;
}

.footer-links li {
  margin-bottom: 0.5em;
}

.footer-links a {
  text-decoration: none;
  color: #123c7c;
  font-weight: 700;
  transition: color 0.3s ease;
}

.footer-links a:hover,
.footer-links a:focus {
  color: #ff7b00;
}

/* ========== Media Queries ========== */
/* Tablety a menší desktopy */
@media (max-width: 1024px) {
  .terminy h2 {
    padding-left: 2em;
  }

  .onas-text p {
    padding-left: 20px;
  }
}

/* Menší tablety a velké mobily */
@media (max-width: 768px) {
  /* Navigace - hamburger menu */
  .hamburger {
    display: block;
  }

  nav ul {
    display: none;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    position: fixed;
    top: 0; left: 0;
    width: 100vw; height: 100vh;
    background-color: rgba(255, 245, 220, 0.98);
    gap: 2em;
    margin: 0; padding: 0;
    z-index: 9999;
  }

  nav ul.active {
    display: flex;
  }

  nav ul li a {
    font-size: 2em;
  }

  nav ul li a:hover,
  nav ul li a:focus {
    color: #ff7b00;
  }

  nav ul:not(.active) {
    display: none;
  }

  /* Hero obrázek větší na mobilu */
  .hero img {
    width: 80%;
  }

  /* Termíny section */
  .terminy h2 {
    font-size: 2.5em;
    padding-left: 1em;
    text-align: center;
  }

  .terminy .cards {
    flex-direction: column;
    align-items: center;
    gap: 1rem;
  }

  .card {
    width: 90%;
    max-width: 320px;
    font-size: 1.1em;
    padding: 1.2em;
  }

  .onas-text h2 {
    font-size: 2.5em;
  }

  .onas-text p {
    padding-left: 0;
    max-width: 100%;
  }

  .onas-img {
    padding-top: 0;
    margin-top: 1.5em;
  }

  .onas-img img {
    max-width: 60%;
  }

  /* Galerie grid na mobilu */
  .gallery-grid {
    grid-template-columns: repeat(2, 1fr);
    max-width: 90vw;
  }
}

/* Mobily */
@media (max-width: 480px) {
  body {
    font-size: 16px;
  }

  .terminy h2 {
    font-size: 2em;
  }

  .card h3 {
    font-size: 2rem;
  }

  .card p {
    font-size: 0.9rem;
  }

  .footer-grid {
    grid-template-columns: 1fr;
  }

  .gallery-grid {
    grid-template-columns: 1fr;
  }

  .onas-text h2 {
    font-size: 2em;
  }

  .cta-button {
    font-size: 1em;
    padding: 0.5em 1em;
  }
}
