
:root {
  --gold-primary: #D4AF37;
  --gold-light: #FFD700;
  --blue-primary: #1160AF;
}

.year-selector {
  margin: 25px 0;
  display: flex;
  justify-content: center;
  gap: 12px;
  flex-wrap: wrap;
  animation: buttonSlideIn 0.6s ease-out;
}

@keyframes buttonSlideIn {
  from { opacity: 0; transform: translateY(-15px); }
  to { opacity: 1; transform: translateY(0); }
}

.year-selector button {
  background: linear-gradient(135deg, var(--blue-primary), #0F3D7D);
  color: #fff;
  border: 2px solid var(--gold-primary);
  padding: 12px 24px;
  border-radius: 8px;
  cursor: pointer;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  transition: all 0.3s ease;
  font-size: 0.95rem;
  box-shadow: 0 4px 12px rgba(212, 175, 55, 0.15);
}

.year-selector button:hover {
  background: linear-gradient(135deg, var(--gold-primary), var(--gold-light));
  color: var(--blue-primary);
  transform: translateY(-3px);
  box-shadow: 0 8px 20px rgba(212, 175, 55, 0.3);
}

.year-selector button.active {
  background: linear-gradient(135deg, var(--gold-primary), var(--gold-light));
  color: var(--blue-primary);
  border-color: var(--gold-light);
}
/* gallery-grid styles further below (kept single definition) */

/* Styly pro formulář filtru */
.filter-form {
  display: flex;
  flex-wrap: wrap;
  gap: 20px;
  margin-bottom: 30px;
  justify-content: center;
  align-items: flex-end;
  background: linear-gradient(135deg, rgba(15, 61, 125, 0.6), rgba(17, 96, 175, 0.6));
  padding: 25px;
  border-radius: 12px;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.3);
  border: 1px solid rgba(212, 175, 55, 0.2);
  animation: formFadeIn 0.7s ease-out;
}

@keyframes formFadeIn {
  from { opacity: 0; transform: translateY(10px); }
  to { opacity: 1; transform: translateY(0); }
}

.filter-group {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
}

.filter-form label {
  margin-bottom: 8px;
  font-weight: 700;
  color: var(--gold-light);
  text-transform: uppercase;
  letter-spacing: 0.5px;
  font-size: 0.9rem;
}

.filter-form select,
.filter-form input[type="text"] {
  padding: 10px 15px;
  border: 2px solid var(--gold-primary);
  border-radius: 6px;
  background-color: rgba(0, 31, 77, 0.7);
  color: #fff;
  font-size: 16px;
  min-width: 150px;
  -webkit-appearance: none;
  -moz-appearance: none;
  appearance: none;
  background-image: url('data:image/svg+xml;charset=US-ASCII,%3Csvg%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%20viewBox%3D%220%200%204%205%22%3E%3Cpath%20fill%3D%22%23FFD700%22%20d%3D%22M2%200L0%202h4zm0%205L0%203h4z%22%2F%3E%3C%2Fsvg%3E');
  background-repeat: no-repeat;
  background-position: right 10px center;
  background-size: 12px;
  padding-right: 30px;
  transition: all 0.3s ease;
}

.filter-form select:focus,
.filter-form input[type="text"]:focus {
  outline: none;
  border-color: var(--gold-light);
  box-shadow: 0 0 8px rgba(255, 215, 0, 0.4);
  background-color: rgba(0, 31, 77, 0.9);
}

.filter-button {
  padding: 12px 28px;
  background: linear-gradient(135deg, var(--gold-light), var(--gold-primary));
  color: #001f4d;
  border: 2px solid var(--gold-primary);
  border-radius: 8px;
  cursor: pointer;
  font-size: 16px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  transition: all 0.3s ease;
  box-shadow: 0 4px 12px rgba(212, 175, 55, 0.25);
}

.filter-button:hover {
  background: linear-gradient(135deg, var(--gold-primary), var(--gold-light));
  transform: translateY(-3px);
  box-shadow: 0 8px 20px rgba(212, 175, 55, 0.4);
}

.filter-button:active {
  transform: translateY(-1px);
}

.filter-button:hover {
  background: linear-gradient(135deg, var(--gold-primary), var(--gold-light));
  transform: translateY(-3px);
  box-shadow: 0 8px 20px rgba(212, 175, 55, 0.4);
}

.filter-button:active {
  transform: translateY(-1px);
}

/* Styly pro mřížku galerie */
.gallery-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  gap: 18px;
  padding: 20px;
  background: linear-gradient(135deg, rgba(15, 61, 125, 0.05), rgba(17, 96, 175, 0.05));
  border-radius: 12px;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.15);
  border: 1px solid rgba(212, 175, 55, 0.1);
  animation: gridFadeIn 0.8s ease-out 0.2s forwards;
  opacity: 0;
}

@keyframes gridFadeIn {
  from { opacity: 0; }
  to { opacity: 1; }
}

.gallery-item {
  overflow: hidden;
  border-radius: 12px;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
  transition: all 0.4s ease;
  display: block;
  border: 2px solid transparent;
  cursor: pointer;
}

.gallery-item:hover {
  transform: translateY(-8px) scale(1.05);
  box-shadow: 0 12px 30px rgba(212, 175, 55, 0.25);
  border-color: var(--gold-primary);
}

.gallery-item img {
  width: 100%;
  height: 200px;
  min-height: 120px;
  object-fit: cover;
  display: block;
  transition: transform 0.4s ease;
}

.gallery-item:hover img {
  transform: scale(1.1);
}

/* Zpráva, pokud nejsou nalezeny žádné fotky */
.no-photos-message {
  text-align: center;
  color: var(--gold-light);
  font-size: 1.2em;
  margin-top: 30px;
  width: 100%;
  font-weight: 600;
}

/* Responzivita pro menší obrazovky */
@media (max-width: 768px) {
    .filter-form {
        flex-direction: column;
        align-items: stretch;
    }

    .filter-group {
        width: 100%;
    }

    .filter-form select,
    .filter-form input[type="text"] {
        width: 100%;
    }

    .gallery-grid {
        grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); /* Menší sloupce na tabletech */
    }

    .gallery-item img {
        height: 120px; /* Menší výška náhledů na tabletech */
    }
}

@media (max-width: 480px) {
    .gallery-grid {
        grid-template-columns: 1fr; /* Jeden sloupec na mobilních telefonech */
    }

    .gallery-item img {
        height: 200px; /* Větší výška náhledů na mobilech pro lepší viditelnost */
    }
}
/* Custom Lightbox Styly */
.custom-lightbox {
    display: none; /* Ve výchozím nastavení skryté */
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.9); /* Tmavé průhledné pozadí */
    z-index: 1000;
    justify-content: center;
    align-items: center;
    opacity: 0; /* Pro animaci zobrazení */
    transition: opacity 0.3s ease-in-out;
}

.custom-lightbox.active {
    display: flex; /* Zobrazí lightbox */
    opacity: 1; /* Zprůhlední při zobrazení */
}

.lightbox-content {
    position: relative;
    max-width: 90%;
    max-height: 90%;
    background-color: #001f4d; /* Tmavé pozadí pro obsah lightboxu */
    padding: 20px;
    border-radius: 10px;
    box-shadow: 0 0 20px rgba(0, 0, 0, 0.7);
    display: flex;
    flex-direction: column;
    align-items: center;
}

.lightbox-content img {
    max-width: 100%;
    max-height: 70vh; /* Omezí výšku obrázku na 70% výšky viewportu */
    display: block;
    margin-bottom: 15px;
    border-radius: 8px;
    object-fit: contain; /* Ujistí se, že celý obrázek je vidět, i když má jiný poměr stran */
}

.lightbox-caption {
    text-align: center;
    color: #fff;
    font-size: 1.1em;
    padding-top: 10px;
    border-top: 1px solid rgba(255, 255, 255, 0.2);
    width: 100%;
}

.lightbox-caption p {
    margin: 5px 0;
}

.lightbox-close-button {
    position: absolute;
    top: 10px;
    right: 20px;
    color: #fff;
    font-size: 40px;
    font-weight: bold;
    cursor: pointer;
    transition: color 0.3s ease;
    z-index: 1001; /* Zajistí, že je nad obsahem lightboxu */
}

.lightbox-close-button:hover {
    color: #FFD700; /* Zlatá barva při najetí */
}

.lightbox-nav-button {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background-color: rgba(0, 0, 0, 0.5);
    color: #fff;
    border: none;
    padding: 10px 15px;
    font-size: 2em;
    cursor: pointer;
    border-radius: 5px;
    transition: background-color 0.3s ease;
    user-select: none; /* Zabrání označení textu */
}

.lightbox-nav-button:hover {
    background-color: rgba(0, 0, 0, 0.8);
}

.prev-button {
    left: 20px;
}

.next-button {
    right: 20px;
}

/* Styly pro náhledy obrázků v galerii (původní jsou OK, ale pro jistotu) */
.gallery-item {
    cursor: pointer; /* Ukazatel pro kliknutí */
    /* Zde zůstanou ostatní tvé styly pro gallery-item, např. border-radius, shadow atd. */
}

/* Strankovani */

.pagination {
    display: flex;
    justify-content: center;
    align-items: center;
    margin: 20px 0;
    padding: 10px;
    background-color: rgba(0, 31, 77, 0.7);
    border-radius: 15px;
    box-shadow: 0 4px 8px rgba(0,0,0,0.2);
    transition: transform 0.3s;
}

.pagination-form {
    display: flex;
    align-items: center;
    gap: 15px; /* Mezera mezi prvky formuláře */
}

.page-buttons {
    display: flex;
    gap: 10px;
}

.pagination-button {
    background-color: #007bff;
    color: white;
    padding: 8px 15px;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    font-size: 16px;
    transition: background-color 0.3s ease;
}

.pagination-button:hover {
    background-color: #0056b3;
}

.pagination-button:disabled {
    background-color: #cccccc;
    cursor: not-allowed;
}

.pagination span {
    font-size: 18px;
    font-weight: bold;
    color: #cccccc;
    padding-top: 3%;
}
.page-limit {
    border-radius: 5px;
    background-color: #007bff;
    color: #ffffff;
    width: 100px;
    height: 30px;
    text-align: center;
    size: a3;
    font-size: medium;
}

/* Styly pro disabled select box */
select:disabled {
    background-color: #e9e9e9;
    cursor: not-allowed;
    opacity: 0.7;
}