/* Základní nastavení */
:root {
    --primary-color: #dc2626; /* Červená */
    --primary-dark: #b91c1c;
    --secondary-color: #1e3a8a; /* Tmavě modrá */
    --secondary-light: #2563eb;
    --text-color: #111827;
    --text-light: #6b7280;
    --white: #ffffff;
    --light-bg: #f3f4f6;
    --container-width: 1200px;
}

* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

/* NATIVNÍ SCROLLOVÁNÍ - KLÍČOVÁ ZMĚNA */
html {
    scroll-behavior: smooth;
    scroll-padding-top: 100px; /* Offset pro fixní hlavičku (80px) + margin (20px) */
}

/* Offset pro jednotlivé sekce - zajistí, že sekce nebude skrytá pod hlavičkou */
section[id] {
    scroll-margin-top: 100px;
}

/* Speciální úpravy pro konkrétní sekce */
#kontakt {
    scroll-margin-top: 90px; /* Mírně menší offset pro kontakt */
}

#projekty {
    scroll-margin-top: 90px; /* Menší offset pro projekty/mapu */
}

body {
    font-family: 'Inter', sans-serif;
    line-height: 1.6;
    color: var(--text-color);
    background-color: var(--white);
}

.container {
    width: 100%;
    max-width: var(--container-width);
    margin: 0 auto;
    padding: 0 20px;
}

h1, h2, h3, h4, h5, h6 {
    font-weight: 700;
    line-height: 1.2;
}

img {
    max-width: 100%;
    height: auto;
}

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

ul {
    list-style-type: none;
}

section {
    padding: 40px 0;
}

.text-center {
    text-align: center;
}

.section-header {
    text-align: center;
    margin-bottom: 50px;
}

.section-header h2 {
    font-size: 2rem;
    color: var(--text-color);
    margin-bottom: 15px;
}

.divider {
    width: 140px;
    height: 5px;
    background-color: var(--primary-color);
    margin: 0 auto;
    margin-bottom: 20px;
}

/* Styl pro aktivní odkazy v navigaci */
.main-nav a.active,
.main-nav a.active-section {
    color: var(--primary-color) !important;
    font-weight: 600;
    position: relative;
}

/* Podtržení pro aktivní odkazy */
.main-nav a.active::after,
.main-nav a.active-section::after {
    content: '';
    position: absolute;
    bottom: -2px;
    left: 0;
    width: 100%;
    height: 2px;
    background-color: var(--primary-color);
    border-radius: 1px;
}

/* Styl pro aktivní odkazy v mobilním menu */
.mobile-menu a.active,
.mobile-menu a.active-section {
    color: var(--primary-color) !important;
    font-weight: 600;
    background-color: rgba(220, 38, 38, 0.1);
    border-radius: 4px;
    margin: 0 -10px;
    padding: 10px 10px !important;
}

/* Animace pro změnu aktivního stavu */
.main-nav a,
.mobile-menu a {
    transition: color 0.3s ease, background-color 0.3s ease;
}

.main-nav a::after {
    transition: width 0.3s ease, background-color 0.3s ease;
}

/* Hover efekt pro neaktivní odkazy */
.main-nav a:not(.active):not(.active-section):hover {
    color: var(--primary-color);
}

/* Tlačítka */
.btn-primary, .btn-secondary {
    display: inline-block;
    padding: 12px 24px;
    border-radius: 4px;
    font-weight: 600;
    text-align: center;
    transition: background-color 0.3s, transform 0.2s;
}

.btn-primary {
    background-color: var(--primary-color);
    color: var(--white);
}

.btn-primary:hover {
    background-color: var(--primary-dark);
    transform: translateY(-2px);
}

.btn-secondary {
    background-color: var(--white);
    color: var(--secondary-color);
}

.btn-secondary:hover {
    background-color: #f8f9fa;
    transform: translateY(-2px);
}

/* Header a navigace */
.header {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    background-color: var(--white);
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    z-index: 1200; /* Zvýšeno pro mapu */
}

.header-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    height: 80px;
}

.logo {
    display: flex;
    align-items: center;
}

.logo a {
    display: flex;
    align-items: center;
}

.logo-image {
    height: 50px;
    width: auto;
    margin-right: 12px;
}

.logo-text {
    font-weight: 700;
    color: var(--text-color);
    font-size: 1.1rem;
}

.main-nav {
    display: none;
}

.main-nav ul {
    display: flex;
    align-items: center;
}

.main-nav li:not(:last-child) {
    margin-right: 20px;
}

.main-nav a {
    font-size: 0.9rem;
    font-weight: 500;
    color: var(--text-color);
    padding: 8px 0;
}

.main-nav a:hover {
    color: var(--primary-color);
}

.main-nav a.active {
    color: var(--primary-color);
    font-weight: 600;
}

.mobile-menu-btn {
    background: none;
    border: none;
    cursor: pointer;
    display: flex;
    flex-direction: column;
    width: 30px;
    height: 21px;
    justify-content: space-between;
}

.mobile-menu-btn span {
    display: block;
    width: 100%;
    height: 3px;
    background-color: var(--text-color);
    transition: transform 0.3s, opacity 0.3s;
}

.mobile-menu-btn.active span:nth-child(1) {
    transform: translateY(9px) rotate(45deg);
}

.mobile-menu-btn.active span:nth-child(2) {
    opacity: 0;
}

.mobile-menu-btn.active span:nth-child(3) {
    transform: translateY(-9px) rotate(-45deg);
}

.mobile-menu {
    position: fixed;
    top: 80px;
    left: 0;
    width: 100%;
    height: calc(100% - 80px);
    background-color: var(--white);
    z-index: 999;
    transform: translateX(-100%);
    transition: transform 0.3s;
}

.mobile-menu.active {
    transform: translateX(0);
}

.mobile-menu ul {
    padding: 20px;
}

.mobile-menu li {
    margin-bottom: 15px;
}

.mobile-menu a {
    display: block;
    padding: 10px 0;
    font-size: 1.1rem;
    font-weight: 500;
}

/* Hero sekce */
.hero {
    background-color: var(--secondary-color);
    color: var(--white);
    padding: 140px 0 80px;
    text-align: center;
}

.hero-content {
    max-width: 800px;
    margin: 0 auto;
}

.hero h1 {
    font-size: 2.5rem;
    margin-bottom: 20px;
}

.hero p {
    font-size: 1.2rem;
    margin-bottom: 30px;
    opacity: 0.9;
}

.hero-buttons {
    display: flex;
    flex-direction: column;
    gap: 15px;
    max-width: 300px;
    margin: 0 auto;
}

/* O nás sekce */
.about {
    background-color: var(--white);
}

.about-content {
    display: flex;
    flex-direction: column;
    gap: 40px;
}

.about-text {
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.about-text p {
    margin-bottom: 24px;
    color: var(--text-light);
    font-size: 1.1rem;
    line-height: 1.7;
}

.about-text p:last-child {
    margin-bottom: 0;
}

/* Styly pro galerii v sekci O nás */
.about-gallery {
    display: grid;
    grid-template-columns: repeat(1, 1fr);
    gap: 15px;
}

.about-gallery .gallery-item {
    height: 200px;
    background-color: var(--light-bg);
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
}

.about-gallery .gallery-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s ease;
}

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

/* Aktivity sekce */
.activities {
    background-color: var(--light-bg);
}

.activities-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 30px;
}

.activity-card {
    background-color: var(--white);
    border-radius: 8px;
    padding: 30px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);
    text-align: center;
}

.activity-card h3 {
    margin-bottom: 15px;
    font-size: 1.3rem;
}

.activity-card p {
    color: var(--text-light);
}

/* Projekty (mapa) sekce */
.map-section {
    background-color: var(--white);
}

.section-description {
    max-width: 700px;
    margin: 20px auto 40px;
    text-align: center;
    color: var(--text-light);
}

/* Zvětšení výšky mapy */
.map-container {
    height: 700px;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    margin-bottom: 20px;
}

#project-map {
    height: 100%;
    width: 100%;
}

.map-legend {
    display: flex;
    justify-content: center;
    gap: 30px;
    flex-wrap: wrap;
    margin-top: 20px;
}

.legend-item {
    display: flex;
    align-items: center;
    gap: 8px;
}

.legend-dot {
    width: 16px;
    height: 16px;
    border-radius: 50%;
    display: inline-block;
}

.legend-dot.memorial {
    background-color: #dc2626;
}

.legend-dot.event {
    background-color: #2563eb;
}

.legend-dot.other {
    background-color: #059669;
}

.legend-dot.pripravujeme {
    background-color: #6b7280;
}

/* Oprava překrývání ovládacích tlačítek Leaflet mapy s hlavičkou */
.leaflet-control-zoom {
    margin-top: 90px !important;
    z-index: 900 !important;
}

.leaflet-control-attribution {
    z-index: 900 !important;
}

/* Styly pro Leaflet mapu a popup okna */
.leaflet-popup-content-wrapper {
    border-radius: 8px !important;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2) !important;
}

.leaflet-popup-content {
    margin: 13px 13px !important;
    width: auto !important;
    max-width: 100% !important;
}

.leaflet-popup {
    margin-bottom: 70px !important;
}

.custom-popup .leaflet-popup-content-wrapper {
    background-color: white !important;
    max-width: 350px !important;
    width: auto !important;
}

.leaflet-popup-pane {
    z-index: 700 !important;
}

.map-popup-content {
    max-height: 500px !important;
    overflow-y: auto !important;
    padding: 5px !important;
}

.map-popup-content img {
    width: 100% !important;
    max-height: 200px !important;
    object-fit: cover !important;
    border-radius: 4px !important;
    margin: 10px 0 !important;
}

.map-popup-content .year {
    display: inline-block !important;
    font-size: 12px !important;
    font-weight: 600 !important;
    background-color: #dc2626 !important;
    color: white !important;
    padding: 2px 8px !important;
    border-radius: 3px !important;
    margin-bottom: 10px !important;
}

.map-popup-content h3 {
    font-size: 16px !important;
    margin: 0 0 10px 0 !important;
    color: #111827 !important;
    line-height: 1.4 !important;
}

.map-popup-content p {
    font-size: 14px !important;
    margin: 0 0 10px 0 !important;
    color: #6b7280 !important;
    line-height: 1.5 !important;
}

.map-popup-link {
    display: inline-block !important;
    margin-top: 10px !important;
    color: #2563eb !important;
    font-size: 14px !important;
    font-weight: 500 !important;
    text-decoration: none !important;
}

.map-popup-link:hover {
    text-decoration: underline !important;
}

/* Publikace sekce */
.publications {
    background-color: var(--light-bg);
}

.publications-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 30px;
    margin-bottom: 40px;
}

.publication-card {
    background-color: var(--white);
    border-radius: 8px;
    padding: 15px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);
    display: flex;
    flex-direction: column;
    height: 100%;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.publication-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.1);
}

.publication-image {
    height: 280px;
    background-color: #f5f5f5;
    border-radius: 4px;
    margin-bottom: 15px;
    background-size: contain;
    background-position: center;
    background-repeat: no-repeat;
    position: relative;
    overflow: hidden;
    padding: 5px;
}

.publication-card h3 {
    font-size: 1.1rem;
    margin-bottom: 5px;
}

.publication-info {
    font-size: 0.85rem;
    color: var(--text-light);
    margin-bottom: 15px;
}

.publication-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: auto;
}

.price {
    font-weight: 700;
    color: var(--primary-color);
}

.detail-link {
    color: var(--secondary-light);
}

.detail-link:hover {
    text-decoration: underline;
}

/* Kontakt sekce */
.contact {
    background-color: var(--secondary-color);
    color: var(--white);
}

.contact .section-header h2 {
    color: var(--white);
}

.info-heading {
    font-weight: 600;
    margin-bottom: 5px;
}

.qr-code {
    text-align: center;
}

.qr-image {
    width: 100px;
    height: auto;
    background-color: white;
    padding: 5px;
    border-radius: 4px;
}

/* Footer */
.footer {
    background-color: #111827;
    color: #9ca3af;
    padding: 30px 0;
}

.footer-content {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 20px;
}

.footer-logo span {
    color: var(--white);
    font-size: 1.1rem;
    font-weight: 600;
}

.footer-stats {
    display: flex;
    justify-content: center;
    align-items: center;
}

.footer-stats img {
    opacity: 0.9;
    transition: opacity 0.3s ease;
}

.footer-stats img:hover {
    opacity: 1;
}

.footer-info {
    text-align: center;
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.footer-copyright p,
.footer-updated p {
    margin: 0;
    font-size: 0.9rem;
    color: #9ca3af;
}

.footer-updated p {
    font-size: 0.85rem;
    color: #6b7280;
}

.footer-copyright a:hover {
    color: var(--primary-color) !important;
    text-decoration: underline !important;
}

/* Tlačítko pro návrat nahoru */
.back-to-top {
    position: fixed;
    bottom: 30px;
    right: 30px;
    width: 40px;
    height: 40px;
    background-color: var(--primary-color);
    color: var(--white);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    cursor: pointer;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.3s, visibility 0.3s;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    z-index: 900;
}

.back-to-top.visible {
    opacity: 1;
    visibility: visible;
}

/* Stránka Aktuálně */
.aktualne-page {
    padding: 140px 0 80px;
    background-color: var(--white);
}

.aktualne-page .section-header {
    margin-bottom: 50px;
}

.aktualne-page h1, .links-page h1, .publikace-page h1, .gallery-section h1 {
    font-size: 2.5rem;
    text-align: center;
    color: var(--text-color);
    margin-bottom: 15px;
}

.events-list {
    max-width: 900px;
    margin: 0 auto;
}

.event-item {
    margin-bottom: 60px;
    background-color: var(--light-bg);
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);
}

.event-date {
    background-color: var(--secondary-color);
    color: var(--white);
    padding: 12px 20px;
    font-weight: 600;
    font-size: 1.1rem;
}

.event-content {
    padding: 25px;
}

.event-content p {
    margin-bottom: 20px;
    line-height: 1.7;
    color: var(--text-color);
}

.event-content a {
    color: var(--secondary-light);
    font-weight: 500;
}

.event-content a:hover {
    color: var(--secondary-color);
    text-decoration: underline;
}

/* Galerie fotografií na stránce Aktuálně */
.event-gallery-container {
    width: 100%;
    display: flex;
    justify-content: center;
    margin: 20px 0;
}

.event-gallery {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    max-width: 660px;
    justify-content: center;
}

.event-gallery .gallery-item {
    flex: 0 0 calc(33.33% - 7px);
    max-width: 210px;
    min-width: 180px;
    position: relative;
    overflow: hidden;
    border-radius: 4px;
    width: 100%;
    height: 150px;
    cursor: pointer;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.event-gallery .gallery-item:hover {
    transform: translateY(-3px);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.15);
}

.event-gallery .gallery-item a {
    display: block;
    width: 100%;
    height: 100%;
}

.event-gallery .gallery-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.4s ease;
}

.event-gallery .gallery-item::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.2);
    opacity: 0;
    transition: opacity 0.3s ease;
    pointer-events: none;
}

.event-gallery .gallery-item:hover::after {
    opacity: 1;
}

.event-gallery .gallery-item::before {
    content: '+';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    color: white;
    font-size: 32px;
    font-weight: bold;
    opacity: 0;
    z-index: 2;
    transition: opacity 0.3s ease;
    pointer-events: none;
    text-shadow: 0 0 10px rgba(0, 0, 0, 0.5);
}

.event-gallery .gallery-item:hover::before {
    opacity: 1;
}

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

/* Galerie publikací - 4 náhledy na řádek */
.event-gallery.publication-gallery {
    gap: 10px;
    justify-content: center;
}

.event-gallery.publication-gallery .gallery-item {
    flex: 0 0 calc(25% - 8px);
    max-width: 180px;
    min-width: 140px;
    height: auto;
    background-color: #f9f9f9;
    padding: 6px;
    margin-bottom: 10px;
}

.event-gallery.publication-gallery .gallery-item:hover {
    transform: translateY(-3px);
    box-shadow: 0 6px 15px rgba(0, 0, 0, 0.12);
}

.event-gallery.publication-gallery .gallery-item img {
    width: 100%;
    height: auto;
    max-height: 240px;
    object-fit: contain;
    border-radius: 4px;
    transition: transform 0.3s ease;
    background-color: white;
}

.event-gallery.publication-gallery .gallery-item:hover img {
    transform: scale(1.02);
}

.event-gallery.publication-gallery .gallery-item::before {
    background-color: rgba(0, 0, 0, 0.08);
    border-radius: 6px;
}

.event-gallery.publication-gallery .gallery-item::after {
    font-size: 20px;
}

/* Speciální styly pro portréty knih */
.event-gallery .portrait-image {
    height: auto;
    max-height: 240px;
    width: auto;
    max-width: 160px;
    margin: 0 auto;
}

.event-gallery .portrait-image img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    box-shadow: 0 3px 10px rgba(0, 0, 0, 0.1);
    background-color: #f9f9f9;
    border-radius: 4px;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.event-gallery .portrait-image:hover img {
    transform: translateY(-3px);
    box-shadow: 0 6px 12px rgba(0, 0, 0, 0.12);
}

/* Video kontejnery */
.video-container {
    position: relative;
    padding-bottom: 56.25%;
    padding-top: 30px;
    height: 0;
    overflow: hidden;
    margin: 20px auto;
    border-radius: 8px;
    max-width: 640px;
}

.video-container iframe {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    border: 0;
}

.event-video-container {
    margin: 0 auto 20px auto;
    display: flex;
    justify-content: center;
    max-width: 100%;
}

/* LIGHTBOX STYLY */
.lightbox-container {
    display: none;
    position: fixed;
    z-index: 2000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.9);
    align-items: center;
    justify-content: center;
    padding: 10px;
    box-sizing: border-box;
}

.lightbox-content {
    position: relative;
    max-width: 90%;
    max-height: 90%;
    margin: auto;
    display: flex;
    align-items: center;
    justify-content: center;
}

.lightbox-image {
    max-width: 100%;
    max-height: 90vh;
    object-fit: contain;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.3);
    border-radius: 4px;
    animation: fadeIn 0.3s;
    display: block;
    transition: opacity 0.3s ease;
}

.lightbox-close {
    position: absolute;
    top: 20px;
    right: 25px;
    color: #f1f1f1;
    font-size: 40px;
    font-weight: bold;
    cursor: pointer;
    z-index: 2100;
    transition: color 0.2s ease;
    width: 50px;
    height: 50px;
    display: flex;
    align-items: center;
    justify-content: center;
    text-shadow: 0 0 10px rgba(0, 0, 0, 0.5);
}

.lightbox-close:hover {
    color: var(--primary-color);
}

.lightbox-nav {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    color: white;
    font-size: 30px;
    font-weight: bold;
    cursor: pointer;
    background-color: rgba(0, 0, 0, 0.3);
    border-radius: 50%;
    width: 50px;
    height: 50px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background-color 0.3s ease;
    z-index: 2100;
    user-select: none;
    box-shadow: 0 0 10px rgba(0, 0, 0, 0.3);
}

.lightbox-nav:hover {
    background-color: rgba(220, 38, 38, 0.9);
}

.lightbox-prev {
    left: 20px;
}

.lightbox-next {
    right: 20px;
}

.lightbox-counter {
    position: absolute;
    bottom: 20px;
    left: 50%;
    transform: translateX(-50%);
    color: white;
    font-size: 16px;
    background-color: rgba(0, 0, 0, 0.5);
    padding: 5px 15px;
    border-radius: 20px;
    z-index: 2100;
}

.lightbox-loading {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    z-index: 2100;
}

.spinner {
    width: 50px;
    height: 50px;
    border: 5px solid rgba(255, 255, 255, 0.3);
    border-radius: 50%;
    border-top-color: var(--primary-color, #dc2626);
    animation: spin 1s infinite ease-in-out;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

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

/* Styly pro paginaci a filtrování */
.pagination {
    display: flex;
    justify-content: center;
    align-items: center;
    margin-top: 40px;
    margin-bottom: 40px;
    gap: 10px;
}

.pagination-button {
    background-color: #f5f5f5;
    border: 1px solid #ddd;
    color: #333;
    padding: 8px 16px;
    cursor: pointer;
    border-radius: 4px;
    transition: background-color 0.3s;
    font-size: 0.9rem;
}

.pagination-button:hover:not(:disabled) {
    background-color: #e9e9e9;
}

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

.pagination-numbers {
    display: flex;
    gap: 5px;
    align-items: center;
}

.page-number {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 36px;
    border: 1px solid #ddd;
    border-radius: 4px;
    cursor: pointer;
    transition: all 0.3s;
    font-size: 0.9rem;
}

.page-number:hover {
    background-color: #e9e9e9;
}

.page-number.active {
    background-color: var(--primary-color);
    color: white;
    border-color: var(--primary-color);
}

.page-ellipsis {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 36px;
    font-size: 0.9rem;
}

.pagination-item {
    display: block;
}

.pagination-item.hidden {
    display: none;
}

/* Archiv akcí */
.events-filter-container {
    display: flex;
    justify-content: center;
    margin-bottom: 30px;
}

.events-filter {
    background-color: var(--light-bg);
    padding: 10px 20px;
    border-radius: 8px;
    display: flex;
    align-items: center;
    gap: 10px;
}

.year-select {
    padding: 8px 12px;
    border-radius: 4px;
    border: 1px solid #ddd;
    background-color: white;
    font-family: inherit;
    cursor: pointer;
}

.year-select:hover {
    border-color: #bbb;
}

.no-events-message {
    text-align: center;
    margin: 40px 0;
    padding: 20px;
    color: var(--text-light);
    background-color: var(--light-bg);
    border-radius: 8px;
    font-size: 1.1rem;
}

/* Aktuálně sekce pro úvodní stránku */
.latest-news {
    background-color: var(--white);
    padding: 80px 0;
}

.latest-news .events-list {
    max-width: 900px;
    margin: 0 auto;
}

.latest-news .event-item {
    margin-bottom: 40px;
    background-color: var(--light-bg);
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.latest-news .event-item:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.1);
}

.latest-news .event-item:last-child {
    margin-bottom: 0;
}

.latest-news .event-content p {
    margin-bottom: 15px;
}

.latest-news .event-gallery {
    max-width: 100%;
    flex-wrap: wrap;
    gap: 8px;
}

.latest-news .gallery-item {
    flex: 0 0 calc(50% - 4px);
    max-width: 200px;
    height: 140px;
}

/* Odstranění hover efektů pro galerii na úvodní stránce */
.latest-news .gallery-item::before,
.latest-news .gallery-item::after {
    display: none !important;
    opacity: 0 !important;
    content: none !important;
}

.latest-news .gallery-item:hover img {
    transform: none !important;
}

.latest-news .event-gallery .gallery-item,
.latest-news .event-gallery .gallery-item img {
    cursor: default !important;
    pointer-events: none !important;
}

.latest-news .event-gallery .gallery-item:hover {
    transform: none !important;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05) !important;
}

.loading-spinner {
    text-align: center;
    padding: 30px;
    font-style: italic;
    color: var(--text-light);
}

/* Styly pro stránku odkazů */
.links-page {
    padding: 140px 0 80px;
    background-color: var(--white);
}

.links-section {
    margin-bottom: 60px;
}

.links-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 25px;
    margin-bottom: 40px;
}

.link-item {
    background-color: var(--light-bg);
    border-radius: 8px;
    padding: 25px;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);
}

.link-item:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.1);
}

.link-title {
    font-size: 1.3rem;
    margin-bottom: 10px;
    color: var(--secondary-color);
    font-weight: 600;
}

.link-description {
    margin-bottom: 15px;
    color: var(--text-light);
    font-size: 0.95rem;
}

.link-url {
    display: inline-block;
    color: var(--primary-color);
    font-weight: 500;
    text-decoration: none;
    transition: color 0.2s;
}

.link-url:hover {
    color: var(--primary-dark);
    text-decoration: underline;
}

/* Stylování pro fotogalerii */
.gallery-section {
    background-color: var(--white);
    padding: 140px 0 80px;
}

.gallery-section .section-header {
    margin-bottom: 40px;
}

.gallery-container {
    margin-bottom: 60px;
    background-color: var(--light-bg);
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);
}

.gallery-title {
    background-color: var(--secondary-color);
    color: var(--white);
    padding: 12px 20px;
    font-weight: 600;
    font-size: 1.1rem;
}

.gallery-content {
    padding: 25px;
}

.photo-gallery {
    display: flex;
    flex-wrap: wrap;
    gap: 15px;
    justify-content: center;
}

.photo-gallery .gallery-item {
    flex: 0 0 calc(25% - 12px);
    max-width: 250px;
    height: 180px;
    position: relative;
    overflow: hidden;
    border-radius: 4px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.photo-gallery .gallery-item:hover {
    transform: translateY(-3px);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.15);
}

.photo-gallery .gallery-item a {
    display: block;
    width: 100%;
    height: 100%;
}

.photo-gallery .gallery-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.4s ease;
}

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

.external-gallery {
    margin-top: 10px;
    background-color: var(--white);
    padding: 15px 20px;
    border-radius: 8px;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.05);
}

.external-gallery h3 {
    margin-bottom: 10px;
    color: var(--secondary-color);
    font-size: 1.1rem;
}

.external-gallery-list {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.external-gallery-list a {
    color: var(--secondary-light);
    padding: 6px 0;
    border-bottom: 1px solid #eee;
    transition: color 0.3s;
}

.external-gallery-list a:hover {
    color: var(--primary-color);
}

/* Styly pro stránku ochrany osobních údajů */
.privacy-page {
    padding: 140px 0 80px;
    background-color: var(--white);
}

.privacy-content {
    max-width: 800px;
    margin: 0 auto;
    line-height: 1.7;
}

.privacy-section {
    margin-bottom: 40px;
    background-color: var(--light-bg);
    border-radius: 8px;
    padding: 30px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);
}

.privacy-section:last-child {
    margin-bottom: 0;
}

.privacy-section h2 {
    color: var(--secondary-color);
    font-size: 1.5rem;
    margin-bottom: 20px;
    border-bottom: 2px solid var(--primary-color);
    padding-bottom: 10px;
}

.privacy-section p {
    margin-bottom: 15px;
    color: var(--text-color);
    font-size: 1rem;
}

.privacy-section p:last-child {
    margin-bottom: 0;
}

.privacy-section ul {
    margin: 15px 0;
    padding-left: 0;
    list-style: none;
}

.privacy-section li {
    margin-bottom: 10px;
    padding-left: 25px;
    position: relative;
    color: var(--text-color);
}

.privacy-section li::before {
    content: "•";
    color: var(--primary-color);
    font-weight: bold;
    position: absolute;
    left: 8px;
    font-size: 1.2rem;
}

.privacy-section strong {
    color: var(--secondary-color);
    font-weight: 600;
}

/* RESPONZIVNÍ DESIGN */

/* Mobilní zařízení - menší offset pro scrollování */
@media (max-width: 768px) {
    html {
        scroll-padding-top: 90px;
    }
    
    section[id] {
        scroll-margin-top: 90px;
    }
    
    #kontakt,
    #projekty {
        scroll-margin-top: 85px;
    }
    
    .main-nav a.active::after,
    .main-nav a.active-section::after {
        display: none;
    }
    
    .map-container {
        height: 600px;
    }
    
    .leaflet-control-zoom {
        margin-top: 85px !important;
    }
    
    .leaflet-popup-content-wrapper {
        max-width: 300px !important;
    }
    
    .map-popup-content img {
        max-height: 150px !important;
    }
    
    .aktualne-page {
        padding: 120px 0 60px;
    }
    
    .aktualne-page h1 {
        font-size: 2rem;
    }
    
    .event-item {
        margin-bottom: 40px;
    }
    
    .event-date {
        padding: 10px 15px;
        font-size: 1rem;
    }
    
    .event-content {
        padding: 20px;
    }
    
    .event-gallery {
        max-width: 510px;
        gap: 8px;
    }
    
    .event-gallery .gallery-item {
        flex: 0 0 calc(33.33% - 6px);
        height: 120px;
        min-width: 150px;
    }
    
    .event-gallery.publication-gallery .gallery-item {
        flex: 0 0 calc(50% - 6px);
        max-width: 200px;
        min-width: 160px;
    }
    
    .lightbox-nav {
        width: 44px;
        height: 44px;
        font-size: 26px;
        opacity: 0.95;
    }

    .lightbox-prev {
        left: 10px;
    }

    .lightbox-next {
        right: 10px;
    }
    
    .lightbox-close {
        top: 10px;
        right: 10px;
        font-size: 30px;
    }
    
    .lightbox-image {
        max-height: 80vh;
    }
    
    .lightbox-counter {
        bottom: 10px;
        font-size: 14px;
        padding: 3px 10px;
    }
    
    .spinner {
        width: 40px;
        height: 40px;
        border-width: 4px;
    }
    
    .pagination {
        flex-wrap: wrap;
    }
    
    .pagination-numbers {
        order: 2;
        margin-top: 10px;
        flex-wrap: wrap;
        justify-content: center;
    }
    
    .pagination-button {
        padding: 6px 12px;
    }
    
    .page-number, .page-ellipsis {
        width: 32px;
        height: 32px;
        font-size: 0.85rem;
    }
    
    .latest-news .gallery-item {
        flex: 0 0 calc(50% - 4px);
        height: 120px;
    }
    
    .privacy-page {
        padding: 120px 0 60px;
    }
    
    .privacy-section {
        padding: 20px;
        margin-bottom: 30px;
    }
    
    .privacy-section h2 {
        font-size: 1.3rem;
    }
    
    .privacy-content {
        margin: 0 15px;
    }
    
    .photo-gallery .gallery-item {
        flex: 0 0 calc(50% - 8px);
        height: 160px;
    }
    
    .gallery-content {
        padding: 20px 15px;
    }
}

@media (min-width: 480px) {
    .about-gallery {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .about-gallery .gallery-item {
        height: 180px;
    }
}

@media (max-width: 640px) {
    .event-gallery {
        max-width: 340px;
    }
    
    .event-gallery .gallery-item {
        flex: 0 0 calc(50% - 5px);
        min-width: 140px;
    }
}

@media (max-width: 480px) {
    .map-container {
        height: 500px;
    }
    
    .event-gallery {
        max-width: 280px;
    }
    
    .event-gallery .gallery-item {
        flex: 0 0 100%;
        height: 180px;
    }
    
    .event-gallery.publication-gallery .gallery-item {
        flex: 0 0 calc(50% - 5px);
        max-width: 160px;
        min-width: 120px;
    }
    
    .latest-news .gallery-item {
        flex: 0 0 100%;
        height: 160px;
    }
    
    .privacy-section {
        padding: 15px;
    }
    
    .privacy-section h2 {
        font-size: 1.2rem;
        margin-bottom: 15px;
    }
    
    .photo-gallery .gallery-item {
        flex: 0 0 100%;
        height: 200px;
        max-width: 100%;
    }
    
    .gallery-content {
        padding: 15px 10px;
    }
    
    .gallery-title {
        font-size: 1rem;
        padding: 10px 15px;
    }
}

@media (min-width: 768px) {
    .main-nav {
        display: block;
    }
    
    .mobile-menu-btn {
        display: none;
    }
    
    .hero h1 {
        font-size: 3rem;
    }
    
    .hero-buttons {
        flex-direction: row;
        max-width: none;
        justify-content: center;
    }
    
    .about-content {
        flex-direction: row;
    }
    
    .about-text {
        flex: 1;
    }
    
    .about-gallery {
        flex: 1;
    }
    
    .about-gallery .gallery-item {
        height: 180px;
    }
    
    .activities-grid {
        grid-template-columns: repeat(3, 1fr);
    }
    
    .publications-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .publication-image {
        height: 240px;
    }
    
    .footer-content {
        flex-direction: row;
        justify-content: space-between;
        align-items: center;
        gap: 30px;
    }
    
    .footer-info {
        text-align: right;
    }
    
    .footer-stats {
        order: 0;
    }
    
    .footer-logo {
        order: 1;
        flex: 1;
        text-align: center;
    }
    
    .footer-info {
        order: 2;
    }
    
    .links-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .photo-gallery .gallery-item {
        flex: 0 0 calc(33.33% - 10px);
    }
}

@media (min-width: 1024px) {
    .map-container {
        height: 800px;
    }
    
    .publications-grid {
        grid-template-columns: repeat(4, 1fr);
    }
    
    .about-gallery .gallery-item {
        height: 200px;
    }
    
    .footer-content {
        display: grid;
        grid-template-columns: 1fr auto 1fr;
        align-items: center;
        gap: 20px;
    }
    
    .footer-stats {
        justify-self: start;
    }
    
    .footer-logo {
        justify-self: center;
        text-align: center;
    }
    
    .footer-info {
        justify-self: end;
        text-align: right;
    }
    
    .links-grid {
        grid-template-columns: repeat(3, 1fr);
    }
}

@media (min-width: 1200px) {
    .event-gallery.publication-gallery .gallery-item {
        flex: 0 0 calc(23% - 8px);
        max-width: 200px;
    }
}

/* Respektování preferencí uživatele pro animace */
@media (prefers-reduced-motion: reduce) {
    html {
        scroll-behavior: auto;
    }
    
    * {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
}

/* Media queries pro layout čtyř sloupců */
@media (max-width: 991px) {
    .four-columns > div {
        width: 100% !important;
        float: none !important;
        text-align: center;
        margin-bottom: 30px;
        height: auto !important;
    }
    
    .four-columns > div:first-child,
    .four-columns > div:nth-child(3) {
        text-align: left;
    }
}